diff --git a/layout/_layout.swig b/layout/_layout.swig index 4012cc9cc1..1198a2c4aa 100644 --- a/layout/_layout.swig +++ b/layout/_layout.swig @@ -94,31 +94,30 @@ {% endif %} - {{ partial('_scripts/vendors.swig', {}, {cache: theme.cache.enable}) }} - {{ partial('_scripts/commons.swig', {}, {cache: theme.cache.enable}) }} + {% include '_scripts/vendors.swig' %} + {% include '_scripts/commons.swig' %} {% set scheme_script = '_scripts/schemes/' + theme.scheme | lower + '.swig' %} - {{ partial(scheme_script, {}, {cache: theme.cache.enable}) }} + {% include scheme_script %} {% block script_extra %}{% endblock %} - {{ partial('_scripts/boostrap.swig', {}, {cache: theme.cache.enable}) }} - - {{ partial('_third-party/comments/index.swig', {}, {cache: theme.cache.enable}) }} - {{ partial('_third-party/search/index.swig', {}, {cache: theme.cache.enable}) }} - {{ partial('_third-party/analytics/lean-analytics.swig', {}, {cache: theme.cache.enable}) }} - {{ partial('_third-party/analytics/firestore.swig', {}, {cache: theme.cache.enable}) }} - {{ partial('_third-party/seo/baidu-push.swig', {}, {cache: theme.cache.enable}) }} - {{ partial('_third-party/schedule.swig', {}, {cache: theme.cache.enable}) }} - {{ partial('_third-party/math/index.swig', {}, {cache: theme.cache.enable}) }} - {{ partial('_third-party/needsharebutton.swig', {}, {cache: theme.cache.enable}) }} - {{ partial('_third-party/rating.swig', {}, {cache: theme.cache.enable}) }} - {{ partial('_third-party/pangu.swig', {}, {cache: theme.cache.enable}) }} - {{ partial('_third-party/scroll-cookie.swig', {}, {cache: theme.cache.enable}) }} - {{ partial('_third-party/exturl.swig', {}, {cache: theme.cache.enable}) }} - {{ partial('_third-party/bookmark.swig', {}, {cache: theme.cache.enable}) }} - {{ partial('_third-party/copy-code.swig', {}, {cache: theme.cache.enable}) }} - {{ partial('_third-party/pdf.swig', {}, {cache: theme.cache.enable}) }} - + {% include '_scripts/boostrap.swig' %} + + {% include '_third-party/comments/index.swig' %} + {% include '_third-party/search/index.swig' %} + {% include '_third-party/analytics/lean-analytics.swig' %} + {% include '_third-party/analytics/firestore.swig' %} + {% include '_third-party/seo/baidu-push.swig' %} + {% include '_third-party/schedule.swig' %} + {% include '_third-party/math/index.swig' %} + {% include '_third-party/needsharebutton.swig' %} + {% include '_third-party/rating.swig' %} + {% include '_third-party/pangu.swig' %} + {% include '_third-party/scroll-cookie.swig' %} + {% include '_third-party/exturl.swig' %} + {% include '_third-party/bookmark.swig' %} + {% include '_third-party/copy-code.swig' %} + {% include '_third-party/pdf.swig' %} diff --git a/layout/_partials/sidebar.swig b/layout/_macro/sidebar.swig similarity index 98% rename from layout/_partials/sidebar.swig rename to layout/_macro/sidebar.swig index a4bb9e9bd3..a83cd2f48f 100644 --- a/layout/_partials/sidebar.swig +++ b/layout/_macro/sidebar.swig @@ -1,3 +1,4 @@ +{% macro render(is_post) %}