mirror of
https://github.com/readthedocs/sphinx_rtd_theme.git
synced 2026-10-13 09:52:01 -05:00
Fix #1522: fix attribute error if css is str
This commit is contained in:
1 file changed
+10
-2
@@ -29,11 +29,19 @@
|
||||
<link rel="stylesheet" href="{{ pathto('_static/pygments.css', 1) }}" type="text/css" />
|
||||
{%- endif %}
|
||||
{%- for css in css_files %}
|
||||
{{ css_tag(css) }}
|
||||
{% if css|attr("filename") -%}
|
||||
{{ css_tag(css) }}
|
||||
{%- else -%}
|
||||
<link rel="stylesheet" href="{{ pathto(css, 1)|escape }}" type="text/css" />
|
||||
{%- endif %}
|
||||
{%- endfor %}
|
||||
|
||||
{%- for cssfile in extra_css_files %}
|
||||
{{ css_tag(cssfile) }}
|
||||
{% if css|attr("filename") -%}
|
||||
{{ css_tag(css) }}
|
||||
{%- else -%}
|
||||
<link rel="stylesheet" href="{{ pathto(css, 1)|escape }}" type="text/css" />
|
||||
{%- endif %}
|
||||
{%- endfor -%}
|
||||
|
||||
{#- FAVICON
|
||||
|
||||
Reference in new issue
Block a user