rsuite 6.0.0-canary-20250624 → 6.0.0-canary-20250702

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 (247) hide show
  1. package/AutoComplete/styles/index.css +156 -161
  2. package/AvatarGroup/styles/index.css +1 -10
  3. package/Badge/styles/index.css +21 -21
  4. package/Button/styles/index.css +78 -63
  5. package/ButtonGroup/styles/index.css +15 -12
  6. package/ButtonToolbar/styles/index.css +1 -10
  7. package/CHANGELOG.md +9 -0
  8. package/Calendar/styles/index.css +92 -67
  9. package/Card/styles/index.css +7 -7
  10. package/CascadeTree/styles/index.css +8 -9
  11. package/Cascader/styles/index.css +160 -164
  12. package/CheckPicker/styles/index.css +173 -178
  13. package/CheckTree/styles/index.css +175 -180
  14. package/CheckTreePicker/styles/index.css +175 -180
  15. package/Checkbox/styles/index.css +21 -28
  16. package/CheckboxGroup/styles/index.css +1 -1
  17. package/DateInput/styles/index.css +8 -18
  18. package/DatePicker/styles/index.css +173 -168
  19. package/DateRangeInput/styles/index.css +8 -18
  20. package/DateRangePicker/styles/index.css +173 -168
  21. package/Dropdown/styles/index.css +110 -94
  22. package/IconButton/styles/index.css +95 -79
  23. package/InlineEdit/styles/index.css +12 -19
  24. package/Input/styles/index.css +8 -18
  25. package/InputGroup/styles/index.css +31 -38
  26. package/InputNumber/styles/index.css +115 -100
  27. package/InputPicker/styles/index.css +156 -161
  28. package/List/styles/index.css +10 -10
  29. package/Loader/styles/index.css +16 -16
  30. package/Menu/styles/index.css +2 -2
  31. package/Message/styles/index.css +2 -2
  32. package/MultiCascadeTree/styles/index.css +178 -191
  33. package/MultiCascader/styles/index.css +178 -200
  34. package/Nav/styles/index.css +162 -146
  35. package/Navbar/styles/index.css +140 -124
  36. package/NumberInput/styles/index.css +115 -100
  37. package/Pagination/styles/index.css +177 -200
  38. package/PasswordInput/styles/index.css +36 -43
  39. package/PinInput/styles/index.css +12 -22
  40. package/Radio/styles/index.css +22 -29
  41. package/RadioGroup/styles/index.css +11 -11
  42. package/SelectPicker/styles/index.css +156 -161
  43. package/Sidenav/styles/index.css +122 -129
  44. package/Stack/styles/index.css +1 -10
  45. package/Stat/styles/index.css +95 -79
  46. package/Steps/styles/index.css +26 -25
  47. package/Table/styles/index.css +11 -0
  48. package/Tabs/styles/index.css +162 -146
  49. package/Tag/styles/index.css +112 -96
  50. package/TagInput/styles/index.css +174 -179
  51. package/TagPicker/styles/index.css +174 -179
  52. package/TimePicker/styles/index.css +173 -168
  53. package/TimeRangePicker/styles/index.css +173 -168
  54. package/Toggle/styles/index.css +27 -30
  55. package/Tree/styles/index.css +157 -162
  56. package/TreePicker/styles/index.css +157 -162
  57. package/Uploader/styles/index.css +94 -65
  58. package/cjs/Badge/Badge.js +16 -11
  59. package/cjs/Breadcrumb/Breadcrumb.d.ts +2 -2
  60. package/cjs/Button/Button.js +9 -7
  61. package/cjs/ButtonGroup/ButtonGroup.js +7 -7
  62. package/cjs/Card/Card.js +6 -6
  63. package/cjs/Checkbox/Checkbox.js +6 -7
  64. package/cjs/CheckboxGroup/CheckboxGroup.js +3 -4
  65. package/cjs/Dropdown/Dropdown.js +3 -4
  66. package/cjs/Dropdown/DropdownItem.js +4 -4
  67. package/cjs/Dropdown/DropdownMenu.js +9 -10
  68. package/cjs/FormControl/FormControl.d.ts +1 -1
  69. package/cjs/FormControlLabel/FormControlLabel.d.ts +1 -1
  70. package/cjs/FormHelpText/FormHelpText.d.ts +1 -1
  71. package/cjs/IconButton/IconButton.d.ts +1 -1
  72. package/cjs/IconButton/IconButton.js +9 -9
  73. package/cjs/Image/Image.d.ts +1 -1
  74. package/cjs/InlineEdit/InlineEdit.js +3 -2
  75. package/cjs/InputGroup/InputGroup.js +12 -14
  76. package/cjs/InputGroup/InputGroupAddon.d.ts +2 -2
  77. package/cjs/InputPicker/InputAutosize.js +4 -6
  78. package/cjs/List/List.d.ts +1 -1
  79. package/cjs/List/List.js +7 -8
  80. package/cjs/List/ListItem.d.ts +2 -2
  81. package/cjs/List/ListItem.js +4 -4
  82. package/cjs/Loader/Loader.js +8 -7
  83. package/cjs/Menu/MenuSeparator.d.ts +2 -2
  84. package/cjs/Nav/Nav.d.ts +2 -2
  85. package/cjs/Nav/Nav.js +12 -13
  86. package/cjs/Nav/NavDropdownItem.js +4 -4
  87. package/cjs/Nav/NavDropdownMenu.js +10 -13
  88. package/cjs/Nav/NavItem.d.ts +2 -2
  89. package/cjs/Nav/NavItem.js +6 -8
  90. package/cjs/Navbar/Navbar.js +6 -6
  91. package/cjs/Navbar/NavbarDropdown.d.ts +1 -1
  92. package/cjs/Navbar/NavbarDropdown.js +3 -4
  93. package/cjs/Navbar/NavbarDropdownItem.js +4 -4
  94. package/cjs/Navbar/NavbarDropdownMenu.js +8 -11
  95. package/cjs/NumberInput/NumberInput.d.ts +1 -1
  96. package/cjs/Pagination/Pagination.js +3 -2
  97. package/cjs/Pagination/PaginationButton.d.ts +3 -3
  98. package/cjs/Pagination/PaginationButton.js +9 -17
  99. package/cjs/Pagination/PaginationGroup.js +2 -1
  100. package/cjs/Panel/PanelHeader.d.ts +1 -1
  101. package/cjs/Radio/Radio.js +6 -6
  102. package/cjs/RadioGroup/RadioGroup.js +4 -4
  103. package/cjs/Sidenav/ExpandedSidenavDropdown.d.ts +1 -1
  104. package/cjs/Sidenav/Sidenav.js +3 -2
  105. package/cjs/Sidenav/SidenavDropdown.js +3 -5
  106. package/cjs/Sidenav/SidenavDropdownItem.js +4 -4
  107. package/cjs/Sidenav/SidenavDropdownMenu.js +10 -13
  108. package/cjs/Sidenav/SidenavItem.d.ts +2 -2
  109. package/cjs/Sidenav/SidenavItem.js +4 -5
  110. package/cjs/Slider/Handle.d.ts +1 -1
  111. package/cjs/Stack/Stack.d.ts +1 -17
  112. package/cjs/Stack/Stack.js +3 -4
  113. package/cjs/Stack/StackItem.d.ts +4 -5
  114. package/cjs/Stack/StackItem.js +4 -10
  115. package/cjs/Steps/StepItem.js +7 -8
  116. package/cjs/Steps/Steps.d.ts +2 -1
  117. package/cjs/Steps/Steps.js +32 -34
  118. package/cjs/Tabs/Tabs.js +1 -1
  119. package/cjs/Tag/Tag.js +5 -2
  120. package/cjs/Toggle/Toggle.d.ts +1 -1
  121. package/cjs/Toggle/Toggle.js +7 -6
  122. package/cjs/Tree/types.d.ts +2 -2
  123. package/cjs/Uploader/Uploader.d.ts +2 -2
  124. package/cjs/internals/Box/Box.d.ts +1 -0
  125. package/cjs/internals/Box/index.d.ts +1 -1
  126. package/cjs/internals/Box/utils.js +5 -4
  127. package/cjs/internals/InputBase/InputBase.d.ts +1 -1
  128. package/cjs/internals/InputBase/InputBase.js +3 -2
  129. package/cjs/internals/Menu/MenuItem.js +1 -1
  130. package/cjs/internals/Overlay/Modal.d.ts +1 -1
  131. package/cjs/internals/Picker/PickerToggle.js +2 -4
  132. package/cjs/internals/SafeAnchor/SafeAnchor.d.ts +2 -2
  133. package/cjs/internals/Tree/TreeView.d.ts +2 -2
  134. package/cjs/internals/hooks/useCustom.js +24 -7
  135. package/cjs/internals/styled-system/css-alias.d.ts +7 -0
  136. package/cjs/internals/styled-system/css-alias.js +391 -0
  137. package/cjs/internals/styled-system/css-properties.d.ts +6 -0
  138. package/cjs/internals/styled-system/css-properties.js +30 -0
  139. package/cjs/internals/styled-system/index.d.ts +1 -1
  140. package/cjs/internals/styled-system/index.js +4 -4
  141. package/cjs/internals/styled-system/responsive.d.ts +0 -4
  142. package/cjs/internals/styled-system/responsive.js +12 -33
  143. package/cjs/internals/styled-system/types.d.ts +59 -5
  144. package/cjs/internals/styled-system/useStyled.js +3 -3
  145. package/cjs/internals/types/html.d.ts +6 -6
  146. package/cjs/internals/types/picker.d.ts +1 -1
  147. package/dist/rsuite-no-reset.css +641 -641
  148. package/dist/rsuite-no-reset.min.css +1 -1
  149. package/dist/rsuite.css +641 -641
  150. package/dist/rsuite.js +60 -60
  151. package/dist/rsuite.min.css +1 -1
  152. package/dist/rsuite.min.js +1 -1
  153. package/dist/rsuite.min.js.map +1 -1
  154. package/esm/Badge/Badge.js +16 -11
  155. package/esm/Breadcrumb/Breadcrumb.d.ts +2 -2
  156. package/esm/Button/Button.js +9 -7
  157. package/esm/ButtonGroup/ButtonGroup.js +7 -7
  158. package/esm/Card/Card.js +6 -6
  159. package/esm/Checkbox/Checkbox.js +6 -7
  160. package/esm/CheckboxGroup/CheckboxGroup.js +3 -4
  161. package/esm/Dropdown/Dropdown.js +3 -4
  162. package/esm/Dropdown/DropdownItem.js +4 -4
  163. package/esm/Dropdown/DropdownMenu.js +9 -10
  164. package/esm/FormControl/FormControl.d.ts +1 -1
  165. package/esm/FormControlLabel/FormControlLabel.d.ts +1 -1
  166. package/esm/FormHelpText/FormHelpText.d.ts +1 -1
  167. package/esm/IconButton/IconButton.d.ts +1 -1
  168. package/esm/IconButton/IconButton.js +9 -9
  169. package/esm/Image/Image.d.ts +1 -1
  170. package/esm/InlineEdit/InlineEdit.js +3 -2
  171. package/esm/InputGroup/InputGroup.js +12 -14
  172. package/esm/InputGroup/InputGroupAddon.d.ts +2 -2
  173. package/esm/InputPicker/InputAutosize.js +4 -6
  174. package/esm/List/List.d.ts +1 -1
  175. package/esm/List/List.js +7 -8
  176. package/esm/List/ListItem.d.ts +2 -2
  177. package/esm/List/ListItem.js +4 -4
  178. package/esm/Loader/Loader.js +8 -7
  179. package/esm/Menu/MenuSeparator.d.ts +2 -2
  180. package/esm/Nav/Nav.d.ts +2 -2
  181. package/esm/Nav/Nav.js +12 -13
  182. package/esm/Nav/NavDropdownItem.js +4 -4
  183. package/esm/Nav/NavDropdownMenu.js +10 -13
  184. package/esm/Nav/NavItem.d.ts +2 -2
  185. package/esm/Nav/NavItem.js +6 -8
  186. package/esm/Navbar/Navbar.js +7 -7
  187. package/esm/Navbar/NavbarDropdown.d.ts +1 -1
  188. package/esm/Navbar/NavbarDropdown.js +3 -4
  189. package/esm/Navbar/NavbarDropdownItem.js +4 -4
  190. package/esm/Navbar/NavbarDropdownMenu.js +8 -11
  191. package/esm/NumberInput/NumberInput.d.ts +1 -1
  192. package/esm/Pagination/Pagination.js +3 -2
  193. package/esm/Pagination/PaginationButton.d.ts +3 -3
  194. package/esm/Pagination/PaginationButton.js +9 -16
  195. package/esm/Pagination/PaginationGroup.js +2 -1
  196. package/esm/Panel/PanelHeader.d.ts +1 -1
  197. package/esm/Radio/Radio.js +6 -6
  198. package/esm/RadioGroup/RadioGroup.js +4 -4
  199. package/esm/Sidenav/ExpandedSidenavDropdown.d.ts +1 -1
  200. package/esm/Sidenav/Sidenav.js +3 -2
  201. package/esm/Sidenav/SidenavDropdown.js +3 -5
  202. package/esm/Sidenav/SidenavDropdownItem.js +4 -4
  203. package/esm/Sidenav/SidenavDropdownMenu.js +10 -13
  204. package/esm/Sidenav/SidenavItem.d.ts +2 -2
  205. package/esm/Sidenav/SidenavItem.js +4 -5
  206. package/esm/Slider/Handle.d.ts +1 -1
  207. package/esm/Stack/Stack.d.ts +1 -17
  208. package/esm/Stack/Stack.js +3 -4
  209. package/esm/Stack/StackItem.d.ts +4 -5
  210. package/esm/Stack/StackItem.js +5 -11
  211. package/esm/Steps/StepItem.js +7 -8
  212. package/esm/Steps/Steps.d.ts +2 -1
  213. package/esm/Steps/Steps.js +31 -34
  214. package/esm/Tabs/Tabs.js +1 -1
  215. package/esm/Tag/Tag.js +5 -2
  216. package/esm/Toggle/Toggle.d.ts +1 -1
  217. package/esm/Toggle/Toggle.js +7 -6
  218. package/esm/Tree/types.d.ts +2 -2
  219. package/esm/Uploader/Uploader.d.ts +2 -2
  220. package/esm/internals/Box/Box.d.ts +1 -0
  221. package/esm/internals/Box/index.d.ts +1 -1
  222. package/esm/internals/Box/utils.js +6 -5
  223. package/esm/internals/InputBase/InputBase.d.ts +1 -1
  224. package/esm/internals/InputBase/InputBase.js +3 -2
  225. package/esm/internals/Menu/MenuItem.js +1 -1
  226. package/esm/internals/Overlay/Modal.d.ts +1 -1
  227. package/esm/internals/Picker/PickerToggle.js +2 -4
  228. package/esm/internals/SafeAnchor/SafeAnchor.d.ts +2 -2
  229. package/esm/internals/Tree/TreeView.d.ts +2 -2
  230. package/esm/internals/hooks/useCustom.js +24 -7
  231. package/esm/internals/styled-system/css-alias.d.ts +7 -0
  232. package/esm/internals/styled-system/css-alias.js +387 -0
  233. package/esm/internals/styled-system/css-properties.d.ts +6 -0
  234. package/esm/internals/styled-system/css-properties.js +26 -0
  235. package/esm/internals/styled-system/index.d.ts +1 -1
  236. package/esm/internals/styled-system/index.js +1 -1
  237. package/esm/internals/styled-system/responsive.d.ts +0 -4
  238. package/esm/internals/styled-system/responsive.js +11 -31
  239. package/esm/internals/styled-system/types.d.ts +59 -5
  240. package/esm/internals/styled-system/useStyled.js +3 -3
  241. package/esm/internals/types/html.d.ts +6 -6
  242. package/esm/internals/types/picker.d.ts +1 -1
  243. package/package.json +1 -1
  244. package/cjs/internals/styled-system/css-property.d.ts +0 -6
  245. package/cjs/internals/styled-system/css-property.js +0 -289
  246. package/esm/internals/styled-system/css-property.d.ts +0 -6
  247. package/esm/internals/styled-system/css-property.js +0 -285
@@ -0,0 +1,391 @@
1
+ 'use client';
2
+ "use strict";
3
+
4
+ exports.__esModule = true;
5
+ exports.cssSystemPropAlias = void 0;
6
+ var _utils = require("../utils");
7
+ const transformRadiusValue = value => (0, _utils.getSizeValue)('radius', value);
8
+ const transformShadowValue = value => (0, _utils.getSizeValue)('shadow', value);
9
+
10
+ /**
11
+ * CSS Property Alias
12
+ * This type maps all the CSS properties defined in cssSystemPropAlias to their corresponding React CSS types
13
+ */
14
+ const cssSystemPropAlias = exports.cssSystemPropAlias = {
15
+ // — Spacing ————————————————————
16
+ p: {
17
+ type: 'any',
18
+ property: 'padding'
19
+ },
20
+ pt: {
21
+ type: 'any',
22
+ property: 'padding-top'
23
+ },
24
+ pr: {
25
+ type: 'any',
26
+ property: 'padding-right'
27
+ },
28
+ pb: {
29
+ type: 'any',
30
+ property: 'padding-bottom'
31
+ },
32
+ pl: {
33
+ type: 'any',
34
+ property: 'padding-left'
35
+ },
36
+ px: {
37
+ type: 'any',
38
+ property: 'padding-inline'
39
+ },
40
+ py: {
41
+ type: 'any',
42
+ property: 'padding-block'
43
+ },
44
+ ps: {
45
+ type: 'any',
46
+ property: 'padding-inline-start'
47
+ },
48
+ pe: {
49
+ type: 'any',
50
+ property: 'padding-inline-end'
51
+ },
52
+ m: {
53
+ type: 'any',
54
+ property: 'margin'
55
+ },
56
+ mt: {
57
+ type: 'any',
58
+ property: 'margin-top'
59
+ },
60
+ mr: {
61
+ type: 'any',
62
+ property: 'margin-right'
63
+ },
64
+ mb: {
65
+ type: 'any',
66
+ property: 'margin-bottom'
67
+ },
68
+ ml: {
69
+ type: 'any',
70
+ property: 'margin-left'
71
+ },
72
+ mx: {
73
+ type: 'any',
74
+ property: 'margin-inline'
75
+ },
76
+ my: {
77
+ type: 'any',
78
+ property: 'margin-block'
79
+ },
80
+ ms: {
81
+ type: 'any',
82
+ property: 'margin-inline-start'
83
+ },
84
+ me: {
85
+ type: 'any',
86
+ property: 'margin-inline-end'
87
+ },
88
+ // — Sizing ————————————————————
89
+ w: {
90
+ type: 'any',
91
+ property: 'width'
92
+ },
93
+ h: {
94
+ type: 'any',
95
+ property: 'height'
96
+ },
97
+ minw: {
98
+ type: 'any',
99
+ property: 'min-width'
100
+ },
101
+ maxw: {
102
+ type: 'any',
103
+ property: 'max-width'
104
+ },
105
+ minh: {
106
+ type: 'any',
107
+ property: 'min-height'
108
+ },
109
+ maxh: {
110
+ type: 'any',
111
+ property: 'max-height'
112
+ },
113
+ // — Layout & Position ————————————————————
114
+ display: {
115
+ type: 'any',
116
+ property: 'display'
117
+ },
118
+ pos: {
119
+ type: 'any',
120
+ property: 'position'
121
+ },
122
+ left: {
123
+ type: 'any',
124
+ property: 'left'
125
+ },
126
+ top: {
127
+ type: 'any',
128
+ property: 'top'
129
+ },
130
+ right: {
131
+ type: 'any',
132
+ property: 'right'
133
+ },
134
+ bottom: {
135
+ type: 'any',
136
+ property: 'bottom'
137
+ },
138
+ inset: {
139
+ type: 'any',
140
+ property: 'inset'
141
+ },
142
+ insetx: {
143
+ type: 'any',
144
+ property: 'inset-inline'
145
+ },
146
+ insety: {
147
+ type: 'any',
148
+ property: 'inset-block'
149
+ },
150
+ bsz: {
151
+ type: 'string',
152
+ property: 'box-sizing'
153
+ },
154
+ z: {
155
+ type: 'number',
156
+ property: 'z-index'
157
+ },
158
+ // — Background ————————————————————
159
+ bg: {
160
+ type: 'string',
161
+ property: 'background',
162
+ transformer: _utils.getColorValue
163
+ },
164
+ bgc: {
165
+ type: 'string',
166
+ property: 'background-color',
167
+ transformer: _utils.getColorValue
168
+ },
169
+ bgi: {
170
+ type: 'string',
171
+ property: 'background-image'
172
+ },
173
+ bga: {
174
+ type: 'string',
175
+ property: 'background-attachment'
176
+ },
177
+ bgp: {
178
+ type: 'string',
179
+ property: 'background-position'
180
+ },
181
+ bgsz: {
182
+ type: 'string',
183
+ property: 'background-size'
184
+ },
185
+ bgr: {
186
+ type: 'string',
187
+ property: 'background-repeat'
188
+ },
189
+ // — Typography ————————————————————
190
+ c: {
191
+ type: 'string',
192
+ property: 'color',
193
+ transformer: _utils.getColorValue
194
+ },
195
+ ff: {
196
+ type: 'string',
197
+ property: 'font-family'
198
+ },
199
+ fs: {
200
+ type: 'string',
201
+ property: 'font-size'
202
+ },
203
+ fw: {
204
+ type: 'string',
205
+ property: 'font-weight'
206
+ },
207
+ ta: {
208
+ type: 'string',
209
+ property: 'text-align'
210
+ },
211
+ tt: {
212
+ type: 'string',
213
+ property: 'text-transform'
214
+ },
215
+ td: {
216
+ type: 'string',
217
+ property: 'text-decoration'
218
+ },
219
+ tds: {
220
+ type: 'string',
221
+ property: 'text-decoration-style'
222
+ },
223
+ tdc: {
224
+ type: 'string',
225
+ property: 'text-decoration-color',
226
+ transformer: _utils.getColorValue
227
+ },
228
+ lts: {
229
+ type: 'string',
230
+ property: 'letter-spacing'
231
+ },
232
+ lh: {
233
+ type: 'any',
234
+ property: 'line-height'
235
+ },
236
+ // — Border ————————————————————
237
+ bd: {
238
+ type: 'string',
239
+ property: 'border'
240
+ },
241
+ bs: {
242
+ type: 'string',
243
+ property: 'border-style'
244
+ },
245
+ bc: {
246
+ type: 'string',
247
+ property: 'border-color',
248
+ transformer: _utils.getColorValue
249
+ },
250
+ bw: {
251
+ type: 'any',
252
+ property: 'border-width'
253
+ },
254
+ bdt: {
255
+ type: 'string',
256
+ property: 'border-top'
257
+ },
258
+ bdb: {
259
+ type: 'string',
260
+ property: 'border-bottom'
261
+ },
262
+ bdl: {
263
+ type: 'string',
264
+ property: 'border-left'
265
+ },
266
+ bdr: {
267
+ type: 'string',
268
+ property: 'border-right'
269
+ },
270
+ bdts: {
271
+ type: 'string',
272
+ property: 'border-top-style'
273
+ },
274
+ bdbs: {
275
+ type: 'string',
276
+ property: 'border-bottom-style'
277
+ },
278
+ bdls: {
279
+ type: 'string',
280
+ property: 'border-left-style'
281
+ },
282
+ bdrs: {
283
+ type: 'string',
284
+ property: 'border-right-style'
285
+ },
286
+ bdtc: {
287
+ type: 'string',
288
+ property: 'border-top-color',
289
+ transformer: _utils.getColorValue
290
+ },
291
+ bdbc: {
292
+ type: 'string',
293
+ property: 'border-bottom-color',
294
+ transformer: _utils.getColorValue
295
+ },
296
+ bdlc: {
297
+ type: 'string',
298
+ property: 'border-left-color',
299
+ transformer: _utils.getColorValue
300
+ },
301
+ bdrc: {
302
+ type: 'string',
303
+ property: 'border-right-color',
304
+ transformer: _utils.getColorValue
305
+ },
306
+ bdtw: {
307
+ type: 'any',
308
+ property: 'border-top-width'
309
+ },
310
+ bdbw: {
311
+ type: 'any',
312
+ property: 'border-bottom-width'
313
+ },
314
+ bdlw: {
315
+ type: 'any',
316
+ property: 'border-left-width'
317
+ },
318
+ bdrw: {
319
+ type: 'any',
320
+ property: 'border-right-width'
321
+ },
322
+ rounded: {
323
+ type: 'any',
324
+ property: 'border-radius',
325
+ transformer: transformRadiusValue
326
+ },
327
+ // — Shadow & Effects ————————————————————
328
+ shadow: {
329
+ type: 'any',
330
+ property: 'box-shadow',
331
+ transformer: transformShadowValue
332
+ },
333
+ opacity: {
334
+ type: 'any',
335
+ property: 'opacity'
336
+ },
337
+ // — Flex ————————————————————
338
+ gap: {
339
+ type: 'any',
340
+ property: 'gap'
341
+ },
342
+ spacing: {
343
+ type: 'any',
344
+ property: 'gap'
345
+ },
346
+ // alias for gap
347
+ rowgap: {
348
+ type: 'any',
349
+ property: 'row-gap'
350
+ },
351
+ colgap: {
352
+ type: 'any',
353
+ property: 'column-gap'
354
+ },
355
+ align: {
356
+ type: 'string',
357
+ property: 'align-items'
358
+ },
359
+ justify: {
360
+ type: 'string',
361
+ property: 'justify-content'
362
+ },
363
+ self: {
364
+ type: 'string',
365
+ property: 'align-self'
366
+ },
367
+ basis: {
368
+ type: 'any',
369
+ property: 'flex-basis'
370
+ },
371
+ flex: {
372
+ type: 'string',
373
+ property: 'flex'
374
+ },
375
+ grow: {
376
+ type: 'number',
377
+ property: 'flex-grow'
378
+ },
379
+ order: {
380
+ type: 'number',
381
+ property: 'order'
382
+ },
383
+ shrink: {
384
+ type: 'number',
385
+ property: 'flex-shrink'
386
+ },
387
+ direction: {
388
+ type: 'string',
389
+ property: 'flex-direction'
390
+ }
391
+ };
@@ -0,0 +1,6 @@
1
+ /**
2
+ * List of commonly used CSS properties in React components
3
+ * Focused on layout, spacing, typography, and common UI patterns
4
+ */
5
+ export declare const supportedCSSProperties: readonly ["display", "position", "top", "right", "bottom", "left", "zIndex", "boxSizing", "width", "height", "minWidth", "maxWidth", "minHeight", "maxHeight", "overflow", "overflowX", "overflowY", "aspectRatio", "padding", "paddingTop", "paddingRight", "paddingBottom", "paddingLeft", "margin", "marginTop", "marginRight", "marginBottom", "marginLeft", "flex", "flexGrow", "flexShrink", "flexBasis", "flexDirection", "flexWrap", "justifyContent", "alignItems", "alignSelf", "alignContent", "gap", "rowGap", "columnGap", "order", "grid", "gridTemplate", "gridTemplateAreas", "gridTemplateColumns", "gridTemplateRows", "gridArea", "gridColumn", "gridRow", "gridAutoFlow", "gridAutoColumns", "gridAutoRows", "color", "fontFamily", "fontSize", "fontWeight", "fontStyle", "lineHeight", "textAlign", "textDecoration", "textTransform", "whiteSpace", "wordBreak", "wordWrap", "textOverflow", "letterSpacing", "background", "backgroundColor", "backgroundImage", "backgroundPosition", "backgroundSize", "backgroundRepeat", "border", "borderColor", "borderStyle", "borderWidth", "borderRadius", "borderTop", "borderRight", "borderBottom", "borderLeft", "boxShadow", "opacity", "transform", "transformOrigin", "transition", "transitionProperty", "transitionDuration", "transitionTimingFunction", "transitionDelay", "cursor", "pointerEvents", "userSelect", "visibility", "scrollBehavior", "scrollbarWidth", "scrollbarColor", "overscrollBehavior", "clipPath", "filter", "objectFit", "objectPosition", "resize"];
6
+ export type SupportedCSSProperty = (typeof supportedCSSProperties)[number];
@@ -0,0 +1,30 @@
1
+ 'use client';
2
+ "use strict";
3
+
4
+ exports.__esModule = true;
5
+ exports.supportedCSSProperties = void 0;
6
+ /**
7
+ * List of commonly used CSS properties in React components
8
+ * Focused on layout, spacing, typography, and common UI patterns
9
+ */
10
+ const supportedCSSProperties = exports.supportedCSSProperties = [
11
+ // Layout & Box Model
12
+ 'display', 'position', 'top', 'right', 'bottom', 'left', 'zIndex', 'boxSizing', 'width', 'height', 'minWidth', 'maxWidth', 'minHeight', 'maxHeight', 'overflow', 'overflowX', 'overflowY', 'aspectRatio',
13
+ // Spacing
14
+ 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft',
15
+ // Flexbox
16
+ 'flex', 'flexGrow', 'flexShrink', 'flexBasis', 'flexDirection', 'flexWrap', 'justifyContent', 'alignItems', 'alignSelf', 'alignContent', 'gap', 'rowGap', 'columnGap', 'order',
17
+ // Grid
18
+ 'grid', 'gridTemplate', 'gridTemplateAreas', 'gridTemplateColumns', 'gridTemplateRows', 'gridArea', 'gridColumn', 'gridRow', 'gridAutoFlow', 'gridAutoColumns', 'gridAutoRows',
19
+ // Typography
20
+ 'color', 'fontFamily', 'fontSize', 'fontWeight', 'fontStyle', 'lineHeight', 'textAlign', 'textDecoration', 'textTransform', 'whiteSpace', 'wordBreak', 'wordWrap', 'textOverflow', 'letterSpacing',
21
+ // Background & Borders
22
+ 'background', 'backgroundColor', 'backgroundImage', 'backgroundPosition', 'backgroundSize', 'backgroundRepeat', 'border', 'borderColor', 'borderStyle', 'borderWidth', 'borderRadius', 'borderTop', 'borderRight', 'borderBottom', 'borderLeft', 'boxShadow', 'opacity',
23
+ // Transforms & Transitions
24
+ 'transform', 'transformOrigin', 'transition', 'transitionProperty', 'transitionDuration', 'transitionTimingFunction', 'transitionDelay',
25
+ // Interactivity
26
+ 'cursor', 'pointerEvents', 'userSelect', 'visibility',
27
+ // Scroll
28
+ 'scrollBehavior', 'scrollbarWidth', 'scrollbarColor', 'overscrollBehavior',
29
+ // Other
30
+ 'clipPath', 'filter', 'objectFit', 'objectPosition', 'resize'];
@@ -1,5 +1,5 @@
1
1
  export * from './responsive';
2
2
  export * from './useStyled';
3
3
  export * from './style-manager';
4
- export * from './css-property';
4
+ export * from './css-alias';
5
5
  export * from './types';
@@ -20,11 +20,11 @@ Object.keys(_styleManager).forEach(function (key) {
20
20
  if (key in exports && exports[key] === _styleManager[key]) return;
21
21
  exports[key] = _styleManager[key];
22
22
  });
23
- var _cssProperty = require("./css-property");
24
- Object.keys(_cssProperty).forEach(function (key) {
23
+ var _cssAlias = require("./css-alias");
24
+ Object.keys(_cssAlias).forEach(function (key) {
25
25
  if (key === "default" || key === "__esModule") return;
26
- if (key in exports && exports[key] === _cssProperty[key]) return;
27
- exports[key] = _cssProperty[key];
26
+ if (key in exports && exports[key] === _cssAlias[key]) return;
27
+ exports[key] = _cssAlias[key];
28
28
  });
29
29
  var _types = require("./types");
30
30
  Object.keys(_types).forEach(function (key) {
@@ -19,10 +19,6 @@ export declare function isResponsiveValue(value: any): value is ResponsiveValue<
19
19
  */
20
20
  export declare function processResponsiveValue<T, R extends string | number | undefined>(value: T | ResponsiveValue<T> | undefined, processor: (val: T) => R): R | ResponsiveValue<R> | undefined;
21
21
  type CSSVarValue = WithResponsive<string | number | undefined>;
22
- /**
23
- * Converts layout properties to CSS variables with abbreviated names
24
- */
25
- export declare const getCSSVariables2: (props: Record<string, any>, prefix?: string) => Record<string, CSSVarValue>;
26
22
  /**
27
23
  * Converts layout properties to CSS variables with abbreviated names
28
24
  */
@@ -3,14 +3,14 @@
3
3
 
4
4
  var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
5
5
  exports.__esModule = true;
6
- exports.getCSSVariables2 = exports.getCSSVariables = exports.breakpointValues = void 0;
6
+ exports.getCSSVariables = exports.breakpointValues = void 0;
7
7
  exports.isResponsiveValue = isResponsiveValue;
8
8
  exports.processResponsiveValue = processResponsiveValue;
9
9
  var _camelCase = _interopRequireDefault(require("lodash/camelCase"));
10
10
  var _kebabCase = _interopRequireDefault(require("lodash/kebabCase"));
11
11
  var _utils = require("../utils");
12
12
  var _constants = require("../constants");
13
- var _cssProperty = require("./css-property");
13
+ var _cssAlias = require("./css-alias");
14
14
  /**
15
15
  * Breakpoint values in pixels - matching SCSS variables
16
16
  * These values are used for responsive design across the application.
@@ -68,46 +68,24 @@ function processResponsiveValue(value, processor) {
68
68
 
69
69
  // Type for CSS variable values that can be string, number, or responsive values
70
70
 
71
- /**
72
- * Converts layout properties to CSS variables with abbreviated names
73
- */
74
- const getCSSVariables2 = (props, prefix = `--rs-`) => {
75
- const cssVars = {};
76
- const cssVar = name => `${prefix}${name}`;
77
-
78
- // Process padding, margin, size properties
79
- Object.entries(_cssProperty.cssPropertyMap).forEach(([name, prop]) => {
80
- const {
81
- transformer,
82
- property
83
- } = prop;
84
- const propName = (0, _camelCase.default)(property);
85
- if (typeof props[name] === 'undefined' && typeof props[propName] === 'undefined') {
86
- return;
87
- }
88
- const varName = cssVar(name || propName);
89
- const value = props[name] || props[propName];
90
- if (transformer) {
91
- cssVars[varName] = processResponsiveValue(value, val => transformer(val));
92
- } else {
93
- cssVars[varName] = processResponsiveValue(value, val => (0, _utils.getCssValue)(val));
94
- }
95
- });
96
- return cssVars;
71
+ const transformCSSValue = (value, type) => {
72
+ if (type === 'number') {
73
+ return value;
74
+ }
75
+ return (0, _utils.getCssValue)(value);
97
76
  };
98
77
 
99
78
  /**
100
79
  * Converts layout properties to CSS variables with abbreviated names
101
80
  */
102
- exports.getCSSVariables2 = getCSSVariables2;
103
81
  const getCSSVariables = (props, prefix = `--rs-`) => {
104
82
  const cssVars = {};
105
83
  const cssVar = name => `${prefix}${(0, _kebabCase.default)(name)}`;
106
84
  const getCSSProperty = name => {
107
85
  let cssName = name;
108
- let cssProp = _cssProperty.cssPropertyMap[name];
86
+ let cssProp = _cssAlias.cssSystemPropAlias[name];
109
87
  if (!cssProp) {
110
- Object.entries(_cssProperty.cssPropertyMap).forEach(([key, prop]) => {
88
+ Object.entries(_cssAlias.cssSystemPropAlias).forEach(([key, prop]) => {
111
89
  if ((0, _camelCase.default)(prop.property) === name) {
112
90
  cssProp = prop;
113
91
  cssName = key;
@@ -124,10 +102,11 @@ const getCSSVariables = (props, prefix = `--rs-`) => {
124
102
  const varName = cssVar(cssName);
125
103
  if (cssProp) {
126
104
  const {
127
- transformer
105
+ transformer,
106
+ type
128
107
  } = cssProp;
129
108
  cssVars[varName] = processResponsiveValue(value, val => {
130
- return transformer ? transformer(val) : (0, _utils.getCssValue)(val);
109
+ return transformer ? transformer(val) : transformCSSValue(val, type);
131
110
  });
132
111
  } else if ((0, _utils.isCSSProperty)(cssName)) {
133
112
  // For non-predefined CSS properties, directly process with getCssValue
@@ -1,11 +1,12 @@
1
1
  import { CSSProperties as CSS } from 'react';
2
+ import { supportedCSSProperties } from './css-properties';
2
3
  import type { WithResponsive, ColorScheme, Size } from '../types';
3
- type CSSPropertyGroup = 'spacing' | 'sizing' | 'layout' | 'color' | 'border' | 'effect' | 'flex' | 'radius' | 'typography' | 'position' | 'background';
4
+ export type CSSPropertyValueType = 'string' | 'number' | 'any';
4
5
  export type CSSProperty = {
5
6
  /**
6
7
  * CSS Property Type
7
8
  */
8
- type: CSSPropertyGroup;
9
+ type: CSSPropertyValueType;
9
10
  /**
10
11
  * CSS Property
11
12
  */
@@ -15,11 +16,16 @@ export type CSSProperty = {
15
16
  */
16
17
  transformer?: (value: any) => any;
17
18
  };
19
+ export type SupportedCSSProperty = (typeof supportedCSSProperties)[number];
20
+ type MakeResponsive<T> = {
21
+ [K in keyof T]?: T[K] | WithResponsive<T[K]>;
22
+ };
23
+ export type StandardCSSProps = MakeResponsive<Pick<CSS, SupportedCSSProperty>>;
18
24
  /**
19
25
  * CSS Properties type for Box component
20
- * This type maps all the CSS properties defined in cssPropertyMap to their corresponding React CSS types
26
+ * This type maps all the CSS properties defined in cssSystemPropAlias to their corresponding React CSS types
21
27
  */
22
- export interface CSSSystemProps {
28
+ export interface CSSSystemProps extends StandardCSSProps {
23
29
  /** Shorthand for CSS property `padding` */
24
30
  p?: WithResponsive<CSS['padding']>;
25
31
  /** Shorthand for CSS property `paddingTop` */
@@ -87,7 +93,9 @@ export interface CSSSystemProps {
87
93
  /** Shorthand for CSS property `insetBlock` */
88
94
  insety?: WithResponsive<CSS['insetBlock']>;
89
95
  /** Shorthand for CSS property `boxSizing` */
90
- boxsizing?: WithResponsive<CSS['boxSizing']>;
96
+ bsz?: WithResponsive<CSS['boxSizing']>;
97
+ /** Shorthand for CSS property `zIndex` */
98
+ z?: WithResponsive<CSS['zIndex']>;
91
99
  /** Shorthand for CSS property `background` */
92
100
  bg?: WithResponsive<ColorScheme | CSS['background']>;
93
101
  /** Shorthand for CSS property `backgroundColor` */
@@ -132,6 +140,38 @@ export interface CSSSystemProps {
132
140
  bc?: WithResponsive<ColorScheme | CSS['borderColor']>;
133
141
  /** Shorthand for CSS property `borderWidth` */
134
142
  bw?: WithResponsive<CSS['borderWidth']>;
143
+ /** Shorthand for CSS property `borderTop` */
144
+ bdt?: WithResponsive<CSS['borderTop']>;
145
+ /** Shorthand for CSS property `borderBottom` */
146
+ bdb?: WithResponsive<CSS['borderBottom']>;
147
+ /** Shorthand for CSS property `borderLeft` */
148
+ bdl?: WithResponsive<CSS['borderLeft']>;
149
+ /** Shorthand for CSS property `borderRight` */
150
+ bdr?: WithResponsive<CSS['borderRight']>;
151
+ /** Shorthand for CSS property `borderTopStyle` */
152
+ bdts?: WithResponsive<CSS['borderTopStyle']>;
153
+ /** Shorthand for CSS property `borderBottomStyle` */
154
+ bdbs?: WithResponsive<CSS['borderBottomStyle']>;
155
+ /** Shorthand for CSS property `borderLeftStyle` */
156
+ bdls?: WithResponsive<CSS['borderLeftStyle']>;
157
+ /** Shorthand for CSS property `borderRightStyle` */
158
+ bdrs?: WithResponsive<CSS['borderRightStyle']>;
159
+ /** Shorthand for CSS property `borderTopColor` */
160
+ bdtc?: WithResponsive<ColorScheme | CSS['borderTopColor']>;
161
+ /** Shorthand for CSS property `borderBottomColor` */
162
+ bdbc?: WithResponsive<ColorScheme | CSS['borderBottomColor']>;
163
+ /** Shorthand for CSS property `borderLeftColor` */
164
+ bdlc?: WithResponsive<ColorScheme | CSS['borderLeftColor']>;
165
+ /** Shorthand for CSS property `borderRightColor` */
166
+ bdrc?: WithResponsive<ColorScheme | CSS['borderRightColor']>;
167
+ /** Shorthand for CSS property `borderTopWidth` */
168
+ bdtw?: WithResponsive<CSS['borderTopWidth']>;
169
+ /** Shorthand for CSS property `borderBottomWidth` */
170
+ bdbw?: WithResponsive<CSS['borderBottomWidth']>;
171
+ /** Shorthand for CSS property `borderLeftWidth` */
172
+ bdlw?: WithResponsive<CSS['borderLeftWidth']>;
173
+ /** Shorthand for CSS property `borderRightWidth` */
174
+ bdrw?: WithResponsive<CSS['borderRightWidth']>;
135
175
  /** Shorthand for CSS property `borderRadius` */
136
176
  rounded?: WithResponsive<Size | CSS['borderRadius'] | 'full'>;
137
177
  /** Shorthand for CSS property `boxShadow` */
@@ -150,5 +190,19 @@ export interface CSSSystemProps {
150
190
  align?: WithResponsive<CSS['alignItems']>;
151
191
  /** Shorthand for CSS property `justifyContent` */
152
192
  justify?: WithResponsive<CSS['justifyContent']>;
193
+ /** Shorthand for CSS property `alignSelf` */
194
+ self?: WithResponsive<CSS['alignSelf']>;
195
+ /** Shorthand for CSS property `flexBasis` */
196
+ basis?: WithResponsive<CSS['flexBasis']>;
197
+ /** Shorthand for CSS property `flex` */
198
+ flex?: WithResponsive<CSS['flex']>;
199
+ /** Shorthand for CSS property `flexGrow` */
200
+ grow?: WithResponsive<CSS['flexGrow']>;
201
+ /** Shorthand for CSS property `order` */
202
+ order?: WithResponsive<CSS['order']>;
203
+ /** Shorthand for CSS property `flexShrink` */
204
+ shrink?: WithResponsive<CSS['flexShrink']>;
205
+ /** Shorthand for CSS property `flexDirection` */
206
+ direction?: WithResponsive<CSS['flexDirection']>;
153
207
  }
154
208
  export {};
@@ -11,7 +11,7 @@ var _hooks = require("../hooks");
11
11
  var _utils = require("../utils");
12
12
  var _CustomContext = require("../Provider/CustomContext");
13
13
  var _responsive = require("./responsive");
14
- var _cssProperty = require("./css-property");
14
+ var _cssAlias = require("./css-alias");
15
15
  var _styleManager = require("./style-manager");
16
16
  /**
17
17
  * Result of the useStyled hook
@@ -90,7 +90,7 @@ function useStyled(options) {
90
90
  const propName = varName.startsWith(cssVarPrefix) ? varName.substring(cssVarPrefix.length) : varName;
91
91
 
92
92
  // Check if the property has a corresponding CSS property mapping
93
- const cssProperty = _cssProperty.cssPropertyMap[propName];
93
+ const cssProperty = _cssAlias.cssSystemPropAlias[propName];
94
94
  if (cssProperty) {
95
95
  basePropRules += `${cssProperty.property}: var(${varName}); `;
96
96
  } else if ((0, _utils.isCSSProperty)(propName)) {
@@ -141,7 +141,7 @@ function useStyled(options) {
141
141
  const propName = varName.startsWith(cssVarPrefix) ? varName.substring(cssVarPrefix.length) : varName;
142
142
 
143
143
  // Check if the property has a corresponding CSS property mapping
144
- const cssProperty = _cssProperty.cssPropertyMap[propName];
144
+ const cssProperty = _cssAlias.cssSystemPropAlias[propName];
145
145
  if (cssProperty) {
146
146
  breakpointPropRules[bp] += `${cssProperty}: var(${varName}); `;
147
147
  } else if ((0, _utils.isCSSProperty)(propName)) {