-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathapp.py
44 lines (37 loc) · 907 Bytes
/
app.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
from dash import Dash, html, dcc, dash_table
import dash
import plotly.express as px
import pandas as pd
import numpy as np
import dash_bootstrap_components as dbc
app = Dash(
__name__,
external_stylesheets=[dbc.themes.COSMO],
use_pages=True
# , suppress_callback_exceptions=True
)
navbar = dbc.NavbarSimple(
children=[
dbc.NavItem(dbc.NavLink(page.get("name"), href=page.get("relative_path")))
for page in dash.page_registry.values()
],
style={"padding": "0% 3%"},
brand="QoS Dashboard",
brand_href="/",
color="#002366",
dark=True,
fluid=True,
sticky="top",
)
# app rendering
app.layout = html.Div(
children=[
navbar,
html.Div(
style={"padding": "1% 3%", "overflow": "hidden"},
children=[dash.page_container],
),
]
)
if __name__ == "__main__":
app.run_server(debug=True)