Anyone wanting to give this a spin can enable the toggletip_test module and go to /toggletip-test/toggletips. It's a test module, so $settings['extension_discovery_scan_tests'] = TRUE; must be configured.
Problem/Motivation
Often, the administration interface gets really busy because there’s a lot of information that needs to be available for the user. Especially in long forms, the descriptions and extra information of fields and other elements add a lot of visual complexity.
Proposed resolution
This extra info could be added to a toggle tip (as opposed to a tooltip). A toggletip has a dedicated disclosure button, while a tooltip is triggered by content that already exists on the page.
Such an elementwould simplify the UI and would allow to add extra information when needed.
Make it ad
Remaining tasks
- Track down UI examples where this could be implemented.
Decide on its implementation: render array or new form element?Render array property that can be added to any existing element. It should also be possible to implement it with just markup, using thedata-drupal-toggletip-toggle-button
attribute.Accesibility feedback: what's the best implementation? Like should it be triggered on hover or on click/touch?Click / touch
User interface changes
Initial design explorations: https://www.figma.com/file/OqWgzAluHtsOd5uwm1lubFeH/Drupal-Design-system...