mirror of
https://github.com/sbrl/Pepperminty-Wiki.git
synced 2024-11-21 16:13:00 +00:00
Don't emit custom css unless there's something to emit
This commit is contained in:
parent
dfca17d1cf
commit
0085ddf0c4
2 changed files with 9 additions and 3 deletions
|
@ -4,6 +4,10 @@ This file holds the changelog for Pepperminty Wiki. This is the master list of t
|
|||
|
||||
## v0.22-dev (unreleased)
|
||||
|
||||
### Changed
|
||||
- Don't emit custom CSS unless there's something to emit
|
||||
|
||||
|
||||
### Fixed
|
||||
- Fixed `inbody:searchterm` advanced query syntax
|
||||
- Fixed inaccessible colours in the page list when using the dark theme
|
||||
|
|
|
@ -335,9 +335,11 @@ class page_renderer
|
|||
self::add_server_push_indicator("style", $settings->css);
|
||||
$result .= "<link rel='stylesheet' href='$settings->css_custom' />\n";
|
||||
}
|
||||
$css .= "\n/*** Custom CSS ***/\n";
|
||||
$css .= !empty($settings->optimize_pages) ? minify_css($settings->css_custom) : $settings->css_custom;
|
||||
$css .= "\n/******************/";
|
||||
if(!empty(trim($settings->css_custom))) {
|
||||
$css .= "\n/*** Custom CSS ***/\n";
|
||||
$css .= !empty($settings->optimize_pages) ? minify_css($settings->css_custom) : $settings->css_custom;
|
||||
$css .= "\n/******************/";
|
||||
}
|
||||
}
|
||||
$result .= "<style>\n$css\n</style>\n";
|
||||
|
||||
|
|
Loading…
Reference in a new issue