lukejacksonn / react-slack-clone

Complete chat application, built with Chatkit | by @lukejacksonn
https://pusher.com/chatkit
MIT License
1.35k stars 262 forks source link

Adds desktop notification support #54

Closed lukejacksonn closed 6 years ago

lukejacksonn commented 6 years ago

Addresses https://github.com/pusher/react-slack-clone/issues/14. Thanks to @DevFlex for kicking this off! A notification is now shown like so:

screen shot 2018-04-10 at 17 47 58

When the device supports Notifications and has allowed them, the window visibility is hidden and the message received is not your own.

The notification will include the message senders name, avatar and the text from the message. If you click on the notification it will focus on the window that spawned the notification and switch to the room where the message resides.