Problem/Motivation

Support for off-canvas navbar and dropdown menus is currently hardcoded in code. This makes the implementation of client sites with very different navigation implementation difficult a bit difficult because you need to override a lot of CSS.

We should decouple off-canvas and dropdown support more so it can be disabled with current theme options.

Comments

pivica created an issue. See original summary.

pivica’s picture

Status: Active » Needs review
Issue tags: +next-release
StatusFileSize
new11.51 KB

Here is a first patch.

pivica’s picture

StatusFileSize
new754 bytes
new11.51 KB

Fixed string concatenation for dropdown-toggle case.

pivica’s picture

StatusFileSize
new31.42 KB
new23.48 KB

The previous patch is introducing a nasty bug because in macro navbar_type is not defined, we need to pass it again as a variable.

Additionally, the refactoring and moving offcanvas CSS code to a new sass file exposed a new bug in drush generator - it is not handling this case correctly and leaving imports in previous SASS file which is producing duplicated CSS code now.

Moreover, a couple of smaller bugs in navbar JS code are fixed, due to extensive testing, and code is improved a bit.

Hopefully, all the problems are addressed with a new patch.

pivica’s picture

StatusFileSize
new31.42 KB

The last patch is fine but it really has a wrong name, attaching a new one.

pivica’s picture

StatusFileSize
new33.14 KB
new2.86 KB

A New version that moves CSS needed for dropdown or horizontal to separate SASS partial so we can exclude these rules when navbar type option is off.

pivica’s picture

StatusFileSize
new35.03 KB

Renamed newly added partial _navbar-layout to _navbar-second-level.

pivica’s picture

StatusFileSize
new1.82 KB
new36.27 KB

Let's not render off-canvas close link when offcanvase type is off. Improved off-canvas type description info for off option.

  • pivica committed e57f327 on 8.x-1.x
    Issue #3078120 by pivica: Decouple support for navbar off-canvas and...
pivica’s picture

Status: Needs review » Fixed

Fixed 'off canvas' spell error, committed.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.