Add config.extra.debug_no_styles for debugging

This commit is contained in:
daudix
2024-10-24 13:21:14 +03:00
parent 694479bcdb
commit 35382b15b5
3 changed files with 14 additions and 9 deletions

View File

@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Added ### Added
- Add `classic-article-list` mod for returning the classic article list style. - Add `classic-article-list` mod for returning the classic article list style.
- Add `config.extra.debug_no_styles` config variable for debugging.
- Add `config.extra.show_backlinks` config variable for showing the backlinks button for linked articles in the article's quick actions. - Add `config.extra.show_backlinks` config variable for showing the backlinks button for linked articles in the article's quick actions.
- Add `fediverse:creator` meta tag. - Add `fediverse:creator` meta tag.
- Add `title` class for use on `<strong>`. - Add `title` class for use on `<strong>`.

View File

@ -175,6 +175,8 @@ csp = [
] ]
# Display outlines around all elements for debugging purposes # Display outlines around all elements for debugging purposes
# debug_layout = true # debug_layout = true
# Don't load any styles for debugging purposes
# debug_no_styles = true
[extra.nav] [extra.nav]
# Whether to show the Atom/RSS feed button in the nav # Whether to show the Atom/RSS feed button in the nav

View File

@ -54,16 +54,18 @@
{%- set styles = styles | concat(with=section.extra.styles) %} {%- set styles = styles | concat(with=section.extra.styles) %}
{%- endif %} {%- endif %}
{%- for style in styles %} {%- if not config.extra.debug_no_styles %}
<link type="text/css" rel="stylesheet" href="{{ get_url(path=style) | safe }}" /> {%- for style in styles %}
{%- endfor %} <link type="text/css" rel="stylesheet" href="{{ get_url(path=style) | safe }}" />
{%- endfor %}
{%- if config.markdown.highlight_code and config.markdown.highlight_theme == "css" %} {%- if config.markdown.highlight_code and config.markdown.highlight_theme == "css" %}
{%- if config.markdown.highlight_themes_css | length > 0 %} {%- if config.markdown.highlight_themes_css | length > 0 %}
<link type="text/css" rel="stylesheet" href="{{ get_url(path='syntax-theme-light.css') }}" media="(prefers-color-scheme: light)" /> <link type="text/css" rel="stylesheet" href="{{ get_url(path='syntax-theme-light.css') }}" media="(prefers-color-scheme: light)" />
<link type="text/css" rel="stylesheet" href="{{ get_url(path='syntax-theme-dark.css') }}" media="(prefers-color-scheme: dark)" /> <link type="text/css" rel="stylesheet" href="{{ get_url(path='syntax-theme-dark.css') }}" media="(prefers-color-scheme: dark)" />
{%- else %} {%- else %}
<link type="text/css" rel="stylesheet" href="{{ get_url(path='syntax-theme.css') }}" /> <link type="text/css" rel="stylesheet" href="{{ get_url(path='syntax-theme.css') }}" />
{%- endif %}
{%- endif %} {%- endif %}
{%- endif %} {%- endif %}