{{deviceName}}. Click the button below to logout."
}
diff --git a/frontend/src/lib/i18n/locales/en.json b/frontend/src/lib/i18n/locales/en.json
index dd39a6ce..49b96659 100644
--- a/frontend/src/lib/i18n/locales/en.json
+++ b/frontend/src/lib/i18n/locales/en.json
@@ -84,5 +84,13 @@
"phoneScopeName": "Phone",
"phoneScopeDescription": "Allows the app to access your phone number.",
"addressScopeName": "Address",
- "addressScopeDescription": "Allows the app to access your address."
+ "addressScopeDescription": "Allows the app to access your address.",
+ "loginTailscaleTitle": "Continue with Tailscale",
+ "loginTailscaleDescription": "We detected that you are accessing Tinyauth from an authorized Tailscale device. Would you like to continue with your Tailscale connection?",
+ "loginTailscaleDeviceName": "Device name:",
+ "loginTailscaleSubmit": "Continue with Tailscale",
+ "loginTailscaleOtherMethod": "Login with another method",
+ "loginTailscaleSuccess": "Successfully authenticated with Tailscale.",
+ "loginTailscaleFail": "Failed to authenticate with Tailscale. Please try again or use another login method.",
+ "logoutTailscaleSubtitle": "You are currently logged in with Tailscale on your device {{deviceName}}. Click the button below to logout."
}
diff --git a/frontend/src/pages/login-page.tsx b/frontend/src/pages/login-page.tsx
index bc94abfd..26538cf3 100644
--- a/frontend/src/pages/login-page.tsx
+++ b/frontend/src/pages/login-page.tsx
@@ -158,8 +158,8 @@ export const LoginPage = () => {
mutationFn: () => axios.post("/api/user/tailscale"),
mutationKey: ["tailscale"],
onSuccess: () => {
- toast.success("Logged in", {
- description: t("Tailscale session confirmed"),
+ toast.success(t("loginSuccessTitle"), {
+ description: t("loginTailscaleSuccess"),
});
redirectTimer.current = window.setTimeout(() => {
@@ -173,8 +173,8 @@ export const LoginPage = () => {
}, 500);
},
onError: () => {
- toast.error("Failed to login", {
- description: "Failed to authenticate with Tailscale.",
+ toast.error(t("loginFailTitle"), {
+ description: t("loginTailscaleFail"),
});
},
});
@@ -266,17 +266,15 @@ export const LoginPage = () => {
{tailscale.nodeName}
+ {t("loginTailscaleDeviceName")} {tailscale.nodeName}
{tailscale.nodeName} node. Click the button below to
- log out.
+