minimal-mistakes icon indicating copy to clipboard operation
minimal-mistakes copied to clipboard

Adjust layout around breadcrumbs and sidebar

Open lsolesen opened this issue 8 months ago • 3 comments
trafficstars

Theme version and system environment

  • Minimal Mistakes version: 4.26.2
  • Ruby gem or remote theme version: Newest
  • Jekyll version: Newest
  • Git repository URL: https://github.com/motionsplan/motionsplan-dk-jekyll
  • URL to the page with the problem: https://www.motionsplan.dk/tests/
  • Operating system:
  • Browser version:

What happened?

It is as if the layout is not completely strict when breadcrumbs are enabled.

Too big of a margin above, and the sidebar starting very low on the page.

Image

Expected behavior

A more streamlined layout.

Steps to reproduce the behavior

Look at the page to see the issue.

Other

No response

lsolesen avatar Feb 24 '25 11:02 lsolesen

Adding margin-top: -1rem to the breadcrumb element partly mitigates this:

Image

Not sure if there's a better way to fix without repositioning the breadcrumb's DOM position.

If you can submit a PR for this I'll be happy to review.

iBug avatar Feb 24 '25 12:02 iBug

No the DOM position is probably one issue. Not feeling right to have to give it a negative margin to fix the issue though right now.

lsolesen avatar Feb 25 '25 10:02 lsolesen

Hey, we are looking into the whole nav concept as well, since we want it a little tighter and dynamic too, but for us CSS is sufficient , the solution, as is present, respects the different viewports in different layouts better (at least than anything I came up with so far.)

.page__hero { position: relative; margin-bottom: 2em; // this value drags the breadcrumbs closer to the page hero.

.sidebar > * { margin-top: 0em; // from 1 to 0 sets it even with the Title margin-bottom: 1em; // distance sidebar autorbox

maybe that helps for now

cocacool49 avatar Mar 01 '25 12:03 cocacool49