fix css and darck mode const
This commit is contained in:
parent
76c178cb42
commit
0a812dc2c3
4 changed files with 68 additions and 77 deletions
|
@ -454,10 +454,10 @@ class SettingsPage extends React.PureComponent<Props, State> {
|
||||||
label={__('Automatic dark mode')}
|
label={__('Automatic dark mode')}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
|
<Form>
|
||||||
<h3>{__('From: ')}</h3>
|
<h3>{__('From: ')}</h3>
|
||||||
<div className="time-section">
|
<fieldset-group class="fieldset-group--smushed">
|
||||||
<FormField
|
<FormField
|
||||||
className="select-hours"
|
|
||||||
type="select"
|
type="select"
|
||||||
name="automatic_dark_mode_range"
|
name="automatic_dark_mode_range"
|
||||||
disabled={!automaticDarkModeEnabled}
|
disabled={!automaticDarkModeEnabled}
|
||||||
|
@ -472,7 +472,6 @@ class SettingsPage extends React.PureComponent<Props, State> {
|
||||||
))}
|
))}
|
||||||
</FormField>
|
</FormField>
|
||||||
<FormField
|
<FormField
|
||||||
className="select-hours"
|
|
||||||
label={__('minutes')}
|
label={__('minutes')}
|
||||||
type="select"
|
type="select"
|
||||||
name="automatic_dark_mode_range"
|
name="automatic_dark_mode_range"
|
||||||
|
@ -486,12 +485,13 @@ class SettingsPage extends React.PureComponent<Props, State> {
|
||||||
</option>
|
</option>
|
||||||
))}
|
))}
|
||||||
</FormField>
|
</FormField>
|
||||||
</div>
|
</fieldset-group>
|
||||||
|
</Form>
|
||||||
|
|
||||||
|
<Form>
|
||||||
<h3>{__('To: ')}</h3>
|
<h3>{__('To: ')}</h3>
|
||||||
<div className="time-section">
|
<fieldset-group class="fieldset-group--smushed">
|
||||||
<FormField
|
<FormField
|
||||||
className="select-hours"
|
|
||||||
type="select"
|
type="select"
|
||||||
name="automatic_dark_mode_range"
|
name="automatic_dark_mode_range"
|
||||||
disabled={!automaticDarkModeEnabled}
|
disabled={!automaticDarkModeEnabled}
|
||||||
|
@ -506,7 +506,6 @@ class SettingsPage extends React.PureComponent<Props, State> {
|
||||||
))}
|
))}
|
||||||
</FormField>
|
</FormField>
|
||||||
<FormField
|
<FormField
|
||||||
className="select-hours"
|
|
||||||
label={__('minutes')}
|
label={__('minutes')}
|
||||||
type="select"
|
type="select"
|
||||||
name="automatic_dark_mode_range"
|
name="automatic_dark_mode_range"
|
||||||
|
@ -520,7 +519,8 @@ class SettingsPage extends React.PureComponent<Props, State> {
|
||||||
</option>
|
</option>
|
||||||
))}
|
))}
|
||||||
</FormField>
|
</FormField>
|
||||||
</div>
|
</fieldset-group>
|
||||||
|
</Form>
|
||||||
</fieldset-section>
|
</fieldset-section>
|
||||||
</Form>
|
</Form>
|
||||||
</section>
|
</section>
|
||||||
|
|
|
@ -3,6 +3,7 @@ import fs from 'fs';
|
||||||
import http from 'http';
|
import http from 'http';
|
||||||
// @endif
|
// @endif
|
||||||
import { Lbry, ACTIONS, SETTINGS } from 'lbry-redux';
|
import { Lbry, ACTIONS, SETTINGS } from 'lbry-redux';
|
||||||
|
import * as DESKTOP_SETTINGS from 'constants/settings';
|
||||||
import { makeSelectClientSetting } from 'redux/selectors/settings';
|
import { makeSelectClientSetting } from 'redux/selectors/settings';
|
||||||
import analytics from 'analytics';
|
import analytics from 'analytics';
|
||||||
|
|
||||||
|
@ -156,7 +157,7 @@ export function doSetDarkTime(value, options) {
|
||||||
};
|
};
|
||||||
const mergedTimes = { ...darkModeTimes, ...modifiedTimes };
|
const mergedTimes = { ...darkModeTimes, ...modifiedTimes };
|
||||||
|
|
||||||
dispatch(doSetClientSetting(SETTINGS.DARK_MODE_TIMES, mergedTimes));
|
dispatch(doSetClientSetting(DESKTOP_SETTINGS.DARK_MODE_TIMES, mergedTimes));
|
||||||
dispatch(doUpdateIsNight());
|
dispatch(doUpdateIsNight());
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -34,7 +34,6 @@
|
||||||
@import 'component/pagination';
|
@import 'component/pagination';
|
||||||
@import 'component/placeholder';
|
@import 'component/placeholder';
|
||||||
@import 'component/search';
|
@import 'component/search';
|
||||||
@import 'component/settings';
|
|
||||||
@import 'component/snack-bar';
|
@import 'component/snack-bar';
|
||||||
@import 'component/spinner';
|
@import 'component/spinner';
|
||||||
@import 'component/splash';
|
@import 'component/splash';
|
||||||
|
|
|
@ -1,9 +0,0 @@
|
||||||
.select-hours {
|
|
||||||
display: block;
|
|
||||||
float: left;
|
|
||||||
width: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
.time-section {
|
|
||||||
display: flex;
|
|
||||||
}
|
|
Loading…
Add table
Reference in a new issue