Factor out logic from EnableNotificationsButton(!) and reuse MatrixToolbar.
Added notification logic to Notifier; dispatch notifier_enabled when toggled so the toolbar can be shown/hidden and the button text can be kept in sync. Add MatrixToolbar back into MatrixChat for notification nagging.
This commit is contained in:
parent
ed738b6398
commit
c1de5e9e95
5 changed files with 95 additions and 38 deletions
|
@ -32,8 +32,7 @@ module.exports = React.createClass({
|
|||
render: function() {
|
||||
return (
|
||||
<div className="mx_MatrixToolbar">
|
||||
<LogoutButton />
|
||||
<EnableNotificationsButton />
|
||||
You are not receiving desktop notifications. <EnableNotificationsButton />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue