@icen.ai/ui 0.10.0 → 0.11.1

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 (362) hide show
  1. package/AGENTS.md +79 -309
  2. package/LICENSE +21 -0
  3. package/README.md +43 -54
  4. package/dist/base.css +68 -22
  5. package/dist/behaviors/accordion.mjs +1 -1
  6. package/dist/behaviors/ai-branch.mjs +14 -0
  7. package/dist/behaviors/ai-chat.d.mts +2 -2
  8. package/dist/behaviors/ai-chat.mjs +66 -10
  9. package/dist/behaviors/ai-composer.d.mts +5 -5
  10. package/dist/behaviors/ai-composer.mjs +34 -10
  11. package/dist/behaviors/ai-core.mjs +14 -0
  12. package/dist/behaviors/ai-diff.mjs +14 -0
  13. package/dist/behaviors/ai-feedback.mjs +14 -0
  14. package/dist/behaviors/ai-panel.d.mts +2 -2
  15. package/dist/behaviors/ai-panel.mjs +14 -0
  16. package/dist/behaviors/ai-provider.d.mts +1 -1
  17. package/dist/behaviors/ai-provider.mjs +14 -0
  18. package/dist/behaviors/ai-threads.mjs +14 -0
  19. package/dist/behaviors/ai-tool.d.mts +1 -1
  20. package/dist/behaviors/ai-tool.mjs +299 -24
  21. package/dist/behaviors/ai-tools.mjs +1179 -28
  22. package/dist/behaviors/autocomplete.d.mts +1 -1
  23. package/dist/behaviors/autocomplete.mjs +14 -0
  24. package/dist/behaviors/back-top.mjs +14 -0
  25. package/dist/behaviors/carousel.mjs +21 -1
  26. package/dist/behaviors/cascader.mjs +27 -0
  27. package/dist/behaviors/charts.d.mts +12 -1
  28. package/dist/behaviors/charts.mjs +298 -20
  29. package/dist/behaviors/code-block.mjs +22 -1
  30. package/dist/behaviors/command-palette.mjs +3 -3
  31. package/dist/behaviors/context-menu.d.mts +2 -2
  32. package/dist/behaviors/context-menu.mjs +14 -0
  33. package/dist/behaviors/controls.d.mts +8 -8
  34. package/dist/behaviors/controls.mjs +50 -6
  35. package/dist/behaviors/copy.mjs +14 -0
  36. package/dist/behaviors/datatable.d.mts +3 -3
  37. package/dist/behaviors/datatable.mjs +89 -11
  38. package/dist/behaviors/date-picker.mjs +14 -0
  39. package/dist/behaviors/events.d.mts +10 -10
  40. package/dist/behaviors/events.mjs +11 -1
  41. package/dist/behaviors/form-validate.d.mts +10 -1
  42. package/dist/behaviors/form-validate.mjs +279 -4611
  43. package/dist/behaviors/i18n.d.mts +14 -0
  44. package/dist/behaviors/i18n.mjs +28 -0
  45. package/dist/behaviors/input.mjs +16 -0
  46. package/dist/behaviors/kb-access.d.mts +2 -2
  47. package/dist/behaviors/kb-access.mjs +21 -2
  48. package/dist/behaviors/kb-acl.d.mts +2 -2
  49. package/dist/behaviors/kb-acl.mjs +14 -0
  50. package/dist/behaviors/kb-answer.d.mts +2 -2
  51. package/dist/behaviors/kb-answer.mjs +298 -23
  52. package/dist/behaviors/kb-audit.d.mts +2 -2
  53. package/dist/behaviors/kb-audit.mjs +14 -0
  54. package/dist/behaviors/kb-canvas.d.mts +3 -3
  55. package/dist/behaviors/kb-canvas.mjs +14 -0
  56. package/dist/behaviors/kb-chain.d.mts +2 -2
  57. package/dist/behaviors/kb-chain.mjs +14 -0
  58. package/dist/behaviors/kb-checkpoint.d.mts +2 -2
  59. package/dist/behaviors/kb-checkpoint.mjs +14 -0
  60. package/dist/behaviors/kb-chunks.d.mts +2 -2
  61. package/dist/behaviors/kb-chunks.mjs +14 -0
  62. package/dist/behaviors/kb-citation.d.mts +2 -2
  63. package/dist/behaviors/kb-citation.mjs +33 -6
  64. package/dist/behaviors/kb-clarify.d.mts +2 -2
  65. package/dist/behaviors/kb-clarify.mjs +14 -0
  66. package/dist/behaviors/kb-conflict.d.mts +2 -2
  67. package/dist/behaviors/kb-conflict.mjs +14 -0
  68. package/dist/behaviors/kb-connector.d.mts +2 -2
  69. package/dist/behaviors/kb-connector.mjs +14 -0
  70. package/dist/behaviors/kb-core.d.mts +1 -1
  71. package/dist/behaviors/kb-core.mjs +14 -0
  72. package/dist/behaviors/kb-eval.d.mts +2 -2
  73. package/dist/behaviors/kb-eval.mjs +21 -2
  74. package/dist/behaviors/kb-explain.d.mts +2 -2
  75. package/dist/behaviors/kb-explain.mjs +26 -2
  76. package/dist/behaviors/kb-filter.d.mts +2 -2
  77. package/dist/behaviors/kb-filter.mjs +21 -2
  78. package/dist/behaviors/kb-gap.d.mts +2 -2
  79. package/dist/behaviors/kb-gap.mjs +14 -0
  80. package/dist/behaviors/kb-hittest.d.mts +2 -2
  81. package/dist/behaviors/kb-hittest.mjs +15 -1
  82. package/dist/behaviors/kb-metadata.mjs +19 -0
  83. package/dist/behaviors/kb-passage.d.mts +2 -2
  84. package/dist/behaviors/kb-passage.mjs +14 -0
  85. package/dist/behaviors/kb-pipeline.d.mts +2 -2
  86. package/dist/behaviors/kb-pipeline.mjs +14 -0
  87. package/dist/behaviors/kb-qa.mjs +14 -0
  88. package/dist/behaviors/kb-rerank.d.mts +2 -2
  89. package/dist/behaviors/kb-rerank.mjs +14 -0
  90. package/dist/behaviors/kb-retrieval.d.mts +2 -2
  91. package/dist/behaviors/kb-retrieval.mjs +31 -4
  92. package/dist/behaviors/kb-review.d.mts +2 -2
  93. package/dist/behaviors/kb-review.mjs +21 -2
  94. package/dist/behaviors/kb-sandbox.d.mts +2 -2
  95. package/dist/behaviors/kb-sandbox.mjs +20 -1
  96. package/dist/behaviors/kb-segment.d.mts +2 -2
  97. package/dist/behaviors/kb-segment.mjs +15 -1
  98. package/dist/behaviors/kb-select.mjs +21 -2
  99. package/dist/behaviors/kb-sources.d.mts +2 -2
  100. package/dist/behaviors/kb-sources.mjs +14 -0
  101. package/dist/behaviors/kb-sql.d.mts +2 -2
  102. package/dist/behaviors/kb-sql.mjs +14 -0
  103. package/dist/behaviors/kb-trace.d.mts +2 -2
  104. package/dist/behaviors/kb-trace.mjs +22 -3
  105. package/dist/behaviors/kb-visibility.d.mts +2 -2
  106. package/dist/behaviors/kb-visibility.mjs +14 -0
  107. package/dist/behaviors/kb-who-can.d.mts +2 -2
  108. package/dist/behaviors/kb-who-can.mjs +21 -2
  109. package/dist/behaviors/mentions.d.mts +1 -1
  110. package/dist/behaviors/mentions.mjs +14 -0
  111. package/dist/behaviors/modal.d.mts +1 -1
  112. package/dist/behaviors/modal.mjs +14 -0
  113. package/dist/behaviors/motion.d.mts +16 -0
  114. package/dist/behaviors/motion.mjs +39 -0
  115. package/dist/behaviors/notification.d.mts +2 -2
  116. package/dist/behaviors/notification.mjs +27 -3
  117. package/dist/behaviors/panel.mjs +14 -0
  118. package/dist/behaviors/scroll-area.d.mts +17 -0
  119. package/dist/behaviors/scroll-area.mjs +59 -0
  120. package/dist/behaviors/select.mjs +21 -2
  121. package/dist/behaviors/slider.mjs +3 -3
  122. package/dist/behaviors/split-pane.mjs +2 -0
  123. package/dist/behaviors/suggestions.mjs +14 -0
  124. package/dist/behaviors/tabs.mjs +10 -0
  125. package/dist/behaviors/tag-input.mjs +14 -0
  126. package/dist/behaviors/theme-switcher.d.mts +2 -2
  127. package/dist/behaviors/theme-switcher.mjs +30 -2
  128. package/dist/behaviors/theme.mjs +16 -2
  129. package/dist/behaviors/toast.d.mts +2 -2
  130. package/dist/behaviors/toast.mjs +14 -0
  131. package/dist/behaviors/tree-select.mjs +27 -0
  132. package/dist/behaviors/tree.mjs +4 -4
  133. package/dist/behaviors/upload.mjs +14 -0
  134. package/dist/behaviors/url-safety.d.mts +8 -0
  135. package/dist/behaviors/url-safety.mjs +11 -0
  136. package/dist/components/accordion.d.mts +2 -0
  137. package/dist/components/ai-branch.d.mts +2 -0
  138. package/dist/components/ai-chat.css +40 -33
  139. package/dist/components/ai-chat.d.mts +2 -0
  140. package/dist/components/ai-composer.d.mts +2 -0
  141. package/dist/components/ai-context.d.mts +2 -0
  142. package/dist/components/ai-context.mjs +1 -0
  143. package/dist/components/ai-diff.css +6 -6
  144. package/dist/components/ai-diff.d.mts +2 -0
  145. package/dist/components/ai-feedback.d.mts +2 -0
  146. package/dist/components/ai-files.d.mts +2 -0
  147. package/dist/components/ai-message.d.mts +2 -0
  148. package/dist/components/ai-panel.css +12 -10
  149. package/dist/components/ai-reasoning.d.mts +2 -0
  150. package/dist/components/ai-subagent.d.mts +2 -0
  151. package/dist/components/ai-subagent.mjs +1 -0
  152. package/dist/components/ai-threads.d.mts +2 -0
  153. package/dist/components/ai-todo.d.mts +2 -0
  154. package/dist/components/ai-todo.mjs +1 -0
  155. package/dist/components/ai-tool-call.d.mts +2 -0
  156. package/dist/components/ai-tool-call.mjs +1 -0
  157. package/dist/components/ai-tool.css +16 -16
  158. package/dist/components/ai-usage.d.mts +2 -0
  159. package/dist/components/alert.d.mts +2 -0
  160. package/dist/components/autocomplete.css +12 -12
  161. package/dist/components/autocomplete.d.mts +2 -0
  162. package/dist/components/avatar.d.mts +2 -0
  163. package/dist/components/back-top.css +47 -16
  164. package/dist/components/back-top.d.mts +2 -0
  165. package/dist/components/badge.css +1 -1
  166. package/dist/components/badge.d.mts +2 -0
  167. package/dist/components/breadcrumb.css +26 -8
  168. package/dist/components/breadcrumb.d.mts +2 -0
  169. package/dist/components/btn.css +67 -62
  170. package/dist/components/btn.d.mts +2 -0
  171. package/dist/components/card.css +22 -22
  172. package/dist/components/card.d.mts +2 -0
  173. package/dist/components/carousel.d.mts +2 -0
  174. package/dist/components/cascader.css +56 -35
  175. package/dist/components/cascader.d.mts +2 -0
  176. package/dist/components/chart-area.css +46 -0
  177. package/dist/components/chart-area.d.mts +2 -0
  178. package/dist/components/chart-bar.css +66 -19
  179. package/dist/components/chart-bar.d.mts +2 -0
  180. package/dist/components/chart-calendar.d.mts +2 -0
  181. package/dist/components/chart-gauge.css +23 -3
  182. package/dist/components/chart-gauge.d.mts +2 -0
  183. package/dist/components/chart-graph.css +15 -3
  184. package/dist/components/chart-graph.d.mts +2 -0
  185. package/dist/components/chart-heatmap.css +117 -95
  186. package/dist/components/chart-heatmap.d.mts +2 -0
  187. package/dist/components/chart-line.css +54 -0
  188. package/dist/components/chart-line.d.mts +2 -0
  189. package/dist/components/chart-map.d.mts +2 -0
  190. package/dist/components/chart-pie.css +29 -0
  191. package/dist/components/chart-pie.d.mts +2 -0
  192. package/dist/components/chart-radar.css +50 -1
  193. package/dist/components/chart-radar.d.mts +2 -0
  194. package/dist/components/chart-scatter.css +39 -2
  195. package/dist/components/chart-scatter.d.mts +2 -0
  196. package/dist/components/chart-sparkline.css +20 -0
  197. package/dist/components/chart-sparkline.d.mts +2 -0
  198. package/dist/components/chart-stack.css +16 -5
  199. package/dist/components/chart-stack.d.mts +2 -0
  200. package/dist/components/charts.css +109 -35
  201. package/dist/components/charts.d.mts +2 -0
  202. package/dist/components/code-block.css +10 -8
  203. package/dist/components/code-block.d.mts +2 -0
  204. package/dist/components/command-palette.css +45 -38
  205. package/dist/components/command-palette.d.mts +2 -0
  206. package/dist/components/content.css +62 -57
  207. package/dist/components/context-menu.d.mts +2 -0
  208. package/dist/components/copy.css +10 -10
  209. package/dist/components/copy.d.mts +2 -0
  210. package/dist/components/datatable.css +72 -59
  211. package/dist/components/datatable.d.mts +2 -0
  212. package/dist/components/date-picker.css +26 -26
  213. package/dist/components/date-picker.d.mts +2 -0
  214. package/dist/components/desc.d.mts +2 -0
  215. package/dist/components/dropdown.d.mts +2 -0
  216. package/dist/components/empty.css +16 -16
  217. package/dist/components/empty.d.mts +2 -0
  218. package/dist/components/feedback.css +31 -29
  219. package/dist/components/form-validate.css +20 -6
  220. package/dist/components/form-validate.d.mts +2 -0
  221. package/dist/components/form.css +17 -14
  222. package/dist/components/form.d.mts +2 -0
  223. package/dist/components/icon.css +21 -10
  224. package/dist/components/icon.d.mts +2 -0
  225. package/dist/components/input.css +22 -22
  226. package/dist/components/input.d.mts +2 -0
  227. package/dist/components/kb-access.d.mts +2 -0
  228. package/dist/components/kb-acl.d.mts +2 -0
  229. package/dist/components/kb-agent.css +134 -55
  230. package/dist/components/kb-answer.d.mts +2 -0
  231. package/dist/components/kb-audit.d.mts +2 -0
  232. package/dist/components/kb-canvas.d.mts +2 -0
  233. package/dist/components/kb-chain.d.mts +2 -0
  234. package/dist/components/kb-checkpoint.d.mts +2 -0
  235. package/dist/components/kb-chunks.d.mts +2 -0
  236. package/dist/components/kb-citation.d.mts +2 -0
  237. package/dist/components/kb-clarify.d.mts +2 -0
  238. package/dist/components/kb-conflict.d.mts +2 -0
  239. package/dist/components/kb-connector.d.mts +2 -0
  240. package/dist/components/kb-data.css +192 -80
  241. package/dist/components/kb-eval.d.mts +2 -0
  242. package/dist/components/kb-explain.d.mts +2 -0
  243. package/dist/components/kb-filter.d.mts +2 -0
  244. package/dist/components/kb-gap.d.mts +2 -0
  245. package/dist/components/kb-ground.css +165 -73
  246. package/dist/components/kb-hittest.d.mts +2 -0
  247. package/dist/components/kb-ingest.css +308 -113
  248. package/dist/components/kb-metadata.d.mts +2 -0
  249. package/dist/components/kb-ops.css +189 -75
  250. package/dist/components/kb-passage.d.mts +2 -0
  251. package/dist/components/kb-perm.css +158 -87
  252. package/dist/components/kb-pipeline.d.mts +2 -0
  253. package/dist/components/kb-qa.d.mts +2 -0
  254. package/dist/components/kb-rerank.d.mts +2 -0
  255. package/dist/components/kb-retrieval.d.mts +2 -0
  256. package/dist/components/kb-review.d.mts +2 -0
  257. package/dist/components/kb-sandbox.d.mts +2 -0
  258. package/dist/components/kb-search.css +353 -116
  259. package/dist/components/kb-segment.d.mts +2 -0
  260. package/dist/components/kb-sources.d.mts +2 -0
  261. package/dist/components/kb-sql.d.mts +2 -0
  262. package/dist/components/kb-trace.d.mts +2 -0
  263. package/dist/components/kb-visibility.d.mts +2 -0
  264. package/dist/components/kb-who-can.d.mts +2 -0
  265. package/dist/components/kb.css +60 -36
  266. package/dist/components/kb.d.mts +2 -0
  267. package/dist/components/kbd.d.mts +2 -0
  268. package/dist/components/layout.css +10 -10
  269. package/dist/components/layout.d.mts +2 -0
  270. package/dist/components/list.d.mts +2 -0
  271. package/dist/components/material-chinese.css +10 -0
  272. package/dist/components/material-soviet.css +10 -0
  273. package/dist/components/material.css +61 -18
  274. package/dist/components/media-card.d.mts +2 -0
  275. package/dist/components/media.css +22 -27
  276. package/dist/components/mentions.css +18 -17
  277. package/dist/components/mentions.d.mts +2 -0
  278. package/dist/components/menu.css +32 -28
  279. package/dist/components/modal.css +30 -27
  280. package/dist/components/modal.d.mts +2 -0
  281. package/dist/components/nav.css +48 -44
  282. package/dist/components/nav.d.mts +2 -0
  283. package/dist/components/notification.css +31 -25
  284. package/dist/components/notification.d.mts +2 -0
  285. package/dist/components/pagination.css +15 -13
  286. package/dist/components/pagination.d.mts +2 -0
  287. package/dist/components/panel.css +19 -20
  288. package/dist/components/panel.d.mts +2 -0
  289. package/dist/components/pill.css +8 -7
  290. package/dist/components/pill.d.mts +2 -0
  291. package/dist/components/popover.css +32 -23
  292. package/dist/components/popover.d.mts +2 -0
  293. package/dist/components/progress.d.mts +2 -0
  294. package/dist/components/rating.d.mts +2 -0
  295. package/dist/components/result.d.mts +2 -0
  296. package/dist/components/scroll-area.css +84 -112
  297. package/dist/components/scroll-area.d.mts +2 -0
  298. package/dist/components/scroll-area.mjs +1 -0
  299. package/dist/components/segmented.css +47 -29
  300. package/dist/components/segmented.d.mts +2 -0
  301. package/dist/components/select.css +80 -41
  302. package/dist/components/select.d.mts +2 -0
  303. package/dist/components/sidebar.css +42 -38
  304. package/dist/components/sidebar.d.mts +2 -0
  305. package/dist/components/skeleton.d.mts +2 -0
  306. package/dist/components/slider.css +26 -22
  307. package/dist/components/slider.d.mts +2 -0
  308. package/dist/components/spinner.d.mts +2 -0
  309. package/dist/components/split-pane.css +16 -7
  310. package/dist/components/split-pane.d.mts +2 -0
  311. package/dist/components/stat.css +17 -16
  312. package/dist/components/stat.d.mts +2 -0
  313. package/dist/components/steps.css +26 -26
  314. package/dist/components/steps.d.mts +2 -0
  315. package/dist/components/switch.css +78 -39
  316. package/dist/components/switch.d.mts +2 -0
  317. package/dist/components/table.css +54 -32
  318. package/dist/components/table.d.mts +2 -0
  319. package/dist/components/tabs.css +53 -32
  320. package/dist/components/tabs.d.mts +2 -0
  321. package/dist/components/tag-input.css +12 -8
  322. package/dist/components/tag-input.d.mts +2 -0
  323. package/dist/components/tag.css +20 -12
  324. package/dist/components/tag.d.mts +2 -0
  325. package/dist/components/theme-switcher.css +7 -7
  326. package/dist/components/theme-switcher.d.mts +2 -0
  327. package/dist/components/timeline.d.mts +2 -0
  328. package/dist/components/toast.css +34 -30
  329. package/dist/components/toast.d.mts +2 -0
  330. package/dist/components/toolbar.css +19 -18
  331. package/dist/components/toolbar.d.mts +2 -0
  332. package/dist/components/tooltip.css +9 -8
  333. package/dist/components/tooltip.d.mts +2 -0
  334. package/dist/components/tree-select.css +63 -40
  335. package/dist/components/tree-select.d.mts +2 -0
  336. package/dist/components/tree.d.mts +2 -0
  337. package/dist/components/upload.css +9 -11
  338. package/dist/components/upload.d.mts +2 -0
  339. package/dist/index.d.mts +85 -84
  340. package/dist/index.mjs +14644 -13935
  341. package/dist/react.d.mts +18 -18
  342. package/dist/react.mjs +377 -36
  343. package/dist/registry.json +797 -64
  344. package/dist/tokens/colors.css +6 -0
  345. package/dist/tokens/design.css +137 -31
  346. package/dist/tokens/dtcg.json +9592 -2008
  347. package/dist/tokens/figma.variables.json +7451 -2141
  348. package/dist/tokens/motion.css +51 -0
  349. package/dist/tokens/pixel.css +10 -0
  350. package/dist/tokens/scrollbars.css +40 -0
  351. package/dist/tokens/tokens-studio.json +8390 -1142
  352. package/dist/tokens/typography.css +33 -0
  353. package/dist/tokens.css +402 -82
  354. package/dist/ui.css +4196 -2163
  355. package/dist/vue.d.mts +17 -17
  356. package/dist/vue.mjs +371 -34
  357. package/docs/spec/charts-scale-a11y.md +115 -0
  358. package/docs/spec/design-philosophy.md +5 -5
  359. package/docs/spec/design-primitives.md +10 -10
  360. package/docs/spec/motion-typography.md +105 -0
  361. package/docs/spec/scrollbars.md +46 -0
  362. package/package.json +17 -3
@@ -17,45 +17,53 @@
17
17
  * 标记 .icen-chart-mark-line / .icen-chart-mark-point / .icen-chart-mark-label
18
18
  * (spec.marks:SVG 变体属性直出样式仅挡指针事件,vbar DOM 变体在 chart-bar.css)。
19
19
  *
20
- * 单色调通过容器或条上的 --chart-tone 自定义属性注入(默认 var(--icen-token-accent))。
20
+ * 图表是「数据墨水」而非装饰面:网格与轴用发丝线,数据用饱和色,文字一律等宽数字,
21
+ * 悬浮只提亮不位移。单色调通过容器或条上的 --chart-tone 自定义属性注入(默认 accent)。
21
22
  */
22
23
 
23
24
  .icen-chart {
24
25
  width: 100%;
26
+ min-width: 0;
25
27
  display: flex;
26
28
  flex-direction: column;
27
29
  gap: var(--icen-density-space-sm);
30
+ color: var(--icen-token-text);
31
+ font-variant-numeric: tabular-nums;
28
32
  }
29
33
  .icen-chart-empty {
30
- height: 150px;
34
+ height: 160px;
31
35
  display: flex;
32
36
  align-items: center;
33
37
  justify-content: center;
34
- font-size: var(--icen-density-font-size-xs);
35
- color: var(--icen-token-text-faint);
38
+ gap: 6px;
39
+ font-size: var(--icen-font-size-caption);
40
+ letter-spacing: 0.01em;
41
+ color: var(--icen-token-text-muted);
36
42
  }
37
43
 
38
44
  /* ── 图例 / 轴标签(donut / stack / vbar / line 共用) ── */
39
45
  .icen-chart-legend {
40
46
  display: flex;
41
47
  flex-direction: column;
42
- gap: 6px;
48
+ gap: 5px;
43
49
  min-width: 0;
44
50
  flex: 1;
45
51
  }
46
52
  .icen-chart-legend-item {
47
53
  display: flex;
48
54
  align-items: center;
49
- gap: var(--icen-density-space-xs);
50
- font-size: var(--icen-density-font-size-xs);
55
+ gap: 7px;
51
56
  min-width: 0;
57
+ font-size: var(--icen-font-size-caption);
58
+ line-height: 1.45;
52
59
  }
53
60
  .icen-chart-legend-dot {
54
- width: 8px;
55
- height: 8px;
61
+ width: 6px;
62
+ height: 6px;
56
63
  flex-shrink: 0;
57
64
  border-radius: var(--icen-radius-full);
58
65
  background: var(--chart-tone, var(--icen-token-accent));
66
+ box-shadow: 0 0 0 1px color-mix(in srgb, var(--icen-token-card) 70%, transparent);
59
67
  }
60
68
  .icen-chart-legend-label {
61
69
  flex: 1;
@@ -67,6 +75,8 @@
67
75
  }
68
76
  .icen-chart-legend-value {
69
77
  flex-shrink: 0;
78
+ font-family: var(--icen-font-mono);
79
+ font-size: 11px;
70
80
  font-variant-numeric: tabular-nums;
71
81
  color: var(--icen-token-text-faint);
72
82
  }
@@ -74,13 +84,15 @@
74
84
  .icen-chart-labels {
75
85
  display: flex;
76
86
  gap: var(--icen-density-space-xs);
77
- margin-top: var(--icen-density-space-xs);
87
+ margin-top: 4px;
78
88
  }
79
89
  .icen-chart-labels > span {
80
90
  flex: 1;
81
91
  min-width: 0;
82
92
  text-align: center;
83
- font-size: var(--icen-density-font-size-2xs);
93
+ font-size: 11px;
94
+ line-height: 1.3;
95
+ letter-spacing: 0.01em;
84
96
  color: var(--icen-token-text-faint);
85
97
  overflow: hidden;
86
98
  text-overflow: ellipsis;
@@ -94,7 +106,7 @@
94
106
  display: block;
95
107
  position: relative;
96
108
  min-block-size: 1.5em;
97
- font-size: var(--icen-density-font-size-2xs);
109
+ font-size: 11px;
98
110
  }
99
111
  .icen-chart-labels--points > span {
100
112
  position: absolute;
@@ -113,8 +125,10 @@
113
125
 
114
126
  /* 标题(spec.title 有值时渲染) */
115
127
  .icen-chart-title {
116
- font-size: var(--icen-density-font-size-sm);
128
+ font-size: var(--icen-font-size-control);
117
129
  font-weight: 600;
130
+ line-height: 1.35;
131
+ letter-spacing: -0.005em;
118
132
  color: var(--icen-token-text);
119
133
  }
120
134
 
@@ -130,8 +144,8 @@
130
144
  display: inline-flex;
131
145
  align-items: center;
132
146
  justify-content: center;
133
- width: 22px;
134
- height: 22px;
147
+ width: 24px;
148
+ height: 24px;
135
149
  padding: 0;
136
150
  border: 0;
137
151
  border-radius: var(--icen-radius-xs);
@@ -140,9 +154,10 @@
140
154
  cursor: pointer;
141
155
  transition: color var(--icen-tx-fast), background-color var(--icen-tx-fast);
142
156
  }
143
- .icen-chart-legend-eye:hover { color: var(--icen-token-text); background: var(--icen-token-fill-1); }
157
+ .icen-chart-legend-eye:hover { color: var(--icen-token-text); background: var(--icen-token-fill-hover); }
158
+ .icen-chart-legend-eye:active { background: var(--icen-token-fill-pressed); }
144
159
  .icen-chart-legend-eye:focus-visible { outline: none; box-shadow: var(--icen-ring); }
145
- .icen-chart-legend-eye svg { width: 13px; height: 13px; }
160
+ .icen-chart-legend-eye svg { width: 14px; height: 14px; }
146
161
  @media (pointer: coarse) {
147
162
  .icen-chart-legend-eye { min-inline-size: 44px; min-block-size: 44px; }
148
163
  .icen-chart-legend-toggle-item { min-block-size: 44px; }
@@ -155,26 +170,35 @@
155
170
  display: none;
156
171
  }
157
172
 
158
- /* 内置 tooltip:portal 到 body 的单例,position: fixed 跟随指针 */
173
+ /* 内置 tooltip:portal 到 body 的单例,position: fixed 跟随指针。
174
+ 浮层物理:玻璃面 + 发丝边 + 抬升阴影;无 backdrop-filter 时回落不透明面。 */
159
175
  .icen-chart-tooltip {
160
176
  position: fixed;
161
177
  z-index: var(--icen-z-tooltip);
162
178
  max-width: 280px;
163
- padding: 3px 8px;
179
+ padding: 6px 10px;
164
180
  border-radius: var(--icen-radius-sm);
165
- background: var(--icen-token-card-strong);
166
- border: 1px solid var(--icen-token-line);
167
- box-shadow: var(--icen-token-shadow-elevated);
168
- font-size: var(--icen-density-font-size-xs);
181
+ background: var(--icen-token-surface-glass);
182
+ -webkit-backdrop-filter: blur(var(--icen-material-blur-floating)) saturate(var(--icen-material-saturate));
183
+ backdrop-filter: blur(var(--icen-material-blur-floating)) saturate(var(--icen-material-saturate));
184
+ border: 1px solid var(--icen-token-material-edge);
185
+ box-shadow: var(--icen-token-material-light), var(--icen-token-shadow-elevated);
186
+ font-size: var(--icen-font-size-caption);
187
+ line-height: 1.45;
188
+ letter-spacing: 0.005em;
169
189
  font-variant-numeric: tabular-nums;
170
190
  color: var(--icen-token-text);
171
191
  pointer-events: none;
172
192
  }
173
193
  .icen-chart-tooltip[hidden] { display: none; }
174
194
 
195
+ @supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
196
+ .icen-chart-tooltip { background: var(--icen-token-surface-raised); }
197
+ }
198
+
175
199
  /* 数据标记(各图型的条/点/段/格):交互态由委托层挂 .is-hover,图例切换挂 .is-off */
176
200
  [data-icen-chart-mark] { cursor: pointer; }
177
- [data-icen-chart-mark].is-hover { filter: brightness(1.12); }
201
+ [data-icen-chart-mark].is-hover { filter: brightness(1.06); }
178
202
  [data-icen-chart-mark].is-off { opacity: 0.16; pointer-events: none; }
179
203
  svg circle[data-icen-chart-mark].is-hover { stroke-width: 3; }
180
204
 
@@ -182,11 +206,12 @@ svg circle[data-icen-chart-mark].is-hover { stroke-width: 3; }
182
206
  .icen-chart-legend--toggle .icen-chart-legend-toggle-item {
183
207
  cursor: pointer;
184
208
  border-radius: var(--icen-radius-xs);
185
- padding: 2px 4px;
186
- margin: -2px -4px;
209
+ padding: 3px 5px;
210
+ margin: -3px -5px;
187
211
  transition: background-color var(--icen-tx-fast);
188
212
  }
189
- .icen-chart-legend--toggle .icen-chart-legend-toggle-item:hover { background: var(--icen-token-fill-1); }
213
+ .icen-chart-legend--toggle .icen-chart-legend-toggle-item:hover { background: var(--icen-token-fill-hover); }
214
+ .icen-chart-legend--toggle .icen-chart-legend-toggle-item:active { background: var(--icen-token-fill-pressed); }
190
215
  .icen-chart-legend--toggle .icen-chart-legend-toggle-item:focus-visible {
191
216
  outline: none;
192
217
  box-shadow: var(--icen-ring);
@@ -207,21 +232,24 @@ svg circle[data-icen-chart-mark].is-hover { stroke-width: 3; }
207
232
  overflow: hidden;
208
233
  text-overflow: ellipsis;
209
234
  white-space: nowrap;
210
- font-size: var(--icen-density-font-size-2xs);
235
+ font-size: 11px;
236
+ letter-spacing: 0.01em;
211
237
  color: var(--icen-token-text-faint);
212
238
  }
213
239
  .icen-chart-zoom-reset {
214
240
  flex-shrink: 0;
215
- padding: 1px 8px;
241
+ min-height: 22px;
242
+ padding: 0 9px;
216
243
  border: 1px solid var(--icen-token-line);
217
244
  border-radius: var(--icen-radius-full);
218
245
  background: var(--icen-token-fill-1);
219
- font-size: var(--icen-density-font-size-2xs);
246
+ font-size: 11px;
220
247
  color: var(--icen-token-text-muted);
221
248
  cursor: pointer;
222
- transition: color var(--icen-tx-fast), background-color var(--icen-tx-fast);
249
+ transition: color var(--icen-tx-fast), background-color var(--icen-tx-fast), border-color var(--icen-tx-fast);
223
250
  }
224
- .icen-chart-zoom-reset:hover { color: var(--icen-token-text); background: var(--icen-token-fill-2); }
251
+ .icen-chart-zoom-reset:hover { color: var(--icen-token-text); background: var(--icen-token-fill-2); border-color: var(--icen-token-line-strong); }
252
+ .icen-chart-zoom-reset:active { background: var(--icen-token-fill-pressed); }
225
253
  .icen-chart-zoom-reset:focus-visible { outline: none; box-shadow: var(--icen-ring); }
226
254
 
227
255
  /* 缩放手势选区(拖拽期挂 body,position:fixed;accent 10% 填充) */
@@ -242,8 +270,8 @@ svg circle[data-icen-chart-mark].is-hover { stroke-width: 3; }
242
270
  height: 150px;
243
271
  }
244
272
  .icen-chart-skeleton-bar {
245
- height: 10px;
246
- border-radius: var(--icen-radius-sm);
273
+ height: 8px;
274
+ border-radius: var(--icen-radius-xs);
247
275
  background: color-mix(in srgb, var(--icen-token-text) 8%, transparent);
248
276
  animation: icen-skeleton-pulse var(--skeleton-duration, 2s) ease-in-out infinite;
249
277
  }
@@ -278,12 +306,29 @@ svg .icen-chart-mark-label {
278
306
  cursor: pointer;
279
307
  }
280
308
  .icen-chart-map-dot {
281
- transition: transform var(--icen-tx-fast);
309
+ transition: transform var(--icen-duration-fast) var(--icen-ease-out), fill-opacity var(--icen-tx-fast);
282
310
  transform-box: fill-box;
283
311
  transform-origin: center;
284
312
  }
285
313
  .icen-chart-map-point.is-hover .icen-chart-map-dot {
286
314
  transform: scale(1.5);
315
+ fill-opacity: 0.9;
316
+ }
317
+
318
+ /* 高对比模式:图表配色由系统接管,只保留结构可辨的最小描边 */
319
+ @media (forced-colors: active) {
320
+ .icen-chart-tooltip {
321
+ background: Canvas;
322
+ border-color: CanvasText;
323
+ box-shadow: none;
324
+ -webkit-backdrop-filter: none;
325
+ backdrop-filter: none;
326
+ }
327
+ .icen-chart-legend-dot,
328
+ .icen-chart-legend--toggle .icen-chart-legend-dot {
329
+ border: 1px solid CanvasText;
330
+ }
331
+ .icen-chart-zoom-reset { border-color: CanvasText; }
287
332
  }
288
333
 
289
334
  @media (prefers-reduced-motion: reduce) {
@@ -292,4 +337,33 @@ svg .icen-chart-mark-label {
292
337
  }
293
338
  }
294
339
 
340
+ /* ── 键盘游标与读屏层(spec.a11y:summary/keyboard/table) ──
341
+ 自包含 sr-only 几何(kit 独立引入时 base.css 可能缺席,不依赖 .icen-sr-only) */
342
+ .icen-chart-summary,
343
+ .icen-chart-live,
344
+ .icen-chart-table {
345
+ position: absolute;
346
+ width: 1px; height: 1px;
347
+ padding: 0; margin: -1px;
348
+ overflow: hidden;
349
+ clip: rect(0, 0, 0, 0);
350
+ clip-path: inset(50%);
351
+ white-space: nowrap;
352
+ border: 0;
353
+ }
354
+ /* 键盘游标入口:图形可聚焦,焦点环走统一 ring 令牌 */
355
+ [data-icen-chart-kb] { outline: none; }
356
+ [data-icen-chart-kb]:focus-visible { box-shadow: var(--icen-ring); border-radius: var(--icen-radius-xs); }
357
+ /* 游标焦点:DOM 柱条用轮廓环;SVG 点圆放大描边(r 为 SVG2 几何属性,不支持时退化为描边加粗) */
358
+ .icen-chart-kb-focus {
359
+ outline: 2px solid var(--icen-token-accent);
360
+ outline-offset: 1px;
361
+ border-radius: var(--icen-radius-xs);
362
+ }
363
+ circle.icen-chart-kb-focus {
364
+ outline: none;
365
+ stroke-width: 3px;
366
+ r: 5px;
367
+ }
368
+
295
369
  }
@@ -0,0 +1,2 @@
1
+ // kit: charts 类型面(构建产物,勿手改)
2
+ export * from '../behaviors/charts.mjs';
@@ -46,8 +46,8 @@
46
46
  /* ══════════════ 容器 ══════════════ */
47
47
 
48
48
  .icen-code-block {
49
- border: 1px solid var(--icen-token-line-soft);
50
- border-radius: var(--icen-radius-lg);
49
+ border: 1px solid var(--icen-token-separator-soft);
50
+ border-radius: var(--icen-control-radius-lg);
51
51
  background: var(--cb-background, var(--icen-token-surface));
52
52
  overflow: hidden;
53
53
  }
@@ -56,12 +56,12 @@
56
56
  margin: 0;
57
57
  border: 0;
58
58
  border-radius: 0;
59
- padding: var(--icen-density-space-sm) 0;
59
+ padding: 10px 0;
60
60
  background: transparent !important; /* guard:allow-important shiki 主题自带内联背景,容器统一接管 */
61
61
  color: var(--icen-token-text);
62
62
  font-family: var(--icen-font-mono);
63
- font-size: var(--icen-density-font-size-md);
64
- line-height: 1.5;
63
+ font-size: 12px;
64
+ line-height: 1.6;
65
65
  overflow-x: auto;
66
66
  transition: max-height var(--icen-duration-slow) var(--icen-ease-out);
67
67
  direction: ltr;
@@ -83,9 +83,11 @@
83
83
  display: flex;
84
84
  align-items: center;
85
85
  gap: var(--icen-density-space-md);
86
- padding: var(--icen-density-space-sm) var(--icen-density-space-md);
87
- border-bottom: 1px solid var(--icen-token-line-soft);
88
- font-size: var(--icen-density-font-size-sm);
86
+ min-block-size: 34px;
87
+ padding: 0 var(--icen-density-space-md);
88
+ background: var(--icen-token-surface-chrome);
89
+ border-bottom: 1px solid var(--icen-token-separator-soft);
90
+ font-size: 11.5px;
89
91
  line-height: 1.4;
90
92
  color: var(--icen-token-text-muted);
91
93
  }
@@ -0,0 +1,2 @@
1
+ // kit: code-block 类型面(构建产物,勿手改)
2
+ export * from '../behaviors/code-block.mjs';
@@ -47,12 +47,12 @@
47
47
  justify-content: center;
48
48
  padding-top: 12vh;
49
49
  padding-inline: var(--icen-density-space-md);
50
- background: color-mix(in srgb, var(--icen-token-text) 40%, transparent);
51
- backdrop-filter: blur(4px);
52
- -webkit-backdrop-filter: blur(4px);
50
+ background: var(--icen-token-scrim);
51
+ backdrop-filter: none;
52
+ -webkit-backdrop-filter: none;
53
53
  animation: icen-cp-fade-in var(--icen-tx-fast);
54
54
  /* 退场走过渡(behavior 的 closing 阶段;可中断续接) */
55
- transition: opacity var(--icen-tx-fast) var(--icen-ease-out);
55
+ transition: opacity var(--icen-duration-fast) var(--icen-ease-out);
56
56
  }
57
57
  .icen-command-palette-backdrop[hidden] { display: none; }
58
58
  .icen-command-palette-backdrop[data-icen-state='closing'] {
@@ -68,12 +68,12 @@
68
68
  max-inline-size: 560px;
69
69
  max-block-size: 70vh;
70
70
  overflow: hidden;
71
- background: var(--icen-token-card-strong);
72
- border: 1px solid var(--icen-token-outline);
71
+ background: var(--icen-token-surface);
72
+ border: 1px solid var(--icen-token-material-edge);
73
73
  border-radius: var(--icen-radius-lg);
74
- box-shadow: var(--icen-token-shadow-overlay);
75
- animation: icen-cp-scale-in var(--icen-tx-fast) var(--icen-ease-out);
76
- transition: transform var(--icen-tx-fast) var(--icen-ease-out);
74
+ box-shadow: var(--icen-token-material-light), var(--icen-token-shadow-overlay);
75
+ animation: icen-cp-scale-in var(--icen-duration-normal) var(--icen-ease-enter);
76
+ transition: transform var(--icen-duration-fast) var(--icen-ease-exit);
77
77
  }
78
78
  .icen-command-palette-backdrop[data-icen-state='closing'] .icen-command-palette {
79
79
  transform: translateY(2px) scale(0.99);
@@ -85,17 +85,18 @@
85
85
  display: flex;
86
86
  align-items: center;
87
87
  gap: var(--icen-density-space-sm);
88
- padding: var(--icen-density-space-md);
89
- border-bottom: 1px solid var(--icen-token-line-soft);
88
+ min-block-size: 48px;
89
+ padding: 8px var(--icen-density-space-md);
90
+ border-bottom: 1px solid var(--icen-token-separator-soft);
90
91
  }
91
92
  .icen-command-palette-search-icon {
92
93
  display: inline-flex;
93
94
  align-items: center;
94
95
  justify-content: center;
95
- color: var(--icen-token-text-faint);
96
+ color: var(--icen-token-text-muted);
96
97
  flex-shrink: 0;
97
98
  }
98
- .icen-command-palette-search-icon svg { width: 16px; height: 16px; }
99
+ .icen-command-palette-search-icon svg { width: 18px; height: 18px; }
99
100
  .icen-command-palette-input {
100
101
  flex: 1;
101
102
  min-width: 0;
@@ -104,17 +105,23 @@
104
105
  background: transparent;
105
106
  color: var(--icen-token-text);
106
107
  font: inherit;
107
- font-size: var(--icen-density-font-size-md);
108
+ font-size: var(--icen-density-font-size-lg);
109
+ }
110
+ /* 搜索栏不是 .icen-control(吃不到全局 focus-within 环):输入框是开面板即聚焦的
111
+ 主控件,焦点可见性自持——包裹层给 focus-within 软环 */
112
+ .icen-command-palette-search:focus-within {
113
+ box-shadow: inset 0 -2px 0 color-mix(in srgb, var(--icen-token-accent) 30%, transparent);
114
+ border-radius: 0;
108
115
  }
109
116
  .icen-command-palette-input::placeholder {
110
- color: color-mix(in srgb, var(--icen-token-text-faint) 60%, transparent);
117
+ color: var(--icen-token-text-muted);
111
118
  }
112
119
  .icen-command-palette-esc {
113
120
  font-family: var(--icen-font-mono);
114
121
  font-size: var(--icen-density-font-size-xs);
115
- color: var(--icen-token-text-faint);
122
+ color: var(--icen-token-text-muted);
116
123
  padding: 2px 6px;
117
- border: 1px solid var(--icen-token-line-soft);
124
+ border: 1px solid var(--icen-token-control-border);
118
125
  border-radius: var(--icen-radius-xs);
119
126
  flex-shrink: 0;
120
127
  }
@@ -136,38 +143,38 @@
136
143
  }
137
144
  .icen-command-palette-group:last-child { margin-bottom: 0; }
138
145
  .icen-command-palette-group-label {
139
- margin: var(--icen-density-space-sm) var(--icen-density-space-sm) var(--icen-density-space-xs);
140
- font-size: var(--icen-density-font-size-xs);
146
+ margin: var(--icen-density-space-sm) var(--icen-density-space-sm) 3px;
147
+ font-size: var(--icen-font-size-caption);
141
148
  font-weight: 600;
142
- color: var(--icen-token-text-faint);
143
- letter-spacing: 0.06em;
144
- text-transform: uppercase;
149
+ color: var(--icen-token-text-muted);
150
+ letter-spacing: var(--icen-letter-spacing-caption);
145
151
  }
146
152
  .icen-command-palette-group:first-child .icen-command-palette-group-label { margin-top: 0; }
147
153
 
148
154
  .icen-command-palette-item {
149
155
  display: flex;
150
156
  align-items: center;
151
- gap: var(--icen-density-space-sm);
157
+ gap: var(--icen-control-gap-sm);
152
158
  width: 100%;
153
- padding: 8px var(--icen-density-space-sm);
159
+ min-block-size: var(--icen-control-height-sm);
160
+ padding: 5px var(--icen-density-space-sm);
154
161
  border: 0;
155
- border-radius: var(--icen-radius-sm);
162
+ border-radius: var(--icen-radius-xs);
156
163
  background: transparent;
157
164
  color: var(--icen-token-text);
158
165
  font: inherit;
159
- font-size: var(--icen-density-font-size-md);
166
+ font-size: var(--icen-font-size-control);
160
167
  text-align: start;
161
168
  cursor: pointer;
162
169
  -webkit-tap-highlight-color: transparent;
163
170
  transition: background-color var(--icen-tx-fast);
164
171
  }
165
- .icen-command-palette-item:hover { background: var(--icen-token-fill-1); }
172
+ .icen-command-palette-item:hover { background: var(--icen-token-fill-hover); }
166
173
  .icen-command-palette-item.is-active {
167
- /* 当前候选 = 选中表面(accent 微底 + 内描边),不改文字色;与菜单/选择器同语言 */
168
- background: var(--icen-token-accent-subtle);
174
+ /* 当前候选 = 选中表面;与菜单/选择器同语言 */
175
+ background: var(--icen-token-fill-selected);
169
176
  color: var(--icen-token-text);
170
- box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--icen-token-accent) 65%, var(--icen-token-line-soft));
177
+ box-shadow: none;
171
178
  }
172
179
  .icen-command-palette-item:focus-visible {
173
180
  outline: none;
@@ -181,9 +188,9 @@
181
188
  flex-shrink: 0;
182
189
  width: 18px;
183
190
  height: 18px;
184
- color: var(--icen-token-text-faint);
191
+ color: var(--icen-token-text-muted);
185
192
  }
186
- .icen-command-palette-item.is-active .icen-command-palette-item-icon { color: var(--icen-token-accent); }
193
+ .icen-command-palette-item.is-active .icen-command-palette-item-icon { color: var(--icen-token-accent-strong); }
187
194
  .icen-command-palette-item-icon svg { width: 16px; height: 16px; }
188
195
  .icen-command-palette-item-label {
189
196
  flex: 1;
@@ -221,22 +228,22 @@
221
228
 
222
229
  /* ── 底栏 ── */
223
230
  .icen-command-palette-foot {
224
- padding: var(--icen-density-space-xs) var(--icen-density-space-md);
225
- border-top: 1px solid var(--icen-token-line-soft);
226
- background: var(--icen-token-bg-soft);
231
+ padding: 6px var(--icen-density-space-md);
232
+ border-top: 1px solid var(--icen-token-separator-soft);
233
+ background: var(--icen-token-surface-chrome);
227
234
  }
228
235
  .icen-command-palette-foot-hint {
229
236
  display: inline-flex;
230
237
  align-items: center;
231
238
  gap: var(--icen-density-space-sm);
232
239
  font-size: var(--icen-density-font-size-xs);
233
- color: var(--icen-token-text-faint);
240
+ color: var(--icen-token-text-muted);
234
241
  }
235
242
  .icen-command-palette-foot-hint kbd {
236
243
  font-family: var(--icen-font-mono);
237
244
  font-size: var(--icen-density-font-size-2xs);
238
245
  padding: 1px 4px;
239
- border: 1px solid var(--icen-token-line-soft);
246
+ border: 1px solid var(--icen-token-control-border);
240
247
  border-radius: var(--icen-radius-xs);
241
248
  background: var(--icen-token-surface);
242
249
  }
@@ -246,7 +253,7 @@
246
253
  to { opacity: 1; }
247
254
  }
248
255
  @keyframes icen-cp-scale-in {
249
- from { opacity: 0; transform: translateY(-6px) scale(0.985); }
256
+ from { opacity: 0; transform: translateY(-4px) scale(0.985); }
250
257
  to { opacity: 1; transform: translateY(0) scale(1); }
251
258
  }
252
259
 
@@ -0,0 +1,2 @@
1
+ // kit: command-palette 类型面(构建产物,勿手改)
2
+ export * from '../behaviors/command-palette.mjs';