Allow content width to grow without limiting it. #6404
-
Hi, I have some wide content that I'd like to be able to see without scroll bars. I can get it to sort of work if I set via browser developer tools/console:
as that wil make the content wide enough to display without scroll bars, but it's not dynamic and setting that in my extra css doesn't have any effect, I think because it gets overwritten after/as the page loads. What I'd bascially like to do is just allow the content section to grow so that the page always fills the browser window. Where/what would I change to allow that? Thanks, griznog |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 6 replies
-
Hello, .md-main__inner.md-grid {
max-width: initial;
} or .md-grid {
max-width: initial;
} The first one targets the inner content grid specifically, and the second targets all of them (footer and header have separate grids). If you don't want to use https://squidfunk.github.io/mkdocs-material/customization/#additional-css |
Beta Was this translation helpful? Give feedback.
-
Interesting and helpful. But what I really want is a way to change the threshold when it displays the navigation as tabs vs. as a dropdown. |
Beta Was this translation helpful? Give feedback.
Hello,
to stretch the content area fully and dynamically, in your extra css you can set either one:
or
The first one targets the inner content grid specifically, and the second targets all of them (footer and header have separate grids).
You can use both but, keep in mind that in CSS specificity matters, so
.md-main__inner.md-grid
will override a plain.md-grid
.If you don't want to use
initial
userem
values, I believe thatmax-width: 61rem;
is the default for.md-grid
.https://squidfunk.github.io/mkdocs-material/customization/#additional-css