Improve readability of _opengraph macro
This commit is contained in:
@@ -1,8 +1,8 @@
|
|||||||
//- Opengraph/Twitter cards for social media.
|
//- Opengraph/Twitter cards for social media.
|
||||||
|
|
||||||
| {% macro opengraph(title, description, image, url) %}
|
| {% macro opengraph(title, description, url_image, url_page) %}
|
||||||
meta(property="og:type", content="website")
|
meta(property="og:type", content="website")
|
||||||
meta(property="og:url", content="{{ url }}")
|
meta(property="og:url", content="{{ url_page }}")
|
||||||
|
|
||||||
meta(property="og:title", content="{{ title }} on Blender Cloud")
|
meta(property="og:title", content="{{ title }} on Blender Cloud")
|
||||||
meta(name="twitter:title", content="{{ title }} on Blender Cloud")
|
meta(name="twitter:title", content="{{ title }} on Blender Cloud")
|
||||||
@@ -10,6 +10,8 @@ meta(name="twitter:title", content="{{ title }} on Blender Cloud")
|
|||||||
meta(property="og:description", content="{{ description }}")
|
meta(property="og:description", content="{{ description }}")
|
||||||
meta(name="twitter:description", content="{{ description }}")
|
meta(name="twitter:description", content="{{ description }}")
|
||||||
|
|
||||||
meta(property="og:image", content="{{ image }}")
|
| {% if url_image %}
|
||||||
meta(name="twitter:image", content="{{ image }}")
|
meta(property="og:image", content="{{ url_image }}")
|
||||||
|
meta(name="twitter:image", content="{{ url_image }}")
|
||||||
|
| {% endif %}
|
||||||
| {% endmacro %}
|
| {% endmacro %}
|
||||||
|
Reference in New Issue
Block a user