Unify Twitter cards and Open Graph data

This commit is contained in:
2017-02-06 14:37:53 +01:00
parent 10df0af355
commit 528887b1a6
10 changed files with 65 additions and 99 deletions

View File

@@ -5,20 +5,13 @@
meta(property="og:type", content="website")
| {% if og_picture %}
meta(property="og:image", content="{{ og_picture.thumbnail('l', api=api) }}")
| {% endif %}
| {% if project %}
meta(property="og:title", content="{{project.name}} - Blender Cloud")
meta(property="og:url", content="{{url_for('projects.view', project_url=project.url, _external=True)}}")
meta(property="og:description", content="{{project.summary}}")
| {% endif %}
| {% endblock %}
| {% block tw %}
| {% if og_picture %}
meta(property="twitter:image", content="{{ og_picture.thumbnail('l', api=api) }}")
| {% endif %}
| {% if project %}
meta(property="og:title", content="{{project.name}} - Blender Cloud")
meta(name="twitter:title", content="{{project.name}} on Blender Cloud")
meta(property="og:url", content="{{url_for('projects.view', project_url=project.url, _external=True)}}")
meta(property="og:description", content="{{project.summary}}")
meta(name="twitter:description", content="{{project.summary}}")
| {% endif %}
| {% endblock %}