The Twig |e('css') filter was escaping '#' (0x23) to '\23 ' in hex
color values (bg_color, fg_color, error_color), causing browsers to
not recognize them as valid CSS colors. These are admin-configured
environment variables, not user input, so CSS escaping is unnecessary.
18 lines
959 B
Twig
18 lines
959 B
Twig
<style id="preauth-style">
|
|
* { margin: 0; padding: 0.25em; }
|
|
html { background-color: {{ env.bg_color }}; color: {{ env.fg_color }}; display: table;
|
|
font-family: sans-serif; font-size: 1.5em; height: 100%; padding: 0; width: 100%; }
|
|
body { display: table-cell; vertical-align: middle; }
|
|
h1 { font-size: 2.5em; font-weight: normal; text-align: center; }
|
|
p { color: {{ env.error_color }}; text-align: center; }
|
|
form { align-items: baseline; display: flex; flex-wrap: wrap; justify-content: center; }
|
|
form div { width: 45%; min-width: 300px; }
|
|
div.right { text-align: right; margin-top: 1em; padding-bottom: 0 }
|
|
div.center { text-align: center; }
|
|
div.hidden { display: none; }
|
|
span { cursor: pointer; font-size: 0.75em; text-decoration: underline; }
|
|
button { background-color: #cccccc; }
|
|
input { background-color: #ffffff; max-width: 100%; }
|
|
button, input { border: 0.0625em solid #333333; border-radius: 0.25em; color: #333333; font-size: 0.9em; }
|
|
</style>
|