@verdocs/web-sdk 4.2.135 → 4.2.136

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (93) hide show
  1. package/dist/cjs/{TemplateStore-d11d62c0.js → TemplateStore-c0062987.js} +1 -1
  2. package/dist/cjs/index-a27a7f77.js +6 -2
  3. package/dist/cjs/loader.cjs.js +1 -1
  4. package/dist/cjs/verdocs-build.cjs.entry.js +1 -1
  5. package/dist/cjs/verdocs-checkbox_4.cjs.entry.js +1 -1
  6. package/dist/cjs/verdocs-preview_9.cjs.entry.js +7 -11
  7. package/dist/cjs/verdocs-radio-button.cjs.entry.js +24 -0
  8. package/dist/cjs/verdocs-template-role-properties.cjs.entry.js +161 -0
  9. package/dist/cjs/verdocs-template-star.cjs.entry.js +1 -1
  10. package/dist/cjs/verdocs-template-tags.cjs.entry.js +1 -1
  11. package/dist/cjs/verdocs-templates-list.cjs.entry.js +15 -15
  12. package/dist/cjs/verdocs-web-sdk.cjs.js +1 -1
  13. package/dist/collection/collection-manifest.json +0 -1
  14. package/dist/collection/components/templates/verdocs-template-role-properties/verdocs-template-role-properties.js +8 -33
  15. package/dist/collection/components/templates/verdocs-template-roles/verdocs-template-roles.css +1 -1
  16. package/dist/collection/components/templates/verdocs-template-roles/verdocs-template-roles.js +6 -11
  17. package/dist/collection/components/templates/verdocs-template-star/verdocs-template-star.js +1 -1
  18. package/dist/collection/components/templates/verdocs-template-tags/verdocs-template-tags.js +1 -1
  19. package/dist/collection/components/templates/verdocs-templates-list/verdocs-templates-list.js +23 -23
  20. package/dist/collection/utils/TemplateStore.js +1 -1
  21. package/dist/components/TemplateStore.js +1 -1
  22. package/dist/components/index.js +0 -2
  23. package/dist/components/verdocs-build.js +74 -86
  24. package/dist/components/verdocs-radio-button.js +37 -1
  25. package/dist/components/verdocs-template-role-properties2.js +8 -10
  26. package/dist/components/verdocs-template-roles2.js +21 -38
  27. package/dist/components/verdocs-template-star2.js +1 -1
  28. package/dist/components/verdocs-template-tags.js +1 -1
  29. package/dist/components/verdocs-templates-list.js +16 -16
  30. package/dist/esm/{TemplateStore-41799d0a.js → TemplateStore-8151aa18.js} +1 -1
  31. package/dist/esm/index-a68c7262.js +6 -2
  32. package/dist/esm/loader.js +1 -1
  33. package/dist/esm/verdocs-build.entry.js +1 -1
  34. package/dist/esm/verdocs-checkbox_4.entry.js +1 -1
  35. package/dist/esm/verdocs-preview_9.entry.js +8 -12
  36. package/dist/{components/verdocs-radio-button2.js → esm/verdocs-radio-button.entry.js} +7 -26
  37. package/dist/esm/verdocs-template-role-properties.entry.js +157 -0
  38. package/dist/esm/verdocs-template-star.entry.js +1 -1
  39. package/dist/esm/verdocs-template-tags.entry.js +1 -1
  40. package/dist/esm/verdocs-templates-list.entry.js +15 -15
  41. package/dist/esm/verdocs-web-sdk.js +1 -1
  42. package/dist/esm-es5/{TemplateStore-41799d0a.js → TemplateStore-8151aa18.js} +1 -1
  43. package/dist/esm-es5/index-a68c7262.js +1 -1
  44. package/dist/esm-es5/loader.js +1 -1
  45. package/dist/esm-es5/verdocs-build.entry.js +1 -1
  46. package/dist/esm-es5/verdocs-checkbox_4.entry.js +1 -1
  47. package/dist/esm-es5/verdocs-preview_9.entry.js +1 -1
  48. package/dist/esm-es5/verdocs-radio-button.entry.js +1 -0
  49. package/dist/esm-es5/verdocs-template-role-properties.entry.js +1 -0
  50. package/dist/esm-es5/verdocs-template-star.entry.js +1 -1
  51. package/dist/esm-es5/verdocs-template-tags.entry.js +1 -1
  52. package/dist/esm-es5/verdocs-templates-list.entry.js +1 -1
  53. package/dist/esm-es5/verdocs-web-sdk.js +1 -1
  54. package/dist/types/components/templates/verdocs-template-role-properties/verdocs-template-role-properties.d.ts +1 -5
  55. package/dist/types/components/templates/verdocs-template-roles/verdocs-template-roles.d.ts +0 -1
  56. package/dist/types/components/templates/verdocs-templates-list/verdocs-templates-list.d.ts +2 -2
  57. package/dist/types/components.d.ts +14 -95
  58. package/dist/verdocs-web-sdk/p-0165edae.entry.js +1 -0
  59. package/dist/verdocs-web-sdk/p-0729a901.entry.js +1 -0
  60. package/dist/verdocs-web-sdk/{p-5f61d897.entry.js → p-221c1a1e.entry.js} +1 -1
  61. package/dist/verdocs-web-sdk/p-267df026.system.js +1 -1
  62. package/dist/verdocs-web-sdk/{p-766e30ab.entry.js → p-26bd87bf.entry.js} +1 -1
  63. package/dist/verdocs-web-sdk/p-2844d252.system.entry.js +1 -0
  64. package/dist/verdocs-web-sdk/p-2cc40a28.system.entry.js +1 -0
  65. package/dist/verdocs-web-sdk/{p-4c514f4f.entry.js → p-42f9eaf8.entry.js} +1 -1
  66. package/dist/verdocs-web-sdk/{p-54526558.system.entry.js → p-48227855.system.entry.js} +1 -1
  67. package/dist/verdocs-web-sdk/p-50271eca.entry.js +1 -0
  68. package/dist/verdocs-web-sdk/p-7ed61c7c.js +1 -0
  69. package/dist/verdocs-web-sdk/{p-f52adfeb.system.entry.js → p-80ddfda6.system.entry.js} +1 -1
  70. package/dist/verdocs-web-sdk/{p-77f25be6.system.entry.js → p-82ba6cba.system.entry.js} +1 -1
  71. package/dist/verdocs-web-sdk/{p-d7f0bb8b.system.entry.js → p-8a7b7815.system.entry.js} +1 -1
  72. package/dist/verdocs-web-sdk/{p-c32f6de0.entry.js → p-8e67affa.entry.js} +1 -1
  73. package/dist/verdocs-web-sdk/{p-1dacf5e4.system.entry.js → p-9931d962.system.entry.js} +1 -1
  74. package/dist/verdocs-web-sdk/{p-1a663adf.system.js → p-a9e0ae2c.system.js} +1 -1
  75. package/dist/verdocs-web-sdk/p-ac677e8c.system.entry.js +1 -0
  76. package/dist/verdocs-web-sdk/p-f83e87d4.entry.js +1 -0
  77. package/dist/verdocs-web-sdk/verdocs-web-sdk.esm.js +1 -1
  78. package/package.json +2 -2
  79. package/dist/cjs/verdocs-radio-button_3.cjs.entry.js +0 -248
  80. package/dist/collection/components/templates/verdocs-template-sender/verdocs-template-sender.css +0 -72
  81. package/dist/collection/components/templates/verdocs-template-sender/verdocs-template-sender.js +0 -189
  82. package/dist/components/verdocs-template-sender.d.ts +0 -11
  83. package/dist/components/verdocs-template-sender.js +0 -6
  84. package/dist/components/verdocs-template-sender2.js +0 -110
  85. package/dist/esm/verdocs-radio-button_3.entry.js +0 -242
  86. package/dist/esm-es5/verdocs-radio-button_3.entry.js +0 -1
  87. package/dist/types/components/templates/verdocs-template-sender/verdocs-template-sender.d.ts +0 -37
  88. package/dist/verdocs-web-sdk/p-1b0294d4.js +0 -1
  89. package/dist/verdocs-web-sdk/p-423a4d58.entry.js +0 -1
  90. package/dist/verdocs-web-sdk/p-47dff85a.system.entry.js +0 -1
  91. package/dist/verdocs-web-sdk/p-5d2c7c6c.entry.js +0 -1
  92. package/dist/verdocs-web-sdk/p-77407be2.entry.js +0 -1
  93. package/dist/verdocs-web-sdk/p-808f956b.system.entry.js +0 -1
@@ -1 +1 @@
1
- import{r as e,c as t,h as s,H as i,g as o}from"./p-5207d80c.js";import{VerdocsEndpoint as l}from"@verdocs/js-sdk";import{g as d}from"./p-1b0294d4.js";import{S as a}from"./p-fd97809c.js";import"./p-83317d11.js";import"./p-9e371467.js";import"./p-784ac100.js";import"./p-a706bac9.js";const r=class{constructor(s){e(this,s),this.sdkError=t(this,"sdkError",7),this.stepChanged=t(this,"stepChanged",7),this.send=t(this,"send",7),this.templateUpdated=t(this,"templateUpdated",7),this.templateCreated=t(this,"templateCreated",7),this.rolesUpdated=t(this,"rolesUpdated",7),this.endpoint=l.getDefault(),this.templateId=null,this.step="preview",this.templateStore=null}onTemplateIdChanged(e,t){!t&&e&&"attachments"===this.step&&(this.step="preview"),this.loadTemplate(e).catch((e=>console.log("Unknown Error",e)))}onStepChanged(){this.loadTemplate(this.templateId).catch((e=>console.log("Unknown Error",e)))}async componentWillLoad(){var e,t,s,i,o,l;try{if(this.endpoint.loadSession(),!this.endpoint.session)return void console.log("[BUILD] Unable to start builder session, must be authenticated");if(!this.templateId)return console.log("[BUILD] No template ID, activating upload mode"),void(this.step="attachments");try{this.loadTemplate(this.templateId).catch((e=>console.log("[BUILD] Unable to load template",e)))}catch(i){console.log("[BUILD] Error loading template",i),null===(e=this.sdkError)||void 0===e||e.emit(new a(i.message,null===(t=i.response)||void 0===t?void 0:t.status,null===(s=i.response)||void 0===s?void 0:s.data))}}catch(e){console.log("[BUILD] Error with builder session",e),null===(i=this.sdkError)||void 0===i||i.emit(new a(e.message,null===(o=e.response)||void 0===o?void 0:o.status,null===(l=e.response)||void 0===l?void 0:l.data))}}async loadTemplate(e){e&&(this.templateStore=await d(this.endpoint,e,!1))}handleCancel(){this.step="preview"}async handleTemplateCreated(e){var t;await this.loadTemplate(e),this.templateId=e,this.step="roles",null===(t=this.stepChanged)||void 0===t||t.emit("roles")}async handleRolesUpdated(e){var t;null===(t=this.templateUpdated)||void 0===t||t.emit(e.detail)}async handleTemplateUpdated(e){var t;null===(t=this.templateUpdated)||void 0===t||t.emit(e.detail)}handleAttachmentsNext(){var e;this.step="roles",null===(e=this.stepChanged)||void 0===e||e.emit("roles")}handleRolesNext(){var e;this.step="fields",null===(e=this.stepChanged)||void 0===e||e.emit("fields")}handleStepChanged(e){var t;this.step=e,null===(t=this.stepChanged)||void 0===t||t.emit(e)}render(){return this.endpoint.session?this.templateStore?(console.log("[BUILD] Rendering build view",this.templateId,this.step,["attachments","roles","settings","fields","preview"].indexOf(this.step)),s(i,null,s("div",{class:"content"},s("verdocs-template-build-tabs",{endpoint:this.endpoint,templateId:this.templateId,step:this.step,onSdkError:e=>{var t;return null===(t=this.sdkError)||void 0===t?void 0:t.emit(e.detail)},onStepChanged:e=>this.handleStepChanged(e.detail)}),"attachments"===this.step&&s("verdocs-template-attachments",{templateId:this.templateId,endpoint:this.endpoint,onExit:()=>this.handleCancel(),onNext:()=>this.handleAttachmentsNext(),onTemplateUpdated:e=>this.handleTemplateUpdated(e)}),"roles"===this.step&&s("verdocs-template-roles",{templateId:this.templateId,endpoint:this.endpoint,onExit:()=>this.handleCancel(),onNext:()=>this.handleRolesNext(),onRolesUpdated:e=>this.handleRolesUpdated(e)}),"settings"===this.step&&s("div",{style:{flexDirection:"column",gap:"20px",display:"flex",maxWidth:"400px",margin:"20px"}},s("verdocs-template-name",{templateId:this.templateId,endpoint:this.endpoint,style:{backgroundColor:"#ffffff",padding:"20px"},onTemplateUpdated:e=>this.handleTemplateUpdated(e)}),s("verdocs-template-reminders",{templateId:this.templateId,endpoint:this.endpoint,style:{backgroundColor:"#ffffff",padding:"20px"},onTemplateUpdated:e=>this.handleTemplateUpdated(e)}),s("verdocs-template-visibility",{templateId:this.templateId,endpoint:this.endpoint,style:{backgroundColor:"#ffffff",padding:"20px"},onTemplateUpdated:e=>this.handleTemplateUpdated(e)})),"fields"===this.step&&s("verdocs-template-fields",{templateId:this.templateId,endpoint:this.endpoint,onTemplateUpdated:e=>this.handleTemplateUpdated(e)}),"preview"===this.step&&s("div",{class:"preview-container"},s("div",{class:"preview-send-wrapper"},s("verdocs-send",{templateId:this.templateId,endpoint:this.endpoint,onSend:e=>{var t;return null===(t=this.send)||void 0===t?void 0:t.emit(e.detail)},style:{width:"100%"}})),s("div",{class:"preview-preview-wrapper"},s("verdocs-preview",{templateId:this.templateId,endpoint:this.endpoint,style:{display:"flex",flex:"1",maxWidth:"1000px"}})))))):(console.log("[BUILD] No template ID, rendering created view"),s(i,null,s("div",{class:"content"},s("verdocs-template-build-tabs",{endpoint:this.endpoint,templateId:this.templateId,step:"attachments",onSdkError:e=>{var t;return null===(t=this.sdkError)||void 0===t?void 0:t.emit(e.detail)},onStepChanged:e=>this.handleStepChanged(e.detail)}),s("verdocs-template-create",{endpoint:this.endpoint,onExit:()=>this.handleCancel(),onNext:()=>this.handleAttachmentsNext(),onTemplateCreated:e=>this.handleTemplateCreated(e.detail.templateId)})))):s(i,null,s("verdocs-component-error",{message:"You must be authenticated to use this module."}))}get el(){return o(this)}static get watchers(){return{templateId:["onTemplateIdChanged"],step:["onStepChanged"]}}};r.style='@-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-build{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif}verdocs-build .content{-ms-flex:1;flex:1;gap:20px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column}verdocs-build verdocs-template-attachments,verdocs-build verdocs-template-roles{margin:20px}verdocs-build verdocs-template-fields{border-top:1px solid #777777}verdocs-build verdocs-template-attachments{padding:20px;background:#ffffff}verdocs-build verdocs-template-fields{width:100%}verdocs-build verdocs-preview{-ms-flex:1;flex:1}verdocs-build .preview-container{-ms-flex-direction:row;flex-direction:row;display:-ms-flexbox;display:flex;width:100%;background-color:#eeeeee;max-height:100%}@media all and (max-width: 450px){verdocs-build .preview-container{-ms-flex-direction:column;flex-direction:column}}verdocs-build .preview-send-wrapper{display:-ms-flexbox;display:flex;-ms-flex:0 0 300px;flex:0 0 300px;background-color:#ffffff;-webkit-box-shadow:1px 1px 6px -2px rgba(0, 0, 0, 0.4980392157);box-shadow:1px 1px 6px -2px rgba(0, 0, 0, 0.4980392157)}@media all and (max-width: 450px){verdocs-build .preview-send-wrapper{-ms-flex:0;flex:0}}verdocs-build .preview-preview-wrapper{display:-ms-flexbox;display:flex;-ms-flex:1;flex:1;-ms-flex-pack:center;justify-content:center;overflow-y:scroll}';export{r as verdocs_build}
1
+ import{r as e,c as t,h as s,H as i,g as o}from"./p-5207d80c.js";import{VerdocsEndpoint as l}from"@verdocs/js-sdk";import{g as d}from"./p-7ed61c7c.js";import{S as a}from"./p-fd97809c.js";import"./p-83317d11.js";import"./p-9e371467.js";import"./p-784ac100.js";import"./p-a706bac9.js";const r=class{constructor(s){e(this,s),this.sdkError=t(this,"sdkError",7),this.stepChanged=t(this,"stepChanged",7),this.send=t(this,"send",7),this.templateUpdated=t(this,"templateUpdated",7),this.templateCreated=t(this,"templateCreated",7),this.rolesUpdated=t(this,"rolesUpdated",7),this.endpoint=l.getDefault(),this.templateId=null,this.step="preview",this.templateStore=null}onTemplateIdChanged(e,t){!t&&e&&"attachments"===this.step&&(this.step="preview"),this.loadTemplate(e).catch((e=>console.log("Unknown Error",e)))}onStepChanged(){this.loadTemplate(this.templateId).catch((e=>console.log("Unknown Error",e)))}async componentWillLoad(){var e,t,s,i,o,l;try{if(this.endpoint.loadSession(),!this.endpoint.session)return void console.log("[BUILD] Unable to start builder session, must be authenticated");if(!this.templateId)return console.log("[BUILD] No template ID, activating upload mode"),void(this.step="attachments");try{this.loadTemplate(this.templateId).catch((e=>console.log("[BUILD] Unable to load template",e)))}catch(i){console.log("[BUILD] Error loading template",i),null===(e=this.sdkError)||void 0===e||e.emit(new a(i.message,null===(t=i.response)||void 0===t?void 0:t.status,null===(s=i.response)||void 0===s?void 0:s.data))}}catch(e){console.log("[BUILD] Error with builder session",e),null===(i=this.sdkError)||void 0===i||i.emit(new a(e.message,null===(o=e.response)||void 0===o?void 0:o.status,null===(l=e.response)||void 0===l?void 0:l.data))}}async loadTemplate(e){e&&(this.templateStore=await d(this.endpoint,e,!1))}handleCancel(){this.step="preview"}async handleTemplateCreated(e){var t;await this.loadTemplate(e),this.templateId=e,this.step="roles",null===(t=this.stepChanged)||void 0===t||t.emit("roles")}async handleRolesUpdated(e){var t;null===(t=this.templateUpdated)||void 0===t||t.emit(e.detail)}async handleTemplateUpdated(e){var t;null===(t=this.templateUpdated)||void 0===t||t.emit(e.detail)}handleAttachmentsNext(){var e;this.step="roles",null===(e=this.stepChanged)||void 0===e||e.emit("roles")}handleRolesNext(){var e;this.step="fields",null===(e=this.stepChanged)||void 0===e||e.emit("fields")}handleStepChanged(e){var t;this.step=e,null===(t=this.stepChanged)||void 0===t||t.emit(e)}render(){return this.endpoint.session?this.templateStore?(console.log("[BUILD] Rendering build view",this.templateId,this.step,["attachments","roles","settings","fields","preview"].indexOf(this.step)),s(i,null,s("div",{class:"content"},s("verdocs-template-build-tabs",{endpoint:this.endpoint,templateId:this.templateId,step:this.step,onSdkError:e=>{var t;return null===(t=this.sdkError)||void 0===t?void 0:t.emit(e.detail)},onStepChanged:e=>this.handleStepChanged(e.detail)}),"attachments"===this.step&&s("verdocs-template-attachments",{templateId:this.templateId,endpoint:this.endpoint,onExit:()=>this.handleCancel(),onNext:()=>this.handleAttachmentsNext(),onTemplateUpdated:e=>this.handleTemplateUpdated(e)}),"roles"===this.step&&s("verdocs-template-roles",{templateId:this.templateId,endpoint:this.endpoint,onExit:()=>this.handleCancel(),onNext:()=>this.handleRolesNext(),onRolesUpdated:e=>this.handleRolesUpdated(e)}),"settings"===this.step&&s("div",{style:{flexDirection:"column",gap:"20px",display:"flex",maxWidth:"400px",margin:"20px"}},s("verdocs-template-name",{templateId:this.templateId,endpoint:this.endpoint,style:{backgroundColor:"#ffffff",padding:"20px"},onTemplateUpdated:e=>this.handleTemplateUpdated(e)}),s("verdocs-template-reminders",{templateId:this.templateId,endpoint:this.endpoint,style:{backgroundColor:"#ffffff",padding:"20px"},onTemplateUpdated:e=>this.handleTemplateUpdated(e)}),s("verdocs-template-visibility",{templateId:this.templateId,endpoint:this.endpoint,style:{backgroundColor:"#ffffff",padding:"20px"},onTemplateUpdated:e=>this.handleTemplateUpdated(e)})),"fields"===this.step&&s("verdocs-template-fields",{templateId:this.templateId,endpoint:this.endpoint,onTemplateUpdated:e=>this.handleTemplateUpdated(e)}),"preview"===this.step&&s("div",{class:"preview-container"},s("div",{class:"preview-send-wrapper"},s("verdocs-send",{templateId:this.templateId,endpoint:this.endpoint,onSend:e=>{var t;return null===(t=this.send)||void 0===t?void 0:t.emit(e.detail)},style:{width:"100%"}})),s("div",{class:"preview-preview-wrapper"},s("verdocs-preview",{templateId:this.templateId,endpoint:this.endpoint,style:{display:"flex",flex:"1",maxWidth:"1000px"}})))))):(console.log("[BUILD] No template ID, rendering created view"),s(i,null,s("div",{class:"content"},s("verdocs-template-build-tabs",{endpoint:this.endpoint,templateId:this.templateId,step:"attachments",onSdkError:e=>{var t;return null===(t=this.sdkError)||void 0===t?void 0:t.emit(e.detail)},onStepChanged:e=>this.handleStepChanged(e.detail)}),s("verdocs-template-create",{endpoint:this.endpoint,onExit:()=>this.handleCancel(),onNext:()=>this.handleAttachmentsNext(),onTemplateCreated:e=>this.handleTemplateCreated(e.detail.templateId)})))):s(i,null,s("verdocs-component-error",{message:"You must be authenticated to use this module."}))}get el(){return o(this)}static get watchers(){return{templateId:["onTemplateIdChanged"],step:["onStepChanged"]}}};r.style='@-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-build{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif}verdocs-build .content{-ms-flex:1;flex:1;gap:20px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column}verdocs-build verdocs-template-attachments,verdocs-build verdocs-template-roles{margin:20px}verdocs-build verdocs-template-fields{border-top:1px solid #777777}verdocs-build verdocs-template-attachments{padding:20px;background:#ffffff}verdocs-build verdocs-template-fields{width:100%}verdocs-build verdocs-preview{-ms-flex:1;flex:1}verdocs-build .preview-container{-ms-flex-direction:row;flex-direction:row;display:-ms-flexbox;display:flex;width:100%;background-color:#eeeeee;max-height:100%}@media all and (max-width: 450px){verdocs-build .preview-container{-ms-flex-direction:column;flex-direction:column}}verdocs-build .preview-send-wrapper{display:-ms-flexbox;display:flex;-ms-flex:0 0 300px;flex:0 0 300px;background-color:#ffffff;-webkit-box-shadow:1px 1px 6px -2px rgba(0, 0, 0, 0.4980392157);box-shadow:1px 1px 6px -2px rgba(0, 0, 0, 0.4980392157)}@media all and (max-width: 450px){verdocs-build .preview-send-wrapper{-ms-flex:0;flex:0}}verdocs-build .preview-preview-wrapper{display:-ms-flexbox;display:flex;-ms-flex:1;flex:1;-ms-flex-pack:center;justify-content:center;overflow-y:scroll}';export{r as verdocs_build}
@@ -1 +1 @@
1
- System.register(["./p-59073837.system.js"],(function(r){"use strict";var e,o,n;return{setters:[function(r){e=r.r;o=r.h;n=r.H}],execute:function(){var a='@-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-tags{font-family:"Inter", "Barlow", sans-serif}verdocs-template-tags span{margin:0 4px;height:28px;font-size:12px;font-weight:600;padding:5px 12px 7px;border-radius:5px;display:inline-block;-webkit-box-sizing:border-box;box-sizing:border-box;text-transform:uppercase;color:#33364b;border:1px solid #707ae5;background-color:#f5f5fa}';var t=a;var s=r("verdocs_template_tags",function(){function r(r){e(this,r);this.tags=undefined}r.prototype.render=function(){var r;return o(n,{key:"2abee2130a12d5165984e025633f419082d02714"},(r=this.tags)===null||r===void 0?void 0:r.map((function(r){return o("span",null,r)})))};return r}());s.style=t}}}));
1
+ System.register(["./p-59073837.system.js"],(function(r){"use strict";var e,o,n;return{setters:[function(r){e=r.r;o=r.h;n=r.H}],execute:function(){var t='@-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-tags{font-family:"Inter", "Barlow", sans-serif}verdocs-template-tags span{margin:0 4px;height:28px;font-size:12px;font-weight:600;padding:5px 12px 7px;border-radius:5px;display:inline-block;-webkit-box-sizing:border-box;box-sizing:border-box;text-transform:uppercase;color:#33364b;border:1px solid #707ae5;background-color:#f5f5fa}';var a=t;var c=r("verdocs_template_tags",function(){function r(r){e(this,r);this.tags=undefined}r.prototype.render=function(){var r;return o(n,{key:"8d6457fdcd02cee93906ee2ba5c59c0780d69dc8"},(r=this.tags)===null||r===void 0?void 0:r.map((function(r){return o("span",null,r)})))};return r}());c.style=a}}}));
@@ -0,0 +1 @@
1
+ import{r as o,h as e,H as r}from"./p-5207d80c.js";const t=class{constructor(e){o(this,e),this.checked=!1,this.name="",this.value="",this.disabled=!1}render(){return e(r,{key:"b8dc5d8e34deeaf6d67f8b38bcf485a66e6fe8c8",class:{disabled:this.disabled}},e("input",{key:"5e03859b9d3082add93aeba0eb626d8f41988f1c",type:"radio",value:this.value,name:this.name,id:`verdocs-radio-button-${this.name}-${this.value}`,checked:this.checked,disabled:this.disabled}),e("label",{key:"4caa876b9138003b5ff7d576fdc32fcf62858bca",htmlFor:`verdocs-radio-button-${this.name}-${this.value}`}))}};t.style='@-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-radio-button{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif;width:20px;height:20px;display:block;font-size:11px;position:relative;background-color:transparent;-webkit-transform-origin:bottom left;transform-origin:bottom left;border-radius:100%}verdocs-radio-button.disabled{opacity:0.5}verdocs-radio-button input[type=radio]{position:absolute;opacity:0}verdocs-radio-button input[type=radio]+label:before{content:"";background:#f5f5fa;border-radius:100%;border:1px solid rgba(0, 0, 0, 0.6);display:inline-block;width:16px;height:16px;position:absolute;left:1px;top:1px;cursor:pointer;text-align:center;-webkit-transition:all 250ms ease;transition:all 250ms ease}verdocs-radio-button input[type=radio]:checked+label:before{background-color:#55bc81;-webkit-box-shadow:inset 0 0 0 2px #f5f5fa;box-shadow:inset 0 0 0 2px #f5f5fa}verdocs-radio-button input[type=radio]:focus+label:before{outline:none;border-color:#55bc81}verdocs-radio-button input[type=radio]:disabled+label:before{-webkit-box-shadow:inset 0 0 0 4px #f5f5fa;box-shadow:inset 0 0 0 4px #f5f5fa;border-color:#a0a0d0;background:#a0a0d0}verdocs-radio-button input[type=radio]+label:empty:before{margin-right:0}verdocs-radio-button.required input[type=radio]+label:before{border:1px solid #cc0000}verdocs-radio-button.hide{display:none}verdocs-radio-button.focused{-webkit-animation:verdocs-field-pulse 0.75s 2;animation:verdocs-field-pulse 0.75s 2}';export{t as verdocs_radio_button}
@@ -0,0 +1 @@
1
+ import{c as e}from"./p-83317d11.js";import{getTemplate as o}from"@verdocs/js-sdk";import{c as r,g as a}from"./p-9e371467.js";import{c as t,g as s}from"./p-784ac100.js";import{u as n}from"./p-a706bac9.js";const i={},l=async(l,c,d=!1)=>{var p;let m=!1;i[c]||(console.debug("[TEMPLATES] No template store found for ID, creating",c),i[c]=(o=>{const r=(new Date).toISOString();return e({isLoading:!0,isLoaded:!1,isError:!1,error:null,roleNames:[],id:o,name:"",description:"",sender:"envelope_creator",profile_id:"",organization_id:"",counter:0,star_counter:0,is_sendable:!1,is_personal:!0,is_public:!1,created_at:r,updated_at:r,last_used_at:r,initial_reminder:0,followup_reminders:0,organization:null,roles:[],data:{},documents:[],fields:[],profile:null,search_key:"",tags:[],pages:[]})})(c),m=!0);const u=i[c];if(m||d){console.debug("[TEMPLATES] Loading template",{templateId:c,created:m,forceReload:d}),u.state.isLoading=!0,u.state.isLoaded=!1,u.state.isError=!1,u.state.error=n;try{const e=await o(l,c);!e.documents&&e.template_documents&&(e.documents=e.template_documents),null===(p=e.documents)||void 0===p||p.forEach((e=>{e.order||(e.order=0),e.page_numbers&&(e.pages=e.page_numbers)})),console.debug("[TEMPLATES] Got template",e),Object.assign(u.state,e),u.state.isLoaded=!0,u.state.isError=!1,u.state.error=n,r(e),t(e)}catch(e){throw console.error("[TEMPLATES] Error loading template",e),u.state.isLoaded=!1,u.state.isError=!0,u.state.error=e,e}u.state.isLoading=!1}else a(c),s(c);return u};export{l as g}
@@ -1 +1 @@
1
- var __awaiter=this&&this.__awaiter||function(e,t,n,s){function i(e){return e instanceof n?e:new n((function(t){t(e)}))}return new(n||(n=Promise))((function(n,a){function l(e){try{c(s.next(e))}catch(e){a(e)}}function r(e){try{c(s["throw"](e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(l,r)}c((s=s.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var n={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},s,i,a,l;return l={next:r(0),throw:r(1),return:r(2)},typeof Symbol==="function"&&(l[Symbol.iterator]=function(){return this}),l;function r(e){return function(t){return c([e,t])}}function c(r){if(s)throw new TypeError("Generator is already executing.");while(l&&(l=0,r[0]&&(n=0)),n)try{if(s=1,i&&(a=r[0]&2?i["return"]:r[0]?i["throw"]||((a=i["return"])&&a.call(i),0):i.next)&&!(a=a.call(i,r[1])).done)return a;if(i=0,a)r=[r[0]&2,a.value];switch(r[0]){case 0:case 1:a=r;break;case 4:n.label++;return{value:r[1],done:false};case 5:n.label++;i=r[1];r=[0];continue;case 7:r=n.ops.pop();n.trys.pop();continue;default:if(!(a=n.trys,a=a.length>0&&a[a.length-1])&&(r[0]===6||r[0]===2)){n=0;continue}if(r[0]===3&&(!a||r[1]>a[0]&&r[1]<a[3])){n.label=r[1];break}if(r[0]===6&&n.label<a[1]){n.label=a[1];a=r;break}if(a&&n.label<a[2]){n.label=a[2];n.ops.push(r);break}if(a[2])n.ops.pop();n.trys.pop();continue}r=t.call(e,n)}catch(e){r=[6,e];i=0}finally{s=a=0}if(r[0]&5)throw r[1];return{value:r[0]?r[1]:void 0,done:true}}};System.register(["./p-59073837.system.js","@verdocs/js-sdk","./p-c8a15cb7.system.js","./p-2c5350ec.system.js"],(function(e){"use strict";var t,n,s,i,a,l,r,c,o,d,p;return{setters:[function(e){t=e.r;n=e.c;s=e.h;i=e.H},function(e){a=e.VerdocsEndpoint;l=e.getTemplates;r=e.deleteTemplate;c=e.integerSequence;o=e.canPerformTemplateAction},function(e){d=e.S},function(e){p=e.f}],execute:function(){var h='@-webkit-keyframes verdocs-field-pulse {\n 0% {\n background-color: rgba(0, 0, 0, 0.35);\n }\n 50% {\n background-color: rgba(0, 0, 0, 0);\n }\n 100% {\n background-color: rgba(0, 0, 0, 0.35);\n }\n}\n@keyframes verdocs-field-pulse {\n 0% {\n background-color: rgba(0, 0, 0, 0.35);\n }\n 50% {\n background-color: rgba(0, 0, 0, 0);\n }\n 100% {\n background-color: rgba(0, 0, 0, 0.35);\n }\n}\nverdocs-templates-list {\n display: -ms-flexbox;\n display: flex;\n padding: 10px;\n font-size: 18px;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n border-radius: 6px;\n color: #33364b;\n -ms-flex-direction: column;\n flex-direction: column;\n font-family: "Inter", "Barlow", sans-serif;\n}\nverdocs-templates-list .header {\n width: 100%;\n row-gap: 4px;\n display: -ms-flexbox;\n display: flex;\n -ms-flex-wrap: wrap;\n flex-wrap: wrap;\n -webkit-column-gap: 12px;\n -moz-column-gap: 12px;\n column-gap: 12px;\n margin: 0 0 10px 0;\n -ms-flex-align: center;\n align-items: center;\n -ms-flex-direction: row;\n flex-direction: row;\n}\nverdocs-templates-list .header .filter {\n width: 150px;\n}\nverdocs-templates-list .header verdocs-text-input {\n margin: 0;\n}\nverdocs-templates-list .header verdocs-text-input input {\n height: 32px;\n}\nverdocs-templates-list .filter {\n -ms-flex-align: center;\n align-items: center;\n}\nverdocs-templates-list .template-placeholder {\n height: 48px;\n -ms-flex: 0 0 48px;\n flex: 0 0 48px;\n margin: 5px 0;\n border-radius: 5px;\n background: #f5f5fa;\n}\nverdocs-templates-list .template {\n width: 100%;\n margin: 2px 0;\n border: 1px solid #ffffff;\n background: #ffffff;\n}\nverdocs-templates-list .template:hover {\n cursor: pointer;\n background: #ededff;\n border: 1px solid #a7a7f5;\n}\nverdocs-templates-list .template .inner {\n gap: 12px;\n display: -ms-flexbox;\n display: flex;\n padding: 8px 14px;\n border-radius: 5px;\n -ms-flex-direction: row;\n flex-direction: row;\n -ms-flex-align: center;\n align-items: center;\n container-type: inline-size;\n}\nverdocs-templates-list .template .inner svg {\n width: 24px;\n height: 24px;\n}\nverdocs-templates-list .name {\n -ms-flex: 1;\n flex: 1;\n display: -ms-flexbox;\n display: flex;\n color: black;\n font-size: 16px;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\n@media screen and (max-width: 1300px) {\n verdocs-templates-list .name {\n font-size: 16px;\n }\n}\nverdocs-templates-list .spacer {\n margin: 0;\n height: 30px;\n -ms-flex: 0 0 1px;\n flex: 0 0 1px;\n display: -ms-flexbox;\n display: flex;\n border-right: 1px solid #dad8dd;\n}\n@media screen and (max-width: 800px) {\n verdocs-templates-list .spacer {\n display: none;\n }\n}\nverdocs-templates-list .empty-text {\n font-size: 20px;\n text-align: center;\n margin: 16px 0 0 0;\n padding: 80px 80px;\n border: 2px solid #ccc;\n}\nverdocs-templates-list .usage,\nverdocs-templates-list .ownership,\nverdocs-templates-list .last-used {\n gap: 10px;\n color: #444;\n display: -ms-flexbox;\n display: flex;\n font-size: 16px;\n margin: 0 0 0 10px;\n -ms-flex-align: center;\n align-items: center;\n -ms-flex-direction: row;\n flex-direction: row;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\nverdocs-templates-list .usage span,\nverdocs-templates-list .usage svg,\nverdocs-templates-list .ownership span,\nverdocs-templates-list .ownership svg,\nverdocs-templates-list .last-used span,\nverdocs-templates-list .last-used svg {\n width: 24px;\n height: 24px;\n}\nverdocs-templates-list .usage span,\nverdocs-templates-list .ownership span,\nverdocs-templates-list .last-used span {\n display: block;\n}\n@media screen and (max-width: 700px) {\n verdocs-templates-list verdocs-template-star {\n display: none;\n }\n}\nverdocs-templates-list .ownership {\n -ms-flex: 0 0 100px;\n flex: 0 0 100px;\n}\n@media screen and (max-width: 700px) {\n verdocs-templates-list .ownership {\n display: none;\n }\n}\nverdocs-templates-list .last-used {\n -ms-flex: 0 0 130px;\n flex: 0 0 130px;\n}\nverdocs-templates-list .usage {\n -ms-flex: 0 0 60px;\n flex: 0 0 60px;\n}\nverdocs-templates-list .header-row {\n display: none;\n}\nverdocs-templates-list table {\n container-type: size;\n max-width: 100%;\n overflow: hidden;\n table-layout: fixed;\n}\nverdocs-templates-list .data-row {\n cursor: pointer;\n background: #ededff;\n border: 1px solid #a7a7f5;\n}\nverdocs-templates-list .data-col svg {\n width: 24px;\n height: 24px;\n}\nverdocs-templates-list .col-name {\n text-overflow: ellipsis;\n white-space: nowrap;\n overflow: hidden;\n}\n@container (max-width:700 px) {\n verdocs-templates-list verdocs-templates-list .col-starred {\n display: none;\n }\n}';var v=h;var u='<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" d="M12 21a9.004 9.004 0 008.716-6.747M12 21a9.004 9.004 0 01-8.716-6.747M12 21c2.485 0 4.5-4.03 4.5-9S14.485 3 12 3m0 18c-2.485 0-4.5-4.03-4.5-9S9.515 3 12 3m0 0a8.997 8.997 0 017.843 4.582M12 3a8.997 8.997 0 00-7.843 4.582m15.686 0A11.953 11.953 0 0112 10.5c-2.998 0-5.74-1.1-7.843-2.918m15.686 0A8.959 8.959 0 0121 12c0 .778-.099 1.533-.284 2.253m0 0A17.919 17.919 0 0112 16.5c-3.162 0-6.133-.815-8.716-2.247m0 0A9.015 9.015 0 013 12c0-1.605.42-3.113 1.157-4.418" /></svg>';var f='<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" d="M16.5 10.5V6.75a4.5 4.5 0 10-9 0v3.75m-.75 11.25h10.5a2.25 2.25 0 002.25-2.25v-6.75a2.25 2.25 0 00-2.25-2.25H6.75a2.25 2.25 0 00-2.25 2.25v6.75a2.25 2.25 0 002.25 2.25z" /></svg>';var m='<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" d="M3.75 21h16.5M4.5 3h15M5.25 3v18m13.5-18v18M9 6.75h1.5m-1.5 3h1.5m-1.5 3h1.5m3-6H15m-1.5 3H15m-1.5 3H15M9 21v-3.375c0-.621.504-1.125 1.125-1.125h3.75c.621 0 1.125.504 1.125 1.125V21" /></svg>';var x='<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" d="M21.75 6.75v10.5a2.25 2.25 0 01-2.25 2.25h-15a2.25 2.25 0 01-2.25-2.25V6.75m19.5 0A2.25 2.25 0 0019.5 4.5h-15a2.25 2.25 0 00-2.25 2.25m19.5 0v.243a2.25 2.25 0 01-1.07 1.916l-7.5 4.615a2.25 2.25 0 01-2.36 0L3.32 8.91a2.25 2.25 0 01-1.07-1.916V6.75" /></svg>';var g='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 122.88 122.88"><g><path d="M81.61,4.73c0-2.61,2.58-4.73,5.77-4.73c3.19,0,5.77,2.12,5.77,4.73v20.72c0,2.61-2.58,4.73-5.77,4.73 c-3.19,0-5.77-2.12-5.77-4.73V4.73L81.61,4.73z M66.11,103.81c-0.34,0-0.61-1.43-0.61-3.2c0-1.77,0.27-3.2,0.61-3.2H81.9 c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H66.11L66.11,103.81z M15.85,67.09c-0.34,0-0.61-1.43-0.61-3.2 c0-1.77,0.27-3.2,0.61-3.2h15.79c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H15.85L15.85,67.09z M40.98,67.09 c-0.34,0-0.61-1.43-0.61-3.2c0-1.77,0.27-3.2,0.61-3.2h15.79c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H40.98 L40.98,67.09z M66.11,67.09c-0.34,0-0.61-1.43-0.61-3.2c0-1.77,0.27-3.2,0.61-3.2H81.9c0.34,0,0.61,1.43,0.61,3.2 c0,1.77-0.27,3.2-0.61,3.2H66.11L66.11,67.09z M91.25,67.09c-0.34,0-0.61-1.43-0.61-3.2c0-1.77,0.27-3.2,0.61-3.2h15.79 c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H91.25L91.25,67.09z M15.85,85.45c-0.34,0-0.61-1.43-0.61-3.2 c0-1.77,0.27-3.2,0.61-3.2h15.79c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H15.85L15.85,85.45z M40.98,85.45 c-0.34,0-0.61-1.43-0.61-3.2c0-1.77,0.27-3.2,0.61-3.2h15.79c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H40.98 L40.98,85.45z M66.11,85.45c-0.34,0-0.61-1.43-0.61-3.2c0-1.77,0.27-3.2,0.61-3.2H81.9c0.34,0,0.61,1.43,0.61,3.2 c0,1.77-0.27,3.2-0.61,3.2H66.11L66.11,85.45z M91.25,85.45c-0.34,0-0.61-1.43-0.61-3.2c0-1.77,0.27-3.2,0.61-3.2h15.79 c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H91.25L91.25,85.45z M15.85,103.81c-0.34,0-0.61-1.43-0.61-3.2 c0-1.77,0.27-3.2,0.61-3.2h15.79c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H15.85L15.85,103.81z M40.98,103.81 c-0.34,0-0.61-1.43-0.61-3.2c0-1.77,0.27-3.2,0.61-3.2h15.79c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H40.98 L40.98,103.81z M29.61,4.73c0-2.61,2.58-4.73,5.77-4.73s5.77,2.12,5.77,4.73v20.72c0,2.61-2.58,4.73-5.77,4.73 s-5.77-2.12-5.77-4.73V4.73L29.61,4.73z M6.4,45.32h110.07V21.47c0-0.8-0.33-1.53-0.86-2.07c-0.53-0.53-1.26-0.86-2.07-0.86H103 c-1.77,0-3.2-1.43-3.2-3.2c0-1.77,1.43-3.2,3.2-3.2h10.55c2.57,0,4.9,1.05,6.59,2.74c1.69,1.69,2.74,4.02,2.74,6.59v27.06v65.03 c0,2.57-1.05,4.9-2.74,6.59c-1.69,1.69-4.02,2.74-6.59,2.74H9.33c-2.57,0-4.9-1.05-6.59-2.74C1.05,118.45,0,116.12,0,113.55V48.52 V21.47c0-2.57,1.05-4.9,2.74-6.59c1.69-1.69,4.02-2.74,6.59-2.74H20.6c1.77,0,3.2,1.43,3.2,3.2c0,1.77-1.43,3.2-3.2,3.2H9.33 c-0.8,0-1.53,0.33-2.07,0.86c-0.53,0.53-0.86,1.26-0.86,2.07V45.32L6.4,45.32z M116.48,51.73H6.4v61.82c0,0.8,0.33,1.53,0.86,2.07 c0.53,0.53,1.26,0.86,2.07,0.86h104.22c0.8,0,1.53-0.33,2.07-0.86c0.53-0.53,0.86-1.26,0.86-2.07V51.73L116.48,51.73z M50.43,18.54 c-1.77,0-3.2-1.43-3.2-3.2c0-1.77,1.43-3.2,3.2-3.2h21.49c1.77,0,3.2,1.43,3.2,3.2c0,1.77-1.43,3.2-3.2,3.2H50.43L50.43,18.54z"/></g></svg>';var w='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 410.2"><path d="M35.28 35.51h32.54v43.42c0 10.58 4.27 20.06 11.35 27.23 17.03 17.14 45.5 17.45 63.06.93 7.71-7.29 12.4-17.14 12.4-28.16V35.51h65.71v43.42c0 6.34 1.56 12.3 4.35 17.6 2.03 3.85 4.71 7.37 7.92 10.43l2.41 2.24c1.79 1.46 3.71 2.79 5.76 3.97l.31.18.07.04.25.13.16.1.15.08.27.14.05.03.32.17.05.03.27.13.15.08.17.09.26.12.07.04.32.16.03.01.31.15.12.06.2.09.24.11.1.05.33.14.34.16.1.04.23.1.21.09.13.05.31.13h.03l.34.14.08.04.27.1.18.07.16.06.3.11.05.02.34.12.06.02.3.11.16.05.19.07.26.09.09.03.35.12.02.01.34.1.13.04.22.07.25.07.11.03.36.11.36.1.11.03.25.07.22.06.14.04.34.09h.02l.37.1.08.02.29.06.19.05.17.03.32.08.05.01.37.08.06.01.31.06.17.04.21.03.28.06.09.02.37.07h.03l.35.06.14.03.23.03.27.04.11.02.38.06.38.05.12.01.26.04.23.03.15.01.35.05h.03l.39.04.08.01.3.02.21.02.17.02.34.02.05.01.39.03h.05l.34.02.18.01.21.01.3.02h.08l.39.01.03.01.36.01h.39l.28.01h.96l.33-.01h.39l.18-.01.2-.01.25-.01h.13l.32-.02h.07l.38-.02h.01l.37-.02.07-.01.32-.02.12-.01.26-.02.19-.02.19-.02.25-.02.13-.01.31-.04h.07l.37-.05h.01l.37-.04.06-.01.32-.04.12-.02.26-.03.18-.03.19-.03.24-.04.14-.02.3-.05.07-.01.36-.06h.01l.37-.07.05-.01.32-.06.12-.02.25-.05.18-.04.19-.04.23-.05.14-.03.29-.07.08-.01.35-.08.01-.01.36-.08.05-.02.31-.08.11-.02.25-.07.17-.04.2-.06.22-.05.14-.05.28-.08.07-.02.34-.09.02-.01.36-.11.03-.01.32-.1.1-.03.25-.08.16-.05.19-.07.22-.07.13-.04.28-.1.08-.03.32-.11.02-.01.35-.13.04-.01.3-.11.09-.04.26-.1.15-.06.19-.07.21-.09.13-.05.26-.11.08-.03.32-.13.02-.01.33-.14.04-.02.3-.13.09-.04.24-.11.14-.07.19-.08.19-.1.14-.06.25-.12.08-.03.3-.16h.03l.32-.17.03-.01.29-.16.09-.04.24-.12.13-.07.19-.1.18-.1.14-.07.23-.13.08-.05.29-.16.03-.01.31-.18c1.11-.64 2.17-1.31 3.2-2.03l2.71-1.95c4.36-3.56 7.92-7.88 10.43-12.76 2.73-5.26 4.25-11.19 4.25-17.5V35.51h33.97c9.68 0 18.5 3.98 24.91 10.38 6.4 6.37 10.38 15.2 10.38 24.9V192.9H365.1v-53.83H11.3v233.49c0 15.25 12.49 27.74 27.75 27.74h298.3c15.27 0 27.75-12.51 27.75-27.74V325.6h11.31v49.32c0 9.7-3.98 18.53-10.37 24.91-6.42 6.39-15.24 10.37-24.92 10.37H35.28c-9.68 0-18.49-3.97-24.89-10.37C3.97 393.41 0 384.59 0 374.92V70.79C0 61.12 3.97 52.3 10.36 45.9c6.43-6.42 15.25-10.39 24.92-10.39zm211.43-21.54c0-7.71 7.61-13.97 17.03-13.97 9.42 0 17.04 6.26 17.04 13.97v64.96c0 7.7-7.62 13.96-17.04 13.96-9.42 0-17.03-6.26-17.03-13.96V13.97zm-152.52 0C94.19 6.26 101.81 0 111.23 0c9.42 0 17.03 6.26 17.03 13.97v64.96c0 7.7-7.61 13.96-17.03 13.96-9.42 0-17.04-6.26-17.04-13.96V13.97zm311.37 327.72c1.48-14.79 2.69-32.45 3.59-46.5h-75.88v-71.88h77.43c-.39-14.06-1.17-31.75-2.35-46.58-.96-5.93 6.02-9.73 10.51-5.9l90.89 82.99c2.7 2.31 3.02 6.38.7 9.08l-.74.73-93.65 84.05c-4.6 3.89-11.47-.19-10.5-5.99zM63.51 286h50.56c3.53 0 6.43 2.91 6.43 6.44v42.06c0 3.52-2.91 6.44-6.43 6.44H63.51c-3.53 0-6.44-2.91-6.44-6.44v-42.06c0-3.54 2.9-6.44 6.44-6.44zm198.44-98.62h50.55c3.23 0 5.92 2.43 6.37 5.52h-16v49.42h-40.92c-3.53 0-6.45-2.9-6.45-6.45v-42.05c0-3.54 2.9-6.44 6.45-6.44zm0 98.62h40.92v39.6h16.07v8.9c0 3.52-2.92 6.44-6.44 6.44h-50.55c-3.53 0-6.45-2.91-6.45-6.44v-42.06c0-3.54 2.9-6.44 6.45-6.44zm-98.5-98.62h50.56c3.53 0 6.43 2.92 6.43 6.44v42.05c0 3.53-2.91 6.45-6.43 6.45h-50.56c-3.53 0-6.44-2.9-6.44-6.45v-42.05c0-3.54 2.9-6.44 6.44-6.44zm-99.94 0h50.56c3.53 0 6.43 2.92 6.43 6.44v42.05c0 3.53-2.91 6.45-6.43 6.45H63.51c-3.53 0-6.44-2.9-6.44-6.45v-42.05c0-3.54 2.9-6.44 6.44-6.44zM163.45 286h50.56c3.53 0 6.43 2.91 6.43 6.44v42.06c0 3.52-2.91 6.44-6.43 6.44h-50.56c-3.53 0-6.44-2.91-6.44-6.44v-42.06c0-3.54 2.9-6.44 6.44-6.44z"/></svg>';var b='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 506.49"><path fill-rule="nonzero" d="m371.06 415.61-43.25 11.52 6.23-46.41 37.02 34.89zm6.76-177.5c36.98 0 70.56 15.04 94.83 39.35C496.96 301.7 512 335.25 512 372.31c0 37.02-15.02 70.61-39.3 94.88l-.68.64c-24.23 23.88-57.5 38.66-94.2 38.66-37.06 0-70.61-15.04-94.88-39.31l-.64-.69c-23.9-24.24-38.68-57.53-38.68-94.18 0-37.06 15.04-70.61 39.32-94.89 24.27-24.27 57.85-39.31 94.88-39.31zm78.74 55.41c-20.09-20.11-47.96-32.58-78.74-32.58-30.75 0-58.61 12.47-78.75 32.62-20.15 20.14-32.62 48-32.62 78.75 0 30.5 12.25 58.14 32.02 78.19l.6.55c20.14 20.14 48 32.61 78.75 32.61 30.48 0 58.12-12.25 78.21-32.02l.54-.58c20.15-20.15 32.61-48 32.61-78.75s-12.48-58.61-32.62-78.79zM294.24 17.11C294.24 7.69 303.52 0 315.1 0c11.57 0 20.87 7.64 20.87 17.11v74.85c0 9.42-9.3 17.11-20.87 17.11-11.58 0-20.86-7.65-20.86-17.11V17.11zM56.8 242.28c-1.17 0-2.23-5.2-2.23-11.57 0-6.38.92-11.53 2.23-11.53h56.94c1.18 0 2.24 5.2 2.24 11.53 0 6.39-.92 11.57-2.24 11.57H56.8zm90.77 0c-1.17 0-2.23-5.2-2.23-11.57 0-6.38.92-11.53 2.23-11.53h56.94c1.18 0 2.24 5.2 2.24 11.53 0 6.39-.92 11.57-2.24 11.57h-56.94zm90.77 0c-1.16 0-2.22-5.2-2.22-11.57 0-6.38.92-11.53 2.22-11.53h56.94c1.19 0 2.25 5.15 2.25 11.49-5.7 3.55-11.2 7.44-16.43 11.61h-42.76zm-181.4 66.24c-1.18 0-2.24-5.2-2.24-11.57 0-6.38.93-11.58 2.24-11.58h56.94c1.18 0 2.22 5.2 2.22 11.58 0 6.37-.91 11.57-2.22 11.57H56.94zm90.77 0c-1.18 0-2.24-5.2-2.24-11.57 0-6.38.93-11.58 2.24-11.58h56.94c1.18 0 2.23 5.2 2.23 11.58 0 6.37-.92 11.57-2.23 11.57h-56.94zM57.06 374.8c-1.18 0-2.24-5.2-2.24-11.59 0-6.36.94-11.56 2.24-11.56H114c1.19 0 2.24 5.2 2.24 11.56 0 6.39-.93 11.59-2.24 11.59H57.06zm90.78 0c-1.19 0-2.25-5.2-2.25-11.59 0-6.36.94-11.56 2.25-11.56h56.94c1.18 0 2.24 5.2 2.24 11.56 0 6.39-.94 11.59-2.24 11.59h-56.94zM106.83 17.11C106.83 7.69 116.1 0 127.69 0c11.57 0 20.86 7.64 20.86 17.11v74.85c0 9.42-9.34 17.11-20.86 17.11-11.59 0-20.86-7.65-20.86-17.11V17.11zM22.97 163.64h397.39V77.46c0-2.94-1.19-5.53-3.09-7.43-1.9-1.9-4.59-3.08-7.42-3.08h-38.1c-6.39 0-11.59-5.2-11.59-11.57 0-6.38 5.2-11.58 11.59-11.58h38.1c9.32 0 17.7 3.77 23.82 9.88 6.12 6.14 9.88 14.5 9.88 23.83v136.81c-7.61-2.62-15.41-4.73-23.44-6.29v-21.38h.25H22.97v223.17c0 2.94 1.18 5.52 3.08 7.42 1.91 1.9 4.61 3.08 7.44 3.08h188.85c2.16 8.02 4.86 15.84 8.11 23.36H33.71c-9.3 0-17.7-3.75-23.84-9.89C3.75 427.72 0 419.36 0 410.02V77.55c0-9.29 3.75-17.7 9.87-23.82 6.14-6.13 14.5-9.89 23.84-9.89h40.67c6.38 0 11.57 5.2 11.57 11.57C85.95 61.8 80.76 67 74.38 67H33.71c-2.96 0-5.54 1.18-7.44 3.08-1.9 1.9-3.09 4.59-3.09 7.43v86.16h-.21v-.03zm158.95-96.69c-6.39 0-11.57-5.2-11.57-11.57 0-6.38 5.18-11.58 11.57-11.58h77.55c6.39 0 11.57 5.2 11.57 11.58 0 6.37-5.18 11.57-11.57 11.57h-77.55zm161.66 303.24 45.37-51.33c.72-.84 1.78-1.34 2.85-1.36.69-.01 1.37.13 1.98.45l32.94 29.96c.66.59 1.05 1.46 1.06 2.35.02 1-.39 1.98-1.16 2.66l-46.15 52.16-36.95-34.89h.06z"/></svg>';var k=[{value:"all",label:"All"},{value:"personal",label:"Personal"},{value:"shared",label:"Shared"},{value:"public",label:"Public"}];var y=[{value:"all",label:"All"},{value:"starred",label:"Starred"},{value:"unstarred",label:"Not Starred"}];var z=[{value:"name",label:"Name"},{value:"created_at",label:"Created"},{value:"updated_at",label:"Last Updated"},{value:"last_used_at",label:"Last Used"},{value:"counter",label:"Most Used"},{value:"star_counter",label:"Most Starred"}];var M=e("verdocs_templates_list",function(){function e(e){var s=this;t(this,e);this.sdkError=n(this,"sdkError",7);this.viewTemplate=n(this,"viewTemplate",7);this.signNow=n(this,"signNow",7);this.submittedData=n(this,"submittedData",7);this.editTemplate=n(this,"editTemplate",7);this.templateDeleted=n(this,"templateDeleted",7);this.changeSort=n(this,"changeSort",7);this.changeSharing=n(this,"changeSharing",7);this.changeStarred=n(this,"changeStarred",7);this.changeName=n(this,"changeName",7);this.handleOptionSelected=function(e,t){var n,i,a,l;if(e==="send"){(n=s.viewTemplate)===null||n===void 0?void 0:n.emit({endpoint:s.endpoint,template:t})}else if(e==="signnow"){(i=s.signNow)===null||i===void 0?void 0:i.emit({endpoint:s.endpoint,template:t})}else if(e==="submitted"){(a=s.submittedData)===null||a===void 0?void 0:a.emit({endpoint:s.endpoint,template:t})}else if(e==="edit"){(l=s.editTemplate)===null||l===void 0?void 0:l.emit({endpoint:s.endpoint,template:t})}else if(e==="delete"){s.confirmDelete=t}};this.endpoint=a.getDefault();this.sharing="all";this.starred="all";this.sort="updated_at";this.name="";this.allowedActions=["send","submitted","link","edit","delete"];this.showPagination=true;this.rowsPerPage=10;this.selectedPage=0;this.count=0;this.initiallyLoaded=false;this.loading=true;this.confirmDelete=null;this.templates=[];this.localNameFilter=""}e.prototype.handleSharingUpdated=function(){return this.queryTemplates()};e.prototype.handleStarredUpdated=function(){return this.queryTemplates()};e.prototype.handleSortUpdated=function(){return this.queryTemplates()};e.prototype.handleNameUpdated=function(){return this.queryTemplates()};e.prototype.handlePageUpdated=function(){return this.queryTemplates()};e.prototype.componentWillLoad=function(){this.endpoint.loadSession();if(!this.endpoint.session){console.log("[TEMPLATES] Must be authenticated");return}};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.queryTemplates()];case 1:e.sent();this.initiallyLoaded=true;return[2]}}))}))};e.prototype.queryTemplates=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,n,s,i,a;return __generator(this,(function(r){switch(r.label){case 0:console.log("[TEMPLATES] Querying templates");this.loading=true;r.label=1;case 1:r.trys.push([1,3,,4]);s={page:this.selectedPage,rows:this.rowsPerPage};if(this.name.trim()!==""){s.q=this.name.trim()}return[4,l(this.endpoint,s)];case 2:i=r.sent();this.templates=i.templates;this.count=i.count;this.loading=false;return[3,4];case 3:a=r.sent();this.loading=false;console.log("[TEMPLATES] Error listing templates",a);(e=this.sdkError)===null||e===void 0?void 0:e.emit(new d(a.message,(t=a.response)===null||t===void 0?void 0:t.status,(n=a.response)===null||n===void 0?void 0:n.data));return[3,4];case 4:return[2]}}))}))};e.prototype.deleteTemplate=function(e){var t=this;this.confirmDelete=null;r(this.endpoint,e.id).then((function(){var n;console.log("[TEMPLATES] Deleted template",e);(n=t.templateDeleted)===null||n===void 0?void 0:n.emit({endpoint:t.endpoint,template:e});return t.queryTemplates()})).catch((function(n){var s,i,a;console.log("[TEMPLATES] Error deleting template",e);(s=t.sdkError)===null||s===void 0?void 0:s.emit(new d(n.message,(i=n.response)===null||i===void 0?void 0:i.status,(a=n.response)===null||a===void 0?void 0:a.data))}))};e.prototype.render=function(){var e=this;var t=!this.localNameFilter?this.templates:this.templates.filter((function(t){return t.name.toLowerCase().includes(e.localNameFilter.toLowerCase())}));return s(i,{key:"898a88f10e4db5a0478c10370b9560e9ec2d2e25"},s("div",{key:"c4c2a4a0bff5ab4ca103377ae08d376b0951f9b6",class:"header"},s("div",{key:"20f158444d4b919126800d546a54834128f7a44d",class:"filter"},s("verdocs-text-input",{key:"dbe2cbff9289957b4fd1ab37664d8c465502fb2e",id:"verdocs-filter-name",value:this.name,clearable:true,autocomplete:"off",placeholder:"Filter by Name...",onInput:function(t){return e.localNameFilter=t.target.value.trim()},onFocusout:function(t){var n;e.name=t.target.value.trim();e.localNameFilter=t.target.value.trim();(n=e.changeName)===null||n===void 0?void 0:n.emit(e.name)}})),s("verdocs-quick-filter",{key:"5fde3481a06af0d8fb407754178762d03dbeb2f2",label:"Sharing",value:this.sharing,options:k,onOptionSelected:function(t){var n;e.sharing=t.detail.value;(n=e.changeSharing)===null||n===void 0?void 0:n.emit(e.sharing)}}),s("verdocs-quick-filter",{key:"a712ec2f941b30700b8fc8becd6e97d7be1311e2",label:"Starred",value:this.starred,options:y,onOptionSelected:function(t){var n;e.starred=t.detail.value;(n=e.changeStarred)===null||n===void 0?void 0:n.emit(e.starred)}}),s("verdocs-quick-filter",{key:"593d4b27e4939583864c799b77a7b3a81c99b2f0",label:"Sort By",value:this.sort,options:z,onOptionSelected:function(t){var n;e.sort=t.detail.value;(n=e.changeSort)===null||n===void 0?void 0:n.emit(e.sort)}}),this.loading&&s("verdocs-spinner",{key:"6ee3d50355dabbd44a89b38f8239470a18ac9fa8",mode:"dark",size:24}),s("div",{key:"d7601f4897a5322d0bd09e579c54de2a183fd622",style:{display:"flex",flex:"1"}})),t.map((function(t){var n=e.sort==="created_at"?"created_at":e.sort==="updated_at"?"updated_at":"last_used_at";var i=t[n];var a=[];var l=[];if(e.allowedActions.includes("send")){a.push({label:"Preview / Send",id:"send",disabled:!o(e.endpoint.profile,"read",t)})}if(e.allowedActions.includes("signnow")){a.push({label:"Sign Now",id:"signnow",disabled:true})}if(e.allowedActions.includes("submitted")){a.push({label:""});a.push({label:"Submissions",id:"submitted",disabled:!o(e.endpoint.profile,"read",t)})}if(e.allowedActions.includes("link")||e.allowedActions.includes("edit")||e.allowedActions.includes("delete")){a.push({label:""});if(e.allowedActions.includes("link")||e.allowedActions.includes("edit")||e.allowedActions.includes("delete")){a.push({label:"Edit",id:"edit",disabled:!l.includes("write")})}if(e.allowedActions.includes("link")||e.allowedActions.includes("edit")||e.allowedActions.includes("delete")){a.push({label:"Delete",id:"delete",disabled:!l.includes("delete")})}}return s("div",{class:"template",onClick:function(){var n;(n=e.viewTemplate)===null||n===void 0?void 0:n.emit({endpoint:e.endpoint,template:t})}},s("div",{class:"inner"},s("verdocs-template-star",{template:t,endpoint:e.endpoint}),s("div",{class:"spacer icon-spacer"}),s("div",{class:"name"},t.name),s("div",{class:"spacer usage-spacer"}),s("div",{class:"usage"},s("span",{innerHTML:x,title:"Usage Counter"}),t.counter||"--"),s("div",{class:"spacer last-used-spacer"}),s("div",{class:"last-used"},n==="created_at"&&s("span",{innerHTML:g,title:"Created"}),n==="updated_at"&&s("span",{innerHTML:b,title:"Last Updated"}),n==="last_used_at"&&s("span",{innerHTML:w,title:"Last Used"}),i?p(new Date(i),"P"):"Never"),s("div",{class:"spacer ownership-spacer"}),t.is_public&&s("div",{class:"ownership"},s("span",{innerHTML:u})," Public"),!t.is_public&&!t.is_personal&&s("div",{class:"ownership"},s("span",{innerHTML:f})," Private"),!t.is_public&&t.is_personal&&s("div",{class:"ownership"},s("span",{innerHTML:m})," Shared"),s("verdocs-dropdown",{options:a,onOptionSelected:function(n){return e.handleOptionSelected(n.detail.id,t)}})))})),!this.initiallyLoaded&&s("div",{key:"8a712cf07d27722804ffa0984e2860b07e148e96"},c(0,this.rowsPerPage).map((function(){return s("div",{class:"template-placeholder"})}))),this.initiallyLoaded&&!this.templates.length&&s("div",{key:"41d59dffca16ffcfe601a06ac85d85534b02a415",class:"empty-text"},"No matching templates found. Please adjust your filters and try again."),this.initiallyLoaded&&this.templates.length&&this.showPagination?s("div",{style:{marginTop:"20px"}},s("verdocs-pagination",{selectedPage:this.selectedPage,perPage:this.rowsPerPage,itemCount:this.count,onSelectPage:function(t){e.selectedPage=t.detail.selectedPage}})):s("div",null),this.confirmDelete&&s("verdocs-ok-dialog",{key:"8a42405881f456dac853d2bb382277e4c7e7f0b7",heading:"Delete this Template?",message:"This operation cannot be undone.",onNext:function(){return e.deleteTemplate(e.confirmDelete)},onExit:function(){return e.confirmDelete=null},showCancel:true}))};Object.defineProperty(e,"watchers",{get:function(){return{sharing:["handleSharingUpdated"],starred:["handleStarredUpdated"],sort:["handleSortUpdated"],name:["handleNameUpdated"],selectedPage:["handlePageUpdated"]}},enumerable:false,configurable:true});return e}());M.style=v}}}));
1
+ var __awaiter=this&&this.__awaiter||function(e,t,n,s){function i(e){return e instanceof n?e:new n((function(t){t(e)}))}return new(n||(n=Promise))((function(n,a){function l(e){try{c(s.next(e))}catch(e){a(e)}}function r(e){try{c(s["throw"](e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(l,r)}c((s=s.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var n={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},s,i,a,l;return l={next:r(0),throw:r(1),return:r(2)},typeof Symbol==="function"&&(l[Symbol.iterator]=function(){return this}),l;function r(e){return function(t){return c([e,t])}}function c(r){if(s)throw new TypeError("Generator is already executing.");while(l&&(l=0,r[0]&&(n=0)),n)try{if(s=1,i&&(a=r[0]&2?i["return"]:r[0]?i["throw"]||((a=i["return"])&&a.call(i),0):i.next)&&!(a=a.call(i,r[1])).done)return a;if(i=0,a)r=[r[0]&2,a.value];switch(r[0]){case 0:case 1:a=r;break;case 4:n.label++;return{value:r[1],done:false};case 5:n.label++;i=r[1];r=[0];continue;case 7:r=n.ops.pop();n.trys.pop();continue;default:if(!(a=n.trys,a=a.length>0&&a[a.length-1])&&(r[0]===6||r[0]===2)){n=0;continue}if(r[0]===3&&(!a||r[1]>a[0]&&r[1]<a[3])){n.label=r[1];break}if(r[0]===6&&n.label<a[1]){n.label=a[1];a=r;break}if(a&&n.label<a[2]){n.label=a[2];n.ops.push(r);break}if(a[2])n.ops.pop();n.trys.pop();continue}r=t.call(e,n)}catch(e){r=[6,e];i=0}finally{s=a=0}if(r[0]&5)throw r[1];return{value:r[0]?r[1]:void 0,done:true}}};System.register(["./p-59073837.system.js","@verdocs/js-sdk","./p-c8a15cb7.system.js","./p-2c5350ec.system.js"],(function(e){"use strict";var t,n,s,i,a,l,r,c,o,d,p;return{setters:[function(e){t=e.r;n=e.c;s=e.h;i=e.H},function(e){a=e.VerdocsEndpoint;l=e.getTemplates;r=e.deleteTemplate;c=e.integerSequence;o=e.canPerformTemplateAction},function(e){d=e.S},function(e){p=e.f}],execute:function(){var h='@-webkit-keyframes verdocs-field-pulse {\n 0% {\n background-color: rgba(0, 0, 0, 0.35);\n }\n 50% {\n background-color: rgba(0, 0, 0, 0);\n }\n 100% {\n background-color: rgba(0, 0, 0, 0.35);\n }\n}\n@keyframes verdocs-field-pulse {\n 0% {\n background-color: rgba(0, 0, 0, 0.35);\n }\n 50% {\n background-color: rgba(0, 0, 0, 0);\n }\n 100% {\n background-color: rgba(0, 0, 0, 0.35);\n }\n}\nverdocs-templates-list {\n display: -ms-flexbox;\n display: flex;\n padding: 10px;\n font-size: 18px;\n -ms-flex-wrap: nowrap;\n flex-wrap: nowrap;\n border-radius: 6px;\n color: #33364b;\n -ms-flex-direction: column;\n flex-direction: column;\n font-family: "Inter", "Barlow", sans-serif;\n}\nverdocs-templates-list .header {\n width: 100%;\n row-gap: 4px;\n display: -ms-flexbox;\n display: flex;\n -ms-flex-wrap: wrap;\n flex-wrap: wrap;\n -webkit-column-gap: 12px;\n -moz-column-gap: 12px;\n column-gap: 12px;\n margin: 0 0 10px 0;\n -ms-flex-align: center;\n align-items: center;\n -ms-flex-direction: row;\n flex-direction: row;\n}\nverdocs-templates-list .header .filter {\n width: 150px;\n}\nverdocs-templates-list .header verdocs-text-input {\n margin: 0;\n}\nverdocs-templates-list .header verdocs-text-input input {\n height: 32px;\n}\nverdocs-templates-list .filter {\n -ms-flex-align: center;\n align-items: center;\n}\nverdocs-templates-list .template-placeholder {\n height: 48px;\n -ms-flex: 0 0 48px;\n flex: 0 0 48px;\n margin: 5px 0;\n border-radius: 5px;\n background: #f5f5fa;\n}\nverdocs-templates-list .template {\n width: 100%;\n margin: 2px 0;\n border: 1px solid #ffffff;\n background: #ffffff;\n}\nverdocs-templates-list .template:hover {\n cursor: pointer;\n background: #ededff;\n border: 1px solid #a7a7f5;\n}\nverdocs-templates-list .template .inner {\n gap: 12px;\n display: -ms-flexbox;\n display: flex;\n padding: 8px 14px;\n border-radius: 5px;\n -ms-flex-direction: row;\n flex-direction: row;\n -ms-flex-align: center;\n align-items: center;\n container-type: inline-size;\n}\nverdocs-templates-list .template .inner svg {\n width: 24px;\n height: 24px;\n}\nverdocs-templates-list .name {\n -ms-flex: 1;\n flex: 1;\n display: -ms-flexbox;\n display: flex;\n color: black;\n font-size: 16px;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\n@media screen and (max-width: 1300px) {\n verdocs-templates-list .name {\n font-size: 16px;\n }\n}\nverdocs-templates-list .spacer {\n margin: 0;\n height: 30px;\n -ms-flex: 0 0 1px;\n flex: 0 0 1px;\n display: -ms-flexbox;\n display: flex;\n border-right: 1px solid #dad8dd;\n}\n@media screen and (max-width: 800px) {\n verdocs-templates-list .spacer {\n display: none;\n }\n}\nverdocs-templates-list .empty-text {\n font-size: 20px;\n text-align: center;\n margin: 16px 0 0 0;\n padding: 80px 80px;\n border: 2px solid #ccc;\n}\nverdocs-templates-list .usage,\nverdocs-templates-list .ownership,\nverdocs-templates-list .last-used {\n gap: 10px;\n color: #444;\n display: -ms-flexbox;\n display: flex;\n font-size: 16px;\n margin: 0 0 0 10px;\n -ms-flex-align: center;\n align-items: center;\n -ms-flex-direction: row;\n flex-direction: row;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\nverdocs-templates-list .usage span,\nverdocs-templates-list .usage svg,\nverdocs-templates-list .ownership span,\nverdocs-templates-list .ownership svg,\nverdocs-templates-list .last-used span,\nverdocs-templates-list .last-used svg {\n width: 24px;\n height: 24px;\n}\nverdocs-templates-list .usage span,\nverdocs-templates-list .ownership span,\nverdocs-templates-list .last-used span {\n display: block;\n}\n@media screen and (max-width: 700px) {\n verdocs-templates-list verdocs-template-star {\n display: none;\n }\n}\nverdocs-templates-list .ownership {\n -ms-flex: 0 0 100px;\n flex: 0 0 100px;\n}\n@media screen and (max-width: 700px) {\n verdocs-templates-list .ownership {\n display: none;\n }\n}\nverdocs-templates-list .last-used {\n -ms-flex: 0 0 130px;\n flex: 0 0 130px;\n}\nverdocs-templates-list .usage {\n -ms-flex: 0 0 60px;\n flex: 0 0 60px;\n}\nverdocs-templates-list .header-row {\n display: none;\n}\nverdocs-templates-list table {\n container-type: size;\n max-width: 100%;\n overflow: hidden;\n table-layout: fixed;\n}\nverdocs-templates-list .data-row {\n cursor: pointer;\n background: #ededff;\n border: 1px solid #a7a7f5;\n}\nverdocs-templates-list .data-col svg {\n width: 24px;\n height: 24px;\n}\nverdocs-templates-list .col-name {\n text-overflow: ellipsis;\n white-space: nowrap;\n overflow: hidden;\n}\n@container (max-width:700 px) {\n verdocs-templates-list verdocs-templates-list .col-starred {\n display: none;\n }\n}';var v=h;var u='<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" d="M12 21a9.004 9.004 0 008.716-6.747M12 21a9.004 9.004 0 01-8.716-6.747M12 21c2.485 0 4.5-4.03 4.5-9S14.485 3 12 3m0 18c-2.485 0-4.5-4.03-4.5-9S9.515 3 12 3m0 0a8.997 8.997 0 017.843 4.582M12 3a8.997 8.997 0 00-7.843 4.582m15.686 0A11.953 11.953 0 0112 10.5c-2.998 0-5.74-1.1-7.843-2.918m15.686 0A8.959 8.959 0 0121 12c0 .778-.099 1.533-.284 2.253m0 0A17.919 17.919 0 0112 16.5c-3.162 0-6.133-.815-8.716-2.247m0 0A9.015 9.015 0 013 12c0-1.605.42-3.113 1.157-4.418" /></svg>';var f='<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" d="M16.5 10.5V6.75a4.5 4.5 0 10-9 0v3.75m-.75 11.25h10.5a2.25 2.25 0 002.25-2.25v-6.75a2.25 2.25 0 00-2.25-2.25H6.75a2.25 2.25 0 00-2.25 2.25v6.75a2.25 2.25 0 002.25 2.25z" /></svg>';var m='<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" d="M3.75 21h16.5M4.5 3h15M5.25 3v18m13.5-18v18M9 6.75h1.5m-1.5 3h1.5m-1.5 3h1.5m3-6H15m-1.5 3H15m-1.5 3H15M9 21v-3.375c0-.621.504-1.125 1.125-1.125h3.75c.621 0 1.125.504 1.125 1.125V21" /></svg>';var x='<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" d="M21.75 6.75v10.5a2.25 2.25 0 01-2.25 2.25h-15a2.25 2.25 0 01-2.25-2.25V6.75m19.5 0A2.25 2.25 0 0019.5 4.5h-15a2.25 2.25 0 00-2.25 2.25m19.5 0v.243a2.25 2.25 0 01-1.07 1.916l-7.5 4.615a2.25 2.25 0 01-2.36 0L3.32 8.91a2.25 2.25 0 01-1.07-1.916V6.75" /></svg>';var b='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 122.88 122.88"><g><path d="M81.61,4.73c0-2.61,2.58-4.73,5.77-4.73c3.19,0,5.77,2.12,5.77,4.73v20.72c0,2.61-2.58,4.73-5.77,4.73 c-3.19,0-5.77-2.12-5.77-4.73V4.73L81.61,4.73z M66.11,103.81c-0.34,0-0.61-1.43-0.61-3.2c0-1.77,0.27-3.2,0.61-3.2H81.9 c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H66.11L66.11,103.81z M15.85,67.09c-0.34,0-0.61-1.43-0.61-3.2 c0-1.77,0.27-3.2,0.61-3.2h15.79c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H15.85L15.85,67.09z M40.98,67.09 c-0.34,0-0.61-1.43-0.61-3.2c0-1.77,0.27-3.2,0.61-3.2h15.79c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H40.98 L40.98,67.09z M66.11,67.09c-0.34,0-0.61-1.43-0.61-3.2c0-1.77,0.27-3.2,0.61-3.2H81.9c0.34,0,0.61,1.43,0.61,3.2 c0,1.77-0.27,3.2-0.61,3.2H66.11L66.11,67.09z M91.25,67.09c-0.34,0-0.61-1.43-0.61-3.2c0-1.77,0.27-3.2,0.61-3.2h15.79 c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H91.25L91.25,67.09z M15.85,85.45c-0.34,0-0.61-1.43-0.61-3.2 c0-1.77,0.27-3.2,0.61-3.2h15.79c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H15.85L15.85,85.45z M40.98,85.45 c-0.34,0-0.61-1.43-0.61-3.2c0-1.77,0.27-3.2,0.61-3.2h15.79c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H40.98 L40.98,85.45z M66.11,85.45c-0.34,0-0.61-1.43-0.61-3.2c0-1.77,0.27-3.2,0.61-3.2H81.9c0.34,0,0.61,1.43,0.61,3.2 c0,1.77-0.27,3.2-0.61,3.2H66.11L66.11,85.45z M91.25,85.45c-0.34,0-0.61-1.43-0.61-3.2c0-1.77,0.27-3.2,0.61-3.2h15.79 c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H91.25L91.25,85.45z M15.85,103.81c-0.34,0-0.61-1.43-0.61-3.2 c0-1.77,0.27-3.2,0.61-3.2h15.79c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H15.85L15.85,103.81z M40.98,103.81 c-0.34,0-0.61-1.43-0.61-3.2c0-1.77,0.27-3.2,0.61-3.2h15.79c0.34,0,0.61,1.43,0.61,3.2c0,1.77-0.27,3.2-0.61,3.2H40.98 L40.98,103.81z M29.61,4.73c0-2.61,2.58-4.73,5.77-4.73s5.77,2.12,5.77,4.73v20.72c0,2.61-2.58,4.73-5.77,4.73 s-5.77-2.12-5.77-4.73V4.73L29.61,4.73z M6.4,45.32h110.07V21.47c0-0.8-0.33-1.53-0.86-2.07c-0.53-0.53-1.26-0.86-2.07-0.86H103 c-1.77,0-3.2-1.43-3.2-3.2c0-1.77,1.43-3.2,3.2-3.2h10.55c2.57,0,4.9,1.05,6.59,2.74c1.69,1.69,2.74,4.02,2.74,6.59v27.06v65.03 c0,2.57-1.05,4.9-2.74,6.59c-1.69,1.69-4.02,2.74-6.59,2.74H9.33c-2.57,0-4.9-1.05-6.59-2.74C1.05,118.45,0,116.12,0,113.55V48.52 V21.47c0-2.57,1.05-4.9,2.74-6.59c1.69-1.69,4.02-2.74,6.59-2.74H20.6c1.77,0,3.2,1.43,3.2,3.2c0,1.77-1.43,3.2-3.2,3.2H9.33 c-0.8,0-1.53,0.33-2.07,0.86c-0.53,0.53-0.86,1.26-0.86,2.07V45.32L6.4,45.32z M116.48,51.73H6.4v61.82c0,0.8,0.33,1.53,0.86,2.07 c0.53,0.53,1.26,0.86,2.07,0.86h104.22c0.8,0,1.53-0.33,2.07-0.86c0.53-0.53,0.86-1.26,0.86-2.07V51.73L116.48,51.73z M50.43,18.54 c-1.77,0-3.2-1.43-3.2-3.2c0-1.77,1.43-3.2,3.2-3.2h21.49c1.77,0,3.2,1.43,3.2,3.2c0,1.77-1.43,3.2-3.2,3.2H50.43L50.43,18.54z"/></g></svg>';var g='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 410.2"><path d="M35.28 35.51h32.54v43.42c0 10.58 4.27 20.06 11.35 27.23 17.03 17.14 45.5 17.45 63.06.93 7.71-7.29 12.4-17.14 12.4-28.16V35.51h65.71v43.42c0 6.34 1.56 12.3 4.35 17.6 2.03 3.85 4.71 7.37 7.92 10.43l2.41 2.24c1.79 1.46 3.71 2.79 5.76 3.97l.31.18.07.04.25.13.16.1.15.08.27.14.05.03.32.17.05.03.27.13.15.08.17.09.26.12.07.04.32.16.03.01.31.15.12.06.2.09.24.11.1.05.33.14.34.16.1.04.23.1.21.09.13.05.31.13h.03l.34.14.08.04.27.1.18.07.16.06.3.11.05.02.34.12.06.02.3.11.16.05.19.07.26.09.09.03.35.12.02.01.34.1.13.04.22.07.25.07.11.03.36.11.36.1.11.03.25.07.22.06.14.04.34.09h.02l.37.1.08.02.29.06.19.05.17.03.32.08.05.01.37.08.06.01.31.06.17.04.21.03.28.06.09.02.37.07h.03l.35.06.14.03.23.03.27.04.11.02.38.06.38.05.12.01.26.04.23.03.15.01.35.05h.03l.39.04.08.01.3.02.21.02.17.02.34.02.05.01.39.03h.05l.34.02.18.01.21.01.3.02h.08l.39.01.03.01.36.01h.39l.28.01h.96l.33-.01h.39l.18-.01.2-.01.25-.01h.13l.32-.02h.07l.38-.02h.01l.37-.02.07-.01.32-.02.12-.01.26-.02.19-.02.19-.02.25-.02.13-.01.31-.04h.07l.37-.05h.01l.37-.04.06-.01.32-.04.12-.02.26-.03.18-.03.19-.03.24-.04.14-.02.3-.05.07-.01.36-.06h.01l.37-.07.05-.01.32-.06.12-.02.25-.05.18-.04.19-.04.23-.05.14-.03.29-.07.08-.01.35-.08.01-.01.36-.08.05-.02.31-.08.11-.02.25-.07.17-.04.2-.06.22-.05.14-.05.28-.08.07-.02.34-.09.02-.01.36-.11.03-.01.32-.1.1-.03.25-.08.16-.05.19-.07.22-.07.13-.04.28-.1.08-.03.32-.11.02-.01.35-.13.04-.01.3-.11.09-.04.26-.1.15-.06.19-.07.21-.09.13-.05.26-.11.08-.03.32-.13.02-.01.33-.14.04-.02.3-.13.09-.04.24-.11.14-.07.19-.08.19-.1.14-.06.25-.12.08-.03.3-.16h.03l.32-.17.03-.01.29-.16.09-.04.24-.12.13-.07.19-.1.18-.1.14-.07.23-.13.08-.05.29-.16.03-.01.31-.18c1.11-.64 2.17-1.31 3.2-2.03l2.71-1.95c4.36-3.56 7.92-7.88 10.43-12.76 2.73-5.26 4.25-11.19 4.25-17.5V35.51h33.97c9.68 0 18.5 3.98 24.91 10.38 6.4 6.37 10.38 15.2 10.38 24.9V192.9H365.1v-53.83H11.3v233.49c0 15.25 12.49 27.74 27.75 27.74h298.3c15.27 0 27.75-12.51 27.75-27.74V325.6h11.31v49.32c0 9.7-3.98 18.53-10.37 24.91-6.42 6.39-15.24 10.37-24.92 10.37H35.28c-9.68 0-18.49-3.97-24.89-10.37C3.97 393.41 0 384.59 0 374.92V70.79C0 61.12 3.97 52.3 10.36 45.9c6.43-6.42 15.25-10.39 24.92-10.39zm211.43-21.54c0-7.71 7.61-13.97 17.03-13.97 9.42 0 17.04 6.26 17.04 13.97v64.96c0 7.7-7.62 13.96-17.04 13.96-9.42 0-17.03-6.26-17.03-13.96V13.97zm-152.52 0C94.19 6.26 101.81 0 111.23 0c9.42 0 17.03 6.26 17.03 13.97v64.96c0 7.7-7.61 13.96-17.03 13.96-9.42 0-17.04-6.26-17.04-13.96V13.97zm311.37 327.72c1.48-14.79 2.69-32.45 3.59-46.5h-75.88v-71.88h77.43c-.39-14.06-1.17-31.75-2.35-46.58-.96-5.93 6.02-9.73 10.51-5.9l90.89 82.99c2.7 2.31 3.02 6.38.7 9.08l-.74.73-93.65 84.05c-4.6 3.89-11.47-.19-10.5-5.99zM63.51 286h50.56c3.53 0 6.43 2.91 6.43 6.44v42.06c0 3.52-2.91 6.44-6.43 6.44H63.51c-3.53 0-6.44-2.91-6.44-6.44v-42.06c0-3.54 2.9-6.44 6.44-6.44zm198.44-98.62h50.55c3.23 0 5.92 2.43 6.37 5.52h-16v49.42h-40.92c-3.53 0-6.45-2.9-6.45-6.45v-42.05c0-3.54 2.9-6.44 6.45-6.44zm0 98.62h40.92v39.6h16.07v8.9c0 3.52-2.92 6.44-6.44 6.44h-50.55c-3.53 0-6.45-2.91-6.45-6.44v-42.06c0-3.54 2.9-6.44 6.45-6.44zm-98.5-98.62h50.56c3.53 0 6.43 2.92 6.43 6.44v42.05c0 3.53-2.91 6.45-6.43 6.45h-50.56c-3.53 0-6.44-2.9-6.44-6.45v-42.05c0-3.54 2.9-6.44 6.44-6.44zm-99.94 0h50.56c3.53 0 6.43 2.92 6.43 6.44v42.05c0 3.53-2.91 6.45-6.43 6.45H63.51c-3.53 0-6.44-2.9-6.44-6.45v-42.05c0-3.54 2.9-6.44 6.44-6.44zM163.45 286h50.56c3.53 0 6.43 2.91 6.43 6.44v42.06c0 3.52-2.91 6.44-6.43 6.44h-50.56c-3.53 0-6.44-2.91-6.44-6.44v-42.06c0-3.54 2.9-6.44 6.44-6.44z"/></svg>';var w='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 506.49"><path fill-rule="nonzero" d="m371.06 415.61-43.25 11.52 6.23-46.41 37.02 34.89zm6.76-177.5c36.98 0 70.56 15.04 94.83 39.35C496.96 301.7 512 335.25 512 372.31c0 37.02-15.02 70.61-39.3 94.88l-.68.64c-24.23 23.88-57.5 38.66-94.2 38.66-37.06 0-70.61-15.04-94.88-39.31l-.64-.69c-23.9-24.24-38.68-57.53-38.68-94.18 0-37.06 15.04-70.61 39.32-94.89 24.27-24.27 57.85-39.31 94.88-39.31zm78.74 55.41c-20.09-20.11-47.96-32.58-78.74-32.58-30.75 0-58.61 12.47-78.75 32.62-20.15 20.14-32.62 48-32.62 78.75 0 30.5 12.25 58.14 32.02 78.19l.6.55c20.14 20.14 48 32.61 78.75 32.61 30.48 0 58.12-12.25 78.21-32.02l.54-.58c20.15-20.15 32.61-48 32.61-78.75s-12.48-58.61-32.62-78.79zM294.24 17.11C294.24 7.69 303.52 0 315.1 0c11.57 0 20.87 7.64 20.87 17.11v74.85c0 9.42-9.3 17.11-20.87 17.11-11.58 0-20.86-7.65-20.86-17.11V17.11zM56.8 242.28c-1.17 0-2.23-5.2-2.23-11.57 0-6.38.92-11.53 2.23-11.53h56.94c1.18 0 2.24 5.2 2.24 11.53 0 6.39-.92 11.57-2.24 11.57H56.8zm90.77 0c-1.17 0-2.23-5.2-2.23-11.57 0-6.38.92-11.53 2.23-11.53h56.94c1.18 0 2.24 5.2 2.24 11.53 0 6.39-.92 11.57-2.24 11.57h-56.94zm90.77 0c-1.16 0-2.22-5.2-2.22-11.57 0-6.38.92-11.53 2.22-11.53h56.94c1.19 0 2.25 5.15 2.25 11.49-5.7 3.55-11.2 7.44-16.43 11.61h-42.76zm-181.4 66.24c-1.18 0-2.24-5.2-2.24-11.57 0-6.38.93-11.58 2.24-11.58h56.94c1.18 0 2.22 5.2 2.22 11.58 0 6.37-.91 11.57-2.22 11.57H56.94zm90.77 0c-1.18 0-2.24-5.2-2.24-11.57 0-6.38.93-11.58 2.24-11.58h56.94c1.18 0 2.23 5.2 2.23 11.58 0 6.37-.92 11.57-2.23 11.57h-56.94zM57.06 374.8c-1.18 0-2.24-5.2-2.24-11.59 0-6.36.94-11.56 2.24-11.56H114c1.19 0 2.24 5.2 2.24 11.56 0 6.39-.93 11.59-2.24 11.59H57.06zm90.78 0c-1.19 0-2.25-5.2-2.25-11.59 0-6.36.94-11.56 2.25-11.56h56.94c1.18 0 2.24 5.2 2.24 11.56 0 6.39-.94 11.59-2.24 11.59h-56.94zM106.83 17.11C106.83 7.69 116.1 0 127.69 0c11.57 0 20.86 7.64 20.86 17.11v74.85c0 9.42-9.34 17.11-20.86 17.11-11.59 0-20.86-7.65-20.86-17.11V17.11zM22.97 163.64h397.39V77.46c0-2.94-1.19-5.53-3.09-7.43-1.9-1.9-4.59-3.08-7.42-3.08h-38.1c-6.39 0-11.59-5.2-11.59-11.57 0-6.38 5.2-11.58 11.59-11.58h38.1c9.32 0 17.7 3.77 23.82 9.88 6.12 6.14 9.88 14.5 9.88 23.83v136.81c-7.61-2.62-15.41-4.73-23.44-6.29v-21.38h.25H22.97v223.17c0 2.94 1.18 5.52 3.08 7.42 1.91 1.9 4.61 3.08 7.44 3.08h188.85c2.16 8.02 4.86 15.84 8.11 23.36H33.71c-9.3 0-17.7-3.75-23.84-9.89C3.75 427.72 0 419.36 0 410.02V77.55c0-9.29 3.75-17.7 9.87-23.82 6.14-6.13 14.5-9.89 23.84-9.89h40.67c6.38 0 11.57 5.2 11.57 11.57C85.95 61.8 80.76 67 74.38 67H33.71c-2.96 0-5.54 1.18-7.44 3.08-1.9 1.9-3.09 4.59-3.09 7.43v86.16h-.21v-.03zm158.95-96.69c-6.39 0-11.57-5.2-11.57-11.57 0-6.38 5.18-11.58 11.57-11.58h77.55c6.39 0 11.57 5.2 11.57 11.58 0 6.37-5.18 11.57-11.57 11.57h-77.55zm161.66 303.24 45.37-51.33c.72-.84 1.78-1.34 2.85-1.36.69-.01 1.37.13 1.98.45l32.94 29.96c.66.59 1.05 1.46 1.06 2.35.02 1-.39 1.98-1.16 2.66l-46.15 52.16-36.95-34.89h.06z"/></svg>';var y=[{value:"private_shared",label:"Personal + Shared"},{value:"private",label:"Personal"},{value:"shared",label:"Shared"},{value:"public",label:"Public"}];var k=[{value:"all",label:"All"},{value:"starred",label:"Starred"},{value:"unstarred",label:"Not Starred"}];var z=[{value:"name",label:"Name"},{value:"created_at",label:"Created"},{value:"updated_at",label:"Last Updated"},{value:"last_used_at",label:"Last Used"},{value:"counter",label:"Most Used"},{value:"star_counter",label:"Most Starred"}];var M=e("verdocs_templates_list",function(){function e(e){var s=this;t(this,e);this.sdkError=n(this,"sdkError",7);this.viewTemplate=n(this,"viewTemplate",7);this.signNow=n(this,"signNow",7);this.submittedData=n(this,"submittedData",7);this.editTemplate=n(this,"editTemplate",7);this.templateDeleted=n(this,"templateDeleted",7);this.changeSort=n(this,"changeSort",7);this.changeVisibility=n(this,"changeVisibility",7);this.changeStarred=n(this,"changeStarred",7);this.changeName=n(this,"changeName",7);this.handleOptionSelected=function(e,t){var n,i,a,l;if(e==="send"){(n=s.viewTemplate)===null||n===void 0?void 0:n.emit({endpoint:s.endpoint,template:t})}else if(e==="signnow"){(i=s.signNow)===null||i===void 0?void 0:i.emit({endpoint:s.endpoint,template:t})}else if(e==="submitted"){(a=s.submittedData)===null||a===void 0?void 0:a.emit({endpoint:s.endpoint,template:t})}else if(e==="edit"){(l=s.editTemplate)===null||l===void 0?void 0:l.emit({endpoint:s.endpoint,template:t})}else if(e==="delete"){s.confirmDelete=t}};this.endpoint=a.getDefault();this.visibility="private_shared";this.starred="all";this.sort="updated_at";this.name="";this.allowedActions=["send","submitted","link","edit","delete"];this.showPagination=true;this.rowsPerPage=10;this.selectedPage=0;this.count=0;this.initiallyLoaded=false;this.loading=true;this.confirmDelete=null;this.templates=[];this.localNameFilter=""}e.prototype.handleSharingUpdated=function(){return this.queryTemplates()};e.prototype.handleStarredUpdated=function(){return this.queryTemplates()};e.prototype.handleSortUpdated=function(){return this.queryTemplates()};e.prototype.handleNameUpdated=function(){return this.queryTemplates()};e.prototype.handlePageUpdated=function(){return this.queryTemplates()};e.prototype.componentWillLoad=function(){this.endpoint.loadSession();if(!this.endpoint.session){console.log("[TEMPLATES] Must be authenticated");return}};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.queryTemplates()];case 1:e.sent();this.initiallyLoaded=true;return[2]}}))}))};e.prototype.queryTemplates=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,n,s,i,a;return __generator(this,(function(r){switch(r.label){case 0:console.log("[TEMPLATES] Querying templates");this.loading=true;r.label=1;case 1:r.trys.push([1,3,,4]);s={visibility:this.visibility,page:this.selectedPage,rows:this.rowsPerPage};if(this.name.trim()!==""){s.q=this.name.trim()}return[4,l(this.endpoint,s)];case 2:i=r.sent();this.templates=i.templates;this.count=i.count;this.loading=false;return[3,4];case 3:a=r.sent();this.loading=false;console.log("[TEMPLATES] Error listing templates",a);(e=this.sdkError)===null||e===void 0?void 0:e.emit(new d(a.message,(t=a.response)===null||t===void 0?void 0:t.status,(n=a.response)===null||n===void 0?void 0:n.data));return[3,4];case 4:return[2]}}))}))};e.prototype.deleteTemplate=function(e){var t=this;this.confirmDelete=null;r(this.endpoint,e.id).then((function(){var n;console.log("[TEMPLATES] Deleted template",e);(n=t.templateDeleted)===null||n===void 0?void 0:n.emit({endpoint:t.endpoint,template:e});return t.queryTemplates()})).catch((function(n){var s,i,a;console.log("[TEMPLATES] Error deleting template",e);(s=t.sdkError)===null||s===void 0?void 0:s.emit(new d(n.message,(i=n.response)===null||i===void 0?void 0:i.status,(a=n.response)===null||a===void 0?void 0:a.data))}))};e.prototype.render=function(){var e=this;var t=!this.localNameFilter?this.templates:this.templates.filter((function(t){return t.name.toLowerCase().includes(e.localNameFilter.toLowerCase())}));return s(i,{key:"df2f80ba1899611e07046635844fd1e4a2bd801f"},s("div",{key:"0560522cb614307dfe4c6125faf9c183e510adc8",class:"header"},s("div",{key:"d0490c7d5a610b8b780762dfbc5a141c0799b7d7",class:"filter"},s("verdocs-text-input",{key:"44b9c9e7429b377b0ed52b9404b6f3d61af8efb0",id:"verdocs-filter-name",value:this.name,clearable:true,autocomplete:"off",placeholder:"Filter by Name...",onInput:function(t){return e.localNameFilter=t.target.value.trim()},onFocusout:function(t){var n;e.name=t.target.value.trim();e.localNameFilter=t.target.value.trim();(n=e.changeName)===null||n===void 0?void 0:n.emit(e.name)}})),s("verdocs-quick-filter",{key:"72bebecb5ae71d1668df2c095fedba131794a1da",label:"Visibility",value:this.visibility,options:y,onOptionSelected:function(t){var n;e.visibility=t.detail.value;(n=e.changeVisibility)===null||n===void 0?void 0:n.emit(e.visibility)}}),s("verdocs-quick-filter",{key:"79af88bb274bdfe78799ecbd8df43823d3e87eb1",label:"Starred",value:this.starred,options:k,onOptionSelected:function(t){var n;e.starred=t.detail.value;(n=e.changeStarred)===null||n===void 0?void 0:n.emit(e.starred)}}),s("verdocs-quick-filter",{key:"107623692057664e0b42892cab4256df8e274f1f",label:"Sort By",value:this.sort,options:z,onOptionSelected:function(t){var n;e.sort=t.detail.value;(n=e.changeSort)===null||n===void 0?void 0:n.emit(e.sort)}}),this.loading&&s("verdocs-spinner",{key:"1982cc9021bf92da53e2b4a6dc0814039a9fa70a",mode:"dark",size:24}),s("div",{key:"581288dea09d793a050c192fc472041138b205dc",style:{display:"flex",flex:"1"}})),t.map((function(t){var n=e.sort==="created_at"?"created_at":e.sort==="updated_at"?"updated_at":"last_used_at";var i=t[n];var a=[];var l=[];if(e.allowedActions.includes("send")){a.push({label:"Preview / Send",id:"send",disabled:!o(e.endpoint.profile,"read",t)})}if(e.allowedActions.includes("signnow")){a.push({label:"Sign Now",id:"signnow",disabled:true})}if(e.allowedActions.includes("submitted")){a.push({label:""});a.push({label:"Submissions",id:"submitted",disabled:!o(e.endpoint.profile,"read",t)})}if(e.allowedActions.includes("link")||e.allowedActions.includes("edit")||e.allowedActions.includes("delete")){a.push({label:""});if(e.allowedActions.includes("link")||e.allowedActions.includes("edit")||e.allowedActions.includes("delete")){a.push({label:"Edit",id:"edit",disabled:!l.includes("write")})}if(e.allowedActions.includes("link")||e.allowedActions.includes("edit")||e.allowedActions.includes("delete")){a.push({label:"Delete",id:"delete",disabled:!l.includes("delete")})}}return s("div",{class:"template",onClick:function(){var n;(n=e.viewTemplate)===null||n===void 0?void 0:n.emit({endpoint:e.endpoint,template:t})}},s("div",{class:"inner"},s("verdocs-template-star",{template:t,endpoint:e.endpoint}),s("div",{class:"spacer icon-spacer"}),s("div",{class:"name"},t.name),s("div",{class:"spacer usage-spacer"}),s("div",{class:"usage"},s("span",{innerHTML:x,title:"Usage Counter"}),t.counter||"--"),s("div",{class:"spacer last-used-spacer"}),s("div",{class:"last-used"},n==="created_at"&&s("span",{innerHTML:b,title:"Created"}),n==="updated_at"&&s("span",{innerHTML:w,title:"Last Updated"}),n==="last_used_at"&&s("span",{innerHTML:g,title:"Last Used"}),i?p(new Date(i),"P"):"Never"),s("div",{class:"spacer ownership-spacer"}),t.is_public&&s("div",{class:"ownership"},s("span",{innerHTML:u})," Public"),!t.is_public&&!t.is_personal&&s("div",{class:"ownership"},s("span",{innerHTML:f})," Private"),!t.is_public&&t.is_personal&&s("div",{class:"ownership"},s("span",{innerHTML:m})," Shared"),s("verdocs-dropdown",{options:a,onOptionSelected:function(n){return e.handleOptionSelected(n.detail.id,t)}})))})),!this.initiallyLoaded&&s("div",{key:"02ce593d239cb477eedbfc172e33e3e9f3e9c27e"},c(0,this.rowsPerPage).map((function(){return s("div",{class:"template-placeholder"})}))),this.initiallyLoaded&&!this.templates.length&&s("div",{key:"b77da1610613c37b725466e1d1613ab8ad625df0",class:"empty-text"},"No matching templates found. Please adjust your filters and try again."),this.initiallyLoaded&&this.templates.length&&this.showPagination?s("div",{style:{marginTop:"20px"}},s("verdocs-pagination",{selectedPage:this.selectedPage,perPage:this.rowsPerPage,itemCount:this.count,onSelectPage:function(t){e.selectedPage=t.detail.selectedPage}})):s("div",null),this.confirmDelete&&s("verdocs-ok-dialog",{key:"b90a1e4a606e46659065a0de6c492213b0e31260",heading:"Delete this Template?",message:"This operation cannot be undone.",onNext:function(){return e.deleteTemplate(e.confirmDelete)},onExit:function(){return e.confirmDelete=null},showCancel:true}))};Object.defineProperty(e,"watchers",{get:function(){return{sharing:["handleSharingUpdated"],starred:["handleStarredUpdated"],sort:["handleSortUpdated"],name:["handleNameUpdated"],selectedPage:["handlePageUpdated"]}},enumerable:false,configurable:true});return e}());M.style=v}}}));
@@ -1 +1 @@
1
- var __awaiter=this&&this.__awaiter||function(e,t,n,i){function r(e){return e instanceof n?e:new n((function(t){t(e)}))}return new(n||(n=Promise))((function(n,o){function s(e){try{a(i.next(e))}catch(e){o(e)}}function l(e){try{a(i["throw"](e))}catch(e){o(e)}}function a(e){e.done?n(e.value):r(e.value).then(s,l)}a((i=i.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var n={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},i,r,o,s;return s={next:l(0),throw:l(1),return:l(2)},typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function l(e){return function(t){return a([e,t])}}function a(l){if(i)throw new TypeError("Generator is already executing.");while(s&&(s=0,l[0]&&(n=0)),n)try{if(i=1,r&&(o=l[0]&2?r["return"]:l[0]?r["throw"]||((o=r["return"])&&o.call(r),0):r.next)&&!(o=o.call(r,l[1])).done)return o;if(r=0,o)l=[l[0]&2,o.value];switch(l[0]){case 0:case 1:o=l;break;case 4:n.label++;return{value:l[1],done:false};case 5:n.label++;r=l[1];l=[0];continue;case 7:l=n.ops.pop();n.trys.pop();continue;default:if(!(o=n.trys,o=o.length>0&&o[o.length-1])&&(l[0]===6||l[0]===2)){n=0;continue}if(l[0]===3&&(!o||l[1]>o[0]&&l[1]<o[3])){n.label=l[1];break}if(l[0]===6&&n.label<o[1]){n.label=o[1];o=l;break}if(o&&n.label<o[2]){n.label=o[2];n.ops.push(l);break}if(o[2])n.ops.pop();n.trys.pop();continue}l=t.call(e,n)}catch(e){l=[6,e];r=0}finally{i=o=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:true}}};System.register(["./p-59073837.system.js","@verdocs/js-sdk","./p-1a663adf.system.js","./p-c8a15cb7.system.js","./p-38778553.system.js","./p-701b9cbd.system.js","./p-38c6897c.system.js","./p-f5064e0c.system.js"],(function(e){"use strict";var t,n,i,r,o,s,l,a;return{setters:[function(e){t=e.r;n=e.c;i=e.h;r=e.H;o=e.g},function(e){s=e.VerdocsEndpoint},function(e){l=e.g},function(e){a=e.S},function(){},function(){},function(){},function(){}],execute:function(){var d='@-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-build{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif}verdocs-build .content{-ms-flex:1;flex:1;gap:20px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column}verdocs-build verdocs-template-attachments,verdocs-build verdocs-template-roles{margin:20px}verdocs-build verdocs-template-fields{border-top:1px solid #777777}verdocs-build verdocs-template-attachments{padding:20px;background:#ffffff}verdocs-build verdocs-template-fields{width:100%}verdocs-build verdocs-preview{-ms-flex:1;flex:1}verdocs-build .preview-container{-ms-flex-direction:row;flex-direction:row;display:-ms-flexbox;display:flex;width:100%;background-color:#eeeeee;max-height:100%}@media all and (max-width: 450px){verdocs-build .preview-container{-ms-flex-direction:column;flex-direction:column}}verdocs-build .preview-send-wrapper{display:-ms-flexbox;display:flex;-ms-flex:0 0 300px;flex:0 0 300px;background-color:#ffffff;-webkit-box-shadow:1px 1px 6px -2px rgba(0, 0, 0, 0.4980392157);box-shadow:1px 1px 6px -2px rgba(0, 0, 0, 0.4980392157)}@media all and (max-width: 450px){verdocs-build .preview-send-wrapper{-ms-flex:0;flex:0}}verdocs-build .preview-preview-wrapper{display:-ms-flexbox;display:flex;-ms-flex:1;flex:1;-ms-flex-pack:center;justify-content:center;overflow-y:scroll}';var c=d;var u=e("verdocs_build",function(){function e(e){t(this,e);this.sdkError=n(this,"sdkError",7);this.stepChanged=n(this,"stepChanged",7);this.send=n(this,"send",7);this.templateUpdated=n(this,"templateUpdated",7);this.templateCreated=n(this,"templateCreated",7);this.rolesUpdated=n(this,"rolesUpdated",7);this.endpoint=s.getDefault();this.templateId=null;this.step="preview";this.templateStore=null}e.prototype.onTemplateIdChanged=function(e,t){if(!t&&e&&this.step==="attachments"){this.step="preview"}this.loadTemplate(e).catch((function(e){return console.log("Unknown Error",e)}))};e.prototype.onStepChanged=function(){this.loadTemplate(this.templateId).catch((function(e){return console.log("Unknown Error",e)}))};e.prototype.componentWillLoad=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,n,i,r,o;return __generator(this,(function(s){try{this.endpoint.loadSession();if(!this.endpoint.session){console.log("[BUILD] Unable to start builder session, must be authenticated");return[2]}if(!this.templateId){console.log("[BUILD] No template ID, activating upload mode");this.step="attachments";return[2]}try{this.loadTemplate(this.templateId).catch((function(e){return console.log("[BUILD] Unable to load template",e)}))}catch(i){console.log("[BUILD] Error loading template",i);(e=this.sdkError)===null||e===void 0?void 0:e.emit(new a(i.message,(t=i.response)===null||t===void 0?void 0:t.status,(n=i.response)===null||n===void 0?void 0:n.data))}}catch(e){console.log("[BUILD] Error with builder session",e);(i=this.sdkError)===null||i===void 0?void 0:i.emit(new a(e.message,(r=e.response)===null||r===void 0?void 0:r.status,(o=e.response)===null||o===void 0?void 0:o.data))}return[2]}))}))};e.prototype.loadTemplate=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(n){switch(n.label){case 0:if(!e)return[3,2];t=this;return[4,l(this.endpoint,e,false)];case 1:t.templateStore=n.sent();n.label=2;case 2:return[2]}}))}))};e.prototype.handleCancel=function(){this.step="preview"};e.prototype.handleTemplateCreated=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(n){switch(n.label){case 0:return[4,this.loadTemplate(e)];case 1:n.sent();this.templateId=e;this.step="roles";(t=this.stepChanged)===null||t===void 0?void 0:t.emit("roles");return[2]}}))}))};e.prototype.handleRolesUpdated=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(n){(t=this.templateUpdated)===null||t===void 0?void 0:t.emit(e.detail);return[2]}))}))};e.prototype.handleTemplateUpdated=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(n){(t=this.templateUpdated)===null||t===void 0?void 0:t.emit(e.detail);return[2]}))}))};e.prototype.handleAttachmentsNext=function(){var e;this.step="roles";(e=this.stepChanged)===null||e===void 0?void 0:e.emit("roles")};e.prototype.handleRolesNext=function(){var e;this.step="fields";(e=this.stepChanged)===null||e===void 0?void 0:e.emit("fields")};e.prototype.handleStepChanged=function(e){var t;this.step=e;(t=this.stepChanged)===null||t===void 0?void 0:t.emit(e)};e.prototype.render=function(){var e=this;if(!this.endpoint.session){return i(r,null,i("verdocs-component-error",{message:"You must be authenticated to use this module."}))}if(!this.templateStore){console.log("[BUILD] No template ID, rendering created view");return i(r,null,i("div",{class:"content"},i("verdocs-template-build-tabs",{endpoint:this.endpoint,templateId:this.templateId,step:"attachments",onSdkError:function(t){var n;return(n=e.sdkError)===null||n===void 0?void 0:n.emit(t.detail)},onStepChanged:function(t){return e.handleStepChanged(t.detail)}}),i("verdocs-template-create",{endpoint:this.endpoint,onExit:function(){return e.handleCancel()},onNext:function(){return e.handleAttachmentsNext()},onTemplateCreated:function(t){return e.handleTemplateCreated(t.detail.templateId)}})))}console.log("[BUILD] Rendering build view",this.templateId,this.step,["attachments","roles","settings","fields","preview"].indexOf(this.step));return i(r,null,i("div",{class:"content"},i("verdocs-template-build-tabs",{endpoint:this.endpoint,templateId:this.templateId,step:this.step,onSdkError:function(t){var n;return(n=e.sdkError)===null||n===void 0?void 0:n.emit(t.detail)},onStepChanged:function(t){return e.handleStepChanged(t.detail)}}),this.step==="attachments"&&i("verdocs-template-attachments",{templateId:this.templateId,endpoint:this.endpoint,onExit:function(){return e.handleCancel()},onNext:function(){return e.handleAttachmentsNext()},onTemplateUpdated:function(t){return e.handleTemplateUpdated(t)}}),this.step==="roles"&&i("verdocs-template-roles",{templateId:this.templateId,endpoint:this.endpoint,onExit:function(){return e.handleCancel()},onNext:function(){return e.handleRolesNext()},onRolesUpdated:function(t){return e.handleRolesUpdated(t)}}),this.step==="settings"&&i("div",{style:{flexDirection:"column",gap:"20px",display:"flex",maxWidth:"400px",margin:"20px"}},i("verdocs-template-name",{templateId:this.templateId,endpoint:this.endpoint,style:{backgroundColor:"#ffffff",padding:"20px"},onTemplateUpdated:function(t){return e.handleTemplateUpdated(t)}}),i("verdocs-template-reminders",{templateId:this.templateId,endpoint:this.endpoint,style:{backgroundColor:"#ffffff",padding:"20px"},onTemplateUpdated:function(t){return e.handleTemplateUpdated(t)}}),i("verdocs-template-visibility",{templateId:this.templateId,endpoint:this.endpoint,style:{backgroundColor:"#ffffff",padding:"20px"},onTemplateUpdated:function(t){return e.handleTemplateUpdated(t)}})),this.step==="fields"&&i("verdocs-template-fields",{templateId:this.templateId,endpoint:this.endpoint,onTemplateUpdated:function(t){return e.handleTemplateUpdated(t)}}),this.step==="preview"&&i("div",{class:"preview-container"},i("div",{class:"preview-send-wrapper"},i("verdocs-send",{templateId:this.templateId,endpoint:this.endpoint,onSend:function(t){var n;return(n=e.send)===null||n===void 0?void 0:n.emit(t.detail)},style:{width:"100%"}})),i("div",{class:"preview-preview-wrapper"},i("verdocs-preview",{templateId:this.templateId,endpoint:this.endpoint,style:{display:"flex",flex:"1",maxWidth:"1000px"}})))))};Object.defineProperty(e.prototype,"el",{get:function(){return o(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{templateId:["onTemplateIdChanged"],step:["onStepChanged"]}},enumerable:false,configurable:true});return e}());u.style=c}}}));
1
+ var __awaiter=this&&this.__awaiter||function(e,t,n,i){function r(e){return e instanceof n?e:new n((function(t){t(e)}))}return new(n||(n=Promise))((function(n,o){function s(e){try{a(i.next(e))}catch(e){o(e)}}function l(e){try{a(i["throw"](e))}catch(e){o(e)}}function a(e){e.done?n(e.value):r(e.value).then(s,l)}a((i=i.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var n={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},i,r,o,s;return s={next:l(0),throw:l(1),return:l(2)},typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function l(e){return function(t){return a([e,t])}}function a(l){if(i)throw new TypeError("Generator is already executing.");while(s&&(s=0,l[0]&&(n=0)),n)try{if(i=1,r&&(o=l[0]&2?r["return"]:l[0]?r["throw"]||((o=r["return"])&&o.call(r),0):r.next)&&!(o=o.call(r,l[1])).done)return o;if(r=0,o)l=[l[0]&2,o.value];switch(l[0]){case 0:case 1:o=l;break;case 4:n.label++;return{value:l[1],done:false};case 5:n.label++;r=l[1];l=[0];continue;case 7:l=n.ops.pop();n.trys.pop();continue;default:if(!(o=n.trys,o=o.length>0&&o[o.length-1])&&(l[0]===6||l[0]===2)){n=0;continue}if(l[0]===3&&(!o||l[1]>o[0]&&l[1]<o[3])){n.label=l[1];break}if(l[0]===6&&n.label<o[1]){n.label=o[1];o=l;break}if(o&&n.label<o[2]){n.label=o[2];n.ops.push(l);break}if(o[2])n.ops.pop();n.trys.pop();continue}l=t.call(e,n)}catch(e){l=[6,e];r=0}finally{i=o=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:true}}};System.register(["./p-59073837.system.js","@verdocs/js-sdk","./p-a9e0ae2c.system.js","./p-c8a15cb7.system.js","./p-38778553.system.js","./p-701b9cbd.system.js","./p-38c6897c.system.js","./p-f5064e0c.system.js"],(function(e){"use strict";var t,n,i,r,o,s,l,a;return{setters:[function(e){t=e.r;n=e.c;i=e.h;r=e.H;o=e.g},function(e){s=e.VerdocsEndpoint},function(e){l=e.g},function(e){a=e.S},function(){},function(){},function(){},function(){}],execute:function(){var d='@-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-build{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif}verdocs-build .content{-ms-flex:1;flex:1;gap:20px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column}verdocs-build verdocs-template-attachments,verdocs-build verdocs-template-roles{margin:20px}verdocs-build verdocs-template-fields{border-top:1px solid #777777}verdocs-build verdocs-template-attachments{padding:20px;background:#ffffff}verdocs-build verdocs-template-fields{width:100%}verdocs-build verdocs-preview{-ms-flex:1;flex:1}verdocs-build .preview-container{-ms-flex-direction:row;flex-direction:row;display:-ms-flexbox;display:flex;width:100%;background-color:#eeeeee;max-height:100%}@media all and (max-width: 450px){verdocs-build .preview-container{-ms-flex-direction:column;flex-direction:column}}verdocs-build .preview-send-wrapper{display:-ms-flexbox;display:flex;-ms-flex:0 0 300px;flex:0 0 300px;background-color:#ffffff;-webkit-box-shadow:1px 1px 6px -2px rgba(0, 0, 0, 0.4980392157);box-shadow:1px 1px 6px -2px rgba(0, 0, 0, 0.4980392157)}@media all and (max-width: 450px){verdocs-build .preview-send-wrapper{-ms-flex:0;flex:0}}verdocs-build .preview-preview-wrapper{display:-ms-flexbox;display:flex;-ms-flex:1;flex:1;-ms-flex-pack:center;justify-content:center;overflow-y:scroll}';var c=d;var u=e("verdocs_build",function(){function e(e){t(this,e);this.sdkError=n(this,"sdkError",7);this.stepChanged=n(this,"stepChanged",7);this.send=n(this,"send",7);this.templateUpdated=n(this,"templateUpdated",7);this.templateCreated=n(this,"templateCreated",7);this.rolesUpdated=n(this,"rolesUpdated",7);this.endpoint=s.getDefault();this.templateId=null;this.step="preview";this.templateStore=null}e.prototype.onTemplateIdChanged=function(e,t){if(!t&&e&&this.step==="attachments"){this.step="preview"}this.loadTemplate(e).catch((function(e){return console.log("Unknown Error",e)}))};e.prototype.onStepChanged=function(){this.loadTemplate(this.templateId).catch((function(e){return console.log("Unknown Error",e)}))};e.prototype.componentWillLoad=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,n,i,r,o;return __generator(this,(function(s){try{this.endpoint.loadSession();if(!this.endpoint.session){console.log("[BUILD] Unable to start builder session, must be authenticated");return[2]}if(!this.templateId){console.log("[BUILD] No template ID, activating upload mode");this.step="attachments";return[2]}try{this.loadTemplate(this.templateId).catch((function(e){return console.log("[BUILD] Unable to load template",e)}))}catch(i){console.log("[BUILD] Error loading template",i);(e=this.sdkError)===null||e===void 0?void 0:e.emit(new a(i.message,(t=i.response)===null||t===void 0?void 0:t.status,(n=i.response)===null||n===void 0?void 0:n.data))}}catch(e){console.log("[BUILD] Error with builder session",e);(i=this.sdkError)===null||i===void 0?void 0:i.emit(new a(e.message,(r=e.response)===null||r===void 0?void 0:r.status,(o=e.response)===null||o===void 0?void 0:o.data))}return[2]}))}))};e.prototype.loadTemplate=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(n){switch(n.label){case 0:if(!e)return[3,2];t=this;return[4,l(this.endpoint,e,false)];case 1:t.templateStore=n.sent();n.label=2;case 2:return[2]}}))}))};e.prototype.handleCancel=function(){this.step="preview"};e.prototype.handleTemplateCreated=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(n){switch(n.label){case 0:return[4,this.loadTemplate(e)];case 1:n.sent();this.templateId=e;this.step="roles";(t=this.stepChanged)===null||t===void 0?void 0:t.emit("roles");return[2]}}))}))};e.prototype.handleRolesUpdated=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(n){(t=this.templateUpdated)===null||t===void 0?void 0:t.emit(e.detail);return[2]}))}))};e.prototype.handleTemplateUpdated=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(n){(t=this.templateUpdated)===null||t===void 0?void 0:t.emit(e.detail);return[2]}))}))};e.prototype.handleAttachmentsNext=function(){var e;this.step="roles";(e=this.stepChanged)===null||e===void 0?void 0:e.emit("roles")};e.prototype.handleRolesNext=function(){var e;this.step="fields";(e=this.stepChanged)===null||e===void 0?void 0:e.emit("fields")};e.prototype.handleStepChanged=function(e){var t;this.step=e;(t=this.stepChanged)===null||t===void 0?void 0:t.emit(e)};e.prototype.render=function(){var e=this;if(!this.endpoint.session){return i(r,null,i("verdocs-component-error",{message:"You must be authenticated to use this module."}))}if(!this.templateStore){console.log("[BUILD] No template ID, rendering created view");return i(r,null,i("div",{class:"content"},i("verdocs-template-build-tabs",{endpoint:this.endpoint,templateId:this.templateId,step:"attachments",onSdkError:function(t){var n;return(n=e.sdkError)===null||n===void 0?void 0:n.emit(t.detail)},onStepChanged:function(t){return e.handleStepChanged(t.detail)}}),i("verdocs-template-create",{endpoint:this.endpoint,onExit:function(){return e.handleCancel()},onNext:function(){return e.handleAttachmentsNext()},onTemplateCreated:function(t){return e.handleTemplateCreated(t.detail.templateId)}})))}console.log("[BUILD] Rendering build view",this.templateId,this.step,["attachments","roles","settings","fields","preview"].indexOf(this.step));return i(r,null,i("div",{class:"content"},i("verdocs-template-build-tabs",{endpoint:this.endpoint,templateId:this.templateId,step:this.step,onSdkError:function(t){var n;return(n=e.sdkError)===null||n===void 0?void 0:n.emit(t.detail)},onStepChanged:function(t){return e.handleStepChanged(t.detail)}}),this.step==="attachments"&&i("verdocs-template-attachments",{templateId:this.templateId,endpoint:this.endpoint,onExit:function(){return e.handleCancel()},onNext:function(){return e.handleAttachmentsNext()},onTemplateUpdated:function(t){return e.handleTemplateUpdated(t)}}),this.step==="roles"&&i("verdocs-template-roles",{templateId:this.templateId,endpoint:this.endpoint,onExit:function(){return e.handleCancel()},onNext:function(){return e.handleRolesNext()},onRolesUpdated:function(t){return e.handleRolesUpdated(t)}}),this.step==="settings"&&i("div",{style:{flexDirection:"column",gap:"20px",display:"flex",maxWidth:"400px",margin:"20px"}},i("verdocs-template-name",{templateId:this.templateId,endpoint:this.endpoint,style:{backgroundColor:"#ffffff",padding:"20px"},onTemplateUpdated:function(t){return e.handleTemplateUpdated(t)}}),i("verdocs-template-reminders",{templateId:this.templateId,endpoint:this.endpoint,style:{backgroundColor:"#ffffff",padding:"20px"},onTemplateUpdated:function(t){return e.handleTemplateUpdated(t)}}),i("verdocs-template-visibility",{templateId:this.templateId,endpoint:this.endpoint,style:{backgroundColor:"#ffffff",padding:"20px"},onTemplateUpdated:function(t){return e.handleTemplateUpdated(t)}})),this.step==="fields"&&i("verdocs-template-fields",{templateId:this.templateId,endpoint:this.endpoint,onTemplateUpdated:function(t){return e.handleTemplateUpdated(t)}}),this.step==="preview"&&i("div",{class:"preview-container"},i("div",{class:"preview-send-wrapper"},i("verdocs-send",{templateId:this.templateId,endpoint:this.endpoint,onSend:function(t){var n;return(n=e.send)===null||n===void 0?void 0:n.emit(t.detail)},style:{width:"100%"}})),i("div",{class:"preview-preview-wrapper"},i("verdocs-preview",{templateId:this.templateId,endpoint:this.endpoint,style:{display:"flex",flex:"1",maxWidth:"1000px"}})))))};Object.defineProperty(e.prototype,"el",{get:function(){return o(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{templateId:["onTemplateIdChanged"],step:["onStepChanged"]}},enumerable:false,configurable:true});return e}());u.style=c}}}));
@@ -1 +1 @@
1
- var __awaiter=this&&this.__awaiter||function(e,t,o,r){function i(e){return e instanceof o?e:new o((function(t){t(e)}))}return new(o||(o=Promise))((function(o,s){function n(e){try{a(r.next(e))}catch(e){s(e)}}function l(e){try{a(r["throw"](e))}catch(e){s(e)}}function a(e){e.done?o(e.value):i(e.value).then(n,l)}a((r=r.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var o={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},r,i,s,n;return n={next:l(0),throw:l(1),return:l(2)},typeof Symbol==="function"&&(n[Symbol.iterator]=function(){return this}),n;function l(e){return function(t){return a([e,t])}}function a(l){if(r)throw new TypeError("Generator is already executing.");while(n&&(n=0,l[0]&&(o=0)),o)try{if(r=1,i&&(s=l[0]&2?i["return"]:l[0]?i["throw"]||((s=i["return"])&&s.call(i),0):i.next)&&!(s=s.call(i,l[1])).done)return s;if(i=0,s)l=[l[0]&2,s.value];switch(l[0]){case 0:case 1:s=l;break;case 4:o.label++;return{value:l[1],done:false};case 5:o.label++;i=l[1];l=[0];continue;case 7:l=o.ops.pop();o.trys.pop();continue;default:if(!(s=o.trys,s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){o=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){o.label=l[1];break}if(l[0]===6&&o.label<s[1]){o.label=s[1];s=l;break}if(s&&o.label<s[2]){o.label=s[2];o.ops.push(l);break}if(s[2])o.ops.pop();o.trys.pop();continue}l=t.call(e,o)}catch(e){l=[6,e];i=0}finally{r=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(e,t,o){if(o||arguments.length===2)for(var r=0,i=t.length,s;r<i;r++){if(s||!(r in t)){if(!s)s=Array.prototype.slice.call(t,0,r);s[r]=t[r]}}return e.concat(s||Array.prototype.slice.call(t))};System.register(["./p-59073837.system.js","@verdocs/js-sdk","./p-38c6897c.system.js","./p-701b9cbd.system.js","./p-1a663adf.system.js","./p-c8a15cb7.system.js","./p-38778553.system.js","./p-f5064e0c.system.js"],(function(e){"use strict";var t,o,r,i,s,n,l,a,c,d,p,f,u;return{setters:[function(e){t=e.r;o=e.h;r=e.H;i=e.c;s=e.g},function(e){n=e.VerdocsEndpoint;l=e.updateField;a=e.deleteField},function(e){c=e.g;d=e.u},function(e){p=e.g},function(e){f=e.g},function(e){u=e.S},function(){},function(){}],execute:function(){var h='@charset "UTF-8";@-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-checkbox{line-height:18px;font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif}verdocs-checkbox label>input[type=checkbox]{display:none}verdocs-checkbox label>input[type=checkbox]+*::before{content:"";width:20px;height:20px;-ms-flex-negative:0;flex-shrink:0;margin-right:8px;line-height:20px;border-radius:2px;border-style:solid;border-width:0.1rem;display:inline-block;vertical-align:bottom;border-color:#aeb4bf}verdocs-checkbox label>input[type=checkbox]:checked+*{color:#55bc81}verdocs-checkbox label>input[type=checkbox]:checked+*::before{content:"✓";color:white;text-align:center;background:#55bc81;border-color:#55bc81}verdocs-checkbox.dark label>input[type=checkbox]+*::before{border-color:#ffffff}verdocs-checkbox.dark label>input[type=checkbox]:checked+*::before{background:#55bc81;border-color:#55bc81}';var b=h;var m=e("verdocs_checkbox",function(){function e(e){t(this,e);this.checked=false;this.name="";this.label="";this.value="";this.theme="light";this.disabled=false}e.prototype.render=function(){var e;return o(r,{key:"7557fbb5f4b2b7c2f73cb70e92c47f72082f7345",class:(e={disabled:this.disabled},e[this.theme]=true,e)},o("label",{key:"525745e68d4688a0249a06ad0f86127dc32d8985"},o("input",{key:"a96e6f0816efa3f4780883e525441413226b7cb2",type:"checkbox",value:this.value,name:this.name,checked:this.checked,disabled:this.disabled}),o("span",{key:"b76e4c1b66f48792db9c75577cb23031ce1cf09f"},this.label)))};return e}());m.style=b;var v='@-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-component-error{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif;display:-ms-flexbox;display:flex;padding:15px;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}verdocs-component-error .inner{-ms-flex:1;flex:1;height:300px;display:-ms-flexbox;display:flex;font-size:18px;-webkit-box-sizing:border-box;box-sizing:border-box;padding:0 20px;background:#ffffff;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}';var x=v;var g=e("verdocs_component_error",function(){function e(e){t(this,e);this.message=""}e.prototype.render=function(){return o(r,{key:"f04b367fe3bba058c058c12214e49256397d1d0b"},o("div",{key:"79520ee8597e0ffa075834719355241389a933ef",class:"inner"},this.message))};return e}());g.style=x;var k='@-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-select-input{font-family:"Inter", "Barlow", sans-serif;-webkit-box-sizing:border-box;box-sizing:border-box;margin:0 0 10px 0;display:block}verdocs-select-input .input-element{-webkit-box-sizing:border-box;box-sizing:border-box;background:#ffffff;border:1px solid #cccccc;border-radius:4px;background:#ffffff;color:#092c4c;width:100%;font-size:16px;height:28px;padding:2px 8px}verdocs-select-input .input-element::-webkit-input-placeholder{color:#aaaaaa;opacity:1}verdocs-select-input .input-element::-moz-placeholder{color:#aaaaaa;opacity:1}verdocs-select-input .input-element:-ms-input-placeholder{color:#aaaaaa;opacity:1}verdocs-select-input .input-element::-ms-input-placeholder{color:#aaaaaa;opacity:1}verdocs-select-input .input-element::placeholder{color:#aaaaaa;opacity:1}verdocs-select-input .input-label{display:block;color:#555570;font-weight:700;font-size:14px;margin:0 0 4px 0}';var y=k;var w=e("verdocs_select_input",function(){function e(e){t(this,e);this.value="";this.label="";this.options=undefined;this.disabled=false}e.prototype.render=function(){var e=this;return o(r,{key:"f1582304d06ac080c2a84f42a26756ccd72b7223",class:"input-field"},o("label",{key:"d25d6b05d23c5b709faf58541885e813a44e6978"},this.label?o("div",{class:"input-label"},this.label+":"):o("div",null),o("select",{key:"7c4c518c6946d4e79d5c04f029703f6367cf1aa4",class:"input-element",disabled:this.disabled},this.options.map((function(t){return o("option",{value:t.value,selected:t.value===e.value},t.label)})))))};return e}());w.style=y;var I='@-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-field-properties{padding:20px;display:block;border-radius:4px;background:#ffffff;border:1px solid #ccc;font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif;-webkit-box-shadow:2px 2px 10px 0 rgba(0, 0, 0, 0.1215686275);box-shadow:2px 2px 10px 0 rgba(0, 0, 0, 0.1215686275)}@media all and (max-width: 600px){verdocs-template-field-properties{padding:10px;-webkit-transform:scale(0.8);transform:scale(0.8)}}verdocs-template-field-properties .buttons{display:-ms-flexbox;display:flex;margin-top:30px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:end;justify-content:flex-end}verdocs-template-field-properties .buttons verdocs-button{margin-left:16px}verdocs-template-field-properties form .row{display:-ms-flexbox;display:flex;-webkit-column-gap:15px;-moz-column-gap:15px;column-gap:15px;margin:0 0 10px 0;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}verdocs-template-field-properties form .row .input-label{display:block;color:#555570;font-weight:700;font-size:14px;margin:0 0 4px 0;-ms-flex:0 0 100px;flex:0 0 100px}verdocs-template-field-properties verdocs-select-input{-ms-flex:1;flex:1;margin:0}verdocs-template-field-properties verdocs-text-input{margin:0;-ms-flex:1;flex:1}verdocs-template-field-properties verdocs-text-input label{margin:0;display:-ms-flexbox;display:flex;-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}verdocs-template-field-properties verdocs-text-input .input-label{-ms-flex:0 0 100px;flex:0 0 100px}verdocs-template-field-properties verdocs-text-input input{-ms-flex:1;flex:1;display:-ms-flexbox;display:flex}verdocs-template-field-properties .checkbox-wrapper{-ms-flex:1;flex:1;display:-ms-flexbox;display:flex}verdocs-template-field-properties .delete-button{height:34px;display:-ms-flexbox;display:flex;cursor:pointer;background:none;border-radius:4px;-ms-flex-align:center;align-items:center;border:1px solid #999;-ms-flex-pack:center;justify-content:center}verdocs-template-field-properties .delete-button:active{background:#f3f3f3}verdocs-template-field-properties .delete-button svg{width:24px;height:24px}verdocs-template-field-properties h6{-ms-flex:1;flex:1;display:-ms-flexbox;display:flex;font-size:16px;font-weight:bold;margin:0 0 8px 0;-ms-flex-direction:row;flex-direction:row;color:#092c4c}verdocs-template-field-properties h6 .help-icon{opacity:0.5}verdocs-template-field-properties h6 .help-icon:hover{opacity:1;cursor:pointer}verdocs-template-field-properties .row-header{gap:15px;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-template-field-properties .row-header h6{margin-bottom:0}verdocs-template-field-properties .row-header verdocs-help-icon{-webkit-transform:scale(0.85);transform:scale(0.85)}verdocs-template-field-properties .row-header verdocs-help-icon svg{margin-bottom:-5px}verdocs-template-field-properties .row-header .add-button{margin:0;padding:0;border:none;opacity:0.5;cursor:pointer;background:none}verdocs-template-field-properties .row-header .add-button:hover{opacity:1}verdocs-template-field-properties .row-header .add-button svg{width:32px;height:32px}verdocs-template-field-properties .options-header{gap:10px;margin:0 0 5px 0;display:-ms-flexbox;display:flex;color:#ffffff;font-size:14px;padding:5px 8px;font-weight:700;text-align:center;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center;background-color:#333333}verdocs-template-field-properties .options-header-label{display:-ms-flexbox;display:flex;-ms-flex:1;flex:1;font-weight:700;font-size:14px}verdocs-template-field-properties .option-row{margin:15px 0}verdocs-template-field-properties .option-row .remove-button{height:28px;display:-ms-flexbox;display:flex;cursor:pointer;background:none;border-radius:4px;-ms-flex-align:center;align-items:center;border:1px solid #999;-ms-flex-pack:center;justify-content:center}verdocs-template-field-properties .option-row .remove-button:active{background:#f3f3f3}verdocs-template-field-properties .option-row .remove-button:hover svg{stroke:rgb(165, 0, 33)}verdocs-template-field-properties .option-row .remove-button svg{width:20px;height:20px;stroke:#333333}verdocs-template-field-properties .options{background:#f3f3f3;padding:0 0 1px 0}verdocs-template-field-properties .options .row-header,verdocs-template-field-properties .options .option-row{padding:0 10px}verdocs-template-field-properties .options .add-option-button{border-radius:5px;border:1px solid #cccccc;background:#46497d;color:#ffffff;padding:3px 8px}verdocs-template-field-properties .options .option-row .input-element{font-size:14px}verdocs-template-field-properties .options verdocs-help-icon{opacity:1;-webkit-transform:scale(0.8);transform:scale(0.8)}verdocs-template-field-properties .options verdocs-help-icon svg{fill:#ffffff}';var E=I;var _=function(e){return e.charAt(0).toUpperCase()+e.slice(1)};var q='<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="#a50021"><path stroke-linecap="round" stroke-linejoin="round" d="M14.74 9l-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 01-2.244 2.077H8.084a2.25 2.25 0 01-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 00-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 013.478-.397m7.5 0v-.916c0-1.18-.91-2.164-2.09-2.201a51.964 51.964 0 00-3.32 0c-1.18.037-2.09 1.022-2.09 2.201v.916m7.5 0a48.667 48.667 0 00-7.5 0" /></svg>';var R='<svg xmlns="http://www.w3.org/2000/svg" height="24" width="24"><path d="M11.925 18q.55 0 .938-.387.387-.388.387-.938 0-.55-.387-.925-.388-.375-.938-.375-.55 0-.925.375t-.375.925q0 .55.375.938.375.387.925.387Zm-.95-3.85h1.95q0-.8.2-1.287.2-.488 1.025-1.288.65-.625 1.025-1.213.375-.587.375-1.437 0-1.425-1.025-2.175Q13.5 6 12.1 6q-1.425 0-2.35.775t-1.275 1.85l1.775.7q.125-.45.55-.975.425-.525 1.275-.525.725 0 1.1.412.375.413.375.888 0 .475-.287.9-.288.425-.713.775-1.075.95-1.325 1.475-.25.525-.25 1.875ZM12 22.2q-2.125 0-3.988-.8-1.862-.8-3.237-2.175Q3.4 17.85 2.6 15.988 1.8 14.125 1.8 12t.8-3.988q.8-1.862 2.175-3.237Q6.15 3.4 8.012 2.6 9.875 1.8 12 1.8t3.988.8q1.862.8 3.237 2.175Q20.6 6.15 21.4 8.012q.8 1.863.8 3.988t-.8 3.988q-.8 1.862-2.175 3.237Q17.85 20.6 15.988 21.4q-1.863.8-3.988.8Zm0-2.275q3.325 0 5.625-2.3t2.3-5.625q0-3.325-2.3-5.625T12 4.075q-3.325 0-5.625 2.3T4.075 12q0 3.325 2.3 5.625t5.625 2.3ZM12 12Z"/></svg>';var T=e("verdocs_template_field_properties",function(){function e(e){t(this,e);this.close=i(this,"close",7);this.delete=i(this,"delete",7);this.settingsChanged=i(this,"settingsChanged",7);this.sdkError=i(this,"sdkError",7);this.templateStore=null;this.fieldStore=null;this.roleStore=null;this.endpoint=n.getDefault();this.templateId="";this.fieldName="";this.helpText="";this.dirty=false;this.loading=true;this.label="";this.type="textbox";this.name="";this.required=false;this.roleName="";this.group="";this.fieldType="";this.options=[];this.placeholder="";this.defaultValue="";this.showingHelp=false}e.prototype.componentWillLoad=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,o,r,i;return __generator(this,(function(s){switch(s.label){case 0:s.trys.push([0,2,,3]);this.endpoint.loadSession();if(!this.templateId){console.log("[FIELD PROPERTIES] Missing required template ID ".concat(this.templateId));return[2]}if(!this.fieldName){console.error("[FIELD PROPERTIES] Missing required field name");return[2]}if(!this.endpoint.session){console.log("[FIELD PROPERTIES] Unable to start builder session, must be authenticated");return[2]}r=this;return[4,f(this.endpoint,this.templateId)];case 1:r.templateStore=s.sent();this.fieldStore=c(this.templateId);this.roleStore=p(this.templateId);this.resetForm();return[3,3];case 2:i=s.sent();console.log("[FIELD PROPERTIES] Error loading template",i);this.loading=false;(e=this.sdkError)===null||e===void 0?void 0:e.emit(new u(i.message,(t=i.response)===null||t===void 0?void 0:t.status,(o=i.response)===null||o===void 0?void 0:o.data));return[3,3];case 3:return[2]}}))}))};e.prototype.resetForm=function(){var e=this;var t=this.fieldStore.get("fields").find((function(t){return t.name===e.fieldName}));if(!t){console.log('[FIELD PROPERTIES] Unable to find field "'.concat(this.fieldName,'" in fields'));return}this.type=t.type;this.name=t.name;this.label=t.label;this.group=t.group;this.roleName=t.role_name;this.required=t.required;this.fieldType=t.type;this.options=t.options||[];this.placeholder=t.placeholder||"";this.defaultValue=t.default||"";this.dirty=false;this.loading=false;this.cleanupOptions()};e.prototype.handleCancel=function(e){var t,o;e.stopPropagation();this.resetForm();(t=this.close)===null||t===void 0?void 0:t.emit();(o=document.getElementById("verdocs-template-field-properties"))===null||o===void 0?void 0:o.remove()};e.prototype.handleSave=function(e){var t=this;e.stopPropagation();var o={name:this.name,role_name:this.roleName,required:this.required,label:this.label,group:this.group,placeholder:this.placeholder,default:this.defaultValue,options:this.options};this.cleanupOptions();console.log("[FIELD PROPERTIES] Will update",this.fieldName,o);l(this.endpoint,this.templateId,this.fieldName,o).then((function(e){var o,r,i;console.log("[FIELD PROPERTIES] Updated",e);d(t.fieldStore,t.fieldName,e);(o=t.settingsChanged)===null||o===void 0?void 0:o.emit({fieldName:t.fieldName,field:e});(r=t.close)===null||r===void 0?void 0:r.emit();(i=document.getElementById("verdocs-template-field-properties"))===null||i===void 0?void 0:i.remove()})).catch((function(){console.log("[FIELD PROPERTIES] Update failed",e)}))};e.prototype.handleDelete=function(e){return __awaiter(this,void 0,void 0,(function(){var t=this;return __generator(this,(function(o){e.stopPropagation();a(this.endpoint,this.templateId,this.fieldName).then((function(){var e,o;t.fieldStore.set("fields",t.fieldStore.get("fields").filter((function(e){return e.name!==t.fieldName})));(e=t.delete)===null||e===void 0?void 0:e.emit({templateId:t.templateId,roleName:t.roleName});(o=document.getElementById("verdocs-template-field-properties"))===null||o===void 0?void 0:o.remove()})).catch((function(e){console.log("[FIELD PROPERTIES] Deletion error",e)}));return[2]}))}))};e.prototype.cleanupOptions=function(){this.options=__spreadArray([],this.options.filter((function(e){return(e.id||"").trim()!==""||(e.label||"").trim()!==""})),true);if(!this.options.find((function(e){return!e.id&&!e.label}))){this.options=__spreadArray(__spreadArray([],this.options,true),[{id:"",label:""}],false)}};e.prototype.render=function(){var e=this;var t;if(!this.endpoint.session){return o(r,null,o("verdocs-component-error",{message:"You must be authenticated to use this module."}))}if(!this.endpoint.session||!this.fieldStore.get("fields").some((function(t){return t.name===e.fieldName}))){return o(r,{class:"empty"})}if(this.helpText&&this.showingHelp){return o(r,null,o("h6",null,_(this.fieldType)," Settings ",o("div",{style:{flex:"1"}}),o("div",{class:"help-icon",innerHTML:R,onClick:function(){return e.showingHelp=false}})),o("p",{class:"instructions",innerHTML:this.helpText}))}var i=this.options.filter((function(e){return(e.id||"").trim()!==""||(e.label||"").trim()!==""})).length>0;var s=!this.dirty||this.type==="dropdown"&&!i;return o(r,{id:"verdocs-template-field-properties"},o("h6",null,_(this.fieldType.replace(/_/g," "))," Settings ",o("div",{style:{flex:"1"}}),this.helpText&&o("div",{class:"help-icon",innerHTML:R,onClick:function(){return e.showingHelp=true}})),o("form",{onSubmit:function(e){return e.preventDefault()},onClick:function(e){return e.stopPropagation()},autocomplete:"off"},o("div",{class:"row"},o("verdocs-text-input",{id:"verdocs-field-name",label:"Field Name",value:this.name,autocomplete:"off",placeholder:"Field Name...",onInput:function(t){e.name=t.target.value;e.dirty=true}})),o("div",{class:"row"},o("verdocs-text-input",{id:"verdocs-field-label",label:"Optional Label",value:this.label,autocomplete:"off",placeholder:"Optional Label...",onInput:function(t){e.label=t.target.value;e.dirty=true}})),o("div",{class:"row"},o("div",{class:"input-label"},"Role:"),o("verdocs-select-input",{value:this.roleName,options:(t=this.roleStore.state)===null||t===void 0?void 0:t.roles.map((function(e){return{label:e.name,value:e.name}})),onInput:function(t){e.roleName=t.target.value;e.dirty=true}})),["textbox","textarea"].includes(this.type)&&o("div",{class:"row",style:{marginTop:"10px",marginBottom:"10px"}},o("verdocs-text-input",{id:"verdocs-field-value",label:"Default Value",value:this.defaultValue,autocomplete:"off",placeholder:"Pre-filled value...",onInput:function(t){e.defaultValue=t.target.value;e.dirty=true}})),this.type==="radio"&&o("div",{class:"row"},o("verdocs-text-input",{id:"verdocs-field-label",label:"Group",value:this.group,autocomplete:"off",helpText:"Enable exclusive selections. Only one option within the same group may be selected at a time.",placeholder:"Group...",onInput:function(t){e.group=(t.target.value||"").trim().toLowerCase().replace(/[^a-z0-9]/g,"");e.dirty=true}})),["textbox","textarea"].includes(this.type)&&o("div",{class:"row",style:{marginTop:"10px",marginBottom:"10px"}},o("verdocs-text-input",{id:"verdocs-field-placeholder",label:"Placeholder",value:this.placeholder,autocomplete:"off",placeholder:"Placeholder...",onInput:function(t){e.placeholder=t.target.value;e.dirty=true}})),o("div",{class:"row",style:{marginTop:"15px",marginBottom:"15px"}},o("label",{htmlFor:"verdocs-is-required",class:"input-label"},"Required"),o("verdocs-checkbox",{id:"verdocs-is-required",name:"is-required",checked:this.required,value:"on",onInput:function(t){e.required=t.target.checked;e.dirty=true}})),this.type==="dropdown"&&o("div",{class:"row",style:{marginTop:"15px",marginBottom:"15px"}},o("label",{htmlFor:"verdocs-is-required",class:"input-label"},"Options")),this.type==="dropdown"&&o("div",{class:"options"},o("div",{class:"options-header"},o("div",{class:"options-header-label"},"ID"),o("dev",{class:"options-header-label"},"Label")),this.options.map((function(t,r){return o("div",{class:"row option-row",key:r},o("verdocs-text-input",{value:t.id,placeholder:"Unique ID",onInput:function(t){e.options[r].id=t.target.value;e.dirty=true;e.cleanupOptions()}}),o("verdocs-text-input",{value:t.label,placeholder:"Display label",onInput:function(t){e.options[r].label=t.target.value;e.dirty=true;e.cleanupOptions()}}),o("button",{innerHTML:q,class:"remove-button",onClick:function(){e.options=e.options.filter((function(e){return e.id!==t.id}));e.dirty=true;e.cleanupOptions()}}))}))),o("div",{class:"buttons"},o("button",{class:"delete-button",disabled:this.dirty,onClick:function(t){return e.handleDelete(t)},innerHTML:q}),o("div",{style:{flex:"1"}}),o("verdocs-button",{size:"small",variant:"outline",label:"Cancel",disabled:!this.dirty,onClick:function(t){return e.handleCancel(t)}}),o("verdocs-button",{size:"small",label:"Save",disabled:s,onClick:function(t){return!s&&e.handleSave(t)}}))))};Object.defineProperty(e.prototype,"el",{get:function(){return s(this)},enumerable:false,configurable:true});return e}());T.style=E}}}));
1
+ var __awaiter=this&&this.__awaiter||function(e,t,o,r){function i(e){return e instanceof o?e:new o((function(t){t(e)}))}return new(o||(o=Promise))((function(o,s){function n(e){try{a(r.next(e))}catch(e){s(e)}}function l(e){try{a(r["throw"](e))}catch(e){s(e)}}function a(e){e.done?o(e.value):i(e.value).then(n,l)}a((r=r.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var o={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},r,i,s,n;return n={next:l(0),throw:l(1),return:l(2)},typeof Symbol==="function"&&(n[Symbol.iterator]=function(){return this}),n;function l(e){return function(t){return a([e,t])}}function a(l){if(r)throw new TypeError("Generator is already executing.");while(n&&(n=0,l[0]&&(o=0)),o)try{if(r=1,i&&(s=l[0]&2?i["return"]:l[0]?i["throw"]||((s=i["return"])&&s.call(i),0):i.next)&&!(s=s.call(i,l[1])).done)return s;if(i=0,s)l=[l[0]&2,s.value];switch(l[0]){case 0:case 1:s=l;break;case 4:o.label++;return{value:l[1],done:false};case 5:o.label++;i=l[1];l=[0];continue;case 7:l=o.ops.pop();o.trys.pop();continue;default:if(!(s=o.trys,s=s.length>0&&s[s.length-1])&&(l[0]===6||l[0]===2)){o=0;continue}if(l[0]===3&&(!s||l[1]>s[0]&&l[1]<s[3])){o.label=l[1];break}if(l[0]===6&&o.label<s[1]){o.label=s[1];s=l;break}if(s&&o.label<s[2]){o.label=s[2];o.ops.push(l);break}if(s[2])o.ops.pop();o.trys.pop();continue}l=t.call(e,o)}catch(e){l=[6,e];i=0}finally{r=s=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(e,t,o){if(o||arguments.length===2)for(var r=0,i=t.length,s;r<i;r++){if(s||!(r in t)){if(!s)s=Array.prototype.slice.call(t,0,r);s[r]=t[r]}}return e.concat(s||Array.prototype.slice.call(t))};System.register(["./p-59073837.system.js","@verdocs/js-sdk","./p-38c6897c.system.js","./p-701b9cbd.system.js","./p-a9e0ae2c.system.js","./p-c8a15cb7.system.js","./p-38778553.system.js","./p-f5064e0c.system.js"],(function(e){"use strict";var t,o,r,i,s,n,l,a,c,d,p,f,u;return{setters:[function(e){t=e.r;o=e.h;r=e.H;i=e.c;s=e.g},function(e){n=e.VerdocsEndpoint;l=e.updateField;a=e.deleteField},function(e){c=e.g;d=e.u},function(e){p=e.g},function(e){f=e.g},function(e){u=e.S},function(){},function(){}],execute:function(){var h='@charset "UTF-8";@-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-checkbox{line-height:18px;font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif}verdocs-checkbox label>input[type=checkbox]{display:none}verdocs-checkbox label>input[type=checkbox]+*::before{content:"";width:20px;height:20px;-ms-flex-negative:0;flex-shrink:0;margin-right:8px;line-height:20px;border-radius:2px;border-style:solid;border-width:0.1rem;display:inline-block;vertical-align:bottom;border-color:#aeb4bf}verdocs-checkbox label>input[type=checkbox]:checked+*{color:#55bc81}verdocs-checkbox label>input[type=checkbox]:checked+*::before{content:"✓";color:white;text-align:center;background:#55bc81;border-color:#55bc81}verdocs-checkbox.dark label>input[type=checkbox]+*::before{border-color:#ffffff}verdocs-checkbox.dark label>input[type=checkbox]:checked+*::before{background:#55bc81;border-color:#55bc81}';var b=h;var m=e("verdocs_checkbox",function(){function e(e){t(this,e);this.checked=false;this.name="";this.label="";this.value="";this.theme="light";this.disabled=false}e.prototype.render=function(){var e;return o(r,{key:"7557fbb5f4b2b7c2f73cb70e92c47f72082f7345",class:(e={disabled:this.disabled},e[this.theme]=true,e)},o("label",{key:"525745e68d4688a0249a06ad0f86127dc32d8985"},o("input",{key:"a96e6f0816efa3f4780883e525441413226b7cb2",type:"checkbox",value:this.value,name:this.name,checked:this.checked,disabled:this.disabled}),o("span",{key:"b76e4c1b66f48792db9c75577cb23031ce1cf09f"},this.label)))};return e}());m.style=b;var v='@-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-component-error{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif;display:-ms-flexbox;display:flex;padding:15px;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}verdocs-component-error .inner{-ms-flex:1;flex:1;height:300px;display:-ms-flexbox;display:flex;font-size:18px;-webkit-box-sizing:border-box;box-sizing:border-box;padding:0 20px;background:#ffffff;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}';var x=v;var g=e("verdocs_component_error",function(){function e(e){t(this,e);this.message=""}e.prototype.render=function(){return o(r,{key:"f04b367fe3bba058c058c12214e49256397d1d0b"},o("div",{key:"79520ee8597e0ffa075834719355241389a933ef",class:"inner"},this.message))};return e}());g.style=x;var k='@-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-select-input{font-family:"Inter", "Barlow", sans-serif;-webkit-box-sizing:border-box;box-sizing:border-box;margin:0 0 10px 0;display:block}verdocs-select-input .input-element{-webkit-box-sizing:border-box;box-sizing:border-box;background:#ffffff;border:1px solid #cccccc;border-radius:4px;background:#ffffff;color:#092c4c;width:100%;font-size:16px;height:28px;padding:2px 8px}verdocs-select-input .input-element::-webkit-input-placeholder{color:#aaaaaa;opacity:1}verdocs-select-input .input-element::-moz-placeholder{color:#aaaaaa;opacity:1}verdocs-select-input .input-element:-ms-input-placeholder{color:#aaaaaa;opacity:1}verdocs-select-input .input-element::-ms-input-placeholder{color:#aaaaaa;opacity:1}verdocs-select-input .input-element::placeholder{color:#aaaaaa;opacity:1}verdocs-select-input .input-label{display:block;color:#555570;font-weight:700;font-size:14px;margin:0 0 4px 0}';var y=k;var w=e("verdocs_select_input",function(){function e(e){t(this,e);this.value="";this.label="";this.options=undefined;this.disabled=false}e.prototype.render=function(){var e=this;return o(r,{key:"f1582304d06ac080c2a84f42a26756ccd72b7223",class:"input-field"},o("label",{key:"d25d6b05d23c5b709faf58541885e813a44e6978"},this.label?o("div",{class:"input-label"},this.label+":"):o("div",null),o("select",{key:"7c4c518c6946d4e79d5c04f029703f6367cf1aa4",class:"input-element",disabled:this.disabled},this.options.map((function(t){return o("option",{value:t.value,selected:t.value===e.value},t.label)})))))};return e}());w.style=y;var I='@-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-field-properties{padding:20px;display:block;border-radius:4px;background:#ffffff;border:1px solid #ccc;font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif;-webkit-box-shadow:2px 2px 10px 0 rgba(0, 0, 0, 0.1215686275);box-shadow:2px 2px 10px 0 rgba(0, 0, 0, 0.1215686275)}@media all and (max-width: 600px){verdocs-template-field-properties{padding:10px;-webkit-transform:scale(0.8);transform:scale(0.8)}}verdocs-template-field-properties .buttons{display:-ms-flexbox;display:flex;margin-top:30px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:end;justify-content:flex-end}verdocs-template-field-properties .buttons verdocs-button{margin-left:16px}verdocs-template-field-properties form .row{display:-ms-flexbox;display:flex;-webkit-column-gap:15px;-moz-column-gap:15px;column-gap:15px;margin:0 0 10px 0;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}verdocs-template-field-properties form .row .input-label{display:block;color:#555570;font-weight:700;font-size:14px;margin:0 0 4px 0;-ms-flex:0 0 100px;flex:0 0 100px}verdocs-template-field-properties verdocs-select-input{-ms-flex:1;flex:1;margin:0}verdocs-template-field-properties verdocs-text-input{margin:0;-ms-flex:1;flex:1}verdocs-template-field-properties verdocs-text-input label{margin:0;display:-ms-flexbox;display:flex;-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}verdocs-template-field-properties verdocs-text-input .input-label{-ms-flex:0 0 100px;flex:0 0 100px}verdocs-template-field-properties verdocs-text-input input{-ms-flex:1;flex:1;display:-ms-flexbox;display:flex}verdocs-template-field-properties .checkbox-wrapper{-ms-flex:1;flex:1;display:-ms-flexbox;display:flex}verdocs-template-field-properties .delete-button{height:34px;display:-ms-flexbox;display:flex;cursor:pointer;background:none;border-radius:4px;-ms-flex-align:center;align-items:center;border:1px solid #999;-ms-flex-pack:center;justify-content:center}verdocs-template-field-properties .delete-button:active{background:#f3f3f3}verdocs-template-field-properties .delete-button svg{width:24px;height:24px}verdocs-template-field-properties h6{-ms-flex:1;flex:1;display:-ms-flexbox;display:flex;font-size:16px;font-weight:bold;margin:0 0 8px 0;-ms-flex-direction:row;flex-direction:row;color:#092c4c}verdocs-template-field-properties h6 .help-icon{opacity:0.5}verdocs-template-field-properties h6 .help-icon:hover{opacity:1;cursor:pointer}verdocs-template-field-properties .row-header{gap:15px;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-template-field-properties .row-header h6{margin-bottom:0}verdocs-template-field-properties .row-header verdocs-help-icon{-webkit-transform:scale(0.85);transform:scale(0.85)}verdocs-template-field-properties .row-header verdocs-help-icon svg{margin-bottom:-5px}verdocs-template-field-properties .row-header .add-button{margin:0;padding:0;border:none;opacity:0.5;cursor:pointer;background:none}verdocs-template-field-properties .row-header .add-button:hover{opacity:1}verdocs-template-field-properties .row-header .add-button svg{width:32px;height:32px}verdocs-template-field-properties .options-header{gap:10px;margin:0 0 5px 0;display:-ms-flexbox;display:flex;color:#ffffff;font-size:14px;padding:5px 8px;font-weight:700;text-align:center;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center;background-color:#333333}verdocs-template-field-properties .options-header-label{display:-ms-flexbox;display:flex;-ms-flex:1;flex:1;font-weight:700;font-size:14px}verdocs-template-field-properties .option-row{margin:15px 0}verdocs-template-field-properties .option-row .remove-button{height:28px;display:-ms-flexbox;display:flex;cursor:pointer;background:none;border-radius:4px;-ms-flex-align:center;align-items:center;border:1px solid #999;-ms-flex-pack:center;justify-content:center}verdocs-template-field-properties .option-row .remove-button:active{background:#f3f3f3}verdocs-template-field-properties .option-row .remove-button:hover svg{stroke:rgb(165, 0, 33)}verdocs-template-field-properties .option-row .remove-button svg{width:20px;height:20px;stroke:#333333}verdocs-template-field-properties .options{background:#f3f3f3;padding:0 0 1px 0}verdocs-template-field-properties .options .row-header,verdocs-template-field-properties .options .option-row{padding:0 10px}verdocs-template-field-properties .options .add-option-button{border-radius:5px;border:1px solid #cccccc;background:#46497d;color:#ffffff;padding:3px 8px}verdocs-template-field-properties .options .option-row .input-element{font-size:14px}verdocs-template-field-properties .options verdocs-help-icon{opacity:1;-webkit-transform:scale(0.8);transform:scale(0.8)}verdocs-template-field-properties .options verdocs-help-icon svg{fill:#ffffff}';var E=I;var _=function(e){return e.charAt(0).toUpperCase()+e.slice(1)};var q='<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="#a50021"><path stroke-linecap="round" stroke-linejoin="round" d="M14.74 9l-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 01-2.244 2.077H8.084a2.25 2.25 0 01-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 00-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 013.478-.397m7.5 0v-.916c0-1.18-.91-2.164-2.09-2.201a51.964 51.964 0 00-3.32 0c-1.18.037-2.09 1.022-2.09 2.201v.916m7.5 0a48.667 48.667 0 00-7.5 0" /></svg>';var R='<svg xmlns="http://www.w3.org/2000/svg" height="24" width="24"><path d="M11.925 18q.55 0 .938-.387.387-.388.387-.938 0-.55-.387-.925-.388-.375-.938-.375-.55 0-.925.375t-.375.925q0 .55.375.938.375.387.925.387Zm-.95-3.85h1.95q0-.8.2-1.287.2-.488 1.025-1.288.65-.625 1.025-1.213.375-.587.375-1.437 0-1.425-1.025-2.175Q13.5 6 12.1 6q-1.425 0-2.35.775t-1.275 1.85l1.775.7q.125-.45.55-.975.425-.525 1.275-.525.725 0 1.1.412.375.413.375.888 0 .475-.287.9-.288.425-.713.775-1.075.95-1.325 1.475-.25.525-.25 1.875ZM12 22.2q-2.125 0-3.988-.8-1.862-.8-3.237-2.175Q3.4 17.85 2.6 15.988 1.8 14.125 1.8 12t.8-3.988q.8-1.862 2.175-3.237Q6.15 3.4 8.012 2.6 9.875 1.8 12 1.8t3.988.8q1.862.8 3.237 2.175Q20.6 6.15 21.4 8.012q.8 1.863.8 3.988t-.8 3.988q-.8 1.862-2.175 3.237Q17.85 20.6 15.988 21.4q-1.863.8-3.988.8Zm0-2.275q3.325 0 5.625-2.3t2.3-5.625q0-3.325-2.3-5.625T12 4.075q-3.325 0-5.625 2.3T4.075 12q0 3.325 2.3 5.625t5.625 2.3ZM12 12Z"/></svg>';var T=e("verdocs_template_field_properties",function(){function e(e){t(this,e);this.close=i(this,"close",7);this.delete=i(this,"delete",7);this.settingsChanged=i(this,"settingsChanged",7);this.sdkError=i(this,"sdkError",7);this.templateStore=null;this.fieldStore=null;this.roleStore=null;this.endpoint=n.getDefault();this.templateId="";this.fieldName="";this.helpText="";this.dirty=false;this.loading=true;this.label="";this.type="textbox";this.name="";this.required=false;this.roleName="";this.group="";this.fieldType="";this.options=[];this.placeholder="";this.defaultValue="";this.showingHelp=false}e.prototype.componentWillLoad=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,o,r,i;return __generator(this,(function(s){switch(s.label){case 0:s.trys.push([0,2,,3]);this.endpoint.loadSession();if(!this.templateId){console.log("[FIELD PROPERTIES] Missing required template ID ".concat(this.templateId));return[2]}if(!this.fieldName){console.error("[FIELD PROPERTIES] Missing required field name");return[2]}if(!this.endpoint.session){console.log("[FIELD PROPERTIES] Unable to start builder session, must be authenticated");return[2]}r=this;return[4,f(this.endpoint,this.templateId)];case 1:r.templateStore=s.sent();this.fieldStore=c(this.templateId);this.roleStore=p(this.templateId);this.resetForm();return[3,3];case 2:i=s.sent();console.log("[FIELD PROPERTIES] Error loading template",i);this.loading=false;(e=this.sdkError)===null||e===void 0?void 0:e.emit(new u(i.message,(t=i.response)===null||t===void 0?void 0:t.status,(o=i.response)===null||o===void 0?void 0:o.data));return[3,3];case 3:return[2]}}))}))};e.prototype.resetForm=function(){var e=this;var t=this.fieldStore.get("fields").find((function(t){return t.name===e.fieldName}));if(!t){console.log('[FIELD PROPERTIES] Unable to find field "'.concat(this.fieldName,'" in fields'));return}this.type=t.type;this.name=t.name;this.label=t.label;this.group=t.group;this.roleName=t.role_name;this.required=t.required;this.fieldType=t.type;this.options=t.options||[];this.placeholder=t.placeholder||"";this.defaultValue=t.default||"";this.dirty=false;this.loading=false;this.cleanupOptions()};e.prototype.handleCancel=function(e){var t,o;e.stopPropagation();this.resetForm();(t=this.close)===null||t===void 0?void 0:t.emit();(o=document.getElementById("verdocs-template-field-properties"))===null||o===void 0?void 0:o.remove()};e.prototype.handleSave=function(e){var t=this;e.stopPropagation();var o={name:this.name,role_name:this.roleName,required:this.required,label:this.label,group:this.group,placeholder:this.placeholder,default:this.defaultValue,options:this.options};this.cleanupOptions();console.log("[FIELD PROPERTIES] Will update",this.fieldName,o);l(this.endpoint,this.templateId,this.fieldName,o).then((function(e){var o,r,i;console.log("[FIELD PROPERTIES] Updated",e);d(t.fieldStore,t.fieldName,e);(o=t.settingsChanged)===null||o===void 0?void 0:o.emit({fieldName:t.fieldName,field:e});(r=t.close)===null||r===void 0?void 0:r.emit();(i=document.getElementById("verdocs-template-field-properties"))===null||i===void 0?void 0:i.remove()})).catch((function(){console.log("[FIELD PROPERTIES] Update failed",e)}))};e.prototype.handleDelete=function(e){return __awaiter(this,void 0,void 0,(function(){var t=this;return __generator(this,(function(o){e.stopPropagation();a(this.endpoint,this.templateId,this.fieldName).then((function(){var e,o;t.fieldStore.set("fields",t.fieldStore.get("fields").filter((function(e){return e.name!==t.fieldName})));(e=t.delete)===null||e===void 0?void 0:e.emit({templateId:t.templateId,roleName:t.roleName});(o=document.getElementById("verdocs-template-field-properties"))===null||o===void 0?void 0:o.remove()})).catch((function(e){console.log("[FIELD PROPERTIES] Deletion error",e)}));return[2]}))}))};e.prototype.cleanupOptions=function(){this.options=__spreadArray([],this.options.filter((function(e){return(e.id||"").trim()!==""||(e.label||"").trim()!==""})),true);if(!this.options.find((function(e){return!e.id&&!e.label}))){this.options=__spreadArray(__spreadArray([],this.options,true),[{id:"",label:""}],false)}};e.prototype.render=function(){var e=this;var t;if(!this.endpoint.session){return o(r,null,o("verdocs-component-error",{message:"You must be authenticated to use this module."}))}if(!this.endpoint.session||!this.fieldStore.get("fields").some((function(t){return t.name===e.fieldName}))){return o(r,{class:"empty"})}if(this.helpText&&this.showingHelp){return o(r,null,o("h6",null,_(this.fieldType)," Settings ",o("div",{style:{flex:"1"}}),o("div",{class:"help-icon",innerHTML:R,onClick:function(){return e.showingHelp=false}})),o("p",{class:"instructions",innerHTML:this.helpText}))}var i=this.options.filter((function(e){return(e.id||"").trim()!==""||(e.label||"").trim()!==""})).length>0;var s=!this.dirty||this.type==="dropdown"&&!i;return o(r,{id:"verdocs-template-field-properties"},o("h6",null,_(this.fieldType.replace(/_/g," "))," Settings ",o("div",{style:{flex:"1"}}),this.helpText&&o("div",{class:"help-icon",innerHTML:R,onClick:function(){return e.showingHelp=true}})),o("form",{onSubmit:function(e){return e.preventDefault()},onClick:function(e){return e.stopPropagation()},autocomplete:"off"},o("div",{class:"row"},o("verdocs-text-input",{id:"verdocs-field-name",label:"Field Name",value:this.name,autocomplete:"off",placeholder:"Field Name...",onInput:function(t){e.name=t.target.value;e.dirty=true}})),o("div",{class:"row"},o("verdocs-text-input",{id:"verdocs-field-label",label:"Optional Label",value:this.label,autocomplete:"off",placeholder:"Optional Label...",onInput:function(t){e.label=t.target.value;e.dirty=true}})),o("div",{class:"row"},o("div",{class:"input-label"},"Role:"),o("verdocs-select-input",{value:this.roleName,options:(t=this.roleStore.state)===null||t===void 0?void 0:t.roles.map((function(e){return{label:e.name,value:e.name}})),onInput:function(t){e.roleName=t.target.value;e.dirty=true}})),["textbox","textarea"].includes(this.type)&&o("div",{class:"row",style:{marginTop:"10px",marginBottom:"10px"}},o("verdocs-text-input",{id:"verdocs-field-value",label:"Default Value",value:this.defaultValue,autocomplete:"off",placeholder:"Pre-filled value...",onInput:function(t){e.defaultValue=t.target.value;e.dirty=true}})),this.type==="radio"&&o("div",{class:"row"},o("verdocs-text-input",{id:"verdocs-field-label",label:"Group",value:this.group,autocomplete:"off",helpText:"Enable exclusive selections. Only one option within the same group may be selected at a time.",placeholder:"Group...",onInput:function(t){e.group=(t.target.value||"").trim().toLowerCase().replace(/[^a-z0-9]/g,"");e.dirty=true}})),["textbox","textarea"].includes(this.type)&&o("div",{class:"row",style:{marginTop:"10px",marginBottom:"10px"}},o("verdocs-text-input",{id:"verdocs-field-placeholder",label:"Placeholder",value:this.placeholder,autocomplete:"off",placeholder:"Placeholder...",onInput:function(t){e.placeholder=t.target.value;e.dirty=true}})),o("div",{class:"row",style:{marginTop:"15px",marginBottom:"15px"}},o("label",{htmlFor:"verdocs-is-required",class:"input-label"},"Required"),o("verdocs-checkbox",{id:"verdocs-is-required",name:"is-required",checked:this.required,value:"on",onInput:function(t){e.required=t.target.checked;e.dirty=true}})),this.type==="dropdown"&&o("div",{class:"row",style:{marginTop:"15px",marginBottom:"15px"}},o("label",{htmlFor:"verdocs-is-required",class:"input-label"},"Options")),this.type==="dropdown"&&o("div",{class:"options"},o("div",{class:"options-header"},o("div",{class:"options-header-label"},"ID"),o("dev",{class:"options-header-label"},"Label")),this.options.map((function(t,r){return o("div",{class:"row option-row",key:r},o("verdocs-text-input",{value:t.id,placeholder:"Unique ID",onInput:function(t){e.options[r].id=t.target.value;e.dirty=true;e.cleanupOptions()}}),o("verdocs-text-input",{value:t.label,placeholder:"Display label",onInput:function(t){e.options[r].label=t.target.value;e.dirty=true;e.cleanupOptions()}}),o("button",{innerHTML:q,class:"remove-button",onClick:function(){e.options=e.options.filter((function(e){return e.id!==t.id}));e.dirty=true;e.cleanupOptions()}}))}))),o("div",{class:"buttons"},o("button",{class:"delete-button",disabled:this.dirty,onClick:function(t){return e.handleDelete(t)},innerHTML:q}),o("div",{style:{flex:"1"}}),o("verdocs-button",{size:"small",variant:"outline",label:"Cancel",disabled:!this.dirty,onClick:function(t){return e.handleCancel(t)}}),o("verdocs-button",{size:"small",label:"Save",disabled:s,onClick:function(t){return!s&&e.handleSave(t)}}))))};Object.defineProperty(e.prototype,"el",{get:function(){return s(this)},enumerable:false,configurable:true});return e}());T.style=E}}}));
@@ -1 +1 @@
1
- import{r,h as o,H as e}from"./p-5207d80c.js";const a=class{constructor(o){r(this,o),this.tags=void 0}render(){var r;return o(e,{key:"2abee2130a12d5165984e025633f419082d02714"},null===(r=this.tags)||void 0===r?void 0:r.map((r=>o("span",null,r))))}};a.style='@-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-tags{font-family:"Inter", "Barlow", sans-serif}verdocs-template-tags span{margin:0 4px;height:28px;font-size:12px;font-weight:600;padding:5px 12px 7px;border-radius:5px;display:inline-block;-webkit-box-sizing:border-box;box-sizing:border-box;text-transform:uppercase;color:#33364b;border:1px solid #707ae5;background-color:#f5f5fa}';export{a as verdocs_template_tags}
1
+ import{r,h as o,H as e}from"./p-5207d80c.js";const a=class{constructor(o){r(this,o),this.tags=void 0}render(){var r;return o(e,{key:"8d6457fdcd02cee93906ee2ba5c59c0780d69dc8"},null===(r=this.tags)||void 0===r?void 0:r.map((r=>o("span",null,r))))}};a.style='@-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-tags{font-family:"Inter", "Barlow", sans-serif}verdocs-template-tags span{margin:0 4px;height:28px;font-size:12px;font-weight:600;padding:5px 12px 7px;border-radius:5px;display:inline-block;-webkit-box-sizing:border-box;box-sizing:border-box;text-transform:uppercase;color:#33364b;border:1px solid #707ae5;background-color:#f5f5fa}';export{a as verdocs_template_tags}
@@ -1 +1 @@
1
- var __awaiter=this&&this.__awaiter||function(t,e,r,n){function i(t){return t instanceof r?t:new r((function(e){e(t)}))}return new(r||(r=Promise))((function(r,o){function a(t){try{c(n.next(t))}catch(t){o(t)}}function s(t){try{c(n["throw"](t))}catch(t){o(t)}}function c(t){t.done?r(t.value):i(t.value).then(a,s)}c((n=n.apply(t,e||[])).next())}))};var __generator=this&&this.__generator||function(t,e){var r={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},n,i,o,a;return a={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(a[Symbol.iterator]=function(){return this}),a;function s(t){return function(e){return c([t,e])}}function c(s){if(n)throw new TypeError("Generator is already executing.");while(a&&(a=0,s[0]&&(r=0)),r)try{if(n=1,i&&(o=s[0]&2?i["return"]:s[0]?i["throw"]||((o=i["return"])&&o.call(i),0):i.next)&&!(o=o.call(i,s[1])).done)return o;if(i=0,o)s=[s[0]&2,o.value];switch(s[0]){case 0:case 1:o=s;break;case 4:r.label++;return{value:s[1],done:false};case 5:r.label++;i=s[1];s=[0];continue;case 7:s=r.ops.pop();r.trys.pop();continue;default:if(!(o=r.trys,o=o.length>0&&o[o.length-1])&&(s[0]===6||s[0]===2)){r=0;continue}if(s[0]===3&&(!o||s[1]>o[0]&&s[1]<o[3])){r.label=s[1];break}if(s[0]===6&&r.label<o[1]){r.label=o[1];o=s;break}if(o&&r.label<o[2]){r.label=o[2];r.ops.push(s);break}if(o[2])r.ops.pop();r.trys.pop();continue}s=e.call(t,r)}catch(t){s=[6,t];i=0}finally{n=o=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:true}}};System.register(["./p-59073837.system.js","@verdocs/js-sdk"],(function(t){"use strict";var e,r,n,i,o,a;return{setters:[function(t){e=t.r;r=t.c;n=t.h;i=t.H},function(t){o=t.VerdocsEndpoint;a=t.toggleStar}],execute:function(){var s='@-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-star{display:-ms-flexbox;display:flex;-ms-flex:0 0 60px;flex:0 0 60px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;font-family:"Inter", "Barlow", sans-serif}verdocs-template-star .star{line-height:10px}verdocs-template-star .star.updating{-webkit-animation:spinningStar 2s infinite linear;animation:spinningStar 2s infinite linear}verdocs-template-star .star svg{width:24px;height:24px}verdocs-template-star .count{color:#595c5d;font-size:14px;margin-left:10px}@-webkit-keyframes spinningStar{from{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes spinningStar{from{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}';var c=s;var f='<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" d="M11.48 3.499a.562.562 0 011.04 0l2.125 5.111a.563.563 0 00.475.345l5.518.442c.499.04.701.663.321.988l-4.204 3.602a.563.563 0 00-.182.557l1.285 5.385a.562.562 0 01-.84.61l-4.725-2.885a.563.563 0 00-.586 0L6.982 20.54a.562.562 0 01-.84-.61l1.285-5.386a.562.562 0 00-.182-.557l-4.204-3.602a.563.563 0 01.321-.988l5.518-.442a.563.563 0 00.475-.345L11.48 3.5z" /></svg>';var l='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M10.788 3.21c.448-1.077 1.976-1.077 2.424 0l2.082 5.007 5.404.433c1.164.093 1.636 1.545.749 2.305l-4.117 3.527 1.257 5.273c.271 1.136-.964 2.033-1.96 1.425L12 18.354 7.373 21.18c-.996.608-2.231-.29-1.96-1.425l1.257-5.273-4.117-3.527c-.887-.76-.415-2.212.749-2.305l5.404-.433 2.082-5.006z" clip-rule="evenodd" /></svg>';var u=t("verdocs_template_star",function(){function t(t){e(this,t);this.starChange=r(this,"starChange",7);this.sdkError=r(this,"sdkError",7);this.endpoint=o.getDefault();this.template=undefined;this.updating=false}t.prototype.componentWillLoad=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.endpoint.loadSession();if(!this.endpoint.session){console.log("[TEMPLATES] Must be authenticated");return[2]}return[2]}))}))};t.prototype.toggle=function(t){var e=this;t.stopPropagation();this.updating=true;a(o.getDefault(),this.template.id).then((function(t){e.updating=false;e.template.star_counter=t.star_counter;e.starChange.emit({templateId:e.template.id,starred:t.star_counter>0,count:t.star_counter})})).catch((function(t){e.updating=false;console.log("[STAR] Error toggling template star",t.message);e.sdkError.emit(t)}))};t.prototype.render=function(){var t=this;return n(i,{key:"3bf76e18041a195c1bf050776cd465f7afde3c37"},n("div",{key:"566edf26b382ce4b758571f6470d1ac873d1e0b6",class:"star ".concat(this.updating?"updating":""),innerHTML:this.template.star_counter?l:f,onClick:function(e){return t.toggle(e)}}),n("div",{key:"602436f5d52db7118af35deccb264ccb331d1b72",class:"count"},this.template.star_counter||"--"))};return t}());u.style=c}}}));
1
+ var __awaiter=this&&this.__awaiter||function(t,e,r,n){function i(t){return t instanceof r?t:new r((function(e){e(t)}))}return new(r||(r=Promise))((function(r,a){function o(t){try{c(n.next(t))}catch(t){a(t)}}function s(t){try{c(n["throw"](t))}catch(t){a(t)}}function c(t){t.done?r(t.value):i(t.value).then(o,s)}c((n=n.apply(t,e||[])).next())}))};var __generator=this&&this.__generator||function(t,e){var r={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,i,a,o;return o={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(t){return function(e){return c([t,e])}}function c(s){if(n)throw new TypeError("Generator is already executing.");while(o&&(o=0,s[0]&&(r=0)),r)try{if(n=1,i&&(a=s[0]&2?i["return"]:s[0]?i["throw"]||((a=i["return"])&&a.call(i),0):i.next)&&!(a=a.call(i,s[1])).done)return a;if(i=0,a)s=[s[0]&2,a.value];switch(s[0]){case 0:case 1:a=s;break;case 4:r.label++;return{value:s[1],done:false};case 5:r.label++;i=s[1];s=[0];continue;case 7:s=r.ops.pop();r.trys.pop();continue;default:if(!(a=r.trys,a=a.length>0&&a[a.length-1])&&(s[0]===6||s[0]===2)){r=0;continue}if(s[0]===3&&(!a||s[1]>a[0]&&s[1]<a[3])){r.label=s[1];break}if(s[0]===6&&r.label<a[1]){r.label=a[1];a=s;break}if(a&&r.label<a[2]){r.label=a[2];r.ops.push(s);break}if(a[2])r.ops.pop();r.trys.pop();continue}s=e.call(t,r)}catch(t){s=[6,t];i=0}finally{n=a=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:true}}};System.register(["./p-59073837.system.js","@verdocs/js-sdk"],(function(t){"use strict";var e,r,n,i,a,o;return{setters:[function(t){e=t.r;r=t.c;n=t.h;i=t.H},function(t){a=t.VerdocsEndpoint;o=t.toggleStar}],execute:function(){var s='@-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-star{display:-ms-flexbox;display:flex;-ms-flex:0 0 60px;flex:0 0 60px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;font-family:"Inter", "Barlow", sans-serif}verdocs-template-star .star{line-height:10px}verdocs-template-star .star.updating{-webkit-animation:spinningStar 2s infinite linear;animation:spinningStar 2s infinite linear}verdocs-template-star .star svg{width:24px;height:24px}verdocs-template-star .count{color:#595c5d;font-size:14px;margin-left:10px}@-webkit-keyframes spinningStar{from{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes spinningStar{from{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}';var c=s;var f='<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" d="M11.48 3.499a.562.562 0 011.04 0l2.125 5.111a.563.563 0 00.475.345l5.518.442c.499.04.701.663.321.988l-4.204 3.602a.563.563 0 00-.182.557l1.285 5.385a.562.562 0 01-.84.61l-4.725-2.885a.563.563 0 00-.586 0L6.982 20.54a.562.562 0 01-.84-.61l1.285-5.386a.562.562 0 00-.182-.557l-4.204-3.602a.563.563 0 01.321-.988l5.518-.442a.563.563 0 00.475-.345L11.48 3.5z" /></svg>';var l='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M10.788 3.21c.448-1.077 1.976-1.077 2.424 0l2.082 5.007 5.404.433c1.164.093 1.636 1.545.749 2.305l-4.117 3.527 1.257 5.273c.271 1.136-.964 2.033-1.96 1.425L12 18.354 7.373 21.18c-.996.608-2.231-.29-1.96-1.425l1.257-5.273-4.117-3.527c-.887-.76-.415-2.212.749-2.305l5.404-.433 2.082-5.006z" clip-rule="evenodd" /></svg>';var u=t("verdocs_template_star",function(){function t(t){e(this,t);this.starChange=r(this,"starChange",7);this.sdkError=r(this,"sdkError",7);this.endpoint=a.getDefault();this.template=undefined;this.updating=false}t.prototype.componentWillLoad=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.endpoint.loadSession();if(!this.endpoint.session){console.log("[TEMPLATES] Must be authenticated");return[2]}return[2]}))}))};t.prototype.toggle=function(t){var e=this;t.stopPropagation();this.updating=true;o(a.getDefault(),this.template.id).then((function(t){e.updating=false;e.template.star_counter=t.star_counter;e.starChange.emit({templateId:e.template.id,starred:t.star_counter>0,count:t.star_counter})})).catch((function(t){e.updating=false;console.log("[STAR] Error toggling template star",t.message);e.sdkError.emit(t)}))};t.prototype.render=function(){var t=this;return n(i,{key:"adb2581eccc56b94ef7f8cbfeb9108b336abda86"},n("div",{key:"38a6a2196a7f84325c6dc21c7788d5fd977760e1",class:"star ".concat(this.updating?"updating":""),innerHTML:this.template.star_counter?l:f,onClick:function(e){return t.toggle(e)}}),n("div",{key:"100cbca2df2d3d31acce78c7dec72444e35a191a",class:"count"},this.template.star_counter||"--"))};return t}());u.style=c}}}));
@@ -1 +1 @@
1
- var __awaiter=this&&this.__awaiter||function(e,r,t,n){function i(e){return e instanceof t?e:new t((function(r){r(e)}))}return new(t||(t=Promise))((function(t,a){function o(e){try{u(n.next(e))}catch(e){a(e)}}function s(e){try{u(n["throw"](e))}catch(e){a(e)}}function u(e){e.done?t(e.value):i(e.value).then(o,s)}u((n=n.apply(e,r||[])).next())}))};var __generator=this&&this.__generator||function(e,r){var t={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,i,a,o;return o={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(e){return function(r){return u([e,r])}}function u(s){if(n)throw new TypeError("Generator is already executing.");while(o&&(o=0,s[0]&&(t=0)),t)try{if(n=1,i&&(a=s[0]&2?i["return"]:s[0]?i["throw"]||((a=i["return"])&&a.call(i),0):i.next)&&!(a=a.call(i,s[1])).done)return a;if(i=0,a)s=[s[0]&2,a.value];switch(s[0]){case 0:case 1:a=s;break;case 4:t.label++;return{value:s[1],done:false};case 5:t.label++;i=s[1];s=[0];continue;case 7:s=t.ops.pop();t.trys.pop();continue;default:if(!(a=t.trys,a=a.length>0&&a[a.length-1])&&(s[0]===6||s[0]===2)){t=0;continue}if(s[0]===3&&(!a||s[1]>a[0]&&s[1]<a[3])){t.label=s[1];break}if(s[0]===6&&t.label<a[1]){t.label=a[1];a=s;break}if(a&&t.label<a[2]){t.label=a[2];t.ops.push(s);break}if(a[2])t.ops.pop();t.trys.pop();continue}s=r.call(e,t)}catch(e){s=[6,e];i=0}finally{n=a=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(e,r,t){if(t||arguments.length===2)for(var n=0,i=r.length,a;n<i;n++){if(a||!(n in r)){if(!a)a=Array.prototype.slice.call(r,0,n);a[n]=r[n]}}return e.concat(a||Array.prototype.slice.call(r))};System.register(["./p-38778553.system.js","@verdocs/js-sdk","./p-701b9cbd.system.js","./p-38c6897c.system.js","./p-f5064e0c.system.js"],(function(e){"use strict";var r,t,n,i,a,o,s;return{setters:[function(e){r=e.c},function(e){t=e.getTemplate},function(e){n=e.c;i=e.g},function(e){a=e.c;o=e.g},function(e){s=e.u}],execute:function(){var u=this;var c=function(e){var t=(new Date).toISOString();return r({isLoading:true,isLoaded:false,isError:false,error:null,roleNames:[],id:e,name:"",description:"",sender:"creator",profile_id:"",organization_id:"",counter:0,star_counter:0,is_sendable:false,is_personal:true,is_public:false,created_at:t,updated_at:t,last_used_at:t,initial_reminder:0,followup_reminders:0,organization:null,roles:[],data:{},documents:[],fields:[],profile:null,search_key:"",tags:[],pages:[]})};var f={};var l=e("g",(function(e,r){var l=[];for(var d=2;d<arguments.length;d++){l[d-2]=arguments[d]}return __awaiter(u,__spreadArray([e,r],l,true),void 0,(function(e,r,u){var l,d,_,p,v;if(u===void 0){u=false}return __generator(this,(function(h){switch(h.label){case 0:d=false;if(!f[r]){console.debug("[TEMPLATES] No template store found for ID, creating",r);f[r]=c(r);d=true}_=f[r];if(!(d||u))return[3,5];console.debug("[TEMPLATES] Loading template",{templateId:r,created:d,forceReload:u});_.state.isLoading=true;_.state.isLoaded=false;_.state.isError=false;_.state.error=s;h.label=1;case 1:h.trys.push([1,3,,4]);return[4,t(e,r)];case 2:p=h.sent();if(!p.documents&&p.template_documents){p.documents=p.template_documents}(l=p.documents)===null||l===void 0?void 0:l.forEach((function(e){if(!e.order){e.order=0}if(e.page_numbers){e.pages=e.page_numbers}}));console.debug("[TEMPLATES] Got template",p);Object.assign(_.state,p);_.state.isLoaded=true;_.state.isError=false;_.state.error=s;n(p);a(p);return[3,4];case 3:v=h.sent();console.error("[TEMPLATES] Error loading template",v);_.state.isLoaded=false;_.state.isError=true;_.state.error=v;throw v;case 4:_.state.isLoading=false;return[3,6];case 5:i(r);o(r);h.label=6;case 6:return[2,_]}}))}))}))}}}));
1
+ var __awaiter=this&&this.__awaiter||function(e,r,t,n){function i(e){return e instanceof t?e:new t((function(r){r(e)}))}return new(t||(t=Promise))((function(t,a){function o(e){try{u(n.next(e))}catch(e){a(e)}}function s(e){try{u(n["throw"](e))}catch(e){a(e)}}function u(e){e.done?t(e.value):i(e.value).then(o,s)}u((n=n.apply(e,r||[])).next())}))};var __generator=this&&this.__generator||function(e,r){var t={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,i,a,o;return o={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(e){return function(r){return u([e,r])}}function u(s){if(n)throw new TypeError("Generator is already executing.");while(o&&(o=0,s[0]&&(t=0)),t)try{if(n=1,i&&(a=s[0]&2?i["return"]:s[0]?i["throw"]||((a=i["return"])&&a.call(i),0):i.next)&&!(a=a.call(i,s[1])).done)return a;if(i=0,a)s=[s[0]&2,a.value];switch(s[0]){case 0:case 1:a=s;break;case 4:t.label++;return{value:s[1],done:false};case 5:t.label++;i=s[1];s=[0];continue;case 7:s=t.ops.pop();t.trys.pop();continue;default:if(!(a=t.trys,a=a.length>0&&a[a.length-1])&&(s[0]===6||s[0]===2)){t=0;continue}if(s[0]===3&&(!a||s[1]>a[0]&&s[1]<a[3])){t.label=s[1];break}if(s[0]===6&&t.label<a[1]){t.label=a[1];a=s;break}if(a&&t.label<a[2]){t.label=a[2];t.ops.push(s);break}if(a[2])t.ops.pop();t.trys.pop();continue}s=r.call(e,t)}catch(e){s=[6,e];i=0}finally{n=a=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(e,r,t){if(t||arguments.length===2)for(var n=0,i=r.length,a;n<i;n++){if(a||!(n in r)){if(!a)a=Array.prototype.slice.call(r,0,n);a[n]=r[n]}}return e.concat(a||Array.prototype.slice.call(r))};System.register(["./p-38778553.system.js","@verdocs/js-sdk","./p-701b9cbd.system.js","./p-38c6897c.system.js","./p-f5064e0c.system.js"],(function(e){"use strict";var r,t,n,i,a,o,s;return{setters:[function(e){r=e.c},function(e){t=e.getTemplate},function(e){n=e.c;i=e.g},function(e){a=e.c;o=e.g},function(e){s=e.u}],execute:function(){var u=this;var c=function(e){var t=(new Date).toISOString();return r({isLoading:true,isLoaded:false,isError:false,error:null,roleNames:[],id:e,name:"",description:"",sender:"envelope_creator",profile_id:"",organization_id:"",counter:0,star_counter:0,is_sendable:false,is_personal:true,is_public:false,created_at:t,updated_at:t,last_used_at:t,initial_reminder:0,followup_reminders:0,organization:null,roles:[],data:{},documents:[],fields:[],profile:null,search_key:"",tags:[],pages:[]})};var f={};var l=e("g",(function(e,r){var l=[];for(var d=2;d<arguments.length;d++){l[d-2]=arguments[d]}return __awaiter(u,__spreadArray([e,r],l,true),void 0,(function(e,r,u){var l,d,_,p,v;if(u===void 0){u=false}return __generator(this,(function(h){switch(h.label){case 0:d=false;if(!f[r]){console.debug("[TEMPLATES] No template store found for ID, creating",r);f[r]=c(r);d=true}_=f[r];if(!(d||u))return[3,5];console.debug("[TEMPLATES] Loading template",{templateId:r,created:d,forceReload:u});_.state.isLoading=true;_.state.isLoaded=false;_.state.isError=false;_.state.error=s;h.label=1;case 1:h.trys.push([1,3,,4]);return[4,t(e,r)];case 2:p=h.sent();if(!p.documents&&p.template_documents){p.documents=p.template_documents}(l=p.documents)===null||l===void 0?void 0:l.forEach((function(e){if(!e.order){e.order=0}if(e.page_numbers){e.pages=e.page_numbers}}));console.debug("[TEMPLATES] Got template",p);Object.assign(_.state,p);_.state.isLoaded=true;_.state.isError=false;_.state.error=s;n(p);a(p);return[3,4];case 3:v=h.sent();console.error("[TEMPLATES] Error loading template",v);_.state.isLoaded=false;_.state.isError=true;_.state.error=v;throw v;case 4:_.state.isLoading=false;return[3,6];case 5:i(r);o(r);h.label=6;case 6:return[2,_]}}))}))}))}}}));
@@ -0,0 +1 @@
1
+ System.register(["./p-59073837.system.js"],(function(o){"use strict";var e,t,r;return{setters:[function(o){e=o.r;t=o.h;r=o.H}],execute:function(){var i='@-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-radio-button{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif;width:20px;height:20px;display:block;font-size:11px;position:relative;background-color:transparent;-webkit-transform-origin:bottom left;transform-origin:bottom left;border-radius:100%}verdocs-radio-button.disabled{opacity:0.5}verdocs-radio-button input[type=radio]{position:absolute;opacity:0}verdocs-radio-button input[type=radio]+label:before{content:"";background:#f5f5fa;border-radius:100%;border:1px solid rgba(0, 0, 0, 0.6);display:inline-block;width:16px;height:16px;position:absolute;left:1px;top:1px;cursor:pointer;text-align:center;-webkit-transition:all 250ms ease;transition:all 250ms ease}verdocs-radio-button input[type=radio]:checked+label:before{background-color:#55bc81;-webkit-box-shadow:inset 0 0 0 2px #f5f5fa;box-shadow:inset 0 0 0 2px #f5f5fa}verdocs-radio-button input[type=radio]:focus+label:before{outline:none;border-color:#55bc81}verdocs-radio-button input[type=radio]:disabled+label:before{-webkit-box-shadow:inset 0 0 0 4px #f5f5fa;box-shadow:inset 0 0 0 4px #f5f5fa;border-color:#a0a0d0;background:#a0a0d0}verdocs-radio-button input[type=radio]+label:empty:before{margin-right:0}verdocs-radio-button.required input[type=radio]+label:before{border:1px solid #cc0000}verdocs-radio-button.hide{display:none}verdocs-radio-button.focused{-webkit-animation:verdocs-field-pulse 0.75s 2;animation:verdocs-field-pulse 0.75s 2}';var a=i;var d=o("verdocs_radio_button",function(){function o(o){e(this,o);this.checked=false;this.name="";this.value="";this.disabled=false}o.prototype.render=function(){return t(r,{key:"b8dc5d8e34deeaf6d67f8b38bcf485a66e6fe8c8",class:{disabled:this.disabled}},t("input",{key:"5e03859b9d3082add93aeba0eb626d8f41988f1c",type:"radio",value:this.value,name:this.name,id:"verdocs-radio-button-".concat(this.name,"-").concat(this.value),checked:this.checked,disabled:this.disabled}),t("label",{key:"4caa876b9138003b5ff7d576fdc32fcf62858bca",htmlFor:"verdocs-radio-button-".concat(this.name,"-").concat(this.value)}))};return o}());d.style=a}}}));