@@ -70,6 +84,7 @@ export default {
signingInWithEmail: false,
emailRegex:
/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9-]+(?:\.[a-zA-Z0-9-]+)*$/,
+ mode: "sign-in",
}
},
mounted() {
@@ -98,10 +113,7 @@ export default {
await fb
.signInWithEmail(this.form.email, actionCodeSettings)
.then(() => {
- this.$toast.success("Check your inbox", {
- icon: "email",
- duration: 0,
- })
+ this.mode = "email"
window.localStorage.setItem("emailForSignIn", this.form.email)
})
.catch((error) => {
@@ -115,6 +127,7 @@ export default {
})
},
hideModal() {
+ this.mode = "sign-in"
this.$toast.clear()
this.$emit("hide-modal")
},
diff --git a/lang/en-US.json b/lang/en-US.json
index 2d31176b3..34bac43bd 100644
--- a/lang/en-US.json
+++ b/lang/en-US.json
@@ -333,5 +333,9 @@
"user_removed": "User removed successfully",
"import_from_my_collections": "Import from My Collections",
"export_as_json": "Export as JSON",
- "send_magic_link": "Send a magic link to sign in"
+ "send_magic_link": "Send a magic link to sign in",
+ "check_your_inbox": "Check your inbox.",
+ "you_can_dismiss_this_modal": "You can dismiss this ",
+ "we_sent_magic_link": "We sent you a magic link!",
+ "we_sent_magic_link_description": "We sent an email to {email}. It contains a magic link that’ll log you in."
}