@px-ui/ui 1.0.11 → 1.2.0
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/{avatar-cLlUF5Lz.d.ts → avatar-BHChvx39.d.ts} +6 -6
- package/dist/{avatar-cLlUF5Lz.d.ts.map → avatar-BHChvx39.d.ts.map} +1 -1
- package/dist/{avatar-a40DzPi3.js → avatar-DnDnGmSj.js} +4 -4
- package/dist/{avatar-a40DzPi3.js.map → avatar-DnDnGmSj.js.map} +1 -1
- package/dist/{button-BJ727apo.d.ts → button-BhyEUVw7.d.ts} +6 -6
- package/dist/{button-BJ727apo.d.ts.map → button-BhyEUVw7.d.ts.map} +1 -1
- package/dist/{button-Cp2S1spE.js → button-DnHwqwy0.js} +2 -2
- package/dist/{button-Cp2S1spE.js.map → button-DnHwqwy0.js.map} +1 -1
- package/dist/checkbox-CwkX29tL.js +22 -0
- package/dist/checkbox-CwkX29tL.js.map +1 -0
- package/dist/collapsible-DsrYXIW5.js +28 -0
- package/dist/collapsible-DsrYXIW5.js.map +1 -0
- package/dist/{combobox-Di5naqIR.js → combobox-5IAivvXw.js} +9 -9
- package/dist/{combobox-Di5naqIR.js.map → combobox-5IAivvXw.js.map} +1 -1
- package/dist/{combobox-B73nb6Tq.d.ts → combobox-BMr1s-el.d.ts} +19 -19
- package/dist/combobox-BMr1s-el.d.ts.map +1 -0
- package/dist/components/accordion.d.ts +5 -5
- package/dist/components/accordion.d.ts.map +1 -1
- package/dist/components/accordion.js +2 -2
- package/dist/components/alert-dialog.d.ts +14 -14
- package/dist/components/alert-dialog.d.ts.map +1 -1
- package/dist/components/alert-dialog.js +3 -3
- package/dist/components/alert.d.ts +7 -7
- package/dist/components/alert.d.ts.map +1 -1
- package/dist/components/alert.js +2 -2
- package/dist/components/aspect-ratio.d.ts +2 -2
- package/dist/components/aspect-ratio.d.ts.map +1 -1
- package/dist/components/aspect-ratio.js +1 -1
- package/dist/components/attachment.d.ts +14 -14
- package/dist/components/attachment.d.ts.map +1 -1
- package/dist/components/attachment.js +3 -3
- package/dist/components/avatar-group.d.ts +4 -4
- package/dist/components/avatar-group.js +5 -5
- package/dist/components/avatar.d.ts +1 -1
- package/dist/components/avatar.js +3 -3
- package/dist/components/badge.d.ts +3 -3
- package/dist/components/badge.js +1 -1
- package/dist/components/breadcrumb.d.ts +7 -7
- package/dist/components/breadcrumb.js +2 -2
- package/dist/components/bubble.d.ts +7 -7
- package/dist/components/bubble.js +2 -2
- package/dist/components/button-group.d.ts +7 -7
- package/dist/components/button-group.d.ts.map +1 -1
- package/dist/components/button-group.js +2 -2
- package/dist/components/button.d.ts +1 -1
- package/dist/components/button.js +2 -2
- package/dist/components/calendar.d.ts +4 -4
- package/dist/components/calendar.d.ts.map +1 -1
- package/dist/components/calendar.js +3 -3
- package/dist/components/card.d.ts +8 -8
- package/dist/components/card.d.ts.map +1 -1
- package/dist/components/card.js +2 -2
- package/dist/components/carousel.d.ts +7 -7
- package/dist/components/carousel.js +3 -3
- package/dist/components/chart.d.ts +5 -5
- package/dist/components/chart.js +2 -2
- package/dist/components/checkbox.d.ts +2 -2
- package/dist/components/checkbox.js +3 -21
- package/dist/components/collapsible.d.ts +4 -4
- package/dist/components/collapsible.js +3 -27
- package/dist/components/combobox.d.ts +2 -2
- package/dist/components/combobox.js +11 -11
- package/dist/components/command.d.ts +11 -11
- package/dist/components/command.d.ts.map +1 -1
- package/dist/components/command.js +7 -7
- package/dist/components/context-menu.d.ts +16 -16
- package/dist/components/context-menu.d.ts.map +1 -1
- package/dist/components/context-menu.js +2 -2
- package/dist/components/currency-select-field.d.ts +4 -4
- package/dist/components/currency-select-field.js +12 -12
- package/dist/components/dialog.d.ts +11 -11
- package/dist/components/dialog.js +3 -3
- package/dist/components/direction.js +1 -1
- package/dist/components/drawer.d.ts +11 -11
- package/dist/components/drawer.js +2 -2
- package/dist/components/dropdown-menu.d.ts +1 -1
- package/dist/components/dropdown-menu.js +2 -2
- package/dist/components/editor-output.d.ts +87 -0
- package/dist/components/editor-output.d.ts.map +1 -0
- package/dist/components/editor-output.js +158 -0
- package/dist/components/editor-output.js.map +1 -0
- package/dist/components/empty.d.ts +9 -9
- package/dist/components/empty.d.ts.map +1 -1
- package/dist/components/empty.js +3 -61
- package/dist/components/field.d.ts +16 -16
- package/dist/components/field.d.ts.map +1 -1
- package/dist/components/field.js +4 -4
- package/dist/components/file-upload-field.d.ts +3 -3
- package/dist/components/file-upload-field.js +6 -6
- package/dist/components/file-upload.d.ts +3 -3
- package/dist/components/file-upload.js +4 -4
- package/dist/components/hover-card.d.ts +4 -4
- package/dist/components/hover-card.d.ts.map +1 -1
- package/dist/components/hover-card.js +1 -1
- package/dist/components/icon.d.ts +83 -0
- package/dist/components/icon.d.ts.map +1 -0
- package/dist/components/icon.js +188 -0
- package/dist/components/icon.js.map +1 -0
- package/dist/components/input-group.d.ts +11 -11
- package/dist/components/input-group.d.ts.map +1 -1
- package/dist/components/input-group.js +5 -5
- package/dist/components/input-otp.d.ts +6 -6
- package/dist/components/input-otp.d.ts.map +1 -1
- package/dist/components/input-otp.js +6 -6
- package/dist/components/input-otp.js.map +1 -1
- package/dist/components/input.d.ts +1 -1
- package/dist/components/input.js +2 -2
- package/dist/components/item.d.ts +15 -15
- package/dist/components/item.d.ts.map +1 -1
- package/dist/components/item.js +3 -3
- package/dist/components/kbd.d.ts +3 -3
- package/dist/components/kbd.d.ts.map +1 -1
- package/dist/components/kbd.js +1 -1
- package/dist/components/label.d.ts +1 -1
- package/dist/components/label.js +2 -2
- package/dist/components/marker.d.ts +4 -4
- package/dist/components/marker.js +2 -2
- package/dist/components/menubar.d.ts +18 -18
- package/dist/components/menubar.js +8 -8
- package/dist/components/menubar.js.map +1 -1
- package/dist/components/message-scroller.d.ts +8 -8
- package/dist/components/message-scroller.d.ts.map +1 -1
- package/dist/components/message-scroller.js +3 -3
- package/dist/components/message.d.ts +7 -7
- package/dist/components/message.d.ts.map +1 -1
- package/dist/components/message.js +2 -2
- package/dist/components/native-select.d.ts +4 -4
- package/dist/components/native-select.d.ts.map +1 -1
- package/dist/components/native-select.js +2 -2
- package/dist/components/navigation-menu.d.ts +11 -11
- package/dist/components/navigation-menu.d.ts.map +1 -1
- package/dist/components/navigation-menu.js +1 -1
- package/dist/components/pagination.d.ts +9 -9
- package/dist/components/pagination.js +3 -3
- package/dist/components/phone-input.d.ts +2 -2
- package/dist/components/phone-input.d.ts.map +1 -1
- package/dist/components/phone-input.js +2 -2
- package/dist/components/popover.d.ts +7 -7
- package/dist/components/popover.d.ts.map +1 -1
- package/dist/components/popover.js +2 -2
- package/dist/components/progress.d.ts +6 -6
- package/dist/components/progress.d.ts.map +1 -1
- package/dist/components/progress.js +1 -1
- package/dist/components/radio-group.d.ts +3 -3
- package/dist/components/radio-group.js +1 -1
- package/dist/components/resizable.d.ts +4 -4
- package/dist/components/resizable.js +1 -1
- package/dist/components/rich-text-editor.d.ts +204 -0
- package/dist/components/rich-text-editor.d.ts.map +1 -0
- package/dist/components/rich-text-editor.js +359 -0
- package/dist/components/rich-text-editor.js.map +1 -0
- package/dist/components/scroll-area.d.ts +13 -3
- package/dist/components/scroll-area.d.ts.map +1 -1
- package/dist/components/scroll-area.js +3 -38
- package/dist/components/select.d.ts +10 -10
- package/dist/components/select.js +2 -2
- package/dist/components/separator.d.ts +1 -1
- package/dist/components/separator.js +2 -2
- package/dist/components/sheet.d.ts +9 -9
- package/dist/components/sheet.js +3 -3
- package/dist/components/sidebar.d.ts +24 -24
- package/dist/components/sidebar.js +9 -9
- package/dist/components/skeleton.d.ts +2 -2
- package/dist/components/skeleton.js +2 -2
- package/dist/components/slider.d.ts +2 -2
- package/dist/components/slider.js +1 -1
- package/dist/components/sortable-list.d.ts +153 -0
- package/dist/components/sortable-list.d.ts.map +1 -0
- package/dist/components/sortable-list.js +191 -0
- package/dist/components/sortable-list.js.map +1 -0
- package/dist/components/spinner.d.ts +2 -2
- package/dist/components/spinner.js +2 -2
- package/dist/components/stepper.d.ts +171 -0
- package/dist/components/stepper.d.ts.map +1 -0
- package/dist/components/stepper.js +281 -0
- package/dist/components/stepper.js.map +1 -0
- package/dist/components/switch.d.ts +2 -2
- package/dist/components/switch.js +1 -1
- package/dist/components/table.d.ts +9 -9
- package/dist/components/table.js +2 -2
- package/dist/components/tabs.d.ts +8 -8
- package/dist/components/tabs.js +1 -1
- package/dist/components/textarea.d.ts +2 -2
- package/dist/components/textarea.js +2 -2
- package/dist/components/toast.d.ts +1 -1
- package/dist/components/toast.js +2 -2
- package/dist/components/toggle-group.d.ts +4 -4
- package/dist/components/toggle-group.js +3 -3
- package/dist/components/toggle.d.ts +1 -1
- package/dist/components/toggle.js +2 -2
- package/dist/components/tooltip.d.ts +1 -1
- package/dist/components/tooltip.js +2 -2
- package/dist/components/tree-select.d.ts +192 -0
- package/dist/components/tree-select.d.ts.map +1 -0
- package/dist/components/tree-select.js +421 -0
- package/dist/components/tree-select.js.map +1 -0
- package/dist/{dialog-B3HhbIdv.js → dialog-DuGJUPQl.js} +4 -4
- package/dist/{dialog-B3HhbIdv.js.map → dialog-DuGJUPQl.js.map} +1 -1
- package/dist/{dropdown-menu-vwX--mgm.js → dropdown-menu-BWEfcvmP.js} +20 -20
- package/dist/{dropdown-menu-vwX--mgm.js.map → dropdown-menu-BWEfcvmP.js.map} +1 -1
- package/dist/{dropdown-menu-C6n_oYre.d.ts → dropdown-menu-DGMTllRk.d.ts} +17 -17
- package/dist/{dropdown-menu-C6n_oYre.d.ts.map → dropdown-menu-DGMTllRk.d.ts.map} +1 -1
- package/dist/empty-U4zrLmFU.js +62 -0
- package/dist/empty-U4zrLmFU.js.map +1 -0
- package/dist/{file-upload-CGfXHKPZ.d.ts → file-upload-C4i5tbut.d.ts} +13 -13
- package/dist/{file-upload-CGfXHKPZ.d.ts.map → file-upload-C4i5tbut.d.ts.map} +1 -1
- package/dist/{file-upload-B0fHdUBL.js → file-upload-DU5FAkHm.js} +5 -5
- package/dist/{file-upload-B0fHdUBL.js.map → file-upload-DU5FAkHm.js.map} +1 -1
- package/dist/hooks/use-async-options.d.ts +1 -1
- package/dist/hooks/use-async-options.js +1 -1
- package/dist/hooks/use-debounce.js +1 -1
- package/dist/hooks/use-file-upload.d.ts +1 -1
- package/dist/hooks/use-file-upload.js +1 -1
- package/dist/hooks/use-infinite-scroll.d.ts +1 -1
- package/dist/hooks/use-infinite-scroll.js +2 -2
- package/dist/hooks/use-intersection-observer.d.ts +1 -1
- package/dist/hooks/use-intersection-observer.js +1 -1
- package/dist/hooks/use-mobile.js +1 -1
- package/dist/{input-group-C78_1dEy.js → input-group-B5PMRYld.js} +6 -6
- package/dist/{input-group-C78_1dEy.js.map → input-group-B5PMRYld.js.map} +1 -1
- package/dist/{input-B-RCmrtR.js → input-jIoNIdLQ.js} +3 -3
- package/dist/{input-B-RCmrtR.js.map → input-jIoNIdLQ.js.map} +1 -1
- package/dist/{input-BtI3FvrB.d.ts → input-zxE3Qo1O.d.ts} +3 -3
- package/dist/input-zxE3Qo1O.d.ts.map +1 -0
- package/dist/{label-Cmlhz-uF.js → label-DsRhOKY_.js} +3 -3
- package/dist/{label-Cmlhz-uF.js.map → label-DsRhOKY_.js.map} +1 -1
- package/dist/label-wB7C6-hQ.d.ts +11 -0
- package/dist/label-wB7C6-hQ.d.ts.map +1 -0
- package/dist/lib/utils.js +1 -1
- package/dist/{popover-CsTnnBvx.js → popover-BGkU46G7.js} +3 -3
- package/dist/{popover-CsTnnBvx.js.map → popover-BGkU46G7.js.map} +1 -1
- package/dist/providers/px-ui-provider.d.ts +4 -4
- package/dist/providers/px-ui-provider.d.ts.map +1 -1
- package/dist/providers/px-ui-provider.js +4 -4
- package/dist/scroll-area-mNVMQ0Of.js +40 -0
- package/dist/scroll-area-mNVMQ0Of.js.map +1 -0
- package/dist/{separator-BQBOLUMc.js → separator-D0bew2D_.js} +2 -2
- package/dist/{separator-BQBOLUMc.js.map → separator-D0bew2D_.js.map} +1 -1
- package/dist/{separator-pyhTqgkN.d.ts → separator-DMTEE-qR.d.ts} +3 -3
- package/dist/{separator-pyhTqgkN.d.ts.map → separator-DMTEE-qR.d.ts.map} +1 -1
- package/dist/{sheet-Chg_afex.js → sheet-BB23q6wd.js} +4 -4
- package/dist/{sheet-Chg_afex.js.map → sheet-BB23q6wd.js.map} +1 -1
- package/dist/{skeleton-J879XBBA.js → skeleton-knxLhbA5.js} +2 -2
- package/dist/{skeleton-J879XBBA.js.map → skeleton-knxLhbA5.js.map} +1 -1
- package/dist/{spinner-C7yzrK_s.js → spinner-9MdgLDTZ.js} +2 -2
- package/dist/{spinner-C7yzrK_s.js.map → spinner-9MdgLDTZ.js.map} +1 -1
- package/dist/{textarea-CaHmr0re.js → textarea-hZg0gA8u.js} +3 -3
- package/dist/{textarea-CaHmr0re.js.map → textarea-hZg0gA8u.js.map} +1 -1
- package/dist/{toast-CSU7vJkV.d.ts → toast-011e8XdI.d.ts} +5 -5
- package/dist/{toast-CSU7vJkV.d.ts.map → toast-011e8XdI.d.ts.map} +1 -1
- package/dist/{toast-BrPEQywl.js → toast-BdxoP8vz.js} +4 -4
- package/dist/{toast-BrPEQywl.js.map → toast-BdxoP8vz.js.map} +1 -1
- package/dist/{toggle-gjMAPmkg.d.ts → toggle-0BxcVVwi.d.ts} +5 -5
- package/dist/toggle-0BxcVVwi.d.ts.map +1 -0
- package/dist/{toggle-CA4KsgWs.js → toggle-BZXrLBLK.js} +2 -2
- package/dist/{toggle-CA4KsgWs.js.map → toggle-BZXrLBLK.js.map} +1 -1
- package/dist/{tooltip-7bptiThf.d.ts → tooltip-DWoVF4fx.d.ts} +6 -6
- package/dist/{tooltip-7bptiThf.d.ts.map → tooltip-DWoVF4fx.d.ts.map} +1 -1
- package/dist/{tooltip-BhxGE3Gb.js → tooltip-Dsfn_zZD.js} +2 -2
- package/dist/{tooltip-BhxGE3Gb.js.map → tooltip-Dsfn_zZD.js.map} +1 -1
- package/dist/{use-async-options-rNdyxIrQ.d.ts → use-async-options-DdyHJxHh.d.ts} +1 -1
- package/dist/{use-async-options-rNdyxIrQ.d.ts.map → use-async-options-DdyHJxHh.d.ts.map} +1 -1
- package/dist/{use-async-options-CtB4wZrr.js → use-async-options-tueAuVs_.js} +1 -1
- package/dist/{use-async-options-CtB4wZrr.js.map → use-async-options-tueAuVs_.js.map} +1 -1
- package/dist/{use-debounce--Lv1ABSa.js → use-debounce-7gIeOwla.js} +1 -1
- package/dist/{use-debounce--Lv1ABSa.js.map → use-debounce-7gIeOwla.js.map} +1 -1
- package/dist/{use-file-upload-Cbb_9kTw.d.ts → use-file-upload-Bc7CyQ7O.d.ts} +1 -1
- package/dist/{use-file-upload-Cbb_9kTw.d.ts.map → use-file-upload-Bc7CyQ7O.d.ts.map} +1 -1
- package/dist/{use-file-upload-BbERd3Nw.js → use-file-upload-DQD1vY_Z.js} +1 -1
- package/dist/{use-file-upload-BbERd3Nw.js.map → use-file-upload-DQD1vY_Z.js.map} +1 -1
- package/dist/{use-infinite-scroll-CC_Guyvn.js → use-infinite-scroll-HpeMA2MK.js} +2 -2
- package/dist/{use-infinite-scroll-CC_Guyvn.js.map → use-infinite-scroll-HpeMA2MK.js.map} +1 -1
- package/dist/{use-intersection-observer-CgAaXczI.d.ts → use-intersection-observer-DNPextJs.d.ts} +1 -1
- package/dist/{use-intersection-observer-CgAaXczI.d.ts.map → use-intersection-observer-DNPextJs.d.ts.map} +1 -1
- package/dist/{use-intersection-observer-S0wsPmhF.js → use-intersection-observer-rlKEjyL1.js} +1 -1
- package/dist/{use-intersection-observer-S0wsPmhF.js.map → use-intersection-observer-rlKEjyL1.js.map} +1 -1
- package/dist/{use-mobile--NaMWuCj.js → use-mobile-DUqQzj2D.js} +1 -1
- package/dist/{use-mobile--NaMWuCj.js.map → use-mobile-DUqQzj2D.js.map} +1 -1
- package/dist/{utils-DeIaBj75.js → utils-DUlptRpf.js} +1 -1
- package/dist/{utils-DeIaBj75.js.map → utils-DUlptRpf.js.map} +1 -1
- package/package.json +52 -2
- package/dist/combobox-B73nb6Tq.d.ts.map +0 -1
- package/dist/components/checkbox.js.map +0 -1
- package/dist/components/collapsible.js.map +0 -1
- package/dist/components/empty.js.map +0 -1
- package/dist/components/scroll-area.js.map +0 -1
- package/dist/input-BtI3FvrB.d.ts.map +0 -1
- package/dist/label-BnSHwOyi.d.ts +0 -11
- package/dist/label-BnSHwOyi.d.ts.map +0 -1
- package/dist/toggle-gjMAPmkg.d.ts.map +0 -1
- /package/dist/{direction-ZS2Hta3v.js → direction-DFPbwDSF.js} +0 -0
package/dist/components/toast.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
|
-
import "../utils-
|
|
4
|
-
import { a as toast, i as anchoredToastManager, n as Toaster, o as toastManager, r as anchoredToast, t as AnchoredToaster } from "../toast-
|
|
3
|
+
import "../utils-DUlptRpf.js";
|
|
4
|
+
import { a as toast, i as anchoredToastManager, n as Toaster, o as toastManager, r as anchoredToast, t as AnchoredToaster } from "../toast-BdxoP8vz.js";
|
|
5
5
|
|
|
6
6
|
export { AnchoredToaster, Toaster, anchoredToast, anchoredToastManager, toast, toastManager };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { n as toggleVariants } from "../toggle-
|
|
2
|
-
import * as
|
|
1
|
+
import { n as toggleVariants } from "../toggle-0BxcVVwi.js";
|
|
2
|
+
import * as react_jsx_runtime172 from "react/jsx-runtime";
|
|
3
3
|
import { VariantProps } from "class-variance-authority";
|
|
4
4
|
import { Toggle } from "@base-ui/react/toggle";
|
|
5
5
|
import { ToggleGroup as ToggleGroup$1 } from "@base-ui/react/toggle-group";
|
|
@@ -16,14 +16,14 @@ declare function ToggleGroup({
|
|
|
16
16
|
}: ToggleGroup$1.Props & VariantProps<typeof toggleVariants> & {
|
|
17
17
|
spacing?: number;
|
|
18
18
|
orientation?: "horizontal" | "vertical";
|
|
19
|
-
}):
|
|
19
|
+
}): react_jsx_runtime172.JSX.Element;
|
|
20
20
|
declare function ToggleGroupItem({
|
|
21
21
|
className,
|
|
22
22
|
children,
|
|
23
23
|
variant,
|
|
24
24
|
size,
|
|
25
25
|
...props
|
|
26
|
-
}: Toggle.Props & VariantProps<typeof toggleVariants>):
|
|
26
|
+
}: Toggle.Props & VariantProps<typeof toggleVariants>): react_jsx_runtime172.JSX.Element;
|
|
27
27
|
//#endregion
|
|
28
28
|
export { ToggleGroup, ToggleGroupItem };
|
|
29
29
|
//# sourceMappingURL=toggle-group.d.ts.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { t as cn } from "../utils-
|
|
2
|
-
import { n as toggleVariants } from "../toggle-
|
|
3
|
-
import * as React$1 from "react";
|
|
1
|
+
import { t as cn } from "../utils-DUlptRpf.js";
|
|
2
|
+
import { n as toggleVariants } from "../toggle-BZXrLBLK.js";
|
|
4
3
|
import { jsx } from "react/jsx-runtime";
|
|
4
|
+
import * as React$1 from "react";
|
|
5
5
|
import "class-variance-authority";
|
|
6
6
|
import { Toggle } from "@base-ui/react/toggle";
|
|
7
7
|
import { ToggleGroup as ToggleGroup$1 } from "@base-ui/react/toggle-group";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as toggleVariants, t as Toggle } from "../toggle-
|
|
1
|
+
import { n as toggleVariants, t as Toggle } from "../toggle-0BxcVVwi.js";
|
|
2
2
|
export { Toggle, toggleVariants };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
|
|
3
|
-
import "../utils-
|
|
4
|
-
import { n as toggleVariants, t as Toggle } from "../toggle-
|
|
3
|
+
import "../utils-DUlptRpf.js";
|
|
4
|
+
import { n as toggleVariants, t as Toggle } from "../toggle-BZXrLBLK.js";
|
|
5
5
|
|
|
6
6
|
export { Toggle, toggleVariants };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { i as TooltipTrigger, n as TooltipContent, r as TooltipProvider, t as Tooltip } from "../tooltip-
|
|
1
|
+
import { i as TooltipTrigger, n as TooltipContent, r as TooltipProvider, t as Tooltip } from "../tooltip-DWoVF4fx.js";
|
|
2
2
|
export { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "../utils-
|
|
2
|
-
import { i as TooltipTrigger, n as TooltipContent, r as TooltipProvider, t as Tooltip } from "../tooltip-
|
|
1
|
+
import "../utils-DUlptRpf.js";
|
|
2
|
+
import { i as TooltipTrigger, n as TooltipContent, r as TooltipProvider, t as Tooltip } from "../tooltip-Dsfn_zZD.js";
|
|
3
3
|
|
|
4
4
|
export { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger };
|
|
@@ -0,0 +1,192 @@
|
|
|
1
|
+
import * as react_jsx_runtime227 from "react/jsx-runtime";
|
|
2
|
+
import * as React$1 from "react";
|
|
3
|
+
|
|
4
|
+
//#region src/components/tree-select.d.ts
|
|
5
|
+
/**
|
|
6
|
+
* A single node in the tree passed to {@link TreeSelect}.
|
|
7
|
+
*/
|
|
8
|
+
interface TreeSelectNode {
|
|
9
|
+
/** Stable, unique identifier. Used as the selection key in `value`. */
|
|
10
|
+
id: string;
|
|
11
|
+
/** Human-readable label rendered on the row. */
|
|
12
|
+
label: React$1.ReactNode;
|
|
13
|
+
/** Plain-text label used for search matching. Falls back to `label` when it is a string. */
|
|
14
|
+
searchText?: string;
|
|
15
|
+
/** Optional child nodes. Presence of a non-empty array makes the row expandable. */
|
|
16
|
+
children?: TreeSelectNode[];
|
|
17
|
+
/** Disables the row's checkbox (and excludes it from parent propagation). */
|
|
18
|
+
disabled?: boolean;
|
|
19
|
+
}
|
|
20
|
+
/** Tri-state checked status for a node, per the active `selectionMode`. */
|
|
21
|
+
type TreeSelectCheckedState = "checked" | "unchecked" | "indeterminate";
|
|
22
|
+
/** How selecting a node affects the others. See {@link TreeSelectProps.selectionMode}. */
|
|
23
|
+
type TreeSelectSelectionMode = "cascade" | "leaf" | "independent";
|
|
24
|
+
/** Per-row context passed to {@link TreeSelectProps.renderNode}. */
|
|
25
|
+
interface TreeSelectNodeMeta {
|
|
26
|
+
/** Tri-state of this row under the active `selectionMode`. */
|
|
27
|
+
state: TreeSelectCheckedState;
|
|
28
|
+
/** 0-based depth (root rows are depth 0). */
|
|
29
|
+
depth: number;
|
|
30
|
+
/** Whether this (expandable) row is currently open. Always false for leaves. */
|
|
31
|
+
expanded: boolean;
|
|
32
|
+
/** Whether the row is disabled (the node itself, or the whole control). */
|
|
33
|
+
disabled: boolean;
|
|
34
|
+
/** Put this on your label text (`id={meta.labelId}`) to name the checkbox. */
|
|
35
|
+
labelId: string;
|
|
36
|
+
/** Toggle this row's selection; omit `next` to flip from the current state. */
|
|
37
|
+
toggle: (next?: boolean) => void;
|
|
38
|
+
}
|
|
39
|
+
interface TreeSelectProps extends Omit<React$1.ComponentProps<"div">, "onChange" | "defaultValue"> {
|
|
40
|
+
/** The tree of nodes to render. */
|
|
41
|
+
nodes: TreeSelectNode[];
|
|
42
|
+
/** Controlled selection — array of selected node `id`s. Pair with `onValueChange`. */
|
|
43
|
+
value?: string[];
|
|
44
|
+
/** Initial selection for the uncontrolled case. @default [] */
|
|
45
|
+
defaultValue?: string[];
|
|
46
|
+
/** Called whenever the selection changes, with the next array of selected `id`s. */
|
|
47
|
+
onValueChange?: (value: string[]) => void;
|
|
48
|
+
/**
|
|
49
|
+
* Render a search box that filters the tree. Matching nodes and their
|
|
50
|
+
* ancestors are kept; non-matching branches are hidden.
|
|
51
|
+
* @default false
|
|
52
|
+
*/
|
|
53
|
+
searchable?: boolean;
|
|
54
|
+
/** Placeholder for the search input. @default "Search…" */
|
|
55
|
+
searchPlaceholder?: string;
|
|
56
|
+
/** Controlled search query. Pair with `onSearchChange`. */
|
|
57
|
+
search?: string;
|
|
58
|
+
/** Default search query for the uncontrolled case. @default "" */
|
|
59
|
+
defaultSearch?: string;
|
|
60
|
+
/** Called when the internal search query changes. */
|
|
61
|
+
onSearchChange?: (search: string) => void;
|
|
62
|
+
/**
|
|
63
|
+
* Maximum depth to render, 0-based (root nodes are depth 0). Nodes deeper
|
|
64
|
+
* than this are not rendered and are excluded from propagation/counts.
|
|
65
|
+
* Omit for unlimited depth.
|
|
66
|
+
*/
|
|
67
|
+
maxDepth?: number;
|
|
68
|
+
/**
|
|
69
|
+
* How selecting a node affects the others.
|
|
70
|
+
* - `"cascade"` (default): selecting a parent selects all of its enabled
|
|
71
|
+
* descendants; a branch with a mix shows the indeterminate state. The
|
|
72
|
+
* selection includes both parent ids and leaf ids.
|
|
73
|
+
* - `"leaf"`: only leaf rows are selectable. A parent checkbox toggles its
|
|
74
|
+
* enabled leaves and reflects their tri-state, but parent ids never enter
|
|
75
|
+
* `value`, and counts are based on leaves.
|
|
76
|
+
* - `"independent"`: each node toggles only itself — no cascade and no
|
|
77
|
+
* indeterminate roll-up.
|
|
78
|
+
* @default "cascade"
|
|
79
|
+
*/
|
|
80
|
+
selectionMode?: TreeSelectSelectionMode;
|
|
81
|
+
/**
|
|
82
|
+
* Show a summary line above the tree with the selected count.
|
|
83
|
+
* @default true
|
|
84
|
+
*/
|
|
85
|
+
showSummary?: boolean;
|
|
86
|
+
/**
|
|
87
|
+
* Render a custom summary given the selected ids and the total selectable
|
|
88
|
+
* count. Overrides the default count text.
|
|
89
|
+
*/
|
|
90
|
+
renderSummary?: (selectedCount: number, total: number) => React$1.ReactNode;
|
|
91
|
+
/**
|
|
92
|
+
* Render the row body (everything after the checkbox) yourself. You own the
|
|
93
|
+
* label markup — including click-to-toggle (call `meta.toggle()`) and naming
|
|
94
|
+
* the managed checkbox (put `id={meta.labelId}` on your label text, or rely
|
|
95
|
+
* on a string `label`/`searchText` as the fallback name). The chevron,
|
|
96
|
+
* checkbox, indentation, and expansion stay managed by the component.
|
|
97
|
+
*/
|
|
98
|
+
renderNode?: (node: TreeSelectNode, meta: TreeSelectNodeMeta) => React$1.ReactNode;
|
|
99
|
+
/** Message shown when the tree has no nodes at all. @default "No items." */
|
|
100
|
+
emptyMessage?: React$1.ReactNode;
|
|
101
|
+
/** Message shown when a search query yields no matches. @default "No results found." */
|
|
102
|
+
noResultsMessage?: React$1.ReactNode;
|
|
103
|
+
/** Disable the entire control. */
|
|
104
|
+
disabled?: boolean;
|
|
105
|
+
/**
|
|
106
|
+
* Whether all branches start expanded (uncontrolled). Ignored when
|
|
107
|
+
* `expandedIds` or `defaultExpandedIds` is provided. @default false
|
|
108
|
+
*/
|
|
109
|
+
defaultExpanded?: boolean;
|
|
110
|
+
/**
|
|
111
|
+
* Controlled set of expanded branch `id`s. Pair with `onExpandedChange`.
|
|
112
|
+
* Driving this lets a consumer implement expand-all / collapse-all or
|
|
113
|
+
* persist which branches are open.
|
|
114
|
+
*/
|
|
115
|
+
expandedIds?: string[];
|
|
116
|
+
/** Initial expanded branch `id`s for the uncontrolled case. */
|
|
117
|
+
defaultExpandedIds?: string[];
|
|
118
|
+
/** Called when the set of expanded branch `id`s changes. */
|
|
119
|
+
onExpandedChange?: (expandedIds: string[]) => void;
|
|
120
|
+
/** Max height of the scroll viewport (any CSS length). @default "16rem" */
|
|
121
|
+
scrollHeight?: string | number;
|
|
122
|
+
/** Extra className for the scroll viewport wrapper. */
|
|
123
|
+
scrollClassName?: string;
|
|
124
|
+
}
|
|
125
|
+
/**
|
|
126
|
+
* A hierarchical, searchable tree multi-select with tri-state checkboxes.
|
|
127
|
+
*
|
|
128
|
+
* Selecting a parent selects all of its (enabled) descendants; clearing a
|
|
129
|
+
* parent clears them. A branch with a mix of selected and unselected
|
|
130
|
+
* descendants shows the indeterminate state. The selection is a flat array of
|
|
131
|
+
* node ids and works controlled (`value` + `onValueChange`) or uncontrolled
|
|
132
|
+
* (`defaultValue`). Expansion is likewise controllable (`expandedIds` +
|
|
133
|
+
* `onExpandedChange`) so consumers can implement expand-all / collapse-all.
|
|
134
|
+
*
|
|
135
|
+
* @example
|
|
136
|
+
* ```tsx
|
|
137
|
+
* const nodes = [
|
|
138
|
+
* {
|
|
139
|
+
* id: "fe",
|
|
140
|
+
* label: "Frontend",
|
|
141
|
+
* children: [
|
|
142
|
+
* { id: "react", label: "React" },
|
|
143
|
+
* { id: "vue", label: "Vue" },
|
|
144
|
+
* ],
|
|
145
|
+
* },
|
|
146
|
+
* { id: "be", label: "Backend", children: [{ id: "rails", label: "Rails" }] },
|
|
147
|
+
* ]
|
|
148
|
+
*
|
|
149
|
+
* function Example() {
|
|
150
|
+
* const [value, setValue] = React.useState<string[]>(["react"])
|
|
151
|
+
* return (
|
|
152
|
+
* <TreeSelect
|
|
153
|
+
* nodes={nodes}
|
|
154
|
+
* value={value}
|
|
155
|
+
* onValueChange={setValue}
|
|
156
|
+
* searchable
|
|
157
|
+
* maxDepth={1}
|
|
158
|
+
* />
|
|
159
|
+
* )
|
|
160
|
+
* }
|
|
161
|
+
* ```
|
|
162
|
+
*/
|
|
163
|
+
declare function TreeSelect({
|
|
164
|
+
nodes,
|
|
165
|
+
value,
|
|
166
|
+
defaultValue,
|
|
167
|
+
onValueChange,
|
|
168
|
+
searchable,
|
|
169
|
+
searchPlaceholder,
|
|
170
|
+
search,
|
|
171
|
+
defaultSearch,
|
|
172
|
+
onSearchChange,
|
|
173
|
+
maxDepth,
|
|
174
|
+
selectionMode,
|
|
175
|
+
showSummary,
|
|
176
|
+
renderSummary,
|
|
177
|
+
renderNode,
|
|
178
|
+
emptyMessage,
|
|
179
|
+
noResultsMessage,
|
|
180
|
+
disabled,
|
|
181
|
+
defaultExpanded,
|
|
182
|
+
expandedIds,
|
|
183
|
+
defaultExpandedIds,
|
|
184
|
+
onExpandedChange,
|
|
185
|
+
scrollHeight,
|
|
186
|
+
scrollClassName,
|
|
187
|
+
className,
|
|
188
|
+
...props
|
|
189
|
+
}: TreeSelectProps): react_jsx_runtime227.JSX.Element;
|
|
190
|
+
//#endregion
|
|
191
|
+
export { TreeSelect, TreeSelectCheckedState, TreeSelectNode, TreeSelectNodeMeta, TreeSelectProps, TreeSelectSelectionMode };
|
|
192
|
+
//# sourceMappingURL=tree-select.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tree-select.d.ts","names":[],"sources":["../../src/components/tree-select.tsx"],"sourcesContent":[],"mappings":";;;;;;;AAiCiB,UAAA,cAAA,CAAc;EAcnB;EAIA,EAAA,EAAA,MAAA;EAGK;EAeA,KAAA,EAhCR,OAAA,CAAM,SAiCb;EAAa;EAEN,UAAA,CAAA,EAAA,MAAA;EAuCS;EAU0C,QAAM,CAAA,EAhFrD,cAgFqD,EAAA;EAQ5C;EAAsB,QAAA,CAAA,EAAA,OAAA;;;AAIvB,KAtFT,sBAAA,GAsFe,SAAA,GAAA,WAAA,GAAA,eAAA;;AA/Db,KAnBF,uBAAA,GAmBE,SAAA,GAAA,MAAA,GAAA,aAAA;AAohBd;AACE,UAriBe,kBAAA,CAqiBf;EACA;EACA,KAAA,EAriBO,sBAqiBP;EACA;EACA,KAAA,EAAA,MAAA;EACA;EACA,QAAA,EAAA,OAAA;EACA;EACA,QAAA,EAAA,OAAA;EACA;EACA,OAAA,EAAA,MAAA;EACA;EACA,MAAA,EAAA,CAAA,IAAA,CAAA,EAAA,OAAA,EAAA,GAAA,IAAA;;AAEA,UApiBe,eAAA,SACP,IAmiBR,CAniBa,OAAA,CAAM,cAmiBnB,CAAA,KAAA,CAAA,EAAA,UAAA,GAAA,cAAA,CAAA,CAAA;EACA;EACA,KAAA,EAniBO,cAmiBP,EAAA;EACA;EACA,KAAA,CAAA,EAAA,MAAA,EAAA;EACA;EACA,YAAA,CAAA,EAAA,MAAA,EAAA;EACA;EACA,aAAA,CAAA,EAAA,CAAA,KAAA,EAAA,MAAA,EAAA,EAAA,GAAA,IAAA;EACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kBAngBgB;;;;;;;;;;4DAU0C,OAAA,CAAM;;;;;;;;sBAQ5C,sBAAsB,uBAAuB,OAAA,CAAM;;iBAExD,OAAA,CAAM;;qBAEF,OAAA,CAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAqdX,UAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0Bb,kBAAe,oBAAA,CAAA,GAAA,CAAA"}
|