Hi,I came across this component when looking for a way to show an alert before the user's session times out. This component looks very promising. I only noticed a little issue:In the documentation you state that the popup appears 60 seconds before the timeout occurs, or at half of the timeout period when this is less than 60 seconds. But this does not seem to be what's happening. According to the calculation below, the popup already occurs after 120 seconds (0.2 * 900) if you pick a timeout of 900 seconds (15 minutes)timeoutToShowPopup = ((a) => a > 50 ? Math.floor( a * 0.2 ) : Math.floor(a / 2))( $parameters.timeoutInSeconds );Kind regards,Lennart
Hi Lennart,
Thank you for pointing that out, and I’m glad you found the component promising!
In the latest version, I’ve introduced a new optional input parameter, ShowPopupInSeconds, which didn’t exist in the previous version. This allows you to define the exact moment the warning popup appears before the session timeout. If this variable is left empty, the popup will appear at 20% of the total timeout duration for timeouts longer than 60 seconds, or at half the timeout period for durations shorter than 60 seconds. For example, with a 900-second timeout, the popup will be triggered after 180 seconds (0.2 * 900), which is now the expected behavior.
I appreciate you catching that and bringing it to my attention. The documentation has also been updated to reflect the new behavior and the introduction of this parameter.
Feel free to share any additional thoughts or improvements!
Kind regards,
Breno Nico
Thanks for the quick fix!