release: WRNexusJS 0.8.0
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
import { expect, test } from "bun:test";
|
||||
import { defineThemeTokens, themeVar } from "../src/index.ts";
|
||||
|
||||
test("typed theme token helpers preserve custom tokens and emit CSS variables", () => {
|
||||
const tokens = defineThemeTokens({
|
||||
"color-primary": "#2563eb",
|
||||
"space-product-card": "1rem",
|
||||
});
|
||||
expect(tokens["space-product-card"]).toBe("1rem");
|
||||
expect(themeVar("color-primary")).toBe("var(--wire-color-primary)");
|
||||
expect(themeVar("color-text", "#111")).toBe("var(--wire-color-text, #111)");
|
||||
});
|
||||
Reference in New Issue
Block a user