@verdocs/web-sdk 5.0.9 → 5.0.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/{Datastore-5b860927.js → Datastore-4448f6ef.js} +3 -3
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{utils-30de2530.js → utils-746daf30.js} +1 -0
- package/dist/cjs/verdocs-build.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-checkbox_6.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-contact-picker_2.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-envelope-document-page.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-envelope-recipient-link_2.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-envelope-recipient-summary.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-envelope-sidebar.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-envelopes-list.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-field-attachment_13.cjs.entry.js +27 -15
- package/dist/cjs/verdocs-field-payment.cjs.entry.js +3 -2
- package/dist/cjs/verdocs-kba-dialog_2.cjs.entry.js +2 -2
- package/dist/cjs/verdocs-menu-panel_2.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-pagination_2.cjs.entry.js +1 -1
- package/dist/cjs/verdocs-preview_6.cjs.entry.js +2 -2
- package/dist/cjs/verdocs-sign.cjs.entry.js +2 -2
- package/dist/cjs/verdocs-template-document-page_2.cjs.entry.js +2 -2
- package/dist/cjs/verdocs-web-sdk.cjs.js +1 -1
- package/dist/collection/components/fields/verdocs-field-attachment/verdocs-field-attachment.js +24 -1
- package/dist/collection/components/fields/verdocs-field-checkbox/verdocs-field-checkbox.js +24 -1
- package/dist/collection/components/fields/verdocs-field-date/verdocs-field-date.js +1 -1
- package/dist/collection/components/fields/verdocs-field-dropdown/verdocs-field-dropdown.js +24 -1
- package/dist/collection/components/fields/verdocs-field-initial/verdocs-field-initial.js +24 -1
- package/dist/collection/components/fields/verdocs-field-payment/verdocs-field-payment.js +24 -1
- package/dist/collection/components/fields/verdocs-field-radio/verdocs-field-radio.js +24 -1
- package/dist/collection/components/fields/verdocs-field-signature/verdocs-field-signature.js +24 -1
- package/dist/collection/components/fields/verdocs-field-textarea/verdocs-field-textarea.js +27 -3
- package/dist/collection/components/fields/verdocs-field-textbox/verdocs-field-textbox.js +28 -3
- package/dist/collection/components/fields/verdocs-field-timestamp/verdocs-field-timestamp.js +24 -1
- package/dist/collection/utils/Datastore.js +3 -3
- package/dist/collection/utils/utils.js +1 -0
- package/dist/components/{p-15b1e7a0.js → p-0689fc47.js} +2 -2
- package/dist/components/{p-ec56d92f.js → p-0ed0ac8b.js} +13 -13
- package/dist/components/{p-c9a4ef35.js → p-14c80ae8.js} +5 -3
- package/dist/components/{p-7246d2ee.js → p-176a07b2.js} +3 -3
- package/dist/components/{p-f21ef4fb.js → p-211fa3e2.js} +5 -3
- package/dist/components/{p-5df09a0d.js → p-261521bc.js} +5 -3
- package/dist/components/{p-d9074622.js → p-27548ebd.js} +1 -1
- package/dist/components/{p-ca8e3721.js → p-2ddf4d5b.js} +5 -3
- package/dist/components/{p-9c37d4b3.js → p-314d698d.js} +1 -1
- package/dist/components/{p-6506ddb4.js → p-5182136e.js} +5 -3
- package/dist/components/{p-b712e729.js → p-58d027d1.js} +3 -3
- package/dist/components/{p-e36c8c69.js → p-5e378f0e.js} +5 -3
- package/dist/components/{p-f7462b26.js → p-6c4fe42c.js} +1 -1
- package/dist/components/{p-052fcdac.js → p-7cd6c0ce.js} +1 -1
- package/dist/components/{p-005c3387.js → p-9bcf9620.js} +1 -1
- package/dist/components/{p-fca85ba0.js → p-a55f08ad.js} +14 -14
- package/dist/components/{p-eefda339.js → p-a60453aa.js} +2 -2
- package/dist/components/{p-ed4f91be.js → p-adf1586f.js} +1 -1
- package/dist/components/{p-093d51c8.js → p-af5ecc92.js} +1 -0
- package/dist/components/{p-332a97b3.js → p-b99b485b.js} +1 -1
- package/dist/components/{p-6c18617e.js → p-c1159428.js} +9 -5
- package/dist/components/{p-1a77c51b.js → p-c662e5f4.js} +3 -3
- package/dist/components/{p-60eb7451.js → p-c76fab71.js} +13 -13
- package/dist/components/{p-053a0408.js → p-d8340641.js} +5 -3
- package/dist/components/{p-b36c979b.js → p-d9a2e920.js} +8 -5
- package/dist/components/{p-5654568d.js → p-efa3b8ac.js} +1 -1
- package/dist/components/verdocs-build.js +21 -21
- package/dist/components/verdocs-contact-picker.js +1 -1
- package/dist/components/verdocs-envelope-document-page.js +1 -1
- package/dist/components/verdocs-envelope-recipient-link.js +1 -1
- package/dist/components/verdocs-envelope-recipient-summary.js +1 -1
- package/dist/components/verdocs-envelope-sidebar.js +2 -2
- package/dist/components/verdocs-envelopes-list.js +2 -2
- package/dist/components/verdocs-field-attachment.js +1 -1
- package/dist/components/verdocs-field-checkbox.js +1 -1
- package/dist/components/verdocs-field-date.js +1 -1
- package/dist/components/verdocs-field-dropdown.js +1 -1
- package/dist/components/verdocs-field-initial.js +1 -1
- package/dist/components/verdocs-field-payment.js +5 -3
- package/dist/components/verdocs-field-radio.js +1 -1
- package/dist/components/verdocs-field-signature.js +1 -1
- package/dist/components/verdocs-field-textarea.js +1 -1
- package/dist/components/verdocs-field-textbox.js +1 -1
- package/dist/components/verdocs-field-timestamp.js +1 -1
- package/dist/components/verdocs-preview.js +1 -1
- package/dist/components/verdocs-quick-filter.js +1 -1
- package/dist/components/verdocs-send.js +1 -1
- package/dist/components/verdocs-sign.js +4 -4
- package/dist/components/verdocs-template-attachments.js +1 -1
- package/dist/components/verdocs-template-build-tabs.js +1 -1
- package/dist/components/verdocs-template-document-page.js +1 -1
- package/dist/components/verdocs-template-field-properties.js +1 -1
- package/dist/components/verdocs-template-fields.js +1 -1
- package/dist/components/verdocs-template-role-properties.js +1 -1
- package/dist/components/verdocs-template-roles.js +1 -1
- package/dist/components/verdocs-templates-list.js +1 -1
- package/dist/components/verdocs-view.js +1 -1
- package/dist/esm/{Datastore-d29d4aeb.js → Datastore-b55570ff.js} +3 -3
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{utils-a5f5c427.js → utils-bd656c37.js} +1 -0
- package/dist/esm/verdocs-build.entry.js +1 -1
- package/dist/esm/verdocs-checkbox_6.entry.js +1 -1
- package/dist/esm/verdocs-contact-picker_2.entry.js +1 -1
- package/dist/esm/verdocs-envelope-document-page.entry.js +1 -1
- package/dist/esm/verdocs-envelope-recipient-link_2.entry.js +1 -1
- package/dist/esm/verdocs-envelope-recipient-summary.entry.js +1 -1
- package/dist/esm/verdocs-envelope-sidebar.entry.js +1 -1
- package/dist/esm/verdocs-envelopes-list.entry.js +1 -1
- package/dist/esm/verdocs-field-attachment_13.entry.js +27 -15
- package/dist/esm/verdocs-field-payment.entry.js +3 -2
- package/dist/esm/verdocs-kba-dialog_2.entry.js +2 -2
- package/dist/esm/verdocs-menu-panel_2.entry.js +1 -1
- package/dist/esm/verdocs-pagination_2.entry.js +1 -1
- package/dist/esm/verdocs-preview_6.entry.js +2 -2
- package/dist/esm/verdocs-sign.entry.js +2 -2
- package/dist/esm/verdocs-template-document-page_2.entry.js +2 -2
- package/dist/esm/verdocs-web-sdk.js +1 -1
- package/dist/esm-es5/{Datastore-d29d4aeb.js → Datastore-b55570ff.js} +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/{utils-a5f5c427.js → utils-bd656c37.js} +1 -1
- package/dist/esm-es5/verdocs-build.entry.js +1 -1
- package/dist/esm-es5/verdocs-checkbox_6.entry.js +1 -1
- package/dist/esm-es5/verdocs-contact-picker_2.entry.js +1 -1
- package/dist/esm-es5/verdocs-envelope-document-page.entry.js +1 -1
- package/dist/esm-es5/verdocs-envelope-recipient-link_2.entry.js +1 -1
- package/dist/esm-es5/verdocs-envelope-recipient-summary.entry.js +1 -1
- package/dist/esm-es5/verdocs-envelope-sidebar.entry.js +1 -1
- package/dist/esm-es5/verdocs-envelopes-list.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-attachment_13.entry.js +1 -1
- package/dist/esm-es5/verdocs-field-payment.entry.js +1 -1
- package/dist/esm-es5/verdocs-kba-dialog_2.entry.js +1 -1
- package/dist/esm-es5/verdocs-menu-panel_2.entry.js +1 -1
- package/dist/esm-es5/verdocs-pagination_2.entry.js +1 -1
- package/dist/esm-es5/verdocs-preview_6.entry.js +1 -1
- package/dist/esm-es5/verdocs-sign.entry.js +1 -1
- package/dist/esm-es5/verdocs-template-document-page_2.entry.js +1 -1
- package/dist/esm-es5/verdocs-web-sdk.js +1 -1
- package/dist/types/components/fields/verdocs-field-attachment/verdocs-field-attachment.d.ts +6 -1
- package/dist/types/components/fields/verdocs-field-checkbox/verdocs-field-checkbox.d.ts +6 -1
- package/dist/types/components/fields/verdocs-field-dropdown/verdocs-field-dropdown.d.ts +6 -1
- package/dist/types/components/fields/verdocs-field-initial/verdocs-field-initial.d.ts +6 -1
- package/dist/types/components/fields/verdocs-field-payment/verdocs-field-payment.d.ts +6 -1
- package/dist/types/components/fields/verdocs-field-radio/verdocs-field-radio.d.ts +6 -1
- package/dist/types/components/fields/verdocs-field-signature/verdocs-field-signature.d.ts +6 -1
- package/dist/types/components/fields/verdocs-field-textarea/verdocs-field-textarea.d.ts +7 -2
- package/dist/types/components/fields/verdocs-field-textbox/verdocs-field-textbox.d.ts +6 -1
- package/dist/types/components/fields/verdocs-field-timestamp/verdocs-field-timestamp.d.ts +6 -1
- package/dist/types/components.d.ts +82 -2
- package/dist/types/utils/Datastore.d.ts +3 -6
- package/dist/verdocs-web-sdk/{p-917aab58.system.entry.js → p-00ed440b.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-cfed8cc1.js → p-0c45b79c.js} +1 -1
- package/dist/verdocs-web-sdk/{p-5b0cd815.system.entry.js → p-19462841.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-42b157d2.entry.js → p-1eb501c3.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-66bf3ba8.system.entry.js → p-2b7edf3a.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-2224ca6d.entry.js → p-2d7d0805.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-fe48c408.entry.js → p-35903760.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-55de8cd1.system.js → p-35dcb386.system.js} +1 -1
- package/dist/verdocs-web-sdk/{p-7e73805f.system.entry.js → p-3cc50f0b.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-51c97029.entry.js → p-4a960ba5.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-660bda06.entry.js → p-553a341c.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-b712e729.js → p-58d027d1.js} +1 -1
- package/dist/verdocs-web-sdk/{p-c94b0dc5.system.entry.js → p-6b4de004.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-27da4a2b.entry.js → p-6da00869.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-a8809e33.entry.js → p-7688bc89.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-c2766b5a.entry.js → p-786bacad.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-7abbdb69.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-c253ae24.system.entry.js → p-7b1e00e5.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-8bdd951b.system.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-5ce491ac.system.entry.js → p-8d7d61ee.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-5aa76635.system.entry.js → p-9021fc7b.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-f40fe8d7.entry.js → p-91977069.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-95ba9c43.entry.js → p-9233595a.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-6546599d.entry.js → p-94ffe928.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-87ac8456.entry.js → p-a4b05f08.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-b0436bc7.entry.js +1 -0
- package/dist/verdocs-web-sdk/{p-899617aa.system.entry.js → p-b0fbfc24.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-62217123.system.entry.js → p-ba92b80b.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-c60743ac.system.entry.js → p-bbf30adc.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-e2b70dfb.system.js +1 -1
- package/dist/verdocs-web-sdk/{p-f3b5052f.system.entry.js → p-e3077c5e.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-b029989a.system.entry.js → p-ea078594.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-bea73364.entry.js → p-ea75f159.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-cb7aa6b8.system.entry.js → p-eb3ceb39.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-fc90cc87.entry.js → p-ef7813ed.entry.js} +1 -1
- package/dist/verdocs-web-sdk/{p-736a2c41.system.js → p-f29eb00a.system.js} +1 -1
- package/dist/verdocs-web-sdk/{p-ff8143df.system.entry.js → p-fda9c437.system.entry.js} +1 -1
- package/dist/verdocs-web-sdk/verdocs-web-sdk.esm.js +1 -1
- package/package.json +1 -1
- package/dist/verdocs-web-sdk/p-30c3f624.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-9dabaa06.entry.js +0 -1
- package/dist/verdocs-web-sdk/p-c3f825d4.system.entry.js +0 -1
@@ -1 +1 @@
|
|
1
|
-
var __assign=this&&this.__assign||function(){__assign=Object.assign||function(e){for(var n,i=1,t=arguments.length;i<t;i++){n=arguments[i];for(var s in n)if(Object.prototype.hasOwnProperty.call(n,s))e[s]=n[s]}return e};return __assign.apply(this,arguments)};var __awaiter=this&&this.__awaiter||function(e,n,i,t){function s(e){return e instanceof i?e:new i((function(n){n(e)}))}return new(i||(i=Promise))((function(i,a){function o(e){try{l(t.next(e))}catch(e){a(e)}}function r(e){try{l(t["throw"](e))}catch(e){a(e)}}function l(e){e.done?i(e.value):s(e.value).then(o,r)}l((t=t.apply(e,n||[])).next())}))};var __generator=this&&this.__generator||function(e,n){var i={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},t,s,a,o;return o={next:r(0),throw:r(1),return:r(2)},typeof Symbol==="function"&&(o[Symbol.iterator]=function(){return this}),o;function r(e){return function(n){return l([e,n])}}function l(r){if(t)throw new TypeError("Generator is already executing.");while(o&&(o=0,r[0]&&(i=0)),i)try{if(t=1,s&&(a=r[0]&2?s["return"]:r[0]?s["throw"]||((a=s["return"])&&a.call(s),0):s.next)&&!(a=a.call(s,r[1])).done)return a;if(s=0,a)r=[r[0]&2,a.value];switch(r[0]){case 0:case 1:a=r;break;case 4:i.label++;return{value:r[1],done:false};case 5:i.label++;s=r[1];r=[0];continue;case 7:r=i.ops.pop();i.trys.pop();continue;default:if(!(a=i.trys,a=a.length>0&&a[a.length-1])&&(r[0]===6||r[0]===2)){i=0;continue}if(r[0]===3&&(!a||r[1]>a[0]&&r[1]<a[3])){i.label=r[1];break}if(r[0]===6&&i.label<a[1]){i.label=a[1];a=r;break}if(a&&i.label<a[2]){i.label=a[2];i.ops.push(r);break}if(a[2])i.ops.pop();i.trys.pop();continue}r=n.call(e,i)}catch(e){r=[6,e];s=0}finally{t=a=0}if(r[0]&5)throw r[1];return{value:r[0]?r[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(e,n,i){if(i||arguments.length===2)for(var t=0,s=n.length,a;t<s;t++){if(a||!(t in n)){if(!a)a=Array.prototype.slice.call(n,0,t);a[t]=n[t]}}return e.concat(a||Array.prototype.slice.call(n))};System.register(["./p-9186f42e.system.js","@verdocs/js-sdk","./p-736a2c41.system.js","./p-9b26e4e0.system.js","./p-c8a15cb7.system.js","./p-21b1acec.system.js","./p-d738b5db.system.js","./p-2c5350ec.system.js"],(function(e){"use strict";var n,i,t,s,a,o,r,l,c,d,f,p,u,v,h;return{setters:[function(e){n=e.r;i=e.c;t=e.h;s=e.H},function(e){a=e.VerdocsEndpoint;o=e.getEnvelopes;r=e.integerSequence;l=e.getRecipientsWithActions;c=e.userCanCancelEnvelope;d=e.userCanAct;f=e.formatFullName;p=e.cancelEnvelope},function(e){u=e.s},function(e){v=e.V},function(e){h=e.S},function(){},function(){},function(){}],execute:function(){var b='@-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-envelopes-list{display:-ms-flexbox;display:flex;padding:10px;font-size:18px;-ms-flex-wrap:nowrap;flex-wrap:nowrap;border-radius:6px;color:#33364b;-ms-flex-direction:column;flex-direction:column;font-family:"Inter", "Barlow", sans-serif}@media screen and (max-width: 800px){verdocs-envelopes-list{font-size:14px}}verdocs-envelopes-list .envelope-placeholder{height:48px;-ms-flex:0 0 48px;flex:0 0 48px;margin:5px 0;border-radius:5px;background:#f5f5fa}verdocs-envelopes-list .header{width:100%;row-gap:4px;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;-webkit-column-gap:12px;-moz-column-gap:12px;column-gap:12px;margin:0 0 10px 0;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}verdocs-envelopes-list .header .filter{width:300px}verdocs-envelopes-list .header verdocs-text-input{margin:0}verdocs-envelopes-list .header verdocs-text-input input{height:32px}verdocs-envelopes-list .filter{-ms-flex-align:center;align-items:center}verdocs-envelopes-list .envelope{width:100%;margin:3px 0;background:#ffffff}verdocs-envelopes-list .envelope:hover{cursor:pointer;background:#f5f5fa}verdocs-envelopes-list .envelope .inner{gap:12px;display:-ms-flexbox;display:flex;padding:8px 14px;border-radius:5px;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:center;align-items:center;container-type:inline-size}verdocs-envelopes-list .envelope .inner svg{width:24px;height:24px}verdocs-envelopes-list .vert-spacer{height:50px;display:-ms-flexbox;display:flex;-ms-flex:0 0 1px;flex:0 0 1px;border-right:1px solid #dad8dd}@media screen and (max-width: 800px){verdocs-envelopes-list .vert-spacer{display:none}}@media screen and (max-width: 800px){verdocs-envelopes-list .envelope-icon{display:none}}@media screen and (max-width: 800px){verdocs-envelopes-list verdocs-checkbox{display:none}}verdocs-envelopes-list .last-modified{color:#444;display:-ms-flexbox;display:flex;-ms-flex:0 0 180px;flex:0 0 180px;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:center;align-items:center;white-space:nowrap}@media screen and (max-width: 800px){verdocs-envelopes-list .last-modified{display:none}}verdocs-envelopes-list .envelope-name{-ms-flex:1;flex:1;display:-ms-flexbox;display:flex;color:#000000;line-height:28px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}verdocs-envelopes-list .envelope-recipients{color:#4b5563;font-weight:700;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}verdocs-envelopes-list .empty-text{text-align:center;margin:16px 0 0 0;padding:80px 80px;border:2px solid #ccc}verdocs-envelopes-list .containing{gap:12px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}@media screen and (max-width: 800px){verdocs-envelopes-list verdocs-status-indicator{font-size:14px}}';var x=b;var g='<svg xmlns="http://www.w3.org/2000/svg" fill="none" stroke="#000000" viewBox="0 0 24 24" stroke-width="1.5"><path stroke-linecap="round" stroke-linejoin="round" d="M9 12h3.75M9 15h3.75M9 18h3.75m3 .75H18a2.25 2.25 0 002.25-2.25V6.108c0-1.135-.845-2.098-1.976-2.192a48.424 48.424 0 00-1.123-.08m-5.801 0c-.065.21-.1.433-.1.664 0 .414.336.75.75.75h4.5a.75.75 0 00.75-.75 2.25 2.25 0 00-.1-.664m-5.8 0A2.251 2.251 0 0113.5 2.25H15c1.012 0 1.867.668 2.15 1.586m-5.8 0c-.376.023-.75.05-1.124.08C9.095 4.01 8.25 4.973 8.25 6.108V8.25m0 0H4.875c-.621 0-1.125.504-1.125 1.125v11.25c0 .621.504 1.125 1.125 1.125h9.75c.621 0 1.125-.504 1.125-1.125V9.375c0-.621-.504-1.125-1.125-1.125H8.25zM6.75 12h.008v.008H6.75V12zm0 3h.008v.008H6.75V15zm0 3h.008v.008H6.75V18z" /></svg>';var m=[{value:"all",label:"All"},{value:"inbox",label:"Inbox"},{value:"sent",label:"Sent"},{value:"completed",label:"Completed"},{value:"action",label:"Action Required"},{value:"waiting",label:"Waiting on Others"}];var w=[{value:"all",label:"All"},{value:"pending",label:"Pending"},{value:"in progress",label:"In Progress"},{value:"complete",label:"Completed"},{value:"declined",label:"Declined"},{value:"canceled",label:"Canceled"}];var y=[{value:"created_at",label:"Created"},{value:"updated_at",label:"Updated"},{value:"canceled_at",label:"Canceled"},{value:"envelope_name",label:"Name"},{value:"envelope_status",label:"Status"}];var _=e("verdocs_envelopes_list",function(){function e(e){n(this,e);this.changeView=i(this,"changeView",7);this.changeStatus=i(this,"changeStatus",7);this.changeSort=i(this,"changeSort",7);this.changeMatch=i(this,"changeMatch",7);this.sdkError=i(this,"sdkError",7);this.viewEnvelope=i(this,"viewEnvelope",7);this.finishEnvelope=i(this,"finishEnvelope",7);this.endpoint=a.getDefault();this.view=undefined;this.status="all";this.sort="created_at";this.match="";this.showPagination=true;this.rowsPerPage=10;this.selectedPage=0;this.count=0;this.initiallyLoaded=false;this.loading=true;this.selectedEnvelopes=[];this.envelopes=[]}e.prototype.handleViewUpdated=function(){return this.queryEnvelopes()};e.prototype.handleStatusUpdated=function(){return this.queryEnvelopes()};e.prototype.handleSortUpdated=function(){return this.queryEnvelopes()};e.prototype.handleMatchUpdated=function(){return this.queryEnvelopes()};e.prototype.handlePageUpdated=function(){return this.queryEnvelopes()};e.prototype.componentWillLoad=function(){this.endpoint.onSessionChanged((function(e,n,i){console.log("[ENVELOPES_LIST] onSessionChanged",n,i)}));this.endpoint.loadSession()};e.prototype.componentDidLoad=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return[4,this.queryEnvelopes()];case 1:e.sent();this.initiallyLoaded=true;return[2]}}))}))};e.prototype.queryEnvelopes=function(){return __awaiter(this,void 0,void 0,(function(){var e,n,i,t,s,a;return __generator(this,(function(r){switch(r.label){case 0:r.trys.push([0,2,,3]);this.loading=true;t={page:this.selectedPage,rows:this.rowsPerPage};switch(this.view){case"all":t=__assign(__assign({},t),{status:this.status==="all"?["pending","in progress","complete","declined","canceled"]:[this.status]});break;case"inbox":t=__assign({},t);break;case"sent":t=__assign({},t);break;case"action":t=__assign(__assign({},t),{status:["pending","in progress"]});break;case"waiting":t=__assign(__assign({},t),{status:["pending","in progress"]});break;case"completed":t=__assign(__assign({},t),{status:["complete"]});break;default:t=__assign(__assign({},t),{status:this.status==="all"?["pending","in progress","complete","declined","canceled"]:[this.status]})}if(this.view==="all"){if(this.status!=="all"){t.status=[this.status]}}if(this.match.trim());return[4,o(this.endpoint,t)];case 1:s=r.sent();this.envelopes=s.envelopes;this.count=s.count;this.loading=false;return[3,3];case 2:a=r.sent();this.loading=false;console.log("[ENVELOPES] Error listing envelopes",a);(e=this.sdkError)===null||e===void 0?void 0:e.emit(new h(a.message,(n=a.response)===null||n===void 0?void 0:n.status,(i=a.response)===null||i===void 0?void 0:i.data));return[3,3];case 3:return[2]}}))}))};e.prototype.handleDownload=function(){var e=this;u(this.endpoint,this.selectedEnvelopes).then((function(){e.selectedEnvelopes=[]})).catch((function(e){console.log("[ENVELOPES] Download error",e);v("Download error: "+e.message,{style:"error"})}))};e.prototype.downloadEnvelope=function(e){u(this.endpoint,[e]).catch((function(e){console.log("[ENVELOPES] Download error",e);v("Download error: "+e.message,{style:"error"})}))};e.prototype.render=function(){var e=this;return t(s,{key:"13cff825b9a325bb5b45e7c26420276bfb7da9ed"},t("div",{key:"1c5373c8a470db467d32597647aa386efb1b9e17",class:"header"},t("div",{key:"4c394a9bf835ce0145b5b11f0bb2d5386134d1fe",class:"filter"},t("verdocs-text-input",{key:"24a0f7b03fa759478824ca79a1e1939ee986fb6a",id:"verdocs-filter-name",value:this.match,clearable:true,autocomplete:"off",placeholder:"Filter by Name, Recipient, or Field...",onFocusout:function(n){var i;e.match=n.target.value.trim();(i=e.changeMatch)===null||i===void 0?void 0:i.emit(e.match)}})),t("verdocs-quick-filter",{key:"437393b3d6019e0891def40a6d3eba7fa3d480e9",label:"View",value:this.view,options:m,onOptionSelected:function(n){e.view=n.detail.value}}),this.view==="all"&&t("verdocs-quick-filter",{key:"aec9971bcdfa2a7f444f22e0a6bba6b9007eef04",label:"Status",value:this.status,options:w,onOptionSelected:function(n){e.status=n.detail.value}}),this.view==="all"&&t("verdocs-quick-filter",{key:"10bb4001fadd7ca49547a7343a7322bcc941c3f6",label:"Sort By",value:this.sort,options:y,onOptionSelected:function(n){e.sort=n.detail.value}}),this.loading&&t("verdocs-spinner",{key:"2181c646258f4c9949eec73fd83ca83d16186170",mode:"dark",size:24}),t("div",{key:"ba7761ae3b1e9e503c00efb2107883e2ea7e0682",style:{display:"flex",flex:"1"}}),this.selectedEnvelopes.length>0&&t("verdocs-button",{key:"7124f4e1533b0f76d9bc098504063d360f49107e",label:"Download (".concat(this.selectedEnvelopes.length,")"),onClick:function(){return e.handleDownload()}})),this.envelopes.map((function(n){var i;var s=l(n);var a=c(e.endpoint.profile,n);var o=s.find((function(n){var i;return n.email===((i=e.endpoint.session)===null||i===void 0?void 0:i.email)||""}));var r=o&&a&&d(((i=e.endpoint.session)===null||i===void 0?void 0:i.email)||"",s);var u=[{label:"View Envelope",id:"view"},{label:"Finish Envelope",id:"finish",disabled:!r},{label:"Download",id:"download"},{label:"Cancel",id:"cancel",disabled:!a}];return t("div",{class:"envelope",key:n.id,onClick:function(){var i;return(i=e.viewEnvelope)===null||i===void 0?void 0:i.emit({endpoint:e.endpoint,envelope:n})}},t("div",{class:"inner"},t("verdocs-checkbox",{checked:e.selectedEnvelopes.findIndex((function(e){return e.id===n.id}))!==-1,onClick:function(e){return e.stopPropagation()},onInput:function(i){if(i.target.checked){e.selectedEnvelopes=__spreadArray(__spreadArray([],e.selectedEnvelopes,true),[n],false)}else{e.selectedEnvelopes=e.selectedEnvelopes.filter((function(e){return e.id!==n.id}))}}}),t("div",{class:"vert-spacer"}),t("span",{innerHTML:g,class:"envelope-icon"}),t("div",{class:"envelope-name"},n.name,": ",t("div",{class:"envelope-recipients"},n.recipients.map((function(e){return f(e)})))),t("div",{class:"vert-spacer"}),t("verdocs-status-indicator",{envelope:n,style:{width:"125px"}}),t("div",{class:"vert-spacer"}),t("div",{class:"last-modified"},new Date(n.updated_at).toLocaleString()),t("div",{class:"vert-spacer"}),t("verdocs-dropdown",{options:u,onOptionSelected:function(i){var t,s;switch(i.detail.id){case"view":(t=e.viewEnvelope)===null||t===void 0?void 0:t.emit({endpoint:e.endpoint,envelope:n});break;case"finish":(s=e.finishEnvelope)===null||s===void 0?void 0:s.emit({endpoint:e.endpoint,envelope:n});break;case"download":e.downloadEnvelope(n);break;case"cancel":if(window.confirm("Are you sure you want to cancel this envelope?")){p(e.endpoint,n.id).then((function(){return v("Envelope canceled")})).catch((function(e){return v("Unable to cancel envelope: "+e.messabge,{style:"error"})}));e.queryEnvelopes().catch((function(){}))}break}}})))})),!this.initiallyLoaded&&t("div",{key:"598ffddf4adeb704ba272938b41cf2403e97f169",style:{width:"100%"}},r(0,this.rowsPerPage).map((function(){return t("div",{class:"envelope-placeholder"})}))),this.initiallyLoaded&&!this.envelopes.length&&t("div",{key:"dde715119c5f62fd0dab1b960ec8ea25ae815c3e",class:"empty-text"},"No matching envelopes found. Please adjust your filters and try again."),this.initiallyLoaded&&this.envelopes.length&&this.showPagination?t("div",{style:{marginTop:"20px"}},t("verdocs-pagination",{selectedPage:this.selectedPage,perPage:this.rowsPerPage,itemCount:this.count,onSelectPage:function(n){e.selectedPage=n.detail.selectedPage}})):t("div",null))};Object.defineProperty(e,"watchers",{get:function(){return{view:["handleViewUpdated"],status:["handleStatusUpdated"],sort:["handleSortUpdated"],match:["handleMatchUpdated"],selectedPage:["handlePageUpdated"]}},enumerable:false,configurable:true});return e}());_.style=x}}}));
|
1
|
+
var __assign=this&&this.__assign||function(){__assign=Object.assign||function(e){for(var n,i=1,t=arguments.length;i<t;i++){n=arguments[i];for(var s in n)if(Object.prototype.hasOwnProperty.call(n,s))e[s]=n[s]}return e};return __assign.apply(this,arguments)};var __awaiter=this&&this.__awaiter||function(e,n,i,t){function s(e){return e instanceof i?e:new i((function(n){n(e)}))}return new(i||(i=Promise))((function(i,a){function o(e){try{l(t.next(e))}catch(e){a(e)}}function r(e){try{l(t["throw"](e))}catch(e){a(e)}}function l(e){e.done?i(e.value):s(e.value).then(o,r)}l((t=t.apply(e,n||[])).next())}))};var __generator=this&&this.__generator||function(e,n){var i={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},t,s,a,o;return o={next:r(0),throw:r(1),return:r(2)},typeof Symbol==="function"&&(o[Symbol.iterator]=function(){return this}),o;function r(e){return function(n){return l([e,n])}}function l(r){if(t)throw new TypeError("Generator is already executing.");while(o&&(o=0,r[0]&&(i=0)),i)try{if(t=1,s&&(a=r[0]&2?s["return"]:r[0]?s["throw"]||((a=s["return"])&&a.call(s),0):s.next)&&!(a=a.call(s,r[1])).done)return a;if(s=0,a)r=[r[0]&2,a.value];switch(r[0]){case 0:case 1:a=r;break;case 4:i.label++;return{value:r[1],done:false};case 5:i.label++;s=r[1];r=[0];continue;case 7:r=i.ops.pop();i.trys.pop();continue;default:if(!(a=i.trys,a=a.length>0&&a[a.length-1])&&(r[0]===6||r[0]===2)){i=0;continue}if(r[0]===3&&(!a||r[1]>a[0]&&r[1]<a[3])){i.label=r[1];break}if(r[0]===6&&i.label<a[1]){i.label=a[1];a=r;break}if(a&&i.label<a[2]){i.label=a[2];i.ops.push(r);break}if(a[2])i.ops.pop();i.trys.pop();continue}r=n.call(e,i)}catch(e){r=[6,e];s=0}finally{t=a=0}if(r[0]&5)throw r[1];return{value:r[0]?r[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(e,n,i){if(i||arguments.length===2)for(var t=0,s=n.length,a;t<s;t++){if(a||!(t in n)){if(!a)a=Array.prototype.slice.call(n,0,t);a[t]=n[t]}}return e.concat(a||Array.prototype.slice.call(n))};System.register(["./p-9186f42e.system.js","@verdocs/js-sdk","./p-f29eb00a.system.js","./p-9b26e4e0.system.js","./p-c8a15cb7.system.js","./p-21b1acec.system.js","./p-d738b5db.system.js","./p-2c5350ec.system.js"],(function(e){"use strict";var n,i,t,s,a,o,r,l,c,d,f,p,u,v,h;return{setters:[function(e){n=e.r;i=e.c;t=e.h;s=e.H},function(e){a=e.VerdocsEndpoint;o=e.getEnvelopes;r=e.integerSequence;l=e.getRecipientsWithActions;c=e.userCanCancelEnvelope;d=e.userCanAct;f=e.formatFullName;p=e.cancelEnvelope},function(e){u=e.s},function(e){v=e.V},function(e){h=e.S},function(){},function(){},function(){}],execute:function(){var b='@-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-envelopes-list{display:-ms-flexbox;display:flex;padding:10px;font-size:18px;-ms-flex-wrap:nowrap;flex-wrap:nowrap;border-radius:6px;color:#33364b;-ms-flex-direction:column;flex-direction:column;font-family:"Inter", "Barlow", sans-serif}@media screen and (max-width: 800px){verdocs-envelopes-list{font-size:14px}}verdocs-envelopes-list .envelope-placeholder{height:48px;-ms-flex:0 0 48px;flex:0 0 48px;margin:5px 0;border-radius:5px;background:#f5f5fa}verdocs-envelopes-list .header{width:100%;row-gap:4px;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;-webkit-column-gap:12px;-moz-column-gap:12px;column-gap:12px;margin:0 0 10px 0;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}verdocs-envelopes-list .header .filter{width:300px}verdocs-envelopes-list .header verdocs-text-input{margin:0}verdocs-envelopes-list .header verdocs-text-input input{height:32px}verdocs-envelopes-list .filter{-ms-flex-align:center;align-items:center}verdocs-envelopes-list .envelope{width:100%;margin:3px 0;background:#ffffff}verdocs-envelopes-list .envelope:hover{cursor:pointer;background:#f5f5fa}verdocs-envelopes-list .envelope .inner{gap:12px;display:-ms-flexbox;display:flex;padding:8px 14px;border-radius:5px;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:center;align-items:center;container-type:inline-size}verdocs-envelopes-list .envelope .inner svg{width:24px;height:24px}verdocs-envelopes-list .vert-spacer{height:50px;display:-ms-flexbox;display:flex;-ms-flex:0 0 1px;flex:0 0 1px;border-right:1px solid #dad8dd}@media screen and (max-width: 800px){verdocs-envelopes-list .vert-spacer{display:none}}@media screen and (max-width: 800px){verdocs-envelopes-list .envelope-icon{display:none}}@media screen and (max-width: 800px){verdocs-envelopes-list verdocs-checkbox{display:none}}verdocs-envelopes-list .last-modified{color:#444;display:-ms-flexbox;display:flex;-ms-flex:0 0 180px;flex:0 0 180px;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:center;align-items:center;white-space:nowrap}@media screen and (max-width: 800px){verdocs-envelopes-list .last-modified{display:none}}verdocs-envelopes-list .envelope-name{-ms-flex:1;flex:1;display:-ms-flexbox;display:flex;color:#000000;line-height:28px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}verdocs-envelopes-list .envelope-recipients{color:#4b5563;font-weight:700;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}verdocs-envelopes-list .empty-text{text-align:center;margin:16px 0 0 0;padding:80px 80px;border:2px solid #ccc}verdocs-envelopes-list .containing{gap:12px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}@media screen and (max-width: 800px){verdocs-envelopes-list verdocs-status-indicator{font-size:14px}}';var x=b;var g='<svg xmlns="http://www.w3.org/2000/svg" fill="none" stroke="#000000" viewBox="0 0 24 24" stroke-width="1.5"><path stroke-linecap="round" stroke-linejoin="round" d="M9 12h3.75M9 15h3.75M9 18h3.75m3 .75H18a2.25 2.25 0 002.25-2.25V6.108c0-1.135-.845-2.098-1.976-2.192a48.424 48.424 0 00-1.123-.08m-5.801 0c-.065.21-.1.433-.1.664 0 .414.336.75.75.75h4.5a.75.75 0 00.75-.75 2.25 2.25 0 00-.1-.664m-5.8 0A2.251 2.251 0 0113.5 2.25H15c1.012 0 1.867.668 2.15 1.586m-5.8 0c-.376.023-.75.05-1.124.08C9.095 4.01 8.25 4.973 8.25 6.108V8.25m0 0H4.875c-.621 0-1.125.504-1.125 1.125v11.25c0 .621.504 1.125 1.125 1.125h9.75c.621 0 1.125-.504 1.125-1.125V9.375c0-.621-.504-1.125-1.125-1.125H8.25zM6.75 12h.008v.008H6.75V12zm0 3h.008v.008H6.75V15zm0 3h.008v.008H6.75V18z" /></svg>';var m=[{value:"all",label:"All"},{value:"inbox",label:"Inbox"},{value:"sent",label:"Sent"},{value:"completed",label:"Completed"},{value:"action",label:"Action Required"},{value:"waiting",label:"Waiting on Others"}];var w=[{value:"all",label:"All"},{value:"pending",label:"Pending"},{value:"in progress",label:"In Progress"},{value:"complete",label:"Completed"},{value:"declined",label:"Declined"},{value:"canceled",label:"Canceled"}];var y=[{value:"created_at",label:"Created"},{value:"updated_at",label:"Updated"},{value:"canceled_at",label:"Canceled"},{value:"envelope_name",label:"Name"},{value:"envelope_status",label:"Status"}];var _=e("verdocs_envelopes_list",function(){function e(e){n(this,e);this.changeView=i(this,"changeView",7);this.changeStatus=i(this,"changeStatus",7);this.changeSort=i(this,"changeSort",7);this.changeMatch=i(this,"changeMatch",7);this.sdkError=i(this,"sdkError",7);this.viewEnvelope=i(this,"viewEnvelope",7);this.finishEnvelope=i(this,"finishEnvelope",7);this.endpoint=a.getDefault();this.view=undefined;this.status="all";this.sort="created_at";this.match="";this.showPagination=true;this.rowsPerPage=10;this.selectedPage=0;this.count=0;this.initiallyLoaded=false;this.loading=true;this.selectedEnvelopes=[];this.envelopes=[]}e.prototype.handleViewUpdated=function(){return this.queryEnvelopes()};e.prototype.handleStatusUpdated=function(){return this.queryEnvelopes()};e.prototype.handleSortUpdated=function(){return this.queryEnvelopes()};e.prototype.handleMatchUpdated=function(){return this.queryEnvelopes()};e.prototype.handlePageUpdated=function(){return this.queryEnvelopes()};e.prototype.componentWillLoad=function(){this.endpoint.onSessionChanged((function(e,n,i){console.log("[ENVELOPES_LIST] onSessionChanged",n,i)}));this.endpoint.loadSession()};e.prototype.componentDidLoad=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return[4,this.queryEnvelopes()];case 1:e.sent();this.initiallyLoaded=true;return[2]}}))}))};e.prototype.queryEnvelopes=function(){return __awaiter(this,void 0,void 0,(function(){var e,n,i,t,s,a;return __generator(this,(function(r){switch(r.label){case 0:r.trys.push([0,2,,3]);this.loading=true;t={page:this.selectedPage,rows:this.rowsPerPage};switch(this.view){case"all":t=__assign(__assign({},t),{status:this.status==="all"?["pending","in progress","complete","declined","canceled"]:[this.status]});break;case"inbox":t=__assign({},t);break;case"sent":t=__assign({},t);break;case"action":t=__assign(__assign({},t),{status:["pending","in progress"]});break;case"waiting":t=__assign(__assign({},t),{status:["pending","in progress"]});break;case"completed":t=__assign(__assign({},t),{status:["complete"]});break;default:t=__assign(__assign({},t),{status:this.status==="all"?["pending","in progress","complete","declined","canceled"]:[this.status]})}if(this.view==="all"){if(this.status!=="all"){t.status=[this.status]}}if(this.match.trim());return[4,o(this.endpoint,t)];case 1:s=r.sent();this.envelopes=s.envelopes;this.count=s.count;this.loading=false;return[3,3];case 2:a=r.sent();this.loading=false;console.log("[ENVELOPES] Error listing envelopes",a);(e=this.sdkError)===null||e===void 0?void 0:e.emit(new h(a.message,(n=a.response)===null||n===void 0?void 0:n.status,(i=a.response)===null||i===void 0?void 0:i.data));return[3,3];case 3:return[2]}}))}))};e.prototype.handleDownload=function(){var e=this;u(this.endpoint,this.selectedEnvelopes).then((function(){e.selectedEnvelopes=[]})).catch((function(e){console.log("[ENVELOPES] Download error",e);v("Download error: "+e.message,{style:"error"})}))};e.prototype.downloadEnvelope=function(e){u(this.endpoint,[e]).catch((function(e){console.log("[ENVELOPES] Download error",e);v("Download error: "+e.message,{style:"error"})}))};e.prototype.render=function(){var e=this;return t(s,{key:"13cff825b9a325bb5b45e7c26420276bfb7da9ed"},t("div",{key:"1c5373c8a470db467d32597647aa386efb1b9e17",class:"header"},t("div",{key:"4c394a9bf835ce0145b5b11f0bb2d5386134d1fe",class:"filter"},t("verdocs-text-input",{key:"24a0f7b03fa759478824ca79a1e1939ee986fb6a",id:"verdocs-filter-name",value:this.match,clearable:true,autocomplete:"off",placeholder:"Filter by Name, Recipient, or Field...",onFocusout:function(n){var i;e.match=n.target.value.trim();(i=e.changeMatch)===null||i===void 0?void 0:i.emit(e.match)}})),t("verdocs-quick-filter",{key:"437393b3d6019e0891def40a6d3eba7fa3d480e9",label:"View",value:this.view,options:m,onOptionSelected:function(n){e.view=n.detail.value}}),this.view==="all"&&t("verdocs-quick-filter",{key:"aec9971bcdfa2a7f444f22e0a6bba6b9007eef04",label:"Status",value:this.status,options:w,onOptionSelected:function(n){e.status=n.detail.value}}),this.view==="all"&&t("verdocs-quick-filter",{key:"10bb4001fadd7ca49547a7343a7322bcc941c3f6",label:"Sort By",value:this.sort,options:y,onOptionSelected:function(n){e.sort=n.detail.value}}),this.loading&&t("verdocs-spinner",{key:"2181c646258f4c9949eec73fd83ca83d16186170",mode:"dark",size:24}),t("div",{key:"ba7761ae3b1e9e503c00efb2107883e2ea7e0682",style:{display:"flex",flex:"1"}}),this.selectedEnvelopes.length>0&&t("verdocs-button",{key:"7124f4e1533b0f76d9bc098504063d360f49107e",label:"Download (".concat(this.selectedEnvelopes.length,")"),onClick:function(){return e.handleDownload()}})),this.envelopes.map((function(n){var i;var s=l(n);var a=c(e.endpoint.profile,n);var o=s.find((function(n){var i;return n.email===((i=e.endpoint.session)===null||i===void 0?void 0:i.email)||""}));var r=o&&a&&d(((i=e.endpoint.session)===null||i===void 0?void 0:i.email)||"",s);var u=[{label:"View Envelope",id:"view"},{label:"Finish Envelope",id:"finish",disabled:!r},{label:"Download",id:"download"},{label:"Cancel",id:"cancel",disabled:!a}];return t("div",{class:"envelope",key:n.id,onClick:function(){var i;return(i=e.viewEnvelope)===null||i===void 0?void 0:i.emit({endpoint:e.endpoint,envelope:n})}},t("div",{class:"inner"},t("verdocs-checkbox",{checked:e.selectedEnvelopes.findIndex((function(e){return e.id===n.id}))!==-1,onClick:function(e){return e.stopPropagation()},onInput:function(i){if(i.target.checked){e.selectedEnvelopes=__spreadArray(__spreadArray([],e.selectedEnvelopes,true),[n],false)}else{e.selectedEnvelopes=e.selectedEnvelopes.filter((function(e){return e.id!==n.id}))}}}),t("div",{class:"vert-spacer"}),t("span",{innerHTML:g,class:"envelope-icon"}),t("div",{class:"envelope-name"},n.name,": ",t("div",{class:"envelope-recipients"},n.recipients.map((function(e){return f(e)})))),t("div",{class:"vert-spacer"}),t("verdocs-status-indicator",{envelope:n,style:{width:"125px"}}),t("div",{class:"vert-spacer"}),t("div",{class:"last-modified"},new Date(n.updated_at).toLocaleString()),t("div",{class:"vert-spacer"}),t("verdocs-dropdown",{options:u,onOptionSelected:function(i){var t,s;switch(i.detail.id){case"view":(t=e.viewEnvelope)===null||t===void 0?void 0:t.emit({endpoint:e.endpoint,envelope:n});break;case"finish":(s=e.finishEnvelope)===null||s===void 0?void 0:s.emit({endpoint:e.endpoint,envelope:n});break;case"download":e.downloadEnvelope(n);break;case"cancel":if(window.confirm("Are you sure you want to cancel this envelope?")){p(e.endpoint,n.id).then((function(){return v("Envelope canceled")})).catch((function(e){return v("Unable to cancel envelope: "+e.messabge,{style:"error"})}));e.queryEnvelopes().catch((function(){}))}break}}})))})),!this.initiallyLoaded&&t("div",{key:"598ffddf4adeb704ba272938b41cf2403e97f169",style:{width:"100%"}},r(0,this.rowsPerPage).map((function(){return t("div",{class:"envelope-placeholder"})}))),this.initiallyLoaded&&!this.envelopes.length&&t("div",{key:"dde715119c5f62fd0dab1b960ec8ea25ae815c3e",class:"empty-text"},"No matching envelopes found. Please adjust your filters and try again."),this.initiallyLoaded&&this.envelopes.length&&this.showPagination?t("div",{style:{marginTop:"20px"}},t("verdocs-pagination",{selectedPage:this.selectedPage,perPage:this.rowsPerPage,itemCount:this.count,onSelectPage:function(n){e.selectedPage=n.detail.selectedPage}})):t("div",null))};Object.defineProperty(e,"watchers",{get:function(){return{view:["handleViewUpdated"],status:["handleStatusUpdated"],sort:["handleSortUpdated"],match:["handleMatchUpdated"],selectedPage:["handlePageUpdated"]}},enumerable:false,configurable:true});return e}());_.style=x}}}));
|
@@ -1 +1 @@
|
|
1
|
-
var __awaiter=this&&this.__awaiter||function(e,t,i,n){function s(e){return e instanceof i?e:new i((function(t){t(e)}))}return new(i||(i=Promise))((function(i,r){function o(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n["throw"](e))}catch(e){r(e)}}function l(e){e.done?i(e.value):s(e.value).then(o,a)}l((n=n.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var i={label:0,sent:function(){if(r[0]&1)throw r[1];return r[1]},trys:[],ops:[]},n,s,r,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol==="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(e){return function(t){return l([e,t])}}function l(a){if(n)throw new TypeError("Generator is already executing.");while(o&&(o=0,a[0]&&(i=0)),i)try{if(n=1,s&&(r=a[0]&2?s["return"]:a[0]?s["throw"]||((r=s["return"])&&r.call(s),0):s.next)&&!(r=r.call(s,a[1])).done)return r;if(s=0,r)a=[a[0]&2,r.value];switch(a[0]){case 0:case 1:r=a;break;case 4:i.label++;return{value:a[1],done:false};case 5:i.label++;s=a[1];a=[0];continue;case 7:a=i.ops.pop();i.trys.pop();continue;default:if(!(r=i.trys,r=r.length>0&&r[r.length-1])&&(a[0]===6||a[0]===2)){i=0;continue}if(a[0]===3&&(!r||a[1]>r[0]&&a[1]<r[3])){i.label=a[1];break}if(a[0]===6&&i.label<r[1]){i.label=r[1];r=a;break}if(r&&i.label<r[2]){i.label=r[2];i.ops.push(a);break}if(r[2])i.ops.pop();i.trys.pop();continue}a=t.call(e,i)}catch(e){a=[6,e];s=0}finally{n=r=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(e,t,i){if(i||arguments.length===2)for(var n=0,s=t.length,r;n<s;n++){if(r||!(n in t)){if(!r)r=Array.prototype.slice.call(t,0,n);r[n]=t[n]}}return e.concat(r||Array.prototype.slice.call(t))};System.register(["./p-9186f42e.system.js","@verdocs/js-sdk","./p-736a2c41.system.js","./p-9b26e4e0.system.js","./p-c8a15cb7.system.js","./p-55de8cd1.system.js","./p-21b1acec.system.js","./p-d738b5db.system.js","./p-2c5350ec.system.js"],(function(e){"use strict";var t,i,n,s,r,o,a,l,c,d,u,h,f,v,p,g,m,x,b,y,w,S,k,_,N,I,G,P,z,A,E,U,T,j,D;return{setters:[function(e){t=e.r;i=e.c;n=e.h;s=e.H;r=e.F},function(e){o=e.VerdocsEndpoint;a=e.startSigningSession;l=e.getKbaStep;c=e.envelopeRecipientAgree;d=e.envelopeRecipientDecline;u=e.updateEnvelopeField;h=e.createSignature;f=e.updateEnvelopeFieldSignature;v=e.createInitials;p=e.updateEnvelopeFieldInitials;g=e.isValidPhone;m=e.isValidEmail;x=e.sortFields;b=e.envelopeRecipientSubmit;y=e.getEnvelope;w=e.uploadEnvelopeFieldAttachment;S=e.deleteEnvelopeFieldAttachment;k=e.formatFullName;_=e.fullNameToInitials;N=e.submitKbaPin;I=e.submitKbaIdentity;G=e.submitKbaChallengeResponse;P=e.integerSequence},function(e){z=e.a;A=e.u;E=e.r;U=e.g},function(e){T=e.V},function(e){j=e.S},function(e){D=e.S},function(){},function(){},function(){}],execute:function(){var L='@-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-sign{display:-ms-flexbox;display:flex;overflow:hidden;position:relative;min-height:600px;-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-sign div{display:block;-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-sign input{vertical-align:top}verdocs-sign>.document{-ms-flex:1;flex:1;width:100%;height:100%;-ms-flex-item-align:center;align-self:center;display:-ms-flexbox;display:flex;padding:15px;row-gap:15px;max-width:1200px;min-height:200px;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-sign>.document .inner{width:100%;max-width:1028px}verdocs-sign .cover{top:0;left:0;right:0;bottom:0;display:-ms-flexbox;display:flex;z-index:5000;position:absolute;padding-top:100px;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column;background:rgba(0, 0, 0, 0.5)}verdocs-sign .agree{-ms-flex:0;flex:0;width:600px;display:-ms-flexbox;display:flex;max-width:90%;padding:30px 15px;-ms-flex-direction:column;flex-direction:column;background-color:#ffffff}verdocs-sign .agree .header{-ms-flex:0 0 56px;flex:0 0 56px}verdocs-sign .agree li{margin:0.5em 0}verdocs-sign verdocs-ok-dialog .background-overlay{-ms-flex-align:start;align-items:flex-start;padding-top:100px}verdocs-sign .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-sign .fatal-error{position:absolute;z-index:100;top:0;left:0;right:0;bottom:0;background-color:#4a4a4a;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}verdocs-sign .fatal-error .placeholder{position:absolute;opacity:0.1;z-index:-1;top:0;left:0;right:0;bottom:0;width:612px;height:792px;-webkit-box-shadow:0 0 10px 5px rgba(0, 0, 0, 0.0588235294);box-shadow:0 0 10px 5px rgba(0, 0, 0, 0.0588235294);margin-top:15px}verdocs-sign .fatal-error .message{width:50%;font-size:16px;background:white;border-radius:5px;-webkit-box-shadow:3px 3px 9px -1px rgba(0, 0, 0, 0.2470588235);box-shadow:3px 3px 9px -1px rgba(0, 0, 0, 0.2470588235)}verdocs-sign .fatal-error .header{color:white;font-size:18px;font-weight:500;padding:5px 10px;margin:0 0 10px 0;background:#654dcb}verdocs-sign .fatal-error p{margin:1rem;font-size:14px;font-weight:400}@media print{verdocs-sign .header{display:none}}#verdocs-sign-header{color:#fff;width:100%;display:-ms-flexbox;display:flex;z-index:1000;-ms-flex:0 0 46px;flex:0 0 46px;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-sign-header .inner{width:100%;display:-ms-flexbox;display:flex;margin:0 auto;padding:0 12px;max-width:1200px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}#verdocs-sign-header .logo{width:80px;display:none;margin:-6px 0 0 0}#verdocs-sign-header .title{font-size:18px;font-weight:500;overflow:hidden;white-space:nowrap;padding:0 10px 0 0;text-overflow:ellipsis}.spinner-overlay{position:fixed;top:0;left:0;right:0;bottom:0;z-index:1000;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;background:rgba(0, 0, 0, 0.4980392157);-ms-flex-pack:center;justify-content:center}';var V=L;var Y=[{id:"later",label:"Finish Later"},{id:"decline",label:"Decline to Sign"},{id:"print",label:"Print Without Signing"},{id:"download",label:"Download"}];var q=[{id:"print",label:"Print"},{id:"download",label:"Download"}];var B=e("verdocs_sign",function(){function e(e){t(this,e);this.sdkError=i(this,"sdkError",7);this.envelopeLoaded=i(this,"envelopeLoaded",7);this.envelopeUpdated=i(this,"envelopeUpdated",7);this.recipientIndex=-1;this.endpoint=null;this.envelopeId=null;this.roleId=null;this.inviteCode=null;this.headerTargetId=null;this.roleNames=[];this.sortedRecipients=[];this.recipient=null;this.hasSignature=false;this.nextButtonLabel="Start";this.nextSubmits=false;this.fatalErrorHeader="";this.fatalErrorMessage="";this.focusedField="";this.submitting=false;this.submitted=false;this.isDone=false;this.showDone=false;this.showLoadError=false;this.finishLater=false;this.showFinishLater=false;this.agreed=false;this.documentsSingularPlural="document";this.kbaStep="";this.kbaQuestions=[];this.showSpinner=false;this.kbaChoices=[];this.loading=true;this.envelope=null}e.prototype.componentWillLoad=function(){if(!this.endpoint){console.log("[SIGN] Creating signing endpoint");this.endpoint=new o({sessionType:"signing"})}};e.prototype.componentDidLoad=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,i,n,s,r,o,c,d,u,h;var f=this;return __generator(this,(function(v){switch(v.label){case 0:if(!this.envelopeId){(e=this.sdkError)===null||e===void 0?void 0:e.emit(new j("[SIGN] Missing required envelopId",500,""));return[2]}if(!this.roleId){(t=this.sdkError)===null||t===void 0?void 0:t.emit(new j("[SIGN] Missing required roleId",500,""));return[2]}if(!this.inviteCode){(i=this.sdkError)===null||i===void 0?void 0:i.emit(new j("[SIGN] Missing required inviteCode",500,""));return[2]}v.label=1;case 1:v.trys.push([1,3,,4]);console.log("[SIGN] Processing invite code for ".concat(this.envelopeId," / ").concat(this.roleId));return[4,a(this.endpoint,this.envelopeId,this.roleId,this.inviteCode)];case 2:c=v.sent(),d=c.envelope,u=c.recipient;console.log("[SIGN] Loaded signing session",d,u);this.recipient=u;this.envelope=d;D.updateEnvelope(this.envelopeId,d);this.sortedRecipients=__spreadArray([],this.envelope.recipients,true);this.sortedRecipients.sort((function(e,t){return e.sequence===t.sequence?e.order-t.order:e.sequence-t.sequence}));this.roleNames=this.sortedRecipients.map((function(e){return e.role_name}));if(this.envelope.documents.length>0){this.documentsSingularPlural="document(s)"}this.recipientIndex=this.roleNames.findIndex((function(e){return e==f.roleId}));if(this.recipientIndex>-1){this.recipient=this.sortedRecipients[this.recipientIndex];this.agreed=this.recipient.agreed}else{console.warn("[SIGN] Could not find our recipient record",this.roleId,this.sortedRecipients)}this.submitted=this.recipient.status==="submitted";this.isDone=this.submitted;this.showDone=this.submitted;if(this.envelope.status==="canceled"){this.fatalErrorHeader="Unable to Start Signing Session";this.fatalErrorMessage="This envelope has been canceled. Please contact its sender for more information."}else if(this.recipient.status==="declined"){this.fatalErrorHeader="Unable to Start Signing Session";this.fatalErrorMessage="You have declined to sign this envelope."}else if(this.agreed){this.nextButtonLabel="Next"}this.checkRecipientFields();(n=this.envelopeLoaded)===null||n===void 0?void 0:n.emit({endpoint:this.endpoint,envelope:this.envelope});if(!this.isDone){l(this.endpoint,this.envelopeId,this.roleId).then((function(e){var t;console.log("[SIGN] KBA Step",e);f.kbaStep=e.kba_step;if(f.kbaStep==="failed"){f.fatalErrorHeader="Identity Verification Failed";f.fatalErrorMessage="We were unable to verify your identity. Please contact the document's sender.";f.isDone=true}else{f.kbaQuestions=((t=e.questions)===null||t===void 0?void 0:t.question)||[];f.kbaChoices=[]}})).catch((function(e){return console.log("Error getting KBA step",e)}))}return[3,4];case 3:h=v.sent();console.log("[SIGN] Error with signing session",h);(s=this.sdkError)===null||s===void 0?void 0:s.emit(new j(h.message,(r=h.response)===null||r===void 0?void 0:r.status,(o=h.response)===null||o===void 0?void 0:o.data));this.showLoadError=true;return[3,4];case 4:return[2]}}))}))};e.prototype.componentDidRender=function(){var e=this.headerTargetId?document.getElementById(this.headerTargetId):null;var t=document.getElementById("verdocs-sign-header");if(e&&t){console.log("[SIGN] Moving header");t.remove();e.append(t)}};e.prototype.handleClickAgree=function(){var e=this;this.submitting=true;c(this.endpoint,this.envelopeId,this.roleId,true).then((function(){var t;e.nextButtonLabel="Next";e.recipient.agreed=true;e.submitting=false;e.agreed=true;(t=e.envelopeUpdated)===null||t===void 0?void 0:t.emit({endpoint:e.endpoint,envelope:e.envelope,event:"agreed"})})).catch((function(t){var i,n,s;console.log("[SIGN] Update failure",t);e.submitting=false;(i=e.sdkError)===null||i===void 0?void 0:i.emit(new j(t.message,(n=t.response)===null||n===void 0?void 0:n.status,(s=t.response)===null||s===void 0?void 0:s.data))}))};e.prototype.handleOptionSelected=function(e){return __awaiter(this,void 0,void 0,(function(){var t,i,n,s,r,o,a,l;return __generator(this,(function(c){switch(c.label){case 0:o=e.detail.id;switch(o){case"later":return[3,1];case"claim":return[3,2];case"decline":return[3,3];case"print":return[3,5];case"download":return[3,6]}return[3,7];case 1:this.finishLater=true;this.showFinishLater=true;(t=this.envelopeUpdated)===null||t===void 0?void 0:t.emit({endpoint:this.endpoint,envelope:this.envelope,event:"later"});return[3,7];case 2:T("This feature will be available in an upcoming release.");(i=this.envelopeUpdated)===null||i===void 0?void 0:i.emit({endpoint:this.endpoint,envelope:this.envelope,event:"claimed"});return[3,7];case 3:this.submitting=true;return[4,d(this.endpoint,this.envelopeId,this.roleId)];case 4:a=c.sent();console.log("[SIGN] Decline result",a);(n=this.envelopeUpdated)===null||n===void 0?void 0:n.emit({endpoint:this.endpoint,envelope:this.envelope,event:"declined"});this.submitting=false;this.fatalErrorHeader="Unable to Start Signing Session";this.fatalErrorMessage="You have declined to sign this envelope.";return[3,7];case 5:window.print();(s=this.envelopeUpdated)===null||s===void 0?void 0:s.emit({endpoint:this.endpoint,envelope:this.envelope,event:"printed"});return[3,7];case 6:{l=this.envelope.documents.find((function(e){return e.type==="attachment"}));if(l){z(this.endpoint,this.envelope,l.id).catch((function(e){console.log("[SIGN] Error downloading PDF",e)}));(r=this.envelopeUpdated)===null||r===void 0?void 0:r.emit({endpoint:this.endpoint,envelope:this.envelope,event:"downloaded"})}}return[3,7];case 7:return[2]}}))}))};e.prototype.updateRecipientFieldValue=function(e,t){var i=this;console.log("[SIGN] updateRecipientFieldValue",e);this.getRecipientFields().forEach((function(n){if(n.name===e){n.value=t.value;n.settings=t.settings;A(n);i.checkRecipientFields()}}))};e.prototype.saveFieldChange=function(e,t){var i=this;console.log("[SIGN] updateRecipientFieldValue",e);u(this.endpoint,this.envelopeId,e,t).then((function(t){return i.updateRecipientFieldValue(e,t)})).catch((function(e){var t,n,s,r,o,a;if(((t=e.response)===null||t===void 0?void 0:t.status)===401&&((s=(n=e.response)===null||n===void 0?void 0:n.data)===null||s===void 0?void 0:s.error)==="jwt expired"){console.log("[SIGN] Signing session expired");i.fatalErrorHeader="Signing Session Expired";i.fatalErrorMessage="Please reload your browser to continue."}else{console.log("[SIGN] Server error",e)}(r=i.sdkError)===null||r===void 0?void 0:r.emit(new j(e.message,(o=e.response)===null||o===void 0?void 0:o.status,(a=e.response)===null||a===void 0?void 0:a.data))}))};e.prototype.handleFieldChange=function(e,t){return __awaiter(this,void 0,void 0,(function(){var i,n,s,r,o,a,l;var c=this;return __generator(this,(function(d){switch(d.label){case 0:i=t.target,n=i.value,s=i.checked;r=e.type;switch(r){case"textarea":return[3,1];case"textbox":return[3,1];case"checkbox":return[3,2];case"radio":return[3,3];case"dropdown":return[3,4];case"initial":return[3,5];case"signature":return[3,8];case"date":return[3,11];case"timestamp":return[3,12]}return[3,13];case 1:return[2,this.saveFieldChange(e.name,{prepared:false,value:n})];case 2:{return[2,this.saveFieldChange(e.name,{prepared:false,value:String(t.target.checked)})]}d.label=3;case 3:{return[2,this.saveFieldChange(e.name,{prepared:false,value:String(t.target.checked)})]}d.label=4;case 4:console.log("Saving dropdown",e.name,t.detail);return[2,this.saveFieldChange(e.name,{prepared:false,value:t.detail})];case 5:if(!t.detail){return[2]}this.showSpinner=true;return[4,fetch(t.detail)];case 6:return[4,d.sent().blob()];case 7:o=d.sent();return[2,v(this.endpoint,"initial",o).then((function(t){return __awaiter(c,void 0,void 0,(function(){var i;return __generator(this,(function(n){switch(n.label){case 0:return[4,p(this.endpoint,this.envelopeId,e.name,t.id)];case 1:i=n.sent();this.updateRecipientFieldValue(e.name,i);this.showSpinner=false;return[2]}}))}))})).catch((function(e){console.log("Error updating initials",e);c.showSpinner=false}))];case 8:if(!t.detail){return[2]}this.showSpinner=true;return[4,fetch(t.detail)];case 9:return[4,d.sent().blob()];case 10:a=d.sent();return[2,h(this.endpoint,"signature",a).then((function(t){return __awaiter(c,void 0,void 0,(function(){var i;return __generator(this,(function(n){switch(n.label){case 0:console.log("Signature update result",t);return[4,f(this.endpoint,this.envelopeId,e.name,t.id)];case 1:i=n.sent();this.updateRecipientFieldValue(e.name,i);this.showSpinner=false;return[2]}}))}))})).catch((function(e){console.warn("[SIGN] Error updating signature",e);c.showSpinner=false}))];case 11:l=t.detail.formattedDate;if(l){return[2,this.saveFieldChange(e.name,{prepared:false,value:l})]}return[3,14];case 12:console.log("[SIGN] Updating timestamp",{value:n,ts:t.target.getAttribute("timestamp")});return[3,14];case 13:console.log("[SIGN] Unhandled field update",{value:n,checked:s},e);return[3,14];case 14:return[2]}}))}))};e.prototype.isFieldFilled=function(e){var t=e.value,i=t===void 0?"":t;switch(e.type){case"textarea":case"textbox":switch(e.validator||""){case"email":return m(i);case"phone":return g(i);default:return(i||"").trim()!==""}case"signature":return i==="signed";case"initial":return i==="initialed";case"timestamp":return true;case"date":return!!i;case"attachment":return i==="attached";case"dropdown":return i!=="";case"checkbox":return i==="true";case"radio":if(!!e.group){return this.getRecipientFields().filter((function(t){return t.group===e.group})).some((function(e){return e.value==="true"}))}return e.value==="true";default:return false}};e.prototype.isFieldValid=function(e){return!e.required||this.isFieldFilled(e)};e.prototype.getSortedFillableFields=function(){var e=this.getRecipientFields().filter((function(e){return e.type!=="timestamp"}));x(e);return e};e.prototype.handleNext=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,i,n,s,r,o,a,l,c;var d=this;return __generator(this,(function(u){switch(u.label){case 0:if(!this.nextSubmits)return[3,5];u.label=1;case 1:u.trys.push([1,3,,4]);(e=document.getElementById("air-datepicker-global-container"))===null||e===void 0?void 0:e.remove();this.submitting=true;return[4,b(this.endpoint,this.envelopeId,this.roleId)];case 2:t=u.sent();console.log("[SIGN] Submitted successfully",t);this.recipient.status="submitted";this.showDone=true;console.log("[SIGN] Reloading envelope");y(this.endpoint,this.envelopeId).then((function(e){d.envelope=e;d.submitting=false})).catch((function(e){console.log("[SIGN] Error reloading envelope",e);d.submitting=false}));return[3,4];case 3:i=u.sent();console.log("[SIGN] Error submitting",i);return[3,4];case 4:return[2];case 5:n=this.getSortedFillableFields().filter((function(e){return e.required&&!d.isFieldFilled(e)}));x(n);s=n.findIndex((function(e){return e.name===d.focusedField}));r=s+1;if(r>=n.length){r=0}o=n[r];a=0;if(a<n.length&&["signature","initial"].includes(o.type)&&["initialed","signed"].includes(o.value)){a++;r++;if(r>=n.length){r=0}o=n[r]}if(a>=n.length){o=null}if(o){l=U(o);c=document.getElementById(l);c===null||c===void 0?void 0:c.scrollIntoView({behavior:"smooth"});c===null||c===void 0?void 0:c.focusField();this.focusedField=o.name}return[2]}}))}))};e.prototype.getRecipientFields=function(){var e=this;return this.envelope.fields.filter((function(t){return t.role_name===e.recipient.role_name}))};e.prototype.checkRecipientFields=function(){var e=this;var t=this.getRecipientFields().filter((function(t){return!e.isFieldValid(t)}));if(t.length<1){this.nextButtonLabel="Finish";if(!this.nextSubmits){this.nextSubmits=true}}else{console.log("[SIGN] Invalid fields remaining",t.map((function(e){return e.name})));this.nextButtonLabel="Next";this.nextSubmits=false}};e.prototype.attachFieldAttributes=function(e,t,i){var n=this;if(i.getAttribute("attached")==="1"){return}i.setAttribute("attached","1");i.addEventListener("input",(function(e){if(e.target.type==="radio"||e.target.type==="checkbox"){n.handleFieldChange(t,e).finally((function(){return n.checkRecipientFields()}))}else{n.checkRecipientFields()}}));i.addEventListener("attached",(function(i){return __awaiter(n,void 0,void 0,(function(){var n,s,r;return __generator(this,(function(o){switch(o.label){case 0:console.log("[SIGN] onAttached",i.detail,i.target.value);this.showSpinner=true;o.label=1;case 1:o.trys.push([1,3,,4]);return[4,w(this.endpoint,this.envelopeId,t.name,i.detail)];case 2:n=o.sent();this.updateRecipientFieldValue(t.name,n);this.checkRecipientFields();s=E("envelope",t,e,{disabled:false,editable:false,draggable:false,done:this.isDone});this.attachFieldAttributes(e,t,s);this.showSpinner=false;return[3,4];case 3:r=o.sent();console.log("Error uploading attachment",r);T("Unable to upload attachment, please try again later",{style:"error"});this.showSpinner=false;return[3,4];case 4:return[2]}}))}))}));i.addEventListener("deleted",(function(i){return __awaiter(n,void 0,void 0,(function(){var n,s,r;return __generator(this,(function(o){switch(o.label){case 0:console.log("[SIGN] onDeleted",i.detail,i.target.value);this.showSpinner=true;o.label=1;case 1:o.trys.push([1,3,,4]);return[4,S(this.endpoint,this.envelopeId,t.name)];case 2:n=o.sent();console.log("[SIGN] Deleted attachment",n);this.updateRecipientFieldValue(t.name,n);this.checkRecipientFields();s=E("envelope",t,e,{disabled:false,editable:false,draggable:false,done:this.isDone});this.attachFieldAttributes(e,t,s);this.showSpinner=false;return[3,4];case 3:r=o.sent();console.log("Error uploading attachment",r);T("Unable to upload attachment, please try again later",{style:"error"});this.showSpinner=false;return[3,4];case 4:return[2]}}))}))}));i.addEventListener("focusout",(function(e){if(t.type!=="dropdown"&&t.type!=="attachment"){n.handleFieldChange(t,e).finally((function(){return n.checkRecipientFields()}))}}));i.addEventListener("fieldChange",(function(e){n.handleFieldChange(t,e).finally((function(){return n.checkRecipientFields()}))}));i.setAttribute("templateid",this.envelope.template_id);i.setAttribute("fieldname",t.name);i.setAttribute("page",e.pageNumber);i.setAttribute("xScale",e.xScale);i.setAttribute("yScale",e.yScale);var s=k(this.recipient);i.setAttribute("initials",_(s));i.setAttribute("name",s)};e.prototype.handlePageRendered=function(e){var t=this;var i=e.detail;var n=this.getSortedFillableFields();console.log("[SIGN] Rendering fields for page",i.pageNumber,n);n.forEach((function(e,n){if(e.page!==i.pageNumber){return}var s=E("envelope",e,i,{disabled:false,editable:false,draggable:false,done:t.isDone},n);if(!s){return}if(Array.isArray(s)){s.map((function(n){return t.attachFieldAttributes(i,e,n)}))}else{t.attachFieldAttributes(i,e,s)}}));this.sortedRecipients.filter((function(e){return e.role_name!==t.recipient.role_name&&(e.status==="invited"||e.status==="opened"||e.status==="pending")})).forEach((function(){t.getRecipientFields().filter((function(e){return e.page===i.pageNumber})).forEach((function(e){var n=E("envelope",e,i,{disabled:true,editable:false,draggable:false,done:t.isDone});if(!n){return}if(Array.isArray(n)){n.map((function(n){return t.attachFieldAttributes(i,e,n)}))}else{t.attachFieldAttributes(i,e,n)}}))}));this.checkRecipientFields()};e.prototype.render=function(){var e=this;if(this.showLoadError){return n(s,null,n("verdocs-ok-dialog",{heading:"Unable to Start Signing",message:"Sorry, your invite code is invalid or has expired. Please check your email for an updated invitation, or contact the sender.",buttonLabel:"OK",onNext:function(){window.location.reload()}}))}if(!this.envelope){return n(s,null,n("verdocs-loader",null))}if(this.fatalErrorMessage){return n(s,{class:{agreed:this.agreed}},n("div",{class:"fatal-error"},n("img",{src:"https://public-assets.verdocs.com/loading-placeholder.png",class:"placeholder",alt:"Placeholder page"}),n("div",{class:"message"},n("div",{class:"header"},this.fatalErrorHeader),n("p",null,this.fatalErrorMessage))))}if(this.isDone){return n(s,{class:{agreed:this.agreed}},n("verdocs-view",{endpoint:this.endpoint,envelopeId:this.envelopeId,onSdkError:function(t){var i;return(i=e.sdkError)===null||i===void 0?void 0:i.emit(t.detail)}}),this.showDone&&n("verdocs-ok-dialog",{heading:"You're Done!",message:"You can access the ".concat(this.documentsSingularPlural," at any time by clicking on the link from the invitation email.<br /><br />After all recipients have completed their actions, you will receive an email with the document and envelope certificate attached."),onNext:function(t){t.preventDefault();t.stopPropagation();e.showDone=false;e.isDone=true}}),this.submitting&&n("div",{class:"loading-indicator"},n("verdocs-loader",null)))}if(!this.agreed){return n(s,{class:"agreed"},n("div",{id:"verdocs-sign-header"},n("div",{class:"inner"},n("img",{src:"https://verdocs.com/assets/white-logo.svg",alt:"Verdocs Logo",class:"logo"}),n("div",{class:"title"},this.envelope.name))),n("div",{class:"document",style:{paddingTop:"15px"}},n("img",{src:"https://public-assets.verdocs.com/loading-placeholder.png",style:{width:"612px",height:"792px",boxShadow:"0 0 10px 5px #0000000f",marginTop:"15px"},alt:"Placeholder page"})),n("div",{class:"cover"},n("div",{class:"agree"},n("verdocs-checkbox",{name:"agree",label:"By checking this box, you:",onInput:function(){return e.handleClickAgree()}}),n("ul",null,n("li",null,"Agree to use electronic records and signatures, and confirm you have read the"," ",n("a",{href:"https://verdocs.com/en/electronic-record-signature-disclosure/",target:"_blank"},"Electronic Record and Signatures Disclosure"),"."),n("li",null,"Agree to Verdocs'"," ",n("a",{href:"https://verdocs.com/en/eula",target:"_blank"},"End User License Agreement")," ","and confirm you have read Verdocs'"," ",n("a",{href:"https://verdocs.com/en/privacy-policy/",target:"_blank"},"Privacy Policy"),".")))))}if(this.kbaStep==="pin"){return n(s,{class:"kba"},n("div",{id:"verdocs-sign-header"},n("div",{class:"inner"},n("img",{src:"https://verdocs.com/assets/white-logo.svg",alt:"Verdocs Logo",class:"logo"}),n("div",{class:"title"},this.envelope.name))),n("div",{class:"document",style:{paddingTop:"15px"}},n("img",{src:"https://public-assets.verdocs.com/loading-placeholder.png",style:{width:"612px",height:"792px",boxShadow:"0 0 10px 5px #0000000f",marginTop:"15px"},alt:"Placeholder page"})),n("div",{class:"cover"},n("div",{class:"kba"},n("verdocs-kba-dialog",{mode:"text",step:1,steps:1,helptitle:"Document is protected by a PIN code",helptext:"Please enter your PIN code to proceed. If you do not have one, please contact the sender.",label:"PIN Code",onNext:function(t){return __awaiter(e,void 0,void 0,(function(){var e=this;return __generator(this,(function(i){N(this.endpoint,this.envelopeId,this.roleId,t.detail).then((function(t){console.log("[SIGN] PIN code submission result",t);if(t.kba_step==="complete"){e.kbaStep=""}})).catch((function(e){var t,i;console.log("[SIGN] Error submitting PIN",e);T(((i=(t=e.response)===null||t===void 0?void 0:t.data)===null||i===void 0?void 0:i.error)||"Unable to verify PIN code. Please try again.",{style:"error"})}));return[2]}))}))}}))))}if(this.kbaStep==="identity"){return n(s,{class:"kba"},n("div",{id:"verdocs-sign-header"},n("div",{class:"inner"},n("img",{src:"https://verdocs.com/assets/white-logo.svg",alt:"Verdocs Logo",class:"logo"}),n("div",{class:"title"},this.envelope.name))),n("div",{class:"document",style:{paddingTop:"15px"}},n("img",{src:"https://public-assets.verdocs.com/loading-placeholder.png",style:{width:"612px",height:"792px",boxShadow:"0 0 10px 5px #0000000f",marginTop:"15px"},alt:"Placeholder page"})),n("div",{class:"cover"},n("div",{class:"kba"},n("verdocs-kba-dialog",{mode:"identity",helptitle:"Document requires identity verification",helptext:"Please complete your contact details to proceed.",recipient:this.recipient,onNext:function(t){return __awaiter(e,void 0,void 0,(function(){var e;var i=this;return __generator(this,(function(n){e=t.detail;I(this.endpoint,this.envelopeId,this.roleId,{firstName:e.first_name,lastName:e.last_name,address:e.address,city:e.city,state:e.state,zip:e.zip,ssnLast4:e.ssn_last_4}).then((function(e){console.log("[SIGN] Identity submission result",e);i.kbaStep=e.kba_step})).catch((function(e){var t,i;console.log("[SIGN] Error submitting identity",e);T(((i=(t=e.response)===null||t===void 0?void 0:t.data)===null||i===void 0?void 0:i.error)||"Unable to verify identity.",{style:"error"})}));return[2]}))}))}}))))}if(this.kbaStep==="challenge"){var t=this.kbaChoices.length;var i=this.kbaQuestions[t];console.log("Showing KBA question",{questionNumber:t,kbaQuestion:i},this.kbaChoices);return n(s,{class:"kba"},n("div",{id:"verdocs-sign-header"},n("div",{class:"inner"},n("img",{src:"https://verdocs.com/assets/white-logo.svg",alt:"Verdocs Logo",class:"logo"}),n("div",{class:"title"},this.envelope.name))),n("div",{class:"document",style:{paddingTop:"15px"}},n("img",{src:"https://public-assets.verdocs.com/loading-placeholder.png",style:{width:"612px",height:"792px",boxShadow:"0 0 10px 5px #0000000f",marginTop:"15px"},alt:"Placeholder page"})),n("div",{class:"cover"},n("div",{class:"kba"},this.kbaChoices.length>=this.kbaQuestions.length?n("verdocs-spinner",null):n("verdocs-kba-dialog",{mode:"choice",helptitle:"Your identity requires additional verification",helptext:(i===null||i===void 0?void 0:i.prompt)||"Please select one of the options below.",choices:(i===null||i===void 0?void 0:i.answer)||["Skip Question"],step:t+1,steps:this.kbaQuestions.length,onNext:function(t){return __awaiter(e,void 0,void 0,(function(){var e,i,n,s,r,o,a;var l=this;return __generator(this,(function(c){switch(c.label){case 0:s=t.detail;this.kbaChoices=__spreadArray(__spreadArray([],this.kbaChoices,true),[s],false);if(!(this.kbaChoices.length>=this.kbaQuestions.length))return[3,4];r=this.kbaQuestions.map((function(e,t){return{type:e.type,answer:l.kbaChoices[t]}}));console.log("Submitting KBA responses",this.kbaChoices,r);c.label=1;case 1:c.trys.push([1,3,,4]);return[4,G(this.endpoint,this.envelopeId,this.roleId,r)];case 2:o=c.sent();console.log("KBA challenge response",o);this.kbaStep=o.kba_step;if(this.kbaStep==="failed"){this.fatalErrorHeader="Identity Verification Failed";this.fatalErrorMessage="We were unable to verify your identity. Please contact the document's sender.";this.isDone=true}else{this.kbaQuestions=((e=o.questions)===null||e===void 0?void 0:e.question)||[];this.kbaChoices=[]}return[3,4];case 3:a=c.sent();console.log("Error submitting KBA challenge",a);this.kbaStep="";this.fatalErrorHeader="Unable to Verify Identity";this.fatalErrorMessage=((n=(i=a.response)===null||i===void 0?void 0:i.data)===null||n===void 0?void 0:n.error)||"Please try again later.";this.isDone=true;return[3,4];case 4:return[2]}}))}))}}))))}return n(s,null,n("div",{id:"verdocs-sign-header"},n("div",{class:"inner"},n("img",{src:"https://verdocs.com/assets/white-logo.svg",alt:"Verdocs Logo",class:"logo"}),n("div",{class:"title"},this.envelope.name),n("div",{style:{flex:"1"}}),!this.finishLater&&n("verdocs-button",{size:"xsmall",label:this.nextButtonLabel,disabled:!this.agreed,onClick:function(){return e.handleNext()}}),n("div",{style:{marginLeft:"10px"}}),n("verdocs-dropdown",{options:!this.isDone&&!this.finishLater?Y:q,onOptionSelected:function(t){return e.handleOptionSelected(t)}}))),n("div",{class:"document",style:{paddingTop:"15px"}},(this.envelope.documents||[]).map((function(t){var i=P(1,t.pages);return n(r,null,i.map((function(i){var s;var r=((s=t.page_sizes)===null||s===void 0?void 0:s[i])||{width:612,height:792};return n("verdocs-envelope-document-page",{envelopeId:e.envelopeId,documentId:t.id,endpoint:e.endpoint,virtualWidth:r.width,virtualHeight:r.height,pageNumber:i,onPageRendered:function(t){return e.handlePageRendered(t)},type:"filled",layers:[{name:"page",type:"canvas"},{name:"controls",type:"div"}]})})))}))),this.showFinishLater&&n("verdocs-ok-dialog",{heading:"You've saved your document to finish later.",message:"To complete the ".concat(this.documentsSingularPlural,", use the link in the original email notification inviting you to review and finish the document."),onNext:function(){return e.showFinishLater=false}}),this.showDone&&n("verdocs-ok-dialog",{heading:"You're Done!",message:"You can access the ".concat(this.documentsSingularPlural," at any time by clicking on the link from the invitation email.<br /><br />After all recipients have completed their actions, you will receive an email with the document and envelope certificate attached."),onNext:function(){e.showDone=false;e.isDone=true}}),this.submitting||this.showSpinner&&n("verdocs-portal",null,n("div",{class:"spinner-overlay"},n("verdocs-spinner",null))))};return e}());B.style=V}}}));
|
1
|
+
var __awaiter=this&&this.__awaiter||function(e,t,i,n){function s(e){return e instanceof i?e:new i((function(t){t(e)}))}return new(i||(i=Promise))((function(i,r){function o(e){try{l(n.next(e))}catch(e){r(e)}}function a(e){try{l(n["throw"](e))}catch(e){r(e)}}function l(e){e.done?i(e.value):s(e.value).then(o,a)}l((n=n.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var i={label:0,sent:function(){if(r[0]&1)throw r[1];return r[1]},trys:[],ops:[]},n,s,r,o;return o={next:a(0),throw:a(1),return:a(2)},typeof Symbol==="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(e){return function(t){return l([e,t])}}function l(a){if(n)throw new TypeError("Generator is already executing.");while(o&&(o=0,a[0]&&(i=0)),i)try{if(n=1,s&&(r=a[0]&2?s["return"]:a[0]?s["throw"]||((r=s["return"])&&r.call(s),0):s.next)&&!(r=r.call(s,a[1])).done)return r;if(s=0,r)a=[a[0]&2,r.value];switch(a[0]){case 0:case 1:r=a;break;case 4:i.label++;return{value:a[1],done:false};case 5:i.label++;s=a[1];a=[0];continue;case 7:a=i.ops.pop();i.trys.pop();continue;default:if(!(r=i.trys,r=r.length>0&&r[r.length-1])&&(a[0]===6||a[0]===2)){i=0;continue}if(a[0]===3&&(!r||a[1]>r[0]&&a[1]<r[3])){i.label=a[1];break}if(a[0]===6&&i.label<r[1]){i.label=r[1];r=a;break}if(r&&i.label<r[2]){i.label=r[2];i.ops.push(a);break}if(r[2])i.ops.pop();i.trys.pop();continue}a=t.call(e,i)}catch(e){a=[6,e];s=0}finally{n=r=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(e,t,i){if(i||arguments.length===2)for(var n=0,s=t.length,r;n<s;n++){if(r||!(n in t)){if(!r)r=Array.prototype.slice.call(t,0,n);r[n]=t[n]}}return e.concat(r||Array.prototype.slice.call(t))};System.register(["./p-9186f42e.system.js","@verdocs/js-sdk","./p-f29eb00a.system.js","./p-9b26e4e0.system.js","./p-c8a15cb7.system.js","./p-35dcb386.system.js","./p-21b1acec.system.js","./p-d738b5db.system.js","./p-2c5350ec.system.js"],(function(e){"use strict";var t,i,n,s,r,o,a,l,c,d,u,h,f,v,p,g,m,x,b,y,w,S,k,_,N,I,G,P,z,A,E,U,T,j,D;return{setters:[function(e){t=e.r;i=e.c;n=e.h;s=e.H;r=e.F},function(e){o=e.VerdocsEndpoint;a=e.startSigningSession;l=e.getKbaStep;c=e.envelopeRecipientAgree;d=e.envelopeRecipientDecline;u=e.updateEnvelopeField;h=e.createSignature;f=e.updateEnvelopeFieldSignature;v=e.createInitials;p=e.updateEnvelopeFieldInitials;g=e.isValidPhone;m=e.isValidEmail;x=e.sortFields;b=e.envelopeRecipientSubmit;y=e.getEnvelope;w=e.uploadEnvelopeFieldAttachment;S=e.deleteEnvelopeFieldAttachment;k=e.formatFullName;_=e.fullNameToInitials;N=e.submitKbaPin;I=e.submitKbaIdentity;G=e.submitKbaChallengeResponse;P=e.integerSequence},function(e){z=e.a;A=e.u;E=e.r;U=e.g},function(e){T=e.V},function(e){j=e.S},function(e){D=e.S},function(){},function(){},function(){}],execute:function(){var L='@-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-sign{display:-ms-flexbox;display:flex;overflow:hidden;position:relative;min-height:600px;-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-sign div{display:block;-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-sign input{vertical-align:top}verdocs-sign>.document{-ms-flex:1;flex:1;width:100%;height:100%;-ms-flex-item-align:center;align-self:center;display:-ms-flexbox;display:flex;padding:15px;row-gap:15px;max-width:1200px;min-height:200px;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-sign>.document .inner{width:100%;max-width:1028px}verdocs-sign .cover{top:0;left:0;right:0;bottom:0;display:-ms-flexbox;display:flex;z-index:5000;position:absolute;padding-top:100px;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column;background:rgba(0, 0, 0, 0.5)}verdocs-sign .agree{-ms-flex:0;flex:0;width:600px;display:-ms-flexbox;display:flex;max-width:90%;padding:30px 15px;-ms-flex-direction:column;flex-direction:column;background-color:#ffffff}verdocs-sign .agree .header{-ms-flex:0 0 56px;flex:0 0 56px}verdocs-sign .agree li{margin:0.5em 0}verdocs-sign verdocs-ok-dialog .background-overlay{-ms-flex-align:start;align-items:flex-start;padding-top:100px}verdocs-sign .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-sign .fatal-error{position:absolute;z-index:100;top:0;left:0;right:0;bottom:0;background-color:#4a4a4a;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}verdocs-sign .fatal-error .placeholder{position:absolute;opacity:0.1;z-index:-1;top:0;left:0;right:0;bottom:0;width:612px;height:792px;-webkit-box-shadow:0 0 10px 5px rgba(0, 0, 0, 0.0588235294);box-shadow:0 0 10px 5px rgba(0, 0, 0, 0.0588235294);margin-top:15px}verdocs-sign .fatal-error .message{width:50%;font-size:16px;background:white;border-radius:5px;-webkit-box-shadow:3px 3px 9px -1px rgba(0, 0, 0, 0.2470588235);box-shadow:3px 3px 9px -1px rgba(0, 0, 0, 0.2470588235)}verdocs-sign .fatal-error .header{color:white;font-size:18px;font-weight:500;padding:5px 10px;margin:0 0 10px 0;background:#654dcb}verdocs-sign .fatal-error p{margin:1rem;font-size:14px;font-weight:400}@media print{verdocs-sign .header{display:none}}#verdocs-sign-header{color:#fff;width:100%;display:-ms-flexbox;display:flex;z-index:1000;-ms-flex:0 0 46px;flex:0 0 46px;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-sign-header .inner{width:100%;display:-ms-flexbox;display:flex;margin:0 auto;padding:0 12px;max-width:1200px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}#verdocs-sign-header .logo{width:80px;display:none;margin:-6px 0 0 0}#verdocs-sign-header .title{font-size:18px;font-weight:500;overflow:hidden;white-space:nowrap;padding:0 10px 0 0;text-overflow:ellipsis}.spinner-overlay{position:fixed;top:0;left:0;right:0;bottom:0;z-index:1000;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;background:rgba(0, 0, 0, 0.4980392157);-ms-flex-pack:center;justify-content:center}';var V=L;var Y=[{id:"later",label:"Finish Later"},{id:"decline",label:"Decline to Sign"},{id:"print",label:"Print Without Signing"},{id:"download",label:"Download"}];var q=[{id:"print",label:"Print"},{id:"download",label:"Download"}];var B=e("verdocs_sign",function(){function e(e){t(this,e);this.sdkError=i(this,"sdkError",7);this.envelopeLoaded=i(this,"envelopeLoaded",7);this.envelopeUpdated=i(this,"envelopeUpdated",7);this.recipientIndex=-1;this.endpoint=null;this.envelopeId=null;this.roleId=null;this.inviteCode=null;this.headerTargetId=null;this.roleNames=[];this.sortedRecipients=[];this.recipient=null;this.hasSignature=false;this.nextButtonLabel="Start";this.nextSubmits=false;this.fatalErrorHeader="";this.fatalErrorMessage="";this.focusedField="";this.submitting=false;this.submitted=false;this.isDone=false;this.showDone=false;this.showLoadError=false;this.finishLater=false;this.showFinishLater=false;this.agreed=false;this.documentsSingularPlural="document";this.kbaStep="";this.kbaQuestions=[];this.showSpinner=false;this.kbaChoices=[];this.loading=true;this.envelope=null}e.prototype.componentWillLoad=function(){if(!this.endpoint){console.log("[SIGN] Creating signing endpoint");this.endpoint=new o({sessionType:"signing"})}};e.prototype.componentDidLoad=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,i,n,s,r,o,c,d,u,h;var f=this;return __generator(this,(function(v){switch(v.label){case 0:if(!this.envelopeId){(e=this.sdkError)===null||e===void 0?void 0:e.emit(new j("[SIGN] Missing required envelopId",500,""));return[2]}if(!this.roleId){(t=this.sdkError)===null||t===void 0?void 0:t.emit(new j("[SIGN] Missing required roleId",500,""));return[2]}if(!this.inviteCode){(i=this.sdkError)===null||i===void 0?void 0:i.emit(new j("[SIGN] Missing required inviteCode",500,""));return[2]}v.label=1;case 1:v.trys.push([1,3,,4]);console.log("[SIGN] Processing invite code for ".concat(this.envelopeId," / ").concat(this.roleId));return[4,a(this.endpoint,this.envelopeId,this.roleId,this.inviteCode)];case 2:c=v.sent(),d=c.envelope,u=c.recipient;console.log("[SIGN] Loaded signing session",d,u);this.recipient=u;this.envelope=d;D.updateEnvelope(this.envelopeId,d);this.sortedRecipients=__spreadArray([],this.envelope.recipients,true);this.sortedRecipients.sort((function(e,t){return e.sequence===t.sequence?e.order-t.order:e.sequence-t.sequence}));this.roleNames=this.sortedRecipients.map((function(e){return e.role_name}));if(this.envelope.documents.length>0){this.documentsSingularPlural="document(s)"}this.recipientIndex=this.roleNames.findIndex((function(e){return e==f.roleId}));if(this.recipientIndex>-1){this.recipient=this.sortedRecipients[this.recipientIndex];this.agreed=this.recipient.agreed}else{console.warn("[SIGN] Could not find our recipient record",this.roleId,this.sortedRecipients)}this.submitted=this.recipient.status==="submitted";this.isDone=this.submitted;this.showDone=this.submitted;if(this.envelope.status==="canceled"){this.fatalErrorHeader="Unable to Start Signing Session";this.fatalErrorMessage="This envelope has been canceled. Please contact its sender for more information."}else if(this.recipient.status==="declined"){this.fatalErrorHeader="Unable to Start Signing Session";this.fatalErrorMessage="You have declined to sign this envelope."}else if(this.agreed){this.nextButtonLabel="Next"}this.checkRecipientFields();(n=this.envelopeLoaded)===null||n===void 0?void 0:n.emit({endpoint:this.endpoint,envelope:this.envelope});if(!this.isDone){l(this.endpoint,this.envelopeId,this.roleId).then((function(e){var t;console.log("[SIGN] KBA Step",e);f.kbaStep=e.kba_step;if(f.kbaStep==="failed"){f.fatalErrorHeader="Identity Verification Failed";f.fatalErrorMessage="We were unable to verify your identity. Please contact the document's sender.";f.isDone=true}else{f.kbaQuestions=((t=e.questions)===null||t===void 0?void 0:t.question)||[];f.kbaChoices=[]}})).catch((function(e){return console.log("Error getting KBA step",e)}))}return[3,4];case 3:h=v.sent();console.log("[SIGN] Error with signing session",h);(s=this.sdkError)===null||s===void 0?void 0:s.emit(new j(h.message,(r=h.response)===null||r===void 0?void 0:r.status,(o=h.response)===null||o===void 0?void 0:o.data));this.showLoadError=true;return[3,4];case 4:return[2]}}))}))};e.prototype.componentDidRender=function(){var e=this.headerTargetId?document.getElementById(this.headerTargetId):null;var t=document.getElementById("verdocs-sign-header");if(e&&t){console.log("[SIGN] Moving header");t.remove();e.append(t)}};e.prototype.handleClickAgree=function(){var e=this;this.submitting=true;c(this.endpoint,this.envelopeId,this.roleId,true).then((function(){var t;e.nextButtonLabel="Next";e.recipient.agreed=true;e.submitting=false;e.agreed=true;(t=e.envelopeUpdated)===null||t===void 0?void 0:t.emit({endpoint:e.endpoint,envelope:e.envelope,event:"agreed"})})).catch((function(t){var i,n,s;console.log("[SIGN] Update failure",t);e.submitting=false;(i=e.sdkError)===null||i===void 0?void 0:i.emit(new j(t.message,(n=t.response)===null||n===void 0?void 0:n.status,(s=t.response)===null||s===void 0?void 0:s.data))}))};e.prototype.handleOptionSelected=function(e){return __awaiter(this,void 0,void 0,(function(){var t,i,n,s,r,o,a,l;return __generator(this,(function(c){switch(c.label){case 0:o=e.detail.id;switch(o){case"later":return[3,1];case"claim":return[3,2];case"decline":return[3,3];case"print":return[3,5];case"download":return[3,6]}return[3,7];case 1:this.finishLater=true;this.showFinishLater=true;(t=this.envelopeUpdated)===null||t===void 0?void 0:t.emit({endpoint:this.endpoint,envelope:this.envelope,event:"later"});return[3,7];case 2:T("This feature will be available in an upcoming release.");(i=this.envelopeUpdated)===null||i===void 0?void 0:i.emit({endpoint:this.endpoint,envelope:this.envelope,event:"claimed"});return[3,7];case 3:this.submitting=true;return[4,d(this.endpoint,this.envelopeId,this.roleId)];case 4:a=c.sent();console.log("[SIGN] Decline result",a);(n=this.envelopeUpdated)===null||n===void 0?void 0:n.emit({endpoint:this.endpoint,envelope:this.envelope,event:"declined"});this.submitting=false;this.fatalErrorHeader="Unable to Start Signing Session";this.fatalErrorMessage="You have declined to sign this envelope.";return[3,7];case 5:window.print();(s=this.envelopeUpdated)===null||s===void 0?void 0:s.emit({endpoint:this.endpoint,envelope:this.envelope,event:"printed"});return[3,7];case 6:{l=this.envelope.documents.find((function(e){return e.type==="attachment"}));if(l){z(this.endpoint,this.envelope,l.id).catch((function(e){console.log("[SIGN] Error downloading PDF",e)}));(r=this.envelopeUpdated)===null||r===void 0?void 0:r.emit({endpoint:this.endpoint,envelope:this.envelope,event:"downloaded"})}}return[3,7];case 7:return[2]}}))}))};e.prototype.updateRecipientFieldValue=function(e,t){var i=this;console.log("[SIGN] updateRecipientFieldValue",e);this.getRecipientFields().forEach((function(n){if(n.name===e){n.value=t.value;n.settings=t.settings;A(n);i.checkRecipientFields()}}))};e.prototype.saveFieldChange=function(e,t){var i=this;console.log("[SIGN] updateRecipientFieldValue",e);u(this.endpoint,this.envelopeId,e,t).then((function(t){return i.updateRecipientFieldValue(e,t)})).catch((function(e){var t,n,s,r,o,a;if(((t=e.response)===null||t===void 0?void 0:t.status)===401&&((s=(n=e.response)===null||n===void 0?void 0:n.data)===null||s===void 0?void 0:s.error)==="jwt expired"){console.log("[SIGN] Signing session expired");i.fatalErrorHeader="Signing Session Expired";i.fatalErrorMessage="Please reload your browser to continue."}else{console.log("[SIGN] Server error",e)}(r=i.sdkError)===null||r===void 0?void 0:r.emit(new j(e.message,(o=e.response)===null||o===void 0?void 0:o.status,(a=e.response)===null||a===void 0?void 0:a.data))}))};e.prototype.handleFieldChange=function(e,t){return __awaiter(this,void 0,void 0,(function(){var i,n,s,r,o,a,l;var c=this;return __generator(this,(function(d){switch(d.label){case 0:i=t.target,n=i.value,s=i.checked;r=e.type;switch(r){case"textarea":return[3,1];case"textbox":return[3,1];case"checkbox":return[3,2];case"radio":return[3,3];case"dropdown":return[3,4];case"initial":return[3,5];case"signature":return[3,8];case"date":return[3,11];case"timestamp":return[3,12]}return[3,13];case 1:return[2,this.saveFieldChange(e.name,{prepared:false,value:n})];case 2:{return[2,this.saveFieldChange(e.name,{prepared:false,value:String(t.target.checked)})]}d.label=3;case 3:{return[2,this.saveFieldChange(e.name,{prepared:false,value:String(t.target.checked)})]}d.label=4;case 4:console.log("Saving dropdown",e.name,t.detail);return[2,this.saveFieldChange(e.name,{prepared:false,value:t.detail})];case 5:if(!t.detail){return[2]}this.showSpinner=true;return[4,fetch(t.detail)];case 6:return[4,d.sent().blob()];case 7:o=d.sent();return[2,v(this.endpoint,"initial",o).then((function(t){return __awaiter(c,void 0,void 0,(function(){var i;return __generator(this,(function(n){switch(n.label){case 0:return[4,p(this.endpoint,this.envelopeId,e.name,t.id)];case 1:i=n.sent();this.updateRecipientFieldValue(e.name,i);this.showSpinner=false;return[2]}}))}))})).catch((function(e){console.log("Error updating initials",e);c.showSpinner=false}))];case 8:if(!t.detail){return[2]}this.showSpinner=true;return[4,fetch(t.detail)];case 9:return[4,d.sent().blob()];case 10:a=d.sent();return[2,h(this.endpoint,"signature",a).then((function(t){return __awaiter(c,void 0,void 0,(function(){var i;return __generator(this,(function(n){switch(n.label){case 0:console.log("Signature update result",t);return[4,f(this.endpoint,this.envelopeId,e.name,t.id)];case 1:i=n.sent();this.updateRecipientFieldValue(e.name,i);this.showSpinner=false;return[2]}}))}))})).catch((function(e){console.warn("[SIGN] Error updating signature",e);c.showSpinner=false}))];case 11:l=t.detail.formattedDate;if(l){return[2,this.saveFieldChange(e.name,{prepared:false,value:l})]}return[3,14];case 12:console.log("[SIGN] Updating timestamp",{value:n,ts:t.target.getAttribute("timestamp")});return[3,14];case 13:console.log("[SIGN] Unhandled field update",{value:n,checked:s},e);return[3,14];case 14:return[2]}}))}))};e.prototype.isFieldFilled=function(e){var t=e.value,i=t===void 0?"":t;switch(e.type){case"textarea":case"textbox":switch(e.validator||""){case"email":return m(i);case"phone":return g(i);default:return(i||"").trim()!==""}case"signature":return i==="signed";case"initial":return i==="initialed";case"timestamp":return true;case"date":return!!i;case"attachment":return i==="attached";case"dropdown":return i!=="";case"checkbox":return i==="true";case"radio":if(!!e.group){return this.getRecipientFields().filter((function(t){return t.group===e.group})).some((function(e){return e.value==="true"}))}return e.value==="true";default:return false}};e.prototype.isFieldValid=function(e){return!e.required||this.isFieldFilled(e)};e.prototype.getSortedFillableFields=function(){var e=this.getRecipientFields().filter((function(e){return e.type!=="timestamp"}));x(e);return e};e.prototype.handleNext=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,i,n,s,r,o,a,l,c;var d=this;return __generator(this,(function(u){switch(u.label){case 0:if(!this.nextSubmits)return[3,5];u.label=1;case 1:u.trys.push([1,3,,4]);(e=document.getElementById("air-datepicker-global-container"))===null||e===void 0?void 0:e.remove();this.submitting=true;return[4,b(this.endpoint,this.envelopeId,this.roleId)];case 2:t=u.sent();console.log("[SIGN] Submitted successfully",t);this.recipient.status="submitted";this.showDone=true;console.log("[SIGN] Reloading envelope");y(this.endpoint,this.envelopeId).then((function(e){d.envelope=e;d.submitting=false})).catch((function(e){console.log("[SIGN] Error reloading envelope",e);d.submitting=false}));return[3,4];case 3:i=u.sent();console.log("[SIGN] Error submitting",i);return[3,4];case 4:return[2];case 5:n=this.getSortedFillableFields().filter((function(e){return e.required&&!d.isFieldFilled(e)}));x(n);s=n.findIndex((function(e){return e.name===d.focusedField}));r=s+1;if(r>=n.length){r=0}o=n[r];a=0;if(a<n.length&&["signature","initial"].includes(o.type)&&["initialed","signed"].includes(o.value)){a++;r++;if(r>=n.length){r=0}o=n[r]}if(a>=n.length){o=null}if(o){l=U(o);c=document.getElementById(l);c===null||c===void 0?void 0:c.scrollIntoView({behavior:"smooth"});c===null||c===void 0?void 0:c.focusField();this.focusedField=o.name}return[2]}}))}))};e.prototype.getRecipientFields=function(){var e=this;return this.envelope.fields.filter((function(t){return t.role_name===e.recipient.role_name}))};e.prototype.checkRecipientFields=function(){var e=this;var t=this.getRecipientFields().filter((function(t){return!e.isFieldValid(t)}));if(t.length<1){this.nextButtonLabel="Finish";if(!this.nextSubmits){this.nextSubmits=true}}else{console.log("[SIGN] Invalid fields remaining",t.map((function(e){return e.name})));this.nextButtonLabel="Next";this.nextSubmits=false}};e.prototype.attachFieldAttributes=function(e,t,i){var n=this;if(i.getAttribute("attached")==="1"){return}i.setAttribute("attached","1");i.addEventListener("input",(function(e){if(e.target.type==="radio"||e.target.type==="checkbox"){n.handleFieldChange(t,e).finally((function(){return n.checkRecipientFields()}))}else{n.checkRecipientFields()}}));i.addEventListener("attached",(function(i){return __awaiter(n,void 0,void 0,(function(){var n,s,r;return __generator(this,(function(o){switch(o.label){case 0:console.log("[SIGN] onAttached",i.detail,i.target.value);this.showSpinner=true;o.label=1;case 1:o.trys.push([1,3,,4]);return[4,w(this.endpoint,this.envelopeId,t.name,i.detail)];case 2:n=o.sent();this.updateRecipientFieldValue(t.name,n);this.checkRecipientFields();s=E("envelope",t,e,{disabled:false,editable:false,draggable:false,done:this.isDone});this.attachFieldAttributes(e,t,s);this.showSpinner=false;return[3,4];case 3:r=o.sent();console.log("Error uploading attachment",r);T("Unable to upload attachment, please try again later",{style:"error"});this.showSpinner=false;return[3,4];case 4:return[2]}}))}))}));i.addEventListener("deleted",(function(i){return __awaiter(n,void 0,void 0,(function(){var n,s,r;return __generator(this,(function(o){switch(o.label){case 0:console.log("[SIGN] onDeleted",i.detail,i.target.value);this.showSpinner=true;o.label=1;case 1:o.trys.push([1,3,,4]);return[4,S(this.endpoint,this.envelopeId,t.name)];case 2:n=o.sent();console.log("[SIGN] Deleted attachment",n);this.updateRecipientFieldValue(t.name,n);this.checkRecipientFields();s=E("envelope",t,e,{disabled:false,editable:false,draggable:false,done:this.isDone});this.attachFieldAttributes(e,t,s);this.showSpinner=false;return[3,4];case 3:r=o.sent();console.log("Error uploading attachment",r);T("Unable to upload attachment, please try again later",{style:"error"});this.showSpinner=false;return[3,4];case 4:return[2]}}))}))}));i.addEventListener("focusout",(function(e){if(t.type!=="dropdown"&&t.type!=="attachment"){n.handleFieldChange(t,e).finally((function(){return n.checkRecipientFields()}))}}));i.addEventListener("fieldChange",(function(e){n.handleFieldChange(t,e).finally((function(){return n.checkRecipientFields()}))}));i.setAttribute("templateid",this.envelope.template_id);i.setAttribute("fieldname",t.name);i.setAttribute("page",e.pageNumber);i.setAttribute("xScale",e.xScale);i.setAttribute("yScale",e.yScale);var s=k(this.recipient);i.setAttribute("initials",_(s));i.setAttribute("name",s)};e.prototype.handlePageRendered=function(e){var t=this;var i=e.detail;var n=this.getSortedFillableFields();console.log("[SIGN] Rendering fields for page",i.pageNumber,n);n.forEach((function(e,n){if(e.page!==i.pageNumber){return}var s=E("envelope",e,i,{disabled:false,editable:false,draggable:false,done:t.isDone},n);if(!s){return}if(Array.isArray(s)){s.map((function(n){return t.attachFieldAttributes(i,e,n)}))}else{t.attachFieldAttributes(i,e,s)}}));this.sortedRecipients.filter((function(e){return e.role_name!==t.recipient.role_name&&(e.status==="invited"||e.status==="opened"||e.status==="pending")})).forEach((function(){t.getRecipientFields().filter((function(e){return e.page===i.pageNumber})).forEach((function(e){var n=E("envelope",e,i,{disabled:true,editable:false,draggable:false,done:t.isDone});if(!n){return}if(Array.isArray(n)){n.map((function(n){return t.attachFieldAttributes(i,e,n)}))}else{t.attachFieldAttributes(i,e,n)}}))}));this.checkRecipientFields()};e.prototype.render=function(){var e=this;if(this.showLoadError){return n(s,null,n("verdocs-ok-dialog",{heading:"Unable to Start Signing",message:"Sorry, your invite code is invalid or has expired. Please check your email for an updated invitation, or contact the sender.",buttonLabel:"OK",onNext:function(){window.location.reload()}}))}if(!this.envelope){return n(s,null,n("verdocs-loader",null))}if(this.fatalErrorMessage){return n(s,{class:{agreed:this.agreed}},n("div",{class:"fatal-error"},n("img",{src:"https://public-assets.verdocs.com/loading-placeholder.png",class:"placeholder",alt:"Placeholder page"}),n("div",{class:"message"},n("div",{class:"header"},this.fatalErrorHeader),n("p",null,this.fatalErrorMessage))))}if(this.isDone){return n(s,{class:{agreed:this.agreed}},n("verdocs-view",{endpoint:this.endpoint,envelopeId:this.envelopeId,onSdkError:function(t){var i;return(i=e.sdkError)===null||i===void 0?void 0:i.emit(t.detail)}}),this.showDone&&n("verdocs-ok-dialog",{heading:"You're Done!",message:"You can access the ".concat(this.documentsSingularPlural," at any time by clicking on the link from the invitation email.<br /><br />After all recipients have completed their actions, you will receive an email with the document and envelope certificate attached."),onNext:function(t){t.preventDefault();t.stopPropagation();e.showDone=false;e.isDone=true}}),this.submitting&&n("div",{class:"loading-indicator"},n("verdocs-loader",null)))}if(!this.agreed){return n(s,{class:"agreed"},n("div",{id:"verdocs-sign-header"},n("div",{class:"inner"},n("img",{src:"https://verdocs.com/assets/white-logo.svg",alt:"Verdocs Logo",class:"logo"}),n("div",{class:"title"},this.envelope.name))),n("div",{class:"document",style:{paddingTop:"15px"}},n("img",{src:"https://public-assets.verdocs.com/loading-placeholder.png",style:{width:"612px",height:"792px",boxShadow:"0 0 10px 5px #0000000f",marginTop:"15px"},alt:"Placeholder page"})),n("div",{class:"cover"},n("div",{class:"agree"},n("verdocs-checkbox",{name:"agree",label:"By checking this box, you:",onInput:function(){return e.handleClickAgree()}}),n("ul",null,n("li",null,"Agree to use electronic records and signatures, and confirm you have read the"," ",n("a",{href:"https://verdocs.com/en/electronic-record-signature-disclosure/",target:"_blank"},"Electronic Record and Signatures Disclosure"),"."),n("li",null,"Agree to Verdocs'"," ",n("a",{href:"https://verdocs.com/en/eula",target:"_blank"},"End User License Agreement")," ","and confirm you have read Verdocs'"," ",n("a",{href:"https://verdocs.com/en/privacy-policy/",target:"_blank"},"Privacy Policy"),".")))))}if(this.kbaStep==="pin"){return n(s,{class:"kba"},n("div",{id:"verdocs-sign-header"},n("div",{class:"inner"},n("img",{src:"https://verdocs.com/assets/white-logo.svg",alt:"Verdocs Logo",class:"logo"}),n("div",{class:"title"},this.envelope.name))),n("div",{class:"document",style:{paddingTop:"15px"}},n("img",{src:"https://public-assets.verdocs.com/loading-placeholder.png",style:{width:"612px",height:"792px",boxShadow:"0 0 10px 5px #0000000f",marginTop:"15px"},alt:"Placeholder page"})),n("div",{class:"cover"},n("div",{class:"kba"},n("verdocs-kba-dialog",{mode:"text",step:1,steps:1,helptitle:"Document is protected by a PIN code",helptext:"Please enter your PIN code to proceed. If you do not have one, please contact the sender.",label:"PIN Code",onNext:function(t){return __awaiter(e,void 0,void 0,(function(){var e=this;return __generator(this,(function(i){N(this.endpoint,this.envelopeId,this.roleId,t.detail).then((function(t){console.log("[SIGN] PIN code submission result",t);if(t.kba_step==="complete"){e.kbaStep=""}})).catch((function(e){var t,i;console.log("[SIGN] Error submitting PIN",e);T(((i=(t=e.response)===null||t===void 0?void 0:t.data)===null||i===void 0?void 0:i.error)||"Unable to verify PIN code. Please try again.",{style:"error"})}));return[2]}))}))}}))))}if(this.kbaStep==="identity"){return n(s,{class:"kba"},n("div",{id:"verdocs-sign-header"},n("div",{class:"inner"},n("img",{src:"https://verdocs.com/assets/white-logo.svg",alt:"Verdocs Logo",class:"logo"}),n("div",{class:"title"},this.envelope.name))),n("div",{class:"document",style:{paddingTop:"15px"}},n("img",{src:"https://public-assets.verdocs.com/loading-placeholder.png",style:{width:"612px",height:"792px",boxShadow:"0 0 10px 5px #0000000f",marginTop:"15px"},alt:"Placeholder page"})),n("div",{class:"cover"},n("div",{class:"kba"},n("verdocs-kba-dialog",{mode:"identity",helptitle:"Document requires identity verification",helptext:"Please complete your contact details to proceed.",recipient:this.recipient,onNext:function(t){return __awaiter(e,void 0,void 0,(function(){var e;var i=this;return __generator(this,(function(n){e=t.detail;I(this.endpoint,this.envelopeId,this.roleId,{firstName:e.first_name,lastName:e.last_name,address:e.address,city:e.city,state:e.state,zip:e.zip,ssnLast4:e.ssn_last_4}).then((function(e){console.log("[SIGN] Identity submission result",e);i.kbaStep=e.kba_step})).catch((function(e){var t,i;console.log("[SIGN] Error submitting identity",e);T(((i=(t=e.response)===null||t===void 0?void 0:t.data)===null||i===void 0?void 0:i.error)||"Unable to verify identity.",{style:"error"})}));return[2]}))}))}}))))}if(this.kbaStep==="challenge"){var t=this.kbaChoices.length;var i=this.kbaQuestions[t];console.log("Showing KBA question",{questionNumber:t,kbaQuestion:i},this.kbaChoices);return n(s,{class:"kba"},n("div",{id:"verdocs-sign-header"},n("div",{class:"inner"},n("img",{src:"https://verdocs.com/assets/white-logo.svg",alt:"Verdocs Logo",class:"logo"}),n("div",{class:"title"},this.envelope.name))),n("div",{class:"document",style:{paddingTop:"15px"}},n("img",{src:"https://public-assets.verdocs.com/loading-placeholder.png",style:{width:"612px",height:"792px",boxShadow:"0 0 10px 5px #0000000f",marginTop:"15px"},alt:"Placeholder page"})),n("div",{class:"cover"},n("div",{class:"kba"},this.kbaChoices.length>=this.kbaQuestions.length?n("verdocs-spinner",null):n("verdocs-kba-dialog",{mode:"choice",helptitle:"Your identity requires additional verification",helptext:(i===null||i===void 0?void 0:i.prompt)||"Please select one of the options below.",choices:(i===null||i===void 0?void 0:i.answer)||["Skip Question"],step:t+1,steps:this.kbaQuestions.length,onNext:function(t){return __awaiter(e,void 0,void 0,(function(){var e,i,n,s,r,o,a;var l=this;return __generator(this,(function(c){switch(c.label){case 0:s=t.detail;this.kbaChoices=__spreadArray(__spreadArray([],this.kbaChoices,true),[s],false);if(!(this.kbaChoices.length>=this.kbaQuestions.length))return[3,4];r=this.kbaQuestions.map((function(e,t){return{type:e.type,answer:l.kbaChoices[t]}}));console.log("Submitting KBA responses",this.kbaChoices,r);c.label=1;case 1:c.trys.push([1,3,,4]);return[4,G(this.endpoint,this.envelopeId,this.roleId,r)];case 2:o=c.sent();console.log("KBA challenge response",o);this.kbaStep=o.kba_step;if(this.kbaStep==="failed"){this.fatalErrorHeader="Identity Verification Failed";this.fatalErrorMessage="We were unable to verify your identity. Please contact the document's sender.";this.isDone=true}else{this.kbaQuestions=((e=o.questions)===null||e===void 0?void 0:e.question)||[];this.kbaChoices=[]}return[3,4];case 3:a=c.sent();console.log("Error submitting KBA challenge",a);this.kbaStep="";this.fatalErrorHeader="Unable to Verify Identity";this.fatalErrorMessage=((n=(i=a.response)===null||i===void 0?void 0:i.data)===null||n===void 0?void 0:n.error)||"Please try again later.";this.isDone=true;return[3,4];case 4:return[2]}}))}))}}))))}return n(s,null,n("div",{id:"verdocs-sign-header"},n("div",{class:"inner"},n("img",{src:"https://verdocs.com/assets/white-logo.svg",alt:"Verdocs Logo",class:"logo"}),n("div",{class:"title"},this.envelope.name),n("div",{style:{flex:"1"}}),!this.finishLater&&n("verdocs-button",{size:"xsmall",label:this.nextButtonLabel,disabled:!this.agreed,onClick:function(){return e.handleNext()}}),n("div",{style:{marginLeft:"10px"}}),n("verdocs-dropdown",{options:!this.isDone&&!this.finishLater?Y:q,onOptionSelected:function(t){return e.handleOptionSelected(t)}}))),n("div",{class:"document",style:{paddingTop:"15px"}},(this.envelope.documents||[]).map((function(t){var i=P(1,t.pages);return n(r,null,i.map((function(i){var s;var r=((s=t.page_sizes)===null||s===void 0?void 0:s[i])||{width:612,height:792};return n("verdocs-envelope-document-page",{envelopeId:e.envelopeId,documentId:t.id,endpoint:e.endpoint,virtualWidth:r.width,virtualHeight:r.height,pageNumber:i,onPageRendered:function(t){return e.handlePageRendered(t)},type:"filled",layers:[{name:"page",type:"canvas"},{name:"controls",type:"div"}]})})))}))),this.showFinishLater&&n("verdocs-ok-dialog",{heading:"You've saved your document to finish later.",message:"To complete the ".concat(this.documentsSingularPlural,", use the link in the original email notification inviting you to review and finish the document."),onNext:function(){return e.showFinishLater=false}}),this.showDone&&n("verdocs-ok-dialog",{heading:"You're Done!",message:"You can access the ".concat(this.documentsSingularPlural," at any time by clicking on the link from the invitation email.<br /><br />After all recipients have completed their actions, you will receive an email with the document and envelope certificate attached."),onNext:function(){e.showDone=false;e.isDone=true}}),this.submitting||this.showSpinner&&n("verdocs-portal",null,n("div",{class:"spinner-overlay"},n("verdocs-spinner",null))))};return e}());B.style=V}}}));
|
@@ -1 +1 @@
|
|
1
|
-
var __awaiter=this&&this.__awaiter||function(e,t,i,o){function r(e){return e instanceof i?e:new i((function(t){t(e)}))}return new(i||(i=Promise))((function(i,a){function s(e){try{c(o.next(e))}catch(e){a(e)}}function n(e){try{c(o["throw"](e))}catch(e){a(e)}}function c(e){e.done?i(e.value):r(e.value).then(s,n)}c((o=o.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var i={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},o,r,a,s;return s={next:n(0),throw:n(1),return:n(2)},typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function n(e){return function(t){return c([e,t])}}function c(n){if(o)throw new TypeError("Generator is already executing.");while(s&&(s=0,n[0]&&(i=0)),i)try{if(o=1,r&&(a=n[0]&2?r["return"]:n[0]?r["throw"]||((a=r["return"])&&a.call(r),0):r.next)&&!(a=a.call(r,n[1])).done)return a;if(r=0,a)n=[n[0]&2,a.value];switch(n[0]){case 0:case 1:a=n;break;case 4:i.label++;return{value:n[1],done:false};case 5:i.label++;r=n[1];n=[0];continue;case 7:n=i.ops.pop();i.trys.pop();continue;default:if(!(a=i.trys,a=a.length>0&&a[a.length-1])&&(n[0]===6||n[0]===2)){i=0;continue}if(n[0]===3&&(!a||n[1]>a[0]&&n[1]<a[3])){i.label=n[1];break}if(n[0]===6&&i.label<a[1]){i.label=a[1];a=n;break}if(a&&i.label<a[2]){i.label=a[2];i.ops.push(n);break}if(a[2])i.ops.pop();i.trys.pop();continue}n=t.call(e,i)}catch(e){n=[6,e];r=0}finally{o=a=0}if(n[0]&5)throw n[1];return{value:n[0]?n[1]:void 0,done:true}}};System.register(["./p-9186f42e.system.js","@verdocs/js-sdk","./p-736a2c41.system.js","./p-55de8cd1.system.js","./p-e0ac9edf.system.js","./p-21b1acec.system.js","./p-d738b5db.system.js","./p-2c5350ec.system.js"],(function(e){"use strict";var t,i,o,r,a,s,n,c,d,l,u,h,p,f;return{setters:[function(e){t=e.r;i=e.c;o=e.h;r=e.H;a=e.F;s=e.g},function(e){n=e.VerdocsEndpoint;c=e.getTemplateDocumentPageDisplayUri;d=e.getTemplate},function(e){l=e.t;u=e.j;h=e.g},function(e){p=e.S},function(e){f=e.c},function(){},function(){},function(){}],execute:function(){var b="@-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-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 rgba(0, 0, 0, 0.0588235294);box-shadow:0 0 10px 5px rgba(0, 0, 0, 0.0588235294)}verdocs-template-document-page .verdocs-template-document-page-layer.img{width:100%}verdocs-template-document-page .placeholder{opacity:0.1;width:612px;height:792px;-webkit-box-shadow:0 0 10px 5px rgba(0, 0, 0, 0.0588235294);box-shadow:0 0 10px 5px rgba(0, 0, 0, 0.0588235294)}";var v=b;var m=e("verdocs_template_document_page",function(){function e(e){t(this,e);this.pageRendered=i(this,"pageRendered",7);this.templateListenerId=null;this.endpoint=n.getDefault();this.editable=false;this.disabled=false;this.done=false;this.templateId="";this.documentId="";this.pageNumber=1;this.virtualWidth=612;this.virtualHeight=792;this.layers=[{name:"page",type:"canvas"}];this.containerId="verdocs-document-page-".concat(Math.random().toString(36).substring(2,11));this.renderedWidth=this.virtualWidth;this.renderedHeight=this.virtualHeight;this.naturalWidth=this.virtualWidth;this.naturalHeight=this.virtualHeight;this.aspectRatio=this.virtualWidth/this.virtualHeight;this.skipFirstNotification=true;this.pageDisplayUri="";this.xScale=1;this.yScale=1;this.loading=true;this.template=null}e.prototype.componentWillLoad=function(){return __awaiter(this,void 0,void 0,(function(){var e;return __generator(this,(function(t){switch(t.label){case 0:e=this;return[4,c(this.endpoint,this.documentId,this.pageNumber)];case 1:e.pageDisplayUri=t.sent();this.listenToTemplate();return[2]}}))}))};e.prototype.componentDidLoad=function(){var e=this;this.resizeObserver=new ResizeObserver(l((function(t){for(var i=0,o=t;i<o.length;i++){var r=o[i];var a=r.contentRect.width;e.renderedWidth=a;e.renderedHeight=e.virtualHeight*(a/e.virtualWidth)}e.notifyRenderedSize()}),100));this.resizeObserver.observe(this.container)};e.prototype.componentDidUpdate=function(){this.notifyRenderedSize()};e.prototype.disconnectedCallback=function(){var e;(e=this.resizeObserver)===null||e===void 0?void 0:e.disconnect();this.unlistenToTemplate()};e.prototype.listenToTemplate=function(){return __awaiter(this,void 0,void 0,(function(){var e=this;return __generator(this,(function(t){this.unlistenToTemplate();p.subscribe("templates",this.templateId,(function(){return d(e.endpoint,e.templateId)}),false,(function(t){e.template=t;e.loading=false}));return[2]}))}))};e.prototype.unlistenToTemplate=function(){if(this.templateListenerId){p.store.delListener(this.templateListenerId);this.templateListenerId=null}};e.prototype.notifyRenderedSize=function(){if(this.skipFirstNotification){this.skipFirstNotification=false;return}var e=this.renderedWidth/this.virtualWidth;if(this.xScale!==e){this.xScale=e}var t=this.renderedHeight/this.virtualHeight;if(this.yScale!==t){this.yScale=t}this.pageRendered.emit({containerId:this.containerId,documentId:this.documentId,pageNumber:this.pageNumber,virtualWidth:this.virtualWidth,virtualHeight:this.virtualHeight,renderedWidth:this.renderedWidth,renderedHeight:this.renderedHeight,naturalWidth:this.naturalWidth,naturalHeight:this.naturalHeight,aspectRatio:this.aspectRatio,xScale:e,yScale:t})};e.prototype.render=function(){var e=this;if(this.loading){return o(r,null,o("img",{src:"https://public-assets.verdocs.com/loading-placeholder.png",class:"placeholder",alt:"Placeholder page"}))}var t="".concat(this.renderedHeight,"px");return o(r,{id:"".concat(this.containerId),style:{height:t,flex:"0 0 ".concat(t)}},this.layers.map((function(i){var r;return i.type==="div"?o("div",{class:"verdocs-template-document-page-layer",id:"".concat(e.containerId,"-").concat(i.name),style:{height:t}},i.name==="controls"&&(((r=e.template)===null||r===void 0?void 0:r.fields)||[]).filter((function(t){return t&&t.page===e.pageNumber})).map((function(t){var i,r;var s=h(t);var n=t.name,c=t.type,d=t.multiline;var l=e,p=l.xScale,f=l.yScale,b=l.templateId,v=l.editable,m=l.disabled,g=l.done,y=l.pageNumber;if(((i=t["setting"])===null||i===void 0?void 0:i.leading)>0||((r=t["settings"])===null||r===void 0?void 0:r.leading)>0){c="textarea";d=true}switch(c){case"textbox":return o("verdocs-field-textbox",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,multiline:d,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});case"textarea":return o("verdocs-field-textarea",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});case"date":return o("verdocs-field-date",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});case"attachment":return o("verdocs-field-attachment",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});case"dropdown":return o("verdocs-field-dropdown",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});case"initial":return o("verdocs-field-initial",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});case"signature":return o("verdocs-field-signature",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,e.xScale,e.yScale)});case"timestamp":return o("verdocs-field-timestamp",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});case"checkbox":return o("verdocs-field-checkbox",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});case"radio":return o("verdocs-field-radio",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});default:return o(a,null,n)}}))):e.pageDisplayUri?o("img",{class:"verdocs-template-document-page-layer img",id:"".concat(e.containerId,"-").concat(i.name),src:e.pageDisplayUri,alt:"Page ".concat(e.pageNumber),"aria-hidden":true,loading:"lazy",onLoad:function(t){e.naturalWidth=t.target.naturalWidth;e.naturalHeight=t.target.naturalHeight;e.aspectRatio=e.naturalWidth/e.naturalHeight;e.virtualHeight=e.virtualWidth/e.aspectRatio;e.renderedHeight=t.target.offsetWidth/e.aspectRatio}}):o("div",null)})))};Object.defineProperty(e.prototype,"container",{get:function(){return s(this)},enumerable:false,configurable:true});return e}());m.style=v;var g='@-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-toolbar-icon{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif;display:inline-block}verdocs-toolbar-icon .icon{display:inline-block;cursor:pointer}verdocs-toolbar-icon .icon svg{fill:#5c6575}verdocs-toolbar-icon .tooltip{display:none;-webkit-box-shadow:0 0 10px 1px #999999;box-shadow:0 0 10px 1px #999999;background:#ffffff;color:#33364b;max-width:240px;font-weight:bold;padding:5px 10px;font-size:13px;position:relative;border-radius:4px;z-index:20000;white-space:nowrap}verdocs-toolbar-icon .tooltip .arrow,verdocs-toolbar-icon .tooltip .arrow::before{position:absolute;width:8px;height:8px;background:inherit}verdocs-toolbar-icon .tooltip .arrow{visibility:hidden;top:-4px}verdocs-toolbar-icon .tooltip .arrow::before{visibility:visible;content:"";-webkit-transform:rotate(45deg);transform:rotate(45deg)}verdocs-toolbar-icon .tooltip[data-show]{display:block}verdocs-toolbar-icon .tooltip[data-popper-placement^=top]>.arrow{bottom:-4px}verdocs-toolbar-icon .tooltip[data-popper-placement^=bottom]>.arrow{top:-4px}verdocs-toolbar-icon .tooltip[data-popper-placement^=left]>.arrow{right:-4px}verdocs-toolbar-icon .tooltip[data-popper-placement^=right]>.arrow{left:-4px}verdocs-toolbar-icon .tooltip[data-popper-placement^=left]{padding:3px 10px}verdocs-toolbar-icon .tooltip[data-popper-placement^=left]>.arrow{right:-1px}';var y=g;var x=e("verdocs_toolbar_icon",function(){function e(e){t(this,e);this.text="";this.icon="";this.placement="bottom";this.containerId="verdocs-toolbar-icon-".concat(Math.random().toString(36).substring(2,11))}e.prototype.componentDidLoad=function(){this.popperInstance=f(this.iconEl,this.tooltip,{placement:this.placement,modifiers:this.placement==="left"?[{name:"offset",options:{offset:[0,20]}}]:[]})};e.prototype.disconnectedCallback=function(){if(this.popperInstance){this.popperInstance.destroy();this.popperInstance=null}};e.prototype.show=function(){var e,t;(e=this.tooltip)===null||e===void 0?void 0:e.setAttribute("data-show","");(t=this.popperInstance)===null||t===void 0?void 0:t.update().catch((function(){}))};e.prototype.hide=function(){var e;(e=this.tooltip)===null||e===void 0?void 0:e.removeAttribute("data-show")};e.prototype.render=function(){var e=this;return o(r,{key:"98b2f6b2a2711df2cf8e687e38684d495b6e7d50",class:{}},o("div",{key:"49500d4d3348e2ccd6c9cbe7867645756c6cf5ef","aria-describedby":this.containerId,class:"icon",innerHTML:this.icon,onMouseEnter:function(){return e.show()},onFocus:function(){return e.show()},onMouseLeave:function(){return e.hide()},onBlur:function(){return e.hide()},ref:function(t){return e.iconEl=t}}),o("div",{key:"e64aa823a8a09b10a9166f96be633439d959d3ff",id:this.containerId,role:"tooltip",class:"tooltip","data-popper-placement":this.placement,ref:function(t){return e.tooltip=t}},this.text,o("div",{key:"399156e882824870173ecf3e4bcc35f2ba720b8c","data-popper-arrow":"true",class:"arrow"})))};return e}());x.style=y}}}));
|
1
|
+
var __awaiter=this&&this.__awaiter||function(e,t,i,o){function r(e){return e instanceof i?e:new i((function(t){t(e)}))}return new(i||(i=Promise))((function(i,a){function s(e){try{c(o.next(e))}catch(e){a(e)}}function n(e){try{c(o["throw"](e))}catch(e){a(e)}}function c(e){e.done?i(e.value):r(e.value).then(s,n)}c((o=o.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var i={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},o,r,a,s;return s={next:n(0),throw:n(1),return:n(2)},typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function n(e){return function(t){return c([e,t])}}function c(n){if(o)throw new TypeError("Generator is already executing.");while(s&&(s=0,n[0]&&(i=0)),i)try{if(o=1,r&&(a=n[0]&2?r["return"]:n[0]?r["throw"]||((a=r["return"])&&a.call(r),0):r.next)&&!(a=a.call(r,n[1])).done)return a;if(r=0,a)n=[n[0]&2,a.value];switch(n[0]){case 0:case 1:a=n;break;case 4:i.label++;return{value:n[1],done:false};case 5:i.label++;r=n[1];n=[0];continue;case 7:n=i.ops.pop();i.trys.pop();continue;default:if(!(a=i.trys,a=a.length>0&&a[a.length-1])&&(n[0]===6||n[0]===2)){i=0;continue}if(n[0]===3&&(!a||n[1]>a[0]&&n[1]<a[3])){i.label=n[1];break}if(n[0]===6&&i.label<a[1]){i.label=a[1];a=n;break}if(a&&i.label<a[2]){i.label=a[2];i.ops.push(n);break}if(a[2])i.ops.pop();i.trys.pop();continue}n=t.call(e,i)}catch(e){n=[6,e];r=0}finally{o=a=0}if(n[0]&5)throw n[1];return{value:n[0]?n[1]:void 0,done:true}}};System.register(["./p-9186f42e.system.js","@verdocs/js-sdk","./p-f29eb00a.system.js","./p-35dcb386.system.js","./p-e0ac9edf.system.js","./p-21b1acec.system.js","./p-d738b5db.system.js","./p-2c5350ec.system.js"],(function(e){"use strict";var t,i,o,r,a,s,n,c,l,d,u,h,p,f;return{setters:[function(e){t=e.r;i=e.c;o=e.h;r=e.H;a=e.F;s=e.g},function(e){n=e.VerdocsEndpoint;c=e.getTemplateDocumentPageDisplayUri;l=e.getTemplate},function(e){d=e.t;u=e.j;h=e.g},function(e){p=e.S},function(e){f=e.c},function(){},function(){},function(){}],execute:function(){var b="@-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-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 rgba(0, 0, 0, 0.0588235294);box-shadow:0 0 10px 5px rgba(0, 0, 0, 0.0588235294)}verdocs-template-document-page .verdocs-template-document-page-layer.img{width:100%}verdocs-template-document-page .placeholder{opacity:0.1;width:612px;height:792px;-webkit-box-shadow:0 0 10px 5px rgba(0, 0, 0, 0.0588235294);box-shadow:0 0 10px 5px rgba(0, 0, 0, 0.0588235294)}";var v=b;var m=e("verdocs_template_document_page",function(){function e(e){t(this,e);this.pageRendered=i(this,"pageRendered",7);this.templateListenerId=null;this.endpoint=n.getDefault();this.editable=false;this.disabled=false;this.done=false;this.templateId="";this.documentId="";this.pageNumber=1;this.virtualWidth=612;this.virtualHeight=792;this.layers=[{name:"page",type:"canvas"}];this.containerId="verdocs-document-page-".concat(Math.random().toString(36).substring(2,11));this.renderedWidth=this.virtualWidth;this.renderedHeight=this.virtualHeight;this.naturalWidth=this.virtualWidth;this.naturalHeight=this.virtualHeight;this.aspectRatio=this.virtualWidth/this.virtualHeight;this.skipFirstNotification=true;this.pageDisplayUri="";this.xScale=1;this.yScale=1;this.loading=true;this.template=null}e.prototype.componentWillLoad=function(){return __awaiter(this,void 0,void 0,(function(){var e;return __generator(this,(function(t){switch(t.label){case 0:e=this;return[4,c(this.endpoint,this.documentId,this.pageNumber)];case 1:e.pageDisplayUri=t.sent();this.listenToTemplate();return[2]}}))}))};e.prototype.componentDidLoad=function(){var e=this;this.resizeObserver=new ResizeObserver(d((function(t){for(var i=0,o=t;i<o.length;i++){var r=o[i];var a=r.contentRect.width;e.renderedWidth=a;e.renderedHeight=e.virtualHeight*(a/e.virtualWidth)}e.notifyRenderedSize()}),100));this.resizeObserver.observe(this.container)};e.prototype.componentDidUpdate=function(){this.notifyRenderedSize()};e.prototype.disconnectedCallback=function(){var e;(e=this.resizeObserver)===null||e===void 0?void 0:e.disconnect();this.unlistenToTemplate()};e.prototype.listenToTemplate=function(){return __awaiter(this,void 0,void 0,(function(){var e=this;return __generator(this,(function(t){this.unlistenToTemplate();p.subscribe("templates",this.templateId,(function(){return l(e.endpoint,e.templateId)}),false,(function(t){e.template=t;e.loading=false}));return[2]}))}))};e.prototype.unlistenToTemplate=function(){if(this.templateListenerId){p.store.delListener(this.templateListenerId);this.templateListenerId=null}};e.prototype.notifyRenderedSize=function(){if(this.skipFirstNotification){this.skipFirstNotification=false;return}var e=this.renderedWidth/this.virtualWidth;if(this.xScale!==e){this.xScale=e}var t=this.renderedHeight/this.virtualHeight;if(this.yScale!==t){this.yScale=t}this.pageRendered.emit({containerId:this.containerId,documentId:this.documentId,pageNumber:this.pageNumber,virtualWidth:this.virtualWidth,virtualHeight:this.virtualHeight,renderedWidth:this.renderedWidth,renderedHeight:this.renderedHeight,naturalWidth:this.naturalWidth,naturalHeight:this.naturalHeight,aspectRatio:this.aspectRatio,xScale:e,yScale:t})};e.prototype.render=function(){var e=this;if(this.loading){return o(r,null,o("img",{src:"https://public-assets.verdocs.com/loading-placeholder.png",class:"placeholder",alt:"Placeholder page"}))}var t="".concat(this.renderedHeight,"px");return o(r,{id:"".concat(this.containerId),style:{height:t,flex:"0 0 ".concat(t)}},this.layers.map((function(i){var r;return i.type==="div"?o("div",{class:"verdocs-template-document-page-layer",id:"".concat(e.containerId,"-").concat(i.name),style:{height:t}},i.name==="controls"&&(((r=e.template)===null||r===void 0?void 0:r.fields)||[]).filter((function(t){return t&&t.page===e.pageNumber})).map((function(t){var i,r;var s=h(t);var n=t.name,c=t.type,l=t.multiline;var d=e,p=d.xScale,f=d.yScale,b=d.templateId,v=d.editable,m=d.disabled,g=d.done,y=d.pageNumber;if(((i=t["setting"])===null||i===void 0?void 0:i.leading)>0||((r=t["settings"])===null||r===void 0?void 0:r.leading)>0){c="textarea";l=true}switch(c){case"textbox":return o("verdocs-field-textbox",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,multiline:l,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});case"textarea":return o("verdocs-field-textarea",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});case"date":return o("verdocs-field-date",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});case"attachment":return o("verdocs-field-attachment",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});case"dropdown":return o("verdocs-field-dropdown",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});case"initial":return o("verdocs-field-initial",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});case"signature":return o("verdocs-field-signature",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,e.xScale,e.yScale)});case"timestamp":return o("verdocs-field-timestamp",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});case"checkbox":return o("verdocs-field-checkbox",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});case"radio":return o("verdocs-field-radio",{id:s,fieldname:n,source:"template",sourceid:b,editable:v,disabled:m,done:g,xscale:p,yscale:f,pagenumber:y,style:u(t,p,f)});default:return o(a,null,n)}}))):e.pageDisplayUri?o("img",{class:"verdocs-template-document-page-layer img",id:"".concat(e.containerId,"-").concat(i.name),src:e.pageDisplayUri,alt:"Page ".concat(e.pageNumber),"aria-hidden":true,loading:"lazy",onLoad:function(t){e.naturalWidth=t.target.naturalWidth;e.naturalHeight=t.target.naturalHeight;e.aspectRatio=e.naturalWidth/e.naturalHeight;e.virtualHeight=e.virtualWidth/e.aspectRatio;e.renderedHeight=t.target.offsetWidth/e.aspectRatio}}):o("div",null)})))};Object.defineProperty(e.prototype,"container",{get:function(){return s(this)},enumerable:false,configurable:true});return e}());m.style=v;var g='@-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-toolbar-icon{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif;display:inline-block}verdocs-toolbar-icon .icon{display:inline-block;cursor:pointer}verdocs-toolbar-icon .icon svg{fill:#5c6575}verdocs-toolbar-icon .tooltip{display:none;-webkit-box-shadow:0 0 10px 1px #999999;box-shadow:0 0 10px 1px #999999;background:#ffffff;color:#33364b;max-width:240px;font-weight:bold;padding:5px 10px;font-size:13px;position:relative;border-radius:4px;z-index:20000;white-space:nowrap}verdocs-toolbar-icon .tooltip .arrow,verdocs-toolbar-icon .tooltip .arrow::before{position:absolute;width:8px;height:8px;background:inherit}verdocs-toolbar-icon .tooltip .arrow{visibility:hidden;top:-4px}verdocs-toolbar-icon .tooltip .arrow::before{visibility:visible;content:"";-webkit-transform:rotate(45deg);transform:rotate(45deg)}verdocs-toolbar-icon .tooltip[data-show]{display:block}verdocs-toolbar-icon .tooltip[data-popper-placement^=top]>.arrow{bottom:-4px}verdocs-toolbar-icon .tooltip[data-popper-placement^=bottom]>.arrow{top:-4px}verdocs-toolbar-icon .tooltip[data-popper-placement^=left]>.arrow{right:-4px}verdocs-toolbar-icon .tooltip[data-popper-placement^=right]>.arrow{left:-4px}verdocs-toolbar-icon .tooltip[data-popper-placement^=left]{padding:3px 10px}verdocs-toolbar-icon .tooltip[data-popper-placement^=left]>.arrow{right:-1px}';var y=g;var x=e("verdocs_toolbar_icon",function(){function e(e){t(this,e);this.text="";this.icon="";this.placement="bottom";this.containerId="verdocs-toolbar-icon-".concat(Math.random().toString(36).substring(2,11))}e.prototype.componentDidLoad=function(){this.popperInstance=f(this.iconEl,this.tooltip,{placement:this.placement,modifiers:this.placement==="left"?[{name:"offset",options:{offset:[0,20]}}]:[]})};e.prototype.disconnectedCallback=function(){if(this.popperInstance){this.popperInstance.destroy();this.popperInstance=null}};e.prototype.show=function(){var e,t;(e=this.tooltip)===null||e===void 0?void 0:e.setAttribute("data-show","");(t=this.popperInstance)===null||t===void 0?void 0:t.update().catch((function(){}))};e.prototype.hide=function(){var e;(e=this.tooltip)===null||e===void 0?void 0:e.removeAttribute("data-show")};e.prototype.render=function(){var e=this;return o(r,{key:"98b2f6b2a2711df2cf8e687e38684d495b6e7d50",class:{}},o("div",{key:"49500d4d3348e2ccd6c9cbe7867645756c6cf5ef","aria-describedby":this.containerId,class:"icon",innerHTML:this.icon,onMouseEnter:function(){return e.show()},onFocus:function(){return e.show()},onMouseLeave:function(){return e.hide()},onBlur:function(){return e.hide()},ref:function(t){return e.iconEl=t}}),o("div",{key:"e64aa823a8a09b10a9166f96be633439d959d3ff",id:this.containerId,role:"tooltip",class:"tooltip","data-popper-placement":this.placement,ref:function(t){return e.tooltip=t}},this.text,o("div",{key:"399156e882824870173ecf3e4bcc35f2ba720b8c","data-popper-arrow":"true",class:"arrow"})))};return e}());x.style=y}}}));
|
@@ -1 +1 @@
|
|
1
|
-
var __awaiter=this&&this.__awaiter||function(e,t,a,n){function i(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,s){function o(e){try{l(n.next(e))}catch(e){s(e)}}function d(e){try{l(n["throw"](e))}catch(e){s(e)}}function l(e){e.done?a(e.value):i(e.value).then(o,d)}l((n=n.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var a={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},n,i,s,o;return o={next:d(0),throw:d(1),return:d(2)},typeof Symbol==="function"&&(o[Symbol.iterator]=function(){return this}),o;function d(e){return function(t){return l([e,t])}}function l(d){if(n)throw new TypeError("Generator is already executing.");while(o&&(o=0,d[0]&&(a=0)),a)try{if(n=1,i&&(s=d[0]&2?i["return"]:d[0]?i["throw"]||((s=i["return"])&&s.call(i),0):i.next)&&!(s=s.call(i,d[1])).done)return s;if(i=0,s)d=[d[0]&2,s.value];switch(d[0]){case 0:case 1:s=d;break;case 4:a.label++;return{value:d[1],done:false};case 5:a.label++;i=d[1];d=[0];continue;case 7:d=a.ops.pop();a.trys.pop();continue;default:if(!(s=a.trys,s=s.length>0&&s[s.length-1])&&(d[0]===6||d[0]===2)){a=0;continue}if(d[0]===3&&(!s||d[1]>s[0]&&d[1]<s[3])){a.label=d[1];break}if(d[0]===6&&a.label<s[1]){a.label=s[1];s=d;break}if(s&&a.label<s[2]){a.label=s[2];a.ops.push(d);break}if(s[2])a.ops.pop();a.trys.pop();continue}d=t.call(e,a)}catch(e){d=[6,e];i=0}finally{n=s=0}if(d[0]&5)throw d[1];return{value:d[0]?d[1]:void 0,done:true}}};System.register(["./p-9186f42e.system.js","./p-56ba5cbf.system.js"],(function(e,t){"use strict";var a,n,i;return{setters:[function(t){a=t.p;n=t.b;e("setNonce",t.s)},function(e){i=e.g}],execute:function(){var e=this;var s=function(){var e=t.meta.url;var n={};if(e!==""){n.resourcesUrl=new URL(".",e).href}return a(n)};s().then((function(t){return __awaiter(e,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return[4,i()];case 1:e.sent();return[2,n(JSON.parse('[["p-5aa76635.system",[[0,"verdocs-build",{"endpoint":[16],"templateId":[1537,"template-id"],"step":[1537],"loading":[32],"template":[32]},null,{"templateId":["onTemplateIdChanged"],"step":["onStepChanged"]}]]],["p-899617aa.system",[[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"]}]]],["p-62217123.system",[[0,"verdocs-sign",{"endpoint":[1040],"envelopeId":[513,"envelope-id"],"roleId":[513,"role-id"],"inviteCode":[513,"invite-code"],"headerTargetId":[1,"header-target-id"],"roleNames":[32],"sortedRecipients":[32],"recipient":[32],"hasSignature":[32],"nextButtonLabel":[32],"nextSubmits":[32],"fatalErrorHeader":[32],"fatalErrorMessage":[32],"focusedField":[32],"submitting":[32],"submitted":[32],"isDone":[32],"showDone":[32],"showLoadError":[32],"finishLater":[32],"showFinishLater":[32],"agreed":[32],"documentsSingularPlural":[32],"kbaStep":[32],"kbaQuestions":[32],"showSpinner":[32],"kbaChoices":[32],"loading":[32],"envelope":[32]}]]],["p-53f4c7c3.system",[[0,"verdocs-templates-list",{"endpoint":[16],"visibility":[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"]}]]],["p-7e73805f.system",[[0,"verdocs-field-payment",{"source":[513],"sourceid":[513],"fieldname":[513],"disabled":[516],"done":[516],"editable":[516],"moveable":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"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"],"signed":[4],"roleindex":[2],"showingProperties":[32],"focused":[32],"preparedMessage":[32],"signatureUrl":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}]]],["p-917aab58.system",[[0,"verdocs-envelope-sidebar",{"endpoint":[16],"envelopeId":[1,"envelope-id"],"activeTab":[32],"panelOpen":[32],"showRecipientDialog":[32],"showCancelDialog":[32],"remindersEnabled":[32],"updatingReminders":[32],"initialReminder":[32],"followupReminders":[32],"loading":[32],"envelope":[32]}]]],["p-cbb75c5e.system",[[0,"verdocs-template-create",{"endpoint":[16],"maxSize":[1026,"max-size"],"file":[32],"creating":[32],"progressLabel":[32],"progressPercent":[32],"errorMessage":[32]}]]],["p-4e9e154f.system",[[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]}]]],["p-5b0cd815.system",[[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],"recipientStatusIcons":[32],"containerId":[32],"gettingLinks":[32],"links":[32],"loading":[32],"envelope":[32]}]]],["p-1d5b9103.system",[[4,"verdocs-dialog"]]],["p-90bc3ad0.system",[[0,"verdocs-quick-functions",{"endpoint":[16]}]]],["p-6237ce51.system",[[0,"verdocs-radio-button",{"checked":[4],"name":[1],"value":[1],"disabled":[4]}]]],["p-d5870e33.system",[[0,"verdocs-search-box",{"endpoint":[16],"placeholder":[1],"type":[1],"query":[1],"grabsFocus":[4,"grabs-focus"],"focusField":[64]}]]],["p-ac6ecfad.system",[[0,"verdocs-search-tabs",{"selected":[32]}]]],["p-9227d400.system",[[0,"verdocs-table",{"columns":[16],"data":[16]}]]],["p-ad3d07a6.system",[[0,"verdocs-template-card",{"template":[16]}]]],["p-5824962b.system",[[0,"verdocs-template-tags",{"tags":[16]}]]],["p-761f6656.system",[[0,"verdocs-toggle",{"options":[16],"theme":[1],"selectedOption":[32]}]]],["p-2eae32d9.system",[[0,"verdocs-status-indicator",{"size":[1],"theme":[1],"status":[1],"envelope":[16],"isOpen":[32],"containerId":[32]}]]],["p-417f71da.system",[[0,"verdocs-template-star",{"endpoint":[16],"template":[1040],"updating":[32]}]]],["p-c253ae24.system",[[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]}]]],["p-1e191c20.system",[[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]}]]],["p-f3b5052f.system",[[0,"verdocs-view",{"endpoint":[16],"envelopeId":[1,"envelope-id"],"headerTargetId":[1,"header-target-id"],"canceling":[32],"showCancelDone":[32],"showLoadError":[32],"loading":[32],"envelope":[32]}],[0,"verdocs-kba-dialog",{"step":[2],"steps":[2],"helptitle":[1],"helptext":[1],"mode":[1],"label":[1],"placeholder":[1],"recipient":[16],"choices":[16],"response":[32],"updatedRecipient":[32]}]]],["p-ff8143df.system",[[0,"verdocs-envelope-recipient-link",{"endpoint":[16],"envelopeId":[1,"envelope-id"],"roleName":[1,"role-name"],"isOpen":[32],"gettingLink":[32],"link":[32],"loading":[32],"envelope":[32],"recipient":[32]}],[0,"verdocs-switch",{"checked":[1028],"theme":[1],"disabled":[4]}]]],["p-b029989a.system",[[0,"verdocs-template-role-properties",{"endpoint":[16],"templateId":[1,"template-id"],"roleName":[1,"role-name"],"dirty":[32],"saving":[32],"name":[32],"type":[32],"first_name":[32],"last_name":[32],"email":[32],"phone":[32],"delegator":[32],"loading":[32],"template":[32]}],[4,"verdocs-menu-panel",{"side":[1],"overlay":[4],"width":[2]},[[4,"click","handleClick"]]]]],["p-e438bd02.system",[[4,"verdocs-button-panel",{"icon":[1],"showPanel":[64],"hidePanel":[64],"toggle":[64]}],[4,"verdocs-tabs",{"tabs":[16],"selectedTab":[2,"selected-tab"]}]]],["p-c94b0dc5.system",[[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]}]]],["p-94fe5817.system",[[0,"verdocs-ok-dialog",{"heading":[1],"message":[1],"buttonLabel":[1,"button-label"],"showCancel":[4,"show-cancel"],"closed":[32]}]]],["p-c60743ac.system",[[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],"loading":[32],"template":[32]}]]],["p-5ce491ac.system",[[0,"verdocs-contact-picker",{"endpoint":[16],"templateRole":[16],"contactSuggestions":[16],"first_name":[32],"last_name":[32],"email":[32],"phone":[32],"zip":[32],"address":[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]}]]],["p-e6d711e0.system",[[0,"verdocs-file-chooser",{"endpoint":[16],"file":[32]}],[0,"verdocs-progress-bar",{"label":[1],"showPercent":[4,"show-percent"],"percent":[2]}]]],["p-f84932fd.system",[[0,"verdocs-spinner",{"size":[2],"mode":[1]}]]],["p-306bde40.system",[[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"]]]]],["p-d8dae4e9.system",[[0,"verdocs-dropdown",{"options":[16],"containerId":[32],"showPicker":[32]}]]],["p-cb7aa6b8.system",[[0,"verdocs-template-field-properties",{"endpoint":[16],"templateId":[1,"template-id"],"fieldName":[1025,"field-name"],"helpText":[1,"help-text"],"dirty":[32],"label":[32],"type":[32],"name":[32],"required":[32],"roleName":[32],"group":[32],"fieldType":[32],"options":[32],"placeholder":[32],"defaultValue":[32],"showingHelp":[32],"loading":[32],"template":[32]}],[0,"verdocs-checkbox",{"checked":[4],"name":[1],"label":[1],"value":[1],"theme":[1],"disabled":[4]}],[0,"verdocs-select-input",{"value":[1],"label":[1],"options":[16],"disabled":[4]}],[0,"verdocs-component-error",{"message":[1]}],[0,"verdocs-loader"],[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]}]]],["p-c3f825d4.system",[[0,"verdocs-field-attachment",{"endpoint":[16],"source":[513],"sourceid":[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",{"source":[513],"sourceid":[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",{"source":[513],"sourceid":[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",{"source":[513],"sourceid":[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",{"source":[513],"sourceid":[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",{"source":[513],"sourceid":[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",{"source":[513],"sourceid":[513],"fieldname":[513],"disabled":[516],"required":[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],"source":[513],"sourceid":[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",{"source":[513],"sourceid":[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",{"source":[513],"sourceid":[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",{"maxSize":[1026,"max-size"],"existingFile":[1032,"existing-file"],"draggingOver":[32],"confirmDelete":[32],"selectedFiles":[32],"errorMessage":[32]}]]],["p-66bf3ba8.system",[[0,"verdocs-template-fields",{"endpoint":[16],"templateId":[1537,"template-id"],"toolbarTargetId":[1,"toolbar-target-id"],"placing":[32],"showMustSelectRole":[32],"selectedRoleName":[32],"loading":[32],"template":[32]},[[4,"keydown","handleKeyDown"]],{"templateId":["onTemplateIdChanged"]}],[0,"verdocs-preview",{"endpoint":[16],"templateId":[1,"template-id"],"loading":[32],"template":[32]},null,{"templateId":["onTemplateIdChanged"]}],[0,"verdocs-send",{"endpoint":[16],"templateId":[513,"template-id"],"environment":[1],"containerId":[32],"showPickerForId":[32],"sessionContacts":[32],"sending":[32],"rolesCompleted":[32],"loading":[32],"template":[32],"reset":[64]},null,{"templateId":["onTemplateIdChanged"]}],[0,"verdocs-template-roles",{"endpoint":[16],"templateId":[1,"template-id"],"showingRoleDialog":[32],"sender":[32],"dragging":[32],"loading":[32],"template":[32]}],[0,"verdocs-template-attachments",{"endpoint":[16],"templateId":[1,"template-id"],"uploading":[32],"progressLabel":[32],"progressPercent":[32],"showDeleteError":[32],"confirmDeleteDocument":[32],"loading":[32],"template":[32]}],[0,"verdocs-template-build-tabs",{"endpoint":[16],"templateId":[1537,"template-id"],"step":[1537],"loading":[32],"template":[32]},null,{"templateId":["onTemplateIdChanged"],"step":["onStepChanged"]}]]]]'),t)]}}))}))}))}}}));
|
1
|
+
var __awaiter=this&&this.__awaiter||function(e,t,a,i){function n(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,s){function d(e){try{l(i.next(e))}catch(e){s(e)}}function o(e){try{l(i["throw"](e))}catch(e){s(e)}}function l(e){e.done?a(e.value):n(e.value).then(d,o)}l((i=i.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var a={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,n,s,d;return d={next:o(0),throw:o(1),return:o(2)},typeof Symbol==="function"&&(d[Symbol.iterator]=function(){return this}),d;function o(e){return function(t){return l([e,t])}}function l(o){if(i)throw new TypeError("Generator is already executing.");while(d&&(d=0,o[0]&&(a=0)),a)try{if(i=1,n&&(s=o[0]&2?n["return"]:o[0]?n["throw"]||((s=n["return"])&&s.call(n),0):n.next)&&!(s=s.call(n,o[1])).done)return s;if(n=0,s)o=[o[0]&2,s.value];switch(o[0]){case 0:case 1:s=o;break;case 4:a.label++;return{value:o[1],done:false};case 5:a.label++;n=o[1];o=[0];continue;case 7:o=a.ops.pop();a.trys.pop();continue;default:if(!(s=a.trys,s=s.length>0&&s[s.length-1])&&(o[0]===6||o[0]===2)){a=0;continue}if(o[0]===3&&(!s||o[1]>s[0]&&o[1]<s[3])){a.label=o[1];break}if(o[0]===6&&a.label<s[1]){a.label=s[1];s=o;break}if(s&&a.label<s[2]){a.label=s[2];a.ops.push(o);break}if(s[2])a.ops.pop();a.trys.pop();continue}o=t.call(e,a)}catch(e){o=[6,e];n=0}finally{i=s=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:true}}};System.register(["./p-9186f42e.system.js","./p-56ba5cbf.system.js"],(function(e,t){"use strict";var a,i,n;return{setters:[function(t){a=t.p;i=t.b;e("setNonce",t.s)},function(e){n=e.g}],execute:function(){var e=this;var s=function(){var e=t.meta.url;var i={};if(e!==""){i.resourcesUrl=new URL(".",e).href}return a(i)};s().then((function(t){return __awaiter(e,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return[4,n()];case 1:e.sent();return[2,i(JSON.parse('[["p-9021fc7b.system",[[0,"verdocs-build",{"endpoint":[16],"templateId":[1537,"template-id"],"step":[1537],"loading":[32],"template":[32]},null,{"templateId":["onTemplateIdChanged"],"step":["onStepChanged"]}]]],["p-b0fbfc24.system",[[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"]}]]],["p-ba92b80b.system",[[0,"verdocs-sign",{"endpoint":[1040],"envelopeId":[513,"envelope-id"],"roleId":[513,"role-id"],"inviteCode":[513,"invite-code"],"headerTargetId":[1,"header-target-id"],"roleNames":[32],"sortedRecipients":[32],"recipient":[32],"hasSignature":[32],"nextButtonLabel":[32],"nextSubmits":[32],"fatalErrorHeader":[32],"fatalErrorMessage":[32],"focusedField":[32],"submitting":[32],"submitted":[32],"isDone":[32],"showDone":[32],"showLoadError":[32],"finishLater":[32],"showFinishLater":[32],"agreed":[32],"documentsSingularPlural":[32],"kbaStep":[32],"kbaQuestions":[32],"showSpinner":[32],"kbaChoices":[32],"loading":[32],"envelope":[32]}]]],["p-53f4c7c3.system",[[0,"verdocs-templates-list",{"endpoint":[16],"visibility":[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"]}]]],["p-3cc50f0b.system",[[0,"verdocs-field-payment",{"source":[513],"sourceid":[513],"fieldname":[513],"field":[16],"disabled":[516],"done":[516],"editable":[516],"moveable":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"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"],"signed":[4],"roleindex":[2],"showingProperties":[32],"focused":[32],"preparedMessage":[32],"signatureUrl":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}]]],["p-00ed440b.system",[[0,"verdocs-envelope-sidebar",{"endpoint":[16],"envelopeId":[1,"envelope-id"],"activeTab":[32],"panelOpen":[32],"showRecipientDialog":[32],"showCancelDialog":[32],"remindersEnabled":[32],"updatingReminders":[32],"initialReminder":[32],"followupReminders":[32],"loading":[32],"envelope":[32]}]]],["p-cbb75c5e.system",[[0,"verdocs-template-create",{"endpoint":[16],"maxSize":[1026,"max-size"],"file":[32],"creating":[32],"progressLabel":[32],"progressPercent":[32],"errorMessage":[32]}]]],["p-4e9e154f.system",[[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]}]]],["p-19462841.system",[[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],"recipientStatusIcons":[32],"containerId":[32],"gettingLinks":[32],"links":[32],"loading":[32],"envelope":[32]}]]],["p-1d5b9103.system",[[4,"verdocs-dialog"]]],["p-90bc3ad0.system",[[0,"verdocs-quick-functions",{"endpoint":[16]}]]],["p-6237ce51.system",[[0,"verdocs-radio-button",{"checked":[4],"name":[1],"value":[1],"disabled":[4]}]]],["p-d5870e33.system",[[0,"verdocs-search-box",{"endpoint":[16],"placeholder":[1],"type":[1],"query":[1],"grabsFocus":[4,"grabs-focus"],"focusField":[64]}]]],["p-ac6ecfad.system",[[0,"verdocs-search-tabs",{"selected":[32]}]]],["p-9227d400.system",[[0,"verdocs-table",{"columns":[16],"data":[16]}]]],["p-ad3d07a6.system",[[0,"verdocs-template-card",{"template":[16]}]]],["p-5824962b.system",[[0,"verdocs-template-tags",{"tags":[16]}]]],["p-761f6656.system",[[0,"verdocs-toggle",{"options":[16],"theme":[1],"selectedOption":[32]}]]],["p-2eae32d9.system",[[0,"verdocs-status-indicator",{"size":[1],"theme":[1],"status":[1],"envelope":[16],"isOpen":[32],"containerId":[32]}]]],["p-417f71da.system",[[0,"verdocs-template-star",{"endpoint":[16],"template":[1040],"updating":[32]}]]],["p-7b1e00e5.system",[[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]}]]],["p-1e191c20.system",[[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]}]]],["p-e3077c5e.system",[[0,"verdocs-view",{"endpoint":[16],"envelopeId":[1,"envelope-id"],"headerTargetId":[1,"header-target-id"],"canceling":[32],"showCancelDone":[32],"showLoadError":[32],"loading":[32],"envelope":[32]}],[0,"verdocs-kba-dialog",{"step":[2],"steps":[2],"helptitle":[1],"helptext":[1],"mode":[1],"label":[1],"placeholder":[1],"recipient":[16],"choices":[16],"response":[32],"updatedRecipient":[32]}]]],["p-fda9c437.system",[[0,"verdocs-envelope-recipient-link",{"endpoint":[16],"envelopeId":[1,"envelope-id"],"roleName":[1,"role-name"],"isOpen":[32],"gettingLink":[32],"link":[32],"loading":[32],"envelope":[32],"recipient":[32]}],[0,"verdocs-switch",{"checked":[1028],"theme":[1],"disabled":[4]}]]],["p-ea078594.system",[[0,"verdocs-template-role-properties",{"endpoint":[16],"templateId":[1,"template-id"],"roleName":[1,"role-name"],"dirty":[32],"saving":[32],"name":[32],"type":[32],"first_name":[32],"last_name":[32],"email":[32],"phone":[32],"delegator":[32],"loading":[32],"template":[32]}],[4,"verdocs-menu-panel",{"side":[1],"overlay":[4],"width":[2]},[[4,"click","handleClick"]]]]],["p-e438bd02.system",[[4,"verdocs-button-panel",{"icon":[1],"showPanel":[64],"hidePanel":[64],"toggle":[64]}],[4,"verdocs-tabs",{"tabs":[16],"selectedTab":[2,"selected-tab"]}]]],["p-6b4de004.system",[[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]}]]],["p-94fe5817.system",[[0,"verdocs-ok-dialog",{"heading":[1],"message":[1],"buttonLabel":[1,"button-label"],"showCancel":[4,"show-cancel"],"closed":[32]}]]],["p-bbf30adc.system",[[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],"loading":[32],"template":[32]}]]],["p-8d7d61ee.system",[[0,"verdocs-contact-picker",{"endpoint":[16],"templateRole":[16],"contactSuggestions":[16],"first_name":[32],"last_name":[32],"email":[32],"phone":[32],"zip":[32],"address":[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]}]]],["p-e6d711e0.system",[[0,"verdocs-file-chooser",{"endpoint":[16],"file":[32]}],[0,"verdocs-progress-bar",{"label":[1],"showPercent":[4,"show-percent"],"percent":[2]}]]],["p-f84932fd.system",[[0,"verdocs-spinner",{"size":[2],"mode":[1]}]]],["p-306bde40.system",[[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"]]]]],["p-d8dae4e9.system",[[0,"verdocs-dropdown",{"options":[16],"containerId":[32],"showPicker":[32]}]]],["p-eb3ceb39.system",[[0,"verdocs-template-field-properties",{"endpoint":[16],"templateId":[1,"template-id"],"fieldName":[1025,"field-name"],"helpText":[1,"help-text"],"dirty":[32],"label":[32],"type":[32],"name":[32],"required":[32],"roleName":[32],"group":[32],"fieldType":[32],"options":[32],"placeholder":[32],"defaultValue":[32],"showingHelp":[32],"loading":[32],"template":[32]}],[0,"verdocs-checkbox",{"checked":[4],"name":[1],"label":[1],"value":[1],"theme":[1],"disabled":[4]}],[0,"verdocs-select-input",{"value":[1],"label":[1],"options":[16],"disabled":[4]}],[0,"verdocs-component-error",{"message":[1]}],[0,"verdocs-loader"],[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]}]]],["p-8bdd951b.system",[[0,"verdocs-field-attachment",{"endpoint":[16],"source":[513],"sourceid":[513],"fieldname":[513],"field":[16],"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",{"source":[513],"sourceid":[513],"fieldname":[513],"field":[16],"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",{"source":[513],"sourceid":[513],"fieldname":[513],"field":[16],"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",{"source":[513],"sourceid":[513],"fieldname":[513],"field":[16],"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",{"source":[513],"sourceid":[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",{"source":[513],"sourceid":[513],"fieldname":[513],"field":[16],"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",{"source":[513],"sourceid":[513],"fieldname":[513],"field":[16],"disabled":[516],"required":[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],"source":[513],"sourceid":[513],"fieldname":[513],"field":[16],"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",{"source":[513],"sourceid":[513],"fieldname":[513],"field":[16],"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",{"source":[513],"sourceid":[513],"fieldname":[513],"field":[16],"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",{"maxSize":[1026,"max-size"],"existingFile":[1032,"existing-file"],"draggingOver":[32],"confirmDelete":[32],"selectedFiles":[32],"errorMessage":[32]}]]],["p-2b7edf3a.system",[[0,"verdocs-template-fields",{"endpoint":[16],"templateId":[1537,"template-id"],"toolbarTargetId":[1,"toolbar-target-id"],"placing":[32],"showMustSelectRole":[32],"selectedRoleName":[32],"loading":[32],"template":[32]},[[4,"keydown","handleKeyDown"]],{"templateId":["onTemplateIdChanged"]}],[0,"verdocs-preview",{"endpoint":[16],"templateId":[1,"template-id"],"loading":[32],"template":[32]},null,{"templateId":["onTemplateIdChanged"]}],[0,"verdocs-send",{"endpoint":[16],"templateId":[513,"template-id"],"environment":[1],"containerId":[32],"showPickerForId":[32],"sessionContacts":[32],"sending":[32],"rolesCompleted":[32],"loading":[32],"template":[32],"reset":[64]},null,{"templateId":["onTemplateIdChanged"]}],[0,"verdocs-template-roles",{"endpoint":[16],"templateId":[1,"template-id"],"showingRoleDialog":[32],"sender":[32],"dragging":[32],"loading":[32],"template":[32]}],[0,"verdocs-template-attachments",{"endpoint":[16],"templateId":[1,"template-id"],"uploading":[32],"progressLabel":[32],"progressPercent":[32],"showDeleteError":[32],"confirmDeleteDocument":[32],"loading":[32],"template":[32]}],[0,"verdocs-template-build-tabs",{"endpoint":[16],"templateId":[1537,"template-id"],"step":[1537],"loading":[32],"template":[32]},null,{"templateId":["onTemplateIdChanged"],"step":["onStepChanged"]}]]]]'),t)]}}))}))}))}}}));
|
@@ -1 +1 @@
|
|
1
|
-
var __assign=this&&this.__assign||function(){__assign=Object.assign||function(e){for(var i,t=1,n=arguments.length;t<n;t++){i=arguments[t];for(var o in i)if(Object.prototype.hasOwnProperty.call(i,o))e[o]=i[o]}return e};return __assign.apply(this,arguments)};var __awaiter=this&&this.__awaiter||function(e,i,t,n){function o(e){return e instanceof t?e:new t((function(i){i(e)}))}return new(t||(t=Promise))((function(t,s){function r(e){try{a(n.next(e))}catch(e){s(e)}}function l(e){try{a(n["throw"](e))}catch(e){s(e)}}function a(e){e.done?t(e.value):o(e.value).then(r,l)}a((n=n.apply(e,i||[])).next())}))};var __generator=this&&this.__generator||function(e,i){var t={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},n,o,s,r;return r={next:l(0),throw:l(1),return:l(2)},typeof Symbol==="function"&&(r[Symbol.iterator]=function(){return this}),r;function l(e){return function(i){return a([e,i])}}function a(l){if(n)throw new TypeError("Generator is already executing.");while(r&&(r=0,l[0]&&(t=0)),t)try{if(n=1,o&&(s=l[0]&2?o["return"]:l[0]?o["throw"]||((s=o["return"])&&s.call(o),0):o.next)&&!(s=s.call(o,l[1])).done)return s;if(o=0,s)l=[l[0]&2,s.value];switch(l[0]){case 0:case 1:s=l;break;case 4:t.label++;return{value:l[1],done:false};case 5:t.label++;o=l[1];l=[0];continue;case 7:l=t.ops.pop();t.trys.pop();continue;default:if(!(s=t.trys,s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){t=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){t.label=l[1];break}if(l[0]===6&&t.label<s[1]){t.label=s[1];s=l;break}if(s&&t.label<s[2]){t.label=s[2];t.ops.push(l);break}if(s[2])t.ops.pop();t.trys.pop();continue}l=i.call(e,t)}catch(e){l=[6,e];o=0}finally{n=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:true}}};System.register(["./p-9186f42e.system.js","@verdocs/js-sdk","./p-736a2c41.system.js","./p-c8a15cb7.system.js","./p-55de8cd1.system.js","./p-21b1acec.system.js","./p-d738b5db.system.js","./p-2c5350ec.system.js"],(function(e){"use strict";var i,t,n,o,s,r,l,a,d,c,u,f,h,p,v;return{setters:[function(e){i=e.r;t=e.c;n=e.h;o=e.F;s=e.H;r=e.g},function(e){l=e.VerdocsEndpoint;a=e.getEnvelope;d=e.getDocumentDownloadLink;c=e.cancelEnvelope;u=e.userCanCancelEnvelope;f=e.integerSequence},function(e){h=e.s},function(e){p=e.S},function(e){v=e.S},function(){},function(){},function(){}],execute:function(){var x='@-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-kba-dialog{font-family:"Inter", "Barlow", sans-serif;-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-kba-dialog div{-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-kba-dialog .background-overlay{position:fixed;z-index:10000;top:0;left:0;right:0;bottom:0;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;background:rgba(0, 0, 0, 0.4980392157)}verdocs-kba-dialog .dialog{width:440px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;border-radius:4px;overflow:hidden;background:#fff;padding:16px;gap:14px;-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-kba-dialog .heading{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;font-size:20px;font-weight:500}verdocs-kba-dialog .step{margin-left:6px;color:#666}verdocs-kba-dialog .help-box{background-color:#707ae5;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;padding:14px;-ms-flex-align:center;align-items:center;color:white}verdocs-kba-dialog .help-details{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;margin-left:15px;font-size:14px}verdocs-kba-dialog .help-icon{width:40px;height:40px}verdocs-kba-dialog .help-title{font-weight:600;margin-bottom:4px}verdocs-kba-dialog .help-text{font-weight:400}verdocs-kba-dialog .input{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;gap:10px;-ms-flex-align:center;align-items:center;margin:16px 0 32px}verdocs-kba-dialog .input label{-ms-flex:0;flex:0;line-height:10px;font-weight:500;white-space:nowrap}verdocs-kba-dialog .input input{-ms-flex:1;flex:1;padding:2px 8px;border-radius:3px;border:1px solid #cccccc}verdocs-kba-dialog .field{gap:10px;margin:0;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;max-width:100%}verdocs-kba-dialog .field .required{color:red;position:relative;top:-0.5em;font-size:80%}verdocs-kba-dialog .field label{-ms-flex:0 0 100px;flex:0 0 100px;font-weight:500;line-height:10px;text-align:right;white-space:nowrap}verdocs-kba-dialog .field input{width:40%;-ms-flex-positive:1;flex-grow:1;padding:2px 8px;border-radius:3px;border:1px solid #cccccc}verdocs-kba-dialog .choices{display:grid;gap:15px;grid-template-columns:repeat(auto-fill, minmax(100px, 1fr));margin:0 0 15px 0}verdocs-kba-dialog .choice{border:1px solid #707ae5;border-radius:5px;display:-ms-flexbox;display:flex;height:60px;font-size:14px;padding:0 5px;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;text-align:center;color:#5c6575;cursor:pointer}verdocs-kba-dialog .choice.selected{background-color:#707ae5;color:#ffffff}verdocs-kba-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-kba-dialog .buttons verdocs-button{margin-left:16px}';var b=x;var g='<svg width="40" height="40" viewBox="0 0 40 40" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M20 0C8.95313 0 0 8.95313 0 20C0 31.0469 8.95313 40 20 40C31.0469 40 40 31.0469 40 20C40 8.95313 31.0469 0 20 0ZM20 36.25C11.0391 36.25 3.75 28.9602 3.75 20C3.75 11.0398 11.0391 3.75 20 3.75C28.9609 3.75 36.25 11.0398 36.25 20C36.25 28.9602 28.9609 36.25 20 36.25Z" fill="white"/><path d="M20 26.25C18.5938 26.25 17.5 27.3438 17.5 28.75C17.5 30.1562 18.5234 31.25 20 31.25C21.3359 31.25 22.5 30.1562 22.5 28.75C22.5 27.3438 21.3359 26.25 20 26.25ZM22.5859 10H18.5938C15.5469 10 13.125 12.4219 13.125 15.4688C13.125 16.4844 13.9844 17.3438 15 17.3438C16.0156 17.3438 16.875 16.4844 16.875 15.4688C16.875 14.5312 17.5859 13.75 18.5234 13.75H22.5156C23.5234 13.75 24.375 14.5312 24.375 15.4688C24.375 16.0938 24.0625 16.5703 23.5156 16.8828L19.0625 19.6094C18.4375 20 18.125 20.625 18.125 21.25V22.5C18.125 23.5156 18.9844 24.375 20 24.375C21.0156 24.375 21.875 23.5156 21.875 22.5V22.3438L25.3984 20.1562C27.0391 19.1406 28.0547 17.3438 28.0547 15.4688C28.125 12.4219 25.7031 10 22.5859 10Z" fill="#E7E7E7"/></svg>';var m=e("verdocs_kba_dialog",function(){function e(e){i(this,e);this.exit=t(this,"exit",7);this.pinEntered=t(this,"pinEntered",7);this.next=t(this,"next",7);this.step=1;this.steps=3;this.helptitle="Previous Addresses";this.helptext="Please select the address below that you have most recently lived at.";this.mode="choice";this.label="PIN";this.placeholder="Enter your PIN...";this.recipient=null;this.choices=["553 Arbor Dr","18 Lacey Ln","23A Ball Ct","2375 Cavallo Blvd","23-1 RR-7","151 Boulder Rd"];this.response="";this.updatedRecipient=null}e.prototype.componentDidLoad=function(){this.updatedRecipient=__assign({},this.recipient||{})};e.prototype.handleCancel=function(){this.exit.emit()};e.prototype.handleDismiss=function(e){if(e.target.class==="background-overlay"){e.preventDefault();this.handleCancel()}};e.prototype.handleDone=function(){this.next.emit(this.response);this.response=""};e.prototype.handleConfirmID=function(){this.next.emit(this.updatedRecipient)};e.prototype.render=function(){var e=this;var i,t,r,l,a,d,c,u,f,h,p;if(this.mode==="choice"){return n(s,null,n("div",{class:"background-overlay",onClick:function(i){return e.handleDismiss(i)}},n("div",{class:"dialog"},n("div",{class:"heading"},"Confirm Your Identity",this.steps>1?n("span",{class:"step"},"(",this.step,"/",this.steps,")"):n(o,null)),!!this.helptitle&&n("div",{class:"help-box"},n("div",{class:"help-icon",innerHTML:g}),n("div",{class:"help-details"},n("div",{class:"help-title"},this.helptitle),n("div",{class:"help-text"},this.helptext))),n("div",{class:"choices"},this.choices.map((function(i){return n("div",{class:"choice ".concat(i===e.response?"selected":""),onClick:function(){console.log("Selected",i);e.response=i}},i)}))),n("div",{class:"buttons"},n("verdocs-button",{label:"Cancel",variant:"outline",onClick:function(){return e.handleCancel()}}),n("verdocs-button",{label:this.step<this.steps?"Next":"Submit",onClick:function(){return e.handleDone()},disabled:!this.response})))))}if(this.mode==="identity"){return n(s,null,n("div",{class:"background-overlay",onClick:function(i){return e.handleDismiss(i)}},n("div",{class:"dialog"},n("div",{class:"heading"},"Confirm Your Identity"),!!this.helptitle&&n("div",{class:"help-box"},n("div",{class:"help-icon",innerHTML:g}),n("div",{class:"help-details"},n("div",{class:"help-title"},"Identity verification is required"),n("div",{class:"help-text"},"NOTE: Only four fields are required, but providing more details will allow us to complete the verification process more quickly."))),n("div",{class:"field"},n("label",{htmlFor:"verdocs-kba-first"},"Your Name:",n("span",{class:"required"},"*")),n("input",{required:true,type:"text",id:"verdocs-kba-first",name:"verdocs-kba-first",placeholder:"First name...",value:(i=this.updatedRecipient)===null||i===void 0?void 0:i.first_name,onInput:function(i){return e.updatedRecipient=__assign(__assign({},e.updatedRecipient),{first_name:i.target.value})}}),n("input",{type:"text",id:"verdocs-kba-last",name:"verdocs-kba-last",placeholder:"Last name...",required:true,value:(t=this.updatedRecipient)===null||t===void 0?void 0:t.last_name,onInput:function(i){return e.updatedRecipient=__assign(__assign({},e.updatedRecipient),{last_name:i.target.value})}})),n("div",{class:"field"},n("label",{htmlFor:"verdocs-kba-address"},"Address:",n("span",{class:"required"},"*")),n("input",{type:"text",id:"verdocs-kba-address",name:"verdocs-kba-address",placeholder:"Address...",value:(r=this.updatedRecipient)===null||r===void 0?void 0:r.address,onInput:function(i){return e.updatedRecipient=__assign(__assign({},e.updatedRecipient),{address:i.target.value})}})),n("div",{class:"field"},n("label",{htmlFor:"verdocs-kba-city"},"City:"),n("input",{type:"text",id:"verdocs-kba-city",name:"verdocs-kba-city",placeholder:"City...",value:(l=this.updatedRecipient)===null||l===void 0?void 0:l.city,onInput:function(i){return e.updatedRecipient=__assign(__assign({},e.updatedRecipient),{city:i.target.value})}})),n("div",{class:"field"},n("label",{htmlFor:"verdocs-kba-state"},"State:"),n("input",{type:"text",id:"verdocs-kba-state",name:"verdocs-kba-state",placeholder:"State...",value:(a=this.updatedRecipient)===null||a===void 0?void 0:a.state,onInput:function(i){return e.updatedRecipient=__assign(__assign({},e.updatedRecipient),{state:i.target.value})}})),n("div",{class:"field"},n("label",{htmlFor:"verdocs-kba-zip"},"Zip Code:",n("span",{class:"required"},"*")),n("input",{type:"text",id:"verdocs-kba-zip",name:"verdocs-kba-zip",placeholder:"Zip Code...",required:true,value:(d=this.updatedRecipient)===null||d===void 0?void 0:d.zip,onInput:function(i){return e.updatedRecipient=__assign(__assign({},e.updatedRecipient),{zip:i.target.value})}})),n("div",{class:"field"},n("label",{htmlFor:"verdocs-kba-address"},"SSN Last 4:"),n("input",{type:"text",id:"verdocs-kba-state",name:"verdocs-kba-state",placeholder:"Last 4 digits of your SSN...",value:(c=this.updatedRecipient)===null||c===void 0?void 0:c.ssn_last_4,onInput:function(i){return e.updatedRecipient=__assign(__assign({},e.updatedRecipient),{ssn_last_4:i.target.value})}})),n("div",{class:"buttons"},n("verdocs-button",{label:"Submit",onClick:function(){return e.handleConfirmID()},disabled:!((u=this.updatedRecipient)===null||u===void 0?void 0:u.first_name)||!((f=this.updatedRecipient)===null||f===void 0?void 0:f.last_name)||!((h=this.updatedRecipient)===null||h===void 0?void 0:h.address)||!((p=this.updatedRecipient)===null||p===void 0?void 0:p.zip)})))))}return n(s,null,n("div",{class:"background-overlay",onClick:function(i){return e.handleDismiss(i)}},n("div",{class:"dialog"},n("div",{class:"heading"},"Please Confirm Your Identity",this.steps>1?n("span",{class:"step"},"(",this.step,"/",this.steps,")"):n(o,null)),!!this.helptitle&&n("div",{class:"help-box"},n("div",{class:"help-icon",innerHTML:g}),n("div",{class:"help-details"},n("div",{class:"help-title"},this.helptitle),n("div",{class:"help-text"},this.helptext))),n("div",{class:"input"},n("label",{htmlFor:"verdocs-kba-input"},this.label),n("input",{type:"text",id:"verdocs-kba-input",name:"verdocs-kba-input",placeholder:this.placeholder,value:this.response,onInput:function(i){return e.response=i.target.value}})),n("div",{class:"buttons"},n("verdocs-button",{label:"Cancel",variant:"outline",onClick:function(){return e.handleCancel()}}),n("verdocs-button",{label:"Submit",onClick:function(){return e.handleDone()},disabled:!this.response})))))};return e}());m.style=b;var w='@-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-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)}@media all and (max-width: 500px){#verdocs-view-header{padding:0 10px}}#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}@media all and (max-width: 500px){#verdocs-view-header .inner{padding:0 10px}}#verdocs-view-header .logo{width:80px;display:none;margin:-6px 0 0 0}#verdocs-view-header .title{font-size:18px;font-weight:500;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}';var k=w;var y=e("verdocs_view",function(){function e(e){i(this,e);this.sdkError=t(this,"sdkError",7);this.envelopeUpdated=t(this,"envelopeUpdated",7);this.another=t(this,"another",7);this.view=t(this,"view",7);this.next=t(this,"next",7);this.envelopeListenerId=null;this.endpoint=null;this.envelopeId="";this.headerTargetId=null;this.canceling=false;this.showCancelDone=false;this.showLoadError=false;this.loading=true;this.envelope=null}e.prototype.componentWillLoad=function(){return __awaiter(this,void 0,void 0,(function(){var e,i,t,n,o;return __generator(this,(function(s){switch(s.label){case 0:if(!this.endpoint){this.endpoint=l.getDefault();this.endpoint.loadSession()}if(!this.envelopeId){console.error("[VIEW] Missing required envelopeId");return[2]}this.listenToEnvelope();if(!!this.envelope)return[3,4];s.label=1;case 1:s.trys.push([1,3,,4]);console.log("[VIEW] Loading envelope...");n=this;return[4,a(this.endpoint,this.envelopeId)];case 2:n.envelope=s.sent();console.log("[VIEW] Loaded envelope",this.envelope);return[3,4];case 3:o=s.sent();this.showLoadError=true;(e=this.sdkError)===null||e===void 0?void 0:e.emit(new p(o.message,(i=o.response)===null||i===void 0?void 0:i.status,(t=o.response)===null||t===void 0?void 0:t.data));return[3,4];case 4:return[2]}}))}))};e.prototype.componentDidRender=function(){var e=this.headerTargetId?document.getElementById(this.headerTargetId):null;var i=document.getElementById("verdocs-view-header");if(e&&i){console.log("[VIEW] Moving header");i.remove();e.append(i)}};e.prototype.disconnectedCallback=function(){this.unlistenToEnvelope()};e.prototype.listenToEnvelope=function(){return __awaiter(this,void 0,void 0,(function(){var e=this;return __generator(this,(function(i){console.log("[SIDEBAR] Loading envelope",this.envelopeId);this.unlistenToEnvelope();v.subscribe("envelopes",this.envelopeId,(function(){return a(e.endpoint,e.envelopeId)}),false,(function(i){e.envelope=i;e.loading=false}));return[2]}))}))};e.prototype.unlistenToEnvelope=function(){if(this.envelopeListenerId){v.store.delListener(this.envelopeListenerId);this.envelopeListenerId=null}};e.prototype.handlePageRendered=function(e){};e.prototype.handleOptionSelected=function(e){return __awaiter(this,void 0,void 0,(function(){var i,t,n,o,s,r,s;var l=this;return __generator(this,(function(u){switch(u.label){case 0:n=e.detail.id;switch(n){case"cancel":return[3,1];case"print":return[3,2];case"download-attachments":return[3,3];case"download-certificate":return[3,6];case"download-all":return[3,9]}return[3,10];case 1:if(confirm("Are you sure you wish to cancel this envelope? This action cannot be undone.")){this.canceling=true;c(this.endpoint,this.envelopeId).then((function(e){l.canceling=false;console.log("[VIEW] Envelope canceled",e);return a(l.endpoint,l.envelopeId)})).then((function(e){console.log("[VIEW] Loaded new envelope details",e);l.envelope=e})).catch((function(e){var i,t,n;l.canceling=false;console.log("[VIEW] Error canceling envelope",e);(i=l.sdkError)===null||i===void 0?void 0:i.emit(new p(e.message,(t=e.response)===null||t===void 0?void 0:t.status,(n=e.response)===null||n===void 0?void 0:n.data))}));this.showCancelDone=true;(i=this.envelopeUpdated)===null||i===void 0?void 0:i.emit({endpoint:this.endpoint,envelope:this.envelope,event:"canceled"})}return[3,10];case 2:window.print();(t=this.envelopeUpdated)===null||t===void 0?void 0:t.emit({endpoint:this.endpoint,envelope:this.envelope,event:"printed"});return[3,10];case 3:o=this.envelope.documents.find((function(e){return e.type==="attachment"}));if(!o)return[3,5];return[4,d(this.endpoint,this.envelopeId,o.id)];case 4:s=u.sent();window.open(s,"_blank");u.label=5;case 5:return[3,10];case 6:r=this.envelope.documents.find((function(e){return e.type==="certificate"}));if(!r)return[3,8];return[4,d(this.endpoint,this.envelopeId,r.id)];case 7:s=u.sent();window.open(s,"_blank");u.label=8;case 8:return[3,10];case 9:h(this.endpoint,[this.envelope]).then((function(){var e;(e=l.envelopeUpdated)===null||e===void 0?void 0:e.emit({endpoint:l.endpoint,envelope:l.envelope,event:"downloaded"})})).catch((function(e){console.log("Error downloading Zip",e)}));return[3,10];case 10:return[2]}}))}))};e.prototype.render=function(){var e=this;var i;if(this.loading){return n(s,null,n("verdocs-loader",null))}if(this.showLoadError){return n(s,null,n("verdocs-ok-dialog",{heading:"Unable to View Envelope",message:"Sorry, that envelope is not valid.",buttonLabel:"OK",onNext:function(){e.showLoadError=false}}))}if(!this.envelope){return n(s,null,n("img",{src:"https://public-assets.verdocs.com/loading-placeholder.png",style:{width:"612px",height:"792px",boxShadow:"0 0 10px 5px #0000000f",marginTop:"15px"},alt:"Placeholder page"}))}var t=[{id:"print",label:"Print"}];if(u(this.endpoint.profile,this.envelope)){t.push({id:"cancel",label:"Cancel"})}var r=this.envelope.documents.length>0;var l=this.envelope.documents.filter((function(e){return e.type==="attachment"})).length;var a=this.envelope.documents.find((function(e){return e.type==="certificate"}))!==undefined;if(r||a){t.push({label:""});if(r){t.push({id:"download-attachments",label:l>1?"Download Documents":"Download Document"})}if(a){t.push({id:"download-certificate",label:"Download Certificate"})}if(r&&a){t.push({id:"download-all",label:"Download All Files"})}}return n(s,null,n("div",{id:"verdocs-view-header"},n("div",{class:"inner"},n("img",{src:"https://verdocs.com/assets/white-logo.svg",alt:"Verdocs Logo",class:"logo"}),n("div",{class:"title"},this.envelope.name),n("div",{style:{flex:"1"}}),n("div",{style:{marginLeft:"10px"}}),n("verdocs-dropdown",{options:t,onOptionSelected:function(i){return e.handleOptionSelected(i)}}))),n("div",{class:"document",style:{paddingTop:this.headerTargetId?"70px":"15px"}},(((i=this.envelope)===null||i===void 0?void 0:i.documents)||[]).filter((function(e){return e.type!=="certificate"})).map((function(i){var t=f(1,i.pages);return n(o,null,t.map((function(t){var o;var s=((o=i.page_sizes)===null||o===void 0?void 0:o[t])||{width:612,height:792};return n("verdocs-envelope-document-page",{envelopeId:e.envelopeId,documentId:i.id,endpoint:e.endpoint,type:"filled",virtualWidth:s.width,virtualHeight:s.height,pageNumber:t,onPageRendered:function(i){return e.handlePageRendered(i)},layers:[{name:"page",type:"canvas"},{name:"controls",type:"div"}]})})))}))),this.showCancelDone&&n("verdocs-ok-dialog",{heading:"Cancelled",message:"This envelope has been cancelled successfully.",onNext:function(){e.showCancelDone=false}}),this.canceling&&n("div",{class:"loading-indicator"},n("verdocs-loader",null)))};Object.defineProperty(e.prototype,"component",{get:function(){return r(this)},enumerable:false,configurable:true});return e}());y.style=k}}}));
|
1
|
+
var __assign=this&&this.__assign||function(){__assign=Object.assign||function(e){for(var i,t=1,n=arguments.length;t<n;t++){i=arguments[t];for(var o in i)if(Object.prototype.hasOwnProperty.call(i,o))e[o]=i[o]}return e};return __assign.apply(this,arguments)};var __awaiter=this&&this.__awaiter||function(e,i,t,n){function o(e){return e instanceof t?e:new t((function(i){i(e)}))}return new(t||(t=Promise))((function(t,s){function r(e){try{a(n.next(e))}catch(e){s(e)}}function l(e){try{a(n["throw"](e))}catch(e){s(e)}}function a(e){e.done?t(e.value):o(e.value).then(r,l)}a((n=n.apply(e,i||[])).next())}))};var __generator=this&&this.__generator||function(e,i){var t={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},n,o,s,r;return r={next:l(0),throw:l(1),return:l(2)},typeof Symbol==="function"&&(r[Symbol.iterator]=function(){return this}),r;function l(e){return function(i){return a([e,i])}}function a(l){if(n)throw new TypeError("Generator is already executing.");while(r&&(r=0,l[0]&&(t=0)),t)try{if(n=1,o&&(s=l[0]&2?o["return"]:l[0]?o["throw"]||((s=o["return"])&&s.call(o),0):o.next)&&!(s=s.call(o,l[1])).done)return s;if(o=0,s)l=[l[0]&2,s.value];switch(l[0]){case 0:case 1:s=l;break;case 4:t.label++;return{value:l[1],done:false};case 5:t.label++;o=l[1];l=[0];continue;case 7:l=t.ops.pop();t.trys.pop();continue;default:if(!(s=t.trys,s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){t=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){t.label=l[1];break}if(l[0]===6&&t.label<s[1]){t.label=s[1];s=l;break}if(s&&t.label<s[2]){t.label=s[2];t.ops.push(l);break}if(s[2])t.ops.pop();t.trys.pop();continue}l=i.call(e,t)}catch(e){l=[6,e];o=0}finally{n=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:true}}};System.register(["./p-9186f42e.system.js","@verdocs/js-sdk","./p-f29eb00a.system.js","./p-c8a15cb7.system.js","./p-35dcb386.system.js","./p-21b1acec.system.js","./p-d738b5db.system.js","./p-2c5350ec.system.js"],(function(e){"use strict";var i,t,n,o,s,r,l,a,d,c,u,f,h,p,v;return{setters:[function(e){i=e.r;t=e.c;n=e.h;o=e.F;s=e.H;r=e.g},function(e){l=e.VerdocsEndpoint;a=e.getEnvelope;d=e.getDocumentDownloadLink;c=e.cancelEnvelope;u=e.userCanCancelEnvelope;f=e.integerSequence},function(e){h=e.s},function(e){p=e.S},function(e){v=e.S},function(){},function(){},function(){}],execute:function(){var x='@-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-kba-dialog{font-family:"Inter", "Barlow", sans-serif;-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-kba-dialog div{-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-kba-dialog .background-overlay{position:fixed;z-index:10000;top:0;left:0;right:0;bottom:0;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;background:rgba(0, 0, 0, 0.4980392157)}verdocs-kba-dialog .dialog{width:440px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;border-radius:4px;overflow:hidden;background:#fff;padding:16px;gap:14px;-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-kba-dialog .heading{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;font-size:20px;font-weight:500}verdocs-kba-dialog .step{margin-left:6px;color:#666}verdocs-kba-dialog .help-box{background-color:#707ae5;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;padding:14px;-ms-flex-align:center;align-items:center;color:white}verdocs-kba-dialog .help-details{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;margin-left:15px;font-size:14px}verdocs-kba-dialog .help-icon{width:40px;height:40px}verdocs-kba-dialog .help-title{font-weight:600;margin-bottom:4px}verdocs-kba-dialog .help-text{font-weight:400}verdocs-kba-dialog .input{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;gap:10px;-ms-flex-align:center;align-items:center;margin:16px 0 32px}verdocs-kba-dialog .input label{-ms-flex:0;flex:0;line-height:10px;font-weight:500;white-space:nowrap}verdocs-kba-dialog .input input{-ms-flex:1;flex:1;padding:2px 8px;border-radius:3px;border:1px solid #cccccc}verdocs-kba-dialog .field{gap:10px;margin:0;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;max-width:100%}verdocs-kba-dialog .field .required{color:red;position:relative;top:-0.5em;font-size:80%}verdocs-kba-dialog .field label{-ms-flex:0 0 100px;flex:0 0 100px;font-weight:500;line-height:10px;text-align:right;white-space:nowrap}verdocs-kba-dialog .field input{width:40%;-ms-flex-positive:1;flex-grow:1;padding:2px 8px;border-radius:3px;border:1px solid #cccccc}verdocs-kba-dialog .choices{display:grid;gap:15px;grid-template-columns:repeat(auto-fill, minmax(100px, 1fr));margin:0 0 15px 0}verdocs-kba-dialog .choice{border:1px solid #707ae5;border-radius:5px;display:-ms-flexbox;display:flex;height:60px;font-size:14px;padding:0 5px;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;text-align:center;color:#5c6575;cursor:pointer}verdocs-kba-dialog .choice.selected{background-color:#707ae5;color:#ffffff}verdocs-kba-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-kba-dialog .buttons verdocs-button{margin-left:16px}';var b=x;var g='<svg width="40" height="40" viewBox="0 0 40 40" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M20 0C8.95313 0 0 8.95313 0 20C0 31.0469 8.95313 40 20 40C31.0469 40 40 31.0469 40 20C40 8.95313 31.0469 0 20 0ZM20 36.25C11.0391 36.25 3.75 28.9602 3.75 20C3.75 11.0398 11.0391 3.75 20 3.75C28.9609 3.75 36.25 11.0398 36.25 20C36.25 28.9602 28.9609 36.25 20 36.25Z" fill="white"/><path d="M20 26.25C18.5938 26.25 17.5 27.3438 17.5 28.75C17.5 30.1562 18.5234 31.25 20 31.25C21.3359 31.25 22.5 30.1562 22.5 28.75C22.5 27.3438 21.3359 26.25 20 26.25ZM22.5859 10H18.5938C15.5469 10 13.125 12.4219 13.125 15.4688C13.125 16.4844 13.9844 17.3438 15 17.3438C16.0156 17.3438 16.875 16.4844 16.875 15.4688C16.875 14.5312 17.5859 13.75 18.5234 13.75H22.5156C23.5234 13.75 24.375 14.5312 24.375 15.4688C24.375 16.0938 24.0625 16.5703 23.5156 16.8828L19.0625 19.6094C18.4375 20 18.125 20.625 18.125 21.25V22.5C18.125 23.5156 18.9844 24.375 20 24.375C21.0156 24.375 21.875 23.5156 21.875 22.5V22.3438L25.3984 20.1562C27.0391 19.1406 28.0547 17.3438 28.0547 15.4688C28.125 12.4219 25.7031 10 22.5859 10Z" fill="#E7E7E7"/></svg>';var m=e("verdocs_kba_dialog",function(){function e(e){i(this,e);this.exit=t(this,"exit",7);this.pinEntered=t(this,"pinEntered",7);this.next=t(this,"next",7);this.step=1;this.steps=3;this.helptitle="Previous Addresses";this.helptext="Please select the address below that you have most recently lived at.";this.mode="choice";this.label="PIN";this.placeholder="Enter your PIN...";this.recipient=null;this.choices=["553 Arbor Dr","18 Lacey Ln","23A Ball Ct","2375 Cavallo Blvd","23-1 RR-7","151 Boulder Rd"];this.response="";this.updatedRecipient=null}e.prototype.componentDidLoad=function(){this.updatedRecipient=__assign({},this.recipient||{})};e.prototype.handleCancel=function(){this.exit.emit()};e.prototype.handleDismiss=function(e){if(e.target.class==="background-overlay"){e.preventDefault();this.handleCancel()}};e.prototype.handleDone=function(){this.next.emit(this.response);this.response=""};e.prototype.handleConfirmID=function(){this.next.emit(this.updatedRecipient)};e.prototype.render=function(){var e=this;var i,t,r,l,a,d,c,u,f,h,p;if(this.mode==="choice"){return n(s,null,n("div",{class:"background-overlay",onClick:function(i){return e.handleDismiss(i)}},n("div",{class:"dialog"},n("div",{class:"heading"},"Confirm Your Identity",this.steps>1?n("span",{class:"step"},"(",this.step,"/",this.steps,")"):n(o,null)),!!this.helptitle&&n("div",{class:"help-box"},n("div",{class:"help-icon",innerHTML:g}),n("div",{class:"help-details"},n("div",{class:"help-title"},this.helptitle),n("div",{class:"help-text"},this.helptext))),n("div",{class:"choices"},this.choices.map((function(i){return n("div",{class:"choice ".concat(i===e.response?"selected":""),onClick:function(){console.log("Selected",i);e.response=i}},i)}))),n("div",{class:"buttons"},n("verdocs-button",{label:"Cancel",variant:"outline",onClick:function(){return e.handleCancel()}}),n("verdocs-button",{label:this.step<this.steps?"Next":"Submit",onClick:function(){return e.handleDone()},disabled:!this.response})))))}if(this.mode==="identity"){return n(s,null,n("div",{class:"background-overlay",onClick:function(i){return e.handleDismiss(i)}},n("div",{class:"dialog"},n("div",{class:"heading"},"Confirm Your Identity"),!!this.helptitle&&n("div",{class:"help-box"},n("div",{class:"help-icon",innerHTML:g}),n("div",{class:"help-details"},n("div",{class:"help-title"},"Identity verification is required"),n("div",{class:"help-text"},"NOTE: Only four fields are required, but providing more details will allow us to complete the verification process more quickly."))),n("div",{class:"field"},n("label",{htmlFor:"verdocs-kba-first"},"Your Name:",n("span",{class:"required"},"*")),n("input",{required:true,type:"text",id:"verdocs-kba-first",name:"verdocs-kba-first",placeholder:"First name...",value:(i=this.updatedRecipient)===null||i===void 0?void 0:i.first_name,onInput:function(i){return e.updatedRecipient=__assign(__assign({},e.updatedRecipient),{first_name:i.target.value})}}),n("input",{type:"text",id:"verdocs-kba-last",name:"verdocs-kba-last",placeholder:"Last name...",required:true,value:(t=this.updatedRecipient)===null||t===void 0?void 0:t.last_name,onInput:function(i){return e.updatedRecipient=__assign(__assign({},e.updatedRecipient),{last_name:i.target.value})}})),n("div",{class:"field"},n("label",{htmlFor:"verdocs-kba-address"},"Address:",n("span",{class:"required"},"*")),n("input",{type:"text",id:"verdocs-kba-address",name:"verdocs-kba-address",placeholder:"Address...",value:(r=this.updatedRecipient)===null||r===void 0?void 0:r.address,onInput:function(i){return e.updatedRecipient=__assign(__assign({},e.updatedRecipient),{address:i.target.value})}})),n("div",{class:"field"},n("label",{htmlFor:"verdocs-kba-city"},"City:"),n("input",{type:"text",id:"verdocs-kba-city",name:"verdocs-kba-city",placeholder:"City...",value:(l=this.updatedRecipient)===null||l===void 0?void 0:l.city,onInput:function(i){return e.updatedRecipient=__assign(__assign({},e.updatedRecipient),{city:i.target.value})}})),n("div",{class:"field"},n("label",{htmlFor:"verdocs-kba-state"},"State:"),n("input",{type:"text",id:"verdocs-kba-state",name:"verdocs-kba-state",placeholder:"State...",value:(a=this.updatedRecipient)===null||a===void 0?void 0:a.state,onInput:function(i){return e.updatedRecipient=__assign(__assign({},e.updatedRecipient),{state:i.target.value})}})),n("div",{class:"field"},n("label",{htmlFor:"verdocs-kba-zip"},"Zip Code:",n("span",{class:"required"},"*")),n("input",{type:"text",id:"verdocs-kba-zip",name:"verdocs-kba-zip",placeholder:"Zip Code...",required:true,value:(d=this.updatedRecipient)===null||d===void 0?void 0:d.zip,onInput:function(i){return e.updatedRecipient=__assign(__assign({},e.updatedRecipient),{zip:i.target.value})}})),n("div",{class:"field"},n("label",{htmlFor:"verdocs-kba-address"},"SSN Last 4:"),n("input",{type:"text",id:"verdocs-kba-state",name:"verdocs-kba-state",placeholder:"Last 4 digits of your SSN...",value:(c=this.updatedRecipient)===null||c===void 0?void 0:c.ssn_last_4,onInput:function(i){return e.updatedRecipient=__assign(__assign({},e.updatedRecipient),{ssn_last_4:i.target.value})}})),n("div",{class:"buttons"},n("verdocs-button",{label:"Submit",onClick:function(){return e.handleConfirmID()},disabled:!((u=this.updatedRecipient)===null||u===void 0?void 0:u.first_name)||!((f=this.updatedRecipient)===null||f===void 0?void 0:f.last_name)||!((h=this.updatedRecipient)===null||h===void 0?void 0:h.address)||!((p=this.updatedRecipient)===null||p===void 0?void 0:p.zip)})))))}return n(s,null,n("div",{class:"background-overlay",onClick:function(i){return e.handleDismiss(i)}},n("div",{class:"dialog"},n("div",{class:"heading"},"Please Confirm Your Identity",this.steps>1?n("span",{class:"step"},"(",this.step,"/",this.steps,")"):n(o,null)),!!this.helptitle&&n("div",{class:"help-box"},n("div",{class:"help-icon",innerHTML:g}),n("div",{class:"help-details"},n("div",{class:"help-title"},this.helptitle),n("div",{class:"help-text"},this.helptext))),n("div",{class:"input"},n("label",{htmlFor:"verdocs-kba-input"},this.label),n("input",{type:"text",id:"verdocs-kba-input",name:"verdocs-kba-input",placeholder:this.placeholder,value:this.response,onInput:function(i){return e.response=i.target.value}})),n("div",{class:"buttons"},n("verdocs-button",{label:"Cancel",variant:"outline",onClick:function(){return e.handleCancel()}}),n("verdocs-button",{label:"Submit",onClick:function(){return e.handleDone()},disabled:!this.response})))))};return e}());m.style=b;var w='@-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-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)}@media all and (max-width: 500px){#verdocs-view-header{padding:0 10px}}#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}@media all and (max-width: 500px){#verdocs-view-header .inner{padding:0 10px}}#verdocs-view-header .logo{width:80px;display:none;margin:-6px 0 0 0}#verdocs-view-header .title{font-size:18px;font-weight:500;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}';var k=w;var y=e("verdocs_view",function(){function e(e){i(this,e);this.sdkError=t(this,"sdkError",7);this.envelopeUpdated=t(this,"envelopeUpdated",7);this.another=t(this,"another",7);this.view=t(this,"view",7);this.next=t(this,"next",7);this.envelopeListenerId=null;this.endpoint=null;this.envelopeId="";this.headerTargetId=null;this.canceling=false;this.showCancelDone=false;this.showLoadError=false;this.loading=true;this.envelope=null}e.prototype.componentWillLoad=function(){return __awaiter(this,void 0,void 0,(function(){var e,i,t,n,o;return __generator(this,(function(s){switch(s.label){case 0:if(!this.endpoint){this.endpoint=l.getDefault();this.endpoint.loadSession()}if(!this.envelopeId){console.error("[VIEW] Missing required envelopeId");return[2]}this.listenToEnvelope();if(!!this.envelope)return[3,4];s.label=1;case 1:s.trys.push([1,3,,4]);console.log("[VIEW] Loading envelope...");n=this;return[4,a(this.endpoint,this.envelopeId)];case 2:n.envelope=s.sent();console.log("[VIEW] Loaded envelope",this.envelope);return[3,4];case 3:o=s.sent();this.showLoadError=true;(e=this.sdkError)===null||e===void 0?void 0:e.emit(new p(o.message,(i=o.response)===null||i===void 0?void 0:i.status,(t=o.response)===null||t===void 0?void 0:t.data));return[3,4];case 4:return[2]}}))}))};e.prototype.componentDidRender=function(){var e=this.headerTargetId?document.getElementById(this.headerTargetId):null;var i=document.getElementById("verdocs-view-header");if(e&&i){console.log("[VIEW] Moving header");i.remove();e.append(i)}};e.prototype.disconnectedCallback=function(){this.unlistenToEnvelope()};e.prototype.listenToEnvelope=function(){return __awaiter(this,void 0,void 0,(function(){var e=this;return __generator(this,(function(i){console.log("[SIDEBAR] Loading envelope",this.envelopeId);this.unlistenToEnvelope();v.subscribe("envelopes",this.envelopeId,(function(){return a(e.endpoint,e.envelopeId)}),false,(function(i){e.envelope=i;e.loading=false}));return[2]}))}))};e.prototype.unlistenToEnvelope=function(){if(this.envelopeListenerId){v.store.delListener(this.envelopeListenerId);this.envelopeListenerId=null}};e.prototype.handlePageRendered=function(e){};e.prototype.handleOptionSelected=function(e){return __awaiter(this,void 0,void 0,(function(){var i,t,n,o,s,r,s;var l=this;return __generator(this,(function(u){switch(u.label){case 0:n=e.detail.id;switch(n){case"cancel":return[3,1];case"print":return[3,2];case"download-attachments":return[3,3];case"download-certificate":return[3,6];case"download-all":return[3,9]}return[3,10];case 1:if(confirm("Are you sure you wish to cancel this envelope? This action cannot be undone.")){this.canceling=true;c(this.endpoint,this.envelopeId).then((function(e){l.canceling=false;console.log("[VIEW] Envelope canceled",e);return a(l.endpoint,l.envelopeId)})).then((function(e){console.log("[VIEW] Loaded new envelope details",e);l.envelope=e})).catch((function(e){var i,t,n;l.canceling=false;console.log("[VIEW] Error canceling envelope",e);(i=l.sdkError)===null||i===void 0?void 0:i.emit(new p(e.message,(t=e.response)===null||t===void 0?void 0:t.status,(n=e.response)===null||n===void 0?void 0:n.data))}));this.showCancelDone=true;(i=this.envelopeUpdated)===null||i===void 0?void 0:i.emit({endpoint:this.endpoint,envelope:this.envelope,event:"canceled"})}return[3,10];case 2:window.print();(t=this.envelopeUpdated)===null||t===void 0?void 0:t.emit({endpoint:this.endpoint,envelope:this.envelope,event:"printed"});return[3,10];case 3:o=this.envelope.documents.find((function(e){return e.type==="attachment"}));if(!o)return[3,5];return[4,d(this.endpoint,this.envelopeId,o.id)];case 4:s=u.sent();window.open(s,"_blank");u.label=5;case 5:return[3,10];case 6:r=this.envelope.documents.find((function(e){return e.type==="certificate"}));if(!r)return[3,8];return[4,d(this.endpoint,this.envelopeId,r.id)];case 7:s=u.sent();window.open(s,"_blank");u.label=8;case 8:return[3,10];case 9:h(this.endpoint,[this.envelope]).then((function(){var e;(e=l.envelopeUpdated)===null||e===void 0?void 0:e.emit({endpoint:l.endpoint,envelope:l.envelope,event:"downloaded"})})).catch((function(e){console.log("Error downloading Zip",e)}));return[3,10];case 10:return[2]}}))}))};e.prototype.render=function(){var e=this;var i;if(this.loading){return n(s,null,n("verdocs-loader",null))}if(this.showLoadError){return n(s,null,n("verdocs-ok-dialog",{heading:"Unable to View Envelope",message:"Sorry, that envelope is not valid.",buttonLabel:"OK",onNext:function(){e.showLoadError=false}}))}if(!this.envelope){return n(s,null,n("img",{src:"https://public-assets.verdocs.com/loading-placeholder.png",style:{width:"612px",height:"792px",boxShadow:"0 0 10px 5px #0000000f",marginTop:"15px"},alt:"Placeholder page"}))}var t=[{id:"print",label:"Print"}];if(u(this.endpoint.profile,this.envelope)){t.push({id:"cancel",label:"Cancel"})}var r=this.envelope.documents.length>0;var l=this.envelope.documents.filter((function(e){return e.type==="attachment"})).length;var a=this.envelope.documents.find((function(e){return e.type==="certificate"}))!==undefined;if(r||a){t.push({label:""});if(r){t.push({id:"download-attachments",label:l>1?"Download Documents":"Download Document"})}if(a){t.push({id:"download-certificate",label:"Download Certificate"})}if(r&&a){t.push({id:"download-all",label:"Download All Files"})}}return n(s,null,n("div",{id:"verdocs-view-header"},n("div",{class:"inner"},n("img",{src:"https://verdocs.com/assets/white-logo.svg",alt:"Verdocs Logo",class:"logo"}),n("div",{class:"title"},this.envelope.name),n("div",{style:{flex:"1"}}),n("div",{style:{marginLeft:"10px"}}),n("verdocs-dropdown",{options:t,onOptionSelected:function(i){return e.handleOptionSelected(i)}}))),n("div",{class:"document",style:{paddingTop:this.headerTargetId?"70px":"15px"}},(((i=this.envelope)===null||i===void 0?void 0:i.documents)||[]).filter((function(e){return e.type!=="certificate"})).map((function(i){var t=f(1,i.pages);return n(o,null,t.map((function(t){var o;var s=((o=i.page_sizes)===null||o===void 0?void 0:o[t])||{width:612,height:792};return n("verdocs-envelope-document-page",{envelopeId:e.envelopeId,documentId:i.id,endpoint:e.endpoint,type:"filled",virtualWidth:s.width,virtualHeight:s.height,pageNumber:t,onPageRendered:function(i){return e.handlePageRendered(i)},layers:[{name:"page",type:"canvas"},{name:"controls",type:"div"}]})})))}))),this.showCancelDone&&n("verdocs-ok-dialog",{heading:"Cancelled",message:"This envelope has been cancelled successfully.",onNext:function(){e.showCancelDone=false}}),this.canceling&&n("div",{class:"loading-indicator"},n("verdocs-loader",null)))};Object.defineProperty(e.prototype,"component",{get:function(){return r(this)},enumerable:false,configurable:true});return e}());y.style=k}}}));
|