# Waitlist form

Collect early-access requests with email, optional role and use-case fields.

Access: pro. Category: Forms. Kind: composite.

## When to use

- Use it when a page needs collect early-access requests with email, optional role and use-case fields.
- Choose it as the cta region when composing a page from independently reusable TidalUI sections.

## Alternatives

- Choose form-field instead when a labeled email field with validation and help text is the actual interface need, rather than waitlist form.

## Setup for agents

Use React 19 and TypeScript. Initialize shadcn for your framework, then merge this exact entry into components.json:

```json
{
  "registries": {
    "@tidal-pro": {
      "url": "https://tidalui.com/r/pro/{name}.json",
      "headers": {
        "Authorization": "Bearer ${TIDALUI_TOKEN}"
      }
    }
  }
}
```

The namespace must be named **@tidal-pro** because transitive Pro dependencies use that namespace. Obtain an agent key from your active Pro account at https://tidalui.com/account. Keep TIDALUI_TOKEN in your local environment, never in components.json, client code, Git or logs.

```sh
export TIDALUI_TOKEN='your-private-agent-key'
npx shadcn@latest add @tidal-pro/waitlist-form
npx shadcn@latest add https://tidalui.com/r/tidal-button.json
```

Free command: `npx shadcn@latest add https://tidalui.com/r/<name>.json`.
Pro command: `npx shadcn@latest add @tidal-pro/<name>`.

Import the base stylesheet and every stylesheet listed on the installed item's metadata. For example:

```tsx
import "./components/ui/tidal.css";
import "./components/ui/hero-section.css";
// Place installed components inside this wrapper:
<div className="tidal-scope" data-theme="dark">...</div>
```

Omit data-theme for the default light theme. Put the attribute on the same tidal-scope element for dark mode. Every component installs the shared free tidal-base dependency. After upgrading, run `npx shadcn@latest add https://tidalui.com/r/tidal-base.json --overwrite` to receive current tokens. Review local modifications before overwriting.

Vite: Use React + TypeScript. Map @/* to ./src/* in paths and Vite resolve.alias. Import tidal.css and each component stylesheet in your application entry.

Next.js 15 App Router: Next.js App Router: import tidal.css and component CSS in app/layout.tsx. Interactive examples belong in a client component with "use client". Map @/* to ./* or ./src/* to match your project.

TypeScript 6: use paths without baseUrl:

```json
{
  "compilerOptions": {
    "paths": {
      "@/*": [
        "./src/*"
      ]
    }
  }
}
```

Pro registry requests are server/CLI-only. Use the same-origin account interface in a browser; cross-origin Authorization preflights are intentionally unsupported.


## Install Waitlist form

```sh
npx shadcn@latest add @tidal-pro/waitlist-form
```

Stylesheets: `components/ui/tidal.css`, `components/ui/waitlist-form.css`.

## Minimal example

```tsx
import"./components/ui/tidal.css";
import"./components/ui/waitlist-form.css";
import{TidalWaitlistForm}from"./components/ui/waitlist-form";
export default()=><div className="tidal-scope"><TidalWaitlistForm title={"Demo"}/></div>;
```

## Structured props

- `TidalWaitlistForm.title: ReactNode`: Required title value accepted by this exported component.
- `TidalWaitlistForm.description?: ReactNode`: Optional description value accepted by this exported component.
- `TidalWaitlistForm.disabled?: boolean | undefined` (default false): Optional disabled value accepted by this exported component.
- `TidalWaitlistForm.emailProps?: EmailProps | undefined` (default {}): Optional email props value accepted by this exported component.
- `TidalWaitlistForm.emailRef?: Ref<HTMLInputElement> | undefined`: Optional email ref value accepted by this exported component.
- `TidalWaitlistForm.error?: ReactNode`: Optional error value accepted by this exported component.
- `TidalWaitlistForm.footer?: ReactNode`: Optional footer value accepted by this exported component.
- `TidalWaitlistForm.headingLevel?: "h2" | "h3" | "h4" | "h5" | "h6" | undefined` (default "h2"): Optional heading level value accepted by this exported component.
- `TidalWaitlistForm.labels?: Partial<{ email: string; role: string; chooseRole: string; notes: string; submit: string; pending: string; success: string; edit: string; invalid: string; }> | undefined` (default {}): Optional labels value accepted by this exported component.
- `TidalWaitlistForm.notesProps?: NotesProps | undefined` (default {}): Optional notes props value accepted by this exported component.
- `TidalWaitlistForm.notesRef?: Ref<HTMLTextAreaElement> | undefined`: Optional notes ref value accepted by this exported component.
- `TidalWaitlistForm.onEdit?: (() => void) | undefined`: Callback invoked when the edit interaction is proposed.
- `TidalWaitlistForm.onRoleChange?: ((role: string) => void) | undefined`: Callback invoked when the role change interaction is proposed.
- `TidalWaitlistForm.onSubmit?: ((event: FormEvent<HTMLFormElement>) => void) | undefined`: Callback invoked when the submit interaction is proposed.
- `TidalWaitlistForm.role?: string | undefined` (default ""): Optional role value accepted by this exported component.
- `TidalWaitlistForm.roleRequired?: boolean | undefined` (default false): Optional role required value accepted by this exported component.
- `TidalWaitlistForm.roles?: ReadonlyArray<TidalWaitlistRole> | undefined` (default []): Optional roles value accepted by this exported component.
- `TidalWaitlistForm.showNotes?: boolean | undefined` (default false): Optional show notes value accepted by this exported component.
- `TidalWaitlistForm.status?: "error" | "pending" | "success" | "idle" | undefined` (default "idle"): Optional status value accepted by this exported component.
- `TidalWaitlistForm.submitProps?: SubmitProps | undefined` (default {}): Optional submit props value accepted by this exported component.
- `TidalWaitlistForm.success?: ReactNode`: Optional success value accepted by this exported component.

## Complete usage example

[Source](https://tidalui.com/examples/waitlist-form.tsx) | [Manifest](https://tidalui.com/examples/waitlist-form.json). Install the listed additional dependencies. Consumer fixture: TypeScript pass; Vite pass. This fixture check is distinct from the actual shadcn install receipt.

```tsx
import "./components/ui/tidal.css";

import { useState } from "react";

import { TidalWaitlistForm } from "./components/ui/waitlist-form";

import "./components/ui/waitlist-form.css";

import "./components/ui/form-field.css";

import "./components/ui/textarea.css";

import "./components/ui/native-select.css";



export function WaitlistFormDemo() {
  const [role, setRole] = useState(""),
    [status, setStatus] = useState<"idle" | "success">("idle");
  return (
    <TidalWaitlistForm
      title="Get early access"
      description="Join the early-access list. Share your role and what you plan to build."
      roles={[
        { id: "founder", label: "Founder" },
        { id: "designer", label: "Designer" },
        { id: "developer", label: "Developer" },
      ]}
      role={role}
      onRoleChange={setRole}
      showNotes
      status={status}
      success="Your sample signup is complete. Nothing was sent or saved."
      onEdit={() => setStatus("idle")}
      onSubmit={(e) => {
        e.preventDefault();
        setStatus("success");
      }}
      emailProps={{ placeholder: "you@company.com" }}
      notesProps={{
        placeholder: "A customer portal, an internal tool…",
        maxLength: 240,
      }}
      footer="Local preview. No signup or email is sent."
    />
  );
}

export default function AgentExample() {
  return (
    <div className="tidal-scope" data-theme="light" dir="ltr">
      <WaitlistFormDemo />
    </div>
  );
}

```

## Gotchas

- The host application owns data, validation, persistence, navigation, and service side effects described by this API.

## Theme and accessibility

{"tokens":["--t-accent","--t-border","--t-border-strong","--t-canvas","--t-danger","--t-display","--t-ease-out","--t-ease-spring","--t-faint","--t-font","--t-ink","--t-line","--t-muted","--t-primary","--t-primary-contrast","--t-radius-card","--t-radius-control","--t-radius-overlay","--t-radius-panel","--t-ring","--t-shadow-lg","--t-shadow-soft","--t-soft","--t-subtle","--t-surface","--t-wash"],"darkMode":true}

{"keyboard":["Tab and Shift+Tab follow the component's native focus order.","Arrow-key behavior follows the exported composite-control implementation."],"aria":"The component wires labels and relationships from consumer-provided visible text or ARIA props; preserve those labels in production.","notes":"Verify focus visibility, text alternatives, contrast, and reduced motion in the final composition."}

Native early-access form composed from TidalField, Native select, Textarea and Button. Required email validation is native; role options are unique nonblank IDs/labels with a controlled choice and optional required flag. Optional use-case field supports native value/defaultValue, selection and FormData. Native form action/method or onSubmit stays consumer-owned. Idle, pending, error and success states, translated labels, title/description/footer slots, heading levels, direct form/email/notes refs and native field/submit props are supported. Source protects owned type, form, label and disabled channels at runtime. Success keeps fields mounted, hidden and disabled so uncontrolled values return on Edit; removed or hidden owned focus recovers to the persistent form only from source/body. All submitted values remain consumer-owned. No signup, email, network request, position assignment, storage or analytics occurs. Demo completion explicitly stays in the preview. A required role must have at least one enabled option; impossible role configurations fail visibly. Email and notes prop bags strip contradictory aria-disabled and untyped error channels.
