Skip to content

pantoken / custom-theme-colors

custom-theme-colors

Beta

@pantoken/plugin-custom-components — 供下游使用者的自定义组件。

输出作用域:root[data-pantoken-color="…"]:root[data-pantoken-theme="canvasHighContrast"][data-pantoken-color="…"] 规则,适用于所有13个颜色命名空间(navy, blue, green, red, orange, grey, plum, violet, stone, sky, honey, sea, aurora)。

示例

ts
import { toCss } from "@pantoken/css";
import { byTheme } from "@pantoken/tokens";
import { customThemeColors } from "@pantoken/plugin-custom-theme-colors";

const css = toCss(byTheme("rebrand"), { plugins: [customThemeColors()] });

接口

类型别名

变量

函数

引用

default

重命名并重新导出 customIcons