Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: includes/meta/social.tmpl

Issue 29469558: Issue 5329 - Optimize website-boilerplate for sharing on social media networks (Closed) Base URL: https://hg.adblockplus.org/website-defaults
Patch Set: Removed shortcut icon Created June 20, 2017, 2:42 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | includes/meta/standard.tmpl » ('j') | includes/meta/standard.tmpl » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 {#
2 # This file is part of the website-defaults,
3 # Copyright (C) 2017 eyeo GmbH
4 #
5 # website-defaults is free software: you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License version 3 as
7 # published by the Free Software Foundation.
8 #
9 # website-defaults is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 # GNU General Public License for more details.
13 #
14 # You should have received a copy of the GNU General Public License
15 # along with website-defaults. If not, see <http://www.gnu.org/licenses/>.
16 #
17 # ---
18 #
19 # # Essential meta data for sharing on social media
20 #
21 # og:site
22 # : A short name associated with the site (not page)
23 #
24 # twitter:site
25 # : A twitter username associated with the site (not page)
26 #
27 # og:title
28 # : A clear title without branding or mentioning the domain itself
29 #
30 # og:description
31 # : A clear description, at least two sentences long
32 #
33 # og:image
34 # : Featured image (at least 1200x630, up to 5MB)
juliandoucette 2017/06/20 14:57:54 Note: The dimensions come from facebook and the fi
35 #}
juliandoucette 2017/06/20 14:57:54 Looks like I'm missing og:type.
juliandoucette 2017/06/20 15:12:29 Done. Note: "website" is the default according to
36 {% if og_site_name %}
37 <meta property="og:site_name" content="{{ og_site_name }}">
38 {% endif %}
39 {% if twitter_site %}
juliandoucette 2017/06/20 14:57:54 Note: I'm saving twitter:creator for another inclu
40 <meta name="twitter:site" content="@{{ twitter_site }}">
41 {% endif %}
42 {% if og_title %}
juliandoucette 2017/06/20 14:57:53 Note: title and description are not redundant beca
43 <meta property="og:title" content="{{ og_title }}">
44 {% endif %}
45 {% if og_description %}
46 <meta property="og:descirption" content="{{ og_description }}">
47 {% endif %}
48 {% if og_image %}
49 <meta property="og:image" content="{{ og_image }}">
50 {% else if og_site_image %}
juliandoucette 2017/06/20 14:57:54 Note: This allows us to optionally configure a def
51 <meta property="og:image" content="{{ og_site_image }}">
52 {% endif %}
53 {% if twitter_card %}
juliandoucette 2017/06/20 14:57:53 Note: I thought these defaults made sense.
54 <meta name="twitter:card" content="{{ twitter_card }}">
55 {% else if og_image or og_site_image %}
56 <meta name="twitter:card" content="summary_large_image">
57 {% else %}
58 <meta name="twitter:card" content="summary">
59 {% endif %}
60 {% if twitter_image_alt %}
juliandoucette 2017/06/20 14:57:53 Note: It's a shame that open graph doesn't support
61 <meta name="twitter:image:alt" content="{{ twitter_image_alt }}">
62 {% endif %}
63 {% if host and page %}
juliandoucette 2017/06/20 14:57:54 Note: We currently do not have a way to output the
64 <meta property="og:url" content="{{ host }}/{{ page }}">
65 {% endif %}
66 <meta property="og:locale" content="{{ locale }}">
67 {% for alternate_locale in locales %}
68 {% if alternate_locale != locale %}
69 <meta property="og:locale:alternate" content="{{ alternate_locale }}">
70 {% endif %}
71 {% endfor %}
OLDNEW
« no previous file with comments | « no previous file | includes/meta/standard.tmpl » ('j') | includes/meta/standard.tmpl » ('J')

Powered by Google App Engine
This is Rietveld