in below code which represents main section of my app I need to apply external_stylesheets which works only with accordion component. What should I change in below code because currently this style is applied for whole app and it cause unwanted style changes. Thanks in advance for help!!!!
import numpy
import pandas as pd
from jupyter_dash import JupyterDash
from dash.dependencies import Input, Output
from dash import dcc
from dash import html
import plotly.express as px
import plotly.graph_objects as go
import dash
import dash_bootstrap_components as dbc
from dash import dash_table
from IPython.core.display import display, HTML
display(HTML("<style>.container { width:100% !important; }</style>"))
external_stylesheets = [dbc.themes.UNITED]
app = JupyterDash(__name__, external_stylesheets=external_stylesheets)
#sets up entire layout of the site
app.layout = html.Div([
dcc.Location(id='url', refresh=False),
html.Div(id='page-content', style = {'font-family': 'Roche Sans'}),
])
app.config.suppress_callback_exceptions = True
# Update the index/page
@app.callback(dash.dependencies.Output('page-content', 'children'),
[dash.dependencies.Input('url', 'pathname')])
def display_page(pathname):
if pathname == '/building-report-intro':
return brp_intro_layout
elif pathname == '/building-report-creation':
return brp_creation_layout
elif pathname == '/process-technology-intro':
return ptr_intro_layout
elif pathname == '/process-technology-report-creation':
return ptr_creation_layout
elif pathname == '/brp-view':
return brp_report_view
else:
return index_page
# You could also return a 404 "URL not found" page here
if __name__ == '__main__':
app.run_server(debug=True)