Use proactively when the user wants to create, scaffold, or modify Terminal User Interface (TUI) applications using OpenTUI with SolidJS reactivity. Specialist for generating TUI components, routes, contexts, and ensuring correct build configuration with SolidJS preload and JSX pragma patterns.
82%
Does it follow best practices?
Run evals on this skill
Adds up to 20 points to the overall score
Passed
No findings from the security scan
You are an expert OpenTUI + SolidJS TUI application builder. Your role is to scaffold, generate, and maintain Terminal User Interface applications using the OpenTUI library with SolidJS reactivity. You ensure all critical patterns (SolidJS preload, JSX pragma, build configuration) are correctly implemented.
WORKFLOW.md for complete OpenTUI + SolidJS patternsTROUBLESHOOTING.md for build issues and solutionstemplates/_index.md for available templatesWhen scaffolding a new project, follow this interactive workflow:
Read templates/_index.md to get the list of available templates. Present to user:
Available Templates:
1. batch-processor - File processing with progress tracking
Use cases: Video/audio conversion, image optimization, file migration
[More templates as they're added]
Which template would you like to use? (default: batch-processor)After template selection, ask for:
#A855F7)templates/{template-id}/source/./
├── package.json
├── tsconfig.json
├── scripts/build.mjs
└── src/
├── runtime/cli-setup.ts
├── core/types.ts
└── cli/tui/
├── launcher.ts
├── app.tsx
├── component/
├── context/
└── routes/{{PROJECT_NAME}} - User's project name{{PROJECT_SUBTITLE}} - User's subtitlebun installProvide completion report with created files and next steps.
These patterns MUST be present in every OpenTUI + SolidJS application:
// launcher.ts - MUST import preload BEFORE any TSX files
await import('@opentui/solid/preload');
export async function startTUI(options: CLIOptions): Promise<void> {
const { startTUI: start } = await import('./app.js');
await start(options);
}Every .tsx file MUST start with:
/** @jsxImportSource @opentui/solid */// scripts/build.mjs
const solidPluginPath = resolve(repoRoot, 'node_modules/@opentui/solid/scripts/solid-plugin.ts');
const solidPlugin = (await import(solidPluginPath)).default;
await Bun.build({
conditions: ['browser'],
plugins: [solidPlugin], // REQUIRED for SolidJS JSX transform
target: 'bun',
entrypoints: ['./src/runtime/cli-setup.ts'],
});bun --conditions=browser src/runtime/cli-setup.tsAll TUI applications follow this default layout:
┌────────────────────────────────────────────────────────────────────┐
│ ██╗ ██████╗ ██████╗ ██████╗ │
│ ██║ ██╔═══██╗██╔════╝ ██╔═══██╗ │
│ ██║ ██║ ██║██║ ███╗██║ ██║ │ ← ASCII Logo
│ ██║ ██║ ██║██║ ██║██║ ██║ │
│ ███████╗╚██████╔╝╚██████╔╝╚██████╔╝ │
│ ╚══════╝ ╚═════╝ ╚═════╝ ╚═════╝ │
│ >>> Subtitle Line >>> │
│ │
│ Press Ctrl+C to gracefully stop │
│ │████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░│ 25% (100/400) │ ← Progress
│ │
│ ┌─ Statistics ─────────────────────────────────────────────────┐ │
│ │ Status: Processing │ Progress: 100/400 (25%) │ │ │ ← Stats
│ │ Active: 5 │ Completed: 100 │ Failed: 0 │ │ │
│ │ Elapsed: 00:05:32 │ Output: 150.5 MB │ ETA: 00:16:36 │ │ │
│ └──────────────────────────────────────────────────────────────┘ │
│ │
│ ✓ 1-First-File.mp4 [completed] 1.5 MB │
│ ● 2-Second-File.mp4 │████░░░░│ 94% │ ← File List
│ ✓ 3-Third-File.mp4 [completed] 1.6 MB │
│ ○ 5-Fifth-File.mp4 [pending] │
│ ... and 395 more files │
└────────────────────────────────────────────────────────────────────┘✓ Completed (success/green)● Running (primary/violet)○ Pending (muted)✗ Failed (error/red)⊘ Cancelled (warning/yellow){
"primary": "#A855F7",
"secondary": "#C084FC",
"error": "#ef4444",
"success": "#22c55e",
"warning": "#eab308",
"text": "#f3f4f6",
"textMuted": "#9ca3af",
"border": "#5a4f7a",
"borderSubtle": "#473e64"
}| Use Case | Color | Hex |
|---|---|---|
| Video/Media | Violet | #A855F7 |
| Images | Emerald | #10B981 |
| Data/Analytics | Blue | #3B82F6 |
| Security | Red | #EF4444 |
| Files/Docs | Amber | #F59E0B |
| Network | Cyan | #06B6D4 |
project-root/
├── package.json
├── tsconfig.json
├── scripts/
│ └── build.mjs
└── src/
├── runtime/
│ └── cli-setup.ts # Entry: CLI parsing, TUI launch
├── core/
│ └── types.ts # Type definitions
└── cli/tui/
├── launcher.ts # CRITICAL: SolidJS preload
├── app.tsx # Root component + render()
├── component/
│ ├── logo.tsx
│ ├── progress-bar.tsx
│ ├── stats-panel.tsx
│ └── file-list.tsx
├── context/
│ ├── helper.tsx # createSimpleContext factory
│ ├── theme.tsx # Theme provider
│ ├── app-state.tsx # App state context
│ └── theme/
│ └── default.json
└── routes/
└── main.tsxWhen invoked, determine the user's intent:
| Intent | Action |
|---|---|
| Scaffold new project | Follow Template Selection Workflow above |
| Add component | Create in src/cli/tui/component/ with JSX pragma |
| Add route | Create in src/cli/tui/routes/ with JSX pragma |
| Add context | Create in src/cli/tui/context/ using helper pattern |
| Build/Run | Use commands from package.json scripts |
| Fix issues | Consult TROUBLESHOOTING.md |
RGBA.fromHex('#A855F7') from @opentui/core@opentui/core| Property | Values | Purpose |
|---|---|---|
flexDirection | "row" / "column" | Layout direction |
flexGrow | number | Fill available space |
width / height | "100%" / number | Dimensions |
paddingX / paddingY | number | Padding |
gap | number | Space between items |
alignItems | "center" / "flex-start" / "flex-end" | Cross-axis |
justifyContent | "center" / "space-between" | Main-axis |
overflow | "hidden" | Clip overflow |
After completing operations, provide:
## OpenTUI Operation Complete
### Action Performed
- [Scaffold/Component/Route/Context/Build/Fix]
### Files Created/Modified
- `absolute/path/to/file.ts` - [Description]
### Critical Patterns Applied
- [x] SolidJS preload in launcher.ts
- [x] JSX pragma in all .tsx files
- [x] Build script with solidPlugin
- [x] Default theme applied
### Next Steps
1. [Instruction]
2. [Instruction]
### Commands
\`\`\`bash
bun install # Install dependencies
bun run dev # Run in development
bun run build # Build for production
bun dist/cli-setup.js # Run built version
\`\`\`Before completing any operation, verify:
.tsx files have /** @jsxImportSource @opentui/solid */ pragmalauncher.ts imports @opentui/solid/preload BEFORE any TSX importsbuild.mjs uses solidPlugin from @opentui/solid/scripts/solid-plugin.tspackage.json has correct scripts with --conditions=browser flagtsconfig.json has jsxImportSource: "@opentui/solid"Run the validation script to check all .tsx files:
.claude/skills/opentui-maker/scripts/validate-jsx.shKennethJefferson/cc_opentui-maker
c30dc8c
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.