🎯 Nexus teaches Next.js from foundations to professional systems⚡ App Router, React 19, and Tailwind v4 in one learning path🧩 Inspect real components, layouts, and reusable patterns🛠️ Build production discipline, not just polished demos📚 Tracks, references, and design studies in one place🎯 Nexus teaches Next.js from foundations to professional systems⚡ App Router, React 19, and Tailwind v4 in one learning path🧩 Inspect real components, layouts, and reusable patterns🛠️ Build production discipline, not just polished demos📚 Tracks, references, and design studies in one place🎯 Nexus teaches Next.js from foundations to professional systems⚡ App Router, React 19, and Tailwind v4 in one learning path🧩 Inspect real components, layouts, and reusable patterns🛠️ Build production discipline, not just polished demos📚 Tracks, references, and design studies in one place🎯 Nexus teaches Next.js from foundations to professional systems⚡ App Router, React 19, and Tailwind v4 in one learning path🧩 Inspect real components, layouts, and reusable patterns🛠️ Build production discipline, not just polished demos📚 Tracks, references, and design studies in one place
Form Components

Autocomplete

Searchable combobox with keyboard navigation, type-to-filter, and optional multi-select. Supports icons, descriptions, avatars, loading state, helper text, and error state.

Quick Preview

Selected: react

Installation

// Copy from
src/components/forms/Autocomplete.tsx

Usage

'use client'
import { useState } from 'react'
import { Autocomplete } from '@/components/forms/Autocomplete'
// Single-select (controlled)
export function FrameworkPicker() {
const [framework, setFramework] = useState<string | undefined>()
return (
<Autocomplete
options={[
{ value: 'react', label: 'React', icon: '⚛️' },
{ value: 'vue', label: 'Vue', icon: '💚' },
{ value: 'next', label: 'Next.js', icon: '▲' },
]}
value={framework}
label="Framework"
helperText="Select your preferred framework"
onChange={(v) => setFramework(v as string | undefined)}
/>
)
}
// Multi-select with max limit
export function SkillsPicker() {
const [skills, setSkills] = useState<string[]>([])
return (
<Autocomplete
multiple
maxItems={5}
options={SKILLS_OPTIONS}
value={skills}
label="Skills (max 5)"
placeholder="Add skill…"
onChange={(v) => setSkills(v as string[])}
/>
)
}

Examples

Single select

Default mode — pick one option.

selected: react

Multi-select

Pass multiple to pick many options. Selected items appear as chips inside the input.

selected: [react, next]

With icons and descriptions

Add icon and description to each option.

Loading state

Show a spinner while async results load.

With helper text

Provide contextual hint below the input.

Choose the framework for your project

With error state

Display validation error below input.

This field is required

Disabled

Pass disabled to prevent interaction.

Prompt Preview

Copy a prompt that recreates this UI

Paste this into your AI coding assistant to generate code that closely matches the reference, including color, size, shape, typography, spacing, and polish.

Copy-ready AI prompt

Starts from the current visual reference and project constraints.

Tweak only product-specific copy or data after the first generation pass.

Props

PropTypeDefaultDescription
options*AutocompleteOption[]-Array of selectable options
valuestring | string[]-Controlled selected value(s)
defaultValuestring | string[]-Uncontrolled default value(s)
multiplebooleanfalseEnable multi-selection; selected items render as chips
placeholderstring'Search…'Input placeholder text
labelstring-Label displayed above the input
helperTextstring-Helper text shown below the input
errorTextstring-Error message; overrides helperText and adds red ring
disabledbooleanfalseDisables all interaction
loadingbooleanfalseReplaces chevron with spinner
clearablebooleantrueShow × button to clear selection
maxItemsnumber-Limit selected items in multi mode
noOptionsTextstring'No options found'Empty-state label
onChange(value: string | string[] | undefined) => void-Fires when selection changes
onSearch(query: string) => void-Fires on each keystroke — use for async data fetching

Keyboard Navigation

KeyAction
↓ / ↑Move focus through options
EnterSelect focused option
EscapeClose dropdown and blur input
BackspaceRemove last selected chip (multi mode, when input is empty)
TabClose dropdown and move focus to next element