@hubsync/esign-web-sdk 6.9.44 → 6.9.45
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/cjs/loader.cjs.js +1 -1
- package/dist/cjs/verdocs-adopt-signature-dialog.verdocs-delegate-dialog.verdocs-disclosure-dialog.verdocs-kba-dialog.verdocs-otp-dialog.verdocs-passcode-dialog.verdocs-signing-progress.verdocs-view.entry.cjs.js.map +1 -1
- package/dist/cjs/verdocs-adopt-signature-dialog_8.cjs.entry.js +33 -6
- package/dist/cjs/verdocs-sign.cjs.entry.js +52 -2
- package/dist/cjs/verdocs-sign.entry.cjs.js.map +1 -1
- package/dist/cjs/verdocs-web-sdk.cjs.js +1 -1
- package/dist/collection/components/dialogs/verdocs-adopt-signature-dialog/verdocs-adopt-signature-dialog.js +87 -11
- package/dist/collection/components/dialogs/verdocs-adopt-signature-dialog/verdocs-adopt-signature-dialog.js.map +1 -1
- package/dist/collection/components/embeds/verdocs-sign/verdocs-sign.js +54 -2
- package/dist/collection/components/embeds/verdocs-sign/verdocs-sign.js.map +1 -1
- package/dist/components/{p-DSzyP6KP.js → p-DFsjkMkI.js} +37 -8
- package/dist/components/p-DFsjkMkI.js.map +1 -0
- package/dist/components/verdocs-adopt-signature-dialog.js +1 -1
- package/dist/components/verdocs-sign.js +55 -3
- package/dist/components/verdocs-sign.js.map +1 -1
- package/dist/custom-elements.json +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/verdocs-adopt-signature-dialog.verdocs-delegate-dialog.verdocs-disclosure-dialog.verdocs-kba-dialog.verdocs-otp-dialog.verdocs-passcode-dialog.verdocs-signing-progress.verdocs-view.entry.js.map +1 -1
- package/dist/esm/verdocs-adopt-signature-dialog_8.entry.js +33 -6
- package/dist/esm/verdocs-sign.entry.js +52 -2
- package/dist/esm/verdocs-sign.entry.js.map +1 -1
- package/dist/esm/verdocs-web-sdk.js +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/verdocs-adopt-signature-dialog.verdocs-delegate-dialog.verdocs-disclosure-dialog.verdocs-kba-dialog.verdocs-otp-dialog.verdocs-passcode-dialog.verdocs-signing-progress.verdocs-view.entry.js.map +1 -1
- package/dist/esm-es5/verdocs-adopt-signature-dialog_8.entry.js +1 -1
- package/dist/esm-es5/verdocs-adopt-signature-dialog_8.entry.js.map +1 -1
- package/dist/esm-es5/verdocs-sign.entry.js +1 -1
- package/dist/esm-es5/verdocs-sign.entry.js.map +1 -1
- package/dist/esm-es5/verdocs-web-sdk.js +1 -1
- package/dist/types/components/dialogs/verdocs-adopt-signature-dialog/verdocs-adopt-signature-dialog.d.ts +30 -3
- package/dist/types/components/embeds/verdocs-sign/verdocs-sign.d.ts +13 -0
- package/dist/types/components.d.ts +35 -5
- package/dist/verdocs-web-sdk/p-3832868c.entry.js +2 -0
- package/dist/verdocs-web-sdk/p-3832868c.entry.js.map +1 -0
- package/dist/verdocs-web-sdk/p-B8zpaHu-.system.js +1 -1
- package/dist/verdocs-web-sdk/p-BEzGtFgy.system.js.map +1 -0
- package/dist/verdocs-web-sdk/p-CCpu7MXO.system.js.map +1 -0
- package/dist/verdocs-web-sdk/p-c67b23fc.system.entry.js +2 -0
- package/dist/verdocs-web-sdk/p-c67b23fc.system.entry.js.map +1 -0
- package/dist/verdocs-web-sdk/p-ec29782b.entry.js +2 -0
- package/dist/verdocs-web-sdk/p-ec29782b.entry.js.map +1 -0
- package/dist/verdocs-web-sdk/p-fe804f97.system.entry.js +2 -0
- package/dist/verdocs-web-sdk/p-fe804f97.system.entry.js.map +1 -0
- package/dist/verdocs-web-sdk/verdocs-adopt-signature-dialog.verdocs-delegate-dialog.verdocs-disclosure-dialog.verdocs-kba-dialog.verdocs-otp-dialog.verdocs-passcode-dialog.verdocs-signing-progress.verdocs-view.entry.esm.js.map +1 -1
- package/dist/verdocs-web-sdk/verdocs-sign.entry.esm.js.map +1 -1
- package/dist/verdocs-web-sdk/verdocs-web-sdk.esm.js +1 -1
- package/package.json +1 -1
- package/dist/components/p-DSzyP6KP.js.map +0 -1
- package/dist/verdocs-web-sdk/p-7a0f0515.entry.js +0 -2
- package/dist/verdocs-web-sdk/p-7a0f0515.entry.js.map +0 -1
- package/dist/verdocs-web-sdk/p-965a8331.entry.js +0 -2
- package/dist/verdocs-web-sdk/p-965a8331.entry.js.map +0 -1
- package/dist/verdocs-web-sdk/p-CSd2l4lv.system.js.map +0 -1
- package/dist/verdocs-web-sdk/p-cbae68bb.system.entry.js +0 -2
- package/dist/verdocs-web-sdk/p-cbae68bb.system.entry.js.map +0 -1
- package/dist/verdocs-web-sdk/p-dx3XIcHV.system.js.map +0 -1
- package/dist/verdocs-web-sdk/p-ff5f20c9.system.entry.js +0 -2
- package/dist/verdocs-web-sdk/p-ff5f20c9.system.entry.js.map +0 -1
|
@@ -19,7 +19,7 @@ var patchBrowser = () => {
|
|
|
19
19
|
|
|
20
20
|
patchBrowser().then(async (options) => {
|
|
21
21
|
await appGlobals.globalScripts();
|
|
22
|
-
return index.bootstrapLazy(JSON.parse("[[\"verdocs-build.cjs\",[[256,\"verdocs-build\",{\"endpoint\":[16],\"templateId\":[1537,\"template-id\"],\"step\":[1537],\"loading\":[32],\"template\":[32]},null,{\"templateId\":[\"onTemplateIdChanged\"],\"step\":[\"onStepChanged\"]}]]],[\"verdocs-sign.cjs\",[[256,\"verdocs-sign\",{\"endpoint\":[1040],\"envelopeId\":[513,\"envelope-id\"],\"roleId\":[513,\"role-id\"],\"inviteCode\":[513,\"invite-code\"],\"headerTargetId\":[1,\"header-target-id\"],\"toolbarStyle\":[1,\"toolbar-style\"],\"autoAcceptDisclosures\":[4,\"auto-accept-disclosures\"],\"recipient\":[32],\"hasSignature\":[32],\"nextButtonLabel\":[32],\"nextSubmits\":[32],\"fatalErrorHeader\":[32],\"fatalErrorMessage\":[32],\"focusedField\":[32],\"disclosures\":[32],\"fieldUpdateCounter\":[32],\"submitting\":[32],\"submitted\":[32],\"isDone\":[32],\"showDone\":[32],\"adoptingSignature\":[32],\"showLoadError\":[32],\"finishLater\":[32],\"showFinishLater\":[32],\"agreed\":[32],\"signatureId\":[32],\"initialId\":[32],\"signatureAdoptMode\":[32],\"adoptedSignaturePreview\":[32],\"adoptedInitialsPreview\":[32],\"adoptedName\":[32],\"skippedFields\":[32],\"documentsSingularPlural\":[32],\"authStep\":[32],\"authMethodStates\":[32],\"pageNumber\":[32],\"kbaQuestions\":[32],\"showSpinner\":[32],\"declining\":[32],\"delegating\":[32],\"delegated\":[32],\"kbaChoices\":[32],\"showDownloadDialog\":[32],\"loading\":[32],\"envelope\":[32],\"zoomLevel\":[32],\"signingProgressMode\":[32],\"polling\":[32]}]]],[\"verdocs-envelopes-list.cjs\",[[256,\"verdocs-envelopes-list\",{\"endpoint\":[16],\"view\":[1537],\"status\":[1537],\"sort\":[1537],\"match\":[1537],\"showPagination\":[4,\"show-pagination\"],\"rowsPerPage\":[2,\"rows-per-page\"],\"selectedPage\":[2,\"selected-page\"],\"count\":[32],\"initiallyLoaded\":[32],\"loading\":[32],\"selectedEnvelopes\":[32],\"envelopes\":[32]},null,{\"view\":[\"handleViewUpdated\"],\"status\":[\"handleStatusUpdated\"],\"sort\":[\"handleSortUpdated\"],\"match\":[\"handleMatchUpdated\"],\"selectedPage\":[\"handlePageUpdated\"]}]]],[\"verdocs-templates-list.cjs\",[[256,\"verdocs-templates-list\",{\"endpoint\":[16],\"visibility\":[1537],\"starred\":[1537],\"sort\":[1537],\"name\":[1537],\"allowedActions\":[1040],\"showPagination\":[4,\"show-pagination\"],\"rowsPerPage\":[2,\"rows-per-page\"],\"selectedPage\":[2,\"selected-page\"],\"count\":[32],\"initiallyLoaded\":[32],\"loading\":[32],\"confirmDelete\":[32],\"templates\":[32],\"localNameFilter\":[32]},null,{\"sharing\":[\"handleSharingUpdated\"],\"starred\":[\"handleStarredUpdated\"],\"sort\":[\"handleSortUpdated\"],\"name\":[\"handleNameUpdated\"],\"selectedPage\":[\"handlePageUpdated\"]}]]],[\"verdocs-envelope-sidebar.cjs\",[[256,\"verdocs-envelope-sidebar\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"activeTab\":[32],\"panelOpen\":[32],\"showRecipientDialog\":[32],\"showCancelDialog\":[32],\"showReinviteDialog\":[32],\"showUpdateDialog\":[32],\"remindersEnabled\":[32],\"updatingReminders\":[32],\"initialReminder\":[32],\"followupReminders\":[32],\"loading\":[32],\"envelope\":[32]}]]],[\"verdocs-field-payment.cjs\",[[256,\"verdocs-field-payment\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"disabled\":[516],\"done\":[516],\"editable\":[516],\"moveable\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"fields\":[16],\"pageNum\":[2,\"page-num\"],\"roleName\":[1,\"role-name\"],\"fieldId\":[1,\"field-id\"],\"recipients\":[8],\"selectedRoleName\":[1,\"selected-role-name\"],\"pdfPages\":[16],\"currentSignature\":[1,\"current-signature\"],\"currentSignatureId\":[1,\"current-signature-id\"],\"currentInitial\":[1,\"current-initial\"],\"currentInitialId\":[1,\"current-initial-id\"],\"signed\":[4],\"roleindex\":[2],\"showingProperties\":[32],\"focused\":[32],\"preparedMessage\":[32],\"signatureUrl\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[0,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}]]],[\"verdocs-template-settings.cjs\",[[256,\"verdocs-template-settings\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"name\":[32],\"visibility\":[32],\"sender\":[32],\"sendReminders\":[32],\"initialReminder\":[32],\"followupReminders\":[32],\"dirty\":[32],\"loading\":[32],\"template\":[32]}]]],[\"verdocs-template-create.cjs\",[[256,\"verdocs-template-create\",{\"endpoint\":[16],\"maxSize\":[1026,\"max-size\"],\"file\":[32],\"creating\":[32],\"progressLabel\":[32],\"progressPercent\":[32],\"errorMessage\":[32]}]]],[\"verdocs-auth.cjs\",[[256,\"verdocs-auth\",{\"endpoint\":[16],\"visible\":[4],\"logo\":[1],\"displayMode\":[1025,\"display-mode\"],\"org_name\":[32],\"first_name\":[32],\"last_name\":[32],\"email\":[32],\"phone\":[32],\"verificationCode\":[32],\"newPassword\":[32],\"password\":[32],\"confirmpass\":[32],\"submitting\":[32],\"resendDisabled\":[32],\"session\":[32],\"profile\":[32]}]]],[\"verdocs-initial-dialog.cjs\",[[256,\"verdocs-initial-dialog\",{\"initials\":[1],\"fontLoaded\":[32],\"enteredInitials\":[32],\"mode\":[32]}]]],[\"verdocs-signature-dialog.cjs\",[[256,\"verdocs-signature-dialog\",{\"name\":[1],\"fontLoaded\":[32],\"enteredName\":[32],\"mode\":[32],\"isDrawing\":[32],\"hasDrawnSignature\":[32],\"hasUploadedImage\":[32],\"uploadedFileName\":[32]}]]],[\"verdocs-date-input.cjs\",[[256,\"verdocs-date-input\",{\"value\":[1537],\"label\":[1],\"placeholder\":[1],\"helpText\":[1,\"help-text\"],\"disabled\":[4],\"required\":[4],\"showingPw\":[32],\"focused\":[32],\"containerId\":[32],\"focusField\":[64]}]]],[\"verdocs-envelope-recipient-summary.cjs\",[[256,\"verdocs-envelope-recipient-summary\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"canSendAnother\":[4,\"can-send-another\"],\"canView\":[4,\"can-view\"],\"canDone\":[4,\"can-done\"],\"isOpen\":[32],\"recipientStatusIcons\":[32],\"containerId\":[32],\"gettingLinks\":[32],\"links\":[32],\"loading\":[32],\"envelope\":[32]}]]],[\"verdocs-multiselect.cjs\",[[256,\"verdocs-multiselect\",{\"label\":[1],\"placeholder\":[1],\"options\":[16],\"selectedOptions\":[16],\"showPicker\":[32]}]]],[\"verdocs-button-panel.cjs\",[[260,\"verdocs-button-panel\",{\"icon\":[1],\"showPanel\":[64],\"hidePanel\":[64],\"toggle\":[64]}]]],[\"verdocs-quick-functions.cjs\",[[256,\"verdocs-quick-functions\",{\"endpoint\":[16]}]]],[\"verdocs-search-box.cjs\",[[256,\"verdocs-search-box\",{\"endpoint\":[16],\"placeholder\":[1],\"type\":[1],\"query\":[1],\"grabsFocus\":[4,\"grabs-focus\"],\"focusField\":[64]}]]],[\"verdocs-search-tabs.cjs\",[[256,\"verdocs-search-tabs\",{\"selected\":[32]}]]],[\"verdocs-table.cjs\",[[256,\"verdocs-table\",{\"columns\":[16],\"data\":[16]}]]],[\"verdocs-tabs.cjs\",[[260,\"verdocs-tabs\",{\"tabs\":[16],\"selectedTab\":[2,\"selected-tab\"]}]]],[\"verdocs-template-card.cjs\",[[256,\"verdocs-template-card\",{\"template\":[16]}]]],[\"verdocs-template-tags.cjs\",[[256,\"verdocs-template-tags\",{\"tags\":[16]}]]],[\"verdocs-toggle.cjs\",[[256,\"verdocs-toggle\",{\"options\":[16],\"theme\":[1],\"selectedOption\":[32]}]]],[\"verdocs-toggle-button.cjs\",[[256,\"verdocs-toggle-button\",{\"active\":[4],\"icon\":[1],\"label\":[1],\"size\":[1],\"_active\":[32]}]]],[\"verdocs-status-indicator.cjs\",[[256,\"verdocs-status-indicator\",{\"size\":[1],\"theme\":[1],\"status\":[1],\"envelope\":[16],\"isOpen\":[32],\"containerId\":[32]}]]],[\"verdocs-template-star.cjs\",[[256,\"verdocs-template-star\",{\"endpoint\":[16],\"template\":[1040],\"updating\":[32]}]]],[\"verdocs-envelope-recipient-link_2.cjs\",[[256,\"verdocs-envelope-update-recipient\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"roleName\":[1,\"role-name\"],\"isOpen\":[32],\"gettingLink\":[32],\"link\":[32],\"loading\":[32],\"envelope\":[32],\"originalRecipient\":[32],\"updatedRecipient\":[32]}],[256,\"verdocs-envelope-recipient-link\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"roleName\":[1,\"role-name\"],\"isOpen\":[32],\"gettingLink\":[32],\"link\":[32],\"loading\":[32],\"envelope\":[32],\"recipient\":[32]}]]],[\"verdocs-contact-picker.cjs\",[[256,\"verdocs-contact-picker\",{\"endpoint\":[16],\"templateRole\":[16],\"contactSuggestions\":[16],\"first_name\":[32],\"last_name\":[32],\"email\":[32],\"phone\":[32],\"zip\":[32],\"address\":[32],\"message\":[32],\"showSuggestions\":[32],\"showMessage\":[32],\"delegator\":[32],\"name_locked\":[32],\"auth_methods\":[32],\"passcode\":[32],\"firstNameFieldId\":[32],\"lastNameFieldId\":[32],\"emailFieldId\":[32],\"phoneFieldId\":[32],\"featureFlags\":[32],\"activeEntitlements\":[32]}]]],[\"verdocs-radio-button.cjs\",[[256,\"verdocs-radio-button\",{\"checked\":[4],\"name\":[1],\"value\":[1],\"disabled\":[4]}]]],[\"verdocs-switch.cjs\",[[256,\"verdocs-switch\",{\"checked\":[1028],\"theme\":[1],\"disabled\":[4]}]]],[\"verdocs-download-dialog_4.cjs\",[[256,\"verdocs-envelope-document-page\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"documentId\":[1,\"document-id\"],\"pageNumber\":[2,\"page-number\"],\"virtualWidth\":[2,\"virtual-width\"],\"virtualHeight\":[1026,\"virtual-height\"],\"layers\":[16],\"type\":[1],\"containerId\":[32],\"renderedWidth\":[32],\"renderedHeight\":[32],\"naturalWidth\":[32],\"naturalHeight\":[32],\"aspectRatio\":[32],\"skipFirstNotification\":[32],\"pageDisplayUri\":[32]}],[256,\"verdocs-sign-footer\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"isDone\":[4,\"is-done\"],\"askingQuestion\":[32],\"declinine\":[32],\"envelope\":[32]}],[256,\"verdocs-download-dialog\",{\"signed\":[4],\"polling\":[4],\"documents\":[16],\"hasCertificate\":[4,\"has-certificate\"]}],[256,\"verdocs-question-dialog\",{\"question\":[1025],\"closed\":[32]}]]],[\"verdocs-button_3.cjs\",[[256,\"verdocs-text-input\",{\"value\":[1537],\"label\":[1],\"placeholder\":[1],\"description\":[1],\"autocomplete\":[1],\"helpText\":[1,\"help-text\"],\"clearable\":[4],\"copyable\":[4],\"type\":[1],\"disabled\":[4],\"required\":[4],\"showingPw\":[32]}],[256,\"verdocs-help-icon\",{\"text\":[1],\"icon\":[1],\"containerId\":[32]}],[256,\"verdocs-button\",{\"label\":[1],\"startIcon\":[1,\"start-icon\"],\"endIcon\":[1,\"end-icon\"],\"size\":[1],\"type\":[1],\"variant\":[1],\"disabled\":[4]}]]],[\"verdocs-menu-panel_2.cjs\",[[256,\"verdocs-template-role-properties\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"roleName\":[1,\"role-name\"],\"dirty\":[32],\"saving\":[32],\"name\":[32],\"type\":[32],\"first_name\":[32],\"last_name\":[32],\"email\":[32],\"phone\":[32],\"delegator\":[32],\"loading\":[32],\"template\":[32]}],[260,\"verdocs-menu-panel\",{\"side\":[1],\"overlay\":[4],\"width\":[2]},[[4,\"click\",\"handleClick\"]]]]],[\"verdocs-pagination_2.cjs\",[[256,\"verdocs-quick-filter\",{\"options\":[16],\"label\":[1],\"value\":[1537],\"placeholder\":[1],\"open\":[32]}],[256,\"verdocs-pagination\",{\"selectedPage\":[1538,\"selected-page\"],\"itemCount\":[2,\"item-count\"],\"perPage\":[2,\"per-page\"]}]]],[\"verdocs-file-chooser_2.cjs\",[[256,\"verdocs-file-chooser\",{\"endpoint\":[16],\"file\":[32]}],[256,\"verdocs-progress-bar\",{\"label\":[1],\"showPercent\":[4,\"show-percent\"],\"percent\":[2]}]]],[\"verdocs-organization-card_2.cjs\",[[256,\"verdocs-organization-card\",{\"organization\":[16],\"hovered\":[32]},[[1,\"mouseover\",\"onMouseOver\"],[1,\"mouseout\",\"onMouseOut\"]]],[260,\"verdocs-portal\",{\"anchor\":[1],\"voffset\":[2]},[[11,\"scroll\",\"handleScroll\"],[9,\"resize\",\"handleResize\"],[4,\"click\",\"handleClick\"]]]]],[\"verdocs-dropdown.cjs\",[[256,\"verdocs-dropdown\",{\"options\":[16],\"containerId\":[32],\"showPicker\":[32]}]]],[\"verdocs-dialog.cjs\",[[260,\"verdocs-dialog\",{\"persistent\":[4],\"hideCloseButton\":[4,\"hide-close-button\"]}]]],[\"verdocs-ok-dialog.cjs\",[[256,\"verdocs-ok-dialog\",{\"heading\":[1],\"message\":[1],\"buttonLabel\":[1,\"button-label\"],\"showCancel\":[4,\"show-cancel\"],\"hideCloseButton\":[4,\"hide-close-button\"],\"closed\":[32]}]]],[\"verdocs-flag_2.cjs\",[[256,\"verdocs-spinner\",{\"size\":[2],\"mode\":[1]}],[256,\"verdocs-flag\",{\"variant\":[1],\"label\":[1],\"showSkip\":[4,\"show-skip\"]}]]],[\"verdocs-checkbox_5.cjs\",[[256,\"verdocs-template-field-properties\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"fieldName\":[1025,\"field-name\"],\"helpText\":[1,\"help-text\"],\"dirty\":[32],\"label\":[32],\"type\":[32],\"name\":[32],\"required\":[32],\"readonly\":[32],\"roleName\":[32],\"group\":[32],\"fieldType\":[32],\"options\":[32],\"placeholder\":[32],\"defaultValue\":[32],\"showingHelp\":[32],\"loading\":[32],\"template\":[32]}],[256,\"verdocs-select-input\",{\"value\":[1],\"label\":[1],\"options\":[16],\"disabled\":[4]}],[256,\"verdocs-component-error\",{\"message\":[1]}],[256,\"verdocs-checkbox\",{\"checked\":[4],\"name\":[1],\"label\":[1],\"value\":[1],\"theme\":[1],\"size\":[1],\"disabled\":[4]}],[256,\"verdocs-loader\"]]],[\"verdocs-field-attachment_11.cjs\",[[256,\"verdocs-field-attachment\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"dialogOpen\":[32],\"selectedFile\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[0,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-checkbox\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"disabled\":[516],\"done\":[516],\"editable\":[516],\"moveable\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[0,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-date\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"containerId\":[32],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[2,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-dropdown\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[2,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-initial\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"disabled\":[516],\"initials\":[513],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"initialid\":[513],\"isPreview\":[516,\"is-preview\"],\"showingProperties\":[32],\"focused\":[32],\"menuOpen\":[32],\"tempInitials\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[0,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-radio\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"disabled\":[516],\"required\":[516],\"done\":[516],\"editable\":[516],\"moveable\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[0,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-signature\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"name\":[513],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"signatureid\":[513],\"isPreview\":[516,\"is-preview\"],\"showingProperties\":[32],\"focused\":[32],\"menuOpen\":[32],\"tempSignature\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[0,\"blur\",\"handleBlur\"],[0,\"blur\",\"onBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-textarea\",{\"endpoint\":[16],\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[2,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-textbox\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"disabled\":[516],\"multiline\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[2,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-timestamp\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[2],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[2,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-upload-dialog\",{\"maxSize\":[1026,\"max-size\"],\"existingFile\":[1032,\"existing-file\"],\"draggingOver\":[32],\"confirmDelete\":[32],\"selectedFiles\":[32],\"errorMessage\":[32]}]]],[\"verdocs-template-document-page_2.cjs\",[[256,\"verdocs-toolbar-icon\",{\"text\":[1],\"icon\":[1],\"placement\":[1],\"containerId\":[32]}],[256,\"verdocs-template-document-page\",{\"endpoint\":[16],\"editable\":[4],\"disabled\":[4],\"done\":[4],\"templateId\":[513,\"template-id\"],\"documentId\":[513,\"document-id\"],\"pageNumber\":[514,\"page-number\"],\"virtualWidth\":[2,\"virtual-width\"],\"virtualHeight\":[1026,\"virtual-height\"],\"layers\":[16],\"containerId\":[32],\"renderedWidth\":[32],\"renderedHeight\":[32],\"naturalWidth\":[32],\"naturalHeight\":[32],\"aspectRatio\":[32],\"skipFirstNotification\":[32],\"pageDisplayUri\":[32],\"xScale\":[32],\"yScale\":[32],\"loading\":[32],\"template\":[32]}]]],[\"verdocs-preview_6.cjs\",[[256,\"verdocs-template-fields\",{\"endpoint\":[16],\"templateId\":[1537,\"template-id\"],\"toolbarTargetId\":[1,\"toolbar-target-id\"],\"placing\":[32],\"showMustSelectRole\":[32],\"selectedRoleName\":[32],\"loading\":[32],\"template\":[32]},[[4,\"keydown\",\"handleKeyDown\"],[0,\"settingsChanged\",\"handleFieldSettingsChanged\"],[0,\"deleted\",\"handleFieldDeleted\"]],{\"templateId\":[\"onTemplateIdChanged\"]}],[256,\"verdocs-preview\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"loading\":[32],\"template\":[32]},null,{\"templateId\":[\"onTemplateIdChanged\"]}],[256,\"verdocs-send\",{\"endpoint\":[16],\"templateId\":[513,\"template-id\"],\"environment\":[1],\"showCancel\":[4,\"show-cancel\"],\"containerId\":[32],\"showPickerForId\":[32],\"sessionContacts\":[32],\"sending\":[32],\"rolesCompleted\":[32],\"loading\":[32],\"template\":[32],\"reset\":[64]},null,{\"templateId\":[\"onTemplateIdChanged\"]}],[256,\"verdocs-template-roles\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"showingRoleDialog\":[32],\"sender\":[32],\"dragging\":[32],\"loading\":[32],\"template\":[32]}],[256,\"verdocs-template-attachments\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"uploading\":[32],\"progressLabel\":[32],\"progressPercent\":[32],\"showDeleteError\":[32],\"confirmDeleteDocument\":[32],\"loading\":[32],\"template\":[32]}],[256,\"verdocs-template-build-tabs\",{\"endpoint\":[16],\"templateId\":[1537,\"template-id\"],\"step\":[1537],\"loading\":[32],\"template\":[32]},null,{\"templateId\":[\"onTemplateIdChanged\"],\"step\":[\"onStepChanged\"]}]]],[\"verdocs-adopt-signature-dialog_8.cjs\",[[256,\"verdocs-view\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"headerTargetId\":[1,\"header-target-id\"],\"canceling\":[32],\"showCancelDone\":[32],\"showLoadError\":[32],\"loading\":[32],\"envelope\":[32],\"zoomLevel\":[32],\"showDownloadDialog\":[32],\"polling\":[32]}],[256,\"verdocs-kba-dialog\",{\"step\":[2],\"steps\":[2],\"helptitle\":[1],\"helptext\":[1],\"mode\":[1],\"label\":[1],\"placeholder\":[1],\"recipient\":[16],\"choices\":[16],\"agreed\":[32],\"response\":[32],\"updatedRecipient\":[32],\"dobContainerId\":[32]}],[256,\"verdocs-adopt-signature-dialog\",{\"name\":[1],\"nameLocked\":[4,\"name-locked\"],\"initialEnteredName\":[1,\"initial-entered-name\"],\"initialMode\":[1,\"initial-mode\"],\"initialSignature\":[1,\"initial-signature\"],\"initialInitials\":[1,\"initial-initials\"],\"fontLoaded\":[32],\"enteredName\":[32],\"enteredInitials\":[32],\"mode\":[32],\"isDrawing\":[32],\"hasDrawnSignature\":[32],\"hasDrawnInitials\":[32]}],[256,\"verdocs-otp-dialog\",{\"endpoint\":[1040],\"method\":[1],\"resendDisabled\":[32],\"response\":[32]}],[256,\"verdocs-passcode-dialog\",{\"endpoint\":[1040],\"response\":[32]}],[256,\"verdocs-disclosure-dialog\",{\"disclosures\":[1],\"delegator\":[4],\"accepted\":[32]}],[256,\"verdocs-delegate-dialog\",{\"endpoint\":[1040],\"envelope\":[16],\"first_name\":[32],\"last_name\":[32],\"email\":[32],\"phone\":[32],\"message\":[32]}],[256,\"verdocs-signing-progress\",{\"mode\":[1],\"focusedField\":[1,\"focused-field\"],\"fields\":[16],\"recipientFields\":[16],\"skippedFields\":[16]}]]]]"), options);
|
|
22
|
+
return index.bootstrapLazy(JSON.parse("[[\"verdocs-build.cjs\",[[256,\"verdocs-build\",{\"endpoint\":[16],\"templateId\":[1537,\"template-id\"],\"step\":[1537],\"loading\":[32],\"template\":[32]},null,{\"templateId\":[\"onTemplateIdChanged\"],\"step\":[\"onStepChanged\"]}]]],[\"verdocs-sign.cjs\",[[256,\"verdocs-sign\",{\"endpoint\":[1040],\"envelopeId\":[513,\"envelope-id\"],\"roleId\":[513,\"role-id\"],\"inviteCode\":[513,\"invite-code\"],\"headerTargetId\":[1,\"header-target-id\"],\"toolbarStyle\":[1,\"toolbar-style\"],\"autoAcceptDisclosures\":[4,\"auto-accept-disclosures\"],\"recipient\":[32],\"hasSignature\":[32],\"nextButtonLabel\":[32],\"nextSubmits\":[32],\"fatalErrorHeader\":[32],\"fatalErrorMessage\":[32],\"focusedField\":[32],\"disclosures\":[32],\"fieldUpdateCounter\":[32],\"submitting\":[32],\"submitted\":[32],\"isDone\":[32],\"showDone\":[32],\"adoptingSignature\":[32],\"showLoadError\":[32],\"finishLater\":[32],\"showFinishLater\":[32],\"agreed\":[32],\"signatureId\":[32],\"initialId\":[32],\"signatureAdoptMode\":[32],\"adoptedSignaturePreview\":[32],\"adoptedInitialsPreview\":[32],\"adoptedSignatureStrokes\":[32],\"adoptedInitialsStrokes\":[32],\"adoptedName\":[32],\"skippedFields\":[32],\"documentsSingularPlural\":[32],\"authStep\":[32],\"authMethodStates\":[32],\"pageNumber\":[32],\"kbaQuestions\":[32],\"showSpinner\":[32],\"declining\":[32],\"delegating\":[32],\"delegated\":[32],\"kbaChoices\":[32],\"showDownloadDialog\":[32],\"loading\":[32],\"envelope\":[32],\"zoomLevel\":[32],\"signingProgressMode\":[32],\"polling\":[32]}]]],[\"verdocs-envelopes-list.cjs\",[[256,\"verdocs-envelopes-list\",{\"endpoint\":[16],\"view\":[1537],\"status\":[1537],\"sort\":[1537],\"match\":[1537],\"showPagination\":[4,\"show-pagination\"],\"rowsPerPage\":[2,\"rows-per-page\"],\"selectedPage\":[2,\"selected-page\"],\"count\":[32],\"initiallyLoaded\":[32],\"loading\":[32],\"selectedEnvelopes\":[32],\"envelopes\":[32]},null,{\"view\":[\"handleViewUpdated\"],\"status\":[\"handleStatusUpdated\"],\"sort\":[\"handleSortUpdated\"],\"match\":[\"handleMatchUpdated\"],\"selectedPage\":[\"handlePageUpdated\"]}]]],[\"verdocs-templates-list.cjs\",[[256,\"verdocs-templates-list\",{\"endpoint\":[16],\"visibility\":[1537],\"starred\":[1537],\"sort\":[1537],\"name\":[1537],\"allowedActions\":[1040],\"showPagination\":[4,\"show-pagination\"],\"rowsPerPage\":[2,\"rows-per-page\"],\"selectedPage\":[2,\"selected-page\"],\"count\":[32],\"initiallyLoaded\":[32],\"loading\":[32],\"confirmDelete\":[32],\"templates\":[32],\"localNameFilter\":[32]},null,{\"sharing\":[\"handleSharingUpdated\"],\"starred\":[\"handleStarredUpdated\"],\"sort\":[\"handleSortUpdated\"],\"name\":[\"handleNameUpdated\"],\"selectedPage\":[\"handlePageUpdated\"]}]]],[\"verdocs-envelope-sidebar.cjs\",[[256,\"verdocs-envelope-sidebar\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"activeTab\":[32],\"panelOpen\":[32],\"showRecipientDialog\":[32],\"showCancelDialog\":[32],\"showReinviteDialog\":[32],\"showUpdateDialog\":[32],\"remindersEnabled\":[32],\"updatingReminders\":[32],\"initialReminder\":[32],\"followupReminders\":[32],\"loading\":[32],\"envelope\":[32]}]]],[\"verdocs-field-payment.cjs\",[[256,\"verdocs-field-payment\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"disabled\":[516],\"done\":[516],\"editable\":[516],\"moveable\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"fields\":[16],\"pageNum\":[2,\"page-num\"],\"roleName\":[1,\"role-name\"],\"fieldId\":[1,\"field-id\"],\"recipients\":[8],\"selectedRoleName\":[1,\"selected-role-name\"],\"pdfPages\":[16],\"currentSignature\":[1,\"current-signature\"],\"currentSignatureId\":[1,\"current-signature-id\"],\"currentInitial\":[1,\"current-initial\"],\"currentInitialId\":[1,\"current-initial-id\"],\"signed\":[4],\"roleindex\":[2],\"showingProperties\":[32],\"focused\":[32],\"preparedMessage\":[32],\"signatureUrl\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[0,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}]]],[\"verdocs-template-settings.cjs\",[[256,\"verdocs-template-settings\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"name\":[32],\"visibility\":[32],\"sender\":[32],\"sendReminders\":[32],\"initialReminder\":[32],\"followupReminders\":[32],\"dirty\":[32],\"loading\":[32],\"template\":[32]}]]],[\"verdocs-template-create.cjs\",[[256,\"verdocs-template-create\",{\"endpoint\":[16],\"maxSize\":[1026,\"max-size\"],\"file\":[32],\"creating\":[32],\"progressLabel\":[32],\"progressPercent\":[32],\"errorMessage\":[32]}]]],[\"verdocs-auth.cjs\",[[256,\"verdocs-auth\",{\"endpoint\":[16],\"visible\":[4],\"logo\":[1],\"displayMode\":[1025,\"display-mode\"],\"org_name\":[32],\"first_name\":[32],\"last_name\":[32],\"email\":[32],\"phone\":[32],\"verificationCode\":[32],\"newPassword\":[32],\"password\":[32],\"confirmpass\":[32],\"submitting\":[32],\"resendDisabled\":[32],\"session\":[32],\"profile\":[32]}]]],[\"verdocs-initial-dialog.cjs\",[[256,\"verdocs-initial-dialog\",{\"initials\":[1],\"fontLoaded\":[32],\"enteredInitials\":[32],\"mode\":[32]}]]],[\"verdocs-signature-dialog.cjs\",[[256,\"verdocs-signature-dialog\",{\"name\":[1],\"fontLoaded\":[32],\"enteredName\":[32],\"mode\":[32],\"isDrawing\":[32],\"hasDrawnSignature\":[32],\"hasUploadedImage\":[32],\"uploadedFileName\":[32]}]]],[\"verdocs-date-input.cjs\",[[256,\"verdocs-date-input\",{\"value\":[1537],\"label\":[1],\"placeholder\":[1],\"helpText\":[1,\"help-text\"],\"disabled\":[4],\"required\":[4],\"showingPw\":[32],\"focused\":[32],\"containerId\":[32],\"focusField\":[64]}]]],[\"verdocs-envelope-recipient-summary.cjs\",[[256,\"verdocs-envelope-recipient-summary\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"canSendAnother\":[4,\"can-send-another\"],\"canView\":[4,\"can-view\"],\"canDone\":[4,\"can-done\"],\"isOpen\":[32],\"recipientStatusIcons\":[32],\"containerId\":[32],\"gettingLinks\":[32],\"links\":[32],\"loading\":[32],\"envelope\":[32]}]]],[\"verdocs-multiselect.cjs\",[[256,\"verdocs-multiselect\",{\"label\":[1],\"placeholder\":[1],\"options\":[16],\"selectedOptions\":[16],\"showPicker\":[32]}]]],[\"verdocs-button-panel.cjs\",[[260,\"verdocs-button-panel\",{\"icon\":[1],\"showPanel\":[64],\"hidePanel\":[64],\"toggle\":[64]}]]],[\"verdocs-quick-functions.cjs\",[[256,\"verdocs-quick-functions\",{\"endpoint\":[16]}]]],[\"verdocs-search-box.cjs\",[[256,\"verdocs-search-box\",{\"endpoint\":[16],\"placeholder\":[1],\"type\":[1],\"query\":[1],\"grabsFocus\":[4,\"grabs-focus\"],\"focusField\":[64]}]]],[\"verdocs-search-tabs.cjs\",[[256,\"verdocs-search-tabs\",{\"selected\":[32]}]]],[\"verdocs-table.cjs\",[[256,\"verdocs-table\",{\"columns\":[16],\"data\":[16]}]]],[\"verdocs-tabs.cjs\",[[260,\"verdocs-tabs\",{\"tabs\":[16],\"selectedTab\":[2,\"selected-tab\"]}]]],[\"verdocs-template-card.cjs\",[[256,\"verdocs-template-card\",{\"template\":[16]}]]],[\"verdocs-template-tags.cjs\",[[256,\"verdocs-template-tags\",{\"tags\":[16]}]]],[\"verdocs-toggle.cjs\",[[256,\"verdocs-toggle\",{\"options\":[16],\"theme\":[1],\"selectedOption\":[32]}]]],[\"verdocs-toggle-button.cjs\",[[256,\"verdocs-toggle-button\",{\"active\":[4],\"icon\":[1],\"label\":[1],\"size\":[1],\"_active\":[32]}]]],[\"verdocs-status-indicator.cjs\",[[256,\"verdocs-status-indicator\",{\"size\":[1],\"theme\":[1],\"status\":[1],\"envelope\":[16],\"isOpen\":[32],\"containerId\":[32]}]]],[\"verdocs-template-star.cjs\",[[256,\"verdocs-template-star\",{\"endpoint\":[16],\"template\":[1040],\"updating\":[32]}]]],[\"verdocs-envelope-recipient-link_2.cjs\",[[256,\"verdocs-envelope-update-recipient\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"roleName\":[1,\"role-name\"],\"isOpen\":[32],\"gettingLink\":[32],\"link\":[32],\"loading\":[32],\"envelope\":[32],\"originalRecipient\":[32],\"updatedRecipient\":[32]}],[256,\"verdocs-envelope-recipient-link\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"roleName\":[1,\"role-name\"],\"isOpen\":[32],\"gettingLink\":[32],\"link\":[32],\"loading\":[32],\"envelope\":[32],\"recipient\":[32]}]]],[\"verdocs-contact-picker.cjs\",[[256,\"verdocs-contact-picker\",{\"endpoint\":[16],\"templateRole\":[16],\"contactSuggestions\":[16],\"first_name\":[32],\"last_name\":[32],\"email\":[32],\"phone\":[32],\"zip\":[32],\"address\":[32],\"message\":[32],\"showSuggestions\":[32],\"showMessage\":[32],\"delegator\":[32],\"name_locked\":[32],\"auth_methods\":[32],\"passcode\":[32],\"firstNameFieldId\":[32],\"lastNameFieldId\":[32],\"emailFieldId\":[32],\"phoneFieldId\":[32],\"featureFlags\":[32],\"activeEntitlements\":[32]}]]],[\"verdocs-radio-button.cjs\",[[256,\"verdocs-radio-button\",{\"checked\":[4],\"name\":[1],\"value\":[1],\"disabled\":[4]}]]],[\"verdocs-switch.cjs\",[[256,\"verdocs-switch\",{\"checked\":[1028],\"theme\":[1],\"disabled\":[4]}]]],[\"verdocs-download-dialog_4.cjs\",[[256,\"verdocs-envelope-document-page\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"documentId\":[1,\"document-id\"],\"pageNumber\":[2,\"page-number\"],\"virtualWidth\":[2,\"virtual-width\"],\"virtualHeight\":[1026,\"virtual-height\"],\"layers\":[16],\"type\":[1],\"containerId\":[32],\"renderedWidth\":[32],\"renderedHeight\":[32],\"naturalWidth\":[32],\"naturalHeight\":[32],\"aspectRatio\":[32],\"skipFirstNotification\":[32],\"pageDisplayUri\":[32]}],[256,\"verdocs-sign-footer\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"isDone\":[4,\"is-done\"],\"askingQuestion\":[32],\"declinine\":[32],\"envelope\":[32]}],[256,\"verdocs-download-dialog\",{\"signed\":[4],\"polling\":[4],\"documents\":[16],\"hasCertificate\":[4,\"has-certificate\"]}],[256,\"verdocs-question-dialog\",{\"question\":[1025],\"closed\":[32]}]]],[\"verdocs-button_3.cjs\",[[256,\"verdocs-text-input\",{\"value\":[1537],\"label\":[1],\"placeholder\":[1],\"description\":[1],\"autocomplete\":[1],\"helpText\":[1,\"help-text\"],\"clearable\":[4],\"copyable\":[4],\"type\":[1],\"disabled\":[4],\"required\":[4],\"showingPw\":[32]}],[256,\"verdocs-help-icon\",{\"text\":[1],\"icon\":[1],\"containerId\":[32]}],[256,\"verdocs-button\",{\"label\":[1],\"startIcon\":[1,\"start-icon\"],\"endIcon\":[1,\"end-icon\"],\"size\":[1],\"type\":[1],\"variant\":[1],\"disabled\":[4]}]]],[\"verdocs-menu-panel_2.cjs\",[[256,\"verdocs-template-role-properties\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"roleName\":[1,\"role-name\"],\"dirty\":[32],\"saving\":[32],\"name\":[32],\"type\":[32],\"first_name\":[32],\"last_name\":[32],\"email\":[32],\"phone\":[32],\"delegator\":[32],\"loading\":[32],\"template\":[32]}],[260,\"verdocs-menu-panel\",{\"side\":[1],\"overlay\":[4],\"width\":[2]},[[4,\"click\",\"handleClick\"]]]]],[\"verdocs-pagination_2.cjs\",[[256,\"verdocs-quick-filter\",{\"options\":[16],\"label\":[1],\"value\":[1537],\"placeholder\":[1],\"open\":[32]}],[256,\"verdocs-pagination\",{\"selectedPage\":[1538,\"selected-page\"],\"itemCount\":[2,\"item-count\"],\"perPage\":[2,\"per-page\"]}]]],[\"verdocs-file-chooser_2.cjs\",[[256,\"verdocs-file-chooser\",{\"endpoint\":[16],\"file\":[32]}],[256,\"verdocs-progress-bar\",{\"label\":[1],\"showPercent\":[4,\"show-percent\"],\"percent\":[2]}]]],[\"verdocs-organization-card_2.cjs\",[[256,\"verdocs-organization-card\",{\"organization\":[16],\"hovered\":[32]},[[1,\"mouseover\",\"onMouseOver\"],[1,\"mouseout\",\"onMouseOut\"]]],[260,\"verdocs-portal\",{\"anchor\":[1],\"voffset\":[2]},[[11,\"scroll\",\"handleScroll\"],[9,\"resize\",\"handleResize\"],[4,\"click\",\"handleClick\"]]]]],[\"verdocs-dropdown.cjs\",[[256,\"verdocs-dropdown\",{\"options\":[16],\"containerId\":[32],\"showPicker\":[32]}]]],[\"verdocs-dialog.cjs\",[[260,\"verdocs-dialog\",{\"persistent\":[4],\"hideCloseButton\":[4,\"hide-close-button\"]}]]],[\"verdocs-ok-dialog.cjs\",[[256,\"verdocs-ok-dialog\",{\"heading\":[1],\"message\":[1],\"buttonLabel\":[1,\"button-label\"],\"showCancel\":[4,\"show-cancel\"],\"hideCloseButton\":[4,\"hide-close-button\"],\"closed\":[32]}]]],[\"verdocs-flag_2.cjs\",[[256,\"verdocs-spinner\",{\"size\":[2],\"mode\":[1]}],[256,\"verdocs-flag\",{\"variant\":[1],\"label\":[1],\"showSkip\":[4,\"show-skip\"]}]]],[\"verdocs-checkbox_5.cjs\",[[256,\"verdocs-template-field-properties\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"fieldName\":[1025,\"field-name\"],\"helpText\":[1,\"help-text\"],\"dirty\":[32],\"label\":[32],\"type\":[32],\"name\":[32],\"required\":[32],\"readonly\":[32],\"roleName\":[32],\"group\":[32],\"fieldType\":[32],\"options\":[32],\"placeholder\":[32],\"defaultValue\":[32],\"showingHelp\":[32],\"loading\":[32],\"template\":[32]}],[256,\"verdocs-select-input\",{\"value\":[1],\"label\":[1],\"options\":[16],\"disabled\":[4]}],[256,\"verdocs-component-error\",{\"message\":[1]}],[256,\"verdocs-checkbox\",{\"checked\":[4],\"name\":[1],\"label\":[1],\"value\":[1],\"theme\":[1],\"size\":[1],\"disabled\":[4]}],[256,\"verdocs-loader\"]]],[\"verdocs-field-attachment_11.cjs\",[[256,\"verdocs-field-attachment\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"dialogOpen\":[32],\"selectedFile\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[0,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-checkbox\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"disabled\":[516],\"done\":[516],\"editable\":[516],\"moveable\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[0,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-date\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"containerId\":[32],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[2,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-dropdown\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[2,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-initial\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"disabled\":[516],\"initials\":[513],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"initialid\":[513],\"isPreview\":[516,\"is-preview\"],\"showingProperties\":[32],\"focused\":[32],\"menuOpen\":[32],\"tempInitials\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[0,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-radio\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"disabled\":[516],\"required\":[516],\"done\":[516],\"editable\":[516],\"moveable\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[0,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-signature\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"name\":[513],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"signatureid\":[513],\"isPreview\":[516,\"is-preview\"],\"showingProperties\":[32],\"focused\":[32],\"menuOpen\":[32],\"tempSignature\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[0,\"blur\",\"handleBlur\"],[0,\"blur\",\"onBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-textarea\",{\"endpoint\":[16],\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[2,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-textbox\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"disabled\":[516],\"multiline\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[2,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-field-timestamp\",{\"source\":[513],\"sourceid\":[513],\"fieldname\":[513],\"field\":[16],\"isPreview\":[516,\"is-preview\"],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[2],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]},[[2,\"blur\",\"handleBlur\"]],{\"editable\":[\"onEditableChanged\"]}],[256,\"verdocs-upload-dialog\",{\"maxSize\":[1026,\"max-size\"],\"existingFile\":[1032,\"existing-file\"],\"draggingOver\":[32],\"confirmDelete\":[32],\"selectedFiles\":[32],\"errorMessage\":[32]}]]],[\"verdocs-template-document-page_2.cjs\",[[256,\"verdocs-toolbar-icon\",{\"text\":[1],\"icon\":[1],\"placement\":[1],\"containerId\":[32]}],[256,\"verdocs-template-document-page\",{\"endpoint\":[16],\"editable\":[4],\"disabled\":[4],\"done\":[4],\"templateId\":[513,\"template-id\"],\"documentId\":[513,\"document-id\"],\"pageNumber\":[514,\"page-number\"],\"virtualWidth\":[2,\"virtual-width\"],\"virtualHeight\":[1026,\"virtual-height\"],\"layers\":[16],\"containerId\":[32],\"renderedWidth\":[32],\"renderedHeight\":[32],\"naturalWidth\":[32],\"naturalHeight\":[32],\"aspectRatio\":[32],\"skipFirstNotification\":[32],\"pageDisplayUri\":[32],\"xScale\":[32],\"yScale\":[32],\"loading\":[32],\"template\":[32]}]]],[\"verdocs-preview_6.cjs\",[[256,\"verdocs-template-fields\",{\"endpoint\":[16],\"templateId\":[1537,\"template-id\"],\"toolbarTargetId\":[1,\"toolbar-target-id\"],\"placing\":[32],\"showMustSelectRole\":[32],\"selectedRoleName\":[32],\"loading\":[32],\"template\":[32]},[[4,\"keydown\",\"handleKeyDown\"],[0,\"settingsChanged\",\"handleFieldSettingsChanged\"],[0,\"deleted\",\"handleFieldDeleted\"]],{\"templateId\":[\"onTemplateIdChanged\"]}],[256,\"verdocs-preview\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"loading\":[32],\"template\":[32]},null,{\"templateId\":[\"onTemplateIdChanged\"]}],[256,\"verdocs-send\",{\"endpoint\":[16],\"templateId\":[513,\"template-id\"],\"environment\":[1],\"showCancel\":[4,\"show-cancel\"],\"containerId\":[32],\"showPickerForId\":[32],\"sessionContacts\":[32],\"sending\":[32],\"rolesCompleted\":[32],\"loading\":[32],\"template\":[32],\"reset\":[64]},null,{\"templateId\":[\"onTemplateIdChanged\"]}],[256,\"verdocs-template-roles\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"showingRoleDialog\":[32],\"sender\":[32],\"dragging\":[32],\"loading\":[32],\"template\":[32]}],[256,\"verdocs-template-attachments\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"uploading\":[32],\"progressLabel\":[32],\"progressPercent\":[32],\"showDeleteError\":[32],\"confirmDeleteDocument\":[32],\"loading\":[32],\"template\":[32]}],[256,\"verdocs-template-build-tabs\",{\"endpoint\":[16],\"templateId\":[1537,\"template-id\"],\"step\":[1537],\"loading\":[32],\"template\":[32]},null,{\"templateId\":[\"onTemplateIdChanged\"],\"step\":[\"onStepChanged\"]}]]],[\"verdocs-adopt-signature-dialog_8.cjs\",[[256,\"verdocs-view\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"headerTargetId\":[1,\"header-target-id\"],\"canceling\":[32],\"showCancelDone\":[32],\"showLoadError\":[32],\"loading\":[32],\"envelope\":[32],\"zoomLevel\":[32],\"showDownloadDialog\":[32],\"polling\":[32]}],[256,\"verdocs-kba-dialog\",{\"step\":[2],\"steps\":[2],\"helptitle\":[1],\"helptext\":[1],\"mode\":[1],\"label\":[1],\"placeholder\":[1],\"recipient\":[16],\"choices\":[16],\"agreed\":[32],\"response\":[32],\"updatedRecipient\":[32],\"dobContainerId\":[32]}],[256,\"verdocs-adopt-signature-dialog\",{\"name\":[1],\"nameLocked\":[4,\"name-locked\"],\"initialEnteredName\":[1,\"initial-entered-name\"],\"initialMode\":[1,\"initial-mode\"],\"initialSignature\":[1,\"initial-signature\"],\"initialInitials\":[1,\"initial-initials\"],\"initialSignatureStrokes\":[16],\"initialInitialsStrokes\":[16],\"fontLoaded\":[32],\"enteredName\":[32],\"enteredInitials\":[32],\"mode\":[32],\"isDrawing\":[32],\"hasDrawnSignature\":[32],\"hasDrawnInitials\":[32]}],[256,\"verdocs-otp-dialog\",{\"endpoint\":[1040],\"method\":[1],\"resendDisabled\":[32],\"response\":[32]}],[256,\"verdocs-passcode-dialog\",{\"endpoint\":[1040],\"response\":[32]}],[256,\"verdocs-disclosure-dialog\",{\"disclosures\":[1],\"delegator\":[4],\"accepted\":[32]}],[256,\"verdocs-delegate-dialog\",{\"endpoint\":[1040],\"envelope\":[16],\"first_name\":[32],\"last_name\":[32],\"email\":[32],\"phone\":[32],\"message\":[32]}],[256,\"verdocs-signing-progress\",{\"mode\":[1],\"focusedField\":[1,\"focused-field\"],\"fields\":[16],\"recipientFields\":[16],\"skippedFields\":[16]}]]]]"), options);
|
|
23
23
|
});
|
|
24
24
|
|
|
25
25
|
exports.setNonce = index.setNonce;
|
|
@@ -223,17 +223,30 @@ export class VerdocsAdoptSignatureDialog {
|
|
|
223
223
|
}
|
|
224
224
|
}
|
|
225
225
|
async restoreDrawnPreviewsIfNeeded() {
|
|
226
|
+
var _a, _b;
|
|
226
227
|
// Preserve in-session stroke edits; only restore saved previews when there are no strokes yet.
|
|
227
228
|
if (this.allSigStrokes.length > 0 || this.allInitialsStrokes.length > 0) {
|
|
228
229
|
return;
|
|
229
230
|
}
|
|
230
231
|
const tasks = [];
|
|
231
|
-
|
|
232
|
+
// Prefer replaying the saved strokes (faithful + editable). Fall back to the rasterized preview only when no
|
|
233
|
+
// strokes are available, e.g. resuming from a server-stored bitmap in a fresh browser session.
|
|
234
|
+
if (((_a = this.initialSignatureStrokes) === null || _a === void 0 ? void 0 : _a.length) && this.signatureElement) {
|
|
235
|
+
this.allSigStrokes = this.denormalizeStrokes(this.initialSignatureStrokes, this.signatureElement);
|
|
236
|
+
this.hasDrawnSignature = true;
|
|
237
|
+
this.redrawDrawnSignature();
|
|
238
|
+
}
|
|
239
|
+
else if (this.initialSignature && this.signatureElement) {
|
|
232
240
|
tasks.push(this.drawImageOnCanvas(this.signatureElement, this.initialSignature).then(() => {
|
|
233
241
|
this.hasDrawnSignature = true;
|
|
234
242
|
}));
|
|
235
243
|
}
|
|
236
|
-
if (this.
|
|
244
|
+
if (((_b = this.initialInitialsStrokes) === null || _b === void 0 ? void 0 : _b.length) && this.initialsElement) {
|
|
245
|
+
this.allInitialsStrokes = this.denormalizeStrokes(this.initialInitialsStrokes, this.initialsElement);
|
|
246
|
+
this.hasDrawnInitials = true;
|
|
247
|
+
this.redrawDrawnInitials();
|
|
248
|
+
}
|
|
249
|
+
else if (this.initialInitials && this.initialsElement) {
|
|
237
250
|
tasks.push(this.drawImageOnCanvas(this.initialsElement, this.initialInitials).then(() => {
|
|
238
251
|
this.hasDrawnInitials = true;
|
|
239
252
|
}));
|
|
@@ -372,7 +385,21 @@ export class VerdocsAdoptSignatureDialog {
|
|
|
372
385
|
e.preventDefault();
|
|
373
386
|
const signature = this.signatureElement.toDataURL('image/png');
|
|
374
387
|
const initials = this.initialsElement.toDataURL('image/png');
|
|
375
|
-
|
|
388
|
+
// Persist the editable source for drawn signatures so a future Edit can replay the exact strokes natively rather
|
|
389
|
+
// than reconstructing them from the bitmap. Typed signatures need no strokes — they re-render from the name.
|
|
390
|
+
const signatureStrokes = this.mode === 'draw' ? this.normalizeStrokes(this.allSigStrokes, this.signatureElement) : [];
|
|
391
|
+
const initialsStrokes = this.mode === 'draw' ? this.normalizeStrokes(this.allInitialsStrokes, this.initialsElement) : [];
|
|
392
|
+
this.next.emit({ signature, initials, mode: this.mode, name: this.enteredName, signatureStrokes, initialsStrokes });
|
|
393
|
+
}
|
|
394
|
+
normalizeStrokes(strokes, canvas) {
|
|
395
|
+
const width = (canvas === null || canvas === void 0 ? void 0 : canvas.width) || 1;
|
|
396
|
+
const height = (canvas === null || canvas === void 0 ? void 0 : canvas.height) || 1;
|
|
397
|
+
return strokes.map(stroke => stroke.map(point => ({ x: point.x / width, y: point.y / height })));
|
|
398
|
+
}
|
|
399
|
+
denormalizeStrokes(strokes, canvas) {
|
|
400
|
+
const width = canvas.width || 1;
|
|
401
|
+
const height = canvas.height || 1;
|
|
402
|
+
return strokes.map(stroke => stroke.map(point => ({ x: point.x * width, y: point.y * height })));
|
|
376
403
|
}
|
|
377
404
|
isAdoptButtonDisabled() {
|
|
378
405
|
switch (this.mode) {
|
|
@@ -501,11 +528,11 @@ export class VerdocsAdoptSignatureDialog {
|
|
|
501
528
|
};
|
|
502
529
|
}
|
|
503
530
|
render() {
|
|
504
|
-
return (h("verdocs-dialog", { key: '
|
|
531
|
+
return (h("verdocs-dialog", { key: 'ddc22647c01547a474b875c409358e3af2f24e3c', persistent: true, onExit: () => this.exit.emit() }, h("div", { key: 'e8a0089ee73a51008d0aeec9dcc7fca1576104ac', slot: "heading", class: "heading" }, "Adopt Your Signature"), h("div", { key: '2d7c449062e88b4bc25d6762cd6c793992f47f4d', slot: "content", class: "content" }, h("div", { key: 'e8d4ec00383967dc9fe30d773ec2212d93b82975', style: { fontWeight: '300', color: '#242424', fontSize: '13px' } }, "Confirm your name, initials, and signature."), h("div", { key: '0f694d93d6f00feb519841870c0fc6a71194d2ca', class: { type: true, active: this.mode === 'type' } }, h("verdocs-text-input", { key: '0d5513fef5e5572b7f4abf1cbac0a1ca3440463f', label: "Full Name", value: this.enteredName, disabled: this.nameLocked, onInput: e => this.handleNameChange(e), onClick: e => e.stopPropagation() }), this.nameLocked && h("div", { key: 'e89a2f87dcfad2fe8f8f4d48a24223e6ea17383d', class: "name-locked-hint" }, "Your name has been set by the sender and cannot be changed.")), h("div", { key: 'd11ea670ee76e772a38455f30f18cbec98fb395a', style: { fontWeight: '400', color: '#242424', fontSize: '13px' } }, "Select a signature style"), h("div", { key: '3bf1e22f0a9e3bbadd0bf4f0b8a3f1b3896d7315', style: { display: 'flex', flexDirection: 'row', gap: '10px', marginBottom: '6px', alignItems: 'center', fontSize: '13px' } }, h("verdocs-radio-button", { key: '99eef6a79eea724f2ad8e66b9394dd40bc9acfe0', checked: this.mode === 'type', value: "type", name: "mode", onClick: () => this.setMode('type') }), h("label", { key: '04194fdf3a502ffd95b696ed9078ab3982a0caf9' }, "Typed with a keyboard")), h("div", { key: '4e122b72fe041edaf499c5ce9ebabaa5c0883a61', style: { display: 'flex', flexDirection: 'row', gap: '10px', marginBottom: '6px', alignItems: 'center', fontSize: '13px' } }, h("verdocs-radio-button", { key: '4a4f2b7492cdb8118184347613cd27ab4994b4dd', checked: this.mode === 'draw', value: "draw", name: "mode", onClick: () => this.setMode('draw') }), h("label", { key: '86824cda2d7968e30d26426e40f336797776ced2' }, "Drawn with touch, mouse, or stylus")), h("div", { key: '94993f0f41b5099d2e86703e711041939c98eda9', class: "preview-header" }, h("div", { key: '55bad19f2cf23ef7ecb4793f76b95feab654b940', style: { fontSize: '13px', fontWeight: '400' } }, "Signature Preview"), this.mode === 'draw' && (h("button", { key: 'ef4713146fca813bef48f537190c438819ff84a2', class: "clear-button-text", onClick: e => this.handleClearDrawing(e, 'signature'), disabled: !this.hasDrawnSignature }, "Clear"))), h("div", { key: '1e58344a555fe2e224f159f3ef830d46ef362086', class: "canvas-container signature-container" }, h("div", { key: '16fac93400bd3f53e7420222c6ba062d49b5d665', class: "signing-indicator" }, h("div", { key: 'e094b7097e905fd438cebc0d897faf1746eefcc7', class: "x-icon", innerHTML: SignatureXIcon }), h("div", { key: 'a67e3effd1f6db780c8a20d31dedd1940e874062', class: "signing-line" })), h("canvas", { key: '5d6c807b860ac53af851dd85cc655aa797ece1ae', ref: el => (this.signatureElement = el),
|
|
505
532
|
// width="300"
|
|
506
|
-
height: "79", class: "signature-canvas", onPointerDown: this.handleSigPointerDown, onPointerMove: this.handleSigPointerMove, onPointerUp: this.handleSigPointerUp, onPointerCancel: this.handleSigPointerCancel, style: { touchAction: 'none', cursor: 'crosshair' } })), h("div", { key: '
|
|
533
|
+
height: "79", class: "signature-canvas", onPointerDown: this.handleSigPointerDown, onPointerMove: this.handleSigPointerMove, onPointerUp: this.handleSigPointerUp, onPointerCancel: this.handleSigPointerCancel, style: { touchAction: 'none', cursor: 'crosshair' } })), h("div", { key: '53953056fcc62dc29bc780400bda01c668d8fc48', class: "preview-header" }, h("div", { key: '554d920b0814e1ada74a0a88310d91b93ac08a5a', style: { fontSize: '13px', fontWeight: '400' } }, "Initials Preview"), this.mode === 'draw' && (h("button", { key: '16db130dd8bdd452e55269ed0670b3ad4b7520f4', class: "clear-button-text", onClick: e => this.handleClearDrawing(e, 'initials'), disabled: !this.hasDrawnInitials }, "Clear"))), h("div", { key: '0e8555d834f009e73b4527b92588d61c4ec20516', class: "canvas-container initials-container" }, h("div", { key: '95292eee946791cc24699d4da2af7df556fd9b34', class: "signing-indicator" }, h("div", { key: 'baba2bc70666d290a93d8c858397da0fa378e65a', class: "x-icon", innerHTML: SignatureXIcon }), h("div", { key: 'ad97b82227759ec6aeaa6735d4ed6355d2ee62e5', class: "signing-line" })), h("canvas", { key: '988f27616ab5bdf37bfba869c612ce75bcde4bd8', ref: el => (this.initialsElement = el),
|
|
507
534
|
// width="300"
|
|
508
|
-
height: "79", class: "initials-canvas", onPointerDown: this.handleInitialsPointerDown, onPointerMove: this.handleInitialsPointerMove, onPointerUp: this.handleInitialsPointerUp, onPointerCancel: this.handleInitialsPointerCancel, style: { touchAction: 'none', cursor: 'crosshair' } })), h("div", { key: '
|
|
535
|
+
height: "79", class: "initials-canvas", onPointerDown: this.handleInitialsPointerDown, onPointerMove: this.handleInitialsPointerMove, onPointerUp: this.handleInitialsPointerUp, onPointerCancel: this.handleInitialsPointerCancel, style: { touchAction: 'none', cursor: 'crosshair' } })), h("div", { key: 'e1f78a82f1f4418d081efa92a9ddb0440b7c410a', class: "disclaimer" }, "By clicking \u00ABAdopt Signature\u00BB, I agree that the signature and initials above will be the electronic representation of my signature and initials for all purposes when I use them to sign documents. Applying them to a document is legally equivalent to signing with a pen on paper.")), h("div", { key: 'a715ffeab244a8f4c68eeab7e4d605a4b0858139', class: "footer", slot: "footer" }, h("div", { key: 'bd07769e1cb702ee6884c72f5d0a005b1844feea', class: "buttons" }, h("button", { key: 'd2905afb693781de51e0e2131368802284a534df', class: "cancel", onClick: e => this.handleCancel(e) }, "Cancel"), h("button", { key: 'a6a5a42a123357c85c9cea004643e33de9caec05', class: "proceed", onClick: e => this.handleAdopt(e), disabled: this.isAdoptButtonDisabled() }, "Adopt & Sign")))));
|
|
509
536
|
}
|
|
510
537
|
static get is() { return "verdocs-adopt-signature-dialog"; }
|
|
511
538
|
static get originalStyleUrls() {
|
|
@@ -629,12 +656,56 @@ export class VerdocsAdoptSignatureDialog {
|
|
|
629
656
|
"optional": true,
|
|
630
657
|
"docs": {
|
|
631
658
|
"tags": [],
|
|
632
|
-
"text": "If set, restores the previously adopted initials preview (base64 data URL)."
|
|
659
|
+
"text": "If set, restores the previously adopted initials preview (base64 data URL). Used only as a fallback when no saved\nstrokes are available (e.g. resuming from a server-stored bitmap in a fresh browser session)."
|
|
633
660
|
},
|
|
634
661
|
"getter": false,
|
|
635
662
|
"setter": false,
|
|
636
663
|
"reflect": false,
|
|
637
664
|
"attribute": "initial-initials"
|
|
665
|
+
},
|
|
666
|
+
"initialSignatureStrokes": {
|
|
667
|
+
"type": "unknown",
|
|
668
|
+
"mutable": false,
|
|
669
|
+
"complexType": {
|
|
670
|
+
"original": "Array<Array<{x: number; y: number}>>",
|
|
671
|
+
"resolved": "{ x: number; y: number; }[][]",
|
|
672
|
+
"references": {
|
|
673
|
+
"Array": {
|
|
674
|
+
"location": "global",
|
|
675
|
+
"id": "global::Array"
|
|
676
|
+
}
|
|
677
|
+
}
|
|
678
|
+
},
|
|
679
|
+
"required": false,
|
|
680
|
+
"optional": true,
|
|
681
|
+
"docs": {
|
|
682
|
+
"tags": [],
|
|
683
|
+
"text": "If set, restores the exact strokes of a previously hand-drawn signature so it can be replayed and edited natively\ninstead of being reconstructed from a bitmap. Coordinates are normalized (0..1) relative to the canvas."
|
|
684
|
+
},
|
|
685
|
+
"getter": false,
|
|
686
|
+
"setter": false
|
|
687
|
+
},
|
|
688
|
+
"initialInitialsStrokes": {
|
|
689
|
+
"type": "unknown",
|
|
690
|
+
"mutable": false,
|
|
691
|
+
"complexType": {
|
|
692
|
+
"original": "Array<Array<{x: number; y: number}>>",
|
|
693
|
+
"resolved": "{ x: number; y: number; }[][]",
|
|
694
|
+
"references": {
|
|
695
|
+
"Array": {
|
|
696
|
+
"location": "global",
|
|
697
|
+
"id": "global::Array"
|
|
698
|
+
}
|
|
699
|
+
}
|
|
700
|
+
},
|
|
701
|
+
"required": false,
|
|
702
|
+
"optional": true,
|
|
703
|
+
"docs": {
|
|
704
|
+
"tags": [],
|
|
705
|
+
"text": "If set, restores the exact strokes of previously hand-drawn initials. See initialSignatureStrokes."
|
|
706
|
+
},
|
|
707
|
+
"getter": false,
|
|
708
|
+
"setter": false
|
|
638
709
|
}
|
|
639
710
|
};
|
|
640
711
|
}
|
|
@@ -658,12 +729,17 @@ export class VerdocsAdoptSignatureDialog {
|
|
|
658
729
|
"composed": true,
|
|
659
730
|
"docs": {
|
|
660
731
|
"tags": [],
|
|
661
|
-
"text": "Fired when the user completes the dialog and clicks Adopt. The event detail
|
|
732
|
+
"text": "Fired when the user completes the dialog and clicks Adopt. The event detail contains base64-encoded previews of the\nsignature and initials, plus the editable source (mode, name, and \u2014 for drawn signatures \u2014 the normalized strokes)\nso the adoption can be reopened and edited faithfully later."
|
|
662
733
|
},
|
|
663
734
|
"complexType": {
|
|
664
|
-
"original": "{signature: string
|
|
665
|
-
"resolved": "{ signature: string; initials: string; mode: \"type\" | \"draw\"; name: string; }",
|
|
666
|
-
"references": {
|
|
735
|
+
"original": "{\n signature: string;\n initials: string;\n mode: 'type' | 'draw';\n name: string;\n signatureStrokes: Array<Array<{x: number; y: number}>>;\n initialsStrokes: Array<Array<{x: number; y: number}>>;\n }",
|
|
736
|
+
"resolved": "{ signature: string; initials: string; mode: \"type\" | \"draw\"; name: string; signatureStrokes: { x: number; y: number; }[][]; initialsStrokes: { x: number; y: number; }[][]; }",
|
|
737
|
+
"references": {
|
|
738
|
+
"Array": {
|
|
739
|
+
"location": "global",
|
|
740
|
+
"id": "global::Array"
|
|
741
|
+
}
|
|
742
|
+
}
|
|
667
743
|
}
|
|
668
744
|
}, {
|
|
669
745
|
"method": "exit",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"verdocs-adopt-signature-dialog.js","sourceRoot":"","sources":["../../../../src/components/dialogs/verdocs-adopt-signature-dialog/verdocs-adopt-signature-dialog.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,KAAK,EAAgB,KAAK,EAAC,MAAM,eAAe,CAAC;AAC7E,OAAO,EAAC,cAAc,EAAC,MAAM,sBAAsB,CAAC;AAEpD;;;GAGG;AAKH,MAAM,OAAO,2BAA2B;IAJxC;QAUE;;WAEG;QACK,SAAI,GAAW,EAAE,CAAC;QAE1B;;WAEG;QACK,eAAU,GAAY,KAAK,CAAC;QAiC3B,eAAU,GAAG,KAAK,CAAC;QACnB,gBAAW,GAAW,EAAE,CAAC;QACzB,oBAAe,GAAW,EAAE,CAAC;QAC7B,SAAI,GAAoB,MAAM,CAAC;QAC/B,cAAS,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AY,sSAGjB,CACF;YAEN,4DAAK,KAAK,EAAC,QAAQ,EAAC,IAAI,EAAC,QAAQ;gBAC/B,4DAAK,KAAK,EAAC,SAAS;oBAClB,+DAAQ,KAAK,EAAC,QAAQ,EAAC,OAAO,EAAE,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC,aAEhD;oBACT,+DAAQ,KAAK,EAAC,SAAS,EAAC,OAAO,EAAE,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,CAAC,qBAAqB,EAAE,mBAExF,CACL,CACF,CACS,CAClB,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import {Component, Prop, h, Event, EventEmitter, State} from '@stencil/core';\nimport {SignatureXIcon} from '../../../utils/Icons';\n\n/**\n * Display a dialog that allows the user to specify a signature image, either by using a signature-font-generated image\n * based on their full name, or by hand-drawing their signature with a mouse or tablet.\n */\n@Component({\n tag: 'verdocs-adopt-signature-dialog',\n styleUrl: 'verdocs-adopt-signature-dialog.scss',\n})\nexport class VerdocsAdoptSignatureDialog {\n private signatureElement?: HTMLCanvasElement;\n private initialsElement?: HTMLCanvasElement;\n private sigDrawingContext?: CanvasRenderingContext2D;\n private initialsDrawingContext?: CanvasRenderingContext2D;\n\n /**\n * Initial signature text\n */\n @Prop() name: string = '';\n\n /**\n * If true, the name fields will be read-only. Used when the sender has locked the recipient's name.\n */\n @Prop() nameLocked: boolean = false;\n\n /**\n * If set, restores the name last used when adopting (e.g. after Edit).\n */\n @Prop() initialEnteredName?: string;\n\n /**\n * If set, restores the signature style tab when reopening the dialog (e.g. after Edit).\n */\n @Prop() initialMode?: 'type' | 'draw';\n\n /**\n * If set, restores the previously adopted signature preview (base64 data URL).\n */\n @Prop() initialSignature?: string;\n\n /**\n * If set, restores the previously adopted initials preview (base64 data URL).\n */\n @Prop() initialInitials?: string;\n\n /**\n * Fired when the user completes the dialog and clicks Adopt. The event detail will contain a base64-encoded string\n * representation of the signature adopted.\n */\n @Event({composed: true}) next: EventEmitter<{signature: string; initials: string; mode: 'type' | 'draw'; name: string}>;\n\n /**\n * Event fired when the step is cancelled. This is called exit to avoid conflicts with the JS-reserved \"cancel\" event name.\n */\n @Event({composed: true}) exit: EventEmitter;\n\n @State() fontLoaded = false;\n @State() enteredName: string = '';\n @State() enteredInitials: string = '';\n @State() mode: 'type' | 'draw' = 'type';\n @State() isDrawing = false;\n @State() hasDrawnSignature = false;\n @State() hasDrawnInitials = false;\n\n private currentSigStroke: Array<{x: number; y: number}> = [];\n private allSigStrokes: Array<Array<{x: number; y: number}>> = [];\n private lastSigPoint: {x: number; y: number} | null = null;\n\n private currentInitialsStroke: Array<{x: number; y: number}> = [];\n private allInitialsStrokes: Array<Array<{x: number; y: number}>> = [];\n private lastInitialsPoint: {x: number; y: number} | null = null;\n\n componentWillLoad() {\n this.enteredName = this.initialEnteredName || this.name;\n this.computeEnteredInitials(this.enteredName);\n\n if (this.initialMode) {\n this.mode = this.initialMode;\n }\n\n const ds = new FontFace('Dancing Script', 'url(https://fonts.gstatic.com/s/dancingscript/v19/If2cXTr6YS-zF4S-kcSWSVi_sxjsohD9F50Ruu7BMSo3Sup6hNX6plRP.woff)');\n ds.load().then(font => {\n document.fonts.add(font);\n this.fontLoaded = true;\n });\n }\n\n componentDidLoad() {\n this.setupSignatureCanvas();\n this.setupInitialsCanvas();\n void this.loadExistingPreviews();\n }\n\n componentDidUpdate() {\n this.setupSignatureCanvas();\n this.setupInitialsCanvas();\n\n if (this.mode === 'type') {\n this.drawSignatureText();\n this.drawInitialsText();\n return;\n }\n\n // Redraw drawn signature when in draw mode\n if (this.allSigStrokes.length > 0) {\n this.redrawDrawnSignature();\n }\n if (this.allInitialsStrokes.length > 0) {\n this.redrawDrawnInitials();\n }\n }\n\n private drawImageOnCanvas(canvas: HTMLCanvasElement, dataUrl: string): Promise<void> {\n return new Promise((resolve, reject) => {\n const image = new Image();\n image.onload = () => {\n const context = canvas.getContext('2d');\n context.clearRect(0, 0, canvas.width, canvas.height);\n\n const padding = 24;\n const scale = Math.min((canvas.width - padding) / image.width, (canvas.height - padding) / image.height, 1);\n const width = image.width * scale;\n const height = image.height * scale;\n const x = (canvas.width - width) / 2;\n const y = (canvas.height - height) / 2;\n\n context.drawImage(image, x, y, width, height);\n resolve();\n };\n image.onerror = () => reject(new Error('Unable to load signature preview'));\n image.src = dataUrl;\n });\n }\n\n private async loadExistingPreviews() {\n if (this.mode === 'draw') {\n await this.restoreDrawnPreviewsIfNeeded();\n return;\n }\n\n this.drawSignatureText();\n this.drawInitialsText();\n }\n\n private setMode(mode: 'type' | 'draw') {\n this.mode = mode;\n\n if (mode === 'draw') {\n void this.restoreDrawnPreviewsIfNeeded();\n }\n }\n\n private async restoreDrawnPreviewsIfNeeded() {\n // Preserve in-session stroke edits; only restore saved previews when there are no strokes yet.\n if (this.allSigStrokes.length > 0 || this.allInitialsStrokes.length > 0) {\n return;\n }\n\n const tasks: Promise<void>[] = [];\n\n if (this.initialSignature && this.signatureElement) {\n tasks.push(\n this.drawImageOnCanvas(this.signatureElement, this.initialSignature).then(() => {\n this.hasDrawnSignature = true;\n }),\n );\n }\n\n if (this.initialInitials && this.initialsElement) {\n tasks.push(\n this.drawImageOnCanvas(this.initialsElement, this.initialInitials).then(() => {\n this.hasDrawnInitials = true;\n }),\n );\n }\n\n if (tasks.length === 0) {\n return;\n }\n\n await Promise.all(tasks);\n this.setupSignatureCanvas();\n this.setupInitialsCanvas();\n }\n\n drawSignatureText() {\n if (!this.signatureElement || this.mode !== 'type') {\n return;\n }\n\n const sigCanvasWidth = this.signatureElement.width;\n const sigCanvasHeight = this.signatureElement.height;\n const sigContext = this.signatureElement.getContext('2d');\n sigContext.clearRect(0, 0, this.signatureElement.width, this.signatureElement.height);\n\n let fontSize = 100;\n let metrics: TextMetrics = sigContext.measureText(this.enteredName);\n do {\n fontSize -= 2;\n sigContext.font = `${fontSize}px Dancing Script`;\n metrics = sigContext.measureText(this.enteredName);\n } while (metrics.width > sigCanvasWidth - 24 || metrics.actualBoundingBoxAscent + metrics.actualBoundingBoxDescent + 24 > sigCanvasHeight);\n\n sigContext.textAlign = 'center';\n sigContext.textBaseline = 'middle';\n sigContext.font = `${fontSize}px Dancing Script`;\n sigContext.fillText(this.enteredName, this.signatureElement.width / 2, this.signatureElement.height / 2);\n }\n\n drawInitialsText() {\n if (!this.initialsElement || this.mode !== 'type') {\n return;\n }\n\n const initialsCanvasWidth = this.initialsElement.width;\n const initialsCanvasHeight = this.initialsElement.height;\n const context = this.initialsElement.getContext('2d');\n context.clearRect(0, 0, this.initialsElement.width, this.initialsElement.height);\n\n let fontSize = 100;\n let metrics: TextMetrics = context.measureText(this.enteredInitials);\n do {\n fontSize -= 2;\n context.font = `${fontSize}px Dancing Script`;\n metrics = context.measureText(this.enteredInitials);\n } while (metrics.width > initialsCanvasWidth - 24 || metrics.actualBoundingBoxAscent + metrics.actualBoundingBoxDescent + 24 > initialsCanvasHeight);\n\n context.textAlign = 'center';\n context.textBaseline = 'middle';\n context.font = `${fontSize}px Dancing Script`;\n context.fillText(this.enteredInitials, this.initialsElement.width / 2, this.initialsElement.height / 2);\n }\n\n redrawDrawnSignature() {\n if (!this.signatureElement || !this.sigDrawingContext || this.allSigStrokes.length === 0) {\n return;\n }\n\n // Clear the canvas first\n this.sigDrawingContext.clearRect(0, 0, this.signatureElement.width, this.signatureElement.height);\n\n // Redraw all strokes\n for (const stroke of this.allSigStrokes) {\n if (stroke.length === 0) {\n continue;\n }\n\n // Start the path at the first point\n this.sigDrawingContext.beginPath();\n this.sigDrawingContext.moveTo(stroke[0].x, stroke[0].y);\n\n // Draw smooth curves through all points in the stroke\n for (let i = 1; i < stroke.length; i++) {\n const currentPoint = stroke[i];\n const previousPoint = stroke[i - 1];\n\n // Use quadratic curves for smooth lines\n const midPoint = {\n x: (previousPoint.x + currentPoint.x) / 2,\n y: (previousPoint.y + currentPoint.y) / 2,\n };\n\n this.sigDrawingContext.quadraticCurveTo(previousPoint.x, previousPoint.y, midPoint.x, midPoint.y);\n }\n\n // Draw to the last point\n if (stroke.length > 1) {\n const lastPoint = stroke[stroke.length - 1];\n this.sigDrawingContext.lineTo(lastPoint.x, lastPoint.y);\n }\n\n this.sigDrawingContext.stroke();\n }\n }\n\n redrawDrawnInitials() {\n if (!this.initialsElement || !this.initialsDrawingContext || this.allInitialsStrokes.length === 0) {\n return;\n }\n\n // Clear the canvas first\n this.initialsDrawingContext.clearRect(0, 0, this.initialsElement.width, this.initialsElement.height);\n\n // Redraw all strokes\n for (const stroke of this.allInitialsStrokes) {\n if (stroke.length === 0) {\n continue;\n }\n\n // Start the path at the first point\n this.initialsDrawingContext.beginPath();\n this.initialsDrawingContext.moveTo(stroke[0].x, stroke[0].y);\n\n // Draw smooth curves through all points in the stroke\n for (let i = 1; i < stroke.length; i++) {\n const currentPoint = stroke[i];\n const previousPoint = stroke[i - 1];\n\n // Use quadratic curves for smooth lines\n const midPoint = {\n x: (previousPoint.x + currentPoint.x) / 2,\n y: (previousPoint.y + currentPoint.y) / 2,\n };\n\n this.initialsDrawingContext.quadraticCurveTo(previousPoint.x, previousPoint.y, midPoint.x, midPoint.y);\n }\n\n // Draw to the last point\n if (stroke.length > 1) {\n const lastPoint = stroke[stroke.length - 1];\n this.initialsDrawingContext.lineTo(lastPoint.x, lastPoint.y);\n }\n\n this.initialsDrawingContext.stroke();\n }\n }\n\n handleNameChange(e: any) {\n this.enteredName = e.target.value;\n this.computeEnteredInitials(e.target.value);\n }\n\n computeEnteredInitials(name: string) {\n const nameComponents = name\n .trim()\n .split(' ')\n .filter(part => part.length > 0);\n\n this.enteredInitials = nameComponents.length > 1 ? nameComponents.map(word => word.charAt(0).toUpperCase()).join('') : nameComponents[0].toUpperCase();\n }\n\n handleCancel(e: any) {\n e.stopPropagation();\n e.preventDefault();\n this.exit.emit();\n }\n\n handleAdopt(e: any) {\n e.stopPropagation();\n e.preventDefault();\n const signature = this.signatureElement.toDataURL('image/png');\n const initials = this.initialsElement.toDataURL('image/png');\n this.next.emit({signature, initials, mode: this.mode, name: this.enteredName});\n }\n\n isAdoptButtonDisabled(): boolean {\n switch (this.mode) {\n case 'type':\n // Disable if no name has been entered\n return !this.enteredName || this.enteredName.trim().length === 0;\n case 'draw':\n // Disable if nothing has been drawn or restored from a previous adoption\n return !this.hasDrawnSignature || !this.hasDrawnInitials;\n default:\n return true;\n }\n }\n\n setupSignatureCanvas() {\n if (!this.signatureElement) {\n return;\n }\n\n // Set up drawing context when in draw mode\n if (this.mode === 'draw') {\n // Always get fresh context from the current canvas element\n const sigContext = this.signatureElement.getContext('2d');\n\n // Only initialize if we don't have a context or it's different\n if (sigContext && sigContext !== this.sigDrawingContext) {\n this.sigDrawingContext = sigContext;\n\n // Configure drawing style for smooth signatures\n this.sigDrawingContext.strokeStyle = '#000000';\n this.sigDrawingContext.lineWidth = 2;\n this.sigDrawingContext.lineCap = 'round';\n this.sigDrawingContext.lineJoin = 'round';\n\n // Clear canvas only if there are no existing strokes or restored previews\n if (this.allSigStrokes.length === 0 && !this.hasDrawnSignature) {\n this.sigDrawingContext.clearRect(0, 0, this.signatureElement.width, this.signatureElement.height);\n }\n }\n }\n\n // Reset drawing context when switching away from draw mode\n // NOTE: We don't clear allStrokes here so drawing persists when returning to draw mode\n if (this.mode !== 'draw' && this.sigDrawingContext) {\n this.sigDrawingContext = null;\n this.currentSigStroke = [];\n this.lastSigPoint = null;\n }\n }\n\n setupInitialsCanvas() {\n if (!this.initialsElement) {\n return;\n }\n\n // Set up drawing context when in draw mode\n if (this.mode === 'draw') {\n // Always get fresh context from the current canvas element\n const initialsContext = this.initialsElement.getContext('2d');\n\n // Only initialize if we don't have a context or it's different\n if (initialsContext && initialsContext !== this.initialsDrawingContext) {\n this.initialsDrawingContext = initialsContext;\n\n // Configure drawing style for smooth signatures\n this.initialsDrawingContext.strokeStyle = '#000000';\n this.initialsDrawingContext.lineWidth = 2;\n this.initialsDrawingContext.lineCap = 'round';\n this.initialsDrawingContext.lineJoin = 'round';\n\n // Clear canvas only if there are no existing strokes or restored previews\n if (this.allInitialsStrokes.length === 0 && !this.hasDrawnInitials) {\n this.initialsDrawingContext.clearRect(0, 0, this.initialsElement.width, this.initialsElement.height);\n }\n }\n }\n\n // Reset drawing context when switching away from draw mode\n // NOTE: We don't clear allStrokes here so drawing persists when returning to draw mode\n if (this.mode !== 'draw' && this.initialsDrawingContext) {\n this.initialsDrawingContext = null;\n this.currentInitialsStroke = [];\n this.lastInitialsPoint = null;\n }\n }\n\n clearSignatureCanvas() {\n if (!this.signatureElement || !this.sigDrawingContext) {\n return;\n }\n\n this.sigDrawingContext.clearRect(0, 0, this.signatureElement.width, this.signatureElement.height);\n this.currentSigStroke = [];\n this.allSigStrokes = [];\n this.lastSigPoint = null;\n this.hasDrawnSignature = false;\n }\n\n clearInitialsCanvas() {\n if (!this.initialsElement || !this.initialsDrawingContext) {\n return;\n }\n\n this.initialsDrawingContext.clearRect(0, 0, this.initialsElement.width, this.initialsElement.height);\n this.currentInitialsStroke = [];\n this.allInitialsStrokes = [];\n this.lastInitialsPoint = null;\n this.hasDrawnInitials = false;\n }\n\n handleClearDrawing(e: any, type: 'signature' | 'initials' | 'all' = 'all') {\n e.stopPropagation();\n e.preventDefault();\n if (type === 'all' || type === 'signature') this.clearSignatureCanvas();\n if (type === 'all' || type === 'initials') this.clearInitialsCanvas();\n }\n\n getSigCanvasCoordinates(e: PointerEvent): {x: number; y: number} {\n if (!this.signatureElement) {\n return {x: 0, y: 0};\n }\n\n const rect = this.signatureElement.getBoundingClientRect();\n\n // Calculate the scale factor between canvas size and display size\n const scaleX = this.signatureElement.width / rect.width;\n const scaleY = this.signatureElement.height / rect.height;\n\n return {\n x: (e.clientX - rect.left) * scaleX,\n y: (e.clientY - rect.top) * scaleY,\n };\n }\n\n getInitialsCanvasCoordinates(e: PointerEvent): {x: number; y: number} {\n if (!this.initialsElement) {\n return {x: 0, y: 0};\n }\n\n const rect = this.initialsElement.getBoundingClientRect();\n\n // Calculate the scale factor between canvas size and display size\n const scaleX = this.initialsElement.width / rect.width;\n const scaleY = this.initialsElement.height / rect.height;\n\n return {\n x: (e.clientX - rect.left) * scaleX,\n y: (e.clientY - rect.top) * scaleY,\n };\n }\n\n handleSigPointerDown = (e: PointerEvent) => {\n e.preventDefault();\n\n if (!this.signatureElement || !this.sigDrawingContext) {\n return;\n }\n\n this.isDrawing = true;\n this.hasDrawnSignature = true;\n\n const point = this.getSigCanvasCoordinates(e);\n this.currentSigStroke = [point];\n this.lastSigPoint = point;\n\n // Start a new path\n this.sigDrawingContext.beginPath();\n this.sigDrawingContext.moveTo(point.x, point.y);\n\n // Capture pointer to ensure we get all events even if pointer leaves canvas\n this.signatureElement.setPointerCapture(e.pointerId);\n };\n\n handleSigPointerMove = (e: PointerEvent) => {\n e.preventDefault();\n\n if (!this.isDrawing || !this.sigDrawingContext || !this.lastSigPoint) {\n return;\n }\n\n const point = this.getSigCanvasCoordinates(e);\n this.currentSigStroke.push(point);\n\n // Use quadratic curves for smooth drawing\n // The control point is the last point, and we draw to the midpoint\n const midPoint = {\n x: (this.lastSigPoint.x + point.x) / 2,\n y: (this.lastSigPoint.y + point.y) / 2,\n };\n\n this.sigDrawingContext.quadraticCurveTo(this.lastSigPoint.x, this.lastSigPoint.y, midPoint.x, midPoint.y);\n this.sigDrawingContext.stroke();\n\n this.lastSigPoint = point;\n };\n\n handleSigPointerUp = (e: PointerEvent) => {\n e.preventDefault();\n\n if (!this.isDrawing || !this.sigDrawingContext) {\n return;\n }\n\n // Complete the stroke\n if (this.lastSigPoint && this.currentSigStroke.length > 0) {\n this.sigDrawingContext.lineTo(this.lastSigPoint.x, this.lastSigPoint.y);\n this.sigDrawingContext.stroke();\n }\n\n // Save the completed stroke\n if (this.currentSigStroke.length > 0) {\n this.allSigStrokes.push([...this.currentSigStroke]);\n }\n\n this.isDrawing = false;\n this.currentSigStroke = [];\n this.lastSigPoint = null;\n\n // Release pointer capture\n if (this.signatureElement) {\n this.signatureElement.releasePointerCapture(e.pointerId);\n }\n };\n\n handleSigPointerCancel = (e: PointerEvent) => {\n // Handle cases where drawing is interrupted (e.g., phone call, notification)\n this.isDrawing = false;\n this.currentSigStroke = [];\n this.lastSigPoint = null;\n\n if (this.signatureElement) {\n this.signatureElement.releasePointerCapture(e.pointerId);\n }\n };\n\n handleInitialsPointerDown = (e: PointerEvent) => {\n e.preventDefault();\n\n if (!this.initialsElement || !this.initialsDrawingContext) {\n return;\n }\n\n this.isDrawing = true;\n this.hasDrawnInitials = true;\n\n const point = this.getInitialsCanvasCoordinates(e);\n this.currentInitialsStroke = [point];\n this.lastInitialsPoint = point;\n\n // Start a new path\n this.initialsDrawingContext.beginPath();\n this.initialsDrawingContext.moveTo(point.x, point.y);\n\n // Capture pointer to ensure we get all events even if pointer leaves canvas\n this.initialsElement.setPointerCapture(e.pointerId);\n };\n\n handleInitialsPointerMove = (e: PointerEvent) => {\n e.preventDefault();\n\n if (!this.isDrawing || !this.initialsDrawingContext || !this.lastInitialsPoint) {\n return;\n }\n\n const point = this.getInitialsCanvasCoordinates(e);\n this.currentInitialsStroke.push(point);\n\n // Use quadratic curves for smooth drawing\n // The control point is the last point, and we draw to the midpoint\n const midPoint = {\n x: (this.lastInitialsPoint.x + point.x) / 2,\n y: (this.lastInitialsPoint.y + point.y) / 2,\n };\n\n this.initialsDrawingContext.quadraticCurveTo(this.lastInitialsPoint.x, this.lastInitialsPoint.y, midPoint.x, midPoint.y);\n this.initialsDrawingContext.stroke();\n\n this.lastInitialsPoint = point;\n };\n\n handleInitialsPointerUp = (e: PointerEvent) => {\n e.preventDefault();\n\n if (!this.isDrawing || !this.initialsDrawingContext) {\n return;\n }\n\n // Complete the stroke\n if (this.lastInitialsPoint && this.currentInitialsStroke.length > 0) {\n this.initialsDrawingContext.lineTo(this.lastInitialsPoint.x, this.lastInitialsPoint.y);\n this.initialsDrawingContext.stroke();\n }\n\n // Save the completed stroke\n if (this.currentInitialsStroke.length > 0) {\n this.allInitialsStrokes.push([...this.currentInitialsStroke]);\n }\n\n this.isDrawing = false;\n this.currentInitialsStroke = [];\n this.lastInitialsPoint = null;\n\n // Release pointer capture\n if (this.initialsElement) {\n this.initialsElement.releasePointerCapture(e.pointerId);\n }\n };\n\n handleInitialsPointerCancel = (e: PointerEvent) => {\n // Handle cases where drawing is interrupted (e.g., phone call, notification)\n this.isDrawing = false;\n this.currentInitialsStroke = [];\n this.lastInitialsPoint = null;\n\n if (this.initialsElement) {\n this.initialsElement.releasePointerCapture(e.pointerId);\n }\n };\n\n render() {\n return (\n <verdocs-dialog persistent onExit={() => this.exit.emit()}>\n <div slot=\"heading\" class=\"heading\">\n Adopt Your Signature\n </div>\n\n <div slot=\"content\" class=\"content\">\n <div style={{fontWeight: '300', color: '#242424', fontSize: '13px'}}>Confirm your name, initials, and signature.</div>\n\n <div class={{type: true, active: this.mode === 'type'}}>\n <verdocs-text-input\n label=\"Full Name\"\n value={this.enteredName}\n disabled={this.nameLocked}\n onInput={e => this.handleNameChange(e)}\n onClick={e => e.stopPropagation()}\n />\n {this.nameLocked && <div class=\"name-locked-hint\">Your name has been set by the sender and cannot be changed.</div>}\n </div>\n\n <div style={{fontWeight: '400', color: '#242424', fontSize: '13px'}}>Select a signature style</div>\n\n <div style={{display: 'flex', flexDirection: 'row', gap: '10px', marginBottom: '6px', alignItems: 'center', fontSize: '13px'}}>\n <verdocs-radio-button checked={this.mode === 'type'} value=\"type\" name=\"mode\" onClick={() => this.setMode('type')} />\n <label>Typed with a keyboard</label>\n </div>\n <div style={{display: 'flex', flexDirection: 'row', gap: '10px', marginBottom: '6px', alignItems: 'center', fontSize: '13px'}}>\n <verdocs-radio-button checked={this.mode === 'draw'} value=\"draw\" name=\"mode\" onClick={() => this.setMode('draw')} />\n <label>Drawn with touch, mouse, or stylus</label>\n </div>\n\n <div class=\"preview-header\">\n <div style={{fontSize: '13px', fontWeight: '400'}}>Signature Preview</div>\n {this.mode === 'draw' && (\n <button class=\"clear-button-text\" onClick={e => this.handleClearDrawing(e, 'signature')} disabled={!this.hasDrawnSignature}>\n Clear\n </button>\n )}\n </div>\n <div class=\"canvas-container signature-container\">\n <div class=\"signing-indicator\">\n <div class=\"x-icon\" innerHTML={SignatureXIcon}></div>\n <div class=\"signing-line\"></div>\n </div>\n <canvas\n ref={el => (this.signatureElement = el as HTMLCanvasElement)}\n // width=\"300\"\n height=\"79\"\n class=\"signature-canvas\"\n onPointerDown={this.handleSigPointerDown}\n onPointerMove={this.handleSigPointerMove}\n onPointerUp={this.handleSigPointerUp}\n onPointerCancel={this.handleSigPointerCancel}\n style={{touchAction: 'none', cursor: 'crosshair'}}\n />\n </div>\n\n <div class=\"preview-header\">\n <div style={{fontSize: '13px', fontWeight: '400'}}>Initials Preview</div>\n {this.mode === 'draw' && (\n <button class=\"clear-button-text\" onClick={e => this.handleClearDrawing(e, 'initials')} disabled={!this.hasDrawnInitials}>\n Clear\n </button>\n )}\n </div>\n <div class=\"canvas-container initials-container\">\n <div class=\"signing-indicator\">\n <div class=\"x-icon\" innerHTML={SignatureXIcon}></div>\n <div class=\"signing-line\"></div>\n </div>\n <canvas\n ref={el => (this.initialsElement = el as HTMLCanvasElement)}\n // width=\"300\"\n height=\"79\"\n class=\"initials-canvas\"\n onPointerDown={this.handleInitialsPointerDown}\n onPointerMove={this.handleInitialsPointerMove}\n onPointerUp={this.handleInitialsPointerUp}\n onPointerCancel={this.handleInitialsPointerCancel}\n style={{touchAction: 'none', cursor: 'crosshair'}}\n />\n </div>\n\n <div class=\"disclaimer\">\n By clicking «Adopt Signature», I agree that the signature and initials above will be the electronic representation of my signature and initials for all purposes when I\n use them to sign documents. Applying them to a document is legally equivalent to signing with a pen on paper.\n </div>\n </div>\n\n <div class=\"footer\" slot=\"footer\">\n <div class=\"buttons\">\n <button class=\"cancel\" onClick={e => this.handleCancel(e)}>\n Cancel\n </button>\n <button class=\"proceed\" onClick={e => this.handleAdopt(e)} disabled={this.isAdoptButtonDisabled()}>\n Adopt & Sign\n </button>\n </div>\n </div>\n </verdocs-dialog>\n );\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"verdocs-adopt-signature-dialog.js","sourceRoot":"","sources":["../../../../src/components/dialogs/verdocs-adopt-signature-dialog/verdocs-adopt-signature-dialog.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,KAAK,EAAgB,KAAK,EAAC,MAAM,eAAe,CAAC;AAC7E,OAAO,EAAC,cAAc,EAAC,MAAM,sBAAsB,CAAC;AASpD;;;GAGG;AAKH,MAAM,OAAO,2BAA2B;IAJxC;QAUE;;WAEG;QACK,SAAI,GAAW,EAAE,CAAC;QAE1B;;WAEG;QACK,eAAU,GAAY,KAAK,CAAC;QAqD3B,eAAU,GAAG,KAAK,CAAC;QACnB,gBAAW,GAAW,EAAE,CAAC;QACzB,oBAAe,GAAW,EAAE,CAAC;QAC7B,SAAI,GAAoB,MAAM,CAAC;QAC/B,cAAS,GAAG,KAAK,CAAC;QAClB,sBAAiB,GAAG,KAAK,CAAC;QAC1B,qBAAgB,GAAG,KAAK,CAAC;QAE1B,qBAAgB,GAAkC,EAAE,CAAC;QACrD,kBAAa,GAAyC,EAAE,CAAC;QACzD,iBAAY,GAAkC,IAAI,CAAC;QAEnD,0BAAqB,GAAkC,EAAE,CAAC;QAC1D,uBAAkB,GAAyC,EAAE,CAAC;QAC9D,sBAAiB,GAAkC,IAAI,CAAC;QAqchE,yBAAoB,GAAG,CAAC,CAAe,EAAE,EAAE;YACzC,CAAC,CAAC,cAAc,EAAE,CAAC;YAEnB,IAAI,CAAC,IAAI,CAAC,gBAAgB,IAAI,CAAC,IA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,IAAI,EACX,KAAK,EAAC,iBAAiB,EACvB,aAAa,EAAE,IAAI,CAAC,yBAAyB,EAC7C,aAAa,EAAE,IAAI,CAAC,yBAAyB,EAC7C,WAAW,EAAE,IAAI,CAAC,uBAAuB,EACzC,eAAe,EAAE,IAAI,CAAC,2BAA2B,EACjD,KAAK,EAAE,EAAC,WAAW,EAAE,MAAM,EAAE,MAAM,EAAE,WAAW,EAAC,GACjD,CACE;gBAEN,4DAAK,KAAK,EAAC,YAAY,sSAGjB,CACF;YAEN,4DAAK,KAAK,EAAC,QAAQ,EAAC,IAAI,EAAC,QAAQ;gBAC/B,4DAAK,KAAK,EAAC,SAAS;oBAClB,+DAAQ,KAAK,EAAC,QAAQ,EAAC,OAAO,EAAE,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC,aAEhD;oBACT,+DAAQ,KAAK,EAAC,SAAS,EAAC,OAAO,EAAE,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,CAAC,qBAAqB,EAAE,mBAExF,CACL,CACF,CACS,CAClB,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import {Component, Prop, h, Event, EventEmitter, State} from '@stencil/core';\nimport {SignatureXIcon} from '../../../utils/Icons';\n\n/**\n * A single drawn stroke is an ordered list of points. Coordinates are stored normalized (0..1) relative to the canvas\n * size so a saved signature can be replayed faithfully regardless of the canvas' pixel dimensions.\n */\ntype TStroke = Array<{x: number; y: number}>;\ntype TStrokes = TStroke[];\n\n/**\n * Display a dialog that allows the user to specify a signature image, either by using a signature-font-generated image\n * based on their full name, or by hand-drawing their signature with a mouse or tablet.\n */\n@Component({\n tag: 'verdocs-adopt-signature-dialog',\n styleUrl: 'verdocs-adopt-signature-dialog.scss',\n})\nexport class VerdocsAdoptSignatureDialog {\n private signatureElement?: HTMLCanvasElement;\n private initialsElement?: HTMLCanvasElement;\n private sigDrawingContext?: CanvasRenderingContext2D;\n private initialsDrawingContext?: CanvasRenderingContext2D;\n\n /**\n * Initial signature text\n */\n @Prop() name: string = '';\n\n /**\n * If true, the name fields will be read-only. Used when the sender has locked the recipient's name.\n */\n @Prop() nameLocked: boolean = false;\n\n /**\n * If set, restores the name last used when adopting (e.g. after Edit).\n */\n @Prop() initialEnteredName?: string;\n\n /**\n * If set, restores the signature style tab when reopening the dialog (e.g. after Edit).\n */\n @Prop() initialMode?: 'type' | 'draw';\n\n /**\n * If set, restores the previously adopted signature preview (base64 data URL).\n */\n @Prop() initialSignature?: string;\n\n /**\n * If set, restores the previously adopted initials preview (base64 data URL). Used only as a fallback when no saved\n * strokes are available (e.g. resuming from a server-stored bitmap in a fresh browser session).\n */\n @Prop() initialInitials?: string;\n\n /**\n * If set, restores the exact strokes of a previously hand-drawn signature so it can be replayed and edited natively\n * instead of being reconstructed from a bitmap. Coordinates are normalized (0..1) relative to the canvas.\n */\n @Prop() initialSignatureStrokes?: Array<Array<{x: number; y: number}>>;\n\n /**\n * If set, restores the exact strokes of previously hand-drawn initials. See initialSignatureStrokes.\n */\n @Prop() initialInitialsStrokes?: Array<Array<{x: number; y: number}>>;\n\n /**\n * Fired when the user completes the dialog and clicks Adopt. The event detail contains base64-encoded previews of the\n * signature and initials, plus the editable source (mode, name, and — for drawn signatures — the normalized strokes)\n * so the adoption can be reopened and edited faithfully later.\n */\n @Event({composed: true}) next: EventEmitter<{\n signature: string;\n initials: string;\n mode: 'type' | 'draw';\n name: string;\n signatureStrokes: Array<Array<{x: number; y: number}>>;\n initialsStrokes: Array<Array<{x: number; y: number}>>;\n }>;\n\n /**\n * Event fired when the step is cancelled. This is called exit to avoid conflicts with the JS-reserved \"cancel\" event name.\n */\n @Event({composed: true}) exit: EventEmitter;\n\n @State() fontLoaded = false;\n @State() enteredName: string = '';\n @State() enteredInitials: string = '';\n @State() mode: 'type' | 'draw' = 'type';\n @State() isDrawing = false;\n @State() hasDrawnSignature = false;\n @State() hasDrawnInitials = false;\n\n private currentSigStroke: Array<{x: number; y: number}> = [];\n private allSigStrokes: Array<Array<{x: number; y: number}>> = [];\n private lastSigPoint: {x: number; y: number} | null = null;\n\n private currentInitialsStroke: Array<{x: number; y: number}> = [];\n private allInitialsStrokes: Array<Array<{x: number; y: number}>> = [];\n private lastInitialsPoint: {x: number; y: number} | null = null;\n\n componentWillLoad() {\n this.enteredName = this.initialEnteredName || this.name;\n this.computeEnteredInitials(this.enteredName);\n\n if (this.initialMode) {\n this.mode = this.initialMode;\n }\n\n const ds = new FontFace('Dancing Script', 'url(https://fonts.gstatic.com/s/dancingscript/v19/If2cXTr6YS-zF4S-kcSWSVi_sxjsohD9F50Ruu7BMSo3Sup6hNX6plRP.woff)');\n ds.load().then(font => {\n document.fonts.add(font);\n this.fontLoaded = true;\n });\n }\n\n componentDidLoad() {\n this.setupSignatureCanvas();\n this.setupInitialsCanvas();\n void this.loadExistingPreviews();\n }\n\n componentDidUpdate() {\n this.setupSignatureCanvas();\n this.setupInitialsCanvas();\n\n if (this.mode === 'type') {\n this.drawSignatureText();\n this.drawInitialsText();\n return;\n }\n\n // Redraw drawn signature when in draw mode\n if (this.allSigStrokes.length > 0) {\n this.redrawDrawnSignature();\n }\n if (this.allInitialsStrokes.length > 0) {\n this.redrawDrawnInitials();\n }\n }\n\n private drawImageOnCanvas(canvas: HTMLCanvasElement, dataUrl: string): Promise<void> {\n return new Promise((resolve, reject) => {\n const image = new Image();\n image.onload = () => {\n const context = canvas.getContext('2d');\n context.clearRect(0, 0, canvas.width, canvas.height);\n\n const padding = 24;\n const scale = Math.min((canvas.width - padding) / image.width, (canvas.height - padding) / image.height, 1);\n const width = image.width * scale;\n const height = image.height * scale;\n const x = (canvas.width - width) / 2;\n const y = (canvas.height - height) / 2;\n\n context.drawImage(image, x, y, width, height);\n resolve();\n };\n image.onerror = () => reject(new Error('Unable to load signature preview'));\n image.src = dataUrl;\n });\n }\n\n private async loadExistingPreviews() {\n if (this.mode === 'draw') {\n await this.restoreDrawnPreviewsIfNeeded();\n return;\n }\n\n this.drawSignatureText();\n this.drawInitialsText();\n }\n\n private setMode(mode: 'type' | 'draw') {\n this.mode = mode;\n\n if (mode === 'draw') {\n void this.restoreDrawnPreviewsIfNeeded();\n }\n }\n\n private async restoreDrawnPreviewsIfNeeded() {\n // Preserve in-session stroke edits; only restore saved previews when there are no strokes yet.\n if (this.allSigStrokes.length > 0 || this.allInitialsStrokes.length > 0) {\n return;\n }\n\n const tasks: Promise<void>[] = [];\n\n // Prefer replaying the saved strokes (faithful + editable). Fall back to the rasterized preview only when no\n // strokes are available, e.g. resuming from a server-stored bitmap in a fresh browser session.\n if (this.initialSignatureStrokes?.length && this.signatureElement) {\n this.allSigStrokes = this.denormalizeStrokes(this.initialSignatureStrokes, this.signatureElement);\n this.hasDrawnSignature = true;\n this.redrawDrawnSignature();\n } else if (this.initialSignature && this.signatureElement) {\n tasks.push(\n this.drawImageOnCanvas(this.signatureElement, this.initialSignature).then(() => {\n this.hasDrawnSignature = true;\n }),\n );\n }\n\n if (this.initialInitialsStrokes?.length && this.initialsElement) {\n this.allInitialsStrokes = this.denormalizeStrokes(this.initialInitialsStrokes, this.initialsElement);\n this.hasDrawnInitials = true;\n this.redrawDrawnInitials();\n } else if (this.initialInitials && this.initialsElement) {\n tasks.push(\n this.drawImageOnCanvas(this.initialsElement, this.initialInitials).then(() => {\n this.hasDrawnInitials = true;\n }),\n );\n }\n\n if (tasks.length === 0) {\n return;\n }\n\n await Promise.all(tasks);\n this.setupSignatureCanvas();\n this.setupInitialsCanvas();\n }\n\n drawSignatureText() {\n if (!this.signatureElement || this.mode !== 'type') {\n return;\n }\n\n const sigCanvasWidth = this.signatureElement.width;\n const sigCanvasHeight = this.signatureElement.height;\n const sigContext = this.signatureElement.getContext('2d');\n sigContext.clearRect(0, 0, this.signatureElement.width, this.signatureElement.height);\n\n let fontSize = 100;\n let metrics: TextMetrics = sigContext.measureText(this.enteredName);\n do {\n fontSize -= 2;\n sigContext.font = `${fontSize}px Dancing Script`;\n metrics = sigContext.measureText(this.enteredName);\n } while (metrics.width > sigCanvasWidth - 24 || metrics.actualBoundingBoxAscent + metrics.actualBoundingBoxDescent + 24 > sigCanvasHeight);\n\n sigContext.textAlign = 'center';\n sigContext.textBaseline = 'middle';\n sigContext.font = `${fontSize}px Dancing Script`;\n sigContext.fillText(this.enteredName, this.signatureElement.width / 2, this.signatureElement.height / 2);\n }\n\n drawInitialsText() {\n if (!this.initialsElement || this.mode !== 'type') {\n return;\n }\n\n const initialsCanvasWidth = this.initialsElement.width;\n const initialsCanvasHeight = this.initialsElement.height;\n const context = this.initialsElement.getContext('2d');\n context.clearRect(0, 0, this.initialsElement.width, this.initialsElement.height);\n\n let fontSize = 100;\n let metrics: TextMetrics = context.measureText(this.enteredInitials);\n do {\n fontSize -= 2;\n context.font = `${fontSize}px Dancing Script`;\n metrics = context.measureText(this.enteredInitials);\n } while (metrics.width > initialsCanvasWidth - 24 || metrics.actualBoundingBoxAscent + metrics.actualBoundingBoxDescent + 24 > initialsCanvasHeight);\n\n context.textAlign = 'center';\n context.textBaseline = 'middle';\n context.font = `${fontSize}px Dancing Script`;\n context.fillText(this.enteredInitials, this.initialsElement.width / 2, this.initialsElement.height / 2);\n }\n\n redrawDrawnSignature() {\n if (!this.signatureElement || !this.sigDrawingContext || this.allSigStrokes.length === 0) {\n return;\n }\n\n // Clear the canvas first\n this.sigDrawingContext.clearRect(0, 0, this.signatureElement.width, this.signatureElement.height);\n\n // Redraw all strokes\n for (const stroke of this.allSigStrokes) {\n if (stroke.length === 0) {\n continue;\n }\n\n // Start the path at the first point\n this.sigDrawingContext.beginPath();\n this.sigDrawingContext.moveTo(stroke[0].x, stroke[0].y);\n\n // Draw smooth curves through all points in the stroke\n for (let i = 1; i < stroke.length; i++) {\n const currentPoint = stroke[i];\n const previousPoint = stroke[i - 1];\n\n // Use quadratic curves for smooth lines\n const midPoint = {\n x: (previousPoint.x + currentPoint.x) / 2,\n y: (previousPoint.y + currentPoint.y) / 2,\n };\n\n this.sigDrawingContext.quadraticCurveTo(previousPoint.x, previousPoint.y, midPoint.x, midPoint.y);\n }\n\n // Draw to the last point\n if (stroke.length > 1) {\n const lastPoint = stroke[stroke.length - 1];\n this.sigDrawingContext.lineTo(lastPoint.x, lastPoint.y);\n }\n\n this.sigDrawingContext.stroke();\n }\n }\n\n redrawDrawnInitials() {\n if (!this.initialsElement || !this.initialsDrawingContext || this.allInitialsStrokes.length === 0) {\n return;\n }\n\n // Clear the canvas first\n this.initialsDrawingContext.clearRect(0, 0, this.initialsElement.width, this.initialsElement.height);\n\n // Redraw all strokes\n for (const stroke of this.allInitialsStrokes) {\n if (stroke.length === 0) {\n continue;\n }\n\n // Start the path at the first point\n this.initialsDrawingContext.beginPath();\n this.initialsDrawingContext.moveTo(stroke[0].x, stroke[0].y);\n\n // Draw smooth curves through all points in the stroke\n for (let i = 1; i < stroke.length; i++) {\n const currentPoint = stroke[i];\n const previousPoint = stroke[i - 1];\n\n // Use quadratic curves for smooth lines\n const midPoint = {\n x: (previousPoint.x + currentPoint.x) / 2,\n y: (previousPoint.y + currentPoint.y) / 2,\n };\n\n this.initialsDrawingContext.quadraticCurveTo(previousPoint.x, previousPoint.y, midPoint.x, midPoint.y);\n }\n\n // Draw to the last point\n if (stroke.length > 1) {\n const lastPoint = stroke[stroke.length - 1];\n this.initialsDrawingContext.lineTo(lastPoint.x, lastPoint.y);\n }\n\n this.initialsDrawingContext.stroke();\n }\n }\n\n handleNameChange(e: any) {\n this.enteredName = e.target.value;\n this.computeEnteredInitials(e.target.value);\n }\n\n computeEnteredInitials(name: string) {\n const nameComponents = name\n .trim()\n .split(' ')\n .filter(part => part.length > 0);\n\n this.enteredInitials = nameComponents.length > 1 ? nameComponents.map(word => word.charAt(0).toUpperCase()).join('') : nameComponents[0].toUpperCase();\n }\n\n handleCancel(e: any) {\n e.stopPropagation();\n e.preventDefault();\n this.exit.emit();\n }\n\n handleAdopt(e: any) {\n e.stopPropagation();\n e.preventDefault();\n const signature = this.signatureElement.toDataURL('image/png');\n const initials = this.initialsElement.toDataURL('image/png');\n\n // Persist the editable source for drawn signatures so a future Edit can replay the exact strokes natively rather\n // than reconstructing them from the bitmap. Typed signatures need no strokes — they re-render from the name.\n const signatureStrokes = this.mode === 'draw' ? this.normalizeStrokes(this.allSigStrokes, this.signatureElement) : [];\n const initialsStrokes = this.mode === 'draw' ? this.normalizeStrokes(this.allInitialsStrokes, this.initialsElement) : [];\n\n this.next.emit({signature, initials, mode: this.mode, name: this.enteredName, signatureStrokes, initialsStrokes});\n }\n\n private normalizeStrokes(strokes: TStrokes, canvas?: HTMLCanvasElement): TStrokes {\n const width = canvas?.width || 1;\n const height = canvas?.height || 1;\n return strokes.map(stroke => stroke.map(point => ({x: point.x / width, y: point.y / height})));\n }\n\n private denormalizeStrokes(strokes: TStrokes, canvas: HTMLCanvasElement): TStrokes {\n const width = canvas.width || 1;\n const height = canvas.height || 1;\n return strokes.map(stroke => stroke.map(point => ({x: point.x * width, y: point.y * height})));\n }\n\n isAdoptButtonDisabled(): boolean {\n switch (this.mode) {\n case 'type':\n // Disable if no name has been entered\n return !this.enteredName || this.enteredName.trim().length === 0;\n case 'draw':\n // Disable if nothing has been drawn or restored from a previous adoption\n return !this.hasDrawnSignature || !this.hasDrawnInitials;\n default:\n return true;\n }\n }\n\n setupSignatureCanvas() {\n if (!this.signatureElement) {\n return;\n }\n\n // Set up drawing context when in draw mode\n if (this.mode === 'draw') {\n // Always get fresh context from the current canvas element\n const sigContext = this.signatureElement.getContext('2d');\n\n // Only initialize if we don't have a context or it's different\n if (sigContext && sigContext !== this.sigDrawingContext) {\n this.sigDrawingContext = sigContext;\n\n // Configure drawing style for smooth signatures\n this.sigDrawingContext.strokeStyle = '#000000';\n this.sigDrawingContext.lineWidth = 2;\n this.sigDrawingContext.lineCap = 'round';\n this.sigDrawingContext.lineJoin = 'round';\n\n // Clear canvas only if there are no existing strokes or restored previews\n if (this.allSigStrokes.length === 0 && !this.hasDrawnSignature) {\n this.sigDrawingContext.clearRect(0, 0, this.signatureElement.width, this.signatureElement.height);\n }\n }\n }\n\n // Reset drawing context when switching away from draw mode\n // NOTE: We don't clear allStrokes here so drawing persists when returning to draw mode\n if (this.mode !== 'draw' && this.sigDrawingContext) {\n this.sigDrawingContext = null;\n this.currentSigStroke = [];\n this.lastSigPoint = null;\n }\n }\n\n setupInitialsCanvas() {\n if (!this.initialsElement) {\n return;\n }\n\n // Set up drawing context when in draw mode\n if (this.mode === 'draw') {\n // Always get fresh context from the current canvas element\n const initialsContext = this.initialsElement.getContext('2d');\n\n // Only initialize if we don't have a context or it's different\n if (initialsContext && initialsContext !== this.initialsDrawingContext) {\n this.initialsDrawingContext = initialsContext;\n\n // Configure drawing style for smooth signatures\n this.initialsDrawingContext.strokeStyle = '#000000';\n this.initialsDrawingContext.lineWidth = 2;\n this.initialsDrawingContext.lineCap = 'round';\n this.initialsDrawingContext.lineJoin = 'round';\n\n // Clear canvas only if there are no existing strokes or restored previews\n if (this.allInitialsStrokes.length === 0 && !this.hasDrawnInitials) {\n this.initialsDrawingContext.clearRect(0, 0, this.initialsElement.width, this.initialsElement.height);\n }\n }\n }\n\n // Reset drawing context when switching away from draw mode\n // NOTE: We don't clear allStrokes here so drawing persists when returning to draw mode\n if (this.mode !== 'draw' && this.initialsDrawingContext) {\n this.initialsDrawingContext = null;\n this.currentInitialsStroke = [];\n this.lastInitialsPoint = null;\n }\n }\n\n clearSignatureCanvas() {\n if (!this.signatureElement || !this.sigDrawingContext) {\n return;\n }\n\n this.sigDrawingContext.clearRect(0, 0, this.signatureElement.width, this.signatureElement.height);\n this.currentSigStroke = [];\n this.allSigStrokes = [];\n this.lastSigPoint = null;\n this.hasDrawnSignature = false;\n }\n\n clearInitialsCanvas() {\n if (!this.initialsElement || !this.initialsDrawingContext) {\n return;\n }\n\n this.initialsDrawingContext.clearRect(0, 0, this.initialsElement.width, this.initialsElement.height);\n this.currentInitialsStroke = [];\n this.allInitialsStrokes = [];\n this.lastInitialsPoint = null;\n this.hasDrawnInitials = false;\n }\n\n handleClearDrawing(e: any, type: 'signature' | 'initials' | 'all' = 'all') {\n e.stopPropagation();\n e.preventDefault();\n if (type === 'all' || type === 'signature') this.clearSignatureCanvas();\n if (type === 'all' || type === 'initials') this.clearInitialsCanvas();\n }\n\n getSigCanvasCoordinates(e: PointerEvent): {x: number; y: number} {\n if (!this.signatureElement) {\n return {x: 0, y: 0};\n }\n\n const rect = this.signatureElement.getBoundingClientRect();\n\n // Calculate the scale factor between canvas size and display size\n const scaleX = this.signatureElement.width / rect.width;\n const scaleY = this.signatureElement.height / rect.height;\n\n return {\n x: (e.clientX - rect.left) * scaleX,\n y: (e.clientY - rect.top) * scaleY,\n };\n }\n\n getInitialsCanvasCoordinates(e: PointerEvent): {x: number; y: number} {\n if (!this.initialsElement) {\n return {x: 0, y: 0};\n }\n\n const rect = this.initialsElement.getBoundingClientRect();\n\n // Calculate the scale factor between canvas size and display size\n const scaleX = this.initialsElement.width / rect.width;\n const scaleY = this.initialsElement.height / rect.height;\n\n return {\n x: (e.clientX - rect.left) * scaleX,\n y: (e.clientY - rect.top) * scaleY,\n };\n }\n\n handleSigPointerDown = (e: PointerEvent) => {\n e.preventDefault();\n\n if (!this.signatureElement || !this.sigDrawingContext) {\n return;\n }\n\n this.isDrawing = true;\n this.hasDrawnSignature = true;\n\n const point = this.getSigCanvasCoordinates(e);\n this.currentSigStroke = [point];\n this.lastSigPoint = point;\n\n // Start a new path\n this.sigDrawingContext.beginPath();\n this.sigDrawingContext.moveTo(point.x, point.y);\n\n // Capture pointer to ensure we get all events even if pointer leaves canvas\n this.signatureElement.setPointerCapture(e.pointerId);\n };\n\n handleSigPointerMove = (e: PointerEvent) => {\n e.preventDefault();\n\n if (!this.isDrawing || !this.sigDrawingContext || !this.lastSigPoint) {\n return;\n }\n\n const point = this.getSigCanvasCoordinates(e);\n this.currentSigStroke.push(point);\n\n // Use quadratic curves for smooth drawing\n // The control point is the last point, and we draw to the midpoint\n const midPoint = {\n x: (this.lastSigPoint.x + point.x) / 2,\n y: (this.lastSigPoint.y + point.y) / 2,\n };\n\n this.sigDrawingContext.quadraticCurveTo(this.lastSigPoint.x, this.lastSigPoint.y, midPoint.x, midPoint.y);\n this.sigDrawingContext.stroke();\n\n this.lastSigPoint = point;\n };\n\n handleSigPointerUp = (e: PointerEvent) => {\n e.preventDefault();\n\n if (!this.isDrawing || !this.sigDrawingContext) {\n return;\n }\n\n // Complete the stroke\n if (this.lastSigPoint && this.currentSigStroke.length > 0) {\n this.sigDrawingContext.lineTo(this.lastSigPoint.x, this.lastSigPoint.y);\n this.sigDrawingContext.stroke();\n }\n\n // Save the completed stroke\n if (this.currentSigStroke.length > 0) {\n this.allSigStrokes.push([...this.currentSigStroke]);\n }\n\n this.isDrawing = false;\n this.currentSigStroke = [];\n this.lastSigPoint = null;\n\n // Release pointer capture\n if (this.signatureElement) {\n this.signatureElement.releasePointerCapture(e.pointerId);\n }\n };\n\n handleSigPointerCancel = (e: PointerEvent) => {\n // Handle cases where drawing is interrupted (e.g., phone call, notification)\n this.isDrawing = false;\n this.currentSigStroke = [];\n this.lastSigPoint = null;\n\n if (this.signatureElement) {\n this.signatureElement.releasePointerCapture(e.pointerId);\n }\n };\n\n handleInitialsPointerDown = (e: PointerEvent) => {\n e.preventDefault();\n\n if (!this.initialsElement || !this.initialsDrawingContext) {\n return;\n }\n\n this.isDrawing = true;\n this.hasDrawnInitials = true;\n\n const point = this.getInitialsCanvasCoordinates(e);\n this.currentInitialsStroke = [point];\n this.lastInitialsPoint = point;\n\n // Start a new path\n this.initialsDrawingContext.beginPath();\n this.initialsDrawingContext.moveTo(point.x, point.y);\n\n // Capture pointer to ensure we get all events even if pointer leaves canvas\n this.initialsElement.setPointerCapture(e.pointerId);\n };\n\n handleInitialsPointerMove = (e: PointerEvent) => {\n e.preventDefault();\n\n if (!this.isDrawing || !this.initialsDrawingContext || !this.lastInitialsPoint) {\n return;\n }\n\n const point = this.getInitialsCanvasCoordinates(e);\n this.currentInitialsStroke.push(point);\n\n // Use quadratic curves for smooth drawing\n // The control point is the last point, and we draw to the midpoint\n const midPoint = {\n x: (this.lastInitialsPoint.x + point.x) / 2,\n y: (this.lastInitialsPoint.y + point.y) / 2,\n };\n\n this.initialsDrawingContext.quadraticCurveTo(this.lastInitialsPoint.x, this.lastInitialsPoint.y, midPoint.x, midPoint.y);\n this.initialsDrawingContext.stroke();\n\n this.lastInitialsPoint = point;\n };\n\n handleInitialsPointerUp = (e: PointerEvent) => {\n e.preventDefault();\n\n if (!this.isDrawing || !this.initialsDrawingContext) {\n return;\n }\n\n // Complete the stroke\n if (this.lastInitialsPoint && this.currentInitialsStroke.length > 0) {\n this.initialsDrawingContext.lineTo(this.lastInitialsPoint.x, this.lastInitialsPoint.y);\n this.initialsDrawingContext.stroke();\n }\n\n // Save the completed stroke\n if (this.currentInitialsStroke.length > 0) {\n this.allInitialsStrokes.push([...this.currentInitialsStroke]);\n }\n\n this.isDrawing = false;\n this.currentInitialsStroke = [];\n this.lastInitialsPoint = null;\n\n // Release pointer capture\n if (this.initialsElement) {\n this.initialsElement.releasePointerCapture(e.pointerId);\n }\n };\n\n handleInitialsPointerCancel = (e: PointerEvent) => {\n // Handle cases where drawing is interrupted (e.g., phone call, notification)\n this.isDrawing = false;\n this.currentInitialsStroke = [];\n this.lastInitialsPoint = null;\n\n if (this.initialsElement) {\n this.initialsElement.releasePointerCapture(e.pointerId);\n }\n };\n\n render() {\n return (\n <verdocs-dialog persistent onExit={() => this.exit.emit()}>\n <div slot=\"heading\" class=\"heading\">\n Adopt Your Signature\n </div>\n\n <div slot=\"content\" class=\"content\">\n <div style={{fontWeight: '300', color: '#242424', fontSize: '13px'}}>Confirm your name, initials, and signature.</div>\n\n <div class={{type: true, active: this.mode === 'type'}}>\n <verdocs-text-input\n label=\"Full Name\"\n value={this.enteredName}\n disabled={this.nameLocked}\n onInput={e => this.handleNameChange(e)}\n onClick={e => e.stopPropagation()}\n />\n {this.nameLocked && <div class=\"name-locked-hint\">Your name has been set by the sender and cannot be changed.</div>}\n </div>\n\n <div style={{fontWeight: '400', color: '#242424', fontSize: '13px'}}>Select a signature style</div>\n\n <div style={{display: 'flex', flexDirection: 'row', gap: '10px', marginBottom: '6px', alignItems: 'center', fontSize: '13px'}}>\n <verdocs-radio-button checked={this.mode === 'type'} value=\"type\" name=\"mode\" onClick={() => this.setMode('type')} />\n <label>Typed with a keyboard</label>\n </div>\n <div style={{display: 'flex', flexDirection: 'row', gap: '10px', marginBottom: '6px', alignItems: 'center', fontSize: '13px'}}>\n <verdocs-radio-button checked={this.mode === 'draw'} value=\"draw\" name=\"mode\" onClick={() => this.setMode('draw')} />\n <label>Drawn with touch, mouse, or stylus</label>\n </div>\n\n <div class=\"preview-header\">\n <div style={{fontSize: '13px', fontWeight: '400'}}>Signature Preview</div>\n {this.mode === 'draw' && (\n <button class=\"clear-button-text\" onClick={e => this.handleClearDrawing(e, 'signature')} disabled={!this.hasDrawnSignature}>\n Clear\n </button>\n )}\n </div>\n <div class=\"canvas-container signature-container\">\n <div class=\"signing-indicator\">\n <div class=\"x-icon\" innerHTML={SignatureXIcon}></div>\n <div class=\"signing-line\"></div>\n </div>\n <canvas\n ref={el => (this.signatureElement = el as HTMLCanvasElement)}\n // width=\"300\"\n height=\"79\"\n class=\"signature-canvas\"\n onPointerDown={this.handleSigPointerDown}\n onPointerMove={this.handleSigPointerMove}\n onPointerUp={this.handleSigPointerUp}\n onPointerCancel={this.handleSigPointerCancel}\n style={{touchAction: 'none', cursor: 'crosshair'}}\n />\n </div>\n\n <div class=\"preview-header\">\n <div style={{fontSize: '13px', fontWeight: '400'}}>Initials Preview</div>\n {this.mode === 'draw' && (\n <button class=\"clear-button-text\" onClick={e => this.handleClearDrawing(e, 'initials')} disabled={!this.hasDrawnInitials}>\n Clear\n </button>\n )}\n </div>\n <div class=\"canvas-container initials-container\">\n <div class=\"signing-indicator\">\n <div class=\"x-icon\" innerHTML={SignatureXIcon}></div>\n <div class=\"signing-line\"></div>\n </div>\n <canvas\n ref={el => (this.initialsElement = el as HTMLCanvasElement)}\n // width=\"300\"\n height=\"79\"\n class=\"initials-canvas\"\n onPointerDown={this.handleInitialsPointerDown}\n onPointerMove={this.handleInitialsPointerMove}\n onPointerUp={this.handleInitialsPointerUp}\n onPointerCancel={this.handleInitialsPointerCancel}\n style={{touchAction: 'none', cursor: 'crosshair'}}\n />\n </div>\n\n <div class=\"disclaimer\">\n By clicking «Adopt Signature», I agree that the signature and initials above will be the electronic representation of my signature and initials for all purposes when I\n use them to sign documents. Applying them to a document is legally equivalent to signing with a pen on paper.\n </div>\n </div>\n\n <div class=\"footer\" slot=\"footer\">\n <div class=\"buttons\">\n <button class=\"cancel\" onClick={e => this.handleCancel(e)}>\n Cancel\n </button>\n <button class=\"proceed\" onClick={e => this.handleAdopt(e)} disabled={this.isAdoptButtonDisabled()}>\n Adopt & Sign\n </button>\n </div>\n </div>\n </verdocs-dialog>\n );\n }\n}\n"]}
|