@verdocs/web-sdk 6.10.6 → 6.12.1

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 (208) hide show
  1. package/dist/cjs/Environment-C3P2cz0J.js +14 -0
  2. package/dist/cjs/Environment-C3P2cz0J.js.map +1 -0
  3. package/dist/cjs/{Icons-TVvtZ5iL.js → Icons-Zdy_DFce.js} +16 -2
  4. package/dist/cjs/{Icons-TVvtZ5iL.js.map → Icons-Zdy_DFce.js.map} +1 -1
  5. package/dist/cjs/loader.cjs.js +1 -1
  6. package/dist/cjs/verdocs-adopt-signature-dialog_7.cjs.entry.js +2 -2
  7. package/dist/cjs/verdocs-auth.cjs.entry.js +271 -15
  8. package/dist/cjs/verdocs-auth.cjs.entry.js.map +1 -1
  9. package/dist/cjs/verdocs-contact-picker.cjs.entry.js +12 -14
  10. package/dist/cjs/verdocs-contact-picker.cjs.entry.js.map +1 -1
  11. package/dist/cjs/verdocs-field-attachment_11.cjs.entry.js +1 -1
  12. package/dist/cjs/verdocs-field-payment.cjs.entry.js +1 -1
  13. package/dist/cjs/verdocs-file-chooser_2.cjs.entry.js +1 -1
  14. package/dist/cjs/verdocs-preview_6.cjs.entry.js +2 -2
  15. package/dist/cjs/verdocs-sign.cjs.entry.js +1 -1
  16. package/dist/cjs/verdocs-template-document-page_2.cjs.entry.js +1 -1
  17. package/dist/cjs/verdocs-template-document-page_2.cjs.entry.js.map +1 -1
  18. package/dist/cjs/verdocs-web-sdk.cjs.js +1 -1
  19. package/dist/collection/components/controls/verdocs-toolbar-icon/verdocs-toolbar-icon.css +2 -1
  20. package/dist/collection/components/embeds/verdocs-auth/verdocs-auth.css +45 -1
  21. package/dist/collection/components/embeds/verdocs-auth/verdocs-auth.js +302 -19
  22. package/dist/collection/components/embeds/verdocs-auth/verdocs-auth.js.map +1 -1
  23. package/dist/collection/components/envelopes/verdocs-contact-picker/verdocs-contact-picker.js +12 -14
  24. package/dist/collection/components/envelopes/verdocs-contact-picker/verdocs-contact-picker.js.map +1 -1
  25. package/dist/collection/utils/Environment.js +4 -7
  26. package/dist/collection/utils/Environment.js.map +1 -1
  27. package/dist/collection/utils/Icons.js +12 -0
  28. package/dist/collection/utils/Icons.js.map +1 -1
  29. package/dist/components/{p-DCZz2B7h.js → p-6RWROB9R.js} +2 -2
  30. package/dist/components/p-6RWROB9R.js.map +1 -0
  31. package/dist/components/{p-i3o08M2d.js → p-B1UVXqFA.js} +2 -2
  32. package/dist/components/{p-bPe0_Dsn.js → p-B8R4luxA.js} +2 -2
  33. package/dist/components/{p-D-TexkaT.js → p-BXaR1BSS.js} +2 -2
  34. package/dist/components/{p-DL4-aTsZ.js → p-BYLm9aol.js} +2 -2
  35. package/dist/components/{p-DiYuPnJJ.js → p-Bp88Loqg.js} +2 -2
  36. package/dist/components/{p-C43B3SP_.js → p-C7JN32A9.js} +2 -2
  37. package/dist/components/{p-BDv5kBUR.js → p-C7k2AOsW.js} +2 -2
  38. package/dist/components/p-C7k2AOsW.js.map +1 -0
  39. package/dist/components/{p-DKKsPZnz.js → p-CCr_gliS.js} +2 -2
  40. package/dist/components/{p-BELGzhZw.js → p-CFau7OiC.js} +2 -2
  41. package/dist/components/{p-zTcSNwsp.js → p-Ck4pdoyc.js} +2 -2
  42. package/dist/components/{p-DZa0rMk2.js → p-CsF979IT.js} +2 -2
  43. package/dist/components/{p-CYvB5bYX.js → p-CtNpZzq1.js} +2 -2
  44. package/dist/components/{p-B6aUlIQe.js → p-CzKj8wD_.js} +2 -2
  45. package/dist/components/{p-DiwfOWXt.js → p-DJMr11ue.js} +2 -2
  46. package/dist/components/{p-CZwyK_uo.js → p-DLo5dMNn.js} +2 -2
  47. package/dist/components/{p-D1cSgqut.js → p-D_FNSGtS.js} +2 -2
  48. package/dist/components/p-DavVixMP.js +2 -0
  49. package/dist/components/p-DavVixMP.js.map +1 -0
  50. package/dist/components/{p-K_PKw6bs.js → p-DmxiVavg.js} +2 -2
  51. package/dist/components/{p-D7oMWhqM.js → p-DrNmI7Wz.js} +2 -2
  52. package/dist/components/{p-DfIxVX8-.js → p-DubfX0n1.js} +2 -2
  53. package/dist/components/{p-Dy2CRiH8.js → p-b2u0_wDk.js} +1 -1
  54. package/dist/components/p-b2u0_wDk.js.map +1 -0
  55. package/dist/components/{p-CAGp0qKc.js → p-hxWwaOcD.js} +2 -2
  56. package/dist/components/{p-BQUZjuoP.js → p-vcHtLpWY.js} +2 -2
  57. package/dist/components/verdocs-adopt-signature-dialog.js +1 -1
  58. package/dist/components/verdocs-auth.js +1 -1
  59. package/dist/components/verdocs-auth.js.map +1 -1
  60. package/dist/components/verdocs-build.js +1 -1
  61. package/dist/components/verdocs-contact-picker.js +1 -1
  62. package/dist/components/verdocs-delegate-dialog.js +1 -1
  63. package/dist/components/verdocs-field-attachment.js +1 -1
  64. package/dist/components/verdocs-field-checkbox.js +1 -1
  65. package/dist/components/verdocs-field-date.js +1 -1
  66. package/dist/components/verdocs-field-dropdown.js +1 -1
  67. package/dist/components/verdocs-field-initial.js +1 -1
  68. package/dist/components/verdocs-field-payment.js +1 -1
  69. package/dist/components/verdocs-field-radio.js +1 -1
  70. package/dist/components/verdocs-field-signature.js +1 -1
  71. package/dist/components/verdocs-field-textarea.js +1 -1
  72. package/dist/components/verdocs-field-textbox.js +1 -1
  73. package/dist/components/verdocs-field-timestamp.js +1 -1
  74. package/dist/components/verdocs-file-chooser.js +1 -1
  75. package/dist/components/verdocs-otp-dialog.js +1 -1
  76. package/dist/components/verdocs-passcode-dialog.js +1 -1
  77. package/dist/components/verdocs-preview.js +1 -1
  78. package/dist/components/verdocs-send.js +1 -1
  79. package/dist/components/verdocs-sign.js +1 -1
  80. package/dist/components/verdocs-template-attachments.js +1 -1
  81. package/dist/components/verdocs-template-document-page.js +1 -1
  82. package/dist/components/verdocs-template-fields.js +1 -1
  83. package/dist/components/verdocs-toolbar-icon.js +1 -1
  84. package/dist/custom-elements.json +2508 -0
  85. package/dist/esm/Environment-b2u0_wDk.js +12 -0
  86. package/dist/esm/Environment-b2u0_wDk.js.map +1 -0
  87. package/dist/esm/{Icons-BU5rnXp2.js → Icons-DobS6Y7w.js} +15 -3
  88. package/dist/esm/{Icons-BU5rnXp2.js.map → Icons-DobS6Y7w.js.map} +1 -1
  89. package/dist/esm/loader.js +1 -1
  90. package/dist/esm/verdocs-adopt-signature-dialog_7.entry.js +2 -2
  91. package/dist/esm/verdocs-auth.entry.js +273 -17
  92. package/dist/esm/verdocs-auth.entry.js.map +1 -1
  93. package/dist/esm/verdocs-contact-picker.entry.js +12 -14
  94. package/dist/esm/verdocs-contact-picker.entry.js.map +1 -1
  95. package/dist/esm/verdocs-field-attachment_11.entry.js +1 -1
  96. package/dist/esm/verdocs-field-payment.entry.js +1 -1
  97. package/dist/esm/verdocs-file-chooser_2.entry.js +1 -1
  98. package/dist/esm/verdocs-preview_6.entry.js +2 -2
  99. package/dist/esm/verdocs-sign.entry.js +1 -1
  100. package/dist/esm/verdocs-template-document-page_2.entry.js +1 -1
  101. package/dist/esm/verdocs-template-document-page_2.entry.js.map +1 -1
  102. package/dist/esm/verdocs-web-sdk.js +1 -1
  103. package/dist/esm-es5/{Environment-Dy2CRiH8.js → Environment-b2u0_wDk.js} +1 -1
  104. package/dist/esm-es5/Environment-b2u0_wDk.js.map +1 -0
  105. package/dist/esm-es5/{Icons-BU5rnXp2.js → Icons-DobS6Y7w.js} +2 -2
  106. package/dist/esm-es5/{Icons-BU5rnXp2.js.map → Icons-DobS6Y7w.js.map} +1 -1
  107. package/dist/esm-es5/loader.js +1 -1
  108. package/dist/esm-es5/verdocs-adopt-signature-dialog_7.entry.js +1 -1
  109. package/dist/esm-es5/verdocs-auth.entry.js +1 -1
  110. package/dist/esm-es5/verdocs-auth.entry.js.map +1 -1
  111. package/dist/esm-es5/verdocs-contact-picker.entry.js +1 -1
  112. package/dist/esm-es5/verdocs-contact-picker.entry.js.map +1 -1
  113. package/dist/esm-es5/verdocs-field-attachment_11.entry.js +1 -1
  114. package/dist/esm-es5/verdocs-field-payment.entry.js +1 -1
  115. package/dist/esm-es5/verdocs-file-chooser_2.entry.js +1 -1
  116. package/dist/esm-es5/verdocs-preview_6.entry.js +1 -1
  117. package/dist/esm-es5/verdocs-sign.entry.js +1 -1
  118. package/dist/esm-es5/verdocs-template-document-page_2.entry.js +1 -1
  119. package/dist/esm-es5/verdocs-template-document-page_2.entry.js.map +1 -1
  120. package/dist/esm-es5/verdocs-web-sdk.js +1 -1
  121. package/dist/types/components/embeds/verdocs-auth/verdocs-auth.d.ts +31 -3
  122. package/dist/types/components.d.ts +18 -7
  123. package/dist/types/utils/Icons.d.ts +2 -0
  124. package/dist/verdocs-web-sdk/{p-869024e0.system.entry.js → p-09f5670e.system.entry.js} +2 -2
  125. package/dist/verdocs-web-sdk/p-0fb8e6e0.system.entry.js +2 -0
  126. package/dist/verdocs-web-sdk/p-0fb8e6e0.system.entry.js.map +1 -0
  127. package/dist/verdocs-web-sdk/{p-e87a29a3.system.entry.js → p-298d799f.system.entry.js} +3 -3
  128. package/dist/verdocs-web-sdk/{p-734c8a8b.entry.js → p-2a6a3bc6.entry.js} +2 -2
  129. package/dist/verdocs-web-sdk/{p-46e52384.system.entry.js → p-39c54b65.system.entry.js} +2 -2
  130. package/dist/verdocs-web-sdk/p-39c54b65.system.entry.js.map +1 -0
  131. package/dist/verdocs-web-sdk/{p-62464041.system.entry.js → p-439d36b0.system.entry.js} +2 -2
  132. package/dist/verdocs-web-sdk/{p-d95705c6.entry.js → p-4930b31d.entry.js} +2 -2
  133. package/dist/verdocs-web-sdk/{p-255e1915.entry.js → p-4e0788f9.entry.js} +2 -2
  134. package/dist/verdocs-web-sdk/p-4e0788f9.entry.js.map +1 -0
  135. package/dist/verdocs-web-sdk/{p-c6f52cd7.entry.js → p-4ea0632f.entry.js} +2 -2
  136. package/dist/verdocs-web-sdk/{p-c6f52cd7.entry.js.map → p-4ea0632f.entry.js.map} +1 -1
  137. package/dist/verdocs-web-sdk/{p-c86111fd.system.entry.js → p-5404f6bf.system.entry.js} +2 -2
  138. package/dist/verdocs-web-sdk/{p-10d47bbd.entry.js → p-5cad2422.entry.js} +2 -2
  139. package/dist/verdocs-web-sdk/{p-4aee15e6.entry.js → p-932e8b9b.entry.js} +2 -2
  140. package/dist/verdocs-web-sdk/{p-6e8ce989.system.entry.js → p-99f7a0fa.system.entry.js} +2 -2
  141. package/dist/verdocs-web-sdk/{p-GqS1qR-V.system.js → p-BHF3ByWV.system.js} +2 -2
  142. package/dist/verdocs-web-sdk/{p-GqS1qR-V.system.js.map → p-BHF3ByWV.system.js.map} +1 -1
  143. package/dist/verdocs-web-sdk/p-BdZ5Ghsa.system.js +1 -1
  144. package/dist/verdocs-web-sdk/{p-C96xjMgt.system.js → p-COHG5J4h.system.js} +1 -1
  145. package/dist/verdocs-web-sdk/p-COHG5J4h.system.js.map +1 -0
  146. package/dist/verdocs-web-sdk/{p-BU5rnXp2.js → p-DobS6Y7w.js} +2 -2
  147. package/dist/verdocs-web-sdk/{p-BU5rnXp2.js.map → p-DobS6Y7w.js.map} +1 -1
  148. package/dist/verdocs-web-sdk/{p-Dy2CRiH8.js → p-b2u0_wDk.js} +1 -1
  149. package/dist/verdocs-web-sdk/p-b2u0_wDk.js.map +1 -0
  150. package/dist/verdocs-web-sdk/{p-098b3852.system.entry.js → p-ba0d4ff5.system.entry.js} +2 -2
  151. package/dist/verdocs-web-sdk/{p-098b3852.system.entry.js.map → p-ba0d4ff5.system.entry.js.map} +1 -1
  152. package/dist/verdocs-web-sdk/p-c3e9634c.entry.js +2 -0
  153. package/dist/verdocs-web-sdk/p-c3e9634c.entry.js.map +1 -0
  154. package/dist/verdocs-web-sdk/{p-7e1f895c.entry.js → p-dd59aa9a.entry.js} +2 -2
  155. package/dist/verdocs-web-sdk/{p-c3527f3e.system.entry.js → p-f7b14409.system.entry.js} +2 -2
  156. package/dist/verdocs-web-sdk/{p-1df29abb.entry.js → p-fe404347.entry.js} +2 -2
  157. package/dist/verdocs-web-sdk/verdocs-web-sdk.esm.js +1 -1
  158. package/package.json +4 -4
  159. package/dist/cjs/Environment-CUCX3aWX.js +0 -17
  160. package/dist/cjs/Environment-CUCX3aWX.js.map +0 -1
  161. package/dist/components/p-BDv5kBUR.js.map +0 -1
  162. package/dist/components/p-CYqVJ_kJ.js +0 -2
  163. package/dist/components/p-CYqVJ_kJ.js.map +0 -1
  164. package/dist/components/p-DCZz2B7h.js.map +0 -1
  165. package/dist/components/p-Dy2CRiH8.js.map +0 -1
  166. package/dist/esm/Environment-Dy2CRiH8.js +0 -15
  167. package/dist/esm/Environment-Dy2CRiH8.js.map +0 -1
  168. package/dist/esm-es5/Environment-Dy2CRiH8.js.map +0 -1
  169. package/dist/verdocs-web-sdk/p-16d655d4.system.entry.js +0 -2
  170. package/dist/verdocs-web-sdk/p-16d655d4.system.entry.js.map +0 -1
  171. package/dist/verdocs-web-sdk/p-255e1915.entry.js.map +0 -1
  172. package/dist/verdocs-web-sdk/p-43ee0267.entry.js +0 -2
  173. package/dist/verdocs-web-sdk/p-43ee0267.entry.js.map +0 -1
  174. package/dist/verdocs-web-sdk/p-46e52384.system.entry.js.map +0 -1
  175. package/dist/verdocs-web-sdk/p-C96xjMgt.system.js.map +0 -1
  176. package/dist/verdocs-web-sdk/p-Dy2CRiH8.js.map +0 -1
  177. /package/dist/components/{p-i3o08M2d.js.map → p-B1UVXqFA.js.map} +0 -0
  178. /package/dist/components/{p-bPe0_Dsn.js.map → p-B8R4luxA.js.map} +0 -0
  179. /package/dist/components/{p-D-TexkaT.js.map → p-BXaR1BSS.js.map} +0 -0
  180. /package/dist/components/{p-DL4-aTsZ.js.map → p-BYLm9aol.js.map} +0 -0
  181. /package/dist/components/{p-DiYuPnJJ.js.map → p-Bp88Loqg.js.map} +0 -0
  182. /package/dist/components/{p-C43B3SP_.js.map → p-C7JN32A9.js.map} +0 -0
  183. /package/dist/components/{p-DKKsPZnz.js.map → p-CCr_gliS.js.map} +0 -0
  184. /package/dist/components/{p-BELGzhZw.js.map → p-CFau7OiC.js.map} +0 -0
  185. /package/dist/components/{p-zTcSNwsp.js.map → p-Ck4pdoyc.js.map} +0 -0
  186. /package/dist/components/{p-DZa0rMk2.js.map → p-CsF979IT.js.map} +0 -0
  187. /package/dist/components/{p-CYvB5bYX.js.map → p-CtNpZzq1.js.map} +0 -0
  188. /package/dist/components/{p-B6aUlIQe.js.map → p-CzKj8wD_.js.map} +0 -0
  189. /package/dist/components/{p-DiwfOWXt.js.map → p-DJMr11ue.js.map} +0 -0
  190. /package/dist/components/{p-CZwyK_uo.js.map → p-DLo5dMNn.js.map} +0 -0
  191. /package/dist/components/{p-D1cSgqut.js.map → p-D_FNSGtS.js.map} +0 -0
  192. /package/dist/components/{p-K_PKw6bs.js.map → p-DmxiVavg.js.map} +0 -0
  193. /package/dist/components/{p-D7oMWhqM.js.map → p-DrNmI7Wz.js.map} +0 -0
  194. /package/dist/components/{p-DfIxVX8-.js.map → p-DubfX0n1.js.map} +0 -0
  195. /package/dist/components/{p-CAGp0qKc.js.map → p-hxWwaOcD.js.map} +0 -0
  196. /package/dist/components/{p-BQUZjuoP.js.map → p-vcHtLpWY.js.map} +0 -0
  197. /package/dist/verdocs-web-sdk/{p-869024e0.system.entry.js.map → p-09f5670e.system.entry.js.map} +0 -0
  198. /package/dist/verdocs-web-sdk/{p-e87a29a3.system.entry.js.map → p-298d799f.system.entry.js.map} +0 -0
  199. /package/dist/verdocs-web-sdk/{p-734c8a8b.entry.js.map → p-2a6a3bc6.entry.js.map} +0 -0
  200. /package/dist/verdocs-web-sdk/{p-62464041.system.entry.js.map → p-439d36b0.system.entry.js.map} +0 -0
  201. /package/dist/verdocs-web-sdk/{p-d95705c6.entry.js.map → p-4930b31d.entry.js.map} +0 -0
  202. /package/dist/verdocs-web-sdk/{p-c86111fd.system.entry.js.map → p-5404f6bf.system.entry.js.map} +0 -0
  203. /package/dist/verdocs-web-sdk/{p-10d47bbd.entry.js.map → p-5cad2422.entry.js.map} +0 -0
  204. /package/dist/verdocs-web-sdk/{p-4aee15e6.entry.js.map → p-932e8b9b.entry.js.map} +0 -0
  205. /package/dist/verdocs-web-sdk/{p-6e8ce989.system.entry.js.map → p-99f7a0fa.system.entry.js.map} +0 -0
  206. /package/dist/verdocs-web-sdk/{p-7e1f895c.entry.js.map → p-dd59aa9a.entry.js.map} +0 -0
  207. /package/dist/verdocs-web-sdk/{p-c3527f3e.system.entry.js.map → p-f7b14409.system.entry.js.map} +0 -0
  208. /package/dist/verdocs-web-sdk/{p-1df29abb.entry.js.map → p-fe404347.entry.js.map} +0 -0
@@ -1,2 +1,2 @@
1
- var __awaiter=this&&this.__awaiter||function(e,t,s,i){function r(e){return e instanceof s?e:new s((function(t){t(e)}))}return new(s||(s=Promise))((function(s,o){function n(e){try{c(i.next(e))}catch(e){o(e)}}function a(e){try{c(i["throw"](e))}catch(e){o(e)}}function c(e){e.done?s(e.value):r(e.value).then(n,a)}c((i=i.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var s={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},i,r,o,n=Object.create((typeof Iterator==="function"?Iterator:Object).prototype);return n.next=a(0),n["throw"]=a(1),n["return"]=a(2),typeof Symbol==="function"&&(n[Symbol.iterator]=function(){return this}),n;function a(e){return function(t){return c([e,t])}}function c(a){if(i)throw new TypeError("Generator is already executing.");while(n&&(n=0,a[0]&&(s=0)),s)try{if(i=1,r&&(o=a[0]&2?r["return"]:a[0]?r["throw"]||((o=r["return"])&&o.call(r),0):r.next)&&!(o=o.call(r,a[1])).done)return o;if(r=0,o)a=[a[0]&2,o.value];switch(a[0]){case 0:case 1:o=a;break;case 4:s.label++;return{value:a[1],done:false};case 5:s.label++;r=a[1];a=[0];continue;case 7:a=s.ops.pop();s.trys.pop();continue;default:if(!(o=s.trys,o=o.length>0&&o[o.length-1])&&(a[0]===6||a[0]===2)){s=0;continue}if(a[0]===3&&(!o||a[1]>o[0]&&a[1]<o[3])){s.label=a[1];break}if(a[0]===6&&s.label<o[1]){s.label=o[1];o=a;break}if(o&&s.label<o[2]){s.label=o[2];s.ops.push(a);break}if(o[2])s.ops.pop();s.trys.pop();continue}a=t.call(e,s)}catch(e){a=[6,e];r=0}finally{i=o=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:true}}};import{r as registerInstance,c as createEvent,h}from"./index-CjTHbolG.js";import{VerdocsEndpoint,convertToE164,createProfile,verifyEmail,authenticate,getMyUser,resendVerification,resetPassword}from"@verdocs/js-sdk";import{V as VerdocsToast}from"./Toast-D97GxsI-.js";import{S as SDKError}from"./errors-C1sRVZWv.js";var verdocsAuthCss=function(){return'verdocs-auth{font-family:var(--verdocs-primary-font, "Inter", "Barlow", sans-serif);display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center}verdocs-auth .form{width:350px;display:-ms-flexbox;display:flex;padding:20px;max-width:90%;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column;-webkit-box-sizing:border-box;box-sizing:border-box;-ms-flex-pack:center;justify-content:center;background:#ffffff}verdocs-auth .logo{width:128px;max-width:100%;margin:20px 0 30px}verdocs-auth h3{color:#092c4c;text-align:center;font-weight:400;font-size:18px;line-height:1.75;margin:0}verdocs-auth em{font-size:14px;margin:15px 0}verdocs-auth .buttons{gap:20px;margin:20px 0 0 0;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth .status-result{display:none}verdocs-auth .status-result.debug{white-space:pre-wrap;font-size:14px;background:#fff;padding:10px;display:block;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth form{width:100%}verdocs-auth verdocs-text-input{margin-bottom:10px}verdocs-auth .account-option{gap:8px;margin:20px 0 8px 0;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-auth p{color:#092c4c;margin:1em 0;font-size:14px}verdocs-auth p+p{margin-top:0}verdocs-auth verdocs-help-icon{margin-top:18px;display:-ms-flexbox;display:flex;width:32px;height:32px;-ms-flex:0 0 32px;flex:0 0 32px}verdocs-auth .already-have{color:#092c4c;margin:0.5em 0;font-size:14px;text-align:center}verdocs-auth .service-agreement{font-size:12px;color:#777}verdocs-auth .service-agreement a{color:#092c4c}'};var VerdocsAuth=function(){function e(e){var t=this;registerInstance(this,e);this.authenticated=createEvent(this,"authenticated");this.sdkError=createEvent(this,"sdkError");this.endpoint=VerdocsEndpoint.getDefault();this.visible=true;this.logo="https://app.verdocs.com/assets/blue-logo.svg";this.displayMode="login";this.org_name="";this.first_name="";this.last_name="";this.email="";this.phone="";this.verificationCode="";this.newPassword="";this.password="";this.confirmpass="";this.submitting=false;this.resendDisabled=false;this.session=null;this.profile=null;this.resendDisabledTimer=null;this.tempAuthEndpoint=new VerdocsEndpoint({baseURL:VerdocsEndpoint.getDefault().getBaseURL(),persist:false});this.handleHashChange=function(){t.applyHashDisplayMode()}}e.prototype.componentWillLoad=function(){var e=this;this.endpoint.loadSession();this.applyHashDisplayMode();if(typeof window!=="undefined"){window.addEventListener("hashchange",this.handleHashChange)}VerdocsEndpoint.getDefault().onSessionChanged((function(t,s,i){var r,o;e.session=s;e.profile=i;if(s){(r=e.authenticated)===null||r===void 0?void 0:r.emit({authenticated:true,session:s,profile:i})}else{(o=e.authenticated)===null||o===void 0?void 0:o.emit({authenticated:false,session:s,profile:i})}}))};e.prototype.disconnectedCallback=function(){if(typeof window!=="undefined"){window.removeEventListener("hashchange",this.handleHashChange)}};e.prototype.applyHashDisplayMode=function(){if(typeof window==="undefined"){return}var e=(window.location.hash||"").replace(/^#/,"").toLowerCase();if(e==="forgot"){this.displayMode="forgot"}};e.prototype.isPasswordComplex=function(e){var t=function(e){return/[A-Z]/.test(e)};var s=function(e){return/[a-z]/.test(e)};var i=function(e){return/[`!@#$%^&*()_\-+=\[\]{};':"\\|,.<>\/?~ ]/.test(e)};var r=0,o=0,n=0;for(var a=0;a<e.length;a++){var c=e.charAt(a);if(t(c))r++;else if(s(c))o++;else if(i(c))n++}return e.length>=8&&o>0&&r>0&&n>0};e.prototype.handleSignup=function(){var e=this;if(!this.isPasswordComplex(this.password)){VerdocsToast("Password must be at least 8 characters long and contain at least one uppercase, one lowercase, and one special character.",{style:"error"});return}if(this.password!==this.confirmpass){VerdocsToast("Passwords do not match.",{style:"error"});return}this.submitting=true;this.tempAuthEndpoint.clearSession();var t=convertToE164(this.phone);var s=Intl.DateTimeFormat().resolvedOptions();createProfile(this.tempAuthEndpoint,{email:this.email,password:this.password,first_name:this.first_name,last_name:this.last_name,org_name:this.org_name,phone:t,timezone:s.timeZone,locale:s.locale}).then((function(t){console.log("[AUTH] Profile creation result",t);e.tempAuthEndpoint.setToken(t.access_token);e.password="";e.phone="";e.first_name="";e.last_name="";e.org_name="";e.displayMode="verify";e.submitting=false})).catch((function(t){var s,i,r,o,n,a;console.log("[AUTH] Signup error",t.response);e.submitting=false;(s=e.authenticated)===null||s===void 0?void 0:s.emit({authenticated:false,profile:null,session:null});(i=e.sdkError)===null||i===void 0?void 0:i.emit(new SDKError(t.message,(r=t.response)===null||r===void 0?void 0:r.status,(o=t.response)===null||o===void 0?void 0:o.data));VerdocsToast("Signup failed: "+((a=(n=t.response)===null||n===void 0?void 0:n.data)===null||a===void 0?void 0:a.error)||"Unknown Error",{style:"error"})}))};e.prototype.handleVerification=function(){return __awaiter(this,void 0,void 0,(function(){var e,t;return __generator(this,(function(s){switch(s.label){case 0:this.submitting=true;s.label=1;case 1:s.trys.push([1,3,,4]);this.submitting=false;return[4,verifyEmail(this.tempAuthEndpoint,{email:this.email,token:this.verificationCode})];case 2:e=s.sent();VerdocsToast("Thank you for verifying your email address.",{style:"success"});this.completeLogin(e);return[3,4];case 3:t=s.sent();this.submitting=false;console.log("Verification error",t);VerdocsToast("Verification error, please check the code and try again.");return[3,4];case 4:return[2]}}))}))};e.prototype.completeLogin=function(e){this.clearForms();this.tempAuthEndpoint.clearSession();this.endpoint.setToken(e.access_token)};e.prototype.loginAndCheckVerification=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,s,i;return __generator(this,(function(r){switch(r.label){case 0:if(this.submitting){return[2]}this.submitting=true;this.tempAuthEndpoint.clearSession();r.label=1;case 1:r.trys.push([1,4,,5]);this.submitting=false;return[4,authenticate(this.tempAuthEndpoint,{username:this.email.trim(),password:this.password,grant_type:"password"})];case 2:t=r.sent();console.log("[AUTH] Authenticated, checking email verification");this.tempAuthEndpoint.setToken(t.access_token);return[4,getMyUser(this.tempAuthEndpoint)];case 3:s=r.sent();if(!s.email_verified){console.log("[AUTH] Logged in, pending email address verification");this.displayMode="verify"}else{console.log("[AUTH] Email address is verified, completing login");this.completeLogin(t)}return[3,5];case 4:i=r.sent();this.submitting=false;console.log("[AUTH] Auth failure",((e=i.response)===null||e===void 0?void 0:e.data)||i);VerdocsToast("Login failed. Please check your credentials and try again.",{style:"error"});return[3,5];case 5:return[2]}}))}))};e.prototype.clearForms=function(){this.submitting=false;this.resendDisabled=false;this.email="";this.phone="";this.password="";this.newPassword="";this.confirmpass="";this.verificationCode="";this.first_name="";this.last_name="";this.org_name=""};e.prototype.handleLogout=function(){console.log("logging out");this.endpoint.clearSession();this.tempAuthEndpoint.clearSession();this.clearForms();this.displayMode="login"};e.prototype.handleResendVerification=function(){var e=this;this.resendDisabled=true;this.resendDisabledTimer=setTimeout((function(){e.resendDisabled=false;e.resendDisabledTimer=null}),3e4);resendVerification(this.tempAuthEndpoint).then((function(e){console.log("[AUTH] Verification request resent",e);VerdocsToast("Please check your email for a verification code.",{style:"info"})})).catch((function(e){console.log("[AUTH] Unable to resend verification",e);VerdocsToast("Unable to resend code. Please try again later.",{style:"error"})}))};e.prototype.handleResendReset=function(){var e=this;this.resendDisabled=true;this.resendDisabledTimer=setTimeout((function(){e.resendDisabled=false;e.resendDisabledTimer=null}),3e4);resetPassword(this.tempAuthEndpoint,{email:this.email}).then((function(e){console.log("[AUTH] Resend-code request resent",e);VerdocsToast("Please check your email again for a verification code.",{style:"info"})})).catch((function(e){console.log("[AUTH] Unable to resend reset request",e);VerdocsToast("Unable to resend code. Please try again later.",{style:"error"})}))};e.prototype.handleResetGetCode=function(){return __awaiter(this,void 0,void 0,(function(){var e,t;return __generator(this,(function(s){switch(s.label){case 0:this.submitting=true;this.confirmpass="";this.newPassword="";s.label=1;case 1:s.trys.push([1,3,,4]);this.submitting=false;return[4,resetPassword(this.endpoint,{email:this.email})];case 2:e=s.sent();console.log("[AUTH] Reset result",e);VerdocsToast("Please check your email inbox for a password reset code.",{style:"success"});this.verificationCode="";this.confirmpass="";this.newPassword="";this.displayMode="reset";return[3,4];case 3:t=s.sent();this.submitting=false;console.log("Reset request error",t);VerdocsToast("Request failed. Please check your email address and try again.");return[3,4];case 4:return[2]}}))}))};e.prototype.handleResetPassword=function(){return __awaiter(this,void 0,void 0,(function(){var e,t;return __generator(this,(function(s){switch(s.label){case 0:if(!this.isPasswordComplex(this.newPassword)){VerdocsToast("Password must be at least 8 characters long and contain at least one uppercase, one lowercase, and one special character.",{style:"error"});return[2]}if(this.newPassword!==this.confirmpass){VerdocsToast("Passwords do not match.",{style:"error"});return[2]}this.submitting=true;s.label=1;case 1:s.trys.push([1,3,,4]);this.submitting=false;return[4,resetPassword(this.endpoint,{email:this.email,code:this.verificationCode,new_password:this.newPassword})];case 2:e=s.sent();console.log("reset result",e);VerdocsToast("Your password has been reset. You may now use your new password to login.",{style:"success"});this.verificationCode="";this.confirmpass="";this.newPassword="";this.password="";this.displayMode="login";return[3,4];case 3:t=s.sent();this.submitting=false;console.log("Verification error",t);VerdocsToast("Verification error, please check the code and try again.");return[3,4];case 4:return[2]}}))}))};e.prototype.handleReset=function(){return __awaiter(this,void 0,void 0,(function(){var e,t;return __generator(this,(function(s){switch(s.label){case 0:this.submitting=true;s.label=1;case 1:s.trys.push([1,3,,4]);return[4,resetPassword(this.endpoint,{email:this.email})];case 2:e=s.sent();console.log("[AUTH] Reset sent",e);this.submitting=false;this.displayMode="login";VerdocsToast("If your email address is registered, you will receive instructions on resetting your password shortly.",{style:"info"});return[3,4];case 3:t=s.sent();console.log("[AUTH] Unable to reset password",t);this.submitting=false;VerdocsToast("Unable to reset password. Please check your email address and try again.",{style:"error"});return[3,4];case 4:return[2]}}))}))};e.prototype.render=function(){var e=this;if(!this.visible){return h("div",{style:{display:"none"}},"Authenticated")}if(this.session){return h("verdocs-button",{label:"Sign Out",disabled:this.submitting,onClick:function(){return e.handleLogout()},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}})}if(this.displayMode==="signup"){var t=this.submitting||!this.first_name||!this.last_name||!this.email||!this.password||!this.confirmpass||!this.org_name;return h("div",{class:"form"},h("a",{href:"https://verdocs.com/en/"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),h("h3",null,"Sign up for a free account"),h("div",{class:"already-have"},"Already have an account?",h("verdocs-button",{label:"Log In",variant:"text",onClick:function(){return e.displayMode="login"},disabled:this.submitting})),h("form",{onSubmit:function(){return e.handleSignup()}},h("div",{style:{display:"flex",flexDirection:"row",columnGap:"20px"}},h("verdocs-text-input",{label:"First Name",autocomplete:"first",required:true,value:this.first_name,onInput:function(t){return e.first_name=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Last Name",autocomplete:"last",required:true,value:this.last_name,onInput:function(t){return e.last_name=t.target.value},disabled:this.submitting})),h("verdocs-text-input",{label:"Email Address",autocomplete:"email",required:true,value:this.email,onInput:function(t){return e.email=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Password",type:"password",required:true,autocomplete:"new-password",value:this.password,onInput:function(t){return e.password=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Confirm Password",type:"password",required:true,autocomplete:"off",value:this.confirmpass,onInput:function(t){return e.confirmpass=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Phone Number",type:"tel",required:true,autocomplete:"phone",value:this.phone,onInput:function(t){return e.phone=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Organization Name",autocomplete:"org",required:true,value:this.org_name,onInput:function(t){return e.org_name=t.target.value},disabled:this.submitting,style:{flex:"1"}}),h("div",{class:"service-agreement"},"By clicking the Create Account button, you agree to the"," ",h("a",{href:"https://verdocs.com/eula",target:"_blank"},"End User License Agreement"),". Learn about how we use and protect your data and how you can opt-out in our"," ",h("a",{href:"https://verdocs.com/privacy-policy",target:"_blank"},"Privacy Policy"),"."),h("div",{style:{marginTop:"30px"}}),h("verdocs-button",{label:"Next",disabled:t,onClick:t?function(){}:function(){return e.handleSignup()},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}})))}if(this.displayMode==="verify"){return h("div",{class:"form"},h("form",{onSubmit:function(){return e.handleVerification()}},h("p",null,"Please check your e-mail inbox for a verification code and enter it below."),h("verdocs-text-input",{label:"Verification Code",required:true,value:this.verificationCode,onInput:function(t){return e.verificationCode=t.target.value},disabled:this.submitting}),h("div",{class:"buttons"},h("verdocs-button",{label:"Sign Out",variant:"outline",disabled:this.submitting,onClick:function(){return e.handleLogout()}}),h("verdocs-button",{label:"Verify",disabled:this.submitting||!this.verificationCode||this.verificationCode.length!==6,onClick:function(){return e.handleVerification()}})),h("div",{class:"buttons"},h("verdocs-button",{variant:"text",label:"Resend Code",disabled:this.resendDisabled||this.submitting,onClick:function(){return e.handleResendVerification()}}))))}if(this.displayMode==="forgot"){return h("div",{class:"form"},h("a",{href:"https://verdocs.com/en/"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),h("h3",null,"Forgot your password?"),h("p",null,"Enter your e-mail address below. If the e-mail address is valid, a password reset code will be sent to your inbox. Please allow up to 15 minutes to arrive, and check your spam folder if you do not receive the message."),h("form",{onSubmit:function(){return e.handleResetGetCode()}},h("verdocs-text-input",{label:"Email Address",autocomplete:"email",required:true,value:this.email,onInput:function(t){return e.email=t.target.value},disabled:this.submitting}),h("div",{style:{marginTop:"30px"}}),h("div",{class:"buttons"},h("verdocs-button",{size:"small",label:"Cancel",variant:"outline",disabled:this.submitting,onClick:function(){return e.displayMode="login"}}),h("verdocs-button",{size:"small",label:"Request Code",disabled:this.submitting,onClick:function(){return e.handleResetGetCode()}}))))}if(this.displayMode==="reset"){return h("div",{class:"form"},h("a",{href:"https://verdocs.com/en/"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),h("h3",null,"Forgot your password?"),h("p",null,"Enter your e-mail address below, and reset instructions will be sent to your Inbox. Please allow up to 15 minutes to arrive. Check your spam folder if you do not receive the message."),h("form",{onSubmit:function(){return e.handleResetPassword()}},h("verdocs-text-input",{label:"Verification Code",required:true,value:this.verificationCode,onInput:function(t){return e.verificationCode=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Password",type:"password",required:true,autocomplete:"off",value:this.newPassword,onInput:function(t){return e.newPassword=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Confirm Password",type:"password",required:true,autocomplete:"off",value:this.confirmpass,onInput:function(t){return e.confirmpass=t.target.value},disabled:this.submitting}),h("div",{style:{marginTop:"30px"}}),h("div",{class:"buttons"},h("verdocs-button",{label:"Cancel",variant:"outline",disabled:this.submitting,onClick:function(){return e.displayMode="login"}}),h("verdocs-button",{label:"Reset",disabled:this.submitting,onClick:function(){return e.handleResetPassword()}})),h("div",{class:"buttons"},h("verdocs-button",{variant:"text",label:"Resend Code",disabled:this.resendDisabled||this.submitting,onClick:function(){return e.handleResendReset()}}))))}return h("div",{class:"form"},h("a",{href:"https://verdocs.com/en/"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),h("h3",null,"Log in to your account"),h("div",{class:"already-have"},"Don't have an account?",h("verdocs-button",{label:"Sign Up",variant:"text",onClick:function(){return e.displayMode="signup"},disabled:this.submitting})),h("form",{onSubmit:function(){return e.loginAndCheckVerification()}},h("verdocs-text-input",{label:"Email",autocomplete:"username",value:this.email,onInput:function(t){return e.email=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Password",type:"password",autocomplete:"current-password",value:this.password,onInput:function(t){return e.password=t.target.value},disabled:this.submitting}),h("verdocs-button",{label:"Forgot Your Password?",variant:"text",onClick:function(){return e.displayMode="forgot"},disabled:this.submitting,style:{display:"flex",justifyContent:"center",margin:"10px auto 20px"}}),h("verdocs-button",{label:"Login",disabled:this.submitting,onClick:function(){return e.loginAndCheckVerification()},style:{display:"flex",justifyContent:"center",margin:"10px auto 0"}})))};return e}();VerdocsAuth.style=verdocsAuthCss();export{VerdocsAuth as verdocs_auth};
1
+ var __awaiter=this&&this.__awaiter||function(e,t,i,r){function s(e){return e instanceof i?e:new i((function(t){t(e)}))}return new(i||(i=Promise))((function(i,o){function n(e){try{c(r.next(e))}catch(e){o(e)}}function a(e){try{c(r["throw"](e))}catch(e){o(e)}}function c(e){e.done?i(e.value):s(e.value).then(n,a)}c((r=r.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var i={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},r,s,o,n=Object.create((typeof Iterator==="function"?Iterator:Object).prototype);return n.next=a(0),n["throw"]=a(1),n["return"]=a(2),typeof Symbol==="function"&&(n[Symbol.iterator]=function(){return this}),n;function a(e){return function(t){return c([e,t])}}function c(a){if(r)throw new TypeError("Generator is already executing.");while(n&&(n=0,a[0]&&(i=0)),i)try{if(r=1,s&&(o=a[0]&2?s["return"]:a[0]?s["throw"]||((o=s["return"])&&o.call(s),0):s.next)&&!(o=o.call(s,a[1])).done)return o;if(s=0,o)a=[a[0]&2,o.value];switch(a[0]){case 0:case 1:o=a;break;case 4:i.label++;return{value:a[1],done:false};case 5:i.label++;s=a[1];a=[0];continue;case 7:a=i.ops.pop();i.trys.pop();continue;default:if(!(o=i.trys,o=o.length>0&&o[o.length-1])&&(a[0]===6||a[0]===2)){i=0;continue}if(a[0]===3&&(!o||a[1]>o[0]&&a[1]<o[3])){i.label=a[1];break}if(a[0]===6&&i.label<o[1]){i.label=o[1];o=a;break}if(o&&i.label<o[2]){i.label=o[2];i.ops.push(a);break}if(o[2])i.ops.pop();i.trys.pop();continue}a=t.call(e,i)}catch(e){a=[6,e];s=0}finally{r=o=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:true}}};import{r as registerInstance,c as createEvent,h,g as getElement}from"./index-CjTHbolG.js";import{VerdocsEndpoint,getSocialProviders,convertToE164,createProfile,verifyEmail,getMyUser,authenticate,isMFARequired,createCodeVerifier,createCodeChallenge,getSocialLoginUrl,resendVerification,resetPassword}from"@verdocs/js-sdk";import{M as MicrosoftIcon,G as GoogleIcon}from"./Icons-DobS6Y7w.js";import{V as VerdocsToast}from"./Toast-D97GxsI-.js";import{S as SDKError}from"./errors-C1sRVZWv.js";var verdocsAuthCss=function(){return'verdocs-auth{font-family:var(--verdocs-primary-font, "Inter", "Barlow", sans-serif);display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center}verdocs-auth .form{width:350px;display:-ms-flexbox;display:flex;padding:20px;max-width:90%;-ms-flex-align:center;align-items:center;-ms-flex-direction:column;flex-direction:column;-webkit-box-sizing:border-box;box-sizing:border-box;-ms-flex-pack:center;justify-content:center;background:#ffffff}verdocs-auth .logo{width:128px;max-width:100%;margin:20px 0 30px}verdocs-auth h3{color:#092c4c;text-align:center;font-weight:400;font-size:18px;line-height:1.75;margin:0 0 20px 0}verdocs-auth em{font-size:14px;margin:15px 0}verdocs-auth .buttons{gap:20px;margin:20px 0 0 0;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth .status-result{display:none}verdocs-auth .status-result.debug{white-space:pre-wrap;font-size:14px;background:#fff;padding:10px;display:block;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth form{width:100%}verdocs-auth verdocs-text-input{margin-bottom:10px}verdocs-auth .account-option{gap:8px;margin:20px 0 8px 0;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-auth p{color:#092c4c;margin:1em 0;font-size:14px}verdocs-auth p+p{margin-top:0}verdocs-auth verdocs-help-icon{margin-top:18px;display:-ms-flexbox;display:flex;width:32px;height:32px;-ms-flex:0 0 32px;flex:0 0 32px}verdocs-auth .already-have{color:#092c4c;margin:0.5em 0;font-size:14px;text-align:center}verdocs-auth .service-agreement{font-size:12px;color:#777}verdocs-auth .service-agreement a{color:#092c4c}verdocs-auth .providers{width:100%}verdocs-auth .providers verdocs-button{display:block;margin-bottom:10px}verdocs-auth .providers verdocs-button button.outline{position:relative;border-color:#aeb4bf}verdocs-auth .providers verdocs-button button.outline:disabled{border-color:#aeb4bf}verdocs-auth .providers verdocs-button .icon.start{position:absolute;left:16px;margin:0;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}verdocs-auth .providers verdocs-button .icon.start svg{width:18px;height:18px}verdocs-auth .divider{gap:8px;color:#777;display:-ms-flexbox;display:flex;font-size:12px;margin:28px 0;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}verdocs-auth .divider .divider-line{-ms-flex:1;flex:1;height:1px;background:#aeb4bf}verdocs-auth .mfa-error{color:#cc0000;font-size:14px;margin:0 0 8px}'};var MFA_CODE_ERROR="Invalid code. Please try again.";var SOCIAL_START_ERROR="Unable to start sign-in sequence. Please try again.";var SOCIAL_LOGIN_KEY="vdocs-social-login";var SOCIAL_ERROR_MESSAGES={email_unverified:"That account does not have a verified email address.",corporate_email_required:"Please use your corporate email address to create an account.",account_locked:"That account is locked. Please contact support@verdocs.com.",provider_error:"That provider could not sign you in. Please try again.",access_denied:"Sign-in was canceled."};var socialErrorMessage=function(e){return SOCIAL_ERROR_MESSAGES[e]||"Unable to sign in. Please try again."};var readSocialLoginAttempt=function(){try{var e=window.sessionStorage.getItem(SOCIAL_LOGIN_KEY);return e?JSON.parse(e):null}catch(e){return null}};var clearSocialLoginAttempt=function(){try{window.sessionStorage.removeItem(SOCIAL_LOGIN_KEY)}catch(e){}};var cleanSocialLoginParams=function(e){var t=new URL(window.location.href);e.forEach((function(e){return t.searchParams.delete(e)}));window.history.replaceState({},"","".concat(t.pathname).concat(t.search).concat(t.hash))};var currentReturnUri=function(){return"".concat(window.location.origin).concat(window.location.pathname)};var formatRecoveryCode=function(e){var t=e.toLowerCase().replace(/[^a-z0-9]/g,"").slice(0,8);return t.length>4?"".concat(t.slice(0,4),"-").concat(t.slice(4)):t};var VerdocsAuth=function(){function e(e){var t=this;registerInstance(this,e);this.authenticated=createEvent(this,"authenticated");this.sdkError=createEvent(this,"sdkError");this.endpoint=VerdocsEndpoint.getDefault();this.visible=true;this.logo="https://app.verdocs.com/assets/blue-logo.svg";this.displayMode="login";this.showSocialLogins=false;this.org_name="";this.first_name="";this.last_name="";this.email="";this.phone="";this.verificationCode="";this.newPassword="";this.password="";this.confirmpass="";this.submitting=false;this.resendDisabled=false;this.session=null;this.profile=null;this.providers={google:false,microsoft:false};this.mfaToken="";this.mfaCode="";this.recoveryCode="";this.useRecoveryCode=false;this.mfaError="";this.resendDisabledTimer=null;this.mfaFocusPending=false;this.tempAuthEndpoint=new VerdocsEndpoint({baseURL:VerdocsEndpoint.getDefault().getBaseURL(),persist:false});this.handleHashChange=function(){t.applyHashDisplayMode()}}e.prototype.componentWillLoad=function(){var e=this;this.endpoint.loadSession();this.applyHashDisplayMode();if(typeof window!=="undefined"){window.addEventListener("hashchange",this.handleHashChange)}VerdocsEndpoint.getDefault().onSessionChanged((function(t,i,r){var s,o;e.session=i;e.profile=r;if(i){(s=e.authenticated)===null||s===void 0?void 0:s.emit({authenticated:true,session:i,profile:r})}else{(o=e.authenticated)===null||o===void 0?void 0:o.emit({authenticated:false,session:i,profile:r})}}));if(this.showSocialLogins){getSocialProviders(this.endpoint).then((function(t){e.providers=t})).catch((function(){return undefined}))}this.handleSocialLoginReturn()};e.prototype.componentDidRender=function(){if(this.displayMode!=="mfa"){return}var e=this.el.querySelector(".mfa-input input");if(!e){return}if(!this.useRecoveryCode){e.setAttribute("inputmode","numeric")}else{e.removeAttribute("inputmode")}if(this.mfaFocusPending){this.mfaFocusPending=false;e.focus()}};e.prototype.disconnectedCallback=function(){if(typeof window!=="undefined"){window.removeEventListener("hashchange",this.handleHashChange)}};e.prototype.applyHashDisplayMode=function(){if(typeof window==="undefined"){return}var e=(window.location.hash||"").replace(/^#/,"").toLowerCase();if(e==="forgot"){this.displayMode="forgot"}};e.prototype.isPasswordComplex=function(e){var t=function(e){return/[A-Z]/.test(e)};var i=function(e){return/[a-z]/.test(e)};var r=function(e){return/[`!@#$%^&*()_\-+=\[\]{};':"\\|,.<>\/?~ ]/.test(e)};var s=0,o=0,n=0;for(var a=0;a<e.length;a++){var c=e.charAt(a);if(t(c))s++;else if(i(c))o++;else if(r(c))n++}return e.length>=8&&o>0&&s>0&&n>0};e.prototype.handleSignup=function(){var e=this;if(!this.isPasswordComplex(this.password)){VerdocsToast("Password must be at least 8 characters long and contain at least one uppercase, one lowercase, and one special character.",{style:"error"});return}if(this.password!==this.confirmpass){VerdocsToast("Passwords do not match.",{style:"error"});return}this.submitting=true;this.tempAuthEndpoint.clearSession();var t=convertToE164(this.phone);var i=Intl.DateTimeFormat().resolvedOptions();createProfile(this.tempAuthEndpoint,{email:this.email,password:this.password,first_name:this.first_name,last_name:this.last_name,org_name:this.org_name,phone:t,timezone:i.timeZone,locale:i.locale}).then((function(t){console.log("[AUTH] Profile creation result",t);e.tempAuthEndpoint.setToken(t.access_token);e.password="";e.phone="";e.first_name="";e.last_name="";e.org_name="";e.displayMode="verify";e.submitting=false})).catch((function(t){var i,r,s,o,n,a;console.log("[AUTH] Signup error",t.response);e.submitting=false;(i=e.authenticated)===null||i===void 0?void 0:i.emit({authenticated:false,profile:null,session:null});(r=e.sdkError)===null||r===void 0?void 0:r.emit(new SDKError(t.message,(s=t.response)===null||s===void 0?void 0:s.status,(o=t.response)===null||o===void 0?void 0:o.data));VerdocsToast("Signup failed: "+((a=(n=t.response)===null||n===void 0?void 0:n.data)===null||a===void 0?void 0:a.error)||"Unknown Error",{style:"error"})}))};e.prototype.handleVerification=function(){return __awaiter(this,void 0,void 0,(function(){var e,t;return __generator(this,(function(i){switch(i.label){case 0:this.submitting=true;i.label=1;case 1:i.trys.push([1,3,,4]);this.submitting=false;return[4,verifyEmail(this.tempAuthEndpoint,{email:this.email,token:this.verificationCode})];case 2:e=i.sent();VerdocsToast("Thank you for verifying your email address.",{style:"success"});this.completeLogin(e);return[3,4];case 3:t=i.sent();this.submitting=false;console.log("Verification error",t);VerdocsToast("Verification error, please check the code and try again.");return[3,4];case 4:return[2]}}))}))};e.prototype.completeLogin=function(e){this.clearForms();this.displayMode="login";this.tempAuthEndpoint.clearSession();this.endpoint.setToken(e.access_token)};e.prototype.finishLogin=function(e){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(i){switch(i.label){case 0:console.log("[AUTH] Authenticated, checking email verification");this.tempAuthEndpoint.setToken(e.access_token);return[4,getMyUser(this.tempAuthEndpoint)];case 1:t=i.sent();this.submitting=false;if(!t.email_verified){console.log("[AUTH] Logged in, pending email address verification");this.displayMode="verify"}else{console.log("[AUTH] Email address is verified, completing login");this.completeLogin(e)}return[2]}}))}))};e.prototype.loginAndCheckVerification=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,i;return __generator(this,(function(r){switch(r.label){case 0:if(this.submitting){return[2]}this.submitting=true;this.tempAuthEndpoint.clearSession();r.label=1;case 1:r.trys.push([1,4,,5]);return[4,authenticate(this.tempAuthEndpoint,{username:this.email.trim(),password:this.password,grant_type:"password"})];case 2:t=r.sent();return[4,this.finishLogin(t)];case 3:r.sent();return[3,5];case 4:i=r.sent();if(isMFARequired(i)){this.startMFA(i.response.data.mfa_token);return[2]}this.submitting=false;console.log("[AUTH] Auth failure",((e=i.response)===null||e===void 0?void 0:e.data)||i);VerdocsToast("Login failed. Please check your credentials and try again.",{style:"error"});return[3,5];case 5:return[2]}}))}))};e.prototype.startMFA=function(e){this.mfaToken=e;this.mfaCode="";this.recoveryCode="";this.useRecoveryCode=false;this.mfaError="";this.submitting=false;this.mfaFocusPending=true;this.displayMode="mfa"};e.prototype.returnToLogin=function(){this.mfaToken="";this.mfaCode="";this.recoveryCode="";this.useRecoveryCode=false;this.mfaError="";this.password="";this.submitting=false;this.displayMode="login"};e.prototype.handleMFAFailure=function(e){var t;this.submitting=false;this.mfaCode="";this.recoveryCode="";if(isMFARequired(e)){this.mfaToken=e.response.data.mfa_token;this.mfaError=MFA_CODE_ERROR;return}if(((t=e===null||e===void 0?void 0:e.response)===null||t===void 0?void 0:t.status)===401){this.returnToLogin();VerdocsToast("Your sign-in timed out. Enter your password again.",{style:"error"});return}this.mfaError=MFA_CODE_ERROR};e.prototype.submitMFA=function(e,t){return __awaiter(this,void 0,void 0,(function(){var i,r;return __generator(this,(function(s){switch(s.label){case 0:if(this.submitting||!e){return[2]}this.submitting=true;this.mfaError="";this.tempAuthEndpoint.clearSession();s.label=1;case 1:s.trys.push([1,4,,5]);return[4,authenticate(this.tempAuthEndpoint,t?{grant_type:"urn:verdocs:params:oauth:grant-type:mfa-recovery-code",mfa_token:this.mfaToken,recovery_code:e}:{grant_type:"urn:verdocs:params:oauth:grant-type:mfa-otp",mfa_token:this.mfaToken,otp:e})];case 2:i=s.sent();return[4,this.finishLogin(i)];case 3:s.sent();return[3,5];case 4:r=s.sent();this.handleMFAFailure(r);return[3,5];case 5:return[2]}}))}))};e.prototype.handleVerifyMFA=function(){this.submitMFA(this.useRecoveryCode?this.recoveryCode:this.mfaCode,this.useRecoveryCode).catch((function(){return undefined}))};e.prototype.handleMFACodeInput=function(e){var t=(e.value||"").replace(/\D/g,"").slice(0,6);if(e.value!==t){e.value=t}this.mfaCode=t;if(t.length===6){this.submitMFA(t,false).catch((function(){return undefined}))}};e.prototype.handleRecoveryCodeInput=function(e){var t=formatRecoveryCode(e.value||"");if(e.value!==t){e.value=t}this.recoveryCode=t};e.prototype.toggleRecoveryCode=function(){this.useRecoveryCode=!this.useRecoveryCode;this.mfaCode="";this.recoveryCode="";this.mfaError="";this.mfaFocusPending=true};e.prototype.handleSocialLogin=function(e){var t=this;try{var i=createCodeVerifier();var r=createCodeVerifier();createCodeChallenge(i).then((function(s){var o={verifier:i,state:r,provider:e};window.sessionStorage.setItem(SOCIAL_LOGIN_KEY,JSON.stringify(o));window.location.assign(getSocialLoginUrl(t.endpoint,e,{returnUri:currentReturnUri(),codeChallenge:s,state:r}))})).catch((function(){return VerdocsToast(SOCIAL_START_ERROR,{style:"error"})}))}catch(e){VerdocsToast(SOCIAL_START_ERROR,{style:"error"})}};e.prototype.handleSocialLoginReturn=function(){if(typeof window==="undefined"){return}var e=new URLSearchParams(window.location.search);var t=e.get("login_code");var i=e.get("state");var r=e.get("error");if(!t&&!r){return}var s=readSocialLoginAttempt();if(!t&&!s){return}clearSocialLoginAttempt();cleanSocialLoginParams(t?["login_code","state"]:["error"]);if(r){VerdocsToast(socialErrorMessage(r),{style:"error"});return}if(!s||s.state!==i){VerdocsToast("Sign-in could not be verified. Try again.",{style:"error"});return}this.exchangeLoginCode(t,s.verifier)};e.prototype.exchangeLoginCode=function(e,t){var i=this;this.submitting=true;this.tempAuthEndpoint.clearSession();authenticate(this.tempAuthEndpoint,{grant_type:"urn:verdocs:params:oauth:grant-type:login-code",login_code:e,code_verifier:t}).then((function(e){return i.finishLogin(e)})).catch((function(e){var t;if(isMFARequired(e)){i.startMFA(e.response.data.mfa_token);return}i.submitting=false;console.log("[AUTH] Social login failure",((t=e.response)===null||t===void 0?void 0:t.data)||e);VerdocsToast("Sign-in failed. Please try again.",{style:"error"})}))};e.prototype.clearForms=function(){this.submitting=false;this.resendDisabled=false;this.mfaToken="";this.mfaCode="";this.recoveryCode="";this.useRecoveryCode=false;this.mfaError="";this.email="";this.phone="";this.password="";this.newPassword="";this.confirmpass="";this.verificationCode="";this.first_name="";this.last_name="";this.org_name=""};e.prototype.handleLogout=function(){console.log("logging out");this.endpoint.clearSession();this.tempAuthEndpoint.clearSession();this.clearForms();this.displayMode="login"};e.prototype.handleResendVerification=function(){var e=this;this.resendDisabled=true;this.resendDisabledTimer=setTimeout((function(){e.resendDisabled=false;e.resendDisabledTimer=null}),3e4);resendVerification(this.tempAuthEndpoint).then((function(e){console.log("[AUTH] Verification request resent",e);VerdocsToast("Please check your email for a verification code.",{style:"info"})})).catch((function(e){console.log("[AUTH] Unable to resend verification",e);VerdocsToast("Unable to resend code. Please try again later.",{style:"error"})}))};e.prototype.handleResendReset=function(){var e=this;this.resendDisabled=true;this.resendDisabledTimer=setTimeout((function(){e.resendDisabled=false;e.resendDisabledTimer=null}),3e4);resetPassword(this.tempAuthEndpoint,{email:this.email}).then((function(e){console.log("[AUTH] Resend-code request resent",e);VerdocsToast("Please check your email again for a verification code.",{style:"info"})})).catch((function(e){console.log("[AUTH] Unable to resend reset request",e);VerdocsToast("Unable to resend code. Please try again later.",{style:"error"})}))};e.prototype.handleResetGetCode=function(){return __awaiter(this,void 0,void 0,(function(){var e,t;return __generator(this,(function(i){switch(i.label){case 0:this.submitting=true;this.confirmpass="";this.newPassword="";i.label=1;case 1:i.trys.push([1,3,,4]);this.submitting=false;return[4,resetPassword(this.endpoint,{email:this.email})];case 2:e=i.sent();console.log("[AUTH] Reset result",e);VerdocsToast("Please check your email inbox for a password reset code.",{style:"success"});this.verificationCode="";this.confirmpass="";this.newPassword="";this.displayMode="reset";return[3,4];case 3:t=i.sent();this.submitting=false;console.log("Reset request error",t);VerdocsToast("Request failed. Please check your email address and try again.");return[3,4];case 4:return[2]}}))}))};e.prototype.handleResetPassword=function(){return __awaiter(this,void 0,void 0,(function(){var e,t;return __generator(this,(function(i){switch(i.label){case 0:if(!this.isPasswordComplex(this.newPassword)){VerdocsToast("Password must be at least 8 characters long and contain at least one uppercase, one lowercase, and one special character.",{style:"error"});return[2]}if(this.newPassword!==this.confirmpass){VerdocsToast("Passwords do not match.",{style:"error"});return[2]}this.submitting=true;i.label=1;case 1:i.trys.push([1,3,,4]);this.submitting=false;return[4,resetPassword(this.endpoint,{email:this.email,code:this.verificationCode,new_password:this.newPassword})];case 2:e=i.sent();console.log("reset result",e);VerdocsToast("Your password has been reset. You may now use your new password to login.",{style:"success"});this.verificationCode="";this.confirmpass="";this.newPassword="";this.password="";this.displayMode="login";return[3,4];case 3:t=i.sent();this.submitting=false;console.log("Verification error",t);VerdocsToast("Verification error, please check the code and try again.");return[3,4];case 4:return[2]}}))}))};e.prototype.handleReset=function(){return __awaiter(this,void 0,void 0,(function(){var e,t;return __generator(this,(function(i){switch(i.label){case 0:this.submitting=true;i.label=1;case 1:i.trys.push([1,3,,4]);return[4,resetPassword(this.endpoint,{email:this.email})];case 2:e=i.sent();console.log("[AUTH] Reset sent",e);this.submitting=false;this.displayMode="login";VerdocsToast("If your email address is registered, you will receive instructions on resetting your password shortly.",{style:"info"});return[3,4];case 3:t=i.sent();console.log("[AUTH] Unable to reset password",t);this.submitting=false;VerdocsToast("Unable to reset password. Please check your email address and try again.",{style:"error"});return[3,4];case 4:return[2]}}))}))};e.prototype.renderProviderButtons=function(){var e=this;if(!this.showSocialLogins||!this.providers.google&&!this.providers.microsoft){return null}return h("div",{class:"providers"},this.providers.google&&h("verdocs-button",{label:"Continue with Google",variant:"outline",class:"provider-google",startIcon:GoogleIcon,disabled:this.submitting,onClick:function(){return e.handleSocialLogin("google")}}),this.providers.microsoft&&h("verdocs-button",{label:"Continue with Microsoft",variant:"outline",class:"provider-microsoft",startIcon:MicrosoftIcon,disabled:this.submitting,onClick:function(){return e.handleSocialLogin("microsoft")}}),h("div",{class:"divider"},h("div",{class:"divider-line"}),"or",h("div",{class:"divider-line"})))};e.prototype.render=function(){var e=this;if(!this.visible){return h("div",{style:{display:"none"}},"Authenticated")}if(this.session){return h("verdocs-button",{label:"Sign Out",disabled:this.submitting,onClick:function(){return e.handleLogout()},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}})}if(this.displayMode==="mfa"){var t=this.useRecoveryCode?this.recoveryCode:this.mfaCode;var i=this.useRecoveryCode?this.recoveryCode.replace("-","").length===8:this.mfaCode.length===6;return h("div",{class:"form"},h("a",{href:"https://verdocs.com/en/"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),h("h3",null,"Two-factor authentication"),h("p",null,this.useRecoveryCode?"Enter one of the backup codes you saved when you turned on multi-factor authentication.":"Enter the six-digit code from your authenticator app."),h("form",{onSubmit:function(t){t.preventDefault();e.handleVerifyMFA()}},this.useRecoveryCode?h("verdocs-text-input",{class:"mfa-input",label:"Backup code",placeholder:"xxxx-xxxx",autocomplete:"one-time-code",value:this.recoveryCode,onInput:function(t){return e.handleRecoveryCodeInput(t.target)},disabled:this.submitting}):h("verdocs-text-input",{class:"mfa-input",label:"Authentication code",autocomplete:"one-time-code",value:this.mfaCode,onInput:function(t){return e.handleMFACodeInput(t.target)},disabled:this.submitting}),this.mfaError&&h("div",{role:"alert",class:"mfa-error"},this.mfaError),h("div",{class:"buttons"},h("verdocs-button",{label:"Cancel",variant:"outline",disabled:this.submitting,onClick:function(){return e.returnToLogin()}}),h("verdocs-button",{label:"Verify",disabled:this.submitting||!i||!t,onClick:function(){return e.handleVerifyMFA()}})),h("div",{class:"buttons"},h("verdocs-button",{variant:"text",size:"small",label:this.useRecoveryCode?"Use your authenticator app instead":"Use a backup code instead",disabled:this.submitting,onClick:function(){return e.toggleRecoveryCode()}}))))}if(this.displayMode==="signup"){var r=this.submitting||!this.first_name||!this.last_name||!this.email||!this.password||!this.confirmpass||!this.org_name;return h("div",{class:"form"},h("a",{href:"https://verdocs.com/en/"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),h("h3",null,"Sign up for a free account"),h("div",{class:"already-have"},"Already have an account?",h("verdocs-button",{label:"Log In",variant:"text",onClick:function(){return e.displayMode="login"},disabled:this.submitting})),this.renderProviderButtons(),h("form",{onSubmit:function(){return e.handleSignup()}},h("div",{style:{display:"flex",flexDirection:"row",columnGap:"20px"}},h("verdocs-text-input",{label:"First Name",autocomplete:"first",required:true,value:this.first_name,onInput:function(t){return e.first_name=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Last Name",autocomplete:"last",required:true,value:this.last_name,onInput:function(t){return e.last_name=t.target.value},disabled:this.submitting})),h("verdocs-text-input",{label:"Email Address",autocomplete:"email",required:true,value:this.email,onInput:function(t){return e.email=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Password",type:"password",required:true,autocomplete:"new-password",value:this.password,onInput:function(t){return e.password=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Confirm Password",type:"password",required:true,autocomplete:"off",value:this.confirmpass,onInput:function(t){return e.confirmpass=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Phone Number",type:"tel",required:true,autocomplete:"phone",value:this.phone,onInput:function(t){return e.phone=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Organization Name",autocomplete:"org",required:true,value:this.org_name,onInput:function(t){return e.org_name=t.target.value},disabled:this.submitting,style:{flex:"1"}}),h("div",{class:"service-agreement"},"By clicking the Create Account button, you agree to the"," ",h("a",{href:"https://verdocs.com/eula",target:"_blank"},"End User License Agreement"),". Learn about how we use and protect your data and how you can opt-out in our"," ",h("a",{href:"https://verdocs.com/privacy-policy",target:"_blank"},"Privacy Policy"),"."),h("div",{style:{marginTop:"30px"}}),h("verdocs-button",{label:"Next",disabled:r,onClick:r?function(){}:function(){return e.handleSignup()},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}})))}if(this.displayMode==="verify"){return h("div",{class:"form"},h("form",{onSubmit:function(){return e.handleVerification()}},h("p",null,"Please check your e-mail inbox for a verification code and enter it below."),h("verdocs-text-input",{label:"Verification Code",required:true,value:this.verificationCode,onInput:function(t){return e.verificationCode=t.target.value},disabled:this.submitting}),h("div",{class:"buttons"},h("verdocs-button",{label:"Sign Out",variant:"outline",disabled:this.submitting,onClick:function(){return e.handleLogout()}}),h("verdocs-button",{label:"Verify",disabled:this.submitting||!this.verificationCode||this.verificationCode.length!==6,onClick:function(){return e.handleVerification()}})),h("div",{class:"buttons"},h("verdocs-button",{variant:"text",label:"Resend Code",disabled:this.resendDisabled||this.submitting,onClick:function(){return e.handleResendVerification()}}))))}if(this.displayMode==="forgot"){return h("div",{class:"form"},h("a",{href:"https://verdocs.com/en/"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),h("h3",null,"Forgot your password?"),h("p",null,"Enter your e-mail address below. If the e-mail address is valid, a password reset code will be sent to your inbox. Please allow up to 15 minutes to arrive, and check your spam folder if you do not receive the message."),h("form",{onSubmit:function(){return e.handleResetGetCode()}},h("verdocs-text-input",{label:"Email Address",autocomplete:"email",required:true,value:this.email,onInput:function(t){return e.email=t.target.value},disabled:this.submitting}),h("div",{style:{marginTop:"30px"}}),h("div",{class:"buttons"},h("verdocs-button",{size:"small",label:"Cancel",variant:"outline",disabled:this.submitting,onClick:function(){return e.displayMode="login"}}),h("verdocs-button",{size:"small",label:"Request Code",disabled:this.submitting,onClick:function(){return e.handleResetGetCode()}}))))}if(this.displayMode==="reset"){return h("div",{class:"form"},h("a",{href:"https://verdocs.com/en/"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),h("h3",null,"Forgot your password?"),h("p",null,"Enter your e-mail address below, and reset instructions will be sent to your Inbox. Please allow up to 15 minutes to arrive. Check your spam folder if you do not receive the message."),h("form",{onSubmit:function(){return e.handleResetPassword()}},h("verdocs-text-input",{label:"Verification Code",required:true,value:this.verificationCode,onInput:function(t){return e.verificationCode=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Password",type:"password",required:true,autocomplete:"off",value:this.newPassword,onInput:function(t){return e.newPassword=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Confirm Password",type:"password",required:true,autocomplete:"off",value:this.confirmpass,onInput:function(t){return e.confirmpass=t.target.value},disabled:this.submitting}),h("div",{style:{marginTop:"30px"}}),h("div",{class:"buttons"},h("verdocs-button",{label:"Cancel",variant:"outline",disabled:this.submitting,onClick:function(){return e.displayMode="login"}}),h("verdocs-button",{label:"Reset",disabled:this.submitting,onClick:function(){return e.handleResetPassword()}})),h("div",{class:"buttons"},h("verdocs-button",{variant:"text",label:"Resend Code",disabled:this.resendDisabled||this.submitting,onClick:function(){return e.handleResendReset()}}))))}return h("div",{class:"form"},h("a",{href:"https://verdocs.com/en/"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),h("h3",null,"Log in to your account"),this.renderProviderButtons(),h("form",{onSubmit:function(){return e.loginAndCheckVerification()}},h("verdocs-text-input",{label:"Email",autocomplete:"username",value:this.email,onInput:function(t){return e.email=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Password",type:"password",autocomplete:"current-password",value:this.password,onInput:function(t){return e.password=t.target.value},disabled:this.submitting}),h("verdocs-button",{label:"Forgot Your Password?",variant:"text",onClick:function(){return e.displayMode="forgot"},disabled:this.submitting,style:{display:"flex",justifyContent:"center",margin:"0 auto 20px"}}),h("verdocs-button",{label:"Login",disabled:this.submitting,onClick:function(){return e.loginAndCheckVerification()},style:{display:"flex",justifyContent:"center",margin:"10px auto 0"}}),h("verdocs-button",{label:"Sign Up",variant:"outline",disabled:this.submitting,onClick:function(){return e.displayMode="signup"},style:{display:"flex",justifyContent:"center",margin:"10px auto 0"}})))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();VerdocsAuth.style=verdocsAuthCss();export{VerdocsAuth as verdocs_auth};
2
2
  //# sourceMappingURL=verdocs-auth.entry.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"verdocs-auth.entry.js","sources":["src/components/embeds/verdocs-auth/verdocs-auth.scss?tag=verdocs-auth","src/components/embeds/verdocs-auth/verdocs-auth.tsx"],"sourcesContent":["@import '../../../theme.scss';\n\nverdocs-auth {\n font-family: $verdocs-primary-font;\n display: flex;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n\n .form {\n width: 350px;\n display: flex;\n padding: 20px;\n max-width: 90%;\n align-items: center;\n flex-direction: column;\n box-sizing: border-box;\n justify-content: center;\n background: $verdocs-grey-4;\n }\n\n .logo {\n width: 128px;\n max-width: 100%;\n margin: 20px 0 30px;\n }\n\n h3 {\n color: $verdocs-grey-0;\n text-align: center;\n font-weight: 400;\n font-size: 18px;\n line-height: 1.75;\n margin: 0;\n }\n\n em {\n font-size: 14px;\n margin: 15px 0;\n }\n\n .buttons {\n gap: 20px;\n margin: 20px 0 0 0;\n display: flex;\n flex-direction: row;\n justify-content: center;\n }\n\n .status-result {\n display: none;\n\n &.debug {\n white-space: pre-wrap;\n font-size: 14px;\n background: #fff;\n padding: 10px;\n display: block;\n flex-direction: row;\n justify-content: center;\n }\n }\n\n form {\n width: 100%;\n }\n\n verdocs-text-input {\n margin-bottom: 10px;\n }\n\n .account-option {\n gap: 8px;\n margin: 20px 0 8px 0;\n display: flex;\n flex-direction: row;\n }\n\n p {\n color: $verdocs-grey-0;\n margin: 1em 0;\n font-size: 14px;\n }\n\n // Our <p>s are in a flex layout which prevents margins from collapsing because each item creates its own row\n p + p {\n margin-top: 0;\n }\n\n verdocs-help-icon {\n margin-top: 18px;\n display: flex;\n width: 32px;\n height: 32px;\n flex: 0 0 32px;\n }\n\n .already-have {\n color: $verdocs-grey-0;\n margin: 0.5em 0;\n font-size: 14px;\n text-align: center;\n }\n\n .service-agreement {\n font-size: 12px;\n color: #777;\n\n a {\n color: $verdocs-grey-0;\n }\n }\n}\n","import {Component, Prop, State, h, Event, EventEmitter} from '@stencil/core';\nimport {verifyEmail, IAuthenticateResponse, getMyUser, IProfile, convertToE164} from '@verdocs/js-sdk';\nimport {TSession, VerdocsEndpoint, createProfile, authenticate, resendVerification, resetPassword} from '@verdocs/js-sdk';\nimport {VerdocsToast} from '../../../utils/Toast';\nimport {SDKError} from '../../../utils/errors';\n\nexport interface IAuthStatus {\n authenticated: boolean;\n session: TSession;\n profile: IProfile | null;\n}\n\n/**\n * Display an authentication dialog that allows the user to login or sign up. If the user is\n * already authenticated with a valid session, this component will hide itself and fire the\n * success callback immediately. It is up to the host application to render the next appropriate\n * view for the application.\n *\n * To simplify UI development, a visibility flag can force this component to never display. This\n * allows you to subscribe to notifications from client apps without calling the lower-level JS SDK.\n *\n * This embed is responsive / mobile-friendly, but the calling application should provide at\n * least a 300px wide container to allow sufficient space for the required forms.\n *\n * ```ts\n * <verdocs-auth\n * onAuthenticated={({ detail }) => console.log('Authentication state:', detail) }\n * onSdkError={({ detail }) => { console.log('SDK error', detail) }\n * />\n * ```\n */\n@Component({\n tag: 'verdocs-auth',\n styleUrl: 'verdocs-auth.scss',\n shadow: false,\n})\nexport class VerdocsAuth {\n /**\n * The endpoint to use to communicate with Verdocs. If not set, the default endpoint will be used.\n */\n @Prop() endpoint: VerdocsEndpoint = VerdocsEndpoint.getDefault();\n\n /**\n * Normally, if the user has a valid session, this embed will be invisible, otherwise it will display\n * login / signup forms. If this is set to false, this embed will be invisible in both cases. Apps may\n * use this to verify if a user has a valid session without needing a separate call to Verdocs JS SDK.\n */\n @Prop() visible: boolean = true;\n\n /**\n * By default, a Verdocs logo will be displayed above the login/signup forms. This may be used to\n * override its source. (Alternatively, you may simply hide it via CSS overrides.) Logos should be\n * in SVG format for best results.\n */\n @Prop() logo: string = 'https://app.verdocs.com/assets/blue-logo.svg';\n\n /**\n * The display mode to start in.\n */\n @Prop({mutable: true}) displayMode: 'login' | 'forgot' | 'reset' | 'signup' | 'verify' = 'login';\n\n /**\n * Event fired when session authentication process has completed. Check the event\n * contents for completion status. This event will always be called at least once,\n * when the component is first rendered.\n */\n @Event({composed: true}) authenticated: EventEmitter<IAuthStatus>;\n\n /**\n * Event fired if an error occurs. The event details will contain information about the error. Most errors will\n * terminate the process, and the calling application should correct the condition and re-render the component.\n */\n @Event({composed: true}) sdkError: EventEmitter<SDKError>;\n\n @State() org_name: string = '';\n @State() first_name: string = '';\n @State() last_name: string = '';\n @State() email: string = '';\n @State() phone: string = '';\n @State() verificationCode: string = '';\n @State() newPassword: string = '';\n @State() password: string = '';\n @State() confirmpass: string = '';\n @State() submitting: boolean = false;\n @State() resendDisabled = false;\n @State() session: TSession = null;\n @State() profile: IProfile | null = null;\n\n resendDisabledTimer = null;\n\n // We can't instantly log in on the default endpoint because other listeners might see\n // its events and incorrectly trigger before we're done. So we manage our own temp\n // endpoint and pass the final tokens to the default once we're ready.\n tempAuthEndpoint = new VerdocsEndpoint({\n baseURL: VerdocsEndpoint.getDefault().getBaseURL(),\n persist: false,\n });\n\n componentWillLoad() {\n this.endpoint.loadSession();\n this.applyHashDisplayMode();\n\n // We need to listen to the hashchange to know when we're being sent to #forgot\n if (typeof window !== 'undefined') {\n window.addEventListener('hashchange', this.handleHashChange);\n }\n\n VerdocsEndpoint.getDefault().onSessionChanged((_endpoint, session, profile) => {\n this.session = session;\n this.profile = profile;\n if (session) {\n this.authenticated?.emit({authenticated: true, session, profile});\n } else {\n this.authenticated?.emit({authenticated: false, session, profile});\n }\n });\n }\n\n disconnectedCallback() {\n if (typeof window !== 'undefined') {\n window.removeEventListener('hashchange', this.handleHashChange);\n }\n }\n\n handleHashChange = () => {\n this.applyHashDisplayMode();\n };\n\n applyHashDisplayMode() {\n if (typeof window === 'undefined') {\n return;\n }\n\n const hash = (window.location.hash || '').replace(/^#/, '').toLowerCase();\n if (hash === 'forgot') {\n this.displayMode = 'forgot';\n }\n }\n\n isPasswordComplex(password: string) {\n const isUppercase = (ch: string) => /[A-Z]/.test(ch);\n const isLowercase = (ch: string) => /[a-z]/.test(ch);\n const isSpecialChar = (ch: string) => /[`!@#$%^&*()_\\-+=\\[\\]{};':\"\\\\|,.<>\\/?~ ]/.test(ch);\n let countOfUpperCase = 0,\n countOfLowerCase = 0,\n countOfSpecialChar = 0;\n for (let i = 0; i < password.length; i++) {\n let ch = password.charAt(i);\n if (isUppercase(ch)) countOfUpperCase++;\n else if (isLowercase(ch)) countOfLowerCase++;\n else if (isSpecialChar(ch)) countOfSpecialChar++;\n }\n return password.length >= 8 && countOfLowerCase > 0 && countOfUpperCase > 0 && countOfSpecialChar > 0;\n }\n\n handleSignup() {\n if (!this.isPasswordComplex(this.password)) {\n VerdocsToast('Password must be at least 8 characters long and contain at least one uppercase, one lowercase, and one special character.', {style: 'error'});\n return;\n }\n\n if (this.password !== this.confirmpass) {\n VerdocsToast('Passwords do not match.', {style: 'error'});\n return;\n }\n\n this.submitting = true;\n this.tempAuthEndpoint.clearSession();\n const formattedPhone = convertToE164(this.phone);\n const localeData = Intl.DateTimeFormat().resolvedOptions();\n\n createProfile(this.tempAuthEndpoint, {\n email: this.email,\n password: this.password,\n first_name: this.first_name,\n last_name: this.last_name,\n org_name: this.org_name,\n phone: formattedPhone,\n timezone: localeData.timeZone,\n locale: localeData.locale,\n })\n .then(r => {\n console.log('[AUTH] Profile creation result', r);\n this.tempAuthEndpoint.setToken(r.access_token);\n // We can't clearForms because we need email to stick around\n this.password = '';\n this.phone = '';\n this.first_name = '';\n this.last_name = '';\n this.org_name = '';\n this.displayMode = 'verify';\n this.submitting = false;\n })\n .catch(e => {\n console.log('[AUTH] Signup error', e.response);\n this.submitting = false;\n this.authenticated?.emit({authenticated: false, profile: null, session: null});\n this.sdkError?.emit(new SDKError(e.message, e.response?.status, e.response?.data));\n\n VerdocsToast('Signup failed: ' + e.response?.data?.error || 'Unknown Error', {style: 'error'});\n });\n }\n\n async handleVerification() {\n this.submitting = true;\n\n try {\n this.submitting = false;\n const verificationResult = await verifyEmail(this.tempAuthEndpoint, {email: this.email, token: this.verificationCode});\n VerdocsToast('Thank you for verifying your email address.', {style: 'success'});\n this.completeLogin(verificationResult);\n } catch (e) {\n this.submitting = false;\n console.log('Verification error', e);\n VerdocsToast('Verification error, please check the code and try again.');\n }\n }\n\n completeLogin(result: IAuthenticateResponse) {\n this.clearForms();\n this.tempAuthEndpoint.clearSession();\n this.endpoint.setToken(result.access_token);\n }\n\n async loginAndCheckVerification() {\n if (this.submitting) {\n return;\n }\n\n this.submitting = true;\n this.tempAuthEndpoint.clearSession();\n\n try {\n this.submitting = false;\n const authResult = await authenticate(this.tempAuthEndpoint, {username: this.email.trim(), password: this.password, grant_type: 'password'});\n console.log('[AUTH] Authenticated, checking email verification');\n this.tempAuthEndpoint.setToken(authResult.access_token);\n\n const user = await getMyUser(this.tempAuthEndpoint);\n\n if (!user.email_verified) {\n console.log('[AUTH] Logged in, pending email address verification');\n this.displayMode = 'verify';\n } else {\n console.log('[AUTH] Email address is verified, completing login');\n this.completeLogin(authResult);\n }\n } catch (e) {\n this.submitting = false;\n console.log('[AUTH] Auth failure', e.response?.data || e);\n VerdocsToast('Login failed. Please check your credentials and try again.', {style: 'error'});\n }\n }\n\n clearForms() {\n this.submitting = false;\n this.resendDisabled = false;\n this.email = '';\n this.phone = '';\n this.password = '';\n this.newPassword = '';\n this.confirmpass = '';\n this.verificationCode = '';\n this.first_name = '';\n this.last_name = '';\n this.org_name = '';\n }\n\n handleLogout() {\n console.log('logging out');\n this.endpoint.clearSession();\n this.tempAuthEndpoint.clearSession();\n this.clearForms();\n this.displayMode = 'login';\n }\n\n handleResendVerification() {\n // Avoid the user just click-spamming this pathway. The server rate-limits this anyway so it's not a\n // security issue but it's a poor user experience to allow it.\n this.resendDisabled = true;\n this.resendDisabledTimer = setTimeout(() => {\n this.resendDisabled = false;\n this.resendDisabledTimer = null;\n }, 30000);\n\n resendVerification(this.tempAuthEndpoint)\n .then(r => {\n console.log('[AUTH] Verification request resent', r);\n VerdocsToast('Please check your email for a verification code.', {style: 'info'});\n })\n .catch((e: any) => {\n console.log('[AUTH] Unable to resend verification', e);\n VerdocsToast('Unable to resend code. Please try again later.', {style: 'error'});\n });\n }\n\n handleResendReset() {\n // Avoid the user just click-spamming this pathway. The server rate-limits this anyway so it's not a\n // security issue but it's a poor user experience to allow it.\n this.resendDisabled = true;\n this.resendDisabledTimer = setTimeout(() => {\n this.resendDisabled = false;\n this.resendDisabledTimer = null;\n }, 30000);\n\n resetPassword(this.tempAuthEndpoint, {email: this.email})\n .then(r => {\n console.log('[AUTH] Resend-code request resent', r);\n VerdocsToast('Please check your email again for a verification code.', {style: 'info'});\n })\n .catch((e: any) => {\n console.log('[AUTH] Unable to resend reset request', e);\n VerdocsToast('Unable to resend code. Please try again later.', {style: 'error'});\n });\n }\n\n async handleResetGetCode() {\n this.submitting = true;\n this.confirmpass = '';\n this.newPassword = '';\n\n try {\n this.submitting = false;\n const result = await resetPassword(this.endpoint, {email: this.email});\n console.log('[AUTH] Reset result', result);\n VerdocsToast('Please check your email inbox for a password reset code.', {style: 'success'});\n this.verificationCode = '';\n this.confirmpass = '';\n this.newPassword = '';\n this.displayMode = 'reset';\n } catch (e) {\n this.submitting = false;\n console.log('Reset request error', e);\n VerdocsToast('Request failed. Please check your email address and try again.');\n }\n }\n\n async handleResetPassword() {\n if (!this.isPasswordComplex(this.newPassword)) {\n VerdocsToast('Password must be at least 8 characters long and contain at least one uppercase, one lowercase, and one special character.', {style: 'error'});\n return;\n }\n\n if (this.newPassword !== this.confirmpass) {\n VerdocsToast('Passwords do not match.', {style: 'error'});\n return;\n }\n\n this.submitting = true;\n try {\n this.submitting = false;\n const resetResult = await resetPassword(this.endpoint, {email: this.email, code: this.verificationCode, new_password: this.newPassword});\n console.log('reset result', resetResult);\n VerdocsToast('Your password has been reset. You may now use your new password to login.', {style: 'success'});\n this.verificationCode = '';\n this.confirmpass = '';\n this.newPassword = '';\n this.password = '';\n this.displayMode = 'login';\n } catch (e) {\n this.submitting = false;\n console.log('Verification error', e);\n VerdocsToast('Verification error, please check the code and try again.');\n }\n }\n\n async handleReset() {\n this.submitting = true;\n\n try {\n const result = await resetPassword(this.endpoint, {email: this.email});\n console.log('[AUTH] Reset sent', result);\n this.submitting = false;\n this.displayMode = 'login';\n VerdocsToast('If your email address is registered, you will receive instructions on resetting your password shortly.', {style: 'info'});\n } catch (e) {\n console.log('[AUTH] Unable to reset password', e);\n this.submitting = false;\n VerdocsToast('Unable to reset password. Please check your email address and try again.', {style: 'error'});\n }\n }\n\n render() {\n if (!this.visible) {\n return <div style={{display: 'none'}}>Authenticated</div>;\n }\n\n if (this.session) {\n return (\n <verdocs-button\n label=\"Sign Out\"\n disabled={this.submitting}\n onClick={() => this.handleLogout()}\n style={{display: 'flex', justifyContent: 'center', margin: '30px auto 0'}}\n />\n );\n }\n\n if (this.displayMode === 'signup') {\n const invalid = this.submitting || !this.first_name || !this.last_name || !this.email || !this.password || !this.confirmpass || !this.org_name;\n\n return (\n <div class=\"form\">\n <a href=\"https://verdocs.com/en/\">\n <img src={this.logo} alt=\"Verdocs Logo\" class=\"logo\" />\n </a>\n\n <h3>Sign up for a free account</h3>\n <div class=\"already-have\">\n Already have an account?\n <verdocs-button label=\"Log In\" variant=\"text\" onClick={() => (this.displayMode = 'login')} disabled={this.submitting} />\n </div>\n\n <form onSubmit={() => this.handleSignup()}>\n <div style={{display: 'flex', flexDirection: 'row', columnGap: '20px'}}>\n <verdocs-text-input\n label=\"First Name\"\n autocomplete=\"first\"\n required={true}\n value={this.first_name}\n onInput={(e: any) => (this.first_name = e.target.value)}\n disabled={this.submitting}\n />\n <verdocs-text-input\n label=\"Last Name\"\n autocomplete=\"last\"\n required={true}\n value={this.last_name}\n onInput={(e: any) => (this.last_name = e.target.value)}\n disabled={this.submitting}\n />\n </div>\n <verdocs-text-input\n label=\"Email Address\"\n autocomplete=\"email\"\n required={true}\n value={this.email}\n onInput={(e: any) => (this.email = e.target.value)}\n disabled={this.submitting}\n />\n <verdocs-text-input\n label=\"Password\"\n type=\"password\"\n required={true}\n autocomplete=\"new-password\"\n value={this.password}\n onInput={(e: any) => (this.password = e.target.value)}\n disabled={this.submitting}\n />\n <verdocs-text-input\n label=\"Confirm Password\"\n type=\"password\"\n required={true}\n autocomplete=\"off\"\n value={this.confirmpass}\n onInput={(e: any) => (this.confirmpass = e.target.value)}\n disabled={this.submitting}\n />\n <verdocs-text-input\n label=\"Phone Number\"\n type=\"tel\"\n required={true}\n autocomplete=\"phone\"\n value={this.phone}\n onInput={(e: any) => (this.phone = e.target.value)}\n disabled={this.submitting}\n />\n <verdocs-text-input\n label=\"Organization Name\"\n autocomplete=\"org\"\n required={true}\n value={this.org_name}\n onInput={(e: any) => (this.org_name = e.target.value)}\n disabled={this.submitting}\n style={{flex: '1'}}\n />\n\n <div class=\"service-agreement\">\n By clicking the Create Account button, you agree to the{' '}\n <a href=\"https://verdocs.com/eula\" target=\"_blank\">\n End User License Agreement\n </a>\n . Learn about how we use and protect your data and how you can opt-out in our{' '}\n <a href=\"https://verdocs.com/privacy-policy\" target=\"_blank\">\n Privacy Policy\n </a>\n .\n </div>\n\n <div style={{marginTop: '30px'}} />\n\n <verdocs-button\n label=\"Next\"\n disabled={invalid}\n onClick={invalid ? () => {} : () => this.handleSignup()}\n style={{display: 'flex', justifyContent: 'center', margin: '30px auto 0'}}\n />\n </form>\n </div>\n );\n }\n\n if (this.displayMode === 'verify') {\n return (\n <div class=\"form\">\n <form onSubmit={() => this.handleVerification()}>\n <p>Please check your e-mail inbox for a verification code and enter it below.</p>\n\n <verdocs-text-input\n label=\"Verification Code\"\n required={true}\n value={this.verificationCode}\n onInput={(e: any) => (this.verificationCode = e.target.value)}\n disabled={this.submitting}\n />\n\n <div class=\"buttons\">\n <verdocs-button label=\"Sign Out\" variant=\"outline\" disabled={this.submitting} onClick={() => this.handleLogout()} />\n <verdocs-button label=\"Verify\" disabled={this.submitting || !this.verificationCode || this.verificationCode.length !== 6} onClick={() => this.handleVerification()} />\n </div>\n <div class=\"buttons\">\n <verdocs-button variant=\"text\" label=\"Resend Code\" disabled={this.resendDisabled || this.submitting} onClick={() => this.handleResendVerification()} />\n </div>\n </form>\n </div>\n );\n }\n\n if (this.displayMode === 'forgot') {\n return (\n <div class=\"form\">\n <a href=\"https://verdocs.com/en/\">\n <img src={this.logo} alt=\"Verdocs Logo\" class=\"logo\" />\n </a>\n\n <h3>Forgot your password?</h3>\n\n <p>\n Enter your e-mail address below. If the e-mail address is valid, a password reset code will be sent to your inbox. Please allow up to 15 minutes to arrive, and check\n your spam folder if you do not receive the message.\n </p>\n\n <form onSubmit={() => this.handleResetGetCode()}>\n <verdocs-text-input\n label=\"Email Address\"\n autocomplete=\"email\"\n required={true}\n value={this.email}\n onInput={(e: any) => (this.email = e.target.value)}\n disabled={this.submitting}\n />\n\n <div style={{marginTop: '30px'}} />\n\n <div class=\"buttons\">\n <verdocs-button size=\"small\" label=\"Cancel\" variant=\"outline\" disabled={this.submitting} onClick={() => (this.displayMode = 'login')} />\n <verdocs-button size=\"small\" label=\"Request Code\" disabled={this.submitting} onClick={() => this.handleResetGetCode()} />\n </div>\n </form>\n </div>\n );\n }\n\n if (this.displayMode === 'reset') {\n return (\n <div class=\"form\">\n <a href=\"https://verdocs.com/en/\">\n <img src={this.logo} alt=\"Verdocs Logo\" class=\"logo\" />\n </a>\n\n <h3>Forgot your password?</h3>\n\n <p>\n Enter your e-mail address below, and reset instructions will be sent to your Inbox. Please allow up to 15 minutes to arrive. Check your spam folder if you do not\n receive the message.\n </p>\n\n <form onSubmit={() => this.handleResetPassword()}>\n <verdocs-text-input\n label=\"Verification Code\"\n required={true}\n value={this.verificationCode}\n onInput={(e: any) => (this.verificationCode = e.target.value)}\n disabled={this.submitting}\n />\n <verdocs-text-input\n label=\"Password\"\n type=\"password\"\n required={true}\n autocomplete=\"off\"\n value={this.newPassword}\n onInput={(e: any) => (this.newPassword = e.target.value)}\n disabled={this.submitting}\n />\n <verdocs-text-input\n label=\"Confirm Password\"\n type=\"password\"\n required={true}\n autocomplete=\"off\"\n value={this.confirmpass}\n onInput={(e: any) => (this.confirmpass = e.target.value)}\n disabled={this.submitting}\n />\n\n <div style={{marginTop: '30px'}} />\n\n <div class=\"buttons\">\n <verdocs-button label=\"Cancel\" variant=\"outline\" disabled={this.submitting} onClick={() => (this.displayMode = 'login')} />\n <verdocs-button label=\"Reset\" disabled={this.submitting} onClick={() => this.handleResetPassword()} />\n </div>\n\n <div class=\"buttons\">\n <verdocs-button variant=\"text\" label=\"Resend Code\" disabled={this.resendDisabled || this.submitting} onClick={() => this.handleResendReset()} />\n </div>\n </form>\n </div>\n );\n }\n\n return (\n <div class=\"form\">\n <a href=\"https://verdocs.com/en/\">\n <img src={this.logo} alt=\"Verdocs Logo\" class=\"logo\" />\n </a>\n\n <h3>Log in to your account</h3>\n <div class=\"already-have\">\n Don't have an account?\n <verdocs-button label=\"Sign Up\" variant=\"text\" onClick={() => (this.displayMode = 'signup')} disabled={this.submitting} />\n </div>\n\n <form onSubmit={() => this.loginAndCheckVerification()}>\n <verdocs-text-input label=\"Email\" autocomplete=\"username\" value={this.email} onInput={(e: any) => (this.email = e.target.value)} disabled={this.submitting} />\n <verdocs-text-input\n label=\"Password\"\n type=\"password\"\n autocomplete=\"current-password\"\n value={this.password}\n onInput={(e: any) => (this.password = e.target.value)}\n disabled={this.submitting}\n />\n\n <verdocs-button\n label=\"Forgot Your Password?\"\n variant=\"text\"\n onClick={() => (this.displayMode = 'forgot')}\n disabled={this.submitting}\n style={{display: 'flex', justifyContent: 'center', margin: '10px auto 20px'}}\n />\n\n <verdocs-button\n label=\"Login\"\n disabled={this.submitting}\n onClick={() => this.loginAndCheckVerification()}\n style={{display: 'flex', justifyContent: 'center', margin: '10px auto 0'}}\n />\n </form>\n </div>\n );\n }\n}\n"],"names":[],"mappings":";;;;;AAAA,MAAM,cAAc,GAAG,MAAM,CAAC,qwDAAqwD,CAAC;;MCoCvxD,WAAW,GAAA,MAAA;AALxB,IAAA,WAAA,CAAA,OAAA,EAAA;;;;AAME;;AAEG;AACK,QAAA,IAAA,CAAA,QAAQ,GAAoB,eAAe,CAAC,UAAU,EAAE;AAEhE;;;;AAIG;AACK,QAAA,IAAA,CAAA,OAAO,GAAY,IAAI;AAE/B;;;;AAIG;AACK,QAAA,IAAA,CAAA,IAAI,GAAW,8CAA8C;AAErE;;AAEG;AACoB,QAAA,IAAA,CAAA,WAAW,GAAuD,OAAO;AAevF,QAAA,IAAA,CAAA,QAAQ,GAAW,EAAE;AACrB,QAAA,IAAA,CAAA,UAAU,GAAW,EAAE;AACvB,QAAA,IAAA,CAAA,SAAS,GAAW,EAAE;AAC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B,KAAK,EAAE,IAAI,CAAC,QAAQ,EACpB,OAAO,EAAE,CAAC,CAAM,MAAM,IAAI,CAAC,QAAQ,GAAG,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,EACrD,QAAQ,EAAE,IAAI,CAAC,UAAU,EAAA,CACzB,EAEF,CAAA,CAAA,gBAAA,EAAA,EACE,KAAK,EAAC,uBAAuB,EAC7B,OAAO,EAAC,MAAM,EACd,OAAO,EAAE,OAAO,IAAI,CAAC,WAAW,GAAG,QAAQ,CAAC,EAC5C,QAAQ,EAAE,IAAI,CAAC,UAAU,EACzB,KAAK,EAAE,EAAC,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,QAAQ,EAAE,MAAM,EAAE,gBAAgB,EAAC,EAAA,CAC5E,EAEF,CAAA,CAAA,gBAAA,EAAA,EACE,KAAK,EAAC,OAAO,EACb,QAAQ,EAAE,IAAI,CAAC,UAAU,EACzB,OAAO,EAAE,MAAM,IAAI,CAAC,yBAAyB,EAAE,EAC/C,KAAK,EAAE,EAAC,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,QAAQ,EAAE,MAAM,EAAE,aAAa,EAAC,GACzE,CACG,CACH;;;;;;;"}
1
+ {"version":3,"file":"verdocs-auth.entry.js","sources":["src/components/embeds/verdocs-auth/verdocs-auth.scss?tag=verdocs-auth","src/components/embeds/verdocs-auth/verdocs-auth.tsx"],"sourcesContent":["@import '../../../theme.scss';\n\nverdocs-auth {\n font-family: $verdocs-primary-font;\n display: flex;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n\n .form {\n width: 350px;\n display: flex;\n padding: 20px;\n max-width: 90%;\n align-items: center;\n flex-direction: column;\n box-sizing: border-box;\n justify-content: center;\n background: $verdocs-grey-4;\n }\n\n .logo {\n width: 128px;\n max-width: 100%;\n margin: 20px 0 30px;\n }\n\n h3 {\n color: $verdocs-grey-0;\n text-align: center;\n font-weight: 400;\n font-size: 18px;\n line-height: 1.75;\n margin: 0 0 20px 0;\n }\n\n em {\n font-size: 14px;\n margin: 15px 0;\n }\n\n .buttons {\n gap: 20px;\n margin: 20px 0 0 0;\n display: flex;\n flex-direction: row;\n justify-content: center;\n }\n\n .status-result {\n display: none;\n\n &.debug {\n white-space: pre-wrap;\n font-size: 14px;\n background: #fff;\n padding: 10px;\n display: block;\n flex-direction: row;\n justify-content: center;\n }\n }\n\n form {\n width: 100%;\n }\n\n verdocs-text-input {\n margin-bottom: 10px;\n }\n\n .account-option {\n gap: 8px;\n margin: 20px 0 8px 0;\n display: flex;\n flex-direction: row;\n }\n\n p {\n color: $verdocs-grey-0;\n margin: 1em 0;\n font-size: 14px;\n }\n\n // Our <p>s are in a flex layout which prevents margins from collapsing because each item creates its own row\n p + p {\n margin-top: 0;\n }\n\n verdocs-help-icon {\n margin-top: 18px;\n display: flex;\n width: 32px;\n height: 32px;\n flex: 0 0 32px;\n }\n\n .already-have {\n color: $verdocs-grey-0;\n margin: 0.5em 0;\n font-size: 14px;\n text-align: center;\n }\n\n .service-agreement {\n font-size: 12px;\n color: #777;\n\n a {\n color: $verdocs-grey-0;\n }\n }\n\n .providers {\n width: 100%;\n\n verdocs-button {\n display: block;\n margin-bottom: 10px;\n\n button.outline {\n position: relative;\n border-color: $verdocs-grey-2;\n\n &:disabled {\n border-color: $verdocs-grey-2;\n }\n }\n\n .icon.start {\n position: absolute;\n left: 16px;\n margin: 0;\n display: flex;\n align-items: center;\n\n svg {\n width: 18px;\n height: 18px;\n }\n }\n }\n }\n\n .divider {\n gap: 8px;\n color: #777;\n display: flex;\n font-size: 12px;\n margin: 28px 0;\n align-items: center;\n flex-direction: row;\n\n .divider-line {\n flex: 1;\n height: 1px;\n background: $verdocs-grey-2;\n }\n }\n\n .mfa-error {\n color: $verdocs-red-1;\n font-size: 14px;\n margin: 0 0 8px;\n }\n}\n","import {Component, Prop, State, h, Event, EventEmitter, Element} from '@stencil/core';\nimport {TSession, VerdocsEndpoint, createProfile, authenticate, resendVerification, resetPassword} from '@verdocs/js-sdk';\nimport {isMFARequired, getSocialProviders, getSocialLoginUrl, createCodeVerifier, createCodeChallenge} from '@verdocs/js-sdk';\nimport {verifyEmail, IAuthenticateResponse, getMyUser, IProfile, convertToE164, ISocialProviders, TSocialLoginProvider} from '@verdocs/js-sdk';\nimport {GoogleIcon, MicrosoftIcon} from '../../../utils/Icons';\nimport {VerdocsToast} from '../../../utils/Toast';\nimport {SDKError} from '../../../utils/errors';\n\nexport interface IAuthStatus {\n authenticated: boolean;\n session: TSession;\n profile: IProfile | null;\n}\n\nconst MFA_CODE_ERROR = 'Invalid code. Please try again.';\nconst SOCIAL_START_ERROR = 'Unable to start sign-in sequence. Please try again.';\nconst SOCIAL_LOGIN_KEY = 'vdocs-social-login';\n\ninterface ISocialLoginAttempt {\n verifier: string;\n state: string;\n provider: TSocialLoginProvider;\n}\n\nconst SOCIAL_ERROR_MESSAGES: Record<string, string> = {\n email_unverified: 'That account does not have a verified email address.',\n corporate_email_required: 'Please use your corporate email address to create an account.',\n account_locked: 'That account is locked. Please contact support@verdocs.com.',\n provider_error: 'That provider could not sign you in. Please try again.',\n access_denied: 'Sign-in was canceled.',\n};\n\nconst socialErrorMessage = (code: string) => SOCIAL_ERROR_MESSAGES[code] || 'Unable to sign in. Please try again.';\n\nconst readSocialLoginAttempt = (): ISocialLoginAttempt | null => {\n try {\n const stored = window.sessionStorage.getItem(SOCIAL_LOGIN_KEY);\n return stored ? (JSON.parse(stored) as ISocialLoginAttempt) : null;\n } catch {\n return null;\n }\n};\n\nconst clearSocialLoginAttempt = () => {\n try {\n window.sessionStorage.removeItem(SOCIAL_LOGIN_KEY);\n } catch {\n // Third-party embeds may block sessionStorage. It's OK.\n }\n};\n\n// Prevent replays on a reload\nconst cleanSocialLoginParams = (names: string[]) => {\n const url = new URL(window.location.href);\n names.forEach(name => url.searchParams.delete(name));\n window.history.replaceState({}, '', `${url.pathname}${url.search}${url.hash}`);\n};\n\nconst currentReturnUri = () => `${window.location.origin}${window.location.pathname}`;\n\nconst formatRecoveryCode = (value: string) => {\n const cleaned = value\n .toLowerCase()\n .replace(/[^a-z0-9]/g, '')\n .slice(0, 8);\n return cleaned.length > 4 ? `${cleaned.slice(0, 4)}-${cleaned.slice(4)}` : cleaned;\n};\n\n/**\n * Display an authentication dialog that allows the user to login or sign up. If the user is\n * already authenticated with a valid session, this component will hide itself and fire the\n * success callback immediately. It is up to the host application to render the next appropriate\n * view for the application.\n *\n * To simplify UI development, a visibility flag can force this component to never display. This\n * allows you to subscribe to notifications from client apps without calling the lower-level JS SDK.\n *\n * This embed is responsive and mobile-friendly, but the calling application should provide at\n * least a 300px wide container to allow sufficient space for the required forms.\n *\n * ```ts\n * <verdocs-auth\n * onAuthenticated={({ detail }) => console.log('Authentication state:', detail) }\n * onSdkError={({ detail }) => { console.log('SDK error', detail) }\n * />\n * ```\n */\n@Component({\n tag: 'verdocs-auth',\n styleUrl: 'verdocs-auth.scss',\n shadow: false,\n})\nexport class VerdocsAuth {\n @Element() el: HTMLElement;\n\n /**\n * The endpoint to use to communicate with Verdocs. If not set, the default endpoint will be used.\n */\n @Prop() endpoint: VerdocsEndpoint = VerdocsEndpoint.getDefault();\n\n /**\n * Normally, if the user has a valid session, this embed will be invisible, otherwise it will display\n * login / signup forms. If this is set to false, this embed will be invisible in both cases. Apps may\n * use this to verify if a user has a valid session without needing a separate call to Verdocs JS SDK.\n */\n @Prop() visible: boolean = true;\n\n /**\n * By default, a Verdocs logo will be displayed above the login/signup forms. This may be used to\n * override its source. (Alternatively, you may simply hide it via CSS overrides.) Logos should be\n * in SVG format for best results.\n */\n @Prop() logo: string = 'https://app.verdocs.com/assets/blue-logo.svg';\n\n /**\n * The display mode to start in.\n */\n @Prop({mutable: true}) displayMode: 'login' | 'forgot' | 'reset' | 'signup' | 'verify' | 'mfa' = 'login';\n\n /**\n * Social auth is disabled by default because these are redirect flows that require allowable redirect_uri\n * destinations be pre-registered. These will only work on Verdocs sites/apps, so third-party developers\n * should not turn this on unless instructed to by Verdocs Support.\n */\n @Prop() showSocialLogins: boolean = false;\n\n /**\n * Event fired when session authentication process has completed. Check the event\n * contents for completion status. This event will always be called at least once,\n * when the component is first rendered.\n */\n @Event({composed: true}) authenticated: EventEmitter<IAuthStatus>;\n\n /**\n * Event fired if an error occurs. The event details will contain information about the error. Most errors will\n * terminate the process, and the calling application should correct the condition and re-render the component.\n */\n @Event({composed: true}) sdkError: EventEmitter<SDKError>;\n\n @State() org_name: string = '';\n @State() first_name: string = '';\n @State() last_name: string = '';\n @State() email: string = '';\n @State() phone: string = '';\n @State() verificationCode: string = '';\n @State() newPassword: string = '';\n @State() password: string = '';\n @State() confirmpass: string = '';\n @State() submitting: boolean = false;\n @State() resendDisabled = false;\n @State() session: TSession = null;\n @State() profile: IProfile | null = null;\n @State() providers: ISocialProviders = {google: false, microsoft: false};\n @State() mfaToken: string = '';\n @State() mfaCode: string = '';\n @State() recoveryCode: string = '';\n @State() useRecoveryCode: boolean = false;\n @State() mfaError: string = '';\n\n resendDisabledTimer = null;\n mfaFocusPending = false;\n\n // We can't instantly log in on the default endpoint because other listeners might see\n // its events and incorrectly trigger before we're done. So we manage our own temp\n // endpoint and pass the final tokens to the default once we're ready.\n tempAuthEndpoint = new VerdocsEndpoint({\n baseURL: VerdocsEndpoint.getDefault().getBaseURL(),\n persist: false,\n });\n\n componentWillLoad() {\n this.endpoint.loadSession();\n this.applyHashDisplayMode();\n\n // We need to listen to the hashchange to know when we're being sent to #forgot\n if (typeof window !== 'undefined') {\n window.addEventListener('hashchange', this.handleHashChange);\n }\n\n VerdocsEndpoint.getDefault().onSessionChanged((_endpoint, session, profile) => {\n this.session = session;\n this.profile = profile;\n if (session) {\n this.authenticated?.emit({authenticated: true, session, profile});\n } else {\n this.authenticated?.emit({authenticated: false, session, profile});\n }\n });\n\n if (this.showSocialLogins) {\n getSocialProviders(this.endpoint)\n .then(providers => {\n this.providers = providers;\n })\n .catch(() => undefined);\n }\n\n this.handleSocialLoginReturn();\n }\n\n componentDidRender() {\n if (this.displayMode !== 'mfa') {\n return;\n }\n\n const input = this.el.querySelector('.mfa-input input') as HTMLInputElement | null;\n if (!input) {\n return;\n }\n\n if (!this.useRecoveryCode) {\n input.setAttribute('inputmode', 'numeric');\n } else {\n input.removeAttribute('inputmode');\n }\n\n if (this.mfaFocusPending) {\n this.mfaFocusPending = false;\n input.focus();\n }\n }\n\n disconnectedCallback() {\n if (typeof window !== 'undefined') {\n window.removeEventListener('hashchange', this.handleHashChange);\n }\n }\n\n handleHashChange = () => {\n this.applyHashDisplayMode();\n };\n\n applyHashDisplayMode() {\n if (typeof window === 'undefined') {\n return;\n }\n\n const hash = (window.location.hash || '').replace(/^#/, '').toLowerCase();\n if (hash === 'forgot') {\n this.displayMode = 'forgot';\n }\n }\n\n isPasswordComplex(password: string) {\n const isUppercase = (ch: string) => /[A-Z]/.test(ch);\n const isLowercase = (ch: string) => /[a-z]/.test(ch);\n const isSpecialChar = (ch: string) => /[`!@#$%^&*()_\\-+=\\[\\]{};':\"\\\\|,.<>\\/?~ ]/.test(ch);\n let countOfUpperCase = 0,\n countOfLowerCase = 0,\n countOfSpecialChar = 0;\n for (let i = 0; i < password.length; i++) {\n let ch = password.charAt(i);\n if (isUppercase(ch)) countOfUpperCase++;\n else if (isLowercase(ch)) countOfLowerCase++;\n else if (isSpecialChar(ch)) countOfSpecialChar++;\n }\n return password.length >= 8 && countOfLowerCase > 0 && countOfUpperCase > 0 && countOfSpecialChar > 0;\n }\n\n handleSignup() {\n if (!this.isPasswordComplex(this.password)) {\n VerdocsToast('Password must be at least 8 characters long and contain at least one uppercase, one lowercase, and one special character.', {style: 'error'});\n return;\n }\n\n if (this.password !== this.confirmpass) {\n VerdocsToast('Passwords do not match.', {style: 'error'});\n return;\n }\n\n this.submitting = true;\n this.tempAuthEndpoint.clearSession();\n const formattedPhone = convertToE164(this.phone);\n const localeData = Intl.DateTimeFormat().resolvedOptions();\n\n createProfile(this.tempAuthEndpoint, {\n email: this.email,\n password: this.password,\n first_name: this.first_name,\n last_name: this.last_name,\n org_name: this.org_name,\n phone: formattedPhone,\n timezone: localeData.timeZone,\n locale: localeData.locale,\n })\n .then(r => {\n console.log('[AUTH] Profile creation result', r);\n this.tempAuthEndpoint.setToken(r.access_token);\n // We can't clearForms because we need email to stick around\n this.password = '';\n this.phone = '';\n this.first_name = '';\n this.last_name = '';\n this.org_name = '';\n this.displayMode = 'verify';\n this.submitting = false;\n })\n .catch(e => {\n console.log('[AUTH] Signup error', e.response);\n this.submitting = false;\n this.authenticated?.emit({authenticated: false, profile: null, session: null});\n this.sdkError?.emit(new SDKError(e.message, e.response?.status, e.response?.data));\n\n VerdocsToast('Signup failed: ' + e.response?.data?.error || 'Unknown Error', {style: 'error'});\n });\n }\n\n async handleVerification() {\n this.submitting = true;\n\n try {\n this.submitting = false;\n const verificationResult = await verifyEmail(this.tempAuthEndpoint, {email: this.email, token: this.verificationCode});\n VerdocsToast('Thank you for verifying your email address.', {style: 'success'});\n this.completeLogin(verificationResult);\n } catch (e) {\n this.submitting = false;\n console.log('Verification error', e);\n VerdocsToast('Verification error, please check the code and try again.');\n }\n }\n\n completeLogin(result: IAuthenticateResponse) {\n this.clearForms();\n this.displayMode = 'login';\n this.tempAuthEndpoint.clearSession();\n this.endpoint.setToken(result.access_token);\n }\n\n async finishLogin(authResult: IAuthenticateResponse) {\n console.log('[AUTH] Authenticated, checking email verification');\n this.tempAuthEndpoint.setToken(authResult.access_token);\n\n const user = await getMyUser(this.tempAuthEndpoint);\n this.submitting = false;\n\n if (!user.email_verified) {\n console.log('[AUTH] Logged in, pending email address verification');\n this.displayMode = 'verify';\n } else {\n console.log('[AUTH] Email address is verified, completing login');\n this.completeLogin(authResult);\n }\n }\n\n async loginAndCheckVerification() {\n if (this.submitting) {\n return;\n }\n\n this.submitting = true;\n this.tempAuthEndpoint.clearSession();\n\n try {\n const authResult = await authenticate(this.tempAuthEndpoint, {username: this.email.trim(), password: this.password, grant_type: 'password'});\n await this.finishLogin(authResult);\n } catch (e) {\n if (isMFARequired(e)) {\n this.startMFA(e.response.data.mfa_token);\n return;\n }\n\n this.submitting = false;\n console.log('[AUTH] Auth failure', e.response?.data || e);\n VerdocsToast('Login failed. Please check your credentials and try again.', {style: 'error'});\n }\n }\n\n startMFA(token: string) {\n this.mfaToken = token;\n this.mfaCode = '';\n this.recoveryCode = '';\n this.useRecoveryCode = false;\n this.mfaError = '';\n this.submitting = false;\n this.mfaFocusPending = true;\n this.displayMode = 'mfa';\n }\n\n returnToLogin() {\n this.mfaToken = '';\n this.mfaCode = '';\n this.recoveryCode = '';\n this.useRecoveryCode = false;\n this.mfaError = '';\n this.password = '';\n this.submitting = false;\n this.displayMode = 'login';\n }\n\n handleMFAFailure(e: any) {\n this.submitting = false;\n this.mfaCode = '';\n this.recoveryCode = '';\n\n // Failed attempts require a fresh token\n if (isMFARequired(e)) {\n this.mfaToken = e.response.data.mfa_token;\n this.mfaError = MFA_CODE_ERROR;\n return;\n }\n\n if (e?.response?.status === 401) {\n this.returnToLogin();\n VerdocsToast('Your sign-in timed out. Enter your password again.', {style: 'error'});\n return;\n }\n\n this.mfaError = MFA_CODE_ERROR;\n }\n\n async submitMFA(code: string, isRecoveryCode: boolean) {\n if (this.submitting || !code) {\n return;\n }\n\n this.submitting = true;\n this.mfaError = '';\n this.tempAuthEndpoint.clearSession();\n\n try {\n const authResult = await authenticate(\n this.tempAuthEndpoint,\n isRecoveryCode\n ? {grant_type: 'urn:verdocs:params:oauth:grant-type:mfa-recovery-code', mfa_token: this.mfaToken, recovery_code: code}\n : {grant_type: 'urn:verdocs:params:oauth:grant-type:mfa-otp', mfa_token: this.mfaToken, otp: code},\n );\n await this.finishLogin(authResult);\n } catch (e) {\n this.handleMFAFailure(e);\n }\n }\n\n handleVerifyMFA() {\n this.submitMFA(this.useRecoveryCode ? this.recoveryCode : this.mfaCode, this.useRecoveryCode).catch(() => undefined);\n }\n\n handleMFACodeInput(target: HTMLInputElement) {\n const digits = (target.value || '').replace(/\\D/g, '').slice(0, 6);\n if (target.value !== digits) {\n target.value = digits;\n }\n this.mfaCode = digits;\n\n // Auto-submit once 6 digits are entered\n if (digits.length === 6) {\n this.submitMFA(digits, false).catch(() => undefined);\n }\n }\n\n handleRecoveryCodeInput(target: HTMLInputElement) {\n const formatted = formatRecoveryCode(target.value || '');\n if (target.value !== formatted) {\n target.value = formatted;\n }\n this.recoveryCode = formatted;\n }\n\n toggleRecoveryCode() {\n this.useRecoveryCode = !this.useRecoveryCode;\n this.mfaCode = '';\n this.recoveryCode = '';\n this.mfaError = '';\n this.mfaFocusPending = true;\n }\n\n handleSocialLogin(provider: TSocialLoginProvider) {\n try {\n const verifier = createCodeVerifier();\n const state = createCodeVerifier();\n\n createCodeChallenge(verifier)\n .then(codeChallenge => {\n const attempt: ISocialLoginAttempt = {verifier, state, provider};\n window.sessionStorage.setItem(SOCIAL_LOGIN_KEY, JSON.stringify(attempt));\n window.location.assign(getSocialLoginUrl(this.endpoint, provider, {returnUri: currentReturnUri(), codeChallenge, state}));\n })\n .catch(() => VerdocsToast(SOCIAL_START_ERROR, {style: 'error'}));\n } catch {\n VerdocsToast(SOCIAL_START_ERROR, {style: 'error'});\n }\n }\n\n handleSocialLoginReturn() {\n if (typeof window === 'undefined') {\n return;\n }\n\n const params = new URLSearchParams(window.location.search);\n const loginCode = params.get('login_code');\n const state = params.get('state');\n const error = params.get('error');\n\n if (!loginCode && !error) {\n return;\n }\n\n const attempt = readSocialLoginAttempt();\n\n // `error` doesn't give us the whole picture\n if (!loginCode && !attempt) {\n return;\n }\n\n clearSocialLoginAttempt();\n cleanSocialLoginParams(loginCode ? ['login_code', 'state'] : ['error']);\n\n if (error) {\n VerdocsToast(socialErrorMessage(error), {style: 'error'});\n return;\n }\n\n if (!attempt || attempt.state !== state) {\n VerdocsToast('Sign-in could not be verified. Try again.', {style: 'error'});\n return;\n }\n\n this.exchangeLoginCode(loginCode, attempt.verifier);\n }\n\n exchangeLoginCode(loginCode: string, codeVerifier: string) {\n this.submitting = true;\n this.tempAuthEndpoint.clearSession();\n\n authenticate(this.tempAuthEndpoint, {grant_type: 'urn:verdocs:params:oauth:grant-type:login-code', login_code: loginCode, code_verifier: codeVerifier})\n .then(authResult => this.finishLogin(authResult))\n .catch(e => {\n if (isMFARequired(e)) {\n this.startMFA(e.response.data.mfa_token);\n return;\n }\n\n this.submitting = false;\n console.log('[AUTH] Social login failure', e.response?.data || e);\n VerdocsToast('Sign-in failed. Please try again.', {style: 'error'});\n });\n }\n\n clearForms() {\n this.submitting = false;\n this.resendDisabled = false;\n this.mfaToken = '';\n this.mfaCode = '';\n this.recoveryCode = '';\n this.useRecoveryCode = false;\n this.mfaError = '';\n this.email = '';\n this.phone = '';\n this.password = '';\n this.newPassword = '';\n this.confirmpass = '';\n this.verificationCode = '';\n this.first_name = '';\n this.last_name = '';\n this.org_name = '';\n }\n\n handleLogout() {\n console.log('logging out');\n this.endpoint.clearSession();\n this.tempAuthEndpoint.clearSession();\n this.clearForms();\n this.displayMode = 'login';\n }\n\n handleResendVerification() {\n // Avoid the user just click-spamming this pathway. The server rate-limits this anyway so it's not a\n // security issue but it's a poor user experience to allow it.\n this.resendDisabled = true;\n this.resendDisabledTimer = setTimeout(() => {\n this.resendDisabled = false;\n this.resendDisabledTimer = null;\n }, 30000);\n\n resendVerification(this.tempAuthEndpoint)\n .then(r => {\n console.log('[AUTH] Verification request resent', r);\n VerdocsToast('Please check your email for a verification code.', {style: 'info'});\n })\n .catch((e: any) => {\n console.log('[AUTH] Unable to resend verification', e);\n VerdocsToast('Unable to resend code. Please try again later.', {style: 'error'});\n });\n }\n\n handleResendReset() {\n // Avoid the user just click-spamming this pathway. The server rate-limits this anyway so it's not a\n // security issue but it's a poor user experience to allow it.\n this.resendDisabled = true;\n this.resendDisabledTimer = setTimeout(() => {\n this.resendDisabled = false;\n this.resendDisabledTimer = null;\n }, 30000);\n\n resetPassword(this.tempAuthEndpoint, {email: this.email})\n .then(r => {\n console.log('[AUTH] Resend-code request resent', r);\n VerdocsToast('Please check your email again for a verification code.', {style: 'info'});\n })\n .catch((e: any) => {\n console.log('[AUTH] Unable to resend reset request', e);\n VerdocsToast('Unable to resend code. Please try again later.', {style: 'error'});\n });\n }\n\n async handleResetGetCode() {\n this.submitting = true;\n this.confirmpass = '';\n this.newPassword = '';\n\n try {\n this.submitting = false;\n const result = await resetPassword(this.endpoint, {email: this.email});\n console.log('[AUTH] Reset result', result);\n VerdocsToast('Please check your email inbox for a password reset code.', {style: 'success'});\n this.verificationCode = '';\n this.confirmpass = '';\n this.newPassword = '';\n this.displayMode = 'reset';\n } catch (e) {\n this.submitting = false;\n console.log('Reset request error', e);\n VerdocsToast('Request failed. Please check your email address and try again.');\n }\n }\n\n async handleResetPassword() {\n if (!this.isPasswordComplex(this.newPassword)) {\n VerdocsToast('Password must be at least 8 characters long and contain at least one uppercase, one lowercase, and one special character.', {style: 'error'});\n return;\n }\n\n if (this.newPassword !== this.confirmpass) {\n VerdocsToast('Passwords do not match.', {style: 'error'});\n return;\n }\n\n this.submitting = true;\n try {\n this.submitting = false;\n const resetResult = await resetPassword(this.endpoint, {email: this.email, code: this.verificationCode, new_password: this.newPassword});\n console.log('reset result', resetResult);\n VerdocsToast('Your password has been reset. You may now use your new password to login.', {style: 'success'});\n this.verificationCode = '';\n this.confirmpass = '';\n this.newPassword = '';\n this.password = '';\n this.displayMode = 'login';\n } catch (e) {\n this.submitting = false;\n console.log('Verification error', e);\n VerdocsToast('Verification error, please check the code and try again.');\n }\n }\n\n async handleReset() {\n this.submitting = true;\n\n try {\n const result = await resetPassword(this.endpoint, {email: this.email});\n console.log('[AUTH] Reset sent', result);\n this.submitting = false;\n this.displayMode = 'login';\n VerdocsToast('If your email address is registered, you will receive instructions on resetting your password shortly.', {style: 'info'});\n } catch (e) {\n console.log('[AUTH] Unable to reset password', e);\n this.submitting = false;\n VerdocsToast('Unable to reset password. Please check your email address and try again.', {style: 'error'});\n }\n }\n\n renderProviderButtons() {\n if (!this.showSocialLogins || (!this.providers.google && !this.providers.microsoft)) {\n return null;\n }\n\n return (\n <div class=\"providers\">\n {this.providers.google && (\n <verdocs-button\n label=\"Continue with Google\"\n variant=\"outline\"\n class=\"provider-google\"\n startIcon={GoogleIcon}\n disabled={this.submitting}\n onClick={() => this.handleSocialLogin('google')}\n />\n )}\n {this.providers.microsoft && (\n <verdocs-button\n label=\"Continue with Microsoft\"\n variant=\"outline\"\n class=\"provider-microsoft\"\n startIcon={MicrosoftIcon}\n disabled={this.submitting}\n onClick={() => this.handleSocialLogin('microsoft')}\n />\n )}\n\n <div class=\"divider\">\n <div class=\"divider-line\" />\n or\n <div class=\"divider-line\" />\n </div>\n </div>\n );\n }\n\n render() {\n if (!this.visible) {\n return <div style={{display: 'none'}}>Authenticated</div>;\n }\n\n if (this.session) {\n return (\n <verdocs-button\n label=\"Sign Out\"\n disabled={this.submitting}\n onClick={() => this.handleLogout()}\n style={{display: 'flex', justifyContent: 'center', margin: '30px auto 0'}}\n />\n );\n }\n\n if (this.displayMode === 'mfa') {\n const enteredCode = this.useRecoveryCode ? this.recoveryCode : this.mfaCode;\n const codeComplete = this.useRecoveryCode ? this.recoveryCode.replace('-', '').length === 8 : this.mfaCode.length === 6;\n\n return (\n <div class=\"form\">\n <a href=\"https://verdocs.com/en/\">\n <img src={this.logo} alt=\"Verdocs Logo\" class=\"logo\" />\n </a>\n\n <h3>Two-factor authentication</h3>\n\n <p>\n {this.useRecoveryCode\n ? 'Enter one of the backup codes you saved when you turned on multi-factor authentication.'\n : 'Enter the six-digit code from your authenticator app.'}\n </p>\n\n <form\n onSubmit={(e: Event) => {\n e.preventDefault();\n this.handleVerifyMFA();\n }}\n >\n {this.useRecoveryCode ? (\n <verdocs-text-input\n class=\"mfa-input\"\n label=\"Backup code\"\n placeholder=\"xxxx-xxxx\"\n autocomplete=\"one-time-code\"\n value={this.recoveryCode}\n onInput={(e: any) => this.handleRecoveryCodeInput(e.target)}\n disabled={this.submitting}\n />\n ) : (\n <verdocs-text-input\n class=\"mfa-input\"\n label=\"Authentication code\"\n autocomplete=\"one-time-code\"\n value={this.mfaCode}\n onInput={(e: any) => this.handleMFACodeInput(e.target)}\n disabled={this.submitting}\n />\n )}\n\n {this.mfaError && (\n <div role=\"alert\" class=\"mfa-error\">\n {this.mfaError}\n </div>\n )}\n\n <div class=\"buttons\">\n <verdocs-button label=\"Cancel\" variant=\"outline\" disabled={this.submitting} onClick={() => this.returnToLogin()} />\n <verdocs-button label=\"Verify\" disabled={this.submitting || !codeComplete || !enteredCode} onClick={() => this.handleVerifyMFA()} />\n </div>\n\n <div class=\"buttons\">\n <verdocs-button\n variant=\"text\"\n size=\"small\"\n label={this.useRecoveryCode ? 'Use your authenticator app instead' : 'Use a backup code instead'}\n disabled={this.submitting}\n onClick={() => this.toggleRecoveryCode()}\n />\n </div>\n </form>\n </div>\n );\n }\n\n if (this.displayMode === 'signup') {\n const invalid = this.submitting || !this.first_name || !this.last_name || !this.email || !this.password || !this.confirmpass || !this.org_name;\n\n return (\n <div class=\"form\">\n <a href=\"https://verdocs.com/en/\">\n <img src={this.logo} alt=\"Verdocs Logo\" class=\"logo\" />\n </a>\n\n <h3>Sign up for a free account</h3>\n <div class=\"already-have\">\n Already have an account?\n <verdocs-button label=\"Log In\" variant=\"text\" onClick={() => (this.displayMode = 'login')} disabled={this.submitting} />\n </div>\n\n {this.renderProviderButtons()}\n\n <form onSubmit={() => this.handleSignup()}>\n <div style={{display: 'flex', flexDirection: 'row', columnGap: '20px'}}>\n <verdocs-text-input\n label=\"First Name\"\n autocomplete=\"first\"\n required={true}\n value={this.first_name}\n onInput={(e: any) => (this.first_name = e.target.value)}\n disabled={this.submitting}\n />\n <verdocs-text-input\n label=\"Last Name\"\n autocomplete=\"last\"\n required={true}\n value={this.last_name}\n onInput={(e: any) => (this.last_name = e.target.value)}\n disabled={this.submitting}\n />\n </div>\n <verdocs-text-input\n label=\"Email Address\"\n autocomplete=\"email\"\n required={true}\n value={this.email}\n onInput={(e: any) => (this.email = e.target.value)}\n disabled={this.submitting}\n />\n <verdocs-text-input\n label=\"Password\"\n type=\"password\"\n required={true}\n autocomplete=\"new-password\"\n value={this.password}\n onInput={(e: any) => (this.password = e.target.value)}\n disabled={this.submitting}\n />\n <verdocs-text-input\n label=\"Confirm Password\"\n type=\"password\"\n required={true}\n autocomplete=\"off\"\n value={this.confirmpass}\n onInput={(e: any) => (this.confirmpass = e.target.value)}\n disabled={this.submitting}\n />\n <verdocs-text-input\n label=\"Phone Number\"\n type=\"tel\"\n required={true}\n autocomplete=\"phone\"\n value={this.phone}\n onInput={(e: any) => (this.phone = e.target.value)}\n disabled={this.submitting}\n />\n <verdocs-text-input\n label=\"Organization Name\"\n autocomplete=\"org\"\n required={true}\n value={this.org_name}\n onInput={(e: any) => (this.org_name = e.target.value)}\n disabled={this.submitting}\n style={{flex: '1'}}\n />\n\n <div class=\"service-agreement\">\n By clicking the Create Account button, you agree to the{' '}\n <a href=\"https://verdocs.com/eula\" target=\"_blank\">\n End User License Agreement\n </a>\n . Learn about how we use and protect your data and how you can opt-out in our{' '}\n <a href=\"https://verdocs.com/privacy-policy\" target=\"_blank\">\n Privacy Policy\n </a>\n .\n </div>\n\n <div style={{marginTop: '30px'}} />\n\n <verdocs-button\n label=\"Next\"\n disabled={invalid}\n onClick={invalid ? () => {} : () => this.handleSignup()}\n style={{display: 'flex', justifyContent: 'center', margin: '30px auto 0'}}\n />\n </form>\n </div>\n );\n }\n\n if (this.displayMode === 'verify') {\n return (\n <div class=\"form\">\n <form onSubmit={() => this.handleVerification()}>\n <p>Please check your e-mail inbox for a verification code and enter it below.</p>\n\n <verdocs-text-input\n label=\"Verification Code\"\n required={true}\n value={this.verificationCode}\n onInput={(e: any) => (this.verificationCode = e.target.value)}\n disabled={this.submitting}\n />\n\n <div class=\"buttons\">\n <verdocs-button label=\"Sign Out\" variant=\"outline\" disabled={this.submitting} onClick={() => this.handleLogout()} />\n <verdocs-button label=\"Verify\" disabled={this.submitting || !this.verificationCode || this.verificationCode.length !== 6} onClick={() => this.handleVerification()} />\n </div>\n <div class=\"buttons\">\n <verdocs-button variant=\"text\" label=\"Resend Code\" disabled={this.resendDisabled || this.submitting} onClick={() => this.handleResendVerification()} />\n </div>\n </form>\n </div>\n );\n }\n\n if (this.displayMode === 'forgot') {\n return (\n <div class=\"form\">\n <a href=\"https://verdocs.com/en/\">\n <img src={this.logo} alt=\"Verdocs Logo\" class=\"logo\" />\n </a>\n\n <h3>Forgot your password?</h3>\n\n <p>\n Enter your e-mail address below. If the e-mail address is valid, a password reset code will be sent to your inbox. Please allow up to 15 minutes to arrive, and check\n your spam folder if you do not receive the message.\n </p>\n\n <form onSubmit={() => this.handleResetGetCode()}>\n <verdocs-text-input\n label=\"Email Address\"\n autocomplete=\"email\"\n required={true}\n value={this.email}\n onInput={(e: any) => (this.email = e.target.value)}\n disabled={this.submitting}\n />\n\n <div style={{marginTop: '30px'}} />\n\n <div class=\"buttons\">\n <verdocs-button size=\"small\" label=\"Cancel\" variant=\"outline\" disabled={this.submitting} onClick={() => (this.displayMode = 'login')} />\n <verdocs-button size=\"small\" label=\"Request Code\" disabled={this.submitting} onClick={() => this.handleResetGetCode()} />\n </div>\n </form>\n </div>\n );\n }\n\n if (this.displayMode === 'reset') {\n return (\n <div class=\"form\">\n <a href=\"https://verdocs.com/en/\">\n <img src={this.logo} alt=\"Verdocs Logo\" class=\"logo\" />\n </a>\n\n <h3>Forgot your password?</h3>\n\n <p>\n Enter your e-mail address below, and reset instructions will be sent to your Inbox. Please allow up to 15 minutes to arrive. Check your spam folder if you do not\n receive the message.\n </p>\n\n <form onSubmit={() => this.handleResetPassword()}>\n <verdocs-text-input\n label=\"Verification Code\"\n required={true}\n value={this.verificationCode}\n onInput={(e: any) => (this.verificationCode = e.target.value)}\n disabled={this.submitting}\n />\n <verdocs-text-input\n label=\"Password\"\n type=\"password\"\n required={true}\n autocomplete=\"off\"\n value={this.newPassword}\n onInput={(e: any) => (this.newPassword = e.target.value)}\n disabled={this.submitting}\n />\n <verdocs-text-input\n label=\"Confirm Password\"\n type=\"password\"\n required={true}\n autocomplete=\"off\"\n value={this.confirmpass}\n onInput={(e: any) => (this.confirmpass = e.target.value)}\n disabled={this.submitting}\n />\n\n <div style={{marginTop: '30px'}} />\n\n <div class=\"buttons\">\n <verdocs-button label=\"Cancel\" variant=\"outline\" disabled={this.submitting} onClick={() => (this.displayMode = 'login')} />\n <verdocs-button label=\"Reset\" disabled={this.submitting} onClick={() => this.handleResetPassword()} />\n </div>\n\n <div class=\"buttons\">\n <verdocs-button variant=\"text\" label=\"Resend Code\" disabled={this.resendDisabled || this.submitting} onClick={() => this.handleResendReset()} />\n </div>\n </form>\n </div>\n );\n }\n\n return (\n <div class=\"form\">\n <a href=\"https://verdocs.com/en/\">\n <img src={this.logo} alt=\"Verdocs Logo\" class=\"logo\" />\n </a>\n\n <h3>Log in to your account</h3>\n\n {this.renderProviderButtons()}\n\n <form onSubmit={() => this.loginAndCheckVerification()}>\n <verdocs-text-input label=\"Email\" autocomplete=\"username\" value={this.email} onInput={(e: any) => (this.email = e.target.value)} disabled={this.submitting} />\n <verdocs-text-input\n label=\"Password\"\n type=\"password\"\n autocomplete=\"current-password\"\n value={this.password}\n onInput={(e: any) => (this.password = e.target.value)}\n disabled={this.submitting}\n />\n\n <verdocs-button\n label=\"Forgot Your Password?\"\n variant=\"text\"\n onClick={() => (this.displayMode = 'forgot')}\n disabled={this.submitting}\n style={{display: 'flex', justifyContent: 'center', margin: '0 auto 20px'}}\n />\n\n <verdocs-button\n label=\"Login\"\n disabled={this.submitting}\n onClick={() => this.loginAndCheckVerification()}\n style={{display: 'flex', justifyContent: 'center', margin: '10px auto 0'}}\n />\n\n <verdocs-button\n label=\"Sign Up\"\n variant=\"outline\"\n disabled={this.submitting}\n onClick={() => (this.displayMode = 'signup')}\n style={{display: 'flex', justifyContent: 'center', margin: '10px auto 0'}}\n />\n </form>\n </div>\n );\n }\n}\n"],"names":[],"mappings":";;;;;;AAAA,MAAM,cAAc,GAAG,MAAM,CAAC,4mFAA4mF,C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M,EAAE,aAAa,EAAC,EAAA,CACzE,EAEF,CAAA,CAAA,gBAAA,EAAA,EACE,KAAK,EAAC,SAAS,EACf,OAAO,EAAC,SAAS,EACjB,QAAQ,EAAE,IAAI,CAAC,UAAU,EACzB,OAAO,EAAE,OAAO,IAAI,CAAC,WAAW,GAAG,QAAQ,CAAC,EAC5C,KAAK,EAAE,EAAC,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,QAAQ,EAAE,MAAM,EAAE,aAAa,EAAC,EAAA,CACzE,CACG,CACH;;;;;;;;"}
@@ -1,2 +1,2 @@
1
- var __awaiter=this&&this.__awaiter||function(e,t,o,i){function a(e){return e instanceof o?e:new o((function(t){t(e)}))}return new(o||(o=Promise))((function(o,c){function s(e){try{r(i.next(e))}catch(e){c(e)}}function n(e){try{r(i["throw"](e))}catch(e){c(e)}}function r(e){e.done?o(e.value):a(e.value).then(s,n)}r((i=i.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var o={label:0,sent:function(){if(c[0]&1)throw c[1];return c[1]},trys:[],ops:[]},i,a,c,s=Object.create((typeof Iterator==="function"?Iterator:Object).prototype);return s.next=n(0),s["throw"]=n(1),s["return"]=n(2),typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function n(e){return function(t){return r([e,t])}}function r(n){if(i)throw new TypeError("Generator is already executing.");while(s&&(s=0,n[0]&&(o=0)),o)try{if(i=1,a&&(c=n[0]&2?a["return"]:n[0]?a["throw"]||((c=a["return"])&&c.call(a),0):a.next)&&!(c=c.call(a,n[1])).done)return c;if(a=0,c)n=[n[0]&2,c.value];switch(n[0]){case 0:case 1:c=n;break;case 4:o.label++;return{value:n[1],done:false};case 5:o.label++;a=n[1];n=[0];continue;case 7:n=o.ops.pop();o.trys.pop();continue;default:if(!(c=o.trys,c=c.length>0&&c[c.length-1])&&(n[0]===6||n[0]===2)){o=0;continue}if(n[0]===3&&(!c||n[1]>c[0]&&n[1]<c[3])){o.label=n[1];break}if(n[0]===6&&o.label<c[1]){o.label=c[1];c=n;break}if(c&&o.label<c[2]){o.label=c[2];o.ops.push(n);break}if(c[2])o.ops.pop();o.trys.pop();continue}n=t.call(e,o)}catch(e){n=[6,e];a=0}finally{i=c=0}if(n[0]&5)throw n[1];return{value:n[0]?n[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(e,t,o){if(o||arguments.length===2)for(var i=0,a=t.length,c;i<a;i++){if(c||!(i in t)){if(!c)c=Array.prototype.slice.call(t,0,i);c[i]=t[i]}}return e.concat(c||Array.prototype.slice.call(t))};import{r as registerInstance,c as createEvent,h,F as Fragment}from"./index-CjTHbolG.js";import{VerdocsEndpoint,formatFullName,getActiveEntitlements,isValidEmail}from"@verdocs/js-sdk";import{c as convertToE164}from"./utils-Bh3zb1Xs.js";import"./index-BglCURB-.js";import"./Types-CIxfEdV7.js";var verdocsContactPickerCss=function(){return'verdocs-contact-picker{display:block;border:1px solid #ebebeb;background-color:#ffffff;font-family:var(--verdocs-primary-font, "Inter", "Barlow", sans-serif);-webkit-box-shadow:0 0 15px 0 rgba(0, 0, 0, 0.1);box-shadow:0 0 15px 0 rgba(0, 0, 0, 0.1)}verdocs-contact-picker form{gap:12px;width:300px;padding:12px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;background-color:#f5f5fa}verdocs-contact-picker form .row{gap:8px;display:-ms-flexbox;display:flex;position:relative;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:start;align-items:flex-start}verdocs-contact-picker form .row .option{gap:4px;display:-ms-flexbox;display:flex;padding:5px 8px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;text-wrap:nowrap}verdocs-contact-picker form .names-row{gap:8px;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-contact-picker form .names-row>input{font-size:14px;width:88px}verdocs-contact-picker form .pin-code{gap:8px;display:-ms-flexbox;display:flex;-ms-flex-align:start;align-items:flex-start;-ms-flex-direction:row;flex-direction:row}verdocs-contact-picker form .pin-code>input{-ms-flex:0 0 197px;flex:0 0 197px;font-size:14px}verdocs-contact-picker form .address{gap:8px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}verdocs-contact-picker form .address>input{-ms-flex:1;flex:1;font-size:14px}verdocs-contact-picker form .zip-code{gap:8px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}verdocs-contact-picker form .zip-code>input{-ms-flex:1;flex:1;font-size:14px}verdocs-contact-picker form label{display:-ms-flexbox;display:flex;-ms-flex:0 0 80px;flex:0 0 80px;font-size:13px;font-weight:500;color:#5c6575}verdocs-contact-picker form .row.message textarea{width:100%;padding:5px 7px;border-radius:4px;font-family:var(--verdocs-primary-font, "Inter", "Barlow", sans-serif)}verdocs-contact-picker form input{-ms-flex:1;flex:1;padding:6px;font-size:14px;border-radius:3px;border:1px solid rgba(112, 122, 229, 0.3725490196)}verdocs-contact-picker form input:focus{outline:none}verdocs-contact-picker .buttons{display:-ms-flexbox;display:flex;-webkit-column-gap:6px;-moz-column-gap:6px;column-gap:6px;margin-top:16px;-ms-flex-direction:row;flex-direction:row}verdocs-contact-picker .buttons .flex-fill{-ms-flex:1;flex:1}verdocs-contact-picker ::-webkit-input-placeholder{color:#aaaaaa}verdocs-contact-picker ::-moz-placeholder{color:#aaaaaa}verdocs-contact-picker :-ms-input-placeholder{color:#aaaaaa}verdocs-contact-picker ::-ms-input-placeholder{color:#aaaaaa}verdocs-contact-picker ::placeholder{color:#aaaaaa}verdocs-contact-picker [data-lastpass-icon-root]{display:none !important}#verdocs-contact-picker-suggestions .dropdown{max-height:225px;overflow-y:scroll;background:#ffffff;font-family:var(--verdocs-primary-font, "Inter", "Barlow", sans-serif);-webkit-box-shadow:0 0 15px 0 rgba(0, 0, 0, 0.1);box-shadow:0 0 15px 0 rgba(0, 0, 0, 0.1)}#verdocs-contact-picker-suggestions .dropdown .suggestion{display:-ms-flexbox;display:flex;padding:6px 12px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}#verdocs-contact-picker-suggestions .dropdown .suggestion svg{width:32px;height:32px}#verdocs-contact-picker-suggestions .dropdown .suggestion .avatar{width:32px;height:32px;-ms-flex:0 0 32px;flex:0 0 32px;margin-right:8px;border-radius:100%}#verdocs-contact-picker-suggestions .dropdown .suggestion .details{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}#verdocs-contact-picker-suggestions .dropdown .suggestion .name{font-size:16px;font-weight:500;margin-bottom:3px;color:#092c4c}#verdocs-contact-picker-suggestions .dropdown .suggestion .destination{font-size:14px;margin-bottom:3px;color:#33364b}#verdocs-contact-picker-suggestions .dropdown .suggestion:hover{background:#eee;cursor:pointer}'};var addrBookIcon='<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-book-user"><path d="M15 13a3 3 0 1 0-6 0"/><path d="M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H19a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1H6.5a1 1 0 0 1 0-5H20"/><circle cx="12" cy="8" r="2"/></svg>';var VerdocsContactPicker=function(){function e(e){registerInstance(this,e);this.searchContacts=createEvent(this,"searchContacts");this.exit=createEvent(this,"exit");this.next=createEvent(this,"next");this.endpoint=VerdocsEndpoint.getDefault();this.templateRole=null;this.contactSuggestions=[];this.showSuggestions=false;this.showMessage=false;this.delegator=false;this.name_locked=false;this.auth_methods=[];this.passcode="";this.firstNameFieldId="verdocs-contact-picker-firstname-".concat(Math.random().toString(36).substring(2,11));this.lastNameFieldId="verdocs-contact-picker-lastname-".concat(Math.random().toString(36).substring(2,11));this.emailFieldId="verdocs-contact-picker-email-".concat(Math.random().toString(36).substring(2,11));this.phoneFieldId="verdocs-contact-picker-phone-".concat(Math.random().toString(36).substring(2,11));this.activeEntitlements={};this.authMethodsLoading=true}e.prototype.componentWillLoad=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,o,i,a;return __generator(this,(function(c){switch(c.label){case 0:this.endpoint.loadSession();if(this.templateRole){e=formatFullName(this.templateRole);t=e.split(" ");o=this.templateRole.first_name||t.shift()||"";i=this.templateRole.last_name||t.join(" ")||"";this.first_name=o;this.last_name=i;this.email=this.templateRole.email||"";this.phone=this.templateRole.phone||"";this.delegator=this.templateRole.delegator||false;this.name_locked=this.delegator?false:this.templateRole.name_locked||false;this.message=this.templateRole.message||"";this.showMessage=this.message!=="";this.auth_methods=this.templateRole.auth_methods||[];this.passcode=this.templateRole.passcode||""}a=this;return[4,getActiveEntitlements(this.endpoint).catch((function(e){console.warn("[CONTACT PICKER] Unable to load entitlements, continuing with base auth methods only",e);return{}}))];case 1:a.activeEntitlements=c.sent();this.authMethodsLoading=false;console.log("[CONTACT PICKER] Loaded entitlements",this.activeEntitlements);return[2]}}))}))};e.prototype.handleFirstNameChange=function(e){var t;this.first_name=e.target.value;(t=this.searchContacts)===null||t===void 0?void 0:t.emit({query:this.first_name})};e.prototype.handleLastNameChange=function(e){var t;this.last_name=e.target.value;(t=this.searchContacts)===null||t===void 0?void 0:t.emit({query:this.last_name})};e.prototype.handleCancel=function(e){var t;e.stopPropagation();this.showSuggestions=false;(t=this.exit)===null||t===void 0?void 0:t.emit()};e.prototype.handleSubmit=function(e){var t;e.stopPropagation();this.showSuggestions=false;(t=this.next)===null||t===void 0?void 0:t.emit({first_name:this.first_name,last_name:this.last_name,email:this.email,phone:this.phone,message:this.message,delegator:this.delegator,name_locked:this.name_locked,auth_methods:this.auth_methods,passcode:this.passcode,address:this.address,zip:this.zip})};e.prototype.handleSelectSuggestion=function(e,t){e.stopPropagation();this.first_name=t.first_name;this.last_name=t.last_name;this.email=t.email;this.phone=t.phone;this.showSuggestions=false};e.prototype.render=function(){var e=this;var t=this.first_name&&this.last_name&&isValidEmail(this.email);var o=!this.auth_methods.length||this.auth_methods.includes("passcode")&&!!this.passcode||this.auth_methods.includes("kba")&&!!this.first_name&&!!this.last_name||this.auth_methods.includes("email")&&!!this.email||this.auth_methods.includes("sms")&&!!this.phone;var i=t&&o;var a=!!this.activeEntitlements.sms_auth;var c=[];c.push({label:"Passcode",value:"passcode"});c.push({label:"Email",value:"email"});if(a){c.push({label:"SMS (One-Time Code)",value:"sms"})}if(!!this.activeEntitlements.kba_auth){c.push({label:"Knowledge-Based (KBA)",value:"kba"})}if(!!this.activeEntitlements.id_auth){c.push({label:"ID Check",value:"id"})}return h("form",{key:"70e2a9e4eb9e9da4bd9f491648d81fd30f9a34a6",onSubmit:function(e){return e.preventDefault()},autocomplete:"off"},h("div",{key:"9134b3e8bcd2c59f8773ad3db7bdd04d52d9cbf7",class:"row"},h("label",{key:"455c784b89b96afddb46dcde9bd760e3b36c890d",htmlFor:this.firstNameFieldId},"Name:"),h("div",{key:"802e5786743df37c017f6aab4061b01db4207988",class:"names-row"},h("input",{key:"5ee405fd8487c8f2539ede7ccf26e76bb96c3932",id:this.firstNameFieldId,name:this.firstNameFieldId,type:"text","data-lpignore":"true",autocomplete:"blocked","aria-autocomplete":"none",value:this.first_name,placeholder:"First...",onFocus:function(){setTimeout((function(){var t;e.showSuggestions=((t=e.contactSuggestions)===null||t===void 0?void 0:t.length)>0}),100)},onInput:function(t){return e.handleFirstNameChange(t)}}),h("input",{key:"2de6301b850c7d0986b0418bbb737b0f9e04849f",id:this.lastNameFieldId,name:this.lastNameFieldId,type:"text","data-lpignore":"true",autocomplete:"blocked","aria-autocomplete":"none",value:this.last_name,placeholder:"Last...",onFocus:function(){setTimeout((function(){var t;e.showSuggestions=((t=e.contactSuggestions)===null||t===void 0?void 0:t.length)>0}),100)},onInput:function(t){return e.handleLastNameChange(t)}})),this.showSuggestions&&h("verdocs-portal",{key:"39c6ccb8a231fe9e01fbd99aebc3e7625dfeef17",anchor:this.firstNameFieldId,onClickAway:function(){e.showSuggestions=false;document.querySelectorAll(".verdocs-portal-wrapper").forEach((function(e){return e.remove()}))},id:"verdocs-contact-picker-suggestions"},h("div",{key:"bbabbff5428faeb5cef999f422d441d3e66fdf62",class:"dropdown"},this.contactSuggestions.filter((function(t){var o;return!e.first_name||((o=t.first_name)===null||o===void 0?void 0:o.toLowerCase().includes(e.first_name.toLowerCase()))})).map((function(t){var o;return h("div",{key:(o=t.id)!==null&&o!==void 0?o:t.email,class:"suggestion",onClick:function(o){return e.handleSelectSuggestion(o,t)}},t.picture?h("img",{alt:"Avatar",class:"avatar",src:t.picture}):h("div",{class:"avatar",innerHTML:addrBookIcon}),h("div",{class:"details"},h("div",{class:"name"},formatFullName(t)),t.email&&h("div",{class:"destination"},t.email),t.phone&&h("div",{class:"destination"},t.phone)))}))))),h("div",{key:"31c843f59d029535c1006c682f76d8b18f885dc3",class:"row"},h("label",{key:"540a430d827ec0b44fc2d56d4f2cb5938d663236",htmlFor:this.emailFieldId},"Email:"),h("input",{key:"055b0ecaee8f361a4f222cbaeedcdcfbf536a5cb",id:this.emailFieldId,name:this.emailFieldId,type:"text","data-lpignore":"true",autoComplete:"blocked","aria-autocomplete":"none",value:this.email,placeholder:"Invite/verify via email...",onFocus:function(){return e.showSuggestions=false},onInput:function(t){return e.email=t.target.value}})),a&&h("div",{key:"b9c6dd3118c6eba736add88b35e68ff79715e44d",class:"row"},h("label",{key:"ff687e318625a8cde98b208bf72b111d48659acc",htmlFor:this.phoneFieldId},"Phone:"),h("input",{key:"3c6f09760be62cedde15b43a1d34bbd8c2960600",id:this.phoneFieldId,name:this.phoneFieldId,type:"text","data-lpignore":"true",autoComplete:"blocked","aria-autocomplete":"none",value:this.phone,placeholder:"Invite/verify via SMS...",onFocus:function(){return e.showSuggestions=false},onInput:function(t){e.phone=convertToE164(t.target.value)}})),h(Fragment,{key:"2b652dbfb48a4b0360c2b6e536158492ef06125b"},c.length>0&&h("div",{key:"589c42562ec9e834680969803d747f6e94d00ec2",class:"row pin-code"},h("label",{key:"189c3562f5e0ed7599a816d0300b5fe3c96741cb"},"Verification Methods:"),this.authMethodsLoading?h("verdocs-spinner",{size:10,mode:"dark",style:{margin:"auto"}}):h("div",null,c.map((function(t,o){return h("div",{class:"option"},h("verdocs-checkbox",{size:"small",id:"verdocs-multi-select-opt-".concat(o),value:t.value,checked:e.auth_methods.includes(t.value),onInput:function(o){if(o.target.checked){e.auth_methods=__spreadArray(__spreadArray([],e.auth_methods,true),[t.value],false)}else{e.auth_methods=e.auth_methods.filter((function(e){return e!==t.value}))}}}),h("label",{htmlFor:"verdocs-multi-select-option-".concat(o)},t.label))})))),this.auth_methods.includes("passcode")&&h("div",{key:"6e12581d825a0c8089e20015d1d96fb6a182cdb5",class:"row pin-code"},h("label",{key:"e728bc75adcf8f8a322628c1a38f612d3dd2d2dc",htmlFor:this.phoneFieldId},"Passcode:"),h("input",{key:"59afa58c6563d4fa9a1cb7e65409370fb685d1db",id:"verdocs-passcode",name:"verdocs-passcode",type:"text","data-lpignore":"true",autocomplete:"blocked","aria-autocomplete":"none",value:this.passcode,placeholder:"4-8 digits recommended...",onFocus:function(){return e.showSuggestions=false},onInput:function(t){return e.passcode=t.target.value}}))),h("div",{key:"eca3f9921286dba2e5d3ba02f0b886e3d179a23f",class:"row pin-code"},h("label",{key:"04e26414864324205e2ee71173aac15b46350b7e",style:{marginTop:"6px"}},"Options:"),h("div",{key:"f8df70196098a3462df02933d7d7c51cac5c856b"},h("div",{key:"09f4d4f88a355d19ae560203020c9639fe88280e",class:"option"},h("verdocs-checkbox",{key:"e71d71be949fc96c1c074dcbb58ff121c4c3fd05",size:"small",id:"verdocs-delegator",checked:this.delegator,disabled:this.name_locked,onInput:function(t){e.delegator=t.target.checked;if(e.delegator)e.name_locked=false}}),h("label",{key:"b83381a0c733b2fc19502ee1fb64462c77eb20f2",htmlFor:"verdocs-delegator"},"May delegate signing")),h("div",{key:"d3f59732383cded91c3c9d0431001ce27b1998b8",class:"option"},h("verdocs-checkbox",{key:"9c0acbf0601728bf4498e2fe3c89232ee4e9448c",size:"small",id:"verdocs-name-locked",checked:this.name_locked,disabled:this.delegator,onInput:function(t){e.name_locked=t.target.checked;if(e.name_locked)e.delegator=false}}),h("label",{key:"df906c6274917b04c471aa00eedf8fad9b9c15a1",htmlFor:"verdocs-name-locked"},"Name locked")))),h("div",{key:"74e5e6004872803e50c315540c6dc66957d6b9b0",class:"row message"},h("label",{key:"36557fd5a7ccd14cd5fae192bf3bfaaf9f39c136",htmlFor:"verdocs-contact-picker-message"},"Message:"),h("textarea",{key:"c362c8a6b1953330f128bfc5083749060d17727c",id:"verdocs-contact-picker-message",name:"verdocs-contact-picker-message","data-lpignore":"true",autocomplete:"blocked",placeholder:"Optional message to include in invitation...",onFocus:function(){return e.showSuggestions=false},onInput:function(t){return e.message=t.target.value}},this.message)),h("div",{key:"8864df6dba12af9cc9e476398368f3482ab4982f",class:"buttons"},h("div",{key:"f09409d3f75a7f04dcb4a93189d098dbc68177c4",class:"flex-fill"}),h("verdocs-button",{key:"17a564f49e64ec50a3ef201e0aa5b662ab0f0522",variant:"outline",label:"Cancel",size:"small",onClick:function(t){return e.handleCancel(t)}}),h("verdocs-button",{key:"c731fb4642166fc0b682894cb71f4e41fe7b48e7",label:"OK",size:"small",disabled:!i,onClick:!i?function(){}:function(t){return e.handleSubmit(t)}})))};return e}();VerdocsContactPicker.style=verdocsContactPickerCss();export{VerdocsContactPicker as verdocs_contact_picker};
1
+ var __awaiter=this&&this.__awaiter||function(e,t,o,i){function a(e){return e instanceof o?e:new o((function(t){t(e)}))}return new(o||(o=Promise))((function(o,s){function c(e){try{r(i.next(e))}catch(e){s(e)}}function n(e){try{r(i["throw"](e))}catch(e){s(e)}}function r(e){e.done?o(e.value):a(e.value).then(c,n)}r((i=i.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:[]},i,a,s,c=Object.create((typeof Iterator==="function"?Iterator:Object).prototype);return c.next=n(0),c["throw"]=n(1),c["return"]=n(2),typeof Symbol==="function"&&(c[Symbol.iterator]=function(){return this}),c;function n(e){return function(t){return r([e,t])}}function r(n){if(i)throw new TypeError("Generator is already executing.");while(c&&(c=0,n[0]&&(o=0)),o)try{if(i=1,a&&(s=n[0]&2?a["return"]:n[0]?a["throw"]||((s=a["return"])&&s.call(a),0):a.next)&&!(s=s.call(a,n[1])).done)return s;if(a=0,s)n=[n[0]&2,s.value];switch(n[0]){case 0:case 1:s=n;break;case 4:o.label++;return{value:n[1],done:false};case 5:o.label++;a=n[1];n=[0];continue;case 7:n=o.ops.pop();o.trys.pop();continue;default:if(!(s=o.trys,s=s.length>0&&s[s.length-1])&&(n[0]===6||n[0]===2)){o=0;continue}if(n[0]===3&&(!s||n[1]>s[0]&&n[1]<s[3])){o.label=n[1];break}if(n[0]===6&&o.label<s[1]){o.label=s[1];s=n;break}if(s&&o.label<s[2]){o.label=s[2];o.ops.push(n);break}if(s[2])o.ops.pop();o.trys.pop();continue}n=t.call(e,o)}catch(e){n=[6,e];a=0}finally{i=s=0}if(n[0]&5)throw n[1];return{value:n[0]?n[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(e,t,o){if(o||arguments.length===2)for(var i=0,a=t.length,s;i<a;i++){if(s||!(i in t)){if(!s)s=Array.prototype.slice.call(t,0,i);s[i]=t[i]}}return e.concat(s||Array.prototype.slice.call(t))};import{r as registerInstance,c as createEvent,h,F as Fragment}from"./index-CjTHbolG.js";import{VerdocsEndpoint,formatFullName,getActiveEntitlements,isValidEmail}from"@verdocs/js-sdk";import{c as convertToE164}from"./utils-Bh3zb1Xs.js";import"./index-BglCURB-.js";import"./Types-CIxfEdV7.js";var verdocsContactPickerCss=function(){return'verdocs-contact-picker{display:block;border:1px solid #ebebeb;background-color:#ffffff;font-family:var(--verdocs-primary-font, "Inter", "Barlow", sans-serif);-webkit-box-shadow:0 0 15px 0 rgba(0, 0, 0, 0.1);box-shadow:0 0 15px 0 rgba(0, 0, 0, 0.1)}verdocs-contact-picker form{gap:12px;width:300px;padding:12px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;background-color:#f5f5fa}verdocs-contact-picker form .row{gap:8px;display:-ms-flexbox;display:flex;position:relative;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:start;align-items:flex-start}verdocs-contact-picker form .row .option{gap:4px;display:-ms-flexbox;display:flex;padding:5px 8px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;text-wrap:nowrap}verdocs-contact-picker form .names-row{gap:8px;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-contact-picker form .names-row>input{font-size:14px;width:88px}verdocs-contact-picker form .pin-code{gap:8px;display:-ms-flexbox;display:flex;-ms-flex-align:start;align-items:flex-start;-ms-flex-direction:row;flex-direction:row}verdocs-contact-picker form .pin-code>input{-ms-flex:0 0 197px;flex:0 0 197px;font-size:14px}verdocs-contact-picker form .address{gap:8px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}verdocs-contact-picker form .address>input{-ms-flex:1;flex:1;font-size:14px}verdocs-contact-picker form .zip-code{gap:8px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}verdocs-contact-picker form .zip-code>input{-ms-flex:1;flex:1;font-size:14px}verdocs-contact-picker form label{display:-ms-flexbox;display:flex;-ms-flex:0 0 80px;flex:0 0 80px;font-size:13px;font-weight:500;color:#5c6575}verdocs-contact-picker form .row.message textarea{width:100%;padding:5px 7px;border-radius:4px;font-family:var(--verdocs-primary-font, "Inter", "Barlow", sans-serif)}verdocs-contact-picker form input{-ms-flex:1;flex:1;padding:6px;font-size:14px;border-radius:3px;border:1px solid rgba(112, 122, 229, 0.3725490196)}verdocs-contact-picker form input:focus{outline:none}verdocs-contact-picker .buttons{display:-ms-flexbox;display:flex;-webkit-column-gap:6px;-moz-column-gap:6px;column-gap:6px;margin-top:16px;-ms-flex-direction:row;flex-direction:row}verdocs-contact-picker .buttons .flex-fill{-ms-flex:1;flex:1}verdocs-contact-picker ::-webkit-input-placeholder{color:#aaaaaa}verdocs-contact-picker ::-moz-placeholder{color:#aaaaaa}verdocs-contact-picker :-ms-input-placeholder{color:#aaaaaa}verdocs-contact-picker ::-ms-input-placeholder{color:#aaaaaa}verdocs-contact-picker ::placeholder{color:#aaaaaa}verdocs-contact-picker [data-lastpass-icon-root]{display:none !important}#verdocs-contact-picker-suggestions .dropdown{max-height:225px;overflow-y:scroll;background:#ffffff;font-family:var(--verdocs-primary-font, "Inter", "Barlow", sans-serif);-webkit-box-shadow:0 0 15px 0 rgba(0, 0, 0, 0.1);box-shadow:0 0 15px 0 rgba(0, 0, 0, 0.1)}#verdocs-contact-picker-suggestions .dropdown .suggestion{display:-ms-flexbox;display:flex;padding:6px 12px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row}#verdocs-contact-picker-suggestions .dropdown .suggestion svg{width:32px;height:32px}#verdocs-contact-picker-suggestions .dropdown .suggestion .avatar{width:32px;height:32px;-ms-flex:0 0 32px;flex:0 0 32px;margin-right:8px;border-radius:100%}#verdocs-contact-picker-suggestions .dropdown .suggestion .details{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}#verdocs-contact-picker-suggestions .dropdown .suggestion .name{font-size:16px;font-weight:500;margin-bottom:3px;color:#092c4c}#verdocs-contact-picker-suggestions .dropdown .suggestion .destination{font-size:14px;margin-bottom:3px;color:#33364b}#verdocs-contact-picker-suggestions .dropdown .suggestion:hover{background:#eee;cursor:pointer}'};var addrBookIcon='<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-book-user"><path d="M15 13a3 3 0 1 0-6 0"/><path d="M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H19a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1H6.5a1 1 0 0 1 0-5H20"/><circle cx="12" cy="8" r="2"/></svg>';var VerdocsContactPicker=function(){function e(e){registerInstance(this,e);this.searchContacts=createEvent(this,"searchContacts");this.exit=createEvent(this,"exit");this.next=createEvent(this,"next");this.endpoint=VerdocsEndpoint.getDefault();this.templateRole=null;this.contactSuggestions=[];this.showSuggestions=false;this.showMessage=false;this.delegator=false;this.name_locked=false;this.auth_methods=[];this.passcode="";this.firstNameFieldId="verdocs-contact-picker-firstname-".concat(Math.random().toString(36).substring(2,11));this.lastNameFieldId="verdocs-contact-picker-lastname-".concat(Math.random().toString(36).substring(2,11));this.emailFieldId="verdocs-contact-picker-email-".concat(Math.random().toString(36).substring(2,11));this.phoneFieldId="verdocs-contact-picker-phone-".concat(Math.random().toString(36).substring(2,11));this.activeEntitlements={};this.authMethodsLoading=true}e.prototype.componentWillLoad=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,o,i,a;return __generator(this,(function(s){switch(s.label){case 0:this.endpoint.loadSession();if(this.templateRole){e=formatFullName(this.templateRole);t=e.split(" ");o=this.templateRole.first_name||t.shift()||"";i=this.templateRole.last_name||t.join(" ")||"";this.first_name=o;this.last_name=i;this.email=this.templateRole.email||"";this.phone=this.templateRole.phone||"";this.delegator=this.templateRole.delegator||false;this.name_locked=this.delegator?false:this.templateRole.name_locked||false;this.message=this.templateRole.message||"";this.showMessage=this.message!=="";this.auth_methods=this.templateRole.auth_methods||[];this.passcode=this.templateRole.passcode||""}a=this;return[4,getActiveEntitlements(this.endpoint).catch((function(e){console.warn("[CONTACT PICKER] Unable to load entitlements, continuing with base auth methods only",e);return{}}))];case 1:a.activeEntitlements=s.sent();this.authMethodsLoading=false;console.log("[CONTACT PICKER] Loaded entitlements",this.activeEntitlements);return[2]}}))}))};e.prototype.handleFirstNameChange=function(e){var t;this.first_name=e.target.value;(t=this.searchContacts)===null||t===void 0?void 0:t.emit({query:this.first_name})};e.prototype.handleLastNameChange=function(e){var t;this.last_name=e.target.value;(t=this.searchContacts)===null||t===void 0?void 0:t.emit({query:this.last_name})};e.prototype.handleCancel=function(e){var t;e.stopPropagation();this.showSuggestions=false;(t=this.exit)===null||t===void 0?void 0:t.emit()};e.prototype.handleSubmit=function(e){var t;e.stopPropagation();this.showSuggestions=false;(t=this.next)===null||t===void 0?void 0:t.emit({first_name:this.first_name,last_name:this.last_name,email:this.email,phone:this.phone,message:this.message,delegator:this.delegator,name_locked:this.name_locked,auth_methods:this.auth_methods,passcode:this.passcode,address:this.address,zip:this.zip})};e.prototype.handleSelectSuggestion=function(e,t){e.stopPropagation();this.first_name=t.first_name;this.last_name=t.last_name;this.email=t.email;this.phone=t.phone;this.showSuggestions=false};e.prototype.render=function(){var e=this;var t=this.first_name&&this.last_name&&isValidEmail(this.email);var o=!this.auth_methods.length||this.auth_methods.includes("passcode")&&!!this.passcode||this.auth_methods.includes("kba")&&!!this.first_name&&!!this.last_name||this.auth_methods.includes("email")&&!!this.email||this.auth_methods.includes("sms")&&!!this.phone;var i=t&&o;var a=!!this.activeEntitlements.sms_auth;var s=[];s.push({label:"Passcode",value:"passcode"});s.push({label:"Email",value:"email"});if(a){s.push({label:"SMS (One-Time Code)",value:"sms"})}if(!!this.activeEntitlements.kba_auth){s.push({label:"Knowledge-Based (KBA)",value:"kba"})}if(!!this.activeEntitlements.id_auth){s.push({label:"ID Check",value:"id"})}return h("form",{key:"6709871235915b9c57af981cb4ab8560c040c29f",onSubmit:function(e){return e.preventDefault()},autocomplete:"off"},h("div",{key:"b4792f8bf7a38bd1eca0a684da63e06607b29d4a",class:"row"},h("label",{key:"75f1386774dcf2dba1ae074e2ef86b9d04525763",htmlFor:this.firstNameFieldId},"Name:"),h("div",{key:"36916fdd64584ef209620a6311c4db381e55ea82",class:"names-row"},h("input",{key:"8ab3867864dad6e2726a09666e8c3334f6bbc713",id:this.firstNameFieldId,name:this.firstNameFieldId,type:"text","data-lpignore":"true",autocomplete:"blocked","aria-autocomplete":"none",value:this.first_name,placeholder:"First...",onFocus:function(){setTimeout((function(){var t;e.showSuggestions=((t=e.contactSuggestions)===null||t===void 0?void 0:t.length)>0}),100)},onInput:function(t){return e.handleFirstNameChange(t)}}),h("input",{key:"000acb6f26cfa8a78105b211df519ef3851dc474",id:this.lastNameFieldId,name:this.lastNameFieldId,type:"text","data-lpignore":"true",autocomplete:"blocked","aria-autocomplete":"none",value:this.last_name,placeholder:"Last...",onFocus:function(){setTimeout((function(){var t;e.showSuggestions=((t=e.contactSuggestions)===null||t===void 0?void 0:t.length)>0}),100)},onInput:function(t){return e.handleLastNameChange(t)}})),this.showSuggestions&&h("verdocs-portal",{key:"4e9c8ee57f464fcf09578430e1fe09981e87bafc",anchor:this.firstNameFieldId,onClickAway:function(){e.showSuggestions=false;document.querySelectorAll(".verdocs-portal-wrapper").forEach((function(e){return e.remove()}))},id:"verdocs-contact-picker-suggestions"},h("div",{key:"5cbf60f0f1186f318f686ef6bdc8d791072e4d41",class:"dropdown"},this.contactSuggestions.filter((function(t){var o;return!e.first_name||((o=t.first_name)===null||o===void 0?void 0:o.toLowerCase().includes(e.first_name.toLowerCase()))})).map((function(t){var o;return h("div",{key:(o=t.id)!==null&&o!==void 0?o:t.email,class:"suggestion",onClick:function(o){return e.handleSelectSuggestion(o,t)}},t.picture?h("img",{alt:"Avatar",class:"avatar",src:t.picture}):h("div",{class:"avatar",innerHTML:addrBookIcon}),h("div",{class:"details"},h("div",{class:"name"},formatFullName(t)),t.email&&h("div",{class:"destination"},t.email),t.phone&&h("div",{class:"destination"},t.phone)))}))))),h("div",{key:"3d6aaa5e5bd3f0bc5681c4b788f222b6dfb45584",class:"row"},h("label",{key:"67e9b6d47602d8c455a46e47b94bf008d2ac3a4e",htmlFor:this.emailFieldId},"Email:"),h("input",{key:"b65569322f9a9864fe82ac3371ffcf4e769b69f1",id:this.emailFieldId,name:this.emailFieldId,type:"text","data-lpignore":"true",autoComplete:"blocked","aria-autocomplete":"none",value:this.email,placeholder:"Invite/verify via email...",onFocus:function(){return e.showSuggestions=false},onInput:function(t){return e.email=t.target.value}})),a&&h("div",{key:"defed17223c457db6eea0aff5c13598a70882157",class:"row"},h("label",{key:"7a06bd13e92cd70c51f23228bbe4ed5be59919bb",htmlFor:this.phoneFieldId},"Phone:"),h("input",{key:"770012fd3d838449afa88309f7b003c600e10a1c",id:this.phoneFieldId,name:this.phoneFieldId,type:"text","data-lpignore":"true",autoComplete:"blocked","aria-autocomplete":"none",value:this.phone,placeholder:"Invite/verify via SMS...",onFocus:function(){return e.showSuggestions=false},onInput:function(t){e.phone=convertToE164(t.target.value)}})),h(Fragment,{key:"e0071e7e2fb5521685c8863dab279f31089bf20e"},s.length>0&&h("div",{key:"7f769fdb13d206c769b813eef2c68e810bc635f3",class:"row pin-code"},h("label",{key:"4ebf33f0821f3b1f2a63ac918d3d2923b8f38e38"},"Verification Methods:"),this.authMethodsLoading?h("verdocs-spinner",{size:10,mode:"dark",style:{margin:"auto"}}):h("div",null,s.map((function(t,o){return h("div",{class:"option"},h("verdocs-checkbox",{size:"small",id:"verdocs-multi-select-opt-".concat(o),value:t.value,checked:e.auth_methods.includes(t.value),onInput:function(o){if(o.target.checked){e.auth_methods=__spreadArray(__spreadArray([],e.auth_methods,true),[t.value],false)}else{e.auth_methods=e.auth_methods.filter((function(e){return e!==t.value}))}}}),h("label",{htmlFor:"verdocs-multi-select-option-".concat(o)},t.label))})))),this.auth_methods.includes("passcode")&&h("div",{key:"79feab0e29cbfbbb825f285a995d21576732bb8a",class:"row pin-code"},h("label",{key:"7fd8dd8c3f254e9d6eba0e657f3a02f0fd47b05e",htmlFor:this.phoneFieldId},"Passcode:"),h("input",{key:"a9d0055ca2669776bc465ed4d7a1ce414bb628a4",id:"verdocs-passcode",name:"verdocs-passcode",type:"text","data-lpignore":"true",autocomplete:"blocked","aria-autocomplete":"none",value:this.passcode,placeholder:"4-8 digits recommended...",onFocus:function(){return e.showSuggestions=false},onInput:function(t){return e.passcode=t.target.value}}))),h("div",{key:"71101e3ae9adab93ffde79f43431ab91657df8cd",class:"row pin-code"},h("label",{key:"312a0dafe35171d1ebc61e62f868e2fdcd8a8e8d",style:{marginTop:"6px"}},"Options:"),h("div",{key:"38341490838ffe88ee03800e886d46b163f1d21a"},h("div",{key:"68fbb6b02029ba082da5db49687989e2d0228235",class:"option"},h("verdocs-checkbox",{key:"57c933a6ebc171d8a0c86452ff26504270175463",size:"small",id:"verdocs-delegator",checked:this.delegator,disabled:this.name_locked,onInput:function(t){e.delegator=t.target.checked;if(e.delegator)e.name_locked=false}}),h("label",{key:"8d4bbaef0ca5cea8100777fa37d520f1bd5a1d1e",htmlFor:"verdocs-delegator"},"May delegate signing")),h("div",{key:"d1278133af51917475ae1778c28da315072ca4a6",class:"option"},h("verdocs-checkbox",{key:"32f6401902c5f850f52c58fb06def2d16fc65e99",size:"small",id:"verdocs-name-locked",checked:this.name_locked,disabled:this.delegator,onInput:function(t){e.name_locked=t.target.checked;if(e.name_locked)e.delegator=false}}),h("label",{key:"82d3cb3a2c48c66e8dd4bf917e35ed85327d994d",htmlFor:"verdocs-name-locked"},"Name locked")))),h("div",{key:"01f4e93445daee8493eb67f41640865753db54bb",class:"row message"},h("label",{key:"499b65b9368abe5f355ece31825fdd6b92905b55",htmlFor:"verdocs-contact-picker-message"},"Message:"),h("textarea",{key:"817c16d982edb9af18f8ebee829ed77068d431b5",id:"verdocs-contact-picker-message",name:"verdocs-contact-picker-message","data-lpignore":"true",autocomplete:"blocked",placeholder:"Optional message to include in invitation...",onFocus:function(){return e.showSuggestions=false},onInput:function(t){return e.message=t.target.value}},this.message)),h("div",{key:"044a45c3a9ba57334c6e10f12e0b1f19ce5c3403",class:"buttons"},h("div",{key:"6aa3536c73eef3852f7d483deee3773413167f5d",class:"flex-fill"}),h("verdocs-button",{key:"7dc65ba7bcb927c9822cc19d00b3a74278db8688",variant:"outline",label:"Cancel",size:"small",onClick:function(t){return e.handleCancel(t)}}),h("verdocs-button",{key:"7f3434aa2547d87ad2a54610374bec0511aa7940",label:"OK",size:"small",disabled:!i,onClick:!i?function(){}:function(t){return e.handleSubmit(t)}})))};return e}();VerdocsContactPicker.style=verdocsContactPickerCss();export{VerdocsContactPicker as verdocs_contact_picker};
2
2
  //# sourceMappingURL=verdocs-contact-picker.entry.js.map