Skip to content

Commit

Permalink
fix: Align side-nav navigation arrow on IE11 (#490)
Browse files Browse the repository at this point in the history
* Set height value lower than min-height to prevent align-items reset on IE11

* Add reference images

* Restore previous test examples

* Add reference images

Co-authored-by: jmarkowski <jdrekmarkowski@gmail.com>
  • Loading branch information
2 people authored and InnaAtanasova committed Jan 15, 2020
1 parent a43b78b commit 4011bab
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 43 deletions.
4 changes: 3 additions & 1 deletion src/_nested-list.scss
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,9 @@ $block: #{$fd-namespace}-nested-list;
&::after {
@include fd-flex-center();
@include fd-nested-list-arrow();

// `height: 0` is set to prevent breaking `align-items: center` on IE11
// Read more https://github.com/philipwalton/flexbugs/issues/231
height: 0;
min-height: 100%;
min-width: 2.75rem;
color: var(--sapList_TextColor);
Expand Down
84 changes: 42 additions & 42 deletions test/templates/side-nav/index.njk
Original file line number Diff line number Diff line change
Expand Up @@ -2,47 +2,47 @@
{% from "./../format.njk" import format %}

{% block content %}
<!-- output the component example and the code snippet -->
<h2>Side Navigation with one level - text-only, cozy mode</h2>
{% set example %}
<nav class="fd-side-nav">
<div class="fd-side-nav__main-navigation">
<ul class="test-sidenav-list">
<li>Item 1</li>
<li>Item 1</li>
<li>Item 1</li>
<li>Item 1</li>
</ul>
</div>
<div class="fd-side-nav__utility">
<ul class="test-sidenav-list">
<li>Item 1</li>
<li>Item 1</li>
</ul>
</div>
</nav>
{% endset %}
{{ format(example) }}
<!-- output the component example and the code snippet -->
<h2>Side Navigation with one level - text-only, cozy mode</h2>
{% set example %}
<nav class="fd-side-nav">
<div class="fd-side-nav__main-navigation">
<ul class="test-sidenav-list">
<li>Item 1</li>
<li>Item 1</li>
<li>Item 1</li>
<li>Item 1</li>
</ul>
</div>
<div class="fd-side-nav__utility">
<ul class="test-sidenav-list">
<li>Item 1</li>
<li>Item 1</li>
</ul>
</div>
</nav>
{% endset %}
{{ format(example) }}

<br><br><br>
<h2>Side navigation with icons - condensed state</h2>
{% set example %}
<nav class="fd-side-nav fd-side-nav--condensed">
<div class="fd-side-nav__main-navigation">
<ul class="test-sidenav-list">
<li class="test-sidenav-list-icon sap-icon--home"></li>
<li class="test-sidenav-list-icon sap-icon--calendar"></li>
<li class="test-sidenav-list-icon sap-icon--employee"></li>
<li class="test-sidenav-list-icon sap-icon--activities"></li>
</ul>
</div>
<div class="fd-side-nav__utility">
<ul class="test-sidenav-list">
<li class="test-sidenav-list-icon sap-icon--bar-chart"></li>
<li class="test-sidenav-list-icon sap-icon--video"></li>
</ul>
</div>
</nav>
{% endset %}
{{ format(example) }}
<br><br><br>
<h2>Side navigation with icons - condensed state</h2>
{% set example %}
<nav class="fd-side-nav fd-side-nav--condensed">
<div class="fd-side-nav__main-navigation">
<ul class="test-sidenav-list">
<li class="test-sidenav-list-icon sap-icon--home"></li>
<li class="test-sidenav-list-icon sap-icon--calendar"></li>
<li class="test-sidenav-list-icon sap-icon--employee"></li>
<li class="test-sidenav-list-icon sap-icon--activities"></li>
</ul>
</div>
<div class="fd-side-nav__utility">
<ul class="test-sidenav-list">
<li class="test-sidenav-list-icon sap-icon--bar-chart"></li>
<li class="test-sidenav-list-icon sap-icon--video"></li>
</ul>
</div>
</nav>
{% endset %}
{{ format(example) }}
{% endblock %}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 4011bab

Please sign in to comment.