@alfadocs/ui-kit-debug 1.132.0 → 1.134.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_chunks/{agenda-card-B8hV3dZV.js → agenda-card-B9wgX_Ed.js} +2 -2
- package/dist/_chunks/{agenda-card-B8hV3dZV.js.map → agenda-card-B9wgX_Ed.js.map} +1 -1
- package/dist/_chunks/{agenda-tray-Bu46s3dI.js → agenda-tray-CGcS_qoM.js} +2 -2
- package/dist/_chunks/{agenda-tray-Bu46s3dI.js.map → agenda-tray-CGcS_qoM.js.map} +1 -1
- package/dist/_chunks/appointment-card-DG3m9yN-.js +504 -0
- package/dist/_chunks/appointment-card-DG3m9yN-.js.map +1 -0
- package/dist/_chunks/{appointment-peek-DZa6xyUb.js → appointment-peek-BK0tDs4C.js} +2 -2
- package/dist/_chunks/{appointment-peek-DZa6xyUb.js.map → appointment-peek-BK0tDs4C.js.map} +1 -1
- package/dist/_chunks/{appointment-timeline-DQePqpyH.js → appointment-timeline-BiI2riRZ.js} +2 -2
- package/dist/_chunks/{appointment-timeline-DQePqpyH.js.map → appointment-timeline-BiI2riRZ.js.map} +1 -1
- package/dist/_chunks/appointment-tray-ClJCtYQj.js +200 -0
- package/dist/_chunks/appointment-tray-ClJCtYQj.js.map +1 -0
- package/dist/_chunks/{appointment-workflow-status-DMjuIK90.js → appointment-workflow-status-S-lx81Yz.js} +2 -2
- package/dist/_chunks/{appointment-workflow-status-DMjuIK90.js.map → appointment-workflow-status-S-lx81Yz.js.map} +1 -1
- package/dist/_chunks/ban-CiSCCcOE.js +15 -0
- package/dist/_chunks/ban-CiSCCcOE.js.map +1 -0
- package/dist/_chunks/{calendar-BIoOeBTT.js → calendar-CyLtLBNP.js} +2 -2
- package/dist/_chunks/{calendar-BIoOeBTT.js.map → calendar-CyLtLBNP.js.map} +1 -1
- package/dist/_chunks/calendar-appointment-editor-dialog-BSkIYGlW.js +13773 -0
- package/dist/_chunks/calendar-appointment-editor-dialog-BSkIYGlW.js.map +1 -0
- package/dist/_chunks/{calendar-event-card-BNEzkjm-.js → calendar-event-card-BJifpYZQ.js} +7 -6
- package/dist/_chunks/{calendar-event-card-BNEzkjm-.js.map → calendar-event-card-BJifpYZQ.js.map} +1 -1
- package/dist/_chunks/{care-plan-card-DKScH9Ss.js → care-plan-card-CjHq6PLo.js} +6 -6
- package/dist/_chunks/{care-plan-card-DKScH9Ss.js.map → care-plan-card-CjHq6PLo.js.map} +1 -1
- package/dist/_chunks/{care-plan-entry-card-AG1y3nyW.js → care-plan-entry-card-DY1toF6E.js} +2 -2
- package/dist/_chunks/{care-plan-entry-card-AG1y3nyW.js.map → care-plan-entry-card-DY1toF6E.js.map} +1 -1
- package/dist/_chunks/{care-plan-header-Dx5OMkc9.js → care-plan-header-CeFXUDnL.js} +6 -6
- package/dist/_chunks/{care-plan-header-Dx5OMkc9.js.map → care-plan-header-CeFXUDnL.js.map} +1 -1
- package/dist/_chunks/check-in-documents-CEVcgcYZ.js +136 -0
- package/dist/_chunks/check-in-documents-CEVcgcYZ.js.map +1 -0
- package/dist/_chunks/{clinical-note-card-pPaeWWnu.js → clinical-note-card-D--IwbZa.js} +2 -2
- package/dist/_chunks/{clinical-note-card-pPaeWWnu.js.map → clinical-note-card-D--IwbZa.js.map} +1 -1
- package/dist/_chunks/document-preview-DLVIrOYV.js +385 -0
- package/dist/_chunks/document-preview-DLVIrOYV.js.map +1 -0
- package/dist/_chunks/{entity-card-fpm-KUKc.js → entity-card-p-LANpYt.js} +18 -17
- package/dist/_chunks/{entity-card-fpm-KUKc.js.map → entity-card-p-LANpYt.js.map} +1 -1
- package/dist/_chunks/{error-page-B0fGNTRB.js → error-page-WLhmWUTq.js} +100 -115
- package/dist/_chunks/error-page-WLhmWUTq.js.map +1 -0
- package/dist/_chunks/finished-terminal-unDnXT4j.js +191 -0
- package/dist/_chunks/finished-terminal-unDnXT4j.js.map +1 -0
- package/dist/_chunks/house-DGCypGTo.js +21 -0
- package/dist/_chunks/house-DGCypGTo.js.map +1 -0
- package/dist/_chunks/is-safe-url-CEy9CEml.js +8 -0
- package/dist/_chunks/is-safe-url-CEy9CEml.js.map +1 -0
- package/dist/_chunks/keypad-DBH_keVs.js +152 -0
- package/dist/_chunks/keypad-DBH_keVs.js.map +1 -0
- package/dist/_chunks/keypad-button-mOaPQRrH.js +114 -0
- package/dist/_chunks/keypad-button-mOaPQRrH.js.map +1 -0
- package/dist/_chunks/{message-card-BG3_3nN1.js → message-card-Bw_q1qKx.js} +2 -2
- package/dist/_chunks/{message-card-BG3_3nN1.js.map → message-card-Bw_q1qKx.js.map} +1 -1
- package/dist/_chunks/{message-tray-BjZv0Fsk.js → message-tray-pLGgLmoG.js} +2 -2
- package/dist/_chunks/{message-tray-BjZv0Fsk.js.map → message-tray-pLGgLmoG.js.map} +1 -1
- package/dist/_chunks/{note-attachment-MNTIqdSz.js → note-attachment-JTIy9iXN.js} +2 -2
- package/dist/_chunks/{note-attachment-MNTIqdSz.js.map → note-attachment-JTIy9iXN.js.map} +1 -1
- package/dist/_chunks/{note-timeline-BQeW0VZY.js → note-timeline-BbjHMhkL.js} +2 -2
- package/dist/_chunks/{note-timeline-BQeW0VZY.js.map → note-timeline-BbjHMhkL.js.map} +1 -1
- package/dist/_chunks/{notes-panel-Cm-_pCRJ.js → notes-panel-BAyPOr8N.js} +2 -2
- package/dist/_chunks/{notes-panel-Cm-_pCRJ.js.map → notes-panel-BAyPOr8N.js.map} +1 -1
- package/dist/_chunks/{operator-hero-CnfWckNQ.js → operator-hero-D4wfVu2l.js} +2 -2
- package/dist/_chunks/{operator-hero-CnfWckNQ.js.map → operator-hero-D4wfVu2l.js.map} +1 -1
- package/dist/_chunks/otp-input-BNOTlxq3.js +342 -0
- package/dist/_chunks/otp-input-BNOTlxq3.js.map +1 -0
- package/dist/_chunks/patient-account-settings-BkAtIxJW.js +546 -0
- package/dist/_chunks/patient-account-settings-BkAtIxJW.js.map +1 -0
- package/dist/_chunks/patient-card-DTh3QTyS.js +125 -0
- package/dist/_chunks/patient-card-DTh3QTyS.js.map +1 -0
- package/dist/_chunks/patient-check-in-resume-xhqjC6gf.js +742 -0
- package/dist/_chunks/patient-check-in-resume-xhqjC6gf.js.map +1 -0
- package/dist/_chunks/patient-sign-in-pin-CDBqV254.js +432 -0
- package/dist/_chunks/patient-sign-in-pin-CDBqV254.js.map +1 -0
- package/dist/_chunks/patient-sign-in-steps-C2JSqlok.js +199 -0
- package/dist/_chunks/patient-sign-in-steps-C2JSqlok.js.map +1 -0
- package/dist/_chunks/{patient-summary-card-BUcZ-gaL.js → patient-summary-card-Bl2NknPe.js} +2 -2
- package/dist/_chunks/{patient-summary-card-BUcZ-gaL.js.map → patient-summary-card-Bl2NknPe.js.map} +1 -1
- package/dist/_chunks/{payment-request-card-Dv4WbRBe.js → payment-request-card-CNW00DCx.js} +6 -6
- package/dist/_chunks/{payment-request-card-Dv4WbRBe.js.map → payment-request-card-CNW00DCx.js.map} +1 -1
- package/dist/_chunks/{pdf-viewer-BnBKdx0y.js → pdf-viewer-TRC5jEm5.js} +472 -425
- package/dist/_chunks/pdf-viewer-TRC5jEm5.js.map +1 -0
- package/dist/_chunks/pin-entry-BugWQMOS.js +219 -0
- package/dist/_chunks/pin-entry-BugWQMOS.js.map +1 -0
- package/dist/_chunks/pin-indicator-Cb-n40UI.js +124 -0
- package/dist/_chunks/pin-indicator-Cb-n40UI.js.map +1 -0
- package/dist/_chunks/portal-details-CTEsm705.js +478 -0
- package/dist/_chunks/portal-details-CTEsm705.js.map +1 -0
- package/dist/_chunks/portal-documents-D8skew0h.js +902 -0
- package/dist/_chunks/portal-documents-D8skew0h.js.map +1 -0
- package/dist/_chunks/portal-parts-BdR29P7z.js +285 -0
- package/dist/_chunks/portal-parts-BdR29P7z.js.map +1 -0
- package/dist/_chunks/{privacy-mask-DJ1gee4c.js → privacy-mask-C19dJFMk.js} +5 -5
- package/dist/_chunks/{privacy-mask-DJ1gee4c.js.map → privacy-mask-C19dJFMk.js.map} +1 -1
- package/dist/_chunks/{product-hub-panel-a8wdVOUt.js → product-hub-panel-K4QbULG7.js} +2 -2
- package/dist/_chunks/{product-hub-panel-a8wdVOUt.js.map → product-hub-panel-K4QbULG7.js.map} +1 -1
- package/dist/_chunks/{registration-form-CwbhtKcy.js → registration-form-DS3RuKHu.js} +2 -2
- package/dist/_chunks/{registration-form-CwbhtKcy.js.map → registration-form-DS3RuKHu.js.map} +1 -1
- package/dist/_chunks/{reserved.agent-W8mR179D.js → reserved.agent-DOzOBUW7.js} +2 -2
- package/dist/_chunks/{reserved.agent-W8mR179D.js.map → reserved.agent-DOzOBUW7.js.map} +1 -1
- package/dist/_chunks/session-countdown-DOx1IBUB.js +232 -0
- package/dist/_chunks/session-countdown-DOx1IBUB.js.map +1 -0
- package/dist/_chunks/{sign-document-CQZVzfpk.js → sign-document-DDZbmYHu.js} +2 -2
- package/dist/_chunks/{sign-document-CQZVzfpk.js.map → sign-document-DDZbmYHu.js.map} +1 -1
- package/dist/_chunks/{signature-field-DjabvRZm.js → signature-field-BjlY_yXH.js} +39 -34
- package/dist/_chunks/signature-field-BjlY_yXH.js.map +1 -0
- package/dist/_chunks/{signature-request-4pGq3YBe.js → signature-request-CHsM_iWi.js} +2 -2
- package/dist/_chunks/{signature-request-4pGq3YBe.js.map → signature-request-CHsM_iWi.js.map} +1 -1
- package/dist/_chunks/{signature-status-chip-pIoQjvH8.js → signature-status-chip-DS9hHwIt.js} +66 -69
- package/dist/_chunks/signature-status-chip-DS9hHwIt.js.map +1 -0
- package/dist/_chunks/signing-end-screen-an9P8DOT.js +1041 -0
- package/dist/_chunks/signing-end-screen-an9P8DOT.js.map +1 -0
- package/dist/_chunks/sms-code-entry-Dgp4GwlM.js +316 -0
- package/dist/_chunks/sms-code-entry-Dgp4GwlM.js.map +1 -0
- package/dist/_chunks/step-up-dialog-C2JqJmCA.js +132 -0
- package/dist/_chunks/step-up-dialog-C2JqJmCA.js.map +1 -0
- package/dist/_chunks/{task-editor-BL2hHxNz.js → task-editor-g1AGfxhr.js} +38 -38
- package/dist/_chunks/{task-editor-BL2hHxNz.js.map → task-editor-g1AGfxhr.js.map} +1 -1
- package/dist/_chunks/{use-appointment-details-read-_b7FRB1x.js → use-appointment-details-read-Dzc6fEzG.js} +6 -6
- package/dist/_chunks/{use-appointment-details-read-_b7FRB1x.js.map → use-appointment-details-read-Dzc6fEzG.js.map} +1 -1
- package/dist/_chunks/use-zoom-drilldown-Cr1baU5X.js +221 -0
- package/dist/_chunks/use-zoom-drilldown-Cr1baU5X.js.map +1 -0
- package/dist/_chunks/{user-x-DYszNtIg.js → user-x-BJZg4kaP.js} +8 -19
- package/dist/_chunks/user-x-BJZg4kaP.js.map +1 -0
- package/dist/_chunks/{verify-identity-types-CxtrBXsZ.js → verify-identity-types-C6Bam8v6.js} +2 -2
- package/dist/_chunks/{verify-identity-types-CxtrBXsZ.js.map → verify-identity-types-C6Bam8v6.js.map} +1 -1
- package/dist/agent-catalog.json +723 -364
- package/dist/agent-i18n/en.json +75 -18
- package/dist/browser-support.js +1 -1
- package/dist/components/_shared/is-safe-url.d.ts +3 -1
- package/dist/components/_shared/is-safe-url.d.ts.map +1 -1
- package/dist/components/agenda-card/index.js +2 -2
- package/dist/components/agenda-tray/index.js +1 -1
- package/dist/components/appointment-card/appointment-card.d.ts +45 -0
- package/dist/components/appointment-card/appointment-card.d.ts.map +1 -1
- package/dist/components/appointment-card/appointment-tray.agent.d.ts.map +1 -1
- package/dist/components/appointment-card/appointment-tray.d.ts +11 -0
- package/dist/components/appointment-card/appointment-tray.d.ts.map +1 -1
- package/dist/components/appointment-card/index.js +3 -3
- package/dist/components/appointment-details-panel/index.js +1 -1
- package/dist/components/appointment-peek/index.js +1 -1
- package/dist/components/appointment-timeline/index.js +1 -1
- package/dist/components/booking/index.js +1 -1
- package/dist/components/calendar/index.js +1 -1
- package/dist/components/calendar-event-card/index.js +1 -1
- package/dist/components/care-plan-card/index.js +1 -1
- package/dist/components/care-plan-entry-card/index.js +1 -1
- package/dist/components/care-plan-header/index.js +1 -1
- package/dist/components/clinical-note-card/index.js +1 -1
- package/dist/components/document-preview/document-preview.agent.d.ts.map +1 -1
- package/dist/components/document-preview/document-preview.d.ts +61 -7
- package/dist/components/document-preview/document-preview.d.ts.map +1 -1
- package/dist/components/document-preview/index.js +1 -1
- package/dist/components/finished-terminal/finished-terminal.d.ts +63 -6
- package/dist/components/finished-terminal/finished-terminal.d.ts.map +1 -1
- package/dist/components/finished-terminal/index.d.ts +1 -1
- package/dist/components/finished-terminal/index.d.ts.map +1 -1
- package/dist/components/finished-terminal/index.js +1 -1
- package/dist/components/index.d.ts +12 -0
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/keypad/index.d.ts +3 -0
- package/dist/components/keypad/index.d.ts.map +1 -0
- package/dist/components/keypad/index.js +6 -0
- package/dist/components/keypad/index.js.map +1 -0
- package/dist/components/keypad/keypad.d.ts +54 -0
- package/dist/components/keypad/keypad.d.ts.map +1 -0
- package/dist/components/keypad-button/index.d.ts +3 -0
- package/dist/components/keypad-button/index.d.ts.map +1 -0
- package/dist/components/keypad-button/index.js +6 -0
- package/dist/components/keypad-button/index.js.map +1 -0
- package/dist/components/keypad-button/keypad-button.d.ts +33 -0
- package/dist/components/keypad-button/keypad-button.d.ts.map +1 -0
- package/dist/components/message-card/index.js +2 -2
- package/dist/components/message-tray/index.js +1 -1
- package/dist/components/note-timeline/index.js +1 -1
- package/dist/components/notes-panel/index.js +1 -1
- package/dist/components/operator-hero/index.js +1 -1
- package/dist/components/otp-input/index.js +1 -1
- package/dist/components/otp-input/otp-input.d.ts +11 -0
- package/dist/components/otp-input/otp-input.d.ts.map +1 -1
- package/dist/components/patient-summary-card/index.js +1 -1
- package/dist/components/payment-card/index.js +1 -1
- package/dist/components/pdf-viewer/index.js +1 -1
- package/dist/components/pdf-viewer/pdf-viewer.agent.d.ts.map +1 -1
- package/dist/components/pdf-viewer/pdf-viewer.d.ts +7 -0
- package/dist/components/pdf-viewer/pdf-viewer.d.ts.map +1 -1
- package/dist/components/pin-entry/index.d.ts +3 -0
- package/dist/components/pin-entry/index.d.ts.map +1 -0
- package/dist/components/pin-entry/index.js +5 -0
- package/dist/components/pin-entry/index.js.map +1 -0
- package/dist/components/pin-entry/pin-entry.agent.d.ts +4 -0
- package/dist/components/pin-entry/pin-entry.agent.d.ts.map +1 -0
- package/dist/components/pin-entry/pin-entry.d.ts +64 -0
- package/dist/components/pin-entry/pin-entry.d.ts.map +1 -0
- package/dist/components/pin-indicator/index.d.ts +3 -0
- package/dist/components/pin-indicator/index.d.ts.map +1 -0
- package/dist/components/pin-indicator/index.js +9 -0
- package/dist/components/pin-indicator/index.js.map +1 -0
- package/dist/components/pin-indicator/pin-indicator.d.ts +34 -0
- package/dist/components/pin-indicator/pin-indicator.d.ts.map +1 -0
- package/dist/components/product-hub-tray/index.js +2 -2
- package/dist/components/session-countdown/index.js +1 -1
- package/dist/components/session-countdown/session-countdown.d.ts +19 -0
- package/dist/components/session-countdown/session-countdown.d.ts.map +1 -1
- package/dist/components/sign-document/index.js +1 -1
- package/dist/components/signature-field/index.js +1 -1
- package/dist/components/signature-field/signature-field.d.ts +17 -6
- package/dist/components/signature-field/signature-field.d.ts.map +1 -1
- package/dist/components/signature-status-chip/index.js +1 -1
- package/dist/components/signature-status-chip/signature-status-chip.d.ts +3 -2
- package/dist/components/signature-status-chip/signature-status-chip.d.ts.map +1 -1
- package/dist/components/sms-code-entry/index.d.ts +3 -0
- package/dist/components/sms-code-entry/index.d.ts.map +1 -0
- package/dist/components/sms-code-entry/index.js +5 -0
- package/dist/components/sms-code-entry/index.js.map +1 -0
- package/dist/components/sms-code-entry/sms-code-entry.agent.d.ts +4 -0
- package/dist/components/sms-code-entry/sms-code-entry.agent.d.ts.map +1 -0
- package/dist/components/sms-code-entry/sms-code-entry.d.ts +156 -0
- package/dist/components/sms-code-entry/sms-code-entry.d.ts.map +1 -0
- package/dist/components/step-up-dialog/index.d.ts +3 -0
- package/dist/components/step-up-dialog/index.d.ts.map +1 -0
- package/dist/components/step-up-dialog/index.js +5 -0
- package/dist/components/step-up-dialog/index.js.map +1 -0
- package/dist/components/step-up-dialog/step-up-dialog.d.ts +108 -0
- package/dist/components/step-up-dialog/step-up-dialog.d.ts.map +1 -0
- package/dist/components/task-editor/index.js +1 -1
- package/dist/components/workflow-status/index.js +1 -1
- package/dist/core.css +1 -1
- package/dist/hooks/index.js +1 -1
- package/dist/hooks/use-signing-session.d.ts +7 -2
- package/dist/hooks/use-signing-session.d.ts.map +1 -1
- package/dist/host-compat.css +10 -1
- package/dist/i18n/locales/ar.d.ts +514 -1
- package/dist/i18n/locales/ar.d.ts.map +1 -1
- package/dist/i18n/locales/ar.js +512 -4
- package/dist/i18n/locales/ar.js.map +1 -1
- package/dist/i18n/locales/de.d.ts +514 -1
- package/dist/i18n/locales/de.d.ts.map +1 -1
- package/dist/i18n/locales/de.js +520 -5
- package/dist/i18n/locales/de.js.map +1 -1
- package/dist/i18n/locales/el.d.ts +514 -1
- package/dist/i18n/locales/el.d.ts.map +1 -1
- package/dist/i18n/locales/el.js +515 -5
- package/dist/i18n/locales/el.js.map +1 -1
- package/dist/i18n/locales/en.d.ts +516 -1
- package/dist/i18n/locales/en.d.ts.map +1 -1
- package/dist/i18n/locales/en.js +522 -4
- package/dist/i18n/locales/en.js.map +1 -1
- package/dist/i18n/locales/es.d.ts +514 -1
- package/dist/i18n/locales/es.d.ts.map +1 -1
- package/dist/i18n/locales/es.js +513 -5
- package/dist/i18n/locales/es.js.map +1 -1
- package/dist/i18n/locales/fr.d.ts +514 -1
- package/dist/i18n/locales/fr.d.ts.map +1 -1
- package/dist/i18n/locales/fr.js +513 -5
- package/dist/i18n/locales/fr.js.map +1 -1
- package/dist/i18n/locales/hi.d.ts +514 -1
- package/dist/i18n/locales/hi.d.ts.map +1 -1
- package/dist/i18n/locales/hi.js +513 -5
- package/dist/i18n/locales/hi.js.map +1 -1
- package/dist/i18n/locales/it.d.ts +514 -1
- package/dist/i18n/locales/it.d.ts.map +1 -1
- package/dist/i18n/locales/it.js +520 -5
- package/dist/i18n/locales/it.js.map +1 -1
- package/dist/i18n/locales/ja.d.ts +514 -1
- package/dist/i18n/locales/ja.d.ts.map +1 -1
- package/dist/i18n/locales/ja.js +513 -5
- package/dist/i18n/locales/ja.js.map +1 -1
- package/dist/i18n/locales/nl.d.ts +514 -1
- package/dist/i18n/locales/nl.d.ts.map +1 -1
- package/dist/i18n/locales/nl.js +520 -5
- package/dist/i18n/locales/nl.js.map +1 -1
- package/dist/i18n/locales/pl.d.ts +514 -1
- package/dist/i18n/locales/pl.d.ts.map +1 -1
- package/dist/i18n/locales/pl.js +520 -5
- package/dist/i18n/locales/pl.js.map +1 -1
- package/dist/i18n/locales/pt.d.ts +514 -1
- package/dist/i18n/locales/pt.d.ts.map +1 -1
- package/dist/i18n/locales/pt.js +520 -5
- package/dist/i18n/locales/pt.js.map +1 -1
- package/dist/i18n/locales/ro.d.ts +514 -1
- package/dist/i18n/locales/ro.d.ts.map +1 -1
- package/dist/i18n/locales/ro.js +520 -5
- package/dist/i18n/locales/ro.js.map +1 -1
- package/dist/i18n/locales/ru.d.ts +514 -1
- package/dist/i18n/locales/ru.d.ts.map +1 -1
- package/dist/i18n/locales/ru.js +512 -4
- package/dist/i18n/locales/ru.js.map +1 -1
- package/dist/i18n/locales/sq.d.ts +514 -1
- package/dist/i18n/locales/sq.d.ts.map +1 -1
- package/dist/i18n/locales/sq.js +513 -5
- package/dist/i18n/locales/sq.js.map +1 -1
- package/dist/i18n/locales/sv.d.ts +514 -1
- package/dist/i18n/locales/sv.d.ts.map +1 -1
- package/dist/i18n/locales/sv.js +513 -5
- package/dist/i18n/locales/sv.js.map +1 -1
- package/dist/i18n/locales/tr.d.ts +514 -1
- package/dist/i18n/locales/tr.d.ts.map +1 -1
- package/dist/i18n/locales/tr.js +515 -5
- package/dist/i18n/locales/tr.js.map +1 -1
- package/dist/i18n/locales/zh.d.ts +514 -1
- package/dist/i18n/locales/zh.d.ts.map +1 -1
- package/dist/i18n/locales/zh.js +513 -5
- package/dist/i18n/locales/zh.js.map +1 -1
- package/dist/index.js +1271 -1204
- package/dist/index.js.map +1 -1
- package/dist/locales/ar.json +516 -3
- package/dist/locales/de.json +517 -4
- package/dist/locales/el.json +517 -4
- package/dist/locales/en.json +516 -3
- package/dist/locales/es.json +517 -4
- package/dist/locales/fr.json +517 -4
- package/dist/locales/hi.json +517 -4
- package/dist/locales/it.json +517 -4
- package/dist/locales/ja.json +517 -4
- package/dist/locales/nl.json +517 -4
- package/dist/locales/pl.json +517 -4
- package/dist/locales/pt.json +517 -4
- package/dist/locales/ro.json +517 -4
- package/dist/locales/ru.json +516 -3
- package/dist/locales/sq.json +517 -4
- package/dist/locales/sv.json +517 -4
- package/dist/locales/tr.json +517 -4
- package/dist/locales/zh.json +517 -4
- package/dist/patterns/calendar/calendar-workspace.d.ts.map +1 -1
- package/dist/patterns/calendar/calendar-workspace.model.d.ts.map +1 -1
- package/dist/patterns/calendar/calendar.journey.d.ts +4 -0
- package/dist/patterns/calendar/calendar.journey.d.ts.map +1 -1
- package/dist/patterns/calendar/calendar.sheets.d.ts.map +1 -1
- package/dist/patterns/calendar/calendar.surface.d.ts +15 -1
- package/dist/patterns/calendar/calendar.surface.d.ts.map +1 -1
- package/dist/patterns/calendar/calendar.types.d.ts +4 -0
- package/dist/patterns/calendar/calendar.types.d.ts.map +1 -1
- package/dist/patterns/calendar/index.js +1 -1
- package/dist/patterns/check-in-documents/check-in-documents.d.ts +61 -0
- package/dist/patterns/check-in-documents/check-in-documents.d.ts.map +1 -0
- package/dist/patterns/check-in-documents/check-in-signable-document.d.ts +32 -0
- package/dist/patterns/check-in-documents/check-in-signable-document.d.ts.map +1 -0
- package/dist/patterns/check-in-documents/index.d.ts +4 -0
- package/dist/patterns/check-in-documents/index.d.ts.map +1 -0
- package/dist/patterns/check-in-documents/index.js +5 -0
- package/dist/patterns/check-in-documents/index.js.map +1 -0
- package/dist/patterns/error-page/index.js +1 -1
- package/dist/patterns/patient-account-settings/index.d.ts +4 -0
- package/dist/patterns/patient-account-settings/index.d.ts.map +1 -0
- package/dist/patterns/patient-account-settings/index.js +5 -0
- package/dist/patterns/patient-account-settings/index.js.map +1 -0
- package/dist/patterns/patient-account-settings/patient-account-settings-panels.d.ts +36 -0
- package/dist/patterns/patient-account-settings/patient-account-settings-panels.d.ts.map +1 -0
- package/dist/patterns/patient-account-settings/patient-account-settings.d.ts +94 -0
- package/dist/patterns/patient-account-settings/patient-account-settings.d.ts.map +1 -0
- package/dist/patterns/patient-account-settings/patient-account-settings.types.d.ts +91 -0
- package/dist/patterns/patient-account-settings/patient-account-settings.types.d.ts.map +1 -0
- package/dist/patterns/patient-check-in/index.d.ts +20 -0
- package/dist/patterns/patient-check-in/index.d.ts.map +1 -0
- package/dist/patterns/patient-check-in/index.js +13 -0
- package/dist/patterns/patient-check-in/index.js.map +1 -0
- package/dist/patterns/patient-check-in/patient-check-in-changed.d.ts +33 -0
- package/dist/patterns/patient-check-in/patient-check-in-changed.d.ts.map +1 -0
- package/dist/patterns/patient-check-in/patient-check-in-connection-notice.d.ts +29 -0
- package/dist/patterns/patient-check-in/patient-check-in-connection-notice.d.ts.map +1 -0
- package/dist/patterns/patient-check-in/patient-check-in-done.d.ts +25 -0
- package/dist/patterns/patient-check-in/patient-check-in-done.d.ts.map +1 -0
- package/dist/patterns/patient-check-in/patient-check-in-entry.d.ts +29 -0
- package/dist/patterns/patient-check-in/patient-check-in-entry.d.ts.map +1 -0
- package/dist/patterns/patient-check-in/patient-check-in-hub-empty.d.ts +23 -0
- package/dist/patterns/patient-check-in/patient-check-in-hub-empty.d.ts.map +1 -0
- package/dist/patterns/patient-check-in/patient-check-in-hub.d.ts +61 -0
- package/dist/patterns/patient-check-in/patient-check-in-hub.d.ts.map +1 -0
- package/dist/patterns/patient-check-in/patient-check-in-personal-data.d.ts +73 -0
- package/dist/patterns/patient-check-in/patient-check-in-personal-data.d.ts.map +1 -0
- package/dist/patterns/patient-check-in/patient-check-in-privacy.d.ts +9 -0
- package/dist/patterns/patient-check-in/patient-check-in-privacy.d.ts.map +1 -0
- package/dist/patterns/patient-check-in/patient-check-in-resume.d.ts +29 -0
- package/dist/patterns/patient-check-in/patient-check-in-resume.d.ts.map +1 -0
- package/dist/patterns/patient-check-in/patient-check-in-shell.d.ts +60 -0
- package/dist/patterns/patient-check-in/patient-check-in-shell.d.ts.map +1 -0
- package/dist/patterns/patient-check-in/patient-check-in-types.d.ts +92 -0
- package/dist/patterns/patient-check-in/patient-check-in-types.d.ts.map +1 -0
- package/dist/patterns/patient-portal/index.d.ts +12 -0
- package/dist/patterns/patient-portal/index.d.ts.map +1 -0
- package/dist/patterns/patient-portal/index.js +13 -0
- package/dist/patterns/patient-portal/index.js.map +1 -0
- package/dist/patterns/patient-portal/portal-appointments.d.ts +70 -0
- package/dist/patterns/patient-portal/portal-appointments.d.ts.map +1 -0
- package/dist/patterns/patient-portal/portal-details.d.ts +148 -0
- package/dist/patterns/patient-portal/portal-details.d.ts.map +1 -0
- package/dist/patterns/patient-portal/portal-documents.d.ts +74 -0
- package/dist/patterns/patient-portal/portal-documents.d.ts.map +1 -0
- package/dist/patterns/patient-portal/portal-format.d.ts +14 -0
- package/dist/patterns/patient-portal/portal-format.d.ts.map +1 -0
- package/dist/patterns/patient-portal/portal-home.d.ts +71 -0
- package/dist/patterns/patient-portal/portal-home.d.ts.map +1 -0
- package/dist/patterns/patient-portal/portal-parts.d.ts +107 -0
- package/dist/patterns/patient-portal/portal-parts.d.ts.map +1 -0
- package/dist/patterns/patient-portal/portal-shell.d.ts +84 -0
- package/dist/patterns/patient-portal/portal-shell.d.ts.map +1 -0
- package/dist/patterns/patient-portal/portal-types.d.ts +157 -0
- package/dist/patterns/patient-portal/portal-types.d.ts.map +1 -0
- package/dist/patterns/patient-sign-in/index.d.ts +7 -0
- package/dist/patterns/patient-sign-in/index.d.ts.map +1 -0
- package/dist/patterns/patient-sign-in/index.js +15 -0
- package/dist/patterns/patient-sign-in/index.js.map +1 -0
- package/dist/patterns/patient-sign-in/patient-card.d.ts +74 -0
- package/dist/patterns/patient-sign-in/patient-card.d.ts.map +1 -0
- package/dist/patterns/patient-sign-in/patient-sign-in-email.d.ts +109 -0
- package/dist/patterns/patient-sign-in/patient-sign-in-email.d.ts.map +1 -0
- package/dist/patterns/patient-sign-in/patient-sign-in-pin.d.ts +157 -0
- package/dist/patterns/patient-sign-in/patient-sign-in-pin.d.ts.map +1 -0
- package/dist/patterns/patient-sign-in/patient-sign-in-steps.d.ts +143 -0
- package/dist/patterns/patient-sign-in/patient-sign-in-steps.d.ts.map +1 -0
- package/dist/patterns/registration-form/index.js +1 -1
- package/dist/patterns/signature-request/index.js +1 -1
- package/dist/patterns/signing/index.d.ts +25 -0
- package/dist/patterns/signing/index.d.ts.map +1 -0
- package/dist/patterns/signing/index.js +16 -0
- package/dist/patterns/signing/index.js.map +1 -0
- package/dist/patterns/signing/multi-field-signer.d.ts +117 -0
- package/dist/patterns/signing/multi-field-signer.d.ts.map +1 -0
- package/dist/patterns/signing/signing-awaiting-screen.d.ts +25 -0
- package/dist/patterns/signing/signing-awaiting-screen.d.ts.map +1 -0
- package/dist/patterns/signing/signing-chrome.d.ts +30 -0
- package/dist/patterns/signing/signing-chrome.d.ts.map +1 -0
- package/dist/patterns/signing/signing-document-screen.d.ts +87 -0
- package/dist/patterns/signing/signing-document-screen.d.ts.map +1 -0
- package/dist/patterns/signing/signing-end-screen.d.ts +27 -0
- package/dist/patterns/signing/signing-end-screen.d.ts.map +1 -0
- package/dist/patterns/signing/signing-finished-screen.d.ts +34 -0
- package/dist/patterns/signing/signing-finished-screen.d.ts.map +1 -0
- package/dist/patterns/signing/signing-footer.d.ts +56 -0
- package/dist/patterns/signing/signing-footer.d.ts.map +1 -0
- package/dist/patterns/signing/signing-handoff-screen.d.ts +37 -0
- package/dist/patterns/signing/signing-handoff-screen.d.ts.map +1 -0
- package/dist/patterns/signing/signing-message-dialog.d.ts +29 -0
- package/dist/patterns/signing/signing-message-dialog.d.ts.map +1 -0
- package/dist/patterns/signing/signing-progress-chip.d.ts +27 -0
- package/dist/patterns/signing/signing-progress-chip.d.ts.map +1 -0
- package/dist/patterns/signing/signing-roster.d.ts +44 -0
- package/dist/patterns/signing/signing-roster.d.ts.map +1 -0
- package/dist/patterns/signing/signing-staff-id-confirmation.d.ts +49 -0
- package/dist/patterns/signing/signing-staff-id-confirmation.d.ts.map +1 -0
- package/dist/patterns/verify-identity/index.js +1 -1
- package/dist/tokens.css +1 -1
- package/package.json +49 -1
- package/dist/_chunks/appointment-card-OAOur8lH.js +0 -434
- package/dist/_chunks/appointment-card-OAOur8lH.js.map +0 -1
- package/dist/_chunks/appointment-tray-DSFqO5Rm.js +0 -193
- package/dist/_chunks/appointment-tray-DSFqO5Rm.js.map +0 -1
- package/dist/_chunks/calendar-appointment-editor-dialog-WW6V1SGh.js +0 -13663
- package/dist/_chunks/calendar-appointment-editor-dialog-WW6V1SGh.js.map +0 -1
- package/dist/_chunks/document-preview-_kQ9QvZV.js +0 -291
- package/dist/_chunks/document-preview-_kQ9QvZV.js.map +0 -1
- package/dist/_chunks/error-page-B0fGNTRB.js.map +0 -1
- package/dist/_chunks/finished-terminal-FR8uc_Ws.js +0 -122
- package/dist/_chunks/finished-terminal-FR8uc_Ws.js.map +0 -1
- package/dist/_chunks/is-safe-url-DkETxeHz.js +0 -7
- package/dist/_chunks/is-safe-url-DkETxeHz.js.map +0 -1
- package/dist/_chunks/otp-input-gV1446Dw.js +0 -301
- package/dist/_chunks/otp-input-gV1446Dw.js.map +0 -1
- package/dist/_chunks/pdf-viewer-BnBKdx0y.js.map +0 -1
- package/dist/_chunks/session-countdown-C4tzbJVc.js +0 -223
- package/dist/_chunks/session-countdown-C4tzbJVc.js.map +0 -1
- package/dist/_chunks/signature-field-DjabvRZm.js.map +0 -1
- package/dist/_chunks/signature-status-chip-pIoQjvH8.js.map +0 -1
- package/dist/_chunks/use-zoom-drilldown-qCX34w9I.js +0 -210
- package/dist/_chunks/use-zoom-drilldown-qCX34w9I.js.map +0 -1
- package/dist/_chunks/user-x-DYszNtIg.js.map +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"signature-status-chip-pIoQjvH8.js","sources":["../../src/components/signature-status-chip/signature-status-chip.tsx"],"sourcesContent":["import { forwardRef, type HTMLAttributes } from 'react';\nimport { useTranslation } from 'react-i18next';\nimport { Badge, type BadgeProps } from '../badge';\nimport { Tooltip } from '../tooltip';\n\n/* ------------------------------------------------------------------ */\n/* State vocabulary */\n/* ------------------------------------------------------------------ */\n\n/** One party's standing on the document. */\nexport type SignatureParty = 'signed' | 'pending' | 'notRequired';\n\n/** The chip's derived state. */\nexport type SignatureStatus = 'signed' | 'partial' | 'unsigned' | 'notRequired';\n\n/**\n * The parties a document can require. `secondary` is the second signee on a\n * two-signee envelope (platform: `secondary_signee_id`) — a guardian, parent\n * or co-signer. It is optional: a document that does not need one leaves it\n * `notRequired`, which is the default.\n */\nexport type SignatureRole = 'operator' | 'patient' | 'secondary';\n\ntype RequiredStanding = Exclude<SignatureParty, 'notRequired'>;\n\n/**\n * Who a party is, and — when they cannot sign for themselves — who signs in\n * their place. A minor, or an adult who lacks capacity, is still the party\n * the document is about; the parent, guardian or legal representative signs\n * on their behalf. The standing (`signed` / `pending`) stays on the party,\n * because it is their signature slot that is being filled.\n */\nexport interface SignerRepresentative {\n /** The representative's display name. */\n name: string;\n /**\n * Already-translated relationship to the party, e.g. \"Mother\",\n * \"Legal guardian\". Same contract as `SignerRoster.relationship` — the\n * host translates it, because the set is open.\n */\n relationship?: string;\n /**\n * This representative's own standing. Supply it when representatives can\n * be at different stages — both parents must consent and only one has\n * signed. Omit it and the representative inherits the party's standing,\n * which is the right default when a single person signs.\n */\n standing?: Exclude<SignatureParty, 'notRequired'>;\n}\n\nexport interface SignerIdentity {\n /** The party's own display name. */\n name: string;\n /**\n * Who signs in this party's place, when the party cannot sign for\n * themselves. One representative for the ordinary guardian case; several\n * where every one of them must sign — both parents consenting for a minor,\n * where the minor never signs at all.\n *\n * When representatives carry their own `standing`, they become the source\n * of truth for this party: the slot is `signed` only once every one of\n * them has signed. Pass the same values to {@link signatureStatusOf} so\n * host-side filtering agrees with the chip.\n */\n signedBy?: SignerRepresentative | SignerRepresentative[];\n}\n\n/** Normalise the one-or-many representative shape to a list. */\nfunction representativesOf(\n identity: string | SignerIdentity | undefined,\n): SignerRepresentative[] {\n if (!identity || typeof identity === 'string') return [];\n const by = identity.signedBy;\n if (!by) return [];\n return Array.isArray(by) ? by : [by];\n}\n\n/**\n * A party's effective standing. Representatives that carry their own\n * `standing` override the party value, because they are the signatures that\n * actually have to land: every one of them must sign before the slot is\n * complete.\n */\nexport function effectiveStanding(\n party: SignatureParty,\n identity?: string | SignerIdentity,\n): SignatureParty {\n if (party === 'notRequired') return 'notRequired';\n const reps = representativesOf(identity).filter((r) => r.standing);\n if (reps.length === 0) return party;\n return reps.every((r) => r.standing === 'signed') ? 'signed' : 'pending';\n}\n\n/**\n * Display names for the signers, when the host has them and chooses to show\n * them. A bare string is the common case; pass a {@link SignerIdentity} where\n * someone signs on the party's behalf.\n */\nexport type SignatureSignerNames = Partial<\n Record<SignatureRole, string | SignerIdentity>\n>;\n\n/**\n * The rule, exported so hosts can sort/filter by the same state the chip\n * shows: required = parties not `notRequired`; all signed → `signed`, some\n * signed → `partial`, none signed → `unsigned`, nobody required → `notRequired`.\n *\n * `secondary` is optional and defaults to `notRequired`, so existing\n * two-argument calls keep their exact meaning.\n */\nexport function signatureStatusOf(\n operator: SignatureParty,\n patient: SignatureParty,\n secondary: SignatureParty = 'notRequired',\n names?: SignatureSignerNames,\n): SignatureStatus {\n const required = [\n effectiveStanding(operator, names?.operator),\n effectiveStanding(patient, names?.patient),\n effectiveStanding(secondary, names?.secondary),\n ].filter((p) => p !== 'notRequired');\n if (required.length === 0) return 'notRequired';\n const signed = required.filter((p) => p === 'signed').length;\n if (signed === 0) return 'unsigned';\n return signed === required.length ? 'signed' : 'partial';\n}\n\n// `partial` shares the warning tone with `unsigned` so a half-signed document\n// never reads as done at a glance — only a fully signed one goes green.\nconst STATUS_VARIANT: Record<\n SignatureStatus,\n NonNullable<BadgeProps['variant']>\n> = {\n // Traffic light: green when everyone required has signed, amber when at\n // least one party is still missing, red when nobody has.\n signed: 'success',\n partial: 'warning',\n unsigned: 'error',\n notRequired: 'neutral',\n};\n\nconst ROLE_DEFAULT: Record<SignatureRole, string> = {\n operator: 'Operator',\n patient: 'Patient',\n secondary: 'Second signee',\n};\n\nconst STANDING_DEFAULT: Record<RequiredStanding, string> = {\n signed: 'signed',\n pending: 'pending',\n};\n\n// Flat keys, matching the shipped bundles. i18next splits on '.', so a\n// nested `missing.operator` alongside the existing flat keys would risk a\n// lookup collision — and renaming them would break any host override.\nconst MISSING_KEY: Record<SignatureRole, string> = {\n operator: 'signatureStatusChip.missingOperator',\n patient: 'signatureStatusChip.missingPatient',\n secondary: 'signatureStatusChip.missingSecondary',\n};\n\nconst MISSING_DEFAULT: Record<SignatureRole, string> = {\n operator: 'Operator signature missing',\n patient: 'Patient signature missing',\n secondary: 'Second signee signature missing',\n};\n\n/**\n * Wrap host-supplied names in a Unicode first-strong isolate. Names arrive in\n * an unknown script and are interpolated into a translated frame — a Latin\n * name inside an Arabic sentence reorders the surrounding punctuation without\n * this. FSI … PDI is invisible, and assistive tech treats it as formatting.\n */\nfunction isolate(value: string): string {\n return `\\u2068${value}\\u2069`;\n}\n\nfunction requiredParties(\n operator: SignatureParty,\n patient: SignatureParty,\n secondary: SignatureParty,\n): Array<{ role: SignatureRole; standing: RequiredStanding }> {\n const out: Array<{ role: SignatureRole; standing: RequiredStanding }> = [];\n if (operator !== 'notRequired')\n out.push({ role: 'operator', standing: operator });\n if (patient !== 'notRequired')\n out.push({ role: 'patient', standing: patient });\n if (secondary !== 'notRequired')\n out.push({ role: 'secondary', standing: secondary });\n return out;\n}\n\n/* ------------------------------------------------------------------ */\n/* Props */\n/* ------------------------------------------------------------------ */\n\nexport interface SignatureStatusChipProps extends Omit<\n HTMLAttributes<HTMLSpanElement>,\n 'children'\n> {\n /** The operator's standing. */\n operator: SignatureParty;\n /** The patient's standing. */\n patient: SignatureParty;\n /**\n * The second signee's standing on a two-signee envelope — a guardian,\n * parent or co-signer. Defaults to `notRequired`, so a document with only\n * an operator and a patient behaves exactly as before.\n */\n secondary?: SignatureParty;\n /**\n * Display names for the signers, keyed by role. Supply them and the\n * breakdown reads \"Operator: Dr Rossi (signed)\" instead of \"Operator\n * signed\"; omit them and only the roles are named.\n *\n * A role may be a bare name, or a {@link SignerIdentity} when someone\n * signs on that party's behalf — a parent for a minor, a guardian for an\n * adult who lacks capacity. Then the row reads \"Patient: M. Bianchi,\n * signed by A. Bianchi (Parent)\".\n *\n * A name is shown in the chip's accessible name and its hover title, so\n * pass one only where the viewer is already entitled to see that person —\n * these are real people, and on the patient row usually a patient. Roles\n * with no name fall back to the role alone, so a partial map is fine.\n */\n names?: SignatureSignerNames;\n /** Chip height — maps onto the Badge `sm` / `md` sizes. */\n size?: 'sm' | 'md';\n /**\n * Spell the breakdown in the chip text (\"Signed · Operator signed · Patient\n * signed\") instead of the summary word. Default false — the breakdown is\n * always in the accessible name / title.\n */\n detail?: boolean;\n /**\n * Make the breakdown reachable by keyboard and touch, not only on hover.\n *\n * The chip becomes focusable and the breakdown moves out of the accessible\n * name into the kit's `Tooltip`, which exposes it as the accessible\n * description. Screen readers then hear the summary once and the detail\n * once, instead of the whole string twice.\n *\n * Off by default for two reasons. It adds a tab stop, and a table of forty\n * chips should not add forty; and it **requires a `TooltipProvider` above\n * it** — without one the kit's Tooltip throws. Turn it on where the\n * breakdown is something the user has to act on.\n */\n tooltip?: boolean;\n /** Agent-readiness consumer id, surfaced as `data-component-id`. */\n id?: string;\n}\n\n/* ------------------------------------------------------------------ */\n/* Component */\n/* ------------------------------------------------------------------ */\n\nexport const SignatureStatusChip = forwardRef<\n HTMLSpanElement,\n SignatureStatusChipProps\n>(\n (\n {\n operator,\n patient,\n secondary = 'notRequired',\n names,\n size = 'md',\n detail = false,\n tooltip = false,\n id,\n className,\n 'aria-label': ariaLabelProp,\n title: titleProp,\n ...rest\n },\n ref,\n ) => {\n const { t } = useTranslation('ui');\n const status = signatureStatusOf(operator, patient, secondary, names);\n // Each party's standing is the effective one, so a slot held open by an\n // unsigned representative reads as pending here too.\n const parties = requiredParties(\n effectiveStanding(operator, names?.operator),\n effectiveStanding(patient, names?.patient),\n effectiveStanding(secondary, names?.secondary),\n );\n\n // When exactly one required party is outstanding the summary names it,\n // which is more use than a vague \"partially signed\". Two or more can be\n // outstanding once a second signee is in play, and then only the count\n // is worth the chip's width — the breakdown spells out the rest.\n // Two summaries, because a summary that is about to be followed by the\n // breakdown must not say what the breakdown is about to say. Alone, it\n // names the party that is missing, which is the useful half. Leading a\n // breakdown, it is the status word only — otherwise a detail chip read\n // \"Operator signature missing · Operator pending · Patient signed\",\n // naming the operator twice in one line.\n const summaryLead = (() => {\n switch (status) {\n case 'signed':\n return t('signatureStatusChip.signed', { defaultValue: 'Signed' });\n case 'unsigned':\n return t('signatureStatusChip.unsigned', {\n defaultValue: 'Not signed',\n });\n case 'notRequired':\n return t('signatureStatusChip.notRequired', {\n defaultValue: 'No signature required',\n });\n case 'partial':\n return t('signatureStatusChip.partial', {\n defaultValue: 'Partially signed',\n });\n }\n })();\n\n const summary = (() => {\n switch (status) {\n case 'signed':\n return t('signatureStatusChip.signed', { defaultValue: 'Signed' });\n case 'unsigned':\n return t('signatureStatusChip.unsigned', {\n defaultValue: 'Not signed',\n });\n case 'notRequired':\n return t('signatureStatusChip.notRequired', {\n defaultValue: 'No signature required',\n });\n case 'partial': {\n const pending = parties.filter((p) => p.standing === 'pending');\n if (pending.length === 1) {\n const role = pending[0].role;\n return t(MISSING_KEY[role], {\n defaultValue: MISSING_DEFAULT[role],\n });\n }\n return t('signatureStatusChip.missingCount', {\n defaultValue: '{{count}} signatures missing',\n count: pending.length,\n });\n }\n }\n })();\n\n // Two breakdowns, deliberately. The chip is a pill: its visible text\n // names roles only, so it stays the length it was before names existed.\n // Names go where there is room for them — the tooltip, or the accessible\n // name when there is no tooltip. A named three-party chip spelled out\n // visibly ran to 138 characters, which is a paragraph, not a chip.\n const buildBreakdown = (withNames: boolean) =>\n parties\n .map(({ role, standing }) => {\n const roleLabel = t(`signatureStatusChip.party.${role}`, {\n defaultValue: ROLE_DEFAULT[role],\n });\n const state = t(`signatureStatusChip.state.${standing}`, {\n defaultValue: STANDING_DEFAULT[standing],\n });\n const identity = withNames ? names?.[role] : undefined;\n if (!identity) {\n return t('signatureStatusChip.breakdownItem', {\n defaultValue: '{{party}} {{state}}',\n party: roleLabel,\n state,\n });\n }\n\n const who =\n typeof identity === 'string' ? { name: identity } : identity;\n\n // Someone signs in the party's place — name the party AND whoever\n // fills their slot, so the reader can see both. Several can be\n // required at once: both parents consenting for a minor.\n const reps = representativesOf(who);\n if (reps.length > 0) {\n const render = (r: SignerRepresentative) =>\n r.relationship\n ? t('signatureStatusChip.representative', {\n defaultValue: '{{name}} ({{relationship}})',\n name: isolate(r.name),\n relationship: r.relationship,\n })\n : isolate(r.name);\n\n // A representative with no standing of its own follows the party.\n const standingOf = (r: SignerRepresentative) =>\n r.standing ?? standing;\n const signed = reps.filter((r) => standingOf(r) === 'signed');\n const awaiting = reps.filter((r) => standingOf(r) === 'pending');\n\n const clauses: string[] = [];\n if (signed.length > 0)\n clauses.push(\n t('signatureStatusChip.signedByList', {\n defaultValue: 'signed by {{signers}}',\n signers: signed.map(render).join(', '),\n }),\n );\n if (awaiting.length > 0)\n clauses.push(\n t('signatureStatusChip.awaitingList', {\n defaultValue: 'awaiting {{signers}}',\n signers: awaiting.map(render).join(', '),\n }),\n );\n\n return t('signatureStatusChip.breakdownItemOnBehalf', {\n defaultValue: '{{party}}: {{name}}, {{detail}}',\n party: roleLabel,\n name: isolate(who.name),\n detail: clauses.join(', '),\n });\n }\n\n return t('signatureStatusChip.breakdownItemNamed', {\n defaultValue: '{{party}}: {{name}} ({{state}})',\n party: roleLabel,\n name: isolate(who.name),\n state,\n });\n })\n .join(' · ');\n\n const breakdownNamed = buildBreakdown(true);\n const breakdownRoles = buildBreakdown(false);\n\n // The full picture always reaches AT and hover, even in the compact form.\n const label = breakdownNamed\n ? `${summaryLead}, ${breakdownNamed}`\n : summary;\n // Visible text: roles only, never names.\n const visible =\n detail && breakdownRoles ? `${summaryLead} · ${breakdownRoles}` : summary;\n\n // With a tooltip the breakdown becomes the accessible DESCRIPTION, so the\n // name carries only the summary — otherwise assistive tech reads the same\n // detail twice. Without one, the name has to carry everything, because\n // there is nowhere else for it to go.\n const useTooltip = tooltip && breakdownNamed.length > 0;\n const accessibleName = ariaLabelProp ?? (useTooltip ? summary : label);\n\n const chip = (\n <Badge\n ref={ref}\n variant={STATUS_VARIANT[status]}\n size={size}\n withDot\n role=\"img\"\n // One source of truth: an overridden aria-label also becomes the\n // hover text, so the two can never drift apart.\n aria-label={accessibleName}\n // A native title alongside a Tooltip shows two overlapping bubbles,\n // so the Tooltip takes over entirely when it is on.\n title={useTooltip ? titleProp : (titleProp ?? accessibleName)}\n tabIndex={useTooltip ? 0 : undefined}\n data-component=\"signature-status-chip\"\n data-status={status}\n data-component-id={id}\n id={id}\n className={\n useTooltip\n ? [\n 'ds:rounded-[var(--radius-full)]',\n 'ds:focus-visible:outline-[length:var(--focus-ring-width)]',\n 'ds:focus-visible:outline-solid',\n 'ds:focus-visible:outline-ring',\n 'ds:focus-visible:outline-offset-[length:var(--focus-ring-offset)]',\n className,\n ]\n .filter(Boolean)\n .join(' ')\n : className\n }\n {...rest}\n >\n {visible}\n </Badge>\n );\n\n if (!useTooltip) return chip;\n\n // Radix's Trigger clones this element, so the chip itself is the trigger:\n // one element, focusable, with the focus ring following the pill shape.\n return <Tooltip label={breakdownNamed}>{chip}</Tooltip>;\n },\n);\n\nSignatureStatusChip.displayName = 'SignatureStatusChip';\n"],"names":["representativesOf","identity","by","effectiveStanding","party","reps","r","signatureStatusOf","operator","patient","secondary","names","required","p","signed","STATUS_VARIANT","ROLE_DEFAULT","STANDING_DEFAULT","MISSING_KEY","MISSING_DEFAULT","isolate","value","requiredParties","out","SignatureStatusChip","forwardRef","size","detail","tooltip","id","className","ariaLabelProp","titleProp","rest","ref","t","useTranslation","status","parties","summaryLead","summary","pending","role","buildBreakdown","withNames","standing","roleLabel","state","who","render","standingOf","awaiting","clauses","breakdownNamed","breakdownRoles","label","visible","useTooltip","accessibleName","chip","jsx","Badge","Tooltip"],"mappings":";;;;;AAoEA,SAASA,EACPC,GACwB;AACxB,MAAI,CAACA,KAAY,OAAOA,KAAa,iBAAiB,CAAA;AACtD,QAAMC,IAAKD,EAAS;AACpB,SAAKC,IACE,MAAM,QAAQA,CAAE,IAAIA,IAAK,CAACA,CAAE,IADnB,CAAA;AAElB;AAQO,SAASC,EACdC,GACAH,GACgB;AAChB,MAAIG,MAAU,cAAe,QAAO;AACpC,QAAMC,IAAOL,EAAkBC,CAAQ,EAAE,OAAO,CAACK,MAAMA,EAAE,QAAQ;AACjE,SAAID,EAAK,WAAW,IAAUD,IACvBC,EAAK,MAAM,CAACC,MAAMA,EAAE,aAAa,QAAQ,IAAI,WAAW;AACjE;AAmBO,SAASC,EACdC,GACAC,GACAC,IAA4B,eAC5BC,GACiB;AACjB,QAAMC,IAAW;AAAA,IACfT,EAAkBK,GAAUG,KAAA,gBAAAA,EAAO,QAAQ;AAAA,IAC3CR,EAAkBM,GAASE,KAAA,gBAAAA,EAAO,OAAO;AAAA,IACzCR,EAAkBO,GAAWC,KAAA,gBAAAA,EAAO,SAAS;AAAA,EAAA,EAC7C,OAAO,CAACE,MAAMA,MAAM,aAAa;AACnC,MAAID,EAAS,WAAW,EAAG,QAAO;AAClC,QAAME,IAASF,EAAS,OAAO,CAACC,MAAMA,MAAM,QAAQ,EAAE;AACtD,SAAIC,MAAW,IAAU,aAClBA,MAAWF,EAAS,SAAS,WAAW;AACjD;AAIA,MAAMG,IAGF;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|
1
|
-
import { useRef as I, useEffect as M, useState as F, useMemo as E, useCallback as s } from "react";
|
|
2
|
-
import { flushSync as R } from "react-dom";
|
|
3
|
-
function x(e) {
|
|
4
|
-
return e != null && e.current ? e.current : typeof document > "u" ? null : document;
|
|
5
|
-
}
|
|
6
|
-
function O(e, l) {
|
|
7
|
-
const c = typeof CSS < "u" && typeof CSS.escape == "function" ? CSS.escape(e) : (
|
|
8
|
-
// SSR / jsdom fallback — drop every character that's
|
|
9
|
-
// significant in a CSS attribute selector. Conservative but
|
|
10
|
-
// robust enough for the test environment.
|
|
11
|
-
e.replace(/["'\\[\]]/g, "")
|
|
12
|
-
), d = `[data-error-anchor="${c}"], [name="${c}"], [name$="[${c}]"]`, u = Array.from(l.querySelectorAll(d));
|
|
13
|
-
return u.length === 0 ? null : u.find((p) => p.offsetParent !== null) ?? u[0];
|
|
14
|
-
}
|
|
15
|
-
function $(e, l, c = {}) {
|
|
16
|
-
const {
|
|
17
|
-
scope: d,
|
|
18
|
-
scrollOptions: u = { behavior: "smooth", block: "center" },
|
|
19
|
-
focus: a = !0,
|
|
20
|
-
skipInitialMount: p = !0
|
|
21
|
-
} = c, o = I(!1), f = I(null), i = l.find((h) => !!e[h]) ?? null;
|
|
22
|
-
M(() => {
|
|
23
|
-
if (p && !o.current) {
|
|
24
|
-
o.current = !0, f.current = i;
|
|
25
|
-
return;
|
|
26
|
-
}
|
|
27
|
-
if (!i) {
|
|
28
|
-
f.current = null;
|
|
29
|
-
return;
|
|
30
|
-
}
|
|
31
|
-
if (i === f.current || typeof window > "u") return;
|
|
32
|
-
const h = window.requestAnimationFrame(() => {
|
|
33
|
-
const g = x(d);
|
|
34
|
-
if (!g) return;
|
|
35
|
-
const t = O(i, g);
|
|
36
|
-
t && (t.scrollIntoView(u), a && t.focus({ preventScroll: !0 }), f.current = i);
|
|
37
|
-
});
|
|
38
|
-
return () => window.cancelAnimationFrame(h);
|
|
39
|
-
}, [i]);
|
|
40
|
-
}
|
|
41
|
-
function k(e, l = !1) {
|
|
42
|
-
const c = {};
|
|
43
|
-
for (const d of e)
|
|
44
|
-
c[d.id] = { signed: l ? !1 : !!d.signed };
|
|
45
|
-
return c;
|
|
46
|
-
}
|
|
47
|
-
function D(e) {
|
|
48
|
-
const [l, c] = F(
|
|
49
|
-
() => k(e)
|
|
50
|
-
), [d, u] = F(null), [a, p] = F(
|
|
51
|
-
() => {
|
|
52
|
-
var n;
|
|
53
|
-
return ((n = e[0]) == null ? void 0 : n.id) ?? null;
|
|
54
|
-
}
|
|
55
|
-
), o = E(
|
|
56
|
-
() => e.map((n) => {
|
|
57
|
-
const r = l[n.id];
|
|
58
|
-
return {
|
|
59
|
-
...n,
|
|
60
|
-
signed: r ? r.signed : !!n.signed,
|
|
61
|
-
payload: r == null ? void 0 : r.payload
|
|
62
|
-
};
|
|
63
|
-
}),
|
|
64
|
-
[e, l]
|
|
65
|
-
), f = E(
|
|
66
|
-
() => o.reduce((n, r) => r.signed ? n + 1 : n, 0),
|
|
67
|
-
[o]
|
|
68
|
-
), i = o.length, h = i > 0 && f === i, g = s((n) => {
|
|
69
|
-
u(n);
|
|
70
|
-
}, []), t = s(() => {
|
|
71
|
-
u(null);
|
|
72
|
-
}, []), w = s((n, r) => {
|
|
73
|
-
c((m) => ({ ...m, [n]: { signed: !0, payload: r } })), u((m) => m === n ? null : m);
|
|
74
|
-
}, []), T = s(
|
|
75
|
-
(n) => {
|
|
76
|
-
var r;
|
|
77
|
-
return !!((r = l[n]) != null && r.signed);
|
|
78
|
-
},
|
|
79
|
-
[l]
|
|
80
|
-
), S = s(() => {
|
|
81
|
-
var n;
|
|
82
|
-
c(k(e, !0)), u(null), p(((n = e[0]) == null ? void 0 : n.id) ?? null);
|
|
83
|
-
}, [e]), C = s(() => {
|
|
84
|
-
p((n) => {
|
|
85
|
-
const r = o.length;
|
|
86
|
-
if (r === 0) return null;
|
|
87
|
-
const m = n ? o.findIndex((y) => y.id === n) : -1;
|
|
88
|
-
return o[(m + 1 + r) % r].id;
|
|
89
|
-
});
|
|
90
|
-
}, [o]), v = s(() => {
|
|
91
|
-
p((n) => {
|
|
92
|
-
const r = o.length;
|
|
93
|
-
if (r === 0) return null;
|
|
94
|
-
const m = n ? o.findIndex((y) => y.id === n) : 0;
|
|
95
|
-
return o[(m - 1 + r) % r].id;
|
|
96
|
-
});
|
|
97
|
-
}, [o]), A = s(() => {
|
|
98
|
-
p((n) => {
|
|
99
|
-
const r = o.length;
|
|
100
|
-
if (r === 0) return n;
|
|
101
|
-
const m = n ? o.findIndex((y) => y.id === n) : -1;
|
|
102
|
-
for (let y = 1; y <= r; y += 1) {
|
|
103
|
-
const b = o[(m + y) % r];
|
|
104
|
-
if (!b.signed) return b.id;
|
|
105
|
-
}
|
|
106
|
-
return n;
|
|
107
|
-
});
|
|
108
|
-
}, [o]);
|
|
109
|
-
return E(
|
|
110
|
-
() => ({
|
|
111
|
-
fields: o,
|
|
112
|
-
signedCount: f,
|
|
113
|
-
total: i,
|
|
114
|
-
isComplete: h,
|
|
115
|
-
activeFieldId: d,
|
|
116
|
-
openField: g,
|
|
117
|
-
closeField: t,
|
|
118
|
-
markSigned: w,
|
|
119
|
-
isFieldSigned: T,
|
|
120
|
-
reset: S,
|
|
121
|
-
cursorFieldId: a,
|
|
122
|
-
goToNextField: C,
|
|
123
|
-
goToPreviousField: v,
|
|
124
|
-
goToNextUnsigned: A
|
|
125
|
-
}),
|
|
126
|
-
[
|
|
127
|
-
o,
|
|
128
|
-
f,
|
|
129
|
-
i,
|
|
130
|
-
h,
|
|
131
|
-
d,
|
|
132
|
-
g,
|
|
133
|
-
t,
|
|
134
|
-
w,
|
|
135
|
-
T,
|
|
136
|
-
S,
|
|
137
|
-
a,
|
|
138
|
-
C,
|
|
139
|
-
v,
|
|
140
|
-
A
|
|
141
|
-
]
|
|
142
|
-
);
|
|
143
|
-
}
|
|
144
|
-
const q = "ds-zoom-drilldown", L = () => {
|
|
145
|
-
if (typeof document > "u") return null;
|
|
146
|
-
const e = document.querySelector("main");
|
|
147
|
-
return e ? e.querySelector("[data-radix-scroll-area-viewport]") ?? e.closest("[data-radix-scroll-area-viewport]") ?? e : null;
|
|
148
|
-
}, N = (e) => typeof e.startViewTransition == "function" && typeof CSS < "u" && typeof CSS.supports == "function" && CSS.supports("view-transition-class", q);
|
|
149
|
-
function P(e = {}) {
|
|
150
|
-
const [l, c] = F(null), d = I(
|
|
151
|
-
null
|
|
152
|
-
), u = I(e.getScrollContainer);
|
|
153
|
-
u.current = e.getScrollContainer;
|
|
154
|
-
const a = s(
|
|
155
|
-
() => (u.current ?? L)(),
|
|
156
|
-
[]
|
|
157
|
-
), p = s(() => {
|
|
158
|
-
const t = a();
|
|
159
|
-
return {
|
|
160
|
-
window: typeof window < "u" ? window.scrollY : 0,
|
|
161
|
-
container: t ? t.scrollTop : 0
|
|
162
|
-
};
|
|
163
|
-
}, [a]), o = s(() => {
|
|
164
|
-
const t = d.current;
|
|
165
|
-
if (!t) return;
|
|
166
|
-
d.current = null;
|
|
167
|
-
let w = 0;
|
|
168
|
-
const T = () => {
|
|
169
|
-
const S = a();
|
|
170
|
-
typeof window < "u" && window.scrollTo({ top: t.window }), S && (S.scrollTop = t.container), !((typeof window > "u" || Math.abs(window.scrollY - t.window) < 2) && (!S || Math.abs(S.scrollTop - t.container) < 2)) && w < 20 && (w += 1, requestAnimationFrame(T));
|
|
171
|
-
};
|
|
172
|
-
T();
|
|
173
|
-
}, [a]), f = s(() => {
|
|
174
|
-
const t = a();
|
|
175
|
-
typeof window < "u" && window.scrollTo({ top: 0 }), t && (t.scrollTop = 0);
|
|
176
|
-
}, [a]), i = s(
|
|
177
|
-
(t) => {
|
|
178
|
-
var v;
|
|
179
|
-
const w = document, T = typeof window < "u" && typeof window.matchMedia == "function" && window.matchMedia("(prefers-reduced-motion: reduce)").matches, S = t === null;
|
|
180
|
-
if (T || !N(w) || !w.startViewTransition) {
|
|
181
|
-
R(() => c(t)), S ? o() : f();
|
|
182
|
-
return;
|
|
183
|
-
}
|
|
184
|
-
const C = w.startViewTransition(() => {
|
|
185
|
-
R(() => c(t)), S || f();
|
|
186
|
-
});
|
|
187
|
-
S && ((v = C == null ? void 0 : C.finished) == null || v.then(o, o));
|
|
188
|
-
},
|
|
189
|
-
[o, f]
|
|
190
|
-
), h = s(
|
|
191
|
-
(t) => {
|
|
192
|
-
d.current = p(), i(t);
|
|
193
|
-
},
|
|
194
|
-
[p, i]
|
|
195
|
-
), g = s(() => i(null), [i]);
|
|
196
|
-
return M(() => {
|
|
197
|
-
if (l === null) return;
|
|
198
|
-
const t = (w) => {
|
|
199
|
-
w.key === "Escape" && !w.defaultPrevented && g();
|
|
200
|
-
};
|
|
201
|
-
return window.addEventListener("keydown", t), () => window.removeEventListener("keydown", t);
|
|
202
|
-
}, [l, g]), { selected: l, open: h, close: g };
|
|
203
|
-
}
|
|
204
|
-
export {
|
|
205
|
-
q as Z,
|
|
206
|
-
D as a,
|
|
207
|
-
P as b,
|
|
208
|
-
$ as u
|
|
209
|
-
};
|
|
210
|
-
//# sourceMappingURL=use-zoom-drilldown-qCX34w9I.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"use-zoom-drilldown-qCX34w9I.js","sources":["../../src/hooks/use-scroll-to-first-error.ts","../../src/hooks/use-signing-session.ts","../../src/hooks/use-zoom-drilldown.ts"],"sourcesContent":["import { useEffect, useRef, type RefObject } from 'react';\n\n/* -------------------------------------------------------------------- */\n/* Types */\n/* -------------------------------------------------------------------- */\n\nexport interface UseScrollToFirstErrorOptions {\n /**\n * Limits the DOM query to this element. Useful when the page renders\n * more than one form, or when an unrelated component happens to share\n * a field name. Defaults to `document`.\n */\n scope?: RefObject<HTMLElement | null>;\n /**\n * Forwarded to `scrollIntoView`. Defaults to\n * `{ behavior: 'smooth', block: 'center' }`. Pass\n * `{ behavior: 'auto' }` (or omit `behavior`) on consumers that\n * respect `prefers-reduced-motion` upstream — the kit doesn't shadow\n * the user's motion preference inside the hook, since some consumers\n * deliberately keep a near-instant snap for power-user form flows.\n */\n scrollOptions?: ScrollIntoViewOptions;\n /**\n * Move keyboard focus to the errored field after scrolling. Default\n * `true`. The focus call uses `preventScroll: true` so the smooth\n * scroll the hook just did isn't replaced by a snap.\n *\n * Setting this `false` defeats the keyboard-user side of WCAG 3.3.1\n * — the viewport will scroll but the active element stays on the\n * submit button, forcing a Shift+Tab back into the form. Only flip\n * this off when an upstream concern (e.g. a custom error summary\n * panel that owns its own focus) is taking responsibility.\n */\n focus?: boolean;\n /**\n * On the very first render, do nothing even if `errors` already has\n * entries. Default `true`. Without this the hook would yank the\n * viewport whenever a form is hydrated with server-rendered errors\n * from a no-JS fallback path — bad UX, since the user landed on the\n * page and hasn't asked for any movement yet. Set `false` only when\n * the consumer explicitly wants the initial-mount scroll (rare).\n */\n skipInitialMount?: boolean;\n}\n\n/* -------------------------------------------------------------------- */\n/* Helpers */\n/* -------------------------------------------------------------------- */\n\nfunction getScopeRoot(\n scope: RefObject<HTMLElement | null> | undefined,\n): ParentNode | null {\n if (scope?.current) return scope.current;\n if (typeof document === 'undefined') return null;\n return document;\n}\n\n/**\n * Resolve the DOM element to scroll/focus for a given errored field\n * name. The match order is:\n *\n * 1. `[data-error-anchor=\"<name>\"]` — the consumer's explicit hook,\n * used for Radix-based fields (Checkbox / Select / Switch) where\n * the named `<input>` is hidden behind a visible `<button>`.\n * Consumers set this on the trigger.\n * 2. `[name=\"<name>\"]` — the literal field name.\n * 3. `[name$=\"[<name>]\"]` — Symfony form-prefixed names like\n * `privacy_generator[fiscal_code]`. Suffix match keeps the hook\n * consumer-agnostic; no need to thread the form prefix through.\n *\n * Returns the first visible element among the matches. \"Visible\" here\n * means `offsetParent !== null` — that's the cheap heuristic Radix's\n * hidden inputs (display:none-equivalent positioning) fail and the\n * visible triggers pass. Falls back to the first match if every match\n * is hidden, so a field can still be scrolled into view even when the\n * trigger uses a non-standard layout.\n */\nfunction findErrorElement(name: string, root: ParentNode): HTMLElement | null {\n // `CSS.escape` is load-bearing here, not cosmetic. The Symfony\n // suffix-match arm embeds `name` inside `[name$=\"[${safe}]\"]`, so a\n // field name containing `]` would otherwise close the attribute\n // selector early and turn the rest of the string into stray\n // selector tokens. We don't expect adversarial input in practice\n // (server-controlled field names), but a server returning a `]`\n // in a 422 payload shouldn't be able to break the query.\n const safe =\n typeof CSS !== 'undefined' && typeof CSS.escape === 'function'\n ? CSS.escape(name)\n : // SSR / jsdom fallback — drop every character that's\n // significant in a CSS attribute selector. Conservative but\n // robust enough for the test environment.\n name.replace(/[\"'\\\\[\\]]/g, '');\n const selector =\n `[data-error-anchor=\"${safe}\"], ` +\n `[name=\"${safe}\"], ` +\n `[name$=\"[${safe}]\"]`;\n\n const matches = Array.from(root.querySelectorAll<HTMLElement>(selector));\n if (matches.length === 0) return null;\n\n const visible = matches.find((el) => el.offsetParent !== null);\n return visible ?? matches[0];\n}\n\n/* -------------------------------------------------------------------- */\n/* Hook */\n/* -------------------------------------------------------------------- */\n\n/**\n * Scrolls the first errored field into view and (by default) focuses\n * it, after `errors` changes. Backs the standard AlfaDocs rebrand\n * validation-error UX: after a 422 with `{ errors: { field: message } }`\n * is rendered inline, the user shouldn't be left staring at red labels\n * they can't see. Implements WCAG 3.3.1 / 3.3.3.\n *\n * The hook is stateless and never mutates the DOM beyond the\n * `scrollIntoView` + `focus` calls.\n *\n * @example\n * const fieldOrder = ['firstName', 'email', 'fiscalCode'] as const;\n * const [errors, setErrors] = useState<Record<string, string>>({});\n * useScrollToFirstError(errors, fieldOrder);\n *\n * @example Radix-based field\n * <Checkbox data-error-anchor=\"consent\" name=\"consent\" />\n * // hook scrolls to the visible <button>, not Radix's hidden input.\n *\n * @example Scoped to one form\n * const formRef = useRef<HTMLFormElement>(null);\n * useScrollToFirstError(errors, fieldOrder, { scope: formRef });\n */\nexport function useScrollToFirstError(\n errors: Readonly<Record<string, string | undefined>>,\n fieldOrder: ReadonlyArray<string>,\n options: UseScrollToFirstErrorOptions = {},\n): void {\n const {\n scope,\n scrollOptions = { behavior: 'smooth', block: 'center' },\n focus = true,\n skipInitialMount = true,\n } = options;\n\n // Single ref guards the initial-mount skip across StrictMode's\n // mount/unmount/remount cycle — flipped inside the effect body, not\n // in cleanup, so the second run sees `true` and stays gated.\n const ranOnceRef = useRef(false);\n\n // Track the previous \"first errored field name\" so a re-render that\n // leaves the same field errored doesn't re-scroll. We intentionally\n // depend on the resolved name (not the whole errors object) — that\n // way callers can mutate `errors` shape freely as long as the head\n // of the validation list is stable, which is the typical pattern\n // after a server returns the same 422 twice in a row.\n const lastScrolledFieldRef = useRef<string | null>(null);\n\n // Resolve the first errored field by visual order. A field is\n // \"errored\" iff its key has a truthy string value — the kit's form\n // contract is `Record<string, string | undefined>` where `undefined`\n // / missing keys mean \"no error\".\n const firstErroredField =\n fieldOrder.find((name) => Boolean(errors[name])) ?? null;\n\n useEffect(() => {\n if (skipInitialMount && !ranOnceRef.current) {\n ranOnceRef.current = true;\n // Record what we skipped so the next render doesn't try to\n // scroll to a field that was already errored at mount.\n lastScrolledFieldRef.current = firstErroredField;\n return;\n }\n\n if (!firstErroredField) {\n lastScrolledFieldRef.current = null;\n return;\n }\n\n if (firstErroredField === lastScrolledFieldRef.current) return;\n\n if (typeof window === 'undefined') return;\n\n // rAF defers the scroll until after the browser has laid out the\n // freshly-rendered error labels. Calling scrollIntoView synchronously\n // inside useEffect would fire before the new DOM is painted on\n // some browsers, leaving the viewport pointing at the old layout.\n const handle = window.requestAnimationFrame(() => {\n const root = getScopeRoot(scope);\n if (!root) return;\n const el = findErrorElement(firstErroredField, root);\n if (!el) return;\n\n el.scrollIntoView(scrollOptions);\n if (focus) {\n // preventScroll: true so the browser doesn't override the\n // smooth scroll above with a snap to put the element at the\n // top of the viewport.\n el.focus({ preventScroll: true });\n }\n lastScrolledFieldRef.current = firstErroredField;\n });\n\n return () => window.cancelAnimationFrame(handle);\n // `scrollOptions` / `focus` / `scope` / `skipInitialMount` are\n // option bag values — re-running on their identity change would\n // be surprising. The hook re-fires only when the field at the\n // head of the errored list changes.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [firstErroredField]);\n}\n","import { useCallback, useMemo, useState } from 'react';\n\n/* ------------------------------------------------------------------ */\n/* useSigningSession */\n/* */\n/* Orchestration state for a multi-field signing flow: N signature */\n/* fields across M pages (and optionally multiple PDFs per envelope), */\n/* a live \"X of Y signed\" counter, and a completion gate. Pure state — */\n/* no I/O, no globals, no persistence. The consumer owns the documents, */\n/* the capture UI, and where signatures are sent. */\n/* */\n/* Generic over the field shape (so geometry / page / docIndex / label */\n/* ride along untouched and `fields` can map straight onto SignatureField)*/\n/* and over the captured payload type (typically SignatureConfirmPayload).*/\n/* */\n/* The SET of field ids and their initial `signed` flags are captured at */\n/* first render — an envelope's fields are fixed for the session. Field */\n/* geometry/label changes still flow through `fields` on every render. */\n/* ------------------------------------------------------------------ */\n\n/** Minimum shape a signing field must satisfy. */\nexport interface SigningFieldBase {\n /** Stable, unique id for the field within the session. */\n id: string;\n /** Initial signed state (default `false`). */\n signed?: boolean;\n}\n\ninterface SignedEntry<TPayload> {\n signed: boolean;\n payload?: TPayload;\n}\n\n/** A consumer field enriched with the session's live signed state + payload. */\nexport type SigningField<TField extends SigningFieldBase, TPayload> = TField & {\n signed: boolean;\n payload?: TPayload;\n};\n\nexport interface UseSigningSessionReturn<\n TField extends SigningFieldBase,\n TPayload,\n> {\n /** The input fields, each enriched with live `signed` + `payload`. */\n fields: SigningField<TField, TPayload>[];\n /** How many fields are currently signed. */\n signedCount: number;\n /** Total number of fields. */\n total: number;\n /** True when every field is signed (and there is at least one). */\n isComplete: boolean;\n /** The field whose capture UI is currently open, or `null`. */\n activeFieldId: string | null;\n /** Open a field's capture UI (sets `activeFieldId`). */\n openField: (id: string) => void;\n /** Close any open capture UI (clears `activeFieldId`). */\n closeField: () => void;\n /** Flip a field to signed, storing its payload, and close it if active. */\n markSigned: (id: string, payload?: TPayload) => void;\n /** Read a single field's signed state. */\n isFieldSigned: (id: string) => boolean;\n /** Clear all signatures and close any open field. */\n reset: () => void;\n /** The field currently targeted by next/previous navigation, or `null`. */\n cursorFieldId: string | null;\n /** Move the navigation cursor to the next field (input order, cycling). */\n goToNextField: () => void;\n /** Move the navigation cursor to the previous field (cycling). */\n goToPreviousField: () => void;\n /** Move the cursor to the next still-unsigned field (cycling); no-op if all signed. */\n goToNextUnsigned: () => void;\n}\n\nfunction seedSigned<TField extends SigningFieldBase, TPayload>(\n fields: TField[],\n forceUnsigned = false,\n): Record<string, SignedEntry<TPayload>> {\n const map: Record<string, SignedEntry<TPayload>> = {};\n for (const field of fields) {\n map[field.id] = { signed: forceUnsigned ? false : Boolean(field.signed) };\n }\n return map;\n}\n\nexport function useSigningSession<\n TField extends SigningFieldBase,\n TPayload = unknown,\n>(fields: TField[]): UseSigningSessionReturn<TField, TPayload> {\n const [signed, setSigned] = useState<Record<string, SignedEntry<TPayload>>>(\n () => seedSigned<TField, TPayload>(fields),\n );\n const [activeFieldId, setActiveFieldId] = useState<string | null>(null);\n const [cursorFieldId, setCursorFieldId] = useState<string | null>(\n () => fields[0]?.id ?? null,\n );\n\n const enriched = useMemo<SigningField<TField, TPayload>[]>(\n () =>\n fields.map((field) => {\n const entry = signed[field.id];\n return {\n ...field,\n signed: entry ? entry.signed : Boolean(field.signed),\n payload: entry?.payload,\n };\n }),\n [fields, signed],\n );\n\n const signedCount = useMemo(\n () =>\n enriched.reduce((count, field) => (field.signed ? count + 1 : count), 0),\n [enriched],\n );\n const total = enriched.length;\n const isComplete = total > 0 && signedCount === total;\n\n const openField = useCallback((id: string) => {\n setActiveFieldId(id);\n }, []);\n\n const closeField = useCallback(() => {\n setActiveFieldId(null);\n }, []);\n\n const markSigned = useCallback((id: string, payload?: TPayload) => {\n setSigned((prev) => ({ ...prev, [id]: { signed: true, payload } }));\n setActiveFieldId((current) => (current === id ? null : current));\n }, []);\n\n const isFieldSigned = useCallback(\n (id: string) => Boolean(signed[id]?.signed),\n [signed],\n );\n\n const reset = useCallback(() => {\n setSigned(seedSigned<TField, TPayload>(fields, true));\n setActiveFieldId(null);\n setCursorFieldId(fields[0]?.id ?? null);\n }, [fields]);\n\n const goToNextField = useCallback(() => {\n setCursorFieldId((cur) => {\n const len = enriched.length;\n if (len === 0) return null;\n const i = cur ? enriched.findIndex((f) => f.id === cur) : -1;\n return enriched[(i + 1 + len) % len].id;\n });\n }, [enriched]);\n\n const goToPreviousField = useCallback(() => {\n setCursorFieldId((cur) => {\n const len = enriched.length;\n if (len === 0) return null;\n const i = cur ? enriched.findIndex((f) => f.id === cur) : 0;\n return enriched[(i - 1 + len) % len].id;\n });\n }, [enriched]);\n\n const goToNextUnsigned = useCallback(() => {\n setCursorFieldId((cur) => {\n const len = enriched.length;\n if (len === 0) return cur;\n const start = cur ? enriched.findIndex((f) => f.id === cur) : -1;\n for (let step = 1; step <= len; step += 1) {\n const field = enriched[(start + step) % len];\n if (!field.signed) return field.id;\n }\n return cur;\n });\n }, [enriched]);\n\n return useMemo(\n () => ({\n fields: enriched,\n signedCount,\n total,\n isComplete,\n activeFieldId,\n openField,\n closeField,\n markSigned,\n isFieldSigned,\n reset,\n cursorFieldId,\n goToNextField,\n goToPreviousField,\n goToNextUnsigned,\n }),\n [\n enriched,\n signedCount,\n total,\n isComplete,\n activeFieldId,\n openField,\n closeField,\n markSigned,\n isFieldSigned,\n reset,\n cursorFieldId,\n goToNextField,\n goToPreviousField,\n goToNextUnsigned,\n ],\n );\n}\n","// Expand-from-position drill-down: wraps the View Transitions API with a\n// feature-detect, a reduced-motion fallback, Esc-to-close and scroll restore.\n// Animation rules ship in ./use-zoom-drilldown.css (folded into tokens.css).\nimport { useCallback, useEffect, useRef, useState } from 'react';\nimport { flushSync } from 'react-dom';\n\n/**\n * The `view-transition-class` the shipped CSS targets. Add it as a class name\n * to the source element and the detail, next to their shared\n * `view-transition-name`. The kit sheet maps the class to the property.\n */\nexport const ZOOM_DRILLDOWN_TRANSITION_CLASS = 'ds-zoom-drilldown' as const;\n\nexport interface UseZoomDrilldownOptions {\n /** Resolver for the scroll container whose scrollTop should be preserved\n * across the transition. Defaults to the nearest `<main>` element in\n * the document (or the Radix ScrollArea viewport around it). The window\n * scroll position is always tracked alongside. */\n getScrollContainer?: () => HTMLElement | null;\n}\n\nexport interface UseZoomDrilldownReturn<Id extends string> {\n /** The open drill-down target, or `null` while the source view shows. */\n readonly selected: Id | null;\n /** Zoom into `id`: saves the scroll position and enters at the top. */\n readonly open: (id: Id) => void;\n /** Zoom back out and restore the saved scroll position. */\n readonly close: () => void;\n}\n\ntype DocumentWithViewTransitions = Document & {\n startViewTransition?: (callback: () => void) => { finished?: Promise<void> };\n};\n\nconst defaultGetScrollContainer = (): HTMLElement | null => {\n if (typeof document === 'undefined') return null;\n const main = document.querySelector<HTMLElement>('main');\n if (!main) return null;\n // AppFrame layouts scroll a ScrollArea VIEWPORT rather than <main> itself.\n return (\n main.querySelector<HTMLElement>('[data-radix-scroll-area-viewport]') ??\n main.closest<HTMLElement>('[data-radix-scroll-area-viewport]') ??\n main\n );\n};\n\n// The scoped CSS only matches where `view-transition-class` is supported.\n// Elsewhere the UA default animation would ignore --animation-duration (and\n// the accessible themes' 0ms), so those browsers get the instant swap too.\nconst canAnimate = (doc: DocumentWithViewTransitions): boolean =>\n typeof doc.startViewTransition === 'function' &&\n typeof CSS !== 'undefined' &&\n typeof CSS.supports === 'function' &&\n CSS.supports('view-transition-class', ZOOM_DRILLDOWN_TRANSITION_CLASS);\n\nexport function useZoomDrilldown<Id extends string>(\n options: UseZoomDrilldownOptions = {},\n): UseZoomDrilldownReturn<Id> {\n const [selected, setSelected] = useState<Id | null>(null);\n // Captured on open(), restored after close() settles.\n const savedScrollRef = useRef<{ window: number; container: number } | null>(\n null,\n );\n // Through a ref so an inline resolver does not give open/close a new\n // identity on every render (and re-attach the Escape listener with it).\n const resolverRef = useRef(options.getScrollContainer);\n resolverRef.current = options.getScrollContainer;\n const getScrollContainer = useCallback(\n () => (resolverRef.current ?? defaultGetScrollContainer)(),\n [],\n );\n\n const readScroll = useCallback(() => {\n const containerEl = getScrollContainer();\n return {\n window: typeof window !== 'undefined' ? window.scrollY : 0,\n container: containerEl ? containerEl.scrollTop : 0,\n };\n }, [getScrollContainer]);\n\n const restoreScroll = useCallback(() => {\n const saved = savedScrollRef.current;\n if (!saved) return;\n savedScrollRef.current = null;\n // Async content can still be growing the page, so a single scrollTo may\n // clamp short. Re-apply over a few frames until it sticks.\n let tries = 0;\n const apply = () => {\n const containerEl = getScrollContainer();\n if (typeof window !== 'undefined') {\n window.scrollTo({ top: saved.window });\n }\n if (containerEl) containerEl.scrollTop = saved.container;\n const settled =\n (typeof window === 'undefined' ||\n Math.abs(window.scrollY - saved.window) < 2) &&\n (!containerEl || Math.abs(containerEl.scrollTop - saved.container) < 2);\n if (!settled && tries < 20) {\n tries += 1;\n requestAnimationFrame(apply);\n }\n };\n apply();\n }, [getScrollContainer]);\n\n // A drill-down always enters at its top, not at the depth scrolled behind it.\n const scrollToTop = useCallback(() => {\n const containerEl = getScrollContainer();\n if (typeof window !== 'undefined') window.scrollTo({ top: 0 });\n if (containerEl) containerEl.scrollTop = 0;\n }, [getScrollContainer]);\n\n const transition = useCallback(\n (next: Id | null) => {\n const doc = document as DocumentWithViewTransitions;\n const reduce =\n typeof window !== 'undefined' &&\n typeof window.matchMedia === 'function' &&\n window.matchMedia('(prefers-reduced-motion: reduce)').matches;\n const isClosing = next === null;\n if (reduce || !canAnimate(doc) || !doc.startViewTransition) {\n flushSync(() => setSelected(next));\n if (isClosing) restoreScroll();\n else scrollToTop();\n return;\n }\n const vt = doc.startViewTransition(() => {\n flushSync(() => setSelected(next));\n // Inside the callback so the new view is captured already at its top.\n if (!isClosing) scrollToTop();\n });\n if (isClosing) {\n vt?.finished?.then(restoreScroll, restoreScroll);\n }\n },\n [restoreScroll, scrollToTop],\n );\n\n const open = useCallback(\n (id: Id) => {\n savedScrollRef.current = readScroll();\n transition(id);\n },\n [readScroll, transition],\n );\n const close = useCallback(() => transition(null), [transition]);\n\n useEffect(() => {\n if (selected === null) return;\n const onKey = (event: KeyboardEvent) => {\n // An overlay inside the detail (Radix Select, Popover, Dialog) calls\n // preventDefault when Escape dismisses it: leave the drill-down open.\n if (event.key === 'Escape' && !event.defaultPrevented) close();\n };\n window.addEventListener('keydown', onKey);\n return () => window.removeEventListener('keydown', onKey);\n }, [selected, close]);\n\n return { selected, open, close };\n}\n"],"names":["getScopeRoot","scope","findErrorElement","name","root","safe","selector","matches","el","useScrollToFirstError","errors","fieldOrder","options","scrollOptions","focus","skipInitialMount","ranOnceRef","useRef","lastScrolledFieldRef","firstErroredField","useEffect","handle","seedSigned","fields","forceUnsigned","map","field","useSigningSession","signed","setSigned","useState","activeFieldId","setActiveFieldId","cursorFieldId","setCursorFieldId","_a","enriched","useMemo","entry","signedCount","count","total","isComplete","openField","useCallback","id","closeField","markSigned","payload","prev","current","isFieldSigned","reset","goToNextField","cur","len","i","f","goToPreviousField","goToNextUnsigned","start","step","ZOOM_DRILLDOWN_TRANSITION_CLASS","defaultGetScrollContainer","main","canAnimate","doc","useZoomDrilldown","selected","setSelected","savedScrollRef","resolverRef","getScrollContainer","readScroll","containerEl","restoreScroll","saved","tries","apply","scrollToTop","transition","next","reduce","isClosing","flushSync","vt","open","close","onKey","event"],"mappings":";;AAiDA,SAASA,EACPC,GACmB;AACnB,SAAIA,KAAA,QAAAA,EAAO,UAAgBA,EAAM,UAC7B,OAAO,WAAa,MAAoB,OACrC;AACT;AAsBA,SAASC,EAAiBC,GAAcC,GAAsC;AAQ5E,QAAMC,IACJ,OAAO,MAAQ,OAAe,OAAO,IAAI,UAAW,aAChD,IAAI,OAAOF,CAAI;AAAA;AAAA;AAAA;AAAA,IAIfA,EAAK,QAAQ,cAAc,EAAE;AAAA,KAC7BG,IACJ,uBAAuBD,CAAI,cACjBA,CAAI,gBACFA,CAAI,OAEZE,IAAU,MAAM,KAAKH,EAAK,iBAA8BE,CAAQ,CAAC;AACvE,SAAIC,EAAQ,WAAW,IAAU,OAE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Mf,EAAYY,CAAI,CAAC,GAC7BE,IAAWR,EAAA,IACVI,EAAA;AACL;AAAA,MACF;AACA,YAAMM,IAAKnB,EAAI,oBAAoB,MAAM;AACvC,QAAAkB,EAAU,MAAMf,EAAYY,CAAI,CAAC,GAE5BE,KAAWJ,EAAA;AAAA,MAClB,CAAC;AACD,MAAII,OACFhD,IAAAkD,KAAA,gBAAAA,EAAI,aAAJ,QAAAlD,EAAc,KAAKwC,GAAeA;AAAA,IAEtC;AAAA,IACA,CAACA,GAAeI,CAAW;AAAA,EAAA,GAGvBO,IAAO1C;AAAA,IACX,CAACC,MAAW;AACV,MAAAyB,EAAe,UAAUG,EAAA,GACzBO,EAAWnC,CAAE;AAAA,IACf;AAAA,IACA,CAAC4B,GAAYO,CAAU;AAAA,EAAA,GAEnBO,IAAQ3C,EAAY,MAAMoC,EAAW,IAAI,GAAG,CAACA,CAAU,CAAC;AAE9D,SAAA5D,EAAU,MAAM;AACd,QAAIgD,MAAa,KAAM;AACvB,UAAMoB,IAAQ,CAACC,MAAyB;AAGtC,MAAIA,EAAM,QAAQ,YAAY,CAACA,EAAM,oBAAkBF,EAAA;AAAA,IACzD;AACA,kBAAO,iBAAiB,WAAWC,CAAK,GACjC,MAAM,OAAO,oBAAoB,WAAWA,CAAK;AAAA,EAC1D,GAAG,CAACpB,GAAUmB,CAAK,CAAC,GAEb,EAAE,UAAAnB,GAAU,MAAAkB,GAAM,OAAAC,EAAA;AAC3B;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"user-x-DYszNtIg.js","sources":["../../node_modules/lucide-react/dist/esm/icons/ban.mjs","../../node_modules/lucide-react/dist/esm/icons/thumbs-up.mjs","../../node_modules/lucide-react/dist/esm/icons/user-x.mjs"],"sourcesContent":["/**\n * @license lucide-react v1.22.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.mjs';\n\nconst __iconNode = [\n [\"circle\", { cx: \"12\", cy: \"12\", r: \"10\", key: \"1mglay\" }],\n [\"path\", { d: \"M4.929 4.929 19.07 19.071\", key: \"196cmz\" }]\n];\nconst Ban = createLucideIcon(\"ban\", __iconNode);\n\nexport { __iconNode, Ban as default };\n//# sourceMappingURL=ban.mjs.map\n","/**\n * @license lucide-react v1.22.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.mjs';\n\nconst __iconNode = [\n [\n \"path\",\n {\n d: \"M15 5.88 14 10h5.83a2 2 0 0 1 1.92 2.56l-2.33 8A2 2 0 0 1 17.5 22H4a2 2 0 0 1-2-2v-8a2 2 0 0 1 2-2h2.76a2 2 0 0 0 1.79-1.11L12 2a3.13 3.13 0 0 1 3 3.88Z\",\n key: \"emmmcr\"\n }\n ],\n [\"path\", { d: \"M7 10v12\", key: \"1qc93n\" }]\n];\nconst ThumbsUp = createLucideIcon(\"thumbs-up\", __iconNode);\n\nexport { __iconNode, ThumbsUp as default };\n//# sourceMappingURL=thumbs-up.mjs.map\n","/**\n * @license lucide-react v1.22.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.mjs';\n\nconst __iconNode = [\n [\"path\", { d: \"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2\", key: \"1yyitq\" }],\n [\"circle\", { cx: \"9\", cy: \"7\", r: \"4\", key: \"nufk8\" }],\n [\"line\", { x1: \"17\", x2: \"22\", y1: \"8\", y2: \"13\", key: \"3nzzx3\" }],\n [\"line\", { x1: \"22\", x2: \"17\", y1: \"8\", y2: \"13\", key: \"1swrse\" }]\n];\nconst UserX = createLucideIcon(\"user-x\", __iconNode);\n\nexport { __iconNode, UserX as default };\n//# sourceMappingURL=user-x.mjs.map\n"],"names":["__iconNode","Ban","createLucideIcon","ThumbsUp","UserX"],"mappings":";AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AASA,MAAMA,IAAa;AAAA,EACjB,CAAC,UAAU,EAAE,IAAI,MAAM,IAAI,MAAM,GAAG,MAAM,KAAK,UAAU;AAAA,EACzD,CAAC,QAAQ,EAAE,GAAG,6BAA6B,KAAK,SAAQ,CAAE;AAC5D,GACMC,IAAMC,EAAiB,OAAOF,CAAU;ACb9C;AAAA;AAAA;AAAA;AAAA;AAAA;AASA,MAAMA,IAAa;AAAA,EACjB;AAAA,IACE;AAAA,IACA;AAAA,MACE,GAAG;AAAA,MACH,KAAK;AAAA,IACX;AAAA,EACA;AAAA,EACE,CAAC,QAAQ,EAAE,GAAG,YAAY,KAAK,SAAQ,CAAE;AAC3C,GACMG,IAAWD,EAAiB,aAAaF,CAAU;ACnBzD;AAAA;AAAA;AAAA;AAAA;AAAA;AASA,MAAMA,IAAa;AAAA,EACjB,CAAC,QAAQ,EAAE,GAAG,6CAA6C,KAAK,SAAQ,CAAE;AAAA,EAC1E,CAAC,UAAU,EAAE,IAAI,KAAK,IAAI,KAAK,GAAG,KAAK,KAAK,SAAS;AAAA,EACrD,CAAC,QAAQ,EAAE,IAAI,MAAM,IAAI,MAAM,IAAI,KAAK,IAAI,MAAM,KAAK,SAAQ,CAAE;AAAA,EACjE,CAAC,QAAQ,EAAE,IAAI,MAAM,IAAI,MAAM,IAAI,KAAK,IAAI,MAAM,KAAK,SAAQ,CAAE;AACnE,GACMI,IAAQF,EAAiB,UAAUF,CAAU;","x_google_ignoreList":[0,1,2]}
|