chromium/third_party/polymer/v3_0/components-chromium/iron-media-query/iron-media-query.d.ts

/**
 * DO NOT EDIT
 *
 * This file was automatically generated by
 *   https://github.com/Polymer/tools/tree/master/packages/gen-typescript-declarations
 *
 * To modify these typings, edit the source file(s):
 *   iron-media-query.js
 */

import {Polymer} from '../polymer/lib/legacy/polymer-fn.js';

import {LegacyElementMixin} from '../polymer/lib/legacy/legacy-element-mixin.js';

/**
 * `iron-media-query` can be used to data bind to a CSS media query.
 * The `query` property is a bare CSS media query.
 * The `query-matches` property is a boolean representing whether the page matches
 * that media query.
 *
 * Example:
 *
 * ```html
 * <iron-media-query query="(min-width: 600px)" query-matches="{{queryMatches}}">
 * </iron-media-query>
 * ```
 */
interface IronMediaQueryElement extends LegacyElementMixin, HTMLElement {

  /**
   * The Boolean return value of the media query.
   */
  readonly queryMatches: boolean|null|undefined;

  /**
   * The CSS media query to evaluate.
   */
  query: string|null|undefined;

  /**
   * If true, the query attribute is assumed to be a complete media query
   * string rather than a single media feature.
   */
  full: boolean|null|undefined;
  _boundMQHandler: (p0: MediaQueryList|null) => any;
  _mq: MediaQueryList|null;
  attached(): void;
  detached(): void;
  _add(): void;
  _remove(): void;
  queryChanged(): void;
  queryHandler(mq: any): void;
}

export {IronMediaQueryElement};

declare global {

  interface HTMLElementTagNameMap {
    "iron-media-query": IronMediaQueryElement;
  }
}