A single CSS style sheet. It inherits properties and methods from its parent, StyleSheet.

interface CSSStyleSheet {
    cssRules: CSSRuleList;
    disabled: boolean;
    href: string;
    media: MediaList;
    ownerNode: Element | ProcessingInstruction;
    ownerRule: CSSRule;
    parentStyleSheet: CSSStyleSheet;
    rules: CSSRuleList;
    title: string;
    type: string;
    addRule(selector?, style?, index?): number;
    deleteRule(index): void;
    insertRule(rule, index?): number;
    removeRule(index?): void;
    replace(text): Promise<CSSStyleSheet>;
    replaceSync(text): void;
}

Hierarchy

Properties

cssRules: CSSRuleList
disabled: boolean
href: string
media: MediaList
ownerRule: CSSRule
parentStyleSheet: CSSStyleSheet
rules: CSSRuleList

Deprecated

title: string
type: string

Methods

  • Parameters

    • Optional selector: string
    • Optional style: string
    • Optional index: number

    Returns number

    Deprecated

  • Parameters

    • index: number

    Returns void

  • Parameters

    • rule: string
    • Optional index: number

    Returns number

  • Parameters

    • Optional index: number

    Returns void

    Deprecated

  • Parameters

    • text: string

    Returns Promise<CSSStyleSheet>

  • Parameters

    • text: string

    Returns void

Generated using TypeDoc