Files
malenia-frontend/.design/system/scripts/apply-design-tokens.mjs
2026-08-10 12:01:03 +07:00

18 lines
599 B
JavaScript

#!/usr/bin/env node
import fs from 'node:fs';
import path from 'node:path';
import { fileURLToPath } from 'node:url';
const target = process.argv[2];
if (!target) {
console.error('Usage: node scripts/apply-design-tokens.mjs <target-css-path>');
process.exit(1);
}
const here = path.dirname(fileURLToPath(import.meta.url));
const source = path.resolve(here, '..', 'variables.css');
const destination = path.resolve(process.cwd(), target);
fs.mkdirSync(path.dirname(destination), { recursive: true });
fs.copyFileSync(source, destination);
console.log(`Copied design tokens to ${destination}`);