@icen.ai/ui 0.9.0 → 0.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (431) hide show
  1. package/AGENTS.md +82 -254
  2. package/LICENSE +21 -0
  3. package/README.md +60 -96
  4. package/dist/base.css +258 -188
  5. package/dist/behaviors/accordion.mjs +8 -8
  6. package/dist/behaviors/ai-branch.d.mts +1 -1
  7. package/dist/behaviors/ai-branch.mjs +1011 -94
  8. package/dist/behaviors/ai-chat.d.mts +9 -9
  9. package/dist/behaviors/ai-chat.mjs +1122 -169
  10. package/dist/behaviors/ai-composer.d.mts +47 -15
  11. package/dist/behaviors/ai-composer.mjs +2018 -534
  12. package/dist/behaviors/ai-core.d.mts +1 -1
  13. package/dist/behaviors/ai-core.mjs +1017 -107
  14. package/dist/behaviors/ai-diff.mjs +1020 -127
  15. package/dist/behaviors/ai-feedback.d.mts +1 -1
  16. package/dist/behaviors/ai-feedback.mjs +1036 -126
  17. package/dist/behaviors/ai-panel.d.mts +10 -10
  18. package/dist/behaviors/ai-panel.mjs +1285 -266
  19. package/dist/behaviors/ai-provider.d.mts +1 -1
  20. package/dist/behaviors/ai-provider.mjs +1004 -101
  21. package/dist/behaviors/ai-threads.d.mts +1 -1
  22. package/dist/behaviors/ai-threads.mjs +1069 -154
  23. package/dist/behaviors/ai-tool.d.mts +3 -3
  24. package/dist/behaviors/ai-tool.mjs +2087 -413
  25. package/dist/behaviors/ai-tools.d.mts +89 -16
  26. package/dist/behaviors/ai-tools.mjs +5365 -380
  27. package/dist/behaviors/autocomplete.d.mts +53 -0
  28. package/dist/behaviors/autocomplete.mjs +1601 -0
  29. package/dist/behaviors/back-top.d.mts +1 -1
  30. package/dist/behaviors/back-top.mjs +952 -14
  31. package/dist/behaviors/carousel.d.mts +1 -1
  32. package/dist/behaviors/carousel.mjs +914 -12
  33. package/dist/behaviors/cascader.d.mts +48 -0
  34. package/dist/behaviors/cascader.mjs +1867 -0
  35. package/dist/behaviors/charts.d.mts +72 -8
  36. package/dist/behaviors/charts.mjs +1953 -272
  37. package/dist/behaviors/code-block.d.mts +36 -0
  38. package/dist/behaviors/code-block.mjs +1619 -0
  39. package/dist/behaviors/command-palette.d.mts +9 -6
  40. package/dist/behaviors/command-palette.mjs +164 -62
  41. package/dist/behaviors/context-menu.d.mts +10 -9
  42. package/dist/behaviors/context-menu.mjs +1113 -44
  43. package/dist/behaviors/controls.d.mts +21 -21
  44. package/dist/behaviors/controls.mjs +1024 -134
  45. package/dist/behaviors/copy.d.mts +21 -2
  46. package/dist/behaviors/copy.mjs +1207 -42
  47. package/dist/behaviors/datatable.d.mts +55 -5
  48. package/dist/behaviors/datatable.mjs +2033 -212
  49. package/dist/behaviors/date-picker.d.mts +0 -1
  50. package/dist/behaviors/date-picker.mjs +1341 -293
  51. package/dist/behaviors/design.d.mts +54 -0
  52. package/dist/behaviors/design.mjs +109 -0
  53. package/dist/behaviors/dropdown.d.mts +5 -6
  54. package/dist/behaviors/dropdown.mjs +262 -110
  55. package/dist/behaviors/events.d.mts +127 -10
  56. package/dist/behaviors/events.mjs +58 -3
  57. package/dist/behaviors/feedback.d.mts +30 -0
  58. package/dist/behaviors/feedback.mjs +296 -0
  59. package/dist/behaviors/focus.d.mts +8 -0
  60. package/dist/behaviors/focus.mjs +24 -0
  61. package/dist/behaviors/form-validate.d.mts +111 -0
  62. package/dist/behaviors/form-validate.mjs +1746 -0
  63. package/dist/behaviors/i18n.d.mts +790 -0
  64. package/dist/behaviors/i18n.mjs +1713 -0
  65. package/dist/behaviors/icons.d.mts +93 -0
  66. package/dist/behaviors/icons.mjs +113 -0
  67. package/dist/behaviors/input.d.mts +9 -1
  68. package/dist/behaviors/input.mjs +1059 -60
  69. package/dist/behaviors/kb-access.d.mts +3 -3
  70. package/dist/behaviors/kb-access.mjs +2135 -239
  71. package/dist/behaviors/kb-acl.d.mts +8 -8
  72. package/dist/behaviors/kb-acl.mjs +1120 -179
  73. package/dist/behaviors/kb-answer.d.mts +2 -2
  74. package/dist/behaviors/kb-answer.mjs +2120 -435
  75. package/dist/behaviors/kb-audit.d.mts +3 -3
  76. package/dist/behaviors/kb-audit.mjs +1077 -154
  77. package/dist/behaviors/kb-canvas.d.mts +3 -3
  78. package/dist/behaviors/kb-canvas.mjs +1101 -177
  79. package/dist/behaviors/kb-chain.d.mts +2 -2
  80. package/dist/behaviors/kb-chain.mjs +1023 -100
  81. package/dist/behaviors/kb-checkpoint.d.mts +3 -3
  82. package/dist/behaviors/kb-checkpoint.mjs +1320 -169
  83. package/dist/behaviors/kb-chunks.d.mts +2 -2
  84. package/dist/behaviors/kb-chunks.mjs +1153 -213
  85. package/dist/behaviors/kb-citation.d.mts +3 -3
  86. package/dist/behaviors/kb-citation.mjs +1221 -185
  87. package/dist/behaviors/kb-clarify.d.mts +2 -2
  88. package/dist/behaviors/kb-clarify.mjs +1059 -130
  89. package/dist/behaviors/kb-conflict.d.mts +2 -2
  90. package/dist/behaviors/kb-conflict.mjs +1042 -119
  91. package/dist/behaviors/kb-connector.d.mts +2 -2
  92. package/dist/behaviors/kb-connector.mjs +1105 -176
  93. package/dist/behaviors/kb-core.d.mts +7 -2
  94. package/dist/behaviors/kb-core.mjs +1078 -162
  95. package/dist/behaviors/kb-eval.d.mts +2 -2
  96. package/dist/behaviors/kb-eval.mjs +1977 -144
  97. package/dist/behaviors/kb-explain.d.mts +3 -3
  98. package/dist/behaviors/kb-explain.mjs +1037 -104
  99. package/dist/behaviors/kb-filter.d.mts +2 -2
  100. package/dist/behaviors/kb-filter.mjs +2014 -178
  101. package/dist/behaviors/kb-gap.d.mts +3 -3
  102. package/dist/behaviors/kb-gap.mjs +1044 -121
  103. package/dist/behaviors/kb-hittest.d.mts +3 -3
  104. package/dist/behaviors/kb-hittest.mjs +1095 -151
  105. package/dist/behaviors/kb-metadata.mjs +1058 -130
  106. package/dist/behaviors/kb-passage.d.mts +4 -4
  107. package/dist/behaviors/kb-passage.mjs +1102 -161
  108. package/dist/behaviors/kb-pipeline.d.mts +4 -4
  109. package/dist/behaviors/kb-pipeline.mjs +1083 -162
  110. package/dist/behaviors/kb-qa.mjs +1089 -160
  111. package/dist/behaviors/kb-rerank.d.mts +2 -2
  112. package/dist/behaviors/kb-rerank.mjs +1048 -114
  113. package/dist/behaviors/kb-retrieval.d.mts +2 -2
  114. package/dist/behaviors/kb-retrieval.mjs +2079 -226
  115. package/dist/behaviors/kb-review.d.mts +2 -2
  116. package/dist/behaviors/kb-review.mjs +1996 -159
  117. package/dist/behaviors/kb-sandbox.d.mts +3 -3
  118. package/dist/behaviors/kb-sandbox.mjs +1033 -105
  119. package/dist/behaviors/kb-segment.d.mts +2 -2
  120. package/dist/behaviors/kb-segment.mjs +1112 -179
  121. package/dist/behaviors/kb-select.d.mts +24 -0
  122. package/dist/behaviors/kb-select.mjs +1995 -0
  123. package/dist/behaviors/kb-sources.d.mts +3 -3
  124. package/dist/behaviors/kb-sources.mjs +1085 -170
  125. package/dist/behaviors/kb-sql.d.mts +3 -3
  126. package/dist/behaviors/kb-sql.mjs +1144 -226
  127. package/dist/behaviors/kb-trace.d.mts +3 -3
  128. package/dist/behaviors/kb-trace.mjs +1051 -131
  129. package/dist/behaviors/kb-visibility.d.mts +2 -2
  130. package/dist/behaviors/kb-visibility.mjs +1087 -158
  131. package/dist/behaviors/kb-who-can.d.mts +2 -2
  132. package/dist/behaviors/kb-who-can.mjs +1980 -137
  133. package/dist/behaviors/mentions.d.mts +93 -0
  134. package/dist/behaviors/mentions.mjs +2153 -0
  135. package/dist/behaviors/modal.d.mts +4 -3
  136. package/dist/behaviors/modal.mjs +1056 -33
  137. package/dist/behaviors/nav.d.mts +1 -1
  138. package/dist/behaviors/nav.mjs +6 -6
  139. package/dist/behaviors/notification.d.mts +16 -8
  140. package/dist/behaviors/notification.mjs +1629 -268
  141. package/dist/behaviors/panel.d.mts +4 -0
  142. package/dist/behaviors/panel.mjs +995 -0
  143. package/dist/behaviors/popover.d.mts +28 -5
  144. package/dist/behaviors/popover.mjs +225 -24
  145. package/dist/behaviors/scroll-area.d.mts +17 -0
  146. package/dist/behaviors/scroll-area.mjs +59 -0
  147. package/dist/behaviors/select.d.mts +5 -2
  148. package/dist/behaviors/select.mjs +1416 -117
  149. package/dist/behaviors/sidebar.d.mts +1 -1
  150. package/dist/behaviors/sidebar.mjs +13 -13
  151. package/dist/behaviors/slider.d.mts +1 -1
  152. package/dist/behaviors/slider.mjs +12 -12
  153. package/dist/behaviors/split-pane.d.mts +1 -1
  154. package/dist/behaviors/split-pane.mjs +9 -7
  155. package/dist/behaviors/suggestions.d.mts +27 -0
  156. package/dist/behaviors/suggestions.mjs +1090 -0
  157. package/dist/behaviors/svg-parse.d.mts +14 -0
  158. package/dist/behaviors/svg-parse.mjs +37 -0
  159. package/dist/behaviors/tabs.d.mts +2 -2
  160. package/dist/behaviors/tabs.mjs +35 -25
  161. package/dist/behaviors/tag-input.d.mts +23 -5
  162. package/dist/behaviors/tag-input.mjs +1360 -104
  163. package/dist/behaviors/theme-switcher.d.mts +24 -0
  164. package/dist/behaviors/theme-switcher.mjs +1996 -0
  165. package/dist/behaviors/theme.d.mts +15 -8
  166. package/dist/behaviors/theme.mjs +406 -30
  167. package/dist/behaviors/toast.d.mts +24 -25
  168. package/dist/behaviors/toast.mjs +1267 -88
  169. package/dist/behaviors/tooltip.d.mts +4 -0
  170. package/dist/behaviors/tooltip.mjs +378 -0
  171. package/dist/behaviors/tree-select.d.mts +69 -0
  172. package/dist/behaviors/tree-select.mjs +1921 -0
  173. package/dist/behaviors/tree.d.mts +1 -1
  174. package/dist/behaviors/tree.mjs +18 -18
  175. package/dist/behaviors/upload.d.mts +3 -2
  176. package/dist/behaviors/upload.mjs +1077 -66
  177. package/dist/behaviors/url-safety.d.mts +8 -0
  178. package/dist/behaviors/url-safety.mjs +11 -0
  179. package/dist/cli.mjs +5 -6
  180. package/dist/components/accordion.d.mts +2 -0
  181. package/dist/components/ai-branch.d.mts +2 -0
  182. package/dist/components/ai-chat.css +682 -582
  183. package/dist/components/ai-chat.d.mts +2 -0
  184. package/dist/components/ai-composer.d.mts +2 -0
  185. package/dist/components/ai-context.d.mts +2 -0
  186. package/dist/components/ai-context.mjs +1 -0
  187. package/dist/components/ai-diff.css +153 -132
  188. package/dist/components/ai-diff.d.mts +2 -0
  189. package/dist/components/ai-feedback.d.mts +2 -0
  190. package/dist/components/ai-files.d.mts +2 -0
  191. package/dist/components/ai-message.d.mts +2 -0
  192. package/dist/components/ai-panel.css +353 -343
  193. package/dist/components/ai-reasoning.d.mts +2 -0
  194. package/dist/components/ai-subagent.d.mts +2 -0
  195. package/dist/components/ai-subagent.mjs +1 -0
  196. package/dist/components/ai-threads.d.mts +2 -0
  197. package/dist/components/ai-todo.d.mts +2 -0
  198. package/dist/components/ai-todo.mjs +1 -0
  199. package/dist/components/ai-tool-call.d.mts +2 -0
  200. package/dist/components/ai-tool-call.mjs +1 -0
  201. package/dist/components/ai-tool.css +397 -242
  202. package/dist/components/ai-usage.d.mts +2 -0
  203. package/dist/components/alert.d.mts +2 -0
  204. package/dist/components/autocomplete.css +61 -0
  205. package/dist/components/autocomplete.d.mts +2 -0
  206. package/dist/components/autocomplete.mjs +3 -0
  207. package/dist/components/avatar.d.mts +2 -0
  208. package/dist/components/back-top.css +74 -40
  209. package/dist/components/back-top.d.mts +2 -0
  210. package/dist/components/badge.css +44 -41
  211. package/dist/components/badge.d.mts +2 -0
  212. package/dist/components/breadcrumb.css +85 -46
  213. package/dist/components/breadcrumb.d.mts +2 -0
  214. package/dist/components/btn.css +105 -94
  215. package/dist/components/btn.d.mts +2 -0
  216. package/dist/components/card.css +124 -113
  217. package/dist/components/card.d.mts +2 -0
  218. package/dist/components/carousel.d.mts +2 -0
  219. package/dist/components/cascader.css +332 -0
  220. package/dist/components/cascader.d.mts +2 -0
  221. package/dist/components/cascader.mjs +3 -0
  222. package/dist/components/chart-area.css +54 -2
  223. package/dist/components/chart-area.d.mts +2 -0
  224. package/dist/components/chart-bar.css +147 -38
  225. package/dist/components/chart-bar.d.mts +2 -0
  226. package/dist/components/chart-calendar.d.mts +2 -0
  227. package/dist/components/chart-gauge.css +36 -13
  228. package/dist/components/chart-gauge.d.mts +2 -0
  229. package/dist/components/chart-graph.css +35 -20
  230. package/dist/components/chart-graph.d.mts +2 -0
  231. package/dist/components/chart-heatmap.css +67 -39
  232. package/dist/components/chart-heatmap.d.mts +2 -0
  233. package/dist/components/chart-line.css +62 -3
  234. package/dist/components/chart-line.d.mts +2 -0
  235. package/dist/components/chart-map.d.mts +2 -0
  236. package/dist/components/chart-pie.css +38 -6
  237. package/dist/components/chart-pie.d.mts +2 -0
  238. package/dist/components/chart-radar.css +57 -5
  239. package/dist/components/chart-radar.d.mts +2 -0
  240. package/dist/components/chart-scatter.css +47 -7
  241. package/dist/components/chart-scatter.d.mts +2 -0
  242. package/dist/components/chart-sparkline.css +25 -2
  243. package/dist/components/chart-sparkline.d.mts +2 -0
  244. package/dist/components/chart-stack.css +27 -13
  245. package/dist/components/chart-stack.d.mts +2 -0
  246. package/dist/components/charts.css +220 -84
  247. package/dist/components/charts.d.mts +2 -0
  248. package/dist/components/code-block.css +420 -0
  249. package/dist/components/code-block.d.mts +2 -0
  250. package/dist/components/code-block.mjs +4 -0
  251. package/dist/components/command-palette.css +150 -122
  252. package/dist/components/command-palette.d.mts +2 -0
  253. package/dist/components/content.css +274 -263
  254. package/dist/components/context-menu.d.mts +2 -0
  255. package/dist/components/copy.css +73 -45
  256. package/dist/components/copy.d.mts +2 -0
  257. package/dist/components/datatable.css +457 -202
  258. package/dist/components/datatable.d.mts +2 -0
  259. package/dist/components/date-picker.css +136 -105
  260. package/dist/components/date-picker.d.mts +2 -0
  261. package/dist/components/desc.d.mts +2 -0
  262. package/dist/components/dropdown.d.mts +2 -0
  263. package/dist/components/empty.css +72 -69
  264. package/dist/components/empty.d.mts +2 -0
  265. package/dist/components/feedback.css +211 -191
  266. package/dist/components/form-validate.css +134 -0
  267. package/dist/components/form-validate.d.mts +2 -0
  268. package/dist/components/form-validate.mjs +3 -0
  269. package/dist/components/form.css +157 -131
  270. package/dist/components/form.d.mts +2 -0
  271. package/dist/components/icon.css +113 -0
  272. package/dist/components/icon.d.mts +2 -0
  273. package/dist/components/icon.mjs +3 -0
  274. package/dist/components/input.css +163 -108
  275. package/dist/components/input.d.mts +2 -0
  276. package/dist/components/kb-access.d.mts +2 -0
  277. package/dist/components/kb-acl.d.mts +2 -0
  278. package/dist/components/kb-agent.css +300 -206
  279. package/dist/components/kb-answer.d.mts +2 -0
  280. package/dist/components/kb-audit.d.mts +2 -0
  281. package/dist/components/kb-canvas.d.mts +2 -0
  282. package/dist/components/kb-chain.d.mts +2 -0
  283. package/dist/components/kb-checkpoint.d.mts +2 -0
  284. package/dist/components/kb-chunks.d.mts +2 -0
  285. package/dist/components/kb-citation.d.mts +2 -0
  286. package/dist/components/kb-clarify.d.mts +2 -0
  287. package/dist/components/kb-conflict.d.mts +2 -0
  288. package/dist/components/kb-connector.d.mts +2 -0
  289. package/dist/components/kb-data.css +431 -315
  290. package/dist/components/kb-eval.d.mts +2 -0
  291. package/dist/components/kb-explain.d.mts +2 -0
  292. package/dist/components/kb-filter.d.mts +2 -0
  293. package/dist/components/kb-gap.d.mts +2 -0
  294. package/dist/components/kb-ground.css +333 -229
  295. package/dist/components/kb-hittest.d.mts +2 -0
  296. package/dist/components/kb-ingest.css +613 -434
  297. package/dist/components/kb-metadata.d.mts +2 -0
  298. package/dist/components/kb-ops.css +422 -302
  299. package/dist/components/kb-passage.d.mts +2 -0
  300. package/dist/components/kb-perm.css +374 -314
  301. package/dist/components/kb-pipeline.d.mts +2 -0
  302. package/dist/components/kb-qa.d.mts +2 -0
  303. package/dist/components/kb-rerank.d.mts +2 -0
  304. package/dist/components/kb-retrieval.d.mts +2 -0
  305. package/dist/components/kb-review.d.mts +2 -0
  306. package/dist/components/kb-sandbox.d.mts +2 -0
  307. package/dist/components/kb-search.css +653 -459
  308. package/dist/components/kb-segment.d.mts +2 -0
  309. package/dist/components/kb-sources.d.mts +2 -0
  310. package/dist/components/kb-sql.d.mts +2 -0
  311. package/dist/components/kb-trace.d.mts +2 -0
  312. package/dist/components/kb-visibility.d.mts +2 -0
  313. package/dist/components/kb-who-can.d.mts +2 -0
  314. package/dist/components/kb.css +170 -135
  315. package/dist/components/kb.d.mts +2 -0
  316. package/dist/components/kbd.d.mts +2 -0
  317. package/dist/components/layout.css +86 -83
  318. package/dist/components/layout.d.mts +2 -0
  319. package/dist/components/list.d.mts +2 -0
  320. package/dist/components/material-chinese.css +83 -0
  321. package/dist/components/material-soviet.css +86 -0
  322. package/dist/components/material.css +318 -0
  323. package/dist/components/media-card.d.mts +2 -0
  324. package/dist/components/media.css +225 -176
  325. package/dist/components/mentions.css +190 -0
  326. package/dist/components/mentions.d.mts +2 -0
  327. package/dist/components/mentions.mjs +3 -0
  328. package/dist/components/menu.css +121 -109
  329. package/dist/components/modal.css +116 -118
  330. package/dist/components/modal.d.mts +2 -0
  331. package/dist/components/nav.css +136 -129
  332. package/dist/components/nav.d.mts +2 -0
  333. package/dist/components/notification.css +247 -177
  334. package/dist/components/notification.d.mts +2 -0
  335. package/dist/components/pagination.css +62 -57
  336. package/dist/components/pagination.d.mts +2 -0
  337. package/dist/components/panel.css +70 -68
  338. package/dist/components/panel.d.mts +2 -0
  339. package/dist/components/panel.mjs +1 -0
  340. package/dist/components/pill.css +83 -72
  341. package/dist/components/pill.d.mts +2 -0
  342. package/dist/components/popover.css +80 -57
  343. package/dist/components/popover.d.mts +2 -0
  344. package/dist/components/progress.d.mts +2 -0
  345. package/dist/components/rating.d.mts +2 -0
  346. package/dist/components/result.d.mts +2 -0
  347. package/dist/components/scroll-area.css +29 -54
  348. package/dist/components/scroll-area.d.mts +2 -0
  349. package/dist/components/scroll-area.mjs +1 -0
  350. package/dist/components/segmented.css +167 -146
  351. package/dist/components/segmented.d.mts +2 -0
  352. package/dist/components/select.css +250 -191
  353. package/dist/components/select.d.mts +2 -0
  354. package/dist/components/sidebar.css +157 -143
  355. package/dist/components/sidebar.d.mts +2 -0
  356. package/dist/components/skeleton.d.mts +2 -0
  357. package/dist/components/slider.css +135 -128
  358. package/dist/components/slider.d.mts +2 -0
  359. package/dist/components/spinner.d.mts +2 -0
  360. package/dist/components/split-pane.css +120 -108
  361. package/dist/components/split-pane.d.mts +2 -0
  362. package/dist/components/stat.css +116 -109
  363. package/dist/components/stat.d.mts +2 -0
  364. package/dist/components/steps.css +114 -108
  365. package/dist/components/steps.d.mts +2 -0
  366. package/dist/components/switch.css +192 -149
  367. package/dist/components/switch.d.mts +2 -0
  368. package/dist/components/table.css +158 -112
  369. package/dist/components/table.d.mts +2 -0
  370. package/dist/components/tabs.css +143 -116
  371. package/dist/components/tabs.d.mts +2 -0
  372. package/dist/components/tag-input.css +52 -133
  373. package/dist/components/tag-input.d.mts +2 -0
  374. package/dist/components/tag.css +90 -72
  375. package/dist/components/tag.d.mts +2 -0
  376. package/dist/components/theme-switcher.css +105 -0
  377. package/dist/components/theme-switcher.d.mts +2 -0
  378. package/dist/components/theme-switcher.mjs +3 -0
  379. package/dist/components/timeline.d.mts +2 -0
  380. package/dist/components/toast.css +115 -97
  381. package/dist/components/toast.d.mts +2 -0
  382. package/dist/components/toolbar.css +47 -43
  383. package/dist/components/toolbar.d.mts +2 -0
  384. package/dist/components/tooltip.css +103 -43
  385. package/dist/components/tooltip.d.mts +2 -0
  386. package/dist/components/tooltip.mjs +1 -0
  387. package/dist/components/tree-select.css +439 -0
  388. package/dist/components/tree-select.d.mts +2 -0
  389. package/dist/components/tree-select.mjs +3 -0
  390. package/dist/components/tree.d.mts +2 -0
  391. package/dist/components/upload.css +138 -97
  392. package/dist/components/upload.d.mts +2 -0
  393. package/dist/fonts/LICENSES/ark-pixel/OFL.txt +96 -0
  394. package/dist/fonts/LICENSES/cubic-11/OFL.txt +108 -0
  395. package/dist/fonts/LICENSES/galmuri/LICENSE.txt +93 -0
  396. package/dist/fonts/OFL.txt +96 -0
  397. package/dist/fonts/README.md +14 -0
  398. package/dist/fonts/fusion-pixel-12px-zh-hans.woff2 +0 -0
  399. package/dist/index.d.mts +85 -70
  400. package/dist/index.mjs +17330 -5773
  401. package/dist/react.d.mts +91 -0
  402. package/dist/react.mjs +8307 -0
  403. package/dist/registry.json +918 -70
  404. package/dist/tokens/chinese.css +44 -0
  405. package/dist/tokens/colors.css +371 -1222
  406. package/dist/tokens/design.css +209 -0
  407. package/dist/tokens/dtcg.json +15926 -0
  408. package/dist/tokens/figma.variables.json +10779 -0
  409. package/dist/tokens/icon-masks.css +78 -0
  410. package/dist/tokens/pixel.css +53 -0
  411. package/dist/tokens/scrollbars.css +40 -0
  412. package/dist/tokens/soviet.css +44 -0
  413. package/dist/tokens/style-profiles.css +36 -547
  414. package/dist/tokens/themes.json +308 -0
  415. package/dist/tokens/tokens-studio.json +11648 -0
  416. package/dist/tokens/typography.css +21 -18
  417. package/dist/tokens.css +1783 -1806
  418. package/dist/ui.css +14796 -10750
  419. package/dist/vue.d.mts +344 -0
  420. package/dist/vue.mjs +7876 -0
  421. package/docs/spec/ai-input-experience.md +75 -0
  422. package/docs/spec/ai-native.md +238 -147
  423. package/docs/spec/design-philosophy.md +189 -0
  424. package/docs/spec/design-primitives.md +196 -0
  425. package/docs/spec/kb-family.md +147 -115
  426. package/docs/spec/scrollbars.md +46 -0
  427. package/package.json +56 -8
  428. package/dist/retro-effects.css +0 -255
  429. package/dist/tokens/retro-effects.css +0 -255
  430. package/docs/research/2026-10-03-ai-kb-components.md +0 -392
  431. package/docs/research/2026-10-03-kb-permissions.md +0 -992
@@ -1,142 +1,192 @@
1
+ @layer icen.components {
1
2
  /*
2
3
  * @icen.ai/ui — Component: datatable(数据表格,与 behaviors/datatable 配套)
3
4
  *
4
5
  * 结构(全部由 createTable 渲染,div + ARIA role 网格):
5
- * .datatable [--striped|--virtual]
6
- * ├─ .dt-toolbar > .dt-search > svg + input.dt-search-input
7
- * ├─ .dt-scroll > .dt-canvas[role=grid]
8
- * │ ├─ .dt-head > .dt-row--head > .dt-cell--head(.is-sortable / .dt-filter-btn / .dt-filter-panel)
9
- * │ └─ .dt-body > .dt-row[.is-selected] > .dt-cell;.dt-expand-row;.dt-empty;.dt-skeleton-row
10
- * └─ .dt-foot > .dt-stat(含 .dt-clear-sel)+ .dt-pager(.dt-page-size / .dt-page-btn / .dt-page-dots)
6
+ * .icen-datatable [--striped|--virtual|--compact|--frozen|--reorderable]
7
+ * ├─ .icen-dt-toolbar > .icen-dt-search > svg + input.icen-dt-search-input
8
+ * ├─ .icen-dt-scroll > .icen-dt-canvas[role=grid]
9
+ * │ ├─ .icen-dt-head > .icen-dt-row--head > .icen-dt-cell--head(.is-sortable / .icen-dt-sort[.is-active] /
10
+ * │ │ .icen-dt-sort-badge 多列排序优先级 / .icen-dt-filter-btn / .icen-dt-resize / .is-drag-source)
11
+ * │ ├─ .icen-dt-body > .icen-dt-row[.is-selected][data-icen-row][data-icen-key]
12
+ * │ │ > .icen-dt-cell[data-icen-col][data-icen-col-key][tabindex](.icen-dt-cell--frozen[left 偏移内联] /
13
+ * │ │ .icen-dt-cell--frozen-right[right 偏移内联] / .is-editable / .is-editing > .icen-dt-editor[.is-invalid]);
14
+ * │ │ .icen-dt-row--group[.is-collapsed] > .icen-dt-cell--group(grid-column 1/-1)
15
+ * │ │ > .icen-dt-group-toggle + .icen-dt-group-label + .icen-dt-group-count + .icen-dt-group-aggs > .icen-dt-group-agg;
16
+ * │ │ .icen-dt-expand-row;.icen-dt-empty;.icen-dt-skeleton-row
17
+ * │ └─ .icen-dt-row--summary[sticky bottom 汇总行] > .icen-dt-cell--summary
18
+ * └─ .icen-dt-foot > .icen-dt-stat(含 .icen-dt-clear-sel)+ .icen-dt-pager(.icen-dt-page-size / .icen-dt-page-btn / .icen-dt-page-dots)
11
19
  *
20
+ * 拖拽浮层(portal 到 body,behavior 定位):.icen-dt-col-ghost(列重排影子)/ .icen-dt-col-indicator(插入指示线)。
12
21
  * 行布局 = grid,grid-template-columns 由 behavior 按列宽计算;行内容溢出省略号。
13
22
  * 右键菜单面板样式在 menu.css(kit 入口自动带上)。
14
23
  */
15
24
 
16
- .datatable {
17
- border: 1px solid var(--token-line-soft);
18
- border-radius: var(--radius-lg);
19
- background: var(--token-surface);
25
+ .icen-datatable {
26
+ border: 1px solid var(--icen-token-separator-soft);
27
+ border-radius: var(--icen-control-radius-lg);
28
+ background: var(--icen-token-surface);
20
29
  overflow: hidden;
21
- font-size: var(--density-font-size-md);
30
+ font-size: var(--icen-font-size-control);
22
31
  }
23
32
 
24
33
  /* ── 工具栏(搜索) ── */
25
- .dt-toolbar {
34
+ .icen-dt-toolbar {
26
35
  display: flex;
27
36
  align-items: center;
28
- gap: var(--density-space-sm);
29
- padding: 10px 14px;
30
- border-bottom: 1px solid var(--token-line-soft);
37
+ gap: var(--icen-density-space-sm);
38
+ min-block-size: 44px;
39
+ padding: 6px 10px;
40
+ border-bottom: 1px solid var(--icen-token-separator-soft);
41
+ background: var(--icen-token-surface-chrome);
31
42
  }
32
- .dt-search {
43
+ .icen-dt-search {
33
44
  display: flex;
34
45
  align-items: center;
35
- gap: 8px;
36
- height: 32px;
37
- width: 260px;
46
+ gap: 7px;
47
+ height: 30px;
48
+ width: 240px;
38
49
  max-width: 100%;
39
- padding: 0 10px;
40
- color: var(--token-text-faint);
41
- background: var(--token-control);
42
- border: 1px solid var(--token-outline-soft);
43
- border-radius: var(--radius-md);
44
- box-shadow: var(--token-shadow-inset);
50
+ padding: 0 var(--icen-field-padding-inline-sm);
51
+ color: var(--icen-token-text-muted);
52
+ background: var(--icen-token-control);
53
+ border: 1px solid var(--icen-token-control-border);
54
+ border-radius: var(--icen-control-radius);
55
+ box-shadow: var(--icen-token-shadow-field);
45
56
  transition: border-color var(--icen-tx-fast), box-shadow var(--icen-tx-fast);
46
57
  }
47
- .dt-search:focus-within {
48
- border-color: var(--icen-control-focus-border, var(--token-accent));
58
+ .icen-dt-search:focus-within {
59
+ border-color: var(--icen-control-focus-border, var(--icen-token-accent));
49
60
  box-shadow: var(--icen-control-focus-shadow);
50
61
  }
51
- .dt-search-input {
62
+ .icen-dt-search-input {
52
63
  flex: 1;
53
64
  min-width: 0;
54
65
  border: 0;
55
66
  outline: none;
56
67
  background: transparent;
57
- color: var(--token-text);
68
+ color: var(--icen-token-text);
58
69
  font: inherit;
59
- font-size: var(--density-font-size-sm);
70
+ font-size: var(--icen-density-font-size-sm);
60
71
  }
61
- .dt-search-input::placeholder { color: var(--token-text-faint); }
62
- .dt-search-input::-webkit-search-cancel-button { -webkit-appearance: none; }
72
+ .icen-dt-search-input::placeholder { color: var(--icen-token-text-faint); }
73
+ .icen-dt-search-input::-webkit-search-cancel-button { -webkit-appearance: none; }
63
74
 
64
75
  /* ── 滚动容器与画布 ── */
65
- .dt-scroll { overflow: auto; }
66
- .datatable--virtual .dt-scroll { overscroll-behavior: contain; }
67
- .dt-canvas { min-width: 560px; }
76
+ .icen-dt-scroll { overflow: auto; }
77
+ .icen-datatable--virtual .icen-dt-scroll { overscroll-behavior: contain; }
78
+ .icen-dt-canvas { min-width: 560px; }
68
79
 
69
80
  /* ── 行 ── */
70
- .dt-row {
81
+ .icen-dt-row {
71
82
  display: grid;
72
83
  align-items: center;
73
- border-bottom: 1px solid var(--token-line-soft);
84
+ border-bottom: 1px solid var(--icen-token-separator-soft);
74
85
  transition: background var(--icen-tx-fast);
75
86
  }
76
- .dt-body .dt-row:last-child { border-bottom: 0; }
77
- .dt-body .dt-row:hover { background: var(--token-fill-1); }
78
- .dt-row.is-selected { background: var(--token-accent-subtle); }
79
- .dt-row.is-selected:hover { background: color-mix(in srgb, var(--token-accent-subtle) 82%, var(--token-fill-1)); }
80
- .dt-row.is-clickable { cursor: pointer; }
81
- .datatable--striped .dt-body .dt-row:nth-child(even):not(.is-selected) {
82
- background: color-mix(in srgb, var(--token-fill-1) 55%, transparent);
83
- }
84
- .datatable--striped .dt-body .dt-row:nth-child(even):not(.is-selected):hover {
85
- background: var(--token-fill-1);
87
+ .icen-dt-body .icen-dt-row:last-child { border-bottom: 0; }
88
+ .icen-dt-body .icen-dt-row:hover { background: var(--icen-token-fill-hover); }
89
+
90
+ /* 行内次要动作(columns.render 产出 .icen-dt-actions):隐式待命,行悬停/聚焦显现;
91
+ 触屏常显;按钮本体 26px 视觉 + 触屏隐形 44px 命中 */
92
+ .icen-dt-actions { display: inline-flex; gap: 2px; }
93
+ .icen-dt-action {
94
+ display: inline-flex;
95
+ align-items: center;
96
+ justify-content: center;
97
+ inline-size: 26px;
98
+ block-size: 26px;
99
+ padding: 0;
100
+ border: 0;
101
+ border-radius: var(--icen-radius-sm);
102
+ background: transparent;
103
+ color: var(--icen-token-text-faint);
104
+ cursor: pointer;
105
+ position: relative;
106
+ transition:
107
+ opacity var(--icen-tx-fast),
108
+ color var(--icen-tx-fast),
109
+ background-color var(--icen-tx-fast);
110
+ }
111
+ .icen-dt-action:hover { color: var(--icen-token-text); background: var(--icen-token-fill-2); }
112
+ .icen-dt-action:focus-visible { outline: none; box-shadow: var(--icen-ring); opacity: 1; }
113
+ @media (hover: hover) and (pointer: fine) {
114
+ .icen-dt-actions { opacity: 0; }
115
+ .icen-dt-row:hover .icen-dt-actions,
116
+ .icen-dt-row:focus-within .icen-dt-actions { opacity: 1; }
117
+ }
118
+ @media (pointer: coarse) {
119
+ /* 隐形命中扩张用透明 border + 负 margin(background-clip 保持视觉不变);
120
+ 不用 ::after——动作钮可同时带 data-icen-tooltip,伪元素只有一颗 */
121
+ .icen-dt-action {
122
+ border: 9px solid transparent;
123
+ background-clip: padding-box;
124
+ margin: -9px;
125
+ }
126
+ }
127
+ .icen-dt-row.is-selected { background: var(--icen-token-fill-selected); }
128
+ .icen-dt-row.is-selected:hover { background: color-mix(in srgb, var(--icen-token-fill-selected) 82%, var(--icen-token-fill-hover)); }
129
+ .icen-dt-row.is-clickable { cursor: pointer; }
130
+ .icen-datatable--striped .icen-dt-body .icen-dt-row:nth-child(even):not(.is-selected) {
131
+ background: color-mix(in srgb, var(--icen-token-fill-hover) 55%, transparent);
132
+ }
133
+ .icen-datatable--striped .icen-dt-body .icen-dt-row:nth-child(even):not(.is-selected):hover {
134
+ background: var(--icen-token-fill-hover);
86
135
  }
87
136
 
88
- .dt-cell {
89
- padding: 0 12px;
137
+ .icen-dt-cell {
138
+ padding: 0 10px;
90
139
  min-width: 0;
91
140
  overflow: hidden;
92
141
  text-overflow: ellipsis;
93
142
  white-space: nowrap;
94
- color: var(--token-text);
143
+ color: var(--icen-token-text);
95
144
  display: flex;
96
145
  align-items: center;
97
- gap: 8px;
98
- min-height: 44px;
146
+ gap: 6px;
147
+ min-height: 32px;
99
148
  }
100
- .datatable--virtual .dt-cell { min-height: 0; height: 100%; }
101
- .dt-cell[data-align='center'] { justify-content: center; text-align: center; }
102
- .dt-cell[data-align='right'] { justify-content: flex-end; text-align: right; }
103
- .dt-cell--check, .dt-cell--expand { justify-content: center; padding: 0 4px; }
149
+ .icen-datatable--virtual .icen-dt-cell { min-height: 0; height: 100%; }
150
+ .icen-dt-cell[data-icen-align='center'] { justify-content: center; text-align: center; }
151
+ .icen-dt-cell[data-icen-align='right'] { justify-content: flex-end; text-align: right; /* guard:allow-physical data-icen-align='right' 是物理对齐属性契约(数字/操作列),RTL 语义不变 */ }
152
+ .icen-dt-cell--check, .icen-dt-cell--expand { justify-content: center; padding: 0 4px; }
104
153
 
105
154
  /* ── 表头 ── */
106
- .dt-head { border-bottom: 1px solid var(--token-line-soft); }
107
- .dt-row--head {
108
- background: var(--token-bg-soft);
155
+ .icen-dt-head { border-bottom: 1px solid var(--icen-token-separator); }
156
+ .icen-dt-row--head {
157
+ background: var(--icen-token-surface-chrome);
109
158
  border-bottom: 0;
110
159
  }
111
- .datatable--virtual .dt-row--head {
160
+ .icen-datatable--virtual .icen-dt-row--head {
112
161
  position: sticky;
113
162
  top: 0;
114
- z-index: var(--z-raised);
163
+ z-index: var(--icen-z-raised);
115
164
  }
116
- .dt-cell--head {
165
+ .icen-dt-cell--head {
117
166
  position: relative;
118
- min-height: 40px;
119
- font-size: var(--density-font-size-sm);
167
+ min-height: 30px;
168
+ font-size: var(--icen-font-size-caption);
120
169
  font-weight: 600;
121
- color: var(--token-text-muted);
170
+ letter-spacing: var(--icen-letter-spacing-caption);
171
+ color: var(--icen-token-text-muted);
122
172
  user-select: none;
123
173
  }
124
- .dt-cell--head.is-sortable { cursor: pointer; }
125
- .dt-cell--head.is-sortable:hover { color: var(--token-text); }
126
- .dt-cell--head:focus-visible {
174
+ .icen-dt-cell--head.is-sortable { cursor: pointer; }
175
+ .icen-dt-cell--head.is-sortable:hover { color: var(--icen-token-text); }
176
+ .icen-dt-cell--head:focus-visible {
127
177
  outline: none;
128
178
  box-shadow: var(--icen-ring-inset);
129
179
  }
130
- .dt-head-title { overflow: hidden; text-overflow: ellipsis; }
131
- .dt-sort {
132
- font-size: var(--density-font-size-2xs);
133
- color: var(--token-text-faint);
180
+ .icen-dt-head-title { overflow: hidden; text-overflow: ellipsis; }
181
+ .icen-dt-sort {
182
+ font-size: var(--icen-density-font-size-2xs);
183
+ color: var(--icen-token-text-faint);
134
184
  flex-shrink: 0;
135
185
  }
136
- .dt-sort.is-active { color: var(--token-accent); }
186
+ .icen-dt-sort.is-active { color: var(--icen-token-accent); }
137
187
 
138
188
  /* 筛选按钮与面板 */
139
- .dt-filter-btn {
189
+ .icen-dt-filter-btn {
140
190
  display: inline-flex;
141
191
  align-items: center;
142
192
  justify-content: center;
@@ -144,236 +194,239 @@
144
194
  height: 22px;
145
195
  flex-shrink: 0;
146
196
  border: 0;
147
- border-radius: var(--radius-sm);
197
+ border-radius: var(--icen-radius-sm);
148
198
  background: transparent;
149
- color: var(--token-text-faint);
199
+ color: var(--icen-token-text-faint);
150
200
  cursor: pointer;
151
201
  transition: color var(--icen-tx-fast), background var(--icen-tx-fast);
152
202
  }
153
- .dt-filter-btn:hover { color: var(--token-text); background: var(--token-fill-2); }
154
- .dt-filter-btn.is-open, .dt-filter-btn.is-active { color: var(--token-accent); }
155
- .dt-filter-btn.is-active { background: var(--token-accent-subtle); }
203
+ .icen-dt-filter-btn:hover { color: var(--icen-token-text); background: var(--icen-token-fill-2); }
204
+ .icen-dt-filter-btn.is-open, .icen-dt-filter-btn.is-active { color: var(--icen-token-accent); }
205
+ .icen-dt-filter-btn.is-active { background: var(--icen-token-accent-subtle); }
156
206
 
157
- .dt-filter-panel {
207
+ .icen-dt-filter-panel {
158
208
  position: fixed; /* portal 到 body,由 behavior 按 trigger rect 定位 */
159
- z-index: var(--z-popover);
209
+ z-index: var(--icen-z-popover);
160
210
  min-width: 168px;
161
211
  max-width: 240px;
162
- padding: 4px;
163
- background: var(--token-card-strong);
164
- border: 1px solid var(--token-outline);
165
- border-radius: var(--radius-md);
166
- box-shadow: var(--token-shadow-overlay);
212
+ padding: var(--icen-density-space-xs);
213
+ background: var(--icen-token-surface);
214
+ border: 1px solid var(--icen-token-material-edge);
215
+ border-radius: var(--icen-radius-lg);
216
+ box-shadow: var(--icen-token-material-light), var(--icen-token-shadow-elevated);
167
217
  font-weight: 400;
168
218
  animation: icen-pop-in var(--icen-tx-fast);
169
219
  }
170
- .dt-filter-list {
220
+ .icen-dt-filter-list {
171
221
  max-height: 220px;
172
222
  overflow-y: auto;
173
223
  display: flex;
174
224
  flex-direction: column;
175
225
  }
176
- .dt-filter-item {
226
+ .icen-dt-filter-item {
177
227
  display: flex;
178
228
  align-items: center;
179
- gap: 8px;
180
- padding: 6px 8px;
181
- border-radius: var(--radius-sm);
182
- font-size: var(--density-font-size-sm);
183
- color: var(--token-text);
229
+ gap: 7px;
230
+ min-block-size: var(--icen-control-height-sm);
231
+ padding: 3px var(--icen-density-space-sm);
232
+ border-radius: var(--icen-radius-xs);
233
+ font-size: var(--icen-font-size-control);
234
+ color: var(--icen-token-text);
184
235
  cursor: pointer;
185
236
  }
186
- .dt-filter-item:hover { background: var(--token-fill-1); }
187
- .dt-filter-item > span {
237
+ .icen-dt-filter-item:hover { background: var(--icen-token-fill-hover); }
238
+ .icen-dt-filter-item > span {
188
239
  overflow: hidden;
189
240
  text-overflow: ellipsis;
190
241
  white-space: nowrap;
191
242
  }
192
- .dt-filter-foot {
243
+ .icen-dt-filter-foot {
193
244
  display: flex;
194
245
  justify-content: flex-end;
195
246
  padding: 4px 6px 2px;
196
- border-top: 1px solid var(--token-line-soft);
247
+ border-top: 1px solid var(--icen-token-line-soft);
197
248
  margin-top: 4px;
198
249
  }
199
- .dt-filter-reset {
250
+ .icen-dt-filter-reset {
200
251
  border: 0;
201
252
  background: transparent;
202
- color: var(--token-accent);
253
+ color: var(--icen-token-accent-text); /* 12px 链接字对白底需 AA(裸 accent 4.07:1 不达) */
203
254
  font: inherit;
204
- font-size: var(--density-font-size-xs);
255
+ font-size: var(--icen-density-font-size-xs);
205
256
  cursor: pointer;
206
257
  padding: 2px 4px;
207
258
  }
208
- .dt-filter-reset:hover { text-decoration: underline; }
259
+ .icen-dt-filter-reset:hover { text-decoration: underline; }
209
260
 
210
261
  /* ── 复选框(accent-color 直达 token,三态由 behavior 控制 indeterminate) ── */
211
- .dt-check {
262
+ .icen-dt-check {
212
263
  width: 15px;
213
264
  height: 15px;
214
265
  margin: 0;
215
- accent-color: var(--token-accent);
266
+ accent-color: var(--icen-token-accent);
216
267
  cursor: pointer;
217
268
  flex-shrink: 0;
218
269
  }
219
270
 
220
271
  /* ── 行展开 ── */
221
- .dt-expand-btn {
272
+ .icen-dt-expand-btn {
222
273
  display: inline-flex;
223
274
  align-items: center;
224
275
  justify-content: center;
225
276
  width: 24px;
226
277
  height: 24px;
227
278
  border: 0;
228
- border-radius: var(--radius-sm);
279
+ border-radius: var(--icen-radius-sm);
229
280
  background: transparent;
230
- color: var(--token-text-faint);
281
+ color: var(--icen-token-text-faint);
231
282
  cursor: pointer;
232
283
  transition: transform var(--icen-tx-fast), color var(--icen-tx-fast), background var(--icen-tx-fast);
233
284
  }
234
- .dt-expand-btn:hover { color: var(--token-text); background: var(--token-fill-2); }
235
- .dt-expand-btn[aria-expanded='true'] { transform: rotate(180deg); color: var(--token-accent); }
236
- .dt-expand-row {
237
- padding: 14px 16px;
238
- border-bottom: 1px solid var(--token-line-soft);
239
- background: var(--token-bg-soft);
240
- color: var(--token-text-muted);
241
- font-size: var(--density-font-size-sm);
242
- line-height: 1.7;
285
+ .icen-dt-expand-btn:hover { color: var(--icen-token-text); background: var(--icen-token-fill-2); }
286
+ .icen-dt-expand-btn[aria-expanded='true'] { transform: rotate(180deg); color: var(--icen-token-accent); }
287
+ .icen-dt-expand-row {
288
+ padding: 10px 12px;
289
+ border-bottom: 1px solid var(--icen-token-separator-soft);
290
+ background: var(--icen-token-surface-chrome);
291
+ color: var(--icen-token-text-muted);
292
+ font-size: var(--icen-density-font-size-sm);
293
+ line-height: 1.55;
243
294
  white-space: normal;
244
295
  }
245
296
 
246
297
  /* ── 空态 / 加载骨架 ── */
247
- .dt-empty {
298
+ .icen-dt-empty {
248
299
  padding: 48px 16px;
249
300
  text-align: center;
250
- color: var(--token-text-faint);
251
- font-size: var(--density-font-size-sm);
301
+ color: var(--icen-token-text-faint);
302
+ font-size: var(--icen-density-font-size-sm);
252
303
  }
253
- .dt-skeleton-row {
304
+ .icen-dt-skeleton-row {
254
305
  padding: 14px 16px;
255
- border-bottom: 1px solid var(--token-line-soft);
306
+ border-bottom: 1px solid var(--icen-token-line-soft);
256
307
  }
257
308
 
258
309
  /* ── 底部(统计 + 分页) ── */
259
- .dt-foot {
310
+ .icen-dt-foot {
260
311
  display: flex;
261
312
  align-items: center;
262
- gap: 12px;
313
+ gap: 10px;
263
314
  flex-wrap: wrap;
264
- padding: 10px 14px;
265
- border-top: 1px solid var(--token-line-soft);
266
- }
267
- .dt-foot:empty { display: none; }
268
- .dt-stat {
269
- font-size: var(--density-font-size-xs);
270
- color: var(--token-text-faint);
315
+ padding: 6px 10px;
316
+ border-top: 1px solid var(--icen-token-separator-soft);
317
+ background: var(--icen-token-surface-chrome);
318
+ }
319
+ .icen-dt-foot:empty { display: none; }
320
+ .icen-dt-stat {
321
+ font-size: var(--icen-density-font-size-xs);
322
+ color: var(--icen-token-text-faint);
271
323
  font-variant-numeric: tabular-nums;
272
324
  }
273
- .dt-stat--sel { color: var(--token-accent); display: inline-flex; align-items: center; gap: 6px; }
274
- .dt-clear-sel {
325
+ .icen-dt-stat--sel { color: var(--icen-token-accent-text); display: inline-flex; align-items: center; gap: 6px; }
326
+ .icen-dt-clear-sel {
275
327
  border: 0;
276
328
  background: transparent;
277
- color: var(--token-accent);
329
+ color: var(--icen-token-accent-text); /* 同 filter-reset:小号链接字走可读变体 */
278
330
  font: inherit;
279
- font-size: var(--density-font-size-xs);
331
+ font-size: var(--icen-density-font-size-xs);
280
332
  cursor: pointer;
281
333
  padding: 0;
282
334
  }
283
- .dt-clear-sel:hover { text-decoration: underline; }
335
+ .icen-dt-clear-sel:hover { text-decoration: underline; }
284
336
 
285
- .dt-pager {
286
- margin-left: auto;
337
+ .icen-dt-pager {
338
+ margin-inline-start: auto;
287
339
  display: flex;
288
340
  align-items: center;
289
341
  gap: 4px;
290
342
  }
291
- .dt-page-size {
343
+ .icen-dt-page-size {
292
344
  appearance: none;
293
345
  -webkit-appearance: none;
294
- height: 28px;
295
- padding: 0 8px;
296
- margin-right: 6px;
346
+ height: 26px;
347
+ padding: 0 7px;
348
+ margin-inline-end: 6px;
297
349
  font: inherit;
298
- font-size: var(--density-font-size-xs);
299
- color: var(--token-text-muted);
300
- background: transparent;
301
- border: 1px solid var(--token-line-soft);
302
- border-radius: var(--radius-sm);
350
+ font-size: var(--icen-density-font-size-xs);
351
+ color: var(--icen-token-text-muted);
352
+ background: var(--icen-token-control);
353
+ border: 1px solid var(--icen-token-control-border);
354
+ border-radius: var(--icen-radius-xs);
303
355
  cursor: pointer;
304
356
  }
305
- .dt-page-size:hover { border-color: var(--token-accent); color: var(--token-text); }
306
- .dt-page-btn {
357
+ .icen-dt-page-size:hover { border-color: var(--icen-token-control-border-hover); color: var(--icen-token-text); }
358
+ .icen-dt-page-btn {
307
359
  min-width: 28px;
308
360
  height: 28px;
309
361
  padding: 0 6px;
310
362
  border: 1px solid transparent;
311
- border-radius: var(--radius-sm);
363
+ border-radius: var(--icen-radius-sm);
312
364
  background: transparent;
313
- color: var(--token-text-muted);
365
+ color: var(--icen-token-text-muted);
314
366
  font: inherit;
315
- font-size: var(--density-font-size-xs);
367
+ font-size: var(--icen-density-font-size-xs);
316
368
  font-variant-numeric: tabular-nums;
317
369
  cursor: pointer;
318
370
  transition: color var(--icen-tx-fast), border-color var(--icen-tx-fast), background var(--icen-tx-fast);
319
371
  }
320
- .dt-page-btn:hover:not(:disabled):not(.is-active) {
321
- color: var(--token-text);
322
- border-color: var(--token-line-soft);
372
+ .icen-dt-page-btn:hover:not(:disabled):not(.is-active) {
373
+ color: var(--icen-token-text);
374
+ border-color: var(--icen-token-control-border);
323
375
  }
324
- .dt-page-btn.is-active {
325
- color: var(--token-accent);
326
- border-color: var(--token-accent);
327
- background: var(--token-accent-subtle);
376
+ .icen-dt-page-btn.is-active {
377
+ color: var(--icen-token-text);
378
+ border-color: color-mix(in srgb, var(--icen-token-accent) 24%, transparent);
379
+ background: var(--icen-token-fill-selected);
328
380
  font-weight: 600;
329
381
  }
330
- .dt-page-btn:disabled { opacity: 0.35; cursor: not-allowed; }
331
- .dt-page-dots {
332
- color: var(--token-text-faint);
333
- font-size: var(--density-font-size-xs);
382
+ .icen-dt-page-btn:disabled { opacity: 0.35; cursor: not-allowed; }
383
+ .icen-dt-page-dots {
384
+ color: var(--icen-token-text-faint);
385
+ font-size: var(--icen-density-font-size-xs);
334
386
  padding: 0 2px;
335
387
  }
336
388
 
337
389
  @media (prefers-reduced-motion: reduce) {
338
- .dt-filter-panel { animation: none; }
390
+ .icen-dt-filter-panel { animation: none; }
391
+ .icen-dt-editor.is-invalid { animation: none; }
339
392
  }
340
393
 
341
- /* ── 紧凑密度(32px 行高) ── */
342
- .datatable--compact .dt-cell { min-height: 32px; padding: 0 10px; }
343
- .datatable--compact .dt-cell--head { min-height: 32px; font-size: var(--density-font-size-xs); }
394
+ /* ── 紧凑密度(28px 行高) ── */
395
+ .icen-datatable--compact .icen-dt-cell { min-height: 28px; padding: 0 8px; }
396
+ .icen-datatable--compact .icen-dt-cell--head { min-height: 28px; font-size: var(--icen-density-font-size-xs); }
344
397
 
345
- /* ── 工具栏右侧操作按钮组 ── */
346
- .dt-toolbar-actions {
347
- margin-left: auto;
398
+ /* ── 工具栏行内末端操作按钮组 ── */
399
+ .icen-dt-toolbar-actions {
400
+ margin-inline-start: auto;
348
401
  display: flex;
349
402
  align-items: center;
350
403
  gap: 4px;
351
404
  }
352
- .dt-tool-btn {
405
+ .icen-dt-tool-btn {
353
406
  display: inline-flex;
354
407
  align-items: center;
355
408
  justify-content: center;
356
409
  width: 28px;
357
410
  height: 28px;
358
411
  flex-shrink: 0;
359
- border: 1px solid var(--token-line-soft);
360
- border-radius: var(--radius-sm);
412
+ border: 1px solid var(--icen-token-line-soft);
413
+ border-radius: var(--icen-radius-sm);
361
414
  background: transparent;
362
- color: var(--token-text-faint);
415
+ color: var(--icen-token-text-faint);
363
416
  cursor: pointer;
364
417
  transition: color var(--icen-tx-fast), border-color var(--icen-tx-fast), background var(--icen-tx-fast);
365
418
  }
366
- .dt-tool-btn:hover {
367
- color: var(--token-text);
368
- border-color: var(--token-accent);
369
- background: var(--token-fill-1);
419
+ .icen-dt-tool-btn:hover {
420
+ color: var(--icen-token-text);
421
+ border-color: var(--icen-token-accent);
422
+ background: var(--icen-token-fill-1);
370
423
  }
371
424
 
372
- /* ── 列宽拖拽手柄 ── */
373
- .dt-resize {
425
+ /* ── 列宽拖拽手柄(列宽由 behavior 用 getBoundingClientRect 物理坐标计算,手柄钉在列物理右缘) ── */
426
+ .icen-dt-resize {
374
427
  position: absolute;
375
428
  top: 0;
376
- right: 0;
429
+ right: 0; /* guard:allow-physical 列宽拖拽坐标系为物理(behavior 测量/写入物理像素),RTL 不变 */
377
430
  bottom: 0;
378
431
  width: 6px;
379
432
  cursor: col-resize;
@@ -381,45 +434,247 @@
381
434
  touch-action: none;
382
435
  z-index: 1;
383
436
  }
384
- .dt-resize::after {
437
+ .icen-dt-resize::after {
385
438
  content: '';
386
439
  position: absolute;
387
440
  top: 25%;
388
441
  bottom: 25%;
389
- right: 2px;
442
+ right: 2px; /* guard:allow-physical 手柄视觉与拖拽坐标系一致(物理右缘),RTL 不变 */
390
443
  width: 2px;
391
- border-radius: 1px;
444
+ border-radius: 1px; /* guard:allow-radius 微构件(指示线/手柄等图形级,不属容器圆角面) */
392
445
  background: transparent;
393
446
  transition: background var(--icen-tx-fast);
394
447
  }
395
- .dt-resize:hover::after,
396
- .dt-resize:active::after {
397
- background: var(--token-accent);
448
+ .icen-dt-resize:hover::after,
449
+ .icen-dt-resize:active::after {
450
+ background: var(--icen-token-accent);
398
451
  }
399
- /* .dt-cell--head 已在主规则 position: relative,供 resize 手柄绝对定位 */
452
+ /* .icen-dt-cell--head 已在主规则 position: relative,供 resize 手柄绝对定位 */
400
453
 
401
454
  /* ── 冻结列(左固定 sticky) ── */
402
- .datatable--frozen .dt-cell--frozen {
455
+ .icen-datatable--frozen .icen-dt-cell--frozen {
403
456
  position: sticky;
404
- z-index: var(--z-raised);
405
- background: var(--token-surface);
457
+ z-index: var(--icen-z-raised);
458
+ background: var(--icen-token-surface);
459
+ }
460
+ .icen-datatable--frozen .icen-dt-row--head .icen-dt-cell--frozen {
461
+ z-index: calc(var(--icen-z-raised) + 1);
462
+ background: var(--icen-token-bg-soft);
463
+ }
464
+ .icen-datatable--frozen .icen-dt-row.is-selected .icen-dt-cell--frozen {
465
+ background: var(--icen-token-accent-subtle);
406
466
  }
407
- .datatable--frozen .dt-row--head .dt-cell--frozen {
408
- z-index: calc(var(--z-raised) + 1);
409
- background: var(--token-bg-soft);
467
+ .icen-datatable--frozen .icen-dt-body .icen-dt-row:hover .icen-dt-cell--frozen {
468
+ background: var(--icen-token-fill-1);
410
469
  }
411
- .datatable--frozen .dt-row.is-selected .dt-cell--frozen {
412
- background: var(--token-accent-subtle);
470
+ .icen-datatable--frozen .icen-dt-row.is-selected:hover .icen-dt-cell--frozen {
471
+ background: color-mix(in srgb, var(--icen-token-accent-subtle) 82%, var(--icen-token-fill-1));
413
472
  }
414
- .datatable--frozen .dt-body .dt-row:hover .dt-cell--frozen {
415
- background: var(--token-fill-1);
473
+ /* 斑马纹是行级底色,冻结格不透明面透不上来:偶数行冻结格重铺同款色,
474
+ 否则条纹在冻结边界处断掉(选中/hover 已有对应规则) */
475
+ .icen-datatable--striped .icen-dt-body .icen-dt-row:nth-child(even):not(.is-selected) .icen-dt-cell--frozen {
476
+ background: color-mix(in srgb, var(--icen-token-fill-1) 55%, transparent);
416
477
  }
417
- .datatable--frozen .dt-row.is-selected:hover .dt-cell--frozen {
418
- background: color-mix(in srgb, var(--token-accent-subtle) 82%, var(--token-fill-1));
478
+ .icen-datatable--striped .icen-dt-body .icen-dt-row:nth-child(even):not(.is-selected):hover .icen-dt-cell--frozen {
479
+ background: var(--icen-token-fill-1);
419
480
  }
420
481
 
421
482
  /* ── 行状态类(rowClassName 产出;--danger/--warning/--success 同族语义行底色) ── */
422
- .dt-row--danger { background: color-mix(in srgb, var(--token-error) 6%, transparent) !important; }
423
- .dt-row--danger:hover { background: color-mix(in srgb, var(--token-error) 10%, transparent) !important; }
424
- .dt-row--warning { background: color-mix(in srgb, var(--token-warning) 6%, transparent) !important; }
425
- .dt-row--success { background: color-mix(in srgb, var(--token-success) 6%, transparent) !important; }
483
+ .icen-dt-row--danger { background: color-mix(in srgb, var(--icen-token-error) 6%, transparent) !important; /* guard:allow-important 状态/守卫覆盖需压制变体优先级 */ }
484
+ .icen-dt-row--danger:hover { background: color-mix(in srgb, var(--icen-token-error) 10%, transparent) !important; /* guard:allow-important 状态/守卫覆盖需压制变体优先级 */ }
485
+ .icen-dt-row--warning { background: color-mix(in srgb, var(--icen-token-warning) 6%, transparent) !important; /* guard:allow-important 状态/守卫覆盖需压制变体优先级 */ }
486
+ .icen-dt-row--success { background: color-mix(in srgb, var(--icen-token-success) 6%, transparent) !important; /* guard:allow-important 状态/守卫覆盖需压制变体优先级 */ }
487
+
488
+ /* ── 多列排序:优先级徽标(1 = 主排序;与 sortable 头部视觉同族) ── */
489
+ .icen-dt-sort-badge {
490
+ display: inline-flex;
491
+ align-items: center;
492
+ justify-content: center;
493
+ min-width: 15px;
494
+ height: 15px;
495
+ padding: 0 3px;
496
+ flex-shrink: 0;
497
+ border-radius: var(--icen-radius-full);
498
+ background: var(--icen-token-accent-strong);
499
+ color: var(--icen-token-on-accent);
500
+ font-size: var(--icen-density-font-size-2xs);
501
+ font-weight: 600;
502
+ line-height: 1;
503
+ }
504
+
505
+ /* ── 列重排(reorderable:整格可拖,把手/按钮除外——behavior 判定) ── */
506
+ .icen-datatable--reorderable .icen-dt-cell--head { cursor: grab; }
507
+ .icen-datatable--reorderable .icen-dt-cell--head:active { cursor: grabbing; }
508
+ .icen-dt-cell--head.is-drag-source { opacity: 0.4; }
509
+ .icen-dt-col-ghost {
510
+ /* portal 到 body,behavior 按指针 rAF 定位 */
511
+ position: fixed;
512
+ z-index: var(--icen-z-popover);
513
+ padding: 6px 12px;
514
+ max-width: 240px;
515
+ overflow: hidden;
516
+ text-overflow: ellipsis;
517
+ white-space: nowrap;
518
+ background: var(--icen-token-card-strong);
519
+ border: 1px solid var(--icen-token-accent);
520
+ border-radius: var(--icen-radius-sm);
521
+ box-shadow: var(--icen-token-shadow-overlay);
522
+ color: var(--icen-token-text);
523
+ font-size: var(--icen-density-font-size-sm);
524
+ font-weight: 600;
525
+ pointer-events: none;
526
+ opacity: 0.92;
527
+ }
528
+ .icen-dt-col-indicator {
529
+ /* 插入指示线:贯穿表头 + 表体可视区(behavior 按 scroll 容器 rect 定位) */
530
+ position: fixed;
531
+ z-index: var(--icen-z-popover);
532
+ width: 2px;
533
+ border-radius: 1px; /* guard:allow-radius 微构件(指示线/手柄等图形级,不属容器圆角面) */
534
+ background: var(--icen-token-accent);
535
+ pointer-events: none;
536
+ }
537
+
538
+ /* ── 冻结列(右固定 sticky;偏移量由 behavior 累计列宽测量后内联 right) ── */
539
+ .icen-datatable--frozen .icen-dt-cell--frozen-right {
540
+ position: sticky;
541
+ z-index: var(--icen-z-raised);
542
+ background: var(--icen-token-surface);
543
+ }
544
+ .icen-datatable--frozen .icen-dt-row--head .icen-dt-cell--frozen-right {
545
+ z-index: calc(var(--icen-z-raised) + 1);
546
+ background: var(--icen-token-bg-soft);
547
+ }
548
+ .icen-datatable--frozen .icen-dt-row.is-selected .icen-dt-cell--frozen-right {
549
+ background: var(--icen-token-accent-subtle);
550
+ }
551
+ .icen-datatable--frozen .icen-dt-body .icen-dt-row:hover .icen-dt-cell--frozen-right {
552
+ background: var(--icen-token-fill-1);
553
+ }
554
+ .icen-datatable--frozen .icen-dt-row.is-selected:hover .icen-dt-cell--frozen-right {
555
+ background: color-mix(in srgb, var(--icen-token-accent-subtle) 82%, var(--icen-token-fill-1));
556
+ }
557
+
558
+ /* ── 行分组(组头行:表头同族底色 + 聚合 chip;点击折叠/展开) ── */
559
+ .icen-dt-row--group {
560
+ background: var(--icen-token-bg-soft);
561
+ font-weight: 600;
562
+ }
563
+ .icen-dt-row--group:hover { background: var(--icen-token-bg-soft); }
564
+ .icen-dt-cell--group {
565
+ gap: var(--icen-density-space-sm);
566
+ color: var(--icen-token-text-muted);
567
+ font-size: var(--icen-density-font-size-sm);
568
+ user-select: none;
569
+ cursor: pointer;
570
+ }
571
+ .icen-dt-group-toggle {
572
+ display: inline-flex;
573
+ align-items: center;
574
+ justify-content: center;
575
+ width: 22px;
576
+ height: 22px;
577
+ flex-shrink: 0;
578
+ border: 0;
579
+ border-radius: var(--icen-radius-sm);
580
+ background: transparent;
581
+ color: var(--icen-token-text-faint);
582
+ cursor: pointer;
583
+ transition: transform var(--icen-tx-fast), color var(--icen-tx-fast), background var(--icen-tx-fast);
584
+ }
585
+ .icen-dt-group-toggle:hover { color: var(--icen-token-text); background: var(--icen-token-fill-2); }
586
+ .icen-dt-row--group:not(.is-collapsed) .icen-dt-group-toggle {
587
+ transform: rotate(180deg);
588
+ color: var(--icen-token-accent);
589
+ }
590
+ .icen-dt-group-label { overflow: hidden; text-overflow: ellipsis; }
591
+ .icen-dt-group-count {
592
+ color: var(--icen-token-text-faint);
593
+ font-size: var(--icen-density-font-size-xs);
594
+ font-weight: 400;
595
+ font-variant-numeric: tabular-nums;
596
+ }
597
+ .icen-dt-group-aggs {
598
+ margin-inline-start: auto;
599
+ display: inline-flex;
600
+ align-items: center;
601
+ gap: 6px;
602
+ flex-shrink: 0;
603
+ }
604
+ .icen-dt-group-agg {
605
+ padding: 1px 8px;
606
+ border-radius: var(--icen-radius-full);
607
+ background: var(--icen-token-accent-subtle);
608
+ color: var(--icen-token-accent-text, var(--icen-token-accent-deep, var(--icen-token-accent)));
609
+ font-size: var(--icen-density-font-size-2xs);
610
+ font-weight: 500;
611
+ font-variant-numeric: tabular-nums;
612
+ white-space: nowrap;
613
+ }
614
+
615
+ /* ── 单元格编辑(行内 input/select 替换内容;非法值抖动不提交) ── */
616
+ .icen-dt-body .icen-dt-cell.is-editable { cursor: text; }
617
+ .icen-dt-cell.is-editing {
618
+ padding: 0 6px;
619
+ overflow: visible;
620
+ background: var(--icen-token-surface);
621
+ }
622
+ .icen-dt-editor {
623
+ flex: 1;
624
+ min-width: 0;
625
+ height: 30px;
626
+ padding: 0 8px;
627
+ font: inherit;
628
+ font-size: var(--icen-density-font-size-sm);
629
+ color: var(--icen-token-text);
630
+ background: var(--icen-token-control);
631
+ border: 1px solid var(--icen-control-focus-border, var(--icen-token-accent));
632
+ border-radius: var(--icen-radius-sm);
633
+ box-shadow: var(--icen-control-focus-shadow);
634
+ outline: none;
635
+ }
636
+ .icen-dt-editor--select {
637
+ appearance: auto;
638
+ cursor: pointer;
639
+ }
640
+ .icen-dt-editor.is-invalid {
641
+ border-color: var(--icen-token-error);
642
+ box-shadow: var(--icen-control-error-shadow);
643
+ animation: dt-editor-shake var(--icen-tx-normal);
644
+ }
645
+ .icen-datatable--compact .icen-dt-editor { height: 24px; }
646
+ @keyframes dt-editor-shake {
647
+ 0%, 100% { transform: translateX(0); }
648
+ 25% { transform: translateX(-3px); }
649
+ 55% { transform: translateX(3px); }
650
+ 80% { transform: translateX(-2px); }
651
+ }
652
+
653
+ /* ── 汇总行(表尾 sticky 一行,钉在滚动视口底、随横向滚动对齐列) ── */
654
+ .icen-dt-row--summary {
655
+ position: sticky;
656
+ bottom: 0;
657
+ z-index: var(--icen-z-raised);
658
+ background: var(--icen-token-bg-soft);
659
+ border-top: 1px solid var(--icen-token-line-soft);
660
+ border-bottom: 0;
661
+ font-weight: 600;
662
+ }
663
+ .icen-dt-row--summary[hidden] { display: none; }
664
+ .icen-dt-cell--summary {
665
+ color: var(--icen-token-text);
666
+ font-size: var(--icen-density-font-size-sm);
667
+ font-variant-numeric: tabular-nums;
668
+ }
669
+ .icen-datatable--frozen .icen-dt-row--summary .icen-dt-cell--frozen,
670
+ .icen-datatable--frozen .icen-dt-row--summary .icen-dt-cell--frozen-right {
671
+ background: var(--icen-token-bg-soft);
672
+ }
673
+
674
+ /* ── 键盘导航(roving tabindex 焦点环;与表头 focus-visible 同环) ── */
675
+ .icen-dt-body .icen-dt-cell:focus-visible {
676
+ outline: none;
677
+ box-shadow: var(--icen-ring-inset);
678
+ }
679
+
680
+ }