Merge pull request #1440 from lbryio/viewer-fix

Don't allow automatic night mode when dark theme is selected
This commit is contained in:
Sean Yesmunt 2018-05-08 01:02:01 -04:00 committed by GitHub
commit ea64c7f9bb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 2 deletions

View file

@ -19,13 +19,13 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/).
* Made font in price badge larger ([#1420](https://github.com/lbryio/lbry-app/pull/1420)) * Made font in price badge larger ([#1420](https://github.com/lbryio/lbry-app/pull/1420))
### Fixed ### Fixed
* Black screen on macOS after maximizing LBRY and then closing ([#1235](https://github.com/lbryio/lbry-app/pull/1235))
* Fix content-type not shown correctly in file description ([#863](https://github.com/lbryio/lbry-app/pull/863)) * Fix content-type not shown correctly in file description ([#863](https://github.com/lbryio/lbry-app/pull/863))
* Fix [Flow](https://flow.org/) ([#1197](https://github.com/lbryio/lbry-app/pull/1197)) * Fix [Flow](https://flow.org/) ([#1197](https://github.com/lbryio/lbry-app/pull/1197))
* Black screen on macOS after maximizing LBRY and then closing ([#1235](https://github.com/lbryio/lbry-app/pull/1235)) * Fix black screen on macOS after maximizing LBRY and then closing ([#1235](https://github.com/lbryio/lbry-app/pull/1235))
* Fix dark theme ([#1034](https://github.com/lbryio/lbry-app/issues/1034)) * Fix dark theme ([#1034](https://github.com/lbryio/lbry-app/issues/1034))
* Fix download percentage indicator overlay ([#1271](https://github.com/lbryio/lbry-app/issues/1271)) * Fix download percentage indicator overlay ([#1271](https://github.com/lbryio/lbry-app/issues/1271))
* Fix alternate row shading for transactions on dark theme ([#1355](https://github.com/lbryio/lbry-app/issues/#1355)) * Fix alternate row shading for transactions on dark theme ([#1355](https://github.com/lbryio/lbry-app/issues/#1355))
* Fix don't allow dark mode with automatic night mode enabled ([#1005](https://github.com/lbryio/lbry-app/issues/1005))
* Fix Description box on Publish (dark theme) ([#1356](https://github.com/lbryio/lbry-app/issues/#1356)) * Fix Description box on Publish (dark theme) ([#1356](https://github.com/lbryio/lbry-app/issues/#1356))
* Fix price wrapping in price badge ([#1420](https://github.com/lbryio/lbry-app/pull/1420)) * Fix price wrapping in price badge ([#1420](https://github.com/lbryio/lbry-app/pull/1420))
* Fix spacing in search suggestions ([#1422])(https://github.com/lbryio/lbry-app/pull/1422)) * Fix spacing in search suggestions ([#1422])(https://github.com/lbryio/lbry-app/pull/1422))

View file

@ -141,6 +141,7 @@ class SettingsPage extends React.PureComponent<Props, State> {
} = this.props; } = this.props;
const noDaemonSettings = !daemonSettings || Object.keys(daemonSettings).length === 0; const noDaemonSettings = !daemonSettings || Object.keys(daemonSettings).length === 0;
const isDarkModeEnabled = currentTheme === 'dark';
return ( return (
<Page> <Page>
@ -294,6 +295,7 @@ class SettingsPage extends React.PureComponent<Props, State> {
name="automatic_dark_mode" name="automatic_dark_mode"
onChange={e => this.onAutomaticDarkModeChange(e.target.checked)} onChange={e => this.onAutomaticDarkModeChange(e.target.checked)}
checked={automaticDarkModeEnabled} checked={automaticDarkModeEnabled}
disabled={isDarkModeEnabled}
postfix={__('Automatic dark mode (9pm to 8am)')} postfix={__('Automatic dark mode (9pm to 8am)')}
/> />
</section> </section>