PromptDialog

Prompt modal for user text input. Animated with Framer Motion, supports Enter to submit and Escape to cancel.

API Reference

PropTypeDefaultDescription
isOpen*boolean—Whether the dialog is open
title*string—Dialog title
placeholderstring—Input placeholder
defaultValuestring—Default input value
confirmTextstring"OK"Confirm button text
cancelTextstring"Cancel"Cancel button text
onConfirm*(value: string) => void—Called with input value on confirm
onCancel*() => void—Called on cancel

Source Code