Files
Clintchiz 2c960fc1dc
Quality / quality (ubuntu-latest) (push) Failing after 9m49s
Quality / quality (windows-latest) (push) Canceled after 0s
refactor: migrate legacy wire namespace to wrn
2026-08-12 18:51:15 +05:30

13 lines
507 B
TypeScript

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(--wrn-color-primary)");
expect(themeVar("color-text", "#111")).toBe("var(--wrn-color-text, #111)");
});