Closed FabianoLothor closed 4 years ago
What is your OS version?
Version 74.0.3729.131 (Official Build) (64-bit)
What is your Windows, MacOS or Linux version?
windows
Just for test:
// ==UserScript==
// @name foo
// @namespace http://fabianolothor.com.br/
// @version 1.0.0
// @description Global
// @author Fabiano (Lothor)
// @match *://*/*
// @grant GM_notification
// @grant GM_getValue
// @grant GM_setValue
// @grant GM_deleteValue
// ==/UserScript==
(function() {
GM_notification({text: "this is a test", timeout: 30000});
})();
Is it some setting on my Chrome or TamperMonkey?
I make a test in a linux machine and the problem is the same.
I see the problem!
Timeout works fine if my mouse is it hover the notification.
If the mouse is not focusing the notification, its just hide after approximately 7 ~ 10 seconds.
You can add this parameter: https://web-push-book.gauntface.com/chapter-05/03-notification-behaviour/#requires-interaction
The timeout
is working fine, and when it is less the 7000 or 10000 miliseconds the problem is not perceptible.
So, with the requires-interaction
until the timeout ended the notification will appear on the screen.
I solve my problem for now: https://pushjs.org/
// @require https://pushjs.org/scripts/push.min.js
Fixed at TM BETA 4.9.5960. "requireInteraction" is now set where ever possible.
Using Chrome:
Timeout
30000
hidding with approximately 7 seconds.Code: