@verdocs/web-sdk 4.2.137 → 4.2.139
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-preview_9.cjs.entry.js +2 -2
- package/dist/cjs/verdocs-sign.cjs.entry.js +2 -2
- package/dist/collection/components/embeds/verdocs-send/verdocs-send.js +3 -3
- package/dist/collection/components/embeds/verdocs-sign/verdocs-sign.js +2 -2
- package/dist/components/verdocs-send2.js +3 -3
- package/dist/components/verdocs-sign.js +2 -2
- package/dist/custom-elements.json +2010 -0
- package/dist/esm/verdocs-preview_9.entry.js +3 -3
- package/dist/esm/verdocs-sign.entry.js +2 -2
- package/dist/esm-es5/verdocs-preview_9.entry.js +1 -1
- package/dist/esm-es5/verdocs-sign.entry.js +1 -1
- package/dist/types/components/envelopes/verdocs-envelope-recipient-summary/verdocs-envelope-recipient-summary.d.ts +1 -0
- package/dist/verdocs-web-sdk/p-0f677e5a.system.entry.js +1 -0
- package/dist/verdocs-web-sdk/p-267df026.system.js +1 -1
- package/dist/verdocs-web-sdk/p-3912a575.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-fd5ffce4.system.entry.js → p-937e21ca.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-97fa9395.entry.js +1 -0
- package/dist/verdocs-web-sdk/verdocs-web-sdk.esm.js +1 -1
- package/package.json +1 -1
- package/dist/verdocs-web-sdk/p-80635ee9.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-be247a01.system.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-de508a82.entry.js +0 -1
@@ -305,10 +305,10 @@ const VerdocsSend = class {
|
|
305
305
|
const allRolesAssigned = rolesAssigned.length >= roleNames.length;
|
306
306
|
console.log('[SEND] Roles completed', this.rolesCompleted);
|
307
307
|
return (index.h(index.Host, { class: { sendable: (_b = (_a = this.templateStore) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.is_sendable } }, index.h("div", { class: "recipients" }, index.h("div", { class: "left-line" }), index.h("div", { class: `level level-start` }, this.getLevelIcon(-1), index.h("div", { class: "complete" }, "Send Envelope")), levels.map(level => (index.h("div", { class: `level level-${level}` }, this.getLevelIcon(level), this.getRolesAtLevel(level).map(role => {
|
308
|
-
var _a, _b, _c, _d
|
308
|
+
var _a, _b, _c, _d;
|
309
309
|
const unknown = !role.email;
|
310
310
|
const elId = `verdocs-send-recipient-${role.role_name}`;
|
311
|
-
return unknown ? (index.h("div", { class: "recipient", "data-ri": TemplateRoleStore.getRoleIndex(this.roleStore, role.role_name), "data-rn": role.role_name, style: { backgroundColor: jsSdk.getRGBA(TemplateRoleStore.getRoleIndex(this.roleStore, role.role_name)) }, onClick: e => this.handleClickRole(e, role), id: elId }, (
|
311
|
+
return unknown ? (index.h("div", { class: "recipient", "data-ri": TemplateRoleStore.getRoleIndex(this.roleStore, role.role_name), "data-rn": role.role_name, style: { backgroundColor: jsSdk.getRGBA(TemplateRoleStore.getRoleIndex(this.roleStore, role.role_name)) }, onClick: e => this.handleClickRole(e, role), id: elId }, ((_a = this.rolesCompleted[role.id]) === null || _a === void 0 ? void 0 : _a.first_name) ? jsSdk.formatFullName(this.rolesCompleted[role.id]) : role.role_name, index.h("div", { class: "icon", innerHTML: editIcon }), this.showPickerForId === role.id && (index.h("verdocs-portal", { anchor: elId, onClickAway: () => (this.showPickerForId = '') }, index.h("verdocs-contact-picker", { onExit: () => (this.showPickerForId = ''), onNext: e => this.handleSelectContact(e, role), contactSuggestions: this.sessionContacts, templateRole: (_b = this.rolesCompleted[role.id]) !== null && _b !== void 0 ? _b : role, onSearchContacts: e => { var _a; return (_a = this.searchContacts) === null || _a === void 0 ? void 0 : _a.emit(e.detail); } }))))) : (index.h("div", { class: "recipient", style: { borderColor: jsSdk.getRGBA(TemplateRoleStore.getRoleIndex(this.roleStore, role.role_name)) }, onClick: e => this.handleClickRole(e, role), id: elId }, ((_c = this.rolesCompleted[role.id]) === null || _c === void 0 ? void 0 : _c.first_name) ? jsSdk.formatFullName(this.rolesCompleted[role.id]) : role.role_name, index.h("div", { class: "icon", innerHTML: editIcon }), this.showPickerForId === role.id && (index.h("verdocs-portal", { anchor: elId, onClickAway: () => (this.showPickerForId = '') }, index.h("verdocs-contact-picker", { onExit: () => (this.showPickerForId = ''), onNext: e => this.handleSelectContact(e, role), contactSuggestions: this.sessionContacts, templateRole: ((_d = this.rolesCompleted[role.id]) !== null && _d !== void 0 ? _d : role), onSearchContacts: e => { var _a; return (_a = this.searchContacts) === null || _a === void 0 ? void 0 : _a.emit(e.detail); } })))));
|
312
312
|
})))), index.h("div", { class: `level level-done` }, this.getLevelIcon(levels.length), index.h("div", { class: "complete" }, "Signing Complete"))), index.h("div", { class: "buttons" }, index.h("verdocs-button", { label: "Cancel", size: "small", variant: "outline", onClick: e => this.handleCancel(e), disabled: this.sending }), index.h("verdocs-button", { label: "Send", size: "small", disabled: !allRolesAssigned || this.sending, onClick: e => this.handleSend(e) }), this.sending && index.h("verdocs-spinner", null))));
|
313
313
|
}
|
314
314
|
static get watchers() { return {
|
@@ -314,6 +314,7 @@ const VerdocsSign = class {
|
|
314
314
|
isFieldFilled(field) {
|
315
315
|
const { value = '' } = field;
|
316
316
|
switch (field.type) {
|
317
|
+
case 'textarea':
|
317
318
|
case 'textbox':
|
318
319
|
switch (field.validator || '') {
|
319
320
|
case 'email':
|
@@ -330,9 +331,8 @@ const VerdocsSign = class {
|
|
330
331
|
// Timestamp fields get automatically filled when the envelope is submitted.
|
331
332
|
case 'timestamp':
|
332
333
|
return true;
|
333
|
-
case 'textarea':
|
334
334
|
case 'date':
|
335
|
-
return value
|
335
|
+
return !!value;
|
336
336
|
case 'attachment':
|
337
337
|
return value === 'attached';
|
338
338
|
case 'dropdown':
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { h, Host } from "@stencil/core";
|
2
|
-
import { createEnvelope, getOrganizationContacts, getRGBA, isValidEmail, isValidPhone, VerdocsEndpoint, } from "@verdocs/js-sdk";
|
2
|
+
import { createEnvelope, formatFullName, getOrganizationContacts, getRGBA, isValidEmail, isValidPhone, VerdocsEndpoint, } from "@verdocs/js-sdk";
|
3
3
|
import { getRoleIndex, getRoleNames, getTemplateRoleStore } from "../../../utils/TemplateRoleStore";
|
4
4
|
import { getTemplateStore } from "../../../utils/TemplateStore";
|
5
5
|
import { SDKError } from "../../../utils/errors";
|
@@ -218,10 +218,10 @@ export class VerdocsSend {
|
|
218
218
|
const allRolesAssigned = rolesAssigned.length >= roleNames.length;
|
219
219
|
console.log('[SEND] Roles completed', this.rolesCompleted);
|
220
220
|
return (h(Host, { class: { sendable: (_b = (_a = this.templateStore) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.is_sendable } }, h("div", { class: "recipients" }, h("div", { class: "left-line" }), h("div", { class: `level level-start` }, this.getLevelIcon(-1), h("div", { class: "complete" }, "Send Envelope")), levels.map(level => (h("div", { class: `level level-${level}` }, this.getLevelIcon(level), this.getRolesAtLevel(level).map(role => {
|
221
|
-
var _a, _b, _c, _d
|
221
|
+
var _a, _b, _c, _d;
|
222
222
|
const unknown = !role.email;
|
223
223
|
const elId = `verdocs-send-recipient-${role.role_name}`;
|
224
|
-
return unknown ? (h("div", { class: "recipient", "data-ri": getRoleIndex(this.roleStore, role.role_name), "data-rn": role.role_name, style: { backgroundColor: getRGBA(getRoleIndex(this.roleStore, role.role_name)) }, onClick: e => this.handleClickRole(e, role), id: elId }, (
|
224
|
+
return unknown ? (h("div", { class: "recipient", "data-ri": getRoleIndex(this.roleStore, role.role_name), "data-rn": role.role_name, style: { backgroundColor: getRGBA(getRoleIndex(this.roleStore, role.role_name)) }, onClick: e => this.handleClickRole(e, role), id: elId }, ((_a = this.rolesCompleted[role.id]) === null || _a === void 0 ? void 0 : _a.first_name) ? formatFullName(this.rolesCompleted[role.id]) : role.role_name, h("div", { class: "icon", innerHTML: editIcon }), this.showPickerForId === role.id && (h("verdocs-portal", { anchor: elId, onClickAway: () => (this.showPickerForId = '') }, h("verdocs-contact-picker", { onExit: () => (this.showPickerForId = ''), onNext: e => this.handleSelectContact(e, role), contactSuggestions: this.sessionContacts, templateRole: (_b = this.rolesCompleted[role.id]) !== null && _b !== void 0 ? _b : role, onSearchContacts: e => { var _a; return (_a = this.searchContacts) === null || _a === void 0 ? void 0 : _a.emit(e.detail); } }))))) : (h("div", { class: "recipient", style: { borderColor: getRGBA(getRoleIndex(this.roleStore, role.role_name)) }, onClick: e => this.handleClickRole(e, role), id: elId }, ((_c = this.rolesCompleted[role.id]) === null || _c === void 0 ? void 0 : _c.first_name) ? formatFullName(this.rolesCompleted[role.id]) : role.role_name, h("div", { class: "icon", innerHTML: editIcon }), this.showPickerForId === role.id && (h("verdocs-portal", { anchor: elId, onClickAway: () => (this.showPickerForId = '') }, h("verdocs-contact-picker", { onExit: () => (this.showPickerForId = ''), onNext: e => this.handleSelectContact(e, role), contactSuggestions: this.sessionContacts, templateRole: ((_d = this.rolesCompleted[role.id]) !== null && _d !== void 0 ? _d : role), onSearchContacts: e => { var _a; return (_a = this.searchContacts) === null || _a === void 0 ? void 0 : _a.emit(e.detail); } })))));
|
225
225
|
})))), h("div", { class: `level level-done` }, this.getLevelIcon(levels.length), h("div", { class: "complete" }, "Signing Complete"))), h("div", { class: "buttons" }, h("verdocs-button", { label: "Cancel", size: "small", variant: "outline", onClick: e => this.handleCancel(e), disabled: this.sending }), h("verdocs-button", { label: "Send", size: "small", disabled: !allRolesAssigned || this.sending, onClick: e => this.handleSend(e) }), this.sending && h("verdocs-spinner", null))));
|
226
226
|
}
|
227
227
|
static get is() { return "verdocs-send"; }
|
@@ -318,6 +318,7 @@ export class VerdocsSign {
|
|
318
318
|
isFieldFilled(field) {
|
319
319
|
const { value = '' } = field;
|
320
320
|
switch (field.type) {
|
321
|
+
case 'textarea':
|
321
322
|
case 'textbox':
|
322
323
|
switch (field.validator || '') {
|
323
324
|
case 'email':
|
@@ -334,9 +335,8 @@ export class VerdocsSign {
|
|
334
335
|
// Timestamp fields get automatically filled when the envelope is submitted.
|
335
336
|
case 'timestamp':
|
336
337
|
return true;
|
337
|
-
case 'textarea':
|
338
338
|
case 'date':
|
339
|
-
return value
|
339
|
+
return !!value;
|
340
340
|
case 'attachment':
|
341
341
|
return value === 'attached';
|
342
342
|
case 'dropdown':
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
|
2
|
-
import { VerdocsEndpoint, getOrganizationContacts, createEnvelope, isValidEmail, isValidPhone, getRGBA } from '@verdocs/js-sdk';
|
2
|
+
import { VerdocsEndpoint, getOrganizationContacts, createEnvelope, isValidEmail, isValidPhone, getRGBA, formatFullName } from '@verdocs/js-sdk';
|
3
3
|
import { g as getTemplateRoleStore, b as getRoleNames, a as getRoleIndex } from './TemplateRoleStore.js';
|
4
4
|
import { g as getTemplateStore } from './TemplateStore.js';
|
5
5
|
import { S as SDKError } from './errors.js';
|
@@ -220,10 +220,10 @@ const VerdocsSend = /*@__PURE__*/ proxyCustomElement(class VerdocsSend extends H
|
|
220
220
|
const allRolesAssigned = rolesAssigned.length >= roleNames.length;
|
221
221
|
console.log('[SEND] Roles completed', this.rolesCompleted);
|
222
222
|
return (h(Host, { class: { sendable: (_b = (_a = this.templateStore) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.is_sendable } }, h("div", { class: "recipients" }, h("div", { class: "left-line" }), h("div", { class: `level level-start` }, this.getLevelIcon(-1), h("div", { class: "complete" }, "Send Envelope")), levels.map(level => (h("div", { class: `level level-${level}` }, this.getLevelIcon(level), this.getRolesAtLevel(level).map(role => {
|
223
|
-
var _a, _b, _c, _d
|
223
|
+
var _a, _b, _c, _d;
|
224
224
|
const unknown = !role.email;
|
225
225
|
const elId = `verdocs-send-recipient-${role.role_name}`;
|
226
|
-
return unknown ? (h("div", { class: "recipient", "data-ri": getRoleIndex(this.roleStore, role.role_name), "data-rn": role.role_name, style: { backgroundColor: getRGBA(getRoleIndex(this.roleStore, role.role_name)) }, onClick: e => this.handleClickRole(e, role), id: elId }, (
|
226
|
+
return unknown ? (h("div", { class: "recipient", "data-ri": getRoleIndex(this.roleStore, role.role_name), "data-rn": role.role_name, style: { backgroundColor: getRGBA(getRoleIndex(this.roleStore, role.role_name)) }, onClick: e => this.handleClickRole(e, role), id: elId }, ((_a = this.rolesCompleted[role.id]) === null || _a === void 0 ? void 0 : _a.first_name) ? formatFullName(this.rolesCompleted[role.id]) : role.role_name, h("div", { class: "icon", innerHTML: editIcon }), this.showPickerForId === role.id && (h("verdocs-portal", { anchor: elId, onClickAway: () => (this.showPickerForId = '') }, h("verdocs-contact-picker", { onExit: () => (this.showPickerForId = ''), onNext: e => this.handleSelectContact(e, role), contactSuggestions: this.sessionContacts, templateRole: (_b = this.rolesCompleted[role.id]) !== null && _b !== void 0 ? _b : role, onSearchContacts: e => { var _a; return (_a = this.searchContacts) === null || _a === void 0 ? void 0 : _a.emit(e.detail); } }))))) : (h("div", { class: "recipient", style: { borderColor: getRGBA(getRoleIndex(this.roleStore, role.role_name)) }, onClick: e => this.handleClickRole(e, role), id: elId }, ((_c = this.rolesCompleted[role.id]) === null || _c === void 0 ? void 0 : _c.first_name) ? formatFullName(this.rolesCompleted[role.id]) : role.role_name, h("div", { class: "icon", innerHTML: editIcon }), this.showPickerForId === role.id && (h("verdocs-portal", { anchor: elId, onClickAway: () => (this.showPickerForId = '') }, h("verdocs-contact-picker", { onExit: () => (this.showPickerForId = ''), onNext: e => this.handleSelectContact(e, role), contactSuggestions: this.sessionContacts, templateRole: ((_d = this.rolesCompleted[role.id]) !== null && _d !== void 0 ? _d : role), onSearchContacts: e => { var _a; return (_a = this.searchContacts) === null || _a === void 0 ? void 0 : _a.emit(e.detail); } })))));
|
227
227
|
})))), h("div", { class: `level level-done` }, this.getLevelIcon(levels.length), h("div", { class: "complete" }, "Signing Complete"))), h("div", { class: "buttons" }, h("verdocs-button", { label: "Cancel", size: "small", variant: "outline", onClick: e => this.handleCancel(e), disabled: this.sending }), h("verdocs-button", { label: "Send", size: "small", disabled: !allRolesAssigned || this.sending, onClick: e => this.handleSend(e) }), this.sending && h("verdocs-spinner", null))));
|
228
228
|
}
|
229
229
|
static get watchers() { return {
|
@@ -317,6 +317,7 @@ const VerdocsSign$1 = /*@__PURE__*/ proxyCustomElement(class VerdocsSign extends
|
|
317
317
|
isFieldFilled(field) {
|
318
318
|
const { value = '' } = field;
|
319
319
|
switch (field.type) {
|
320
|
+
case 'textarea':
|
320
321
|
case 'textbox':
|
321
322
|
switch (field.validator || '') {
|
322
323
|
case 'email':
|
@@ -333,9 +334,8 @@ const VerdocsSign$1 = /*@__PURE__*/ proxyCustomElement(class VerdocsSign extends
|
|
333
334
|
// Timestamp fields get automatically filled when the envelope is submitted.
|
334
335
|
case 'timestamp':
|
335
336
|
return true;
|
336
|
-
case 'textarea':
|
337
337
|
case 'date':
|
338
|
-
return value
|
338
|
+
return !!value;
|
339
339
|
case 'attachment':
|
340
340
|
return value === 'attached';
|
341
341
|
case 'dropdown':
|