CssParserBlock Class

A simple block (https://wicg.github.io/css-parser-api/#cssparserblock, https://drafts.csswg.org/css-syntax-3/#simple-block): [...], (...) or {...}.

public sealed class CssParserBlock : CssParserValue
Inheritance
CssParserValue CssParserBlock

Constructors

NameDescription
CssParserBlock(string, IEnumerable<CssParserToken>)Creates a simple block (https://wicg.github.io/css-parser-api/#dom-cssparserblock-cssparserblock).

CssParserBlock(string, IEnumerable<CssParserToken>)

CssParserObjects.cs

Creates a simple block (https://wicg.github.io/css-parser-api/#dom-cssparserblock-cssparserblock).

public CssParserBlock(string name, IEnumerable<CssParserToken> body)

Parameters

name string
The brackets of the block: "[]", "()" or "{}".
body IEnumerable<CssParserToken>
The component values of the block.

Exceptions

TypeErrorException
The name is not "[]", "()" or "{}".

See also

Properties

NameDescription
BodyGets the component values of the block.
NameGets the brackets of the block: "[]", "()" or "{}".

Gets the component values of the block.

public IReadOnlyList<CssParserToken> Body { get; }

Gets the brackets of the block: "[]", "()" or "{}".

public string Name { get; }