mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-14 17:13:49 -07:00
New: Auto theme option to match OS theme
Closes #3165 Co-authored-by: Qstick <qstick@gmail.com> (cherry picked from commit 4ca5a213fa0fc29ed93e7e31b080728d6fa7f1f3)
This commit is contained in:
parent
fd463ad283
commit
4fd389021a
3 changed files with 6 additions and 2 deletions
|
@ -1,7 +1,11 @@
|
||||||
import * as dark from './dark';
|
import * as dark from './dark';
|
||||||
import * as light from './light';
|
import * as light from './light';
|
||||||
|
|
||||||
|
const defaultDark = window.matchMedia('(prefers-color-scheme: dark)').matches;
|
||||||
|
const auto = defaultDark ? { ...dark } : { ...light };
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
auto,
|
||||||
light,
|
light,
|
||||||
dark
|
dark
|
||||||
};
|
};
|
||||||
|
|
|
@ -196,7 +196,7 @@ namespace NzbDrone.Core.Configuration
|
||||||
public string LogLevel => GetValue("LogLevel", "info");
|
public string LogLevel => GetValue("LogLevel", "info");
|
||||||
public string ConsoleLogLevel => GetValue("ConsoleLogLevel", string.Empty, persist: false);
|
public string ConsoleLogLevel => GetValue("ConsoleLogLevel", string.Empty, persist: false);
|
||||||
|
|
||||||
public string Theme => GetValue("Theme", "light", persist: false);
|
public string Theme => GetValue("Theme", "auto", persist: false);
|
||||||
public string PostgresHost => _postgresOptions?.Host ?? GetValue("PostgresHost", string.Empty, persist: false);
|
public string PostgresHost => _postgresOptions?.Host ?? GetValue("PostgresHost", string.Empty, persist: false);
|
||||||
public string PostgresUser => _postgresOptions?.User ?? GetValue("PostgresUser", string.Empty, persist: false);
|
public string PostgresUser => _postgresOptions?.User ?? GetValue("PostgresUser", string.Empty, persist: false);
|
||||||
public string PostgresPassword => _postgresOptions?.Password ?? GetValue("PostgresPassword", string.Empty, persist: false);
|
public string PostgresPassword => _postgresOptions?.Password ?? GetValue("PostgresPassword", string.Empty, persist: false);
|
||||||
|
|
|
@ -769,7 +769,7 @@
|
||||||
"TheAlbumsFilesWillBeDeleted": "The album's files will be deleted.",
|
"TheAlbumsFilesWillBeDeleted": "The album's files will be deleted.",
|
||||||
"TheArtistFolderStrongpathstrongAndAllOfItsContentWillBeDeleted": "The artist folder <strong>{path}</strong> and all of its content will be deleted.",
|
"TheArtistFolderStrongpathstrongAndAllOfItsContentWillBeDeleted": "The artist folder <strong>{path}</strong> and all of its content will be deleted.",
|
||||||
"Theme": "Theme",
|
"Theme": "Theme",
|
||||||
"ThemeHelpText": "Change Application UI Theme",
|
"ThemeHelpText": "Change Application UI Theme, 'Auto' Theme will use your OS Theme to set Light or Dark mode. Inspired by Theme.Park",
|
||||||
"ThisCannotBeCancelled": "This cannot be cancelled once started without disabling all of your indexers.",
|
"ThisCannotBeCancelled": "This cannot be cancelled once started without disabling all of your indexers.",
|
||||||
"ThisWillApplyToAllIndexersPleaseFollowTheRulesSetForthByThem": "This will apply to all indexers, please follow the rules set forth by them",
|
"ThisWillApplyToAllIndexersPleaseFollowTheRulesSetForthByThem": "This will apply to all indexers, please follow the rules set forth by them",
|
||||||
"Time": "Time",
|
"Time": "Time",
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue