codefast/ui

Command Palette

Search for a command to run...

Components

65+ ready-to-use components.

Built on Radix UI primitives with Tailwind CSS v4. Each component ships as a named sub-path import — no barrel files, no tree-shaking surprises, no config required.

Display

Presentational atoms for surfacing information, status, and identity. No interactivity required.

13 components
@codefast/ui/badge
Badge

Compact label for status, category, or count. Four variants cover most use cases.

@codefast/ui/alert
Alert

Contextual banner with icon, title, and body. Supports default and destructive variants.

@codefast/ui/avatar
Avatar

User icon with image support and initials fallback. Compose with AvatarGroup for stacks.

@codefast/ui/spinner
Spinner

Indeterminate loading indicator. Wrap children — shown when loading is false.

@codefast/ui/kbd
Kbd

Keyboard shortcut display. Use KbdGroup to compose multi-key combos.

@codefast/ui/aspect-ratio
Aspect Ratio

Locks content to a specific width-to-height ratio. Useful for images, videos, and embeds.

@codefast/ui/chart
Chart

Recharts wrapper with consistent theming, tooltip, and legend. Supports all chart types.

@codefast/ui/empty
Empty

Empty-state layout with media, title, description, and action slots.

@codefast/ui/item
Item

Row layout for lists. Composes media, content, title, description, and action slots.

@codefast/ui/table
Table

Semantic HTML table with styled header, body, footer, and caption slots.

@tanstack/react-table · Table
Data Table

A sortable, filterable, paginated table built with TanStack Table and the Table primitives.

Tailwind utility classes
Typography

Styled headings, paragraphs, lists, blockquotes, and tables built from Tailwind utility classes.

Form

Input primitives and controls for collecting user data. All keyboard-accessible and screen-reader ready.

26 components
@codefast/ui/button
Button

Six variants and four sizes. Supports icons, loading state, and asChild composition.

@codefast/ui/button-group
Button Group

Horizontal or vertical group that visually joins adjacent buttons into a single control.

@codefast/ui/input
Input

Text input with focus ring, disabled state, and file input styling.

@codefast/ui/input-group
Input Group

Composes an input with leading/trailing addons, text labels, and icon buttons.

@codefast/ui/input-number
Input Number

Numeric input with increment/decrement controls, min/max/step, and format options.

@codefast/ui/input-otp
Input OTP

One-time password input with slot groups and separator. Built on input-otp.

@codefast/ui/input-password
Input Password

Password field with a show/hide toggle. Extends Input Group with no extra markup.

@codefast/ui/textarea
Textarea

Multiline text input. Pair with Label and field utilities for accessible forms.

@codefast/ui/select
Select

Accessible dropdown selector. Supports groups, disabled options, and custom triggers.

@codefast/ui/native-select
Native Select

Styled HTML select element with option groups. Zero JS — best for mobile forms.

@codefast/ui/checkbox
Checkbox

Binary control with indeterminate state. Controlled or uncontrolled via onCheckedChange.

@codefast/ui/checkbox-group
Checkbox Group

Multi-select group of checkboxes sharing a value array. Supports disabled items.

@codefast/ui/checkbox-cards
Checkbox Cards

Card-style multi-select. Each card has a built-in checkbox with highlighted selected state.

@codefast/ui/radio
Radio

Single native radio input. Use Radio Group for accessible keyboard-navigable groups.

@codefast/ui/radio-group
Radio Group

Single-selection group. Use value + onValueChange for controlled behaviour.

@codefast/ui/radio-cards
Radio Cards

Card-style single-select. Each card highlights when selected, ideal for plan pickers.

@codefast/ui/switch
Switch

Toggle control for boolean settings. Fires onCheckedChange with the new boolean value.

@codefast/ui/slider
Slider

Range input with keyboard support. Supports min, max, step, and multiple thumbs.

@codefast/ui/toggle
Toggle

Pressable button with active/inactive state. Use ToggleGroup for exclusive selection.

@codefast/ui/toggle-group
Toggle Group

Single or multiple selection group of toggle buttons. Ideal for toolbars and alignment pickers.

@codefast/ui/calendar
Calendar

Full calendar built on @daypicker/react. Supports single, multiple, and range selection.

Calendar · Popover
Date Picker

A date and date-range picker composed from a Popover and the Calendar component.

@codefast/ui/label
Label

Accessible form label that forwards htmlFor. Pairs with any form control.

@codefast/ui/field
Field

Layout wrapper that composes label, description, error, and control in vertical or horizontal orientation.

@codefast/ui/form
Form

React Hook Form integration with accessible label, description, and error message binding.

Overlay

Floating UI: modals, popovers, menus, and tooltips. All trap focus and close on Escape.

10 components
@codefast/ui/dialog
Dialog

Modal window with focus trap, backdrop blur, and accessible close. Use AlertDialog for destructive confirms.

@codefast/ui/tooltip
Tooltip

Hover label with delay and side placement control. Supports rich content including Kbd.

@codefast/ui/popover
Popover

Non-modal floating panel anchored to a trigger. Use for settings panels and pickers.

@codefast/ui/alert-dialog
Alert Dialog

Blocking confirmation modal requiring an explicit decision. Backs the browser back button.

@codefast/ui/command
Command

Command palette with fuzzy search, groups, keyboard shortcuts, and empty state.

@codefast/ui/context-menu
Context Menu

Right-click menu with items, checkboxes, radio groups, submenus, and shortcuts.

@codefast/ui/drawer
Drawer

Bottom sheet drawer built on Vaul. Supports drag-to-dismiss and scale background.

@codefast/ui/hover-card
Hover Card

Rich preview card that appears on hover. Ideal for user profiles and link previews.

@codefast/ui/sheet
Sheet

Side-anchored panel (left, right, top, or bottom). Useful for settings and detail drawers.

Feedback

Status indicators, confirmations, and loading states that communicate async operations to users.

4 components
@codefast/ui/progress
Progress

Determinate progress bar. Pass value 0–100. Colour via className on the indicator slot.

@codefast/ui/progress-circle
Progress Circle

Circular progress indicator with optional value label and animation. Multiple sizes.

@codefast/ui/skeleton
Skeleton

Shimmer placeholder for any shape of content — cards, text lines, avatars.

@codefast/ui/sonner
Sonner

Toast notifications via Sonner. Supports success, error, warning, and custom durations.

Layout

Structural components for organising and containing content. Compose freely with any child.

6 components
@codefast/ui/card
Card

Elevated surface for grouping related content. Compose Header, Content, and Footer slots freely.

@codefast/ui/accordion
Accordion

Expandable sections with smooth animation. Supports single or multiple open items.

@codefast/ui/separator
Separator

Semantic horizontal or vertical divider. Renders as hr with role=separator.

@codefast/ui/scroll-area
Scroll Area

Custom-styled scrollbar that matches your design system. Hides native OS scrollbars.

@codefast/ui/collapsible
Collapsible

Togglable content section with animated expand/collapse. Controlled or uncontrolled.

@codefast/ui/resizable
Resizable

Drag-to-resize panel groups. Supports horizontal, vertical, and nested layouts.