lissarchive-website/themes/custom/templates/index_helper.tmpl

41 lines
1.4 KiB
Cheetah

## -*- coding: utf-8 -*-
<%def name="html_pager()">
%if prevlink or nextlink:
<nav class="postindexpager">
<ul class="pager">
%if prevlink:
<li class="previous">
<a href="${prevlink}" rel="prev">${messages("Newer posts")}</a>
</li>
%endif
%if nextlink:
<li class="next">
<a href="${nextlink}" rel="next">${messages("Older posts")}</a>
</li>
%endif
</ul>
</nav>
%endif
</%def>
<%def name="mathjax_script(posts)">
%if any(post.is_mathjax for post in posts):
%if use_katex:
<script src="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.5.1/katex.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.5.1/contrib/auto-render.min.js"></script>
<script>
renderMathInElement(document.body);
</script>
%else:
<script type="text/javascript" src="https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML"> </script>
% if mathjax_config:
${mathjax_config}
% else:
<script type="text/x-mathjax-config">
MathJax.Hub.Config({tex2jax: {inlineMath: [['$latex ','$'], ['\\(','\\)']]}});
</script>
% endif
%endif
%endif
</%def>