File tree Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Original file line number Diff line number Diff line change 31
31
{%- if pageurl %}
32
32
< link rel ="canonical " href ="{{ pageurl|e }} " />
33
33
{%- endif %}
34
+
35
+ {%- block logo_prefetch_links %}
36
+ {%- if logo_url %}
37
+ < link rel ="prefetch " href ="{{ logo_url }} " as ="image " />
38
+ {%- endif %}
39
+ {%- if theme_light_logo and theme_dark_logo %}
40
+ < link rel ="prefetch " href ="{{ pathto('_static/' + theme_light_logo, 1) }} " as ="image " />
41
+ < link rel ="prefetch " href ="{{ pathto('_static/' + theme_dark_logo, 1) }} " as ="image " />
42
+ {%- endif %}
43
+ {%- endblock logo_prefetch_links %}
34
44
{%- endblock linktags %}
35
45
36
46
{# Favicon #}
Original file line number Diff line number Diff line change 12
12
13
13
-#}
14
14
< a class ="sidebar-brand{% if logo %} centered{% endif %} " href ="{{ pathto(master_doc) }} ">
15
- {% block brand_content %}
15
+ {%- block brand_content %}
16
+ {#- Remember to update the prefetch logic in `block logo_prefetch_links` in base.html #}
16
17
{%- if logo_url %}
17
18
< div class ="sidebar-logo-container ">
18
19
< img class ="sidebar-logo " src ="{{ logo_url }} " alt ="Logo "/>
You can’t perform that action at this time.
0 commit comments