-
Notifications
You must be signed in to change notification settings - Fork 607
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Duplicate Check
- I have searched the opened issues and there are no duplicates
Describe the bug
v1: ElevatedButton's style property seems to be ignored iin some cases
Code sample
Code
import flet as ft
def main(page: ft.Page):
counter = ft.Text("0", size=50, data=0)
def increment_click(e):
counter.data += 1
counter.value = str(counter.data)
counter.update()
page.floating_action_button = ft.ElevatedButton(
content=ft.Text('Add'),
# bgcolor=ft.Colors.RED, # UNCOMMENT
style=ft.ButtonStyle(
shape=ft.RoundedRectangleBorder(
radius=4,
),
),
on_click=increment_click,
)
page.add(
ft.SafeArea(
expand=True,
content=ft.Container(
content=counter,
alignment=ft.Alignment.CENTER,
),
)
)
ft.run(main)To reproduce
Run sample code - button will have border radius != 4
BUT!
If you uncomment line
# bgcolor=ft.Colors.RED, # UNCOMMENTthen button border radius will be 4 as expected
Expected behavior
ElevatedButton border radius should be as specified in style property
Screenshots / Videos
No response
Operating System
Windows
Operating system details
Windows 11
Flet version
0.70.0.dev5367
Regression
Yes, it used to work in a previous Flet version (please specify the version in additional details)
Suggestions
No response
Logs
No response
Additional details
No response
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working