Signer page kit
Field Box
A field on a document page in four states: waiting, next to do, done, and filled in for you.
- In the signer page, not yet in the package
- AGPL-3.0-only
- Client only · no backend
Initials are a design preview: the API has no initials field yet (proposal in ADR 0019).
Theme
The CSS variables this sets
:root {
--signing-accent: #3157e8;
--sig-accent: #3157e8;
--sig-accent-soft: color-mix(in oklab, #3157e8 14%, white);
--sig-radius: 8px;
--radius-control: 8px;
--radius-panel: 12px;
--font-sans: var(--font-inter), ui-sans-serif, system-ui, sans-serif;
}In the signer page kit, set the accent with accentProps(accent) on the element around the surface; it sets data-signing-accent and --signing-accent. The secure elements take the same values as a checked appearance object instead.
Todo: waiting for you
Click to sign
Initial
Job title
2026-12-04
tsx
import { FieldBox, PenIcon } from "@/components/signing";
export function Example() {
return (
<div style={{ position: "relative", width: 420, height: 190 }}>
<FieldBox kind="signature" state="todo" required box={{ x: 0.07, y: 0.4, width: 0.5, height: 0.26 }}>
<PenIcon size={12} /> Click to sign
</FieldBox>
<FieldBox kind="text" state="todo" required label="Job title" box={{ x: 0.64, y: 0.4, width: 0.29, height: 0.13 }} />
</div>
);
}
Active: the next thing to do
Add signature Click to sign
Initial
Job title
2026-12-04
tsx
import { FieldBox, PenIcon } from "@/components/signing";
export function Example() {
return (
<div style={{ position: "relative", width: 420, height: 190 }}>
<FieldBox kind="signature" state="active" required box={{ x: 0.07, y: 0.4, width: 0.5, height: 0.26 }}>
<PenIcon size={12} /> Click to sign
</FieldBox>
<FieldBox kind="text" state="todo" required label="Job title" box={{ x: 0.64, y: 0.4, width: 0.29, height: 0.13 }} />
</div>
);
}
Done
Ada Example
AE
CTO
2026-12-04
tsx
import { FieldBox, PenIcon } from "@/components/signing";
export function Example() {
return (
<div style={{ position: "relative", width: 420, height: 190 }}>
<FieldBox kind="signature" state="done" required box={{ x: 0.07, y: 0.4, width: 0.5, height: 0.26 }}>
<PenIcon size={12} /> Click to sign
</FieldBox>
<FieldBox kind="text" state="done" required label="Job title" box={{ x: 0.64, y: 0.4, width: 0.29, height: 0.13 }} />
</div>
);
}
Locked: filled in for you, or someone else's
Click to sign
Initial
Job title
2026-12-04
tsx
import { FieldBox, PenIcon } from "@/components/signing";
export function Example() {
return (
<div style={{ position: "relative", width: 420, height: 190 }}>
<FieldBox kind="signature" state="locked" required box={{ x: 0.07, y: 0.4, width: 0.5, height: 0.26 }}>
<PenIcon size={12} /> Click to sign
</FieldBox>
<FieldBox kind="text" state="locked" required label="Job title" box={{ x: 0.64, y: 0.4, width: 0.29, height: 0.13 }} />
</div>
);
}
Installation
npx shadcn@latest add …
Not published yet
Not in the registry (packages/ui/registry.json) yet.
Props
className and children are left out: every component that takes them passes them on.
FieldBox
| Name | Type | Default | Description |
|---|---|---|---|
| kind | "signature" | "initials" | "text" | "date" | "checkbox" | What the field holds. | |
| state | "todo" | "active" | "done" | "locked" | Waiting, next to do, done, or filled in for you. | |
| box | { x, y, width, height } | Position on the page, each 0 to 1. | |
| label | string | null | The sender's label, used in the tag and for screen readers. | |
| required | boolean | false | Required, as data-required. Say it in the control's label too. |
| quietTag | boolean | false | Outlined tag, when a bottom bar is the primary action. |
| tag | "above" | "side" | "below" | "above" | Where the active tag sits; beside or below when another field is just above. |
| onActivate | () => void | Called when the box itself is clicked or tapped. | |
| id | string | Target id for the navigator and scrollToField. |
Accessibility
- State is never only a colour: dashed, solid with a tag, a check badge, or grey.
- Required is data-required on the box; say it in the control's label too.