const extraThemesFolder =
process.env["LEMMY_UI_EXTRA_THEMES_FOLDER"] || "./extra_themes";
- const themes = [
+ const themes: ReadonlyArray<string> = [
"darkly",
"darkly-red",
+ "darkly-compact",
"litely",
"litely-red",
+ "litely-compact",
];
- export async function buildThemeList(): Promise<string[]> {
+ export async function buildThemeList(): Promise<ReadonlyArray<string>> {
if (existsSync(extraThemesFolder)) {
const dirThemes = await readdir(extraThemesFolder);
const cssThemes = dirThemes
.filter(d => d.endsWith(".css"))
.map(d => d.replace(".css", ""));
- themes.push(...cssThemes);
+ return themes.concat(cssThemes);
}
return themes;
}