Javascript [Electronic resources] : The Definitive Guide (4th Edition)

David Flanagan

نسخه متنی -صفحه : 844/ 555
نمايش فراداده

Availability

DOM Level 2 CSS

Inherits from/Overrides

CSSRule CSSMediaRule

Properties

readonly

CSSRuleList

cssRules

An array (technically, a CSSRuleList) of all the rules nested within this @media rule block.

readonly

MediaList

media

The list of media types to which the nested rules apply.

Methods

deleteRule( )

Deletes the nested rule at the specified position.

insertRule( )

Inserts a new rule at the specified position within this @media rule block.

Description

This interface represents an @media rule, and all of its nested rules, in a CSS style sheet. It defines methods that allow you to insert and delete nested rules. Consult a CSS reference for details.