AI Native UI Kit
Components

Private Composer

A dark, compact prompt composer with a private-mode toggle.

Installation

npx shadcn@latest add https://ai-native-ui.com/r/private-composer.json

Usage

import { PrivateComposer } from "@/components/ui/private-composer";

<PrivateComposer
  onSend={(text, isPrivate) => ask(text, { isPrivate })}
  onPrivateToggle={(on) => setPrivate(on)}
/>;

Props

PropTypeDescription
placeholderstringInput placeholder.
modelstringModel label shown in the toolbar.
sourcestringSource label shown in the toolbar.
defaultPrivatebooleanInitial private-mode state.
onSend(text: string, isPrivate: boolean) => voidFires on submit.
onPrivateToggle(isPrivate: boolean) => voidFires when private mode toggles.

On this page