1
0
Fork 0

refactor: Reduce complexity

default.html: Use Google Fonts and load efficiently fonts with <link rel="preconnect" ...> and comment the self hosted way
teams.html: Set width and height directly in the HTML
_config.yml: Modify the style of sass to compressed
_team: Make consistent use of double quote and remove width and height attributes
style.scss: Comment import of fonts component
This commit is contained in:
root 2021-08-09 13:02:59 +02:00
parent 45518323f3
commit 5c54466e13
11 changed files with 23 additions and 32 deletions

View File

@ -30,7 +30,7 @@ defaults:
sass: sass:
indentWidth: 4 indentWidth: 4
style: compact # possible values: nested expanded compact compressed style: compressed # possible values: nested expanded compact compressed
precision: 10 precision: 10
plugins: plugins:

View File

@ -6,7 +6,12 @@
<title>{% if page.title %}{{page.title}}{% else %}{{ site.title | escape }}{% endif %}</title> <title>{% if page.title %}{{page.title}}{% else %}{{ site.title | escape }}{% endif %}</title>
<meta name="viewport" content="width=device-width, initial-scale=1" /> <meta name="viewport" content="width=device-width, initial-scale=1" />
<link rel="icon" type="image/png" href="{{ '/images/favicon-32x32.svg' | relative_url }}"> <link rel="icon" type="image/png" href="{{ '/images/favicon-32x32.svg' | relative_url }}">
<link rel="preload" href="{{ '/assets/fonts/playfair-display.woff2' | relative_url }}" as="font" type="font/woff2" crossorigin> <!-- Google Fonts CDN -->
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;700&display=swap" rel="stylesheet">
<!-- Self host font -->
<!-- <link rel="preload" href="{{ '/assets/fonts/playfair-display.woff2' | relative_url }}" as="font" type="font/woff2" crossorigin> -->
<link href="{{ '/assets/css/style.css' | relative_url }}" rel="stylesheet"> <link href="{{ '/assets/css/style.css' | relative_url }}" rel="stylesheet">
{% if page.description %}<meta name="description" content="{{ page.description }}" />{% endif %} {% if page.description %}<meta name="description" content="{{ page.description }}" />{% endif %}
@ -29,7 +34,7 @@
</div> </div>
{% include footer.html %} {% include footer.html %}
{% include sub-footer.html %} {% include sub-footer.html %}
<script type="text/javascript" src="{{ "/assets/js/scripts.js" | relative_url }}"></script> <script type="text/javascript" src="{{ '/assets/js/scripts.js' | relative_url }}"></script>
{% include google-analytics.html %} {% include google-analytics.html %}
</body> </body>
</html> </html>

View File

@ -26,7 +26,7 @@ bodyClass: "page-teams"
<div class="team team-summary team-summary-large"> <div class="team team-summary team-summary-large">
{% if team.image %} {% if team.image %}
<div class="team-image"> <div class="team-image">
<img width="{{ team.image_width }}" height="{{ team.image_height }}" alt="{{ team.title }}" class="img-fluid mb-2" src="{{ team.image | relative_url }}" /> <img width="90" height="90" alt="{{ team.title }}" class="img-fluid mb-2" src="{{ team.image | relative_url }}" />
</div> </div>
{% endif %} {% endif %}
<div class="team-meta"> <div class="team-meta">
@ -48,7 +48,7 @@ bodyClass: "page-teams"
<div class="team team-summary"> <div class="team team-summary">
{% if team.image %} {% if team.image %}
<div class="team-image"> <div class="team-image">
<img width="{{ team.image_width }}" height="{{ team.image_height }}" alt="{{ team.title }}" class="img-fluid mb-2" src="{{ team.image | relative_url }}" /> <img width="60" height="60" alt="{{ team.title }}" class="img-fluid mb-2" src="{{ team.image | relative_url }}" />
</div> </div>
{% endif %} {% endif %}
<div class="team-meta"> <div class="team-meta">

View File

@ -3,8 +3,6 @@ title: "Bill McDonald"
date: 2018-11-19T10:47:58+10:00 date: 2018-11-19T10:47:58+10:00
draft: false draft: false
image: "images/team/nonsap-visuals-kMJp7620W6U-unsplash.jpg" image: "images/team/nonsap-visuals-kMJp7620W6U-unsplash.jpg"
image_width: 60
image_height: 60
jobtitle: "Graphic Designer" jobtitle: "Graphic Designer"
linkedinurl: "" linkedinurl: ""
weight: 7 weight: 7

View File

@ -1,11 +1,9 @@
--- ---
title: 'Mike Vance' title: "Mike Vance"
date: 2018-12-20T13:44:30+10:00 date: 2018-12-20T13:44:30+10:00
draft: false draft: false
image: 'images/team/joseph-gonzalez-399972-unsplash.jpg' image: "images/team/joseph-gonzalez-399972-unsplash.jpg"
image_width: 60 jobtitle: "Art Director"
image_height: 60
jobtitle: 'Art Director'
linkedinurl: "" linkedinurl: ""
weight: 3 weight: 3
--- ---

View File

@ -3,8 +3,6 @@ title: "Peter Van Eijk"
date: 2018-11-19T10:47:58+10:00 date: 2018-11-19T10:47:58+10:00
draft: false draft: false
image: "images/team/peter-van-eijk-711986-unsplash.jpg" image: "images/team/peter-van-eijk-711986-unsplash.jpg"
image_width: 90
image_height: 90
jobtitle: "Director" jobtitle: "Director"
linkedinurl: "https://www.linkedin.com/" linkedinurl: "https://www.linkedin.com/"
promoted: true promoted: true

View File

@ -1,11 +1,9 @@
--- ---
title: 'Robert Johnson' title: "Robert Johnson"
date: 2018-12-20T13:44:23+10:00 date: 2018-12-20T13:44:23+10:00
draft: false draft: false
image: 'images/team/vince-fleming-613817-unsplash.jpg' image: "images/team/vince-fleming-613817-unsplash.jpg"
image_width: 60 jobtitle: "Developer"
image_height: 60
jobtitle: 'Developer'
linkedinurl: "https://www.linkedin.com/" linkedinurl: "https://www.linkedin.com/"
weight: 3 weight: 3
--- ---

View File

@ -3,8 +3,6 @@ title: "Sage Kirk"
date: 2018-11-19T10:47:58+10:00 date: 2018-11-19T10:47:58+10:00
draft: false draft: false
image: "images/team/sage-kirk-485982-unsplash.jpg" image: "images/team/sage-kirk-485982-unsplash.jpg"
image_width: 90
image_height: 90
jobtitle: "Accounting Partner" jobtitle: "Accounting Partner"
linkedinurl: "https://www.linkedin.com/example2" linkedinurl: "https://www.linkedin.com/example2"
promoted: true promoted: true

View File

@ -1,11 +1,9 @@
--- ---
title: 'Susan Shelton' title: "Susan Shelton"
date: 2018-12-20T13:45:06+10:00 date: 2018-12-20T13:45:06+10:00
draft: false draft: false
image: 'images/team/cristian-newman-94319-unsplash.jpg' image: "images/team/cristian-newman-94319-unsplash.jpg"
image_width: 60 jobtitle: "Developer"
image_height: 60
jobtitle: 'Developer'
weight: 5 weight: 5
--- ---

View File

@ -1,11 +1,9 @@
--- ---
title: 'Tamara Ells' title: "Tamara Ells"
date: 2018-12-20T13:44:55+10:00 date: 2018-12-20T13:44:55+10:00
draft: false draft: false
image: 'images/team/michael-dam-258165-unsplash.jpg' image: "images/team/michael-dam-258165-unsplash.jpg"
image_width: 60 jobtitle: "UI Designer"
image_height: 60
jobtitle: 'UI Designer'
weight: 4 weight: 4
--- ---

View File

@ -55,7 +55,7 @@ $sub-footer-text-color: $white;
@import "components/strip"; @import "components/strip";
@import "components/feature"; @import "components/feature";
@import "components/social"; @import "components/social";
@import "components/fonts"; // @import "components/fonts"; // Uncomment this line to self host font
// Pages // Pages
@import "pages/page-home"; @import "pages/page-home";