Skip to content

Instantly share code, notes, and snippets.

@Zodiac1978
Last active March 13, 2021 19:40
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 Zodiac1978/d3a857b0520db51e84c0939cab853ebb to your computer and use it in GitHub Desktop.
Save Zodiac1978/d3a857b0520db51e84c0939cab853ebb to your computer and use it in GitHub Desktop.
Responsiveness Spalten-Block anpassen - CSS-Lösung für das hier beschriebene Problem: https://die-netzialisten.de/responsiveness-spalten-block-anpassen/
/*
Sources:
https://stackoverflow.com/questions/8720931/can-css-detect-the-number-of-children-an-element-has
https://lea.verou.me/2011/01/styling-children-based-on-their-number-with-css3/
*/
@media (min-width:600px) and (max-width:781px) {
.wp-block-column:first-child:nth-last-child(3) {
flex-basis: 100% !important;
}
.wp-block-column:first-child:nth-last-child(3) ~ .wp-block-column {
margin-left: 0 !important;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment