Skip to content

feat: customizable Scrollbars#6282

Draft
ndonkoHenri wants to merge 9 commits intomainfrom
scroll
Draft

feat: customizable Scrollbars#6282
ndonkoHenri wants to merge 9 commits intomainfrom
scroll

Conversation

@ndonkoHenri
Copy link
Contributor

@ndonkoHenri ndonkoHenri commented Mar 8, 2026

Fix #5912

Test Code

# Test code for the review of this PR

Summary by Sourcery

Introduce a configurable Scrollbar API for scrollable controls and migrate existing scroll behavior to use it.

New Features:

  • Add a Scrollbar dataclass and ScrollbarOrientation enum to configure scrollbar appearance and placement in scrollable controls and pages.
  • Allow ScrollableControl and Page.scroll to accept either legacy ScrollMode presets or detailed Scrollbar configurations.
  • Provide interactive Python examples demonstrating Scrollbar customization and ScrollbarOrientation behavior.

Enhancements:

  • Refactor Flutter-side scrollbar handling into a ScrollbarConfiguration utility, translating legacy ScrollMode values and custom configuration maps into Flutter Scrollbar properties.
  • Update scrollable control rendering to always use the unified ScrollbarConfiguration, simplifying auto-scroll logic and removing the old ScrollMode.none path.
  • Expose the new scrollbar utilities in the Dart public API and Python package exports, and extend documentation to cover the new types.

@cloudflare-workers-and-pages
Copy link

Deploying flet-examples with  Cloudflare Pages  Cloudflare Pages

Latest commit: 0c409c8
Status: ✅  Deploy successful!
Preview URL: https://e295041c.flet-examples.pages.dev
Branch Preview URL: https://scroll.flet-examples.pages.dev

View logs

@cloudflare-workers-and-pages
Copy link

Deploying flet-docs with  Cloudflare Pages  Cloudflare Pages

Latest commit: 0c409c8
Status: ✅  Deploy successful!
Preview URL: https://2b3e5963.flet-docs.pages.dev
Branch Preview URL: https://scroll.flet-docs.pages.dev

View logs

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.

Custom scrollbars

1 participant