Lack of interest Flash messages obstruct the page header, make a click hide them?

This suggestion has been closed automatically because it did not receive enough votes over an extended period of time. If you wish to see this, please search for an open suggestion and, if you don't find any, post a new one.

Steffen

Well-known member
The flash messages (e.g. "Your changes have been saved.") can obstruct the whole header or parts of the header while they are shown. Most of them are displayed for 3000 ms (this value seems to be hard-coded in multiple places). This can be annoying for power-users (example for such feedback).

One solution could be to show the flash message bar at the bottom (i.e. not at the top).

Another solution could be to give the user the option to manually dismiss the flash message bar by clicking it:

Diff:
--- a/js/xf/core.js
+++ b/js/xf/core.js
@@ -2461,7 +2461,7 @@ if (window.jQuery === undefined) jQuery = $ = {};
             $message.find('.flashMessage-content').html(message);
 
             $message.appendTo('body').addClassTransitioned('is-active');
-            setTimeout(function()
+            var timeout = setTimeout(function()
             {
                 $message.removeClassTransitioned('is-active', function()
                 {
@@ -2472,6 +2472,19 @@ if (window.jQuery === undefined) jQuery = $ = {};
                     }
                 });
             }, Math.max(500, timeout));
+
+            $message.on('click', function() {
+                clearTimeout(timeout);
+
+                $message.removeClassTransitioned('is-active', function()
+                {
+                    $message.remove();
+                    if (onClose)
+                    {
+                        onClose();
+                    }
+                });
+            });
         },
 
         htmlspecialchars: function(string)

What do you think? I'm not sure which option is better.
 
Upvote 0
This suggestion has been closed. Votes are no longer accepted.
Back
Top Bottom