Skip to content

Commit

Permalink
Move width and height mapping to aspect ratio to HTML data (#6918)
Browse files Browse the repository at this point in the history
* Describe aspect ratio mapping without respect to aspect-ratio CSS property

* Mark aspect ratio mapping as non-experimental. Chrome, Firefox, and Safari implement this without flags. This looks
unlikely to change soon.

* Mirror computed aspect ratio data from Chrome to Opera

* Mirror computed aspect ratio data from Firefox desktop to Android

* Rename computed aspect ratio feature before moving to HTML tree

* Move computed aspect ratio data to HTML tree
  • Loading branch information
ddbeck authored Oct 29, 2020
1 parent 39ae20a commit 9dda22b
Show file tree
Hide file tree
Showing 6 changed files with 307 additions and 63 deletions.
61 changes: 0 additions & 61 deletions css/properties/aspect-ratio.json
Original file line number Diff line number Diff line change
Expand Up @@ -78,67 +78,6 @@
"standard_track": true,
"deprecated": false
}
},
"internal-value": {
"__compat": {
"description": "Internal mapping of width and height",
"support": {
"chrome": {
"version_added": "79"
},
"chrome_android": {
"version_added": "79"
},
"edge": {
"version_added": "79"
},
"firefox": [
{
"version_added": "71"
},
{
"version_added": "69",
"version_removed": "71",
"flags": [
{
"type": "preference",
"name": "layout.css.width-and-height-map-to-aspect-ratio.enabled",
"value_to_set": "true"
}
]
}
],
"firefox_android": {
"version_added": false
},
"ie": {
"version_added": false
},
"opera": {
"version_added": false
},
"opera_android": {
"version_added": false
},
"safari": {
"version_added": "14"
},
"safari_ios": {
"version_added": "14"
},
"samsunginternet_android": {
"version_added": "12.0"
},
"webview_android": {
"version_added": "79"
}
},
"status": {
"experimental": true,
"standard_track": true,
"deprecated": false
}
}
}
}
}
Expand Down
65 changes: 63 additions & 2 deletions html/elements/embed.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,13 @@
"version_added": true
},
"opera_android": {
"version_added": null
"version_added": true
},
"safari": {
"version_added": true
},
"safari_ios": {
"version_added": null
"version_added": true
},
"samsunginternet_android": {
"version_added": true
Expand All @@ -48,6 +48,67 @@
"deprecated": false
}
},
"aspect_ratio_computed_from_attributes": {
"__compat": {
"description": "Aspect ratio computed from <code>width</code> and <code>height</code> attributes",
"support": {
"chrome": {
"version_added": "79"
},
"chrome_android": {
"version_added": "79"
},
"edge": {
"version_added": "79"
},
"firefox": [
{
"version_added": "71"
},
{
"version_added": "69",
"version_removed": "71",
"flags": [
{
"type": "preference",
"name": "layout.css.width-and-height-map-to-aspect-ratio.enabled",
"value_to_set": "true"
}
]
}
],
"firefox_android": {
"version_added": "79"
},
"ie": {
"version_added": false
},
"opera": {
"version_added": "66"
},
"opera_android": {
"version_added": "57"
},
"safari": {
"version_added": "14"
},
"safari_ios": {
"version_added": "14"
},
"samsunginternet_android": {
"version_added": "12.0"
},
"webview_android": {
"version_added": "79"
}
},
"status": {
"experimental": false,
"standard_track": true,
"deprecated": false
}
}
},
"height": {
"__compat": {
"support": {
Expand Down
61 changes: 61 additions & 0 deletions html/elements/iframe.json
Original file line number Diff line number Diff line change
Expand Up @@ -314,6 +314,67 @@
}
}
},
"aspect_ratio_computed_from_attributes": {
"__compat": {
"description": "Aspect ratio computed from <code>width</code> and <code>height</code> attributes",
"support": {
"chrome": {
"version_added": "79"
},
"chrome_android": {
"version_added": "79"
},
"edge": {
"version_added": "79"
},
"firefox": [
{
"version_added": "71"
},
{
"version_added": "69",
"version_removed": "71",
"flags": [
{
"type": "preference",
"name": "layout.css.width-and-height-map-to-aspect-ratio.enabled",
"value_to_set": "true"
}
]
}
],
"firefox_android": {
"version_added": "79"
},
"ie": {
"version_added": false
},
"opera": {
"version_added": "66"
},
"opera_android": {
"version_added": "57"
},
"safari": {
"version_added": "14"
},
"safari_ios": {
"version_added": "14"
},
"samsunginternet_android": {
"version_added": "12.0"
},
"webview_android": {
"version_added": "79"
}
},
"status": {
"experimental": false,
"standard_track": true,
"deprecated": false
}
}
},
"external_protocol_urls_blocked": {
"__compat": {
"description": "External protocol URLs blocked",
Expand Down
61 changes: 61 additions & 0 deletions html/elements/img.json
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,67 @@
}
}
},
"aspect_ratio_computed_from_attributes": {
"__compat": {
"description": "Aspect ratio computed from <code>width</code> and <code>height</code> attributes",
"support": {
"chrome": {
"version_added": "79"
},
"chrome_android": {
"version_added": "79"
},
"edge": {
"version_added": "79"
},
"firefox": [
{
"version_added": "71"
},
{
"version_added": "69",
"version_removed": "71",
"flags": [
{
"type": "preference",
"name": "layout.css.width-and-height-map-to-aspect-ratio.enabled",
"value_to_set": "true"
}
]
}
],
"firefox_android": {
"version_added": "79"
},
"ie": {
"version_added": false
},
"opera": {
"version_added": "66"
},
"opera_android": {
"version_added": "57"
},
"safari": {
"version_added": "14"
},
"safari_ios": {
"version_added": "14"
},
"samsunginternet_android": {
"version_added": "12.0"
},
"webview_android": {
"version_added": "79"
}
},
"status": {
"experimental": false,
"standard_track": true,
"deprecated": false
}
}
},
"border": {
"__compat": {
"support": {
Expand Down
61 changes: 61 additions & 0 deletions html/elements/object.json
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,67 @@
}
}
},
"aspect_ratio_computed_from_attributes": {
"__compat": {
"description": "Aspect ratio computed from <code>width</code> and <code>height</code> attributes",
"support": {
"chrome": {
"version_added": "79"
},
"chrome_android": {
"version_added": "79"
},
"edge": {
"version_added": "79"
},
"firefox": [
{
"version_added": "71"
},
{
"version_added": "69",
"version_removed": "71",
"flags": [
{
"type": "preference",
"name": "layout.css.width-and-height-map-to-aspect-ratio.enabled",
"value_to_set": "true"
}
]
}
],
"firefox_android": {
"version_added": "79"
},
"ie": {
"version_added": false
},
"opera": {
"version_added": "66"
},
"opera_android": {
"version_added": "57"
},
"safari": {
"version_added": "14"
},
"safari_ios": {
"version_added": "14"
},
"samsunginternet_android": {
"version_added": "12.0"
},
"webview_android": {
"version_added": "79"
}
},
"status": {
"experimental": false,
"standard_track": true,
"deprecated": false
}
}
},
"border": {
"__compat": {
"support": {
Expand Down
Loading

0 comments on commit 9dda22b

Please sign in to comment.