ferdium-app icon indicating copy to clipboard operation
ferdium-app copied to clipboard

Notifications Stay on Screen

Open Kyzoku opened this issue 1 year ago • 19 comments

Avoid duplicates

  • [X] I agree to follow the Code of Conduct that this project adheres to.
  • [X] I have searched the issues tracker for a bug report similar to mine, in vain

Ferdium Version

6.7.0

What Operating System are you using?

Windows

Operating System Version

Windows 11 23H2 (22631.3085)

What arch are you using?

x64

Last Known Working Ferdium version

No response

Expected Behavior

When a notification banner appears, it will then go away on its own after 5 seconds.

Actual Behavior

When a notification banner appears, it remains on the screen indefinitely unless closed manually.

Steps to reproduce

  1. Receive a notification (potentially Google Voice).

Debug link

https://debug.ferdium.org/df51556e-2097-4dfa-a5dc-898edac2239f

Screenshots

No response

Additional information

It might be related to the Google Voice service as that is the one I remember seeing and a notification from Skype service acted appropriately.

Kyzoku avatar Feb 14 '24 02:02 Kyzoku

The same problem is with Ubuntu Linux and KDE. Seems Ferdium started to create notifications with timeout=0, instead of using the system default timeout.

MurzNN avatar Jun 07 '24 16:06 MurzNN

Same issue with the new Teams on Windows, you have to click on close to hide the notification

DrIT2016 avatar Jun 13 '24 07:06 DrIT2016

same issue using Manjaro + KDE. notification never times out (never run actually)

steadfasterX avatar Jul 02 '24 08:07 steadfasterX

Same issue still happening in 6.7.5 in openSUSE + KDE and Windows 11. Since this is happening for both Linux and Windows, I assume that this is happening in all OS and all DE.

DenysMb avatar Jul 03 '24 12:07 DenysMb

I think I found whats wrong with this.

According to MDN [^1]:

requireInteraction Optional: Indicates that a notification should remain active until the user clicks or dismisses it, rather than closing automatically. The default value is false.

But Microsoft Teams thinks its notifications are very important [^2]:

getNotificationOptionsPayload() {
  const e = this.entityCommand.entityOptions;
  return {
    notificationTitle: e.title,
    notificationOptions: {
      body: e.text,
      icon: e.mainImage?.src,
      timestamp: new Date(e.time).getTime(),
      tag: void 0,
      requireInteraction: !0, // This evaluates to true in JS
      dir: this.isRtl ? VO.b7.Rtl : VO.b7.Auto
    }
  };
}

Can Ferdium force the default behavior to requireInteraction=false?, I don't see a future were Microsoft fixes this.

[^1]: Notification API: https://developer.mozilla.org/en-US/docs/Web/API/Notification/Notification#requireinteraction [^2]: https://statics.teams.cdn.office.net/teams-modular-packages/hashed-assets/async-entry-e0e507f543cd11e2.js

marcosins avatar Oct 07 '24 20:10 marcosins

Steps to reproduce:

  1. Open Developer Tools using View -> Toggle Service Developer Tools or CTRL+ALT+SHIFT+I
  2. Change to the Console tab
  3. Create a new not dismissable notification using this snippet:
    new Notification('not dismissable', {requireInteraction:true})
    
  4. Notification stays on top until you dismiss it manually

Create a dismissable notification with a similar snippet: new Notification('dismissable')

Edit: Looks that this only affects Chromium browsers, when using the not dismissable snippet in Firefox the notification goes away after 5 secs (my OS setting).

marcosins avatar Oct 07 '24 21:10 marcosins

This is not a Teams only problem though. I have it also in Threema Web for example.

steadfasterX avatar Oct 08 '24 06:10 steadfasterX

I'd also like to see this resolved. I'm using teams for my work communication and having to manually dismiss hundreds of notifications per day is really tiresome. Thank you!

thorgrin avatar Nov 29 '24 12:11 thorgrin

Any news on this? I use the app for multiple accounts (Teams, Discord, Messenger...), it often happens that you end up with notifications all the way to the bottom of the screen and you have to close them all one by one. If anyone has a solution, I'm interested. (I use Manjaro + KDE)

thomas-ddev avatar Mar 11 '25 21:03 thomas-ddev

Hey!

I've been trying to reproduce this issue with the latest nightly and Windows 11 and it looks like I'm not able to.

Can I assume this issue only happens in Manjaro + KDE ? Can anyone who uses windows and macOS also confirm having this issue?

SpecialAro avatar Mar 12 '25 22:03 SpecialAro

I was the original poster of this issue and I use Windows 11. However, I have made it a habit to manually close the notifications so I have no idea if this problem still exists. I'll test and see.

Kyzoku avatar Mar 13 '25 00:03 Kyzoku

I can confirm, this is still happening. Windows 11 23H2, Ferdium 7.0.1-nightly.11

tberreis avatar Mar 13 '25 05:03 tberreis

Still happens on Kubuntu 24.10 with Ferdium 7.0.0.

I assigned a key combination to forcibly close all notifications including the persistent ones (Enumerating all the notifications and closing them one by one starting from this number to zero).

One of the ways to fix it is to block the notification in JS an recreate it as ephemeral, requires some JS tinkering but definitely possible.

yarons avatar Mar 13 '25 07:03 yarons

still the same for (again) Manjaro + KDE here. afaiu this is due to the notification type: https://github.com/ferdium/ferdium-app/issues/1574#issuecomment-2397895007 so no JS workarounds are needed if ferdium would "just" override the 'not dismissable' thing by Teams and others. at least that is what I understood

steadfasterX avatar Mar 13 '25 07:03 steadfasterX

Found an issue in MS Teams forum about this issue https://answers.microsoft.com/en-us/msteams/forum/all/web-new-microsoft-teams-notifications-are-always/ef550955-e675-4659-9956-5a6d351bb70b but, as usual, with no adequate response :(

So, seems we have to invent a workaround from Ferdium side to intercept notifications and overwrite the "requireInteraction" option in them.

MurzNN avatar Mar 13 '25 07:03 MurzNN

By the way, maybe a fix from here https://github.com/ferdium/ferdium-app/issues/1675#issuecomment-2078996172 can help?

MurzNN avatar Mar 13 '25 07:03 MurzNN

And because the main issue is on the MS Teams side, let's maybe submit more feedback and reports in the forum about this problem to MS Teams, to attract attention? I already started to do this :)

MurzNN avatar Mar 13 '25 07:03 MurzNN

Found an issue in MS Teams forum about this issue https://answers.microsoft.com/en-us/msteams/forum/all/web-new-microsoft-teams-notifications-are-always/ef550955-e675-4659-9956-5a6d351bb70b but, as usual, with no adequate response :(

That was me using my corp account. Someone else should test this with regular Teams (not business) and ask in the forums

marrws avatar Mar 13 '25 13:03 marrws

The same problem is with ms private account (teams). I think we (Ferdium) should be able to overwrite it in settings.

BTW: There is workaround for Windows (which I do not use, but I helped friend to setup Ferdium), Settings - Privacy - "Notify Taskbar/Dock on new message". And we turned off notifications for Ferdium in Windows.

For Linux there are also workarounds for it, but it depends on notification daemons you use (mako, dunst, ... allows to customize timeouts).

ernierasta avatar Apr 04 '25 08:04 ernierasta