Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix feature structure of HTMLCanvasElement API (and correct version numbers) #11234

Merged
merged 19 commits into from
Aug 12, 2021

Conversation

queengooborg
Copy link
Collaborator

@queengooborg queengooborg commented Jun 25, 2021

This PR fixes up the names of the features within the HTMLCanvasElement API. Many of the feature names did not conform to the documented guidelines, so this is an attempt to get them to conform properly. This also adds the 2d context to our data, which was originally missing.

As a part of the research of adding in the context and organizing the options, I've found some errors within our data. This PR fixes the data as well. (I would've separated it into another PR, but I thought it would be better to tackle it in one go.)

@github-actions github-actions bot added the data:api 🐇 Compat data for Web APIs. https://developer.mozilla.org/docs/Web/API label Jun 25, 2021
api/HTMLCanvasElement.json Outdated Show resolved Hide resolved
api/HTMLCanvasElement.json Outdated Show resolved Hide resolved
@queengooborg queengooborg changed the title Fix feature names for members of HTMLCanvasElement API Fix feature structure of HTMLCanvasElement API (and correct version numbers) Jul 16, 2021
Copy link
Collaborator

@foolip foolip left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The structure looks great now! I have a lot of questions about the versions. This might turn into a giant rabbit hole, so if some of it can be turned into true or ranges to avoid digging too deep, I'd be OK with that. We'll come back to it :)

Or, we can excavate this rabbit hole and build a tidy little museum down there.

api/HTMLCanvasElement.json Outdated Show resolved Hide resolved
api/HTMLCanvasElement.json Outdated Show resolved Hide resolved
api/HTMLCanvasElement.json Outdated Show resolved Hide resolved
api/HTMLCanvasElement.json Outdated Show resolved Hide resolved
api/HTMLCanvasElement.json Outdated Show resolved Hide resolved
api/HTMLCanvasElement.json Outdated Show resolved Hide resolved
"version_added": "41"
},
"ie": {
"version_added": true
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was this really supported in IE?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm unsure, this came from the original data. I'm actually not sure how to test this particular option.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, let's leave it for now, it's true so we'll get back to it.

api/HTMLCanvasElement.json Outdated Show resolved Hide resolved
api/HTMLCanvasElement.json Show resolved Hide resolved
api/HTMLCanvasElement.json Outdated Show resolved Hide resolved
@foolip
Copy link
Collaborator

foolip commented Jul 20, 2021

@vinyldarkscratch I notice in another review that OffscreenCanvas also has a similar structure. Can you reorganize that too so that the style is kept consistent between the two?

@foolip
Copy link
Collaborator

foolip commented Aug 10, 2021

@vinyldarkscratch there are still unresolved comments here, over to you :)

@@ -32,7 +32,7 @@
"notes": "Opera Mini 5.0 and later has partial support."
},
"safari": {
"version_added": "3"
"version_added": "2"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is consistent with CanvasRenderingContext2D 👍

"chrome": [
{
"version_added": "81",
"notes": "ChromeOS and Windows"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like https://bugs.chromium.org/p/chromium/issues/detail?id=945835 is the bug about enabling this.

@foolip foolip merged commit e013078 into mdn:main Aug 12, 2021
@queengooborg queengooborg deleted the api/HTMLCanvasElement/property-names branch August 12, 2021 19:57
@ddbeck
Copy link
Collaborator

ddbeck commented Aug 17, 2021

A summary of the feature name changes that happened in this PR:

Removed

  • api.HTMLCanvasElement.getContext.desynchronized
  • api.HTMLCanvasElement.getContext.failIfMajorPerformanceCaveat
  • api.HTMLCanvasElement.getContext.powerPreference
  • api.HTMLCanvasElement.getContext.2d_alpha_context
  • api.HTMLCanvasElement.toBlob.Image_quality

Added

  • api.HTMLCanvasElement.getContext.bitmaprenderer_context.options_alpha_parameter
  • api.HTMLCanvasElement.getContext.webgl_context.options_alpha_parameter
  • api.HTMLCanvasElement.getContext.webgl_context.options_desynchronized_parameter
  • api.HTMLCanvasElement.getContext.webgl_context.options_failIfMajorPerformanceCaveat_parameter
  • api.HTMLCanvasElement.getContext.webgl_context.options_powerPreference_parameter
  • api.HTMLCanvasElement.getContext.webgl2_context.options_alpha_parameter
  • api.HTMLCanvasElement.getContext.webgl2_context.options_desynchronized_parameter
  • api.HTMLCanvasElement.getContext.webgl2_context.options_failIfMajorPerformanceCaveat_parameter
  • api.HTMLCanvasElement.getContext.webgl2_context.options_powerPreference_parameter
  • api.HTMLCanvasElement.getContext.2d_context
  • api.HTMLCanvasElement.getContext.2d_context.options_alpha_parameter
  • api.HTMLCanvasElement.getContext.2d_context.options_desynchronized_parameter
  • api.HTMLCanvasElement.toBlob.quality_parameter

ddbeck added a commit to ddbeck/browser-compat-data that referenced this pull request Aug 17, 2021
ddbeck added a commit to ddbeck/browser-compat-data that referenced this pull request Aug 17, 2021
ddbeck added a commit that referenced this pull request Aug 19, 2021
* Bump version to v4.0.0

* Add release note for #11234

* Bump known issues

* Add release note for #11760

* Add release note for #11286

* Add release note for #9830

* Add release note for #10334

* Add v4.0.0 highlights to release notes

* Add release note for #10753

* Revise description of `accepts_flags` hint

* Add release note for #11961

* Add release note for #12059

* Add stats
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
data:api 🐇 Compat data for Web APIs. https://developer.mozilla.org/docs/Web/API
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants