Skip to content

Commit

Permalink
Add sections for dark mode and realm overrides.
Browse files Browse the repository at this point in the history
Signed-off-by: Stan Silvert <[email protected]>
  • Loading branch information
ssilvert committed Dec 3, 2024
1 parent 3602fdf commit 314ed28
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 2 deletions.
17 changes: 16 additions & 1 deletion docs/documentation/ui_customization/topics/localization.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -78,4 +78,19 @@ Previous versions of Keycloak supported specifying the encoding in the first lin

=== Overriding localized text for an entire realm

Often, you wish to declare translations that take effect for an entire realm. This is done by specifying key/value pairs in the realm settings.
Occasionally, you wish to declare translations that take effect for an entire realm. This is done by specifying key/value pairs in the realm settings. Any key specified in this way will override key/value pairs deployed with a theme.

CAUTION: Using realm overrides is not the typical way to do localization in {project_name}. Consider carefully if you want every theme in your realm to use these key/value pairs.

.Procedure to add a realm override

. Log into the Admin Console
. Select your realm
. Click *Realm Settings* from the menu.
. Click on the *Localization* tab.
. Click on the *Realm overrides* subtab.
. Select a language from the dropdown
. Click on *Add translation*
. Create a key/value pair from the modal dialog

Note that there is another subtab called *Effective message bundles*. This subtab provides a tool to query key/value pairs for a combination of theme, language, and theme type. You can use this tool to test and make sure your realm overrides have taken effect.
2 changes: 2 additions & 0 deletions docs/documentation/ui_customization/topics/quick-theme.adoc
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
[[_quick_theme]]

== Customizing with Quick Theme

blah blah blah
11 changes: 10 additions & 1 deletion docs/documentation/ui_customization/topics/themes.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -387,8 +387,17 @@ To deploy the archive to {project_name}, add it to the `providers/` directory of
{project_name} and restart the server if it is already running.

=== Dark Mode
Dark mode is a feature that changes the color scheme to a dark background with lighter text. For example, themes based on PatternFly, such as Keycloak's admin console and account console, support dark mode. But for some themes, dark mode doesn't work well for various reasons. So Keycloak allows you to disable dark mode from the admin console.

Explain how to enable/disable dark mode
.Procedure to disable dark mode

. Log into the Admin Console.
. Select your realm.
. Click *Realm Settings* from the menu.
. Click on the *Themes* tab.
. Unselect *Dark mode* and click *Save*.

If enabled, the dark variant of the theme will be applied based on user preference through an operating system setting (e.g. light or dark mode) or a user agent setting. If disabled, only the light variant will be used. This setting only applies to themes that support dark and light variants. On themes that do not support this feature it will have no effect.

[role="_additional-resources"]
=== Additional resources for Themes
Expand Down

0 comments on commit 314ed28

Please sign in to comment.