gecko-dev/dom/webidl/Grid.webidl
Brad Werth e0d3269112 Bug 1241932 - Expose decoded CSS grid track properties in a Chrome API. r=heycam, r=khuey
--HG--
extra : rebase_source : 0c2a49236a2c71233a1ce6a92e50663b8a9f6238
2016-07-06 11:45:18 -07:00

55 lines
1.2 KiB
Plaintext

/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at http://mozilla.org/MPL/2.0/.
*/
[ChromeOnly]
interface Grid
{
readonly attribute GridDimension rows;
readonly attribute GridDimension cols;
};
[ChromeOnly]
interface GridDimension
{
readonly attribute GridLines lines;
readonly attribute GridTracks tracks;
};
[ChromeOnly]
interface GridLines
{
readonly attribute unsigned long length;
getter GridLine? item(unsigned long index);
};
[ChromeOnly]
interface GridLine
{
readonly attribute double start;
readonly attribute double breadth;
readonly attribute unsigned long number;
[Cached, Pure]
readonly attribute sequence<DOMString> names;
};
[ChromeOnly]
interface GridTracks
{
readonly attribute unsigned long length;
getter GridTrack? item(unsigned long index);
};
enum GridTrackType { "explicit", "implicit" };
enum GridTrackState { "static", "repeat" };
[ChromeOnly]
interface GridTrack
{
readonly attribute double start;
readonly attribute double breadth;
readonly attribute GridTrackType type;
readonly attribute GridTrackState state;
};