@moduix/react 1.1.1 → 2.1.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 +105 -177
- package/dist/components/accordion/Accordion.css +12 -5
- package/dist/components/accordion/Accordion.d.ts +3 -2
- package/dist/components/accordion/Accordion.js +17 -5
- package/dist/components/accordion/Accordion.module.js +1 -0
- 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 +1 -0
- package/dist/components/angle-slider/AngleSlider.css +9 -9
- package/dist/components/angle-slider/AngleSlider.d.ts +18 -2
- package/dist/components/angle-slider/AngleSlider.js +34 -18
- package/dist/components/angle-slider/index.d.ts +2 -2
- package/dist/components/aspect-ratio/AspectRatio.css +3 -1
- package/dist/components/aspect-ratio/AspectRatio.js +2 -2
- package/dist/components/avatar/Avatar.d.ts +6 -3
- package/dist/components/avatar/Avatar.js +12 -5
- package/dist/components/avatar/index.d.ts +2 -2
- package/dist/components/badge/Badge.css +52 -8
- package/dist/components/badge/Badge.d.ts +2 -2
- package/dist/components/badge/Badge.js +1 -1
- package/dist/components/bleed/Bleed.d.ts +6 -4
- package/dist/components/bleed/Bleed.js +3 -3
- package/dist/components/breadcrumbs/Breadcrumbs.css +13 -6
- package/dist/components/breadcrumbs/Breadcrumbs.d.ts +18 -0
- package/dist/components/breadcrumbs/Breadcrumbs.js +18 -4
- package/dist/components/breadcrumbs/Breadcrumbs.module.js +2 -1
- package/dist/components/breadcrumbs/index.d.ts +2 -0
- package/dist/components/button/Button.css +45 -25
- package/dist/components/button/Button.d.ts +6 -0
- package/dist/components/button/Button.js +12 -7
- package/dist/components/card/Card.css +21 -5
- package/dist/components/card/Card.d.ts +1 -0
- package/dist/components/card/Card.js +12 -1
- package/dist/components/card/Card.module.js +1 -0
- package/dist/components/carousel/Carousel.css +19 -17
- package/dist/components/carousel/Carousel.d.ts +4 -0
- package/dist/components/carousel/Carousel.js +15 -2
- package/dist/components/checkbox/Checkbox.css +13 -13
- package/dist/components/checkbox/Checkbox.d.ts +2 -3
- package/dist/components/checkbox/Checkbox.js +25 -22
- package/dist/components/checkbox/index.d.ts +2 -2
- package/dist/components/clipboard/Clipboard.css +11 -11
- package/dist/components/clipboard/Clipboard.d.ts +2 -0
- package/dist/components/clipboard/Clipboard.js +15 -4
- package/dist/components/close-button/CloseButton.css +7 -7
- package/dist/components/close-button/CloseButton.d.ts +12 -2
- package/dist/components/close-button/CloseButton.js +9 -9
- package/dist/components/collapsible/Collapsible.css +13 -6
- package/dist/components/collapsible/Collapsible.d.ts +3 -2
- package/dist/components/collapsible/Collapsible.js +18 -6
- package/dist/components/collapsible/Collapsible.module.js +1 -0
- package/dist/components/collapsible/index.d.ts +2 -2
- package/dist/components/color-picker/ColorPicker.css +63 -27
- 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 +1 -0
- package/dist/components/color-picker/index.d.ts +2 -2
- package/dist/components/combobox/Combobox.css +69 -53
- package/dist/components/combobox/Combobox.d.ts +9 -2
- package/dist/components/combobox/Combobox.js +34 -8
- package/dist/components/combobox/index.d.ts +2 -2
- package/dist/components/command-palette/CommandPalette.css +67 -100
- 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 +0 -2
- package/dist/components/container/Container.js +1 -1
- package/dist/components/date-input/DateInput.css +8 -5
- package/dist/components/date-input/DateInput.d.ts +12 -7
- package/dist/components/date-input/DateInput.js +35 -14
- package/dist/components/date-input/index.d.ts +2 -2
- package/dist/components/date-picker/DatePicker.css +78 -57
- package/dist/components/date-picker/DatePicker.d.ts +30 -2
- package/dist/components/date-picker/DatePicker.js +94 -9
- package/dist/components/date-picker/index.d.ts +2 -2
- package/dist/components/dialog/Dialog.css +19 -14
- package/dist/components/dialog/Dialog.d.ts +2 -2
- package/dist/components/dialog/Dialog.js +3 -3
- package/dist/components/dialog/index.d.ts +2 -2
- package/dist/components/drawer/Drawer.css +6 -5
- package/dist/components/drawer/Drawer.d.ts +2 -2
- package/dist/components/drawer/Drawer.js +3 -3
- package/dist/components/drawer/index.d.ts +2 -2
- package/dist/components/editable/Editable.css +12 -10
- package/dist/components/editable/Editable.d.ts +9 -2
- package/dist/components/editable/Editable.js +14 -5
- package/dist/components/editable/index.d.ts +2 -2
- package/dist/components/empty/Empty.css +2 -2
- package/dist/components/empty/Empty.js +1 -1
- package/dist/components/field/Field.css +6 -8
- package/dist/components/field/Field.d.ts +3 -2
- package/dist/components/field/Field.js +6 -5
- package/dist/components/field/Field.module.js +0 -1
- package/dist/components/field/index.d.ts +2 -2
- package/dist/components/fieldset/Fieldset.d.ts +2 -2
- package/dist/components/fieldset/Fieldset.js +3 -3
- package/dist/components/fieldset/index.d.ts +2 -2
- package/dist/components/file-upload/FileUpload.css +96 -23
- 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 +3 -0
- package/dist/components/file-upload/index.d.ts +2 -2
- package/dist/components/floating-panel/FloatingPanel.css +44 -40
- package/dist/components/floating-panel/FloatingPanel.d.ts +10 -2
- package/dist/components/floating-panel/FloatingPanel.js +15 -9
- package/dist/components/heading/Heading.js +1 -1
- package/dist/components/highlight/Highlight.css +1 -1
- package/dist/components/highlight/Highlight.js +1 -1
- package/dist/components/hover-card/HoverCard.css +19 -15
- package/dist/components/hover-card/HoverCard.d.ts +3 -2
- package/dist/components/hover-card/HoverCard.js +5 -4
- 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 +15 -11
- package/dist/components/image-cropper/ImageCropper.d.ts +7 -2
- package/dist/components/image-cropper/ImageCropper.js +25 -3
- package/dist/components/image-cropper/index.d.ts +2 -2
- package/dist/components/input/Input.css +9 -9
- package/dist/components/input/Input.js +1 -1
- package/dist/components/input-group/InputGroup.css +29 -29
- package/dist/components/input-group/InputGroup.d.ts +3 -0
- package/dist/components/input-group/InputGroup.js +1 -1
- package/dist/components/kbd/Kbd.css +2 -2
- package/dist/components/kbd/Kbd.js +1 -1
- package/dist/components/lightbox/Lightbox.css +19 -17
- package/dist/components/lightbox/Lightbox.d.ts +4 -2
- package/dist/components/lightbox/Lightbox.js +9 -7
- package/dist/components/lightbox/index.d.ts +2 -2
- package/dist/components/list/List.js +1 -1
- package/dist/components/listbox/Listbox.css +87 -26
- package/dist/components/listbox/Listbox.d.ts +14 -2
- package/dist/components/listbox/Listbox.js +41 -5
- package/dist/components/listbox/Listbox.module.js +3 -0
- package/dist/components/listbox/index.d.ts +2 -2
- package/dist/components/marquee/Marquee.d.ts +2 -1
- package/dist/components/marquee/Marquee.js +4 -3
- package/dist/components/marquee/index.d.ts +2 -2
- package/dist/components/menu/Menu.css +54 -45
- package/dist/components/menu/Menu.d.ts +3 -2
- package/dist/components/menu/Menu.js +6 -5
- package/dist/components/menu/index.d.ts +2 -2
- package/dist/components/native-select/NativeSelect.css +17 -12
- package/dist/components/native-select/NativeSelect.d.ts +6 -2
- package/dist/components/native-select/NativeSelect.js +5 -4
- package/dist/components/number-input/NumberInput.css +17 -24
- package/dist/components/number-input/NumberInput.d.ts +7 -2
- package/dist/components/number-input/NumberInput.js +17 -4
- package/dist/components/number-input/index.d.ts +2 -2
- package/dist/components/pagination/Pagination.css +11 -11
- package/dist/components/pagination/Pagination.d.ts +4 -0
- package/dist/components/pagination/Pagination.js +13 -4
- package/dist/components/password-input/PasswordInput.css +4 -4
- package/dist/components/password-input/PasswordInput.d.ts +4 -0
- package/dist/components/password-input/PasswordInput.js +10 -2
- package/dist/components/pin-input/PinInput.css +6 -6
- package/dist/components/pin-input/PinInput.d.ts +6 -1
- package/dist/components/pin-input/PinInput.js +25 -16
- package/dist/components/popover/Popover.css +29 -19
- package/dist/components/popover/Popover.js +1 -1
- package/dist/components/progress-circular/ProgressCircular.css +2 -2
- package/dist/components/progress-circular/ProgressCircular.d.ts +6 -0
- package/dist/components/progress-circular/ProgressCircular.js +14 -3
- package/dist/components/progress-linear/ProgressLinear.css +1 -1
- package/dist/components/progress-linear/ProgressLinear.d.ts +3 -0
- package/dist/components/progress-linear/ProgressLinear.js +6 -3
- package/dist/components/qr-code/QrCode.css +10 -9
- package/dist/components/qr-code/QrCode.d.ts +2 -2
- package/dist/components/qr-code/QrCode.js +3 -3
- package/dist/components/qr-code/index.d.ts +2 -2
- package/dist/components/radio-group/RadioGroup.css +12 -12
- package/dist/components/radio-group/RadioGroup.d.ts +8 -4
- package/dist/components/radio-group/RadioGroup.js +22 -14
- package/dist/components/radio-group/index.d.ts +2 -2
- package/dist/components/rating-group/RatingGroup.css +10 -10
- package/dist/components/rating-group/RatingGroup.d.ts +11 -4
- package/dist/components/rating-group/RatingGroup.js +29 -18
- package/dist/components/rating-group/index.d.ts +2 -2
- package/dist/components/scroll-area/ScrollArea.css +12 -7
- package/dist/components/scroll-area/ScrollArea.d.ts +3 -0
- package/dist/components/scroll-area/ScrollArea.js +9 -6
- package/dist/components/segment-group/SegmentGroup.css +4 -4
- package/dist/components/segment-group/SegmentGroup.d.ts +13 -3
- package/dist/components/segment-group/SegmentGroup.js +23 -15
- package/dist/components/segment-group/index.d.ts +2 -2
- package/dist/components/select/Select.css +81 -55
- package/dist/components/select/Select.d.ts +18 -4
- package/dist/components/select/Select.js +65 -20
- package/dist/components/separator/Separator.css +6 -6
- package/dist/components/separator/Separator.js +1 -1
- package/dist/components/sidebar/Sidebar.css +161 -20
- package/dist/components/sidebar/Sidebar.d.ts +26 -0
- package/dist/components/sidebar/Sidebar.js +105 -13
- package/dist/components/sidebar/Sidebar.module.js +6 -0
- package/dist/components/signature-pad/SignaturePad.css +17 -45
- package/dist/components/signature-pad/SignaturePad.d.ts +14 -6
- package/dist/components/signature-pad/SignaturePad.js +56 -17
- 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/slider/Slider.css +17 -13
- package/dist/components/slider/Slider.d.ts +12 -3
- package/dist/components/slider/Slider.js +24 -15
- package/dist/components/slider/index.d.ts +2 -2
- package/dist/components/spinner/Spinner.css +5 -5
- package/dist/components/spinner/Spinner.js +2 -2
- package/dist/components/split-button/SplitButton.css +10 -10
- package/dist/components/split-button/SplitButton.d.ts +1 -1
- package/dist/components/split-button/SplitButton.js +3 -4
- package/dist/components/splitter/Splitter.css +19 -18
- package/dist/components/splitter/Splitter.d.ts +2 -2
- package/dist/components/splitter/Splitter.js +12 -11
- package/dist/components/splitter/index.d.ts +2 -2
- package/dist/components/stack/Stack.d.ts +1 -3
- package/dist/components/stack/Stack.js +4 -6
- package/dist/components/steps/Steps.css +20 -19
- package/dist/components/steps/Steps.d.ts +2 -1
- package/dist/components/steps/Steps.js +5 -4
- 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 +17 -17
- package/dist/components/switch/Switch.d.ts +4 -4
- package/dist/components/switch/Switch.js +19 -16
- package/dist/components/switch/index.d.ts +2 -2
- package/dist/components/table/Table.css +3 -3
- package/dist/components/table/Table.js +3 -2
- package/dist/components/table/Table.module.js +0 -1
- package/dist/components/tabs/Tabs.css +22 -20
- package/dist/components/tabs/Tabs.d.ts +3 -2
- package/dist/components/tabs/Tabs.js +5 -4
- package/dist/components/tabs/index.d.ts +2 -2
- package/dist/components/tag/Tag.css +23 -53
- package/dist/components/tag/Tag.js +7 -20
- package/dist/components/tags-input/TagsInput.css +19 -55
- package/dist/components/tags-input/TagsInput.d.ts +7 -4
- package/dist/components/tags-input/TagsInput.js +33 -21
- package/dist/components/tags-input/index.d.ts +2 -2
- package/dist/components/text/Text.d.ts +2 -2
- package/dist/components/text/Text.js +1 -1
- package/dist/components/textarea/Textarea.css +4 -3
- package/dist/components/textarea/Textarea.js +1 -1
- package/dist/components/timer/Timer.css +7 -7
- package/dist/components/timer/Timer.d.ts +14 -2
- package/dist/components/timer/Timer.js +13 -5
- package/dist/components/timer/index.d.ts +2 -2
- package/dist/components/toast/Toast.css +16 -15
- package/dist/components/toast/Toast.d.ts +3 -1
- package/dist/components/toast/Toast.js +11 -2
- package/dist/components/toggle/Toggle.css +23 -23
- package/dist/components/toggle/Toggle.d.ts +3 -2
- package/dist/components/toggle/Toggle.js +5 -4
- package/dist/components/toggle/index.d.ts +2 -2
- package/dist/components/toggle-group/ToggleGroup.d.ts +3 -2
- package/dist/components/toggle-group/ToggleGroup.js +4 -3
- package/dist/components/toggle-group/index.d.ts +2 -2
- package/dist/components/tooltip/Tooltip.css +23 -18
- package/dist/components/tooltip/Tooltip.d.ts +3 -2
- package/dist/components/tooltip/Tooltip.js +10 -3
- package/dist/components/tooltip/index.d.ts +2 -2
- package/dist/components/tour/Tour.css +37 -32
- package/dist/components/tour/Tour.d.ts +6 -0
- package/dist/components/tour/Tour.js +8 -1
- package/dist/components/tree-view/TreeView.css +24 -21
- package/dist/components/tree-view/TreeView.d.ts +2 -2
- package/dist/components/tree-view/TreeView.js +4 -4
- package/dist/components/tree-view/index.d.ts +2 -2
- package/dist/components/typeset/Typeset.css +317 -0
- package/dist/components/typeset/Typeset.d.ts +7 -0
- package/dist/components/typeset/Typeset.js +33 -0
- package/dist/components/typeset/Typeset.module.js +8 -0
- package/dist/index.d.ts +42 -39
- package/dist/index.js +42 -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/dist/lib/moduix/presets/contrast.css +65 -0
- package/dist/lib/moduix/presets/dense.css +78 -0
- package/dist/lib/moduix/presets/soft.css +77 -0
- package/dist/lib/moduix/styles/reset.css +33 -0
- package/dist/lib/moduix/styles/style.css +17 -4
- package/dist/presets/contrast.d.ts +1 -0
- package/dist/presets/contrast.js +1 -0
- package/dist/presets/dense.d.ts +1 -0
- package/dist/presets/dense.js +1 -0
- package/dist/presets/soft.d.ts +1 -0
- package/dist/presets/soft.js +1 -0
- package/package.json +7 -3
|
@@ -1,27 +1,31 @@
|
|
|
1
|
-
import { RatingStarIcon } from "../../lib/moduix/icons/ui/Icons.js";
|
|
2
1
|
import { normalizeClassName } from "../../lib/moduix/normalizeClassName.js";
|
|
2
|
+
import { RatingStarIcon } from "../../lib/moduix/icons/ui/Icons.js";
|
|
3
3
|
import RatingGroup_module_default from "./RatingGroup.module.js";
|
|
4
|
-
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
5
4
|
import { clsx } from "clsx";
|
|
6
|
-
import { forwardRef } from "react";
|
|
7
|
-
import {
|
|
5
|
+
import { Children, cloneElement, forwardRef } from "react";
|
|
6
|
+
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
7
|
+
import { RatingGroup, useRatingGroup, useRatingGroupContext, useRatingGroupItemContext } from "@ark-ui/react/rating-group";
|
|
8
8
|
//#region src/components/rating-group/RatingGroup.tsx
|
|
9
|
-
const RatingGroupRoot = forwardRef(function RatingGroupRoot({ className, size = "md", ...props }, ref) {
|
|
9
|
+
const RatingGroupRoot = forwardRef(function RatingGroupRoot({ asChild, children, className, size = "md", ...props }, ref) {
|
|
10
10
|
return /* @__PURE__ */ jsx(RatingGroup.Root, {
|
|
11
11
|
ref,
|
|
12
|
+
asChild,
|
|
12
13
|
"data-slot": "rating-group-root",
|
|
13
14
|
"data-size": size,
|
|
14
15
|
className: clsx(RatingGroup_module_default.root, normalizeClassName(className)),
|
|
15
|
-
...props
|
|
16
|
+
...props,
|
|
17
|
+
children: withHiddenInput(children, asChild)
|
|
16
18
|
});
|
|
17
19
|
});
|
|
18
|
-
const RatingGroupRootProvider = forwardRef(function RatingGroupRootProvider({ className, size = "md", ...props }, ref) {
|
|
20
|
+
const RatingGroupRootProvider = forwardRef(function RatingGroupRootProvider({ asChild, children, className, size = "md", ...props }, ref) {
|
|
19
21
|
return /* @__PURE__ */ jsx(RatingGroup.RootProvider, {
|
|
20
22
|
ref,
|
|
23
|
+
asChild,
|
|
21
24
|
"data-slot": "rating-group-root-provider",
|
|
22
25
|
"data-size": size,
|
|
23
26
|
className: clsx(RatingGroup_module_default.root, normalizeClassName(className)),
|
|
24
|
-
...props
|
|
27
|
+
...props,
|
|
28
|
+
children: withHiddenInput(children, asChild)
|
|
25
29
|
});
|
|
26
30
|
});
|
|
27
31
|
const RatingGroupLabel = forwardRef(function RatingGroupLabel({ className, ...props }, ref) {
|
|
@@ -57,7 +61,7 @@ const RatingGroupItemIndicator = forwardRef(function RatingGroupItemIndicator({
|
|
|
57
61
|
"data-highlighted": highlighted ? "" : void 0,
|
|
58
62
|
className: clsx(RatingGroup_module_default.itemIndicator, normalizeClassName(className)),
|
|
59
63
|
...props,
|
|
60
|
-
children: children ?? /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(RatingStarIcon, {
|
|
64
|
+
children: children ?? /* @__PURE__ */ jsxs(Fragment$1, { children: [/* @__PURE__ */ jsx(RatingStarIcon, {
|
|
61
65
|
"data-slot": "rating-group-item-indicator-bg",
|
|
62
66
|
className: RatingGroup_module_default.iconBg
|
|
63
67
|
}), /* @__PURE__ */ jsx(RatingStarIcon, {
|
|
@@ -66,21 +70,28 @@ const RatingGroupItemIndicator = forwardRef(function RatingGroupItemIndicator({
|
|
|
66
70
|
})] })
|
|
67
71
|
});
|
|
68
72
|
});
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
})
|
|
73
|
+
function withHiddenInput(children, asChild) {
|
|
74
|
+
const hiddenInput = /* @__PURE__ */ jsx(RatingGroup.HiddenInput, { "data-slot": "rating-group-hidden-input" });
|
|
75
|
+
if (!asChild) return /* @__PURE__ */ jsxs(Fragment$1, { children: [children, hiddenInput] });
|
|
76
|
+
const child = Children.only(children);
|
|
77
|
+
return cloneElement(child, {}, child.props.children, hiddenInput);
|
|
78
|
+
}
|
|
79
|
+
function RatingGroupItems({ children }) {
|
|
80
|
+
return /* @__PURE__ */ jsx(Fragment$1, { children: /* @__PURE__ */ jsx(RatingGroup.Context, { children: ({ items }) => items.map((item) => /* @__PURE__ */ jsx(RatingGroupItem, {
|
|
81
|
+
index: item,
|
|
82
|
+
children: children ?? /* @__PURE__ */ jsx(RatingGroupItemIndicator, {})
|
|
83
|
+
}, item)) }) });
|
|
84
|
+
}
|
|
76
85
|
const RatingGroup$1 = Object.assign(RatingGroupRoot, {
|
|
77
86
|
Root: RatingGroupRoot,
|
|
78
87
|
RootProvider: RatingGroupRootProvider,
|
|
88
|
+
Context: RatingGroup.Context,
|
|
79
89
|
Label: RatingGroupLabel,
|
|
80
90
|
Control: RatingGroupControl,
|
|
81
91
|
Item: RatingGroupItem,
|
|
92
|
+
ItemContext: RatingGroup.ItemContext,
|
|
82
93
|
ItemIndicator: RatingGroupItemIndicator,
|
|
83
|
-
|
|
94
|
+
Items: RatingGroupItems
|
|
84
95
|
});
|
|
85
96
|
//#endregion
|
|
86
|
-
export { RatingGroup$1 as RatingGroup };
|
|
97
|
+
export { RatingGroup$1 as RatingGroup, useRatingGroup, useRatingGroupContext, useRatingGroupItemContext };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { RatingGroup, RatingGroupItemIndicatorProps, RatingGroupRootProps, RatingGroupRootProviderProps, RatingGroupSize } from "./RatingGroup.js";
|
|
2
|
-
export { RatingGroup, type RatingGroupItemIndicatorProps, type RatingGroupRootProps, type RatingGroupRootProviderProps, type RatingGroupSize };
|
|
1
|
+
import { RatingGroup, RatingGroupItemIndicatorProps, RatingGroupRootProps, RatingGroupRootProviderProps, RatingGroupSize, useRatingGroup, useRatingGroupContext, useRatingGroupItemContext } from "./RatingGroup.js";
|
|
2
|
+
export { RatingGroup, type RatingGroupItemIndicatorProps, type RatingGroupRootProps, type RatingGroupRootProviderProps, type RatingGroupSize, useRatingGroup, useRatingGroupContext, useRatingGroupItemContext };
|
|
@@ -41,9 +41,9 @@
|
|
|
41
41
|
}
|
|
42
42
|
|
|
43
43
|
&:focus-visible {
|
|
44
|
-
outline: var(--scroll-area-focus-ring-width, var(--border-width-sm))
|
|
45
|
-
var(--scroll-area-focus-ring-color, var(--color-ring));
|
|
46
|
-
outline-offset: var(--scroll-area-focus-ring-offset, -
|
|
44
|
+
outline: var(--scroll-area-focus-ring-width, var(--focus-ring-inset-width, var(--border-width-sm)))
|
|
45
|
+
solid var(--scroll-area-focus-ring-color, var(--color-ring));
|
|
46
|
+
outline-offset: var(--scroll-area-focus-ring-offset, var(--focus-ring-inset-offset));
|
|
47
47
|
}
|
|
48
48
|
}
|
|
49
49
|
|
|
@@ -65,8 +65,8 @@
|
|
|
65
65
|
user-select: none;
|
|
66
66
|
touch-action: none;
|
|
67
67
|
transition: opacity var(--scroll-area-transition, var(--transition-default)),
|
|
68
|
-
width var(--scroll-area-transition, var(--transition-
|
|
69
|
-
height var(--scroll-area-transition, var(--transition-
|
|
68
|
+
width var(--scroll-area-thumb-hover-transition, var(--transition-fast)),
|
|
69
|
+
height var(--scroll-area-thumb-hover-transition, var(--transition-fast));
|
|
70
70
|
justify-content: center;
|
|
71
71
|
display: flex;
|
|
72
72
|
position: absolute;
|
|
@@ -137,6 +137,11 @@
|
|
|
137
137
|
&[data-scrolling] {
|
|
138
138
|
transition-duration: 0s;
|
|
139
139
|
}
|
|
140
|
+
|
|
141
|
+
.xqtLha_root[data-variant="always"] & {
|
|
142
|
+
opacity: var(--scroll-area-scrollbar-visible-opacity, 1);
|
|
143
|
+
pointer-events: auto;
|
|
144
|
+
}
|
|
140
145
|
}
|
|
141
146
|
|
|
142
147
|
.xqtLha_thumb {
|
|
@@ -146,12 +151,12 @@
|
|
|
146
151
|
|
|
147
152
|
&[data-orientation="vertical"] {
|
|
148
153
|
width: 100%;
|
|
149
|
-
min-height: var(--scroll-area-thumb-min-size,
|
|
154
|
+
min-height: var(--scroll-area-thumb-min-size, var(--size-xs));
|
|
150
155
|
}
|
|
151
156
|
|
|
152
157
|
&[data-orientation="horizontal"] {
|
|
153
158
|
height: 100%;
|
|
154
|
-
min-width: var(--scroll-area-thumb-min-size,
|
|
159
|
+
min-width: var(--scroll-area-thumb-min-size, var(--size-xs));
|
|
155
160
|
}
|
|
156
161
|
}
|
|
157
162
|
|
|
@@ -4,9 +4,11 @@ import { ScrollArea } from "@ark-ui/react/scroll-area";
|
|
|
4
4
|
//#region src/components/scroll-area/ScrollArea.d.ts
|
|
5
5
|
type ModuixScrollAreaRootProps = ComponentProps<typeof ScrollArea.Root> & {
|
|
6
6
|
fade?: boolean;
|
|
7
|
+
variant?: 'hover' | 'always';
|
|
7
8
|
};
|
|
8
9
|
type ModuixScrollAreaRootProviderProps = ComponentProps<typeof ScrollArea.RootProvider> & {
|
|
9
10
|
fade?: boolean;
|
|
11
|
+
variant?: 'hover' | 'always';
|
|
10
12
|
};
|
|
11
13
|
declare const ScrollArea$1: import("react").ForwardRefExoticComponent<Omit<ModuixScrollAreaRootProps, "ref"> & import("react").RefAttributes<HTMLDivElement>> & {
|
|
12
14
|
Root: import("react").ForwardRefExoticComponent<Omit<ModuixScrollAreaRootProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -16,6 +18,7 @@ declare const ScrollArea$1: import("react").ForwardRefExoticComponent<Omit<Modui
|
|
|
16
18
|
Scrollbar: import("react").ForwardRefExoticComponent<Omit<ScrollArea.ScrollbarProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
17
19
|
Thumb: import("react").ForwardRefExoticComponent<Omit<ScrollArea.ThumbProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
18
20
|
Corner: import("react").ForwardRefExoticComponent<Omit<ScrollArea.CornerProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
21
|
+
useScrollArea: (props?: import("@ark-ui/react/scroll-area").UseScrollAreaProps) => import("@ark-ui/react/scroll-area").UseScrollAreaReturn;
|
|
19
22
|
};
|
|
20
23
|
//#endregion
|
|
21
24
|
export { type ModuixScrollAreaRootProps, type ModuixScrollAreaRootProviderProps, ScrollArea$1 as ScrollArea };
|
|
@@ -1,24 +1,26 @@
|
|
|
1
1
|
import { normalizeClassName } from "../../lib/moduix/normalizeClassName.js";
|
|
2
2
|
import ScrollArea_module_default from "./ScrollArea.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 { ScrollArea, useScrollArea } from "@ark-ui/react/scroll-area";
|
|
7
7
|
//#region src/components/scroll-area/ScrollArea.tsx
|
|
8
|
-
const ScrollAreaRoot = forwardRef(function ScrollAreaRoot({ className, fade, ...props }, ref) {
|
|
8
|
+
const ScrollAreaRoot = forwardRef(function ScrollAreaRoot({ className, fade, variant = "hover", ...props }, ref) {
|
|
9
9
|
return /* @__PURE__ */ jsx(ScrollArea.Root, {
|
|
10
10
|
ref,
|
|
11
11
|
"data-slot": "scroll-area-root",
|
|
12
12
|
"data-fade": fade ? "" : void 0,
|
|
13
|
+
"data-variant": variant,
|
|
13
14
|
className: clsx(ScrollArea_module_default.root, normalizeClassName(className)),
|
|
14
15
|
...props
|
|
15
16
|
});
|
|
16
17
|
});
|
|
17
|
-
const ScrollAreaRootProvider = forwardRef(function ScrollAreaRootProvider({ className, fade, ...props }, ref) {
|
|
18
|
+
const ScrollAreaRootProvider = forwardRef(function ScrollAreaRootProvider({ className, fade, variant = "hover", ...props }, ref) {
|
|
18
19
|
return /* @__PURE__ */ jsx(ScrollArea.RootProvider, {
|
|
19
20
|
ref,
|
|
20
21
|
"data-slot": "scroll-area-root-provider",
|
|
21
22
|
"data-fade": fade ? "" : void 0,
|
|
23
|
+
"data-variant": variant,
|
|
22
24
|
className: clsx(ScrollArea_module_default.root, normalizeClassName(className)),
|
|
23
25
|
...props
|
|
24
26
|
});
|
|
@@ -70,7 +72,8 @@ const ScrollArea$1 = Object.assign(ScrollAreaRoot, {
|
|
|
70
72
|
Content: ScrollAreaContent,
|
|
71
73
|
Scrollbar: ScrollAreaScrollbar,
|
|
72
74
|
Thumb: ScrollAreaThumb,
|
|
73
|
-
Corner: ScrollAreaCorner
|
|
75
|
+
Corner: ScrollAreaCorner,
|
|
76
|
+
useScrollArea
|
|
74
77
|
});
|
|
75
78
|
//#endregion
|
|
76
|
-
export { ScrollArea$1 as ScrollArea };
|
|
79
|
+
export { ScrollArea$1 as ScrollArea, useScrollArea };
|
|
@@ -44,9 +44,9 @@
|
|
|
44
44
|
justify-content: center;
|
|
45
45
|
align-items: center;
|
|
46
46
|
gap: var(--segment-group-item-gap, var(--spacing-2));
|
|
47
|
-
min-height: var(--segment-group-item-height,
|
|
47
|
+
min-height: var(--segment-group-item-height, var(--size-sm));
|
|
48
48
|
border-radius: var(--segment-group-item-radius, var(--radius-md));
|
|
49
|
-
padding-inline: var(--segment-group-item-padding-x,
|
|
49
|
+
padding-inline: var(--segment-group-item-padding-x, var(--spacing-3-5));
|
|
50
50
|
color: var(--segment-group-item-color, var(--color-muted-foreground));
|
|
51
51
|
font-size: var(--segment-group-item-font-size, var(--text-sm));
|
|
52
52
|
font-weight: var(--segment-group-item-font-weight, var(--weight-medium));
|
|
@@ -71,8 +71,8 @@
|
|
|
71
71
|
}
|
|
72
72
|
|
|
73
73
|
&[data-focus-visible] {
|
|
74
|
-
outline: var(--segment-group-focus-ring-width, var(--border-width-sm))
|
|
75
|
-
var(--segment-group-focus-ring-color, var(--color-ring));
|
|
74
|
+
outline: var(--segment-group-focus-ring-width, var(--focus-ring-inset-width, var(--border-width-sm)))
|
|
75
|
+
solid var(--segment-group-focus-ring-color, var(--color-ring));
|
|
76
76
|
outline-offset: var(--segment-group-focus-ring-offset, var(--border-width-sm));
|
|
77
77
|
}
|
|
78
78
|
|
|
@@ -1,6 +1,16 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ReactNode } from "react";
|
|
2
|
+
import { SegmentGroup, useSegmentGroup } from "@ark-ui/react/segment-group";
|
|
2
3
|
|
|
3
4
|
//#region src/components/segment-group/SegmentGroup.d.ts
|
|
5
|
+
declare function SegmentGroupItems({
|
|
6
|
+
items
|
|
7
|
+
}: {
|
|
8
|
+
items: readonly {
|
|
9
|
+
value: string;
|
|
10
|
+
label: ReactNode;
|
|
11
|
+
disabled?: boolean;
|
|
12
|
+
}[];
|
|
13
|
+
}): import("react").JSX.Element[];
|
|
4
14
|
declare const SegmentGroup$1: import("react").ForwardRefExoticComponent<Omit<SegmentGroup.RootProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>> & {
|
|
5
15
|
Root: import("react").ForwardRefExoticComponent<Omit<SegmentGroup.RootProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
6
16
|
RootProvider: import("react").ForwardRefExoticComponent<Omit<SegmentGroup.RootProviderProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -8,8 +18,8 @@ declare const SegmentGroup$1: import("react").ForwardRefExoticComponent<Omit<Seg
|
|
|
8
18
|
Item: import("react").ForwardRefExoticComponent<Omit<SegmentGroup.ItemProps & import("react").RefAttributes<HTMLLabelElement>, "ref"> & import("react").RefAttributes<HTMLLabelElement>>;
|
|
9
19
|
ItemControl: import("react").ForwardRefExoticComponent<Omit<SegmentGroup.ItemControlProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
10
20
|
ItemText: import("react").ForwardRefExoticComponent<Omit<SegmentGroup.ItemTextProps & import("react").RefAttributes<HTMLSpanElement>, "ref"> & import("react").RefAttributes<HTMLSpanElement>>;
|
|
11
|
-
ItemHiddenInput: import("react").ForwardRefExoticComponent<Omit<SegmentGroup.ItemHiddenInputProps & import("react").RefAttributes<HTMLInputElement>, "ref"> & import("react").RefAttributes<HTMLInputElement>>;
|
|
12
21
|
Indicator: import("react").ForwardRefExoticComponent<Omit<SegmentGroup.IndicatorProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
22
|
+
Items: typeof SegmentGroupItems;
|
|
13
23
|
};
|
|
14
24
|
//#endregion
|
|
15
|
-
export { SegmentGroup$1 as SegmentGroup };
|
|
25
|
+
export { SegmentGroup$1 as SegmentGroup, useSegmentGroup };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { normalizeClassName } from "../../lib/moduix/normalizeClassName.js";
|
|
2
2
|
import SegmentGroup_module_default from "./SegmentGroup.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 { SegmentGroup, useSegmentGroup } from "@ark-ui/react/segment-group";
|
|
7
7
|
//#region src/components/segment-group/SegmentGroup.tsx
|
|
8
8
|
const SegmentGroupRoot = forwardRef(function SegmentGroupRoot({ className, orientation = "horizontal", ...props }, ref) {
|
|
9
9
|
return /* @__PURE__ */ jsx(SegmentGroup.Root, {
|
|
@@ -30,12 +30,14 @@ const SegmentGroupLabel = forwardRef(function SegmentGroupLabel({ className, ...
|
|
|
30
30
|
...props
|
|
31
31
|
});
|
|
32
32
|
});
|
|
33
|
-
const SegmentGroupItem = forwardRef(function SegmentGroupItem({ className, ...props }, ref) {
|
|
33
|
+
const SegmentGroupItem = forwardRef(function SegmentGroupItem({ asChild, children, className, ...props }, ref) {
|
|
34
34
|
return /* @__PURE__ */ jsx(SegmentGroup.Item, {
|
|
35
35
|
ref,
|
|
36
|
+
asChild,
|
|
36
37
|
"data-slot": "segment-group-item",
|
|
37
38
|
className: clsx(SegmentGroup_module_default.item, normalizeClassName(className)),
|
|
38
|
-
...props
|
|
39
|
+
...props,
|
|
40
|
+
children: withItemHiddenInput(children, asChild)
|
|
39
41
|
});
|
|
40
42
|
});
|
|
41
43
|
const SegmentGroupItemControl = forwardRef(function SegmentGroupItemControl({ className, ...props }, ref) {
|
|
@@ -54,13 +56,12 @@ const SegmentGroupItemText = forwardRef(function SegmentGroupItemText({ classNam
|
|
|
54
56
|
...props
|
|
55
57
|
});
|
|
56
58
|
});
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
});
|
|
59
|
+
function withItemHiddenInput(children, asChild) {
|
|
60
|
+
const hiddenInput = /* @__PURE__ */ jsx(SegmentGroup.ItemHiddenInput, { "data-slot": "segment-group-item-hidden-input" });
|
|
61
|
+
if (!asChild) return /* @__PURE__ */ jsxs(Fragment$1, { children: [children, hiddenInput] });
|
|
62
|
+
const child = Children.only(children);
|
|
63
|
+
return cloneElement(child, {}, child.props.children, hiddenInput);
|
|
64
|
+
}
|
|
64
65
|
const SegmentGroupIndicator = forwardRef(function SegmentGroupIndicator({ className, ...props }, ref) {
|
|
65
66
|
return /* @__PURE__ */ jsx(SegmentGroup.Indicator, {
|
|
66
67
|
ref,
|
|
@@ -69,6 +70,13 @@ const SegmentGroupIndicator = forwardRef(function SegmentGroupIndicator({ classN
|
|
|
69
70
|
...props
|
|
70
71
|
});
|
|
71
72
|
});
|
|
73
|
+
function SegmentGroupItems({ items }) {
|
|
74
|
+
return items.map(({ value, label, disabled }) => /* @__PURE__ */ jsxs(SegmentGroupItem, {
|
|
75
|
+
value,
|
|
76
|
+
disabled,
|
|
77
|
+
children: [/* @__PURE__ */ jsx(SegmentGroupItemText, { children: label }), /* @__PURE__ */ jsx(SegmentGroupItemControl, {})]
|
|
78
|
+
}, value));
|
|
79
|
+
}
|
|
72
80
|
const SegmentGroup$1 = Object.assign(SegmentGroupRoot, {
|
|
73
81
|
Root: SegmentGroupRoot,
|
|
74
82
|
RootProvider: SegmentGroupRootProvider,
|
|
@@ -76,8 +84,8 @@ const SegmentGroup$1 = Object.assign(SegmentGroupRoot, {
|
|
|
76
84
|
Item: SegmentGroupItem,
|
|
77
85
|
ItemControl: SegmentGroupItemControl,
|
|
78
86
|
ItemText: SegmentGroupItemText,
|
|
79
|
-
|
|
80
|
-
|
|
87
|
+
Indicator: SegmentGroupIndicator,
|
|
88
|
+
Items: SegmentGroupItems
|
|
81
89
|
});
|
|
82
90
|
//#endregion
|
|
83
|
-
export { SegmentGroup$1 as SegmentGroup };
|
|
91
|
+
export { SegmentGroup$1 as SegmentGroup, useSegmentGroup };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { SegmentGroup } from "./SegmentGroup.js";
|
|
2
|
-
export { SegmentGroup };
|
|
1
|
+
import { SegmentGroup, useSegmentGroup } from "./SegmentGroup.js";
|
|
2
|
+
export { SegmentGroup, useSegmentGroup };
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
@layer ui.components {
|
|
2
2
|
@keyframes FGbIOa_select-content-open {
|
|
3
3
|
from {
|
|
4
|
-
opacity: var(--select-content-closed-opacity, 0);
|
|
5
|
-
|
|
4
|
+
opacity: var(--select-content-closed-opacity, var(--popup-motion-starting-opacity, 0));
|
|
5
|
+
translate: var(--popup-motion-starting-translate-x, 0)
|
|
6
|
+
var(--popup-motion-starting-translate-y, 0);
|
|
7
|
+
transform: scale(var(--select-content-closed-scale, var(--popup-motion-starting-scale, var(--scale-popup))));
|
|
6
8
|
}
|
|
7
9
|
|
|
8
10
|
to {
|
|
@@ -18,8 +20,9 @@
|
|
|
18
20
|
}
|
|
19
21
|
|
|
20
22
|
to {
|
|
21
|
-
opacity: var(--select-content-closed-opacity, 0);
|
|
22
|
-
|
|
23
|
+
opacity: var(--select-content-closed-opacity, var(--popup-motion-ending-opacity, 0));
|
|
24
|
+
translate: var(--popup-motion-ending-translate-x, 0) var(--popup-motion-ending-translate-y, 0);
|
|
25
|
+
transform: scale(var(--select-content-closed-scale, var(--popup-motion-ending-scale, var(--scale-popup))));
|
|
23
26
|
}
|
|
24
27
|
}
|
|
25
28
|
|
|
@@ -27,7 +30,7 @@
|
|
|
27
30
|
box-sizing: border-box;
|
|
28
31
|
width: var(--select-width, 14rem);
|
|
29
32
|
max-width: var(--select-max-width, 100%);
|
|
30
|
-
gap: var(--select-root-gap,
|
|
33
|
+
gap: var(--select-root-gap, var(--spacing-1-5));
|
|
31
34
|
min-width: 0;
|
|
32
35
|
color: var(--select-color, var(--color-foreground));
|
|
33
36
|
flex-direction: column;
|
|
@@ -65,19 +68,21 @@
|
|
|
65
68
|
box-sizing: border-box;
|
|
66
69
|
width: 100%;
|
|
67
70
|
min-width: 0;
|
|
68
|
-
height: var(--select-control-height, var(--size-
|
|
71
|
+
height: var(--select-control-height, var(--size-md));
|
|
69
72
|
border: var(--select-border-width, var(--border-width-sm)) solid
|
|
70
73
|
var(--select-border-color, var(--color-border));
|
|
71
74
|
border-radius: var(--select-radius, var(--radius-md));
|
|
72
|
-
padding-inline: var(--select-trigger-padding-x-start,
|
|
73
|
-
calc(var(--select-action-offset-right,
|
|
74
|
-
var(--select-
|
|
75
|
+
padding-inline: var(--select-trigger-padding-x-start, var(--spacing-3-5))
|
|
76
|
+
calc(var(--select-action-offset-right, var(--spacing-2)) +
|
|
77
|
+
var(--select-action-size, var(--size-xs)) +
|
|
78
|
+
var(--select-trigger-padding-x-start, var(--spacing-3-5)));
|
|
75
79
|
background-color: var(--select-bg, var(--color-background));
|
|
76
80
|
color: inherit;
|
|
77
81
|
font: inherit;
|
|
78
82
|
text-align: start;
|
|
79
|
-
outline: var(--select-focus-ring-width, var(--border-width-sm))
|
|
80
|
-
|
|
83
|
+
outline: var(--select-focus-ring-width, var(--focus-ring-inset-width, var(--border-width-sm)))
|
|
84
|
+
solid transparent;
|
|
85
|
+
outline-offset: calc(var(--select-focus-ring-width, var(--focus-ring-inset-width, var(--border-width-sm))) * -1);
|
|
81
86
|
cursor: pointer;
|
|
82
87
|
user-select: none;
|
|
83
88
|
transition: background-color var(--select-transition, var(--transition-default)),
|
|
@@ -87,13 +92,13 @@
|
|
|
87
92
|
align-items: center;
|
|
88
93
|
margin: 0;
|
|
89
94
|
display: inline-flex;
|
|
95
|
+
position: relative;
|
|
90
96
|
|
|
91
97
|
&[data-placeholder-shown] {
|
|
92
98
|
color: var(--select-placeholder-color, var(--color-muted-foreground));
|
|
93
99
|
}
|
|
94
100
|
|
|
95
101
|
&[data-state="open"] {
|
|
96
|
-
background-color: var(--select-bg-active, var(--color-muted));
|
|
97
102
|
border-color: var(--select-focus-ring-color, var(--color-ring));
|
|
98
103
|
outline-color: var(--select-focus-ring-color, var(--color-ring));
|
|
99
104
|
}
|
|
@@ -111,14 +116,6 @@
|
|
|
111
116
|
border-color: var(--select-invalid-color, var(--color-destructive));
|
|
112
117
|
outline-color: var(--select-invalid-color, var(--color-destructive));
|
|
113
118
|
}
|
|
114
|
-
|
|
115
|
-
.FGbIOa_control:not([data-disabled]) & {
|
|
116
|
-
@media (hover: hover) {
|
|
117
|
-
&:hover {
|
|
118
|
-
background-color: var(--select-bg-hover, var(--color-accent));
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
}
|
|
122
119
|
}
|
|
123
120
|
|
|
124
121
|
.FGbIOa_control:has(.FGbIOa_clearTrigger:not([hidden])) .FGbIOa_trigger {
|
|
@@ -135,20 +132,20 @@
|
|
|
135
132
|
|
|
136
133
|
.FGbIOa_indicators {
|
|
137
134
|
top: 50%;
|
|
138
|
-
right: var(--select-action-offset-right, .5rem);
|
|
139
135
|
align-items: center;
|
|
140
|
-
gap: var(--select-action-gap,
|
|
136
|
+
gap: var(--select-action-gap, var(--spacing-0-5));
|
|
141
137
|
pointer-events: none;
|
|
142
138
|
line-height: 0;
|
|
143
139
|
display: inline-flex;
|
|
144
140
|
position: absolute;
|
|
141
|
+
inset-inline-end: var(--select-action-offset-right, var(--spacing-2));
|
|
145
142
|
transform: translateY(-50%);
|
|
146
143
|
}
|
|
147
144
|
|
|
148
|
-
.FGbIOa_indicator
|
|
145
|
+
.FGbIOa_indicator {
|
|
149
146
|
box-sizing: border-box;
|
|
150
|
-
width: var(--select-action-size,
|
|
151
|
-
height: var(--select-action-size,
|
|
147
|
+
width: var(--select-action-size, var(--size-xs));
|
|
148
|
+
height: var(--select-action-size, var(--size-xs));
|
|
152
149
|
border-radius: var(--select-action-radius, var(--radius-sm));
|
|
153
150
|
background: var(--select-action-bg, transparent);
|
|
154
151
|
color: var(--select-icon-color, var(--color-muted-foreground));
|
|
@@ -165,8 +162,8 @@
|
|
|
165
162
|
display: inline-flex;
|
|
166
163
|
|
|
167
164
|
& > svg {
|
|
168
|
-
width: var(--select-icon-size,
|
|
169
|
-
height: var(--select-icon-size,
|
|
165
|
+
width: var(--select-icon-size, var(--spacing-4));
|
|
166
|
+
height: var(--select-icon-size, var(--spacing-4));
|
|
170
167
|
display: block;
|
|
171
168
|
}
|
|
172
169
|
|
|
@@ -183,20 +180,45 @@
|
|
|
183
180
|
pointer-events: none;
|
|
184
181
|
}
|
|
185
182
|
|
|
183
|
+
.FGbIOa_trigger > .FGbIOa_indicator {
|
|
184
|
+
top: 50%;
|
|
185
|
+
pointer-events: auto;
|
|
186
|
+
position: absolute;
|
|
187
|
+
inset-inline-end: var(--select-action-offset-right, var(--spacing-2));
|
|
188
|
+
transform: translateY(-50%);
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
.FGbIOa_trigger > .FGbIOa_indicator:not(:is([data-disabled], [disabled])):hover {
|
|
192
|
+
@media (hover: hover) {
|
|
193
|
+
background-color: var(--select-action-bg-hover, var(--color-muted));
|
|
194
|
+
color: var(--select-action-color-hover, var(--color-foreground));
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
|
|
186
198
|
.FGbIOa_clearTrigger {
|
|
187
|
-
|
|
199
|
+
--close-button-size: var(--select-action-size, var(--size-xs));
|
|
200
|
+
--close-button-icon-size: var(--select-icon-size, var(--spacing-4));
|
|
201
|
+
--close-button-radius: var(--select-action-radius, var(--radius-sm));
|
|
202
|
+
--close-button-bg: var(--select-action-bg, transparent);
|
|
203
|
+
--close-button-bg-hover: var(--select-action-bg-hover, var(--color-muted));
|
|
204
|
+
--close-button-color: var(--select-icon-color, var(--color-muted-foreground));
|
|
205
|
+
--close-button-color-hover: var(--select-action-color-hover, var(--color-foreground));
|
|
206
|
+
--close-button-transition: var(--select-transition, var(--transition-default));
|
|
188
207
|
pointer-events: auto;
|
|
189
208
|
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
&:hover {
|
|
193
|
-
background-color: var(--select-action-bg-hover, var(--color-muted));
|
|
194
|
-
color: var(--select-action-color-hover, var(--color-foreground));
|
|
195
|
-
}
|
|
196
|
-
}
|
|
209
|
+
&[hidden] {
|
|
210
|
+
display: none;
|
|
197
211
|
}
|
|
198
212
|
}
|
|
199
213
|
|
|
214
|
+
.FGbIOa_control > .FGbIOa_clearTrigger {
|
|
215
|
+
top: 50%;
|
|
216
|
+
position: absolute;
|
|
217
|
+
inset-inline-end: calc(var(--select-action-offset-right, var(--spacing-2)) +
|
|
218
|
+
var(--select-action-size, var(--size-xs)) + var(--select-action-gap, var(--spacing-0-5)));
|
|
219
|
+
transform: translateY(-50%);
|
|
220
|
+
}
|
|
221
|
+
|
|
200
222
|
.FGbIOa_positioner {
|
|
201
223
|
z-index: var(--z-index);
|
|
202
224
|
outline: 0;
|
|
@@ -211,7 +233,7 @@
|
|
|
211
233
|
border: var(--select-content-border-width, var(--border-width-sm)) solid
|
|
212
234
|
var(--select-content-border-color, var(--color-border));
|
|
213
235
|
border-radius: var(--select-radius, var(--radius-md));
|
|
214
|
-
padding-block: var(--select-content-padding-y, var(--spacing-1));
|
|
236
|
+
padding-block: var(--select-content-padding-y, var(--popup-list-padding-y, var(--spacing-1)));
|
|
215
237
|
background-color: var(--select-content-bg, var(--color-popover));
|
|
216
238
|
box-shadow: var(--select-content-shadow, var(--shadow-lg));
|
|
217
239
|
color: var(--select-content-color, var(--color-popover-foreground));
|
|
@@ -224,11 +246,15 @@
|
|
|
224
246
|
overflow: auto;
|
|
225
247
|
|
|
226
248
|
&[data-state="open"] {
|
|
227
|
-
animation: FGbIOa_select-content-open
|
|
249
|
+
animation: FGbIOa_select-content-open
|
|
250
|
+
var(--select-transition, var(--popup-motion-duration, var(--duration-normal))
|
|
251
|
+
var(--popup-motion-easing, var(--ease-in-out)));
|
|
228
252
|
}
|
|
229
253
|
|
|
230
254
|
&[data-state="closed"] {
|
|
231
|
-
animation: FGbIOa_select-content-closed
|
|
255
|
+
animation: FGbIOa_select-content-closed
|
|
256
|
+
var(--select-transition, var(--popup-motion-duration, var(--duration-normal))
|
|
257
|
+
var(--popup-motion-easing, var(--ease-in-out)));
|
|
232
258
|
pointer-events: none;
|
|
233
259
|
}
|
|
234
260
|
}
|
|
@@ -253,31 +279,31 @@
|
|
|
253
279
|
}
|
|
254
280
|
|
|
255
281
|
.FGbIOa_itemGroupLabel {
|
|
256
|
-
padding-block: var(--select-item-group-label-padding-y,
|
|
257
|
-
padding-inline: var(--select-item-group-label-padding-x,
|
|
258
|
-
color: var(--select-item-group-label-color, var(--color-muted-foreground));
|
|
259
|
-
font-size: var(--select-item-group-label-font-size, var(--text-xs));
|
|
260
|
-
font-weight: var(--select-item-group-label-font-weight, var(--weight-
|
|
261
|
-
line-height: var(--select-item-group-label-line-height, var(--line-height-text-xs));
|
|
282
|
+
padding-block: var(--select-item-group-label-padding-y, var(--popup-group-label-padding-y, var(--spacing-1)));
|
|
283
|
+
padding-inline: var(--select-item-group-label-padding-x, var(--spacing-2-5));
|
|
284
|
+
color: var(--select-item-group-label-color, var(--popup-group-label-color, var(--color-muted-foreground)));
|
|
285
|
+
font-size: var(--select-item-group-label-font-size, var(--popup-group-label-font-size, var(--text-xs)));
|
|
286
|
+
font-weight: var(--select-item-group-label-font-weight, var(--popup-group-label-font-weight, var(--weight-regular)));
|
|
287
|
+
line-height: var(--select-item-group-label-line-height, var(--popup-group-label-line-height, var(--line-height-text-xs)));
|
|
262
288
|
}
|
|
263
289
|
|
|
264
290
|
.FGbIOa_item {
|
|
265
291
|
box-sizing: border-box;
|
|
266
292
|
width: calc(100% - var(--select-item-inset-x, var(--spacing-2)));
|
|
267
|
-
min-height: var(--select-item-min-height,
|
|
293
|
+
min-height: var(--select-item-min-height, var(--popup-item-min-height, var(--size-sm)));
|
|
268
294
|
justify-content: space-between;
|
|
269
295
|
align-items: center;
|
|
270
296
|
gap: var(--select-item-gap, var(--spacing-2));
|
|
271
297
|
margin-inline: calc(var(--select-item-inset-x, var(--spacing-2)) / 2);
|
|
272
298
|
border: var(--select-item-border-width, 0) solid var(--select-item-border-color, transparent);
|
|
273
299
|
border-radius: var(--select-item-radius, var(--radius-sm));
|
|
274
|
-
padding-block: var(--select-item-padding-y, var(--spacing-
|
|
275
|
-
padding-inline: var(--select-item-padding-x,
|
|
300
|
+
padding-block: var(--select-item-padding-y, var(--popup-item-padding-y, var(--spacing-1)));
|
|
301
|
+
padding-inline: var(--select-item-padding-x, var(--popup-item-padding-x-start, var(--spacing-3)));
|
|
276
302
|
background-color: var(--select-item-bg, transparent);
|
|
277
303
|
color: var(--select-item-color, var(--select-content-color, var(--color-foreground)));
|
|
278
304
|
font: inherit;
|
|
279
|
-
font-size: var(--select-item-font-size, var(--text-sm));
|
|
280
|
-
line-height: var(--select-item-line-height, var(--line-height-text-sm));
|
|
305
|
+
font-size: var(--select-item-font-size, var(--popup-item-font-size, var(--text-sm)));
|
|
306
|
+
line-height: var(--select-item-line-height, var(--popup-item-line-height, var(--line-height-text-sm)));
|
|
281
307
|
user-select: none;
|
|
282
308
|
cursor: default;
|
|
283
309
|
outline: 0;
|
|
@@ -309,8 +335,8 @@
|
|
|
309
335
|
}
|
|
310
336
|
|
|
311
337
|
.FGbIOa_itemIndicator {
|
|
312
|
-
width: var(--select-item-indicator-size,
|
|
313
|
-
height: var(--select-item-indicator-size,
|
|
338
|
+
width: var(--select-item-indicator-size, var(--spacing-3-5));
|
|
339
|
+
height: var(--select-item-indicator-size, var(--spacing-3-5));
|
|
314
340
|
color: var(--select-item-indicator-color, currentColor);
|
|
315
341
|
flex-shrink: 0;
|
|
316
342
|
justify-content: center;
|
|
@@ -318,8 +344,8 @@
|
|
|
318
344
|
display: inline-flex;
|
|
319
345
|
|
|
320
346
|
& > svg {
|
|
321
|
-
width: var(--select-item-indicator-icon-size,
|
|
322
|
-
height: var(--select-item-indicator-icon-size,
|
|
347
|
+
width: var(--select-item-indicator-icon-size, var(--spacing-3));
|
|
348
|
+
height: var(--select-item-indicator-icon-size, var(--spacing-3));
|
|
323
349
|
}
|
|
324
350
|
}
|
|
325
351
|
|
|
@@ -333,8 +359,8 @@
|
|
|
333
359
|
}
|
|
334
360
|
|
|
335
361
|
.FGbIOa_itemTextIcon {
|
|
336
|
-
width: var(--select-item-text-icon-size,
|
|
337
|
-
height: var(--select-item-text-icon-size,
|
|
362
|
+
width: var(--select-item-text-icon-size, var(--spacing-4));
|
|
363
|
+
height: var(--select-item-text-icon-size, var(--spacing-4));
|
|
338
364
|
color: var(--select-item-text-icon-color, currentColor);
|
|
339
365
|
flex-shrink: 0;
|
|
340
366
|
justify-content: center;
|