This document describes the technical architecture, design decisions, and system structure of ShellUI.
ShellUI is a CLI-first Blazor component library that copies components directly into user projects rather than distributing them as NuGet packages. This architectural choice enables full customization and ownership of component code.
User/Developer runs shellui init | add | list | remove | update.
ShellUI.CLI (Global .NET Tool) handles commands via:
- InitService / TailwindDownloader (init)
- ComponentInstaller (add, update – resolves dependencies, writes files)
- ComponentManager (list, remove)
ShellUI.Templates (embedded in CLI) provides ComponentRegistry with 139 templates. GetComponentContent(name) returns Razor/C# source.
Packages: ShellUI.Core (models/config), ShellUI.Components (NuGet – components, variants, services, theme CSS).
User's Blazor Project receives copied source in Components/UI/, Variants/, Services/, plus shellui.json and Tailwind config.
- CLI references: Templates, Core, Components
- Templates and Components both depend on Core
- CLI copies source to user project on
add - NuGet option: User adds ShellUI.Components package directly
When you run shellui add button, that counts as 1 component. Dependencies (button-variants, etc.) are auto-installed and not counted.
| Category | Installable | Description |
|---|---|---|
| Form | 14 | Button, Input, Select, Checkbox, Switch, etc. |
| Layout | 15 | Card, Dialog, Sheet, Drawer, Popover, etc. |
| Navigation | 12 | Navbar, Sidebar, Tabs, Breadcrumb, etc. |
| Data Display | 14 | Table, Badge, Avatar, Alert, Toast, Sonner, etc. |
| Feedback | 8 | Toast, Sonner, Loading, Skeleton, Progress, etc. |
| Overlay | 10 | Dialog, Sheet, Drawer, Tooltip, Popover, etc. |
| Charts | 9 | Chart, BarChart, LineChart, PieChart, etc. |
| Utility | 18 | ThemeToggle, CopyButton, ScrollArea, etc. |
| Total | ~100 | *Actual components only; *-variants, -service excluded |
- src/ShellUI.CLI/ – Global tool (init, add, list, remove, update)
- src/ShellUI.Core/ – ComponentMetadata, ShellUIConfig
- src/ShellUI.Templates/ – 139 component templates (embedded in CLI)
- src/ShellUI.Components/ – NuGet package
- NET9/ – Blazor demo app
- docs/ – Documentation
- Copy, Don't Install – Components copied to your project
- Tailwind-First – All styling via Tailwind CSS v4
- Composability – Variants for styling, Services for shared state
- Dependency Resolution –
shellui add dialoginstalls dialog + sub-components automatically
- Look up component in ComponentRegistry
- Resolve dependencies (e.g., button → button-variants)
- Get content from Template.Content
- Write files (e.g., Components/UI/Button.razor, Variants/ButtonVariants.cs)
- Update shellui.json
- QUICKSTART.md - Get started
- CLI_SYNTAX.md - Command reference
- COMPONENT_DEPENDENCIES.md - Dependency details
- COMPONENT_ROADMAP.md - Roadmap