@moduix/solid 1.0.0 → 1.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.
Files changed (119) hide show
  1. package/dist/components/accordion/Accordion.js +19 -13
  2. package/dist/components/accordion/Accordion.jsx +7 -7
  3. package/dist/components/alert/Alert.js +19 -13
  4. package/dist/components/alert/Alert.jsx +6 -6
  5. package/dist/components/angle-slider/AngleSlider.d.ts +2 -6
  6. package/dist/components/angle-slider/AngleSlider.js +21 -16
  7. package/dist/components/angle-slider/AngleSlider.jsx +9 -10
  8. package/dist/components/avatar/Avatar.js +10 -7
  9. package/dist/components/avatar/Avatar.jsx +4 -4
  10. package/dist/components/button/Button.js +0 -5
  11. package/dist/components/button/Button.jsx +1 -3
  12. package/dist/components/button/Button_module.css +1 -3
  13. package/dist/components/card/Card.js +45 -36
  14. package/dist/components/card/Card.jsx +9 -9
  15. package/dist/components/card/Card_module.css +1 -1
  16. package/dist/components/carousel/Carousel.d.ts +1 -1
  17. package/dist/components/carousel/Carousel.js +32 -23
  18. package/dist/components/carousel/Carousel.jsx +12 -13
  19. package/dist/components/checkbox/Checkbox.js +16 -14
  20. package/dist/components/checkbox/Checkbox.jsx +6 -6
  21. package/dist/components/clipboard/Clipboard.js +28 -17
  22. package/dist/components/clipboard/Clipboard.jsx +12 -11
  23. package/dist/components/collapsible/Collapsible.js +16 -11
  24. package/dist/components/collapsible/Collapsible.jsx +6 -6
  25. package/dist/components/color-picker/ColorPicker.js +69 -48
  26. package/dist/components/color-picker/ColorPicker.jsx +28 -28
  27. package/dist/components/combobox/Combobox.js +44 -31
  28. package/dist/components/combobox/Combobox.jsx +18 -18
  29. package/dist/components/command-palette/CommandPalette.js +71 -52
  30. package/dist/components/command-palette/CommandPalette.jsx +28 -31
  31. package/dist/components/container/Container_module.css +1 -1
  32. package/dist/components/date-input/DateInput.js +18 -12
  33. package/dist/components/date-input/DateInput.jsx +7 -7
  34. package/dist/components/date-picker/DatePicker.js +73 -51
  35. package/dist/components/date-picker/DatePicker.jsx +29 -29
  36. package/dist/components/dialog/Dialog.js +30 -20
  37. package/dist/components/dialog/Dialog.jsx +10 -10
  38. package/dist/components/drawer/Drawer.js +45 -30
  39. package/dist/components/drawer/Drawer.jsx +15 -15
  40. package/dist/components/editable/Editable.js +24 -17
  41. package/dist/components/editable/Editable.jsx +10 -10
  42. package/dist/components/file-upload/FileUpload.js +39 -28
  43. package/dist/components/file-upload/FileUpload.jsx +17 -17
  44. package/dist/components/floating-panel/FloatingPanel.js +35 -23
  45. package/dist/components/floating-panel/FloatingPanel.jsx +12 -12
  46. package/dist/components/hover-card/HoverCard.js +16 -11
  47. package/dist/components/hover-card/HoverCard.jsx +6 -6
  48. package/dist/components/image-cropper/ImageCropper.js +21 -14
  49. package/dist/components/image-cropper/ImageCropper.jsx +7 -7
  50. package/dist/components/kbd/Kbd.js +8 -8
  51. package/dist/components/kbd/Kbd.jsx +2 -2
  52. package/dist/components/lightbox/Lightbox.d.ts +1 -0
  53. package/dist/components/lightbox/Lightbox.js +41 -27
  54. package/dist/components/lightbox/Lightbox.jsx +13 -12
  55. package/dist/components/listbox/Listbox.js +48 -32
  56. package/dist/components/listbox/Listbox.jsx +17 -17
  57. package/dist/components/marquee/Marquee.js +18 -12
  58. package/dist/components/marquee/Marquee.jsx +6 -6
  59. package/dist/components/menu/Menu.js +64 -43
  60. package/dist/components/menu/Menu.jsx +24 -24
  61. package/dist/components/navigation-menu/NavigationMenu.js +36 -24
  62. package/dist/components/navigation-menu/NavigationMenu.jsx +12 -12
  63. package/dist/components/number-input/NumberInput.js +19 -14
  64. package/dist/components/number-input/NumberInput.jsx +9 -9
  65. package/dist/components/pagination/Pagination.js +10 -9
  66. package/dist/components/pagination/Pagination.jsx +8 -8
  67. package/dist/components/password-input/PasswordInput.js +16 -11
  68. package/dist/components/password-input/PasswordInput.jsx +6 -6
  69. package/dist/components/pin-input/PinInput.js +15 -10
  70. package/dist/components/pin-input/PinInput.jsx +6 -6
  71. package/dist/components/popover/Popover.js +37 -25
  72. package/dist/components/popover/Popover.jsx +13 -13
  73. package/dist/components/progress-circular/ProgressCircular.js +18 -13
  74. package/dist/components/progress-circular/ProgressCircular.jsx +8 -8
  75. package/dist/components/progress-linear/ProgressLinear.js +21 -14
  76. package/dist/components/progress-linear/ProgressLinear.jsx +7 -7
  77. package/dist/components/qr-code/QrCode.js +8 -7
  78. package/dist/components/qr-code/QrCode.jsx +6 -6
  79. package/dist/components/rating-group/RatingGroup.js +15 -10
  80. package/dist/components/rating-group/RatingGroup.jsx +6 -6
  81. package/dist/components/segment-group/SegmentGroup.js +17 -12
  82. package/dist/components/segment-group/SegmentGroup.jsx +7 -7
  83. package/dist/components/select/Select.js +50 -35
  84. package/dist/components/select/Select.jsx +20 -20
  85. package/dist/components/sidebar/Sidebar.js +73 -43
  86. package/dist/components/sidebar/Sidebar.jsx +35 -27
  87. package/dist/components/signature-pad/SignaturePad.js +16 -12
  88. package/dist/components/signature-pad/SignaturePad.jsx +8 -8
  89. package/dist/components/slider/Slider.js +29 -20
  90. package/dist/components/slider/Slider.jsx +11 -11
  91. package/dist/components/split-button/SplitButton.d.ts +4 -3
  92. package/dist/components/split-button/SplitButton.js +21 -9
  93. package/dist/components/split-button/SplitButton.jsx +14 -7
  94. package/dist/components/splitter/Splitter.js +13 -9
  95. package/dist/components/splitter/Splitter.jsx +5 -5
  96. package/dist/components/steps/Steps.js +34 -23
  97. package/dist/components/steps/Steps.jsx +12 -12
  98. package/dist/components/swap/Swap.js +9 -6
  99. package/dist/components/swap/Swap.jsx +3 -3
  100. package/dist/components/switch/Switch.js +9 -7
  101. package/dist/components/switch/Switch.jsx +5 -5
  102. package/dist/components/tabs/Tabs.js +18 -12
  103. package/dist/components/tabs/Tabs.jsx +6 -6
  104. package/dist/components/tags-input/TagsInput.js +28 -20
  105. package/dist/components/tags-input/TagsInput.jsx +12 -12
  106. package/dist/components/timer/Timer.js +21 -14
  107. package/dist/components/timer/Timer.jsx +7 -7
  108. package/dist/components/toast/Toast.js +11 -9
  109. package/dist/components/toast/Toast.jsx +7 -7
  110. package/dist/components/toc/Toc.js +31 -20
  111. package/dist/components/toc/Toc.jsx +10 -10
  112. package/dist/components/tooltip/Tooltip.js +13 -9
  113. package/dist/components/tooltip/Tooltip.jsx +5 -5
  114. package/dist/components/tour/Tour.js +37 -25
  115. package/dist/components/tour/Tour.jsx +13 -13
  116. package/dist/components/tree-view/TreeView.js +39 -28
  117. package/dist/components/tree-view/TreeView.jsx +17 -17
  118. package/dist/styles/animations.css +8 -8
  119. package/package.json +1 -1
@@ -19,11 +19,11 @@ function SignaturePadRoot(props) {
19
19
  get asChild () {
20
20
  return local.asChild;
21
21
  },
22
- "data-slot": "signature-pad-root",
23
22
  get ["class"] () {
24
23
  return clsx(SignaturePad_module.root, local.class);
25
24
  }
26
25
  }, others, {
26
+ "data-slot": "signature-pad-root",
27
27
  get children () {
28
28
  return createComponent(SignaturePadReadOnlyContext.Provider, {
29
29
  value: ()=>others.readOnly ?? field?.().readOnly ?? false,
@@ -50,11 +50,11 @@ function SignaturePadRootProvider(props) {
50
50
  get asChild () {
51
51
  return local.asChild;
52
52
  },
53
- "data-slot": "signature-pad-root-provider",
54
53
  get ["class"] () {
55
54
  return clsx(SignaturePad_module.root, local.class);
56
55
  }
57
56
  }, others, {
57
+ "data-slot": "signature-pad-root-provider",
58
58
  get children () {
59
59
  return local.children;
60
60
  }
@@ -67,44 +67,48 @@ function SignaturePadLabel(props) {
67
67
  'class'
68
68
  ]);
69
69
  return createComponent(SignaturePad.Label, mergeProps({
70
- "data-slot": "signature-pad-label",
71
70
  get ["class"] () {
72
71
  return clsx(SignaturePad_module.label, local.class);
73
72
  }
74
- }, others));
73
+ }, others, {
74
+ "data-slot": "signature-pad-label"
75
+ }));
75
76
  }
76
77
  function SignaturePadControl(props) {
77
78
  const [local, others] = splitProps(props, [
78
79
  'class'
79
80
  ]);
80
81
  return createComponent(SignaturePad.Control, mergeProps({
81
- "data-slot": "signature-pad-control",
82
82
  get ["class"] () {
83
83
  return clsx(SignaturePad_module.control, local.class);
84
84
  }
85
- }, others));
85
+ }, others, {
86
+ "data-slot": "signature-pad-control"
87
+ }));
86
88
  }
87
89
  function SignaturePadSegment(props) {
88
90
  const [local, others] = splitProps(props, [
89
91
  'class'
90
92
  ]);
91
93
  return createComponent(SignaturePad.Segment, mergeProps({
92
- "data-slot": "signature-pad-segment",
93
94
  get ["class"] () {
94
95
  return clsx(SignaturePad_module.segment, local.class);
95
96
  }
96
- }, others));
97
+ }, others, {
98
+ "data-slot": "signature-pad-segment"
99
+ }));
97
100
  }
98
101
  function SignaturePadGuide(props) {
99
102
  const [local, others] = splitProps(props, [
100
103
  'class'
101
104
  ]);
102
105
  return createComponent(SignaturePad.Guide, mergeProps({
103
- "data-slot": "signature-pad-guide",
104
106
  get ["class"] () {
105
107
  return clsx(SignaturePad_module.guide, local.class);
106
108
  }
107
- }, others));
109
+ }, others, {
110
+ "data-slot": "signature-pad-guide"
111
+ }));
108
112
  }
109
113
  function SignaturePadClearTrigger(props) {
110
114
  const [local, others] = splitProps(props, [
@@ -129,9 +133,9 @@ function SignaturePadClearTrigger(props) {
129
133
  get ["aria-labelledby"] () {
130
134
  return local['aria-labelledby'];
131
135
  },
132
- "data-slot": "signature-pad-clear-trigger",
133
136
  class: triggerClass
134
137
  }, others, {
138
+ "data-slot": "signature-pad-clear-trigger",
135
139
  get disabled () {
136
140
  return isDisabled();
137
141
  },
@@ -155,9 +159,9 @@ function SignaturePadClearTrigger(props) {
155
159
  }
156
160
  }));
157
161
  },
158
- "data-slot": "signature-pad-clear-trigger",
159
162
  class: triggerClass
160
163
  }, others, {
164
+ "data-slot": "signature-pad-clear-trigger",
161
165
  get disabled () {
162
166
  return isDisabled();
163
167
  }
@@ -14,7 +14,7 @@ function SignaturePadRoot(props) {
14
14
  'class'
15
15
  ]);
16
16
  const field = useFieldContext();
17
- return <SignaturePad.Root asChild={local.asChild} data-slot="signature-pad-root" class={clsx(SignaturePad_module.root, local.class)} {...others}>
17
+ return <SignaturePad.Root asChild={local.asChild} class={clsx(SignaturePad_module.root, local.class)} {...others} data-slot="signature-pad-root">
18
18
  <SignaturePadReadOnlyContext.Provider value={()=>others.readOnly ?? field?.().readOnly ?? false}>
19
19
  {local.children}
20
20
  </SignaturePadReadOnlyContext.Provider>
@@ -30,7 +30,7 @@ function SignaturePadRootProvider(props) {
30
30
  const signaturePad = others.value;
31
31
  return signaturePad[signaturePadReadOnly]?.() ?? false;
32
32
  }}>
33
- <SignaturePad.RootProvider asChild={local.asChild} data-slot="signature-pad-root-provider" class={clsx(SignaturePad_module.root, local.class)} {...others}>
33
+ <SignaturePad.RootProvider asChild={local.asChild} class={clsx(SignaturePad_module.root, local.class)} {...others} data-slot="signature-pad-root-provider">
34
34
  {local.children}
35
35
  </SignaturePad.RootProvider>
36
36
  </SignaturePadReadOnlyContext.Provider>;
@@ -39,25 +39,25 @@ function SignaturePadLabel(props) {
39
39
  const [local, others] = splitProps(props, [
40
40
  'class'
41
41
  ]);
42
- return <SignaturePad.Label data-slot="signature-pad-label" class={clsx(SignaturePad_module.label, local.class)} {...others}/>;
42
+ return <SignaturePad.Label class={clsx(SignaturePad_module.label, local.class)} {...others} data-slot="signature-pad-label"/>;
43
43
  }
44
44
  function SignaturePadControl(props) {
45
45
  const [local, others] = splitProps(props, [
46
46
  'class'
47
47
  ]);
48
- return <SignaturePad.Control data-slot="signature-pad-control" class={clsx(SignaturePad_module.control, local.class)} {...others}/>;
48
+ return <SignaturePad.Control class={clsx(SignaturePad_module.control, local.class)} {...others} data-slot="signature-pad-control"/>;
49
49
  }
50
50
  function SignaturePadSegment(props) {
51
51
  const [local, others] = splitProps(props, [
52
52
  'class'
53
53
  ]);
54
- return <SignaturePad.Segment data-slot="signature-pad-segment" class={clsx(SignaturePad_module.segment, local.class)} {...others}/>;
54
+ return <SignaturePad.Segment class={clsx(SignaturePad_module.segment, local.class)} {...others} data-slot="signature-pad-segment"/>;
55
55
  }
56
56
  function SignaturePadGuide(props) {
57
57
  const [local, others] = splitProps(props, [
58
58
  'class'
59
59
  ]);
60
- return <SignaturePad.Guide data-slot="signature-pad-guide" class={clsx(SignaturePad_module.guide, local.class)} {...others}/>;
60
+ return <SignaturePad.Guide class={clsx(SignaturePad_module.guide, local.class)} {...others} data-slot="signature-pad-guide"/>;
61
61
  }
62
62
  function SignaturePadClearTrigger(props) {
63
63
  const [local, others] = splitProps(props, [
@@ -72,7 +72,7 @@ function SignaturePadClearTrigger(props) {
72
72
  const readOnly = useContext(SignaturePadReadOnlyContext);
73
73
  const isDisabled = ()=>readOnly() || local.disabled ? true : void 0;
74
74
  const triggerClass = clsx(SignaturePad_module.clearTrigger, local.class);
75
- if (local.asChild) return <SignaturePad.ClearTrigger asChild={local.asChild} aria-label={local['aria-label']} aria-labelledby={local['aria-labelledby']} data-slot="signature-pad-clear-trigger" class={triggerClass} {...others} disabled={isDisabled()}>
75
+ if (local.asChild) return <SignaturePad.ClearTrigger asChild={local.asChild} aria-label={local['aria-label']} aria-labelledby={local['aria-labelledby']} class={triggerClass} {...others} data-slot="signature-pad-clear-trigger" disabled={isDisabled()}>
76
76
  {local.children}
77
77
  </SignaturePad.ClearTrigger>;
78
78
  return <SignaturePad.ClearTrigger asChild={(triggerProps)=>{
@@ -81,7 +81,7 @@ function SignaturePadClearTrigger(props) {
81
81
  return <CloseButton.Root {...resolvedProps} aria-label={ariaLabel} aria-labelledby={local['aria-labelledby'] ?? resolvedProps['aria-labelledby']}>
82
82
  {resolvedChildren() ?? <RotateCcwIcon aria-hidden="true"/>}
83
83
  </CloseButton.Root>;
84
- }} data-slot="signature-pad-clear-trigger" class={triggerClass} {...others} disabled={isDisabled()}/>;
84
+ }} class={triggerClass} {...others} data-slot="signature-pad-clear-trigger" disabled={isDisabled()}/>;
85
85
  }
86
86
  function SignaturePadCanvas(props) {
87
87
  return <SignaturePadControl {...props}>
@@ -22,7 +22,6 @@ function SliderRoot(props) {
22
22
  get value () {
23
23
  return local.value;
24
24
  },
25
- "data-slot": "slider-root",
26
25
  get ["data-readonly"] () {
27
26
  return local.readOnly ? '' : void 0;
28
27
  },
@@ -33,6 +32,7 @@ function SliderRoot(props) {
33
32
  return local.readOnly;
34
33
  }
35
34
  }, others, {
35
+ "data-slot": "slider-root",
36
36
  get children () {
37
37
  return local.children;
38
38
  }
@@ -51,66 +51,72 @@ function SliderRootProvider(props) {
51
51
  get value () {
52
52
  return local.value;
53
53
  },
54
- "data-slot": "slider-root-provider",
55
54
  get ["class"] () {
56
55
  return clsx(Slider_module.root, local.class);
57
56
  }
58
- }, others));
57
+ }, others, {
58
+ "data-slot": "slider-root-provider"
59
+ }));
59
60
  }
60
61
  function SliderLabel(props) {
61
62
  const [local, others] = splitProps(props, [
62
63
  'class'
63
64
  ]);
64
65
  return createComponent(Slider.Label, mergeProps({
65
- "data-slot": "slider-label",
66
66
  get ["class"] () {
67
67
  return clsx(Slider_module.label, local.class);
68
68
  }
69
- }, others));
69
+ }, others, {
70
+ "data-slot": "slider-label"
71
+ }));
70
72
  }
71
73
  function SliderValueText(props) {
72
74
  const [local, others] = splitProps(props, [
73
75
  'class'
74
76
  ]);
75
77
  return createComponent(Slider.ValueText, mergeProps({
76
- "data-slot": "slider-value-text",
77
78
  get ["class"] () {
78
79
  return clsx(Slider_module.valueText, local.class);
79
80
  }
80
- }, others));
81
+ }, others, {
82
+ "data-slot": "slider-value-text"
83
+ }));
81
84
  }
82
85
  function SliderControl(props) {
83
86
  const [local, others] = splitProps(props, [
84
87
  'class'
85
88
  ]);
86
89
  return createComponent(Slider.Control, mergeProps({
87
- "data-slot": "slider-control",
88
90
  get ["class"] () {
89
91
  return clsx(Slider_module.control, local.class);
90
92
  }
91
- }, others));
93
+ }, others, {
94
+ "data-slot": "slider-control"
95
+ }));
92
96
  }
93
97
  function SliderTrack(props) {
94
98
  const [local, others] = splitProps(props, [
95
99
  'class'
96
100
  ]);
97
101
  return createComponent(Slider.Track, mergeProps({
98
- "data-slot": "slider-track",
99
102
  get ["class"] () {
100
103
  return clsx(Slider_module.track, local.class);
101
104
  }
102
- }, others));
105
+ }, others, {
106
+ "data-slot": "slider-track"
107
+ }));
103
108
  }
104
109
  function SliderRange(props) {
105
110
  const [local, others] = splitProps(props, [
106
111
  'class'
107
112
  ]);
108
113
  return createComponent(Slider.Range, mergeProps({
109
- "data-slot": "slider-range",
110
114
  get ["class"] () {
111
115
  return clsx(Slider_module.range, local.class);
112
116
  }
113
- }, others));
117
+ }, others, {
118
+ "data-slot": "slider-range"
119
+ }));
114
120
  }
115
121
  function SliderThumb(props) {
116
122
  const [local, others] = splitProps(props, [
@@ -122,11 +128,11 @@ function SliderThumb(props) {
122
128
  get asChild () {
123
129
  return local.asChild;
124
130
  },
125
- "data-slot": "slider-thumb",
126
131
  get ["class"] () {
127
132
  return clsx(Slider_module.thumb, local.class);
128
133
  }
129
134
  }, others, {
135
+ "data-slot": "slider-thumb",
130
136
  get children () {
131
137
  return local.children;
132
138
  }
@@ -154,33 +160,36 @@ function SliderMarkerGroup(props) {
154
160
  'class'
155
161
  ]);
156
162
  return createComponent(Slider.MarkerGroup, mergeProps({
157
- "data-slot": "slider-marker-group",
158
163
  get ["class"] () {
159
164
  return clsx(Slider_module.markerGroup, local.class);
160
165
  }
161
- }, others));
166
+ }, others, {
167
+ "data-slot": "slider-marker-group"
168
+ }));
162
169
  }
163
170
  function SliderMarker(props) {
164
171
  const [local, others] = splitProps(props, [
165
172
  'class'
166
173
  ]);
167
174
  return createComponent(Slider.Marker, mergeProps({
168
- "data-slot": "slider-marker",
169
175
  get ["class"] () {
170
176
  return clsx(Slider_module.marker, local.class);
171
177
  }
172
- }, others));
178
+ }, others, {
179
+ "data-slot": "slider-marker"
180
+ }));
173
181
  }
174
182
  function SliderDraggingIndicator(props) {
175
183
  const [local, others] = splitProps(props, [
176
184
  'class'
177
185
  ]);
178
186
  return createComponent(Slider.DraggingIndicator, mergeProps({
179
- "data-slot": "slider-dragging-indicator",
180
187
  get ["class"] () {
181
188
  return clsx(Slider_module.draggingIndicator, local.class);
182
189
  }
183
- }, others));
190
+ }, others, {
191
+ "data-slot": "slider-dragging-indicator"
192
+ }));
184
193
  }
185
194
  const Slider_Slider = Object.assign(SliderRoot, {
186
195
  Root: SliderRoot,
@@ -11,7 +11,7 @@ function SliderRoot(props) {
11
11
  'readOnly',
12
12
  'value'
13
13
  ]);
14
- return <Slider.Root asChild={local.asChild} defaultValue={local.defaultValue} value={local.value} data-slot="slider-root" data-readonly={local.readOnly ? '' : void 0} class={clsx(Slider_module.root, local.class)} readOnly={local.readOnly} {...others}>
14
+ return <Slider.Root asChild={local.asChild} defaultValue={local.defaultValue} value={local.value} data-readonly={local.readOnly ? '' : void 0} class={clsx(Slider_module.root, local.class)} readOnly={local.readOnly} {...others} data-slot="slider-root">
15
15
  {local.children}
16
16
  </Slider.Root>;
17
17
  }
@@ -21,37 +21,37 @@ function SliderRootProvider(props) {
21
21
  'class',
22
22
  'value'
23
23
  ]);
24
- return <Slider.RootProvider asChild={local.asChild} value={local.value} data-slot="slider-root-provider" class={clsx(Slider_module.root, local.class)} {...others}/>;
24
+ return <Slider.RootProvider asChild={local.asChild} value={local.value} class={clsx(Slider_module.root, local.class)} {...others} data-slot="slider-root-provider"/>;
25
25
  }
26
26
  function SliderLabel(props) {
27
27
  const [local, others] = splitProps(props, [
28
28
  'class'
29
29
  ]);
30
- return <Slider.Label data-slot="slider-label" class={clsx(Slider_module.label, local.class)} {...others}/>;
30
+ return <Slider.Label class={clsx(Slider_module.label, local.class)} {...others} data-slot="slider-label"/>;
31
31
  }
32
32
  function SliderValueText(props) {
33
33
  const [local, others] = splitProps(props, [
34
34
  'class'
35
35
  ]);
36
- return <Slider.ValueText data-slot="slider-value-text" class={clsx(Slider_module.valueText, local.class)} {...others}/>;
36
+ return <Slider.ValueText class={clsx(Slider_module.valueText, local.class)} {...others} data-slot="slider-value-text"/>;
37
37
  }
38
38
  function SliderControl(props) {
39
39
  const [local, others] = splitProps(props, [
40
40
  'class'
41
41
  ]);
42
- return <Slider.Control data-slot="slider-control" class={clsx(Slider_module.control, local.class)} {...others}/>;
42
+ return <Slider.Control class={clsx(Slider_module.control, local.class)} {...others} data-slot="slider-control"/>;
43
43
  }
44
44
  function SliderTrack(props) {
45
45
  const [local, others] = splitProps(props, [
46
46
  'class'
47
47
  ]);
48
- return <Slider.Track data-slot="slider-track" class={clsx(Slider_module.track, local.class)} {...others}/>;
48
+ return <Slider.Track class={clsx(Slider_module.track, local.class)} {...others} data-slot="slider-track"/>;
49
49
  }
50
50
  function SliderRange(props) {
51
51
  const [local, others] = splitProps(props, [
52
52
  'class'
53
53
  ]);
54
- return <Slider.Range data-slot="slider-range" class={clsx(Slider_module.range, local.class)} {...others}/>;
54
+ return <Slider.Range class={clsx(Slider_module.range, local.class)} {...others} data-slot="slider-range"/>;
55
55
  }
56
56
  function SliderThumb(props) {
57
57
  const [local, others] = splitProps(props, [
@@ -59,7 +59,7 @@ function SliderThumb(props) {
59
59
  'children',
60
60
  'class'
61
61
  ]);
62
- return <Slider.Thumb asChild={local.asChild} data-slot="slider-thumb" class={clsx(Slider_module.thumb, local.class)} {...others}>
62
+ return <Slider.Thumb asChild={local.asChild} class={clsx(Slider_module.thumb, local.class)} {...others} data-slot="slider-thumb">
63
63
  {local.children}
64
64
  </Slider.Thumb>;
65
65
  }
@@ -75,19 +75,19 @@ function SliderMarkerGroup(props) {
75
75
  const [local, others] = splitProps(props, [
76
76
  'class'
77
77
  ]);
78
- return <Slider.MarkerGroup data-slot="slider-marker-group" class={clsx(Slider_module.markerGroup, local.class)} {...others}/>;
78
+ return <Slider.MarkerGroup class={clsx(Slider_module.markerGroup, local.class)} {...others} data-slot="slider-marker-group"/>;
79
79
  }
80
80
  function SliderMarker(props) {
81
81
  const [local, others] = splitProps(props, [
82
82
  'class'
83
83
  ]);
84
- return <Slider.Marker data-slot="slider-marker" class={clsx(Slider_module.marker, local.class)} {...others}/>;
84
+ return <Slider.Marker class={clsx(Slider_module.marker, local.class)} {...others} data-slot="slider-marker"/>;
85
85
  }
86
86
  function SliderDraggingIndicator(props) {
87
87
  const [local, others] = splitProps(props, [
88
88
  'class'
89
89
  ]);
90
- return <Slider.DraggingIndicator data-slot="slider-dragging-indicator" class={clsx(Slider_module.draggingIndicator, local.class)} {...others}/>;
90
+ return <Slider.DraggingIndicator class={clsx(Slider_module.draggingIndicator, local.class)} {...others} data-slot="slider-dragging-indicator"/>;
91
91
  }
92
92
  const Slider_Slider = Object.assign(SliderRoot, {
93
93
  Root: SliderRoot,
@@ -1,3 +1,4 @@
1
+ import { Menu as MenuPrimitive } from '@ark-ui/solid/menu';
1
2
  import type { ComponentProps, JSX } from 'solid-js';
2
3
  import { Button } from '../button/index.js';
3
4
  import { Menu } from '../menu/index.js';
@@ -17,14 +18,14 @@ type SplitButtonActionProps = Omit<ButtonProps, 'size' | 'variant'> & {
17
18
  size?: SplitButtonSize;
18
19
  variant?: SplitButtonVariant;
19
20
  };
20
- type SplitButtonTriggerProps = Omit<ComponentProps<typeof Menu.Trigger>, 'asChild' | 'children' | 'class'> & {
21
+ type SplitButtonTriggerProps = Omit<ComponentProps<typeof MenuPrimitive.Trigger>, 'asChild' | 'children' | 'class'> & {
21
22
  children?: JSX.Element;
22
23
  class?: string;
23
24
  size?: SplitButtonSize;
24
25
  variant?: SplitButtonVariant;
25
26
  };
26
- type SplitButtonContentProps = ComponentProps<typeof Menu.Content>;
27
- type SplitButtonPositionerProps = ComponentProps<typeof Menu.Positioner>;
27
+ type SplitButtonContentProps = ComponentProps<typeof MenuPrimitive.Content>;
28
+ type SplitButtonPositionerProps = ComponentProps<typeof MenuPrimitive.Positioner>;
28
29
  declare function SplitButtonRoot(props: SplitButtonRootProps): JSX.Element;
29
30
  declare function SplitButtonAction(props: SplitButtonActionProps): JSX.Element;
30
31
  declare function SplitButtonTrigger(props: SplitButtonTriggerProps): JSX.Element;
@@ -1,9 +1,13 @@
1
1
  import { className, createComponent, effect, insert, memo, mergeProps, setAttribute, template, use } from "solid-js/web";
2
+ import { useFocusVisible } from "@ark-ui/solid";
3
+ import { Menu } from "@ark-ui/solid/menu";
2
4
  import { clsx } from "clsx";
3
5
  import { children, createContext, splitProps, useContext } from "solid-js";
4
6
  import { ChevronDownIcon } from "../../internal/icons/ui/Icons.js";
7
+ import { OverlayPortal } from "../../internal/overlayPortal.js";
5
8
  import { Button } from "../button/index.js";
6
- import { Menu } from "../menu/index.js";
9
+ import { Menu as index_js_Menu } from "../menu/index.js";
10
+ import Menu_module from "../menu/Menu.module.js";
7
11
  import SplitButton_module from "./SplitButton.module.js";
8
12
  var _tmpl$ = /*#__PURE__*/ template("<div role=group data-scope=split-button data-part=root data-slot=split-button-root>");
9
13
  const SplitButtonContext = createContext(null);
@@ -30,7 +34,7 @@ function SplitButtonRoot(props) {
30
34
  variant: ()=>local.variant ?? 'default'
31
35
  },
32
36
  get children () {
33
- return createComponent(Menu.Root, mergeProps({
37
+ return createComponent(index_js_Menu.Root, mergeProps({
34
38
  get onSelect () {
35
39
  return local.onSelect;
36
40
  },
@@ -93,6 +97,7 @@ function SplitButtonTrigger(props) {
93
97
  'aria-label'
94
98
  ]);
95
99
  const context = useSplitButtonContext('SplitButton.Trigger');
100
+ const focusVisible = useFocusVisible();
96
101
  const resolvedChildren = children(()=>local.children);
97
102
  const isIconOnly = ()=>null == resolvedChildren();
98
103
  const ariaLabel = ()=>isIconOnly() ? local['aria-label'] ?? 'More actions' : local['aria-label'];
@@ -121,6 +126,9 @@ function SplitButtonTrigger(props) {
121
126
  },
122
127
  get ["class"] () {
123
128
  return clsx(SplitButton_module.trigger, local.class);
129
+ },
130
+ get ["data-focus-visible"] () {
131
+ return focusVisible() ? '' : void 0;
124
132
  }
125
133
  }));
126
134
  }
@@ -128,12 +136,16 @@ function SplitButtonPositioner(props) {
128
136
  const [local, others] = splitProps(props, [
129
137
  'class'
130
138
  ]);
131
- return createComponent(Menu.Positioner, mergeProps(others, {
132
- "data-slot": "split-button-positioner",
133
- get ["class"] () {
134
- return local.class;
139
+ return createComponent(OverlayPortal, {
140
+ get children () {
141
+ return createComponent(Menu.Positioner, mergeProps(others, {
142
+ "data-slot": "split-button-positioner",
143
+ get ["class"] () {
144
+ return clsx(Menu_module.positioner, local.class);
145
+ }
146
+ }));
135
147
  }
136
- }));
148
+ });
137
149
  }
138
150
  function SplitButtonContent(props) {
139
151
  const [local, others] = splitProps(props, [
@@ -147,10 +159,10 @@ function SplitButtonContent(props) {
147
159
  },
148
160
  "data-slot": "split-button-content",
149
161
  get ["class"] () {
150
- return local.class;
162
+ return clsx(Menu_module.content, local.class);
151
163
  },
152
164
  get children () {
153
- return memo(()=>!!local.asChild)() ? local.children : createComponent(Menu.Viewport, {
165
+ return memo(()=>!!local.asChild)() ? local.children : createComponent(index_js_Menu.Viewport, {
154
166
  get children () {
155
167
  return local.children;
156
168
  }
@@ -1,8 +1,12 @@
1
+ import { useFocusVisible } from "@ark-ui/solid";
2
+ import { Menu } from "@ark-ui/solid/menu";
1
3
  import { clsx } from "clsx";
2
4
  import { children, createContext, splitProps, useContext } from "solid-js";
3
5
  import { ChevronDownIcon } from "../../internal/icons/ui/Icons.jsx";
6
+ import { OverlayPortal } from "../../internal/overlayPortal.jsx";
4
7
  import { Button } from "../button/index.jsx";
5
- import { Menu } from "../menu/index.jsx";
8
+ import { Menu as index_jsx_Menu } from "../menu/index.jsx";
9
+ import Menu_module from "../menu/Menu.module.jsx";
6
10
  import SplitButton_module from "./SplitButton.module.jsx";
7
11
  const SplitButtonContext = createContext(null);
8
12
  function useSplitButtonContext(componentName) {
@@ -26,7 +30,7 @@ function SplitButtonRoot(props) {
26
30
  size: ()=>local.size ?? 'md',
27
31
  variant: ()=>local.variant ?? 'default'
28
32
  }}>
29
- <Menu.Root onSelect={local.onSelect} positioning={{
33
+ <index_jsx_Menu.Root onSelect={local.onSelect} positioning={{
30
34
  placement: 'bottom-end',
31
35
  gutter: 4,
32
36
  ...local.positioning
@@ -34,7 +38,7 @@ function SplitButtonRoot(props) {
34
38
  <div role="group" aria-label={local['aria-label']} aria-labelledby={local['aria-labelledby']} data-scope="split-button" data-part="root" data-slot="split-button-root" class={clsx(SplitButton_module.root, local.class)} ref={local.ref}>
35
39
  {local.children}
36
40
  </div>
37
- </Menu.Root>
41
+ </index_jsx_Menu.Root>
38
42
  </SplitButtonContext.Provider>;
39
43
  }
40
44
  function SplitButtonAction(props) {
@@ -55,18 +59,21 @@ function SplitButtonTrigger(props) {
55
59
  'aria-label'
56
60
  ]);
57
61
  const context = useSplitButtonContext('SplitButton.Trigger');
62
+ const focusVisible = useFocusVisible();
58
63
  const resolvedChildren = children(()=>local.children);
59
64
  const isIconOnly = ()=>null == resolvedChildren();
60
65
  const ariaLabel = ()=>isIconOnly() ? local['aria-label'] ?? 'More actions' : local['aria-label'];
61
66
  return <Menu.Trigger {...others} asChild={(triggerProps)=><Button {...triggerProps()} data-slot="split-button-trigger" size={local.size ?? context.size()} variant={local.variant ?? context.variant()} class={clsx(SplitButton_module.trigger, local.class)} aria-label={ariaLabel()}>
62
67
  {resolvedChildren() ?? <ChevronDownIcon/>}
63
- </Button>} data-slot="split-button-trigger" aria-label={ariaLabel()} class={clsx(SplitButton_module.trigger, local.class)}/>;
68
+ </Button>} data-slot="split-button-trigger" aria-label={ariaLabel()} class={clsx(SplitButton_module.trigger, local.class)} data-focus-visible={focusVisible() ? '' : void 0}/>;
64
69
  }
65
70
  function SplitButtonPositioner(props) {
66
71
  const [local, others] = splitProps(props, [
67
72
  'class'
68
73
  ]);
69
- return <Menu.Positioner {...others} data-slot="split-button-positioner" class={local.class}/>;
74
+ return <OverlayPortal>
75
+ <Menu.Positioner {...others} data-slot="split-button-positioner" class={clsx(Menu_module.positioner, local.class)}/>
76
+ </OverlayPortal>;
70
77
  }
71
78
  function SplitButtonContent(props) {
72
79
  const [local, others] = splitProps(props, [
@@ -74,8 +81,8 @@ function SplitButtonContent(props) {
74
81
  'children',
75
82
  'class'
76
83
  ]);
77
- return <Menu.Content {...others} asChild={local.asChild} data-slot="split-button-content" class={local.class}>
78
- {local.asChild ? local.children : <Menu.Viewport>{local.children}</Menu.Viewport>}
84
+ return <Menu.Content {...others} asChild={local.asChild} data-slot="split-button-content" class={clsx(Menu_module.content, local.class)}>
85
+ {local.asChild ? local.children : <index_jsx_Menu.Viewport>{local.children}</index_jsx_Menu.Viewport>}
79
86
  </Menu.Content>;
80
87
  }
81
88
  const SplitButton = Object.assign(SplitButtonRoot, {
@@ -24,14 +24,15 @@ function SplitterRoot(props) {
24
24
  get asChild () {
25
25
  return local.asChild;
26
26
  },
27
- "data-slot": "splitter-root",
28
27
  get ["class"] () {
29
28
  return clsx(Splitter_module.root, local.class);
30
29
  },
31
30
  get style () {
32
31
  return getRootStyle(local.style);
33
32
  }
34
- }, others));
33
+ }, others, {
34
+ "data-slot": "splitter-root"
35
+ }));
35
36
  }
36
37
  function SplitterRootProvider(props) {
37
38
  const [local, others] = splitProps(props, [
@@ -43,36 +44,39 @@ function SplitterRootProvider(props) {
43
44
  get asChild () {
44
45
  return local.asChild;
45
46
  },
46
- "data-slot": "splitter-root-provider",
47
47
  get ["class"] () {
48
48
  return clsx(Splitter_module.root, local.class);
49
49
  },
50
50
  get style () {
51
51
  return getRootStyle(local.style);
52
52
  }
53
- }, others));
53
+ }, others, {
54
+ "data-slot": "splitter-root-provider"
55
+ }));
54
56
  }
55
57
  function SplitterPanel(props) {
56
58
  const [local, others] = splitProps(props, [
57
59
  'class'
58
60
  ]);
59
61
  return createComponent(Splitter.Panel, mergeProps({
60
- "data-slot": "splitter-panel",
61
62
  get ["class"] () {
62
63
  return clsx(Splitter_module.panel, local.class);
63
64
  }
64
- }, others));
65
+ }, others, {
66
+ "data-slot": "splitter-panel"
67
+ }));
65
68
  }
66
69
  function SplitterResizeTriggerIndicator(props) {
67
70
  const [local, others] = splitProps(props, [
68
71
  'class'
69
72
  ]);
70
73
  return createComponent(Splitter.ResizeTriggerIndicator, mergeProps({
71
- "data-slot": "splitter-resize-trigger-indicator",
72
74
  get ["class"] () {
73
75
  return clsx(Splitter_module.resizeTriggerIndicator, local.class);
74
76
  }
75
- }, others));
77
+ }, others, {
78
+ "data-slot": "splitter-resize-trigger-indicator"
79
+ }));
76
80
  }
77
81
  function SplitterResizeTrigger(props) {
78
82
  const [local, others] = splitProps(props, [
@@ -84,11 +88,11 @@ function SplitterResizeTrigger(props) {
84
88
  get asChild () {
85
89
  return local.asChild;
86
90
  },
87
- "data-slot": "splitter-resize-trigger",
88
91
  get ["class"] () {
89
92
  return clsx(Splitter_module.resizeTrigger, local.class);
90
93
  }
91
94
  }, others, {
95
+ "data-slot": "splitter-resize-trigger",
92
96
  get children () {
93
97
  return memo(()=>!!(void 0 === local.children && !local.asChild))() ? createComponent(SplitterResizeTriggerIndicator, {}) : local.children;
94
98
  }