Sidebar offcanvas navigation links have wrong color in some edge cases

Created on 20 November 2024, about 1 month ago

Problem/Motivation

We are using BS dropdown CSS rules for our nav links in main navigation. This is handy so we can cover the cases when dropdown menus option is turned on but also because we need helper CSS classes to cover our custom handling. We have reset CSS rules that make this links look like regular main navigation links and not like dropdown links - for cases for mobile navigation, second level horizontal, etc.

The problem is that in some edge cases CSS navigation rules will be loaded before dropdown CSS rules and some dropdown rules (like color) will be applied and this will cause visual bug.

One solution for this problem would be to stop using dropdown CSS classes when we do not need them, but then we would need to also adjust the code in navigation.js and this could also affect child themes that are using dropdown CSS classes for it CSS rules. I am not sure for now how good is this option.

As alternative we will adjust our CSS rules and make sure that we always set color rule for nav-link dropdown-item combination so we are sure that dropdown CSS color rules are not applied.

🐛 Bug report
Status

Active

Version

1.0

Component

BS Bootstrap

Created by

🇷🇸Serbia pivica

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024