From d5c9a84bdfa20727c8b86d27ca60cb41b3bc79e7 Mon Sep 17 00:00:00 2001 From: rcourtman Date: Fri, 28 Nov 2025 09:05:41 +0000 Subject: [PATCH] Fix hideLocalLogin toggle persistence and login page UI - Add hideLocalLogin handler in HandleUpdateSystemSettings() so the toggle setting is saved to system.json - Conditionally hide "or" divider and admin credentials message when local login is hidden Related to #750 --- frontend-modern/src/components/Login.tsx | 22 ++++++++++++---------- internal/api/system_settings.go | 3 +++ 2 files changed, 15 insertions(+), 10 deletions(-) diff --git a/frontend-modern/src/components/Login.tsx b/frontend-modern/src/components/Login.tsx index 5d3e317c7..a27e40078 100644 --- a/frontend-modern/src/components/Login.tsx +++ b/frontend-modern/src/components/Login.tsx @@ -443,16 +443,18 @@ const LoginForm: Component<{ {oidcMessage()} -
- - - or - - -
-

- Use your admin credentials to sign in below. -

+ +
+ + + or + + +
+

+ Use your admin credentials to sign in below. +

+
diff --git a/internal/api/system_settings.go b/internal/api/system_settings.go index 41c2c6420..600470fb8 100644 --- a/internal/api/system_settings.go +++ b/internal/api/system_settings.go @@ -590,6 +590,9 @@ func (h *SystemSettingsHandler) HandleUpdateSystemSettings(w http.ResponseWriter if _, ok := rawRequest["allowEmbedding"]; ok { settings.AllowEmbedding = updates.AllowEmbedding } + if _, ok := rawRequest["hideLocalLogin"]; ok { + settings.HideLocalLogin = updates.HideLocalLogin + } if _, ok := rawRequest["backupPollingEnabled"]; ok { settings.BackupPollingEnabled = updates.BackupPollingEnabled }