Permalink
Browse files

fix(App): App mute now disables notifications as well

  • Loading branch information...
adlk committed Nov 29, 2017
1 parent 0ca3912 commit 0fa1cafeae39c00a9102a1a1d83a422d600a80d0
Showing with 8 additions and 6 deletions.
  1. +4 −4 src/components/layout/Sidebar.js
  2. +2 −2 src/i18n/locales/en-US.json
  3. +2 −0 src/stores/AppStore.js
@@ -17,12 +17,12 @@ const messages = defineMessages({
defaultMessage: '!!!Add new service',
},
mute: {
id: 'sidebar.mute',
defaultMessage: '!!!Disable audio',
id: 'sidebar.muteApp',
defaultMessage: '!!!Disable notifications & audio',
},
unmute: {
id: 'sidebar.unmute',
defaultMessage: '!!!Enable audio',
id: 'sidebar.unmuteApp',
defaultMessage: '!!!Enable notifications & audio',
},
});
@@ -62,8 +62,8 @@
"infobar.requiredRequestsFailed": "Could not load services and user information",
"sidebar.settings": "Settings",
"sidebar.addNewService": "Add new service",
"sidebar.mute": "Disable audio",
"sidebar.unmute": "Enable audio",
"sidebar.muteApp": "Disable notifications & audio",
"sidebar.unmuteApp": "Enable notifications & audio",
"services.welcome": "Welcome to Franz",
"services.getStarted": "Get started",
"settings.account.headline": "Account",
@@ -150,6 +150,8 @@ export default class AppStore extends Store {
// Actions
@action _notify({ title, options, notificationId, serviceId = null }) {
if (this.stores.settings.all.isAppMuted) return;
const notification = new window.Notification(title, options);
notification.onclick = (e) => {
if (serviceId) {

0 comments on commit 0fa1caf

Please sign in to comment.