Merged
Conversation
Deploying flet-docs with
|
| Latest commit: |
c13b204
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://446a206a.flet-docs.pages.dev |
| Branch Preview URL: | https://v1-improve-tabs.flet-docs.pages.dev |
Contributor
Author
|
@sourcery-ai review |
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR enhances the Tabs component by splitting it into separate TabBar and TabBarView controls, introducing new configuration options and improved API design. It provides better flexibility for tab layouts with dedicated controls for tab headers and content areas.
Key changes include:
- Split Tabs into TabBar and TabBarView components with a unified Tabs wrapper
- Added new properties like
length,content,initial_index, and enhanced animation controls - Introduced TabAlignment enum and related tab indicator customization options
Reviewed Changes
Copilot reviewed 31 out of 32 changed files in this pull request and generated 8 comments.
Show a summary per file
| File | Description |
|---|---|
| sdk/python/packages/flet/src/flet/controls/types.py | Removed duplicate TabAlignment enum definition |
| sdk/python/packages/flet/src/flet/controls/theme.py | Renamed TabsTheme to TabBarTheme with updated properties |
| sdk/python/packages/flet/src/flet/controls/material/tabs.py | Major refactor splitting Tabs into TabBar, TabBarView, and Tabs components |
| sdk/python/packages/flet/src/flet/controls/material/elevated_button.py | Refactored style handling to use copy_with pattern |
| packages/flet/lib/src/controls/tabs.dart | Complete rewrite implementing separate TabBar and TabBarView controls |
| sdk/python/examples/controls/tabs/*.py | Updated examples to use new TabBar/TabBarView structure |
| Documentation files | Updated navigation and documentation structure for new components |
sdk/python/packages/flet/src/flet/controls/material/elevated_button.py
Outdated
Show resolved
Hide resolved
SourceryAI
reviewed
Aug 2, 2025
SourceryAI
left a comment
There was a problem hiding this comment.
We've reviewed this pull request using the Sourcery rules engine
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
# Conflicts: # sdk/python/packages/flet/docs/controls/tabs/index.md
…to v1-improve-tabs
FeodorFitsner
approved these changes
Aug 6, 2025
This was
linked to
issues
Aug 6, 2025
4 tasks
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.
Fixes #5494
Test code
Summary by Sourcery
Split and enhance the Tabs component by introducing dedicated TabBar and TabBarView controls, a TabAlignment enum, and refined API properties (length, content, initial_index, animation_duration), along with corresponding Dart implementations using DefaultTabController. Expand project tooling with new Taskfile commands, update pre-commit hooks, and reorganize documentation to surface TabBar and TabBarView under a unified tabs section.
New Features:
Enhancements:
CI:
Documentation:
Summary by Sourcery
Enhance the Tabs system by splitting it into TabBar and TabBarView with richer Python and Dart APIs, introduce supporting enums and indicator controls, refine button styling, bolster project tooling, update pre-commit hooks, and reorganize documentation
New Features:
Enhancements:
CI:
Documentation:
Chores: