Skip to content

Commit 2b508be

Browse files
authored
Merge pull request #311 from torchbox/fix-wide-footer-logos-recreated-with-access
Adjust horizontal footer logos style
2 parents 9097719 + ebcd64c commit 2b508be

File tree

2 files changed

+21
-14
lines changed

2 files changed

+21
-14
lines changed
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,39 @@
11
{% load wagtailcore_tags wagtailimages_tags wagtail_cache navigation_tags %}
2-
32
<footer class="footer">
4-
53
<div class="grid footer__top ">
64
<span class="grid__footer-line footer__line"></span>
75
{% with contact=page.footer_contact %}
86
{% if contact %}
97
{% include "patterns/molecules/footer-cta/footer-cta.html" with contact_heading=contact.title contact_text=contact.text contact_link=contact.link contact_name=contact.name contact_role=contact.role contact_image=contact.image contact_action=contact.button_text contact_email=contact.email_text %}
108
{% endif %}
119
{% endwith %}
12-
1310
<div class="grid__footer-links">
1411
{% wagtailcache 600 "footerlinks" current_site.pk is_pattern_library %}
1512
{% footerlinks %}
1613
{% endwagtailcache %}
17-
1814
<ul class="footer__socials">
1915
<li>
20-
<a aria-label="Follow us on Twitter" href="https://twitter.com/torchbox" class="footer__social-link">
16+
<a aria-label="Follow us on Twitter"
17+
href="https://twitter.com/torchbox"
18+
class="footer__social-link">
2119
<svg width="24" height="24" aria-hidden="true" class="footer__social-icon">
2220
<use xlink:href="#twitter" />
2321
</svg>
2422
</a>
2523
</li>
2624
<li>
27-
<a aria-label="Connect with us on LinkedIn" href="https://www.linkedin.com/company/torchbox" class="footer__social-link">
25+
<a aria-label="Connect with us on LinkedIn"
26+
href="https://www.linkedin.com/company/torchbox"
27+
class="footer__social-link">
2828
<svg width="24" height="24" aria-hidden="true" class="footer__social-icon">
2929
<use xlink:href="#linkedin" />
3030
</svg>
3131
</a>
3232
</li>
3333
<li>
34-
<a aria-label="Follow us on Instagram" href="https://www.instagram.com/torchboxltd/" class="footer__social-link">
34+
<a aria-label="Follow us on Instagram"
35+
href="https://www.instagram.com/torchboxltd/"
36+
class="footer__social-link">
3537
<svg width="24" height="24" aria-hidden="true" class="footer__social-icon">
3638
<use xlink:href="#instagram" />
3739
</svg>
@@ -40,7 +42,6 @@
4042
</ul>
4143
</div>
4244
</div>
43-
4445
<div class="footer__bottom-container">
4546
<div class="grid footer__bottom">
4647
<div class="grid__footer-logos">
@@ -52,7 +53,11 @@
5253
<li>
5354
{% with logo.link as link %}
5455
<a class="footer__logo-link" href="{{ link.url }}">
55-
{% image logo.image max-100x100 format-webp loading="lazy" class="footer__logo" alt=logo.alt_text|default:logo.image.title %}
56+
{% if logo.image.width > logo.image.height %}
57+
{% image logo.image max-200x100 format-webp loading="lazy" class="footer__logo" alt=logo.alt_text|default:logo.image.title %}
58+
{% else %}
59+
{% image logo.image max-100x100 format-webp loading="lazy" class="footer__logo footer__logo--narrow" alt=logo.alt_text|default:logo.image.title %}
60+
{% endif %}
5661
</a>
5762
{% endwith %}
5863
</li>
@@ -65,18 +70,16 @@
6570
<div class="grid__footer-company">
6671
<div class="footer__company">
6772
<div class="footer__company-address">
68-
<p>© Torchbox {% now "Y" %} - </p><address>3rd Floor, 15 Colston St, Bristol, BS1 5AP</address>
73+
<p>© Torchbox {% now "Y" %} -</p>
74+
<address>3rd Floor, 15 Colston St, Bristol, BS1 5AP</address>
6975
</div>
7076
<div>
7177
<p>Registered in England &amp; Wales. Company no. 3983354, VAT no. 752981011</p>
7278
</div>
7379
</div>
7480
</div>
7581
</div>
76-
7782
{% include "patterns/molecules/carbon-impact/carbon-impact.html" %}
7883
</div>
79-
8084
{% include "patterns/molecules/cookie-message/cookie-message.html" %}
81-
8285
</footer>

tbx/static_src/sass/components/_footer.scss

+5-1
Original file line numberDiff line numberDiff line change
@@ -85,11 +85,15 @@
8585

8686
&__logo {
8787
filter: grayscale(1) invert(1) brightness(0.52);
88-
max-width: 70px;
88+
max-width: 150px;
8989

9090
@include high-contrast-light-mode() {
9191
filter: none;
9292
}
93+
94+
&--narrow {
95+
max-width: 70px;
96+
}
9397
}
9498

9599
&__company {

0 commit comments

Comments
 (0)