Revised fix for menu/UI issues for Joomla 4.0 #20401
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Overview
CiviCRM's below Menubar position is hidden in Joomla 4's new admin theme (1); and at tablet (2) & mobile (3), width, also for wrapped menus (4). There are other issues tidied here: white labels for the search menu (5); padding around the main content; and dashlets sometimes becomming extra wide (6).
Before
2.
3.
4.
5.
After
2.
3.
4.
5.
Technical Details
This was tested on Civi 5.37.1 with Joomla 4 Beta 7; as well as Joomla 3.9.26 to check against regressions. The css is namespaced with
body.layout-default
to prevent styles loading on Joomla 3.x; but in the event Joomla removes that from its body classes in the final J4 release another method will be needed.Comments
To help testing/debugging, the 1st commit in the PR is the menu, the 3rd removes padding and the 4th fixes the dashlet bug (the 2nd and 5th are spacing/indent tidying – which I didn't notice till checking the diff).