From b540104d4a1485cb97ec7a39fcfb04bb7f23de6e Mon Sep 17 00:00:00 2001 From: crisbeto Date: Mon, 22 Oct 2018 19:55:33 +0200 Subject: [PATCH] fix(stepper): selector assuming that there will always be a dir attribute One of the selectors in the step header assumes that there will be at least one parent with a `dir="ltr"` or `dir="rtl"`. These changes rework it to have LTR as the base. Fixes #13741. --- src/lib/stepper/stepper.scss | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/lib/stepper/stepper.scss b/src/lib/stepper/stepper.scss index a91a241de129..4999373d4d3a 100644 --- a/src/lib/stepper/stepper.scss +++ b/src/lib/stepper/stepper.scss @@ -76,18 +76,23 @@ $mat-stepper-line-gap: 8px !default; height: auto; padding: $mat-stepper-side-gap; - [dir='ltr'] &:not(:last-child)::after, + &:not(:last-child)::after, [dir='rtl'] &:not(:first-child)::after { @extend %mat-header-horizontal-line-label-position-bottom; right: 0; } - [dir='ltr'] &:not(:first-child)::before, + &:not(:first-child)::before, [dir='rtl'] &:not(:last-child)::before { @extend %mat-header-horizontal-line-label-position-bottom; left: 0; } + [dir='rtl'] &:last-child::before, + [dir='rtl'] &:first-child::after { + display: none; + } + & .mat-step-icon, & .mat-step-icon-not-touched { // Cleans margin both for ltr and rtl direction