Skip to content

Instantly share code, notes, and snippets.

@vctls
Last active July 8, 2021 13:35
Show Gist options
  • Save vctls/4fe6f6a13300328c401f0b9f02001dfd to your computer and use it in GitHub Desktop.
Save vctls/4fe6f6a13300328c401f0b9f02001dfd to your computer and use it in GitHub Desktop.
Symfony doc, wide layout, no distractions.
/* ==UserStyle==
@name symfony.com - 25/05/2020 à 15:29:45
@namespace github.com/openstyles/stylus
@version 1.0.0
@description A new userstyle
@author Me
==/UserStyle== */
@-moz-document url-prefix("https://symfony.com/doc/") {
.container {
max-width: 100% !important;
}
.header__bottom {
position: relative;
}
/* Make navi menu fixed and same color as background. */
.doc__nav {
position: fixed;
top: 120px !important;
background: var(--page-background);
padding: 10px;
border-radius: 5px;
z-index: 1;
}
.doc__tools {
position: fixed;
left: 10px;
top: 50px !important;
}
.version__all {
right: auto;
}
/* Hide ads, conference dates, Symfony network, etc. */
.header__top,
[data-category="Ads"],
.ads,
#sln,
.sfbook-banner,
.conference-banner,
.doc__backer,
div.d-sm-block:nth-child(2) {
display: none !important;
}
#content_wrapper {
margin-top: 0;
}
aside{
width: 15% !important;
}
main{
width: 85% !important;
}
}
@vctls
Copy link
Author

vctls commented Jul 8, 2021

Makes Symfony documentation use most of the page width, only leaving some space for the navigation menu on the left.
Hides most distractions like banners, sponsors, etc.
Uses the background color variable in order to preserve theme synchronization.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment