-
Notifications
You must be signed in to change notification settings - Fork 10
/
navbar.py
86 lines (83 loc) · 3.35 KB
/
navbar.py
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
import dash_bootstrap_components as dbc
import dash_html_components as html
def Navbar():
links = dbc.Row(
[
dbc.DropdownMenu(
className = "nav-links-dd",
color="link",
label="Dataset",
children=[
dbc.DropdownMenuItem("Data", href="/dataset"),
dbc.DropdownMenuItem(divider=True),
dbc.DropdownMenuItem("Insights", href="/interactive-graph"),
],
),
dbc.DropdownMenu(
className = "nav-links-dd",
color="link",
label="Projections",
children=[
dbc.DropdownMenuItem("Case Predictions", href="/projections"),
dbc.DropdownMenuItem(divider=True),
dbc.DropdownMenuItem("Policy Evaluation", href="/policies"),
dbc.DropdownMenuItem(divider=True),
dbc.DropdownMenuItem("Ventilator Allocation", href="/ventilator_allocation"),
],
),
dbc.DropdownMenu(
className = "nav-links-dd",
color="link",
label="Risk Calculators",
children=[
dbc.DropdownMenuItem("Mortality Risk Calculator", href="/mortality_calculator"),
dbc.DropdownMenuItem(divider=True),
dbc.DropdownMenuItem("Infection Risk Calculator", href="/infection_calculator"),
dbc.DropdownMenuItem(divider=True),
dbc.DropdownMenuItem("Treatments Calculator", href="/treatments")
]
),
dbc.DropdownMenu(
className = "nav-links-dd",
color="link",
label="About Us",
children=[
dbc.DropdownMenuItem("The Team", href="/team"),
dbc.DropdownMenuItem(divider=True),
dbc.DropdownMenuItem("Collaborators", href="/collaborators"),
dbc.DropdownMenuItem(divider=True),
dbc.DropdownMenuItem("Model Users", href="/users"),
dbc.DropdownMenuItem(divider=True),
dbc.DropdownMenuItem("Contact Us", href="/contact"),
],
),
dbc.Button(
"In the Press",
className = "nav-links-dd",
color="link", href="/press",
),
],
id="navbar-links",
style={"position":"static"},
no_gutters=True,
className="ml-auto",
)
navbar = dbc.Navbar(
[
html.A(
dbc.Row(
[
dbc.Col(html.Img(src="assets/images/logo_black.png", height="60px")),
],
align="center",
),
href="/home",
),
dbc.NavbarToggler(id="navbar-toggler"),
dbc.Collapse(links, id="navbar-collapse", navbar=True),
],
id="navbar",
color="black",
dark=True,
)
return navbar