DSL Actions: StacSnackBarAction, StacMultiAction, StacModalBottomSheetAction, StacDelayAction, StacDialogAction#340
Merged
divyanshub024 merged 3 commits intodv/stac-exportfrom Aug 22, 2025
Merged
Conversation
-StacSnackBarAction -StacMultiAction -StacModalBottomSheetAction -StacDelayAction -StacDialogAction
divyanshub024
requested changes
Aug 22, 2025
| import 'package:stac_framework/stac_framework.dart'; | ||
|
|
||
| import 'stac_snack_bar.dart'; | ||
| // Types are parsed via extensions in type_parser.dart |
Comment on lines
1410
to
1420
| extension StacSnackBarActionParser on StacSnackBarAction { | ||
| SnackBarAction parse(BuildContext context) { | ||
| return SnackBarAction( | ||
| textColor: textColor?.toColor(context), | ||
| disabledTextColor: disabledTextColor?.toColor(context), | ||
| backgroundColor: backgroundColor?.toColor(context), | ||
| disabledBackgroundColor: disabledBackgroundColor?.toColor(context), | ||
| label: label, | ||
| onPressed: () => onPressed.parse(context), | ||
| ); | ||
| } |
Member
There was a problem hiding this comment.
Should this be in type or in action_parser?
Contributor
Author
There was a problem hiding this comment.
should be in its own parser ig
|
|
||
| part 'stac_snack_bar_action.g.dart'; | ||
|
|
||
| @JsonSerializable() |
Member
There was a problem hiding this comment.
Can we add documentation as well?
|
|
||
| part 'stac_snack_bar.g.dart'; | ||
|
|
||
| @JsonSerializable() |
Member
There was a problem hiding this comment.
Can we add documentation as well?
|
|
||
| part 'stac_multi_action.g.dart'; | ||
|
|
||
| @JsonSerializable() |
Member
There was a problem hiding this comment.
Can we add documentation as well?
Comment on lines
22
to
27
| this.isScrollControlled = false, | ||
| this.useRootNavigator = false, | ||
| this.isDismissible = true, | ||
| this.enableDrag = true, | ||
| this.showDragHandle, | ||
| this.useSafeArea = false, |
Member
There was a problem hiding this comment.
We should define the default values in parsers
Comment on lines
14
to
17
| this.barrierDismissible = true, | ||
| this.barrierColor, | ||
| this.barrierLabel, | ||
| this.useSafeArea = true, |
Member
There was a problem hiding this comment.
Please define default values in parser
|
|
||
| @JsonSerializable() | ||
| class StacDelayAction extends StacAction { | ||
| const StacDelayAction({this.milliseconds = 1000}); |
Member
There was a problem hiding this comment.
Please define default values in parser
divyanshub024
approved these changes
Aug 22, 2025
lstonussi
pushed a commit
to SuaMusica/stac
that referenced
this pull request
Feb 25, 2026
DSL Actions: StacSnackBarAction, StacMultiAction, StacModalBottomSheetAction, StacDelayAction, StacDialogAction
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
added StacSnackBarAction, StacMultiAction, StacModalBottomSheetAction, StacDelayAction, StacDialogAction
Type of Change