Skip to content

Commit 1fda624

Browse files
committed
docs: move header link icon to the right to align with Angular style
1 parent 2b85d59 commit 1fda624

File tree

1 file changed

+22
-16
lines changed

1 file changed

+22
-16
lines changed

docs/src/styles/_markdown.scss

Lines changed: 22 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -8,23 +8,25 @@
88
color: var(--mat-sys-primary);
99
}
1010

11-
h1 {
12-
display: inline-block;
13-
font-size: 32px;
11+
h1,
12+
h2,
13+
h3 {
1414
font-weight: 400;
1515
margin: 32px 0 16px;
16+
display: flex;
17+
align-items: center;
18+
}
19+
20+
h1 {
21+
font-size: 32px;
1622
}
1723

1824
h2 {
1925
font-size: 28px;
20-
margin: 32px 0 16px;
21-
font-weight: 400;
2226
}
2327

2428
h3 {
2529
font-size: 24px;
26-
margin: 32px 0 16px;
27-
font-weight: 400;
2830
}
2931

3032
h4 {
@@ -34,7 +36,8 @@
3436
}
3537

3638
// stylelint-disable-next-line selector-class-pattern
37-
h3 .material-icons, h4 .material-icons {
39+
h3 .material-icons,
40+
h4 .material-icons {
3841
color: var(--mat-sys-on-surface);
3942
}
4043

@@ -44,7 +47,9 @@
4447
font-weight: 400;
4548
}
4649

47-
p, ul, ol {
50+
p,
51+
ul,
52+
ol {
4853
font-size: 16px;
4954
line-height: 28px;
5055
}
@@ -90,13 +95,15 @@
9095
}
9196

9297
.docs-header-link {
98+
// Align header link to the right of the header text.
99+
[header-link] {
100+
order: 2;
101+
}
102+
93103
header-link {
94-
// deduct -30px so the anchor icon will be positioned outside the content
95-
margin-left: -30px;
96-
// Slight margin to try and center the icon better.
97-
margin-top: 2px;
98-
display: inline-block;
99-
vertical-align: middle;
104+
margin-left: 8px;
105+
display: flex;
106+
align-items: center;
100107

101108
// stylelint-disable-next-line material/no-prefixes
102109
user-select: none;
@@ -117,5 +124,4 @@
117124
visibility: visible;
118125
}
119126
}
120-
121127
}

0 commit comments

Comments
 (0)