Skip to content

Commit f4d894d

Browse files
committed
Fixed footer direction label being cut off
1 parent 7c473e1 commit f4d894d

File tree

8 files changed

+25
-28
lines changed

8 files changed

+25
-28
lines changed

material/assets/stylesheets/main.666dee5c.min.css

-1
This file was deleted.

material/assets/stylesheets/main.666dee5c.min.css.map

-1
This file was deleted.

material/assets/stylesheets/main.7a7fce14.min.css

+1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

material/assets/stylesheets/main.7a7fce14.min.css.map

+1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

material/base.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
{% endif %}
4141
{% endblock %}
4242
{% block styles %}
43-
<link rel="stylesheet" href="{{ 'assets/stylesheets/main.666dee5c.min.css' | url }}">
43+
<link rel="stylesheet" href="{{ 'assets/stylesheets/main.7a7fce14.min.css' | url }}">
4444
{% if config.theme.palette %}
4545
{% set palette = config.theme.palette %}
4646
<link rel="stylesheet" href="{{ 'assets/stylesheets/palette.a0c5b2b5.min.css' | url }}">

material/partials/footer.html

+6-6
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,10 @@
1515
{% include ".icons/material/arrow-left.svg" %}
1616
</div>
1717
<div class="md-footer__title">
18+
<span class="md-footer__direction">
19+
{{ direction }}
20+
</span>
1821
<div class="md-ellipsis">
19-
<span class="md-footer__direction">
20-
{{ direction }}
21-
</span>
2222
{{ page.previous_page.title }}
2323
</div>
2424
</div>
@@ -28,10 +28,10 @@
2828
{% set direction = lang.t("footer.next") %}
2929
<a href="{{ page.next_page.url | url }}" class="md-footer__link md-footer__link--next" aria-label="{{ direction }}: {{ page.next_page.title | e }}" rel="next">
3030
<div class="md-footer__title">
31+
<span class="md-footer__direction">
32+
{{ direction }}
33+
</span>
3134
<div class="md-ellipsis">
32-
<span class="md-footer__direction">
33-
{{ direction }}
34-
</span>
3535
{{ page.next_page.title }}
3636
</div>
3737
</div>

src/assets/stylesheets/main/components/_footer.scss

+10-13
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,9 @@
5454
// a tiny factor seems to get rid of the ellipsis and renders the text as
5555
// it should - see https://bit.ly/2ZUCXQ8
5656
flex-grow: 0.01;
57-
padding-top: px2rem(28px);
58-
padding-bottom: px2rem(8px);
57+
align-items: end;
58+
max-width: 100%;
59+
margin-block: px2rem(20px) px2rem(8px);
5960
overflow: hidden;
6061
outline-color: var(--md-accent-fg-color);
6162
transition: opacity 250ms;
@@ -70,14 +71,15 @@
7071
transform: scaleX(-1);
7172
}
7273

73-
// Footer link to previous page
74-
&--prev {
74+
// [mobile -]: Adjust width to 25/75 and hide title
75+
@include break-to-device(mobile) {
7576

76-
// [mobile -]: Adjust width to 25/75 and hide title
77-
@include break-to-device(mobile) {
77+
// Footer link to previous page
78+
&--prev {
79+
flex-shrink: 0;
7880

7981
// Hide footer title
80-
.md-footer__title {
82+
.md-footer__title {
8183
display: none;
8284
}
8385
}
@@ -97,12 +99,11 @@
9799

98100
// Footer title
99101
&__title {
100-
position: relative;
101102
flex-grow: 1;
102103
max-width: calc(100% - #{px2rem(48px)});
103104
padding: 0 px2rem(20px);
105+
margin-bottom: px2rem(14px);
104106
font-size: px2rem(18px);
105-
line-height: px2rem(48px);
106107
white-space: nowrap;
107108
}
108109

@@ -114,10 +115,6 @@
114115

115116
// Footer link direction (i.e. prev and next)
116117
&__direction {
117-
position: absolute;
118-
inset-inline: 0;
119-
padding: 0 px2rem(20px);
120-
margin-top: px2rem(-20px);
121118
font-size: px2rem(12.8px);
122119
opacity: 0.7;
123120
}

src/partials/footer.html

+6-6
Original file line numberDiff line numberDiff line change
@@ -48,10 +48,10 @@
4848
{% include ".icons/material/arrow-left.svg" %}
4949
</div>
5050
<div class="md-footer__title">
51+
<span class="md-footer__direction">
52+
{{ direction }}
53+
</span>
5154
<div class="md-ellipsis">
52-
<span class="md-footer__direction">
53-
{{ direction }}
54-
</span>
5555
{{ page.previous_page.title }}
5656
</div>
5757
</div>
@@ -68,10 +68,10 @@
6868
rel="next"
6969
>
7070
<div class="md-footer__title">
71+
<span class="md-footer__direction">
72+
{{ direction }}
73+
</span>
7174
<div class="md-ellipsis">
72-
<span class="md-footer__direction">
73-
{{ direction }}
74-
</span>
7575
{{ page.next_page.title }}
7676
</div>
7777
</div>

0 commit comments

Comments
 (0)