@verdocs/web-sdk 1.4.7 → 1.5.2

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 (114) hide show
  1. package/dist/cjs/VerdocsEndpoint-5e6dd8ef.js +4780 -0
  2. package/dist/cjs/loader.cjs.js +1 -1
  3. package/dist/cjs/verdocs-auth.cjs.entry.js +32 -19
  4. package/dist/cjs/verdocs-dropdown_12.cjs.entry.js +15 -11
  5. package/dist/cjs/verdocs-kba-dialog.cjs.entry.js +1 -1
  6. package/dist/cjs/verdocs-ok-dialog.cjs.entry.js +1 -1
  7. package/dist/cjs/verdocs-quick-functions.cjs.entry.js +5 -0
  8. package/dist/cjs/verdocs-search-activity_2.cjs.entry.js +40 -35
  9. package/dist/cjs/verdocs-search.cjs.entry.js +6 -1
  10. package/dist/cjs/verdocs-sign.cjs.entry.js +26 -161
  11. package/dist/cjs/verdocs-web-sdk.cjs.js +1 -1
  12. package/dist/collection/components/dialogs/verdocs-kba-dialog/verdocs-kba-dialog.css +1 -1
  13. package/dist/collection/components/dialogs/verdocs-ok-dialog/verdocs-ok-dialog.css +1 -1
  14. package/dist/collection/components/elements/verdocs-quick-functions/verdocs-quick-functions.js +31 -1
  15. package/dist/collection/components/elements/verdocs-search-activity/verdocs-search-activity.js +30 -6
  16. package/dist/collection/components/elements/verdocs-search-box/verdocs-search-box.js +26 -0
  17. package/dist/collection/components/embeds/verdocs-auth/verdocs-auth.css +1 -4
  18. package/dist/collection/components/embeds/verdocs-auth/verdocs-auth.js +35 -17
  19. package/dist/collection/components/embeds/verdocs-search/verdocs-search.js +36 -6
  20. package/dist/collection/components/embeds/verdocs-sign/verdocs-sign.css +27 -26
  21. package/dist/collection/components/embeds/verdocs-sign/verdocs-sign.js +40 -23
  22. package/dist/collection/components/embeds/verdocs-sign/verdocs-sign.stories.js +2 -2
  23. package/dist/collection/components/embeds/verdocs-view/verdocs-view.js +26 -0
  24. package/dist/components/VerdocsEndpoint.js +4766 -0
  25. package/dist/components/verdocs-auth.js +33 -18
  26. package/dist/components/verdocs-kba-dialog.js +1 -1
  27. package/dist/components/verdocs-ok-dialog2.js +1 -1
  28. package/dist/components/verdocs-quick-functions.js +8 -1
  29. package/dist/components/verdocs-search-activity2.js +37 -34
  30. package/dist/components/verdocs-search-box2.js +6 -0
  31. package/dist/components/verdocs-search.js +9 -2
  32. package/dist/components/verdocs-sign.js +27 -162
  33. package/dist/components/verdocs-view2.js +6 -1
  34. package/dist/custom-elements.json +830 -0
  35. package/dist/docs.json +117 -3
  36. package/dist/esm/VerdocsEndpoint-30e1b6ec.js +4766 -0
  37. package/dist/esm/loader.js +1 -1
  38. package/dist/esm/verdocs-auth.entry.js +32 -19
  39. package/dist/esm/verdocs-dropdown_12.entry.js +5 -1
  40. package/dist/esm/verdocs-kba-dialog.entry.js +1 -1
  41. package/dist/esm/verdocs-ok-dialog.entry.js +1 -1
  42. package/dist/esm/verdocs-quick-functions.entry.js +5 -0
  43. package/dist/esm/verdocs-search-activity_2.entry.js +40 -35
  44. package/dist/esm/verdocs-search.entry.js +6 -1
  45. package/dist/esm/verdocs-sign.entry.js +26 -161
  46. package/dist/esm/verdocs-web-sdk.js +1 -1
  47. package/dist/esm-es5/VerdocsEndpoint-30e1b6ec.js +7 -0
  48. package/dist/esm-es5/loader.js +1 -1
  49. package/dist/esm-es5/verdocs-auth.entry.js +1 -1
  50. package/dist/esm-es5/verdocs-dropdown_12.entry.js +2 -2
  51. package/dist/esm-es5/verdocs-kba-dialog.entry.js +1 -1
  52. package/dist/esm-es5/verdocs-ok-dialog.entry.js +1 -1
  53. package/dist/esm-es5/verdocs-quick-functions.entry.js +1 -1
  54. package/dist/esm-es5/verdocs-search-activity_2.entry.js +1 -1
  55. package/dist/esm-es5/verdocs-search.entry.js +1 -1
  56. package/dist/esm-es5/verdocs-sign.entry.js +1 -1
  57. package/dist/esm-es5/verdocs-web-sdk.js +1 -1
  58. package/dist/types/components/elements/verdocs-quick-functions/verdocs-quick-functions.d.ts +5 -0
  59. package/dist/types/components/elements/verdocs-search-activity/verdocs-search-activity.d.ts +5 -0
  60. package/dist/types/components/elements/verdocs-search-box/verdocs-search-box.d.ts +5 -0
  61. package/dist/types/components/embeds/verdocs-auth/verdocs-auth.d.ts +7 -4
  62. package/dist/types/components/embeds/verdocs-search/verdocs-search.d.ts +5 -0
  63. package/dist/types/components/embeds/verdocs-sign/verdocs-sign.d.ts +6 -3
  64. package/dist/types/components/embeds/verdocs-view/verdocs-view.d.ts +5 -0
  65. package/dist/types/components.d.ts +57 -0
  66. package/dist/verdocs-web-sdk/{p-ed5baeb4.entry.js → p-064453c3.entry.js} +1 -1
  67. package/dist/verdocs-web-sdk/p-06f38046.js +1 -0
  68. package/dist/verdocs-web-sdk/p-16d62a51.system.entry.js +1 -0
  69. package/dist/verdocs-web-sdk/p-1b4e04b7.system.entry.js +1 -0
  70. package/dist/verdocs-web-sdk/p-1ea3b9d3.entry.js +1 -0
  71. package/dist/verdocs-web-sdk/p-30cc8818.entry.js +1 -0
  72. package/dist/verdocs-web-sdk/{p-0353c423.entry.js → p-32ad1014.entry.js} +1 -1
  73. package/dist/verdocs-web-sdk/p-4d80d044.system.js +7 -0
  74. package/dist/verdocs-web-sdk/{p-432c3151.system.entry.js → p-81fc0196.system.entry.js} +1 -1
  75. package/dist/verdocs-web-sdk/p-8276345a.entry.js +1 -0
  76. package/dist/verdocs-web-sdk/p-88a300c5.system.js +1 -1
  77. package/dist/verdocs-web-sdk/p-9139a76d.system.entry.js +1 -0
  78. package/dist/verdocs-web-sdk/p-a87069d5.system.entry.js +1 -0
  79. package/dist/verdocs-web-sdk/p-aa9fc574.entry.js +1 -0
  80. package/dist/verdocs-web-sdk/p-c29c2cf8.entry.js +1 -0
  81. package/dist/verdocs-web-sdk/{p-4368df79.system.entry.js → p-c4d03ff9.system.entry.js} +2 -2
  82. package/dist/verdocs-web-sdk/{p-a1143ddb.entry.js → p-d522de7d.entry.js} +2 -2
  83. package/dist/verdocs-web-sdk/{p-e2e643c5.system.entry.js → p-e4ba14dc.system.entry.js} +1 -1
  84. package/dist/verdocs-web-sdk/p-f6a53928.system.entry.js +1 -0
  85. package/dist/verdocs-web-sdk/verdocs-web-sdk.esm.js +1 -1
  86. package/package.json +2 -2
  87. package/dist/cjs/Auth-4ec35ac7.js +0 -97
  88. package/dist/cjs/Token-ac80819a.js +0 -2331
  89. package/dist/cjs/buffer-es6-bc8199b1.js +0 -2018
  90. package/dist/components/Auth.js +0 -92
  91. package/dist/components/Token.js +0 -2325
  92. package/dist/components/buffer-es6.js +0 -2010
  93. package/dist/esm/Auth-15cd42a8.js +0 -92
  94. package/dist/esm/Token-ce37bd9d.js +0 -2325
  95. package/dist/esm/buffer-es6-136673c8.js +0 -2010
  96. package/dist/esm-es5/Auth-15cd42a8.js +0 -1
  97. package/dist/esm-es5/Token-ce37bd9d.js +0 -1
  98. package/dist/esm-es5/buffer-es6-136673c8.js +0 -7
  99. package/dist/verdocs-web-sdk/p-0c0b4a10.system.entry.js +0 -1
  100. package/dist/verdocs-web-sdk/p-2b57857d.system.entry.js +0 -1
  101. package/dist/verdocs-web-sdk/p-2c161242.system.entry.js +0 -1
  102. package/dist/verdocs-web-sdk/p-39633a02.entry.js +0 -1
  103. package/dist/verdocs-web-sdk/p-5dfd73f9.system.js +0 -7
  104. package/dist/verdocs-web-sdk/p-69ef22bd.entry.js +0 -1
  105. package/dist/verdocs-web-sdk/p-737b2e99.js +0 -1
  106. package/dist/verdocs-web-sdk/p-8730dc92.system.js +0 -1
  107. package/dist/verdocs-web-sdk/p-a7cfe6fc.entry.js +0 -1
  108. package/dist/verdocs-web-sdk/p-b9164c4b.system.entry.js +0 -1
  109. package/dist/verdocs-web-sdk/p-cec13589.system.js +0 -1
  110. package/dist/verdocs-web-sdk/p-e6e2894e.js +0 -1
  111. package/dist/verdocs-web-sdk/p-ea6d6dc7.entry.js +0 -1
  112. package/dist/verdocs-web-sdk/p-ef932a87.js +0 -1
  113. package/dist/verdocs-web-sdk/p-f0e6fde0.entry.js +0 -1
  114. package/dist/verdocs-web-sdk/p-fd853e54.system.entry.js +0 -1
@@ -0,0 +1 @@
1
+ const t="undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{};var n=[],r=[],e="undefined"!=typeof Uint8Array?Uint8Array:Array,i=!1;function o(){i=!0;for(var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",e=0,o=t.length;e<o;++e)n[e]=t[e],r[t.charCodeAt(e)]=e;r["-".charCodeAt(0)]=62,r["_".charCodeAt(0)]=63}function u(t,r,e){for(var i,o=[],u=r;u<e;u+=3)o.push(n[(i=(t[u]<<16)+(t[u+1]<<8)+t[u+2])>>18&63]+n[i>>12&63]+n[i>>6&63]+n[63&i]);return o.join("")}function f(t,n,r,e,i){var o,u,f=8*i-e-1,s=(1<<f)-1,a=s>>1,c=-7,h=r?i-1:0,l=r?-1:1,d=t[n+h];for(h+=l,o=d&(1<<-c)-1,d>>=-c,c+=f;c>0;o=256*o+t[n+h],h+=l,c-=8);for(u=o&(1<<-c)-1,o>>=-c,c+=e;c>0;u=256*u+t[n+h],h+=l,c-=8);if(0===o)o=1-a;else{if(o===s)return u?NaN:1/0*(d?-1:1);u+=Math.pow(2,e),o-=a}return(d?-1:1)*u*Math.pow(2,o-e)}function s(t,n,r,e,i,o){var u,f,s,a=8*o-i-1,c=(1<<a)-1,h=c>>1,l=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,d=e?0:o-1,v=e?1:-1,p=n<0||0===n&&1/n<0?1:0;for(n=Math.abs(n),isNaN(n)||n===1/0?(f=isNaN(n)?1:0,u=c):(u=Math.floor(Math.log(n)/Math.LN2),n*(s=Math.pow(2,-u))<1&&(u--,s*=2),(n+=u+h>=1?l/s:l*Math.pow(2,1-h))*s>=2&&(u++,s/=2),u+h>=c?(f=0,u=c):u+h>=1?(f=(n*s-1)*Math.pow(2,i),u+=h):(f=n*Math.pow(2,h-1)*Math.pow(2,i),u=0));i>=8;t[r+d]=255&f,d+=v,f/=256,i-=8);for(u=u<<i|f,a+=i;a>0;t[r+d]=255&u,d+=v,u/=256,a-=8);t[r+d-v]|=128*p}var a={}.toString,c=Array.isArray||function(t){return"[object Array]"==a.call(t)};function h(){return d.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function l(t,n){if(h()<n)throw new RangeError("Invalid typed array length");return d.TYPED_ARRAY_SUPPORT?(t=new Uint8Array(n)).__proto__=d.prototype:(null===t&&(t=new d(n)),t.length=n),t}function d(t,n,r){if(!(d.TYPED_ARRAY_SUPPORT||this instanceof d))return new d(t,n,r);if("number"==typeof t){if("string"==typeof n)throw new Error("If encoding is specified then the first argument must be a string");return m(this,t)}return v(this,t,n,r)}function v(t,n,r,e){if("number"==typeof n)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&n instanceof ArrayBuffer?function(t,n,r,e){if(r<0||n.byteLength<r)throw new RangeError("'offset' is out of bounds");if(n.byteLength<r+(e||0))throw new RangeError("'length' is out of bounds");return n=void 0===r&&void 0===e?new Uint8Array(n):void 0===e?new Uint8Array(n,r):new Uint8Array(n,r,e),d.TYPED_ARRAY_SUPPORT?(t=n).__proto__=d.prototype:t=w(t,n),t}(t,n,r,e):"string"==typeof n?function(t,n,r){if("string"==typeof r&&""!==r||(r="utf8"),!d.isEncoding(r))throw new TypeError('"encoding" must be a valid string encoding');var e=0|b(n,r),i=(t=l(t,e)).write(n,r);return i!==e&&(t=t.slice(0,i)),t}(t,n,r):function(t,n){if(g(n)){var r=0|y(n.length);return 0===(t=l(t,r)).length||n.copy(t,0,0,r),t}if(n){if("undefined"!=typeof ArrayBuffer&&n.buffer instanceof ArrayBuffer||"length"in n)return"number"!=typeof n.length||(e=n.length)!=e?l(t,0):w(t,n);if("Buffer"===n.type&&c(n.data))return w(t,n.data)}var e;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(t,n)}function p(t){if("number"!=typeof t)throw new TypeError('"size" argument must be a number');if(t<0)throw new RangeError('"size" argument must not be negative')}function m(t,n){if(p(n),t=l(t,n<0?0:0|y(n)),!d.TYPED_ARRAY_SUPPORT)for(var r=0;r<n;++r)t[r]=0;return t}function w(t,n){var r=n.length<0?0:0|y(n.length);t=l(t,r);for(var e=0;e<r;e+=1)t[e]=255&n[e];return t}function y(t){if(t>=h())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+h().toString(16)+" bytes");return 0|t}function g(t){return!(null==t||!t._isBuffer)}function b(t,n){if(g(t))return t.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(t)||t instanceof ArrayBuffer))return t.byteLength;"string"!=typeof t&&(t=""+t);var r=t.length;if(0===r)return 0;for(var e=!1;;)switch(n){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return X(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return K(t).length;default:if(e)return X(t).length;n=(""+n).toLowerCase(),e=!0}}function E(t,n,r){var e=!1;if((void 0===n||n<0)&&(n=0),n>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(n>>>=0))return"";for(t||(t="utf8");;)switch(t){case"hex":return U(this,n,r);case"utf8":case"utf-8":return M(this,n,r);case"ascii":return k(this,n,r);case"latin1":case"binary":return D(this,n,r);case"base64":return N(this,n,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return F(this,n,r);default:if(e)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),e=!0}}function _(t,n,r){var e=t[n];t[n]=t[r],t[r]=e}function A(t,n,r,e,i){if(0===t.length)return-1;if("string"==typeof r?(e=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=i?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(i)return-1;r=t.length-1}else if(r<0){if(!i)return-1;r=0}if("string"==typeof n&&(n=d.from(n,e)),g(n))return 0===n.length?-1:R(t,n,r,e,i);if("number"==typeof n)return n&=255,d.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(t,n,r):Uint8Array.prototype.lastIndexOf.call(t,n,r):R(t,[n],r,e,i);throw new TypeError("val must be string, number or Buffer")}function R(t,n,r,e,i){var o,u=1,f=t.length,s=n.length;if(void 0!==e&&("ucs2"===(e=String(e).toLowerCase())||"ucs-2"===e||"utf16le"===e||"utf-16le"===e)){if(t.length<2||n.length<2)return-1;u=2,f/=2,s/=2,r/=2}function a(t,n){return 1===u?t[n]:t.readUInt16BE(n*u)}if(i){var c=-1;for(o=r;o<f;o++)if(a(t,o)===a(n,-1===c?0:o-c)){if(-1===c&&(c=o),o-c+1===s)return c*u}else-1!==c&&(o-=o-c),c=-1}else for(r+s>f&&(r=f-s),o=r;o>=0;o--){for(var h=!0,l=0;l<s;l++)if(a(t,o+l)!==a(n,l)){h=!1;break}if(h)return o}return-1}function O(t,n,r,e){r=Number(r)||0;var i=t.length-r;e?(e=Number(e))>i&&(e=i):e=i;var o=n.length;if(o%2!=0)throw new TypeError("Invalid hex string");e>o/2&&(e=o/2);for(var u=0;u<e;++u){var f=parseInt(n.substr(2*u,2),16);if(isNaN(f))return u;t[r+u]=f}return u}function S(t,n,r,e){return W(X(n,t.length-r),t,r,e)}function j(t,n,r,e){return W(function(t){for(var n=[],r=0;r<t.length;++r)n.push(255&t.charCodeAt(r));return n}(n),t,r,e)}function T(t,n,r,e){return j(t,n,r,e)}function B(t,n,r,e){return W(K(n),t,r,e)}function x(t,n,r,e){return W(function(t,n){for(var r,e,i=[],o=0;o<t.length&&!((n-=2)<0);++o)e=(r=t.charCodeAt(o))>>8,i.push(r%256),i.push(e);return i}(n,t.length-r),t,r,e)}function N(t,r,e){return function(t){var r;i||o();for(var e=t.length,f=e%3,s="",a=[],c=16383,h=0,l=e-f;h<l;h+=c)a.push(u(t,h,h+c>l?l:h+c));return 1===f?(s+=n[(r=t[e-1])>>2],s+=n[r<<4&63],s+="=="):2===f&&(s+=n[(r=(t[e-2]<<8)+t[e-1])>>10],s+=n[r>>4&63],s+=n[r<<2&63],s+="="),a.push(s),a.join("")}(0===r&&e===t.length?t:t.slice(r,e))}function M(t,n,r){r=Math.min(t.length,r);for(var e=[],i=n;i<r;){var o,u,f,s,a=t[i],c=null,h=a>239?4:a>223?3:a>191?2:1;if(i+h<=r)switch(h){case 1:a<128&&(c=a);break;case 2:128==(192&(o=t[i+1]))&&(s=(31&a)<<6|63&o)>127&&(c=s);break;case 3:u=t[i+2],128==(192&(o=t[i+1]))&&128==(192&u)&&(s=(15&a)<<12|(63&o)<<6|63&u)>2047&&(s<55296||s>57343)&&(c=s);break;case 4:u=t[i+2],f=t[i+3],128==(192&(o=t[i+1]))&&128==(192&u)&&128==(192&f)&&(s=(15&a)<<18|(63&o)<<12|(63&u)<<6|63&f)>65535&&s<1114112&&(c=s)}null===c?(c=65533,h=1):c>65535&&(e.push((c-=65536)>>>10&1023|55296),c=56320|1023&c),e.push(c),i+=h}return function(t){var n=t.length;if(n<=4096)return String.fromCharCode.apply(String,t);for(var r="",e=0;e<n;)r+=String.fromCharCode.apply(String,t.slice(e,e+=4096));return r}(e)}function k(t,n,r){var e="";r=Math.min(t.length,r);for(var i=n;i<r;++i)e+=String.fromCharCode(127&t[i]);return e}function D(t,n,r){var e="";r=Math.min(t.length,r);for(var i=n;i<r;++i)e+=String.fromCharCode(t[i]);return e}function U(t,n,r){var e,i=t.length;(!n||n<0)&&(n=0),(!r||r<0||r>i)&&(r=i);for(var o="",u=n;u<r;++u)o+=(e=t[u])<16?"0"+e.toString(16):e.toString(16);return o}function F(t,n,r){for(var e=t.slice(n,r),i="",o=0;o<e.length;o+=2)i+=String.fromCharCode(e[o]+256*e[o+1]);return i}function C(t,n,r){if(t%1!=0||t<0)throw new RangeError("offset is not uint");if(t+n>r)throw new RangeError("Trying to access beyond buffer length")}function P(t,n,r,e,i,o){if(!g(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(n>i||n<o)throw new RangeError('"value" argument is out of bounds');if(r+e>t.length)throw new RangeError("Index out of range")}function I(t,n,r,e){n<0&&(n=65535+n+1);for(var i=0,o=Math.min(t.length-r,2);i<o;++i)t[r+i]=(n&255<<8*(e?i:1-i))>>>8*(e?i:1-i)}function z(t,n,r,e){n<0&&(n=4294967295+n+1);for(var i=0,o=Math.min(t.length-r,4);i<o;++i)t[r+i]=n>>>8*(e?i:3-i)&255}function L(t,n,r,e){if(r+e>t.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function J(t,n,r,e,i){return i||L(t,0,r,4),s(t,n,r,e,23,4),r+4}function q(t,n,r,e,i){return i||L(t,0,r,8),s(t,n,r,e,52,8),r+8}d.TYPED_ARRAY_SUPPORT=void 0===t.TYPED_ARRAY_SUPPORT||t.TYPED_ARRAY_SUPPORT,d.poolSize=8192,d._augment=function(t){return t.__proto__=d.prototype,t},d.from=function(t,n,r){return v(null,t,n,r)},d.TYPED_ARRAY_SUPPORT&&(d.prototype.__proto__=Uint8Array.prototype,d.__proto__=Uint8Array),d.alloc=function(t,n,r){return function(t,n,r,e){return p(n),n<=0?l(t,n):void 0!==r?"string"==typeof e?l(t,n).fill(r,e):l(t,n).fill(r):l(t,n)}(null,t,n,r)},d.allocUnsafe=function(t){return m(null,t)},d.allocUnsafeSlow=function(t){return m(null,t)},d.isBuffer=function(t){return null!=t&&(!!t._isBuffer||Z(t)||function(t){return"function"==typeof t.readFloatLE&&"function"==typeof t.slice&&Z(t.slice(0,0))}(t))},d.compare=function(t,n){if(!g(t)||!g(n))throw new TypeError("Arguments must be Buffers");if(t===n)return 0;for(var r=t.length,e=n.length,i=0,o=Math.min(r,e);i<o;++i)if(t[i]!==n[i]){r=t[i],e=n[i];break}return r<e?-1:e<r?1:0},d.isEncoding=function(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},d.concat=function(t,n){if(!c(t))throw new TypeError('"list" argument must be an Array of Buffers');if(0===t.length)return d.alloc(0);var r;if(void 0===n)for(n=0,r=0;r<t.length;++r)n+=t[r].length;var e=d.allocUnsafe(n),i=0;for(r=0;r<t.length;++r){var o=t[r];if(!g(o))throw new TypeError('"list" argument must be an Array of Buffers');o.copy(e,i),i+=o.length}return e},d.byteLength=b,d.prototype._isBuffer=!0,d.prototype.swap16=function(){var t=this.length;if(t%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var n=0;n<t;n+=2)_(this,n,n+1);return this},d.prototype.swap32=function(){var t=this.length;if(t%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var n=0;n<t;n+=4)_(this,n,n+3),_(this,n+1,n+2);return this},d.prototype.swap64=function(){var t=this.length;if(t%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var n=0;n<t;n+=8)_(this,n,n+7),_(this,n+1,n+6),_(this,n+2,n+5),_(this,n+3,n+4);return this},d.prototype.toString=function(){var t=0|this.length;return 0===t?"":0===arguments.length?M(this,0,t):E.apply(this,arguments)},d.prototype.equals=function(t){if(!g(t))throw new TypeError("Argument must be a Buffer");return this===t||0===d.compare(this,t)},d.prototype.inspect=function(){var t="";return this.length>0&&(t=this.toString("hex",0,50).match(/.{2}/g).join(" "),this.length>50&&(t+=" ... ")),"<Buffer "+t+">"},d.prototype.compare=function(t,n,r,e,i){if(!g(t))throw new TypeError("Argument must be a Buffer");if(void 0===n&&(n=0),void 0===r&&(r=t?t.length:0),void 0===e&&(e=0),void 0===i&&(i=this.length),n<0||r>t.length||e<0||i>this.length)throw new RangeError("out of range index");if(e>=i&&n>=r)return 0;if(e>=i)return-1;if(n>=r)return 1;if(this===t)return 0;for(var o=(i>>>=0)-(e>>>=0),u=(r>>>=0)-(n>>>=0),f=Math.min(o,u),s=this.slice(e,i),a=t.slice(n,r),c=0;c<f;++c)if(s[c]!==a[c]){o=s[c],u=a[c];break}return o<u?-1:u<o?1:0},d.prototype.includes=function(t,n,r){return-1!==this.indexOf(t,n,r)},d.prototype.indexOf=function(t,n,r){return A(this,t,n,r,!0)},d.prototype.lastIndexOf=function(t,n,r){return A(this,t,n,r,!1)},d.prototype.write=function(t,n,r,e){if(void 0===n)e="utf8",r=this.length,n=0;else if(void 0===r&&"string"==typeof n)e=n,r=this.length,n=0;else{if(!isFinite(n))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");n|=0,isFinite(r)?(r|=0,void 0===e&&(e="utf8")):(e=r,r=void 0)}var i=this.length-n;if((void 0===r||r>i)&&(r=i),t.length>0&&(r<0||n<0)||n>this.length)throw new RangeError("Attempt to write outside buffer bounds");e||(e="utf8");for(var o=!1;;)switch(e){case"hex":return O(this,t,n,r);case"utf8":case"utf-8":return S(this,t,n,r);case"ascii":return j(this,t,n,r);case"latin1":case"binary":return T(this,t,n,r);case"base64":return B(this,t,n,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return x(this,t,n,r);default:if(o)throw new TypeError("Unknown encoding: "+e);e=(""+e).toLowerCase(),o=!0}},d.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},d.prototype.slice=function(t,n){var r,e=this.length;if((t=~~t)<0?(t+=e)<0&&(t=0):t>e&&(t=e),(n=void 0===n?e:~~n)<0?(n+=e)<0&&(n=0):n>e&&(n=e),n<t&&(n=t),d.TYPED_ARRAY_SUPPORT)(r=this.subarray(t,n)).__proto__=d.prototype;else{var i=n-t;r=new d(i,void 0);for(var o=0;o<i;++o)r[o]=this[o+t]}return r},d.prototype.readUIntLE=function(t,n,r){t|=0,n|=0,r||C(t,n,this.length);for(var e=this[t],i=1,o=0;++o<n&&(i*=256);)e+=this[t+o]*i;return e},d.prototype.readUIntBE=function(t,n,r){t|=0,n|=0,r||C(t,n,this.length);for(var e=this[t+--n],i=1;n>0&&(i*=256);)e+=this[t+--n]*i;return e},d.prototype.readUInt8=function(t,n){return n||C(t,1,this.length),this[t]},d.prototype.readUInt16LE=function(t,n){return n||C(t,2,this.length),this[t]|this[t+1]<<8},d.prototype.readUInt16BE=function(t,n){return n||C(t,2,this.length),this[t]<<8|this[t+1]},d.prototype.readUInt32LE=function(t,n){return n||C(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},d.prototype.readUInt32BE=function(t,n){return n||C(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},d.prototype.readIntLE=function(t,n,r){t|=0,n|=0,r||C(t,n,this.length);for(var e=this[t],i=1,o=0;++o<n&&(i*=256);)e+=this[t+o]*i;return e>=(i*=128)&&(e-=Math.pow(2,8*n)),e},d.prototype.readIntBE=function(t,n,r){t|=0,n|=0,r||C(t,n,this.length);for(var e=n,i=1,o=this[t+--e];e>0&&(i*=256);)o+=this[t+--e]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*n)),o},d.prototype.readInt8=function(t,n){return n||C(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},d.prototype.readInt16LE=function(t,n){n||C(t,2,this.length);var r=this[t]|this[t+1]<<8;return 32768&r?4294901760|r:r},d.prototype.readInt16BE=function(t,n){n||C(t,2,this.length);var r=this[t+1]|this[t]<<8;return 32768&r?4294901760|r:r},d.prototype.readInt32LE=function(t,n){return n||C(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},d.prototype.readInt32BE=function(t,n){return n||C(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},d.prototype.readFloatLE=function(t,n){return n||C(t,4,this.length),f(this,t,!0,23,4)},d.prototype.readFloatBE=function(t,n){return n||C(t,4,this.length),f(this,t,!1,23,4)},d.prototype.readDoubleLE=function(t,n){return n||C(t,8,this.length),f(this,t,!0,52,8)},d.prototype.readDoubleBE=function(t,n){return n||C(t,8,this.length),f(this,t,!1,52,8)},d.prototype.writeUIntLE=function(t,n,r,e){t=+t,n|=0,r|=0,e||P(this,t,n,r,Math.pow(2,8*r)-1,0);var i=1,o=0;for(this[n]=255&t;++o<r&&(i*=256);)this[n+o]=t/i&255;return n+r},d.prototype.writeUIntBE=function(t,n,r,e){t=+t,n|=0,r|=0,e||P(this,t,n,r,Math.pow(2,8*r)-1,0);var i=r-1,o=1;for(this[n+i]=255&t;--i>=0&&(o*=256);)this[n+i]=t/o&255;return n+r},d.prototype.writeUInt8=function(t,n,r){return t=+t,n|=0,r||P(this,t,n,1,255,0),d.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[n]=255&t,n+1},d.prototype.writeUInt16LE=function(t,n,r){return t=+t,n|=0,r||P(this,t,n,2,65535,0),d.TYPED_ARRAY_SUPPORT?(this[n]=255&t,this[n+1]=t>>>8):I(this,t,n,!0),n+2},d.prototype.writeUInt16BE=function(t,n,r){return t=+t,n|=0,r||P(this,t,n,2,65535,0),d.TYPED_ARRAY_SUPPORT?(this[n]=t>>>8,this[n+1]=255&t):I(this,t,n,!1),n+2},d.prototype.writeUInt32LE=function(t,n,r){return t=+t,n|=0,r||P(this,t,n,4,4294967295,0),d.TYPED_ARRAY_SUPPORT?(this[n+3]=t>>>24,this[n+2]=t>>>16,this[n+1]=t>>>8,this[n]=255&t):z(this,t,n,!0),n+4},d.prototype.writeUInt32BE=function(t,n,r){return t=+t,n|=0,r||P(this,t,n,4,4294967295,0),d.TYPED_ARRAY_SUPPORT?(this[n]=t>>>24,this[n+1]=t>>>16,this[n+2]=t>>>8,this[n+3]=255&t):z(this,t,n,!1),n+4},d.prototype.writeIntLE=function(t,n,r,e){if(t=+t,n|=0,!e){var i=Math.pow(2,8*r-1);P(this,t,n,r,i-1,-i)}var o=0,u=1,f=0;for(this[n]=255&t;++o<r&&(u*=256);)t<0&&0===f&&0!==this[n+o-1]&&(f=1),this[n+o]=(t/u>>0)-f&255;return n+r},d.prototype.writeIntBE=function(t,n,r,e){if(t=+t,n|=0,!e){var i=Math.pow(2,8*r-1);P(this,t,n,r,i-1,-i)}var o=r-1,u=1,f=0;for(this[n+o]=255&t;--o>=0&&(u*=256);)t<0&&0===f&&0!==this[n+o+1]&&(f=1),this[n+o]=(t/u>>0)-f&255;return n+r},d.prototype.writeInt8=function(t,n,r){return t=+t,n|=0,r||P(this,t,n,1,127,-128),d.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[n]=255&t,n+1},d.prototype.writeInt16LE=function(t,n,r){return t=+t,n|=0,r||P(this,t,n,2,32767,-32768),d.TYPED_ARRAY_SUPPORT?(this[n]=255&t,this[n+1]=t>>>8):I(this,t,n,!0),n+2},d.prototype.writeInt16BE=function(t,n,r){return t=+t,n|=0,r||P(this,t,n,2,32767,-32768),d.TYPED_ARRAY_SUPPORT?(this[n]=t>>>8,this[n+1]=255&t):I(this,t,n,!1),n+2},d.prototype.writeInt32LE=function(t,n,r){return t=+t,n|=0,r||P(this,t,n,4,2147483647,-2147483648),d.TYPED_ARRAY_SUPPORT?(this[n]=255&t,this[n+1]=t>>>8,this[n+2]=t>>>16,this[n+3]=t>>>24):z(this,t,n,!0),n+4},d.prototype.writeInt32BE=function(t,n,r){return t=+t,n|=0,r||P(this,t,n,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),d.TYPED_ARRAY_SUPPORT?(this[n]=t>>>24,this[n+1]=t>>>16,this[n+2]=t>>>8,this[n+3]=255&t):z(this,t,n,!1),n+4},d.prototype.writeFloatLE=function(t,n,r){return J(this,t,n,!0,r)},d.prototype.writeFloatBE=function(t,n,r){return J(this,t,n,!1,r)},d.prototype.writeDoubleLE=function(t,n,r){return q(this,t,n,!0,r)},d.prototype.writeDoubleBE=function(t,n,r){return q(this,t,n,!1,r)},d.prototype.copy=function(t,n,r,e){if(r||(r=0),e||0===e||(e=this.length),n>=t.length&&(n=t.length),n||(n=0),e>0&&e<r&&(e=r),e===r)return 0;if(0===t.length||0===this.length)return 0;if(n<0)throw new RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw new RangeError("sourceStart out of bounds");if(e<0)throw new RangeError("sourceEnd out of bounds");e>this.length&&(e=this.length),t.length-n<e-r&&(e=t.length-n+r);var i,o=e-r;if(this===t&&r<n&&n<e)for(i=o-1;i>=0;--i)t[i+n]=this[i+r];else if(o<1e3||!d.TYPED_ARRAY_SUPPORT)for(i=0;i<o;++i)t[i+n]=this[i+r];else Uint8Array.prototype.set.call(t,this.subarray(r,r+o),n);return o},d.prototype.fill=function(t,n,r,e){if("string"==typeof t){if("string"==typeof n?(e=n,n=0,r=this.length):"string"==typeof r&&(e=r,r=this.length),1===t.length){var i=t.charCodeAt(0);i<256&&(t=i)}if(void 0!==e&&"string"!=typeof e)throw new TypeError("encoding must be a string");if("string"==typeof e&&!d.isEncoding(e))throw new TypeError("Unknown encoding: "+e)}else"number"==typeof t&&(t&=255);if(n<0||this.length<n||this.length<r)throw new RangeError("Out of range index");if(r<=n)return this;var o;if(n>>>=0,r=void 0===r?this.length:r>>>0,t||(t=0),"number"==typeof t)for(o=n;o<r;++o)this[o]=t;else{var u=g(t)?t:X(new d(t,e).toString()),f=u.length;for(o=0;o<r-n;++o)this[o+n]=u[o%f]}return this};var H=/[^+\/0-9A-Za-z-_]/g;function X(t,n){var r;n=n||1/0;for(var e=t.length,i=null,o=[],u=0;u<e;++u){if((r=t.charCodeAt(u))>55295&&r<57344){if(!i){if(r>56319){(n-=3)>-1&&o.push(239,191,189);continue}if(u+1===e){(n-=3)>-1&&o.push(239,191,189);continue}i=r;continue}if(r<56320){(n-=3)>-1&&o.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&(n-=3)>-1&&o.push(239,191,189);if(i=null,r<128){if((n-=1)<0)break;o.push(r)}else if(r<2048){if((n-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((n-=3)<0)break;o.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((n-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function K(t){return function(t){var n,u,f,s,a,c;i||o();var h=t.length;if(h%4>0)throw new Error("Invalid string. Length must be a multiple of 4");c=new e(3*h/4-(a="="===t[h-2]?2:"="===t[h-1]?1:0)),f=a>0?h-4:h;var l=0;for(n=0,u=0;n<f;n+=4,u+=3)s=r[t.charCodeAt(n)]<<18|r[t.charCodeAt(n+1)]<<12|r[t.charCodeAt(n+2)]<<6|r[t.charCodeAt(n+3)],c[l++]=s>>16&255,c[l++]=s>>8&255,c[l++]=255&s;return 2===a?(s=r[t.charCodeAt(n)]<<2|r[t.charCodeAt(n+1)]>>4,c[l++]=255&s):1===a&&(s=r[t.charCodeAt(n)]<<10|r[t.charCodeAt(n+1)]<<4|r[t.charCodeAt(n+2)]>>2,c[l++]=s>>8&255,c[l++]=255&s),c}(function(t){if((t=function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}(t).replace(H,"")).length<2)return"";for(;t.length%4!=0;)t+="=";return t}(t))}function W(t,n,r,e){for(var i=0;i<e&&!(i+r>=n.length||i>=t.length);++i)n[i+r]=t[i];return i}function Z(t){return!!t.constructor&&"function"==typeof t.constructor.isBuffer&&t.constructor.isBuffer(t)}var $="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",V=/^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/,G=function(t){var n;try{if(null===(n=function(t){return JSON.parse(function(t){if(t=String(t).replace(/[\t\n\f\r ]+/g,""),!V.test(t))throw new TypeError("Failed to execute 'atob' on 'Window': The string to be decoded is not correctly encoded.");var n;t+="==".slice(2-(3&t.length));for(var r,e,i="",o=0;o<t.length;)n=$.indexOf(t.charAt(o++))<<18|$.indexOf(t.charAt(o++))<<12|(r=$.indexOf(t.charAt(o++)))<<6|(e=$.indexOf(t.charAt(o++))),i+=64===r?String.fromCharCode(n>>16&255):64===e?String.fromCharCode(n>>16&255,n>>8&255):String.fromCharCode(n>>16&255,n>>8&255,255&n);return i}((t||"").split(".")[1]||""))}(t)))return null}catch(t){return null}return Object.keys(n).forEach((function(t){"string"==typeof t&&t.startsWith("https://verdocs.com/")&&(n[t.replace("https://verdocs.com/","")]=n[t],delete n[t])})),n},Q=function(t,n,r,e){return new(r||(r=Promise))((function(i,o){function u(t){try{s(e.next(t))}catch(t){o(t)}}function f(t){try{s(e.throw(t))}catch(t){o(t)}}function s(t){var n;t.done?i(t.value):(n=t.value,n instanceof r?n:new r((function(t){t(n)}))).then(u,f)}s((e=e.apply(t,n||[])).next())}))},Y=function(t,n){var r,e,i,o,u={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:f(0),throw:f(1),return:f(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function f(o){return function(f){return function(o){if(r)throw new TypeError("Generator is already executing.");for(;u;)try{if(r=1,e&&(i=2&o[0]?e.return:o[0]?e.throw||((i=e.return)&&i.call(e),0):e.next)&&!(i=i.call(e,o[1])).done)return i;switch(e=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return u.label++,{value:o[1],done:!1};case 5:u.label++,e=o[1],o=[0];continue;case 7:o=u.ops.pop(),u.trys.pop();continue;default:if(!((i=(i=u.trys).length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){u=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){u.label=o[1];break}if(6===o[0]&&u.label<i[1]){u.label=i[1],i=o;break}if(i&&u.label<i[2]){u.label=i[2],u.ops.push(o);break}i[2]&&u.ops.pop(),u.trys.pop();continue}o=n.call(t,u)}catch(t){o=[6,t],e=0}finally{r=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,f])}}},tt=function(t,n){return Q(void 0,void 0,void 0,(function(){return Y(this,(function(){return[2,t.api.get("/documents/".concat(n.documentId,"/recipients/").concat(encodeURIComponent(n.roleId),"/invitation/").concat(n.inviteCode)).then((function(n){var r,e,i=(null===(r=n.headers)||void 0===r?void 0:r.signer_token)||"",o=G(i);return t.setToken(null===(e=n.headers)||void 0===e?void 0:e.signer_token),{recipient:n.data,session:o,signerToken:i}}))]}))}))},nt=function(t,n){return Q(void 0,void 0,void 0,(function(){return Y(this,(function(){return[2,t.api.get("/documents/".concat(n)).then((function(t){return t.data}))]}))}))},rt=function(t,n,r){return Q(void 0,void 0,void 0,(function(){return Y(this,(function(){return[2,t.api.get("/documents/".concat(n,"/envelope_documents/").concat(r,"?file=true"),{responseType:"arraybuffer"}).then((function(t){return d.from(t.data,"binary").toString("base64")}))]}))}))},et=function(t,n,r,e){return Q(void 0,void 0,void 0,(function(){return Y(this,(function(){return[2,t.api.put("/documents/".concat(n,"/fields/").concat(r),e).then((function(t){return t.data}))]}))}))},it=function(){return(it=Object.assign||function(t){for(var n,r=1,e=arguments.length;r<e;r++)for(var i in n=arguments[r])Object.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i]);return t}).apply(this,arguments)},ot=function(t,n,r,e,i){return o=void 0,u=void 0,s=function(){return function(t,n){var r,e,i,o,u={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:f(0),throw:f(1),return:f(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function f(o){return function(f){return function(o){if(r)throw new TypeError("Generator is already executing.");for(;u;)try{if(r=1,e&&(i=2&o[0]?e.return:o[0]?e.throw||((i=e.return)&&i.call(e),0):e.next)&&!(i=i.call(e,o[1])).done)return i;switch(e=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return u.label++,{value:o[1],done:!1};case 5:u.label++,e=o[1],o=[0];continue;case 7:o=u.ops.pop(),u.trys.pop();continue;default:if(!((i=(i=u.trys).length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){u=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){u.label=o[1];break}if(6===o[0]&&u.label<i[1]){u.label=i[1],i=o;break}if(i&&u.label<i[2]){u.label=i[2],u.ops.push(o);break}i[2]&&u.ops.pop(),u.trys.pop();continue}o=n.call(t,u)}catch(t){o=[6,t],e=0}finally{r=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,f])}}}(this,(function(){return[2,t.api.put("/documents/".concat(n,"/recipients/").concat(r),it({role_name:r,action:e},i||{})).then((function(t){return t.data}))]}))},new((f=void 0)||(f=Promise))((function(t,n){function r(t){try{i(s.next(t))}catch(t){n(t)}}function e(t){try{i(s.throw(t))}catch(t){n(t)}}function i(n){var i;n.done?t(n.value):(i=n.value,i instanceof f?i:new f((function(t){t(i)}))).then(r,e)}i((s=s.apply(o,u||[])).next())}));var o,u,f,s};const ut=Object.freeze({__proto__:null,Documents:Object.freeze({__proto__:null,getSummary:function(t,n){return Q(void 0,void 0,void 0,(function(){return Y(this,(function(){return[2,t.api.post("/documents/summary",{page:n}).then((function(t){return t.data}))]}))}))},searchDocuments:function(t,n){return Q(void 0,void 0,void 0,(function(){return Y(this,(function(){return[2,t.api.post("/documents/search",n).then((function(t){return t.data}))]}))}))},getSigningSession:tt,getDocumentRecipients:function(t,n){return Q(void 0,void 0,void 0,(function(){return Y(this,(function(){return[2,t.api.get("/documents/".concat(n,"/recipients")).then((function(t){return t.data}))]}))}))},getDocument:nt,getDocumentFile:rt,updateDocumentField:et,updateDocumentFieldSignature:function(t,n,r,e){return Q(void 0,void 0,void 0,(function(){return Y(this,(function(){return[2,t.api.put("/documents/".concat(n,"/fields/").concat(r,"/signature/").concat(e)).then((function(t){return t.data}))]}))}))}}),Recipients:Object.freeze({__proto__:null,updateRecipientStatus:ot}),Signatures:Object.freeze({__proto__:null,createSignature:function(t,n,r){var e=new FormData;return e.append("signature",r,n),t.api.post("/signatures",e).then((function(t){return t.data}))},getSignatures:function(t){return t.api.get("/signatures").then((function(t){return t.data}))},getSignature:function(t,n){return t.api.get("/signatures/".concat(n)).then((function(t){return t.data}))},deleteSignature:function(t,n){return t.api.delete("/signatures/".concat(n)).then((function(t){return t.data}))}}),Initials:Object.freeze({__proto__:null,createInitials:function(t,n,r){var e=new FormData;return e.append("initial",r,n),t.api.post("/initials",e).then((function(t){return t.data}))}}),Types:Object.freeze({__proto__:null})});var ft,st,at,ct;!function(t){t.TEMPLATE_CREATOR_CREATE_PUBLIC="template:creator:create:public",t.TEMPLATE_CREATOR_CREATE_ORG="template:creator:create:org",t.TEMPLATE_CREATOR_CREATE_PERSONAL="template:creator:create:personal",t.TEMPLATE_CREATOR_DELETE="template:creator:delete",t.TEMPLATE_CREATOR_VISIBILITY="template:creator:visibility",t.TEMPLATE_MEMBER_READ="template:member:read",t.TEMPLATE_MEMBER_WRITE="template:member:write",t.TEMPLATE_MEMBER_DELETE="template:member:delete",t.TEMPLATE_MEMBER_VISIBILITY="template:member:visibility"}(ft||(ft={})),function(t){t.CREATOR="creator",t.ORGANIZATION_MEMBER="organization_member",t.ORGANIZATION_MEMBER_AS_CREATOR="organization_member_as_creator",t.EVERYONE="everyone",t.EVERYONE_AS_CREATOR="everyone_as_creator"}(st||(st={})),function(t){t.CREATE_PERSONAL="create_personal",t.CREATE_ORG="create_org",t.CREATE_PUBLIC="create_public",t.READ="read",t.WRITE="write",t.DELETE="delete",t.CHANGE_VISIBILITY_PERSONAL="change_visibility_personal",t.CHANGE_VISIBILITY_ORG="change_visibility_org",t.CHANGE_VISIBILITY_PUBLIC="change_visibility_public"}(at||(at={})),function(t){t.CREATED_AT="created_at",t.UPDATED_AT="updated_at",t.NAME="name",t.LAST_USED_AT="last_used_at",t.COUNTER="counter",t.STAR_COUNTER="star_counter"}(ct||(ct={}));var ht,lt=function(t,n){return function(){for(var r=new Array(arguments.length),e=0;e<r.length;e++)r[e]=arguments[e];return t.apply(n,r)}},dt=Object.prototype.toString,vt=(ht=Object.create(null),function(t){var n=dt.call(t);return ht[n]||(ht[n]=n.slice(8,-1).toLowerCase())});function pt(t){return t=t.toLowerCase(),function(n){return vt(n)===t}}function mt(t){return Array.isArray(t)}function wt(t){return void 0===t}var yt=pt("ArrayBuffer");function gt(t){return null!==t&&"object"==typeof t}function bt(t){if("object"!==vt(t))return!1;var n=Object.getPrototypeOf(t);return null===n||n===Object.prototype}var Et=pt("Date"),_t=pt("File"),At=pt("Blob"),Rt=pt("FileList");function Ot(t){return"[object Function]"===dt.call(t)}var St=pt("URLSearchParams");function jt(t,n){if(null!=t)if("object"!=typeof t&&(t=[t]),mt(t))for(var r=0,e=t.length;r<e;r++)n.call(null,t[r],r,t);else for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&n.call(null,t[i],i,t)}var Tt,Bt=(Tt="undefined"!=typeof Uint8Array&&Object.getPrototypeOf(Uint8Array),function(t){return Tt&&t instanceof Tt}),xt={isArray:mt,isArrayBuffer:yt,isBuffer:function(t){return null!==t&&!wt(t)&&null!==t.constructor&&!wt(t.constructor)&&"function"==typeof t.constructor.isBuffer&&t.constructor.isBuffer(t)},isFormData:function(t){var n="[object FormData]";return t&&("function"==typeof FormData&&t instanceof FormData||dt.call(t)===n||Ot(t.toString)&&t.toString()===n)},isArrayBufferView:function(t){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(t):t&&t.buffer&&yt(t.buffer)},isString:function(t){return"string"==typeof t},isNumber:function(t){return"number"==typeof t},isObject:gt,isPlainObject:bt,isUndefined:wt,isDate:Et,isFile:_t,isBlob:At,isFunction:Ot,isStream:function(t){return gt(t)&&Ot(t.pipe)},isURLSearchParams:St,isStandardBrowserEnv:function(){return("undefined"==typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&"undefined"!=typeof window&&"undefined"!=typeof document},forEach:jt,merge:function t(){var n={};function r(r,e){n[e]=bt(n[e])&&bt(r)?t(n[e],r):bt(r)?t({},r):mt(r)?r.slice():r}for(var e=0,i=arguments.length;e<i;e++)jt(arguments[e],r);return n},extend:function(t,n,r){return jt(n,(function(n,e){t[e]=r&&"function"==typeof n?lt(n,r):n})),t},trim:function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")},stripBOM:function(t){return 65279===t.charCodeAt(0)&&(t=t.slice(1)),t},inherits:function(t,n,r,e){t.prototype=Object.create(n.prototype,e),t.prototype.constructor=t,r&&Object.assign(t.prototype,r)},toFlatObject:function(t,n,r){var e,i,o,u={};n=n||{};do{for(i=(e=Object.getOwnPropertyNames(t)).length;i-- >0;)u[o=e[i]]||(n[o]=t[o],u[o]=!0);t=Object.getPrototypeOf(t)}while(t&&(!r||r(t,n))&&t!==Object.prototype);return n},kindOf:vt,kindOfTest:pt,endsWith:function(t,n,r){t=String(t),(void 0===r||r>t.length)&&(r=t.length);var e=t.indexOf(n,r-=n.length);return-1!==e&&e===r},toArray:function(t){if(!t)return null;var n=t.length;if(wt(n))return null;for(var r=new Array(n);n-- >0;)r[n]=t[n];return r},isTypedArray:Bt,isFileList:Rt};function Nt(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}var Mt=function(t,n,r){if(!n)return t;var e;if(r)e=r(n);else if(xt.isURLSearchParams(n))e=n.toString();else{var i=[];xt.forEach(n,(function(t,n){null!=t&&(xt.isArray(t)?n+="[]":t=[t],xt.forEach(t,(function(t){xt.isDate(t)?t=t.toISOString():xt.isObject(t)&&(t=JSON.stringify(t)),i.push(Nt(n)+"="+Nt(t))})))})),e=i.join("&")}if(e){var o=t.indexOf("#");-1!==o&&(t=t.slice(0,o)),t+=(-1===t.indexOf("?")?"?":"&")+e}return t};function kt(){this.handlers=[]}kt.prototype.use=function(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:!!r&&r.synchronous,runWhen:r?r.runWhen:null}),this.handlers.length-1},kt.prototype.eject=function(t){this.handlers[t]&&(this.handlers[t]=null)},kt.prototype.forEach=function(t){xt.forEach(this.handlers,(function(n){null!==n&&t(n)}))};var Dt=kt,Ut="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function Ft(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function Ct(t,n,r){return t(r={path:n,exports:{},require:function(){return It()}},r.exports),r.exports}function Pt(t){if(t.__esModule)return t;var n=Object.defineProperty({},"__esModule",{value:!0});return Object.keys(t).forEach((function(r){var e=Object.getOwnPropertyDescriptor(t,r);Object.defineProperty(n,r,e.get?e:{enumerable:!0,get:function(){return t[r]}})})),n}function It(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}var zt=Ut.process,Lt=function(t,n){xt.forEach(t,(function(r,e){e!==n&&e.toUpperCase()===n.toUpperCase()&&(t[n]=r,delete t[e])}))};function Jt(t,n,r,e,i){Error.call(this),this.message=t,this.name="AxiosError",n&&(this.code=n),r&&(this.config=r),e&&(this.request=e),i&&(this.response=i)}xt.inherits(Jt,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code,status:this.response&&this.response.status?this.response.status:null}}});var qt=Jt.prototype,Ht={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED"].forEach((function(t){Ht[t]={value:t}})),Object.defineProperties(Jt,Ht),Object.defineProperty(qt,"isAxiosError",{value:!0}),Jt.from=function(t,n,r,e,i,o){var u=Object.create(qt);return xt.toFlatObject(t,u,(function(t){return t!==Error.prototype})),Jt.call(u,t.message,n,r,e,i),u.name=t.name,o&&Object.assign(u,o),u};var Xt=Jt,Kt={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Wt=function(t,n){n=n||new FormData;var r=[];function e(t){return null===t?"":xt.isDate(t)?t.toISOString():xt.isArrayBuffer(t)||xt.isTypedArray(t)?"function"==typeof Blob?new Blob([t]):d.from(t):t}return function t(i,o){if(xt.isPlainObject(i)||xt.isArray(i)){if(-1!==r.indexOf(i))throw Error("Circular reference detected in "+o);r.push(i),xt.forEach(i,(function(r,i){if(!xt.isUndefined(r)){var u,f=o?o+"."+i:i;if(r&&!o&&"object"==typeof r)if(xt.endsWith(i,"{}"))r=JSON.stringify(r);else if(xt.endsWith(i,"[]")&&(u=xt.toArray(r)))return void u.forEach((function(t){!xt.isUndefined(t)&&n.append(f,e(t))}));t(r,f)}})),r.pop()}else n.append(o,e(i))}(t),n},Zt=xt.isStandardBrowserEnv()?{write:function(t,n,r,e,i,o){var u=[];u.push(t+"="+encodeURIComponent(n)),xt.isNumber(r)&&u.push("expires="+new Date(r).toGMTString()),xt.isString(e)&&u.push("path="+e),xt.isString(i)&&u.push("domain="+i),!0===o&&u.push("secure"),document.cookie=u.join("; ")},read:function(t){var n=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return n?decodeURIComponent(n[3]):null},remove:function(t){this.write(t,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}},$t=function(t,n){return t&&!/^([a-z][a-z\d+\-.]*:)?\/\//i.test(n)?function(t,n){return n?t.replace(/\/+$/,"")+"/"+n.replace(/^\/+/,""):t}(t,n):n},Vt=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"],Gt=xt.isStandardBrowserEnv()?function(){var t,n=/(msie|trident)/i.test(navigator.userAgent),r=document.createElement("a");function e(t){var e=t;return n&&(r.setAttribute("href",e),e=r.href),r.setAttribute("href",e),{href:r.href,protocol:r.protocol?r.protocol.replace(/:$/,""):"",host:r.host,search:r.search?r.search.replace(/^\?/,""):"",hash:r.hash?r.hash.replace(/^#/,""):"",hostname:r.hostname,port:r.port,pathname:"/"===r.pathname.charAt(0)?r.pathname:"/"+r.pathname}}return t=e(window.location.href),function(n){var r=xt.isString(n)?e(n):n;return r.protocol===t.protocol&&r.host===t.host}}():function(){return!0};function Qt(t){Xt.call(this,null==t?"canceled":t,Xt.ERR_CANCELED),this.name="CanceledError"}xt.inherits(Qt,Xt,{__CANCEL__:!0});var Yt=Qt,tn={"Content-Type":"application/x-www-form-urlencoded"};function nn(t,n){!xt.isUndefined(t)&&xt.isUndefined(t["Content-Type"])&&(t["Content-Type"]=n)}var rn,en={transitional:Kt,adapter:(("undefined"!=typeof XMLHttpRequest||void 0!==zt&&"[object process]"===Object.prototype.toString.call(zt))&&(rn=function(t){return new Promise((function(n,r){var e,i=t.data,o=t.headers,u=t.responseType;function f(){t.cancelToken&&t.cancelToken.unsubscribe(e),t.signal&&t.signal.removeEventListener("abort",e)}xt.isFormData(i)&&xt.isStandardBrowserEnv()&&delete o["Content-Type"];var s=new XMLHttpRequest;if(t.auth){var a=t.auth.username||"",c=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";o.Authorization="Basic "+btoa(a+":"+c)}var h=$t(t.baseURL,t.url);function l(){if(s){var e,i,o,a,c,h="getAllResponseHeaders"in s?(e=s.getAllResponseHeaders(),c={},e?(xt.forEach(e.split("\n"),(function(t){if(a=t.indexOf(":"),i=xt.trim(t.substr(0,a)).toLowerCase(),o=xt.trim(t.substr(a+1)),i){if(c[i]&&Vt.indexOf(i)>=0)return;c[i]="set-cookie"===i?(c[i]?c[i]:[]).concat([o]):c[i]?c[i]+", "+o:o}})),c):c):null;!function(t,n,r){var e=r.config.validateStatus;r.status&&e&&!e(r.status)?n(new Xt("Request failed with status code "+r.status,[Xt.ERR_BAD_REQUEST,Xt.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r)):t(r)}((function(t){n(t),f()}),(function(t){r(t),f()}),{data:u&&"text"!==u&&"json"!==u?s.response:s.responseText,status:s.status,statusText:s.statusText,headers:h,config:t,request:s}),s=null}}if(s.open(t.method.toUpperCase(),Mt(h,t.params,t.paramsSerializer),!0),s.timeout=t.timeout,"onloadend"in s?s.onloadend=l:s.onreadystatechange=function(){s&&4===s.readyState&&(0!==s.status||s.responseURL&&0===s.responseURL.indexOf("file:"))&&setTimeout(l)},s.onabort=function(){s&&(r(new Xt("Request aborted",Xt.ECONNABORTED,t,s)),s=null)},s.onerror=function(){r(new Xt("Network Error",Xt.ERR_NETWORK,t,s,s)),s=null},s.ontimeout=function(){var n=t.timeout?"timeout of "+t.timeout+"ms exceeded":"timeout exceeded";t.timeoutErrorMessage&&(n=t.timeoutErrorMessage),r(new Xt(n,(t.transitional||Kt).clarifyTimeoutError?Xt.ETIMEDOUT:Xt.ECONNABORTED,t,s)),s=null},xt.isStandardBrowserEnv()){var d=(t.withCredentials||Gt(h))&&t.xsrfCookieName?Zt.read(t.xsrfCookieName):void 0;d&&(o[t.xsrfHeaderName]=d)}"setRequestHeader"in s&&xt.forEach(o,(function(t,n){void 0===i&&"content-type"===n.toLowerCase()?delete o[n]:s.setRequestHeader(n,t)})),xt.isUndefined(t.withCredentials)||(s.withCredentials=!!t.withCredentials),u&&"json"!==u&&(s.responseType=t.responseType),"function"==typeof t.onDownloadProgress&&s.addEventListener("progress",t.onDownloadProgress),"function"==typeof t.onUploadProgress&&s.upload&&s.upload.addEventListener("progress",t.onUploadProgress),(t.cancelToken||t.signal)&&(e=function(t){s&&(r(!t||t&&t.type?new Yt:t),s.abort(),s=null)},t.cancelToken&&t.cancelToken.subscribe(e),t.signal&&(t.signal.aborted?e():t.signal.addEventListener("abort",e))),i||(i=null);var v,p=(v=/^([-+\w]{1,25})(:?\/\/|:)/.exec(h))&&v[1]||"";p&&-1===["http","https","file"].indexOf(p)?r(new Xt("Unsupported protocol "+p+":",Xt.ERR_BAD_REQUEST,t)):s.send(i)}))}),rn),transformRequest:[function(t,n){if(Lt(n,"Accept"),Lt(n,"Content-Type"),xt.isFormData(t)||xt.isArrayBuffer(t)||xt.isBuffer(t)||xt.isStream(t)||xt.isFile(t)||xt.isBlob(t))return t;if(xt.isArrayBufferView(t))return t.buffer;if(xt.isURLSearchParams(t))return nn(n,"application/x-www-form-urlencoded;charset=utf-8"),t.toString();var r,e=xt.isObject(t),i=n&&n["Content-Type"];if((r=xt.isFileList(t))||e&&"multipart/form-data"===i){var o=this.env&&this.env.FormData;return Wt(r?{"files[]":t}:t,o&&new o)}return e||"application/json"===i?(nn(n,"application/json"),function(t){if(xt.isString(t))try{return(0,JSON.parse)(t),xt.trim(t)}catch(t){if("SyntaxError"!==t.name)throw t}return(0,JSON.stringify)(t)}(t)):t}],transformResponse:[function(t){var n=this.transitional||en.transitional,r=!(n&&n.silentJSONParsing)&&"json"===this.responseType;if(r||n&&n.forcedJSONParsing&&xt.isString(t)&&t.length)try{return JSON.parse(t)}catch(t){if(r){if("SyntaxError"===t.name)throw Xt.from(t,Xt.ERR_BAD_RESPONSE,this,null,this.response);throw t}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:null},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};xt.forEach(["delete","get","head"],(function(t){en.headers[t]={}})),xt.forEach(["post","put","patch"],(function(t){en.headers[t]=xt.merge(tn)}));var on=en,un=function(t,n,r){var e=this||on;return xt.forEach(r,(function(r){t=r.call(e,t,n)})),t},fn=function(t){return!(!t||!t.__CANCEL__)};function sn(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new Yt}var an=function(t){return sn(t),t.headers=t.headers||{},t.data=un.call(t,t.data,t.headers,t.transformRequest),t.headers=xt.merge(t.headers.common||{},t.headers[t.method]||{},t.headers),xt.forEach(["delete","get","head","post","put","patch","common"],(function(n){delete t.headers[n]})),(t.adapter||on.adapter)(t).then((function(n){return sn(t),n.data=un.call(t,n.data,n.headers,t.transformResponse),n}),(function(n){return fn(n)||(sn(t),n&&n.response&&(n.response.data=un.call(t,n.response.data,n.response.headers,t.transformResponse))),Promise.reject(n)}))},cn=function(t,n){n=n||{};var r={};function e(t,n){return xt.isPlainObject(t)&&xt.isPlainObject(n)?xt.merge(t,n):xt.isPlainObject(n)?xt.merge({},n):xt.isArray(n)?n.slice():n}function i(r){return xt.isUndefined(n[r])?xt.isUndefined(t[r])?void 0:e(void 0,t[r]):e(t[r],n[r])}function o(t){if(!xt.isUndefined(n[t]))return e(void 0,n[t])}function u(r){return xt.isUndefined(n[r])?xt.isUndefined(t[r])?void 0:e(void 0,t[r]):e(void 0,n[r])}function f(r){return r in n?e(t[r],n[r]):r in t?e(void 0,t[r]):void 0}var s={url:o,method:o,data:o,baseURL:u,transformRequest:u,transformResponse:u,paramsSerializer:u,timeout:u,timeoutMessage:u,withCredentials:u,adapter:u,responseType:u,xsrfCookieName:u,xsrfHeaderName:u,onUploadProgress:u,onDownloadProgress:u,decompress:u,maxContentLength:u,maxBodyLength:u,beforeRedirect:u,transport:u,httpAgent:u,httpsAgent:u,cancelToken:u,socketPath:u,responseEncoding:u,validateStatus:f};return xt.forEach(Object.keys(t).concat(Object.keys(n)),(function(t){var n=s[t]||i,e=n(t);xt.isUndefined(e)&&n!==f||(r[t]=e)})),r},hn={};["object","boolean","number","function","string","symbol"].forEach((function(t,n){hn[t]=function(r){return typeof r===t||"a"+(n<1?"n ":" ")+t}}));var ln={};hn.transitional=function(t,n,r){function e(t,n){return"[Axios v0.27.2] Transitional option '"+t+"'"+n+(r?". "+r:"")}return function(r,i,o){if(!1===t)throw new Xt(e(i," has been removed"+(n?" in "+n:"")),Xt.ERR_DEPRECATED);return n&&!ln[i]&&(ln[i]=!0,console.warn(e(i," has been deprecated since v"+n+" and will be removed in the near future"))),!t||t(r,i,o)}};var dn={assertOptions:function(t,n,r){if("object"!=typeof t)throw new Xt("options must be an object",Xt.ERR_BAD_OPTION_VALUE);for(var e=Object.keys(t),i=e.length;i-- >0;){var o=e[i],u=n[o];if(u){var f=t[o],s=void 0===f||u(f,o,t);if(!0!==s)throw new Xt("option "+o+" must be "+s,Xt.ERR_BAD_OPTION_VALUE)}else if(!0!==r)throw new Xt("Unknown option "+o,Xt.ERR_BAD_OPTION)}},validators:hn},vn=dn.validators;function pn(t){this.defaults=t,this.interceptors={request:new Dt,response:new Dt}}pn.prototype.request=function(t,n){"string"==typeof t?(n=n||{}).url=t:n=t||{},(n=cn(this.defaults,n)).method=n.method?n.method.toLowerCase():this.defaults.method?this.defaults.method.toLowerCase():"get";var r=n.transitional;void 0!==r&&dn.assertOptions(r,{silentJSONParsing:vn.transitional(vn.boolean),forcedJSONParsing:vn.transitional(vn.boolean),clarifyTimeoutError:vn.transitional(vn.boolean)},!1);var e=[],i=!0;this.interceptors.request.forEach((function(t){"function"==typeof t.runWhen&&!1===t.runWhen(n)||(i=i&&t.synchronous,e.unshift(t.fulfilled,t.rejected))}));var o,u=[];if(this.interceptors.response.forEach((function(t){u.push(t.fulfilled,t.rejected)})),!i){var f=[an,void 0];for(Array.prototype.unshift.apply(f,e),f=f.concat(u),o=Promise.resolve(n);f.length;)o=o.then(f.shift(),f.shift());return o}for(var s=n;e.length;){var a=e.shift(),c=e.shift();try{s=a(s)}catch(t){c(t);break}}try{o=an(s)}catch(t){return Promise.reject(t)}for(;u.length;)o=o.then(u.shift(),u.shift());return o},pn.prototype.getUri=function(t){t=cn(this.defaults,t);var n=$t(t.baseURL,t.url);return Mt(n,t.params,t.paramsSerializer)},xt.forEach(["delete","get","head","options"],(function(t){pn.prototype[t]=function(n,r){return this.request(cn(r||{},{method:t,url:n,data:(r||{}).data}))}})),xt.forEach(["post","put","patch"],(function(t){function n(n){return function(r,e,i){return this.request(cn(i||{},{method:t,headers:n?{"Content-Type":"multipart/form-data"}:{},url:r,data:e}))}}pn.prototype[t]=n(),pn.prototype[t+"Form"]=n(!0)}));var mn=pn;function wn(t){if("function"!=typeof t)throw new TypeError("executor must be a function.");var n;this.promise=new Promise((function(t){n=t}));var r=this;this.promise.then((function(t){if(r._listeners){var n,e=r._listeners.length;for(n=0;n<e;n++)r._listeners[n](t);r._listeners=null}})),this.promise.then=function(t){var n,e=new Promise((function(t){r.subscribe(t),n=t})).then(t);return e.cancel=function(){r.unsubscribe(n)},e},t((function(t){r.reason||(r.reason=new Yt(t),n(r.reason))}))}wn.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},wn.prototype.subscribe=function(t){this.reason?t(this.reason):this._listeners?this._listeners.push(t):this._listeners=[t]},wn.prototype.unsubscribe=function(t){if(this._listeners){var n=this._listeners.indexOf(t);-1!==n&&this._listeners.splice(n,1)}},wn.source=function(){var t;return{token:new wn((function(n){t=n})),cancel:t}};var yn=wn,gn=function t(n){var r=new mn(n),e=lt(mn.prototype.request,r);return xt.extend(e,mn.prototype,r),xt.extend(e,r),e.create=function(r){return t(cn(n,r))},e}(on);gn.Axios=mn,gn.CanceledError=Yt,gn.CancelToken=yn,gn.isCancel=fn,gn.VERSION="0.27.2",gn.toFormData=Wt,gn.AxiosError=Xt,gn.Cancel=gn.CanceledError,gn.all=function(t){return Promise.all(t)},gn.spread=function(t){return function(n){return t.apply(null,n)}},gn.isAxiosError=function(t){return xt.isObject(t)&&!0===t.isAxiosError};var bn=gn;bn.default=gn;var En=bn,_n=function(){if("object"==typeof self&&self)return self;if("object"==typeof window&&window)return window;throw new Error("Unable to resolve global `this`")},An=function(){if(this)return this;if("object"==typeof globalThis&&globalThis)return globalThis;try{Object.defineProperty(Object.prototype,"__global__",{get:function(){return this},configurable:!0})}catch(t){return _n()}try{return __global__||_n()}finally{delete Object.prototype.__global__}}(),Rn=function(t){return console.debug("[JS-SDK] ".concat(t.method.toUpperCase()," ").concat(t.baseURL).concat(t.url),t.data?JSON.stringify(t.data):""),t},On=function(){function t(t){this.environment="verdocs",this.sessionType="user",this.baseURL="https://api.verdocs.com",this.clientID="not-set",this.timeout=3e3,this.token=null,this.nextListenerId=0,this.sessionListeners=new Map,this.requestLoggerId=null,this.session=null,this.Documents=ut,this.baseURL=(null==t?void 0:t.baseURL)||"https://api.verdocs.com",this.timeout=(null==t?void 0:t.timeout)||3e3,this.environment=(null==t?void 0:t.environment)||"verdocs",this.sessionType=(null==t?void 0:t.sessionType)||"user",this.clientID=(null==t?void 0:t.clientID)||"not-set",this.api=En.create({baseURL:this.baseURL,timeout:this.timeout})}return t.prototype.setDefault=function(){An[Sn]=this},t.getDefault=function(){return An[Sn]},t.prototype.getEnvironment=function(){return this.environment},t.prototype.getSessionType=function(){return this.sessionType},t.prototype.getBaseURL=function(){return this.baseURL},t.prototype.getClientID=function(){return this.clientID},t.prototype.getTimeout=function(){return this.timeout},t.prototype.getSession=function(){return this.session},t.prototype.setEnvironment=function(t){return this.environment=t,this},t.prototype.setSessionType=function(t){return this.sessionType=t,this},t.prototype.setBaseURL=function(t){return this.api.defaults.baseURL=t,this},t.prototype.setClientID=function(t){return this.clientID=t,this.api.defaults.headers.common["X-Client-ID"]=t,this},t.prototype.setTimeout=function(t){return this.timeout=t,this.api.defaults.timeout=t,this},t.prototype.logRequests=function(t){return t&&null===this.requestLoggerId?this.requestLoggerId=this.api.interceptors.request.use(Rn):t||null===this.requestLoggerId||this.api.interceptors.request.eject(this.requestLoggerId),this},t.prototype.setToken=function(t){if(!t)return this.clearSession();var n=G(t);return null===n||n.exp&&1e3*n.exp<(new Date).getTime()?this.clearSession():(this.token=t,this.session=n,this.api.defaults.headers.common.Authorization="Bearer ".concat(t),localStorage.setItem(this.sessionStorageKey(),t),this.notifySessionListeners(),this)},t.prototype.sessionStorageKey=function(){return"verdocs-session-".concat(this.getSessionType(),"-").concat(this.getEnvironment())},t.prototype.clearSession=function(){return localStorage.removeItem(this.sessionStorageKey()),delete this.api.defaults.headers.common.Authorization,this.session=null,this.token=null,this.notifySessionListeners(),this},t.prototype.notifySessionListeners=function(){var t=this;this.sessionListeners.forEach((function(n){try{n(t,t.session)}catch(t){}}))},t.prototype.onSessionChanged=function(t){var n=this;this.nextListenerId++;var r=Symbol.for(""+this.nextListenerId);return this.sessionListeners.set(r,t),function(){n.sessionListeners.delete(r)}},t.prototype.loadSession=function(){var t=localStorage.getItem(this.sessionStorageKey());return t?this.setToken(t):this.clearSession()},t}(),Sn=Symbol.for("verdocs-default-endpoint");An[Sn]||(An[Sn]=new On);export{d as B,On as V,nt as a,rt as b,et as c,Pt as d,Ct as e,Ft as f,tt as g,Ut as h,It as i,zt as p,ot as u}
@@ -0,0 +1 @@
1
+ System.register(["./p-caed7818.system.js","./p-4d80d044.system.js"],(function(e){"use strict";var s,r,t;return{setters:[function(e){s=e.r;r=e.h},function(e){t=e.V}],execute:function(){var i='verdocs-search{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif;display:-ms-flexbox;display:flex;background-color:#1e2031}verdocs-search search-box{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;margin:20px 10px}verdocs-search .boxes{-ms-flex-wrap:wrap;flex-wrap:wrap;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;margin:20px 0}verdocs-search search-recent,verdocs-search search-saved,verdocs-search search-quick-functions,verdocs-search search-starred{display:-ms-flexbox;display:flex;margin:0 20px 20px 0}';var c=e("verdocs_search",function(){function e(e){s(this,e);this.endpoint=t.getDefault()}e.prototype.render=function(){return r("div",{class:"container"},r("verdocs-search-box",{endpoint:this.endpoint}),r("div",{class:"boxes"},r("verdocs-search-activity",{type:"recent",endpoint:this.endpoint}),r("verdocs-search-activity",{type:"saved",endpoint:this.endpoint}),r("verdocs-search-activity",{type:"starred",endpoint:this.endpoint}),r("search-quick-functions",{endpoint:this.endpoint})))};return e}());c.style=i}}}));
@@ -0,0 +1 @@
1
+ System.register(["./p-caed7818.system.js","./p-4d80d044.system.js"],(function(e){"use strict";var t,r,n,i;return{setters:[function(e){t=e.r;r=e.c;n=e.h},function(e){i=e.V}],execute:function(){var o=function(e,t){return e.api.get("/templates/",{params:t}).then((function(e){return e.data}))};var s=undefined&&undefined.__awaiter||function(e,t,r,n){function i(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,o){function s(e){try{c(n.next(e))}catch(e){o(e)}}function a(e){try{c(n["throw"](e))}catch(e){o(e)}}function c(e){e.done?r(e.value):i(e.value).then(s,a)}c((n=n.apply(e,t||[])).next())}))};var a=undefined&&undefined.__generator||function(e,t){var r={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},n,i,o,s;return s={next:a(0),throw:a(1),return:a(2)},typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function a(e){return function(t){return c([e,t])}}function c(s){if(n)throw new TypeError("Generator is already executing.");while(r)try{if(n=1,i&&(o=s[0]&2?i["return"]:s[0]?i["throw"]||((o=i["return"])&&o.call(i),0):i.next)&&!(o=o.call(i,s[1])).done)return o;if(i=0,o)s=[s[0]&2,o.value];switch(s[0]){case 0:case 1:o=s;break;case 4:r.label++;return{value:s[1],done:false};case 5:r.label++;i=s[1];s=[0];continue;case 7:s=r.ops.pop();r.trys.pop();continue;default:if(!(o=r.trys,o=o.length>0&&o[o.length-1])&&(s[0]===6||s[0]===2)){r=0;continue}if(s[0]===3&&(!o||s[1]>o[0]&&s[1]<o[3])){r.label=s[1];break}if(s[0]===6&&r.label<o[1]){r.label=o[1];o=s;break}if(o&&r.label<o[2]){r.label=o[2];r.ops.push(s);break}if(o[2])r.ops.pop();r.trys.pop();continue}s=t.call(e,r)}catch(e){s=[6,e];i=0}finally{n=o=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:true}}};var c=function(e){return s(void 0,void 0,void 0,(function(){return a(this,(function(t){return[2,e.api.get("/search/history").then((function(e){return e.data}))]}))}))};var l='<svg xmlns="http://www.w3.org/2000/svg" height="24px" viewBox="0 0 24 24" width="24px" fill="#000000"><path d="M0 0h24v24H0V0z" fill="none"/><path d="M8 16h8v2H8zm0-4h8v2H8zm6-10H6c-1.1 0-2 .9-2 2v16c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6zm4 18H6V4h7v5h5v11z"/></svg>';var h='verdocs-search-activity{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif}verdocs-search-activity .container{display:-ms-flexbox;display:flex;width:240px;color:#ffffff;-ms-flex-direction:column;flex-direction:column;text-transform:uppercase;padding:10px 10px 20px 10px;background-color:var(--verdocs-background-dark)}verdocs-search-activity .title{font-size:22px;font-weight:700;line-height:30px}verdocs-search-activity .items{display:-ms-flexbox;display:flex;margin-top:20px;-ms-flex-direction:column;flex-direction:column}verdocs-search-activity .item{border:none;display:-ms-flexbox;display:flex;text-align:left;margin-bottom:20px;-ms-flex-direction:row;flex-direction:row;background:transparent}verdocs-search-activity .item:hover{cursor:pointer}verdocs-search-activity .icon{-ms-flex:0 0 22px;flex:0 0 22px;margin-right:14px}verdocs-search-activity .icon svg{fill:#707ae5;width:22px;height:22px}verdocs-search-activity .details{display:-ms-flexbox;display:flex;overflow:hidden;-ms-flex-direction:column;flex-direction:column}verdocs-search-activity .item-title{font-size:16px;font-weight:400;color:#ffffff;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}verdocs-search-activity .info{font-size:14px;font-weight:500;line-height:23px;color:#aeb4bf}verdocs-search-activity .empty{text-transform:none;line-height:22px;color:#ccc}';var d=e("verdocs_search_activity",function(){function e(e){t(this,e);this.entrySelected=r(this,"entrySelected",7);this.endpoint=i.getDefault();this.type="recent";this.emptyMessage="You do not have any starred searches.";this.authFailure=false;this.title="Recent Searches";this.recent=[];this.saved=[];this.starred=[]}e.prototype.componentWillLoad=function(){var e=this;this.endpoint.loadSession();var t=function(t){var r;console.warn("[Verdocs/search-activity] Error getting search data",t);if(((r=t===null||t===void 0?void 0:t.response)===null||r===void 0?void 0:r.status)===401){e.authFailure=true}};switch(this.type){case"recent":this.title="Recent Searches";this.emptyMessage="You do not have any recent searches.";c(this.endpoint).then((function(t){return e.recent=t.recent})).catch(t);break;case"saved":this.title="Saved Searches";this.emptyMessage="You do not have any saved searches.";c(this.endpoint).then((function(t){return e.saved=t.saved})).catch(t);break;case"starred":this.title="My Starred items";this.emptyMessage="You do not have any starred templates.";o(this.endpoint,{is_starred:true}).then((function(t){return e.starred=t})).catch(t);break}};e.prototype.handleSelectEntry=function(e){this.entrySelected.emit(e)};e.prototype.computePagesText=function(e){if(e<2){return"".concat(e," Page")}else{return"".concat(e," Pages")}};e.prototype.computeRecipientsText=function(e){if(typeof e==="object"){return e.join(", ")}else if(e>1){return"".concat(e," Recipients")}else{return"".concat(e," Recipient")}};e.prototype.render=function(){var e=this;var t=this.recent.length<1&&this.saved.length<1&&this.starred.length<1;return n("div",{class:"container"},n("p",{class:"title"},this.title),n("div",{class:"items"},this.recent.map((function(t){return n("button",{class:"item",onClick:function(){return e.handleSelectEntry(t)}},n("div",{class:"icon",innerHTML:l}),n("div",{class:"details"},n("div",{class:"item-title"},t.params.q),n("div",{class:"info"},"Test")))})),this.saved.map((function(t){return n("button",{class:"item",onClick:function(){return e.handleSelectEntry(t)}},n("div",{class:"icon",innerHTML:l}),n("div",{class:"details"},n("div",{class:"item-title"},t.params.q),n("div",{class:"info"})))})),t&&n("div",{class:"empty"},this.authFailure?"Authentication required":this.emptyMessage)))};return e}());d.style=h;var p='<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">\n<path d="M23.4809 20.7176L17.9111 15.2536C19.0961 13.6368 19.727 11.6926 19.7128 9.70131C19.7201 7.53345 18.9846 5.42606 17.6244 3.71753C16.2642 2.009 14.3581 0.798456 12.2123 0.280282C10.0665 -0.237892 7.80552 -0.0336342 5.79227 0.86026C3.77902 1.75415 2.13038 3.28582 1.1111 5.20931C0.0918114 7.1328 -0.238985 9.33652 0.171813 11.4666C0.582612 13.5967 1.71117 15.5296 3.37628 16.9548C5.0414 18.3801 7.14646 19.2151 9.35344 19.3257C11.5604 19.4364 13.7413 18.8162 15.5458 17.5649L21.1372 23.05L21.1563 23.0663C21.4841 23.3487 21.9039 23.507 22.3401 23.5128C22.7823 23.5125 23.2063 23.3402 23.5191 23.0337V23.0337C23.6749 22.8812 23.7979 22.6995 23.8804 22.4993C23.963 22.2991 24.0036 22.0847 23.9997 21.8688C23.9959 21.6529 23.9477 21.44 23.858 21.2428C23.7683 21.0456 23.639 20.8682 23.4778 20.7212L23.4809 20.7176ZM14.5167 14.1975C13.4564 15.2349 12.0623 15.8797 10.5719 16.022C9.08145 16.1644 7.58681 15.7955 6.34249 14.9781C5.09816 14.1608 4.18109 12.9456 3.74751 11.5395C3.31393 10.1334 3.39064 8.6233 3.96455 7.26643C4.53846 5.90955 5.57409 4.7898 6.89507 4.09787C8.21606 3.40594 9.74071 3.18461 11.2093 3.4716C12.678 3.75858 13.9998 4.53612 14.9497 5.6718C15.8996 6.80748 16.4188 8.23105 16.4189 9.7001C16.4196 10.5357 16.2519 11.3632 15.9254 12.135C15.599 12.9069 15.1202 13.6078 14.5167 14.1975V14.1975Z" fill="white"/>\n</svg>\n';var f='<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">\n<path d="M14.0739 11.7565L19.7127 6.23228C20.0875 5.85692 20.0875 5.25309 19.7127 4.87773L19.0213 4.20046C18.6382 3.82511 18.0219 3.82511 17.6387 4.20046L12 9.72472L6.36127 4.20046C5.97814 3.82511 5.36179 3.82511 4.97866 4.20046L4.28735 4.87773C3.90422 5.25309 3.90422 5.85692 4.28735 6.23228L9.92608 11.7565L4.28735 17.2808C3.90422 17.6561 3.90422 18.26 4.28735 18.6353L4.97866 19.3126C5.36179 19.688 5.97814 19.688 6.36127 19.3126L12 13.7883L17.6387 19.3126C18.0219 19.688 18.6382 19.688 19.0213 19.3126L19.7127 18.6353C20.0958 18.26 20.0958 17.6561 19.7127 17.2808L14.0739 11.7565Z" fill="white"/>\n</svg>\n';var u='verdocs-search-box{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif}verdocs-search-box form{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;height:45px;-webkit-box-sizing:border-box;box-sizing:border-box;margin:5px 0 0;border-radius:5px;-ms-flex-align:center;align-items:center;background-color:#fff;padding:0 8px;border-width:1px;border-style:solid;border-color:var(--verdocs-container-border-color)}verdocs-search-box form input{-webkit-box-sizing:border-box;box-sizing:border-box;height:43px;width:100%;font-size:18px;border:none}verdocs-search-box form input:focus{outline:none}verdocs-search-box form button.search{cursor:pointer;display:-ms-inline-flexbox;display:inline-flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;-webkit-box-sizing:border-box;box-sizing:border-box;border-radius:4px;border:none;width:100px;height:28px;font-weight:700;font-size:10px;letter-spacing:1px;background-color:#50be80;text-transform:uppercase;color:#fff}verdocs-search-box form .type{background-color:#707ae5;height:30px;display:-ms-inline-flexbox;display:inline-flex;padding:1px 0 2px 10px;font-size:13px;line-height:16px;border-radius:4px;-ms-flex-pack:center;justify-content:center;text-transform:uppercase;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;color:#fff;margin-right:10px}verdocs-search-box form .type button{border:none;color:#fff;margin:5px 0 0 8px;background:transparent}verdocs-search-box form svg{width:12px;height:12px;margin-right:6px}verdocs-search-box ::-webkit-input-placeholder{color:#aeb4bf}verdocs-search-box ::-moz-placeholder{color:#aeb4bf}verdocs-search-box :-ms-input-placeholder{color:#aeb4bf}verdocs-search-box ::-ms-input-placeholder{color:#aeb4bf}verdocs-search-box ::placeholder{color:#aeb4bf}';var x=e("verdocs_search_box",function(){function e(e){t(this,e);this.searchClicked=r(this,"searchClicked",7);this.typeChanged=r(this,"typeChanged",7);this.queryChanged=r(this,"queryChanged",7);this.endpoint=i.getDefault();this.placeholder="search documents, templates, people...";this.type="all";this.query=""}e.prototype.handleSearch=function(e){this.searchClicked.emit({type:this.type,query:this.query});e.preventDefault();return false};e.prototype.handleChange=function(e){this.queryChanged.emit(e.target.value)};e.prototype.handleClearFilter=function(){this.typeChanged.emit("all")};e.prototype.handleKeyUp=function(e){if(e.key==="Enter"){this.searchClicked.emit({type:this.type,query:this.query})}};e.prototype.render=function(){var e=this;return n("form",{onSubmit:function(t){return e.handleSearch(t)}},this.type!==undefined&&this.type!=="all"&&n("span",{class:"type"},this.type,"s ",n("button",{class:"remove",innerHTML:f,onClick:function(){return e.handleClearFilter()}})),n("input",{type:"text",placeholder:this.placeholder,value:this.query,onInput:function(t){return e.handleChange(t)},onKeyUp:function(t){return e.handleKeyUp(t)}}),n("button",{onClick:function(t){return e.handleSearch(t)},class:"search"},n("span",{innerHTML:p}),"Search"))};return e}());x.style=u}}}));
@@ -0,0 +1 @@
1
+ import{r as t,c as s,h as e}from"./p-2bc58746.js";import{V as i}from"./p-06f38046.js";const o=class{constructor(e){t(this,e),this.authenticated=s(this,"authenticated",7),this.endpoint=i.getDefault(),this.visible=!0,this.logo="https://verdocs.com/assets/blue-logo.svg",this.debug=!1,this.isAuthenticated=!1,this.displayMode="login",this.username="",this.password="",this.loggingIn=!1,this.activeSession=null,this.loginError=null}componentDidLoad(){this.endpoint.loadSession(),null!==this.endpoint.session?(this.isAuthenticated=!0,this.activeSession=this.endpoint.session,this.authenticated.emit({authenticated:!0,session:this.endpoint.session})):this.authenticated.emit({authenticated:!1,session:null})}handleLogin(){var t,s;this.loggingIn=!0,(t=this.endpoint,s={username:this.username,password:this.password},t.api.post("/authentication/login",s).then((function(t){return t.data}))).then((t=>{this.loggingIn=!1,this.endpoint.setToken(t.accessToken),this.activeSession=this.endpoint.session,this.isAuthenticated=!0,this.authenticated.emit({authenticated:!0,session:this.endpoint.session})})).catch((t=>{var s;console.log("[VERDOCS] Login error",t.response,JSON.stringify(t)),this.loggingIn=!1,this.activeSession=null,this.authenticated.emit({authenticated:!1,session:null}),403===(null===(s=null==t?void 0:t.response)||void 0===s?void 0:s.status)&&(this.loginError="Please check your username and password and try again.")}))}handleLogout(){this.endpoint.clearSession(),this.isAuthenticated=!1,this.authenticated.emit({authenticated:!1,session:null})}handleClearError(){this.loginError=null}render(){return this.visible?this.isAuthenticated?this.debug?e("div",{class:"status-result debug"},e("verdocs-button",{label:"Logout",disabled:this.loggingIn,onPress:()=>this.handleLogout()})):e("div",{class:"status-result"},"Authenticated"):"signup"===this.displayMode?e("div",{class:"signup-form"},e("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"}),e("h3",null,"Sign up for an account"),e("h4",null,"Already have an account?",e("verdocs-button",{label:"Log In",variant:"text",onClick:()=>this.displayMode="login",disabled:this.loggingIn})),e("form",{onSubmit:()=>this.handleLogin()},e("verdocs-text-input",{label:"Email",autocomplete:"username",value:this.username,onFieldInput:t=>this.username=t.detail,disabled:this.loggingIn}),e("verdocs-text-input",{label:"Password",type:"password",autocomplete:"current-password",value:this.password,onFieldInput:t=>this.password=t.detail,disabled:this.loggingIn}),e("verdocs-button",{label:"Signup",disabled:this.loggingIn,onPress:()=>this.handleLogin(),style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}}))):e("div",{class:"login-form"},e("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"}),e("h3",null,"Log in to your account"),e("h4",null,"Don't have an account?",e("verdocs-button",{label:"Sign Up",variant:"text",onClick:()=>this.displayMode="signup",disabled:this.loggingIn})),e("form",{onSubmit:()=>this.handleLogin()},e("verdocs-text-input",{label:"Email",autocomplete:"username",value:this.username,onFieldInput:t=>this.username=t.detail,disabled:this.loggingIn}),e("verdocs-text-input",{label:"Password",type:"password",autocomplete:"current-password",value:this.password,onFieldInput:t=>this.password=t.detail,disabled:this.loggingIn}),e("verdocs-button",{label:"Forgot Your Password?",variant:"text",onClick:()=>this.displayMode="signup",disabled:this.loggingIn,style:{display:"flex",justifyContent:"center",margin:"10px auto 20px"}}),e("verdocs-button",{label:"Login",disabled:this.loggingIn,onPress:()=>this.handleLogin(),style:{display:"flex",justifyContent:"center",margin:"10px auto 0"}})),this.loginError?e("verdocs-ok-dialog",{open:!0,heading:"Login Error",message:this.loginError,onClosed:()=>this.handleClearError()}):e("div",null)):e("div",{style:{display:"none"}},"Verdocs Auth Placeholder")}};o.style='verdocs-auth{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}verdocs-auth .login-form,verdocs-auth .signup-form{background:#ffffff;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;-ms-flex-direction:column;flex-direction:column;display:-ms-flexbox;display:flex;padding:20px;width:300px;max-width:100%}verdocs-auth .logo{margin:20px 0 30px;width:128px;max-width:100%}verdocs-auth h3{text-align:center;font-weight:400;font-size:16px;line-height:1.75;margin:0}verdocs-auth h4{text-align:center;font-weight:400;font-size:14px;line-height:1.43;margin:0}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}';export{o as verdocs_auth}
@@ -0,0 +1 @@
1
+ import{r as e,h as o,H as i}from"./p-2bc58746.js";import{V as t,g as s,a as r,u as n,b as a,c as l}from"./p-06f38046.js";var d=new RegExp(/\+[1-9]\d{6,14}/g),c=/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;function u(e){switch(e%10){case 0:return 0===e?"rgba(255, 193, 7, 0.4)":"rgba(134, 134, 134, 0.3)";case 1:return"rgba(156, 39, 176, .4)";case 2:return"rgba(33, 150, 243, .4)";case 3:return"rgba(220, 231, 117, 0.3)";case 4:return"rgba(121, 134, 203, 0.3)";case 5:return"rgba(77, 182, 172, 0.3)";case 6:return"rgba(255, 202, 165, 0.3)";case 7:return"rgba(2, 247, 190, 0.3)";case 8:return"rgba(255, 138, 101, 0.3)";case 9:return"rgba(82, 255, 79, 0.3)";default:return"rgba(229, 115, 155, 0.3)"}}function h(e,o){return e*o}const p=class{constructor(o){e(this,o),this.endpoint=t.getDefault(),this.documentid=null,this.roleid=null,this.invitecode=null,this.recipient=null,this.signerToken=null,this.pdfUrl=null,this.recipientIndex=-1,this.document=null,this.fields=[],this.hasSignature=!1,this.nextButtonLabel="Start",this.focusedField=""}async componentDidLoad(){try{console.log("[SIGN] Processing invite code",this.documentid,this.roleid,this.invitecode);const{session:e,recipient:o,signerToken:i}=await s(this.endpoint,{documentId:this.documentid,roleId:this.roleid,inviteCode:this.invitecode});console.log("[SIGN] Got signing session",e),console.log("[SIGN] Recipient",o),this.recipient=o,this.signerToken=i,this.endpoint.setToken(i),this.recipient.agreed&&(this.nextButtonLabel="Next");const t=await r(this.endpoint,this.documentid);this.document=t,console.log("[SIGN] Document",t),this.pdfUrl=`${this.endpoint.getBaseURL()}/documents/${this.documentid}/envelope_documents/${t.envelope_document_id}?file=true`,this.recipientIndex=this.document.recipients.findIndex((e=>e.role_name==this.roleid)),this.recipientIndex>-1&&console.log("Found recipient",this.document.recipients[this.recipientIndex]),this.fields=this.document.fields.filter((e=>e.recipient_role===this.roleid)),console.log("Loaded fields",this.fields)}catch(e){console.log("Error with signing session",e)}}handleClickAgree(){console.log("agree clicked"),n(this.endpoint,this.documentid,this.roleid,"update",{agreed:!0}).then((e=>{console.log("update result",e),this.nextButtonLabel="Next",this.recipient=e})).catch((e=>{console.log("update failure",e)}))}async savePDF(){const e=`${this.document.name} - ${this.document.updated_at.split("T")[0]}.pdf`,o=await a(this.endpoint,this.documentid,this.document.envelope_document_id);let i=new XMLHttpRequest;i.responseType="blob",i.onload=function(){let o=document.createElement("a");o.href=window.URL.createObjectURL(i.response),o.download=e,o.style.display="none",document.body.appendChild(o),o.click(),o.remove()};const t=`data:application/pdf;base64,${o}`;console.log("url",t.length,t),i.open("GET",`data:application/pdf;base64,${o}`),i.send()}async handleOptionSelected(e){switch(e.detail.id){case"later":(null===window||void 0===window?void 0:window.STORYBOOK_ENV)||window.alert("User intends to sign later.");break;case"claim":case"decline":case"print":break;case"download":this.savePDF().catch((()=>{}))}}async handleFieldChange(e,o,i){switch(console.log("fieldChange",e,o.detail),e.type){case"textbox":l(this.endpoint,this.documentid,e.name,{prepared:!1,value:o.detail}).then((e=>console.log("Update result",e))).catch((e=>console.log("Error updating",e)));break;case"checkbox_group":l(this.endpoint,this.documentid,e.name,{prepared:!1,value:{options:[{id:i,checked:o.detail}]}}).then((e=>console.log("Update result",e))).catch((e=>console.log("Error updating",e)));break;case"radio_button_group":const t=e.settings.options.map((e=>({id:e.id,selected:i===e.id})));l(this.endpoint,this.documentid,e.name,{prepared:!1,value:{options:t}}).then((e=>console.log("Update result",e))).catch((e=>console.log("Error updating",e)));break;case"dropdown":l(this.endpoint,this.documentid,e.name,{prepared:!1,value:o.detail}).then((e=>console.log("Update result",e))).catch((e=>console.log("Error updating",e)));break;case"initial":console.log("Got initial",o.detail);break;case"signature":console.log("Got signature",o.detail)}}renderCheckboxGroupOption(e,i,t,s){const r={left:`${h(e.xRatio,t.x)}px`,bottom:`${h(e.yRatio,t.y)}px`,position:"absolute",transform:`scale(${e.xRatio}, ${e.yRatio})`,backgroundColor:u(this.recipientIndex)};return o("verdocs-field-checkbox",{style:r,order:s,value:t.checked,onFieldChange:e=>this.handleFieldChange(i,e,t.id)})}renderRadioGroupOption(e,i,t,s){const r={left:`${h(e.xRatio,t.x)}px`,bottom:`${h(e.yRatio,t.y)}px`,position:"absolute",transform:`scale(${e.xRatio}, ${e.yRatio})`,backgroundColor:u(this.recipientIndex)};return o("verdocs-field-radio-button",{style:r,order:s,value:t.id,name:i.name,checked:t.selected,onFieldChange:e=>this.handleFieldChange(i,e,t.id)})}renderField(e,i){const{required:t=!1,settings:s={}}=e,{x:r=0,y:n=0,base64:a="",placeholder:l="",options:d=[],value:c="",result:p=""}=s,g=this.pdfPageInfo.pages.find((o=>o.pageNumber===e.page));if(!g)return console.log("Unable to render invalid field",e),o("div",{class:"invalid-field"},"Invalid field.");const x={left:`${h(g.xRatio,r)}px`,bottom:`${h(g.yRatio,n)}px`,position:"absolute",transform:`scale(${g.xRatio}, ${g.yRatio})`,backgroundColor:e.settings.rgba||u(this.recipientIndex)};e.settings.height&&(x.height=`${e.settings.height}px`),e.settings.width&&(x.width=`${e.settings.width}px`),console.log("rendering field",e.type,e);const b=`field-${e.name}`;switch(e.type){case"signature":return o("verdocs-field-signature",{style:x,value:a,required:t,id:b});case"initial":return o("verdocs-field-initial",{style:x,required:t,id:b});case"textbox":return o("verdocs-field-textbox",{style:x,order:i,value:p||"",placeholder:l,id:b,onFieldChange:o=>this.handleFieldChange(e,o)});case"textarea":return o("verdocs-field-textarea",{style:x,placeholder:l||"",id:b});case"date":return o("verdocs-field-date",{style:x,order:i,value:p||"",placeholder:l,required:t,id:b});case"dropdown":return o("verdocs-field-dropdown",{style:x,options:d,value:c,required:t,id:b,onFieldChange:o=>this.handleFieldChange(e,o)});case"checkbox":return o("verdocs-field-checkbox",{style:x,value:p||"",id:b});case"checkbox_group":return e.settings.options.map(((o,i)=>this.renderCheckboxGroupOption(g,e,o,i)));case"radio_button_group":return e.settings.options.map(((o,i)=>this.renderRadioGroupOption(g,e,o,i)));case"attachment":return o("verdocs-field-attachment",{style:x,value:p||"",id:b});case"payment":return o("verdocs-field-payment",{style:x,field:e,id:b});default:console.log("[SIGN] Skipping unsupported field type",e)}return o("div",{style:{display:"none"}},'Unsupported field type "',e.type,'"')}isFieldValid(e){var o,i,t,s,r,n,a,l,u,h,p,g,x;switch(e.type){case"textbox":switch((null===(o=e.settings)||void 0===o?void 0:o.validator)||""){case"email":return x=(null===(i=e.settings)||void 0===i?void 0:i.result)||"",c.test(x);case"phone":return function(e){return null!==(o=e)&&o.length<16&&o.length>6&&d.test(o)||""===o||null===o;var o}((null===(t=e.settings)||void 0===t?void 0:t.result)||"");default:return!!(null===(s=e.settings)||void 0===s?void 0:s.result)}case"signature":case"initial":case"textarea":case"date":case"attachment":return!!(null===(r=e.settings)||void 0===r?void 0:r.result);case"dropdown":return!!(null===(n=e.settings)||void 0===n?void 0:n.value);case"checkbox_group":const b=((null===(l=null===(a=e.settings)||void 0===a?void 0:a.options)||void 0===l?void 0:l.filter((e=>e.checked)))||[]).length;return b>=((null===(u=e.settings)||void 0===u?void 0:u.minimum_checked)||0)&&b<=((null===(h=e.settings)||void 0===h?void 0:h.maximum_checked)||999);case"radio_button_group":return((null===(g=null===(p=e.settings)||void 0===p?void 0:p.options)||void 0===g?void 0:g.filter((e=>e.selected)))||[]).length>0;default:return!1}}handleDocumentRendered(e){console.log("[SIGN] Document rendered",e.detail),this.pdfPageInfo=e.detail}handleNext(){const e=this.fields.filter((e=>e.required));console.log("required Fields",e);const o=e.findIndex((e=>e.name===this.focusedField));console.log("focused Index",o);let i=o+1;i>=e.length&&(i=0);const t=e[i];if(console.log("next required fielod",t),t){const e=document.getElementById(`field-${t.name}`);null==e||e.focusField(),this.focusedField=t.name}}render(){var e,t,s,r,n;return o(i,{class:{storybook:!!(null===window||void 0===window?void 0:window.STORYBOOK_ENV),agreed:null===(e=this.recipient)||void 0===e?void 0:e.agreed}},o("div",{class:"header"},o("div",{class:"intro"},"Please review and act on these documents."),o("div",{class:"toolbar"},o("div",{class:"tools"},o("verdocs-dropdown",{options:[{id:"later",label:"Finish Later"},{id:"claim",label:"Claim the Document",disabled:!0},{id:"decline",label:"Decline to Sign"},{id:"print",label:"Print Without Signing"},{id:"download",label:"Download"}],onOptionSelected:e=>this.handleOptionSelected(e)}),(null===(t=this.recipient)||void 0===t?void 0:t.agreed)?o("div",{style:{flex:"1"}}):o("div",{class:"agree"},o("div",{class:"agree-checkbox"},o("input",{type:"checkbox",value:"None",id:"agree-checkbox-element",name:"agree",onChange:()=>this.handleClickAgree()}),o("label",{htmlFor:"agree-checkbox-element"})),o("span",null,"I agree to use electronic records and signatures.")),o("verdocs-button",{size:"small",label:this.nextButtonLabel,disabled:!(null===(s=this.recipient)||void 0===s?void 0:s.agreed),onClick:()=>this.handleNext()})))),(null===(r=this.recipient)||void 0===r?void 0:r.agreed)?o("div",{style:{display:"none"}}):o("div",{class:"cover"}),o("div",{class:"document"},this.pdfUrl?o("verdocs-view",{source:this.pdfUrl,token:this.signerToken,onDocumentRendered:e=>this.handleDocumentRendered(e)}):o("verdocs-loader",null),((null===(n=this.pdfPageInfo)||void 0===n?void 0:n.pages)||[]).map((e=>{var i;return o("div",{class:"page-controls",style:{height:`${e.height}px`,width:`${e.width}px`,top:`${e.canvasTop}px`,margin:"0 auto"}},(null===(i=this.pdfPageInfo)||void 0===i?void 0:i.numRendered)>0?this.fields.filter((o=>o.page===e.pageNumber)).map(((e,o)=>this.renderField(e,o))):o("div",{style:{display:"none"}},"Waiting for PDF to render..."))}))))}};p.style='verdocs-sign{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif;position:relative;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;min-height:600px;-webkit-box-sizing:border-box;box-sizing:border-box;overflow:hidden}verdocs-sign.storybook{max-height:600px}verdocs-sign div{-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-sign .header{-ms-flex:0 0 115px;flex:0 0 115px;z-index:1000;background-color:#33354c;-webkit-box-shadow:0 4px 4px 0 rgba(0, 0, 0, 0.24), 0 0 4px 0 rgba(0, 0, 0, 0.12);box-shadow:0 4px 4px 0 rgba(0, 0, 0, 0.24), 0 0 4px 0 rgba(0, 0, 0, 0.12);-webkit-transition:all 0.25s;transition:all 0.25s}verdocs-sign .intro{background-color:#ffffff;width:100%;margin:0 auto;padding:20px;max-width:1028px;color:rgba(0, 0, 0, 0.87)}verdocs-sign .toolbar{width:100%;margin:0 auto;padding:0 14px;max-width:1028px;position:relative}verdocs-sign .tools{width:100%;color:#fff;height:56px;padding:4px;display:-ms-flexbox;display:flex;font-size:12px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;background-color:#33354c}verdocs-sign .cover{top:0;left:0;right:0;bottom:0;z-index:999;position:absolute;background:rgba(0, 0, 0, 0.5)}verdocs-sign .document{-ms-flex:1;flex:1;height:100%;position:relative;overflow-y:scroll}verdocs-sign .agree{-ms-flex:1;flex:1;-ms-flex-direction:row;flex-direction:row;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;margin-right:10px}verdocs-sign .agree .intro{display:none}verdocs-sign .agree .header{-ms-flex:0 0 56px;flex:0 0 56px}verdocs-sign .agree .agree-checkbox{background:#ccc;-ms-flex:0 0 20px;flex:0 0 20px;display:-ms-flexbox;display:flex;width:20px;height:20px;border-radius:3px;position:relative;margin:0 10px 0 14px}verdocs-sign .agree .agree-checkbox input[type=checkbox]:checked+label:after{filter:alpha(opacity=100);opacity:1}verdocs-sign .agree .agree-checkbox label{left:2px;top:2px;width:16px;height:16px;cursor:pointer;position:absolute;background:#33354c;-webkit-box-shadow:inset 0 -1px 1px rgba(255, 255, 255, 0.8);box-shadow:inset 0 -1px 1px rgba(255, 255, 255, 0.8)}verdocs-sign .agree .agree-checkbox label .agree-checkbox label:hover::after{filter:alpha(opacity=30);opacity:0.3}verdocs-sign .agree .agree-checkbox label:after{top:2px;left:3px;width:8px;opacity:0;height:5px;content:"";position:absolute;background:transparent;filter:alpha(opacity=0);-webkit-transform:rotate(-45deg);transform:rotate(-45deg);border:2px solid #fcfff4;border-top:none;border-right:none}verdocs-sign .page-controls{position:absolute;left:50%;-webkit-transform:translateX(-50%);transform:translateX(-50%);z-index:500}';export{p as verdocs_sign}
@@ -1 +1 @@
1
- import{r as o,c as s,h as e,H as i}from"./p-2bc58746.js";const t=class{constructor(e){o(this,e),this.closed=s(this,"closed",7),this.heading="",this.message="",this.open=!1,this.cancel=!1}handleClose(o){this.closed.emit(o),this.open=!1}handleDismiss(o){"background-overlay"===o.target.className&&(o.preventDefault(),this.handleClose("cancel"))}render(){return e(i,{style:{display:this.open?"block":"none"}},e("div",{class:"background-overlay",onClick:o=>this.handleDismiss(o)},e("div",{class:"dialog"},e("div",{class:"heading"},this.heading),e("div",{class:"content"},this.message,e("div",{class:"buttons"},this.cancel?e("verdocs-button",{label:"CANCEL",variant:"outline",onPress:()=>this.handleClose("cancel")}):e("div",{style:{display:"none"}}),e("verdocs-button",{label:"OK",onPress:()=>this.handleClose("ok")}))))))}};t.style='verdocs-ok-dialog{font-family:"Barlow", sans-serif;-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-ok-dialog .background-overlay{position:absolute;z-index:10000;top:0;left:0;right:0;bottom:0;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;background:#0000007f}verdocs-ok-dialog .dialog{max-width:50%;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;border-radius:4px;overflow:hidden;-webkit-box-shadow:3px 3px 5px 1px rgba(40, 40, 40, 0.4);box-shadow:3px 3px 5px 1px rgba(40, 40, 40, 0.4)}verdocs-ok-dialog .heading{display:-ms-flexbox;display:flex;font-size:16px;-ms-flex-direction:row;flex-direction:row;background:#444444;padding:8px 16px;color:#ffffff}verdocs-ok-dialog .content{font-size:14px;background:#ffffff;padding:20px}verdocs-ok-dialog .buttons{display:-ms-flexbox;display:flex;margin:20px 0 0 0;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:center;align-items:center;-ms-flex-pack:end;justify-content:flex-end}verdocs-ok-dialog .buttons verdocs-button{margin-left:16px}';export{t as verdocs_ok_dialog}
1
+ import{r as o,c as s,h as e,H as i}from"./p-2bc58746.js";const t=class{constructor(e){o(this,e),this.closed=s(this,"closed",7),this.heading="",this.message="",this.open=!1,this.cancel=!1}handleClose(o){this.closed.emit(o),this.open=!1}handleDismiss(o){"background-overlay"===o.target.className&&(o.preventDefault(),this.handleClose("cancel"))}render(){return e(i,{style:{display:this.open?"block":"none"}},e("div",{class:"background-overlay",onClick:o=>this.handleDismiss(o)},e("div",{class:"dialog"},e("div",{class:"heading"},this.heading),e("div",{class:"content"},this.message,e("div",{class:"buttons"},this.cancel?e("verdocs-button",{label:"CANCEL",variant:"outline",onPress:()=>this.handleClose("cancel")}):e("div",{style:{display:"none"}}),e("verdocs-button",{label:"OK",onPress:()=>this.handleClose("ok")}))))))}};t.style='verdocs-ok-dialog{font-family:"Barlow", sans-serif;-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-ok-dialog .background-overlay{position:absolute;z-index:10000;top:0;left:0;right:0;bottom:0;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;background:#0000007f}verdocs-ok-dialog .dialog{max-width:50%;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;border-radius:4px;overflow:hidden;-webkit-box-shadow:3px 3px 5px 1px rgba(40, 40, 40, 0.4);box-shadow:3px 3px 5px 1px rgba(40, 40, 40, 0.4)}verdocs-ok-dialog .heading{display:-ms-flexbox;display:flex;font-size:16px;-ms-flex-direction:row;flex-direction:row;background:#444444;padding:8px 16px;color:#ffffff}verdocs-ok-dialog .content{font-size:16px;background:#ffffff;padding:20px}verdocs-ok-dialog .buttons{display:-ms-flexbox;display:flex;margin:20px 0 0 0;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:center;align-items:center;-ms-flex-pack:end;justify-content:flex-end}verdocs-ok-dialog .buttons verdocs-button{margin-left:16px}';export{t as verdocs_ok_dialog}
@@ -0,0 +1,7 @@
1
+ System.register([],(function(e){"use strict";return{execute:function(){e({B:m,d:Dt,e:Bt,f:Lt,i:xt});var t=typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{};var r=[];var n=[];var i=typeof Uint8Array!=="undefined"?Uint8Array:Array;var o=false;function a(){o=true;var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(var t=0,i=e.length;t<i;++t){r[t]=e[t];n[e.charCodeAt(t)]=t}n["-".charCodeAt(0)]=62;n["_".charCodeAt(0)]=63}function s(e){if(!o){a()}var t,r,s,u,f,c;var l=e.length;if(l%4>0){throw new Error("Invalid string. Length must be a multiple of 4")}f=e[l-2]==="="?2:e[l-1]==="="?1:0;c=new i(l*3/4-f);s=f>0?l-4:l;var h=0;for(t=0,r=0;t<s;t+=4,r+=3){u=n[e.charCodeAt(t)]<<18|n[e.charCodeAt(t+1)]<<12|n[e.charCodeAt(t+2)]<<6|n[e.charCodeAt(t+3)];c[h++]=u>>16&255;c[h++]=u>>8&255;c[h++]=u&255}if(f===2){u=n[e.charCodeAt(t)]<<2|n[e.charCodeAt(t+1)]>>4;c[h++]=u&255}else if(f===1){u=n[e.charCodeAt(t)]<<10|n[e.charCodeAt(t+1)]<<4|n[e.charCodeAt(t+2)]>>2;c[h++]=u>>8&255;c[h++]=u&255}return c}function u(e){return r[e>>18&63]+r[e>>12&63]+r[e>>6&63]+r[e&63]}function f(e,t,r){var n;var i=[];for(var o=t;o<r;o+=3){n=(e[o]<<16)+(e[o+1]<<8)+e[o+2];i.push(u(n))}return i.join("")}function c(e){if(!o){a()}var t;var n=e.length;var i=n%3;var s="";var u=[];var c=16383;for(var l=0,h=n-i;l<h;l+=c){u.push(f(e,l,l+c>h?h:l+c))}if(i===1){t=e[n-1];s+=r[t>>2];s+=r[t<<4&63];s+="=="}else if(i===2){t=(e[n-2]<<8)+e[n-1];s+=r[t>>10];s+=r[t>>4&63];s+=r[t<<2&63];s+="="}u.push(s);return u.join("")}function l(e,t,r,n,i){var o,a;var s=i*8-n-1;var u=(1<<s)-1;var f=u>>1;var c=-7;var l=r?i-1:0;var h=r?-1:1;var p=e[t+l];l+=h;o=p&(1<<-c)-1;p>>=-c;c+=s;for(;c>0;o=o*256+e[t+l],l+=h,c-=8){}a=o&(1<<-c)-1;o>>=-c;c+=n;for(;c>0;a=a*256+e[t+l],l+=h,c-=8){}if(o===0){o=1-f}else if(o===u){return a?NaN:(p?-1:1)*Infinity}else{a=a+Math.pow(2,n);o=o-f}return(p?-1:1)*a*Math.pow(2,o-n)}function h(e,t,r,n,i,o){var a,s,u;var f=o*8-i-1;var c=(1<<f)-1;var l=c>>1;var h=i===23?Math.pow(2,-24)-Math.pow(2,-77):0;var p=n?0:o-1;var d=n?1:-1;var v=t<0||t===0&&1/t<0?1:0;t=Math.abs(t);if(isNaN(t)||t===Infinity){s=isNaN(t)?1:0;a=c}else{a=Math.floor(Math.log(t)/Math.LN2);if(t*(u=Math.pow(2,-a))<1){a--;u*=2}if(a+l>=1){t+=h/u}else{t+=h*Math.pow(2,1-l)}if(t*u>=2){a++;u/=2}if(a+l>=c){s=0;a=c}else if(a+l>=1){s=(t*u-1)*Math.pow(2,i);a=a+l}else{s=t*Math.pow(2,l-1)*Math.pow(2,i);a=0}}for(;i>=8;e[r+p]=s&255,p+=d,s/=256,i-=8){}a=a<<i|s;f+=i;for(;f>0;e[r+p]=a&255,p+=d,a/=256,f-=8){}e[r+p-d]|=v*128}var p={}.toString;var d=Array.isArray||function(e){return p.call(e)=="[object Array]"};
2
+ /*!
3
+ * The buffer module from node.js, for the browser.
4
+ *
5
+ * @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org>
6
+ * @license MIT
7
+ */var v=50;m.TYPED_ARRAY_SUPPORT=t.TYPED_ARRAY_SUPPORT!==undefined?t.TYPED_ARRAY_SUPPORT:true;function g(){return m.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function y(e,t){if(g()<t){throw new RangeError("Invalid typed array length")}if(m.TYPED_ARRAY_SUPPORT){e=new Uint8Array(t);e.__proto__=m.prototype}else{if(e===null){e=new m(t)}e.length=t}return e}function m(e,t,r){if(!m.TYPED_ARRAY_SUPPORT&&!(this instanceof m)){return new m(e,t,r)}if(typeof e==="number"){if(typeof t==="string"){throw new Error("If encoding is specified then the first argument must be a string")}return _(this,e)}return E(this,e,t,r)}m.poolSize=8192;m._augment=function(e){e.__proto__=m.prototype;return e};function E(e,t,r,n){if(typeof t==="number"){throw new TypeError('"value" argument must not be a number')}if(typeof ArrayBuffer!=="undefined"&&t instanceof ArrayBuffer){return T(e,t,r,n)}if(typeof t==="string"){return R(e,t,r)}return O(e,t)}m.from=function(e,t,r){return E(null,e,t,r)};if(m.TYPED_ARRAY_SUPPORT){m.prototype.__proto__=Uint8Array.prototype;m.__proto__=Uint8Array}function w(e){if(typeof e!=="number"){throw new TypeError('"size" argument must be a number')}else if(e<0){throw new RangeError('"size" argument must not be negative')}}function b(e,t,r,n){w(t);if(t<=0){return y(e,t)}if(r!==undefined){return typeof n==="string"?y(e,t).fill(r,n):y(e,t).fill(r)}return y(e,t)}m.alloc=function(e,t,r){return b(null,e,t,r)};function _(e,t){w(t);e=y(e,t<0?0:S(t)|0);if(!m.TYPED_ARRAY_SUPPORT){for(var r=0;r<t;++r){e[r]=0}}return e}m.allocUnsafe=function(e){return _(null,e)};m.allocUnsafeSlow=function(e){return _(null,e)};function R(e,t,r){if(typeof r!=="string"||r===""){r="utf8"}if(!m.isEncoding(r)){throw new TypeError('"encoding" must be a valid string encoding')}var n=C(t,r)|0;e=y(e,n);var i=e.write(t,r);if(i!==n){e=e.slice(0,i)}return e}function A(e,t){var r=t.length<0?0:S(t.length)|0;e=y(e,r);for(var n=0;n<r;n+=1){e[n]=t[n]&255}return e}function T(e,t,r,n){if(r<0||t.byteLength<r){throw new RangeError("'offset' is out of bounds")}if(t.byteLength<r+(n||0)){throw new RangeError("'length' is out of bounds")}if(r===undefined&&n===undefined){t=new Uint8Array(t)}else if(n===undefined){t=new Uint8Array(t,r)}else{t=new Uint8Array(t,r,n)}if(m.TYPED_ARRAY_SUPPORT){e=t;e.__proto__=m.prototype}else{e=A(e,t)}return e}function O(e,t){if(P(t)){var r=S(t.length)|0;e=y(e,r);if(e.length===0){return e}t.copy(e,0,0,r);return e}if(t){if(typeof ArrayBuffer!=="undefined"&&t.buffer instanceof ArrayBuffer||"length"in t){if(typeof t.length!=="number"||ce(t.length)){return y(e,0)}return A(e,t)}if(t.type==="Buffer"&&d(t.data)){return A(e,t.data)}}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}function S(e){if(e>=g()){throw new RangeError("Attempt to allocate Buffer larger than maximum "+"size: 0x"+g().toString(16)+" bytes")}return e|0}m.isBuffer=le;function P(e){return!!(e!=null&&e._isBuffer)}m.compare=function e(t,r){if(!P(t)||!P(r)){throw new TypeError("Arguments must be Buffers")}if(t===r)return 0;var n=t.length;var i=r.length;for(var o=0,a=Math.min(n,i);o<a;++o){if(t[o]!==r[o]){n=t[o];i=r[o];break}}if(n<i)return-1;if(i<n)return 1;return 0};m.isEncoding=function e(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return true;default:return false}};m.concat=function e(t,r){if(!d(t)){throw new TypeError('"list" argument must be an Array of Buffers')}if(t.length===0){return m.alloc(0)}var n;if(r===undefined){r=0;for(n=0;n<t.length;++n){r+=t[n].length}}var i=m.allocUnsafe(r);var o=0;for(n=0;n<t.length;++n){var a=t[n];if(!P(a)){throw new TypeError('"list" argument must be an Array of Buffers')}a.copy(i,o);o+=a.length}return i};function C(e,t){if(P(e)){return e.length}if(typeof ArrayBuffer!=="undefined"&&typeof ArrayBuffer.isView==="function"&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer)){return e.byteLength}if(typeof e!=="string"){e=""+e}var r=e.length;if(r===0)return 0;var n=false;for(;;){switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case undefined:return oe(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return r*2;case"hex":return r>>>1;case"base64":return ue(e).length;default:if(n)return oe(e).length;t=(""+t).toLowerCase();n=true}}}m.byteLength=C;function U(e,t,r){var n=false;if(t===undefined||t<0){t=0}if(t>this.length){return""}if(r===undefined||r>this.length){r=this.length}if(r<=0){return""}r>>>=0;t>>>=0;if(r<=t){return""}if(!e)e="utf8";while(true){switch(e){case"hex":return W(this,t,r);case"utf8":case"utf-8":return F(this,t,r);case"ascii":return V(this,t,r);case"latin1":case"binary":return J(this,t,r);case"base64":return Y(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return H(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase();n=true}}}m.prototype._isBuffer=true;function I(e,t,r){var n=e[t];e[t]=e[r];e[r]=n}m.prototype.swap16=function e(){var t=this.length;if(t%2!==0){throw new RangeError("Buffer size must be a multiple of 16-bits")}for(var r=0;r<t;r+=2){I(this,r,r+1)}return this};m.prototype.swap32=function e(){var t=this.length;if(t%4!==0){throw new RangeError("Buffer size must be a multiple of 32-bits")}for(var r=0;r<t;r+=4){I(this,r,r+3);I(this,r+1,r+2)}return this};m.prototype.swap64=function e(){var t=this.length;if(t%8!==0){throw new RangeError("Buffer size must be a multiple of 64-bits")}for(var r=0;r<t;r+=8){I(this,r,r+7);I(this,r+1,r+6);I(this,r+2,r+5);I(this,r+3,r+4)}return this};m.prototype.toString=function e(){var t=this.length|0;if(t===0)return"";if(arguments.length===0)return F(this,0,t);return U.apply(this,arguments)};m.prototype.equals=function e(t){if(!P(t))throw new TypeError("Argument must be a Buffer");if(this===t)return true;return m.compare(this,t)===0};m.prototype.inspect=function e(){var t="";var r=v;if(this.length>0){t=this.toString("hex",0,r).match(/.{2}/g).join(" ");if(this.length>r)t+=" ... "}return"<Buffer "+t+">"};m.prototype.compare=function e(t,r,n,i,o){if(!P(t)){throw new TypeError("Argument must be a Buffer")}if(r===undefined){r=0}if(n===undefined){n=t?t.length:0}if(i===undefined){i=0}if(o===undefined){o=this.length}if(r<0||n>t.length||i<0||o>this.length){throw new RangeError("out of range index")}if(i>=o&&r>=n){return 0}if(i>=o){return-1}if(r>=n){return 1}r>>>=0;n>>>=0;i>>>=0;o>>>=0;if(this===t)return 0;var a=o-i;var s=n-r;var u=Math.min(a,s);var f=this.slice(i,o);var c=t.slice(r,n);for(var l=0;l<u;++l){if(f[l]!==c[l]){a=f[l];s=c[l];break}}if(a<s)return-1;if(s<a)return 1;return 0};function L(e,t,r,n,i){if(e.length===0)return-1;if(typeof r==="string"){n=r;r=0}else if(r>2147483647){r=2147483647}else if(r<-2147483648){r=-2147483648}r=+r;if(isNaN(r)){r=i?0:e.length-1}if(r<0)r=e.length+r;if(r>=e.length){if(i)return-1;else r=e.length-1}else if(r<0){if(i)r=0;else return-1}if(typeof t==="string"){t=m.from(t,n)}if(P(t)){if(t.length===0){return-1}return B(e,t,r,n,i)}else if(typeof t==="number"){t=t&255;if(m.TYPED_ARRAY_SUPPORT&&typeof Uint8Array.prototype.indexOf==="function"){if(i){return Uint8Array.prototype.indexOf.call(e,t,r)}else{return Uint8Array.prototype.lastIndexOf.call(e,t,r)}}return B(e,[t],r,n,i)}throw new TypeError("val must be string, number or Buffer")}function B(e,t,r,n,i){var o=1;var a=e.length;var s=t.length;if(n!==undefined){n=String(n).toLowerCase();if(n==="ucs2"||n==="ucs-2"||n==="utf16le"||n==="utf-16le"){if(e.length<2||t.length<2){return-1}o=2;a/=2;s/=2;r/=2}}function u(e,t){if(o===1){return e[t]}else{return e.readUInt16BE(t*o)}}var f;if(i){var c=-1;for(f=r;f<a;f++){if(u(e,f)===u(t,c===-1?0:f-c)){if(c===-1)c=f;if(f-c+1===s)return c*o}else{if(c!==-1)f-=f-c;c=-1}}}else{if(r+s>a)r=a-s;for(f=r;f>=0;f--){var l=true;for(var h=0;h<s;h++){if(u(e,f+h)!==u(t,h)){l=false;break}}if(l)return f}}return-1}m.prototype.includes=function e(t,r,n){return this.indexOf(t,r,n)!==-1};m.prototype.indexOf=function e(t,r,n){return L(this,t,r,n,true)};m.prototype.lastIndexOf=function e(t,r,n){return L(this,t,r,n,false)};function D(e,t,r,n){r=Number(r)||0;var i=e.length-r;if(!n){n=i}else{n=Number(n);if(n>i){n=i}}var o=t.length;if(o%2!==0)throw new TypeError("Invalid hex string");if(n>o/2){n=o/2}for(var a=0;a<n;++a){var s=parseInt(t.substr(a*2,2),16);if(isNaN(s))return a;e[r+a]=s}return a}function x(e,t,r,n){return fe(oe(t,e.length-r),e,r,n)}function N(e,t,r,n){return fe(ae(t),e,r,n)}function j(e,t,r,n){return N(e,t,r,n)}function M(e,t,r,n){return fe(ue(t),e,r,n)}function k(e,t,r,n){return fe(se(t,e.length-r),e,r,n)}m.prototype.write=function e(t,r,n,i){if(r===undefined){i="utf8";n=this.length;r=0}else if(n===undefined&&typeof r==="string"){i=r;n=this.length;r=0}else if(isFinite(r)){r=r|0;if(isFinite(n)){n=n|0;if(i===undefined)i="utf8"}else{i=n;n=undefined}}else{throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported")}var o=this.length-r;if(n===undefined||n>o)n=o;if(t.length>0&&(n<0||r<0)||r>this.length){throw new RangeError("Attempt to write outside buffer bounds")}if(!i)i="utf8";var a=false;for(;;){switch(i){case"hex":return D(this,t,r,n);case"utf8":case"utf-8":return x(this,t,r,n);case"ascii":return N(this,t,r,n);case"latin1":case"binary":return j(this,t,r,n);case"base64":return M(this,t,r,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return k(this,t,r,n);default:if(a)throw new TypeError("Unknown encoding: "+i);i=(""+i).toLowerCase();a=true}}};m.prototype.toJSON=function e(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function Y(e,t,r){if(t===0&&r===e.length){return c(e)}else{return c(e.slice(t,r))}}function F(e,t,r){r=Math.min(e.length,r);var n=[];var i=t;while(i<r){var o=e[i];var a=null;var s=o>239?4:o>223?3:o>191?2:1;if(i+s<=r){var u,f,c,l;switch(s){case 1:if(o<128){a=o}break;case 2:u=e[i+1];if((u&192)===128){l=(o&31)<<6|u&63;if(l>127){a=l}}break;case 3:u=e[i+1];f=e[i+2];if((u&192)===128&&(f&192)===128){l=(o&15)<<12|(u&63)<<6|f&63;if(l>2047&&(l<55296||l>57343)){a=l}}break;case 4:u=e[i+1];f=e[i+2];c=e[i+3];if((u&192)===128&&(f&192)===128&&(c&192)===128){l=(o&15)<<18|(u&63)<<12|(f&63)<<6|c&63;if(l>65535&&l<1114112){a=l}}}}if(a===null){a=65533;s=1}else if(a>65535){a-=65536;n.push(a>>>10&1023|55296);a=56320|a&1023}n.push(a);i+=s}return z(n)}var q=4096;function z(e){var t=e.length;if(t<=q){return String.fromCharCode.apply(String,e)}var r="";var n=0;while(n<t){r+=String.fromCharCode.apply(String,e.slice(n,n+=q))}return r}function V(e,t,r){var n="";r=Math.min(e.length,r);for(var i=t;i<r;++i){n+=String.fromCharCode(e[i]&127)}return n}function J(e,t,r){var n="";r=Math.min(e.length,r);for(var i=t;i<r;++i){n+=String.fromCharCode(e[i])}return n}function W(e,t,r){var n=e.length;if(!t||t<0)t=0;if(!r||r<0||r>n)r=n;var i="";for(var o=t;o<r;++o){i+=ie(e[o])}return i}function H(e,t,r){var n=e.slice(t,r);var i="";for(var o=0;o<n.length;o+=2){i+=String.fromCharCode(n[o]+n[o+1]*256)}return i}m.prototype.slice=function e(t,r){var n=this.length;t=~~t;r=r===undefined?n:~~r;if(t<0){t+=n;if(t<0)t=0}else if(t>n){t=n}if(r<0){r+=n;if(r<0)r=0}else if(r>n){r=n}if(r<t)r=t;var i;if(m.TYPED_ARRAY_SUPPORT){i=this.subarray(t,r);i.__proto__=m.prototype}else{var o=r-t;i=new m(o,undefined);for(var a=0;a<o;++a){i[a]=this[a+t]}}return i};function G(e,t,r){if(e%1!==0||e<0)throw new RangeError("offset is not uint");if(e+t>r)throw new RangeError("Trying to access beyond buffer length")}m.prototype.readUIntLE=function e(t,r,n){t=t|0;r=r|0;if(!n)G(t,r,this.length);var i=this[t];var o=1;var a=0;while(++a<r&&(o*=256)){i+=this[t+a]*o}return i};m.prototype.readUIntBE=function e(t,r,n){t=t|0;r=r|0;if(!n){G(t,r,this.length)}var i=this[t+--r];var o=1;while(r>0&&(o*=256)){i+=this[t+--r]*o}return i};m.prototype.readUInt8=function e(t,r){if(!r)G(t,1,this.length);return this[t]};m.prototype.readUInt16LE=function e(t,r){if(!r)G(t,2,this.length);return this[t]|this[t+1]<<8};m.prototype.readUInt16BE=function e(t,r){if(!r)G(t,2,this.length);return this[t]<<8|this[t+1]};m.prototype.readUInt32LE=function e(t,r){if(!r)G(t,4,this.length);return(this[t]|this[t+1]<<8|this[t+2]<<16)+this[t+3]*16777216};m.prototype.readUInt32BE=function e(t,r){if(!r)G(t,4,this.length);return this[t]*16777216+(this[t+1]<<16|this[t+2]<<8|this[t+3])};m.prototype.readIntLE=function e(t,r,n){t=t|0;r=r|0;if(!n)G(t,r,this.length);var i=this[t];var o=1;var a=0;while(++a<r&&(o*=256)){i+=this[t+a]*o}o*=128;if(i>=o)i-=Math.pow(2,8*r);return i};m.prototype.readIntBE=function e(t,r,n){t=t|0;r=r|0;if(!n)G(t,r,this.length);var i=r;var o=1;var a=this[t+--i];while(i>0&&(o*=256)){a+=this[t+--i]*o}o*=128;if(a>=o)a-=Math.pow(2,8*r);return a};m.prototype.readInt8=function e(t,r){if(!r)G(t,1,this.length);if(!(this[t]&128))return this[t];return(255-this[t]+1)*-1};m.prototype.readInt16LE=function e(t,r){if(!r)G(t,2,this.length);var n=this[t]|this[t+1]<<8;return n&32768?n|4294901760:n};m.prototype.readInt16BE=function e(t,r){if(!r)G(t,2,this.length);var n=this[t+1]|this[t]<<8;return n&32768?n|4294901760:n};m.prototype.readInt32LE=function e(t,r){if(!r)G(t,4,this.length);return this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24};m.prototype.readInt32BE=function e(t,r){if(!r)G(t,4,this.length);return this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]};m.prototype.readFloatLE=function e(t,r){if(!r)G(t,4,this.length);return l(this,t,true,23,4)};m.prototype.readFloatBE=function e(t,r){if(!r)G(t,4,this.length);return l(this,t,false,23,4)};m.prototype.readDoubleLE=function e(t,r){if(!r)G(t,8,this.length);return l(this,t,true,52,8)};m.prototype.readDoubleBE=function e(t,r){if(!r)G(t,8,this.length);return l(this,t,false,52,8)};function K(e,t,r,n,i,o){if(!P(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||t<o)throw new RangeError('"value" argument is out of bounds');if(r+n>e.length)throw new RangeError("Index out of range")}m.prototype.writeUIntLE=function e(t,r,n,i){t=+t;r=r|0;n=n|0;if(!i){var o=Math.pow(2,8*n)-1;K(this,t,r,n,o,0)}var a=1;var s=0;this[r]=t&255;while(++s<n&&(a*=256)){this[r+s]=t/a&255}return r+n};m.prototype.writeUIntBE=function e(t,r,n,i){t=+t;r=r|0;n=n|0;if(!i){var o=Math.pow(2,8*n)-1;K(this,t,r,n,o,0)}var a=n-1;var s=1;this[r+a]=t&255;while(--a>=0&&(s*=256)){this[r+a]=t/s&255}return r+n};m.prototype.writeUInt8=function e(t,r,n){t=+t;r=r|0;if(!n)K(this,t,r,1,255,0);if(!m.TYPED_ARRAY_SUPPORT)t=Math.floor(t);this[r]=t&255;return r+1};function X(e,t,r,n){if(t<0)t=65535+t+1;for(var i=0,o=Math.min(e.length-r,2);i<o;++i){e[r+i]=(t&255<<8*(n?i:1-i))>>>(n?i:1-i)*8}}m.prototype.writeUInt16LE=function e(t,r,n){t=+t;r=r|0;if(!n)K(this,t,r,2,65535,0);if(m.TYPED_ARRAY_SUPPORT){this[r]=t&255;this[r+1]=t>>>8}else{X(this,t,r,true)}return r+2};m.prototype.writeUInt16BE=function e(t,r,n){t=+t;r=r|0;if(!n)K(this,t,r,2,65535,0);if(m.TYPED_ARRAY_SUPPORT){this[r]=t>>>8;this[r+1]=t&255}else{X(this,t,r,false)}return r+2};function Z(e,t,r,n){if(t<0)t=4294967295+t+1;for(var i=0,o=Math.min(e.length-r,4);i<o;++i){e[r+i]=t>>>(n?i:3-i)*8&255}}m.prototype.writeUInt32LE=function e(t,r,n){t=+t;r=r|0;if(!n)K(this,t,r,4,4294967295,0);if(m.TYPED_ARRAY_SUPPORT){this[r+3]=t>>>24;this[r+2]=t>>>16;this[r+1]=t>>>8;this[r]=t&255}else{Z(this,t,r,true)}return r+4};m.prototype.writeUInt32BE=function e(t,r,n){t=+t;r=r|0;if(!n)K(this,t,r,4,4294967295,0);if(m.TYPED_ARRAY_SUPPORT){this[r]=t>>>24;this[r+1]=t>>>16;this[r+2]=t>>>8;this[r+3]=t&255}else{Z(this,t,r,false)}return r+4};m.prototype.writeIntLE=function e(t,r,n,i){t=+t;r=r|0;if(!i){var o=Math.pow(2,8*n-1);K(this,t,r,n,o-1,-o)}var a=0;var s=1;var u=0;this[r]=t&255;while(++a<n&&(s*=256)){if(t<0&&u===0&&this[r+a-1]!==0){u=1}this[r+a]=(t/s>>0)-u&255}return r+n};m.prototype.writeIntBE=function e(t,r,n,i){t=+t;r=r|0;if(!i){var o=Math.pow(2,8*n-1);K(this,t,r,n,o-1,-o)}var a=n-1;var s=1;var u=0;this[r+a]=t&255;while(--a>=0&&(s*=256)){if(t<0&&u===0&&this[r+a+1]!==0){u=1}this[r+a]=(t/s>>0)-u&255}return r+n};m.prototype.writeInt8=function e(t,r,n){t=+t;r=r|0;if(!n)K(this,t,r,1,127,-128);if(!m.TYPED_ARRAY_SUPPORT)t=Math.floor(t);if(t<0)t=255+t+1;this[r]=t&255;return r+1};m.prototype.writeInt16LE=function e(t,r,n){t=+t;r=r|0;if(!n)K(this,t,r,2,32767,-32768);if(m.TYPED_ARRAY_SUPPORT){this[r]=t&255;this[r+1]=t>>>8}else{X(this,t,r,true)}return r+2};m.prototype.writeInt16BE=function e(t,r,n){t=+t;r=r|0;if(!n)K(this,t,r,2,32767,-32768);if(m.TYPED_ARRAY_SUPPORT){this[r]=t>>>8;this[r+1]=t&255}else{X(this,t,r,false)}return r+2};m.prototype.writeInt32LE=function e(t,r,n){t=+t;r=r|0;if(!n)K(this,t,r,4,2147483647,-2147483648);if(m.TYPED_ARRAY_SUPPORT){this[r]=t&255;this[r+1]=t>>>8;this[r+2]=t>>>16;this[r+3]=t>>>24}else{Z(this,t,r,true)}return r+4};m.prototype.writeInt32BE=function e(t,r,n){t=+t;r=r|0;if(!n)K(this,t,r,4,2147483647,-2147483648);if(t<0)t=4294967295+t+1;if(m.TYPED_ARRAY_SUPPORT){this[r]=t>>>24;this[r+1]=t>>>16;this[r+2]=t>>>8;this[r+3]=t&255}else{Z(this,t,r,false)}return r+4};function $(e,t,r,n,i,o){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function Q(e,t,r,n,i){if(!i){$(e,t,r,4)}h(e,t,r,n,23,4);return r+4}m.prototype.writeFloatLE=function e(t,r,n){return Q(this,t,r,true,n)};m.prototype.writeFloatBE=function e(t,r,n){return Q(this,t,r,false,n)};function ee(e,t,r,n,i){if(!i){$(e,t,r,8)}h(e,t,r,n,52,8);return r+8}m.prototype.writeDoubleLE=function e(t,r,n){return ee(this,t,r,true,n)};m.prototype.writeDoubleBE=function e(t,r,n){return ee(this,t,r,false,n)};m.prototype.copy=function e(t,r,n,i){if(!n)n=0;if(!i&&i!==0)i=this.length;if(r>=t.length)r=t.length;if(!r)r=0;if(i>0&&i<n)i=n;if(i===n)return 0;if(t.length===0||this.length===0)return 0;if(r<0){throw new RangeError("targetStart out of bounds")}if(n<0||n>=this.length)throw new RangeError("sourceStart out of bounds");if(i<0)throw new RangeError("sourceEnd out of bounds");if(i>this.length)i=this.length;if(t.length-r<i-n){i=t.length-r+n}var o=i-n;var a;if(this===t&&n<r&&r<i){for(a=o-1;a>=0;--a){t[a+r]=this[a+n]}}else if(o<1e3||!m.TYPED_ARRAY_SUPPORT){for(a=0;a<o;++a){t[a+r]=this[a+n]}}else{Uint8Array.prototype.set.call(t,this.subarray(n,n+o),r)}return o};m.prototype.fill=function e(t,r,n,i){if(typeof t==="string"){if(typeof r==="string"){i=r;r=0;n=this.length}else if(typeof n==="string"){i=n;n=this.length}if(t.length===1){var o=t.charCodeAt(0);if(o<256){t=o}}if(i!==undefined&&typeof i!=="string"){throw new TypeError("encoding must be a string")}if(typeof i==="string"&&!m.isEncoding(i)){throw new TypeError("Unknown encoding: "+i)}}else if(typeof t==="number"){t=t&255}if(r<0||this.length<r||this.length<n){throw new RangeError("Out of range index")}if(n<=r){return this}r=r>>>0;n=n===undefined?this.length:n>>>0;if(!t)t=0;var a;if(typeof t==="number"){for(a=r;a<n;++a){this[a]=t}}else{var s=P(t)?t:oe(new m(t,i).toString());var u=s.length;for(a=0;a<n-r;++a){this[a+r]=s[a%u]}}return this};var te=/[^+\/0-9A-Za-z-_]/g;function re(e){e=ne(e).replace(te,"");if(e.length<2)return"";while(e.length%4!==0){e=e+"="}return e}function ne(e){if(e.trim)return e.trim();return e.replace(/^\s+|\s+$/g,"")}function ie(e){if(e<16)return"0"+e.toString(16);return e.toString(16)}function oe(e,t){t=t||Infinity;var r;var n=e.length;var i=null;var o=[];for(var a=0;a<n;++a){r=e.charCodeAt(a);if(r>55295&&r<57344){if(!i){if(r>56319){if((t-=3)>-1)o.push(239,191,189);continue}else if(a+1===n){if((t-=3)>-1)o.push(239,191,189);continue}i=r;continue}if(r<56320){if((t-=3)>-1)o.push(239,191,189);i=r;continue}r=(i-55296<<10|r-56320)+65536}else if(i){if((t-=3)>-1)o.push(239,191,189)}i=null;if(r<128){if((t-=1)<0)break;o.push(r)}else if(r<2048){if((t-=2)<0)break;o.push(r>>6|192,r&63|128)}else if(r<65536){if((t-=3)<0)break;o.push(r>>12|224,r>>6&63|128,r&63|128)}else if(r<1114112){if((t-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,r&63|128)}else{throw new Error("Invalid code point")}}return o}function ae(e){var t=[];for(var r=0;r<e.length;++r){t.push(e.charCodeAt(r)&255)}return t}function se(e,t){var r,n,i;var o=[];for(var a=0;a<e.length;++a){if((t-=2)<0)break;r=e.charCodeAt(a);n=r>>8;i=r%256;o.push(i);o.push(n)}return o}function ue(e){return s(re(e))}function fe(e,t,r,n){for(var i=0;i<n;++i){if(i+r>=t.length||i>=e.length)break;t[i+r]=e[i]}return i}function ce(e){return e!==e}function le(e){return e!=null&&(!!e._isBuffer||he(e)||pe(e))}function he(e){return!!e.constructor&&typeof e.constructor.isBuffer==="function"&&e.constructor.isBuffer(e)}function pe(e){return typeof e.readFloatLE==="function"&&typeof e.slice==="function"&&he(e.slice(0,0))}var de="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";var ve=/^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/;var ge=function(e){e=String(e).replace(/[\t\n\f\r ]+/g,"");if(!ve.test(e))throw new TypeError("Failed to execute 'atob' on 'Window': The string to be decoded is not correctly encoded.");e+="==".slice(2-(e.length&3));var t;var r="";var n;var i;var o=0;for(;o<e.length;){t=de.indexOf(e.charAt(o++))<<18|de.indexOf(e.charAt(o++))<<12|(n=de.indexOf(e.charAt(o++)))<<6|(i=de.indexOf(e.charAt(o++)));r+=n===64?String.fromCharCode(t>>16&255):i===64?String.fromCharCode(t>>16&255,t>>8&255):String.fromCharCode(t>>16&255,t>>8&255,t&255)}return r};var ye=function(e){return JSON.parse(ge((e||"").split(".")[1]||""))};var me=function(e){var t;try{t=ye(e);if(t===null){return null}}catch(e){return null}Object.keys(t).forEach((function(e){if(typeof e==="string"&&e.startsWith("https://verdocs.com/")){t[e.replace("https://verdocs.com/","")]=t[e];delete t[e]}}));return t};var Ee=undefined&&undefined.__awaiter||function(e,t,r,n){function i(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n["throw"](e))}catch(e){o(e)}}function u(e){e.done?r(e.value):i(e.value).then(a,s)}u((n=n.apply(e,t||[])).next())}))};var we=undefined&&undefined.__generator||function(e,t){var r={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},n,i,o,a;return a={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(a[Symbol.iterator]=function(){return this}),a;function s(e){return function(t){return u([e,t])}}function u(a){if(n)throw new TypeError("Generator is already executing.");while(r)try{if(n=1,i&&(o=a[0]&2?i["return"]:a[0]?i["throw"]||((o=i["return"])&&o.call(i),0):i.next)&&!(o=o.call(i,a[1])).done)return o;if(i=0,o)a=[a[0]&2,o.value];switch(a[0]){case 0:case 1:o=a;break;case 4:r.label++;return{value:a[1],done:false};case 5:r.label++;i=a[1];a=[0];continue;case 7:a=r.ops.pop();r.trys.pop();continue;default:if(!(o=r.trys,o=o.length>0&&o[o.length-1])&&(a[0]===6||a[0]===2)){r=0;continue}if(a[0]===3&&(!o||a[1]>o[0]&&a[1]<o[3])){r.label=a[1];break}if(a[0]===6&&r.label<o[1]){r.label=o[1];o=a;break}if(o&&r.label<o[2]){r.label=o[2];r.ops.push(a);break}if(o[2])r.ops.pop();r.trys.pop();continue}a=t.call(e,r)}catch(e){a=[6,e];i=0}finally{n=o=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:true}}};var be=function(e,t){return Ee(void 0,void 0,void 0,(function(){return we(this,(function(r){return[2,e.api.post("/documents/summary",{page:t}).then((function(e){return e.data}))]}))}))};var _e=function(e,t){return Ee(void 0,void 0,void 0,(function(){return we(this,(function(r){return[2,e.api.post("/documents/search",t).then((function(e){return e.data}))]}))}))};var Re=e("g",(function(e,t){return Ee(void 0,void 0,void 0,(function(){return we(this,(function(r){return[2,e.api.get("/documents/".concat(t.documentId,"/recipients/").concat(encodeURIComponent(t.roleId),"/invitation/").concat(t.inviteCode)).then((function(t){var r,n;var i=((r=t.headers)===null||r===void 0?void 0:r.signer_token)||"";var o=me(i);e.setToken((n=t.headers)===null||n===void 0?void 0:n.signer_token);return{recipient:t.data,session:o,signerToken:i}}))]}))}))}));var Ae=function(e,t){return Ee(void 0,void 0,void 0,(function(){return we(this,(function(r){return[2,e.api.get("/documents/".concat(t,"/recipients")).then((function(e){return e.data}))]}))}))};var Te=e("a",(function(e,t){return Ee(void 0,void 0,void 0,(function(){return we(this,(function(r){return[2,e.api.get("/documents/".concat(t)).then((function(e){return e.data}))]}))}))}));var Oe=e("b",(function(e,t,r){return Ee(void 0,void 0,void 0,(function(){return we(this,(function(n){return[2,e.api.get("/documents/".concat(t,"/envelope_documents/").concat(r,"?file=true"),{responseType:"arraybuffer"}).then((function(e){return m.from(e.data,"binary").toString("base64")}))]}))}))}));var Se=e("c",(function(e,t,r,n){return Ee(void 0,void 0,void 0,(function(){return we(this,(function(i){return[2,e.api.put("/documents/".concat(t,"/fields/").concat(r),n).then((function(e){return e.data}))]}))}))}));var Pe=function(e,t,r,n){return Ee(void 0,void 0,void 0,(function(){return we(this,(function(i){return[2,e.api.put("/documents/".concat(t,"/fields/").concat(r,"/signature/").concat(n)).then((function(e){return e.data}))]}))}))};var Ce=Object.freeze({__proto__:null,getSummary:be,searchDocuments:_e,getSigningSession:Re,getDocumentRecipients:Ae,getDocument:Te,getDocumentFile:Oe,updateDocumentField:Se,updateDocumentFieldSignature:Pe});var Ue=undefined&&undefined.__assign||function(){Ue=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++){t=arguments[r];for(var i in t)if(Object.prototype.hasOwnProperty.call(t,i))e[i]=t[i]}return e};return Ue.apply(this,arguments)};var Ie=undefined&&undefined.__awaiter||function(e,t,r,n){function i(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,o){function a(e){try{u(n.next(e))}catch(e){o(e)}}function s(e){try{u(n["throw"](e))}catch(e){o(e)}}function u(e){e.done?r(e.value):i(e.value).then(a,s)}u((n=n.apply(e,t||[])).next())}))};var Le=undefined&&undefined.__generator||function(e,t){var r={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},n,i,o,a;return a={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(a[Symbol.iterator]=function(){return this}),a;function s(e){return function(t){return u([e,t])}}function u(a){if(n)throw new TypeError("Generator is already executing.");while(r)try{if(n=1,i&&(o=a[0]&2?i["return"]:a[0]?i["throw"]||((o=i["return"])&&o.call(i),0):i.next)&&!(o=o.call(i,a[1])).done)return o;if(i=0,o)a=[a[0]&2,o.value];switch(a[0]){case 0:case 1:o=a;break;case 4:r.label++;return{value:a[1],done:false};case 5:r.label++;i=a[1];a=[0];continue;case 7:a=r.ops.pop();r.trys.pop();continue;default:if(!(o=r.trys,o=o.length>0&&o[o.length-1])&&(a[0]===6||a[0]===2)){r=0;continue}if(a[0]===3&&(!o||a[1]>o[0]&&a[1]<o[3])){r.label=a[1];break}if(a[0]===6&&r.label<o[1]){r.label=o[1];o=a;break}if(o&&r.label<o[2]){r.label=o[2];r.ops.push(a);break}if(o[2])r.ops.pop();r.trys.pop();continue}a=t.call(e,r)}catch(e){a=[6,e];i=0}finally{n=o=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:true}}};var Be=e("u",(function(e,t,r,n,i){return Ie(void 0,void 0,void 0,(function(){return Le(this,(function(o){return[2,e.api.put("/documents/".concat(t,"/recipients/").concat(r),Ue({role_name:r,action:n},i||{})).then((function(e){return e.data}))]}))}))}));var De=Object.freeze({__proto__:null,updateRecipientStatus:Be});var xe=function(e,t,r){var n=new FormData;n.append("signature",r,t);return e.api.post("/signatures",n).then((function(e){return e.data}))};var Ne=function(e){return e.api.get("/signatures").then((function(e){return e.data}))};var je=function(e,t){return e.api.get("/signatures/".concat(t)).then((function(e){return e.data}))};var Me=function(e,t){return e.api.delete("/signatures/".concat(t)).then((function(e){return e.data}))};var ke=Object.freeze({__proto__:null,createSignature:xe,getSignatures:Ne,getSignature:je,deleteSignature:Me});var Ye=function(e,t,r){var n=new FormData;n.append("initial",r,t);return e.api.post("/initials",n).then((function(e){return e.data}))};var Fe=Object.freeze({__proto__:null,createInitials:Ye});var qe=Object.freeze({__proto__:null});var ze=Object.freeze({__proto__:null,Documents:Ce,Recipients:De,Signatures:ke,Initials:Fe,Types:qe});var Ve;(function(e){e["TEMPLATE_CREATOR_CREATE_PUBLIC"]="template:creator:create:public";e["TEMPLATE_CREATOR_CREATE_ORG"]="template:creator:create:org";e["TEMPLATE_CREATOR_CREATE_PERSONAL"]="template:creator:create:personal";e["TEMPLATE_CREATOR_DELETE"]="template:creator:delete";e["TEMPLATE_CREATOR_VISIBILITY"]="template:creator:visibility";e["TEMPLATE_MEMBER_READ"]="template:member:read";e["TEMPLATE_MEMBER_WRITE"]="template:member:write";e["TEMPLATE_MEMBER_DELETE"]="template:member:delete";e["TEMPLATE_MEMBER_VISIBILITY"]="template:member:visibility"})(Ve||(Ve={}));var Je;(function(e){e["CREATOR"]="creator";e["ORGANIZATION_MEMBER"]="organization_member";e["ORGANIZATION_MEMBER_AS_CREATOR"]="organization_member_as_creator";e["EVERYONE"]="everyone";e["EVERYONE_AS_CREATOR"]="everyone_as_creator"})(Je||(Je={}));var We;(function(e){e["CREATE_PERSONAL"]="create_personal";e["CREATE_ORG"]="create_org";e["CREATE_PUBLIC"]="create_public";e["READ"]="read";e["WRITE"]="write";e["DELETE"]="delete";e["CHANGE_VISIBILITY_PERSONAL"]="change_visibility_personal";e["CHANGE_VISIBILITY_ORG"]="change_visibility_org";e["CHANGE_VISIBILITY_PUBLIC"]="change_visibility_public"})(We||(We={}));var He;(function(e){e["CREATED_AT"]="created_at";e["UPDATED_AT"]="updated_at";e["NAME"]="name";e["LAST_USED_AT"]="last_used_at";e["COUNTER"]="counter";e["STAR_COUNTER"]="star_counter"})(He||(He={}));var Ge=function e(t,r){return function e(){var n=new Array(arguments.length);for(var i=0;i<n.length;i++){n[i]=arguments[i]}return t.apply(r,n)}};var Ke=Object.prototype.toString;var Xe=function(e){return function(t){var r=Ke.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())}}(Object.create(null));function Ze(e){e=e.toLowerCase();return function t(r){return Xe(r)===e}}function $e(e){return Array.isArray(e)}function Qe(e){return typeof e==="undefined"}function et(e){return e!==null&&!Qe(e)&&e.constructor!==null&&!Qe(e.constructor)&&typeof e.constructor.isBuffer==="function"&&e.constructor.isBuffer(e)}var tt=Ze("ArrayBuffer");function rt(e){var t;if(typeof ArrayBuffer!=="undefined"&&ArrayBuffer.isView){t=ArrayBuffer.isView(e)}else{t=e&&e.buffer&&tt(e.buffer)}return t}function nt(e){return typeof e==="string"}function it(e){return typeof e==="number"}function ot(e){return e!==null&&typeof e==="object"}function at(e){if(Xe(e)!=="object"){return false}var t=Object.getPrototypeOf(e);return t===null||t===Object.prototype}var st=Ze("Date");var ut=Ze("File");var ft=Ze("Blob");var ct=Ze("FileList");function lt(e){return Ke.call(e)==="[object Function]"}function ht(e){return ot(e)&&lt(e.pipe)}function pt(e){var t="[object FormData]";return e&&(typeof FormData==="function"&&e instanceof FormData||Ke.call(e)===t||lt(e.toString)&&e.toString()===t)}var dt=Ze("URLSearchParams");function vt(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function gt(){if(typeof navigator!=="undefined"&&(navigator.product==="ReactNative"||navigator.product==="NativeScript"||navigator.product==="NS")){return false}return typeof window!=="undefined"&&typeof document!=="undefined"}function yt(e,t){if(e===null||typeof e==="undefined"){return}if(typeof e!=="object"){e=[e]}if($e(e)){for(var r=0,n=e.length;r<n;r++){t.call(null,e[r],r,e)}}else{for(var i in e){if(Object.prototype.hasOwnProperty.call(e,i)){t.call(null,e[i],i,e)}}}}function mt(){var e={};function t(t,r){if(at(e[r])&&at(t)){e[r]=mt(e[r],t)}else if(at(t)){e[r]=mt({},t)}else if($e(t)){e[r]=t.slice()}else{e[r]=t}}for(var r=0,n=arguments.length;r<n;r++){yt(arguments[r],t)}return e}function Et(e,t,r){yt(t,(function t(n,i){if(r&&typeof n==="function"){e[i]=Ge(n,r)}else{e[i]=n}}));return e}function wt(e){if(e.charCodeAt(0)===65279){e=e.slice(1)}return e}function bt(e,t,r,n){e.prototype=Object.create(t.prototype,n);e.prototype.constructor=e;r&&Object.assign(e.prototype,r)}function _t(e,t,r){var n;var i;var o;var a={};t=t||{};do{n=Object.getOwnPropertyNames(e);i=n.length;while(i-- >0){o=n[i];if(!a[o]){t[o]=e[o];a[o]=true}}e=Object.getPrototypeOf(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t}function Rt(e,t,r){e=String(e);if(r===undefined||r>e.length){r=e.length}r-=t.length;var n=e.indexOf(t,r);return n!==-1&&n===r}function At(e){if(!e)return null;var t=e.length;if(Qe(t))return null;var r=new Array(t);while(t-- >0){r[t]=e[t]}return r}var Tt=function(e){return function(t){return e&&t instanceof e}}(typeof Uint8Array!=="undefined"&&Object.getPrototypeOf(Uint8Array));var Ot={isArray:$e,isArrayBuffer:tt,isBuffer:et,isFormData:pt,isArrayBufferView:rt,isString:nt,isNumber:it,isObject:ot,isPlainObject:at,isUndefined:Qe,isDate:st,isFile:ut,isBlob:ft,isFunction:lt,isStream:ht,isURLSearchParams:dt,isStandardBrowserEnv:gt,forEach:yt,merge:mt,extend:Et,trim:vt,stripBOM:wt,inherits:bt,toFlatObject:_t,kindOf:Xe,kindOfTest:Ze,endsWith:Rt,toArray:At,isTypedArray:Tt,isFileList:ct};function St(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}var Pt=function e(t,r,n){if(!r){return t}var i;if(n){i=n(r)}else if(Ot.isURLSearchParams(r)){i=r.toString()}else{var o=[];Ot.forEach(r,(function e(t,r){if(t===null||typeof t==="undefined"){return}if(Ot.isArray(t)){r=r+"[]"}else{t=[t]}Ot.forEach(t,(function e(t){if(Ot.isDate(t)){t=t.toISOString()}else if(Ot.isObject(t)){t=JSON.stringify(t)}o.push(St(r)+"="+St(t))}))}));i=o.join("&")}if(i){var a=t.indexOf("#");if(a!==-1){t=t.slice(0,a)}t+=(t.indexOf("?")===-1?"?":"&")+i}return t};function Ct(){this.handlers=[]}Ct.prototype.use=function e(t,r,n){this.handlers.push({fulfilled:t,rejected:r,synchronous:n?n.synchronous:false,runWhen:n?n.runWhen:null});return this.handlers.length-1};Ct.prototype.eject=function e(t){if(this.handlers[t]){this.handlers[t]=null}};Ct.prototype.forEach=function e(t){Ot.forEach(this.handlers,(function e(r){if(r!==null){t(r)}}))};var Ut=Ct;var It=e("h",typeof globalThis!=="undefined"?globalThis:typeof window!=="undefined"?window:typeof global!=="undefined"?global:typeof self!=="undefined"?self:{});function Lt(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e["default"]:e}function Bt(e,t,r){return r={path:t,exports:{},require:function(e,t){return xt()}},e(r,r.exports),r.exports}function Dt(e){if(e.__esModule)return e;var t=Object.defineProperty({},"__esModule",{value:true});Object.keys(e).forEach((function(r){var n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:true,get:function(){return e[r]}})}));return t}function xt(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}var Nt=e("p",It.process);var jt=function e(t,r){Ot.forEach(t,(function e(n,i){if(i!==r&&i.toUpperCase()===r.toUpperCase()){t[r]=n;delete t[i]}}))};function Mt(e,t,r,n,i){Error.call(this);this.message=e;this.name="AxiosError";t&&(this.code=t);r&&(this.config=r);n&&(this.request=n);i&&(this.response=i)}Ot.inherits(Mt,Error,{toJSON:function e(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code,status:this.response&&this.response.status?this.response.status:null}}});var kt=Mt.prototype;var Yt={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED"].forEach((function(e){Yt[e]={value:e}}));Object.defineProperties(Mt,Yt);Object.defineProperty(kt,"isAxiosError",{value:true});Mt.from=function(e,t,r,n,i,o){var a=Object.create(kt);Ot.toFlatObject(e,a,(function e(t){return t!==Error.prototype}));Mt.call(a,e.message,t,r,n,i);a.name=e.name;o&&Object.assign(a,o);return a};var Ft=Mt;var qt={silentJSONParsing:true,forcedJSONParsing:true,clarifyTimeoutError:false};function zt(e,t){t=t||new FormData;var r=[];function n(e){if(e===null)return"";if(Ot.isDate(e)){return e.toISOString()}if(Ot.isArrayBuffer(e)||Ot.isTypedArray(e)){return typeof Blob==="function"?new Blob([e]):m.from(e)}return e}function i(e,o){if(Ot.isPlainObject(e)||Ot.isArray(e)){if(r.indexOf(e)!==-1){throw Error("Circular reference detected in "+o)}r.push(e);Ot.forEach(e,(function e(r,a){if(Ot.isUndefined(r))return;var s=o?o+"."+a:a;var u;if(r&&!o&&typeof r==="object"){if(Ot.endsWith(a,"{}")){r=JSON.stringify(r)}else if(Ot.endsWith(a,"[]")&&(u=Ot.toArray(r))){u.forEach((function(e){!Ot.isUndefined(e)&&t.append(s,n(e))}));return}}i(r,s)}));r.pop()}else{t.append(o,n(e))}}i(e);return t}var Vt=zt;var Jt=function e(t,r,n){var i=n.config.validateStatus;if(!n.status||!i||i(n.status)){t(n)}else{r(new Ft("Request failed with status code "+n.status,[Ft.ERR_BAD_REQUEST,Ft.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}};var Wt=Ot.isStandardBrowserEnv()?function e(){return{write:function e(t,r,n,i,o,a){var s=[];s.push(t+"="+encodeURIComponent(r));if(Ot.isNumber(n)){s.push("expires="+new Date(n).toGMTString())}if(Ot.isString(i)){s.push("path="+i)}if(Ot.isString(o)){s.push("domain="+o)}if(a===true){s.push("secure")}document.cookie=s.join("; ")},read:function e(t){var r=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return r?decodeURIComponent(r[3]):null},remove:function e(t){this.write(t,"",Date.now()-864e5)}}}():function e(){return{write:function e(){},read:function e(){return null},remove:function e(){}}}();var Ht=function e(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)};var Gt=function e(t,r){return r?t.replace(/\/+$/,"")+"/"+r.replace(/^\/+/,""):t};var Kt=function e(t,r){if(t&&!Ht(r)){return Gt(t,r)}return r};var Xt=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];var Zt=function e(t){var r={};var n;var i;var o;if(!t){return r}Ot.forEach(t.split("\n"),(function e(t){o=t.indexOf(":");n=Ot.trim(t.substr(0,o)).toLowerCase();i=Ot.trim(t.substr(o+1));if(n){if(r[n]&&Xt.indexOf(n)>=0){return}if(n==="set-cookie"){r[n]=(r[n]?r[n]:[]).concat([i])}else{r[n]=r[n]?r[n]+", "+i:i}}}));return r};var $t=Ot.isStandardBrowserEnv()?function e(){var t=/(msie|trident)/i.test(navigator.userAgent);var r=document.createElement("a");var n;function i(e){var n=e;if(t){r.setAttribute("href",n);n=r.href}r.setAttribute("href",n);return{href:r.href,protocol:r.protocol?r.protocol.replace(/:$/,""):"",host:r.host,search:r.search?r.search.replace(/^\?/,""):"",hash:r.hash?r.hash.replace(/^#/,""):"",hostname:r.hostname,port:r.port,pathname:r.pathname.charAt(0)==="/"?r.pathname:"/"+r.pathname}}n=i(window.location.href);return function e(t){var r=Ot.isString(t)?i(t):t;return r.protocol===n.protocol&&r.host===n.host}}():function e(){return function e(){return true}}();function Qt(e){Ft.call(this,e==null?"canceled":e,Ft.ERR_CANCELED);this.name="CanceledError"}Ot.inherits(Qt,Ft,{__CANCEL__:true});var er=Qt;var tr=function e(t){var r=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return r&&r[1]||""};var rr=function e(t){return new Promise((function e(r,n){var i=t.data;var o=t.headers;var a=t.responseType;var s;function u(){if(t.cancelToken){t.cancelToken.unsubscribe(s)}if(t.signal){t.signal.removeEventListener("abort",s)}}if(Ot.isFormData(i)&&Ot.isStandardBrowserEnv()){delete o["Content-Type"]}var f=new XMLHttpRequest;if(t.auth){var c=t.auth.username||"";var l=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";o.Authorization="Basic "+btoa(c+":"+l)}var h=Kt(t.baseURL,t.url);f.open(t.method.toUpperCase(),Pt(h,t.params,t.paramsSerializer),true);f.timeout=t.timeout;function p(){if(!f){return}var e="getAllResponseHeaders"in f?Zt(f.getAllResponseHeaders()):null;var i=!a||a==="text"||a==="json"?f.responseText:f.response;var o={data:i,status:f.status,statusText:f.statusText,headers:e,config:t,request:f};Jt((function e(t){r(t);u()}),(function e(t){n(t);u()}),o);f=null}if("onloadend"in f){f.onloadend=p}else{f.onreadystatechange=function e(){if(!f||f.readyState!==4){return}if(f.status===0&&!(f.responseURL&&f.responseURL.indexOf("file:")===0)){return}setTimeout(p)}}f.onabort=function e(){if(!f){return}n(new Ft("Request aborted",Ft.ECONNABORTED,t,f));f=null};f.onerror=function e(){n(new Ft("Network Error",Ft.ERR_NETWORK,t,f,f));f=null};f.ontimeout=function e(){var r=t.timeout?"timeout of "+t.timeout+"ms exceeded":"timeout exceeded";var i=t.transitional||qt;if(t.timeoutErrorMessage){r=t.timeoutErrorMessage}n(new Ft(r,i.clarifyTimeoutError?Ft.ETIMEDOUT:Ft.ECONNABORTED,t,f));f=null};if(Ot.isStandardBrowserEnv()){var d=(t.withCredentials||$t(h))&&t.xsrfCookieName?Wt.read(t.xsrfCookieName):undefined;if(d){o[t.xsrfHeaderName]=d}}if("setRequestHeader"in f){Ot.forEach(o,(function e(t,r){if(typeof i==="undefined"&&r.toLowerCase()==="content-type"){delete o[r]}else{f.setRequestHeader(r,t)}}))}if(!Ot.isUndefined(t.withCredentials)){f.withCredentials=!!t.withCredentials}if(a&&a!=="json"){f.responseType=t.responseType}if(typeof t.onDownloadProgress==="function"){f.addEventListener("progress",t.onDownloadProgress)}if(typeof t.onUploadProgress==="function"&&f.upload){f.upload.addEventListener("progress",t.onUploadProgress)}if(t.cancelToken||t.signal){s=function(e){if(!f){return}n(!e||e&&e.type?new er:e);f.abort();f=null};t.cancelToken&&t.cancelToken.subscribe(s);if(t.signal){t.signal.aborted?s():t.signal.addEventListener("abort",s)}}if(!i){i=null}var v=tr(h);if(v&&["http","https","file"].indexOf(v)===-1){n(new Ft("Unsupported protocol "+v+":",Ft.ERR_BAD_REQUEST,t));return}f.send(i)}))};var nr=null;var ir={"Content-Type":"application/x-www-form-urlencoded"};function or(e,t){if(!Ot.isUndefined(e)&&Ot.isUndefined(e["Content-Type"])){e["Content-Type"]=t}}function ar(){var e;if(typeof XMLHttpRequest!=="undefined"){e=rr}else if(typeof Nt!=="undefined"&&Object.prototype.toString.call(Nt)==="[object process]"){e=rr}return e}function sr(e,t,r){if(Ot.isString(e)){try{(t||JSON.parse)(e);return Ot.trim(e)}catch(e){if(e.name!=="SyntaxError"){throw e}}}return(r||JSON.stringify)(e)}var ur={transitional:qt,adapter:ar(),transformRequest:[function e(t,r){jt(r,"Accept");jt(r,"Content-Type");if(Ot.isFormData(t)||Ot.isArrayBuffer(t)||Ot.isBuffer(t)||Ot.isStream(t)||Ot.isFile(t)||Ot.isBlob(t)){return t}if(Ot.isArrayBufferView(t)){return t.buffer}if(Ot.isURLSearchParams(t)){or(r,"application/x-www-form-urlencoded;charset=utf-8");return t.toString()}var n=Ot.isObject(t);var i=r&&r["Content-Type"];var o;if((o=Ot.isFileList(t))||n&&i==="multipart/form-data"){var a=this.env&&this.env.FormData;return Vt(o?{"files[]":t}:t,a&&new a)}else if(n||i==="application/json"){or(r,"application/json");return sr(t)}return t}],transformResponse:[function e(t){var r=this.transitional||ur.transitional;var n=r&&r.silentJSONParsing;var i=r&&r.forcedJSONParsing;var o=!n&&this.responseType==="json";if(o||i&&Ot.isString(t)&&t.length){try{return JSON.parse(t)}catch(e){if(o){if(e.name==="SyntaxError"){throw Ft.from(e,Ft.ERR_BAD_RESPONSE,this,null,this.response)}throw e}}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:nr},validateStatus:function e(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};Ot.forEach(["delete","get","head"],(function e(t){ur.headers[t]={}}));Ot.forEach(["post","put","patch"],(function e(t){ur.headers[t]=Ot.merge(ir)}));var fr=ur;var cr=function e(t,r,n){var i=this||fr;Ot.forEach(n,(function e(n){t=n.call(i,t,r)}));return t};var lr=function e(t){return!!(t&&t.__CANCEL__)};function hr(e){if(e.cancelToken){e.cancelToken.throwIfRequested()}if(e.signal&&e.signal.aborted){throw new er}}var pr=function e(t){hr(t);t.headers=t.headers||{};t.data=cr.call(t,t.data,t.headers,t.transformRequest);t.headers=Ot.merge(t.headers.common||{},t.headers[t.method]||{},t.headers);Ot.forEach(["delete","get","head","post","put","patch","common"],(function e(r){delete t.headers[r]}));var r=t.adapter||fr.adapter;return r(t).then((function e(r){hr(t);r.data=cr.call(t,r.data,r.headers,t.transformResponse);return r}),(function e(r){if(!lr(r)){hr(t);if(r&&r.response){r.response.data=cr.call(t,r.response.data,r.response.headers,t.transformResponse)}}return Promise.reject(r)}))};var dr=function e(t,r){r=r||{};var n={};function i(e,t){if(Ot.isPlainObject(e)&&Ot.isPlainObject(t)){return Ot.merge(e,t)}else if(Ot.isPlainObject(t)){return Ot.merge({},t)}else if(Ot.isArray(t)){return t.slice()}return t}function o(e){if(!Ot.isUndefined(r[e])){return i(t[e],r[e])}else if(!Ot.isUndefined(t[e])){return i(undefined,t[e])}}function a(e){if(!Ot.isUndefined(r[e])){return i(undefined,r[e])}}function s(e){if(!Ot.isUndefined(r[e])){return i(undefined,r[e])}else if(!Ot.isUndefined(t[e])){return i(undefined,t[e])}}function u(e){if(e in r){return i(t[e],r[e])}else if(e in t){return i(undefined,t[e])}}var f={url:a,method:a,data:a,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:u};Ot.forEach(Object.keys(t).concat(Object.keys(r)),(function e(t){var r=f[t]||o;var i=r(t);Ot.isUndefined(i)&&r!==u||(n[t]=i)}));return n};var vr={version:"0.27.2"};var gr=vr.version;var yr={};["object","boolean","number","function","string","symbol"].forEach((function(e,t){yr[e]=function r(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}}));var mr={};yr.transitional=function e(t,r,n){function i(e,t){return"[Axios v"+gr+"] Transitional option '"+e+"'"+t+(n?". "+n:"")}return function(e,n,o){if(t===false){throw new Ft(i(n," has been removed"+(r?" in "+r:"")),Ft.ERR_DEPRECATED)}if(r&&!mr[n]){mr[n]=true;console.warn(i(n," has been deprecated since v"+r+" and will be removed in the near future"))}return t?t(e,n,o):true}};function Er(e,t,r){if(typeof e!=="object"){throw new Ft("options must be an object",Ft.ERR_BAD_OPTION_VALUE)}var n=Object.keys(e);var i=n.length;while(i-- >0){var o=n[i];var a=t[o];if(a){var s=e[o];var u=s===undefined||a(s,o,e);if(u!==true){throw new Ft("option "+o+" must be "+u,Ft.ERR_BAD_OPTION_VALUE)}continue}if(r!==true){throw new Ft("Unknown option "+o,Ft.ERR_BAD_OPTION)}}}var wr={assertOptions:Er,validators:yr};var br=wr.validators;function _r(e){this.defaults=e;this.interceptors={request:new Ut,response:new Ut}}_r.prototype.request=function e(t,r){if(typeof t==="string"){r=r||{};r.url=t}else{r=t||{}}r=dr(this.defaults,r);if(r.method){r.method=r.method.toLowerCase()}else if(this.defaults.method){r.method=this.defaults.method.toLowerCase()}else{r.method="get"}var n=r.transitional;if(n!==undefined){wr.assertOptions(n,{silentJSONParsing:br.transitional(br.boolean),forcedJSONParsing:br.transitional(br.boolean),clarifyTimeoutError:br.transitional(br.boolean)},false)}var i=[];var o=true;this.interceptors.request.forEach((function e(t){if(typeof t.runWhen==="function"&&t.runWhen(r)===false){return}o=o&&t.synchronous;i.unshift(t.fulfilled,t.rejected)}));var a=[];this.interceptors.response.forEach((function e(t){a.push(t.fulfilled,t.rejected)}));var s;if(!o){var u=[pr,undefined];Array.prototype.unshift.apply(u,i);u=u.concat(a);s=Promise.resolve(r);while(u.length){s=s.then(u.shift(),u.shift())}return s}var f=r;while(i.length){var c=i.shift();var l=i.shift();try{f=c(f)}catch(e){l(e);break}}try{s=pr(f)}catch(e){return Promise.reject(e)}while(a.length){s=s.then(a.shift(),a.shift())}return s};_r.prototype.getUri=function e(t){t=dr(this.defaults,t);var r=Kt(t.baseURL,t.url);return Pt(r,t.params,t.paramsSerializer)};Ot.forEach(["delete","get","head","options"],(function e(t){_r.prototype[t]=function(e,r){return this.request(dr(r||{},{method:t,url:e,data:(r||{}).data}))}}));Ot.forEach(["post","put","patch"],(function e(t){function r(e){return function r(n,i,o){return this.request(dr(o||{},{method:t,headers:e?{"Content-Type":"multipart/form-data"}:{},url:n,data:i}))}}_r.prototype[t]=r();_r.prototype[t+"Form"]=r(true)}));var Rr=_r;function Ar(e){if(typeof e!=="function"){throw new TypeError("executor must be a function.")}var t;this.promise=new Promise((function e(r){t=r}));var r=this;this.promise.then((function(e){if(!r._listeners)return;var t;var n=r._listeners.length;for(t=0;t<n;t++){r._listeners[t](e)}r._listeners=null}));this.promise.then=function(e){var t;var n=new Promise((function(e){r.subscribe(e);t=e})).then(e);n.cancel=function e(){r.unsubscribe(t)};return n};e((function e(n){if(r.reason){return}r.reason=new er(n);t(r.reason)}))}Ar.prototype.throwIfRequested=function e(){if(this.reason){throw this.reason}};Ar.prototype.subscribe=function e(t){if(this.reason){t(this.reason);return}if(this._listeners){this._listeners.push(t)}else{this._listeners=[t]}};Ar.prototype.unsubscribe=function e(t){if(!this._listeners){return}var r=this._listeners.indexOf(t);if(r!==-1){this._listeners.splice(r,1)}};Ar.source=function e(){var t;var r=new Ar((function e(r){t=r}));return{token:r,cancel:t}};var Tr=Ar;var Or=function e(t){return function e(r){return t.apply(null,r)}};var Sr=function e(t){return Ot.isObject(t)&&t.isAxiosError===true};function Pr(e){var t=new Rr(e);var r=Ge(Rr.prototype.request,t);Ot.extend(r,Rr.prototype,t);Ot.extend(r,t);r.create=function t(r){return Pr(dr(e,r))};return r}var Cr=Pr(fr);Cr.Axios=Rr;Cr.CanceledError=er;Cr.CancelToken=Tr;Cr.isCancel=lr;Cr.VERSION=vr.version;Cr.toFormData=Vt;Cr.AxiosError=Ft;Cr.Cancel=Cr.CanceledError;Cr.all=function e(t){return Promise.all(t)};Cr.spread=Or;Cr.isAxiosError=Sr;var Ur=Cr;var Ir=Cr;Ur.default=Ir;var Lr=Ur;var Br=function(){if(typeof self==="object"&&self)return self;if(typeof window==="object"&&window)return window;throw new Error("Unable to resolve global `this`")};var Dr=function(){if(this)return this;if(typeof globalThis==="object"&&globalThis)return globalThis;try{Object.defineProperty(Object.prototype,"__global__",{get:function(){return this},configurable:true})}catch(e){return Br()}try{if(!__global__)return Br();return __global__}finally{delete Object.prototype.__global__}}();var xr=function(e){console.debug("[JS-SDK] ".concat(e.method.toUpperCase()," ").concat(e.baseURL).concat(e.url),e.data?JSON.stringify(e.data):"");return e};var Nr=e("V",function(){function e(e){this.environment="verdocs";this.sessionType="user";this.baseURL="https://api.verdocs.com";this.clientID="not-set";this.timeout=3e3;this.token=null;this.nextListenerId=0;this.sessionListeners=new Map;this.requestLoggerId=null;this.session=null;this.Documents=ze;this.baseURL=(e===null||e===void 0?void 0:e.baseURL)||"https://api.verdocs.com";this.timeout=(e===null||e===void 0?void 0:e.timeout)||3e3;this.environment=(e===null||e===void 0?void 0:e.environment)||"verdocs";this.sessionType=(e===null||e===void 0?void 0:e.sessionType)||"user";this.clientID=(e===null||e===void 0?void 0:e.clientID)||"not-set";this.api=Lr.create({baseURL:this.baseURL,timeout:this.timeout})}e.prototype.setDefault=function(){Dr[jr]=this};e.getDefault=function(){return Dr[jr]};e.prototype.getEnvironment=function(){return this.environment};e.prototype.getSessionType=function(){return this.sessionType};e.prototype.getBaseURL=function(){return this.baseURL};e.prototype.getClientID=function(){return this.clientID};e.prototype.getTimeout=function(){return this.timeout};e.prototype.getSession=function(){return this.session};e.prototype.setEnvironment=function(e){this.environment=e;return this};e.prototype.setSessionType=function(e){this.sessionType=e;return this};e.prototype.setBaseURL=function(e){this.api.defaults.baseURL=e;return this};e.prototype.setClientID=function(e){this.clientID=e;this.api.defaults.headers.common["X-Client-ID"]=e;return this};e.prototype.setTimeout=function(e){this.timeout=e;this.api.defaults.timeout=e;return this};e.prototype.logRequests=function(e){if(e&&this.requestLoggerId===null){this.requestLoggerId=this.api.interceptors.request.use(xr)}else if(!e&&this.requestLoggerId!==null){this.api.interceptors.request.eject(this.requestLoggerId)}return this};e.prototype.setToken=function(e){if(!e){return this.clearSession()}var t=me(e);if(t===null||t.exp&&t.exp*1e3<(new Date).getTime()){return this.clearSession()}this.token=e;this.session=t;this.api.defaults.headers.common.Authorization="Bearer ".concat(e);localStorage.setItem(this.sessionStorageKey(),e);this.notifySessionListeners();return this};e.prototype.sessionStorageKey=function(){return"verdocs-session-".concat(this.getSessionType(),"-").concat(this.getEnvironment())};e.prototype.clearSession=function(){localStorage.removeItem(this.sessionStorageKey());delete this.api.defaults.headers.common.Authorization;this.session=null;this.token=null;this.notifySessionListeners();return this};e.prototype.notifySessionListeners=function(){var e=this;this.sessionListeners.forEach((function(t){try{t(e,e.session)}catch(e){}}))};e.prototype.onSessionChanged=function(e){var t=this;this.nextListenerId++;var r=Symbol.for(""+this.nextListenerId);this.sessionListeners.set(r,e);return function(){t.sessionListeners.delete(r)}};e.prototype.loadSession=function(){var e=localStorage.getItem(this.sessionStorageKey());if(!e){return this.clearSession()}return this.setToken(e)};return e}());var jr=Symbol.for("verdocs-default-endpoint");if(!Dr[jr]){Dr[jr]=new Nr}}}}));
@@ -1 +1 @@
1
- System.register(["./p-caed7818.system.js"],(function(e){"use strict";var o,s,n,i;return{setters:[function(e){o=e.r;s=e.c;n=e.h;i=e.H}],execute:function(){var t='verdocs-ok-dialog{font-family:"Barlow", sans-serif;-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-ok-dialog .background-overlay{position:absolute;z-index:10000;top:0;left:0;right:0;bottom:0;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;background:#0000007f}verdocs-ok-dialog .dialog{max-width:50%;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;border-radius:4px;overflow:hidden;-webkit-box-shadow:3px 3px 5px 1px rgba(40, 40, 40, 0.4);box-shadow:3px 3px 5px 1px rgba(40, 40, 40, 0.4)}verdocs-ok-dialog .heading{display:-ms-flexbox;display:flex;font-size:16px;-ms-flex-direction:row;flex-direction:row;background:#444444;padding:8px 16px;color:#ffffff}verdocs-ok-dialog .content{font-size:14px;background:#ffffff;padding:20px}verdocs-ok-dialog .buttons{display:-ms-flexbox;display:flex;margin:20px 0 0 0;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:center;align-items:center;-ms-flex-pack:end;justify-content:flex-end}verdocs-ok-dialog .buttons verdocs-button{margin-left:16px}';var l=e("verdocs_ok_dialog",function(){function e(e){o(this,e);this.closed=s(this,"closed",7);this.heading="";this.message="";this.open=false;this.cancel=false}e.prototype.handleClose=function(e){this.closed.emit(e);this.open=false};e.prototype.handleDismiss=function(e){if(e.target.className==="background-overlay"){e.preventDefault();this.handleClose("cancel")}};e.prototype.render=function(){var e=this;return n(i,{style:{display:this.open?"block":"none"}},n("div",{class:"background-overlay",onClick:function(o){return e.handleDismiss(o)}},n("div",{class:"dialog"},n("div",{class:"heading"},this.heading),n("div",{class:"content"},this.message,n("div",{class:"buttons"},this.cancel?n("verdocs-button",{label:"CANCEL",variant:"outline",onPress:function(){return e.handleClose("cancel")}}):n("div",{style:{display:"none"}}),n("verdocs-button",{label:"OK",onPress:function(){return e.handleClose("ok")}}))))))};return e}());l.style=t}}}));
1
+ System.register(["./p-caed7818.system.js"],(function(e){"use strict";var o,s,n,i;return{setters:[function(e){o=e.r;s=e.c;n=e.h;i=e.H}],execute:function(){var t='verdocs-ok-dialog{font-family:"Barlow", sans-serif;-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-ok-dialog .background-overlay{position:absolute;z-index:10000;top:0;left:0;right:0;bottom:0;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;background:#0000007f}verdocs-ok-dialog .dialog{max-width:50%;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;border-radius:4px;overflow:hidden;-webkit-box-shadow:3px 3px 5px 1px rgba(40, 40, 40, 0.4);box-shadow:3px 3px 5px 1px rgba(40, 40, 40, 0.4)}verdocs-ok-dialog .heading{display:-ms-flexbox;display:flex;font-size:16px;-ms-flex-direction:row;flex-direction:row;background:#444444;padding:8px 16px;color:#ffffff}verdocs-ok-dialog .content{font-size:16px;background:#ffffff;padding:20px}verdocs-ok-dialog .buttons{display:-ms-flexbox;display:flex;margin:20px 0 0 0;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:center;align-items:center;-ms-flex-pack:end;justify-content:flex-end}verdocs-ok-dialog .buttons verdocs-button{margin-left:16px}';var l=e("verdocs_ok_dialog",function(){function e(e){o(this,e);this.closed=s(this,"closed",7);this.heading="";this.message="";this.open=false;this.cancel=false}e.prototype.handleClose=function(e){this.closed.emit(e);this.open=false};e.prototype.handleDismiss=function(e){if(e.target.className==="background-overlay"){e.preventDefault();this.handleClose("cancel")}};e.prototype.render=function(){var e=this;return n(i,{style:{display:this.open?"block":"none"}},n("div",{class:"background-overlay",onClick:function(o){return e.handleDismiss(o)}},n("div",{class:"dialog"},n("div",{class:"heading"},this.heading),n("div",{class:"content"},this.message,n("div",{class:"buttons"},this.cancel?n("verdocs-button",{label:"CANCEL",variant:"outline",onPress:function(){return e.handleClose("cancel")}}):n("div",{style:{display:"none"}}),n("verdocs-button",{label:"OK",onPress:function(){return e.handleClose("ok")}}))))))};return e}());l.style=t}}}));
@@ -0,0 +1 @@
1
+ import{r as e,c as t,h as i}from"./p-2bc58746.js";import{V as n}from"./p-06f38046.js";const o=class{constructor(i){e(this,i),this.createTemplate=t(this,"createTemplate",7),this.createDocument=t(this,"createDocument",7),this.endpoint=n.getDefault()}handleCreateTemplate(){this.createTemplate.emit()}handleCreateDocument(){this.createDocument.emit()}render(){return i("div",{class:"container"},i("p",{class:"title"},"Quick Create"),i("button",{onClick:()=>this.handleCreateTemplate(),innerHTML:'<svg xmlns="http://www.w3.org/2000/svg" enable-background="new 0 0 24 24" height="24px" viewBox="0 0 24 24" width="24px" fill="#000000"><g><rect fill="none" height="24" width="24"/><g><path d="M19,5v14H5V5H19 M19,3H5C3.9,3,3,3.9,3,5v14c0,1.1,0.9,2,2,2h14c1.1,0,2-0.9,2-2V5C21,3.9,20.1,3,19,3L19,3z"/></g><path d="M14,17H7v-2h7V17z M17,13H7v-2h10V13z M17,9H7V7h10V9z"/></g></svg>'},"Template"),i("button",{onClick:()=>this.handleCreateDocument(),innerHTML:'<svg xmlns="http://www.w3.org/2000/svg" height="24px" viewBox="0 0 24 24" width="24px" fill="#000000"><path d="M0 0h24v24H0V0z" fill="none"/><path d="M8 16h8v2H8zm0-4h8v2H8zm6-10H6c-1.1 0-2 .9-2 2v16c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6zm4 18H6V4h7v5h5v11z"/></svg>'},"Document"))}};o.style='verdocs-quick-functions{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif}verdocs-quick-functions .container{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-wrap:nowrap;flex-wrap:nowrap;width:240px;background-color:var(--verdocs-background-dark);text-transform:uppercase;padding:10px 10px 20px 10px;font-family:sans-serif;color:#ffffff}verdocs-quick-functions .title{font-size:22px;font-weight:700;line-height:30px;margin:1em 0 40px 0}verdocs-quick-functions button{width:140px;height:40px;border:none;display:-ms-flexbox;display:flex;color:#ffffff;cursor:pointer;font-size:14px;font-weight:700;line-height:25px;-ms-flex-align:center;align-items:center;margin-bottom:20px;border-radius:5px;text-transform:uppercase;-ms-flex-pack:space-evenly;justify-content:space-evenly;background-color:#50be50}verdocs-quick-functions button svg{fill:#ffffff}';export{o as verdocs_quick_functions}
@@ -1 +1 @@
1
- System.register(["./p-caed7818.system.js"],(function(e,d){"use strict";var s,r;return{setters:[function(e){s=e.p;r=e.b}],execute:function(){var e=function(){var e=d.meta.url;var r={};if(e!==""){r.resourcesUrl=new URL(".",e).href}return s(r)};e().then((function(e){return r([["p-0c0b4a10.system",[[0,"verdocs-sign",{documentid:[1],roleid:[1],invitecode:[1],endpoint:[32],recipient:[32],signerToken:[32],pdfUrl:[32],recipientIndex:[32],document:[32],fields:[32],pdfPageInfo:[32],hasSignature:[32],nextButtonLabel:[32],focusedField:[32]}]]],["p-2b57857d.system",[[0,"verdocs-auth",{visible:[4],logo:[1],debug:[4],isAuthenticated:[32],displayMode:[32],username:[32],password:[32],loggingIn:[32],activeSession:[32],loginError:[32]}]]],["p-fd853e54.system",[[0,"verdocs-search"]]],["p-e2e643c5.system",[[0,"verdocs-kba-dialog",{step:[2],steps:[2],helptitle:[1],helptext:[1],mode:[1],label:[1],placeholder:[1],choices:[16],open:[4],response:[32]}]]],["p-e719f9ca.system",[[0,"verdocs-organization-card",{organization:[16]}]]],["p-2c161242.system",[[0,"verdocs-quick-functions"]]],["p-d14a6057.system",[[0,"verdocs-search-tabs",{selected:[32]}]]],["p-f814d5cc.system",[[0,"verdocs-status-indicator",{size:[1],theme:[1],status:[1],document:[16],isOpen:[32],recipientStatusIcons:[32]}]]],["p-1f55d8ac.system",[[0,"verdocs-template-card",{template:[16]}]]],["p-cc127684.system",[[0,"verdocs-template-tags",{tags:[16]}]]],["p-6802ef91.system",[[0,"verdocs-toggle",{options:[16],theme:[1]},[[6,"click","handleClick"]]]]],["p-cd6a2c40.system",[[0,"verdocs-text-input",{value:[1],label:[1],placeholder:[1],autocomplete:[1],type:[1],disabled:[4],_value:[32]}],[0,"verdocs-button",{label:[1],startIcon:[1,"start-icon"],endIcon:[1,"end-icon"],size:[1],type:[1],variant:[1],disabled:[4]}]]],["p-432c3151.system",[[0,"verdocs-ok-dialog",{heading:[1],message:[1],open:[4],cancel:[4]}]]],["p-d6206c17.system",[[0,"verdocs-initial-dialog",{fullname:[1],open:[4],fontLoaded:[32],enteredInitials:[32],mode:[32]}]]],["p-c2f97ef9.system",[[0,"verdocs-signature-dialog",{fullname:[1],open:[4],fontLoaded:[32],enteredName:[32],mode:[32]}]]],["p-f0d0f959.system",[[0,"verdocs-upload-dialog",{open:[4],draggingOver:[32],decodedFiles:[32]}]]],["p-b9164c4b.system",[[0,"verdocs-search-activity",{type:[1],options:[8],emptyMessage:[32],authFailure:[32],title:[32],recent:[32],saved:[32],starred:[32]}],[0,"verdocs-search-box",{placeholder:[1],type:[1],query:[1]}]]],["p-144e0842.system",[[0,"verdocs-loader"]]],["p-4368df79.system",[[0,"verdocs-field-initial",{required:[4],fullName:[1,"full-name"],value:[1],focusField:[64]}],[0,"verdocs-field-signature",{required:[4],fullName:[1,"full-name"],value:[1],focusField:[64]}],[0,"verdocs-field-attachment",{order:[2],value:[1],required:[4],disabled:[4],focusField:[64]}],[0,"verdocs-view",{rotation:[2],source:[1],token:[1],loadProgress:[32]}],[0,"verdocs-dropdown",{options:[16],open:[4],isOpen:[32]}],[0,"verdocs-field-checkbox",{order:[2],value:[4],required:[4],disabled:[4]}],[0,"verdocs-field-date",{placeholder:[1],order:[2],value:[1],required:[4],disabled:[4],focused:[32],focusField:[64]}],[0,"verdocs-field-dropdown",{options:[16],required:[4],order:[2],disabled:[4],value:[1],focused:[32],focusField:[64]}],[0,"verdocs-field-payment",{field:[16],fields:[16],pageNum:[2,"page-num"],roleName:[1,"role-name"],fieldId:[1,"field-id"],recipients:[8],selectedRoleName:[1,"selected-role-name"],pdfPages:[16],currentSignature:[1,"current-signature"],currentSignatureId:[1,"current-signature-id"],currentInitial:[1,"current-initial"],currentInitialId:[1,"current-initial-id"],focused:[4],signed:[4],preparedMessage:[32],signatureUrl:[32]}],[0,"verdocs-field-radio-button",{order:[2],checked:[4],value:[1],name:[1],required:[4],disabled:[4]}],[0,"verdocs-field-textarea",{placeholder:[1],order:[2],value:[1],required:[4],disabled:[4],focused:[32],focusField:[64]}],[0,"verdocs-field-textbox",{placeholder:[1],order:[2],value:[1],required:[4],disabled:[4],focused:[32],focusField:[64]}]]]],e)}))}}}));
1
+ System.register(["./p-caed7818.system.js"],(function(e,d){"use strict";var s,r;return{setters:[function(e){s=e.p;r=e.b}],execute:function(){var e=function(){var e=d.meta.url;var r={};if(e!==""){r.resourcesUrl=new URL(".",e).href}return s(r)};e().then((function(e){return r([["p-a87069d5.system",[[0,"verdocs-sign",{endpoint:[16],documentid:[1],roleid:[1],invitecode:[1],recipient:[32],signerToken:[32],pdfUrl:[32],recipientIndex:[32],document:[32],fields:[32],pdfPageInfo:[32],hasSignature:[32],nextButtonLabel:[32],focusedField:[32]}]]],["p-f6a53928.system",[[0,"verdocs-auth",{endpoint:[16],visible:[4],logo:[1],debug:[4],isAuthenticated:[32],displayMode:[32],username:[32],password:[32],loggingIn:[32],activeSession:[32],loginError:[32]}]]],["p-16d62a51.system",[[0,"verdocs-search",{endpoint:[16]}]]],["p-e4ba14dc.system",[[0,"verdocs-kba-dialog",{step:[2],steps:[2],helptitle:[1],helptext:[1],mode:[1],label:[1],placeholder:[1],choices:[16],open:[4],response:[32]}]]],["p-e719f9ca.system",[[0,"verdocs-organization-card",{organization:[16]}]]],["p-9139a76d.system",[[0,"verdocs-quick-functions",{endpoint:[16]}]]],["p-d14a6057.system",[[0,"verdocs-search-tabs",{selected:[32]}]]],["p-f814d5cc.system",[[0,"verdocs-status-indicator",{size:[1],theme:[1],status:[1],document:[16],isOpen:[32],recipientStatusIcons:[32]}]]],["p-1f55d8ac.system",[[0,"verdocs-template-card",{template:[16]}]]],["p-cc127684.system",[[0,"verdocs-template-tags",{tags:[16]}]]],["p-6802ef91.system",[[0,"verdocs-toggle",{options:[16],theme:[1]},[[6,"click","handleClick"]]]]],["p-cd6a2c40.system",[[0,"verdocs-text-input",{value:[1],label:[1],placeholder:[1],autocomplete:[1],type:[1],disabled:[4],_value:[32]}],[0,"verdocs-button",{label:[1],startIcon:[1,"start-icon"],endIcon:[1,"end-icon"],size:[1],type:[1],variant:[1],disabled:[4]}]]],["p-81fc0196.system",[[0,"verdocs-ok-dialog",{heading:[1],message:[1],open:[4],cancel:[4]}]]],["p-d6206c17.system",[[0,"verdocs-initial-dialog",{fullname:[1],open:[4],fontLoaded:[32],enteredInitials:[32],mode:[32]}]]],["p-c2f97ef9.system",[[0,"verdocs-signature-dialog",{fullname:[1],open:[4],fontLoaded:[32],enteredName:[32],mode:[32]}]]],["p-f0d0f959.system",[[0,"verdocs-upload-dialog",{open:[4],draggingOver:[32],decodedFiles:[32]}]]],["p-1b4e04b7.system",[[0,"verdocs-search-activity",{endpoint:[16],type:[1],options:[8],emptyMessage:[32],authFailure:[32],title:[32],recent:[32],saved:[32],starred:[32]}],[0,"verdocs-search-box",{endpoint:[16],placeholder:[1],type:[1],query:[1]}]]],["p-144e0842.system",[[0,"verdocs-loader"]]],["p-c4d03ff9.system",[[0,"verdocs-field-initial",{required:[4],fullName:[1,"full-name"],value:[1],focusField:[64]}],[0,"verdocs-field-signature",{required:[4],fullName:[1,"full-name"],value:[1],focusField:[64]}],[0,"verdocs-field-attachment",{order:[2],value:[1],required:[4],disabled:[4],focusField:[64]}],[0,"verdocs-view",{endpoint:[16],rotation:[2],source:[1],token:[1],loadProgress:[32]}],[0,"verdocs-dropdown",{options:[16],open:[4],isOpen:[32]}],[0,"verdocs-field-checkbox",{order:[2],value:[4],required:[4],disabled:[4]}],[0,"verdocs-field-date",{placeholder:[1],order:[2],value:[1],required:[4],disabled:[4],focused:[32],focusField:[64]}],[0,"verdocs-field-dropdown",{options:[16],required:[4],order:[2],disabled:[4],value:[1],focused:[32],focusField:[64]}],[0,"verdocs-field-payment",{field:[16],fields:[16],pageNum:[2,"page-num"],roleName:[1,"role-name"],fieldId:[1,"field-id"],recipients:[8],selectedRoleName:[1,"selected-role-name"],pdfPages:[16],currentSignature:[1,"current-signature"],currentSignatureId:[1,"current-signature-id"],currentInitial:[1,"current-initial"],currentInitialId:[1,"current-initial-id"],focused:[4],signed:[4],preparedMessage:[32],signatureUrl:[32]}],[0,"verdocs-field-radio-button",{order:[2],checked:[4],value:[1],name:[1],required:[4],disabled:[4]}],[0,"verdocs-field-textarea",{placeholder:[1],order:[2],value:[1],required:[4],disabled:[4],focused:[32],focusField:[64]}],[0,"verdocs-field-textbox",{placeholder:[1],order:[2],value:[1],required:[4],disabled:[4],focused:[32],focusField:[64]}]]]],e)}))}}}));
@@ -0,0 +1 @@
1
+ System.register(["./p-caed7818.system.js","./p-4d80d044.system.js"],(function(e){"use strict";var t,n,i,o;return{setters:[function(e){t=e.r;n=e.c;i=e.h},function(e){o=e.V}],execute:function(){var r='<svg xmlns="http://www.w3.org/2000/svg" enable-background="new 0 0 24 24" height="24px" viewBox="0 0 24 24" width="24px" fill="#000000"><g><rect fill="none" height="24" width="24"/><g><path d="M19,5v14H5V5H19 M19,3H5C3.9,3,3,3.9,3,5v14c0,1.1,0.9,2,2,2h14c1.1,0,2-0.9,2-2V5C21,3.9,20.1,3,19,3L19,3z"/></g><path d="M14,17H7v-2h7V17z M17,13H7v-2h10V13z M17,9H7V7h10V9z"/></g></svg>';var c='<svg xmlns="http://www.w3.org/2000/svg" height="24px" viewBox="0 0 24 24" width="24px" fill="#000000"><path d="M0 0h24v24H0V0z" fill="none"/><path d="M8 16h8v2H8zm0-4h8v2H8zm6-10H6c-1.1 0-2 .9-2 2v16c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6zm4 18H6V4h7v5h5v11z"/></svg>';var s='verdocs-quick-functions{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif}verdocs-quick-functions .container{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-wrap:nowrap;flex-wrap:nowrap;width:240px;background-color:var(--verdocs-background-dark);text-transform:uppercase;padding:10px 10px 20px 10px;font-family:sans-serif;color:#ffffff}verdocs-quick-functions .title{font-size:22px;font-weight:700;line-height:30px;margin:1em 0 40px 0}verdocs-quick-functions button{width:140px;height:40px;border:none;display:-ms-flexbox;display:flex;color:#ffffff;cursor:pointer;font-size:14px;font-weight:700;line-height:25px;-ms-flex-align:center;align-items:center;margin-bottom:20px;border-radius:5px;text-transform:uppercase;-ms-flex-pack:space-evenly;justify-content:space-evenly;background-color:#50be50}verdocs-quick-functions button svg{fill:#ffffff}';var a=e("verdocs_quick_functions",function(){function e(e){t(this,e);this.createTemplate=n(this,"createTemplate",7);this.createDocument=n(this,"createDocument",7);this.endpoint=o.getDefault()}e.prototype.handleCreateTemplate=function(){this.createTemplate.emit()};e.prototype.handleCreateDocument=function(){this.createDocument.emit()};e.prototype.render=function(){var e=this;return i("div",{class:"container"},i("p",{class:"title"},"Quick Create"),i("button",{onClick:function(){return e.handleCreateTemplate()},innerHTML:r},"Template"),i("button",{onClick:function(){return e.handleCreateDocument()},innerHTML:c},"Document"))};return e}());a.style=s}}}));
@@ -0,0 +1 @@
1
+ var __awaiter=this&&this.__awaiter||function(e,t,n,i){function o(e){return e instanceof n?e:new n((function(t){t(e)}))}return new(n||(n=Promise))((function(n,r){function a(e){try{d(i.next(e))}catch(e){r(e)}}function s(e){try{d(i["throw"](e))}catch(e){r(e)}}function d(e){e.done?n(e.value):o(e.value).then(a,s)}d((i=i.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var n={label:0,sent:function(){if(r[0]&1)throw r[1];return r[1]},trys:[],ops:[]},i,o,r,a;return a={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(a[Symbol.iterator]=function(){return this}),a;function s(e){return function(t){return d([e,t])}}function d(a){if(i)throw new TypeError("Generator is already executing.");while(n)try{if(i=1,o&&(r=a[0]&2?o["return"]:a[0]?o["throw"]||((r=o["return"])&&r.call(o),0):o.next)&&!(r=r.call(o,a[1])).done)return r;if(o=0,r)a=[a[0]&2,r.value];switch(a[0]){case 0:case 1:r=a;break;case 4:n.label++;return{value:a[1],done:false};case 5:n.label++;o=a[1];a=[0];continue;case 7:a=n.ops.pop();n.trys.pop();continue;default:if(!(r=n.trys,r=r.length>0&&r[r.length-1])&&(a[0]===6||a[0]===2)){n=0;continue}if(a[0]===3&&(!r||a[1]>r[0]&&a[1]<r[3])){n.label=a[1];break}if(a[0]===6&&n.label<r[1]){n.label=r[1];r=a;break}if(r&&n.label<r[2]){n.label=r[2];n.ops.push(a);break}if(r[2])n.ops.pop();n.trys.pop();continue}a=t.call(e,n)}catch(e){a=[6,e];o=0}finally{i=r=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:true}}};System.register(["./p-caed7818.system.js","./p-4d80d044.system.js"],(function(e){"use strict";var t,n,i,o,r,a,s,d,l;return{setters:[function(e){t=e.r;n=e.h;i=e.H},function(e){o=e.V;r=e.g;a=e.a;s=e.u;d=e.b;l=e.c}],execute:function(){var c=new RegExp(/\+[1-9]\d{6,14}/g);function u(e){return e!==null&&e.length<16&&e.length>6&&c.test(e)||e===""||e===null}var p=/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;var h=function(e){return p.test(e)};var f=function(e){return u(e)};function g(e){switch(e%10){case 0:return e===0?"rgba(255, 193, 7, 0.4)":"rgba(134, 134, 134, 0.3)";case 1:return"rgba(156, 39, 176, .4)";case 2:return"rgba(33, 150, 243, .4)";case 3:return"rgba(220, 231, 117, 0.3)";case 4:return"rgba(121, 134, 203, 0.3)";case 5:return"rgba(77, 182, 172, 0.3)";case 6:return"rgba(255, 202, 165, 0.3)";case 7:return"rgba(2, 247, 190, 0.3)";case 8:return"rgba(255, 138, 101, 0.3)";case 9:return"rgba(82, 255, 79, 0.3)";default:return"rgba(229, 115, 155, 0.3)"}}function v(e,t){return e*t}var x='verdocs-sign{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif;position:relative;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;min-height:600px;-webkit-box-sizing:border-box;box-sizing:border-box;overflow:hidden}verdocs-sign.storybook{max-height:600px}verdocs-sign div{-webkit-box-sizing:border-box;box-sizing:border-box}verdocs-sign .header{-ms-flex:0 0 115px;flex:0 0 115px;z-index:1000;background-color:#33354c;-webkit-box-shadow:0 4px 4px 0 rgba(0, 0, 0, 0.24), 0 0 4px 0 rgba(0, 0, 0, 0.12);box-shadow:0 4px 4px 0 rgba(0, 0, 0, 0.24), 0 0 4px 0 rgba(0, 0, 0, 0.12);-webkit-transition:all 0.25s;transition:all 0.25s}verdocs-sign .intro{background-color:#ffffff;width:100%;margin:0 auto;padding:20px;max-width:1028px;color:rgba(0, 0, 0, 0.87)}verdocs-sign .toolbar{width:100%;margin:0 auto;padding:0 14px;max-width:1028px;position:relative}verdocs-sign .tools{width:100%;color:#fff;height:56px;padding:4px;display:-ms-flexbox;display:flex;font-size:12px;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;background-color:#33354c}verdocs-sign .cover{top:0;left:0;right:0;bottom:0;z-index:999;position:absolute;background:rgba(0, 0, 0, 0.5)}verdocs-sign .document{-ms-flex:1;flex:1;height:100%;position:relative;overflow-y:scroll}verdocs-sign .agree{-ms-flex:1;flex:1;-ms-flex-direction:row;flex-direction:row;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;margin-right:10px}verdocs-sign .agree .intro{display:none}verdocs-sign .agree .header{-ms-flex:0 0 56px;flex:0 0 56px}verdocs-sign .agree .agree-checkbox{background:#ccc;-ms-flex:0 0 20px;flex:0 0 20px;display:-ms-flexbox;display:flex;width:20px;height:20px;border-radius:3px;position:relative;margin:0 10px 0 14px}verdocs-sign .agree .agree-checkbox input[type=checkbox]:checked+label:after{filter:alpha(opacity=100);opacity:1}verdocs-sign .agree .agree-checkbox label{left:2px;top:2px;width:16px;height:16px;cursor:pointer;position:absolute;background:#33354c;-webkit-box-shadow:inset 0 -1px 1px rgba(255, 255, 255, 0.8);box-shadow:inset 0 -1px 1px rgba(255, 255, 255, 0.8)}verdocs-sign .agree .agree-checkbox label .agree-checkbox label:hover::after{filter:alpha(opacity=30);opacity:0.3}verdocs-sign .agree .agree-checkbox label:after{top:2px;left:3px;width:8px;opacity:0;height:5px;content:"";position:absolute;background:transparent;filter:alpha(opacity=0);-webkit-transform:rotate(-45deg);transform:rotate(-45deg);border:2px solid #fcfff4;border-top:none;border-right:none}verdocs-sign .page-controls{position:absolute;left:50%;-webkit-transform:translateX(-50%);transform:translateX(-50%);z-index:500}';var b=e("verdocs_sign",function(){function e(e){t(this,e);this.endpoint=o.getDefault();this.documentid=null;this.roleid=null;this.invitecode=null;this.recipient=null;this.signerToken=null;this.pdfUrl=null;this.recipientIndex=-1;this.document=null;this.fields=[];this.hasSignature=false;this.nextButtonLabel="Start";this.focusedField=""}e.prototype.componentDidLoad=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,n,i,o,s;var d=this;return __generator(this,(function(l){switch(l.label){case 0:l.trys.push([0,3,,4]);console.log("[SIGN] Processing invite code",this.documentid,this.roleid,this.invitecode);return[4,r(this.endpoint,{documentId:this.documentid,roleId:this.roleid,inviteCode:this.invitecode})];case 1:e=l.sent(),t=e.session,n=e.recipient,i=e.signerToken;console.log("[SIGN] Got signing session",t);console.log("[SIGN] Recipient",n);this.recipient=n;this.signerToken=i;this.endpoint.setToken(i);if(this.recipient.agreed){this.nextButtonLabel="Next"}return[4,a(this.endpoint,this.documentid)];case 2:o=l.sent();this.document=o;console.log("[SIGN] Document",o);this.pdfUrl="".concat(this.endpoint.getBaseURL(),"/documents/").concat(this.documentid,"/envelope_documents/").concat(o.envelope_document_id,"?file=true");this.recipientIndex=this.document.recipients.findIndex((function(e){return e.role_name==d.roleid}));if(this.recipientIndex>-1){console.log("Found recipient",this.document.recipients[this.recipientIndex])}this.fields=this.document.fields.filter((function(e){return e.recipient_role===d.roleid}));console.log("Loaded fields",this.fields);return[3,4];case 3:s=l.sent();console.log("Error with signing session",s);return[3,4];case 4:return[2]}}))}))};e.prototype.handleClickAgree=function(){var e=this;console.log("agree clicked");s(this.endpoint,this.documentid,this.roleid,"update",{agreed:true}).then((function(t){console.log("update result",t);e.nextButtonLabel="Next";e.recipient=t})).catch((function(e){console.log("update failure",e)}))};e.prototype.savePDF=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,n,i;return __generator(this,(function(o){switch(o.label){case 0:e="".concat(this.document.name," - ").concat(this.document.updated_at.split("T")[0],".pdf");return[4,d(this.endpoint,this.documentid,this.document.envelope_document_id)];case 1:t=o.sent();n=new XMLHttpRequest;n.responseType="blob";n.onload=function(){var t=document.createElement("a");t.href=window.URL.createObjectURL(n.response);t.download=e;t.style.display="none";document.body.appendChild(t);t.click();t.remove()};i="data:application/pdf;base64,".concat(t);console.log("url",i.length,i);n.open("GET","data:application/pdf;base64,".concat(t));n.send();return[2]}}))}))};e.prototype.handleOptionSelected=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){switch(e.detail.id){case"later":if(!(window===null||window===void 0?void 0:window["STORYBOOK_ENV"])){window.alert("User intends to sign later.")}break;case"claim":break;case"decline":break;case"print":break;case"download":this.savePDF().catch((function(){}));break}return[2]}))}))};e.prototype.handleFieldChange=function(e,t,n){return __awaiter(this,void 0,void 0,(function(){var i;return __generator(this,(function(o){console.log("fieldChange",e,t.detail);switch(e.type){case"textbox":l(this.endpoint,this.documentid,e.name,{prepared:false,value:t.detail}).then((function(e){return console.log("Update result",e)})).catch((function(e){return console.log("Error updating",e)}));break;case"checkbox_group":l(this.endpoint,this.documentid,e.name,{prepared:false,value:{options:[{id:n,checked:t.detail}]}}).then((function(e){return console.log("Update result",e)})).catch((function(e){return console.log("Error updating",e)}));break;case"radio_button_group":i=e.settings.options.map((function(e){return{id:e.id,selected:n===e.id}}));l(this.endpoint,this.documentid,e.name,{prepared:false,value:{options:i}}).then((function(e){return console.log("Update result",e)})).catch((function(e){return console.log("Error updating",e)}));break;case"dropdown":l(this.endpoint,this.documentid,e.name,{prepared:false,value:t.detail}).then((function(e){return console.log("Update result",e)})).catch((function(e){return console.log("Error updating",e)}));break;case"initial":console.log("Got initial",t.detail);break;case"signature":console.log("Got signature",t.detail);break}return[2]}))}))};e.prototype.renderCheckboxGroupOption=function(e,t,i,o){var r=this;var a=v(e.xRatio,i.x);var s=v(e.yRatio,i.y);var d={left:"".concat(a,"px"),bottom:"".concat(s,"px"),position:"absolute",transform:"scale(".concat(e.xRatio,", ").concat(e.yRatio,")"),backgroundColor:g(this.recipientIndex)};return n("verdocs-field-checkbox",{style:d,order:o,value:i.checked,onFieldChange:function(e){return r.handleFieldChange(t,e,i.id)}})};e.prototype.renderRadioGroupOption=function(e,t,i,o){var r=this;var a=v(e.xRatio,i.x);var s=v(e.yRatio,i.y);var d={left:"".concat(a,"px"),bottom:"".concat(s,"px"),position:"absolute",transform:"scale(".concat(e.xRatio,", ").concat(e.yRatio,")"),backgroundColor:g(this.recipientIndex)};return n("verdocs-field-radio-button",{style:d,order:o,value:i.id,name:t.name,checked:i.selected,onFieldChange:function(e){return r.handleFieldChange(t,e,i.id)}})};e.prototype.renderField=function(e,t){var i=this;var o=e.required,r=o===void 0?false:o,a=e.settings,s=a===void 0?{}:a;var d=s.x,l=d===void 0?0:d,c=s.y,u=c===void 0?0:c,p=s.base64,h=p===void 0?"":p,f=s.placeholder,x=f===void 0?"":f,b=s.options,m=b===void 0?[]:b,y=s.value,w=y===void 0?"":y,k=s.result,_=k===void 0?"":k;var I=this.pdfPageInfo.pages.find((function(t){return t.pageNumber===e.page}));if(!I){console.log("Unable to render invalid field",e);return n("div",{class:"invalid-field"},"Invalid field.")}var R=v(I.xRatio,l);var F=v(I.yRatio,u);var C={left:"".concat(R,"px"),bottom:"".concat(F,"px"),position:"absolute",transform:"scale(".concat(I.xRatio,", ").concat(I.yRatio,")"),backgroundColor:e.settings.rgba||g(this.recipientIndex)};if(e.settings.height){C.height="".concat(e.settings.height,"px")}if(e.settings.width){C.width="".concat(e.settings.width,"px")}console.log("rendering field",e.type,e);var S="field-".concat(e.name);switch(e.type){case"signature":return n("verdocs-field-signature",{style:C,value:h,required:r,id:S});case"initial":return n("verdocs-field-initial",{style:C,required:r,id:S});case"textbox":return n("verdocs-field-textbox",{style:C,order:t,value:_||"",placeholder:x,id:S,onFieldChange:function(t){return i.handleFieldChange(e,t)}});case"textarea":return n("verdocs-field-textarea",{style:C,placeholder:x||"",id:S});case"date":return n("verdocs-field-date",{style:C,order:t,value:_||"",placeholder:x,required:r,id:S});case"dropdown":return n("verdocs-field-dropdown",{style:C,options:m,value:w,required:r,id:S,onFieldChange:function(t){return i.handleFieldChange(e,t)}});case"checkbox":return n("verdocs-field-checkbox",{style:C,value:_||"",id:S});case"checkbox_group":return e.settings.options.map((function(t,n){return i.renderCheckboxGroupOption(I,e,t,n)}));case"radio_button_group":return e.settings.options.map((function(t,n){return i.renderRadioGroupOption(I,e,t,n)}));case"attachment":return n("verdocs-field-attachment",{style:C,value:_||"",id:S});case"payment":return n("verdocs-field-payment",{style:C,field:e,id:S});default:console.log("[SIGN] Skipping unsupported field type",e)}return n("div",{style:{display:"none"}},'Unsupported field type "',e.type,'"')};e.prototype.isFieldValid=function(e){var t,n,i,o,r,a,s,d,l,c,u,p;switch(e.type){case"textbox":switch(((t=e.settings)===null||t===void 0?void 0:t.validator)||""){case"email":return h(((n=e.settings)===null||n===void 0?void 0:n.result)||"");case"phone":return f(((i=e.settings)===null||i===void 0?void 0:i.result)||"");default:return!!((o=e.settings)===null||o===void 0?void 0:o.result)}case"signature":case"initial":case"textarea":case"date":case"attachment":return!!((r=e.settings)===null||r===void 0?void 0:r.result);case"dropdown":return!!((a=e.settings)===null||a===void 0?void 0:a.value);case"checkbox_group":var g=(((d=(s=e.settings)===null||s===void 0?void 0:s.options)===null||d===void 0?void 0:d.filter((function(e){return e.checked})))||[]).length;return g>=(((l=e.settings)===null||l===void 0?void 0:l.minimum_checked)||0)&&g<=(((c=e.settings)===null||c===void 0?void 0:c.maximum_checked)||999);case"radio_button_group":return(((p=(u=e.settings)===null||u===void 0?void 0:u.options)===null||p===void 0?void 0:p.filter((function(e){return e.selected})))||[]).length>0;default:return false}};e.prototype.handleDocumentRendered=function(e){console.log("[SIGN] Document rendered",e.detail);this.pdfPageInfo=e.detail};e.prototype.handleNext=function(){var e=this;var t=this.fields.filter((function(e){return e.required}));console.log("required Fields",t);var n=t.findIndex((function(t){return t.name===e.focusedField}));console.log("focused Index",n);var i=n+1;if(i>=t.length){i=0}var o=t[i];console.log("next required fielod",o);if(o){var r=document.getElementById("field-".concat(o.name));r===null||r===void 0?void 0:r.focusField();this.focusedField=o.name}};e.prototype.render=function(){var e=this;var t,o,r,a,s;var d=[{id:"later",label:"Finish Later"},{id:"claim",label:"Claim the Document",disabled:true},{id:"decline",label:"Decline to Sign"},{id:"print",label:"Print Without Signing"},{id:"download",label:"Download"}];return n(i,{class:{storybook:!!(window===null||window===void 0?void 0:window["STORYBOOK_ENV"]),agreed:(t=this.recipient)===null||t===void 0?void 0:t.agreed}},n("div",{class:"header"},n("div",{class:"intro"},"Please review and act on these documents."),n("div",{class:"toolbar"},n("div",{class:"tools"},n("verdocs-dropdown",{options:d,onOptionSelected:function(t){return e.handleOptionSelected(t)}}),!((o=this.recipient)===null||o===void 0?void 0:o.agreed)?n("div",{class:"agree"},n("div",{class:"agree-checkbox"},n("input",{type:"checkbox",value:"None",id:"agree-checkbox-element",name:"agree",onChange:function(){return e.handleClickAgree()}}),n("label",{htmlFor:"agree-checkbox-element"})),n("span",null,"I agree to use electronic records and signatures.")):n("div",{style:{flex:"1"}}),n("verdocs-button",{size:"small",label:this.nextButtonLabel,disabled:!((r=this.recipient)===null||r===void 0?void 0:r.agreed),onClick:function(){return e.handleNext()}})))),!((a=this.recipient)===null||a===void 0?void 0:a.agreed)?n("div",{class:"cover"}):n("div",{style:{display:"none"}}),n("div",{class:"document"},this.pdfUrl?n("verdocs-view",{source:this.pdfUrl,token:this.signerToken,onDocumentRendered:function(t){return e.handleDocumentRendered(t)}}):n("verdocs-loader",null),(((s=this.pdfPageInfo)===null||s===void 0?void 0:s.pages)||[]).map((function(t){var i;return n("div",{class:"page-controls",style:{height:"".concat(t.height,"px"),width:"".concat(t.width,"px"),top:"".concat(t.canvasTop,"px"),margin:"0 auto"}},((i=e.pdfPageInfo)===null||i===void 0?void 0:i.numRendered)>0?e.fields.filter((function(e){return e.page===t.pageNumber})).map((function(t,n){return e.renderField(t,n)})):n("div",{style:{display:"none"}},"Waiting for PDF to render..."))}))))};return e}());b.style=x}}}));
@@ -0,0 +1 @@
1
+ import{r as e,c as t,h as i}from"./p-2bc58746.js";import{V as r}from"./p-06f38046.js";var s=function(e){return t=void 0,i=void 0,s=function(){return function(e,t){var i,r,s,o,n={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:c(0),throw:c(1),return:c(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function c(o){return function(c){return function(o){if(i)throw new TypeError("Generator is already executing.");for(;n;)try{if(i=1,r&&(s=2&o[0]?r.return:o[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,o[1])).done)return s;switch(r=0,s&&(o=[2&o[0],s.value]),o[0]){case 0:case 1:s=o;break;case 4:return n.label++,{value:o[1],done:!1};case 5:n.label++,r=o[1],o=[0];continue;case 7:o=n.ops.pop(),n.trys.pop();continue;default:if(!((s=(s=n.trys).length>0&&s[s.length-1])||6!==o[0]&&2!==o[0])){n=0;continue}if(3===o[0]&&(!s||o[1]>s[0]&&o[1]<s[3])){n.label=o[1];break}if(6===o[0]&&n.label<s[1]){n.label=s[1],s=o;break}if(s&&n.label<s[2]){n.label=s[2],n.ops.push(o);break}s[2]&&n.ops.pop(),n.trys.pop();continue}o=t.call(e,n)}catch(e){o=[6,e],r=0}finally{i=s=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,c])}}}(this,(function(){return[2,e.api.get("/search/history").then((function(e){return e.data}))]}))},new((r=void 0)||(r=Promise))((function(e,o){function n(e){try{a(s.next(e))}catch(e){o(e)}}function c(e){try{a(s.throw(e))}catch(e){o(e)}}function a(t){var i;t.done?e(t.value):(i=t.value,i instanceof r?i:new r((function(e){e(i)}))).then(n,c)}a((s=s.apply(t,i||[])).next())}));var t,i,r,s};const o='<svg xmlns="http://www.w3.org/2000/svg" height="24px" viewBox="0 0 24 24" width="24px" fill="#000000"><path d="M0 0h24v24H0V0z" fill="none"/><path d="M8 16h8v2H8zm0-4h8v2H8zm6-10H6c-1.1 0-2 .9-2 2v16c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6zm4 18H6V4h7v5h5v11z"/></svg>',n=class{constructor(i){e(this,i),this.entrySelected=t(this,"entrySelected",7),this.endpoint=r.getDefault(),this.type="recent",this.emptyMessage="You do not have any starred searches.",this.authFailure=!1,this.title="Recent Searches",this.recent=[],this.saved=[],this.starred=[]}componentWillLoad(){this.endpoint.loadSession();const e=e=>{var t;console.warn("[Verdocs/search-activity] Error getting search data",e),401===(null===(t=null==e?void 0:e.response)||void 0===t?void 0:t.status)&&(this.authFailure=!0)};switch(this.type){case"recent":this.title="Recent Searches",this.emptyMessage="You do not have any recent searches.",s(this.endpoint).then((e=>this.recent=e.recent)).catch(e);break;case"saved":this.title="Saved Searches",this.emptyMessage="You do not have any saved searches.",s(this.endpoint).then((e=>this.saved=e.saved)).catch(e);break;case"starred":this.title="My Starred items",this.emptyMessage="You do not have any starred templates.",(t=this.endpoint,i={is_starred:!0},t.api.get("/templates/",{params:i}).then((function(e){return e.data}))).then((e=>this.starred=e)).catch(e)}var t,i}handleSelectEntry(e){this.entrySelected.emit(e)}computePagesText(e){return e<2?`${e} Page`:`${e} Pages`}computeRecipientsText(e){return"object"==typeof e?e.join(", "):e>1?`${e} Recipients`:`${e} Recipient`}render(){const e=this.recent.length<1&&this.saved.length<1&&this.starred.length<1;return i("div",{class:"container"},i("p",{class:"title"},this.title),i("div",{class:"items"},this.recent.map((e=>i("button",{class:"item",onClick:()=>this.handleSelectEntry(e)},i("div",{class:"icon",innerHTML:o}),i("div",{class:"details"},i("div",{class:"item-title"},e.params.q),i("div",{class:"info"},"Test"))))),this.saved.map((e=>i("button",{class:"item",onClick:()=>this.handleSelectEntry(e)},i("div",{class:"icon",innerHTML:o}),i("div",{class:"details"},i("div",{class:"item-title"},e.params.q),i("div",{class:"info"}))))),e&&i("div",{class:"empty"},this.authFailure?"Authentication required":this.emptyMessage)))}};n.style='verdocs-search-activity{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif}verdocs-search-activity .container{display:-ms-flexbox;display:flex;width:240px;color:#ffffff;-ms-flex-direction:column;flex-direction:column;text-transform:uppercase;padding:10px 10px 20px 10px;background-color:var(--verdocs-background-dark)}verdocs-search-activity .title{font-size:22px;font-weight:700;line-height:30px}verdocs-search-activity .items{display:-ms-flexbox;display:flex;margin-top:20px;-ms-flex-direction:column;flex-direction:column}verdocs-search-activity .item{border:none;display:-ms-flexbox;display:flex;text-align:left;margin-bottom:20px;-ms-flex-direction:row;flex-direction:row;background:transparent}verdocs-search-activity .item:hover{cursor:pointer}verdocs-search-activity .icon{-ms-flex:0 0 22px;flex:0 0 22px;margin-right:14px}verdocs-search-activity .icon svg{fill:#707ae5;width:22px;height:22px}verdocs-search-activity .details{display:-ms-flexbox;display:flex;overflow:hidden;-ms-flex-direction:column;flex-direction:column}verdocs-search-activity .item-title{font-size:16px;font-weight:400;color:#ffffff;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}verdocs-search-activity .info{font-size:14px;font-weight:500;line-height:23px;color:#aeb4bf}verdocs-search-activity .empty{text-transform:none;line-height:22px;color:#ccc}';const c=class{constructor(i){e(this,i),this.searchClicked=t(this,"searchClicked",7),this.typeChanged=t(this,"typeChanged",7),this.queryChanged=t(this,"queryChanged",7),this.endpoint=r.getDefault(),this.placeholder="search documents, templates, people...",this.type="all",this.query=""}handleSearch(e){return this.searchClicked.emit({type:this.type,query:this.query}),e.preventDefault(),!1}handleChange(e){this.queryChanged.emit(e.target.value)}handleClearFilter(){this.typeChanged.emit("all")}handleKeyUp(e){"Enter"===e.key&&this.searchClicked.emit({type:this.type,query:this.query})}render(){return i("form",{onSubmit:e=>this.handleSearch(e)},void 0!==this.type&&"all"!==this.type&&i("span",{class:"type"},this.type,"s ",i("button",{class:"remove",innerHTML:'<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">\n<path d="M14.0739 11.7565L19.7127 6.23228C20.0875 5.85692 20.0875 5.25309 19.7127 4.87773L19.0213 4.20046C18.6382 3.82511 18.0219 3.82511 17.6387 4.20046L12 9.72472L6.36127 4.20046C5.97814 3.82511 5.36179 3.82511 4.97866 4.20046L4.28735 4.87773C3.90422 5.25309 3.90422 5.85692 4.28735 6.23228L9.92608 11.7565L4.28735 17.2808C3.90422 17.6561 3.90422 18.26 4.28735 18.6353L4.97866 19.3126C5.36179 19.688 5.97814 19.688 6.36127 19.3126L12 13.7883L17.6387 19.3126C18.0219 19.688 18.6382 19.688 19.0213 19.3126L19.7127 18.6353C20.0958 18.26 20.0958 17.6561 19.7127 17.2808L14.0739 11.7565Z" fill="white"/>\n</svg>\n',onClick:()=>this.handleClearFilter()})),i("input",{type:"text",placeholder:this.placeholder,value:this.query,onInput:e=>this.handleChange(e),onKeyUp:e=>this.handleKeyUp(e)}),i("button",{onClick:e=>this.handleSearch(e),class:"search"},i("span",{innerHTML:'<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">\n<path d="M23.4809 20.7176L17.9111 15.2536C19.0961 13.6368 19.727 11.6926 19.7128 9.70131C19.7201 7.53345 18.9846 5.42606 17.6244 3.71753C16.2642 2.009 14.3581 0.798456 12.2123 0.280282C10.0665 -0.237892 7.80552 -0.0336342 5.79227 0.86026C3.77902 1.75415 2.13038 3.28582 1.1111 5.20931C0.0918114 7.1328 -0.238985 9.33652 0.171813 11.4666C0.582612 13.5967 1.71117 15.5296 3.37628 16.9548C5.0414 18.3801 7.14646 19.2151 9.35344 19.3257C11.5604 19.4364 13.7413 18.8162 15.5458 17.5649L21.1372 23.05L21.1563 23.0663C21.4841 23.3487 21.9039 23.507 22.3401 23.5128C22.7823 23.5125 23.2063 23.3402 23.5191 23.0337V23.0337C23.6749 22.8812 23.7979 22.6995 23.8804 22.4993C23.963 22.2991 24.0036 22.0847 23.9997 21.8688C23.9959 21.6529 23.9477 21.44 23.858 21.2428C23.7683 21.0456 23.639 20.8682 23.4778 20.7212L23.4809 20.7176ZM14.5167 14.1975C13.4564 15.2349 12.0623 15.8797 10.5719 16.022C9.08145 16.1644 7.58681 15.7955 6.34249 14.9781C5.09816 14.1608 4.18109 12.9456 3.74751 11.5395C3.31393 10.1334 3.39064 8.6233 3.96455 7.26643C4.53846 5.90955 5.57409 4.7898 6.89507 4.09787C8.21606 3.40594 9.74071 3.18461 11.2093 3.4716C12.678 3.75858 13.9998 4.53612 14.9497 5.6718C15.8996 6.80748 16.4188 8.23105 16.4189 9.7001C16.4196 10.5357 16.2519 11.3632 15.9254 12.135C15.599 12.9069 15.1202 13.6078 14.5167 14.1975V14.1975Z" fill="white"/>\n</svg>\n'}),"Search"))}};c.style='verdocs-search-box{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif}verdocs-search-box form{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;height:45px;-webkit-box-sizing:border-box;box-sizing:border-box;margin:5px 0 0;border-radius:5px;-ms-flex-align:center;align-items:center;background-color:#fff;padding:0 8px;border-width:1px;border-style:solid;border-color:var(--verdocs-container-border-color)}verdocs-search-box form input{-webkit-box-sizing:border-box;box-sizing:border-box;height:43px;width:100%;font-size:18px;border:none}verdocs-search-box form input:focus{outline:none}verdocs-search-box form button.search{cursor:pointer;display:-ms-inline-flexbox;display:inline-flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;-webkit-box-sizing:border-box;box-sizing:border-box;border-radius:4px;border:none;width:100px;height:28px;font-weight:700;font-size:10px;letter-spacing:1px;background-color:#50be80;text-transform:uppercase;color:#fff}verdocs-search-box form .type{background-color:#707ae5;height:30px;display:-ms-inline-flexbox;display:inline-flex;padding:1px 0 2px 10px;font-size:13px;line-height:16px;border-radius:4px;-ms-flex-pack:center;justify-content:center;text-transform:uppercase;-ms-flex-align:center;align-items:center;-ms-flex-direction:row;flex-direction:row;color:#fff;margin-right:10px}verdocs-search-box form .type button{border:none;color:#fff;margin:5px 0 0 8px;background:transparent}verdocs-search-box form svg{width:12px;height:12px;margin-right:6px}verdocs-search-box ::-webkit-input-placeholder{color:#aeb4bf}verdocs-search-box ::-moz-placeholder{color:#aeb4bf}verdocs-search-box :-ms-input-placeholder{color:#aeb4bf}verdocs-search-box ::-ms-input-placeholder{color:#aeb4bf}verdocs-search-box ::placeholder{color:#aeb4bf}';export{n as verdocs_search_activity,c as verdocs_search_box}
@@ -0,0 +1 @@
1
+ import{r as e,h as s}from"./p-2bc58746.js";import{V as r}from"./p-06f38046.js";const c=class{constructor(s){e(this,s),this.endpoint=r.getDefault()}render(){return s("div",{class:"container"},s("verdocs-search-box",{endpoint:this.endpoint}),s("div",{class:"boxes"},s("verdocs-search-activity",{type:"recent",endpoint:this.endpoint}),s("verdocs-search-activity",{type:"saved",endpoint:this.endpoint}),s("verdocs-search-activity",{type:"starred",endpoint:this.endpoint}),s("search-quick-functions",{endpoint:this.endpoint})))}};c.style='verdocs-search{font-family:"Inter", -apple-system, "Segoe UI", "Roboto", "Helvetica Neue", sans-serif;display:-ms-flexbox;display:flex;background-color:#1e2031}verdocs-search search-box{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;margin:20px 10px}verdocs-search .boxes{-ms-flex-wrap:wrap;flex-wrap:wrap;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;margin:20px 0}verdocs-search search-recent,verdocs-search search-saved,verdocs-search search-quick-functions,verdocs-search search-starred{display:-ms-flexbox;display:flex;margin:0 20px 20px 0}';export{c as verdocs_search}