I am trying to use Dash Alerts bootstrap components on my dash app but the alerts are not displaying colors like “primary” , "warning " etc so when i load my app it doesn’t get loaded with the colors
app = dash.Dash(name)
alerts = html.Div(
[
dbc.Alert(“This is a primary alert”, color="#ff3300"),
dbc.Alert(“This is a secondary alert”, color=“secondary”),
dbc.Alert(“This is a success alert! Well done!”, color=“success”),
dbc.Alert(“This is a warning alert… be careful…”, color=“warning”),
dbc.Alert(“This is a danger alert. Scary!”, color=“danger”),
dbc.Alert(“This is an info alert. Good to know!”, color=“info”),
dbc.Alert(“This is a light alert”, color=“light”),
dbc.Alert(“This is a dark alert”, color=“dark”),
]
)
I am returning these alerts in one callback function
@app.callback(dash.dependencies.Output(‘page-content’, ‘children’),
[dash.dependencies.Input(‘url’, ‘search’),Input(‘graph-update’, ‘n_intervals’)])
def display_page(search,n_intervals):
return alerts
How to load these standard colors on my app ?How to make it work any help is appreciated