@verdocs/web-sdk 4.2.121 → 4.2.123

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 (167) hide show
  1. package/dist/cjs/index-a27a7f77.js +4 -4
  2. package/dist/cjs/loader.cjs.js +1 -1
  3. package/dist/cjs/{utils-6a8c3390.js → utils-5accd019.js} +1 -1
  4. package/dist/cjs/verdocs-button_3.cjs.entry.js +2 -2
  5. package/dist/cjs/verdocs-contact-picker_2.cjs.entry.js +1 -1
  6. package/dist/cjs/verdocs-envelope-document-page.cjs.entry.js +2 -2
  7. package/dist/cjs/verdocs-envelope-sidebar.cjs.entry.js +4 -2
  8. package/dist/cjs/verdocs-envelopes-list.cjs.entry.js +7 -7
  9. package/dist/cjs/verdocs-field-attachment_13.cjs.entry.js +41 -13
  10. package/dist/cjs/verdocs-kba-dialog_2.cjs.entry.js +4 -4
  11. package/dist/cjs/verdocs-pagination_2.cjs.entry.js +1 -1
  12. package/dist/cjs/verdocs-preview_9.cjs.entry.js +1 -1
  13. package/dist/cjs/verdocs-quick-functions.cjs.entry.js +1 -1
  14. package/dist/cjs/verdocs-radio-button_3.cjs.entry.js +9 -9
  15. package/dist/cjs/verdocs-search-tabs.cjs.entry.js +1 -1
  16. package/dist/cjs/verdocs-sign.cjs.entry.js +78 -29
  17. package/dist/cjs/verdocs-status-indicator.cjs.entry.js +2 -2
  18. package/dist/cjs/verdocs-template-card.cjs.entry.js +1 -1
  19. package/dist/cjs/verdocs-template-document-page_2.cjs.entry.js +2 -2
  20. package/dist/cjs/verdocs-template-star.cjs.entry.js +1 -1
  21. package/dist/cjs/verdocs-template-tags.cjs.entry.js +1 -1
  22. package/dist/cjs/verdocs-web-sdk.cjs.js +1 -1
  23. package/dist/collection/components/controls/verdocs-button/verdocs-button.css +14 -0
  24. package/dist/collection/components/controls/verdocs-button/verdocs-button.js +3 -3
  25. package/dist/collection/components/dialogs/verdocs-upload-dialog/verdocs-upload-dialog.css +1 -1
  26. package/dist/collection/components/dialogs/verdocs-upload-dialog/verdocs-upload-dialog.js +18 -4
  27. package/dist/collection/components/elements/verdocs-quick-functions/verdocs-quick-functions.js +1 -1
  28. package/dist/collection/components/elements/verdocs-search-tabs/verdocs-search-tabs.js +1 -1
  29. package/dist/collection/components/embeds/verdocs-sign/verdocs-sign.css +4 -3
  30. package/dist/collection/components/embeds/verdocs-sign/verdocs-sign.js +78 -27
  31. package/dist/collection/components/embeds/verdocs-view/verdocs-view.js +4 -3
  32. package/dist/collection/components/envelopes/verdocs-envelope-document-page/verdocs-envelope-document-page.js +1 -1
  33. package/dist/collection/components/envelopes/verdocs-envelope-sidebar/verdocs-envelope-sidebar.js +4 -2
  34. package/dist/collection/components/envelopes/verdocs-envelopes-list/verdocs-envelopes-list.js +6 -6
  35. package/dist/collection/components/envelopes/verdocs-status-indicator/verdocs-status-indicator.js +2 -2
  36. package/dist/collection/components/fields/verdocs-field-attachment/verdocs-field-attachment.js +17 -25
  37. package/dist/collection/components/fields/verdocs-field-date/verdocs-field-date.js +4 -1
  38. package/dist/collection/components/fields/verdocs-field-dropdown/verdocs-field-dropdown.js +8 -1
  39. package/dist/collection/components/templates/verdocs-template-card/verdocs-template-card.js +1 -1
  40. package/dist/collection/components/templates/verdocs-template-document-page/verdocs-template-document-page.js +1 -1
  41. package/dist/collection/components/templates/verdocs-template-role-properties/verdocs-template-role-properties.js +8 -8
  42. package/dist/collection/components/templates/verdocs-template-sender/verdocs-template-sender.js +1 -1
  43. package/dist/collection/components/templates/verdocs-template-star/verdocs-template-star.js +1 -1
  44. package/dist/collection/components/templates/verdocs-template-tags/verdocs-template-tags.js +1 -1
  45. package/dist/collection/utils/utils.js +1 -1
  46. package/dist/components/utils.js +1 -1
  47. package/dist/components/verdocs-button2.js +2 -2
  48. package/dist/components/verdocs-envelope-document-page2.js +1 -1
  49. package/dist/components/verdocs-envelope-sidebar.js +4 -2
  50. package/dist/components/verdocs-envelopes-list.js +6 -6
  51. package/dist/components/verdocs-field-attachment2.js +27 -15
  52. package/dist/components/verdocs-field-date2.js +4 -1
  53. package/dist/components/verdocs-field-dropdown2.js +8 -1
  54. package/dist/components/verdocs-preview2.js +38 -32
  55. package/dist/components/verdocs-quick-functions.js +1 -1
  56. package/dist/components/verdocs-search-tabs.js +1 -1
  57. package/dist/components/verdocs-sign.js +80 -29
  58. package/dist/components/verdocs-status-indicator2.js +2 -2
  59. package/dist/components/verdocs-template-card.js +1 -1
  60. package/dist/components/verdocs-template-document-page2.js +37 -31
  61. package/dist/components/verdocs-template-role-properties2.js +8 -8
  62. package/dist/components/verdocs-template-sender2.js +1 -1
  63. package/dist/components/verdocs-template-star2.js +1 -1
  64. package/dist/components/verdocs-template-tags.js +1 -1
  65. package/dist/components/verdocs-upload-dialog2.js +25 -6
  66. package/dist/components/verdocs-view2.js +3 -3
  67. package/dist/esm/index-a68c7262.js +4 -4
  68. package/dist/esm/loader.js +1 -1
  69. package/dist/esm/{utils-8f3ace81.js → utils-6ecd6558.js} +1 -1
  70. package/dist/esm/verdocs-button_3.entry.js +2 -2
  71. package/dist/esm/verdocs-contact-picker_2.entry.js +1 -1
  72. package/dist/esm/verdocs-envelope-document-page.entry.js +2 -2
  73. package/dist/esm/verdocs-envelope-sidebar.entry.js +4 -2
  74. package/dist/esm/verdocs-envelopes-list.entry.js +7 -7
  75. package/dist/esm/verdocs-field-attachment_13.entry.js +41 -13
  76. package/dist/esm/verdocs-kba-dialog_2.entry.js +4 -4
  77. package/dist/esm/verdocs-pagination_2.entry.js +1 -1
  78. package/dist/esm/verdocs-preview_9.entry.js +1 -1
  79. package/dist/esm/verdocs-quick-functions.entry.js +1 -1
  80. package/dist/esm/verdocs-radio-button_3.entry.js +9 -9
  81. package/dist/esm/verdocs-search-tabs.entry.js +1 -1
  82. package/dist/esm/verdocs-sign.entry.js +79 -30
  83. package/dist/esm/verdocs-status-indicator.entry.js +2 -2
  84. package/dist/esm/verdocs-template-card.entry.js +1 -1
  85. package/dist/esm/verdocs-template-document-page_2.entry.js +2 -2
  86. package/dist/esm/verdocs-template-star.entry.js +1 -1
  87. package/dist/esm/verdocs-template-tags.entry.js +1 -1
  88. package/dist/esm/verdocs-web-sdk.js +1 -1
  89. package/dist/esm-es5/index-a68c7262.js +1 -1
  90. package/dist/esm-es5/loader.js +1 -1
  91. package/dist/esm-es5/{utils-8f3ace81.js → utils-6ecd6558.js} +1 -1
  92. package/dist/esm-es5/verdocs-button_3.entry.js +1 -1
  93. package/dist/esm-es5/verdocs-contact-picker_2.entry.js +1 -1
  94. package/dist/esm-es5/verdocs-envelope-document-page.entry.js +1 -1
  95. package/dist/esm-es5/verdocs-envelope-sidebar.entry.js +1 -1
  96. package/dist/esm-es5/verdocs-envelopes-list.entry.js +1 -1
  97. package/dist/esm-es5/verdocs-field-attachment_13.entry.js +1 -1
  98. package/dist/esm-es5/verdocs-kba-dialog_2.entry.js +1 -1
  99. package/dist/esm-es5/verdocs-pagination_2.entry.js +1 -1
  100. package/dist/esm-es5/verdocs-preview_9.entry.js +1 -1
  101. package/dist/esm-es5/verdocs-quick-functions.entry.js +1 -1
  102. package/dist/esm-es5/verdocs-radio-button_3.entry.js +1 -1
  103. package/dist/esm-es5/verdocs-search-tabs.entry.js +1 -1
  104. package/dist/esm-es5/verdocs-sign.entry.js +1 -1
  105. package/dist/esm-es5/verdocs-status-indicator.entry.js +1 -1
  106. package/dist/esm-es5/verdocs-template-card.entry.js +1 -1
  107. package/dist/esm-es5/verdocs-template-document-page_2.entry.js +1 -1
  108. package/dist/esm-es5/verdocs-template-star.entry.js +1 -1
  109. package/dist/esm-es5/verdocs-template-tags.entry.js +1 -1
  110. package/dist/esm-es5/verdocs-web-sdk.js +1 -1
  111. package/dist/types/components/controls/verdocs-button/verdocs-button.d.ts +1 -1
  112. package/dist/types/components/dialogs/verdocs-upload-dialog/verdocs-upload-dialog.d.ts +4 -2
  113. package/dist/types/components/embeds/verdocs-sign/verdocs-sign.d.ts +2 -0
  114. package/dist/types/components/embeds/verdocs-view/verdocs-view.d.ts +1 -1
  115. package/dist/types/components/envelopes/verdocs-envelope-sidebar/verdocs-envelope-sidebar.d.ts +1 -1
  116. package/dist/types/components/fields/verdocs-field-attachment/verdocs-field-attachment.d.ts +5 -8
  117. package/dist/types/components/fields/verdocs-field-date/verdocs-field-date.d.ts +2 -0
  118. package/dist/types/components.d.ts +11 -12
  119. package/dist/verdocs-web-sdk/p-02af8123.entry.js +1 -0
  120. package/dist/verdocs-web-sdk/p-267df026.system.js +1 -1
  121. package/dist/verdocs-web-sdk/{p-f3d00620.entry.js → p-28684a2b.entry.js} +1 -1
  122. package/dist/verdocs-web-sdk/{p-d00fb7f3.system.entry.js → p-2ee3549e.system.entry.js} +1 -1
  123. package/dist/verdocs-web-sdk/{p-60ae48fb.system.entry.js → p-3128b508.system.entry.js} +1 -1
  124. package/dist/verdocs-web-sdk/{p-7a3a3c2c.system.entry.js → p-43a7fce5.system.entry.js} +1 -1
  125. package/dist/verdocs-web-sdk/{p-b4b064ad.entry.js → p-48c2f79b.entry.js} +1 -1
  126. package/dist/verdocs-web-sdk/p-4ee43d61.entry.js +1 -0
  127. package/dist/verdocs-web-sdk/p-4f864f00.system.entry.js +1 -0
  128. package/dist/verdocs-web-sdk/{p-c5b6c6b0.entry.js → p-5313e672.entry.js} +1 -1
  129. package/dist/verdocs-web-sdk/{p-04cb12eb.system.js → p-5381847c.system.js} +1 -1
  130. package/dist/verdocs-web-sdk/{p-aa599c94.entry.js → p-55f49f87.entry.js} +1 -1
  131. package/dist/verdocs-web-sdk/{p-ae0ec155.entry.js → p-5b7fd148.entry.js} +1 -1
  132. package/dist/verdocs-web-sdk/{p-2510a25a.system.entry.js → p-6a57c036.system.entry.js} +1 -1
  133. package/dist/verdocs-web-sdk/{p-6885774c.entry.js → p-72b47a99.entry.js} +1 -1
  134. package/dist/verdocs-web-sdk/{p-24c226e1.system.entry.js → p-779a342d.system.entry.js} +1 -1
  135. package/dist/verdocs-web-sdk/{p-34439493.entry.js → p-77f12464.entry.js} +1 -1
  136. package/dist/verdocs-web-sdk/p-7cad3ec7.system.entry.js +1 -0
  137. package/dist/verdocs-web-sdk/{p-e621a28c.system.entry.js → p-7d7ca35a.system.entry.js} +1 -1
  138. package/dist/verdocs-web-sdk/p-826d6fb0.system.entry.js +1 -0
  139. package/dist/verdocs-web-sdk/{p-cb645d07.entry.js → p-8ce033ef.entry.js} +1 -1
  140. package/dist/verdocs-web-sdk/{p-46f5c0f0.system.entry.js → p-8f3ed4da.system.entry.js} +1 -1
  141. package/dist/verdocs-web-sdk/{p-6ab8ef68.system.entry.js → p-932ec5e5.system.entry.js} +1 -1
  142. package/dist/verdocs-web-sdk/p-93fc163b.entry.js +1 -0
  143. package/dist/verdocs-web-sdk/{p-6975a763.entry.js → p-98885cd8.entry.js} +1 -1
  144. package/dist/verdocs-web-sdk/{p-e9513023.system.entry.js → p-a6be54b0.system.entry.js} +1 -1
  145. package/dist/verdocs-web-sdk/{p-c539cdb9.entry.js → p-aace040e.entry.js} +1 -1
  146. package/dist/verdocs-web-sdk/{p-e723c6b1.entry.js → p-acf595c9.entry.js} +1 -1
  147. package/dist/verdocs-web-sdk/{p-2acc0c5c.system.entry.js → p-b52b2533.system.entry.js} +1 -1
  148. package/dist/verdocs-web-sdk/{p-147f2526.entry.js → p-bc9928a8.entry.js} +1 -1
  149. package/dist/verdocs-web-sdk/{p-e9c5d985.entry.js → p-c0018ff8.entry.js} +1 -1
  150. package/dist/verdocs-web-sdk/{p-d078d872.system.entry.js → p-c43f5df7.system.entry.js} +1 -1
  151. package/dist/verdocs-web-sdk/p-c5e65e9d.system.entry.js +1 -0
  152. package/dist/verdocs-web-sdk/{p-e2a9ee8d.entry.js → p-c9f545fe.entry.js} +1 -1
  153. package/dist/verdocs-web-sdk/{p-34f114de.system.entry.js → p-cc5245b4.system.entry.js} +1 -1
  154. package/dist/verdocs-web-sdk/{p-7798b826.system.entry.js → p-d119854a.system.entry.js} +1 -1
  155. package/dist/verdocs-web-sdk/p-e0ffd00f.entry.js +1 -0
  156. package/dist/verdocs-web-sdk/{p-68c7371d.system.entry.js → p-f96de332.system.entry.js} +1 -1
  157. package/dist/verdocs-web-sdk/{p-3b6dfc9f.js → p-fae63f89.js} +1 -1
  158. package/dist/verdocs-web-sdk/verdocs-web-sdk.esm.js +1 -1
  159. package/package.json +1 -1
  160. package/dist/verdocs-web-sdk/p-070549e6.system.entry.js +0 -1
  161. package/dist/verdocs-web-sdk/p-3164d8c4.system.entry.js +0 -1
  162. package/dist/verdocs-web-sdk/p-4cdc47be.system.entry.js +0 -1
  163. package/dist/verdocs-web-sdk/p-68eceea2.entry.js +0 -1
  164. package/dist/verdocs-web-sdk/p-6cadd2b5.entry.js +0 -1
  165. package/dist/verdocs-web-sdk/p-a146e2b0.system.entry.js +0 -1
  166. package/dist/verdocs-web-sdk/p-af74d24f.entry.js +0 -1
  167. package/dist/verdocs-web-sdk/p-d93a51b0.entry.js +0 -1
@@ -1,7 +1,8 @@
1
1
  import { proxyCustomElement, HTMLElement, createEvent, h, Host, Fragment } from '@stencil/core/internal/client';
2
- import { d as defineCustomElement$1 } from './verdocs-button2.js';
2
+ import { d as defineCustomElement$2 } from './verdocs-button2.js';
3
+ import { d as defineCustomElement$1 } from './verdocs-ok-dialog2.js';
3
4
 
4
- const verdocsUploadDialogCss = "@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-upload-dialog{position:fixed;-webkit-box-sizing:border-box;box-sizing:border-box;font-family:\"Inter\", \"Barlow\", sans-serif}verdocs-upload-dialog div{-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-upload-dialog .background-overlay{top:0;left:0;right:0;bottom:0;display:-ms-flexbox;display:flex;z-index:10000;position:fixed;-ms-flex-align:center;align-items:center;background:rgba(0, 0, 0, 0.4980392157);-ms-flex-pack:center;justify-content:center}verdocs-upload-dialog .dialog{width:320px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;border-radius:4px;overflow:hidden;background:#ffffff;padding:16px;-webkit-box-shadow:3px 3px 5px 1px rgba(40, 40, 40, 0.4);box-shadow:3px 3px 5px 1px rgba(40, 40, 40, 0.4)}verdocs-upload-dialog .heading{display:-ms-flexbox;display:flex;font-size:20px;font-weight:500;-ms-flex-direction:row;flex-direction:row}verdocs-upload-dialog .buttons{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:end;justify-content:flex-end}verdocs-upload-dialog .buttons verdocs-button{margin-left:16px}verdocs-upload-dialog .current-label{margin:20px 0 5px 0}verdocs-upload-dialog .drop-target{opacity:1;width:100%;display:-ms-flexbox;display:flex;margin:20px 0;min-height:260px;padding:30px 15px;text-align:center;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;background-color:#f5f5f5;color:rgba(0, 0, 0, 0.54);border:2px dashed #979797}verdocs-upload-dialog .drop-target p{margin:12px 0}verdocs-upload-dialog .drop-target.dragging-over{border:5px solid #4c56cb}verdocs-upload-dialog .drop-target>verdocs-button{margin:12px 0;display:inline-block}verdocs-upload-dialog .attachments{height:56px;font-size:0;margin:20px 0;padding:0 16px;line-height:56px;white-space:normal;-webkit-box-shadow:0 1px 3px 0 rgba(0, 0, 0, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.12), 0 0 2px 0 rgba(0, 0, 0, 0.14);box-shadow:0 1px 3px 0 rgba(0, 0, 0, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.12), 0 0 2px 0 rgba(0, 0, 0, 0.14)}verdocs-upload-dialog .attachments .attachment{gap:10px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}verdocs-upload-dialog .attachments .attachment .icon{width:18px;height:18px;line-height:18px}verdocs-upload-dialog .attachments .attachment .icon.trash{cursor:pointer}verdocs-upload-dialog .attachments .attachment .name{-ms-flex:1;flex:1;font-size:14px;overflow:hidden;font-weight:400;white-space:nowrap;text-overflow:ellipsis}";
5
+ const verdocsUploadDialogCss = "@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-upload-dialog{position:fixed;-webkit-box-sizing:border-box;box-sizing:border-box;font-family:\"Inter\", \"Barlow\", sans-serif}verdocs-upload-dialog div{-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-upload-dialog .background-overlay{top:0;left:0;right:0;bottom:0;display:-ms-flexbox;display:flex;z-index:10000;position:fixed;-ms-flex-align:center;align-items:center;background:rgba(0, 0, 0, 0.4980392157);-ms-flex-pack:center;justify-content:center}verdocs-upload-dialog .upload-dialog-content{width:320px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;border-radius:4px;overflow:hidden;background:#ffffff;padding:16px;-webkit-box-shadow:3px 3px 5px 1px rgba(40, 40, 40, 0.4);box-shadow:3px 3px 5px 1px rgba(40, 40, 40, 0.4)}verdocs-upload-dialog .heading{display:-ms-flexbox;display:flex;font-size:20px;font-weight:500;-ms-flex-direction:row;flex-direction:row}verdocs-upload-dialog .buttons{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:end;justify-content:flex-end}verdocs-upload-dialog .buttons verdocs-button{margin-left:16px}verdocs-upload-dialog .current-label{margin:20px 0 5px 0}verdocs-upload-dialog .drop-target{opacity:1;width:100%;display:-ms-flexbox;display:flex;margin:20px 0;min-height:260px;padding:30px 15px;text-align:center;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;background-color:#f5f5f5;color:rgba(0, 0, 0, 0.54);border:2px dashed #979797}verdocs-upload-dialog .drop-target p{margin:12px 0}verdocs-upload-dialog .drop-target.dragging-over{border:5px solid #4c56cb}verdocs-upload-dialog .drop-target>verdocs-button{margin:12px 0;display:inline-block}verdocs-upload-dialog .attachments{height:56px;font-size:0;margin:20px 0;padding:0 16px;line-height:56px;white-space:normal;-webkit-box-shadow:0 1px 3px 0 rgba(0, 0, 0, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.12), 0 0 2px 0 rgba(0, 0, 0, 0.14);box-shadow:0 1px 3px 0 rgba(0, 0, 0, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.12), 0 0 2px 0 rgba(0, 0, 0, 0.14)}verdocs-upload-dialog .attachments .attachment{gap:10px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}verdocs-upload-dialog .attachments .attachment .icon{width:18px;height:18px;line-height:18px}verdocs-upload-dialog .attachments .attachment .icon.trash{cursor:pointer}verdocs-upload-dialog .attachments .attachment .name{-ms-flex:1;flex:1;font-size:14px;overflow:hidden;font-weight:400;white-space:nowrap;text-overflow:ellipsis}";
5
6
  const VerdocsUploadDialogStyle0 = verdocsUploadDialogCss;
6
7
 
7
8
  const TrashIcon = `<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 7l-.867 12.142A2 2 0 0116.138 21H7.862a2 2 0 01-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 00-1-1h-4a1 1 0 00-1 1v3M4 7h16" /></svg>`;
@@ -15,6 +16,7 @@ const VerdocsUploadDialog = /*@__PURE__*/ proxyCustomElement(class VerdocsUpload
15
16
  this.remove = createEvent(this, "remove", 7);
16
17
  this.existingFile = undefined;
17
18
  this.draggingOver = false;
19
+ this.confirmDelete = false;
18
20
  this.selectedFiles = [];
19
21
  }
20
22
  handleCancel() {
@@ -48,11 +50,15 @@ const VerdocsUploadDialog = /*@__PURE__*/ proxyCustomElement(class VerdocsUpload
48
50
  newFiles.splice(index, 1);
49
51
  this.selectedFiles = newFiles;
50
52
  }
51
- handleDeleteAttachment() {
53
+ handleDeleteAttachment(e) {
52
54
  var _a;
53
- // TODO: Discuss how we want to delete up to the server
55
+ // Stop the parent from seeing "next" and thinking an upload was done.
56
+ // TODO: Rethink having so many commonalities in nested dialogs (next/exit).
57
+ e.preventDefault();
58
+ e.stopPropagation();
54
59
  (_a = this.remove) === null || _a === void 0 ? void 0 : _a.emit();
55
60
  this.existingFile = null;
61
+ this.confirmDelete = false;
56
62
  }
57
63
  handleSelectFile() {
58
64
  var _a;
@@ -63,19 +69,27 @@ const VerdocsUploadDialog = /*@__PURE__*/ proxyCustomElement(class VerdocsUpload
63
69
  this.selectedFiles = Array.from((_a = this.fileInput) === null || _a === void 0 ? void 0 : _a.files);
64
70
  }
65
71
  render() {
66
- return (h(Host, { key: 'ea7aaec178e0708c73e6ad4f12253f4ff73b9310' }, h("div", { key: '7d769afe448df6edfb40800bc08237d60c924d95', class: "background-overlay", onClick: e => this.handleDismiss(e) }, h("div", { key: 'cd32c34e98c48b1e48b1792bead1634ca70df871', class: "dialog" }, h("div", { key: 'eb7f1782c643b531c2ff6faf17e2248f803cde39', class: "heading" }, "Upload attachment"), this.selectedFiles.length < 1 && this.existingFile && (h(Fragment, { key: '2feac9b495828147f2be51e2368c7d03b039f64a' }, h("div", { key: '9ead90c769215c71bd952bb585a3cbde16c7e518', class: "current-label" }, "Current Attachment"), h("div", { key: '671e35179c26f14823ae504a1fc40f4506117e2e', class: "attachments", style: { marginTop: '0' } }, h("div", { key: '2ae16fe846ee84db2f0fdb2cfb39d1e0a30f85f2', class: "attachment" }, h("div", { key: '8db0145b16b3568d7fd5e1287a4a81b3a8822c3f', class: "icon", innerHTML: PaperclipIcon }), h("div", { key: '5c9c54ce036cec26e721fc32e4a9c8326735f221', class: "name" }, this.existingFile.name), h("div", { key: '99c17d1a88f6f8c07b346b37836969c60c1ee31d', class: "icon trash", innerHTML: TrashIcon, onClick: () => this.handleDeleteAttachment() }))))), this.selectedFiles.length < 1 && !this.existingFile && (h("div", { key: 'eec6e965857fca674db531ebad805c6931a2daf2', class: { 'drop-target': true, 'dragging-over': this.draggingOver }, onDragOver: e => this.handleDragOver(e), onDragLeave: e => this.handleDragLeave(e), onDrop: e => this.handleDrop(e) }, h("p", { key: '4dc240eacbd3724a54f6613113d98f5446c6c478' }, "Drag and drop a ", !!this.existingFile && 'replacement', " here..."), h("p", { key: 'af261cba2d009aa6733891e670029e4a2fec6a4d' }, "- or -"), h("verdocs-button", { key: 'f922efbffa39aa22b58b30b50697f17edcdd0f48', label: !!this.existingFile ? 'Replace file...' : 'Select a file...', onClick: () => this.handleSelectFile() }), h("input", { key: '504ae2231657a1ff6f27405b789c239f41f4fdce', type: "file", ref: el => (this.fileInput = el), style: { display: 'none' }, onChange: () => this.handleFileChange() }))), this.selectedFiles.length > 0 && (h("div", { key: 'e225969a1e6073a883e3e47fbeeec1bf88085f82', class: "attachments" }, this.selectedFiles.map((file, index) => (h("div", { class: "attachment" }, h("div", { class: "icon", innerHTML: PaperclipIcon }), h("div", { class: "name" }, file.name), h("div", { class: "icon trash", innerHTML: TrashIcon, onClick: () => this.handleRemoveAttachment(index) })))))), h("div", { key: 'b34ab1a0be4e5b7bfeb9f52b2e4820e8dce3a40a', class: "buttons" }, h("verdocs-button", { key: '9e35669d8a39a493b53434d680d66745610d4828', label: "Cancel", variant: "outline", onClick: () => this.handleCancel() }), h("verdocs-button", { key: '9b41014e538eecdec86221c637c09c8f00b9b3af', label: "Upload", onClick: () => this.handleDone(), disabled: this.selectedFiles.length < 1 }))))));
72
+ var _a;
73
+ const existingFile = ((_a = this.existingFile) === null || _a === void 0 ? void 0 : _a.name) ? this.existingFile : null;
74
+ return (h(Host, { key: '1659eb29f75e9bf3866a011a1ce39767f045e58c' }, h("div", { key: '764f802db78676a02d17fbf2ee93dd859c90494c', class: "background-overlay", onClick: e => this.handleDismiss(e) }, h("div", { key: 'c28580308a52defdd648f197aa5d1e74a1ff366c', class: "upload-dialog-content" }, h("div", { key: '6de50a3f71d93a176b4db5a248a49da4cf8d404d', class: "heading" }, "Upload attachment"), this.selectedFiles.length < 1 && existingFile && (h(Fragment, { key: '0882e3e5cae1dae105645f6f4b5dd8986c336e1f' }, h("div", { key: 'a762a4dbf4f1be8a29d637e6bee196ab4b960c60', class: "current-label" }, "Current Attachment"), h("div", { key: 'ada0b184bb53583dc6012ab5393be2a36714eba4', class: "attachments", style: { marginTop: '0' } }, h("div", { key: '3d9555cf0f7876ba192e3efec76bf677eec137cf', class: "attachment" }, h("div", { key: 'cea6d0e30448b6ea003a32d838bd64d642a621f3', class: "icon", innerHTML: PaperclipIcon }), h("div", { key: '20b87ade4eb56de78db2e0c1a7fe5c1f88d9f2c7', class: "name" }, existingFile.name), h("div", { key: '6359ea1dffd674d708afcd6b1e4f5be38062b861', class: "icon trash", innerHTML: TrashIcon, onClick: () => (this.confirmDelete = true) }))))), this.selectedFiles.length < 1 && !existingFile && (h("div", { key: 'c554239826339af3008fd9b4ef235efe6b4bf138', class: { 'drop-target': true, 'dragging-over': this.draggingOver }, onDragOver: e => this.handleDragOver(e), onDragLeave: e => this.handleDragLeave(e), onDrop: e => this.handleDrop(e) }, h("p", { key: 'a2bcc388981e79a1c6c3325081546ea41d7fd96f' }, "Drag and drop a ", !!existingFile && 'replacement', " here..."), h("p", { key: '23c7c1e2c8c369a8b85d83fc9a7d2e03bd26f6d9' }, "- or -"), h("verdocs-button", { key: 'cba655d0b392f5f03776f769cd3ee626b432b846', label: !!existingFile ? 'Replace file...' : 'Select a file...', onClick: () => this.handleSelectFile() }), h("input", { key: 'cbaa00e587959f418709c89b531a173512f5b9fa', type: "file", ref: el => (this.fileInput = el), style: { display: 'none' }, onChange: () => this.handleFileChange() }))), this.selectedFiles.length > 0 && (h("div", { key: '35f7be5ad20ecab5947c2f90f4ac529775ec51ce', class: "attachments" }, this.selectedFiles.map((file, index) => (h("div", { class: "attachment" }, h("div", { class: "icon", innerHTML: PaperclipIcon }), h("div", { class: "name" }, file.name), h("div", { class: "icon trash", innerHTML: TrashIcon, onClick: () => this.handleRemoveAttachment(index) })))))), h("div", { key: 'ea437cefbfa71cd4853f4fd77d1d1a78b576e032', class: "buttons" }, h("verdocs-button", { key: '2be19df5ae677ee0d0893266fd2f72aeff609e95', label: "Cancel", variant: "outline", onClick: () => this.handleCancel() }), h("verdocs-button", { key: '2013efb5dba9d6b3236ad280dbc6883473eebabf', label: "Upload", onClick: () => this.handleDone(), disabled: this.selectedFiles.length < 1 })))), this.confirmDelete && (h("verdocs-ok-dialog", { key: 'd55cbad44c7d50d9c479a87917b14fc0ae488a2b', heading: "Delete Attachment?", message: "Are you sure you wish to delete this attachment? This action cannot be undone.", showCancel: true, onExit: e => {
75
+ // So we don't close the upload dialog
76
+ e.preventDefault();
77
+ e.stopPropagation();
78
+ this.confirmDelete = false;
79
+ }, onNext: e => this.handleDeleteAttachment(e) }))));
67
80
  }
68
81
  static get style() { return VerdocsUploadDialogStyle0; }
69
82
  }, [0, "verdocs-upload-dialog", {
70
83
  "existingFile": [1032, "existing-file"],
71
84
  "draggingOver": [32],
85
+ "confirmDelete": [32],
72
86
  "selectedFiles": [32]
73
87
  }]);
74
88
  function defineCustomElement() {
75
89
  if (typeof customElements === "undefined") {
76
90
  return;
77
91
  }
78
- const components = ["verdocs-upload-dialog", "verdocs-button"];
92
+ const components = ["verdocs-upload-dialog", "verdocs-button", "verdocs-ok-dialog"];
79
93
  components.forEach(tagName => { switch (tagName) {
80
94
  case "verdocs-upload-dialog":
81
95
  if (!customElements.get(tagName)) {
@@ -83,6 +97,11 @@ function defineCustomElement() {
83
97
  }
84
98
  break;
85
99
  case "verdocs-button":
100
+ if (!customElements.get(tagName)) {
101
+ defineCustomElement$2();
102
+ }
103
+ break;
104
+ case "verdocs-ok-dialog":
86
105
  if (!customElements.get(tagName)) {
87
106
  defineCustomElement$1();
88
107
  }
@@ -62,9 +62,9 @@ const VerdocsView = /*@__PURE__*/ proxyCustomElement(class VerdocsView extends H
62
62
  headerTarget.append(headerEl);
63
63
  }
64
64
  }
65
- handlePageRendered(e) {
66
- const pageInfo = e.detail;
67
- console.log('[VIEW] Page rendered', pageInfo);
65
+ handlePageRendered(_e) {
66
+ // const pageInfo = e.detail as IDocumentPageInfo;
67
+ // console.log('[VIEW] Page rendered', pageInfo);
68
68
  }
69
69
  async handleOptionSelected(e) {
70
70
  var _a, _b;
@@ -180,14 +180,14 @@ var loadModule = (cmpMeta, hostRef, hmrVersionId) => {
180
180
  return import(
181
181
  /* webpackMode: "lazy" */
182
182
  './verdocs-spinner.entry.js').then(processMod, consoleError);
183
- case 'verdocs-ok-dialog':
184
- return import(
185
- /* webpackMode: "lazy" */
186
- './verdocs-ok-dialog.entry.js').then(processMod, consoleError);
187
183
  case 'verdocs-loader':
188
184
  return import(
189
185
  /* webpackMode: "lazy" */
190
186
  './verdocs-loader.entry.js').then(processMod, consoleError);
187
+ case 'verdocs-ok-dialog':
188
+ return import(
189
+ /* webpackMode: "lazy" */
190
+ './verdocs-ok-dialog.entry.js').then(processMod, consoleError);
191
191
  case 'verdocs-checkbox_4':
192
192
  return import(
193
193
  /* webpackMode: "lazy" */
@@ -5,7 +5,7 @@ import { g as globalScripts } from './app-globals-0f993ce5.js';
5
5
  const defineCustomElements = async (win, options) => {
6
6
  if (typeof window === 'undefined') return undefined;
7
7
  await globalScripts();
8
- return bootstrapLazy(JSON.parse("[[\"verdocs-build\",[[0,\"verdocs-build\",{\"endpoint\":[16],\"templateId\":[1537,\"template-id\"],\"step\":[1537],\"templateStore\":[32]},null,{\"templateId\":[\"onTemplateIdChanged\"],\"step\":[\"onStepChanged\"]}]]],[\"verdocs-envelopes-list\",[[0,\"verdocs-envelopes-list\",{\"endpoint\":[16],\"view\":[1537],\"status\":[1537],\"sort\":[1537],\"match\":[1537],\"showPagination\":[4,\"show-pagination\"],\"rowsPerPage\":[2,\"rows-per-page\"],\"selectedPage\":[2,\"selected-page\"],\"count\":[32],\"initiallyLoaded\":[32],\"loading\":[32],\"selectedEnvelopes\":[32],\"envelopes\":[32]},null,{\"view\":[\"handleViewUpdated\"],\"status\":[\"handleStatusUpdated\"],\"sort\":[\"handleSortUpdated\"],\"match\":[\"handleMatchUpdated\"],\"selectedPage\":[\"handlePageUpdated\"]}]]],[\"verdocs-sign\",[[0,\"verdocs-sign\",{\"endpoint\":[1040],\"envelopeId\":[1,\"envelope-id\"],\"roleId\":[1,\"role-id\"],\"inviteCode\":[1,\"invite-code\"],\"headerTargetId\":[1,\"header-target-id\"],\"envelope\":[32],\"roleNames\":[32],\"sortedRecipients\":[32],\"recipient\":[32],\"hasSignature\":[32],\"nextButtonLabel\":[32],\"nextSubmits\":[32],\"errorMessage\":[32],\"focusedField\":[32],\"submitting\":[32],\"submitted\":[32],\"canceled\":[32],\"declined\":[32],\"isDone\":[32],\"showDone\":[32],\"showLoadError\":[32],\"finishLater\":[32],\"showFinishLater\":[32],\"agreed\":[32],\"documentsSingularPlural\":[32],\"kbaStep\":[32],\"showSpinner\":[32]}]]],[\"verdocs-templates-list\",[[0,\"verdocs-templates-list\",{\"endpoint\":[16],\"sharing\":[1537],\"starred\":[1537],\"sort\":[1537],\"name\":[1537],\"allowedActions\":[1040],\"showPagination\":[4,\"show-pagination\"],\"rowsPerPage\":[2,\"rows-per-page\"],\"selectedPage\":[2,\"selected-page\"],\"count\":[32],\"initiallyLoaded\":[32],\"loading\":[32],\"confirmDelete\":[32],\"templates\":[32],\"localNameFilter\":[32]},null,{\"sharing\":[\"handleSharingUpdated\"],\"starred\":[\"handleStarredUpdated\"],\"sort\":[\"handleSortUpdated\"],\"name\":[\"handleNameUpdated\"],\"selectedPage\":[\"handlePageUpdated\"]}]]],[\"verdocs-envelope-sidebar\",[[0,\"verdocs-envelope-sidebar\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"activeTab\":[32],\"panelOpen\":[32],\"showRecipientDialog\":[32],\"showCancelDialog\":[32],\"loading\":[32],\"remindersEnabled\":[32],\"updatingReminders\":[32],\"initialReminder\":[32],\"followupReminders\":[32]}]]],[\"verdocs-auth\",[[0,\"verdocs-auth\",{\"endpoint\":[16],\"visible\":[4],\"logo\":[1],\"displayMode\":[1025,\"display-mode\"],\"org_name\":[32],\"first_name\":[32],\"last_name\":[32],\"email\":[32],\"verificationCode\":[32],\"newPassword\":[32],\"password\":[32],\"confirmpass\":[32],\"submitting\":[32],\"resendDisabled\":[32],\"session\":[32],\"profile\":[32]}]]],[\"verdocs-envelope-recipient-summary\",[[0,\"verdocs-envelope-recipient-summary\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"canSendAnother\":[4,\"can-send-another\"],\"canView\":[4,\"can-view\"],\"canDone\":[4,\"can-done\"],\"isOpen\":[32],\"loading\":[32],\"recipientStatusIcons\":[32],\"containerId\":[32],\"gettingLinks\":[32],\"links\":[32]}]]],[\"verdocs-dialog\",[[4,\"verdocs-dialog\"]]],[\"verdocs-field-payment\",[[0,\"verdocs-field-payment\",{\"templateid\":[1],\"fieldname\":[1],\"disabled\":[4],\"fields\":[16],\"pageNum\":[2,\"page-num\"],\"roleName\":[1,\"role-name\"],\"fieldId\":[1,\"field-id\"],\"recipients\":[8],\"selectedRoleName\":[1,\"selected-role-name\"],\"pdfPages\":[16],\"currentSignature\":[1,\"current-signature\"],\"currentSignatureId\":[1,\"current-signature-id\"],\"currentInitial\":[1,\"current-initial\"],\"currentInitialId\":[1,\"current-initial-id\"],\"focused\":[4],\"signed\":[4],\"xscale\":[2],\"yscale\":[2],\"pagenumber\":[2],\"roleindex\":[2],\"preparedMessage\":[32],\"signatureUrl\":[32],\"showingProperties\":[32],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}]]],[\"verdocs-quick-functions\",[[0,\"verdocs-quick-functions\",{\"endpoint\":[16]}]]],[\"verdocs-search-box\",[[0,\"verdocs-search-box\",{\"endpoint\":[16],\"placeholder\":[1],\"type\":[1],\"query\":[1],\"grabsFocus\":[4,\"grabs-focus\"],\"focusField\":[64]}]]],[\"verdocs-search-tabs\",[[0,\"verdocs-search-tabs\",{\"selected\":[32]}]]],[\"verdocs-table\",[[0,\"verdocs-table\",{\"columns\":[16],\"data\":[16]}]]],[\"verdocs-template-card\",[[0,\"verdocs-template-card\",{\"template\":[16]}]]],[\"verdocs-template-tags\",[[0,\"verdocs-template-tags\",{\"tags\":[16]}]]],[\"verdocs-toggle\",[[0,\"verdocs-toggle\",{\"options\":[16],\"theme\":[1],\"selectedOption\":[32]}]]],[\"verdocs-status-indicator\",[[0,\"verdocs-status-indicator\",{\"size\":[1],\"theme\":[1],\"status\":[1],\"envelope\":[16],\"isOpen\":[32],\"containerId\":[32]}]]],[\"verdocs-template-star\",[[0,\"verdocs-template-star\",{\"endpoint\":[16],\"template\":[1040],\"updating\":[32]}]]],[\"verdocs-envelope-document-page\",[[0,\"verdocs-envelope-document-page\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"documentId\":[1,\"document-id\"],\"pageNumber\":[2,\"page-number\"],\"virtualWidth\":[2,\"virtual-width\"],\"virtualHeight\":[1026,\"virtual-height\"],\"layers\":[16],\"type\":[1],\"containerId\":[32],\"renderedWidth\":[32],\"renderedHeight\":[32],\"naturalWidth\":[32],\"naturalHeight\":[32],\"aspectRatio\":[32],\"skipFirstNotification\":[32],\"pageDisplayUri\":[32]}]]],[\"verdocs-kba-dialog_2\",[[0,\"verdocs-view\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"envelope\":[1040],\"headerTargetId\":[1,\"header-target-id\"],\"canceling\":[32],\"roleNames\":[32],\"showCancelDone\":[32],\"showLoadError\":[32]}],[0,\"verdocs-kba-dialog\",{\"step\":[2],\"steps\":[2],\"helptitle\":[1],\"helptext\":[1],\"mode\":[1],\"label\":[1],\"placeholder\":[1],\"choices\":[16],\"response\":[32]}]]],[\"verdocs-envelope-recipient-link_2\",[[0,\"verdocs-envelope-recipient-link\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"roleName\":[1,\"role-name\"],\"isOpen\":[32],\"loading\":[32],\"gettingLink\":[32],\"link\":[32]}],[0,\"verdocs-switch\",{\"checked\":[1028],\"theme\":[1],\"disabled\":[4]}]]],[\"verdocs-button-panel_2\",[[4,\"verdocs-button-panel\",{\"icon\":[1],\"showPanel\":[64],\"hidePanel\":[64],\"toggle\":[64]}],[4,\"verdocs-tabs\",{\"tabs\":[16],\"selectedTab\":[2,\"selected-tab\"]}]]],[\"verdocs-pagination_2\",[[0,\"verdocs-pagination\",{\"selectedPage\":[1538,\"selected-page\"],\"itemCount\":[2,\"item-count\"],\"perPage\":[2,\"per-page\"]}],[0,\"verdocs-quick-filter\",{\"options\":[16],\"label\":[1],\"value\":[1537],\"placeholder\":[1],\"open\":[32]}]]],[\"verdocs-template-document-page_2\",[[0,\"verdocs-toolbar-icon\",{\"text\":[1],\"icon\":[1],\"placement\":[1],\"containerId\":[32]}],[0,\"verdocs-template-document-page\",{\"endpoint\":[16],\"editable\":[4],\"disabled\":[4],\"done\":[4],\"templateId\":[1,\"template-id\"],\"documentId\":[1,\"document-id\"],\"pageNumber\":[2,\"page-number\"],\"virtualWidth\":[2,\"virtual-width\"],\"virtualHeight\":[1026,\"virtual-height\"],\"layers\":[16],\"containerId\":[32],\"renderedWidth\":[32],\"renderedHeight\":[32],\"naturalWidth\":[32],\"naturalHeight\":[32],\"aspectRatio\":[32],\"skipFirstNotification\":[32],\"pageDisplayUri\":[32],\"xScale\":[32],\"yScale\":[32]}]]],[\"verdocs-contact-picker_2\",[[0,\"verdocs-contact-picker\",{\"endpoint\":[16],\"templateRole\":[16],\"contactSuggestions\":[16],\"first_name\":[32],\"last_name\":[32],\"email\":[32],\"phone\":[32],\"zip\":[32],\"message\":[32],\"showSuggestions\":[32],\"showMessage\":[32],\"delegator\":[32],\"showKba\":[32],\"kba_method\":[32],\"kba_pin\":[32],\"nameFieldId\":[32],\"firstNameFieldId\":[32],\"lastNameFieldId\":[32],\"emailFieldId\":[32],\"phoneFieldId\":[32]}],[0,\"verdocs-toggle-button\",{\"active\":[4],\"icon\":[1],\"label\":[1],\"size\":[1],\"_active\":[32]}]]],[\"verdocs-file-chooser_2\",[[0,\"verdocs-file-chooser\",{\"endpoint\":[16],\"file\":[32]}],[0,\"verdocs-progress-bar\",{\"label\":[1],\"showPercent\":[4,\"show-percent\"],\"percent\":[2]}]]],[\"verdocs-spinner\",[[0,\"verdocs-spinner\",{\"size\":[2],\"mode\":[1]}]]],[\"verdocs-radio-button_3\",[[0,\"verdocs-template-role-properties\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"roleName\":[1,\"role-name\"],\"sender\":[1],\"dirty\":[32],\"saving\":[32],\"name\":[32],\"type\":[32],\"first_name\":[32],\"last_name\":[32],\"email\":[32],\"phone\":[32],\"delegator\":[32]}],[0,\"verdocs-template-sender\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"sender\":[1],\"saving\":[32]}],[0,\"verdocs-radio-button\",{\"checked\":[4],\"name\":[1],\"value\":[1],\"disabled\":[4]}]]],[\"verdocs-ok-dialog\",[[0,\"verdocs-ok-dialog\",{\"heading\":[1],\"message\":[1],\"buttonLabel\":[1,\"button-label\"],\"showCancel\":[4,\"show-cancel\"],\"closed\":[32]}]]],[\"verdocs-loader\",[[0,\"verdocs-loader\"]]],[\"verdocs-organization-card_2\",[[0,\"verdocs-organization-card\",{\"organization\":[16],\"hovered\":[32]},[[1,\"mouseover\",\"onMouseOver\"],[1,\"mouseout\",\"onMouseOut\"]]],[4,\"verdocs-portal\",{\"anchor\":[1],\"voffset\":[2]},[[11,\"scroll\",\"handleScroll\"],[9,\"resize\",\"handleResize\"],[4,\"click\",\"handleClick\"]]]]],[\"verdocs-dropdown\",[[0,\"verdocs-dropdown\",{\"options\":[16],\"containerId\":[32],\"showPicker\":[32]}]]],[\"verdocs-button_3\",[[0,\"verdocs-text-input\",{\"value\":[1537],\"label\":[1],\"placeholder\":[1],\"autocomplete\":[1],\"helpText\":[1,\"help-text\"],\"clearable\":[4],\"copyable\":[4],\"type\":[1],\"disabled\":[4],\"required\":[4],\"showingPw\":[32]}],[0,\"verdocs-help-icon\",{\"text\":[1],\"icon\":[1],\"containerId\":[32]}],[0,\"verdocs-button\",{\"label\":[1],\"startIcon\":[1,\"start-icon\"],\"endIcon\":[1,\"end-icon\"],\"size\":[1],\"type\":[1],\"variant\":[1],\"disabled\":[4]}]]],[\"verdocs-checkbox_4\",[[0,\"verdocs-template-field-properties\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"fieldName\":[1025,\"field-name\"],\"helpText\":[1,\"help-text\"],\"dirty\":[32],\"loading\":[32],\"label\":[32],\"type\":[32],\"name\":[32],\"required\":[32],\"roleName\":[32],\"group\":[32],\"fieldType\":[32],\"options\":[32],\"placeholder\":[32],\"defaultValue\":[32],\"showingHelp\":[32]}],[0,\"verdocs-select-input\",{\"value\":[1],\"label\":[1],\"options\":[16],\"disabled\":[4]}],[0,\"verdocs-checkbox\",{\"checked\":[4],\"name\":[1],\"label\":[1],\"value\":[1],\"theme\":[1],\"disabled\":[4]}],[0,\"verdocs-component-error\",{\"message\":[1]}]]],[\"verdocs-field-attachment_13\",[[0,\"verdocs-field-attachment\",{\"endpoint\":[16],\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"dialogOpen\":[32],\"selectedFile\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-initial\",{\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"initials\":[513],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"tempInitials\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-signature\",{\"templateid\":[513],\"fieldname\":[513],\"name\":[513],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"tempSignature\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-checkbox\",{\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"done\":[516],\"editable\":[516],\"moveable\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-date\",{\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"field\":[16],\"containerId\":[32],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-dropdown\",{\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-radio\",{\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"done\":[516],\"editable\":[516],\"moveable\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-textarea\",{\"endpoint\":[16],\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-textbox\",{\"endpoint\":[16],\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"multiline\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-timestamp\",{\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[2],\"showingProperties\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-initial-dialog\",{\"initials\":[1],\"fontLoaded\":[32],\"enteredInitials\":[32],\"mode\":[32]}],[0,\"verdocs-signature-dialog\",{\"name\":[1],\"fontLoaded\":[32],\"enteredName\":[32],\"mode\":[32]}],[0,\"verdocs-upload-dialog\",{\"existingFile\":[1032,\"existing-file\"],\"draggingOver\":[32],\"selectedFiles\":[32]}]]],[\"verdocs-preview_9\",[[0,\"verdocs-template-fields\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"toolbarTargetId\":[1,\"toolbar-target-id\"],\"placing\":[32],\"showMustSelectRole\":[32],\"selectedRoleName\":[32],\"loading\":[32]},[[4,\"keydown\",\"handleKeyDown\"]]],[0,\"verdocs-preview\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"loading\":[32]},null,{\"templateId\":[\"onTemplateIdChanged\"]}],[0,\"verdocs-template-roles\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"showingRoleDialog\":[32],\"showingSenderDialog\":[32],\"sender\":[32],\"loading\":[32]}],[0,\"verdocs-send\",{\"endpoint\":[16],\"templateId\":[513,\"template-id\"],\"environment\":[1],\"containerId\":[32],\"showPickerForId\":[32],\"sessionContacts\":[32],\"sending\":[32],\"rolesCompleted\":[32],\"templateStore\":[32],\"roleStore\":[32],\"reset\":[64]},null,{\"templateId\":[\"onTemplateIdChanged\"]}],[0,\"verdocs-template-attachments\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"uploading\":[32],\"progressLabel\":[32],\"progressPercent\":[32],\"showDeleteError\":[32],\"confirmDeleteDocument\":[32],\"store\":[32]}],[0,\"verdocs-template-name\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"name\":[32],\"dirty\":[32]}],[0,\"verdocs-template-create\",{\"endpoint\":[16],\"file\":[32],\"creating\":[32],\"progressLabel\":[32],\"progressPercent\":[32]}],[0,\"verdocs-template-build-tabs\",{\"endpoint\":[16],\"templateId\":[1537,\"template-id\"],\"step\":[1537],\"templateStore\":[32]},null,{\"templateId\":[\"onTemplateIdChanged\"],\"step\":[\"onStepChanged\"]}],[0,\"verdocs-template-visibility\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"dirty\":[32],\"personal\":[32],\"public\":[32]}]]]]"), options);
8
+ return bootstrapLazy(JSON.parse("[[\"verdocs-build\",[[0,\"verdocs-build\",{\"endpoint\":[16],\"templateId\":[1537,\"template-id\"],\"step\":[1537],\"templateStore\":[32]},null,{\"templateId\":[\"onTemplateIdChanged\"],\"step\":[\"onStepChanged\"]}]]],[\"verdocs-envelopes-list\",[[0,\"verdocs-envelopes-list\",{\"endpoint\":[16],\"view\":[1537],\"status\":[1537],\"sort\":[1537],\"match\":[1537],\"showPagination\":[4,\"show-pagination\"],\"rowsPerPage\":[2,\"rows-per-page\"],\"selectedPage\":[2,\"selected-page\"],\"count\":[32],\"initiallyLoaded\":[32],\"loading\":[32],\"selectedEnvelopes\":[32],\"envelopes\":[32]},null,{\"view\":[\"handleViewUpdated\"],\"status\":[\"handleStatusUpdated\"],\"sort\":[\"handleSortUpdated\"],\"match\":[\"handleMatchUpdated\"],\"selectedPage\":[\"handlePageUpdated\"]}]]],[\"verdocs-sign\",[[0,\"verdocs-sign\",{\"endpoint\":[1040],\"envelopeId\":[1,\"envelope-id\"],\"roleId\":[1,\"role-id\"],\"inviteCode\":[1,\"invite-code\"],\"headerTargetId\":[1,\"header-target-id\"],\"envelope\":[32],\"roleNames\":[32],\"sortedRecipients\":[32],\"recipient\":[32],\"hasSignature\":[32],\"nextButtonLabel\":[32],\"nextSubmits\":[32],\"errorMessage\":[32],\"focusedField\":[32],\"submitting\":[32],\"submitted\":[32],\"canceled\":[32],\"declined\":[32],\"isDone\":[32],\"showDone\":[32],\"showCanceled\":[32],\"showDeclined\":[32],\"showLoadError\":[32],\"finishLater\":[32],\"showFinishLater\":[32],\"agreed\":[32],\"documentsSingularPlural\":[32],\"kbaStep\":[32],\"showSpinner\":[32]}]]],[\"verdocs-templates-list\",[[0,\"verdocs-templates-list\",{\"endpoint\":[16],\"sharing\":[1537],\"starred\":[1537],\"sort\":[1537],\"name\":[1537],\"allowedActions\":[1040],\"showPagination\":[4,\"show-pagination\"],\"rowsPerPage\":[2,\"rows-per-page\"],\"selectedPage\":[2,\"selected-page\"],\"count\":[32],\"initiallyLoaded\":[32],\"loading\":[32],\"confirmDelete\":[32],\"templates\":[32],\"localNameFilter\":[32]},null,{\"sharing\":[\"handleSharingUpdated\"],\"starred\":[\"handleStarredUpdated\"],\"sort\":[\"handleSortUpdated\"],\"name\":[\"handleNameUpdated\"],\"selectedPage\":[\"handlePageUpdated\"]}]]],[\"verdocs-envelope-sidebar\",[[0,\"verdocs-envelope-sidebar\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"activeTab\":[32],\"panelOpen\":[32],\"showRecipientDialog\":[32],\"showCancelDialog\":[32],\"loading\":[32],\"remindersEnabled\":[32],\"updatingReminders\":[32],\"initialReminder\":[32],\"followupReminders\":[32]}]]],[\"verdocs-auth\",[[0,\"verdocs-auth\",{\"endpoint\":[16],\"visible\":[4],\"logo\":[1],\"displayMode\":[1025,\"display-mode\"],\"org_name\":[32],\"first_name\":[32],\"last_name\":[32],\"email\":[32],\"verificationCode\":[32],\"newPassword\":[32],\"password\":[32],\"confirmpass\":[32],\"submitting\":[32],\"resendDisabled\":[32],\"session\":[32],\"profile\":[32]}]]],[\"verdocs-envelope-recipient-summary\",[[0,\"verdocs-envelope-recipient-summary\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"canSendAnother\":[4,\"can-send-another\"],\"canView\":[4,\"can-view\"],\"canDone\":[4,\"can-done\"],\"isOpen\":[32],\"loading\":[32],\"recipientStatusIcons\":[32],\"containerId\":[32],\"gettingLinks\":[32],\"links\":[32]}]]],[\"verdocs-dialog\",[[4,\"verdocs-dialog\"]]],[\"verdocs-field-payment\",[[0,\"verdocs-field-payment\",{\"templateid\":[1],\"fieldname\":[1],\"disabled\":[4],\"fields\":[16],\"pageNum\":[2,\"page-num\"],\"roleName\":[1,\"role-name\"],\"fieldId\":[1,\"field-id\"],\"recipients\":[8],\"selectedRoleName\":[1,\"selected-role-name\"],\"pdfPages\":[16],\"currentSignature\":[1,\"current-signature\"],\"currentSignatureId\":[1,\"current-signature-id\"],\"currentInitial\":[1,\"current-initial\"],\"currentInitialId\":[1,\"current-initial-id\"],\"focused\":[4],\"signed\":[4],\"xscale\":[2],\"yscale\":[2],\"pagenumber\":[2],\"roleindex\":[2],\"preparedMessage\":[32],\"signatureUrl\":[32],\"showingProperties\":[32],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}]]],[\"verdocs-quick-functions\",[[0,\"verdocs-quick-functions\",{\"endpoint\":[16]}]]],[\"verdocs-search-box\",[[0,\"verdocs-search-box\",{\"endpoint\":[16],\"placeholder\":[1],\"type\":[1],\"query\":[1],\"grabsFocus\":[4,\"grabs-focus\"],\"focusField\":[64]}]]],[\"verdocs-search-tabs\",[[0,\"verdocs-search-tabs\",{\"selected\":[32]}]]],[\"verdocs-table\",[[0,\"verdocs-table\",{\"columns\":[16],\"data\":[16]}]]],[\"verdocs-template-card\",[[0,\"verdocs-template-card\",{\"template\":[16]}]]],[\"verdocs-template-tags\",[[0,\"verdocs-template-tags\",{\"tags\":[16]}]]],[\"verdocs-toggle\",[[0,\"verdocs-toggle\",{\"options\":[16],\"theme\":[1],\"selectedOption\":[32]}]]],[\"verdocs-status-indicator\",[[0,\"verdocs-status-indicator\",{\"size\":[1],\"theme\":[1],\"status\":[1],\"envelope\":[16],\"isOpen\":[32],\"containerId\":[32]}]]],[\"verdocs-template-star\",[[0,\"verdocs-template-star\",{\"endpoint\":[16],\"template\":[1040],\"updating\":[32]}]]],[\"verdocs-envelope-document-page\",[[0,\"verdocs-envelope-document-page\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"documentId\":[1,\"document-id\"],\"pageNumber\":[2,\"page-number\"],\"virtualWidth\":[2,\"virtual-width\"],\"virtualHeight\":[1026,\"virtual-height\"],\"layers\":[16],\"type\":[1],\"containerId\":[32],\"renderedWidth\":[32],\"renderedHeight\":[32],\"naturalWidth\":[32],\"naturalHeight\":[32],\"aspectRatio\":[32],\"skipFirstNotification\":[32],\"pageDisplayUri\":[32]}]]],[\"verdocs-kba-dialog_2\",[[0,\"verdocs-view\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"envelope\":[1040],\"headerTargetId\":[1,\"header-target-id\"],\"canceling\":[32],\"roleNames\":[32],\"showCancelDone\":[32],\"showLoadError\":[32]}],[0,\"verdocs-kba-dialog\",{\"step\":[2],\"steps\":[2],\"helptitle\":[1],\"helptext\":[1],\"mode\":[1],\"label\":[1],\"placeholder\":[1],\"choices\":[16],\"response\":[32]}]]],[\"verdocs-envelope-recipient-link_2\",[[0,\"verdocs-envelope-recipient-link\",{\"endpoint\":[16],\"envelopeId\":[1,\"envelope-id\"],\"roleName\":[1,\"role-name\"],\"isOpen\":[32],\"loading\":[32],\"gettingLink\":[32],\"link\":[32]}],[0,\"verdocs-switch\",{\"checked\":[1028],\"theme\":[1],\"disabled\":[4]}]]],[\"verdocs-button-panel_2\",[[4,\"verdocs-button-panel\",{\"icon\":[1],\"showPanel\":[64],\"hidePanel\":[64],\"toggle\":[64]}],[4,\"verdocs-tabs\",{\"tabs\":[16],\"selectedTab\":[2,\"selected-tab\"]}]]],[\"verdocs-pagination_2\",[[0,\"verdocs-pagination\",{\"selectedPage\":[1538,\"selected-page\"],\"itemCount\":[2,\"item-count\"],\"perPage\":[2,\"per-page\"]}],[0,\"verdocs-quick-filter\",{\"options\":[16],\"label\":[1],\"value\":[1537],\"placeholder\":[1],\"open\":[32]}]]],[\"verdocs-template-document-page_2\",[[0,\"verdocs-toolbar-icon\",{\"text\":[1],\"icon\":[1],\"placement\":[1],\"containerId\":[32]}],[0,\"verdocs-template-document-page\",{\"endpoint\":[16],\"editable\":[4],\"disabled\":[4],\"done\":[4],\"templateId\":[1,\"template-id\"],\"documentId\":[1,\"document-id\"],\"pageNumber\":[2,\"page-number\"],\"virtualWidth\":[2,\"virtual-width\"],\"virtualHeight\":[1026,\"virtual-height\"],\"layers\":[16],\"containerId\":[32],\"renderedWidth\":[32],\"renderedHeight\":[32],\"naturalWidth\":[32],\"naturalHeight\":[32],\"aspectRatio\":[32],\"skipFirstNotification\":[32],\"pageDisplayUri\":[32],\"xScale\":[32],\"yScale\":[32]}]]],[\"verdocs-contact-picker_2\",[[0,\"verdocs-contact-picker\",{\"endpoint\":[16],\"templateRole\":[16],\"contactSuggestions\":[16],\"first_name\":[32],\"last_name\":[32],\"email\":[32],\"phone\":[32],\"zip\":[32],\"message\":[32],\"showSuggestions\":[32],\"showMessage\":[32],\"delegator\":[32],\"showKba\":[32],\"kba_method\":[32],\"kba_pin\":[32],\"nameFieldId\":[32],\"firstNameFieldId\":[32],\"lastNameFieldId\":[32],\"emailFieldId\":[32],\"phoneFieldId\":[32]}],[0,\"verdocs-toggle-button\",{\"active\":[4],\"icon\":[1],\"label\":[1],\"size\":[1],\"_active\":[32]}]]],[\"verdocs-file-chooser_2\",[[0,\"verdocs-file-chooser\",{\"endpoint\":[16],\"file\":[32]}],[0,\"verdocs-progress-bar\",{\"label\":[1],\"showPercent\":[4,\"show-percent\"],\"percent\":[2]}]]],[\"verdocs-spinner\",[[0,\"verdocs-spinner\",{\"size\":[2],\"mode\":[1]}]]],[\"verdocs-radio-button_3\",[[0,\"verdocs-template-role-properties\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"roleName\":[1,\"role-name\"],\"sender\":[1],\"dirty\":[32],\"saving\":[32],\"name\":[32],\"type\":[32],\"first_name\":[32],\"last_name\":[32],\"email\":[32],\"phone\":[32],\"delegator\":[32]}],[0,\"verdocs-template-sender\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"sender\":[1],\"saving\":[32]}],[0,\"verdocs-radio-button\",{\"checked\":[4],\"name\":[1],\"value\":[1],\"disabled\":[4]}]]],[\"verdocs-loader\",[[0,\"verdocs-loader\"]]],[\"verdocs-ok-dialog\",[[0,\"verdocs-ok-dialog\",{\"heading\":[1],\"message\":[1],\"buttonLabel\":[1,\"button-label\"],\"showCancel\":[4,\"show-cancel\"],\"closed\":[32]}]]],[\"verdocs-organization-card_2\",[[0,\"verdocs-organization-card\",{\"organization\":[16],\"hovered\":[32]},[[1,\"mouseover\",\"onMouseOver\"],[1,\"mouseout\",\"onMouseOut\"]]],[4,\"verdocs-portal\",{\"anchor\":[1],\"voffset\":[2]},[[11,\"scroll\",\"handleScroll\"],[9,\"resize\",\"handleResize\"],[4,\"click\",\"handleClick\"]]]]],[\"verdocs-dropdown\",[[0,\"verdocs-dropdown\",{\"options\":[16],\"containerId\":[32],\"showPicker\":[32]}]]],[\"verdocs-button_3\",[[0,\"verdocs-text-input\",{\"value\":[1537],\"label\":[1],\"placeholder\":[1],\"autocomplete\":[1],\"helpText\":[1,\"help-text\"],\"clearable\":[4],\"copyable\":[4],\"type\":[1],\"disabled\":[4],\"required\":[4],\"showingPw\":[32]}],[0,\"verdocs-help-icon\",{\"text\":[1],\"icon\":[1],\"containerId\":[32]}],[0,\"verdocs-button\",{\"label\":[1],\"startIcon\":[1,\"start-icon\"],\"endIcon\":[1,\"end-icon\"],\"size\":[1],\"type\":[1],\"variant\":[1],\"disabled\":[4]}]]],[\"verdocs-checkbox_4\",[[0,\"verdocs-template-field-properties\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"fieldName\":[1025,\"field-name\"],\"helpText\":[1,\"help-text\"],\"dirty\":[32],\"loading\":[32],\"label\":[32],\"type\":[32],\"name\":[32],\"required\":[32],\"roleName\":[32],\"group\":[32],\"fieldType\":[32],\"options\":[32],\"placeholder\":[32],\"defaultValue\":[32],\"showingHelp\":[32]}],[0,\"verdocs-select-input\",{\"value\":[1],\"label\":[1],\"options\":[16],\"disabled\":[4]}],[0,\"verdocs-checkbox\",{\"checked\":[4],\"name\":[1],\"label\":[1],\"value\":[1],\"theme\":[1],\"disabled\":[4]}],[0,\"verdocs-component-error\",{\"message\":[1]}]]],[\"verdocs-field-attachment_13\",[[0,\"verdocs-field-attachment\",{\"endpoint\":[16],\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"dialogOpen\":[32],\"selectedFile\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-initial\",{\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"initials\":[513],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"tempInitials\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-signature\",{\"templateid\":[513],\"fieldname\":[513],\"name\":[513],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"tempSignature\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-checkbox\",{\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"done\":[516],\"editable\":[516],\"moveable\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-date\",{\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"field\":[16],\"containerId\":[32],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-dropdown\",{\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-radio\",{\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"done\":[516],\"editable\":[516],\"moveable\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-textarea\",{\"endpoint\":[16],\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-textbox\",{\"endpoint\":[16],\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"multiline\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[514],\"showingProperties\":[32],\"focused\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-field-timestamp\",{\"templateid\":[513],\"fieldname\":[513],\"disabled\":[516],\"editable\":[516],\"moveable\":[516],\"done\":[516],\"xscale\":[514],\"yscale\":[514],\"pagenumber\":[2],\"showingProperties\":[32],\"focusField\":[64],\"showSettingsPanel\":[64],\"hideSettingsPanel\":[64]}],[0,\"verdocs-initial-dialog\",{\"initials\":[1],\"fontLoaded\":[32],\"enteredInitials\":[32],\"mode\":[32]}],[0,\"verdocs-signature-dialog\",{\"name\":[1],\"fontLoaded\":[32],\"enteredName\":[32],\"mode\":[32]}],[0,\"verdocs-upload-dialog\",{\"existingFile\":[1032,\"existing-file\"],\"draggingOver\":[32],\"confirmDelete\":[32],\"selectedFiles\":[32]}]]],[\"verdocs-preview_9\",[[0,\"verdocs-template-fields\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"toolbarTargetId\":[1,\"toolbar-target-id\"],\"placing\":[32],\"showMustSelectRole\":[32],\"selectedRoleName\":[32],\"loading\":[32]},[[4,\"keydown\",\"handleKeyDown\"]]],[0,\"verdocs-preview\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"loading\":[32]},null,{\"templateId\":[\"onTemplateIdChanged\"]}],[0,\"verdocs-template-roles\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"showingRoleDialog\":[32],\"showingSenderDialog\":[32],\"sender\":[32],\"loading\":[32]}],[0,\"verdocs-send\",{\"endpoint\":[16],\"templateId\":[513,\"template-id\"],\"environment\":[1],\"containerId\":[32],\"showPickerForId\":[32],\"sessionContacts\":[32],\"sending\":[32],\"rolesCompleted\":[32],\"templateStore\":[32],\"roleStore\":[32],\"reset\":[64]},null,{\"templateId\":[\"onTemplateIdChanged\"]}],[0,\"verdocs-template-attachments\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"uploading\":[32],\"progressLabel\":[32],\"progressPercent\":[32],\"showDeleteError\":[32],\"confirmDeleteDocument\":[32],\"store\":[32]}],[0,\"verdocs-template-name\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"name\":[32],\"dirty\":[32]}],[0,\"verdocs-template-create\",{\"endpoint\":[16],\"file\":[32],\"creating\":[32],\"progressLabel\":[32],\"progressPercent\":[32]}],[0,\"verdocs-template-build-tabs\",{\"endpoint\":[16],\"templateId\":[1537,\"template-id\"],\"step\":[1537],\"templateStore\":[32]},null,{\"templateId\":[\"onTemplateIdChanged\"],\"step\":[\"onStepChanged\"]}],[0,\"verdocs-template-visibility\",{\"endpoint\":[16],\"templateId\":[1,\"template-id\"],\"dirty\":[32],\"personal\":[32],\"public\":[32]}]]]]"), options);
9
9
  };
10
10
 
11
11
  export { defineCustomElements };
@@ -258,7 +258,7 @@ const saveEnvelopesAsZip = async (endpoint, envelopes) => {
258
258
  const subFolder = envelopes.length > 0 ? zip.folder(`${envelope.id} - ${envelope.name} - ${date}`) : null;
259
259
  for await (let document of envelope.documents) {
260
260
  // TODO: When attachments are added to envelopes, add a field that reflects the full, original filename (including extension)
261
- const documentFileName = document.type === 'certificate' ? `${envelope.name}_certificate.pdf` : `${document.name}.pdf`;
261
+ const documentFileName = document.type === 'certificate' ? `${envelope.name}_certificate.pdf` : `${document.name.replace('.pdf', '')}.pdf`;
262
262
  const data = await getEnvelopeFile(endpoint, envelope.id, document.id);
263
263
  if (subFolder) {
264
264
  subFolder.file(documentFileName, data, { compression: 'DEFLATE' });
@@ -2,7 +2,7 @@ import { r as registerInstance, h, H as Host, c as createEvent, g as getElement
2
2
  import { c as createPopper } from './popper-0fbeff6d.js';
3
3
  import { V as VerdocsToast } from './Toast-c4843828.js';
4
4
 
5
- const verdocsButtonCss = "@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-button button{font-family:\"Inter\", -apple-system, \"Segoe UI\", \"Roboto\", \"Helvetica Neue\", sans-serif;text-transform:uppercase;-ms-flex-pack:center;justify-content:center;display:-ms-inline-flexbox;display:inline-flex;-ms-flex-align:center;align-items:center;font-weight:700;cursor:pointer;margin:0}verdocs-button button:disabled{cursor:inherit;pointer-events:none}verdocs-button button .icon{margin:0 12px}verdocs-button button .icon svg{fill:#ffffff;display:block}verdocs-button button .button-label{padding:0 12px}verdocs-button button.small{height:34px;font-size:13px}verdocs-button button.small .icon{margin:0 4px}verdocs-button button.small .icon svg{margin:2px 0 0 0;height:20px}verdocs-button button.small .button-label{padding:0 4px}verdocs-button button.normal{height:44px;font-size:14px}verdocs-button button.normal .icon.start{margin:0 4px 0 8px}verdocs-button button.normal .icon.end{margin:0 8px 0 4px}verdocs-button button.normal .icon svg{margin:2px 0 0 0;height:22px}verdocs-button button.normal .button-label{padding:0 10px}verdocs-button button.medium{height:52px;font-size:16px}verdocs-button button.medium .icon.start{margin:0 0 0 18px}verdocs-button button.medium .icon.end{margin:0 18px 0 0}verdocs-button button.medium .icon svg{margin:2px 0 0 0;height:26px}verdocs-button button.medium .button-label{padding:0 20px}verdocs-button button.large{height:60px;font-size:20px}verdocs-button button.large .icon.start{margin:0 0 0 24px}verdocs-button button.large .icon.end{margin:0 24px 0 0}verdocs-button button.large .icon svg{margin:2px 0 0 0;height:32px}verdocs-button button.large .button-label{padding:0 34px}verdocs-button button.standard{background:#55bc81;border-radius:4px;outline:none;border:none;color:white}verdocs-button button.standard:disabled{background-color:#999999;cursor:default}verdocs-button button.standard:active:not([disabled]){-webkit-filter:brightness(110%);filter:brightness(110%)}verdocs-button button.text{color:#4c56cb;background:transparent;font-weight:500;padding:0 4px;outline:none;border:none}verdocs-button button.text:disabled{color:#999999}verdocs-button button.text:active:not([disabled]){-webkit-filter:brightness(130%);filter:brightness(130%)}verdocs-button button.text .icon svg{fill:#4c56cb}verdocs-button button.outline{border:1px solid #4c56cb;color:#4c56cb;outline:none;background:transparent;border-radius:4px;padding:0 20px}verdocs-button button.outline:disabled{color:#999999;border:1px solid #999999}verdocs-button button.outline:active{background:#4c56cb;color:white}verdocs-button button.outline .icon svg{fill:#4c56cb}";
5
+ const verdocsButtonCss = "@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-button button{font-family:\"Inter\", -apple-system, \"Segoe UI\", \"Roboto\", \"Helvetica Neue\", sans-serif;text-transform:uppercase;-ms-flex-pack:center;justify-content:center;display:-ms-inline-flexbox;display:inline-flex;-ms-flex-align:center;align-items:center;font-weight:700;cursor:pointer;margin:0}verdocs-button button:disabled{cursor:inherit;pointer-events:none}verdocs-button button .icon{margin:0 12px}verdocs-button button .icon svg{fill:#ffffff;display:block}verdocs-button button .button-label{padding:0 12px}verdocs-button button.xsmall{height:26px;font-size:12px}verdocs-button button.xsmall .icon{margin:0 3px}verdocs-button button.xsmall .icon svg{margin:2px 0 0 0;height:18px}verdocs-button button.xsmall .button-label{padding:0 4px}verdocs-button button.small{height:34px;font-size:13px}verdocs-button button.small .icon{margin:0 4px}verdocs-button button.small .icon svg{margin:2px 0 0 0;height:20px}verdocs-button button.small .button-label{padding:0 4px}verdocs-button button.normal{height:44px;font-size:14px}verdocs-button button.normal .icon.start{margin:0 4px 0 8px}verdocs-button button.normal .icon.end{margin:0 8px 0 4px}verdocs-button button.normal .icon svg{margin:2px 0 0 0;height:22px}verdocs-button button.normal .button-label{padding:0 10px}verdocs-button button.medium{height:52px;font-size:16px}verdocs-button button.medium .icon.start{margin:0 0 0 18px}verdocs-button button.medium .icon.end{margin:0 18px 0 0}verdocs-button button.medium .icon svg{margin:2px 0 0 0;height:26px}verdocs-button button.medium .button-label{padding:0 20px}verdocs-button button.large{height:60px;font-size:20px}verdocs-button button.large .icon.start{margin:0 0 0 24px}verdocs-button button.large .icon.end{margin:0 24px 0 0}verdocs-button button.large .icon svg{margin:2px 0 0 0;height:32px}verdocs-button button.large .button-label{padding:0 34px}verdocs-button button.standard{background:#55bc81;border-radius:4px;outline:none;border:none;color:white}verdocs-button button.standard:disabled{background-color:#999999;cursor:default}verdocs-button button.standard:active:not([disabled]){-webkit-filter:brightness(110%);filter:brightness(110%)}verdocs-button button.text{color:#4c56cb;background:transparent;font-weight:500;padding:0 4px;outline:none;border:none}verdocs-button button.text:disabled{color:#999999}verdocs-button button.text:active:not([disabled]){-webkit-filter:brightness(130%);filter:brightness(130%)}verdocs-button button.text .icon svg{fill:#4c56cb}verdocs-button button.outline{border:1px solid #4c56cb;color:#4c56cb;outline:none;background:transparent;border-radius:4px;padding:0 20px}verdocs-button button.outline:disabled{color:#999999;border:1px solid #999999}verdocs-button button.outline:active{background:#4c56cb;color:white}verdocs-button button.outline .icon svg{fill:#4c56cb}";
6
6
  const VerdocsButtonStyle0 = verdocsButtonCss;
7
7
 
8
8
  const VerdocsButton = class {
@@ -17,7 +17,7 @@ const VerdocsButton = class {
17
17
  this.disabled = false;
18
18
  }
19
19
  render() {
20
- return (h("button", { key: '6f9a370981774fcdeba9668fdaa1afc665084232', disabled: this.disabled, type: this.type, class: `${this.variant} ${this.size} ${this.type}` }, this.startIcon ? h("span", { class: "icon start", innerHTML: this.startIcon }) : null, h("span", { key: '78222704eeb942766fcc62b1587bb7a61137bed7', class: "button-label" }, this.label), this.endIcon ? h("span", { class: "icon end", innerHTML: this.endIcon }) : null));
20
+ return (h("button", { key: 'e9771fa14f70fd9f3ea7d2f643a46bdcc5a3b1e8', disabled: this.disabled, type: this.type, class: `${this.variant} ${this.size} ${this.type}` }, this.startIcon ? h("span", { class: "icon start", innerHTML: this.startIcon }) : null, h("span", { key: 'ba98cd4f1c26cbfafb63314fe139a8dedfcca6bf', class: "button-label" }, this.label), this.endIcon ? h("span", { class: "icon end", innerHTML: this.endIcon }) : null));
21
21
  }
22
22
  };
23
23
  VerdocsButton.style = VerdocsButtonStyle0;
@@ -1,6 +1,6 @@
1
1
  import { r as registerInstance, c as createEvent, h, F as Fragment, H as Host } from './index-a68c7262.js';
2
2
  import { VerdocsEndpoint, formatFullName } from '@verdocs/js-sdk';
3
- import { f as convertToE164 } from './utils-8f3ace81.js';
3
+ import { f as convertToE164 } from './utils-6ecd6558.js';
4
4
  import './_commonjsHelpers-bdec4bbd.js';
5
5
  import './Types-95d86a44.js';
6
6
  import './format-b8602175.js';
@@ -1,6 +1,6 @@
1
1
  import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-a68c7262.js';
2
2
  import { VerdocsEndpoint, getEnvelopeDocumentPageDisplayUri } from '@verdocs/js-sdk';
3
- import { t as throttle } from './utils-8f3ace81.js';
3
+ import { t as throttle } from './utils-6ecd6558.js';
4
4
  import './_commonjsHelpers-bdec4bbd.js';
5
5
  import './Types-95d86a44.js';
6
6
  import './format-b8602175.js';
@@ -77,7 +77,7 @@ const VerdocsEnvelopeDocumentPage = class {
77
77
  }
78
78
  render() {
79
79
  const height = `${this.renderedHeight}px`;
80
- return (h(Host, { key: 'd0b33866715373307c93aa63a2d669180d137c31', id: `${this.containerId}`, style: { height, flex: `0 0 ${height}` } }, this.layers.map(layer => layer.type === 'div' ? (h("div", { class: "verdocs-envelope-document-page-layer", id: `${this.containerId}-${layer.name}`, style: { height } })) : this.pageDisplayUri ? (h("img", { class: "verdocs-envelope-document-page-layer img", id: `${this.containerId}-${layer.name}`, src: this.pageDisplayUri, alt: `Page ${this.pageNumber}`, "aria-hidden": true, loading: "lazy", onLoad: (e) => {
80
+ return (h(Host, { key: 'cca4f6b0c00556a1662ee175292d59b249b17604', id: `${this.containerId}`, style: { height, flex: `0 0 ${height}` } }, this.layers.map(layer => layer.type === 'div' ? (h("div", { class: "verdocs-envelope-document-page-layer", id: `${this.containerId}-${layer.name}`, style: { height } })) : this.pageDisplayUri ? (h("img", { class: "verdocs-envelope-document-page-layer img", id: `${this.containerId}-${layer.name}`, src: this.pageDisplayUri, alt: `Page ${this.pageNumber}`, "aria-hidden": true, loading: "lazy", onLoad: (e) => {
81
81
  // Note that all we really care about is the aspect ratio. We track the natural Width and Height but they aren't really that
82
82
  // useful as individual values. The image will already have been scaled down to fit a DIV for display (100%, auto height).
83
83
  // Builder places fields offset into the rendered display area, not the original document's dimensions. So its X/Y values
@@ -125,7 +125,7 @@ const VerdocsEnvelopeSidebar = class {
125
125
  }
126
126
  (_a = this.envelopeUpdated) === null || _a === void 0 ? void 0 : _a.emit({ endpoint: this.endpoint, envelope: (_b = this.store) === null || _b === void 0 ? void 0 : _b.state, event: id });
127
127
  }
128
- cancelEnvelope() {
128
+ handleCancelEnvelope() {
129
129
  this.loading = true;
130
130
  cancelEnvelope(this.endpoint, this.envelopeId)
131
131
  .then(async (r) => {
@@ -255,6 +255,8 @@ const VerdocsEnvelopeSidebar = class {
255
255
  case 'completed':
256
256
  entries.push({ icon: 'done_all', message: `Envelope was completed.`, date: new Date(history.created_at) });
257
257
  break;
258
+ // TODO: Final answer?
259
+ case 'envelope:canceled':
258
260
  case 'envelope_canceled':
259
261
  case 'canceled':
260
262
  case 'owner:canceled':
@@ -334,7 +336,7 @@ const VerdocsEnvelopeSidebar = class {
334
336
  this.handleSetReminders(this.initialReminder, this.followupReminders);
335
337
  } })), h("div", { class: "form-row" }, h("div", { class: "form-label" }, "Next Reminder:"), h("div", { style: { color: '#dddddd' } }, format(new Date((_y = (_x = this.store) === null || _x === void 0 ? void 0 : _x.state) === null || _y === void 0 ? void 0 : _y.next_reminder), 'P p'))))))), isEnvelopeOwner && (h("verdocs-button", { class: "manage-recipients-button", variant: "standard", label: "Cancel Envelope", onClick: () => (this.showCancelDialog = !functionsDisabled), disabled: functionsDisabled })))), this.activeTab === 3 && (h("div", { class: "content" }, h("div", { class: "title" }, "History"), historyEntries.map(entry => (h("div", { class: "history-entry" }, h("div", { class: "activity-icon", innerHTML: ActivityIcons[entry.icon] || entry.icon }), h("div", { class: "activity-details" }, h("div", { class: "activity-text" }, entry.message), h("div", { class: "activity-date" }, format(entry.date, FORMAT_TIMESTAMP)))))))), this.showRecipientDialog && (h("verdocs-envelope-recipient-link", { envelopeId: this.envelopeId, roleName: this.showRecipientDialog, onNext: () => (this.showRecipientDialog = '') })), this.showCancelDialog && (h("verdocs-ok-dialog", { heading: "Cancel Envelope?", message: 'Are you sure you want to cancel this Envelope? This action cannot be undone.', onNext: () => {
336
338
  this.showCancelDialog = false;
337
- this.cancelEnvelope();
339
+ this.handleCancelEnvelope();
338
340
  } }))));
339
341
  }
340
342
  };
@@ -1,6 +1,6 @@
1
1
  import { r as registerInstance, c as createEvent, h, H as Host } from './index-a68c7262.js';
2
2
  import { VerdocsEndpoint, getEnvelopes, integerSequence, getRecipientsWithActions, userCanCancelEnvelope, userCanAct, formatFullName, cancelEnvelope } from '@verdocs/js-sdk';
3
- import { s as saveEnvelopesAsZip } from './utils-8f3ace81.js';
3
+ import { s as saveEnvelopesAsZip } from './utils-6ecd6558.js';
4
4
  import { V as VerdocsToast } from './Toast-c4843828.js';
5
5
  import { S as SDKError } from './errors-887f1e88.js';
6
6
  import './_commonjsHelpers-bdec4bbd.js';
@@ -196,18 +196,18 @@ const VerdocsEnvelopesList = class {
196
196
  });
197
197
  }
198
198
  render() {
199
- return (h(Host, { key: '108b5afd94968cb2801ed59a0ac22415b69089d2' }, h("div", { key: 'ce4fc0e1f129cb7628cfc3f6f082074637cff0b7', class: "header" }, h("div", { key: 'ad67a17d11cd9b599242813f3868b58e4296d82d', class: "filter" }, h("verdocs-text-input", { key: '3c516592fdfc4215734c8c84c3553ff368867652', id: "verdocs-filter-name", value: this.match, clearable: true, autocomplete: "off", placeholder: "Filter by Name, Recipient, or Field...", onFocusout: (e) => {
199
+ return (h(Host, { key: '65d29f9d52c1e4580e335015941be7f8f20197a9' }, h("div", { key: '64a021af11c8a291981bb49f88cddedf5253593d', class: "header" }, h("div", { key: '12ae24224cc5bae515cad1b6382b1fa64fce1223', class: "filter" }, h("verdocs-text-input", { key: 'b895bcdfa7829a5a78460759291890859d5cf6b5', id: "verdocs-filter-name", value: this.match, clearable: true, autocomplete: "off", placeholder: "Filter by Name, Recipient, or Field...", onFocusout: (e) => {
200
200
  var _a;
201
201
  // We don't locally filter envelopes because there are too many fields to match against efficiently.
202
202
  this.match = e.target.value.trim();
203
203
  (_a = this.changeMatch) === null || _a === void 0 ? void 0 : _a.emit(this.match);
204
- } })), h("verdocs-quick-filter", { key: '215d014e581b9bff84a56ee919810b6329a2789e', label: "View", value: this.view, options: ViewFilters, onOptionSelected: e => {
204
+ } })), h("verdocs-quick-filter", { key: '72e6e429edabd43c71a24d5d74e7be57b44073b8', label: "View", value: this.view, options: ViewFilters, onOptionSelected: e => {
205
205
  this.view = e.detail.value;
206
- } }), this.view === 'all' && (h("verdocs-quick-filter", { key: '69f79850d7165d1150383f845909dd3cfd23255e', label: "Status", value: this.status, options: StatusFilters, onOptionSelected: e => {
206
+ } }), this.view === 'all' && (h("verdocs-quick-filter", { key: '883d9ed133ad696a6fa1a572aa331aad753296ea', label: "Status", value: this.status, options: StatusFilters, onOptionSelected: e => {
207
207
  this.status = e.detail.value;
208
- } })), this.view === 'all' && (h("verdocs-quick-filter", { key: 'eb5b7ff77417c2432a9963fa1cffb30e09bf3e05', label: "Sort By", value: this.sort, options: SortFilters, onOptionSelected: e => {
208
+ } })), this.view === 'all' && (h("verdocs-quick-filter", { key: '626d712a6760eb30c9d10a142358f0e9c3ad6548', label: "Sort By", value: this.sort, options: SortFilters, onOptionSelected: e => {
209
209
  this.sort = e.detail.value;
210
- } })), this.loading && h("verdocs-spinner", { key: 'a1869793d432b972161301903df300a9e972728b', mode: "dark", size: 24 }), h("div", { key: '9ad9261f2c1fac268483b2caf7c5f4b67f1a5236', style: { display: 'flex', flex: '1' } }), this.selectedEnvelopes.length > 0 && h("verdocs-button", { key: '47d7186632c3823a573f4b034e8c301dc842992e', label: `Download (${this.selectedEnvelopes.length})`, onClick: () => this.handleDownload() })), this.envelopes.map(envelope => {
210
+ } })), this.loading && h("verdocs-spinner", { key: '391ee75435dfe6203eef29e29b14f74cda3a32ab', mode: "dark", size: 24 }), h("div", { key: 'd12b2ce01d44e81728189968947c7b5e9e778293', style: { display: 'flex', flex: '1' } }), this.selectedEnvelopes.length > 0 && h("verdocs-button", { key: 'c2d20419257993759e8cd7c5ea5e58a20db5b15e', label: `Download (${this.selectedEnvelopes.length})`, onClick: () => this.handleDownload() })), this.envelopes.map(envelope => {
211
211
  var _a;
212
212
  const recipientsWithActions = getRecipientsWithActions(envelope);
213
213
  const userCanCancel = userCanCancelEnvelope(this.endpoint.profile, envelope);
@@ -248,7 +248,7 @@ const VerdocsEnvelopesList = class {
248
248
  break;
249
249
  }
250
250
  } }))));
251
- }), !this.initiallyLoaded && (h("div", { key: '8b16c1e78ed0b9263e6831e8e84c7f92863a5225', style: { width: '100%' } }, integerSequence(0, this.rowsPerPage).map(() => (h("div", { class: "envelope-placeholder" }))))), this.initiallyLoaded && !this.envelopes.length && h("div", { key: '9b7aeee48c38402025afec1e8584be15c9160eb1', class: "empty-text" }, "No matching envelopes found. Please adjust your filters and try again."), this.initiallyLoaded && this.envelopes.length && this.showPagination ? (h("div", { style: { marginTop: '20px' } }, h("verdocs-pagination", { selectedPage: this.selectedPage, perPage: this.rowsPerPage, itemCount: this.count, onSelectPage: e => {
251
+ }), !this.initiallyLoaded && (h("div", { key: '3c1f1711abdeaaf92c12129e8f7e5ab13c06db1d', style: { width: '100%' } }, integerSequence(0, this.rowsPerPage).map(() => (h("div", { class: "envelope-placeholder" }))))), this.initiallyLoaded && !this.envelopes.length && h("div", { key: '1f14c23162b105b4947e3b574e0192fee0f164b5', class: "empty-text" }, "No matching envelopes found. Please adjust your filters and try again."), this.initiallyLoaded && this.envelopes.length && this.showPagination ? (h("div", { style: { marginTop: '20px' } }, h("verdocs-pagination", { selectedPage: this.selectedPage, perPage: this.rowsPerPage, itemCount: this.count, onSelectPage: e => {
252
252
  this.selectedPage = e.detail.selectedPage;
253
253
  } }))) : (h("div", null))));
254
254
  }
@@ -13,14 +13,14 @@ const verdocsFieldAttachmentCss = "@-webkit-keyframes verdocs-field-pulse{0%{bac
13
13
  const VerdocsFieldAttachmentStyle0 = verdocsFieldAttachmentCss;
14
14
 
15
15
  const PaperclipIcon$1 = `<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15.172 7l-6.586 6.586a2 2 0 102.828 2.828l6.414-6.586a4 4 0 00-5.656-5.656l-6.415 6.585a6 6 0 108.486 8.486L20.5 13" /></svg>`;
16
- const AttachedIcon = `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 104.69 122.88"><g><path d="M31.54,86.95c-1.74,0-3.16-1.43-3.16-3.19c0-1.76,1.41-3.19,3.16-3.19h20.5c1.74,0,3.16,1.43,3.16,3.19 c0,1.76-1.41,3.19-3.16,3.19H31.54L31.54,86.95z M31.54,42.27c-1.74,0-3.15-1.41-3.15-3.15c0-1.74,1.41-3.15,3.15-3.15h41.61 c1.74,0,3.15,1.41,3.15,3.15c0,1.74-1.41,3.15-3.15,3.15H31.54L31.54,42.27z M66.57,108.66c-1.36-1.08-1.59-3.06-0.5-4.42 c1.08-1.36,3.06-1.59,4.42-0.5l9.57,7.59l18.21-22.27c1.1-1.35,3.09-1.54,4.43-0.44c1.35,1.1,1.54,3.09,0.44,4.43l-20.17,24.67l0,0 c-1.09,1.33-3.04,1.54-4.39,0.47L66.57,108.66L66.57,108.66z M56.85,116.58c1.74,0,3.15,1.41,3.15,3.15c0,1.74-1.41,3.15-3.15,3.15 H7.33c-2.02,0-3.85-0.82-5.18-2.15C0.82,119.4,0,117.57,0,115.55V7.33c0-2.02,0.82-3.85,2.15-5.18C3.48,0.82,5.31,0,7.33,0h90.02 c2.02,0,3.85,0.82,5.18,2.15c1.33,1.33,2.15,3.16,2.15,5.18V72.6c0,1.74-1.41,3.15-3.15,3.15c-1.74,0-3.15-1.41-3.15-3.15V7.33 c0-0.28-0.12-0.54-0.3-0.73c-0.19-0.19-0.45-0.3-0.73-0.3H7.33c-0.28,0-0.54,0.12-0.73,0.3C6.42,6.8,6.3,7.05,6.3,7.33v108.21 c0,0.28,0.12,0.54,0.3,0.73c0.19,0.19,0.45,0.3,0.73,0.3H56.85L56.85,116.58z M31.54,64.59c-1.74,0-3.15-1.41-3.15-3.15 c0-1.74,1.41-3.15,3.15-3.15h41.61c1.74,0,3.15,1.41,3.15,3.15c0,1.74-1.41,3.15-3.15,3.15H31.54L31.54,64.59z"/></g></svg>`;
16
+ // const AttachedIcon = `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 104.69 122.88"><g><path d="M31.54,86.95c-1.74,0-3.16-1.43-3.16-3.19c0-1.76,1.41-3.19,3.16-3.19h20.5c1.74,0,3.16,1.43,3.16,3.19 c0,1.76-1.41,3.19-3.16,3.19H31.54L31.54,86.95z M31.54,42.27c-1.74,0-3.15-1.41-3.15-3.15c0-1.74,1.41-3.15,3.15-3.15h41.61 c1.74,0,3.15,1.41,3.15,3.15c0,1.74-1.41,3.15-3.15,3.15H31.54L31.54,42.27z M66.57,108.66c-1.36-1.08-1.59-3.06-0.5-4.42 c1.08-1.36,3.06-1.59,4.42-0.5l9.57,7.59l18.21-22.27c1.1-1.35,3.09-1.54,4.43-0.44c1.35,1.1,1.54,3.09,0.44,4.43l-20.17,24.67l0,0 c-1.09,1.33-3.04,1.54-4.39,0.47L66.57,108.66L66.57,108.66z M56.85,116.58c1.74,0,3.15,1.41,3.15,3.15c0,1.74-1.41,3.15-3.15,3.15 H7.33c-2.02,0-3.85-0.82-5.18-2.15C0.82,119.4,0,117.57,0,115.55V7.33c0-2.02,0.82-3.85,2.15-5.18C3.48,0.82,5.31,0,7.33,0h90.02 c2.02,0,3.85,0.82,5.18,2.15c1.33,1.33,2.15,3.16,2.15,5.18V72.6c0,1.74-1.41,3.15-3.15,3.15c-1.74,0-3.15-1.41-3.15-3.15V7.33 c0-0.28-0.12-0.54-0.3-0.73c-0.19-0.19-0.45-0.3-0.73-0.3H7.33c-0.28,0-0.54,0.12-0.73,0.3C6.42,6.8,6.3,7.05,6.3,7.33v108.21 c0,0.28,0.12,0.54,0.3,0.73c0.19,0.19,0.45,0.3,0.73,0.3H56.85L56.85,116.58z M31.54,64.59c-1.74,0-3.15-1.41-3.15-3.15 c0-1.74,1.41-3.15,3.15-3.15h41.61c1.74,0,3.15,1.41,3.15,3.15c0,1.74-1.41,3.15-3.15,3.15H31.54L31.54,64.59z"/></g></svg>`;
17
+ const AttachedIcon = `<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="#339933" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-file-check"><path d="M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z"/><path d="M14 2v4a2 2 0 0 0 2 2h4"/><path d="m9 15 2 2 4-4"/></svg>`;
17
18
  const VerdocsFieldAttachment = class {
18
19
  constructor(hostRef) {
19
20
  registerInstance(this, hostRef);
20
21
  this.settingsChanged = createEvent(this, "settingsChanged", 7);
21
- this.deleted = createEvent(this, "deleted", 7);
22
22
  this.attached = createEvent(this, "attached", 7);
23
- this.remove = createEvent(this, "remove", 7);
23
+ this.deleted = createEvent(this, "deleted", 7);
24
24
  this.fieldStore = null;
25
25
  this.roleStore = null;
26
26
  this.handleUploadNext = (e) => {
@@ -30,6 +30,14 @@ const VerdocsFieldAttachment = class {
30
30
  this.selectedFile = e.detail[0];
31
31
  (_a = this.attached) === null || _a === void 0 ? void 0 : _a.emit(e.detail[0]);
32
32
  };
33
+ this.handleUploadRemove = (e) => {
34
+ var _a;
35
+ e.preventDefault();
36
+ e.stopPropagation();
37
+ this.dialogOpen = false;
38
+ this.selectedFile = null;
39
+ (_a = this.deleted) === null || _a === void 0 ? void 0 : _a.emit({ fieldName: this.fieldname });
40
+ };
33
41
  this.endpoint = VerdocsEndpoint.getDefault();
34
42
  this.templateid = '';
35
43
  this.fieldname = '';
@@ -48,6 +56,7 @@ const VerdocsFieldAttachment = class {
48
56
  async focusField() {
49
57
  // Our input field is fake, so we fake the flash too
50
58
  this.focused = true;
59
+ this.dialogOpen = true;
51
60
  setTimeout(() => {
52
61
  this.focused = false;
53
62
  }, 500);
@@ -74,7 +83,6 @@ const VerdocsFieldAttachment = class {
74
83
  render() {
75
84
  const { templateid, fieldname = '', editable = false, done = false, disabled = false, focused, xscale = 1, yscale = 1 } = this;
76
85
  const field = this.fieldStore.get('fields').find(field => field.name === fieldname);
77
- console.log('Rendering attachment', field);
78
86
  const { required = false, role_name = '', value = '', label = '', settings = {} } = field || {};
79
87
  const backgroundColor = getRGBA(getRoleIndex(this.roleStore, role_name));
80
88
  const hasFile = value || !!this.selectedFile;
@@ -92,9 +100,7 @@ const VerdocsFieldAttachment = class {
92
100
  var _a;
93
101
  (_a = this.settingsChanged) === null || _a === void 0 ? void 0 : _a.emit(e.detail);
94
102
  return this.hideSettingsPanel();
95
- }, helpText: 'Attachments allow the user to attach their own documents (e.g. resumes or disclosures) to a signing flow.' }))))), this.dialogOpen && (h("verdocs-portal", null, h("verdocs-upload-dialog", { existingFile: settings, onNext: e => this.handleUploadNext(e), onExit: () => (this.dialogOpen = false), onRemove: e => {
96
- console.log('remove', e);
97
- } })))));
103
+ }, helpText: 'Attachments allow the user to attach their own documents (e.g. resumes or disclosures) to a signing flow.' }))))), this.dialogOpen && (h("verdocs-portal", null, h("verdocs-upload-dialog", { existingFile: settings, onNext: e => this.handleUploadNext(e), onRemove: e => this.handleUploadRemove(e), onExit: () => (this.dialogOpen = false) })))));
98
104
  }
99
105
  get el() { return getElement(this); }
100
106
  };
@@ -211,6 +217,7 @@ const VerdocsFieldDate = class {
211
217
  this.deleted = createEvent(this, "deleted", 7);
212
218
  this.fieldStore = null;
213
219
  this.roleStore = null;
220
+ this.picker = null;
214
221
  this.templateid = '';
215
222
  this.fieldname = '';
216
223
  this.disabled = false;
@@ -226,8 +233,10 @@ const VerdocsFieldDate = class {
226
233
  this.focused = false;
227
234
  }
228
235
  async focusField() {
236
+ var _a;
229
237
  // Our input field is fake, so we fake the flash too
230
238
  this.focused = true;
239
+ (_a = this.picker) === null || _a === void 0 ? void 0 : _a.show();
231
240
  setTimeout(() => {
232
241
  this.focused = false;
233
242
  }, 500);
@@ -241,7 +250,7 @@ const VerdocsFieldDate = class {
241
250
  this.roleStore = getTemplateRoleStore(this.templateid);
242
251
  }
243
252
  componentDidLoad() {
244
- new AirDatepicker(`#${this.containerId}`, {
253
+ this.picker = new AirDatepicker(`#${this.containerId}`, {
245
254
  locale: default_1,
246
255
  isMobile: true,
247
256
  autoClose: true,
@@ -344,11 +353,18 @@ const VerdocsFieldDropdown = class {
344
353
  render() {
345
354
  const { templateid, fieldname = '', editable = false, done = false, disabled = false, focused, xscale = 1, yscale = 1 } = this;
346
355
  const field = this.fieldStore.get('fields').find(field => field.name === fieldname);
347
- const { required = false, role_name = '', value = '', label = '', options = [] } = field || {};
356
+ let { required = false, role_name = '', value = '', label = '', options } = field || {};
348
357
  const backgroundColor = getRGBA(getRoleIndex(this.roleStore, role_name));
349
358
  if (done) {
350
359
  return h(Host, { class: { done } }, value);
351
360
  }
361
+ // TODO: Look for other places this mistaken assumption was made.
362
+ // Defaults only apply in destructuring if undefined. null doesn't trigger it.
363
+ options || (options = []);
364
+ if (!options.length) {
365
+ console.log('[DROPDOWN] Dropdown has no options, hiding field...', fieldname);
366
+ return h(Host, null);
367
+ }
352
368
  return (h(Host, { class: { required, disabled, done, focused }, style: { backgroundColor } }, label && h("label", null, label), h("select", { disabled: disabled, onChange: e => this.handleChange(e) }, h("option", { value: "" }, "Select..."), options.map(option => (h("option", { value: option.id, selected: option.id === value }, option.label)))), editable && (h(Fragment, null, h("div", { id: `verdocs-settings-panel-trigger-${fieldname}`, style: { transform: `scale(${Math.floor((1 / xscale) * 1000) / 1000}, ${Math.floor((1 / yscale) * 1000) / 1000})` }, class: "settings-icon", innerHTML: SettingsIcon, onClick: (e) => {
353
369
  e.stopPropagation();
354
370
  this.showingProperties = !this.showingProperties;
@@ -1381,7 +1397,7 @@ const VerdocsSignatureDialog = class {
1381
1397
  };
1382
1398
  VerdocsSignatureDialog.style = VerdocsSignatureDialogStyle0;
1383
1399
 
1384
- const verdocsUploadDialogCss = "@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-upload-dialog{position:fixed;-webkit-box-sizing:border-box;box-sizing:border-box;font-family:\"Inter\", \"Barlow\", sans-serif}verdocs-upload-dialog div{-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-upload-dialog .background-overlay{top:0;left:0;right:0;bottom:0;display:-ms-flexbox;display:flex;z-index:10000;position:fixed;-ms-flex-align:center;align-items:center;background:rgba(0, 0, 0, 0.4980392157);-ms-flex-pack:center;justify-content:center}verdocs-upload-dialog .dialog{width:320px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;border-radius:4px;overflow:hidden;background:#ffffff;padding:16px;-webkit-box-shadow:3px 3px 5px 1px rgba(40, 40, 40, 0.4);box-shadow:3px 3px 5px 1px rgba(40, 40, 40, 0.4)}verdocs-upload-dialog .heading{display:-ms-flexbox;display:flex;font-size:20px;font-weight:500;-ms-flex-direction:row;flex-direction:row}verdocs-upload-dialog .buttons{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:end;justify-content:flex-end}verdocs-upload-dialog .buttons verdocs-button{margin-left:16px}verdocs-upload-dialog .current-label{margin:20px 0 5px 0}verdocs-upload-dialog .drop-target{opacity:1;width:100%;display:-ms-flexbox;display:flex;margin:20px 0;min-height:260px;padding:30px 15px;text-align:center;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;background-color:#f5f5f5;color:rgba(0, 0, 0, 0.54);border:2px dashed #979797}verdocs-upload-dialog .drop-target p{margin:12px 0}verdocs-upload-dialog .drop-target.dragging-over{border:5px solid #4c56cb}verdocs-upload-dialog .drop-target>verdocs-button{margin:12px 0;display:inline-block}verdocs-upload-dialog .attachments{height:56px;font-size:0;margin:20px 0;padding:0 16px;line-height:56px;white-space:normal;-webkit-box-shadow:0 1px 3px 0 rgba(0, 0, 0, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.12), 0 0 2px 0 rgba(0, 0, 0, 0.14);box-shadow:0 1px 3px 0 rgba(0, 0, 0, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.12), 0 0 2px 0 rgba(0, 0, 0, 0.14)}verdocs-upload-dialog .attachments .attachment{gap:10px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}verdocs-upload-dialog .attachments .attachment .icon{width:18px;height:18px;line-height:18px}verdocs-upload-dialog .attachments .attachment .icon.trash{cursor:pointer}verdocs-upload-dialog .attachments .attachment .name{-ms-flex:1;flex:1;font-size:14px;overflow:hidden;font-weight:400;white-space:nowrap;text-overflow:ellipsis}";
1400
+ const verdocsUploadDialogCss = "@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-upload-dialog{position:fixed;-webkit-box-sizing:border-box;box-sizing:border-box;font-family:\"Inter\", \"Barlow\", sans-serif}verdocs-upload-dialog div{-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-upload-dialog .background-overlay{top:0;left:0;right:0;bottom:0;display:-ms-flexbox;display:flex;z-index:10000;position:fixed;-ms-flex-align:center;align-items:center;background:rgba(0, 0, 0, 0.4980392157);-ms-flex-pack:center;justify-content:center}verdocs-upload-dialog .upload-dialog-content{width:320px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;border-radius:4px;overflow:hidden;background:#ffffff;padding:16px;-webkit-box-shadow:3px 3px 5px 1px rgba(40, 40, 40, 0.4);box-shadow:3px 3px 5px 1px rgba(40, 40, 40, 0.4)}verdocs-upload-dialog .heading{display:-ms-flexbox;display:flex;font-size:20px;font-weight:500;-ms-flex-direction:row;flex-direction:row}verdocs-upload-dialog .buttons{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:end;justify-content:flex-end}verdocs-upload-dialog .buttons verdocs-button{margin-left:16px}verdocs-upload-dialog .current-label{margin:20px 0 5px 0}verdocs-upload-dialog .drop-target{opacity:1;width:100%;display:-ms-flexbox;display:flex;margin:20px 0;min-height:260px;padding:30px 15px;text-align:center;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;background-color:#f5f5f5;color:rgba(0, 0, 0, 0.54);border:2px dashed #979797}verdocs-upload-dialog .drop-target p{margin:12px 0}verdocs-upload-dialog .drop-target.dragging-over{border:5px solid #4c56cb}verdocs-upload-dialog .drop-target>verdocs-button{margin:12px 0;display:inline-block}verdocs-upload-dialog .attachments{height:56px;font-size:0;margin:20px 0;padding:0 16px;line-height:56px;white-space:normal;-webkit-box-shadow:0 1px 3px 0 rgba(0, 0, 0, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.12), 0 0 2px 0 rgba(0, 0, 0, 0.14);box-shadow:0 1px 3px 0 rgba(0, 0, 0, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.12), 0 0 2px 0 rgba(0, 0, 0, 0.14)}verdocs-upload-dialog .attachments .attachment{gap:10px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}verdocs-upload-dialog .attachments .attachment .icon{width:18px;height:18px;line-height:18px}verdocs-upload-dialog .attachments .attachment .icon.trash{cursor:pointer}verdocs-upload-dialog .attachments .attachment .name{-ms-flex:1;flex:1;font-size:14px;overflow:hidden;font-weight:400;white-space:nowrap;text-overflow:ellipsis}";
1385
1401
  const VerdocsUploadDialogStyle0 = verdocsUploadDialogCss;
1386
1402
 
1387
1403
  const TrashIcon = `<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 7l-.867 12.142A2 2 0 0116.138 21H7.862a2 2 0 01-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 00-1-1h-4a1 1 0 00-1 1v3M4 7h16" /></svg>`;
@@ -1394,6 +1410,7 @@ const VerdocsUploadDialog = class {
1394
1410
  this.remove = createEvent(this, "remove", 7);
1395
1411
  this.existingFile = undefined;
1396
1412
  this.draggingOver = false;
1413
+ this.confirmDelete = false;
1397
1414
  this.selectedFiles = [];
1398
1415
  }
1399
1416
  handleCancel() {
@@ -1427,11 +1444,15 @@ const VerdocsUploadDialog = class {
1427
1444
  newFiles.splice(index, 1);
1428
1445
  this.selectedFiles = newFiles;
1429
1446
  }
1430
- handleDeleteAttachment() {
1447
+ handleDeleteAttachment(e) {
1431
1448
  var _a;
1432
- // TODO: Discuss how we want to delete up to the server
1449
+ // Stop the parent from seeing "next" and thinking an upload was done.
1450
+ // TODO: Rethink having so many commonalities in nested dialogs (next/exit).
1451
+ e.preventDefault();
1452
+ e.stopPropagation();
1433
1453
  (_a = this.remove) === null || _a === void 0 ? void 0 : _a.emit();
1434
1454
  this.existingFile = null;
1455
+ this.confirmDelete = false;
1435
1456
  }
1436
1457
  handleSelectFile() {
1437
1458
  var _a;
@@ -1442,7 +1463,14 @@ const VerdocsUploadDialog = class {
1442
1463
  this.selectedFiles = Array.from((_a = this.fileInput) === null || _a === void 0 ? void 0 : _a.files);
1443
1464
  }
1444
1465
  render() {
1445
- return (h(Host, { key: 'ea7aaec178e0708c73e6ad4f12253f4ff73b9310' }, h("div", { key: '7d769afe448df6edfb40800bc08237d60c924d95', class: "background-overlay", onClick: e => this.handleDismiss(e) }, h("div", { key: 'cd32c34e98c48b1e48b1792bead1634ca70df871', class: "dialog" }, h("div", { key: 'eb7f1782c643b531c2ff6faf17e2248f803cde39', class: "heading" }, "Upload attachment"), this.selectedFiles.length < 1 && this.existingFile && (h(Fragment, { key: '2feac9b495828147f2be51e2368c7d03b039f64a' }, h("div", { key: '9ead90c769215c71bd952bb585a3cbde16c7e518', class: "current-label" }, "Current Attachment"), h("div", { key: '671e35179c26f14823ae504a1fc40f4506117e2e', class: "attachments", style: { marginTop: '0' } }, h("div", { key: '2ae16fe846ee84db2f0fdb2cfb39d1e0a30f85f2', class: "attachment" }, h("div", { key: '8db0145b16b3568d7fd5e1287a4a81b3a8822c3f', class: "icon", innerHTML: PaperclipIcon }), h("div", { key: '5c9c54ce036cec26e721fc32e4a9c8326735f221', class: "name" }, this.existingFile.name), h("div", { key: '99c17d1a88f6f8c07b346b37836969c60c1ee31d', class: "icon trash", innerHTML: TrashIcon, onClick: () => this.handleDeleteAttachment() }))))), this.selectedFiles.length < 1 && !this.existingFile && (h("div", { key: 'eec6e965857fca674db531ebad805c6931a2daf2', class: { 'drop-target': true, 'dragging-over': this.draggingOver }, onDragOver: e => this.handleDragOver(e), onDragLeave: e => this.handleDragLeave(e), onDrop: e => this.handleDrop(e) }, h("p", { key: '4dc240eacbd3724a54f6613113d98f5446c6c478' }, "Drag and drop a ", !!this.existingFile && 'replacement', " here..."), h("p", { key: 'af261cba2d009aa6733891e670029e4a2fec6a4d' }, "- or -"), h("verdocs-button", { key: 'f922efbffa39aa22b58b30b50697f17edcdd0f48', label: !!this.existingFile ? 'Replace file...' : 'Select a file...', onClick: () => this.handleSelectFile() }), h("input", { key: '504ae2231657a1ff6f27405b789c239f41f4fdce', type: "file", ref: el => (this.fileInput = el), style: { display: 'none' }, onChange: () => this.handleFileChange() }))), this.selectedFiles.length > 0 && (h("div", { key: 'e225969a1e6073a883e3e47fbeeec1bf88085f82', class: "attachments" }, this.selectedFiles.map((file, index) => (h("div", { class: "attachment" }, h("div", { class: "icon", innerHTML: PaperclipIcon }), h("div", { class: "name" }, file.name), h("div", { class: "icon trash", innerHTML: TrashIcon, onClick: () => this.handleRemoveAttachment(index) })))))), h("div", { key: 'b34ab1a0be4e5b7bfeb9f52b2e4820e8dce3a40a', class: "buttons" }, h("verdocs-button", { key: '9e35669d8a39a493b53434d680d66745610d4828', label: "Cancel", variant: "outline", onClick: () => this.handleCancel() }), h("verdocs-button", { key: '9b41014e538eecdec86221c637c09c8f00b9b3af', label: "Upload", onClick: () => this.handleDone(), disabled: this.selectedFiles.length < 1 }))))));
1466
+ var _a;
1467
+ const existingFile = ((_a = this.existingFile) === null || _a === void 0 ? void 0 : _a.name) ? this.existingFile : null;
1468
+ return (h(Host, { key: '1659eb29f75e9bf3866a011a1ce39767f045e58c' }, h("div", { key: '764f802db78676a02d17fbf2ee93dd859c90494c', class: "background-overlay", onClick: e => this.handleDismiss(e) }, h("div", { key: 'c28580308a52defdd648f197aa5d1e74a1ff366c', class: "upload-dialog-content" }, h("div", { key: '6de50a3f71d93a176b4db5a248a49da4cf8d404d', class: "heading" }, "Upload attachment"), this.selectedFiles.length < 1 && existingFile && (h(Fragment, { key: '0882e3e5cae1dae105645f6f4b5dd8986c336e1f' }, h("div", { key: 'a762a4dbf4f1be8a29d637e6bee196ab4b960c60', class: "current-label" }, "Current Attachment"), h("div", { key: 'ada0b184bb53583dc6012ab5393be2a36714eba4', class: "attachments", style: { marginTop: '0' } }, h("div", { key: '3d9555cf0f7876ba192e3efec76bf677eec137cf', class: "attachment" }, h("div", { key: 'cea6d0e30448b6ea003a32d838bd64d642a621f3', class: "icon", innerHTML: PaperclipIcon }), h("div", { key: '20b87ade4eb56de78db2e0c1a7fe5c1f88d9f2c7', class: "name" }, existingFile.name), h("div", { key: '6359ea1dffd674d708afcd6b1e4f5be38062b861', class: "icon trash", innerHTML: TrashIcon, onClick: () => (this.confirmDelete = true) }))))), this.selectedFiles.length < 1 && !existingFile && (h("div", { key: 'c554239826339af3008fd9b4ef235efe6b4bf138', class: { 'drop-target': true, 'dragging-over': this.draggingOver }, onDragOver: e => this.handleDragOver(e), onDragLeave: e => this.handleDragLeave(e), onDrop: e => this.handleDrop(e) }, h("p", { key: 'a2bcc388981e79a1c6c3325081546ea41d7fd96f' }, "Drag and drop a ", !!existingFile && 'replacement', " here..."), h("p", { key: '23c7c1e2c8c369a8b85d83fc9a7d2e03bd26f6d9' }, "- or -"), h("verdocs-button", { key: 'cba655d0b392f5f03776f769cd3ee626b432b846', label: !!existingFile ? 'Replace file...' : 'Select a file...', onClick: () => this.handleSelectFile() }), h("input", { key: 'cbaa00e587959f418709c89b531a173512f5b9fa', type: "file", ref: el => (this.fileInput = el), style: { display: 'none' }, onChange: () => this.handleFileChange() }))), this.selectedFiles.length > 0 && (h("div", { key: '35f7be5ad20ecab5947c2f90f4ac529775ec51ce', class: "attachments" }, this.selectedFiles.map((file, index) => (h("div", { class: "attachment" }, h("div", { class: "icon", innerHTML: PaperclipIcon }), h("div", { class: "name" }, file.name), h("div", { class: "icon trash", innerHTML: TrashIcon, onClick: () => this.handleRemoveAttachment(index) })))))), h("div", { key: 'ea437cefbfa71cd4853f4fd77d1d1a78b576e032', class: "buttons" }, h("verdocs-button", { key: '2be19df5ae677ee0d0893266fd2f72aeff609e95', label: "Cancel", variant: "outline", onClick: () => this.handleCancel() }), h("verdocs-button", { key: '2013efb5dba9d6b3236ad280dbc6883473eebabf', label: "Upload", onClick: () => this.handleDone(), disabled: this.selectedFiles.length < 1 })))), this.confirmDelete && (h("verdocs-ok-dialog", { key: 'd55cbad44c7d50d9c479a87917b14fc0ae488a2b', heading: "Delete Attachment?", message: "Are you sure you wish to delete this attachment? This action cannot be undone.", showCancel: true, onExit: e => {
1469
+ // So we don't close the upload dialog
1470
+ e.preventDefault();
1471
+ e.stopPropagation();
1472
+ this.confirmDelete = false;
1473
+ }, onNext: e => this.handleDeleteAttachment(e) }))));
1446
1474
  }
1447
1475
  };
1448
1476
  VerdocsUploadDialog.style = VerdocsUploadDialogStyle0;