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.
Hi Gaurav Yadav,
thank you very much for the implementing this useful VerticalTabs widget.
I've noticed an issue, when I wanted to apply transparency to Tabs block of it.
This PR contains my idea of fixing this case.
Since I'm new in flutter, I cannot be sure that this solution is completely right. Please review and decide.
Add materialType property that defines the value of Material.type used for piece of material definition, when the Material widget is configured inside of VerticalTabs widget. By default this value is set to MaterialType.canvas. Set it to MaterialType.transparency value, so it could be possible to apply opacity for widgets used for rendering bars block.
Add example in
example/lib/transparent.dartfor illustrating the issue I've fixed by this PR. This example displays picture in the background of the VerticalTabs widget.The top one implementation sets the MaterialType.canvas value for the materialType property, as it is expected as default value of the Material widget. As you can see, this way we cannot achieve correct transparency of the Tab block (content block is fine).
The bottom VerticalTabs implementation sets the MaterialType.transparency value for the materialType property, and it helps us to achieve expected transparency.