Skip to content
Forms

Signature Pad

Canvas signature input with smoothed strokes, undo/clear, and data-URL output.

Import

tsx
import { SignaturePad } from "@cronus-ui/ui";
bash
npx cronus-ui add signature-pad

Examples

.cronus

The same component declared in Cronus. Emitted at build time from the audit fixtures — the kernel renders it as HTML with no React.

PortedParity: MatchGeometry 1/1Pixel diff 0 pxLogic 1/1Parity scoreboard
default.cronus
app "audit-fixtures" {
  port 5176
}

style {
  preset aurora
  theme dark
}

component SignaturePadDefault layout:inline style:signature-pad {
  aria-label:"Signature pad"
  label "Signature pad"
}

page "/audit/signature-pad/default" type:custom {
  use SignaturePadDefault
}

API Reference

Generated from the component's exported types.

SignaturePadProps

Extends Omit<HTMLAttributes<HTMLDivElement>, "onChange">

Skip SignaturePadProps props table
PropTypeDefaultDescription
onChange
(dataUrl: string | null) => void—Fired when a stroke is committed, undone, or the pad is cleared. Receives a PNG data URL of the drawing, or `null` once the pad is empty again.
disabled
booleanfalseFreezes the pad: pointer input is ignored and the overlay actions disable.
className
string—Additional class names merged onto the root.
children
ReactNode—Contents of the component.
id
string—DOM id of the root element.