fix loading
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import flet as ft
|
||||
from flet_core.types import OptionalControlEventCallable
|
||||
from flet.core.types import OptionalControlEventCallable
|
||||
import json
|
||||
import requests
|
||||
|
||||
@@ -46,21 +46,27 @@ class Loger(ft.SnackBar):
|
||||
)
|
||||
|
||||
class Field(ft.TextField):
|
||||
def __init__(self, label: str = "", password: bool = False):
|
||||
def __init__(self, label: str = "", password: bool = False,width:int=0):
|
||||
|
||||
super().__init__(
|
||||
max_lines=1,
|
||||
border_color=color[3],
|
||||
color=color[3],
|
||||
text_size=24,
|
||||
label=label,
|
||||
expand=True,
|
||||
password=password,
|
||||
can_reveal_password=password,
|
||||
label_style=ft.TextStyle(
|
||||
color=color[3],
|
||||
size=24
|
||||
),
|
||||
|
||||
)
|
||||
if width == 0:
|
||||
self.expand=True,
|
||||
else:
|
||||
self.expand=False
|
||||
self.width=width
|
||||
|
||||
class Button(ft.ElevatedButton):
|
||||
def __init__(self, text: str = "", on_click: OptionalControlEventCallable = None):
|
||||
|
||||
Reference in New Issue
Block a user