Make un-hover delay configurable

Created on 14 April 2024, 7 months ago
Updated 14 September 2024, 2 months ago

Problem/Motivation

The 250 millisecond delay is a bit too fast for my taste, and I sometimes lose the opened menus, and need to start over.

Steps to reproduce

Use the Admin Toolbar, want to change to a deep sub-menu, and lose the opened menus if you stray outside for more than 250 milliseconds, and have to start over.

Proposed resolution

Make the "hover out" delay set in /js/admin_toolbar.hoverintent.js (timeout: 250) configurable, allowing the user to set it to for example 500 ms, or even 0 ms, to entirely disable it.

The setting could be under /admin/config/user-interface/admin-toolbar.

It could be a drop-down with pre-configured values (0, 250, 500, 750, 1000, 2500, 5000) or it could be an integer field, accepting values from 0 to 5000 (ms).

Remaining tasks

User interface changes

API changes

Data model changes

✨ Feature request
Status

RTBC

Version

3.0

Component

User interface

Created by

πŸ‡©πŸ‡°Denmark ressa Copenhagen

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @ressa
  • First commit to issue fork.
  • πŸ‡¬πŸ‡§United Kingdom aaron.ferris

    aaron.ferris β†’ made their first commit to this issue’s fork.

  • πŸ‡¬πŸ‡§United Kingdom aaron.ferris

    Made an initial MR for this - we could always add an update hook to make sure this setting exists, ive coded defensively for it.

  • Pipeline finished with Success
    2 months ago
    Total: 339s
    #283159
  • Status changed to RTBC 2 months ago
  • πŸ‡©πŸ‡°Denmark ressa Copenhagen

    This is awesome @aaron.ferris, thanks!

    It works perfectly, and bumping "Hover Intent Timeout (ms)" up to 500 ms or even 750 ms allows for non-precise mousing, without having to start all over with a multi-level traversal, due to slipping out of the menus accidentally. I'll set to RTBC, and if more code is on the way, it can always be reverted to "Needs work".

    PS. Setting timeout to 0 ms and speed-running Drupal menus, traversing to the deepest level of all menus could be a new sports discipline :-)

  • πŸ‡¬πŸ‡§United Kingdom aaron.ferris

    No problem, glad it’s working well for you.

Production build 0.71.5 2024