From edb3f1c6170088866bf2f43432c1ccef7ba7b1a5 Mon Sep 17 00:00:00 2001 From: Ryan Wang Date: Tue, 8 Oct 2024 22:54:56 +0800 Subject: [PATCH] feat: add login link to signup page (#6780) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit #### What type of PR is this? /area core /kind improvement /milestone 2.20.x #### What this PR does / why we need it: 在注册表单底部添加登录入口。 image #### Which issue(s) this PR fixes: Fixes https://github.com/halo-dev/halo/issues/6770 #### Does this PR introduce a user-facing change? ```release-note None ``` --- .../gateway_modules/common_fragments.html | 70 +++++++++++++++++++ .../common_fragments.properties | 8 ++- .../common_fragments_en.properties | 8 ++- .../common_fragments_es.properties | 8 ++- .../common_fragments_zh_TW.properties | 8 ++- .../gateway_modules/login_fragments.html | 42 ----------- .../login_fragments.properties | 3 - .../login_fragments_en.properties | 3 - .../login_fragments_es.properties | 5 +- .../login_fragments_zh_TW.properties | 5 +- .../src/main/resources/templates/login.html | 3 +- .../src/main/resources/templates/signup.html | 2 + 12 files changed, 104 insertions(+), 61 deletions(-) diff --git a/application/src/main/resources/templates/gateway_modules/common_fragments.html b/application/src/main/resources/templates/gateway_modules/common_fragments.html index 6ce5f4a41..cb0bd48b5 100644 --- a/application/src/main/resources/templates/gateway_modules/common_fragments.html +++ b/application/src/main/resources/templates/gateway_modules/common_fragments.html @@ -119,3 +119,73 @@ + +
+ + +
+ +
+ + +
+ +
+ + +
diff --git a/application/src/main/resources/templates/gateway_modules/common_fragments.properties b/application/src/main/resources/templates/gateway_modules/common_fragments.properties index f079f83e5..36f5946b8 100644 --- a/application/src/main/resources/templates/gateway_modules/common_fragments.properties +++ b/application/src/main/resources/templates/gateway_modules/common_fragments.properties @@ -1,3 +1,9 @@ socialLogin.label=社交登录 js.sendVerificationCode.success=发送成功 -js.sendVerificationCode.failed=发送失败,请稍后再试 \ No newline at end of file +js.sendVerificationCode.failed=发送失败,请稍后再试 + +signupNotice.description=没有账号? +signupNotice.link=立即注册 +loginNotice.description=已有账号, +loginNotice.link=立即登录 +returnToSite=返回网站 \ No newline at end of file diff --git a/application/src/main/resources/templates/gateway_modules/common_fragments_en.properties b/application/src/main/resources/templates/gateway_modules/common_fragments_en.properties index cb299c93a..77019abe1 100644 --- a/application/src/main/resources/templates/gateway_modules/common_fragments_en.properties +++ b/application/src/main/resources/templates/gateway_modules/common_fragments_en.properties @@ -1,3 +1,9 @@ socialLogin.label=Social Login js.sendVerificationCode.success=Sent Successfully -js.sendVerificationCode.failed=Sending Failed, Please Try Again Later \ No newline at end of file +js.sendVerificationCode.failed=Sending Failed, Please Try Again Later + +signupNotice.description=Don't have an account? +signupNotice.link=Sign up +loginNotice.description=Already have an account, +loginNotice.link=Login now +returnToSite=Return to site \ No newline at end of file diff --git a/application/src/main/resources/templates/gateway_modules/common_fragments_es.properties b/application/src/main/resources/templates/gateway_modules/common_fragments_es.properties index cbda753fe..e79af3831 100644 --- a/application/src/main/resources/templates/gateway_modules/common_fragments_es.properties +++ b/application/src/main/resources/templates/gateway_modules/common_fragments_es.properties @@ -1,3 +1,9 @@ socialLogin.label=Inicio de Sesión Social js.sendVerificationCode.success=Enviado con éxito -js.sendVerificationCode.failed=Error al enviar, por favor intente nuevamente más tarde \ No newline at end of file +js.sendVerificationCode.failed=Error al enviar, por favor intente nuevamente más tarde + +signupNotice.description=¿No tienes una cuenta? +signupNotice.link=Regístrate ahora +loginNotice.description=Ya tienes una cuenta, +loginNotice.link=Inicia sesión ahora +returnToSite=Volver al sitio \ No newline at end of file diff --git a/application/src/main/resources/templates/gateway_modules/common_fragments_zh_TW.properties b/application/src/main/resources/templates/gateway_modules/common_fragments_zh_TW.properties index d55ad22de..ddc0d3f89 100644 --- a/application/src/main/resources/templates/gateway_modules/common_fragments_zh_TW.properties +++ b/application/src/main/resources/templates/gateway_modules/common_fragments_zh_TW.properties @@ -1,3 +1,9 @@ socialLogin.label=社交登入 js.sendVerificationCode.success=發送成功 -js.sendVerificationCode.failed=發送失敗,請稍後再試 \ No newline at end of file +js.sendVerificationCode.failed=發送失敗,請稍後再試 + +signupNotice.description=沒有帳號? +signupNotice.link=立即註冊 +loginNotice.description=已有帳號, +loginNotice.link=立即登入 +returnToSite=返回網站 \ No newline at end of file diff --git a/application/src/main/resources/templates/gateway_modules/login_fragments.html b/application/src/main/resources/templates/gateway_modules/login_fragments.html index 2d6d0f95c..20cbfd22d 100644 --- a/application/src/main/resources/templates/gateway_modules/login_fragments.html +++ b/application/src/main/resources/templates/gateway_modules/login_fragments.html @@ -18,45 +18,3 @@ - -
- - - -
diff --git a/application/src/main/resources/templates/gateway_modules/login_fragments.properties b/application/src/main/resources/templates/gateway_modules/login_fragments.properties index a5b4cc3d2..5396009aa 100644 --- a/application/src/main/resources/templates/gateway_modules/login_fragments.properties +++ b/application/src/main/resources/templates/gateway_modules/login_fragments.properties @@ -1,7 +1,4 @@ otherLogin.label=其他登录方式 -signup.description=没有账号? -signup.link=立即注册 -returnToSite=返回网站 # Rule: `formAuthProviders.${provider.metadata.name}.displayName` formAuthProviders.local.displayName=账号密码登录 \ No newline at end of file diff --git a/application/src/main/resources/templates/gateway_modules/login_fragments_en.properties b/application/src/main/resources/templates/gateway_modules/login_fragments_en.properties index 39a5fc7b5..2ac24fcf2 100644 --- a/application/src/main/resources/templates/gateway_modules/login_fragments_en.properties +++ b/application/src/main/resources/templates/gateway_modules/login_fragments_en.properties @@ -1,7 +1,4 @@ otherLogin.label=Other Login -signup.description=Don't have an account? -signup.link=Sign up -returnToSite=Return to site # Rule: `formAuthProviders.${provider.metadata.name}.displayName` formAuthProviders.local.displayName=Login with credentials \ No newline at end of file diff --git a/application/src/main/resources/templates/gateway_modules/login_fragments_es.properties b/application/src/main/resources/templates/gateway_modules/login_fragments_es.properties index a714b589a..90da22132 100644 --- a/application/src/main/resources/templates/gateway_modules/login_fragments_es.properties +++ b/application/src/main/resources/templates/gateway_modules/login_fragments_es.properties @@ -1,7 +1,4 @@ otherLogin.label=Otras formas de inicio de sesión -signup.description=¿No tienes una cuenta? -signup.link=Regístrate ahora -returnToSite=Volver al sitio # Rule: `formAuthProviders.${provider.metadata.name}.displayName` -formAuthProviders.local.displayName=Iniciar sesión con credenciales +formAuthProviders.local.displayName=Iniciar sesión con credenciales \ No newline at end of file diff --git a/application/src/main/resources/templates/gateway_modules/login_fragments_zh_TW.properties b/application/src/main/resources/templates/gateway_modules/login_fragments_zh_TW.properties index b0e101238..8a96457de 100644 --- a/application/src/main/resources/templates/gateway_modules/login_fragments_zh_TW.properties +++ b/application/src/main/resources/templates/gateway_modules/login_fragments_zh_TW.properties @@ -1,7 +1,4 @@ otherLogin.label=其他登入方式 -signup.description=沒有帳號? -signup.link=立即註冊 -returnToSite=返回網站 # Rule: `formAuthProviders.${provider.metadata.name}.displayName` -formAuthProviders.local.displayName=帳號密碼登入 +formAuthProviders.local.displayName=帳號密碼登入 \ No newline at end of file diff --git a/application/src/main/resources/templates/login.html b/application/src/main/resources/templates/login.html index 4d8513891..ac00d57c8 100644 --- a/application/src/main/resources/templates/login.html +++ b/application/src/main/resources/templates/login.html @@ -13,7 +13,8 @@
-
+
+
diff --git a/application/src/main/resources/templates/signup.html b/application/src/main/resources/templates/signup.html index 1aca0da13..e602bad92 100644 --- a/application/src/main/resources/templates/signup.html +++ b/application/src/main/resources/templates/signup.html @@ -18,6 +18,8 @@
+
+