﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
34399	dark-mode-vars block is overwritten by extrastyles	Timothy Fiss	nobody	"When themeing the admin site the dark-mode-vars block is overwritten by the extrastyle block. making styling both impossible

example:

{{{
{% block extrastyle %}{{ block.super }}
<style>
    :root {
      --primary: red; /*will style primary red*/
    }
</style>
{% endblock %}

{% block dark-mode-vars %}{{ block.super }}
<style>
    :root {
      --body-bg: green; /*will remain styled red in dark mode.*/
    }
</style> 
{% endblock %}
}}}

Also annoyingly styles applied in the ""dark-mode-vars"" block will leak to lightmode if they are not protected with the media prefers-color-scheme query.

This can be worked around by encasing the extrastyle styles in the ""prefers-color-scheme: light"" query, but if this is going to remain the behaviour the documentation should be updated to reflect it."	Bug	closed	contrib.admin	4.1	Normal	invalid	dark-mode-vars	Sarah Boyce	Unreviewed	0	0	0	0	0	0
