@verdocs/web-sdk 4.2.12 → 4.2.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/verdocs-auth.cjs.entry.js +3 -3
- package/dist/collection/components/embeds/verdocs-auth/verdocs-auth.css +11 -0
- package/dist/collection/components/embeds/verdocs-auth/verdocs-auth.js +2 -2
- package/dist/components/verdocs-auth.js +3 -3
- package/dist/esm/verdocs-auth.entry.js +3 -3
- package/dist/esm-es5/verdocs-auth.entry.js +1 -1
- package/dist/verdocs-web-sdk/p-322fa613.system.js +1 -1
- package/dist/verdocs-web-sdk/{p-18363901.entry.js → p-3d0ceb71.entry.js} +1 -1
- package/dist/verdocs-web-sdk/p-dd426399.system.entry.js +1 -0
- package/dist/verdocs-web-sdk/verdocs-web-sdk.esm.js +1 -1
- package/package.json +1 -1
- package/dist/custom-elements.json +0 -2086
- package/dist/verdocs-web-sdk/p-f0299a13.system.entry.js +0 -1
@@ -7,7 +7,7 @@ const jsSdk = require('@verdocs/js-sdk');
|
|
7
7
|
const Toast = require('./Toast-bb6f20af.js');
|
8
8
|
const errors = require('./errors-017fb835.js');
|
9
9
|
|
10
|
-
const verdocsAuthCss = "@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-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 .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 h4 verdocs-button button.normal .button-label{padding:0}verdocs-auth .buttons{gap:20px;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth .status-result{display:none}verdocs-auth .status-result.debug{white-space:pre-wrap;font-size:14px;background:#fff;padding:10px;display:block;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth form{width:100%}verdocs-auth verdocs-text-input{margin-bottom:10px}verdocs-auth .account-option{gap:8px;margin:20px 0 8px 0;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-auth p+p{margin-top:0}verdocs-auth verdocs-help-icon{margin-top:18px;display:-ms-flexbox;display:flex;width:32px;height:32px;-ms-flex:0 0 32px;flex:0 0 32px}";
|
10
|
+
const verdocsAuthCss = "@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-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 .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 h4 verdocs-button button.normal .button-label{padding:0}verdocs-auth h6{text-align:center;font-weight:500;font-size:16px;line-height:1.75;margin:0 0 20px 0}verdocs-auth em{font-size:14px;margin:15px 0}verdocs-auth .buttons{gap:20px;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth .status-result{display:none}verdocs-auth .status-result.debug{white-space:pre-wrap;font-size:14px;background:#fff;padding:10px;display:block;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth form{width:100%}verdocs-auth verdocs-text-input{margin-bottom:10px}verdocs-auth .account-option{gap:8px;margin:20px 0 8px 0;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-auth p+p{margin-top:0}verdocs-auth verdocs-help-icon{margin-top:18px;display:-ms-flexbox;display:flex;width:32px;height:32px;-ms-flex:0 0 32px;flex:0 0 32px}";
|
11
11
|
const VerdocsAuthStyle0 = verdocsAuthCss;
|
12
12
|
|
13
13
|
const RECHECK_INTERVAL = 5000;
|
@@ -202,7 +202,7 @@ const VerdocsAuth = class {
|
|
202
202
|
}
|
203
203
|
if (this.displayMode === 'signup') {
|
204
204
|
const step1Invalid = this.submitting || !this.first_name || !this.last_name || !this.username || !this.password || !this.org_name;
|
205
|
-
return (index.h("div", { class: "form" }, index.h("a", { href: "https://verdocs.com/en/" }, index.h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" })), index.h("h3", null, "Sign up for a free account"), index.h("
|
205
|
+
return (index.h("div", { class: "form" }, index.h("a", { href: "https://verdocs.com/en/" }, index.h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" })), index.h("h3", null, "Sign up for a free account"), index.h("h5", null, "Already have an account?", index.h("verdocs-button", { label: "Log In", variant: "text", onClick: () => (this.displayMode = 'login'), disabled: this.submitting })), this.signupStep === 1 && (index.h("form", { onSubmit: () => this.handleSignup() }, index.h("div", { style: { display: 'flex', flexDirection: 'row', columnGap: '20px' } }, index.h("verdocs-text-input", { label: "First Name", autocomplete: "first", required: true, value: this.first_name, onInput: (e) => (this.first_name = e.target.value), disabled: this.submitting }), index.h("verdocs-text-input", { label: "Last Name", autocomplete: "last", required: true, value: this.last_name, onInput: (e) => (this.last_name = e.target.value), disabled: this.submitting })), index.h("verdocs-text-input", { label: "Email Address", autocomplete: "email", required: true, value: this.username, onInput: (e) => (this.username = e.target.value), disabled: this.submitting }), index.h("verdocs-text-input", { label: "Password", type: "password", required: true, autocomplete: "current-password", value: this.password, onInput: (e) => (this.password = e.target.value), disabled: this.submitting }), index.h("verdocs-text-input", { label: "Organization Name", autocomplete: "org", required: true, value: this.org_name, onInput: (e) => (this.org_name = e.target.value), disabled: this.submitting, style: { flex: '1' } }), index.h("div", { style: { marginTop: '30px' } }), index.h("verdocs-button", { label: "Next", disabled: step1Invalid, onClick: () => this.handleSignup(), style: { display: 'flex', justifyContent: 'center', margin: '30px auto 0' } }))), this.signupStep === 3 && (index.h("form", { onSubmit: () => this.handleSignup() }, index.h("p", null, "Please check your e-mail inbox for a verification code and follow the instructions provided."), index.h("p", null, index.h("em", null, "Verification messages may take up to 1 hour to arrive. If you do not receive the invitation, ", index.h("a", { href: "#" }, "Click Here"), " to resend it. Be sure to check your spam folder.")), index.h("div", { style: { display: 'flex', flexDirection: 'row', gap: '20px' } }, index.h("verdocs-button", { label: "Back", disabled: this.submitting, onClick: () => {
|
206
206
|
this.signupStep = 2;
|
207
207
|
}, style: { display: 'flex', justifyContent: 'center', margin: '30px auto 0' } }), index.h("verdocs-button", { label: "Go to Dashboard", disabled: true, onClick: () => this.handleSignup(), style: { display: 'flex', justifyContent: 'center', margin: '30px auto 0' } }))))));
|
208
208
|
}
|
@@ -210,7 +210,7 @@ const VerdocsAuth = class {
|
|
210
210
|
return (index.h("div", { class: "form" }, index.h("a", { href: "https://verdocs.com/en/" }, index.h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" })), index.h("h3", null, "Forgot your password?"), index.h("p", null, "Enter your e-mail address below, and reset instructions will be sent to your Inbox."), index.h("p", null, index.h("em", null, "Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")), index.h("form", { onSubmit: () => this.handleSignup() }, index.h("verdocs-text-input", { label: "Email", autocomplete: "email", required: true, value: this.username, onInput: (e) => (this.username = e.target.value), disabled: this.submitting }), index.h("div", { style: { marginTop: '30px' } }), index.h("div", { class: "buttons" }, index.h("verdocs-button", { label: "Cancel", variant: "outline", disabled: this.submitting, onClick: () => (this.displayMode = 'login') }), index.h("verdocs-button", { label: "Reset", disabled: this.submitting, onClick: () => this.handleReset() })))));
|
211
211
|
}
|
212
212
|
if (this.displayMode === 'verify') {
|
213
|
-
return (index.h("div", { class: "form" }, index.h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" }), index.h("
|
213
|
+
return (index.h("div", { class: "form" }, index.h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" }), index.h("h6", null, "Please Verify your Email Address"), index.h("p", null, "Check your e-mail inbox for a verification email, and follow the instructions provided."), index.h("p", null, index.h("em", null, "Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")), index.h("div", { class: "buttons" }, index.h("verdocs-button", { label: "Sign Out", variant: "outline", disabled: this.submitting, onClick: () => {
|
214
214
|
this.username = '';
|
215
215
|
this.password = '';
|
216
216
|
this.cancelRecheckTimer();
|
@@ -48,6 +48,17 @@ verdocs-auth h4 {
|
|
48
48
|
verdocs-auth h4 verdocs-button button.normal .button-label {
|
49
49
|
padding: 0;
|
50
50
|
}
|
51
|
+
verdocs-auth h6 {
|
52
|
+
text-align: center;
|
53
|
+
font-weight: 500;
|
54
|
+
font-size: 16px;
|
55
|
+
line-height: 1.75;
|
56
|
+
margin: 0 0 20px 0;
|
57
|
+
}
|
58
|
+
verdocs-auth em {
|
59
|
+
font-size: 14px;
|
60
|
+
margin: 15px 0;
|
61
|
+
}
|
51
62
|
verdocs-auth .buttons {
|
52
63
|
gap: 20px;
|
53
64
|
display: flex;
|
@@ -206,7 +206,7 @@ export class VerdocsAuth {
|
|
206
206
|
}
|
207
207
|
if (this.displayMode === 'signup') {
|
208
208
|
const step1Invalid = this.submitting || !this.first_name || !this.last_name || !this.username || !this.password || !this.org_name;
|
209
|
-
return (h("div", { class: "form" }, h("a", { href: "https://verdocs.com/en/" }, h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" })), h("h3", null, "Sign up for a free account"), h("
|
209
|
+
return (h("div", { class: "form" }, h("a", { href: "https://verdocs.com/en/" }, h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" })), h("h3", null, "Sign up for a free account"), h("h5", null, "Already have an account?", h("verdocs-button", { label: "Log In", variant: "text", onClick: () => (this.displayMode = 'login'), disabled: this.submitting })), this.signupStep === 1 && (h("form", { onSubmit: () => this.handleSignup() }, h("div", { style: { display: 'flex', flexDirection: 'row', columnGap: '20px' } }, h("verdocs-text-input", { label: "First Name", autocomplete: "first", required: true, value: this.first_name, onInput: (e) => (this.first_name = e.target.value), disabled: this.submitting }), h("verdocs-text-input", { label: "Last Name", autocomplete: "last", required: true, value: this.last_name, onInput: (e) => (this.last_name = e.target.value), disabled: this.submitting })), h("verdocs-text-input", { label: "Email Address", autocomplete: "email", required: true, value: this.username, onInput: (e) => (this.username = e.target.value), disabled: this.submitting }), h("verdocs-text-input", { label: "Password", type: "password", required: true, autocomplete: "current-password", value: this.password, onInput: (e) => (this.password = e.target.value), disabled: this.submitting }), h("verdocs-text-input", { label: "Organization Name", autocomplete: "org", required: true, value: this.org_name, onInput: (e) => (this.org_name = e.target.value), disabled: this.submitting, style: { flex: '1' } }), h("div", { style: { marginTop: '30px' } }), h("verdocs-button", { label: "Next", disabled: step1Invalid, onClick: () => this.handleSignup(), style: { display: 'flex', justifyContent: 'center', margin: '30px auto 0' } }))), this.signupStep === 3 && (h("form", { onSubmit: () => this.handleSignup() }, h("p", null, "Please check your e-mail inbox for a verification code and follow the instructions provided."), h("p", null, h("em", null, "Verification messages may take up to 1 hour to arrive. If you do not receive the invitation, ", h("a", { href: "#" }, "Click Here"), " to resend it. Be sure to check your spam folder.")), h("div", { style: { display: 'flex', flexDirection: 'row', gap: '20px' } }, h("verdocs-button", { label: "Back", disabled: this.submitting, onClick: () => {
|
210
210
|
this.signupStep = 2;
|
211
211
|
}, style: { display: 'flex', justifyContent: 'center', margin: '30px auto 0' } }), h("verdocs-button", { label: "Go to Dashboard", disabled: true, onClick: () => this.handleSignup(), style: { display: 'flex', justifyContent: 'center', margin: '30px auto 0' } }))))));
|
212
212
|
}
|
@@ -214,7 +214,7 @@ export class VerdocsAuth {
|
|
214
214
|
return (h("div", { class: "form" }, h("a", { href: "https://verdocs.com/en/" }, h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" })), h("h3", null, "Forgot your password?"), h("p", null, "Enter your e-mail address below, and reset instructions will be sent to your Inbox."), h("p", null, h("em", null, "Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")), h("form", { onSubmit: () => this.handleSignup() }, h("verdocs-text-input", { label: "Email", autocomplete: "email", required: true, value: this.username, onInput: (e) => (this.username = e.target.value), disabled: this.submitting }), h("div", { style: { marginTop: '30px' } }), h("div", { class: "buttons" }, h("verdocs-button", { label: "Cancel", variant: "outline", disabled: this.submitting, onClick: () => (this.displayMode = 'login') }), h("verdocs-button", { label: "Reset", disabled: this.submitting, onClick: () => this.handleReset() })))));
|
215
215
|
}
|
216
216
|
if (this.displayMode === 'verify') {
|
217
|
-
return (h("div", { class: "form" }, h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" }), h("
|
217
|
+
return (h("div", { class: "form" }, h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" }), h("h6", null, "Please Verify your Email Address"), h("p", null, "Check your e-mail inbox for a verification email, and follow the instructions provided."), h("p", null, h("em", null, "Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")), h("div", { class: "buttons" }, h("verdocs-button", { label: "Sign Out", variant: "outline", disabled: this.submitting, onClick: () => {
|
218
218
|
this.username = '';
|
219
219
|
this.password = '';
|
220
220
|
this.cancelRecheckTimer();
|
@@ -6,7 +6,7 @@ import { d as defineCustomElement$4 } from './verdocs-button2.js';
|
|
6
6
|
import { d as defineCustomElement$3 } from './verdocs-help-icon2.js';
|
7
7
|
import { d as defineCustomElement$2 } from './verdocs-text-input2.js';
|
8
8
|
|
9
|
-
const verdocsAuthCss = "@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-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 .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 h4 verdocs-button button.normal .button-label{padding:0}verdocs-auth .buttons{gap:20px;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth .status-result{display:none}verdocs-auth .status-result.debug{white-space:pre-wrap;font-size:14px;background:#fff;padding:10px;display:block;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth form{width:100%}verdocs-auth verdocs-text-input{margin-bottom:10px}verdocs-auth .account-option{gap:8px;margin:20px 0 8px 0;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-auth p+p{margin-top:0}verdocs-auth verdocs-help-icon{margin-top:18px;display:-ms-flexbox;display:flex;width:32px;height:32px;-ms-flex:0 0 32px;flex:0 0 32px}";
|
9
|
+
const verdocsAuthCss = "@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-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 .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 h4 verdocs-button button.normal .button-label{padding:0}verdocs-auth h6{text-align:center;font-weight:500;font-size:16px;line-height:1.75;margin:0 0 20px 0}verdocs-auth em{font-size:14px;margin:15px 0}verdocs-auth .buttons{gap:20px;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth .status-result{display:none}verdocs-auth .status-result.debug{white-space:pre-wrap;font-size:14px;background:#fff;padding:10px;display:block;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth form{width:100%}verdocs-auth verdocs-text-input{margin-bottom:10px}verdocs-auth .account-option{gap:8px;margin:20px 0 8px 0;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-auth p+p{margin-top:0}verdocs-auth verdocs-help-icon{margin-top:18px;display:-ms-flexbox;display:flex;width:32px;height:32px;-ms-flex:0 0 32px;flex:0 0 32px}";
|
10
10
|
const VerdocsAuthStyle0 = verdocsAuthCss;
|
11
11
|
|
12
12
|
const RECHECK_INTERVAL = 5000;
|
@@ -202,7 +202,7 @@ const VerdocsAuth$1 = /*@__PURE__*/ proxyCustomElement(class VerdocsAuth extends
|
|
202
202
|
}
|
203
203
|
if (this.displayMode === 'signup') {
|
204
204
|
const step1Invalid = this.submitting || !this.first_name || !this.last_name || !this.username || !this.password || !this.org_name;
|
205
|
-
return (h("div", { class: "form" }, h("a", { href: "https://verdocs.com/en/" }, h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" })), h("h3", null, "Sign up for a free account"), h("
|
205
|
+
return (h("div", { class: "form" }, h("a", { href: "https://verdocs.com/en/" }, h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" })), h("h3", null, "Sign up for a free account"), h("h5", null, "Already have an account?", h("verdocs-button", { label: "Log In", variant: "text", onClick: () => (this.displayMode = 'login'), disabled: this.submitting })), this.signupStep === 1 && (h("form", { onSubmit: () => this.handleSignup() }, h("div", { style: { display: 'flex', flexDirection: 'row', columnGap: '20px' } }, h("verdocs-text-input", { label: "First Name", autocomplete: "first", required: true, value: this.first_name, onInput: (e) => (this.first_name = e.target.value), disabled: this.submitting }), h("verdocs-text-input", { label: "Last Name", autocomplete: "last", required: true, value: this.last_name, onInput: (e) => (this.last_name = e.target.value), disabled: this.submitting })), h("verdocs-text-input", { label: "Email Address", autocomplete: "email", required: true, value: this.username, onInput: (e) => (this.username = e.target.value), disabled: this.submitting }), h("verdocs-text-input", { label: "Password", type: "password", required: true, autocomplete: "current-password", value: this.password, onInput: (e) => (this.password = e.target.value), disabled: this.submitting }), h("verdocs-text-input", { label: "Organization Name", autocomplete: "org", required: true, value: this.org_name, onInput: (e) => (this.org_name = e.target.value), disabled: this.submitting, style: { flex: '1' } }), h("div", { style: { marginTop: '30px' } }), h("verdocs-button", { label: "Next", disabled: step1Invalid, onClick: () => this.handleSignup(), style: { display: 'flex', justifyContent: 'center', margin: '30px auto 0' } }))), this.signupStep === 3 && (h("form", { onSubmit: () => this.handleSignup() }, h("p", null, "Please check your e-mail inbox for a verification code and follow the instructions provided."), h("p", null, h("em", null, "Verification messages may take up to 1 hour to arrive. If you do not receive the invitation, ", h("a", { href: "#" }, "Click Here"), " to resend it. Be sure to check your spam folder.")), h("div", { style: { display: 'flex', flexDirection: 'row', gap: '20px' } }, h("verdocs-button", { label: "Back", disabled: this.submitting, onClick: () => {
|
206
206
|
this.signupStep = 2;
|
207
207
|
}, style: { display: 'flex', justifyContent: 'center', margin: '30px auto 0' } }), h("verdocs-button", { label: "Go to Dashboard", disabled: true, onClick: () => this.handleSignup(), style: { display: 'flex', justifyContent: 'center', margin: '30px auto 0' } }))))));
|
208
208
|
}
|
@@ -210,7 +210,7 @@ const VerdocsAuth$1 = /*@__PURE__*/ proxyCustomElement(class VerdocsAuth extends
|
|
210
210
|
return (h("div", { class: "form" }, h("a", { href: "https://verdocs.com/en/" }, h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" })), h("h3", null, "Forgot your password?"), h("p", null, "Enter your e-mail address below, and reset instructions will be sent to your Inbox."), h("p", null, h("em", null, "Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")), h("form", { onSubmit: () => this.handleSignup() }, h("verdocs-text-input", { label: "Email", autocomplete: "email", required: true, value: this.username, onInput: (e) => (this.username = e.target.value), disabled: this.submitting }), h("div", { style: { marginTop: '30px' } }), h("div", { class: "buttons" }, h("verdocs-button", { label: "Cancel", variant: "outline", disabled: this.submitting, onClick: () => (this.displayMode = 'login') }), h("verdocs-button", { label: "Reset", disabled: this.submitting, onClick: () => this.handleReset() })))));
|
211
211
|
}
|
212
212
|
if (this.displayMode === 'verify') {
|
213
|
-
return (h("div", { class: "form" }, h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" }), h("
|
213
|
+
return (h("div", { class: "form" }, h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" }), h("h6", null, "Please Verify your Email Address"), h("p", null, "Check your e-mail inbox for a verification email, and follow the instructions provided."), h("p", null, h("em", null, "Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")), h("div", { class: "buttons" }, h("verdocs-button", { label: "Sign Out", variant: "outline", disabled: this.submitting, onClick: () => {
|
214
214
|
this.username = '';
|
215
215
|
this.password = '';
|
216
216
|
this.cancelRecheckTimer();
|
@@ -3,7 +3,7 @@ import { VerdocsEndpoint, createProfile, authenticate, decodeAccessTokenBody, re
|
|
3
3
|
import { V as VerdocsToast } from './Toast-b71de686.js';
|
4
4
|
import { S as SDKError } from './errors-887f1e88.js';
|
5
5
|
|
6
|
-
const verdocsAuthCss = "@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-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 .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 h4 verdocs-button button.normal .button-label{padding:0}verdocs-auth .buttons{gap:20px;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth .status-result{display:none}verdocs-auth .status-result.debug{white-space:pre-wrap;font-size:14px;background:#fff;padding:10px;display:block;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth form{width:100%}verdocs-auth verdocs-text-input{margin-bottom:10px}verdocs-auth .account-option{gap:8px;margin:20px 0 8px 0;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-auth p+p{margin-top:0}verdocs-auth verdocs-help-icon{margin-top:18px;display:-ms-flexbox;display:flex;width:32px;height:32px;-ms-flex:0 0 32px;flex:0 0 32px}";
|
6
|
+
const verdocsAuthCss = "@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-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 .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 h4 verdocs-button button.normal .button-label{padding:0}verdocs-auth h6{text-align:center;font-weight:500;font-size:16px;line-height:1.75;margin:0 0 20px 0}verdocs-auth em{font-size:14px;margin:15px 0}verdocs-auth .buttons{gap:20px;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth .status-result{display:none}verdocs-auth .status-result.debug{white-space:pre-wrap;font-size:14px;background:#fff;padding:10px;display:block;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth form{width:100%}verdocs-auth verdocs-text-input{margin-bottom:10px}verdocs-auth .account-option{gap:8px;margin:20px 0 8px 0;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-auth p+p{margin-top:0}verdocs-auth verdocs-help-icon{margin-top:18px;display:-ms-flexbox;display:flex;width:32px;height:32px;-ms-flex:0 0 32px;flex:0 0 32px}";
|
7
7
|
const VerdocsAuthStyle0 = verdocsAuthCss;
|
8
8
|
|
9
9
|
const RECHECK_INTERVAL = 5000;
|
@@ -198,7 +198,7 @@ const VerdocsAuth = class {
|
|
198
198
|
}
|
199
199
|
if (this.displayMode === 'signup') {
|
200
200
|
const step1Invalid = this.submitting || !this.first_name || !this.last_name || !this.username || !this.password || !this.org_name;
|
201
|
-
return (h("div", { class: "form" }, h("a", { href: "https://verdocs.com/en/" }, h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" })), h("h3", null, "Sign up for a free account"), h("
|
201
|
+
return (h("div", { class: "form" }, h("a", { href: "https://verdocs.com/en/" }, h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" })), h("h3", null, "Sign up for a free account"), h("h5", null, "Already have an account?", h("verdocs-button", { label: "Log In", variant: "text", onClick: () => (this.displayMode = 'login'), disabled: this.submitting })), this.signupStep === 1 && (h("form", { onSubmit: () => this.handleSignup() }, h("div", { style: { display: 'flex', flexDirection: 'row', columnGap: '20px' } }, h("verdocs-text-input", { label: "First Name", autocomplete: "first", required: true, value: this.first_name, onInput: (e) => (this.first_name = e.target.value), disabled: this.submitting }), h("verdocs-text-input", { label: "Last Name", autocomplete: "last", required: true, value: this.last_name, onInput: (e) => (this.last_name = e.target.value), disabled: this.submitting })), h("verdocs-text-input", { label: "Email Address", autocomplete: "email", required: true, value: this.username, onInput: (e) => (this.username = e.target.value), disabled: this.submitting }), h("verdocs-text-input", { label: "Password", type: "password", required: true, autocomplete: "current-password", value: this.password, onInput: (e) => (this.password = e.target.value), disabled: this.submitting }), h("verdocs-text-input", { label: "Organization Name", autocomplete: "org", required: true, value: this.org_name, onInput: (e) => (this.org_name = e.target.value), disabled: this.submitting, style: { flex: '1' } }), h("div", { style: { marginTop: '30px' } }), h("verdocs-button", { label: "Next", disabled: step1Invalid, onClick: () => this.handleSignup(), style: { display: 'flex', justifyContent: 'center', margin: '30px auto 0' } }))), this.signupStep === 3 && (h("form", { onSubmit: () => this.handleSignup() }, h("p", null, "Please check your e-mail inbox for a verification code and follow the instructions provided."), h("p", null, h("em", null, "Verification messages may take up to 1 hour to arrive. If you do not receive the invitation, ", h("a", { href: "#" }, "Click Here"), " to resend it. Be sure to check your spam folder.")), h("div", { style: { display: 'flex', flexDirection: 'row', gap: '20px' } }, h("verdocs-button", { label: "Back", disabled: this.submitting, onClick: () => {
|
202
202
|
this.signupStep = 2;
|
203
203
|
}, style: { display: 'flex', justifyContent: 'center', margin: '30px auto 0' } }), h("verdocs-button", { label: "Go to Dashboard", disabled: true, onClick: () => this.handleSignup(), style: { display: 'flex', justifyContent: 'center', margin: '30px auto 0' } }))))));
|
204
204
|
}
|
@@ -206,7 +206,7 @@ const VerdocsAuth = class {
|
|
206
206
|
return (h("div", { class: "form" }, h("a", { href: "https://verdocs.com/en/" }, h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" })), h("h3", null, "Forgot your password?"), h("p", null, "Enter your e-mail address below, and reset instructions will be sent to your Inbox."), h("p", null, h("em", null, "Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")), h("form", { onSubmit: () => this.handleSignup() }, h("verdocs-text-input", { label: "Email", autocomplete: "email", required: true, value: this.username, onInput: (e) => (this.username = e.target.value), disabled: this.submitting }), h("div", { style: { marginTop: '30px' } }), h("div", { class: "buttons" }, h("verdocs-button", { label: "Cancel", variant: "outline", disabled: this.submitting, onClick: () => (this.displayMode = 'login') }), h("verdocs-button", { label: "Reset", disabled: this.submitting, onClick: () => this.handleReset() })))));
|
207
207
|
}
|
208
208
|
if (this.displayMode === 'verify') {
|
209
|
-
return (h("div", { class: "form" }, h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" }), h("
|
209
|
+
return (h("div", { class: "form" }, h("img", { src: this.logo, alt: "Verdocs Logo", class: "logo" }), h("h6", null, "Please Verify your Email Address"), h("p", null, "Check your e-mail inbox for a verification email, and follow the instructions provided."), h("p", null, h("em", null, "Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")), h("div", { class: "buttons" }, h("verdocs-button", { label: "Sign Out", variant: "outline", disabled: this.submitting, onClick: () => {
|
210
210
|
this.username = '';
|
211
211
|
this.password = '';
|
212
212
|
this.cancelRecheckTimer();
|
@@ -1 +1 @@
|
|
1
|
-
import{r as registerInstance,c as createEvent,h}from"./index-b89cf6a4.js";import{VerdocsEndpoint,createProfile,authenticate,decodeAccessTokenBody,resendVerification,resetPassword}from"@verdocs/js-sdk";import{V as VerdocsToast}from"./Toast-b71de686.js";import{S as SDKError}from"./errors-887f1e88.js";var verdocsAuthCss='@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-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 .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 h4 verdocs-button button.normal .button-label{padding:0}verdocs-auth .buttons{gap:20px;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth .status-result{display:none}verdocs-auth .status-result.debug{white-space:pre-wrap;font-size:14px;background:#fff;padding:10px;display:block;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth form{width:100%}verdocs-auth verdocs-text-input{margin-bottom:10px}verdocs-auth .account-option{gap:8px;margin:20px 0 8px 0;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-auth p+p{margin-top:0}verdocs-auth verdocs-help-icon{margin-top:18px;display:-ms-flexbox;display:flex;width:32px;height:32px;-ms-flex:0 0 32px;flex:0 0 32px}';var VerdocsAuthStyle0=verdocsAuthCss;var RECHECK_INTERVAL=5e3;var VerdocsAuth=function(){function e(e){registerInstance(this,e);this.authenticated=createEvent(this,"authenticated",7);this.sdkError=createEvent(this,"sdkError",7);this.recheckTimer=null;this.resendDisabledTimer=null;this.accessTokenForVerification=null;this.endpoint=VerdocsEndpoint.getDefault();this.visible=true;this.logo="https://app.verdocs.com/assets/blue-logo.svg";this.isAuthenticated=false;this.displayMode="login";this.org_name="";this.first_name="";this.last_name="";this.username="";this.password="";this.submitting=false;this.activeSession=null;this.accountType="org";this.signupStep=1;this.resendDisabled=false;this.checkingOrg=false}e.prototype.componentWillLoad=function(){var e,t;this.endpoint.loadSession();if(this.endpoint.session){console.log("[AUTH] Authenticated");this.isAuthenticated=true;this.activeSession=this.endpoint.session;(e=this.authenticated)===null||e===void 0?void 0:e.emit({authenticated:true,session:this.endpoint.session})}else{console.log("[AUTH] Anonymous");(t=this.authenticated)===null||t===void 0?void 0:t.emit({authenticated:false,session:null})}};e.prototype.disconnectedCallback=function(){this.cancelRecheckTimer()};e.prototype.cancelRecheckTimer=function(){if(this.recheckTimer){try{clearTimeout(this.recheckTimer)}catch(e){}this.recheckTimer=null}if(this.resendDisabledTimer){try{clearTimeout(this.resendDisabledTimer)}catch(e){}this.resendDisabledTimer=null}};e.prototype.isPasswordComplex=function(e){var t=function(e){return/[A-Z]/.test(e)};var o=function(e){return/[a-z]/.test(e)};var i=function(e){return/[`!@#$%^&*()_\-+=\[\]{};':"\\|,.<>\/?~ ]/.test(e)};var s=0,n=0,r=0;for(var l=0;l<e.length;l++){var a=e.charAt(l);if(t(a))s++;else if(o(a))n++;else if(i(a))r++}return e.length>=8&&n>0&&s>0&&r>0};e.prototype.handleSignup=function(){var e=this;this.submitting=true;this.accessTokenForVerification=null;if(!this.isPasswordComplex(this.password)){window.alert("Password must be at least 8 characters long and contain at least one uppercase, one lowercase, and one special character.");return}createProfile(this.endpoint,{email:this.username,password:this.password,first_name:this.first_name,last_name:this.last_name,org_name:this.org_name}).then((function(t){console.log("Profile creation result",t);e.loginAndCheckVerification()})).catch((function(t){var o,i,s,n,r,l;console.log("[AUTH] Signup error",t.response);e.submitting=false;e.activeSession=null;(o=e.authenticated)===null||o===void 0?void 0:o.emit({authenticated:false,session:null});(i=e.sdkError)===null||i===void 0?void 0:i.emit(new SDKError(t.message,(s=t.response)===null||s===void 0?void 0:s.status,(n=t.response)===null||n===void 0?void 0:n.data));VerdocsToast("Signup failed: "+((l=(r=t.response)===null||r===void 0?void 0:r.data)===null||l===void 0?void 0:l.message)||"Unknown Error",{style:"error"})}))};e.prototype.loginAndCheckVerification=function(){var e=this;this.submitting=true;this.accessTokenForVerification=null;authenticate(this.endpoint,{username:this.username,password:this.password,grant_type:"password"}).then((function(t){var o;e.cancelRecheckTimer();e.submitting=false;var i=decodeAccessTokenBody(t.access_token);console.log("[AUTH] Got access token body",i);if(i===null||i===void 0?void 0:i.email_verified){console.log("[AUTH] Email address is verified, completing login");e.displayMode="login";e.accessTokenForVerification=null;e.endpoint.setToken(t.access_token);e.activeSession=e.endpoint.session;e.isAuthenticated=true;(o=e.authenticated)===null||o===void 0?void 0:o.emit({authenticated:true,session:e.endpoint.session})}else{console.log("[AUTH] Logged in, pending email address verification");e.displayMode="verify";e.accessTokenForVerification=t.access_token;e.recheckTimer=setTimeout(e.loginAndCheckVerification,RECHECK_INTERVAL)}})).catch((function(t){var o,i,s,n;e.cancelRecheckTimer();console.log("[AUTH] Authentication error",t.response,JSON.stringify(t));e.displayMode="login";e.submitting=false;e.activeSession=null;(o=e.authenticated)===null||o===void 0?void 0:o.emit({authenticated:false,session:null});(i=e.sdkError)===null||i===void 0?void 0:i.emit(new SDKError(t.message,(s=t.response)===null||s===void 0?void 0:s.status,(n=t.response)===null||n===void 0?void 0:n.data));VerdocsToast("Login failed. Please check your username and password and try again.",{style:"error"})}))};e.prototype.handleLogout=function(){var e;this.endpoint.clearSession();this.isAuthenticated=false;this.accessTokenForVerification=null;(e=this.authenticated)===null||e===void 0?void 0:e.emit({authenticated:false,session:null})};e.prototype.handleResend=function(){var e=this;this.resendDisabled=true;this.resendDisabledTimer=setTimeout((function(){e.resendDisabled=false;e.resendDisabledTimer=null}),3e4);resendVerification(this.endpoint,this.accessTokenForVerification).then((function(e){console.log("[AUTH] Verification request resent",e);VerdocsToast("Please check your email for a message with verification instructions.",{style:"info"})})).catch((function(e){console.log("[AUTH] Unable to resend verification",e)}))};e.prototype.handleReset=function(){var e=this;this.submitting=true;resetPassword(this.endpoint,{email:this.username}).then((function(t){console.log("[AUTH] Reset sent",t);e.submitting=false;e.displayMode="login";VerdocsToast("If your email address is registered, you will receive instructions on resetting your password shortly.",{style:"info"})})).catch((function(t){console.log("[AUTH] Unable to reset password",t);e.submitting=false}))};e.prototype.render=function(){var e=this;if(!this.visible){return h("div",{style:{display:"none"}},"Authenticated")}if(this.isAuthenticated){return h("verdocs-button",{label:"Sign Out",disabled:this.submitting,onClick:function(){return e.handleLogout()},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}})}if(this.displayMode==="signup"){var t=this.submitting||!this.first_name||!this.last_name||!this.username||!this.password||!this.org_name;return h("div",{class:"form"},h("a",{href:"https://verdocs.com/en/"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),h("h3",null,"Sign up for a free account"),h("h4",null,"Already have an account?",h("verdocs-button",{label:"Log In",variant:"text",onClick:function(){return e.displayMode="login"},disabled:this.submitting})),this.signupStep===1&&h("form",{onSubmit:function(){return e.handleSignup()}},h("div",{style:{display:"flex",flexDirection:"row",columnGap:"20px"}},h("verdocs-text-input",{label:"First Name",autocomplete:"first",required:true,value:this.first_name,onInput:function(t){return e.first_name=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Last Name",autocomplete:"last",required:true,value:this.last_name,onInput:function(t){return e.last_name=t.target.value},disabled:this.submitting})),h("verdocs-text-input",{label:"Email Address",autocomplete:"email",required:true,value:this.username,onInput:function(t){return e.username=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Password",type:"password",required:true,autocomplete:"current-password",value:this.password,onInput:function(t){return e.password=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Organization Name",autocomplete:"org",required:true,value:this.org_name,onInput:function(t){return e.org_name=t.target.value},disabled:this.submitting,style:{flex:"1"}}),h("div",{style:{marginTop:"30px"}}),h("verdocs-button",{label:"Next",disabled:t,onClick:function(){return e.handleSignup()},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}})),this.signupStep===3&&h("form",{onSubmit:function(){return e.handleSignup()}},h("p",null,"Please check your e-mail inbox for a verification code and follow the instructions provided."),h("p",null,h("em",null,"Verification messages may take up to 1 hour to arrive. If you do not receive the invitation, ",h("a",{href:"#"},"Click Here")," to resend it. Be sure to check your spam folder.")),h("div",{style:{display:"flex",flexDirection:"row",gap:"20px"}},h("verdocs-button",{label:"Back",disabled:this.submitting,onClick:function(){e.signupStep=2},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}}),h("verdocs-button",{label:"Go to Dashboard",disabled:true,onClick:function(){return e.handleSignup()},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}}))))}if(this.displayMode==="forgot"){return h("div",{class:"form"},h("a",{href:"https://verdocs.com/en/"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),h("h3",null,"Forgot your password?"),h("p",null,"Enter your e-mail address below, and reset instructions will be sent to your Inbox."),h("p",null,h("em",null,"Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")),h("form",{onSubmit:function(){return e.handleSignup()}},h("verdocs-text-input",{label:"Email",autocomplete:"email",required:true,value:this.username,onInput:function(t){return e.username=t.target.value},disabled:this.submitting}),h("div",{style:{marginTop:"30px"}}),h("div",{class:"buttons"},h("verdocs-button",{label:"Cancel",variant:"outline",disabled:this.submitting,onClick:function(){return e.displayMode="login"}}),h("verdocs-button",{label:"Reset",disabled:this.submitting,onClick:function(){return e.handleReset()}}))))}if(this.displayMode==="verify"){return h("div",{class:"form"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"}),h("h3",null,"Please Verify your Email Address"),h("p",null,"Check your e-mail inbox for a verification email, and follow the instructions provided."),h("p",null,h("em",null,"Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")),h("div",{class:"buttons"},h("verdocs-button",{label:"Sign Out",variant:"outline",disabled:this.submitting,onClick:function(){e.username="";e.password="";e.cancelRecheckTimer();e.displayMode="login"}}),h("verdocs-button",{label:"Resend Email",disabled:this.resendDisabled,onClick:function(){return e.handleResend()}})))}return h("div",{class:"form"},h("a",{href:"https://verdocs.com/en/"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),h("h3",null,"Log in to your account"),h("h4",null,"Don't have an account?",h("verdocs-button",{label:"Sign Up",variant:"text",onClick:function(){e.displayMode="signup";e.signupStep=1},disabled:this.submitting})),h("form",{onSubmit:function(){return e.loginAndCheckVerification()}},h("verdocs-text-input",{label:"Email",autocomplete:"username",value:this.username,onInput:function(t){return e.username=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Password",type:"password",autocomplete:"current-password",value:this.password,onInput:function(t){return e.password=t.target.value},disabled:this.submitting}),h("verdocs-button",{label:"Forgot Your Password?",variant:"text",onClick:function(){return e.displayMode="forgot"},disabled:this.submitting,style:{display:"flex",justifyContent:"center",margin:"10px auto 20px"}}),h("verdocs-button",{label:"Login",disabled:this.submitting,onClick:function(){return e.loginAndCheckVerification()},style:{display:"flex",justifyContent:"center",margin:"10px auto 0"}})))};return e}();VerdocsAuth.style=VerdocsAuthStyle0;export{VerdocsAuth as verdocs_auth};
|
1
|
+
import{r as registerInstance,c as createEvent,h}from"./index-b89cf6a4.js";import{VerdocsEndpoint,createProfile,authenticate,decodeAccessTokenBody,resendVerification,resetPassword}from"@verdocs/js-sdk";import{V as VerdocsToast}from"./Toast-b71de686.js";import{S as SDKError}from"./errors-887f1e88.js";var verdocsAuthCss='@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-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 .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 h4 verdocs-button button.normal .button-label{padding:0}verdocs-auth h6{text-align:center;font-weight:500;font-size:16px;line-height:1.75;margin:0 0 20px 0}verdocs-auth em{font-size:14px;margin:15px 0}verdocs-auth .buttons{gap:20px;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth .status-result{display:none}verdocs-auth .status-result.debug{white-space:pre-wrap;font-size:14px;background:#fff;padding:10px;display:block;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth form{width:100%}verdocs-auth verdocs-text-input{margin-bottom:10px}verdocs-auth .account-option{gap:8px;margin:20px 0 8px 0;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-auth p+p{margin-top:0}verdocs-auth verdocs-help-icon{margin-top:18px;display:-ms-flexbox;display:flex;width:32px;height:32px;-ms-flex:0 0 32px;flex:0 0 32px}';var VerdocsAuthStyle0=verdocsAuthCss;var RECHECK_INTERVAL=5e3;var VerdocsAuth=function(){function e(e){registerInstance(this,e);this.authenticated=createEvent(this,"authenticated",7);this.sdkError=createEvent(this,"sdkError",7);this.recheckTimer=null;this.resendDisabledTimer=null;this.accessTokenForVerification=null;this.endpoint=VerdocsEndpoint.getDefault();this.visible=true;this.logo="https://app.verdocs.com/assets/blue-logo.svg";this.isAuthenticated=false;this.displayMode="login";this.org_name="";this.first_name="";this.last_name="";this.username="";this.password="";this.submitting=false;this.activeSession=null;this.accountType="org";this.signupStep=1;this.resendDisabled=false;this.checkingOrg=false}e.prototype.componentWillLoad=function(){var e,t;this.endpoint.loadSession();if(this.endpoint.session){console.log("[AUTH] Authenticated");this.isAuthenticated=true;this.activeSession=this.endpoint.session;(e=this.authenticated)===null||e===void 0?void 0:e.emit({authenticated:true,session:this.endpoint.session})}else{console.log("[AUTH] Anonymous");(t=this.authenticated)===null||t===void 0?void 0:t.emit({authenticated:false,session:null})}};e.prototype.disconnectedCallback=function(){this.cancelRecheckTimer()};e.prototype.cancelRecheckTimer=function(){if(this.recheckTimer){try{clearTimeout(this.recheckTimer)}catch(e){}this.recheckTimer=null}if(this.resendDisabledTimer){try{clearTimeout(this.resendDisabledTimer)}catch(e){}this.resendDisabledTimer=null}};e.prototype.isPasswordComplex=function(e){var t=function(e){return/[A-Z]/.test(e)};var i=function(e){return/[a-z]/.test(e)};var o=function(e){return/[`!@#$%^&*()_\-+=\[\]{};':"\\|,.<>\/?~ ]/.test(e)};var s=0,n=0,r=0;for(var l=0;l<e.length;l++){var a=e.charAt(l);if(t(a))s++;else if(i(a))n++;else if(o(a))r++}return e.length>=8&&n>0&&s>0&&r>0};e.prototype.handleSignup=function(){var e=this;this.submitting=true;this.accessTokenForVerification=null;if(!this.isPasswordComplex(this.password)){window.alert("Password must be at least 8 characters long and contain at least one uppercase, one lowercase, and one special character.");return}createProfile(this.endpoint,{email:this.username,password:this.password,first_name:this.first_name,last_name:this.last_name,org_name:this.org_name}).then((function(t){console.log("Profile creation result",t);e.loginAndCheckVerification()})).catch((function(t){var i,o,s,n,r,l;console.log("[AUTH] Signup error",t.response);e.submitting=false;e.activeSession=null;(i=e.authenticated)===null||i===void 0?void 0:i.emit({authenticated:false,session:null});(o=e.sdkError)===null||o===void 0?void 0:o.emit(new SDKError(t.message,(s=t.response)===null||s===void 0?void 0:s.status,(n=t.response)===null||n===void 0?void 0:n.data));VerdocsToast("Signup failed: "+((l=(r=t.response)===null||r===void 0?void 0:r.data)===null||l===void 0?void 0:l.message)||"Unknown Error",{style:"error"})}))};e.prototype.loginAndCheckVerification=function(){var e=this;this.submitting=true;this.accessTokenForVerification=null;authenticate(this.endpoint,{username:this.username,password:this.password,grant_type:"password"}).then((function(t){var i;e.cancelRecheckTimer();e.submitting=false;var o=decodeAccessTokenBody(t.access_token);console.log("[AUTH] Got access token body",o);if(o===null||o===void 0?void 0:o.email_verified){console.log("[AUTH] Email address is verified, completing login");e.displayMode="login";e.accessTokenForVerification=null;e.endpoint.setToken(t.access_token);e.activeSession=e.endpoint.session;e.isAuthenticated=true;(i=e.authenticated)===null||i===void 0?void 0:i.emit({authenticated:true,session:e.endpoint.session})}else{console.log("[AUTH] Logged in, pending email address verification");e.displayMode="verify";e.accessTokenForVerification=t.access_token;e.recheckTimer=setTimeout(e.loginAndCheckVerification,RECHECK_INTERVAL)}})).catch((function(t){var i,o,s,n;e.cancelRecheckTimer();console.log("[AUTH] Authentication error",t.response,JSON.stringify(t));e.displayMode="login";e.submitting=false;e.activeSession=null;(i=e.authenticated)===null||i===void 0?void 0:i.emit({authenticated:false,session:null});(o=e.sdkError)===null||o===void 0?void 0:o.emit(new SDKError(t.message,(s=t.response)===null||s===void 0?void 0:s.status,(n=t.response)===null||n===void 0?void 0:n.data));VerdocsToast("Login failed. Please check your username and password and try again.",{style:"error"})}))};e.prototype.handleLogout=function(){var e;this.endpoint.clearSession();this.isAuthenticated=false;this.accessTokenForVerification=null;(e=this.authenticated)===null||e===void 0?void 0:e.emit({authenticated:false,session:null})};e.prototype.handleResend=function(){var e=this;this.resendDisabled=true;this.resendDisabledTimer=setTimeout((function(){e.resendDisabled=false;e.resendDisabledTimer=null}),3e4);resendVerification(this.endpoint,this.accessTokenForVerification).then((function(e){console.log("[AUTH] Verification request resent",e);VerdocsToast("Please check your email for a message with verification instructions.",{style:"info"})})).catch((function(e){console.log("[AUTH] Unable to resend verification",e)}))};e.prototype.handleReset=function(){var e=this;this.submitting=true;resetPassword(this.endpoint,{email:this.username}).then((function(t){console.log("[AUTH] Reset sent",t);e.submitting=false;e.displayMode="login";VerdocsToast("If your email address is registered, you will receive instructions on resetting your password shortly.",{style:"info"})})).catch((function(t){console.log("[AUTH] Unable to reset password",t);e.submitting=false}))};e.prototype.render=function(){var e=this;if(!this.visible){return h("div",{style:{display:"none"}},"Authenticated")}if(this.isAuthenticated){return h("verdocs-button",{label:"Sign Out",disabled:this.submitting,onClick:function(){return e.handleLogout()},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}})}if(this.displayMode==="signup"){var t=this.submitting||!this.first_name||!this.last_name||!this.username||!this.password||!this.org_name;return h("div",{class:"form"},h("a",{href:"https://verdocs.com/en/"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),h("h3",null,"Sign up for a free account"),h("h5",null,"Already have an account?",h("verdocs-button",{label:"Log In",variant:"text",onClick:function(){return e.displayMode="login"},disabled:this.submitting})),this.signupStep===1&&h("form",{onSubmit:function(){return e.handleSignup()}},h("div",{style:{display:"flex",flexDirection:"row",columnGap:"20px"}},h("verdocs-text-input",{label:"First Name",autocomplete:"first",required:true,value:this.first_name,onInput:function(t){return e.first_name=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Last Name",autocomplete:"last",required:true,value:this.last_name,onInput:function(t){return e.last_name=t.target.value},disabled:this.submitting})),h("verdocs-text-input",{label:"Email Address",autocomplete:"email",required:true,value:this.username,onInput:function(t){return e.username=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Password",type:"password",required:true,autocomplete:"current-password",value:this.password,onInput:function(t){return e.password=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Organization Name",autocomplete:"org",required:true,value:this.org_name,onInput:function(t){return e.org_name=t.target.value},disabled:this.submitting,style:{flex:"1"}}),h("div",{style:{marginTop:"30px"}}),h("verdocs-button",{label:"Next",disabled:t,onClick:function(){return e.handleSignup()},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}})),this.signupStep===3&&h("form",{onSubmit:function(){return e.handleSignup()}},h("p",null,"Please check your e-mail inbox for a verification code and follow the instructions provided."),h("p",null,h("em",null,"Verification messages may take up to 1 hour to arrive. If you do not receive the invitation, ",h("a",{href:"#"},"Click Here")," to resend it. Be sure to check your spam folder.")),h("div",{style:{display:"flex",flexDirection:"row",gap:"20px"}},h("verdocs-button",{label:"Back",disabled:this.submitting,onClick:function(){e.signupStep=2},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}}),h("verdocs-button",{label:"Go to Dashboard",disabled:true,onClick:function(){return e.handleSignup()},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}}))))}if(this.displayMode==="forgot"){return h("div",{class:"form"},h("a",{href:"https://verdocs.com/en/"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),h("h3",null,"Forgot your password?"),h("p",null,"Enter your e-mail address below, and reset instructions will be sent to your Inbox."),h("p",null,h("em",null,"Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")),h("form",{onSubmit:function(){return e.handleSignup()}},h("verdocs-text-input",{label:"Email",autocomplete:"email",required:true,value:this.username,onInput:function(t){return e.username=t.target.value},disabled:this.submitting}),h("div",{style:{marginTop:"30px"}}),h("div",{class:"buttons"},h("verdocs-button",{label:"Cancel",variant:"outline",disabled:this.submitting,onClick:function(){return e.displayMode="login"}}),h("verdocs-button",{label:"Reset",disabled:this.submitting,onClick:function(){return e.handleReset()}}))))}if(this.displayMode==="verify"){return h("div",{class:"form"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"}),h("h6",null,"Please Verify your Email Address"),h("p",null,"Check your e-mail inbox for a verification email, and follow the instructions provided."),h("p",null,h("em",null,"Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")),h("div",{class:"buttons"},h("verdocs-button",{label:"Sign Out",variant:"outline",disabled:this.submitting,onClick:function(){e.username="";e.password="";e.cancelRecheckTimer();e.displayMode="login"}}),h("verdocs-button",{label:"Resend Email",disabled:this.resendDisabled,onClick:function(){return e.handleResend()}})))}return h("div",{class:"form"},h("a",{href:"https://verdocs.com/en/"},h("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),h("h3",null,"Log in to your account"),h("h4",null,"Don't have an account?",h("verdocs-button",{label:"Sign Up",variant:"text",onClick:function(){e.displayMode="signup";e.signupStep=1},disabled:this.submitting})),h("form",{onSubmit:function(){return e.loginAndCheckVerification()}},h("verdocs-text-input",{label:"Email",autocomplete:"username",value:this.username,onInput:function(t){return e.username=t.target.value},disabled:this.submitting}),h("verdocs-text-input",{label:"Password",type:"password",autocomplete:"current-password",value:this.password,onInput:function(t){return e.password=t.target.value},disabled:this.submitting}),h("verdocs-button",{label:"Forgot Your Password?",variant:"text",onClick:function(){return e.displayMode="forgot"},disabled:this.submitting,style:{display:"flex",justifyContent:"center",margin:"10px auto 20px"}}),h("verdocs-button",{label:"Login",disabled:this.submitting,onClick:function(){return e.loginAndCheckVerification()},style:{display:"flex",justifyContent:"center",margin:"10px auto 0"}})))};return e}();VerdocsAuth.style=VerdocsAuthStyle0;export{VerdocsAuth as verdocs_auth};
|
@@ -1 +1 @@
|
|
1
|
-
var __awaiter=this&&this.__awaiter||function(e,t,a,n){function i(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,d){function s(e){try{l(n.next(e))}catch(e){d(e)}}function o(e){try{l(n["throw"](e))}catch(e){d(e)}}function l(e){e.done?a(e.value):i(e.value).then(s,o)}l((n=n.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var a={label:0,sent:function(){if(d[0]&1)throw d[1];return d[1]},trys:[],ops:[]},n,i,d,s;return s={next:o(0),throw:o(1),return:o(2)},typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function o(e){return function(t){return l([e,t])}}function l(o){if(n)throw new TypeError("Generator is already executing.");while(s&&(s=0,o[0]&&(a=0)),a)try{if(n=1,i&&(d=o[0]&2?i["return"]:o[0]?i["throw"]||((d=i["return"])&&d.call(i),0):i.next)&&!(d=d.call(i,o[1])).done)return d;if(i=0,d)o=[o[0]&2,d.value];switch(o[0]){case 0:case 1:d=o;break;case 4:a.label++;return{value:o[1],done:false};case 5:a.label++;i=o[1];o=[0];continue;case 7:o=a.ops.pop();a.trys.pop();continue;default:if(!(d=a.trys,d=d.length>0&&d[d.length-1])&&(o[0]===6||o[0]===2)){a=0;continue}if(o[0]===3&&(!d||o[1]>d[0]&&o[1]<d[3])){a.label=o[1];break}if(o[0]===6&&a.label<d[1]){a.label=d[1];d=o;break}if(d&&a.label<d[2]){a.label=d[2];a.ops.push(o);break}if(d[2])a.ops.pop();a.trys.pop();continue}o=t.call(e,a)}catch(e){o=[6,e];i=0}finally{n=d=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:true}}};System.register(["./p-e748b2d2.system.js","./p-56ba5cbf.system.js"],(function(e,t){"use strict";var a,n,i;return{setters:[function(t){a=t.p;n=t.b;e("setNonce",t.s)},function(e){i=e.g}],execute:function(){var e=this;var d=function(){var e=t.meta.url;var n={};if(e!==""){n.resourcesUrl=new URL(".",e).href}return a(n)};d().then((function(t){return __awaiter(e,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return[4,i()];case 1:e.sent();return[2,n(JSON.parse('[["p-977a5a4b.system",[[0,"verdocs-build",{"endpoint":[16],"templateId":[1537,"template-id"],"step":[1537],"templateStore":[32]},null,{"templateId":["onTemplateIdChanged"],"step":["onStepChanged"]}]]],["p-ee08c75b.system",[[0,"verdocs-envelopes-list",{"endpoint":[16],"view":[1537],"status":[1537],"sort":[1537],"match":[1537],"showPagination":[4,"show-pagination"],"rowsPerPage":[2,"rows-per-page"],"selectedPage":[2,"selected-page"],"count":[32],"initiallyLoaded":[32],"loading":[32],"selectedEnvelopes":[32],"envelopes":[32]},null,{"view":["handleViewUpdated"],"status":["handleStatusUpdated"],"sort":["handleSortUpdated"],"match":["handleMatchUpdated"],"selectedPage":["handlePageUpdated"]}]]],["p-b7397955.system",[[0,"verdocs-templates-list",{"endpoint":[16],"sharing":[1537],"starred":[1537],"sort":[1537],"name":[1537],"allowedActions":[1040],"showPagination":[4,"show-pagination"],"rowsPerPage":[2,"rows-per-page"],"selectedPage":[2,"selected-page"],"count":[32],"initiallyLoaded":[32],"loading":[32],"confirmDelete":[32],"templates":[32],"localNameFilter":[32]},null,{"sharing":["handleSharingUpdated"],"starred":["handleStarredUpdated"],"sort":["handleSortUpdated"],"name":["handleNameUpdated"],"selectedPage":["handlePageUpdated"]}]]],["p-8d0807ab.system",[[0,"verdocs-sign",{"envelopeId":[1,"envelope-id"],"roleId":[1,"role-id"],"inviteCode":[1,"invite-code"],"headerTargetId":[1,"header-target-id"],"envelope":[32],"roleNames":[32],"sortedRecipients":[32],"recipient":[32],"hasSignature":[32],"nextButtonLabel":[32],"nextSubmits":[32],"errorMessage":[32],"focusedField":[32],"submitting":[32],"isDone":[32],"showDone":[32],"showLoadError":[32],"finishLater":[32],"showFinishLater":[32],"agreed":[32],"documentsSingularPlural":[32]}]]],["p-2be9ba53.system",[[0,"verdocs-envelope-sidebar",{"endpoint":[16],"envelopeId":[1,"envelope-id"],"activeTab":[32],"panelOpen":[32],"showManageDialog":[32],"showRecipientDialog":[32],"showCancelDialog":[32],"loading":[32]}]]],["p-f0299a13.system",[[0,"verdocs-auth",{"endpoint":[16],"visible":[4],"logo":[1],"isAuthenticated":[32],"displayMode":[32],"org_name":[32],"first_name":[32],"last_name":[32],"username":[32],"password":[32],"submitting":[32],"activeSession":[32],"accountType":[32],"signupStep":[32],"resendDisabled":[32],"checkingOrg":[32]}]]],["p-50aa20d5.system",[[0,"verdocs-search",{"endpoint":[16]}]]],["p-b96e571d.system",[[0,"verdocs-activity-box",{"endpoint":[16],"items":[2],"view":[1],"header":[1],"title":[32],"count":[32],"loading":[32],"entries":[32]},null,{"items":["handleItemsUpdated"],"view":["handleViewUpdated"]}]]],["p-fdb77c22.system",[[0,"verdocs-kba-dialog",{"step":[2],"steps":[2],"helptitle":[1],"helptext":[1],"mode":[1],"label":[1],"placeholder":[1],"choices":[16],"response":[32]}]]],["p-fc5e568d.system",[[4,"verdocs-dialog"]]],["p-98928410.system",[[0,"verdocs-field-payment",{"templateid":[1],"fieldname":[1],"disabled":[4],"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],"xscale":[2],"yscale":[2],"pagenumber":[2],"roleindex":[2],"preparedMessage":[32],"signatureUrl":[32],"showingProperties":[32],"showSettingsPanel":[64],"hideSettingsPanel":[64]}]]],["p-8ee31f33.system",[[0,"verdocs-search-tabs",{"selected":[32]}]]],["p-3f4b3548.system",[[0,"verdocs-table",{"columns":[16],"data":[16]}]]],["p-9ce9d353.system",[[0,"verdocs-template-card",{"template":[16]}]]],["p-08210588.system",[[0,"verdocs-template-tags",{"tags":[16]}]]],["p-c293ad2e.system",[[0,"verdocs-toggle",{"options":[16],"theme":[1],"selectedOption":[32]}]]],["p-dcbad099.system",[[0,"verdocs-dropdown",{"options":[16]},[[9,"resize","handleResize"]]]]],["p-9452b95d.system",[[0,"verdocs-loader"]]],["p-1030a0b7.system",[[0,"verdocs-text-input",{"value":[1537],"label":[1],"placeholder":[1],"autocomplete":[1],"helpText":[1,"help-text"],"clearable":[4],"copyable":[4],"type":[1],"disabled":[4],"required":[4]}],[0,"verdocs-help-icon",{"text":[1],"icon":[1],"containerId":[32]}],[0,"verdocs-button",{"label":[1],"startIcon":[1,"start-icon"],"endIcon":[1,"end-icon"],"size":[1],"type":[1],"variant":[1],"disabled":[4]}]]],["p-a2a0c7b4.system",[[0,"verdocs-view",{"endpoint":[16],"envelopeId":[1,"envelope-id"],"headerTargetId":[1,"header-target-id"],"canceling":[32],"envelope":[32],"roleNames":[32],"showCancelDone":[32]}]]],["p-cef88396.system",[[0,"verdocs-status-indicator",{"size":[1],"theme":[1],"status":[1],"envelope":[16],"isOpen":[32],"containerId":[32]}]]],["p-6fc92b73.system",[[0,"verdocs-template-star",{"endpoint":[16],"template":[1040],"updating":[32]}]]],["p-48fce604.system",[[0,"verdocs-envelope-recipient-link",{"endpoint":[16],"envelopeId":[1,"envelope-id"],"roleName":[1,"role-name"],"isOpen":[32],"loading":[32],"gettingLink":[32],"link":[32]}],[0,"verdocs-envelope-recipient-summary",{"endpoint":[16],"envelopeId":[1,"envelope-id"],"canSendAnother":[4,"can-send-another"],"canView":[4,"can-view"],"canDone":[4,"can-done"],"isOpen":[32],"loading":[32],"recipientStatusIcons":[32],"containerId":[32],"gettingLinks":[32],"links":[32]}]]],["p-e1679e5b.system",[[0,"verdocs-quick-functions",{"endpoint":[16]}],[0,"verdocs-search-box",{"endpoint":[16],"placeholder":[1],"type":[1],"query":[1],"grabsFocus":[4,"grabs-focus"],"focusField":[64]}]]],["p-aed8139a.system",[[0,"verdocs-envelope-document-page",{"endpoint":[16],"envelopeId":[1,"envelope-id"],"documentId":[1,"document-id"],"pageNumber":[2,"page-number"],"virtualWidth":[2,"virtual-width"],"virtualHeight":[1026,"virtual-height"],"layers":[16],"type":[1],"containerId":[32],"renderedWidth":[32],"renderedHeight":[32],"naturalWidth":[32],"naturalHeight":[32],"aspectRatio":[32],"skipFirstNotification":[32],"pageDisplayUri":[32]}]]],["p-ba6570b4.system",[[4,"verdocs-button-panel",{"icon":[1],"showPanel":[64],"hidePanel":[64],"toggle":[64]}],[4,"verdocs-tabs",{"tabs":[16],"selectedTab":[2,"selected-tab"]}]]],["p-17050bcd.system",[[0,"verdocs-pagination",{"selectedPage":[1538,"selected-page"],"itemCount":[2,"item-count"],"perPage":[2,"per-page"]}],[0,"verdocs-quick-filter",{"options":[16],"label":[1],"value":[1537],"placeholder":[1],"open":[32]}]]],["p-daf07a17.system",[[0,"verdocs-spinner",{"size":[2],"mode":[1]}]]],["p-8ca0c8c2.system",[[0,"verdocs-toolbar-icon",{"text":[1],"icon":[1],"placement":[1],"containerId":[32]}],[0,"verdocs-template-document-page",{"endpoint":[16],"editable":[4],"disabled":[4],"done":[4],"templateId":[1,"template-id"],"documentId":[1,"document-id"],"pageNumber":[2,"page-number"],"virtualWidth":[2,"virtual-width"],"virtualHeight":[1026,"virtual-height"],"layers":[16],"containerId":[32],"renderedWidth":[32],"renderedHeight":[32],"naturalWidth":[32],"naturalHeight":[32],"aspectRatio":[32],"skipFirstNotification":[32],"pageDisplayUri":[32],"xScale":[32],"yScale":[32]}]]],["p-a1289b75.system",[[0,"verdocs-contact-picker",{"endpoint":[16],"templateRole":[16],"contactSuggestions":[16],"name":[32],"email":[32],"phone":[32],"message":[32],"showSuggestions":[32],"showMessage":[32],"delegator":[32],"showKba":[32],"kbaMethod":[32],"pinCode":[32],"nameFieldId":[32],"emailFieldId":[32],"phoneFieldId":[32]}],[0,"verdocs-toggle-button",{"active":[4],"icon":[1],"label":[1],"size":[1],"_active":[32]}]]],["p-f2884b26.system",[[0,"verdocs-file-chooser",{"endpoint":[16],"file":[32]}],[0,"verdocs-progress-bar",{"label":[1],"showPercent":[4,"show-percent"],"percent":[2]}]]],["p-d2feac5b.system",[[0,"verdocs-template-role-properties",{"endpoint":[16],"templateId":[1,"template-id"],"roleName":[1,"role-name"],"sender":[1],"dirty":[32],"saving":[32],"name":[32],"type":[32],"full_name":[32],"email":[32],"phone":[32],"delegator":[32]}],[0,"verdocs-template-sender",{"endpoint":[16],"templateId":[1,"template-id"],"sender":[1],"saving":[32]}],[0,"verdocs-radio-button",{"checked":[4],"name":[1],"value":[1],"disabled":[4]}]]],["p-71efd549.system",[[0,"verdocs-ok-dialog",{"heading":[1],"message":[1],"buttonLabel":[1,"button-label"],"showCancel":[4,"show-cancel"],"closed":[32]}]]],["p-1175926f.system",[[0,"verdocs-organization-card",{"organization":[16],"hovered":[32]},[[1,"mouseover","onMouseOver"],[1,"mouseout","onMouseOut"]]],[4,"verdocs-portal",{"anchor":[1],"voffset":[2],"align":[1]},[[11,"scroll","handleScroll"],[11,"resize","handleResize"],[10,"click","handleClick"]]]]],["p-73f45012.system",[[0,"verdocs-template-field-properties",{"endpoint":[16],"templateId":[1,"template-id"],"fieldName":[1025,"field-name"],"helpText":[1,"help-text"],"dirty":[32],"loading":[32],"setting":[32],"label":[32],"type":[32],"name":[32],"required":[32],"roleName":[32],"group":[32],"fieldType":[32],"options":[32],"placeholder":[32],"value":[32],"leading":[32],"showingHelp":[32]}],[0,"verdocs-select-input",{"value":[1],"label":[1],"options":[16],"disabled":[4]}],[0,"verdocs-checkbox",{"checked":[4],"name":[1],"label":[1],"value":[1],"theme":[1],"disabled":[4]}],[0,"verdocs-component-error",{"message":[1]}]]],["p-6bbea733.system",[[0,"verdocs-field-attachment",{"endpoint":[16],"templateid":[513],"fieldname":[513],"disabled":[516],"editable":[516],"moveable":[516],"done":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"showingProperties":[32],"selectedFile":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-initial",{"templateid":[513],"fieldname":[513],"disabled":[516],"initials":[513],"editable":[516],"moveable":[516],"done":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"showingProperties":[32],"focused":[32],"tempInitials":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-signature",{"templateid":[513],"fieldname":[513],"name":[513],"disabled":[516],"editable":[516],"moveable":[516],"done":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"showingProperties":[32],"focused":[32],"tempSignature":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-checkbox",{"templateid":[513],"fieldname":[513],"option":[514],"disabled":[516],"done":[516],"editable":[516],"moveable":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"showingProperties":[32],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-date",{"templateid":[513],"fieldname":[513],"disabled":[516],"editable":[516],"moveable":[516],"done":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"field":[16],"containerId":[32],"showingProperties":[32],"focused":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-dropdown",{"templateid":[513],"fieldname":[513],"disabled":[516],"editable":[516],"moveable":[516],"done":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"showingProperties":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-radio-button",{"templateid":[513],"fieldname":[513],"option":[514],"disabled":[516],"done":[516],"editable":[516],"moveable":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"showingProperties":[32],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-textarea",{"endpoint":[16],"templateid":[513],"fieldname":[513],"disabled":[516],"editable":[516],"moveable":[516],"done":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"showingProperties":[32],"focused":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-textbox",{"endpoint":[16],"templateid":[513],"fieldname":[513],"disabled":[516],"editable":[516],"moveable":[516],"done":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"showingProperties":[32],"focused":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-timestamp",{"templateid":[513],"fieldname":[513],"disabled":[516],"editable":[516],"moveable":[516],"done":[516],"xscale":[514],"yscale":[514],"pagenumber":[2],"showingProperties":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-initial-dialog",{"initials":[1],"fontLoaded":[32],"enteredInitials":[32],"mode":[32]}],[0,"verdocs-signature-dialog",{"name":[1],"fontLoaded":[32],"enteredName":[32],"mode":[32]}],[0,"verdocs-upload-dialog",{"draggingOver":[32],"decodedFiles":[32]}]]],["p-51544250.system",[[0,"verdocs-template-fields",{"endpoint":[16],"templateId":[1,"template-id"],"toolbarTargetId":[1,"toolbar-target-id"],"placing":[32],"showMustSelectRole":[32],"selectedRoleName":[32],"loading":[32]},[[4,"keydown","handleKeyDown"]]],[0,"verdocs-preview",{"endpoint":[16],"templateId":[1,"template-id"],"loading":[32]},null,{"templateId":["onTemplateIdChanged"]}],[0,"verdocs-template-roles",{"endpoint":[16],"templateId":[1,"template-id"],"showingRoleDialog":[32],"showingSenderDialog":[32],"sender":[32],"loading":[32]}],[0,"verdocs-send",{"endpoint":[16],"templateId":[513,"template-id"],"environment":[1],"containerId":[32],"rolesAtLevel":[32],"showPickerForId":[32],"sessionContacts":[32],"sending":[32],"rolesCompleted":[32],"reset":[64]},null,{"templateId":["onTemplateIdChanged"]}],[0,"verdocs-template-attachments",{"endpoint":[16],"templateId":[1,"template-id"],"uploading":[32],"progressLabel":[32],"progressPercent":[32],"showDeleteError":[32],"confirmDeleteDocument":[32],"store":[32]}],[0,"verdocs-template-reminders",{"endpoint":[16],"templateId":[1,"template-id"],"showPlanBlocker":[32],"sendReminders":[32],"firstReminderDays":[32],"reminderDays":[32],"dirty":[32]}],[0,"verdocs-template-name",{"endpoint":[16],"templateId":[1,"template-id"],"name":[32],"dirty":[32]}],[0,"verdocs-template-create",{"endpoint":[16],"file":[32],"creating":[32],"progressLabel":[32],"progressPercent":[32]}],[0,"verdocs-template-build-tabs",{"endpoint":[16],"templateId":[1537,"template-id"],"step":[1537],"templateStore":[32]},null,{"templateId":["onTemplateIdChanged"],"step":["onStepChanged"]}],[0,"verdocs-template-visibility",{"endpoint":[16],"templateId":[1,"template-id"],"dirty":[32],"personal":[32],"public":[32]}]]]]'),t)]}}))}))}))}}}));
|
1
|
+
var __awaiter=this&&this.__awaiter||function(e,t,a,n){function i(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,d){function s(e){try{l(n.next(e))}catch(e){d(e)}}function o(e){try{l(n["throw"](e))}catch(e){d(e)}}function l(e){e.done?a(e.value):i(e.value).then(s,o)}l((n=n.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var a={label:0,sent:function(){if(d[0]&1)throw d[1];return d[1]},trys:[],ops:[]},n,i,d,s;return s={next:o(0),throw:o(1),return:o(2)},typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function o(e){return function(t){return l([e,t])}}function l(o){if(n)throw new TypeError("Generator is already executing.");while(s&&(s=0,o[0]&&(a=0)),a)try{if(n=1,i&&(d=o[0]&2?i["return"]:o[0]?i["throw"]||((d=i["return"])&&d.call(i),0):i.next)&&!(d=d.call(i,o[1])).done)return d;if(i=0,d)o=[o[0]&2,d.value];switch(o[0]){case 0:case 1:d=o;break;case 4:a.label++;return{value:o[1],done:false};case 5:a.label++;i=o[1];o=[0];continue;case 7:o=a.ops.pop();a.trys.pop();continue;default:if(!(d=a.trys,d=d.length>0&&d[d.length-1])&&(o[0]===6||o[0]===2)){a=0;continue}if(o[0]===3&&(!d||o[1]>d[0]&&o[1]<d[3])){a.label=o[1];break}if(o[0]===6&&a.label<d[1]){a.label=d[1];d=o;break}if(d&&a.label<d[2]){a.label=d[2];a.ops.push(o);break}if(d[2])a.ops.pop();a.trys.pop();continue}o=t.call(e,a)}catch(e){o=[6,e];i=0}finally{n=d=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:true}}};System.register(["./p-e748b2d2.system.js","./p-56ba5cbf.system.js"],(function(e,t){"use strict";var a,n,i;return{setters:[function(t){a=t.p;n=t.b;e("setNonce",t.s)},function(e){i=e.g}],execute:function(){var e=this;var d=function(){var e=t.meta.url;var n={};if(e!==""){n.resourcesUrl=new URL(".",e).href}return a(n)};d().then((function(t){return __awaiter(e,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return[4,i()];case 1:e.sent();return[2,n(JSON.parse('[["p-977a5a4b.system",[[0,"verdocs-build",{"endpoint":[16],"templateId":[1537,"template-id"],"step":[1537],"templateStore":[32]},null,{"templateId":["onTemplateIdChanged"],"step":["onStepChanged"]}]]],["p-ee08c75b.system",[[0,"verdocs-envelopes-list",{"endpoint":[16],"view":[1537],"status":[1537],"sort":[1537],"match":[1537],"showPagination":[4,"show-pagination"],"rowsPerPage":[2,"rows-per-page"],"selectedPage":[2,"selected-page"],"count":[32],"initiallyLoaded":[32],"loading":[32],"selectedEnvelopes":[32],"envelopes":[32]},null,{"view":["handleViewUpdated"],"status":["handleStatusUpdated"],"sort":["handleSortUpdated"],"match":["handleMatchUpdated"],"selectedPage":["handlePageUpdated"]}]]],["p-b7397955.system",[[0,"verdocs-templates-list",{"endpoint":[16],"sharing":[1537],"starred":[1537],"sort":[1537],"name":[1537],"allowedActions":[1040],"showPagination":[4,"show-pagination"],"rowsPerPage":[2,"rows-per-page"],"selectedPage":[2,"selected-page"],"count":[32],"initiallyLoaded":[32],"loading":[32],"confirmDelete":[32],"templates":[32],"localNameFilter":[32]},null,{"sharing":["handleSharingUpdated"],"starred":["handleStarredUpdated"],"sort":["handleSortUpdated"],"name":["handleNameUpdated"],"selectedPage":["handlePageUpdated"]}]]],["p-8d0807ab.system",[[0,"verdocs-sign",{"envelopeId":[1,"envelope-id"],"roleId":[1,"role-id"],"inviteCode":[1,"invite-code"],"headerTargetId":[1,"header-target-id"],"envelope":[32],"roleNames":[32],"sortedRecipients":[32],"recipient":[32],"hasSignature":[32],"nextButtonLabel":[32],"nextSubmits":[32],"errorMessage":[32],"focusedField":[32],"submitting":[32],"isDone":[32],"showDone":[32],"showLoadError":[32],"finishLater":[32],"showFinishLater":[32],"agreed":[32],"documentsSingularPlural":[32]}]]],["p-2be9ba53.system",[[0,"verdocs-envelope-sidebar",{"endpoint":[16],"envelopeId":[1,"envelope-id"],"activeTab":[32],"panelOpen":[32],"showManageDialog":[32],"showRecipientDialog":[32],"showCancelDialog":[32],"loading":[32]}]]],["p-dd426399.system",[[0,"verdocs-auth",{"endpoint":[16],"visible":[4],"logo":[1],"isAuthenticated":[32],"displayMode":[32],"org_name":[32],"first_name":[32],"last_name":[32],"username":[32],"password":[32],"submitting":[32],"activeSession":[32],"accountType":[32],"signupStep":[32],"resendDisabled":[32],"checkingOrg":[32]}]]],["p-50aa20d5.system",[[0,"verdocs-search",{"endpoint":[16]}]]],["p-b96e571d.system",[[0,"verdocs-activity-box",{"endpoint":[16],"items":[2],"view":[1],"header":[1],"title":[32],"count":[32],"loading":[32],"entries":[32]},null,{"items":["handleItemsUpdated"],"view":["handleViewUpdated"]}]]],["p-fdb77c22.system",[[0,"verdocs-kba-dialog",{"step":[2],"steps":[2],"helptitle":[1],"helptext":[1],"mode":[1],"label":[1],"placeholder":[1],"choices":[16],"response":[32]}]]],["p-fc5e568d.system",[[4,"verdocs-dialog"]]],["p-98928410.system",[[0,"verdocs-field-payment",{"templateid":[1],"fieldname":[1],"disabled":[4],"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],"xscale":[2],"yscale":[2],"pagenumber":[2],"roleindex":[2],"preparedMessage":[32],"signatureUrl":[32],"showingProperties":[32],"showSettingsPanel":[64],"hideSettingsPanel":[64]}]]],["p-8ee31f33.system",[[0,"verdocs-search-tabs",{"selected":[32]}]]],["p-3f4b3548.system",[[0,"verdocs-table",{"columns":[16],"data":[16]}]]],["p-9ce9d353.system",[[0,"verdocs-template-card",{"template":[16]}]]],["p-08210588.system",[[0,"verdocs-template-tags",{"tags":[16]}]]],["p-c293ad2e.system",[[0,"verdocs-toggle",{"options":[16],"theme":[1],"selectedOption":[32]}]]],["p-dcbad099.system",[[0,"verdocs-dropdown",{"options":[16]},[[9,"resize","handleResize"]]]]],["p-9452b95d.system",[[0,"verdocs-loader"]]],["p-1030a0b7.system",[[0,"verdocs-text-input",{"value":[1537],"label":[1],"placeholder":[1],"autocomplete":[1],"helpText":[1,"help-text"],"clearable":[4],"copyable":[4],"type":[1],"disabled":[4],"required":[4]}],[0,"verdocs-help-icon",{"text":[1],"icon":[1],"containerId":[32]}],[0,"verdocs-button",{"label":[1],"startIcon":[1,"start-icon"],"endIcon":[1,"end-icon"],"size":[1],"type":[1],"variant":[1],"disabled":[4]}]]],["p-a2a0c7b4.system",[[0,"verdocs-view",{"endpoint":[16],"envelopeId":[1,"envelope-id"],"headerTargetId":[1,"header-target-id"],"canceling":[32],"envelope":[32],"roleNames":[32],"showCancelDone":[32]}]]],["p-cef88396.system",[[0,"verdocs-status-indicator",{"size":[1],"theme":[1],"status":[1],"envelope":[16],"isOpen":[32],"containerId":[32]}]]],["p-6fc92b73.system",[[0,"verdocs-template-star",{"endpoint":[16],"template":[1040],"updating":[32]}]]],["p-48fce604.system",[[0,"verdocs-envelope-recipient-link",{"endpoint":[16],"envelopeId":[1,"envelope-id"],"roleName":[1,"role-name"],"isOpen":[32],"loading":[32],"gettingLink":[32],"link":[32]}],[0,"verdocs-envelope-recipient-summary",{"endpoint":[16],"envelopeId":[1,"envelope-id"],"canSendAnother":[4,"can-send-another"],"canView":[4,"can-view"],"canDone":[4,"can-done"],"isOpen":[32],"loading":[32],"recipientStatusIcons":[32],"containerId":[32],"gettingLinks":[32],"links":[32]}]]],["p-e1679e5b.system",[[0,"verdocs-quick-functions",{"endpoint":[16]}],[0,"verdocs-search-box",{"endpoint":[16],"placeholder":[1],"type":[1],"query":[1],"grabsFocus":[4,"grabs-focus"],"focusField":[64]}]]],["p-aed8139a.system",[[0,"verdocs-envelope-document-page",{"endpoint":[16],"envelopeId":[1,"envelope-id"],"documentId":[1,"document-id"],"pageNumber":[2,"page-number"],"virtualWidth":[2,"virtual-width"],"virtualHeight":[1026,"virtual-height"],"layers":[16],"type":[1],"containerId":[32],"renderedWidth":[32],"renderedHeight":[32],"naturalWidth":[32],"naturalHeight":[32],"aspectRatio":[32],"skipFirstNotification":[32],"pageDisplayUri":[32]}]]],["p-ba6570b4.system",[[4,"verdocs-button-panel",{"icon":[1],"showPanel":[64],"hidePanel":[64],"toggle":[64]}],[4,"verdocs-tabs",{"tabs":[16],"selectedTab":[2,"selected-tab"]}]]],["p-17050bcd.system",[[0,"verdocs-pagination",{"selectedPage":[1538,"selected-page"],"itemCount":[2,"item-count"],"perPage":[2,"per-page"]}],[0,"verdocs-quick-filter",{"options":[16],"label":[1],"value":[1537],"placeholder":[1],"open":[32]}]]],["p-daf07a17.system",[[0,"verdocs-spinner",{"size":[2],"mode":[1]}]]],["p-8ca0c8c2.system",[[0,"verdocs-toolbar-icon",{"text":[1],"icon":[1],"placement":[1],"containerId":[32]}],[0,"verdocs-template-document-page",{"endpoint":[16],"editable":[4],"disabled":[4],"done":[4],"templateId":[1,"template-id"],"documentId":[1,"document-id"],"pageNumber":[2,"page-number"],"virtualWidth":[2,"virtual-width"],"virtualHeight":[1026,"virtual-height"],"layers":[16],"containerId":[32],"renderedWidth":[32],"renderedHeight":[32],"naturalWidth":[32],"naturalHeight":[32],"aspectRatio":[32],"skipFirstNotification":[32],"pageDisplayUri":[32],"xScale":[32],"yScale":[32]}]]],["p-a1289b75.system",[[0,"verdocs-contact-picker",{"endpoint":[16],"templateRole":[16],"contactSuggestions":[16],"name":[32],"email":[32],"phone":[32],"message":[32],"showSuggestions":[32],"showMessage":[32],"delegator":[32],"showKba":[32],"kbaMethod":[32],"pinCode":[32],"nameFieldId":[32],"emailFieldId":[32],"phoneFieldId":[32]}],[0,"verdocs-toggle-button",{"active":[4],"icon":[1],"label":[1],"size":[1],"_active":[32]}]]],["p-f2884b26.system",[[0,"verdocs-file-chooser",{"endpoint":[16],"file":[32]}],[0,"verdocs-progress-bar",{"label":[1],"showPercent":[4,"show-percent"],"percent":[2]}]]],["p-d2feac5b.system",[[0,"verdocs-template-role-properties",{"endpoint":[16],"templateId":[1,"template-id"],"roleName":[1,"role-name"],"sender":[1],"dirty":[32],"saving":[32],"name":[32],"type":[32],"full_name":[32],"email":[32],"phone":[32],"delegator":[32]}],[0,"verdocs-template-sender",{"endpoint":[16],"templateId":[1,"template-id"],"sender":[1],"saving":[32]}],[0,"verdocs-radio-button",{"checked":[4],"name":[1],"value":[1],"disabled":[4]}]]],["p-71efd549.system",[[0,"verdocs-ok-dialog",{"heading":[1],"message":[1],"buttonLabel":[1,"button-label"],"showCancel":[4,"show-cancel"],"closed":[32]}]]],["p-1175926f.system",[[0,"verdocs-organization-card",{"organization":[16],"hovered":[32]},[[1,"mouseover","onMouseOver"],[1,"mouseout","onMouseOut"]]],[4,"verdocs-portal",{"anchor":[1],"voffset":[2],"align":[1]},[[11,"scroll","handleScroll"],[11,"resize","handleResize"],[10,"click","handleClick"]]]]],["p-73f45012.system",[[0,"verdocs-template-field-properties",{"endpoint":[16],"templateId":[1,"template-id"],"fieldName":[1025,"field-name"],"helpText":[1,"help-text"],"dirty":[32],"loading":[32],"setting":[32],"label":[32],"type":[32],"name":[32],"required":[32],"roleName":[32],"group":[32],"fieldType":[32],"options":[32],"placeholder":[32],"value":[32],"leading":[32],"showingHelp":[32]}],[0,"verdocs-select-input",{"value":[1],"label":[1],"options":[16],"disabled":[4]}],[0,"verdocs-checkbox",{"checked":[4],"name":[1],"label":[1],"value":[1],"theme":[1],"disabled":[4]}],[0,"verdocs-component-error",{"message":[1]}]]],["p-6bbea733.system",[[0,"verdocs-field-attachment",{"endpoint":[16],"templateid":[513],"fieldname":[513],"disabled":[516],"editable":[516],"moveable":[516],"done":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"showingProperties":[32],"selectedFile":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-initial",{"templateid":[513],"fieldname":[513],"disabled":[516],"initials":[513],"editable":[516],"moveable":[516],"done":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"showingProperties":[32],"focused":[32],"tempInitials":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-signature",{"templateid":[513],"fieldname":[513],"name":[513],"disabled":[516],"editable":[516],"moveable":[516],"done":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"showingProperties":[32],"focused":[32],"tempSignature":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-checkbox",{"templateid":[513],"fieldname":[513],"option":[514],"disabled":[516],"done":[516],"editable":[516],"moveable":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"showingProperties":[32],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-date",{"templateid":[513],"fieldname":[513],"disabled":[516],"editable":[516],"moveable":[516],"done":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"field":[16],"containerId":[32],"showingProperties":[32],"focused":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-dropdown",{"templateid":[513],"fieldname":[513],"disabled":[516],"editable":[516],"moveable":[516],"done":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"showingProperties":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-radio-button",{"templateid":[513],"fieldname":[513],"option":[514],"disabled":[516],"done":[516],"editable":[516],"moveable":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"showingProperties":[32],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-textarea",{"endpoint":[16],"templateid":[513],"fieldname":[513],"disabled":[516],"editable":[516],"moveable":[516],"done":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"showingProperties":[32],"focused":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-textbox",{"endpoint":[16],"templateid":[513],"fieldname":[513],"disabled":[516],"editable":[516],"moveable":[516],"done":[516],"xscale":[514],"yscale":[514],"pagenumber":[514],"showingProperties":[32],"focused":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-field-timestamp",{"templateid":[513],"fieldname":[513],"disabled":[516],"editable":[516],"moveable":[516],"done":[516],"xscale":[514],"yscale":[514],"pagenumber":[2],"showingProperties":[32],"focusField":[64],"showSettingsPanel":[64],"hideSettingsPanel":[64]}],[0,"verdocs-initial-dialog",{"initials":[1],"fontLoaded":[32],"enteredInitials":[32],"mode":[32]}],[0,"verdocs-signature-dialog",{"name":[1],"fontLoaded":[32],"enteredName":[32],"mode":[32]}],[0,"verdocs-upload-dialog",{"draggingOver":[32],"decodedFiles":[32]}]]],["p-51544250.system",[[0,"verdocs-template-fields",{"endpoint":[16],"templateId":[1,"template-id"],"toolbarTargetId":[1,"toolbar-target-id"],"placing":[32],"showMustSelectRole":[32],"selectedRoleName":[32],"loading":[32]},[[4,"keydown","handleKeyDown"]]],[0,"verdocs-preview",{"endpoint":[16],"templateId":[1,"template-id"],"loading":[32]},null,{"templateId":["onTemplateIdChanged"]}],[0,"verdocs-template-roles",{"endpoint":[16],"templateId":[1,"template-id"],"showingRoleDialog":[32],"showingSenderDialog":[32],"sender":[32],"loading":[32]}],[0,"verdocs-send",{"endpoint":[16],"templateId":[513,"template-id"],"environment":[1],"containerId":[32],"rolesAtLevel":[32],"showPickerForId":[32],"sessionContacts":[32],"sending":[32],"rolesCompleted":[32],"reset":[64]},null,{"templateId":["onTemplateIdChanged"]}],[0,"verdocs-template-attachments",{"endpoint":[16],"templateId":[1,"template-id"],"uploading":[32],"progressLabel":[32],"progressPercent":[32],"showDeleteError":[32],"confirmDeleteDocument":[32],"store":[32]}],[0,"verdocs-template-reminders",{"endpoint":[16],"templateId":[1,"template-id"],"showPlanBlocker":[32],"sendReminders":[32],"firstReminderDays":[32],"reminderDays":[32],"dirty":[32]}],[0,"verdocs-template-name",{"endpoint":[16],"templateId":[1,"template-id"],"name":[32],"dirty":[32]}],[0,"verdocs-template-create",{"endpoint":[16],"file":[32],"creating":[32],"progressLabel":[32],"progressPercent":[32]}],[0,"verdocs-template-build-tabs",{"endpoint":[16],"templateId":[1537,"template-id"],"step":[1537],"templateStore":[32]},null,{"templateId":["onTemplateIdChanged"],"step":["onStepChanged"]}],[0,"verdocs-template-visibility",{"endpoint":[16],"templateId":[1,"template-id"],"dirty":[32],"personal":[32],"public":[32]}]]]]'),t)]}}))}))}))}}}));
|
@@ -1 +1 @@
|
|
1
|
-
import{r as t,c as e,h as s}from"./p-73a6f972.js";import{VerdocsEndpoint as i,createProfile as o,authenticate as l,decodeAccessTokenBody as n,resendVerification as a,resetPassword as r}from"@verdocs/js-sdk";import{V as d}from"./p-026b3103.js";import{S as c}from"./p-fd97809c.js";const h=class{constructor(s){t(this,s),this.authenticated=e(this,"authenticated",7),this.sdkError=e(this,"sdkError",7),this.recheckTimer=null,this.resendDisabledTimer=null,this.accessTokenForVerification=null,this.endpoint=i.getDefault(),this.visible=!0,this.logo="https://app.verdocs.com/assets/blue-logo.svg",this.isAuthenticated=!1,this.displayMode="login",this.org_name="",this.first_name="",this.last_name="",this.username="",this.password="",this.submitting=!1,this.activeSession=null,this.accountType="org",this.signupStep=1,this.resendDisabled=!1,this.checkingOrg=!1}componentWillLoad(){var t,e;this.endpoint.loadSession(),this.endpoint.session?(console.log("[AUTH] Authenticated"),this.isAuthenticated=!0,this.activeSession=this.endpoint.session,null===(t=this.authenticated)||void 0===t||t.emit({authenticated:!0,session:this.endpoint.session})):(console.log("[AUTH] Anonymous"),null===(e=this.authenticated)||void 0===e||e.emit({authenticated:!1,session:null}))}disconnectedCallback(){this.cancelRecheckTimer()}cancelRecheckTimer(){if(this.recheckTimer){try{clearTimeout(this.recheckTimer)}catch(t){}this.recheckTimer=null}if(this.resendDisabledTimer){try{clearTimeout(this.resendDisabledTimer)}catch(t){}this.resendDisabledTimer=null}}isPasswordComplex(t){const e=t=>/[A-Z]/.test(t),s=t=>/[a-z]/.test(t),i=t=>/[`!@#$%^&*()_\-+=\[\]{};':"\\|,.<>\/?~ ]/.test(t);let o=0,l=0,n=0;for(let a=0;a<t.length;a++){let r=t.charAt(a);e(r)?o++:s(r)?l++:i(r)&&n++}return t.length>=8&&l>0&&o>0&&n>0}handleSignup(){this.submitting=!0,this.accessTokenForVerification=null,this.isPasswordComplex(this.password)?o(this.endpoint,{email:this.username,password:this.password,first_name:this.first_name,last_name:this.last_name,org_name:this.org_name}).then((t=>{console.log("Profile creation result",t),this.loginAndCheckVerification()})).catch((t=>{var e,s,i,o,l,n;console.log("[AUTH] Signup error",t.response),this.submitting=!1,this.activeSession=null,null===(e=this.authenticated)||void 0===e||e.emit({authenticated:!1,session:null}),null===(s=this.sdkError)||void 0===s||s.emit(new c(t.message,null===(i=t.response)||void 0===i?void 0:i.status,null===(o=t.response)||void 0===o?void 0:o.data)),d("Signup failed: "+(null===(n=null===(l=t.response)||void 0===l?void 0:l.data)||void 0===n?void 0:n.message)||"Unknown Error",{style:"error"})})):window.alert("Password must be at least 8 characters long and contain at least one uppercase, one lowercase, and one special character.")}loginAndCheckVerification(){this.submitting=!0,this.accessTokenForVerification=null,l(this.endpoint,{username:this.username,password:this.password,grant_type:"password"}).then((t=>{var e;this.cancelRecheckTimer(),this.submitting=!1;const s=n(t.access_token);console.log("[AUTH] Got access token body",s),(null==s?void 0:s.email_verified)?(console.log("[AUTH] Email address is verified, completing login"),this.displayMode="login",this.accessTokenForVerification=null,this.endpoint.setToken(t.access_token),this.activeSession=this.endpoint.session,this.isAuthenticated=!0,null===(e=this.authenticated)||void 0===e||e.emit({authenticated:!0,session:this.endpoint.session})):(console.log("[AUTH] Logged in, pending email address verification"),this.displayMode="verify",this.accessTokenForVerification=t.access_token,this.recheckTimer=setTimeout(this.loginAndCheckVerification,5e3))})).catch((t=>{var e,s,i,o;this.cancelRecheckTimer(),console.log("[AUTH] Authentication error",t.response,JSON.stringify(t)),this.displayMode="login",this.submitting=!1,this.activeSession=null,null===(e=this.authenticated)||void 0===e||e.emit({authenticated:!1,session:null}),null===(s=this.sdkError)||void 0===s||s.emit(new c(t.message,null===(i=t.response)||void 0===i?void 0:i.status,null===(o=t.response)||void 0===o?void 0:o.data)),d("Login failed. Please check your username and password and try again.",{style:"error"})}))}handleLogout(){var t;this.endpoint.clearSession(),this.isAuthenticated=!1,this.accessTokenForVerification=null,null===(t=this.authenticated)||void 0===t||t.emit({authenticated:!1,session:null})}handleResend(){this.resendDisabled=!0,this.resendDisabledTimer=setTimeout((()=>{this.resendDisabled=!1,this.resendDisabledTimer=null}),3e4),a(this.endpoint,this.accessTokenForVerification).then((t=>{console.log("[AUTH] Verification request resent",t),d("Please check your email for a message with verification instructions.",{style:"info"})})).catch((t=>{console.log("[AUTH] Unable to resend verification",t)}))}handleReset(){this.submitting=!0,r(this.endpoint,{email:this.username}).then((t=>{console.log("[AUTH] Reset sent",t),this.submitting=!1,this.displayMode="login",d("If your email address is registered, you will receive instructions on resetting your password shortly.",{style:"info"})})).catch((t=>{console.log("[AUTH] Unable to reset password",t),this.submitting=!1}))}render(){if(!this.visible)return s("div",{style:{display:"none"}},"Authenticated");if(this.isAuthenticated)return s("verdocs-button",{label:"Sign Out",disabled:this.submitting,onClick:()=>this.handleLogout(),style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}});if("signup"===this.displayMode){const t=this.submitting||!this.first_name||!this.last_name||!this.username||!this.password||!this.org_name;return s("div",{class:"form"},s("a",{href:"https://verdocs.com/en/"},s("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),s("h3",null,"Sign up for a free account"),s("h4",null,"Already have an account?",s("verdocs-button",{label:"Log In",variant:"text",onClick:()=>this.displayMode="login",disabled:this.submitting})),1===this.signupStep&&s("form",{onSubmit:()=>this.handleSignup()},s("div",{style:{display:"flex",flexDirection:"row",columnGap:"20px"}},s("verdocs-text-input",{label:"First Name",autocomplete:"first",required:!0,value:this.first_name,onInput:t=>this.first_name=t.target.value,disabled:this.submitting}),s("verdocs-text-input",{label:"Last Name",autocomplete:"last",required:!0,value:this.last_name,onInput:t=>this.last_name=t.target.value,disabled:this.submitting})),s("verdocs-text-input",{label:"Email Address",autocomplete:"email",required:!0,value:this.username,onInput:t=>this.username=t.target.value,disabled:this.submitting}),s("verdocs-text-input",{label:"Password",type:"password",required:!0,autocomplete:"current-password",value:this.password,onInput:t=>this.password=t.target.value,disabled:this.submitting}),s("verdocs-text-input",{label:"Organization Name",autocomplete:"org",required:!0,value:this.org_name,onInput:t=>this.org_name=t.target.value,disabled:this.submitting,style:{flex:"1"}}),s("div",{style:{marginTop:"30px"}}),s("verdocs-button",{label:"Next",disabled:t,onClick:()=>this.handleSignup(),style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}})),3===this.signupStep&&s("form",{onSubmit:()=>this.handleSignup()},s("p",null,"Please check your e-mail inbox for a verification code and follow the instructions provided."),s("p",null,s("em",null,"Verification messages may take up to 1 hour to arrive. If you do not receive the invitation, ",s("a",{href:"#"},"Click Here")," to resend it. Be sure to check your spam folder.")),s("div",{style:{display:"flex",flexDirection:"row",gap:"20px"}},s("verdocs-button",{label:"Back",disabled:this.submitting,onClick:()=>{this.signupStep=2},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}}),s("verdocs-button",{label:"Go to Dashboard",disabled:!0,onClick:()=>this.handleSignup(),style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}}))))}return"forgot"===this.displayMode?s("div",{class:"form"},s("a",{href:"https://verdocs.com/en/"},s("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),s("h3",null,"Forgot your password?"),s("p",null,"Enter your e-mail address below, and reset instructions will be sent to your Inbox."),s("p",null,s("em",null,"Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")),s("form",{onSubmit:()=>this.handleSignup()},s("verdocs-text-input",{label:"Email",autocomplete:"email",required:!0,value:this.username,onInput:t=>this.username=t.target.value,disabled:this.submitting}),s("div",{style:{marginTop:"30px"}}),s("div",{class:"buttons"},s("verdocs-button",{label:"Cancel",variant:"outline",disabled:this.submitting,onClick:()=>this.displayMode="login"}),s("verdocs-button",{label:"Reset",disabled:this.submitting,onClick:()=>this.handleReset()})))):"verify"===this.displayMode?s("div",{class:"form"},s("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"}),s("h3",null,"Please Verify your Email Address"),s("p",null,"Check your e-mail inbox for a verification email, and follow the instructions provided."),s("p",null,s("em",null,"Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")),s("div",{class:"buttons"},s("verdocs-button",{label:"Sign Out",variant:"outline",disabled:this.submitting,onClick:()=>{this.username="",this.password="",this.cancelRecheckTimer(),this.displayMode="login"}}),s("verdocs-button",{label:"Resend Email",disabled:this.resendDisabled,onClick:()=>this.handleResend()}))):s("div",{class:"form"},s("a",{href:"https://verdocs.com/en/"},s("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),s("h3",null,"Log in to your account"),s("h4",null,"Don't have an account?",s("verdocs-button",{label:"Sign Up",variant:"text",onClick:()=>{this.displayMode="signup",this.signupStep=1},disabled:this.submitting})),s("form",{onSubmit:()=>this.loginAndCheckVerification()},s("verdocs-text-input",{label:"Email",autocomplete:"username",value:this.username,onInput:t=>this.username=t.target.value,disabled:this.submitting}),s("verdocs-text-input",{label:"Password",type:"password",autocomplete:"current-password",value:this.password,onInput:t=>this.password=t.target.value,disabled:this.submitting}),s("verdocs-button",{label:"Forgot Your Password?",variant:"text",onClick:()=>this.displayMode="forgot",disabled:this.submitting,style:{display:"flex",justifyContent:"center",margin:"10px auto 20px"}}),s("verdocs-button",{label:"Login",disabled:this.submitting,onClick:()=>this.loginAndCheckVerification(),style:{display:"flex",justifyContent:"center",margin:"10px auto 0"}})))}};h.style='@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-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 .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 h4 verdocs-button button.normal .button-label{padding:0}verdocs-auth .buttons{gap:20px;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth .status-result{display:none}verdocs-auth .status-result.debug{white-space:pre-wrap;font-size:14px;background:#fff;padding:10px;display:block;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth form{width:100%}verdocs-auth verdocs-text-input{margin-bottom:10px}verdocs-auth .account-option{gap:8px;margin:20px 0 8px 0;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-auth p+p{margin-top:0}verdocs-auth verdocs-help-icon{margin-top:18px;display:-ms-flexbox;display:flex;width:32px;height:32px;-ms-flex:0 0 32px;flex:0 0 32px}';export{h as verdocs_auth}
|
1
|
+
import{r as t,c as e,h as i}from"./p-73a6f972.js";import{VerdocsEndpoint as s,createProfile as o,authenticate as l,decodeAccessTokenBody as n,resendVerification as a,resetPassword as r}from"@verdocs/js-sdk";import{V as d}from"./p-026b3103.js";import{S as h}from"./p-fd97809c.js";const c=class{constructor(i){t(this,i),this.authenticated=e(this,"authenticated",7),this.sdkError=e(this,"sdkError",7),this.recheckTimer=null,this.resendDisabledTimer=null,this.accessTokenForVerification=null,this.endpoint=s.getDefault(),this.visible=!0,this.logo="https://app.verdocs.com/assets/blue-logo.svg",this.isAuthenticated=!1,this.displayMode="login",this.org_name="",this.first_name="",this.last_name="",this.username="",this.password="",this.submitting=!1,this.activeSession=null,this.accountType="org",this.signupStep=1,this.resendDisabled=!1,this.checkingOrg=!1}componentWillLoad(){var t,e;this.endpoint.loadSession(),this.endpoint.session?(console.log("[AUTH] Authenticated"),this.isAuthenticated=!0,this.activeSession=this.endpoint.session,null===(t=this.authenticated)||void 0===t||t.emit({authenticated:!0,session:this.endpoint.session})):(console.log("[AUTH] Anonymous"),null===(e=this.authenticated)||void 0===e||e.emit({authenticated:!1,session:null}))}disconnectedCallback(){this.cancelRecheckTimer()}cancelRecheckTimer(){if(this.recheckTimer){try{clearTimeout(this.recheckTimer)}catch(t){}this.recheckTimer=null}if(this.resendDisabledTimer){try{clearTimeout(this.resendDisabledTimer)}catch(t){}this.resendDisabledTimer=null}}isPasswordComplex(t){const e=t=>/[A-Z]/.test(t),i=t=>/[a-z]/.test(t),s=t=>/[`!@#$%^&*()_\-+=\[\]{};':"\\|,.<>\/?~ ]/.test(t);let o=0,l=0,n=0;for(let a=0;a<t.length;a++){let r=t.charAt(a);e(r)?o++:i(r)?l++:s(r)&&n++}return t.length>=8&&l>0&&o>0&&n>0}handleSignup(){this.submitting=!0,this.accessTokenForVerification=null,this.isPasswordComplex(this.password)?o(this.endpoint,{email:this.username,password:this.password,first_name:this.first_name,last_name:this.last_name,org_name:this.org_name}).then((t=>{console.log("Profile creation result",t),this.loginAndCheckVerification()})).catch((t=>{var e,i,s,o,l,n;console.log("[AUTH] Signup error",t.response),this.submitting=!1,this.activeSession=null,null===(e=this.authenticated)||void 0===e||e.emit({authenticated:!1,session:null}),null===(i=this.sdkError)||void 0===i||i.emit(new h(t.message,null===(s=t.response)||void 0===s?void 0:s.status,null===(o=t.response)||void 0===o?void 0:o.data)),d("Signup failed: "+(null===(n=null===(l=t.response)||void 0===l?void 0:l.data)||void 0===n?void 0:n.message)||"Unknown Error",{style:"error"})})):window.alert("Password must be at least 8 characters long and contain at least one uppercase, one lowercase, and one special character.")}loginAndCheckVerification(){this.submitting=!0,this.accessTokenForVerification=null,l(this.endpoint,{username:this.username,password:this.password,grant_type:"password"}).then((t=>{var e;this.cancelRecheckTimer(),this.submitting=!1;const i=n(t.access_token);console.log("[AUTH] Got access token body",i),(null==i?void 0:i.email_verified)?(console.log("[AUTH] Email address is verified, completing login"),this.displayMode="login",this.accessTokenForVerification=null,this.endpoint.setToken(t.access_token),this.activeSession=this.endpoint.session,this.isAuthenticated=!0,null===(e=this.authenticated)||void 0===e||e.emit({authenticated:!0,session:this.endpoint.session})):(console.log("[AUTH] Logged in, pending email address verification"),this.displayMode="verify",this.accessTokenForVerification=t.access_token,this.recheckTimer=setTimeout(this.loginAndCheckVerification,5e3))})).catch((t=>{var e,i,s,o;this.cancelRecheckTimer(),console.log("[AUTH] Authentication error",t.response,JSON.stringify(t)),this.displayMode="login",this.submitting=!1,this.activeSession=null,null===(e=this.authenticated)||void 0===e||e.emit({authenticated:!1,session:null}),null===(i=this.sdkError)||void 0===i||i.emit(new h(t.message,null===(s=t.response)||void 0===s?void 0:s.status,null===(o=t.response)||void 0===o?void 0:o.data)),d("Login failed. Please check your username and password and try again.",{style:"error"})}))}handleLogout(){var t;this.endpoint.clearSession(),this.isAuthenticated=!1,this.accessTokenForVerification=null,null===(t=this.authenticated)||void 0===t||t.emit({authenticated:!1,session:null})}handleResend(){this.resendDisabled=!0,this.resendDisabledTimer=setTimeout((()=>{this.resendDisabled=!1,this.resendDisabledTimer=null}),3e4),a(this.endpoint,this.accessTokenForVerification).then((t=>{console.log("[AUTH] Verification request resent",t),d("Please check your email for a message with verification instructions.",{style:"info"})})).catch((t=>{console.log("[AUTH] Unable to resend verification",t)}))}handleReset(){this.submitting=!0,r(this.endpoint,{email:this.username}).then((t=>{console.log("[AUTH] Reset sent",t),this.submitting=!1,this.displayMode="login",d("If your email address is registered, you will receive instructions on resetting your password shortly.",{style:"info"})})).catch((t=>{console.log("[AUTH] Unable to reset password",t),this.submitting=!1}))}render(){if(!this.visible)return i("div",{style:{display:"none"}},"Authenticated");if(this.isAuthenticated)return i("verdocs-button",{label:"Sign Out",disabled:this.submitting,onClick:()=>this.handleLogout(),style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}});if("signup"===this.displayMode){const t=this.submitting||!this.first_name||!this.last_name||!this.username||!this.password||!this.org_name;return i("div",{class:"form"},i("a",{href:"https://verdocs.com/en/"},i("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),i("h3",null,"Sign up for a free account"),i("h5",null,"Already have an account?",i("verdocs-button",{label:"Log In",variant:"text",onClick:()=>this.displayMode="login",disabled:this.submitting})),1===this.signupStep&&i("form",{onSubmit:()=>this.handleSignup()},i("div",{style:{display:"flex",flexDirection:"row",columnGap:"20px"}},i("verdocs-text-input",{label:"First Name",autocomplete:"first",required:!0,value:this.first_name,onInput:t=>this.first_name=t.target.value,disabled:this.submitting}),i("verdocs-text-input",{label:"Last Name",autocomplete:"last",required:!0,value:this.last_name,onInput:t=>this.last_name=t.target.value,disabled:this.submitting})),i("verdocs-text-input",{label:"Email Address",autocomplete:"email",required:!0,value:this.username,onInput:t=>this.username=t.target.value,disabled:this.submitting}),i("verdocs-text-input",{label:"Password",type:"password",required:!0,autocomplete:"current-password",value:this.password,onInput:t=>this.password=t.target.value,disabled:this.submitting}),i("verdocs-text-input",{label:"Organization Name",autocomplete:"org",required:!0,value:this.org_name,onInput:t=>this.org_name=t.target.value,disabled:this.submitting,style:{flex:"1"}}),i("div",{style:{marginTop:"30px"}}),i("verdocs-button",{label:"Next",disabled:t,onClick:()=>this.handleSignup(),style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}})),3===this.signupStep&&i("form",{onSubmit:()=>this.handleSignup()},i("p",null,"Please check your e-mail inbox for a verification code and follow the instructions provided."),i("p",null,i("em",null,"Verification messages may take up to 1 hour to arrive. If you do not receive the invitation, ",i("a",{href:"#"},"Click Here")," to resend it. Be sure to check your spam folder.")),i("div",{style:{display:"flex",flexDirection:"row",gap:"20px"}},i("verdocs-button",{label:"Back",disabled:this.submitting,onClick:()=>{this.signupStep=2},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}}),i("verdocs-button",{label:"Go to Dashboard",disabled:!0,onClick:()=>this.handleSignup(),style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}}))))}return"forgot"===this.displayMode?i("div",{class:"form"},i("a",{href:"https://verdocs.com/en/"},i("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),i("h3",null,"Forgot your password?"),i("p",null,"Enter your e-mail address below, and reset instructions will be sent to your Inbox."),i("p",null,i("em",null,"Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")),i("form",{onSubmit:()=>this.handleSignup()},i("verdocs-text-input",{label:"Email",autocomplete:"email",required:!0,value:this.username,onInput:t=>this.username=t.target.value,disabled:this.submitting}),i("div",{style:{marginTop:"30px"}}),i("div",{class:"buttons"},i("verdocs-button",{label:"Cancel",variant:"outline",disabled:this.submitting,onClick:()=>this.displayMode="login"}),i("verdocs-button",{label:"Reset",disabled:this.submitting,onClick:()=>this.handleReset()})))):"verify"===this.displayMode?i("div",{class:"form"},i("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"}),i("h6",null,"Please Verify your Email Address"),i("p",null,"Check your e-mail inbox for a verification email, and follow the instructions provided."),i("p",null,i("em",null,"Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")),i("div",{class:"buttons"},i("verdocs-button",{label:"Sign Out",variant:"outline",disabled:this.submitting,onClick:()=>{this.username="",this.password="",this.cancelRecheckTimer(),this.displayMode="login"}}),i("verdocs-button",{label:"Resend Email",disabled:this.resendDisabled,onClick:()=>this.handleResend()}))):i("div",{class:"form"},i("a",{href:"https://verdocs.com/en/"},i("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),i("h3",null,"Log in to your account"),i("h4",null,"Don't have an account?",i("verdocs-button",{label:"Sign Up",variant:"text",onClick:()=>{this.displayMode="signup",this.signupStep=1},disabled:this.submitting})),i("form",{onSubmit:()=>this.loginAndCheckVerification()},i("verdocs-text-input",{label:"Email",autocomplete:"username",value:this.username,onInput:t=>this.username=t.target.value,disabled:this.submitting}),i("verdocs-text-input",{label:"Password",type:"password",autocomplete:"current-password",value:this.password,onInput:t=>this.password=t.target.value,disabled:this.submitting}),i("verdocs-button",{label:"Forgot Your Password?",variant:"text",onClick:()=>this.displayMode="forgot",disabled:this.submitting,style:{display:"flex",justifyContent:"center",margin:"10px auto 20px"}}),i("verdocs-button",{label:"Login",disabled:this.submitting,onClick:()=>this.loginAndCheckVerification(),style:{display:"flex",justifyContent:"center",margin:"10px auto 0"}})))}};c.style='@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-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 .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 h4 verdocs-button button.normal .button-label{padding:0}verdocs-auth h6{text-align:center;font-weight:500;font-size:16px;line-height:1.75;margin:0 0 20px 0}verdocs-auth em{font-size:14px;margin:15px 0}verdocs-auth .buttons{gap:20px;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth .status-result{display:none}verdocs-auth .status-result.debug{white-space:pre-wrap;font-size:14px;background:#fff;padding:10px;display:block;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth form{width:100%}verdocs-auth verdocs-text-input{margin-bottom:10px}verdocs-auth .account-option{gap:8px;margin:20px 0 8px 0;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-auth p+p{margin-top:0}verdocs-auth verdocs-help-icon{margin-top:18px;display:-ms-flexbox;display:flex;width:32px;height:32px;-ms-flex:0 0 32px;flex:0 0 32px}';export{c as verdocs_auth}
|
@@ -0,0 +1 @@
|
|
1
|
+
System.register(["./p-e748b2d2.system.js","@verdocs/js-sdk","./p-7ce23c90.system.js","./p-c8a15cb7.system.js"],(function(e){"use strict";var t,i,n,o,s,r,l,a,u,c,d;return{setters:[function(e){t=e.r;i=e.c;n=e.h},function(e){o=e.VerdocsEndpoint;s=e.createProfile;r=e.authenticate;l=e.decodeAccessTokenBody;a=e.resendVerification;u=e.resetPassword},function(e){c=e.V},function(e){d=e.S}],execute:function(){var f='@-webkit-keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}@keyframes verdocs-field-pulse{0%{background-color:rgba(0, 0, 0, 0.35)}50%{background-color:rgba(0, 0, 0, 0)}100%{background-color:rgba(0, 0, 0, 0.35)}}verdocs-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 .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 h4 verdocs-button button.normal .button-label{padding:0}verdocs-auth h6{text-align:center;font-weight:500;font-size:16px;line-height:1.75;margin:0 0 20px 0}verdocs-auth em{font-size:14px;margin:15px 0}verdocs-auth .buttons{gap:20px;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth .status-result{display:none}verdocs-auth .status-result.debug{white-space:pre-wrap;font-size:14px;background:#fff;padding:10px;display:block;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:center;justify-content:center}verdocs-auth form{width:100%}verdocs-auth verdocs-text-input{margin-bottom:10px}verdocs-auth .account-option{gap:8px;margin:20px 0 8px 0;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row}verdocs-auth p+p{margin-top:0}verdocs-auth verdocs-help-icon{margin-top:18px;display:-ms-flexbox;display:flex;width:32px;height:32px;-ms-flex:0 0 32px;flex:0 0 32px}';var h=f;var p=5e3;var v=e("verdocs_auth",function(){function e(e){t(this,e);this.authenticated=i(this,"authenticated",7);this.sdkError=i(this,"sdkError",7);this.recheckTimer=null;this.resendDisabledTimer=null;this.accessTokenForVerification=null;this.endpoint=o.getDefault();this.visible=true;this.logo="https://app.verdocs.com/assets/blue-logo.svg";this.isAuthenticated=false;this.displayMode="login";this.org_name="";this.first_name="";this.last_name="";this.username="";this.password="";this.submitting=false;this.activeSession=null;this.accountType="org";this.signupStep=1;this.resendDisabled=false;this.checkingOrg=false}e.prototype.componentWillLoad=function(){var e,t;this.endpoint.loadSession();if(this.endpoint.session){console.log("[AUTH] Authenticated");this.isAuthenticated=true;this.activeSession=this.endpoint.session;(e=this.authenticated)===null||e===void 0?void 0:e.emit({authenticated:true,session:this.endpoint.session})}else{console.log("[AUTH] Anonymous");(t=this.authenticated)===null||t===void 0?void 0:t.emit({authenticated:false,session:null})}};e.prototype.disconnectedCallback=function(){this.cancelRecheckTimer()};e.prototype.cancelRecheckTimer=function(){if(this.recheckTimer){try{clearTimeout(this.recheckTimer)}catch(e){}this.recheckTimer=null}if(this.resendDisabledTimer){try{clearTimeout(this.resendDisabledTimer)}catch(e){}this.resendDisabledTimer=null}};e.prototype.isPasswordComplex=function(e){var t=function(e){return/[A-Z]/.test(e)};var i=function(e){return/[a-z]/.test(e)};var n=function(e){return/[`!@#$%^&*()_\-+=\[\]{};':"\\|,.<>\/?~ ]/.test(e)};var o=0,s=0,r=0;for(var l=0;l<e.length;l++){var a=e.charAt(l);if(t(a))o++;else if(i(a))s++;else if(n(a))r++}return e.length>=8&&s>0&&o>0&&r>0};e.prototype.handleSignup=function(){var e=this;this.submitting=true;this.accessTokenForVerification=null;if(!this.isPasswordComplex(this.password)){window.alert("Password must be at least 8 characters long and contain at least one uppercase, one lowercase, and one special character.");return}s(this.endpoint,{email:this.username,password:this.password,first_name:this.first_name,last_name:this.last_name,org_name:this.org_name}).then((function(t){console.log("Profile creation result",t);e.loginAndCheckVerification()})).catch((function(t){var i,n,o,s,r,l;console.log("[AUTH] Signup error",t.response);e.submitting=false;e.activeSession=null;(i=e.authenticated)===null||i===void 0?void 0:i.emit({authenticated:false,session:null});(n=e.sdkError)===null||n===void 0?void 0:n.emit(new d(t.message,(o=t.response)===null||o===void 0?void 0:o.status,(s=t.response)===null||s===void 0?void 0:s.data));c("Signup failed: "+((l=(r=t.response)===null||r===void 0?void 0:r.data)===null||l===void 0?void 0:l.message)||"Unknown Error",{style:"error"})}))};e.prototype.loginAndCheckVerification=function(){var e=this;this.submitting=true;this.accessTokenForVerification=null;r(this.endpoint,{username:this.username,password:this.password,grant_type:"password"}).then((function(t){var i;e.cancelRecheckTimer();e.submitting=false;var n=l(t.access_token);console.log("[AUTH] Got access token body",n);if(n===null||n===void 0?void 0:n.email_verified){console.log("[AUTH] Email address is verified, completing login");e.displayMode="login";e.accessTokenForVerification=null;e.endpoint.setToken(t.access_token);e.activeSession=e.endpoint.session;e.isAuthenticated=true;(i=e.authenticated)===null||i===void 0?void 0:i.emit({authenticated:true,session:e.endpoint.session})}else{console.log("[AUTH] Logged in, pending email address verification");e.displayMode="verify";e.accessTokenForVerification=t.access_token;e.recheckTimer=setTimeout(e.loginAndCheckVerification,p)}})).catch((function(t){var i,n,o,s;e.cancelRecheckTimer();console.log("[AUTH] Authentication error",t.response,JSON.stringify(t));e.displayMode="login";e.submitting=false;e.activeSession=null;(i=e.authenticated)===null||i===void 0?void 0:i.emit({authenticated:false,session:null});(n=e.sdkError)===null||n===void 0?void 0:n.emit(new d(t.message,(o=t.response)===null||o===void 0?void 0:o.status,(s=t.response)===null||s===void 0?void 0:s.data));c("Login failed. Please check your username and password and try again.",{style:"error"})}))};e.prototype.handleLogout=function(){var e;this.endpoint.clearSession();this.isAuthenticated=false;this.accessTokenForVerification=null;(e=this.authenticated)===null||e===void 0?void 0:e.emit({authenticated:false,session:null})};e.prototype.handleResend=function(){var e=this;this.resendDisabled=true;this.resendDisabledTimer=setTimeout((function(){e.resendDisabled=false;e.resendDisabledTimer=null}),3e4);a(this.endpoint,this.accessTokenForVerification).then((function(e){console.log("[AUTH] Verification request resent",e);c("Please check your email for a message with verification instructions.",{style:"info"})})).catch((function(e){console.log("[AUTH] Unable to resend verification",e)}))};e.prototype.handleReset=function(){var e=this;this.submitting=true;u(this.endpoint,{email:this.username}).then((function(t){console.log("[AUTH] Reset sent",t);e.submitting=false;e.displayMode="login";c("If your email address is registered, you will receive instructions on resetting your password shortly.",{style:"info"})})).catch((function(t){console.log("[AUTH] Unable to reset password",t);e.submitting=false}))};e.prototype.render=function(){var e=this;if(!this.visible){return n("div",{style:{display:"none"}},"Authenticated")}if(this.isAuthenticated){return n("verdocs-button",{label:"Sign Out",disabled:this.submitting,onClick:function(){return e.handleLogout()},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}})}if(this.displayMode==="signup"){var t=this.submitting||!this.first_name||!this.last_name||!this.username||!this.password||!this.org_name;return n("div",{class:"form"},n("a",{href:"https://verdocs.com/en/"},n("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),n("h3",null,"Sign up for a free account"),n("h5",null,"Already have an account?",n("verdocs-button",{label:"Log In",variant:"text",onClick:function(){return e.displayMode="login"},disabled:this.submitting})),this.signupStep===1&&n("form",{onSubmit:function(){return e.handleSignup()}},n("div",{style:{display:"flex",flexDirection:"row",columnGap:"20px"}},n("verdocs-text-input",{label:"First Name",autocomplete:"first",required:true,value:this.first_name,onInput:function(t){return e.first_name=t.target.value},disabled:this.submitting}),n("verdocs-text-input",{label:"Last Name",autocomplete:"last",required:true,value:this.last_name,onInput:function(t){return e.last_name=t.target.value},disabled:this.submitting})),n("verdocs-text-input",{label:"Email Address",autocomplete:"email",required:true,value:this.username,onInput:function(t){return e.username=t.target.value},disabled:this.submitting}),n("verdocs-text-input",{label:"Password",type:"password",required:true,autocomplete:"current-password",value:this.password,onInput:function(t){return e.password=t.target.value},disabled:this.submitting}),n("verdocs-text-input",{label:"Organization Name",autocomplete:"org",required:true,value:this.org_name,onInput:function(t){return e.org_name=t.target.value},disabled:this.submitting,style:{flex:"1"}}),n("div",{style:{marginTop:"30px"}}),n("verdocs-button",{label:"Next",disabled:t,onClick:function(){return e.handleSignup()},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}})),this.signupStep===3&&n("form",{onSubmit:function(){return e.handleSignup()}},n("p",null,"Please check your e-mail inbox for a verification code and follow the instructions provided."),n("p",null,n("em",null,"Verification messages may take up to 1 hour to arrive. If you do not receive the invitation, ",n("a",{href:"#"},"Click Here")," to resend it. Be sure to check your spam folder.")),n("div",{style:{display:"flex",flexDirection:"row",gap:"20px"}},n("verdocs-button",{label:"Back",disabled:this.submitting,onClick:function(){e.signupStep=2},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}}),n("verdocs-button",{label:"Go to Dashboard",disabled:true,onClick:function(){return e.handleSignup()},style:{display:"flex",justifyContent:"center",margin:"30px auto 0"}}))))}if(this.displayMode==="forgot"){return n("div",{class:"form"},n("a",{href:"https://verdocs.com/en/"},n("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),n("h3",null,"Forgot your password?"),n("p",null,"Enter your e-mail address below, and reset instructions will be sent to your Inbox."),n("p",null,n("em",null,"Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")),n("form",{onSubmit:function(){return e.handleSignup()}},n("verdocs-text-input",{label:"Email",autocomplete:"email",required:true,value:this.username,onInput:function(t){return e.username=t.target.value},disabled:this.submitting}),n("div",{style:{marginTop:"30px"}}),n("div",{class:"buttons"},n("verdocs-button",{label:"Cancel",variant:"outline",disabled:this.submitting,onClick:function(){return e.displayMode="login"}}),n("verdocs-button",{label:"Reset",disabled:this.submitting,onClick:function(){return e.handleReset()}}))))}if(this.displayMode==="verify"){return n("div",{class:"form"},n("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"}),n("h6",null,"Please Verify your Email Address"),n("p",null,"Check your e-mail inbox for a verification email, and follow the instructions provided."),n("p",null,n("em",null,"Please allow up to 24 hours for delivery, and check your spam folder if you do not receive the message. ")),n("div",{class:"buttons"},n("verdocs-button",{label:"Sign Out",variant:"outline",disabled:this.submitting,onClick:function(){e.username="";e.password="";e.cancelRecheckTimer();e.displayMode="login"}}),n("verdocs-button",{label:"Resend Email",disabled:this.resendDisabled,onClick:function(){return e.handleResend()}})))}return n("div",{class:"form"},n("a",{href:"https://verdocs.com/en/"},n("img",{src:this.logo,alt:"Verdocs Logo",class:"logo"})),n("h3",null,"Log in to your account"),n("h4",null,"Don't have an account?",n("verdocs-button",{label:"Sign Up",variant:"text",onClick:function(){e.displayMode="signup";e.signupStep=1},disabled:this.submitting})),n("form",{onSubmit:function(){return e.loginAndCheckVerification()}},n("verdocs-text-input",{label:"Email",autocomplete:"username",value:this.username,onInput:function(t){return e.username=t.target.value},disabled:this.submitting}),n("verdocs-text-input",{label:"Password",type:"password",autocomplete:"current-password",value:this.password,onInput:function(t){return e.password=t.target.value},disabled:this.submitting}),n("verdocs-button",{label:"Forgot Your Password?",variant:"text",onClick:function(){return e.displayMode="forgot"},disabled:this.submitting,style:{display:"flex",justifyContent:"center",margin:"10px auto 20px"}}),n("verdocs-button",{label:"Login",disabled:this.submitting,onClick:function(){return e.loginAndCheckVerification()},style:{display:"flex",justifyContent:"center",margin:"10px auto 0"}})))};return e}());v.style=h}}}));
|