@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.
- package/AGENTS.md +82 -254
- package/LICENSE +21 -0
- package/README.md +60 -96
- package/dist/base.css +258 -188
- package/dist/behaviors/accordion.mjs +8 -8
- package/dist/behaviors/ai-branch.d.mts +1 -1
- package/dist/behaviors/ai-branch.mjs +1011 -94
- package/dist/behaviors/ai-chat.d.mts +9 -9
- package/dist/behaviors/ai-chat.mjs +1122 -169
- package/dist/behaviors/ai-composer.d.mts +47 -15
- package/dist/behaviors/ai-composer.mjs +2018 -534
- package/dist/behaviors/ai-core.d.mts +1 -1
- package/dist/behaviors/ai-core.mjs +1017 -107
- package/dist/behaviors/ai-diff.mjs +1020 -127
- package/dist/behaviors/ai-feedback.d.mts +1 -1
- package/dist/behaviors/ai-feedback.mjs +1036 -126
- package/dist/behaviors/ai-panel.d.mts +10 -10
- package/dist/behaviors/ai-panel.mjs +1285 -266
- package/dist/behaviors/ai-provider.d.mts +1 -1
- package/dist/behaviors/ai-provider.mjs +1004 -101
- package/dist/behaviors/ai-threads.d.mts +1 -1
- package/dist/behaviors/ai-threads.mjs +1069 -154
- package/dist/behaviors/ai-tool.d.mts +3 -3
- package/dist/behaviors/ai-tool.mjs +2087 -413
- package/dist/behaviors/ai-tools.d.mts +89 -16
- package/dist/behaviors/ai-tools.mjs +5365 -380
- package/dist/behaviors/autocomplete.d.mts +53 -0
- package/dist/behaviors/autocomplete.mjs +1601 -0
- package/dist/behaviors/back-top.d.mts +1 -1
- package/dist/behaviors/back-top.mjs +952 -14
- package/dist/behaviors/carousel.d.mts +1 -1
- package/dist/behaviors/carousel.mjs +914 -12
- package/dist/behaviors/cascader.d.mts +48 -0
- package/dist/behaviors/cascader.mjs +1867 -0
- package/dist/behaviors/charts.d.mts +72 -8
- package/dist/behaviors/charts.mjs +1953 -272
- package/dist/behaviors/code-block.d.mts +36 -0
- package/dist/behaviors/code-block.mjs +1619 -0
- package/dist/behaviors/command-palette.d.mts +9 -6
- package/dist/behaviors/command-palette.mjs +164 -62
- package/dist/behaviors/context-menu.d.mts +10 -9
- package/dist/behaviors/context-menu.mjs +1113 -44
- package/dist/behaviors/controls.d.mts +21 -21
- package/dist/behaviors/controls.mjs +1024 -134
- package/dist/behaviors/copy.d.mts +21 -2
- package/dist/behaviors/copy.mjs +1207 -42
- package/dist/behaviors/datatable.d.mts +55 -5
- package/dist/behaviors/datatable.mjs +2033 -212
- package/dist/behaviors/date-picker.d.mts +0 -1
- package/dist/behaviors/date-picker.mjs +1341 -293
- package/dist/behaviors/design.d.mts +54 -0
- package/dist/behaviors/design.mjs +109 -0
- package/dist/behaviors/dropdown.d.mts +5 -6
- package/dist/behaviors/dropdown.mjs +262 -110
- package/dist/behaviors/events.d.mts +127 -10
- package/dist/behaviors/events.mjs +58 -3
- package/dist/behaviors/feedback.d.mts +30 -0
- package/dist/behaviors/feedback.mjs +296 -0
- package/dist/behaviors/focus.d.mts +8 -0
- package/dist/behaviors/focus.mjs +24 -0
- package/dist/behaviors/form-validate.d.mts +111 -0
- package/dist/behaviors/form-validate.mjs +1746 -0
- package/dist/behaviors/i18n.d.mts +790 -0
- package/dist/behaviors/i18n.mjs +1713 -0
- package/dist/behaviors/icons.d.mts +93 -0
- package/dist/behaviors/icons.mjs +113 -0
- package/dist/behaviors/input.d.mts +9 -1
- package/dist/behaviors/input.mjs +1059 -60
- package/dist/behaviors/kb-access.d.mts +3 -3
- package/dist/behaviors/kb-access.mjs +2135 -239
- package/dist/behaviors/kb-acl.d.mts +8 -8
- package/dist/behaviors/kb-acl.mjs +1120 -179
- package/dist/behaviors/kb-answer.d.mts +2 -2
- package/dist/behaviors/kb-answer.mjs +2120 -435
- package/dist/behaviors/kb-audit.d.mts +3 -3
- package/dist/behaviors/kb-audit.mjs +1077 -154
- package/dist/behaviors/kb-canvas.d.mts +3 -3
- package/dist/behaviors/kb-canvas.mjs +1101 -177
- package/dist/behaviors/kb-chain.d.mts +2 -2
- package/dist/behaviors/kb-chain.mjs +1023 -100
- package/dist/behaviors/kb-checkpoint.d.mts +3 -3
- package/dist/behaviors/kb-checkpoint.mjs +1320 -169
- package/dist/behaviors/kb-chunks.d.mts +2 -2
- package/dist/behaviors/kb-chunks.mjs +1153 -213
- package/dist/behaviors/kb-citation.d.mts +3 -3
- package/dist/behaviors/kb-citation.mjs +1221 -185
- package/dist/behaviors/kb-clarify.d.mts +2 -2
- package/dist/behaviors/kb-clarify.mjs +1059 -130
- package/dist/behaviors/kb-conflict.d.mts +2 -2
- package/dist/behaviors/kb-conflict.mjs +1042 -119
- package/dist/behaviors/kb-connector.d.mts +2 -2
- package/dist/behaviors/kb-connector.mjs +1105 -176
- package/dist/behaviors/kb-core.d.mts +7 -2
- package/dist/behaviors/kb-core.mjs +1078 -162
- package/dist/behaviors/kb-eval.d.mts +2 -2
- package/dist/behaviors/kb-eval.mjs +1977 -144
- package/dist/behaviors/kb-explain.d.mts +3 -3
- package/dist/behaviors/kb-explain.mjs +1037 -104
- package/dist/behaviors/kb-filter.d.mts +2 -2
- package/dist/behaviors/kb-filter.mjs +2014 -178
- package/dist/behaviors/kb-gap.d.mts +3 -3
- package/dist/behaviors/kb-gap.mjs +1044 -121
- package/dist/behaviors/kb-hittest.d.mts +3 -3
- package/dist/behaviors/kb-hittest.mjs +1095 -151
- package/dist/behaviors/kb-metadata.mjs +1058 -130
- package/dist/behaviors/kb-passage.d.mts +4 -4
- package/dist/behaviors/kb-passage.mjs +1102 -161
- package/dist/behaviors/kb-pipeline.d.mts +4 -4
- package/dist/behaviors/kb-pipeline.mjs +1083 -162
- package/dist/behaviors/kb-qa.mjs +1089 -160
- package/dist/behaviors/kb-rerank.d.mts +2 -2
- package/dist/behaviors/kb-rerank.mjs +1048 -114
- package/dist/behaviors/kb-retrieval.d.mts +2 -2
- package/dist/behaviors/kb-retrieval.mjs +2079 -226
- package/dist/behaviors/kb-review.d.mts +2 -2
- package/dist/behaviors/kb-review.mjs +1996 -159
- package/dist/behaviors/kb-sandbox.d.mts +3 -3
- package/dist/behaviors/kb-sandbox.mjs +1033 -105
- package/dist/behaviors/kb-segment.d.mts +2 -2
- package/dist/behaviors/kb-segment.mjs +1112 -179
- package/dist/behaviors/kb-select.d.mts +24 -0
- package/dist/behaviors/kb-select.mjs +1995 -0
- package/dist/behaviors/kb-sources.d.mts +3 -3
- package/dist/behaviors/kb-sources.mjs +1085 -170
- package/dist/behaviors/kb-sql.d.mts +3 -3
- package/dist/behaviors/kb-sql.mjs +1144 -226
- package/dist/behaviors/kb-trace.d.mts +3 -3
- package/dist/behaviors/kb-trace.mjs +1051 -131
- package/dist/behaviors/kb-visibility.d.mts +2 -2
- package/dist/behaviors/kb-visibility.mjs +1087 -158
- package/dist/behaviors/kb-who-can.d.mts +2 -2
- package/dist/behaviors/kb-who-can.mjs +1980 -137
- package/dist/behaviors/mentions.d.mts +93 -0
- package/dist/behaviors/mentions.mjs +2153 -0
- package/dist/behaviors/modal.d.mts +4 -3
- package/dist/behaviors/modal.mjs +1056 -33
- package/dist/behaviors/nav.d.mts +1 -1
- package/dist/behaviors/nav.mjs +6 -6
- package/dist/behaviors/notification.d.mts +16 -8
- package/dist/behaviors/notification.mjs +1629 -268
- package/dist/behaviors/panel.d.mts +4 -0
- package/dist/behaviors/panel.mjs +995 -0
- package/dist/behaviors/popover.d.mts +28 -5
- package/dist/behaviors/popover.mjs +225 -24
- package/dist/behaviors/scroll-area.d.mts +17 -0
- package/dist/behaviors/scroll-area.mjs +59 -0
- package/dist/behaviors/select.d.mts +5 -2
- package/dist/behaviors/select.mjs +1416 -117
- package/dist/behaviors/sidebar.d.mts +1 -1
- package/dist/behaviors/sidebar.mjs +13 -13
- package/dist/behaviors/slider.d.mts +1 -1
- package/dist/behaviors/slider.mjs +12 -12
- package/dist/behaviors/split-pane.d.mts +1 -1
- package/dist/behaviors/split-pane.mjs +9 -7
- package/dist/behaviors/suggestions.d.mts +27 -0
- package/dist/behaviors/suggestions.mjs +1090 -0
- package/dist/behaviors/svg-parse.d.mts +14 -0
- package/dist/behaviors/svg-parse.mjs +37 -0
- package/dist/behaviors/tabs.d.mts +2 -2
- package/dist/behaviors/tabs.mjs +35 -25
- package/dist/behaviors/tag-input.d.mts +23 -5
- package/dist/behaviors/tag-input.mjs +1360 -104
- package/dist/behaviors/theme-switcher.d.mts +24 -0
- package/dist/behaviors/theme-switcher.mjs +1996 -0
- package/dist/behaviors/theme.d.mts +15 -8
- package/dist/behaviors/theme.mjs +406 -30
- package/dist/behaviors/toast.d.mts +24 -25
- package/dist/behaviors/toast.mjs +1267 -88
- package/dist/behaviors/tooltip.d.mts +4 -0
- package/dist/behaviors/tooltip.mjs +378 -0
- package/dist/behaviors/tree-select.d.mts +69 -0
- package/dist/behaviors/tree-select.mjs +1921 -0
- package/dist/behaviors/tree.d.mts +1 -1
- package/dist/behaviors/tree.mjs +18 -18
- package/dist/behaviors/upload.d.mts +3 -2
- package/dist/behaviors/upload.mjs +1077 -66
- package/dist/behaviors/url-safety.d.mts +8 -0
- package/dist/behaviors/url-safety.mjs +11 -0
- package/dist/cli.mjs +5 -6
- package/dist/components/accordion.d.mts +2 -0
- package/dist/components/ai-branch.d.mts +2 -0
- package/dist/components/ai-chat.css +682 -582
- 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 +153 -132
- 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 +353 -343
- 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 +397 -242
- package/dist/components/ai-usage.d.mts +2 -0
- package/dist/components/alert.d.mts +2 -0
- package/dist/components/autocomplete.css +61 -0
- package/dist/components/autocomplete.d.mts +2 -0
- package/dist/components/autocomplete.mjs +3 -0
- package/dist/components/avatar.d.mts +2 -0
- package/dist/components/back-top.css +74 -40
- package/dist/components/back-top.d.mts +2 -0
- package/dist/components/badge.css +44 -41
- package/dist/components/badge.d.mts +2 -0
- package/dist/components/breadcrumb.css +85 -46
- package/dist/components/breadcrumb.d.mts +2 -0
- package/dist/components/btn.css +105 -94
- package/dist/components/btn.d.mts +2 -0
- package/dist/components/card.css +124 -113
- package/dist/components/card.d.mts +2 -0
- package/dist/components/carousel.d.mts +2 -0
- package/dist/components/cascader.css +332 -0
- package/dist/components/cascader.d.mts +2 -0
- package/dist/components/cascader.mjs +3 -0
- package/dist/components/chart-area.css +54 -2
- package/dist/components/chart-area.d.mts +2 -0
- package/dist/components/chart-bar.css +147 -38
- package/dist/components/chart-bar.d.mts +2 -0
- package/dist/components/chart-calendar.d.mts +2 -0
- package/dist/components/chart-gauge.css +36 -13
- package/dist/components/chart-gauge.d.mts +2 -0
- package/dist/components/chart-graph.css +35 -20
- package/dist/components/chart-graph.d.mts +2 -0
- package/dist/components/chart-heatmap.css +67 -39
- package/dist/components/chart-heatmap.d.mts +2 -0
- package/dist/components/chart-line.css +62 -3
- package/dist/components/chart-line.d.mts +2 -0
- package/dist/components/chart-map.d.mts +2 -0
- package/dist/components/chart-pie.css +38 -6
- package/dist/components/chart-pie.d.mts +2 -0
- package/dist/components/chart-radar.css +57 -5
- package/dist/components/chart-radar.d.mts +2 -0
- package/dist/components/chart-scatter.css +47 -7
- package/dist/components/chart-scatter.d.mts +2 -0
- package/dist/components/chart-sparkline.css +25 -2
- package/dist/components/chart-sparkline.d.mts +2 -0
- package/dist/components/chart-stack.css +27 -13
- package/dist/components/chart-stack.d.mts +2 -0
- package/dist/components/charts.css +220 -84
- package/dist/components/charts.d.mts +2 -0
- package/dist/components/code-block.css +420 -0
- package/dist/components/code-block.d.mts +2 -0
- package/dist/components/code-block.mjs +4 -0
- package/dist/components/command-palette.css +150 -122
- package/dist/components/command-palette.d.mts +2 -0
- package/dist/components/content.css +274 -263
- package/dist/components/context-menu.d.mts +2 -0
- package/dist/components/copy.css +73 -45
- package/dist/components/copy.d.mts +2 -0
- package/dist/components/datatable.css +457 -202
- package/dist/components/datatable.d.mts +2 -0
- package/dist/components/date-picker.css +136 -105
- 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 +72 -69
- package/dist/components/empty.d.mts +2 -0
- package/dist/components/feedback.css +211 -191
- package/dist/components/form-validate.css +134 -0
- package/dist/components/form-validate.d.mts +2 -0
- package/dist/components/form-validate.mjs +3 -0
- package/dist/components/form.css +157 -131
- package/dist/components/form.d.mts +2 -0
- package/dist/components/icon.css +113 -0
- package/dist/components/icon.d.mts +2 -0
- package/dist/components/icon.mjs +3 -0
- package/dist/components/input.css +163 -108
- 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 +300 -206
- 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 +431 -315
- 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 +333 -229
- package/dist/components/kb-hittest.d.mts +2 -0
- package/dist/components/kb-ingest.css +613 -434
- package/dist/components/kb-metadata.d.mts +2 -0
- package/dist/components/kb-ops.css +422 -302
- package/dist/components/kb-passage.d.mts +2 -0
- package/dist/components/kb-perm.css +374 -314
- 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 +653 -459
- 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 +170 -135
- package/dist/components/kb.d.mts +2 -0
- package/dist/components/kbd.d.mts +2 -0
- package/dist/components/layout.css +86 -83
- package/dist/components/layout.d.mts +2 -0
- package/dist/components/list.d.mts +2 -0
- package/dist/components/material-chinese.css +83 -0
- package/dist/components/material-soviet.css +86 -0
- package/dist/components/material.css +318 -0
- package/dist/components/media-card.d.mts +2 -0
- package/dist/components/media.css +225 -176
- package/dist/components/mentions.css +190 -0
- package/dist/components/mentions.d.mts +2 -0
- package/dist/components/mentions.mjs +3 -0
- package/dist/components/menu.css +121 -109
- package/dist/components/modal.css +116 -118
- package/dist/components/modal.d.mts +2 -0
- package/dist/components/nav.css +136 -129
- package/dist/components/nav.d.mts +2 -0
- package/dist/components/notification.css +247 -177
- package/dist/components/notification.d.mts +2 -0
- package/dist/components/pagination.css +62 -57
- package/dist/components/pagination.d.mts +2 -0
- package/dist/components/panel.css +70 -68
- package/dist/components/panel.d.mts +2 -0
- package/dist/components/panel.mjs +1 -0
- package/dist/components/pill.css +83 -72
- package/dist/components/pill.d.mts +2 -0
- package/dist/components/popover.css +80 -57
- 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 +29 -54
- package/dist/components/scroll-area.d.mts +2 -0
- package/dist/components/scroll-area.mjs +1 -0
- package/dist/components/segmented.css +167 -146
- package/dist/components/segmented.d.mts +2 -0
- package/dist/components/select.css +250 -191
- package/dist/components/select.d.mts +2 -0
- package/dist/components/sidebar.css +157 -143
- package/dist/components/sidebar.d.mts +2 -0
- package/dist/components/skeleton.d.mts +2 -0
- package/dist/components/slider.css +135 -128
- package/dist/components/slider.d.mts +2 -0
- package/dist/components/spinner.d.mts +2 -0
- package/dist/components/split-pane.css +120 -108
- package/dist/components/split-pane.d.mts +2 -0
- package/dist/components/stat.css +116 -109
- package/dist/components/stat.d.mts +2 -0
- package/dist/components/steps.css +114 -108
- package/dist/components/steps.d.mts +2 -0
- package/dist/components/switch.css +192 -149
- package/dist/components/switch.d.mts +2 -0
- package/dist/components/table.css +158 -112
- package/dist/components/table.d.mts +2 -0
- package/dist/components/tabs.css +143 -116
- package/dist/components/tabs.d.mts +2 -0
- package/dist/components/tag-input.css +52 -133
- package/dist/components/tag-input.d.mts +2 -0
- package/dist/components/tag.css +90 -72
- package/dist/components/tag.d.mts +2 -0
- package/dist/components/theme-switcher.css +105 -0
- package/dist/components/theme-switcher.d.mts +2 -0
- package/dist/components/theme-switcher.mjs +3 -0
- package/dist/components/timeline.d.mts +2 -0
- package/dist/components/toast.css +115 -97
- package/dist/components/toast.d.mts +2 -0
- package/dist/components/toolbar.css +47 -43
- package/dist/components/toolbar.d.mts +2 -0
- package/dist/components/tooltip.css +103 -43
- package/dist/components/tooltip.d.mts +2 -0
- package/dist/components/tooltip.mjs +1 -0
- package/dist/components/tree-select.css +439 -0
- package/dist/components/tree-select.d.mts +2 -0
- package/dist/components/tree-select.mjs +3 -0
- package/dist/components/tree.d.mts +2 -0
- package/dist/components/upload.css +138 -97
- package/dist/components/upload.d.mts +2 -0
- package/dist/fonts/LICENSES/ark-pixel/OFL.txt +96 -0
- package/dist/fonts/LICENSES/cubic-11/OFL.txt +108 -0
- package/dist/fonts/LICENSES/galmuri/LICENSE.txt +93 -0
- package/dist/fonts/OFL.txt +96 -0
- package/dist/fonts/README.md +14 -0
- package/dist/fonts/fusion-pixel-12px-zh-hans.woff2 +0 -0
- package/dist/index.d.mts +85 -70
- package/dist/index.mjs +17330 -5773
- package/dist/react.d.mts +91 -0
- package/dist/react.mjs +8307 -0
- package/dist/registry.json +918 -70
- package/dist/tokens/chinese.css +44 -0
- package/dist/tokens/colors.css +371 -1222
- package/dist/tokens/design.css +209 -0
- package/dist/tokens/dtcg.json +15926 -0
- package/dist/tokens/figma.variables.json +10779 -0
- package/dist/tokens/icon-masks.css +78 -0
- package/dist/tokens/pixel.css +53 -0
- package/dist/tokens/scrollbars.css +40 -0
- package/dist/tokens/soviet.css +44 -0
- package/dist/tokens/style-profiles.css +36 -547
- package/dist/tokens/themes.json +308 -0
- package/dist/tokens/tokens-studio.json +11648 -0
- package/dist/tokens/typography.css +21 -18
- package/dist/tokens.css +1783 -1806
- package/dist/ui.css +14796 -10750
- package/dist/vue.d.mts +344 -0
- package/dist/vue.mjs +7876 -0
- package/docs/spec/ai-input-experience.md +75 -0
- package/docs/spec/ai-native.md +238 -147
- package/docs/spec/design-philosophy.md +189 -0
- package/docs/spec/design-primitives.md +196 -0
- package/docs/spec/kb-family.md +147 -115
- package/docs/spec/scrollbars.md +46 -0
- package/package.json +56 -8
- package/dist/retro-effects.css +0 -255
- package/dist/tokens/retro-effects.css +0 -255
- package/docs/research/2026-10-03-ai-kb-components.md +0 -392
- package/docs/research/2026-10-03-kb-permissions.md +0 -992
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@icen.ai/ui",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "Icen Design System — 设计 tokens(6
|
|
3
|
+
"version": "0.11.0",
|
|
4
|
+
"description": "Icen Design System — 设计 tokens(6 主题 × 4 原语 × 明暗)+ 无框架组件 CSS/行为 JS + AI 原生组件族(7 态状态机/多模态/定价审计)+ 图表通用层(ChartSpec 纯 JSON)+ AI 工具体系",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "git+https://github.com/icen-ai/ui.git"
|
|
@@ -10,12 +10,14 @@
|
|
|
10
10
|
"type": "module",
|
|
11
11
|
"exports": {
|
|
12
12
|
".": "./dist/index.mjs",
|
|
13
|
+
"./react": "./dist/react.mjs",
|
|
14
|
+
"./vue": "./dist/vue.mjs",
|
|
13
15
|
"./behaviors/*": "./dist/behaviors/*.mjs",
|
|
14
16
|
"./kit/*": "./dist/components/*.mjs",
|
|
15
17
|
"./tokens.css": "./dist/tokens.css",
|
|
18
|
+
"./tokens/dtcg.json": "./dist/tokens/dtcg.json",
|
|
16
19
|
"./ui.css": "./dist/ui.css",
|
|
17
20
|
"./base.css": "./dist/base.css",
|
|
18
|
-
"./retro-effects.css": "./dist/retro-effects.css",
|
|
19
21
|
"./tokens/*": "./dist/tokens/*",
|
|
20
22
|
"./components/*": "./dist/components/*",
|
|
21
23
|
"./registry.json": "./dist/registry.json"
|
|
@@ -26,23 +28,69 @@
|
|
|
26
28
|
"sideEffects": [
|
|
27
29
|
"**/*.css"
|
|
28
30
|
],
|
|
31
|
+
"engines": {
|
|
32
|
+
"node": ">=18"
|
|
33
|
+
},
|
|
34
|
+
"packageManager": "bun@1.3.5",
|
|
35
|
+
"peerDependencies": {
|
|
36
|
+
"react": ">=18",
|
|
37
|
+
"react-dom": ">=18",
|
|
38
|
+
"vue": ">=3.3"
|
|
39
|
+
},
|
|
40
|
+
"peerDependenciesMeta": {
|
|
41
|
+
"react": {
|
|
42
|
+
"optional": true
|
|
43
|
+
},
|
|
44
|
+
"react-dom": {
|
|
45
|
+
"optional": true
|
|
46
|
+
},
|
|
47
|
+
"vue": {
|
|
48
|
+
"optional": true
|
|
49
|
+
}
|
|
50
|
+
},
|
|
29
51
|
"files": [
|
|
30
52
|
"dist",
|
|
31
53
|
"AGENTS.md",
|
|
32
|
-
"docs"
|
|
54
|
+
"docs/spec"
|
|
33
55
|
],
|
|
34
56
|
"license": "MIT",
|
|
35
57
|
"publishConfig": {
|
|
36
58
|
"access": "public"
|
|
37
59
|
},
|
|
38
60
|
"scripts": {
|
|
39
|
-
"build": "tsup && bun scripts/dts-ext.mjs && bun scripts/build-css.ts",
|
|
40
|
-
"
|
|
61
|
+
"build": "tsup && bun scripts/react-use-client.mjs && bun scripts/dts-ext.mjs && bun scripts/build-css.ts && bun scripts/dtcg.mjs && bun scripts/design-tokens.mjs",
|
|
62
|
+
"dtcg": "bun scripts/dtcg.mjs",
|
|
63
|
+
"design-tokens": "bun scripts/design-tokens.mjs",
|
|
64
|
+
"guard": "bun scripts/guard/index.ts",
|
|
65
|
+
"contracts": "bun scripts/contracts.ts --check",
|
|
66
|
+
"contracts:update": "bun scripts/contracts.ts --write",
|
|
67
|
+
"contracts:diff": "bun scripts/contracts.ts --diff",
|
|
68
|
+
"size": "bun scripts/size.ts",
|
|
69
|
+
"check:pkg": "bunx publint && bunx @arethetypeswrong/cli --pack . --ignore-rules no-resolution cjs-resolves-to-esm",
|
|
70
|
+
"prepublishOnly": "bun run build",
|
|
71
|
+
"pretest:e2e": "cd site && bun run build",
|
|
72
|
+
"test": "bun test",
|
|
73
|
+
"test:coverage": "bun scripts/coverage.ts",
|
|
74
|
+
"test:e2e": "playwright test",
|
|
75
|
+
"test:e2e:update": "playwright test --update-snapshots",
|
|
76
|
+
"verify": "bunx tsc --noEmit && bun run guard && bun test && bun run build && bun run size",
|
|
77
|
+
"colors": "bun scripts/theme-colors.mjs"
|
|
41
78
|
},
|
|
42
79
|
"devDependencies": {
|
|
80
|
+
"@arethetypeswrong/cli": "^0.18.5",
|
|
81
|
+
"@happy-dom/global-registrator": "^20.14.5",
|
|
82
|
+
"@playwright/test": "^1.63.0",
|
|
43
83
|
"@types/node": "^20.14.0",
|
|
84
|
+
"@types/react": "^19.3.0",
|
|
85
|
+
"@types/react-dom": "^19.3.0",
|
|
86
|
+
"axe-core": "^4.14.0",
|
|
87
|
+
"happy-dom": "^20.14.5",
|
|
88
|
+
"publint": "^0.3.25",
|
|
89
|
+
"react": "^19.3.0",
|
|
90
|
+
"react-dom": "^19.3.0",
|
|
44
91
|
"tsup": "^8.3.0",
|
|
45
|
-
"typescript": "^5.5.0"
|
|
92
|
+
"typescript": "^5.5.0",
|
|
93
|
+
"vue": "^3.5.43"
|
|
46
94
|
},
|
|
47
95
|
"keywords": [
|
|
48
96
|
"design-system",
|
|
@@ -52,4 +100,4 @@
|
|
|
52
100
|
"css",
|
|
53
101
|
"tokens"
|
|
54
102
|
]
|
|
55
|
-
}
|
|
103
|
+
}
|
package/dist/retro-effects.css
DELETED
|
@@ -1,255 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* @icen.ai/ui — Retro 效果层(按需引入)
|
|
3
|
-
*
|
|
4
|
-
* 与 tokens.css 不同,本文件 **不** 进 tokens.css 拼合,需显式 import:
|
|
5
|
-
* import '@icen.ai/ui/retro-effects.css';
|
|
6
|
-
*
|
|
7
|
-
* 仅在 <html class="style-retro">(或叠加 .dark)激活时生效,对其它风格无副作用:
|
|
8
|
-
* - CRT 扫描线 + 暗角 + 颗粒噪点
|
|
9
|
-
* - 游走扫描光
|
|
10
|
-
* - RGB 色散 / 霓虹发光(暗色)
|
|
11
|
-
* - 像素边框 / 像素按钮 / 像素分隔线工具类
|
|
12
|
-
* - 开机自检 / 打字机光标 / 页面闪白动画
|
|
13
|
-
*
|
|
14
|
-
* 作用域约定:效果类(扫描线/噪点/光标/开机行/闪白)均收在 .style-retro 下;
|
|
15
|
-
* 像素工具类(.retro-pixel-border / .retro-pixel-button / .retro-pixel-rule)
|
|
16
|
-
* 有意保持全局可用——它们是纯几何装饰,任何风格都可取用。
|
|
17
|
-
* z-index 统一走 base.css 的 --z-fx 标尺(效果层,tooltip 之上)。
|
|
18
|
-
*
|
|
19
|
-
* 所有动画尊重 prefers-reduced-motion:在 reduce 下由 base.css 的全局兜底降为 0.01ms。
|
|
20
|
-
*/
|
|
21
|
-
|
|
22
|
-
/* ══════════════════════════════════════════════════════════════
|
|
23
|
-
CRT 显示器效果
|
|
24
|
-
══════════════════════════════════════════════════════════════ */
|
|
25
|
-
|
|
26
|
-
/* CRT 扫描线 overlay */
|
|
27
|
-
.style-retro body::before {
|
|
28
|
-
content: "";
|
|
29
|
-
position: fixed;
|
|
30
|
-
inset: 0;
|
|
31
|
-
pointer-events: none;
|
|
32
|
-
z-index: calc(var(--z-fx) - 1);
|
|
33
|
-
opacity: 0.14;
|
|
34
|
-
background:
|
|
35
|
-
repeating-linear-gradient(
|
|
36
|
-
0deg,
|
|
37
|
-
transparent,
|
|
38
|
-
transparent 2px,
|
|
39
|
-
rgba(0, 0, 0, 0.35) 2px,
|
|
40
|
-
rgba(0, 0, 0, 0.35) 4px
|
|
41
|
-
);
|
|
42
|
-
mix-blend-mode: multiply;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
.style-retro.dark body::before {
|
|
46
|
-
opacity: 0.22;
|
|
47
|
-
mix-blend-mode: screen;
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
/* CRT 暗角 + 轻微曲面 */
|
|
51
|
-
.style-retro body::after {
|
|
52
|
-
content: "";
|
|
53
|
-
position: fixed;
|
|
54
|
-
inset: 0;
|
|
55
|
-
pointer-events: none;
|
|
56
|
-
z-index: calc(var(--z-fx) - 2);
|
|
57
|
-
background:
|
|
58
|
-
radial-gradient(
|
|
59
|
-
ellipse at center,
|
|
60
|
-
transparent 55%,
|
|
61
|
-
rgba(0, 0, 0, 0.18) 100%
|
|
62
|
-
);
|
|
63
|
-
opacity: 0.55;
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
/* CRT 颗粒噪点 */
|
|
67
|
-
@keyframes retro-grain {
|
|
68
|
-
0%, 100% { background-position: 0 0; }
|
|
69
|
-
10% { background-position: -5% -10%; }
|
|
70
|
-
20% { background-position: -15% 5%; }
|
|
71
|
-
30% { background-position: 7% -25%; }
|
|
72
|
-
40% { background-position: -5% 25%; }
|
|
73
|
-
50% { background-position: -15% 10%; }
|
|
74
|
-
60% { background-position: 15% 0%; }
|
|
75
|
-
70% { background-position: 0% 15%; }
|
|
76
|
-
80% { background-position: 3% 35%; }
|
|
77
|
-
90% { background-position: -10% 10%; }
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
.style-retro .retro-crt-grain {
|
|
81
|
-
position: fixed;
|
|
82
|
-
inset: 0;
|
|
83
|
-
pointer-events: none;
|
|
84
|
-
z-index: calc(var(--z-fx) - 3);
|
|
85
|
-
opacity: 0.06;
|
|
86
|
-
background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
|
|
87
|
-
animation: retro-grain 0.5s steps(10) infinite;
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
/* ══════════════════════════════════════════════════════════════
|
|
91
|
-
全局动画关键帧 + 游走扫描光
|
|
92
|
-
══════════════════════════════════════════════════════════════ */
|
|
93
|
-
|
|
94
|
-
@keyframes retro-blink {
|
|
95
|
-
0%, 49% { opacity: 1; }
|
|
96
|
-
50%, 100% { opacity: 0; }
|
|
97
|
-
}
|
|
98
|
-
|
|
99
|
-
@keyframes retro-scanline-slide {
|
|
100
|
-
0% { transform: translateY(-100%); }
|
|
101
|
-
100% { transform: translateY(100vh); }
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
/* 游走的扫描线(偶尔闪过)—— 仅 .style-retro 下生效 */
|
|
105
|
-
.style-retro .retro-scanline-beam {
|
|
106
|
-
position: fixed;
|
|
107
|
-
left: 0;
|
|
108
|
-
right: 0;
|
|
109
|
-
height: 4px;
|
|
110
|
-
background: linear-gradient(
|
|
111
|
-
180deg,
|
|
112
|
-
transparent,
|
|
113
|
-
color-mix(in srgb, var(--token-accent) 30%, transparent),
|
|
114
|
-
transparent
|
|
115
|
-
);
|
|
116
|
-
pointer-events: none;
|
|
117
|
-
z-index: calc(var(--z-fx) - 4);
|
|
118
|
-
opacity: 0.4;
|
|
119
|
-
animation: retro-scanline-slide 4s linear infinite;
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
/* ══════════════════════════════════════════════════════════════
|
|
123
|
-
开机自检 / 打字机效果
|
|
124
|
-
══════════════════════════════════════════════════════════════ */
|
|
125
|
-
|
|
126
|
-
@keyframes retro-boot-text {
|
|
127
|
-
0% { opacity: 0; transform: translateY(4px); }
|
|
128
|
-
10% { opacity: 1; transform: translateY(0); }
|
|
129
|
-
90% { opacity: 1; transform: translateY(0); }
|
|
130
|
-
100% { opacity: 0; transform: translateY(-4px); }
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
.style-retro .retro-boot-line {
|
|
134
|
-
opacity: 0;
|
|
135
|
-
animation: retro-boot-text 0.3s steps(1) forwards;
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
.style-retro .retro-boot-line:nth-child(1) { animation-delay: 0.1s; }
|
|
139
|
-
.style-retro .retro-boot-line:nth-child(2) { animation-delay: 0.25s; }
|
|
140
|
-
.style-retro .retro-boot-line:nth-child(3) { animation-delay: 0.4s; }
|
|
141
|
-
.style-retro .retro-boot-line:nth-child(4) { animation-delay: 0.55s; }
|
|
142
|
-
.style-retro .retro-boot-line:nth-child(5) { animation-delay: 0.7s; }
|
|
143
|
-
|
|
144
|
-
/* 打字机光标 */
|
|
145
|
-
.style-retro .retro-cursor::after {
|
|
146
|
-
content: "█";
|
|
147
|
-
display: inline-block;
|
|
148
|
-
margin-left: 2px;
|
|
149
|
-
color: var(--token-accent);
|
|
150
|
-
animation: retro-blink 1s step-end infinite;
|
|
151
|
-
}
|
|
152
|
-
|
|
153
|
-
/* ══════════════════════════════════════════════════════════════
|
|
154
|
-
RGB 色散 / 霓虹发光(暗色下尤其出彩)
|
|
155
|
-
══════════════════════════════════════════════════════════════ */
|
|
156
|
-
|
|
157
|
-
.style-retro.dark .retro-glow {
|
|
158
|
-
text-shadow:
|
|
159
|
-
-1px 0 0 rgba(255, 0, 0, 0.4),
|
|
160
|
-
1px 0 0 rgba(0, 255, 255, 0.4),
|
|
161
|
-
0 0 2px var(--token-accent),
|
|
162
|
-
0 0 8px var(--token-accent);
|
|
163
|
-
}
|
|
164
|
-
|
|
165
|
-
.style-retro.dark .retro-glow-cold {
|
|
166
|
-
text-shadow:
|
|
167
|
-
-1px 0 0 rgba(255, 0, 0, 0.4),
|
|
168
|
-
1px 0 0 rgba(0, 255, 255, 0.4),
|
|
169
|
-
0 0 2px var(--token-accent-cold),
|
|
170
|
-
0 0 8px var(--token-accent-cold);
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
/* 亮色模式下发光退化为单层硬投影,保持像素感而不刺眼 */
|
|
174
|
-
.style-retro:not(.dark) .retro-glow {
|
|
175
|
-
text-shadow:
|
|
176
|
-
1px 1px 0 color-mix(in srgb, var(--token-accent) 30%, transparent);
|
|
177
|
-
}
|
|
178
|
-
|
|
179
|
-
/* ══════════════════════════════════════════════════════════════
|
|
180
|
-
像素边框工具类(任意风格下可用,但与 retro 最契合)
|
|
181
|
-
══════════════════════════════════════════════════════════════ */
|
|
182
|
-
|
|
183
|
-
.retro-pixel-border {
|
|
184
|
-
border: 2px solid var(--token-line);
|
|
185
|
-
box-shadow:
|
|
186
|
-
2px 2px 0 var(--token-line-strong),
|
|
187
|
-
inset 2px 2px 0 var(--token-surface-strong),
|
|
188
|
-
inset -2px -2px 0 var(--token-line-soft);
|
|
189
|
-
}
|
|
190
|
-
|
|
191
|
-
.retro-pixel-border-accent {
|
|
192
|
-
border: 2px solid var(--token-accent);
|
|
193
|
-
box-shadow:
|
|
194
|
-
2px 2px 0 var(--token-accent-cold),
|
|
195
|
-
inset 2px 2px 0 color-mix(in srgb, var(--token-accent) 20%, transparent),
|
|
196
|
-
inset -2px -2px 0 color-mix(in srgb, var(--token-accent) 40%, transparent);
|
|
197
|
-
}
|
|
198
|
-
|
|
199
|
-
/* 像素按钮:硬投影 + 按下内移 */
|
|
200
|
-
.retro-pixel-button {
|
|
201
|
-
position: relative;
|
|
202
|
-
border: 2px solid var(--token-line-strong);
|
|
203
|
-
box-shadow:
|
|
204
|
-
inset -2px -2px 0 var(--token-line-soft),
|
|
205
|
-
inset 2px 2px 0 var(--token-surface-strong),
|
|
206
|
-
2px 2px 0 var(--token-line);
|
|
207
|
-
transition: none;
|
|
208
|
-
}
|
|
209
|
-
|
|
210
|
-
.retro-pixel-button:active {
|
|
211
|
-
transform: translate(2px, 2px);
|
|
212
|
-
box-shadow:
|
|
213
|
-
inset -2px -2px 0 var(--token-line-soft),
|
|
214
|
-
inset 2px 2px 0 var(--token-surface-strong);
|
|
215
|
-
}
|
|
216
|
-
|
|
217
|
-
/* ══════════════════════════════════════════════════════════════
|
|
218
|
-
选中文字 / 像素分隔线
|
|
219
|
-
══════════════════════════════════════════════════════════════ */
|
|
220
|
-
|
|
221
|
-
.style-retro ::selection {
|
|
222
|
-
background: var(--token-accent);
|
|
223
|
-
color: var(--token-on-accent);
|
|
224
|
-
}
|
|
225
|
-
|
|
226
|
-
.retro-pixel-rule {
|
|
227
|
-
height: 0;
|
|
228
|
-
border: 0;
|
|
229
|
-
border-top: 2px dashed var(--token-line);
|
|
230
|
-
image-rendering: pixelated;
|
|
231
|
-
}
|
|
232
|
-
|
|
233
|
-
/* ══════════════════════════════════════════════════════════════
|
|
234
|
-
页面切换 / 闪白效果
|
|
235
|
-
══════════════════════════════════════════════════════════════ */
|
|
236
|
-
|
|
237
|
-
@keyframes retro-flash {
|
|
238
|
-
0% { opacity: 0; }
|
|
239
|
-
10% { opacity: 0.8; }
|
|
240
|
-
100% { opacity: 0; }
|
|
241
|
-
}
|
|
242
|
-
|
|
243
|
-
.style-retro .retro-page-flash {
|
|
244
|
-
position: fixed;
|
|
245
|
-
inset: 0;
|
|
246
|
-
pointer-events: none;
|
|
247
|
-
z-index: var(--z-fx);
|
|
248
|
-
background: var(--token-bg);
|
|
249
|
-
opacity: 0;
|
|
250
|
-
}
|
|
251
|
-
|
|
252
|
-
/* 状态类遵循全库 .is-* 规范 */
|
|
253
|
-
.style-retro .retro-page-flash.is-active {
|
|
254
|
-
animation: retro-flash 0.2s steps(3) forwards;
|
|
255
|
-
}
|
|
@@ -1,255 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* @icen.ai/ui — Retro 效果层(按需引入)
|
|
3
|
-
*
|
|
4
|
-
* 与 tokens.css 不同,本文件 **不** 进 tokens.css 拼合,需显式 import:
|
|
5
|
-
* import '@icen.ai/ui/retro-effects.css';
|
|
6
|
-
*
|
|
7
|
-
* 仅在 <html class="style-retro">(或叠加 .dark)激活时生效,对其它风格无副作用:
|
|
8
|
-
* - CRT 扫描线 + 暗角 + 颗粒噪点
|
|
9
|
-
* - 游走扫描光
|
|
10
|
-
* - RGB 色散 / 霓虹发光(暗色)
|
|
11
|
-
* - 像素边框 / 像素按钮 / 像素分隔线工具类
|
|
12
|
-
* - 开机自检 / 打字机光标 / 页面闪白动画
|
|
13
|
-
*
|
|
14
|
-
* 作用域约定:效果类(扫描线/噪点/光标/开机行/闪白)均收在 .style-retro 下;
|
|
15
|
-
* 像素工具类(.retro-pixel-border / .retro-pixel-button / .retro-pixel-rule)
|
|
16
|
-
* 有意保持全局可用——它们是纯几何装饰,任何风格都可取用。
|
|
17
|
-
* z-index 统一走 base.css 的 --z-fx 标尺(效果层,tooltip 之上)。
|
|
18
|
-
*
|
|
19
|
-
* 所有动画尊重 prefers-reduced-motion:在 reduce 下由 base.css 的全局兜底降为 0.01ms。
|
|
20
|
-
*/
|
|
21
|
-
|
|
22
|
-
/* ══════════════════════════════════════════════════════════════
|
|
23
|
-
CRT 显示器效果
|
|
24
|
-
══════════════════════════════════════════════════════════════ */
|
|
25
|
-
|
|
26
|
-
/* CRT 扫描线 overlay */
|
|
27
|
-
.style-retro body::before {
|
|
28
|
-
content: "";
|
|
29
|
-
position: fixed;
|
|
30
|
-
inset: 0;
|
|
31
|
-
pointer-events: none;
|
|
32
|
-
z-index: calc(var(--z-fx) - 1);
|
|
33
|
-
opacity: 0.14;
|
|
34
|
-
background:
|
|
35
|
-
repeating-linear-gradient(
|
|
36
|
-
0deg,
|
|
37
|
-
transparent,
|
|
38
|
-
transparent 2px,
|
|
39
|
-
rgba(0, 0, 0, 0.35) 2px,
|
|
40
|
-
rgba(0, 0, 0, 0.35) 4px
|
|
41
|
-
);
|
|
42
|
-
mix-blend-mode: multiply;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
.style-retro.dark body::before {
|
|
46
|
-
opacity: 0.22;
|
|
47
|
-
mix-blend-mode: screen;
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
/* CRT 暗角 + 轻微曲面 */
|
|
51
|
-
.style-retro body::after {
|
|
52
|
-
content: "";
|
|
53
|
-
position: fixed;
|
|
54
|
-
inset: 0;
|
|
55
|
-
pointer-events: none;
|
|
56
|
-
z-index: calc(var(--z-fx) - 2);
|
|
57
|
-
background:
|
|
58
|
-
radial-gradient(
|
|
59
|
-
ellipse at center,
|
|
60
|
-
transparent 55%,
|
|
61
|
-
rgba(0, 0, 0, 0.18) 100%
|
|
62
|
-
);
|
|
63
|
-
opacity: 0.55;
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
/* CRT 颗粒噪点 */
|
|
67
|
-
@keyframes retro-grain {
|
|
68
|
-
0%, 100% { background-position: 0 0; }
|
|
69
|
-
10% { background-position: -5% -10%; }
|
|
70
|
-
20% { background-position: -15% 5%; }
|
|
71
|
-
30% { background-position: 7% -25%; }
|
|
72
|
-
40% { background-position: -5% 25%; }
|
|
73
|
-
50% { background-position: -15% 10%; }
|
|
74
|
-
60% { background-position: 15% 0%; }
|
|
75
|
-
70% { background-position: 0% 15%; }
|
|
76
|
-
80% { background-position: 3% 35%; }
|
|
77
|
-
90% { background-position: -10% 10%; }
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
.style-retro .retro-crt-grain {
|
|
81
|
-
position: fixed;
|
|
82
|
-
inset: 0;
|
|
83
|
-
pointer-events: none;
|
|
84
|
-
z-index: calc(var(--z-fx) - 3);
|
|
85
|
-
opacity: 0.06;
|
|
86
|
-
background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
|
|
87
|
-
animation: retro-grain 0.5s steps(10) infinite;
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
/* ══════════════════════════════════════════════════════════════
|
|
91
|
-
全局动画关键帧 + 游走扫描光
|
|
92
|
-
══════════════════════════════════════════════════════════════ */
|
|
93
|
-
|
|
94
|
-
@keyframes retro-blink {
|
|
95
|
-
0%, 49% { opacity: 1; }
|
|
96
|
-
50%, 100% { opacity: 0; }
|
|
97
|
-
}
|
|
98
|
-
|
|
99
|
-
@keyframes retro-scanline-slide {
|
|
100
|
-
0% { transform: translateY(-100%); }
|
|
101
|
-
100% { transform: translateY(100vh); }
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
/* 游走的扫描线(偶尔闪过)—— 仅 .style-retro 下生效 */
|
|
105
|
-
.style-retro .retro-scanline-beam {
|
|
106
|
-
position: fixed;
|
|
107
|
-
left: 0;
|
|
108
|
-
right: 0;
|
|
109
|
-
height: 4px;
|
|
110
|
-
background: linear-gradient(
|
|
111
|
-
180deg,
|
|
112
|
-
transparent,
|
|
113
|
-
color-mix(in srgb, var(--token-accent) 30%, transparent),
|
|
114
|
-
transparent
|
|
115
|
-
);
|
|
116
|
-
pointer-events: none;
|
|
117
|
-
z-index: calc(var(--z-fx) - 4);
|
|
118
|
-
opacity: 0.4;
|
|
119
|
-
animation: retro-scanline-slide 4s linear infinite;
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
/* ══════════════════════════════════════════════════════════════
|
|
123
|
-
开机自检 / 打字机效果
|
|
124
|
-
══════════════════════════════════════════════════════════════ */
|
|
125
|
-
|
|
126
|
-
@keyframes retro-boot-text {
|
|
127
|
-
0% { opacity: 0; transform: translateY(4px); }
|
|
128
|
-
10% { opacity: 1; transform: translateY(0); }
|
|
129
|
-
90% { opacity: 1; transform: translateY(0); }
|
|
130
|
-
100% { opacity: 0; transform: translateY(-4px); }
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
.style-retro .retro-boot-line {
|
|
134
|
-
opacity: 0;
|
|
135
|
-
animation: retro-boot-text 0.3s steps(1) forwards;
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
.style-retro .retro-boot-line:nth-child(1) { animation-delay: 0.1s; }
|
|
139
|
-
.style-retro .retro-boot-line:nth-child(2) { animation-delay: 0.25s; }
|
|
140
|
-
.style-retro .retro-boot-line:nth-child(3) { animation-delay: 0.4s; }
|
|
141
|
-
.style-retro .retro-boot-line:nth-child(4) { animation-delay: 0.55s; }
|
|
142
|
-
.style-retro .retro-boot-line:nth-child(5) { animation-delay: 0.7s; }
|
|
143
|
-
|
|
144
|
-
/* 打字机光标 */
|
|
145
|
-
.style-retro .retro-cursor::after {
|
|
146
|
-
content: "█";
|
|
147
|
-
display: inline-block;
|
|
148
|
-
margin-left: 2px;
|
|
149
|
-
color: var(--token-accent);
|
|
150
|
-
animation: retro-blink 1s step-end infinite;
|
|
151
|
-
}
|
|
152
|
-
|
|
153
|
-
/* ══════════════════════════════════════════════════════════════
|
|
154
|
-
RGB 色散 / 霓虹发光(暗色下尤其出彩)
|
|
155
|
-
══════════════════════════════════════════════════════════════ */
|
|
156
|
-
|
|
157
|
-
.style-retro.dark .retro-glow {
|
|
158
|
-
text-shadow:
|
|
159
|
-
-1px 0 0 rgba(255, 0, 0, 0.4),
|
|
160
|
-
1px 0 0 rgba(0, 255, 255, 0.4),
|
|
161
|
-
0 0 2px var(--token-accent),
|
|
162
|
-
0 0 8px var(--token-accent);
|
|
163
|
-
}
|
|
164
|
-
|
|
165
|
-
.style-retro.dark .retro-glow-cold {
|
|
166
|
-
text-shadow:
|
|
167
|
-
-1px 0 0 rgba(255, 0, 0, 0.4),
|
|
168
|
-
1px 0 0 rgba(0, 255, 255, 0.4),
|
|
169
|
-
0 0 2px var(--token-accent-cold),
|
|
170
|
-
0 0 8px var(--token-accent-cold);
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
/* 亮色模式下发光退化为单层硬投影,保持像素感而不刺眼 */
|
|
174
|
-
.style-retro:not(.dark) .retro-glow {
|
|
175
|
-
text-shadow:
|
|
176
|
-
1px 1px 0 color-mix(in srgb, var(--token-accent) 30%, transparent);
|
|
177
|
-
}
|
|
178
|
-
|
|
179
|
-
/* ══════════════════════════════════════════════════════════════
|
|
180
|
-
像素边框工具类(任意风格下可用,但与 retro 最契合)
|
|
181
|
-
══════════════════════════════════════════════════════════════ */
|
|
182
|
-
|
|
183
|
-
.retro-pixel-border {
|
|
184
|
-
border: 2px solid var(--token-line);
|
|
185
|
-
box-shadow:
|
|
186
|
-
2px 2px 0 var(--token-line-strong),
|
|
187
|
-
inset 2px 2px 0 var(--token-surface-strong),
|
|
188
|
-
inset -2px -2px 0 var(--token-line-soft);
|
|
189
|
-
}
|
|
190
|
-
|
|
191
|
-
.retro-pixel-border-accent {
|
|
192
|
-
border: 2px solid var(--token-accent);
|
|
193
|
-
box-shadow:
|
|
194
|
-
2px 2px 0 var(--token-accent-cold),
|
|
195
|
-
inset 2px 2px 0 color-mix(in srgb, var(--token-accent) 20%, transparent),
|
|
196
|
-
inset -2px -2px 0 color-mix(in srgb, var(--token-accent) 40%, transparent);
|
|
197
|
-
}
|
|
198
|
-
|
|
199
|
-
/* 像素按钮:硬投影 + 按下内移 */
|
|
200
|
-
.retro-pixel-button {
|
|
201
|
-
position: relative;
|
|
202
|
-
border: 2px solid var(--token-line-strong);
|
|
203
|
-
box-shadow:
|
|
204
|
-
inset -2px -2px 0 var(--token-line-soft),
|
|
205
|
-
inset 2px 2px 0 var(--token-surface-strong),
|
|
206
|
-
2px 2px 0 var(--token-line);
|
|
207
|
-
transition: none;
|
|
208
|
-
}
|
|
209
|
-
|
|
210
|
-
.retro-pixel-button:active {
|
|
211
|
-
transform: translate(2px, 2px);
|
|
212
|
-
box-shadow:
|
|
213
|
-
inset -2px -2px 0 var(--token-line-soft),
|
|
214
|
-
inset 2px 2px 0 var(--token-surface-strong);
|
|
215
|
-
}
|
|
216
|
-
|
|
217
|
-
/* ══════════════════════════════════════════════════════════════
|
|
218
|
-
选中文字 / 像素分隔线
|
|
219
|
-
══════════════════════════════════════════════════════════════ */
|
|
220
|
-
|
|
221
|
-
.style-retro ::selection {
|
|
222
|
-
background: var(--token-accent);
|
|
223
|
-
color: var(--token-on-accent);
|
|
224
|
-
}
|
|
225
|
-
|
|
226
|
-
.retro-pixel-rule {
|
|
227
|
-
height: 0;
|
|
228
|
-
border: 0;
|
|
229
|
-
border-top: 2px dashed var(--token-line);
|
|
230
|
-
image-rendering: pixelated;
|
|
231
|
-
}
|
|
232
|
-
|
|
233
|
-
/* ══════════════════════════════════════════════════════════════
|
|
234
|
-
页面切换 / 闪白效果
|
|
235
|
-
══════════════════════════════════════════════════════════════ */
|
|
236
|
-
|
|
237
|
-
@keyframes retro-flash {
|
|
238
|
-
0% { opacity: 0; }
|
|
239
|
-
10% { opacity: 0.8; }
|
|
240
|
-
100% { opacity: 0; }
|
|
241
|
-
}
|
|
242
|
-
|
|
243
|
-
.style-retro .retro-page-flash {
|
|
244
|
-
position: fixed;
|
|
245
|
-
inset: 0;
|
|
246
|
-
pointer-events: none;
|
|
247
|
-
z-index: var(--z-fx);
|
|
248
|
-
background: var(--token-bg);
|
|
249
|
-
opacity: 0;
|
|
250
|
-
}
|
|
251
|
-
|
|
252
|
-
/* 状态类遵循全库 .is-* 规范 */
|
|
253
|
-
.style-retro .retro-page-flash.is-active {
|
|
254
|
-
animation: retro-flash 0.2s steps(3) forwards;
|
|
255
|
-
}
|