Prompt Dialog

A customizable dialog for user input with validation.

v0

Installation

Full Setup guide

Install the component automatically via Shadcn CLI.

npx shadcn@latest add https://www.grettech.com/api/registry/prompt-dialog

Other Examples

Destructive Action

v0

Props

PropTypeDefaultDescription
className
string-Optional CSS classes to apply.
title
stringEnter ValueThe dialog title.
description
stringPlease provide the requested information below.The dialog description.
placeholder
stringEnter value...Input placeholder text.
submitText
stringSubmitText for the submit button.
onConfirm
(value: string) => void | Promise<void>() => {}Callback fired when user submits
children
ReactNode<Button variant='outline'>Open Prompt</Button>The trigger button/element
...props
React.HTMLAttributes<HTMLDivElement>-Accepts all standard HTML attributes (id, style, etc).