Skip to content

Valley of Code / Bootcamp.dev by sirmontegu

Details

Authorsirmontegu

LicenseUNLICENSE (https://choosealicense.com/licenses/unlicense/)

CategoryBootcamp.dev

Created

Updated

Size1.8 kB

Statistics

Learn how we calculate statistics in the FAQ.

Failed to fetch stats.

Description

Makes content on Flavio Copes training sites a little bit more readable.

Intended for large screens, not recommended for screens <1200px wide.

Notes

  • Moves TOC out of the way until needed
  • Adjust font/spacing
  • Centers content
  • Reduces image size with hover interaction to view full-size

Source code

/* ==UserStyle==
@name         Valley of Code / Bootcamp.dev
@version      20240303.02.05
@namespace    https://userstyles.world/user/sirmontegu
@description  Makes content on Flavio Copes training site a little easier to read on wide screens.
@author       sirmontegu
@license      UNLICENSE (https://choosealicense.com/licenses/unlicense/)
==/UserStyle== */

@-moz-document domain("bootcamp.dev") {
#sidebar {
    position: fixed;
    width: auto;
    max-width: 25%;
    left: 0;
    opacity: 10%;
}
#sidebar:hover {
    opacity: 100%;
}
main.full > div > div {
    min-width: auto;
    max-width: unset;
}
#content h1 {
    margin: 12rem -2rem 2rem;
    display: flex;
    font-size: 2rem;
    line-height: 3rem;
    flex-direction: column;
}
#content {
    font-family: Roboto, ui-system, sans-serif;
    *:not(code *) {
        letter-spacing: .025em;
    }

    h1 + p {
        margin-top: .5rem;
    }
    img {
        max-width: 300px;
        transition: .5s ease-in-out;
        border-radius: .5rem;
    }
    img:hover {
        max-width: 100%;
    }

    p:has(img) {
        margin-top: .5rem;
        margin-bottom: 0;
    }
    & pre > code {
        font-family: Roboto Mono, ui-monospace, monospace;
        letter-spacing: 0;
        font-size: smaller;
    }
}
@media (min-width: 1600px) {
    main {
        max-width: unset;
    }
    main section:first-child {
        width: auto;
    }
    main section:last-child {
        width: 100%;
        min-width: auto;
        max-width: 80ch;
        margin: 0px auto;
    }
    main section:last-child {
        width: 100%;
        min-width: auto;
        max-width: 80ch;
        margin: 0px auto;
    }
}
}

Reviews

No reviews yet.