import { i as ActorRefFrom } from "./spawn-D9jgw9pW.js"; import { t as Manager } from "./Manager-CQQ99QOI.js"; import "./Actor-iTq7YY48.js"; //#region src/modules/signature/types.d.ts /** * Configuration options for Signature. */ type SignatureConfig = { type?: string; /** * Optional header title for both steps. When omitted, the UI uses per-step defaults * (“Draw your signature”). */ title?: string; /** * Optional subtitle for both steps. When omitted, the UI uses the default finger/mouse copy. * Backend field name: `subTitle` (capital T). */ subTitle?: string; /** * When true, uploads base64 via Omni `addSignature` v2 JSON body. * When false (default), uploads JPEG bytes (`image/jpeg`). */ sendBase64?: boolean; /** * Optional fill behind the drawing area (e.g. hex, `rgb()`, or a CSS variable). * When omitted, the default themed surface from the signature UI is used. */ canvasBackgroundColor?: string; /** * Optional maximum stroke width for the pen, in CSS pixels (passed to `SignaturePad` as `maxWidth`). * When omitted, the pad uses its default sizing. */ penStrokeWidth?: number; /** * Optional ink color (e.g. hex, `rgb()`, or `var(--token)` resolved where supported). * When omitted, the default signature pen color from theme tokens is used. */ penColor?: string; /** * Optional border color for the drawing area (same format as `penColor`). * When omitted, the default input border token from the signature UI is used. */ canvasBorderColor?: string; }; /** Response body from Omni add-signature endpoints. */ type AddSignatureResponse = { image: string | Blob; type: string; }; //#endregion //#region src/modules/signature/signatureStateMachine.d.ts declare const signatureMachine: any; type SignatureMachine = typeof signatureMachine; //#endregion //#region src/modules/signature/signatureActor.d.ts type CreateSignatureActorOptions = { config: SignatureConfig; }; type SignatureActor = ActorRefFrom; //#endregion //#region src/modules/signature/signatureManager.d.ts type SignatureIdleState = { status: 'idle'; }; type SignatureCaptureState = { status: 'capture'; title: string | undefined; subtitle: string | undefined; canContinue: boolean; }; type SignatureSubmittingState = { status: 'submitting'; }; type SignatureFinishedState = { status: 'finished'; result: AddSignatureResponse | undefined; }; type SignatureErrorState = { status: 'error'; error: string; }; type SignatureSuccessState = { status: 'success'; }; type SignatureState = SignatureIdleState | SignatureCaptureState | SignatureSubmittingState | SignatureFinishedState | SignatureErrorState | SignatureSuccessState; declare function createSignatureManager(options: CreateSignatureActorOptions): Manager & { load(): void; setSignatureValid(isValid: boolean): void; /** Exported image (base64 string or JPEG Blob) from the canvas; starts the upload actor. */ submit(image: string | Blob): void; }; /** * Creates a signature manager from a pre-built actor. * Use this when overriding the machine via `.provide()` for custom backends * or isolated UI rendering. */ declare function createSignatureManagerFromActor(actor: SignatureActor): Manager & { load(): void; setSignatureValid(isValid: boolean): void; /** Exported image (base64 string or JPEG Blob) from the canvas; starts the upload actor. */ submit(image: string | Blob): void; }; type SignatureManager = ReturnType; //#endregion export { createSignatureManagerFromActor as a, SignatureConfig as c, createSignatureManager as i, SignatureManager as n, SignatureActor as o, SignatureState as r, signatureMachine as s, SignatureCaptureState as t };