Wed, 31 Dec 2014 06:09:35 +0100
Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.
michael@0 | 1 | /* -*- Mode: Java; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */ |
michael@0 | 2 | /* vim: set shiftwidth=4 tabstop=4 autoindent cindent noexpandtab: */ |
michael@0 | 3 | /* This Source Code Form is subject to the terms of the Mozilla Public |
michael@0 | 4 | * License, v. 2.0. If a copy of the MPL was not distributed with this |
michael@0 | 5 | * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ |
michael@0 | 6 | |
michael@0 | 7 | // True longhand properties. |
michael@0 | 8 | const CSS_TYPE_LONGHAND = 0; |
michael@0 | 9 | |
michael@0 | 10 | // True shorthand properties. |
michael@0 | 11 | const CSS_TYPE_TRUE_SHORTHAND = 1; |
michael@0 | 12 | |
michael@0 | 13 | // Properties that we handle as shorthands but were longhands either in |
michael@0 | 14 | // the current spec or earlier versions of the spec. |
michael@0 | 15 | const CSS_TYPE_SHORTHAND_AND_LONGHAND = 2; |
michael@0 | 16 | |
michael@0 | 17 | // Each property has the following fields: |
michael@0 | 18 | // domProp: The name of the relevant member of nsIDOM[NS]CSS2Properties |
michael@0 | 19 | // inherited: Whether the property is inherited by default (stated as |
michael@0 | 20 | // yes or no in the property header in all CSS specs) |
michael@0 | 21 | // type: see above |
michael@0 | 22 | // alias_for: optional, indicates that the property is an alias for |
michael@0 | 23 | // some other property that is the preferred serialization. (Type |
michael@0 | 24 | // must not be CSS_TYPE_LONGHAND.) |
michael@0 | 25 | // get_computed: if present, the property's computed value shows up on |
michael@0 | 26 | // another property, and this is a function used to get it |
michael@0 | 27 | // initial_values: Values whose computed value should be the same as the |
michael@0 | 28 | // computed value for the property's initial value. |
michael@0 | 29 | // other_values: Values whose computed value should be different from the |
michael@0 | 30 | // computed value for the property's initial value. |
michael@0 | 31 | // XXX Should have a third field for values whose computed value may or |
michael@0 | 32 | // may not be the same as for the property's initial value. |
michael@0 | 33 | // invalid_values: Things that are not values for the property and |
michael@0 | 34 | // should be rejected, but which are balanced and should not absorb |
michael@0 | 35 | // what follows |
michael@0 | 36 | // quirks_values: Values that should be accepted in quirks mode only, |
michael@0 | 37 | // mapped to the values they are equivalent to. |
michael@0 | 38 | // unbalanced_values: Things that are not values for the property and |
michael@0 | 39 | // should be rejected, and which also contain unbalanced constructs |
michael@0 | 40 | // that should absorb what follows |
michael@0 | 41 | |
michael@0 | 42 | // Helper functions used to construct gCSSProperties. |
michael@0 | 43 | |
michael@0 | 44 | function initial_font_family_is_sans_serif() |
michael@0 | 45 | { |
michael@0 | 46 | // The initial value of 'font-family' might be 'serif' or |
michael@0 | 47 | // 'sans-serif'. |
michael@0 | 48 | var div = document.createElement("div"); |
michael@0 | 49 | div.setAttribute("style", "font: initial"); |
michael@0 | 50 | return getComputedStyle(div, "").fontFamily == "sans-serif"; |
michael@0 | 51 | } |
michael@0 | 52 | var gInitialFontFamilyIsSansSerif = initial_font_family_is_sans_serif(); |
michael@0 | 53 | |
michael@0 | 54 | // shared by background-image and border-image-source |
michael@0 | 55 | var validGradientAndElementValues = [ |
michael@0 | 56 | "-moz-element(#a)", |
michael@0 | 57 | "-moz-element( #a )", |
michael@0 | 58 | "-moz-element(#a-1)", |
michael@0 | 59 | "-moz-element(#a\\:1)", |
michael@0 | 60 | /* gradient torture test */ |
michael@0 | 61 | "linear-gradient(red, blue)", |
michael@0 | 62 | "linear-gradient(red, yellow, blue)", |
michael@0 | 63 | "linear-gradient(red 1px, yellow 20%, blue 24em, green)", |
michael@0 | 64 | "linear-gradient(red, yellow, green, blue 50%)", |
michael@0 | 65 | "linear-gradient(red -50%, yellow -25%, green, blue)", |
michael@0 | 66 | "linear-gradient(red -99px, yellow, green, blue 120%)", |
michael@0 | 67 | "linear-gradient(#ffff00, #ef3, rgba(10, 20, 30, 0.4))", |
michael@0 | 68 | "linear-gradient(rgba(10, 20, 30, 0.4), #ffff00, #ef3)", |
michael@0 | 69 | |
michael@0 | 70 | "linear-gradient(to top, red, blue)", |
michael@0 | 71 | "linear-gradient(to bottom, red, blue)", |
michael@0 | 72 | "linear-gradient(to left, red, blue)", |
michael@0 | 73 | "linear-gradient(to right, red, blue)", |
michael@0 | 74 | "linear-gradient(to top left, red, blue)", |
michael@0 | 75 | "linear-gradient(to top right, red, blue)", |
michael@0 | 76 | "linear-gradient(to bottom left, red, blue)", |
michael@0 | 77 | "linear-gradient(to bottom right, red, blue)", |
michael@0 | 78 | "linear-gradient(to left top, red, blue)", |
michael@0 | 79 | "linear-gradient(to left bottom, red, blue)", |
michael@0 | 80 | "linear-gradient(to right top, red, blue)", |
michael@0 | 81 | "linear-gradient(to right bottom, red, blue)", |
michael@0 | 82 | |
michael@0 | 83 | "linear-gradient(-33deg, red, blue)", |
michael@0 | 84 | "linear-gradient(30grad, red, blue)", |
michael@0 | 85 | "linear-gradient(10deg, red, blue)", |
michael@0 | 86 | "linear-gradient(1turn, red, blue)", |
michael@0 | 87 | "linear-gradient(.414rad, red, blue)", |
michael@0 | 88 | |
michael@0 | 89 | "-moz-linear-gradient(red, blue)", |
michael@0 | 90 | "-moz-linear-gradient(red, yellow, blue)", |
michael@0 | 91 | "-moz-linear-gradient(red 1px, yellow 20%, blue 24em, green)", |
michael@0 | 92 | "-moz-linear-gradient(red, yellow, green, blue 50%)", |
michael@0 | 93 | "-moz-linear-gradient(red -50%, yellow -25%, green, blue)", |
michael@0 | 94 | "-moz-linear-gradient(red -99px, yellow, green, blue 120%)", |
michael@0 | 95 | "-moz-linear-gradient(#ffff00, #ef3, rgba(10, 20, 30, 0.4))", |
michael@0 | 96 | "-moz-linear-gradient(rgba(10, 20, 30, 0.4), #ffff00, #ef3)", |
michael@0 | 97 | |
michael@0 | 98 | "-moz-linear-gradient(to top, red, blue)", |
michael@0 | 99 | "-moz-linear-gradient(to bottom, red, blue)", |
michael@0 | 100 | "-moz-linear-gradient(to left, red, blue)", |
michael@0 | 101 | "-moz-linear-gradient(to right, red, blue)", |
michael@0 | 102 | "-moz-linear-gradient(to top left, red, blue)", |
michael@0 | 103 | "-moz-linear-gradient(to top right, red, blue)", |
michael@0 | 104 | "-moz-linear-gradient(to bottom left, red, blue)", |
michael@0 | 105 | "-moz-linear-gradient(to bottom right, red, blue)", |
michael@0 | 106 | "-moz-linear-gradient(to left top, red, blue)", |
michael@0 | 107 | "-moz-linear-gradient(to left bottom, red, blue)", |
michael@0 | 108 | "-moz-linear-gradient(to right top, red, blue)", |
michael@0 | 109 | "-moz-linear-gradient(to right bottom, red, blue)", |
michael@0 | 110 | |
michael@0 | 111 | "-moz-linear-gradient(top left, red, blue)", |
michael@0 | 112 | "-moz-linear-gradient(0 0, red, blue)", |
michael@0 | 113 | "-moz-linear-gradient(20% bottom, red, blue)", |
michael@0 | 114 | "-moz-linear-gradient(center 20%, red, blue)", |
michael@0 | 115 | "-moz-linear-gradient(left 35px, red, blue)", |
michael@0 | 116 | "-moz-linear-gradient(10% 10em, red, blue)", |
michael@0 | 117 | "-moz-linear-gradient(44px top, red, blue)", |
michael@0 | 118 | |
michael@0 | 119 | "-moz-linear-gradient(top left 45deg, red, blue)", |
michael@0 | 120 | "-moz-linear-gradient(20% bottom -300deg, red, blue)", |
michael@0 | 121 | "-moz-linear-gradient(center 20% 1.95929rad, red, blue)", |
michael@0 | 122 | "-moz-linear-gradient(left 35px 30grad, red, blue)", |
michael@0 | 123 | "-moz-linear-gradient(left 35px 0.1turn, red, blue)", |
michael@0 | 124 | "-moz-linear-gradient(10% 10em 99999deg, red, blue)", |
michael@0 | 125 | "-moz-linear-gradient(44px top -33deg, red, blue)", |
michael@0 | 126 | |
michael@0 | 127 | "-moz-linear-gradient(-33deg, red, blue)", |
michael@0 | 128 | "-moz-linear-gradient(30grad left 35px, red, blue)", |
michael@0 | 129 | "-moz-linear-gradient(10deg 20px, red, blue)", |
michael@0 | 130 | "-moz-linear-gradient(1turn 20px, red, blue)", |
michael@0 | 131 | "-moz-linear-gradient(.414rad bottom, red, blue)", |
michael@0 | 132 | |
michael@0 | 133 | "-moz-linear-gradient(blue calc(0px) ,green calc(25%) ,red calc(40px) ,blue calc(60px) , yellow calc(100px))", |
michael@0 | 134 | "-moz-linear-gradient(-33deg, blue calc(-25%) ,red 40px)", |
michael@0 | 135 | "-moz-linear-gradient(10deg, blue calc(100px + -25%),red calc(40px))", |
michael@0 | 136 | "-moz-linear-gradient(10deg, blue calc(-25px),red calc(100%))", |
michael@0 | 137 | "-moz-linear-gradient(.414rad, blue calc(100px + -25px) ,green calc(100px + -25px) ,red calc(100px + -25%) ,blue calc(-25px) , yellow calc(-25px))", |
michael@0 | 138 | "-moz-linear-gradient(1turn, blue calc(-25%) ,green calc(25px) ,red calc(25%),blue calc(0px),white 50px, yellow calc(-25px))", |
michael@0 | 139 | |
michael@0 | 140 | "radial-gradient(red, blue)", |
michael@0 | 141 | "radial-gradient(red, yellow, blue)", |
michael@0 | 142 | "radial-gradient(red 1px, yellow 20%, blue 24em, green)", |
michael@0 | 143 | "radial-gradient(red, yellow, green, blue 50%)", |
michael@0 | 144 | "radial-gradient(red -50%, yellow -25%, green, blue)", |
michael@0 | 145 | "radial-gradient(red -99px, yellow, green, blue 120%)", |
michael@0 | 146 | "radial-gradient(#ffff00, #ef3, rgba(10, 20, 30, 0.4))", |
michael@0 | 147 | |
michael@0 | 148 | "radial-gradient(0 0, red, blue)", |
michael@0 | 149 | "radial-gradient(rgba(10, 20, 30, 0.4), #ffff00, #ef3)", |
michael@0 | 150 | |
michael@0 | 151 | "radial-gradient(at top left, red, blue)", |
michael@0 | 152 | "radial-gradient(at 20% bottom, red, blue)", |
michael@0 | 153 | "radial-gradient(at center 20%, red, blue)", |
michael@0 | 154 | "radial-gradient(at left 35px, red, blue)", |
michael@0 | 155 | "radial-gradient(at 10% 10em, red, blue)", |
michael@0 | 156 | "radial-gradient(at 44px top, red, blue)", |
michael@0 | 157 | "radial-gradient(at 0 0, red, blue)", |
michael@0 | 158 | |
michael@0 | 159 | "radial-gradient(farthest-corner, red, blue)", |
michael@0 | 160 | "radial-gradient(circle, red, blue)", |
michael@0 | 161 | "radial-gradient(ellipse closest-corner, red, blue)", |
michael@0 | 162 | "radial-gradient(closest-corner ellipse, red, blue)", |
michael@0 | 163 | |
michael@0 | 164 | "radial-gradient(43px, red, blue)", |
michael@0 | 165 | "radial-gradient(43px 43px, red, blue)", |
michael@0 | 166 | "radial-gradient(50% 50%, red, blue)", |
michael@0 | 167 | "radial-gradient(43px 50%, red, blue)", |
michael@0 | 168 | "radial-gradient(50% 43px, red, blue)", |
michael@0 | 169 | "radial-gradient(circle 43px, red, blue)", |
michael@0 | 170 | "radial-gradient(43px circle, red, blue)", |
michael@0 | 171 | "radial-gradient(ellipse 43px 43px, red, blue)", |
michael@0 | 172 | "radial-gradient(ellipse 50% 50%, red, blue)", |
michael@0 | 173 | "radial-gradient(ellipse 43px 50%, red, blue)", |
michael@0 | 174 | "radial-gradient(ellipse 50% 43px, red, blue)", |
michael@0 | 175 | "radial-gradient(50% 43px ellipse, red, blue)", |
michael@0 | 176 | |
michael@0 | 177 | "radial-gradient(farthest-corner at top left, red, blue)", |
michael@0 | 178 | "radial-gradient(ellipse closest-corner at 45px, red, blue)", |
michael@0 | 179 | "radial-gradient(circle farthest-side at 45px, red, blue)", |
michael@0 | 180 | "radial-gradient(closest-side ellipse at 50%, red, blue)", |
michael@0 | 181 | "radial-gradient(farthest-corner circle at 4em, red, blue)", |
michael@0 | 182 | |
michael@0 | 183 | "radial-gradient(30% 40% at top left, red, blue)", |
michael@0 | 184 | "radial-gradient(50px 60px at 15% 20%, red, blue)", |
michael@0 | 185 | "radial-gradient(7em 8em at 45px, red, blue)", |
michael@0 | 186 | |
michael@0 | 187 | "-moz-radial-gradient(red, blue)", |
michael@0 | 188 | "-moz-radial-gradient(red, yellow, blue)", |
michael@0 | 189 | "-moz-radial-gradient(red 1px, yellow 20%, blue 24em, green)", |
michael@0 | 190 | "-moz-radial-gradient(red, yellow, green, blue 50%)", |
michael@0 | 191 | "-moz-radial-gradient(red -50%, yellow -25%, green, blue)", |
michael@0 | 192 | "-moz-radial-gradient(red -99px, yellow, green, blue 120%)", |
michael@0 | 193 | "-moz-radial-gradient(#ffff00, #ef3, rgba(10, 20, 30, 0.4))", |
michael@0 | 194 | |
michael@0 | 195 | "-moz-radial-gradient(top left, red, blue)", |
michael@0 | 196 | "-moz-radial-gradient(20% bottom, red, blue)", |
michael@0 | 197 | "-moz-radial-gradient(center 20%, red, blue)", |
michael@0 | 198 | "-moz-radial-gradient(left 35px, red, blue)", |
michael@0 | 199 | "-moz-radial-gradient(10% 10em, red, blue)", |
michael@0 | 200 | "-moz-radial-gradient(44px top, red, blue)", |
michael@0 | 201 | |
michael@0 | 202 | "-moz-radial-gradient(top left 45deg, red, blue)", |
michael@0 | 203 | "-moz-radial-gradient(0 0, red, blue)", |
michael@0 | 204 | "-moz-radial-gradient(20% bottom -300deg, red, blue)", |
michael@0 | 205 | "-moz-radial-gradient(center 20% 1.95929rad, red, blue)", |
michael@0 | 206 | "-moz-radial-gradient(left 35px 30grad, red, blue)", |
michael@0 | 207 | "-moz-radial-gradient(10% 10em 99999deg, red, blue)", |
michael@0 | 208 | "-moz-radial-gradient(44px top -33deg, red, blue)", |
michael@0 | 209 | "-moz-radial-gradient(rgba(10, 20, 30, 0.4), #ffff00, #ef3)", |
michael@0 | 210 | |
michael@0 | 211 | "-moz-radial-gradient(-33deg, red, blue)", |
michael@0 | 212 | "-moz-radial-gradient(30grad left 35px, red, blue)", |
michael@0 | 213 | "-moz-radial-gradient(10deg 20px, red, blue)", |
michael@0 | 214 | "-moz-radial-gradient(.414rad bottom, red, blue)", |
michael@0 | 215 | |
michael@0 | 216 | "-moz-radial-gradient(cover, red, blue)", |
michael@0 | 217 | "-moz-radial-gradient(circle, red, blue)", |
michael@0 | 218 | "-moz-radial-gradient(ellipse closest-corner, red, blue)", |
michael@0 | 219 | "-moz-radial-gradient(farthest-side circle, red, blue)", |
michael@0 | 220 | |
michael@0 | 221 | "-moz-radial-gradient(top left, cover, red, blue)", |
michael@0 | 222 | "-moz-radial-gradient(15% 20%, circle, red, blue)", |
michael@0 | 223 | "-moz-radial-gradient(45px, ellipse closest-corner, red, blue)", |
michael@0 | 224 | "-moz-radial-gradient(45px, farthest-side circle, red, blue)", |
michael@0 | 225 | |
michael@0 | 226 | "-moz-radial-gradient(99deg, cover, red, blue)", |
michael@0 | 227 | "-moz-radial-gradient(-1.2345rad, circle, red, blue)", |
michael@0 | 228 | "-moz-radial-gradient(399grad, ellipse closest-corner, red, blue)", |
michael@0 | 229 | "-moz-radial-gradient(399grad, farthest-side circle, red, blue)", |
michael@0 | 230 | |
michael@0 | 231 | "-moz-radial-gradient(top left 99deg, cover, red, blue)", |
michael@0 | 232 | "-moz-radial-gradient(15% 20% -1.2345rad, circle, red, blue)", |
michael@0 | 233 | "-moz-radial-gradient(45px 399grad, ellipse closest-corner, red, blue)", |
michael@0 | 234 | "-moz-radial-gradient(45px 399grad, farthest-side circle, red, blue)", |
michael@0 | 235 | |
michael@0 | 236 | "-moz-repeating-linear-gradient(red, blue)", |
michael@0 | 237 | "-moz-repeating-linear-gradient(red, yellow, blue)", |
michael@0 | 238 | "-moz-repeating-linear-gradient(red 1px, yellow 20%, blue 24em, green)", |
michael@0 | 239 | "-moz-repeating-linear-gradient(red, yellow, green, blue 50%)", |
michael@0 | 240 | "-moz-repeating-linear-gradient(red -50%, yellow -25%, green, blue)", |
michael@0 | 241 | "-moz-repeating-linear-gradient(red -99px, yellow, green, blue 120%)", |
michael@0 | 242 | "-moz-repeating-linear-gradient(#ffff00, #ef3, rgba(10, 20, 30, 0.4))", |
michael@0 | 243 | "-moz-repeating-linear-gradient(rgba(10, 20, 30, 0.4), #ffff00, #ef3)", |
michael@0 | 244 | |
michael@0 | 245 | "-moz-repeating-linear-gradient(to top, red, blue)", |
michael@0 | 246 | "-moz-repeating-linear-gradient(to bottom, red, blue)", |
michael@0 | 247 | "-moz-repeating-linear-gradient(to left, red, blue)", |
michael@0 | 248 | "-moz-repeating-linear-gradient(to right, red, blue)", |
michael@0 | 249 | "-moz-repeating-linear-gradient(to top left, red, blue)", |
michael@0 | 250 | "-moz-repeating-linear-gradient(to top right, red, blue)", |
michael@0 | 251 | "-moz-repeating-linear-gradient(to bottom left, red, blue)", |
michael@0 | 252 | "-moz-repeating-linear-gradient(to bottom right, red, blue)", |
michael@0 | 253 | "-moz-repeating-linear-gradient(to left top, red, blue)", |
michael@0 | 254 | "-moz-repeating-linear-gradient(to left bottom, red, blue)", |
michael@0 | 255 | "-moz-repeating-linear-gradient(to right top, red, blue)", |
michael@0 | 256 | "-moz-repeating-linear-gradient(to right bottom, red, blue)", |
michael@0 | 257 | |
michael@0 | 258 | "-moz-repeating-linear-gradient(top left, red, blue)", |
michael@0 | 259 | "-moz-repeating-linear-gradient(0 0, red, blue)", |
michael@0 | 260 | "-moz-repeating-linear-gradient(20% bottom, red, blue)", |
michael@0 | 261 | "-moz-repeating-linear-gradient(center 20%, red, blue)", |
michael@0 | 262 | "-moz-repeating-linear-gradient(left 35px, red, blue)", |
michael@0 | 263 | "-moz-repeating-linear-gradient(10% 10em, red, blue)", |
michael@0 | 264 | "-moz-repeating-linear-gradient(44px top, red, blue)", |
michael@0 | 265 | |
michael@0 | 266 | "-moz-repeating-linear-gradient(top left 45deg, red, blue)", |
michael@0 | 267 | "-moz-repeating-linear-gradient(20% bottom -300deg, red, blue)", |
michael@0 | 268 | "-moz-repeating-linear-gradient(center 20% 1.95929rad, red, blue)", |
michael@0 | 269 | "-moz-repeating-linear-gradient(left 35px 30grad, red, blue)", |
michael@0 | 270 | "-moz-repeating-linear-gradient(10% 10em 99999deg, red, blue)", |
michael@0 | 271 | "-moz-repeating-linear-gradient(44px top -33deg, red, blue)", |
michael@0 | 272 | |
michael@0 | 273 | "-moz-repeating-linear-gradient(-33deg, red, blue)", |
michael@0 | 274 | "-moz-repeating-linear-gradient(30grad left 35px, red, blue)", |
michael@0 | 275 | "-moz-repeating-linear-gradient(10deg 20px, red, blue)", |
michael@0 | 276 | "-moz-repeating-linear-gradient(.414rad bottom, red, blue)", |
michael@0 | 277 | |
michael@0 | 278 | "-moz-repeating-radial-gradient(red, blue)", |
michael@0 | 279 | "-moz-repeating-radial-gradient(red, yellow, blue)", |
michael@0 | 280 | "-moz-repeating-radial-gradient(red 1px, yellow 20%, blue 24em, green)", |
michael@0 | 281 | "-moz-repeating-radial-gradient(red, yellow, green, blue 50%)", |
michael@0 | 282 | "-moz-repeating-radial-gradient(red -50%, yellow -25%, green, blue)", |
michael@0 | 283 | "-moz-repeating-radial-gradient(red -99px, yellow, green, blue 120%)", |
michael@0 | 284 | "-moz-repeating-radial-gradient(#ffff00, #ef3, rgba(10, 20, 30, 0.4))", |
michael@0 | 285 | "-moz-repeating-radial-gradient(rgba(10, 20, 30, 0.4), #ffff00, #ef3)", |
michael@0 | 286 | |
michael@0 | 287 | "repeating-radial-gradient(at top left, red, blue)", |
michael@0 | 288 | "repeating-radial-gradient(at 0 0, red, blue)", |
michael@0 | 289 | "repeating-radial-gradient(at 20% bottom, red, blue)", |
michael@0 | 290 | "repeating-radial-gradient(at center 20%, red, blue)", |
michael@0 | 291 | "repeating-radial-gradient(at left 35px, red, blue)", |
michael@0 | 292 | "repeating-radial-gradient(at 10% 10em, red, blue)", |
michael@0 | 293 | "repeating-radial-gradient(at 44px top, red, blue)", |
michael@0 | 294 | |
michael@0 | 295 | "-moz-repeating-radial-gradient(farthest-corner, red, blue)", |
michael@0 | 296 | "-moz-repeating-radial-gradient(circle, red, blue)", |
michael@0 | 297 | "-moz-repeating-radial-gradient(ellipse closest-corner, red, blue)", |
michael@0 | 298 | |
michael@0 | 299 | "repeating-radial-gradient(farthest-corner at top left, red, blue)", |
michael@0 | 300 | "repeating-radial-gradient(closest-corner ellipse at 45px, red, blue)", |
michael@0 | 301 | "repeating-radial-gradient(farthest-side circle at 45px, red, blue)", |
michael@0 | 302 | "repeating-radial-gradient(ellipse closest-side at 50%, red, blue)", |
michael@0 | 303 | "repeating-radial-gradient(circle farthest-corner at 4em, red, blue)", |
michael@0 | 304 | |
michael@0 | 305 | "repeating-radial-gradient(30% 40% at top left, red, blue)", |
michael@0 | 306 | "repeating-radial-gradient(50px 60px at 15% 20%, red, blue)", |
michael@0 | 307 | "repeating-radial-gradient(7em 8em at 45px, red, blue)", |
michael@0 | 308 | |
michael@0 | 309 | "-moz-image-rect(url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==), 2, 10, 10, 2)", |
michael@0 | 310 | "-moz-image-rect(url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==), 10%, 50%, 30%, 0%)", |
michael@0 | 311 | "-moz-image-rect(url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==), 10, 50%, 30%, 0)", |
michael@0 | 312 | |
michael@0 | 313 | "-moz-radial-gradient(calc(25%) top, red, blue)", |
michael@0 | 314 | "-moz-radial-gradient(left calc(25%), red, blue)", |
michael@0 | 315 | "-moz-radial-gradient(calc(25px) top, red, blue)", |
michael@0 | 316 | "-moz-radial-gradient(left calc(25px), red, blue)", |
michael@0 | 317 | "-moz-radial-gradient(calc(-25%) top, red, blue)", |
michael@0 | 318 | "-moz-radial-gradient(left calc(-25%), red, blue)", |
michael@0 | 319 | "-moz-radial-gradient(calc(-25px) top, red, blue)", |
michael@0 | 320 | "-moz-radial-gradient(left calc(-25px), red, blue)", |
michael@0 | 321 | "-moz-radial-gradient(calc(100px + -25%) top, red, blue)", |
michael@0 | 322 | "-moz-radial-gradient(left calc(100px + -25%), red, blue)", |
michael@0 | 323 | "-moz-radial-gradient(calc(100px + -25px) top, red, blue)", |
michael@0 | 324 | "-moz-radial-gradient(left calc(100px + -25px), red, blue)" |
michael@0 | 325 | ]; |
michael@0 | 326 | var invalidGradientAndElementValues = [ |
michael@0 | 327 | "-moz-element(#a:1)", |
michael@0 | 328 | "-moz-element(a#a)", |
michael@0 | 329 | "-moz-element(#a a)", |
michael@0 | 330 | "-moz-element(#a+a)", |
michael@0 | 331 | "-moz-element(#a())", |
michael@0 | 332 | /* no quirks mode colors */ |
michael@0 | 333 | "linear-gradient(red, ff00ff)", |
michael@0 | 334 | /* no quirks mode colors */ |
michael@0 | 335 | "-moz-radial-gradient(10% bottom, ffffff, black) scroll no-repeat", |
michael@0 | 336 | /* no quirks mode lengths */ |
michael@0 | 337 | "-moz-linear-gradient(10 10px -45deg, red, blue) repeat", |
michael@0 | 338 | "-moz-linear-gradient(10px 10 -45deg, red, blue) repeat", |
michael@0 | 339 | "linear-gradient(red -99, yellow, green, blue 120%)", |
michael@0 | 340 | /* Old syntax */ |
michael@0 | 341 | "-moz-linear-gradient(10px 10px, 20px, 30px 30px, 40px, from(blue), to(red))", |
michael@0 | 342 | "-moz-radial-gradient(20px 20px, 10px 10px, from(green), to(#ff00ff))", |
michael@0 | 343 | "-moz-radial-gradient(10px 10px, 20%, 40px 40px, 10px, from(green), to(#ff00ff))", |
michael@0 | 344 | "-moz-linear-gradient(10px, 20px, 30px, 40px, color-stop(0.5, #00ccff))", |
michael@0 | 345 | "-moz-linear-gradient(20px 20px, from(blue), to(red))", |
michael@0 | 346 | "-moz-linear-gradient(40px 40px, 10px 10px, from(blue) to(red) color-stop(10%, fuchsia))", |
michael@0 | 347 | "-moz-linear-gradient(20px 20px 30px, 10px 10px, from(red), to(#ff0000))", |
michael@0 | 348 | "-moz-radial-gradient(left top, center, 20px 20px, 10px, from(blue), to(red))", |
michael@0 | 349 | "-moz-linear-gradient(left left, top top, from(blue))", |
michael@0 | 350 | "-moz-linear-gradient(inherit, 10px 10px, from(blue))", |
michael@0 | 351 | /* New syntax */ |
michael@0 | 352 | "-moz-linear-gradient(10px 10px, 20px, 30px 30px, 40px, blue 0, red 100%)", |
michael@0 | 353 | "-moz-radial-gradient(20px 20px, 10px 10px, from(green), to(#ff00ff))", |
michael@0 | 354 | "-moz-radial-gradient(10px 10px, 20%, 40px 40px, 10px, from(green), to(#ff00ff))", |
michael@0 | 355 | "-moz-linear-gradient(10px, 20px, 30px, 40px, #00ccff 50%)", |
michael@0 | 356 | "-moz-linear-gradient(40px 40px, 10px 10px, blue 0 fuchsia 10% red 100%)", |
michael@0 | 357 | "-moz-linear-gradient(20px 20px 30px, 10px 10px, red 0, #ff0000 100%)", |
michael@0 | 358 | "-moz-radial-gradient(left top, center, 20px 20px, 10px, from(blue), to(red))", |
michael@0 | 359 | "-moz-linear-gradient(left left, top top, blue 0)", |
michael@0 | 360 | "-moz-linear-gradient(inherit, 10px 10px, blue 0)", |
michael@0 | 361 | "-moz-linear-gradient(left left blue red)", |
michael@0 | 362 | "-moz-linear-gradient(left left blue, red)", |
michael@0 | 363 | "-moz-linear-gradient()", |
michael@0 | 364 | "-moz-linear-gradient(cover, red, blue)", |
michael@0 | 365 | "-moz-linear-gradient(auto, red, blue)", |
michael@0 | 366 | "-moz-linear-gradient(22 top, red, blue)", |
michael@0 | 367 | "-moz-linear-gradient(10% red blue)", |
michael@0 | 368 | "-moz-linear-gradient(10%, red blue)", |
michael@0 | 369 | "-moz-linear-gradient(10%,, red, blue)", |
michael@0 | 370 | "-moz-linear-gradient(45px, center, red, blue)", |
michael@0 | 371 | "-moz-linear-gradient(45px, center red, blue)", |
michael@0 | 372 | "-moz-radial-gradient(contain, ellipse, red, blue)", |
michael@0 | 373 | "-moz-radial-gradient(10deg contain, red, blue)", |
michael@0 | 374 | "-moz-radial-gradient(10deg, contain,, red, blue)", |
michael@0 | 375 | "-moz-radial-gradient(contain contain, red, blue)", |
michael@0 | 376 | "-moz-radial-gradient(ellipse circle, red, blue)", |
michael@0 | 377 | "-moz-radial-gradient(to top left, red, blue)", |
michael@0 | 378 | "-moz-radial-gradient(center, 10%, red, blue)", |
michael@0 | 379 | "-moz-radial-gradient(5rad, 20px, red, blue)", |
michael@0 | 380 | "-moz-radial-gradient(40%, -100px -10%, red, blue)", |
michael@0 | 381 | |
michael@0 | 382 | "-moz-radial-gradient(at top left to cover, red, blue)", |
michael@0 | 383 | "-moz-radial-gradient(at 15% 20% circle, red, blue)", |
michael@0 | 384 | |
michael@0 | 385 | "-moz-radial-gradient(to cover, red, blue)", |
michael@0 | 386 | "-moz-radial-gradient(to contain, red, blue)", |
michael@0 | 387 | "-moz-radial-gradient(to closest-side circle, red, blue)", |
michael@0 | 388 | "-moz-radial-gradient(to farthest-corner ellipse, red, blue)", |
michael@0 | 389 | |
michael@0 | 390 | "-moz-radial-gradient(ellipse at 45px closest-corner, red, blue)", |
michael@0 | 391 | "-moz-radial-gradient(circle at 45px farthest-side, red, blue)", |
michael@0 | 392 | "-moz-radial-gradient(ellipse 45px, closest-side, red, blue)", |
michael@0 | 393 | "-moz-radial-gradient(circle 45px, farthest-corner, red, blue)", |
michael@0 | 394 | "-moz-radial-gradient(ellipse, ellipse closest-side, red, blue)", |
michael@0 | 395 | "-moz-radial-gradient(circle, circle farthest-corner, red, blue)", |
michael@0 | 396 | |
michael@0 | 397 | "-moz-radial-gradient(99deg to farthest-corner, red, blue)", |
michael@0 | 398 | "-moz-radial-gradient(-1.2345rad circle, red, blue)", |
michael@0 | 399 | "-moz-radial-gradient(ellipse 399grad to closest-corner, red, blue)", |
michael@0 | 400 | "-moz-radial-gradient(circle 399grad to farthest-side, red, blue)", |
michael@0 | 401 | |
michael@0 | 402 | "-moz-radial-gradient(at top left 99deg, to farthest-corner, red, blue)", |
michael@0 | 403 | "-moz-radial-gradient(circle at 15% 20% -1.2345rad, red, blue)", |
michael@0 | 404 | "-moz-radial-gradient(to top left at 30% 40%, red, blue)", |
michael@0 | 405 | "-moz-radial-gradient(ellipse at 45px 399grad, to closest-corner, red, blue)", |
michael@0 | 406 | "-moz-radial-gradient(at 45px 399grad to farthest-side circle, red, blue)", |
michael@0 | 407 | |
michael@0 | 408 | "-moz-radial-gradient(to 50%, red, blue)", |
michael@0 | 409 | "-moz-radial-gradient(circle to 50%, red, blue)", |
michael@0 | 410 | "-moz-radial-gradient(circle to 43px 43px, red, blue)", |
michael@0 | 411 | "-moz-radial-gradient(circle to 50% 50%, red, blue)", |
michael@0 | 412 | "-moz-radial-gradient(circle to 43px 50%, red, blue)", |
michael@0 | 413 | "-moz-radial-gradient(circle to 50% 43px, red, blue)", |
michael@0 | 414 | "-moz-radial-gradient(ellipse to 43px, red, blue)", |
michael@0 | 415 | "-moz-radial-gradient(ellipse to 50%, red, blue)", |
michael@0 | 416 | |
michael@0 | 417 | "-moz-linear-gradient(to 0 0, red, blue)", |
michael@0 | 418 | "-moz-linear-gradient(to 20% bottom, red, blue)", |
michael@0 | 419 | "-moz-linear-gradient(to center 20%, red, blue)", |
michael@0 | 420 | "-moz-linear-gradient(to left 35px, red, blue)", |
michael@0 | 421 | "-moz-linear-gradient(to 10% 10em, red, blue)", |
michael@0 | 422 | "-moz-linear-gradient(to 44px top, red, blue)", |
michael@0 | 423 | "-moz-linear-gradient(to top left 45deg, red, blue)", |
michael@0 | 424 | "-moz-linear-gradient(to 20% bottom -300deg, red, blue)", |
michael@0 | 425 | "-moz-linear-gradient(to center 20% 1.95929rad, red, blue)", |
michael@0 | 426 | "-moz-linear-gradient(to left 35px 30grad, red, blue)", |
michael@0 | 427 | "-moz-linear-gradient(to 10% 10em 99999deg, red, blue)", |
michael@0 | 428 | "-moz-linear-gradient(to 44px top -33deg, red, blue)", |
michael@0 | 429 | "-moz-linear-gradient(to -33deg, red, blue)", |
michael@0 | 430 | "-moz-linear-gradient(to 30grad left 35px, red, blue)", |
michael@0 | 431 | "-moz-linear-gradient(to 10deg 20px, red, blue)", |
michael@0 | 432 | "-moz-linear-gradient(to .414rad bottom, red, blue)", |
michael@0 | 433 | |
michael@0 | 434 | "-moz-linear-gradient(to top top, red, blue)", |
michael@0 | 435 | "-moz-linear-gradient(to bottom bottom, red, blue)", |
michael@0 | 436 | "-moz-linear-gradient(to left left, red, blue)", |
michael@0 | 437 | "-moz-linear-gradient(to right right, red, blue)", |
michael@0 | 438 | |
michael@0 | 439 | "-moz-repeating-linear-gradient(10px 10px, 20px, 30px 30px, 40px, blue 0, red 100%)", |
michael@0 | 440 | "-moz-repeating-radial-gradient(20px 20px, 10px 10px, from(green), to(#ff00ff))", |
michael@0 | 441 | "-moz-repeating-radial-gradient(10px 10px, 20%, 40px 40px, 10px, from(green), to(#ff00ff))", |
michael@0 | 442 | "-moz-repeating-linear-gradient(10px, 20px, 30px, 40px, #00ccff 50%)", |
michael@0 | 443 | "-moz-repeating-linear-gradient(40px 40px, 10px 10px, blue 0 fuchsia 10% red 100%)", |
michael@0 | 444 | "-moz-repeating-linear-gradient(20px 20px 30px, 10px 10px, red 0, #ff0000 100%)", |
michael@0 | 445 | "-moz-repeating-radial-gradient(left top, center, 20px 20px, 10px, from(blue), to(red))", |
michael@0 | 446 | "-moz-repeating-linear-gradient(left left, top top, blue 0)", |
michael@0 | 447 | "-moz-repeating-linear-gradient(inherit, 10px 10px, blue 0)", |
michael@0 | 448 | "-moz-repeating-linear-gradient(left left blue red)", |
michael@0 | 449 | "-moz-repeating-linear-gradient()", |
michael@0 | 450 | |
michael@0 | 451 | "-moz-repeating-linear-gradient(to 0 0, red, blue)", |
michael@0 | 452 | "-moz-repeating-linear-gradient(to 20% bottom, red, blue)", |
michael@0 | 453 | "-moz-repeating-linear-gradient(to center 20%, red, blue)", |
michael@0 | 454 | "-moz-repeating-linear-gradient(to left 35px, red, blue)", |
michael@0 | 455 | "-moz-repeating-linear-gradient(to 10% 10em, red, blue)", |
michael@0 | 456 | "-moz-repeating-linear-gradient(to 44px top, red, blue)", |
michael@0 | 457 | "-moz-repeating-linear-gradient(to top left 45deg, red, blue)", |
michael@0 | 458 | "-moz-repeating-linear-gradient(to 20% bottom -300deg, red, blue)", |
michael@0 | 459 | "-moz-repeating-linear-gradient(to center 20% 1.95929rad, red, blue)", |
michael@0 | 460 | "-moz-repeating-linear-gradient(to left 35px 30grad, red, blue)", |
michael@0 | 461 | "-moz-repeating-linear-gradient(to 10% 10em 99999deg, red, blue)", |
michael@0 | 462 | "-moz-repeating-linear-gradient(to 44px top -33deg, red, blue)", |
michael@0 | 463 | "-moz-repeating-linear-gradient(to -33deg, red, blue)", |
michael@0 | 464 | "-moz-repeating-linear-gradient(to 30grad left 35px, red, blue)", |
michael@0 | 465 | "-moz-repeating-linear-gradient(to 10deg 20px, red, blue)", |
michael@0 | 466 | "-moz-repeating-linear-gradient(to .414rad bottom, red, blue)", |
michael@0 | 467 | |
michael@0 | 468 | "-moz-repeating-linear-gradient(to top top, red, blue)", |
michael@0 | 469 | "-moz-repeating-linear-gradient(to bottom bottom, red, blue)", |
michael@0 | 470 | "-moz-repeating-linear-gradient(to left left, red, blue)", |
michael@0 | 471 | "-moz-repeating-linear-gradient(to right right, red, blue)", |
michael@0 | 472 | |
michael@0 | 473 | "-moz-repeating-radial-gradient(to top left at 30% 40%, red, blue)", |
michael@0 | 474 | "-moz-repeating-radial-gradient(ellipse at 45px closest-corner, red, blue)", |
michael@0 | 475 | "-moz-repeating-radial-gradient(circle at 45px farthest-side, red, blue)", |
michael@0 | 476 | |
michael@0 | 477 | "radial-gradient(circle 175px 20px, black, white)", |
michael@0 | 478 | "radial-gradient(175px 20px circle, black, white)", |
michael@0 | 479 | "radial-gradient(ellipse 175px, black, white)", |
michael@0 | 480 | "radial-gradient(175px ellipse, black, white)", |
michael@0 | 481 | "radial-gradient(50%, red, blue)", |
michael@0 | 482 | "radial-gradient(circle 50%, red, blue)", |
michael@0 | 483 | "radial-gradient(50% circle, red, blue)", |
michael@0 | 484 | |
michael@0 | 485 | /* Valid only when prefixed */ |
michael@0 | 486 | "linear-gradient(top left, red, blue)", |
michael@0 | 487 | "linear-gradient(0 0, red, blue)", |
michael@0 | 488 | "linear-gradient(20% bottom, red, blue)", |
michael@0 | 489 | "linear-gradient(center 20%, red, blue)", |
michael@0 | 490 | "linear-gradient(left 35px, red, blue)", |
michael@0 | 491 | "linear-gradient(10% 10em, red, blue)", |
michael@0 | 492 | "linear-gradient(44px top, red, blue)", |
michael@0 | 493 | |
michael@0 | 494 | "linear-gradient(top left 45deg, red, blue)", |
michael@0 | 495 | "linear-gradient(20% bottom -300deg, red, blue)", |
michael@0 | 496 | "linear-gradient(center 20% 1.95929rad, red, blue)", |
michael@0 | 497 | "linear-gradient(left 35px 30grad, red, blue)", |
michael@0 | 498 | "linear-gradient(left 35px 0.1turn, red, blue)", |
michael@0 | 499 | "linear-gradient(10% 10em 99999deg, red, blue)", |
michael@0 | 500 | "linear-gradient(44px top -33deg, red, blue)", |
michael@0 | 501 | |
michael@0 | 502 | "linear-gradient(30grad left 35px, red, blue)", |
michael@0 | 503 | "linear-gradient(10deg 20px, red, blue)", |
michael@0 | 504 | "linear-gradient(1turn 20px, red, blue)", |
michael@0 | 505 | "linear-gradient(.414rad bottom, red, blue)", |
michael@0 | 506 | |
michael@0 | 507 | "radial-gradient(top left 45deg, red, blue)", |
michael@0 | 508 | "radial-gradient(20% bottom -300deg, red, blue)", |
michael@0 | 509 | "radial-gradient(center 20% 1.95929rad, red, blue)", |
michael@0 | 510 | "radial-gradient(left 35px 30grad, red, blue)", |
michael@0 | 511 | "radial-gradient(10% 10em 99999deg, red, blue)", |
michael@0 | 512 | "radial-gradient(44px top -33deg, red, blue)", |
michael@0 | 513 | |
michael@0 | 514 | "radial-gradient(-33deg, red, blue)", |
michael@0 | 515 | "radial-gradient(30grad left 35px, red, blue)", |
michael@0 | 516 | "radial-gradient(10deg 20px, red, blue)", |
michael@0 | 517 | "radial-gradient(.414rad bottom, red, blue)", |
michael@0 | 518 | |
michael@0 | 519 | "radial-gradient(cover, red, blue)", |
michael@0 | 520 | "radial-gradient(ellipse contain, red, blue)", |
michael@0 | 521 | "radial-gradient(cover circle, red, blue)", |
michael@0 | 522 | |
michael@0 | 523 | "radial-gradient(top left, cover, red, blue)", |
michael@0 | 524 | "radial-gradient(15% 20%, circle, red, blue)", |
michael@0 | 525 | "radial-gradient(45px, ellipse closest-corner, red, blue)", |
michael@0 | 526 | "radial-gradient(45px, farthest-side circle, red, blue)", |
michael@0 | 527 | |
michael@0 | 528 | "radial-gradient(99deg, cover, red, blue)", |
michael@0 | 529 | "radial-gradient(-1.2345rad, circle, red, blue)", |
michael@0 | 530 | "radial-gradient(399grad, ellipse closest-corner, red, blue)", |
michael@0 | 531 | "radial-gradient(399grad, farthest-side circle, red, blue)", |
michael@0 | 532 | |
michael@0 | 533 | "radial-gradient(top left 99deg, cover, red, blue)", |
michael@0 | 534 | "radial-gradient(15% 20% -1.2345rad, circle, red, blue)", |
michael@0 | 535 | "radial-gradient(45px 399grad, ellipse closest-corner, red, blue)", |
michael@0 | 536 | "radial-gradient(45px 399grad, farthest-side circle, red, blue)", |
michael@0 | 537 | |
michael@0 | 538 | /* Valid only when unprefixed */ |
michael@0 | 539 | "-moz-radial-gradient(at top left, red, blue)", |
michael@0 | 540 | "-moz-radial-gradient(at 20% bottom, red, blue)", |
michael@0 | 541 | "-moz-radial-gradient(at center 20%, red, blue)", |
michael@0 | 542 | "-moz-radial-gradient(at left 35px, red, blue)", |
michael@0 | 543 | "-moz-radial-gradient(at 10% 10em, red, blue)", |
michael@0 | 544 | "-moz-radial-gradient(at 44px top, red, blue)", |
michael@0 | 545 | "-moz-radial-gradient(at 0 0, red, blue)", |
michael@0 | 546 | |
michael@0 | 547 | "-moz-radial-gradient(circle 43px, red, blue)", |
michael@0 | 548 | "-moz-radial-gradient(ellipse 43px 43px, red, blue)", |
michael@0 | 549 | "-moz-radial-gradient(ellipse 50% 50%, red, blue)", |
michael@0 | 550 | "-moz-radial-gradient(ellipse 43px 50%, red, blue)", |
michael@0 | 551 | "-moz-radial-gradient(ellipse 50% 43px, red, blue)", |
michael@0 | 552 | |
michael@0 | 553 | "-moz-radial-gradient(farthest-corner at top left, red, blue)", |
michael@0 | 554 | "-moz-radial-gradient(ellipse closest-corner at 45px, red, blue)", |
michael@0 | 555 | "-moz-radial-gradient(circle farthest-side at 45px, red, blue)", |
michael@0 | 556 | "-moz-radial-gradient(closest-side ellipse at 50%, red, blue)", |
michael@0 | 557 | "-moz-radial-gradient(farthest-corner circle at 4em, red, blue)", |
michael@0 | 558 | |
michael@0 | 559 | "-moz-radial-gradient(30% 40% at top left, red, blue)", |
michael@0 | 560 | "-moz-radial-gradient(50px 60px at 15% 20%, red, blue)", |
michael@0 | 561 | "-moz-radial-gradient(7em 8em at 45px, red, blue)" |
michael@0 | 562 | ]; |
michael@0 | 563 | var unbalancedGradientAndElementValues = [ |
michael@0 | 564 | "-moz-element(#a()", |
michael@0 | 565 | ]; |
michael@0 | 566 | |
michael@0 | 567 | var gCSSProperties = { |
michael@0 | 568 | "animation": { |
michael@0 | 569 | domProp: "animation", |
michael@0 | 570 | inherited: false, |
michael@0 | 571 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 572 | subproperties: [ "animation-name", "animation-duration", "animation-timing-function", "animation-delay", "animation-direction", "animation-fill-mode", "animation-iteration-count" ], |
michael@0 | 573 | initial_values: [ "none none 0s 0s ease normal 1.0", "none", "0s", "ease", "normal", "1.0" ], |
michael@0 | 574 | other_values: [ "bounce 1s linear 2s", "bounce 1s 2s linear", "bounce linear 1s 2s", "linear bounce 1s 2s", "linear 1s bounce 2s", "linear 1s 2s bounce", "1s bounce linear 2s", "1s bounce 2s linear", "1s 2s bounce linear", "1s linear bounce 2s", "1s linear 2s bounce", "1s 2s linear bounce", "bounce linear 1s", "bounce 1s linear", "linear bounce 1s", "linear 1s bounce", "1s bounce linear", "1s linear bounce", "1s 2s bounce", "1s bounce 2s", "bounce 1s 2s", "1s 2s linear", "1s linear 2s", "linear 1s 2s", "bounce 1s", "1s bounce", "linear 1s", "1s linear", "1s 2s", "2s 1s", "bounce", "linear", "1s", "height", "2s", "ease-in-out", "2s ease-in", "opacity linear", "ease-out 2s", "2s color, 1s bounce, 500ms height linear, 1s opacity 4s cubic-bezier(0.0, 0.1, 1.0, 1.0)", "1s \\32bounce linear 2s", "1s -bounce linear 2s", "1s -\\32bounce linear 2s", "1s \\32 0bounce linear 2s", "1s -\\32 0bounce linear 2s", "1s \\2bounce linear 2s", "1s -\\2bounce linear 2s", "2s, 1s bounce", "1s bounce, 2s", "2s all, 1s bounce", "1s bounce, 2s all", "1s bounce, 2s none", "2s none, 1s bounce", "2s bounce, 1s all", "2s all, 1s bounce" ], |
michael@0 | 575 | invalid_values: [ "2s inherit", "inherit 2s", "2s bounce, 1s inherit", "2s inherit, 1s bounce", "2s initial", "2s all,, 1s bounce", "2s all, , 1s bounce" ] |
michael@0 | 576 | }, |
michael@0 | 577 | "animation-delay": { |
michael@0 | 578 | domProp: "animationDelay", |
michael@0 | 579 | inherited: false, |
michael@0 | 580 | type: CSS_TYPE_LONGHAND, |
michael@0 | 581 | initial_values: [ "0s", "0ms" ], |
michael@0 | 582 | other_values: [ "1s", "250ms", "-100ms", "-1s", "1s, 250ms, 2.3s"], |
michael@0 | 583 | invalid_values: [ "0", "0px" ] |
michael@0 | 584 | }, |
michael@0 | 585 | "animation-direction": { |
michael@0 | 586 | domProp: "animationDirection", |
michael@0 | 587 | inherited: false, |
michael@0 | 588 | type: CSS_TYPE_LONGHAND, |
michael@0 | 589 | initial_values: [ "normal" ], |
michael@0 | 590 | other_values: [ "alternate", "normal, alternate", "alternate, normal", "normal, normal", "normal, normal, normal", "reverse", "alternate-reverse", "normal, reverse, alternate-reverse, alternate" ], |
michael@0 | 591 | invalid_values: [ "normal normal", "inherit, normal", "reverse-alternate" ] |
michael@0 | 592 | }, |
michael@0 | 593 | "animation-duration": { |
michael@0 | 594 | domProp: "animationDuration", |
michael@0 | 595 | inherited: false, |
michael@0 | 596 | type: CSS_TYPE_LONGHAND, |
michael@0 | 597 | initial_values: [ "0s", "0ms" ], |
michael@0 | 598 | other_values: [ "1s", "250ms", "1s, 250ms, 2.3s"], |
michael@0 | 599 | invalid_values: [ "0", "0px", "-1ms", "-2s" ] |
michael@0 | 600 | }, |
michael@0 | 601 | "animation-fill-mode": { |
michael@0 | 602 | domProp: "animationFillMode", |
michael@0 | 603 | inherited: false, |
michael@0 | 604 | type: CSS_TYPE_LONGHAND, |
michael@0 | 605 | initial_values: [ "none" ], |
michael@0 | 606 | other_values: [ "forwards", "backwards", "both", "none, none", "forwards, backwards", "forwards, none", "none, both" ], |
michael@0 | 607 | invalid_values: [ "all"] |
michael@0 | 608 | }, |
michael@0 | 609 | "animation-iteration-count": { |
michael@0 | 610 | domProp: "animationIterationCount", |
michael@0 | 611 | inherited: false, |
michael@0 | 612 | type: CSS_TYPE_LONGHAND, |
michael@0 | 613 | initial_values: [ "1" ], |
michael@0 | 614 | other_values: [ "infinite", "0", "0.5", "7.75", "-0.0", "1, 2, 3", "infinite, 2", "1, infinite" ], |
michael@0 | 615 | // negatives forbidden per |
michael@0 | 616 | // http://lists.w3.org/Archives/Public/www-style/2011Mar/0355.html |
michael@0 | 617 | invalid_values: [ "none", "-1", "-0.5", "-1, infinite", "infinite, -3" ] |
michael@0 | 618 | }, |
michael@0 | 619 | "animation-name": { |
michael@0 | 620 | domProp: "animationName", |
michael@0 | 621 | inherited: false, |
michael@0 | 622 | type: CSS_TYPE_LONGHAND, |
michael@0 | 623 | initial_values: [ "none" ], |
michael@0 | 624 | other_values: [ "all", "ball", "mall", "color", "bounce, bubble, opacity", "foobar", "auto", "\\32bounce", "-bounce", "-\\32bounce", "\\32 0bounce", "-\\32 0bounce", "\\2bounce", "-\\2bounce" ], |
michael@0 | 625 | invalid_values: [ "bounce, initial", "initial, bounce", "bounce, inherit", "inherit, bounce" ] |
michael@0 | 626 | }, |
michael@0 | 627 | "animation-play-state": { |
michael@0 | 628 | domProp: "animationPlayState", |
michael@0 | 629 | inherited: false, |
michael@0 | 630 | type: CSS_TYPE_LONGHAND, |
michael@0 | 631 | initial_values: [ "running" ], |
michael@0 | 632 | other_values: [ "paused", "running, running", "paused, running", "paused, paused", "running, paused", "paused, running, running, running, paused, running" ], |
michael@0 | 633 | invalid_values: [ "0" ] |
michael@0 | 634 | }, |
michael@0 | 635 | "animation-timing-function": { |
michael@0 | 636 | domProp: "animationTimingFunction", |
michael@0 | 637 | inherited: false, |
michael@0 | 638 | type: CSS_TYPE_LONGHAND, |
michael@0 | 639 | initial_values: [ "ease", "cubic-bezier(0.25, 0.1, 0.25, 1.0)" ], |
michael@0 | 640 | other_values: [ "linear", "ease-in", "ease-out", "ease-in-out", "linear, ease-in, cubic-bezier(0.1, 0.2, 0.8, 0.9)", "cubic-bezier(0.5, 0.5, 0.5, 0.5)", "cubic-bezier(0.25, 1.5, 0.75, -0.5)", "step-start", "step-end", "steps(1)", "steps(2, start)", "steps(386)", "steps(3, end)" ], |
michael@0 | 641 | invalid_values: [ "none", "auto", "cubic-bezier(0.25, 0.1, 0.25)", "cubic-bezier(0.25, 0.1, 0.25, 0.25, 1.0)", "cubic-bezier(-0.5, 0.5, 0.5, 0.5)", "cubic-bezier(1.5, 0.5, 0.5, 0.5)", "cubic-bezier(0.5, 0.5, -0.5, 0.5)", "cubic-bezier(0.5, 0.5, 1.5, 0.5)", "steps(2, step-end)", "steps(0)", "steps(-2)", "steps(0, step-end, 1)" ] |
michael@0 | 642 | }, |
michael@0 | 643 | "-moz-appearance": { |
michael@0 | 644 | domProp: "MozAppearance", |
michael@0 | 645 | inherited: false, |
michael@0 | 646 | type: CSS_TYPE_LONGHAND, |
michael@0 | 647 | initial_values: [ "none" ], |
michael@0 | 648 | other_values: [ "radio", "menulist" ], |
michael@0 | 649 | invalid_values: [] |
michael@0 | 650 | }, |
michael@0 | 651 | "-moz-background-inline-policy": { |
michael@0 | 652 | domProp: "MozBackgroundInlinePolicy", |
michael@0 | 653 | inherited: false, |
michael@0 | 654 | type: CSS_TYPE_LONGHAND, |
michael@0 | 655 | initial_values: [ "continuous" ], |
michael@0 | 656 | other_values: ["bounding-box", "each-box" ], |
michael@0 | 657 | invalid_values: [] |
michael@0 | 658 | }, |
michael@0 | 659 | "-moz-binding": { |
michael@0 | 660 | domProp: "MozBinding", |
michael@0 | 661 | inherited: false, |
michael@0 | 662 | type: CSS_TYPE_LONGHAND, |
michael@0 | 663 | initial_values: [ "none" ], |
michael@0 | 664 | other_values: [ "url(foo.xml)" ], |
michael@0 | 665 | invalid_values: [] |
michael@0 | 666 | }, |
michael@0 | 667 | "-moz-border-bottom-colors": { |
michael@0 | 668 | domProp: "MozBorderBottomColors", |
michael@0 | 669 | inherited: false, |
michael@0 | 670 | type: CSS_TYPE_LONGHAND, |
michael@0 | 671 | initial_values: [ "none" ], |
michael@0 | 672 | other_values: [ "red green", "red #fc3", "#ff00cc", "currentColor", "blue currentColor orange currentColor" ], |
michael@0 | 673 | invalid_values: [ "red none", "red inherit", "red, green", "none red", "inherit red", "ff00cc" ] |
michael@0 | 674 | }, |
michael@0 | 675 | "-moz-border-end": { |
michael@0 | 676 | domProp: "MozBorderEnd", |
michael@0 | 677 | inherited: false, |
michael@0 | 678 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 679 | subproperties: [ "-moz-border-end-color", "-moz-border-end-style", "-moz-border-end-width" ], |
michael@0 | 680 | initial_values: [ "none", "medium", "currentColor", "thin", "none medium currentcolor" ], |
michael@0 | 681 | other_values: [ "solid", "green", "medium solid", "green solid", "10px solid", "thick solid", "5px green none" ], |
michael@0 | 682 | invalid_values: [ "5%", "5", "5 green none" ] |
michael@0 | 683 | }, |
michael@0 | 684 | "-moz-border-end-color": { |
michael@0 | 685 | domProp: "MozBorderEndColor", |
michael@0 | 686 | inherited: false, |
michael@0 | 687 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 688 | get_computed: logical_box_prop_get_computed, |
michael@0 | 689 | initial_values: [ "currentColor" ], |
michael@0 | 690 | other_values: [ "green", "rgba(255,128,0,0.5)", "transparent" ], |
michael@0 | 691 | invalid_values: [ "#0", "#00", "#0000", "#00000", "#0000000", "#00000000", "#000000000", "000000" ] |
michael@0 | 692 | }, |
michael@0 | 693 | "-moz-border-end-style": { |
michael@0 | 694 | domProp: "MozBorderEndStyle", |
michael@0 | 695 | inherited: false, |
michael@0 | 696 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 697 | get_computed: logical_box_prop_get_computed, |
michael@0 | 698 | /* XXX hidden is sometimes the same as initial */ |
michael@0 | 699 | initial_values: [ "none" ], |
michael@0 | 700 | other_values: [ "solid", "dashed", "dotted", "double", "outset", "inset", "groove", "ridge" ], |
michael@0 | 701 | invalid_values: [] |
michael@0 | 702 | }, |
michael@0 | 703 | "-moz-border-end-width": { |
michael@0 | 704 | domProp: "MozBorderEndWidth", |
michael@0 | 705 | inherited: false, |
michael@0 | 706 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 707 | get_computed: logical_box_prop_get_computed, |
michael@0 | 708 | prerequisites: { "-moz-border-end-style": "solid" }, |
michael@0 | 709 | initial_values: [ "medium", "3px", "calc(4px - 1px)" ], |
michael@0 | 710 | other_values: [ "thin", "thick", "1px", "2em", |
michael@0 | 711 | "calc(2px)", |
michael@0 | 712 | "calc(-2px)", |
michael@0 | 713 | "calc(0em)", |
michael@0 | 714 | "calc(0px)", |
michael@0 | 715 | "calc(5em)", |
michael@0 | 716 | "calc(3*25px)", |
michael@0 | 717 | "calc(25px*3)", |
michael@0 | 718 | "calc(3*25px + 5em)", |
michael@0 | 719 | ], |
michael@0 | 720 | invalid_values: [ "5%", "5" ] |
michael@0 | 721 | }, |
michael@0 | 722 | "border-image": { |
michael@0 | 723 | domProp: "borderImage", |
michael@0 | 724 | inherited: false, |
michael@0 | 725 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 726 | subproperties: [ "border-image-source", "border-image-slice", "border-image-width", "border-image-outset", "border-image-repeat" ], |
michael@0 | 727 | initial_values: [ "none" ], |
michael@0 | 728 | other_values: [ "url('border.png') 27 27 27 27", |
michael@0 | 729 | "url('border.png') 27", |
michael@0 | 730 | "stretch url('border.png')", |
michael@0 | 731 | "url('border.png') 27 fill", |
michael@0 | 732 | "url('border.png') 27 27 27 27 repeat", |
michael@0 | 733 | "repeat url('border.png') 27 27 27 27", |
michael@0 | 734 | "url('border.png') repeat 27 27 27 27", |
michael@0 | 735 | "url('border.png') fill 27 27 27 27 repeat", |
michael@0 | 736 | "url('border.png') 27 27 27 27 / 1em", |
michael@0 | 737 | "27 27 27 27 / 1em url('border.png') ", |
michael@0 | 738 | "url('border.png') 27 27 27 27 / 10 10 10 / 10 10 repeat", |
michael@0 | 739 | "repeat 27 27 27 27 / 10 10 10 / 10 10 url('border.png')", |
michael@0 | 740 | "url('border.png') 27 27 27 27 / / 10 10 1em", |
michael@0 | 741 | "fill 27 27 27 27 / / 10 10 1em url('border.png')", |
michael@0 | 742 | "url('border.png') 27 27 27 27 / 1em 1em 1em 1em repeat", |
michael@0 | 743 | "url('border.png') 27 27 27 27 / 1em 1em 1em 1em stretch round" ], |
michael@0 | 744 | invalid_values: [ "url('border.png') 27 27 27 27 27", |
michael@0 | 745 | "url('border.png') 27 27 27 27 / 1em 1em 1em 1em 1em", |
michael@0 | 746 | "url('border.png') 27 27 27 27 /", |
michael@0 | 747 | "url('border.png') fill", |
michael@0 | 748 | "url('border.png') fill repeat", |
michael@0 | 749 | "fill repeat", |
michael@0 | 750 | "url('border.png') fill / 1em", |
michael@0 | 751 | "url('border.png') / repeat", |
michael@0 | 752 | "url('border.png') 1 /", |
michael@0 | 753 | "url('border.png') 1 / /", |
michael@0 | 754 | "1 / url('border.png')", |
michael@0 | 755 | "url('border.png') / 1", |
michael@0 | 756 | "url('border.png') / / 1"] |
michael@0 | 757 | }, |
michael@0 | 758 | "border-image-source": { |
michael@0 | 759 | domProp: "borderImageSource", |
michael@0 | 760 | inherited: false, |
michael@0 | 761 | type: CSS_TYPE_LONGHAND, |
michael@0 | 762 | initial_values: [ "none" ], |
michael@0 | 763 | other_values: [ |
michael@0 | 764 | "url('border.png')" |
michael@0 | 765 | ].concat(validGradientAndElementValues), |
michael@0 | 766 | invalid_values: [ |
michael@0 | 767 | "url('border.png') url('border.png')", |
michael@0 | 768 | ].concat(invalidGradientAndElementValues), |
michael@0 | 769 | unbalanced_values: [ |
michael@0 | 770 | ].concat(unbalancedGradientAndElementValues) |
michael@0 | 771 | }, |
michael@0 | 772 | "border-image-slice": { |
michael@0 | 773 | domProp: "borderImageSlice", |
michael@0 | 774 | inherited: false, |
michael@0 | 775 | type: CSS_TYPE_LONGHAND, |
michael@0 | 776 | initial_values: [ "100%", "100% 100% 100% 100%" ], |
michael@0 | 777 | other_values: [ "0%", "10", "10 100% 0 2", "0 0 0 0", "fill 10 10", "10 10 fill" ], |
michael@0 | 778 | invalid_values: [ "-10%", "-10", "10 10 10 10 10", "10 10 10 10 -10", "10px", "-10px", "fill", "fill fill 10px", "10px fill fill" ] |
michael@0 | 779 | }, |
michael@0 | 780 | "border-image-width": { |
michael@0 | 781 | domProp: "borderImageWidth", |
michael@0 | 782 | inherited: false, |
michael@0 | 783 | type: CSS_TYPE_LONGHAND, |
michael@0 | 784 | initial_values: [ "1", "1 1 1 1" ], |
michael@0 | 785 | other_values: [ "0", "0%", "0px", "auto auto auto auto", "10 10% auto 15px", "10px 10px 10px 10px", "10", "10 10", "10 10 10" ], |
michael@0 | 786 | invalid_values: [ "-10", "-10px", "-10%", "10 10 10 10 10", "10 10 10 10 auto", "auto auto auto auto auto" ] |
michael@0 | 787 | }, |
michael@0 | 788 | "border-image-outset": { |
michael@0 | 789 | domProp: "borderImageOutset", |
michael@0 | 790 | inherited: false, |
michael@0 | 791 | type: CSS_TYPE_LONGHAND, |
michael@0 | 792 | initial_values: [ "0", "0 0 0 0" ], |
michael@0 | 793 | other_values: [ "10px", "10", "10 10", "10 10 10", "10 10 10 10", "10px 10 10 10px" ], |
michael@0 | 794 | invalid_values: [ "-10", "-10px", "-10%", "10%", "10 10 10 10 10" ] |
michael@0 | 795 | }, |
michael@0 | 796 | "border-image-repeat": { |
michael@0 | 797 | domProp: "borderImageRepeat", |
michael@0 | 798 | inherited: false, |
michael@0 | 799 | type: CSS_TYPE_LONGHAND, |
michael@0 | 800 | initial_values: [ "stretch", "stretch stretch" ], |
michael@0 | 801 | other_values: [ "round", "repeat", "stretch round", "repeat round", "stretch repeat", "round round", "repeat repeat" ], |
michael@0 | 802 | invalid_values: [ "none", "stretch stretch stretch", "0", "10", "0%", "0px" ] |
michael@0 | 803 | }, |
michael@0 | 804 | "-moz-border-left-colors": { |
michael@0 | 805 | domProp: "MozBorderLeftColors", |
michael@0 | 806 | inherited: false, |
michael@0 | 807 | type: CSS_TYPE_LONGHAND, |
michael@0 | 808 | initial_values: [ "none" ], |
michael@0 | 809 | other_values: [ "red green", "red #fc3", "#ff00cc", "currentColor", "blue currentColor orange currentColor" ], |
michael@0 | 810 | invalid_values: [ "red none", "red inherit", "red, green", "none red", "inherit red", "ff00cc" ] |
michael@0 | 811 | }, |
michael@0 | 812 | "border-radius": { |
michael@0 | 813 | domProp: "borderRadius", |
michael@0 | 814 | inherited: false, |
michael@0 | 815 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 816 | prerequisites: { "width": "200px", "height": "100px", "display": "inline-block"}, |
michael@0 | 817 | subproperties: [ "border-bottom-left-radius", "border-bottom-right-radius", "border-top-left-radius", "border-top-right-radius" ], |
michael@0 | 818 | initial_values: [ "0", "0px", "0%", "0px 0 0 0px", "calc(-2px)", "calc(-1%)", "calc(0px) calc(0pt) calc(0%) calc(0em)" ], |
michael@0 | 819 | other_values: [ "3%", "1px", "2em", "3em 2px", "2pt 3% 4em", "2px 2px 2px 2px", // circular |
michael@0 | 820 | "3% / 2%", "1px / 4px", "2em / 1em", "3em 2px / 2px 3em", "2pt 3% 4em / 4pt 1% 5em", "2px 2px 2px 2px / 4px 4px 4px 4px", "1pt / 2pt 3pt", "4pt 5pt / 3pt", // elliptical |
michael@0 | 821 | "calc(2px)", |
michael@0 | 822 | "calc(50%)", |
michael@0 | 823 | "calc(3*25px)", |
michael@0 | 824 | "calc(3*25px) 5px", |
michael@0 | 825 | "5px calc(3*25px)", |
michael@0 | 826 | "calc(20%) calc(3*25px)", |
michael@0 | 827 | "calc(25px*3)", |
michael@0 | 828 | "calc(3*25px + 50%)", |
michael@0 | 829 | "2px 2px calc(2px + 1%) 2px", |
michael@0 | 830 | "1px 2px 2px 2px / 2px 2px calc(2px + 1%) 2px", |
michael@0 | 831 | ], |
michael@0 | 832 | invalid_values: [ "2px -2px", "inherit 2px", "inherit / 2px", "2px inherit", "2px / inherit", "2px 2px 2px 2px 2px", "1px / 2px 2px 2px 2px 2px", "2", "2 2", "2px 2px 2px 2px / 2px 2px 2 2px" ] |
michael@0 | 833 | }, |
michael@0 | 834 | "border-bottom-left-radius": { |
michael@0 | 835 | domProp: "borderBottomLeftRadius", |
michael@0 | 836 | inherited: false, |
michael@0 | 837 | type: CSS_TYPE_LONGHAND, |
michael@0 | 838 | prerequisites: { "width": "200px", "height": "100px", "display": "inline-block"}, |
michael@0 | 839 | initial_values: [ "0", "0px", "0%", "calc(-2px)", "calc(-1%)" ], |
michael@0 | 840 | other_values: [ "3%", "1px", "2em", // circular |
michael@0 | 841 | "3% 2%", "1px 4px", "2em 2pt", // elliptical |
michael@0 | 842 | "calc(2px)", |
michael@0 | 843 | "calc(50%)", |
michael@0 | 844 | "calc(3*25px)", |
michael@0 | 845 | "calc(3*25px) 5px", |
michael@0 | 846 | "5px calc(3*25px)", |
michael@0 | 847 | "calc(20%) calc(3*25px)", |
michael@0 | 848 | "calc(25px*3)", |
michael@0 | 849 | "calc(3*25px + 50%)", |
michael@0 | 850 | ], |
michael@0 | 851 | invalid_values: [ "-1px", "4px -2px", "inherit 2px", "2px inherit", "2", "2px 2", "2 2px" ] |
michael@0 | 852 | }, |
michael@0 | 853 | "border-bottom-right-radius": { |
michael@0 | 854 | domProp: "borderBottomRightRadius", |
michael@0 | 855 | inherited: false, |
michael@0 | 856 | type: CSS_TYPE_LONGHAND, |
michael@0 | 857 | prerequisites: { "width": "200px", "height": "100px", "display": "inline-block"}, |
michael@0 | 858 | initial_values: [ "0", "0px", "0%", "calc(-2px)", "calc(-1%)" ], |
michael@0 | 859 | other_values: [ "3%", "1px", "2em", // circular |
michael@0 | 860 | "3% 2%", "1px 4px", "2em 2pt", // elliptical |
michael@0 | 861 | "calc(2px)", |
michael@0 | 862 | "calc(50%)", |
michael@0 | 863 | "calc(3*25px)", |
michael@0 | 864 | "calc(3*25px) 5px", |
michael@0 | 865 | "5px calc(3*25px)", |
michael@0 | 866 | "calc(20%) calc(3*25px)", |
michael@0 | 867 | "calc(25px*3)", |
michael@0 | 868 | "calc(3*25px + 50%)", |
michael@0 | 869 | ], |
michael@0 | 870 | invalid_values: [ "-1px", "4px -2px", "inherit 2px", "2px inherit", "2", "2px 2", "2 2px" ] |
michael@0 | 871 | }, |
michael@0 | 872 | "border-top-left-radius": { |
michael@0 | 873 | domProp: "borderTopLeftRadius", |
michael@0 | 874 | inherited: false, |
michael@0 | 875 | type: CSS_TYPE_LONGHAND, |
michael@0 | 876 | prerequisites: { "width": "200px", "height": "100px", "display": "inline-block"}, |
michael@0 | 877 | initial_values: [ "0", "0px", "0%", "calc(-2px)", "calc(-1%)" ], |
michael@0 | 878 | other_values: [ "3%", "1px", "2em", // circular |
michael@0 | 879 | "3% 2%", "1px 4px", "2em 2pt", // elliptical |
michael@0 | 880 | "calc(2px)", |
michael@0 | 881 | "calc(50%)", |
michael@0 | 882 | "calc(3*25px)", |
michael@0 | 883 | "calc(3*25px) 5px", |
michael@0 | 884 | "5px calc(3*25px)", |
michael@0 | 885 | "calc(20%) calc(3*25px)", |
michael@0 | 886 | "calc(25px*3)", |
michael@0 | 887 | "calc(3*25px + 50%)", |
michael@0 | 888 | ], |
michael@0 | 889 | invalid_values: [ "-1px", "4px -2px", "inherit 2px", "2px inherit", "2", "2px 2", "2 2px" ] |
michael@0 | 890 | }, |
michael@0 | 891 | "border-top-right-radius": { |
michael@0 | 892 | domProp: "borderTopRightRadius", |
michael@0 | 893 | inherited: false, |
michael@0 | 894 | type: CSS_TYPE_LONGHAND, |
michael@0 | 895 | prerequisites: { "width": "200px", "height": "100px", "display": "inline-block"}, |
michael@0 | 896 | initial_values: [ "0", "0px", "0%", "calc(-2px)", "calc(-1%)" ], |
michael@0 | 897 | other_values: [ "3%", "1px", "2em", // circular |
michael@0 | 898 | "3% 2%", "1px 4px", "2em 2pt", // elliptical |
michael@0 | 899 | "calc(2px)", |
michael@0 | 900 | "calc(50%)", |
michael@0 | 901 | "calc(3*25px)", |
michael@0 | 902 | "calc(3*25px) 5px", |
michael@0 | 903 | "5px calc(3*25px)", |
michael@0 | 904 | "calc(20%) calc(3*25px)", |
michael@0 | 905 | "calc(25px*3)", |
michael@0 | 906 | "calc(3*25px + 50%)", |
michael@0 | 907 | ], |
michael@0 | 908 | invalid_values: [ "-1px", "4px -2px", "inherit 2px", "2px inherit", "2", "2px 2", "2 2px" ] |
michael@0 | 909 | }, |
michael@0 | 910 | "-moz-border-right-colors": { |
michael@0 | 911 | domProp: "MozBorderRightColors", |
michael@0 | 912 | inherited: false, |
michael@0 | 913 | type: CSS_TYPE_LONGHAND, |
michael@0 | 914 | initial_values: [ "none" ], |
michael@0 | 915 | other_values: [ "red green", "red #fc3", "#ff00cc", "currentColor", "blue currentColor orange currentColor" ], |
michael@0 | 916 | invalid_values: [ "red none", "red inherit", "red, green", "none red", "inherit red", "ff00cc" ] |
michael@0 | 917 | }, |
michael@0 | 918 | "-moz-border-start": { |
michael@0 | 919 | domProp: "MozBorderStart", |
michael@0 | 920 | inherited: false, |
michael@0 | 921 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 922 | subproperties: [ "-moz-border-start-color", "-moz-border-start-style", "-moz-border-start-width" ], |
michael@0 | 923 | initial_values: [ "none", "medium", "currentColor", "thin", "none medium currentcolor" ], |
michael@0 | 924 | other_values: [ "solid", "green", "medium solid", "green solid", "10px solid", "thick solid", "5px green none" ], |
michael@0 | 925 | invalid_values: [ "5%", "5", "5 green solid" ] |
michael@0 | 926 | }, |
michael@0 | 927 | "-moz-border-start-color": { |
michael@0 | 928 | domProp: "MozBorderStartColor", |
michael@0 | 929 | inherited: false, |
michael@0 | 930 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 931 | get_computed: logical_box_prop_get_computed, |
michael@0 | 932 | initial_values: [ "currentColor" ], |
michael@0 | 933 | other_values: [ "green", "rgba(255,128,0,0.5)", "transparent" ], |
michael@0 | 934 | invalid_values: [ "#0", "#00", "#0000", "#00000", "#0000000", "#00000000", "#000000000", "000000" ] |
michael@0 | 935 | }, |
michael@0 | 936 | "-moz-border-start-style": { |
michael@0 | 937 | domProp: "MozBorderStartStyle", |
michael@0 | 938 | inherited: false, |
michael@0 | 939 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 940 | get_computed: logical_box_prop_get_computed, |
michael@0 | 941 | /* XXX hidden is sometimes the same as initial */ |
michael@0 | 942 | initial_values: [ "none" ], |
michael@0 | 943 | other_values: [ "solid", "dashed", "dotted", "double", "outset", "inset", "groove", "ridge" ], |
michael@0 | 944 | invalid_values: [] |
michael@0 | 945 | }, |
michael@0 | 946 | "-moz-border-start-width": { |
michael@0 | 947 | domProp: "MozBorderStartWidth", |
michael@0 | 948 | inherited: false, |
michael@0 | 949 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 950 | get_computed: logical_box_prop_get_computed, |
michael@0 | 951 | prerequisites: { "-moz-border-start-style": "solid" }, |
michael@0 | 952 | initial_values: [ "medium", "3px", "calc(4px - 1px)" ], |
michael@0 | 953 | other_values: [ "thin", "thick", "1px", "2em", |
michael@0 | 954 | "calc(2px)", |
michael@0 | 955 | "calc(-2px)", |
michael@0 | 956 | "calc(0em)", |
michael@0 | 957 | "calc(0px)", |
michael@0 | 958 | "calc(5em)", |
michael@0 | 959 | "calc(3*25px)", |
michael@0 | 960 | "calc(25px*3)", |
michael@0 | 961 | "calc(3*25px + 5em)", |
michael@0 | 962 | ], |
michael@0 | 963 | invalid_values: [ "5%", "5" ] |
michael@0 | 964 | }, |
michael@0 | 965 | "-moz-border-top-colors": { |
michael@0 | 966 | domProp: "MozBorderTopColors", |
michael@0 | 967 | inherited: false, |
michael@0 | 968 | type: CSS_TYPE_LONGHAND, |
michael@0 | 969 | initial_values: [ "none" ], |
michael@0 | 970 | other_values: [ "red green", "red #fc3", "#ff00cc", "currentColor", "blue currentColor orange currentColor" ], |
michael@0 | 971 | invalid_values: [ "red none", "red inherit", "red, green", "none red", "inherit red", "ff00cc" ] |
michael@0 | 972 | }, |
michael@0 | 973 | "-moz-box-align": { |
michael@0 | 974 | domProp: "MozBoxAlign", |
michael@0 | 975 | inherited: false, |
michael@0 | 976 | type: CSS_TYPE_LONGHAND, |
michael@0 | 977 | initial_values: [ "stretch" ], |
michael@0 | 978 | other_values: [ "start", "center", "baseline", "end" ], |
michael@0 | 979 | invalid_values: [] |
michael@0 | 980 | }, |
michael@0 | 981 | "-moz-box-direction": { |
michael@0 | 982 | domProp: "MozBoxDirection", |
michael@0 | 983 | inherited: false, |
michael@0 | 984 | type: CSS_TYPE_LONGHAND, |
michael@0 | 985 | initial_values: [ "normal" ], |
michael@0 | 986 | other_values: [ "reverse" ], |
michael@0 | 987 | invalid_values: [] |
michael@0 | 988 | }, |
michael@0 | 989 | "-moz-box-flex": { |
michael@0 | 990 | domProp: "MozBoxFlex", |
michael@0 | 991 | inherited: false, |
michael@0 | 992 | type: CSS_TYPE_LONGHAND, |
michael@0 | 993 | initial_values: [ "0", "0.0", "-0.0" ], |
michael@0 | 994 | other_values: [ "1", "100", "0.1" ], |
michael@0 | 995 | invalid_values: [ "10px", "-1" ] |
michael@0 | 996 | }, |
michael@0 | 997 | "-moz-box-ordinal-group": { |
michael@0 | 998 | domProp: "MozBoxOrdinalGroup", |
michael@0 | 999 | inherited: false, |
michael@0 | 1000 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1001 | initial_values: [ "1" ], |
michael@0 | 1002 | other_values: [ "2", "100", "0" ], |
michael@0 | 1003 | invalid_values: [ "1.0", "-1", "-1000" ] |
michael@0 | 1004 | }, |
michael@0 | 1005 | "-moz-box-orient": { |
michael@0 | 1006 | domProp: "MozBoxOrient", |
michael@0 | 1007 | inherited: false, |
michael@0 | 1008 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1009 | initial_values: [ "horizontal", "inline-axis" ], |
michael@0 | 1010 | other_values: [ "vertical", "block-axis" ], |
michael@0 | 1011 | invalid_values: [] |
michael@0 | 1012 | }, |
michael@0 | 1013 | "-moz-box-pack": { |
michael@0 | 1014 | domProp: "MozBoxPack", |
michael@0 | 1015 | inherited: false, |
michael@0 | 1016 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1017 | initial_values: [ "start" ], |
michael@0 | 1018 | other_values: [ "center", "end", "justify" ], |
michael@0 | 1019 | invalid_values: [] |
michael@0 | 1020 | }, |
michael@0 | 1021 | "box-sizing": { |
michael@0 | 1022 | domProp: "boxSizing", |
michael@0 | 1023 | inherited: false, |
michael@0 | 1024 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1025 | initial_values: [ "content-box" ], |
michael@0 | 1026 | other_values: [ "border-box", "padding-box" ], |
michael@0 | 1027 | invalid_values: [ "margin-box", "content", "padding", "border", "margin" ] |
michael@0 | 1028 | }, |
michael@0 | 1029 | "-moz-box-sizing": { |
michael@0 | 1030 | domProp: "MozBoxSizing", |
michael@0 | 1031 | inherited: false, |
michael@0 | 1032 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 1033 | alias_for: "box-sizing", |
michael@0 | 1034 | subproperties: [ "box-sizing" ], |
michael@0 | 1035 | initial_values: [ "content-box" ], |
michael@0 | 1036 | other_values: [ "border-box", "padding-box" ], |
michael@0 | 1037 | invalid_values: [ "margin-box", "content", "padding", "border", "margin" ] |
michael@0 | 1038 | }, |
michael@0 | 1039 | "-moz-columns": { |
michael@0 | 1040 | domProp: "MozColumns", |
michael@0 | 1041 | inherited: false, |
michael@0 | 1042 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 1043 | subproperties: [ "-moz-column-count", "-moz-column-width" ], |
michael@0 | 1044 | initial_values: [ "auto", "auto auto" ], |
michael@0 | 1045 | other_values: [ "3", "20px", "2 10px", "10px 2", "2 auto", "auto 2", "auto 50px", "50px auto" ], |
michael@0 | 1046 | invalid_values: [ "5%", "-1px", "-1", "3 5", "10px 4px", "10 2px 5in", "30px -1", |
michael@0 | 1047 | "auto 3 5px", "5 auto 20px", "auto auto auto" ] |
michael@0 | 1048 | }, |
michael@0 | 1049 | "-moz-column-count": { |
michael@0 | 1050 | domProp: "MozColumnCount", |
michael@0 | 1051 | inherited: false, |
michael@0 | 1052 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1053 | initial_values: [ "auto" ], |
michael@0 | 1054 | other_values: [ "1", "17" ], |
michael@0 | 1055 | // negative and zero invalid per editor's draft |
michael@0 | 1056 | invalid_values: [ "-1", "0", "3px" ] |
michael@0 | 1057 | }, |
michael@0 | 1058 | "-moz-column-fill": { |
michael@0 | 1059 | domProp: "MozColumnFill", |
michael@0 | 1060 | inherited: false, |
michael@0 | 1061 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1062 | initial_values: [ "balance" ], |
michael@0 | 1063 | other_values: [ "auto" ], |
michael@0 | 1064 | invalid_values: [ "2px", "dotted", "5em" ] |
michael@0 | 1065 | }, |
michael@0 | 1066 | "-moz-column-gap": { |
michael@0 | 1067 | domProp: "MozColumnGap", |
michael@0 | 1068 | inherited: false, |
michael@0 | 1069 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1070 | initial_values: [ "normal", "1em", "calc(-2em + 3em)" ], |
michael@0 | 1071 | other_values: [ "2px", "4em", |
michael@0 | 1072 | "calc(2px)", |
michael@0 | 1073 | "calc(-2px)", |
michael@0 | 1074 | "calc(0px)", |
michael@0 | 1075 | "calc(0pt)", |
michael@0 | 1076 | "calc(5em)", |
michael@0 | 1077 | "calc(3*25px)", |
michael@0 | 1078 | "calc(25px*3)", |
michael@0 | 1079 | "calc(3*25px + 5em)", |
michael@0 | 1080 | ], |
michael@0 | 1081 | invalid_values: [ "3%", "-1px", "4" ] |
michael@0 | 1082 | }, |
michael@0 | 1083 | "-moz-column-rule": { |
michael@0 | 1084 | domProp: "MozColumnRule", |
michael@0 | 1085 | inherited: false, |
michael@0 | 1086 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 1087 | prerequisites: { "color": "green" }, |
michael@0 | 1088 | subproperties: [ "-moz-column-rule-width", "-moz-column-rule-style", "-moz-column-rule-color" ], |
michael@0 | 1089 | initial_values: [ "medium none currentColor", "none", "medium", "currentColor" ], |
michael@0 | 1090 | other_values: [ "2px blue solid", "red dotted 1px", "ridge 4px orange", "5px solid" ], |
michael@0 | 1091 | invalid_values: [ "2px 3px 4px red", "dotted dashed", "5px dashed green 3px", "5 solid", "5 green solid" ] |
michael@0 | 1092 | }, |
michael@0 | 1093 | "-moz-column-rule-width": { |
michael@0 | 1094 | domProp: "MozColumnRuleWidth", |
michael@0 | 1095 | inherited: false, |
michael@0 | 1096 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1097 | prerequisites: { "-moz-column-rule-style": "solid" }, |
michael@0 | 1098 | initial_values: [ |
michael@0 | 1099 | "medium", |
michael@0 | 1100 | "3px", |
michael@0 | 1101 | "-moz-calc(3px)", |
michael@0 | 1102 | "-moz-calc(5em + 3px - 5em)", |
michael@0 | 1103 | "calc(3px)", |
michael@0 | 1104 | "calc(5em + 3px - 5em)", |
michael@0 | 1105 | ], |
michael@0 | 1106 | other_values: [ "thin", "15px", |
michael@0 | 1107 | /* valid -moz-calc() values */ |
michael@0 | 1108 | "-moz-calc(-2px)", |
michael@0 | 1109 | "-moz-calc(2px)", |
michael@0 | 1110 | "-moz-calc(3em)", |
michael@0 | 1111 | "-moz-calc(3em + 2px)", |
michael@0 | 1112 | "-moz-calc( 3em + 2px)", |
michael@0 | 1113 | "-moz-calc(3em + 2px )", |
michael@0 | 1114 | "-moz-calc( 3em + 2px )", |
michael@0 | 1115 | "-moz-calc(3*25px)", |
michael@0 | 1116 | "-moz-calc(3 *25px)", |
michael@0 | 1117 | "-moz-calc(3 * 25px)", |
michael@0 | 1118 | "-moz-calc(3* 25px)", |
michael@0 | 1119 | "-moz-calc(25px*3)", |
michael@0 | 1120 | "-moz-calc(25px *3)", |
michael@0 | 1121 | "-moz-calc(25px* 3)", |
michael@0 | 1122 | "-moz-calc(25px * 3)", |
michael@0 | 1123 | "-moz-calc(25px * 3 / 4)", |
michael@0 | 1124 | "-moz-calc((25px * 3) / 4)", |
michael@0 | 1125 | "-moz-calc(25px * (3 / 4))", |
michael@0 | 1126 | "-moz-calc(3 * 25px / 4)", |
michael@0 | 1127 | "-moz-calc((3 * 25px) / 4)", |
michael@0 | 1128 | "-moz-calc(3 * (25px / 4))", |
michael@0 | 1129 | "-moz-calc(3em + 25px * 3 / 4)", |
michael@0 | 1130 | "-moz-calc(3em + (25px * 3) / 4)", |
michael@0 | 1131 | "-moz-calc(3em + 25px * (3 / 4))", |
michael@0 | 1132 | "-moz-calc(25px * 3 / 4 + 3em)", |
michael@0 | 1133 | "-moz-calc((25px * 3) / 4 + 3em)", |
michael@0 | 1134 | "-moz-calc(25px * (3 / 4) + 3em)", |
michael@0 | 1135 | "-moz-calc(3em + (25px * 3 / 4))", |
michael@0 | 1136 | "-moz-calc(3em + ((25px * 3) / 4))", |
michael@0 | 1137 | "-moz-calc(3em + (25px * (3 / 4)))", |
michael@0 | 1138 | "-moz-calc((25px * 3 / 4) + 3em)", |
michael@0 | 1139 | "-moz-calc(((25px * 3) / 4) + 3em)", |
michael@0 | 1140 | "-moz-calc((25px * (3 / 4)) + 3em)", |
michael@0 | 1141 | "-moz-calc(3*25px + 1in)", |
michael@0 | 1142 | "-moz-calc(1in - 3em + 2px)", |
michael@0 | 1143 | "-moz-calc(1in - (3em + 2px))", |
michael@0 | 1144 | "-moz-calc((1in - 3em) + 2px)", |
michael@0 | 1145 | "-moz-calc(50px/2)", |
michael@0 | 1146 | "-moz-calc(50px/(2 - 1))", |
michael@0 | 1147 | "-moz-calc(-3px)", |
michael@0 | 1148 | /* numeric reduction cases */ |
michael@0 | 1149 | "-moz-calc(5 * 3 * 2em)", |
michael@0 | 1150 | "-moz-calc(2em * 5 * 3)", |
michael@0 | 1151 | "-moz-calc((5 * 3) * 2em)", |
michael@0 | 1152 | "-moz-calc(2em * (5 * 3))", |
michael@0 | 1153 | "-moz-calc((5 + 3) * 2em)", |
michael@0 | 1154 | "-moz-calc(2em * (5 + 3))", |
michael@0 | 1155 | "-moz-calc(2em / (5 + 3))", |
michael@0 | 1156 | "-moz-calc(2em * (5*2 + 3))", |
michael@0 | 1157 | "-moz-calc(2em * ((5*2) + 3))", |
michael@0 | 1158 | "-moz-calc(2em * (5*(2 + 3)))", |
michael@0 | 1159 | |
michael@0 | 1160 | "-moz-calc((5 + 7) * 3em)", |
michael@0 | 1161 | "-moz-calc((5em + 3em) - 2em)", |
michael@0 | 1162 | "-moz-calc((5em - 3em) + 2em)", |
michael@0 | 1163 | "-moz-calc(2em - (5em - 3em))", |
michael@0 | 1164 | "-moz-calc(2em + (5em - 3em))", |
michael@0 | 1165 | "-moz-calc(2em - (5em + 3em))", |
michael@0 | 1166 | "-moz-calc(2em + (5em + 3em))", |
michael@0 | 1167 | "-moz-calc(2em + 5em - 3em)", |
michael@0 | 1168 | "-moz-calc(2em - 5em - 3em)", |
michael@0 | 1169 | "-moz-calc(2em + 5em + 3em)", |
michael@0 | 1170 | "-moz-calc(2em - 5em + 3em)", |
michael@0 | 1171 | |
michael@0 | 1172 | "-moz-calc(2em / 4 * 3)", |
michael@0 | 1173 | "-moz-calc(2em * 4 / 3)", |
michael@0 | 1174 | "-moz-calc(2em * 4 * 3)", |
michael@0 | 1175 | "-moz-calc(2em / 4 / 3)", |
michael@0 | 1176 | "-moz-calc(4 * 2em / 3)", |
michael@0 | 1177 | "-moz-calc(4 / 3 * 2em)", |
michael@0 | 1178 | |
michael@0 | 1179 | "-moz-calc((2em / 4) * 3)", |
michael@0 | 1180 | "-moz-calc((2em * 4) / 3)", |
michael@0 | 1181 | "-moz-calc((2em * 4) * 3)", |
michael@0 | 1182 | "-moz-calc((2em / 4) / 3)", |
michael@0 | 1183 | "-moz-calc((4 * 2em) / 3)", |
michael@0 | 1184 | "-moz-calc((4 / 3) * 2em)", |
michael@0 | 1185 | |
michael@0 | 1186 | "-moz-calc(2em / (4 * 3))", |
michael@0 | 1187 | "-moz-calc(2em * (4 / 3))", |
michael@0 | 1188 | "-moz-calc(2em * (4 * 3))", |
michael@0 | 1189 | "-moz-calc(2em / (4 / 3))", |
michael@0 | 1190 | "-moz-calc(4 * (2em / 3))", |
michael@0 | 1191 | |
michael@0 | 1192 | // Valid cases with unitless zero (which is never |
michael@0 | 1193 | // a length). |
michael@0 | 1194 | "-moz-calc(0 * 2em)", |
michael@0 | 1195 | "-moz-calc(2em * 0)", |
michael@0 | 1196 | "-moz-calc(3em + 0 * 2em)", |
michael@0 | 1197 | "-moz-calc(3em + 2em * 0)", |
michael@0 | 1198 | "-moz-calc((0 + 2) * 2em)", |
michael@0 | 1199 | "-moz-calc((2 + 0) * 2em)", |
michael@0 | 1200 | // And test zero lengths while we're here. |
michael@0 | 1201 | "-moz-calc(2 * 0px)", |
michael@0 | 1202 | "-moz-calc(0 * 0px)", |
michael@0 | 1203 | "-moz-calc(2 * 0em)", |
michael@0 | 1204 | "-moz-calc(0 * 0em)", |
michael@0 | 1205 | "-moz-calc(0px * 0)", |
michael@0 | 1206 | "-moz-calc(0px * 2)", |
michael@0 | 1207 | |
michael@0 | 1208 | /* valid calc() values */ |
michael@0 | 1209 | "calc(-2px)", |
michael@0 | 1210 | "calc(2px)", |
michael@0 | 1211 | "calc(3em)", |
michael@0 | 1212 | "calc(3em + 2px)", |
michael@0 | 1213 | "calc( 3em + 2px)", |
michael@0 | 1214 | "calc(3em + 2px )", |
michael@0 | 1215 | "calc( 3em + 2px )", |
michael@0 | 1216 | "calc(3*25px)", |
michael@0 | 1217 | "calc(3 *25px)", |
michael@0 | 1218 | "calc(3 * 25px)", |
michael@0 | 1219 | "calc(3* 25px)", |
michael@0 | 1220 | "calc(25px*3)", |
michael@0 | 1221 | "calc(25px *3)", |
michael@0 | 1222 | "calc(25px* 3)", |
michael@0 | 1223 | "calc(25px * 3)", |
michael@0 | 1224 | "calc(25px * 3 / 4)", |
michael@0 | 1225 | "calc((25px * 3) / 4)", |
michael@0 | 1226 | "calc(25px * (3 / 4))", |
michael@0 | 1227 | "calc(3 * 25px / 4)", |
michael@0 | 1228 | "calc((3 * 25px) / 4)", |
michael@0 | 1229 | "calc(3 * (25px / 4))", |
michael@0 | 1230 | "calc(3em + 25px * 3 / 4)", |
michael@0 | 1231 | "calc(3em + (25px * 3) / 4)", |
michael@0 | 1232 | "calc(3em + 25px * (3 / 4))", |
michael@0 | 1233 | "calc(25px * 3 / 4 + 3em)", |
michael@0 | 1234 | "calc((25px * 3) / 4 + 3em)", |
michael@0 | 1235 | "calc(25px * (3 / 4) + 3em)", |
michael@0 | 1236 | "calc(3em + (25px * 3 / 4))", |
michael@0 | 1237 | "calc(3em + ((25px * 3) / 4))", |
michael@0 | 1238 | "calc(3em + (25px * (3 / 4)))", |
michael@0 | 1239 | "calc((25px * 3 / 4) + 3em)", |
michael@0 | 1240 | "calc(((25px * 3) / 4) + 3em)", |
michael@0 | 1241 | "calc((25px * (3 / 4)) + 3em)", |
michael@0 | 1242 | "calc(3*25px + 1in)", |
michael@0 | 1243 | "calc(1in - 3em + 2px)", |
michael@0 | 1244 | "calc(1in - (3em + 2px))", |
michael@0 | 1245 | "calc((1in - 3em) + 2px)", |
michael@0 | 1246 | "calc(50px/2)", |
michael@0 | 1247 | "calc(50px/(2 - 1))", |
michael@0 | 1248 | "calc(-3px)", |
michael@0 | 1249 | /* numeric reduction cases */ |
michael@0 | 1250 | "calc(5 * 3 * 2em)", |
michael@0 | 1251 | "calc(2em * 5 * 3)", |
michael@0 | 1252 | "calc((5 * 3) * 2em)", |
michael@0 | 1253 | "calc(2em * (5 * 3))", |
michael@0 | 1254 | "calc((5 + 3) * 2em)", |
michael@0 | 1255 | "calc(2em * (5 + 3))", |
michael@0 | 1256 | "calc(2em / (5 + 3))", |
michael@0 | 1257 | "calc(2em * (5*2 + 3))", |
michael@0 | 1258 | "calc(2em * ((5*2) + 3))", |
michael@0 | 1259 | "calc(2em * (5*(2 + 3)))", |
michael@0 | 1260 | |
michael@0 | 1261 | "calc((5 + 7) * 3em)", |
michael@0 | 1262 | "calc((5em + 3em) - 2em)", |
michael@0 | 1263 | "calc((5em - 3em) + 2em)", |
michael@0 | 1264 | "calc(2em - (5em - 3em))", |
michael@0 | 1265 | "calc(2em + (5em - 3em))", |
michael@0 | 1266 | "calc(2em - (5em + 3em))", |
michael@0 | 1267 | "calc(2em + (5em + 3em))", |
michael@0 | 1268 | "calc(2em + 5em - 3em)", |
michael@0 | 1269 | "calc(2em - 5em - 3em)", |
michael@0 | 1270 | "calc(2em + 5em + 3em)", |
michael@0 | 1271 | "calc(2em - 5em + 3em)", |
michael@0 | 1272 | |
michael@0 | 1273 | "calc(2em / 4 * 3)", |
michael@0 | 1274 | "calc(2em * 4 / 3)", |
michael@0 | 1275 | "calc(2em * 4 * 3)", |
michael@0 | 1276 | "calc(2em / 4 / 3)", |
michael@0 | 1277 | "calc(4 * 2em / 3)", |
michael@0 | 1278 | "calc(4 / 3 * 2em)", |
michael@0 | 1279 | |
michael@0 | 1280 | "calc((2em / 4) * 3)", |
michael@0 | 1281 | "calc((2em * 4) / 3)", |
michael@0 | 1282 | "calc((2em * 4) * 3)", |
michael@0 | 1283 | "calc((2em / 4) / 3)", |
michael@0 | 1284 | "calc((4 * 2em) / 3)", |
michael@0 | 1285 | "calc((4 / 3) * 2em)", |
michael@0 | 1286 | |
michael@0 | 1287 | "calc(2em / (4 * 3))", |
michael@0 | 1288 | "calc(2em * (4 / 3))", |
michael@0 | 1289 | "calc(2em * (4 * 3))", |
michael@0 | 1290 | "calc(2em / (4 / 3))", |
michael@0 | 1291 | "calc(4 * (2em / 3))", |
michael@0 | 1292 | |
michael@0 | 1293 | // Valid cases with unitless zero (which is never |
michael@0 | 1294 | // a length). |
michael@0 | 1295 | "calc(0 * 2em)", |
michael@0 | 1296 | "calc(2em * 0)", |
michael@0 | 1297 | "calc(3em + 0 * 2em)", |
michael@0 | 1298 | "calc(3em + 2em * 0)", |
michael@0 | 1299 | "calc((0 + 2) * 2em)", |
michael@0 | 1300 | "calc((2 + 0) * 2em)", |
michael@0 | 1301 | // And test zero lengths while we're here. |
michael@0 | 1302 | "calc(2 * 0px)", |
michael@0 | 1303 | "calc(0 * 0px)", |
michael@0 | 1304 | "calc(2 * 0em)", |
michael@0 | 1305 | "calc(0 * 0em)", |
michael@0 | 1306 | "calc(0px * 0)", |
michael@0 | 1307 | "calc(0px * 2)", |
michael@0 | 1308 | |
michael@0 | 1309 | ], |
michael@0 | 1310 | invalid_values: [ "20", "-1px", "red", "50%", |
michael@0 | 1311 | /* invalid -moz-calc() values */ |
michael@0 | 1312 | "-moz-calc(2em+ 2px)", |
michael@0 | 1313 | "-moz-calc(2em +2px)", |
michael@0 | 1314 | "-moz-calc(2em+2px)", |
michael@0 | 1315 | "-moz-calc(2em- 2px)", |
michael@0 | 1316 | "-moz-calc(2em -2px)", |
michael@0 | 1317 | "-moz-calc(2em-2px)", |
michael@0 | 1318 | /* invalid calc() values */ |
michael@0 | 1319 | "calc(2em+ 2px)", |
michael@0 | 1320 | "calc(2em +2px)", |
michael@0 | 1321 | "calc(2em+2px)", |
michael@0 | 1322 | "calc(2em- 2px)", |
michael@0 | 1323 | "calc(2em -2px)", |
michael@0 | 1324 | "calc(2em-2px)", |
michael@0 | 1325 | "-moz-min()", |
michael@0 | 1326 | "calc(min())", |
michael@0 | 1327 | "-moz-max()", |
michael@0 | 1328 | "calc(max())", |
michael@0 | 1329 | "-moz-min(5px)", |
michael@0 | 1330 | "calc(min(5px))", |
michael@0 | 1331 | "-moz-max(5px)", |
michael@0 | 1332 | "calc(max(5px))", |
michael@0 | 1333 | "-moz-min(5px,2em)", |
michael@0 | 1334 | "calc(min(5px,2em))", |
michael@0 | 1335 | "-moz-max(5px,2em)", |
michael@0 | 1336 | "calc(max(5px,2em))", |
michael@0 | 1337 | "calc(50px/(2 - 2))", |
michael@0 | 1338 | "calc(5 + 5)", |
michael@0 | 1339 | "calc(5 * 5)", |
michael@0 | 1340 | "calc(5em * 5em)", |
michael@0 | 1341 | "calc(5em / 5em * 5em)", |
michael@0 | 1342 | |
michael@0 | 1343 | "calc(4 * 3 / 2em)", |
michael@0 | 1344 | "calc((4 * 3) / 2em)", |
michael@0 | 1345 | "calc(4 * (3 / 2em))", |
michael@0 | 1346 | "calc(4 / (3 * 2em))", |
michael@0 | 1347 | |
michael@0 | 1348 | // Tests for handling of unitless zero, which cannot |
michael@0 | 1349 | // be a length inside calc(). |
michael@0 | 1350 | "calc(0)", |
michael@0 | 1351 | "calc(0 + 2em)", |
michael@0 | 1352 | "calc(2em + 0)", |
michael@0 | 1353 | "calc(0 * 2)", |
michael@0 | 1354 | "calc(2 * 0)", |
michael@0 | 1355 | "calc(1 * (2em + 0))", |
michael@0 | 1356 | "calc((2em + 0))", |
michael@0 | 1357 | "calc((2em + 0) * 1)", |
michael@0 | 1358 | "calc(1 * (0 + 2em))", |
michael@0 | 1359 | "calc((0 + 2em))", |
michael@0 | 1360 | "calc((0 + 2em) * 1)", |
michael@0 | 1361 | ] |
michael@0 | 1362 | }, |
michael@0 | 1363 | "-moz-column-rule-style": { |
michael@0 | 1364 | domProp: "MozColumnRuleStyle", |
michael@0 | 1365 | inherited: false, |
michael@0 | 1366 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1367 | initial_values: [ "none" ], |
michael@0 | 1368 | other_values: [ "solid", "hidden", "ridge", "groove", "inset", "outset", "double", "dotted", "dashed" ], |
michael@0 | 1369 | invalid_values: [ "20", "foo" ] |
michael@0 | 1370 | }, |
michael@0 | 1371 | "-moz-column-rule-color": { |
michael@0 | 1372 | domProp: "MozColumnRuleColor", |
michael@0 | 1373 | inherited: false, |
michael@0 | 1374 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1375 | prerequisites: { "color": "green" }, |
michael@0 | 1376 | initial_values: [ "currentColor", "-moz-use-text-color" ], |
michael@0 | 1377 | other_values: [ "red", "blue", "#ffff00" ], |
michael@0 | 1378 | invalid_values: [ "ffff00" ] |
michael@0 | 1379 | }, |
michael@0 | 1380 | "-moz-column-width": { |
michael@0 | 1381 | domProp: "MozColumnWidth", |
michael@0 | 1382 | inherited: false, |
michael@0 | 1383 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1384 | initial_values: [ "auto" ], |
michael@0 | 1385 | other_values: [ |
michael@0 | 1386 | "15px", |
michael@0 | 1387 | "calc(15px)", |
michael@0 | 1388 | "calc(30px - 3em)", |
michael@0 | 1389 | "calc(-15px)", |
michael@0 | 1390 | "0px", |
michael@0 | 1391 | "calc(0px)" |
michael@0 | 1392 | ], |
michael@0 | 1393 | invalid_values: [ "20", "-1px", "50%" ] |
michael@0 | 1394 | }, |
michael@0 | 1395 | "-moz-float-edge": { |
michael@0 | 1396 | domProp: "MozFloatEdge", |
michael@0 | 1397 | inherited: false, |
michael@0 | 1398 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1399 | initial_values: [ "content-box" ], |
michael@0 | 1400 | other_values: [ "margin-box" ], |
michael@0 | 1401 | invalid_values: [ "content", "padding", "border", "margin" ] |
michael@0 | 1402 | }, |
michael@0 | 1403 | "-moz-force-broken-image-icon": { |
michael@0 | 1404 | domProp: "MozForceBrokenImageIcon", |
michael@0 | 1405 | inherited: false, |
michael@0 | 1406 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1407 | initial_values: [ "0" ], |
michael@0 | 1408 | other_values: [ "1" ], |
michael@0 | 1409 | invalid_values: [] |
michael@0 | 1410 | }, |
michael@0 | 1411 | "-moz-image-region": { |
michael@0 | 1412 | domProp: "MozImageRegion", |
michael@0 | 1413 | inherited: true, |
michael@0 | 1414 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1415 | initial_values: [ "auto" ], |
michael@0 | 1416 | other_values: [ "rect(3px 20px 15px 4px)", "rect(17px, 21px, 33px, 2px)" ], |
michael@0 | 1417 | invalid_values: [ "rect(17px, 21px, 33, 2px)" ] |
michael@0 | 1418 | }, |
michael@0 | 1419 | "-moz-margin-end": { |
michael@0 | 1420 | domProp: "MozMarginEnd", |
michael@0 | 1421 | inherited: false, |
michael@0 | 1422 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 1423 | get_computed: logical_box_prop_get_computed, |
michael@0 | 1424 | /* no subproperties */ |
michael@0 | 1425 | /* auto may or may not be initial */ |
michael@0 | 1426 | initial_values: [ "0", "0px", "0%", "0em", "0ex", "calc(0pt)", "calc(0% + 0px)" ], |
michael@0 | 1427 | other_values: [ "1px", "3em", |
michael@0 | 1428 | "calc(2px)", |
michael@0 | 1429 | "calc(-2px)", |
michael@0 | 1430 | "calc(50%)", |
michael@0 | 1431 | "calc(3*25px)", |
michael@0 | 1432 | "calc(25px*3)", |
michael@0 | 1433 | "calc(3*25px + 50%)", |
michael@0 | 1434 | ], |
michael@0 | 1435 | invalid_values: [ "5" ] |
michael@0 | 1436 | }, |
michael@0 | 1437 | "-moz-margin-start": { |
michael@0 | 1438 | domProp: "MozMarginStart", |
michael@0 | 1439 | inherited: false, |
michael@0 | 1440 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 1441 | get_computed: logical_box_prop_get_computed, |
michael@0 | 1442 | /* no subproperties */ |
michael@0 | 1443 | /* auto may or may not be initial */ |
michael@0 | 1444 | initial_values: [ "0", "0px", "0%", "0em", "0ex", "calc(0pt)", "calc(0% + 0px)" ], |
michael@0 | 1445 | other_values: [ "1px", "3em", |
michael@0 | 1446 | "calc(2px)", |
michael@0 | 1447 | "calc(-2px)", |
michael@0 | 1448 | "calc(50%)", |
michael@0 | 1449 | "calc(3*25px)", |
michael@0 | 1450 | "calc(25px*3)", |
michael@0 | 1451 | "calc(3*25px + 50%)", |
michael@0 | 1452 | ], |
michael@0 | 1453 | invalid_values: [ "5" ] |
michael@0 | 1454 | }, |
michael@0 | 1455 | "-moz-outline-radius": { |
michael@0 | 1456 | domProp: "MozOutlineRadius", |
michael@0 | 1457 | inherited: false, |
michael@0 | 1458 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 1459 | prerequisites: { "width": "200px", "height": "100px", "display": "inline-block"}, |
michael@0 | 1460 | subproperties: [ "-moz-outline-radius-bottomleft", "-moz-outline-radius-bottomright", "-moz-outline-radius-topleft", "-moz-outline-radius-topright" ], |
michael@0 | 1461 | initial_values: [ "0", "0px", "0%", "calc(-2px)", "calc(-1%)", "calc(0px) calc(0pt) calc(0%) calc(0em)" ], |
michael@0 | 1462 | other_values: [ "3%", "1px", "2em", "3em 2px", "2pt 3% 4em", "2px 2px 2px 2px", // circular |
michael@0 | 1463 | "3% / 2%", "1px / 4px", "2em / 1em", "3em 2px / 2px 3em", "2pt 3% 4em / 4pt 1% 5em", "2px 2px 2px 2px / 4px 4px 4px 4px", "1pt / 2pt 3pt", "4pt 5pt / 3pt", // elliptical |
michael@0 | 1464 | "calc(2px)", |
michael@0 | 1465 | "calc(50%)", |
michael@0 | 1466 | "calc(3*25px)", |
michael@0 | 1467 | "calc(3*25px) 5px", |
michael@0 | 1468 | "5px calc(3*25px)", |
michael@0 | 1469 | "calc(20%) calc(3*25px)", |
michael@0 | 1470 | "calc(25px*3)", |
michael@0 | 1471 | "calc(3*25px + 50%)", |
michael@0 | 1472 | "2px 2px calc(2px + 1%) 2px", |
michael@0 | 1473 | "1px 2px 2px 2px / 2px 2px calc(2px + 1%) 2px", |
michael@0 | 1474 | ], |
michael@0 | 1475 | invalid_values: [ "2px -2px", "inherit 2px", "inherit / 2px", "2px inherit", "2px / inherit", "2px 2px 2px 2px 2px", "1px / 2px 2px 2px 2px 2px", "2", "2 2", "2px 2px 2px 2px / 2px 2px 2 2px" ] |
michael@0 | 1476 | }, |
michael@0 | 1477 | "-moz-outline-radius-bottomleft": { |
michael@0 | 1478 | domProp: "MozOutlineRadiusBottomleft", |
michael@0 | 1479 | inherited: false, |
michael@0 | 1480 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1481 | prerequisites: { "width": "200px", "height": "100px", "display": "inline-block"}, |
michael@0 | 1482 | initial_values: [ "0", "0px", "0%", "calc(-2px)", "calc(-1%)", "calc(0px)" ], |
michael@0 | 1483 | other_values: [ "3%", "1px", "2em", // circular |
michael@0 | 1484 | "3% 2%", "1px 4px", "2em 2pt", // elliptical |
michael@0 | 1485 | "calc(2px)", |
michael@0 | 1486 | "calc(50%)", |
michael@0 | 1487 | "calc(3*25px)", |
michael@0 | 1488 | "calc(3*25px) 5px", |
michael@0 | 1489 | "5px calc(3*25px)", |
michael@0 | 1490 | "calc(20%) calc(3*25px)", |
michael@0 | 1491 | "calc(25px*3)", |
michael@0 | 1492 | "calc(3*25px + 50%)", |
michael@0 | 1493 | ], |
michael@0 | 1494 | invalid_values: [ "-1px", "4px -2px", "inherit 2px", "2px inherit", "2", "2px 2", "2 2px" ] |
michael@0 | 1495 | }, |
michael@0 | 1496 | "-moz-outline-radius-bottomright": { |
michael@0 | 1497 | domProp: "MozOutlineRadiusBottomright", |
michael@0 | 1498 | inherited: false, |
michael@0 | 1499 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1500 | prerequisites: { "width": "200px", "height": "100px", "display": "inline-block"}, |
michael@0 | 1501 | initial_values: [ "0", "0px", "0%", "calc(-2px)", "calc(-1%)", "calc(0px)" ], |
michael@0 | 1502 | other_values: [ "3%", "1px", "2em", // circular |
michael@0 | 1503 | "3% 2%", "1px 4px", "2em 2pt", // elliptical |
michael@0 | 1504 | "calc(2px)", |
michael@0 | 1505 | "calc(50%)", |
michael@0 | 1506 | "calc(3*25px)", |
michael@0 | 1507 | "calc(3*25px) 5px", |
michael@0 | 1508 | "5px calc(3*25px)", |
michael@0 | 1509 | "calc(20%) calc(3*25px)", |
michael@0 | 1510 | "calc(25px*3)", |
michael@0 | 1511 | "calc(3*25px + 50%)", |
michael@0 | 1512 | ], |
michael@0 | 1513 | invalid_values: [ "-1px", "4px -2px", "inherit 2px", "2px inherit", "2", "2px 2", "2 2px" ] |
michael@0 | 1514 | }, |
michael@0 | 1515 | "-moz-outline-radius-topleft": { |
michael@0 | 1516 | domProp: "MozOutlineRadiusTopleft", |
michael@0 | 1517 | inherited: false, |
michael@0 | 1518 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1519 | prerequisites: { "width": "200px", "height": "100px", "display": "inline-block"}, |
michael@0 | 1520 | initial_values: [ "0", "0px", "0%", "calc(-2px)", "calc(-1%)", "calc(0px)" ], |
michael@0 | 1521 | other_values: [ "3%", "1px", "2em", // circular |
michael@0 | 1522 | "3% 2%", "1px 4px", "2em 2pt", // elliptical |
michael@0 | 1523 | "calc(2px)", |
michael@0 | 1524 | "calc(50%)", |
michael@0 | 1525 | "calc(3*25px)", |
michael@0 | 1526 | "calc(3*25px) 5px", |
michael@0 | 1527 | "5px calc(3*25px)", |
michael@0 | 1528 | "calc(20%) calc(3*25px)", |
michael@0 | 1529 | "calc(25px*3)", |
michael@0 | 1530 | "calc(3*25px + 50%)", |
michael@0 | 1531 | ], |
michael@0 | 1532 | invalid_values: [ "-1px", "4px -2px", "inherit 2px", "2px inherit", "2", "2px 2", "2 2px" ] |
michael@0 | 1533 | }, |
michael@0 | 1534 | "-moz-outline-radius-topright": { |
michael@0 | 1535 | domProp: "MozOutlineRadiusTopright", |
michael@0 | 1536 | inherited: false, |
michael@0 | 1537 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1538 | prerequisites: { "width": "200px", "height": "100px", "display": "inline-block"}, |
michael@0 | 1539 | initial_values: [ "0", "0px", "0%", "calc(-2px)", "calc(-1%)", "calc(0px)" ], |
michael@0 | 1540 | other_values: [ "3%", "1px", "2em", // circular |
michael@0 | 1541 | "3% 2%", "1px 4px", "2em 2pt", // elliptical |
michael@0 | 1542 | "calc(2px)", |
michael@0 | 1543 | "calc(50%)", |
michael@0 | 1544 | "calc(3*25px)", |
michael@0 | 1545 | "calc(3*25px) 5px", |
michael@0 | 1546 | "5px calc(3*25px)", |
michael@0 | 1547 | "calc(20%) calc(3*25px)", |
michael@0 | 1548 | "calc(25px*3)", |
michael@0 | 1549 | "calc(3*25px + 50%)", |
michael@0 | 1550 | ], |
michael@0 | 1551 | invalid_values: [ "-1px", "4px -2px", "inherit 2px", "2px inherit", "2", "2px 2", "2 2px" ] |
michael@0 | 1552 | }, |
michael@0 | 1553 | "-moz-padding-end": { |
michael@0 | 1554 | domProp: "MozPaddingEnd", |
michael@0 | 1555 | inherited: false, |
michael@0 | 1556 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 1557 | get_computed: logical_box_prop_get_computed, |
michael@0 | 1558 | /* no subproperties */ |
michael@0 | 1559 | initial_values: [ "0", "0px", "0%", "0em", "0ex", "calc(0pt)", "calc(0% + 0px)", "calc(-3px)", "calc(-1%)" ], |
michael@0 | 1560 | other_values: [ "1px", "3em", |
michael@0 | 1561 | "calc(2px)", |
michael@0 | 1562 | "calc(50%)", |
michael@0 | 1563 | "calc(3*25px)", |
michael@0 | 1564 | "calc(25px*3)", |
michael@0 | 1565 | "calc(3*25px + 50%)", |
michael@0 | 1566 | ], |
michael@0 | 1567 | invalid_values: [ "5" ] |
michael@0 | 1568 | }, |
michael@0 | 1569 | "-moz-padding-start": { |
michael@0 | 1570 | domProp: "MozPaddingStart", |
michael@0 | 1571 | inherited: false, |
michael@0 | 1572 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 1573 | get_computed: logical_box_prop_get_computed, |
michael@0 | 1574 | /* no subproperties */ |
michael@0 | 1575 | initial_values: [ "0", "0px", "0%", "0em", "0ex", "calc(0pt)", "calc(0% + 0px)", "calc(-3px)", "calc(-1%)" ], |
michael@0 | 1576 | other_values: [ "1px", "3em", |
michael@0 | 1577 | "calc(2px)", |
michael@0 | 1578 | "calc(50%)", |
michael@0 | 1579 | "calc(3*25px)", |
michael@0 | 1580 | "calc(25px*3)", |
michael@0 | 1581 | "calc(3*25px + 50%)", |
michael@0 | 1582 | ], |
michael@0 | 1583 | invalid_values: [ "5" ] |
michael@0 | 1584 | }, |
michael@0 | 1585 | "resize": { |
michael@0 | 1586 | domProp: "resize", |
michael@0 | 1587 | inherited: false, |
michael@0 | 1588 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1589 | prerequisites: { "display": "block", "overflow": "auto" }, |
michael@0 | 1590 | initial_values: [ "none" ], |
michael@0 | 1591 | other_values: [ "both", "horizontal", "vertical" ], |
michael@0 | 1592 | invalid_values: [] |
michael@0 | 1593 | }, |
michael@0 | 1594 | "-moz-stack-sizing": { |
michael@0 | 1595 | domProp: "MozStackSizing", |
michael@0 | 1596 | inherited: false, |
michael@0 | 1597 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1598 | initial_values: [ "stretch-to-fit" ], |
michael@0 | 1599 | other_values: [ "ignore" ], |
michael@0 | 1600 | invalid_values: [] |
michael@0 | 1601 | }, |
michael@0 | 1602 | "-moz-tab-size": { |
michael@0 | 1603 | domProp: "MozTabSize", |
michael@0 | 1604 | inherited: true, |
michael@0 | 1605 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1606 | initial_values: [ "8" ], |
michael@0 | 1607 | other_values: [ "0", "3", "99", "12000" ], |
michael@0 | 1608 | invalid_values: [ "-1", "-808", "3.0", "17.5" ] |
michael@0 | 1609 | }, |
michael@0 | 1610 | "-moz-text-size-adjust": { |
michael@0 | 1611 | domProp: "MozTextSizeAdjust", |
michael@0 | 1612 | inherited: true, |
michael@0 | 1613 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1614 | initial_values: [ "auto" ], |
michael@0 | 1615 | other_values: [ "none" ], |
michael@0 | 1616 | invalid_values: [ "-5%", "0", "100", "0%", "50%", "100%", "220.3%" ] |
michael@0 | 1617 | }, |
michael@0 | 1618 | "transform": { |
michael@0 | 1619 | domProp: "transform", |
michael@0 | 1620 | inherited: false, |
michael@0 | 1621 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1622 | prerequisites: { "width": "300px", "height": "50px" }, |
michael@0 | 1623 | initial_values: [ "none" ], |
michael@0 | 1624 | other_values: [ "translatex(1px)", "translatex(4em)", |
michael@0 | 1625 | "translatex(-4px)", "translatex(3px)", |
michael@0 | 1626 | "translatex(0px) translatex(1px) translatex(2px) translatex(3px) translatex(4px)", |
michael@0 | 1627 | "translatey(4em)", "translate(3px)", "translate(10px, -3px)", |
michael@0 | 1628 | "rotate(45deg)", "rotate(45grad)", "rotate(45rad)", |
michael@0 | 1629 | "rotate(0.25turn)", "rotate(0)", "scalex(10)", "scaley(10)", |
michael@0 | 1630 | "scale(10)", "scale(10, 20)", "skewx(30deg)", "skewx(0)", |
michael@0 | 1631 | "skewy(0)", "skewx(30grad)", "skewx(30rad)", "skewx(0.08turn)", |
michael@0 | 1632 | "skewy(30deg)", "skewy(30grad)", "skewy(30rad)", "skewy(0.08turn)", |
michael@0 | 1633 | "rotate(45deg) scale(2, 1)", "skewx(45deg) skewx(-50grad)", |
michael@0 | 1634 | "translate(0, 0) scale(1, 1) skewx(0) skewy(0) matrix(1, 0, 0, 1, 0, 0)", |
michael@0 | 1635 | "translatex(50%)", "translatey(50%)", "translate(50%)", |
michael@0 | 1636 | "translate(3%, 5px)", "translate(5px, 3%)", |
michael@0 | 1637 | "matrix(1, 2, 3, 4, 5, 6)", |
michael@0 | 1638 | /* valid calc() values */ |
michael@0 | 1639 | "translatex(calc(5px + 10%))", |
michael@0 | 1640 | "translatey(calc(0.25 * 5px + 10% / 3))", |
michael@0 | 1641 | "translate(calc(5px - 10% * 3))", |
michael@0 | 1642 | "translate(calc(5px - 3 * 10%), 50px)", |
michael@0 | 1643 | "translate(-50px, calc(5px - 10% * 3))", |
michael@0 | 1644 | "translatez(1px)", "translatez(4em)", "translatez(-4px)", |
michael@0 | 1645 | "translatez(0px)", "translatez(2px) translatez(5px)", |
michael@0 | 1646 | "translate3d(3px, 4px, 5px)", "translate3d(2em, 3px, 1em)", |
michael@0 | 1647 | "translatex(2px) translate3d(4px, 5px, 6px) translatey(1px)", |
michael@0 | 1648 | "scale3d(4, 4, 4)", "scale3d(-2, 3, -7)", "scalez(4)", |
michael@0 | 1649 | "scalez(-6)", "rotate3d(2, 3, 4, 45deg)", |
michael@0 | 1650 | "rotate3d(-3, 7, 0, 12rad)", "rotatex(15deg)", "rotatey(-12grad)", |
michael@0 | 1651 | "rotatez(72rad)", "rotatex(0.125turn)", "perspective(1000px)", |
michael@0 | 1652 | "matrix3d(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16)", |
michael@0 | 1653 | ], |
michael@0 | 1654 | invalid_values: ["1px", "#0000ff", "red", "auto", |
michael@0 | 1655 | "translatex(1)", "translatey(1)", "translate(2)", |
michael@0 | 1656 | "translate(-3, -4)", |
michael@0 | 1657 | "translatex(1px 1px)", "translatex(translatex(1px))", |
michael@0 | 1658 | "translatex(#0000ff)", "translatex(red)", "translatey()", |
michael@0 | 1659 | "matrix(1px, 2px, 3px, 4px, 5px, 6px)", "scale(150%)", |
michael@0 | 1660 | "skewx(red)", "matrix(1%, 0, 0, 0, 0px, 0px)", |
michael@0 | 1661 | "matrix(0, 1%, 2, 3, 4px,5px)", "matrix(0, 1, 2%, 3, 4px, 5px)", |
michael@0 | 1662 | "matrix(0, 1, 2, 3%, 4%, 5%)", "matrix(1, 2, 3, 4, 5px, 6%)", |
michael@0 | 1663 | "matrix(1, 2, 3, 4, 5%, 6px)", "matrix(1, 2, 3, 4, 5%, 6%)", |
michael@0 | 1664 | "matrix(1, 2, 3, 4, 5px, 6em)", |
michael@0 | 1665 | /* invalid calc() values */ |
michael@0 | 1666 | "translatey(-moz-min(5px,10%))", |
michael@0 | 1667 | "translatex(-moz-max(5px,10%))", |
michael@0 | 1668 | "translate(10px, calc(min(5px,10%)))", |
michael@0 | 1669 | "translate(calc(max(5px,10%)), 10%)", |
michael@0 | 1670 | "matrix(1, 0, 0, 1, max(5px * 3), calc(10% - 3px))", |
michael@0 | 1671 | "perspective(0px)", "perspective(-10px)", "matrix3d(dinosaur)", |
michael@0 | 1672 | "matrix3d(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17)", |
michael@0 | 1673 | "matrix3d(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15)", |
michael@0 | 1674 | "matrix3d(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15%, 16)", |
michael@0 | 1675 | "matrix3d(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16px)", |
michael@0 | 1676 | "rotatey(words)", "rotatex(7)", "translate3d(3px, 4px, 1px, 7px)", |
michael@0 | 1677 | "matrix3d(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13px, 14em, 15px, 16)", |
michael@0 | 1678 | "matrix3d(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 20%, 10%, 15, 16)" |
michael@0 | 1679 | ], |
michael@0 | 1680 | }, |
michael@0 | 1681 | "transform-origin": { |
michael@0 | 1682 | domProp: "transformOrigin", |
michael@0 | 1683 | inherited: false, |
michael@0 | 1684 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1685 | /* no subproperties */ |
michael@0 | 1686 | prerequisites: { "width": "10px", "height": "10px", "display": "block"}, |
michael@0 | 1687 | initial_values: [ "50% 50%", "center", "center center" ], |
michael@0 | 1688 | other_values: [ "25% 25%", "6px 5px", "20% 3em", "0 0", "0in 1in", |
michael@0 | 1689 | "top", "bottom","top left", "top right", |
michael@0 | 1690 | "top center", "center left", "center right", |
michael@0 | 1691 | "bottom left", "bottom right", "bottom center", |
michael@0 | 1692 | "20% center", "6px center", "13in bottom", |
michael@0 | 1693 | "left 50px", "right 13%", "center 40px", |
michael@0 | 1694 | "calc(20px)", |
michael@0 | 1695 | "calc(20px) 10px", |
michael@0 | 1696 | "10px calc(20px)", |
michael@0 | 1697 | "calc(20px) 25%", |
michael@0 | 1698 | "25% calc(20px)", |
michael@0 | 1699 | "calc(20px) calc(20px)", |
michael@0 | 1700 | "calc(20px + 1em) calc(20px / 2)", |
michael@0 | 1701 | "calc(20px + 50%) calc(50% - 10px)", |
michael@0 | 1702 | "calc(-20px) calc(-50%)", |
michael@0 | 1703 | "calc(-20%) calc(-50%)", |
michael@0 | 1704 | "6px 5px 5px", |
michael@0 | 1705 | "top center 10px" |
michael@0 | 1706 | ], |
michael@0 | 1707 | invalid_values: ["red", "auto", "none", "0.5 0.5", "40px #0000ff", |
michael@0 | 1708 | "border", "center red", "right diagonal", |
michael@0 | 1709 | "#00ffff bottom"] |
michael@0 | 1710 | }, |
michael@0 | 1711 | "perspective-origin": { |
michael@0 | 1712 | domProp: "perspectiveOrigin", |
michael@0 | 1713 | inherited: false, |
michael@0 | 1714 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1715 | /* no subproperties */ |
michael@0 | 1716 | prerequisites: { "width": "10px", "height": "10px", "display": "block"}, |
michael@0 | 1717 | initial_values: [ "50% 50%", "center", "center center" ], |
michael@0 | 1718 | other_values: [ "25% 25%", "6px 5px", "20% 3em", "0 0", "0in 1in", |
michael@0 | 1719 | "top", "bottom","top left", "top right", |
michael@0 | 1720 | "top center", "center left", "center right", |
michael@0 | 1721 | "bottom left", "bottom right", "bottom center", |
michael@0 | 1722 | "20% center", "6px center", "13in bottom", |
michael@0 | 1723 | "left 50px", "right 13%", "center 40px", |
michael@0 | 1724 | "calc(20px)", |
michael@0 | 1725 | "calc(20px) 10px", |
michael@0 | 1726 | "10px calc(20px)", |
michael@0 | 1727 | "calc(20px) 25%", |
michael@0 | 1728 | "25% calc(20px)", |
michael@0 | 1729 | "calc(20px) calc(20px)", |
michael@0 | 1730 | "calc(20px + 1em) calc(20px / 2)", |
michael@0 | 1731 | "calc(20px + 50%) calc(50% - 10px)", |
michael@0 | 1732 | "calc(-20px) calc(-50%)", |
michael@0 | 1733 | "calc(-20%) calc(-50%)" ], |
michael@0 | 1734 | invalid_values: [ "red", "auto", "none", "0.5 0.5", "40px #0000ff", |
michael@0 | 1735 | "border", "center red", "right diagonal", |
michael@0 | 1736 | "#00ffff bottom"] |
michael@0 | 1737 | }, |
michael@0 | 1738 | "perspective": { |
michael@0 | 1739 | domProp: "perspective", |
michael@0 | 1740 | inherited: false, |
michael@0 | 1741 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1742 | initial_values: [ "none" ], |
michael@0 | 1743 | other_values: [ "1000px", "500.2px" ], |
michael@0 | 1744 | invalid_values: [ "pants", "200", "0", "-100px", "-27.2em", "0px" ] |
michael@0 | 1745 | }, |
michael@0 | 1746 | "backface-visibility": { |
michael@0 | 1747 | domProp: "backfaceVisibility", |
michael@0 | 1748 | inherited: false, |
michael@0 | 1749 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1750 | initial_values: [ "visible" ], |
michael@0 | 1751 | other_values: [ "hidden" ], |
michael@0 | 1752 | invalid_values: [ "collapse" ] |
michael@0 | 1753 | }, |
michael@0 | 1754 | "transform-style": { |
michael@0 | 1755 | domProp: "transformStyle", |
michael@0 | 1756 | inherited: false, |
michael@0 | 1757 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1758 | initial_values: [ "flat" ], |
michael@0 | 1759 | other_values: [ "preserve-3d" ], |
michael@0 | 1760 | invalid_values: [] |
michael@0 | 1761 | }, |
michael@0 | 1762 | "-moz-user-focus": { |
michael@0 | 1763 | domProp: "MozUserFocus", |
michael@0 | 1764 | inherited: true, |
michael@0 | 1765 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1766 | initial_values: [ "none" ], |
michael@0 | 1767 | other_values: [ "normal", "ignore", "select-all", "select-before", "select-after", "select-same", "select-menu" ], |
michael@0 | 1768 | invalid_values: [] |
michael@0 | 1769 | }, |
michael@0 | 1770 | "-moz-user-input": { |
michael@0 | 1771 | domProp: "MozUserInput", |
michael@0 | 1772 | inherited: true, |
michael@0 | 1773 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1774 | initial_values: [ "auto" ], |
michael@0 | 1775 | other_values: [ "none", "enabled", "disabled" ], |
michael@0 | 1776 | invalid_values: [] |
michael@0 | 1777 | }, |
michael@0 | 1778 | "-moz-user-modify": { |
michael@0 | 1779 | domProp: "MozUserModify", |
michael@0 | 1780 | inherited: true, |
michael@0 | 1781 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1782 | initial_values: [ "read-only" ], |
michael@0 | 1783 | other_values: [ "read-write", "write-only" ], |
michael@0 | 1784 | invalid_values: [] |
michael@0 | 1785 | }, |
michael@0 | 1786 | "-moz-user-select": { |
michael@0 | 1787 | domProp: "MozUserSelect", |
michael@0 | 1788 | inherited: false, |
michael@0 | 1789 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1790 | initial_values: [ "auto" ], |
michael@0 | 1791 | other_values: [ "none", "text", "element", "elements", "all", "toggle", "tri-state", "-moz-all", "-moz-none" ], |
michael@0 | 1792 | invalid_values: [] |
michael@0 | 1793 | }, |
michael@0 | 1794 | "-moz-window-shadow": { |
michael@0 | 1795 | domProp: "MozWindowShadow", |
michael@0 | 1796 | inherited: false, |
michael@0 | 1797 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1798 | initial_values: [ "default" ], |
michael@0 | 1799 | other_values: [ "none", "menu", "tooltip", "sheet" ], |
michael@0 | 1800 | invalid_values: [] |
michael@0 | 1801 | }, |
michael@0 | 1802 | "background": { |
michael@0 | 1803 | domProp: "background", |
michael@0 | 1804 | inherited: false, |
michael@0 | 1805 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 1806 | subproperties: [ "background-attachment", "background-color", "background-image", "background-position", "background-repeat", "background-clip", "background-origin", "background-size" ], |
michael@0 | 1807 | initial_values: [ "transparent", "none", "repeat", "scroll", "0% 0%", "top left", "left top", "0% 0% / auto", "top left / auto", "left top / auto", "0% 0% / auto auto", |
michael@0 | 1808 | "transparent none", "top left none", "left top none", "none left top", "none top left", "none 0% 0%", "left top / auto none", "left top / auto auto none", |
michael@0 | 1809 | "transparent none repeat scroll top left", "left top repeat none scroll transparent", "transparent none repeat scroll top left / auto", "left top / auto repeat none scroll transparent", "none repeat scroll 0% 0% / auto auto transparent" ], |
michael@0 | 1810 | other_values: [ |
michael@0 | 1811 | /* without multiple backgrounds */ |
michael@0 | 1812 | "green", |
michael@0 | 1813 | "none green repeat scroll left top", |
michael@0 | 1814 | "url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==)", |
michael@0 | 1815 | "repeat url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==') transparent left top scroll", |
michael@0 | 1816 | "repeat-x", |
michael@0 | 1817 | "repeat-y", |
michael@0 | 1818 | "no-repeat", |
michael@0 | 1819 | "none repeat-y transparent scroll 0% 0%", |
michael@0 | 1820 | "fixed", |
michael@0 | 1821 | "0% top transparent fixed repeat none", |
michael@0 | 1822 | "top", |
michael@0 | 1823 | "left", |
michael@0 | 1824 | "50% 50%", |
michael@0 | 1825 | "center", |
michael@0 | 1826 | "top / 100px", |
michael@0 | 1827 | "left / contain", |
michael@0 | 1828 | "left / cover", |
michael@0 | 1829 | "10px / 10%", |
michael@0 | 1830 | "10em / calc(20px)", |
michael@0 | 1831 | "top left / 100px 100px", |
michael@0 | 1832 | "top left / 100px auto", |
michael@0 | 1833 | "top left / 100px 10%", |
michael@0 | 1834 | "top left / 100px calc(20px)", |
michael@0 | 1835 | "bottom right scroll none transparent repeat", |
michael@0 | 1836 | "50% transparent", |
michael@0 | 1837 | "transparent 50%", |
michael@0 | 1838 | "50%", |
michael@0 | 1839 | "-moz-radial-gradient(10% bottom, #ffffff, black) scroll no-repeat", |
michael@0 | 1840 | "-moz-linear-gradient(10px 10px -45deg, red, blue) repeat", |
michael@0 | 1841 | "-moz-linear-gradient(10px 10px -0.125turn, red, blue) repeat", |
michael@0 | 1842 | "-moz-repeating-radial-gradient(10% bottom, #ffffff, black) scroll no-repeat", |
michael@0 | 1843 | "-moz-repeating-linear-gradient(10px 10px -45deg, red, blue) repeat", |
michael@0 | 1844 | "-moz-element(#test) lime", |
michael@0 | 1845 | /* multiple backgrounds */ |
michael@0 | 1846 | "url(404.png), url(404.png)", |
michael@0 | 1847 | "url(404.png), url(404.png) transparent", |
michael@0 | 1848 | "url(404.png), url(404.png) red", |
michael@0 | 1849 | "repeat-x, fixed, none", |
michael@0 | 1850 | "0% top url(404.png), url(404.png) 0% top", |
michael@0 | 1851 | "fixed repeat-y top left url(404.png), repeat-x green", |
michael@0 | 1852 | "url(404.png), -moz-linear-gradient(20px 20px -45deg, blue, green), -moz-element(#a) black", |
michael@0 | 1853 | "top left / contain, bottom right / cover", |
michael@0 | 1854 | /* test cases with clip+origin in the shorthand */ |
michael@0 | 1855 | "url(404.png) green padding-box", |
michael@0 | 1856 | "url(404.png) border-box transparent", |
michael@0 | 1857 | "content-box url(404.png) blue", |
michael@0 | 1858 | "url(404.png) green padding-box padding-box", |
michael@0 | 1859 | "url(404.png) green padding-box border-box", |
michael@0 | 1860 | "content-box border-box url(404.png) blue", |
michael@0 | 1861 | ], |
michael@0 | 1862 | invalid_values: [ |
michael@0 | 1863 | /* mixes with keywords have to be in correct order */ |
michael@0 | 1864 | "50% left", "top 50%", |
michael@0 | 1865 | /* no quirks mode colors */ |
michael@0 | 1866 | "-moz-radial-gradient(10% bottom, ffffff, black) scroll no-repeat", |
michael@0 | 1867 | /* no quirks mode lengths */ |
michael@0 | 1868 | "-moz-linear-gradient(10 10px -45deg, red, blue) repeat", |
michael@0 | 1869 | "-moz-linear-gradient(10px 10 -45deg, red, blue) repeat", |
michael@0 | 1870 | "linear-gradient(red -99, yellow, green, blue 120%)", |
michael@0 | 1871 | /* bug 258080: don't accept background-position separated */ |
michael@0 | 1872 | "left url(404.png) top", "top url(404.png) left", |
michael@0 | 1873 | /* not allowed to have color in non-bottom layer */ |
michael@0 | 1874 | "url(404.png) transparent, url(404.png)", |
michael@0 | 1875 | "url(404.png) red, url(404.png)", |
michael@0 | 1876 | "url(404.png) transparent, url(404.png) transparent", |
michael@0 | 1877 | "url(404.png) transparent red, url(404.png) transparent red", |
michael@0 | 1878 | "url(404.png) red, url(404.png) red", |
michael@0 | 1879 | "url(404.png) rgba(0, 0, 0, 0), url(404.png)", |
michael@0 | 1880 | "url(404.png) rgb(255, 0, 0), url(404.png)", |
michael@0 | 1881 | "url(404.png) rgba(0, 0, 0, 0), url(404.png) rgba(0, 0, 0, 0)", |
michael@0 | 1882 | "url(404.png) rgba(0, 0, 0, 0) rgb(255, 0, 0), url(404.png) rgba(0, 0, 0, 0) rgb(255, 0, 0)", |
michael@0 | 1883 | "url(404.png) rgb(255, 0, 0), url(404.png) rgb(255, 0, 0)", |
michael@0 | 1884 | /* bug 513395: old syntax for gradients */ |
michael@0 | 1885 | "-moz-radial-gradient(10% bottom, 30px, 20px 20px, 10px, from(#ffffff), to(black)) scroll no-repeat", |
michael@0 | 1886 | "-moz-linear-gradient(10px 10px, 20px 20px, from(red), to(blue)) repeat", |
michael@0 | 1887 | /* clip and origin separated in the shorthand */ |
michael@0 | 1888 | "url(404.png) padding-box green border-box", |
michael@0 | 1889 | "url(404.png) padding-box green padding-box", |
michael@0 | 1890 | "transparent padding-box url(404.png) border-box", |
michael@0 | 1891 | "transparent padding-box url(404.png) padding-box", |
michael@0 | 1892 | ] |
michael@0 | 1893 | }, |
michael@0 | 1894 | "background-attachment": { |
michael@0 | 1895 | domProp: "backgroundAttachment", |
michael@0 | 1896 | inherited: false, |
michael@0 | 1897 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1898 | initial_values: [ "scroll" ], |
michael@0 | 1899 | other_values: [ "fixed", "local", "scroll,scroll", "fixed, scroll", "scroll, fixed, local, scroll", "fixed, fixed" ], |
michael@0 | 1900 | invalid_values: [] |
michael@0 | 1901 | }, |
michael@0 | 1902 | "background-clip": { |
michael@0 | 1903 | /* |
michael@0 | 1904 | * When we rename this to 'background-clip', we also |
michael@0 | 1905 | * need to rename the values to match the spec. |
michael@0 | 1906 | */ |
michael@0 | 1907 | domProp: "backgroundClip", |
michael@0 | 1908 | inherited: false, |
michael@0 | 1909 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1910 | initial_values: [ "border-box" ], |
michael@0 | 1911 | other_values: [ "content-box", "padding-box", "border-box, padding-box", "padding-box, padding-box, padding-box", "border-box, border-box" ], |
michael@0 | 1912 | invalid_values: [ "margin-box", "border-box border-box" ] |
michael@0 | 1913 | }, |
michael@0 | 1914 | "background-color": { |
michael@0 | 1915 | domProp: "backgroundColor", |
michael@0 | 1916 | inherited: false, |
michael@0 | 1917 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1918 | initial_values: [ "transparent", "rgba(255, 127, 15, 0)", "hsla(240, 97%, 50%, 0.0)", "rgba(0, 0, 0, 0)", "rgba(255,255,255,-3.7)" ], |
michael@0 | 1919 | other_values: [ "green", "rgb(255, 0, 128)", "#fc2", "#96ed2a", "black", "rgba(255,255,0,3)", "hsl(240, 50%, 50%)", "rgb(50%, 50%, 50%)", "-moz-default-background-color" ], |
michael@0 | 1920 | invalid_values: [ "#0", "#00", "#0000", "#00000", "#0000000", "#00000000", "#000000000", "rgb(100, 100.0, 100)" ], |
michael@0 | 1921 | quirks_values: { "000000": "#000000", "96ed2a": "#96ed2a" }, |
michael@0 | 1922 | }, |
michael@0 | 1923 | "background-image": { |
michael@0 | 1924 | domProp: "backgroundImage", |
michael@0 | 1925 | inherited: false, |
michael@0 | 1926 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1927 | initial_values: [ "none" ], |
michael@0 | 1928 | other_values: [ |
michael@0 | 1929 | "url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==)", "url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==')", 'url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==")', |
michael@0 | 1930 | "none, none", |
michael@0 | 1931 | "none, none, none, none, none", |
michael@0 | 1932 | "url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==), none", |
michael@0 | 1933 | "none, url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==), none", |
michael@0 | 1934 | "url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==), url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==)", |
michael@0 | 1935 | ].concat(validGradientAndElementValues), |
michael@0 | 1936 | invalid_values: [ |
michael@0 | 1937 | ].concat(invalidGradientAndElementValues), |
michael@0 | 1938 | unbalanced_values: [ |
michael@0 | 1939 | ].concat(unbalancedGradientAndElementValues) |
michael@0 | 1940 | }, |
michael@0 | 1941 | "background-origin": { |
michael@0 | 1942 | domProp: "backgroundOrigin", |
michael@0 | 1943 | inherited: false, |
michael@0 | 1944 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1945 | initial_values: [ "padding-box" ], |
michael@0 | 1946 | other_values: [ "border-box", "content-box", "border-box, padding-box", "padding-box, padding-box, padding-box", "border-box, border-box" ], |
michael@0 | 1947 | invalid_values: [ "margin-box", "padding-box padding-box" ] |
michael@0 | 1948 | }, |
michael@0 | 1949 | "background-position": { |
michael@0 | 1950 | domProp: "backgroundPosition", |
michael@0 | 1951 | inherited: false, |
michael@0 | 1952 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1953 | initial_values: [ "top 0% left 0%", "top 0% left", "top left", "left top", "0% 0%", "0% top", "left 0%" ], |
michael@0 | 1954 | other_values: [ "top", "left", "right", "bottom", "center", "center bottom", "bottom center", "center right", "right center", "center top", "top center", "center left", "left center", "right bottom", "bottom right", "50%", "top left, top left", "top left, top right", "top right, top left", "left top, 0% 0%", "10% 20%, 30%, 40%", "top left, bottom right", "right bottom, left top", "0%", "0px", "30px", "0%, 10%, 20%, 30%", "top, top, top, top, top", |
michael@0 | 1955 | "calc(20px)", |
michael@0 | 1956 | "calc(20px) 10px", |
michael@0 | 1957 | "10px calc(20px)", |
michael@0 | 1958 | "calc(20px) 25%", |
michael@0 | 1959 | "25% calc(20px)", |
michael@0 | 1960 | "calc(20px) calc(20px)", |
michael@0 | 1961 | "calc(20px + 1em) calc(20px / 2)", |
michael@0 | 1962 | "calc(20px + 50%) calc(50% - 10px)", |
michael@0 | 1963 | "calc(-20px) calc(-50%)", |
michael@0 | 1964 | "calc(-20%) calc(-50%)", |
michael@0 | 1965 | "0px 0px", |
michael@0 | 1966 | "right 20px top 60px", |
michael@0 | 1967 | "right 20px bottom 60px", |
michael@0 | 1968 | "left 20px top 60px", |
michael@0 | 1969 | "left 20px bottom 60px", |
michael@0 | 1970 | "right -50px top -50px", |
michael@0 | 1971 | "left -50px bottom -50px", |
michael@0 | 1972 | "right 20px top -50px", |
michael@0 | 1973 | "right -20px top 50px", |
michael@0 | 1974 | "right 3em bottom 10px", |
michael@0 | 1975 | "bottom 3em right 10px", |
michael@0 | 1976 | "top 3em right 10px", |
michael@0 | 1977 | "left 15px", |
michael@0 | 1978 | "10px top", |
michael@0 | 1979 | "left top 15px", |
michael@0 | 1980 | "left 10px top", |
michael@0 | 1981 | "left 20%", |
michael@0 | 1982 | "right 20%" |
michael@0 | 1983 | ], |
michael@0 | 1984 | invalid_values: [ "center 10px center 4px", "center 10px center", |
michael@0 | 1985 | "top 20%", "bottom 20%", "50% left", "top 50%", |
michael@0 | 1986 | "50% bottom 10%", "right 10% 50%", "left right", |
michael@0 | 1987 | "top bottom", "left 10% right", |
michael@0 | 1988 | "top 20px bottom 20px", "left left", "20 20" ] |
michael@0 | 1989 | }, |
michael@0 | 1990 | "background-repeat": { |
michael@0 | 1991 | domProp: "backgroundRepeat", |
michael@0 | 1992 | inherited: false, |
michael@0 | 1993 | type: CSS_TYPE_LONGHAND, |
michael@0 | 1994 | initial_values: [ "repeat", "repeat repeat" ], |
michael@0 | 1995 | other_values: [ "repeat-x", "repeat-y", "no-repeat", |
michael@0 | 1996 | "repeat-x, repeat-x", |
michael@0 | 1997 | "repeat, no-repeat", |
michael@0 | 1998 | "repeat-y, no-repeat, repeat-y", |
michael@0 | 1999 | "repeat, repeat, repeat", |
michael@0 | 2000 | "repeat no-repeat", |
michael@0 | 2001 | "no-repeat repeat", |
michael@0 | 2002 | "no-repeat no-repeat", |
michael@0 | 2003 | "repeat repeat, repeat repeat", |
michael@0 | 2004 | ], |
michael@0 | 2005 | invalid_values: [ "repeat repeat repeat", |
michael@0 | 2006 | "repeat-x repeat-y", |
michael@0 | 2007 | "repeat repeat-x", |
michael@0 | 2008 | "repeat repeat-y", |
michael@0 | 2009 | "repeat-x repeat", |
michael@0 | 2010 | "repeat-y repeat" ] |
michael@0 | 2011 | }, |
michael@0 | 2012 | "background-size": { |
michael@0 | 2013 | domProp: "backgroundSize", |
michael@0 | 2014 | inherited: false, |
michael@0 | 2015 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2016 | initial_values: [ "auto", "auto auto" ], |
michael@0 | 2017 | other_values: [ "contain", "cover", "100px auto", "auto 100px", "100% auto", "auto 100%", "25% 50px", "3em 40%", |
michael@0 | 2018 | "calc(20px)", |
michael@0 | 2019 | "calc(20px) 10px", |
michael@0 | 2020 | "10px calc(20px)", |
michael@0 | 2021 | "calc(20px) 25%", |
michael@0 | 2022 | "25% calc(20px)", |
michael@0 | 2023 | "calc(20px) calc(20px)", |
michael@0 | 2024 | "calc(20px + 1em) calc(20px / 2)", |
michael@0 | 2025 | "calc(20px + 50%) calc(50% - 10px)", |
michael@0 | 2026 | "calc(-20px) calc(-50%)", |
michael@0 | 2027 | "calc(-20%) calc(-50%)" |
michael@0 | 2028 | ], |
michael@0 | 2029 | invalid_values: [ "contain contain", "cover cover", "cover auto", "auto cover", "contain cover", "cover contain", "-5px 3px", "3px -5px", "auto -5px", "-5px auto", "5 3" ] |
michael@0 | 2030 | }, |
michael@0 | 2031 | "border": { |
michael@0 | 2032 | domProp: "border", |
michael@0 | 2033 | inherited: false, |
michael@0 | 2034 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 2035 | subproperties: [ "border-bottom-color", "border-bottom-style", "border-bottom-width", "border-left-color", "border-left-style", "border-left-width", "border-right-color", "border-right-style", "border-right-width", "border-top-color", "border-top-style", "border-top-width", "-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" ], |
michael@0 | 2036 | initial_values: [ "none", "medium", "currentColor", "thin", "none medium currentcolor", "calc(4px - 1px) none" ], |
michael@0 | 2037 | other_values: [ "solid", "medium solid", "green solid", "10px solid", "thick solid", "calc(2px) solid blue" ], |
michael@0 | 2038 | invalid_values: [ "5%", "medium solid ff00ff", "5 solid green" ] |
michael@0 | 2039 | }, |
michael@0 | 2040 | "border-bottom": { |
michael@0 | 2041 | domProp: "borderBottom", |
michael@0 | 2042 | inherited: false, |
michael@0 | 2043 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 2044 | subproperties: [ "border-bottom-color", "border-bottom-style", "border-bottom-width" ], |
michael@0 | 2045 | initial_values: [ "none", "medium", "currentColor", "thin", "none medium currentcolor" ], |
michael@0 | 2046 | other_values: [ "solid", "green", "medium solid", "green solid", "10px solid", "thick solid", "5px green none" ], |
michael@0 | 2047 | invalid_values: [ "5%", "5", "5 solid green" ] |
michael@0 | 2048 | }, |
michael@0 | 2049 | "border-bottom-color": { |
michael@0 | 2050 | domProp: "borderBottomColor", |
michael@0 | 2051 | inherited: false, |
michael@0 | 2052 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2053 | prerequisites: { "color": "black" }, |
michael@0 | 2054 | initial_values: [ "currentColor", "-moz-use-text-color" ], |
michael@0 | 2055 | other_values: [ "green", "rgba(255,128,0,0.5)", "transparent" ], |
michael@0 | 2056 | invalid_values: [ "#0", "#00", "#0000", "#00000", "#0000000", "#00000000", "#000000000" ], |
michael@0 | 2057 | quirks_values: { "000000": "#000000", "96ed2a": "#96ed2a" }, |
michael@0 | 2058 | }, |
michael@0 | 2059 | "border-bottom-style": { |
michael@0 | 2060 | domProp: "borderBottomStyle", |
michael@0 | 2061 | inherited: false, |
michael@0 | 2062 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2063 | /* XXX hidden is sometimes the same as initial */ |
michael@0 | 2064 | initial_values: [ "none" ], |
michael@0 | 2065 | other_values: [ "solid", "dashed", "dotted", "double", "outset", "inset", "groove", "ridge" ], |
michael@0 | 2066 | invalid_values: [] |
michael@0 | 2067 | }, |
michael@0 | 2068 | "border-bottom-width": { |
michael@0 | 2069 | domProp: "borderBottomWidth", |
michael@0 | 2070 | inherited: false, |
michael@0 | 2071 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2072 | prerequisites: { "border-bottom-style": "solid" }, |
michael@0 | 2073 | initial_values: [ "medium", "3px", "calc(4px - 1px)" ], |
michael@0 | 2074 | other_values: [ "thin", "thick", "1px", "2em", |
michael@0 | 2075 | "calc(2px)", |
michael@0 | 2076 | "calc(-2px)", |
michael@0 | 2077 | "calc(0em)", |
michael@0 | 2078 | "calc(0px)", |
michael@0 | 2079 | "calc(5em)", |
michael@0 | 2080 | "calc(3*25px)", |
michael@0 | 2081 | "calc(25px*3)", |
michael@0 | 2082 | "calc(3*25px + 5em)", |
michael@0 | 2083 | ], |
michael@0 | 2084 | invalid_values: [ "5%" ], |
michael@0 | 2085 | quirks_values: { "5": "5px" }, |
michael@0 | 2086 | }, |
michael@0 | 2087 | "border-collapse": { |
michael@0 | 2088 | domProp: "borderCollapse", |
michael@0 | 2089 | inherited: true, |
michael@0 | 2090 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2091 | initial_values: [ "separate" ], |
michael@0 | 2092 | other_values: [ "collapse" ], |
michael@0 | 2093 | invalid_values: [] |
michael@0 | 2094 | }, |
michael@0 | 2095 | "border-color": { |
michael@0 | 2096 | domProp: "borderColor", |
michael@0 | 2097 | inherited: false, |
michael@0 | 2098 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 2099 | subproperties: [ "border-top-color", "border-right-color", "border-bottom-color", "border-left-color" ], |
michael@0 | 2100 | initial_values: [ "currentColor", "currentColor currentColor", "currentColor currentColor currentColor", "currentColor currentColor currentcolor CURRENTcolor" ], |
michael@0 | 2101 | other_values: [ "green", "currentColor green", "currentColor currentColor green", "currentColor currentColor currentColor green", "rgba(255,128,0,0.5)", "transparent" ], |
michael@0 | 2102 | invalid_values: [ "#0", "#00", "#0000", "#00000", "#0000000", "#00000000", "#000000000" ], |
michael@0 | 2103 | quirks_values: { "000000": "#000000", "96ed2a": "#96ed2a" }, |
michael@0 | 2104 | }, |
michael@0 | 2105 | "border-left": { |
michael@0 | 2106 | domProp: "borderLeft", |
michael@0 | 2107 | inherited: false, |
michael@0 | 2108 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 2109 | subproperties: [ "border-left-color", "border-left-style", "border-left-width" ], |
michael@0 | 2110 | initial_values: [ "none", "medium", "currentColor", "thin", "none medium currentcolor" ], |
michael@0 | 2111 | other_values: [ "solid", "green", "medium solid", "green solid", "10px solid", "thick solid", "5px green none" ], |
michael@0 | 2112 | invalid_values: [ "5%", "5", "5 solid green" ] |
michael@0 | 2113 | }, |
michael@0 | 2114 | "border-left-color": { |
michael@0 | 2115 | domProp: "borderLeftColor", |
michael@0 | 2116 | inherited: false, |
michael@0 | 2117 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 2118 | prerequisites: { "color": "black" }, |
michael@0 | 2119 | initial_values: [ "currentColor", "-moz-use-text-color" ], |
michael@0 | 2120 | other_values: [ "green", "rgba(255,128,0,0.5)", "transparent" ], |
michael@0 | 2121 | invalid_values: [ "#0", "#00", "#0000", "#00000", "#0000000", "#00000000", "#000000000" ], |
michael@0 | 2122 | quirks_values: { "000000": "#000000", "96ed2a": "#96ed2a" }, |
michael@0 | 2123 | }, |
michael@0 | 2124 | "border-left-style": { |
michael@0 | 2125 | domProp: "borderLeftStyle", |
michael@0 | 2126 | inherited: false, |
michael@0 | 2127 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 2128 | /* XXX hidden is sometimes the same as initial */ |
michael@0 | 2129 | initial_values: [ "none" ], |
michael@0 | 2130 | other_values: [ "solid", "dashed", "dotted", "double", "outset", "inset", "groove", "ridge" ], |
michael@0 | 2131 | invalid_values: [] |
michael@0 | 2132 | }, |
michael@0 | 2133 | "border-left-width": { |
michael@0 | 2134 | domProp: "borderLeftWidth", |
michael@0 | 2135 | inherited: false, |
michael@0 | 2136 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 2137 | prerequisites: { "border-left-style": "solid" }, |
michael@0 | 2138 | initial_values: [ "medium", "3px", "calc(4px - 1px)" ], |
michael@0 | 2139 | other_values: [ "thin", "thick", "1px", "2em", |
michael@0 | 2140 | "calc(2px)", |
michael@0 | 2141 | "calc(-2px)", |
michael@0 | 2142 | "calc(0em)", |
michael@0 | 2143 | "calc(0px)", |
michael@0 | 2144 | "calc(5em)", |
michael@0 | 2145 | "calc(3*25px)", |
michael@0 | 2146 | "calc(25px*3)", |
michael@0 | 2147 | "calc(3*25px + 5em)", |
michael@0 | 2148 | ], |
michael@0 | 2149 | invalid_values: [ "5%" ], |
michael@0 | 2150 | quirks_values: { "5": "5px" }, |
michael@0 | 2151 | }, |
michael@0 | 2152 | "border-right": { |
michael@0 | 2153 | domProp: "borderRight", |
michael@0 | 2154 | inherited: false, |
michael@0 | 2155 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 2156 | subproperties: [ "border-right-color", "border-right-style", "border-right-width" ], |
michael@0 | 2157 | initial_values: [ "none", "medium", "currentColor", "thin", "none medium currentcolor" ], |
michael@0 | 2158 | other_values: [ "solid", "green", "medium solid", "green solid", "10px solid", "thick solid", "5px green none" ], |
michael@0 | 2159 | invalid_values: [ "5%", "5", "5 solid green" ] |
michael@0 | 2160 | }, |
michael@0 | 2161 | "border-right-color": { |
michael@0 | 2162 | domProp: "borderRightColor", |
michael@0 | 2163 | inherited: false, |
michael@0 | 2164 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 2165 | prerequisites: { "color": "black" }, |
michael@0 | 2166 | initial_values: [ "currentColor", "-moz-use-text-color" ], |
michael@0 | 2167 | other_values: [ "green", "rgba(255,128,0,0.5)", "transparent" ], |
michael@0 | 2168 | invalid_values: [ "#0", "#00", "#0000", "#00000", "#0000000", "#00000000", "#000000000" ], |
michael@0 | 2169 | quirks_values: { "000000": "#000000", "96ed2a": "#96ed2a" }, |
michael@0 | 2170 | }, |
michael@0 | 2171 | "border-right-style": { |
michael@0 | 2172 | domProp: "borderRightStyle", |
michael@0 | 2173 | inherited: false, |
michael@0 | 2174 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 2175 | /* XXX hidden is sometimes the same as initial */ |
michael@0 | 2176 | initial_values: [ "none" ], |
michael@0 | 2177 | other_values: [ "solid", "dashed", "dotted", "double", "outset", "inset", "groove", "ridge" ], |
michael@0 | 2178 | invalid_values: [] |
michael@0 | 2179 | }, |
michael@0 | 2180 | "border-right-width": { |
michael@0 | 2181 | domProp: "borderRightWidth", |
michael@0 | 2182 | inherited: false, |
michael@0 | 2183 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 2184 | prerequisites: { "border-right-style": "solid" }, |
michael@0 | 2185 | initial_values: [ "medium", "3px", "calc(4px - 1px)" ], |
michael@0 | 2186 | other_values: [ "thin", "thick", "1px", "2em", |
michael@0 | 2187 | "calc(2px)", |
michael@0 | 2188 | "calc(-2px)", |
michael@0 | 2189 | "calc(0em)", |
michael@0 | 2190 | "calc(0px)", |
michael@0 | 2191 | "calc(5em)", |
michael@0 | 2192 | "calc(3*25px)", |
michael@0 | 2193 | "calc(25px*3)", |
michael@0 | 2194 | "calc(3*25px + 5em)", |
michael@0 | 2195 | ], |
michael@0 | 2196 | invalid_values: [ "5%" ], |
michael@0 | 2197 | quirks_values: { "5": "5px" }, |
michael@0 | 2198 | }, |
michael@0 | 2199 | "border-spacing": { |
michael@0 | 2200 | domProp: "borderSpacing", |
michael@0 | 2201 | inherited: true, |
michael@0 | 2202 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2203 | initial_values: [ "0", "0 0", "0px", "0 0px", "calc(0px)", "calc(0px) calc(0em)", "calc(2em - 2em) calc(3px + 7px - 10px)", "calc(-5px)", "calc(-5px) calc(-5px)" ], |
michael@0 | 2204 | other_values: [ "3px", "4em 2px", "4em 0", "0px 2px", "calc(7px)", "0 calc(7px)", "calc(7px) 0", "calc(0px) calc(7px)", "calc(7px) calc(0px)", "7px calc(0px)", "calc(0px) 7px", "7px calc(0px)", "3px calc(2em)" ], |
michael@0 | 2205 | invalid_values: [ "0%", "0 0%", "-5px", "-5px -5px", "0 -5px", "-5px 0" ] |
michael@0 | 2206 | }, |
michael@0 | 2207 | "border-style": { |
michael@0 | 2208 | domProp: "borderStyle", |
michael@0 | 2209 | inherited: false, |
michael@0 | 2210 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 2211 | subproperties: [ "border-top-style", "border-right-style", "border-bottom-style", "border-left-style" ], |
michael@0 | 2212 | /* XXX hidden is sometimes the same as initial */ |
michael@0 | 2213 | initial_values: [ "none", "none none", "none none none", "none none none none" ], |
michael@0 | 2214 | other_values: [ "solid", "dashed", "dotted", "double", "outset", "inset", "groove", "ridge", "none solid", "none none solid", "none none none solid", "groove none none none", "none ridge none none", "none none double none", "none none none dotted" ], |
michael@0 | 2215 | invalid_values: [] |
michael@0 | 2216 | }, |
michael@0 | 2217 | "border-top": { |
michael@0 | 2218 | domProp: "borderTop", |
michael@0 | 2219 | inherited: false, |
michael@0 | 2220 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 2221 | subproperties: [ "border-top-color", "border-top-style", "border-top-width" ], |
michael@0 | 2222 | initial_values: [ "none", "medium", "currentColor", "thin", "none medium currentcolor" ], |
michael@0 | 2223 | other_values: [ "solid", "green", "medium solid", "green solid", "10px solid", "thick solid", "5px green none" ], |
michael@0 | 2224 | invalid_values: [ "5%", "5", "5 solid green" ] |
michael@0 | 2225 | }, |
michael@0 | 2226 | "border-top-color": { |
michael@0 | 2227 | domProp: "borderTopColor", |
michael@0 | 2228 | inherited: false, |
michael@0 | 2229 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2230 | prerequisites: { "color": "black" }, |
michael@0 | 2231 | initial_values: [ "currentColor", "-moz-use-text-color" ], |
michael@0 | 2232 | other_values: [ "green", "rgba(255,128,0,0.5)", "transparent" ], |
michael@0 | 2233 | invalid_values: [ "#0", "#00", "#0000", "#00000", "#0000000", "#00000000", "#000000000" ], |
michael@0 | 2234 | quirks_values: { "000000": "#000000", "96ed2a": "#96ed2a" }, |
michael@0 | 2235 | }, |
michael@0 | 2236 | "border-top-style": { |
michael@0 | 2237 | domProp: "borderTopStyle", |
michael@0 | 2238 | inherited: false, |
michael@0 | 2239 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2240 | /* XXX hidden is sometimes the same as initial */ |
michael@0 | 2241 | initial_values: [ "none" ], |
michael@0 | 2242 | other_values: [ "solid", "dashed", "dotted", "double", "outset", "inset", "groove", "ridge" ], |
michael@0 | 2243 | invalid_values: [] |
michael@0 | 2244 | }, |
michael@0 | 2245 | "border-top-width": { |
michael@0 | 2246 | domProp: "borderTopWidth", |
michael@0 | 2247 | inherited: false, |
michael@0 | 2248 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2249 | prerequisites: { "border-top-style": "solid" }, |
michael@0 | 2250 | initial_values: [ "medium", "3px", "calc(4px - 1px)" ], |
michael@0 | 2251 | other_values: [ "thin", "thick", "1px", "2em", |
michael@0 | 2252 | "calc(2px)", |
michael@0 | 2253 | "calc(-2px)", |
michael@0 | 2254 | "calc(0em)", |
michael@0 | 2255 | "calc(0px)", |
michael@0 | 2256 | "calc(5em)", |
michael@0 | 2257 | "calc(3*25px)", |
michael@0 | 2258 | "calc(25px*3)", |
michael@0 | 2259 | "calc(3*25px + 5em)", |
michael@0 | 2260 | ], |
michael@0 | 2261 | invalid_values: [ "5%" ], |
michael@0 | 2262 | quirks_values: { "5": "5px" }, |
michael@0 | 2263 | }, |
michael@0 | 2264 | "border-width": { |
michael@0 | 2265 | domProp: "borderWidth", |
michael@0 | 2266 | inherited: false, |
michael@0 | 2267 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 2268 | subproperties: [ "border-top-width", "border-right-width", "border-bottom-width", "border-left-width" ], |
michael@0 | 2269 | prerequisites: { "border-style": "solid" }, |
michael@0 | 2270 | initial_values: [ "medium", "3px", "medium medium", "3px medium medium", "medium 3px medium medium", "calc(3px) 3px calc(5px - 2px) calc(2px - -1px)" ], |
michael@0 | 2271 | other_values: [ "thin", "thick", "1px", "2em", "2px 0 0px 1em", "calc(2em)" ], |
michael@0 | 2272 | invalid_values: [ "5%" ], |
michael@0 | 2273 | quirks_values: { "5": "5px" }, |
michael@0 | 2274 | }, |
michael@0 | 2275 | "bottom": { |
michael@0 | 2276 | domProp: "bottom", |
michael@0 | 2277 | inherited: false, |
michael@0 | 2278 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2279 | /* FIXME: run tests with multiple prerequisites */ |
michael@0 | 2280 | prerequisites: { "position": "relative" }, |
michael@0 | 2281 | /* XXX 0 may or may not be equal to auto */ |
michael@0 | 2282 | initial_values: [ "auto" ], |
michael@0 | 2283 | other_values: [ "32px", "-3em", "12%", |
michael@0 | 2284 | "calc(2px)", |
michael@0 | 2285 | "calc(-2px)", |
michael@0 | 2286 | "calc(50%)", |
michael@0 | 2287 | "calc(3*25px)", |
michael@0 | 2288 | "calc(25px*3)", |
michael@0 | 2289 | "calc(3*25px + 50%)", |
michael@0 | 2290 | ], |
michael@0 | 2291 | invalid_values: [], |
michael@0 | 2292 | quirks_values: { "5": "5px" }, |
michael@0 | 2293 | }, |
michael@0 | 2294 | "box-shadow": { |
michael@0 | 2295 | domProp: "boxShadow", |
michael@0 | 2296 | inherited: false, |
michael@0 | 2297 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2298 | initial_values: [ "none" ], |
michael@0 | 2299 | prerequisites: { "color": "blue" }, |
michael@0 | 2300 | other_values: [ "2px 2px", "2px 2px 1px", "2px 2px 2px 2px", "blue 3px 2px", "2px 2px 1px 5px green", "2px 2px red", "green 2px 2px 1px", "green 2px 2px, blue 1px 3px 4px", "currentColor 3px 3px", "blue 2px 2px, currentColor 1px 2px, 1px 2px 3px 2px orange", "3px 0 0 0", "inset 2px 2px 3px 4px black", "2px -2px green inset, 4px 4px 3px blue, inset 2px 2px", |
michael@0 | 2301 | /* calc() values */ |
michael@0 | 2302 | "2px 2px calc(-5px)", /* clamped */ |
michael@0 | 2303 | "calc(3em - 2px) 2px green", |
michael@0 | 2304 | "green calc(3em - 2px) 2px", |
michael@0 | 2305 | "2px calc(2px + 0.2em)", |
michael@0 | 2306 | "blue 2px calc(2px + 0.2em)", |
michael@0 | 2307 | "2px calc(2px + 0.2em) blue", |
michael@0 | 2308 | "calc(-2px) calc(-2px)", |
michael@0 | 2309 | "-2px -2px", |
michael@0 | 2310 | "calc(2px) calc(2px)", |
michael@0 | 2311 | "calc(2px) calc(2px) calc(2px)", |
michael@0 | 2312 | "calc(2px) calc(2px) calc(2px) calc(2px)" |
michael@0 | 2313 | ], |
michael@0 | 2314 | invalid_values: [ "3% 3%", "1px 1px 1px 1px 1px", "2px 2px, none", "red 2px 2px blue", "inherit, 2px 2px", "2px 2px, inherit", "2px 2px -5px", "inset 4px 4px black inset", "inset inherit", "inset none", "3 3", "3px 3", "3 3px", "3px 3px 3", "3px 3px 3px 3" ] |
michael@0 | 2315 | }, |
michael@0 | 2316 | "caption-side": { |
michael@0 | 2317 | domProp: "captionSide", |
michael@0 | 2318 | inherited: true, |
michael@0 | 2319 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2320 | initial_values: [ "top" ], |
michael@0 | 2321 | other_values: [ "right", "left", "bottom", "top-outside", "bottom-outside" ], |
michael@0 | 2322 | invalid_values: [] |
michael@0 | 2323 | }, |
michael@0 | 2324 | "clear": { |
michael@0 | 2325 | domProp: "clear", |
michael@0 | 2326 | inherited: false, |
michael@0 | 2327 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2328 | initial_values: [ "none" ], |
michael@0 | 2329 | other_values: [ "left", "right", "both" ], |
michael@0 | 2330 | invalid_values: [] |
michael@0 | 2331 | }, |
michael@0 | 2332 | "clip": { |
michael@0 | 2333 | domProp: "clip", |
michael@0 | 2334 | inherited: false, |
michael@0 | 2335 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2336 | initial_values: [ "auto" ], |
michael@0 | 2337 | other_values: [ "rect(0 0 0 0)", "rect(auto,auto,auto,auto)", "rect(3px, 4px, 4em, 0)", "rect(auto, 3em, 4pt, 2px)", "rect(2px 3px 4px 5px)" ], |
michael@0 | 2338 | invalid_values: [ "rect(auto, 3em, 2%, 5px)" ], |
michael@0 | 2339 | quirks_values: { "rect(1, 2, 3, 4)": "rect(1px, 2px, 3px, 4px)" }, |
michael@0 | 2340 | }, |
michael@0 | 2341 | "color": { |
michael@0 | 2342 | domProp: "color", |
michael@0 | 2343 | inherited: true, |
michael@0 | 2344 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2345 | /* XXX should test currentColor, but may or may not be initial */ |
michael@0 | 2346 | initial_values: [ "black", "#000", "-moz-default-color" ], |
michael@0 | 2347 | other_values: [ "green", "#f3c", "#fed292", "rgba(45,300,12,2)", "transparent", "-moz-nativehyperlinktext", "rgba(255,128,0,0.5)" ], |
michael@0 | 2348 | invalid_values: [ "#f", "#ff", "#ffff", "#fffff", "#fffffff", "#ffffffff", "#fffffffff" ], |
michael@0 | 2349 | quirks_values: { "000000": "#000000", "96ed2a": "#96ed2a", "fff": "#ffffff", "ffffff": "#ffffff", }, |
michael@0 | 2350 | }, |
michael@0 | 2351 | "content": { |
michael@0 | 2352 | domProp: "content", |
michael@0 | 2353 | inherited: false, |
michael@0 | 2354 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2355 | /* XXX needs to be on pseudo-elements */ |
michael@0 | 2356 | initial_values: [ "normal", "none" ], |
michael@0 | 2357 | other_values: [ '""', "''", '"hello"', "url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==)", "url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==')", 'url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==")', 'counter(foo)', 'counter(bar, upper-roman)', 'counters(foo, ".")', "counters(bar, '-', lower-greek)", "'-' counter(foo) '.'", "attr(title)", "open-quote", "close-quote", "no-open-quote", "no-close-quote", "close-quote attr(title) counters(foo, '.', upper-alpha)", "counter(foo, none)", "counters(bar, '.', none)", "attr(\\32)", "attr(\\2)", "attr(-\\2)", "attr(-\\32)", "counter(\\2)", "counters(\\32, '.')", "counter(-\\32, upper-roman)", "counters(-\\2, '-', lower-greek)", "counter(\\()", "counters(a\\+b, '.')", "counter(\\}, upper-alpha)", "-moz-alt-content" ], |
michael@0 | 2358 | invalid_values: [ 'counters(foo)', 'counter(foo, ".")', 'attr("title")', "attr('title')", "attr(2)", "attr(-2)", "counter(2)", "counters(-2, '.')", "-moz-alt-content 'foo'", "'foo' -moz-alt-content" ] |
michael@0 | 2359 | }, |
michael@0 | 2360 | "counter-increment": { |
michael@0 | 2361 | domProp: "counterIncrement", |
michael@0 | 2362 | inherited: false, |
michael@0 | 2363 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2364 | initial_values: [ "none" ], |
michael@0 | 2365 | other_values: [ "foo 1", "bar", "foo 3 bar baz 2", "\\32 1", "-\\32 1", "-c 1", "\\32 1", "-\\32 1", "\\2 1", "-\\2 1", "-c 1", "\\2 1", "-\\2 1", "-\\7f \\9e 1" ], |
michael@0 | 2366 | invalid_values: [ "none foo", "none foo 3", "foo none", "foo 3 none" ], |
michael@0 | 2367 | unbalanced_values: [ "foo 1 (" ] |
michael@0 | 2368 | }, |
michael@0 | 2369 | "counter-reset": { |
michael@0 | 2370 | domProp: "counterReset", |
michael@0 | 2371 | inherited: false, |
michael@0 | 2372 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2373 | initial_values: [ "none" ], |
michael@0 | 2374 | other_values: [ "foo 1", "bar", "foo 3 bar baz 2", "\\32 1", "-\\32 1", "-c 1", "\\32 1", "-\\32 1", "\\2 1", "-\\2 1", "-c 1", "\\2 1", "-\\2 1", "-\\7f \\9e 1" ], |
michael@0 | 2375 | invalid_values: [ "none foo", "none foo 3", "foo none", "foo 3 none" ] |
michael@0 | 2376 | }, |
michael@0 | 2377 | "cursor": { |
michael@0 | 2378 | domProp: "cursor", |
michael@0 | 2379 | inherited: true, |
michael@0 | 2380 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2381 | initial_values: [ "auto" ], |
michael@0 | 2382 | other_values: [ "crosshair", "default", "pointer", "move", "e-resize", "ne-resize", "nw-resize", "n-resize", "se-resize", "sw-resize", "s-resize", "w-resize", "text", "wait", "help", "progress", "copy", "alias", "context-menu", "cell", "not-allowed", "col-resize", "row-resize", "no-drop", "vertical-text", "all-scroll", "nesw-resize", "nwse-resize", "ns-resize", "ew-resize", "none", "grab", "grabbing", "zoom-in", "zoom-out", "-moz-grab", "-moz-grabbing", "-moz-zoom-in", "-moz-zoom-out", "url(foo.png), move", "url(foo.png) 5 7, move", "url(foo.png) 12 3, url(bar.png), no-drop", "url(foo.png), url(bar.png) 7 2, wait", "url(foo.png) 3 2, url(bar.png) 7 9, pointer" ], |
michael@0 | 2383 | invalid_values: [ "url(foo.png)", "url(foo.png) 5 5" ] |
michael@0 | 2384 | }, |
michael@0 | 2385 | "direction": { |
michael@0 | 2386 | domProp: "direction", |
michael@0 | 2387 | inherited: true, |
michael@0 | 2388 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2389 | initial_values: [ "ltr" ], |
michael@0 | 2390 | other_values: [ "rtl" ], |
michael@0 | 2391 | invalid_values: [] |
michael@0 | 2392 | }, |
michael@0 | 2393 | "display": { |
michael@0 | 2394 | domProp: "display", |
michael@0 | 2395 | inherited: false, |
michael@0 | 2396 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2397 | initial_values: [ "inline" ], |
michael@0 | 2398 | /* XXX none will really mess with other properties */ |
michael@0 | 2399 | prerequisites: { "float": "none", "position": "static" }, |
michael@0 | 2400 | other_values: [ |
michael@0 | 2401 | "block", |
michael@0 | 2402 | "flex", |
michael@0 | 2403 | "inline-flex", |
michael@0 | 2404 | "list-item", |
michael@0 | 2405 | "inline-block", |
michael@0 | 2406 | "table", |
michael@0 | 2407 | "inline-table", |
michael@0 | 2408 | "table-row-group", |
michael@0 | 2409 | "table-header-group", |
michael@0 | 2410 | "table-footer-group", |
michael@0 | 2411 | "table-row", |
michael@0 | 2412 | "table-column-group", |
michael@0 | 2413 | "table-column", |
michael@0 | 2414 | "table-cell", |
michael@0 | 2415 | "table-caption", |
michael@0 | 2416 | "none" |
michael@0 | 2417 | ], |
michael@0 | 2418 | invalid_values: [] |
michael@0 | 2419 | }, |
michael@0 | 2420 | "empty-cells": { |
michael@0 | 2421 | domProp: "emptyCells", |
michael@0 | 2422 | inherited: true, |
michael@0 | 2423 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2424 | initial_values: [ "show" ], |
michael@0 | 2425 | other_values: [ "hide", "-moz-show-background" ], |
michael@0 | 2426 | invalid_values: [] |
michael@0 | 2427 | }, |
michael@0 | 2428 | "float": { |
michael@0 | 2429 | domProp: "cssFloat", |
michael@0 | 2430 | inherited: false, |
michael@0 | 2431 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2432 | initial_values: [ "none" ], |
michael@0 | 2433 | other_values: [ "left", "right" ], |
michael@0 | 2434 | invalid_values: [] |
michael@0 | 2435 | }, |
michael@0 | 2436 | "font": { |
michael@0 | 2437 | domProp: "font", |
michael@0 | 2438 | inherited: true, |
michael@0 | 2439 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 2440 | subproperties: [ "font-style", "font-variant", "font-weight", "font-size", "line-height", "font-family", "font-stretch", "font-size-adjust", "-moz-font-feature-settings", "-moz-font-language-override" ], |
michael@0 | 2441 | initial_values: [ (gInitialFontFamilyIsSansSerif ? "medium sans-serif" : "medium serif") ], |
michael@0 | 2442 | other_values: [ "large serif", "9px fantasy", "bold italic small-caps 24px/1.4 Times New Roman, serif", "small inherit roman", "small roman inherit", |
michael@0 | 2443 | // system fonts |
michael@0 | 2444 | "caption", "icon", "menu", "message-box", "small-caption", "status-bar", |
michael@0 | 2445 | // Gecko-specific system fonts |
michael@0 | 2446 | "-moz-window", "-moz-document", "-moz-desktop", "-moz-info", "-moz-dialog", "-moz-button", "-moz-pull-down-menu", "-moz-list", "-moz-field", "-moz-workspace", |
michael@0 | 2447 | ], |
michael@0 | 2448 | invalid_values: [ "9 fantasy", "-2px fantasy" ] |
michael@0 | 2449 | }, |
michael@0 | 2450 | "font-family": { |
michael@0 | 2451 | domProp: "fontFamily", |
michael@0 | 2452 | inherited: true, |
michael@0 | 2453 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2454 | initial_values: [ (gInitialFontFamilyIsSansSerif ? "sans-serif" : "serif") ], |
michael@0 | 2455 | other_values: [ (gInitialFontFamilyIsSansSerif ? "serif" : "sans-serif"), "Times New Roman, serif", "'Times New Roman', serif", "cursive", "fantasy", "\\\"Times New Roman", "\"Times New Roman\"", "Times, \\\"Times New Roman", "Times, \"Times New Roman\"", "-no-such-font-installed", "inherit roman", "roman inherit", "Times, inherit roman", "inherit roman, Times", "roman inherit, Times", "Times, roman inherit" ], |
michael@0 | 2456 | invalid_values: [ "\"Times New\" Roman", "\"Times New Roman\n", "Times, \"Times New Roman\n" ] |
michael@0 | 2457 | }, |
michael@0 | 2458 | "-moz-font-feature-settings": { |
michael@0 | 2459 | domProp: "MozFontFeatureSettings", |
michael@0 | 2460 | inherited: true, |
michael@0 | 2461 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2462 | initial_values: [ "normal" ], |
michael@0 | 2463 | other_values: [ |
michael@0 | 2464 | "'liga' on", "'liga'", "\"liga\" 1", "'liga', 'clig' 1", |
michael@0 | 2465 | "\"liga\" off", "\"liga\" 0", '"cv01" 3, "cv02" 4', |
michael@0 | 2466 | '"cswh", "smcp" off, "salt" 4', '"cswh" 1, "smcp" off, "salt" 4', |
michael@0 | 2467 | '"cswh" 0, \'blah\', "liga", "smcp" off, "salt" 4', |
michael@0 | 2468 | '"liga" ,"smcp" 0 , "blah"' |
michael@0 | 2469 | ], |
michael@0 | 2470 | invalid_values: [ |
michael@0 | 2471 | 'liga', 'liga 1', 'liga normal', '"liga" normal', 'normal liga', |
michael@0 | 2472 | 'normal "liga"', 'normal, "liga"', '"liga=1"', "'foobar' on", |
michael@0 | 2473 | '"blahblah" 0', '"liga" 3.14', '"liga" 1 3.14', '"liga" 1 normal', |
michael@0 | 2474 | '"liga" 1 off', '"liga" on off', '"liga" , 0 "smcp"', '"liga" "smcp"' |
michael@0 | 2475 | ] |
michael@0 | 2476 | }, |
michael@0 | 2477 | "-moz-font-language-override": { |
michael@0 | 2478 | domProp: "MozFontLanguageOverride", |
michael@0 | 2479 | inherited: true, |
michael@0 | 2480 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2481 | initial_values: [ "normal" ], |
michael@0 | 2482 | other_values: [ "'ENG'", "'TRK'", "\"TRK\"", "'N\\'Ko'" ], |
michael@0 | 2483 | invalid_values: [ "TRK", "ja" ] |
michael@0 | 2484 | }, |
michael@0 | 2485 | "font-size": { |
michael@0 | 2486 | domProp: "fontSize", |
michael@0 | 2487 | inherited: true, |
michael@0 | 2488 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2489 | initial_values: [ "medium", |
michael@0 | 2490 | "1rem", |
michael@0 | 2491 | "calc(1rem)", |
michael@0 | 2492 | "calc(0.75rem + 200% - 125% + 0.25rem - 75%)" |
michael@0 | 2493 | ], |
michael@0 | 2494 | other_values: [ "large", "2em", "50%", "xx-small", "36pt", "8px", "larger", "smaller", |
michael@0 | 2495 | "0px", |
michael@0 | 2496 | "0%", |
michael@0 | 2497 | "calc(2em)", |
michael@0 | 2498 | "calc(36pt + 75% + (30% + 2em + 2px))", |
michael@0 | 2499 | "calc(-2em)", |
michael@0 | 2500 | "calc(-50%)", |
michael@0 | 2501 | "calc(-1px)" |
michael@0 | 2502 | ], |
michael@0 | 2503 | invalid_values: [ "-2em", "-50%", "-1px" ], |
michael@0 | 2504 | quirks_values: { "5": "5px" }, |
michael@0 | 2505 | }, |
michael@0 | 2506 | "font-size-adjust": { |
michael@0 | 2507 | domProp: "fontSizeAdjust", |
michael@0 | 2508 | inherited: true, |
michael@0 | 2509 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2510 | initial_values: [ "none" ], |
michael@0 | 2511 | other_values: [ "0.3", "0.5", "0.7" ], |
michael@0 | 2512 | invalid_values: [] |
michael@0 | 2513 | }, |
michael@0 | 2514 | "font-stretch": { |
michael@0 | 2515 | domProp: "fontStretch", |
michael@0 | 2516 | inherited: true, |
michael@0 | 2517 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2518 | initial_values: [ "normal" ], |
michael@0 | 2519 | other_values: [ "ultra-condensed", "extra-condensed", "condensed", "semi-condensed", "semi-expanded", "expanded", "extra-expanded", "ultra-expanded" ], |
michael@0 | 2520 | invalid_values: [ "narrower", "wider" ] |
michael@0 | 2521 | }, |
michael@0 | 2522 | "font-style": { |
michael@0 | 2523 | domProp: "fontStyle", |
michael@0 | 2524 | inherited: true, |
michael@0 | 2525 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2526 | initial_values: [ "normal" ], |
michael@0 | 2527 | other_values: [ "italic", "oblique" ], |
michael@0 | 2528 | invalid_values: [] |
michael@0 | 2529 | }, |
michael@0 | 2530 | "font-variant": { |
michael@0 | 2531 | domProp: "fontVariant", |
michael@0 | 2532 | inherited: true, |
michael@0 | 2533 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2534 | initial_values: [ "normal" ], |
michael@0 | 2535 | other_values: [ "small-caps" ], |
michael@0 | 2536 | invalid_values: [ "small-caps normal" ] |
michael@0 | 2537 | }, |
michael@0 | 2538 | "font-weight": { |
michael@0 | 2539 | domProp: "fontWeight", |
michael@0 | 2540 | inherited: true, |
michael@0 | 2541 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2542 | initial_values: [ "normal", "400" ], |
michael@0 | 2543 | other_values: [ "bold", "100", "200", "300", "500", "600", "700", "800", "900", "bolder", "lighter" ], |
michael@0 | 2544 | invalid_values: [ "0", "100.0", "107", "399", "401", "699", "710", "1000" ] |
michael@0 | 2545 | }, |
michael@0 | 2546 | "height": { |
michael@0 | 2547 | domProp: "height", |
michael@0 | 2548 | inherited: false, |
michael@0 | 2549 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2550 | /* FIXME: test zero, and test calc clamping */ |
michael@0 | 2551 | initial_values: [ " auto" ], |
michael@0 | 2552 | /* computed value tests for height test more with display:block */ |
michael@0 | 2553 | prerequisites: { "display": "block" }, |
michael@0 | 2554 | other_values: [ "15px", "3em", "15%", |
michael@0 | 2555 | "calc(2px)", |
michael@0 | 2556 | "calc(50%)", |
michael@0 | 2557 | "calc(3*25px)", |
michael@0 | 2558 | "calc(25px*3)", |
michael@0 | 2559 | "calc(3*25px + 50%)", |
michael@0 | 2560 | ], |
michael@0 | 2561 | invalid_values: [ "none", "-moz-max-content", "-moz-min-content", "-moz-fit-content", "-moz-available" ], |
michael@0 | 2562 | quirks_values: { "5": "5px" }, |
michael@0 | 2563 | }, |
michael@0 | 2564 | "ime-mode": { |
michael@0 | 2565 | domProp: "imeMode", |
michael@0 | 2566 | inherited: false, |
michael@0 | 2567 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2568 | initial_values: [ "auto" ], |
michael@0 | 2569 | other_values: [ "normal", "disabled", "active", "inactive" ], |
michael@0 | 2570 | invalid_values: [ "none", "enabled", "1px" ] |
michael@0 | 2571 | }, |
michael@0 | 2572 | "left": { |
michael@0 | 2573 | domProp: "left", |
michael@0 | 2574 | inherited: false, |
michael@0 | 2575 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2576 | /* FIXME: run tests with multiple prerequisites */ |
michael@0 | 2577 | prerequisites: { "position": "relative" }, |
michael@0 | 2578 | /* XXX 0 may or may not be equal to auto */ |
michael@0 | 2579 | initial_values: [ "auto" ], |
michael@0 | 2580 | other_values: [ "32px", "-3em", "12%", |
michael@0 | 2581 | "calc(2px)", |
michael@0 | 2582 | "calc(-2px)", |
michael@0 | 2583 | "calc(50%)", |
michael@0 | 2584 | "calc(3*25px)", |
michael@0 | 2585 | "calc(25px*3)", |
michael@0 | 2586 | "calc(3*25px + 50%)", |
michael@0 | 2587 | ], |
michael@0 | 2588 | invalid_values: [], |
michael@0 | 2589 | quirks_values: { "5": "5px" }, |
michael@0 | 2590 | }, |
michael@0 | 2591 | "letter-spacing": { |
michael@0 | 2592 | domProp: "letterSpacing", |
michael@0 | 2593 | inherited: true, |
michael@0 | 2594 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2595 | initial_values: [ "normal" ], |
michael@0 | 2596 | other_values: [ "0", "0px", "1em", "2px", "-3px", |
michael@0 | 2597 | "calc(0px)", "calc(1em)", "calc(1em + 3px)", |
michael@0 | 2598 | "calc(15px / 2)", "calc(15px/2)", "calc(-3px)" |
michael@0 | 2599 | ], |
michael@0 | 2600 | invalid_values: [], |
michael@0 | 2601 | quirks_values: { "5": "5px" }, |
michael@0 | 2602 | }, |
michael@0 | 2603 | "line-height": { |
michael@0 | 2604 | domProp: "lineHeight", |
michael@0 | 2605 | inherited: true, |
michael@0 | 2606 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2607 | /* |
michael@0 | 2608 | * Inheritance tests require consistent font size, since |
michael@0 | 2609 | * getComputedStyle (which uses the CSS2 computed value, or |
michael@0 | 2610 | * CSS2.1 used value) doesn't match what the CSS2.1 computed |
michael@0 | 2611 | * value is. And they even require consistent font metrics for |
michael@0 | 2612 | * computation of 'normal'. -moz-block-height requires height |
michael@0 | 2613 | * on a block. |
michael@0 | 2614 | */ |
michael@0 | 2615 | prerequisites: { "font-size": "19px", "font-size-adjust": "none", "font-family": "serif", "font-weight": "normal", "font-style": "normal", "height": "18px", "display": "block"}, |
michael@0 | 2616 | initial_values: [ "normal" ], |
michael@0 | 2617 | other_values: [ "1.0", "1", "1em", "47px", "-moz-block-height" ], |
michael@0 | 2618 | invalid_values: [] |
michael@0 | 2619 | }, |
michael@0 | 2620 | "list-style": { |
michael@0 | 2621 | domProp: "listStyle", |
michael@0 | 2622 | inherited: true, |
michael@0 | 2623 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 2624 | subproperties: [ "list-style-type", "list-style-position", "list-style-image" ], |
michael@0 | 2625 | initial_values: [ "outside", "disc", "disc outside", "outside disc", "disc none", "none disc", "none disc outside", "none outside disc", "disc none outside", "disc outside none", "outside none disc", "outside disc none" ], |
michael@0 | 2626 | other_values: [ "inside none", "none inside", "none none inside", "square", "none", "none none", "outside none none", "none outside none", "none none outside", "none outside", "outside none", |
michael@0 | 2627 | 'url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==")', |
michael@0 | 2628 | 'none url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==")', |
michael@0 | 2629 | 'url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==") none', |
michael@0 | 2630 | 'url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==") outside', |
michael@0 | 2631 | 'outside url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==")', |
michael@0 | 2632 | 'outside none url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==")', |
michael@0 | 2633 | 'outside url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==") none', |
michael@0 | 2634 | 'none url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==") outside', |
michael@0 | 2635 | 'none outside url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==")', |
michael@0 | 2636 | 'url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==") outside none', |
michael@0 | 2637 | 'url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==") none outside' |
michael@0 | 2638 | ], |
michael@0 | 2639 | invalid_values: [ "outside outside", "disc disc", "unknown value", "none none none", "none disc url(404.png)", "none url(404.png) disc", "disc none url(404.png)", "disc url(404.png) none", "url(404.png) none disc", "url(404.png) disc none", "none disc outside url(404.png)" ] |
michael@0 | 2640 | }, |
michael@0 | 2641 | "list-style-image": { |
michael@0 | 2642 | domProp: "listStyleImage", |
michael@0 | 2643 | inherited: true, |
michael@0 | 2644 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2645 | initial_values: [ "none" ], |
michael@0 | 2646 | other_values: [ 'url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==")', |
michael@0 | 2647 | // Add some tests for interesting url() values here to test serialization, etc. |
michael@0 | 2648 | "url(\'data:text/plain,\"\')", |
michael@0 | 2649 | "url(\"data:text/plain,\'\")", |
michael@0 | 2650 | "url(\'data:text/plain,\\\'\')", |
michael@0 | 2651 | "url(\"data:text/plain,\\\"\")", |
michael@0 | 2652 | "url(\'data:text/plain,\\\"\')", |
michael@0 | 2653 | "url(\"data:text/plain,\\\'\")", |
michael@0 | 2654 | "url(data:text/plain,\\\\)", |
michael@0 | 2655 | ], |
michael@0 | 2656 | invalid_values: [] |
michael@0 | 2657 | }, |
michael@0 | 2658 | "list-style-position": { |
michael@0 | 2659 | domProp: "listStylePosition", |
michael@0 | 2660 | inherited: true, |
michael@0 | 2661 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2662 | initial_values: [ "outside" ], |
michael@0 | 2663 | other_values: [ "inside" ], |
michael@0 | 2664 | invalid_values: [] |
michael@0 | 2665 | }, |
michael@0 | 2666 | "list-style-type": { |
michael@0 | 2667 | domProp: "listStyleType", |
michael@0 | 2668 | inherited: true, |
michael@0 | 2669 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2670 | initial_values: [ "disc" ], |
michael@0 | 2671 | other_values: [ "none", "circle", "square", |
michael@0 | 2672 | "decimal", "decimal-leading-zero", |
michael@0 | 2673 | "lower-roman", "upper-roman", "lower-greek", |
michael@0 | 2674 | "lower-alpha", "lower-latin", "upper-alpha", "upper-latin", |
michael@0 | 2675 | "hebrew", "armenian", "georgian", |
michael@0 | 2676 | "cjk-decimal", "cjk-ideographic", |
michael@0 | 2677 | "hiragana", "katakana", "hiragana-iroha", "katakana-iroha", |
michael@0 | 2678 | "japanese-informal", "japanese-formal", "korean-hangul-formal", |
michael@0 | 2679 | "korean-hanja-informal", "korean-hanja-formal", |
michael@0 | 2680 | "simp-chinese-informal", "simp-chinese-formal", |
michael@0 | 2681 | "trad-chinese-informal", "trad-chinese-formal", |
michael@0 | 2682 | "-moz-cjk-heavenly-stem", "-moz-cjk-earthly-branch", |
michael@0 | 2683 | "-moz-trad-chinese-informal", "-moz-trad-chinese-formal", |
michael@0 | 2684 | "-moz-simp-chinese-informal", "-moz-simp-chinese-formal", |
michael@0 | 2685 | "-moz-japanese-informal", "-moz-japanese-formal", |
michael@0 | 2686 | "-moz-arabic-indic", "-moz-persian", "-moz-urdu", |
michael@0 | 2687 | "-moz-devanagari", "-moz-gurmukhi", "-moz-gujarati", |
michael@0 | 2688 | "-moz-oriya", "-moz-kannada", "-moz-malayalam", "-moz-bengali", |
michael@0 | 2689 | "-moz-tamil", "-moz-telugu", "-moz-thai", "-moz-lao", |
michael@0 | 2690 | "-moz-myanmar", "-moz-khmer", |
michael@0 | 2691 | "-moz-hangul", "-moz-hangul-consonant", |
michael@0 | 2692 | "-moz-ethiopic-halehame", "-moz-ethiopic-numeric", |
michael@0 | 2693 | "-moz-ethiopic-halehame-am", |
michael@0 | 2694 | "-moz-ethiopic-halehame-ti-er", "-moz-ethiopic-halehame-ti-et" |
michael@0 | 2695 | ], |
michael@0 | 2696 | invalid_values: [] |
michael@0 | 2697 | }, |
michael@0 | 2698 | "margin": { |
michael@0 | 2699 | domProp: "margin", |
michael@0 | 2700 | inherited: false, |
michael@0 | 2701 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 2702 | subproperties: [ "margin-top", "margin-right", "margin-bottom", "margin-left" ], |
michael@0 | 2703 | initial_values: [ "0", "0px 0 0em", "0% 0px 0em 0pt" ], |
michael@0 | 2704 | other_values: [ "3px 0", "2em 4px 2pt", "1em 2em 3px 4px" ], |
michael@0 | 2705 | invalid_values: [], |
michael@0 | 2706 | quirks_values: { "5": "5px", "3px 6px 2 5px": "3px 6px 2px 5px" }, |
michael@0 | 2707 | }, |
michael@0 | 2708 | "margin-bottom": { |
michael@0 | 2709 | domProp: "marginBottom", |
michael@0 | 2710 | inherited: false, |
michael@0 | 2711 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2712 | /* XXX testing auto has prerequisites */ |
michael@0 | 2713 | initial_values: [ "0", "0px", "0%", "calc(0pt)", "calc(0% + 0px)" ], |
michael@0 | 2714 | other_values: [ "1px", "2em", "5%", |
michael@0 | 2715 | "calc(2px)", |
michael@0 | 2716 | "calc(-2px)", |
michael@0 | 2717 | "calc(50%)", |
michael@0 | 2718 | "calc(3*25px)", |
michael@0 | 2719 | "calc(25px*3)", |
michael@0 | 2720 | "calc(3*25px + 50%)", |
michael@0 | 2721 | ], |
michael@0 | 2722 | invalid_values: [ ], |
michael@0 | 2723 | quirks_values: { "5": "5px" }, |
michael@0 | 2724 | }, |
michael@0 | 2725 | "margin-left": { |
michael@0 | 2726 | domProp: "marginLeft", |
michael@0 | 2727 | inherited: false, |
michael@0 | 2728 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 2729 | /* no subproperties */ |
michael@0 | 2730 | /* XXX testing auto has prerequisites */ |
michael@0 | 2731 | initial_values: [ "0", "0px", "0%", "calc(0pt)", "calc(0% + 0px)" ], |
michael@0 | 2732 | other_values: [ "1px", "2em", "5%", ".5px", "+32px", "+.789px", "-.328px", "+0.56px", "-0.974px", "237px", "-289px", "-056px", "1987.45px", "-84.32px", |
michael@0 | 2733 | "calc(2px)", |
michael@0 | 2734 | "calc(-2px)", |
michael@0 | 2735 | "calc(50%)", |
michael@0 | 2736 | "calc(3*25px)", |
michael@0 | 2737 | "calc(25px*3)", |
michael@0 | 2738 | "calc(3*25px + 50%)", |
michael@0 | 2739 | ], |
michael@0 | 2740 | invalid_values: [ "..25px", ".+5px", ".px", "-.px", "++5px", "-+4px", "+-3px", "--7px", "+-.6px", "-+.5px", "++.7px", "--.4px" ], |
michael@0 | 2741 | quirks_values: { "5": "5px" }, |
michael@0 | 2742 | }, |
michael@0 | 2743 | "margin-right": { |
michael@0 | 2744 | domProp: "marginRight", |
michael@0 | 2745 | inherited: false, |
michael@0 | 2746 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 2747 | /* no subproperties */ |
michael@0 | 2748 | /* XXX testing auto has prerequisites */ |
michael@0 | 2749 | initial_values: [ "0", "0px", "0%", "calc(0pt)", "calc(0% + 0px)" ], |
michael@0 | 2750 | other_values: [ "1px", "2em", "5%", |
michael@0 | 2751 | "calc(2px)", |
michael@0 | 2752 | "calc(-2px)", |
michael@0 | 2753 | "calc(50%)", |
michael@0 | 2754 | "calc(3*25px)", |
michael@0 | 2755 | "calc(25px*3)", |
michael@0 | 2756 | "calc(3*25px + 50%)", |
michael@0 | 2757 | ], |
michael@0 | 2758 | invalid_values: [ ], |
michael@0 | 2759 | quirks_values: { "5": "5px" }, |
michael@0 | 2760 | }, |
michael@0 | 2761 | "margin-top": { |
michael@0 | 2762 | domProp: "marginTop", |
michael@0 | 2763 | inherited: false, |
michael@0 | 2764 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2765 | /* XXX testing auto has prerequisites */ |
michael@0 | 2766 | initial_values: [ "0", "0px", "0%", "calc(0pt)", "calc(0% + 0px)" ], |
michael@0 | 2767 | other_values: [ "1px", "2em", "5%", |
michael@0 | 2768 | "calc(2px)", |
michael@0 | 2769 | "calc(-2px)", |
michael@0 | 2770 | "calc(50%)", |
michael@0 | 2771 | "calc(3*25px)", |
michael@0 | 2772 | "calc(25px*3)", |
michael@0 | 2773 | "calc(3*25px + 50%)", |
michael@0 | 2774 | ], |
michael@0 | 2775 | invalid_values: [ ], |
michael@0 | 2776 | quirks_values: { "5": "5px" }, |
michael@0 | 2777 | }, |
michael@0 | 2778 | "marker-offset": { |
michael@0 | 2779 | domProp: "markerOffset", |
michael@0 | 2780 | inherited: false, |
michael@0 | 2781 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2782 | initial_values: [ "auto" ], |
michael@0 | 2783 | other_values: [ "6em", "-1px", "calc(0px)", "calc(3em + 2px - 4px)", "calc(-2em)" ], |
michael@0 | 2784 | invalid_values: [] |
michael@0 | 2785 | }, |
michael@0 | 2786 | "marks": { |
michael@0 | 2787 | /* XXX not a real property; applies only to page context */ |
michael@0 | 2788 | domProp: "marks", |
michael@0 | 2789 | inherited: false, |
michael@0 | 2790 | backend_only: true, |
michael@0 | 2791 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2792 | initial_values: [ "none" ], |
michael@0 | 2793 | other_values: [ "crop", "cross", "crop cross", "cross crop" ], |
michael@0 | 2794 | invalid_values: [ "none none", "crop none", "none crop", "cross none", "none cross" ] |
michael@0 | 2795 | }, |
michael@0 | 2796 | "max-height": { |
michael@0 | 2797 | domProp: "maxHeight", |
michael@0 | 2798 | inherited: false, |
michael@0 | 2799 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2800 | prerequisites: { "display": "block" }, |
michael@0 | 2801 | initial_values: [ "none" ], |
michael@0 | 2802 | other_values: [ "30px", "50%", "0", |
michael@0 | 2803 | "calc(2px)", |
michael@0 | 2804 | "calc(-2px)", |
michael@0 | 2805 | "calc(0px)", |
michael@0 | 2806 | "calc(50%)", |
michael@0 | 2807 | "calc(3*25px)", |
michael@0 | 2808 | "calc(25px*3)", |
michael@0 | 2809 | "calc(3*25px + 50%)", |
michael@0 | 2810 | ], |
michael@0 | 2811 | invalid_values: [ "auto", "-moz-max-content", "-moz-min-content", "-moz-fit-content", "-moz-available", "5" ] |
michael@0 | 2812 | }, |
michael@0 | 2813 | "max-width": { |
michael@0 | 2814 | domProp: "maxWidth", |
michael@0 | 2815 | inherited: false, |
michael@0 | 2816 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2817 | prerequisites: { "display": "block" }, |
michael@0 | 2818 | initial_values: [ "none" ], |
michael@0 | 2819 | other_values: [ "30px", "50%", "0", "-moz-max-content", "-moz-min-content", "-moz-fit-content", "-moz-available", |
michael@0 | 2820 | "calc(2px)", |
michael@0 | 2821 | "calc(-2px)", |
michael@0 | 2822 | "calc(0px)", |
michael@0 | 2823 | "calc(50%)", |
michael@0 | 2824 | "calc(3*25px)", |
michael@0 | 2825 | "calc(25px*3)", |
michael@0 | 2826 | "calc(3*25px + 50%)", |
michael@0 | 2827 | ], |
michael@0 | 2828 | invalid_values: [ "auto", "5" ] |
michael@0 | 2829 | }, |
michael@0 | 2830 | "min-height": { |
michael@0 | 2831 | domProp: "minHeight", |
michael@0 | 2832 | inherited: false, |
michael@0 | 2833 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2834 | prerequisites: { "display": "block" }, |
michael@0 | 2835 | initial_values: [ "0", "calc(0em)", "calc(-2px)", "calc(-1%)" ], |
michael@0 | 2836 | other_values: [ "30px", "50%", |
michael@0 | 2837 | "calc(2px)", |
michael@0 | 2838 | "calc(50%)", |
michael@0 | 2839 | "calc(3*25px)", |
michael@0 | 2840 | "calc(25px*3)", |
michael@0 | 2841 | "calc(3*25px + 50%)", |
michael@0 | 2842 | ], |
michael@0 | 2843 | invalid_values: [ "auto", "none", "-moz-max-content", "-moz-min-content", "-moz-fit-content", "-moz-available", "5" ] |
michael@0 | 2844 | }, |
michael@0 | 2845 | "min-width": { |
michael@0 | 2846 | domProp: "minWidth", |
michael@0 | 2847 | inherited: false, |
michael@0 | 2848 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2849 | prerequisites: { "display": "block" }, |
michael@0 | 2850 | initial_values: [ "0", "calc(0em)", "calc(-2px)", "calc(-1%)" ], |
michael@0 | 2851 | other_values: [ "30px", "50%", "-moz-max-content", "-moz-min-content", "-moz-fit-content", "-moz-available", |
michael@0 | 2852 | "calc(2px)", |
michael@0 | 2853 | "calc(50%)", |
michael@0 | 2854 | "calc(3*25px)", |
michael@0 | 2855 | "calc(25px*3)", |
michael@0 | 2856 | "calc(3*25px + 50%)", |
michael@0 | 2857 | ], |
michael@0 | 2858 | invalid_values: [ "auto", "none", "5" ] |
michael@0 | 2859 | }, |
michael@0 | 2860 | |
michael@0 | 2861 | "opacity": { |
michael@0 | 2862 | domProp: "opacity", |
michael@0 | 2863 | inherited: false, |
michael@0 | 2864 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2865 | initial_values: [ "1", "17", "397.376", "3e1", "3e+1", "3e0", "3e+0", "3e-0" ], |
michael@0 | 2866 | other_values: [ "0", "0.4", "0.0000", "-3", "3e-1" ], |
michael@0 | 2867 | invalid_values: [ "0px", "1px" ] |
michael@0 | 2868 | }, |
michael@0 | 2869 | "-moz-orient": { |
michael@0 | 2870 | domProp: "MozOrient", |
michael@0 | 2871 | inherited: false, |
michael@0 | 2872 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2873 | initial_values: [ "auto" ], |
michael@0 | 2874 | other_values: [ "horizontal", "vertical" ], |
michael@0 | 2875 | invalid_values: [ "none" ] |
michael@0 | 2876 | }, |
michael@0 | 2877 | "orphans": { |
michael@0 | 2878 | domProp: "orphans", |
michael@0 | 2879 | inherited: true, |
michael@0 | 2880 | backend_only: true, |
michael@0 | 2881 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2882 | // XXX requires display:block |
michael@0 | 2883 | initial_values: [ "2" ], |
michael@0 | 2884 | other_values: [ "1", "7" ], |
michael@0 | 2885 | invalid_values: [ "0", "-1", "0px", "3px", "3e1" ] |
michael@0 | 2886 | }, |
michael@0 | 2887 | "outline": { |
michael@0 | 2888 | domProp: "outline", |
michael@0 | 2889 | inherited: false, |
michael@0 | 2890 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 2891 | subproperties: [ "outline-color", "outline-style", "outline-width" ], |
michael@0 | 2892 | initial_values: [ |
michael@0 | 2893 | "none", "medium", "thin", |
michael@0 | 2894 | // XXX Should be invert, but currently currentcolor. |
michael@0 | 2895 | //"invert", "none medium invert" |
michael@0 | 2896 | "currentColor", "none medium currentcolor" |
michael@0 | 2897 | ], |
michael@0 | 2898 | other_values: [ "solid", "medium solid", "green solid", "10px solid", "thick solid" ], |
michael@0 | 2899 | invalid_values: [ "5%", "5", "5 solid green" ] |
michael@0 | 2900 | }, |
michael@0 | 2901 | "outline-color": { |
michael@0 | 2902 | domProp: "outlineColor", |
michael@0 | 2903 | inherited: false, |
michael@0 | 2904 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2905 | prerequisites: { "color": "black" }, |
michael@0 | 2906 | initial_values: [ "currentColor", "-moz-use-text-color" ], // XXX should be invert |
michael@0 | 2907 | other_values: [ "green", "rgba(255,128,0,0.5)", "transparent" ], |
michael@0 | 2908 | invalid_values: [ "#0", "#00", "#0000", "#00000", "#0000000", "#00000000", "#000000000", "000000", "cc00ff" ] |
michael@0 | 2909 | }, |
michael@0 | 2910 | "outline-offset": { |
michael@0 | 2911 | domProp: "outlineOffset", |
michael@0 | 2912 | inherited: false, |
michael@0 | 2913 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2914 | initial_values: [ "0", "0px", "-0", "calc(0px)", "calc(3em + 2px - 2px - 3em)", "calc(-0em)" ], |
michael@0 | 2915 | other_values: [ "-3px", "1em", "calc(3em)", "calc(7pt + 3 * 2em)", "calc(-3px)" ], |
michael@0 | 2916 | invalid_values: [ "5%" ] |
michael@0 | 2917 | }, |
michael@0 | 2918 | "outline-style": { |
michael@0 | 2919 | domProp: "outlineStyle", |
michael@0 | 2920 | inherited: false, |
michael@0 | 2921 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2922 | // XXX Should 'hidden' be the same as initial? |
michael@0 | 2923 | initial_values: [ "none" ], |
michael@0 | 2924 | other_values: [ "solid", "dashed", "dotted", "double", "outset", "inset", "groove", "ridge" ], |
michael@0 | 2925 | invalid_values: [] |
michael@0 | 2926 | }, |
michael@0 | 2927 | "outline-width": { |
michael@0 | 2928 | domProp: "outlineWidth", |
michael@0 | 2929 | inherited: false, |
michael@0 | 2930 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2931 | prerequisites: { "outline-style": "solid" }, |
michael@0 | 2932 | initial_values: [ "medium", "3px", "calc(4px - 1px)" ], |
michael@0 | 2933 | other_values: [ "thin", "thick", "1px", "2em", |
michael@0 | 2934 | "calc(2px)", |
michael@0 | 2935 | "calc(-2px)", |
michael@0 | 2936 | "calc(0px)", |
michael@0 | 2937 | "calc(0px)", |
michael@0 | 2938 | "calc(5em)", |
michael@0 | 2939 | "calc(3*25px)", |
michael@0 | 2940 | "calc(25px*3)", |
michael@0 | 2941 | "calc(3*25px + 5em)", |
michael@0 | 2942 | ], |
michael@0 | 2943 | invalid_values: [ "5%", "5" ] |
michael@0 | 2944 | }, |
michael@0 | 2945 | "overflow": { |
michael@0 | 2946 | domProp: "overflow", |
michael@0 | 2947 | inherited: false, |
michael@0 | 2948 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 2949 | prerequisites: { "display": "block" }, |
michael@0 | 2950 | subproperties: [ "overflow-x", "overflow-y" ], |
michael@0 | 2951 | initial_values: [ "visible" ], |
michael@0 | 2952 | other_values: [ "auto", "scroll", "hidden", "-moz-hidden-unscrollable", "-moz-scrollbars-none" ], |
michael@0 | 2953 | invalid_values: [] |
michael@0 | 2954 | }, |
michael@0 | 2955 | "overflow-x": { |
michael@0 | 2956 | domProp: "overflowX", |
michael@0 | 2957 | inherited: false, |
michael@0 | 2958 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2959 | prerequisites: { "display": "block", "overflow-y": "visible" }, |
michael@0 | 2960 | initial_values: [ "visible" ], |
michael@0 | 2961 | other_values: [ "auto", "scroll", "hidden", "-moz-hidden-unscrollable" ], |
michael@0 | 2962 | invalid_values: [] |
michael@0 | 2963 | }, |
michael@0 | 2964 | "overflow-y": { |
michael@0 | 2965 | domProp: "overflowY", |
michael@0 | 2966 | inherited: false, |
michael@0 | 2967 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2968 | prerequisites: { "display": "block", "overflow-x": "visible" }, |
michael@0 | 2969 | initial_values: [ "visible" ], |
michael@0 | 2970 | other_values: [ "auto", "scroll", "hidden", "-moz-hidden-unscrollable" ], |
michael@0 | 2971 | invalid_values: [] |
michael@0 | 2972 | }, |
michael@0 | 2973 | "padding": { |
michael@0 | 2974 | domProp: "padding", |
michael@0 | 2975 | inherited: false, |
michael@0 | 2976 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 2977 | subproperties: [ "padding-top", "padding-right", "padding-bottom", "padding-left" ], |
michael@0 | 2978 | initial_values: [ "0", "0px 0 0em", "0% 0px 0em 0pt", "calc(0px) calc(0em) calc(-2px) calc(-1%)" ], |
michael@0 | 2979 | other_values: [ "3px 0", "2em 4px 2pt", "1em 2em 3px 4px" ], |
michael@0 | 2980 | invalid_values: [], |
michael@0 | 2981 | quirks_values: { "5": "5px", "3px 6px 2 5px": "3px 6px 2px 5px" }, |
michael@0 | 2982 | }, |
michael@0 | 2983 | "padding-bottom": { |
michael@0 | 2984 | domProp: "paddingBottom", |
michael@0 | 2985 | inherited: false, |
michael@0 | 2986 | type: CSS_TYPE_LONGHAND, |
michael@0 | 2987 | initial_values: [ "0", "0px", "0%", "calc(0pt)", "calc(0% + 0px)", "calc(-3px)", "calc(-1%)" ], |
michael@0 | 2988 | other_values: [ "1px", "2em", "5%", |
michael@0 | 2989 | "calc(2px)", |
michael@0 | 2990 | "calc(50%)", |
michael@0 | 2991 | "calc(3*25px)", |
michael@0 | 2992 | "calc(25px*3)", |
michael@0 | 2993 | "calc(3*25px + 50%)", |
michael@0 | 2994 | ], |
michael@0 | 2995 | invalid_values: [ ], |
michael@0 | 2996 | quirks_values: { "5": "5px" }, |
michael@0 | 2997 | }, |
michael@0 | 2998 | "padding-left": { |
michael@0 | 2999 | domProp: "paddingLeft", |
michael@0 | 3000 | inherited: false, |
michael@0 | 3001 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 3002 | /* no subproperties */ |
michael@0 | 3003 | initial_values: [ "0", "0px", "0%", "calc(0pt)", "calc(0% + 0px)", "calc(-3px)", "calc(-1%)" ], |
michael@0 | 3004 | other_values: [ "1px", "2em", "5%", |
michael@0 | 3005 | "calc(2px)", |
michael@0 | 3006 | "calc(50%)", |
michael@0 | 3007 | "calc(3*25px)", |
michael@0 | 3008 | "calc(25px*3)", |
michael@0 | 3009 | "calc(3*25px + 50%)", |
michael@0 | 3010 | ], |
michael@0 | 3011 | invalid_values: [ ], |
michael@0 | 3012 | quirks_values: { "5": "5px" }, |
michael@0 | 3013 | }, |
michael@0 | 3014 | "padding-right": { |
michael@0 | 3015 | domProp: "paddingRight", |
michael@0 | 3016 | inherited: false, |
michael@0 | 3017 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 3018 | /* no subproperties */ |
michael@0 | 3019 | initial_values: [ "0", "0px", "0%", "calc(0pt)", "calc(0% + 0px)", "calc(-3px)", "calc(-1%)" ], |
michael@0 | 3020 | other_values: [ "1px", "2em", "5%", |
michael@0 | 3021 | "calc(2px)", |
michael@0 | 3022 | "calc(50%)", |
michael@0 | 3023 | "calc(3*25px)", |
michael@0 | 3024 | "calc(25px*3)", |
michael@0 | 3025 | "calc(3*25px + 50%)", |
michael@0 | 3026 | ], |
michael@0 | 3027 | invalid_values: [ ], |
michael@0 | 3028 | quirks_values: { "5": "5px" }, |
michael@0 | 3029 | }, |
michael@0 | 3030 | "padding-top": { |
michael@0 | 3031 | domProp: "paddingTop", |
michael@0 | 3032 | inherited: false, |
michael@0 | 3033 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3034 | initial_values: [ "0", "0px", "0%", "calc(0pt)", "calc(0% + 0px)", "calc(-3px)", "calc(-1%)" ], |
michael@0 | 3035 | other_values: [ "1px", "2em", "5%", |
michael@0 | 3036 | "calc(2px)", |
michael@0 | 3037 | "calc(50%)", |
michael@0 | 3038 | "calc(3*25px)", |
michael@0 | 3039 | "calc(25px*3)", |
michael@0 | 3040 | "calc(3*25px + 50%)", |
michael@0 | 3041 | ], |
michael@0 | 3042 | invalid_values: [ ], |
michael@0 | 3043 | quirks_values: { "5": "5px" }, |
michael@0 | 3044 | }, |
michael@0 | 3045 | "page": { |
michael@0 | 3046 | domProp: "page", |
michael@0 | 3047 | inherited: true, |
michael@0 | 3048 | backend_only: true, |
michael@0 | 3049 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3050 | initial_values: [ "auto" ], |
michael@0 | 3051 | other_values: [ "foo", "bar" ], |
michael@0 | 3052 | invalid_values: [ "3px" ] |
michael@0 | 3053 | }, |
michael@0 | 3054 | "page-break-after": { |
michael@0 | 3055 | domProp: "pageBreakAfter", |
michael@0 | 3056 | inherited: false, |
michael@0 | 3057 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3058 | initial_values: [ "auto" ], |
michael@0 | 3059 | other_values: [ "always", "avoid", "left", "right" ], |
michael@0 | 3060 | invalid_values: [] |
michael@0 | 3061 | }, |
michael@0 | 3062 | "page-break-before": { |
michael@0 | 3063 | domProp: "pageBreakBefore", |
michael@0 | 3064 | inherited: false, |
michael@0 | 3065 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3066 | initial_values: [ "auto" ], |
michael@0 | 3067 | other_values: [ "always", "avoid", "left", "right" ], |
michael@0 | 3068 | invalid_values: [] |
michael@0 | 3069 | }, |
michael@0 | 3070 | "page-break-inside": { |
michael@0 | 3071 | domProp: "pageBreakInside", |
michael@0 | 3072 | inherited: false, |
michael@0 | 3073 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3074 | initial_values: [ "auto" ], |
michael@0 | 3075 | other_values: [ "avoid" ], |
michael@0 | 3076 | invalid_values: [ "left", "right" ] |
michael@0 | 3077 | }, |
michael@0 | 3078 | "pointer-events": { |
michael@0 | 3079 | domProp: "pointerEvents", |
michael@0 | 3080 | inherited: true, |
michael@0 | 3081 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3082 | initial_values: [ "auto" ], |
michael@0 | 3083 | other_values: [ "visiblePainted", "visibleFill", "visibleStroke", "visible", |
michael@0 | 3084 | "painted", "fill", "stroke", "all", "none" ], |
michael@0 | 3085 | invalid_values: [] |
michael@0 | 3086 | }, |
michael@0 | 3087 | "position": { |
michael@0 | 3088 | domProp: "position", |
michael@0 | 3089 | inherited: false, |
michael@0 | 3090 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3091 | initial_values: [ "static" ], |
michael@0 | 3092 | other_values: [ "relative", "absolute", "fixed" ], |
michael@0 | 3093 | invalid_values: [] |
michael@0 | 3094 | }, |
michael@0 | 3095 | "quotes": { |
michael@0 | 3096 | domProp: "quotes", |
michael@0 | 3097 | inherited: true, |
michael@0 | 3098 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3099 | initial_values: [ '"\u201C" "\u201D" "\u2018" "\u2019"', |
michael@0 | 3100 | '"\\201C" "\\201D" "\\2018" "\\2019"' ], |
michael@0 | 3101 | other_values: [ "none", "'\"' '\"'" ], |
michael@0 | 3102 | invalid_values: [] |
michael@0 | 3103 | }, |
michael@0 | 3104 | "right": { |
michael@0 | 3105 | domProp: "right", |
michael@0 | 3106 | inherited: false, |
michael@0 | 3107 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3108 | /* FIXME: run tests with multiple prerequisites */ |
michael@0 | 3109 | prerequisites: { "position": "relative" }, |
michael@0 | 3110 | /* XXX 0 may or may not be equal to auto */ |
michael@0 | 3111 | initial_values: [ "auto" ], |
michael@0 | 3112 | other_values: [ "32px", "-3em", "12%", |
michael@0 | 3113 | "calc(2px)", |
michael@0 | 3114 | "calc(-2px)", |
michael@0 | 3115 | "calc(50%)", |
michael@0 | 3116 | "calc(3*25px)", |
michael@0 | 3117 | "calc(25px*3)", |
michael@0 | 3118 | "calc(3*25px + 50%)", |
michael@0 | 3119 | ], |
michael@0 | 3120 | invalid_values: [], |
michael@0 | 3121 | quirks_values: { "5": "5px" }, |
michael@0 | 3122 | }, |
michael@0 | 3123 | "size": { |
michael@0 | 3124 | /* XXX not a real property; applies only to page context */ |
michael@0 | 3125 | domProp: "size", |
michael@0 | 3126 | inherited: false, |
michael@0 | 3127 | backend_only: true, |
michael@0 | 3128 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3129 | initial_values: [ "auto" ], |
michael@0 | 3130 | other_values: [ "landscape", "portrait", "8.5in 11in", "14in 11in", "297mm 210mm", "21cm 29.7cm", "100mm" ], |
michael@0 | 3131 | invalid_values: [ |
michael@0 | 3132 | // XXX spec unclear on 0s and negatives |
michael@0 | 3133 | "100mm 100mm 100mm" |
michael@0 | 3134 | ] |
michael@0 | 3135 | }, |
michael@0 | 3136 | "table-layout": { |
michael@0 | 3137 | domProp: "tableLayout", |
michael@0 | 3138 | inherited: false, |
michael@0 | 3139 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3140 | initial_values: [ "auto" ], |
michael@0 | 3141 | other_values: [ "fixed" ], |
michael@0 | 3142 | invalid_values: [] |
michael@0 | 3143 | }, |
michael@0 | 3144 | "text-align": { |
michael@0 | 3145 | domProp: "textAlign", |
michael@0 | 3146 | inherited: true, |
michael@0 | 3147 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3148 | // don't know whether left and right are same as start |
michael@0 | 3149 | initial_values: [ "start" ], |
michael@0 | 3150 | other_values: [ "center", "justify", "end" ], |
michael@0 | 3151 | invalid_values: [ "true", "true true" ] |
michael@0 | 3152 | }, |
michael@0 | 3153 | "-moz-text-align-last": { |
michael@0 | 3154 | domProp: "MozTextAlignLast", |
michael@0 | 3155 | inherited: true, |
michael@0 | 3156 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3157 | initial_values: [ "auto" ], |
michael@0 | 3158 | other_values: [ "center", "justify", "start", "end", "left", "right" ], |
michael@0 | 3159 | invalid_values: [] |
michael@0 | 3160 | }, |
michael@0 | 3161 | "text-decoration": { |
michael@0 | 3162 | domProp: "textDecoration", |
michael@0 | 3163 | inherited: false, |
michael@0 | 3164 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 3165 | subproperties: [ "-moz-text-decoration-color", "-moz-text-decoration-line", "-moz-text-decoration-style" ], |
michael@0 | 3166 | initial_values: [ "none" ], |
michael@0 | 3167 | other_values: [ "underline", "overline", "line-through", "blink", "blink line-through underline", "underline overline line-through blink", "-moz-anchor-decoration", "blink -moz-anchor-decoration" ], |
michael@0 | 3168 | invalid_values: [ "none none", "underline none", "none underline", "blink none", "none blink", "line-through blink line-through", "underline overline line-through blink none", "underline overline line-throuh blink blink", |
michael@0 | 3169 | "underline red solid", "underline #ff0000", "solid underline", "red underline", "#ff0000 underline" ] |
michael@0 | 3170 | }, |
michael@0 | 3171 | "-moz-text-decoration-color": { |
michael@0 | 3172 | domProp: "MozTextDecorationColor", |
michael@0 | 3173 | inherited: false, |
michael@0 | 3174 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3175 | prerequisites: { "color": "black" }, |
michael@0 | 3176 | initial_values: [ "currentColor", "-moz-use-text-color" ], |
michael@0 | 3177 | other_values: [ "green", "rgba(255,128,0,0.5)", "transparent" ], |
michael@0 | 3178 | invalid_values: [ "#0", "#00", "#0000", "#00000", "#0000000", "#00000000", "#000000000", "000000", "ff00ff" ] |
michael@0 | 3179 | }, |
michael@0 | 3180 | "-moz-text-decoration-line": { |
michael@0 | 3181 | domProp: "MozTextDecorationLine", |
michael@0 | 3182 | inherited: false, |
michael@0 | 3183 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3184 | initial_values: [ "none" ], |
michael@0 | 3185 | other_values: [ "underline", "overline", "line-through", "blink", "blink line-through underline", "underline overline line-through blink", "-moz-anchor-decoration", "blink -moz-anchor-decoration" ], |
michael@0 | 3186 | invalid_values: [ "none none", "underline none", "none underline", "line-through blink line-through", "underline overline line-through blink none", "underline overline line-throuh blink blink" ] |
michael@0 | 3187 | }, |
michael@0 | 3188 | "-moz-text-decoration-style": { |
michael@0 | 3189 | domProp: "MozTextDecorationStyle", |
michael@0 | 3190 | inherited: false, |
michael@0 | 3191 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3192 | initial_values: [ "solid" ], |
michael@0 | 3193 | other_values: [ "double", "dotted", "dashed", "wavy", "-moz-none" ], |
michael@0 | 3194 | invalid_values: [ "none", "groove", "ridge", "inset", "outset", "solid dashed", "wave" ] |
michael@0 | 3195 | }, |
michael@0 | 3196 | "text-indent": { |
michael@0 | 3197 | domProp: "textIndent", |
michael@0 | 3198 | inherited: true, |
michael@0 | 3199 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3200 | initial_values: [ "0", "calc(3em - 5em + 2px + 2em - 2px)" ], |
michael@0 | 3201 | other_values: [ "2em", "5%", "-10px", |
michael@0 | 3202 | "calc(2px)", |
michael@0 | 3203 | "calc(-2px)", |
michael@0 | 3204 | "calc(50%)", |
michael@0 | 3205 | "calc(3*25px)", |
michael@0 | 3206 | "calc(25px*3)", |
michael@0 | 3207 | "calc(3*25px + 50%)", |
michael@0 | 3208 | ], |
michael@0 | 3209 | invalid_values: [ "5" ] |
michael@0 | 3210 | }, |
michael@0 | 3211 | "text-overflow": { |
michael@0 | 3212 | domProp: "textOverflow", |
michael@0 | 3213 | inherited: false, |
michael@0 | 3214 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3215 | initial_values: [ "clip" ], |
michael@0 | 3216 | other_values: [ "ellipsis", '""', "''", '"hello"', 'clip clip', 'ellipsis ellipsis', 'clip ellipsis', 'clip ""', '"hello" ""', '"" ellipsis' ], |
michael@0 | 3217 | invalid_values: [ "none", "auto", '"hello" inherit', 'inherit "hello"', 'clip initial', 'initial clip', 'initial inherit', 'inherit initial', 'inherit none'] |
michael@0 | 3218 | }, |
michael@0 | 3219 | "text-shadow": { |
michael@0 | 3220 | domProp: "textShadow", |
michael@0 | 3221 | inherited: true, |
michael@0 | 3222 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3223 | prerequisites: { "color": "blue" }, |
michael@0 | 3224 | initial_values: [ "none" ], |
michael@0 | 3225 | other_values: [ "2px 2px", "2px 2px 1px", "2px 2px green", "2px 2px 1px green", "green 2px 2px", "green 2px 2px 1px", "green 2px 2px, blue 1px 3px 4px", "currentColor 3px 3px", "blue 2px 2px, currentColor 1px 2px", |
michael@0 | 3226 | /* calc() values */ |
michael@0 | 3227 | "2px 2px calc(-5px)", /* clamped */ |
michael@0 | 3228 | "calc(3em - 2px) 2px green", |
michael@0 | 3229 | "green calc(3em - 2px) 2px", |
michael@0 | 3230 | "2px calc(2px + 0.2em)", |
michael@0 | 3231 | "blue 2px calc(2px + 0.2em)", |
michael@0 | 3232 | "2px calc(2px + 0.2em) blue", |
michael@0 | 3233 | "calc(-2px) calc(-2px)", |
michael@0 | 3234 | "-2px -2px", |
michael@0 | 3235 | "calc(2px) calc(2px)", |
michael@0 | 3236 | "calc(2px) calc(2px) calc(2px)", |
michael@0 | 3237 | ], |
michael@0 | 3238 | invalid_values: [ "3% 3%", "2px 2px -5px", "2px 2px 2px 2px", "2px 2px, none", "none, 2px 2px", "inherit, 2px 2px", "2px 2px, inherit", "2 2px", "2px 2", "2px 2px 2", "2px 2px 2px 2", |
michael@0 | 3239 | "calc(2px) calc(2px) calc(2px) calc(2px)" |
michael@0 | 3240 | ] |
michael@0 | 3241 | }, |
michael@0 | 3242 | "text-transform": { |
michael@0 | 3243 | domProp: "textTransform", |
michael@0 | 3244 | inherited: true, |
michael@0 | 3245 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3246 | initial_values: [ "none" ], |
michael@0 | 3247 | other_values: [ "capitalize", "uppercase", "lowercase", "full-width" ], |
michael@0 | 3248 | invalid_values: [] |
michael@0 | 3249 | }, |
michael@0 | 3250 | "top": { |
michael@0 | 3251 | domProp: "top", |
michael@0 | 3252 | inherited: false, |
michael@0 | 3253 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3254 | /* FIXME: run tests with multiple prerequisites */ |
michael@0 | 3255 | prerequisites: { "position": "relative" }, |
michael@0 | 3256 | /* XXX 0 may or may not be equal to auto */ |
michael@0 | 3257 | initial_values: [ "auto" ], |
michael@0 | 3258 | other_values: [ "32px", "-3em", "12%", |
michael@0 | 3259 | "calc(2px)", |
michael@0 | 3260 | "calc(-2px)", |
michael@0 | 3261 | "calc(50%)", |
michael@0 | 3262 | "calc(3*25px)", |
michael@0 | 3263 | "calc(25px*3)", |
michael@0 | 3264 | "calc(3*25px + 50%)", |
michael@0 | 3265 | ], |
michael@0 | 3266 | invalid_values: [], |
michael@0 | 3267 | quirks_values: { "5": "5px" }, |
michael@0 | 3268 | }, |
michael@0 | 3269 | "transition": { |
michael@0 | 3270 | domProp: "transition", |
michael@0 | 3271 | inherited: false, |
michael@0 | 3272 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 3273 | subproperties: [ "transition-property", "transition-duration", "transition-timing-function", "transition-delay" ], |
michael@0 | 3274 | initial_values: [ "all 0s ease 0s", "all", "0s", "0s 0s", "ease" ], |
michael@0 | 3275 | other_values: [ "width 1s linear 2s", "width 1s 2s linear", "width linear 1s 2s", "linear width 1s 2s", "linear 1s width 2s", "linear 1s 2s width", "1s width linear 2s", "1s width 2s linear", "1s 2s width linear", "1s linear width 2s", "1s linear 2s width", "1s 2s linear width", "width linear 1s", "width 1s linear", "linear width 1s", "linear 1s width", "1s width linear", "1s linear width", "1s 2s width", "1s width 2s", "width 1s 2s", "1s 2s linear", "1s linear 2s", "linear 1s 2s", "width 1s", "1s width", "linear 1s", "1s linear", "1s 2s", "2s 1s", "width", "linear", "1s", "height", "2s", "ease-in-out", "2s ease-in", "opacity linear", "ease-out 2s", "2s color, 1s width, 500ms height linear, 1s opacity 4s cubic-bezier(0.0, 0.1, 1.0, 1.0)", "1s \\32width linear 2s", "1s -width linear 2s", "1s -\\32width linear 2s", "1s \\32 0width linear 2s", "1s -\\32 0width linear 2s", "1s \\2width linear 2s", "1s -\\2width linear 2s", "2s, 1s width", "1s width, 2s", "2s all, 1s width", "1s width, 2s all", "2s all, 1s width", "2s width, 1s all" ], |
michael@0 | 3276 | invalid_values: [ "1s width, 2s none", "2s none, 1s width", "2s inherit", "inherit 2s", "2s width, 1s inherit", "2s inherit, 1s width", "2s initial", "1s width,,2s color", "1s width, ,2s color" ] |
michael@0 | 3277 | }, |
michael@0 | 3278 | "transition-delay": { |
michael@0 | 3279 | domProp: "transitionDelay", |
michael@0 | 3280 | inherited: false, |
michael@0 | 3281 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3282 | initial_values: [ "0s", "0ms" ], |
michael@0 | 3283 | other_values: [ "1s", "250ms", "-100ms", "-1s", "1s, 250ms, 2.3s"], |
michael@0 | 3284 | invalid_values: [ "0", "0px" ] |
michael@0 | 3285 | }, |
michael@0 | 3286 | "transition-duration": { |
michael@0 | 3287 | domProp: "transitionDuration", |
michael@0 | 3288 | inherited: false, |
michael@0 | 3289 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3290 | initial_values: [ "0s", "0ms" ], |
michael@0 | 3291 | other_values: [ "1s", "250ms", "1s, 250ms, 2.3s"], |
michael@0 | 3292 | invalid_values: [ "0", "0px", "-1ms", "-2s" ] |
michael@0 | 3293 | }, |
michael@0 | 3294 | "transition-property": { |
michael@0 | 3295 | domProp: "transitionProperty", |
michael@0 | 3296 | inherited: false, |
michael@0 | 3297 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3298 | initial_values: [ "all" ], |
michael@0 | 3299 | other_values: [ "none", "left", "top", "color", "width, height, opacity", "foobar", "auto", "\\32width", "-width", "-\\32width", "\\32 0width", "-\\32 0width", "\\2width", "-\\2width", "all, all", "all, color", "color, all" ], |
michael@0 | 3300 | invalid_values: [ "none, none", "color, none", "none, color", "inherit, color", "color, inherit", "initial, color", "color, initial", "none, color", "color, none" ] |
michael@0 | 3301 | }, |
michael@0 | 3302 | "transition-timing-function": { |
michael@0 | 3303 | domProp: "transitionTimingFunction", |
michael@0 | 3304 | inherited: false, |
michael@0 | 3305 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3306 | initial_values: [ "ease", "cubic-bezier(0.25, 0.1, 0.25, 1.0)" ], |
michael@0 | 3307 | other_values: [ "linear", "ease-in", "ease-out", "ease-in-out", "linear, ease-in, cubic-bezier(0.1, 0.2, 0.8, 0.9)", "cubic-bezier(0.5, 0.5, 0.5, 0.5)", "cubic-bezier(0.25, 1.5, 0.75, -0.5)", "step-start", "step-end", "steps(1)", "steps(2, start)", "steps(386)", "steps(3, end)" ], |
michael@0 | 3308 | invalid_values: [ "none", "auto", "cubic-bezier(0.25, 0.1, 0.25)", "cubic-bezier(0.25, 0.1, 0.25, 0.25, 1.0)", "cubic-bezier(-0.5, 0.5, 0.5, 0.5)", "cubic-bezier(1.5, 0.5, 0.5, 0.5)", "cubic-bezier(0.5, 0.5, -0.5, 0.5)", "cubic-bezier(0.5, 0.5, 1.5, 0.5)", "steps(2, step-end)", "steps(0)", "steps(-2)", "steps(0, step-end, 1)" ] |
michael@0 | 3309 | }, |
michael@0 | 3310 | "unicode-bidi": { |
michael@0 | 3311 | domProp: "unicodeBidi", |
michael@0 | 3312 | inherited: false, |
michael@0 | 3313 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3314 | initial_values: [ "normal" ], |
michael@0 | 3315 | other_values: [ "embed", "bidi-override", "-moz-isolate", "-moz-plaintext", "-moz-isolate-override" ], |
michael@0 | 3316 | invalid_values: [ "auto", "none" ] |
michael@0 | 3317 | }, |
michael@0 | 3318 | "vertical-align": { |
michael@0 | 3319 | domProp: "verticalAlign", |
michael@0 | 3320 | inherited: false, |
michael@0 | 3321 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3322 | initial_values: [ "baseline" ], |
michael@0 | 3323 | other_values: [ "sub", "super", "top", "text-top", "middle", "bottom", "text-bottom", "-moz-middle-with-baseline", "15%", "3px", "0.2em", "-5px", "-3%", |
michael@0 | 3324 | "calc(2px)", |
michael@0 | 3325 | "calc(-2px)", |
michael@0 | 3326 | "calc(50%)", |
michael@0 | 3327 | "calc(3*25px)", |
michael@0 | 3328 | "calc(25px*3)", |
michael@0 | 3329 | "calc(3*25px + 50%)", |
michael@0 | 3330 | ], |
michael@0 | 3331 | invalid_values: [ "5" ] |
michael@0 | 3332 | }, |
michael@0 | 3333 | "visibility": { |
michael@0 | 3334 | domProp: "visibility", |
michael@0 | 3335 | inherited: true, |
michael@0 | 3336 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3337 | initial_values: [ "visible" ], |
michael@0 | 3338 | other_values: [ "hidden", "collapse" ], |
michael@0 | 3339 | invalid_values: [] |
michael@0 | 3340 | }, |
michael@0 | 3341 | "white-space": { |
michael@0 | 3342 | domProp: "whiteSpace", |
michael@0 | 3343 | inherited: true, |
michael@0 | 3344 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3345 | initial_values: [ "normal" ], |
michael@0 | 3346 | other_values: [ "pre", "nowrap", "pre-wrap", "pre-line", "-moz-pre-discard-newlines" ], |
michael@0 | 3347 | invalid_values: [] |
michael@0 | 3348 | }, |
michael@0 | 3349 | "widows": { |
michael@0 | 3350 | domProp: "widows", |
michael@0 | 3351 | inherited: true, |
michael@0 | 3352 | backend_only: true, |
michael@0 | 3353 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3354 | // XXX requires display:block |
michael@0 | 3355 | initial_values: [ "2" ], |
michael@0 | 3356 | other_values: [ "1", "7" ], |
michael@0 | 3357 | invalid_values: [ "0", "-1", "0px", "3px", "3e1" ] |
michael@0 | 3358 | }, |
michael@0 | 3359 | "width": { |
michael@0 | 3360 | domProp: "width", |
michael@0 | 3361 | inherited: false, |
michael@0 | 3362 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3363 | /* computed value tests for width test more with display:block */ |
michael@0 | 3364 | prerequisites: { "display": "block" }, |
michael@0 | 3365 | initial_values: [ " auto" ], |
michael@0 | 3366 | /* XXX these have prerequisites */ |
michael@0 | 3367 | other_values: [ "15px", "3em", "15%", "-moz-max-content", "-moz-min-content", "-moz-fit-content", "-moz-available", |
michael@0 | 3368 | "3e1px", "3e+1px", "3e0px", "3e+0px", "3e-0px", "3e-1px", |
michael@0 | 3369 | "3.2e1px", "3.2e+1px", "3.2e0px", "3.2e+0px", "3.2e-0px", "3.2e-1px", |
michael@0 | 3370 | "3e1%", "3e+1%", "3e0%", "3e+0%", "3e-0%", "3e-1%", |
michael@0 | 3371 | "3.2e1%", "3.2e+1%", "3.2e0%", "3.2e+0%", "3.2e-0%", "3.2e-1%", |
michael@0 | 3372 | /* valid -moz-calc() values */ |
michael@0 | 3373 | "-moz-calc(-2px)", |
michael@0 | 3374 | "-moz-calc(2px)", |
michael@0 | 3375 | "-moz-calc(50%)", |
michael@0 | 3376 | "-moz-calc(50% + 2px)", |
michael@0 | 3377 | "-moz-calc( 50% + 2px)", |
michael@0 | 3378 | "-moz-calc(50% + 2px )", |
michael@0 | 3379 | "-moz-calc( 50% + 2px )", |
michael@0 | 3380 | "-moz-calc(50% - -2px)", |
michael@0 | 3381 | "-moz-calc(2px - -50%)", |
michael@0 | 3382 | "-moz-calc(3*25px)", |
michael@0 | 3383 | "-moz-calc(3 *25px)", |
michael@0 | 3384 | "-moz-calc(3 * 25px)", |
michael@0 | 3385 | "-moz-calc(3* 25px)", |
michael@0 | 3386 | "-moz-calc(25px*3)", |
michael@0 | 3387 | "-moz-calc(25px *3)", |
michael@0 | 3388 | "-moz-calc(25px* 3)", |
michael@0 | 3389 | "-moz-calc(25px * 3)", |
michael@0 | 3390 | "-moz-calc(3*25px + 50%)", |
michael@0 | 3391 | "-moz-calc(50% - 3em + 2px)", |
michael@0 | 3392 | "-moz-calc(50% - (3em + 2px))", |
michael@0 | 3393 | "-moz-calc((50% - 3em) + 2px)", |
michael@0 | 3394 | "-moz-calc(2em)", |
michael@0 | 3395 | "-moz-calc(50%)", |
michael@0 | 3396 | "-moz-calc(50px/2)", |
michael@0 | 3397 | "-moz-calc(50px/(2 - 1))", |
michael@0 | 3398 | /* valid calc() values */ |
michael@0 | 3399 | "calc(-2px)", |
michael@0 | 3400 | "calc(2px)", |
michael@0 | 3401 | "calc(50%)", |
michael@0 | 3402 | "calc(50% + 2px)", |
michael@0 | 3403 | "calc( 50% + 2px)", |
michael@0 | 3404 | "calc(50% + 2px )", |
michael@0 | 3405 | "calc( 50% + 2px )", |
michael@0 | 3406 | "calc(50% - -2px)", |
michael@0 | 3407 | "calc(2px - -50%)", |
michael@0 | 3408 | "calc(3*25px)", |
michael@0 | 3409 | "calc(3 *25px)", |
michael@0 | 3410 | "calc(3 * 25px)", |
michael@0 | 3411 | "calc(3* 25px)", |
michael@0 | 3412 | "calc(25px*3)", |
michael@0 | 3413 | "calc(25px *3)", |
michael@0 | 3414 | "calc(25px* 3)", |
michael@0 | 3415 | "calc(25px * 3)", |
michael@0 | 3416 | "calc(3*25px + 50%)", |
michael@0 | 3417 | "calc(50% - 3em + 2px)", |
michael@0 | 3418 | "calc(50% - (3em + 2px))", |
michael@0 | 3419 | "calc((50% - 3em) + 2px)", |
michael@0 | 3420 | "calc(2em)", |
michael@0 | 3421 | "calc(50%)", |
michael@0 | 3422 | "calc(50px/2)", |
michael@0 | 3423 | "calc(50px/(2 - 1))", |
michael@0 | 3424 | ], |
michael@0 | 3425 | invalid_values: [ "none", "-2px", |
michael@0 | 3426 | /* invalid -moz-calc() values */ |
michael@0 | 3427 | "-moz-calc(50%+ 2px)", |
michael@0 | 3428 | "-moz-calc(50% +2px)", |
michael@0 | 3429 | "-moz-calc(50%+2px)", |
michael@0 | 3430 | /* invalid calc() values */ |
michael@0 | 3431 | "calc(50%+ 2px)", |
michael@0 | 3432 | "calc(50% +2px)", |
michael@0 | 3433 | "calc(50%+2px)", |
michael@0 | 3434 | "-moz-min()", |
michael@0 | 3435 | "calc(min())", |
michael@0 | 3436 | "-moz-max()", |
michael@0 | 3437 | "calc(max())", |
michael@0 | 3438 | "-moz-min(5px)", |
michael@0 | 3439 | "calc(min(5px))", |
michael@0 | 3440 | "-moz-max(5px)", |
michael@0 | 3441 | "calc(max(5px))", |
michael@0 | 3442 | "-moz-min(5px,2em)", |
michael@0 | 3443 | "calc(min(5px,2em))", |
michael@0 | 3444 | "-moz-max(5px,2em)", |
michael@0 | 3445 | "calc(max(5px,2em))", |
michael@0 | 3446 | "calc(50px/(2 - 2))", |
michael@0 | 3447 | /* If we ever support division by values, which is |
michael@0 | 3448 | * complicated for the reasons described in |
michael@0 | 3449 | * http://lists.w3.org/Archives/Public/www-style/2010Jan/0007.html |
michael@0 | 3450 | * , we should support all 4 of these as described in |
michael@0 | 3451 | * http://lists.w3.org/Archives/Public/www-style/2009Dec/0296.html |
michael@0 | 3452 | */ |
michael@0 | 3453 | "calc((3em / 100%) * 3em)", |
michael@0 | 3454 | "calc(3em / 100% * 3em)", |
michael@0 | 3455 | "calc(3em * (3em / 100%))", |
michael@0 | 3456 | "calc(3em * 3em / 100%)", |
michael@0 | 3457 | ], |
michael@0 | 3458 | quirks_values: { "5": "5px" }, |
michael@0 | 3459 | }, |
michael@0 | 3460 | "word-break": { |
michael@0 | 3461 | domProp: "wordBreak", |
michael@0 | 3462 | inherited: true, |
michael@0 | 3463 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3464 | initial_values: [ "normal" ], |
michael@0 | 3465 | other_values: [ "break-all", "keep-all" ], |
michael@0 | 3466 | invalid_values: [] |
michael@0 | 3467 | }, |
michael@0 | 3468 | "word-spacing": { |
michael@0 | 3469 | domProp: "wordSpacing", |
michael@0 | 3470 | inherited: true, |
michael@0 | 3471 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3472 | initial_values: [ "normal", "0", "0px", "-0em", |
michael@0 | 3473 | "calc(-0px)", "calc(0em)" |
michael@0 | 3474 | ], |
michael@0 | 3475 | other_values: [ "1em", "2px", "-3px", |
michael@0 | 3476 | "calc(1em)", "calc(1em + 3px)", |
michael@0 | 3477 | "calc(15px / 2)", "calc(15px/2)", |
michael@0 | 3478 | "calc(-2em)" |
michael@0 | 3479 | ], |
michael@0 | 3480 | invalid_values: [], |
michael@0 | 3481 | quirks_values: { "5": "5px" }, |
michael@0 | 3482 | }, |
michael@0 | 3483 | "word-wrap": { |
michael@0 | 3484 | domProp: "wordWrap", |
michael@0 | 3485 | inherited: true, |
michael@0 | 3486 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3487 | initial_values: [ "normal" ], |
michael@0 | 3488 | other_values: [ "break-word" ], |
michael@0 | 3489 | invalid_values: [] |
michael@0 | 3490 | }, |
michael@0 | 3491 | "-moz-hyphens": { |
michael@0 | 3492 | domProp: "MozHyphens", |
michael@0 | 3493 | inherited: true, |
michael@0 | 3494 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3495 | initial_values: [ "manual" ], |
michael@0 | 3496 | other_values: [ "none", "auto" ], |
michael@0 | 3497 | invalid_values: [] |
michael@0 | 3498 | }, |
michael@0 | 3499 | "z-index": { |
michael@0 | 3500 | domProp: "zIndex", |
michael@0 | 3501 | inherited: false, |
michael@0 | 3502 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3503 | /* XXX requires position */ |
michael@0 | 3504 | initial_values: [ "auto" ], |
michael@0 | 3505 | other_values: [ "0", "3", "-7000", "12000" ], |
michael@0 | 3506 | invalid_values: [ "3.0", "17.5", "3e1" ] |
michael@0 | 3507 | } |
michael@0 | 3508 | , |
michael@0 | 3509 | "clip-path": { |
michael@0 | 3510 | domProp: "clipPath", |
michael@0 | 3511 | inherited: false, |
michael@0 | 3512 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3513 | initial_values: [ "none" ], |
michael@0 | 3514 | other_values: [ "url(#mypath)", "url('404.svg#mypath')" ], |
michael@0 | 3515 | invalid_values: [] |
michael@0 | 3516 | }, |
michael@0 | 3517 | "clip-rule": { |
michael@0 | 3518 | domProp: "clipRule", |
michael@0 | 3519 | inherited: true, |
michael@0 | 3520 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3521 | initial_values: [ "nonzero" ], |
michael@0 | 3522 | other_values: [ "evenodd" ], |
michael@0 | 3523 | invalid_values: [] |
michael@0 | 3524 | }, |
michael@0 | 3525 | "color-interpolation": { |
michael@0 | 3526 | domProp: "colorInterpolation", |
michael@0 | 3527 | inherited: true, |
michael@0 | 3528 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3529 | initial_values: [ "sRGB" ], |
michael@0 | 3530 | other_values: [ "auto", "linearRGB" ], |
michael@0 | 3531 | invalid_values: [] |
michael@0 | 3532 | }, |
michael@0 | 3533 | "color-interpolation-filters": { |
michael@0 | 3534 | domProp: "colorInterpolationFilters", |
michael@0 | 3535 | inherited: true, |
michael@0 | 3536 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3537 | initial_values: [ "linearRGB" ], |
michael@0 | 3538 | other_values: [ "sRGB", "auto" ], |
michael@0 | 3539 | invalid_values: [] |
michael@0 | 3540 | }, |
michael@0 | 3541 | "dominant-baseline": { |
michael@0 | 3542 | domProp: "dominantBaseline", |
michael@0 | 3543 | inherited: false, |
michael@0 | 3544 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3545 | initial_values: [ "auto" ], |
michael@0 | 3546 | other_values: [ "use-script", "no-change", "reset-size", "ideographic", "alphabetic", "hanging", "mathematical", "central", "middle", "text-after-edge", "text-before-edge" ], |
michael@0 | 3547 | invalid_values: [] |
michael@0 | 3548 | }, |
michael@0 | 3549 | "fill": { |
michael@0 | 3550 | domProp: "fill", |
michael@0 | 3551 | inherited: true, |
michael@0 | 3552 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3553 | prerequisites: { "color": "blue" }, |
michael@0 | 3554 | initial_values: [ "black", "#000", "#000000", "rgb(0,0,0)", "rgba(0,0,0,1)" ], |
michael@0 | 3555 | other_values: [ "green", "#fc3", "url('#myserver')", "url(foo.svg#myserver)", 'url("#myserver") green', "none", "currentColor", "context-fill", "context-stroke" ], |
michael@0 | 3556 | invalid_values: [ "000000", "ff00ff" ] |
michael@0 | 3557 | }, |
michael@0 | 3558 | "fill-opacity": { |
michael@0 | 3559 | domProp: "fillOpacity", |
michael@0 | 3560 | inherited: true, |
michael@0 | 3561 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3562 | initial_values: [ "1", "2.8", "1.000", "context-fill-opacity", "context-stroke-opacity" ], |
michael@0 | 3563 | other_values: [ "0", "0.3", "-7.3" ], |
michael@0 | 3564 | invalid_values: [] |
michael@0 | 3565 | }, |
michael@0 | 3566 | "fill-rule": { |
michael@0 | 3567 | domProp: "fillRule", |
michael@0 | 3568 | inherited: true, |
michael@0 | 3569 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3570 | initial_values: [ "nonzero" ], |
michael@0 | 3571 | other_values: [ "evenodd" ], |
michael@0 | 3572 | invalid_values: [] |
michael@0 | 3573 | }, |
michael@0 | 3574 | "filter": { |
michael@0 | 3575 | domProp: "filter", |
michael@0 | 3576 | inherited: false, |
michael@0 | 3577 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3578 | initial_values: [ "none" ], |
michael@0 | 3579 | other_values: [ "url(#myfilt)" ], |
michael@0 | 3580 | invalid_values: [ "url(#myfilt) none" ] |
michael@0 | 3581 | }, |
michael@0 | 3582 | "flood-color": { |
michael@0 | 3583 | domProp: "floodColor", |
michael@0 | 3584 | inherited: false, |
michael@0 | 3585 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3586 | prerequisites: { "color": "blue" }, |
michael@0 | 3587 | initial_values: [ "black", "#000", "#000000", "rgb(0,0,0)", "rgba(0,0,0,1)" ], |
michael@0 | 3588 | other_values: [ "green", "#fc3", "currentColor" ], |
michael@0 | 3589 | invalid_values: [ "url('#myserver')", "url(foo.svg#myserver)", 'url("#myserver") green', "000000", "ff00ff" ] |
michael@0 | 3590 | }, |
michael@0 | 3591 | "flood-opacity": { |
michael@0 | 3592 | domProp: "floodOpacity", |
michael@0 | 3593 | inherited: false, |
michael@0 | 3594 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3595 | initial_values: [ "1", "2.8", "1.000" ], |
michael@0 | 3596 | other_values: [ "0", "0.3", "-7.3" ], |
michael@0 | 3597 | invalid_values: [] |
michael@0 | 3598 | }, |
michael@0 | 3599 | "image-rendering": { |
michael@0 | 3600 | domProp: "imageRendering", |
michael@0 | 3601 | inherited: true, |
michael@0 | 3602 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3603 | initial_values: [ "auto" ], |
michael@0 | 3604 | other_values: [ "optimizeSpeed", "optimizeQuality", "-moz-crisp-edges" ], |
michael@0 | 3605 | invalid_values: [] |
michael@0 | 3606 | }, |
michael@0 | 3607 | "lighting-color": { |
michael@0 | 3608 | domProp: "lightingColor", |
michael@0 | 3609 | inherited: false, |
michael@0 | 3610 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3611 | prerequisites: { "color": "blue" }, |
michael@0 | 3612 | initial_values: [ "white", "#fff", "#ffffff", "rgb(255,255,255)", "rgba(255,255,255,1.0)", "rgba(255,255,255,42.0)" ], |
michael@0 | 3613 | other_values: [ "green", "#fc3", "currentColor" ], |
michael@0 | 3614 | invalid_values: [ "url('#myserver')", "url(foo.svg#myserver)", 'url("#myserver") green', "000000", "ff00ff" ] |
michael@0 | 3615 | }, |
michael@0 | 3616 | "marker": { |
michael@0 | 3617 | domProp: "marker", |
michael@0 | 3618 | inherited: true, |
michael@0 | 3619 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 3620 | subproperties: [ "marker-start", "marker-mid", "marker-end" ], |
michael@0 | 3621 | initial_values: [ "none" ], |
michael@0 | 3622 | other_values: [ "url(#mysym)" ], |
michael@0 | 3623 | invalid_values: [ "none none", "url(#mysym) url(#mysym)", "none url(#mysym)", "url(#mysym) none" ] |
michael@0 | 3624 | }, |
michael@0 | 3625 | "marker-end": { |
michael@0 | 3626 | domProp: "markerEnd", |
michael@0 | 3627 | inherited: true, |
michael@0 | 3628 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3629 | initial_values: [ "none" ], |
michael@0 | 3630 | other_values: [ "url(#mysym)" ], |
michael@0 | 3631 | invalid_values: [] |
michael@0 | 3632 | }, |
michael@0 | 3633 | "marker-mid": { |
michael@0 | 3634 | domProp: "markerMid", |
michael@0 | 3635 | inherited: true, |
michael@0 | 3636 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3637 | initial_values: [ "none" ], |
michael@0 | 3638 | other_values: [ "url(#mysym)" ], |
michael@0 | 3639 | invalid_values: [] |
michael@0 | 3640 | }, |
michael@0 | 3641 | "marker-start": { |
michael@0 | 3642 | domProp: "markerStart", |
michael@0 | 3643 | inherited: true, |
michael@0 | 3644 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3645 | initial_values: [ "none" ], |
michael@0 | 3646 | other_values: [ "url(#mysym)" ], |
michael@0 | 3647 | invalid_values: [] |
michael@0 | 3648 | }, |
michael@0 | 3649 | "mask": { |
michael@0 | 3650 | domProp: "mask", |
michael@0 | 3651 | inherited: false, |
michael@0 | 3652 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3653 | initial_values: [ "none" ], |
michael@0 | 3654 | other_values: [ "url(#mymask)" ], |
michael@0 | 3655 | invalid_values: [] |
michael@0 | 3656 | }, |
michael@0 | 3657 | "shape-rendering": { |
michael@0 | 3658 | domProp: "shapeRendering", |
michael@0 | 3659 | inherited: true, |
michael@0 | 3660 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3661 | initial_values: [ "auto" ], |
michael@0 | 3662 | other_values: [ "optimizeSpeed", "crispEdges", "geometricPrecision" ], |
michael@0 | 3663 | invalid_values: [] |
michael@0 | 3664 | }, |
michael@0 | 3665 | "stop-color": { |
michael@0 | 3666 | domProp: "stopColor", |
michael@0 | 3667 | inherited: false, |
michael@0 | 3668 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3669 | prerequisites: { "color": "blue" }, |
michael@0 | 3670 | initial_values: [ "black", "#000", "#000000", "rgb(0,0,0)", "rgba(0,0,0,1)" ], |
michael@0 | 3671 | other_values: [ "green", "#fc3", "currentColor" ], |
michael@0 | 3672 | invalid_values: [ "url('#myserver')", "url(foo.svg#myserver)", 'url("#myserver") green', "000000", "ff00ff" ] |
michael@0 | 3673 | }, |
michael@0 | 3674 | "stop-opacity": { |
michael@0 | 3675 | domProp: "stopOpacity", |
michael@0 | 3676 | inherited: false, |
michael@0 | 3677 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3678 | initial_values: [ "1", "2.8", "1.000" ], |
michael@0 | 3679 | other_values: [ "0", "0.3", "-7.3" ], |
michael@0 | 3680 | invalid_values: [] |
michael@0 | 3681 | }, |
michael@0 | 3682 | "stroke": { |
michael@0 | 3683 | domProp: "stroke", |
michael@0 | 3684 | inherited: true, |
michael@0 | 3685 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3686 | initial_values: [ "none" ], |
michael@0 | 3687 | other_values: [ "black", "#000", "#000000", "rgb(0,0,0)", "rgba(0,0,0,1)", "green", "#fc3", "url('#myserver')", "url(foo.svg#myserver)", 'url("#myserver") green', "currentColor", "context-fill", "context-stroke" ], |
michael@0 | 3688 | invalid_values: [ "000000", "ff00ff" ] |
michael@0 | 3689 | }, |
michael@0 | 3690 | "stroke-dasharray": { |
michael@0 | 3691 | domProp: "strokeDasharray", |
michael@0 | 3692 | inherited: true, |
michael@0 | 3693 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3694 | initial_values: [ "none", "context-value" ], |
michael@0 | 3695 | other_values: [ "5px,3px,2px", "5px 3px 2px", " 5px ,3px , 2px ", "1px", "5%", "3em" ], |
michael@0 | 3696 | invalid_values: [ "-5px,3px,2px", "5px,3px,-2px" ] |
michael@0 | 3697 | }, |
michael@0 | 3698 | "stroke-dashoffset": { |
michael@0 | 3699 | domProp: "strokeDashoffset", |
michael@0 | 3700 | inherited: true, |
michael@0 | 3701 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3702 | initial_values: [ "0", "-0px", "0em", "context-value" ], |
michael@0 | 3703 | other_values: [ "3px", "3%", "1em" ], |
michael@0 | 3704 | invalid_values: [] |
michael@0 | 3705 | }, |
michael@0 | 3706 | "stroke-linecap": { |
michael@0 | 3707 | domProp: "strokeLinecap", |
michael@0 | 3708 | inherited: true, |
michael@0 | 3709 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3710 | initial_values: [ "butt" ], |
michael@0 | 3711 | other_values: [ "round", "square" ], |
michael@0 | 3712 | invalid_values: [] |
michael@0 | 3713 | }, |
michael@0 | 3714 | "stroke-linejoin": { |
michael@0 | 3715 | domProp: "strokeLinejoin", |
michael@0 | 3716 | inherited: true, |
michael@0 | 3717 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3718 | initial_values: [ "miter" ], |
michael@0 | 3719 | other_values: [ "round", "bevel" ], |
michael@0 | 3720 | invalid_values: [] |
michael@0 | 3721 | }, |
michael@0 | 3722 | "stroke-miterlimit": { |
michael@0 | 3723 | domProp: "strokeMiterlimit", |
michael@0 | 3724 | inherited: true, |
michael@0 | 3725 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3726 | initial_values: [ "4" ], |
michael@0 | 3727 | other_values: [ "1", "7", "5000", "1.1" ], |
michael@0 | 3728 | invalid_values: [ "0.9", "0", "-1", "3px", "-0.3" ] |
michael@0 | 3729 | }, |
michael@0 | 3730 | "stroke-opacity": { |
michael@0 | 3731 | domProp: "strokeOpacity", |
michael@0 | 3732 | inherited: true, |
michael@0 | 3733 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3734 | initial_values: [ "1", "2.8", "1.000", "context-fill-opacity", "context-stroke-opacity" ], |
michael@0 | 3735 | other_values: [ "0", "0.3", "-7.3" ], |
michael@0 | 3736 | invalid_values: [] |
michael@0 | 3737 | }, |
michael@0 | 3738 | "stroke-width": { |
michael@0 | 3739 | domProp: "strokeWidth", |
michael@0 | 3740 | inherited: true, |
michael@0 | 3741 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3742 | initial_values: [ "1px", "context-value" ], |
michael@0 | 3743 | other_values: [ "0", "0px", "-0em", "17px", "0.2em" ], |
michael@0 | 3744 | invalid_values: [ "-0.1px", "-3px" ] |
michael@0 | 3745 | }, |
michael@0 | 3746 | "text-anchor": { |
michael@0 | 3747 | domProp: "textAnchor", |
michael@0 | 3748 | inherited: true, |
michael@0 | 3749 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3750 | initial_values: [ "start" ], |
michael@0 | 3751 | other_values: [ "middle", "end" ], |
michael@0 | 3752 | invalid_values: [] |
michael@0 | 3753 | }, |
michael@0 | 3754 | "text-rendering": { |
michael@0 | 3755 | domProp: "textRendering", |
michael@0 | 3756 | inherited: true, |
michael@0 | 3757 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3758 | initial_values: [ "auto" ], |
michael@0 | 3759 | other_values: [ "optimizeSpeed", "optimizeLegibility", "geometricPrecision" ], |
michael@0 | 3760 | invalid_values: [] |
michael@0 | 3761 | }, |
michael@0 | 3762 | "vector-effect": { |
michael@0 | 3763 | domProp: "vectorEffect", |
michael@0 | 3764 | inherited: false, |
michael@0 | 3765 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3766 | initial_values: [ "none" ], |
michael@0 | 3767 | other_values: [ "non-scaling-stroke" ], |
michael@0 | 3768 | invalid_values: [] |
michael@0 | 3769 | }, |
michael@0 | 3770 | "align-content": { |
michael@0 | 3771 | domProp: "alignContent", |
michael@0 | 3772 | inherited: false, |
michael@0 | 3773 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3774 | initial_values: [ "stretch" ], |
michael@0 | 3775 | other_values: [ |
michael@0 | 3776 | "flex-start", |
michael@0 | 3777 | "flex-end", |
michael@0 | 3778 | "center", |
michael@0 | 3779 | "space-between", |
michael@0 | 3780 | "space-around" |
michael@0 | 3781 | ], |
michael@0 | 3782 | invalid_values: [ "abc", "30px", "0", "auto" ] |
michael@0 | 3783 | }, |
michael@0 | 3784 | "align-items": { |
michael@0 | 3785 | domProp: "alignItems", |
michael@0 | 3786 | inherited: false, |
michael@0 | 3787 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3788 | initial_values: [ "stretch" ], |
michael@0 | 3789 | other_values: [ "flex-start", "flex-end", "center", "baseline" ], |
michael@0 | 3790 | invalid_values: [ "space-between", "abc", "30px" ] |
michael@0 | 3791 | }, |
michael@0 | 3792 | "align-self": { |
michael@0 | 3793 | domProp: "alignSelf", |
michael@0 | 3794 | inherited: false, |
michael@0 | 3795 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3796 | // (Assuming defaults on the parent, 'auto' will compute to 'stretch'.) |
michael@0 | 3797 | initial_values: [ "auto", "stretch" ], |
michael@0 | 3798 | other_values: [ "flex-start", "flex-end", "center", "baseline" ], |
michael@0 | 3799 | invalid_values: [ "space-between", "abc", "30px" ] |
michael@0 | 3800 | }, |
michael@0 | 3801 | "flex": { |
michael@0 | 3802 | domProp: "flex", |
michael@0 | 3803 | inherited: false, |
michael@0 | 3804 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 3805 | subproperties: [ |
michael@0 | 3806 | "flex-grow", |
michael@0 | 3807 | "flex-shrink", |
michael@0 | 3808 | "flex-basis" |
michael@0 | 3809 | ], |
michael@0 | 3810 | initial_values: [ "0 1 auto", "auto 0 1", "0 auto", "auto 0" ], |
michael@0 | 3811 | other_values: [ |
michael@0 | 3812 | "none", |
michael@0 | 3813 | "1", |
michael@0 | 3814 | "0", |
michael@0 | 3815 | "0 1", |
michael@0 | 3816 | "0.5", |
michael@0 | 3817 | "1.2 3.4", |
michael@0 | 3818 | "0 0 0", |
michael@0 | 3819 | "0 0 0px", |
michael@0 | 3820 | "0px 0 0", |
michael@0 | 3821 | "5px 0 0", |
michael@0 | 3822 | "2 auto", |
michael@0 | 3823 | "auto 4", |
michael@0 | 3824 | "auto 5.6 7.8", |
michael@0 | 3825 | "-moz-max-content", |
michael@0 | 3826 | "1 -moz-max-content", |
michael@0 | 3827 | "1 2 -moz-max-content", |
michael@0 | 3828 | "-moz-max-content 1", |
michael@0 | 3829 | "-moz-max-content 1 2", |
michael@0 | 3830 | "-0" |
michael@0 | 3831 | ], |
michael@0 | 3832 | invalid_values: [ |
michael@0 | 3833 | "1 2px 3", |
michael@0 | 3834 | "1 auto 3", |
michael@0 | 3835 | "1px 2 3px", |
michael@0 | 3836 | "1px 2 3 4px", |
michael@0 | 3837 | "-1", |
michael@0 | 3838 | "1 -1" |
michael@0 | 3839 | ] |
michael@0 | 3840 | }, |
michael@0 | 3841 | "flex-basis": { |
michael@0 | 3842 | domProp: "flexBasis", |
michael@0 | 3843 | inherited: false, |
michael@0 | 3844 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3845 | initial_values: [ " auto" ], |
michael@0 | 3846 | // NOTE: This is cribbed directly from the "width" chunk, since this |
michael@0 | 3847 | // property takes the exact same values as width (albeit with |
michael@0 | 3848 | // different semantics on 'auto'). |
michael@0 | 3849 | // XXXdholbert (Maybe these should get separated out into |
michael@0 | 3850 | // a reusable array defined at the top of this file?) |
michael@0 | 3851 | other_values: [ "15px", "3em", "15%", "-moz-max-content", "-moz-min-content", "-moz-fit-content", "-moz-available", |
michael@0 | 3852 | // valid calc() values |
michael@0 | 3853 | "calc(-2px)", |
michael@0 | 3854 | "calc(2px)", |
michael@0 | 3855 | "calc(50%)", |
michael@0 | 3856 | "calc(50% + 2px)", |
michael@0 | 3857 | "calc( 50% + 2px)", |
michael@0 | 3858 | "calc(50% + 2px )", |
michael@0 | 3859 | "calc( 50% + 2px )", |
michael@0 | 3860 | "calc(50% - -2px)", |
michael@0 | 3861 | "calc(2px - -50%)", |
michael@0 | 3862 | "calc(3*25px)", |
michael@0 | 3863 | "calc(3 *25px)", |
michael@0 | 3864 | "calc(3 * 25px)", |
michael@0 | 3865 | "calc(3* 25px)", |
michael@0 | 3866 | "calc(25px*3)", |
michael@0 | 3867 | "calc(25px *3)", |
michael@0 | 3868 | "calc(25px* 3)", |
michael@0 | 3869 | "calc(25px * 3)", |
michael@0 | 3870 | "calc(3*25px + 50%)", |
michael@0 | 3871 | "calc(50% - 3em + 2px)", |
michael@0 | 3872 | "calc(50% - (3em + 2px))", |
michael@0 | 3873 | "calc((50% - 3em) + 2px)", |
michael@0 | 3874 | "calc(2em)", |
michael@0 | 3875 | "calc(50%)", |
michael@0 | 3876 | "calc(50px/2)", |
michael@0 | 3877 | "calc(50px/(2 - 1))" |
michael@0 | 3878 | ], |
michael@0 | 3879 | invalid_values: [ "none", "-2px", |
michael@0 | 3880 | // invalid calc() values |
michael@0 | 3881 | "calc(50%+ 2px)", |
michael@0 | 3882 | "calc(50% +2px)", |
michael@0 | 3883 | "calc(50%+2px)", |
michael@0 | 3884 | "-moz-min()", |
michael@0 | 3885 | "calc(min())", |
michael@0 | 3886 | "-moz-max()", |
michael@0 | 3887 | "calc(max())", |
michael@0 | 3888 | "-moz-min(5px)", |
michael@0 | 3889 | "calc(min(5px))", |
michael@0 | 3890 | "-moz-max(5px)", |
michael@0 | 3891 | "calc(max(5px))", |
michael@0 | 3892 | "-moz-min(5px,2em)", |
michael@0 | 3893 | "calc(min(5px,2em))", |
michael@0 | 3894 | "-moz-max(5px,2em)", |
michael@0 | 3895 | "calc(max(5px,2em))", |
michael@0 | 3896 | "calc(50px/(2 - 2))", |
michael@0 | 3897 | // If we ever support division by values, which is |
michael@0 | 3898 | // complicated for the reasons described in |
michael@0 | 3899 | // http://lists.w3.org/Archives/Public/www-style/2010Jan/0007.html |
michael@0 | 3900 | // , we should support all 4 of these as described in |
michael@0 | 3901 | // http://lists.w3.org/Archives/Public/www-style/2009Dec/0296.html |
michael@0 | 3902 | "calc((3em / 100%) * 3em)", |
michael@0 | 3903 | "calc(3em / 100% * 3em)", |
michael@0 | 3904 | "calc(3em * (3em / 100%))", |
michael@0 | 3905 | "calc(3em * 3em / 100%)" |
michael@0 | 3906 | ] |
michael@0 | 3907 | }, |
michael@0 | 3908 | "flex-direction": { |
michael@0 | 3909 | domProp: "flexDirection", |
michael@0 | 3910 | inherited: false, |
michael@0 | 3911 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3912 | initial_values: [ "row" ], |
michael@0 | 3913 | other_values: [ "row-reverse", "column", "column-reverse" ], |
michael@0 | 3914 | invalid_values: [ "10px", "30%", "justify", "column wrap" ] |
michael@0 | 3915 | }, |
michael@0 | 3916 | "flex-flow": { |
michael@0 | 3917 | domProp: "flexFlow", |
michael@0 | 3918 | inherited: false, |
michael@0 | 3919 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 3920 | subproperties: [ |
michael@0 | 3921 | "flex-direction", |
michael@0 | 3922 | "flex-wrap" |
michael@0 | 3923 | ], |
michael@0 | 3924 | initial_values: [ "row nowrap", "nowrap row", "row", "nowrap" ], |
michael@0 | 3925 | other_values: [ |
michael@0 | 3926 | // only specifying one property: |
michael@0 | 3927 | "column", |
michael@0 | 3928 | "wrap", |
michael@0 | 3929 | "wrap-reverse", |
michael@0 | 3930 | // specifying both properties, 'flex-direction' first: |
michael@0 | 3931 | "row wrap", |
michael@0 | 3932 | "row wrap-reverse", |
michael@0 | 3933 | "column wrap", |
michael@0 | 3934 | "column wrap-reverse", |
michael@0 | 3935 | // specifying both properties, 'flex-wrap' first: |
michael@0 | 3936 | "wrap row", |
michael@0 | 3937 | "wrap column", |
michael@0 | 3938 | "wrap-reverse row", |
michael@0 | 3939 | "wrap-reverse column", |
michael@0 | 3940 | ], |
michael@0 | 3941 | invalid_values: [ |
michael@0 | 3942 | // specifying flex-direction twice (invalid): |
michael@0 | 3943 | "row column", |
michael@0 | 3944 | "row column nowrap", |
michael@0 | 3945 | "row nowrap column", |
michael@0 | 3946 | "nowrap row column", |
michael@0 | 3947 | // specifying flex-wrap twice (invalid): |
michael@0 | 3948 | "nowrap wrap-reverse", |
michael@0 | 3949 | "nowrap wrap-reverse row", |
michael@0 | 3950 | "nowrap row wrap-reverse", |
michael@0 | 3951 | "row nowrap wrap-reverse", |
michael@0 | 3952 | // Invalid data-type / invalid keyword type: |
michael@0 | 3953 | "1px", "5%", "justify", "none" |
michael@0 | 3954 | ] |
michael@0 | 3955 | }, |
michael@0 | 3956 | "flex-grow": { |
michael@0 | 3957 | domProp: "flexGrow", |
michael@0 | 3958 | inherited: false, |
michael@0 | 3959 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3960 | initial_values: [ "0" ], |
michael@0 | 3961 | other_values: [ "3", "1", "1.0", "2.5", "123" ], |
michael@0 | 3962 | invalid_values: [ "0px", "-5", "1%", "3em", "stretch", "auto" ] |
michael@0 | 3963 | }, |
michael@0 | 3964 | "flex-shrink": { |
michael@0 | 3965 | domProp: "flexShrink", |
michael@0 | 3966 | inherited: false, |
michael@0 | 3967 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3968 | initial_values: [ "1" ], |
michael@0 | 3969 | other_values: [ "3", "0", "0.0", "2.5", "123" ], |
michael@0 | 3970 | invalid_values: [ "0px", "-5", "1%", "3em", "stretch", "auto" ] |
michael@0 | 3971 | }, |
michael@0 | 3972 | "flex-wrap": { |
michael@0 | 3973 | domProp: "flexWrap", |
michael@0 | 3974 | inherited: false, |
michael@0 | 3975 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3976 | initial_values: [ "nowrap" ], |
michael@0 | 3977 | other_values: [ "wrap", "wrap-reverse" ], |
michael@0 | 3978 | invalid_values: [ "10px", "30%", "justify", "column wrap", "auto" ] |
michael@0 | 3979 | }, |
michael@0 | 3980 | "order": { |
michael@0 | 3981 | domProp: "order", |
michael@0 | 3982 | inherited: false, |
michael@0 | 3983 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3984 | initial_values: [ "0" ], |
michael@0 | 3985 | other_values: [ "1", "99999", "-1", "-50" ], |
michael@0 | 3986 | invalid_values: [ "0px", "1.0", "1.", "1%", "0.2", "3em", "stretch" ] |
michael@0 | 3987 | }, |
michael@0 | 3988 | "justify-content": { |
michael@0 | 3989 | domProp: "justifyContent", |
michael@0 | 3990 | inherited: false, |
michael@0 | 3991 | type: CSS_TYPE_LONGHAND, |
michael@0 | 3992 | initial_values: [ "flex-start" ], |
michael@0 | 3993 | other_values: [ "flex-end", "center", "space-between", "space-around" ], |
michael@0 | 3994 | invalid_values: [ "baseline", "stretch", "30px", "5%" ] |
michael@0 | 3995 | }, |
michael@0 | 3996 | |
michael@0 | 3997 | // Aliases |
michael@0 | 3998 | "-moz-transform": { |
michael@0 | 3999 | domProp: "MozTransform", |
michael@0 | 4000 | inherited: false, |
michael@0 | 4001 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4002 | alias_for: "transform", |
michael@0 | 4003 | subproperties: [ "transform" ], |
michael@0 | 4004 | prerequisites: { "width": "300px", "height": "50px" }, |
michael@0 | 4005 | initial_values: [ "none" ], |
michael@0 | 4006 | other_values: [ "translatex(1px)", "translatex(4em)", |
michael@0 | 4007 | "translatex(-4px)", "translatex(3px)", |
michael@0 | 4008 | "translatex(0px) translatex(1px) translatex(2px) translatex(3px) translatex(4px)", |
michael@0 | 4009 | "translatey(4em)", "translate(3px)", "translate(10px, -3px)", |
michael@0 | 4010 | "rotate(45deg)", "rotate(45grad)", "rotate(45rad)", |
michael@0 | 4011 | "rotate(0.25turn)", "rotate(0)", "scalex(10)", "scaley(10)", |
michael@0 | 4012 | "scale(10)", "scale(10, 20)", "skewx(30deg)", "skewx(0)", |
michael@0 | 4013 | "skewy(0)", "skewx(30grad)", "skewx(30rad)", "skewx(0.08turn)", |
michael@0 | 4014 | "skewy(30deg)", "skewy(30grad)", "skewy(30rad)", "skewy(0.08turn)", |
michael@0 | 4015 | "rotate(45deg) scale(2, 1)", "skewx(45deg) skewx(-50grad)", |
michael@0 | 4016 | "translate(0, 0) scale(1, 1) skewx(0) skewy(0) matrix(1, 0, 0, 1, 0, 0)", |
michael@0 | 4017 | "translatex(50%)", "translatey(50%)", "translate(50%)", |
michael@0 | 4018 | "translate(3%, 5px)", "translate(5px, 3%)", |
michael@0 | 4019 | "matrix(1, 2, 3, 4, 5, 6)", |
michael@0 | 4020 | /* valid calc() values */ |
michael@0 | 4021 | "translatex(calc(5px + 10%))", |
michael@0 | 4022 | "translatey(calc(0.25 * 5px + 10% / 3))", |
michael@0 | 4023 | "translate(calc(5px - 10% * 3))", |
michael@0 | 4024 | "translate(calc(5px - 3 * 10%), 50px)", |
michael@0 | 4025 | "translate(-50px, calc(5px - 10% * 3))", |
michael@0 | 4026 | /* valid only when prefixed */ |
michael@0 | 4027 | "matrix(1, 2, 3, 4, 5px, 6%)", |
michael@0 | 4028 | "matrix(1, 2, 3, 4, 5%, 6px)", |
michael@0 | 4029 | "matrix(1, 2, 3, 4, 5%, 6%)", |
michael@0 | 4030 | "matrix(1, 2, 3, 4, 5px, 6em)", |
michael@0 | 4031 | "matrix(1, 0, 0, 1, calc(5px * 3), calc(10% - 3px))", |
michael@0 | 4032 | "translatez(1px)", "translatez(4em)", "translatez(-4px)", |
michael@0 | 4033 | "translatez(0px)", "translatez(2px) translatez(5px)", |
michael@0 | 4034 | "translate3d(3px, 4px, 5px)", "translate3d(2em, 3px, 1em)", |
michael@0 | 4035 | "translatex(2px) translate3d(4px, 5px, 6px) translatey(1px)", |
michael@0 | 4036 | "scale3d(4, 4, 4)", "scale3d(-2, 3, -7)", "scalez(4)", |
michael@0 | 4037 | "scalez(-6)", "rotate3d(2, 3, 4, 45deg)", |
michael@0 | 4038 | "rotate3d(-3, 7, 0, 12rad)", "rotatex(15deg)", "rotatey(-12grad)", |
michael@0 | 4039 | "rotatez(72rad)", "rotatex(0.125turn)", "perspective(1000px)", |
michael@0 | 4040 | "matrix3d(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16)", |
michael@0 | 4041 | /* valid only when prefixed */ |
michael@0 | 4042 | "matrix3d(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13px, 14em, 15px, 16)", |
michael@0 | 4043 | "matrix3d(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 20%, 10%, 15, 16)", |
michael@0 | 4044 | ], |
michael@0 | 4045 | invalid_values: ["1px", "#0000ff", "red", "auto", |
michael@0 | 4046 | "translatex(1)", "translatey(1)", "translate(2)", |
michael@0 | 4047 | "translate(-3, -4)", |
michael@0 | 4048 | "translatex(1px 1px)", "translatex(translatex(1px))", |
michael@0 | 4049 | "translatex(#0000ff)", "translatex(red)", "translatey()", |
michael@0 | 4050 | "matrix(1px, 2px, 3px, 4px, 5px, 6px)", "scale(150%)", |
michael@0 | 4051 | "skewx(red)", "matrix(1%, 0, 0, 0, 0px, 0px)", |
michael@0 | 4052 | "matrix(0, 1%, 2, 3, 4px,5px)", "matrix(0, 1, 2%, 3, 4px, 5px)", |
michael@0 | 4053 | "matrix(0, 1, 2, 3%, 4%, 5%)", |
michael@0 | 4054 | /* invalid calc() values */ |
michael@0 | 4055 | "translatey(-moz-min(5px,10%))", |
michael@0 | 4056 | "translatex(-moz-max(5px,10%))", |
michael@0 | 4057 | "translate(10px, calc(min(5px,10%)))", |
michael@0 | 4058 | "translate(calc(max(5px,10%)), 10%)", |
michael@0 | 4059 | "matrix(1, 0, 0, 1, max(5px * 3), calc(10% - 3px))", |
michael@0 | 4060 | "perspective(0px)", "perspective(-10px)", "matrix3d(dinosaur)", |
michael@0 | 4061 | "matrix3d(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17)", |
michael@0 | 4062 | "matrix3d(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15)", |
michael@0 | 4063 | "matrix3d(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15%, 16)", |
michael@0 | 4064 | "matrix3d(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16px)", |
michael@0 | 4065 | "rotatey(words)", "rotatex(7)", "translate3d(3px, 4px, 1px, 7px)", |
michael@0 | 4066 | ], |
michael@0 | 4067 | }, |
michael@0 | 4068 | "-moz-transform-origin": { |
michael@0 | 4069 | domProp: "MozTransformOrigin", |
michael@0 | 4070 | inherited: false, |
michael@0 | 4071 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4072 | alias_for: "transform-origin", |
michael@0 | 4073 | subproperties: [ "transform-origin" ], |
michael@0 | 4074 | prerequisites: { "width": "10px", "height": "10px", "display": "block"}, |
michael@0 | 4075 | initial_values: [ "50% 50%", "center", "center center" ], |
michael@0 | 4076 | other_values: [ "25% 25%", "6px 5px", "20% 3em", "0 0", "0in 1in", |
michael@0 | 4077 | "top", "bottom","top left", "top right", |
michael@0 | 4078 | "top center", "center left", "center right", |
michael@0 | 4079 | "bottom left", "bottom right", "bottom center", |
michael@0 | 4080 | "20% center", "6px center", "13in bottom", |
michael@0 | 4081 | "left 50px", "right 13%", "center 40px", |
michael@0 | 4082 | "calc(20px)", |
michael@0 | 4083 | "calc(20px) 10px", |
michael@0 | 4084 | "10px calc(20px)", |
michael@0 | 4085 | "calc(20px) 25%", |
michael@0 | 4086 | "25% calc(20px)", |
michael@0 | 4087 | "calc(20px) calc(20px)", |
michael@0 | 4088 | "calc(20px + 1em) calc(20px / 2)", |
michael@0 | 4089 | "calc(20px + 50%) calc(50% - 10px)", |
michael@0 | 4090 | "calc(-20px) calc(-50%)", |
michael@0 | 4091 | "calc(-20%) calc(-50%)", |
michael@0 | 4092 | "6px 5px 5px", |
michael@0 | 4093 | "top center 10px" |
michael@0 | 4094 | ], |
michael@0 | 4095 | invalid_values: ["red", "auto", "none", "0.5 0.5", "40px #0000ff", |
michael@0 | 4096 | "border", "center red", "right diagonal", |
michael@0 | 4097 | "#00ffff bottom"] |
michael@0 | 4098 | }, |
michael@0 | 4099 | "-moz-perspective-origin": { |
michael@0 | 4100 | domProp: "MozPerspectiveOrigin", |
michael@0 | 4101 | inherited: false, |
michael@0 | 4102 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4103 | alias_for: "perspective-origin", |
michael@0 | 4104 | subproperties: [ "perspective-origin" ], |
michael@0 | 4105 | prerequisites: { "width": "10px", "height": "10px", "display": "block"}, |
michael@0 | 4106 | initial_values: [ "50% 50%", "center", "center center" ], |
michael@0 | 4107 | other_values: [ "25% 25%", "6px 5px", "20% 3em", "0 0", "0in 1in", |
michael@0 | 4108 | "top", "bottom","top left", "top right", |
michael@0 | 4109 | "top center", "center left", "center right", |
michael@0 | 4110 | "bottom left", "bottom right", "bottom center", |
michael@0 | 4111 | "20% center", "6px center", "13in bottom", |
michael@0 | 4112 | "left 50px", "right 13%", "center 40px", |
michael@0 | 4113 | "calc(20px)", |
michael@0 | 4114 | "calc(20px) 10px", |
michael@0 | 4115 | "10px calc(20px)", |
michael@0 | 4116 | "calc(20px) 25%", |
michael@0 | 4117 | "25% calc(20px)", |
michael@0 | 4118 | "calc(20px) calc(20px)", |
michael@0 | 4119 | "calc(20px + 1em) calc(20px / 2)", |
michael@0 | 4120 | "calc(20px + 50%) calc(50% - 10px)", |
michael@0 | 4121 | "calc(-20px) calc(-50%)", |
michael@0 | 4122 | "calc(-20%) calc(-50%)" ], |
michael@0 | 4123 | invalid_values: [ "red", "auto", "none", "0.5 0.5", "40px #0000ff", |
michael@0 | 4124 | "border", "center red", "right diagonal", |
michael@0 | 4125 | "#00ffff bottom"] |
michael@0 | 4126 | }, |
michael@0 | 4127 | "-moz-perspective": { |
michael@0 | 4128 | domProp: "MozPerspective", |
michael@0 | 4129 | inherited: false, |
michael@0 | 4130 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4131 | alias_for: "perspective", |
michael@0 | 4132 | subproperties: [ "perspective" ], |
michael@0 | 4133 | initial_values: [ "none" ], |
michael@0 | 4134 | other_values: [ "1000px", "500.2px" ], |
michael@0 | 4135 | invalid_values: [ "pants", "200", "0", "-100px", "-27.2em" ] |
michael@0 | 4136 | }, |
michael@0 | 4137 | "-moz-backface-visibility": { |
michael@0 | 4138 | domProp: "MozBackfaceVisibility", |
michael@0 | 4139 | inherited: false, |
michael@0 | 4140 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4141 | alias_for: "backface-visibility", |
michael@0 | 4142 | subproperties: [ "backface-visibility" ], |
michael@0 | 4143 | initial_values: [ "visible" ], |
michael@0 | 4144 | other_values: [ "hidden" ], |
michael@0 | 4145 | invalid_values: [ "collapse" ] |
michael@0 | 4146 | }, |
michael@0 | 4147 | "-moz-transform-style": { |
michael@0 | 4148 | domProp: "MozTransformStyle", |
michael@0 | 4149 | inherited: false, |
michael@0 | 4150 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4151 | alias_for: "transform-style", |
michael@0 | 4152 | subproperties: [ "transform-style" ], |
michael@0 | 4153 | initial_values: [ "flat" ], |
michael@0 | 4154 | other_values: [ "preserve-3d" ], |
michael@0 | 4155 | invalid_values: [] |
michael@0 | 4156 | }, |
michael@0 | 4157 | "-moz-border-image": { |
michael@0 | 4158 | domProp: "MozBorderImage", |
michael@0 | 4159 | inherited: false, |
michael@0 | 4160 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 4161 | alias_for: "border-image", |
michael@0 | 4162 | subproperties: [ "border-image-source", "border-image-slice", "border-image-width", "border-image-outset", "border-image-repeat" ], |
michael@0 | 4163 | initial_values: [ "none" ], |
michael@0 | 4164 | other_values: [ "url('border.png') 27 27 27 27", |
michael@0 | 4165 | "url('border.png') 27", |
michael@0 | 4166 | "stretch url('border.png')", |
michael@0 | 4167 | "url('border.png') 27 fill", |
michael@0 | 4168 | "url('border.png') 27 27 27 27 repeat", |
michael@0 | 4169 | "repeat url('border.png') 27 27 27 27", |
michael@0 | 4170 | "url('border.png') repeat 27 27 27 27", |
michael@0 | 4171 | "url('border.png') fill 27 27 27 27 repeat", |
michael@0 | 4172 | "url('border.png') 27 27 27 27 / 1em", |
michael@0 | 4173 | "27 27 27 27 / 1em url('border.png') ", |
michael@0 | 4174 | "url('border.png') 27 27 27 27 / 10 10 10 / 10 10 repeat", |
michael@0 | 4175 | "repeat 27 27 27 27 / 10 10 10 / 10 10 url('border.png')", |
michael@0 | 4176 | "url('border.png') 27 27 27 27 / / 10 10 1em", |
michael@0 | 4177 | "fill 27 27 27 27 / / 10 10 1em url('border.png')", |
michael@0 | 4178 | "url('border.png') 27 27 27 27 / 1em 1em 1em 1em repeat", |
michael@0 | 4179 | "url('border.png') 27 27 27 27 / 1em 1em 1em 1em stretch round" ], |
michael@0 | 4180 | invalid_values: [ "url('border.png') 27 27 27 27 27", |
michael@0 | 4181 | "url('border.png') 27 27 27 27 / 1em 1em 1em 1em 1em", |
michael@0 | 4182 | "url('border.png') 27 27 27 27 /", |
michael@0 | 4183 | "url('border.png') fill", |
michael@0 | 4184 | "url('border.png') fill repeat", |
michael@0 | 4185 | "fill repeat", |
michael@0 | 4186 | "url('border.png') fill / 1em", |
michael@0 | 4187 | "url('border.png') / repeat", |
michael@0 | 4188 | "url('border.png') 1 /", |
michael@0 | 4189 | "url('border.png') 1 / /", |
michael@0 | 4190 | "1 / url('border.png')", |
michael@0 | 4191 | "url('border.png') / 1", |
michael@0 | 4192 | "url('border.png') / / 1"] |
michael@0 | 4193 | }, |
michael@0 | 4194 | "-moz-transition": { |
michael@0 | 4195 | domProp: "MozTransition", |
michael@0 | 4196 | inherited: false, |
michael@0 | 4197 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 4198 | alias_for: "transition", |
michael@0 | 4199 | subproperties: [ "transition-property", "transition-duration", "transition-timing-function", "transition-delay" ], |
michael@0 | 4200 | initial_values: [ "all 0s ease 0s", "all", "0s", "0s 0s", "ease" ], |
michael@0 | 4201 | other_values: [ "width 1s linear 2s", "width 1s 2s linear", "width linear 1s 2s", "linear width 1s 2s", "linear 1s width 2s", "linear 1s 2s width", "1s width linear 2s", "1s width 2s linear", "1s 2s width linear", "1s linear width 2s", "1s linear 2s width", "1s 2s linear width", "width linear 1s", "width 1s linear", "linear width 1s", "linear 1s width", "1s width linear", "1s linear width", "1s 2s width", "1s width 2s", "width 1s 2s", "1s 2s linear", "1s linear 2s", "linear 1s 2s", "width 1s", "1s width", "linear 1s", "1s linear", "1s 2s", "2s 1s", "width", "linear", "1s", "height", "2s", "ease-in-out", "2s ease-in", "opacity linear", "ease-out 2s", "2s color, 1s width, 500ms height linear, 1s opacity 4s cubic-bezier(0.0, 0.1, 1.0, 1.0)", "1s \\32width linear 2s", "1s -width linear 2s", "1s -\\32width linear 2s", "1s \\32 0width linear 2s", "1s -\\32 0width linear 2s", "1s \\2width linear 2s", "1s -\\2width linear 2s", "2s, 1s width", "1s width, 2s", "2s all, 1s width", "1s width, 2s all", "2s all, 1s width", "2s width, 1s all" ], |
michael@0 | 4202 | invalid_values: [ "1s width, 2s none", "2s none, 1s width", "2s inherit", "inherit 2s", "2s width, 1s inherit", "2s inherit, 1s width", "2s initial" ] |
michael@0 | 4203 | }, |
michael@0 | 4204 | "-moz-transition-delay": { |
michael@0 | 4205 | domProp: "MozTransitionDelay", |
michael@0 | 4206 | inherited: false, |
michael@0 | 4207 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4208 | alias_for: "transition-delay", |
michael@0 | 4209 | subproperties: [ "transition-delay" ], |
michael@0 | 4210 | initial_values: [ "0s", "0ms" ], |
michael@0 | 4211 | other_values: [ "1s", "250ms", "-100ms", "-1s", "1s, 250ms, 2.3s"], |
michael@0 | 4212 | invalid_values: [ "0", "0px" ] |
michael@0 | 4213 | }, |
michael@0 | 4214 | "-moz-transition-duration": { |
michael@0 | 4215 | domProp: "MozTransitionDuration", |
michael@0 | 4216 | inherited: false, |
michael@0 | 4217 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4218 | alias_for: "transition-duration", |
michael@0 | 4219 | subproperties: [ "transition-duration" ], |
michael@0 | 4220 | initial_values: [ "0s", "0ms" ], |
michael@0 | 4221 | other_values: [ "1s", "250ms", "1s, 250ms, 2.3s"], |
michael@0 | 4222 | invalid_values: [ "0", "0px", "-1ms", "-2s" ] |
michael@0 | 4223 | }, |
michael@0 | 4224 | "-moz-transition-property": { |
michael@0 | 4225 | domProp: "MozTransitionProperty", |
michael@0 | 4226 | inherited: false, |
michael@0 | 4227 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4228 | alias_for: "transition-property", |
michael@0 | 4229 | subproperties: [ "transition-property" ], |
michael@0 | 4230 | initial_values: [ "all" ], |
michael@0 | 4231 | other_values: [ "none", "left", "top", "color", "width, height, opacity", "foobar", "auto", "\\32width", "-width", "-\\32width", "\\32 0width", "-\\32 0width", "\\2width", "-\\2width", "all, all", "all, color", "color, all" ], |
michael@0 | 4232 | invalid_values: [ "none, none", "color, none", "none, color", "inherit, color", "color, inherit", "initial, color", "color, initial", "none, color", "color, none" ] |
michael@0 | 4233 | }, |
michael@0 | 4234 | "-moz-transition-timing-function": { |
michael@0 | 4235 | domProp: "MozTransitionTimingFunction", |
michael@0 | 4236 | inherited: false, |
michael@0 | 4237 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4238 | alias_for: "transition-timing-function", |
michael@0 | 4239 | subproperties: [ "transition-timing-function" ], |
michael@0 | 4240 | initial_values: [ "ease", "cubic-bezier(0.25, 0.1, 0.25, 1.0)" ], |
michael@0 | 4241 | other_values: [ "linear", "ease-in", "ease-out", "ease-in-out", "linear, ease-in, cubic-bezier(0.1, 0.2, 0.8, 0.9)", "cubic-bezier(0.5, 0.5, 0.5, 0.5)", "cubic-bezier(0.25, 1.5, 0.75, -0.5)", "step-start", "step-end", "steps(1)", "steps(2, start)", "steps(386)", "steps(3, end)" ], |
michael@0 | 4242 | invalid_values: [ "none", "auto", "cubic-bezier(0.25, 0.1, 0.25)", "cubic-bezier(0.25, 0.1, 0.25, 0.25, 1.0)", "cubic-bezier(-0.5, 0.5, 0.5, 0.5)", "cubic-bezier(1.5, 0.5, 0.5, 0.5)", "cubic-bezier(0.5, 0.5, -0.5, 0.5)", "cubic-bezier(0.5, 0.5, 1.5, 0.5)", "steps(2, step-end)", "steps(0)", "steps(-2)", "steps(0, step-end, 1)" ] |
michael@0 | 4243 | }, |
michael@0 | 4244 | "-moz-animation": { |
michael@0 | 4245 | domProp: "MozAnimation", |
michael@0 | 4246 | inherited: false, |
michael@0 | 4247 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 4248 | alias_for: "animation", |
michael@0 | 4249 | subproperties: [ "animation-name", "animation-duration", "animation-timing-function", "animation-delay", "animation-direction", "animation-fill-mode", "animation-iteration-count" ], |
michael@0 | 4250 | initial_values: [ "none none 0s 0s ease normal 1.0", "none", "0s", "ease", "normal", "1.0" ], |
michael@0 | 4251 | other_values: [ "bounce 1s linear 2s", "bounce 1s 2s linear", "bounce linear 1s 2s", "linear bounce 1s 2s", "linear 1s bounce 2s", "linear 1s 2s bounce", "1s bounce linear 2s", "1s bounce 2s linear", "1s 2s bounce linear", "1s linear bounce 2s", "1s linear 2s bounce", "1s 2s linear bounce", "bounce linear 1s", "bounce 1s linear", "linear bounce 1s", "linear 1s bounce", "1s bounce linear", "1s linear bounce", "1s 2s bounce", "1s bounce 2s", "bounce 1s 2s", "1s 2s linear", "1s linear 2s", "linear 1s 2s", "bounce 1s", "1s bounce", "linear 1s", "1s linear", "1s 2s", "2s 1s", "bounce", "linear", "1s", "height", "2s", "ease-in-out", "2s ease-in", "opacity linear", "ease-out 2s", "2s color, 1s bounce, 500ms height linear, 1s opacity 4s cubic-bezier(0.0, 0.1, 1.0, 1.0)", "1s \\32bounce linear 2s", "1s -bounce linear 2s", "1s -\\32bounce linear 2s", "1s \\32 0bounce linear 2s", "1s -\\32 0bounce linear 2s", "1s \\2bounce linear 2s", "1s -\\2bounce linear 2s", "2s, 1s bounce", "1s bounce, 2s", "2s all, 1s bounce", "1s bounce, 2s all", "1s bounce, 2s none", "2s none, 1s bounce", "2s bounce, 1s all", "2s all, 1s bounce" ], |
michael@0 | 4252 | invalid_values: [ "2s inherit", "inherit 2s", "2s bounce, 1s inherit", "2s inherit, 1s bounce", "2s initial" ] |
michael@0 | 4253 | }, |
michael@0 | 4254 | "-moz-animation-delay": { |
michael@0 | 4255 | domProp: "MozAnimationDelay", |
michael@0 | 4256 | inherited: false, |
michael@0 | 4257 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4258 | alias_for: "animation-delay", |
michael@0 | 4259 | subproperties: [ "animation-delay" ], |
michael@0 | 4260 | initial_values: [ "0s", "0ms" ], |
michael@0 | 4261 | other_values: [ "1s", "250ms", "-100ms", "-1s", "1s, 250ms, 2.3s"], |
michael@0 | 4262 | invalid_values: [ "0", "0px" ] |
michael@0 | 4263 | }, |
michael@0 | 4264 | "-moz-animation-direction": { |
michael@0 | 4265 | domProp: "MozAnimationDirection", |
michael@0 | 4266 | inherited: false, |
michael@0 | 4267 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4268 | alias_for: "animation-direction", |
michael@0 | 4269 | subproperties: [ "animation-direction" ], |
michael@0 | 4270 | initial_values: [ "normal" ], |
michael@0 | 4271 | other_values: [ "alternate", "normal, alternate", "alternate, normal", "normal, normal", "normal, normal, normal", "reverse", "alternate-reverse", "normal, reverse, alternate-reverse, alternate" ], |
michael@0 | 4272 | invalid_values: [ "normal normal", "inherit, normal", "reverse-alternate" ] |
michael@0 | 4273 | }, |
michael@0 | 4274 | "-moz-animation-duration": { |
michael@0 | 4275 | domProp: "MozAnimationDuration", |
michael@0 | 4276 | inherited: false, |
michael@0 | 4277 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4278 | alias_for: "animation-duration", |
michael@0 | 4279 | subproperties: [ "animation-duration" ], |
michael@0 | 4280 | initial_values: [ "0s", "0ms" ], |
michael@0 | 4281 | other_values: [ "1s", "250ms", "1s, 250ms, 2.3s"], |
michael@0 | 4282 | invalid_values: [ "0", "0px", "-1ms", "-2s" ] |
michael@0 | 4283 | }, |
michael@0 | 4284 | "-moz-animation-fill-mode": { |
michael@0 | 4285 | domProp: "MozAnimationFillMode", |
michael@0 | 4286 | inherited: false, |
michael@0 | 4287 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4288 | alias_for: "animation-fill-mode", |
michael@0 | 4289 | subproperties: [ "animation-fill-mode" ], |
michael@0 | 4290 | initial_values: [ "none" ], |
michael@0 | 4291 | other_values: [ "forwards", "backwards", "both", "none, none", "forwards, backwards", "forwards, none", "none, both" ], |
michael@0 | 4292 | invalid_values: [ "all"] |
michael@0 | 4293 | }, |
michael@0 | 4294 | "-moz-animation-iteration-count": { |
michael@0 | 4295 | domProp: "MozAnimationIterationCount", |
michael@0 | 4296 | inherited: false, |
michael@0 | 4297 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4298 | alias_for: "animation-iteration-count", |
michael@0 | 4299 | subproperties: [ "animation-iteration-count" ], |
michael@0 | 4300 | initial_values: [ "1" ], |
michael@0 | 4301 | other_values: [ "infinite", "0", "0.5", "7.75", "-0.0", "1, 2, 3", "infinite, 2", "1, infinite" ], |
michael@0 | 4302 | // negatives forbidden per |
michael@0 | 4303 | // http://lists.w3.org/Archives/Public/www-style/2011Mar/0355.html |
michael@0 | 4304 | invalid_values: [ "none", "-1", "-0.5", "-1, infinite", "infinite, -3" ] |
michael@0 | 4305 | }, |
michael@0 | 4306 | "-moz-animation-name": { |
michael@0 | 4307 | domProp: "MozAnimationName", |
michael@0 | 4308 | inherited: false, |
michael@0 | 4309 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4310 | alias_for: "animation-name", |
michael@0 | 4311 | subproperties: [ "animation-name" ], |
michael@0 | 4312 | initial_values: [ "none" ], |
michael@0 | 4313 | other_values: [ "all", "ball", "mall", "color", "bounce, bubble, opacity", "foobar", "auto", "\\32bounce", "-bounce", "-\\32bounce", "\\32 0bounce", "-\\32 0bounce", "\\2bounce", "-\\2bounce" ], |
michael@0 | 4314 | invalid_values: [ "bounce, initial", "initial, bounce", "bounce, inherit", "inherit, bounce" ] |
michael@0 | 4315 | }, |
michael@0 | 4316 | "-moz-animation-play-state": { |
michael@0 | 4317 | domProp: "MozAnimationPlayState", |
michael@0 | 4318 | inherited: false, |
michael@0 | 4319 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4320 | alias_for: "animation-play-state", |
michael@0 | 4321 | subproperties: [ "animation-play-state" ], |
michael@0 | 4322 | initial_values: [ "running" ], |
michael@0 | 4323 | other_values: [ "paused", "running, running", "paused, running", "paused, paused", "running, paused", "paused, running, running, running, paused, running" ], |
michael@0 | 4324 | invalid_values: [ "0" ] |
michael@0 | 4325 | }, |
michael@0 | 4326 | "-moz-animation-timing-function": { |
michael@0 | 4327 | domProp: "MozAnimationTimingFunction", |
michael@0 | 4328 | inherited: false, |
michael@0 | 4329 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4330 | alias_for: "animation-timing-function", |
michael@0 | 4331 | subproperties: [ "animation-timing-function" ], |
michael@0 | 4332 | initial_values: [ "ease", "cubic-bezier(0.25, 0.1, 0.25, 1.0)" ], |
michael@0 | 4333 | other_values: [ "linear", "ease-in", "ease-out", "ease-in-out", "linear, ease-in, cubic-bezier(0.1, 0.2, 0.8, 0.9)", "cubic-bezier(0.5, 0.5, 0.5, 0.5)", "cubic-bezier(0.25, 1.5, 0.75, -0.5)", "step-start", "step-end", "steps(1)", "steps(2, start)", "steps(386)", "steps(3, end)" ], |
michael@0 | 4334 | invalid_values: [ "none", "auto", "cubic-bezier(0.25, 0.1, 0.25)", "cubic-bezier(0.25, 0.1, 0.25, 0.25, 1.0)", "cubic-bezier(-0.5, 0.5, 0.5, 0.5)", "cubic-bezier(1.5, 0.5, 0.5, 0.5)", "cubic-bezier(0.5, 0.5, -0.5, 0.5)", "cubic-bezier(0.5, 0.5, 1.5, 0.5)", "steps(2, step-end)", "steps(0)", "steps(-2)", "steps(0, step-end, 1)" ] |
michael@0 | 4335 | } |
michael@0 | 4336 | } |
michael@0 | 4337 | |
michael@0 | 4338 | function logical_box_prop_get_computed(cs, property) |
michael@0 | 4339 | { |
michael@0 | 4340 | if (! /^-moz-/.test(property)) |
michael@0 | 4341 | throw "Unexpected property"; |
michael@0 | 4342 | property = property.substring(5); |
michael@0 | 4343 | if (cs.getPropertyValue("direction") == "ltr") |
michael@0 | 4344 | property = property.replace("-start", "-left").replace("-end", "-right"); |
michael@0 | 4345 | else |
michael@0 | 4346 | property = property.replace("-start", "-right").replace("-end", "-left"); |
michael@0 | 4347 | return cs.getPropertyValue(property); |
michael@0 | 4348 | } |
michael@0 | 4349 | |
michael@0 | 4350 | // Get the computed value for a property. For shorthands, return the |
michael@0 | 4351 | // computed values of all the subproperties, delimited by " ; ". |
michael@0 | 4352 | function get_computed_value(cs, property) |
michael@0 | 4353 | { |
michael@0 | 4354 | var info = gCSSProperties[property]; |
michael@0 | 4355 | if (info.type == CSS_TYPE_TRUE_SHORTHAND || |
michael@0 | 4356 | (info.type == CSS_TYPE_SHORTHAND_AND_LONGHAND && |
michael@0 | 4357 | property == "text-decoration")) { |
michael@0 | 4358 | var results = []; |
michael@0 | 4359 | for (var idx in info.subproperties) { |
michael@0 | 4360 | var subprop = info.subproperties[idx]; |
michael@0 | 4361 | results.push(get_computed_value(cs, subprop)); |
michael@0 | 4362 | } |
michael@0 | 4363 | return results.join(" ; "); |
michael@0 | 4364 | } |
michael@0 | 4365 | if (info.get_computed) |
michael@0 | 4366 | return info.get_computed(cs, property); |
michael@0 | 4367 | return cs.getPropertyValue(property); |
michael@0 | 4368 | } |
michael@0 | 4369 | |
michael@0 | 4370 | if (SpecialPowers.getBoolPref("layout.css.touch_action.enabled")) { |
michael@0 | 4371 | gCSSProperties["touch-action"] = { |
michael@0 | 4372 | domProp: "touchAction", |
michael@0 | 4373 | inherited: false, |
michael@0 | 4374 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4375 | initial_values: ["auto"], |
michael@0 | 4376 | other_values: ["none", "pan-x", "pan-y", "pan-x pan-y", "pan-y pan-x", "manipulation"], |
michael@0 | 4377 | invalid_values: ["zoom", "pinch", "tap", "10px", "2", "auto pan-x", "pan-x auto", "none pan-x", "pan-x none", |
michael@0 | 4378 | "auto pan-y", "pan-y auto", "none pan-y", "pan-y none", "pan-x pan-x", "pan-y pan-y", |
michael@0 | 4379 | "pan-x pan-y none", "pan-x none pan-y", "none pan-x pan-y", "pan-y pan-x none", "pan-y none pan-x", "none pan-y pan-x", |
michael@0 | 4380 | "pan-x pan-y auto", "pan-x auto pan-y", "auto pan-x pan-y", "pan-y pan-x auto", "pan-y auto pan-x", "auto pan-y pan-x", |
michael@0 | 4381 | "pan-x pan-y zoom", "pan-x zoom pan-y", "zoom pan-x pan-y", "pan-y pan-x zoom", "pan-y zoom pan-x", "zoom pan-y pan-x", |
michael@0 | 4382 | "pan-x pan-y pan-x", "pan-x pan-x pan-y", "pan-y pan-x pan-x", "pan-y pan-x pan-y", "pan-y pan-y pan-x", "pan-x pan-y pan-y", |
michael@0 | 4383 | "manipulation none", "none manipulation", "manipulation auto", "auto manipulation", "manipulation zoom", "zoom manipulation", |
michael@0 | 4384 | "manipulation manipulation", "manipulation pan-x", "pan-x manipulation", "manipulation pan-y", "pan-y manipulation", |
michael@0 | 4385 | "manipulation pan-x pan-y", "pan-x manipulation pan-y", "pan-x pan-y manipulation", |
michael@0 | 4386 | "manipulation pan-y pan-x", "pan-y manipulation pan-x", "pan-y pan-x manipulation"] |
michael@0 | 4387 | }; |
michael@0 | 4388 | } |
michael@0 | 4389 | |
michael@0 | 4390 | if (SpecialPowers.getBoolPref("layout.css.vertical-text.enabled")) { |
michael@0 | 4391 | var verticalTextProperties = { |
michael@0 | 4392 | "writing-mode": { |
michael@0 | 4393 | domProp: "writingMode", |
michael@0 | 4394 | inherited: true, |
michael@0 | 4395 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4396 | initial_values: [ "horizontal-tb" ], |
michael@0 | 4397 | other_values: [ "vertical-lr", "vertical-rl" ], |
michael@0 | 4398 | invalid_values: [ "10px", "30%", "justify", "auto", "1em" ] |
michael@0 | 4399 | }, |
michael@0 | 4400 | "text-orientation": { |
michael@0 | 4401 | domProp: "textOrientation", |
michael@0 | 4402 | inherited: true, |
michael@0 | 4403 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4404 | initial_values: [ "auto" ], |
michael@0 | 4405 | other_values: [ "upright", "sideways" ], |
michael@0 | 4406 | invalid_values: [ "none", "3em" ] |
michael@0 | 4407 | }, |
michael@0 | 4408 | "text-combine-upright": { |
michael@0 | 4409 | domProp: "textCombineUpright", |
michael@0 | 4410 | inherited: true, |
michael@0 | 4411 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4412 | initial_values: [ "none" ], |
michael@0 | 4413 | other_values: [ "all", "digits", "digits 2", "digits 3", "digits 4", "digits 3" ], |
michael@0 | 4414 | invalid_values: [ "auto", "all 2", "none all", "digits -3", "digits 0", |
michael@0 | 4415 | "digits 12", "none 3", "digits 3.1415", "digits3", "digits 1", |
michael@0 | 4416 | "digits 3 all", "digits foo", "digits all", "digits 3.0" ] |
michael@0 | 4417 | } |
michael@0 | 4418 | }; |
michael@0 | 4419 | for (var prop in verticalTextProperties) { |
michael@0 | 4420 | gCSSProperties[prop] = verticalTextProperties[prop]; |
michael@0 | 4421 | } |
michael@0 | 4422 | } |
michael@0 | 4423 | |
michael@0 | 4424 | if (SpecialPowers.getBoolPref("layout.css.font-features.enabled")) { |
michael@0 | 4425 | var fontFeatureProperties = { |
michael@0 | 4426 | "font-kerning": { |
michael@0 | 4427 | domProp: "fontKerning", |
michael@0 | 4428 | inherited: true, |
michael@0 | 4429 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4430 | initial_values: [ "auto" ], |
michael@0 | 4431 | other_values: [ "normal", "none" ], |
michael@0 | 4432 | invalid_values: [ "on" ] |
michael@0 | 4433 | }, |
michael@0 | 4434 | "font-variant-alternates": { |
michael@0 | 4435 | domProp: "fontVariantAlternates", |
michael@0 | 4436 | inherited: true, |
michael@0 | 4437 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4438 | initial_values: [ "normal" ], |
michael@0 | 4439 | other_values: [ "historical-forms", |
michael@0 | 4440 | "styleset(alt-a, alt-b)", "character-variant(a, b, c)", "annotation(circled)", |
michael@0 | 4441 | "swash(squishy)", "styleset(complex\\ blob, a)", "annotation(\\62 lah)" ], |
michael@0 | 4442 | invalid_values: [ "historical-forms normal", "historical-forms historical-forms", |
michael@0 | 4443 | "swash", "swash(3)", "annotation(a, b)", "ornaments(a,b)", |
michael@0 | 4444 | "styleset(1234blah)", "annotation(a), annotation(b)", "annotation(a) normal" ] |
michael@0 | 4445 | }, |
michael@0 | 4446 | "font-variant-caps": { |
michael@0 | 4447 | domProp: "fontVariantCaps", |
michael@0 | 4448 | inherited: true, |
michael@0 | 4449 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4450 | initial_values: [ "normal" ], |
michael@0 | 4451 | other_values: [ "small-caps", "all-small-caps", "petite-caps", "all-petite-caps", "titling-caps", "unicase" ], |
michael@0 | 4452 | invalid_values: [ "normal small-caps", "petite-caps normal", "unicase unicase" ] |
michael@0 | 4453 | }, |
michael@0 | 4454 | "font-variant-east-asian": { |
michael@0 | 4455 | domProp: "fontVariantEastAsian", |
michael@0 | 4456 | inherited: true, |
michael@0 | 4457 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4458 | initial_values: [ "normal" ], |
michael@0 | 4459 | other_values: [ "jis78", "jis83", "jis90", "jis04", "simplified", "traditional", "full-width", "proportional-width", "ruby", |
michael@0 | 4460 | "jis78 full-width", "jis78 full-width ruby", "simplified proportional-width", "ruby simplified" ], |
michael@0 | 4461 | invalid_values: [ "jis78 normal", "jis90 jis04", "simplified traditional", "full-width proportional-width", |
michael@0 | 4462 | "ruby simplified ruby", "jis78 ruby simplified" ] |
michael@0 | 4463 | }, |
michael@0 | 4464 | "font-variant-ligatures": { |
michael@0 | 4465 | domProp: "fontVariantLigatures", |
michael@0 | 4466 | inherited: true, |
michael@0 | 4467 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4468 | initial_values: [ "normal" ], |
michael@0 | 4469 | other_values: [ "none", "common-ligatures", "no-common-ligatures", "discretionary-ligatures", "no-discretionary-ligatures", |
michael@0 | 4470 | "historical-ligatures", "no-historical-ligatures", "contextual", "no-contextual", |
michael@0 | 4471 | "common-ligatures no-discretionary-ligatures", "contextual no-discretionary-ligatures", |
michael@0 | 4472 | "historical-ligatures no-common-ligatures", "no-historical-ligatures discretionary-ligatures", |
michael@0 | 4473 | "common-ligatures no-discretionary-ligatures historical-ligatures no-contextual" ], |
michael@0 | 4474 | invalid_values: [ "common-ligatures normal", "common-ligatures no-common-ligatures", "common-ligatures common-ligatures", |
michael@0 | 4475 | "no-historical-ligatures historical-ligatures", "no-discretionary-ligatures discretionary-ligatures", |
michael@0 | 4476 | "no-contextual contextual", "common-ligatures no-discretionary-ligatures no-common-ligatures", |
michael@0 | 4477 | "common-ligatures none", "no-discretionary-ligatures none", "none common-ligatures" ] |
michael@0 | 4478 | }, |
michael@0 | 4479 | "font-variant-numeric": { |
michael@0 | 4480 | domProp: "fontVariantNumeric", |
michael@0 | 4481 | inherited: true, |
michael@0 | 4482 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4483 | initial_values: [ "normal" ], |
michael@0 | 4484 | other_values: [ "lining-nums", "oldstyle-nums", "proportional-nums", "tabular-nums", "diagonal-fractions", |
michael@0 | 4485 | "stacked-fractions", "slashed-zero", "ordinal", "lining-nums diagonal-fractions", |
michael@0 | 4486 | "tabular-nums stacked-fractions", "tabular-nums slashed-zero stacked-fractions", |
michael@0 | 4487 | "proportional-nums slashed-zero diagonal-fractions oldstyle-nums ordinal" ], |
michael@0 | 4488 | invalid_values: [ "lining-nums normal", "lining-nums oldstyle-nums", "lining-nums normal slashed-zero ordinal", |
michael@0 | 4489 | "proportional-nums tabular-nums", "diagonal-fractions stacked-fractions", "slashed-zero diagonal-fractions slashed-zero", |
michael@0 | 4490 | "lining-nums slashed-zero diagonal-fractions oldstyle-nums", "diagonal-fractions diagonal-fractions" ] |
michael@0 | 4491 | }, |
michael@0 | 4492 | "font-variant-position": { |
michael@0 | 4493 | domProp: "fontVariantPosition", |
michael@0 | 4494 | inherited: true, |
michael@0 | 4495 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4496 | initial_values: [ "normal" ], |
michael@0 | 4497 | other_values: [ "super", "sub" ], |
michael@0 | 4498 | invalid_values: [ "normal sub", "super sub" ] |
michael@0 | 4499 | }, |
michael@0 | 4500 | "font-synthesis": { |
michael@0 | 4501 | domProp: "fontSynthesis", |
michael@0 | 4502 | inherited: true, |
michael@0 | 4503 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4504 | initial_values: [ "weight style" ], |
michael@0 | 4505 | other_values: [ "none", "weight", "style" ], |
michael@0 | 4506 | invalid_values: [ "weight none", "style none", "none style", "weight 10px", "weight weight", "style style" ] |
michael@0 | 4507 | }, |
michael@0 | 4508 | // aliases for prefixed properties |
michael@0 | 4509 | "font-feature-settings": { |
michael@0 | 4510 | domProp: "fontFeatureSettings", |
michael@0 | 4511 | inherited: true, |
michael@0 | 4512 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4513 | alias_for: "-moz-font-feature-settings", |
michael@0 | 4514 | subproperties: [ "-moz-font-feature-settings" ], |
michael@0 | 4515 | initial_values: [ "normal" ], |
michael@0 | 4516 | other_values: [ |
michael@0 | 4517 | "'liga' on", "'liga'", "\"liga\" 1", "'liga', 'clig' 1", |
michael@0 | 4518 | "\"liga\" off", "\"liga\" 0", '"cv01" 3, "cv02" 4', |
michael@0 | 4519 | '"cswh", "smcp" off, "salt" 4', '"cswh" 1, "smcp" off, "salt" 4', |
michael@0 | 4520 | '"cswh" 0, \'blah\', "liga", "smcp" off, "salt" 4', |
michael@0 | 4521 | '"liga" ,"smcp" 0 , "blah"' |
michael@0 | 4522 | ], |
michael@0 | 4523 | invalid_values: [ |
michael@0 | 4524 | 'liga', 'liga 1', 'liga normal', '"liga" normal', 'normal liga', |
michael@0 | 4525 | 'normal "liga"', 'normal, "liga"', '"liga=1"', "'foobar' on", |
michael@0 | 4526 | '"blahblah" 0', '"liga" 3.14', '"liga" 1 3.14', '"liga" 1 normal', |
michael@0 | 4527 | '"liga" 1 off', '"liga" on off', '"liga" , 0 "smcp"', '"liga" "smcp"' |
michael@0 | 4528 | ] |
michael@0 | 4529 | }, |
michael@0 | 4530 | "font-language-override": { |
michael@0 | 4531 | domProp: "fontLanguageOverride", |
michael@0 | 4532 | inherited: true, |
michael@0 | 4533 | type: CSS_TYPE_SHORTHAND_AND_LONGHAND, |
michael@0 | 4534 | alias_for: "-moz-font-language-override", |
michael@0 | 4535 | subproperties: [ "-moz-font-language-override" ], |
michael@0 | 4536 | initial_values: [ "normal" ], |
michael@0 | 4537 | other_values: [ "'ENG'", "'TRK'", "\"TRK\"", "'N\\'Ko'" ], |
michael@0 | 4538 | invalid_values: [ "TRK", "ja" ] |
michael@0 | 4539 | } |
michael@0 | 4540 | }; |
michael@0 | 4541 | for (var prop in fontFeatureProperties) { |
michael@0 | 4542 | gCSSProperties[prop] = fontFeatureProperties[prop]; |
michael@0 | 4543 | } |
michael@0 | 4544 | var fontAdditions = [ "font-kerning", "font-synthesis", "font-variant-alternates", "font-variant-caps", "font-variant-east-asian", "font-variant-ligatures", "font-variant-numeric", "font-variant-position" ]; |
michael@0 | 4545 | gCSSProperties["font"].subproperties = gCSSProperties["font"].subproperties.concat(fontAdditions); |
michael@0 | 4546 | } |
michael@0 | 4547 | |
michael@0 | 4548 | if (SpecialPowers.getBoolPref("layout.css.masking.enabled")) { |
michael@0 | 4549 | gCSSProperties["mask-type"] = { |
michael@0 | 4550 | domProp: "maskType", |
michael@0 | 4551 | inherited: false, |
michael@0 | 4552 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4553 | initial_values: [ "luminance" ], |
michael@0 | 4554 | other_values: [ "alpha" ], |
michael@0 | 4555 | invalid_values: [] |
michael@0 | 4556 | }; |
michael@0 | 4557 | } |
michael@0 | 4558 | |
michael@0 | 4559 | if (SpecialPowers.getBoolPref("svg.paint-order.enabled")) { |
michael@0 | 4560 | gCSSProperties["paint-order"] = { |
michael@0 | 4561 | domProp: "paintOrder", |
michael@0 | 4562 | inherited: true, |
michael@0 | 4563 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4564 | initial_values: [ "normal" ], |
michael@0 | 4565 | other_values: [ "fill", "fill stroke", "fill stroke markers", "stroke markers fill" ], |
michael@0 | 4566 | invalid_values: [ "fill stroke markers fill", "fill normal" ] |
michael@0 | 4567 | }; |
michael@0 | 4568 | } |
michael@0 | 4569 | |
michael@0 | 4570 | if (SpecialPowers.getBoolPref("layout.css.filters.enabled")) { |
michael@0 | 4571 | gCSSProperties["filter"] = { |
michael@0 | 4572 | domProp: "filter", |
michael@0 | 4573 | inherited: false, |
michael@0 | 4574 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4575 | initial_values: [ "none" ], |
michael@0 | 4576 | other_values: [ |
michael@0 | 4577 | // SVG reference filters |
michael@0 | 4578 | "url(#my-filter)", |
michael@0 | 4579 | "url(#my-filter-1) url(#my-filter-2)", |
michael@0 | 4580 | |
michael@0 | 4581 | // Filter functions |
michael@0 | 4582 | "opacity(50%) saturate(1.0)", |
michael@0 | 4583 | "invert(50%) sepia(0.1) brightness(90%)", |
michael@0 | 4584 | |
michael@0 | 4585 | // Mixed SVG reference filters and filter functions |
michael@0 | 4586 | "grayscale(1) url(#my-filter-1)", |
michael@0 | 4587 | "url(#my-filter-1) brightness(50%) contrast(0.9)", |
michael@0 | 4588 | |
michael@0 | 4589 | // The CSS parser will accept these weird URLs. However, we'll fail |
michael@0 | 4590 | // to resolve them when computing style, so we'll fall back to the |
michael@0 | 4591 | // initial value ("none"). |
michael@0 | 4592 | "url('feed:javascript:5')", |
michael@0 | 4593 | "blur(3px) url('feed:javascript:5') grayscale(50%)", |
michael@0 | 4594 | |
michael@0 | 4595 | "blur(0)", |
michael@0 | 4596 | "blur(0px)", |
michael@0 | 4597 | "blur(0.5px)", |
michael@0 | 4598 | "blur(3px)", |
michael@0 | 4599 | "blur(100px)", |
michael@0 | 4600 | "blur(0.1em)", |
michael@0 | 4601 | "blur(calc(-1px))", // Parses and becomes blur(0px). |
michael@0 | 4602 | "blur(calc(0px))", |
michael@0 | 4603 | "blur(calc(5px))", |
michael@0 | 4604 | "blur(calc(2 * 5px))", |
michael@0 | 4605 | |
michael@0 | 4606 | "brightness(0)", |
michael@0 | 4607 | "brightness(50%)", |
michael@0 | 4608 | "brightness(1)", |
michael@0 | 4609 | "brightness(1.0)", |
michael@0 | 4610 | "brightness(2)", |
michael@0 | 4611 | "brightness(350%)", |
michael@0 | 4612 | "brightness(4.567)", |
michael@0 | 4613 | |
michael@0 | 4614 | "contrast(0)", |
michael@0 | 4615 | "contrast(50%)", |
michael@0 | 4616 | "contrast(1)", |
michael@0 | 4617 | "contrast(1.0)", |
michael@0 | 4618 | "contrast(2)", |
michael@0 | 4619 | "contrast(350%)", |
michael@0 | 4620 | "contrast(4.567)", |
michael@0 | 4621 | |
michael@0 | 4622 | "drop-shadow(2px 2px)", |
michael@0 | 4623 | "drop-shadow(2px 2px 1px)", |
michael@0 | 4624 | "drop-shadow(2px 2px green)", |
michael@0 | 4625 | "drop-shadow(2px 2px 1px green)", |
michael@0 | 4626 | "drop-shadow(green 2px 2px)", |
michael@0 | 4627 | "drop-shadow(green 2px 2px 1px)", |
michael@0 | 4628 | "drop-shadow(currentColor 3px 3px)", |
michael@0 | 4629 | "drop-shadow(2px 2px calc(-5px))", /* clamped */ |
michael@0 | 4630 | "drop-shadow(calc(3em - 2px) 2px green)", |
michael@0 | 4631 | "drop-shadow(green calc(3em - 2px) 2px)", |
michael@0 | 4632 | "drop-shadow(2px calc(2px + 0.2em))", |
michael@0 | 4633 | "drop-shadow(blue 2px calc(2px + 0.2em))", |
michael@0 | 4634 | "drop-shadow(2px calc(2px + 0.2em) blue)", |
michael@0 | 4635 | "drop-shadow(calc(-2px) calc(-2px))", |
michael@0 | 4636 | "drop-shadow(-2px -2px)", |
michael@0 | 4637 | "drop-shadow(calc(2px) calc(2px))", |
michael@0 | 4638 | "drop-shadow(calc(2px) calc(2px) calc(2px))", |
michael@0 | 4639 | |
michael@0 | 4640 | "grayscale(0)", |
michael@0 | 4641 | "grayscale(50%)", |
michael@0 | 4642 | "grayscale(1)", |
michael@0 | 4643 | "grayscale(1.0)", |
michael@0 | 4644 | "grayscale(2)", |
michael@0 | 4645 | "grayscale(350%)", |
michael@0 | 4646 | "grayscale(4.567)", |
michael@0 | 4647 | |
michael@0 | 4648 | "hue-rotate(0deg)", |
michael@0 | 4649 | "hue-rotate(90deg)", |
michael@0 | 4650 | "hue-rotate(540deg)", |
michael@0 | 4651 | "hue-rotate(-90deg)", |
michael@0 | 4652 | "hue-rotate(10grad)", |
michael@0 | 4653 | "hue-rotate(1.6rad)", |
michael@0 | 4654 | "hue-rotate(-1.6rad)", |
michael@0 | 4655 | "hue-rotate(0.5turn)", |
michael@0 | 4656 | "hue-rotate(-2turn)", |
michael@0 | 4657 | |
michael@0 | 4658 | "invert(0)", |
michael@0 | 4659 | "invert(50%)", |
michael@0 | 4660 | "invert(1)", |
michael@0 | 4661 | "invert(1.0)", |
michael@0 | 4662 | "invert(2)", |
michael@0 | 4663 | "invert(350%)", |
michael@0 | 4664 | "invert(4.567)", |
michael@0 | 4665 | |
michael@0 | 4666 | "opacity(0)", |
michael@0 | 4667 | "opacity(50%)", |
michael@0 | 4668 | "opacity(1)", |
michael@0 | 4669 | "opacity(1.0)", |
michael@0 | 4670 | "opacity(2)", |
michael@0 | 4671 | "opacity(350%)", |
michael@0 | 4672 | "opacity(4.567)", |
michael@0 | 4673 | |
michael@0 | 4674 | "saturate(0)", |
michael@0 | 4675 | "saturate(50%)", |
michael@0 | 4676 | "saturate(1)", |
michael@0 | 4677 | "saturate(1.0)", |
michael@0 | 4678 | "saturate(2)", |
michael@0 | 4679 | "saturate(350%)", |
michael@0 | 4680 | "saturate(4.567)", |
michael@0 | 4681 | |
michael@0 | 4682 | "sepia(0)", |
michael@0 | 4683 | "sepia(50%)", |
michael@0 | 4684 | "sepia(1)", |
michael@0 | 4685 | "sepia(1.0)", |
michael@0 | 4686 | "sepia(2)", |
michael@0 | 4687 | "sepia(350%)", |
michael@0 | 4688 | "sepia(4.567)", |
michael@0 | 4689 | ], |
michael@0 | 4690 | invalid_values: [ |
michael@0 | 4691 | // none |
michael@0 | 4692 | "none none", |
michael@0 | 4693 | "url(#my-filter) none", |
michael@0 | 4694 | "none url(#my-filter)", |
michael@0 | 4695 | "blur(2px) none url(#my-filter)", |
michael@0 | 4696 | |
michael@0 | 4697 | // Nested filters |
michael@0 | 4698 | "grayscale(invert(1.0))", |
michael@0 | 4699 | |
michael@0 | 4700 | // Comma delimited filters |
michael@0 | 4701 | "url(#my-filter),", |
michael@0 | 4702 | "invert(50%), url(#my-filter), brightness(90%)", |
michael@0 | 4703 | |
michael@0 | 4704 | // Test the following situations for each filter function: |
michael@0 | 4705 | // - Invalid number of arguments |
michael@0 | 4706 | // - Comma delimited arguments |
michael@0 | 4707 | // - Wrong argument type |
michael@0 | 4708 | // - Argument value out of range |
michael@0 | 4709 | "blur()", |
michael@0 | 4710 | "blur(3px 5px)", |
michael@0 | 4711 | "blur(3px,)", |
michael@0 | 4712 | "blur(3px, 5px)", |
michael@0 | 4713 | "blur(#my-filter)", |
michael@0 | 4714 | "blur(0.5)", |
michael@0 | 4715 | "blur(50%)", |
michael@0 | 4716 | "blur(calc(0))", // Unitless zero in calc is not a valid length. |
michael@0 | 4717 | "blur(calc(0.1))", |
michael@0 | 4718 | "blur(calc(10%))", |
michael@0 | 4719 | "blur(calc(20px - 5%))", |
michael@0 | 4720 | "blur(-3px)", |
michael@0 | 4721 | |
michael@0 | 4722 | "brightness()", |
michael@0 | 4723 | "brightness(0.5 0.5)", |
michael@0 | 4724 | "brightness(0.5,)", |
michael@0 | 4725 | "brightness(0.5, 0.5)", |
michael@0 | 4726 | "brightness(#my-filter)", |
michael@0 | 4727 | "brightness(10px)", |
michael@0 | 4728 | "brightness(-1)", |
michael@0 | 4729 | |
michael@0 | 4730 | "contrast()", |
michael@0 | 4731 | "contrast(0.5 0.5)", |
michael@0 | 4732 | "contrast(0.5,)", |
michael@0 | 4733 | "contrast(0.5, 0.5)", |
michael@0 | 4734 | "contrast(#my-filter)", |
michael@0 | 4735 | "contrast(10px)", |
michael@0 | 4736 | "contrast(-1)", |
michael@0 | 4737 | |
michael@0 | 4738 | "drop-shadow()", |
michael@0 | 4739 | "drop-shadow(3% 3%)", |
michael@0 | 4740 | "drop-shadow(2px 2px -5px)", |
michael@0 | 4741 | "drop-shadow(2px 2px 2px 2px)", |
michael@0 | 4742 | "drop-shadow(2px 2px, none)", |
michael@0 | 4743 | "drop-shadow(none, 2px 2px)", |
michael@0 | 4744 | "drop-shadow(inherit, 2px 2px)", |
michael@0 | 4745 | "drop-shadow(2px 2px, inherit)", |
michael@0 | 4746 | "drop-shadow(2 2px)", |
michael@0 | 4747 | "drop-shadow(2px 2)", |
michael@0 | 4748 | "drop-shadow(2px 2px 2)", |
michael@0 | 4749 | "drop-shadow(2px 2px 2px 2)", |
michael@0 | 4750 | "drop-shadow(calc(2px) calc(2px) calc(2px) calc(2px))", |
michael@0 | 4751 | "drop-shadow(green 2px 2px, blue 1px 3px 4px)", |
michael@0 | 4752 | "drop-shadow(blue 2px 2px, currentColor 1px 2px)", |
michael@0 | 4753 | |
michael@0 | 4754 | "grayscale()", |
michael@0 | 4755 | "grayscale(0.5 0.5)", |
michael@0 | 4756 | "grayscale(0.5,)", |
michael@0 | 4757 | "grayscale(0.5, 0.5)", |
michael@0 | 4758 | "grayscale(#my-filter)", |
michael@0 | 4759 | "grayscale(10px)", |
michael@0 | 4760 | "grayscale(-1)", |
michael@0 | 4761 | |
michael@0 | 4762 | "hue-rotate()", |
michael@0 | 4763 | "hue-rotate(0)", |
michael@0 | 4764 | "hue-rotate(0.5 0.5)", |
michael@0 | 4765 | "hue-rotate(0.5,)", |
michael@0 | 4766 | "hue-rotate(0.5, 0.5)", |
michael@0 | 4767 | "hue-rotate(#my-filter)", |
michael@0 | 4768 | "hue-rotate(10px)", |
michael@0 | 4769 | "hue-rotate(-1)", |
michael@0 | 4770 | "hue-rotate(45deg,)", |
michael@0 | 4771 | |
michael@0 | 4772 | "invert()", |
michael@0 | 4773 | "invert(0.5 0.5)", |
michael@0 | 4774 | "invert(0.5,)", |
michael@0 | 4775 | "invert(0.5, 0.5)", |
michael@0 | 4776 | "invert(#my-filter)", |
michael@0 | 4777 | "invert(10px)", |
michael@0 | 4778 | "invert(-1)", |
michael@0 | 4779 | |
michael@0 | 4780 | "opacity()", |
michael@0 | 4781 | "opacity(0.5 0.5)", |
michael@0 | 4782 | "opacity(0.5,)", |
michael@0 | 4783 | "opacity(0.5, 0.5)", |
michael@0 | 4784 | "opacity(#my-filter)", |
michael@0 | 4785 | "opacity(10px)", |
michael@0 | 4786 | "opacity(-1)", |
michael@0 | 4787 | |
michael@0 | 4788 | "saturate()", |
michael@0 | 4789 | "saturate(0.5 0.5)", |
michael@0 | 4790 | "saturate(0.5,)", |
michael@0 | 4791 | "saturate(0.5, 0.5)", |
michael@0 | 4792 | "saturate(#my-filter)", |
michael@0 | 4793 | "saturate(10px)", |
michael@0 | 4794 | "saturate(-1)", |
michael@0 | 4795 | |
michael@0 | 4796 | "sepia()", |
michael@0 | 4797 | "sepia(0.5 0.5)", |
michael@0 | 4798 | "sepia(0.5,)", |
michael@0 | 4799 | "sepia(0.5, 0.5)", |
michael@0 | 4800 | "sepia(#my-filter)", |
michael@0 | 4801 | "sepia(10px)", |
michael@0 | 4802 | "sepia(-1)", |
michael@0 | 4803 | ] |
michael@0 | 4804 | }; |
michael@0 | 4805 | } |
michael@0 | 4806 | |
michael@0 | 4807 | if (SpecialPowers.getBoolPref("layout.css.grid.enabled")) { |
michael@0 | 4808 | gCSSProperties["display"].other_values.push("grid", "inline-grid"); |
michael@0 | 4809 | gCSSProperties["grid-auto-flow"] = { |
michael@0 | 4810 | domProp: "gridAutoFlow", |
michael@0 | 4811 | inherited: false, |
michael@0 | 4812 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4813 | initial_values: [ "none" ], |
michael@0 | 4814 | other_values: [ |
michael@0 | 4815 | "column", |
michael@0 | 4816 | "row", |
michael@0 | 4817 | "column dense", |
michael@0 | 4818 | "row dense", |
michael@0 | 4819 | "dense column", |
michael@0 | 4820 | "dense row", |
michael@0 | 4821 | ], |
michael@0 | 4822 | invalid_values: [ |
michael@0 | 4823 | "", |
michael@0 | 4824 | "auto", |
michael@0 | 4825 | "10px", |
michael@0 | 4826 | "dense", |
michael@0 | 4827 | "none row", |
michael@0 | 4828 | "none dense", |
michael@0 | 4829 | "column row", |
michael@0 | 4830 | "dense row dense", |
michael@0 | 4831 | ] |
michael@0 | 4832 | }; |
michael@0 | 4833 | |
michael@0 | 4834 | gCSSProperties["grid-auto-columns"] = { |
michael@0 | 4835 | domProp: "gridAutoColumns", |
michael@0 | 4836 | inherited: false, |
michael@0 | 4837 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4838 | initial_values: [ "auto" ], |
michael@0 | 4839 | other_values: [ |
michael@0 | 4840 | "40px", |
michael@0 | 4841 | "2em", |
michael@0 | 4842 | "2.5fr", |
michael@0 | 4843 | "12%", |
michael@0 | 4844 | "min-content", |
michael@0 | 4845 | "max-content", |
michael@0 | 4846 | "calc(20px + 10%)", |
michael@0 | 4847 | "minmax(20px, max-content)", |
michael@0 | 4848 | "m\\69nmax(20px, 4Fr)", |
michael@0 | 4849 | "MinMax(min-content, calc(20px + 10%))", |
michael@0 | 4850 | ], |
michael@0 | 4851 | invalid_values: [ |
michael@0 | 4852 | "", |
michael@0 | 4853 | "normal", |
michael@0 | 4854 | "40ms", |
michael@0 | 4855 | "-40px", |
michael@0 | 4856 | "-12%", |
michael@0 | 4857 | "-2em", |
michael@0 | 4858 | "-2.5fr", |
michael@0 | 4859 | "minmax()", |
michael@0 | 4860 | "minmax(20px)", |
michael@0 | 4861 | "mİnmax(20px, 100px)", |
michael@0 | 4862 | "minmax(20px, 100px, 200px)", |
michael@0 | 4863 | "maxmin(100px, 20px)", |
michael@0 | 4864 | "minmax(min-content, auto)", |
michael@0 | 4865 | "minmax(min-content, minmax(30px, max-content))", |
michael@0 | 4866 | ] |
michael@0 | 4867 | }; |
michael@0 | 4868 | gCSSProperties["grid-auto-rows"] = { |
michael@0 | 4869 | domProp: "gridAutoRows", |
michael@0 | 4870 | inherited: false, |
michael@0 | 4871 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4872 | initial_values: gCSSProperties["grid-auto-columns"].initial_values, |
michael@0 | 4873 | other_values: gCSSProperties["grid-auto-columns"].other_values, |
michael@0 | 4874 | invalid_values: gCSSProperties["grid-auto-columns"].invalid_values |
michael@0 | 4875 | }; |
michael@0 | 4876 | |
michael@0 | 4877 | gCSSProperties["grid-template-columns"] = { |
michael@0 | 4878 | domProp: "gridTemplateColumns", |
michael@0 | 4879 | inherited: false, |
michael@0 | 4880 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4881 | initial_values: [ "none" ], |
michael@0 | 4882 | other_values: [ |
michael@0 | 4883 | "auto", |
michael@0 | 4884 | "40px", |
michael@0 | 4885 | "2.5fr", |
michael@0 | 4886 | "(normal) 40px () auto ( ) 12%", |
michael@0 | 4887 | "(foo) 40px min-content ( bar ) calc(20px + 10%) max-content", |
michael@0 | 4888 | "40px min-content calc(20px + 10%) max-content", |
michael@0 | 4889 | "m\\69nmax(20px, 4Fr)", |
michael@0 | 4890 | "40px MinMax(min-content, calc(20px + 10%)) max-content", |
michael@0 | 4891 | "40px 2em", |
michael@0 | 4892 | "() 40px (-foo) 2em (bar baz This\ is\ one\ ident)", |
michael@0 | 4893 | // TODO bug 978478: "(a) repeat(3, (b) 20px (c) 40px (d)) (e)", |
michael@0 | 4894 | "repeat(1, 20px)", |
michael@0 | 4895 | "repeat(1, (a) 20px)", |
michael@0 | 4896 | "(a) Repeat(4, (a) 20px () auto (b c)) (d)", |
michael@0 | 4897 | "(a) 2.5fr Repeat(4, (a) 20px () auto (b c)) (d)", |
michael@0 | 4898 | "(a) 2.5fr (z) Repeat(4, (a) 20px () auto (b c)) (d)", |
michael@0 | 4899 | "(a) 2.5fr (z) Repeat(4, (a) 20px () auto) (d)", |
michael@0 | 4900 | "(a) 2.5fr (z) Repeat(4, 20px (b c) auto (b c)) (d)", |
michael@0 | 4901 | "(a) 2.5fr (z) Repeat(4, 20px auto) (d)", |
michael@0 | 4902 | |
michael@0 | 4903 | // See https://bugzilla.mozilla.org/show_bug.cgi?id=981300 |
michael@0 | 4904 | "(none auto subgrid min-content max-content foo) 40px", |
michael@0 | 4905 | |
michael@0 | 4906 | "subgrid", |
michael@0 | 4907 | "subgrid () (foo bar)", |
michael@0 | 4908 | "subgrid repeat(1, ())", |
michael@0 | 4909 | "subgrid Repeat(4, (a) (b c) () (d))", |
michael@0 | 4910 | ], |
michael@0 | 4911 | invalid_values: [ |
michael@0 | 4912 | "", |
michael@0 | 4913 | "normal", |
michael@0 | 4914 | "40ms", |
michael@0 | 4915 | "-40px", |
michael@0 | 4916 | "-12%", |
michael@0 | 4917 | "-2fr", |
michael@0 | 4918 | "(foo)", |
michael@0 | 4919 | "(inherit) 40px", |
michael@0 | 4920 | "(initial) 40px", |
michael@0 | 4921 | "(unset) 40px", |
michael@0 | 4922 | "(default) 40px", |
michael@0 | 4923 | "(6%) 40px", |
michael@0 | 4924 | "(5th) 40px", |
michael@0 | 4925 | "(foo() bar) 40px", |
michael@0 | 4926 | "(foo)) 40px", |
michael@0 | 4927 | "[foo] 40px", |
michael@0 | 4928 | "(foo) (bar) 40px", |
michael@0 | 4929 | "40px (foo) (bar)", |
michael@0 | 4930 | "minmax()", |
michael@0 | 4931 | "minmax(20px)", |
michael@0 | 4932 | "mİnmax(20px, 100px)", |
michael@0 | 4933 | "minmax(20px, 100px, 200px)", |
michael@0 | 4934 | "maxmin(100px, 20px)", |
michael@0 | 4935 | "minmax(min-content, auto)", |
michael@0 | 4936 | "minmax(min-content, minmax(30px, max-content))", |
michael@0 | 4937 | "repeat(0, 20px)", |
michael@0 | 4938 | "repeat(-3, 20px)", |
michael@0 | 4939 | "rêpeat(1, 20px)", |
michael@0 | 4940 | "repeat(1)", |
michael@0 | 4941 | "repeat(1, )", |
michael@0 | 4942 | "repeat(3px, 20px)", |
michael@0 | 4943 | "repeat(2.0, 20px)", |
michael@0 | 4944 | "repeat(2.5, 20px)", |
michael@0 | 4945 | "repeat(2, (foo))", |
michael@0 | 4946 | "repeat(2, foo)", |
michael@0 | 4947 | "subgrid (foo) 40px", |
michael@0 | 4948 | "subgrid (foo 40px)", |
michael@0 | 4949 | "(foo) subgrid", |
michael@0 | 4950 | "subgrid rêpeat(1, ())", |
michael@0 | 4951 | "subgrid repeat(0, ())", |
michael@0 | 4952 | "subgrid repeat(-3, ())", |
michael@0 | 4953 | "subgrid repeat(2.0, ())", |
michael@0 | 4954 | "subgrid repeat(2.5, ())", |
michael@0 | 4955 | "subgrid repeat(3px, ())", |
michael@0 | 4956 | "subgrid repeat(1)", |
michael@0 | 4957 | "subgrid repeat(1, )", |
michael@0 | 4958 | "subgrid repeat(2, (40px))", |
michael@0 | 4959 | "subgrid repeat(2, foo)", |
michael@0 | 4960 | ], |
michael@0 | 4961 | unbalanced_values: [ |
michael@0 | 4962 | "(foo] 40px", |
michael@0 | 4963 | ] |
michael@0 | 4964 | }; |
michael@0 | 4965 | gCSSProperties["grid-template-rows"] = { |
michael@0 | 4966 | domProp: "gridTemplateRows", |
michael@0 | 4967 | inherited: false, |
michael@0 | 4968 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4969 | initial_values: gCSSProperties["grid-template-columns"].initial_values, |
michael@0 | 4970 | other_values: gCSSProperties["grid-template-columns"].other_values, |
michael@0 | 4971 | invalid_values: gCSSProperties["grid-template-columns"].invalid_values |
michael@0 | 4972 | }; |
michael@0 | 4973 | gCSSProperties["grid-template-areas"] = { |
michael@0 | 4974 | domProp: "gridTemplateAreas", |
michael@0 | 4975 | inherited: false, |
michael@0 | 4976 | type: CSS_TYPE_LONGHAND, |
michael@0 | 4977 | initial_values: [ "none" ], |
michael@0 | 4978 | other_values: [ |
michael@0 | 4979 | "''", |
michael@0 | 4980 | "'' ''", |
michael@0 | 4981 | "'1a-é_ .' \"b .\"", |
michael@0 | 4982 | "' Z\t\\aZ' 'Z Z'", |
michael@0 | 4983 | " '. . a b' '..a b' ", |
michael@0 | 4984 | ], |
michael@0 | 4985 | invalid_values: [ |
michael@0 | 4986 | "'a b' 'a/b'", |
michael@0 | 4987 | "'a . a'", |
michael@0 | 4988 | "'. a a' 'a a a'", |
michael@0 | 4989 | "'a a .' 'a a a'", |
michael@0 | 4990 | "'a a' 'a .'", |
michael@0 | 4991 | "'a a'\n'..'\n'a a'", |
michael@0 | 4992 | ] |
michael@0 | 4993 | }; |
michael@0 | 4994 | |
michael@0 | 4995 | gCSSProperties["grid-template"] = { |
michael@0 | 4996 | domProp: "gridTemplate", |
michael@0 | 4997 | inherited: false, |
michael@0 | 4998 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 4999 | subproperties: [ |
michael@0 | 5000 | "grid-template-areas", |
michael@0 | 5001 | "grid-template-columns", |
michael@0 | 5002 | "grid-template-rows", |
michael@0 | 5003 | ], |
michael@0 | 5004 | initial_values: [ |
michael@0 | 5005 | "none", |
michael@0 | 5006 | "none / none", |
michael@0 | 5007 | ], |
michael@0 | 5008 | other_values: [ |
michael@0 | 5009 | "subgrid", |
michael@0 | 5010 | // <'grid-template-columns'> / <'grid-template-rows'> |
michael@0 | 5011 | "40px / 100px", |
michael@0 | 5012 | "(foo) 40px (bar) / (baz) 100px (fizz)", |
michael@0 | 5013 | " none/100px", |
michael@0 | 5014 | "40px/none", |
michael@0 | 5015 | "subgrid/40px 20px", |
michael@0 | 5016 | "subgrid (foo) () (bar baz) / 40px 20px", |
michael@0 | 5017 | "40px 20px/subgrid", |
michael@0 | 5018 | "40px 20px/subgrid (foo) () repeat(3, (a) (b)) (bar baz)", |
michael@0 | 5019 | "subgrid/subgrid", |
michael@0 | 5020 | "subgrid (foo) () (bar baz)/subgrid (foo) () (bar baz)", |
michael@0 | 5021 | // [ <track-list> / ]? [ <line-names>? <string> <track-size>? <line-names>? ]+ |
michael@0 | 5022 | "'fizz'", |
michael@0 | 5023 | "(bar) 'fizz'", |
michael@0 | 5024 | "(foo) 40px / 'fizz'", |
michael@0 | 5025 | "(foo) 40px / (bar) 'fizz'", |
michael@0 | 5026 | "(foo) 40px / 'fizz' 100px", |
michael@0 | 5027 | "(foo) 40px / (bar) 'fizz' 100px", |
michael@0 | 5028 | "(foo) 40px / (bar) 'fizz' 100px (buzz)", |
michael@0 | 5029 | "(foo) 40px / (bar) 'fizz' 100px (buzz) \n (a) '.' 200px (b)", |
michael@0 | 5030 | ], |
michael@0 | 5031 | invalid_values: [ |
michael@0 | 5032 | "subgrid ()", |
michael@0 | 5033 | "subgrid () / 'fizz'", |
michael@0 | 5034 | "subgrid / 'fizz'", |
michael@0 | 5035 | "(foo) (bar) 40px / 100px", |
michael@0 | 5036 | "40px / (fizz) (buzz) 100px", |
michael@0 | 5037 | "40px / (fizz) (buzz) 'foo'", |
michael@0 | 5038 | "none / 'foo'" |
michael@0 | 5039 | ] |
michael@0 | 5040 | }; |
michael@0 | 5041 | |
michael@0 | 5042 | gCSSProperties["grid"] = { |
michael@0 | 5043 | domProp: "grid", |
michael@0 | 5044 | inherited: false, |
michael@0 | 5045 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 5046 | subproperties: [ |
michael@0 | 5047 | "grid-template-areas", |
michael@0 | 5048 | "grid-template-columns", |
michael@0 | 5049 | "grid-template-rows", |
michael@0 | 5050 | "grid-auto-flow", |
michael@0 | 5051 | "grid-auto-columns", |
michael@0 | 5052 | "grid-auto-rows", |
michael@0 | 5053 | ], |
michael@0 | 5054 | initial_values: [ |
michael@0 | 5055 | "none", |
michael@0 | 5056 | "none / none", |
michael@0 | 5057 | "none auto", |
michael@0 | 5058 | "none auto / auto", |
michael@0 | 5059 | ], |
michael@0 | 5060 | other_values: [ |
michael@0 | 5061 | "row", |
michael@0 | 5062 | "none 40px", |
michael@0 | 5063 | "column dense auto", |
michael@0 | 5064 | "dense row minmax(min-content, 2fr)", |
michael@0 | 5065 | "row 40px / 100px", |
michael@0 | 5066 | ].concat( |
michael@0 | 5067 | gCSSProperties["grid-template"].other_values, |
michael@0 | 5068 | gCSSProperties["grid-auto-flow"].other_values |
michael@0 | 5069 | ), |
michael@0 | 5070 | invalid_values: [ |
michael@0 | 5071 | "row column 40px", |
michael@0 | 5072 | "row -20px", |
michael@0 | 5073 | "row 200ms", |
michael@0 | 5074 | "row 40px 100px", |
michael@0 | 5075 | ].concat( |
michael@0 | 5076 | gCSSProperties["grid-template"].invalid_values, |
michael@0 | 5077 | gCSSProperties["grid-auto-flow"].invalid_values |
michael@0 | 5078 | ) |
michael@0 | 5079 | }; |
michael@0 | 5080 | |
michael@0 | 5081 | var gridLineOtherValues = [ |
michael@0 | 5082 | "foo", |
michael@0 | 5083 | "2", |
michael@0 | 5084 | "2 foo", |
michael@0 | 5085 | "foo 2", |
michael@0 | 5086 | "-3", |
michael@0 | 5087 | "-3 bar", |
michael@0 | 5088 | "bar -3", |
michael@0 | 5089 | "span 2", |
michael@0 | 5090 | "2 span", |
michael@0 | 5091 | "span foo", |
michael@0 | 5092 | "foo span", |
michael@0 | 5093 | "span 2 foo", |
michael@0 | 5094 | "span foo 2", |
michael@0 | 5095 | "2 foo span", |
michael@0 | 5096 | "foo 2 span", |
michael@0 | 5097 | ]; |
michael@0 | 5098 | var gridLineInvalidValues = [ |
michael@0 | 5099 | "", |
michael@0 | 5100 | "4th", |
michael@0 | 5101 | "span", |
michael@0 | 5102 | "inherit 2", |
michael@0 | 5103 | "2 inherit", |
michael@0 | 5104 | "20px", |
michael@0 | 5105 | "2 3", |
michael@0 | 5106 | "2.5", |
michael@0 | 5107 | "2.0", |
michael@0 | 5108 | "0", |
michael@0 | 5109 | "0 foo", |
michael@0 | 5110 | "span 0", |
michael@0 | 5111 | "2 foo 3", |
michael@0 | 5112 | "foo 2 foo", |
michael@0 | 5113 | "2 span foo", |
michael@0 | 5114 | "foo span 2", |
michael@0 | 5115 | "span -3", |
michael@0 | 5116 | "span -3 bar", |
michael@0 | 5117 | "span 2 span", |
michael@0 | 5118 | "span foo span", |
michael@0 | 5119 | "span 2 foo span", |
michael@0 | 5120 | ]; |
michael@0 | 5121 | |
michael@0 | 5122 | gCSSProperties["grid-column-start"] = { |
michael@0 | 5123 | domProp: "gridColumnStart", |
michael@0 | 5124 | inherited: false, |
michael@0 | 5125 | type: CSS_TYPE_LONGHAND, |
michael@0 | 5126 | initial_values: [ "auto" ], |
michael@0 | 5127 | other_values: gridLineOtherValues, |
michael@0 | 5128 | invalid_values: gridLineInvalidValues |
michael@0 | 5129 | }; |
michael@0 | 5130 | gCSSProperties["grid-column-end"] = { |
michael@0 | 5131 | domProp: "gridColumnEnd", |
michael@0 | 5132 | inherited: false, |
michael@0 | 5133 | type: CSS_TYPE_LONGHAND, |
michael@0 | 5134 | initial_values: [ "auto" ], |
michael@0 | 5135 | other_values: gridLineOtherValues, |
michael@0 | 5136 | invalid_values: gridLineInvalidValues |
michael@0 | 5137 | }; |
michael@0 | 5138 | gCSSProperties["grid-row-start"] = { |
michael@0 | 5139 | domProp: "gridRowStart", |
michael@0 | 5140 | inherited: false, |
michael@0 | 5141 | type: CSS_TYPE_LONGHAND, |
michael@0 | 5142 | initial_values: [ "auto" ], |
michael@0 | 5143 | other_values: gridLineOtherValues, |
michael@0 | 5144 | invalid_values: gridLineInvalidValues |
michael@0 | 5145 | }; |
michael@0 | 5146 | gCSSProperties["grid-row-end"] = { |
michael@0 | 5147 | domProp: "gridRowEnd", |
michael@0 | 5148 | inherited: false, |
michael@0 | 5149 | type: CSS_TYPE_LONGHAND, |
michael@0 | 5150 | initial_values: [ "auto" ], |
michael@0 | 5151 | other_values: gridLineOtherValues, |
michael@0 | 5152 | invalid_values: gridLineInvalidValues |
michael@0 | 5153 | }; |
michael@0 | 5154 | |
michael@0 | 5155 | var gridAutoPositionOtherValues = []; |
michael@0 | 5156 | gridLineOtherValues.concat([ "auto" ]).forEach(function(val) { |
michael@0 | 5157 | gridAutoPositionOtherValues.push(" foo / " + val); |
michael@0 | 5158 | gridAutoPositionOtherValues.push(val + "/2"); |
michael@0 | 5159 | }); |
michael@0 | 5160 | var gridAutoPositionInvalidValues = [ |
michael@0 | 5161 | "foo", |
michael@0 | 5162 | "foo, bar", |
michael@0 | 5163 | "foo / bar / baz", |
michael@0 | 5164 | ]; |
michael@0 | 5165 | gridLineInvalidValues.forEach(function(val) { |
michael@0 | 5166 | gridAutoPositionInvalidValues.push("span 3 / " + val); |
michael@0 | 5167 | gridAutoPositionInvalidValues.push(val + " / foo"); |
michael@0 | 5168 | }); |
michael@0 | 5169 | gCSSProperties["grid-auto-position"] = { |
michael@0 | 5170 | domProp: "gridAutoPosition", |
michael@0 | 5171 | inherited: false, |
michael@0 | 5172 | type: CSS_TYPE_LONGHAND, |
michael@0 | 5173 | initial_values: [ "1 / 1" ], |
michael@0 | 5174 | other_values: gridAutoPositionOtherValues, |
michael@0 | 5175 | invalid_values: gridAutoPositionInvalidValues |
michael@0 | 5176 | }; |
michael@0 | 5177 | |
michael@0 | 5178 | // The grid-column and grid-row shorthands take values of the form |
michael@0 | 5179 | // <grid-line> [ / <grid-line> ]? |
michael@0 | 5180 | // which is equivalent to: |
michael@0 | 5181 | // <grid-line> | [ <grid-line> / <grid-line> ] |
michael@0 | 5182 | // which is equivalent to: |
michael@0 | 5183 | // <grid-line> | <'grid-auto-position'> |
michael@0 | 5184 | var gridColumnRowOtherValues = [].concat( |
michael@0 | 5185 | gridLineOtherValues, |
michael@0 | 5186 | gridAutoPositionOtherValues); |
michael@0 | 5187 | var gridColumnRowInvalidValues = [].concat( |
michael@0 | 5188 | gridLineInvalidValues, |
michael@0 | 5189 | gridAutoPositionInvalidValues); |
michael@0 | 5190 | // A single <grid-line> is invalid for grid-auto-position, |
michael@0 | 5191 | // but not for grid-column or grid-row: |
michael@0 | 5192 | gridColumnRowInvalidValues.splice( |
michael@0 | 5193 | gridColumnRowInvalidValues.indexOf("foo"), |
michael@0 | 5194 | 1); |
michael@0 | 5195 | gCSSProperties["grid-column"] = { |
michael@0 | 5196 | domProp: "gridColumn", |
michael@0 | 5197 | inherited: false, |
michael@0 | 5198 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 5199 | subproperties: [ |
michael@0 | 5200 | "grid-column-start", |
michael@0 | 5201 | "grid-column-end" |
michael@0 | 5202 | ], |
michael@0 | 5203 | initial_values: [ "auto", "auto / auto" ], |
michael@0 | 5204 | other_values: gridColumnRowOtherValues, |
michael@0 | 5205 | invalid_values: gridColumnRowInvalidValues |
michael@0 | 5206 | }; |
michael@0 | 5207 | gCSSProperties["grid-row"] = { |
michael@0 | 5208 | domProp: "gridRow", |
michael@0 | 5209 | inherited: false, |
michael@0 | 5210 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 5211 | subproperties: [ |
michael@0 | 5212 | "grid-row-start", |
michael@0 | 5213 | "grid-row-end" |
michael@0 | 5214 | ], |
michael@0 | 5215 | initial_values: [ "auto", "auto / auto" ], |
michael@0 | 5216 | other_values: gridColumnRowOtherValues, |
michael@0 | 5217 | invalid_values: gridColumnRowInvalidValues |
michael@0 | 5218 | }; |
michael@0 | 5219 | |
michael@0 | 5220 | var gridAreaOtherValues = gridLineOtherValues.slice(); |
michael@0 | 5221 | gridLineOtherValues.forEach(function(val) { |
michael@0 | 5222 | gridAreaOtherValues.push("foo / " + val); |
michael@0 | 5223 | gridAreaOtherValues.push(val + "/2/3"); |
michael@0 | 5224 | gridAreaOtherValues.push("foo / bar / " + val + " / baz"); |
michael@0 | 5225 | }); |
michael@0 | 5226 | var gridAreaInvalidValues = [ |
michael@0 | 5227 | "foo, bar", |
michael@0 | 5228 | "foo / bar / baz / fizz / buzz", |
michael@0 | 5229 | "default / foo / bar / baz", |
michael@0 | 5230 | "foo / initial / bar / baz", |
michael@0 | 5231 | "foo / bar / inherit / baz", |
michael@0 | 5232 | "foo / bar / baz / unset", |
michael@0 | 5233 | ].concat(gridLineInvalidValues); |
michael@0 | 5234 | gridLineInvalidValues.forEach(function(val) { |
michael@0 | 5235 | gridAreaInvalidValues.push("foo / " + val); |
michael@0 | 5236 | gridAreaInvalidValues.push("foo / bar / " + val); |
michael@0 | 5237 | gridAreaInvalidValues.push("foo / 4 / bar / " + val); |
michael@0 | 5238 | }); |
michael@0 | 5239 | |
michael@0 | 5240 | gCSSProperties["grid-area"] = { |
michael@0 | 5241 | domProp: "gridArea", |
michael@0 | 5242 | inherited: false, |
michael@0 | 5243 | type: CSS_TYPE_TRUE_SHORTHAND, |
michael@0 | 5244 | subproperties: [ |
michael@0 | 5245 | "grid-row-start", |
michael@0 | 5246 | "grid-column-start", |
michael@0 | 5247 | "grid-row-end", |
michael@0 | 5248 | "grid-column-end" |
michael@0 | 5249 | ], |
michael@0 | 5250 | initial_values: [ |
michael@0 | 5251 | "auto", |
michael@0 | 5252 | "auto / auto", |
michael@0 | 5253 | "auto / auto / auto", |
michael@0 | 5254 | "auto / auto / auto / auto" |
michael@0 | 5255 | ], |
michael@0 | 5256 | other_values: gridAreaOtherValues, |
michael@0 | 5257 | invalid_values: gridAreaInvalidValues |
michael@0 | 5258 | }; |
michael@0 | 5259 | } |
michael@0 | 5260 | |
michael@0 | 5261 | if (SpecialPowers.getBoolPref("layout.css.image-orientation.enabled")) { |
michael@0 | 5262 | gCSSProperties["image-orientation"] = { |
michael@0 | 5263 | domProp: "imageOrientation", |
michael@0 | 5264 | inherited: true, |
michael@0 | 5265 | type: CSS_TYPE_LONGHAND, |
michael@0 | 5266 | initial_values: [ |
michael@0 | 5267 | "0deg", |
michael@0 | 5268 | "0grad", |
michael@0 | 5269 | "0rad", |
michael@0 | 5270 | "0turn", |
michael@0 | 5271 | |
michael@0 | 5272 | // Rounded initial values. |
michael@0 | 5273 | "-90deg", |
michael@0 | 5274 | "15deg", |
michael@0 | 5275 | "360deg", |
michael@0 | 5276 | ], |
michael@0 | 5277 | other_values: [ |
michael@0 | 5278 | "0deg flip", |
michael@0 | 5279 | "90deg", |
michael@0 | 5280 | "90deg flip", |
michael@0 | 5281 | "180deg", |
michael@0 | 5282 | "180deg flip", |
michael@0 | 5283 | "270deg", |
michael@0 | 5284 | "270deg flip", |
michael@0 | 5285 | "flip", |
michael@0 | 5286 | "from-image", |
michael@0 | 5287 | |
michael@0 | 5288 | // Grad units. |
michael@0 | 5289 | "0grad flip", |
michael@0 | 5290 | "100grad", |
michael@0 | 5291 | "100grad flip", |
michael@0 | 5292 | "200grad", |
michael@0 | 5293 | "200grad flip", |
michael@0 | 5294 | "300grad", |
michael@0 | 5295 | "300grad flip", |
michael@0 | 5296 | |
michael@0 | 5297 | // Radian units. |
michael@0 | 5298 | "0rad flip", |
michael@0 | 5299 | "1.57079633rad", |
michael@0 | 5300 | "1.57079633rad flip", |
michael@0 | 5301 | "3.14159265rad", |
michael@0 | 5302 | "3.14159265rad flip", |
michael@0 | 5303 | "4.71238898rad", |
michael@0 | 5304 | "4.71238898rad flip", |
michael@0 | 5305 | |
michael@0 | 5306 | // Turn units. |
michael@0 | 5307 | "0turn flip", |
michael@0 | 5308 | "0.25turn", |
michael@0 | 5309 | "0.25turn flip", |
michael@0 | 5310 | "0.5turn", |
michael@0 | 5311 | "0.5turn flip", |
michael@0 | 5312 | "0.75turn", |
michael@0 | 5313 | "0.75turn flip", |
michael@0 | 5314 | |
michael@0 | 5315 | // Rounded values. |
michael@0 | 5316 | "-45deg flip", |
michael@0 | 5317 | "65deg flip", |
michael@0 | 5318 | "400deg flip", |
michael@0 | 5319 | ], |
michael@0 | 5320 | invalid_values: [ |
michael@0 | 5321 | "none", |
michael@0 | 5322 | "0deg none", |
michael@0 | 5323 | "flip 0deg", |
michael@0 | 5324 | "flip 0deg", |
michael@0 | 5325 | "0", |
michael@0 | 5326 | "0 flip", |
michael@0 | 5327 | "flip 0", |
michael@0 | 5328 | "0deg from-image", |
michael@0 | 5329 | "from-image 0deg", |
michael@0 | 5330 | "flip from-image", |
michael@0 | 5331 | "from-image flip", |
michael@0 | 5332 | ] |
michael@0 | 5333 | }; |
michael@0 | 5334 | } |
michael@0 | 5335 | |
michael@0 | 5336 | if (SpecialPowers.getBoolPref("layout.css.osx-font-smoothing.enabled")) { |
michael@0 | 5337 | gCSSProperties["-moz-osx-font-smoothing"] = { |
michael@0 | 5338 | domProp: "MozOSXFontSmoothing", |
michael@0 | 5339 | inherited: true, |
michael@0 | 5340 | type: CSS_TYPE_LONGHAND, |
michael@0 | 5341 | initial_values: [ "auto" ], |
michael@0 | 5342 | other_values: [ "grayscale" ], |
michael@0 | 5343 | invalid_values: [ "none", "subpixel-antialiased", "antialiased" ] |
michael@0 | 5344 | }; |
michael@0 | 5345 | } |
michael@0 | 5346 | |
michael@0 | 5347 | if (SpecialPowers.getBoolPref("layout.css.sticky.enabled")) { |
michael@0 | 5348 | gCSSProperties["position"].other_values.push("sticky"); |
michael@0 | 5349 | } |
michael@0 | 5350 | |
michael@0 | 5351 | if (SpecialPowers.getBoolPref("layout.css.mix-blend-mode.enabled")) { |
michael@0 | 5352 | gCSSProperties["mix-blend-mode"] = { |
michael@0 | 5353 | domProp: "mixBlendMode", |
michael@0 | 5354 | inherited: false, |
michael@0 | 5355 | type: CSS_TYPE_LONGHAND, |
michael@0 | 5356 | initial_values: [ "normal" ], |
michael@0 | 5357 | other_values: ["multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", |
michael@0 | 5358 | "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"], |
michael@0 | 5359 | invalid_values: [] |
michael@0 | 5360 | }; |
michael@0 | 5361 | } |
michael@0 | 5362 | |
michael@0 | 5363 | if (SpecialPowers.getBoolPref("layout.css.background-blend-mode.enabled")) { |
michael@0 | 5364 | gCSSProperties["background-blend-mode"] = { |
michael@0 | 5365 | domProp: "backgroundBlendMode", |
michael@0 | 5366 | inherited: false, |
michael@0 | 5367 | type: CSS_TYPE_LONGHAND, |
michael@0 | 5368 | initial_values: [ "normal" ], |
michael@0 | 5369 | other_values: [ "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", |
michael@0 | 5370 | "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity" ], |
michael@0 | 5371 | invalid_values: ["none", "10px", "multiply multiply"] |
michael@0 | 5372 | }; |
michael@0 | 5373 | } |
michael@0 | 5374 | |
michael@0 | 5375 | if (SpecialPowers.getBoolPref("layout.css.will-change.enabled")) { |
michael@0 | 5376 | gCSSProperties["will-change"] = { |
michael@0 | 5377 | domProp: "willChange", |
michael@0 | 5378 | inherited: false, |
michael@0 | 5379 | type: CSS_TYPE_LONGHAND, |
michael@0 | 5380 | initial_values: [ "auto" ], |
michael@0 | 5381 | other_values: [ "scroll-position", "contents", "transform", "opacity", "scroll-position, transform", "transform, opacity", "contents, transform", "property-that-doesnt-exist-yet" ], |
michael@0 | 5382 | invalid_values: [ "none", "all", "default", "auto, scroll-position", "scroll-position, auto", "transform scroll-position", ",", "trailing," ] |
michael@0 | 5383 | }; |
michael@0 | 5384 | } |
michael@0 | 5385 | |
michael@0 | 5386 | if (SpecialPowers.getBoolPref("layout.css.overflow-clip-box.enabled")) { |
michael@0 | 5387 | gCSSProperties["overflow-clip-box"] = { |
michael@0 | 5388 | domProp: "overflowClipBox", |
michael@0 | 5389 | inherited: false, |
michael@0 | 5390 | type: CSS_TYPE_LONGHAND, |
michael@0 | 5391 | initial_values: [ "padding-box" ], |
michael@0 | 5392 | other_values: [ "content-box" ], |
michael@0 | 5393 | invalid_values: [ "none", "auto", "border-box", "0" ] |
michael@0 | 5394 | }; |
michael@0 | 5395 | } |
michael@0 | 5396 | |
michael@0 | 5397 | if (SpecialPowers.getBoolPref("layout.css.unset-value.enabled")) { |
michael@0 | 5398 | gCSSProperties["animation-direction"].invalid_values.push("normal, unset"); |
michael@0 | 5399 | gCSSProperties["animation-name"].invalid_values.push("bounce, unset", "unset, bounce"); |
michael@0 | 5400 | gCSSProperties["-moz-border-bottom-colors"].invalid_values.push("red unset", "unset red"); |
michael@0 | 5401 | gCSSProperties["-moz-border-left-colors"].invalid_values.push("red unset", "unset red"); |
michael@0 | 5402 | gCSSProperties["border-radius"].invalid_values.push("unset 2px", "unset / 2px", "2px unset", "2px / unset"); |
michael@0 | 5403 | gCSSProperties["border-bottom-left-radius"].invalid_values.push("unset 2px", "2px unset"); |
michael@0 | 5404 | gCSSProperties["border-bottom-right-radius"].invalid_values.push("unset 2px", "2px unset"); |
michael@0 | 5405 | gCSSProperties["border-top-left-radius"].invalid_values.push("unset 2px", "2px unset"); |
michael@0 | 5406 | gCSSProperties["border-top-right-radius"].invalid_values.push("unset 2px", "2px unset"); |
michael@0 | 5407 | gCSSProperties["-moz-border-right-colors"].invalid_values.push("red unset", "unset red"); |
michael@0 | 5408 | gCSSProperties["-moz-border-top-colors"].invalid_values.push("red unset", "unset red"); |
michael@0 | 5409 | gCSSProperties["-moz-outline-radius"].invalid_values.push("unset 2px", "unset / 2px", "2px unset", "2px / unset"); |
michael@0 | 5410 | gCSSProperties["-moz-outline-radius-bottomleft"].invalid_values.push("unset 2px", "2px unset"); |
michael@0 | 5411 | gCSSProperties["-moz-outline-radius-bottomright"].invalid_values.push("unset 2px", "2px unset"); |
michael@0 | 5412 | gCSSProperties["-moz-outline-radius-topleft"].invalid_values.push("unset 2px", "2px unset"); |
michael@0 | 5413 | gCSSProperties["-moz-outline-radius-topright"].invalid_values.push("unset 2px", "2px unset"); |
michael@0 | 5414 | gCSSProperties["background-image"].invalid_values.push("-moz-linear-gradient(unset, 10px 10px, from(blue))", "-moz-linear-gradient(unset, 10px 10px, blue 0)", "-moz-repeating-linear-gradient(unset, 10px 10px, blue 0)"); |
michael@0 | 5415 | gCSSProperties["box-shadow"].invalid_values.push("unset, 2px 2px", "2px 2px, unset", "inset unset"); |
michael@0 | 5416 | gCSSProperties["text-overflow"].invalid_values.push('"hello" unset', 'unset "hello"', 'clip unset', 'unset clip', 'unset inherit', 'unset none', 'initial unset'); |
michael@0 | 5417 | gCSSProperties["text-shadow"].invalid_values.push("unset, 2px 2px", "2px 2px, unset"); |
michael@0 | 5418 | gCSSProperties["transition"].invalid_values.push("2s unset"); |
michael@0 | 5419 | gCSSProperties["transition-property"].invalid_values.push("unset, color", "color, unset"); |
michael@0 | 5420 | gCSSProperties["-moz-transition"].invalid_values.push("2s unset"); |
michael@0 | 5421 | gCSSProperties["-moz-transition-property"].invalid_values.push("unset, color", "color, unset"); |
michael@0 | 5422 | gCSSProperties["-moz-animation"].invalid_values.push("2s unset"); |
michael@0 | 5423 | gCSSProperties["-moz-animation-direction"].invalid_values.push("unset, normal"); |
michael@0 | 5424 | gCSSProperties["-moz-animation-name"].invalid_values.push("bounce, unset", "unset, bounce"); |
michael@0 | 5425 | if (SpecialPowers.getBoolPref("layout.css.filters.enabled")) { |
michael@0 | 5426 | gCSSProperties["filter"].invalid_values.push("drop-shadow(unset, 2px 2px)", "drop-shadow(2px 2px, unset)"); |
michael@0 | 5427 | } |
michael@0 | 5428 | if (SpecialPowers.getBoolPref("layout.css.text-align-true-value.enabled")) { |
michael@0 | 5429 | gCSSProperties["text-align"].other_values.push("true left"); |
michael@0 | 5430 | } else { |
michael@0 | 5431 | gCSSProperties["text-align"].invalid_values.push("true left"); |
michael@0 | 5432 | } |
michael@0 | 5433 | } |