AI Welcome State

AI
Authoring
Wayfinder

Onboarding screen with example prompts for AI chat interfaces. Features a branded header, 2-column grid of clickable prompt cards with icons, and keyboard shortcut hint.

Preview

Default welcome screen with example prompts

Welcome to Horizon AI

I'm here to help you plan, prioritize, and achieve your goals. Start with a prompt below or type your own question.

Press/for commands or just start typing

Custom Content

Custom heading, description, and prompts

Welcome to CodeAssist

Your AI pair programming companion. Pick a task or describe what you need.

Press/for commands or just start typing

Without Keyboard Hint

Hide the keyboard shortcut footer

Welcome to Horizon AI

I'm here to help you plan, prioritize, and achieve your goals. Start with a prompt below or type your own question.

Props

AIWelcomeState component API reference

PropTypeDefaultDescription
headingstring'Welcome to Horizon AI'Main heading text
descriptionstring'I\'m here to help you plan, prioritize...'Subheading/description text
promptsExamplePrompt[](default prompts)Array of example prompts to display
onPromptSelect(prompt: string) => voidCallback when a prompt card is clicked
showKeyboardHintbooleantrueShow the keyboard shortcut hint footer
keyboardHintTextstring'for commands or just start typing'Text after the "/" key hint
classNamestringAdditional CSS classes for the container

ExamplePrompt Type

PropTypeDefaultDescription
icon*LucideIconIcon component to display
title*stringShort title for the prompt card
prompt*stringFull prompt text (returned on click)
colorColorVariantColor theme for the icon (default: indigo)

ColorVariant

"indigo" |"teal" |"amber" |"violet" |"rose" |"emerald"

Usage

Import and implementation example

import { AIWelcomeState } from '@/blocks/ai-conversation/ai-welcome-state'
import { ListTodo, Calendar, Target, Zap } from 'lucide-react'

export default function Example() {
  const prompts = [
    {
      icon: ListTodo,
      title: 'Plan my day',
      prompt: 'Help me prioritize my tasks for today',
      color: 'indigo',
    },
    {
      icon: Calendar,
      title: 'Schedule focus time',
      prompt: 'Block 2 hours of deep work this week',
      color: 'teal',
    },
    {
      icon: Target,
      title: 'Set weekly goals',
      prompt: 'Break down my Q1 objectives into milestones',
      color: 'amber',
    },
    {
      icon: Zap,
      title: 'Boost productivity',
      prompt: 'Analyze my task patterns and suggest improvements',
      color: 'violet',
    },
  ]

  const handlePromptSelect = (prompt: string) => {
    // Insert prompt into chat input
    setInputValue(prompt)
    inputRef.current?.focus()
  }

  return (
    <AIWelcomeState
      heading="Welcome to Horizon AI"
      description="I'm here to help you plan, prioritize, and achieve your goals."
      prompts={prompts}
      onPromptSelect={handlePromptSelect}
      keyboardHintText="for commands or just start typing"
    />
  )
}
This block is self-contained (no UI component dependencies)

Features

Built-in functionality

  • Branded header: Gradient sparkles icon with customizable heading and description
  • Prompt card grid: 2-column grid of clickable example prompts
  • Color-coded icons: Six color variants (indigo, teal, amber, violet, rose, emerald)
  • Hover animations: Border highlight and arrow slide on hover
  • Keyboard hint: Configurable "/" shortcut hint footer
  • Line clamping: Prompt descriptions truncated to 2 lines
  • Click callback: Returns full prompt text for input insertion
  • Centered layout: Vertically centered with max-width container
  • Dark mode: Full dark mode support with proper gradients

Accessibility

Accessibility considerations

ARIA Attributes

Prompt cards are native button elementsIcons are decorative and accompany visible textKeyboard hint uses semantic kbd element

Keyboard Navigation

KeyAction
TabNavigate between prompt cards
Enter / SpaceSelect the focused prompt card

Notes

  • Cards have visible focus states from default button styling
  • Prompt titles provide clear labels for each action
  • Description text provides additional context
  • Consider adding aria-label combining title and prompt for screen readers
  • Arrow icon indicates the card is actionable