A part of the structured CSS picker.

It is a structured CSS selector part that:

  • does not contain empty properties,
  • does not contain unnecessary * element,
  • does not contain empty class names,
  • does not contain empty class names array,
  • has class names sorted,
  • does not contain empty sub-selectors array,
  • contains normalized sub-pickers.
  • does not contain empty qualifiers,
  • does not contain empty qualifiers array,
  • has qualifiers exposed, e.g. foo:bar=baz is exposed as three qualifiers: foo, foo:bar, and foo:bar=baz
  • has qualifiers sorted.

Hierarchy

Properties

Properties

$?: readonly [string, string]

Array of qualifiers.

Either absent, or non-empty and containing non-empty qualifiers sorted alphabetically.

c?: readonly [QualifiedName, QualifiedName]

Array of element class names.

Either absent, or non-empty and containing non-empty class names sorted alphabetically.

e?: QualifiedName

Element name.

This is the same as * when absent. Unless the part contains only sub-selectors, and the first one is either a pseudo-class or a pseudo-element.

i?: QualifiedName

Element identifier.

ns?: string | NamespaceDef

Element namespace.

s?: string

Raw CSS selector text to append to the end.

When all other properties are omitted this one represents a raw CSS selector text. Otherwise it is appended to other selector parts representation.

Array of sub-pickers, each of which represents either attribute selector, pseudo-class, or pseudo-element.

Either absent or non-empty.

Generated using TypeDoc