Skip to content

Instantly share code, notes, and snippets.

@bjesuiter
Created May 23, 2022 09:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bjesuiter/d358dde0a9a5b89412a79919f4cd1a88 to your computer and use it in GitHub Desktop.
Save bjesuiter/d358dde0a9a5b89412a79919f4cd1a88 to your computer and use it in GitHub Desktop.
Prevent CSS Grid Blowout / Overflowing it's Parent
.document-tile-control-box.desktop-mode {
// The reason for minmax(0, value) here is:
// - forces grid columns to have a defined min-width
// - which forces the grid to assume defined sizes and to not grow columns indefinitely
// - more details: https://css-tricks.com/preventing-a-grid-blowout/
grid-template-columns: minmax(0, max-content) minmax(0, max-content);
grid-template-rows: 1fr min-content min-content;
/* prettier-ignore */
grid-template-areas:
"anschreiben agbsb"
"hinweis hinweis"
"formularFreigeben formularFreigeben";
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment