@moduix/react 1.1.0 → 2.0.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/README.md +16 -16
- package/dist/components/accordion/Accordion.css +21 -14
- package/dist/components/accordion/Accordion.d.ts +3 -2
- package/dist/components/accordion/Accordion.js +17 -5
- package/dist/components/accordion/Accordion.module.js +10 -9
- package/dist/components/accordion/index.d.ts +2 -2
- package/dist/components/alert/Alert.css +24 -10
- package/dist/components/alert/Alert.d.ts +5 -3
- package/dist/components/alert/Alert.js +17 -5
- package/dist/components/alert/Alert.module.js +6 -5
- package/dist/components/angle-slider/AngleSlider.css +8 -8
- package/dist/components/angle-slider/AngleSlider.d.ts +18 -2
- package/dist/components/angle-slider/AngleSlider.js +34 -18
- package/dist/components/angle-slider/AngleSlider.module.js +7 -7
- package/dist/components/angle-slider/index.d.ts +2 -2
- package/dist/components/aspect-ratio/AspectRatio.css +4 -2
- package/dist/components/aspect-ratio/AspectRatio.js +2 -2
- package/dist/components/aspect-ratio/AspectRatio.module.js +1 -1
- package/dist/components/avatar/Avatar.css +3 -3
- package/dist/components/avatar/Avatar.d.ts +6 -3
- package/dist/components/avatar/Avatar.js +12 -5
- package/dist/components/avatar/Avatar.module.js +3 -3
- package/dist/components/avatar/index.d.ts +2 -2
- package/dist/components/badge/Badge.css +46 -3
- package/dist/components/badge/Badge.d.ts +2 -2
- package/dist/components/badge/Badge.js +1 -1
- package/dist/components/badge/Badge.module.js +2 -2
- package/dist/components/bleed/Bleed.css +1 -1
- package/dist/components/bleed/Bleed.d.ts +6 -4
- package/dist/components/bleed/Bleed.js +3 -3
- package/dist/components/bleed/Bleed.module.js +1 -1
- package/dist/components/breadcrumbs/Breadcrumbs.css +17 -11
- package/dist/components/breadcrumbs/Breadcrumbs.d.ts +18 -0
- package/dist/components/breadcrumbs/Breadcrumbs.js +18 -4
- package/dist/components/breadcrumbs/Breadcrumbs.module.js +8 -7
- package/dist/components/breadcrumbs/index.d.ts +2 -0
- package/dist/components/button/Button.css +22 -2
- package/dist/components/button/Button.d.ts +6 -0
- package/dist/components/button/Button.js +12 -7
- package/dist/components/button/Button.module.js +1 -1
- package/dist/components/card/Card.css +29 -13
- package/dist/components/card/Card.d.ts +1 -0
- package/dist/components/card/Card.js +12 -1
- package/dist/components/card/Card.module.js +9 -8
- package/dist/components/carousel/Carousel.css +20 -18
- package/dist/components/carousel/Carousel.d.ts +4 -0
- package/dist/components/carousel/Carousel.js +15 -2
- package/dist/components/carousel/Carousel.module.js +12 -12
- package/dist/components/checkbox/Checkbox.css +11 -11
- package/dist/components/checkbox/Checkbox.d.ts +2 -3
- package/dist/components/checkbox/Checkbox.js +25 -22
- package/dist/components/checkbox/Checkbox.module.js +6 -6
- package/dist/components/checkbox/index.d.ts +2 -2
- package/dist/components/clipboard/Clipboard.css +8 -8
- package/dist/components/clipboard/Clipboard.d.ts +2 -0
- package/dist/components/clipboard/Clipboard.js +15 -4
- package/dist/components/clipboard/Clipboard.module.js +8 -8
- package/dist/components/close-button/CloseButton.css +1 -1
- package/dist/components/close-button/CloseButton.d.ts +12 -2
- package/dist/components/close-button/CloseButton.js +9 -9
- package/dist/components/close-button/CloseButton.module.js +1 -1
- package/dist/components/collapsible/Collapsible.css +17 -10
- package/dist/components/collapsible/Collapsible.d.ts +3 -2
- package/dist/components/collapsible/Collapsible.js +18 -6
- package/dist/components/collapsible/Collapsible.module.js +7 -6
- package/dist/components/collapsible/index.d.ts +2 -2
- package/dist/components/color-picker/ColorPicker.css +63 -34
- package/dist/components/color-picker/ColorPicker.d.ts +3 -3
- package/dist/components/color-picker/ColorPicker.js +78 -27
- package/dist/components/color-picker/ColorPicker.module.js +28 -27
- package/dist/components/color-picker/index.d.ts +2 -2
- package/dist/components/combobox/Combobox.css +55 -26
- package/dist/components/combobox/Combobox.d.ts +9 -2
- package/dist/components/combobox/Combobox.js +34 -8
- package/dist/components/combobox/Combobox.module.js +17 -17
- package/dist/components/combobox/index.d.ts +2 -2
- package/dist/components/command-palette/CommandPalette.css +80 -114
- package/dist/components/command-palette/CommandPalette.d.ts +13 -3
- package/dist/components/command-palette/CommandPalette.js +54 -43
- package/dist/components/command-palette/CommandPalette.module.js +35 -37
- package/dist/components/container/Container.css +1 -1
- package/dist/components/container/Container.js +1 -1
- package/dist/components/container/Container.module.js +1 -1
- package/dist/components/date-input/DateInput.css +9 -7
- package/dist/components/date-input/DateInput.d.ts +12 -7
- package/dist/components/date-input/DateInput.js +35 -14
- package/dist/components/date-input/DateInput.module.js +6 -6
- package/dist/components/date-input/index.d.ts +2 -2
- package/dist/components/date-picker/DatePicker.css +68 -40
- package/dist/components/date-picker/DatePicker.d.ts +30 -2
- package/dist/components/date-picker/DatePicker.js +94 -9
- package/dist/components/date-picker/DatePicker.module.js +23 -23
- package/dist/components/date-picker/index.d.ts +2 -2
- package/dist/components/dialog/Dialog.css +31 -27
- package/dist/components/dialog/Dialog.d.ts +2 -2
- package/dist/components/dialog/Dialog.js +3 -3
- package/dist/components/dialog/Dialog.module.js +15 -15
- package/dist/components/dialog/index.d.ts +2 -2
- package/dist/components/drawer/Drawer.css +40 -40
- package/dist/components/drawer/Drawer.d.ts +2 -2
- package/dist/components/drawer/Drawer.js +3 -3
- package/dist/components/drawer/Drawer.module.js +26 -26
- package/dist/components/drawer/index.d.ts +2 -2
- package/dist/components/editable/Editable.css +10 -10
- package/dist/components/editable/Editable.d.ts +9 -2
- package/dist/components/editable/Editable.js +14 -5
- package/dist/components/editable/Editable.module.js +7 -7
- package/dist/components/editable/index.d.ts +2 -2
- package/dist/components/empty/Empty.css +6 -6
- package/dist/components/empty/Empty.js +1 -1
- package/dist/components/empty/Empty.module.js +6 -6
- package/dist/components/field/Field.css +8 -12
- package/dist/components/field/Field.d.ts +3 -2
- package/dist/components/field/Field.js +6 -5
- package/dist/components/field/Field.module.js +8 -9
- package/dist/components/field/index.d.ts +2 -2
- package/dist/components/fieldset/Fieldset.css +6 -6
- package/dist/components/fieldset/Fieldset.d.ts +2 -2
- package/dist/components/fieldset/Fieldset.js +3 -3
- package/dist/components/fieldset/Fieldset.module.js +4 -4
- package/dist/components/fieldset/index.d.ts +2 -2
- package/dist/components/file-upload/FileUpload.css +97 -24
- package/dist/components/file-upload/FileUpload.d.ts +22 -5
- package/dist/components/file-upload/FileUpload.js +79 -21
- package/dist/components/file-upload/FileUpload.module.js +16 -13
- package/dist/components/file-upload/index.d.ts +2 -2
- package/dist/components/floating-panel/FloatingPanel.css +28 -24
- package/dist/components/floating-panel/FloatingPanel.d.ts +11 -3
- package/dist/components/floating-panel/FloatingPanel.js +15 -9
- package/dist/components/floating-panel/FloatingPanel.module.js +14 -14
- package/dist/components/heading/Heading.css +1 -1
- package/dist/components/heading/Heading.js +1 -1
- package/dist/components/heading/Heading.module.js +1 -1
- package/dist/components/highlight/Highlight.css +1 -1
- package/dist/components/highlight/Highlight.js +1 -1
- package/dist/components/highlight/Highlight.module.js +1 -1
- package/dist/components/hover-card/HoverCard.css +21 -17
- package/dist/components/hover-card/HoverCard.d.ts +3 -2
- package/dist/components/hover-card/HoverCard.js +5 -4
- package/dist/components/hover-card/HoverCard.module.js +7 -7
- package/dist/components/hover-card/index.d.ts +2 -2
- package/dist/components/image/Image.css +7 -0
- package/dist/components/image/Image.d.ts +12 -0
- package/dist/components/image/Image.js +28 -0
- package/dist/components/image/Image.module.js +5 -0
- package/dist/components/image/index.d.ts +2 -0
- package/dist/components/image-cropper/ImageCropper.css +6 -6
- package/dist/components/image-cropper/ImageCropper.d.ts +7 -2
- package/dist/components/image-cropper/ImageCropper.js +25 -3
- package/dist/components/image-cropper/ImageCropper.module.js +6 -6
- package/dist/components/image-cropper/index.d.ts +2 -2
- package/dist/components/input/Input.css +1 -1
- package/dist/components/input/Input.js +1 -1
- package/dist/components/input/Input.module.js +1 -1
- package/dist/components/input-group/InputGroup.css +6 -6
- package/dist/components/input-group/InputGroup.d.ts +3 -0
- package/dist/components/input-group/InputGroup.js +1 -1
- package/dist/components/input-group/InputGroup.module.js +5 -5
- package/dist/components/kbd/Kbd.css +2 -2
- package/dist/components/kbd/Kbd.js +1 -1
- package/dist/components/kbd/Kbd.module.js +2 -2
- package/dist/components/lightbox/Lightbox.css +30 -28
- package/dist/components/lightbox/Lightbox.d.ts +4 -2
- package/dist/components/lightbox/Lightbox.js +9 -7
- package/dist/components/lightbox/Lightbox.module.js +16 -16
- package/dist/components/lightbox/index.d.ts +2 -2
- package/dist/components/list/List.css +1 -1
- package/dist/components/list/List.js +1 -1
- package/dist/components/list/List.module.js +1 -1
- package/dist/components/listbox/Listbox.css +76 -17
- package/dist/components/listbox/Listbox.d.ts +14 -2
- package/dist/components/listbox/Listbox.js +41 -5
- package/dist/components/listbox/Listbox.module.js +17 -14
- package/dist/components/listbox/index.d.ts +2 -2
- package/dist/components/marquee/Marquee.css +10 -10
- package/dist/components/marquee/Marquee.d.ts +2 -1
- package/dist/components/marquee/Marquee.js +4 -3
- package/dist/components/marquee/Marquee.module.js +7 -7
- package/dist/components/marquee/index.d.ts +2 -2
- package/dist/components/menu/Menu.css +46 -40
- package/dist/components/menu/Menu.d.ts +3 -2
- package/dist/components/menu/Menu.js +6 -5
- package/dist/components/menu/Menu.module.js +27 -27
- package/dist/components/menu/index.d.ts +2 -2
- package/dist/components/native-select/NativeSelect.css +5 -5
- package/dist/components/native-select/NativeSelect.d.ts +6 -2
- package/dist/components/native-select/NativeSelect.js +5 -4
- package/dist/components/native-select/NativeSelect.module.js +3 -3
- package/dist/components/number-input/NumberInput.css +11 -17
- package/dist/components/number-input/NumberInput.d.ts +7 -2
- package/dist/components/number-input/NumberInput.js +17 -4
- package/dist/components/number-input/NumberInput.module.js +8 -8
- package/dist/components/number-input/index.d.ts +2 -2
- package/dist/components/pagination/Pagination.css +8 -8
- package/dist/components/pagination/Pagination.d.ts +4 -0
- package/dist/components/pagination/Pagination.js +13 -4
- package/dist/components/pagination/Pagination.module.js +6 -6
- package/dist/components/password-input/PasswordInput.css +7 -7
- package/dist/components/password-input/PasswordInput.d.ts +4 -0
- package/dist/components/password-input/PasswordInput.js +10 -2
- package/dist/components/password-input/PasswordInput.module.js +6 -6
- package/dist/components/pin-input/PinInput.css +5 -5
- package/dist/components/pin-input/PinInput.d.ts +6 -1
- package/dist/components/pin-input/PinInput.js +25 -16
- package/dist/components/pin-input/PinInput.module.js +5 -5
- package/dist/components/popover/Popover.css +33 -24
- package/dist/components/popover/Popover.js +1 -1
- package/dist/components/popover/Popover.module.js +14 -14
- package/dist/components/progress-circular/ProgressCircular.css +8 -8
- package/dist/components/progress-circular/ProgressCircular.d.ts +6 -0
- package/dist/components/progress-circular/ProgressCircular.js +14 -3
- package/dist/components/progress-circular/ProgressCircular.module.js +8 -8
- package/dist/components/progress-linear/ProgressLinear.css +8 -8
- package/dist/components/progress-linear/ProgressLinear.d.ts +3 -0
- package/dist/components/progress-linear/ProgressLinear.js +6 -3
- package/dist/components/progress-linear/ProgressLinear.module.js +8 -8
- package/dist/components/qr-code/QrCode.css +13 -12
- package/dist/components/qr-code/QrCode.d.ts +2 -2
- package/dist/components/qr-code/QrCode.js +3 -3
- package/dist/components/qr-code/QrCode.module.js +5 -5
- package/dist/components/qr-code/index.d.ts +2 -2
- package/dist/components/radio-group/RadioGroup.css +6 -6
- package/dist/components/radio-group/RadioGroup.d.ts +8 -4
- package/dist/components/radio-group/RadioGroup.js +22 -14
- package/dist/components/radio-group/RadioGroup.module.js +6 -6
- package/dist/components/radio-group/index.d.ts +2 -2
- package/dist/components/rating-group/RatingGroup.css +14 -14
- package/dist/components/rating-group/RatingGroup.d.ts +11 -4
- package/dist/components/rating-group/RatingGroup.js +29 -18
- package/dist/components/rating-group/RatingGroup.module.js +7 -7
- package/dist/components/rating-group/index.d.ts +2 -2
- package/dist/components/scroll-area/ScrollArea.css +14 -9
- package/dist/components/scroll-area/ScrollArea.d.ts +3 -0
- package/dist/components/scroll-area/ScrollArea.js +9 -6
- package/dist/components/scroll-area/ScrollArea.module.js +6 -6
- package/dist/components/segment-group/SegmentGroup.css +6 -6
- package/dist/components/segment-group/SegmentGroup.d.ts +13 -3
- package/dist/components/segment-group/SegmentGroup.js +23 -15
- package/dist/components/segment-group/SegmentGroup.module.js +6 -6
- package/dist/components/segment-group/index.d.ts +2 -2
- package/dist/components/select/Select.css +49 -40
- package/dist/components/select/Select.d.ts +18 -4
- package/dist/components/select/Select.js +65 -20
- package/dist/components/select/Select.module.js +21 -21
- package/dist/components/separator/Separator.css +1 -1
- package/dist/components/separator/Separator.js +1 -1
- package/dist/components/separator/Separator.module.js +1 -1
- package/dist/components/sidebar/Sidebar.css +169 -32
- package/dist/components/sidebar/Sidebar.d.ts +26 -0
- package/dist/components/sidebar/Sidebar.js +105 -13
- package/dist/components/sidebar/Sidebar.module.js +23 -17
- package/dist/components/signature-pad/SignaturePad.css +18 -47
- package/dist/components/signature-pad/SignaturePad.d.ts +14 -6
- package/dist/components/signature-pad/SignaturePad.js +56 -17
- package/dist/components/signature-pad/SignaturePad.module.js +6 -6
- package/dist/components/signature-pad/index.d.ts +2 -2
- package/dist/components/simple-grid/SimpleGrid.js +3 -3
- package/dist/components/skeleton/Skeleton.css +1 -1
- package/dist/components/skeleton/Skeleton.js +1 -1
- package/dist/components/skeleton/Skeleton.module.js +1 -1
- package/dist/components/slider/Slider.css +16 -14
- package/dist/components/slider/Slider.d.ts +12 -3
- package/dist/components/slider/Slider.js +24 -15
- package/dist/components/slider/Slider.module.js +10 -10
- package/dist/components/slider/index.d.ts +2 -2
- package/dist/components/spinner/Spinner.css +9 -9
- package/dist/components/spinner/Spinner.js +2 -2
- package/dist/components/spinner/Spinner.module.js +3 -3
- package/dist/components/split-button/SplitButton.css +9 -9
- package/dist/components/split-button/SplitButton.d.ts +1 -1
- package/dist/components/split-button/SplitButton.js +3 -4
- package/dist/components/split-button/SplitButton.module.js +3 -3
- package/dist/components/splitter/Splitter.css +27 -22
- package/dist/components/splitter/Splitter.d.ts +2 -2
- package/dist/components/splitter/Splitter.js +12 -11
- package/dist/components/splitter/Splitter.module.js +4 -4
- package/dist/components/splitter/index.d.ts +2 -2
- package/dist/components/stack/Stack.css +2 -2
- package/dist/components/stack/Stack.d.ts +1 -3
- package/dist/components/stack/Stack.js +4 -6
- package/dist/components/stack/Stack.module.js +1 -1
- package/dist/components/steps/Steps.css +14 -14
- package/dist/components/steps/Steps.d.ts +2 -1
- package/dist/components/steps/Steps.js +5 -4
- package/dist/components/steps/Steps.module.js +11 -11
- package/dist/components/swap/Swap.css +45 -0
- package/dist/components/swap/Swap.d.ts +11 -0
- package/dist/components/swap/Swap.js +39 -0
- package/dist/components/swap/Swap.module.js +11 -0
- package/dist/components/swap/index.d.ts +2 -0
- package/dist/components/switch/Switch.css +11 -11
- package/dist/components/switch/Switch.d.ts +4 -4
- package/dist/components/switch/Switch.js +19 -16
- package/dist/components/switch/Switch.module.js +4 -4
- package/dist/components/switch/index.d.ts +2 -2
- package/dist/components/table/Table.css +18 -18
- package/dist/components/table/Table.js +3 -2
- package/dist/components/table/Table.module.js +11 -12
- package/dist/components/tabs/Tabs.css +12 -10
- package/dist/components/tabs/Tabs.d.ts +3 -2
- package/dist/components/tabs/Tabs.js +5 -4
- package/dist/components/tabs/Tabs.module.js +5 -5
- package/dist/components/tabs/index.d.ts +2 -2
- package/dist/components/tag/Tag.css +16 -46
- package/dist/components/tag/Tag.js +7 -20
- package/dist/components/tag/Tag.module.js +5 -5
- package/dist/components/tags-input/TagsInput.css +13 -50
- package/dist/components/tags-input/TagsInput.d.ts +7 -4
- package/dist/components/tags-input/TagsInput.js +33 -21
- package/dist/components/tags-input/TagsInput.module.js +10 -10
- package/dist/components/tags-input/index.d.ts +2 -2
- package/dist/components/text/Text.css +1 -1
- package/dist/components/text/Text.d.ts +2 -2
- package/dist/components/text/Text.js +1 -1
- package/dist/components/text/Text.module.js +1 -1
- package/dist/components/textarea/Textarea.css +7 -7
- package/dist/components/textarea/Textarea.js +1 -1
- package/dist/components/textarea/Textarea.module.js +1 -1
- package/dist/components/timer/Timer.css +6 -6
- package/dist/components/timer/Timer.d.ts +14 -2
- package/dist/components/timer/Timer.js +13 -5
- package/dist/components/timer/Timer.module.js +6 -6
- package/dist/components/timer/index.d.ts +2 -2
- package/dist/components/toast/Toast.css +8 -8
- package/dist/components/toast/Toast.d.ts +3 -1
- package/dist/components/toast/Toast.js +11 -2
- package/dist/components/toast/Toast.module.js +6 -6
- package/dist/components/toggle/Toggle.css +5 -5
- package/dist/components/toggle/Toggle.d.ts +3 -2
- package/dist/components/toggle/Toggle.js +5 -4
- package/dist/components/toggle/Toggle.module.js +2 -2
- package/dist/components/toggle/index.d.ts +2 -2
- package/dist/components/toggle-group/ToggleGroup.css +3 -3
- package/dist/components/toggle-group/ToggleGroup.d.ts +3 -2
- package/dist/components/toggle-group/ToggleGroup.js +4 -3
- package/dist/components/toggle-group/ToggleGroup.module.js +2 -2
- package/dist/components/toggle-group/index.d.ts +2 -2
- package/dist/components/tooltip/Tooltip.css +21 -17
- package/dist/components/tooltip/Tooltip.d.ts +3 -2
- package/dist/components/tooltip/Tooltip.js +10 -3
- package/dist/components/tooltip/Tooltip.module.js +7 -7
- package/dist/components/tooltip/index.d.ts +2 -2
- package/dist/components/tour/Tour.css +42 -37
- package/dist/components/tour/Tour.d.ts +6 -0
- package/dist/components/tour/Tour.js +8 -1
- package/dist/components/tour/Tour.module.js +17 -17
- package/dist/components/tree-view/TreeView.css +22 -22
- package/dist/components/tree-view/TreeView.d.ts +2 -2
- package/dist/components/tree-view/TreeView.js +4 -4
- package/dist/components/tree-view/TreeView.module.js +20 -20
- package/dist/components/tree-view/index.d.ts +2 -2
- package/dist/index.d.ts +40 -39
- package/dist/index.js +40 -39
- package/dist/lib/moduix/icons/ui/Icons.d.ts +1 -45
- package/dist/lib/moduix/icons/ui/Icons.js +36 -263
- package/dist/lib/moduix/icons/ui/index.d.ts +2 -2
- package/dist/lib/moduix/overlayPortal.js +1 -1
- package/package.json +4 -3
|
@@ -1,16 +1,18 @@
|
|
|
1
1
|
import { normalizeClassName } from "../../lib/moduix/normalizeClassName.js";
|
|
2
2
|
import AngleSlider_module_default from "./AngleSlider.module.js";
|
|
3
|
-
import { jsx } from "react/jsx-runtime";
|
|
4
3
|
import { clsx } from "clsx";
|
|
5
|
-
import { forwardRef } from "react";
|
|
6
|
-
import {
|
|
4
|
+
import { Children, cloneElement, forwardRef } from "react";
|
|
5
|
+
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
6
|
+
import { AngleSlider, useAngleSlider } from "@ark-ui/react/angle-slider";
|
|
7
7
|
//#region src/components/angle-slider/AngleSlider.tsx
|
|
8
|
-
const AngleSliderRoot = forwardRef(function AngleSliderRoot({ className, ...props }, ref) {
|
|
8
|
+
const AngleSliderRoot = forwardRef(function AngleSliderRoot({ asChild, children, className, ...props }, ref) {
|
|
9
9
|
return /* @__PURE__ */ jsx(AngleSlider.Root, {
|
|
10
10
|
ref,
|
|
11
11
|
"data-slot": "angle-slider-root",
|
|
12
12
|
className: clsx(AngleSlider_module_default.root, normalizeClassName(className)),
|
|
13
|
-
|
|
13
|
+
asChild,
|
|
14
|
+
...props,
|
|
15
|
+
children: withHiddenInput(children, asChild)
|
|
14
16
|
});
|
|
15
17
|
});
|
|
16
18
|
const AngleSliderLabel = forwardRef(function AngleSliderLabel({ className, ...props }, ref) {
|
|
@@ -21,14 +23,22 @@ const AngleSliderLabel = forwardRef(function AngleSliderLabel({ className, ...pr
|
|
|
21
23
|
...props
|
|
22
24
|
});
|
|
23
25
|
});
|
|
24
|
-
const AngleSliderRootProvider = forwardRef(function AngleSliderRootProvider({ className, ...props }, ref) {
|
|
26
|
+
const AngleSliderRootProvider = forwardRef(function AngleSliderRootProvider({ asChild, children, className, ...props }, ref) {
|
|
25
27
|
return /* @__PURE__ */ jsx(AngleSlider.RootProvider, {
|
|
26
28
|
ref,
|
|
27
29
|
"data-slot": "angle-slider-root-provider",
|
|
28
30
|
className: clsx(AngleSlider_module_default.root, normalizeClassName(className)),
|
|
29
|
-
|
|
31
|
+
asChild,
|
|
32
|
+
...props,
|
|
33
|
+
children: withHiddenInput(children, asChild)
|
|
30
34
|
});
|
|
31
35
|
});
|
|
36
|
+
function withHiddenInput(children, asChild) {
|
|
37
|
+
const hiddenInput = /* @__PURE__ */ jsx(AngleSlider.HiddenInput, { "data-slot": "angle-slider-hidden-input" });
|
|
38
|
+
if (!asChild) return /* @__PURE__ */ jsxs(Fragment$1, { children: [children, hiddenInput] });
|
|
39
|
+
const child = Children.only(children);
|
|
40
|
+
return cloneElement(child, {}, child.props.children, hiddenInput);
|
|
41
|
+
}
|
|
32
42
|
const AngleSliderControl = forwardRef(function AngleSliderControl({ className, ...props }, ref) {
|
|
33
43
|
return /* @__PURE__ */ jsx(AngleSlider.Control, {
|
|
34
44
|
ref,
|
|
@@ -61,6 +71,18 @@ const AngleSliderMarker = forwardRef(function AngleSliderMarker({ className, ...
|
|
|
61
71
|
...props
|
|
62
72
|
});
|
|
63
73
|
});
|
|
74
|
+
function AngleSliderMarks({ values, ...props }) {
|
|
75
|
+
return /* @__PURE__ */ jsx(AngleSliderMarkerGroup, {
|
|
76
|
+
...props,
|
|
77
|
+
children: values.map((value) => /* @__PURE__ */ jsx(AngleSliderMarker, { value }, value))
|
|
78
|
+
});
|
|
79
|
+
}
|
|
80
|
+
function AngleSliderDial({ children, thumbClassName, ...props }) {
|
|
81
|
+
return /* @__PURE__ */ jsxs(AngleSliderControl, {
|
|
82
|
+
...props,
|
|
83
|
+
children: [children, /* @__PURE__ */ jsx(AngleSliderThumb, { className: thumbClassName })]
|
|
84
|
+
});
|
|
85
|
+
}
|
|
64
86
|
const AngleSliderValueText = forwardRef(function AngleSliderValueText({ className, ...props }, ref) {
|
|
65
87
|
return /* @__PURE__ */ jsx(AngleSlider.ValueText, {
|
|
66
88
|
ref,
|
|
@@ -69,24 +91,18 @@ const AngleSliderValueText = forwardRef(function AngleSliderValueText({ classNam
|
|
|
69
91
|
...props
|
|
70
92
|
});
|
|
71
93
|
});
|
|
72
|
-
const AngleSliderHiddenInput = forwardRef(function AngleSliderHiddenInput({ className, ...props }, ref) {
|
|
73
|
-
return /* @__PURE__ */ jsx(AngleSlider.HiddenInput, {
|
|
74
|
-
ref,
|
|
75
|
-
"data-slot": "angle-slider-hidden-input",
|
|
76
|
-
className: normalizeClassName(className),
|
|
77
|
-
...props
|
|
78
|
-
});
|
|
79
|
-
});
|
|
80
94
|
const AngleSlider$1 = Object.assign(AngleSliderRoot, {
|
|
81
95
|
Root: AngleSliderRoot,
|
|
82
96
|
RootProvider: AngleSliderRootProvider,
|
|
83
97
|
Label: AngleSliderLabel,
|
|
84
98
|
Control: AngleSliderControl,
|
|
99
|
+
Dial: AngleSliderDial,
|
|
85
100
|
Thumb: AngleSliderThumb,
|
|
86
101
|
MarkerGroup: AngleSliderMarkerGroup,
|
|
87
102
|
Marker: AngleSliderMarker,
|
|
88
|
-
|
|
89
|
-
|
|
103
|
+
Marks: AngleSliderMarks,
|
|
104
|
+
ValueText: AngleSliderValueText
|
|
90
105
|
});
|
|
106
|
+
const useAngleSlider$1 = useAngleSlider;
|
|
91
107
|
//#endregion
|
|
92
|
-
export { AngleSlider$1 as AngleSlider };
|
|
108
|
+
export { AngleSlider$1 as AngleSlider, useAngleSlider$1 as useAngleSlider };
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import './AngleSlider.css';
|
|
2
2
|
//#region src/components/angle-slider/AngleSlider.module.css
|
|
3
3
|
var AngleSlider_module_default = {
|
|
4
|
-
"control": "
|
|
5
|
-
"label": "
|
|
6
|
-
"marker": "
|
|
7
|
-
"markerGroup": "
|
|
8
|
-
"root": "
|
|
9
|
-
"thumb": "
|
|
10
|
-
"valueText": "
|
|
4
|
+
"control": "vn7zXa_control",
|
|
5
|
+
"label": "vn7zXa_label",
|
|
6
|
+
"marker": "vn7zXa_marker",
|
|
7
|
+
"markerGroup": "vn7zXa_markerGroup",
|
|
8
|
+
"root": "vn7zXa_root",
|
|
9
|
+
"thumb": "vn7zXa_thumb",
|
|
10
|
+
"valueText": "vn7zXa_valueText"
|
|
11
11
|
};
|
|
12
12
|
//#endregion
|
|
13
13
|
export { AngleSlider_module_default as default };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { AngleSlider } from "./AngleSlider.js";
|
|
2
|
-
export { AngleSlider };
|
|
1
|
+
import { AngleSlider, useAngleSlider } from "./AngleSlider.js";
|
|
2
|
+
export { AngleSlider, useAngleSlider };
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
@layer ui.components {
|
|
2
|
-
.
|
|
3
|
-
|
|
2
|
+
.iOVgxW_root {
|
|
3
|
+
--aspect-ratio-value: 1;
|
|
4
4
|
width: 100%;
|
|
5
|
+
aspect-ratio: var(--aspect-ratio-value);
|
|
6
|
+
border-radius: var(--aspect-ratio-radius, var(--radius-md));
|
|
5
7
|
position: relative;
|
|
6
8
|
overflow: hidden;
|
|
7
9
|
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { normalizeClassName } from "../../lib/moduix/normalizeClassName.js";
|
|
2
2
|
import AspectRatio_module_default from "./AspectRatio.module.js";
|
|
3
|
-
import { jsx } from "react/jsx-runtime";
|
|
4
3
|
import { ark } from "@ark-ui/react/factory";
|
|
5
4
|
import { clsx } from "clsx";
|
|
6
5
|
import { forwardRef } from "react";
|
|
6
|
+
import { jsx } from "react/jsx-runtime";
|
|
7
7
|
//#region src/components/aspect-ratio/AspectRatio.tsx
|
|
8
8
|
const AspectRatioRoot = forwardRef(function AspectRatioRoot({ ratio, className, style, ...props }, ref) {
|
|
9
9
|
return /* @__PURE__ */ jsx(ark.div, {
|
|
@@ -13,7 +13,7 @@ const AspectRatioRoot = forwardRef(function AspectRatioRoot({ ratio, className,
|
|
|
13
13
|
"data-slot": "aspect-ratio-root",
|
|
14
14
|
className: clsx(AspectRatio_module_default.root, normalizeClassName(className)),
|
|
15
15
|
style: {
|
|
16
|
-
|
|
16
|
+
"--aspect-ratio-value": ratio,
|
|
17
17
|
...style
|
|
18
18
|
},
|
|
19
19
|
...props
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import './AspectRatio.css';
|
|
2
2
|
//#region src/components/aspect-ratio/AspectRatio.module.css
|
|
3
|
-
var AspectRatio_module_default = { "root": "
|
|
3
|
+
var AspectRatio_module_default = { "root": "iOVgxW_root" };
|
|
4
4
|
//#endregion
|
|
5
5
|
export { AspectRatio_module_default as default };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
@layer ui.components {
|
|
2
|
-
.
|
|
2
|
+
.qCmyuq_root {
|
|
3
3
|
box-sizing: border-box;
|
|
4
4
|
width: var(--avatar-size, var(--size-md));
|
|
5
5
|
height: var(--avatar-size, var(--size-md));
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
}
|
|
44
44
|
}
|
|
45
45
|
|
|
46
|
-
.
|
|
46
|
+
.qCmyuq_image {
|
|
47
47
|
object-fit: var(--avatar-image-object-fit, cover);
|
|
48
48
|
object-position: var(--avatar-image-object-position, center);
|
|
49
49
|
border-radius: inherit;
|
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
}
|
|
57
57
|
}
|
|
58
58
|
|
|
59
|
-
.
|
|
59
|
+
.qCmyuq_fallback {
|
|
60
60
|
width: 100%;
|
|
61
61
|
height: 100%;
|
|
62
62
|
padding: var(--avatar-fallback-padding, 0);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ComponentProps } from "react";
|
|
2
|
-
import { Avatar } from "@ark-ui/react/avatar";
|
|
2
|
+
import { Avatar, useAvatar, useAvatarContext } from "@ark-ui/react/avatar";
|
|
3
3
|
|
|
4
4
|
//#region src/components/avatar/Avatar.d.ts
|
|
5
5
|
type AvatarSize = 'xs' | 'sm' | 'md' | 'lg' | 'xl';
|
|
@@ -9,11 +9,14 @@ type AvatarRootProps = ComponentProps<typeof Avatar.Root> & {
|
|
|
9
9
|
type AvatarRootProviderProps = ComponentProps<typeof Avatar.RootProvider> & {
|
|
10
10
|
size?: AvatarSize;
|
|
11
11
|
};
|
|
12
|
+
type AvatarFallbackProps = ComponentProps<typeof Avatar.Fallback> & {
|
|
13
|
+
name?: string;
|
|
14
|
+
};
|
|
12
15
|
declare const Avatar$1: import("react").ForwardRefExoticComponent<Omit<AvatarRootProps, "ref"> & import("react").RefAttributes<HTMLDivElement>> & {
|
|
13
16
|
Root: import("react").ForwardRefExoticComponent<Omit<AvatarRootProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
14
17
|
RootProvider: import("react").ForwardRefExoticComponent<Omit<AvatarRootProviderProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
15
18
|
Image: import("react").ForwardRefExoticComponent<Omit<Avatar.ImageProps & import("react").RefAttributes<HTMLImageElement>, "ref"> & import("react").RefAttributes<HTMLImageElement>>;
|
|
16
|
-
Fallback: import("react").ForwardRefExoticComponent<Omit<
|
|
19
|
+
Fallback: import("react").ForwardRefExoticComponent<Omit<AvatarFallbackProps, "ref"> & import("react").RefAttributes<HTMLSpanElement>>;
|
|
17
20
|
};
|
|
18
21
|
//#endregion
|
|
19
|
-
export { Avatar$1 as Avatar };
|
|
22
|
+
export { Avatar$1 as Avatar, useAvatar, useAvatarContext };
|
|
@@ -1,10 +1,16 @@
|
|
|
1
1
|
import { normalizeClassName } from "../../lib/moduix/normalizeClassName.js";
|
|
2
2
|
import Avatar_module_default from "./Avatar.module.js";
|
|
3
|
-
import { jsx } from "react/jsx-runtime";
|
|
4
3
|
import { clsx } from "clsx";
|
|
5
4
|
import { forwardRef } from "react";
|
|
6
|
-
import {
|
|
5
|
+
import { jsx } from "react/jsx-runtime";
|
|
6
|
+
import { Avatar, useAvatar, useAvatarContext } from "@ark-ui/react/avatar";
|
|
7
7
|
//#region src/components/avatar/Avatar.tsx
|
|
8
|
+
const getInitials = (name) => {
|
|
9
|
+
const parts = name.trim().split(/\s+/).filter(Boolean);
|
|
10
|
+
const firstName = parts[0] ?? "";
|
|
11
|
+
const lastName = parts.length > 1 ? parts[parts.length - 1] : "";
|
|
12
|
+
return firstName && lastName ? `${firstName[0]}${lastName[0]}` : firstName[0] ?? "";
|
|
13
|
+
};
|
|
8
14
|
const AvatarRoot = forwardRef(function AvatarRoot({ className, size, ...props }, ref) {
|
|
9
15
|
return /* @__PURE__ */ jsx(Avatar.Root, {
|
|
10
16
|
ref,
|
|
@@ -31,12 +37,13 @@ const AvatarImage = forwardRef(function AvatarImage({ className, ...props }, ref
|
|
|
31
37
|
...props
|
|
32
38
|
});
|
|
33
39
|
});
|
|
34
|
-
const AvatarFallback = forwardRef(function AvatarFallback({ className, ...props }, ref) {
|
|
40
|
+
const AvatarFallback = forwardRef(function AvatarFallback({ children, className, name, ...props }, ref) {
|
|
35
41
|
return /* @__PURE__ */ jsx(Avatar.Fallback, {
|
|
36
42
|
ref,
|
|
37
43
|
"data-slot": "avatar-fallback",
|
|
38
44
|
className: clsx(Avatar_module_default.fallback, normalizeClassName(className)),
|
|
39
|
-
...props
|
|
45
|
+
...props,
|
|
46
|
+
children: children ?? (name ? getInitials(name) : void 0)
|
|
40
47
|
});
|
|
41
48
|
});
|
|
42
49
|
const Avatar$1 = Object.assign(AvatarRoot, {
|
|
@@ -46,4 +53,4 @@ const Avatar$1 = Object.assign(AvatarRoot, {
|
|
|
46
53
|
Fallback: AvatarFallback
|
|
47
54
|
});
|
|
48
55
|
//#endregion
|
|
49
|
-
export { Avatar$1 as Avatar };
|
|
56
|
+
export { Avatar$1 as Avatar, useAvatar, useAvatarContext };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import './Avatar.css';
|
|
2
2
|
//#region src/components/avatar/Avatar.module.css
|
|
3
3
|
var Avatar_module_default = {
|
|
4
|
-
"fallback": "
|
|
5
|
-
"image": "
|
|
6
|
-
"root": "
|
|
4
|
+
"fallback": "qCmyuq_fallback",
|
|
5
|
+
"image": "qCmyuq_image",
|
|
6
|
+
"root": "qCmyuq_root"
|
|
7
7
|
};
|
|
8
8
|
//#endregion
|
|
9
9
|
export { Avatar_module_default as default };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { Avatar } from "./Avatar.js";
|
|
2
|
-
export { Avatar };
|
|
1
|
+
import { Avatar, useAvatar, useAvatarContext } from "./Avatar.js";
|
|
2
|
+
export { Avatar, useAvatar, useAvatarContext };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
@layer ui.components {
|
|
2
|
-
.
|
|
2
|
+
.NXa69G_root {
|
|
3
3
|
justify-content: center;
|
|
4
4
|
align-items: center;
|
|
5
5
|
gap: var(--badge-gap, .375rem);
|
|
@@ -29,6 +29,34 @@
|
|
|
29
29
|
display: inline-flex;
|
|
30
30
|
overflow: hidden;
|
|
31
31
|
|
|
32
|
+
&:is(a, button, [role="button"]) {
|
|
33
|
+
cursor: pointer;
|
|
34
|
+
|
|
35
|
+
&:focus-visible {
|
|
36
|
+
outline: var(--border-width-md) solid var(--color-ring);
|
|
37
|
+
outline-offset: var(--spacing-1);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
&[data-variant="default"], &[data-variant="secondary"], &[data-variant="destructive"] {
|
|
41
|
+
&:hover {
|
|
42
|
+
opacity: .9;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
&[data-variant="outline"], &[data-variant="ghost"] {
|
|
47
|
+
&:hover {
|
|
48
|
+
border-color: var(--badge-border-color, var(--color-primary));
|
|
49
|
+
color: var(--badge-color, var(--color-primary));
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
&[data-variant="link"] {
|
|
54
|
+
&:hover {
|
|
55
|
+
text-decoration-color: currentColor;
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
|
|
32
60
|
& > svg {
|
|
33
61
|
width: var(--badge-icon-size, .75rem);
|
|
34
62
|
height: var(--badge-icon-size, .75rem);
|
|
@@ -46,17 +74,32 @@
|
|
|
46
74
|
color: var(--badge-color, var(--color-primary-foreground));
|
|
47
75
|
}
|
|
48
76
|
|
|
49
|
-
&[data-variant="outline"], &[data-variant="ghost"] {
|
|
77
|
+
&[data-variant="outline"], &[data-variant="ghost"], &[data-variant="link"] {
|
|
50
78
|
background-color: var(--badge-bg, transparent);
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
&[data-variant="outline"], &[data-variant="ghost"] {
|
|
51
82
|
color: var(--badge-color, var(--color-foreground));
|
|
52
83
|
}
|
|
53
84
|
|
|
54
85
|
&[data-variant="outline"] {
|
|
55
86
|
border-color: var(--badge-border-color, var(--color-border));
|
|
56
87
|
}
|
|
88
|
+
|
|
89
|
+
&[data-variant="link"] {
|
|
90
|
+
min-height: auto;
|
|
91
|
+
color: var(--badge-color, var(--color-primary));
|
|
92
|
+
text-decoration: underline;
|
|
93
|
+
text-decoration-color: color-mix(in oklab, currentColor 55%, transparent);
|
|
94
|
+
text-underline-offset: .15em;
|
|
95
|
+
border-color: #0000;
|
|
96
|
+
padding-inline: 0;
|
|
97
|
+
text-decoration-thickness: from-font;
|
|
98
|
+
overflow: visible;
|
|
99
|
+
}
|
|
57
100
|
}
|
|
58
101
|
|
|
59
|
-
.
|
|
102
|
+
.NXa69G_dot {
|
|
60
103
|
width: var(--badge-dot-size, .375rem);
|
|
61
104
|
height: var(--badge-dot-size, .375rem);
|
|
62
105
|
background-color: currentColor;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
//#region src/components/badge/Badge.d.ts
|
|
2
2
|
declare const Badge: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & import("@ark-ui/react/factory").PolymorphicProps & {
|
|
3
|
-
variant?: "default" | "secondary" | "destructive" | "outline" | "ghost";
|
|
3
|
+
variant?: "default" | "secondary" | "destructive" | "outline" | "ghost" | "link";
|
|
4
4
|
} & import("react").RefAttributes<HTMLSpanElement>> & {
|
|
5
5
|
Root: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & import("@ark-ui/react/factory").PolymorphicProps & {
|
|
6
|
-
variant?: "default" | "secondary" | "destructive" | "outline" | "ghost";
|
|
6
|
+
variant?: "default" | "secondary" | "destructive" | "outline" | "ghost" | "link";
|
|
7
7
|
} & import("react").RefAttributes<HTMLSpanElement>>;
|
|
8
8
|
Dot: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & import("@ark-ui/react/factory").PolymorphicProps & import("react").RefAttributes<HTMLSpanElement>>;
|
|
9
9
|
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { normalizeClassName } from "../../lib/moduix/normalizeClassName.js";
|
|
2
2
|
import Badge_module_default from "./Badge.module.js";
|
|
3
|
-
import { jsx } from "react/jsx-runtime";
|
|
4
3
|
import { ark } from "@ark-ui/react/factory";
|
|
5
4
|
import { clsx } from "clsx";
|
|
6
5
|
import { forwardRef } from "react";
|
|
6
|
+
import { jsx } from "react/jsx-runtime";
|
|
7
7
|
//#region src/components/badge/Badge.tsx
|
|
8
8
|
const BadgeRoot = forwardRef(function BadgeRoot({ className, variant = "default", ...props }, ref) {
|
|
9
9
|
return /* @__PURE__ */ jsx(ark.span, {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import './Badge.css';
|
|
2
2
|
//#region src/components/badge/Badge.module.css
|
|
3
3
|
var Badge_module_default = {
|
|
4
|
-
"dot": "
|
|
5
|
-
"root": "
|
|
4
|
+
"dot": "NXa69G_dot",
|
|
5
|
+
"root": "NXa69G_root"
|
|
6
6
|
};
|
|
7
7
|
//#endregion
|
|
8
8
|
export { Badge_module_default as default };
|
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
//#region src/components/bleed/Bleed.d.ts
|
|
2
|
+
type BleedAmount = 'none' | 'xs' | 'sm' | 'md' | 'lg' | 'xl';
|
|
3
|
+
type BleedInline = BleedAmount | 'full';
|
|
2
4
|
declare const Bleed: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("@ark-ui/react/factory").PolymorphicProps & {
|
|
3
|
-
inline?:
|
|
4
|
-
block?:
|
|
5
|
+
inline?: BleedInline;
|
|
6
|
+
block?: BleedAmount;
|
|
5
7
|
} & import("react").RefAttributes<HTMLDivElement>> & {
|
|
6
8
|
Root: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("@ark-ui/react/factory").PolymorphicProps & {
|
|
7
|
-
inline?:
|
|
8
|
-
block?:
|
|
9
|
+
inline?: BleedInline;
|
|
10
|
+
block?: BleedAmount;
|
|
9
11
|
} & import("react").RefAttributes<HTMLDivElement>>;
|
|
10
12
|
};
|
|
11
13
|
//#endregion
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { normalizeClassName } from "../../lib/moduix/normalizeClassName.js";
|
|
2
2
|
import Bleed_module_default from "./Bleed.module.js";
|
|
3
|
-
import { jsx } from "react/jsx-runtime";
|
|
4
3
|
import { ark } from "@ark-ui/react/factory";
|
|
5
4
|
import { clsx } from "clsx";
|
|
6
5
|
import { forwardRef } from "react";
|
|
6
|
+
import { jsx } from "react/jsx-runtime";
|
|
7
7
|
//#region src/components/bleed/Bleed.tsx
|
|
8
8
|
const BleedRoot = forwardRef(function BleedRoot({ inline = "full", block = "none", className, ...props }, ref) {
|
|
9
9
|
return /* @__PURE__ */ jsx(ark.div, {
|
|
10
10
|
ref,
|
|
11
|
+
...props,
|
|
11
12
|
"data-scope": "bleed",
|
|
12
13
|
"data-part": "root",
|
|
13
14
|
"data-slot": "bleed-root",
|
|
14
15
|
"data-inline": inline,
|
|
15
16
|
"data-block": block,
|
|
16
|
-
className: clsx(Bleed_module_default.root, normalizeClassName(className))
|
|
17
|
-
...props
|
|
17
|
+
className: clsx(Bleed_module_default.root, normalizeClassName(className))
|
|
18
18
|
});
|
|
19
19
|
});
|
|
20
20
|
const Bleed = Object.assign(BleedRoot, { Root: BleedRoot });
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
@layer ui.components {
|
|
2
|
-
.
|
|
2
|
+
.WoRWWa_root[data-scope="breadcrumbs"][data-part="root"] {
|
|
3
3
|
max-width: var(--breadcrumbs-max-width, 100%);
|
|
4
4
|
color: var(--breadcrumbs-color, var(--color-muted-foreground));
|
|
5
5
|
font-size: var(--breadcrumbs-font-size, var(--text-sm));
|
|
6
6
|
line-height: var(--breadcrumbs-line-height, var(--line-height-text-sm));
|
|
7
7
|
}
|
|
8
8
|
|
|
9
|
-
.
|
|
9
|
+
.WoRWWa_list[data-scope="breadcrumbs"][data-part="list"] {
|
|
10
10
|
align-items: center;
|
|
11
11
|
gap: var(--breadcrumbs-gap, var(--spacing-1));
|
|
12
12
|
white-space: nowrap;
|
|
@@ -16,20 +16,20 @@
|
|
|
16
16
|
list-style: none;
|
|
17
17
|
display: flex;
|
|
18
18
|
|
|
19
|
-
& > .
|
|
19
|
+
& > .WoRWWa_item:last-child {
|
|
20
20
|
max-width: var(--breadcrumbs-item-max-width, 16rem);
|
|
21
21
|
flex: auto;
|
|
22
22
|
}
|
|
23
23
|
}
|
|
24
24
|
|
|
25
|
-
.
|
|
26
|
-
flex:
|
|
25
|
+
.WoRWWa_item[data-scope="breadcrumbs"][data-part="item"] {
|
|
26
|
+
flex: 0 auto;
|
|
27
27
|
align-items: center;
|
|
28
28
|
min-width: 0;
|
|
29
29
|
display: inline-flex;
|
|
30
30
|
}
|
|
31
31
|
|
|
32
|
-
.
|
|
32
|
+
.WoRWWa_link[data-scope="breadcrumbs"][data-part="link"], .WoRWWa_page[data-scope="breadcrumbs"][data-part="page"] {
|
|
33
33
|
min-width: 0;
|
|
34
34
|
max-width: 100%;
|
|
35
35
|
padding-inline: var(--breadcrumbs-item-padding-x, .25rem);
|
|
@@ -37,12 +37,12 @@
|
|
|
37
37
|
display: block;
|
|
38
38
|
}
|
|
39
39
|
|
|
40
|
-
.
|
|
40
|
+
.WoRWWa_link[data-scope="breadcrumbs"][data-part="link"], .WoRWWa_page[data-scope="breadcrumbs"][data-part="page"], .WoRWWa_ellipsis[data-scope="breadcrumbs"][data-part="ellipsis"] {
|
|
41
41
|
text-overflow: ellipsis;
|
|
42
42
|
overflow: hidden;
|
|
43
43
|
}
|
|
44
44
|
|
|
45
|
-
.
|
|
45
|
+
.WoRWWa_link[data-scope="breadcrumbs"][data-part="link"] {
|
|
46
46
|
color: var(--breadcrumbs-link-color, var(--color-muted-foreground));
|
|
47
47
|
text-decoration: var(--breadcrumbs-link-text-decoration, none);
|
|
48
48
|
text-underline-offset: var(--breadcrumbs-link-underline-offset, .2em);
|
|
@@ -63,12 +63,12 @@
|
|
|
63
63
|
}
|
|
64
64
|
}
|
|
65
65
|
|
|
66
|
-
.
|
|
66
|
+
.WoRWWa_page[data-scope="breadcrumbs"][data-part="page"] {
|
|
67
67
|
color: var(--breadcrumbs-page-color, var(--color-foreground));
|
|
68
68
|
font-weight: var(--breadcrumbs-page-font-weight, var(--weight-medium));
|
|
69
69
|
}
|
|
70
70
|
|
|
71
|
-
.
|
|
71
|
+
.WoRWWa_separator[data-scope="breadcrumbs"][data-part="separator"] {
|
|
72
72
|
color: var(--breadcrumbs-separator-color, var(--color-muted-foreground));
|
|
73
73
|
font-size: var(--breadcrumbs-separator-font-size, .875em);
|
|
74
74
|
user-select: none;
|
|
@@ -77,7 +77,13 @@
|
|
|
77
77
|
display: inline-flex;
|
|
78
78
|
}
|
|
79
79
|
|
|
80
|
-
.
|
|
80
|
+
.WoRWWa_separatorIcon {
|
|
81
|
+
flex: none;
|
|
82
|
+
width: 1em;
|
|
83
|
+
height: 1em;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
.WoRWWa_ellipsis[data-scope="breadcrumbs"][data-part="ellipsis"] {
|
|
81
87
|
min-width: var(--breadcrumbs-ellipsis-size, 1rem);
|
|
82
88
|
min-height: var(--breadcrumbs-ellipsis-size, 1rem);
|
|
83
89
|
padding-inline: var(--breadcrumbs-item-padding-x, .25rem);
|
|
@@ -1,9 +1,27 @@
|
|
|
1
|
+
import { HTMLArkProps } from "@ark-ui/react/factory";
|
|
2
|
+
import { Key, ReactNode } from "react";
|
|
3
|
+
|
|
1
4
|
//#region src/components/breadcrumbs/Breadcrumbs.d.ts
|
|
5
|
+
type BreadcrumbsPathItem = {
|
|
6
|
+
href?: string;
|
|
7
|
+
key?: Key;
|
|
8
|
+
label: ReactNode;
|
|
9
|
+
};
|
|
10
|
+
type BreadcrumbsPathProps = Omit<HTMLArkProps<'ol'>, 'children'> & {
|
|
11
|
+
items: readonly BreadcrumbsPathItem[];
|
|
12
|
+
separator?: ReactNode;
|
|
13
|
+
};
|
|
14
|
+
declare function BreadcrumbsPath({
|
|
15
|
+
items,
|
|
16
|
+
separator,
|
|
17
|
+
...props
|
|
18
|
+
}: BreadcrumbsPathProps): import("react").JSX.Element;
|
|
2
19
|
declare const Breadcrumbs: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & import("@ark-ui/react/factory").PolymorphicProps & import("react").RefAttributes<HTMLElement>> & {
|
|
3
20
|
Root: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & import("@ark-ui/react/factory").PolymorphicProps & import("react").RefAttributes<HTMLElement>>;
|
|
4
21
|
List: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").OlHTMLAttributes<HTMLOListElement>, HTMLOListElement>, "ref"> & import("@ark-ui/react/factory").PolymorphicProps & import("react").RefAttributes<HTMLOListElement>>;
|
|
5
22
|
Item: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & import("@ark-ui/react/factory").PolymorphicProps & import("react").RefAttributes<HTMLLIElement>>;
|
|
6
23
|
Link: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, "ref"> & import("@ark-ui/react/factory").PolymorphicProps & import("react").RefAttributes<HTMLAnchorElement>>;
|
|
24
|
+
Path: typeof BreadcrumbsPath;
|
|
7
25
|
Page: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & import("@ark-ui/react/factory").PolymorphicProps & import("react").RefAttributes<HTMLSpanElement>>;
|
|
8
26
|
Separator: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & import("@ark-ui/react/factory").PolymorphicProps & import("react").RefAttributes<HTMLLIElement>>;
|
|
9
27
|
Ellipsis: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & import("@ark-ui/react/factory").PolymorphicProps & import("react").RefAttributes<HTMLSpanElement>>;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { normalizeClassName } from "../../lib/moduix/normalizeClassName.js";
|
|
2
|
+
import { ChevronRightIcon } from "../../lib/moduix/icons/ui/Icons.js";
|
|
2
3
|
import Breadcrumbs_module_default from "./Breadcrumbs.module.js";
|
|
3
|
-
import { jsx } from "react/jsx-runtime";
|
|
4
4
|
import { ark } from "@ark-ui/react/factory";
|
|
5
5
|
import { clsx } from "clsx";
|
|
6
|
-
import { forwardRef } from "react";
|
|
6
|
+
import { Fragment, forwardRef } from "react";
|
|
7
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
7
8
|
//#region src/components/breadcrumbs/Breadcrumbs.tsx
|
|
8
9
|
const BreadcrumbsRoot = forwardRef(function BreadcrumbsRoot({ className, "aria-label": ariaLabel = "Breadcrumb", ...props }, ref) {
|
|
9
10
|
return /* @__PURE__ */ jsx(ark.nav, {
|
|
@@ -57,7 +58,19 @@ const BreadcrumbsPage = forwardRef(function BreadcrumbsPage({ className, ...prop
|
|
|
57
58
|
...props
|
|
58
59
|
});
|
|
59
60
|
});
|
|
60
|
-
|
|
61
|
+
function BreadcrumbsPath({ items, separator, ...props }) {
|
|
62
|
+
return /* @__PURE__ */ jsx(BreadcrumbsList, {
|
|
63
|
+
...props,
|
|
64
|
+
children: items.map((item, index) => {
|
|
65
|
+
const isLastItem = index === items.length - 1;
|
|
66
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(BreadcrumbsItem, { children: item.href && !isLastItem ? /* @__PURE__ */ jsx(BreadcrumbsLink, {
|
|
67
|
+
href: item.href,
|
|
68
|
+
children: item.label
|
|
69
|
+
}) : /* @__PURE__ */ jsx(BreadcrumbsPage, { children: item.label }) }), !isLastItem ? /* @__PURE__ */ jsx(BreadcrumbsSeparator, { children: separator }) : null] }, item.key ?? item.href ?? index);
|
|
70
|
+
})
|
|
71
|
+
});
|
|
72
|
+
}
|
|
73
|
+
const BreadcrumbsSeparator = forwardRef(function BreadcrumbsSeparator({ className, children, role = "presentation", ...props }, ref) {
|
|
61
74
|
return /* @__PURE__ */ jsx(ark.li, {
|
|
62
75
|
ref,
|
|
63
76
|
"data-scope": "breadcrumbs",
|
|
@@ -67,7 +80,7 @@ const BreadcrumbsSeparator = forwardRef(function BreadcrumbsSeparator({ classNam
|
|
|
67
80
|
role,
|
|
68
81
|
className: clsx(Breadcrumbs_module_default.separator, normalizeClassName(className)),
|
|
69
82
|
...props,
|
|
70
|
-
children
|
|
83
|
+
children: children ?? /* @__PURE__ */ jsx(ChevronRightIcon, { className: Breadcrumbs_module_default.separatorIcon })
|
|
71
84
|
});
|
|
72
85
|
});
|
|
73
86
|
const BreadcrumbsEllipsis = forwardRef(function BreadcrumbsEllipsis({ className, children = "...", ...props }, ref) {
|
|
@@ -87,6 +100,7 @@ const Breadcrumbs = Object.assign(BreadcrumbsRoot, {
|
|
|
87
100
|
List: BreadcrumbsList,
|
|
88
101
|
Item: BreadcrumbsItem,
|
|
89
102
|
Link: BreadcrumbsLink,
|
|
103
|
+
Path: BreadcrumbsPath,
|
|
90
104
|
Page: BreadcrumbsPage,
|
|
91
105
|
Separator: BreadcrumbsSeparator,
|
|
92
106
|
Ellipsis: BreadcrumbsEllipsis
|
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
import './Breadcrumbs.css';
|
|
2
2
|
//#region src/components/breadcrumbs/Breadcrumbs.module.css
|
|
3
3
|
var Breadcrumbs_module_default = {
|
|
4
|
-
"ellipsis": "
|
|
5
|
-
"item": "
|
|
6
|
-
"link": "
|
|
7
|
-
"list": "
|
|
8
|
-
"page": "
|
|
9
|
-
"root": "
|
|
10
|
-
"separator": "
|
|
4
|
+
"ellipsis": "WoRWWa_ellipsis",
|
|
5
|
+
"item": "WoRWWa_item",
|
|
6
|
+
"link": "WoRWWa_link",
|
|
7
|
+
"list": "WoRWWa_list",
|
|
8
|
+
"page": "WoRWWa_page",
|
|
9
|
+
"root": "WoRWWa_root",
|
|
10
|
+
"separator": "WoRWWa_separator",
|
|
11
|
+
"separatorIcon": "WoRWWa_separatorIcon"
|
|
11
12
|
};
|
|
12
13
|
//#endregion
|
|
13
14
|
export { Breadcrumbs_module_default as default };
|