diff options
Diffstat (limited to 'app/javascript/flavours/glitch/features/notifications')
-rw-r--r-- | app/javascript/flavours/glitch/features/notifications/components/notifications_permission_banner.js | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/app/javascript/flavours/glitch/features/notifications/components/notifications_permission_banner.js b/app/javascript/flavours/glitch/features/notifications/components/notifications_permission_banner.js index 8e77f5a03..0ba929711 100644 --- a/app/javascript/flavours/glitch/features/notifications/components/notifications_permission_banner.js +++ b/app/javascript/flavours/glitch/features/notifications/components/notifications_permission_banner.js @@ -17,12 +17,17 @@ class NotificationsPermissionBanner extends React.PureComponent { this.props.dispatch(requestBrowserPermission()); } + handleClickDisable = () => { + window.location = '/settings/preferences/notifications'; + } + render () { return ( <div className='notifications-permission-banner'> <h2><FormattedMessage id='notifications_permission_banner.title' defaultMessage='Never miss a thing' /></h2> <p><FormattedMessage id='notifications_permission_banner.how_to_control' defaultMessage="To receive notifications when Mastodon isn't open, enable desktop notifications. You can control precisely which types of interactions generate desktop notifications through the {icon} button above once they're enabled." values={{ icon: <Icon id='sliders' /> }} /></p> - <Button onClick={this.handleClick}><FormattedMessage id='notifications_permission_banner.enable' defaultMessage='Enable desktop notifications' /></Button> + <Button onClick={this.handleClick}><FormattedMessage id='notifications_permission_banner.enable' defaultMessage='Request' /></Button> + <Button onClick={this.handleClickDisable}><FormattedMessage id='notifications_permission_banner.disable' defaultMessage='Disable' /></Button> </div> ); } |