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

Dart-Code.dart-code & Dart-Code.flutter dependencies #8

Merged
merged 4 commits into from
Aug 23, 2024

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
2 checks passed
@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.

1 participant