User tests: Successful: Unsuccessful:
Pull Request resolves #48397
The Save & Close split button rendered its dropdown toggle before the primary button in the HTML. A CSS order: 1 rule then moved the toggle to the right, so it looked correct but keyboard focus went to the toggle first. The toggle was also named only "Toggle Dropdown".
layouts/joomla/toolbar/dropdown.php: render the primary button first, then the toggle. The DOM order now matches the visual order. The hidden label uses a new $toggleText variable and falls back to the old string.libraries/src/Toolbar/Button/DropdownButton.php: build toggleText from the primary button's text, for example "Save & Close options".administrator/language/en-GB/joomla.ini: add JTOOLBAR_SPLIT_TOGGLE_OPTIONS="%s options"._toolbar.scss: remove the order: 1 workaround. The look is unchanged.The fix is in the shared toolbar layout, so every edit form that uses the Save & Close group gets it. The "Toggle Dropdown" label is still used by two hand-written buttons, in the Users list and the Module assignment tab. I left those alone because they don't use this layout.
npm run build. If you use a pull-request test tool, it does this for you.<button> comes before Save & Close.Please select:
Documentation link for guide.joomla.org:
No documentation changes for guide.joomla.org needed
Pull Request link for manual.joomla.org:
No documentation changes for manual.joomla.org needed
| Status | New | ⇒ | Pending |
| Category | ⇒ | Administration Language & Strings Layout Libraries NPM Change |
I agree that the accessible name needs improving. "Toggle Dropdown" is too generic and doesn't explain what the dropdown relates to.
However, I am not convinced that changing the DOM order is necessarily the right solution.
The current implementation has a visual ordering that is achieved using CSS, and I would like to understand whether there is a reason the DOM was originally structured this way before changing it. Matching the DOM order to the visual order is not, in itself, an accessibility requirement. What matters is that the resulting focus order and screen-reader experience are logical and meaningful. There is nothing inherently wrong with a DOM order differing from visual order, provided the resulting keyboard and assistive-technology experience remains logical and understandable. WCAG 2.4.3 requires a meaningful focus order, not necessarily identical DOM and visual ordering in every situation.
I would also like to see this tested against all the other uses of this shared dropdown layout, rather than just the Save & Close example, to ensure that changing the order does not introduce unexpected behaviour elsewhere.
I support making the accessible name more descriptive, but I think we should consider whether that name should be explicitly configurable rather than automatically derived from the primary button's text. That would give us more flexibility for other uses of the component.
I would therefore separate the two changes and establish that the DOM-order change is actually necessary before adopting it.
Thanks @brianeteeman for the review. Taking your points in turn:
I found no discussion of reading order or focus order in #32440 (all 10 comments, no inline comments) or in #31990 (keyword search of its
comments and inline review comments). If you know of another reason, please tell me.
3. Testing some other uses.
Test 1: keyboard open and close
With focus on the caret, Enter opens the menu (aria-expanded="true"). Esc closes it and focus stays on the caret.
https://github.com/user-attachments/assets/d64a4421-3599-4436-a37d-e39eb4ea242f
Test 2: accessible name
The Firefox Accessibility panel shows the caret as role button with the name "Save & Close options". The name was "Toggle Dropdown" before.

Test 3: mouse
Clicking the caret opens the menu. Clicking outside closes it. The main Save button saves the article. "Save & New" from the menu works too.
https://github.com/user-attachments/assets/f290de2d-9b9a-4ba8-bc7d-ec25fd988d8d
Test 4: RTL
With dir="rtl" the caret mirrors to the left of Save & Close and stays attached to it.
https://github.com/user-attachments/assets/2a21f95d-2da2-4c16-9502-4632f59a2573
it remain identical in both before and after
Test 5:
Before-
https://github.com/user-attachments/assets/9deb2fa1-cf40-4fa8-8557-f5d20c103c26
After-
Test 6:
under Banner
Before
After:
Same behaviour under Menu page, tags page
I do not agree with the change in order