Skip to content

[question] How to filter by media query #96

Open
@JonathanKolnik

Description

@JonathanKolnik

Hi,
I'm struggling to filter by a media type. Any help would be greatly appreciated!

CSS

@media (max-width: 767px) {
  h1 {
    font-size: 12px
  }
}

Console:
It has the media query

parser.rules_by_media_query.keys
 => [:all, :print,  :"(max-width:767px)", ...]

I can't figure out the syntax to filter by that media type though

#symbol
parser.find_by_selector("h1", :"(max-width:767px)")
 => []

#string
parser.find_by_selector("h1", "(max-width:767px)")
 => []

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions