diff --git a/config/cms.php b/config/cms.php index 645497a93..07f35f7bb 100644 --- a/config/cms.php +++ b/config/cms.php @@ -186,12 +186,12 @@ return [ | | If deep hashing is enabled, the combiner cache will be reset when a change | is detected on imported files, in addition to those referenced directly. - | This will cause slower page performance. If set to null, assets are - | minified, when debug mode (app.debug) is disabled. + | This will cause slower page performance. If set to null, deep hashing + | is used when debug mode (app.debug) is enabled. | */ - 'enableAssetDeepHashing' => false, + 'enableAssetDeepHashing' => null, /* |-------------------------------------------------------------------------- diff --git a/themes/demo/README.md b/themes/demo/README.md index 024614237..181268d0a 100644 --- a/themes/demo/README.md +++ b/themes/demo/README.md @@ -18,7 +18,7 @@ If you clone this theme to use as a starting point. You may follow these instruc ## Combining CSS and JavaScript -This theme doesn't combine assets for performance reasons. To combine the stylesheets, replace the following lines in the default layout. +This theme doesn't combine assets for performance reasons. To combine the stylesheets, replace the following lines in the default layout. When combining with this theme, we recommend enabling the config `enableAssetDeepHashing` in the file **config/cms.php**. Uncombined stylesheets: diff --git a/themes/demo/assets/css/theme.css b/themes/demo/assets/css/theme.css index 84c32cde2..f8de963ef 100644 --- a/themes/demo/assets/css/theme.css +++ b/themes/demo/assets/css/theme.css @@ -428,10 +428,6 @@ left: 50%; transition: all 0.2s ease 0.05s; } -.navbar-collapse:not(.in):not(.collapsing) .navbar-nav li.active > a:after, -.navbar-collapse:not(.in):not(.collapsing) .navbar-nav li > a:hover:after { - background: #000000; -} .navbar-collapse:not(.in):not(.collapsing) .navbar-nav li.active > a:after { width: 100% !important; left: 0 !important; @@ -440,12 +436,29 @@ width: 100%; left: 0; } -.navbar-collapse:not(.in):not(.collapsing) .navbar-nav li.active > a:hover:after { +.navbar-collapse:not(.in):not(.collapsing) .navbar-nav li.active > a { + background: transparent; +} +.navbar-inverse .navbar-collapse:not(.in):not(.collapsing) .navbar-nav li.active > a:after, +.navbar-inverse .navbar-collapse:not(.in):not(.collapsing) .navbar-nav li > a:hover:after { background: #000000; } -.navbar-collapse:not(.in):not(.collapsing) .navbar-nav li > a:hover:after { +.navbar-inverse .navbar-collapse:not(.in):not(.collapsing) .navbar-nav li.active > a:hover:after { + background: #000000; +} +.navbar-inverse .navbar-collapse:not(.in):not(.collapsing) .navbar-nav li > a:hover:after { background: #e67e22; } +.navbar-default .navbar-collapse:not(.in):not(.collapsing) .navbar-nav li.active > a:after, +.navbar-default .navbar-collapse:not(.in):not(.collapsing) .navbar-nav li > a:hover:after { + background: #64ae5b; +} +.navbar-default .navbar-collapse:not(.in):not(.collapsing) .navbar-nav li.active > a:hover:after { + background: #64ae5b; +} +.navbar-default .navbar-collapse:not(.in):not(.collapsing) .navbar-nav li > a:hover:after { + background: #93dc8a; +} body { padding-top: 70px; } diff --git a/themes/demo/assets/less/elements/navbar.less b/themes/demo/assets/less/elements/navbar.less index 0d7f88073..536491117 100644 --- a/themes/demo/assets/less/elements/navbar.less +++ b/themes/demo/assets/less/elements/navbar.less @@ -27,7 +27,6 @@ } .navbar-collapse:not(.in):not(.collapsing) .navbar-nav li { - > a { transition: color 0.2s ease 0.05s; } @@ -44,11 +43,6 @@ transition: all 0.2s ease 0.05s; } - &.active > a:after, - > a:hover:after { - background: @navbar-link-stripe-color-active; - } - &.active > a:after { width: 100% !important; left: 0 !important; @@ -59,11 +53,37 @@ left: 0; } + &.active > a { + background: transparent; + } +} + +.navbar-inverse .navbar-collapse:not(.in):not(.collapsing) .navbar-nav li { + &.active > a:after, + > a:hover:after { + background: @navbar-inverse-stripe-color-active; + } + &.active > a:hover:after { - background: @navbar-link-stripe-color-active; + background: @navbar-inverse-stripe-color-active; } > a:hover:after { - background: @navbar-link-stripe-color-hover; + background: @navbar-inverse-stripe-color-hover; + } +} + +.navbar-default .navbar-collapse:not(.in):not(.collapsing) .navbar-nav li { + &.active > a:after, + > a:hover:after { + background: @navbar-default-stripe-color-active; + } + + &.active > a:hover:after { + background: @navbar-default-stripe-color-active; + } + + > a:hover:after { + background: @navbar-default-stripe-color-hover; } } diff --git a/themes/demo/assets/less/theme/variables.less b/themes/demo/assets/less/theme/variables.less index 11d59c940..6e5ce0a00 100644 --- a/themes/demo/assets/less/theme/variables.less +++ b/themes/demo/assets/less/theme/variables.less @@ -39,8 +39,10 @@ @navbar-inverse-bg: #000; @navbar-inverse-link-color: rgba(255,255,255,0.6); -@navbar-link-stripe-color-active: #000; -@navbar-link-stripe-color-hover: #e67e22; +@navbar-inverse-stripe-color-active: #000; +@navbar-inverse-stripe-color-hover: #e67e22; +@navbar-default-stripe-color-active: #64ae5b; +@navbar-default-stripe-color-hover: #93dc8a; // Callouts // --------------------------------------------------