Use action buttons on bottom as well as within the sticky header

Created on 18 June 2025, about 1 month ago

Problem/Motivation

With https://www.drupal.org/project/gin/issues/3356717 Move Action buttons to sticky header Fixed the option to use sticky action buttons was introduced, which is a great addition. However with a few forms I'm running into the issue that the buttons are not really user friendly, or hidden behind a dot menu.
For example when using the TFA module, the saving of the setup is hidden in the header. See the attached picture.

We can of course disable the sticky header buttons, but this would lose all the positives as well. Is it possible to have a 'best of both worlds' scenario?
Removing the visually hidden for the form actions in the CSS does the trick, but it probably has to be a little more thought out (also regarding a11y) to be a valid solution. Maybe also considering to only show certain actions as sticky buttons (save?)

Curious to see if anyone else has run into this issue or if this has been discussed before.

Steps to reproduce

-

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Feature request
Status

Active

Version

5.0

Component

Code

Created by

🇳🇱Netherlands nvandijk

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

Comments & Activities

  • Issue created by @nvandijk
  • 🇳🇱Netherlands nvandijk

    Hi saschaeggi,

    I tried to use your method of using the hook for a different problem, however the sticky buttons still show up because I'm trying this for a node bundle form. They are still activated in the GinContentFormHelper as it is a content form with actions.

    This bundle uses a workflow, so does not use the standard $includes = ['save', 'submit', 'preview']; buttons as defined in gin_form_after_build. For the workflow buttons module there is even a patch for ensuring that the buttons are visible in Gin, I feel like this should not be mandatory for modules that might possibly be used in a installation that uses Gin. I feel that this should be the responsibility of the installation that combines modules with Gin, but the ability to configure this should be facilitated by Gin itself. A hook to modify the $includes for a form could be a solution for example.

    This means that no button is initially visible and all of them are hidden behind the more_actions menu, even when using the hook_gin_ignore_sticky_form_actions.

    Could you tell me if there is also a way to override the includes or something that might resolve the issues I am facing now?
    I saw issue https://www.drupal.org/project/gin/issues/3488050 🐛 Uncaught TypeError: formActions is null on a form that is trying not to use Gin form modifications Active relates to this as well. Please let me know if this is more suited there.

Production build 0.71.5 2024