1

I am using dash bootstrap components and I would like to remove the black border on hover on the header. also if I remove the 404 page from the navbar, the 404 does not work when i enter a page that does not exist.

any help appreciated.

Thank you.

dbc_css = ("https://cdn.jsdelivr.net/gh/AnnMarieW/dash-bootstrap-templates@V1.0.7/dbc.min.css")



app = Dash(__name__, 
           use_pages=True, 
           title='Portfolio Optimization', 
           external_stylesheets=[dbc.themes.SLATE,dbc_css]
           )

load_figure_template("slate")

and the header code is:

header = dbc.Navbar(
dbc.Container(
    [
        html.A(
            dbc.Row(
                dbc.Col(dbc.NavbarBrand("brandName")),
                align="center",
                className="g-0",
            ),
            href="/",
            style={"textDecoration": "none"},
        ),
        dbc.Row(
            [
                dbc.NavbarToggler(id="navbar-toggler"),
                dbc.Collapse(
                    dbc.Nav(
                        [
                            dbc.NavItem(dbc.NavLink('Home',               href='/')),
                            dbc.NavItem(dbc.NavLink('About',              href='/about')),
                            dbc.NavItem(dbc.NavLink('Help',               href='/help')),
                            dbc.NavItem(dbc.NavLink('404',                href='/404')),
                            
                            
                        ],
                        # make sure nav takes up the full width for auto
                        # margin to get applied
                        className="w-100"
                    ),
                    id="navbar-collapse",
                    is_open=False,
                    navbar=True,
                    
                ),
            ],
            # the row should expand to fill the available horizontal space
            className="flex-grow-1",
        ),
    ],
    fluid=True,
    
),
dark=True,
color="dark",
className="dbc"
)

no hover hover

grayred8
  • 93
  • 6

0 Answers0