From 214a48a2d9bb0f86740f805459e0fdeea289b150 Mon Sep 17 00:00:00 2001 From: Pratik Date: Tue, 28 Jan 2025 12:16:15 +0530 Subject: [PATCH] perf: toggle dark mode before content loads --- .../doctype/wiki_page/templates/base.html | 66 ++++++++++++------- 1 file changed, 44 insertions(+), 22 deletions(-) diff --git a/wiki/wiki/doctype/wiki_page/templates/base.html b/wiki/wiki/doctype/wiki_page/templates/base.html index d53c4617..79c7e297 100644 --- a/wiki/wiki/doctype/wiki_page/templates/base.html +++ b/wiki/wiki/doctype/wiki_page/templates/base.html @@ -1,45 +1,50 @@ + {% block meta_block %} - {% include "templates/includes/meta_block.html" %} + {% include "templates/includes/meta_block.html" %} {% endblock %} {% block title %}{{ title | striptags }}{% endblock %} {% block favicon %} - + {% endblock %} {%- block head -%} - {% include "templates/includes/head.html" %} + {% include "templates/includes/head.html" %} {%- endblock -%} {%- block head_include %} - {{ head_include or "" }} + {{ head_include or "" }} {% endblock -%} {%- block style %} - {% if colocated_css -%} - - {%- endif %} + {% if colocated_css -%} + + {%- endif %} {%- endblock -%} + - + + + + {% include "public/icons/timeless/icons.svg" %} {%- block banner -%} - {% include "templates/includes/banner_extension.html" ignore missing %} + {% include "templates/includes/banner_extension.html" ignore missing %} - {% if banner_html -%} - {{ banner_html or "" }} - {%- endif %} + {% if banner_html -%} + {{ banner_html or "" }} + {%- endif %} {%- endblock -%} {% block content %} - {{ content }} + {{ content }} {% endblock %} {% block base_scripts %} @@ -76,11 +97,12 @@ {%- endfor -%} {%- block script %} - {% if colocated_js -%} - - {%- endif %} + {% if colocated_js -%} + + {%- endif %} {%- endblock %} {%- block body_include %}{{ body_include or "" }}{% endblock -%} - + + \ No newline at end of file