Problem/Motivation

Currently, Toolbar doesn't work with Default Admin. Going back with git, looks like it broke with #3590364: Part 2 of Consolidate, refactor, remove and untangle Claro's CSS from Default Admin theme—probably with the removal of Toolbar integration from the theme.

I'm calling this a regression and Major because we want people to experiment with Default Admin, but they will see a mess if they try it out on a site that's using Toolbar. IMO, Toolbar needs to work with Default Admin until it's removed.

Here's a screenshot from 11.4.4:

Steps to reproduce

  1. Install 11.4.4.
  2. Install Default Admin theme and set it as the administration theme.
  3. Uninstall the Navigation module.
  4. Install the Toolbar module.
  5. Go to any admin page.

Proposed resolution

Ensure Toolbar works with Default Admin.

Perhaps restore the Toolbar integration in Default Admin until it can be fixed in the Toolbar module at the same time.

Remaining tasks

User interface changes

Introduced terminology

API changes

Data model changes

Release notes snippet

Issue fork drupal-3612540

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

kentr created an issue. See original summary.

kentr’s picture

Title: [11.4 regression] Default Admin breaks Toolbar » [11.4 regression] Fix Toolbar with Default Admin
Issue summary: View changes

c2h2o5 made their first commit to this issue’s fork.

rupeshghar’s picture

StatusFileSize
new37.98 KB
new114.09 KB
new16.46 KB

default_admin.info.yml overrides toolbar's CSS to a file that doesn't exist (css/components/toolbar.module.css), dropped during #3590364's consolidation but the override reference stayed. That file has the tray show/hide logic, so without it every tray renders expanded and stacked. Restored it from Claro's equivalent, matching the theme's other toolbar CSS overrides. Tested on 11.4.4 with Default Admin + Toolbar: renders correctly now.

Patch and screenshots attached.

rupeshghar’s picture

Status: Active » Needs review
smustgrave’s picture

Status: Needs review » Needs work

Fixes need to be in MRs

kentr’s picture

Issue tags: +Needs merge request

There's already an issue fork with a change that appears to fix this (#3).

As @smustgrave said, it needs a merge request created.

@c2h2o5: if your change is ready, please create a merge request and set this issue to "Needs review".

quietone’s picture

Title: [11.4 regression] Fix Toolbar with Default Admin » [regression] Fix Toolbar with Default Admin
Issue tags: -Regression

Changing title per Special titles.

kentr’s picture

Component: toolbar.module » Admin theme

Thanks @quietone.

Both the change in #3 and the patch in #4 are against Default Admin, so I'm changing the component.

jurgenhaas’s picture

The issue fork has a commit that removes the non-existing css file from the toolbar library. The patch from #4, however, brings back that missing file. Only one of those approaches should be followed. If it's about bringing back the css file, then the patch from #4 needs to be brought into the issue fork and the commit from #3 needs to be removed.

I've created the MR so that it's easier for folks to look into it. But we first need to decide which path to take.

kentr’s picture

But we first need to decide which path to take.

To me, that's your call as subsystem maintainer.

In a roadmap of removing Toolbar support from the theme and deprecating Toolbar, removing the non-existing css file from the toolbar library (#3) seems like the cleanest and most proper.

Adding the missing file back to the theme (#4) seems like a step backwards.

It looks like your MR takes the path of #3.

jurgenhaas’s picture

Well, I thought that decision depends on which of the 2 approaches actually really fixes the problem. If removing the missing file from the library is a fix, that's certainly preferred. Less code is always better. But if that's just to avoid an error message but the styling would not be fixed by that, then maybe the other approach is required.

So, my question actually was ment to go to the 2 contributors of the 2 code changes to learn, if they both finally fix the problem.

And the MR is actually not mine, I've just opened the MR with the commit from #3.

charlliequadros’s picture

Hi @jurgenhaas,

I tested the MR.
In the first image, before applying the changes, you can see that the issue was already occurring.

image with regression error

In the second image, after applying the changes, the issue was resolved.

Image applied using MR.
The MR looks good. It removes a reference to a CSS file that does not exist and provides a smaller and simpler solution compared to patch 4.

I believe we can proceed with this MR, as the changes resolved the issue.

charlliequadros’s picture

Status: Needs work » Needs review
saman_malik’s picture

StatusFileSize
new63.17 KB
new73.99 KB

Verified and tested MR !16485 on 11.4.4 — everything looks good.

Setup:

Set Default Admin as the administration theme.
Uninstalled Navigation module.
Installed Toolbar module.

Before patch: Confirmed the reported bug — toolbar trays rendered fully expanded and stacked, matching the issue screenshots.

After applying MR !16485: Toolbar renders correctly — trays collapse/expand as expected, no visual issues.
RTBC++

kentr’s picture

Status: Needs review » Reviewed & tested by the community
Issue tags: -Needs merge request

Thanks for reviewing the MR!

Maybe #13 is causing uncertainty, but for folks who don't know:

The usual protocol is to set the status to Reviewed & tested by the community if you find in your testing that the MR fixes the problem. Please see Life cycle of an issue for details.

IMO, the MR can be RTBC. Someone in charge will change it back if they disagree.

kentr’s picture

At least, I don't think it needs more manual testing on the current MR, anyway.