@verdocs/web-sdk 1.13.7 → 1.13.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/Icons-a11fb3fc.js +84 -0
- package/dist/cjs/TemplateDocuments-e2e0e6b7.js +93 -0
- package/dist/cjs/{TemplateStore-df478971.js → TemplateStore-f934a60e.js} +13 -5
- package/dist/cjs/{index-67233b76.js → index-5e786db9.js} +10 -0
- package/dist/cjs/ipc-test.cjs.entry.js +36 -0
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/verdocs-auth.cjs.entry.js +3 -3
- package/dist/cjs/verdocs-build.cjs.entry.js +6 -8
- package/dist/cjs/verdocs-button-panel_3.cjs.entry.js +3 -3
- package/dist/cjs/verdocs-button.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-checkbox_4.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-contact-picker.cjs.entry.js +2 -2
- package/dist/cjs/verdocs-dropdown_2.cjs.entry.js +2 -2
- package/dist/cjs/verdocs-envelope-sidebar.cjs.entry.js +2 -2
- package/dist/cjs/verdocs-field-attachment.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-field-checkbox.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-field-date.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-field-dropdown.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-field-initial.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-field-payment.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-field-radio-button.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-field-signature.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-field-textarea.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-field-textbox.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-field-timestamp.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-file-chooser_2.cjs.entry.js +56 -0
- package/dist/cjs/verdocs-floating-menu.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-initial-dialog.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-kba-dialog.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-loader.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-ok-dialog.cjs.entry.js +2 -2
- package/dist/cjs/verdocs-organization-card.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-preview.cjs.entry.js +3 -3
- package/dist/cjs/verdocs-quick-functions_3.cjs.entry.js +2 -2
- package/dist/cjs/verdocs-radio-button.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-search-tabs.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-search.cjs.entry.js +2 -2
- package/dist/cjs/verdocs-send.cjs.entry.js +3 -3
- package/dist/cjs/verdocs-sign.cjs.entry.js +2 -2
- package/dist/cjs/verdocs-signature-dialog.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-status-indicator.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-template-attachments_2.cjs.entry.js +228 -0
- package/dist/cjs/verdocs-template-card.cjs.entry.js +1 -1
- package/dist/cjs/{verdocs-template-document-page.cjs.entry.js → verdocs-template-document-page_2.cjs.entry.js} +49 -54
- package/dist/cjs/{verdocs-template-create_3.cjs.entry.js → verdocs-template-fields_4.cjs.entry.js} +261 -107
- package/dist/cjs/verdocs-template-name.cjs.entry.js +4 -4
- package/dist/cjs/verdocs-template-properties.cjs.entry.js +4 -4
- package/dist/cjs/verdocs-template-reminders.cjs.entry.js +3 -3
- package/dist/cjs/verdocs-template-tags.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-template-visibility.cjs.entry.js +3 -3
- package/dist/cjs/verdocs-toggle-button.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-toggle.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-upload-dialog.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-view.cjs.entry.js +2 -2
- package/dist/cjs/verdocs-web-sdk.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +2 -0
- package/dist/collection/components/controls/verdocs-file-chooser/verdocs-file-chooser.css +27 -0
- package/dist/collection/components/controls/verdocs-file-chooser/verdocs-file-chooser.js +93 -0
- package/dist/collection/components/controls/verdocs-file-chooser/verdocs-file-chooser.stories.js +10 -0
- package/dist/collection/components/dialogs/verdocs-ok-dialog/verdocs-ok-dialog.css +1 -1
- package/dist/collection/components/embeds/verdocs-auth/verdocs-auth.js +4 -3
- package/dist/collection/components/embeds/verdocs-build/verdocs-build.js +22 -8
- package/dist/collection/components/other/ipctest/ipc-test.css +4 -0
- package/dist/collection/components/other/ipctest/ipc-test.js +79 -0
- package/dist/collection/components/other/ipctest/ipc-test.stories.js +8 -0
- package/dist/collection/components/templates/verdocs-template-attachments/verdocs-template-attachments.css +91 -5
- package/dist/collection/components/templates/verdocs-template-attachments/verdocs-template-attachments.js +140 -10
- package/dist/collection/components/templates/verdocs-template-attachments/verdocs-template-attachments.stories.js +2 -3
- package/dist/collection/components/templates/verdocs-template-create/verdocs-template-create.js +2 -2
- package/dist/collection/components/templates/verdocs-template-field-properties/verdocs-template-field-properties.stories.js +2 -3
- package/dist/collection/components/templates/verdocs-template-fields/verdocs-template-fields.js +16 -14
- package/dist/collection/components/templates/verdocs-template-name/verdocs-template-name.css +0 -40
- package/dist/collection/components/templates/verdocs-template-name/verdocs-template-name.stories.js +1 -2
- package/dist/collection/components/templates/verdocs-template-properties/verdocs-template-properties.js +1 -1
- package/dist/collection/components/templates/verdocs-template-properties/verdocs-template-properties.stories.js +1 -1
- package/dist/collection/components/templates/verdocs-template-reminders/verdocs-template-reminders.stories.js +1 -2
- package/dist/collection/components/templates/verdocs-template-role-properties/verdocs-template-role-properties.js +18 -15
- package/dist/collection/components/templates/verdocs-template-roles/verdocs-template-roles.js +8 -4
- package/dist/collection/components/templates/verdocs-template-visibillity/verdocs-template-visibility.stories.js +1 -1
- package/dist/collection/utils/Icons.js +73 -0
- package/dist/collection/utils/TemplateStore.js +11 -3
- package/dist/components/Primitives.js +20 -0
- package/dist/components/TemplateDocuments.js +89 -0
- package/dist/components/TemplateStore.js +11 -3
- package/dist/components/VerdocsEndpoint.js +30 -30
- package/dist/components/index.d.ts +2 -0
- package/dist/components/index.js +2 -0
- package/dist/components/ipc-test.d.ts +11 -0
- package/dist/components/ipc-test.js +136 -0
- package/dist/components/verdocs-auth.js +1 -1
- package/dist/components/verdocs-build.js +38 -23
- package/dist/components/verdocs-file-chooser.d.ts +11 -0
- package/dist/components/verdocs-file-chooser.js +6 -0
- package/dist/components/verdocs-file-chooser2.js +132 -0
- package/dist/components/verdocs-ok-dialog2.js +1 -1
- package/dist/components/verdocs-sign.js +2 -1
- package/dist/components/verdocs-template-attachments.js +1 -87
- package/dist/components/verdocs-template-attachments2.js +200 -0
- package/dist/components/verdocs-template-create2.js +2 -2
- package/dist/components/verdocs-template-document-page2.js +1 -51
- package/dist/components/verdocs-template-fields2.js +16 -14
- package/dist/components/verdocs-template-name.js +1 -1
- package/dist/components/verdocs-template-properties.js +1 -1
- package/dist/components/verdocs-template-role-properties2.js +18 -15
- package/dist/components/verdocs-template-roles2.js +8 -4
- package/dist/components/verdocs-view2.js +2 -20
- package/dist/custom-elements.json +47 -2
- package/dist/docs.json +268 -8
- package/dist/esm/Icons-c29eb0fa.js +75 -0
- package/dist/esm/TemplateDocuments-6fd2f4e2.js +89 -0
- package/dist/esm/{TemplateStore-373c72a8.js → TemplateStore-1a6322b4.js} +13 -5
- package/dist/esm/{index-5260ed60.js → index-9ee0ca9f.js} +10 -0
- package/dist/esm/ipc-test.entry.js +32 -0
- package/dist/esm/loader.js +2 -2
- package/dist/esm/{utils-78a752e0.js → utils-39fef438.js} +1 -1
- package/dist/esm/verdocs-auth.entry.js +3 -3
- package/dist/esm/verdocs-build.entry.js +6 -8
- package/dist/esm/verdocs-button-panel_3.entry.js +3 -3
- package/dist/esm/verdocs-button.entry.js +1 -1
- package/dist/esm/verdocs-checkbox_4.entry.js +1 -1
- package/dist/esm/verdocs-contact-picker.entry.js +2 -2
- package/dist/esm/verdocs-dropdown_2.entry.js +3 -3
- package/dist/esm/verdocs-envelope-sidebar.entry.js +2 -2
- package/dist/esm/verdocs-field-attachment.entry.js +1 -1
- package/dist/esm/verdocs-field-checkbox.entry.js +2 -2
- package/dist/esm/verdocs-field-date.entry.js +2 -2
- package/dist/esm/verdocs-field-dropdown.entry.js +2 -2
- package/dist/esm/verdocs-field-initial.entry.js +2 -2
- package/dist/esm/verdocs-field-payment.entry.js +2 -2
- package/dist/esm/verdocs-field-radio-button.entry.js +2 -2
- package/dist/esm/verdocs-field-signature.entry.js +2 -2
- package/dist/esm/verdocs-field-textarea.entry.js +2 -2
- package/dist/esm/verdocs-field-textbox.entry.js +2 -2
- package/dist/esm/verdocs-field-timestamp.entry.js +2 -2
- package/dist/esm/verdocs-file-chooser_2.entry.js +51 -0
- package/dist/esm/verdocs-floating-menu.entry.js +1 -1
- package/dist/esm/verdocs-initial-dialog.entry.js +1 -1
- package/dist/esm/verdocs-kba-dialog.entry.js +1 -1
- package/dist/esm/verdocs-loader.entry.js +1 -1
- package/dist/esm/verdocs-ok-dialog.entry.js +2 -2
- package/dist/esm/verdocs-organization-card.entry.js +1 -1
- package/dist/esm/verdocs-preview.entry.js +4 -4
- package/dist/esm/verdocs-quick-functions_3.entry.js +2 -2
- package/dist/esm/verdocs-radio-button.entry.js +1 -1
- package/dist/esm/verdocs-search-tabs.entry.js +1 -1
- package/dist/esm/verdocs-search.entry.js +2 -2
- package/dist/esm/verdocs-send.entry.js +4 -4
- package/dist/esm/verdocs-sign.entry.js +3 -3
- package/dist/esm/verdocs-signature-dialog.entry.js +1 -1
- package/dist/esm/verdocs-status-indicator.entry.js +1 -1
- package/dist/esm/verdocs-template-attachments_2.entry.js +223 -0
- package/dist/esm/verdocs-template-card.entry.js +1 -1
- package/dist/esm/{verdocs-template-document-page.entry.js → verdocs-template-document-page_2.entry.js} +49 -55
- package/dist/esm/{verdocs-template-create_3.entry.js → verdocs-template-fields_4.entry.js} +259 -106
- package/dist/esm/verdocs-template-name.entry.js +4 -4
- package/dist/esm/verdocs-template-properties.entry.js +4 -4
- package/dist/esm/verdocs-template-reminders.entry.js +3 -3
- package/dist/esm/verdocs-template-tags.entry.js +1 -1
- package/dist/esm/verdocs-template-visibility.entry.js +3 -3
- package/dist/esm/verdocs-toggle-button.entry.js +1 -1
- package/dist/esm/verdocs-toggle.entry.js +1 -1
- package/dist/esm/verdocs-upload-dialog.entry.js +1 -1
- package/dist/esm/verdocs-view.entry.js +3 -3
- package/dist/esm/verdocs-web-sdk.js +2 -2
- package/dist/esm-es5/Icons-c29eb0fa.js +1 -0
- package/dist/esm-es5/TemplateDocuments-6fd2f4e2.js +1 -0
- package/dist/esm-es5/TemplateStore-1a6322b4.js +1 -0
- package/dist/esm-es5/{VerdocsEndpoint-4367eb13.js → VerdocsEndpoint-ca592138.js} +1 -1
- package/dist/esm-es5/{index-5260ed60.js → index-9ee0ca9f.js} +1 -1
- package/dist/esm-es5/ipc-test.entry.js +1 -0
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/{utils-78a752e0.js → utils-39fef438.js} +1 -1
- package/dist/esm-es5/verdocs-auth.entry.js +1 -1
- package/dist/esm-es5/verdocs-build.entry.js +1 -1
- package/dist/esm-es5/verdocs-button-panel_3.entry.js +1 -1
- package/dist/esm-es5/verdocs-button.entry.js +1 -1
- package/dist/esm-es5/verdocs-checkbox_4.entry.js +1 -1
- package/dist/esm-es5/verdocs-contact-picker.entry.js +1 -1
- package/dist/esm-es5/verdocs-dropdown_2.entry.js +1 -1
- package/dist/esm-es5/verdocs-envelope-sidebar.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-attachment.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-checkbox.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-date.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-dropdown.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-initial.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-payment.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-radio-button.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-signature.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-textarea.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-textbox.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-timestamp.entry.js +1 -1
- package/dist/esm-es5/verdocs-file-chooser_2.entry.js +1 -0
- package/dist/esm-es5/verdocs-floating-menu.entry.js +1 -1
- package/dist/esm-es5/verdocs-initial-dialog.entry.js +1 -1
- package/dist/esm-es5/verdocs-kba-dialog.entry.js +1 -1
- package/dist/esm-es5/verdocs-loader.entry.js +1 -1
- package/dist/esm-es5/verdocs-ok-dialog.entry.js +1 -1
- package/dist/esm-es5/verdocs-organization-card.entry.js +1 -1
- package/dist/esm-es5/verdocs-preview.entry.js +1 -1
- package/dist/esm-es5/verdocs-quick-functions_3.entry.js +1 -1
- package/dist/esm-es5/verdocs-radio-button.entry.js +1 -1
- package/dist/esm-es5/verdocs-search-tabs.entry.js +1 -1
- package/dist/esm-es5/verdocs-search.entry.js +1 -1
- package/dist/esm-es5/verdocs-send.entry.js +1 -1
- package/dist/esm-es5/verdocs-sign.entry.js +1 -1
- package/dist/esm-es5/verdocs-signature-dialog.entry.js +1 -1
- package/dist/esm-es5/verdocs-status-indicator.entry.js +1 -1
- package/dist/esm-es5/verdocs-template-attachments_2.entry.js +1 -0
- package/dist/esm-es5/verdocs-template-card.entry.js +1 -1
- package/dist/esm-es5/verdocs-template-document-page_2.entry.js +1 -0
- package/dist/esm-es5/verdocs-template-fields_4.entry.js +1 -0
- package/dist/esm-es5/verdocs-template-name.entry.js +1 -1
- package/dist/esm-es5/verdocs-template-properties.entry.js +1 -1
- package/dist/esm-es5/verdocs-template-reminders.entry.js +1 -1
- package/dist/esm-es5/verdocs-template-tags.entry.js +1 -1
- package/dist/esm-es5/verdocs-template-visibility.entry.js +1 -1
- package/dist/esm-es5/verdocs-toggle-button.entry.js +1 -1
- package/dist/esm-es5/verdocs-toggle.entry.js +1 -1
- package/dist/esm-es5/verdocs-upload-dialog.entry.js +1 -1
- package/dist/esm-es5/verdocs-view.entry.js +1 -1
- package/dist/esm-es5/verdocs-web-sdk.js +1 -1
- package/dist/types/components/controls/verdocs-file-chooser/verdocs-file-chooser.d.ts +23 -0
- package/dist/types/components/controls/verdocs-file-chooser/verdocs-file-chooser.stories.d.ts +6 -0
- package/dist/types/components/embeds/verdocs-auth/verdocs-auth.d.ts +3 -2
- package/dist/types/components/embeds/verdocs-build/verdocs-build.d.ts +8 -5
- package/dist/types/components/other/ipctest/ipc-test.d.ts +17 -0
- package/dist/types/components/other/ipctest/ipc-test.stories.d.ts +4 -0
- package/dist/types/components/templates/verdocs-template-attachments/verdocs-template-attachments.d.ts +27 -2
- package/dist/types/components/templates/verdocs-template-fields/verdocs-template-fields.d.ts +2 -2
- package/dist/types/components.d.ts +78 -4
- package/dist/types/utils/Icons.d.ts +8 -0
- package/dist/verdocs-web-sdk/p-01a240ac.system.js +1 -0
- package/dist/verdocs-web-sdk/{p-1fc2dcb7.entry.js → p-07715513.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-08305f4e.system.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-d4f2c4cd.entry.js → p-09382df0.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-ad6e9a9a.system.entry.js → p-09f756a2.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-1044c9ea.system.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-499022e8.entry.js → p-12aac44a.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-6b693508.system.entry.js → p-18658f1f.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-7464fd3c.system.entry.js → p-1900bbbb.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-d1f80bd5.entry.js → p-1a666173.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-c2b91d4d.system.entry.js → p-1fe5af0c.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-614368ee.system.entry.js → p-204fadd2.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-d643db3b.entry.js → p-2544faa8.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-254b91cf.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-3ca6f68d.entry.js → p-263acb59.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-5e3893ec.system.entry.js → p-26801979.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-fc67ddc9.entry.js → p-27eb5497.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-bd8ff2a6.entry.js → p-288103cc.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-7f13e92e.entry.js → p-2a2ba635.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-0464731b.system.entry.js → p-2d31b931.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-e59061aa.system.entry.js → p-2d40f2ba.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-77a2ec7e.entry.js → p-2d73b96f.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-1edbfaf5.entry.js → p-2e1b6646.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-ebce4300.entry.js → p-2f929364.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-9c36aaaa.entry.js → p-31de3afe.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-068e6212.entry.js → p-36c540fa.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-1c75e276.entry.js → p-452d6537.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-455d16dc.system.js +1 -0
- package/dist/verdocs-web-sdk/{p-9cbe4bc7.system.entry.js → p-473770b0.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-1db79af9.system.entry.js → p-47aac035.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-c2c49441.js → p-49fb6d62.js} +1 -1
- package/dist/verdocs-web-sdk/{p-527f15bb.system.entry.js → p-4afeb123.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-87f428fb.entry.js → p-4c40cfde.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-ac61df73.system.entry.js → p-4fdf4196.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-603db817.entry.js → p-4ff16721.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-567a6e7c.js +1 -0
- package/dist/verdocs-web-sdk/{p-798c0134.system.entry.js → p-59d4ad25.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-e16ad8fe.entry.js → p-5c55ff7b.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-6f511c7b.entry.js → p-5cfaf9d6.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-895ca90d.system.entry.js → p-5d755377.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-da129971.entry.js → p-5e292135.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-5e448806.system.js +1 -0
- package/dist/verdocs-web-sdk/p-637fee9b.js +1 -0
- package/dist/verdocs-web-sdk/{p-34eb8a38.entry.js → p-681c7361.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-438a5bfb.system.entry.js → p-6a26b4fd.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-6a6c8f99.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-21ad4745.entry.js → p-6c12d567.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-a3282274.system.entry.js → p-6e1a4eb1.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-6e9af353.system.js +1 -0
- package/dist/verdocs-web-sdk/{p-47bba747.entry.js → p-706044e2.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-97be89cf.entry.js → p-73995d74.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-60b59333.system.entry.js → p-773ce755.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-756d5c24.entry.js → p-7aeb1f15.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-42fa6b2f.entry.js → p-7c109ef1.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-1abcf29d.js → p-7f727073.js} +1 -1
- package/dist/verdocs-web-sdk/p-809d389e.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-f0d1c6bd.system.entry.js → p-86cba33a.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-870b157b.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-c44fd897.system.js → p-882cf708.system.js} +1 -1
- package/dist/verdocs-web-sdk/{p-d936d293.system.entry.js → p-8a48f02b.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-9b9c0ae7.entry.js → p-8aa496fb.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-0f065d24.system.entry.js → p-8c8960a3.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-227d07a2.entry.js → p-8d998322.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-658c3ab7.entry.js → p-8e89f2ce.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-e352d3f8.system.entry.js → p-8ebf7d74.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-90254335.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-2287f1bc.system.entry.js → p-93b51fba.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-96cfa8a2.system.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-201f27f6.system.js → p-a06e53f9.system.js} +1 -1
- package/dist/verdocs-web-sdk/{p-07d80297.entry.js → p-a490803a.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-e9751ec7.entry.js → p-a4e3a061.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-137664e4.system.entry.js → p-a6da9fa8.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-71a1576a.system.entry.js → p-a6f2cde3.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-60548c5f.entry.js → p-a75f3b9a.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-1e782b9d.entry.js → p-aabfb02a.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-ac888bf4.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-1ea3753f.system.entry.js → p-adb73796.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-82854066.entry.js → p-af821140.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-eff8b358.entry.js → p-b29a5587.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-a8003a10.system.entry.js → p-b2cb8889.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-b310edb5.system.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-e035df4b.js → p-b3dfe499.js} +2 -2
- package/dist/verdocs-web-sdk/{p-16f3cd2d.system.entry.js → p-b568ce5d.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-d714a804.system.entry.js → p-b6c2f196.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-b6f6c21e.system.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-37dd3108.system.entry.js → p-b89b5bde.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-7ba0c530.system.entry.js → p-beeb7c8a.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-a5a530fa.entry.js → p-bf4cdcdb.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-809947d4.system.entry.js → p-c1099ce1.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-d595eba2.system.entry.js → p-c47e1d37.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-3ef23762.system.entry.js → p-c8a56083.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-cb335fc6.system.entry.js +1 -0
- package/dist/verdocs-web-sdk/p-cf2fdb73.js +1 -0
- package/dist/verdocs-web-sdk/{p-f2f3583f.system.entry.js → p-d3402d72.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-db2b75bc.system.entry.js → p-db31b40c.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-db7fb7e4.system.entry.js +1 -0
- package/dist/verdocs-web-sdk/p-e20da92f.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-07dac8d8.entry.js → p-e44c2491.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-e9c9cdf5.entry.js → p-e604b3b5.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-a5f3f29c.entry.js → p-e9f5417d.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-a5970648.system.entry.js → p-eb41c2c8.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-f201e410.system.entry.js → p-ebd5167e.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-ed5afe17.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-ec6c0c40.system.entry.js → p-f23e0059.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-8a84234f.entry.js → p-f6306a21.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-ab6bd525.entry.js → p-f876e71d.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-78f732f3.system.entry.js → p-f9a490e7.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-56bea00a.system.entry.js → p-fbee0760.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-aa3e3ffc.system.entry.js → p-fc64e091.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-871407e9.system.js → p-fd374620.system.js} +1 -1
- package/dist/verdocs-web-sdk/{p-6ea848fe.system.entry.js → p-fe7a023d.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/verdocs-web-sdk.esm.js +1 -1
- package/dist/verdocs-web-sdk/verdocs-web-sdk.js +1 -1
- package/package.json +2 -2
- package/dist/cjs/Roles-9b593b95.js +0 -28
- package/dist/cjs/verdocs-progress-bar.cjs.entry.js +0 -23
- package/dist/cjs/verdocs-template-attachments.cjs.entry.js +0 -64
- package/dist/cjs/verdocs-template-role-properties_2.cjs.entry.js +0 -217
- package/dist/cjs/verdocs-toolbar-icon.cjs.entry.js +0 -51
- package/dist/esm/Roles-6eb459df.js +0 -24
- package/dist/esm/verdocs-progress-bar.entry.js +0 -19
- package/dist/esm/verdocs-template-attachments.entry.js +0 -60
- package/dist/esm/verdocs-template-role-properties_2.entry.js +0 -212
- package/dist/esm/verdocs-toolbar-icon.entry.js +0 -47
- package/dist/esm-es5/Roles-6eb459df.js +0 -1
- package/dist/esm-es5/TemplateStore-373c72a8.js +0 -1
- package/dist/esm-es5/verdocs-progress-bar.entry.js +0 -1
- package/dist/esm-es5/verdocs-template-attachments.entry.js +0 -1
- package/dist/esm-es5/verdocs-template-create_3.entry.js +0 -1
- package/dist/esm-es5/verdocs-template-document-page.entry.js +0 -1
- package/dist/esm-es5/verdocs-template-role-properties_2.entry.js +0 -1
- package/dist/esm-es5/verdocs-toolbar-icon.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-0714e785.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-126c0301.system.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-2413519c.system.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-27332125.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-2fc46a8b.js +0 -1
- package/dist/verdocs-web-sdk/p-5bb80e03.system.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-66c74103.system.js +0 -1
- package/dist/verdocs-web-sdk/p-6caf1137.system.js +0 -1
- package/dist/verdocs-web-sdk/p-7e8fe43e.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-8027431e.js +0 -1
- package/dist/verdocs-web-sdk/p-8229e6df.system.js +0 -1
- package/dist/verdocs-web-sdk/p-82512045.system.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-86e507c1.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-879e9572.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-91f062a8.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-920fd6d9.system.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-ba591e02.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-bcc9c2d8.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-bd35fd77.system.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-c9ff6acb.system.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-d28acca1.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-d67b2a26.system.entry.js +0 -1
- package/dist/cjs/{VerdocsEndpoint-3e95f87f.js → VerdocsEndpoint-1b1836af.js} +30 -30
- package/dist/esm/{VerdocsEndpoint-4367eb13.js → VerdocsEndpoint-ca592138.js} +30 -30
@@ -0,0 +1,200 @@
|
|
1
|
+
import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
|
2
|
+
import './Types.js';
|
3
|
+
import { c as createTemplateDocument, d as deleteTemplateDocument } from './TemplateDocuments.js';
|
4
|
+
import { V as VerdocsEndpoint } from './VerdocsEndpoint.js';
|
5
|
+
import { D as DocIcon, P as PngIcon, J as JpgIcon, a as PdfIcon, F as FileIcon, b as PageCountIcon, T as TrashIcon, d as defineCustomElement$4 } from './verdocs-file-chooser2.js';
|
6
|
+
import { g as getTemplateStore } from './TemplateStore.js';
|
7
|
+
import { S as SDKError } from './errors.js';
|
8
|
+
import { d as defineCustomElement$6 } from './verdocs-button2.js';
|
9
|
+
import { d as defineCustomElement$5 } from './verdocs-component-error2.js';
|
10
|
+
import { d as defineCustomElement$3 } from './verdocs-loader2.js';
|
11
|
+
import { d as defineCustomElement$2 } from './verdocs-ok-dialog2.js';
|
12
|
+
import { d as defineCustomElement$1 } from './verdocs-progress-bar2.js';
|
13
|
+
|
14
|
+
const verdocsTemplateAttachmentsCss = "verdocs-template-attachments{font-family:\"Inter\", -apple-system, \"Segoe UI\", \"Roboto\", \"Helvetica Neue\", sans-serif}verdocs-template-attachments h5{font-size:16px;font-weight:bold;margin:0 0 10px 0;color:#46497d}verdocs-template-attachments .attachments{margin:0 0 40px 0}verdocs-template-attachments .attachment{display:-ms-flexbox;display:flex;padding:5px 0;-webkit-column-gap:15px;-moz-column-gap:15px;column-gap:15px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;color:#33364b}verdocs-template-attachments .attachment:hover .trash-icon{display:-ms-flexbox;display:flex}verdocs-template-attachments .attachment:hover .pages{display:none}verdocs-template-attachments svg{width:28px;height:28px;fill:#5c6575;margin:2px 0 0 0}verdocs-template-attachments .file-icon{-ms-flex:0;flex:0}verdocs-template-attachments .pages{width:24px;height:24px;-ms-flex:0 0 24px;flex:0 0 24px;padding-left:4px;position:relative;margin:-10px 0 0 0}verdocs-template-attachments .pages .pages-icon{top:0;left:0;width:24px;height:24px;position:absolute}verdocs-template-attachments .pages .count{top:11px;left:7px;z-index:1;width:18px;font-size:12px;font-weight:500;position:absolute;text-align:center;letter-spacing:-2px}verdocs-template-attachments .filename{-ms-flex:1;flex:1;display:block;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;border-bottom:1px dotted #cccccc}verdocs-template-attachments .trash-icon{-ms-flex:0;flex:0;display:none}verdocs-template-attachments .trash-icon:hover{cursor:pointer}verdocs-template-attachments verdocs-file-chooser{margin:10px 0;border:2px dashed #979797}verdocs-template-attachments .loader-wrapper{background-color:#ffffff;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-webkit-box-sizing:border-box;box-sizing:border-box;position:relative;width:320px;height:320px;text-align:center;border:2px dashed #979797;-ms-flex-pack:end;justify-content:flex-end}verdocs-template-attachments .progress-wrapper{padding:20px}verdocs-template-attachments .buttons{display:-ms-flexbox;display:flex;-webkit-column-gap:8px;-moz-column-gap:8px;column-gap:8px;margin-top:16px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:end;justify-content:flex-end}verdocs-template-attachments .buttons .flex-fill{-ms-flex:1;flex:1}verdocs-template-attachments ::-webkit-input-placeholder{color:#aaaaaa}verdocs-template-attachments ::-moz-placeholder{color:#aaaaaa}verdocs-template-attachments :-ms-input-placeholder{color:#aaaaaa}verdocs-template-attachments ::-ms-input-placeholder{color:#aaaaaa}verdocs-template-attachments ::placeholder{color:#aaaaaa}";
|
15
|
+
|
16
|
+
const VerdocsTemplateAttachments = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
17
|
+
constructor() {
|
18
|
+
super();
|
19
|
+
this.__registerHost();
|
20
|
+
this.exit = createEvent(this, "exit", 7);
|
21
|
+
this.next = createEvent(this, "next", 7);
|
22
|
+
this.templateUpdate = createEvent(this, "templateUpdate", 7);
|
23
|
+
this.sdkError = createEvent(this, "sdkError", 7);
|
24
|
+
this.endpoint = VerdocsEndpoint.getDefault();
|
25
|
+
this.templateId = '';
|
26
|
+
this.uploading = false;
|
27
|
+
this.progressLabel = 'Uploading...';
|
28
|
+
this.progressPercent = 0;
|
29
|
+
this.showDeleteError = false;
|
30
|
+
this.confirmDeleteDocument = null;
|
31
|
+
this.store = null;
|
32
|
+
}
|
33
|
+
async componentWillLoad() {
|
34
|
+
var _a, _b, _c;
|
35
|
+
try {
|
36
|
+
this.endpoint.loadSession();
|
37
|
+
if (!this.templateId) {
|
38
|
+
console.log(`[ROLES] Missing required template ID ${this.templateId}`);
|
39
|
+
return;
|
40
|
+
}
|
41
|
+
if (!this.endpoint.session) {
|
42
|
+
console.log('[ROLES] Unable to start builder session, must be authenticated');
|
43
|
+
return;
|
44
|
+
}
|
45
|
+
this.store = await getTemplateStore(this.endpoint, this.templateId, false);
|
46
|
+
}
|
47
|
+
catch (e) {
|
48
|
+
console.log('[TEMPLATE ATTACHMENTS] Error loading template', e);
|
49
|
+
(_a = this.sdkError) === null || _a === void 0 ? void 0 : _a.emit(new SDKError(e.message, (_b = e.response) === null || _b === void 0 ? void 0 : _b.status, (_c = e.response) === null || _c === void 0 ? void 0 : _c.data));
|
50
|
+
}
|
51
|
+
}
|
52
|
+
handleCancel(e) {
|
53
|
+
e.stopPropagation();
|
54
|
+
this.exit.emit();
|
55
|
+
}
|
56
|
+
handleUploadProgress(percent) {
|
57
|
+
if (percent >= 99) {
|
58
|
+
this.progressPercent = 100;
|
59
|
+
this.progressLabel = 'Processing...';
|
60
|
+
}
|
61
|
+
else {
|
62
|
+
this.progressPercent = percent;
|
63
|
+
}
|
64
|
+
}
|
65
|
+
async handleUpload(e) {
|
66
|
+
var _a, _b, _c;
|
67
|
+
e.stopPropagation();
|
68
|
+
const file = e.detail.file;
|
69
|
+
if (!file) {
|
70
|
+
return;
|
71
|
+
}
|
72
|
+
console.log('[ATTACHMENTS] Uploading...', file);
|
73
|
+
this.uploading = true;
|
74
|
+
this.progressLabel = 'Uploading...';
|
75
|
+
try {
|
76
|
+
const template = await createTemplateDocument(this.endpoint, this.templateId, file, this.handleUploadProgress.bind(this));
|
77
|
+
console.log('[ATTACHMENTS] Created attachment', template);
|
78
|
+
this.store = await getTemplateStore(this.endpoint, this.templateId, true);
|
79
|
+
console.log('[ATTACHMENTS] New template', this.store.state);
|
80
|
+
this.uploading = false;
|
81
|
+
this.progressLabel = '';
|
82
|
+
this.progressPercent = 0;
|
83
|
+
}
|
84
|
+
catch (e) {
|
85
|
+
console.log('[ATTACHMENTS] Error creating template', e);
|
86
|
+
(_a = this.sdkError) === null || _a === void 0 ? void 0 : _a.emit(new SDKError(e.message, (_b = e.response) === null || _b === void 0 ? void 0 : _b.status, (_c = e.response) === null || _c === void 0 ? void 0 : _c.data));
|
87
|
+
this.uploading = false;
|
88
|
+
}
|
89
|
+
}
|
90
|
+
handleNext(e) {
|
91
|
+
var _a;
|
92
|
+
e.stopPropagation();
|
93
|
+
this.uploading = false;
|
94
|
+
this.progressLabel = '';
|
95
|
+
this.progressPercent = 0;
|
96
|
+
(_a = this.next) === null || _a === void 0 ? void 0 : _a.emit({ template: this.store.state });
|
97
|
+
}
|
98
|
+
async confirmDelete() {
|
99
|
+
await deleteTemplateDocument(this.endpoint, this.templateId, this.confirmDeleteDocument.id);
|
100
|
+
this.store = await getTemplateStore(this.endpoint, this.templateId, true);
|
101
|
+
console.log('[ATTACHMENTS] New template', this.store.state);
|
102
|
+
this.confirmDeleteDocument = null;
|
103
|
+
}
|
104
|
+
async handleDelete(document) {
|
105
|
+
var _a;
|
106
|
+
if (((_a = this.store.state) === null || _a === void 0 ? void 0 : _a.template_documents.length) > 1) {
|
107
|
+
this.confirmDeleteDocument = document;
|
108
|
+
}
|
109
|
+
else {
|
110
|
+
this.showDeleteError = true;
|
111
|
+
}
|
112
|
+
}
|
113
|
+
getFileIcon(document) {
|
114
|
+
switch (document.mime) {
|
115
|
+
case 'application/pdf':
|
116
|
+
return PdfIcon;
|
117
|
+
case 'image/jpeg':
|
118
|
+
return JpgIcon;
|
119
|
+
case 'image/png':
|
120
|
+
return PngIcon;
|
121
|
+
case 'application/msword':
|
122
|
+
case 'application/vnd.openxmlformats-officedocument.wordprocessingml.document':
|
123
|
+
return DocIcon;
|
124
|
+
}
|
125
|
+
return FileIcon;
|
126
|
+
}
|
127
|
+
render() {
|
128
|
+
var _a, _b, _c;
|
129
|
+
if (!this.endpoint.session) {
|
130
|
+
return (h(Host, null, h("verdocs-component-error", { message: "You must be authenticated to use this module." })));
|
131
|
+
}
|
132
|
+
const templateState = (_a = this.store) === null || _a === void 0 ? void 0 : _a.state;
|
133
|
+
if (!templateState.isLoaded) {
|
134
|
+
return (h(Host, { class: "loading" }, h("verdocs-loader", null)));
|
135
|
+
}
|
136
|
+
// This is meant to be a companion for larger visual experiences so we just go blank on errors for now.
|
137
|
+
if (!this.endpoint.session || !templateState.profile_id) {
|
138
|
+
return h(Host, { class: "empty" });
|
139
|
+
}
|
140
|
+
return (h(Host, null, h("h5", null, "Existing Attachments"), h("div", { class: "attachments" }, (_b = this.store) === null || _b === void 0 ? void 0 : _b.state.template_documents.map(document => (h("div", { class: "attachment" }, h("div", { class: "file-icon", innerHTML: this.getFileIcon(document) }), h("div", { class: "filename", title: document.name }, document.name), h("div", { class: "pages" }, h("div", { class: "count" }, document.page_numbers), h("div", { class: "pages-icon", innerHTML: PageCountIcon })), h("div", { class: "trash-icon", innerHTML: TrashIcon, onClick: () => this.handleDelete(document) }))))), h("h5", null, "Attach a New Document"), this.uploading ? (h("div", { class: "loader-wrapper" }, h("verdocs-loader", null), this.progressLabel && (h("div", { class: "progress-wrapper" }, h("verdocs-progress-bar", { showPercent: true, percent: this.progressPercent, label: this.progressLabel }))))) : (h("verdocs-file-chooser", { onFileSelected: e => this.handleUpload(e) })), h("div", { class: "buttons" }, h("verdocs-button", { variant: "outline", label: "Cancel", size: "small", onClick: e => this.handleCancel(e), disabled: this.uploading }), h("verdocs-button", { label: "Next", size: "small", onClick: e => this.handleNext(e), disabled: !((_c = this.store) === null || _c === void 0 ? void 0 : _c.state.template_documents.length) || this.uploading })), this.showDeleteError && (h("verdocs-ok-dialog", { heading: "Unable to Delete Attachment", message: "Templates must contain at least one attachment.", onNext: () => (this.showDeleteError = false) })), this.confirmDeleteDocument && (h("verdocs-ok-dialog", { heading: "Delete this Attachment?", message: "This operation cannot be undone. All fields placed<br />on the deleted attachment will also be removed.", onNext: () => this.confirmDelete(), showCancel: true, onExit: () => {
|
141
|
+
this.confirmDeleteDocument = null;
|
142
|
+
} }))));
|
143
|
+
}
|
144
|
+
static get style() { return verdocsTemplateAttachmentsCss; }
|
145
|
+
}, [0, "verdocs-template-attachments", {
|
146
|
+
"endpoint": [16],
|
147
|
+
"templateId": [1, "template-id"],
|
148
|
+
"uploading": [32],
|
149
|
+
"progressLabel": [32],
|
150
|
+
"progressPercent": [32],
|
151
|
+
"showDeleteError": [32],
|
152
|
+
"confirmDeleteDocument": [32],
|
153
|
+
"store": [32]
|
154
|
+
}]);
|
155
|
+
function defineCustomElement() {
|
156
|
+
if (typeof customElements === "undefined") {
|
157
|
+
return;
|
158
|
+
}
|
159
|
+
const components = ["verdocs-template-attachments", "verdocs-button", "verdocs-component-error", "verdocs-file-chooser", "verdocs-loader", "verdocs-ok-dialog", "verdocs-progress-bar"];
|
160
|
+
components.forEach(tagName => { switch (tagName) {
|
161
|
+
case "verdocs-template-attachments":
|
162
|
+
if (!customElements.get(tagName)) {
|
163
|
+
customElements.define(tagName, VerdocsTemplateAttachments);
|
164
|
+
}
|
165
|
+
break;
|
166
|
+
case "verdocs-button":
|
167
|
+
if (!customElements.get(tagName)) {
|
168
|
+
defineCustomElement$6();
|
169
|
+
}
|
170
|
+
break;
|
171
|
+
case "verdocs-component-error":
|
172
|
+
if (!customElements.get(tagName)) {
|
173
|
+
defineCustomElement$5();
|
174
|
+
}
|
175
|
+
break;
|
176
|
+
case "verdocs-file-chooser":
|
177
|
+
if (!customElements.get(tagName)) {
|
178
|
+
defineCustomElement$4();
|
179
|
+
}
|
180
|
+
break;
|
181
|
+
case "verdocs-loader":
|
182
|
+
if (!customElements.get(tagName)) {
|
183
|
+
defineCustomElement$3();
|
184
|
+
}
|
185
|
+
break;
|
186
|
+
case "verdocs-ok-dialog":
|
187
|
+
if (!customElements.get(tagName)) {
|
188
|
+
defineCustomElement$2();
|
189
|
+
}
|
190
|
+
break;
|
191
|
+
case "verdocs-progress-bar":
|
192
|
+
if (!customElements.get(tagName)) {
|
193
|
+
defineCustomElement$1();
|
194
|
+
}
|
195
|
+
break;
|
196
|
+
} });
|
197
|
+
}
|
198
|
+
defineCustomElement();
|
199
|
+
|
200
|
+
export { VerdocsTemplateAttachments as V, defineCustomElement as d };
|
@@ -80,12 +80,12 @@ const VerdocsTemplateCreate = /*@__PURE__*/ proxyCustomElement(class extends HTM
|
|
80
80
|
if (!this.endpoint.session) {
|
81
81
|
return (h(Host, null, h("verdocs-component-error", { message: "You must be authenticated to use this module." })));
|
82
82
|
}
|
83
|
-
return (h("form", { onSubmit: e => e.preventDefault(), onClick: e => e.stopPropagation(), autocomplete: "off" }, h("input", { type: "file", id: "verdocs-template-create-file", multiple: true, accept: "application/pdf", style: { display: 'none' }, onChange: e => this.handleFileChanged(e) }), this.creating ? (h("div", { class: "loader-wrapper" }, h("verdocs-loader", null), this.progressLabel && (h("div", { class: "progress-wrapper" }, h("verdocs-progress-bar", { showPercent: true, percent: this.progressPercent, label: this.progressLabel }))))) : (h("div", { class: "upload-box" }, h("div", null, h("span", { innerHTML: FileIcon })), h("div", { style: { marginTop: '20px', fontSize: '20px', fontWeight: 'bold', overflowWrap: 'anywhere' } }, this.file ? this.file.name : 'Drag a file here'), h("div", { style: {
|
83
|
+
return (h(Host, null, h("form", { onSubmit: e => e.preventDefault(), onClick: e => e.stopPropagation(), autocomplete: "off" }, h("input", { type: "file", id: "verdocs-template-create-file", multiple: true, accept: "application/pdf", style: { display: 'none' }, onChange: e => this.handleFileChanged(e) }), this.creating ? (h("div", { class: "loader-wrapper" }, h("verdocs-loader", null), this.progressLabel && (h("div", { class: "progress-wrapper" }, h("verdocs-progress-bar", { showPercent: true, percent: this.progressPercent, label: this.progressLabel }))))) : (h("div", { class: "upload-box" }, h("div", null, h("span", { innerHTML: FileIcon })), h("div", { style: { marginTop: '20px', fontSize: '20px', fontWeight: 'bold', overflowWrap: 'anywhere' } }, this.file ? this.file.name : 'Drag a file here'), h("div", { style: {
|
84
84
|
marginTop: '20px',
|
85
85
|
marginBottom: '20px',
|
86
86
|
fontSize: '16px',
|
87
87
|
height: '20px',
|
88
|
-
} }, this.file ? unicodeNBSP : 'Or, if you prefer...'), h("verdocs-button", { label: this.file ? 'Select a different file' : 'Select a file from your computer', size: "small", onClick: e => this.handleUpload(e) }))), h("div", { class: "buttons" }, h("verdocs-button", { variant: "outline", label: "Cancel", size: "small", onClick: e => this.handleCancel(e), disabled: this.creating }), h("verdocs-button", { label: "Next", size: "small", onClick: e => this.handleSubmit(e), disabled: !this.file || this.creating }))));
|
88
|
+
} }, this.file ? unicodeNBSP : 'Or, if you prefer...'), h("verdocs-button", { label: this.file ? 'Select a different file' : 'Select a file from your computer', size: "small", onClick: e => this.handleUpload(e) }))), h("div", { class: "buttons" }, h("verdocs-button", { variant: "outline", label: "Cancel", size: "small", onClick: e => this.handleCancel(e), disabled: this.creating }), h("verdocs-button", { label: "Next", size: "small", onClick: e => this.handleSubmit(e), disabled: !this.file || this.creating })))));
|
89
89
|
}
|
90
90
|
static get style() { return verdocsTemplateCreateCss; }
|
91
91
|
}, [0, "verdocs-template-create", {
|
@@ -1,59 +1,9 @@
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
|
2
2
|
import './Types.js';
|
3
|
+
import { g as getTemplateDocumentPageDisplayUri } from './TemplateDocuments.js';
|
3
4
|
import { V as VerdocsEndpoint } from './VerdocsEndpoint.js';
|
4
5
|
import { t as throttle } from './utils.js';
|
5
6
|
|
6
|
-
/**
|
7
|
-
* A TemplateDocument represents a PDF or other attachment in a Template.
|
8
|
-
*
|
9
|
-
* @module
|
10
|
-
*/
|
11
|
-
var __awaiter = (undefined && undefined.__awaiter) || function (thisArg, _arguments, P, generator) {
|
12
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
13
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
14
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
15
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
16
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
17
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
18
|
-
});
|
19
|
-
};
|
20
|
-
var __generator = (undefined && undefined.__generator) || function (thisArg, body) {
|
21
|
-
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
22
|
-
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
23
|
-
function verb(n) { return function (v) { return step([n, v]); }; }
|
24
|
-
function step(op) {
|
25
|
-
if (f) throw new TypeError("Generator is already executing.");
|
26
|
-
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
27
|
-
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
28
|
-
if (y = 0, t) op = [op[0] & 2, t.value];
|
29
|
-
switch (op[0]) {
|
30
|
-
case 0: case 1: t = op; break;
|
31
|
-
case 4: _.label++; return { value: op[1], done: false };
|
32
|
-
case 5: _.label++; y = op[1]; op = [0]; continue;
|
33
|
-
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
34
|
-
default:
|
35
|
-
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
36
|
-
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
37
|
-
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
38
|
-
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
39
|
-
if (t[2]) _.ops.pop();
|
40
|
-
_.trys.pop(); continue;
|
41
|
-
}
|
42
|
-
op = body.call(thisArg, _);
|
43
|
-
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
44
|
-
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
45
|
-
}
|
46
|
-
};
|
47
|
-
/**
|
48
|
-
* Get a display URI for a given page in a file attached to a template document. These pages are rendered server-side
|
49
|
-
* into PNG resources suitable for display in IMG tags although they may be used elsewhere. Note that these are intended
|
50
|
-
* for DISPLAY ONLY, are not legally binding documents, and do not contain any encoded metadata from participants. The
|
51
|
-
* original asset may be obtained by calling `getTemplateDocumentFile()` or similar.
|
52
|
-
*/
|
53
|
-
var getTemplateDocumentPageDisplayUri = function (endpoint, templateId, documentId, page) { return __awaiter(void 0, void 0, void 0, function () { return __generator(this, function (_a) {
|
54
|
-
return [2 /*return*/, endpoint.api.get("/templates/".concat(templateId, "/documents/").concat(documentId, "/pages/").concat(page, "/image")).then(function (r) { return r.data; })];
|
55
|
-
}); }); };
|
56
|
-
|
57
7
|
const verdocsTemplateDocumentPageCss = "verdocs-template-document-page{width:100%;position:relative}verdocs-template-document-page .verdocs-template-document-page-layer{position:absolute;top:0;left:0;right:0;bottom:0;-webkit-box-shadow:0 0 10px 5px #0000000f;box-shadow:0 0 10px 5px #0000000f}verdocs-template-document-page .verdocs-template-document-page-layer.img{width:100%}";
|
58
8
|
|
59
9
|
const VerdocsTemplateDocumentPage = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
@@ -3,6 +3,7 @@ import { i as interact } from './interact.min.js';
|
|
3
3
|
import './Types.js';
|
4
4
|
import { u as updateField, c as createField } from './Fields.js';
|
5
5
|
import { V as VerdocsEndpoint } from './VerdocsEndpoint.js';
|
6
|
+
import { i as integerSequence } from './Primitives.js';
|
6
7
|
import { a as getRoleIndex, r as renderDocumentField, c as updateCssTransform, d as defaultWidth, e as defaultHeight } from './utils.js';
|
7
8
|
import { g as getTemplateStore, a as getRoleNames } from './TemplateStore.js';
|
8
9
|
import { S as SDKError } from './errors.js';
|
@@ -69,9 +70,9 @@ const VerdocsTemplateFields = /*@__PURE__*/ proxyCustomElement(class extends HTM
|
|
69
70
|
return;
|
70
71
|
}
|
71
72
|
this.store = await getTemplateStore(this.endpoint, this.templateId, true);
|
72
|
-
console.log(`[FIELDS]
|
73
|
+
console.log(`[FIELDS] Loaded template ${this.templateId}`, this.store.state);
|
73
74
|
this.selectedRoleName = ((_d = (_c = (_b = (_a = this.store) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.roles) === null || _c === void 0 ? void 0 : _c[0]) === null || _d === void 0 ? void 0 : _d.name) || '';
|
74
|
-
console.log('Starting with role', this.selectedRoleName);
|
75
|
+
console.log('[FIELDS] Starting with role', this.selectedRoleName);
|
75
76
|
}
|
76
77
|
catch (e) {
|
77
78
|
console.log('[FIELDS] Error with preview session', e);
|
@@ -248,7 +249,7 @@ const VerdocsTemplateFields = /*@__PURE__*/ proxyCustomElement(class extends HTM
|
|
248
249
|
console.log('testing field', fieldName);
|
249
250
|
i++;
|
250
251
|
} while ((_a = this.store) === null || _a === void 0 ? void 0 : _a.state.fields.some(field => field.name === fieldName));
|
251
|
-
console.log('Will use field name', fieldName, (_b = this.store) === null || _b === void 0 ? void 0 : _b.state.fields);
|
252
|
+
console.log('Will use field name', this, fieldName, (_b = this.store) === null || _b === void 0 ? void 0 : _b.state.fields);
|
252
253
|
return fieldName;
|
253
254
|
}
|
254
255
|
// Scale the X,Y clicks to the virtual page dimensions. Also ensure the field doesn't go off the page.
|
@@ -258,17 +259,18 @@ const VerdocsTemplateFields = /*@__PURE__*/ proxyCustomElement(class extends HTM
|
|
258
259
|
const y = Math.floor(Math.min(Math.max(renderedHeight - viewY, 0) / yScale, yMax));
|
259
260
|
return { x, y };
|
260
261
|
}
|
261
|
-
async handleClickPage(e,
|
262
|
+
async handleClickPage(e, pageNumber) {
|
262
263
|
var _a, _b, _c;
|
263
264
|
if (this.placing) {
|
264
|
-
console.log('Placing field', this.
|
265
|
-
|
265
|
+
console.log('Placing field', this, this.selectedRoleName, this.placing, pageNumber, e.offsetX, e.offsetY);
|
266
|
+
// console.log('Placing field', this.placing, page.sequence, e.offsetX, e.offsetY);
|
267
|
+
// const pageNumber = page.sequence;
|
266
268
|
const clickedX = e.offsetX;
|
267
269
|
const clickedY = e.offsetY;
|
268
270
|
const width = defaultWidth(this.placing);
|
269
271
|
const height = defaultHeight(this.placing);
|
270
272
|
const cachedPage = this.cachedPageInfo[pageNumber];
|
271
|
-
console.log('Cached page', cachedPage);
|
273
|
+
// console.log('Cached page', cachedPage);
|
272
274
|
const { naturalWidth = 612, naturalHeight = 792 } = cachedPage;
|
273
275
|
const coords = this.viewCoordinatesToPageCoordinates(clickedX, clickedY, pageNumber, naturalWidth - width, naturalHeight - height);
|
274
276
|
const x = Math.floor(coords.x);
|
@@ -363,7 +365,8 @@ const VerdocsTemplateFields = /*@__PURE__*/ proxyCustomElement(class extends HTM
|
|
363
365
|
}
|
364
366
|
}
|
365
367
|
render() {
|
366
|
-
var _a, _b, _c, _d;
|
368
|
+
var _a, _b, _c, _d, _e;
|
369
|
+
console.log('[FIELDS] Rendering');
|
367
370
|
if (!this.endpoint.session) {
|
368
371
|
return (h(Host, null, h("verdocs-component-error", { message: "You must be authenticated to use this module." })));
|
369
372
|
}
|
@@ -371,9 +374,7 @@ const VerdocsTemplateFields = /*@__PURE__*/ proxyCustomElement(class extends HTM
|
|
371
374
|
if (!((_a = this.store) === null || _a === void 0 ? void 0 : _a.state.isLoaded)) {
|
372
375
|
return (h(Host, null, h("verdocs-loader", null)));
|
373
376
|
}
|
374
|
-
const
|
375
|
-
pages.sort((a, b) => a.sequence - b.sequence);
|
376
|
-
const selectableRoles = (_d = (_c = this.store) === null || _c === void 0 ? void 0 : _c.state) === null || _d === void 0 ? void 0 : _d.roles.map(role => ({ value: role.name, label: role.name }));
|
377
|
+
const selectableRoles = (_c = (_b = this.store) === null || _b === void 0 ? void 0 : _b.state) === null || _c === void 0 ? void 0 : _c.roles.map(role => ({ value: role.name, label: role.name }));
|
377
378
|
return (h(Host, { class: this.placing ? { [`placing-${this.placing}`]: true } : {}, "data-r": this.rerender, onSubmit: () => {
|
378
379
|
console.log('onSubmit');
|
379
380
|
} }, h("div", { id: "verdocs-template-fields-toolbar" }, h("div", { class: "add-for" }, "Add field:"), h("verdocs-select-input", { value: this.selectedRoleName, options: selectableRoles, onInput: (e) => (this.selectedRoleName = e.target.value) }), menuOptions.map(option => (h("verdocs-toolbar-icon", { text: option.tooltip, icon: option.icon, onClick: () => {
|
@@ -381,11 +382,12 @@ const VerdocsTemplateFields = /*@__PURE__*/ proxyCustomElement(class extends HTM
|
|
381
382
|
// We have empty tooltips on the separators, quick hack...
|
382
383
|
this.placing = option.id;
|
383
384
|
}
|
384
|
-
} })))), h("div", { class: "pages" },
|
385
|
-
|
385
|
+
} })))), h("div", { class: "pages" }, (((_e = (_d = this.store) === null || _d === void 0 ? void 0 : _d.state) === null || _e === void 0 ? void 0 : _e.template_documents) || []).map(document => {
|
386
|
+
const pageNumbers = integerSequence(1, document.page_numbers);
|
387
|
+
return pageNumbers.map(page => (h("verdocs-template-document-page", { templateId: this.templateId, documentId: document.id, pageNumber: page, virtualWidth: 612, virtualHeight: 792, onClick: (e) => this.handleClickPage(e, page), onPageRendered: e => this.handlePageRendered(e), layers: [
|
386
388
|
{ name: 'page', type: 'canvas' },
|
387
389
|
{ name: 'controls', type: 'div' },
|
388
|
-
] }));
|
390
|
+
] })));
|
389
391
|
}))));
|
390
392
|
}
|
391
393
|
static get style() { return verdocsTemplateFieldsCss; }
|
@@ -10,7 +10,7 @@ import { d as defineCustomElement$4 } from './verdocs-help-icon2.js';
|
|
10
10
|
import { d as defineCustomElement$3 } from './verdocs-loader2.js';
|
11
11
|
import { d as defineCustomElement$2 } from './verdocs-text-input2.js';
|
12
12
|
|
13
|
-
const verdocsTemplateNameCss = "
|
13
|
+
const verdocsTemplateNameCss = "";
|
14
14
|
|
15
15
|
const VerdocsTemplateName$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
16
16
|
constructor() {
|
@@ -40,7 +40,7 @@ const VerdocsTemplateProperties$1 = /*@__PURE__*/ proxyCustomElement(class exten
|
|
40
40
|
console.log('[PROPERTIES] Unable to start builder session, must be authenticated');
|
41
41
|
return;
|
42
42
|
}
|
43
|
-
this.store = await getTemplateStore(this.endpoint, this.templateId,
|
43
|
+
this.store = await getTemplateStore(this.endpoint, this.templateId, true);
|
44
44
|
this.name = (_b = (_a = this.store) === null || _a === void 0 ? void 0 : _a.state) === null || _b === void 0 ? void 0 : _b.name;
|
45
45
|
this.sendReminders = ((_d = (_c = this.store) === null || _c === void 0 ? void 0 : _c.state) === null || _d === void 0 ? void 0 : _d.reminder_id) !== null;
|
46
46
|
}
|
@@ -77,7 +77,7 @@ const VerdocsTemplateRoleProperties = /*@__PURE__*/ proxyCustomElement(class ext
|
|
77
77
|
this.email = editingRole.email;
|
78
78
|
this.phone = editingRole.phone;
|
79
79
|
this.allowDelegation = editingRole.delegator;
|
80
|
-
console.log('
|
80
|
+
console.log('[ROLES] Editing role', editingRole);
|
81
81
|
}
|
82
82
|
}
|
83
83
|
catch (e) {
|
@@ -103,23 +103,26 @@ const VerdocsTemplateRoleProperties = /*@__PURE__*/ proxyCustomElement(class ext
|
|
103
103
|
phone: this.phone,
|
104
104
|
delegator: this.allowDelegation,
|
105
105
|
})
|
106
|
-
.then(r => {
|
106
|
+
.then(async (r) => {
|
107
107
|
var _a;
|
108
|
-
console.log('Update result', r);
|
108
|
+
console.log('[ROLE_PROPERTIES] Update result', r);
|
109
109
|
this.saving = false;
|
110
110
|
this.dirty = false;
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
111
|
+
this.store = await getTemplateStore(this.endpoint, this.templateId, true);
|
112
|
+
// this.sortTemplateRoles();
|
113
|
+
// this.renumberTemplateRoles();
|
114
|
+
// const newRoles = [...this.store.state.roles];
|
115
|
+
// newRoles.forEach(role => {
|
116
|
+
// if (role.name === this.roleName) {
|
117
|
+
// role.name = this.name;
|
118
|
+
// role.type = this.type;
|
119
|
+
// role.full_name = this.fullName;
|
120
|
+
// role.email = this.email;
|
121
|
+
// role.phone = this.phone;
|
122
|
+
// role.delegator = this.allowDelegation;
|
123
|
+
// }
|
124
|
+
// });
|
125
|
+
// this.store.state.roles = newRoles;
|
123
126
|
(_a = this.close) === null || _a === void 0 ? void 0 : _a.emit();
|
124
127
|
})
|
125
128
|
.catch(e => {
|
@@ -220,12 +220,15 @@ const VerdocsTemplateRoles = /*@__PURE__*/ proxyCustomElement(class extends HTML
|
|
220
220
|
type: 'signer',
|
221
221
|
delegator: false,
|
222
222
|
})
|
223
|
-
.then(r => {
|
224
|
-
var _a, _b
|
223
|
+
.then(async (r) => {
|
224
|
+
var _a, _b;
|
225
225
|
console.log('[ROLES] Created role', r);
|
226
|
-
this.store
|
226
|
+
this.store = await getTemplateStore(this.endpoint, this.templateId, true);
|
227
|
+
this.sortTemplateRoles();
|
227
228
|
this.renumberTemplateRoles();
|
228
|
-
|
229
|
+
// this.store.state.roles = [...this.store?.state.roles, r];
|
230
|
+
// this.renumberTemplateRoles();
|
231
|
+
(_a = this.templateUpdated) === null || _a === void 0 ? void 0 : _a.emit({ event: 'created-role', endpoint: this.endpoint, template: (_b = this.store) === null || _b === void 0 ? void 0 : _b.state });
|
229
232
|
})
|
230
233
|
.catch(e => {
|
231
234
|
console.log('[ROLES] Error creating role', e);
|
@@ -247,6 +250,7 @@ const VerdocsTemplateRoles = /*@__PURE__*/ proxyCustomElement(class extends HTML
|
|
247
250
|
}
|
248
251
|
render() {
|
249
252
|
var _a, _b, _c, _d, _e, _f;
|
253
|
+
console.log('[ROLES] Rendering');
|
250
254
|
if (!this.endpoint.session) {
|
251
255
|
return (h(Host, null, h("verdocs-component-error", { message: "You must be authenticated to use this module." })));
|
252
256
|
}
|
@@ -2,6 +2,7 @@ import { proxyCustomElement, HTMLElement, createEvent, h, Host, Fragment } from
|
|
2
2
|
import { t as throttledGetEnvelope, d as cancelEnvelope } from './Envelopes.js';
|
3
3
|
import { E as EnvelopeStates } from './Types.js';
|
4
4
|
import { V as VerdocsEndpoint } from './VerdocsEndpoint.js';
|
5
|
+
import { i as integerSequence } from './Primitives.js';
|
5
6
|
import { f as saveEnvelopesAsZip, h as saveCertificate, s as saveAttachment } from './utils.js';
|
6
7
|
import { S as SDKError } from './errors.js';
|
7
8
|
import { d as defineCustomElement$5 } from './verdocs-button2.js';
|
@@ -29,25 +30,6 @@ var userCanCancelEnvelope = function (session, envelope) {
|
|
29
30
|
envelope.status !== EnvelopeStates.CANCELED;
|
30
31
|
};
|
31
32
|
|
32
|
-
/**
|
33
|
-
* Create an array containing a sequence of integers, e.g. [START, START+1, START+2, ...] This is frequently useful
|
34
|
-
* in rendering operations when there is no source array to .map() across.
|
35
|
-
*/
|
36
|
-
var integerSequence = function (start, count) {
|
37
|
-
return Array(count)
|
38
|
-
.fill(1)
|
39
|
-
.map(function (_, index) { return index + start; });
|
40
|
-
};
|
41
|
-
/**
|
42
|
-
* Generate suggested initials for a full name, e.g. "John Doe" will yield "JD".
|
43
|
-
*/
|
44
|
-
var fullNameToInitials = function (name) {
|
45
|
-
return name
|
46
|
-
.split(' ')
|
47
|
-
.map(function (word) { return word[0]; })
|
48
|
-
.join('');
|
49
|
-
};
|
50
|
-
|
51
33
|
const verdocsViewCss = "verdocs-view{display:-ms-flexbox;display:flex;overflow:hidden;min-height:600px;position:relative;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column;-webkit-box-sizing:border-box;box-sizing:border-box;font-family:\"Inter\", -apple-system, \"Segoe UI\", \"Roboto\", \"Helvetica Neue\", sans-serif}verdocs-view div,verdocs-view canvas{-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-view .document{-ms-flex:1;flex:1;width:100%;height:100%;display:-ms-flexbox;display:flex;padding:15px;row-gap:15px;min-height:200px;max-width:1200px;position:relative;overflow-y:scroll;-ms-flex-align:center;align-items:center;-webkit-box-sizing:border-box;box-sizing:border-box;-ms-flex-direction:column;flex-direction:column}verdocs-view .document .inner{width:100%;max-width:1028px}verdocs-view .loading-indicator{top:0;left:0;right:0;bottom:0;display:-ms-flexbox;display:flex;z-index:10000;position:fixed;background-color:rgba(0, 0, 0, 0.7)}#verdocs-view-header{width:100%;color:#fff;display:-ms-flexbox;display:flex;z-index:1000;-ms-flex:0 0 56px;flex:0 0 56px;padding:0 20px;font-size:12px;-webkit-column-gap:15px;-moz-column-gap:15px;column-gap:15px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;-webkit-transition:all 0.25s;transition:all 0.25s;background-color:#33354c;-webkit-box-shadow:0 4px 4px 0 rgba(0, 0, 0, 0.24), 0 0 4px 0 rgba(0, 0, 0, 0.12);box-shadow:0 4px 4px 0 rgba(0, 0, 0, 0.24), 0 0 4px 0 rgba(0, 0, 0, 0.12)}#verdocs-view-header .inner{width:100%;display:-ms-flexbox;display:flex;margin:0 auto;padding:0 20px;max-width:1200px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}#verdocs-view-header .logo{width:80px;display:none;margin:-6px 0 0 0}#verdocs-view-header .title{font-size:18px;font-weight:500;white-space:nowrap;text-overflow:ellipsis}";
|
52
34
|
|
53
35
|
const VerdocsView = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
@@ -251,4 +233,4 @@ function defineCustomElement() {
|
|
251
233
|
}
|
252
234
|
defineCustomElement();
|
253
235
|
|
254
|
-
export { VerdocsView as V, defineCustomElement as d
|
236
|
+
export { VerdocsView as V, defineCustomElement as d };
|
@@ -1,11 +1,24 @@
|
|
1
1
|
{
|
2
2
|
"version": 1.1,
|
3
3
|
"tags": [
|
4
|
+
{
|
5
|
+
"name": "ipc-test",
|
6
|
+
"description": {
|
7
|
+
"kind": "markdown",
|
8
|
+
"value": ""
|
9
|
+
},
|
10
|
+
"attributes": [
|
11
|
+
{
|
12
|
+
"name": "template-id",
|
13
|
+
"description": "The template ID to edit."
|
14
|
+
}
|
15
|
+
]
|
16
|
+
},
|
4
17
|
{
|
5
18
|
"name": "verdocs-auth",
|
6
19
|
"description": {
|
7
20
|
"kind": "markdown",
|
8
|
-
"value": "Display an authentication dialog that allows the user to login or sign up. Callbacks are provided for events that\noccur during the process (especially successful completion).
|
21
|
+
"value": "Display an authentication dialog that allows the user to login or sign up. Callbacks are provided for events that\noccur during the process (especially successful completion). If the user is already authenticated with a valid\nsession, this component will hide itself and fire the success callback immediately. It is up to the host application\nto render the next appropriate view for the application.\n\nTo simplify some types of authentication flows, a visibility flag can force this component to never display. This\nallows you to susbcribe to notifications from the\n\nThis embed is responsive / mobile-friendly, but the calling application should provide at least a 300px wide\ncontainer to allow sufficient space for the required forms.\n\nAs noted below, the primary event is `authenticated`. This will always be fired at least once, immediately after\nthe widget is rendered and the user's status has been checked. It may be fired again as the user completes (or\ncancels) authentication steps.\n\nAuthentication is required to demonstrate this Element. You may do this in Storybook by using the Auth\nembed. This Element will reuse the same session produced by logging in via that Embed.\n\n```typescript\ninterface IAuthStatus {\n // If true, the user is authenticated with a valid session\n authenticated: boolean;\n\n // Details for the user's session\n session: IActiveSession | null;\n}\n```"
|
9
22
|
},
|
10
23
|
"attributes": [
|
11
24
|
{
|
@@ -25,9 +38,33 @@
|
|
25
38
|
"value": "Display a template building experience."
|
26
39
|
},
|
27
40
|
"attributes": [
|
41
|
+
{
|
42
|
+
"name": "step",
|
43
|
+
"description": "The step in the creation process to display.",
|
44
|
+
"values": [
|
45
|
+
{
|
46
|
+
"name": "attachments"
|
47
|
+
},
|
48
|
+
{
|
49
|
+
"name": "create"
|
50
|
+
},
|
51
|
+
{
|
52
|
+
"name": "fields"
|
53
|
+
},
|
54
|
+
{
|
55
|
+
"name": "preview"
|
56
|
+
},
|
57
|
+
{
|
58
|
+
"name": "roles"
|
59
|
+
},
|
60
|
+
{
|
61
|
+
"name": "settings"
|
62
|
+
}
|
63
|
+
]
|
64
|
+
},
|
28
65
|
{
|
29
66
|
"name": "template-id",
|
30
|
-
"description": "The ID of the template to create the document from."
|
67
|
+
"description": "The ID of the template to create the document from. Unlike most other components, this is an optional parameter here.\nIf the template ID is known, `step` may also be specified to force displaying a specific step in the creation process.\nIf it is not specified, `step` will be ignored and the create step will be shown."
|
31
68
|
}
|
32
69
|
]
|
33
70
|
},
|
@@ -687,6 +724,14 @@
|
|
687
724
|
}
|
688
725
|
]
|
689
726
|
},
|
727
|
+
{
|
728
|
+
"name": "verdocs-file-chooser",
|
729
|
+
"description": {
|
730
|
+
"kind": "markdown",
|
731
|
+
"value": "Displays a file picker to upload an attachment. This component is just the picker - the host application or component should\nprovide the actual upload functionality."
|
732
|
+
},
|
733
|
+
"attributes": []
|
734
|
+
},
|
690
735
|
{
|
691
736
|
"name": "verdocs-floating-menu",
|
692
737
|
"description": {
|