CSSRule

@native @JSGlobal @JSType
class CSSRule extends Object

An object implementing the CSSRule DOM interface represents a single CSS at-rule. References to a CSSRule-implementing object may be obtained by looking at a CSS style sheet's cssRules list.

Companion:
object
class Object
trait Any
class Object
trait Matchable
class Any

Value members

Inherited methods

def hasOwnProperty(v: String): Boolean
Inherited from:
Object
def isPrototypeOf(v: Object): Boolean
Inherited from:
Object
def propertyIsEnumerable(v: String): Boolean
Inherited from:
Object
def toLocaleString(): String
Inherited from:
Object
def valueOf(): Any
Inherited from:
Object

Concrete fields

var CHARSET_RULE: Int
var IMPORT_RULE: Int
var KEYFRAME_RULE: Int
var MEDIA_RULE: Int
var PAGE_RULE: Int
var STYLE_RULE: Int
var UNKNOWN_RULE: Int
var VIEWPORT_RULE: Int
var `type`: Int
var cssText: String

cssText returns the actual text of the style rule. To be able to set a stylesheet rule dynamically, see Using dynamic styling information.

cssText returns the actual text of the style rule. To be able to set a stylesheet rule dynamically, see Using dynamic styling information.

Returns the containing rule, otherwise null. E.g. if this rule is a style rule inside an @media block, the parent rule would be that CSSMediaRule.

Returns the containing rule, otherwise null. E.g. if this rule is a style rule inside an @media block, the parent rule would be that CSSMediaRule.

parentStyleSheet returns the stylesheet object in which the current rule is defined.

parentStyleSheet returns the stylesheet object in which the current rule is defined.