Skip to content

Conversation

@PlugFox
Copy link
Owner

@PlugFox PlugFox commented Aug 23, 2024

Add "Actions" panel to side bar

This commit adds support for activating the Flutter Plus extension and registering SDK commands. It ensures that the required Dart and Flutter extensions are installed and activated before proceeding. If any of the extensions are missing or fail to activate, an error message is displayed.

The SDK commands are registered using the `registerCommands` function, which is called during extension activation. The `registerCommands` function registers the `flutter-plus.sealed-states` command.

Additionally, the commit registers wrappers for the "Wrap with..." functionality using the `registerWrappers` function. The wrappers registered include `flutter-plus.wrap-sizedbox`, `flutter-plus.wrap-listenablebuilder`, `flutter-plus.wrap-valuelistenablebuilder`, and `flutter-plus.wrap-repaintboundary`.

This commit also introduces a new `SdkCommands` class in the `src/utils/sdk.ts` file. The `SdkCommands` class handles the registration and execution of SDK commands. It takes the `dartExtensionApi` as a parameter and uses it to run the desired function if it is supported. If the function is not available, an error message is displayed.

The changes in this commit aim to enhance the functionality and usability of the Flutter Plus extension by adding support for activation and SDK commands.
@PlugFox PlugFox merged commit 5441345 into master Aug 23, 2024
@PlugFox PlugFox deleted the feature/actions branch August 23, 2024 12:08
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.

2 participants