UNPKG

@docuseal/react

Version:

DocuSeal React components to integrate documents signing process into apps. ✍️

84 lines (83 loc) 2.85 kB
import React from 'react'; export type DocusealFormField = { name: string; title?: string; description?: string; type?: string; position?: number; required?: boolean; readonly?: boolean; validation?: { pattern?: string; message?: string; }; preferences?: { font_size?: number; font_type?: "bold" | "italic" | "bold_italic"; mask?: boolean | number; font?: "Times" | "Helvetica" | "Courier"; color?: "black" | "white" | "blue"; align?: "left" | "center" | "right"; valign?: "top" | "center" | "bottom"; format?: string; price?: number; currency?: "USD" | "EUR" | "GBP" | "CAD" | "AUD"; }; }; export type DocusealFormProps = { src?: string; token?: string; host?: string; role?: string; submitter?: string; expand?: boolean; minimize?: boolean; orderAsOnPage?: boolean; preview?: boolean; email?: string; name?: string; applicationKey?: string; externalId?: string; backgroundColor?: string; logo?: string; language?: string; completedMessage?: { title?: string; body?: string; }; completedRedirectUrl?: string; completedButton?: { title: string; url: string; }; goToLast?: boolean; skipFields?: boolean; autoscrollFields?: boolean; withTitle?: boolean; withDecline?: boolean; withFieldNames?: boolean; withFieldPlaceholder?: boolean; sendCopyEmail?: boolean; withDownloadButton?: boolean; withSendCopyButton?: boolean; withCompleteButton?: boolean; allowToResubmit?: boolean; allowTypedSignature?: boolean; signature?: string; rememberSignature?: boolean; reuseSignature?: boolean; values?: object; metadata?: object; i18n?: object; fields?: DocusealFormField[]; readonlyFields?: string[]; onComplete?: (detail: any) => void; onInit?: (detail: any) => void; onDecline?: (detail: any) => void; onLoad?: (detail: any) => void; className?: string; customCss?: string; style?: React.CSSProperties; }; declare const DocusealForm: ({ src, token, host, role, submitter, preview, expand, minimize, orderAsOnPage, email, name, backgroundColor, sendCopyEmail, applicationKey, externalId, logo, language, completedRedirectUrl, completedButton, completedMessage, goToLast, skipFields, autoscrollFields, withTitle, withDecline, withFieldNames, withFieldPlaceholder, withDownloadButton, allowToResubmit, allowTypedSignature, signature, rememberSignature, reuseSignature, withSendCopyButton, withCompleteButton, values, metadata, i18n, fields, readonlyFields, onComplete, onInit, onDecline, onLoad, className, customCss, style }: DocusealFormProps) => JSX.Element; export default DocusealForm;