Skip to content

Replace contextMenus with menus#631

Open
caugner wants to merge 1 commit into
mainfrom
replace-contextmenus-with-menus
Open

Replace contextMenus with menus#631
caugner wants to merge 1 commit into
mainfrom
replace-contextmenus-with-menus

Conversation

@caugner
Copy link
Copy Markdown
Contributor

@caugner caugner commented May 12, 2026

Description

Replace contextMenus with menus.

Motivation

Resolves webextallexamples flaws reported by @mdn/rari.

Additional details

See: https://caugner.github.io/mdn-flawless/#locale=en-US&templ=webextallexamples

Related issues and pull requests

Part of mdn/fred#1462.

See also:

Resolves `webextallexamples` flaws reported by `@mdn/rari`.
@caugner caugner requested a review from a team as a code owner May 12, 2026 11:31
@caugner caugner requested a review from LeoMcA May 12, 2026 11:31
Copy link
Copy Markdown
Member

@Rob--W Rob--W left a comment

Choose a reason for hiding this comment

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

These examples use contextMenus, not the menus APIs.

Restating what I wrote at mdn/content#44090 (review) :

Although mdn only features "menus" without "contextMenus", we should really be documenting both instead of deleting references to contextMenus.

Sadly the same API is available under 2 namespaces, but different permissions.

contextMenus namespace + contextMenus permission

menus namespace + menus permission.

menus is available in Firefox and Safari, not Chrome.

contextMenus is available in all.

@rebloor
Copy link
Copy Markdown
Collaborator

rebloor commented May 12, 2026

@rebloor (note to self) when this is resolved, if we are retaining contextMenus, confirm that these examples show on menus.create and menus.onClicked (which they don't at the moment) and, if necessary, add links.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants