A shadcn-style signature pad component built with Ark UI primitives.

Signature

Installation

npx shadcn@latest add @ark-cn/signature-pad

Usage

import * as SignaturePad from "@/components/ui/signature-pad"

Read exported parts in src/components/ui/signature-pad.tsx and compose the primitive according to the Ark UI pattern for this component.

Examples

Basic

Signature

Image Preview

Signature
Image preview

Draw to update preview.

Context

Empty: true · Paths: 0

Signature

Root Provider

Paths: 0
Signature

API reference

This component mirrors the upstream Ark UI primitive. All props and DOM behavior are defined by Ark unless you see an ark-cn-only row below.

SignaturePad

PropTypeDescription
width?string | numberSets --signature-pad-width (default 20rem).
height?string | numberSets --signature-pad-height (default 10rem).

SignaturePadClearTrigger

PropTypeDescription
variant?ButtonVariantButton style for the clear control (default ghost).
size?ButtonSizeButton size for the clear control (default icon-sm).

SignaturePadField

PropTypeDescription
hideGuide?booleanOmits the guide line when true.
clearTriggerProps?ClearTriggerPropsExtra props for the clear trigger.

See the ARK UI documentation for the full API.