Skip to content

Add support for mechanism event handlers #199

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

Open
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

lizlooney
Copy link
Collaborator

@lizlooney lizlooney commented Aug 15, 2025

Add support for mechanism event handlers

…om arrow functions to function declarations.

See https://google.github.io/styleguide/tsguide.html#function-declarations

In mrc_call_python_function.ts:
Removed unnecessary semicolon.
Changed "...method on a mechanism..." to "...method in a mechanism...".
Renamed RobotEventsCategory to RobotEventHandlersCategory.

In editor.ts, updated code that parses the module content text for the robot and mechanisms to use ? : instead of if/else.
…gory, and RobotEventHandlersCategory from hardware_category.ts to event_handlers_category.ts.
…anism events.

Use the block id of the mrc_event blocks to identify which event handlers are already on the workspace.
Changed custom values to begin with MRC_.
@lizlooney lizlooney requested a review from alan412 August 15, 2025 04:20
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.

1 participant