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

chore: Use JSON objects for context menu callbackFactory #7382

Merged
merged 3 commits into from
Sep 8, 2023

Conversation

johnnesky
Copy link
Member

The basics

  • I branched from develop
  • My pull request is against develop
  • My code follows the style guide
  • I ran npm run format and npm run lint

The details

Resolves

Fixes #5579

Proposed Changes

Adds support for using JSON objects to define blocks to be instantiated by callbackFactory(...) for context menus, while preserving support for using XML. Ports existing usage of callbackFactory(...) in core from XML to JSON objects.

Behavior Before Change

Only XML is supported for the second argument of callbackFactory(...).

Behavior After Change

Both XML and JSON objects are supported for the second argument.

Reason for Changes

XML support is deprecated.

Test Coverage

Documentation

The automatic documentation will need to be updated at: https://developers.google.com/blockly/reference/js/blockly.contextmenu_namespace

@github-actions github-actions bot added the PR: chore General chores (dependencies, typos, etc) label Aug 12, 2023
@johnnesky johnnesky marked this pull request as ready for review August 18, 2023 20:47
@johnnesky johnnesky requested a review from a team as a code owner August 18, 2023 20:47
@johnnesky johnnesky merged commit 1b2e912 into google:develop Sep 8, 2023
9 checks passed
@johnnesky johnnesky deleted the context_menu branch September 8, 2023 23:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR: chore General chores (dependencies, typos, etc)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Move context menu items to use JSON
2 participants