Closed mootari closed 2 years ago
Possible duplicate, but regarding the left sidebar: #4635
Possible duplicate, but regarding the left sidebar: #4635
Not sure it is still a problem. That is from 2021.
@Rumyra that's a tricky one. All columns don't play well together.
table-layout: fixed;
does the trick. But that would be applied to all tables in content. Would that work?
@Rumyra that's a tricky one. All columns don't play well together.
table-layout: fixed;
does the trick. But that would be applied to all tables in content. Would that work?
@fiji-flo Do we have a utility class for that or would it need to be an inline style attribute? I would definitely want to avoid adding inline style
attributes in content as this has bitten us in the past.
@schalkneethling My suggestion is to apply this to all tables.
The theme already defines a div.table-scroll
element that is e.g. used to wrap the browser compatibility table. Why not alter the table markup that is produced by Markdown to automatically wrap tables this way?
My gut is telling me this is actually due to the table being inside a dl - let me find some more examples to check, but it could be we can dl table {table-layout: fixed;}
which would be better 👍
Applying table-layout: fixed
would cause all columns to have equal width, which can result in very suboptimal table layouts.
Here's a list of paths that should contain Markdown tables (grepped from the content repo):
Page: https://developer.mozilla.org/en-US/docs/Web/API/TreeWalker
Browser: Chrome 97 (macOS 11.6.4, devicePixelRatio=2)
At a viewport width of >=1200px the element
nav#sidebar-quicklinks
is displayed on the right side of the content. Unfortunately it overlaps the content up until ~1270px width (see screenshot).