Bug 1885602 - Part 5: Implement navigating to the SUMO help topic from the menu heade...
[gecko.git] / dom / webidl / CSSStyleRule.webidl
blob652e456f658ecfd95b372b579f720517f7869084
1 /* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3  * License, v. 2.0. If a copy of the MPL was not distributed with this file,
4  * You can obtain one at http://mozilla.org/MPL/2.0/.
5  *
6  * The origin of this IDL file is
7  * https://drafts.csswg.org/cssom/#the-cssstylerule-interface
8  */
10 // https://drafts.csswg.org/cssom/#the-cssstylerule-interface
11 [Exposed=Window]
12 interface CSSStyleRule : CSSGroupingRule {
13   attribute UTF8String selectorText;
14   [SameObject, PutForwards=cssText] readonly attribute CSSStyleDeclaration style;
16   [ChromeOnly] readonly attribute unsigned long selectorCount;
17   [ChromeOnly] UTF8String selectorTextAt(unsigned long index, optional boolean desugared = false);
18   [ChromeOnly] unsigned long long selectorSpecificityAt(unsigned long index, optional boolean desugared = false);
19   [ChromeOnly] boolean selectorMatchesElement(
20     unsigned long selectorIndex,
21     Element element,
22     optional [LegacyNullToEmptyString] DOMString pseudo = "",
23     optional boolean includeVisitedStyle = false);
24   [ChromeOnly] sequence<SelectorWarning> getSelectorWarnings();
27 enum SelectorWarningKind {
28   "UnconstrainedHas",
31 dictionary SelectorWarning {
32   required unsigned long index;
33   required SelectorWarningKind kind;