@verdocs/web-sdk 6.9.12 → 6.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/verdocs-adopt-signature-dialog_7.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-adopt-signature-dialog_7.cjs.entry.js.map +1 -1
- package/dist/cjs/verdocs-auth.cjs.entry.js +3 -0
- package/dist/cjs/verdocs-auth.cjs.entry.js.map +1 -1
- package/dist/cjs/verdocs-contact-picker.cjs.entry.js +422 -115
- package/dist/cjs/verdocs-contact-picker.cjs.entry.js.map +1 -1
- package/dist/cjs/verdocs-download-dialog_4.cjs.entry.js +6 -5
- package/dist/cjs/verdocs-download-dialog_4.cjs.entry.js.map +1 -1
- package/dist/cjs/verdocs-preview_6.cjs.entry.js +3 -0
- package/dist/cjs/verdocs-preview_6.cjs.entry.js.map +1 -1
- package/dist/cjs/verdocs-sign.cjs.entry.js +79 -20
- package/dist/cjs/verdocs-sign.cjs.entry.js.map +1 -1
- package/dist/collection/components/dialogs/verdocs-download-dialog/verdocs-download-dialog.js +6 -5
- package/dist/collection/components/dialogs/verdocs-download-dialog/verdocs-download-dialog.js.map +1 -1
- package/dist/collection/components/embeds/verdocs-auth/verdocs-auth.js +3 -0
- package/dist/collection/components/embeds/verdocs-auth/verdocs-auth.js.map +1 -1
- package/dist/collection/components/embeds/verdocs-send/verdocs-send.js +3 -0
- package/dist/collection/components/embeds/verdocs-send/verdocs-send.js.map +1 -1
- package/dist/collection/components/embeds/verdocs-sign/verdocs-sign.js +79 -20
- package/dist/collection/components/embeds/verdocs-sign/verdocs-sign.js.map +1 -1
- package/dist/collection/components/embeds/verdocs-view/verdocs-view.js +1 -1
- package/dist/collection/components/embeds/verdocs-view/verdocs-view.js.map +1 -1
- package/dist/components/{p-Ce29XBfJ.js → p-CBKrl6B7.js} +2 -2
- package/dist/components/{p-Ce29XBfJ.js.map → p-CBKrl6B7.js.map} +1 -1
- package/dist/components/p-CPYFXW2q.js +3 -0
- package/dist/components/p-CPYFXW2q.js.map +1 -0
- package/dist/components/{p-Bpe5Awxh.js → p-CnoHN1S8.js} +2 -2
- package/dist/components/p-CnoHN1S8.js.map +1 -0
- package/dist/components/{p-BVhOFpVZ.js → p-DfaM_cug.js} +2 -2
- package/dist/components/p-DfaM_cug.js.map +1 -0
- package/dist/components/verdocs-auth.js +1 -1
- package/dist/components/verdocs-auth.js.map +1 -1
- package/dist/components/verdocs-build.js +1 -1
- package/dist/components/verdocs-contact-picker.js +1 -1
- package/dist/components/verdocs-download-dialog.js +1 -1
- package/dist/components/verdocs-send.js +1 -1
- package/dist/components/verdocs-sign.js +1 -1
- package/dist/components/verdocs-sign.js.map +1 -1
- package/dist/components/verdocs-view.js +1 -1
- package/dist/esm/verdocs-adopt-signature-dialog_7.entry.js +1 -1
- package/dist/esm/verdocs-adopt-signature-dialog_7.entry.js.map +1 -1
- package/dist/esm/verdocs-auth.entry.js +3 -0
- package/dist/esm/verdocs-auth.entry.js.map +1 -1
- package/dist/esm/verdocs-contact-picker.entry.js +422 -115
- package/dist/esm/verdocs-contact-picker.entry.js.map +1 -1
- package/dist/esm/verdocs-download-dialog_4.entry.js +6 -5
- package/dist/esm/verdocs-download-dialog_4.entry.js.map +1 -1
- package/dist/esm/verdocs-preview_6.entry.js +3 -0
- package/dist/esm/verdocs-preview_6.entry.js.map +1 -1
- package/dist/esm/verdocs-sign.entry.js +80 -21
- package/dist/esm/verdocs-sign.entry.js.map +1 -1
- package/dist/esm-es5/verdocs-adopt-signature-dialog_7.entry.js +1 -1
- package/dist/esm-es5/verdocs-adopt-signature-dialog_7.entry.js.map +1 -1
- package/dist/esm-es5/verdocs-auth.entry.js +1 -1
- package/dist/esm-es5/verdocs-auth.entry.js.map +1 -1
- package/dist/esm-es5/verdocs-contact-picker.entry.js +2 -2
- package/dist/esm-es5/verdocs-contact-picker.entry.js.map +1 -1
- package/dist/esm-es5/verdocs-download-dialog_4.entry.js +1 -1
- package/dist/esm-es5/verdocs-download-dialog_4.entry.js.map +1 -1
- package/dist/esm-es5/verdocs-preview_6.entry.js +1 -1
- package/dist/esm-es5/verdocs-preview_6.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/types/components/embeds/verdocs-sign/verdocs-sign.d.ts +5 -0
- package/dist/verdocs-web-sdk/p-11c3e5bb.entry.js +2 -0
- package/dist/verdocs-web-sdk/p-11c3e5bb.entry.js.map +1 -0
- package/dist/verdocs-web-sdk/p-16d655d4.system.entry.js +2 -0
- package/dist/verdocs-web-sdk/p-16d655d4.system.entry.js.map +1 -0
- package/dist/verdocs-web-sdk/p-1ce27c81.system.entry.js +4 -0
- package/dist/verdocs-web-sdk/p-1ce27c81.system.entry.js.map +1 -0
- package/dist/verdocs-web-sdk/p-2d72560a.entry.js +2 -0
- package/dist/verdocs-web-sdk/p-2d72560a.entry.js.map +1 -0
- package/dist/verdocs-web-sdk/p-33cfc977.system.entry.js +2 -0
- package/dist/verdocs-web-sdk/p-33cfc977.system.entry.js.map +1 -0
- package/dist/verdocs-web-sdk/p-43ee0267.entry.js +2 -0
- package/dist/verdocs-web-sdk/p-43ee0267.entry.js.map +1 -0
- package/dist/verdocs-web-sdk/p-4e84a5b6.entry.js +3 -0
- package/dist/verdocs-web-sdk/p-4e84a5b6.entry.js.map +1 -0
- package/dist/verdocs-web-sdk/p-BdZ5Ghsa.system.js +1 -1
- package/dist/verdocs-web-sdk/{p-9756028f.entry.js → p-d0e8419b.entry.js} +2 -2
- package/dist/verdocs-web-sdk/p-d0e8419b.entry.js.map +1 -0
- package/dist/verdocs-web-sdk/{p-64034b55.system.entry.js → p-d60cfa3e.system.entry.js} +2 -2
- package/dist/verdocs-web-sdk/{p-64034b55.system.entry.js.map → p-d60cfa3e.system.entry.js.map} +1 -1
- package/dist/verdocs-web-sdk/p-e608d2bc.system.entry.js +2 -0
- package/dist/verdocs-web-sdk/p-e608d2bc.system.entry.js.map +1 -0
- package/dist/verdocs-web-sdk/{p-6abf8f8f.entry.js → p-e95723ac.entry.js} +2 -2
- package/dist/verdocs-web-sdk/{p-6abf8f8f.entry.js.map → p-e95723ac.entry.js.map} +1 -1
- package/dist/verdocs-web-sdk/{p-f85f8560.system.entry.js → p-edab1fed.system.entry.js} +2 -2
- package/dist/verdocs-web-sdk/p-edab1fed.system.entry.js.map +1 -0
- package/dist/verdocs-web-sdk/verdocs-web-sdk.esm.js +1 -1
- package/package.json +2 -2
- package/dist/components/p-BVhOFpVZ.js.map +0 -1
- package/dist/components/p-Bpe5Awxh.js.map +0 -1
- package/dist/components/p-DeQsR41s.js +0 -3
- package/dist/components/p-DeQsR41s.js.map +0 -1
- package/dist/verdocs-web-sdk/p-0240a6e1.system.entry.js +0 -2
- package/dist/verdocs-web-sdk/p-0240a6e1.system.entry.js.map +0 -1
- package/dist/verdocs-web-sdk/p-12676649.entry.js +0 -2
- package/dist/verdocs-web-sdk/p-12676649.entry.js.map +0 -1
- package/dist/verdocs-web-sdk/p-1a6869c9.system.entry.js +0 -2
- package/dist/verdocs-web-sdk/p-1a6869c9.system.entry.js.map +0 -1
- package/dist/verdocs-web-sdk/p-3a542ed0.system.entry.js +0 -4
- package/dist/verdocs-web-sdk/p-3a542ed0.system.entry.js.map +0 -1
- package/dist/verdocs-web-sdk/p-3f5ad836.system.entry.js +0 -2
- package/dist/verdocs-web-sdk/p-3f5ad836.system.entry.js.map +0 -1
- package/dist/verdocs-web-sdk/p-9756028f.entry.js.map +0 -1
- package/dist/verdocs-web-sdk/p-9c6cca6e.entry.js +0 -2
- package/dist/verdocs-web-sdk/p-9c6cca6e.entry.js.map +0 -1
- package/dist/verdocs-web-sdk/p-ae4290c6.entry.js +0 -3
- package/dist/verdocs-web-sdk/p-ae4290c6.entry.js.map +0 -1
- package/dist/verdocs-web-sdk/p-c89d74b2.entry.js +0 -2
- package/dist/verdocs-web-sdk/p-c89d74b2.entry.js.map +0 -1
- package/dist/verdocs-web-sdk/p-f85f8560.system.entry.js.map +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { r as registerInstance, c as createEvent, h, H as Host, F as Fragment, g as getElement } from './index-CjTHbolG.js';
|
|
2
|
-
import { VerdocsEndpoint, DEFAULT_DISCLOSURES, startSigningSession,
|
|
2
|
+
import { VerdocsEndpoint, DEFAULT_DISCLOSURES, startSigningSession, getEnvelope, envelopeRecipientAgree, updateEnvelopeField, createSignature, createInitials, sortFields, envelopeRecipientSubmit, isFieldValid, isFieldFilled, uploadEnvelopeFieldAttachment, deleteEnvelopeFieldAttachment, formatFullName, fullNameToInitials, verifySigner, getEnvelopesZip, getEnvelopeDocumentDownloadLink, getCombinedEnvelopeDocumentDownloadLink, delegateRecipient, envelopeRecipientDecline, integerSequence, askQuestion } from '@verdocs/js-sdk';
|
|
3
3
|
import { u as updateDocumentFieldValue, g as getFieldId, r as renderDocumentFlag, a as renderDocumentField, d as defaultHeight } from './utils-D9l-GFdv.js';
|
|
4
4
|
import { D as DownloadAction } from './Types-CIxfEdV7.js';
|
|
5
5
|
import { D as DocumentPageIcon, C as CheckCircleIcon } from './Icons-BU5rnXp2.js';
|
|
@@ -89,6 +89,14 @@ const VerdocsSign = class {
|
|
|
89
89
|
this.polling = true;
|
|
90
90
|
this.renderedPages = {};
|
|
91
91
|
this.pollingInterval = null;
|
|
92
|
+
this.handleDoneDialogDismiss = async () => {
|
|
93
|
+
this.showDone = false;
|
|
94
|
+
if (!this.isDone) {
|
|
95
|
+
this.prepareForViewTransition();
|
|
96
|
+
await new Promise(resolve => requestAnimationFrame(() => resolve()));
|
|
97
|
+
this.isDone = true;
|
|
98
|
+
}
|
|
99
|
+
};
|
|
92
100
|
}
|
|
93
101
|
async componentDidLoad() {
|
|
94
102
|
var _a, _b, _c, _d, _e, _f;
|
|
@@ -107,11 +115,7 @@ const VerdocsSign = class {
|
|
|
107
115
|
return;
|
|
108
116
|
}
|
|
109
117
|
try {
|
|
110
|
-
|
|
111
|
-
// NOTE: We don't listen to the store here because we are often an independent
|
|
112
|
-
// session and might have a different "view" of the envelope.
|
|
113
|
-
const response = await startSigningSession(this.endpoint, this.envelopeId, this.roleId, this.inviteCode);
|
|
114
|
-
this.processAuthResponse(response);
|
|
118
|
+
await this.initSigningSession();
|
|
115
119
|
}
|
|
116
120
|
catch (e) {
|
|
117
121
|
console.log('[SIGN] Error with signing session', e);
|
|
@@ -119,6 +123,56 @@ const VerdocsSign = class {
|
|
|
119
123
|
this.showLoadError = true;
|
|
120
124
|
}
|
|
121
125
|
}
|
|
126
|
+
async initSigningSession() {
|
|
127
|
+
console.log(`[SIGN] Processing invite code for ${this.envelopeId} / ${this.roleId}`);
|
|
128
|
+
// NOTE: We don't listen to the store here because we are often an independent
|
|
129
|
+
// session and might have a different "view" of the envelope.
|
|
130
|
+
const response = await startSigningSession(this.endpoint, this.envelopeId, this.roleId, this.inviteCode);
|
|
131
|
+
this.processAuthResponse(response);
|
|
132
|
+
}
|
|
133
|
+
async retrySigningSession() {
|
|
134
|
+
var _a, _b, _c;
|
|
135
|
+
this.showLoadError = false;
|
|
136
|
+
this.loading = true;
|
|
137
|
+
try {
|
|
138
|
+
await this.initSigningSession();
|
|
139
|
+
}
|
|
140
|
+
catch (e) {
|
|
141
|
+
console.log('[SIGN] Error with signing session', e);
|
|
142
|
+
(_a = this.sdkError) === null || _a === void 0 ? void 0 : _a.emit(new SDKError(e.message, (_b = e.response) === null || _b === void 0 ? void 0 : _b.status, (_c = e.response) === null || _c === void 0 ? void 0 : _c.data));
|
|
143
|
+
this.showLoadError = true;
|
|
144
|
+
this.loading = false;
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
prepareForViewTransition() {
|
|
148
|
+
var _a, _b, _c;
|
|
149
|
+
this.stopPolling();
|
|
150
|
+
(_a = this.observer) === null || _a === void 0 ? void 0 : _a.disconnect();
|
|
151
|
+
this.observer = null;
|
|
152
|
+
(_b = document.getElementById('air-datepicker-global-container')) === null || _b === void 0 ? void 0 : _b.remove();
|
|
153
|
+
(_c = document.getElementById('verdocs-sign-header')) === null || _c === void 0 ? void 0 : _c.remove();
|
|
154
|
+
}
|
|
155
|
+
async handleSubmitSuccess() {
|
|
156
|
+
var _a, _b;
|
|
157
|
+
this.submitting = false;
|
|
158
|
+
this.submitted = true;
|
|
159
|
+
this.nextSubmits = false;
|
|
160
|
+
this.signingProgressMode = 'completed';
|
|
161
|
+
try {
|
|
162
|
+
const envelope = await getEnvelope(this.endpoint, this.envelopeId);
|
|
163
|
+
this.envelope = envelope;
|
|
164
|
+
Store.updateEnvelope(this.envelopeId, envelope);
|
|
165
|
+
const updatedRecipient = (_a = envelope.recipients) === null || _a === void 0 ? void 0 : _a.find(r => { var _a; return r.role_name === ((_a = this.recipient) === null || _a === void 0 ? void 0 : _a.role_name); });
|
|
166
|
+
if (updatedRecipient) {
|
|
167
|
+
this.recipient = updatedRecipient;
|
|
168
|
+
}
|
|
169
|
+
(_b = this.envelopeUpdated) === null || _b === void 0 ? void 0 : _b.emit({ endpoint: this.endpoint, envelope, event: 'submitted' });
|
|
170
|
+
}
|
|
171
|
+
catch (e) {
|
|
172
|
+
console.warn('[SIGN] Error refreshing envelope after submit', e);
|
|
173
|
+
}
|
|
174
|
+
this.showDone = true;
|
|
175
|
+
}
|
|
122
176
|
componentDidRender() {
|
|
123
177
|
const headerTarget = this.headerTargetId ? document.getElementById(this.headerTargetId) : null;
|
|
124
178
|
const headerEl = document.getElementById('verdocs-sign-header');
|
|
@@ -274,7 +328,8 @@ const VerdocsSign = class {
|
|
|
274
328
|
handleClickAgree() {
|
|
275
329
|
this.submitting = true;
|
|
276
330
|
console.log('[SIGN] Accepting disclosures', this.disclosures);
|
|
277
|
-
|
|
331
|
+
const localeData = Intl.DateTimeFormat().resolvedOptions();
|
|
332
|
+
envelopeRecipientAgree(this.endpoint, this.envelopeId, this.roleId, this.disclosures, { locale: localeData.locale, timezone: localeData.timeZone })
|
|
278
333
|
.then(() => {
|
|
279
334
|
var _a;
|
|
280
335
|
this.nextButtonLabel = 'Next';
|
|
@@ -571,16 +626,17 @@ const VerdocsSign = class {
|
|
|
571
626
|
async handleNext() {
|
|
572
627
|
var _a;
|
|
573
628
|
if (this.nextSubmits) {
|
|
629
|
+
if (this.submitted) {
|
|
630
|
+
return;
|
|
631
|
+
}
|
|
574
632
|
try {
|
|
575
633
|
// Patches the date picker to be forcibly removed if still showing during submission
|
|
576
634
|
(_a = document.getElementById('air-datepicker-global-container')) === null || _a === void 0 ? void 0 : _a.remove();
|
|
577
635
|
this.submitting = true;
|
|
578
|
-
const
|
|
636
|
+
const localeData = Intl.DateTimeFormat().resolvedOptions();
|
|
637
|
+
const result = await envelopeRecipientSubmit(this.endpoint, this.envelopeId, this.roleId, { locale: localeData.locale, timezone: localeData.timeZone });
|
|
579
638
|
console.log('[SIGN] Submitted successfully', result);
|
|
580
|
-
|
|
581
|
-
// NotFoundError: Failed to execute 'insertBefore' on 'Node': The node before which
|
|
582
|
-
// the new node is to be inserted is not a child of this node.
|
|
583
|
-
window.location.reload();
|
|
639
|
+
await this.handleSubmitSuccess();
|
|
584
640
|
}
|
|
585
641
|
catch (e) {
|
|
586
642
|
console.log('[SIGN] Error submitting', e);
|
|
@@ -626,6 +682,9 @@ const VerdocsSign = class {
|
|
|
626
682
|
}
|
|
627
683
|
// See if everything that "needs to be" filled in is, and all "fillable fields" are valid
|
|
628
684
|
checkRecipientFields() {
|
|
685
|
+
if (this.submitted || this.isDone) {
|
|
686
|
+
return;
|
|
687
|
+
}
|
|
629
688
|
const invalidFields = this.getRecipientFields().filter(field => !isFieldValid(field, this.getRecipientFields()));
|
|
630
689
|
if (invalidFields.length < 1) {
|
|
631
690
|
this.nextButtonLabel = 'Finish';
|
|
@@ -988,7 +1047,7 @@ const VerdocsSign = class {
|
|
|
988
1047
|
var _a;
|
|
989
1048
|
if (this.showLoadError) {
|
|
990
1049
|
return (h(Host, null, h("verdocs-ok-dialog", { heading: "Unable to Start Signing", message: `Sorry, your invite code is invalid or has expired. Please check your email for an updated invitation, or contact the sender.`, buttonLabel: "OK", onNext: () => {
|
|
991
|
-
|
|
1050
|
+
this.retrySigningSession();
|
|
992
1051
|
} })));
|
|
993
1052
|
}
|
|
994
1053
|
if (!this.envelope) {
|
|
@@ -1004,8 +1063,7 @@ const VerdocsSign = class {
|
|
|
1004
1063
|
return (h(Host, { class: { agreed: this.agreed } }, h("verdocs-view", { endpoint: this.endpoint, envelopeId: this.envelopeId, onSdkError: e => { var _a; return (_a = this.sdkError) === null || _a === void 0 ? void 0 : _a.emit(e.detail); } }), this.showDone && (h("verdocs-ok-dialog", { heading: "You're Done!", message: `You can access the ${this.documentsSingularPlural} at any time by clicking on the link from the invitation email.<br /><br />After all recipients have completed their actions, you will receive an email with the document and envelope certificate attached.`, onNext: (e) => {
|
|
1005
1064
|
e.preventDefault();
|
|
1006
1065
|
e.stopPropagation();
|
|
1007
|
-
this.
|
|
1008
|
-
this.isDone = true;
|
|
1066
|
+
this.handleDoneDialogDismiss();
|
|
1009
1067
|
} })), this.submitting && (h("div", { class: "loading-indicator" }, h("verdocs-loader", null)))));
|
|
1010
1068
|
}
|
|
1011
1069
|
if (this.delegating) {
|
|
@@ -1028,7 +1086,9 @@ const VerdocsSign = class {
|
|
|
1028
1086
|
envelopeRecipientDecline(this.endpoint, this.envelopeId, this.roleId)
|
|
1029
1087
|
.then(r => {
|
|
1030
1088
|
console.log('[SIGN] Decline result', r);
|
|
1031
|
-
|
|
1089
|
+
this.declining = false;
|
|
1090
|
+
this.fatalErrorHeader = 'Declined';
|
|
1091
|
+
this.fatalErrorMessage = 'You have declined to sign this request. The sender has been notified.';
|
|
1032
1092
|
})
|
|
1033
1093
|
.catch(e => {
|
|
1034
1094
|
console.warn('[SIGN] Error declining signing session', e);
|
|
@@ -1096,7 +1156,7 @@ const VerdocsSign = class {
|
|
|
1096
1156
|
const totalPages = this.envelope.documents.reduce((acc, doc) => acc + doc.pages, 0);
|
|
1097
1157
|
const pageOptions = integerSequence(1, totalPages).map(p => ({ label: p.toString(), value: p.toString() }));
|
|
1098
1158
|
let globalPageCounter = 0;
|
|
1099
|
-
return (h(Host, null, this.toolbarStyle === 'menu' && (h("div", { id: "verdocs-sign-header" }, h("div", { class: "inner" }, h("div", { class: "title" }, this.envelope.name), h("div", { style: { flex: '1' } }), !this.finishLater &&
|
|
1159
|
+
return (h(Host, null, this.toolbarStyle === 'menu' && (h("div", { id: "verdocs-sign-header" }, h("div", { class: "inner" }, h("div", { class: "title" }, this.envelope.name), h("div", { style: { flex: '1' } }), !this.finishLater && !this.submitted &&
|
|
1100
1160
|
(() => {
|
|
1101
1161
|
const remaining = this.getRequiredTotalCount() - this.getRequiredFilledCount();
|
|
1102
1162
|
const optionalLeft = this.getOptionalUnfilledCount();
|
|
@@ -1104,7 +1164,7 @@ const VerdocsSign = class {
|
|
|
1104
1164
|
return (h("span", { class: "remaining-count" }, remaining, " required field", remaining === 1 ? '' : 's', " left"));
|
|
1105
1165
|
}
|
|
1106
1166
|
return (h("span", { class: "remaining-count" }, h("span", { class: "check-icon", innerHTML: CheckCircleIcon }), "All required fields complete", optionalLeft > 0 && (h("div", { class: "review-optional" }, h("span", { class: "separator" }, "| "), h("span", { onClick: () => this.handleNextOptional() }, "Review ", optionalLeft, " optional")))));
|
|
1107
|
-
})(), !this.finishLater && (h("verdocs-button", { size: "xsmall", label: this.nextButtonLabel === 'Next' ? 'Next Required' : this.nextButtonLabel, disabled: !this.agreed || this.submitting, onClick: () => this.handleNext() })), h("div", { class: { 'icon-button': true, 'minus': true, 'disabled': this.zoomLevel === 'normal', 'magnify': true }, innerHTML: ToolbarMinusIcon, onClick: () => this.handleZoomOut() }), h("div", { class: { 'icon-button': true, 'plus': true, 'disabled': this.zoomLevel === 'zoom2', 'magnify': true }, innerHTML: ToolbarPlusIcon, onClick: () => this.handleZoomIn() }), h("verdocs-dropdown", { options: !this.isDone && !this.finishLater ? inProgressMenuOptions : doneMenuOptions, onOptionSelected: e => this.handleOptionSelected(e) })))), this.toolbarStyle === 'controls' && (h("div", { class: "controls-toolbar" }, h("div", { class: "left-controls" }, h("div", { class: "title" }, this.envelope.name)), h("div", { class: "center-controls" }, h("span", { class: "label" }, "Page"), h("div", { class: "select-wrapper" }, h("verdocs-select-input", { options: pageOptions, value: this.pageNumber.toString(), onInput: e => this.handlePageSelect(e) })), h("span", { class: "count" }, "of ", totalPages)), h("div", { class: "right-controls" }, h("verdocs-button", { class: "mobile-next-button", label: this.nextButtonLabel, size: "xsmall", disabled: !this.agreed || this.submitting, onClick: () => this.handleNext() }), h("div", { class: { 'icon-button': true, 'minus': true, 'disabled': this.zoomLevel === 'normal' }, innerHTML: ToolbarMinusIcon, onClick: () => this.handleZoomOut() }), h("div", { class: { 'icon-button': true, 'plus': true, 'disabled': this.zoomLevel === 'zoom2' }, innerHTML: ToolbarPlusIcon, onClick: () => this.handleZoomIn() }), h("div", { class: "icon-button download", innerHTML: ToolbarDownloadIcon, onClick: () => this.handleOptionSelected({ detail: { id: 'download' } }) }), h("div", { class: "icon-button print", innerHTML: ToolbarPrintIcon, onClick: () => this.handleOptionSelected({ detail: { id: 'print' } }) })))), h("div", { class: `document signed-document-container zoom-${this.zoomLevel}` }, (this.envelope.documents || []).map(envelopeDocument => {
|
|
1167
|
+
})(), !this.finishLater && !this.submitted && (h("verdocs-button", { size: "xsmall", label: this.nextButtonLabel === 'Next' ? 'Next Required' : this.nextButtonLabel, disabled: !this.agreed || this.submitting || this.submitted, onClick: () => this.handleNext() })), h("div", { class: { 'icon-button': true, 'minus': true, 'disabled': this.zoomLevel === 'normal', 'magnify': true }, innerHTML: ToolbarMinusIcon, onClick: () => this.handleZoomOut() }), h("div", { class: { 'icon-button': true, 'plus': true, 'disabled': this.zoomLevel === 'zoom2', 'magnify': true }, innerHTML: ToolbarPlusIcon, onClick: () => this.handleZoomIn() }), h("verdocs-dropdown", { options: !this.isDone && !this.finishLater && !this.submitted ? inProgressMenuOptions : doneMenuOptions, onOptionSelected: e => this.handleOptionSelected(e) })))), this.toolbarStyle === 'controls' && (h("div", { class: "controls-toolbar" }, h("div", { class: "left-controls" }, h("div", { class: "title" }, this.envelope.name)), h("div", { class: "center-controls" }, h("span", { class: "label" }, "Page"), h("div", { class: "select-wrapper" }, h("verdocs-select-input", { options: pageOptions, value: this.pageNumber.toString(), onInput: e => this.handlePageSelect(e) })), h("span", { class: "count" }, "of ", totalPages)), h("div", { class: "right-controls" }, !this.submitted && (h("verdocs-button", { class: "mobile-next-button", label: this.nextButtonLabel, size: "xsmall", disabled: !this.agreed || this.submitting, onClick: () => this.handleNext() })), h("div", { class: { 'icon-button': true, 'minus': true, 'disabled': this.zoomLevel === 'normal' }, innerHTML: ToolbarMinusIcon, onClick: () => this.handleZoomOut() }), h("div", { class: { 'icon-button': true, 'plus': true, 'disabled': this.zoomLevel === 'zoom2' }, innerHTML: ToolbarPlusIcon, onClick: () => this.handleZoomIn() }), h("div", { class: "icon-button download", innerHTML: ToolbarDownloadIcon, onClick: () => this.handleOptionSelected({ detail: { id: 'download' } }) }), h("div", { class: "icon-button print", innerHTML: ToolbarPrintIcon, onClick: () => this.handleOptionSelected({ detail: { id: 'print' } }) })))), h("div", { class: `document signed-document-container zoom-${this.zoomLevel}` }, (this.envelope.documents || []).map(envelopeDocument => {
|
|
1108
1168
|
const pageNumbers = integerSequence(1, envelopeDocument.pages);
|
|
1109
1169
|
return (h(Fragment, null, this.envelope.documents.length > 1 && (h("div", { class: "document-separator" }, h("div", { innerHTML: DocumentPageIcon }), h("span", null, envelopeDocument.name))), pageNumbers.map(pageNumber => {
|
|
1110
1170
|
var _a;
|
|
@@ -1126,8 +1186,7 @@ const VerdocsSign = class {
|
|
|
1126
1186
|
this.isDone = true;
|
|
1127
1187
|
this.showFinishLater = false;
|
|
1128
1188
|
} })), this.showDone && (h("verdocs-ok-dialog", { heading: "You're Done!", message: `You can access the ${this.documentsSingularPlural} at any time by clicking on the link from the invitation email.<br /><br />After all recipients have completed their actions, you will receive an email with the document and envelope certificate attached.`, onNext: () => {
|
|
1129
|
-
this.
|
|
1130
|
-
this.isDone = true;
|
|
1189
|
+
this.handleDoneDialogDismiss();
|
|
1131
1190
|
} })), this.adoptingSignature && (h("verdocs-adopt-signature-dialog", { name: formatFullName(this.recipient), nameLocked: !!((_a = this.recipient) === null || _a === void 0 ? void 0 : _a.name_locked), onNext: async (e) => {
|
|
1132
1191
|
console.log('[SIGN] Adopting signature/initials block', e.detail);
|
|
1133
1192
|
this.showSpinner = true;
|
|
@@ -1165,7 +1224,7 @@ const VerdocsSign = class {
|
|
|
1165
1224
|
}, onExit: () => (this.adoptingSignature = false) })), (this.submitting || this.showSpinner) && (h("verdocs-portal", null, h("div", { class: "spinner-overlay" }, h("verdocs-spinner", null)))), this.showDownloadDialog && (h("verdocs-download-dialog", { signed: this.envelope.signed, polling: this.polling, documents: this.envelope.documents, onExit: () => {
|
|
1166
1225
|
this.showDownloadDialog = false;
|
|
1167
1226
|
this.stopPolling();
|
|
1168
|
-
}, onDownload: this.handleOnDownload })), !this.loading && !this.isDone && (h("verdocs-sign-footer", { endpoint: this.endpoint, envelopeId: this.envelopeId, isDone: this.isDone, onAskQuestion: (e) => {
|
|
1227
|
+
}, onDownload: e => this.handleOnDownload(e) })), !this.loading && !this.isDone && !this.submitted && (h("verdocs-sign-footer", { endpoint: this.endpoint, envelopeId: this.envelopeId, isDone: this.isDone, onAskQuestion: (e) => {
|
|
1169
1228
|
askQuestion(this.endpoint, this.envelopeId, this.roleId, { question: e.detail.question })
|
|
1170
1229
|
.then(() => VerdocsToast('Your question has been sent.', { style: 'success' }))
|
|
1171
1230
|
.catch(e => {
|