@icen.ai/ui 0.10.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.
- package/AGENTS.md +79 -309
- package/LICENSE +21 -0
- package/README.md +43 -54
- package/dist/base.css +57 -16
- package/dist/behaviors/accordion.mjs +1 -1
- package/dist/behaviors/ai-branch.mjs +1 -0
- package/dist/behaviors/ai-chat.d.mts +2 -2
- package/dist/behaviors/ai-chat.mjs +53 -10
- package/dist/behaviors/ai-composer.d.mts +5 -5
- package/dist/behaviors/ai-composer.mjs +21 -10
- package/dist/behaviors/ai-core.mjs +1 -0
- package/dist/behaviors/ai-diff.mjs +1 -0
- package/dist/behaviors/ai-feedback.mjs +1 -0
- package/dist/behaviors/ai-panel.d.mts +2 -2
- package/dist/behaviors/ai-panel.mjs +1 -0
- package/dist/behaviors/ai-provider.d.mts +1 -1
- package/dist/behaviors/ai-provider.mjs +1 -0
- package/dist/behaviors/ai-threads.mjs +1 -0
- package/dist/behaviors/ai-tool.d.mts +1 -1
- package/dist/behaviors/ai-tool.mjs +57 -24
- package/dist/behaviors/ai-tools.mjs +937 -28
- package/dist/behaviors/autocomplete.d.mts +1 -1
- package/dist/behaviors/autocomplete.mjs +1 -0
- package/dist/behaviors/back-top.mjs +1 -0
- package/dist/behaviors/carousel.mjs +8 -1
- package/dist/behaviors/cascader.mjs +14 -0
- package/dist/behaviors/charts.mjs +56 -20
- package/dist/behaviors/code-block.mjs +9 -1
- package/dist/behaviors/command-palette.mjs +3 -3
- package/dist/behaviors/context-menu.d.mts +2 -2
- package/dist/behaviors/context-menu.mjs +1 -0
- package/dist/behaviors/controls.d.mts +8 -8
- package/dist/behaviors/controls.mjs +37 -6
- package/dist/behaviors/copy.mjs +1 -0
- package/dist/behaviors/datatable.d.mts +3 -3
- package/dist/behaviors/datatable.mjs +76 -11
- package/dist/behaviors/date-picker.mjs +1 -0
- package/dist/behaviors/events.d.mts +10 -10
- package/dist/behaviors/events.mjs +11 -1
- package/dist/behaviors/form-validate.d.mts +10 -1
- package/dist/behaviors/form-validate.mjs +266 -4611
- package/dist/behaviors/i18n.d.mts +1 -0
- package/dist/behaviors/i18n.mjs +2 -0
- package/dist/behaviors/input.mjs +3 -0
- package/dist/behaviors/kb-access.d.mts +2 -2
- package/dist/behaviors/kb-access.mjs +8 -2
- package/dist/behaviors/kb-acl.d.mts +2 -2
- package/dist/behaviors/kb-acl.mjs +1 -0
- package/dist/behaviors/kb-answer.d.mts +2 -2
- package/dist/behaviors/kb-answer.mjs +56 -23
- package/dist/behaviors/kb-audit.d.mts +2 -2
- package/dist/behaviors/kb-audit.mjs +1 -0
- package/dist/behaviors/kb-canvas.d.mts +3 -3
- package/dist/behaviors/kb-canvas.mjs +1 -0
- package/dist/behaviors/kb-chain.d.mts +2 -2
- package/dist/behaviors/kb-chain.mjs +1 -0
- package/dist/behaviors/kb-checkpoint.d.mts +2 -2
- package/dist/behaviors/kb-checkpoint.mjs +1 -0
- package/dist/behaviors/kb-chunks.d.mts +2 -2
- package/dist/behaviors/kb-chunks.mjs +1 -0
- package/dist/behaviors/kb-citation.d.mts +2 -2
- package/dist/behaviors/kb-citation.mjs +20 -6
- package/dist/behaviors/kb-clarify.d.mts +2 -2
- package/dist/behaviors/kb-clarify.mjs +1 -0
- package/dist/behaviors/kb-conflict.d.mts +2 -2
- package/dist/behaviors/kb-conflict.mjs +1 -0
- package/dist/behaviors/kb-connector.d.mts +2 -2
- package/dist/behaviors/kb-connector.mjs +1 -0
- package/dist/behaviors/kb-core.d.mts +1 -1
- package/dist/behaviors/kb-core.mjs +1 -0
- package/dist/behaviors/kb-eval.d.mts +2 -2
- package/dist/behaviors/kb-eval.mjs +8 -2
- package/dist/behaviors/kb-explain.d.mts +2 -2
- package/dist/behaviors/kb-explain.mjs +13 -2
- package/dist/behaviors/kb-filter.d.mts +2 -2
- package/dist/behaviors/kb-filter.mjs +8 -2
- package/dist/behaviors/kb-gap.d.mts +2 -2
- package/dist/behaviors/kb-gap.mjs +1 -0
- package/dist/behaviors/kb-hittest.d.mts +2 -2
- package/dist/behaviors/kb-hittest.mjs +2 -1
- package/dist/behaviors/kb-metadata.mjs +6 -0
- package/dist/behaviors/kb-passage.d.mts +2 -2
- package/dist/behaviors/kb-passage.mjs +1 -0
- package/dist/behaviors/kb-pipeline.d.mts +2 -2
- package/dist/behaviors/kb-pipeline.mjs +1 -0
- package/dist/behaviors/kb-qa.mjs +1 -0
- package/dist/behaviors/kb-rerank.d.mts +2 -2
- package/dist/behaviors/kb-rerank.mjs +1 -0
- package/dist/behaviors/kb-retrieval.d.mts +2 -2
- package/dist/behaviors/kb-retrieval.mjs +18 -4
- package/dist/behaviors/kb-review.d.mts +2 -2
- package/dist/behaviors/kb-review.mjs +8 -2
- package/dist/behaviors/kb-sandbox.d.mts +2 -2
- package/dist/behaviors/kb-sandbox.mjs +7 -1
- package/dist/behaviors/kb-segment.d.mts +2 -2
- package/dist/behaviors/kb-segment.mjs +2 -1
- package/dist/behaviors/kb-select.mjs +8 -2
- package/dist/behaviors/kb-sources.d.mts +2 -2
- package/dist/behaviors/kb-sources.mjs +1 -0
- package/dist/behaviors/kb-sql.d.mts +2 -2
- package/dist/behaviors/kb-sql.mjs +1 -0
- package/dist/behaviors/kb-trace.d.mts +2 -2
- package/dist/behaviors/kb-trace.mjs +9 -3
- package/dist/behaviors/kb-visibility.d.mts +2 -2
- package/dist/behaviors/kb-visibility.mjs +1 -0
- package/dist/behaviors/kb-who-can.d.mts +2 -2
- package/dist/behaviors/kb-who-can.mjs +8 -2
- package/dist/behaviors/mentions.d.mts +1 -1
- package/dist/behaviors/mentions.mjs +1 -0
- package/dist/behaviors/modal.d.mts +1 -1
- package/dist/behaviors/modal.mjs +1 -0
- package/dist/behaviors/notification.d.mts +2 -2
- package/dist/behaviors/notification.mjs +14 -3
- package/dist/behaviors/panel.mjs +1 -0
- package/dist/behaviors/scroll-area.d.mts +17 -0
- package/dist/behaviors/scroll-area.mjs +59 -0
- package/dist/behaviors/select.mjs +8 -2
- package/dist/behaviors/slider.mjs +3 -3
- package/dist/behaviors/split-pane.mjs +2 -0
- package/dist/behaviors/suggestions.mjs +1 -0
- package/dist/behaviors/tabs.mjs +10 -0
- package/dist/behaviors/tag-input.mjs +1 -0
- package/dist/behaviors/theme-switcher.d.mts +2 -2
- package/dist/behaviors/theme-switcher.mjs +17 -2
- package/dist/behaviors/theme.mjs +16 -2
- package/dist/behaviors/toast.d.mts +2 -2
- package/dist/behaviors/toast.mjs +1 -0
- package/dist/behaviors/tree-select.mjs +14 -0
- package/dist/behaviors/tree.mjs +4 -4
- package/dist/behaviors/upload.mjs +1 -0
- package/dist/behaviors/url-safety.d.mts +8 -0
- package/dist/behaviors/url-safety.mjs +11 -0
- package/dist/components/accordion.d.mts +2 -0
- package/dist/components/ai-branch.d.mts +2 -0
- package/dist/components/ai-chat.css +40 -33
- package/dist/components/ai-chat.d.mts +2 -0
- package/dist/components/ai-composer.d.mts +2 -0
- package/dist/components/ai-context.d.mts +2 -0
- package/dist/components/ai-context.mjs +1 -0
- package/dist/components/ai-diff.css +6 -6
- package/dist/components/ai-diff.d.mts +2 -0
- package/dist/components/ai-feedback.d.mts +2 -0
- package/dist/components/ai-files.d.mts +2 -0
- package/dist/components/ai-message.d.mts +2 -0
- package/dist/components/ai-panel.css +12 -10
- package/dist/components/ai-reasoning.d.mts +2 -0
- package/dist/components/ai-subagent.d.mts +2 -0
- package/dist/components/ai-subagent.mjs +1 -0
- package/dist/components/ai-threads.d.mts +2 -0
- package/dist/components/ai-todo.d.mts +2 -0
- package/dist/components/ai-todo.mjs +1 -0
- package/dist/components/ai-tool-call.d.mts +2 -0
- package/dist/components/ai-tool-call.mjs +1 -0
- package/dist/components/ai-tool.css +16 -16
- package/dist/components/ai-usage.d.mts +2 -0
- package/dist/components/alert.d.mts +2 -0
- package/dist/components/autocomplete.css +12 -12
- package/dist/components/autocomplete.d.mts +2 -0
- package/dist/components/avatar.d.mts +2 -0
- package/dist/components/back-top.css +47 -16
- package/dist/components/back-top.d.mts +2 -0
- package/dist/components/badge.css +1 -1
- package/dist/components/badge.d.mts +2 -0
- package/dist/components/breadcrumb.css +26 -8
- package/dist/components/breadcrumb.d.mts +2 -0
- package/dist/components/btn.css +67 -62
- package/dist/components/btn.d.mts +2 -0
- package/dist/components/card.css +22 -22
- package/dist/components/card.d.mts +2 -0
- package/dist/components/carousel.d.mts +2 -0
- package/dist/components/cascader.css +56 -35
- package/dist/components/cascader.d.mts +2 -0
- package/dist/components/chart-area.css +46 -0
- package/dist/components/chart-area.d.mts +2 -0
- package/dist/components/chart-bar.css +66 -19
- package/dist/components/chart-bar.d.mts +2 -0
- package/dist/components/chart-calendar.d.mts +2 -0
- package/dist/components/chart-gauge.css +23 -3
- package/dist/components/chart-gauge.d.mts +2 -0
- package/dist/components/chart-graph.css +15 -3
- package/dist/components/chart-graph.d.mts +2 -0
- package/dist/components/chart-heatmap.css +117 -95
- package/dist/components/chart-heatmap.d.mts +2 -0
- package/dist/components/chart-line.css +54 -0
- package/dist/components/chart-line.d.mts +2 -0
- package/dist/components/chart-map.d.mts +2 -0
- package/dist/components/chart-pie.css +29 -0
- package/dist/components/chart-pie.d.mts +2 -0
- package/dist/components/chart-radar.css +50 -1
- package/dist/components/chart-radar.d.mts +2 -0
- package/dist/components/chart-scatter.css +39 -2
- package/dist/components/chart-scatter.d.mts +2 -0
- package/dist/components/chart-sparkline.css +20 -0
- package/dist/components/chart-sparkline.d.mts +2 -0
- package/dist/components/chart-stack.css +16 -5
- package/dist/components/chart-stack.d.mts +2 -0
- package/dist/components/charts.css +80 -35
- package/dist/components/charts.d.mts +2 -0
- package/dist/components/code-block.css +10 -8
- package/dist/components/code-block.d.mts +2 -0
- package/dist/components/command-palette.css +45 -38
- package/dist/components/command-palette.d.mts +2 -0
- package/dist/components/content.css +62 -57
- package/dist/components/context-menu.d.mts +2 -0
- package/dist/components/copy.css +10 -10
- package/dist/components/copy.d.mts +2 -0
- package/dist/components/datatable.css +72 -59
- package/dist/components/datatable.d.mts +2 -0
- package/dist/components/date-picker.css +26 -26
- package/dist/components/date-picker.d.mts +2 -0
- package/dist/components/desc.d.mts +2 -0
- package/dist/components/dropdown.d.mts +2 -0
- package/dist/components/empty.css +16 -16
- package/dist/components/empty.d.mts +2 -0
- package/dist/components/feedback.css +31 -29
- package/dist/components/form-validate.css +20 -6
- package/dist/components/form-validate.d.mts +2 -0
- package/dist/components/form.css +17 -14
- package/dist/components/form.d.mts +2 -0
- package/dist/components/icon.css +21 -10
- package/dist/components/icon.d.mts +2 -0
- package/dist/components/input.css +22 -22
- package/dist/components/input.d.mts +2 -0
- package/dist/components/kb-access.d.mts +2 -0
- package/dist/components/kb-acl.d.mts +2 -0
- package/dist/components/kb-agent.css +134 -55
- package/dist/components/kb-answer.d.mts +2 -0
- package/dist/components/kb-audit.d.mts +2 -0
- package/dist/components/kb-canvas.d.mts +2 -0
- package/dist/components/kb-chain.d.mts +2 -0
- package/dist/components/kb-checkpoint.d.mts +2 -0
- package/dist/components/kb-chunks.d.mts +2 -0
- package/dist/components/kb-citation.d.mts +2 -0
- package/dist/components/kb-clarify.d.mts +2 -0
- package/dist/components/kb-conflict.d.mts +2 -0
- package/dist/components/kb-connector.d.mts +2 -0
- package/dist/components/kb-data.css +192 -80
- package/dist/components/kb-eval.d.mts +2 -0
- package/dist/components/kb-explain.d.mts +2 -0
- package/dist/components/kb-filter.d.mts +2 -0
- package/dist/components/kb-gap.d.mts +2 -0
- package/dist/components/kb-ground.css +165 -73
- package/dist/components/kb-hittest.d.mts +2 -0
- package/dist/components/kb-ingest.css +308 -113
- package/dist/components/kb-metadata.d.mts +2 -0
- package/dist/components/kb-ops.css +189 -75
- package/dist/components/kb-passage.d.mts +2 -0
- package/dist/components/kb-perm.css +158 -87
- package/dist/components/kb-pipeline.d.mts +2 -0
- package/dist/components/kb-qa.d.mts +2 -0
- package/dist/components/kb-rerank.d.mts +2 -0
- package/dist/components/kb-retrieval.d.mts +2 -0
- package/dist/components/kb-review.d.mts +2 -0
- package/dist/components/kb-sandbox.d.mts +2 -0
- package/dist/components/kb-search.css +353 -116
- package/dist/components/kb-segment.d.mts +2 -0
- package/dist/components/kb-sources.d.mts +2 -0
- package/dist/components/kb-sql.d.mts +2 -0
- package/dist/components/kb-trace.d.mts +2 -0
- package/dist/components/kb-visibility.d.mts +2 -0
- package/dist/components/kb-who-can.d.mts +2 -0
- package/dist/components/kb.css +60 -36
- package/dist/components/kb.d.mts +2 -0
- package/dist/components/kbd.d.mts +2 -0
- package/dist/components/layout.css +10 -10
- package/dist/components/layout.d.mts +2 -0
- package/dist/components/list.d.mts +2 -0
- package/dist/components/material-chinese.css +10 -0
- package/dist/components/material-soviet.css +10 -0
- package/dist/components/material.css +61 -18
- package/dist/components/media-card.d.mts +2 -0
- package/dist/components/media.css +22 -27
- package/dist/components/mentions.css +18 -17
- package/dist/components/mentions.d.mts +2 -0
- package/dist/components/menu.css +32 -28
- package/dist/components/modal.css +30 -27
- package/dist/components/modal.d.mts +2 -0
- package/dist/components/nav.css +48 -44
- package/dist/components/nav.d.mts +2 -0
- package/dist/components/notification.css +31 -25
- package/dist/components/notification.d.mts +2 -0
- package/dist/components/pagination.css +15 -13
- package/dist/components/pagination.d.mts +2 -0
- package/dist/components/panel.css +19 -20
- package/dist/components/panel.d.mts +2 -0
- package/dist/components/pill.css +8 -7
- package/dist/components/pill.d.mts +2 -0
- package/dist/components/popover.css +32 -23
- package/dist/components/popover.d.mts +2 -0
- package/dist/components/progress.d.mts +2 -0
- package/dist/components/rating.d.mts +2 -0
- package/dist/components/result.d.mts +2 -0
- package/dist/components/scroll-area.css +84 -112
- package/dist/components/scroll-area.d.mts +2 -0
- package/dist/components/scroll-area.mjs +1 -0
- package/dist/components/segmented.css +47 -29
- package/dist/components/segmented.d.mts +2 -0
- package/dist/components/select.css +80 -41
- package/dist/components/select.d.mts +2 -0
- package/dist/components/sidebar.css +42 -38
- package/dist/components/sidebar.d.mts +2 -0
- package/dist/components/skeleton.d.mts +2 -0
- package/dist/components/slider.css +26 -22
- package/dist/components/slider.d.mts +2 -0
- package/dist/components/spinner.d.mts +2 -0
- package/dist/components/split-pane.css +16 -7
- package/dist/components/split-pane.d.mts +2 -0
- package/dist/components/stat.css +17 -16
- package/dist/components/stat.d.mts +2 -0
- package/dist/components/steps.css +26 -26
- package/dist/components/steps.d.mts +2 -0
- package/dist/components/switch.css +78 -39
- package/dist/components/switch.d.mts +2 -0
- package/dist/components/table.css +54 -32
- package/dist/components/table.d.mts +2 -0
- package/dist/components/tabs.css +53 -32
- package/dist/components/tabs.d.mts +2 -0
- package/dist/components/tag-input.css +12 -8
- package/dist/components/tag-input.d.mts +2 -0
- package/dist/components/tag.css +20 -12
- package/dist/components/tag.d.mts +2 -0
- package/dist/components/theme-switcher.css +7 -7
- package/dist/components/theme-switcher.d.mts +2 -0
- package/dist/components/timeline.d.mts +2 -0
- package/dist/components/toast.css +34 -30
- package/dist/components/toast.d.mts +2 -0
- package/dist/components/toolbar.css +19 -18
- package/dist/components/toolbar.d.mts +2 -0
- package/dist/components/tooltip.css +9 -8
- package/dist/components/tooltip.d.mts +2 -0
- package/dist/components/tree-select.css +63 -40
- package/dist/components/tree-select.d.mts +2 -0
- package/dist/components/tree.d.mts +2 -0
- package/dist/components/upload.css +9 -11
- package/dist/components/upload.d.mts +2 -0
- package/dist/index.d.mts +85 -84
- package/dist/index.mjs +14764 -14311
- package/dist/react.d.mts +18 -18
- package/dist/react.mjs +135 -36
- package/dist/registry.json +795 -64
- package/dist/tokens/colors.css +6 -0
- package/dist/tokens/design.css +130 -30
- package/dist/tokens/dtcg.json +6189 -1461
- package/dist/tokens/figma.variables.json +4107 -345
- package/dist/tokens/pixel.css +3 -0
- package/dist/tokens/scrollbars.css +40 -0
- package/dist/tokens/tokens-studio.json +5191 -271
- package/dist/tokens.css +304 -81
- package/dist/ui.css +4050 -2148
- package/dist/vue.d.mts +17 -17
- package/dist/vue.mjs +129 -34
- package/docs/spec/design-philosophy.md +5 -5
- package/docs/spec/design-primitives.md +10 -10
- package/docs/spec/scrollbars.md +46 -0
- package/package.json +16 -3
|
@@ -22,26 +22,35 @@
|
|
|
22
22
|
position: relative;
|
|
23
23
|
display: flex;
|
|
24
24
|
align-items: flex-end;
|
|
25
|
-
gap:
|
|
25
|
+
gap: 4px;
|
|
26
26
|
height: 112px;
|
|
27
27
|
}
|
|
28
|
+
/* 轨道同时承担两件事:极淡的槽 + 四档横向网格(柱体覆盖网格,空白区仍可读数) */
|
|
28
29
|
.icen-chart-vbar-track {
|
|
29
30
|
flex: 1;
|
|
30
|
-
height: 100%;
|
|
31
31
|
min-width: 0;
|
|
32
|
+
height: 100%;
|
|
32
33
|
display: flex;
|
|
33
34
|
align-items: flex-end;
|
|
34
|
-
background: color-mix(in srgb, var(--icen-token-fill-2) 45%, transparent);
|
|
35
|
-
border-radius: var(--icen-radius-sm);
|
|
36
35
|
overflow: hidden;
|
|
36
|
+
border-radius: var(--icen-radius-xs);
|
|
37
|
+
background:
|
|
38
|
+
repeating-linear-gradient(
|
|
39
|
+
to top,
|
|
40
|
+
color-mix(in srgb, var(--icen-token-line-soft) 90%, transparent) 0 1px,
|
|
41
|
+
transparent 1px 25%
|
|
42
|
+
),
|
|
43
|
+
color-mix(in srgb, var(--icen-token-fill-2) 34%, transparent);
|
|
37
44
|
}
|
|
38
45
|
.icen-chart-vbar-bar {
|
|
39
46
|
width: 100%;
|
|
40
|
-
border-radius: var(--icen-radius-
|
|
47
|
+
border-radius: var(--icen-radius-xs);
|
|
41
48
|
background: var(--chart-tone, var(--icen-token-accent));
|
|
42
|
-
|
|
49
|
+
box-shadow: inset 0 1px 0 color-mix(in srgb, var(--icen-token-top-highlight) 55%, transparent);
|
|
50
|
+
transition: height var(--icen-duration-slow) var(--icen-ease-out), filter var(--icen-tx-fast);
|
|
43
51
|
}
|
|
44
|
-
.icen-chart-vbar-bar:hover
|
|
52
|
+
.icen-chart-vbar-bar:hover,
|
|
53
|
+
.icen-chart-vbar-bar.is-hover {
|
|
45
54
|
filter: brightness(1.08);
|
|
46
55
|
}
|
|
47
56
|
|
|
@@ -49,14 +58,22 @@
|
|
|
49
58
|
.icen-chart-hbar {
|
|
50
59
|
display: flex;
|
|
51
60
|
flex-direction: column;
|
|
52
|
-
gap:
|
|
61
|
+
gap: 2px;
|
|
53
62
|
}
|
|
54
63
|
.icen-chart-hbar-row {
|
|
55
64
|
display: grid;
|
|
56
|
-
grid-template-columns: minmax(72px, 1fr) minmax(90px, 2fr) 52px;
|
|
65
|
+
grid-template-columns: minmax(72px, 1fr) minmax(90px, 2fr) minmax(52px, auto); /* 数值列可长:定宽 52px 遇 "1234567.89" 会换行撑高整行错位 */
|
|
57
66
|
gap: var(--icen-density-space-xs);
|
|
58
67
|
align-items: center;
|
|
59
|
-
|
|
68
|
+
min-height: 26px;
|
|
69
|
+
padding: 0 4px;
|
|
70
|
+
margin: 0 -4px;
|
|
71
|
+
border-radius: var(--icen-radius-xs);
|
|
72
|
+
font-size: 12px;
|
|
73
|
+
transition: background-color var(--icen-tx-fast);
|
|
74
|
+
}
|
|
75
|
+
.icen-chart-hbar-row:hover {
|
|
76
|
+
background: var(--icen-token-fill-hover);
|
|
60
77
|
}
|
|
61
78
|
.icen-chart-hbar-label {
|
|
62
79
|
overflow: hidden;
|
|
@@ -65,24 +82,28 @@
|
|
|
65
82
|
color: var(--icen-token-text-muted);
|
|
66
83
|
}
|
|
67
84
|
.icen-chart-hbar-track {
|
|
68
|
-
height:
|
|
85
|
+
height: 8px;
|
|
69
86
|
overflow: hidden;
|
|
70
87
|
border-radius: var(--icen-radius-full);
|
|
71
|
-
background: var(--icen-token-fill-2);
|
|
88
|
+
background: color-mix(in srgb, var(--icen-token-fill-2) 70%, transparent);
|
|
72
89
|
}
|
|
73
90
|
.icen-chart-hbar-bar {
|
|
74
91
|
height: 100%;
|
|
75
92
|
border-radius: var(--icen-radius-full);
|
|
76
93
|
background: var(--chart-tone, var(--icen-token-accent));
|
|
77
|
-
transition: width var(--icen-
|
|
94
|
+
transition: width var(--icen-duration-slow) var(--icen-ease-out), filter var(--icen-tx-fast);
|
|
78
95
|
}
|
|
79
|
-
.icen-chart-hbar-bar:hover
|
|
96
|
+
.icen-chart-hbar-bar:hover,
|
|
97
|
+
.icen-chart-hbar-bar.is-hover {
|
|
80
98
|
filter: brightness(1.08);
|
|
81
99
|
}
|
|
82
100
|
.icen-chart-hbar-value {
|
|
83
101
|
text-align: right;
|
|
102
|
+
font-family: var(--icen-font-mono);
|
|
103
|
+
font-size: 11px;
|
|
84
104
|
font-variant-numeric: tabular-nums;
|
|
85
|
-
|
|
105
|
+
white-space: nowrap; /* 配合 minmax(52px, auto):长数值单行右对齐,不换行 */
|
|
106
|
+
color: var(--icen-token-text-muted);
|
|
86
107
|
}
|
|
87
108
|
|
|
88
109
|
@media (prefers-reduced-motion: reduce) {
|
|
@@ -96,11 +117,29 @@
|
|
|
96
117
|
flex-direction: column;
|
|
97
118
|
justify-content: flex-end;
|
|
98
119
|
gap: 0;
|
|
120
|
+
background: color-mix(in srgb, var(--icen-token-fill-2) 26%, transparent);
|
|
121
|
+
}
|
|
122
|
+
.icen-chart-vbar-track--multi.icen-chart-vbar-track--stacked > .icen-chart-vbar-bar {
|
|
123
|
+
flex: none;
|
|
124
|
+
width: 100%;
|
|
125
|
+
border-radius: 0;
|
|
126
|
+
box-shadow: none;
|
|
127
|
+
}
|
|
128
|
+
/* 堆叠两端保留外轮廓圆角,段与段之间用 2px 面色缝分界(同色相邻也辨得清) */
|
|
129
|
+
.icen-chart-vbar-track--stacked > .icen-chart-vbar-bar:first-child {
|
|
130
|
+
border-end-start-radius: var(--icen-radius-xs);
|
|
131
|
+
border-end-end-radius: var(--icen-radius-xs);
|
|
132
|
+
}
|
|
133
|
+
.icen-chart-vbar-track--stacked > .icen-chart-vbar-bar:last-child {
|
|
134
|
+
border-start-start-radius: var(--icen-radius-xs);
|
|
135
|
+
border-start-end-radius: var(--icen-radius-xs);
|
|
136
|
+
}
|
|
137
|
+
.icen-chart-vbar-track--stacked > .icen-chart-vbar-bar + .icen-chart-vbar-bar {
|
|
138
|
+
box-shadow: inset 0 2px 0 var(--icen-token-card);
|
|
99
139
|
}
|
|
100
|
-
.icen-chart-vbar-track--multi.icen-chart-vbar-track--stacked > .icen-chart-vbar-bar { flex: none; width: 100%; }
|
|
101
140
|
|
|
102
141
|
/* ── 标记线/标记点(spec.marks 的 vbar DOM 变体;--chart-mark-tone 注入标记色;
|
|
103
|
-
|
|
142
|
+
绝对定位元素无 z-index 也高于同容器内的静态条/轨,保持 DOM 顺序即叠放正确)── */
|
|
104
143
|
.icen-chart-vbar .icen-chart-mark-line {
|
|
105
144
|
position: absolute;
|
|
106
145
|
pointer-events: none;
|
|
@@ -118,8 +157,8 @@
|
|
|
118
157
|
}
|
|
119
158
|
.icen-chart-vbar .icen-chart-mark-label {
|
|
120
159
|
position: absolute;
|
|
121
|
-
font-size:
|
|
122
|
-
line-height: 1.
|
|
160
|
+
font-size: 11px;
|
|
161
|
+
line-height: 1.25;
|
|
123
162
|
color: var(--chart-mark-tone, var(--icen-token-text-muted));
|
|
124
163
|
white-space: nowrap;
|
|
125
164
|
}
|
|
@@ -148,4 +187,12 @@
|
|
|
148
187
|
transform: translateX(-50%);
|
|
149
188
|
}
|
|
150
189
|
|
|
190
|
+
@media (forced-colors: active) {
|
|
191
|
+
.icen-chart-vbar-track {
|
|
192
|
+
background: Canvas;
|
|
193
|
+
border: 1px solid CanvasText;
|
|
194
|
+
}
|
|
195
|
+
.icen-chart-hbar-track { border: 1px solid CanvasText; }
|
|
196
|
+
}
|
|
197
|
+
|
|
151
198
|
}
|
|
@@ -17,6 +17,14 @@
|
|
|
17
17
|
display: block;
|
|
18
18
|
width: 132px;
|
|
19
19
|
height: 132px;
|
|
20
|
+
overflow: visible;
|
|
21
|
+
}
|
|
22
|
+
/* 轨道与进度同宽(10);轨道压到 6 成,进度弧圆头收口 */
|
|
23
|
+
.icen-chart-gauge svg circle {
|
|
24
|
+
stroke-width: 10;
|
|
25
|
+
}
|
|
26
|
+
.icen-chart-gauge svg circle:first-of-type {
|
|
27
|
+
opacity: 0.7;
|
|
20
28
|
}
|
|
21
29
|
.icen-chart-gauge-center {
|
|
22
30
|
position: absolute;
|
|
@@ -25,17 +33,29 @@
|
|
|
25
33
|
flex-direction: column;
|
|
26
34
|
align-items: center;
|
|
27
35
|
justify-content: center;
|
|
28
|
-
gap:
|
|
36
|
+
gap: 2px;
|
|
37
|
+
text-align: center;
|
|
29
38
|
}
|
|
30
39
|
.icen-chart-gauge-value {
|
|
31
40
|
font-size: var(--icen-density-font-size-2xl);
|
|
32
|
-
font-weight:
|
|
41
|
+
font-weight: 600;
|
|
42
|
+
line-height: 1.05;
|
|
43
|
+
letter-spacing: -0.02em;
|
|
33
44
|
font-variant-numeric: tabular-nums;
|
|
34
45
|
color: var(--icen-token-text);
|
|
35
46
|
}
|
|
36
47
|
.icen-chart-gauge-label {
|
|
37
|
-
|
|
48
|
+
max-width: 88px;
|
|
49
|
+
overflow: hidden;
|
|
50
|
+
text-overflow: ellipsis;
|
|
51
|
+
white-space: nowrap;
|
|
52
|
+
font-size: 11px;
|
|
53
|
+
letter-spacing: 0.01em;
|
|
38
54
|
color: var(--icen-token-text-faint);
|
|
39
55
|
}
|
|
40
56
|
|
|
57
|
+
@media (forced-colors: active) {
|
|
58
|
+
.icen-chart-gauge svg circle:first-of-type { stroke: CanvasText; }
|
|
59
|
+
}
|
|
60
|
+
|
|
41
61
|
}
|
|
@@ -17,15 +17,18 @@
|
|
|
17
17
|
width: 100%;
|
|
18
18
|
height: auto;
|
|
19
19
|
display: block;
|
|
20
|
+
overflow: visible;
|
|
20
21
|
}
|
|
21
22
|
|
|
22
|
-
/*
|
|
23
|
+
/* 边:不参与命中(交互只留节点),任一端簇隐藏时淡化;权重宽度由行为直出 */
|
|
23
24
|
.icen-chart-graph-edge {
|
|
24
25
|
pointer-events: none;
|
|
26
|
+
stroke: var(--icen-token-line);
|
|
27
|
+
opacity: 0.9;
|
|
25
28
|
transition: opacity var(--icen-tx-fast);
|
|
26
29
|
}
|
|
27
30
|
.icen-chart-graph-edge.is-off {
|
|
28
|
-
opacity: 0.
|
|
31
|
+
opacity: 0.08;
|
|
29
32
|
}
|
|
30
33
|
|
|
31
34
|
/* 节点:拖拽抓手(触屏禁默认手势,pointer 拖拽不滚动页面) */
|
|
@@ -37,18 +40,22 @@
|
|
|
37
40
|
cursor: grabbing;
|
|
38
41
|
}
|
|
39
42
|
.icen-chart-graph-dot {
|
|
40
|
-
transition: stroke var(--icen-tx-fast), stroke-width var(--icen-tx-fast);
|
|
43
|
+
transition: stroke var(--icen-tx-fast), stroke-width var(--icen-tx-fast), filter var(--icen-tx-fast);
|
|
41
44
|
}
|
|
42
45
|
/* hover:描边换前景色(bindDatumEvents 挂 .is-hover) */
|
|
43
46
|
.icen-chart-graph-node.is-hover .icen-chart-graph-dot {
|
|
44
47
|
stroke: var(--icen-token-text);
|
|
45
48
|
stroke-width: 2;
|
|
49
|
+
filter: brightness(1.05);
|
|
46
50
|
}
|
|
47
51
|
/* 拖拽态:accent 描边 */
|
|
48
52
|
.icen-chart-graph-node.is-drag .icen-chart-graph-dot {
|
|
49
53
|
stroke: var(--icen-token-accent);
|
|
50
54
|
stroke-width: 2.5;
|
|
51
55
|
}
|
|
56
|
+
.icen-chart-graph-node.is-off {
|
|
57
|
+
opacity: 0.16;
|
|
58
|
+
}
|
|
52
59
|
|
|
53
60
|
@media (prefers-reduced-motion: reduce) {
|
|
54
61
|
.icen-chart-graph-edge,
|
|
@@ -57,4 +64,9 @@
|
|
|
57
64
|
}
|
|
58
65
|
}
|
|
59
66
|
|
|
67
|
+
@media (forced-colors: active) {
|
|
68
|
+
.icen-chart-graph-edge { stroke: GrayText; }
|
|
69
|
+
.icen-chart-graph-dot { stroke: CanvasText; }
|
|
70
|
+
}
|
|
71
|
+
|
|
60
72
|
}
|
|
@@ -1,98 +1,120 @@
|
|
|
1
1
|
@layer icen.components {
|
|
2
|
-
/*
|
|
3
|
-
* @icen.ai/ui — Component: chart-heatmap(热力图 / 贡献图专属样式)
|
|
4
|
-
* 依赖:charts.css(基座 --chart-tone)
|
|
5
|
-
*
|
|
6
|
-
* DOM 由 behaviors/charts.ts 的 renderHeatmap 构建:
|
|
7
|
-
* .icen-chart-heatmap > .icen-chart-heatmap-grid > .icen-chart-heatmap-cell[data-icen-level=0-4][.is-blank]
|
|
8
|
-
* > .icen-chart-heatmap-legend
|
|
9
|
-
* 7 行(周一→周日)× N 周列,5 档色阶(data-icen-level 0-4)。
|
|
10
|
-
*
|
|
11
|
-
* RTL 豁免(guard 文件级白名单 scripts/guard/rtl.ts):热力图格子按列号物理百分比定位
|
|
12
|
-
* (贡献图坐标系),RTL 不镜像。
|
|
13
|
-
*/
|
|
14
|
-
|
|
15
|
-
.icen-chart-heatmap {
|
|
16
|
-
display: flex;
|
|
17
|
-
flex-direction: column;
|
|
18
|
-
gap: var(--icen-density-space-xs);
|
|
19
|
-
}
|
|
20
|
-
.icen-chart-heatmap-grid {
|
|
21
|
-
display: grid;
|
|
22
|
-
grid-template-rows: repeat(7, 1fr);
|
|
23
|
-
grid-auto-flow: column;
|
|
24
|
-
grid-auto-columns: 1fr;
|
|
25
|
-
gap: 3px;
|
|
26
|
-
width: 100%;
|
|
27
|
-
}
|
|
28
|
-
.icen-chart-heatmap-cell {
|
|
29
|
-
aspect-ratio: 1;
|
|
30
|
-
border-radius: 2px;
|
|
31
2
|
/* guard:allow-radius 微构件(bar/dot/track/指示器等图形级,不属容器圆角面) */
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
.
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
.icen-chart-heatmap-
|
|
38
|
-
.icen-chart-heatmap-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
color: var(--icen-token-text-faint);
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
3
|
+
/*
|
|
4
|
+
* @icen.ai/ui — Component: chart-heatmap(热力图 / 贡献图专属样式)
|
|
5
|
+
* 依赖:charts.css(基座 --chart-tone)
|
|
6
|
+
*
|
|
7
|
+
* DOM 由 behaviors/charts.ts 的 renderHeatmap 构建:
|
|
8
|
+
* .icen-chart-heatmap > .icen-chart-heatmap-grid > .icen-chart-heatmap-cell[data-icen-level=0-4][.is-blank]
|
|
9
|
+
* > .icen-chart-heatmap-legend
|
|
10
|
+
* 7 行(周一→周日)× N 周列,5 档色阶(data-icen-level 0-4)。
|
|
11
|
+
*
|
|
12
|
+
* RTL 豁免(guard 文件级白名单 scripts/guard/rtl.ts):热力图格子按列号物理百分比定位
|
|
13
|
+
* (贡献图坐标系),RTL 不镜像。
|
|
14
|
+
*/
|
|
15
|
+
|
|
16
|
+
.icen-chart-heatmap {
|
|
17
|
+
display: flex;
|
|
18
|
+
flex-direction: column;
|
|
19
|
+
gap: 6px;
|
|
20
|
+
}
|
|
21
|
+
.icen-chart-heatmap-grid {
|
|
22
|
+
display: grid;
|
|
23
|
+
grid-template-rows: repeat(7, 1fr);
|
|
24
|
+
grid-auto-flow: column;
|
|
25
|
+
grid-auto-columns: 1fr;
|
|
26
|
+
gap: 3px;
|
|
27
|
+
width: 100%;
|
|
28
|
+
}
|
|
29
|
+
.icen-chart-heatmap-cell {
|
|
30
|
+
aspect-ratio: 1;
|
|
31
|
+
border-radius: var(--icen-radius-xs);
|
|
32
|
+
background: color-mix(in srgb, var(--icen-token-fill-2) 80%, transparent);
|
|
33
|
+
transition: box-shadow var(--icen-tx-fast), filter var(--icen-tx-fast);
|
|
34
|
+
}
|
|
35
|
+
.icen-chart-heatmap-cell.is-blank { background: transparent; }
|
|
36
|
+
.icen-chart-heatmap-cell[data-icen-level='1'] { background: color-mix(in srgb, var(--chart-tone, var(--icen-token-accent)) 24%, var(--icen-token-fill-2)); }
|
|
37
|
+
.icen-chart-heatmap-cell[data-icen-level='2'] { background: color-mix(in srgb, var(--chart-tone, var(--icen-token-accent)) 46%, var(--icen-token-fill-2)); }
|
|
38
|
+
.icen-chart-heatmap-cell[data-icen-level='3'] { background: color-mix(in srgb, var(--chart-tone, var(--icen-token-accent)) 70%, var(--icen-token-fill-2)); }
|
|
39
|
+
.icen-chart-heatmap-cell[data-icen-level='4'] { background: var(--chart-tone, var(--icen-token-accent)); }
|
|
40
|
+
|
|
41
|
+
/* hover:面色内圈 + 色环外圈(不改变格子尺寸,网格不跳) */
|
|
42
|
+
.icen-chart-heatmap-cell:not(.is-blank):hover {
|
|
43
|
+
box-shadow:
|
|
44
|
+
0 0 0 1.5px var(--icen-token-card),
|
|
45
|
+
0 0 0 2.5px var(--chart-tone, var(--icen-token-accent));
|
|
46
|
+
}
|
|
47
|
+
.icen-chart-heatmap-cell:not(.is-blank):active {
|
|
48
|
+
filter: brightness(0.94);
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.icen-chart-heatmap-legend {
|
|
52
|
+
display: flex;
|
|
53
|
+
align-items: center;
|
|
54
|
+
justify-content: flex-end;
|
|
55
|
+
gap: 4px;
|
|
56
|
+
font-size: 11px;
|
|
57
|
+
letter-spacing: 0.01em;
|
|
58
|
+
color: var(--icen-token-text-faint);
|
|
59
|
+
}
|
|
60
|
+
.icen-chart-heatmap-legend .icen-chart-heatmap-cell {
|
|
61
|
+
width: 10px;
|
|
62
|
+
height: 10px;
|
|
63
|
+
aspect-ratio: auto;
|
|
64
|
+
border-radius: 2px; /* guard:allow-radius 微构件(bar/dot/track/指示器等图形级,不属容器圆角面) */
|
|
65
|
+
}
|
|
66
|
+
.icen-chart-heatmap-legend > span:first-child { margin-right: 2px; }
|
|
67
|
+
.icen-chart-heatmap-legend > span:last-child { margin-left: 2px; }
|
|
68
|
+
|
|
69
|
+
/* ── 贡献日历(renderCalendar):月份标签 + 星期列 + 周格 ──
|
|
70
|
+
* 布局 grid:左列星期标签(一/三/五/日),右列自上而下 月份行 / 周格 / 图例。
|
|
71
|
+
* 月份标签按周列定位:left = col / columns * 100%。 */
|
|
72
|
+
.icen-chart-calendar {
|
|
73
|
+
display: grid;
|
|
74
|
+
grid-template-columns: 16px 1fr;
|
|
75
|
+
grid-template-rows: 14px auto auto;
|
|
76
|
+
column-gap: 6px;
|
|
77
|
+
row-gap: 4px;
|
|
78
|
+
}
|
|
79
|
+
.icen-chart-calendar-months {
|
|
80
|
+
grid-column: 2;
|
|
81
|
+
position: relative;
|
|
82
|
+
font-size: 10px;
|
|
83
|
+
letter-spacing: 0.01em;
|
|
84
|
+
color: var(--icen-token-text-faint);
|
|
85
|
+
}
|
|
86
|
+
.icen-chart-calendar-month {
|
|
87
|
+
position: absolute;
|
|
88
|
+
top: 0;
|
|
89
|
+
left: calc(var(--col, 0) / var(--columns, 1) * 100%);
|
|
90
|
+
white-space: nowrap;
|
|
91
|
+
}
|
|
92
|
+
.icen-chart-calendar-weekdays {
|
|
93
|
+
grid-column: 1;
|
|
94
|
+
grid-row: 2;
|
|
95
|
+
display: grid;
|
|
96
|
+
grid-template-rows: repeat(7, 1fr);
|
|
97
|
+
align-items: center;
|
|
98
|
+
font-size: 10px;
|
|
99
|
+
color: var(--icen-token-text-faint);
|
|
100
|
+
line-height: 1;
|
|
101
|
+
}
|
|
102
|
+
.icen-chart-calendar .icen-chart-heatmap-grid {
|
|
103
|
+
grid-column: 2;
|
|
104
|
+
grid-row: 2;
|
|
105
|
+
gap: 2px;
|
|
106
|
+
}
|
|
107
|
+
.icen-chart-calendar .icen-chart-heatmap-legend {
|
|
108
|
+
grid-column: 2;
|
|
109
|
+
grid-row: 3;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
@media (prefers-reduced-motion: reduce) {
|
|
113
|
+
.icen-chart-heatmap-cell { transition: none; }
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
@media (forced-colors: active) {
|
|
117
|
+
.icen-chart-heatmap-cell { border: 1px solid CanvasText; }
|
|
118
|
+
.icen-chart-heatmap-cell.is-blank { border-color: transparent; }
|
|
119
|
+
}
|
|
98
120
|
|
|
99
121
|
}
|
|
@@ -6,10 +6,15 @@
|
|
|
6
6
|
* DOM 由 behaviors/charts.ts 的 renderLine 构建:
|
|
7
7
|
* .icen-chart-line > svg[viewBox="0 0 360 150"]
|
|
8
8
|
* 含面积渐变 + 网格线 + 数据点 + 底部 .icen-chart-labels。
|
|
9
|
+
* 网格线带 .icen-chart-grid,最底一条同时带 .icen-chart-baseline(轴基线加重)。
|
|
9
10
|
* spec.marks 的 SVG 标记(.icen-chart-mark-line 参考线 / .icen-chart-mark-point
|
|
10
11
|
* 标记点 + .icen-chart-mark-label 标注)直接追加进本 svg,样式属性直出(挡指针事件在基座)。
|
|
11
12
|
*/
|
|
12
13
|
|
|
14
|
+
.icen-chart-line {
|
|
15
|
+
position: relative;
|
|
16
|
+
min-width: 0;
|
|
17
|
+
}
|
|
13
18
|
.icen-chart-line > svg {
|
|
14
19
|
display: block;
|
|
15
20
|
width: 100%;
|
|
@@ -17,4 +22,53 @@
|
|
|
17
22
|
overflow: visible;
|
|
18
23
|
}
|
|
19
24
|
|
|
25
|
+
/* 网格:四档横向发丝线;基线略重(1 档灰差,不做粗黑轴) */
|
|
26
|
+
.icen-chart-line svg .icen-chart-grid {
|
|
27
|
+
stroke: var(--icen-token-line-soft);
|
|
28
|
+
opacity: 0.9;
|
|
29
|
+
}
|
|
30
|
+
.icen-chart-line svg .icen-chart-baseline {
|
|
31
|
+
stroke: var(--icen-token-line);
|
|
32
|
+
opacity: 1;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/* 数据线:单/多系列统一 2px(行为给 2.5/2,CSS 归一保持同族粗细) */
|
|
36
|
+
.icen-chart-line svg > path[fill='none'] {
|
|
37
|
+
stroke-width: 2;
|
|
38
|
+
}
|
|
39
|
+
/* 面积渐变压到克制档:首色 .22、尾色 0,避免大色块压过线本身 */
|
|
40
|
+
.icen-chart-line svg stop:first-child { stop-opacity: 0.22; }
|
|
41
|
+
.icen-chart-line svg stop:last-child { stop-opacity: 0; }
|
|
42
|
+
|
|
43
|
+
/* 数据点:白芯 + 色环;hover 放大 1.45×(命中圆在点之后,用相邻选择器把放大
|
|
44
|
+
落到被盖住的实心点上;命中圆自身只铺一层极淡的 accent 晕) */
|
|
45
|
+
.icen-chart-line svg circle[data-icen-chart-mark]:not([data-icen-chart-hit]) {
|
|
46
|
+
transform-box: fill-box;
|
|
47
|
+
transform-origin: center;
|
|
48
|
+
transition: transform var(--icen-duration-fast) var(--icen-ease-out), opacity var(--icen-tx-fast);
|
|
49
|
+
}
|
|
50
|
+
.icen-chart-line svg circle[data-icen-chart-mark]:not([data-icen-chart-hit]):has(+ .is-hover) {
|
|
51
|
+
transform: scale(1.45);
|
|
52
|
+
}
|
|
53
|
+
.icen-chart-line svg circle[data-icen-chart-hit].is-hover {
|
|
54
|
+
fill: color-mix(in srgb, var(--icen-token-accent) 9%, transparent);
|
|
55
|
+
}
|
|
56
|
+
.icen-chart-line svg circle[data-icen-chart-mark].is-off {
|
|
57
|
+
opacity: 0.18;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
/* 轴标签行与绘图区之间留一口气,不贴线 */
|
|
61
|
+
.icen-chart-line .icen-chart-labels {
|
|
62
|
+
margin-top: 5px;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
@media (prefers-reduced-motion: reduce) {
|
|
66
|
+
.icen-chart-line svg circle[data-icen-chart-mark] { transition: none; }
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
@media (forced-colors: active) {
|
|
70
|
+
.icen-chart-line svg .icen-chart-grid,
|
|
71
|
+
.icen-chart-line svg .icen-chart-baseline { stroke: GrayText; }
|
|
72
|
+
}
|
|
73
|
+
|
|
20
74
|
}
|
|
@@ -6,11 +6,13 @@
|
|
|
6
6
|
* DOM 由 behaviors/charts.ts 的 renderDonut 构建:
|
|
7
7
|
* .icen-chart-donut > svg[viewBox="0 0 120 120"](-90° 起笔)
|
|
8
8
|
* .icen-chart-donut > .icen-chart-legend
|
|
9
|
+
* 多段时 behavior 在每段尾部留 2.5 用户单位白隙(同色相邻段可辨)。
|
|
9
10
|
*/
|
|
10
11
|
|
|
11
12
|
.icen-chart-donut {
|
|
12
13
|
display: flex;
|
|
13
14
|
align-items: center;
|
|
15
|
+
flex-wrap: wrap;
|
|
14
16
|
gap: var(--icen-density-space-md);
|
|
15
17
|
min-height: 150px;
|
|
16
18
|
}
|
|
@@ -18,6 +20,33 @@
|
|
|
18
20
|
width: 132px;
|
|
19
21
|
height: 132px;
|
|
20
22
|
flex-shrink: 0;
|
|
23
|
+
overflow: visible;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
/* 环宽 13(轨道与弧一致);hover 段加宽 2px 但不压邻段(底座已留 2.5 缝隙) */
|
|
27
|
+
.icen-chart-donut svg circle {
|
|
28
|
+
stroke-width: 13;
|
|
29
|
+
transition: stroke-width var(--icen-duration-fast) var(--icen-ease-out), opacity var(--icen-tx-fast);
|
|
30
|
+
}
|
|
31
|
+
.icen-chart-donut svg circle[data-icen-chart-mark].is-hover {
|
|
32
|
+
stroke-width: 15;
|
|
33
|
+
}
|
|
34
|
+
.icen-chart-donut svg circle[data-icen-chart-mark].is-off {
|
|
35
|
+
opacity: 0.22;
|
|
36
|
+
stroke-width: 13;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.icen-chart-donut .icen-chart-legend {
|
|
40
|
+
gap: 6px;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
@media (prefers-reduced-motion: reduce) {
|
|
44
|
+
.icen-chart-donut svg circle { transition: none; }
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
@media (forced-colors: active) {
|
|
48
|
+
.icen-chart-donut svg circle { forced-color-adjust: none; }
|
|
49
|
+
.icen-chart-donut svg circle:first-of-type { stroke: CanvasText; }
|
|
21
50
|
}
|
|
22
51
|
|
|
23
52
|
}
|