Options
All
  • Public
  • Public/Protected
  • All
Menu

Stores information on a media query applied to a document, and handles sending notifications to listeners when the media query state change (i.e. when the media query test starts or stops evaluating to true).

Hierarchy

  • EventTarget
    • MediaQueryList

Index

Properties

matches: boolean
media: string
onchange: null | ((this: internal.MediaQueryList, ev: internal.MediaQueryListEvent) => any)

Methods

  • addEventListener<K>(type: K, listener: ((this: internal.MediaQueryList, ev: MediaQueryListEventMap[K]) => any), options?: boolean | AddEventListenerOptions): void
  • addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void
  • dispatchEvent(event: Event): boolean
  • Dispatches a synthetic event event to target and returns true if either event's cancelable attribute value is false or its preventDefault() method was not invoked, and false otherwise.

    Parameters

    • event: Event

    Returns boolean

  • removeEventListener<K>(type: K, listener: ((this: internal.MediaQueryList, ev: MediaQueryListEventMap[K]) => any), options?: boolean | EventListenerOptions): void
  • removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void

Generated using TypeDoc