Home Reference Source
import {SelectorElement} from 'potassium-es/src/style/Selector.js'
public class | source

SelectorElement

Extends:

SelectorFragment → SelectorElement

SelectorElement holds a parsed version of a single element in a selector.

Example element strings: .foo:active div#id.group.dinkus-moon[foo=23][bar^="glitz grease"][blatz]::after:first

Note: combinators like '>>', '>', '+', and '~' are represented by the {Combinator} class, not this class

Constructor Summary

Public Constructor
public

constructor(selector: string)

Member Summary

Public Members
public get

Method Summary

Public Methods
public

matches(node: *): bool

Public Constructors

public constructor(selector: string) source

Params:

NameTypeAttributeDescription
selector string

the string of a single selector element

Public Members

public get raw: string source

Public Methods

public matches(node: *): bool source

Params:

NameTypeAttributeDescription
node *

Return:

bool