rename background setting to be disable backgroud; add default value for background setting.
This commit is contained in:
parent
97920a6bf0
commit
b77ae9b0ea
7 changed files with 11 additions and 11 deletions
|
@ -2313,7 +2313,6 @@
|
||||||
"Top content in %language%": "Top content in %language%",
|
"Top content in %language%": "Top content in %language%",
|
||||||
"Apply": "Apply",
|
"Apply": "Apply",
|
||||||
"24-hour clock": "24-hour clock",
|
"24-hour clock": "24-hour clock",
|
||||||
"background": "background",
|
|
||||||
"Disable background": "Disable background",
|
"Disable background": "Disable background",
|
||||||
"--end--": "--end--"
|
"--end--": "--end--"
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,7 +5,7 @@ import { makeSelectClientSetting } from 'redux/selectors/settings';
|
||||||
import SettingAppearance from './view';
|
import SettingAppearance from './view';
|
||||||
|
|
||||||
const select = (state) => ({
|
const select = (state) => ({
|
||||||
background: makeSelectClientSetting(SETTINGS.BACKGROUND)(state),
|
disableBackground: makeSelectClientSetting(SETTINGS.DISABLE_BACKGROUND)(state),
|
||||||
clock24h: makeSelectClientSetting(SETTINGS.CLOCK_24H)(state),
|
clock24h: makeSelectClientSetting(SETTINGS.CLOCK_24H)(state),
|
||||||
searchInLanguage: makeSelectClientSetting(SETTINGS.SEARCH_IN_LANGUAGE)(state),
|
searchInLanguage: makeSelectClientSetting(SETTINGS.SEARCH_IN_LANGUAGE)(state),
|
||||||
hideBalance: makeSelectClientSetting(SETTINGS.HIDE_BALANCE)(state),
|
hideBalance: makeSelectClientSetting(SETTINGS.HIDE_BALANCE)(state),
|
||||||
|
|
|
@ -12,7 +12,7 @@ import ThemeSelector from 'component/themeSelector';
|
||||||
import homepages from 'homepages';
|
import homepages from 'homepages';
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
background: boolean,
|
disableBackground: boolean,
|
||||||
clock24h: boolean,
|
clock24h: boolean,
|
||||||
searchInLanguage: boolean,
|
searchInLanguage: boolean,
|
||||||
hideBalance: boolean,
|
hideBalance: boolean,
|
||||||
|
@ -21,7 +21,7 @@ type Props = {
|
||||||
};
|
};
|
||||||
|
|
||||||
export default function SettingAppearance(props: Props) {
|
export default function SettingAppearance(props: Props) {
|
||||||
const { clock24h, background, searchInLanguage, hideBalance, setClientSetting, setSearchInLanguage } = props;
|
const { clock24h, disableBackground, searchInLanguage, hideBalance, setClientSetting, setSearchInLanguage } = props;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
|
@ -68,8 +68,8 @@ export default function SettingAppearance(props: Props) {
|
||||||
<FormField
|
<FormField
|
||||||
type="checkbox"
|
type="checkbox"
|
||||||
name="background"
|
name="background"
|
||||||
onChange={() => setClientSetting(SETTINGS.BACKGROUND, !background)}
|
onChange={() => setClientSetting(SETTINGS.DISABLE_BACKGROUND, !disableBackground)}
|
||||||
checked={background}
|
checked={disableBackground}
|
||||||
/>
|
/>
|
||||||
</SettingsRow>
|
</SettingsRow>
|
||||||
<SettingsRow title={__('Hide wallet balance in header')}>
|
<SettingsRow title={__('Hide wallet balance in header')}>
|
||||||
|
|
|
@ -4,7 +4,7 @@ import * as SETTINGS from 'constants/settings';
|
||||||
import { makeSelectClientSetting } from 'redux/selectors/settings';
|
import { makeSelectClientSetting } from 'redux/selectors/settings';
|
||||||
|
|
||||||
const select = (state) => ({
|
const select = (state) => ({
|
||||||
background: makeSelectClientSetting(SETTINGS.BACKGROUND)(state),
|
disableBackground: makeSelectClientSetting(SETTINGS.DISABLE_BACKGROUND)(state),
|
||||||
});
|
});
|
||||||
|
|
||||||
const perform = {};
|
const perform = {};
|
||||||
|
|
|
@ -8,11 +8,11 @@ type Props = {
|
||||||
// cover: ?string,
|
// cover: ?string,
|
||||||
// avatar: ?string,
|
// avatar: ?string,
|
||||||
reset: ?boolean,
|
reset: ?boolean,
|
||||||
background: ?boolean,
|
disableBackground: ?boolean,
|
||||||
};
|
};
|
||||||
|
|
||||||
const Wallpaper = (props: Props) => {
|
const Wallpaper = (props: Props) => {
|
||||||
const { background } = props;
|
const { disableBackground } = props;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
if (avatar) {
|
if (avatar) {
|
||||||
|
@ -234,7 +234,7 @@ const Wallpaper = (props: Props) => {
|
||||||
<div
|
<div
|
||||||
className={'background-image'}
|
className={'background-image'}
|
||||||
style={{
|
style={{
|
||||||
backgroundImage: background ? `none` : `url(${freeezepeach})`,
|
backgroundImage: disableBackground ? `none` : `url(${freeezepeach})`,
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
<div className={'theme'} />
|
<div className={'theme'} />
|
||||||
|
|
|
@ -14,7 +14,7 @@ export const THEME = 'theme';
|
||||||
export const THEMES = 'themes';
|
export const THEMES = 'themes';
|
||||||
export const AUTOMATIC_DARK_MODE_ENABLED = 'automatic_dark_mode_enabled';
|
export const AUTOMATIC_DARK_MODE_ENABLED = 'automatic_dark_mode_enabled';
|
||||||
export const CLOCK_24H = 'clock_24h';
|
export const CLOCK_24H = 'clock_24h';
|
||||||
export const BACKGROUND = 'background';
|
export const DISABLE_BACKGROUND = 'disableBackground';
|
||||||
export const AUTOPLAY_MEDIA = 'autoplay';
|
export const AUTOPLAY_MEDIA = 'autoplay';
|
||||||
export const AUTOPLAY_NEXT = 'autoplay_next';
|
export const AUTOPLAY_NEXT = 'autoplay_next';
|
||||||
export const OS_NOTIFICATIONS_ENABLED = 'os_notifications_enabled';
|
export const OS_NOTIFICATIONS_ENABLED = 'os_notifications_enabled';
|
||||||
|
|
|
@ -40,6 +40,7 @@ const defaultState = {
|
||||||
[SETTINGS.OS_NOTIFICATIONS_ENABLED]: true,
|
[SETTINGS.OS_NOTIFICATIONS_ENABLED]: true,
|
||||||
[SETTINGS.AUTOMATIC_DARK_MODE_ENABLED]: false,
|
[SETTINGS.AUTOMATIC_DARK_MODE_ENABLED]: false,
|
||||||
[SETTINGS.CLOCK_24H]: false,
|
[SETTINGS.CLOCK_24H]: false,
|
||||||
|
[SETTINGS.DISABLE_BACKGROUND]: false,
|
||||||
[SETTINGS.TILE_LAYOUT]: true,
|
[SETTINGS.TILE_LAYOUT]: true,
|
||||||
[SETTINGS.VIDEO_THEATER_MODE]: false,
|
[SETTINGS.VIDEO_THEATER_MODE]: false,
|
||||||
[SETTINGS.VIDEO_PLAYBACK_RATE]: 1,
|
[SETTINGS.VIDEO_PLAYBACK_RATE]: 1,
|
||||||
|
|
Loading…
Reference in a new issue