From c83ac61e1d183a962311efa5d76498249084c6b5 Mon Sep 17 00:00:00 2001 From: Goffi Date: Mon, 25 Mar 2019 18:40:11 +0100 Subject: [PATCH] tools (common/template): always use highlight.css if present. --- sat/tools/common/template.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sat/tools/common/template.py b/sat/tools/common/template.py index d1abd0bd..4d66a115 100644 --- a/sat/tools/common/template.py +++ b/sat/tools/common/template.py @@ -560,7 +560,8 @@ class Renderer(object): For each element of the path, a .css file is looked for in /static, and returned if it exists. Previous element are kept by replacing '/' with '_'. - styles_extra.css, styles.css and fonts.css are always used if they exist. + styles_extra.css, styles.css, highlight.css and fonts.css are always used if they + exist. For each found file, if a file with the same name and "_noscript" suffix exists, it will be return is second part of resulting tuple. For instance, if template_data is (some_site, some_theme, blog/articles.html), @@ -589,7 +590,7 @@ class Renderer(object): if css_path is not None: css_files.append(self.getFrontURL(css_path)) - for name_root in (u'styles', u'styles_extra'): + for name_root in (u'styles', u'styles_extra', u'highlight'): self._appendCSSPaths(template_data, css_files, css_files_noscript, name_root) for idx in xrange(len(path_elems)):