@stesura/esign-react
The editor UI for @stesura/esign: the field node view, the Insert tab’s
Signature group and signature-block snippets.
UI extension
createEsignUIExtension
E-signature fields in the editor: the field view and the Insert tab’s
Signature group. The schema needs withEsign (@stesura/esign). Call once
at module scope.
Snippets
insertEsignSnippet
Inserts a signature-block snippet at the cursor. The labels are ordinary
text in the editor’s locale, the author edits them freely. single uses
signer; twoParties its default party roles.
| Name | Type | Default |
|---|---|---|
snippet | EsignSnippet | |
t | TranslationKeys | |
signer | string |
EsignSnippet
type EsignSnippet = "single" | "twoParties" | "witness";A signature-block snippet: one signer’s block, two parties side by side, or a witness’s signature and name.
Custom toolbars and views
EsignGroup
The Insert tab’s Signature group: insert a field for the current signer, pick or rename signers, insert signature-block snippets. With a field selected, the signer picker reassigns it and the field menu edits it.
| Name | Type | Default |
|---|---|---|
props | {} |
esignProbes
Enabled-state probe for inserting a field, for a custom toolbar.
| Name | Type | Default |
|---|---|---|
insert | TbProbe |
esignSelectors
Toolbar selectors for the Signature group: the document’s signer roles and the selected field.
| Name | Type | Default |
|---|---|---|
roles | TbSelector<string[]> | |
selected | TbSelector<EsignFieldAttrs | null> |
EsignFieldView
An e-signature field: a dashed box tinted by its signer, with its label and
a signer badge, resizable per its kind. In print only the style border and
the anchor token render; data-pdf-field (from the spec) is what the PDF
export measures.
| Name | Type | Default |
|---|---|---|
props | Omit<NodeViewComponentProps, "ref"> & RefAttributes<HTMLSpanElement> |