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

Chrome 22 added webextensions.manifest.commands support #24293

Conversation

queengooborg
Copy link
Contributor

This PR updates and corrects version values for Chromium (Chrome, Opera, Samsung Internet, WebView Android) for the commands Web Extensions manifest property. The data comes from a commit in the browser's source code, mapped to a version number using available tooling or via the commit timestamp.

Commit: https://chromiumdash.appspot.com/commit/8e1b9cf4b212c6596d979b333c1627d6acb714e2

This PR updates and corrects version values for Chromium (Chrome, Opera, Samsung Internet, WebView Android) for the `commands` Web Extensions manifest property. The data comes from a commit in the browser's source code, mapped to a version number using available tooling or via the commit timestamp.

Commit: https://chromiumdash.appspot.com/commit/8e1b9cf4b212c6596d979b333c1627d6acb714e2
@queengooborg queengooborg added data:webext Compat data for Browser Extensions. https://developer.mozilla.org/Add-ons/WebExtensions KR: Real BCD Key Result: Eliminate true/null values and replace them with "real" values. labels Sep 3, 2024
Copy link
Contributor

@rebloor rebloor left a comment

Choose a reason for hiding this comment

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

@queengooborg _execute_action should remain at 88 - the MV3 features landed sooner but the release was 88. Also, _execute_browser_action and _execute_page_action will have been earlier - most likely with the action and page action APIs (but I have no more information).

@queengooborg
Copy link
Contributor Author

What should we do for _execute_browser_action and _execute_page_action then? We could set them as ranges, though I'm working to eliminate to ranges (and focusing on webextensions to start)!

@rebloor
Copy link
Contributor

rebloor commented Sep 5, 2024

@dotproto Any thoughts on how we find when _execute_browser_action and _execute_page_action were implemented in Chrome?

@github-actions github-actions bot added the size:xs [PR only] 0-6 LoC changed label Nov 22, 2024
@queengooborg queengooborg requested a review from caugner November 27, 2024 12:18
@danielhjacobs
Copy link
Contributor

danielhjacobs commented Nov 27, 2024

At least as early as September 18, 2012, https://chromium.googlesource.com/chromium/src/+/09d2e1d94dab63e571d527fb716c0fc86dd51206/chrome/common/extensions/docs/templates/intros/commands.html referenced _execute_browser_action and _execute_page_action (when I hover over "12 years ago" on https://chromium.googlesource.com/chromium/src/+log/09d2e1d94dab63e571d527fb716c0fc86dd51206/chrome/common/extensions/docs/templates/intros/commands.html, it says that date).

In https://chromium.googlesource.com/chromium/src/+log/854e828ba4af79eec2d97678264b97fa38a41ecd/chrome/common/extensions/docs/server2/templates/intros/commands.html, on August 30, 2012, this file inside the folder server2 already listed _execute_browser_action and _execute_page_action.

Even before then in https://chromium.googlesource.com/chromium/src/+/4a7ce7a4c35f99571d6989b00c492149dbc2ff31/chrome/common/extensions/docs/server2/templates/intros/experimental_commands.html from July 31, 2012, the file there already listed this, though at the time it was named experimental_commands.

Even before then in https://chromium.googlesource.com/chromium/src/+/3c0d22621d6f2fbcfc4d1c02172ff73fe5c6f89e/chrome/common/extensions/docs/server2/templates/intros/experimental_keybinding.html from July 10, 2012, the file there already listed this, though at the time it was named experimental_keybinding.

Even before then in https://chromium.googlesource.com/chromium/src/+/d4468be582737a9c9d8f9112735604c2610f9afd/chrome/common/extensions/docs/server2/templates/private/experimental_keybinding_intro.html from July 6, 2012, the file there already listed this, though at the time it was named experimental_keybinding_intro.html.

I guess my assumption would be that the moment the commands API became supported it already supported these options.

Everything I'm looking at is suggesting that perhaps the commands API was supported since some time in 2012.

https://chromium.googlesource.com/chromium/src/+/c2b5ed357576bdb64e842794a59fd8c89a95f1bd, September 10, 2012, enabled the commands API for platform apps, and it was already enabled for extensions before then.

https://issues.chromium.org/issues/40197373. A bug referencing _execute_browser_action at least as early as April 2012.

@danielhjacobs
Copy link
Contributor

danielhjacobs commented Nov 27, 2024

I finally found the relevant info in the docs:

https://web.archive.org/web/20130824074541/https://developer.chrome.com/extensions/commands.html

"Stable since Chrome 25"

Already listed _execute_browser_action and _execute_page_action at the time.

webextensions/manifest/commands.json Outdated Show resolved Hide resolved
webextensions/manifest/commands.json Outdated Show resolved Hide resolved
Co-authored-by: Daniel Jacobs <danielhunterjacobs@gmail.com>
@github-actions github-actions bot added size:s [PR only] 7-24 LoC changed and removed size:xs [PR only] 0-6 LoC changed labels Nov 27, 2024
@caugner caugner changed the title Update Chromium data for commands Web Extensions manifest property Chrome 22 added webextensions.manifest.commands support Nov 27, 2024
@caugner
Copy link
Contributor

caugner commented Nov 27, 2024

@danielhjacobs Nice research, thanks! Fixed in 0fa5fbb.

@caugner
Copy link
Contributor

caugner commented Nov 27, 2024

@rebloor @queengooborg Any concerns with the evidence found by @danielhjacobs?

Copy link
Contributor

@rebloor rebloor left a comment

Choose a reason for hiding this comment

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

No concerns on my part

@queengooborg queengooborg merged commit cd024fa into mdn:main Nov 27, 2024
7 checks passed
@queengooborg queengooborg deleted the webextensions/manifest/commands/chrome-corrections branch November 27, 2024 22:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
data:webext Compat data for Browser Extensions. https://developer.mozilla.org/Add-ons/WebExtensions KR: Real BCD Key Result: Eliminate true/null values and replace them with "real" values. size:s [PR only] 7-24 LoC changed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants