kopia lustrzana https://gitlab.com/soapbox-pub/soapbox
Add to /settings/profile
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>merge-requests/931/head
rodzic
e3d2b44bdc
commit
d5e565e766
|
@ -103,6 +103,7 @@ class EditProfile extends ImmutablePureComponent {
|
|||
|
||||
const strangerNotifications = account.getIn(['pleroma', 'notification_settings', 'block_from_strangers']);
|
||||
const acceptsEmailList = account.getIn(['pleroma', 'accepts_email_list']);
|
||||
const discoverable = account.getIn(['source', 'pleroma', 'discoverable']);
|
||||
|
||||
const initialState = account.withMutations(map => {
|
||||
map.merge(map.get('source'));
|
||||
|
@ -111,6 +112,7 @@ class EditProfile extends ImmutablePureComponent {
|
|||
map.set('stranger_notifications', strangerNotifications);
|
||||
map.set('accepts_email_list', acceptsEmailList);
|
||||
map.set('hide_network', hidesNetwork(account));
|
||||
map.set('discoverable', discoverable);
|
||||
unescapeParams(map, ['display_name', 'bio']);
|
||||
});
|
||||
|
||||
|
@ -309,6 +311,13 @@ class EditProfile extends ImmutablePureComponent {
|
|||
checked={this.state.stranger_notifications}
|
||||
onChange={this.handleCheckboxChange}
|
||||
/>
|
||||
<Checkbox
|
||||
label={<FormattedMessage id='edit_profile.fields.discoverable_label' defaultMessage='Allow account discovery' />}
|
||||
hint={<FormattedMessage id='edit_profile.hints.discoverable' defaultMessage='Display account in profile directory and allow indexing by external services' />}
|
||||
name='discoverable'
|
||||
checked={this.state.discoverable}
|
||||
onChange={this.handleCheckboxChange}
|
||||
/>
|
||||
{supportsEmailList && <Checkbox
|
||||
label={<FormattedMessage id='edit_profile.fields.accepts_email_list_label' defaultMessage='Subscribe to newsletter' />}
|
||||
hint={<FormattedMessage id='edit_profile.hints.accepts_email_list' defaultMessage='Opt-in to news and marketing updates.' />}
|
||||
|
|
Ładowanie…
Reference in New Issue