ProfessionalWiki / chameleon

Provides a highly flexible and customizable skin using Bootstrap 4
https://www.mediawiki.org/wiki/Skin:Chameleon
Other
115 stars 63 forks source link

Tweak CSS to fix grouping of "right" items when navbar is collapsed #354

Closed mdoggydog closed 1 year ago

mdoggydog commented 1 year ago

It is not clear what the .flex-row on .navbar-nav.right elements was intended to accomplish, but the effect that it has is that, when the navbar is collapsed and switches to a vertical layout, all the right-grouped navbar items are jammed together into a single row (instead of switching to a vertical/column layout like the non-right- -grouped items). Removing the .flex-row fixes that.

This commit also removes the .justify-content-center, which does not seem to have any effect at all on any layout/orientation/screen. (Since the .navbar-nav.right wrapper is always squeezed to the right, there is no free space into which its children can be centered.)

For what it's worth, this commit does leave the .mt-4 in place; it does not seem to have any effect in the horizontal layout, and in the collapsed/vertical layout it appears to introduce a gap between the "left" grouped (top) items and the "right" grouped (bottom) items.

Before this commit:

screenshot-navbar-right-forced-row

After this commit:

(...and, after #353 so that everything is vertically centered, too) screenshot-navbar-right-not-forced-row