forked from WeLoveSpeed/welovespeed.com
-
Notifications
You must be signed in to change notification settings - Fork 1
/
head.html
58 lines (56 loc) · 4.14 KB
/
head.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
<!doctype html>
<html lang="{{ lang }}" dir="ltr">
{% comment %} Social Image computation {% endcomment %}
{% if page.i18n-key=="home" %}
{% capture socialTitle %}{{ site.seo_title }} - {{ site.description }}{% endcapture %}
{% capture socialImage %}https://res.cloudinary.com/we-love-speed/image/fetch/c_limit,f_auto,q_auto,w_960/https://welovespeed.netlify.com/assets/images/social-{{ page.locale | slice: 0,2 }}.png{% endcapture %}
{% else %}
{% capture socialTitle %}{{ page.seo_title | default: page.title }} - {{ site.seo_title }}{% endcapture %}
{% assign imgtitle = page.title | url_escape | replace: ' ', '%20' | replace: '.', '%2e' | replace: ',', '%252C' | replace: "'", '%E2%80%99' | replace: '?', '%3F'%}
{% capture socialImage %}{{ site.cloudinary.origin_url}}/assets/images/social-bg-bx.jpg{% endcapture %}
{% capture socialImage %}https://res.cloudinary.com/{{ site.cloudinary.cloud_name }}/image/fetch/e_blur:200,c_crop,ar_1200:600,b_white/e_grayscale/w_1200/b_rgb:{{ site.main_color }},o_40/w_1000,c_fit,l_text:Rubik_80:{{ imgtitle }},x_2,y_-98,co_black,o_80/w_1000,c_fit,l_text:Rubik_80:{{ imgtitle }},y_-100,co_white/c_fill,y_150,h_200,w_200,l_ws-square,r_max,bo_5px_solid_red/{{ socialImage }}{% endcapture %}
{% endif %}
{% comment %} End Social Image computation {% endcomment %}
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="robots" content="{{ page.robots |default: site.robots }}">
<title>{{ socialTitle }}</title>
<meta name="description" content="{{ page.description }}">
<link rel="apple-touch-icon" sizes="180x180" href="/assets/favicons/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/assets/favicons/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16" href="/assets/favicons/favicon-16x16.png">
<link rel="manifest" href="/manifest.json">
<link rel="mask-icon" href="/assets/favicons/safari-pinned-tab.svg" color="#cd2f2b">
<link rel="shortcut icon" href="/assets/favicons/favicon.ico">
<meta name="msapplication-TileColor" content="#ffffff">
<meta name="msapplication-config" content="/assets/favicons/browserconfig.xml">
<meta name="theme-color" content="#{{ site.main_color }}">
<link rel="author" href="{{ site.baseurl }}/humans.txt">
<meta property="og:url" content="{{ page.url | absolute_url }}">
<meta property="og:type" content="website">
<meta property="og:title" content="{{ socialTitle }}">
<meta property="og:image" content="{{ socialImage }}" />
<meta property="og:image:width" content="1200" />
<meta property="og:image:height" content="630" />
<meta property="og:site_name" content="{{ site.seo_title }}" />
<meta property="article:author" content="{{ site.seo_title }}" />
<meta property="article:published_time" content="{{ page.date | date: "%Y-%m-%d" }}" />
<meta name="twitter:card" content="summary_large_image" />
<meta name="twitter:domain" content="{{ site.domain }}" />
<meta name="twitter:title" content="{{ socialTitle }}" />
<meta name="twitter:description" content="{{ page.description }}" />
<meta name="twitter:image" content="{{ socialImage }}">
<meta name="twitter:creator" content="{{ site.social.twitter }}" />
<meta name="twitter:site" content="{{ site.seo_title }}" />
<meta name="twitter:widgets:link-color" content="#{{ site.main_color }}">
<meta name="twitter:widgets:border-color" content="#{{ site.main_color }}">
<meta name="twitter:dnt" content="on">
<meta name="twitter:widgets:csp" content="on">
{% if page.translation %}
{% assign lang = page.translation.locale | slice: 0,2 %}
<link rel="alternate" hreflang="{{ lang }}" href="{{ page.translation.url | relative_url }}"/>
{% endif %}
{% capture css_url %}/assets/css/main.css?{{ site.time|date: "%Y%m%d%H%M%S" }}{% endcapture %}
<link rel="stylesheet" href="{{ css_url | relative_url }}">
</head>