@fangxinyan/lumina 0.6.1 → 0.6.3

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 (270) hide show
  1. package/README.md +2 -1
  2. package/dist/{Alert-JJ7GB3UU.css → Alert-QBKIDY5H.css} +7 -0
  3. package/dist/Alert.cjs +3 -3
  4. package/dist/Alert.d.cts +3 -2
  5. package/dist/Alert.d.ts +3 -2
  6. package/dist/Alert.js +2 -2
  7. package/dist/AutoComplete.cjs +5 -4
  8. package/dist/AutoComplete.d.cts +1 -1
  9. package/dist/AutoComplete.d.ts +1 -1
  10. package/dist/AutoComplete.js +4 -3
  11. package/dist/Badge-DPGLV3D3.css +22 -0
  12. package/dist/Badge.cjs +10 -0
  13. package/dist/Badge.d.cts +19 -0
  14. package/dist/Badge.d.ts +19 -0
  15. package/dist/Badge.js +1 -0
  16. package/dist/{Button-SDQD25AG.css → Button-4Z3Q6KII.css} +56 -36
  17. package/dist/Button.cjs +3 -7
  18. package/dist/Button.d.cts +11 -15
  19. package/dist/Button.d.ts +11 -15
  20. package/dist/Button.js +2 -2
  21. package/dist/Calendar.cjs +3 -3
  22. package/dist/Calendar.js +2 -2
  23. package/dist/{Card-RG7ECXL2.css → Card-6RMVIHWX.css} +7 -13
  24. package/dist/Card.cjs +2 -6
  25. package/dist/Card.d.cts +7 -11
  26. package/dist/Card.d.ts +7 -11
  27. package/dist/Card.js +1 -1
  28. package/dist/{Cascader-VSYEKQCG.css → Cascader-3BLLA7EN.css} +77 -0
  29. package/dist/Cascader.cjs +5 -3
  30. package/dist/Cascader.d.cts +22 -4
  31. package/dist/Cascader.d.ts +22 -4
  32. package/dist/Cascader.js +4 -2
  33. package/dist/{Checkbox-SKJATVSN.css → Checkbox-U5EUDSYS.css} +5 -35
  34. package/dist/Checkbox.cjs +3 -7
  35. package/dist/Checkbox.d.cts +1 -18
  36. package/dist/Checkbox.d.ts +1 -18
  37. package/dist/Checkbox.js +2 -2
  38. package/dist/Collapse-66U5YJFY.css +53 -0
  39. package/dist/Collapse.cjs +11 -0
  40. package/dist/Collapse.d.cts +32 -0
  41. package/dist/Collapse.d.ts +32 -0
  42. package/dist/Collapse.js +2 -0
  43. package/dist/CommandPalette.cjs +5 -4
  44. package/dist/CommandPalette.js +4 -3
  45. package/dist/Drawer.cjs +3 -3
  46. package/dist/Drawer.js +2 -2
  47. package/dist/Empty-DC2LPORC.css +28 -0
  48. package/dist/Empty.cjs +2 -10
  49. package/dist/Empty.d.cts +1 -62
  50. package/dist/Empty.d.ts +1 -62
  51. package/dist/Empty.js +1 -1
  52. package/dist/Form.d.cts +1 -1
  53. package/dist/Form.d.ts +1 -1
  54. package/dist/Icon.cjs +187 -3
  55. package/dist/Icon.d.cts +104 -3
  56. package/dist/Icon.d.ts +104 -3
  57. package/dist/Icon.js +1 -1
  58. package/dist/{Image-4MN34O6P.css → Image-MRYQCRQ5.css} +78 -0
  59. package/dist/Image.cjs +12 -4
  60. package/dist/Image.d.cts +79 -6
  61. package/dist/Image.d.ts +79 -6
  62. package/dist/Image.js +2 -2
  63. package/dist/{Input-33CAH4O6.css → Input-HUBJ55OH.css} +25 -42
  64. package/dist/Input.cjs +6 -5
  65. package/dist/Input.d.cts +23 -26
  66. package/dist/Input.d.ts +23 -26
  67. package/dist/Input.js +3 -2
  68. package/dist/InputNumber.cjs +5 -4
  69. package/dist/InputNumber.d.cts +1 -1
  70. package/dist/InputNumber.d.ts +1 -1
  71. package/dist/InputNumber.js +4 -3
  72. package/dist/Message-2MZ3LFPU.css +45 -0
  73. package/dist/Message.cjs +23 -0
  74. package/dist/Message.d.cts +54 -0
  75. package/dist/Message.d.ts +54 -0
  76. package/dist/Message.js +2 -0
  77. package/dist/{Modal-XSDMU4XJ.css → Modal-2QNDW4SO.css} +27 -0
  78. package/dist/Modal.cjs +4 -4
  79. package/dist/Modal.d.cts +29 -4
  80. package/dist/Modal.d.ts +29 -4
  81. package/dist/Modal.js +3 -3
  82. package/dist/Pagination.cjs +7 -5
  83. package/dist/Pagination.js +6 -4
  84. package/dist/Popover.cjs +2 -2
  85. package/dist/Popover.d.cts +11 -3
  86. package/dist/Popover.d.ts +11 -3
  87. package/dist/Popover.js +1 -1
  88. package/dist/Radio-GVFDPAZM.css +97 -0
  89. package/dist/Radio.cjs +14 -0
  90. package/dist/Radio.d.cts +36 -0
  91. package/dist/Radio.d.ts +36 -0
  92. package/dist/Radio.js +1 -0
  93. package/dist/{Select-J3CCVFJ7.css → Select-Z5VYPEEY.css} +33 -24
  94. package/dist/Select.cjs +6 -4
  95. package/dist/Select.d.cts +29 -7
  96. package/dist/Select.d.ts +29 -7
  97. package/dist/Select.js +5 -3
  98. package/dist/Skeleton-CVWH2VWN.css +40 -0
  99. package/dist/Skeleton.cjs +10 -0
  100. package/dist/Skeleton.d.cts +30 -0
  101. package/dist/Skeleton.d.ts +30 -0
  102. package/dist/Skeleton.js +1 -0
  103. package/dist/Spin-3GJNMSIH.css +94 -0
  104. package/dist/Spin.cjs +10 -0
  105. package/dist/Spin.d.cts +20 -0
  106. package/dist/Spin.d.ts +20 -0
  107. package/dist/Spin.js +1 -0
  108. package/dist/{Table-2LPTOUIR.css → Table-ATJJQLKU.css} +0 -53
  109. package/dist/Table.cjs +9 -11
  110. package/dist/Table.d.cts +2 -21
  111. package/dist/Table.d.ts +2 -21
  112. package/dist/Table.js +8 -6
  113. package/dist/TablePro-3XVHYLSL.css +45 -0
  114. package/dist/TablePro.cjs +19 -0
  115. package/dist/TablePro.d.cts +21 -0
  116. package/dist/TablePro.d.ts +21 -0
  117. package/dist/TablePro.js +10 -0
  118. package/dist/{Tabs-RHK6XAFF.css → Tabs-BLSNI2T5.css} +0 -34
  119. package/dist/Tabs.cjs +2 -6
  120. package/dist/Tabs.d.cts +1 -16
  121. package/dist/Tabs.d.ts +1 -16
  122. package/dist/Tabs.js +1 -1
  123. package/dist/Tag-HDYCDPFS.css +42 -0
  124. package/dist/Tag.cjs +3 -7
  125. package/dist/Tag.d.cts +5 -14
  126. package/dist/Tag.d.ts +5 -14
  127. package/dist/Tag.js +2 -2
  128. package/dist/Textarea-YNET7IBH.css +54 -0
  129. package/dist/Textarea.cjs +15 -0
  130. package/dist/Textarea.d.cts +25 -0
  131. package/dist/Textarea.d.ts +25 -0
  132. package/dist/Textarea.js +2 -0
  133. package/dist/Theme.cjs +14 -10
  134. package/dist/Theme.d.cts +29 -6
  135. package/dist/Theme.d.ts +29 -6
  136. package/dist/Theme.js +1 -1
  137. package/dist/{Timeline-RHZAZKZ7.css → Timeline-3ZHOHPXT.css} +2 -2
  138. package/dist/Timeline.cjs +3 -3
  139. package/dist/Timeline.d.cts +1 -1
  140. package/dist/Timeline.d.ts +1 -1
  141. package/dist/Timeline.js +2 -2
  142. package/dist/Tooltip.cjs +2 -2
  143. package/dist/Tooltip.d.cts +17 -4
  144. package/dist/Tooltip.d.ts +17 -4
  145. package/dist/Tooltip.js +1 -1
  146. package/dist/Typography.cjs +7 -7
  147. package/dist/Typography.d.cts +1 -0
  148. package/dist/Typography.d.ts +1 -0
  149. package/dist/Typography.js +2 -2
  150. package/dist/{chunk-OVZTG5CP.cjs → chunk-2HQCUBA7.cjs} +2 -2
  151. package/dist/{chunk-X2U7EKCS.cjs → chunk-3YJU3D5S.cjs} +28 -5
  152. package/dist/chunk-45VJGBGN.js +25 -0
  153. package/dist/{chunk-3D77MQHO.js → chunk-46VXFTEC.js} +3 -3
  154. package/dist/chunk-47VG2P34.js +393 -0
  155. package/dist/{chunk-LZU33BX6.cjs → chunk-5DKRY67M.cjs} +4 -20
  156. package/dist/{chunk-TWGQZX2R.js → chunk-5H5YP2TB.js} +4 -19
  157. package/dist/chunk-5MN3PMF4.cjs +240 -0
  158. package/dist/{chunk-5A3RT4KD.js → chunk-5TKC6IEN.js} +4 -55
  159. package/dist/{chunk-N57NXCNC.cjs → chunk-6HMTV6P4.cjs} +3 -44
  160. package/dist/{chunk-RF2EY5JS.cjs → chunk-6ZXQJRAT.cjs} +153 -34
  161. package/dist/{chunk-OFGDUCT7.cjs → chunk-7AG524YZ.cjs} +3 -3
  162. package/dist/chunk-7IYKKLV3.js +283 -0
  163. package/dist/{chunk-73RQBWWW.js → chunk-AAGF7K3L.js} +2 -2
  164. package/dist/chunk-AXZ7ELMA.js +41 -0
  165. package/dist/{chunk-R6BIF3FF.js → chunk-BPOOVO5T.js} +5 -23
  166. package/dist/{chunk-OI3CWXT3.js → chunk-BVQ77VRY.js} +3 -3
  167. package/dist/{chunk-UXH5PH3S.js → chunk-CETNCRZ4.js} +2 -2
  168. package/dist/chunk-DG5VQ6BO.cjs +28 -0
  169. package/dist/chunk-DWAN57G4.js +243 -0
  170. package/dist/chunk-ELNT3CFO.js +64 -0
  171. package/dist/{chunk-ULOJ5UEY.js → chunk-ET6DYQVZ.js} +1 -1
  172. package/dist/chunk-F6RYCBQG.js +25 -0
  173. package/dist/{chunk-RPFMQZA5.js → chunk-FBYUZOZP.js} +42 -31
  174. package/dist/chunk-FGW5GJ22.cjs +132 -0
  175. package/dist/{chunk-6Y5WRCPW.js → chunk-FWPBORRB.js} +1 -1
  176. package/dist/chunk-GENABQYA.cjs +47 -0
  177. package/dist/{chunk-TGHBKKSS.js → chunk-GIZU3H6H.js} +3 -43
  178. package/dist/chunk-GMN74OEY.cjs +63 -0
  179. package/dist/{chunk-Y47YTYQ3.cjs → chunk-H4LGWZMH.cjs} +159 -8
  180. package/dist/chunk-HKF2V5MM.cjs +214 -0
  181. package/dist/chunk-HLFH5HWR.js +81 -0
  182. package/dist/{chunk-4WRE4HQP.js → chunk-HWFM4MAT.js} +18 -6
  183. package/dist/{chunk-GY3BSHHS.cjs → chunk-HZSIUOCN.cjs} +2 -55
  184. package/dist/{chunk-D46EM4EN.js → chunk-I5WTQ5Y3.js} +4 -4
  185. package/dist/chunk-J2HZTJO6.js +26 -0
  186. package/dist/{chunk-NN25YMOL.js → chunk-J5ZGYQZK.js} +153 -35
  187. package/dist/{chunk-WRDKOSSM.js → chunk-JCEHZ336.js} +1 -1
  188. package/dist/chunk-JVUVOR6S.js +110 -0
  189. package/dist/chunk-K5IGFBDR.js +113 -0
  190. package/dist/{chunk-Q2KG6SQK.cjs → chunk-K7FV7W6U.cjs} +5 -5
  191. package/dist/{chunk-PWW64ZWO.cjs → chunk-KD4YYIIO.cjs} +1 -32
  192. package/dist/chunk-KGSADAOD.cjs +170 -0
  193. package/dist/{chunk-54YLXXS2.js → chunk-ME5BZ2WA.js} +2 -2
  194. package/dist/chunk-MPVCYU2K.cjs +104 -0
  195. package/dist/{chunk-EEMWQX3C.cjs → chunk-NTS5L4NQ.cjs} +3 -3
  196. package/dist/{chunk-WBK6XIDJ.js → chunk-OBEKX4VR.js} +2 -32
  197. package/dist/{chunk-EBNRZRWY.cjs → chunk-P6EZG2R7.cjs} +5 -5
  198. package/dist/{chunk-KYEY2LIB.cjs → chunk-P6P4DGLF.cjs} +3 -3
  199. package/dist/{chunk-GOBWKQCX.cjs → chunk-PULGVK2I.cjs} +3 -3
  200. package/dist/chunk-Q5SZIU7Z.cjs +47 -0
  201. package/dist/chunk-QKQHZIF3.cjs +86 -0
  202. package/dist/{chunk-3TWNBJFI.cjs → chunk-QP3VCSRY.cjs} +6 -6
  203. package/dist/{chunk-6ODY6MGL.cjs → chunk-R2TEDH2F.cjs} +5 -5
  204. package/dist/{chunk-YRZGXXWA.js → chunk-SQGPSMSK.js} +14 -20
  205. package/dist/{chunk-IW5LW6XS.js → chunk-TEEFR2FD.js} +28 -5
  206. package/dist/chunk-TGL5BGMR.js +218 -0
  207. package/dist/{chunk-62GU4OHH.cjs → chunk-TP567B3L.cjs} +13 -20
  208. package/dist/chunk-UKS23N3L.js +191 -0
  209. package/dist/chunk-USQ43DJ5.js +147 -0
  210. package/dist/{chunk-G2K6ETP4.cjs → chunk-UUHFKIWP.cjs} +18 -6
  211. package/dist/{chunk-2MNAZRWE.cjs → chunk-V272XR3F.cjs} +271 -2
  212. package/dist/chunk-VFFIE2VO.cjs +271 -0
  213. package/dist/{chunk-FIO65XYG.cjs → chunk-X5GCOMC3.cjs} +49 -38
  214. package/dist/{chunk-Y3ZSG3SJ.cjs → chunk-XSN4TLN5.cjs} +11 -30
  215. package/dist/chunk-ZKE73UQF.cjs +138 -0
  216. package/dist/index.cjs +342 -132
  217. package/dist/index.d.cts +26 -20
  218. package/dist/index.d.ts +26 -20
  219. package/dist/index.js +35 -29
  220. package/dist/styles.css +515 -230
  221. package/docs/llms/alert.md +4 -3
  222. package/docs/llms/badge.md +3 -3
  223. package/docs/llms/button.md +11 -41
  224. package/docs/llms/card.md +6 -12
  225. package/docs/llms/cascader.md +22 -0
  226. package/docs/llms/{accordion.md → collapse.md} +13 -11
  227. package/docs/llms/drawer.md +1 -1
  228. package/docs/llms/form.md +1 -1
  229. package/docs/llms/image.md +72 -1
  230. package/docs/llms/input.md +28 -18
  231. package/docs/llms/message.md +63 -0
  232. package/docs/llms/modal.md +30 -0
  233. package/docs/llms/popover.md +18 -1
  234. package/docs/llms/radio.md +37 -1
  235. package/docs/llms/select.md +22 -2
  236. package/docs/llms/spin.md +59 -0
  237. package/docs/llms/table.md +3 -3
  238. package/docs/llms/tag.md +3 -2
  239. package/docs/llms/theme.md +41 -4
  240. package/docs/llms/tooltip.md +16 -3
  241. package/docs/llms.md +8 -8
  242. package/package.json +32 -52
  243. package/dist/Accordion-REMDCQUD.css +0 -44
  244. package/dist/Accordion.cjs +0 -11
  245. package/dist/Accordion.d.cts +0 -33
  246. package/dist/Accordion.d.ts +0 -33
  247. package/dist/Accordion.js +0 -2
  248. package/dist/Empty-NQ72W3D7.css +0 -160
  249. package/dist/Tag-FGDY3W7E.css +0 -51
  250. package/dist/Toast-YSACW3EM.css +0 -45
  251. package/dist/Toast.cjs +0 -15
  252. package/dist/Toast.d.cts +0 -26
  253. package/dist/Toast.d.ts +0 -26
  254. package/dist/Toast.js +0 -2
  255. package/dist/chunk-32HBMXXV.cjs +0 -208
  256. package/dist/chunk-3XTHKAEY.js +0 -39
  257. package/dist/chunk-5M26OVVY.js +0 -90
  258. package/dist/chunk-DOMYUGJY.js +0 -132
  259. package/dist/chunk-DPNDHNKK.js +0 -185
  260. package/dist/chunk-G2XK57I7.cjs +0 -116
  261. package/dist/chunk-HBWO3QKW.js +0 -74
  262. package/dist/chunk-JVS5ZALZ.js +0 -123
  263. package/dist/chunk-LIGHV4RC.cjs +0 -121
  264. package/dist/chunk-MCTIA6RZ.js +0 -99
  265. package/dist/chunk-NC4YUEXM.cjs +0 -145
  266. package/dist/chunk-NJ6B22YJ.js +0 -170
  267. package/dist/chunk-W64ARHLJ.cjs +0 -62
  268. package/dist/chunk-ZFW6OYAO.cjs +0 -100
  269. package/docs/llms/spinner.md +0 -58
  270. package/docs/llms/toast.md +0 -51
@@ -24,6 +24,24 @@
24
24
  }
25
25
  .cascader-trigger.placeholder { color: var(--fg-subtle); }
26
26
  .cascader.open .cascader-trigger { box-shadow: var(--neu-in-sm); color: var(--accent-ink); }
27
+ .cascader-clear {
28
+ position: absolute;
29
+ right: 30px;
30
+ top: 50%;
31
+ transform: translateY(-50%);
32
+ width: 20px;
33
+ height: 20px;
34
+ border-radius: 999px;
35
+ background: var(--bg);
36
+ box-shadow: var(--neu-out-sm);
37
+ display: inline-grid;
38
+ place-items: center;
39
+ color: var(--fg-subtle);
40
+ opacity: 0;
41
+ transition: all var(--dur-fast) var(--ease);
42
+ }
43
+ .cascader:hover .cascader-clear { opacity: 1; }
44
+ .cascader-clear:hover { color: var(--accent-ink); box-shadow: var(--neu-in-sm); }
27
45
  .cascader-panel {
28
46
  z-index: 1000;
29
47
  display: flex;
@@ -34,6 +52,52 @@
34
52
  animation: menuIn var(--dur) var(--ease);
35
53
  gap: 4px;
36
54
  }
55
+ .cascader-panel.with-search {
56
+ flex-direction: column;
57
+ min-width: 320px;
58
+ }
59
+ .cascader-columns {
60
+ display: flex;
61
+ gap: 4px;
62
+ }
63
+ .cascader-search {
64
+ padding: 4px 2px 8px;
65
+ border-bottom: 1px solid var(--divider);
66
+ }
67
+ .cascader-search-list {
68
+ display: flex;
69
+ flex-direction: column;
70
+ gap: 4px;
71
+ max-height: 260px;
72
+ overflow-y: auto;
73
+ padding: 4px;
74
+ }
75
+ .cascader-search-item {
76
+ border: none;
77
+ background: transparent;
78
+ color: var(--fg);
79
+ border-radius: var(--r-sm);
80
+ padding: 8px 10px;
81
+ display: flex;
82
+ align-items: center;
83
+ gap: 6px;
84
+ font-size: 13px;
85
+ font-family: inherit;
86
+ text-align: left;
87
+ cursor: pointer;
88
+ }
89
+ .cascader-search-item:hover {
90
+ background: var(--bg);
91
+ box-shadow: var(--neu-flat);
92
+ color: var(--accent-ink);
93
+ }
94
+ .cascader-path-sep { color: var(--fg-subtle); }
95
+ .cascader-empty {
96
+ padding: 24px 12px;
97
+ text-align: center;
98
+ color: var(--fg-muted);
99
+ font-size: 12px;
100
+ }
37
101
  .cascader-col {
38
102
  min-width: 160px;
39
103
  max-height: 280px;
@@ -62,6 +126,19 @@
62
126
  width: 100%;
63
127
  text-align: left;
64
128
  }
129
+ .cascader-icon {
130
+ display: inline-flex;
131
+ align-items: center;
132
+ justify-content: center;
133
+ line-height: 0;
134
+ flex-shrink: 0;
135
+ }
136
+ .cascader-icon img {
137
+ display: block;
138
+ width: 15px;
139
+ height: 15px;
140
+ object-fit: contain;
141
+ }
65
142
  .cascader-item:hover { background: var(--bg); box-shadow: var(--neu-flat); color: var(--accent-ink); }
66
143
  .cascader-item.active {
67
144
  background: var(--bg);
package/dist/Cascader.cjs CHANGED
@@ -1,12 +1,14 @@
1
1
  'use strict';
2
2
 
3
- var chunkNC4YUEXM_cjs = require('./chunk-NC4YUEXM.cjs');
3
+ var chunk5MN3PMF4_cjs = require('./chunk-5MN3PMF4.cjs');
4
4
  require('./chunk-YB3IWIOJ.cjs');
5
- require('./chunk-2MNAZRWE.cjs');
5
+ require('./chunk-HKF2V5MM.cjs');
6
+ require('./chunk-MPVCYU2K.cjs');
7
+ require('./chunk-V272XR3F.cjs');
6
8
 
7
9
 
8
10
 
9
11
  Object.defineProperty(exports, "Cascader", {
10
12
  enumerable: true,
11
- get: function () { return chunkNC4YUEXM_cjs.Cascader; }
13
+ get: function () { return chunk5MN3PMF4_cjs.Cascader; }
12
14
  });
@@ -1,23 +1,41 @@
1
1
  import * as React from 'react';
2
- import { IconName } from './Icon.cjs';
2
+ import { IconSlot } from './Icon.cjs';
3
+ import 'react/jsx-runtime';
3
4
 
4
5
  interface CascaderOption {
5
6
  value: string;
6
7
  label: React.ReactNode;
7
- icon?: IconName;
8
+ /** Leading icon. Accepts a built-in icon name or custom React node. */
9
+ icon?: IconSlot;
8
10
  children?: CascaderOption[];
9
11
  disabled?: boolean;
10
12
  }
13
+ interface CascaderShowSearchConfig {
14
+ filter?: (inputValue: string, path: CascaderOption[]) => boolean;
15
+ render?: (inputValue: string, path: CascaderOption[]) => React.ReactNode;
16
+ limit?: number | false;
17
+ }
11
18
  interface CascaderProps extends Omit<React.HTMLAttributes<HTMLDivElement>, "onChange" | "defaultValue"> {
12
19
  options: CascaderOption[];
13
20
  value?: string[];
14
21
  defaultValue?: string[];
15
- onChange?: (path: string[]) => void;
22
+ onChange?: (path: string[], selectedOptions?: CascaderOption[]) => void;
16
23
  placeholder?: string;
17
24
  disabled?: boolean;
25
+ /** Show a clear button. */
26
+ allowClear?: boolean;
27
+ onClear?: () => void;
28
+ /** Select intermediate nodes instead of only leaf nodes. */
29
+ changeOnSelect?: boolean;
30
+ /** Search mode. */
31
+ showSearch?: boolean | CascaderShowSearchConfig;
32
+ /** Class for the popped-out panel. */
33
+ popupClassName?: string;
34
+ /** Additional alias for `popupClassName`. */
35
+ dropdownClassName?: string;
18
36
  className?: string;
19
37
  }
20
38
  /** `Cascader` — multi-column hierarchical selector. */
21
39
  declare const Cascader: React.ForwardRefExoticComponent<CascaderProps & React.RefAttributes<HTMLDivElement>>;
22
40
 
23
- export { Cascader, type CascaderOption, type CascaderProps };
41
+ export { Cascader, type CascaderOption, type CascaderProps, type CascaderShowSearchConfig };
@@ -1,23 +1,41 @@
1
1
  import * as React from 'react';
2
- import { IconName } from './Icon.js';
2
+ import { IconSlot } from './Icon.js';
3
+ import 'react/jsx-runtime';
3
4
 
4
5
  interface CascaderOption {
5
6
  value: string;
6
7
  label: React.ReactNode;
7
- icon?: IconName;
8
+ /** Leading icon. Accepts a built-in icon name or custom React node. */
9
+ icon?: IconSlot;
8
10
  children?: CascaderOption[];
9
11
  disabled?: boolean;
10
12
  }
13
+ interface CascaderShowSearchConfig {
14
+ filter?: (inputValue: string, path: CascaderOption[]) => boolean;
15
+ render?: (inputValue: string, path: CascaderOption[]) => React.ReactNode;
16
+ limit?: number | false;
17
+ }
11
18
  interface CascaderProps extends Omit<React.HTMLAttributes<HTMLDivElement>, "onChange" | "defaultValue"> {
12
19
  options: CascaderOption[];
13
20
  value?: string[];
14
21
  defaultValue?: string[];
15
- onChange?: (path: string[]) => void;
22
+ onChange?: (path: string[], selectedOptions?: CascaderOption[]) => void;
16
23
  placeholder?: string;
17
24
  disabled?: boolean;
25
+ /** Show a clear button. */
26
+ allowClear?: boolean;
27
+ onClear?: () => void;
28
+ /** Select intermediate nodes instead of only leaf nodes. */
29
+ changeOnSelect?: boolean;
30
+ /** Search mode. */
31
+ showSearch?: boolean | CascaderShowSearchConfig;
32
+ /** Class for the popped-out panel. */
33
+ popupClassName?: string;
34
+ /** Additional alias for `popupClassName`. */
35
+ dropdownClassName?: string;
18
36
  className?: string;
19
37
  }
20
38
  /** `Cascader` — multi-column hierarchical selector. */
21
39
  declare const Cascader: React.ForwardRefExoticComponent<CascaderProps & React.RefAttributes<HTMLDivElement>>;
22
40
 
23
- export { Cascader, type CascaderOption, type CascaderProps };
41
+ export { Cascader, type CascaderOption, type CascaderProps, type CascaderShowSearchConfig };
package/dist/Cascader.js CHANGED
@@ -1,3 +1,5 @@
1
- export { Cascader } from './chunk-JVS5ZALZ.js';
1
+ export { Cascader } from './chunk-TGL5BGMR.js';
2
2
  import './chunk-DUFRASGO.js';
3
- import './chunk-NJ6B22YJ.js';
3
+ import './chunk-UKS23N3L.js';
4
+ import './chunk-HLFH5HWR.js';
5
+ import './chunk-47VG2P34.js';
@@ -1,5 +1,5 @@
1
- /* ============ Checkbox & Radio ============ */
2
- .checkbox, .radio {
1
+ /* ============ Checkbox ============ */
2
+ .checkbox {
3
3
  display: inline-flex;
4
4
  align-items: center;
5
5
  gap: 10px;
@@ -8,7 +8,7 @@
8
8
  font-size: 13px;
9
9
  color: var(--fg);
10
10
  }
11
- .checkbox.disabled, .radio.disabled { opacity: 0.5; cursor: not-allowed; }
11
+ .checkbox.disabled { opacity: 0.5; cursor: not-allowed; }
12
12
  .checkbox-box {
13
13
  width: 20px; height: 20px;
14
14
  border: none;
@@ -20,7 +20,7 @@
20
20
  place-items: center;
21
21
  flex-shrink: 0;
22
22
  cursor: inherit;
23
- color: white;
23
+ color: var(--bg);
24
24
  transition: all var(--dur) var(--ease);
25
25
  }
26
26
  .checkbox-box svg { opacity: 0; transform: scale(0.6); transition: all var(--dur) var(--ease); }
@@ -36,37 +36,7 @@
36
36
  .checkbox.indeterminate .checkbox-box::after {
37
37
  content: "";
38
38
  width: 10px; height: 2px;
39
- background: white;
39
+ background: var(--bg);
40
40
  border-radius: 2px;
41
41
  }
42
42
  .checkbox.indeterminate .checkbox-box svg { display: none; }
43
-
44
- .radio-dot {
45
- width: 20px; height: 20px;
46
- border: none;
47
- padding: 0;
48
- border-radius: 999px;
49
- background: var(--bg);
50
- box-shadow: var(--neu-in-sm);
51
- cursor: inherit;
52
- position: relative;
53
- flex-shrink: 0;
54
- transition: all var(--dur) var(--ease);
55
- }
56
- .radio.checked .radio-dot {
57
- background: var(--accent);
58
- box-shadow: var(--neu-out-sm), 0 2px 8px var(--accent-glow);
59
- }
60
- .radio.checked .radio-dot::after {
61
- content: "";
62
- position: absolute;
63
- top: 50%; left: 50%;
64
- transform: translate(-50%, -50%);
65
- width: 8px; height: 8px;
66
- border-radius: 999px;
67
- background: white;
68
- }
69
-
70
- .radio-group { display: flex; gap: 14px; }
71
- .radio-group.vertical { flex-direction: column; gap: 10px; }
72
- .radio-group.horizontal { flex-direction: row; flex-wrap: wrap; }
package/dist/Checkbox.cjs CHANGED
@@ -1,15 +1,11 @@
1
1
  'use strict';
2
2
 
3
- var chunkN57NXCNC_cjs = require('./chunk-N57NXCNC.cjs');
4
- require('./chunk-2MNAZRWE.cjs');
3
+ var chunk6HMTV6P4_cjs = require('./chunk-6HMTV6P4.cjs');
4
+ require('./chunk-V272XR3F.cjs');
5
5
 
6
6
 
7
7
 
8
8
  Object.defineProperty(exports, "Checkbox", {
9
9
  enumerable: true,
10
- get: function () { return chunkN57NXCNC_cjs.Checkbox; }
11
- });
12
- Object.defineProperty(exports, "RadioGroup", {
13
- enumerable: true,
14
- get: function () { return chunkN57NXCNC_cjs.RadioGroup; }
10
+ get: function () { return chunk6HMTV6P4_cjs.Checkbox; }
15
11
  });
@@ -12,22 +12,5 @@ interface CheckboxProps extends Omit<React.LabelHTMLAttributes<HTMLLabelElement>
12
12
  }
13
13
  /** `Checkbox` — binary choice, supports indeterminate state. */
14
14
  declare const Checkbox: React.ForwardRefExoticComponent<CheckboxProps & React.RefAttributes<HTMLLabelElement>>;
15
- interface RadioOption<T extends string | number = string> {
16
- value: T;
17
- label: React.ReactNode;
18
- disabled?: boolean;
19
- }
20
- interface RadioGroupProps<T extends string | number = string> extends Omit<React.HTMLAttributes<HTMLDivElement>, "onChange" | "defaultValue"> {
21
- options: RadioOption<T>[];
22
- value?: T;
23
- defaultValue?: T;
24
- onChange?: (value: T) => void;
25
- name?: string;
26
- direction?: "vertical" | "horizontal";
27
- className?: string;
28
- }
29
- type RadioGroupComponent = <T extends string | number = string>(props: RadioGroupProps<T> & React.RefAttributes<HTMLDivElement>) => React.ReactElement | null;
30
- /** `RadioGroup` — mutually exclusive options. */
31
- declare const RadioGroup: RadioGroupComponent;
32
15
 
33
- export { Checkbox, type CheckboxProps, RadioGroup, type RadioGroupProps, type RadioOption };
16
+ export { Checkbox, type CheckboxProps };
@@ -12,22 +12,5 @@ interface CheckboxProps extends Omit<React.LabelHTMLAttributes<HTMLLabelElement>
12
12
  }
13
13
  /** `Checkbox` — binary choice, supports indeterminate state. */
14
14
  declare const Checkbox: React.ForwardRefExoticComponent<CheckboxProps & React.RefAttributes<HTMLLabelElement>>;
15
- interface RadioOption<T extends string | number = string> {
16
- value: T;
17
- label: React.ReactNode;
18
- disabled?: boolean;
19
- }
20
- interface RadioGroupProps<T extends string | number = string> extends Omit<React.HTMLAttributes<HTMLDivElement>, "onChange" | "defaultValue"> {
21
- options: RadioOption<T>[];
22
- value?: T;
23
- defaultValue?: T;
24
- onChange?: (value: T) => void;
25
- name?: string;
26
- direction?: "vertical" | "horizontal";
27
- className?: string;
28
- }
29
- type RadioGroupComponent = <T extends string | number = string>(props: RadioGroupProps<T> & React.RefAttributes<HTMLDivElement>) => React.ReactElement | null;
30
- /** `RadioGroup` — mutually exclusive options. */
31
- declare const RadioGroup: RadioGroupComponent;
32
15
 
33
- export { Checkbox, type CheckboxProps, RadioGroup, type RadioGroupProps, type RadioOption };
16
+ export { Checkbox, type CheckboxProps };
package/dist/Checkbox.js CHANGED
@@ -1,2 +1,2 @@
1
- export { Checkbox, RadioGroup } from './chunk-TGHBKKSS.js';
2
- import './chunk-NJ6B22YJ.js';
1
+ export { Checkbox } from './chunk-GIZU3H6H.js';
2
+ import './chunk-47VG2P34.js';
@@ -0,0 +1,53 @@
1
+ /* ============ Collapse ============ */
2
+ .collapse { display: flex; flex-direction: column; gap: 10px; }
3
+ .collapse-item {
4
+ background: var(--bg);
5
+ border-radius: var(--r-md);
6
+ box-shadow: var(--neu-out-sm);
7
+ overflow: hidden;
8
+ }
9
+ .collapse.ghost .collapse-item {
10
+ background: transparent;
11
+ box-shadow: none;
12
+ border-radius: var(--r-sm);
13
+ }
14
+ .collapse-item.disabled { opacity: 0.5; }
15
+ .collapse-head {
16
+ width: 100%;
17
+ border: none;
18
+ background: transparent;
19
+ padding: 14px 18px;
20
+ display: flex;
21
+ align-items: center;
22
+ justify-content: space-between;
23
+ cursor: pointer;
24
+ font-size: 13px;
25
+ font-weight: 500;
26
+ font-family: inherit;
27
+ color: var(--fg);
28
+ text-align: left;
29
+ }
30
+ .collapse.small .collapse-head { padding: 10px 14px; font-size: 12px; }
31
+ .collapse.large .collapse-head { padding: 18px 22px; font-size: 14px; }
32
+ .collapse-item.disabled .collapse-head { cursor: not-allowed; }
33
+ .collapse-item.icon-only .collapse-head:not(:disabled) { cursor: default; }
34
+ .collapse-body {
35
+ max-height: 0;
36
+ overflow: hidden;
37
+ transition: max-height var(--dur) var(--ease);
38
+ color: var(--fg-muted);
39
+ font-size: 13px;
40
+ }
41
+ .collapse-body-inner { padding: 0 18px 16px; }
42
+ .collapse.small .collapse-body-inner { padding: 0 14px 12px; }
43
+ .collapse.large .collapse-body-inner { padding: 0 22px 20px; }
44
+ .collapse-chev {
45
+ transition: transform var(--dur) var(--ease), color var(--dur) var(--ease);
46
+ color: var(--fg-subtle);
47
+ display: inline-flex;
48
+ border-radius: var(--r-xs);
49
+ padding: 2px;
50
+ }
51
+ .collapse-chev.clickable { cursor: pointer; }
52
+ .collapse-chev.clickable:hover { color: var(--fg); background: var(--bg); box-shadow: var(--neu-flat); }
53
+ .collapse-item.open .collapse-chev { transform: rotate(180deg); color: var(--accent); }
@@ -0,0 +1,11 @@
1
+ 'use strict';
2
+
3
+ var chunkFGW5GJ22_cjs = require('./chunk-FGW5GJ22.cjs');
4
+ require('./chunk-V272XR3F.cjs');
5
+
6
+
7
+
8
+ Object.defineProperty(exports, "Collapse", {
9
+ enumerable: true,
10
+ get: function () { return chunkFGW5GJ22_cjs.Collapse; }
11
+ });
@@ -0,0 +1,32 @@
1
+ import * as React from 'react';
2
+
3
+ interface CollapseItem {
4
+ key: string;
5
+ label: React.ReactNode;
6
+ children: React.ReactNode;
7
+ disabled?: boolean;
8
+ }
9
+ interface CollapseProps extends Omit<React.HTMLAttributes<HTMLDivElement>, "onChange"> {
10
+ items: CollapseItem[];
11
+ /** If true, at most one item can be open at a time. */
12
+ accordion?: boolean;
13
+ /** If false, at most one section can be open. Kept for explicit Lumina layouts. */
14
+ multiple?: boolean;
15
+ /**
16
+ * What triggers expansion.
17
+ * - `"header"` (default): clicking anywhere on the header toggles.
18
+ * - `"icon"`: only the chevron icon is clickable.
19
+ * - `"disabled"`: the panel cannot be toggled.
20
+ */
21
+ collapsible?: "header" | "icon" | "disabled";
22
+ activeKey?: string | string[];
23
+ defaultActiveKey?: string | string[];
24
+ onChange?: (keys: string[]) => void;
25
+ ghost?: boolean;
26
+ size?: "small" | "middle" | "large";
27
+ className?: string;
28
+ }
29
+ /** `Collapse` — collapsible sections. */
30
+ declare const Collapse: React.ForwardRefExoticComponent<CollapseProps & React.RefAttributes<HTMLDivElement>>;
31
+
32
+ export { Collapse, type CollapseItem, type CollapseProps };
@@ -0,0 +1,32 @@
1
+ import * as React from 'react';
2
+
3
+ interface CollapseItem {
4
+ key: string;
5
+ label: React.ReactNode;
6
+ children: React.ReactNode;
7
+ disabled?: boolean;
8
+ }
9
+ interface CollapseProps extends Omit<React.HTMLAttributes<HTMLDivElement>, "onChange"> {
10
+ items: CollapseItem[];
11
+ /** If true, at most one item can be open at a time. */
12
+ accordion?: boolean;
13
+ /** If false, at most one section can be open. Kept for explicit Lumina layouts. */
14
+ multiple?: boolean;
15
+ /**
16
+ * What triggers expansion.
17
+ * - `"header"` (default): clicking anywhere on the header toggles.
18
+ * - `"icon"`: only the chevron icon is clickable.
19
+ * - `"disabled"`: the panel cannot be toggled.
20
+ */
21
+ collapsible?: "header" | "icon" | "disabled";
22
+ activeKey?: string | string[];
23
+ defaultActiveKey?: string | string[];
24
+ onChange?: (keys: string[]) => void;
25
+ ghost?: boolean;
26
+ size?: "small" | "middle" | "large";
27
+ className?: string;
28
+ }
29
+ /** `Collapse` — collapsible sections. */
30
+ declare const Collapse: React.ForwardRefExoticComponent<CollapseProps & React.RefAttributes<HTMLDivElement>>;
31
+
32
+ export { Collapse, type CollapseItem, type CollapseProps };
@@ -0,0 +1,2 @@
1
+ export { Collapse } from './chunk-JVUVOR6S.js';
2
+ import './chunk-47VG2P34.js';
@@ -1,12 +1,13 @@
1
1
  'use strict';
2
2
 
3
- var chunkGOBWKQCX_cjs = require('./chunk-GOBWKQCX.cjs');
4
- require('./chunk-32HBMXXV.cjs');
5
- require('./chunk-2MNAZRWE.cjs');
3
+ var chunkPULGVK2I_cjs = require('./chunk-PULGVK2I.cjs');
4
+ require('./chunk-HKF2V5MM.cjs');
5
+ require('./chunk-MPVCYU2K.cjs');
6
+ require('./chunk-V272XR3F.cjs');
6
7
 
7
8
 
8
9
 
9
10
  Object.defineProperty(exports, "CommandPalette", {
10
11
  enumerable: true,
11
- get: function () { return chunkGOBWKQCX_cjs.CommandPalette; }
12
+ get: function () { return chunkPULGVK2I_cjs.CommandPalette; }
12
13
  });
@@ -1,3 +1,4 @@
1
- export { CommandPalette } from './chunk-54YLXXS2.js';
2
- import './chunk-DPNDHNKK.js';
3
- import './chunk-NJ6B22YJ.js';
1
+ export { CommandPalette } from './chunk-ME5BZ2WA.js';
2
+ import './chunk-UKS23N3L.js';
3
+ import './chunk-HLFH5HWR.js';
4
+ import './chunk-47VG2P34.js';
package/dist/Drawer.cjs CHANGED
@@ -1,11 +1,11 @@
1
1
  'use strict';
2
2
 
3
- var chunkOVZTG5CP_cjs = require('./chunk-OVZTG5CP.cjs');
4
- require('./chunk-2MNAZRWE.cjs');
3
+ var chunk2HQCUBA7_cjs = require('./chunk-2HQCUBA7.cjs');
4
+ require('./chunk-V272XR3F.cjs');
5
5
 
6
6
 
7
7
 
8
8
  Object.defineProperty(exports, "Drawer", {
9
9
  enumerable: true,
10
- get: function () { return chunkOVZTG5CP_cjs.Drawer; }
10
+ get: function () { return chunk2HQCUBA7_cjs.Drawer; }
11
11
  });
package/dist/Drawer.js CHANGED
@@ -1,2 +1,2 @@
1
- export { Drawer } from './chunk-WRDKOSSM.js';
2
- import './chunk-NJ6B22YJ.js';
1
+ export { Drawer } from './chunk-JCEHZ336.js';
2
+ import './chunk-47VG2P34.js';
@@ -0,0 +1,28 @@
1
+ /* ============ Empty ============ */
2
+ .empty {
3
+ padding: 60px 20px;
4
+ display: grid; place-items: center;
5
+ gap: 12px;
6
+ color: var(--fg-muted);
7
+ text-align: center;
8
+ }
9
+ .empty.sm { padding: 28px 16px; gap: 8px; }
10
+ .empty.sm .empty-ico { width: 40px; height: 40px; }
11
+ .empty.sm .empty-title { font-size: 13px; }
12
+ .empty.sm .empty-desc { font-size: 11px; }
13
+ .empty.lg { padding: 96px 24px; gap: 16px; }
14
+ .empty.lg .empty-ico { width: 72px; height: 72px; }
15
+ .empty.lg .empty-title { font-size: 16px; }
16
+ .empty.lg .empty-desc { font-size: 13px; }
17
+ .empty.subtle .empty-ico { background: transparent; box-shadow: none; }
18
+ .empty-ico {
19
+ width: 56px; height: 56px;
20
+ border-radius: var(--r-lg);
21
+ background: var(--bg);
22
+ box-shadow: var(--neu-in-sm);
23
+ display: grid; place-items: center;
24
+ color: var(--fg-subtle);
25
+ }
26
+ .empty-title { font-size: 14px; font-weight: 600; color: var(--fg); }
27
+ .empty-desc { font-size: 12px; }
28
+ .empty-action { margin-top: 8px; }
package/dist/Empty.cjs CHANGED
@@ -1,18 +1,10 @@
1
1
  'use strict';
2
2
 
3
- var chunkGY3BSHHS_cjs = require('./chunk-GY3BSHHS.cjs');
3
+ var chunkGENABQYA_cjs = require('./chunk-GENABQYA.cjs');
4
4
 
5
5
 
6
6
 
7
7
  Object.defineProperty(exports, "Empty", {
8
8
  enumerable: true,
9
- get: function () { return chunkGY3BSHHS_cjs.Empty; }
10
- });
11
- Object.defineProperty(exports, "Skeleton", {
12
- enumerable: true,
13
- get: function () { return chunkGY3BSHHS_cjs.Skeleton; }
14
- });
15
- Object.defineProperty(exports, "Spinner", {
16
- enumerable: true,
17
- get: function () { return chunkGY3BSHHS_cjs.Spinner; }
9
+ get: function () { return chunkGENABQYA_cjs.Empty; }
18
10
  });
package/dist/Empty.d.cts CHANGED
@@ -12,66 +12,5 @@ interface EmptyProps extends Omit<React.HTMLAttributes<HTMLDivElement>, "title"
12
12
  }
13
13
  /** `Empty` — empty state placeholder. */
14
14
  declare const Empty: React.ForwardRefExoticComponent<EmptyProps & React.RefAttributes<HTMLDivElement>>;
15
- interface SpinnerProps extends React.HTMLAttributes<HTMLSpanElement> {
16
- size?: number;
17
- tone?: "accent" | "success" | "warning" | "danger" | "current";
18
- /** Text rendered next to the spinner. */
19
- label?: React.ReactNode;
20
- /** `ring` is the default border spinner; `dots` is a three-dot bounce. */
21
- variant?: "ring" | "dots";
22
- className?: string;
23
- }
24
- /** `Spinner` — loading indicator. */
25
- declare const Spinner: React.ForwardRefExoticComponent<SpinnerProps & React.RefAttributes<HTMLSpanElement>>;
26
- interface SkeletonAvatarConfig {
27
- shape?: "circle" | "square";
28
- size?: "sm" | "md" | "lg";
29
- }
30
- interface SkeletonTitleConfig {
31
- width?: number | string;
32
- }
33
- interface SkeletonParagraphConfig {
34
- rows?: number;
35
- width?: (number | string)[];
36
- }
37
- interface SkeletonProps extends Omit<React.HTMLAttributes<HTMLElement>, "title"> {
38
- width?: number | string;
39
- height?: number | string;
40
- circle?: boolean;
41
- /** `wave` is a shimmer sweep; `pulse` fades opacity; `none` disables animation. */
42
- animation?: "wave" | "pulse" | "none";
43
- /**
44
- * Render an avatar skeleton on the left. `true` gives the defaults (circle, md).
45
- * @example avatar
46
- * @example avatar={{ shape: "square", size: "lg" }}
47
- */
48
- avatar?: boolean | SkeletonAvatarConfig;
49
- /**
50
- * Render a title line skeleton. Defaults to `true` whenever the composite layout is active
51
- * (any of `avatar` / `paragraph` / `title` is set).
52
- */
53
- title?: boolean | SkeletonTitleConfig;
54
- /**
55
- * Render N paragraph lines. `true` gives 3 rows; passing `width` arrays lets you
56
- * control per-row widths (last row defaults to 60%).
57
- */
58
- paragraph?: boolean | SkeletonParagraphConfig;
59
- className?: string;
60
- }
61
- /**
62
- * `Skeleton` — content placeholder during loading.
63
- *
64
- * Two modes:
65
- * - **Primitive** (no composite prop set): renders a single block using `width` / `height` / `circle`.
66
- * - **Composite** (`avatar` / `title` / `paragraph`): renders the Ant-Design-style avatar + title + paragraph layout.
67
- *
68
- * @example
69
- * // primitive
70
- * <Skeleton height={14} width="60%" />
71
- * @example
72
- * // composite
73
- * <Skeleton avatar title paragraph={{ rows: 4 }} />
74
- */
75
- declare const Skeleton: React.ForwardRefExoticComponent<SkeletonProps & React.RefAttributes<HTMLElement>>;
76
15
 
77
- export { Empty, type EmptyProps, Skeleton, type SkeletonAvatarConfig, type SkeletonParagraphConfig, type SkeletonProps, type SkeletonTitleConfig, Spinner, type SpinnerProps };
16
+ export { Empty, type EmptyProps };