summaryrefslogtreecommitdiffstats
path: root/devtools/shared/css
diff options
context:
space:
mode:
authorMatt A. Tobin <mattatobin@localhost.localdomain>2018-02-02 04:16:08 -0500
committerMatt A. Tobin <mattatobin@localhost.localdomain>2018-02-02 04:16:08 -0500
commit5f8de423f190bbb79a62f804151bc24824fa32d8 (patch)
tree10027f336435511475e392454359edea8e25895d /devtools/shared/css
parent49ee0794b5d912db1f95dce6eb52d781dc210db5 (diff)
downloadUXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.gz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.lz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.xz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.zip
Add m-esr52 at 52.6.0
Diffstat (limited to 'devtools/shared/css')
-rw-r--r--devtools/shared/css/color-db.js162
-rw-r--r--devtools/shared/css/color.js1117
-rw-r--r--devtools/shared/css/generated/generate-properties-db.js55
-rw-r--r--devtools/shared/css/generated/mach_commands.py91
-rw-r--r--devtools/shared/css/generated/moz.build9
-rw-r--r--devtools/shared/css/generated/properties-db.js9367
-rw-r--r--devtools/shared/css/generated/properties-db.js.in20
-rw-r--r--devtools/shared/css/lexer.js1240
-rw-r--r--devtools/shared/css/moz.build17
-rw-r--r--devtools/shared/css/parsing-utils.js1171
-rw-r--r--devtools/shared/css/properties-db.js100
11 files changed, 13349 insertions, 0 deletions
diff --git a/devtools/shared/css/color-db.js b/devtools/shared/css/color-db.js
new file mode 100644
index 000000000..5cbf508f1
--- /dev/null
+++ b/devtools/shared/css/color-db.js
@@ -0,0 +1,162 @@
+/* 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/. */
+
+"use strict";
+
+// /!\ Auto-generated from nsColorNameList.h.
+// This should be kept in sync with that list.
+// test_cssColorDatabase.js tries to enforce this.
+
+const cssColors = {
+ aliceblue: [240, 248, 255, 1],
+ antiquewhite: [250, 235, 215, 1],
+ aqua: [0, 255, 255, 1],
+ aquamarine: [127, 255, 212, 1],
+ azure: [240, 255, 255, 1],
+ beige: [245, 245, 220, 1],
+ bisque: [255, 228, 196, 1],
+ black: [0, 0, 0, 1],
+ blanchedalmond: [255, 235, 205, 1],
+ blue: [0, 0, 255, 1],
+ blueviolet: [138, 43, 226, 1],
+ brown: [165, 42, 42, 1],
+ burlywood: [222, 184, 135, 1],
+ cadetblue: [95, 158, 160, 1],
+ chartreuse: [127, 255, 0, 1],
+ chocolate: [210, 105, 30, 1],
+ coral: [255, 127, 80, 1],
+ cornflowerblue: [100, 149, 237, 1],
+ cornsilk: [255, 248, 220, 1],
+ crimson: [220, 20, 60, 1],
+ cyan: [0, 255, 255, 1],
+ darkblue: [0, 0, 139, 1],
+ darkcyan: [0, 139, 139, 1],
+ darkgoldenrod: [184, 134, 11, 1],
+ darkgray: [169, 169, 169, 1],
+ darkgreen: [0, 100, 0, 1],
+ darkgrey: [169, 169, 169, 1],
+ darkkhaki: [189, 183, 107, 1],
+ darkmagenta: [139, 0, 139, 1],
+ darkolivegreen: [85, 107, 47, 1],
+ darkorange: [255, 140, 0, 1],
+ darkorchid: [153, 50, 204, 1],
+ darkred: [139, 0, 0, 1],
+ darksalmon: [233, 150, 122, 1],
+ darkseagreen: [143, 188, 143, 1],
+ darkslateblue: [72, 61, 139, 1],
+ darkslategray: [47, 79, 79, 1],
+ darkslategrey: [47, 79, 79, 1],
+ darkturquoise: [0, 206, 209, 1],
+ darkviolet: [148, 0, 211, 1],
+ deeppink: [255, 20, 147, 1],
+ deepskyblue: [0, 191, 255, 1],
+ dimgray: [105, 105, 105, 1],
+ dimgrey: [105, 105, 105, 1],
+ dodgerblue: [30, 144, 255, 1],
+ firebrick: [178, 34, 34, 1],
+ floralwhite: [255, 250, 240, 1],
+ forestgreen: [34, 139, 34, 1],
+ fuchsia: [255, 0, 255, 1],
+ gainsboro: [220, 220, 220, 1],
+ ghostwhite: [248, 248, 255, 1],
+ gold: [255, 215, 0, 1],
+ goldenrod: [218, 165, 32, 1],
+ gray: [128, 128, 128, 1],
+ grey: [128, 128, 128, 1],
+ green: [0, 128, 0, 1],
+ greenyellow: [173, 255, 47, 1],
+ honeydew: [240, 255, 240, 1],
+ hotpink: [255, 105, 180, 1],
+ indianred: [205, 92, 92, 1],
+ indigo: [75, 0, 130, 1],
+ ivory: [255, 255, 240, 1],
+ khaki: [240, 230, 140, 1],
+ lavender: [230, 230, 250, 1],
+ lavenderblush: [255, 240, 245, 1],
+ lawngreen: [124, 252, 0, 1],
+ lemonchiffon: [255, 250, 205, 1],
+ lightblue: [173, 216, 230, 1],
+ lightcoral: [240, 128, 128, 1],
+ lightcyan: [224, 255, 255, 1],
+ lightgoldenrodyellow: [250, 250, 210, 1],
+ lightgray: [211, 211, 211, 1],
+ lightgreen: [144, 238, 144, 1],
+ lightgrey: [211, 211, 211, 1],
+ lightpink: [255, 182, 193, 1],
+ lightsalmon: [255, 160, 122, 1],
+ lightseagreen: [32, 178, 170, 1],
+ lightskyblue: [135, 206, 250, 1],
+ lightslategray: [119, 136, 153, 1],
+ lightslategrey: [119, 136, 153, 1],
+ lightsteelblue: [176, 196, 222, 1],
+ lightyellow: [255, 255, 224, 1],
+ lime: [0, 255, 0, 1],
+ limegreen: [50, 205, 50, 1],
+ linen: [250, 240, 230, 1],
+ magenta: [255, 0, 255, 1],
+ maroon: [128, 0, 0, 1],
+ mediumaquamarine: [102, 205, 170, 1],
+ mediumblue: [0, 0, 205, 1],
+ mediumorchid: [186, 85, 211, 1],
+ mediumpurple: [147, 112, 219, 1],
+ mediumseagreen: [60, 179, 113, 1],
+ mediumslateblue: [123, 104, 238, 1],
+ mediumspringgreen: [0, 250, 154, 1],
+ mediumturquoise: [72, 209, 204, 1],
+ mediumvioletred: [199, 21, 133, 1],
+ midnightblue: [25, 25, 112, 1],
+ mintcream: [245, 255, 250, 1],
+ mistyrose: [255, 228, 225, 1],
+ moccasin: [255, 228, 181, 1],
+ navajowhite: [255, 222, 173, 1],
+ navy: [0, 0, 128, 1],
+ oldlace: [253, 245, 230, 1],
+ olive: [128, 128, 0, 1],
+ olivedrab: [107, 142, 35, 1],
+ orange: [255, 165, 0, 1],
+ orangered: [255, 69, 0, 1],
+ orchid: [218, 112, 214, 1],
+ palegoldenrod: [238, 232, 170, 1],
+ palegreen: [152, 251, 152, 1],
+ paleturquoise: [175, 238, 238, 1],
+ palevioletred: [219, 112, 147, 1],
+ papayawhip: [255, 239, 213, 1],
+ peachpuff: [255, 218, 185, 1],
+ peru: [205, 133, 63, 1],
+ pink: [255, 192, 203, 1],
+ plum: [221, 160, 221, 1],
+ powderblue: [176, 224, 230, 1],
+ purple: [128, 0, 128, 1],
+ rebeccapurple: [102, 51, 153, 1],
+ red: [255, 0, 0, 1],
+ rosybrown: [188, 143, 143, 1],
+ royalblue: [65, 105, 225, 1],
+ saddlebrown: [139, 69, 19, 1],
+ salmon: [250, 128, 114, 1],
+ sandybrown: [244, 164, 96, 1],
+ seagreen: [46, 139, 87, 1],
+ seashell: [255, 245, 238, 1],
+ sienna: [160, 82, 45, 1],
+ silver: [192, 192, 192, 1],
+ skyblue: [135, 206, 235, 1],
+ slateblue: [106, 90, 205, 1],
+ slategray: [112, 128, 144, 1],
+ slategrey: [112, 128, 144, 1],
+ snow: [255, 250, 250, 1],
+ springgreen: [0, 255, 127, 1],
+ steelblue: [70, 130, 180, 1],
+ tan: [210, 180, 140, 1],
+ teal: [0, 128, 128, 1],
+ thistle: [216, 191, 216, 1],
+ tomato: [255, 99, 71, 1],
+ turquoise: [64, 224, 208, 1],
+ violet: [238, 130, 238, 1],
+ wheat: [245, 222, 179, 1],
+ white: [255, 255, 255, 1],
+ whitesmoke: [245, 245, 245, 1],
+ yellow: [255, 255, 0, 1],
+ yellowgreen: [154, 205, 50, 1],
+};
+
+exports.cssColors = cssColors;
diff --git a/devtools/shared/css/color.js b/devtools/shared/css/color.js
new file mode 100644
index 000000000..b354043d7
--- /dev/null
+++ b/devtools/shared/css/color.js
@@ -0,0 +1,1117 @@
+/* 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/. */
+
+"use strict";
+
+const Services = require("Services");
+
+const {CSS_ANGLEUNIT} = require("devtools/shared/css/properties-db");
+const {getAngleValueInDegrees} = require("devtools/shared/css/parsing-utils");
+
+const {getCSSLexer} = require("devtools/shared/css/lexer");
+const {cssColors} = require("devtools/shared/css/color-db");
+
+const COLOR_UNIT_PREF = "devtools.defaultColorUnit";
+
+const SPECIALVALUES = new Set([
+ "currentcolor",
+ "initial",
+ "inherit",
+ "transparent",
+ "unset"
+]);
+
+/**
+ * This module is used to convert between various color types.
+ *
+ * Usage:
+ * let {colorUtils} = require("devtools/shared/css/color");
+ * let color = new colorUtils.CssColor("red");
+ *
+ * color.authored === "red"
+ * color.hasAlpha === false
+ * color.valid === true
+ * color.transparent === false // transparent has a special status.
+ * color.name === "red" // returns hex when no name available.
+ * color.hex === "#f00" // returns shortHex when available else returns
+ * longHex. If alpha channel is present then we
+ * return this.alphaHex if available,
+ * or this.longAlphaHex if not.
+ * color.alphaHex === "#f00f" // returns short alpha hex when available
+ * else returns longAlphaHex.
+ * color.longHex === "#ff0000" // If alpha channel is present then we return
+ * this.longAlphaHex.
+ * color.longAlphaHex === "#ff0000ff"
+ * color.rgb === "rgb(255, 0, 0)" // If alpha channel is present
+ * // then we return this.rgba.
+ * color.rgba === "rgba(255, 0, 0, 1)"
+ * color.hsl === "hsl(0, 100%, 50%)"
+ * color.hsla === "hsla(0, 100%, 50%, 1)" // If alpha channel is present
+ * then we return this.rgba.
+ *
+ * color.toString() === "#f00"; // Outputs the color type determined in the
+ * COLOR_UNIT_PREF constant (above).
+ * // Color objects can be reused
+ * color.newColor("green") === "#0f0"; // true
+ *
+ * Valid values for COLOR_UNIT_PREF are contained in CssColor.COLORUNIT.
+ */
+
+function CssColor(colorValue) {
+ this.newColor(colorValue);
+}
+
+module.exports.colorUtils = {
+ CssColor: CssColor,
+ rgbToHsl: rgbToHsl,
+ setAlpha: setAlpha,
+ classifyColor: classifyColor,
+ rgbToColorName: rgbToColorName,
+ colorToRGBA: colorToRGBA,
+ isValidCSSColor: isValidCSSColor,
+};
+
+/**
+ * Values used in COLOR_UNIT_PREF
+ */
+CssColor.COLORUNIT = {
+ "authored": "authored",
+ "hex": "hex",
+ "name": "name",
+ "rgb": "rgb",
+ "hsl": "hsl"
+};
+
+CssColor.prototype = {
+ _colorUnit: null,
+ _colorUnitUppercase: false,
+
+ // The value as-authored.
+ authored: null,
+ // A lower-cased copy of |authored|.
+ lowerCased: null,
+
+ _setColorUnitUppercase: function (color) {
+ // Specifically exclude the case where the color is
+ // case-insensitive. This makes it so that "#000" isn't
+ // considered "upper case" for the purposes of color cycling.
+ this._colorUnitUppercase = (color === color.toUpperCase()) &&
+ (color !== color.toLowerCase());
+ },
+
+ get colorUnit() {
+ if (this._colorUnit === null) {
+ let defaultUnit = Services.prefs.getCharPref(COLOR_UNIT_PREF);
+ this._colorUnit = CssColor.COLORUNIT[defaultUnit];
+ this._setColorUnitUppercase(this.authored);
+ }
+ return this._colorUnit;
+ },
+
+ set colorUnit(unit) {
+ this._colorUnit = unit;
+ },
+
+ /**
+ * If the current color unit pref is "authored", then set the
+ * default color unit from the given color. Otherwise, leave the
+ * color unit untouched.
+ *
+ * @param {String} color The color to use
+ */
+ setAuthoredUnitFromColor: function (color) {
+ if (Services.prefs.getCharPref(COLOR_UNIT_PREF) ===
+ CssColor.COLORUNIT.authored) {
+ this._colorUnit = classifyColor(color);
+ this._setColorUnitUppercase(color);
+ }
+ },
+
+ get hasAlpha() {
+ if (!this.valid) {
+ return false;
+ }
+ return this._getRGBATuple().a !== 1;
+ },
+
+ get valid() {
+ return isValidCSSColor(this.authored);
+ },
+
+ /**
+ * Return true for all transparent values e.g. rgba(0, 0, 0, 0).
+ */
+ get transparent() {
+ try {
+ let tuple = this._getRGBATuple();
+ return !(tuple.r || tuple.g || tuple.b || tuple.a);
+ } catch (e) {
+ return false;
+ }
+ },
+
+ get specialValue() {
+ return SPECIALVALUES.has(this.lowerCased) ? this.authored : null;
+ },
+
+ get name() {
+ let invalidOrSpecialValue = this._getInvalidOrSpecialValue();
+ if (invalidOrSpecialValue !== false) {
+ return invalidOrSpecialValue;
+ }
+
+ try {
+ let tuple = this._getRGBATuple();
+
+ if (tuple.a !== 1) {
+ return this.hex;
+ }
+ let {r, g, b} = tuple;
+ return rgbToColorName(r, g, b);
+ } catch (e) {
+ return this.hex;
+ }
+ },
+
+ get hex() {
+ let invalidOrSpecialValue = this._getInvalidOrSpecialValue();
+ if (invalidOrSpecialValue !== false) {
+ return invalidOrSpecialValue;
+ }
+ if (this.hasAlpha) {
+ return this.alphaHex;
+ }
+
+ let hex = this.longHex;
+ if (hex.charAt(1) == hex.charAt(2) &&
+ hex.charAt(3) == hex.charAt(4) &&
+ hex.charAt(5) == hex.charAt(6)) {
+ hex = "#" + hex.charAt(1) + hex.charAt(3) + hex.charAt(5);
+ }
+ return hex;
+ },
+
+ get alphaHex() {
+ let invalidOrSpecialValue = this._getInvalidOrSpecialValue();
+ if (invalidOrSpecialValue !== false) {
+ return invalidOrSpecialValue;
+ }
+
+ let alphaHex = this.longAlphaHex;
+ if (alphaHex.charAt(1) == alphaHex.charAt(2) &&
+ alphaHex.charAt(3) == alphaHex.charAt(4) &&
+ alphaHex.charAt(5) == alphaHex.charAt(6) &&
+ alphaHex.charAt(7) == alphaHex.charAt(8)) {
+ alphaHex = "#" + alphaHex.charAt(1) + alphaHex.charAt(3) +
+ alphaHex.charAt(5) + alphaHex.charAt(7);
+ }
+ return alphaHex;
+ },
+
+ get longHex() {
+ let invalidOrSpecialValue = this._getInvalidOrSpecialValue();
+ if (invalidOrSpecialValue !== false) {
+ return invalidOrSpecialValue;
+ }
+ if (this.hasAlpha) {
+ return this.longAlphaHex;
+ }
+
+ let tuple = this._getRGBATuple();
+ return "#" + ((1 << 24) + (tuple.r << 16) + (tuple.g << 8) +
+ (tuple.b << 0)).toString(16).substr(-6);
+ },
+
+ get longAlphaHex() {
+ let invalidOrSpecialValue = this._getInvalidOrSpecialValue();
+ if (invalidOrSpecialValue !== false) {
+ return invalidOrSpecialValue;
+ }
+
+ let tuple = this._getRGBATuple();
+ return "#" + ((1 << 24) + (tuple.r << 16) + (tuple.g << 8) +
+ (tuple.b << 0)).toString(16).substr(-6) +
+ Math.round(tuple.a * 255).toString(16).padEnd(2, "0");
+ },
+
+ get rgb() {
+ let invalidOrSpecialValue = this._getInvalidOrSpecialValue();
+ if (invalidOrSpecialValue !== false) {
+ return invalidOrSpecialValue;
+ }
+ if (!this.hasAlpha) {
+ if (this.lowerCased.startsWith("rgb(")) {
+ // The color is valid and begins with rgb(.
+ return this.authored;
+ }
+ let tuple = this._getRGBATuple();
+ return "rgb(" + tuple.r + ", " + tuple.g + ", " + tuple.b + ")";
+ }
+ return this.rgba;
+ },
+
+ get rgba() {
+ let invalidOrSpecialValue = this._getInvalidOrSpecialValue();
+ if (invalidOrSpecialValue !== false) {
+ return invalidOrSpecialValue;
+ }
+ if (this.lowerCased.startsWith("rgba(")) {
+ // The color is valid and begins with rgba(.
+ return this.authored;
+ }
+ let components = this._getRGBATuple();
+ return "rgba(" + components.r + ", " +
+ components.g + ", " +
+ components.b + ", " +
+ components.a + ")";
+ },
+
+ get hsl() {
+ let invalidOrSpecialValue = this._getInvalidOrSpecialValue();
+ if (invalidOrSpecialValue !== false) {
+ return invalidOrSpecialValue;
+ }
+ if (this.lowerCased.startsWith("hsl(")) {
+ // The color is valid and begins with hsl(.
+ return this.authored;
+ }
+ if (this.hasAlpha) {
+ return this.hsla;
+ }
+ return this._hsl();
+ },
+
+ get hsla() {
+ let invalidOrSpecialValue = this._getInvalidOrSpecialValue();
+ if (invalidOrSpecialValue !== false) {
+ return invalidOrSpecialValue;
+ }
+ if (this.lowerCased.startsWith("hsla(")) {
+ // The color is valid and begins with hsla(.
+ return this.authored;
+ }
+ if (this.hasAlpha) {
+ let a = this._getRGBATuple().a;
+ return this._hsl(a);
+ }
+ return this._hsl(1);
+ },
+
+ /**
+ * Check whether the current color value is in the special list e.g.
+ * transparent or invalid.
+ *
+ * @return {String|Boolean}
+ * - If the current color is a special value e.g. "transparent" then
+ * return the color.
+ * - If the color is invalid return an empty string.
+ * - If the color is a regular color e.g. #F06 so we return false
+ * to indicate that the color is neither invalid or special.
+ */
+ _getInvalidOrSpecialValue: function () {
+ if (this.specialValue) {
+ return this.specialValue;
+ }
+ if (!this.valid) {
+ return "";
+ }
+ return false;
+ },
+
+ /**
+ * Change color
+ *
+ * @param {String} color
+ * Any valid color string
+ */
+ newColor: function (color) {
+ // Store a lower-cased version of the color to help with format
+ // testing. The original text is kept as well so it can be
+ // returned when needed.
+ this.lowerCased = color.toLowerCase();
+ this.authored = color;
+ this._setColorUnitUppercase(color);
+ return this;
+ },
+
+ nextColorUnit: function () {
+ // Reorder the formats array to have the current format at the
+ // front so we can cycle through.
+ let formats = ["hex", "hsl", "rgb", "name"];
+ let currentFormat = classifyColor(this.toString());
+ let putOnEnd = formats.splice(0, formats.indexOf(currentFormat));
+ formats = formats.concat(putOnEnd);
+ let currentDisplayedColor = this[formats[0]];
+
+ for (let format of formats) {
+ if (this[format].toLowerCase() !== currentDisplayedColor.toLowerCase()) {
+ this.colorUnit = CssColor.COLORUNIT[format];
+ break;
+ }
+ }
+
+ return this.toString();
+ },
+
+ /**
+ * Return a string representing a color of type defined in COLOR_UNIT_PREF.
+ */
+ toString: function () {
+ let color;
+
+ switch (this.colorUnit) {
+ case CssColor.COLORUNIT.authored:
+ color = this.authored;
+ break;
+ case CssColor.COLORUNIT.hex:
+ color = this.hex;
+ break;
+ case CssColor.COLORUNIT.hsl:
+ color = this.hsl;
+ break;
+ case CssColor.COLORUNIT.name:
+ color = this.name;
+ break;
+ case CssColor.COLORUNIT.rgb:
+ color = this.rgb;
+ break;
+ default:
+ color = this.rgb;
+ }
+
+ if (this._colorUnitUppercase &&
+ this.colorUnit != CssColor.COLORUNIT.authored) {
+ color = color.toUpperCase();
+ }
+
+ return color;
+ },
+
+ /**
+ * Returns a RGBA 4-Tuple representation of a color or transparent as
+ * appropriate.
+ */
+ _getRGBATuple: function () {
+ let tuple = colorToRGBA(this.authored);
+
+ tuple.a = parseFloat(tuple.a.toFixed(1));
+
+ return tuple;
+ },
+
+ _hsl: function (maybeAlpha) {
+ if (this.lowerCased.startsWith("hsl(") && maybeAlpha === undefined) {
+ // We can use it as-is.
+ return this.authored;
+ }
+
+ let {r, g, b} = this._getRGBATuple();
+ let [h, s, l] = rgbToHsl([r, g, b]);
+ if (maybeAlpha !== undefined) {
+ return "hsla(" + h + ", " + s + "%, " + l + "%, " + maybeAlpha + ")";
+ }
+ return "hsl(" + h + ", " + s + "%, " + l + "%)";
+ },
+
+ /**
+ * This method allows comparison of CssColor objects using ===.
+ */
+ valueOf: function () {
+ return this.rgba;
+ },
+};
+
+/**
+ * Convert rgb value to hsl
+ *
+ * @param {array} rgb
+ * Array of rgb values
+ * @return {array}
+ * Array of hsl values.
+ */
+function rgbToHsl([r, g, b]) {
+ r = r / 255;
+ g = g / 255;
+ b = b / 255;
+
+ let max = Math.max(r, g, b);
+ let min = Math.min(r, g, b);
+ let h;
+ let s;
+ let l = (max + min) / 2;
+
+ if (max == min) {
+ h = s = 0;
+ } else {
+ let d = max - min;
+ s = l > 0.5 ? d / (2 - max - min) : d / (max + min);
+
+ switch (max) {
+ case r:
+ h = ((g - b) / d) % 6;
+ break;
+ case g:
+ h = (b - r) / d + 2;
+ break;
+ case b:
+ h = (r - g) / d + 4;
+ break;
+ }
+ h *= 60;
+ if (h < 0) {
+ h += 360;
+ }
+ }
+
+ return [roundTo(h, 1), roundTo(s * 100, 1), roundTo(l * 100, 1)];
+}
+
+function roundTo(number, digits) {
+ const multiplier = Math.pow(10, digits);
+ return Math.round(number * multiplier) / multiplier;
+}
+
+/**
+ * Takes a color value of any type (hex, hsl, hsla, rgb, rgba)
+ * and an alpha value to generate an rgba string with the correct
+ * alpha value.
+ *
+ * @param {String} colorValue
+ * Color in the form of hex, hsl, hsla, rgb, rgba.
+ * @param {Number} alpha
+ * Alpha value for the color, between 0 and 1.
+ * @return {String}
+ * Converted color with `alpha` value in rgba form.
+ */
+function setAlpha(colorValue, alpha) {
+ let color = new CssColor(colorValue);
+
+ // Throw if the color supplied is not valid.
+ if (!color.valid) {
+ throw new Error("Invalid color.");
+ }
+
+ // If an invalid alpha valid, just set to 1.
+ if (!(alpha >= 0 && alpha <= 1)) {
+ alpha = 1;
+ }
+
+ let { r, g, b } = color._getRGBATuple();
+ return "rgba(" + r + ", " + g + ", " + b + ", " + alpha + ")";
+}
+
+/**
+ * Given a color, classify its type as one of the possible color
+ * units, as known by |CssColor.colorUnit|.
+ *
+ * @param {String} value
+ * The color, in any form accepted by CSS.
+ * @return {String}
+ * The color classification, one of "rgb", "hsl", "hex", or "name".
+ */
+function classifyColor(value) {
+ value = value.toLowerCase();
+ if (value.startsWith("rgb(") || value.startsWith("rgba(")) {
+ return CssColor.COLORUNIT.rgb;
+ } else if (value.startsWith("hsl(") || value.startsWith("hsla(")) {
+ return CssColor.COLORUNIT.hsl;
+ } else if (/^#[0-9a-f]+$/.exec(value)) {
+ return CssColor.COLORUNIT.hex;
+ }
+ return CssColor.COLORUNIT.name;
+}
+
+// This holds a map from colors back to color names for use by
+// rgbToColorName.
+var cssRGBMap;
+
+/**
+ * Given a color, return its name, if it has one. Throws an exception
+ * if the color does not have a name.
+ *
+ * @param {Number} r, g, b The color components.
+ * @return {String} the name of the color
+ */
+function rgbToColorName(r, g, b) {
+ if (!cssRGBMap) {
+ cssRGBMap = {};
+ for (let name in cssColors) {
+ let key = JSON.stringify(cssColors[name]);
+ if (!(key in cssRGBMap)) {
+ cssRGBMap[key] = name;
+ }
+ }
+ }
+ let value = cssRGBMap[JSON.stringify([r, g, b, 1])];
+ if (!value) {
+ throw new Error("no such color");
+ }
+ return value;
+}
+
+// Translated from nsColor.cpp.
+function _hslValue(m1, m2, h) {
+ if (h < 0.0) {
+ h += 1.0;
+ }
+ if (h > 1.0) {
+ h -= 1.0;
+ }
+ if (h < 1.0 / 6.0) {
+ return m1 + (m2 - m1) * h * 6.0;
+ }
+ if (h < 1.0 / 2.0) {
+ return m2;
+ }
+ if (h < 2.0 / 3.0) {
+ return m1 + (m2 - m1) * (2.0 / 3.0 - h) * 6.0;
+ }
+ return m1;
+}
+
+// Translated from nsColor.cpp. All three values are expected to be
+// in the range 0-1.
+function hslToRGB([h, s, l]) {
+ let r, g, b;
+ let m1, m2;
+ if (l <= 0.5) {
+ m2 = l * (s + 1);
+ } else {
+ m2 = l + s - l * s;
+ }
+ m1 = l * 2 - m2;
+ r = Math.round(255 * _hslValue(m1, m2, h + 1.0 / 3.0));
+ g = Math.round(255 * _hslValue(m1, m2, h));
+ b = Math.round(255 * _hslValue(m1, m2, h - 1.0 / 3.0));
+ return [r, g, b];
+}
+
+/**
+ * A helper function to convert a hex string like "F0C" or "F0C8" to a color.
+ *
+ * @param {String} name the color string
+ * @return {Object} an object of the form {r, g, b, a}; or null if the
+ * name was not a valid color
+ */
+function hexToRGBA(name) {
+ let r, g, b, a = 1;
+
+ if (name.length === 3) {
+ // short hex string (e.g. F0C)
+ r = parseInt(name.charAt(0) + name.charAt(0), 16);
+ g = parseInt(name.charAt(1) + name.charAt(1), 16);
+ b = parseInt(name.charAt(2) + name.charAt(2), 16);
+ } else if (name.length === 4) {
+ // short alpha hex string (e.g. F0CA)
+ r = parseInt(name.charAt(0) + name.charAt(0), 16);
+ g = parseInt(name.charAt(1) + name.charAt(1), 16);
+ b = parseInt(name.charAt(2) + name.charAt(2), 16);
+ a = parseInt(name.charAt(3) + name.charAt(3), 16) / 255;
+ } else if (name.length === 6) {
+ // hex string (e.g. FD01CD)
+ r = parseInt(name.charAt(0) + name.charAt(1), 16);
+ g = parseInt(name.charAt(2) + name.charAt(3), 16);
+ b = parseInt(name.charAt(4) + name.charAt(5), 16);
+ } else if (name.length === 8) {
+ // alpha hex string (e.g. FD01CDAB)
+ r = parseInt(name.charAt(0) + name.charAt(1), 16);
+ g = parseInt(name.charAt(2) + name.charAt(3), 16);
+ b = parseInt(name.charAt(4) + name.charAt(5), 16);
+ a = parseInt(name.charAt(6) + name.charAt(7), 16) / 255;
+ } else {
+ return null;
+ }
+ a = Math.round(a * 10) / 10;
+ return {r, g, b, a};
+}
+
+/**
+ * A helper function to clamp a value.
+ *
+ * @param {Number} value The value to clamp
+ * @param {Number} min The minimum value
+ * @param {Number} max The maximum value
+ * @return {Number} A value between min and max
+ */
+function clamp(value, min, max) {
+ if (value < min) {
+ value = min;
+ }
+ if (value > max) {
+ value = max;
+ }
+ return value;
+}
+
+/**
+ * A helper function to get a token from a lexer, skipping comments
+ * and whitespace.
+ *
+ * @param {CSSLexer} lexer The lexer
+ * @return {CSSToken} The next non-whitespace, non-comment token; or
+ * null at EOF.
+ */
+function getToken(lexer) {
+ if (lexer._hasPushBackToken) {
+ lexer._hasPushBackToken = false;
+ return lexer._currentToken;
+ }
+
+ while (true) {
+ let token = lexer.nextToken();
+ if (!token || (token.tokenType !== "comment" &&
+ token.tokenType !== "whitespace")) {
+ lexer._currentToken = token;
+ return token;
+ }
+ }
+}
+
+/**
+ * A helper function to put a token back to lexer for the next call of
+ * getToken().
+ *
+ * @param {CSSLexer} lexer The lexer
+ */
+function unGetToken(lexer) {
+ if (lexer._hasPushBackToken) {
+ throw new Error("Double pushback.");
+ }
+ lexer._hasPushBackToken = true;
+}
+
+/**
+ * A helper function that checks if the next token matches symbol.
+ * If so, reads the token and returns true. If not, pushes the
+ * token back and returns false.
+ *
+ * @param {CSSLexer} lexer The lexer.
+ * @param {String} symbol The symbol.
+ * @return {Boolean} The expect symbol is parsed or not.
+ */
+function expectSymbol(lexer, symbol) {
+ let token = getToken(lexer);
+ if (!token) {
+ return false;
+ }
+
+ if (token.tokenType !== "symbol" || token.text !== symbol) {
+ unGetToken(lexer);
+ return false;
+ }
+
+ return true;
+}
+
+const COLOR_COMPONENT_TYPE = {
+ "integer": "integer",
+ "number": "number",
+ "percentage": "percentage",
+};
+
+/**
+ * Parse a <integer> or a <number> or a <percentage> color component. If
+ * |separator| is provided (not an empty string ""), this function will also
+ * attempt to parse that character after parsing the color component. The range
+ * of output component value is [0, 1] if the component type is percentage.
+ * Otherwise, the range is [0, 255].
+ *
+ * @param {CSSLexer} lexer The lexer.
+ * @param {COLOR_COMPONENT_TYPE} type The color component type.
+ * @param {String} separator The separator.
+ * @param {Array} colorArray [out] The parsed color component will push into this array.
+ * @return {Boolean} Return false on error.
+ */
+function parseColorComponent(lexer, type, separator, colorArray) {
+ let token = getToken(lexer);
+
+ if (!token) {
+ return false;
+ }
+
+ switch (type) {
+ case COLOR_COMPONENT_TYPE.integer:
+ if (token.tokenType !== "number" || !token.isInteger) {
+ return false;
+ }
+ break;
+ case COLOR_COMPONENT_TYPE.number:
+ if (token.tokenType !== "number") {
+ return false;
+ }
+ break;
+ case COLOR_COMPONENT_TYPE.percentage:
+ if (token.tokenType !== "percentage") {
+ return false;
+ }
+ break;
+ default:
+ throw new Error("Invalid color component type.");
+ }
+
+ let colorComponent = 0;
+ if (type === COLOR_COMPONENT_TYPE.percentage) {
+ colorComponent = clamp(token.number, 0, 1);
+ } else {
+ colorComponent = clamp(token.number, 0, 255);
+ }
+
+ if (separator !== "" && !expectSymbol(lexer, separator)) {
+ return false;
+ }
+
+ colorArray.push(colorComponent);
+
+ return true;
+}
+
+/**
+ * Parse an optional [ separator <alpha-value> ] expression, followed by a
+ * close-parenthesis, at the end of a css color function (e.g. rgba() or hsla()).
+ * If this function simply encounters a close-parenthesis (without the
+ * [ separator <alpha-value> ]), it will still succeed. Then put a fully-opaque
+ * alpha value into the colorArray. The range of output alpha value is [0, 1].
+ *
+ * @param {CSSLexer} lexer The lexer
+ * @param {String} separator The separator.
+ * @param {Array} colorArray [out] The parsed color component will push into this array.
+ * @return {Boolean} Return false on error.
+ */
+function parseColorOpacityAndCloseParen(lexer, separator, colorArray) {
+ // The optional [separator <alpha-value>] was omitted, so set the opacity
+ // to a fully-opaque value '1.0' and return success.
+ if (expectSymbol(lexer, ")")) {
+ colorArray.push(1);
+ return true;
+ }
+
+ if (!expectSymbol(lexer, separator)) {
+ return false;
+ }
+
+ let token = getToken(lexer);
+ if (!token) {
+ return false;
+ }
+
+ // <number> or <percentage>
+ if (token.tokenType !== "number" && token.tokenType !== "percentage") {
+ return false;
+ }
+
+ if (!expectSymbol(lexer, ")")) {
+ return false;
+ }
+
+ colorArray.push(clamp(token.number, 0, 1));
+
+ return true;
+}
+
+/**
+ * Parse a hue value.
+ * <hue> = <number> | <angle>
+ *
+ * @param {CSSLexer} lexer The lexer
+ * @param {Array} colorArray [out] The parsed color component will push into this array.
+ * @return {Boolean} Return false on error.
+ */
+function parseHue(lexer, colorArray) {
+ let token = getToken(lexer);
+
+ if (!token) {
+ return false;
+ }
+
+ let val = 0;
+ if (token.tokenType === "number") {
+ val = token.number;
+ } else if (token.tokenType === "dimension" && token.text in CSS_ANGLEUNIT) {
+ val = getAngleValueInDegrees(token.number, token.text);
+ } else {
+ return false;
+ }
+
+ val = val / 360.0;
+ colorArray.push(val - Math.floor(val));
+
+ return true;
+}
+
+/**
+ * A helper function to parse the color components of hsl()/hsla() function.
+ * hsl() and hsla() are now aliases.
+ *
+ * @param {CSSLexer} lexer The lexer
+ * @return {Array} An array of the form [r,g,b,a]; or null on error.
+ */
+function parseHsl(lexer) {
+ // comma-less expression:
+ // hsl() = hsl( <hue> <saturation> <lightness> [ / <alpha-value> ]? )
+ // the expression with comma:
+ // hsl() = hsl( <hue>, <saturation>, <lightness>, <alpha-value>? )
+ //
+ // <hue> = <number> | <angle>
+ // <alpha-value> = <number> | <percentage>
+
+ const commaSeparator = ",";
+ let hsl = [];
+ let a = [];
+
+ // Parse hue.
+ if (!parseHue(lexer, hsl)) {
+ return null;
+ }
+
+ // Look for a comma separator after "hue" component to determine if the
+ // expression is comma-less or not.
+ let hasComma = expectSymbol(lexer, commaSeparator);
+
+ // Parse saturation, lightness and opacity.
+ // The saturation and lightness are <percentage>, so reuse the <percentage>
+ // version of parseColorComponent function for them. No need to check the
+ // separator after 'lightness'. It will be checked in opacity value parsing.
+ let separatorBeforeAlpha = hasComma ? commaSeparator : "/";
+ if (parseColorComponent(lexer, COLOR_COMPONENT_TYPE.percentage,
+ hasComma ? commaSeparator : "", hsl) &&
+ parseColorComponent(lexer, COLOR_COMPONENT_TYPE.percentage, "", hsl) &&
+ parseColorOpacityAndCloseParen(lexer, separatorBeforeAlpha, a)) {
+ return [...hslToRGB(hsl), ...a];
+ }
+
+ return null;
+}
+
+/**
+ * A helper function to parse the color arguments of old style hsl()/hsla()
+ * function.
+ *
+ * @param {CSSLexer} lexer The lexer.
+ * @param {Boolean} hasAlpha The color function has alpha component or not.
+ * @return {Array} An array of the form [r,g,b,a]; or null on error.
+ */
+function parseOldStyleHsl(lexer, hasAlpha) {
+ // hsla() = hsla( <hue>, <saturation>, <lightness>, <alpha-value> )
+ // hsl() = hsl( <hue>, <saturation>, <lightness> )
+ //
+ // <hue> = <number>
+ // <alpha-value> = <number>
+
+ const commaSeparator = ",";
+ const closeParen = ")";
+ let hsl = [];
+ let a = [];
+
+ // Parse hue.
+ let token = getToken(lexer);
+ if (!token || token.tokenType !== "number") {
+ return null;
+ }
+ if (!expectSymbol(lexer, commaSeparator)) {
+ return null;
+ }
+ let val = token.number / 360.0;
+ hsl.push(val - Math.floor(val));
+
+ // Parse saturation, lightness and opacity.
+ // The saturation and lightness are <percentage>, so reuse the <percentage>
+ // version of parseColorComponent function for them. The opacity is <number>
+ if (hasAlpha) {
+ if (parseColorComponent(lexer, COLOR_COMPONENT_TYPE.percentage,
+ commaSeparator, hsl) &&
+ parseColorComponent(lexer, COLOR_COMPONENT_TYPE.percentage,
+ commaSeparator, hsl) &&
+ parseColorComponent(lexer, COLOR_COMPONENT_TYPE.number,
+ closeParen, a)) {
+ return [...hslToRGB(hsl), ...a];
+ }
+ } else if (parseColorComponent(lexer, COLOR_COMPONENT_TYPE.percentage,
+ commaSeparator, hsl) &&
+ parseColorComponent(lexer, COLOR_COMPONENT_TYPE.percentage,
+ closeParen, hsl)) {
+ return [...hslToRGB(hsl), 1];
+ }
+
+ return null;
+}
+
+/**
+ * A helper function to parse the color arguments of rgb()/rgba() function.
+ * rgb() and rgba() now are aliases.
+ *
+ * @param {CSSLexer} lexer The lexer.
+ * @return {Array} An array of the form [r,g,b,a]; or null on error.
+ */
+function parseRgb(lexer) {
+ // comma-less expression:
+ // rgb() = rgb( component{3} [ / <alpha-value> ]? )
+ // the expression with comma:
+ // rgb() = rgb( component#{3} , <alpha-value>? )
+ //
+ // component = <number> | <percentage>
+ // <alpa-value> = <number> | <percentage>
+
+ const commaSeparator = ",";
+ let rgba = [];
+
+ let token = getToken(lexer);
+ if (token.tokenType !== "percentage" && token.tokenType !== "number") {
+ return null;
+ }
+ unGetToken(lexer);
+ let type = (token.tokenType === "percentage") ?
+ COLOR_COMPONENT_TYPE.percentage :
+ COLOR_COMPONENT_TYPE.number;
+
+ // Parse R.
+ if (!parseColorComponent(lexer, type, "", rgba)) {
+ return null;
+ }
+ let hasComma = expectSymbol(lexer, commaSeparator);
+
+ // Parse G, B and A.
+ // No need to check the separator after 'B'. It will be checked in 'A' values
+ // parsing.
+ let separatorBeforeAlpha = hasComma ? commaSeparator : "/";
+ if (parseColorComponent(lexer, type, hasComma ? commaSeparator : "", rgba) &&
+ parseColorComponent(lexer, type, "", rgba) &&
+ parseColorOpacityAndCloseParen(lexer, separatorBeforeAlpha, rgba)) {
+ if (type === COLOR_COMPONENT_TYPE.percentage) {
+ rgba[0] = Math.round(255 * rgba[0]);
+ rgba[1] = Math.round(255 * rgba[1]);
+ rgba[2] = Math.round(255 * rgba[2]);
+ }
+ return rgba;
+ }
+
+ return null;
+}
+
+/**
+ * A helper function to parse the color arguments of old style rgb()/rgba()
+ * function.
+ *
+ * @param {CSSLexer} lexer The lexer.
+ * @param {Boolean} hasAlpha The color function has alpha component or not.
+ * @return {Array} An array of the form [r,g,b,a]; or null on error.
+ */
+function parseOldStyleRgb(lexer, hasAlpha) {
+ // rgba() = rgba( component#{3} , <alpha-value> )
+ // rgb() = rgb( component#{3} )
+ //
+ // component = <integer> | <percentage>
+ // <alpha-value> = <number>
+
+ const commaSeparator = ",";
+ const closeParen = ")";
+ let rgba = [];
+
+ let token = getToken(lexer);
+ if (token.tokenType !== "percentage" &&
+ (token.tokenType !== "number" || !token.isInteger)) {
+ return null;
+ }
+ unGetToken(lexer);
+ let type = (token.tokenType === "percentage") ?
+ COLOR_COMPONENT_TYPE.percentage :
+ COLOR_COMPONENT_TYPE.integer;
+
+ // Parse R. G, B and A.
+ if (hasAlpha) {
+ if (!parseColorComponent(lexer, type, commaSeparator, rgba) ||
+ !parseColorComponent(lexer, type, commaSeparator, rgba) ||
+ !parseColorComponent(lexer, type, commaSeparator, rgba) ||
+ !parseColorComponent(lexer, COLOR_COMPONENT_TYPE.number,
+ closeParen, rgba)) {
+ return null;
+ }
+ } else if (!parseColorComponent(lexer, type, commaSeparator, rgba) ||
+ !parseColorComponent(lexer, type, commaSeparator, rgba) ||
+ !parseColorComponent(lexer, type, closeParen, rgba)) {
+ return null;
+ }
+
+ if (type === COLOR_COMPONENT_TYPE.percentage) {
+ rgba[0] = Math.round(255 * rgba[0]);
+ rgba[1] = Math.round(255 * rgba[1]);
+ rgba[2] = Math.round(255 * rgba[2]);
+ }
+ if (!hasAlpha) {
+ rgba.push(1);
+ }
+
+ return rgba;
+}
+
+/**
+ * Convert a string representing a color to an object holding the
+ * color's components. Any valid CSS color form can be passed in.
+ *
+ * @param {String} name the color
+ * @param {Boolean} oldColorFunctionSyntax use old color function syntax or the
+ * css-color-4 syntax
+ * @return {Object} an object of the form {r, g, b, a}; or null if the
+ * name was not a valid color
+ */
+function colorToRGBA(name, oldColorFunctionSyntax = true) {
+ name = name.trim().toLowerCase();
+
+ if (name in cssColors) {
+ let result = cssColors[name];
+ return {r: result[0], g: result[1], b: result[2], a: result[3]};
+ } else if (name === "transparent") {
+ return {r: 0, g: 0, b: 0, a: 0};
+ } else if (name === "currentcolor") {
+ return {r: 0, g: 0, b: 0, a: 1};
+ }
+
+ let lexer = getCSSLexer(name);
+
+ let func = getToken(lexer);
+ if (!func) {
+ return null;
+ }
+
+ if (func.tokenType === "id" || func.tokenType === "hash") {
+ if (getToken(lexer) !== null) {
+ return null;
+ }
+ return hexToRGBA(func.text);
+ }
+
+ const expectedFunctions = ["rgba", "rgb", "hsla", "hsl"];
+ if (!func || func.tokenType !== "function" ||
+ !expectedFunctions.includes(func.text)) {
+ return null;
+ }
+
+ let hsl = func.text === "hsl" || func.text === "hsla";
+
+ let vals;
+ if (oldColorFunctionSyntax) {
+ let hasAlpha = (func.text === "rgba" || func.text === "hsla");
+ vals = hsl ? parseOldStyleHsl(lexer, hasAlpha) : parseOldStyleRgb(lexer, hasAlpha);
+ } else {
+ vals = hsl ? parseHsl(lexer) : parseRgb(lexer);
+ }
+
+ if (!vals) {
+ return null;
+ }
+ if (getToken(lexer) !== null) {
+ return null;
+ }
+
+ return {r: vals[0], g: vals[1], b: vals[2], a: vals[3]};
+}
+
+/**
+ * Check whether a string names a valid CSS color.
+ *
+ * @param {String} name The string to check
+ * @return {Boolean} True if the string is a CSS color name.
+ */
+function isValidCSSColor(name) {
+ return colorToRGBA(name) !== null;
+}
diff --git a/devtools/shared/css/generated/generate-properties-db.js b/devtools/shared/css/generated/generate-properties-db.js
new file mode 100644
index 000000000..ad8dfb0ab
--- /dev/null
+++ b/devtools/shared/css/generated/generate-properties-db.js
@@ -0,0 +1,55 @@
+/* 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/. */
+"use strict";
+
+/*
+ * This is an xpcshell script that runs to generate a static list of CSS properties
+ * as known by the platform. It is run from ./mach_commands.py by running
+ * `mach devtools-css-db`.
+ */
+var {require} = Components.utils.import("resource://devtools/shared/Loader.jsm", {});
+var {generateCssProperties} = require("devtools/server/actors/css-properties");
+
+// xpcshell can output extra information, so place some delimiter text between
+// the output of the css properties database.
+dump("DEVTOOLS_CSS_DB_DELIMITER");
+
+// Output JSON
+dump(JSON.stringify({
+ cssProperties: cssProperties(),
+ pseudoElements: pseudoElements()
+}));
+
+dump("DEVTOOLS_CSS_DB_DELIMITER");
+
+/*
+ * A list of CSS Properties and their various characteristics. This is used on the
+ * client-side when the CssPropertiesActor is not found, or when the client and server
+ * are the same version. A single property takes the form:
+ *
+ * "animation": {
+ * "isInherited": false,
+ * "supports": [ 7, 9, 10 ]
+ * }
+ */
+function cssProperties() {
+ const properties = generateCssProperties();
+ for (let key in properties) {
+ // Ignore OS-specific properties
+ if (key.indexOf("-moz-osx-") !== -1) {
+ properties[key] = undefined;
+ }
+ }
+ return properties;
+}
+
+/**
+ * The list of all CSS Pseudo Elements.
+ */
+function pseudoElements() {
+ const {classes: Cc, interfaces: Ci} = Components;
+ const domUtils = Cc["@mozilla.org/inspector/dom-utils;1"]
+ .getService(Ci.inIDOMUtils);
+ return domUtils.getCSSPseudoElementNames();
+}
diff --git a/devtools/shared/css/generated/mach_commands.py b/devtools/shared/css/generated/mach_commands.py
new file mode 100644
index 000000000..4d6016276
--- /dev/null
+++ b/devtools/shared/css/generated/mach_commands.py
@@ -0,0 +1,91 @@
+# 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/.
+
+"""
+This script implements the `mach devtools-css-db` command. It runs an xpcshell script
+that uses inIDOMUtils to query the CSS properties used by the browser. This information
+is used to generate the properties-db.js file.
+"""
+
+import json
+import os
+import sys
+import string
+import subprocess
+from mozbuild.base import (
+ MozbuildObject,
+ MachCommandBase,
+)
+from mach.decorators import (
+ CommandProvider,
+ Command,
+)
+
+def resolve_path(start, relativePath):
+ """Helper to resolve a path from a start, and a relative path"""
+ return os.path.normpath(os.path.join(start, relativePath))
+
+def stringify(obj):
+ """Helper to stringify to JSON"""
+ return json.dumps(obj, sort_keys=True, indent=2, separators=(',', ': '))
+
+@CommandProvider
+class MachCommands(MachCommandBase):
+ @Command(
+ 'devtools-css-db', category='post-build',
+ description='Rebuild the devtool\'s static css properties database.')
+ def generate_css_db(self):
+ """Generate the static css properties database for devtools and write it to file."""
+
+ print("Re-generating the css properties database...")
+ db = self.get_properties_db_from_xpcshell()
+
+ self.output_template({
+ 'cssProperties': stringify(db['cssProperties']),
+ 'pseudoElements': stringify(db['pseudoElements'])})
+
+ def get_properties_db_from_xpcshell(self):
+ """Generate the static css properties db for devtools from an xpcshell script."""
+ build = MozbuildObject.from_environment()
+
+ # Get the paths
+ script_path = resolve_path(self.topsrcdir,
+ 'devtools/shared/css/generated/generate-properties-db.js')
+ gre_path = resolve_path(self.topobjdir, 'dist/bin')
+ browser_path = resolve_path(self.topobjdir, 'dist/bin/browser')
+ xpcshell_path = build.get_binary_path(what='xpcshell')
+ print(browser_path)
+
+ sub_env = dict(os.environ)
+ if sys.platform.startswith('linux'):
+ sub_env["LD_LIBRARY_PATH"] = gre_path
+
+ # Run the xcpshell script, and set the appdir flag to the browser path so that
+ # we have the proper dependencies for requiring the loader.
+ contents = subprocess.check_output([xpcshell_path, '-g', gre_path,
+ '-a', browser_path, script_path],
+ env = sub_env)
+ # Extract just the output between the delimiters as the xpcshell output can
+ # have extra output that we don't want.
+ contents = contents.split('DEVTOOLS_CSS_DB_DELIMITER')[1]
+
+ return json.loads(contents)
+
+ def output_template(self, substitutions):
+ """Output a the properties-db.js from a template."""
+ js_template_path = resolve_path(self.topsrcdir,
+ 'devtools/shared/css/generated/properties-db.js.in')
+ destination_path = resolve_path(self.topsrcdir,
+ 'devtools/shared/css/generated/properties-db.js')
+
+ with open(js_template_path, 'rb') as handle:
+ js_template = handle.read()
+
+ preamble = '/* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT */\n\n'
+ contents = string.Template(js_template).substitute(substitutions)
+
+ with open(destination_path, 'wb') as destination:
+ destination.write(preamble + contents)
+
+ print('The database was successfully generated at ' + destination_path)
diff --git a/devtools/shared/css/generated/moz.build b/devtools/shared/css/generated/moz.build
new file mode 100644
index 000000000..7f01281db
--- /dev/null
+++ b/devtools/shared/css/generated/moz.build
@@ -0,0 +1,9 @@
+# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
+# vim: set filetype=python:
+# 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/.
+
+DevToolsModules(
+ 'properties-db.js',
+)
diff --git a/devtools/shared/css/generated/properties-db.js b/devtools/shared/css/generated/properties-db.js
new file mode 100644
index 000000000..83b3efafc
--- /dev/null
+++ b/devtools/shared/css/generated/properties-db.js
@@ -0,0 +1,9367 @@
+/* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT */
+
+/* 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/. */
+"use strict";
+
+/**
+ * This file is automatically generated by `mach devtools-css-db`. It contains
+ * a static list of CSS properties that can be computed by Gecko. The actual script
+ * to generate these files can be found at devtools/shared/css/generate-properties-db.js.
+ */
+
+/**
+ * A list of CSS Properties and their various characteristics.
+ */
+exports.CSS_PROPERTIES = {
+ "-moz-animation": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-duration",
+ "animation-timing-function",
+ "animation-delay",
+ "animation-direction",
+ "animation-fill-mode",
+ "animation-iteration-count",
+ "animation-play-state",
+ "animation-name"
+ ],
+ "supports": [
+ 7,
+ 9,
+ 10
+ ],
+ "values": [
+ "alternate",
+ "alternate-reverse",
+ "backwards",
+ "both",
+ "cubic-bezier",
+ "ease",
+ "ease-in",
+ "ease-in-out",
+ "ease-out",
+ "forwards",
+ "infinite",
+ "inherit",
+ "initial",
+ "linear",
+ "none",
+ "normal",
+ "paused",
+ "reverse",
+ "running",
+ "step-end",
+ "step-start",
+ "steps",
+ "unset"
+ ]
+ },
+ "-moz-animation-delay": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-delay"
+ ],
+ "supports": [
+ 9
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-animation-direction": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-direction"
+ ],
+ "supports": [],
+ "values": [
+ "alternate",
+ "alternate-reverse",
+ "inherit",
+ "initial",
+ "normal",
+ "reverse",
+ "unset"
+ ]
+ },
+ "-moz-animation-duration": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-duration"
+ ],
+ "supports": [
+ 9
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-animation-fill-mode": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-fill-mode"
+ ],
+ "supports": [],
+ "values": [
+ "backwards",
+ "both",
+ "forwards",
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "-moz-animation-iteration-count": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-iteration-count"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "infinite",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-animation-name": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-name"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "-moz-animation-play-state": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-play-state"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "paused",
+ "running",
+ "unset"
+ ]
+ },
+ "-moz-animation-timing-function": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-timing-function"
+ ],
+ "supports": [
+ 10
+ ],
+ "values": [
+ "cubic-bezier",
+ "ease",
+ "ease-in",
+ "ease-in-out",
+ "ease-out",
+ "inherit",
+ "initial",
+ "linear",
+ "step-end",
+ "step-start",
+ "steps",
+ "unset"
+ ]
+ },
+ "-moz-appearance": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-appearance"
+ ],
+ "supports": [],
+ "values": [
+ "-moz-gtk-info-bar",
+ "-moz-mac-disclosure-button-closed",
+ "-moz-mac-disclosure-button-open",
+ "-moz-mac-fullscreen-button",
+ "-moz-mac-help-button",
+ "-moz-mac-source-list",
+ "-moz-mac-vibrancy-dark",
+ "-moz-mac-vibrancy-light",
+ "-moz-win-borderless-glass",
+ "-moz-win-browsertabbar-toolbox",
+ "-moz-win-communications-toolbox",
+ "-moz-win-exclude-glass",
+ "-moz-win-glass",
+ "-moz-win-media-toolbox",
+ "-moz-window-button-box",
+ "-moz-window-button-box-maximized",
+ "-moz-window-button-close",
+ "-moz-window-button-maximize",
+ "-moz-window-button-minimize",
+ "-moz-window-button-restore",
+ "-moz-window-frame-bottom",
+ "-moz-window-frame-left",
+ "-moz-window-frame-right",
+ "-moz-window-titlebar",
+ "-moz-window-titlebar-maximized",
+ "button",
+ "button-arrow-down",
+ "button-arrow-next",
+ "button-arrow-previous",
+ "button-arrow-up",
+ "button-bevel",
+ "button-focus",
+ "caret",
+ "checkbox",
+ "checkbox-container",
+ "checkbox-label",
+ "checkmenuitem",
+ "dialog",
+ "dualbutton",
+ "groupbox",
+ "inherit",
+ "initial",
+ "listbox",
+ "listitem",
+ "menuarrow",
+ "menubar",
+ "menucheckbox",
+ "menuimage",
+ "menuitem",
+ "menuitemtext",
+ "menulist",
+ "menulist-button",
+ "menulist-text",
+ "menulist-textfield",
+ "menupopup",
+ "menuradio",
+ "menuseparator",
+ "meterbar",
+ "meterchunk",
+ "none",
+ "number-input",
+ "progressbar",
+ "progressbar-vertical",
+ "progresschunk",
+ "progresschunk-vertical",
+ "radio",
+ "radio-container",
+ "radio-label",
+ "radiomenuitem",
+ "range",
+ "range-thumb",
+ "resizer",
+ "resizerpanel",
+ "scale-horizontal",
+ "scale-vertical",
+ "scalethumb-horizontal",
+ "scalethumb-vertical",
+ "scalethumbend",
+ "scalethumbstart",
+ "scalethumbtick",
+ "scrollbar",
+ "scrollbar-horizontal",
+ "scrollbar-small",
+ "scrollbar-vertical",
+ "scrollbarbutton-down",
+ "scrollbarbutton-left",
+ "scrollbarbutton-right",
+ "scrollbarbutton-up",
+ "scrollbarthumb-horizontal",
+ "scrollbarthumb-vertical",
+ "scrollbartrack-horizontal",
+ "scrollbartrack-vertical",
+ "searchfield",
+ "separator",
+ "spinner",
+ "spinner-downbutton",
+ "spinner-textfield",
+ "spinner-upbutton",
+ "splitter",
+ "statusbar",
+ "statusbarpanel",
+ "tab",
+ "tab-scroll-arrow-back",
+ "tab-scroll-arrow-forward",
+ "tabpanel",
+ "tabpanels",
+ "textfield",
+ "textfield-multiline",
+ "toolbar",
+ "toolbarbutton",
+ "toolbarbutton-dropdown",
+ "toolbargripper",
+ "toolbox",
+ "tooltip",
+ "treeheader",
+ "treeheadercell",
+ "treeheadersortarrow",
+ "treeitem",
+ "treeline",
+ "treetwisty",
+ "treetwistyopen",
+ "treeview",
+ "unset",
+ "window"
+ ]
+ },
+ "-moz-backface-visibility": {
+ "isInherited": false,
+ "subproperties": [
+ "backface-visibility"
+ ],
+ "supports": [],
+ "values": [
+ "hidden",
+ "inherit",
+ "initial",
+ "unset",
+ "visible"
+ ]
+ },
+ "-moz-binding": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-binding"
+ ],
+ "supports": [
+ 11
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "none",
+ "unset",
+ "url"
+ ]
+ },
+ "-moz-border-bottom-colors": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-border-bottom-colors"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-border-end": {
+ "isInherited": false,
+ "subproperties": [
+ "border-inline-end-width",
+ "border-inline-end-style",
+ "border-inline-end-color"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "COLOR",
+ "-moz-calc",
+ "calc",
+ "currentColor",
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "inset",
+ "medium",
+ "none",
+ "outset",
+ "rgb",
+ "rgba",
+ "ridge",
+ "solid",
+ "thick",
+ "thin",
+ "transparent",
+ "unset"
+ ]
+ },
+ "-moz-border-end-color": {
+ "isInherited": false,
+ "subproperties": [
+ "border-inline-end-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "-moz-border-end-style": {
+ "isInherited": false,
+ "subproperties": [
+ "border-inline-end-style"
+ ],
+ "supports": [],
+ "values": [
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "inherit",
+ "initial",
+ "inset",
+ "none",
+ "outset",
+ "ridge",
+ "solid",
+ "unset"
+ ]
+ },
+ "-moz-border-end-width": {
+ "isInherited": false,
+ "subproperties": [
+ "border-inline-end-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "medium",
+ "thick",
+ "thin",
+ "unset"
+ ]
+ },
+ "-moz-border-image": {
+ "isInherited": false,
+ "subproperties": [
+ "border-image-source",
+ "border-image-slice",
+ "border-image-width",
+ "border-image-outset",
+ "border-image-repeat"
+ ],
+ "supports": [
+ 4,
+ 5,
+ 6,
+ 7,
+ 8,
+ 11
+ ],
+ "values": [
+ "-moz-element",
+ "-moz-image-rect",
+ "-moz-linear-gradient",
+ "-moz-radial-gradient",
+ "-moz-repeating-linear-gradient",
+ "-moz-repeating-radial-gradient",
+ "inherit",
+ "initial",
+ "linear-gradient",
+ "none",
+ "radial-gradient",
+ "repeating-linear-gradient",
+ "repeating-radial-gradient",
+ "unset",
+ "url"
+ ]
+ },
+ "-moz-border-left-colors": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-border-left-colors"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-border-right-colors": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-border-right-colors"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-border-start": {
+ "isInherited": false,
+ "subproperties": [
+ "border-inline-start-width",
+ "border-inline-start-style",
+ "border-inline-start-color"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "COLOR",
+ "-moz-calc",
+ "calc",
+ "currentColor",
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "inset",
+ "medium",
+ "none",
+ "outset",
+ "rgb",
+ "rgba",
+ "ridge",
+ "solid",
+ "thick",
+ "thin",
+ "transparent",
+ "unset"
+ ]
+ },
+ "-moz-border-start-color": {
+ "isInherited": false,
+ "subproperties": [
+ "border-inline-start-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "-moz-border-start-style": {
+ "isInherited": false,
+ "subproperties": [
+ "border-inline-start-style"
+ ],
+ "supports": [],
+ "values": [
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "inherit",
+ "initial",
+ "inset",
+ "none",
+ "outset",
+ "ridge",
+ "solid",
+ "unset"
+ ]
+ },
+ "-moz-border-start-width": {
+ "isInherited": false,
+ "subproperties": [
+ "border-inline-start-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "medium",
+ "thick",
+ "thin",
+ "unset"
+ ]
+ },
+ "-moz-border-top-colors": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-border-top-colors"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-box-align": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-box-align"
+ ],
+ "supports": [],
+ "values": [
+ "baseline",
+ "center",
+ "end",
+ "inherit",
+ "initial",
+ "start",
+ "stretch",
+ "unset"
+ ]
+ },
+ "-moz-box-direction": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-box-direction"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "normal",
+ "reverse",
+ "unset"
+ ]
+ },
+ "-moz-box-flex": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-box-flex"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-box-ordinal-group": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-box-ordinal-group"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-box-orient": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-box-orient"
+ ],
+ "supports": [],
+ "values": [
+ "block-axis",
+ "horizontal",
+ "inherit",
+ "initial",
+ "inline-axis",
+ "unset",
+ "vertical"
+ ]
+ },
+ "-moz-box-pack": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-box-pack"
+ ],
+ "supports": [],
+ "values": [
+ "center",
+ "end",
+ "inherit",
+ "initial",
+ "justify",
+ "start",
+ "unset"
+ ]
+ },
+ "-moz-box-sizing": {
+ "isInherited": false,
+ "subproperties": [
+ "box-sizing"
+ ],
+ "supports": [],
+ "values": [
+ "border-box",
+ "content-box",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-column-count": {
+ "isInherited": false,
+ "subproperties": [
+ "column-count"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "auto",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-column-fill": {
+ "isInherited": false,
+ "subproperties": [
+ "column-fill"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "balance",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-column-gap": {
+ "isInherited": false,
+ "subproperties": [
+ "column-gap"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "normal",
+ "unset"
+ ]
+ },
+ "-moz-column-rule": {
+ "isInherited": false,
+ "subproperties": [
+ "column-rule-width",
+ "column-rule-style",
+ "column-rule-color"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "COLOR",
+ "-moz-calc",
+ "calc",
+ "currentColor",
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "inset",
+ "medium",
+ "none",
+ "outset",
+ "rgb",
+ "rgba",
+ "ridge",
+ "solid",
+ "thick",
+ "thin",
+ "transparent",
+ "unset"
+ ]
+ },
+ "-moz-column-rule-color": {
+ "isInherited": false,
+ "subproperties": [
+ "column-rule-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "-moz-column-rule-style": {
+ "isInherited": false,
+ "subproperties": [
+ "column-rule-style"
+ ],
+ "supports": [],
+ "values": [
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "inherit",
+ "initial",
+ "inset",
+ "none",
+ "outset",
+ "ridge",
+ "solid",
+ "unset"
+ ]
+ },
+ "-moz-column-rule-width": {
+ "isInherited": false,
+ "subproperties": [
+ "column-rule-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "medium",
+ "thick",
+ "thin",
+ "unset"
+ ]
+ },
+ "-moz-column-width": {
+ "isInherited": false,
+ "subproperties": [
+ "column-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-columns": {
+ "isInherited": false,
+ "subproperties": [
+ "column-count",
+ "column-width"
+ ],
+ "supports": [
+ 6,
+ 7
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-control-character-visibility": {
+ "isInherited": true,
+ "subproperties": [
+ "-moz-control-character-visibility"
+ ],
+ "supports": [],
+ "values": [
+ "hidden",
+ "inherit",
+ "initial",
+ "unset",
+ "visible"
+ ]
+ },
+ "-moz-float-edge": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-float-edge"
+ ],
+ "supports": [],
+ "values": [
+ "content-box",
+ "inherit",
+ "initial",
+ "margin-box",
+ "unset"
+ ]
+ },
+ "-moz-font-feature-settings": {
+ "isInherited": true,
+ "subproperties": [
+ "font-feature-settings"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-font-language-override": {
+ "isInherited": true,
+ "subproperties": [
+ "font-language-override"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "normal",
+ "unset"
+ ]
+ },
+ "-moz-force-broken-image-icon": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-force-broken-image-icon"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-hyphens": {
+ "isInherited": true,
+ "subproperties": [
+ "hyphens"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "inherit",
+ "initial",
+ "manual",
+ "none",
+ "unset"
+ ]
+ },
+ "-moz-image-region": {
+ "isInherited": true,
+ "subproperties": [
+ "-moz-image-region"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-margin-end": {
+ "isInherited": false,
+ "subproperties": [
+ "margin-inline-end"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-margin-start": {
+ "isInherited": false,
+ "subproperties": [
+ "margin-inline-start"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-orient": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-orient"
+ ],
+ "supports": [],
+ "values": [
+ "block",
+ "horizontal",
+ "inherit",
+ "initial",
+ "inline",
+ "unset",
+ "vertical"
+ ]
+ },
+ "-moz-outline-radius": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-outline-radius-topleft",
+ "-moz-outline-radius-topright",
+ "-moz-outline-radius-bottomright",
+ "-moz-outline-radius-bottomleft"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-outline-radius-bottomleft": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-outline-radius-bottomleft"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-outline-radius-bottomright": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-outline-radius-bottomright"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-outline-radius-topleft": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-outline-radius-topleft"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-outline-radius-topright": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-outline-radius-topright"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-padding-end": {
+ "isInherited": false,
+ "subproperties": [
+ "padding-inline-end"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-padding-start": {
+ "isInherited": false,
+ "subproperties": [
+ "padding-inline-start"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-perspective": {
+ "isInherited": false,
+ "subproperties": [
+ "perspective"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "-moz-perspective-origin": {
+ "isInherited": false,
+ "subproperties": [
+ "perspective-origin"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-stack-sizing": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-stack-sizing"
+ ],
+ "supports": [],
+ "values": [
+ "ignore",
+ "inherit",
+ "initial",
+ "stretch-to-fit",
+ "unset"
+ ]
+ },
+ "-moz-tab-size": {
+ "isInherited": true,
+ "subproperties": [
+ "-moz-tab-size"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-text-align-last": {
+ "isInherited": true,
+ "subproperties": [
+ "text-align-last"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "center",
+ "end",
+ "inherit",
+ "initial",
+ "justify",
+ "left",
+ "right",
+ "start",
+ "unset"
+ ]
+ },
+ "-moz-text-size-adjust": {
+ "isInherited": true,
+ "subproperties": [
+ "-moz-text-size-adjust"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "-moz-transform": {
+ "isInherited": false,
+ "subproperties": [
+ "transform"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-transform-origin": {
+ "isInherited": false,
+ "subproperties": [
+ "transform-origin"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-transform-style": {
+ "isInherited": false,
+ "subproperties": [
+ "transform-style"
+ ],
+ "supports": [],
+ "values": [
+ "flat",
+ "inherit",
+ "initial",
+ "preserve-3d",
+ "unset"
+ ]
+ },
+ "-moz-transition": {
+ "isInherited": false,
+ "subproperties": [
+ "transition-property",
+ "transition-duration",
+ "transition-timing-function",
+ "transition-delay"
+ ],
+ "supports": [
+ 9,
+ 10
+ ],
+ "values": [
+ "all",
+ "cubic-bezier",
+ "ease",
+ "ease-in",
+ "ease-in-out",
+ "ease-out",
+ "inherit",
+ "initial",
+ "linear",
+ "none",
+ "step-end",
+ "step-start",
+ "steps",
+ "unset"
+ ]
+ },
+ "-moz-transition-delay": {
+ "isInherited": false,
+ "subproperties": [
+ "transition-delay"
+ ],
+ "supports": [
+ 9
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-transition-duration": {
+ "isInherited": false,
+ "subproperties": [
+ "transition-duration"
+ ],
+ "supports": [
+ 9
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-moz-transition-property": {
+ "isInherited": false,
+ "subproperties": [
+ "transition-property"
+ ],
+ "supports": [],
+ "values": [
+ "all",
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "-moz-transition-timing-function": {
+ "isInherited": false,
+ "subproperties": [
+ "transition-timing-function"
+ ],
+ "supports": [
+ 10
+ ],
+ "values": [
+ "cubic-bezier",
+ "ease",
+ "ease-in",
+ "ease-in-out",
+ "ease-out",
+ "inherit",
+ "initial",
+ "linear",
+ "step-end",
+ "step-start",
+ "steps",
+ "unset"
+ ]
+ },
+ "-moz-user-focus": {
+ "isInherited": true,
+ "subproperties": [
+ "-moz-user-focus"
+ ],
+ "supports": [],
+ "values": [
+ "ignore",
+ "inherit",
+ "initial",
+ "none",
+ "normal",
+ "select-after",
+ "select-all",
+ "select-before",
+ "select-menu",
+ "select-same",
+ "unset"
+ ]
+ },
+ "-moz-user-input": {
+ "isInherited": true,
+ "subproperties": [
+ "-moz-user-input"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "disabled",
+ "enabled",
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "-moz-user-modify": {
+ "isInherited": true,
+ "subproperties": [
+ "-moz-user-modify"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "read-only",
+ "read-write",
+ "unset",
+ "write-only"
+ ]
+ },
+ "-moz-user-select": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-user-select"
+ ],
+ "supports": [],
+ "values": [
+ "-moz-all",
+ "-moz-none",
+ "-moz-text",
+ "all",
+ "auto",
+ "element",
+ "elements",
+ "inherit",
+ "initial",
+ "none",
+ "text",
+ "toggle",
+ "tri-state",
+ "unset"
+ ]
+ },
+ "-moz-window-dragging": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-window-dragging"
+ ],
+ "supports": [],
+ "values": [
+ "default",
+ "drag",
+ "inherit",
+ "initial",
+ "no-drag",
+ "unset"
+ ]
+ },
+ "-webkit-align-content": {
+ "isInherited": false,
+ "subproperties": [
+ "align-content"
+ ],
+ "supports": [],
+ "values": [
+ "baseline",
+ "center",
+ "end",
+ "flex-end",
+ "flex-start",
+ "inherit",
+ "initial",
+ "last baseline",
+ "left",
+ "normal",
+ "right",
+ "space-around",
+ "space-between",
+ "space-evenly",
+ "start",
+ "stretch",
+ "unset"
+ ]
+ },
+ "-webkit-align-items": {
+ "isInherited": false,
+ "subproperties": [
+ "align-items"
+ ],
+ "supports": [],
+ "values": [
+ "baseline",
+ "center",
+ "end",
+ "flex-end",
+ "flex-start",
+ "inherit",
+ "initial",
+ "last baseline",
+ "left",
+ "normal",
+ "right",
+ "self-end",
+ "self-start",
+ "start",
+ "stretch",
+ "unset"
+ ]
+ },
+ "-webkit-align-self": {
+ "isInherited": false,
+ "subproperties": [
+ "align-self"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "baseline",
+ "center",
+ "end",
+ "flex-end",
+ "flex-start",
+ "inherit",
+ "initial",
+ "last baseline",
+ "left",
+ "normal",
+ "right",
+ "self-end",
+ "self-start",
+ "start",
+ "stretch",
+ "unset"
+ ]
+ },
+ "-webkit-animation": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-duration",
+ "animation-timing-function",
+ "animation-delay",
+ "animation-direction",
+ "animation-fill-mode",
+ "animation-iteration-count",
+ "animation-play-state",
+ "animation-name"
+ ],
+ "supports": [
+ 7,
+ 9,
+ 10
+ ],
+ "values": [
+ "alternate",
+ "alternate-reverse",
+ "backwards",
+ "both",
+ "cubic-bezier",
+ "ease",
+ "ease-in",
+ "ease-in-out",
+ "ease-out",
+ "forwards",
+ "infinite",
+ "inherit",
+ "initial",
+ "linear",
+ "none",
+ "normal",
+ "paused",
+ "reverse",
+ "running",
+ "step-end",
+ "step-start",
+ "steps",
+ "unset"
+ ]
+ },
+ "-webkit-animation-delay": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-delay"
+ ],
+ "supports": [
+ 9
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-animation-direction": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-direction"
+ ],
+ "supports": [],
+ "values": [
+ "alternate",
+ "alternate-reverse",
+ "inherit",
+ "initial",
+ "normal",
+ "reverse",
+ "unset"
+ ]
+ },
+ "-webkit-animation-duration": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-duration"
+ ],
+ "supports": [
+ 9
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-animation-fill-mode": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-fill-mode"
+ ],
+ "supports": [],
+ "values": [
+ "backwards",
+ "both",
+ "forwards",
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "-webkit-animation-iteration-count": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-iteration-count"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "infinite",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-animation-name": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-name"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "-webkit-animation-play-state": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-play-state"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "paused",
+ "running",
+ "unset"
+ ]
+ },
+ "-webkit-animation-timing-function": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-timing-function"
+ ],
+ "supports": [
+ 10
+ ],
+ "values": [
+ "cubic-bezier",
+ "ease",
+ "ease-in",
+ "ease-in-out",
+ "ease-out",
+ "inherit",
+ "initial",
+ "linear",
+ "step-end",
+ "step-start",
+ "steps",
+ "unset"
+ ]
+ },
+ "-webkit-backface-visibility": {
+ "isInherited": false,
+ "subproperties": [
+ "backface-visibility"
+ ],
+ "supports": [],
+ "values": [
+ "hidden",
+ "inherit",
+ "initial",
+ "unset",
+ "visible"
+ ]
+ },
+ "-webkit-background-clip": {
+ "isInherited": false,
+ "subproperties": [
+ "background-clip"
+ ],
+ "supports": [],
+ "values": [
+ "border-box",
+ "content-box",
+ "inherit",
+ "initial",
+ "padding-box",
+ "text",
+ "unset"
+ ]
+ },
+ "-webkit-background-origin": {
+ "isInherited": false,
+ "subproperties": [
+ "background-origin"
+ ],
+ "supports": [],
+ "values": [
+ "border-box",
+ "content-box",
+ "inherit",
+ "initial",
+ "padding-box",
+ "unset"
+ ]
+ },
+ "-webkit-background-size": {
+ "isInherited": false,
+ "subproperties": [
+ "background-size"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-border-bottom-left-radius": {
+ "isInherited": false,
+ "subproperties": [
+ "border-bottom-left-radius"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-border-bottom-right-radius": {
+ "isInherited": false,
+ "subproperties": [
+ "border-bottom-right-radius"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-border-image": {
+ "isInherited": false,
+ "subproperties": [
+ "border-image-source",
+ "border-image-slice",
+ "border-image-width",
+ "border-image-outset",
+ "border-image-repeat"
+ ],
+ "supports": [
+ 4,
+ 5,
+ 6,
+ 7,
+ 8,
+ 11
+ ],
+ "values": [
+ "-moz-element",
+ "-moz-image-rect",
+ "-moz-linear-gradient",
+ "-moz-radial-gradient",
+ "-moz-repeating-linear-gradient",
+ "-moz-repeating-radial-gradient",
+ "inherit",
+ "initial",
+ "linear-gradient",
+ "none",
+ "radial-gradient",
+ "repeating-linear-gradient",
+ "repeating-radial-gradient",
+ "unset",
+ "url"
+ ]
+ },
+ "-webkit-border-radius": {
+ "isInherited": false,
+ "subproperties": [
+ "border-top-left-radius",
+ "border-top-right-radius",
+ "border-bottom-right-radius",
+ "border-bottom-left-radius"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-border-top-left-radius": {
+ "isInherited": false,
+ "subproperties": [
+ "border-top-left-radius"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-border-top-right-radius": {
+ "isInherited": false,
+ "subproperties": [
+ "border-top-right-radius"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-box-align": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-box-align"
+ ],
+ "supports": [],
+ "values": [
+ "baseline",
+ "center",
+ "end",
+ "inherit",
+ "initial",
+ "start",
+ "stretch",
+ "unset"
+ ]
+ },
+ "-webkit-box-direction": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-box-direction"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "normal",
+ "reverse",
+ "unset"
+ ]
+ },
+ "-webkit-box-flex": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-box-flex"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-box-ordinal-group": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-box-ordinal-group"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-box-orient": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-box-orient"
+ ],
+ "supports": [],
+ "values": [
+ "block-axis",
+ "horizontal",
+ "inherit",
+ "initial",
+ "inline-axis",
+ "unset",
+ "vertical"
+ ]
+ },
+ "-webkit-box-pack": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-box-pack"
+ ],
+ "supports": [],
+ "values": [
+ "center",
+ "end",
+ "inherit",
+ "initial",
+ "justify",
+ "start",
+ "unset"
+ ]
+ },
+ "-webkit-box-shadow": {
+ "isInherited": false,
+ "subproperties": [
+ "box-shadow"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-box-sizing": {
+ "isInherited": false,
+ "subproperties": [
+ "box-sizing"
+ ],
+ "supports": [],
+ "values": [
+ "border-box",
+ "content-box",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-filter": {
+ "isInherited": false,
+ "subproperties": [
+ "filter"
+ ],
+ "supports": [
+ 11
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-flex": {
+ "isInherited": false,
+ "subproperties": [
+ "flex-grow",
+ "flex-shrink",
+ "flex-basis"
+ ],
+ "supports": [
+ 6,
+ 7,
+ 8
+ ],
+ "values": [
+ "-moz-available",
+ "-moz-calc",
+ "-moz-fit-content",
+ "-moz-max-content",
+ "-moz-min-content",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-flex-basis": {
+ "isInherited": false,
+ "subproperties": [
+ "flex-basis"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-available",
+ "-moz-calc",
+ "-moz-fit-content",
+ "-moz-max-content",
+ "-moz-min-content",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-flex-direction": {
+ "isInherited": false,
+ "subproperties": [
+ "flex-direction"
+ ],
+ "supports": [],
+ "values": [
+ "column",
+ "column-reverse",
+ "inherit",
+ "initial",
+ "row",
+ "row-reverse",
+ "unset"
+ ]
+ },
+ "-webkit-flex-flow": {
+ "isInherited": false,
+ "subproperties": [
+ "flex-direction",
+ "flex-wrap"
+ ],
+ "supports": [],
+ "values": [
+ "column",
+ "column-reverse",
+ "inherit",
+ "initial",
+ "nowrap",
+ "row",
+ "row-reverse",
+ "unset",
+ "wrap",
+ "wrap-reverse"
+ ]
+ },
+ "-webkit-flex-grow": {
+ "isInherited": false,
+ "subproperties": [
+ "flex-grow"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-flex-shrink": {
+ "isInherited": false,
+ "subproperties": [
+ "flex-shrink"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-flex-wrap": {
+ "isInherited": false,
+ "subproperties": [
+ "flex-wrap"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "nowrap",
+ "unset",
+ "wrap",
+ "wrap-reverse"
+ ]
+ },
+ "-webkit-justify-content": {
+ "isInherited": false,
+ "subproperties": [
+ "justify-content"
+ ],
+ "supports": [],
+ "values": [
+ "baseline",
+ "center",
+ "end",
+ "flex-end",
+ "flex-start",
+ "inherit",
+ "initial",
+ "last baseline",
+ "left",
+ "normal",
+ "right",
+ "space-around",
+ "space-between",
+ "space-evenly",
+ "start",
+ "stretch",
+ "unset"
+ ]
+ },
+ "-webkit-mask": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-image",
+ "mask-repeat",
+ "mask-position-x",
+ "mask-position-y",
+ "mask-clip",
+ "mask-origin",
+ "mask-size",
+ "mask-composite",
+ "mask-mode"
+ ],
+ "supports": [
+ 4,
+ 5,
+ 6,
+ 8,
+ 11
+ ],
+ "values": [
+ "-moz-element",
+ "-moz-image-rect",
+ "-moz-linear-gradient",
+ "-moz-radial-gradient",
+ "-moz-repeating-linear-gradient",
+ "-moz-repeating-radial-gradient",
+ "add",
+ "alpha",
+ "border-box",
+ "content-box",
+ "exclude",
+ "inherit",
+ "initial",
+ "intersect",
+ "linear-gradient",
+ "luminance",
+ "match-source",
+ "no-repeat",
+ "none",
+ "padding-box",
+ "radial-gradient",
+ "repeat",
+ "repeat-x",
+ "repeat-y",
+ "repeating-linear-gradient",
+ "repeating-radial-gradient",
+ "round",
+ "space",
+ "subtract",
+ "unset",
+ "url"
+ ]
+ },
+ "-webkit-mask-clip": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-clip"
+ ],
+ "supports": [],
+ "values": [
+ "border-box",
+ "content-box",
+ "inherit",
+ "initial",
+ "padding-box",
+ "unset"
+ ]
+ },
+ "-webkit-mask-composite": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-composite"
+ ],
+ "supports": [],
+ "values": [
+ "add",
+ "exclude",
+ "inherit",
+ "initial",
+ "intersect",
+ "subtract",
+ "unset"
+ ]
+ },
+ "-webkit-mask-image": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-image"
+ ],
+ "supports": [
+ 4,
+ 5,
+ 11
+ ],
+ "values": [
+ "-moz-element",
+ "-moz-image-rect",
+ "-moz-linear-gradient",
+ "-moz-radial-gradient",
+ "-moz-repeating-linear-gradient",
+ "-moz-repeating-radial-gradient",
+ "inherit",
+ "initial",
+ "linear-gradient",
+ "none",
+ "radial-gradient",
+ "repeating-linear-gradient",
+ "repeating-radial-gradient",
+ "unset",
+ "url"
+ ]
+ },
+ "-webkit-mask-origin": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-origin"
+ ],
+ "supports": [],
+ "values": [
+ "border-box",
+ "content-box",
+ "inherit",
+ "initial",
+ "padding-box",
+ "unset"
+ ]
+ },
+ "-webkit-mask-position": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-position-x",
+ "mask-position-y"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-mask-position-x": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-position-x"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-mask-position-y": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-position-y"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-mask-repeat": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-repeat"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "no-repeat",
+ "repeat",
+ "repeat-x",
+ "repeat-y",
+ "round",
+ "space",
+ "unset"
+ ]
+ },
+ "-webkit-mask-size": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-size"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-order": {
+ "isInherited": false,
+ "subproperties": [
+ "order"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-perspective": {
+ "isInherited": false,
+ "subproperties": [
+ "perspective"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "-webkit-perspective-origin": {
+ "isInherited": false,
+ "subproperties": [
+ "perspective-origin"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-text-fill-color": {
+ "isInherited": true,
+ "subproperties": [
+ "-webkit-text-fill-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "-webkit-text-size-adjust": {
+ "isInherited": true,
+ "subproperties": [
+ "-moz-text-size-adjust"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "-webkit-text-stroke": {
+ "isInherited": true,
+ "subproperties": [
+ "-webkit-text-stroke-width",
+ "-webkit-text-stroke-color"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "COLOR",
+ "-moz-calc",
+ "calc",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "medium",
+ "rgb",
+ "rgba",
+ "thick",
+ "thin",
+ "transparent",
+ "unset"
+ ]
+ },
+ "-webkit-text-stroke-color": {
+ "isInherited": true,
+ "subproperties": [
+ "-webkit-text-stroke-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "-webkit-text-stroke-width": {
+ "isInherited": true,
+ "subproperties": [
+ "-webkit-text-stroke-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "medium",
+ "thick",
+ "thin",
+ "unset"
+ ]
+ },
+ "-webkit-transform": {
+ "isInherited": false,
+ "subproperties": [
+ "transform"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-transform-origin": {
+ "isInherited": false,
+ "subproperties": [
+ "transform-origin"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-transform-style": {
+ "isInherited": false,
+ "subproperties": [
+ "transform-style"
+ ],
+ "supports": [],
+ "values": [
+ "flat",
+ "inherit",
+ "initial",
+ "preserve-3d",
+ "unset"
+ ]
+ },
+ "-webkit-transition": {
+ "isInherited": false,
+ "subproperties": [
+ "transition-property",
+ "transition-duration",
+ "transition-timing-function",
+ "transition-delay"
+ ],
+ "supports": [
+ 9,
+ 10
+ ],
+ "values": [
+ "all",
+ "cubic-bezier",
+ "ease",
+ "ease-in",
+ "ease-in-out",
+ "ease-out",
+ "inherit",
+ "initial",
+ "linear",
+ "none",
+ "step-end",
+ "step-start",
+ "steps",
+ "unset"
+ ]
+ },
+ "-webkit-transition-delay": {
+ "isInherited": false,
+ "subproperties": [
+ "transition-delay"
+ ],
+ "supports": [
+ 9
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-transition-duration": {
+ "isInherited": false,
+ "subproperties": [
+ "transition-duration"
+ ],
+ "supports": [
+ 9
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "-webkit-transition-property": {
+ "isInherited": false,
+ "subproperties": [
+ "transition-property"
+ ],
+ "supports": [],
+ "values": [
+ "all",
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "-webkit-transition-timing-function": {
+ "isInherited": false,
+ "subproperties": [
+ "transition-timing-function"
+ ],
+ "supports": [
+ 10
+ ],
+ "values": [
+ "cubic-bezier",
+ "ease",
+ "ease-in",
+ "ease-in-out",
+ "ease-out",
+ "inherit",
+ "initial",
+ "linear",
+ "step-end",
+ "step-start",
+ "steps",
+ "unset"
+ ]
+ },
+ "-webkit-user-select": {
+ "isInherited": false,
+ "subproperties": [
+ "-moz-user-select"
+ ],
+ "supports": [],
+ "values": [
+ "-moz-all",
+ "-moz-none",
+ "-moz-text",
+ "all",
+ "auto",
+ "element",
+ "elements",
+ "inherit",
+ "initial",
+ "none",
+ "text",
+ "toggle",
+ "tri-state",
+ "unset"
+ ]
+ },
+ "align-content": {
+ "isInherited": false,
+ "subproperties": [
+ "align-content"
+ ],
+ "supports": [],
+ "values": [
+ "baseline",
+ "center",
+ "end",
+ "flex-end",
+ "flex-start",
+ "inherit",
+ "initial",
+ "last baseline",
+ "left",
+ "normal",
+ "right",
+ "space-around",
+ "space-between",
+ "space-evenly",
+ "start",
+ "stretch",
+ "unset"
+ ]
+ },
+ "align-items": {
+ "isInherited": false,
+ "subproperties": [
+ "align-items"
+ ],
+ "supports": [],
+ "values": [
+ "baseline",
+ "center",
+ "end",
+ "flex-end",
+ "flex-start",
+ "inherit",
+ "initial",
+ "last baseline",
+ "left",
+ "normal",
+ "right",
+ "self-end",
+ "self-start",
+ "start",
+ "stretch",
+ "unset"
+ ]
+ },
+ "align-self": {
+ "isInherited": false,
+ "subproperties": [
+ "align-self"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "baseline",
+ "center",
+ "end",
+ "flex-end",
+ "flex-start",
+ "inherit",
+ "initial",
+ "last baseline",
+ "left",
+ "normal",
+ "right",
+ "self-end",
+ "self-start",
+ "start",
+ "stretch",
+ "unset"
+ ]
+ },
+ "all": {
+ "isInherited": false,
+ "subproperties": [
+ "align-content",
+ "align-items",
+ "align-self",
+ "animation-delay",
+ "animation-direction",
+ "animation-duration",
+ "animation-fill-mode",
+ "animation-iteration-count",
+ "animation-name",
+ "animation-play-state",
+ "animation-timing-function",
+ "-moz-appearance",
+ "backface-visibility",
+ "background-attachment",
+ "background-blend-mode",
+ "background-clip",
+ "background-color",
+ "background-image",
+ "background-origin",
+ "background-position-x",
+ "background-position-y",
+ "background-repeat",
+ "background-size",
+ "-moz-binding",
+ "block-size",
+ "border-block-end-color",
+ "border-block-end-style",
+ "border-block-end-width",
+ "border-block-start-color",
+ "border-block-start-style",
+ "border-block-start-width",
+ "border-bottom-color",
+ "-moz-border-bottom-colors",
+ "border-bottom-left-radius",
+ "border-bottom-right-radius",
+ "border-bottom-style",
+ "border-bottom-width",
+ "border-collapse",
+ "border-image-outset",
+ "border-image-repeat",
+ "border-image-slice",
+ "border-image-source",
+ "border-image-width",
+ "border-inline-end-color",
+ "border-inline-end-style",
+ "border-inline-end-width",
+ "border-inline-start-color",
+ "border-inline-start-style",
+ "border-inline-start-width",
+ "border-left-color",
+ "-moz-border-left-colors",
+ "border-left-style",
+ "border-left-width",
+ "border-right-color",
+ "-moz-border-right-colors",
+ "border-right-style",
+ "border-right-width",
+ "border-spacing",
+ "border-top-color",
+ "-moz-border-top-colors",
+ "border-top-left-radius",
+ "border-top-right-radius",
+ "border-top-style",
+ "border-top-width",
+ "bottom",
+ "-moz-box-align",
+ "box-decoration-break",
+ "-moz-box-direction",
+ "-moz-box-flex",
+ "-moz-box-ordinal-group",
+ "-moz-box-orient",
+ "-moz-box-pack",
+ "box-shadow",
+ "box-sizing",
+ "caption-side",
+ "clear",
+ "clip",
+ "clip-path",
+ "clip-rule",
+ "color",
+ "color-adjust",
+ "color-interpolation",
+ "color-interpolation-filters",
+ "column-count",
+ "column-fill",
+ "column-gap",
+ "column-rule-color",
+ "column-rule-style",
+ "column-rule-width",
+ "column-width",
+ "contain",
+ "content",
+ "-moz-control-character-visibility",
+ "counter-increment",
+ "counter-reset",
+ "cursor",
+ "display",
+ "dominant-baseline",
+ "empty-cells",
+ "fill",
+ "fill-opacity",
+ "fill-rule",
+ "filter",
+ "flex-basis",
+ "flex-direction",
+ "flex-grow",
+ "flex-shrink",
+ "flex-wrap",
+ "float",
+ "-moz-float-edge",
+ "flood-color",
+ "flood-opacity",
+ "font-family",
+ "font-feature-settings",
+ "font-kerning",
+ "font-language-override",
+ "font-size",
+ "font-size-adjust",
+ "font-stretch",
+ "font-style",
+ "font-synthesis",
+ "font-variant-alternates",
+ "font-variant-caps",
+ "font-variant-east-asian",
+ "font-variant-ligatures",
+ "font-variant-numeric",
+ "font-variant-position",
+ "font-weight",
+ "-moz-force-broken-image-icon",
+ "grid-auto-columns",
+ "grid-auto-flow",
+ "grid-auto-rows",
+ "grid-column-end",
+ "grid-column-gap",
+ "grid-column-start",
+ "grid-row-end",
+ "grid-row-gap",
+ "grid-row-start",
+ "grid-template-areas",
+ "grid-template-columns",
+ "grid-template-rows",
+ "height",
+ "hyphens",
+ "initial-letter",
+ "image-orientation",
+ "-moz-image-region",
+ "image-rendering",
+ "ime-mode",
+ "inline-size",
+ "isolation",
+ "justify-content",
+ "justify-items",
+ "justify-self",
+ "left",
+ "letter-spacing",
+ "lighting-color",
+ "line-height",
+ "list-style-image",
+ "list-style-position",
+ "list-style-type",
+ "margin-block-end",
+ "margin-block-start",
+ "margin-bottom",
+ "margin-inline-end",
+ "margin-inline-start",
+ "margin-left",
+ "margin-right",
+ "margin-top",
+ "marker-end",
+ "marker-mid",
+ "marker-start",
+ "mask-clip",
+ "mask-composite",
+ "mask-image",
+ "mask-mode",
+ "mask-origin",
+ "mask-position-x",
+ "mask-position-y",
+ "mask-repeat",
+ "mask-size",
+ "mask-type",
+ "max-block-size",
+ "max-height",
+ "max-inline-size",
+ "max-width",
+ "min-block-size",
+ "-moz-min-font-size-ratio",
+ "min-height",
+ "min-inline-size",
+ "min-width",
+ "mix-blend-mode",
+ "object-fit",
+ "object-position",
+ "offset-block-end",
+ "offset-block-start",
+ "offset-inline-end",
+ "offset-inline-start",
+ "opacity",
+ "order",
+ "-moz-orient",
+ "-moz-osx-font-smoothing",
+ "outline-color",
+ "outline-offset",
+ "-moz-outline-radius-bottomleft",
+ "-moz-outline-radius-bottomright",
+ "-moz-outline-radius-topleft",
+ "-moz-outline-radius-topright",
+ "outline-style",
+ "outline-width",
+ "overflow-clip-box",
+ "overflow-x",
+ "overflow-y",
+ "padding-block-end",
+ "padding-block-start",
+ "padding-bottom",
+ "padding-inline-end",
+ "padding-inline-start",
+ "padding-left",
+ "padding-right",
+ "padding-top",
+ "page-break-after",
+ "page-break-before",
+ "page-break-inside",
+ "paint-order",
+ "perspective",
+ "perspective-origin",
+ "pointer-events",
+ "position",
+ "quotes",
+ "resize",
+ "right",
+ "ruby-align",
+ "ruby-position",
+ "scroll-behavior",
+ "scroll-snap-coordinate",
+ "scroll-snap-destination",
+ "scroll-snap-points-x",
+ "scroll-snap-points-y",
+ "scroll-snap-type-x",
+ "scroll-snap-type-y",
+ "shape-outside",
+ "shape-rendering",
+ "-moz-stack-sizing",
+ "stop-color",
+ "stop-opacity",
+ "stroke",
+ "stroke-dasharray",
+ "stroke-dashoffset",
+ "stroke-linecap",
+ "stroke-linejoin",
+ "stroke-miterlimit",
+ "stroke-opacity",
+ "stroke-width",
+ "-x-system-font",
+ "-moz-tab-size",
+ "table-layout",
+ "text-align",
+ "text-align-last",
+ "text-anchor",
+ "text-combine-upright",
+ "text-decoration-color",
+ "text-decoration-line",
+ "text-decoration-style",
+ "text-emphasis-color",
+ "text-emphasis-position",
+ "text-emphasis-style",
+ "-webkit-text-fill-color",
+ "text-indent",
+ "text-orientation",
+ "text-overflow",
+ "text-rendering",
+ "text-shadow",
+ "-moz-text-size-adjust",
+ "-webkit-text-stroke-color",
+ "-webkit-text-stroke-width",
+ "text-transform",
+ "top",
+ "-moz-top-layer",
+ "touch-action",
+ "transform",
+ "transform-box",
+ "transform-origin",
+ "transform-style",
+ "transition-delay",
+ "transition-duration",
+ "transition-property",
+ "transition-timing-function",
+ "-moz-user-focus",
+ "-moz-user-input",
+ "-moz-user-modify",
+ "-moz-user-select",
+ "vector-effect",
+ "vertical-align",
+ "visibility",
+ "white-space",
+ "width",
+ "will-change",
+ "-moz-window-dragging",
+ "-moz-window-shadow",
+ "word-break",
+ "word-spacing",
+ "overflow-wrap",
+ "writing-mode",
+ "z-index"
+ ],
+ "supports": [
+ 1,
+ 2,
+ 4,
+ 5,
+ 6,
+ 7,
+ 8,
+ 9,
+ 10,
+ 11
+ ],
+ "values": [
+ "COLOR",
+ "-moz-all",
+ "-moz-available",
+ "-moz-block-height",
+ "-moz-box",
+ "-moz-calc",
+ "-moz-center",
+ "-moz-crisp-edges",
+ "-moz-deck",
+ "-moz-element",
+ "-moz-fit-content",
+ "-moz-grid",
+ "-moz-grid-group",
+ "-moz-grid-line",
+ "-moz-groupbox",
+ "-moz-gtk-info-bar",
+ "-moz-hidden-unscrollable",
+ "-moz-image-rect",
+ "-moz-inline-box",
+ "-moz-inline-grid",
+ "-moz-inline-stack",
+ "-moz-left",
+ "-moz-linear-gradient",
+ "-moz-mac-disclosure-button-closed",
+ "-moz-mac-disclosure-button-open",
+ "-moz-mac-fullscreen-button",
+ "-moz-mac-help-button",
+ "-moz-mac-source-list",
+ "-moz-mac-vibrancy-dark",
+ "-moz-mac-vibrancy-light",
+ "-moz-max-content",
+ "-moz-middle-with-baseline",
+ "-moz-min-content",
+ "-moz-none",
+ "-moz-popup",
+ "-moz-pre-space",
+ "-moz-radial-gradient",
+ "-moz-repeating-linear-gradient",
+ "-moz-repeating-radial-gradient",
+ "-moz-right",
+ "-moz-stack",
+ "-moz-text",
+ "-moz-win-borderless-glass",
+ "-moz-win-browsertabbar-toolbox",
+ "-moz-win-communications-toolbox",
+ "-moz-win-exclude-glass",
+ "-moz-win-glass",
+ "-moz-win-media-toolbox",
+ "-moz-window-button-box",
+ "-moz-window-button-box-maximized",
+ "-moz-window-button-close",
+ "-moz-window-button-maximize",
+ "-moz-window-button-minimize",
+ "-moz-window-button-restore",
+ "-moz-window-frame-bottom",
+ "-moz-window-frame-left",
+ "-moz-window-frame-right",
+ "-moz-window-titlebar",
+ "-moz-window-titlebar-maximized",
+ "-webkit-box",
+ "-webkit-flex",
+ "-webkit-inline-box",
+ "-webkit-inline-flex",
+ "absolute",
+ "active",
+ "add",
+ "all",
+ "all-petite-caps",
+ "all-small-caps",
+ "alpha",
+ "alphabetic",
+ "alternate",
+ "alternate-reverse",
+ "always",
+ "auto",
+ "avoid",
+ "backwards",
+ "balance",
+ "baseline",
+ "bevel",
+ "block",
+ "block-axis",
+ "border-box",
+ "both",
+ "bottom",
+ "bottom-outside",
+ "break-all",
+ "break-word",
+ "butt",
+ "button",
+ "button-arrow-down",
+ "button-arrow-next",
+ "button-arrow-previous",
+ "button-arrow-up",
+ "button-bevel",
+ "button-focus",
+ "calc",
+ "capitalize",
+ "caret",
+ "center",
+ "central",
+ "checkbox",
+ "checkbox-container",
+ "checkbox-label",
+ "checkmenuitem",
+ "clone",
+ "collapse",
+ "color",
+ "color-burn",
+ "color-dodge",
+ "column",
+ "column-reverse",
+ "condensed",
+ "contain",
+ "content-box",
+ "contents",
+ "cover",
+ "crispedges",
+ "cubic-bezier",
+ "currentColor",
+ "darken",
+ "dashed",
+ "default",
+ "dialog",
+ "difference",
+ "disabled",
+ "dotted",
+ "double",
+ "drag",
+ "dualbutton",
+ "ease",
+ "ease-in",
+ "ease-in-out",
+ "ease-out",
+ "economy",
+ "element",
+ "elements",
+ "enabled",
+ "end",
+ "evenodd",
+ "exact",
+ "exclude",
+ "exclusion",
+ "expanded",
+ "extra-condensed",
+ "extra-expanded",
+ "fill",
+ "fill-box",
+ "fixed",
+ "flat",
+ "flex",
+ "flex-end",
+ "flex-start",
+ "forwards",
+ "full-width",
+ "geometricprecision",
+ "grayscale",
+ "grid",
+ "groove",
+ "groupbox",
+ "hanging",
+ "hard-light",
+ "hidden",
+ "hide",
+ "horizontal",
+ "horizontal-tb",
+ "hsl",
+ "hsla",
+ "hue",
+ "ideographic",
+ "ignore",
+ "inactive",
+ "infinite",
+ "inherit",
+ "initial",
+ "inline",
+ "inline-axis",
+ "inline-block",
+ "inline-end",
+ "inline-flex",
+ "inline-grid",
+ "inline-start",
+ "inline-table",
+ "inset",
+ "inside",
+ "intersect",
+ "isolate",
+ "italic",
+ "justify",
+ "keep-all",
+ "large",
+ "larger",
+ "last baseline",
+ "left",
+ "lighten",
+ "linear",
+ "linear-gradient",
+ "linearrgb",
+ "list-item",
+ "listbox",
+ "listitem",
+ "local",
+ "lowercase",
+ "lr",
+ "lr-tb",
+ "luminance",
+ "luminosity",
+ "mandatory",
+ "manipulation",
+ "manual",
+ "margin-box",
+ "match-source",
+ "mathematical",
+ "medium",
+ "menuarrow",
+ "menubar",
+ "menucheckbox",
+ "menuimage",
+ "menuitem",
+ "menuitemtext",
+ "menulist",
+ "menulist-button",
+ "menulist-text",
+ "menulist-textfield",
+ "menupopup",
+ "menuradio",
+ "menuseparator",
+ "meterbar",
+ "meterchunk",
+ "middle",
+ "miter",
+ "mixed",
+ "multiply",
+ "no-change",
+ "no-drag",
+ "no-repeat",
+ "non-scaling-stroke",
+ "none",
+ "nonzero",
+ "normal",
+ "nowrap",
+ "number-input",
+ "oblique",
+ "optimizelegibility",
+ "optimizequality",
+ "optimizespeed",
+ "outset",
+ "outside",
+ "over",
+ "overlay",
+ "padding-box",
+ "painted",
+ "pan-x",
+ "pan-y",
+ "paused",
+ "petite-caps",
+ "pre",
+ "pre-line",
+ "pre-wrap",
+ "preserve-3d",
+ "progressbar",
+ "progressbar-vertical",
+ "progresschunk",
+ "progresschunk-vertical",
+ "proximity",
+ "radial-gradient",
+ "radio",
+ "radio-container",
+ "radio-label",
+ "radiomenuitem",
+ "range",
+ "range-thumb",
+ "read-only",
+ "read-write",
+ "relative",
+ "repeat",
+ "repeat-x",
+ "repeat-y",
+ "repeating-linear-gradient",
+ "repeating-radial-gradient",
+ "reset-size",
+ "resizer",
+ "resizerpanel",
+ "reverse",
+ "rgb",
+ "rgba",
+ "ridge",
+ "right",
+ "rl",
+ "rl-tb",
+ "round",
+ "row",
+ "row-reverse",
+ "ruby",
+ "ruby-base",
+ "ruby-base-container",
+ "ruby-text",
+ "ruby-text-container",
+ "running",
+ "saturation",
+ "scale-down",
+ "scale-horizontal",
+ "scale-vertical",
+ "scalethumb-horizontal",
+ "scalethumb-vertical",
+ "scalethumbend",
+ "scalethumbstart",
+ "scalethumbtick",
+ "screen",
+ "scroll",
+ "scrollbar",
+ "scrollbar-horizontal",
+ "scrollbar-small",
+ "scrollbar-vertical",
+ "scrollbarbutton-down",
+ "scrollbarbutton-left",
+ "scrollbarbutton-right",
+ "scrollbarbutton-up",
+ "scrollbarthumb-horizontal",
+ "scrollbarthumb-vertical",
+ "scrollbartrack-horizontal",
+ "scrollbartrack-vertical",
+ "searchfield",
+ "select-after",
+ "select-all",
+ "select-before",
+ "select-menu",
+ "select-same",
+ "self-end",
+ "self-start",
+ "semi-condensed",
+ "semi-expanded",
+ "separate",
+ "separator",
+ "show",
+ "sideways",
+ "sideways-lr",
+ "sideways-right",
+ "sideways-rl",
+ "slice",
+ "small",
+ "small-caps",
+ "smaller",
+ "smooth",
+ "soft-light",
+ "solid",
+ "space",
+ "space-around",
+ "space-between",
+ "space-evenly",
+ "spinner",
+ "spinner-downbutton",
+ "spinner-textfield",
+ "spinner-upbutton",
+ "splitter",
+ "square",
+ "srgb",
+ "start",
+ "static",
+ "statusbar",
+ "statusbarpanel",
+ "step-end",
+ "step-start",
+ "steps",
+ "sticky",
+ "stretch",
+ "stretch-to-fit",
+ "stroke",
+ "sub",
+ "subtract",
+ "super",
+ "tab",
+ "tab-scroll-arrow-back",
+ "tab-scroll-arrow-forward",
+ "table",
+ "table-caption",
+ "table-cell",
+ "table-column",
+ "table-column-group",
+ "table-footer-group",
+ "table-header-group",
+ "table-row",
+ "table-row-group",
+ "tabpanel",
+ "tabpanels",
+ "tb",
+ "tb-rl",
+ "text",
+ "text-after-edge",
+ "text-before-edge",
+ "text-bottom",
+ "text-top",
+ "textfield",
+ "textfield-multiline",
+ "thick",
+ "thin",
+ "titling-caps",
+ "toggle",
+ "toolbar",
+ "toolbarbutton",
+ "toolbarbutton-dropdown",
+ "toolbargripper",
+ "toolbox",
+ "tooltip",
+ "top",
+ "top-outside",
+ "transparent",
+ "treeheader",
+ "treeheadercell",
+ "treeheadersortarrow",
+ "treeitem",
+ "treeline",
+ "treetwisty",
+ "treetwistyopen",
+ "treeview",
+ "tri-state",
+ "ultra-condensed",
+ "ultra-expanded",
+ "under",
+ "unicase",
+ "unset",
+ "uppercase",
+ "upright",
+ "url",
+ "use-script",
+ "vertical",
+ "vertical-lr",
+ "vertical-rl",
+ "view-box",
+ "visible",
+ "visiblefill",
+ "visiblepainted",
+ "visiblestroke",
+ "wavy",
+ "window",
+ "wrap",
+ "wrap-reverse",
+ "write-only",
+ "x-large",
+ "x-small",
+ "xx-large",
+ "xx-small"
+ ]
+ },
+ "animation": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-duration",
+ "animation-timing-function",
+ "animation-delay",
+ "animation-direction",
+ "animation-fill-mode",
+ "animation-iteration-count",
+ "animation-play-state",
+ "animation-name"
+ ],
+ "supports": [
+ 7,
+ 9,
+ 10
+ ],
+ "values": [
+ "alternate",
+ "alternate-reverse",
+ "backwards",
+ "both",
+ "cubic-bezier",
+ "ease",
+ "ease-in",
+ "ease-in-out",
+ "ease-out",
+ "forwards",
+ "infinite",
+ "inherit",
+ "initial",
+ "linear",
+ "none",
+ "normal",
+ "paused",
+ "reverse",
+ "running",
+ "step-end",
+ "step-start",
+ "steps",
+ "unset"
+ ]
+ },
+ "animation-delay": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-delay"
+ ],
+ "supports": [
+ 9
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "animation-direction": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-direction"
+ ],
+ "supports": [],
+ "values": [
+ "alternate",
+ "alternate-reverse",
+ "inherit",
+ "initial",
+ "normal",
+ "reverse",
+ "unset"
+ ]
+ },
+ "animation-duration": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-duration"
+ ],
+ "supports": [
+ 9
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "animation-fill-mode": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-fill-mode"
+ ],
+ "supports": [],
+ "values": [
+ "backwards",
+ "both",
+ "forwards",
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "animation-iteration-count": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-iteration-count"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "infinite",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "animation-name": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-name"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "animation-play-state": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-play-state"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "paused",
+ "running",
+ "unset"
+ ]
+ },
+ "animation-timing-function": {
+ "isInherited": false,
+ "subproperties": [
+ "animation-timing-function"
+ ],
+ "supports": [
+ 10
+ ],
+ "values": [
+ "cubic-bezier",
+ "ease",
+ "ease-in",
+ "ease-in-out",
+ "ease-out",
+ "inherit",
+ "initial",
+ "linear",
+ "step-end",
+ "step-start",
+ "steps",
+ "unset"
+ ]
+ },
+ "backface-visibility": {
+ "isInherited": false,
+ "subproperties": [
+ "backface-visibility"
+ ],
+ "supports": [],
+ "values": [
+ "hidden",
+ "inherit",
+ "initial",
+ "unset",
+ "visible"
+ ]
+ },
+ "background": {
+ "isInherited": false,
+ "subproperties": [
+ "background-color",
+ "background-image",
+ "background-repeat",
+ "background-attachment",
+ "background-clip",
+ "background-origin",
+ "background-position-x",
+ "background-position-y",
+ "background-size"
+ ],
+ "supports": [
+ 2,
+ 4,
+ 5,
+ 6,
+ 8,
+ 11
+ ],
+ "values": [
+ "COLOR",
+ "-moz-element",
+ "-moz-image-rect",
+ "-moz-linear-gradient",
+ "-moz-radial-gradient",
+ "-moz-repeating-linear-gradient",
+ "-moz-repeating-radial-gradient",
+ "border-box",
+ "content-box",
+ "currentColor",
+ "fixed",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "linear-gradient",
+ "local",
+ "no-repeat",
+ "none",
+ "padding-box",
+ "radial-gradient",
+ "repeat",
+ "repeat-x",
+ "repeat-y",
+ "repeating-linear-gradient",
+ "repeating-radial-gradient",
+ "rgb",
+ "rgba",
+ "round",
+ "scroll",
+ "space",
+ "text",
+ "transparent",
+ "unset",
+ "url"
+ ]
+ },
+ "background-attachment": {
+ "isInherited": false,
+ "subproperties": [
+ "background-attachment"
+ ],
+ "supports": [],
+ "values": [
+ "fixed",
+ "inherit",
+ "initial",
+ "local",
+ "scroll",
+ "unset"
+ ]
+ },
+ "background-blend-mode": {
+ "isInherited": false,
+ "subproperties": [
+ "background-blend-mode"
+ ],
+ "supports": [],
+ "values": [
+ "color",
+ "color-burn",
+ "color-dodge",
+ "darken",
+ "difference",
+ "exclusion",
+ "hard-light",
+ "hue",
+ "inherit",
+ "initial",
+ "lighten",
+ "luminosity",
+ "multiply",
+ "normal",
+ "overlay",
+ "saturation",
+ "screen",
+ "soft-light",
+ "unset"
+ ]
+ },
+ "background-clip": {
+ "isInherited": false,
+ "subproperties": [
+ "background-clip"
+ ],
+ "supports": [],
+ "values": [
+ "border-box",
+ "content-box",
+ "inherit",
+ "initial",
+ "padding-box",
+ "text",
+ "unset"
+ ]
+ },
+ "background-color": {
+ "isInherited": false,
+ "subproperties": [
+ "background-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "background-image": {
+ "isInherited": false,
+ "subproperties": [
+ "background-image"
+ ],
+ "supports": [
+ 4,
+ 5,
+ 11
+ ],
+ "values": [
+ "-moz-element",
+ "-moz-image-rect",
+ "-moz-linear-gradient",
+ "-moz-radial-gradient",
+ "-moz-repeating-linear-gradient",
+ "-moz-repeating-radial-gradient",
+ "inherit",
+ "initial",
+ "linear-gradient",
+ "none",
+ "radial-gradient",
+ "repeating-linear-gradient",
+ "repeating-radial-gradient",
+ "unset",
+ "url"
+ ]
+ },
+ "background-origin": {
+ "isInherited": false,
+ "subproperties": [
+ "background-origin"
+ ],
+ "supports": [],
+ "values": [
+ "border-box",
+ "content-box",
+ "inherit",
+ "initial",
+ "padding-box",
+ "unset"
+ ]
+ },
+ "background-position": {
+ "isInherited": false,
+ "subproperties": [
+ "background-position-x",
+ "background-position-y"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "background-position-x": {
+ "isInherited": false,
+ "subproperties": [
+ "background-position-x"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "background-position-y": {
+ "isInherited": false,
+ "subproperties": [
+ "background-position-y"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "background-repeat": {
+ "isInherited": false,
+ "subproperties": [
+ "background-repeat"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "no-repeat",
+ "repeat",
+ "repeat-x",
+ "repeat-y",
+ "round",
+ "space",
+ "unset"
+ ]
+ },
+ "background-size": {
+ "isInherited": false,
+ "subproperties": [
+ "background-size"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "block-size": {
+ "isInherited": false,
+ "subproperties": [
+ "block-size"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "border": {
+ "isInherited": false,
+ "subproperties": [
+ "border-top-width",
+ "border-right-width",
+ "border-bottom-width",
+ "border-left-width",
+ "border-top-style",
+ "border-right-style",
+ "border-bottom-style",
+ "border-left-style",
+ "border-top-color",
+ "border-right-color",
+ "border-bottom-color",
+ "border-left-color",
+ "-moz-border-top-colors",
+ "-moz-border-right-colors",
+ "-moz-border-bottom-colors",
+ "-moz-border-left-colors",
+ "border-image-source",
+ "border-image-slice",
+ "border-image-width",
+ "border-image-outset",
+ "border-image-repeat"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "COLOR",
+ "-moz-calc",
+ "-moz-element",
+ "-moz-image-rect",
+ "-moz-linear-gradient",
+ "-moz-radial-gradient",
+ "-moz-repeating-linear-gradient",
+ "-moz-repeating-radial-gradient",
+ "calc",
+ "currentColor",
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "inset",
+ "linear-gradient",
+ "medium",
+ "none",
+ "outset",
+ "radial-gradient",
+ "repeating-linear-gradient",
+ "repeating-radial-gradient",
+ "rgb",
+ "rgba",
+ "ridge",
+ "solid",
+ "thick",
+ "thin",
+ "transparent",
+ "unset",
+ "url"
+ ]
+ },
+ "border-block-end": {
+ "isInherited": false,
+ "subproperties": [
+ "border-block-end-width",
+ "border-block-end-style",
+ "border-block-end-color"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "COLOR",
+ "-moz-calc",
+ "calc",
+ "currentColor",
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "inset",
+ "medium",
+ "none",
+ "outset",
+ "rgb",
+ "rgba",
+ "ridge",
+ "solid",
+ "thick",
+ "thin",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-block-end-color": {
+ "isInherited": false,
+ "subproperties": [
+ "border-block-end-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-block-end-style": {
+ "isInherited": false,
+ "subproperties": [
+ "border-block-end-style"
+ ],
+ "supports": [],
+ "values": [
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "inherit",
+ "initial",
+ "inset",
+ "none",
+ "outset",
+ "ridge",
+ "solid",
+ "unset"
+ ]
+ },
+ "border-block-end-width": {
+ "isInherited": false,
+ "subproperties": [
+ "border-block-end-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "medium",
+ "thick",
+ "thin",
+ "unset"
+ ]
+ },
+ "border-block-start": {
+ "isInherited": false,
+ "subproperties": [
+ "border-block-start-width",
+ "border-block-start-style",
+ "border-block-start-color"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "COLOR",
+ "-moz-calc",
+ "calc",
+ "currentColor",
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "inset",
+ "medium",
+ "none",
+ "outset",
+ "rgb",
+ "rgba",
+ "ridge",
+ "solid",
+ "thick",
+ "thin",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-block-start-color": {
+ "isInherited": false,
+ "subproperties": [
+ "border-block-start-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-block-start-style": {
+ "isInherited": false,
+ "subproperties": [
+ "border-block-start-style"
+ ],
+ "supports": [],
+ "values": [
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "inherit",
+ "initial",
+ "inset",
+ "none",
+ "outset",
+ "ridge",
+ "solid",
+ "unset"
+ ]
+ },
+ "border-block-start-width": {
+ "isInherited": false,
+ "subproperties": [
+ "border-block-start-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "medium",
+ "thick",
+ "thin",
+ "unset"
+ ]
+ },
+ "border-bottom": {
+ "isInherited": false,
+ "subproperties": [
+ "border-bottom-width",
+ "border-bottom-style",
+ "border-bottom-color"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "COLOR",
+ "-moz-calc",
+ "calc",
+ "currentColor",
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "inset",
+ "medium",
+ "none",
+ "outset",
+ "rgb",
+ "rgba",
+ "ridge",
+ "solid",
+ "thick",
+ "thin",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-bottom-color": {
+ "isInherited": false,
+ "subproperties": [
+ "border-bottom-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-bottom-left-radius": {
+ "isInherited": false,
+ "subproperties": [
+ "border-bottom-left-radius"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "border-bottom-right-radius": {
+ "isInherited": false,
+ "subproperties": [
+ "border-bottom-right-radius"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "border-bottom-style": {
+ "isInherited": false,
+ "subproperties": [
+ "border-bottom-style"
+ ],
+ "supports": [],
+ "values": [
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "inherit",
+ "initial",
+ "inset",
+ "none",
+ "outset",
+ "ridge",
+ "solid",
+ "unset"
+ ]
+ },
+ "border-bottom-width": {
+ "isInherited": false,
+ "subproperties": [
+ "border-bottom-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "medium",
+ "thick",
+ "thin",
+ "unset"
+ ]
+ },
+ "border-collapse": {
+ "isInherited": true,
+ "subproperties": [
+ "border-collapse"
+ ],
+ "supports": [],
+ "values": [
+ "collapse",
+ "inherit",
+ "initial",
+ "separate",
+ "unset"
+ ]
+ },
+ "border-color": {
+ "isInherited": false,
+ "subproperties": [
+ "border-top-color",
+ "border-right-color",
+ "border-bottom-color",
+ "border-left-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-image": {
+ "isInherited": false,
+ "subproperties": [
+ "border-image-source",
+ "border-image-slice",
+ "border-image-width",
+ "border-image-outset",
+ "border-image-repeat"
+ ],
+ "supports": [
+ 4,
+ 5,
+ 6,
+ 7,
+ 8,
+ 11
+ ],
+ "values": [
+ "-moz-element",
+ "-moz-image-rect",
+ "-moz-linear-gradient",
+ "-moz-radial-gradient",
+ "-moz-repeating-linear-gradient",
+ "-moz-repeating-radial-gradient",
+ "inherit",
+ "initial",
+ "linear-gradient",
+ "none",
+ "radial-gradient",
+ "repeating-linear-gradient",
+ "repeating-radial-gradient",
+ "unset",
+ "url"
+ ]
+ },
+ "border-image-outset": {
+ "isInherited": false,
+ "subproperties": [
+ "border-image-outset"
+ ],
+ "supports": [
+ 6,
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "border-image-repeat": {
+ "isInherited": false,
+ "subproperties": [
+ "border-image-repeat"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "border-image-slice": {
+ "isInherited": false,
+ "subproperties": [
+ "border-image-slice"
+ ],
+ "supports": [
+ 7,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "border-image-source": {
+ "isInherited": false,
+ "subproperties": [
+ "border-image-source"
+ ],
+ "supports": [
+ 4,
+ 5,
+ 11
+ ],
+ "values": [
+ "-moz-element",
+ "-moz-image-rect",
+ "-moz-linear-gradient",
+ "-moz-radial-gradient",
+ "-moz-repeating-linear-gradient",
+ "-moz-repeating-radial-gradient",
+ "inherit",
+ "initial",
+ "linear-gradient",
+ "none",
+ "radial-gradient",
+ "repeating-linear-gradient",
+ "repeating-radial-gradient",
+ "unset",
+ "url"
+ ]
+ },
+ "border-image-width": {
+ "isInherited": false,
+ "subproperties": [
+ "border-image-width"
+ ],
+ "supports": [
+ 6,
+ 7,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "border-inline-end": {
+ "isInherited": false,
+ "subproperties": [
+ "border-inline-end-width",
+ "border-inline-end-style",
+ "border-inline-end-color"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "COLOR",
+ "-moz-calc",
+ "calc",
+ "currentColor",
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "inset",
+ "medium",
+ "none",
+ "outset",
+ "rgb",
+ "rgba",
+ "ridge",
+ "solid",
+ "thick",
+ "thin",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-inline-end-color": {
+ "isInherited": false,
+ "subproperties": [
+ "border-inline-end-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-inline-end-style": {
+ "isInherited": false,
+ "subproperties": [
+ "border-inline-end-style"
+ ],
+ "supports": [],
+ "values": [
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "inherit",
+ "initial",
+ "inset",
+ "none",
+ "outset",
+ "ridge",
+ "solid",
+ "unset"
+ ]
+ },
+ "border-inline-end-width": {
+ "isInherited": false,
+ "subproperties": [
+ "border-inline-end-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "medium",
+ "thick",
+ "thin",
+ "unset"
+ ]
+ },
+ "border-inline-start": {
+ "isInherited": false,
+ "subproperties": [
+ "border-inline-start-width",
+ "border-inline-start-style",
+ "border-inline-start-color"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "COLOR",
+ "-moz-calc",
+ "calc",
+ "currentColor",
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "inset",
+ "medium",
+ "none",
+ "outset",
+ "rgb",
+ "rgba",
+ "ridge",
+ "solid",
+ "thick",
+ "thin",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-inline-start-color": {
+ "isInherited": false,
+ "subproperties": [
+ "border-inline-start-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-inline-start-style": {
+ "isInherited": false,
+ "subproperties": [
+ "border-inline-start-style"
+ ],
+ "supports": [],
+ "values": [
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "inherit",
+ "initial",
+ "inset",
+ "none",
+ "outset",
+ "ridge",
+ "solid",
+ "unset"
+ ]
+ },
+ "border-inline-start-width": {
+ "isInherited": false,
+ "subproperties": [
+ "border-inline-start-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "medium",
+ "thick",
+ "thin",
+ "unset"
+ ]
+ },
+ "border-left": {
+ "isInherited": false,
+ "subproperties": [
+ "border-left-width",
+ "border-left-style",
+ "border-left-color"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "COLOR",
+ "-moz-calc",
+ "calc",
+ "currentColor",
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "inset",
+ "medium",
+ "none",
+ "outset",
+ "rgb",
+ "rgba",
+ "ridge",
+ "solid",
+ "thick",
+ "thin",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-left-color": {
+ "isInherited": false,
+ "subproperties": [
+ "border-left-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-left-style": {
+ "isInherited": false,
+ "subproperties": [
+ "border-left-style"
+ ],
+ "supports": [],
+ "values": [
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "inherit",
+ "initial",
+ "inset",
+ "none",
+ "outset",
+ "ridge",
+ "solid",
+ "unset"
+ ]
+ },
+ "border-left-width": {
+ "isInherited": false,
+ "subproperties": [
+ "border-left-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "medium",
+ "thick",
+ "thin",
+ "unset"
+ ]
+ },
+ "border-radius": {
+ "isInherited": false,
+ "subproperties": [
+ "border-top-left-radius",
+ "border-top-right-radius",
+ "border-bottom-right-radius",
+ "border-bottom-left-radius"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "border-right": {
+ "isInherited": false,
+ "subproperties": [
+ "border-right-width",
+ "border-right-style",
+ "border-right-color"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "COLOR",
+ "-moz-calc",
+ "calc",
+ "currentColor",
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "inset",
+ "medium",
+ "none",
+ "outset",
+ "rgb",
+ "rgba",
+ "ridge",
+ "solid",
+ "thick",
+ "thin",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-right-color": {
+ "isInherited": false,
+ "subproperties": [
+ "border-right-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-right-style": {
+ "isInherited": false,
+ "subproperties": [
+ "border-right-style"
+ ],
+ "supports": [],
+ "values": [
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "inherit",
+ "initial",
+ "inset",
+ "none",
+ "outset",
+ "ridge",
+ "solid",
+ "unset"
+ ]
+ },
+ "border-right-width": {
+ "isInherited": false,
+ "subproperties": [
+ "border-right-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "medium",
+ "thick",
+ "thin",
+ "unset"
+ ]
+ },
+ "border-spacing": {
+ "isInherited": true,
+ "subproperties": [
+ "border-spacing"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "border-style": {
+ "isInherited": false,
+ "subproperties": [
+ "border-top-style",
+ "border-right-style",
+ "border-bottom-style",
+ "border-left-style"
+ ],
+ "supports": [],
+ "values": [
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "inherit",
+ "initial",
+ "inset",
+ "none",
+ "outset",
+ "ridge",
+ "solid",
+ "unset"
+ ]
+ },
+ "border-top": {
+ "isInherited": false,
+ "subproperties": [
+ "border-top-width",
+ "border-top-style",
+ "border-top-color"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "COLOR",
+ "-moz-calc",
+ "calc",
+ "currentColor",
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "inset",
+ "medium",
+ "none",
+ "outset",
+ "rgb",
+ "rgba",
+ "ridge",
+ "solid",
+ "thick",
+ "thin",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-top-color": {
+ "isInherited": false,
+ "subproperties": [
+ "border-top-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "border-top-left-radius": {
+ "isInherited": false,
+ "subproperties": [
+ "border-top-left-radius"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "border-top-right-radius": {
+ "isInherited": false,
+ "subproperties": [
+ "border-top-right-radius"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "border-top-style": {
+ "isInherited": false,
+ "subproperties": [
+ "border-top-style"
+ ],
+ "supports": [],
+ "values": [
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "inherit",
+ "initial",
+ "inset",
+ "none",
+ "outset",
+ "ridge",
+ "solid",
+ "unset"
+ ]
+ },
+ "border-top-width": {
+ "isInherited": false,
+ "subproperties": [
+ "border-top-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "medium",
+ "thick",
+ "thin",
+ "unset"
+ ]
+ },
+ "border-width": {
+ "isInherited": false,
+ "subproperties": [
+ "border-top-width",
+ "border-right-width",
+ "border-bottom-width",
+ "border-left-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "medium",
+ "thick",
+ "thin",
+ "unset"
+ ]
+ },
+ "bottom": {
+ "isInherited": false,
+ "subproperties": [
+ "bottom"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "box-decoration-break": {
+ "isInherited": false,
+ "subproperties": [
+ "box-decoration-break"
+ ],
+ "supports": [],
+ "values": [
+ "clone",
+ "inherit",
+ "initial",
+ "slice",
+ "unset"
+ ]
+ },
+ "box-shadow": {
+ "isInherited": false,
+ "subproperties": [
+ "box-shadow"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "box-sizing": {
+ "isInherited": false,
+ "subproperties": [
+ "box-sizing"
+ ],
+ "supports": [],
+ "values": [
+ "border-box",
+ "content-box",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "caption-side": {
+ "isInherited": true,
+ "subproperties": [
+ "caption-side"
+ ],
+ "supports": [],
+ "values": [
+ "bottom",
+ "bottom-outside",
+ "inherit",
+ "initial",
+ "left",
+ "right",
+ "top",
+ "top-outside",
+ "unset"
+ ]
+ },
+ "clear": {
+ "isInherited": false,
+ "subproperties": [
+ "clear"
+ ],
+ "supports": [],
+ "values": [
+ "both",
+ "inherit",
+ "initial",
+ "inline-end",
+ "inline-start",
+ "left",
+ "none",
+ "right",
+ "unset"
+ ]
+ },
+ "clip": {
+ "isInherited": false,
+ "subproperties": [
+ "clip"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "clip-path": {
+ "isInherited": false,
+ "subproperties": [
+ "clip-path"
+ ],
+ "supports": [
+ 11
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "clip-rule": {
+ "isInherited": true,
+ "subproperties": [
+ "clip-rule"
+ ],
+ "supports": [],
+ "values": [
+ "evenodd",
+ "inherit",
+ "initial",
+ "nonzero",
+ "unset"
+ ]
+ },
+ "color": {
+ "isInherited": true,
+ "subproperties": [
+ "color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "color-adjust": {
+ "isInherited": true,
+ "subproperties": [
+ "color-adjust"
+ ],
+ "supports": [],
+ "values": [
+ "economy",
+ "exact",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "color-interpolation": {
+ "isInherited": true,
+ "subproperties": [
+ "color-interpolation"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "inherit",
+ "initial",
+ "linearrgb",
+ "srgb",
+ "unset"
+ ]
+ },
+ "color-interpolation-filters": {
+ "isInherited": true,
+ "subproperties": [
+ "color-interpolation-filters"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "inherit",
+ "initial",
+ "linearrgb",
+ "srgb",
+ "unset"
+ ]
+ },
+ "column-count": {
+ "isInherited": false,
+ "subproperties": [
+ "column-count"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "auto",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "column-fill": {
+ "isInherited": false,
+ "subproperties": [
+ "column-fill"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "balance",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "column-gap": {
+ "isInherited": false,
+ "subproperties": [
+ "column-gap"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "normal",
+ "unset"
+ ]
+ },
+ "column-rule": {
+ "isInherited": false,
+ "subproperties": [
+ "column-rule-width",
+ "column-rule-style",
+ "column-rule-color"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "COLOR",
+ "-moz-calc",
+ "calc",
+ "currentColor",
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "inset",
+ "medium",
+ "none",
+ "outset",
+ "rgb",
+ "rgba",
+ "ridge",
+ "solid",
+ "thick",
+ "thin",
+ "transparent",
+ "unset"
+ ]
+ },
+ "column-rule-color": {
+ "isInherited": false,
+ "subproperties": [
+ "column-rule-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "column-rule-style": {
+ "isInherited": false,
+ "subproperties": [
+ "column-rule-style"
+ ],
+ "supports": [],
+ "values": [
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hidden",
+ "inherit",
+ "initial",
+ "inset",
+ "none",
+ "outset",
+ "ridge",
+ "solid",
+ "unset"
+ ]
+ },
+ "column-rule-width": {
+ "isInherited": false,
+ "subproperties": [
+ "column-rule-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "medium",
+ "thick",
+ "thin",
+ "unset"
+ ]
+ },
+ "column-width": {
+ "isInherited": false,
+ "subproperties": [
+ "column-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "columns": {
+ "isInherited": false,
+ "subproperties": [
+ "column-count",
+ "column-width"
+ ],
+ "supports": [
+ 6,
+ 7
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "content": {
+ "isInherited": false,
+ "subproperties": [
+ "content"
+ ],
+ "supports": [
+ 11
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "counter-increment": {
+ "isInherited": false,
+ "subproperties": [
+ "counter-increment"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "counter-reset": {
+ "isInherited": false,
+ "subproperties": [
+ "counter-reset"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "cursor": {
+ "isInherited": true,
+ "subproperties": [
+ "cursor"
+ ],
+ "supports": [
+ 11
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "direction": {
+ "isInherited": true,
+ "subproperties": [
+ "direction"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "ltr",
+ "rtl",
+ "unset"
+ ]
+ },
+ "display": {
+ "isInherited": false,
+ "subproperties": [
+ "display"
+ ],
+ "supports": [],
+ "values": [
+ "-moz-box",
+ "-moz-deck",
+ "-moz-grid",
+ "-moz-grid-group",
+ "-moz-grid-line",
+ "-moz-groupbox",
+ "-moz-inline-box",
+ "-moz-inline-grid",
+ "-moz-inline-stack",
+ "-moz-popup",
+ "-moz-stack",
+ "-webkit-box",
+ "-webkit-flex",
+ "-webkit-inline-box",
+ "-webkit-inline-flex",
+ "block",
+ "contents",
+ "flex",
+ "grid",
+ "inherit",
+ "initial",
+ "inline",
+ "inline-block",
+ "inline-flex",
+ "inline-grid",
+ "inline-table",
+ "list-item",
+ "none",
+ "ruby",
+ "ruby-base",
+ "ruby-base-container",
+ "ruby-text",
+ "ruby-text-container",
+ "table",
+ "table-caption",
+ "table-cell",
+ "table-column",
+ "table-column-group",
+ "table-footer-group",
+ "table-header-group",
+ "table-row",
+ "table-row-group",
+ "unset"
+ ]
+ },
+ "dominant-baseline": {
+ "isInherited": false,
+ "subproperties": [
+ "dominant-baseline"
+ ],
+ "supports": [],
+ "values": [
+ "alphabetic",
+ "auto",
+ "central",
+ "hanging",
+ "ideographic",
+ "inherit",
+ "initial",
+ "mathematical",
+ "middle",
+ "no-change",
+ "reset-size",
+ "text-after-edge",
+ "text-before-edge",
+ "unset",
+ "use-script"
+ ]
+ },
+ "empty-cells": {
+ "isInherited": true,
+ "subproperties": [
+ "empty-cells"
+ ],
+ "supports": [],
+ "values": [
+ "hide",
+ "inherit",
+ "initial",
+ "show",
+ "unset"
+ ]
+ },
+ "fill": {
+ "isInherited": true,
+ "subproperties": [
+ "fill"
+ ],
+ "supports": [
+ 2,
+ 11
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "fill-opacity": {
+ "isInherited": true,
+ "subproperties": [
+ "fill-opacity"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "fill-rule": {
+ "isInherited": true,
+ "subproperties": [
+ "fill-rule"
+ ],
+ "supports": [],
+ "values": [
+ "evenodd",
+ "inherit",
+ "initial",
+ "nonzero",
+ "unset"
+ ]
+ },
+ "filter": {
+ "isInherited": false,
+ "subproperties": [
+ "filter"
+ ],
+ "supports": [
+ 11
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "flex": {
+ "isInherited": false,
+ "subproperties": [
+ "flex-grow",
+ "flex-shrink",
+ "flex-basis"
+ ],
+ "supports": [
+ 6,
+ 7,
+ 8
+ ],
+ "values": [
+ "-moz-available",
+ "-moz-calc",
+ "-moz-fit-content",
+ "-moz-max-content",
+ "-moz-min-content",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "flex-basis": {
+ "isInherited": false,
+ "subproperties": [
+ "flex-basis"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-available",
+ "-moz-calc",
+ "-moz-fit-content",
+ "-moz-max-content",
+ "-moz-min-content",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "flex-direction": {
+ "isInherited": false,
+ "subproperties": [
+ "flex-direction"
+ ],
+ "supports": [],
+ "values": [
+ "column",
+ "column-reverse",
+ "inherit",
+ "initial",
+ "row",
+ "row-reverse",
+ "unset"
+ ]
+ },
+ "flex-flow": {
+ "isInherited": false,
+ "subproperties": [
+ "flex-direction",
+ "flex-wrap"
+ ],
+ "supports": [],
+ "values": [
+ "column",
+ "column-reverse",
+ "inherit",
+ "initial",
+ "nowrap",
+ "row",
+ "row-reverse",
+ "unset",
+ "wrap",
+ "wrap-reverse"
+ ]
+ },
+ "flex-grow": {
+ "isInherited": false,
+ "subproperties": [
+ "flex-grow"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "flex-shrink": {
+ "isInherited": false,
+ "subproperties": [
+ "flex-shrink"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "flex-wrap": {
+ "isInherited": false,
+ "subproperties": [
+ "flex-wrap"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "nowrap",
+ "unset",
+ "wrap",
+ "wrap-reverse"
+ ]
+ },
+ "float": {
+ "isInherited": false,
+ "subproperties": [
+ "float"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "inline-end",
+ "inline-start",
+ "left",
+ "none",
+ "right",
+ "unset"
+ ]
+ },
+ "flood-color": {
+ "isInherited": false,
+ "subproperties": [
+ "flood-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "flood-opacity": {
+ "isInherited": false,
+ "subproperties": [
+ "flood-opacity"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "font": {
+ "isInherited": true,
+ "subproperties": [
+ "font-family",
+ "font-style",
+ "font-weight",
+ "font-size",
+ "line-height",
+ "font-size-adjust",
+ "font-stretch",
+ "-x-system-font",
+ "font-feature-settings",
+ "font-language-override",
+ "font-kerning",
+ "font-synthesis",
+ "font-variant-alternates",
+ "font-variant-caps",
+ "font-variant-east-asian",
+ "font-variant-ligatures",
+ "font-variant-numeric",
+ "font-variant-position"
+ ],
+ "supports": [
+ 6,
+ 7,
+ 8
+ ],
+ "values": [
+ "-moz-block-height",
+ "-moz-calc",
+ "all-petite-caps",
+ "all-small-caps",
+ "auto",
+ "calc",
+ "condensed",
+ "expanded",
+ "extra-condensed",
+ "extra-expanded",
+ "inherit",
+ "initial",
+ "italic",
+ "large",
+ "larger",
+ "medium",
+ "none",
+ "normal",
+ "oblique",
+ "petite-caps",
+ "semi-condensed",
+ "semi-expanded",
+ "small",
+ "small-caps",
+ "smaller",
+ "sub",
+ "super",
+ "titling-caps",
+ "ultra-condensed",
+ "ultra-expanded",
+ "unicase",
+ "unset",
+ "x-large",
+ "x-small",
+ "xx-large",
+ "xx-small"
+ ]
+ },
+ "font-family": {
+ "isInherited": true,
+ "subproperties": [
+ "font-family"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "font-feature-settings": {
+ "isInherited": true,
+ "subproperties": [
+ "font-feature-settings"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "font-kerning": {
+ "isInherited": true,
+ "subproperties": [
+ "font-kerning"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "inherit",
+ "initial",
+ "none",
+ "normal",
+ "unset"
+ ]
+ },
+ "font-language-override": {
+ "isInherited": true,
+ "subproperties": [
+ "font-language-override"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "normal",
+ "unset"
+ ]
+ },
+ "font-size": {
+ "isInherited": true,
+ "subproperties": [
+ "font-size"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "large",
+ "larger",
+ "medium",
+ "small",
+ "smaller",
+ "unset",
+ "x-large",
+ "x-small",
+ "xx-large",
+ "xx-small"
+ ]
+ },
+ "font-size-adjust": {
+ "isInherited": true,
+ "subproperties": [
+ "font-size-adjust"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "font-stretch": {
+ "isInherited": true,
+ "subproperties": [
+ "font-stretch"
+ ],
+ "supports": [],
+ "values": [
+ "condensed",
+ "expanded",
+ "extra-condensed",
+ "extra-expanded",
+ "inherit",
+ "initial",
+ "normal",
+ "semi-condensed",
+ "semi-expanded",
+ "ultra-condensed",
+ "ultra-expanded",
+ "unset"
+ ]
+ },
+ "font-style": {
+ "isInherited": true,
+ "subproperties": [
+ "font-style"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "italic",
+ "normal",
+ "oblique",
+ "unset"
+ ]
+ },
+ "font-synthesis": {
+ "isInherited": true,
+ "subproperties": [
+ "font-synthesis"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "font-variant": {
+ "isInherited": true,
+ "subproperties": [
+ "font-variant-alternates",
+ "font-variant-caps",
+ "font-variant-east-asian",
+ "font-variant-ligatures",
+ "font-variant-numeric",
+ "font-variant-position"
+ ],
+ "supports": [],
+ "values": [
+ "all-petite-caps",
+ "all-small-caps",
+ "inherit",
+ "initial",
+ "normal",
+ "petite-caps",
+ "small-caps",
+ "sub",
+ "super",
+ "titling-caps",
+ "unicase",
+ "unset"
+ ]
+ },
+ "font-variant-alternates": {
+ "isInherited": true,
+ "subproperties": [
+ "font-variant-alternates"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "font-variant-caps": {
+ "isInherited": true,
+ "subproperties": [
+ "font-variant-caps"
+ ],
+ "supports": [],
+ "values": [
+ "all-petite-caps",
+ "all-small-caps",
+ "inherit",
+ "initial",
+ "normal",
+ "petite-caps",
+ "small-caps",
+ "titling-caps",
+ "unicase",
+ "unset"
+ ]
+ },
+ "font-variant-east-asian": {
+ "isInherited": true,
+ "subproperties": [
+ "font-variant-east-asian"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "font-variant-ligatures": {
+ "isInherited": true,
+ "subproperties": [
+ "font-variant-ligatures"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "font-variant-numeric": {
+ "isInherited": true,
+ "subproperties": [
+ "font-variant-numeric"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "font-variant-position": {
+ "isInherited": true,
+ "subproperties": [
+ "font-variant-position"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "normal",
+ "sub",
+ "super",
+ "unset"
+ ]
+ },
+ "font-weight": {
+ "isInherited": true,
+ "subproperties": [
+ "font-weight"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-template-areas",
+ "grid-template-rows",
+ "grid-template-columns",
+ "grid-auto-flow",
+ "grid-auto-rows",
+ "grid-auto-columns",
+ "grid-row-gap",
+ "grid-column-gap"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-area": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-row-start",
+ "grid-column-start",
+ "grid-row-end",
+ "grid-column-end"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-auto-columns": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-auto-columns"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-auto-flow": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-auto-flow"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-auto-rows": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-auto-rows"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-column": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-column-start",
+ "grid-column-end"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-column-end": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-column-end"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-column-gap": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-column-gap"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-column-start": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-column-start"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-gap": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-row-gap",
+ "grid-column-gap"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-row": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-row-start",
+ "grid-row-end"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-row-end": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-row-end"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-row-gap": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-row-gap"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-row-start": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-row-start"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-template": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-template-areas",
+ "grid-template-rows",
+ "grid-template-columns"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-template-areas": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-template-areas"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-template-columns": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-template-columns"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "grid-template-rows": {
+ "isInherited": false,
+ "subproperties": [
+ "grid-template-rows"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "height": {
+ "isInherited": false,
+ "subproperties": [
+ "height"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-available",
+ "-moz-calc",
+ "-moz-fit-content",
+ "-moz-max-content",
+ "-moz-min-content",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "hyphens": {
+ "isInherited": true,
+ "subproperties": [
+ "hyphens"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "inherit",
+ "initial",
+ "manual",
+ "none",
+ "unset"
+ ]
+ },
+ "image-orientation": {
+ "isInherited": true,
+ "subproperties": [
+ "image-orientation"
+ ],
+ "supports": [
+ 1
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "image-rendering": {
+ "isInherited": true,
+ "subproperties": [
+ "image-rendering"
+ ],
+ "supports": [],
+ "values": [
+ "-moz-crisp-edges",
+ "auto",
+ "inherit",
+ "initial",
+ "optimizequality",
+ "optimizespeed",
+ "unset"
+ ]
+ },
+ "ime-mode": {
+ "isInherited": false,
+ "subproperties": [
+ "ime-mode"
+ ],
+ "supports": [],
+ "values": [
+ "active",
+ "auto",
+ "disabled",
+ "inactive",
+ "inherit",
+ "initial",
+ "normal",
+ "unset"
+ ]
+ },
+ "inline-size": {
+ "isInherited": false,
+ "subproperties": [
+ "inline-size"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-available",
+ "-moz-calc",
+ "-moz-fit-content",
+ "-moz-max-content",
+ "-moz-min-content",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "isolation": {
+ "isInherited": false,
+ "subproperties": [
+ "isolation"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "inherit",
+ "initial",
+ "isolate",
+ "unset"
+ ]
+ },
+ "justify-content": {
+ "isInherited": false,
+ "subproperties": [
+ "justify-content"
+ ],
+ "supports": [],
+ "values": [
+ "baseline",
+ "center",
+ "end",
+ "flex-end",
+ "flex-start",
+ "inherit",
+ "initial",
+ "last baseline",
+ "left",
+ "normal",
+ "right",
+ "space-around",
+ "space-between",
+ "space-evenly",
+ "start",
+ "stretch",
+ "unset"
+ ]
+ },
+ "justify-items": {
+ "isInherited": false,
+ "subproperties": [
+ "justify-items"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "baseline",
+ "center",
+ "end",
+ "flex-end",
+ "flex-start",
+ "inherit",
+ "initial",
+ "last baseline",
+ "left",
+ "normal",
+ "right",
+ "self-end",
+ "self-start",
+ "start",
+ "stretch",
+ "unset"
+ ]
+ },
+ "justify-self": {
+ "isInherited": false,
+ "subproperties": [
+ "justify-self"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "baseline",
+ "center",
+ "end",
+ "flex-end",
+ "flex-start",
+ "inherit",
+ "initial",
+ "last baseline",
+ "left",
+ "normal",
+ "right",
+ "self-end",
+ "self-start",
+ "start",
+ "stretch",
+ "unset"
+ ]
+ },
+ "left": {
+ "isInherited": false,
+ "subproperties": [
+ "left"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "letter-spacing": {
+ "isInherited": true,
+ "subproperties": [
+ "letter-spacing"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "normal",
+ "unset"
+ ]
+ },
+ "lighting-color": {
+ "isInherited": false,
+ "subproperties": [
+ "lighting-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "line-height": {
+ "isInherited": true,
+ "subproperties": [
+ "line-height"
+ ],
+ "supports": [
+ 6,
+ 7,
+ 8
+ ],
+ "values": [
+ "-moz-block-height",
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "normal",
+ "unset"
+ ]
+ },
+ "list-style": {
+ "isInherited": true,
+ "subproperties": [
+ "list-style-type",
+ "list-style-image",
+ "list-style-position"
+ ],
+ "supports": [
+ 11
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "inside",
+ "none",
+ "outside",
+ "unset",
+ "url"
+ ]
+ },
+ "list-style-image": {
+ "isInherited": true,
+ "subproperties": [
+ "list-style-image"
+ ],
+ "supports": [
+ 11
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "none",
+ "unset",
+ "url"
+ ]
+ },
+ "list-style-position": {
+ "isInherited": true,
+ "subproperties": [
+ "list-style-position"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "inside",
+ "outside",
+ "unset"
+ ]
+ },
+ "list-style-type": {
+ "isInherited": true,
+ "subproperties": [
+ "list-style-type"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "margin": {
+ "isInherited": false,
+ "subproperties": [
+ "margin-top",
+ "margin-right",
+ "margin-bottom",
+ "margin-left"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "margin-block-end": {
+ "isInherited": false,
+ "subproperties": [
+ "margin-block-end"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "margin-block-start": {
+ "isInherited": false,
+ "subproperties": [
+ "margin-block-start"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "margin-bottom": {
+ "isInherited": false,
+ "subproperties": [
+ "margin-bottom"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "margin-inline-end": {
+ "isInherited": false,
+ "subproperties": [
+ "margin-inline-end"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "margin-inline-start": {
+ "isInherited": false,
+ "subproperties": [
+ "margin-inline-start"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "margin-left": {
+ "isInherited": false,
+ "subproperties": [
+ "margin-left"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "margin-right": {
+ "isInherited": false,
+ "subproperties": [
+ "margin-right"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "margin-top": {
+ "isInherited": false,
+ "subproperties": [
+ "margin-top"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "marker": {
+ "isInherited": true,
+ "subproperties": [
+ "marker-start",
+ "marker-mid",
+ "marker-end"
+ ],
+ "supports": [
+ 11
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "none",
+ "unset",
+ "url"
+ ]
+ },
+ "marker-end": {
+ "isInherited": true,
+ "subproperties": [
+ "marker-end"
+ ],
+ "supports": [
+ 11
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "none",
+ "unset",
+ "url"
+ ]
+ },
+ "marker-mid": {
+ "isInherited": true,
+ "subproperties": [
+ "marker-mid"
+ ],
+ "supports": [
+ 11
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "none",
+ "unset",
+ "url"
+ ]
+ },
+ "marker-start": {
+ "isInherited": true,
+ "subproperties": [
+ "marker-start"
+ ],
+ "supports": [
+ 11
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "none",
+ "unset",
+ "url"
+ ]
+ },
+ "mask": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-image",
+ "mask-repeat",
+ "mask-position-x",
+ "mask-position-y",
+ "mask-clip",
+ "mask-origin",
+ "mask-size",
+ "mask-composite",
+ "mask-mode"
+ ],
+ "supports": [
+ 4,
+ 5,
+ 6,
+ 8,
+ 11
+ ],
+ "values": [
+ "-moz-element",
+ "-moz-image-rect",
+ "-moz-linear-gradient",
+ "-moz-radial-gradient",
+ "-moz-repeating-linear-gradient",
+ "-moz-repeating-radial-gradient",
+ "add",
+ "alpha",
+ "border-box",
+ "content-box",
+ "exclude",
+ "inherit",
+ "initial",
+ "intersect",
+ "linear-gradient",
+ "luminance",
+ "match-source",
+ "no-repeat",
+ "none",
+ "padding-box",
+ "radial-gradient",
+ "repeat",
+ "repeat-x",
+ "repeat-y",
+ "repeating-linear-gradient",
+ "repeating-radial-gradient",
+ "round",
+ "space",
+ "subtract",
+ "unset",
+ "url"
+ ]
+ },
+ "mask-clip": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-clip"
+ ],
+ "supports": [],
+ "values": [
+ "border-box",
+ "content-box",
+ "inherit",
+ "initial",
+ "padding-box",
+ "unset"
+ ]
+ },
+ "mask-composite": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-composite"
+ ],
+ "supports": [],
+ "values": [
+ "add",
+ "exclude",
+ "inherit",
+ "initial",
+ "intersect",
+ "subtract",
+ "unset"
+ ]
+ },
+ "mask-image": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-image"
+ ],
+ "supports": [
+ 4,
+ 5,
+ 11
+ ],
+ "values": [
+ "-moz-element",
+ "-moz-image-rect",
+ "-moz-linear-gradient",
+ "-moz-radial-gradient",
+ "-moz-repeating-linear-gradient",
+ "-moz-repeating-radial-gradient",
+ "inherit",
+ "initial",
+ "linear-gradient",
+ "none",
+ "radial-gradient",
+ "repeating-linear-gradient",
+ "repeating-radial-gradient",
+ "unset",
+ "url"
+ ]
+ },
+ "mask-mode": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-mode"
+ ],
+ "supports": [],
+ "values": [
+ "alpha",
+ "inherit",
+ "initial",
+ "luminance",
+ "match-source",
+ "unset"
+ ]
+ },
+ "mask-origin": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-origin"
+ ],
+ "supports": [],
+ "values": [
+ "border-box",
+ "content-box",
+ "inherit",
+ "initial",
+ "padding-box",
+ "unset"
+ ]
+ },
+ "mask-position": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-position-x",
+ "mask-position-y"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "mask-position-x": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-position-x"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "mask-position-y": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-position-y"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "mask-repeat": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-repeat"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "no-repeat",
+ "repeat",
+ "repeat-x",
+ "repeat-y",
+ "round",
+ "space",
+ "unset"
+ ]
+ },
+ "mask-size": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-size"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "mask-type": {
+ "isInherited": false,
+ "subproperties": [
+ "mask-type"
+ ],
+ "supports": [],
+ "values": [
+ "alpha",
+ "inherit",
+ "initial",
+ "luminance",
+ "unset"
+ ]
+ },
+ "max-block-size": {
+ "isInherited": false,
+ "subproperties": [
+ "max-block-size"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "max-height": {
+ "isInherited": false,
+ "subproperties": [
+ "max-height"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-available",
+ "-moz-calc",
+ "-moz-fit-content",
+ "-moz-max-content",
+ "-moz-min-content",
+ "calc",
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "max-inline-size": {
+ "isInherited": false,
+ "subproperties": [
+ "max-inline-size"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-available",
+ "-moz-calc",
+ "-moz-fit-content",
+ "-moz-max-content",
+ "-moz-min-content",
+ "calc",
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "max-width": {
+ "isInherited": false,
+ "subproperties": [
+ "max-width"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-available",
+ "-moz-calc",
+ "-moz-fit-content",
+ "-moz-max-content",
+ "-moz-min-content",
+ "calc",
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "min-block-size": {
+ "isInherited": false,
+ "subproperties": [
+ "min-block-size"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "min-height": {
+ "isInherited": false,
+ "subproperties": [
+ "min-height"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-available",
+ "-moz-calc",
+ "-moz-fit-content",
+ "-moz-max-content",
+ "-moz-min-content",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "min-inline-size": {
+ "isInherited": false,
+ "subproperties": [
+ "min-inline-size"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-available",
+ "-moz-calc",
+ "-moz-fit-content",
+ "-moz-max-content",
+ "-moz-min-content",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "min-width": {
+ "isInherited": false,
+ "subproperties": [
+ "min-width"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-available",
+ "-moz-calc",
+ "-moz-fit-content",
+ "-moz-max-content",
+ "-moz-min-content",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "mix-blend-mode": {
+ "isInherited": false,
+ "subproperties": [
+ "mix-blend-mode"
+ ],
+ "supports": [],
+ "values": [
+ "color",
+ "color-burn",
+ "color-dodge",
+ "darken",
+ "difference",
+ "exclusion",
+ "hard-light",
+ "hue",
+ "inherit",
+ "initial",
+ "lighten",
+ "luminosity",
+ "multiply",
+ "normal",
+ "overlay",
+ "saturation",
+ "screen",
+ "soft-light",
+ "unset"
+ ]
+ },
+ "object-fit": {
+ "isInherited": false,
+ "subproperties": [
+ "object-fit"
+ ],
+ "supports": [],
+ "values": [
+ "contain",
+ "cover",
+ "fill",
+ "inherit",
+ "initial",
+ "none",
+ "scale-down",
+ "unset"
+ ]
+ },
+ "object-position": {
+ "isInherited": false,
+ "subproperties": [
+ "object-position"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "offset-block-end": {
+ "isInherited": false,
+ "subproperties": [
+ "offset-block-end"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "offset-block-start": {
+ "isInherited": false,
+ "subproperties": [
+ "offset-block-start"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "offset-inline-end": {
+ "isInherited": false,
+ "subproperties": [
+ "offset-inline-end"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "offset-inline-start": {
+ "isInherited": false,
+ "subproperties": [
+ "offset-inline-start"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "opacity": {
+ "isInherited": false,
+ "subproperties": [
+ "opacity"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "order": {
+ "isInherited": false,
+ "subproperties": [
+ "order"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "outline": {
+ "isInherited": false,
+ "subproperties": [
+ "outline-width",
+ "outline-style",
+ "outline-color"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "COLOR",
+ "-moz-calc",
+ "auto",
+ "calc",
+ "currentColor",
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "inset",
+ "medium",
+ "none",
+ "outset",
+ "rgb",
+ "rgba",
+ "ridge",
+ "solid",
+ "thick",
+ "thin",
+ "transparent",
+ "unset"
+ ]
+ },
+ "outline-color": {
+ "isInherited": false,
+ "subproperties": [
+ "outline-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "outline-offset": {
+ "isInherited": false,
+ "subproperties": [
+ "outline-offset"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "outline-style": {
+ "isInherited": false,
+ "subproperties": [
+ "outline-style"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "dashed",
+ "dotted",
+ "double",
+ "groove",
+ "inherit",
+ "initial",
+ "inset",
+ "none",
+ "outset",
+ "ridge",
+ "solid",
+ "unset"
+ ]
+ },
+ "outline-width": {
+ "isInherited": false,
+ "subproperties": [
+ "outline-width"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "medium",
+ "thick",
+ "thin",
+ "unset"
+ ]
+ },
+ "overflow": {
+ "isInherited": false,
+ "subproperties": [
+ "overflow-x",
+ "overflow-y"
+ ],
+ "supports": [],
+ "values": [
+ "-moz-hidden-unscrollable",
+ "auto",
+ "hidden",
+ "inherit",
+ "initial",
+ "scroll",
+ "unset",
+ "visible"
+ ]
+ },
+ "overflow-wrap": {
+ "isInherited": true,
+ "subproperties": [
+ "overflow-wrap"
+ ],
+ "supports": [],
+ "values": [
+ "break-word",
+ "inherit",
+ "initial",
+ "normal",
+ "unset"
+ ]
+ },
+ "overflow-x": {
+ "isInherited": false,
+ "subproperties": [
+ "overflow-x"
+ ],
+ "supports": [],
+ "values": [
+ "-moz-hidden-unscrollable",
+ "auto",
+ "hidden",
+ "inherit",
+ "initial",
+ "scroll",
+ "unset",
+ "visible"
+ ]
+ },
+ "overflow-y": {
+ "isInherited": false,
+ "subproperties": [
+ "overflow-y"
+ ],
+ "supports": [],
+ "values": [
+ "-moz-hidden-unscrollable",
+ "auto",
+ "hidden",
+ "inherit",
+ "initial",
+ "scroll",
+ "unset",
+ "visible"
+ ]
+ },
+ "padding": {
+ "isInherited": false,
+ "subproperties": [
+ "padding-top",
+ "padding-right",
+ "padding-bottom",
+ "padding-left"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "padding-block-end": {
+ "isInherited": false,
+ "subproperties": [
+ "padding-block-end"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "padding-block-start": {
+ "isInherited": false,
+ "subproperties": [
+ "padding-block-start"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "padding-bottom": {
+ "isInherited": false,
+ "subproperties": [
+ "padding-bottom"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "padding-inline-end": {
+ "isInherited": false,
+ "subproperties": [
+ "padding-inline-end"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "padding-inline-start": {
+ "isInherited": false,
+ "subproperties": [
+ "padding-inline-start"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "padding-left": {
+ "isInherited": false,
+ "subproperties": [
+ "padding-left"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "padding-right": {
+ "isInherited": false,
+ "subproperties": [
+ "padding-right"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "padding-top": {
+ "isInherited": false,
+ "subproperties": [
+ "padding-top"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "page-break-after": {
+ "isInherited": false,
+ "subproperties": [
+ "page-break-after"
+ ],
+ "supports": [],
+ "values": [
+ "always",
+ "auto",
+ "avoid",
+ "inherit",
+ "initial",
+ "left",
+ "right",
+ "unset"
+ ]
+ },
+ "page-break-before": {
+ "isInherited": false,
+ "subproperties": [
+ "page-break-before"
+ ],
+ "supports": [],
+ "values": [
+ "always",
+ "auto",
+ "avoid",
+ "inherit",
+ "initial",
+ "left",
+ "right",
+ "unset"
+ ]
+ },
+ "page-break-inside": {
+ "isInherited": false,
+ "subproperties": [
+ "page-break-inside"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "avoid",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "paint-order": {
+ "isInherited": true,
+ "subproperties": [
+ "paint-order"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "perspective": {
+ "isInherited": false,
+ "subproperties": [
+ "perspective"
+ ],
+ "supports": [
+ 6
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "perspective-origin": {
+ "isInherited": false,
+ "subproperties": [
+ "perspective-origin"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "place-content": {
+ "isInherited": false,
+ "subproperties": [
+ "align-content",
+ "justify-content"
+ ],
+ "supports": [],
+ "values": [
+ "baseline",
+ "center",
+ "end",
+ "flex-end",
+ "flex-start",
+ "inherit",
+ "initial",
+ "last baseline",
+ "left",
+ "normal",
+ "right",
+ "space-around",
+ "space-between",
+ "space-evenly",
+ "start",
+ "stretch",
+ "unset"
+ ]
+ },
+ "place-items": {
+ "isInherited": false,
+ "subproperties": [
+ "align-items",
+ "justify-items"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "baseline",
+ "center",
+ "end",
+ "flex-end",
+ "flex-start",
+ "inherit",
+ "initial",
+ "last baseline",
+ "left",
+ "normal",
+ "right",
+ "self-end",
+ "self-start",
+ "start",
+ "stretch",
+ "unset"
+ ]
+ },
+ "place-self": {
+ "isInherited": false,
+ "subproperties": [
+ "align-self",
+ "justify-self"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "baseline",
+ "center",
+ "end",
+ "flex-end",
+ "flex-start",
+ "inherit",
+ "initial",
+ "last baseline",
+ "left",
+ "normal",
+ "right",
+ "self-end",
+ "self-start",
+ "start",
+ "stretch",
+ "unset"
+ ]
+ },
+ "pointer-events": {
+ "isInherited": true,
+ "subproperties": [
+ "pointer-events"
+ ],
+ "supports": [],
+ "values": [
+ "all",
+ "auto",
+ "fill",
+ "inherit",
+ "initial",
+ "none",
+ "painted",
+ "stroke",
+ "unset",
+ "visible",
+ "visiblefill",
+ "visiblepainted",
+ "visiblestroke"
+ ]
+ },
+ "position": {
+ "isInherited": false,
+ "subproperties": [
+ "position"
+ ],
+ "supports": [],
+ "values": [
+ "absolute",
+ "fixed",
+ "inherit",
+ "initial",
+ "relative",
+ "static",
+ "sticky",
+ "unset"
+ ]
+ },
+ "quotes": {
+ "isInherited": true,
+ "subproperties": [
+ "quotes"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "resize": {
+ "isInherited": false,
+ "subproperties": [
+ "resize"
+ ],
+ "supports": [],
+ "values": [
+ "both",
+ "horizontal",
+ "inherit",
+ "initial",
+ "none",
+ "unset",
+ "vertical"
+ ]
+ },
+ "right": {
+ "isInherited": false,
+ "subproperties": [
+ "right"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "ruby-align": {
+ "isInherited": true,
+ "subproperties": [
+ "ruby-align"
+ ],
+ "supports": [],
+ "values": [
+ "center",
+ "inherit",
+ "initial",
+ "space-around",
+ "space-between",
+ "start",
+ "unset"
+ ]
+ },
+ "ruby-position": {
+ "isInherited": true,
+ "subproperties": [
+ "ruby-position"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "over",
+ "under",
+ "unset"
+ ]
+ },
+ "scroll-behavior": {
+ "isInherited": false,
+ "subproperties": [
+ "scroll-behavior"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "inherit",
+ "initial",
+ "smooth",
+ "unset"
+ ]
+ },
+ "scroll-snap-coordinate": {
+ "isInherited": false,
+ "subproperties": [
+ "scroll-snap-coordinate"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "scroll-snap-destination": {
+ "isInherited": false,
+ "subproperties": [
+ "scroll-snap-destination"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "scroll-snap-points-x": {
+ "isInherited": false,
+ "subproperties": [
+ "scroll-snap-points-x"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "scroll-snap-points-y": {
+ "isInherited": false,
+ "subproperties": [
+ "scroll-snap-points-y"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "scroll-snap-type": {
+ "isInherited": false,
+ "subproperties": [
+ "scroll-snap-type-x",
+ "scroll-snap-type-y"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "mandatory",
+ "none",
+ "proximity",
+ "unset"
+ ]
+ },
+ "scroll-snap-type-x": {
+ "isInherited": false,
+ "subproperties": [
+ "scroll-snap-type-x"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "mandatory",
+ "none",
+ "proximity",
+ "unset"
+ ]
+ },
+ "scroll-snap-type-y": {
+ "isInherited": false,
+ "subproperties": [
+ "scroll-snap-type-y"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "mandatory",
+ "none",
+ "proximity",
+ "unset"
+ ]
+ },
+ "shape-rendering": {
+ "isInherited": true,
+ "subproperties": [
+ "shape-rendering"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "crispedges",
+ "geometricprecision",
+ "inherit",
+ "initial",
+ "optimizespeed",
+ "unset"
+ ]
+ },
+ "stop-color": {
+ "isInherited": false,
+ "subproperties": [
+ "stop-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "stop-opacity": {
+ "isInherited": false,
+ "subproperties": [
+ "stop-opacity"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "stroke": {
+ "isInherited": true,
+ "subproperties": [
+ "stroke"
+ ],
+ "supports": [
+ 2,
+ 11
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "stroke-dasharray": {
+ "isInherited": true,
+ "subproperties": [
+ "stroke-dasharray"
+ ],
+ "supports": [
+ 6,
+ 7,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "stroke-dashoffset": {
+ "isInherited": true,
+ "subproperties": [
+ "stroke-dashoffset"
+ ],
+ "supports": [
+ 6,
+ 7,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "stroke-linecap": {
+ "isInherited": true,
+ "subproperties": [
+ "stroke-linecap"
+ ],
+ "supports": [],
+ "values": [
+ "butt",
+ "inherit",
+ "initial",
+ "round",
+ "square",
+ "unset"
+ ]
+ },
+ "stroke-linejoin": {
+ "isInherited": true,
+ "subproperties": [
+ "stroke-linejoin"
+ ],
+ "supports": [],
+ "values": [
+ "bevel",
+ "inherit",
+ "initial",
+ "miter",
+ "round",
+ "unset"
+ ]
+ },
+ "stroke-miterlimit": {
+ "isInherited": true,
+ "subproperties": [
+ "stroke-miterlimit"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "stroke-opacity": {
+ "isInherited": true,
+ "subproperties": [
+ "stroke-opacity"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "stroke-width": {
+ "isInherited": true,
+ "subproperties": [
+ "stroke-width"
+ ],
+ "supports": [
+ 6,
+ 7,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "table-layout": {
+ "isInherited": false,
+ "subproperties": [
+ "table-layout"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "fixed",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "text-align": {
+ "isInherited": true,
+ "subproperties": [
+ "text-align"
+ ],
+ "supports": [],
+ "values": [
+ "-moz-center",
+ "-moz-left",
+ "-moz-right",
+ "center",
+ "end",
+ "inherit",
+ "initial",
+ "justify",
+ "left",
+ "right",
+ "start",
+ "unset"
+ ]
+ },
+ "text-align-last": {
+ "isInherited": true,
+ "subproperties": [
+ "text-align-last"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "center",
+ "end",
+ "inherit",
+ "initial",
+ "justify",
+ "left",
+ "right",
+ "start",
+ "unset"
+ ]
+ },
+ "text-anchor": {
+ "isInherited": true,
+ "subproperties": [
+ "text-anchor"
+ ],
+ "supports": [],
+ "values": [
+ "end",
+ "inherit",
+ "initial",
+ "middle",
+ "start",
+ "unset"
+ ]
+ },
+ "text-combine-upright": {
+ "isInherited": true,
+ "subproperties": [
+ "text-combine-upright"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "text-decoration": {
+ "isInherited": false,
+ "subproperties": [
+ "text-decoration-color",
+ "text-decoration-line",
+ "text-decoration-style"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "-moz-none",
+ "currentColor",
+ "dashed",
+ "dotted",
+ "double",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "solid",
+ "transparent",
+ "unset",
+ "wavy"
+ ]
+ },
+ "text-decoration-color": {
+ "isInherited": false,
+ "subproperties": [
+ "text-decoration-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "text-decoration-line": {
+ "isInherited": false,
+ "subproperties": [
+ "text-decoration-line"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "text-decoration-style": {
+ "isInherited": false,
+ "subproperties": [
+ "text-decoration-style"
+ ],
+ "supports": [],
+ "values": [
+ "-moz-none",
+ "dashed",
+ "dotted",
+ "double",
+ "inherit",
+ "initial",
+ "solid",
+ "unset",
+ "wavy"
+ ]
+ },
+ "text-emphasis": {
+ "isInherited": true,
+ "subproperties": [
+ "text-emphasis-style",
+ "text-emphasis-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "text-emphasis-color": {
+ "isInherited": true,
+ "subproperties": [
+ "text-emphasis-color"
+ ],
+ "supports": [
+ 2
+ ],
+ "values": [
+ "COLOR",
+ "currentColor",
+ "hsl",
+ "hsla",
+ "inherit",
+ "initial",
+ "rgb",
+ "rgba",
+ "transparent",
+ "unset"
+ ]
+ },
+ "text-emphasis-position": {
+ "isInherited": true,
+ "subproperties": [
+ "text-emphasis-position"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "text-emphasis-style": {
+ "isInherited": true,
+ "subproperties": [
+ "text-emphasis-style"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "text-indent": {
+ "isInherited": true,
+ "subproperties": [
+ "text-indent"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "text-orientation": {
+ "isInherited": true,
+ "subproperties": [
+ "text-orientation"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "mixed",
+ "sideways",
+ "sideways-right",
+ "unset",
+ "upright"
+ ]
+ },
+ "text-overflow": {
+ "isInherited": false,
+ "subproperties": [
+ "text-overflow"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "text-rendering": {
+ "isInherited": true,
+ "subproperties": [
+ "text-rendering"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "geometricprecision",
+ "inherit",
+ "initial",
+ "optimizelegibility",
+ "optimizespeed",
+ "unset"
+ ]
+ },
+ "text-shadow": {
+ "isInherited": true,
+ "subproperties": [
+ "text-shadow"
+ ],
+ "supports": [
+ 2,
+ 6
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "text-transform": {
+ "isInherited": true,
+ "subproperties": [
+ "text-transform"
+ ],
+ "supports": [],
+ "values": [
+ "capitalize",
+ "full-width",
+ "inherit",
+ "initial",
+ "lowercase",
+ "none",
+ "unset",
+ "uppercase"
+ ]
+ },
+ "top": {
+ "isInherited": false,
+ "subproperties": [
+ "top"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "touch-action": {
+ "isInherited": false,
+ "subproperties": [
+ "touch-action"
+ ],
+ "supports": [],
+ "values": [
+ "auto",
+ "inherit",
+ "initial",
+ "manipulation",
+ "none",
+ "pan-x",
+ "pan-y",
+ "unset"
+ ]
+ },
+ "transform": {
+ "isInherited": false,
+ "subproperties": [
+ "transform"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "transform-box": {
+ "isInherited": false,
+ "subproperties": [
+ "transform-box"
+ ],
+ "supports": [],
+ "values": [
+ "border-box",
+ "fill-box",
+ "inherit",
+ "initial",
+ "unset",
+ "view-box"
+ ]
+ },
+ "transform-origin": {
+ "isInherited": false,
+ "subproperties": [
+ "transform-origin"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "transform-style": {
+ "isInherited": false,
+ "subproperties": [
+ "transform-style"
+ ],
+ "supports": [],
+ "values": [
+ "flat",
+ "inherit",
+ "initial",
+ "preserve-3d",
+ "unset"
+ ]
+ },
+ "transition": {
+ "isInherited": false,
+ "subproperties": [
+ "transition-property",
+ "transition-duration",
+ "transition-timing-function",
+ "transition-delay"
+ ],
+ "supports": [
+ 9,
+ 10
+ ],
+ "values": [
+ "all",
+ "cubic-bezier",
+ "ease",
+ "ease-in",
+ "ease-in-out",
+ "ease-out",
+ "inherit",
+ "initial",
+ "linear",
+ "none",
+ "step-end",
+ "step-start",
+ "steps",
+ "unset"
+ ]
+ },
+ "transition-delay": {
+ "isInherited": false,
+ "subproperties": [
+ "transition-delay"
+ ],
+ "supports": [
+ 9
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "transition-duration": {
+ "isInherited": false,
+ "subproperties": [
+ "transition-duration"
+ ],
+ "supports": [
+ 9
+ ],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "transition-property": {
+ "isInherited": false,
+ "subproperties": [
+ "transition-property"
+ ],
+ "supports": [],
+ "values": [
+ "all",
+ "inherit",
+ "initial",
+ "none",
+ "unset"
+ ]
+ },
+ "transition-timing-function": {
+ "isInherited": false,
+ "subproperties": [
+ "transition-timing-function"
+ ],
+ "supports": [
+ 10
+ ],
+ "values": [
+ "cubic-bezier",
+ "ease",
+ "ease-in",
+ "ease-in-out",
+ "ease-out",
+ "inherit",
+ "initial",
+ "linear",
+ "step-end",
+ "step-start",
+ "steps",
+ "unset"
+ ]
+ },
+ "unicode-bidi": {
+ "isInherited": false,
+ "subproperties": [
+ "unicode-bidi"
+ ],
+ "supports": [],
+ "values": [
+ "-moz-isolate",
+ "-moz-isolate-override",
+ "-moz-plaintext",
+ "bidi-override",
+ "embed",
+ "inherit",
+ "initial",
+ "isolate",
+ "isolate-override",
+ "normal",
+ "plaintext",
+ "unset"
+ ]
+ },
+ "vector-effect": {
+ "isInherited": false,
+ "subproperties": [
+ "vector-effect"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "non-scaling-stroke",
+ "none",
+ "unset"
+ ]
+ },
+ "vertical-align": {
+ "isInherited": false,
+ "subproperties": [
+ "vertical-align"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "-moz-middle-with-baseline",
+ "baseline",
+ "bottom",
+ "calc",
+ "inherit",
+ "initial",
+ "middle",
+ "sub",
+ "super",
+ "text-bottom",
+ "text-top",
+ "top",
+ "unset"
+ ]
+ },
+ "visibility": {
+ "isInherited": true,
+ "subproperties": [
+ "visibility"
+ ],
+ "supports": [],
+ "values": [
+ "collapse",
+ "hidden",
+ "inherit",
+ "initial",
+ "unset",
+ "visible"
+ ]
+ },
+ "white-space": {
+ "isInherited": true,
+ "subproperties": [
+ "white-space"
+ ],
+ "supports": [],
+ "values": [
+ "-moz-pre-space",
+ "inherit",
+ "initial",
+ "normal",
+ "nowrap",
+ "pre",
+ "pre-line",
+ "pre-wrap",
+ "unset"
+ ]
+ },
+ "width": {
+ "isInherited": false,
+ "subproperties": [
+ "width"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-available",
+ "-moz-calc",
+ "-moz-fit-content",
+ "-moz-max-content",
+ "-moz-min-content",
+ "auto",
+ "calc",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "will-change": {
+ "isInherited": false,
+ "subproperties": [
+ "will-change"
+ ],
+ "supports": [],
+ "values": [
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ },
+ "word-break": {
+ "isInherited": true,
+ "subproperties": [
+ "word-break"
+ ],
+ "supports": [],
+ "values": [
+ "break-all",
+ "inherit",
+ "initial",
+ "keep-all",
+ "normal",
+ "unset"
+ ]
+ },
+ "word-spacing": {
+ "isInherited": true,
+ "subproperties": [
+ "word-spacing"
+ ],
+ "supports": [
+ 6,
+ 8
+ ],
+ "values": [
+ "-moz-calc",
+ "calc",
+ "inherit",
+ "initial",
+ "normal",
+ "unset"
+ ]
+ },
+ "word-wrap": {
+ "isInherited": true,
+ "subproperties": [
+ "overflow-wrap"
+ ],
+ "supports": [],
+ "values": [
+ "break-word",
+ "inherit",
+ "initial",
+ "normal",
+ "unset"
+ ]
+ },
+ "writing-mode": {
+ "isInherited": true,
+ "subproperties": [
+ "writing-mode"
+ ],
+ "supports": [],
+ "values": [
+ "horizontal-tb",
+ "inherit",
+ "initial",
+ "lr",
+ "lr-tb",
+ "rl",
+ "rl-tb",
+ "sideways-lr",
+ "sideways-rl",
+ "tb",
+ "tb-rl",
+ "unset",
+ "vertical-lr",
+ "vertical-rl"
+ ]
+ },
+ "z-index": {
+ "isInherited": false,
+ "subproperties": [
+ "z-index"
+ ],
+ "supports": [
+ 7
+ ],
+ "values": [
+ "auto",
+ "inherit",
+ "initial",
+ "unset"
+ ]
+ }
+};
+
+/**
+ * A list of the pseudo elements.
+ */
+exports.PSEUDO_ELEMENTS = [
+ ":after",
+ ":before",
+ ":backdrop",
+ ":first-letter",
+ ":first-line",
+ ":-moz-selection",
+ ":-moz-focus-inner",
+ ":-moz-focus-outer",
+ ":-moz-list-bullet",
+ ":-moz-list-number",
+ ":-moz-math-anonymous",
+ ":-moz-progress-bar",
+ ":-moz-range-track",
+ ":-moz-range-progress",
+ ":-moz-range-thumb",
+ ":-moz-meter-bar",
+ ":-moz-placeholder",
+ ":placeholder",
+ ":-moz-color-swatch"
+];
diff --git a/devtools/shared/css/generated/properties-db.js.in b/devtools/shared/css/generated/properties-db.js.in
new file mode 100644
index 000000000..370c9199a
--- /dev/null
+++ b/devtools/shared/css/generated/properties-db.js.in
@@ -0,0 +1,20 @@
+/* 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/. */
+"use strict";
+
+/**
+ * This file is automatically generated by `mach devtools-css-db`. It contains
+ * a static list of CSS properties that can be computed by Gecko. The actual script
+ * to generate these files can be found at devtools/shared/css/generate-properties-db.js.
+ */
+
+/**
+ * A list of CSS Properties and their various characteristics.
+ */
+exports.CSS_PROPERTIES = ${cssProperties};
+
+/**
+ * A list of the pseudo elements.
+ */
+exports.PSEUDO_ELEMENTS = ${pseudoElements};
diff --git a/devtools/shared/css/lexer.js b/devtools/shared/css/lexer.js
new file mode 100644
index 000000000..9013b63ea
--- /dev/null
+++ b/devtools/shared/css/lexer.js
@@ -0,0 +1,1240 @@
+/* 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/. */
+
+// A CSS Lexer. This file is a bit unusual -- it is a more or less
+// direct translation of layout/style/nsCSSScanner.cpp and
+// layout/style/CSSLexer.cpp into JS. This implements the
+// CSSLexer.webidl interface, and the intent is to try to keep it in
+// sync with changes to the platform CSS lexer. Due to this goal,
+// this file violates some naming conventions and consequently locally
+// disables some eslint rules.
+
+/* eslint-disable camelcase, no-inline-comments, mozilla/no-aArgs */
+/* eslint-disable no-else-return */
+
+"use strict";
+
+// White space of any kind. No value fields are used. Note that
+// comments do *not* count as white space; comments separate tokens
+// but are not themselves tokens.
+const eCSSToken_Whitespace = "whitespace"; //
+// A comment.
+const eCSSToken_Comment = "comment"; // /*...*/
+
+// Identifier-like tokens. mIdent is the text of the identifier.
+// The difference between ID and Hash is: if the text after the #
+// would have been a valid Ident if the # hadn't been there, the
+// scanner produces an ID token. Otherwise it produces a Hash token.
+// (This distinction is required by css3-selectors.)
+const eCSSToken_Ident = "ident"; // word
+const eCSSToken_Function = "function"; // word(
+const eCSSToken_AtKeyword = "at"; // @word
+const eCSSToken_ID = "id"; // #word
+const eCSSToken_Hash = "hash"; // #0word
+
+// Numeric tokens. mNumber is the floating-point value of the
+// number, and mHasSign indicates whether there was an explicit sign
+// (+ or -) in front of the number. If mIntegerValid is true, the
+// number had the lexical form of an integer, and mInteger is its
+// integer value. Lexically integer values outside the range of a
+// 32-bit signed number are clamped to the maximum values; mNumber
+// will indicate a 'truer' value in that case. Percentage tokens
+// are always considered not to be integers, even if their numeric
+// value is integral (100% => mNumber = 1.0). For Dimension
+// tokens, mIdent holds the text of the unit.
+const eCSSToken_Number = "number"; // 1 -5 +2e3 3.14159 7.297352e-3
+const eCSSToken_Dimension = "dimension"; // 24px 8.5in
+const eCSSToken_Percentage = "percentage"; // 85% 1280.4%
+
+// String-like tokens. In all cases, mIdent holds the text
+// belonging to the string, and mSymbol holds the delimiter
+// character, which may be ', ", or zero (only for unquoted URLs).
+// Bad_String and Bad_URL tokens are emitted when the closing
+// delimiter or parenthesis was missing.
+const eCSSToken_String = "string"; // 'foo bar' "foo bar"
+const eCSSToken_Bad_String = "bad_string"; // 'foo bar
+const eCSSToken_URL = "url"; // url(foobar) url("foo bar")
+const eCSSToken_Bad_URL = "bad_url"; // url(foo
+
+// Any one-character symbol. mSymbol holds the character.
+const eCSSToken_Symbol = "symbol"; // . ; { } ! *
+
+// Match operators. These are single tokens rather than pairs of
+// Symbol tokens because css3-selectors forbids the presence of
+// comments between the two characters. No value fields are used;
+// the token type indicates which operator.
+const eCSSToken_Includes = "includes"; // ~=
+const eCSSToken_Dashmatch = "dashmatch"; // |=
+const eCSSToken_Beginsmatch = "beginsmatch"; // ^=
+const eCSSToken_Endsmatch = "endsmatch"; // $=
+const eCSSToken_Containsmatch = "containsmatch"; // *=
+
+// Unicode-range token: currently used only in @font-face.
+// The lexical rule for this token includes several forms that are
+// semantically invalid. Therefore, mIdent always holds the
+// complete original text of the token (so we can print it
+// accurately in diagnostics), and mIntegerValid is true iff the
+// token is semantically valid. In that case, mInteger holds the
+// lowest value included in the range, and mInteger2 holds the
+// highest value included in the range.
+const eCSSToken_URange = "urange"; // U+007e U+01?? U+2000-206F
+
+// HTML comment delimiters, ignored as a unit when they appear at
+// the top level of a style sheet, for compatibility with websites
+// written for compatibility with pre-CSS browsers. This token type
+// subsumes the css2.1 CDO and CDC tokens, which are always treated
+// the same by the parser. mIdent holds the text of the token, for
+// diagnostics.
+const eCSSToken_HTMLComment = "htmlcomment"; // <!-- -->
+
+const eEOFCharacters_None = 0x0000;
+
+// to handle \<EOF> inside strings
+const eEOFCharacters_DropBackslash = 0x0001;
+
+// to handle \<EOF> outside strings
+const eEOFCharacters_ReplacementChar = 0x0002;
+
+// to close comments
+const eEOFCharacters_Asterisk = 0x0004;
+const eEOFCharacters_Slash = 0x0008;
+
+// to close double-quoted strings
+const eEOFCharacters_DoubleQuote = 0x0010;
+
+// to close single-quoted strings
+const eEOFCharacters_SingleQuote = 0x0020;
+
+// to close URLs
+const eEOFCharacters_CloseParen = 0x0040;
+
+// Bridge the char/string divide.
+const APOSTROPHE = "'".charCodeAt(0);
+const ASTERISK = "*".charCodeAt(0);
+const CARRIAGE_RETURN = "\r".charCodeAt(0);
+const CIRCUMFLEX_ACCENT = "^".charCodeAt(0);
+const COMMERCIAL_AT = "@".charCodeAt(0);
+const DIGIT_NINE = "9".charCodeAt(0);
+const DIGIT_ZERO = "0".charCodeAt(0);
+const DOLLAR_SIGN = "$".charCodeAt(0);
+const EQUALS_SIGN = "=".charCodeAt(0);
+const EXCLAMATION_MARK = "!".charCodeAt(0);
+const FULL_STOP = ".".charCodeAt(0);
+const GREATER_THAN_SIGN = ">".charCodeAt(0);
+const HYPHEN_MINUS = "-".charCodeAt(0);
+const LATIN_CAPITAL_LETTER_E = "E".charCodeAt(0);
+const LATIN_CAPITAL_LETTER_U = "U".charCodeAt(0);
+const LATIN_SMALL_LETTER_E = "e".charCodeAt(0);
+const LATIN_SMALL_LETTER_U = "u".charCodeAt(0);
+const LEFT_PARENTHESIS = "(".charCodeAt(0);
+const LESS_THAN_SIGN = "<".charCodeAt(0);
+const LINE_FEED = "\n".charCodeAt(0);
+const NUMBER_SIGN = "#".charCodeAt(0);
+const PERCENT_SIGN = "%".charCodeAt(0);
+const PLUS_SIGN = "+".charCodeAt(0);
+const QUESTION_MARK = "?".charCodeAt(0);
+const QUOTATION_MARK = "\"".charCodeAt(0);
+const REVERSE_SOLIDUS = "\\".charCodeAt(0);
+const RIGHT_PARENTHESIS = ")".charCodeAt(0);
+const SOLIDUS = "/".charCodeAt(0);
+const TILDE = "~".charCodeAt(0);
+const VERTICAL_LINE = "|".charCodeAt(0);
+
+const UCS2_REPLACEMENT_CHAR = 0xFFFD;
+
+const kImpliedEOFCharacters = [
+ UCS2_REPLACEMENT_CHAR,
+ ASTERISK,
+ SOLIDUS,
+ QUOTATION_MARK,
+ APOSTROPHE,
+ RIGHT_PARENTHESIS,
+ 0
+];
+
+/**
+ * Ensure that the character is valid. If it is valid, return it;
+ * otherwise, return the replacement character.
+ *
+ * @param {Number} c the character to check
+ * @return {Number} the character or its replacement
+ */
+function ensureValidChar(c) {
+ if (c >= 0x00110000 || (c & 0xFFF800) == 0xD800) {
+ // Out of range or a surrogate.
+ return UCS2_REPLACEMENT_CHAR;
+ }
+ return c;
+}
+
+/**
+ * Turn a string into an array of character codes.
+ *
+ * @param {String} str the input string
+ * @return {Array} an array of character codes, one per character in
+ * the input string.
+ */
+function stringToCodes(str) {
+ return Array.prototype.map.call(str, (c) => c.charCodeAt(0));
+}
+
+const IS_HEX_DIGIT = 0x01;
+const IS_IDSTART = 0x02;
+const IS_IDCHAR = 0x04;
+const IS_URL_CHAR = 0x08;
+const IS_HSPACE = 0x10;
+const IS_VSPACE = 0x20;
+const IS_SPACE = IS_HSPACE | IS_VSPACE;
+const IS_STRING = 0x40;
+
+const H = IS_HSPACE;
+const V = IS_VSPACE;
+const I = IS_IDCHAR;
+const J = IS_IDSTART;
+const U = IS_URL_CHAR;
+const S = IS_STRING;
+const X = IS_HEX_DIGIT;
+
+const SH = S | H;
+const SU = S | U;
+const SUI = S | U | I;
+const SUIJ = S | U | I | J;
+const SUIX = S | U | I | X;
+const SUIJX = S | U | I | J | X;
+
+/* eslint-disable indent, no-multi-spaces, comma-spacing, spaced-comment */
+const gLexTable = [
+// 00 01 02 03 04 05 06 07
+ 0, S, S, S, S, S, S, S,
+// 08 TAB LF 0B FF CR 0E 0F
+ S, SH, V, S, V, V, S, S,
+// 10 11 12 13 14 15 16 17
+ S, S, S, S, S, S, S, S,
+// 18 19 1A 1B 1C 1D 1E 1F
+ S, S, S, S, S, S, S, S,
+//SPC ! " # $ % & '
+ SH, SU, 0, SU, SU, SU, SU, 0,
+// ( ) * + , - . /
+ S, S, SU, SU, SU, SUI, SU, SU,
+// 0 1 2 3 4 5 6 7
+ SUIX, SUIX, SUIX, SUIX, SUIX, SUIX, SUIX, SUIX,
+// 8 9 : ; < = > ?
+ SUIX, SUIX, SU, SU, SU, SU, SU, SU,
+// @ A B C D E F G
+ SU,SUIJX,SUIJX,SUIJX,SUIJX,SUIJX,SUIJX, SUIJ,
+// H I J K L M N O
+ SUIJ, SUIJ, SUIJ, SUIJ, SUIJ, SUIJ, SUIJ, SUIJ,
+// P Q R S T U V W
+ SUIJ, SUIJ, SUIJ, SUIJ, SUIJ, SUIJ, SUIJ, SUIJ,
+// X Y Z [ \ ] ^ _
+ SUIJ, SUIJ, SUIJ, SU, J, SU, SU, SUIJ,
+// ` a b c d e f g
+ SU,SUIJX,SUIJX,SUIJX,SUIJX,SUIJX,SUIJX, SUIJ,
+// h i j k l m n o
+ SUIJ, SUIJ, SUIJ, SUIJ, SUIJ, SUIJ, SUIJ, SUIJ,
+// p q r s t u v w
+ SUIJ, SUIJ, SUIJ, SUIJ, SUIJ, SUIJ, SUIJ, SUIJ,
+// x y z { | } ~ 7F
+ SUIJ, SUIJ, SUIJ, SU, SU, SU, SU, S,
+];
+/* eslint-enable indent, no-multi-spaces, comma-spacing, spaced-comment */
+
+/**
+ * True if 'ch' is in character class 'cls', which should be one of
+ * the constants above or some combination of them. All characters
+ * above U+007F are considered to be in 'cls'. EOF is never in 'cls'.
+ */
+function IsOpenCharClass(ch, cls) {
+ return ch >= 0 && (ch >= 128 || (gLexTable[ch] & cls) != 0);
+}
+
+/**
+ * True if 'ch' is in character class 'cls', which should be one of
+ * the constants above or some combination of them. No characters
+ * above U+007F are considered to be in 'cls'. EOF is never in 'cls'.
+ */
+function IsClosedCharClass(ch, cls) {
+ return ch >= 0 && ch < 128 && (gLexTable[ch] & cls) != 0;
+}
+
+/**
+ * True if 'ch' is CSS whitespace, i.e. any of the ASCII characters
+ * TAB, LF, FF, CR, or SPC.
+ */
+function IsWhitespace(ch) {
+ return IsClosedCharClass(ch, IS_SPACE);
+}
+
+/**
+ * True if 'ch' is horizontal whitespace, i.e. TAB or SPC.
+ */
+function IsHorzSpace(ch) {
+ return IsClosedCharClass(ch, IS_HSPACE);
+}
+
+/**
+ * True if 'ch' is vertical whitespace, i.e. LF, FF, or CR. Vertical
+ * whitespace requires special handling when consumed, see AdvanceLine.
+ */
+function IsVertSpace(ch) {
+ return IsClosedCharClass(ch, IS_VSPACE);
+}
+
+/**
+ * True if 'ch' is a character that can appear in the middle of an identifier.
+ * This includes U+0000 since it is handled as U+FFFD, but for purposes of
+ * GatherText it should not be included in IsOpenCharClass.
+ */
+function IsIdentChar(ch) {
+ return IsOpenCharClass(ch, IS_IDCHAR) || ch == 0;
+}
+
+/**
+ * True if 'ch' is a character that by itself begins an identifier.
+ * This includes U+0000 since it is handled as U+FFFD, but for purposes of
+ * GatherText it should not be included in IsOpenCharClass.
+ * (This is a subset of IsIdentChar.)
+ */
+function IsIdentStart(ch) {
+ return IsOpenCharClass(ch, IS_IDSTART) || ch == 0;
+}
+
+/**
+ * True if the two-character sequence aFirstChar+aSecondChar begins an
+ * identifier.
+ */
+function StartsIdent(aFirstChar, aSecondChar) {
+ return IsIdentStart(aFirstChar) ||
+ (aFirstChar == HYPHEN_MINUS && (aSecondChar == HYPHEN_MINUS ||
+ IsIdentStart(aSecondChar)));
+}
+
+/**
+ * True if 'ch' is a decimal digit.
+ */
+function IsDigit(ch) {
+ return (ch >= DIGIT_ZERO) && (ch <= DIGIT_NINE);
+}
+
+/**
+ * True if 'ch' is a hexadecimal digit.
+ */
+function IsHexDigit(ch) {
+ return IsClosedCharClass(ch, IS_HEX_DIGIT);
+}
+
+/**
+ * Assuming that 'ch' is a decimal digit, return its numeric value.
+ */
+function DecimalDigitValue(ch) {
+ return ch - DIGIT_ZERO;
+}
+
+/**
+ * Assuming that 'ch' is a hexadecimal digit, return its numeric value.
+ */
+function HexDigitValue(ch) {
+ if (IsDigit(ch)) {
+ return DecimalDigitValue(ch);
+ } else {
+ // Note: c&7 just keeps the low three bits which causes
+ // upper and lower case alphabetics to both yield their
+ // "relative to 10" value for computing the hex value.
+ return (ch & 0x7) + 9;
+ }
+}
+
+/**
+ * If 'ch' can be the first character of a two-character match operator
+ * token, return the token type code for that token, otherwise return
+ * eCSSToken_Symbol to indicate that it can't.
+ */
+function MatchOperatorType(ch) {
+ switch (ch) {
+ case TILDE: return eCSSToken_Includes;
+ case VERTICAL_LINE: return eCSSToken_Dashmatch;
+ case CIRCUMFLEX_ACCENT: return eCSSToken_Beginsmatch;
+ case DOLLAR_SIGN: return eCSSToken_Endsmatch;
+ case ASTERISK: return eCSSToken_Containsmatch;
+ default: return eCSSToken_Symbol;
+ }
+}
+
+function Scanner(buffer) {
+ this.mBuffer = buffer || "";
+ this.mOffset = 0;
+ this.mCount = this.mBuffer.length;
+ this.mLineNumber = 1;
+ this.mLineOffset = 0;
+ this.mTokenLineOffset = 0;
+ this.mTokenOffset = 0;
+ this.mTokenLineNumber = 1;
+ this.mEOFCharacters = eEOFCharacters_None;
+}
+
+Scanner.prototype = {
+ /**
+ * @see CSSLexer.lineNumber
+ */
+ get lineNumber() {
+ return this.mTokenLineNumber - 1;
+ },
+
+ /**
+ * @see CSSLexer.columnNumber
+ */
+ get columnNumber() {
+ return this.mTokenOffset - this.mTokenLineOffset;
+ },
+
+ /**
+ * @see CSSLexer.performEOFFixup
+ */
+ performEOFFixup: function (aInputString, aPreserveBackslash) {
+ let result = aInputString;
+
+ let eofChars = this.mEOFCharacters;
+
+ if (aPreserveBackslash &&
+ (eofChars & (eEOFCharacters_DropBackslash |
+ eEOFCharacters_ReplacementChar)) != 0) {
+ eofChars &= ~(eEOFCharacters_DropBackslash |
+ eEOFCharacters_ReplacementChar);
+ result += "\\";
+ }
+
+ if ((eofChars & eEOFCharacters_DropBackslash) != 0 &&
+ result.length > 0 && result.endsWith("\\")) {
+ result = result.slice(0, -1);
+ }
+
+ let extra = [];
+ this.AppendImpliedEOFCharacters(eofChars, extra);
+ let asString = String.fromCharCode.apply(null, extra);
+
+ return result + asString;
+ },
+
+ /**
+ * @see CSSLexer.nextToken
+ */
+ nextToken: function () {
+ let token = {};
+ if (!this.Next(token)) {
+ return null;
+ }
+
+ let resultToken = {};
+ resultToken.tokenType = token.mType;
+ resultToken.startOffset = this.mTokenOffset;
+ resultToken.endOffset = this.mOffset;
+
+ let constructText = () => {
+ return String.fromCharCode.apply(null, token.mIdent);
+ };
+
+ switch (token.mType) {
+ case eCSSToken_Whitespace:
+ break;
+
+ case eCSSToken_Ident:
+ case eCSSToken_Function:
+ case eCSSToken_AtKeyword:
+ case eCSSToken_ID:
+ case eCSSToken_Hash:
+ resultToken.text = constructText();
+ break;
+
+ case eCSSToken_Dimension:
+ resultToken.text = constructText();
+ /* Fall through. */
+ case eCSSToken_Number:
+ case eCSSToken_Percentage:
+ resultToken.number = token.mNumber;
+ resultToken.hasSign = token.mHasSign;
+ resultToken.isInteger = token.mIntegerValid;
+ break;
+
+ case eCSSToken_String:
+ case eCSSToken_Bad_String:
+ case eCSSToken_URL:
+ case eCSSToken_Bad_URL:
+ resultToken.text = constructText();
+ /* Don't bother emitting the delimiter, as it is readily extracted
+ from the source string when needed. */
+ break;
+
+ case eCSSToken_Symbol:
+ resultToken.text = String.fromCharCode(token.mSymbol);
+ break;
+
+ case eCSSToken_Includes:
+ case eCSSToken_Dashmatch:
+ case eCSSToken_Beginsmatch:
+ case eCSSToken_Endsmatch:
+ case eCSSToken_Containsmatch:
+ case eCSSToken_URange:
+ break;
+
+ case eCSSToken_Comment:
+ case eCSSToken_HTMLComment:
+ /* The comment text is easily extracted from the source string,
+ and is rarely useful. */
+ break;
+ }
+
+ return resultToken;
+ },
+
+ /**
+ * Return the raw UTF-16 code unit at position |this.mOffset + n| within
+ * the read buffer. If that is beyond the end of the buffer, returns
+ * -1 to indicate end of input.
+ */
+ Peek: function (n = 0) {
+ if (this.mOffset + n >= this.mCount) {
+ return -1;
+ }
+ return this.mBuffer.charCodeAt(this.mOffset + n);
+ },
+
+ /**
+ * Advance |this.mOffset| over |n| code units. Advance(0) is a no-op.
+ * If |n| is greater than the distance to end of input, will silently
+ * stop at the end. May not be used to advance over a line boundary;
+ * AdvanceLine() must be used instead.
+ */
+ Advance: function (n = 1) {
+ if (this.mOffset + n >= this.mCount || this.mOffset + n < this.mOffset) {
+ this.mOffset = this.mCount;
+ } else {
+ this.mOffset += n;
+ }
+ },
+
+ /**
+ * Advance |this.mOffset| over a line boundary.
+ */
+ AdvanceLine: function () {
+ // Advance over \r\n as a unit.
+ if (this.mBuffer.charCodeAt(this.mOffset) == CARRIAGE_RETURN &&
+ this.mOffset + 1 < this.mCount &&
+ this.mBuffer.charCodeAt(this.mOffset + 1) == LINE_FEED) {
+ this.mOffset += 2;
+ } else {
+ this.mOffset += 1;
+ }
+ // 0 is a magical line number meaning that we don't know (i.e., script)
+ if (this.mLineNumber != 0) {
+ this.mLineNumber++;
+ }
+ this.mLineOffset = this.mOffset;
+ },
+
+ /**
+ * Skip over a sequence of whitespace characters (vertical or
+ * horizontal) starting at the current read position.
+ */
+ SkipWhitespace: function () {
+ for (;;) {
+ let ch = this.Peek();
+ if (!IsWhitespace(ch)) { // EOF counts as non-whitespace
+ break;
+ }
+ if (IsVertSpace(ch)) {
+ this.AdvanceLine();
+ } else {
+ this.Advance();
+ }
+ }
+ },
+
+ /**
+ * Skip over one CSS comment starting at the current read position.
+ */
+ SkipComment: function () {
+ this.Advance(2);
+ for (;;) {
+ let ch = this.Peek();
+ if (ch < 0) {
+ this.SetEOFCharacters(eEOFCharacters_Asterisk | eEOFCharacters_Slash);
+ return;
+ }
+ if (ch == ASTERISK) {
+ this.Advance();
+ ch = this.Peek();
+ if (ch < 0) {
+ this.SetEOFCharacters(eEOFCharacters_Slash);
+ return;
+ }
+ if (ch == SOLIDUS) {
+ this.Advance();
+ return;
+ }
+ } else if (IsVertSpace(ch)) {
+ this.AdvanceLine();
+ } else {
+ this.Advance();
+ }
+ }
+ },
+
+ /**
+ * If there is a valid escape sequence starting at the current read
+ * position, consume it, decode it, append the result to |aOutput|,
+ * and return true. Otherwise, consume nothing, leave |aOutput|
+ * unmodified, and return false. If |aInString| is true, accept the
+ * additional form of escape sequence allowed within string-like tokens.
+ */
+ GatherEscape: function (aOutput, aInString) {
+ let ch = this.Peek(1);
+ if (ch < 0) {
+ // If we are in a string (or a url() containing a string), we want to drop
+ // the backslash on the floor. Otherwise, we want to treat it as a U+FFFD
+ // character.
+ this.Advance();
+ if (aInString) {
+ this.SetEOFCharacters(eEOFCharacters_DropBackslash);
+ } else {
+ aOutput.push(UCS2_REPLACEMENT_CHAR);
+ this.SetEOFCharacters(eEOFCharacters_ReplacementChar);
+ }
+ return true;
+ }
+ if (IsVertSpace(ch)) {
+ if (aInString) {
+ // In strings (and in url() containing a string), escaped
+ // newlines are completely removed, to allow splitting over
+ // multiple lines.
+ this.Advance();
+ this.AdvanceLine();
+ return true;
+ }
+ // Outside of strings, backslash followed by a newline is not an escape.
+ return false;
+ }
+
+ if (!IsHexDigit(ch)) {
+ // "Any character (except a hexadecimal digit, linefeed, carriage
+ // return, or form feed) can be escaped with a backslash to remove
+ // its special meaning." -- CSS2.1 section 4.1.3
+ this.Advance(2);
+ if (ch == 0) {
+ aOutput.push(UCS2_REPLACEMENT_CHAR);
+ } else {
+ aOutput.push(ch);
+ }
+ return true;
+ }
+
+ // "[at most six hexadecimal digits following a backslash] stand
+ // for the ISO 10646 character with that number, which must not be
+ // zero. (It is undefined in CSS 2.1 what happens if a style sheet
+ // does contain a character with Unicode codepoint zero.)"
+ // -- CSS2.1 section 4.1.3
+
+ // At this point we know we have \ followed by at least one
+ // hexadecimal digit, therefore the escape sequence is valid and we
+ // can go ahead and consume the backslash.
+ this.Advance();
+ let val = 0;
+ let i = 0;
+ do {
+ val = val * 16 + HexDigitValue(ch);
+ i++;
+ this.Advance();
+ ch = this.Peek();
+ } while (i < 6 && IsHexDigit(ch));
+
+ // "Interpret the hex digits as a hexadecimal number. If this
+ // number is zero, or is greater than the maximum allowed
+ // codepoint, return U+FFFD REPLACEMENT CHARACTER" -- CSS Syntax
+ // Level 3
+ if (val == 0) {
+ aOutput.push(UCS2_REPLACEMENT_CHAR);
+ } else {
+ aOutput.push(ensureValidChar(val));
+ }
+
+ // Consume exactly one whitespace character after a
+ // hexadecimal escape sequence.
+ if (IsVertSpace(ch)) {
+ this.AdvanceLine();
+ } else if (IsHorzSpace(ch)) {
+ this.Advance();
+ }
+ return true;
+ },
+
+ /**
+ * Consume a run of "text" beginning with the current read position,
+ * consisting of characters in the class |aClass| (which must be a
+ * suitable argument to IsOpenCharClass) plus escape sequences.
+ * Append the text to |aText|, after decoding escape sequences.
+ *
+ * Returns true if at least one character was appended to |aText|,
+ * false otherwise.
+ */
+ GatherText: function (aClass, aText) {
+ let start = this.mOffset;
+ let inString = aClass == IS_STRING;
+
+ for (;;) {
+ // Consume runs of unescaped characters in one go.
+ let n = this.mOffset;
+ while (n < this.mCount && IsOpenCharClass(this.mBuffer.charCodeAt(n),
+ aClass)) {
+ n++;
+ }
+ if (n > this.mOffset) {
+ let substr = this.mBuffer.slice(this.mOffset, n);
+ Array.prototype.push.apply(aText, stringToCodes(substr));
+ this.mOffset = n;
+ }
+ if (n == this.mCount) {
+ break;
+ }
+
+ let ch = this.Peek();
+ if (ch == 0) {
+ this.Advance();
+ aText.push(UCS2_REPLACEMENT_CHAR);
+ continue;
+ }
+
+ if (ch != REVERSE_SOLIDUS) {
+ break;
+ }
+ if (!this.GatherEscape(aText, inString)) {
+ break;
+ }
+ }
+
+ return this.mOffset > start;
+ },
+
+ /**
+ * Scan an Ident token. This also handles Function and URL tokens,
+ * both of which begin indistinguishably from an identifier. It can
+ * produce a Symbol token when an apparent identifier actually led
+ * into an invalid escape sequence.
+ */
+ ScanIdent: function (aToken) {
+ if (!this.GatherText(IS_IDCHAR, aToken.mIdent)) {
+ aToken.mSymbol = this.Peek();
+ this.Advance();
+ return true;
+ }
+
+ if (this.Peek() != LEFT_PARENTHESIS) {
+ aToken.mType = eCSSToken_Ident;
+ return true;
+ }
+
+ this.Advance();
+ aToken.mType = eCSSToken_Function;
+
+ let asString = String.fromCharCode.apply(null, aToken.mIdent);
+ if (asString.toLowerCase() === "url") {
+ this.NextURL(aToken);
+ }
+ return true;
+ },
+
+ /**
+ * Scan an AtKeyword token. Also handles production of Symbol when
+ * an '@' is not followed by an identifier.
+ */
+ ScanAtKeyword: function (aToken) {
+ // Fall back for when '@' isn't followed by an identifier.
+ aToken.mSymbol = COMMERCIAL_AT;
+ this.Advance();
+
+ let ch = this.Peek();
+ if (StartsIdent(ch, this.Peek(1))) {
+ if (this.GatherText(IS_IDCHAR, aToken.mIdent)) {
+ aToken.mType = eCSSToken_AtKeyword;
+ }
+ }
+ return true;
+ },
+
+ /**
+ * Scan a Hash token. Handles the distinction between eCSSToken_ID
+ * and eCSSToken_Hash, and handles production of Symbol when a '#'
+ * is not followed by identifier characters.
+ */
+ ScanHash: function (aToken) {
+ // Fall back for when '#' isn't followed by identifier characters.
+ aToken.mSymbol = NUMBER_SIGN;
+ this.Advance();
+
+ let ch = this.Peek();
+ if (IsIdentChar(ch) || ch == REVERSE_SOLIDUS) {
+ let type =
+ StartsIdent(ch, this.Peek(1)) ? eCSSToken_ID : eCSSToken_Hash;
+ aToken.mIdent.length = 0;
+ if (this.GatherText(IS_IDCHAR, aToken.mIdent)) {
+ aToken.mType = type;
+ }
+ }
+
+ return true;
+ },
+
+ /**
+ * Scan a Number, Percentage, or Dimension token (all of which begin
+ * like a Number). Can produce a Symbol when a '.' is not followed by
+ * digits, or when '+' or '-' are not followed by either a digit or a
+ * '.' and then a digit. Can also produce a HTMLComment when it
+ * encounters '-->'.
+ */
+ ScanNumber: function (aToken) {
+ let c = this.Peek();
+
+ // Sign of the mantissa (-1 or 1).
+ let sign = c == HYPHEN_MINUS ? -1 : 1;
+ // Absolute value of the integer part of the mantissa. This is a double so
+ // we don't run into overflow issues for consumers that only care about our
+ // floating-point value while still being able to express the full int32_t
+ // range for consumers who want integers.
+ let intPart = 0;
+ // Fractional part of the mantissa. This is a double so that when
+ // we convert to float at the end we'll end up rounding to nearest
+ // float instead of truncating down (as we would if fracPart were
+ // a float and we just effectively lost the last several digits).
+ let fracPart = 0;
+ // Absolute value of the power of 10 that we should multiply by
+ // (only relevant for numbers in scientific notation). Has to be
+ // a signed integer, because multiplication of signed by unsigned
+ // converts the unsigned to signed, so if we plan to actually
+ // multiply by expSign...
+ let exponent = 0;
+ // Sign of the exponent.
+ let expSign = 1;
+
+ aToken.mHasSign = (c == PLUS_SIGN || c == HYPHEN_MINUS);
+ if (aToken.mHasSign) {
+ this.Advance();
+ c = this.Peek();
+ }
+
+ let gotDot = (c == FULL_STOP);
+
+ if (!gotDot) {
+ // Scan the integer part of the mantissa.
+ do {
+ intPart = 10 * intPart + DecimalDigitValue(c);
+ this.Advance();
+ c = this.Peek();
+ } while (IsDigit(c));
+
+ gotDot = (c == FULL_STOP) && IsDigit(this.Peek(1));
+ }
+
+ if (gotDot) {
+ // Scan the fractional part of the mantissa.
+ this.Advance();
+ c = this.Peek();
+ // Power of ten by which we need to divide our next digit
+ let divisor = 10;
+ do {
+ fracPart += DecimalDigitValue(c) / divisor;
+ divisor *= 10;
+ this.Advance();
+ c = this.Peek();
+ } while (IsDigit(c));
+ }
+
+ let gotE = false;
+ if (c == LATIN_SMALL_LETTER_E || c == LATIN_CAPITAL_LETTER_E) {
+ let expSignChar = this.Peek(1);
+ let nextChar = this.Peek(2);
+ if (IsDigit(expSignChar) ||
+ ((expSignChar == HYPHEN_MINUS || expSignChar == PLUS_SIGN) &&
+ IsDigit(nextChar))) {
+ gotE = true;
+ if (expSignChar == HYPHEN_MINUS) {
+ expSign = -1;
+ }
+ this.Advance(); // consumes the E
+ if (expSignChar == HYPHEN_MINUS || expSignChar == PLUS_SIGN) {
+ this.Advance();
+ c = nextChar;
+ } else {
+ c = expSignChar;
+ }
+ do {
+ exponent = 10 * exponent + DecimalDigitValue(c);
+ this.Advance();
+ c = this.Peek();
+ } while (IsDigit(c));
+ }
+ }
+
+ let type = eCSSToken_Number;
+
+ // Set mIntegerValid for all cases (except %, below) because we need
+ // it for the "2n" in :nth-child(2n).
+ aToken.mIntegerValid = false;
+
+ // Time to reassemble our number.
+ // Do all the math in double precision so it's truncated only once.
+ let value = sign * (intPart + fracPart);
+ if (gotE) {
+ // Explicitly cast expSign*exponent to double to avoid issues with
+ // overloaded pow() on Windows.
+ value *= Math.pow(10.0, expSign * exponent);
+ } else if (!gotDot) {
+ // Clamp values outside of integer range.
+ if (sign > 0) {
+ aToken.mInteger = Math.min(intPart, Number.MAX_SAFE_INTEGER);
+ } else {
+ aToken.mInteger = Math.max(-intPart, Number.MIN_SAFE_INTEGER);
+ }
+ aToken.mIntegerValid = true;
+ }
+
+ let ident = aToken.mIdent;
+
+ // Check for Dimension and Percentage tokens.
+ if (c >= 0) {
+ if (StartsIdent(c, this.Peek(1))) {
+ if (this.GatherText(IS_IDCHAR, ident)) {
+ type = eCSSToken_Dimension;
+ }
+ } else if (c == PERCENT_SIGN) {
+ this.Advance();
+ type = eCSSToken_Percentage;
+ value = value / 100.0;
+ aToken.mIntegerValid = false;
+ }
+ }
+ aToken.mNumber = value;
+ aToken.mType = type;
+ return true;
+ },
+
+ /**
+ * Scan a string constant ('foo' or "foo"). Will always produce
+ * either a String or a Bad_String token; the latter occurs when the
+ * close quote is missing. Always returns true (for convenience in Next()).
+ */
+ ScanString: function (aToken) {
+ let aStop = this.Peek();
+ aToken.mType = eCSSToken_String;
+ aToken.mSymbol = aStop; // Remember how it's quoted.
+ this.Advance();
+
+ for (;;) {
+ this.GatherText(IS_STRING, aToken.mIdent);
+
+ let ch = this.Peek();
+ if (ch == -1) {
+ this.AddEOFCharacters(aStop == QUOTATION_MARK ?
+ eEOFCharacters_DoubleQuote :
+ eEOFCharacters_SingleQuote);
+ break; // EOF ends a string token with no error.
+ }
+ if (ch == aStop) {
+ this.Advance();
+ break;
+ }
+ // Both " and ' are excluded from IS_STRING.
+ if (ch == QUOTATION_MARK || ch == APOSTROPHE) {
+ aToken.mIdent.push(ch);
+ this.Advance();
+ continue;
+ }
+
+ aToken.mType = eCSSToken_Bad_String;
+ break;
+ }
+ return true;
+ },
+
+ /**
+ * Scan a unicode-range token. These match the regular expression
+ *
+ * u\+[0-9a-f?]{1,6}(-[0-9a-f]{1,6})?
+ *
+ * However, some such tokens are "invalid". There are three valid forms:
+ *
+ * u+[0-9a-f]{x} 1 <= x <= 6
+ * u+[0-9a-f]{x}\?{y} 1 <= x+y <= 6
+ * u+[0-9a-f]{x}-[0-9a-f]{y} 1 <= x <= 6, 1 <= y <= 6
+ *
+ * All unicode-range tokens have their text recorded in mIdent; valid ones
+ * are also decoded into mInteger and mInteger2, and mIntegerValid is set.
+ * Note that this does not validate the numeric range, only the syntactic
+ * form.
+ */
+ ScanURange: function (aResult) {
+ let intro1 = this.Peek();
+ let intro2 = this.Peek(1);
+ let ch = this.Peek(2);
+
+ aResult.mIdent.push(intro1);
+ aResult.mIdent.push(intro2);
+ this.Advance(2);
+
+ let valid = true;
+ let haveQues = false;
+ let low = 0;
+ let high = 0;
+ let i = 0;
+
+ do {
+ aResult.mIdent.push(ch);
+ if (IsHexDigit(ch)) {
+ if (haveQues) {
+ valid = false; // All question marks should be at the end.
+ }
+ low = low * 16 + HexDigitValue(ch);
+ high = high * 16 + HexDigitValue(ch);
+ } else {
+ haveQues = true;
+ low = low * 16 + 0x0;
+ high = high * 16 + 0xF;
+ }
+
+ i++;
+ this.Advance();
+ ch = this.Peek();
+ } while (i < 6 && (IsHexDigit(ch) || ch == QUESTION_MARK));
+
+ if (ch == HYPHEN_MINUS && IsHexDigit(this.Peek(1))) {
+ if (haveQues) {
+ valid = false;
+ }
+
+ aResult.mIdent.push(ch);
+ this.Advance();
+ ch = this.Peek();
+ high = 0;
+ i = 0;
+ do {
+ aResult.mIdent.push(ch);
+ high = high * 16 + HexDigitValue(ch);
+
+ i++;
+ this.Advance();
+ ch = this.Peek();
+ } while (i < 6 && IsHexDigit(ch));
+ }
+
+ aResult.mInteger = low;
+ aResult.mInteger2 = high;
+ aResult.mIntegerValid = valid;
+ aResult.mType = eCSSToken_URange;
+ return true;
+ },
+
+ SetEOFCharacters: function (aEOFCharacters) {
+ this.mEOFCharacters = aEOFCharacters;
+ },
+
+ AddEOFCharacters: function (aEOFCharacters) {
+ this.mEOFCharacters = this.mEOFCharacters | aEOFCharacters;
+ },
+
+ AppendImpliedEOFCharacters: function (aEOFCharacters, aResult) {
+ // First, ignore eEOFCharacters_DropBackslash.
+ let c = aEOFCharacters >> 1;
+
+ // All of the remaining EOFCharacters bits represent appended characters,
+ // and the bits are in the order that they need appending.
+ for (let p of kImpliedEOFCharacters) {
+ if (c & 1) {
+ aResult.push(p);
+ }
+ c >>= 1;
+ }
+ },
+
+ /**
+ * Consume the part of an URL token after the initial 'url('. Caller
+ * is assumed to have consumed 'url(' already. Will always produce
+ * either an URL or a Bad_URL token.
+ *
+ * Exposed for use by nsCSSParser::ParseMozDocumentRule, which applies
+ * the special lexical rules for URL tokens in a nonstandard context.
+ */
+ NextURL: function (aToken) {
+ this.SkipWhitespace();
+
+ // aToken.mIdent may be "url" at this point; clear that out
+ aToken.mIdent.length = 0;
+
+ let ch = this.Peek();
+ // Do we have a string?
+ if (ch == QUOTATION_MARK || ch == APOSTROPHE) {
+ this.ScanString(aToken);
+ if (aToken.mType == eCSSToken_Bad_String) {
+ aToken.mType = eCSSToken_Bad_URL;
+ return;
+ }
+ } else {
+ // Otherwise, this is the start of a non-quoted url (which may be empty).
+ aToken.mSymbol = 0;
+ this.GatherText(IS_URL_CHAR, aToken.mIdent);
+ }
+
+ // Consume trailing whitespace and then look for a close parenthesis.
+ this.SkipWhitespace();
+ ch = this.Peek();
+ // ch can be less than zero indicating EOF
+ if (ch < 0 || ch == RIGHT_PARENTHESIS) {
+ this.Advance();
+ aToken.mType = eCSSToken_URL;
+ if (ch < 0) {
+ this.AddEOFCharacters(eEOFCharacters_CloseParen);
+ }
+ } else {
+ aToken.mType = eCSSToken_Bad_URL;
+ }
+ },
+
+ /**
+ * Primary scanner entry point. Consume one token and fill in
+ * |aToken| accordingly. Will skip over any number of comments first,
+ * and will also skip over rather than return whitespace and comment
+ * tokens, depending on the value of |aSkip|.
+ *
+ * Returns true if it successfully consumed a token, false if EOF has
+ * been reached. Will always advance the current read position by at
+ * least one character unless called when already at EOF.
+ */
+ Next: function (aToken, aSkip) {
+ let ch;
+
+ // do this here so we don't have to do it in dozens of other places
+ aToken.mIdent = [];
+ aToken.mType = eCSSToken_Symbol;
+
+ this.mTokenOffset = this.mOffset;
+ this.mTokenLineOffset = this.mLineOffset;
+ this.mTokenLineNumber = this.mLineNumber;
+
+ ch = this.Peek();
+ if (IsWhitespace(ch)) {
+ this.SkipWhitespace();
+ aToken.mType = eCSSToken_Whitespace;
+ return true;
+ }
+ if (ch == SOLIDUS && // !IsSVGMode() &&
+ this.Peek(1) == ASTERISK) {
+ this.SkipComment();
+ aToken.mType = eCSSToken_Comment;
+ return true;
+ }
+
+ // EOF
+ if (ch < 0) {
+ return false;
+ }
+
+ // 'u' could be UNICODE-RANGE or an identifier-family token
+ if (ch == LATIN_SMALL_LETTER_U || ch == LATIN_CAPITAL_LETTER_U) {
+ let c2 = this.Peek(1);
+ let c3 = this.Peek(2);
+ if (c2 == PLUS_SIGN && (IsHexDigit(c3) || c3 == QUESTION_MARK)) {
+ return this.ScanURange(aToken);
+ }
+ return this.ScanIdent(aToken);
+ }
+
+ // identifier family
+ if (IsIdentStart(ch)) {
+ return this.ScanIdent(aToken);
+ }
+
+ // number family
+ if (IsDigit(ch)) {
+ return this.ScanNumber(aToken);
+ }
+
+ if (ch == FULL_STOP && IsDigit(this.Peek(1))) {
+ return this.ScanNumber(aToken);
+ }
+
+ if (ch == PLUS_SIGN) {
+ let c2 = this.Peek(1);
+ if (IsDigit(c2) || (c2 == FULL_STOP && IsDigit(this.Peek(2)))) {
+ return this.ScanNumber(aToken);
+ }
+ }
+
+ // HYPHEN_MINUS can start an identifier-family token, a number-family token,
+ // or an HTML-comment
+ if (ch == HYPHEN_MINUS) {
+ let c2 = this.Peek(1);
+ let c3 = this.Peek(2);
+ if (IsIdentStart(c2) || (c2 == HYPHEN_MINUS && c3 != GREATER_THAN_SIGN)) {
+ return this.ScanIdent(aToken);
+ }
+ if (IsDigit(c2) || (c2 == FULL_STOP && IsDigit(c3))) {
+ return this.ScanNumber(aToken);
+ }
+ if (c2 == HYPHEN_MINUS && c3 == GREATER_THAN_SIGN) {
+ this.Advance(3);
+ aToken.mType = eCSSToken_HTMLComment;
+ aToken.mIdent = stringToCodes("-->");
+ return true;
+ }
+ }
+
+ // the other HTML-comment token
+ if (ch == LESS_THAN_SIGN &&
+ this.Peek(1) == EXCLAMATION_MARK &&
+ this.Peek(2) == HYPHEN_MINUS &&
+ this.Peek(3) == HYPHEN_MINUS) {
+ this.Advance(4);
+ aToken.mType = eCSSToken_HTMLComment;
+ aToken.mIdent = stringToCodes("<!--");
+ return true;
+ }
+
+ // AT_KEYWORD
+ if (ch == COMMERCIAL_AT) {
+ return this.ScanAtKeyword(aToken);
+ }
+
+ // HASH
+ if (ch == NUMBER_SIGN) {
+ return this.ScanHash(aToken);
+ }
+
+ // STRING
+ if (ch == QUOTATION_MARK || ch == APOSTROPHE) {
+ return this.ScanString(aToken);
+ }
+
+ // Match operators: ~= |= ^= $= *=
+ let opType = MatchOperatorType(ch);
+ if (opType != eCSSToken_Symbol && this.Peek(1) == EQUALS_SIGN) {
+ aToken.mType = opType;
+ this.Advance(2);
+ return true;
+ }
+
+ // Otherwise, a symbol (DELIM).
+ aToken.mSymbol = ch;
+ this.Advance();
+ return true;
+ },
+};
+
+/**
+ * Create and return a new CSS lexer, conforming to the @see CSSLexer
+ * webidl interface.
+ *
+ * @param {String} input the CSS text to lex
+ * @return {CSSLexer} the new lexer
+ */
+function getCSSLexer(input) {
+ return new Scanner(input);
+}
+
+exports.getCSSLexer = getCSSLexer;
diff --git a/devtools/shared/css/moz.build b/devtools/shared/css/moz.build
new file mode 100644
index 000000000..c65b8d141
--- /dev/null
+++ b/devtools/shared/css/moz.build
@@ -0,0 +1,17 @@
+# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
+# vim: set filetype=python:
+# 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/.
+
+DIRS += [
+ 'generated',
+]
+
+DevToolsModules(
+ 'color-db.js',
+ 'color.js',
+ 'lexer.js',
+ 'parsing-utils.js',
+ 'properties-db.js',
+)
diff --git a/devtools/shared/css/parsing-utils.js b/devtools/shared/css/parsing-utils.js
new file mode 100644
index 000000000..f477b0f12
--- /dev/null
+++ b/devtools/shared/css/parsing-utils.js
@@ -0,0 +1,1171 @@
+/* -*- indent-tabs-mode: nil; js-indent-level: 2 -*- */
+/* vim: set ts=2 et sw=2 tw=80: */
+/* 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/. */
+
+// This file holds various CSS parsing and rewriting utilities.
+// Some entry points of note are:
+// parseDeclarations - parse a CSS rule into declarations
+// RuleRewriter - rewrite CSS rule text
+// parsePseudoClassesAndAttributes - parse selector and extract
+// pseudo-classes
+// parseSingleValue - parse a single CSS property value
+
+"use strict";
+
+const {CSS_ANGLEUNIT} = require("devtools/shared/css/properties-db");
+
+const promise = require("promise");
+const {getCSSLexer} = require("devtools/shared/css/lexer");
+const {Task} = require("devtools/shared/task");
+
+const SELECTOR_ATTRIBUTE = exports.SELECTOR_ATTRIBUTE = 1;
+const SELECTOR_ELEMENT = exports.SELECTOR_ELEMENT = 2;
+const SELECTOR_PSEUDO_CLASS = exports.SELECTOR_PSEUDO_CLASS = 3;
+
+// Used to test whether a newline appears anywhere in some text.
+const NEWLINE_RX = /[\r\n]/;
+// Used to test whether a bit of text starts an empty comment, either
+// an "ordinary" /* ... */ comment, or a "heuristic bypass" comment
+// like /*! ... */.
+const EMPTY_COMMENT_START_RX = /^\/\*!?[ \r\n\t\f]*$/;
+// Used to test whether a bit of text ends an empty comment.
+const EMPTY_COMMENT_END_RX = /^[ \r\n\t\f]*\*\//;
+// Used to test whether a string starts with a blank line.
+const BLANK_LINE_RX = /^[ \t]*(?:\r\n|\n|\r|\f|$)/;
+
+// When commenting out a declaration, we put this character into the
+// comment opener so that future parses of the commented text know to
+// bypass the property name validity heuristic.
+const COMMENT_PARSING_HEURISTIC_BYPASS_CHAR = "!";
+
+/**
+ * A generator function that lexes a CSS source string, yielding the
+ * CSS tokens. Comment tokens are dropped.
+ *
+ * @param {String} CSS source string
+ * @yield {CSSToken} The next CSSToken that is lexed
+ * @see CSSToken for details about the returned tokens
+ */
+function* cssTokenizer(string) {
+ let lexer = getCSSLexer(string);
+ while (true) {
+ let token = lexer.nextToken();
+ if (!token) {
+ break;
+ }
+ // None of the existing consumers want comments.
+ if (token.tokenType !== "comment") {
+ yield token;
+ }
+ }
+}
+
+/**
+ * Pass |string| to the CSS lexer and return an array of all the
+ * returned tokens. Comment tokens are not included. In addition to
+ * the usual information, each token will have starting and ending
+ * line and column information attached. Specifically, each token
+ * has an additional "loc" attribute. This attribute is an object
+ * of the form {line: L, column: C}. Lines and columns are both zero
+ * based.
+ *
+ * It's best not to add new uses of this function. In general it is
+ * simpler and better to use the CSSToken offsets, rather than line
+ * and column. Also, this function lexes the entire input string at
+ * once, rather than lazily yielding a token stream. Use
+ * |cssTokenizer| or |getCSSLexer| instead.
+ *
+ * @param{String} string The input string.
+ * @return {Array} An array of tokens (@see CSSToken) that have
+ * line and column information.
+ */
+function cssTokenizerWithLineColumn(string) {
+ let lexer = getCSSLexer(string);
+ let result = [];
+ let prevToken = undefined;
+ while (true) {
+ let token = lexer.nextToken();
+ let lineNumber = lexer.lineNumber;
+ let columnNumber = lexer.columnNumber;
+
+ if (prevToken) {
+ prevToken.loc.end = {
+ line: lineNumber,
+ column: columnNumber
+ };
+ }
+
+ if (!token) {
+ break;
+ }
+
+ if (token.tokenType === "comment") {
+ // We've already dealt with the previous token's location.
+ prevToken = undefined;
+ } else {
+ let startLoc = {
+ line: lineNumber,
+ column: columnNumber
+ };
+ token.loc = {start: startLoc};
+
+ result.push(token);
+ prevToken = token;
+ }
+ }
+
+ return result;
+}
+
+/**
+ * Escape a comment body. Find the comment start and end strings in a
+ * string and inserts backslashes so that the resulting text can
+ * itself be put inside a comment.
+ *
+ * @param {String} inputString
+ * input string
+ * @return {String} the escaped result
+ */
+function escapeCSSComment(inputString) {
+ let result = inputString.replace(/\/(\\*)\*/g, "/\\$1*");
+ return result.replace(/\*(\\*)\//g, "*\\$1/");
+}
+
+/**
+ * Un-escape a comment body. This undoes any comment escaping that
+ * was done by escapeCSSComment. That is, given input like "/\*
+ * comment *\/", it will strip the backslashes.
+ *
+ * @param {String} inputString
+ * input string
+ * @return {String} the un-escaped result
+ */
+function unescapeCSSComment(inputString) {
+ let result = inputString.replace(/\/\\(\\*)\*/g, "/$1*");
+ return result.replace(/\*\\(\\*)\//g, "*$1/");
+}
+
+/**
+ * A helper function for @see parseDeclarations that handles parsing
+ * of comment text. This wraps a recursive call to parseDeclarations
+ * with the processing needed to ensure that offsets in the result
+ * refer back to the original, unescaped, input string.
+ *
+ * @param {Function} isCssPropertyKnown
+ * A function to check if the CSS property is known. This is either an
+ * internal server function or from the CssPropertiesFront.
+ * @param {String} commentText The text of the comment, without the
+ * delimiters.
+ * @param {Number} startOffset The offset of the comment opener
+ * in the original text.
+ * @param {Number} endOffset The offset of the comment closer
+ * in the original text.
+ * @return {array} Array of declarations of the same form as returned
+ * by parseDeclarations.
+ */
+function parseCommentDeclarations(isCssPropertyKnown, commentText, startOffset,
+ endOffset) {
+ let commentOverride = false;
+ if (commentText === "") {
+ return [];
+ } else if (commentText[0] === COMMENT_PARSING_HEURISTIC_BYPASS_CHAR) {
+ // This is the special sign that the comment was written by
+ // rewriteDeclarations and so we should bypass the usual
+ // heuristic.
+ commentOverride = true;
+ commentText = commentText.substring(1);
+ }
+
+ let rewrittenText = unescapeCSSComment(commentText);
+
+ // We might have rewritten an embedded comment. For example
+ // /\* ... *\/ would turn into /* ... */.
+ // This rewriting is necessary for proper lexing, but it means
+ // that the offsets we get back can be off. So now we compute
+ // a map so that we can rewrite offsets later. The map is the same
+ // length as |rewrittenText| and tells us how to map an index
+ // into |rewrittenText| to an index into |commentText|.
+ //
+ // First, we find the location of each comment starter or closer in
+ // |rewrittenText|. At these spots we put a 1 into |rewrites|.
+ // Then we walk the array again, using the elements to compute a
+ // delta, which we use to make the final mapping.
+ //
+ // Note we allocate one extra entry because we can see an ending
+ // offset that is equal to the length.
+ let rewrites = new Array(rewrittenText.length + 1).fill(0);
+
+ let commentRe = /\/\\*\*|\*\\*\//g;
+ while (true) {
+ let matchData = commentRe.exec(rewrittenText);
+ if (!matchData) {
+ break;
+ }
+ rewrites[matchData.index] = 1;
+ }
+
+ let delta = 0;
+ for (let i = 0; i <= rewrittenText.length; ++i) {
+ delta += rewrites[i];
+ // |startOffset| to add the offset from the comment starter, |+2|
+ // for the length of the "/*", then |i| and |delta| as described
+ // above.
+ rewrites[i] = startOffset + 2 + i + delta;
+ if (commentOverride) {
+ ++rewrites[i];
+ }
+ }
+
+ // Note that we pass "false" for parseComments here. It doesn't
+ // seem worthwhile to support declarations in comments-in-comments
+ // here, as there's no way to generate those using the tools, and
+ // users would be crazy to write such things.
+ let newDecls = parseDeclarationsInternal(isCssPropertyKnown, rewrittenText,
+ false, true, commentOverride);
+ for (let decl of newDecls) {
+ decl.offsets[0] = rewrites[decl.offsets[0]];
+ decl.offsets[1] = rewrites[decl.offsets[1]];
+ decl.colonOffsets[0] = rewrites[decl.colonOffsets[0]];
+ decl.colonOffsets[1] = rewrites[decl.colonOffsets[1]];
+ decl.commentOffsets = [startOffset, endOffset];
+ }
+ return newDecls;
+}
+
+/**
+ * A helper function for parseDeclarationsInternal that creates a new
+ * empty declaration.
+ *
+ * @return {object} an empty declaration of the form returned by
+ * parseDeclarations
+ */
+function getEmptyDeclaration() {
+ return {name: "", value: "", priority: "",
+ terminator: "",
+ offsets: [undefined, undefined],
+ colonOffsets: false};
+}
+
+/**
+ * A helper function that does all the parsing work for
+ * parseDeclarations. This is separate because it has some arguments
+ * that don't make sense in isolation.
+ *
+ * The return value and arguments are like parseDeclarations, with
+ * these additional arguments.
+ *
+ * @param {Function} isCssPropertyKnown
+ * Function to check if the CSS property is known.
+ * @param {Boolean} inComment
+ * If true, assume that this call is parsing some text
+ * which came from a comment in another declaration.
+ * In this case some heuristics are used to avoid parsing
+ * text which isn't obviously a series of declarations.
+ * @param {Boolean} commentOverride
+ * This only makes sense when inComment=true.
+ * When true, assume that the comment was generated by
+ * rewriteDeclarations, and skip the usual name-checking
+ * heuristic.
+ */
+function parseDeclarationsInternal(isCssPropertyKnown, inputString,
+ parseComments, inComment, commentOverride) {
+ if (inputString === null || inputString === undefined) {
+ throw new Error("empty input string");
+ }
+
+ let lexer = getCSSLexer(inputString);
+
+ let declarations = [getEmptyDeclaration()];
+ let lastProp = declarations[0];
+
+ let current = "", hasBang = false;
+ while (true) {
+ let token = lexer.nextToken();
+ if (!token) {
+ break;
+ }
+
+ // Ignore HTML comment tokens (but parse anything they might
+ // happen to surround).
+ if (token.tokenType === "htmlcomment") {
+ continue;
+ }
+
+ // Update the start and end offsets of the declaration, but only
+ // when we see a significant token.
+ if (token.tokenType !== "whitespace" && token.tokenType !== "comment") {
+ if (lastProp.offsets[0] === undefined) {
+ lastProp.offsets[0] = token.startOffset;
+ }
+ lastProp.offsets[1] = token.endOffset;
+ } else if (lastProp.name && !current && !hasBang &&
+ !lastProp.priority && lastProp.colonOffsets[1]) {
+ // Whitespace appearing after the ":" is attributed to it.
+ lastProp.colonOffsets[1] = token.endOffset;
+ }
+
+ if (token.tokenType === "symbol" && token.text === ":") {
+ if (!lastProp.name) {
+ // Set the current declaration name if there's no name yet
+ lastProp.name = current.trim();
+ lastProp.colonOffsets = [token.startOffset, token.endOffset];
+ current = "";
+ hasBang = false;
+
+ // When parsing a comment body, if the left-hand-side is not a
+ // valid property name, then drop it and stop parsing.
+ if (inComment && !commentOverride &&
+ !isCssPropertyKnown(lastProp.name)) {
+ lastProp.name = null;
+ break;
+ }
+ } else {
+ // Otherwise, just append ':' to the current value (declaration value
+ // with colons)
+ current += ":";
+ }
+ } else if (token.tokenType === "symbol" && token.text === ";") {
+ lastProp.terminator = "";
+ // When parsing a comment, if the name hasn't been set, then we
+ // have probably just seen an ordinary semicolon used in text,
+ // so drop this and stop parsing.
+ if (inComment && !lastProp.name) {
+ current = "";
+ break;
+ }
+ lastProp.value = current.trim();
+ current = "";
+ hasBang = false;
+ declarations.push(getEmptyDeclaration());
+ lastProp = declarations[declarations.length - 1];
+ } else if (token.tokenType === "ident") {
+ if (token.text === "important" && hasBang) {
+ lastProp.priority = "important";
+ hasBang = false;
+ } else {
+ if (hasBang) {
+ current += "!";
+ }
+ // Re-escape the token to avoid dequoting problems.
+ // See bug 1287620.
+ current += CSS.escape(token.text);
+ }
+ } else if (token.tokenType === "symbol" && token.text === "!") {
+ hasBang = true;
+ } else if (token.tokenType === "whitespace") {
+ if (current !== "") {
+ current += " ";
+ }
+ } else if (token.tokenType === "comment") {
+ if (parseComments && !lastProp.name && !lastProp.value) {
+ let commentText = inputString.substring(token.startOffset + 2,
+ token.endOffset - 2);
+ let newDecls = parseCommentDeclarations(isCssPropertyKnown, commentText,
+ token.startOffset,
+ token.endOffset);
+
+ // Insert the new declarations just before the final element.
+ let lastDecl = declarations.pop();
+ declarations = [...declarations, ...newDecls, lastDecl];
+ } else {
+ current += " ";
+ }
+ } else {
+ current += inputString.substring(token.startOffset, token.endOffset);
+ }
+ }
+
+ // Handle whatever trailing properties or values might still be there
+ if (current) {
+ if (!lastProp.name) {
+ // Ignore this case in comments.
+ if (!inComment) {
+ // Trailing property found, e.g. p1:v1;p2:v2;p3
+ lastProp.name = current.trim();
+ }
+ } else {
+ // Trailing value found, i.e. value without an ending ;
+ lastProp.value = current.trim();
+ let terminator = lexer.performEOFFixup("", true);
+ lastProp.terminator = terminator + ";";
+ // If the input was unterminated, attribute the remainder to
+ // this property. This avoids some bad behavior when rewriting
+ // an unterminated comment.
+ if (terminator) {
+ lastProp.offsets[1] = inputString.length;
+ }
+ }
+ }
+
+ // Remove declarations that have neither a name nor a value
+ declarations = declarations.filter(prop => prop.name || prop.value);
+
+ return declarations;
+}
+
+/**
+ * Returns an array of CSS declarations given a string.
+ * For example, parseDeclarations(isCssPropertyKnown, "width: 1px; height: 1px")
+ * would return:
+ * [{name:"width", value: "1px"}, {name: "height", "value": "1px"}]
+ *
+ * The input string is assumed to only contain declarations so { and }
+ * characters will be treated as part of either the property or value,
+ * depending where it's found.
+ *
+ * @param {Function} isCssPropertyKnown
+ * A function to check if the CSS property is known. This is either an
+ * internal server function or from the CssPropertiesFront.
+ * that are supported by the server.
+ * @param {String} inputString
+ * An input string of CSS
+ * @param {Boolean} parseComments
+ * If true, try to parse the contents of comments as well.
+ * A comment will only be parsed if it occurs outside of
+ * the body of some other declaration.
+ * @return {Array} an array of objects with the following signature:
+ * [{"name": string, "value": string, "priority": string,
+ * "terminator": string,
+ * "offsets": [start, end], "colonOffsets": [start, end]},
+ * ...]
+ * Here, "offsets" holds the offsets of the start and end
+ * of the declaration text, in a form suitable for use with
+ * String.substring.
+ * "terminator" is a string to use to terminate the declaration,
+ * usually "" to mean no additional termination is needed.
+ * "colonOffsets" holds the start and end locations of the
+ * ":" that separates the property name from the value.
+ * If the declaration appears in a comment, then there will
+ * be an additional {"commentOffsets": [start, end] property
+ * on the object, which will hold the offsets of the start
+ * and end of the enclosing comment.
+ */
+function parseDeclarations(isCssPropertyKnown, inputString,
+ parseComments = false) {
+ return parseDeclarationsInternal(isCssPropertyKnown, inputString,
+ parseComments, false, false);
+}
+
+/**
+ * Return an object that can be used to rewrite declarations in some
+ * source text. The source text and parsing are handled in the same
+ * way as @see parseDeclarations, with |parseComments| being true.
+ * Rewriting is done by calling one of the modification functions like
+ * setPropertyEnabled. The returned object has the same interface
+ * as @see RuleModificationList.
+ *
+ * An example showing how to disable the 3rd property in a rule:
+ *
+ * let rewriter = new RuleRewriter(isCssPropertyKnown, ruleActor,
+ * ruleActor.authoredText);
+ * rewriter.setPropertyEnabled(3, "color", false);
+ * rewriter.apply().then(() => { ... the change is made ... });
+ *
+ * The exported rewriting methods are |renameProperty|, |setPropertyEnabled|,
+ * |createProperty|, |setProperty|, and |removeProperty|. The |apply|
+ * method can be used to send the edited text to the StyleRuleActor;
+ * |getDefaultIndentation| is useful for the methods requiring a
+ * default indentation value; and |getResult| is useful for testing.
+ *
+ * Additionally, editing will set the |changedDeclarations| property
+ * on this object. This property has the same form as the |changed|
+ * property of the object returned by |getResult|.
+ *
+ * @param {Function} isCssPropertyKnown
+ * A function to check if the CSS property is known. This is either an
+ * internal server function or from the CssPropertiesFront.
+ * that are supported by the server. Note that if Bug 1222047
+ * is completed then isCssPropertyKnown will not need to be passed in.
+ * The CssProperty front will be able to obtained directly from the
+ * RuleRewriter.
+ * @param {StyleRuleFront} rule The style rule to use. Note that this
+ * is only needed by the |apply| and |getDefaultIndentation| methods;
+ * and in particular for testing it can be |null|.
+ * @param {String} inputString The CSS source text to parse and modify.
+ * @return {Object} an object that can be used to rewrite the input text.
+ */
+function RuleRewriter(isCssPropertyKnown, rule, inputString) {
+ this.rule = rule;
+ this.isCssPropertyKnown = isCssPropertyKnown;
+
+ // Keep track of which any declarations we had to rewrite while
+ // performing the requested action.
+ this.changedDeclarations = {};
+
+ // If not null, a promise that must be wait upon before |apply| can
+ // do its work.
+ this.editPromise = null;
+
+ // If the |defaultIndentation| property is set, then it is used;
+ // otherwise the RuleRewriter will try to compute the default
+ // indentation based on the style sheet's text. This override
+ // facility is for testing.
+ this.defaultIndentation = null;
+
+ this.startInitialization(inputString);
+}
+
+RuleRewriter.prototype = {
+ /**
+ * An internal function to initialize the rewriter with a given
+ * input string.
+ *
+ * @param {String} inputString the input to use
+ */
+ startInitialization: function (inputString) {
+ this.inputString = inputString;
+ // Whether there are any newlines in the input text.
+ this.hasNewLine = /[\r\n]/.test(this.inputString);
+ // The declarations.
+ this.declarations = parseDeclarations(this.isCssPropertyKnown, this.inputString,
+ true);
+ this.decl = null;
+ this.result = null;
+ },
+
+ /**
+ * An internal function to complete initialization and set some
+ * properties for further processing.
+ *
+ * @param {Number} index The index of the property to modify
+ */
+ completeInitialization: function (index) {
+ if (index < 0) {
+ throw new Error("Invalid index " + index + ". Expected positive integer");
+ }
+ // |decl| is the declaration to be rewritten, or null if there is no
+ // declaration corresponding to |index|.
+ // |result| is used to accumulate the result text.
+ if (index < this.declarations.length) {
+ this.decl = this.declarations[index];
+ this.result = this.inputString.substring(0, this.decl.offsets[0]);
+ } else {
+ this.decl = null;
+ this.result = this.inputString;
+ }
+ },
+
+ /**
+ * A helper function to compute the indentation of some text. This
+ * examines the rule's existing text to guess the indentation to use;
+ * unlike |getDefaultIndentation|, which examines the entire style
+ * sheet.
+ *
+ * @param {String} string the input text
+ * @param {Number} offset the offset at which to compute the indentation
+ * @return {String} the indentation at the indicated position
+ */
+ getIndentation: function (string, offset) {
+ let originalOffset = offset;
+ for (--offset; offset >= 0; --offset) {
+ let c = string[offset];
+ if (c === "\r" || c === "\n" || c === "\f") {
+ return string.substring(offset + 1, originalOffset);
+ }
+ if (c !== " " && c !== "\t") {
+ // Found some non-whitespace character before we found a newline
+ // -- let's reset the starting point and keep going, as we saw
+ // something on the line before the declaration.
+ originalOffset = offset;
+ }
+ }
+ // Ran off the end.
+ return "";
+ },
+
+ /**
+ * Modify a property value to ensure it is "lexically safe" for
+ * insertion into a style sheet. This function doesn't attempt to
+ * ensure that the resulting text is a valid value for the given
+ * property; but rather just that inserting the text into the style
+ * sheet will not cause unwanted changes to other rules or
+ * declarations.
+ *
+ * @param {String} text The input text. This should include the trailing ";".
+ * @return {Array} An array of the form [anySanitized, text], where
+ * |anySanitized| is a boolean that indicates
+ * whether anything substantive has changed; and
+ * where |text| is the text that has been rewritten
+ * to be "lexically safe".
+ */
+ sanitizePropertyValue: function (text) {
+ let lexer = getCSSLexer(text);
+
+ let result = "";
+ let previousOffset = 0;
+ let braceDepth = 0;
+ let anySanitized = false;
+ while (true) {
+ let token = lexer.nextToken();
+ if (!token) {
+ break;
+ }
+
+ if (token.tokenType === "symbol") {
+ switch (token.text) {
+ case ";":
+ // We simply drop the ";" here. This lets us cope with
+ // declarations that don't have a ";" and also other
+ // termination. The caller handles adding the ";" again.
+ result += text.substring(previousOffset, token.startOffset);
+ previousOffset = token.endOffset;
+ break;
+
+ case "{":
+ ++braceDepth;
+ break;
+
+ case "}":
+ --braceDepth;
+ if (braceDepth < 0) {
+ // Found an unmatched close bracket.
+ braceDepth = 0;
+ // Copy out text from |previousOffset|.
+ result += text.substring(previousOffset, token.startOffset);
+ // Quote the offending symbol.
+ result += "\\" + token.text;
+ previousOffset = token.endOffset;
+ anySanitized = true;
+ }
+ break;
+ }
+ }
+ }
+
+ // Copy out any remaining text, then any needed terminators.
+ result += text.substring(previousOffset, text.length);
+ let eofFixup = lexer.performEOFFixup("", true);
+ if (eofFixup) {
+ anySanitized = true;
+ result += eofFixup;
+ }
+ return [anySanitized, result];
+ },
+
+ /**
+ * Start at |index| and skip whitespace
+ * backward in |string|. Return the index of the first
+ * non-whitespace character, or -1 if the entire string was
+ * whitespace.
+ * @param {String} string the input string
+ * @param {Number} index the index at which to start
+ * @return {Number} index of the first non-whitespace character, or -1
+ */
+ skipWhitespaceBackward: function (string, index) {
+ for (--index;
+ index >= 0 && (string[index] === " " || string[index] === "\t");
+ --index) {
+ // Nothing.
+ }
+ return index;
+ },
+
+ /**
+ * Terminate a given declaration, if needed.
+ *
+ * @param {Number} index The index of the rule to possibly
+ * terminate. It might be invalid, so this
+ * function must check for that.
+ */
+ maybeTerminateDecl: function (index) {
+ if (index < 0 || index >= this.declarations.length
+ // No need to rewrite declarations in comments.
+ || ("commentOffsets" in this.declarations[index])) {
+ return;
+ }
+
+ let termDecl = this.declarations[index];
+ let endIndex = termDecl.offsets[1];
+ // Due to an oddity of the lexer, we might have gotten a bit of
+ // extra whitespace in a trailing bad_url token -- so be sure to
+ // skip that as well.
+ endIndex = this.skipWhitespaceBackward(this.result, endIndex) + 1;
+
+ let trailingText = this.result.substring(endIndex);
+ if (termDecl.terminator) {
+ // Insert the terminator just at the end of the declaration,
+ // before any trailing whitespace.
+ this.result = this.result.substring(0, endIndex) + termDecl.terminator +
+ trailingText;
+ // In a couple of cases, we may have had to add something to
+ // terminate the declaration, but the termination did not
+ // actually affect the property's value -- and at this spot, we
+ // only care about reporting value changes. In particular, we
+ // might have added a plain ";", or we might have terminated a
+ // comment with "*/;". Neither of these affect the value.
+ if (termDecl.terminator !== ";" && termDecl.terminator !== "*/;") {
+ this.changedDeclarations[index] =
+ termDecl.value + termDecl.terminator.slice(0, -1);
+ }
+ }
+ // If the rule generally has newlines, but this particular
+ // declaration doesn't have a trailing newline, insert one now.
+ // Maybe this style is too weird to bother with.
+ if (this.hasNewLine && !NEWLINE_RX.test(trailingText)) {
+ this.result += "\n";
+ }
+ },
+
+ /**
+ * Sanitize the given property value and return the sanitized form.
+ * If the property is rewritten during sanitization, make a note in
+ * |changedDeclarations|.
+ *
+ * @param {String} text The property text.
+ * @param {Number} index The index of the property.
+ * @return {String} The sanitized text.
+ */
+ sanitizeText: function (text, index) {
+ let [anySanitized, sanitizedText] = this.sanitizePropertyValue(text);
+ if (anySanitized) {
+ this.changedDeclarations[index] = sanitizedText;
+ }
+ return sanitizedText;
+ },
+
+ /**
+ * Rename a declaration.
+ *
+ * @param {Number} index index of the property in the rule.
+ * @param {String} name current name of the property
+ * @param {String} newName new name of the property
+ */
+ renameProperty: function (index, name, newName) {
+ this.completeInitialization(index);
+ this.result += CSS.escape(newName);
+ // We could conceivably compute the name offsets instead so we
+ // could preserve white space and comments on the LHS of the ":".
+ this.completeCopying(this.decl.colonOffsets[0]);
+ },
+
+ /**
+ * Enable or disable a declaration
+ *
+ * @param {Number} index index of the property in the rule.
+ * @param {String} name current name of the property
+ * @param {Boolean} isEnabled true if the property should be enabled;
+ * false if it should be disabled
+ */
+ setPropertyEnabled: function (index, name, isEnabled) {
+ this.completeInitialization(index);
+ const decl = this.decl;
+ let copyOffset = decl.offsets[1];
+ if (isEnabled) {
+ // Enable it. First see if the comment start can be deleted.
+ let commentStart = decl.commentOffsets[0];
+ if (EMPTY_COMMENT_START_RX.test(this.result.substring(commentStart))) {
+ this.result = this.result.substring(0, commentStart);
+ } else {
+ this.result += "*/ ";
+ }
+
+ // Insert the name and value separately, so we can report
+ // sanitization changes properly.
+ let commentNamePart =
+ this.inputString.substring(decl.offsets[0],
+ decl.colonOffsets[1]);
+ this.result += unescapeCSSComment(commentNamePart);
+
+ // When uncommenting, we must be sure to sanitize the text, to
+ // avoid things like /* decl: }; */, which will be accepted as
+ // a property but which would break the entire style sheet.
+ let newText = this.inputString.substring(decl.colonOffsets[1],
+ decl.offsets[1]);
+ newText = unescapeCSSComment(newText).trimRight();
+ this.result += this.sanitizeText(newText, index) + ";";
+
+ // See if the comment end can be deleted.
+ let trailingText = this.inputString.substring(decl.offsets[1]);
+ if (EMPTY_COMMENT_END_RX.test(trailingText)) {
+ copyOffset = decl.commentOffsets[1];
+ } else {
+ this.result += " /*";
+ }
+ } else {
+ // Disable it. Note that we use our special comment syntax
+ // here.
+ let declText = this.inputString.substring(decl.offsets[0],
+ decl.offsets[1]);
+ this.result += "/*" + COMMENT_PARSING_HEURISTIC_BYPASS_CHAR +
+ " " + escapeCSSComment(declText) + " */";
+ }
+ this.completeCopying(copyOffset);
+ },
+
+ /**
+ * Return a promise that will be resolved to the default indentation
+ * of the rule. This is a helper for internalCreateProperty.
+ *
+ * @return {Promise} a promise that will be resolved to a string
+ * that holds the default indentation that should be used
+ * for edits to the rule.
+ */
+ getDefaultIndentation: function () {
+ return this.rule.parentStyleSheet.guessIndentation();
+ },
+
+ /**
+ * An internal function to create a new declaration. This does all
+ * the work of |createProperty|.
+ *
+ * @param {Number} index index of the property in the rule.
+ * @param {String} name name of the new property
+ * @param {String} value value of the new property
+ * @param {String} priority priority of the new property; either
+ * the empty string or "important"
+ * @param {Boolean} enabled True if the new property should be
+ * enabled, false if disabled
+ * @return {Promise} a promise that is resolved when the edit has
+ * completed
+ */
+ internalCreateProperty: Task.async(function* (index, name, value, priority, enabled) {
+ this.completeInitialization(index);
+ let newIndentation = "";
+ if (this.hasNewLine) {
+ if (this.declarations.length > 0) {
+ newIndentation = this.getIndentation(this.inputString,
+ this.declarations[0].offsets[0]);
+ } else if (this.defaultIndentation) {
+ newIndentation = this.defaultIndentation;
+ } else {
+ newIndentation = yield this.getDefaultIndentation();
+ }
+ }
+
+ this.maybeTerminateDecl(index - 1);
+
+ // If we generally have newlines, and if skipping whitespace
+ // backward stops at a newline, then insert our text before that
+ // whitespace. This ensures the indentation we computed is what
+ // is actually used.
+ let savedWhitespace = "";
+ if (this.hasNewLine) {
+ let wsOffset = this.skipWhitespaceBackward(this.result,
+ this.result.length);
+ if (this.result[wsOffset] === "\r" || this.result[wsOffset] === "\n") {
+ savedWhitespace = this.result.substring(wsOffset + 1);
+ this.result = this.result.substring(0, wsOffset + 1);
+ }
+ }
+
+ let newText = CSS.escape(name) + ": " + this.sanitizeText(value, index);
+ if (priority === "important") {
+ newText += " !important";
+ }
+ newText += ";";
+
+ if (!enabled) {
+ newText = "/*" + COMMENT_PARSING_HEURISTIC_BYPASS_CHAR + " " +
+ escapeCSSComment(newText) + " */";
+ }
+
+ this.result += newIndentation + newText;
+ if (this.hasNewLine) {
+ this.result += "\n";
+ }
+ this.result += savedWhitespace;
+
+ if (this.decl) {
+ // Still want to copy in the declaration previously at this
+ // index.
+ this.completeCopying(this.decl.offsets[0]);
+ }
+ }),
+
+ /**
+ * Create a new declaration.
+ *
+ * @param {Number} index index of the property in the rule.
+ * @param {String} name name of the new property
+ * @param {String} value value of the new property
+ * @param {String} priority priority of the new property; either
+ * the empty string or "important"
+ * @param {Boolean} enabled True if the new property should be
+ * enabled, false if disabled
+ */
+ createProperty: function (index, name, value, priority, enabled) {
+ this.editPromise = this.internalCreateProperty(index, name, value,
+ priority, enabled);
+ },
+
+ /**
+ * Set a declaration's value.
+ *
+ * @param {Number} index index of the property in the rule.
+ * This can be -1 in the case where
+ * the rule does not support setRuleText;
+ * generally for setting properties
+ * on an element's style.
+ * @param {String} name the property's name
+ * @param {String} value the property's value
+ * @param {String} priority the property's priority, either the empty
+ * string or "important"
+ */
+ setProperty: function (index, name, value, priority) {
+ this.completeInitialization(index);
+ // We might see a "set" on a previously non-existent property; in
+ // that case, act like "create".
+ if (!this.decl) {
+ this.createProperty(index, name, value, priority, true);
+ return;
+ }
+
+ // Note that this assumes that "set" never operates on disabled
+ // properties.
+ this.result += this.inputString.substring(this.decl.offsets[0],
+ this.decl.colonOffsets[1]) +
+ this.sanitizeText(value, index);
+
+ if (priority === "important") {
+ this.result += " !important";
+ }
+ this.result += ";";
+ this.completeCopying(this.decl.offsets[1]);
+ },
+
+ /**
+ * Remove a declaration.
+ *
+ * @param {Number} index index of the property in the rule.
+ * @param {String} name the name of the property to remove
+ */
+ removeProperty: function (index, name) {
+ this.completeInitialization(index);
+
+ // If asked to remove a property that does not exist, bail out.
+ if (!this.decl) {
+ return;
+ }
+
+ // If the property is disabled, then first enable it, and then
+ // delete it. We take this approach because we want to remove the
+ // entire comment if possible; but the logic for dealing with
+ // comments is hairy and already implemented in
+ // setPropertyEnabled.
+ if (this.decl.commentOffsets) {
+ this.setPropertyEnabled(index, name, true);
+ this.startInitialization(this.result);
+ this.completeInitialization(index);
+ }
+
+ let copyOffset = this.decl.offsets[1];
+ // Maybe removing this rule left us with a completely blank
+ // line. In this case, we'll delete the whole thing. We only
+ // bother with this if we're looking at sources that already
+ // have a newline somewhere.
+ if (this.hasNewLine) {
+ let nlOffset = this.skipWhitespaceBackward(this.result,
+ this.decl.offsets[0]);
+ if (nlOffset < 0 || this.result[nlOffset] === "\r" ||
+ this.result[nlOffset] === "\n") {
+ let trailingText = this.inputString.substring(copyOffset);
+ let match = BLANK_LINE_RX.exec(trailingText);
+ if (match) {
+ this.result = this.result.substring(0, nlOffset + 1);
+ copyOffset += match[0].length;
+ }
+ }
+ }
+ this.completeCopying(copyOffset);
+ },
+
+ /**
+ * An internal function to copy any trailing text to the output
+ * string.
+ *
+ * @param {Number} copyOffset Offset into |inputString| of the
+ * final text to copy to the output string.
+ */
+ completeCopying: function (copyOffset) {
+ // Add the trailing text.
+ this.result += this.inputString.substring(copyOffset);
+ },
+
+ /**
+ * Apply the modifications in this object to the associated rule.
+ *
+ * @return {Promise} A promise which will be resolved when the modifications
+ * are complete.
+ */
+ apply: function () {
+ return promise.resolve(this.editPromise).then(() => {
+ return this.rule.setRuleText(this.result);
+ });
+ },
+
+ /**
+ * Get the result of the rewriting. This is used for testing.
+ *
+ * @return {object} an object of the form {changed: object, text: string}
+ * |changed| is an object where each key is
+ * the index of a property whose value had to be
+ * rewritten during the sanitization process, and
+ * whose value is the new text of the property.
+ * |text| is the rewritten text of the rule.
+ */
+ getResult: function () {
+ return {changed: this.changedDeclarations, text: this.result};
+ },
+};
+
+/**
+ * Returns an array of the parsed CSS selector value and type given a string.
+ *
+ * The components making up the CSS selector can be extracted into 3 different
+ * types: element, attribute and pseudoclass. The object that is appended to
+ * the returned array contains the value related to one of the 3 types described
+ * along with the actual type.
+ *
+ * The following are the 3 types that can be returned in the object signature:
+ * (1) SELECTOR_ATTRIBUTE
+ * (2) SELECTOR_ELEMENT
+ * (3) SELECTOR_PSEUDO_CLASS
+ *
+ * @param {String} value
+ * The CSS selector text.
+ * @return {Array} an array of objects with the following signature:
+ * [{ "value": string, "type": integer }, ...]
+ */
+function parsePseudoClassesAndAttributes(value) {
+ if (!value) {
+ throw new Error("empty input string");
+ }
+
+ let tokens = cssTokenizer(value);
+ let result = [];
+ let current = "";
+ let functionCount = 0;
+ let hasAttribute = false;
+ let hasColon = false;
+
+ for (let token of tokens) {
+ if (token.tokenType === "ident") {
+ current += value.substring(token.startOffset, token.endOffset);
+
+ if (hasColon && !functionCount) {
+ if (current) {
+ result.push({ value: current, type: SELECTOR_PSEUDO_CLASS });
+ }
+
+ current = "";
+ hasColon = false;
+ }
+ } else if (token.tokenType === "symbol" && token.text === ":") {
+ if (!hasColon) {
+ if (current) {
+ result.push({ value: current, type: SELECTOR_ELEMENT });
+ }
+
+ current = "";
+ hasColon = true;
+ }
+
+ current += token.text;
+ } else if (token.tokenType === "function") {
+ current += value.substring(token.startOffset, token.endOffset);
+ functionCount++;
+ } else if (token.tokenType === "symbol" && token.text === ")") {
+ current += token.text;
+
+ if (hasColon && functionCount == 1) {
+ if (current) {
+ result.push({ value: current, type: SELECTOR_PSEUDO_CLASS });
+ }
+
+ current = "";
+ functionCount--;
+ hasColon = false;
+ } else {
+ functionCount--;
+ }
+ } else if (token.tokenType === "symbol" && token.text === "[") {
+ if (!hasAttribute && !functionCount) {
+ if (current) {
+ result.push({ value: current, type: SELECTOR_ELEMENT });
+ }
+
+ current = "";
+ hasAttribute = true;
+ }
+
+ current += token.text;
+ } else if (token.tokenType === "symbol" && token.text === "]") {
+ current += token.text;
+
+ if (hasAttribute && !functionCount) {
+ if (current) {
+ result.push({ value: current, type: SELECTOR_ATTRIBUTE });
+ }
+
+ current = "";
+ hasAttribute = false;
+ }
+ } else {
+ current += value.substring(token.startOffset, token.endOffset);
+ }
+ }
+
+ if (current) {
+ result.push({ value: current, type: SELECTOR_ELEMENT });
+ }
+
+ return result;
+}
+
+/**
+ * Expects a single CSS value to be passed as the input and parses the value
+ * and priority.
+ *
+ * @param {Function} isCssPropertyKnown
+ * A function to check if the CSS property is known. This is either an
+ * internal server function or from the CssPropertiesFront.
+ * that are supported by the server.
+ * @param {String} value
+ * The value from the text editor.
+ * @return {Object} an object with 'value' and 'priority' properties.
+ */
+function parseSingleValue(isCssPropertyKnown, value) {
+ let declaration = parseDeclarations(isCssPropertyKnown,
+ "a: " + value + ";")[0];
+ return {
+ value: declaration ? declaration.value : "",
+ priority: declaration ? declaration.priority : ""
+ };
+}
+
+/**
+ * Convert an angle value to degree.
+ *
+ * @param {Number} angleValue The angle value.
+ * @param {CSS_ANGLEUNIT} angleUnit The angleValue's angle unit.
+ * @return {Number} An angle value in degree.
+ */
+function getAngleValueInDegrees(angleValue, angleUnit) {
+ switch (angleUnit) {
+ case CSS_ANGLEUNIT.deg:
+ return angleValue;
+ case CSS_ANGLEUNIT.grad:
+ return angleValue * 0.9;
+ case CSS_ANGLEUNIT.rad:
+ return angleValue * 180 / Math.PI;
+ case CSS_ANGLEUNIT.turn:
+ return angleValue * 360;
+ default:
+ throw new Error("No matched angle unit.");
+ }
+}
+
+exports.cssTokenizer = cssTokenizer;
+exports.cssTokenizerWithLineColumn = cssTokenizerWithLineColumn;
+exports.escapeCSSComment = escapeCSSComment;
+// unescapeCSSComment is exported for testing.
+exports._unescapeCSSComment = unescapeCSSComment;
+exports.parseDeclarations = parseDeclarations;
+// parseCommentDeclarations is exported for testing.
+exports._parseCommentDeclarations = parseCommentDeclarations;
+exports.RuleRewriter = RuleRewriter;
+exports.parsePseudoClassesAndAttributes = parsePseudoClassesAndAttributes;
+exports.parseSingleValue = parseSingleValue;
+exports.getAngleValueInDegrees = getAngleValueInDegrees;
diff --git a/devtools/shared/css/properties-db.js b/devtools/shared/css/properties-db.js
new file mode 100644
index 000000000..32454482a
--- /dev/null
+++ b/devtools/shared/css/properties-db.js
@@ -0,0 +1,100 @@
+/* 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/. */
+
+"use strict";
+
+/**
+ * This file contains static lists of CSS properties and values. Some of the small lists
+ * are edited manually, while the larger ones are generated by a script. The comments
+ * above each list indicates how it should be updated.
+ */
+
+let db;
+
+// Allow this require to fail in case it's been deleted in the process of running
+// `mach devtools-css-db` to regenerate the database.
+try {
+ db = require("devtools/shared/css/generated/properties-db");
+} catch (error) {
+ console.error(`If this error is being displayed and "mach devtools-css-db" is not ` +
+ `being run, then it needs to be fixed.`, error);
+ db = {
+ CSS_PROPERTIES: {},
+ PSEUDO_ELEMENTS: []
+ };
+}
+
+/**
+ * All CSS types that properties can support. This list can be manually edited.
+ */
+exports.CSS_TYPES = {
+ "ANGLE": 1,
+ "COLOR": 2,
+ "FREQUENCY": 3,
+ "GRADIENT": 4,
+ "IMAGE_RECT": 5,
+ "LENGTH": 6,
+ "NUMBER": 7,
+ "PERCENTAGE": 8,
+ "TIME": 9,
+ "TIMING_FUNCTION": 10,
+ "URL": 11,
+};
+
+/**
+ * All CSS <angle> types that properties can support. This list can be manually edited.
+ */
+exports.CSS_ANGLEUNIT = {
+ "deg": "deg",
+ "rad": "rad",
+ "grad": "grad",
+ "turn": "turn"
+};
+
+/**
+ * All cubic-bezier CSS timing-function names. This list can be manually edited.
+ */
+exports.BEZIER_KEYWORDS = ["linear", "ease-in-out", "ease-in", "ease-out", "ease"];
+
+/**
+ * Functions that accept a color argument. This list can be manually edited.
+ */
+exports.COLOR_TAKING_FUNCTIONS = ["linear-gradient", "-moz-linear-gradient",
+ "repeating-linear-gradient",
+ "-moz-repeating-linear-gradient", "radial-gradient",
+ "-moz-radial-gradient", "repeating-radial-gradient",
+ "-moz-repeating-radial-gradient", "drop-shadow"];
+
+/**
+ * Functions that accept an angle argument. This list can be manually edited.
+ */
+exports.ANGLE_TAKING_FUNCTIONS = ["linear-gradient", "-moz-linear-gradient",
+ "repeating-linear-gradient",
+ "-moz-repeating-linear-gradient", "rotate", "rotateX",
+ "rotateY", "rotateZ", "rotate3d", "skew", "skewX",
+ "skewY", "hue-rotate"];
+
+/**
+ * The list of all CSS Pseudo Elements.
+ *
+ * This list can be updated with `mach devtools-css-db`.
+ */
+exports.PSEUDO_ELEMENTS = db.PSEUDO_ELEMENTS;
+
+/**
+ * A list of CSS Properties and their various characteristics. This is used on the
+ * client-side when the CssPropertiesActor is not found, or when the client and server
+ * are the same version. A single property takes the form:
+ *
+ * "animation": {
+ * "isInherited": false,
+ * "supports": [ 7, 9, 10 ]
+ * }
+ */
+exports.CSS_PROPERTIES = db.CSS_PROPERTIES;
+
+exports.CSS_PROPERTIES_DB = {
+ properties: db.CSS_PROPERTIES,
+ pseudoElements: db.PSEUDO_ELEMENTS
+};