Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Original CSS-
@media(min-width:720px) {
.class {
font-family: "EB Garamond", serif;
}
}
This would render as-
@media(min-width:720px) {
.class {
font-family: "EB Garamond", serif;
}
.eb-garamond @media(min-width:720px) {
font-family: "EB Garamond", serif;
}
}
This isn't correct CSS, so fonts being set inside a media query weren't being set correctly when they loaded. Correct CSS would be-
@media(min-width:720px) {
.class {
font-family: "EB Garamond", serif;
}
.eb-garamond .class{
font-family: "EB Garamond", serif;
}
}
Patch filters out selectors that start with "@media" and looks for the selector inside.
Comment | File | Size | Author |
---|---|---|---|
#2 | filter-media-queries-2553445-1.patch | 816 bytes | jamessw |
Comments
Comment #2
jamessw CreditAttribution: jamessw commentedComment #3
mikeytown2 CreditAttribution: mikeytown2 commentedComment #4
mikeytown2 CreditAttribution: mikeytown2 commentedThanks for the patch! It's been committed. Also added a couple of inline comments.