From 26a029d407be480d791972afb5975cf62c9360a6 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Fri, 19 Apr 2024 02:47:55 +0200 Subject: Adding upstream version 124.0.1. Signed-off-by: Daniel Baumann --- .../tests/interfaces/css-parser-api.idl | 76 ++++++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 testing/web-platform/tests/interfaces/css-parser-api.idl (limited to 'testing/web-platform/tests/interfaces/css-parser-api.idl') diff --git a/testing/web-platform/tests/interfaces/css-parser-api.idl b/testing/web-platform/tests/interfaces/css-parser-api.idl new file mode 100644 index 0000000000..4e34a3f25d --- /dev/null +++ b/testing/web-platform/tests/interfaces/css-parser-api.idl @@ -0,0 +1,76 @@ +// GENERATED CONTENT - DO NOT EDIT +// Content was automatically extracted by Reffy into webref +// (https://github.com/w3c/webref) +// Source: CSS Parser API (https://wicg.github.io/css-parser-api/) + +typedef (DOMString or ReadableStream) CSSStringSource; +typedef (DOMString or CSSStyleValue or CSSParserValue) CSSToken; + +partial namespace CSS { + Promise> parseStylesheet(CSSStringSource css, optional CSSParserOptions options = {}); + Promise> parseRuleList(CSSStringSource css, optional CSSParserOptions options = {}); + Promise parseRule(CSSStringSource css, optional CSSParserOptions options = {}); + Promise> parseDeclarationList(CSSStringSource css, optional CSSParserOptions options = {}); + CSSParserDeclaration parseDeclaration(DOMString css, optional CSSParserOptions options = {}); + CSSToken parseValue(DOMString css); + sequence parseValueList(DOMString css); + sequence> parseCommaValueList(DOMString css); +}; + +dictionary CSSParserOptions { + object atRules; + /* dict of at-rule name => at-rule type + (contains decls or contains qualified rules) */ +}; + +[Exposed=Window] +interface CSSParserRule { + /* Just a superclass. */ +}; + +[Exposed=Window] +interface CSSParserAtRule : CSSParserRule { + constructor(DOMString name, sequence prelude, optional sequence? body); + readonly attribute DOMString name; + readonly attribute FrozenArray prelude; + readonly attribute FrozenArray? body; + /* nullable to handle at-statements */ + stringifier; +}; + +[Exposed=Window] +interface CSSParserQualifiedRule : CSSParserRule { + constructor(sequence prelude, optional sequence? body); + readonly attribute FrozenArray prelude; + readonly attribute FrozenArray body; + stringifier; +}; + +[Exposed=Window] +interface CSSParserDeclaration : CSSParserRule { + constructor(DOMString name, optional sequence body); + readonly attribute DOMString name; + readonly attribute FrozenArray body; + stringifier; +}; + +[Exposed=Window] +interface CSSParserValue { + /* Just a superclass. */ +}; + +[Exposed=Window] +interface CSSParserBlock : CSSParserValue { + constructor(DOMString name, sequence body); + readonly attribute DOMString name; /* "[]", "{}", or "()" */ + readonly attribute FrozenArray body; + stringifier; +}; + +[Exposed=Window] +interface CSSParserFunction : CSSParserValue { + constructor(DOMString name, sequence> args); + readonly attribute DOMString name; + readonly attribute FrozenArray> args; + stringifier; +}; -- cgit v1.2.3