feat(branding): customize Gita platform experience
giteabot backport / giteabot (push) Canceled after 0s
giteabot / giteabot (push) Canceled after 0s
release-nightly / nightly-binary (push) Canceled after 0s
release-nightly / nightly-container (push) Canceled after 0s
release-nightly-snapcraft / build-and-publish (push) Canceled after 0s

Assisted-by: Codex:GPT-5
This commit is contained in:
2026-08-16 07:45:24 +08:00
parent e4afba3416
commit 442ddc5f0d
27 changed files with 129 additions and 123 deletions
+8 -2
View File
@@ -40,7 +40,7 @@ import (
)
const (
tplSignIn templates.TplName = "user/auth/signin" // for sign in page
tplSignIn templates.TplName = "home" // sign in is part of the landing page
tplSignUp templates.TplName = "user/auth/signup" // for sign up page
TplActivate templates.TplName = "user/auth/activate" // for activate user
TplActivatePrompt templates.TplName = "user/auth/activate_prompt" // for showing a message for user activation
@@ -254,9 +254,10 @@ func prepareSignInPageData(ctx *context.Context) (ret preparedSignInData) {
ctx.Data["Title"] = ctx.Tr("sign_in")
ctx.Data["OAuth2Providers"] = ret.oauth2Providers
ctx.Data["Title"] = ctx.Tr("sign_in")
ctx.Data["SignInLink"] = setting.AppSubURL + "/user/login"
ctx.Data["SignInLink"] = setting.AppSubURL + "/"
ctx.Data["PageIsSignIn"] = true
ctx.Data["PageIsLogin"] = true
ctx.Data["PageIsHome"] = true
ctx.Data["EnableSSPI"] = ret.enableSSPI
prepareCommonAuthPageData(ctx, CommonAuthOptions{
@@ -265,6 +266,11 @@ func prepareSignInPageData(ctx *context.Context) (ret preparedSignInData) {
return ret
}
// PrepareSignInPageData exposes the shared sign-in data for the landing page.
func PrepareSignInPageData(ctx *context.Context) {
prepareSignInPageData(ctx)
}
// SignIn render sign in page
func SignIn(ctx *context.Context) {
if performAutoLogin(ctx) {