@verdocs/web-sdk 2.3.20 → 2.3.22

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.
Files changed (45) hide show
  1. package/dist/cjs/verdocs-build.cjs.entry.js +1 -1
  2. package/dist/cjs/verdocs-field-textbox.cjs.entry.js +1 -3
  3. package/dist/cjs/verdocs-preview_8.cjs.entry.js +9 -9
  4. package/dist/cjs/verdocs-template-fields_4.cjs.entry.js +5 -5
  5. package/dist/collection/components/embeds/verdocs-build/verdocs-build.js +1 -1
  6. package/dist/collection/components/embeds/verdocs-preview/verdocs-preview.js +1 -1
  7. package/dist/collection/components/embeds/verdocs-send/verdocs-send.js +1 -1
  8. package/dist/collection/components/fields/verdocs-field-textbox/verdocs-field-textbox.js +1 -3
  9. package/dist/collection/components/templates/verdocs-template-attachments/verdocs-template-attachments.js +2 -2
  10. package/dist/collection/components/templates/verdocs-template-fields/verdocs-template-fields.js +1 -1
  11. package/dist/collection/components/templates/verdocs-template-reminders/verdocs-template-reminders.js +5 -5
  12. package/dist/collection/components/templates/verdocs-template-role-properties/verdocs-template-role-properties.js +1 -1
  13. package/dist/collection/components/templates/verdocs-template-roles/verdocs-template-roles.js +3 -3
  14. package/dist/components/verdocs-build.js +1 -1
  15. package/dist/components/verdocs-field-textbox.js +1 -3
  16. package/dist/components/verdocs-preview2.js +1 -1
  17. package/dist/components/verdocs-send2.js +1 -1
  18. package/dist/components/verdocs-template-attachments2.js +2 -2
  19. package/dist/components/verdocs-template-fields2.js +1 -1
  20. package/dist/components/verdocs-template-reminders2.js +5 -5
  21. package/dist/components/verdocs-template-role-properties2.js +1 -1
  22. package/dist/components/verdocs-template-roles2.js +3 -3
  23. package/dist/docs.json +1 -1
  24. package/dist/esm/verdocs-build.entry.js +1 -1
  25. package/dist/esm/verdocs-field-textbox.entry.js +1 -3
  26. package/dist/esm/verdocs-preview_8.entry.js +9 -9
  27. package/dist/esm/verdocs-template-fields_4.entry.js +5 -5
  28. package/dist/esm-es5/verdocs-build.entry.js +1 -1
  29. package/dist/esm-es5/verdocs-field-textbox.entry.js +1 -1
  30. package/dist/esm-es5/verdocs-preview_8.entry.js +1 -1
  31. package/dist/esm-es5/verdocs-template-fields_4.entry.js +1 -1
  32. package/dist/verdocs-web-sdk/{p-f8093452.entry.js → p-1780a4f1.entry.js} +1 -1
  33. package/dist/verdocs-web-sdk/{p-83bedd31.entry.js → p-66d58683.entry.js} +1 -1
  34. package/dist/verdocs-web-sdk/{p-92e5e32d.system.entry.js → p-710d6928.system.entry.js} +1 -1
  35. package/dist/verdocs-web-sdk/{p-558f9f80.system.entry.js → p-79fcaf1e.system.entry.js} +1 -1
  36. package/dist/verdocs-web-sdk/p-88c64957.system.entry.js +1 -0
  37. package/dist/verdocs-web-sdk/p-cc9a62c3.entry.js +1 -0
  38. package/dist/verdocs-web-sdk/{p-9ac6d5eb.entry.js → p-d1837af9.entry.js} +1 -1
  39. package/dist/verdocs-web-sdk/p-d5e27c32.system.entry.js +1 -0
  40. package/dist/verdocs-web-sdk/p-f04bf956.system.js +1 -1
  41. package/dist/verdocs-web-sdk/verdocs-web-sdk.esm.js +1 -1
  42. package/package.json +2 -2
  43. package/dist/verdocs-web-sdk/p-6925f18d.system.entry.js +0 -1
  44. package/dist/verdocs-web-sdk/p-b409f610.system.entry.js +0 -1
  45. package/dist/verdocs-web-sdk/p-ff46c394.entry.js +0 -1
@@ -56,7 +56,7 @@ const VerdocsBuild = class {
56
56
  async loadTemplate(templateId) {
57
57
  if (templateId) {
58
58
  console.log('Loading store', templateId);
59
- this.store = await TemplateStore.getTemplateStore(this.endpoint, templateId, true);
59
+ this.store = await TemplateStore.getTemplateStore(this.endpoint, templateId, false);
60
60
  index.forceUpdate(this.el);
61
61
  }
62
62
  }
@@ -56,7 +56,6 @@ const VerdocsFieldTextbox = class {
56
56
  }
57
57
  async componentWillLoad() {
58
58
  this.fieldStore = TemplateFieldStore.getTemplateFieldStore(this.templateid);
59
- console.log('fs', this.templateid);
60
59
  }
61
60
  componentDidRender() {
62
61
  interact_min.interact_min.dynamicDrop(true);
@@ -99,7 +98,7 @@ const VerdocsFieldTextbox = class {
99
98
  Fields.updateField(this.endpoint, this.templateid, this.fieldname, { setting: newSettings })
100
99
  .then(field => {
101
100
  var _a;
102
- console.log('update result', field);
101
+ console.log('Update result', field);
103
102
  (_a = this.settingsChanged) === null || _a === void 0 ? void 0 : _a.emit({ fieldName: field.name, settings: newSettings, field });
104
103
  Object.assign(e.target.dataset, { x: 0, y: 0, h: 0 });
105
104
  })
@@ -108,7 +107,6 @@ const VerdocsFieldTextbox = class {
108
107
  render() {
109
108
  var _a, _b;
110
109
  const field = this.fieldStore.get(this.fieldname);
111
- console.log('textbox', this.fieldname, field);
112
110
  if (!field) {
113
111
  return index.h(index.Fragment, null);
114
112
  }
@@ -69,7 +69,7 @@ const VerdocsPreview = class {
69
69
  console.log('[PREVIEW] Unable to start builder session, must be authenticated');
70
70
  return;
71
71
  }
72
- this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, true);
72
+ this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, false);
73
73
  console.log(`[PREVIEW] Loading template ${this.templateId}`, this.endpoint.session);
74
74
  }
75
75
  catch (e) {
@@ -143,7 +143,7 @@ const VerdocsSend = class {
143
143
  console.log('[SEND] Unable to start builder session, must be authenticated');
144
144
  return;
145
145
  }
146
- this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, true);
146
+ this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, false);
147
147
  if (!((_b = (_a = this.store) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.is_sendable)) {
148
148
  console.warn(`[SEND] Template is not sendable`, this.templateId);
149
149
  }
@@ -313,7 +313,7 @@ const VerdocsTemplateAttachments = class {
313
313
  try {
314
314
  const template = await TemplateDocuments.createTemplateDocument(this.endpoint, this.templateId, file, this.handleUploadProgress.bind(this));
315
315
  console.log('[ATTACHMENTS] Created attachment', template);
316
- this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, true);
316
+ this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, false);
317
317
  console.log('[ATTACHMENTS] Updated template', this.store.state);
318
318
  (_a = this.templateUpdated) === null || _a === void 0 ? void 0 : _a.emit({ endpoint: this.endpoint, template: this.store.state, event: 'attachments' });
319
319
  this.uploading = false;
@@ -336,7 +336,7 @@ const VerdocsTemplateAttachments = class {
336
336
  }
337
337
  async confirmDelete() {
338
338
  await TemplateDocuments.deleteTemplateDocument(this.endpoint, this.templateId, this.confirmDeleteDocument.id);
339
- this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, true);
339
+ this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, false);
340
340
  console.log('[ATTACHMENTS] New template', this.store.state);
341
341
  this.confirmDeleteDocument = null;
342
342
  }
@@ -668,7 +668,7 @@ const VerdocsTemplateReminders = class {
668
668
  console.log('[ROLES] Unable to start builder session, must be authenticated');
669
669
  return;
670
670
  }
671
- this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, true);
671
+ this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, false);
672
672
  this.sendReminders = !!((_b = (_a = this.store) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.reminder_id);
673
673
  this.dirty = false;
674
674
  }
@@ -695,16 +695,16 @@ const VerdocsTemplateReminders = class {
695
695
  };
696
696
  if (!((_b = (_a = this.store) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.reminder_id)) {
697
697
  await createReminder(this.endpoint, this.templateId, params);
698
- this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, true);
698
+ this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, false);
699
699
  }
700
700
  else {
701
701
  await updateReminder(this.endpoint, this.templateId, (_c = this.store) === null || _c === void 0 ? void 0 : _c.state.reminder_id, params);
702
- this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, true);
702
+ this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, false);
703
703
  }
704
704
  }
705
705
  else {
706
706
  await deleteReminder(this.endpoint, this.templateId, (_d = this.store) === null || _d === void 0 ? void 0 : _d.state.reminder_id);
707
- this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, true);
707
+ this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, false);
708
708
  }
709
709
  (_e = this.templateUpdated) === null || _e === void 0 ? void 0 : _e.emit({ endpoint: this.endpoint, template: this.store.state, event: 'attachments' });
710
710
  }
@@ -730,7 +730,7 @@ const VerdocsTemplateReminders = class {
730
730
  // e.target.checked = false;
731
731
  this.sendReminders = e.target.checked;
732
732
  this.dirty = true;
733
- } })), index.h("div", { class: "input-row" }, index.h("label", { htmlFor: "verdocs-first-reminder-days" }, "Days Before First Reminder"), index.h("verdocs-text-input", { id: "verdocs-first-reminder-days", type: "number", value: this.firstReminderDays, onInput: (e) => {
733
+ } })), index.h("p", null, index.h("strong", null, "NOTE:"), " Reminders will only be sent for up to 14 days."), index.h("div", { class: "input-row" }, index.h("label", { htmlFor: "verdocs-first-reminder-days" }, "Days Before First Reminder"), index.h("verdocs-text-input", { id: "verdocs-first-reminder-days", type: "number", value: this.firstReminderDays, onInput: (e) => {
734
734
  this.firstReminderDays = e.target.value;
735
735
  this.dirty = true;
736
736
  }, disabled: !this.sendReminders })), index.h("div", { class: "input-row" }, index.h("label", { htmlFor: "verdocs-days-between-reminders" }, "Days Between Reminders"), index.h("verdocs-text-input", { id: "verdocs-days-between-reminders", type: "number", value: this.reminderDays, onInput: (e) => {
@@ -100,7 +100,7 @@ const VerdocsTemplateFields = class {
100
100
  console.log('[FIELDS] Unable to start builder session, must be authenticated');
101
101
  return;
102
102
  }
103
- this.templateStore = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, true);
103
+ this.templateStore = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, false);
104
104
  this.fieldStore = TemplateFieldStore.createTemplateFieldStore(this.templateStore.state);
105
105
  this.selectedRoleName = ((_d = (_c = (_b = (_a = this.templateStore) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.roles) === null || _c === void 0 ? void 0 : _c[0]) === null || _d === void 0 ? void 0 : _d.name) || '';
106
106
  }
@@ -505,7 +505,7 @@ const VerdocsTemplateRoleProperties = class {
505
505
  console.log('[ROLE_PROPERTIES] Update result', r);
506
506
  this.saving = false;
507
507
  this.dirty = false;
508
- this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, true);
508
+ this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, false);
509
509
  // this.sortTemplateRoles();
510
510
  // this.renumberTemplateRoles();
511
511
  // const newRoles = [...this.store.state.roles];
@@ -625,7 +625,7 @@ const VerdocsTemplateRoles = class {
625
625
  }
626
626
  }
627
627
  async reloadStore() {
628
- this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, true);
628
+ this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, false);
629
629
  this.sortTemplateRoles();
630
630
  this.renumberTemplateRoles();
631
631
  }
@@ -782,7 +782,7 @@ const VerdocsTemplateRoles = class {
782
782
  .then(async (r) => {
783
783
  var _a, _b;
784
784
  console.log('[ROLES] Created role', r);
785
- this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, true);
785
+ this.store = await TemplateStore.getTemplateStore(this.endpoint, this.templateId, false);
786
786
  this.sortTemplateRoles();
787
787
  this.renumberTemplateRoles();
788
788
  // this.store.state.roles = [...this.store?.state.roles, r];
@@ -830,7 +830,7 @@ const VerdocsTemplateRoles = class {
830
830
  // this.forceRerender++;
831
831
  }, onDelete: async () => {
832
832
  var _a, _b;
833
- await TemplateStore.getTemplateStore(this.endpoint, this.templateId, true);
833
+ await TemplateStore.getTemplateStore(this.endpoint, this.templateId, false);
834
834
  this.renumberTemplateRoles();
835
835
  this.showingRoleDialog = null;
836
836
  // this.forceRerender++;
@@ -43,7 +43,7 @@ export class VerdocsBuild {
43
43
  async loadTemplate(templateId) {
44
44
  if (templateId) {
45
45
  console.log('Loading store', templateId);
46
- this.store = await getTemplateStore(this.endpoint, templateId, true);
46
+ this.store = await getTemplateStore(this.endpoint, templateId, false);
47
47
  forceUpdate(this.el);
48
48
  }
49
49
  }
@@ -27,7 +27,7 @@ export class VerdocsPreview {
27
27
  console.log('[PREVIEW] Unable to start builder session, must be authenticated');
28
28
  return;
29
29
  }
30
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
30
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
31
31
  console.log(`[PREVIEW] Loading template ${this.templateId}`, this.endpoint.session);
32
32
  }
33
33
  catch (e) {
@@ -48,7 +48,7 @@ export class VerdocsSend {
48
48
  console.log('[SEND] Unable to start builder session, must be authenticated');
49
49
  return;
50
50
  }
51
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
51
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
52
52
  if (!((_b = (_a = this.store) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.is_sendable)) {
53
53
  console.warn(`[SEND] Template is not sendable`, this.templateId);
54
54
  }
@@ -42,7 +42,6 @@ export class VerdocsFieldTextbox {
42
42
  }
43
43
  async componentWillLoad() {
44
44
  this.fieldStore = getTemplateFieldStore(this.templateid);
45
- console.log('fs', this.templateid);
46
45
  }
47
46
  componentDidRender() {
48
47
  interact.dynamicDrop(true);
@@ -85,7 +84,7 @@ export class VerdocsFieldTextbox {
85
84
  updateField(this.endpoint, this.templateid, this.fieldname, { setting: newSettings })
86
85
  .then(field => {
87
86
  var _a;
88
- console.log('update result', field);
87
+ console.log('Update result', field);
89
88
  (_a = this.settingsChanged) === null || _a === void 0 ? void 0 : _a.emit({ fieldName: field.name, settings: newSettings, field });
90
89
  Object.assign(e.target.dataset, { x: 0, y: 0, h: 0 });
91
90
  })
@@ -94,7 +93,6 @@ export class VerdocsFieldTextbox {
94
93
  render() {
95
94
  var _a, _b;
96
95
  const field = this.fieldStore.get(this.fieldname);
97
- console.log('textbox', this.fieldname, field);
98
96
  if (!field) {
99
97
  return h(Fragment, null);
100
98
  }
@@ -64,7 +64,7 @@ export class VerdocsTemplateAttachments {
64
64
  try {
65
65
  const template = await createTemplateDocument(this.endpoint, this.templateId, file, this.handleUploadProgress.bind(this));
66
66
  console.log('[ATTACHMENTS] Created attachment', template);
67
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
67
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
68
68
  console.log('[ATTACHMENTS] Updated template', this.store.state);
69
69
  (_a = this.templateUpdated) === null || _a === void 0 ? void 0 : _a.emit({ endpoint: this.endpoint, template: this.store.state, event: 'attachments' });
70
70
  this.uploading = false;
@@ -87,7 +87,7 @@ export class VerdocsTemplateAttachments {
87
87
  }
88
88
  async confirmDelete() {
89
89
  await deleteTemplateDocument(this.endpoint, this.templateId, this.confirmDeleteDocument.id);
90
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
90
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
91
91
  console.log('[ATTACHMENTS] New template', this.store.state);
92
92
  this.confirmDeleteDocument = null;
93
93
  }
@@ -63,7 +63,7 @@ export class VerdocsTemplateFields {
63
63
  console.log('[FIELDS] Unable to start builder session, must be authenticated');
64
64
  return;
65
65
  }
66
- this.templateStore = await getTemplateStore(this.endpoint, this.templateId, true);
66
+ this.templateStore = await getTemplateStore(this.endpoint, this.templateId, false);
67
67
  this.fieldStore = createTemplateFieldStore(this.templateStore.state);
68
68
  this.selectedRoleName = ((_d = (_c = (_b = (_a = this.templateStore) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.roles) === null || _c === void 0 ? void 0 : _c[0]) === null || _d === void 0 ? void 0 : _d.name) || '';
69
69
  }
@@ -33,7 +33,7 @@ export class VerdocsTemplateReminders {
33
33
  console.log('[ROLES] Unable to start builder session, must be authenticated');
34
34
  return;
35
35
  }
36
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
36
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
37
37
  this.sendReminders = !!((_b = (_a = this.store) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.reminder_id);
38
38
  this.dirty = false;
39
39
  }
@@ -60,16 +60,16 @@ export class VerdocsTemplateReminders {
60
60
  };
61
61
  if (!((_b = (_a = this.store) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.reminder_id)) {
62
62
  await createReminder(this.endpoint, this.templateId, params);
63
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
63
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
64
64
  }
65
65
  else {
66
66
  await updateReminder(this.endpoint, this.templateId, (_c = this.store) === null || _c === void 0 ? void 0 : _c.state.reminder_id, params);
67
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
67
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
68
68
  }
69
69
  }
70
70
  else {
71
71
  await deleteReminder(this.endpoint, this.templateId, (_d = this.store) === null || _d === void 0 ? void 0 : _d.state.reminder_id);
72
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
72
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
73
73
  }
74
74
  (_e = this.templateUpdated) === null || _e === void 0 ? void 0 : _e.emit({ endpoint: this.endpoint, template: this.store.state, event: 'attachments' });
75
75
  }
@@ -95,7 +95,7 @@ export class VerdocsTemplateReminders {
95
95
  // e.target.checked = false;
96
96
  this.sendReminders = e.target.checked;
97
97
  this.dirty = true;
98
- } })), h("div", { class: "input-row" }, h("label", { htmlFor: "verdocs-first-reminder-days" }, "Days Before First Reminder"), h("verdocs-text-input", { id: "verdocs-first-reminder-days", type: "number", value: this.firstReminderDays, onInput: (e) => {
98
+ } })), h("p", null, h("strong", null, "NOTE:"), " Reminders will only be sent for up to 14 days."), h("div", { class: "input-row" }, h("label", { htmlFor: "verdocs-first-reminder-days" }, "Days Before First Reminder"), h("verdocs-text-input", { id: "verdocs-first-reminder-days", type: "number", value: this.firstReminderDays, onInput: (e) => {
99
99
  this.firstReminderDays = e.target.value;
100
100
  this.dirty = true;
101
101
  }, disabled: !this.sendReminders })), h("div", { class: "input-row" }, h("label", { htmlFor: "verdocs-days-between-reminders" }, "Days Between Reminders"), h("verdocs-text-input", { id: "verdocs-days-between-reminders", type: "number", value: this.reminderDays, onInput: (e) => {
@@ -76,7 +76,7 @@ export class VerdocsTemplateRoleProperties {
76
76
  console.log('[ROLE_PROPERTIES] Update result', r);
77
77
  this.saving = false;
78
78
  this.dirty = false;
79
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
79
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
80
80
  // this.sortTemplateRoles();
81
81
  // this.renumberTemplateRoles();
82
82
  // const newRoles = [...this.store.state.roles];
@@ -55,7 +55,7 @@ export class VerdocsTemplateRoles {
55
55
  }
56
56
  }
57
57
  async reloadStore() {
58
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
58
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
59
59
  this.sortTemplateRoles();
60
60
  this.renumberTemplateRoles();
61
61
  }
@@ -212,7 +212,7 @@ export class VerdocsTemplateRoles {
212
212
  .then(async (r) => {
213
213
  var _a, _b;
214
214
  console.log('[ROLES] Created role', r);
215
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
215
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
216
216
  this.sortTemplateRoles();
217
217
  this.renumberTemplateRoles();
218
218
  // this.store.state.roles = [...this.store?.state.roles, r];
@@ -260,7 +260,7 @@ export class VerdocsTemplateRoles {
260
260
  // this.forceRerender++;
261
261
  }, onDelete: async () => {
262
262
  var _a, _b;
263
- await getTemplateStore(this.endpoint, this.templateId, true);
263
+ await getTemplateStore(this.endpoint, this.templateId, false);
264
264
  this.renumberTemplateRoles();
265
265
  this.showingRoleDialog = null;
266
266
  // this.forceRerender++;
@@ -81,7 +81,7 @@ const VerdocsBuild$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLElemen
81
81
  async loadTemplate(templateId) {
82
82
  if (templateId) {
83
83
  console.log('Loading store', templateId);
84
- this.store = await getTemplateStore(this.endpoint, templateId, true);
84
+ this.store = await getTemplateStore(this.endpoint, templateId, false);
85
85
  forceUpdate(this.el);
86
86
  }
87
87
  }
@@ -55,7 +55,6 @@ const VerdocsFieldTextbox$1 = /*@__PURE__*/ proxyCustomElement(class extends HTM
55
55
  }
56
56
  async componentWillLoad() {
57
57
  this.fieldStore = getTemplateFieldStore(this.templateid);
58
- console.log('fs', this.templateid);
59
58
  }
60
59
  componentDidRender() {
61
60
  interact_min.dynamicDrop(true);
@@ -98,7 +97,7 @@ const VerdocsFieldTextbox$1 = /*@__PURE__*/ proxyCustomElement(class extends HTM
98
97
  updateField(this.endpoint, this.templateid, this.fieldname, { setting: newSettings })
99
98
  .then(field => {
100
99
  var _a;
101
- console.log('update result', field);
100
+ console.log('Update result', field);
102
101
  (_a = this.settingsChanged) === null || _a === void 0 ? void 0 : _a.emit({ fieldName: field.name, settings: newSettings, field });
103
102
  Object.assign(e.target.dataset, { x: 0, y: 0, h: 0 });
104
103
  })
@@ -107,7 +106,6 @@ const VerdocsFieldTextbox$1 = /*@__PURE__*/ proxyCustomElement(class extends HTM
107
106
  render() {
108
107
  var _a, _b;
109
108
  const field = this.fieldStore.get(this.fieldname);
110
- console.log('textbox', this.fieldname, field);
111
109
  if (!field) {
112
110
  return h(Fragment, null);
113
111
  }
@@ -30,7 +30,7 @@ const VerdocsPreview = /*@__PURE__*/ proxyCustomElement(class extends HTMLElemen
30
30
  console.log('[PREVIEW] Unable to start builder session, must be authenticated');
31
31
  return;
32
32
  }
33
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
33
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
34
34
  console.log(`[PREVIEW] Loading template ${this.templateId}`, this.endpoint.session);
35
35
  }
36
36
  catch (e) {
@@ -54,7 +54,7 @@ const VerdocsSend = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
54
54
  console.log('[SEND] Unable to start builder session, must be authenticated');
55
55
  return;
56
56
  }
57
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
57
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
58
58
  if (!((_b = (_a = this.store) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.is_sendable)) {
59
59
  console.warn(`[SEND] Template is not sendable`, this.templateId);
60
60
  }
@@ -75,7 +75,7 @@ const VerdocsTemplateAttachments = /*@__PURE__*/ proxyCustomElement(class extend
75
75
  try {
76
76
  const template = await createTemplateDocument(this.endpoint, this.templateId, file, this.handleUploadProgress.bind(this));
77
77
  console.log('[ATTACHMENTS] Created attachment', template);
78
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
78
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
79
79
  console.log('[ATTACHMENTS] Updated template', this.store.state);
80
80
  (_a = this.templateUpdated) === null || _a === void 0 ? void 0 : _a.emit({ endpoint: this.endpoint, template: this.store.state, event: 'attachments' });
81
81
  this.uploading = false;
@@ -98,7 +98,7 @@ const VerdocsTemplateAttachments = /*@__PURE__*/ proxyCustomElement(class extend
98
98
  }
99
99
  async confirmDelete() {
100
100
  await deleteTemplateDocument(this.endpoint, this.templateId, this.confirmDeleteDocument.id);
101
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
101
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
102
102
  console.log('[ATTACHMENTS] New template', this.store.state);
103
103
  this.confirmDeleteDocument = null;
104
104
  }
@@ -74,7 +74,7 @@ const VerdocsTemplateFields = /*@__PURE__*/ proxyCustomElement(class extends HTM
74
74
  console.log('[FIELDS] Unable to start builder session, must be authenticated');
75
75
  return;
76
76
  }
77
- this.templateStore = await getTemplateStore(this.endpoint, this.templateId, true);
77
+ this.templateStore = await getTemplateStore(this.endpoint, this.templateId, false);
78
78
  this.fieldStore = createTemplateFieldStore(this.templateStore.state);
79
79
  this.selectedRoleName = ((_d = (_c = (_b = (_a = this.templateStore) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.roles) === null || _c === void 0 ? void 0 : _c[0]) === null || _d === void 0 ? void 0 : _d.name) || '';
80
80
  }
@@ -70,7 +70,7 @@ const VerdocsTemplateReminders = /*@__PURE__*/ proxyCustomElement(class extends
70
70
  console.log('[ROLES] Unable to start builder session, must be authenticated');
71
71
  return;
72
72
  }
73
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
73
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
74
74
  this.sendReminders = !!((_b = (_a = this.store) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.reminder_id);
75
75
  this.dirty = false;
76
76
  }
@@ -97,16 +97,16 @@ const VerdocsTemplateReminders = /*@__PURE__*/ proxyCustomElement(class extends
97
97
  };
98
98
  if (!((_b = (_a = this.store) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.reminder_id)) {
99
99
  await createReminder(this.endpoint, this.templateId, params);
100
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
100
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
101
101
  }
102
102
  else {
103
103
  await updateReminder(this.endpoint, this.templateId, (_c = this.store) === null || _c === void 0 ? void 0 : _c.state.reminder_id, params);
104
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
104
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
105
105
  }
106
106
  }
107
107
  else {
108
108
  await deleteReminder(this.endpoint, this.templateId, (_d = this.store) === null || _d === void 0 ? void 0 : _d.state.reminder_id);
109
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
109
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
110
110
  }
111
111
  (_e = this.templateUpdated) === null || _e === void 0 ? void 0 : _e.emit({ endpoint: this.endpoint, template: this.store.state, event: 'attachments' });
112
112
  }
@@ -132,7 +132,7 @@ const VerdocsTemplateReminders = /*@__PURE__*/ proxyCustomElement(class extends
132
132
  // e.target.checked = false;
133
133
  this.sendReminders = e.target.checked;
134
134
  this.dirty = true;
135
- } })), h("div", { class: "input-row" }, h("label", { htmlFor: "verdocs-first-reminder-days" }, "Days Before First Reminder"), h("verdocs-text-input", { id: "verdocs-first-reminder-days", type: "number", value: this.firstReminderDays, onInput: (e) => {
135
+ } })), h("p", null, h("strong", null, "NOTE:"), " Reminders will only be sent for up to 14 days."), h("div", { class: "input-row" }, h("label", { htmlFor: "verdocs-first-reminder-days" }, "Days Before First Reminder"), h("verdocs-text-input", { id: "verdocs-first-reminder-days", type: "number", value: this.firstReminderDays, onInput: (e) => {
136
136
  this.firstReminderDays = e.target.value;
137
137
  this.dirty = true;
138
138
  }, disabled: !this.sendReminders })), h("div", { class: "input-row" }, h("label", { htmlFor: "verdocs-days-between-reminders" }, "Days Between Reminders"), h("verdocs-text-input", { id: "verdocs-days-between-reminders", type: "number", value: this.reminderDays, onInput: (e) => {
@@ -108,7 +108,7 @@ const VerdocsTemplateRoleProperties = /*@__PURE__*/ proxyCustomElement(class ext
108
108
  console.log('[ROLE_PROPERTIES] Update result', r);
109
109
  this.saving = false;
110
110
  this.dirty = false;
111
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
111
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
112
112
  // this.sortTemplateRoles();
113
113
  // this.renumberTemplateRoles();
114
114
  // const newRoles = [...this.store.state.roles];
@@ -70,7 +70,7 @@ const VerdocsTemplateRoles = /*@__PURE__*/ proxyCustomElement(class extends HTML
70
70
  }
71
71
  }
72
72
  async reloadStore() {
73
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
73
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
74
74
  this.sortTemplateRoles();
75
75
  this.renumberTemplateRoles();
76
76
  }
@@ -227,7 +227,7 @@ const VerdocsTemplateRoles = /*@__PURE__*/ proxyCustomElement(class extends HTML
227
227
  .then(async (r) => {
228
228
  var _a, _b;
229
229
  console.log('[ROLES] Created role', r);
230
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
230
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
231
231
  this.sortTemplateRoles();
232
232
  this.renumberTemplateRoles();
233
233
  // this.store.state.roles = [...this.store?.state.roles, r];
@@ -275,7 +275,7 @@ const VerdocsTemplateRoles = /*@__PURE__*/ proxyCustomElement(class extends HTML
275
275
  // this.forceRerender++;
276
276
  }, onDelete: async () => {
277
277
  var _a, _b;
278
- await getTemplateStore(this.endpoint, this.templateId, true);
278
+ await getTemplateStore(this.endpoint, this.templateId, false);
279
279
  this.renumberTemplateRoles();
280
280
  this.showingRoleDialog = null;
281
281
  // this.forceRerender++;
package/dist/docs.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "timestamp": "2024-01-11T15:18:22",
2
+ "timestamp": "2024-01-15T00:38:21",
3
3
  "compiler": {
4
4
  "name": "@stencil/core",
5
5
  "version": "2.20.0",
@@ -52,7 +52,7 @@ const VerdocsBuild = class {
52
52
  async loadTemplate(templateId) {
53
53
  if (templateId) {
54
54
  console.log('Loading store', templateId);
55
- this.store = await getTemplateStore(this.endpoint, templateId, true);
55
+ this.store = await getTemplateStore(this.endpoint, templateId, false);
56
56
  forceUpdate(this.el);
57
57
  }
58
58
  }
@@ -52,7 +52,6 @@ const VerdocsFieldTextbox = class {
52
52
  }
53
53
  async componentWillLoad() {
54
54
  this.fieldStore = getTemplateFieldStore(this.templateid);
55
- console.log('fs', this.templateid);
56
55
  }
57
56
  componentDidRender() {
58
57
  interact_min.dynamicDrop(true);
@@ -95,7 +94,7 @@ const VerdocsFieldTextbox = class {
95
94
  updateField(this.endpoint, this.templateid, this.fieldname, { setting: newSettings })
96
95
  .then(field => {
97
96
  var _a;
98
- console.log('update result', field);
97
+ console.log('Update result', field);
99
98
  (_a = this.settingsChanged) === null || _a === void 0 ? void 0 : _a.emit({ fieldName: field.name, settings: newSettings, field });
100
99
  Object.assign(e.target.dataset, { x: 0, y: 0, h: 0 });
101
100
  })
@@ -104,7 +103,6 @@ const VerdocsFieldTextbox = class {
104
103
  render() {
105
104
  var _a, _b;
106
105
  const field = this.fieldStore.get(this.fieldname);
107
- console.log('textbox', this.fieldname, field);
108
106
  if (!field) {
109
107
  return h(Fragment, null);
110
108
  }
@@ -65,7 +65,7 @@ const VerdocsPreview = class {
65
65
  console.log('[PREVIEW] Unable to start builder session, must be authenticated');
66
66
  return;
67
67
  }
68
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
68
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
69
69
  console.log(`[PREVIEW] Loading template ${this.templateId}`, this.endpoint.session);
70
70
  }
71
71
  catch (e) {
@@ -139,7 +139,7 @@ const VerdocsSend = class {
139
139
  console.log('[SEND] Unable to start builder session, must be authenticated');
140
140
  return;
141
141
  }
142
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
142
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
143
143
  if (!((_b = (_a = this.store) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.is_sendable)) {
144
144
  console.warn(`[SEND] Template is not sendable`, this.templateId);
145
145
  }
@@ -309,7 +309,7 @@ const VerdocsTemplateAttachments = class {
309
309
  try {
310
310
  const template = await createTemplateDocument(this.endpoint, this.templateId, file, this.handleUploadProgress.bind(this));
311
311
  console.log('[ATTACHMENTS] Created attachment', template);
312
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
312
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
313
313
  console.log('[ATTACHMENTS] Updated template', this.store.state);
314
314
  (_a = this.templateUpdated) === null || _a === void 0 ? void 0 : _a.emit({ endpoint: this.endpoint, template: this.store.state, event: 'attachments' });
315
315
  this.uploading = false;
@@ -332,7 +332,7 @@ const VerdocsTemplateAttachments = class {
332
332
  }
333
333
  async confirmDelete() {
334
334
  await deleteTemplateDocument(this.endpoint, this.templateId, this.confirmDeleteDocument.id);
335
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
335
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
336
336
  console.log('[ATTACHMENTS] New template', this.store.state);
337
337
  this.confirmDeleteDocument = null;
338
338
  }
@@ -664,7 +664,7 @@ const VerdocsTemplateReminders = class {
664
664
  console.log('[ROLES] Unable to start builder session, must be authenticated');
665
665
  return;
666
666
  }
667
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
667
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
668
668
  this.sendReminders = !!((_b = (_a = this.store) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.reminder_id);
669
669
  this.dirty = false;
670
670
  }
@@ -691,16 +691,16 @@ const VerdocsTemplateReminders = class {
691
691
  };
692
692
  if (!((_b = (_a = this.store) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.reminder_id)) {
693
693
  await createReminder(this.endpoint, this.templateId, params);
694
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
694
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
695
695
  }
696
696
  else {
697
697
  await updateReminder(this.endpoint, this.templateId, (_c = this.store) === null || _c === void 0 ? void 0 : _c.state.reminder_id, params);
698
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
698
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
699
699
  }
700
700
  }
701
701
  else {
702
702
  await deleteReminder(this.endpoint, this.templateId, (_d = this.store) === null || _d === void 0 ? void 0 : _d.state.reminder_id);
703
- this.store = await getTemplateStore(this.endpoint, this.templateId, true);
703
+ this.store = await getTemplateStore(this.endpoint, this.templateId, false);
704
704
  }
705
705
  (_e = this.templateUpdated) === null || _e === void 0 ? void 0 : _e.emit({ endpoint: this.endpoint, template: this.store.state, event: 'attachments' });
706
706
  }
@@ -726,7 +726,7 @@ const VerdocsTemplateReminders = class {
726
726
  // e.target.checked = false;
727
727
  this.sendReminders = e.target.checked;
728
728
  this.dirty = true;
729
- } })), h("div", { class: "input-row" }, h("label", { htmlFor: "verdocs-first-reminder-days" }, "Days Before First Reminder"), h("verdocs-text-input", { id: "verdocs-first-reminder-days", type: "number", value: this.firstReminderDays, onInput: (e) => {
729
+ } })), h("p", null, h("strong", null, "NOTE:"), " Reminders will only be sent for up to 14 days."), h("div", { class: "input-row" }, h("label", { htmlFor: "verdocs-first-reminder-days" }, "Days Before First Reminder"), h("verdocs-text-input", { id: "verdocs-first-reminder-days", type: "number", value: this.firstReminderDays, onInput: (e) => {
730
730
  this.firstReminderDays = e.target.value;
731
731
  this.dirty = true;
732
732
  }, disabled: !this.sendReminders })), h("div", { class: "input-row" }, h("label", { htmlFor: "verdocs-days-between-reminders" }, "Days Between Reminders"), h("verdocs-text-input", { id: "verdocs-days-between-reminders", type: "number", value: this.reminderDays, onInput: (e) => {