From 7e6614869085b9ac13bdfe604de985b463faa3b7 Mon Sep 17 00:00:00 2001 From: Engincan VESKE Date: Wed, 6 May 2026 18:26:11 +0300 Subject: [PATCH] docs: refine React admin console configuration Co-authored-by: Cursor --- docs/en/framework/ui/react/admin-console.md | 24 +++++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) diff --git a/docs/en/framework/ui/react/admin-console.md b/docs/en/framework/ui/react/admin-console.md index adbe4056c3..47bc355b76 100644 --- a/docs/en/framework/ui/react/admin-console.md +++ b/docs/en/framework/ui/react/admin-console.md @@ -106,9 +106,9 @@ GET /admin-console/api/config This endpoint provides Admin Console runtime settings such as authority, client ID, scopes, application name, customization options, and localization language configuration. -Host applications can configure Admin Console options from the `AdminConsole` configuration section. +Host applications can configure Admin Console options from the `AdminConsole` configuration section or by configuring `AbpAdminConsoleOptions`. -## `appsettings.json` Customization +## Configuring the Admin Console In layered and single-layer modern React templates, the embedded Admin Console is configured from the backend host application's `appsettings.json` file. The generated template includes an `AdminConsole` section similar to the following: @@ -128,6 +128,26 @@ In layered and single-layer modern React templates, the embedded Admin Console i } ``` +You can also configure the same values in the module class with `AbpAdminConsoleOptions`: + +```csharp +public override void ConfigureServices(ServiceConfigurationContext context) +{ + Configure(options => + { + options.IsEnabled = true; + options.RedirectRootToAdminConsole = true; + options.Authority = "https://localhost:44300"; + options.ClientId = "Acme_BookStore_AdminConsole"; + options.Scope = "openid profile email offline_access Acme_BookStore"; + options.LocalizationLanguages = new[] { "en", "tr" }; + options.ThemeOverrideCssPath = "/theme-override.css"; + options.InitialTheme = "system"; + options.CustomizationPermissionName = "AdminConsole.Customization"; + }); +} +``` + The most commonly changed options are: | Option | Description |