@moduix/solid 1.1.1 → 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.
Files changed (88) hide show
  1. package/dist/components/accordion/Accordion.js +2 -2
  2. package/dist/components/accordion/Accordion.jsx +1 -1
  3. package/dist/components/alert/Alert.js +14 -14
  4. package/dist/components/alert/Alert.jsx +6 -6
  5. package/dist/components/angle-slider/AngleSlider.js +13 -1
  6. package/dist/components/angle-slider/AngleSlider.jsx +13 -2
  7. package/dist/components/angle-slider/AngleSlider_module.css +65 -90
  8. package/dist/components/avatar/Avatar.js +3 -3
  9. package/dist/components/avatar/Avatar.jsx +1 -1
  10. package/dist/components/breadcrumbs/Breadcrumbs.d.ts +4 -4
  11. package/dist/components/breadcrumbs/Breadcrumbs.js +34 -29
  12. package/dist/components/breadcrumbs/Breadcrumbs.jsx +12 -11
  13. package/dist/components/carousel/Carousel_module.css +2 -2
  14. package/dist/components/drawer/Drawer.js +3 -3
  15. package/dist/components/drawer/Drawer.jsx +1 -1
  16. package/dist/components/highlight/Highlight_module.css +0 -1
  17. package/dist/components/image-cropper/ImageCropper.d.ts +1 -1
  18. package/dist/components/json-tree-view/JsonTreeView_module.css +9 -1
  19. package/dist/components/marquee/Marquee_module.css +12 -14
  20. package/dist/components/menu/Menu.js +11 -20
  21. package/dist/components/menu/Menu.jsx +6 -9
  22. package/dist/components/menu/Menu_module.css +1 -1
  23. package/dist/components/native-select/NativeSelect.d.ts +0 -1
  24. package/dist/components/native-select/NativeSelect.js +2 -7
  25. package/dist/components/native-select/NativeSelect.jsx +2 -4
  26. package/dist/components/native-select/NativeSelect_module.css +7 -7
  27. package/dist/components/navigation-menu/NavigationMenu.d.ts +1 -0
  28. package/dist/components/navigation-menu/NavigationMenu.js +2 -1
  29. package/dist/components/navigation-menu/NavigationMenu.jsx +2 -1
  30. package/dist/components/navigation-menu/NavigationMenu_module.css +2 -2
  31. package/dist/components/number-input/NumberInput_module.css +4 -4
  32. package/dist/components/pagination/Pagination.js +4 -4
  33. package/dist/components/pagination/Pagination.jsx +4 -4
  34. package/dist/components/pagination/Pagination_module.css +1 -1
  35. package/dist/components/password-input/PasswordInput.js +4 -13
  36. package/dist/components/password-input/PasswordInput.jsx +4 -12
  37. package/dist/components/password-input/PasswordInput_module.css +11 -3
  38. package/dist/components/progress-linear/ProgressLinear_module.css +0 -1
  39. package/dist/components/radio-group/RadioGroup.d.ts +2 -2
  40. package/dist/components/radio-group/RadioGroup_module.css +1 -4
  41. package/dist/components/rating-group/RatingGroup.js +10 -10
  42. package/dist/components/rating-group/RatingGroup.jsx +3 -3
  43. package/dist/components/rating-group/RatingGroup_module.css +2 -14
  44. package/dist/components/scroll-area/ScrollArea.d.ts +1 -1
  45. package/dist/components/segment-group/SegmentGroup.d.ts +1 -1
  46. package/dist/components/segment-group/SegmentGroup.js +1 -0
  47. package/dist/components/segment-group/SegmentGroup.jsx +1 -0
  48. package/dist/components/select/Select.module.js +1 -1
  49. package/dist/components/select/Select.module.jsx +1 -1
  50. package/dist/components/select/Select_module.css +4 -4
  51. package/dist/components/separator/Separator_module.css +6 -6
  52. package/dist/components/sidebar/Sidebar.js +46 -52
  53. package/dist/components/sidebar/Sidebar.jsx +21 -23
  54. package/dist/components/sidebar/Sidebar_module.css +1 -1
  55. package/dist/components/signature-pad/SignaturePad.d.ts +1 -1
  56. package/dist/components/slider/Slider.js +3 -3
  57. package/dist/components/slider/Slider.jsx +1 -1
  58. package/dist/components/slider/Slider_module.css +6 -4
  59. package/dist/components/split-button/SplitButton.js +7 -7
  60. package/dist/components/split-button/SplitButton.jsx +5 -6
  61. package/dist/components/split-button/SplitButton_module.css +4 -1
  62. package/dist/components/steps/Steps_module.css +1 -1
  63. package/dist/components/swap/Swap.js +6 -6
  64. package/dist/components/swap/Swap.jsx +2 -2
  65. package/dist/components/swap/Swap_module.css +0 -3
  66. package/dist/components/switch/Switch.js +6 -6
  67. package/dist/components/switch/Switch.jsx +2 -2
  68. package/dist/components/switch/Switch_module.css +2 -2
  69. package/dist/components/table/Table_module.css +4 -2
  70. package/dist/components/tabs/Tabs.js +6 -6
  71. package/dist/components/tabs/Tabs.jsx +2 -2
  72. package/dist/components/tabs/Tabs_module.css +2 -2
  73. package/dist/components/tags-input/TagsInput_module.css +5 -4
  74. package/dist/components/toast/Toast.module.js +2 -2
  75. package/dist/components/toast/Toast.module.jsx +2 -2
  76. package/dist/components/toast/Toast_module.css +4 -6
  77. package/dist/components/toc/Toc.d.ts +2 -2
  78. package/dist/components/toc/Toc.js +4 -5
  79. package/dist/components/toc/Toc.jsx +4 -5
  80. package/dist/components/toc/Toc_module.css +2 -1
  81. package/dist/components/toggle/Toggle_module.css +3 -0
  82. package/dist/components/tooltip/Tooltip_module.css +1 -3
  83. package/dist/components/tour/Tour_module.css +2 -3
  84. package/dist/components/tree-view/TreeView_module.css +7 -5
  85. package/dist/components/typeset/Typeset_module.css +6 -4
  86. package/dist/styles/animations.css +10 -0
  87. package/dist/styles/style.css +2 -0
  88. package/package.json +1 -1
@@ -1,6 +1,6 @@
1
1
  import { PasswordInput, usePasswordInput, usePasswordInputContext } from "@ark-ui/solid/password-input";
2
2
  import { clsx } from "clsx";
3
- import { children, createEffect, splitProps } from "solid-js";
3
+ import { children, splitProps } from "solid-js";
4
4
  import { EyeClosedIcon, EyeIcon } from "../../internal/icons/ui/Icons.jsx";
5
5
  import PasswordInput_module from "./PasswordInput.module.jsx";
6
6
  function PasswordInputRoot(props) {
@@ -31,19 +31,11 @@ function PasswordInputInput(props) {
31
31
  const [local, others] = splitProps(props, [
32
32
  'asChild',
33
33
  'class',
34
- 'defaultValue',
35
- 'ref'
34
+ 'defaultValue'
36
35
  ]);
37
- let inputRef;
38
- createEffect(()=>{
39
- if (inputRef) inputRef.defaultValue = String(local.defaultValue ?? '');
40
- });
41
- return <PasswordInput.Input asChild={local.asChild} {...others} {...local.asChild ? {
36
+ return <PasswordInput.Input asChild={local.asChild} {...others} {...{
42
37
  'prop:defaultValue': local.defaultValue
43
- } : {}} data-slot="password-input-input" class={clsx(PasswordInput_module.input, local.class)} ref={(element)=>{
44
- inputRef = element;
45
- if ('function' == typeof local.ref) local.ref(element);
46
- }}/>;
38
+ }} data-slot="password-input-input" class={clsx(PasswordInput_module.input, local.class)}/>;
47
39
  }
48
40
  function PasswordInputVisibilityTrigger(props) {
49
41
  const [local, others] = splitProps(props, [
@@ -115,8 +115,10 @@
115
115
  display: inline-flex;
116
116
  }
117
117
 
118
- .visibilityTrigger-UlZG7F:not([data-disabled]):not([data-readonly]):hover {
119
- color: var(--moduix-password-input-trigger-hover-color, var(--moduix-color-foreground));
118
+ @media (hover: hover) {
119
+ .visibilityTrigger-UlZG7F:not([data-disabled]):not([data-readonly]):hover {
120
+ color: var(--moduix-password-input-trigger-hover-color, var(--moduix-color-foreground));
121
+ }
120
122
  }
121
123
 
122
124
  .visibilityTrigger-UlZG7F:focus-visible {
@@ -143,7 +145,13 @@
143
145
  height: var(--moduix-password-input-icon-size, var(--moduix-button-icon-size, var(--moduix-spacing-4)));
144
146
  }
145
147
 
146
- .visibilityTrigger-UlZG7F:not([data-disabled]):not([data-readonly]):is(:hover, :focus-visible) .indicator-ede0IZ {
148
+ @media (hover: hover) {
149
+ .visibilityTrigger-UlZG7F:not([data-disabled]):not([data-readonly]):hover .indicator-ede0IZ {
150
+ background: var(--moduix-password-input-trigger-hover-bg, var(--moduix-color-muted));
151
+ }
152
+ }
153
+
154
+ .visibilityTrigger-UlZG7F:not([data-disabled]):not([data-readonly]):focus-visible .indicator-ede0IZ {
147
155
  background: var(--moduix-password-input-trigger-hover-bg, var(--moduix-color-muted));
148
156
  }
149
157
  }
@@ -14,7 +14,6 @@
14
14
  width: var(--moduix-progress-linear-vertical-width, max-content);
15
15
  height: var(--moduix-progress-linear-height, 12rem);
16
16
  grid-template-rows: auto minmax(0, 1fr);
17
- grid-template-columns: minmax(0, 1fr) auto;
18
17
  }
19
18
 
20
19
  .label-Rv3Sur {
@@ -19,8 +19,8 @@ declare function RadioGroupIndicator(props: ComponentProps<typeof RadioGroupPrim
19
19
  declare const RadioGroup: typeof RadioGroupRoot & {
20
20
  Root: typeof RadioGroupRoot;
21
21
  RootProvider: typeof RadioGroupRootProvider;
22
- Context: (props: import("@ark-ui/solid").RadioGroupContextProps) => JSX.Element;
23
- ItemContext: (props: import("@ark-ui/solid").RadioGroupItemContextProps) => JSX.Element;
22
+ Context: (props: import("@ark-ui/solid/radio-group").RadioGroupContextProps) => JSX.Element;
23
+ ItemContext: (props: import("@ark-ui/solid/radio-group").RadioGroupItemContextProps) => JSX.Element;
24
24
  Label: typeof RadioGroupLabel;
25
25
  Item: typeof RadioGroupItem;
26
26
  ItemHiddenInput: (props: RadioGroupPrimitive.ItemHiddenInputProps) => JSX.Element;
@@ -34,7 +34,6 @@
34
34
 
35
35
  .itemControl-l9dtE4 {
36
36
  box-sizing: border-box;
37
- appearance: none;
38
37
  width: var(--_radio-size, 1.25rem);
39
38
  height: var(--_radio-size, 1.25rem);
40
39
  border: var(--moduix-radio-border-width, var(--moduix-border-width-sm)) solid
@@ -53,7 +52,6 @@
53
52
  flex: none;
54
53
  justify-content: center;
55
54
  align-items: center;
56
- line-height: 0;
57
55
  display: inline-flex;
58
56
  position: relative;
59
57
  }
@@ -148,8 +146,7 @@
148
146
  background-color: var(--moduix-radio-bg-checked, var(--moduix-color-primary));
149
147
  opacity: var(--moduix-radio-group-indicator-opacity, .12);
150
148
  pointer-events: none;
151
- transition: var(--transition-property, translate)
152
- var(--moduix-radio-transition, var(--moduix-transition-default));
149
+ --transition-duration: var(--moduix-duration-normal);
153
150
  position: absolute;
154
151
  }
155
152
  }
@@ -16,13 +16,13 @@ function RatingGroupRoot(props) {
16
16
  get asChild () {
17
17
  return local.asChild;
18
18
  },
19
- get ["data-size"] () {
20
- return local.size ?? 'md';
21
- },
22
19
  get ["class"] () {
23
20
  return clsx(RatingGroup_module.root, local.class);
24
21
  }
25
22
  }, others, {
23
+ get ["data-size"] () {
24
+ return local.size ?? 'md';
25
+ },
26
26
  "data-slot": "rating-group-root",
27
27
  get children () {
28
28
  return local.children;
@@ -40,13 +40,13 @@ function RatingGroupRootProvider(props) {
40
40
  get asChild () {
41
41
  return local.asChild;
42
42
  },
43
- get ["data-size"] () {
44
- return local.size ?? 'md';
45
- },
46
43
  get ["class"] () {
47
44
  return clsx(RatingGroup_module.root, local.class);
48
45
  }
49
46
  }, others, {
47
+ get ["data-size"] () {
48
+ return local.size ?? 'md';
49
+ },
50
50
  "data-slot": "rating-group-root-provider",
51
51
  get children () {
52
52
  return local.children;
@@ -99,16 +99,16 @@ function RatingGroupItemIndicator(props) {
99
99
  return (()=>{
100
100
  var _el$ = _tmpl$();
101
101
  spread(_el$, mergeProps({
102
+ get ["class"] () {
103
+ return clsx(RatingGroup_module.itemIndicator, local.class);
104
+ }
105
+ }, others, {
102
106
  get ["data-half"] () {
103
107
  return item().half ? '' : void 0;
104
108
  },
105
109
  get ["data-highlighted"] () {
106
110
  return item().highlighted ? '' : void 0;
107
111
  },
108
- get ["class"] () {
109
- return clsx(RatingGroup_module.itemIndicator, local.class);
110
- }
111
- }, others, {
112
112
  "data-slot": "rating-group-item-indicator"
113
113
  }), false, true);
114
114
  insert(_el$, ()=>resolvedChildren() ?? [
@@ -10,7 +10,7 @@ function RatingGroupRoot(props) {
10
10
  'class',
11
11
  'size'
12
12
  ]);
13
- return <RatingGroup.Root asChild={local.asChild} data-size={local.size ?? 'md'} class={clsx(RatingGroup_module.root, local.class)} {...others} data-slot="rating-group-root">
13
+ return <RatingGroup.Root asChild={local.asChild} class={clsx(RatingGroup_module.root, local.class)} {...others} data-size={local.size ?? 'md'} data-slot="rating-group-root">
14
14
  {local.children}
15
15
  </RatingGroup.Root>;
16
16
  }
@@ -21,7 +21,7 @@ function RatingGroupRootProvider(props) {
21
21
  'class',
22
22
  'size'
23
23
  ]);
24
- return <RatingGroup.RootProvider asChild={local.asChild} data-size={local.size ?? 'md'} class={clsx(RatingGroup_module.root, local.class)} {...others} data-slot="rating-group-root-provider">
24
+ return <RatingGroup.RootProvider asChild={local.asChild} class={clsx(RatingGroup_module.root, local.class)} {...others} data-size={local.size ?? 'md'} data-slot="rating-group-root-provider">
25
25
  {local.children}
26
26
  </RatingGroup.RootProvider>;
27
27
  }
@@ -50,7 +50,7 @@ function RatingGroupItemIndicator(props) {
50
50
  ]);
51
51
  const resolvedChildren = children(()=>local.children);
52
52
  const item = useRatingGroupItemContext();
53
- return <span data-half={item().half ? '' : void 0} data-highlighted={item().highlighted ? '' : void 0} class={clsx(RatingGroup_module.itemIndicator, local.class)} {...others} data-slot="rating-group-item-indicator">
53
+ return <span class={clsx(RatingGroup_module.itemIndicator, local.class)} {...others} data-half={item().half ? '' : void 0} data-highlighted={item().highlighted ? '' : void 0} data-slot="rating-group-item-indicator">
54
54
  {resolvedChildren() ?? <>
55
55
  <RatingStarIcon data-slot="rating-group-item-indicator-bg" class={RatingGroup_module.iconBg}/>
56
56
  <RatingStarIcon data-slot="rating-group-item-indicator-fg" class={RatingGroup_module.iconFg}/>
@@ -55,12 +55,8 @@
55
55
  cursor: pointer;
56
56
  transition: color var(--moduix-rating-group-transition, var(--moduix-transition-default)),
57
57
  opacity var(--moduix-rating-group-transition, var(--moduix-transition-default));
58
- background-color: #0000;
59
- border: 0;
60
58
  justify-content: center;
61
59
  align-items: center;
62
- margin: 0;
63
- padding: 0;
64
60
  line-height: 0;
65
61
  display: inline-flex;
66
62
  }
@@ -73,7 +69,7 @@
73
69
  pointer-events: none;
74
70
  }
75
71
 
76
- .item-KSLnDf[data-focus-visible] {
72
+ .item-KSLnDf:focus-visible {
77
73
  outline: var(--moduix-rating-group-focus-ring-width, var(--moduix-focus-ring-inset-width, var(--moduix-border-width-sm)))
78
74
  solid var(--moduix-rating-group-focus-ring-color, var(--moduix-color-ring));
79
75
  outline-offset: var(--moduix-rating-group-focus-ring-offset, var(--moduix-border-width-sm));
@@ -107,15 +103,7 @@
107
103
  clip-path: inset(0 100% 0 0);
108
104
  }
109
105
 
110
- .item-KSLnDf[data-half] .iconFg-SJSzOf {
111
- clip-path: inset(0 50% 0 0);
112
- }
113
-
114
- .item-KSLnDf:not([data-highlighted]) .iconFg-SJSzOf {
115
- clip-path: inset(0 100% 0 0);
116
- }
117
-
118
- .root-estfrz:is(:lang(ae), :lang(ar), :lang(arc), :lang(bcc), :lang(bqi), :lang(ckb), :lang(dv), :lang(fa), :lang(glk), :lang(he), :lang(ku), :lang(mzn), :lang(nqo), :lang(pnb), :lang(ps), :lang(sd), :lang(ug), :lang(ur), :lang(yi)) .itemIndicator-vRie_M[data-half] .iconFg-SJSzOf, .root-estfrz:is(:lang(ae), :lang(ar), :lang(arc), :lang(bcc), :lang(bqi), :lang(ckb), :lang(dv), :lang(fa), :lang(glk), :lang(he), :lang(ku), :lang(mzn), :lang(nqo), :lang(pnb), :lang(ps), :lang(sd), :lang(ug), :lang(ur), :lang(yi)) .item-KSLnDf[data-half] .iconFg-SJSzOf {
106
+ .root-estfrz:is(:lang(ae), :lang(ar), :lang(arc), :lang(bcc), :lang(bqi), :lang(ckb), :lang(dv), :lang(fa), :lang(glk), :lang(he), :lang(ku), :lang(mzn), :lang(nqo), :lang(pnb), :lang(ps), :lang(sd), :lang(ug), :lang(ur), :lang(yi)) .itemIndicator-vRie_M[data-half] .iconFg-SJSzOf {
119
107
  clip-path: inset(0 0 0 50%);
120
108
  }
121
109
 
@@ -24,7 +24,7 @@ declare const ScrollArea: typeof ScrollAreaRoot & {
24
24
  Scrollbar: typeof ScrollAreaScrollbar;
25
25
  Thumb: typeof ScrollAreaThumb;
26
26
  Corner: typeof ScrollAreaCorner;
27
- useScrollArea: (props?: import("@ark-ui/solid").UseScrollAreaProps) => import("@ark-ui/solid").UseScrollAreaReturn;
27
+ useScrollArea: (props?: import("@ark-ui/solid/scroll-area").UseScrollAreaProps) => import("@ark-ui/solid/scroll-area").UseScrollAreaReturn;
28
28
  };
29
29
  export { ScrollArea, useScrollArea, useScrollAreaContext };
30
30
  export type { ModuixScrollAreaRootProps, ModuixScrollAreaRootProviderProps };
@@ -6,7 +6,7 @@ type SegmentGroupOption = {
6
6
  label: JSX.Element;
7
7
  disabled?: boolean;
8
8
  };
9
- declare function useSegmentGroup(props?: SegmentGroupMachineProps): import("@ark-ui/solid").UseSegmentGroupReturn;
9
+ declare function useSegmentGroup(props?: SegmentGroupMachineProps): import("@ark-ui/solid/segment-group").UseSegmentGroupReturn;
10
10
  declare function SegmentGroupRoot(props: ComponentProps<typeof SegmentGroupPrimitive.Root>): JSX.Element;
11
11
  declare function SegmentGroupRootProvider(props: ComponentProps<typeof SegmentGroupPrimitive.RootProvider>): JSX.Element;
12
12
  declare function SegmentGroupLabel(props: ComponentProps<typeof SegmentGroupPrimitive.Label>): JSX.Element;
@@ -14,6 +14,7 @@ function SegmentGroup_useSegmentGroup(props) {
14
14
  return useSegmentGroup(()=>{
15
15
  const machineProps = 'function' == typeof props ? props() : props;
16
16
  return omitUndefined({
17
+ orientation: 'horizontal',
17
18
  disabled: field?.()?.disabled ?? fieldset?.()?.disabled,
18
19
  invalid: field?.()?.invalid ?? fieldset?.()?.invalid,
19
20
  readOnly: field?.()?.readOnly,
@@ -13,6 +13,7 @@ function SegmentGroup_useSegmentGroup(props) {
13
13
  return useSegmentGroup(()=>{
14
14
  const machineProps = 'function' == typeof props ? props() : props;
15
15
  return omitUndefined({
16
+ orientation: 'horizontal',
16
17
  disabled: field?.()?.disabled ?? fieldset?.()?.disabled,
17
18
  invalid: field?.()?.invalid ?? fieldset?.()?.invalid,
18
19
  readOnly: field?.()?.readOnly,
@@ -4,10 +4,10 @@ const Select_module = {
4
4
  label: "label-WNAZBK",
5
5
  control: "control-QCSm_x",
6
6
  trigger: "trigger-_8XyWR",
7
- clearTrigger: "clearTrigger-bA52Dh",
8
7
  valueText: "valueText-ZjlEZ9",
9
8
  itemText: "itemText-yYAdr3",
10
9
  indicator: "indicator-ywAB27",
10
+ clearTrigger: "clearTrigger-bA52Dh",
11
11
  positioner: "positioner-mCDY9D",
12
12
  content: "content-fSDhut",
13
13
  "select-content-open": "select-content-open-BbqYJQ",
@@ -4,10 +4,10 @@ const Select_module = {
4
4
  label: "label-WNAZBK",
5
5
  control: "control-QCSm_x",
6
6
  trigger: "trigger-_8XyWR",
7
- clearTrigger: "clearTrigger-bA52Dh",
8
7
  valueText: "valueText-ZjlEZ9",
9
8
  itemText: "itemText-yYAdr3",
10
9
  indicator: "indicator-ywAB27",
10
+ clearTrigger: "clearTrigger-bA52Dh",
11
11
  positioner: "positioner-mCDY9D",
12
12
  content: "content-fSDhut",
13
13
  "select-content-open": "select-content-open-BbqYJQ",
@@ -103,6 +103,10 @@
103
103
  color: var(--moduix-select-placeholder-color, var(--moduix-color-muted-foreground));
104
104
  }
105
105
 
106
+ .trigger-_8XyWR:not([data-placeholder-shown]) {
107
+ padding-inline-end: var(--moduix-select-trigger-padding-x-end, 4.25rem);
108
+ }
109
+
106
110
  .trigger-_8XyWR[data-disabled], .trigger-_8XyWR[disabled] {
107
111
  cursor: default;
108
112
  }
@@ -117,10 +121,6 @@
117
121
  outline-color: var(--moduix-select-invalid-color, var(--moduix-color-destructive));
118
122
  }
119
123
 
120
- .control-QCSm_x:has(.clearTrigger-bA52Dh:not([hidden])) .trigger-_8XyWR {
121
- padding-inline-end: var(--moduix-select-trigger-padding-x-end, 4.25rem);
122
- }
123
-
124
124
  .valueText-ZjlEZ9, .itemText-yYAdr3 {
125
125
  text-overflow: ellipsis;
126
126
  white-space: nowrap;
@@ -9,19 +9,19 @@
9
9
  }
10
10
 
11
11
  .root-q9iyyK[data-size="xs"] {
12
- --moduix-separator-size-thickness: var(--moduix-separator-thickness-xs, .5px);
12
+ --_separator-size-thickness: var(--moduix-separator-thickness-xs, .5px);
13
13
  }
14
14
 
15
15
  .root-q9iyyK[data-size="sm"] {
16
- --moduix-separator-size-thickness: var(--moduix-separator-thickness-sm, var(--moduix-border-width-sm));
16
+ --_separator-size-thickness: var(--moduix-separator-thickness-sm, var(--moduix-border-width-sm));
17
17
  }
18
18
 
19
19
  .root-q9iyyK[data-size="md"] {
20
- --moduix-separator-size-thickness: var(--moduix-separator-thickness-md, var(--moduix-border-width-md));
20
+ --_separator-size-thickness: var(--moduix-separator-thickness-md, var(--moduix-border-width-md));
21
21
  }
22
22
 
23
23
  .root-q9iyyK[data-size="lg"] {
24
- --moduix-separator-size-thickness: var(--moduix-separator-thickness-lg, 3px);
24
+ --_separator-size-thickness: var(--moduix-separator-thickness-lg, 3px);
25
25
  }
26
26
 
27
27
  .root-q9iyyK[data-variant="dashed"] {
@@ -34,14 +34,14 @@
34
34
 
35
35
  .root-q9iyyK[data-orientation="horizontal"] {
36
36
  width: var(--moduix-separator-length-horizontal, 100%);
37
- border-block-start-width: var(--moduix-separator-thickness, var(--moduix-separator-size-thickness, var(--moduix-border-width-sm)));
37
+ border-block-start-width: var(--moduix-separator-thickness, var(--_separator-size-thickness, var(--moduix-border-width-sm)));
38
38
  height: 0;
39
39
  }
40
40
 
41
41
  .root-q9iyyK[data-orientation="vertical"] {
42
42
  width: 0;
43
43
  height: var(--moduix-separator-length-vertical, 1em);
44
- border-inline-start-width: var(--moduix-separator-thickness, var(--moduix-separator-size-thickness, var(--moduix-border-width-sm)));
44
+ border-inline-start-width: var(--moduix-separator-thickness, var(--_separator-size-thickness, var(--moduix-border-width-sm)));
45
45
  }
46
46
  }
47
47
 
@@ -55,9 +55,7 @@ function toggleSidebarPanel(splitter, panelId) {
55
55
  splitter().collapsePanel(panelId);
56
56
  }
57
57
  function useSidebarConfig() {
58
- const config = useContext(SidebarConfigContext);
59
- if (!config) throw new Error('Sidebar components must be used within Sidebar.Root');
60
- return config;
58
+ return useContext(SidebarConfigContext);
61
59
  }
62
60
  function SidebarRoot(props) {
63
61
  const [local, others] = splitProps(props, [
@@ -212,6 +210,11 @@ function SidebarTrigger(props) {
212
210
  get ["aria-expanded"] () {
213
211
  return !collapsed();
214
212
  },
213
+ get ["class"] () {
214
+ return clsx(Sidebar_module.trigger, local.class);
215
+ },
216
+ onClick: handleClick
217
+ }, others, {
215
218
  "data-scope": "sidebar",
216
219
  "data-part": "trigger",
217
220
  get ["data-side"] () {
@@ -220,11 +223,6 @@ function SidebarTrigger(props) {
220
223
  get ["data-state"] () {
221
224
  return collapsed() ? 'collapsed' : 'expanded';
222
225
  },
223
- get ["class"] () {
224
- return clsx(Sidebar_module.trigger, local.class);
225
- },
226
- onClick: handleClick
227
- }, others, {
228
226
  "data-slot": "sidebar-trigger",
229
227
  get children () {
230
228
  return memo(()=>!!(void 0 === local.children && !local.asChild))() ? createComponent(ChevronLeftIcon, {}) : local.children;
@@ -236,12 +234,12 @@ function SidebarLabel(props) {
236
234
  'class'
237
235
  ]);
238
236
  return createComponent(ark.span, mergeProps({
239
- "data-scope": "sidebar",
240
- "data-part": "label",
241
237
  get ["class"] () {
242
238
  return clsx(Sidebar_module.label, local.class);
243
239
  }
244
240
  }, others, {
241
+ "data-scope": "sidebar",
242
+ "data-part": "label",
245
243
  "data-slot": "sidebar-label"
246
244
  }));
247
245
  }
@@ -250,12 +248,12 @@ function SidebarHeader(props) {
250
248
  'class'
251
249
  ]);
252
250
  return createComponent(ark.header, mergeProps({
253
- "data-scope": "sidebar",
254
- "data-part": "header",
255
251
  get ["class"] () {
256
252
  return clsx(Sidebar_module.header, local.class);
257
253
  }
258
254
  }, others, {
255
+ "data-scope": "sidebar",
256
+ "data-part": "header",
259
257
  "data-slot": "sidebar-header"
260
258
  }));
261
259
  }
@@ -264,12 +262,12 @@ function SidebarContent(props) {
264
262
  'class'
265
263
  ]);
266
264
  return createComponent(ark.div, mergeProps({
267
- "data-scope": "sidebar",
268
- "data-part": "content",
269
265
  get ["class"] () {
270
266
  return clsx(Sidebar_module.content, local.class);
271
267
  }
272
268
  }, others, {
269
+ "data-scope": "sidebar",
270
+ "data-part": "content",
273
271
  "data-slot": "sidebar-content"
274
272
  }));
275
273
  }
@@ -279,12 +277,12 @@ function SidebarExpandedContent(props) {
279
277
  ]);
280
278
  const { collapsed } = useSidebar();
281
279
  return createComponent(ark.div, mergeProps({
282
- "data-scope": "sidebar",
283
- "data-part": "expanded-content",
284
280
  get ["class"] () {
285
281
  return local.class;
286
282
  }
287
283
  }, others, {
284
+ "data-scope": "sidebar",
285
+ "data-part": "expanded-content",
288
286
  "data-slot": "sidebar-expanded-content",
289
287
  get hidden () {
290
288
  return collapsed();
@@ -297,12 +295,12 @@ function SidebarCollapsedContent(props) {
297
295
  ]);
298
296
  const { collapsed } = useSidebar();
299
297
  return createComponent(ark.div, mergeProps({
300
- "data-scope": "sidebar",
301
- "data-part": "collapsed-content",
302
298
  get ["class"] () {
303
299
  return local.class;
304
300
  }
305
301
  }, others, {
302
+ "data-scope": "sidebar",
303
+ "data-part": "collapsed-content",
306
304
  "data-slot": "sidebar-collapsed-content",
307
305
  get hidden () {
308
306
  return !collapsed();
@@ -314,12 +312,12 @@ function SidebarFooter(props) {
314
312
  'class'
315
313
  ]);
316
314
  return createComponent(ark.footer, mergeProps({
317
- "data-scope": "sidebar",
318
- "data-part": "footer",
319
315
  get ["class"] () {
320
316
  return clsx(Sidebar_module.footer, local.class);
321
317
  }
322
318
  }, others, {
319
+ "data-scope": "sidebar",
320
+ "data-part": "footer",
323
321
  "data-slot": "sidebar-footer"
324
322
  }));
325
323
  }
@@ -328,12 +326,12 @@ function SidebarGroup(props) {
328
326
  'class'
329
327
  ]);
330
328
  return createComponent(ark.section, mergeProps({
331
- "data-scope": "sidebar",
332
- "data-part": "group",
333
329
  get ["class"] () {
334
330
  return clsx(Sidebar_module.group, local.class);
335
331
  }
336
332
  }, others, {
333
+ "data-scope": "sidebar",
334
+ "data-part": "group",
337
335
  "data-slot": "sidebar-group"
338
336
  }));
339
337
  }
@@ -342,12 +340,12 @@ function SidebarGroupLabel(props) {
342
340
  'class'
343
341
  ]);
344
342
  return createComponent(ark.h3, mergeProps({
345
- "data-scope": "sidebar",
346
- "data-part": "group-label",
347
343
  get ["class"] () {
348
344
  return clsx(Sidebar_module.groupLabel, local.class);
349
345
  }
350
346
  }, others, {
347
+ "data-scope": "sidebar",
348
+ "data-part": "group-label",
351
349
  "data-slot": "sidebar-group-label"
352
350
  }));
353
351
  }
@@ -356,12 +354,12 @@ function SidebarGroupHeader(props) {
356
354
  'class'
357
355
  ]);
358
356
  return createComponent(ark.div, mergeProps({
359
- "data-scope": "sidebar",
360
- "data-part": "group-header",
361
357
  get ["class"] () {
362
358
  return clsx(Sidebar_module.groupHeader, local.class);
363
359
  }
364
360
  }, others, {
361
+ "data-scope": "sidebar",
362
+ "data-part": "group-header",
365
363
  "data-slot": "sidebar-group-header"
366
364
  }));
367
365
  }
@@ -374,12 +372,12 @@ function SidebarGroupAction(props) {
374
372
  get type () {
375
373
  return local.type ?? 'button';
376
374
  },
377
- "data-scope": "sidebar",
378
- "data-part": "group-action",
379
375
  get ["class"] () {
380
376
  return clsx(Sidebar_module.groupAction, local.class);
381
377
  }
382
378
  }, others, {
379
+ "data-scope": "sidebar",
380
+ "data-part": "group-action",
383
381
  "data-slot": "sidebar-group-action"
384
382
  }));
385
383
  }
@@ -388,12 +386,12 @@ function SidebarNavigationList(props) {
388
386
  'class'
389
387
  ]);
390
388
  return createComponent(ark.ul, mergeProps({
391
- "data-scope": "sidebar",
392
- "data-part": "navigation-list",
393
389
  get ["class"] () {
394
390
  return clsx(Sidebar_module.menu, local.class);
395
391
  }
396
392
  }, others, {
393
+ "data-scope": "sidebar",
394
+ "data-part": "navigation-list",
397
395
  "data-slot": "sidebar-navigation-list"
398
396
  }));
399
397
  }
@@ -402,12 +400,12 @@ function SidebarNavigationItem(props) {
402
400
  'class'
403
401
  ]);
404
402
  return createComponent(ark.li, mergeProps({
405
- "data-scope": "sidebar",
406
- "data-part": "navigation-item",
407
403
  get ["class"] () {
408
404
  return clsx(Sidebar_module.menuItem, local.class);
409
405
  }
410
406
  }, others, {
407
+ "data-scope": "sidebar",
408
+ "data-part": "navigation-item",
411
409
  "data-slot": "sidebar-navigation-item"
412
410
  }));
413
411
  }
@@ -430,6 +428,10 @@ function SidebarNavigationButton(props) {
430
428
  get ["aria-current"] () {
431
429
  return local['aria-current'] ?? (local.active ? 'page' : void 0);
432
430
  },
431
+ get ["class"] () {
432
+ return clsx(Sidebar_module.menuButton, local.class);
433
+ }
434
+ }, others, {
433
435
  "data-scope": "sidebar",
434
436
  "data-part": "navigation-button",
435
437
  get ["data-active"] () {
@@ -438,10 +440,6 @@ function SidebarNavigationButton(props) {
438
440
  get ["data-size"] () {
439
441
  return local.size ?? 'md';
440
442
  },
441
- get ["class"] () {
442
- return clsx(Sidebar_module.menuButton, local.class);
443
- }
444
- }, others, {
445
443
  "data-slot": "sidebar-navigation-button"
446
444
  }));
447
445
  }
@@ -450,12 +448,12 @@ function SidebarNavigationBadge(props) {
450
448
  'class'
451
449
  ]);
452
450
  return createComponent(ark.span, mergeProps({
453
- "data-scope": "sidebar",
454
- "data-part": "navigation-badge",
455
451
  get ["class"] () {
456
452
  return clsx(Sidebar_module.menuBadge, local.class);
457
453
  }
458
454
  }, others, {
455
+ "data-scope": "sidebar",
456
+ "data-part": "navigation-badge",
459
457
  "data-slot": "sidebar-navigation-badge"
460
458
  }));
461
459
  }
@@ -464,12 +462,12 @@ function SidebarNavigationSubList(props) {
464
462
  'class'
465
463
  ]);
466
464
  return createComponent(ark.ul, mergeProps({
467
- "data-scope": "sidebar",
468
- "data-part": "navigation-sub-list",
469
465
  get ["class"] () {
470
466
  return clsx(Sidebar_module.menuSub, local.class);
471
467
  }
472
468
  }, others, {
469
+ "data-scope": "sidebar",
470
+ "data-part": "navigation-sub-list",
473
471
  "data-slot": "sidebar-navigation-sub-list"
474
472
  }));
475
473
  }
@@ -478,12 +476,12 @@ function SidebarNavigationSubItem(props) {
478
476
  'class'
479
477
  ]);
480
478
  return createComponent(ark.li, mergeProps({
481
- "data-scope": "sidebar",
482
- "data-part": "navigation-sub-item",
483
479
  get ["class"] () {
484
480
  return clsx(Sidebar_module.menuSubItem, local.class);
485
481
  }
486
482
  }, others, {
483
+ "data-scope": "sidebar",
484
+ "data-part": "navigation-sub-item",
487
485
  "data-slot": "sidebar-navigation-sub-item"
488
486
  }));
489
487
  }
@@ -502,15 +500,15 @@ function SidebarNavigationSubButton(props) {
502
500
  get ["aria-current"] () {
503
501
  return local['aria-current'] ?? (local.active ? 'page' : void 0);
504
502
  },
503
+ get ["class"] () {
504
+ return clsx(Sidebar_module.menuSubButton, local.class);
505
+ }
506
+ }, others, {
505
507
  "data-scope": "sidebar",
506
508
  "data-part": "navigation-sub-button",
507
509
  get ["data-active"] () {
508
510
  return local.active ? '' : void 0;
509
511
  },
510
- get ["class"] () {
511
- return clsx(Sidebar_module.menuSubButton, local.class);
512
- }
513
- }, others, {
514
512
  "data-slot": "sidebar-navigation-sub-button",
515
513
  get children () {
516
514
  return memo(()=>'string' == typeof local.children)() ? (()=>{
@@ -575,9 +573,7 @@ function SidebarInput(props) {
575
573
  get ["class"] () {
576
574
  return clsx(Sidebar_module.input, local.class);
577
575
  }
578
- }, others, {
579
- "data-slot": "sidebar-input"
580
- }));
576
+ }, others));
581
577
  }
582
578
  function SidebarSeparator(props) {
583
579
  const [local, others] = splitProps(props, [
@@ -587,9 +583,7 @@ function SidebarSeparator(props) {
587
583
  get ["class"] () {
588
584
  return clsx(Sidebar_module.separator, local.class);
589
585
  }
590
- }, others, {
591
- "data-slot": "sidebar-separator"
592
- }));
586
+ }, others));
593
587
  }
594
588
  const Sidebar = Object.assign(SidebarRoot, {
595
589
  Root: SidebarRoot,