@verdocs/web-sdk 1.13.3 → 1.13.5
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-button-panel_3.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-checkbox_4.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-field-checkbox.cjs.entry.js +2 -2
- package/dist/cjs/verdocs-field-date.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-field-radio-button.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-field-textarea.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-field-textbox.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-sign.cjs.entry.js +9 -1
- package/dist/cjs/verdocs-template-create_3.cjs.entry.js +7 -2
- package/dist/cjs/verdocs-view.cjs.entry.js +20 -4
- package/dist/cjs/verdocs-web-sdk.cjs.js +1 -1
- package/dist/collection/components/controls/verdocs-checkbox/verdocs-checkbox.css +1 -1
- package/dist/collection/components/embeds/verdocs-sign/verdocs-sign.js +9 -1
- package/dist/collection/components/embeds/verdocs-view/verdocs-view.css +10 -0
- package/dist/collection/components/embeds/verdocs-view/verdocs-view.js +20 -4
- package/dist/collection/components/fields/verdocs-field-attachment/verdocs-field-attachment.js +3 -3
- package/dist/collection/components/fields/verdocs-field-checkbox/verdocs-field-checkbox.css +12 -11
- package/dist/collection/components/fields/verdocs-field-checkbox/verdocs-field-checkbox.js +4 -4
- package/dist/collection/components/fields/verdocs-field-date/verdocs-field-date.js +4 -4
- package/dist/collection/components/fields/verdocs-field-dropdown/verdocs-field-dropdown.js +3 -3
- package/dist/collection/components/fields/verdocs-field-initial/verdocs-field-initial.js +3 -3
- package/dist/collection/components/fields/verdocs-field-payment/verdocs-field-payment.js +3 -3
- package/dist/collection/components/fields/verdocs-field-radio-button-group/verdocs-field-radio-button.js +4 -4
- package/dist/collection/components/fields/verdocs-field-signature/verdocs-field-signature.js +3 -3
- package/dist/collection/components/fields/verdocs-field-textarea/verdocs-field-textarea.js +4 -4
- package/dist/collection/components/fields/verdocs-field-textbox/verdocs-field-textbox.js +4 -4
- package/dist/collection/components/fields/verdocs-field-timestamp/verdocs-field-timestamp.js +3 -3
- package/dist/collection/components/templates/verdocs-template-field-properties/verdocs-template-field-properties.js +1 -1
- package/dist/collection/components/templates/verdocs-template-fields/verdocs-template-fields.css +6 -1
- package/dist/collection/components/templates/verdocs-template-fields/verdocs-template-fields.js +6 -1
- package/dist/components/verdocs-checkbox2.js +1 -1
- package/dist/components/verdocs-field-checkbox.js +2 -2
- package/dist/components/verdocs-field-date.js +1 -1
- package/dist/components/verdocs-field-radio-button.js +1 -1
- package/dist/components/verdocs-field-textarea.js +1 -1
- package/dist/components/verdocs-field-textbox.js +1 -1
- package/dist/components/verdocs-sign.js +9 -1
- package/dist/components/verdocs-template-field-properties2.js +1 -1
- package/dist/components/verdocs-template-fields2.js +7 -2
- package/dist/components/verdocs-view2.js +33 -11
- package/dist/docs.json +34 -27
- package/dist/esm/loader.js +1 -1
- package/dist/esm/verdocs-button-panel_3.entry.js +1 -1
- package/dist/esm/verdocs-checkbox_4.entry.js +1 -1
- package/dist/esm/verdocs-field-checkbox.entry.js +2 -2
- package/dist/esm/verdocs-field-date.entry.js +1 -1
- package/dist/esm/verdocs-field-radio-button.entry.js +1 -1
- package/dist/esm/verdocs-field-textarea.entry.js +1 -1
- package/dist/esm/verdocs-field-textbox.entry.js +1 -1
- package/dist/esm/verdocs-sign.entry.js +9 -1
- package/dist/esm/verdocs-template-create_3.entry.js +7 -2
- package/dist/esm/verdocs-view.entry.js +20 -4
- package/dist/esm/verdocs-web-sdk.js +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/verdocs-button-panel_3.entry.js +1 -1
- package/dist/esm-es5/verdocs-checkbox_4.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-checkbox.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-date.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-radio-button.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-textarea.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-textbox.entry.js +1 -1
- package/dist/esm-es5/verdocs-sign.entry.js +1 -1
- package/dist/esm-es5/verdocs-template-create_3.entry.js +1 -1
- package/dist/esm-es5/verdocs-view.entry.js +1 -1
- package/dist/esm-es5/verdocs-web-sdk.js +1 -1
- package/dist/types/components/embeds/verdocs-view/verdocs-view.d.ts +1 -1
- package/dist/types/components/fields/verdocs-field-attachment/verdocs-field-attachment.d.ts +2 -2
- package/dist/types/components/fields/verdocs-field-checkbox/verdocs-field-checkbox.d.ts +2 -2
- package/dist/types/components/fields/verdocs-field-date/verdocs-field-date.d.ts +2 -2
- package/dist/types/components/fields/verdocs-field-dropdown/verdocs-field-dropdown.d.ts +2 -2
- package/dist/types/components/fields/verdocs-field-initial/verdocs-field-initial.d.ts +2 -2
- package/dist/types/components/fields/verdocs-field-payment/verdocs-field-payment.d.ts +2 -2
- package/dist/types/components/fields/verdocs-field-radio-button-group/verdocs-field-radio-button.d.ts +2 -2
- package/dist/types/components/fields/verdocs-field-signature/verdocs-field-signature.d.ts +2 -2
- package/dist/types/components/fields/verdocs-field-textarea/verdocs-field-textarea.d.ts +2 -2
- package/dist/types/components/fields/verdocs-field-textbox/verdocs-field-textbox.d.ts +2 -2
- package/dist/types/components/fields/verdocs-field-timestamp/verdocs-field-timestamp.d.ts +2 -2
- package/dist/types/components.d.ts +23 -23
- package/dist/types/utils/utils.d.ts +1 -1
- package/dist/verdocs-web-sdk/p-0714e785.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-59370436.system.entry.js → p-13f91d03.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-6a0e0615.system.entry.js → p-16f3cd2d.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-194a8f9c.system.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-bc287bf9.system.entry.js → p-1a34942f.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-d8343849.entry.js → p-39e906e0.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-7306abd0.system.entry.js → p-3b1b11a8.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-7a4d71b7.entry.js → p-40bb871d.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-8eca5dd8.entry.js → p-42fa6b2f.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-60b59333.system.entry.js +1 -0
- package/dist/verdocs-web-sdk/p-6caf1137.system.js +1 -1
- package/dist/verdocs-web-sdk/{p-ba62a8f6.system.entry.js → p-798c0134.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-923f56f3.entry.js +1 -0
- package/dist/verdocs-web-sdk/p-c2b91d4d.system.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-5a3d9d9f.system.entry.js → p-d595eba2.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-d643db3b.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-27fe6789.entry.js → p-e16ad8fe.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-92a2bb47.entry.js → p-ebce4300.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-eff8b358.entry.js +1 -0
- package/dist/verdocs-web-sdk/p-f2f3583f.system.entry.js +1 -0
- package/dist/verdocs-web-sdk/p-f44f5d73.entry.js +1 -0
- package/dist/verdocs-web-sdk/verdocs-web-sdk.esm.js +1 -1
- package/package.json +2 -2
- package/dist/typings.d.ts +0 -4
- package/dist/verdocs-web-sdk/p-09b008aa.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-22708d7d.system.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-2cb414ec.system.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-36a31514.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-530e47e2.system.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-84485446.system.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-8d32078d.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-d7ca70cc.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-f7910b66.entry.js +0 -1
@@ -62,7 +62,7 @@ export class VerdocsFieldDate {
|
|
62
62
|
const formatted = (settings === null || settings === void 0 ? void 0 : settings.result) ? format(new Date(settings === null || settings === void 0 ? void 0 : settings.result), 'PP') : '';
|
63
63
|
return h(Host, { class: { done: this.done } }, formatted);
|
64
64
|
}
|
65
|
-
return (h(Host, { class: { required: (_c = this.field) === null || _c === void 0 ? void 0 : _c.required, disabled }, style: { backgroundColor } }, h("input", { type: "text", value: "", id: this.containerId, disabled: disabled, placeholder: settings.placeholder, ref: el => (this.el = el) }), this.editable && (h("verdocs-button-panel", { icon: settingsIcon, id: `verdocs-settings-panel-${this.field.name}` }, h("verdocs-template-field-properties", { templateId: this.templateId, fieldName: this.field.name, onClose: () => this.hideSettingsPanel(), onDelete: () => {
|
65
|
+
return (h(Host, { class: { required: (_c = this.field) === null || _c === void 0 ? void 0 : _c.required, disabled }, style: { backgroundColor } }, h("input", { name: this.field.name, type: "text", value: "", id: this.containerId, disabled: disabled, placeholder: settings.placeholder, ref: el => (this.el = el) }), this.editable && (h("verdocs-button-panel", { icon: settingsIcon, id: `verdocs-settings-panel-${this.field.name}` }, h("verdocs-template-field-properties", { templateId: this.templateId, fieldName: this.field.name, onClose: () => this.hideSettingsPanel(), onDelete: () => {
|
66
66
|
var _a;
|
67
67
|
(_a = this.deleted) === null || _a === void 0 ? void 0 : _a.emit({ fieldName: this.field.name });
|
68
68
|
return this.hideSettingsPanel();
|
@@ -107,10 +107,10 @@ export class VerdocsFieldDate {
|
|
107
107
|
"type": "unknown",
|
108
108
|
"mutable": false,
|
109
109
|
"complexType": {
|
110
|
-
"original": "
|
111
|
-
"resolved": "
|
110
|
+
"original": "IEnvelopeField | ITemplateField | null",
|
111
|
+
"resolved": "IEnvelopeField | ITemplateField",
|
112
112
|
"references": {
|
113
|
-
"
|
113
|
+
"IEnvelopeField": {
|
114
114
|
"location": "import",
|
115
115
|
"path": "@verdocs/js-sdk/Envelopes/Types"
|
116
116
|
},
|
@@ -91,10 +91,10 @@ export class VerdocsFieldDropdown {
|
|
91
91
|
"type": "unknown",
|
92
92
|
"mutable": false,
|
93
93
|
"complexType": {
|
94
|
-
"original": "
|
95
|
-
"resolved": "
|
94
|
+
"original": "IEnvelopeField | ITemplateField | null",
|
95
|
+
"resolved": "IEnvelopeField | ITemplateField",
|
96
96
|
"references": {
|
97
|
-
"
|
97
|
+
"IEnvelopeField": {
|
98
98
|
"location": "import",
|
99
99
|
"path": "@verdocs/js-sdk/Envelopes/Types"
|
100
100
|
},
|
@@ -109,10 +109,10 @@ export class VerdocsFieldInitial {
|
|
109
109
|
"type": "unknown",
|
110
110
|
"mutable": false,
|
111
111
|
"complexType": {
|
112
|
-
"original": "
|
113
|
-
"resolved": "
|
112
|
+
"original": "IEnvelopeField | ITemplateField | null",
|
113
|
+
"resolved": "IEnvelopeField | ITemplateField",
|
114
114
|
"references": {
|
115
|
-
"
|
115
|
+
"IEnvelopeField": {
|
116
116
|
"location": "import",
|
117
117
|
"path": "@verdocs/js-sdk/Envelopes/Types"
|
118
118
|
},
|
@@ -146,10 +146,10 @@ export class VerdocsFieldPayment {
|
|
146
146
|
"type": "unknown",
|
147
147
|
"mutable": false,
|
148
148
|
"complexType": {
|
149
|
-
"original": "
|
150
|
-
"resolved": "
|
149
|
+
"original": "IEnvelopeField | ITemplateField | null",
|
150
|
+
"resolved": "IEnvelopeField | ITemplateField",
|
151
151
|
"references": {
|
152
|
-
"
|
152
|
+
"IEnvelopeField": {
|
153
153
|
"location": "import",
|
154
154
|
"path": "@verdocs/js-sdk/Envelopes/Types"
|
155
155
|
},
|
@@ -43,7 +43,7 @@ export class VerdocsFieldRadioButton {
|
|
43
43
|
if (this.done) {
|
44
44
|
return (h(Host, { class: { done: this.done }, style: { maxWidth: '10px' } }, h("span", { innerHTML: !!option.selected ? RadioIconSelected : RadioIconUnselected })));
|
45
45
|
}
|
46
|
-
return (h(Host, { class: { required, disabled }, style: { backgroundColor } }, h("input", { id: id, type: "radio", value: option.id, tabIndex: settings.order,
|
46
|
+
return (h(Host, { class: { required, disabled }, style: { backgroundColor } }, h("input", { id: id, type: "radio", name: this.field.name, value: option.id, tabIndex: settings.order, checked: !!option.selected, disabled: disabled, required: settings.required }), h("label", { htmlFor: id }), this.editable && (h("verdocs-button-panel", { icon: settingsIcon, id: `verdocs-settings-panel-${this.field.name}` }, h("verdocs-template-field-properties", { templateId: this.templateid, fieldName: this.field.name, onClose: () => this.hideSettingsPanel(), onDelete: () => {
|
47
47
|
var _a;
|
48
48
|
(_a = this.deleted) === null || _a === void 0 ? void 0 : _a.emit({ fieldName: this.field.name });
|
49
49
|
return this.hideSettingsPanel();
|
@@ -88,10 +88,10 @@ export class VerdocsFieldRadioButton {
|
|
88
88
|
"type": "unknown",
|
89
89
|
"mutable": false,
|
90
90
|
"complexType": {
|
91
|
-
"original": "
|
92
|
-
"resolved": "
|
91
|
+
"original": "IEnvelopeField | ITemplateField | null",
|
92
|
+
"resolved": "IEnvelopeField | ITemplateField",
|
93
93
|
"references": {
|
94
|
-
"
|
94
|
+
"IEnvelopeField": {
|
95
95
|
"location": "import",
|
96
96
|
"path": "@verdocs/js-sdk/Envelopes/Types"
|
97
97
|
},
|
package/dist/collection/components/fields/verdocs-field-signature/verdocs-field-signature.js
CHANGED
@@ -110,10 +110,10 @@ export class VerdocsFieldSignature {
|
|
110
110
|
"type": "unknown",
|
111
111
|
"mutable": false,
|
112
112
|
"complexType": {
|
113
|
-
"original": "
|
114
|
-
"resolved": "
|
113
|
+
"original": "IEnvelopeField | ITemplateField | null",
|
114
|
+
"resolved": "IEnvelopeField | ITemplateField",
|
115
115
|
"references": {
|
116
|
-
"
|
116
|
+
"IEnvelopeField": {
|
117
117
|
"location": "import",
|
118
118
|
"path": "@verdocs/js-sdk/Envelopes/Types"
|
119
119
|
},
|
@@ -40,7 +40,7 @@ export class VerdocsFieldTextarea {
|
|
40
40
|
if (this.done) {
|
41
41
|
return h(Host, { class: { done: this.done } }, settings.value);
|
42
42
|
}
|
43
|
-
return (h(Host, { class: { required: settings.required, disabled }, style: { backgroundColor } }, h("textarea", { placeholder: settings.placeholder || '', tabIndex: settings.order, value: settings.value, disabled: disabled, required: settings.required, ref: el => (this.el = el) }), this.editable && (h("verdocs-button-panel", { icon: settingsIcon, id: `verdocs-settings-panel-${this.field.name}` }, h("verdocs-template-field-properties", { templateId: this.templateid, fieldName: this.field.name, onClose: () => this.hideSettingsPanel(), onDelete: () => {
|
43
|
+
return (h(Host, { class: { required: settings.required, disabled }, style: { backgroundColor } }, h("textarea", { placeholder: settings.placeholder || '', tabIndex: settings.order, value: settings.value, disabled: disabled, name: this.field.name, required: settings.required, ref: el => (this.el = el) }), this.editable && (h("verdocs-button-panel", { icon: settingsIcon, id: `verdocs-settings-panel-${this.field.name}` }, h("verdocs-template-field-properties", { templateId: this.templateid, fieldName: this.field.name, onClose: () => this.hideSettingsPanel(), onDelete: () => {
|
44
44
|
var _a;
|
45
45
|
(_a = this.deleted) === null || _a === void 0 ? void 0 : _a.emit({ fieldName: this.field.name });
|
46
46
|
return this.hideSettingsPanel();
|
@@ -85,10 +85,10 @@ export class VerdocsFieldTextarea {
|
|
85
85
|
"type": "unknown",
|
86
86
|
"mutable": false,
|
87
87
|
"complexType": {
|
88
|
-
"original": "
|
89
|
-
"resolved": "
|
88
|
+
"original": "IEnvelopeField | ITemplateField | null",
|
89
|
+
"resolved": "IEnvelopeField | ITemplateField",
|
90
90
|
"references": {
|
91
|
-
"
|
91
|
+
"IEnvelopeField": {
|
92
92
|
"location": "import",
|
93
93
|
"path": "@verdocs/js-sdk/Envelopes/Types"
|
94
94
|
},
|
@@ -70,7 +70,7 @@ export class VerdocsFieldTextbox {
|
|
70
70
|
if (this.done) {
|
71
71
|
return h(Host, { class: { done: this.done } }, value);
|
72
72
|
}
|
73
|
-
return (h(Host, { class: { required: (_c = this.field) === null || _c === void 0 ? void 0 : _c.required, disabled, done: this.done }, style: { backgroundColor } }, h("input", { type: "text", placeholder: settings === null || settings === void 0 ? void 0 : settings.placeholder, tabIndex: settings === null || settings === void 0 ? void 0 : settings.order, value: value, disabled: disabled, required: (_d = this.field) === null || _d === void 0 ? void 0 : _d.required, ref: el => (this.inputEl = el) }), this.editable && (h("div", { class: "resizer", ref: el => (this.resizeHandle = el) }, h("div", { class: "resizer-inner" }))), this.editable && (h("verdocs-button-panel", { icon: settingsIcon, id: `verdocs-settings-panel-${this.field.name}` }, h("verdocs-template-field-properties", { templateId: this.templateid, fieldName: this.field.name, onClose: () => this.hideSettingsPanel(), onDelete: () => {
|
73
|
+
return (h(Host, { class: { required: (_c = this.field) === null || _c === void 0 ? void 0 : _c.required, disabled, done: this.done }, style: { backgroundColor } }, h("input", { type: "text", name: this.field.name, placeholder: settings === null || settings === void 0 ? void 0 : settings.placeholder, tabIndex: settings === null || settings === void 0 ? void 0 : settings.order, value: value, disabled: disabled, required: (_d = this.field) === null || _d === void 0 ? void 0 : _d.required, ref: el => (this.inputEl = el) }), this.editable && (h("div", { class: "resizer", ref: el => (this.resizeHandle = el) }, h("div", { class: "resizer-inner" }))), this.editable && (h("verdocs-button-panel", { icon: settingsIcon, id: `verdocs-settings-panel-${this.field.name}` }, h("verdocs-template-field-properties", { templateId: this.templateid, fieldName: this.field.name, onClose: () => this.hideSettingsPanel(), onDelete: () => {
|
74
74
|
var _a;
|
75
75
|
(_a = this.deleted) === null || _a === void 0 ? void 0 : _a.emit({ fieldName: this.field.name });
|
76
76
|
return this.hideSettingsPanel();
|
@@ -115,10 +115,10 @@ export class VerdocsFieldTextbox {
|
|
115
115
|
"type": "unknown",
|
116
116
|
"mutable": false,
|
117
117
|
"complexType": {
|
118
|
-
"original": "
|
119
|
-
"resolved": "
|
118
|
+
"original": "IEnvelopeField | ITemplateField | null",
|
119
|
+
"resolved": "IEnvelopeField | ITemplateField",
|
120
120
|
"references": {
|
121
|
-
"
|
121
|
+
"IEnvelopeField": {
|
122
122
|
"location": "import",
|
123
123
|
"path": "@verdocs/js-sdk/Envelopes/Types"
|
124
124
|
},
|
package/dist/collection/components/fields/verdocs-field-timestamp/verdocs-field-timestamp.js
CHANGED
@@ -92,10 +92,10 @@ export class VerdocsFieldTimestamp {
|
|
92
92
|
"type": "unknown",
|
93
93
|
"mutable": false,
|
94
94
|
"complexType": {
|
95
|
-
"original": "
|
96
|
-
"resolved": "
|
95
|
+
"original": "IEnvelopeField | ITemplateField | null",
|
96
|
+
"resolved": "IEnvelopeField | ITemplateField",
|
97
97
|
"references": {
|
98
|
-
"
|
98
|
+
"IEnvelopeField": {
|
99
99
|
"location": "import",
|
100
100
|
"path": "@verdocs/js-sdk/Envelopes/Types"
|
101
101
|
},
|
@@ -142,7 +142,7 @@ export class VerdocsTemplateFieldProperties {
|
|
142
142
|
});
|
143
143
|
newProperties.setting = { ...this.setting };
|
144
144
|
delete newProperties.setting.result;
|
145
|
-
newProperties.setting.options =
|
145
|
+
newProperties.setting.options = [...this.options];
|
146
146
|
updateField(this.endpoint, this.templateId, this.fieldName, newProperties)
|
147
147
|
.then(() => {
|
148
148
|
var _a, _b;
|
package/dist/collection/components/templates/verdocs-template-fields/verdocs-template-fields.css
CHANGED
@@ -43,19 +43,24 @@ verdocs-template-fields #verdocs-template-fields-toolbar {
|
|
43
43
|
display: flex;
|
44
44
|
flex: 0 0 50px;
|
45
45
|
column-gap: 15px;
|
46
|
+
font-weight: 700;
|
46
47
|
padding: 0 20px 0 0;
|
47
48
|
align-items: center;
|
48
49
|
flex-direction: row;
|
50
|
+
color: #f5f5fa;
|
49
51
|
justify-content: center;
|
50
52
|
background: #46497d;
|
51
53
|
}
|
54
|
+
verdocs-template-fields #verdocs-template-fields-toolbar > verdocs-select-input {
|
55
|
+
margin: 0;
|
56
|
+
}
|
52
57
|
verdocs-template-fields #verdocs-template-fields-toolbar svg {
|
53
58
|
width: 24px;
|
54
59
|
height: 24px;
|
55
60
|
}
|
56
61
|
verdocs-template-fields #verdocs-template-fields-toolbar .add-for {
|
57
|
-
font-weight: 500;
|
58
62
|
margin: 0;
|
63
|
+
font-weight: 500;
|
59
64
|
color: #f5f5fa;
|
60
65
|
}
|
61
66
|
verdocs-template-fields #verdocs-template-fields-toolbar verdocs-select-input {
|
package/dist/collection/components/templates/verdocs-template-fields/verdocs-template-fields.js
CHANGED
@@ -272,7 +272,12 @@ export class VerdocsTemplateFields {
|
|
272
272
|
required: true,
|
273
273
|
page_sequence: pageNumber,
|
274
274
|
validator: null,
|
275
|
-
setting: { x, y },
|
275
|
+
setting: { x, y },
|
276
|
+
x,
|
277
|
+
y,
|
278
|
+
tabindex: 0,
|
279
|
+
width,
|
280
|
+
height,
|
276
281
|
};
|
277
282
|
// TODO: Fix how the server validates all this. It uses a JSON schema and is very particular about shapes for each field type.
|
278
283
|
// That makes it harder for third party developers to create fields via API calls. It would be better to always set X/Y and
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
|
2
2
|
|
3
|
-
const verdocsCheckboxCss = "@charset \"UTF-8\";verdocs-checkbox{font-family:\"Inter\", -apple-system, \"Segoe UI\", \"Roboto\", \"Helvetica Neue\", sans-serif
|
3
|
+
const verdocsCheckboxCss = "@charset \"UTF-8\";verdocs-checkbox{line-height:18px;font-family:\"Inter\", -apple-system, \"Segoe UI\", \"Roboto\", \"Helvetica Neue\", sans-serif}verdocs-checkbox label>input[type=checkbox]{display:none}verdocs-checkbox label>input[type=checkbox]+*::before{content:\"\";width:1rem;height:1rem;-ms-flex-negative:0;flex-shrink:0;line-height:18px;border-radius:2px;border-style:solid;margin-right:0.5rem;border-width:0.1rem;display:inline-block;vertical-align:bottom;border-color:#aeb4bf}verdocs-checkbox label>input[type=checkbox]:checked+*{color:#55bc81}verdocs-checkbox label>input[type=checkbox]:checked+*::before{content:\"✓\";color:white;text-align:center;background:#55bc81;border-color:#55bc81}verdocs-checkbox.dark label>input[type=checkbox]+*::before{border-color:#ffffff}verdocs-checkbox.dark label>input[type=checkbox]:checked+*::before{background:#55bc81;border-color:#55bc81}";
|
4
4
|
|
5
5
|
const VerdocsCheckbox = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
6
6
|
constructor() {
|
@@ -10,7 +10,7 @@ import { d as defineCustomElement$4 } from './verdocs-select-input2.js';
|
|
10
10
|
import { d as defineCustomElement$3 } from './verdocs-template-field-properties2.js';
|
11
11
|
import { d as defineCustomElement$2 } from './verdocs-text-input2.js';
|
12
12
|
|
13
|
-
const verdocsFieldCheckboxCss = "@charset \"UTF-8\";verdocs-field-checkbox{font-family:\"Inter\", -apple-system, \"Segoe UI\", \"Roboto\", \"Helvetica Neue\", sans-serif
|
13
|
+
const verdocsFieldCheckboxCss = "@charset \"UTF-8\";verdocs-field-checkbox{line-height:18px;-webkit-transform-origin:bottom left;transform-origin:bottom left;font-family:\"Inter\", -apple-system, \"Segoe UI\", \"Roboto\", \"Helvetica Neue\", sans-serif}verdocs-field-checkbox.disabled{opacity:0.5}verdocs-field-checkbox label>input[type=checkbox]{display:none}verdocs-field-checkbox label>input[type=checkbox]+*::before{content:\"\";width:1rem;height:1rem;-ms-flex-negative:0;flex-shrink:0;line-height:18px;border-radius:2px;border-style:solid;margin-right:0.5rem;border-width:0.1rem;display:inline-block;vertical-align:bottom;border-color:#aeb4bf}verdocs-field-checkbox label>input[type=checkbox]:checked+*{color:#55bc81}verdocs-field-checkbox label>input[type=checkbox]:checked+*::before{content:\"✓\";color:white;text-align:center;background:#55bc81;border-color:#55bc81}verdocs-field-checkbox.required{border:1px solid #cc0000}verdocs-field-checkbox.hide{display:none}verdocs-field-checkbox.focused{-webkit-animation:verdocs-field-pulse 0.75s 2;animation:verdocs-field-pulse 0.75s 2}verdocs-field-checkbox verdocs-button-panel{margin-left:-20px;margin-top:-4px;-webkit-transform:scale(0.7);transform:scale(0.7)}";
|
14
14
|
|
15
15
|
const settingsIcon = '<svg xmlns="http://www.w3.org/2000/svg" height="20" width="20"><path d="m7.5 18.5-.312-2.667q-.188-.125-.396-.25-.209-.125-.396-.229l-2.479 1.063-2.521-4.334 2.125-1.625q.021-.104.021-.229v-.458q0-.125-.021-.229L1.396 7.917l2.521-4.313 2.5 1.042q.166-.104.375-.229.208-.125.396-.229L7.5 1.5h5l.312 2.688q.188.104.396.229.209.125.396.229l2.479-1.042 2.521 4.313-2.125 1.625v.916l2.125 1.625-2.521 4.334-2.5-1.063q-.166.104-.375.229-.208.125-.396.25L12.5 18.5Zm2.479-5.521q1.229 0 2.104-.875T12.958 10q0-1.229-.875-2.104t-2.104-.875q-1.208 0-2.094.875Q7 8.771 7 10t.885 2.104q.886.875 2.094.875Zm0-1.75q-.5 0-.864-.364Q8.75 10.5 8.75 10t.365-.865q.364-.364.864-.364t.865.364q.364.365.364.865t-.364.865q-.365.364-.865.364ZM10.021 10Zm-.792 6.521h1.542l.25-2.146q.625-.167 1.198-.51.573-.344 1.031-.823l2.021.854.771-1.271-1.771-1.354q.104-.292.156-.615.052-.323.052-.656 0-.292-.052-.604-.052-.313-.135-.646l1.77-1.375-.77-1.271-2.021.875q-.479-.5-1.042-.833-.562-.334-1.187-.5l-.271-2.167H9.208l-.25 2.167q-.625.166-1.187.5-.563.333-1.042.812l-2-.854-.771 1.271 1.73 1.354q-.084.333-.136.656Q5.5 9.708 5.5 10t.052.604q.052.313.136.667l-1.73 1.354.771 1.271 2-.834q.479.459 1.042.792.562.334 1.187.5Z"/></svg>';
|
16
16
|
const VerdocsFieldCheckbox$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
@@ -51,7 +51,7 @@ const VerdocsFieldCheckbox$1 = /*@__PURE__*/ proxyCustomElement(class extends HT
|
|
51
51
|
if (this.done) {
|
52
52
|
return h(Host, { class: { done: this.done } }, option.checked ? '✓' : '☐');
|
53
53
|
}
|
54
|
-
return (h(Host, { class: { required: settings.required, disabled }, style: { backgroundColor } }, h("label", null, h("input", { type: "checkbox", tabIndex: settings.order, checked: option.checked, disabled: disabled, required: settings.required, value: option.id }), h("span", null), this.editable && (h("verdocs-button-panel", { icon: settingsIcon, id: `verdocs-settings-panel-${this.field.name}` }, h("verdocs-template-field-properties", { templateId: this.templateid, fieldName: this.field.name, onClose: () => this.hideSettingsPanel(), onDelete: () => {
|
54
|
+
return (h(Host, { class: { required: settings.required, disabled }, style: { backgroundColor } }, h("label", null, h("input", { name: this.field.name, type: "checkbox", tabIndex: settings.order, checked: option.checked, disabled: disabled, required: settings.required, value: option.id }), h("span", null), this.editable && (h("verdocs-button-panel", { icon: settingsIcon, id: `verdocs-settings-panel-${this.field.name}` }, h("verdocs-template-field-properties", { templateId: this.templateid, fieldName: this.field.name, onClose: () => this.hideSettingsPanel(), onDelete: () => {
|
55
55
|
var _a;
|
56
56
|
(_a = this.deleted) === null || _a === void 0 ? void 0 : _a.emit({ fieldName: this.field.name });
|
57
57
|
return this.hideSettingsPanel();
|
@@ -2623,7 +2623,7 @@ const VerdocsFieldDate$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLEl
|
|
2623
2623
|
const formatted = (settings === null || settings === void 0 ? void 0 : settings.result) ? format(new Date(settings === null || settings === void 0 ? void 0 : settings.result), 'PP') : '';
|
2624
2624
|
return h(Host, { class: { done: this.done } }, formatted);
|
2625
2625
|
}
|
2626
|
-
return (h(Host, { class: { required: (_c = this.field) === null || _c === void 0 ? void 0 : _c.required, disabled }, style: { backgroundColor } }, h("input", { type: "text", value: "", id: this.containerId, disabled: disabled, placeholder: settings.placeholder, ref: el => (this.el = el) }), this.editable && (h("verdocs-button-panel", { icon: settingsIcon, id: `verdocs-settings-panel-${this.field.name}` }, h("verdocs-template-field-properties", { templateId: this.templateId, fieldName: this.field.name, onClose: () => this.hideSettingsPanel(), onDelete: () => {
|
2626
|
+
return (h(Host, { class: { required: (_c = this.field) === null || _c === void 0 ? void 0 : _c.required, disabled }, style: { backgroundColor } }, h("input", { name: this.field.name, type: "text", value: "", id: this.containerId, disabled: disabled, placeholder: settings.placeholder, ref: el => (this.el = el) }), this.editable && (h("verdocs-button-panel", { icon: settingsIcon, id: `verdocs-settings-panel-${this.field.name}` }, h("verdocs-template-field-properties", { templateId: this.templateId, fieldName: this.field.name, onClose: () => this.hideSettingsPanel(), onDelete: () => {
|
2627
2627
|
var _a;
|
2628
2628
|
(_a = this.deleted) === null || _a === void 0 ? void 0 : _a.emit({ fieldName: this.field.name });
|
2629
2629
|
return this.hideSettingsPanel();
|
@@ -55,7 +55,7 @@ const VerdocsFieldRadioButton$1 = /*@__PURE__*/ proxyCustomElement(class extends
|
|
55
55
|
if (this.done) {
|
56
56
|
return (h(Host, { class: { done: this.done }, style: { maxWidth: '10px' } }, h("span", { innerHTML: !!option.selected ? RadioIconSelected : RadioIconUnselected })));
|
57
57
|
}
|
58
|
-
return (h(Host, { class: { required, disabled }, style: { backgroundColor } }, h("input", { id: id, type: "radio", value: option.id, tabIndex: settings.order,
|
58
|
+
return (h(Host, { class: { required, disabled }, style: { backgroundColor } }, h("input", { id: id, type: "radio", name: this.field.name, value: option.id, tabIndex: settings.order, checked: !!option.selected, disabled: disabled, required: settings.required }), h("label", { htmlFor: id }), this.editable && (h("verdocs-button-panel", { icon: settingsIcon, id: `verdocs-settings-panel-${this.field.name}` }, h("verdocs-template-field-properties", { templateId: this.templateid, fieldName: this.field.name, onClose: () => this.hideSettingsPanel(), onDelete: () => {
|
59
59
|
var _a;
|
60
60
|
(_a = this.deleted) === null || _a === void 0 ? void 0 : _a.emit({ fieldName: this.field.name });
|
61
61
|
return this.hideSettingsPanel();
|
@@ -52,7 +52,7 @@ const VerdocsFieldTextarea$1 = /*@__PURE__*/ proxyCustomElement(class extends HT
|
|
52
52
|
if (this.done) {
|
53
53
|
return h(Host, { class: { done: this.done } }, settings.value);
|
54
54
|
}
|
55
|
-
return (h(Host, { class: { required: settings.required, disabled }, style: { backgroundColor } }, h("textarea", { placeholder: settings.placeholder || '', tabIndex: settings.order, value: settings.value, disabled: disabled, required: settings.required, ref: el => (this.el = el) }), this.editable && (h("verdocs-button-panel", { icon: settingsIcon, id: `verdocs-settings-panel-${this.field.name}` }, h("verdocs-template-field-properties", { templateId: this.templateid, fieldName: this.field.name, onClose: () => this.hideSettingsPanel(), onDelete: () => {
|
55
|
+
return (h(Host, { class: { required: settings.required, disabled }, style: { backgroundColor } }, h("textarea", { placeholder: settings.placeholder || '', tabIndex: settings.order, value: settings.value, disabled: disabled, name: this.field.name, required: settings.required, ref: el => (this.el = el) }), this.editable && (h("verdocs-button-panel", { icon: settingsIcon, id: `verdocs-settings-panel-${this.field.name}` }, h("verdocs-template-field-properties", { templateId: this.templateid, fieldName: this.field.name, onClose: () => this.hideSettingsPanel(), onDelete: () => {
|
56
56
|
var _a;
|
57
57
|
(_a = this.deleted) === null || _a === void 0 ? void 0 : _a.emit({ fieldName: this.field.name });
|
58
58
|
return this.hideSettingsPanel();
|
@@ -82,7 +82,7 @@ const VerdocsFieldTextbox$1 = /*@__PURE__*/ proxyCustomElement(class extends HTM
|
|
82
82
|
if (this.done) {
|
83
83
|
return h(Host, { class: { done: this.done } }, value);
|
84
84
|
}
|
85
|
-
return (h(Host, { class: { required: (_c = this.field) === null || _c === void 0 ? void 0 : _c.required, disabled, done: this.done }, style: { backgroundColor } }, h("input", { type: "text", placeholder: settings === null || settings === void 0 ? void 0 : settings.placeholder, tabIndex: settings === null || settings === void 0 ? void 0 : settings.order, value: value, disabled: disabled, required: (_d = this.field) === null || _d === void 0 ? void 0 : _d.required, ref: el => (this.inputEl = el) }), this.editable && (h("div", { class: "resizer", ref: el => (this.resizeHandle = el) }, h("div", { class: "resizer-inner" }))), this.editable && (h("verdocs-button-panel", { icon: settingsIcon, id: `verdocs-settings-panel-${this.field.name}` }, h("verdocs-template-field-properties", { templateId: this.templateid, fieldName: this.field.name, onClose: () => this.hideSettingsPanel(), onDelete: () => {
|
85
|
+
return (h(Host, { class: { required: (_c = this.field) === null || _c === void 0 ? void 0 : _c.required, disabled, done: this.done }, style: { backgroundColor } }, h("input", { type: "text", name: this.field.name, placeholder: settings === null || settings === void 0 ? void 0 : settings.placeholder, tabIndex: settings === null || settings === void 0 ? void 0 : settings.order, value: value, disabled: disabled, required: (_d = this.field) === null || _d === void 0 ? void 0 : _d.required, ref: el => (this.inputEl = el) }), this.editable && (h("div", { class: "resizer", ref: el => (this.resizeHandle = el) }, h("div", { class: "resizer-inner" }))), this.editable && (h("verdocs-button-panel", { icon: settingsIcon, id: `verdocs-settings-panel-${this.field.name}` }, h("verdocs-template-field-properties", { templateId: this.templateid, fieldName: this.field.name, onClose: () => this.hideSettingsPanel(), onDelete: () => {
|
86
86
|
var _a;
|
87
87
|
(_a = this.deleted) === null || _a === void 0 ? void 0 : _a.emit({ fieldName: this.field.name });
|
88
88
|
return this.hideSettingsPanel();
|
@@ -438,7 +438,15 @@ const VerdocsSign$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement
|
|
438
438
|
var _a;
|
439
439
|
el.addEventListener('input', (e) => {
|
440
440
|
console.log('[SIGN] onfieldInput', e.detail, e.target.value);
|
441
|
-
|
441
|
+
// These field types don't emit fieldChange. Should we standardize on that? We don't tap "input" for fields like
|
442
|
+
// text boxes because we'd be updating the field on every keystroke. We do those on blur which fires fieldChange.
|
443
|
+
if (e.target.name.includes('checkbox_group') || e.target.name.includes('radio_button_group')) {
|
444
|
+
console.log('CB', e.target);
|
445
|
+
this.handleFieldChange(field, e).finally(() => this.checkRecipientFields());
|
446
|
+
}
|
447
|
+
else {
|
448
|
+
this.checkRecipientFields();
|
449
|
+
}
|
442
450
|
});
|
443
451
|
el.addEventListener('focusout', e => this.handleFieldChange(field, e).finally(() => this.checkRecipientFields()));
|
444
452
|
el.addEventListener('fieldChange', e => this.handleFieldChange(field, e).finally(() => this.checkRecipientFields()));
|
@@ -343,7 +343,7 @@ const VerdocsTemplateFieldProperties = /*@__PURE__*/ proxyCustomElement(class ex
|
|
343
343
|
});
|
344
344
|
newProperties.setting = { ...this.setting };
|
345
345
|
delete newProperties.setting.result;
|
346
|
-
newProperties.setting.options =
|
346
|
+
newProperties.setting.options = [...this.options];
|
347
347
|
updateField(this.endpoint, this.templateId, this.fieldName, newProperties)
|
348
348
|
.then(() => {
|
349
349
|
var _a, _b;
|
@@ -12,7 +12,7 @@ import { d as defineCustomElement$3 } from './verdocs-select-input2.js';
|
|
12
12
|
import { d as defineCustomElement$2 } from './verdocs-template-document-page2.js';
|
13
13
|
import { d as defineCustomElement$1 } from './verdocs-toolbar-icon2.js';
|
14
14
|
|
15
|
-
const verdocsTemplateFieldsCss = "verdocs-template-fields{font-family:\"Inter\", -apple-system, \"Segoe UI\", \"Roboto\", \"Helvetica Neue\", sans-serif;position:relative;display:block;min-height:600px}verdocs-template-fields .page-0{padding:65px 15px 0 15px;-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-template-fields .page-0 .user-placed-fields{height:100px;position:relative;background:#ffffff;-webkit-box-shadow:0 0 10px 5px #0000000f;box-shadow:0 0 10px 5px #0000000f}verdocs-template-fields .page-0 .user-placed-fields .title{top:0;left:0;color:#ffffff;font-size:12px;padding:3px 6px;font-weight:bold;position:absolute;background:#46497d}verdocs-template-fields .pages{display:-ms-flexbox;display:flex;padding:15px;row-gap:15px;min-height:200px;position:relative;-ms-flex-align:center;align-items:center;-webkit-box-sizing:border-box;box-sizing:border-box;-ms-flex-direction:column;flex-direction:column}verdocs-template-fields .pages div,verdocs-template-fields .pages canvas{-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-template-fields #verdocs-template-fields-toolbar{height:50px;display:-ms-flexbox;display:flex;-ms-flex:0 0 50px;flex:0 0 50px;-webkit-column-gap:15px;-moz-column-gap:15px;column-gap:15px;padding:0 20px 0 0;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center;background:#46497d}verdocs-template-fields #verdocs-template-fields-toolbar svg{width:24px;height:24px}verdocs-template-fields #verdocs-template-fields-toolbar .add-for{font-weight:500;
|
15
|
+
const verdocsTemplateFieldsCss = "verdocs-template-fields{font-family:\"Inter\", -apple-system, \"Segoe UI\", \"Roboto\", \"Helvetica Neue\", sans-serif;position:relative;display:block;min-height:600px}verdocs-template-fields .page-0{padding:65px 15px 0 15px;-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-template-fields .page-0 .user-placed-fields{height:100px;position:relative;background:#ffffff;-webkit-box-shadow:0 0 10px 5px #0000000f;box-shadow:0 0 10px 5px #0000000f}verdocs-template-fields .page-0 .user-placed-fields .title{top:0;left:0;color:#ffffff;font-size:12px;padding:3px 6px;font-weight:bold;position:absolute;background:#46497d}verdocs-template-fields .pages{display:-ms-flexbox;display:flex;padding:15px;row-gap:15px;min-height:200px;position:relative;-ms-flex-align:center;align-items:center;-webkit-box-sizing:border-box;box-sizing:border-box;-ms-flex-direction:column;flex-direction:column}verdocs-template-fields .pages div,verdocs-template-fields .pages canvas{-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-template-fields #verdocs-template-fields-toolbar{height:50px;display:-ms-flexbox;display:flex;-ms-flex:0 0 50px;flex:0 0 50px;-webkit-column-gap:15px;-moz-column-gap:15px;column-gap:15px;font-weight:700;padding:0 20px 0 0;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;color:#f5f5fa;-ms-flex-pack:center;justify-content:center;background:#46497d}verdocs-template-fields #verdocs-template-fields-toolbar>verdocs-select-input{margin:0}verdocs-template-fields #verdocs-template-fields-toolbar svg{width:24px;height:24px}verdocs-template-fields #verdocs-template-fields-toolbar .add-for{margin:0;font-weight:500;color:#f5f5fa}verdocs-template-fields #verdocs-template-fields-toolbar verdocs-select-input{margin:0 20px 0 0}verdocs-template-fields.placing-attachment{cursor:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='24' width='24'%3E%3Cpath d='m10.55 16.55 7.275-7.275L16.05 7.5l-5.5 5.45-2.675-2.65L6.1 12.075Zm-5.375 4.925q-1.125 0-1.887-.763-.763-.762-.763-1.887V5.175q0-1.125.763-1.888.762-.762 1.887-.762h13.65q1.125 0 1.888.762.762.763.762 1.888v13.65q0 1.125-.762 1.887-.763.763-1.888.763Zm0-2.65h13.65V5.175H5.175v13.65Zm0-13.65v13.65-13.65Z'/%3E%3C/svg%3E\") 16 16, pointer}verdocs-template-fields.placing-checkbox_group{cursor:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='24' width='24'%3E%3Cpath d='m10.55 16.55 7.275-7.275L16.05 7.5l-5.5 5.45-2.675-2.65L6.1 12.075Zm-5.375 4.925q-1.125 0-1.887-.763-.763-.762-.763-1.887V5.175q0-1.125.763-1.888.762-.762 1.887-.762h13.65q1.125 0 1.888.762.762.763.762 1.888v13.65q0 1.125-.762 1.887-.763.763-1.888.763Zm0-2.65h13.65V5.175H5.175v13.65Zm0-13.65v13.65-13.65Z'/%3E%3C/svg%3E\") 16 16, pointer}verdocs-template-fields.placing-date{cursor:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='24' width='24'%3E%3Cpath fill='%23000000' d='M7.6 13.925q-.55 0-.925-.375t-.375-.925q0-.55.375-.937.375-.388.925-.388t.925.388q.375.387.375.937t-.375.925q-.375.375-.925.375Zm4.4 0q-.55 0-.925-.375t-.375-.925q0-.55.375-.937.375-.388.925-.388t.925.388q.375.387.375.937t-.375.925q-.375.375-.925.375Zm4.4 0q-.55 0-.925-.375t-.375-.925q0-.55.375-.937.375-.388.925-.388t.925.388q.375.387.375.937t-.375.925q-.375.375-.925.375ZM5.3 22.85q-1.325 0-2.238-.912-.912-.913-.912-2.238V6.3q0-1.325.912-2.238.913-.912 2.238-.912H6v-2h2.575v2h6.85v-2H18v2h.7q1.325 0 2.238.912.912.913.912 2.238v13.4q0 1.325-.912 2.238-.913.912-2.238.912Zm0-3.15h13.4V10H5.3v9.7ZM5.3 8h13.4V6.3H5.3Zm0 0V6.3 8Z'/%3E%3C/svg%3E\") 16 16, pointer}verdocs-template-fields.placing-dropdown{cursor:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='24' width='24' stroke-width='1.5' stroke='currentColor'%3E%3Cpath stroke='%23000000' stroke-linecap='round' stroke-linejoin='round' d='M3 4.5h14.25M3 9h9.75M3 13.5h9.75m4.5-4.5v12m0 0l-3.75-3.75M17.25 21L21 17.25' /%3E%3C/svg%3E\") 16 16, pointer}verdocs-template-fields.placing-initial{cursor:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='24' width='24'%3E%3Cpath d='M6.225 20.775V7h-5V3.225H15V7h-5v13.775Zm9.775 0v-8h-3V9h9.775v3.775h-3v8Z'/%3E%3C/svg%3E\") 16 16, pointer}verdocs-template-fields.placing-payment{cursor:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='24' width='24'%3E%3Cpath d='m10.55 16.55 7.275-7.275L16.05 7.5l-5.5 5.45-2.675-2.65L6.1 12.075Zm-5.375 4.925q-1.125 0-1.887-.763-.763-.762-.763-1.887V5.175q0-1.125.763-1.888.762-.762 1.887-.762h13.65q1.125 0 1.888.762.762.763.762 1.888v13.65q0 1.125-.762 1.887-.763.763-1.888.763Zm0-2.65h13.65V5.175H5.175v13.65Zm0-13.65v13.65-13.65Z'/%3E%3C/svg%3E\") 16 16, pointer}verdocs-template-fields.placing-radio_button_group{cursor:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='24' width='24'%3E%3Cpath d='M12 17q2.075 0 3.538-1.463Q17 14.075 17 12t-1.462-3.538Q14.075 7 12 7 9.925 7 8.463 8.462 7 9.925 7 12q0 2.075 1.463 3.537Q9.925 17 12 17Zm0 5.85q-2.275 0-4.25-.85t-3.438-2.312Q2.85 18.225 2 16.25q-.85-1.975-.85-4.25T2 7.75q.85-1.975 2.312-3.438Q5.775 2.85 7.75 2q1.975-.85 4.25-.85t4.25.85q1.975.85 3.438 2.312Q21.15 5.775 22 7.75q.85 1.975.85 4.25T22 16.25q-.85 1.975-2.312 3.438Q18.225 21.15 16.25 22q-1.975.85-4.25.85Zm0-3.15q3.25 0 5.475-2.225Q19.7 15.25 19.7 12q0-3.25-2.225-5.475Q15.25 4.3 12 4.3q-3.25 0-5.475 2.225Q4.3 8.75 4.3 12q0 3.25 2.225 5.475Q8.75 19.7 12 19.7Zm0-7.7Z'/%3E%3C/svg%3E\") 16 16, pointer}verdocs-template-fields.placing-signature{cursor:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='24' width='24'%3E%3Cpath d='m9.225 21.225 4.65-4.65h8.45v4.65Zm-5.35-2.2H5.05l8.5-8.5-1.175-1.175-8.5 8.5Zm14.25-9.95L13.8 4.8l1.325-1.325q.625-.65 1.525-.663.9-.012 1.6.663l1.225 1.175q.675.675.663 1.562-.013.888-.663 1.513ZM16.7 10.55 6 21.225H1.675V16.9L12.35 6.225Zm-3.725-.625-.6-.575 1.175 1.175Z'/%3E%3C/svg%3E\") 16 16, pointer}verdocs-template-fields.placing-textarea{cursor:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='24' width='24'%3E%3Cpath d='M3.225 20.725v-3.15h11.55v3.15Zm0-4.775V12.8h17.55v3.15Zm0-4.75V8.05h17.55v3.15Zm0-4.775v-3.15h17.55v3.15Z'/%3E%3C/svg%3E\") 16 16, pointer}verdocs-template-fields.placing-textbox{cursor:url(\"data:image/svg+xml,%3Csvg width='32' height='15' viewBox='0 0 32 15' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cmask id='path-1-inside-1_1401_24' fill='white'%3E%3Cpath d='M0 0H32V15H0V0Z'/%3E%3C/mask%3E%3Cpath d='M0 0H32V15H0V0Z' fill='%234C56CB' fill-opacity='0.1'/%3E%3Cpath d='M0 0V-1H-1V0H0ZM0 15H-1V16H0V15ZM0 1H32V-1H0V1ZM32 14H0V16H32V14ZM1 15V0H-1V15H1Z' fill='%234C56CB' mask='url(%23path-1-inside-1_1401_24)'/%3E%3Cpath d='M3 11.8V8.65H14.15V11.8H3ZM3 6.65V3.5H20.15V6.65H3Z' fill='%234C56CB'/%3E%3Cline x1='31.5' y1='1' x2='31.5' y2='14' stroke='%234C56CB' stroke-opacity='0.32' stroke-dasharray='1 1'/%3E%3C/svg%3E%0A\") 0 14, pointer}verdocs-template-fields.placing-timestamp{cursor:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='24' width='24'%3E%3Cpath fill='%23000000' d='M9 1h6v2H9zm10.03 6.39 1.42-1.42c-.43-.51-.9-.99-1.41-1.41l-1.42 1.42C16.07 4.74 14.12 4 12 4c-4.97 0-9 4.03-9 9s4.02 9 9 9 9-4.03 9-9c0-2.12-.74-4.07-1.97-5.61zM13 14h-2V8h2v6z'%3E%3C/path%3E%3C/svg%3E\") 16 16, pointer}";
|
16
16
|
|
17
17
|
const iconTextbox = '<svg xmlns="http://www.w3.org/2000/svg" height="24" width="24"><path fill="#ffffff" d="M3.425 16.15V13h11.15v3.15Zm0-5.15V7.85h17.15V11Z"/></svg>';
|
18
18
|
const iconTextarea = '<svg xmlns="http://www.w3.org/2000/svg" height="24" width="24"><path fill="#ffffff" d="M3.225 20.725v-3.15h11.55v3.15Zm0-4.775V12.8h17.55v3.15Zm0-4.75V8.05h17.55v3.15Zm0-4.775v-3.15h17.55v3.15Z"/></svg>';
|
@@ -281,7 +281,12 @@ const VerdocsTemplateFields = /*@__PURE__*/ proxyCustomElement(class extends HTM
|
|
281
281
|
required: true,
|
282
282
|
page_sequence: pageNumber,
|
283
283
|
validator: null,
|
284
|
-
setting: { x, y },
|
284
|
+
setting: { x, y },
|
285
|
+
x,
|
286
|
+
y,
|
287
|
+
tabindex: 0,
|
288
|
+
width,
|
289
|
+
height,
|
285
290
|
};
|
286
291
|
// TODO: Fix how the server validates all this. It uses a JSON schema and is very particular about shapes for each field type.
|
287
292
|
// That makes it harder for third party developers to create fields via API calls. It would be better to always set X/Y and
|
@@ -4,9 +4,10 @@ import { E as EnvelopeStates } from './Types.js';
|
|
4
4
|
import { V as VerdocsEndpoint } from './VerdocsEndpoint.js';
|
5
5
|
import { f as saveEnvelopesAsZip, h as saveCertificate, s as saveAttachment } from './utils.js';
|
6
6
|
import { S as SDKError } from './errors.js';
|
7
|
-
import { d as defineCustomElement$
|
8
|
-
import { d as defineCustomElement$
|
9
|
-
import { d as defineCustomElement$
|
7
|
+
import { d as defineCustomElement$5 } from './verdocs-button2.js';
|
8
|
+
import { d as defineCustomElement$4 } from './verdocs-dropdown2.js';
|
9
|
+
import { d as defineCustomElement$3 } from './verdocs-envelope-document-page2.js';
|
10
|
+
import { d as defineCustomElement$2 } from './verdocs-loader2.js';
|
10
11
|
import { d as defineCustomElement$1 } from './verdocs-ok-dialog2.js';
|
11
12
|
|
12
13
|
/**
|
@@ -47,7 +48,7 @@ var fullNameToInitials = function (name) {
|
|
47
48
|
.join('');
|
48
49
|
};
|
49
50
|
|
50
|
-
const verdocsViewCss = "verdocs-view{display:-ms-flexbox;display:flex;overflow:hidden;min-height:600px;position:relative;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column;-webkit-box-sizing:border-box;box-sizing:border-box;font-family:\"Inter\", -apple-system, \"Segoe UI\", \"Roboto\", \"Helvetica Neue\", sans-serif}verdocs-view div,verdocs-view canvas{-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-view .document{-ms-flex:1;flex:1;width:100%;height:100%;display:-ms-flexbox;display:flex;padding:15px;row-gap:15px;min-height:200px;max-width:1200px;position:relative;overflow-y:scroll;-ms-flex-align:center;align-items:center;-webkit-box-sizing:border-box;box-sizing:border-box;-ms-flex-direction:column;flex-direction:column}verdocs-view .document .inner{width:100%;max-width:1028px}#verdocs-view-header{width:100%;color:#fff;display:-ms-flexbox;display:flex;z-index:1000;-ms-flex:0 0 56px;flex:0 0 56px;padding:0 20px;font-size:12px;-webkit-column-gap:15px;-moz-column-gap:15px;column-gap:15px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;-webkit-transition:all 0.25s;transition:all 0.25s;background-color:#33354c;-webkit-box-shadow:0 4px 4px 0 rgba(0, 0, 0, 0.24), 0 0 4px 0 rgba(0, 0, 0, 0.12);box-shadow:0 4px 4px 0 rgba(0, 0, 0, 0.24), 0 0 4px 0 rgba(0, 0, 0, 0.12)}#verdocs-view-header .inner{width:100%;display:-ms-flexbox;display:flex;margin:0 auto;padding:0 20px;max-width:1200px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}#verdocs-view-header .logo{width:80px;display:none;margin:-6px 0 0 0}#verdocs-view-header .title{font-size:18px;font-weight:500;white-space:nowrap;text-overflow:ellipsis}";
|
51
|
+
const verdocsViewCss = "verdocs-view{display:-ms-flexbox;display:flex;overflow:hidden;min-height:600px;position:relative;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column;-webkit-box-sizing:border-box;box-sizing:border-box;font-family:\"Inter\", -apple-system, \"Segoe UI\", \"Roboto\", \"Helvetica Neue\", sans-serif}verdocs-view div,verdocs-view canvas{-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-view .document{-ms-flex:1;flex:1;width:100%;height:100%;display:-ms-flexbox;display:flex;padding:15px;row-gap:15px;min-height:200px;max-width:1200px;position:relative;overflow-y:scroll;-ms-flex-align:center;align-items:center;-webkit-box-sizing:border-box;box-sizing:border-box;-ms-flex-direction:column;flex-direction:column}verdocs-view .document .inner{width:100%;max-width:1028px}verdocs-view .loading-indicator{top:0;left:0;right:0;bottom:0;display:-ms-flexbox;display:flex;z-index:10000;position:fixed;background-color:rgba(0, 0, 0, 0.7)}#verdocs-view-header{width:100%;color:#fff;display:-ms-flexbox;display:flex;z-index:1000;-ms-flex:0 0 56px;flex:0 0 56px;padding:0 20px;font-size:12px;-webkit-column-gap:15px;-moz-column-gap:15px;column-gap:15px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;-webkit-transition:all 0.25s;transition:all 0.25s;background-color:#33354c;-webkit-box-shadow:0 4px 4px 0 rgba(0, 0, 0, 0.24), 0 0 4px 0 rgba(0, 0, 0, 0.12);box-shadow:0 4px 4px 0 rgba(0, 0, 0, 0.24), 0 0 4px 0 rgba(0, 0, 0, 0.12)}#verdocs-view-header .inner{width:100%;display:-ms-flexbox;display:flex;margin:0 auto;padding:0 20px;max-width:1200px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}#verdocs-view-header .logo{width:80px;display:none;margin:-6px 0 0 0}#verdocs-view-header .title{font-size:18px;font-weight:500;white-space:nowrap;text-overflow:ellipsis}";
|
51
52
|
|
52
53
|
const VerdocsView = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
53
54
|
constructor() {
|
@@ -58,7 +59,7 @@ const VerdocsView = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
|
58
59
|
this.endpoint = VerdocsEndpoint.getDefault();
|
59
60
|
this.envelopeId = '';
|
60
61
|
this.headerTargetId = null;
|
61
|
-
this.
|
62
|
+
this.canceling = false;
|
62
63
|
this.envelope = null;
|
63
64
|
this.roleNames = [];
|
64
65
|
this.showCancelDone = false;
|
@@ -106,7 +107,23 @@ const VerdocsView = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
|
106
107
|
case 'cancel':
|
107
108
|
// TODO: Better option for inline-flow confirmation and alert dialogs.
|
108
109
|
if (confirm('Are you sure you wish to cancel this envelope? This action cannot be undone.')) {
|
109
|
-
|
110
|
+
this.canceling = true;
|
111
|
+
cancelEnvelope(this.endpoint, this.envelopeId)
|
112
|
+
.then(r => {
|
113
|
+
this.canceling = false;
|
114
|
+
console.log('[VIEW] Envelope canceled', r);
|
115
|
+
return throttledGetEnvelope(this.endpoint, this.envelopeId);
|
116
|
+
})
|
117
|
+
.then(env => {
|
118
|
+
console.log('[VIEW] Loaded new envelope details', env);
|
119
|
+
this.envelope = env;
|
120
|
+
})
|
121
|
+
.catch(e => {
|
122
|
+
var _a, _b, _c;
|
123
|
+
this.canceling = false;
|
124
|
+
console.log('[VIEW] Error canceling envelope', e);
|
125
|
+
(_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));
|
126
|
+
});
|
110
127
|
this.showCancelDone = true;
|
111
128
|
(_a = this.envelopeUpdated) === null || _a === void 0 ? void 0 : _a.emit({ endpoint: this.endpoint, envelope: this.envelope, event: 'canceled' });
|
112
129
|
}
|
@@ -181,7 +198,7 @@ const VerdocsView = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
|
181
198
|
] })))));
|
182
199
|
})), this.showCancelDone && (h("verdocs-ok-dialog", { heading: "Cancelled", message: `This envelope has been cancelled successfully.`, onNext: () => {
|
183
200
|
this.showCancelDone = false;
|
184
|
-
} }))));
|
201
|
+
} })), this.canceling && (h("div", { class: "loading-indicator" }, h("verdocs-loader", null)))));
|
185
202
|
}
|
186
203
|
get component() { return this; }
|
187
204
|
static get style() { return verdocsViewCss; }
|
@@ -189,7 +206,7 @@ const VerdocsView = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
|
189
206
|
"endpoint": [16],
|
190
207
|
"envelopeId": [1, "envelope-id"],
|
191
208
|
"headerTargetId": [1, "header-target-id"],
|
192
|
-
"
|
209
|
+
"canceling": [32],
|
193
210
|
"envelope": [32],
|
194
211
|
"roleNames": [32],
|
195
212
|
"showCancelDone": [32]
|
@@ -198,7 +215,7 @@ function defineCustomElement() {
|
|
198
215
|
if (typeof customElements === "undefined") {
|
199
216
|
return;
|
200
217
|
}
|
201
|
-
const components = ["verdocs-view", "verdocs-button", "verdocs-dropdown", "verdocs-envelope-document-page", "verdocs-ok-dialog"];
|
218
|
+
const components = ["verdocs-view", "verdocs-button", "verdocs-dropdown", "verdocs-envelope-document-page", "verdocs-loader", "verdocs-ok-dialog"];
|
202
219
|
components.forEach(tagName => { switch (tagName) {
|
203
220
|
case "verdocs-view":
|
204
221
|
if (!customElements.get(tagName)) {
|
@@ -207,15 +224,20 @@ function defineCustomElement() {
|
|
207
224
|
break;
|
208
225
|
case "verdocs-button":
|
209
226
|
if (!customElements.get(tagName)) {
|
210
|
-
defineCustomElement$
|
227
|
+
defineCustomElement$5();
|
211
228
|
}
|
212
229
|
break;
|
213
230
|
case "verdocs-dropdown":
|
214
231
|
if (!customElements.get(tagName)) {
|
215
|
-
defineCustomElement$
|
232
|
+
defineCustomElement$4();
|
216
233
|
}
|
217
234
|
break;
|
218
235
|
case "verdocs-envelope-document-page":
|
236
|
+
if (!customElements.get(tagName)) {
|
237
|
+
defineCustomElement$3();
|
238
|
+
}
|
239
|
+
break;
|
240
|
+
case "verdocs-loader":
|
219
241
|
if (!customElements.get(tagName)) {
|
220
242
|
defineCustomElement$2();
|
221
243
|
}
|