Skip to content

pantoken / custom-icons

custom-icons

Beta

@pantoken/plugin-custom-icons — vendored custom icon glyphs for downstream consumers.

Brings in icons that aren't part of the InstUI set (product/brand marks, etc.) as --instui-icon-<name> image tokens — the same namespace and .-icon-<name> painter class the built-in InstUI icons use, so a custom icon drops into .instui-icon -icon-<name> exactly like a built-in one. No custom- prefix: on a name collision, the built-in InstUI icon should win (load it after this plugin's CSS in any combine URL).

Example

ts
import { toCss } from "@pantoken/css";
import { byTheme } from "@pantoken/tokens";
import { customIcons } from "@pantoken/plugin-custom-icons";

const css = toCss(byTheme("rebrand"), { plugins: [customIcons({ names: ["highspot"] })] });
// adds --instui-icon-highspot as an <image> token

Interfaces

Variables

Functions

References

default

Renames and re-exports customIcons