Skip to content

Conversation

@d0niek
Copy link

@d0niek d0niek commented Mar 6, 2021

Sound file was downloaded from here.

It's a basic sound notification that I could make with my skills.
Probably it's not the perfect but it works and my users are happy.

I didn't know how to add new feature so I modified branche with my
installed version of Nextcloud Talk.

Resolves: #760, #5096, #4651

Sound file was downloaded from
[here](https://notificationsounds.com/message-tones/that-was-quick-606).

It's a basic sound notification that I could make with my skills.
Probably it's not the perfect but it works and my users are happy.

I didn't know how to add new feature so I modified branche with my
installed version of Nextcloud Talk.

Resolves: nextcloud#760, nextcloud#5096, nextcloud#4651
@nickvergessen
Copy link
Member

Thanks for the start.

Unluckily it's not easy like that. I just recently gave it another try in general:
nextcloud/notifications#116 (comment)

So to support all supported browsers and also work in background etc a bit more work is necessary.
Similarly it definetly needs a setting to disable it and also should only play the sound on one tab.

I have a local branch which brings in a audio setting for sounds in calls. I will push it on monday. We then can take your changes onto the branch controlled by the setting and continue from there.

@d0niek
Copy link
Author

d0niek commented Mar 7, 2021

As I follow sound notification topic in Nextcloud and understand it that you're going to implement sound play for Nextcloud notifications (top-right bell icon)? It would be nice but Facebook or Google don't have it and people can live with it. Advantage of Facebook or Google (Gmail) is that when someone text you then small window with chat is opening (sound is playing so you won't miss a message). Maybe one day I will browse my files in Nextcloud and same small window with chat will open? :-)

Nextcloud Talk (web) is like Facebook Messenger (www.messenger.com), Google Hangout (hangouts.google.com), Slack and many other chat applications which have sound notifications for all new messages, comming calls, etc. Nextcloud Talk is adding only * in tab title and that's why I added here a sound play. But it has a bug (?) because it happens only if window is not visible and it happens only once. If window is visible but browser hasn't focus, * won't be added to tab title and my sound won't play. If window is not visible and I receive more then one new message, event with adding * (playing sound) will happens only once.

Another thing is that when I have Nextcloud Talk tab open and someone start calling then all my devices are ringing (web browser, phone, tablet) and it's ok, I won't miss a call ;-) The same is with Facebook or Google. Now when I have Nextcloud Talk tab open but is not visible and someone text me, I miss my sound notification and someone text me again I will never know about it because my phone/tablet don't ring. Mobile devices only ring when Nextcloud Talk tab is not open or if a video call is comming.

Maybe you're right that I should used https://github.com/goldfire/howler.js to play a sound but I'm not a front-end guy and I don't want to make a mess. I prefer another PR from vue.js master guys which will upgrade my implementation. I just wanted to check how hard (easy) is to add sound notification. My users are so happy with this upgrade and I have a hope that more users can be happy too and sound notifications can be only better from this point :-)

@nickvergessen
Copy link
Member

Finally managed to push my changes. You can find them in #5410 and it comes with generic sound settings. I guess sounds for chat messages require a second setting as you might not want that while still having sounds in calls, but it should be possible to duplicate the changes for the setting easily.

@nickvergessen nickvergessen added this to the 💖 Next Major (22) milestone Mar 24, 2021
@nickvergessen nickvergessen mentioned this pull request Mar 24, 2021
7 tasks
@nickvergessen nickvergessen marked this pull request as draft April 8, 2021 11:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants