@gv-tech/ui-web 2.28.0 → 2.29.1
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/__contracts.d.ts +44 -2
- package/dist/__contracts.d.ts.map +1 -1
- package/dist/accordion-D5QXSsCK.mjs +248 -0
- package/dist/accordion-DjyDOX-h.js +1 -0
- package/dist/accordion.cjs +1 -1
- package/dist/accordion.d.ts +5 -5
- package/dist/accordion.d.ts.map +1 -1
- package/dist/accordion.mjs +1 -1
- package/dist/alert-dialog-B-a0Wa1M.mjs +182 -0
- package/dist/alert-dialog-DYQAhGBC.js +1 -0
- package/dist/alert-dialog.cjs +1 -1
- package/dist/alert-dialog.d.ts +13 -13
- package/dist/alert-dialog.d.ts.map +1 -1
- package/dist/alert-dialog.mjs +1 -1
- package/dist/alert.cjs +1 -1
- package/dist/alert.d.ts +5 -5
- package/dist/alert.d.ts.map +1 -1
- package/dist/alert.mjs +4 -4
- package/dist/aspect-ratio-C-KOOyGP.js +1 -0
- package/dist/{aspect-ratio-DnChDaBi.mjs → aspect-ratio-s7Ji1MSr.mjs} +10 -9
- package/dist/aspect-ratio.cjs +1 -1
- package/dist/aspect-ratio.d.ts +2 -2
- package/dist/aspect-ratio.d.ts.map +1 -1
- package/dist/aspect-ratio.mjs +1 -1
- package/dist/attachment.cjs +1 -0
- package/dist/attachment.d.ts +23 -0
- package/dist/attachment.d.ts.map +1 -0
- package/dist/attachment.mjs +101 -0
- package/dist/attachment.test.d.ts +2 -0
- package/dist/attachment.test.d.ts.map +1 -0
- package/dist/avatar-4K3XjhP8.js +1 -0
- package/dist/avatar-d8Di248f.mjs +138 -0
- package/dist/avatar.cjs +1 -1
- package/dist/avatar.d.ts +7 -7
- package/dist/avatar.d.ts.map +1 -1
- package/dist/avatar.mjs +1 -1
- package/dist/badge.cjs +1 -1
- package/dist/badge.d.ts +2 -2
- package/dist/badge.d.ts.map +1 -1
- package/dist/badge.mjs +2 -2
- package/dist/breadcrumb.cjs +1 -1
- package/dist/breadcrumb.d.ts +7 -7
- package/dist/breadcrumb.d.ts.map +1 -1
- package/dist/breadcrumb.mjs +25 -27
- package/dist/bubble.cjs +1 -0
- package/dist/bubble.d.ts +13 -0
- package/dist/bubble.d.ts.map +1 -0
- package/dist/bubble.mjs +72 -0
- package/dist/bubble.test.d.ts +2 -0
- package/dist/bubble.test.d.ts.map +1 -0
- package/dist/button-group.cjs +1 -1
- package/dist/button-group.d.ts +4 -4
- package/dist/button-group.d.ts.map +1 -1
- package/dist/button-group.mjs +7 -8
- package/dist/button.cjs +1 -1
- package/dist/button.d.ts +2 -2
- package/dist/button.d.ts.map +1 -1
- package/dist/button.mjs +7 -7
- package/dist/calendar-DFj14O6r.js +1 -0
- package/dist/{calendar-Dg6VGycy.mjs → calendar-UW8h9dfh.mjs} +870 -842
- package/dist/calendar.cjs +1 -1
- package/dist/calendar.d.ts +3 -3
- package/dist/calendar.d.ts.map +1 -1
- package/dist/calendar.mjs +1 -1
- package/dist/card.cjs +1 -1
- package/dist/card.d.ts +7 -7
- package/dist/card.d.ts.map +1 -1
- package/dist/card.mjs +5 -5
- package/dist/carousel-CNGpg5df.js +1 -0
- package/dist/{carousel-DbDoNdqJ.mjs → carousel-DG9xGJns.mjs} +53 -55
- package/dist/carousel.cjs +1 -1
- package/dist/carousel.d.ts +6 -6
- package/dist/carousel.d.ts.map +1 -1
- package/dist/carousel.mjs +1 -1
- package/dist/chart.cjs +1 -1
- package/dist/chart.d.ts +4 -4
- package/dist/chart.d.ts.map +1 -1
- package/dist/chart.mjs +1 -1
- package/dist/checkbox-BCgbTAdU.js +1 -0
- package/dist/checkbox-Dq8VHKDH.mjs +186 -0
- package/dist/checkbox.cjs +1 -1
- package/dist/checkbox.d.ts +2 -2
- package/dist/checkbox.d.ts.map +1 -1
- package/dist/checkbox.mjs +1 -1
- package/dist/chunk-HBS6WEDP-CQNaACTf.js +1 -0
- package/dist/chunk-HBS6WEDP-aK8IuEX9.mjs +63 -0
- package/dist/collapsible.cjs +1 -1
- package/dist/collapsible.d.ts +4 -4
- package/dist/collapsible.d.ts.map +1 -1
- package/dist/collapsible.mjs +7 -7
- package/dist/combobox-CpPIGtPJ.js +4 -0
- package/dist/combobox-b4OmCNw1.mjs +5887 -0
- package/dist/combobox.cjs +1 -1
- package/dist/combobox.d.ts +14 -14
- package/dist/combobox.d.ts.map +1 -1
- package/dist/combobox.mjs +1 -1
- package/dist/command-5hobOyGG.mjs +545 -0
- package/dist/command-Dbqnm9kI.js +1 -0
- package/dist/command.cjs +1 -1
- package/dist/command.d.ts +10 -10
- package/dist/command.d.ts.map +1 -1
- package/dist/command.mjs +1 -1
- package/dist/context-menu-DyTUismw.js +1 -0
- package/dist/context-menu-DzzU-_v8.mjs +317 -0
- package/dist/context-menu.cjs +1 -1
- package/dist/context-menu.d.ts +16 -16
- package/dist/context-menu.d.ts.map +1 -1
- package/dist/context-menu.mjs +1 -1
- package/dist/dialog.cjs +1 -1
- package/dist/dialog.d.ts +11 -11
- package/dist/dialog.d.ts.map +1 -1
- package/dist/dialog.mjs +25 -25
- package/dist/direction.cjs +1 -1
- package/dist/direction.d.ts +2 -2
- package/dist/direction.d.ts.map +1 -1
- package/dist/direction.mjs +1 -1
- package/dist/dist-1zUKVGvf.js +1 -0
- package/dist/dist-B057I8ju.mjs +30 -0
- package/dist/dist-BB78QQyQ.mjs +41 -0
- package/dist/dist-BBvidwzC.js +1 -0
- package/dist/{dist-Cacc4QIh.mjs → dist-BEbV0Hal.mjs} +9 -5
- package/dist/dist-BPL7gUpg.mjs +18 -0
- package/dist/dist-BTUvBzOm.js +1 -0
- package/dist/dist-BU-TFzJf.js +1 -0
- package/dist/dist-Bb5W_J2F.mjs +39 -0
- package/dist/dist-BbI6NHqR.mjs +23 -0
- package/dist/dist-BexAB6yo.mjs +192 -0
- package/dist/dist-BgXIqHHq.js +1 -0
- package/dist/dist-Bvfb4y_L.mjs +100 -0
- package/dist/dist-C8Pm6LRc.js +1 -0
- package/dist/dist-CPAF050o.mjs +90 -0
- package/dist/dist-CS572Be42.mjs +11 -0
- package/dist/dist-CUvxOuXM.mjs +551 -0
- package/dist/dist-C_iFkwIX.js +1 -0
- package/dist/dist-ClYM7l1t.js +1 -0
- package/dist/dist-CpKLY_uZ.mjs +96 -0
- package/dist/dist-D1qkELLT.js +1 -0
- package/dist/dist-D7-Fky36.js +1 -0
- package/dist/dist-DEpkkABT.js +1 -0
- package/dist/dist-DI1vapnL.mjs +20 -0
- package/dist/dist-DJqkhIXb2.js +1 -0
- package/dist/dist-DKXojpVG.js +1 -0
- package/dist/dist-DYUvPCPC.js +1 -0
- package/dist/dist-DZiOPWLp.js +1 -0
- package/dist/dist-DatgTWLz.mjs +202 -0
- package/dist/dist-Dm3IQk5b.mjs +685 -0
- package/dist/dist-DoivLw3t.js +1 -0
- package/dist/dist-Dq-h6VAy.mjs +118 -0
- package/dist/dist-Dt6m-kwU.mjs +221 -0
- package/dist/dist-E8ieJTBC.mjs +190 -0
- package/dist/{dist-C9PlF532.mjs → dist-GazS1kfR.mjs} +1 -1
- package/dist/dist-N97cIp0_.js +1 -0
- package/dist/dist-OqDzLHTa.mjs +460 -0
- package/dist/dist-Qm9hFvM1.js +1 -0
- package/dist/dist-UkWa-Arh.mjs +16 -0
- package/dist/dist-UnTrOmPV.js +1 -0
- package/dist/dist-YAADIsyo.js +1 -0
- package/dist/dist-Zs2sjYhL.js +1 -0
- package/dist/dist-hFLuJoMi.js +1 -0
- package/dist/dist-s7ibhASj.mjs +181 -0
- package/dist/dist-vu20fMUK.mjs +93 -0
- package/dist/drawer.cjs +1 -1
- package/dist/drawer.d.ts +11 -11
- package/dist/drawer.d.ts.map +1 -1
- package/dist/drawer.mjs +2 -2
- package/dist/{dropdown-menu-CriaO1_i.mjs → dropdown-menu-BqAhn64y.mjs} +109 -143
- package/dist/dropdown-menu-BtKOr--r.js +1 -0
- package/dist/dropdown-menu.cjs +1 -1
- package/dist/dropdown-menu.d.ts +16 -16
- package/dist/dropdown-menu.d.ts.map +1 -1
- package/dist/dropdown-menu.mjs +1 -1
- package/dist/empty.cjs +1 -1
- package/dist/empty.d.ts +7 -7
- package/dist/empty.d.ts.map +1 -1
- package/dist/empty.mjs +2 -2
- package/dist/es2015-DbAsWDbs.js +41 -0
- package/dist/es2015-DbsmTzuc.mjs +571 -0
- package/dist/field.cjs +1 -1
- package/dist/field.d.ts +12 -12
- package/dist/field.d.ts.map +1 -1
- package/dist/field.mjs +6 -7
- package/dist/floating-ui.react-dom-BwFRxNGc.js +1 -0
- package/dist/{floating-ui.react-dom-DgS_bqyY.mjs → floating-ui.react-dom-CyupHsR6.mjs} +249 -276
- package/dist/form.cjs +1 -1
- package/dist/form.d.ts +8 -6
- package/dist/form.d.ts.map +1 -1
- package/dist/form.mjs +8 -8
- package/dist/hover-card-DMsxpR9G.mjs +178 -0
- package/dist/hover-card-DWXusgiI.js +1 -0
- package/dist/hover-card.cjs +1 -1
- package/dist/hover-card.d.ts +4 -4
- package/dist/hover-card.d.ts.map +1 -1
- package/dist/hover-card.mjs +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +6 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.mjs +40 -34
- package/dist/input-group.cjs +1 -1
- package/dist/input-group.d.ts +7 -7
- package/dist/input-group.d.ts.map +1 -1
- package/dist/input-group.mjs +6 -11
- package/dist/input-otp-D49Y9VcH.mjs +409 -0
- package/dist/input-otp-u3obpt-Q.js +20 -0
- package/dist/input-otp.cjs +1 -1
- package/dist/input-otp.d.ts +5 -5
- package/dist/input-otp.d.ts.map +1 -1
- package/dist/input-otp.mjs +1 -1
- package/dist/input.cjs +1 -1
- package/dist/input.d.ts +1 -1
- package/dist/input.d.ts.map +1 -1
- package/dist/input.mjs +1 -1
- package/dist/item.cjs +1 -1
- package/dist/item.d.ts +11 -11
- package/dist/item.d.ts.map +1 -1
- package/dist/item.mjs +7 -8
- package/dist/kbd.cjs +1 -1
- package/dist/kbd.d.ts +2 -2
- package/dist/kbd.d.ts.map +1 -1
- package/dist/kbd.mjs +2 -2
- package/dist/label-Dacwh21G.js +1 -0
- package/dist/label-DsSICLPc.mjs +28 -0
- package/dist/label.cjs +1 -1
- package/dist/label.d.ts +2 -2
- package/dist/label.d.ts.map +1 -1
- package/dist/label.mjs +1 -1
- package/dist/marker.cjs +1 -0
- package/dist/marker.d.ts +12 -0
- package/dist/marker.d.ts.map +1 -0
- package/dist/marker.mjs +40 -0
- package/dist/marker.test.d.ts +2 -0
- package/dist/marker.test.d.ts.map +1 -0
- package/dist/menubar-BYNeRuzx.js +1 -0
- package/dist/{menubar-BcyqIJgy.mjs → menubar-DZqEj6S1.mjs} +138 -172
- package/dist/menubar.cjs +1 -1
- package/dist/menubar.d.ts +17 -17
- package/dist/menubar.d.ts.map +1 -1
- package/dist/menubar.mjs +1 -1
- package/dist/message-scroller-CS4t7Ypn.mjs +824 -0
- package/dist/message-scroller-DqLu0YI6.js +1 -0
- package/dist/message-scroller.cjs +1 -0
- package/dist/message-scroller.d.ts +13 -0
- package/dist/message-scroller.d.ts.map +1 -0
- package/dist/message-scroller.mjs +3 -0
- package/dist/message-scroller.test.d.ts +2 -0
- package/dist/message-scroller.test.d.ts.map +1 -0
- package/dist/message.cjs +1 -0
- package/dist/message.d.ts +11 -0
- package/dist/message.d.ts.map +1 -0
- package/dist/message.mjs +50 -0
- package/dist/message.test.d.ts +2 -0
- package/dist/message.test.d.ts.map +1 -0
- package/dist/native-select.cjs +1 -1
- package/dist/native-select.d.ts +3 -3
- package/dist/native-select.d.ts.map +1 -1
- package/dist/native-select.mjs +12 -12
- package/dist/navigation-menu-B36G3O83.js +1 -0
- package/dist/navigation-menu-RO6thDOF.mjs +636 -0
- package/dist/navigation-menu.cjs +1 -1
- package/dist/navigation-menu.d.ts +9 -9
- package/dist/navigation-menu.d.ts.map +1 -1
- package/dist/navigation-menu.mjs +1 -1
- package/dist/pagination.cjs +1 -1
- package/dist/pagination.d.ts +8 -8
- package/dist/pagination.d.ts.map +1 -1
- package/dist/pagination.mjs +42 -35
- package/dist/popover-DSBkc70V.mjs +243 -0
- package/dist/popover-DUHbvKB8.js +1 -0
- package/dist/popover.cjs +1 -1
- package/dist/popover.d.ts +8 -8
- package/dist/popover.d.ts.map +1 -1
- package/dist/popover.mjs +1 -1
- package/dist/progress-B9z08UXf.js +6 -0
- package/dist/progress-CQ4nQ85t.mjs +92 -0
- package/dist/progress.cjs +1 -1
- package/dist/progress.d.ts +2 -2
- package/dist/progress.d.ts.map +1 -1
- package/dist/progress.mjs +1 -1
- package/dist/questionnaire-CVED7G7R.mjs +1159 -0
- package/dist/questionnaire-PWClWvST.js +1 -0
- package/dist/questionnaire.cjs +1 -0
- package/dist/questionnaire.d.ts +22 -0
- package/dist/questionnaire.d.ts.map +1 -0
- package/dist/questionnaire.mjs +4 -0
- package/dist/questionnaire.test.d.ts +2 -0
- package/dist/questionnaire.test.d.ts.map +1 -0
- package/dist/radio-group-Bd3WbH5I.js +1 -0
- package/dist/radio-group-TRiAhMZB.mjs +266 -0
- package/dist/radio-group.cjs +1 -1
- package/dist/radio-group.d.ts +2 -2
- package/dist/radio-group.d.ts.map +1 -1
- package/dist/radio-group.mjs +1 -1
- package/dist/resizable-Cq60hEWB.js +1 -0
- package/dist/resizable-Qc8cVUKd.mjs +2857 -0
- package/dist/resizable.cjs +1 -1
- package/dist/resizable.d.ts +3 -3
- package/dist/resizable.d.ts.map +1 -1
- package/dist/resizable.mjs +1 -1
- package/dist/scroll-area-D6MiNHnJ.mjs +564 -0
- package/dist/scroll-area-DFUdJeSZ.js +1 -0
- package/dist/scroll-area.cjs +1 -1
- package/dist/scroll-area.d.ts +3 -3
- package/dist/scroll-area.d.ts.map +1 -1
- package/dist/scroll-area.mjs +1 -1
- package/dist/scroll-to-top.cjs +1 -1
- package/dist/scroll-to-top.d.ts +1 -1
- package/dist/scroll-to-top.d.ts.map +1 -1
- package/dist/scroll-to-top.mjs +18 -16
- package/dist/search.cjs +1 -1
- package/dist/search.d.ts +1 -1
- package/dist/search.d.ts.map +1 -1
- package/dist/search.mjs +17 -17
- package/dist/select-BFJUmjvX.mjs +830 -0
- package/dist/select-iQFoKU1s.js +1 -0
- package/dist/select.cjs +1 -1
- package/dist/select.d.ts +11 -11
- package/dist/select.d.ts.map +1 -1
- package/dist/select.mjs +1 -1
- package/dist/separator-2kr96SyF.mjs +40 -0
- package/dist/separator-Bo49G2aj.js +1 -0
- package/dist/separator.cjs +1 -1
- package/dist/separator.d.ts +2 -2
- package/dist/separator.d.ts.map +1 -1
- package/dist/separator.mjs +1 -1
- package/dist/sheet.cjs +1 -1
- package/dist/sheet.d.ts +9 -9
- package/dist/sheet.d.ts.map +1 -1
- package/dist/sheet.mjs +23 -23
- package/dist/sidebar-C6O8hLkz.js +1 -0
- package/dist/{sidebar-B-sWccYh.mjs → sidebar-DM9ee9wf.mjs} +66 -66
- package/dist/sidebar.cjs +1 -1
- package/dist/sidebar.d.ts +24 -24
- package/dist/sidebar.d.ts.map +1 -1
- package/dist/sidebar.mjs +1 -1
- package/dist/skeleton.cjs +1 -1
- package/dist/skeleton.d.ts +1 -1
- package/dist/skeleton.d.ts.map +1 -1
- package/dist/skeleton.mjs +1 -1
- package/dist/slider-CagVxozY.js +1 -0
- package/dist/slider-CdTCoQu1.mjs +485 -0
- package/dist/slider.cjs +1 -1
- package/dist/slider.d.ts +2 -2
- package/dist/slider.d.ts.map +1 -1
- package/dist/slider.mjs +1 -1
- package/dist/sonner.cjs +1 -1
- package/dist/sonner.d.ts +2 -4
- package/dist/sonner.d.ts.map +1 -1
- package/dist/sonner.mjs +8 -8
- package/dist/spinner.cjs +1 -1
- package/dist/spinner.d.ts +2 -1
- package/dist/spinner.d.ts.map +1 -1
- package/dist/spinner.mjs +12 -7
- package/dist/support-fab.cjs +1 -1
- package/dist/support-fab.d.ts +1 -1
- package/dist/support-fab.d.ts.map +1 -1
- package/dist/support-fab.mjs +22 -22
- package/dist/switch-CoeAC1Wk.js +1 -0
- package/dist/switch-zUBdj7jK.mjs +174 -0
- package/dist/switch.cjs +1 -1
- package/dist/switch.d.ts +2 -2
- package/dist/switch.d.ts.map +1 -1
- package/dist/switch.mjs +1 -1
- package/dist/table-of-contents.cjs +1 -1
- package/dist/table-of-contents.d.ts +9 -13
- package/dist/table-of-contents.d.ts.map +1 -1
- package/dist/table-of-contents.mjs +3 -2
- package/dist/table.cjs +1 -1
- package/dist/table.d.ts +8 -8
- package/dist/table.d.ts.map +1 -1
- package/dist/table.mjs +1 -1
- package/dist/tabs-DaE9pEbo.mjs +160 -0
- package/dist/tabs-TMhXe20x.js +1 -0
- package/dist/tabs.cjs +1 -1
- package/dist/tabs.d.ts +5 -5
- package/dist/tabs.d.ts.map +1 -1
- package/dist/tabs.mjs +1 -1
- package/dist/text.cjs +1 -1
- package/dist/text.d.ts +1 -1
- package/dist/text.d.ts.map +1 -1
- package/dist/text.mjs +3 -3
- package/dist/textarea.cjs +1 -1
- package/dist/textarea.d.ts +1 -1
- package/dist/textarea.d.ts.map +1 -1
- package/dist/textarea.mjs +1 -1
- package/dist/theme-provider.d.ts +1 -1
- package/dist/theme-provider.d.ts.map +1 -1
- package/dist/theme-toggle-3RStptYf.mjs +73 -0
- package/dist/theme-toggle-DKh8WFLT.js +1 -0
- package/dist/theme-toggle.cjs +1 -1
- package/dist/theme-toggle.d.ts +1 -1
- package/dist/theme-toggle.d.ts.map +1 -1
- package/dist/theme-toggle.mjs +1 -1
- package/dist/toast-B0S3F09s.js +1 -0
- package/dist/toast-D0Yb-K84.mjs +445 -0
- package/dist/toast.cjs +1 -1
- package/dist/toast.d.ts +1 -1
- package/dist/toast.d.ts.map +1 -1
- package/dist/toast.mjs +1 -1
- package/dist/{toaster-DfDb2-aI.js → toaster-CX9im8R_.js} +1 -1
- package/dist/{toaster-Czhz-ktg.mjs → toaster-gT2b7mfE.mjs} +1 -1
- package/dist/toaster.cjs +1 -1
- package/dist/toaster.d.ts +1 -1
- package/dist/toaster.d.ts.map +1 -1
- package/dist/toaster.mjs +1 -1
- package/dist/toggle-B0hXPsi7.js +1 -0
- package/dist/toggle-BAeKd2N0.mjs +59 -0
- package/dist/toggle-group-CEKhUozD.mjs +167 -0
- package/dist/toggle-group-htyug3G7.js +1 -0
- package/dist/toggle-group.cjs +1 -1
- package/dist/toggle-group.d.ts +3 -3
- package/dist/toggle-group.d.ts.map +1 -1
- package/dist/toggle-group.mjs +1 -1
- package/dist/toggle.cjs +1 -1
- package/dist/toggle.d.ts +2 -2
- package/dist/toggle.d.ts.map +1 -1
- package/dist/toggle.mjs +1 -1
- package/dist/tooltip-BZazhXDZ.js +1 -0
- package/dist/tooltip-R_nK_Qh5.mjs +390 -0
- package/dist/tooltip.cjs +1 -1
- package/dist/tooltip.d.ts +5 -5
- package/dist/tooltip.d.ts.map +1 -1
- package/dist/tooltip.mjs +1 -1
- package/package.json +18 -16
- package/src/__contracts.ts +438 -278
- package/src/accordion.tsx +4 -6
- package/src/alert-dialog.tsx +6 -7
- package/src/alert.tsx +5 -7
- package/src/aspect-ratio.tsx +1 -2
- package/src/attachment.tsx +202 -0
- package/src/avatar.tsx +1 -2
- package/src/badge.tsx +2 -3
- package/src/breadcrumb.tsx +4 -8
- package/src/bubble.tsx +115 -0
- package/src/button-group.tsx +7 -8
- package/src/button.tsx +7 -9
- package/src/calendar.tsx +14 -14
- package/src/card.tsx +6 -7
- package/src/carousel.tsx +16 -17
- package/src/chart.tsx +1 -4
- package/src/checkbox.tsx +4 -6
- package/src/collapsible.tsx +1 -2
- package/src/combobox.tsx +8 -8
- package/src/command.tsx +8 -9
- package/src/context-menu.tsx +10 -12
- package/src/dialog.tsx +6 -7
- package/src/direction.tsx +1 -2
- package/src/drawer.tsx +3 -5
- package/src/dropdown-menu.tsx +10 -12
- package/src/empty.tsx +3 -5
- package/src/field.tsx +10 -11
- package/src/form.tsx +8 -8
- package/src/hooks/use-mobile.ts +1 -1
- package/src/hover-card.tsx +3 -5
- package/src/index.ts +54 -0
- package/src/input-group.tsx +14 -22
- package/src/input-otp.tsx +5 -6
- package/src/input.tsx +2 -4
- package/src/item.tsx +11 -12
- package/src/kbd.tsx +2 -2
- package/src/label.tsx +2 -4
- package/src/marker.tsx +61 -0
- package/src/menubar.tsx +11 -13
- package/src/message-scroller.tsx +133 -0
- package/src/message.tsx +85 -0
- package/src/native-select.tsx +2 -3
- package/src/navigation-menu.tsx +8 -10
- package/src/pagination.tsx +11 -10
- package/src/popover.tsx +3 -5
- package/src/progress.tsx +2 -4
- package/src/questionnaire.tsx +333 -0
- package/src/radio-group.tsx +2 -3
- package/src/resizable.tsx +1 -4
- package/src/scroll-area.tsx +3 -5
- package/src/scroll-to-top.tsx +7 -2
- package/src/search.tsx +2 -1
- package/src/select.tsx +8 -10
- package/src/separator.tsx +4 -6
- package/src/setupTests.ts +9 -9
- package/src/sheet.tsx +6 -7
- package/src/sidebar.tsx +17 -17
- package/src/skeleton.tsx +1 -2
- package/src/slider.tsx +5 -7
- package/src/sonner.tsx +0 -5
- package/src/spinner.tsx +14 -5
- package/src/support-fab.tsx +5 -1
- package/src/switch.tsx +4 -6
- package/src/table-of-contents.tsx +15 -13
- package/src/table.tsx +2 -4
- package/src/tabs.tsx +9 -11
- package/src/text.tsx +4 -4
- package/src/textarea.tsx +2 -4
- package/src/theme-provider.tsx +1 -1
- package/src/theme-toggle.tsx +26 -23
- package/src/toast.tsx +3 -4
- package/src/toaster.tsx +2 -1
- package/src/toggle-group.tsx +5 -6
- package/src/toggle.tsx +5 -7
- package/src/tooltip.tsx +3 -5
- package/dist/accordion-Dd8Hrexd.mjs +0 -244
- package/dist/accordion-DdSOiVyo.js +0 -1
- package/dist/alert-dialog-B7zX3gJX.js +0 -7
- package/dist/alert-dialog-BQoG5g_w.mjs +0 -213
- package/dist/aspect-ratio-QD1ZXP2B.js +0 -1
- package/dist/avatar-C4onD8-4.mjs +0 -127
- package/dist/avatar-ki_M47qG.js +0 -1
- package/dist/calendar-D9sapvfY.js +0 -1
- package/dist/carousel-6oFHLN7R.js +0 -1
- package/dist/checkbox-BLgY82mB.js +0 -1
- package/dist/checkbox-Bts_zfqd.mjs +0 -173
- package/dist/combobox-6qNx9Wbb.js +0 -4
- package/dist/combobox-yDMqxM_J.mjs +0 -5522
- package/dist/command-C6wJ5giF.mjs +0 -576
- package/dist/command-DCrPL1iW.js +0 -1
- package/dist/context-menu-CydUpD4W.mjs +0 -349
- package/dist/context-menu-DQ7XuuG5.js +0 -1
- package/dist/dist-1C8JOpVg.js +0 -1
- package/dist/dist-B1OcuinL.mjs +0 -558
- package/dist/dist-BGZDG175.mjs +0 -199
- package/dist/dist-BPBwSSyk.mjs +0 -8
- package/dist/dist-BPX1UGAz2.js +0 -1
- package/dist/dist-BRsDdVlJ.js +0 -1
- package/dist/dist-BWwCr-xN.mjs +0 -118
- package/dist/dist-BYdcKuDi.mjs +0 -16
- package/dist/dist-BlB11V_z.mjs +0 -27
- package/dist/dist-Bm8Cuttq.mjs +0 -76
- package/dist/dist-Byhx2fDJ.js +0 -1
- package/dist/dist-CCXBcfM3.js +0 -1
- package/dist/dist-CCokLFyA.mjs +0 -10
- package/dist/dist-CDU9vno-.mjs +0 -18
- package/dist/dist-CEJNUZGZ.js +0 -1
- package/dist/dist-CJolxugc.js +0 -1
- package/dist/dist-CQhWBhaI.mjs +0 -91
- package/dist/dist-CRLbUj9C.js +0 -1
- package/dist/dist-CSkpam6a.js +0 -1
- package/dist/dist-CWElW7UD.js +0 -1
- package/dist/dist-CXbzwSnE.js +0 -1
- package/dist/dist-CYj6O95k.mjs +0 -220
- package/dist/dist-C_45sBzc2.js +0 -1
- package/dist/dist-Cb7OVHcJ.js +0 -1
- package/dist/dist-Ccv5O-Vw.js +0 -1
- package/dist/dist-ChuP-5Gb.js +0 -1
- package/dist/dist-CiM892Rg.js +0 -1
- package/dist/dist-CuMQq0hV.js +0 -1
- package/dist/dist-DGzGsPqo2.mjs +0 -6
- package/dist/dist-DMnXk8Uo.js +0 -1
- package/dist/dist-DPBTfUqI.mjs +0 -96
- package/dist/dist-DR0lXVFG.js +0 -1
- package/dist/dist-Da7BU5sd.js +0 -5
- package/dist/dist-Df2ez-DA.mjs +0 -12
- package/dist/dist-DuTFGM_g.mjs +0 -45
- package/dist/dist-DynSBUGq.js +0 -1
- package/dist/dist-Dz3LbuDd.mjs +0 -60
- package/dist/dist-GhACpuJb2.mjs +0 -73
- package/dist/dist-N3JLy7yk.mjs +0 -29
- package/dist/dist-o4zlRoDG.js +0 -1
- package/dist/dist-rGeQfsgN.mjs +0 -66
- package/dist/dist-tvb2Wafb.mjs +0 -153
- package/dist/dist-xgVOvcNx.mjs +0 -11
- package/dist/dropdown-menu-BoJvZ3Fj.js +0 -1
- package/dist/es2015-BhmbVcui.mjs +0 -701
- package/dist/es2015-D22cM8Q_.js +0 -41
- package/dist/floating-ui.react-dom-DpCJEf_x.js +0 -1
- package/dist/hover-card-CJ-ibpbC.mjs +0 -187
- package/dist/hover-card-CK5SjVLL.js +0 -1
- package/dist/input-otp-BH_9dVhh.mjs +0 -391
- package/dist/input-otp-BibboKMt.js +0 -20
- package/dist/label-BXMSoyyu.js +0 -1
- package/dist/label-C8GNfPU0.mjs +0 -25
- package/dist/menubar-DPxokWFI.js +0 -1
- package/dist/navigation-menu-2yE2MUu-.js +0 -1
- package/dist/navigation-menu-N8gkxEXE.mjs +0 -628
- package/dist/popover-D1AO-E8p.js +0 -1
- package/dist/popover-wQACF3ut.mjs +0 -245
- package/dist/progress-DPWSEWa5.mjs +0 -86
- package/dist/progress-ShXZwOfj.js +0 -6
- package/dist/radio-group-CQbZCQmj.mjs +0 -199
- package/dist/radio-group-DAEi5vW_.js +0 -1
- package/dist/resizable-Cv-mKMKP.js +0 -1
- package/dist/resizable-DJSE3e5L.mjs +0 -1561
- package/dist/scroll-area-8QcqkHnC.mjs +0 -530
- package/dist/scroll-area-Cqqinhxf.js +0 -1
- package/dist/select-DdUveoSA.js +0 -1
- package/dist/select-yoeH35x2.mjs +0 -778
- package/dist/separator-BU1ea5gl.mjs +0 -35
- package/dist/separator-DBjErwHf.js +0 -1
- package/dist/shim-B5sEfNEJ.js +0 -1
- package/dist/shim-DX33EwUw.mjs +0 -91
- package/dist/sidebar-DIW-1cin.js +0 -1
- package/dist/slider-CCPXejUF.mjs +0 -388
- package/dist/slider-w05gD_Ix.js +0 -1
- package/dist/switch-CDBqsWQa.mjs +0 -112
- package/dist/switch-X2WBJsUu.js +0 -1
- package/dist/tabs-DzvgrVzk.js +0 -1
- package/dist/tabs-KDeHjVQU.mjs +0 -160
- package/dist/theme-toggle-C2Y4bIM3.js +0 -1
- package/dist/theme-toggle-clE-HpSS.mjs +0 -64
- package/dist/toast-1keyrzem.js +0 -1
- package/dist/toast-DVI6jPq5.mjs +0 -428
- package/dist/toggle-BGkq5XDM.js +0 -1
- package/dist/toggle-BfIIdlA6.mjs +0 -58
- package/dist/toggle-group-CbqgoPFU.mjs +0 -167
- package/dist/toggle-group-D7hR4BT2.js +0 -1
- package/dist/tooltip-CAIbshMk.js +0 -1
- package/dist/tooltip-D_o8Z-Ya.mjs +0 -380
|
@@ -0,0 +1,445 @@
|
|
|
1
|
+
import { t as e } from "./utils-A_oVsYw5.mjs";
|
|
2
|
+
import { a as t } from "./dist-Dq-h6VAy.mjs";
|
|
3
|
+
import { n, t as r } from "./dist-BEbV0Hal.mjs";
|
|
4
|
+
import { n as i } from "./dist-B057I8ju.mjs";
|
|
5
|
+
import { t as a } from "./dist-CPAF050o.mjs";
|
|
6
|
+
import { t as o } from "./dist-GazS1kfR.mjs";
|
|
7
|
+
import { t as s } from "./dist-OqDzLHTa.mjs";
|
|
8
|
+
import { t as c } from "./dist-BB78QQyQ.mjs";
|
|
9
|
+
import { t as l } from "./dist-Bvfb4y_L.mjs";
|
|
10
|
+
import { t as u } from "./dist-CpKLY_uZ.mjs";
|
|
11
|
+
import { t as d } from "./dist-BPL7gUpg.mjs";
|
|
12
|
+
import { n as f, t as p } from "./dist-s7ibhASj.mjs";
|
|
13
|
+
import { t as m } from "./dist-DI1vapnL.mjs";
|
|
14
|
+
import { X as h } from "lucide-react";
|
|
15
|
+
import * as g from "react";
|
|
16
|
+
import * as _ from "react-dom";
|
|
17
|
+
import { Fragment as v, jsx as y, jsxs as b } from "react/jsx-runtime";
|
|
18
|
+
import { cva as x } from "class-variance-authority";
|
|
19
|
+
//#region ../../node_modules/.bun/@radix-ui+react-toast@1.3.1+b146eb580f4286be/node_modules/@radix-ui/react-toast/dist/index.mjs
|
|
20
|
+
var S = Object.defineProperty, C = (e, t) => S(e, "name", {
|
|
21
|
+
value: t,
|
|
22
|
+
configurable: !0
|
|
23
|
+
}), w = g.startTransition || (() => void 0), T = "ToastProvider", [E, D, O] = s("Toast"), k = {
|
|
24
|
+
Up: "up",
|
|
25
|
+
Down: "down",
|
|
26
|
+
Left: "left",
|
|
27
|
+
Right: "right"
|
|
28
|
+
}, A = {
|
|
29
|
+
Foreground: "foreground",
|
|
30
|
+
Background: "background"
|
|
31
|
+
}, [j, ee] = a("Toast", [O]), [M, N] = j(T);
|
|
32
|
+
function P(e) {
|
|
33
|
+
typeof w == "function" ? w(e) : e();
|
|
34
|
+
}
|
|
35
|
+
C(P, "scheduleUpdate");
|
|
36
|
+
var F = /* @__PURE__ */ C((e) => {
|
|
37
|
+
let { __scopeToast: t, label: n = "Notification", duration: r = 5e3, swipeDirection: i = k.Right, swipeThreshold: a = 50, announcerContainer: o, children: s } = e, [c, l] = g.useState(null), [u, d] = g.useState(0), f = g.useRef(!1), p = g.useCallback((e) => {
|
|
38
|
+
P(() => l(e));
|
|
39
|
+
}, []), m = g.useCallback(() => {
|
|
40
|
+
P(() => d((e) => e + 1));
|
|
41
|
+
}, []), h = g.useCallback(() => {
|
|
42
|
+
P(() => d((e) => e - 1));
|
|
43
|
+
}, []);
|
|
44
|
+
return n.trim() || console.error(`Invalid prop \`label\` supplied to \`${T}\`. Expected non-empty \`string\`.`), /* @__PURE__ */ y(E.Provider, {
|
|
45
|
+
scope: t,
|
|
46
|
+
children: /* @__PURE__ */ y(M, {
|
|
47
|
+
scope: t,
|
|
48
|
+
label: n,
|
|
49
|
+
duration: r,
|
|
50
|
+
swipeDirection: i,
|
|
51
|
+
swipeThreshold: a,
|
|
52
|
+
toastCount: u,
|
|
53
|
+
viewport: c,
|
|
54
|
+
onViewportChange: p,
|
|
55
|
+
onToastAdd: m,
|
|
56
|
+
onToastRemove: h,
|
|
57
|
+
isClosePausedRef: f,
|
|
58
|
+
announcerContainer: o,
|
|
59
|
+
children: s
|
|
60
|
+
})
|
|
61
|
+
});
|
|
62
|
+
}, "ToastProvider"), I = "ToastViewport", L = ["F8"], R = "toast.viewportPause", z = "toast.viewportResume", B = /* @__PURE__ */ g.forwardRef(/* @__PURE__ */ C(function(e, n) {
|
|
63
|
+
let { __scopeToast: i, hotkey: a = L, label: o = "Notifications ({hotkey})", ...s } = e, c = N(I, i), l = D(i), u = g.useRef(null), d = g.useRef(null), p = g.useRef(null), m = g.useRef(null), h = t(n, m, c.onViewportChange), _ = a.join("+").replace(/Key/g, "").replace(/Digit/g, ""), v = c.toastCount > 0;
|
|
64
|
+
g.useEffect(() => {
|
|
65
|
+
let e = /* @__PURE__ */ C((e) => {
|
|
66
|
+
a.length !== 0 && a.every((t) => e[t] || e.code === t) && m.current?.focus();
|
|
67
|
+
}, "handleKeyDown");
|
|
68
|
+
return document.addEventListener("keydown", e), () => document.removeEventListener("keydown", e);
|
|
69
|
+
}, [a]), g.useEffect(() => {
|
|
70
|
+
let e = u.current, t = m.current;
|
|
71
|
+
if (v && e && t) {
|
|
72
|
+
let n = /* @__PURE__ */ C(() => {
|
|
73
|
+
if (!c.isClosePausedRef.current) {
|
|
74
|
+
let e = new CustomEvent(R);
|
|
75
|
+
t.dispatchEvent(e), c.isClosePausedRef.current = !0;
|
|
76
|
+
}
|
|
77
|
+
}, "handlePause"), r = /* @__PURE__ */ C(() => {
|
|
78
|
+
if (c.isClosePausedRef.current) {
|
|
79
|
+
let e = new CustomEvent(z);
|
|
80
|
+
t.dispatchEvent(e), c.isClosePausedRef.current = !1;
|
|
81
|
+
}
|
|
82
|
+
}, "handleResume"), i = /* @__PURE__ */ C((t) => {
|
|
83
|
+
e.contains(t.relatedTarget) || r();
|
|
84
|
+
}, "handleFocusOutResume"), a = /* @__PURE__ */ C(() => {
|
|
85
|
+
e.contains(document.activeElement) || r();
|
|
86
|
+
}, "handlePointerLeaveResume");
|
|
87
|
+
return e.addEventListener("focusin", n), e.addEventListener("focusout", i), e.addEventListener("pointermove", n), e.addEventListener("pointerleave", a), window.addEventListener("blur", n), window.addEventListener("focus", r), () => {
|
|
88
|
+
e.removeEventListener("focusin", n), e.removeEventListener("focusout", i), e.removeEventListener("pointermove", n), e.removeEventListener("pointerleave", a), window.removeEventListener("blur", n), window.removeEventListener("focus", r);
|
|
89
|
+
};
|
|
90
|
+
}
|
|
91
|
+
}, [v, c.isClosePausedRef]);
|
|
92
|
+
let x = g.useCallback(({ tabbingDirection: e }) => {
|
|
93
|
+
let t = l().map((t) => {
|
|
94
|
+
let n = t.ref.current, r = [n, ...pe(n)];
|
|
95
|
+
return e === "forwards" ? r : r.reverse();
|
|
96
|
+
});
|
|
97
|
+
return (e === "forwards" ? t.reverse() : t).flat();
|
|
98
|
+
}, [l]);
|
|
99
|
+
return g.useEffect(() => {
|
|
100
|
+
let e = m.current;
|
|
101
|
+
if (e) {
|
|
102
|
+
let t = /* @__PURE__ */ C((t) => {
|
|
103
|
+
let n = t.altKey || t.ctrlKey || t.metaKey;
|
|
104
|
+
if (t.key === "Tab" && !n) {
|
|
105
|
+
let n = document.activeElement, r = t.shiftKey;
|
|
106
|
+
if (t.target === e && r) {
|
|
107
|
+
d.current?.focus();
|
|
108
|
+
return;
|
|
109
|
+
}
|
|
110
|
+
let i = x({ tabbingDirection: r ? "backwards" : "forwards" }), a = i.findIndex((e) => e === n);
|
|
111
|
+
$(i.slice(a + 1)) ? t.preventDefault() : r ? d.current?.focus() : p.current?.focus();
|
|
112
|
+
}
|
|
113
|
+
}, "handleKeyDown");
|
|
114
|
+
return e.addEventListener("keydown", t), () => e.removeEventListener("keydown", t);
|
|
115
|
+
}
|
|
116
|
+
}, [l, x]), /* @__PURE__ */ b(f, {
|
|
117
|
+
ref: u,
|
|
118
|
+
role: "region",
|
|
119
|
+
"aria-label": o.replace("{hotkey}", _),
|
|
120
|
+
tabIndex: -1,
|
|
121
|
+
style: { pointerEvents: v ? void 0 : "none" },
|
|
122
|
+
children: [
|
|
123
|
+
v && /* @__PURE__ */ y(H, {
|
|
124
|
+
ref: d,
|
|
125
|
+
onFocusFromOutsideViewport: () => {
|
|
126
|
+
$(x({ tabbingDirection: "forwards" }));
|
|
127
|
+
}
|
|
128
|
+
}),
|
|
129
|
+
/* @__PURE__ */ y(E.Slot, {
|
|
130
|
+
scope: i,
|
|
131
|
+
children: /* @__PURE__ */ y(r.ol, {
|
|
132
|
+
tabIndex: -1,
|
|
133
|
+
...s,
|
|
134
|
+
ref: h
|
|
135
|
+
})
|
|
136
|
+
}),
|
|
137
|
+
v && /* @__PURE__ */ y(H, {
|
|
138
|
+
ref: p,
|
|
139
|
+
onFocusFromOutsideViewport: () => {
|
|
140
|
+
$(x({ tabbingDirection: "backwards" }));
|
|
141
|
+
}
|
|
142
|
+
})
|
|
143
|
+
]
|
|
144
|
+
});
|
|
145
|
+
}, "ToastViewport")), V = "ToastFocusProxy", H = /* @__PURE__ */ g.forwardRef(/* @__PURE__ */ C(function(e, t) {
|
|
146
|
+
let { __scopeToast: n, onFocusFromOutsideViewport: r, ...a } = e, o = N(V, n);
|
|
147
|
+
return /* @__PURE__ */ y(i, {
|
|
148
|
+
tabIndex: 0,
|
|
149
|
+
...a,
|
|
150
|
+
ref: t,
|
|
151
|
+
style: { position: "fixed" },
|
|
152
|
+
onFocus: (e) => {
|
|
153
|
+
let t = e.relatedTarget;
|
|
154
|
+
o.viewport?.contains(t) || r();
|
|
155
|
+
}
|
|
156
|
+
});
|
|
157
|
+
}, "ToastFocusProxy")), U = "Toast", te = "toast.swipeStart", ne = "toast.swipeMove", re = "toast.swipeCancel", ie = "toast.swipeEnd", W = /* @__PURE__ */ g.forwardRef(/* @__PURE__ */ C(function(e, t) {
|
|
158
|
+
let { forceMount: n, open: r, defaultOpen: i, onOpenChange: a, ...o } = e, [s, f] = l({
|
|
159
|
+
prop: r,
|
|
160
|
+
defaultProp: i ?? !0,
|
|
161
|
+
onChange: a,
|
|
162
|
+
caller: U
|
|
163
|
+
});
|
|
164
|
+
return /* @__PURE__ */ y(u, {
|
|
165
|
+
present: n || s,
|
|
166
|
+
children: /* @__PURE__ */ y(K, {
|
|
167
|
+
open: s,
|
|
168
|
+
...o,
|
|
169
|
+
ref: t,
|
|
170
|
+
onClose: () => f(!1),
|
|
171
|
+
onPause: d(e.onPause),
|
|
172
|
+
onResume: d(e.onResume),
|
|
173
|
+
onSwipeStart: c(e.onSwipeStart, (e) => {
|
|
174
|
+
e.currentTarget.setAttribute("data-swipe", "start");
|
|
175
|
+
}),
|
|
176
|
+
onSwipeMove: c(e.onSwipeMove, (e) => {
|
|
177
|
+
let { x: t, y: n } = e.detail.delta;
|
|
178
|
+
e.currentTarget.setAttribute("data-swipe", "move"), e.currentTarget.style.setProperty("--radix-toast-swipe-move-x", `${t}px`), e.currentTarget.style.setProperty("--radix-toast-swipe-move-y", `${n}px`);
|
|
179
|
+
}),
|
|
180
|
+
onSwipeCancel: c(e.onSwipeCancel, (e) => {
|
|
181
|
+
e.currentTarget.setAttribute("data-swipe", "cancel"), e.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"), e.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"), e.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"), e.currentTarget.style.removeProperty("--radix-toast-swipe-end-y");
|
|
182
|
+
}),
|
|
183
|
+
onSwipeEnd: c(e.onSwipeEnd, (e) => {
|
|
184
|
+
let { x: t, y: n } = e.detail.delta;
|
|
185
|
+
e.currentTarget.setAttribute("data-swipe", "end"), e.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"), e.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"), e.currentTarget.style.setProperty("--radix-toast-swipe-end-x", `${t}px`), e.currentTarget.style.setProperty("--radix-toast-swipe-end-y", `${n}px`), f(!1);
|
|
186
|
+
})
|
|
187
|
+
})
|
|
188
|
+
});
|
|
189
|
+
}, "Toast")), [ae, G] = j(U, { onClose() {} }), K = /* @__PURE__ */ g.forwardRef(/* @__PURE__ */ C(function(e, n) {
|
|
190
|
+
let { __scopeToast: i, type: a = A.Foreground, duration: o, open: s, onClose: l, onEscapeKeyDown: u, onPause: f, onResume: m, onSwipeStart: h, onSwipeMove: x, onSwipeCancel: S, onSwipeEnd: w, ...T } = e, O = N(U, i), k = D(i), [j, ee] = g.useState(null), M = t(n, ee), P = g.useRef(null), F = g.useRef(null), I = o || O.duration, L = g.useRef(0), B = g.useRef(I), V = g.useRef(0), { onToastAdd: H, onToastRemove: W } = O, G = d(() => {
|
|
191
|
+
j?.contains(document.activeElement) && O.viewport?.focus(), l();
|
|
192
|
+
}), K = g.useCallback((e) => {
|
|
193
|
+
!e || e === Infinity || (window.clearTimeout(V.current), L.current = (/* @__PURE__ */ new Date()).getTime(), V.current = window.setTimeout(G, e));
|
|
194
|
+
}, [G]);
|
|
195
|
+
g.useEffect(() => {
|
|
196
|
+
let e = O.viewport;
|
|
197
|
+
if (e) {
|
|
198
|
+
let t = /* @__PURE__ */ C(() => {
|
|
199
|
+
K(B.current), m?.();
|
|
200
|
+
}, "handleResume"), n = /* @__PURE__ */ C(() => {
|
|
201
|
+
let e = (/* @__PURE__ */ new Date()).getTime() - L.current;
|
|
202
|
+
B.current -= e, window.clearTimeout(V.current), f?.();
|
|
203
|
+
}, "handlePause");
|
|
204
|
+
return e.addEventListener(R, n), e.addEventListener(z, t), () => {
|
|
205
|
+
e.removeEventListener(R, n), e.removeEventListener(z, t);
|
|
206
|
+
};
|
|
207
|
+
}
|
|
208
|
+
}, [
|
|
209
|
+
O.viewport,
|
|
210
|
+
I,
|
|
211
|
+
f,
|
|
212
|
+
m,
|
|
213
|
+
K
|
|
214
|
+
]), g.useEffect(() => {
|
|
215
|
+
B.current = I, s && !O.isClosePausedRef.current && K(I);
|
|
216
|
+
}, [
|
|
217
|
+
s,
|
|
218
|
+
I,
|
|
219
|
+
O.isClosePausedRef,
|
|
220
|
+
K
|
|
221
|
+
]), g.useEffect(() => () => {
|
|
222
|
+
window.clearTimeout(V.current);
|
|
223
|
+
}, []), g.useEffect(() => (H(), () => W()), [H, W]);
|
|
224
|
+
let q = g.useMemo(() => j ? Z(j) : null, [j]);
|
|
225
|
+
return O.viewport ? /* @__PURE__ */ b(v, { children: [q && /* @__PURE__ */ y(oe, {
|
|
226
|
+
__scopeToast: i,
|
|
227
|
+
role: "status",
|
|
228
|
+
"aria-live": a === A.Foreground ? "assertive" : "polite",
|
|
229
|
+
children: q
|
|
230
|
+
}), /* @__PURE__ */ y(ae, {
|
|
231
|
+
scope: i,
|
|
232
|
+
onClose: G,
|
|
233
|
+
children: _.createPortal(/* @__PURE__ */ y(E.ItemSlot, {
|
|
234
|
+
scope: i,
|
|
235
|
+
children: /* @__PURE__ */ y(p, {
|
|
236
|
+
asChild: !0,
|
|
237
|
+
onEscapeKeyDown: c(u, (e) => {
|
|
238
|
+
k().some((t) => t.ref.current?.contains(e.target)) || G();
|
|
239
|
+
}),
|
|
240
|
+
children: /* @__PURE__ */ y(r.li, {
|
|
241
|
+
tabIndex: 0,
|
|
242
|
+
"data-state": s ? "open" : "closed",
|
|
243
|
+
"data-swipe-direction": O.swipeDirection,
|
|
244
|
+
...T,
|
|
245
|
+
ref: M,
|
|
246
|
+
style: {
|
|
247
|
+
userSelect: "none",
|
|
248
|
+
touchAction: "none",
|
|
249
|
+
...e.style
|
|
250
|
+
},
|
|
251
|
+
onKeyDown: c(e.onKeyDown, (e) => {
|
|
252
|
+
e.key === "Escape" && (u?.(e.nativeEvent), e.nativeEvent.defaultPrevented || G());
|
|
253
|
+
}),
|
|
254
|
+
onPointerDown: c(e.onPointerDown, (e) => {
|
|
255
|
+
e.button === 0 && (P.current = {
|
|
256
|
+
x: e.clientX,
|
|
257
|
+
y: e.clientY
|
|
258
|
+
});
|
|
259
|
+
}),
|
|
260
|
+
onPointerMove: c(e.onPointerMove, (e) => {
|
|
261
|
+
if (!P.current) return;
|
|
262
|
+
let t = e.clientX - P.current.x, n = e.clientY - P.current.y, r = !!F.current, i = ["left", "right"].includes(O.swipeDirection), a = ["left", "up"].includes(O.swipeDirection) ? Math.min : Math.max, o = i ? a(0, t) : 0, s = i ? 0 : a(0, n), c = e.pointerType === "touch" ? 10 : 2, l = {
|
|
263
|
+
x: o,
|
|
264
|
+
y: s
|
|
265
|
+
}, u = {
|
|
266
|
+
originalEvent: e,
|
|
267
|
+
delta: l
|
|
268
|
+
};
|
|
269
|
+
r ? (F.current = l, Q(ne, x, u, { discrete: !1 })) : ue(l, O.swipeDirection, c) ? (F.current = l, Q(te, h, u, { discrete: !1 }), e.target.setPointerCapture(e.pointerId)) : (Math.abs(t) > c || Math.abs(n) > c) && (P.current = null);
|
|
270
|
+
}),
|
|
271
|
+
onPointerUp: c(e.onPointerUp, (e) => {
|
|
272
|
+
let t = F.current, n = e.target;
|
|
273
|
+
if (n.hasPointerCapture(e.pointerId) && n.releasePointerCapture(e.pointerId), F.current = null, P.current = null, t) {
|
|
274
|
+
let n = e.currentTarget, r = {
|
|
275
|
+
originalEvent: e,
|
|
276
|
+
delta: t
|
|
277
|
+
};
|
|
278
|
+
ue(t, O.swipeDirection, O.swipeThreshold) ? Q(ie, w, r, { discrete: !0 }) : Q(re, S, r, { discrete: !0 }), n.addEventListener("click", (e) => e.preventDefault(), { once: !0 });
|
|
279
|
+
}
|
|
280
|
+
})
|
|
281
|
+
})
|
|
282
|
+
})
|
|
283
|
+
}), O.viewport)
|
|
284
|
+
})] }) : null;
|
|
285
|
+
}, "ToastImpl")), oe = /* @__PURE__ */ C((e) => {
|
|
286
|
+
let { __scopeToast: t, children: n, ...r } = e, a = N(U, t), [o, s] = g.useState(!1), [c, l] = g.useState(!1);
|
|
287
|
+
return de(() => s(!0)), g.useEffect(() => {
|
|
288
|
+
let e = window.setTimeout(() => l(!0), 1e3);
|
|
289
|
+
return () => window.clearTimeout(e);
|
|
290
|
+
}, []), c ? null : /* @__PURE__ */ y(m, {
|
|
291
|
+
asChild: !0,
|
|
292
|
+
container: a.announcerContainer || void 0,
|
|
293
|
+
children: /* @__PURE__ */ y(i, {
|
|
294
|
+
...r,
|
|
295
|
+
children: o && /* @__PURE__ */ b(v, { children: [
|
|
296
|
+
a.label,
|
|
297
|
+
" ",
|
|
298
|
+
n
|
|
299
|
+
] })
|
|
300
|
+
})
|
|
301
|
+
});
|
|
302
|
+
}, "ToastAnnounce"), q = /* @__PURE__ */ g.forwardRef(/* @__PURE__ */ C(function(e, t) {
|
|
303
|
+
let { __scopeToast: n, ...i } = e;
|
|
304
|
+
return /* @__PURE__ */ y(r.div, {
|
|
305
|
+
...i,
|
|
306
|
+
ref: t
|
|
307
|
+
});
|
|
308
|
+
}, "ToastTitle")), J = /* @__PURE__ */ g.forwardRef(/* @__PURE__ */ C(function(e, t) {
|
|
309
|
+
let { __scopeToast: n, ...i } = e;
|
|
310
|
+
return /* @__PURE__ */ y(r.div, {
|
|
311
|
+
...i,
|
|
312
|
+
ref: t
|
|
313
|
+
});
|
|
314
|
+
}, "ToastDescription")), se = "ToastAction", Y = /* @__PURE__ */ g.forwardRef(/* @__PURE__ */ C(function(e, t) {
|
|
315
|
+
let { altText: n, ...r } = e;
|
|
316
|
+
return n.trim() ? /* @__PURE__ */ y(le, {
|
|
317
|
+
altText: n,
|
|
318
|
+
asChild: !0,
|
|
319
|
+
children: /* @__PURE__ */ y(X, {
|
|
320
|
+
...r,
|
|
321
|
+
ref: t
|
|
322
|
+
})
|
|
323
|
+
}) : (console.error(`Invalid prop \`altText\` supplied to \`${se}\`. Expected non-empty \`string\`.`), null);
|
|
324
|
+
}, "ToastAction")), ce = "ToastClose", X = /* @__PURE__ */ g.forwardRef(/* @__PURE__ */ C(function(e, t) {
|
|
325
|
+
let { __scopeToast: n, ...i } = e, a = G(ce, n);
|
|
326
|
+
return /* @__PURE__ */ y(le, {
|
|
327
|
+
asChild: !0,
|
|
328
|
+
children: /* @__PURE__ */ y(r.button, {
|
|
329
|
+
type: "button",
|
|
330
|
+
...i,
|
|
331
|
+
ref: t,
|
|
332
|
+
onClick: c(e.onClick, a.onClose)
|
|
333
|
+
})
|
|
334
|
+
});
|
|
335
|
+
}, "ToastClose")), le = /* @__PURE__ */ g.forwardRef(/* @__PURE__ */ C(function(e, t) {
|
|
336
|
+
let { __scopeToast: n, altText: i, ...a } = e;
|
|
337
|
+
return /* @__PURE__ */ y(r.div, {
|
|
338
|
+
"data-radix-toast-announce-exclude": "",
|
|
339
|
+
"data-radix-toast-announce-alt": i || void 0,
|
|
340
|
+
...a,
|
|
341
|
+
ref: t
|
|
342
|
+
});
|
|
343
|
+
}, "ToastAnnounceExclude"));
|
|
344
|
+
function Z(e) {
|
|
345
|
+
let t = [];
|
|
346
|
+
return Array.from(e.childNodes).forEach((e) => {
|
|
347
|
+
if (e.nodeType === e.TEXT_NODE && e.textContent && t.push(e.textContent), fe(e)) {
|
|
348
|
+
let n = e.ariaHidden || e.hidden || e.style.display === "none", r = e.dataset.radixToastAnnounceExclude === "";
|
|
349
|
+
if (!n) if (r) {
|
|
350
|
+
let n = e.dataset.radixToastAnnounceAlt;
|
|
351
|
+
n && t.push(n);
|
|
352
|
+
} else t.push(...Z(e));
|
|
353
|
+
}
|
|
354
|
+
}), t;
|
|
355
|
+
}
|
|
356
|
+
C(Z, "getAnnounceTextContent");
|
|
357
|
+
function Q(e, t, r, { discrete: i }) {
|
|
358
|
+
let a = r.originalEvent.currentTarget, o = new CustomEvent(e, {
|
|
359
|
+
bubbles: !0,
|
|
360
|
+
cancelable: !0,
|
|
361
|
+
detail: r
|
|
362
|
+
});
|
|
363
|
+
t && a.addEventListener(e, t, { once: !0 }), i ? n(a, o) : a.dispatchEvent(o);
|
|
364
|
+
}
|
|
365
|
+
C(Q, "handleAndDispatchCustomEvent");
|
|
366
|
+
var ue = /* @__PURE__ */ C((e, t, n = 0) => {
|
|
367
|
+
let r = Math.abs(e.x), i = Math.abs(e.y), a = r > i;
|
|
368
|
+
return t === k.Left || t === k.Right ? a && r > n : !a && i > n;
|
|
369
|
+
}, "isDeltaInDirection");
|
|
370
|
+
function de(e = () => {}) {
|
|
371
|
+
let t = d(e);
|
|
372
|
+
o(() => {
|
|
373
|
+
let e = 0, n = 0;
|
|
374
|
+
return e = window.requestAnimationFrame(() => n = window.requestAnimationFrame(t)), () => {
|
|
375
|
+
window.cancelAnimationFrame(e), window.cancelAnimationFrame(n);
|
|
376
|
+
};
|
|
377
|
+
}, [t]);
|
|
378
|
+
}
|
|
379
|
+
C(de, "useNextFrame");
|
|
380
|
+
function fe(e) {
|
|
381
|
+
return e.nodeType === e.ELEMENT_NODE;
|
|
382
|
+
}
|
|
383
|
+
C(fe, "isHTMLElement");
|
|
384
|
+
function pe(e) {
|
|
385
|
+
let t = [], n = document.createTreeWalker(e, NodeFilter.SHOW_ELEMENT, { acceptNode: /* @__PURE__ */ C((e) => {
|
|
386
|
+
let t = e.tagName === "INPUT" && e.type === "hidden";
|
|
387
|
+
return e.disabled || e.hidden || t ? NodeFilter.FILTER_SKIP : e.tabIndex >= 0 ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_SKIP;
|
|
388
|
+
}, "acceptNode") });
|
|
389
|
+
for (; n.nextNode();) t.push(n.currentNode);
|
|
390
|
+
return t;
|
|
391
|
+
}
|
|
392
|
+
C(pe, "getTabbableCandidates");
|
|
393
|
+
function $(e) {
|
|
394
|
+
let t = document.activeElement;
|
|
395
|
+
return e.some((e) => e === t ? !0 : (e.focus(), document.activeElement !== t));
|
|
396
|
+
}
|
|
397
|
+
C($, "focusFirst");
|
|
398
|
+
//#endregion
|
|
399
|
+
//#region src/toast.tsx
|
|
400
|
+
var me = F, he = g.forwardRef(({ className: t, ...n }, r) => /* @__PURE__ */ y(B, {
|
|
401
|
+
ref: r,
|
|
402
|
+
className: e("fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4 sm:top-auto sm:right-0 sm:bottom-0 sm:flex-col md:max-w-[420px]", t),
|
|
403
|
+
...n
|
|
404
|
+
}));
|
|
405
|
+
he.displayName = B?.displayName || "ToastViewport";
|
|
406
|
+
var ge = x("group data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full pointer-events-auto relative flex w-full items-center justify-between space-x-2 overflow-hidden rounded-md border p-4 pr-6 shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none", {
|
|
407
|
+
variants: { variant: {
|
|
408
|
+
default: "bg-background text-foreground border",
|
|
409
|
+
destructive: "destructive group border-destructive bg-destructive text-destructive-foreground"
|
|
410
|
+
} },
|
|
411
|
+
defaultVariants: { variant: "default" }
|
|
412
|
+
}), _e = g.forwardRef(({ className: t, variant: n, ...r }, i) => /* @__PURE__ */ y(W, {
|
|
413
|
+
ref: i,
|
|
414
|
+
className: e(ge({ variant: n }), t),
|
|
415
|
+
...r
|
|
416
|
+
}));
|
|
417
|
+
_e.displayName = W?.displayName || "Toast";
|
|
418
|
+
var ve = g.forwardRef(({ className: t, ...n }, r) => /* @__PURE__ */ y(Y, {
|
|
419
|
+
ref: r,
|
|
420
|
+
className: e("hover:bg-secondary focus:ring-ring group-[.destructive]:border-muted/40 group-[.destructive]:hover:border-destructive/30 group-[.destructive]:hover:bg-destructive group-[.destructive]:hover:text-destructive-foreground group-[.destructive]:focus:ring-destructive inline-flex h-8 shrink-0 items-center justify-center rounded-md border bg-transparent px-3 text-sm font-medium transition-colors focus:ring-1 focus:outline-none disabled:pointer-events-none disabled:opacity-50", t),
|
|
421
|
+
...n
|
|
422
|
+
}));
|
|
423
|
+
ve.displayName = Y?.displayName || "ToastAction";
|
|
424
|
+
var ye = g.forwardRef(({ className: t, ...n }, r) => /* @__PURE__ */ y(X, {
|
|
425
|
+
ref: r,
|
|
426
|
+
className: e("text-foreground/50 hover:text-foreground absolute top-1 right-1 rounded-md p-1 opacity-0 transition-opacity group-hover:opacity-100 group-[.destructive]:text-red-300 group-[.destructive]:hover:text-red-50 focus:opacity-100 focus:ring-1 focus:outline-none group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600", t),
|
|
427
|
+
"toast-close": "",
|
|
428
|
+
...n,
|
|
429
|
+
children: /* @__PURE__ */ y(h, { className: "h-4 w-4" })
|
|
430
|
+
}));
|
|
431
|
+
ye.displayName = X?.displayName || "ToastClose";
|
|
432
|
+
var be = g.forwardRef(({ className: t, ...n }, r) => /* @__PURE__ */ y(q, {
|
|
433
|
+
ref: r,
|
|
434
|
+
className: e("text-sm font-semibold [&+div]:text-xs", t),
|
|
435
|
+
...n
|
|
436
|
+
}));
|
|
437
|
+
be.displayName = q?.displayName || "ToastTitle";
|
|
438
|
+
var xe = g.forwardRef(({ className: t, ...n }, r) => /* @__PURE__ */ y(J, {
|
|
439
|
+
ref: r,
|
|
440
|
+
className: e("text-sm opacity-90", t),
|
|
441
|
+
...n
|
|
442
|
+
}));
|
|
443
|
+
xe.displayName = J?.displayName || "ToastDescription";
|
|
444
|
+
//#endregion
|
|
445
|
+
export { me as a, xe as i, ve as n, be as o, ye as r, he as s, _e as t };
|
package/dist/toast.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";"use client";Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./toast-
|
|
1
|
+
"use client";"use client";Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./toast-B0S3F09s.js");exports.Toast=e.t,exports.ToastAction=e.n,exports.ToastClose=e.r,exports.ToastDescription=e.i,exports.ToastProvider=e.a,exports.ToastTitle=e.o,exports.ToastViewport=e.s;
|
package/dist/toast.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { VariantProps } from 'class-variance-authority';
|
|
2
1
|
import { ToastBaseProps } from '@gv-tech/ui-core';
|
|
2
|
+
import { VariantProps } from 'class-variance-authority';
|
|
3
3
|
import * as ToastPrimitives from '@radix-ui/react-toast';
|
|
4
4
|
import * as React from 'react';
|
|
5
5
|
declare const ToastProvider: React.FC<ToastPrimitives.ToastProviderProps>;
|
package/dist/toast.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"toast.d.ts","sourceRoot":"","sources":["../src/toast.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,eAAe,MAAM,uBAAuB,CAAC;AACzD,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAElE,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,
|
|
1
|
+
{"version":3,"file":"toast.d.ts","sourceRoot":"","sources":["../src/toast.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,KAAK,eAAe,MAAM,uBAAuB,CAAC;AACzD,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAElE,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,QAAA,MAAM,aAAa,8CAA2B,CAAC;AAE/C,QAAA,MAAM,aAAa,kKAYjB,CAAC;AAkBH,QAAA,MAAM,KAAK;;qHAKT,CAAC;AAGH,QAAA,MAAM,WAAW,kKAYf,CAAC;AAGH,QAAA,MAAM,UAAU,iKAed,CAAC;AAGH,QAAA,MAAM,UAAU,2JAKd,CAAC;AAGH,QAAA,MAAM,gBAAgB,iKAKpB,CAAC;AAGH,KAAK,UAAU,GAAG,KAAK,CAAC,wBAAwB,CAAC,OAAO,KAAK,CAAC,CAAC;AAE/D,KAAK,kBAAkB,GAAG,KAAK,CAAC,YAAY,CAAC,OAAO,WAAW,CAAC,CAAC;AAEjE,OAAO,EACL,KAAK,EACL,WAAW,EACX,UAAU,EACV,gBAAgB,EAChB,aAAa,EACb,UAAU,EACV,aAAa,EACb,KAAK,kBAAkB,EACvB,KAAK,UAAU,GAChB,CAAC;AAGF,MAAM,MAAM,sBAAsB,GAAG,KAAK,CAAC,cAAc,CAAC,OAAO,KAAK,CAAC,SAAS,cAAc,GAAG,IAAI,GAAG,KAAK,CAAC"}
|
package/dist/toast.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
"use client";
|
|
3
|
-
import { a as e, i as t, n, o as r, r as i, s as a, t as o } from "./toast-
|
|
3
|
+
import { a as e, i as t, n, o as r, r as i, s as a, t as o } from "./toast-D0Yb-K84.mjs";
|
|
4
4
|
export { o as Toast, n as ToastAction, i as ToastClose, t as ToastDescription, e as ToastProvider, r as ToastTitle, a as ToastViewport };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const e=require("./chunk-mLOUI7ql.js"),t=require("./toast-
|
|
1
|
+
const e=require("./chunk-mLOUI7ql.js"),t=require("./toast-B0S3F09s.js");let n=require("react");n=e.r(n);let r=require("react/jsx-runtime");var i=1,a=1e6,o={ADD_TOAST:`ADD_TOAST`,UPDATE_TOAST:`UPDATE_TOAST`,DISMISS_TOAST:`DISMISS_TOAST`,REMOVE_TOAST:`REMOVE_TOAST`},s=0;function c(){return s=(s+1)%(2**53-1),s.toString()}var l=new Map,u=e=>{if(l.has(e))return;let t=setTimeout(()=>{l.delete(e),m({type:`REMOVE_TOAST`,toastId:e})},a);l.set(e,t)},d=(e,t)=>{switch(t.type){case o.ADD_TOAST:return{...e,toasts:[t.toast,...e.toasts].slice(0,i)};case o.UPDATE_TOAST:return{...e,toasts:e.toasts.map(e=>e.id===t.toast.id?{...e,...t.toast}:e)};case o.DISMISS_TOAST:{let{toastId:n}=t;return n?u(n):e.toasts.forEach(e=>{u(e.id)}),{...e,toasts:e.toasts.map(e=>e.id===n||n===void 0?{...e,open:!1}:e)}}case o.REMOVE_TOAST:return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(e=>e.id!==t.toastId)}}},f=[],p={toasts:[]};function m(e){p=d(p,e),f.forEach(e=>{e(p)})}function h({...e}){let t=c(),n=e=>m({type:`UPDATE_TOAST`,toast:{...e,id:t}}),r=()=>m({type:`DISMISS_TOAST`,toastId:t});return m({type:`ADD_TOAST`,toast:{...e,id:t,open:!0,onOpenChange:e=>{e||r()}}}),{id:t,dismiss:r,update:n}}function g(){let[e,t]=n.useState(p);return n.useEffect(()=>(f.push(t),()=>{let e=f.indexOf(t);e>-1&&f.splice(e,1)}),[e]),{...e,toast:h,dismiss:e=>m({type:`DISMISS_TOAST`,toastId:e})}}function _({...e}){let{toasts:n}=g();return(0,r.jsxs)(t.a,{...e,children:[n.map(function({id:e,title:n,description:i,action:a,...o}){return(0,r.jsxs)(t.t,{...o,children:[(0,r.jsxs)(`div`,{className:`grid gap-1`,children:[n&&(0,r.jsx)(t.o,{children:n}),i&&(0,r.jsx)(t.i,{children:i})]}),a,(0,r.jsx)(t.r,{})]},e)}),(0,r.jsx)(t.s,{})]})}Object.defineProperty(exports,"n",{enumerable:!0,get:function(){return h}}),Object.defineProperty(exports,"r",{enumerable:!0,get:function(){return g}}),Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return _}});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as e, i as t, o as n, r, s as i, t as a } from "./toast-
|
|
1
|
+
import { a as e, i as t, o as n, r, s as i, t as a } from "./toast-D0Yb-K84.mjs";
|
|
2
2
|
import * as o from "react";
|
|
3
3
|
import { jsx as s, jsxs as c } from "react/jsx-runtime";
|
|
4
4
|
//#region src/hooks/use-toast.ts
|
package/dist/toaster.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";"use client";Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./toaster-
|
|
1
|
+
"use client";"use client";Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./toaster-CX9im8R_.js");exports.Toaster=e.t;
|
package/dist/toaster.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { ToasterBaseProps } from '@gv-tech/ui-core';
|
|
2
|
-
export declare function Toaster({ ...props }: ToasterBaseProps): import(
|
|
2
|
+
export declare function Toaster({ ...props }: ToasterBaseProps): import('react').JSX.Element;
|
|
3
3
|
//# sourceMappingURL=toaster.d.ts.map
|
package/dist/toaster.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"toaster.d.ts","sourceRoot":"","sources":["../src/toaster.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"toaster.d.ts","sourceRoot":"","sources":["../src/toaster.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AAKzD,wBAAgB,OAAO,CAAC,EAAE,GAAG,KAAK,EAAE,EAAE,gBAAgB,+BAoBrD"}
|
package/dist/toaster.mjs
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e=require("./chunk-mLOUI7ql.js"),t=require("./dist-C_iFkwIX.js"),n=require("./dist-hFLuJoMi.js"),r=require("./dist-DZiOPWLp.js"),i=require("./dist-YAADIsyo.js");let a=require("react"),o=e.r(a,1);a=e.r(a);let s=require("react/jsx-runtime"),c=require("class-variance-authority");var l=Object.defineProperty,u=(e,t)=>l(e,`name`,{value:t,configurable:!0}),d=`Toggle`,f=o.forwardRef(u(function(e,t){let{pressed:a,defaultPressed:o,onPressedChange:c,...l}=e,[u,f]=i.t({prop:a,onChange:c,defaultProp:o??!1,caller:d});return(0,s.jsx)(n.t.button,{type:`button`,"aria-pressed":u,"data-state":u?`on`:`off`,"data-disabled":e.disabled?``:void 0,...l,ref:t,onClick:r.t(e.onClick,()=>{e.disabled||f(!u)})})},`Toggle`)),p=(0,c.cva)(`group/toggle hover:bg-muted hover:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 aria-pressed:bg-muted data-[state=on]:bg-muted dark:aria-invalid:ring-destructive/40 inline-flex items-center justify-center gap-1 rounded-lg text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:ring-[3px] disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,{variants:{variant:{default:`bg-transparent`,outline:`border-input hover:bg-muted border bg-transparent`},size:{default:`h-8 min-w-8 px-2.5 has-data-[icon=inline-end]:pe-2 has-data-[icon=inline-start]:ps-2`,sm:`h-7 min-w-7 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] has-data-[icon=inline-end]:pe-1.5 has-data-[icon=inline-start]:ps-1.5 [&_svg:not([class*='size-'])]:size-3.5`,lg:`h-9 min-w-9 px-2.5 has-data-[icon=inline-end]:pe-2 has-data-[icon=inline-start]:ps-2`}},defaultVariants:{variant:`default`,size:`default`}});function m({className:e,variant:n=`default`,size:r=`default`,...i}){return(0,s.jsx)(f,{"data-slot":`toggle`,className:t.t(p({variant:n,size:r,className:e})),...i})}Object.defineProperty(exports,"n",{enumerable:!0,get:function(){return p}}),Object.defineProperty(exports,"r",{enumerable:!0,get:function(){return f}}),Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return m}});
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { t as e } from "./dist-Dm3IQk5b.mjs";
|
|
2
|
+
import { t } from "./dist-BEbV0Hal.mjs";
|
|
3
|
+
import { t as n } from "./dist-BB78QQyQ.mjs";
|
|
4
|
+
import { t as r } from "./dist-Bvfb4y_L.mjs";
|
|
5
|
+
import * as i from "react";
|
|
6
|
+
import { jsx as a } from "react/jsx-runtime";
|
|
7
|
+
import { cva as o } from "class-variance-authority";
|
|
8
|
+
//#region ../../node_modules/.bun/@radix-ui+react-toggle@1.2.1+b146eb580f4286be/node_modules/@radix-ui/react-toggle/dist/index.mjs
|
|
9
|
+
var s = Object.defineProperty, c = (e, t) => s(e, "name", {
|
|
10
|
+
value: t,
|
|
11
|
+
configurable: !0
|
|
12
|
+
}), l = "Toggle", u = /* @__PURE__ */ i.forwardRef(/* @__PURE__ */ c(function(e, i) {
|
|
13
|
+
let { pressed: o, defaultPressed: s, onPressedChange: c, ...u } = e, [d, f] = r({
|
|
14
|
+
prop: o,
|
|
15
|
+
onChange: c,
|
|
16
|
+
defaultProp: s ?? !1,
|
|
17
|
+
caller: l
|
|
18
|
+
});
|
|
19
|
+
return /* @__PURE__ */ a(t.button, {
|
|
20
|
+
type: "button",
|
|
21
|
+
"aria-pressed": d,
|
|
22
|
+
"data-state": d ? "on" : "off",
|
|
23
|
+
"data-disabled": e.disabled ? "" : void 0,
|
|
24
|
+
...u,
|
|
25
|
+
ref: i,
|
|
26
|
+
onClick: n(e.onClick, () => {
|
|
27
|
+
e.disabled || f(!d);
|
|
28
|
+
})
|
|
29
|
+
});
|
|
30
|
+
}, "Toggle")), d = o("group/toggle hover:bg-muted hover:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 aria-pressed:bg-muted data-[state=on]:bg-muted dark:aria-invalid:ring-destructive/40 inline-flex items-center justify-center gap-1 rounded-lg text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:ring-[3px] disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", {
|
|
31
|
+
variants: {
|
|
32
|
+
variant: {
|
|
33
|
+
default: "bg-transparent",
|
|
34
|
+
outline: "border-input hover:bg-muted border bg-transparent"
|
|
35
|
+
},
|
|
36
|
+
size: {
|
|
37
|
+
default: "h-8 min-w-8 px-2.5 has-data-[icon=inline-end]:pe-2 has-data-[icon=inline-start]:ps-2",
|
|
38
|
+
sm: "h-7 min-w-7 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] has-data-[icon=inline-end]:pe-1.5 has-data-[icon=inline-start]:ps-1.5 [&_svg:not([class*='size-'])]:size-3.5",
|
|
39
|
+
lg: "h-9 min-w-9 px-2.5 has-data-[icon=inline-end]:pe-2 has-data-[icon=inline-start]:ps-2"
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
defaultVariants: {
|
|
43
|
+
variant: "default",
|
|
44
|
+
size: "default"
|
|
45
|
+
}
|
|
46
|
+
});
|
|
47
|
+
function f({ className: t, variant: n = "default", size: r = "default", ...i }) {
|
|
48
|
+
return /* @__PURE__ */ a(u, {
|
|
49
|
+
"data-slot": "toggle",
|
|
50
|
+
className: e(d({
|
|
51
|
+
variant: n,
|
|
52
|
+
size: r,
|
|
53
|
+
className: t
|
|
54
|
+
})),
|
|
55
|
+
...i
|
|
56
|
+
});
|
|
57
|
+
}
|
|
58
|
+
//#endregion
|
|
59
|
+
export { d as n, u as r, f as t };
|