Fix: Adds favicon badge for notification alert. (#2079)

* Adds favicon badge for notification alert.
This commit is contained in:
Sivin Varghese
2021-04-13 19:25:19 +05:30
committed by GitHub
parent 4387736f1a
commit a14e8ba250
7 changed files with 28 additions and 3 deletions

View File

@@ -1,6 +1,7 @@
import { MESSAGE_TYPE } from 'shared/constants/messages';
const notificationAudio = require('shared/assets/audio/ding.mp3');
import axios from 'axios';
import { showBadgeOnFavicon } from './faviconHelper';
export const playNotificationAudio = () => {
try {
@@ -74,5 +75,6 @@ export const newMessageNotification = data => {
if (enableAudioAlerts && playAudio) {
window.playAudioAlert();
showBadgeOnFavicon();
}
};