Table of Contents

Class CSSRule

Namespace
Selenium.WebDriver.BiDi.Cdp.CSS
Assembly
Selenium.WebDriver.BiDi.Cdp.dll

CSS rule representation.

public sealed record CSSRule : IEquatable<CSSRule>
Inheritance
CSSRule
Implements
Inherited Members

Constructors

CSSRule(SelectorList, StyleSheetOrigin, CSSStyle)

CSS rule representation.

public CSSRule(SelectorList SelectorList, StyleSheetOrigin Origin, CSSStyle Style)

Parameters

SelectorList SelectorList

Rule selector data.

Origin StyleSheetOrigin

Parent stylesheet's origin.

Style CSSStyle

Associated style declaration.

Properties

ContainerQueries

Container query list array (for rules involving container queries). The array enumerates container queries starting with the innermost one, going outwards.

public ImmutableArray<CSSContainerQuery>? ContainerQueries { get; init; }

Property Value

ImmutableArray<CSSContainerQuery>?

Layers

Cascade layer array. Contains the layer hierarchy that this rule belongs to starting with the innermost layer and going outwards.

public ImmutableArray<CSSLayer>? Layers { get; init; }

Property Value

ImmutableArray<CSSLayer>?

Media

Media list array (for rules involving media queries). The array enumerates media queries starting with the innermost one, going outwards.

public ImmutableArray<CSSMedia>? Media { get; init; }

Property Value

ImmutableArray<CSSMedia>?

Navigations

@navigation CSS at-rule array. The array enumerates @navigation at-rules starting with the innermost one, going outwards.

public ImmutableArray<CSSNavigation>? Navigations { get; init; }

Property Value

ImmutableArray<CSSNavigation>?

NestingSelectors

Array of selectors from ancestor style rules, sorted by distance from the current rule.

public ImmutableArray<string>? NestingSelectors { get; init; }

Property Value

ImmutableArray<string>?

Origin

Parent stylesheet's origin.

public StyleSheetOrigin Origin { get; init; }

Property Value

StyleSheetOrigin

OriginTreeScopeNodeId

The BackendNodeId of the DOM node that constitutes the origin tree scope of this rule.

public BackendNodeId? OriginTreeScopeNodeId { get; init; }

Property Value

BackendNodeId

RuleTypes

The array keeps the types of ancestor CSSRules from the innermost going outwards.

public ImmutableArray<CSSRuleType>? RuleTypes { get; init; }

Property Value

ImmutableArray<CSSRuleType>?

Scopes

@scope CSS at-rule array. The array enumerates @scope at-rules starting with the innermost one, going outwards.

public ImmutableArray<CSSScope>? Scopes { get; init; }

Property Value

ImmutableArray<CSSScope>?

SelectorList

Rule selector data.

public SelectorList SelectorList { get; init; }

Property Value

SelectorList

StartingStyles

@starting-style CSS at-rule array. The array enumerates @starting-style at-rules starting with the innermost one, going outwards.

public ImmutableArray<CSSStartingStyle>? StartingStyles { get; init; }

Property Value

ImmutableArray<CSSStartingStyle>?

Style

Associated style declaration.

public CSSStyle Style { get; init; }

Property Value

CSSStyle

StyleSheetId

The css style sheet identifier (absent for user agent stylesheet and user-specified stylesheet rules) this rule came from.

public StyleSheetId? StyleSheetId { get; init; }

Property Value

StyleSheetId

Supports

@supports CSS at-rule array. The array enumerates @supports at-rules starting with the innermost one, going outwards.

public ImmutableArray<CSSSupports>? Supports { get; init; }

Property Value

ImmutableArray<CSSSupports>?