From 683e4cc1ce7f9605529e1a4989d9edbf33d8e9c0 Mon Sep 17 00:00:00 2001 From: sg00dwin Date: Thu, 24 Aug 2017 17:24:09 -0400 Subject: [PATCH] Enhancements to vertical nav animation and slight adjustment on primary nav vertical alignment with arrows --- app/index.html | 54 ++++++++++++++++++----------------- app/styles/_layouts.less | 4 +++ app/styles/_vertical-nav.less | 21 ++++++++++++-- app/views/_sidebar.html | 2 +- 4 files changed, 52 insertions(+), 29 deletions(-) diff --git a/app/index.html b/app/index.html index b3c2796e35..cb20b44aa7 100644 --- a/app/index.html +++ b/app/index.html @@ -42,34 +42,36 @@

Technology preview is enabled

-
- - -
-
-
- - - +
+
+ + +
+
+
+ + +
- + +
diff --git a/app/styles/_layouts.less b/app/styles/_layouts.less index 4cca95343a..6b42fe078c 100644 --- a/app/styles/_layouts.less +++ b/app/styles/_layouts.less @@ -41,6 +41,7 @@ } .container-pf-nav-pf-vertical { height: 100%; + transition: margin-left .1s ease-in-out; &, &.collapsed-nav { margin-left: 0; // override PatternFly default @@ -48,6 +49,9 @@ .middle-header { margin-bottom: @grid-gutter-width / 2; } + .view { + height: 100%; + } } } .surface-shaded { diff --git a/app/styles/_vertical-nav.less b/app/styles/_vertical-nav.less index 72e2918e16..3c82e2feb2 100644 --- a/app/styles/_vertical-nav.less +++ b/app/styles/_vertical-nav.less @@ -5,6 +5,7 @@ .nav-pf-vertical { background-color: @nav-pf-vertical-bg-color; top: @navbar-os-header-mobile; + transition: width .1s ease-in-out, left .1s ease-in-out; z-index: 990; @media(min-width: @screen-sm-min) { top: @navbar-os-header-desktop; @@ -66,9 +67,17 @@ } } .list-group-item-value { + line-height: inherit; text-decoration: none !important; } } + // padding aligns arrow vertically + &.secondary-nav-item-pf > a:after { + padding: 16px 0; + @media(max-width: @screen-xs-max) { + padding: 8px 0; + } + } } &.collapsed { .list-group-item.secondary-nav-item-pf:hover, @@ -81,6 +90,13 @@ left: (@nav-pf-vertical-collapsed-width - 1); // adjust for 1px border } } + &.hide-mobile-nav { + left: -(@nav-pf-vertical-width + 2); // width + box-shadow + } + &.show-mobile-nav { + box-shadow: 2px 0 3px rgba(3,3,3,.15); + left: 0; + } .list-group-item.secondary-nav-item-pf { &:hover > a:after { color: @sidebar-os-icon-hover-color; @@ -94,9 +110,10 @@ background: @nav-pf-vertical-secondary-bg-color; border-left: 0; border-right: 1px solid @nav-pf-vertical-border-color; - top: (@project-bar-height-mobile + @navbar-os-header-mobile - 1); // adjust for 1px border + top:(@project-bar-height-mobile + @navbar-os-header-mobile); + width: @nav-pf-vertical-width + 1; // adjust for 1px border @media(min-width: @screen-sm-min) { - border-left: 1px solid @nav-pf-vertical-border-color; + border-left: 1px solid @nav-pf-vertical-border-color; // inset border between primary and secondary top: (@project-bar-height-desktop + @navbar-os-header-desktop); } .list-group-item { diff --git a/app/views/_sidebar.html b/app/views/_sidebar.html index 52c913f576..5047b5e07e 100644 --- a/app/views/_sidebar.html +++ b/app/views/_sidebar.html @@ -1,7 +1,7 @@