Created
November 22, 2023 08:17
-
-
Save Mix-Liten/9ae9460fae9ffb65e7a1a5a194e65357 to your computer and use it in GitHub Desktop.
A new approach to container and wrapper classes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.content { | |
--gap: clamp(1rem, 6vw, 3rem); | |
--full: minmax(var(--gap), 1fr); | |
--content: min(75ch, 100% - var(--gap) * 2); | |
--popout: minmax(0, 2rem); | |
--feature: minmax(0, 5rem); | |
display: grid; | |
grid-template-columns: | |
[full-start] var(--full) | |
[feature-start] var(--feature) | |
[popout-start] var(--popout) | |
[content-start] var(--content) [content-end] | |
var(--popout) [popout-end] | |
var(--feature) [feature-end] | |
var(--full) [full-end]; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Refs: