Skip to content

Commit

Permalink
Add features to distill template (#2840)
Browse files Browse the repository at this point in the history
While using the distill template, I noticed it lacked many features
available in the regular post template, such as typograms, echarts, and
other interactive elements. To address this, I **included the necessary
scripts and dependencies for these features in** _distill.liquid_,
referencing them from misc.liquid. Now, the distill template offers the
same interactive functionality as the post template.
  • Loading branch information
ShuhongDai authored Dec 4, 2024
1 parent a340b60 commit 957dc2c
Show file tree
Hide file tree
Showing 2 changed files with 1,128 additions and 0 deletions.
13 changes: 13 additions & 0 deletions _layouts/distill.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,19 @@
{% endif %}
{% include scripts/jquery.liquid %}
{% include scripts/mathjax.liquid %}
{% include scripts/mermaid.liquid %}
{% include scripts/diff2html.liquid %}
{% include scripts/leaflet.liquid %}
{% include scripts/chartjs.liquid %}
{% include scripts/echarts.liquid %}
{% include scripts/vega.liquid %}
{% include scripts/tikzjax.liquid %}
{% include scripts/typograms.liquid %}
{% include scripts/misc.liquid %}
{% comment %}
misc.liquid loads interactive features like the code copy button to prevent dynamic elements from displaying incorrectly at the end of the article.
{% endcomment %}

<!-- Distill js -->
<script src="{{ '/assets/js/distillpub/template.v2.js' | relative_url }}"></script>
<script src="{{ '/assets/js/distillpub/transforms.v2.js' | relative_url }}"></script>
Expand Down
Loading

0 comments on commit 957dc2c

Please sign in to comment.