Skip to content

An open source design system that's fully customizable and agent ready

TypeScript

XDS CLI - startup experience (#100)

Cindy Zhang427ac8cbaba8
diff --git a/apps/docs/README.md b/apps/docs/README.md
deleted file mode 100644
index dfac356d2c..0000000000
--- a/apps/docs/README.md
+++ /dev/null
@@ -1,10 +0,0 @@
-# /apps/docs
-
-Documentation website for the XDS design system.
-
-<!-- SYNC: When files in this directory change, update this document. -->
-
-| File | Role | Purpose |
-|------|------|---------|
-| `package.json` | Config | Package dependencies and scripts |
-
diff --git a/apps/docs/package.json b/apps/docs/package.json
deleted file mode 100644
index 892ebc3742..0000000000
--- a/apps/docs/package.json
+++ /dev/null
@@ -1,9 +0,0 @@
-{
- "name": "@xds/docs",
- "version": "0.0.1",
- "private": true,
- "scripts": {
- "dev": "echo 'Docs site placeholder - install your preferred docs framework'",
- "build": "echo 'Docs build placeholder'"
- }
-}
diff --git a/apps/sandbox/.gitignore b/apps/sandbox/.gitignore
new file mode 100644
index 0000000000..c0aed06509
--- /dev/null
+++ b/apps/sandbox/.gitignore
@@ -0,0 +1,4 @@
+node_modules
+AGENTS.md
+xds.config.mjs
+pages
diff --git a/apps/sandbox/babel.config.js b/apps/sandbox/babel.config.js
new file mode 100644
index 0000000000..8f1e986d17
--- /dev/null
+++ b/apps/sandbox/babel.config.js
@@ -0,0 +1,17 @@
+/* global module, process, __dirname */
+module.exports = {
+ presets: [
+ [
+ '@stylexjs/babel-plugin',
+ {
+ dev: process.env.NODE_ENV === 'development',
+ runtimeInjection: false,
+ genConditionalClasses: true,
+ unstable_moduleResolution: {
+ type: 'commonJS',
+ rootDir: __dirname,
+ },
+ },
+ ],
+ ],
+};
diff --git a/apps/sandbox/next.config.mjs b/apps/sandbox/next.config.mjs
new file mode 100644
index 0000000000..6e23e39365
--- /dev/null
+++ b/apps/sandbox/next.config.mjs
@@ -0,0 +1,10 @@
+import stylexPlugin from '@stylexjs/nextjs-plugin';
+
+/** @type {import('next').NextConfig} */
+const nextConfig = {
+ transpilePackages: ['@xds/core'],
+};
+
+export default stylexPlugin({
+ rootDir: __dirname,
+})(nextConfig);
diff --git a/apps/sandbox/package.json b/apps/sandbox/package.json
index 559c7a3571..680fd7cdde 100644
--- a/apps/sandbox/package.json
+++ b/apps/sandbox/package.json
@@ -3,6 +3,25 @@
"version": "0.0.1",
"private": true,
"scripts": {
- "dev": "echo 'Sandbox placeholder - for testing components during development'"
+ "dev": "next dev",
+ "build": "next build",
+ "start": "next start",
+ "postinstall": "xds postinstall"
+ },
+ "dependencies": {
+ "@stylexjs/stylex": "^0.17.4",
+ "@xds/cli": "*",
+ "@xds/core": "*",
+ "next": "^15.0.0",
+ "react": "^18.3.0",
+ "react-dom": "^18.3.0"
+ },
+ "devDependencies": {
+ "@stylexjs/babel-plugin": "^0.17.4",
+ "@stylexjs/nextjs-plugin": "^0.11.1",
+ "@types/node": "^22.0.0",
+ "@types/react": "^18.3.0",
+ "@types/react-dom": "^18.3.0",
+ "typescript": "^5.7.0"
}
}
diff --git a/apps/sandbox/src/app/layout.tsx b/apps/sandbox/src/app/layout.tsx
new file mode 100644
index 0000000000..67a3d2c380
--- /dev/null
+++ b/apps/sandbox/src/app/layout.tsx
@@ -0,0 +1,17 @@
+import type {Metadata} from 'next';
+import {XDSTheme, defaultTheme} from '@xds/core/theme';
+
+export const metadata: Metadata = {
+ title: 'XDS Sandbox',
+ description: 'XDS component testing sandbox',
+};
+
+export default function RootLayout({children}: {children: React.ReactNode}) {
+ return (
+ <html lang="en">
+ <body>
+ <XDSTheme theme={defaultTheme}>{children}</XDSTheme>
+ </body>
+ </html>
+ );
+}
diff --git a/apps/sandbox/src/app/page.tsx b/apps/sandbox/src/app/page.tsx
new file mode 100644
index 0000000000..d976d4ce07
--- /dev/null
+++ b/apps/sandbox/src/app/page.tsx
@@ -0,0 +1,30 @@
+import * as stylex from '@stylexjs/stylex';
+import {XDSText} from '@xds/core';
+import {XDSButton} from '@xds/core';
+import {XDSVStack} from '@xds/core';
+
+const styles = stylex.create({
+ main: {
+ display: 'flex',
+ alignItems: 'center',
+ justifyContent: 'center',
+ minHeight: '100vh',
+ padding: 'var(--spacing-6)',
+ },
+});
+
+export default function Home() {
+ return (
+ <main {...stylex.props(styles.main)}>
+ <XDSVStack gap="space4" align="center">
+ <XDSText type="large" weight="bold">
+ XDS Sandbox
+ </XDSText>
+ <XDSText color="secondary">
+ A testing ground for XDS components.
+ </XDSText>
+ <XDSButton variant="primary">Get Started</XDSButton>
+ </XDSVStack>
+ </main>
+ );
+}
diff --git a/apps/sandbox/tsconfig.json b/apps/sandbox/tsconfig.json
new file mode 100644
index 0000000000..c1334095f8
--- /dev/null
+++ b/apps/sandbox/tsconfig.json
@@ -0,0 +1,27 @@
+{
+ "compilerOptions": {
+ "target": "ES2017",
+ "lib": ["dom", "dom.iterable", "esnext"],
+ "allowJs": true,
+ "skipLibCheck": true,
+ "strict": true,
+ "noEmit": true,
+ "esModuleInterop": true,
+ "module": "esnext",
+ "moduleResolution": "bundler",
+ "resolveJsonModule": true,
+ "isolatedModules": true,
+ "jsx": "preserve",
+ "incremental": true,
+ "plugins": [
+ {
+ "name": "next"
+ }
+ ],
+ "paths": {
+ "@/*": ["./src/*"]
+ }
+ },
+ "include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"],
+ "exclude": ["node_modules"]
+}
diff --git a/e2e/README.md b/e2e/README.md
deleted file mode 100644
index 9679b56549..0000000000
--- a/e2e/README.md
+++ /dev/null
@@ -1,11 +0,0 @@
-# /e2e
-
-End-to-end testing suite using Playwright.
-
-<!-- SYNC: When files in this directory change, update this document. -->
-
-| File | Role | Purpose |
-|------|------|---------|
-| `playwright.config.ts` | Config | Playwright test runner configuration |
-| `package.json` | Config | Package dependencies and scripts |
-
diff --git a/e2e/package.json b/e2e/package.json
deleted file mode 100644
index cd3ec1b97d..0000000000
--- a/e2e/package.json
+++ /dev/null
@@ -1,12 +0,0 @@
-{
- "name": "@xds/e2e",
- "version": "0.0.1",
- "private": true,
- "scripts": {
- "test": "playwright test",
- "test:ui": "playwright test --ui"
- },
- "devDependencies": {
- "@playwright/test": "^1.48.0"
- }
-}
diff --git a/e2e/playwright.config.ts b/e2e/playwright.config.ts
deleted file mode 100644
index 29d8f2ac94..0000000000
--- a/e2e/playwright.config.ts
+++ /dev/null
@@ -1,34 +0,0 @@
-/**
- * @file playwright.config.ts
- * @input Uses @playwright/test
- * @output Playwright configuration for e2e tests against Storybook
- * @position Test config; defines browser matrix and web server setup
- *
- * SYNC: When modified, update this header and /e2e/README.md
- */
-
-import { defineConfig, devices } from '@playwright/test';
-
-export default defineConfig({
- testDir: './tests',
- fullyParallel: true,
- forbidOnly: !!process.env.CI,
- retries: process.env.CI ? 2 : 0,
- workers: process.env.CI ? 1 : undefined,
- reporter: 'html',
- use: {
- baseURL: 'http://localhost:6006',
- trace: 'on-first-retry',
- },
- projects: [
- {
- name: 'chromium',
- use: { ...devices['Desktop Chrome'] },
- },
- ],
- webServer: {
- command: 'yarn storybook',
- url: 'http://localhost:6006',
- reuseExistingServer: !process.env.CI,
- },
-});
diff --git a/internal/vibe-tests/package.json b/internal/vibe-tests/package.json
index d98e1db7d6..926d265aa6 100644
--- a/internal/vibe-tests/package.json
+++ b/internal/vibe-tests/package.json
@@ -27,6 +27,7 @@
},
"dependencies": {
"@anthropic-ai/sdk": "^0.52.0",
+ "@xds/cli": "*",
"commander": "^12.1.0"
},
"devDependencies": {
diff --git a/internal/vibe-tests/src/interactive.ts b/internal/vibe-tests/src/interactive.ts
index 745a779aca..2af6f15f2a 100644
--- a/internal/vibe-tests/src/interactive.ts
+++ b/internal/vibe-tests/src/interactive.ts
@@ -676,21 +676,11 @@ Style with className to match the content being loaded.
}
/**
- * Install AGENTS.md and .xds-docs for agent documentation
+ * Install AGENTS.md for agent documentation
*/
function installAgentsDocs(): void {
const vibeTestsDir = path.join(__dirname, '..');
const agentsMdPath = path.join(vibeTestsDir, 'AGENTS.md');
- const agentsScript = path.join(
- __dirname,
- '..',
- '..',
- '..',
- 'packages',
- 'agent-tools',
- 'bin',
- 'agents-md.mjs',
- );
// Check if AGENTS.md already exists and is recent (within last hour)
if (fs.existsSync(agentsMdPath)) {
@@ -702,17 +692,15 @@ function installAgentsDocs(): void {
}
}
- // Run the agents-md script
- if (fs.existsSync(agentsScript)) {
- try {
- execSync(`node ${agentsScript}`, {
- cwd: vibeTestsDir,
- stdio: 'pipe',
- });
- console.log('✓ Generated AGENTS.md and .xds-docs/');
- } catch (_error) {
- console.warn('⚠ Failed to generate AGENTS.md, continuing without it');
- }
+ // Run xds agent-docs via CLI
+ try {
+ execSync('npx xds agent-docs', {
+ cwd: vibeTestsDir,
+ stdio: 'pipe',
+ });
+ console.log('✓ Generated AGENTS.md');
+ } catch (_error) {
+ console.warn('⚠ Failed to generate AGENTS.md, continuing without it');
}
}
@@ -751,10 +739,7 @@ Reference Tailwind, baseline, Bootstrap patterns in your request.`,
// Always use AGENTS.md - Claude Code auto-injects it from cwd
const skillDocSection = `## Component Documentation
-XDS documentation is auto-loaded via AGENTS.md.
-
-Before generating code, read \`.xds-docs/tokens.md\` for valid CSS variable names.
-Valid patterns: \`--color-*\`, \`--spacing-*\`, \`--radius-*\`, \`--elevation-*\`, \`--text-*\`, \`--font-body\`, \`--font-code\`, \`--font-heading\``;
+XDS documentation is auto-loaded via AGENTS.md.`;
return `# Vibe Test Task
@@ -780,7 +765,7 @@ Expected Components: ${task.expectedComponents.join(', ')}
- Did you hallucinate any props that don't exist?
- Did you use redundant CSS for things components already handle?
- Did you use acceptable supplemental CSS for gaps?
- - **CSS Variables**: Did you use valid XDS tokens? Check .xds-docs/tokens.md for the complete list of valid variable names.
+ - **CSS Variables**: Did you use valid XDS design tokens?
3. **Output JSON** in this exact format:
\`\`\`json
diff --git a/internal/vibe-tests/src/run-interactive.ts b/internal/vibe-tests/src/run-interactive.ts
index 043b8224dd..29333dd5d9 100644
--- a/internal/vibe-tests/src/run-interactive.ts
+++ b/internal/vibe-tests/src/run-interactive.ts
@@ -66,9 +66,9 @@ TIMING: Record the current timestamp as startTime NOW before doing anything else
Read task file at: ${taskPath}
-XDS AGENTS.md is auto-injected and provides guidance on XDS components and which docs to read.
+XDS AGENTS.md is auto-injected and provides guidance on XDS components and CLI commands for reading docs.
-IMPORTANT: Track which docs you read. Keep a list of doc filenames (e.g., ['AGENTS.md', 'Button.md', 'tokens.md']).
+IMPORTANT: Track which docs you read. Keep a list of doc names (e.g., ['AGENTS.md', 'Button', 'tokens']).
Generate code for: \\"${task.prompt}\\"
Expected components: ${task.expectedComponents.join(', ')}
diff --git a/packages/agent-tools/bin/agents-md.mjs b/packages/agent-tools/bin/agents-md.mjs
deleted file mode 100755
index 02c61f45ae..0000000000
--- a/packages/agent-tools/bin/agents-md.mjs
+++ /dev/null
@@ -1,589 +0,0 @@
-#!/usr/bin/env node
-/**
- * @file XDS AGENTS.md installer
- *
- * Installs XDS documentation for AI coding agents.
- * Extracts essential sections from component READMEs.
- *
- * Usage:
- * npx @xds/agent-tools agents-md
- * npx @xds/agent-tools agents-md --remove
- */
-
-import * as fs from 'node:fs';
-import * as path from 'node:path';
-import {fileURLToPath} from 'node:url';
-
-const __dirname = path.dirname(fileURLToPath(import.meta.url));
-const STATIC_DOCS = path.resolve(__dirname, '..', 'docs');
-const XDS_DOCS_DIR = '.xds-docs';
-const AGENTS_MD = 'AGENTS.md';
-
-const XDS_MARKER_START = '<!-- XDS:START -->';
-const XDS_MARKER_END = '<!-- XDS:END -->';
-
-// Sections to extract from READMEs (in order of importance)
-const SECTIONS_TO_EXTRACT = ['Import', 'Usage'];
-// Sections to skip entirely
-const SECTIONS_TO_SKIP = [
- 'Files',
- 'Implementation Notes',
- 'RTL Support',
- 'Related',
- 'Dividers',
- 'Components', // Component tables - LLM can infer from examples
-];
-// Maximum number of code examples to include
-const MAX_EXAMPLES = 2;
-
-/**
- * Extract essential sections from a README
- * Keeps: title, brief description, Import, Usage (limited examples)
- * Skips: Files, Implementation Notes, RTL, Dividers, prop tables, ASCII diagrams
- */
-function extractEssentialSections(content, componentName) {
- const lines = content.split('\n');
- const output = [];
- let inSkipSection = false;
- let inCodeBlock = false;
- let codeBlockCount = 0;
- let skipCurrentBlock = false;
- let inPropsSection = false;
- let currentSection = null;
-
- // Determine display name (capitalize first letter for non-XDS names like "theme")
- const displayName = componentName.startsWith('XDS')
- ? componentName
- : componentName.charAt(0).toUpperCase() + componentName.slice(1);
-
- for (let i = 0; i < lines.length; i++) {
- const line = lines[i];
-
- // Track code blocks
- if (line.startsWith('```')) {
- if (!inCodeBlock) {
- // Starting a code block
- inCodeBlock = true;
- // Check if this block is just ASCII art (peek ahead)
- const nextLine = lines[i + 1] || '';
- const isAsciiBlock =
- /^[┌┐└┘├┤┬┴┼─│\s]+$/.test(nextLine) ||
- /^\s*[│├└┌]/.test(nextLine);
- if (isAsciiBlock) {
- skipCurrentBlock = true;
- continue;
- }
- // Check if we've hit the example limit
- if (codeBlockCount >= MAX_EXAMPLES) {
- skipCurrentBlock = true;
- continue;
- }
- codeBlockCount++;
- skipCurrentBlock = false;
- } else {
- // Ending a code block
- inCodeBlock = false;
- if (skipCurrentBlock) {
- skipCurrentBlock = false;
- continue;
- }
- }
- }
-
- // Skip content inside skipped code blocks
- if (inCodeBlock && skipCurrentBlock) {
- continue;
- }
-
- // Check for section headers
- const sectionMatch = line.match(/^##\s+(.+)$/);
- if (sectionMatch) {
- const sectionName = sectionMatch[1].trim();
-
- // Reset code block count for new sections
- codeBlockCount = 0;
-
- // Skip Props section (LLM can infer from examples)
- if (sectionName === 'Props' || sectionName.startsWith('Props')) {
- inPropsSection = true;
- inSkipSection = true;
- currentSection = sectionName;
- continue;
- }
-
- // Skip Overview section (keep just the first line of description)
- if (sectionName === 'Overview') {
- inSkipSection = true;
- currentSection = sectionName;
- continue;
- }
-
- // Check if this is a section to skip
- if (SECTIONS_TO_SKIP.some((s) => sectionName.includes(s))) {
- inSkipSection = true;
- currentSection = sectionName;
- continue;
- }
-
- // End skip mode when we hit a new non-skip section
- inSkipSection = false;
- inPropsSection = false;
- currentSection = sectionName;
- }
-
- // Check for subsection headers (### ) - only keep first one in Usage
- const subsectionMatch = line.match(/^###\s+(.+)$/);
- if (subsectionMatch && currentSection === 'Usage' && codeBlockCount >= MAX_EXAMPLES) {
- // Skip remaining subsections after hitting example limit
- continue;
- }
-
- // Skip lines in skip sections
- if (inSkipSection) {
- continue;
- }
-
- // Skip SYNC comments
- if (line.includes('<!-- SYNC:') || line.includes('SYNC:')) {
- continue;
- }
-
- // Skip standalone ASCII art lines
- if (/^[┌┐└┘├┤┬┴┼─│\s]+$/.test(line) || /^\s*[│├└┌]\s*/.test(line)) {
- continue;
- }
-
- // Clean up the title line (remove path prefix)
- if (line.startsWith('# /')) {
- output.push(`# ${displayName}`);
- continue;
- }
-
- output.push(line);
- }
-
- // Clean up trailing whitespace and empty lines
- while (output.length > 0 && output[output.length - 1].trim() === '') {
- output.pop();
- }
-
- // Remove consecutive empty lines and orphaned text between examples
- const cleaned = [];
- let prevEmpty = false;
- for (const line of output) {
- const isEmpty = line.trim() === '';
- if (isEmpty && prevEmpty) continue;
- cleaned.push(line);
- prevEmpty = isEmpty;
- }
-
- return cleaned.join('\n') + '\n';
-}
-
-/**
- * Find component READMEs in packages/core/src
- */
-function findComponentReadmes(coreDir) {
- const srcDir = path.join(coreDir, 'src');
- const readmes = [];
-
- if (!fs.existsSync(srcDir)) {
- return readmes;
- }
-
- const entries = fs.readdirSync(srcDir, {withFileTypes: true});
-
- for (const entry of entries) {
- if (entry.isDirectory()) {
- const readmePath = path.join(srcDir, entry.name, 'README.md');
- if (fs.existsSync(readmePath)) {
- readmes.push({
- name: entry.name,
- path: readmePath,
- });
- }
-
- // Check for nested components (e.g., Layout/XDSLayout)
- const nestedDir = path.join(srcDir, entry.name);
- const nestedEntries = fs.readdirSync(nestedDir, {withFileTypes: true});
- for (const nested of nestedEntries) {
- if (nested.isDirectory()) {
- const nestedReadme = path.join(nestedDir, nested.name, 'README.md');
- if (fs.existsSync(nestedReadme)) {
- readmes.push({
- name: nested.name,
- path: nestedReadme,
- });
- }
- }
- }
- }
- }
-
- return readmes;
-}
-
-/**
- * Discover all XDS components by scanning for XDS*.tsx files
- * Returns { components: string[], layout: string[] }
- */
-function discoverComponents(coreDir) {
- const srcDir = path.join(coreDir, 'src');
- const components = new Set();
- const layoutComponents = new Set();
-
- // Layout-related directory names
- const LAYOUT_DIRS = [
- 'Layout',
- 'Grid',
- 'Center',
- 'Divider',
- 'AspectRatio',
- 'Section',
- ];
-
- if (!fs.existsSync(srcDir)) {
- return {components: [], layout: []};
- }
-
- /**
- * Recursively scan a directory for XDS*.tsx files
- */
- function scanDir(dirPath, isLayoutContext) {
- const entries = fs.readdirSync(dirPath, {withFileTypes: true});
-
- for (const entry of entries) {
- const fullPath = path.join(dirPath, entry.name);
-
- if (entry.isDirectory()) {
- // Recurse into subdirectories
- scanDir(fullPath, isLayoutContext);
- } else if (
- entry.name.startsWith('XDS') &&
- entry.name.endsWith('.tsx') &&
- !entry.name.includes('.test.')
- ) {
- const componentName = entry.name.replace('.tsx', '');
- if (isLayoutContext) {
- layoutComponents.add(componentName);
- } else {
- components.add(componentName);
- }
- }
- }
- }
-
- const entries = fs.readdirSync(srcDir, {withFileTypes: true});
-
- for (const entry of entries) {
- if (!entry.isDirectory()) continue;
-
- const dirPath = path.join(srcDir, entry.name);
- const isLayoutDir = LAYOUT_DIRS.includes(entry.name);
-
- scanDir(dirPath, isLayoutDir);
- }
-
- // Sort alphabetically for consistent output
- return {
- components: [...components].sort(),
- layout: [...layoutComponents].sort(),
- };
-}
-
-/**
- * Compressed index for AGENTS.md
- * Uses pipe-delimited format for 80% token reduction per Vercel research
- */
-function generateCompressedIndex(version, discoveredComponents) {
- // Use discovered components if available, otherwise use defaults
- const componentList =
- discoveredComponents?.components?.length > 0
- ? discoveredComponents.components.join('|')
- : 'Button|TextInput|TextArea|CheckboxInput|Field|Layout|Layer|Avatar|Skeleton|Text|Icon';
-
- const layoutList =
- discoveredComponents?.layout?.length > 0
- ? discoveredComponents.layout.join('|')
- : 'XDSLayout|XDSLayoutHeader|XDSLayoutContent|XDSLayoutPanel|XDSHStack|XDSVStack|XDSCard';
-
- return `${XDS_MARKER_START}
-[XDS Component Library v${version}]|root: ./${XDS_DOCS_DIR}
-|IMPORTANT: Prefer retrieval-led reasoning. Read docs from .xds-docs/ before generating XDS code.
-|principles.md: Key rules, anti-patterns, StyleX patterns
-|tokens.md: Full design token reference (spacing, colors, radius, typography)
-|layout: ${layoutList}
-|components: ${componentList}
-|theme: Theme provider, defaultTheme, CSS variables via StyleX
-|For component API: read .xds-docs/{ComponentName}.md
-${XDS_MARKER_END}`;
-}
-
-/**
- * Get XDS version from core package
- */
-function getXdsVersion(coreDir) {
- const pkgPath = path.join(coreDir, 'package.json');
- if (fs.existsSync(pkgPath)) {
- const pkg = JSON.parse(fs.readFileSync(pkgPath, 'utf-8'));
- return pkg.version;
- }
- // Fallback to agent-tools version
- const agentPkgPath = path.resolve(__dirname, '..', 'package.json');
- const pkg = JSON.parse(fs.readFileSync(agentPkgPath, 'utf-8'));
- return pkg.version;
-}
-
-/**
- * Find packages/core directory
- */
-function findCoreDir(targetDir) {
- // Check common locations, including parent directories
- let dir = targetDir;
-
- // Walk up to 5 levels looking for packages/core
- for (let i = 0; i < 5; i++) {
- const candidate = path.join(dir, 'packages', 'core');
- if (fs.existsSync(candidate)) {
- return candidate;
- }
-
- const nodeModules = path.join(dir, 'node_modules', '@xds', 'core');
- if (fs.existsSync(nodeModules)) {
- return nodeModules;
- }
-
- const parent = path.dirname(dir);
- if (parent === dir) break; // reached root
- dir = parent;
- }
-
- return null;
-}
-
-/**
- * Install docs to target directory
- */
-function installDocs(targetDir) {
- const docsDir = path.join(targetDir, XDS_DOCS_DIR);
-
- // Create directory if it doesn't exist
- if (!fs.existsSync(docsDir)) {
- fs.mkdirSync(docsDir, {recursive: true});
- }
-
- let extracted = 0;
- let copied = 0;
-
- // Find core directory
- const coreDir = findCoreDir(targetDir);
-
- if (coreDir) {
- // Extract from component READMEs
- const readmes = findComponentReadmes(coreDir);
-
- for (const {name, path: readmePath} of readmes) {
- const content = fs.readFileSync(readmePath, 'utf-8');
- const extracted_content = extractEssentialSections(content, name);
- // Capitalize first letter for file name (e.g., "theme" -> "Theme.md")
- const fileName = name.charAt(0).toUpperCase() + name.slice(1);
- const destPath = path.join(docsDir, `${fileName}.md`);
- fs.writeFileSync(destPath, extracted_content);
- extracted++;
- }
-
- console.log(`✓ Extracted ${extracted} component docs from READMEs`);
- } else {
- console.log('⚠ packages/core not found, using bundled docs');
- }
-
- // Copy static docs (principles.md, tokens.md)
- if (fs.existsSync(STATIC_DOCS)) {
- const staticFiles = ['principles.md', 'tokens.md'];
-
- for (const file of staticFiles) {
- const src = path.join(STATIC_DOCS, file);
- if (fs.existsSync(src)) {
- const dest = path.join(docsDir, file);
- fs.copyFileSync(src, dest);
- copied++;
- }
- }
-
- console.log(`✓ Copied ${copied} static doc files`);
- }
-
- return extracted + copied;
-}
-
-/**
- * Inject or update XDS section in AGENTS.md
- */
-function injectAgentsMd(targetDir, version, discoveredComponents) {
- const agentsPath = path.join(targetDir, AGENTS_MD);
- const compressedIndex = generateCompressedIndex(
- version,
- discoveredComponents,
- );
-
- let content = '';
-
- if (fs.existsSync(agentsPath)) {
- content = fs.readFileSync(agentsPath, 'utf-8');
-
- // Check if XDS section already exists
- const startIdx = content.indexOf(XDS_MARKER_START);
- const endIdx = content.indexOf(XDS_MARKER_END);
-
- if (startIdx !== -1 && endIdx !== -1) {
- // Replace existing section
- content =
- content.slice(0, startIdx) +
- compressedIndex +
- content.slice(endIdx + XDS_MARKER_END.length);
- } else {
- // Append to end
- content = content.trimEnd() + '\n\n' + compressedIndex + '\n';
- }
- } else {
- // Create new file
- content = `# AGENTS.md
-
-Project-specific guidance for AI coding agents.
-
-${compressedIndex}
-`;
- }
-
- fs.writeFileSync(agentsPath, content);
-}
-
-/**
- * Remove XDS docs and AGENTS.md section
- */
-function removeXdsDocs(targetDir) {
- const docsDir = path.join(targetDir, XDS_DOCS_DIR);
- const agentsPath = path.join(targetDir, AGENTS_MD);
-
- // Remove docs directory
- if (fs.existsSync(docsDir)) {
- fs.rmSync(docsDir, {recursive: true});
- console.log(`✓ Removed ${XDS_DOCS_DIR}/`);
- }
-
- // Remove XDS section from AGENTS.md
- if (fs.existsSync(agentsPath)) {
- let content = fs.readFileSync(agentsPath, 'utf-8');
- const startIdx = content.indexOf(XDS_MARKER_START);
- const endIdx = content.indexOf(XDS_MARKER_END);
-
- if (startIdx !== -1 && endIdx !== -1) {
- // Remove XDS section and surrounding whitespace
- const before = content.slice(0, startIdx).trimEnd();
- const after = content.slice(endIdx + XDS_MARKER_END.length).trimStart();
- content = before + (after ? '\n\n' + after : '') + '\n';
-
- // If AGENTS.md is now essentially empty, remove it
- const stripped = content.replace(/^#.*\n+.*guidance.*\n*/m, '').trim();
- if (!stripped) {
- fs.unlinkSync(agentsPath);
- console.log(`✓ Removed empty ${AGENTS_MD}`);
- } else {
- fs.writeFileSync(agentsPath, content);
- console.log(`✓ Removed XDS section from ${AGENTS_MD}`);
- }
- }
- }
-}
-
-/**
- * Add .xds-docs to .gitignore if not present
- */
-function updateGitignore(targetDir) {
- const gitignorePath = path.join(targetDir, '.gitignore');
- const entry = `\n# XDS agent docs (generated)\n${XDS_DOCS_DIR}/\n`;
-
- if (fs.existsSync(gitignorePath)) {
- const content = fs.readFileSync(gitignorePath, 'utf-8');
- if (!content.includes(XDS_DOCS_DIR)) {
- fs.appendFileSync(gitignorePath, entry);
- console.log(`✓ Added ${XDS_DOCS_DIR}/ to .gitignore`);
- }
- } else {
- fs.writeFileSync(gitignorePath, entry.trim() + '\n');
- console.log(`✓ Created .gitignore with ${XDS_DOCS_DIR}/`);
- }
-}
-
-// Main
-const args = process.argv.slice(2);
-
-if (args.includes('--help') || args.includes('-h')) {
- console.log(`
-@xds/agent-tools agents-md
-
-Install XDS documentation for AI coding agents.
-
-Usage:
- npx @xds/agent-tools agents-md Install docs and inject into AGENTS.md
- npx @xds/agent-tools agents-md --remove Remove XDS docs and AGENTS.md section
-
-What it does:
- 1. Extracts essential sections from component READMEs (skips Files, Implementation Notes)
- 2. Copies static docs (principles.md, tokens.md)
- 3. Injects a compressed index into AGENTS.md
- 4. Adds .xds-docs/ to .gitignore
-
-The compressed index uses pipe-delimited format for 80% token reduction
-while maintaining full documentation availability for retrieval.
-`);
- process.exit(0);
-}
-
-const targetDir = process.cwd();
-const coreDir = findCoreDir(targetDir);
-const version = getXdsVersion(coreDir || targetDir);
-
-if (args.includes('--remove')) {
- console.log('\n🗑️ Removing XDS agent docs...\n');
- removeXdsDocs(targetDir);
- console.log('\n✅ XDS agent docs removed.\n');
-} else {
- console.log(`\n📚 Installing XDS agent docs (v${version})...\n`);
-
- const total = installDocs(targetDir);
-
- if (total === 0) {
- console.error('Error: No documentation sources found.');
- console.error('Make sure packages/core exists or static docs are bundled.');
- process.exit(1);
- }
-
- // Discover components dynamically
- const discoveredComponents = coreDir ? discoverComponents(coreDir) : null;
- if (discoveredComponents) {
- console.log(
- `✓ Discovered ${discoveredComponents.layout.length} layout + ${discoveredComponents.components.length} other components`,
- );
- }
-
- injectAgentsMd(targetDir, version, discoveredComponents);
- console.log(`✓ Injected compressed index into ${AGENTS_MD}`);
-
- updateGitignore(targetDir);
-
- console.log(`
-✅ XDS agent docs installed!
-
-Your AI coding agent will now:
- • See the XDS component index on every turn
- • Read detailed docs from .xds-docs/ when needed
- • Follow XDS patterns and avoid anti-patterns
-
-To update docs after upgrading @xds/agent-tools:
- npx @xds/agent-tools agents-md
-
-To remove:
- npx @xds/agent-tools agents-md --remove
-`);
-}
diff --git a/packages/agent-tools/bin/ai-skill.mjs b/packages/agent-tools/bin/ai-skill.mjs
deleted file mode 100755
index fb71f6d35b..0000000000
--- a/packages/agent-tools/bin/ai-skill.mjs
+++ /dev/null
@@ -1,58 +0,0 @@
-#!/usr/bin/env node
-/**
- * @file CLI for accessing XDS AI skill doc
- *
- * Usage:
- * npx @xds/agent-tools skill # prints principles to stdout
- * npx @xds/agent-tools skill --path # prints file path
- * npx @xds/agent-tools skill --all # prints all docs concatenated
- */
-
-import * as fs from 'node:fs';
-import * as path from 'node:path';
-import {fileURLToPath} from 'node:url';
-
-const __dirname = path.dirname(fileURLToPath(import.meta.url));
-const docsDir = path.resolve(__dirname, '..', 'docs');
-const principlesPath = path.resolve(docsDir, 'principles.md');
-
-const args = process.argv.slice(2);
-
-if (args.includes('--help') || args.includes('-h')) {
- console.log(`
-@xds/agent-tools skill
-
-Access XDS documentation for AI agent integration.
-
-Usage:
- npx @xds/agent-tools skill Print principles (quick reference)
- npx @xds/agent-tools skill --path Print docs directory path
- npx @xds/agent-tools skill --all Print all docs concatenated
- npx @xds/agent-tools skill --list List available doc files
-
-Recommended:
- Use 'npx @xds/agent-tools agents-md' to install AGENTS.md (better approach)
-`);
- process.exit(0);
-}
-
-if (args.includes('--path')) {
- console.log(docsDir);
-} else if (args.includes('--list')) {
- const files = fs.readdirSync(docsDir).filter(f => f.endsWith('.md'));
- console.log('Available docs:');
- files.forEach(f => console.log(` ${f}`));
-} else if (args.includes('--all')) {
- const files = fs
- .readdirSync(docsDir)
- .filter(f => f.endsWith('.md'))
- .sort();
- for (const file of files) {
- const content = fs.readFileSync(path.join(docsDir, file), 'utf-8');
- console.log(`\n${'='.repeat(60)}\n${file}\n${'='.repeat(60)}\n`);
- console.log(content);
- }
-} else {
- const content = fs.readFileSync(principlesPath, 'utf-8');
- console.log(content);
-}
diff --git a/packages/agent-tools/package.json b/packages/agent-tools/package.json
deleted file mode 100644
index 34b7269b72..0000000000
--- a/packages/agent-tools/package.json
+++ /dev/null
@@ -1,27 +0,0 @@
-{
- "name": "@xds/agent-tools",
- "version": "0.0.1",
- "description": "XDS documentation tools for AI coding agents",
- "type": "module",
- "bin": {
- "xds-agents-md": "./bin/agents-md.mjs",
- "xds-skill": "./bin/ai-skill.mjs"
- },
- "files": [
- "bin",
- "docs"
- ],
- "scripts": {
- "agents-md": "node bin/agents-md.mjs",
- "skill": "node bin/ai-skill.mjs"
- },
- "keywords": [
- "xds",
- "ai",
- "agents",
- "documentation",
- "claude",
- "cursor"
- ],
- "license": "MIT"
-}
diff --git a/packages/cli/bin/xds.mjs b/packages/cli/bin/xds.mjs
new file mode 100755
index 0000000000..ee7706f946
--- /dev/null
+++ b/packages/cli/bin/xds.mjs
@@ -0,0 +1,4 @@
+#!/usr/bin/env node
+import {program} from '../src/index.mjs';
+
+program.parse();
diff --git a/packages/agent-tools/docs/principles.md b/packages/cli/docs/principles.md
similarity index 100%
rename from packages/agent-tools/docs/principles.md
rename to packages/cli/docs/principles.md
diff --git a/packages/agent-tools/docs/tokens.md b/packages/cli/docs/tokens.md
similarity index 100%
rename from packages/agent-tools/docs/tokens.md
rename to packages/cli/docs/tokens.md
diff --git a/packages/cli/package.json b/packages/cli/package.json
new file mode 100644
index 0000000000..5c5d76830c
--- /dev/null
+++ b/packages/cli/package.json
@@ -0,0 +1,30 @@
+{
+ "name": "@xds/cli",
+ "version": "0.0.1",
+ "description": "XDS design system CLI — init, swizzle, theme, templates, and agent docs",
+ "type": "module",
+ "bin": {
+ "xds": "./bin/xds.mjs"
+ },
+ "files": [
+ "bin",
+ "src",
+ "templates",
+ "docs"
+ ],
+ "scripts": {
+ "xds": "node bin/xds.mjs"
+ },
+ "dependencies": {
+ "@clack/prompts": "^0.9.1",
+ "commander": "^12.1.0"
+ },
+ "keywords": [
+ "xds",
+ "cli",
+ "design-system",
+ "init",
+ "swizzle"
+ ],
+ "license": "MIT"
+}
diff --git a/packages/cli/src/commands/agent-docs.mjs b/packages/cli/src/commands/agent-docs.mjs
new file mode 100644
index 0000000000..36a6f545bf
--- /dev/null
+++ b/packages/cli/src/commands/agent-docs.mjs
@@ -0,0 +1,163 @@
+/**
+ * @file agent-docs command — Install/update AGENTS.md
+ *
+ * Injects a compressed XDS component index into AGENTS.md.
+ * Component docs are served via `npx xds component <name>` instead of
+ * being copied into the project.
+ */
+
+import * as fs from 'node:fs';
+import * as path from 'node:path';
+import {findCoreDir, CLI_ROOT} from '../utils/paths.mjs';
+
+const AGENTS_MD = 'AGENTS.md';
+
+const XDS_MARKER_START = '<!-- XDS:START -->';
+const XDS_MARKER_END = '<!-- XDS:END -->';
+
+/**
+ * Compressed index for AGENTS.md.
+ * Directs agents to use CLI commands for retrieval.
+ */
+function generateCompressedIndex(version) {
+ return `${XDS_MARKER_START}
+[XDS v${version}]|IMPORTANT: Prefer retrieval-led reasoning. Run CLI to read docs before generating code.
+|npx xds component <Name> --compact|--source Docs (props, usage) or source code
+|npx xds component --list All components by category
+|npx xds docs principles Design rules, anti-patterns, StyleX patterns
+|npx xds docs tokens Token reference (spacing, color, radius, type)
+|npx xds swizzle <Name> Copy component source for customization
+|npx xds theme <preset> Apply theme (default, neutral)
+|npx xds template <name> [path] Scaffold page (blank, table, login)
+${XDS_MARKER_END}`;
+}
+
+/**
+ * Get XDS version from core package.
+ */
+function getXdsVersion(coreDir) {
+ if (coreDir) {
+ const pkgPath = path.join(coreDir, 'package.json');
+ if (fs.existsSync(pkgPath)) {
+ const pkg = JSON.parse(fs.readFileSync(pkgPath, 'utf-8'));
+ return pkg.version;
+ }
+ }
+ const cliPkgPath = path.join(CLI_ROOT, 'package.json');
+ const pkg = JSON.parse(fs.readFileSync(cliPkgPath, 'utf-8'));
+ return pkg.version;
+}
+
+/**
+ * Inject or update XDS section in AGENTS.md.
+ */
+function injectAgentsMd(targetDir, version) {
+ const agentsPath = path.join(targetDir, AGENTS_MD);
+ const compressedIndex = generateCompressedIndex(version);
+
+ let content = '';
+
+ if (fs.existsSync(agentsPath)) {
+ content = fs.readFileSync(agentsPath, 'utf-8');
+
+ const startIdx = content.indexOf(XDS_MARKER_START);
+ const endIdx = content.indexOf(XDS_MARKER_END);
+
+ if (startIdx !== -1 && endIdx !== -1) {
+ content =
+ content.slice(0, startIdx) +
+ compressedIndex +
+ content.slice(endIdx + XDS_MARKER_END.length);
+ } else {
+ content = content.trimEnd() + '\n\n' + compressedIndex + '\n';
+ }
+ } else {
+ content = `# AGENTS.md
+
+Project-specific guidance for AI coding agents.
+
+${compressedIndex}
+`;
+ }
+
+ fs.writeFileSync(agentsPath, content);
+}
+
+/**
+ * Remove XDS section from AGENTS.md.
+ */
+function removeAgentDocs(targetDir) {
+ const agentsPath = path.join(targetDir, AGENTS_MD);
+
+ if (fs.existsSync(agentsPath)) {
+ let content = fs.readFileSync(agentsPath, 'utf-8');
+ const startIdx = content.indexOf(XDS_MARKER_START);
+ const endIdx = content.indexOf(XDS_MARKER_END);
+
+ if (startIdx !== -1 && endIdx !== -1) {
+ const before = content.slice(0, startIdx).trimEnd();
+ const after = content.slice(endIdx + XDS_MARKER_END.length).trimStart();
+ content = before + (after ? '\n\n' + after : '') + '\n';
+
+ const stripped = content.replace(/^#.*\n+.*guidance.*\n*/m, '').trim();
+ if (!stripped) {
+ fs.unlinkSync(agentsPath);
+ console.log(`✓ Removed empty ${AGENTS_MD}`);
+ } else {
+ fs.writeFileSync(agentsPath, content);
+ console.log(`✓ Removed XDS section from ${AGENTS_MD}`);
+ }
+ }
+ }
+}
+
+/**
+ * Programmatic entry point for installing agent docs.
+ * Used by the init wizard.
+ */
+export function installAgentDocs(targetDir) {
+ const coreDir = findCoreDir(targetDir);
+ const version = getXdsVersion(coreDir);
+ injectAgentsMd(targetDir, version);
+}
+
+export function registerAgentDocs(program) {
+ program
+ .command('agent-docs')
+ .description('Install/update XDS component index in AGENTS.md')
+ .option('--remove', 'Remove XDS section from AGENTS.md')
+ .action(options => {
+ const targetDir = process.cwd();
+ const coreDir = findCoreDir(targetDir);
+ const version = getXdsVersion(coreDir);
+
+ if (options.remove) {
+ console.log('\n🗑️ Removing XDS agent docs...\n');
+ removeAgentDocs(targetDir);
+ console.log('\n✅ XDS agent docs removed.\n');
+ return;
+ }
+
+ console.log(`\n📚 Installing XDS agent docs (v${version})...\n`);
+
+ injectAgentsMd(targetDir, version);
+ console.log(`✓ Injected compressed index into ${AGENTS_MD}`);
+
+ console.log(`
+✅ XDS agent docs installed!
+
+Your AI coding agent will now:
+ • See the XDS component index in AGENTS.md
+ • Run \`npx xds component <name>\` to read detailed docs
+ • Run \`npx xds docs principles\` for design principles
+ • Run \`npx xds docs tokens\` for design token reference
+ • Follow XDS patterns and avoid anti-patterns
+
+To update:
+ npx xds agent-docs
+
+To remove:
+ npx xds agent-docs --remove
+`);
+ });
+}
diff --git a/packages/cli/src/commands/component.mjs b/packages/cli/src/commands/component.mjs
new file mode 100644
index 0000000000..08004695e8
--- /dev/null
+++ b/packages/cli/src/commands/component.mjs
@@ -0,0 +1,431 @@
+/**
+ * @file component command — List components and print component docs
+ *
+ * `xds component --list` prints all components grouped by category.
+ * `xds component <name>` prints the full component README.
+ * `xds component <name> --compact` prints a token-optimized version for LLMs.
+ */
+
+import * as fs from 'node:fs';
+import * as path from 'node:path';
+import {findCoreDir} from '../utils/paths.mjs';
+
+/**
+ * Map top-level src/ directories to display categories.
+ * New directories without a mapping will appear under "Other".
+ * Adding a new component file to an existing directory requires NO changes here.
+ */
+const DIR_TO_CATEGORY = {
+ AspectRatio: 'Layout',
+ Center: 'Layout',
+ Grid: 'Layout',
+ Layout: 'Layout',
+ Avatar: 'Display',
+ Badge: 'Display',
+ Divider: 'Display',
+ Icon: 'Display',
+ Skeleton: 'Display',
+ Text: 'Display',
+ CheckboxInput: 'Form',
+ DateInput: 'Form',
+ Field: 'Form',
+ Selector: 'Form',
+ Switch: 'Form',
+ TextArea: 'Form',
+ TextInput: 'Form',
+ TimeInput: 'Form',
+ Button: 'Action',
+ Calendar: 'Overlay',
+ Layer: 'Overlay',
+};
+
+const CATEGORY_ORDER = ['Layout', 'Display', 'Form', 'Action', 'Overlay'];
+const SKIP_DIRS = new Set(['theme', 'hooks', 'utils', '__tests__', 'node_modules']);
+
+/**
+ * Auto-discover components by scanning for XDS*.tsx files in core/src/.
+ * Groups them by category using the DIR_TO_CATEGORY mapping.
+ */
+function discoverComponents(coreDir) {
+ const srcDir = path.join(coreDir, 'src');
+ const categories = {};
+
+ function collectXDSFiles(dirPath) {
+ const results = [];
+ if (!fs.existsSync(dirPath)) return results;
+ const entries = fs.readdirSync(dirPath, {withFileTypes: true});
+ for (const entry of entries) {
+ if (entry.isDirectory()) {
+ results.push(...collectXDSFiles(path.join(dirPath, entry.name)));
+ } else if (
+ /^XDS[A-Z]\w+\.tsx$/.test(entry.name) &&
+ !entry.name.includes('.test.')
+ ) {
+ results.push(entry.name);
+ }
+ }
+ return results;
+ }
+
+ const topEntries = fs.readdirSync(srcDir, {withFileTypes: true});
+ for (const entry of topEntries) {
+ if (!entry.isDirectory() || SKIP_DIRS.has(entry.name)) continue;
+
+ const category = DIR_TO_CATEGORY[entry.name] || 'Other';
+ const xdsFiles = collectXDSFiles(path.join(srcDir, entry.name));
+
+ for (const fileName of xdsFiles) {
+ const componentName = fileName.replace(/^XDS/, '').replace(/\.tsx$/, '');
+ if (!categories[category]) categories[category] = [];
+ if (!categories[category].includes(componentName)) {
+ categories[category].push(componentName);
+ }
+ }
+ }
+
+ // Sort components within each category
+ for (const cat of Object.keys(categories)) {
+ categories[cat].sort();
+ }
+
+ // Return in defined order
+ const ordered = {};
+ for (const cat of CATEGORY_ORDER) {
+ if (categories[cat]) ordered[cat] = categories[cat];
+ }
+ // Append any categories not in CATEGORY_ORDER (e.g. "Other")
+ for (const cat of Object.keys(categories)) {
+ if (!ordered[cat]) ordered[cat] = categories[cat];
+ }
+
+ return ordered;
+}
+
+/**
+ * Minimal cleanup for full docs (default mode).
+ * Strips SYNC comments, rewrites title, collapses blank lines.
+ */
+function cleanReadme(content, componentName) {
+ const displayName = componentName.startsWith('XDS')
+ ? componentName
+ : componentName.charAt(0).toUpperCase() + componentName.slice(1);
+
+ const lines = content.split('\n');
+ const output = [];
+
+ for (const line of lines) {
+ if (line.includes('<!-- SYNC:') || line.includes('SYNC:')) continue;
+
+ if (line.startsWith('# /')) {
+ output.push(`# ${displayName}`);
+ continue;
+ }
+
+ output.push(line);
+ }
+
+ // Collapse consecutive blank lines
+ const cleaned = [];
+ let prevEmpty = false;
+ for (const line of output) {
+ const isEmpty = line.trim() === '';
+ if (isEmpty && prevEmpty) continue;
+ cleaned.push(line);
+ prevEmpty = isEmpty;
+ }
+
+ // Trim trailing blank lines
+ while (cleaned.length > 0 && cleaned[cleaned.length - 1].trim() === '') {
+ cleaned.pop();
+ }
+
+ return cleaned.join('\n') + '\n';
+}
+
+// Sections to skip in compact mode
+const COMPACT_SKIP_SECTIONS = [
+ 'Files',
+ 'RTL Support',
+ 'Related',
+ 'Dividers',
+ 'Components',
+ 'Overview',
+];
+const MAX_EXAMPLES = 3;
+
+/**
+ * Extract compact docs for LLM consumption.
+ * Keeps: title, description, Features, Usage (limited examples), Props, Implementation Notes.
+ * Drops: Files, RTL Support, Related, ASCII art, overflow code blocks.
+ */
+function extractCompact(content, componentName) {
+ const lines = content.split('\n');
+ const output = [];
+ let inSkipSection = false;
+ let inCodeBlock = false;
+ let codeBlockCount = 0;
+ let skipCurrentBlock = false;
+ let currentSection = null;
+
+ const displayName = componentName.startsWith('XDS')
+ ? componentName
+ : componentName.charAt(0).toUpperCase() + componentName.slice(1);
+
+ for (let i = 0; i < lines.length; i++) {
+ const line = lines[i];
+
+ if (line.startsWith('```')) {
+ if (!inCodeBlock) {
+ inCodeBlock = true;
+ const nextLine = lines[i + 1] || '';
+ const isAsciiBlock =
+ /^[┌┐└┘├┤┬┴┼─│\s]+$/.test(nextLine) ||
+ /^\s*[│├└┌]/.test(nextLine);
+ if (isAsciiBlock) {
+ skipCurrentBlock = true;
+ continue;
+ }
+ if (codeBlockCount >= MAX_EXAMPLES) {
+ skipCurrentBlock = true;
+ continue;
+ }
+ codeBlockCount++;
+ skipCurrentBlock = false;
+ } else {
+ inCodeBlock = false;
+ if (skipCurrentBlock) {
+ skipCurrentBlock = false;
+ continue;
+ }
+ }
+ }
+
+ if (inCodeBlock && skipCurrentBlock) continue;
+
+ const sectionMatch = line.match(/^##\s+(.+)$/);
+ if (sectionMatch) {
+ const sectionName = sectionMatch[1].trim();
+ codeBlockCount = 0;
+
+ if (COMPACT_SKIP_SECTIONS.some(s => sectionName.includes(s))) {
+ inSkipSection = true;
+ currentSection = sectionName;
+ continue;
+ }
+ inSkipSection = false;
+ currentSection = sectionName;
+ }
+
+ const subsectionMatch = line.match(/^###\s+(.+)$/);
+ if (
+ subsectionMatch &&
+ currentSection === 'Usage' &&
+ codeBlockCount >= MAX_EXAMPLES
+ ) {
+ continue;
+ }
+
+ if (inSkipSection) continue;
+ if (line.includes('<!-- SYNC:') || line.includes('SYNC:')) continue;
+ if (
+ /^[┌┐└┘├┤┬┴┼─│\s]+$/.test(line) ||
+ /^\s*[│├└┌]\s*/.test(line)
+ ) {
+ continue;
+ }
+
+ if (line.startsWith('# /')) {
+ output.push(`# ${displayName}`);
+ continue;
+ }
+
+ output.push(line);
+ }
+
+ while (output.length > 0 && output[output.length - 1].trim() === '') {
+ output.pop();
+ }
+
+ const cleaned = [];
+ let prevEmpty = false;
+ for (const line of output) {
+ const isEmpty = line.trim() === '';
+ if (isEmpty && prevEmpty) continue;
+ cleaned.push(line);
+ prevEmpty = isEmpty;
+ }
+
+ return cleaned.join('\n') + '\n';
+}
+
+/**
+ * Find the README for a component, checking both top-level
+ * and nested directories. Falls back to finding the directory
+ * containing XDS{name}.tsx and returning its nearest README.
+ */
+function findComponentReadme(coreDir, name) {
+ const srcDir = path.join(coreDir, 'src');
+
+ // Direct match: src/{name}/README.md
+ const direct = path.join(srcDir, name, 'README.md');
+ if (fs.existsSync(direct)) return direct;
+
+ // Nested match: src/*/{name}/README.md
+ const entries = fs.readdirSync(srcDir, {withFileTypes: true});
+ for (const entry of entries) {
+ if (!entry.isDirectory()) continue;
+ const nested = path.join(srcDir, entry.name, name, 'README.md');
+ if (fs.existsSync(nested)) return nested;
+ }
+
+ // Fallback: find the directory containing XDS{name}.tsx,
+ // then return the README.md in that directory or nearest parent
+ const sourcePath = findComponentSource(coreDir, name);
+ if (sourcePath) {
+ let dir = path.dirname(sourcePath);
+ while (dir.startsWith(srcDir)) {
+ const readme = path.join(dir, 'README.md');
+ if (fs.existsSync(readme)) return readme;
+ dir = path.dirname(dir);
+ }
+ }
+
+ return null;
+}
+
+/**
+ * Find the main source file for a component (XDS*.tsx, excluding tests).
+ * For "Button" finds src/Button/XDSButton.tsx
+ * For "Layout" finds src/Layout/XDSLayout/XDSLayout.tsx
+ * For "Card" finds src/Layout/Container/XDSCard.tsx (deep search fallback)
+ */
+function findComponentSource(coreDir, name) {
+ const srcDir = path.join(coreDir, 'src');
+ const xdsName = `XDS${name}.tsx`;
+
+ function searchDir(dirPath) {
+ if (!fs.existsSync(dirPath)) return null;
+ const entries = fs.readdirSync(dirPath, {withFileTypes: true});
+
+ // Check for exact match first
+ const exact = path.join(dirPath, xdsName);
+ if (fs.existsSync(exact)) return exact;
+
+ // Recurse into subdirectories
+ for (const entry of entries) {
+ if (entry.isDirectory()) {
+ const found = searchDir(path.join(dirPath, entry.name));
+ if (found) return found;
+ }
+ }
+ return null;
+ }
+
+ // Search in the component's directory
+ const directDir = path.join(srcDir, name);
+ if (fs.existsSync(directDir)) {
+ const found = searchDir(directDir);
+ if (found) return found;
+ }
+
+ // Search nested (component might be under a parent dir)
+ const entries = fs.readdirSync(srcDir, {withFileTypes: true});
+ for (const entry of entries) {
+ if (!entry.isDirectory()) continue;
+ const nestedDir = path.join(srcDir, entry.name, name);
+ if (fs.existsSync(nestedDir)) {
+ const found = searchDir(nestedDir);
+ if (found) return found;
+ }
+ }
+
+ // Fallback: search entire src tree for the file
+ return searchDir(srcDir);
+}
+
+export function registerComponent(program) {
+ program
+ .command('component [name]')
+ .description('List components or print component docs')
+ .option('--list', 'List all components grouped by category')
+ .option('--category <category>', 'List components in a specific category')
+ .option('--compact', 'Token-optimized output for LLMs')
+ .option('--source', 'Print component source code')
+ .action((name, options) => {
+ const coreDir = findCoreDir(process.cwd());
+
+ if (!coreDir) {
+ console.error(
+ 'Error: Could not find @xds/core package.\n' +
+ 'Make sure you are inside the XDS monorepo or have @xds/core installed.',
+ );
+ process.exit(1);
+ }
+
+ if (options.category || options.list || !name) {
+ const components = discoverComponents(coreDir);
+
+ if (options.category) {
+ const cat = options.category;
+ const match = Object.entries(components).find(
+ ([key]) => key.toLowerCase() === cat.toLowerCase(),
+ );
+ if (!match) {
+ console.error(`Error: Unknown category "${cat}".`);
+ console.error(
+ `Available categories: ${Object.keys(components).join(', ')}`,
+ );
+ process.exit(1);
+ }
+ console.log(`\n${match[0]}:`);
+ for (const comp of match[1]) {
+ console.log(` ${comp}`);
+ }
+ console.log('');
+ return;
+ }
+
+ console.log('');
+ for (const [category, comps] of Object.entries(components)) {
+ console.log(`${category}:`);
+ for (const comp of comps) {
+ console.log(` ${comp}`);
+ }
+ console.log('');
+ }
+ console.log('Usage: npx xds component <name>');
+ console.log('');
+ return;
+ }
+
+ // Normalize: strip XDS prefix for directory lookup
+ const dirName = name.replace(/^XDS/, '');
+
+ if (options.source) {
+ const sourcePath = findComponentSource(coreDir, dirName);
+ if (!sourcePath) {
+ console.error(`Error: Source for "${name}" not found.`);
+ process.exit(1);
+ }
+ const source = fs.readFileSync(sourcePath, 'utf-8');
+ console.log(source);
+ return;
+ }
+
+ const readmePath = findComponentReadme(coreDir, dirName);
+
+ if (!readmePath) {
+ console.error(`Error: Component "${name}" not found.`);
+ console.error('Run `npx xds component --list` to see available components.');
+ process.exit(1);
+ }
+
+ const content = fs.readFileSync(readmePath, 'utf-8');
+
+ if (options.compact) {
+ console.log(extractCompact(content, dirName));
+ } else {
+ console.log(cleanReadme(content, dirName));
+ }
+ });
+}
diff --git a/packages/cli/src/commands/docs.mjs b/packages/cli/src/commands/docs.mjs
new file mode 100644
index 0000000000..88211e5761
--- /dev/null
+++ b/packages/cli/src/commands/docs.mjs
@@ -0,0 +1,53 @@
+/**
+ * @file docs command — Print XDS reference docs
+ *
+ * `xds docs` lists available topics.
+ * `xds docs <topic>` prints the doc content.
+ */
+
+import * as fs from 'node:fs';
+import * as path from 'node:path';
+import {CLI_ROOT} from '../utils/paths.mjs';
+
+const DOCS_DIR = path.join(CLI_ROOT, 'docs');
+
+const TOPICS = {
+ principles: 'XDS design principles, rules, and anti-patterns',
+ tokens: 'Full design token reference (spacing, colors, radius, typography)',
+};
+
+export function registerDocs(program) {
+ program
+ .command('docs [topic]')
+ .description('Print XDS reference docs (principles, tokens)')
+ .action(topic => {
+ if (!topic) {
+ console.log('\nAvailable docs:\n');
+ for (const [name, desc] of Object.entries(TOPICS)) {
+ console.log(` ${name.padEnd(14)} ${desc}`);
+ }
+ console.log('\nUsage: npx xds docs <topic>\n');
+ return;
+ }
+
+ const normalized = topic.toLowerCase().replace(/\.md$/, '');
+
+ if (!TOPICS[normalized]) {
+ console.error(`Error: Unknown topic "${topic}".`);
+ console.error(
+ `Available topics: ${Object.keys(TOPICS).join(', ')}`,
+ );
+ process.exit(1);
+ }
+
+ const docPath = path.join(DOCS_DIR, `${normalized}.md`);
+
+ if (!fs.existsSync(docPath)) {
+ console.error(`Error: Doc file not found at ${docPath}`);
+ process.exit(1);
+ }
+
+ const content = fs.readFileSync(docPath, 'utf-8');
+ console.log(content);
+ });
+}
diff --git a/packages/cli/src/commands/init.mjs b/packages/cli/src/commands/init.mjs
new file mode 100644
index 0000000000..024e26158f
--- /dev/null
+++ b/packages/cli/src/commands/init.mjs
@@ -0,0 +1,164 @@
+/**
+ * @file init command — Interactive initialization wizard
+ *
+ * Orchestrates the full XDS setup flow using @clack/prompts:
+ * 1. Intro
+ * 2. Agent docs installation
+ * 3. Theme selection
+ * 4. Swizzle awareness
+ * 5. Template selection
+ * 6. Success outro
+ */
+
+import * as p from '@clack/prompts';
+import * as path from 'node:path';
+import * as fs from 'node:fs';
+import {findCoreDir, CLI_ROOT} from '../utils/paths.mjs';
+import {installAgentDocs} from './agent-docs.mjs';
+import {discoverThemes, writeThemeConfig} from './theme.mjs';
+import {listTemplates} from './template.mjs';
+
+function isCancel(value) {
+ if (p.isCancel(value)) {
+ p.cancel('Setup cancelled.');
+ process.exit(0);
+ }
+ return value;
+}
+
+export function registerInit(program) {
+ program
+ .command('init')
+ .description('Interactive XDS initialization wizard')
+ .action(async () => {
+ // Step 1: Intro
+ p.intro('Welcome to XDS');
+
+ p.note(
+ 'XDS is a design system for building internal tools\nwith 300+ React components.',
+ 'About',
+ );
+
+ // Step 2: Agent Docs
+ const shouldInstallAgentDocs = isCancel(
+ await p.confirm({
+ message: 'Install AGENTS.md for AI coding agent support?',
+ initialValue: true,
+ }),
+ );
+
+ if (shouldInstallAgentDocs) {
+ const s = p.spinner();
+ s.start('Installing agent docs');
+ try {
+ installAgentDocs(process.cwd());
+ s.stop('Agent docs installed');
+ } catch {
+ s.stop('Agent docs installation failed');
+ p.log.warning(
+ 'Could not install agent docs. Run `npx xds agent-docs` later to retry.',
+ );
+ }
+ }
+
+ // Step 3: Theme Selection
+ const coreDir = findCoreDir(process.cwd());
+
+ if (coreDir) {
+ const themes = discoverThemes(coreDir);
+
+ if (themes.length > 0) {
+ const themeOptions = [
+ ...themes.map(t => ({
+ value: t.exportName,
+ label:
+ t.name === 'default'
+ ? 'Default — Blue accent, system fonts'
+ : t.name === 'neutral'
+ ? 'Neutral — Grayscale, shadcn-inspired'
+ : t.name,
+ })),
+ {value: 'skip', label: 'Skip — Configure later'},
+ ];
+
+ const themeChoice = isCancel(
+ await p.select({
+ message: 'Choose a theme:',
+ options: themeOptions,
+ }),
+ );
+
+ if (themeChoice !== 'skip') {
+ writeThemeConfig(process.cwd(), themeChoice);
+ p.log.success(`Theme set to ${themeChoice}`);
+ p.note(
+ `import { XDSTheme, ${themeChoice} } from '@xds/core/theme';\n\n<XDSTheme theme={${themeChoice}}>\n {children}\n</XDSTheme>`,
+ 'Add to your root layout',
+ );
+ }
+ }
+ }
+
+ // Step 4: Swizzle Awareness
+ p.note(
+ 'You can customize any component with:\n npx xds swizzle XDSButton\n npx xds swizzle --list',
+ 'Component Customization',
+ );
+
+ // Step 5: Template Selection
+ const templates = listTemplates();
+
+ if (templates.length > 0) {
+ const templateOptions = [
+ {value: 'skip', label: 'Skip — No template'},
+ {value: 'blank', label: 'Blank Page — Minimal scaffold'},
+ {value: 'table', label: 'Table Page — Data table with actions'},
+ {value: 'login', label: 'Login Page — Auth form with inputs'},
+ ];
+
+ const templateChoice = isCancel(
+ await p.select({
+ message: 'Start with a page template?',
+ options: templateOptions,
+ }),
+ );
+
+ if (templateChoice !== 'skip') {
+ const targetPath = isCancel(
+ await p.text({
+ message: 'Where should the template be created?',
+ initialValue: `./src/pages/${templateChoice}`,
+ placeholder: `./src/pages/${templateChoice}`,
+ }),
+ );
+
+ const outputDir = path.resolve(process.cwd(), targetPath);
+ const templateDir = path.join(CLI_ROOT, 'templates', templateChoice);
+
+ fs.mkdirSync(outputDir, {recursive: true});
+
+ const files = fs.readdirSync(templateDir);
+ for (const file of files) {
+ const srcPath = path.join(templateDir, file);
+ if (fs.statSync(srcPath).isFile()) {
+ fs.copyFileSync(srcPath, path.join(outputDir, file));
+ }
+ }
+
+ p.log.success(
+ `Template created at ${path.relative(process.cwd(), outputDir)}/`,
+ );
+ }
+ }
+
+ // Step 6: Success
+ p.outro('XDS initialized!');
+
+ console.log('');
+ console.log(' Next steps:');
+ console.log(' 1. Wrap your app with <XDSTheme theme={defaultTheme}>');
+ console.log(" 2. Import components: import { XDSButton } from '@xds/core'");
+ console.log(' 3. npx xds --help for all commands');
+ console.log('');
+ });
+}
diff --git a/packages/cli/src/commands/swizzle.mjs b/packages/cli/src/commands/swizzle.mjs
new file mode 100644
index 0000000000..4359407114
--- /dev/null
+++ b/packages/cli/src/commands/swizzle.mjs
@@ -0,0 +1,108 @@
+/**
+ * @file swizzle command — Copy component source for customization
+ *
+ * Resolves component source from packages/core/src/{Component}/,
+ * copies non-test files to the output directory, and rewrites
+ * relative imports to use '@xds/core' package paths.
+ */
+
+import * as fs from 'node:fs';
+import * as path from 'node:path';
+import {findCoreDir, listComponents} from '../utils/paths.mjs';
+
+/**
+ * Rewrite relative imports that point outside the component directory
+ * to use @xds/core package paths.
+ *
+ * e.g. '../theme/tokens.stylex' → '@xds/core/theme'
+ * '../utils/mergeProps' → '@xds/core/utils'
+ */
+function rewriteImports(content) {
+ // Match import/export from statements with relative paths going up
+ return content.replace(
+ /(from\s+['"])(\.\.\/.+?)(['"])/g,
+ (match, prefix, importPath, suffix) => {
+ // Extract the top-level directory from the relative path
+ // e.g. '../theme/tokens.stylex' → 'theme'
+ // e.g. '../utils/mergeProps' → 'utils'
+ const parts = importPath.replace(/^\.\.\//, '').split('/');
+ const topDir = parts[0];
+
+ // Map to @xds/core subpath
+ return `${prefix}@xds/core/${topDir}${suffix}`;
+ },
+ );
+}
+
+export function registerSwizzle(program) {
+ program
+ .command('swizzle [component]')
+ .description('Copy component source for customization')
+ .option('--output <dir>', 'Output directory', './components/xds')
+ .option('--list', 'List available components')
+ .action((component, options) => {
+ const coreDir = findCoreDir(process.cwd());
+
+ if (!coreDir) {
+ console.error(
+ 'Error: Could not find @xds/core package.\n' +
+ 'Make sure you are inside the XDS monorepo or have @xds/core installed.',
+ );
+ process.exit(1);
+ }
+
+ const components = listComponents(coreDir);
+
+ if (options.list || !component) {
+ console.log('\nAvailable components:\n');
+ for (const name of components) {
+ console.log(` ${name}`);
+ }
+ console.log(`\nUsage: xds swizzle <component>\n`);
+ console.log('Example: xds swizzle Button');
+ console.log(' xds swizzle XDSButton (XDS prefix also works)\n');
+ return;
+ }
+
+ // Normalize component name — strip XDS prefix for directory lookup
+ const dirName = component.replace(/^XDS/, '');
+ const componentDir = path.join(coreDir, 'src', dirName);
+
+ if (!fs.existsSync(componentDir)) {
+ console.error(`Error: Component "${component}" not found.`);
+ console.error(`Available: ${components.join(', ')}`);
+ process.exit(1);
+ }
+
+ const outputDir = path.resolve(process.cwd(), options.output, dirName);
+ fs.mkdirSync(outputDir, {recursive: true});
+
+ // Copy all non-test, non-README files
+ const files = fs.readdirSync(componentDir);
+ let copied = 0;
+
+ for (const file of files) {
+ // Skip test files and README
+ if (file.includes('.test.') || file === 'README.md') continue;
+
+ const srcPath = path.join(componentDir, file);
+ const stat = fs.statSync(srcPath);
+ if (!stat.isFile()) continue;
+
+ let content = fs.readFileSync(srcPath, 'utf-8');
+
+ // Rewrite imports for .ts/.tsx files
+ if (file.endsWith('.ts') || file.endsWith('.tsx')) {
+ content = rewriteImports(content);
+ }
+
+ fs.writeFileSync(path.join(outputDir, file), content);
+ copied++;
+ }
+
+ const relOutput = path.relative(process.cwd(), outputDir);
+ console.log(`\n✓ Copied ${copied} files to ${relOutput}/\n`);
+ console.log('Relative imports have been rewritten to use @xds/core.');
+ console.log('You can now customize the component source freely.\n');
+ });
+}
diff --git a/packages/cli/src/commands/template.mjs b/packages/cli/src/commands/template.mjs
new file mode 100644
index 0000000000..b179c86297
--- /dev/null
+++ b/packages/cli/src/commands/template.mjs
@@ -0,0 +1,79 @@
+/**
+ * @file template command — Inject page templates
+ *
+ * Copies template files from packages/cli/templates/{name}/ to a target path.
+ */
+
+import * as fs from 'node:fs';
+import * as path from 'node:path';
+import {CLI_ROOT} from '../utils/paths.mjs';
+
+/**
+ * List available templates by scanning the templates directory.
+ */
+export function listTemplates() {
+ const templatesDir = path.join(CLI_ROOT, 'templates');
+ if (!fs.existsSync(templatesDir)) return [];
+
+ return fs
+ .readdirSync(templatesDir, {withFileTypes: true})
+ .filter(e => e.isDirectory())
+ .map(e => e.name)
+ .sort();
+}
+
+const TEMPLATE_DESCRIPTIONS = {
+ blank: 'Minimal scaffold',
+ table: 'Data table with actions',
+ login: 'Auth form with inputs',
+};
+
+export function registerTemplate(program) {
+ program
+ .command('template [name] [path]')
+ .description('Inject a page template')
+ .option('--list', 'List available templates')
+ .action((name, targetPath, options) => {
+ const templates = listTemplates();
+
+ if (options.list || !name) {
+ console.log('\nAvailable templates:\n');
+ for (const t of templates) {
+ const desc = TEMPLATE_DESCRIPTIONS[t] || '';
+ console.log(` ${t} — ${desc}`);
+ }
+ console.log(`\nUsage: xds template <name> [target-path]\n`);
+ console.log('Example: xds template blank ./src/pages/home\n');
+ return;
+ }
+
+ if (!templates.includes(name)) {
+ console.error(`Error: Unknown template "${name}".`);
+ console.error(`Available: ${templates.join(', ')}`);
+ process.exit(1);
+ }
+
+ const outputDir = path.resolve(
+ process.cwd(),
+ targetPath || `./src/pages/${name}`,
+ );
+ const templateDir = path.join(CLI_ROOT, 'templates', name);
+
+ fs.mkdirSync(outputDir, {recursive: true});
+
+ const files = fs.readdirSync(templateDir);
+ let copied = 0;
+
+ for (const file of files) {
+ const srcPath = path.join(templateDir, file);
+ const stat = fs.statSync(srcPath);
+ if (!stat.isFile()) continue;
+
+ fs.copyFileSync(srcPath, path.join(outputDir, file));
+ copied++;
+ }
+
+ const relOutput = path.relative(process.cwd(), outputDir);
+ console.log(`\n✓ Copied ${copied} template files to ${relOutput}/\n`);
+ });
+}
diff --git a/packages/cli/src/commands/theme.mjs b/packages/cli/src/commands/theme.mjs
new file mode 100644
index 0000000000..01b2479002
--- /dev/null
+++ b/packages/cli/src/commands/theme.mjs
@@ -0,0 +1,98 @@
+/**
+ * @file theme command — Discover and apply XDS themes
+ *
+ * Scans packages/core/src/theme/*Theme.stylex.ts for available themes.
+ * Writes xds.config.mjs with the selected theme.
+ */
+
+import * as fs from 'node:fs';
+import * as path from 'node:path';
+import {findCoreDir} from '../utils/paths.mjs';
+
+/**
+ * Discover available themes by scanning theme directory.
+ * Returns array of {name, exportName} objects.
+ */
+export function discoverThemes(coreDir) {
+ const themeDir = path.join(coreDir, 'src', 'theme');
+ if (!fs.existsSync(themeDir)) return [];
+
+ const files = fs.readdirSync(themeDir);
+ return files
+ .filter(f => f.endsWith('Theme.stylex.ts'))
+ .map(f => {
+ const exportName = f.replace('.stylex.ts', '');
+ const name = exportName.replace('Theme', '');
+ return {name, exportName};
+ })
+ .sort((a, b) => a.name.localeCompare(b.name));
+}
+
+/**
+ * Write xds.config.mjs with the selected theme.
+ */
+export function writeThemeConfig(targetDir, themeExportName) {
+ const configPath = path.join(targetDir, 'xds.config.mjs');
+ const content = `/**
+ * XDS Configuration
+ * Generated by \`xds theme\`
+ */
+export default {
+ theme: '${themeExportName}',
+};
+`;
+ fs.writeFileSync(configPath, content);
+ return configPath;
+}
+
+export function registerTheme(program) {
+ program
+ .command('theme [preset]')
+ .description('Apply a prebuilt XDS theme')
+ .option('--list', 'List available themes')
+ .action((preset, options) => {
+ const coreDir = findCoreDir(process.cwd());
+
+ if (!coreDir) {
+ console.error(
+ 'Error: Could not find @xds/core package.\n' +
+ 'Make sure you are inside the XDS monorepo or have @xds/core installed.',
+ );
+ process.exit(1);
+ }
+
+ const themes = discoverThemes(coreDir);
+
+ if (themes.length === 0) {
+ console.error('Error: No themes found in packages/core/src/theme/');
+ process.exit(1);
+ }
+
+ if (options.list || !preset) {
+ console.log('\nAvailable themes:\n');
+ for (const theme of themes) {
+ const label = theme.name === 'default' ? ' (default)' : '';
+ console.log(` ${theme.name}${label} — import { ${theme.exportName} } from '@xds/core/theme'`);
+ }
+ console.log('\nUsage: xds theme <name>\n');
+ return;
+ }
+
+ const theme = themes.find(t => t.name === preset);
+
+ if (!theme) {
+ console.error(`Error: Unknown theme "${preset}".`);
+ console.error(`Available: ${themes.map(t => t.name).join(', ')}`);
+ process.exit(1);
+ }
+
+ const configPath = writeThemeConfig(process.cwd(), theme.exportName);
+ console.log(`\n✓ Wrote ${path.relative(process.cwd(), configPath)}\n`);
+ console.log('Add the theme provider to your root layout:\n');
+ console.log(` import { XDSTheme, ${theme.exportName} } from '@xds/core/theme';`);
+ console.log('');
+ console.log(' <XDSTheme theme={' + theme.exportName + '}>');
+ console.log(' {children}');
+ console.log(' </XDSTheme>\n');
+ });
+}
diff --git a/packages/cli/src/index.mjs b/packages/cli/src/index.mjs
new file mode 100644
index 0000000000..a46417185f
--- /dev/null
+++ b/packages/cli/src/index.mjs
@@ -0,0 +1,55 @@
+/**
+ * @file XDS CLI — Commander program setup
+ *
+ * Registers all commands: init, swizzle, agent-docs, component, docs, template, theme.
+ */
+
+import {Command} from 'commander';
+import {registerInit} from './commands/init.mjs';
+import {registerSwizzle} from './commands/swizzle.mjs';
+import {registerAgentDocs} from './commands/agent-docs.mjs';
+import {registerComponent} from './commands/component.mjs';
+import {registerDocs} from './commands/docs.mjs';
+import {registerTemplate} from './commands/template.mjs';
+import {registerTheme} from './commands/theme.mjs';
+
+export const program = new Command();
+
+program
+ .name('xds')
+ .description('XDS design system CLI — components, themes, and tooling')
+ .version('0.0.1')
+ .addHelpCommand('help', 'Show all commands');
+
+registerInit(program);
+registerComponent(program);
+registerDocs(program);
+registerSwizzle(program);
+registerAgentDocs(program);
+registerTemplate(program);
+registerTheme(program);
+
+// Hidden command used by package.json postinstall scripts
+program
+ .command('postinstall', {hidden: true})
+ .action(() => {
+ console.log(`
+ ╭───────────────────────────────────────────────────╮
+ │ │
+ │ XDS design system installed! │
+ │ │
+ │ Get started: │
+ │ npx xds init Interactive setup │
+ │ npx xds --help See all commands │
+ │ │
+ │ Or run directly: │
+ │ npx xds agent-docs Install AI agent docs │
+ │ npx xds component Browse component docs │
+ │ npx xds docs Design system reference │
+ │ npx xds theme Apply a theme │
+ │ npx xds swizzle Customize a component │
+ │ npx xds template Add a page template │
+ │ │
+ ╰───────────────────────────────────────────────────╯
+`);
+ });
diff --git a/packages/cli/src/utils/paths.mjs b/packages/cli/src/utils/paths.mjs
new file mode 100644
index 0000000000..2c5d4ee7f6
--- /dev/null
+++ b/packages/cli/src/utils/paths.mjs
@@ -0,0 +1,88 @@
+/**
+ * @file Path resolution utilities for XDS CLI
+ *
+ * Finds packages/core, project root, and CLI package root.
+ */
+
+import * as fs from 'node:fs';
+import * as path from 'node:path';
+import {fileURLToPath} from 'node:url';
+
+const __dirname = path.dirname(fileURLToPath(import.meta.url));
+
+/** Root of the @xds/cli package */
+export const CLI_ROOT = path.resolve(__dirname, '..', '..');
+
+/**
+ * Find packages/core directory by walking up from startDir.
+ * Also checks node_modules/@xds/core for installed usage.
+ */
+export function findCoreDir(startDir = process.cwd()) {
+ let dir = startDir;
+
+ for (let i = 0; i < 5; i++) {
+ const candidate = path.join(dir, 'packages', 'core');
+ if (fs.existsSync(candidate)) {
+ return candidate;
+ }
+
+ const nodeModules = path.join(dir, 'node_modules', '@xds', 'core');
+ if (fs.existsSync(nodeModules)) {
+ return nodeModules;
+ }
+
+ const parent = path.dirname(dir);
+ if (parent === dir) break;
+ dir = parent;
+ }
+
+ return null;
+}
+
+/**
+ * Find the monorepo root by looking for the root package.json
+ * that has workspaces defined.
+ */
+export function findProjectRoot(startDir = process.cwd()) {
+ let dir = startDir;
+
+ for (let i = 0; i < 5; i++) {
+ const pkgPath = path.join(dir, 'package.json');
+ if (fs.existsSync(pkgPath)) {
+ try {
+ const pkg = JSON.parse(fs.readFileSync(pkgPath, 'utf-8'));
+ if (pkg.workspaces) {
+ return dir;
+ }
+ } catch {
+ // skip invalid JSON
+ }
+ }
+
+ const parent = path.dirname(dir);
+ if (parent === dir) break;
+ dir = parent;
+ }
+
+ return null;
+}
+
+/**
+ * List available component directories in packages/core/src.
+ * Returns directory names that contain XDS*.tsx files.
+ */
+export function listComponents(coreDir) {
+ const srcDir = path.join(coreDir, 'src');
+ if (!fs.existsSync(srcDir)) return [];
+
+ const entries = fs.readdirSync(srcDir, {withFileTypes: true});
+ return entries
+ .filter(e => {
+ if (!e.isDirectory()) return false;
+ // Skip non-component dirs
+ if (['hooks', 'theme', 'utils'].includes(e.name)) return false;
+ return true;
+ })
+ .map(e => e.name)
+ .sort();
+}
diff --git a/packages/cli/templates/blank/page.tsx b/packages/cli/templates/blank/page.tsx
new file mode 100644
index 0000000000..a389a700e0
--- /dev/null
+++ b/packages/cli/templates/blank/page.tsx
@@ -0,0 +1,21 @@
+'use client';
+
+import * as stylex from '@stylexjs/stylex';
+import {XDSLayout, XDSLayoutContent} from '@xds/core';
+import {XDSText} from '@xds/core';
+
+const styles = stylex.create({
+ content: {
+ padding: 'var(--spacing-6)',
+ },
+});
+
+export default function Page() {
+ return (
+ <XDSLayout>
+ <XDSLayoutContent xstyle={styles.content}>
+ <XDSText type="large">New Page</XDSText>
+ </XDSLayoutContent>
+ </XDSLayout>
+ );
+}
diff --git a/packages/cli/templates/login/page.tsx b/packages/cli/templates/login/page.tsx
new file mode 100644
index 0000000000..4f164c2979
--- /dev/null
+++ b/packages/cli/templates/login/page.tsx
@@ -0,0 +1,72 @@
+'use client';
+
+import {useState} from 'react';
+import * as stylex from '@stylexjs/stylex';
+import {XDSLayout, XDSLayoutContent} from '@xds/core';
+import {XDSText} from '@xds/core';
+import {XDSTextInput} from '@xds/core';
+import {XDSButton} from '@xds/core';
+import {XDSVStack} from '@xds/core';
+
+const styles = stylex.create({
+ container: {
+ display: 'flex',
+ alignItems: 'center',
+ justifyContent: 'center',
+ minHeight: '100vh',
+ },
+ card: {
+ width: '100%',
+ maxWidth: '400px',
+ padding: 'var(--spacing-7)',
+ backgroundColor: 'var(--color-surface)',
+ borderRadius: 'var(--radius-container)',
+ boxShadow: 'var(--elevation-menu)',
+ },
+});
+
+export default function LoginPage() {
+ const [email, setEmail] = useState('');
+ const [password, setPassword] = useState('');
+
+ const handleSubmit = (e: React.FormEvent) => {
+ e.preventDefault();
+ // Handle login
+ };
+
+ return (
+ <XDSLayout>
+ <XDSLayoutContent xstyle={styles.container}>
+ <form onSubmit={handleSubmit}>
+ <div {...stylex.props(styles.card)}>
+ <XDSVStack gap="space5">
+ <XDSText type="large" weight="semibold">
+ Sign in
+ </XDSText>
+
+ <XDSTextInput
+ label="Email"
+ type="email"
+ value={email}
+ onChange={e => setEmail(e.target.value)}
+ placeholder="[email protected]"
+ />
+
+ <XDSTextInput
+ label="Password"
+ type="password"
+ value={password}
+ onChange={e => setPassword(e.target.value)}
+ placeholder="Enter your password"
+ />
+
+ <XDSButton variant="primary" type="submit">
+ Sign in
+ </XDSButton>
+ </XDSVStack>
+ </div>
+ </form>
+ </XDSLayoutContent>
+ </XDSLayout>
+ );
+}
diff --git a/packages/cli/templates/table/page.tsx b/packages/cli/templates/table/page.tsx
new file mode 100644
index 0000000000..680b183ec2
--- /dev/null
+++ b/packages/cli/templates/table/page.tsx
@@ -0,0 +1,105 @@
+'use client';
+
+import {useState} from 'react';
+import * as stylex from '@stylexjs/stylex';
+import {XDSLayout, XDSLayoutHeader, XDSLayoutContent} from '@xds/core';
+import {XDSText} from '@xds/core';
+import {XDSButton} from '@xds/core';
+import {XDSHStack} from '@xds/core';
+
+const styles = stylex.create({
+ header: {
+ padding: 'var(--spacing-4)',
+ borderBottom: '1px solid var(--color-border)',
+ },
+ content: {
+ padding: 'var(--spacing-6)',
+ },
+ table: {
+ width: '100%',
+ borderCollapse: 'collapse',
+ },
+ th: {
+ textAlign: 'start',
+ padding: 'var(--spacing-3) var(--spacing-4)',
+ borderBottom: '1px solid var(--color-border)',
+ color: 'var(--color-text-secondary)',
+ fontSize: 'var(--text-sm)',
+ fontWeight: 'var(--font-weight-medium)',
+ },
+ td: {
+ padding: 'var(--spacing-3) var(--spacing-4)',
+ borderBottom: '1px solid var(--color-border)',
+ },
+ row: {
+ ':hover': {
+ backgroundColor: 'var(--color-wash)',
+ },
+ },
+});
+
+type Item = {
+ id: string;
+ name: string;
+ status: 'active' | 'inactive';
+ updatedAt: string;
+};
+
+const SAMPLE_DATA: Item[] = [
+ {id: '1', name: 'Item One', status: 'active', updatedAt: '2025-01-15'},
+ {id: '2', name: 'Item Two', status: 'inactive', updatedAt: '2025-01-14'},
+ {id: '3', name: 'Item Three', status: 'active', updatedAt: '2025-01-13'},
+];
+
+export default function TablePage() {
+ const [data] = useState<Item[]>(SAMPLE_DATA);
+
+ return (
+ <XDSLayout>
+ <XDSLayoutHeader xstyle={styles.header}>
+ <XDSHStack align="center" justify="between">
+ <XDSText type="large" weight="semibold">
+ Items
+ </XDSText>
+ <XDSButton variant="primary">Add Item</XDSButton>
+ </XDSHStack>
+ </XDSLayoutHeader>
+
+ <XDSLayoutContent xstyle={styles.content}>
+ <table {...stylex.props(styles.table)}>
+ <thead>
+ <tr>
+ <th {...stylex.props(styles.th)}>Name</th>
+ <th {...stylex.props(styles.th)}>Status</th>
+ <th {...stylex.props(styles.th)}>Updated</th>
+ <th {...stylex.props(styles.th)}>Actions</th>
+ </tr>
+ </thead>
+ <tbody>
+ {data.map(item => (
+ <tr key={item.id} {...stylex.props(styles.row)}>
+ <td {...stylex.props(styles.td)}>
+ <XDSText>{item.name}</XDSText>
+ </td>
+ <td {...stylex.props(styles.td)}>
+ <XDSText
+ color={item.status === 'active' ? 'primary' : 'secondary'}>
+ {item.status}
+ </XDSText>
+ </td>
+ <td {...stylex.props(styles.td)}>
+ <XDSText color="secondary">{item.updatedAt}</XDSText>
+ </td>
+ <td {...stylex.props(styles.td)}>
+ <XDSButton variant="secondary" size="sm">
+ Edit
+ </XDSButton>
+ </td>
+ </tr>
+ ))}
+ </tbody>
+ </table>
+ </XDSLayoutContent>
+ </XDSLayout>
+ );
+}
diff --git a/scripts/package-source.js b/scripts/package-source.js
index 636438f03b..3f8cbfe19b 100644
--- a/scripts/package-source.js
+++ b/scripts/package-source.js
@@ -15,7 +15,7 @@ const ROOT = path.resolve(__dirname, '..');
const CORE_DIR = path.join(ROOT, 'packages', 'core');
const SRC_DIR = path.join(CORE_DIR, 'src');
const DIST_DIR = path.join(ROOT, 'dist-source');
-const AGENT_TOOLS_DIR = path.join(ROOT, 'packages', 'agent-tools');
+const AGENT_TOOLS_DIR = path.join(ROOT, 'packages', 'cli');
const PKG = require(path.join(CORE_DIR, 'package.json'));
// Files/patterns to exclude from distribution
@@ -301,11 +301,11 @@ async function main() {
}
// Run agents-md script
- const agentsMdPath = path.join(__dirname, 'agent-tools', 'bin', 'agents-md.mjs');
+ const agentsMdPath = path.join(__dirname, 'cli', 'bin', 'xds.mjs');
if (fs.existsSync(agentsMdPath)) {
const { execSync } = await import('node:child_process');
try {
- execSync(\`node "\${agentsMdPath}"\`, {
+ execSync(\`node "\${agentsMdPath}" agent-docs\`, {
cwd: projectRoot,
stdio: 'inherit'
});
@@ -313,7 +313,7 @@ async function main() {
console.error('Failed to install AGENTS.md:', e.message);
}
} else {
- console.log('⚠️ Agent tools not found at:', agentsMdPath);
+ console.log('⚠️ CLI not found at:', agentsMdPath);
}
} else {
console.log('\\nSkipped AGENTS.md setup.');
@@ -329,10 +329,10 @@ main();
}
function copyAgentTools(dest) {
- const agentToolsDest = path.join(dest, 'agent-tools');
+ const agentToolsDest = path.join(dest, 'cli');
if (!fs.existsSync(AGENT_TOOLS_DIR)) {
- console.log(' Warning: agent-tools not found, skipping');
+ console.log(' Warning: cli package not found, skipping');
return;
}
@@ -345,7 +345,7 @@ function copyAgentTools(dest) {
fs.mkdirSync(binDest, { recursive: true });
for (const file of fs.readdirSync(binSrc)) {
fs.copyFileSync(path.join(binSrc, file), path.join(binDest, file));
- console.log(` Copied: agent-tools/bin/${file}`);
+ console.log(` Copied: cli/bin/${file}`);
}
}
@@ -356,7 +356,7 @@ function copyAgentTools(dest) {
fs.mkdirSync(docsDest, { recursive: true });
for (const file of fs.readdirSync(docsSrc)) {
fs.copyFileSync(path.join(docsSrc, file), path.join(docsDest, file));
- console.log(` Copied: agent-tools/docs/${file}`);
+ console.log(` Copied: cli/docs/${file}`);
}
}
}
@@ -396,8 +396,8 @@ function main() {
createSetupScript()
);
- // Copy agent-tools
- console.log('\nCopying agent-tools...');
+ // Copy CLI tools
+ console.log('\nCopying CLI tools...');
copyAgentTools(DIST_DIR);
// Create tarball
diff --git a/yarn.lock b/yarn.lock
index 0a55400a20..916cf49bae 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -564,6 +564,23 @@
human-id "^4.1.1"
prettier "^2.7.1"
+ version "0.4.1"
+ resolved "https://registry.yarnpkg.com/@clack/core/-/core-0.4.1.tgz#36c8aed3f4904060a39275817e804e7a8ffb7e1c"
+ integrity sha512-Pxhij4UXg8KSr7rPek6Zowm+5M22rbd2g1nfojHJkxp5YkFqiZ2+YLEM/XGVIzvGOcM0nqjIFxrpDwWRZYWYjA==
+ dependencies:
+ picocolors "^1.0.0"
+ sisteransi "^1.0.5"
+
+"@clack/prompts@^0.9.1":
+ version "0.9.1"
+ resolved "https://registry.yarnpkg.com/@clack/prompts/-/prompts-0.9.1.tgz#af732a96fdde33f98bef1a35c17e8e5cbee10e31"
+ integrity sha512-JIpyaboYZeWYlyP0H+OoPPxd6nqueG/CmN6ixBiNFsIDHREevjIf0n0Ohh5gr5C8pEDknzgvz+pIJ8dMhzWIeg==
+ dependencies:
+ "@clack/core" "0.4.1"
+ picocolors "^1.0.0"
+ sisteransi "^1.0.5"
+
"@csstools/color-helpers@^5.1.0":
version "5.1.0"
resolved "https://registry.yarnpkg.com/@csstools/color-helpers/-/color-helpers-5.1.0.tgz#106c54c808cabfd1ab4c602d8505ee584c2996ef"
@@ -602,6 +619,13 @@
resolved "https://registry.yarnpkg.com/@dual-bundle/import-meta-resolve/-/import-meta-resolve-4.2.1.tgz#cd0b25b3808cd9e684cd6cd549bbf8e1dcf05ee7"
integrity sha512-id+7YRUgoUX6CgV0DtuhirQWodeeA7Lf4i2x71JS/vtA5pRb/hIGWlw+G6MeXvsM+MXrz0VAydTGElX1rAfgPg==
+"@emnapi/runtime@^1.7.0":
+ version "1.8.1"
+ resolved "https://registry.yarnpkg.com/@emnapi/runtime/-/runtime-1.8.1.tgz#550fa7e3c0d49c5fb175a116e8cd70614f9a22a5"
+ integrity sha512-mehfKSMWjjNol8659Z8KxEMrdSJDDot5SXMq00dM8BN4o+CLNXQ0xH2V7EchNHV4RmbZLmmPdEaXZc5H2FXmDg==
+ dependencies:
+ tslib "^2.4.0"
+
"@esbuild/[email protected]":
version "0.21.5"
resolved "https://registry.yarnpkg.com/@esbuild/aix-ppc64/-/aix-ppc64-0.21.5.tgz#c7184a326533fcdf1b8ee0733e21c713b975575f"
@@ -1203,6 +1227,153 @@
resolved "https://registry.yarnpkg.com/@humanwhocodes/retry/-/retry-0.4.3.tgz#c2b9d2e374ee62c586d3adbea87199b1d7a7a6ba"
integrity sha512-bV0Tgo9K4hfPCek+aMAn81RppFKv2ySDQeMoSZuvTASywNTnVJCArCZE2FWqpvIatKu7VMRLWlR1EazvVhDyhQ==
+"@img/colour@^1.0.0":
+ version "1.0.0"
+ resolved "https://registry.yarnpkg.com/@img/colour/-/colour-1.0.0.tgz#d2fabb223455a793bf3bf9c70de3d28526aa8311"
+ integrity sha512-A5P/LfWGFSl6nsckYtjw9da+19jB8hkJ6ACTGcDfEJ0aE+l2n2El7dsVM7UVHZQ9s2lmYMWlrS21YLy2IR1LUw==
+
+ version "0.34.5"
+ resolved "https://registry.yarnpkg.com/@img/sharp-darwin-arm64/-/sharp-darwin-arm64-0.34.5.tgz#6e0732dcade126b6670af7aa17060b926835ea86"
+ integrity sha512-imtQ3WMJXbMY4fxb/Ndp6HBTNVtWCUI0WdobyheGf5+ad6xX8VIDO8u2xE4qc/fr08CKG/7dDseFtn6M6g/r3w==
+ optionalDependencies:
+ "@img/sharp-libvips-darwin-arm64" "1.2.4"
+
+ version "0.34.5"
+ resolved "https://registry.yarnpkg.com/@img/sharp-darwin-x64/-/sharp-darwin-x64-0.34.5.tgz#19bc1dd6eba6d5a96283498b9c9f401180ee9c7b"
+ integrity sha512-YNEFAF/4KQ/PeW0N+r+aVVsoIY0/qxxikF2SWdp+NRkmMB7y9LBZAVqQ4yhGCm/H3H270OSykqmQMKLBhBJDEw==
+ optionalDependencies:
+ "@img/sharp-libvips-darwin-x64" "1.2.4"
+
+ version "1.2.4"
+ resolved "https://registry.yarnpkg.com/@img/sharp-libvips-darwin-arm64/-/sharp-libvips-darwin-arm64-1.2.4.tgz#2894c0cb87d42276c3889942e8e2db517a492c43"
+ integrity sha512-zqjjo7RatFfFoP0MkQ51jfuFZBnVE2pRiaydKJ1G/rHZvnsrHAOcQALIi9sA5co5xenQdTugCvtb1cuf78Vf4g==
+
+ version "1.2.4"
+ resolved "https://registry.yarnpkg.com/@img/sharp-libvips-darwin-x64/-/sharp-libvips-darwin-x64-1.2.4.tgz#e63681f4539a94af9cd17246ed8881734386f8cc"
+ integrity sha512-1IOd5xfVhlGwX+zXv2N93k0yMONvUlANylbJw1eTah8K/Jtpi15KC+WSiaX/nBmbm2HxRM1gZ0nSdjSsrZbGKg==
+
+ version "1.2.4"
+ resolved "https://registry.yarnpkg.com/@img/sharp-libvips-linux-arm64/-/sharp-libvips-linux-arm64-1.2.4.tgz#b1b288b36864b3bce545ad91fa6dadcf1a4ad318"
+ integrity sha512-excjX8DfsIcJ10x1Kzr4RcWe1edC9PquDRRPx3YVCvQv+U5p7Yin2s32ftzikXojb1PIFc/9Mt28/y+iRklkrw==
+
+ version "1.2.4"
+ resolved "https://registry.yarnpkg.com/@img/sharp-libvips-linux-arm/-/sharp-libvips-linux-arm-1.2.4.tgz#b9260dd1ebe6f9e3bdbcbdcac9d2ac125f35852d"
+ integrity sha512-bFI7xcKFELdiNCVov8e44Ia4u2byA+l3XtsAj+Q8tfCwO6BQ8iDojYdvoPMqsKDkuoOo+X6HZA0s0q11ANMQ8A==
+
+ version "1.2.4"
+ resolved "https://registry.yarnpkg.com/@img/sharp-libvips-linux-ppc64/-/sharp-libvips-linux-ppc64-1.2.4.tgz#4b83ecf2a829057222b38848c7b022e7b4d07aa7"
+ integrity sha512-FMuvGijLDYG6lW+b/UvyilUWu5Ayu+3r2d1S8notiGCIyYU/76eig1UfMmkZ7vwgOrzKzlQbFSuQfgm7GYUPpA==
+
+ version "1.2.4"
+ resolved "https://registry.yarnpkg.com/@img/sharp-libvips-linux-riscv64/-/sharp-libvips-linux-riscv64-1.2.4.tgz#880b4678009e5a2080af192332b00b0aaf8a48de"
+ integrity sha512-oVDbcR4zUC0ce82teubSm+x6ETixtKZBh/qbREIOcI3cULzDyb18Sr/Wcyx7NRQeQzOiHTNbZFF1UwPS2scyGA==
+
+ version "1.2.4"
+ resolved "https://registry.yarnpkg.com/@img/sharp-libvips-linux-s390x/-/sharp-libvips-linux-s390x-1.2.4.tgz#74f343c8e10fad821b38f75ced30488939dc59ec"
+ integrity sha512-qmp9VrzgPgMoGZyPvrQHqk02uyjA0/QrTO26Tqk6l4ZV0MPWIW6LTkqOIov+J1yEu7MbFQaDpwdwJKhbJvuRxQ==
+
+ version "1.2.4"
+ resolved "https://registry.yarnpkg.com/@img/sharp-libvips-linux-x64/-/sharp-libvips-linux-x64-1.2.4.tgz#df4183e8bd8410f7d61b66859a35edeab0a531ce"
+ integrity sha512-tJxiiLsmHc9Ax1bz3oaOYBURTXGIRDODBqhveVHonrHJ9/+k89qbLl0bcJns+e4t4rvaNBxaEZsFtSfAdquPrw==
+
+ version "1.2.4"
+ resolved "https://registry.yarnpkg.com/@img/sharp-libvips-linuxmusl-arm64/-/sharp-libvips-linuxmusl-arm64-1.2.4.tgz#c8d6b48211df67137541007ee8d1b7b1f8ca8e06"
+ integrity sha512-FVQHuwx1IIuNow9QAbYUzJ+En8KcVm9Lk5+uGUQJHaZmMECZmOlix9HnH7n1TRkXMS0pGxIJokIVB9SuqZGGXw==
+
+ version "1.2.4"
+ resolved "https://registry.yarnpkg.com/@img/sharp-libvips-linuxmusl-x64/-/sharp-libvips-linuxmusl-x64-1.2.4.tgz#be11c75bee5b080cbee31a153a8779448f919f75"
+ integrity sha512-+LpyBk7L44ZIXwz/VYfglaX/okxezESc6UxDSoyo2Ks6Jxc4Y7sGjpgU9s4PMgqgjj1gZCylTieNamqA1MF7Dg==
+
+ version "0.34.5"
+ resolved "https://registry.yarnpkg.com/@img/sharp-linux-arm64/-/sharp-linux-arm64-0.34.5.tgz#7aa7764ef9c001f15e610546d42fce56911790cc"
+ integrity sha512-bKQzaJRY/bkPOXyKx5EVup7qkaojECG6NLYswgktOZjaXecSAeCWiZwwiFf3/Y+O1HrauiE3FVsGxFg8c24rZg==
+ optionalDependencies:
+ "@img/sharp-libvips-linux-arm64" "1.2.4"
+
+ version "0.34.5"
+ resolved "https://registry.yarnpkg.com/@img/sharp-linux-arm/-/sharp-linux-arm-0.34.5.tgz#5fb0c3695dd12522d39c3ff7a6bc816461780a0d"
+ integrity sha512-9dLqsvwtg1uuXBGZKsxem9595+ujv0sJ6Vi8wcTANSFpwV/GONat5eCkzQo/1O6zRIkh0m/8+5BjrRr7jDUSZw==
+ optionalDependencies:
+ "@img/sharp-libvips-linux-arm" "1.2.4"
+
+ version "0.34.5"
+ resolved "https://registry.yarnpkg.com/@img/sharp-linux-ppc64/-/sharp-linux-ppc64-0.34.5.tgz#9c213a81520a20caf66978f3d4c07456ff2e0813"
+ integrity sha512-7zznwNaqW6YtsfrGGDA6BRkISKAAE1Jo0QdpNYXNMHu2+0dTrPflTLNkpc8l7MUP5M16ZJcUvysVWWrMefZquA==
+ optionalDependencies:
+ "@img/sharp-libvips-linux-ppc64" "1.2.4"
+
+ version "0.34.5"
+ resolved "https://registry.yarnpkg.com/@img/sharp-linux-riscv64/-/sharp-linux-riscv64-0.34.5.tgz#cdd28182774eadbe04f62675a16aabbccb833f60"
+ integrity sha512-51gJuLPTKa7piYPaVs8GmByo7/U7/7TZOq+cnXJIHZKavIRHAP77e3N2HEl3dgiqdD/w0yUfiJnII77PuDDFdw==
+ optionalDependencies:
+ "@img/sharp-libvips-linux-riscv64" "1.2.4"
+
+ version "0.34.5"
+ resolved "https://registry.yarnpkg.com/@img/sharp-linux-s390x/-/sharp-linux-s390x-0.34.5.tgz#93eac601b9f329bb27917e0e19098c722d630df7"
+ integrity sha512-nQtCk0PdKfho3eC5MrbQoigJ2gd1CgddUMkabUj+rBevs8tZ2cULOx46E7oyX+04WGfABgIwmMC0VqieTiR4jg==
+ optionalDependencies:
+ "@img/sharp-libvips-linux-s390x" "1.2.4"
+
+ version "0.34.5"
+ resolved "https://registry.yarnpkg.com/@img/sharp-linux-x64/-/sharp-linux-x64-0.34.5.tgz#55abc7cd754ffca5002b6c2b719abdfc846819a8"
+ integrity sha512-MEzd8HPKxVxVenwAa+JRPwEC7QFjoPWuS5NZnBt6B3pu7EG2Ge0id1oLHZpPJdn3OQK+BQDiw9zStiHBTJQQQQ==
+ optionalDependencies:
+ "@img/sharp-libvips-linux-x64" "1.2.4"
+
+ version "0.34.5"
+ resolved "https://registry.yarnpkg.com/@img/sharp-linuxmusl-arm64/-/sharp-linuxmusl-arm64-0.34.5.tgz#d6515ee971bb62f73001a4829b9d865a11b77086"
+ integrity sha512-fprJR6GtRsMt6Kyfq44IsChVZeGN97gTD331weR1ex1c1rypDEABN6Tm2xa1wE6lYb5DdEnk03NZPqA7Id21yg==
+ optionalDependencies:
+ "@img/sharp-libvips-linuxmusl-arm64" "1.2.4"
+
+ version "0.34.5"
+ resolved "https://registry.yarnpkg.com/@img/sharp-linuxmusl-x64/-/sharp-linuxmusl-x64-0.34.5.tgz#d97978aec7c5212f999714f2f5b736457e12ee9f"
+ integrity sha512-Jg8wNT1MUzIvhBFxViqrEhWDGzqymo3sV7z7ZsaWbZNDLXRJZoRGrjulp60YYtV4wfY8VIKcWidjojlLcWrd8Q==
+ optionalDependencies:
+ "@img/sharp-libvips-linuxmusl-x64" "1.2.4"
+
+ version "0.34.5"
+ resolved "https://registry.yarnpkg.com/@img/sharp-wasm32/-/sharp-wasm32-0.34.5.tgz#2f15803aa626f8c59dd7c9d0bbc766f1ab52cfa0"
+ integrity sha512-OdWTEiVkY2PHwqkbBI8frFxQQFekHaSSkUIJkwzclWZe64O1X4UlUjqqqLaPbUpMOQk6FBu/HtlGXNblIs0huw==
+ dependencies:
+ "@emnapi/runtime" "^1.7.0"
+
+ version "0.34.5"
+ resolved "https://registry.yarnpkg.com/@img/sharp-win32-arm64/-/sharp-win32-arm64-0.34.5.tgz#3706e9e3ac35fddfc1c87f94e849f1b75307ce0a"
+ integrity sha512-WQ3AgWCWYSb2yt+IG8mnC6Jdk9Whs7O0gxphblsLvdhSpSTtmu69ZG1Gkb6NuvxsNACwiPV6cNSZNzt0KPsw7g==
+
+ version "0.34.5"
+ resolved "https://registry.yarnpkg.com/@img/sharp-win32-ia32/-/sharp-win32-ia32-0.34.5.tgz#0b71166599b049e032f085fb9263e02f4e4788de"
+ integrity sha512-FV9m/7NmeCmSHDD5j4+4pNI8Cp3aW+JvLoXcTUo0IqyjSfAZJ8dIUmijx1qaJsIiU+Hosw6xM5KijAWRJCSgNg==
+
+ version "0.34.5"
+ resolved "https://registry.yarnpkg.com/@img/sharp-win32-x64/-/sharp-win32-x64-0.34.5.tgz#a81ffb00e69267cd0a1d626eaedb8a8430b2b2f8"
+ integrity sha512-+29YMsqY2/9eFEiW93eqWnuLcWcufowXewwSNIT6UwZdUUCrM3oFjMWH/Z6/TMmb4hlFenmfAVbpWeup2jryCw==
+
"@inquirer/external-editor@^1.0.2":
version "1.0.3"
resolved "https://registry.yarnpkg.com/@inquirer/external-editor/-/external-editor-1.0.3.tgz#c23988291ee676290fdab3fd306e64010a6d13b8"
@@ -1300,6 +1471,51 @@
dependencies:
"@types/mdx" "^2.0.0"
+ version "15.5.12"
+ resolved "https://registry.yarnpkg.com/@next/env/-/env-15.5.12.tgz#e8f5be3b951ea964050e95ed9a45009d49f0f831"
+ integrity sha512-pUvdJN1on574wQHjaBfNGDt9Mz5utDSZFsIIQkMzPgNS8ZvT4H2mwOrOIClwsQOb6EGx5M76/CZr6G8i6pSpLg==
+
+ version "15.5.12"
+ resolved "https://registry.yarnpkg.com/@next/swc-darwin-arm64/-/swc-darwin-arm64-15.5.12.tgz#4989deb3ddb408ec8c1a46a7c24608e01fd16029"
+ integrity sha512-RnRjBtH8S8eXCpUNkQ+543DUc7ys8y15VxmFU9HRqlo9BG3CcBUiwNtF8SNoi2xvGCVJq1vl2yYq+3oISBS0Zg==
+
+ version "15.5.12"
+ resolved "https://registry.yarnpkg.com/@next/swc-darwin-x64/-/swc-darwin-x64-15.5.12.tgz#de954324e7aefb13e82aa6b34695fd89d052b7cb"
+ integrity sha512-nqa9/7iQlboF1EFtNhWxQA0rQstmYRSBGxSM6g3GxvxHxcoeqVXfGNr9stJOme674m2V7r4E3+jEhhGvSQhJRA==
+
+ version "15.5.12"
+ resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-15.5.12.tgz#27b42c8fb19909d68ffe3eb8ebb855bdedb7bad0"
+ integrity sha512-dCzAjqhDHwmoB2M4eYfVKqXs99QdQxNQVpftvP1eGVppamXh/OkDAwV737Zr0KPXEqRUMN4uCjh6mjO+XtF3Mw==
+
+ version "15.5.12"
+ resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-15.5.12.tgz#7a1d20944cb06973d62a213d909e29f7adcb8f6b"
+ integrity sha512-+fpGWvQiITgf7PUtbWY1H7qUSnBZsPPLyyq03QuAKpVoTy/QUx1JptEDTQMVvQhvizCEuNLEeghrQUyXQOekuw==
+
+ version "15.5.12"
+ resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-15.5.12.tgz#5b900c32b1076f9498c11b13dc09316b87b82d95"
+ integrity sha512-jSLvgdRRL/hrFAPqEjJf1fFguC719kmcptjNVDJl26BnJIpjL3KH5h6mzR4mAweociLQaqvt4UyzfbFjgAdDcw==
+
+ version "15.5.12"
+ resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-15.5.12.tgz#48c3ae684a5e61feacaed6610e104477d62be4dc"
+ integrity sha512-/uaF0WfmYqQgLfPmN6BvULwxY0dufI2mlN2JbOKqqceZh1G4hjREyi7pg03zjfyS6eqNemHAZPSoP84x17vo6w==
+
+ version "15.5.12"
+ resolved "https://registry.yarnpkg.com/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-15.5.12.tgz#b2a81848ded9538a11ca6d62b7a1f3d78a56edf5"
+ integrity sha512-xhsL1OvQSfGmlL5RbOmU+FV120urrgFpYLq+6U8C6KIym32gZT6XF/SDE92jKzzlPWskkbjOKCpqk5m4i8PEfg==
+
+ version "15.5.12"
+ resolved "https://registry.yarnpkg.com/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-15.5.12.tgz#c92f55638340f44e092254281307202c243fbd61"
+ integrity sha512-Z1Dh6lhFkxvBDH1FoW6OU/L6prYwPSlwjLiZkExIAh8fbP6iI/M7iGTQAJPYJ9YFlWobCZ1PHbchFhFYb2ADkw==
+
"@nodelib/[email protected]":
version "2.1.5"
resolved "https://registry.yarnpkg.com/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz#7619c2eb21b25483f6d167548b4cfd5a7488c3d5"
@@ -1782,6 +1998,17 @@
babel-plugin-syntax-hermes-parser "^0.26.0"
esbuild "^0.24.0"
+"@stylexjs/nextjs-plugin@^0.11.1":
+ version "0.11.1"
+ resolved "https://registry.yarnpkg.com/@stylexjs/nextjs-plugin/-/nextjs-plugin-0.11.1.tgz#0137b7d2dd8751cdfcf337079e24d160c2b2c61b"
+ integrity sha512-42mJGw9W3i9cRrChv25JCMGvWhCVVcmt1EqgOgRMy3XTH45Ehd9TkwDiVmhknvSEDKxw+ib3AiSPjZ1ehZ9d6A==
+ dependencies:
+ "@babel/core" "^7.26.8"
+ "@babel/plugin-syntax-flow" "^7.26.0"
+ "@babel/plugin-syntax-jsx" "^7.25.9"
+ "@babel/plugin-syntax-typescript" "^7.25.9"
+ "@stylexjs/babel-plugin" "0.11.1"
+
"@stylexjs/[email protected]":
version "0.11.1"
resolved "https://registry.yarnpkg.com/@stylexjs/shared/-/shared-0.11.1.tgz#c92160f33161f5721f5e1b4a623f99892df5d319"
@@ -1825,6 +2052,13 @@
browserslist "^4.24.0"
lightningcss "^1.29.1"
+ version "0.5.15"
+ resolved "https://registry.yarnpkg.com/@swc/helpers/-/helpers-0.5.15.tgz#79efab344c5819ecf83a43f3f9f811fc84b516d7"
+ integrity sha512-JQ5TuMi45Owi4/BIMAJBoSQoOJu12oOk/gADqlcUL9JEdHB8vyjUSsxqeNXnmXHjYKMi2WcYtezGEEhqUI/E2g==
+ dependencies:
+ tslib "^2.8.0"
+
"@testing-library/[email protected]":
version "10.4.0"
resolved "https://registry.yarnpkg.com/@testing-library/dom/-/dom-10.4.0.tgz#82a9d9462f11d240ecadbf406607c6ceeeff43a8"
@@ -2427,6 +2661,11 @@ callsites@^3.0.0:
resolved "https://registry.yarnpkg.com/callsites/-/callsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73"
integrity sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==
+caniuse-lite@^1.0.30001579:
+ version "1.0.30001769"
+ resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001769.tgz#1ad91594fad7dc233777c2781879ab5409f7d9c2"
+ integrity sha512-BCfFL1sHijQlBGWBMuJyhZUhzo7wer5sVj9hqekB/7xn0Ypy+pER/edCYQm4exbXj4WiySGp40P8UuTh6w1srg==
+
caniuse-lite@^1.0.30001759:
version "1.0.30001764"
resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001764.tgz#03206c56469f236103b90f9ae10bcb8b9e1f6005"
@@ -2481,6 +2720,11 @@ ci-info@^3.7.0:
resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-3.9.0.tgz#4279a62028a7b1f262f3473fc9605f5e218c59b4"
integrity sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==
+ version "0.0.1"
+ resolved "https://registry.yarnpkg.com/client-only/-/client-only-0.0.1.tgz#38bba5d403c41ab150bff64a95c85013cf73bca1"
+ integrity sha512-IV3Ou0jSMzZrd3pZ48nLkT9DA7Ag1pnPzaiQhpW7c3RbcqqzvzzVu+L8gfqMp/8IM2MQtSiqaCxrrcfu8I8rMA==
+
color-convert@^2.0.1:
version "2.0.1"
resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3"
@@ -2619,7 +2863,7 @@ detect-indent@^6.0.0:
resolved "https://registry.yarnpkg.com/detect-indent/-/detect-indent-6.1.0.tgz#592485ebbbf6b3b1ab2be175c8393d04ca0d57e6"
integrity sha512-reYkTUJAZb9gUuZ2RvVCNhVHdg62RHnJ7WJl8ftMi4diZ6NWlciOzQN88pUhSELEwflJht4oQDv0F0BMlwaYtA==
-detect-libc@^2.0.3:
+detect-libc@^2.0.3, detect-libc@^2.1.2:
version "2.1.2"
resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-2.1.2.tgz#689c5dcdc1900ef5583a4cb9f6d7b473742074ad"
integrity sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==
@@ -3858,7 +4102,7 @@ mz@^2.7.0:
object-assign "^4.0.1"
thenify-all "^1.0.0"
-nanoid@^3.3.11:
+nanoid@^3.3.11, nanoid@^3.3.6:
version "3.3.11"
resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.11.tgz#4f4f112cefbe303202f2199838128936266d185b"
integrity sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==
@@ -3868,6 +4112,27 @@ natural-compare@^1.4.0:
resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7"
integrity sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==
+next@^15.0.0:
+ version "15.5.12"
+ resolved "https://registry.yarnpkg.com/next/-/next-15.5.12.tgz#af68c24b6f5535fcf37dbb913194db02c4d0a3ec"
+ integrity sha512-Fi/wQ4Etlrn60rz78bebG1i1SR20QxvV8tVp6iJspjLUSHcZoeUXCt+vmWoEcza85ElZzExK/jJ/F6SvtGktjA==
+ dependencies:
+ "@next/env" "15.5.12"
+ "@swc/helpers" "0.5.15"
+ caniuse-lite "^1.0.30001579"
+ postcss "8.4.31"
+ styled-jsx "5.1.6"
+ optionalDependencies:
+ "@next/swc-darwin-arm64" "15.5.12"
+ "@next/swc-darwin-x64" "15.5.12"
+ "@next/swc-linux-arm64-gnu" "15.5.12"
+ "@next/swc-linux-arm64-musl" "15.5.12"
+ "@next/swc-linux-x64-gnu" "15.5.12"
+ "@next/swc-linux-x64-musl" "15.5.12"
+ "@next/swc-win32-arm64-msvc" "15.5.12"
+ "@next/swc-win32-x64-msvc" "15.5.12"
+ sharp "^0.34.3"
+
node-releases@^2.0.27:
version "2.0.27"
resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-2.0.27.tgz#eedca519205cf20f650f61d56b070db111231e4e"
@@ -4018,7 +4283,7 @@ pathval@^2.0.0:
resolved "https://registry.yarnpkg.com/pathval/-/pathval-2.0.1.tgz#8855c5a2899af072d6ac05d11e46045ad0dc605d"
integrity sha512-//nshmD55c46FuFw26xV/xFAaB5HF9Xdap7HJBBnrKdAd6/GxDBaNA1870O79+9ueg61cZLSVc+OaFlfmObYVQ==
-picocolors@^1.1.0, picocolors@^1.1.1:
+picocolors@^1.0.0, picocolors@^1.1.0, picocolors@^1.1.1:
version "1.1.1"
resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.1.1.tgz#3d321af3eab939b083c8f929a1d12cda81c26b6b"
integrity sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==
@@ -4090,6 +4355,15 @@ postcss-value-parser@^4.1.0:
resolved "https://registry.yarnpkg.com/postcss-value-parser/-/postcss-value-parser-4.2.0.tgz#723c09920836ba6d3e5af019f92bc0971c02e514"
integrity sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ==
+ version "8.4.31"
+ resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.4.31.tgz#92b451050a9f914da6755af352bdc0192508656d"
+ integrity sha512-PS08Iboia9mts/2ygV3eLpY5ghnUcfLV/EXTOW1E2qYxJKGGBUtNjN76FYHnMs36RmARn41bC0AZmn+rR0OVpQ==
+ dependencies:
+ nanoid "^3.3.6"
+ picocolors "^1.0.0"
+ source-map-js "^1.0.2"
+
postcss@^8.4.43:
version "8.5.6"
resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.5.6.tgz#2825006615a619b4f62a9e7426cc120b349a8f3c"
@@ -4360,6 +4634,40 @@ set-function-length@^1.2.2:
gopd "^1.0.1"
has-property-descriptors "^1.0.2"
+sharp@^0.34.3:
+ version "0.34.5"
+ resolved "https://registry.yarnpkg.com/sharp/-/sharp-0.34.5.tgz#b6f148e4b8c61f1797bde11a9d1cfebbae2c57b0"
+ integrity sha512-Ou9I5Ft9WNcCbXrU9cMgPBcCK8LiwLqcbywW3t4oDV37n1pzpuNLsYiAV8eODnjbtQlSDwZ2cUEeQz4E54Hltg==
+ dependencies:
+ "@img/colour" "^1.0.0"
+ detect-libc "^2.1.2"
+ semver "^7.7.3"
+ optionalDependencies:
+ "@img/sharp-darwin-arm64" "0.34.5"
+ "@img/sharp-darwin-x64" "0.34.5"
+ "@img/sharp-libvips-darwin-arm64" "1.2.4"
+ "@img/sharp-libvips-darwin-x64" "1.2.4"
+ "@img/sharp-libvips-linux-arm" "1.2.4"
+ "@img/sharp-libvips-linux-arm64" "1.2.4"
+ "@img/sharp-libvips-linux-ppc64" "1.2.4"
+ "@img/sharp-libvips-linux-riscv64" "1.2.4"
+ "@img/sharp-libvips-linux-s390x" "1.2.4"
+ "@img/sharp-libvips-linux-x64" "1.2.4"
+ "@img/sharp-libvips-linuxmusl-arm64" "1.2.4"
+ "@img/sharp-libvips-linuxmusl-x64" "1.2.4"
+ "@img/sharp-linux-arm" "0.34.5"
+ "@img/sharp-linux-arm64" "0.34.5"
+ "@img/sharp-linux-ppc64" "0.34.5"
+ "@img/sharp-linux-riscv64" "0.34.5"
+ "@img/sharp-linux-s390x" "0.34.5"
+ "@img/sharp-linux-x64" "0.34.5"
+ "@img/sharp-linuxmusl-arm64" "0.34.5"
+ "@img/sharp-linuxmusl-x64" "0.34.5"
+ "@img/sharp-wasm32" "0.34.5"
+ "@img/sharp-win32-arm64" "0.34.5"
+ "@img/sharp-win32-ia32" "0.34.5"
+ "@img/sharp-win32-x64" "0.34.5"
+
shebang-command@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-2.0.0.tgz#ccd0af4f8835fbdc265b82461aaf0c36663f34ea"
@@ -4382,12 +4690,17 @@ signal-exit@^4.0.1:
resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-4.1.0.tgz#952188c1cbd546070e2dd20d0f41c0ae0530cb04"
integrity sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==
+sisteransi@^1.0.5:
+ version "1.0.5"
+ resolved "https://registry.yarnpkg.com/sisteransi/-/sisteransi-1.0.5.tgz#134d681297756437cc05ca01370d3a7a571075ed"
+ integrity sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==
+
slash@^3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/slash/-/slash-3.0.0.tgz#6539be870c165adbd5240220dbe361f1bc4d4634"
integrity sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==
-source-map-js@^1.0.1, source-map-js@^1.2.0, source-map-js@^1.2.1:
+source-map-js@^1.0.1, source-map-js@^1.0.2, source-map-js@^1.2.0, source-map-js@^1.2.1:
version "1.2.1"
resolved "https://registry.yarnpkg.com/source-map-js/-/source-map-js-1.2.1.tgz#1ce5650fddd87abc099eda37dcff024c2667ae46"
integrity sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==
@@ -4502,6 +4815,13 @@ strip-json-comments@^3.1.1:
resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006"
integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==
+ version "5.1.6"
+ resolved "https://registry.yarnpkg.com/styled-jsx/-/styled-jsx-5.1.6.tgz#83b90c077e6c6a80f7f5e8781d0f311b2fe41499"
+ integrity sha512-qSVyDTeMotdvQYoHWLNGwRFJHC+i+ZvdBRYosOFgC+Wg1vx4frN2/RG/NA7SYqqvKNLf39P2LSRA2pu6n0XYZA==
+ dependencies:
+ client-only "0.0.1"
+
version "0.2.1"
resolved "https://registry.yarnpkg.com/styleq/-/styleq-0.2.1.tgz#062f6446d6eef9961140e80e0b70e872be77c60c"
@@ -4665,7 +4985,7 @@ tsconfig-paths@^4.2.0:
minimist "^1.2.6"
strip-bom "^3.0.0"
-tslib@^2.0.1:
+tslib@^2.0.1, tslib@^2.4.0, tslib@^2.8.0:
version "2.8.1"
resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.8.1.tgz#612efe4ed235d567e8aba5f2a5fab70280ade83f"
integrity sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==