Implement Tabs node minimum size #47491
Merged
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.
Fixes a long overdue 😛 TODO in the Tabs node.
This allow with the new "clip_tabs" property to set up a minimum size to the Tabs node. It's enabled by default to keep compatibility.
Also, I changed the logic a little bit used to choose when a tab should be shown or not. Previously, it always removed the size of the increment and decrement buttons from the available space, even if the last tab would fit in the parent's size. So now, it instead waits for the last bit of space available to show the buttons. (Not sure if there was an issue about that, but didn't find one)
To illustrate the changes:
Peek.30-03-2021.12-28.mp4
Bugsquad edit: This closes #31238.