Skip to content

Commit 742179d

Browse files
ENGCOM-3229: icon text showing feature #18706
- Merge Pull Request #18706 from Karlasa/magento2:icons-feature - Merged commits: 1. 22a40cc 2. 4b9b8a3
2 parents 77af5d6 + 4b9b8a3 commit 742179d

File tree

1 file changed

+19
-7
lines changed

1 file changed

+19
-7
lines changed

lib/web/css/source/lib/_icons.less

Lines changed: 19 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,12 @@
2525
@_icon-font-text-hide: @icon-font__text-hide,
2626
@_icon-font-display: @icon-font__display
2727
) when (@_icon-font-position = before) {
28-
._lib-icon-text-hide(@_icon-font-text-hide);
2928
.lib-css(display, @_icon-font-display);
30-
text-decoration: none;
29+
text-decoration: none;
30+
31+
& when not (@_icon-font-content = false) {
32+
._lib-icon-text-hide(@_icon-font-text-hide);
33+
}
3134

3235
&:before {
3336
._lib-icon-font(
@@ -68,10 +71,13 @@
6871
@_icon-font-text-hide: @icon-font__text-hide,
6972
@_icon-font-display: @icon-font__display
7073
) when (@_icon-font-position = after) {
71-
._lib-icon-text-hide(@_icon-font-text-hide);
7274
.lib-css(display, @_icon-font-display);
7375
text-decoration: none;
74-
76+
77+
& when not (@_icon-font-content = false) {
78+
._lib-icon-text-hide(@_icon-font-text-hide);
79+
}
80+
7581
&:after {
7682
._lib-icon-font(
7783
@_icon-font-content,
@@ -151,8 +157,11 @@
151157
@_icon-image-text-hide: @icon__text-hide
152158
) when (@_icon-image-position = before) {
153159
display: inline-block;
154-
._lib-icon-text-hide(@_icon-image-text-hide);
155-
160+
161+
& when not (@_icon-image = false) {
162+
._lib-icon-text-hide(@_icon-image-text-hide);
163+
}
164+
156165
&:before {
157166
._lib-icon-image(
158167
@_icon-image,
@@ -179,7 +188,10 @@
179188
@_icon-image-text-hide: @icon__text-hide
180189
) when (@_icon-image-position = after) {
181190
display: inline-block;
182-
._lib-icon-text-hide(@_icon-image-text-hide);
191+
192+
& when not (@_icon-image = false) {
193+
._lib-icon-text-hide(@_icon-font-text-hide);
194+
}
183195

184196
&:after {
185197
._lib-icon-image(

0 commit comments

Comments
 (0)