Add dyslexicFont preference

stable/1.0.x
Alex Gleason 2020-04-21 15:10:45 -05:00
rodzic 394aaaf23f
commit c90f087d2a
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 7211D1F99744FBB7
3 zmienionych plików z 11 dodań i 1 usunięć

Wyświetl plik

@ -44,6 +44,7 @@ const mapStateToProps = (state) => {
me,
theme: state.getIn(['settings', 'theme']),
systemFont: state.getIn(['settings', 'systemFont']),
dyslexicFont: state.getIn(['settings', 'dyslexicFont']),
};
};
@ -55,10 +56,11 @@ class GabSocialMount extends React.PureComponent {
me: PropTypes.string,
theme: PropTypes.string,
systemFont: PropTypes.bool,
dyslexicFont: PropTypes.bool,
};
render() {
const { me, theme, systemFont } = this.props;
const { me, theme, systemFont, dyslexicFont } = this.props;
if (me === null) return null;
// Disabling introduction for launch
@ -71,6 +73,7 @@ class GabSocialMount extends React.PureComponent {
const bodyClass = classNames('app-body', {
[`theme-${theme}`]: theme,
'system-font': systemFont,
'dyslexic': dyslexicFont,
});
return (

Wyświetl plik

@ -136,6 +136,12 @@ class Preferences extends ImmutablePureComponent {
label="Use system's default font"
path={['systemFont']}
/>
<div className='dyslexic'>
<SettingsCheckbox
label='Dyslexic mode'
path={['dyslexicFont']}
/>
</div>
</FieldsGroup>
</SimpleForm>
</Column>

Wyświetl plik

@ -23,6 +23,7 @@ const initialState = ImmutableMap({
theme: 'lime',
systemFont: false,
dyslexicFont: false,
home: ImmutableMap({
shows: ImmutableMap({