Can a user style move tables of contents to the left of articles?
For use with e.g. Stylus. Thanks.
<https://docs.freebsd.org/en/articles>
For use with e.g. Stylus. Thanks.
<https://docs.freebsd.org/en/articles>
What link is that?
flex-direction: row-reverse
property to the <main> element.I don't know Stylus, but basically you have to add the new property to the <main> element (which has the classWhat should I type?
main-wrapper-article
). In CSS this would look like this:.main-wrapper-article {
flex-direction: row-reverse;
}
@-moz-document domain("docs.freebsd.org") {
main.main-wrapper-article {
flex-direction: row-reverse !important;
}
}
This could be done by using theFor now, I can't be bothered to work around the exceptional pages.
order
property instead. See the link i posted earlier.In addition to reversing the order in which flex items are visually displayed, you can target individual items and change where they appear in the visual order with the order property.
.main-wrapper-article .article-toc,
.main-wrapper-book .book-toc {
order: 1 !important;
}
.main-wrapper-article .article,
.main-wrapper-book .book {
order: 2 !important;
}
… TOC always to be to the left, regardless of its position in the source code. …
aside.toc
{
visibility: hidden !important;
}
display: none;
.Exactly. That would be a good basis for a user activated display<->hide of either side TOC.[...] But in order to hide the TOC i'd rather usedisplay: none;
.
.main-wrapper-article .article-toc,
.main-wrapper-book .book-toc,
.main-wrapper-book .toc,
aside.book-menu,
aside.toc {
display: none !important;
}