{# -*- coding: utf-8 -*- #} {% import 'math_helper.tmpl' as math with context %} {% macro meta_translations(post) %} {% if translations|length > 1 %} {% for langname in translations|sort %} {% if langname != lang and ((not post.skip_untranslated) or post.is_translation_available(langname)) %} {% endif %} {% endfor %} {% endif %} {% endmacro %} {% macro html_tags(post) %} {% if post.tags %} {% endif %} {% endmacro %} {% macro html_pager(post) %} {% if post.prev_post or post.next_post %} {% endif %} {% endmacro %} {% macro open_graph_metadata(post) %} {% if post.description() %} {% else %} {% endif %} {% if post.previewimage %} {% endif %} {# Will only work with Pintrest and breaks everywhere else who expect a [Facebook] URI. #} {# %if post.author(): #} {# #} {# %endif #} {% if post.date.isoformat() %} {% endif %} {% if post.tags %} {% for tag in post.tags %} {% endfor %} {% endif %} {% endmacro %} {% macro twitter_card_information(post) %} {% if twitter_card and twitter_card['use_twitter_cards'] %} {% if 'site:id' in twitter_card %} {% elif 'site' in twitter_card %} {% endif %} {% if 'creator:id' in twitter_card %} {% elif 'creator' in twitter_card %} {% endif %} {% endif %} {% endmacro %} {# This function is deprecated; use math_helper directly. #} {% macro mathjax_script(post) %} {{ math.math_scripts_ifpost(post) }} {% endmacro %}