Skip to content

Commit 5612167

Browse files
committed
fix: 🐛 Fix issues from review
1 parent 416ea0c commit 5612167

File tree

2 files changed

+30
-8
lines changed

2 files changed

+30
-8
lines changed
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,23 @@
11
@import "link.variables";
22
@import "../link";
3+
4+
// Define the available icons
5+
.elm-link {
6+
&[rel="configuration"] {
7+
@include icon(glyph(settings), 24, "outline", $partial: $partial);
8+
}
9+
&[rel="messages"] {
10+
@include icon(glyph(chat), 24, "outline", $partial: $partial);
11+
}
12+
&[rel="account"] {
13+
@include icon(glyph(account), 24, "outline", $partial: $partial);
14+
}
15+
&[rel="configuration"],
16+
&[rel="messages"],
17+
&[rel="account"] {
18+
&::before {
19+
// preventing an underlined icon on click
20+
display: inline-block;
21+
}
22+
}
23+
}

source/_patterns/01-elements/link/link.scss

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
@import "link.variables";
33

44
.elm-link {
5+
color: #282d37;
56
display: inline-block;
67
border-radius: to-rem($pxValue: 6);
78

@@ -13,10 +14,6 @@
1314
text-underline-position: auto;
1415
}
1516

16-
&:active {
17-
font-size: to-em($pxValue: 14);
18-
}
19-
2017
// "disabled" links
2118
&[aria-disabled="true"] {
2219
opacity: $link--disabled-opacity;
@@ -36,7 +33,6 @@
3633

3734
&[data-variant="internal"],
3835
&[data-variant="external"] {
39-
color: #282d37;
4036
&::after {
4137
margin-top: -3px;
4238
--icon-margin-before: #{to-rem($pxValue: 4)};
@@ -51,16 +47,21 @@
5147
&:not(.is-icon-text-replace) {
5248
font-size: to-em($pxValue: 12);
5349
}
54-
&:active {
55-
font-size: to-em($pxValue: 10);
56-
}
5750
}
5851

5952
&[data-size="small"] {
53+
// TODO: replace with color when it becomes available via core
6054
color: #42464f;
6155
@extend %size-Small;
6256
&::after {
6357
--icon-font-size: #{to-rem($pxValue: 16)};
6458
}
59+
&[rel],
60+
&[data-icon],
61+
&[data-icon-before] {
62+
@include iconMeta(20);
63+
// TODO: remove when icons are availabe in the correct size
64+
font-size: 16px;
65+
}
6566
}
6667
}

0 commit comments

Comments
 (0)