Console: Fix theme selection

This commit is contained in:
zzz
2020-12-20 14:40:09 -05:00
parent bec8feb05a
commit 340df51429
2 changed files with 2 additions and 0 deletions

View File

@@ -21,6 +21,7 @@ public class CSSHelper extends HelperBase {
/** @since 0.9.33 moved from ConfigUIHelper */
public static final String PROP_THEME_PFX = PROP_THEME_NAME + '.';
public static final String DEFAULT_THEME = "light";
public static final String ALT_THEME = "dark";
public static final String BASE_THEME_PATH = "/themes/console/";
private static final String FORCE = "classic";
public static final String PROP_REFRESH = "routerconsole.summaryRefresh";

View File

@@ -76,6 +76,7 @@ public class ConfigUIHelper extends HelperBase {
Set<String> rv = new TreeSet<String>();
// add a failsafe even if we can't find any themes
rv.add(CSSHelper.DEFAULT_THEME);
rv.add(CSSHelper.ALT_THEME);
File dir = new File(_context.getBaseDir(), "docs/themes/console");
File[] files = dir.listFiles();
if (files == null)