Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4)

Side by Side Diff: third_party/WebKit/Source/core/css/CSSProperties.json5

Issue 2786883002: Generate subgroup StyleSurroundData in ComputedStyle. (Closed)
Patch Set: Rebase Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 { 1 {
2 // This file specifies all the CSS properties we support and the necessary 2 // This file specifies all the CSS properties we support and the necessary
3 // information for our code generation. The various supported arguments 3 // information for our code generation. The various supported arguments
4 // are described below with example usage 4 // are described below with example usage
5 5
6 parameters: { 6 parameters: {
7 // - alias_for: "other-property" 7 // - alias_for: "other-property"
8 // Properties specifying alias_for should be virtually identical to the 8 // Properties specifying alias_for should be virtually identical to the
9 // properties they alias. Minor parsing differences are allowed as long as 9 // properties they alias. Minor parsing differences are allowed as long as
10 // the CSSValues created are of the same format of the aliased property. 10 // the CSSValues created are of the same format of the aliased property.
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 // in the .h file for this property, and also used in CSSPropertyAPIFiles.h. tmpl to 54 // in the .h file for this property, and also used in CSSPropertyAPIFiles.h. tmpl to
55 // generate declarations for only the methods this property has implementati ons for. 55 // generate declarations for only the methods this property has implementati ons for.
56 api_methods: { 56 api_methods: {
57 default: [], 57 default: [],
58 valid_type: "list", 58 valid_type: "list",
59 // This list must be an ordered, complete list of methods whose names mat ch those 59 // This list must be an ordered, complete list of methods whose names mat ch those
60 // defined in CSSPropertyDescriptor.h. 60 // defined in CSSPropertyDescriptor.h.
61 valid_values: ["parseSingleValue", "parseShorthand"], 61 valid_values: ["parseSingleValue", "parseShorthand"],
62 }, 62 },
63 63
64 // - field_group
65 // Name of the group that this field belongs to. Fields in the same group ar e stored
66 // together as a nested class inside ComputedStyle and dynamically allocated on use.
67 // Leave this out if the field is stored directly on ComputedStyle.
68 field_group: {
69 value_type: "str"
70 },
71
64 // - field_template 72 // - field_template
65 // Affects how the interface to this field is generated. 73 // Affects how the interface to this field is generated.
66 // TODO(sashab, meade): Remove this once TypedOM types are specified for 74 // TODO(sashab, meade): Remove this once TypedOM types are specified for
67 // every property, since this value can be inferred from that. 75 // every property, since this value can be inferred from that.
68 field_template: { 76 field_template: {
69 valid_values: [ 77 valid_values: [
70 // Field is stored as an enum and has a initial/getter/setter/resetter. 78 // Field is stored as an enum and has a initial/getter/setter/resetter.
71 "keyword", 79 "keyword",
72 // Field stores a primitive value like int/bool. The type is specified b y 80 // Field stores a primitive value like int/bool. The type is specified b y
73 // type_name. The interface has a initial/getter/setter/resetter. 81 // type_name. The interface has a initial/getter/setter/resetter.
(...skipping 715 matching lines...) Expand 10 before | Expand all | Expand 10 after
789 }, 797 },
790 { 798 {
791 name: "bottom", 799 name: "bottom",
792 api_class: "CSSPropertyAPIMargin", 800 api_class: "CSSPropertyAPIMargin",
793 api_methods: ["parseSingleValue"], 801 api_methods: ["parseSingleValue"],
794 converter: "ConvertLengthOrAuto", 802 converter: "ConvertLengthOrAuto",
795 interpolable: true, 803 interpolable: true,
796 keywords: ["auto"], 804 keywords: ["auto"],
797 supports_percentage: true, 805 supports_percentage: true,
798 typedom_types: ["Length"], 806 typedom_types: ["Length"],
807 field_template: "external",
808 field_type_path: "platform/Length",
809 field_group: "surround",
810 default_value: "Length()",
799 }, 811 },
800 { 812 {
801 name: "box-shadow", 813 name: "box-shadow",
802 converter: "ConvertShadowList", 814 converter: "ConvertShadowList",
803 interpolable: true, 815 interpolable: true,
804 }, 816 },
805 "box-sizing", 817 "box-sizing",
806 { 818 {
807 name: "break-after", 819 name: "break-after",
808 // Storage for this property also covers these legacy properties: 820 // Storage for this property also covers these legacy properties:
(...skipping 382 matching lines...) Expand 10 before | Expand all | Expand 10 after
1191 }, 1203 },
1192 { 1204 {
1193 name: "left", 1205 name: "left",
1194 api_class: "CSSPropertyAPIMargin", 1206 api_class: "CSSPropertyAPIMargin",
1195 api_methods: ["parseSingleValue"], 1207 api_methods: ["parseSingleValue"],
1196 converter: "ConvertLengthOrAuto", 1208 converter: "ConvertLengthOrAuto",
1197 interpolable: true, 1209 interpolable: true,
1198 keywords: ["auto"], 1210 keywords: ["auto"],
1199 supports_percentage: true, 1211 supports_percentage: true,
1200 typedom_types: ["Length"], 1212 typedom_types: ["Length"],
1213 field_template: "external",
1214 field_type_path: "platform/Length",
1215 field_group: "surround",
1216 default_value: "Length()",
1201 }, 1217 },
1202 { 1218 {
1203 name: "letter-spacing", 1219 name: "letter-spacing",
1204 api_class: "CSSPropertyAPILetterAndWordSpacing", 1220 api_class: "CSSPropertyAPILetterAndWordSpacing",
1205 api_methods: ["parseSingleValue"], 1221 api_methods: ["parseSingleValue"],
1206 converter: "ConvertSpacing", 1222 converter: "ConvertSpacing",
1207 inherited: true, 1223 inherited: true,
1208 initial: "InitialLetterWordSpacing", 1224 initial: "InitialLetterWordSpacing",
1209 interpolable: true, 1225 interpolable: true,
1210 }, 1226 },
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
1258 keywords: [ 1274 keywords: [
1259 "disc", "circle", "square", "decimal", "decimal-leading-zero", "arabic-i ndic", "bengali", "cambodian", "khmer", "devanagari", "gujarati", "gurmukhi", "k annada", "lao", "malayalam", "mongolian", "myanmar", "oriya", "persian", "urdu", "telugu", "tibetan", "thai", "lower-roman", "upper-roman", "lower-greek", "lowe r-alpha", "lower-latin", "upper-alpha", "upper-latin", "cjk-earthly-branch", "cj k-heavenly-stem", "ethiopic-halehame", "ethiopic-halehame-am", "ethiopic-haleham e-ti-er", "ethiopic-halehame-ti-et", "hangul", "hangul-consonant", "korean-hangu l-formal", "korean-hanja-formal", "korean-hanja-informal", "hebrew", "armenian", "lower-armenian", "upper-armenian", "georgian", "cjk-ideographic", "simp-chines e-formal", "simp-chinese-informal", "trad-chinese-formal", "trad-chinese-informa l", "hiragana", "katakana", "hiragana-iroha", "katakana-iroha", "none", 1275 "disc", "circle", "square", "decimal", "decimal-leading-zero", "arabic-i ndic", "bengali", "cambodian", "khmer", "devanagari", "gujarati", "gurmukhi", "k annada", "lao", "malayalam", "mongolian", "myanmar", "oriya", "persian", "urdu", "telugu", "tibetan", "thai", "lower-roman", "upper-roman", "lower-greek", "lowe r-alpha", "lower-latin", "upper-alpha", "upper-latin", "cjk-earthly-branch", "cj k-heavenly-stem", "ethiopic-halehame", "ethiopic-halehame-am", "ethiopic-haleham e-ti-er", "ethiopic-halehame-ti-et", "hangul", "hangul-consonant", "korean-hangu l-formal", "korean-hanja-formal", "korean-hanja-informal", "hebrew", "armenian", "lower-armenian", "upper-armenian", "georgian", "cjk-ideographic", "simp-chines e-formal", "simp-chinese-informal", "trad-chinese-formal", "trad-chinese-informa l", "hiragana", "katakana", "hiragana-iroha", "katakana-iroha", "none",
1260 ], 1276 ],
1261 }, 1277 },
1262 { 1278 {
1263 name: "margin-bottom", 1279 name: "margin-bottom",
1264 api_class: "CSSPropertyAPIMargin", 1280 api_class: "CSSPropertyAPIMargin",
1265 api_methods: ["parseSingleValue"], 1281 api_methods: ["parseSingleValue"],
1266 converter: "ConvertQuirkyLength", 1282 converter: "ConvertQuirkyLength",
1267 interpolable: true, 1283 interpolable: true,
1284 field_template: "external",
1285 field_type_path: "platform/Length",
1286 field_group: "surround",
1287 default_value: "Length(kFixed)",
1268 }, 1288 },
1269 { 1289 {
1270 name: "margin-left", 1290 name: "margin-left",
1271 api_class: "CSSPropertyAPIMargin", 1291 api_class: "CSSPropertyAPIMargin",
1272 api_methods: ["parseSingleValue"], 1292 api_methods: ["parseSingleValue"],
1273 converter: "ConvertQuirkyLength", 1293 converter: "ConvertQuirkyLength",
1274 interpolable: true, 1294 interpolable: true,
1295 field_template: "external",
1296 field_type_path: "platform/Length",
1297 field_group: "surround",
1298 default_value: "Length(kFixed)",
1275 }, 1299 },
1276 { 1300 {
1277 name: "margin-right", 1301 name: "margin-right",
1278 api_class: "CSSPropertyAPIMargin", 1302 api_class: "CSSPropertyAPIMargin",
1279 api_methods: ["parseSingleValue"], 1303 api_methods: ["parseSingleValue"],
1280 converter: "ConvertQuirkyLength", 1304 converter: "ConvertQuirkyLength",
1281 interpolable: true, 1305 interpolable: true,
1306 field_template: "external",
1307 field_type_path: "platform/Length",
1308 field_group: "surround",
1309 default_value: "Length(kFixed)",
1282 }, 1310 },
1283 { 1311 {
1284 name: "margin-top", 1312 name: "margin-top",
1285 api_class: "CSSPropertyAPIMargin", 1313 api_class: "CSSPropertyAPIMargin",
1286 api_methods: ["parseSingleValue"], 1314 api_methods: ["parseSingleValue"],
1287 converter: "ConvertQuirkyLength", 1315 converter: "ConvertQuirkyLength",
1288 interpolable: true, 1316 interpolable: true,
1317 field_template: "external",
1318 field_type_path: "platform/Length",
1319 field_group: "surround",
1320 default_value: "Length(kFixed)",
1289 }, 1321 },
1290 { 1322 {
1291 name: "marker-end", 1323 name: "marker-end",
1292 api_class: "CSSPropertyAPIMarker", 1324 api_class: "CSSPropertyAPIMarker",
1293 converter: "ConvertFragmentIdentifier", 1325 converter: "ConvertFragmentIdentifier",
1294 inherited: true, 1326 inherited: true,
1295 name_for_methods: "MarkerEndResource", 1327 name_for_methods: "MarkerEndResource",
1296 svg: true, 1328 svg: true,
1297 }, 1329 },
1298 { 1330 {
(...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after
1501 "visible", "hidden", "scroll", "auto", "overlay", "-webkit-paged-x", "-w ebkit-paged-y", 1533 "visible", "hidden", "scroll", "auto", "overlay", "-webkit-paged-x", "-w ebkit-paged-y",
1502 ], 1534 ],
1503 type_name: "EOverflow", 1535 type_name: "EOverflow",
1504 }, 1536 },
1505 { 1537 {
1506 name: "padding-bottom", 1538 name: "padding-bottom",
1507 api_class: "CSSPropertyAPIPadding", 1539 api_class: "CSSPropertyAPIPadding",
1508 api_methods: ["parseSingleValue"], 1540 api_methods: ["parseSingleValue"],
1509 converter: "ConvertLength", 1541 converter: "ConvertLength",
1510 interpolable: true, 1542 interpolable: true,
1543 field_template: "external",
1544 field_type_path: "platform/Length",
1545 field_group: "surround",
1546 default_value: "Length(kFixed)",
1511 }, 1547 },
1512 { 1548 {
1513 name: "padding-left", 1549 name: "padding-left",
1514 api_class: "CSSPropertyAPIPadding", 1550 api_class: "CSSPropertyAPIPadding",
1515 api_methods: ["parseSingleValue"], 1551 api_methods: ["parseSingleValue"],
1516 converter: "ConvertLength", 1552 converter: "ConvertLength",
1517 interpolable: true, 1553 interpolable: true,
1554 field_template: "external",
1555 field_type_path: "platform/Length",
1556 field_group: "surround",
1557 default_value: "Length(kFixed)",
1518 }, 1558 },
1519 { 1559 {
1520 name: "padding-right", 1560 name: "padding-right",
1521 api_class: "CSSPropertyAPIPadding", 1561 api_class: "CSSPropertyAPIPadding",
1522 api_methods: ["parseSingleValue"], 1562 api_methods: ["parseSingleValue"],
1523 converter: "ConvertLength", 1563 converter: "ConvertLength",
1524 interpolable: true, 1564 interpolable: true,
1565 field_template: "external",
1566 field_type_path: "platform/Length",
1567 field_group: "surround",
1568 default_value: "Length(kFixed)",
1525 }, 1569 },
1526 { 1570 {
1527 name: "padding-top", 1571 name: "padding-top",
1528 api_class: "CSSPropertyAPIPadding", 1572 api_class: "CSSPropertyAPIPadding",
1529 api_methods: ["parseSingleValue"], 1573 api_methods: ["parseSingleValue"],
1530 converter: "ConvertLength", 1574 converter: "ConvertLength",
1531 interpolable: true, 1575 interpolable: true,
1576 field_template: "external",
1577 field_type_path: "platform/Length",
1578 field_group: "surround",
1579 default_value: "Length(kFixed)",
1532 }, 1580 },
1533 { 1581 {
1534 name: "paint-order", 1582 name: "paint-order",
1535 api_class: true, 1583 api_class: true,
1536 api_methods: ["parseSingleValue"], 1584 api_methods: ["parseSingleValue"],
1537 converter: "ConvertPaintOrder", 1585 converter: "ConvertPaintOrder",
1538 inherited: true, 1586 inherited: true,
1539 svg: true, 1587 svg: true,
1540 }, 1588 },
1541 { 1589 {
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
1582 }, 1630 },
1583 { 1631 {
1584 name: "right", 1632 name: "right",
1585 api_class: "CSSPropertyAPIMargin", 1633 api_class: "CSSPropertyAPIMargin",
1586 api_methods: ["parseSingleValue"], 1634 api_methods: ["parseSingleValue"],
1587 converter: "ConvertLengthOrAuto", 1635 converter: "ConvertLengthOrAuto",
1588 interpolable: true, 1636 interpolable: true,
1589 keywords: ["auto"], 1637 keywords: ["auto"],
1590 supports_percentage: true, 1638 supports_percentage: true,
1591 typedom_types: ["Length"], 1639 typedom_types: ["Length"],
1640 field_template: "external",
1641 field_type_path: "platform/Length",
1642 field_group: "surround",
1643 default_value: "Length()",
1592 }, 1644 },
1593 { 1645 {
1594 name: "r", 1646 name: "r",
1595 api_class: "CSSPropertyAPIStrokeOrLength", 1647 api_class: "CSSPropertyAPIStrokeOrLength",
1596 converter: "ConvertLength", 1648 converter: "ConvertLength",
1597 interpolable: true, 1649 interpolable: true,
1598 svg: true, 1650 svg: true,
1599 }, 1651 },
1600 { 1652 {
1601 name: "rx", 1653 name: "rx",
(...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after
1900 }, 1952 },
1901 { 1953 {
1902 name: "top", 1954 name: "top",
1903 api_class: "CSSPropertyAPIMargin", 1955 api_class: "CSSPropertyAPIMargin",
1904 api_methods: ["parseSingleValue"], 1956 api_methods: ["parseSingleValue"],
1905 converter: "ConvertLengthOrAuto", 1957 converter: "ConvertLengthOrAuto",
1906 interpolable: true, 1958 interpolable: true,
1907 keywords: ["auto"], 1959 keywords: ["auto"],
1908 supports_percentage: true, 1960 supports_percentage: true,
1909 typedom_types: ["Length"], 1961 typedom_types: ["Length"],
1962 field_template: "external",
1963 field_type_path: "platform/Length",
1964 field_group: "surround",
1965 default_value: "Length()",
1910 }, 1966 },
1911 { 1967 {
1912 name: "touch-action", 1968 name: "touch-action",
1913 api_class: true, 1969 api_class: true,
1914 api_methods: ["parseSingleValue"], 1970 api_methods: ["parseSingleValue"],
1915 converter: "ConvertFlags<TouchAction>", 1971 converter: "ConvertFlags<TouchAction>",
1916 type_name: "TouchAction", 1972 type_name: "TouchAction",
1917 }, 1973 },
1918 { 1974 {
1919 name: "transform", 1975 name: "transform",
(...skipping 1261 matching lines...) Expand 10 before | Expand all | Expand 10 after
3181 { 3237 {
3182 name: "-webkit-transition-timing-function", 3238 name: "-webkit-transition-timing-function",
3183 alias_for: "transition-timing-function", 3239 alias_for: "transition-timing-function",
3184 }, 3240 },
3185 { 3241 {
3186 name: "-webkit-user-select", 3242 name: "-webkit-user-select",
3187 alias_for: "user-select", 3243 alias_for: "user-select",
3188 }, 3244 },
3189 ], 3245 ],
3190 } 3246 }
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/BUILD.gn ('k') | third_party/WebKit/Source/core/css/ComputedStyleExtraFields.json5 » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698