@plastic-js/tsumiki 0.1.22 → 0.1.24

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 (199) hide show
  1. package/README.md +838 -65
  2. package/dist/components/Accordion.js +93 -4
  3. package/dist/components/Avatar.js +96 -4
  4. package/dist/components/BottomSheet.js +131 -0
  5. package/dist/components/Button.js +194 -0
  6. package/dist/components/CardNumberInput.js +28 -44
  7. package/dist/components/Carousel.js +71 -5
  8. package/dist/components/Checkbox.js +178 -4
  9. package/dist/components/Clipboard.js +135 -5
  10. package/dist/components/CloseButton.js +97 -0
  11. package/dist/components/Collapsible.js +22 -4
  12. package/dist/components/ColorPicker.js +327 -4
  13. package/dist/components/Combobox.js +86 -13
  14. package/dist/components/ConfirmDialog.js +174 -19
  15. package/dist/components/DateInput.js +437 -5
  16. package/dist/components/{DatePickerMobile/wheel.js → DateWheel.js} +1 -3
  17. package/dist/components/Dialog.js +214 -110
  18. package/dist/components/Drawer.js +169 -4
  19. package/dist/components/Field.js +121 -5
  20. package/dist/components/Fieldset.js +64 -5
  21. package/dist/components/FileUpload.js +181 -4
  22. package/dist/components/FocusTrap.js +0 -2
  23. package/dist/components/Icon.js +32 -17
  24. package/dist/components/Input.js +211 -0
  25. package/dist/components/Listbox.js +47 -4
  26. package/dist/components/Menu.js +99 -4
  27. package/dist/components/MoneyInput.js +33 -85
  28. package/dist/components/NumberInput.js +117 -4
  29. package/dist/components/Pagination.js +91 -5
  30. package/dist/components/Popover.js +123 -4
  31. package/dist/components/Portal.js +0 -2
  32. package/dist/components/Presence.js +0 -2
  33. package/dist/components/Progress.js +107 -4
  34. package/dist/components/RadioGroup.js +104 -4
  35. package/dist/components/RatingGroup.js +75 -4
  36. package/dist/components/SearchInput.js +60 -55
  37. package/dist/components/Select.js +428 -5
  38. package/dist/components/SelectPc.js +239 -0
  39. package/dist/components/SignaturePad.js +77 -4
  40. package/dist/components/Skeleton.js +2 -4
  41. package/dist/components/Slider.js +112 -4
  42. package/dist/components/Spinner.js +41 -0
  43. package/dist/components/Splitter.js +51 -4
  44. package/dist/components/Steps.js +259 -4
  45. package/dist/components/SwipeReveal.js +2 -4
  46. package/dist/components/Switch.js +147 -4
  47. package/dist/components/Tabs.js +80 -4
  48. package/dist/components/TagsInput.js +128 -4
  49. package/dist/components/Toast.js +174 -4
  50. package/dist/components/Toggle.js +39 -4
  51. package/dist/components/ToggleGroup.js +103 -4
  52. package/dist/components/Tour.js +63 -4
  53. package/dist/components/TreeView.js +113 -4
  54. package/dist/index.js +44 -45
  55. package/dist/tsumiki.css +1 -0
  56. package/docs/api.md +670 -0
  57. package/docs/component-api-pattern.md +362 -0
  58. package/package.json +16 -6
  59. package/src/styles/color.css +112 -0
  60. package/src/styles/index.css +1 -0
  61. package/src/styles/radius.css +27 -0
  62. package/src/styles/reset.css +111 -0
  63. package/src/styles/shadow.css +5 -0
  64. package/src/styles/sizing.css +59 -0
  65. package/src/styles/spacing.css +9 -0
  66. package/src/styles/theme.css +38 -0
  67. package/src/styles/tokens.css +22 -0
  68. package/src/styles/transition.css +5 -0
  69. package/src/styles/typography.css +8 -0
  70. package/dist/components/Accordion.js.map +0 -1
  71. package/dist/components/Avatar.js.map +0 -1
  72. package/dist/components/CardNumberInput.js.map +0 -1
  73. package/dist/components/Carousel.js.map +0 -1
  74. package/dist/components/Checkbox.js.map +0 -1
  75. package/dist/components/Clipboard.js.map +0 -1
  76. package/dist/components/Collapsible.js.map +0 -1
  77. package/dist/components/ColorPicker.js.map +0 -1
  78. package/dist/components/Combobox.js.map +0 -1
  79. package/dist/components/ConfirmDialog.js.map +0 -1
  80. package/dist/components/DateInput.js.map +0 -1
  81. package/dist/components/DatePicker.js +0 -7
  82. package/dist/components/DatePicker.js.map +0 -1
  83. package/dist/components/DatePickerMobile/index.js +0 -479
  84. package/dist/components/DatePickerMobile/index.js.map +0 -1
  85. package/dist/components/DatePickerMobile/wheel.js.map +0 -1
  86. package/dist/components/Dialog.js.map +0 -1
  87. package/dist/components/Drawer.js.map +0 -1
  88. package/dist/components/Field.js.map +0 -1
  89. package/dist/components/Fieldset.js.map +0 -1
  90. package/dist/components/FileUpload.js.map +0 -1
  91. package/dist/components/FilterableSelect.js +0 -210
  92. package/dist/components/FilterableSelect.js.map +0 -1
  93. package/dist/components/FilterableSelectMobile.js +0 -167
  94. package/dist/components/FilterableSelectMobile.js.map +0 -1
  95. package/dist/components/FocusTrap.js.map +0 -1
  96. package/dist/components/HoverCard.js +0 -7
  97. package/dist/components/HoverCard.js.map +0 -1
  98. package/dist/components/Icon.js.map +0 -1
  99. package/dist/components/Listbox.js.map +0 -1
  100. package/dist/components/Menu.js.map +0 -1
  101. package/dist/components/MoneyInput.js.map +0 -1
  102. package/dist/components/NumberInput.js.map +0 -1
  103. package/dist/components/Pagination.js.map +0 -1
  104. package/dist/components/Popover.js.map +0 -1
  105. package/dist/components/Portal.js.map +0 -1
  106. package/dist/components/Presence.js.map +0 -1
  107. package/dist/components/Progress.js.map +0 -1
  108. package/dist/components/RadioGroup.js.map +0 -1
  109. package/dist/components/RatingGroup.js.map +0 -1
  110. package/dist/components/SearchInput.js.map +0 -1
  111. package/dist/components/Select.js.map +0 -1
  112. package/dist/components/SelectMobile/anatomy.js +0 -10
  113. package/dist/components/SelectMobile/anatomy.js.map +0 -1
  114. package/dist/components/SelectMobile/index.js +0 -310
  115. package/dist/components/SelectMobile/index.js.map +0 -1
  116. package/dist/components/SignaturePad.js.map +0 -1
  117. package/dist/components/Skeleton.js.map +0 -1
  118. package/dist/components/Slider.js.map +0 -1
  119. package/dist/components/Splitter.js.map +0 -1
  120. package/dist/components/Steps.js.map +0 -1
  121. package/dist/components/SwipeReveal.js.map +0 -1
  122. package/dist/components/Switch.js.map +0 -1
  123. package/dist/components/Tabs.js.map +0 -1
  124. package/dist/components/TagsInput.js.map +0 -1
  125. package/dist/components/Toast.js.map +0 -1
  126. package/dist/components/Toggle.js.map +0 -1
  127. package/dist/components/ToggleGroup.js.map +0 -1
  128. package/dist/components/Tooltip.js +0 -7
  129. package/dist/components/Tooltip.js.map +0 -1
  130. package/dist/components/Tour.js.map +0 -1
  131. package/dist/components/TreeView.js.map +0 -1
  132. package/dist/node_modules/framesync/dist/es/create-render-step.js +0 -54
  133. package/dist/node_modules/framesync/dist/es/create-render-step.js.map +0 -1
  134. package/dist/node_modules/framesync/dist/es/index.js +0 -61
  135. package/dist/node_modules/framesync/dist/es/index.js.map +0 -1
  136. package/dist/node_modules/framesync/dist/es/on-next-frame.js +0 -8
  137. package/dist/node_modules/framesync/dist/es/on-next-frame.js.map +0 -1
  138. package/dist/node_modules/hey-listen/dist/hey-listen.es.js +0 -15
  139. package/dist/node_modules/hey-listen/dist/hey-listen.es.js.map +0 -1
  140. package/dist/node_modules/popmotion/dist/es/animations/generators/decay.js +0 -24
  141. package/dist/node_modules/popmotion/dist/es/animations/generators/decay.js.map +0 -1
  142. package/dist/node_modules/popmotion/dist/es/animations/generators/keyframes.js +0 -40
  143. package/dist/node_modules/popmotion/dist/es/animations/generators/keyframes.js.map +0 -1
  144. package/dist/node_modules/popmotion/dist/es/animations/generators/spring.js +0 -96
  145. package/dist/node_modules/popmotion/dist/es/animations/generators/spring.js.map +0 -1
  146. package/dist/node_modules/popmotion/dist/es/animations/index.js +0 -94
  147. package/dist/node_modules/popmotion/dist/es/animations/index.js.map +0 -1
  148. package/dist/node_modules/popmotion/dist/es/animations/inertia.js +0 -74
  149. package/dist/node_modules/popmotion/dist/es/animations/inertia.js.map +0 -1
  150. package/dist/node_modules/popmotion/dist/es/animations/utils/detect-animation-from-options.js +0 -21
  151. package/dist/node_modules/popmotion/dist/es/animations/utils/detect-animation-from-options.js.map +0 -1
  152. package/dist/node_modules/popmotion/dist/es/animations/utils/elapsed.js +0 -14
  153. package/dist/node_modules/popmotion/dist/es/animations/utils/elapsed.js.map +0 -1
  154. package/dist/node_modules/popmotion/dist/es/animations/utils/find-spring.js +0 -68
  155. package/dist/node_modules/popmotion/dist/es/animations/utils/find-spring.js.map +0 -1
  156. package/dist/node_modules/popmotion/dist/es/easing/index.js +0 -28
  157. package/dist/node_modules/popmotion/dist/es/easing/index.js.map +0 -1
  158. package/dist/node_modules/popmotion/dist/es/easing/utils.js +0 -13
  159. package/dist/node_modules/popmotion/dist/es/easing/utils.js.map +0 -1
  160. package/dist/node_modules/popmotion/dist/es/utils/clamp.js +0 -6
  161. package/dist/node_modules/popmotion/dist/es/utils/clamp.js.map +0 -1
  162. package/dist/node_modules/popmotion/dist/es/utils/hsla-to-rgba.js +0 -35
  163. package/dist/node_modules/popmotion/dist/es/utils/hsla-to-rgba.js.map +0 -1
  164. package/dist/node_modules/popmotion/dist/es/utils/inc.js +0 -6
  165. package/dist/node_modules/popmotion/dist/es/utils/inc.js.map +0 -1
  166. package/dist/node_modules/popmotion/dist/es/utils/interpolate.js +0 -69
  167. package/dist/node_modules/popmotion/dist/es/utils/interpolate.js.map +0 -1
  168. package/dist/node_modules/popmotion/dist/es/utils/mix-color.js +0 -45
  169. package/dist/node_modules/popmotion/dist/es/utils/mix-color.js.map +0 -1
  170. package/dist/node_modules/popmotion/dist/es/utils/mix-complex.js +0 -61
  171. package/dist/node_modules/popmotion/dist/es/utils/mix-complex.js.map +0 -1
  172. package/dist/node_modules/popmotion/dist/es/utils/mix.js +0 -6
  173. package/dist/node_modules/popmotion/dist/es/utils/mix.js.map +0 -1
  174. package/dist/node_modules/popmotion/dist/es/utils/pipe.js +0 -7
  175. package/dist/node_modules/popmotion/dist/es/utils/pipe.js.map +0 -1
  176. package/dist/node_modules/popmotion/dist/es/utils/progress.js +0 -9
  177. package/dist/node_modules/popmotion/dist/es/utils/progress.js.map +0 -1
  178. package/dist/node_modules/popmotion/dist/es/utils/velocity-per-second.js +0 -8
  179. package/dist/node_modules/popmotion/dist/es/utils/velocity-per-second.js.map +0 -1
  180. package/dist/node_modules/popmotion/node_modules/tslib/tslib.es6.js +0 -13
  181. package/dist/node_modules/popmotion/node_modules/tslib/tslib.es6.js.map +0 -1
  182. package/dist/node_modules/style-value-types/dist/es/color/hex.js +0 -39
  183. package/dist/node_modules/style-value-types/dist/es/color/hex.js.map +0 -1
  184. package/dist/node_modules/style-value-types/dist/es/color/hsla.js +0 -16
  185. package/dist/node_modules/style-value-types/dist/es/color/hsla.js.map +0 -1
  186. package/dist/node_modules/style-value-types/dist/es/color/index.js +0 -20
  187. package/dist/node_modules/style-value-types/dist/es/color/index.js.map +0 -1
  188. package/dist/node_modules/style-value-types/dist/es/color/rgba.js +0 -15
  189. package/dist/node_modules/style-value-types/dist/es/color/rgba.js.map +0 -1
  190. package/dist/node_modules/style-value-types/dist/es/color/utils.js +0 -19
  191. package/dist/node_modules/style-value-types/dist/es/color/utils.js.map +0 -1
  192. package/dist/node_modules/style-value-types/dist/es/complex/index.js +0 -58
  193. package/dist/node_modules/style-value-types/dist/es/complex/index.js.map +0 -1
  194. package/dist/node_modules/style-value-types/dist/es/numbers/index.js +0 -13
  195. package/dist/node_modules/style-value-types/dist/es/numbers/index.js.map +0 -1
  196. package/dist/node_modules/style-value-types/dist/es/numbers/units.js +0 -16
  197. package/dist/node_modules/style-value-types/dist/es/numbers/units.js.map +0 -1
  198. package/dist/node_modules/style-value-types/dist/es/utils.js +0 -13
  199. package/dist/node_modules/style-value-types/dist/es/utils.js.map +0 -1
package/docs/api.md ADDED
@@ -0,0 +1,670 @@
1
+ # Tsumiki Component API Reference
2
+
3
+ > Public API contract for `@plastic-js/tsumiki` (v0.1.x).
4
+
5
+ This document is the authoritative reference for the components exported from the package root (`@plastic-js/tsumiki`). It is part of the version 1.0 API contract: anything documented here is stable; anything not documented here (deep imports into `dist/components`, `.origin` internals, or `...rest` passthrough behavior) is **not** part of the contract and may change without a major version bump.
6
+
7
+ > Components still **in development** (`Accordion`, `Carousel`, `Combobox`, `Listbox`, `Tour`, `TreeView`) are intentionally **not documented** here — their APIs are not yet frozen. They remain importable but are outside the v1 contract.
8
+
9
+ ## Conventions
10
+
11
+ ### Controlled-only
12
+
13
+ Tsumiki is **controlled-only**. State-managing components (`value`, `open`, `checked`, …) receive state as a signal and report changes via a callback. There are no `defaultValue` / `defaultOpen` / `defaultChecked` props.
14
+
15
+ ```jsx
16
+ const isOpen = createSignal(false)
17
+ <Dialog open={isOpen} onOpenChange={v => isOpen(v.open)} />
18
+ ```
19
+
20
+ ### Reactive props
21
+
22
+ Any prop may be a static value **or** a Plastic reactive getter function:
23
+
24
+ ```jsx
25
+ <Switch size="md" /> // static
26
+ <Switch size={() => mySignal()} /> // reactive
27
+ ```
28
+
29
+ ### Passthrough
30
+
31
+ Ark-backed components forward all props **not listed** in their table to the underlying Ark primitive's `Root` (unless stated otherwise). This includes Ark/Zag props, ARIA attributes, and DOM event handlers.
32
+
33
+ ### Escape hatch
34
+
35
+ Every Ark-backed component exposes `.origin` — a mapping to the raw `@plastic-js/ark` sub-parts, for when you need the full headless API:
36
+
37
+ ```jsx
38
+ <Checkbox.origin.Root>
39
+ <Checkbox.origin.Control>
40
+ <Checkbox.origin.Indicator />
41
+ </Checkbox.origin.Control>
42
+ </Checkbox.origin.Root>
43
+ ```
44
+
45
+ ### Size values
46
+
47
+ The shared `size` prop accepts: `xs | sm | md | lg | xl | xxl` (default `md`).
48
+
49
+ ---
50
+
51
+ ## Inputs & Forms
52
+
53
+ ### Field
54
+
55
+ A labeled field wrapper combining a label, an error message and helper text.
56
+
57
+ **Exports:** `Field`
58
+
59
+ | Prop | Type | Default | Description |
60
+ |---|---|---|---|
61
+ | `label` | `string` | `''` | Field label text. |
62
+ | `error` | `string` | `''` | Error message; when non-empty the field renders in its error state. |
63
+ | `helper` | `string` | `''` | Helper text below the control. |
64
+ | `required` | `boolean` | `false` | Marks the label with a required indicator. |
65
+ | `compact` | `boolean` | `false` | Renders in a compact (smaller) layout. |
66
+ | `children` | `node` | — | The input control (e.g. `<Input />`). |
67
+
68
+ ### Fieldset
69
+
70
+ Groups several `Field`s with a legend.
71
+
72
+ **Exports:** `Fieldset`
73
+
74
+ | Prop | Type | Default | Description |
75
+ |---|---|---|---|
76
+ | `legend` | `string` | `''` | Fieldset legend text. |
77
+ | `helper` | `string` | `''` | Helper text below the fields. |
78
+ | `children` | `node` | — | `Field` components to group. |
79
+
80
+ ### Input
81
+
82
+ **Exports:** `Input` · Escape hatch: `Input.origin.Root`
83
+
84
+ | Prop | Type | Default | Description |
85
+ |---|---|---|---|
86
+ | `solid` | `boolean` | `false` | Filled background instead of outlined. |
87
+ | `size` | `string` | `md` | See size values. |
88
+ | `disabled` | `boolean` | `false` | Disables the input. |
89
+ | `invalid` | `boolean` | `false` | Renders the error/invalid style. |
90
+ | `inputClassName` | `string` | — | Class applied to the raw `<input>` element. |
91
+ | `type` | `string` | — | Input type (e.g. `text`, `password`). |
92
+ | `prefix` | `node` | — | Content rendered before the input (e.g. an icon). |
93
+ | `suffix` | `node` | — | Content rendered after the input. |
94
+ | `ref` | `ref` | — | Ref to the underlying `<input>`. |
95
+
96
+ ### CardNumberInput
97
+
98
+ Credit-card number input with automatic `XXXX-XXXX-XXXX-XXXX` grouping.
99
+
100
+ **Exports:** `CardNumberInput`
101
+
102
+ | Prop | Type | Default | Description |
103
+ |---|---|---|---|
104
+ | `value` | `string \| (() => string)` | — | Card number (digits only). |
105
+ | `onValueChange` | `(value) => void` | — | Called with the raw digits. |
106
+ | `invalid` | `boolean` | `false` | Error state. |
107
+ | `disabled` | `boolean` | `false` | Disabled. |
108
+ | `placeholder` | `string` | — | Placeholder text. |
109
+
110
+ ### MoneyInput
111
+
112
+ Currency-formatted numeric input.
113
+
114
+ **Exports:** `MoneyInput`
115
+
116
+ | Prop | Type | Default | Description |
117
+ |---|---|---|---|
118
+ | `value` | `number \| (() => number)` | — | Numeric value. |
119
+ | `onValueChange` | `(value) => void` | — | Called with the parsed number. |
120
+ | `invalid` | `boolean` | `false` | Error state. |
121
+ | `currency` | `string` | — | Currency code (e.g. `TWD`, `USD`). |
122
+ | `affix` | `node` | — | Custom prefix/suffix content. |
123
+ | `placeholder` | `string` | — | Placeholder text. |
124
+ | `disabled` | `boolean` | `false` | Disabled. |
125
+
126
+ ### NumberInput
127
+
128
+ **Exports:** `NumberInput` · Escape hatch: `NumberInput.origin.{Root, DecrementTrigger, Input, IncrementTrigger}`
129
+
130
+ | Prop | Type | Default | Description |
131
+ |---|---|---|---|
132
+ | `size` | `string` | `md` | See size values. |
133
+ | `disabled` | `boolean` | `false` | Disabled. |
134
+ | `children` | `node` | — | Custom triggers, if any. |
135
+
136
+ Passthrough: Ark `Root` props (`value`, `onValueChange`, `min`, `max`, `step`, `formatOptions`, …).
137
+
138
+ ### SearchInput
139
+
140
+ **Exports:** `SearchInput`
141
+
142
+ | Prop | Type | Default | Description |
143
+ |---|---|---|---|
144
+ | `placeholder` | `string` | — | Placeholder text. |
145
+ | `onInput` | `(value) => void` | — | Called with the current query. |
146
+
147
+ ### TagsInput
148
+
149
+ **Exports:** `TagsInput` · Escape hatch: `TagsInput.origin.{Root, Label, Control, Input, Item, ItemPreview, ItemText, ItemDeleteTrigger, ItemInput, ClearTrigger, HiddenInput}`
150
+
151
+ | Prop | Type | Default | Description |
152
+ |---|---|---|---|
153
+ | `className` | `string` | — | Root class. |
154
+ | `label` | `string` | — | Optional label text. |
155
+ | `placeholder` | `string` | — | Input placeholder. |
156
+ | `children` | `node` | — | Custom item rendering. |
157
+
158
+ Passthrough: Ark `Root` props (`value`, `onValueChange`, `allowOverflow`, `validate`, …).
159
+
160
+ ### DateInput
161
+
162
+ Mobile date picker built on the `DateWheel` utility.
163
+
164
+ **Exports:** `DateInput`
165
+
166
+ | Prop | Type | Default | Description |
167
+ |---|---|---|---|
168
+ | `value` | `string \| (() => string)` | — | ISO date string. |
169
+ | `onValueChange` | `(value) => void` | — | Called with the new ISO date. |
170
+ | `placeholder` | `string` | — | Placeholder text. |
171
+ | `disabled` | `boolean` | `false` | Disabled. |
172
+ | `className` | `string` | — | Root class. |
173
+
174
+ ### ColorPicker
175
+
176
+ **Exports:** `ColorPicker` · Escape hatch: `ColorPicker.origin.*` (full Ark surface: `Root`, `Label`, `Control`, `Trigger`, `Positioner`, `Content`, `ValueSwatch`, `ValueText`, `Area`, `ChannelSlider`, `ChannelInput`, `TransparencyGrid`, `EyeDropperTrigger`, …)
177
+
178
+ | Prop | Type | Default | Description |
179
+ |---|---|---|---|
180
+ | `label` | `string` | — | Optional label text. |
181
+ | `showAlpha` | `boolean` | — | Show the alpha channel. |
182
+ | `eyedropper` | `boolean` | — | Show the eyedropper trigger. |
183
+ | `hiddenInput` | `boolean` | — | Render a hidden input. |
184
+ | `onChange` | `(value) => void` | — | Called on color change. |
185
+ | `size` | `string` | `md` | See size values. |
186
+ | `className` | `string` | — | Root class. |
187
+ | `children` | `node` | — | Custom content. |
188
+
189
+ Passthrough: Ark `Root` props (`value`, `onValueChange`, `format`, …).
190
+
191
+ ### Clipboard
192
+
193
+ **Exports:** `Clipboard`
194
+
195
+ | Prop | Type | Default | Description |
196
+ |---|---|---|---|
197
+ | `size` | `string` | `md` | See size values. |
198
+ | `copiedDuration` | `number` | `2000` | ms to keep the "copied" state after copying. |
199
+
200
+ Passthrough: Ark `Root` props (`value`, `onValueChange`, …).
201
+
202
+ ---
203
+
204
+ ## Buttons & Toggles
205
+
206
+ ### Button
207
+
208
+ **Exports:** `Button` · Escape hatch: `Button.origin.Root`
209
+
210
+ | Prop | Type | Default | Description |
211
+ |---|---|---|---|
212
+ | `solid` | `boolean` | `false` | Filled (solid) variant instead of outline. |
213
+ | `danger` | `boolean` | `false` | Destructive (red) variant. |
214
+ | `size` | `string` | `md` | See size values. |
215
+ | `disabled` | `boolean` | `false` | Disabled. |
216
+ | `loading` | `boolean` | `false` | Shows a spinner and blocks interaction. |
217
+ | `children` | `node` | — | Button content. |
218
+
219
+ ### Checkbox
220
+
221
+ **Exports:** `Checkbox` · Escape hatch: `Checkbox.origin.{Root, Label, Control, Indicator, HiddenInput, Group}`
222
+
223
+ | Prop | Type | Default | Description |
224
+ |---|---|---|---|
225
+ | `size` | `string` | `md` | See size values. |
226
+ | `rounded` | `boolean` | `true` | Rounded (pill) control shape. |
227
+ | `invalid` | `boolean` | `false` | Error state. |
228
+ | `children` | `node` | — | Label content. |
229
+
230
+ Passthrough: Ark `Root` props (`checked`, `onCheckedChange`, `disabled`, `indeterminate`, …).
231
+
232
+ ### Switch
233
+
234
+ **Exports:** `Switch` · Escape hatch: `Switch.origin.{Root, Control, Thumb, Label, HiddenInput}`
235
+
236
+ | Prop | Type | Default | Description |
237
+ |---|---|---|---|
238
+ | `size` | `string` | `md` | See size values. |
239
+ | `children` | `node` | — | Label content. |
240
+
241
+ Passthrough: Ark `Root` props (`checked`, `onCheckedChange`, `disabled`, …).
242
+
243
+ ### Toggle
244
+
245
+ **Exports:** `Toggle` · Escape hatch: `Toggle.origin.Root`
246
+
247
+ | Prop | Type | Default | Description |
248
+ |---|---|---|---|
249
+ | `className` | `string` | — | Root class. |
250
+ | `children` | `node` | — | Content. |
251
+
252
+ Passthrough: Ark `Root` props (`pressed`, `onPressedChange`, …).
253
+
254
+ ### ToggleGroup
255
+
256
+ **Exports:** `ToggleGroup`, `ToggleGroupItem` · Escape hatch: `ToggleGroup.origin.{Root, Item}`
257
+
258
+ | Prop | Type | Default | Description |
259
+ |---|---|---|---|
260
+ | `size` | `string` | `md` | See size values. |
261
+ | `children` | `node` | — | `ToggleGroupItem` elements. |
262
+
263
+ ### RadioGroup
264
+
265
+ **Exports:** `RadioGroup` · Escape hatch: `RadioGroup.origin.{Root, Label, Item, ItemControl, ItemText, ItemHiddenInput, Indicator}`
266
+
267
+ | Prop | Type | Default | Description |
268
+ |---|---|---|---|
269
+ | `label` | `string` | — | Group label text. |
270
+ | `items` | `array` | — | Data items (see `SelectPc` collection semantics). |
271
+ | `className` | `string` | — | Root class. |
272
+
273
+ Passthrough: Ark `Root` props (`value`, `onValueChange`, `disabled`, …).
274
+
275
+ ### RatingGroup
276
+
277
+ **Exports:** `RatingGroup` · Escape hatch: `RatingGroup.origin.{Root, Label, Control, Item, ItemText, HiddenInput}`
278
+
279
+ | Prop | Type | Default | Description |
280
+ |---|---|---|---|
281
+ | `count` | `number` | `5` | Number of rating items. |
282
+ | `label` | `string` | — | Optional label. |
283
+
284
+ Passthrough: Ark `Root` props (`value`, `onValueChange`, `readOnly`, …).
285
+
286
+ ---
287
+
288
+ ## Selection & Capture
289
+
290
+ ### Select
291
+
292
+ Mobile-optimized bottom-sheet select (draggable sheet overlay).
293
+
294
+ **Exports:** `Select`, `SelectTrigger`
295
+
296
+ | Prop | Type | Default | Description |
297
+ |---|---|---|---|
298
+ | `value` | `string \| (() => string)` | — | Selected value. |
299
+ | `onValueChange` | `(value) => void` | — | Called when an item is selected. |
300
+ | `items` | `array \| (() => array)` | `[]` | Data array. |
301
+ | `itemToValue` | `(item) => string` | `item.value` | Extract value from an item. |
302
+ | `itemToLabel` | `(item) => node` | `item.label` | Extract label from an item. |
303
+ | `open` | `(() => boolean)` | — | **Required** controlled open state. |
304
+ | `onOpenChange` | `(open) => void` | — | Open/close callback. |
305
+ | `disabled` | `boolean` | `false` | Disabled. |
306
+ | `clearable` | `boolean` | `false` | Show a clear trigger. |
307
+ | `clearLabel` | `string` | — | Accessible label for the clear trigger. |
308
+ | `filter` | `(item, query, itemToLabel) => boolean` | — | Custom filter for the search box. |
309
+ | `placeholder` | `string` | — | Trigger placeholder. |
310
+ | `backdropClassName` | `string` | — | Backdrop class. |
311
+ | `backdropStyle` | `object` | — | Backdrop inline styles. |
312
+ | `children` | `node` | — | Custom trigger (`SelectTrigger`). |
313
+ | `item` | `node` | — | Custom item renderer. |
314
+
315
+ ### SelectPc
316
+
317
+ Desktop (popover-style) select built on Ark `Select`.
318
+
319
+ **Exports:** `SelectPc` · Escape hatch: `SelectPc.origin.{Root, Trigger, Indicator, Positioner, Content, List, Item, ItemText, ValueText, HiddenSelect}`
320
+
321
+ | Prop | Type | Default | Description |
322
+ |---|---|---|---|
323
+ | `solid` | `boolean` | `false` | Filled trigger variant. |
324
+ | `size` | `string` | `md` | See size values. |
325
+ | `disabled` | `boolean` | `false` | Disabled. |
326
+ | `invalid` | `boolean` | `false` | Error state. |
327
+ | `positioning` | `object` | `{ sameWidth: true }` | Positioning options. |
328
+ | `children` | `node` | — | `SelectPc.origin.Item` elements or custom content. |
329
+
330
+ Passthrough: Ark `Root` props (`value`, `onValueChange`, `collection`, …). Note: unlike `Select`, it is **not** controlled-only at the tsumiki level — state flows through the Ark props.
331
+
332
+ ### FileUpload
333
+
334
+ **Exports:** `FileUpload`, `FileUploadItemGroup`, `FileUploadItem`, `FileUploadClearTrigger` · Escape hatch: `FileUpload.origin.{Root, Label, Dropzone, Trigger, ItemGroup, Item, ItemName, ItemSizeText, ItemDeleteTrigger, ClearTrigger, HiddenInput}`
335
+
336
+ | Prop | Type | Default | Description |
337
+ |---|---|---|---|
338
+ | `className` | `string` | — | Root class. |
339
+ | `file` | `object` | — | A controlled file object. |
340
+ | `children` | `node` | — | `FileUploadItemGroup` / `FileUploadItem` elements. |
341
+
342
+ Passthrough: Ark `Root` props (`accept`, `multiple`, `maxFiles`, `onFileAccept`, …).
343
+
344
+ ### SignaturePad
345
+
346
+ **Exports:** `SignaturePad`, `ClearTrigger` · no `.origin`
347
+
348
+ | Prop | Type | Default | Description |
349
+ |---|---|---|---|
350
+ | `label` | `string` | `'Signature'` | Accessible label / placeholder. |
351
+ | `height` | `number` | `160` | Canvas height in px. |
352
+ | `className` | `string` | — | Root class. |
353
+ | `children` | `node` | — | Custom content. |
354
+
355
+ ---
356
+
357
+ ## Navigation & Data
358
+
359
+ ### Tabs
360
+
361
+ **Exports:** `Tabs` · no `.origin`
362
+
363
+ | Prop | Type | Default | Description |
364
+ |---|---|---|---|
365
+ | `triggers` | `array` | — | Tab trigger definitions (`{ value, label }`). |
366
+ | `className` | `string` | — | Root class. |
367
+ | `children` | `node` | — | Tab panels keyed by value. |
368
+
369
+ Passthrough: Ark `Root` props (`value`, `onValueChange`, `orientation`, …).
370
+
371
+ ### Steps
372
+
373
+ **Exports:** `Steps` · Escape hatch: `Steps.origin.{Root, List, Item, Trigger, Content, CompletedContent, Separator, PrevTrigger, NextTrigger, Indicator, Progress}`
374
+
375
+ | Prop | Type | Default | Description |
376
+ |---|---|---|---|
377
+ | `items` | `array` | — | Step definitions (`{ title, description, ... }`). |
378
+ | `vertical` | `boolean` | `false` | Vertical layout. |
379
+ | `value` | `number` | `0` | Active step index. |
380
+ | `onValueChange` | `(value) => void` | — | Step-change callback. |
381
+ | `completedContent` | `node` | — | Content shown on the last step. |
382
+ | `className` | `string` | — | Root class. |
383
+
384
+ ### Menu
385
+
386
+ **Exports:** `Menu`, `MenuTrigger`, `MenuContent`, `MenuItem`, `MenuSeparator` · Escape hatch: `Menu.origin.{Root, Trigger, Positioner, Content, Item, Separator}`
387
+
388
+ | Prop | Type | Default | Description |
389
+ |---|---|---|---|
390
+ | `className` | `string` | — | Root class. |
391
+ | `children` | `node` | — | `MenuTrigger` / `MenuContent` elements. |
392
+
393
+ ### Pagination
394
+
395
+ **Exports:** `Pagination` · Escape hatch: `Pagination.origin.Root`
396
+
397
+ | Prop | Type | Default | Description |
398
+ |---|---|---|---|
399
+ | `prevLabel` | `string` | — | Previous-page label. |
400
+ | `nextLabel` | `string` | — | Next-page label. |
401
+ | `prevChildren` | `node` | — | Custom previous trigger content. |
402
+ | `nextChildren` | `node` | — | Custom next trigger content. |
403
+ | `className` | `string` | — | Root class. |
404
+
405
+ Passthrough: Ark `Root` props (`count`, `pageSize`, `page`, `onPageChange`, …).
406
+
407
+ ---
408
+
409
+ ## Content & Layout
410
+
411
+ ### Collapsible
412
+
413
+ **Exports:** `Collapsible` · Escape hatch: `Collapsible.origin.{Root, Trigger, Content}`
414
+
415
+ | Prop | Type | Default | Description |
416
+ |---|---|---|---|
417
+ | `className` | `string` | — | Root class. |
418
+ | `children` | `node` | — | `Trigger` / `Content` elements. |
419
+
420
+ ### Splitter
421
+
422
+ **Exports:** `Splitter`, `SplitterPanel`, `SplitterResizeTrigger`, `SplitterResizeTriggerIndicator` · Escape hatch: `Splitter.origin.{Root, Panel, ResizeTrigger, ResizeTriggerIndicator}`
423
+
424
+ Passthrough: Ark `Root` props (`size`, `onSizeChange`, `orientation`, …).
425
+
426
+ ### SwipeReveal
427
+
428
+ Touch-driven swipe-to-reveal row.
429
+
430
+ **Exports:** `SwipeReveal` · no `.origin`
431
+
432
+ | Prop | Type | Default | Description |
433
+ |---|---|---|---|
434
+ | `actions` | `array` | — | Action definitions; each item supplies `{ color, label, ... }` (background is consumer-defined). |
435
+ | `activeId` | `string` | — | The id of the currently open row. |
436
+ | `thisId` | `string` | — | This row's id (used to coordinate with `activeId`). |
437
+ | `onSwipeStart` | `() => void` | — | Called when a swipe begins. |
438
+ | `onOpenChange` | `(open) => void` | — | Open/close callback. |
439
+ | `children` | `node` | — | Row content. |
440
+
441
+ ---
442
+
443
+ ## Elements
444
+
445
+ ### Avatar
446
+
447
+ **Exports:** `Avatar`, `AvatarImage`, `AvatarFallback` · Escape hatch: `Avatar.origin.{Root, Image, Fallback}`
448
+
449
+ | Prop | Type | Default | Description |
450
+ |---|---|---|---|
451
+ | `mode` | `string` | `'image'` | `'image'` (photo) or `'initials'` (initial letter). |
452
+ | `name` | `string` | `''` | Person's name (used for initials/alt). |
453
+ | `gender` | `string` | `'male'` | Initials color treatment. |
454
+ | `src` | `string` | `''` | Image source. |
455
+ | `alt` | `string` | `''` | Image alt text. |
456
+ | `style` | `object` | — | Root inline styles. |
457
+ | `children` | `node` | — | Fallback content. |
458
+
459
+ ### Icon
460
+
461
+ **Exports:** `Icon` · no `.origin`
462
+
463
+ | Prop | Type | Default | Description |
464
+ |---|---|---|---|
465
+ | `svg` | `node` | — | The SVG element to render. |
466
+ | `size` | `number` | `22` | Icon size in px. |
467
+ | `strokeWidth` | `number` | `1.25` | Stroke width. |
468
+ | `className` | `string` | — | Root class. |
469
+
470
+ ### CloseButton
471
+
472
+ **Exports:** `CloseButton` · no `.origin`
473
+
474
+ | Prop | Type | Default | Description |
475
+ |---|---|---|---|
476
+ | `size` | `string` | `md` | See size values. |
477
+ | `className` | `string` | — | Root class. |
478
+ | `children` | `node` | — | Close icon (defaults to ✕). |
479
+
480
+ ### Skeleton
481
+
482
+ Pure-CSS loading placeholder.
483
+
484
+ **Exports:** `Skeleton` · no `.origin`
485
+
486
+ Accepts no tsumiki-specific props; `className`/style/DOM props pass through.
487
+
488
+ ### Spinner
489
+
490
+ Pure-CSS spinner.
491
+
492
+ **Exports:** `Spinner` · no `.origin`
493
+
494
+ Accepts no tsumiki-specific props; `className`/style/DOM props pass through.
495
+
496
+ ---
497
+
498
+ ## Feedback
499
+
500
+ ### Slider
501
+
502
+ **Exports:** `Slider` · Escape hatch: `Slider.origin.{Root, Label, Control, Track, Range, Thumb, DraggingIndicator, ValueText, HiddenInput}`
503
+
504
+ | Prop | Type | Default | Description |
505
+ |---|---|---|---|
506
+ | `label` | `string` | — | Accessible label. |
507
+ | `className` | `string` | — | Root class. |
508
+ | `children` | `node` | — | Custom value rendering. |
509
+
510
+ Passthrough: Ark `Root` props (`value`, `onValueChange`, `min`, `max`, `step`, `thumbAlignment`, …) — defaults `min: 0`, `max: 100`, `step: 1`, `thumbAlignment: 'center'` are supplied by tsumiki.
511
+
512
+ ### Progress
513
+
514
+ **Exports:** `Progress`, `ProgressLabel` · no `.origin`
515
+
516
+ | Prop | Type | Default | Description |
517
+ |---|---|---|---|
518
+ | `size` | `string` | `md` | See size values. |
519
+ | `striped` | `boolean` | `false` | Animated striped fill. |
520
+ | `className` | `string` | — | Root class. |
521
+
522
+ Passthrough: Ark `Root` props (`value`, `min`, `max`, …).
523
+
524
+ ---
525
+
526
+ ## Overlays
527
+
528
+ ### Dialog
529
+
530
+ **Exports:** `Dialog` · Escape hatch: `Dialog.origin.{Root, Trigger, Backdrop, Positioner, Content, Title, Description, CloseTrigger}`
531
+
532
+ | Prop | Type | Default | Description |
533
+ |---|---|---|---|
534
+ | `mode` | `string` | `'modal'` | `'modal'` or `'nonModal'`. |
535
+ | `open` | `boolean \| (() => boolean)` | — | **Required** controlled open state. |
536
+ | `onOpenChange` | `(v) => void` | — | Receives `{ open }`; sync your state here. |
537
+ | `onOpen` | `() => void` | — | Fired when opened. |
538
+ | `onClose` | `() => void` | — | Fired when closed. |
539
+ | `title` | `string` | — | Dialog title. |
540
+ | `icon` | `node` | — | Optional icon above the title. |
541
+ | `message` | `string` | — | Body text. |
542
+ | `showCancel` | `boolean` | `true` | Show the cancel button. |
543
+ | `showConfirm` | `boolean` | `true` | Show the confirm button. |
544
+ | `cancelText` | `string` | `'Cancel'` | Cancel button label. |
545
+ | `confirmText` | `string` | `'Confirm'` | Confirm button label. |
546
+ | `onCancel` | `() => void` | — | Cancel callback. |
547
+ | `onConfirm` | `() => void` | — | Confirm callback. |
548
+ | `loading` | `boolean` | `false` | Confirm button shows a spinner. |
549
+ | `danger` | `boolean` | `false` | Confirm button uses the danger style. |
550
+ | `closeable` | `boolean` | `true` | Show the close (✕) trigger. |
551
+ | `lazyMount` | `boolean` | `true` | Mount content lazily. |
552
+ | `unmountOnExit` | `boolean` | `true` | Unmount content when closed. |
553
+ | `closeOnInteractOutside` | `boolean` | `false` | Close when clicking outside. |
554
+ | `footer` | `node` | — | Custom footer replacing the default buttons. |
555
+ | `class` | `string` | — | Content class. |
556
+ | `children` | `node` | — | Custom body content. |
557
+
558
+ ### ConfirmDialog
559
+
560
+ Imperative + declarative confirm dialog built on `Dialog`.
561
+
562
+ **Exports:** `ConfirmDialog`, `confirm`
563
+
564
+ | Prop | Type | Default | Description |
565
+ |---|---|---|---|
566
+ | `mode` | `string` | — | `'alert'` / `'confirm'` / `'prompt'`-style mode. |
567
+ | `open` | `boolean \| (() => boolean)` | — | Controlled open state. |
568
+ | `onOpenChange` | `(v) => void` | — | Open/close callback. |
569
+ | `onConfirm` | `() => void` | — | Confirm callback. |
570
+ | `onCancel` | `() => void` | — | Cancel callback. |
571
+ | `loading` | `boolean` | `false` | Confirm button loading. |
572
+ | `title` | `string` | — | Title. |
573
+ | `message` | `string` | — | Body message. |
574
+ | `confirmText` | `string` | — | Confirm button label. |
575
+ | `cancelText` | `string` | — | Cancel button label. |
576
+ | `danger` | `boolean` | `false` | Danger-styled confirm button. |
577
+
578
+ Imperative API:
579
+
580
+ ```js
581
+ await confirm({ title, message, danger, confirmText })
582
+ // resolves true/false
583
+ ```
584
+
585
+ ### Drawer
586
+
587
+ Side drawer overlay.
588
+
589
+ **Exports:** `Drawer`, `DrawerTrigger`, `DrawerContent` · Escape hatch: `Drawer.origin.{Root, Trigger, Backdrop, Positioner, Content, Title, Description, CloseTrigger}`
590
+
591
+ | Prop | Type | Default | Description |
592
+ |---|---|---|---|
593
+ | `open` | `boolean \| (() => boolean)` | — | **Required** controlled open state. |
594
+ | `onOpenChange` | `(v) => void` | — | Open/close callback. |
595
+ | `onOpen` | `() => void` | — | Fired when opened. |
596
+ | `onClose` | `() => void` | — | Fired when closed. |
597
+ | `closeOnInteractOutside` | `boolean` | — | Close when clicking outside. |
598
+ | `lazyMount` | `boolean` | — | Mount lazily. |
599
+ | `zIndex` | `number` | — | Overlay z-index. |
600
+ | `title` | `string` | — | Drawer title. |
601
+ | `icon` | `node` | — | Optional icon. |
602
+ | `description` | `string` | — | Subtitle text. |
603
+ | `children` | `node` | — | Drawer body. |
604
+
605
+ ### Toast
606
+
607
+ **Exports:** `Toast`, `ToastTitle`, `ToastDescription`, `ToastCloseTrigger`, `ToastIcon`, `ToastToaster`, `createToaster` · Escape hatch: `Toast.origin.{Root, Title, Description, CloseTrigger, Toaster}`
608
+
609
+ Imperative API:
610
+
611
+ ```js
612
+ const toaster = createToaster()
613
+ <ToastToaster toaster={toaster} />
614
+ toaster.create({ title, description, type: 'success' })
615
+ ```
616
+
617
+ | Prop | Type | Default | Description |
618
+ |---|---|---|---|
619
+ | `toaster` | `object` | — | Toaster instance (on `ToastToaster`). |
620
+ | `className` | `string` | — | Root class. |
621
+
622
+ ### Popover
623
+
624
+ **Exports:** `Popover` · Escape hatch: `Popover.origin.{Root, Trigger, Positioner, Content, Arrow, ArrowTip, CloseTrigger, Title, Description}`
625
+
626
+ | Prop | Type | Default | Description |
627
+ |---|---|---|---|
628
+ | `lazyMount` | `boolean` | `true` | Mount content lazily. |
629
+ | `unmountOnExit` | `boolean` | `true` | Unmount when closed. |
630
+ | `closeable` | `boolean` | `false` | Show the close (✕) trigger. |
631
+
632
+ Passthrough: Ark `Root` props (`open`, `onOpenChange`, `positioning`, …).
633
+
634
+ ### BottomSheet
635
+
636
+ Mobile bottom sheet (drag-to-dismiss).
637
+
638
+ **Exports:** `BottomSheet` · no `.origin`
639
+
640
+ | Prop | Type | Default | Description |
641
+ |---|---|---|---|
642
+ | `dismissible` | `boolean` | `true` | Allow dismiss. |
643
+ | `backdropBlur` | `boolean` | `true` | Blur the backdrop. |
644
+
645
+ Passthrough: DOM props (`open`, `onOpenChange`, `title`, `children`, …).
646
+
647
+ ---
648
+
649
+ ## Utilities
650
+
651
+ ### Portal
652
+
653
+ **Exports:** `Portal` · no `.origin`
654
+
655
+ Renders children into `document.body` (or a `container` prop if provided).
656
+
657
+ ### Presence
658
+
659
+ **Exports:** `Presence` · no `.origin`
660
+
661
+ Applies presence/mount transitions; used internally by overlay components. Pass-through component.
662
+
663
+ ### FocusTrap
664
+
665
+ **Exports:** `FocusTrap` · no `.origin`
666
+
667
+ Traps focus within its children; accepts `disabled`, `initialFocus`, `returnFocus` DOM props.
668
+
669
+ ---
670
+