-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.py
More file actions
49 lines (40 loc) · 1.52 KB
/
main.py
File metadata and controls
49 lines (40 loc) · 1.52 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
from flet import *
from flet_route import *
from views.login import Login
from views.registro import Registro
from apps.home import Home
from apps.nuevaCita import NuevaCita
from apps.historico import HistoricoCita
def main(page: Page):
page.padding = 0
page.spacing = 0
page.window_width = 390
page.window_height = 844
page.window_max_width = 800
page.window_max_height = 844
page.window_left = 1500
page.fonts = {
"Poppins": "https://fonts.google.com/share?selection.family=Onest:wght@100..900"
}
page.theme = Theme(font_family="Poppins")
page.theme_mode = ThemeMode.DARK
theme = Theme()
theme.page_transitions.android = PageTransitionTheme.ZOOM
theme.page_transitions.ios = PageTransitionTheme.ZOOM
theme.page_transitions.macos = PageTransitionTheme.ZOOM
theme.page_transitions.linux = PageTransitionTheme.ZOOM
theme.page_transitions.windows = PageTransitionTheme.ZOOM
page.theme = theme
page.update()
app_routes = [
path('/', clear=True, view=Login),
path('/registro', clear=True, view=Registro),
path('/home', clear=True, view=Home, ),
path('/nueva_cita', clear=True, view=NuevaCita),
path('/historico', clear=True, view=HistoricoCita),
]
Routing(page=page, app_routes=app_routes)
page.go(page.route)
if __name__ == '__main__':
# app(target=main, view=WEB_BROWSER, assets_dir="assets") # en web
app(target=main, assets_dir="assets") # en pantalla