Files
codex-bot c405f47916
Endoleap brand checks / verify (pull_request) Failing after 5s
creative workspace review checks / verify (pull_request) Has been cancelled
feat(brand): add Endoleap assets and production theme package
2026-11-01 00:22:43 +08:00

14 lines
1.2 KiB
JavaScript

// Real Tailwind compilation belongs to remote Docker CI, never the local check command.
import assert from 'node:assert/strict';
import { readFile } from 'node:fs/promises';
import postcss from 'postcss';
import tailwind from '@tailwindcss/postcss';
const root = new URL('../', import.meta.url);
const source = `@import "tailwindcss";\n${await readFile(new URL('src/tailwind.css', root), 'utf8')}\n@source inline("bg-background text-foreground bg-card text-card-foreground bg-primary text-primary-foreground bg-accent text-accent-foreground border-input ring-ring bg-sidebar text-sidebar-foreground rounded-lg dark:bg-background bg-brand-mocha");`;
const result = await postcss([tailwind({ base: root.pathname })]).process(source, { from: new URL('fixture.css', root).pathname });
for (const token of ['background', 'card', 'primary', 'accent', 'sidebar', 'brand-mocha']) assert.ok(result.css.includes(`background-color: var(--${token})`), token);
assert.ok(result.css.includes('border-color: var(--input)'));
assert.ok(result.css.includes('var(--ring)'));
assert.ok(!result.css.includes('@theme inline'));
console.log('Tailwind v4 compiled standard shadcn, sidebar, brand, radius and dark utilities.');