Skip to content

Commit 12c58d5

Browse files
committed
style: Homepage performance improvements (#2806)
1 parent d62e221 commit 12c58d5

File tree

9 files changed

+21
-25
lines changed

9 files changed

+21
-25
lines changed

.github/workflows/publish-pr.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,10 +116,10 @@ jobs:
116116
comment:
117117
permissions:
118118
pull-requests: write
119-
needs: [deploy_netlify, metadata]
119+
needs: [deploy_garage, metadata]
120120
runs-on: ubuntu-latest
121121
env:
122-
address: ${{ needs.deploy_netlify.outputs.address }}
122+
address: ${{ needs.deploy_garage.outputs.address }}
123123
steps:
124124
- uses: thollander/[email protected]
125125
with:

docs/index.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -86,23 +86,23 @@ Trying to protect all your data from everyone all the time is impractical, expen
8686

8787
<div class="grid cards" markdown>
8888

89-
- ![Proton Mail logo](assets/img/email/protonmail.svg){ .lg .middle .twemoji } **Proton Mail**
89+
- ![Proton Mail logo](assets/img/email/protonmail.svg){ .lg .middle .twemoji loading=lazy } **Proton Mail**
9090

9191
---
9292

9393
Proton Mail is an email service with a focus on privacy, encryption, security, and ease of use. They have been in operation since 2013. Proton AG is based in Genève, Switzerland. The Proton Mail Free plan comes with 500MB of Mail storage, which you can increase up to 1GB for free.
9494

9595
[:octicons-arrow-right-24: Read Full Review](email.md#proton-mail)
9696

97-
- ![Mailbox.org logo](assets/img/email/mailboxorg.svg){ .lg .middle .twemoji } **Mailbox.org**
97+
- ![Mailbox.org logo](assets/img/email/mailboxorg.svg){ .lg .middle .twemoji loading=lazy } **Mailbox.org**
9898

9999
---
100100

101101
Mailbox.org is an email service with a focus on being secure, ad-free, and privately powered by 100% eco-friendly energy. They have been in operation since 2014. Mailbox.org is based in Berlin, Germany. Accounts start with up to 2GB storage, which can be upgraded as needed.
102102

103103
[:octicons-arrow-right-24: Read Full Review](email.md#mailboxorg)
104104

105-
- ![Tuta logo](assets/img/email/tuta.svg#only-light){ .lg .middle .twemoji }![Tuta logo](assets/img/email/tuta-dark.svg#only-dark){ .lg .middle .twemoji } **Tuta**
105+
- ![Tuta logo](assets/img/email/tuta.svg#only-light){ .lg .middle .twemoji loading=lazy }![Tuta logo](assets/img/email/tuta-dark.svg#only-dark){ .lg .middle .twemoji loading=lazy } **Tuta**
106106

107107
---
108108

@@ -162,7 +162,7 @@ Trying to protect all your data from everyone all the time is impractical, expen
162162

163163
## About Privacy Guides
164164

165-
![Privacy Guides logo](assets/brand/logos/png/square/pg-yellow.png){ align=right }
165+
![Privacy Guides logo](assets/brand/logos/png/square/pg-yellow.png){ align=right loading=lazy }
166166

167167
Established in 2021 due to the difficulty of finding unbiased reviewers in the VPN and privacy space, **Privacy Guides** is the most popular, trustworthy, non-profit website that provides information about protecting your *personal* data security and privacy. Our crowdsourced recommendations and reviews of **privacy tools** and our community dedicated to helping others set us apart from other blogs and content creators. The team behind this project has been researching privacy and security in the open-source space for over 5 years, originally with a now-defunct web resource that eventually became the *Privacy Guides* millions of readers trust.
168168

includes/strings.en.env

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,8 @@ HOMEPAGE_CTA_DESCRIPTION="It's important for a website like Privacy Guides to al
1111
HOMEPAGE_DESCRIPTION="A socially motivated website which provides information about protecting your online data privacy and security."
1212
HOMEPAGE_RSS_CHANGELOG_LINK="https://discuss.privacyguides.net/c/site-development/changelog/9.rss"
1313
HOMEPAGE_RSS_CHANGELOG_TITLE="Privacy Guides release changelog"
14-
HOMEPAGE_RSS_BLOG_LINK="https://blog.privacyguides.org/feed_rss_created.xml"
14+
HOMEPAGE_RSS_BLOG_LINK="https://www.privacyguides.org/articles/feed_rss_created.xml"
1515
HOMEPAGE_RSS_BLOG_TITLE="Privacy Guides blog feed"
16-
HOMEPAGE_RSS_STORIES_LINK="https://share.privacyguides.org/web-stories/feed/"
17-
HOMEPAGE_RSS_STORIES_TITLE="Privacy Guides web stories feed"
1816
HOMEPAGE_RSS_FORUM_LINK="https://discuss.privacyguides.net/latest.rss"
1917
HOMEPAGE_RSS_FORUM_TITLE="Latest Privacy Guides forum topics"
2018
HOMEPAGE_HEADER="The collaborative privacy advocacy community."

mkdocs.yml

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -143,14 +143,7 @@ extra:
143143
link:
144144
!ENV [
145145
HOMEPAGE_RSS_BLOG_LINK,
146-
"https://blog.privacyguides.org/feed_rss_created.xml",
147-
]
148-
- title:
149-
!ENV [HOMEPAGE_RSS_STORIES_TITLE, "Privacy Guides Web Stories feed"]
150-
link:
151-
!ENV [
152-
HOMEPAGE_RSS_STORIES_LINK,
153-
"https://share.privacyguides.org/web-stories/feed/",
146+
"https://www.privacyguides.org/articles/feed_rss_created.xml",
154147
]
155148
- title:
156149
!ENV [
@@ -284,8 +277,10 @@ theme:
284277
extra_css:
285278
- assets/stylesheets/extra.css?v=20240802
286279
extra_javascript:
287-
- assets/javascripts/randomize-element.js?v=20240801
288-
- assets/javascripts/feedback.js?v=20240801
280+
- path: assets/javascripts/randomize-element.js?v=20240801
281+
defer: true
282+
- path: assets/javascripts/feedback.js?v=20240801
283+
defer: true
289284

290285
watch:
291286
- theme

theme/assets/javascripts/discourse-topics.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,9 @@ async function main() {
7979
avatar.width = 20;
8080
avatar.height = 20;
8181
avatar.className = "middle";
82+
avatar.loading = "lazy";
83+
avatar.ariaHidden = "true";
84+
avatar.alt = "";
8285
author.appendChild(avatar);
8386
var namespan = document.createElement('span');
8487
namespan.innerText = " Posted by " + author_data['username'];

theme/home.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,6 @@ <h3>Latest discussions</h3>
121121
{% endif %}
122122
{% endblock %}
123123
{% block scripts %}
124-
<script src="{{ 'assets/javascripts/discourse-topics.js' | url }}"></script>
124+
<script defer src="{{ 'assets/javascripts/discourse-topics.js' | url }}"></script>
125125
{{ super() }}
126126
{% endblock %}

theme/partials/alternate.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
{% for alt in config.extra.alternate %}
2828
{% if alt.lang == config.theme.language %}
2929
<button class="md-header__button md-icon" aria-label="{{ lang.t('select.language') }}">
30-
<img alt="{{ config.theme.language }}" class="twemoji" src="{{ alt.icon }}">
30+
<img alt="{{ config.theme.language }}" class="twemoji" src="{{ alt.icon }}" width="20" height="20">
3131
</button>
3232
{% endif %}
3333
{% endfor %}
@@ -40,7 +40,7 @@
4040
hreflang="{{ alt.lang }}"
4141
class="md-select__link"
4242
>
43-
<img alt="{{ alt.lang }}" class="twemoji" src="{{ alt.icon }}">
43+
<img alt="{{ alt.lang }}" class="twemoji" src="{{ alt.icon }}" width="20" height="20">
4444
{{ alt.name }}
4545
</a>
4646
</li>

theme/partials/copyright.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
<br />
3030
{{ copyright.note }}
3131
<br />
32-
<a href='/license'>
32+
<a href='/license' aria-label="More information about our website license.">
3333
{% for icon in copyright.license %}
3434
<span class="twemoji">{% include ".icons/" ~ icon ~ ".svg" %}</span>
3535
{% endfor %}

theme/partials/logo.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,5 +23,5 @@
2323
<img src="{{ 'assets/brand/logos/svg/logo/privacy-guides-rainbow-logo-notext.svg#only-light' | url }}" alt="logo">
2424
<img src="{{ 'assets/brand/logos/svg/logo/privacy-guides-rainbow-logo-notext-darkbg.svg#only-dark' | url }}" alt="logo">
2525
#} -->
26-
<img src="{{ 'assets/brand/logos/svg/logo/privacy-guides-logo-notext.svg#only-light' | url }}" alt="logo">
27-
<img src="{{ 'assets/brand/logos/svg/logo/privacy-guides-logo-notext-darkbg.svg#only-dark' | url }}" alt="logo">
26+
<img src="{{ 'assets/brand/logos/svg/logo/privacy-guides-logo-notext.svg#only-light' | url }}" alt="logo" width="24" height="24">
27+
<img src="{{ 'assets/brand/logos/svg/logo/privacy-guides-logo-notext-darkbg.svg#only-dark' | url }}" alt="logo" width="24" height="24">

0 commit comments

Comments
 (0)