import type { Plugin, RevealUIField } from '../types/index.js'; export interface BaseFormField extends RevealUIField { name: string; label?: string; width?: number | string; defaultValue?: string | number | boolean | null; required?: boolean; placeholder?: string; } export interface TextField extends BaseFormField { type: 'text'; maxLength?: number; minLength?: number; } export interface EmailField extends BaseFormField { type: 'email'; } export interface TextareaField extends BaseFormField { type: 'textarea'; maxLength?: number; minLength?: number; } export interface NumberField extends BaseFormField { type: 'number'; max?: number; min?: number; } export interface SelectField extends BaseFormField { type: 'select'; options: Array<{ label: string; value: string; }>; } export interface CheckboxField extends Omit { type: 'checkbox'; defaultValue?: boolean; } export interface CountryField extends BaseFormField { type: 'text'; } export interface StateField extends BaseFormField { type: 'text'; } export interface FormFieldBlock { name: string; label?: string; type: string; blockType: string; blockName?: string; placeholder?: string; required?: boolean; defaultValue?: unknown; options?: Array<{ label: string; value: string; }>; width?: number; id?: string; } export interface Form { id: string; title: string; fields: FormFieldBlock[]; confirmationMessage?: unknown; confirmationType?: 'message' | 'redirect'; submitButtonLabel?: string; redirect?: { url?: string; }; emails?: Array<{ emailTo?: string; emailFrom?: string; subject: string; message?: unknown; cc?: string; bcc?: string; replyTo?: string; }>; } export interface FormSubmission { id: string; form: string; submissionData: Record; submittedAt: string; } export interface FormBuilderPluginConfig { fields?: { payment?: boolean; }; formOverrides?: { fields?: (args: { defaultFields: RevealUIField[]; }) => RevealUIField[]; slug?: string; admin?: { useAsTitle?: string; defaultColumns?: string[]; components?: Record; }; }; formSubmissionOverrides?: { fields?: (args: { defaultFields: RevealUIField[]; }) => RevealUIField[]; slug?: string; admin?: { useAsTitle?: string; defaultColumns?: string[]; components?: Record; }; }; } export declare function formBuilderPlugin(config?: FormBuilderPluginConfig): Plugin; //# sourceMappingURL=form-builder.d.ts.map