diff --git a/packages/styles/scss/components/link-with-icon/_link-with-icon.scss b/packages/styles/scss/components/link-with-icon/_link-with-icon.scss index 1841a5037f1..46495d4fdf8 100644 --- a/packages/styles/scss/components/link-with-icon/_link-with-icon.scss +++ b/packages/styles/scss/components/link-with-icon/_link-with-icon.scss @@ -1,5 +1,5 @@ /** - * Copyright IBM Corp. 2016, 2021 + * Copyright IBM Corp. 2016, 2022 * * This source code is licensed under the Apache-2.0 license found in the * LICENSE file in the root directory of this source tree. @@ -43,18 +43,21 @@ } } } - } - .#{$prefix}--link-with-icon.#{$prefix}--link-with-icon__icon-left { - justify-content: flex-end; - flex-direction: row-reverse; + &.#{$prefix}--link-with-icon__icon-left, + .#{$prefix}--link-with-icon.#{$prefix}--link-with-icon--inline-icon.#{$prefix}--link-with-icon__icon-left { + display: flex; + justify-content: flex-end; + flex-direction: row-reverse; - svg { - align-self: start; - position: relative; - top: 1px; - margin-left: 0; - margin-right: $carbon--spacing-03; + svg, + ::slotted(svg[slot='icon']) { + align-self: start; + position: relative; + margin-left: 0; + margin-right: $carbon--spacing-03; + top: 1px; + } } } diff --git a/packages/web-components/src/components/link-with-icon/link-with-icon.scss b/packages/web-components/src/components/link-with-icon/link-with-icon.scss index c519af7154f..3ed03696fc6 100644 --- a/packages/web-components/src/components/link-with-icon/link-with-icon.scss +++ b/packages/web-components/src/components/link-with-icon/link-with-icon.scss @@ -1,5 +1,5 @@ // -// Copyright IBM Corp. 2020, 2021 +// Copyright IBM Corp. 2020, 2022 // // This source code is licensed under the Apache-2.0 license found in the // LICENSE file in the root directory of this source tree. @@ -17,16 +17,6 @@ .#{$prefix}--link--disabled { color: $disabled-02; } - - .#{$prefix}--link-with-icon__icon-left ::slotted(svg[slot='icon']) { - margin-right: $carbon--spacing-03; - margin-left: 0; - } - - .#{$prefix}--link-with-icon__icon-right ::slotted(svg[slot='icon']) { - margin-left: $carbon--spacing-03; - margin-right: 0; - } } :host(#{$dds-prefix}-link-list-item) {