ConsentSigner
ComplexClinical
<co-consent-signer>ConsentSigner shows a consent document in a scroll box with agree, signature and guardian fields.
import { ConsentSigner } from 'health-components';
Examples
Guardian
Signed
Compact
Usage
<ConsentSigner title="Telehealth Consent" version="v3, 01/2026" body={text} signer="Henna West" />
When to use
- Consent to treat, telehealth consent, HIPAA notice, financial policy.
When not to use
- Unsigned information pages.
Variants and states
| Variant | What it is |
|---|---|
| patient | Patient signs. |
| guardian | Relationship field. |
| signed | Pre-signed state. |
Accessibility
- Document region is focusable for keyboard scroll.
Do and don't
- Do: Version and date on every consent.
- Don't: Sign without showing the text.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
title * | string | — | Consent title ("Consent for Telehealth Services"); also names the document region. Required |
version * | string | — | Version and effective date ("Version 3 . effective 01/01/2026"). Required |
body * | string | — | Consent text; blank lines separate paragraphs. Required |
signer * | string | — | Name of the person signing. Required |
guardian | string | none | Relationship to the patient; shows the guardian field when set |
agreed | boolean | false | Agree box ticked initially (uncontrolled) |
agreedValue | boolean | undefined (uncontrolled) | Agree box state (controlled) |
onAgreedChange | (agreed: boolean) => void | none | Called when the agree box changes |
signed | boolean | false | Signature present initially (uncontrolled) |
onSignedChange | (signed: boolean) => void | none | Called when the signature is added or cleared |
agreeLabel | string | "I have read and agree to this consent." | Agree box label |
signerLabel | string | "Patient Signature" | Signature pad label |
compact | boolean | false | Shorter signature pad |
onSignConsent | (signature: ConsentSignature) => void | none | Called by Sign Consent (enabled once agreed and signed) |
onDecline | () => void | none | Called by Decline |
Also accepts native attributes, including defaultChecked, defaultValue, autoFocus, plus className and event handlers on the root element.
Angular, Vue and HTML
Register the elements once (Angular guide), then use <co-consent-signer>. Attributes take strings; arrays and objects are set as properties (Angular [prop], Vue :prop) or as JSON attributes. Callbacks are DOM events with the value in event.detail.
Angular template
<co-consent-signer title="…" version="…" [defaultValue]="defaultValue" (co-agreed-change)="onAgreedChange($event.detail)"></co-consent-signer>
| Kind | Name | Description |
|---|---|---|
| attribute | title | Consent title ("Consent for Telehealth Services"); also names the document region. Required |
| attribute | version | Version and effective date ("Version 3 . effective 01/01/2026"). Required |
| attribute | body | Consent text; blank lines separate paragraphs. Required |
| attribute | signer | Name of the person signing. Required |
| attribute | guardian | Relationship to the patient; shows the guardian field when set; default none |
| attribute | agreed | Agree box ticked initially (uncontrolled); default false |
| attribute | agreed-value / agreedValue | Agree box state (controlled); default undefined (uncontrolled) |
| attribute | signed | Signature present initially (uncontrolled); default false |
| attribute | agree-label / agreeLabel | Agree box label; default "I have read and agree to this consent." |
| attribute | signer-label / signerLabel | Signature pad label; default "Patient Signature" |
| attribute | compact | Shorter signature pad; default false |
| attribute | default-checked / defaultChecked | |
| property / JSON attribute | default-value / defaultValue | |
| attribute | auto-focus / autoFocus | |
| event | co-agreed-change | Called when the agree box changes; default none (React: onAgreedChange) |
| event | co-signed-change | Called when the signature is added or cleared; default none (React: onSignedChange) |
| event | co-sign-consent | Called by Sign Consent (enabled once agreed and signed); default none (React: onSignConsent) |
| event | co-decline | Called by Decline; default none (React: onDecline) |