Commit f42fd8e1 authored by Martijn Braam's avatar Martijn Braam

Dark mode fixup

parent 9e02fd13
......@@ -28,12 +28,4 @@ def wiki_redirect():
if __name__ == '__main__':
import argparse
parser = argparse.ArgumentParser()
parser.add_argument('--dark', help='Render dark version of the website', action='store_true')
args = parser.parse_args()
if args.dark:
app.config['DARK'] = True
app.config['FREEZER_BASE_URL'] = 'https://nm.postmarketos.org/'
freezer.freeze()
html body {
background: #232729;
}
@media (prefers-color-scheme: dark) {
html body {
background: #232729;
}
html .header {
background-image: url(/static/img/nexus5-bg-dark.jpg);
border-left: 1px solid #0b0c0c;
border-right: 1px solid #0b0c0c;
border-bottom: 1px solid #0b0c0c;
}
html .header {
background-image: url(/static/img/nexus5-bg-dark.jpg);
border-left: 1px solid #0b0c0c;
border-right: 1px solid #0b0c0c;
border-bottom: 1px solid #0b0c0c;
}
html main {
background: #2c3133;
color: #ccc;
border-left: 1px solid #0b0c0c;
border-right: 1px solid #0b0c0c;
}
html main {
background: #2c3133;
color: #ccc;
border-left: 1px solid #0b0c0c;
border-right: 1px solid #0b0c0c;
}
html .content.alt {
background: #33393b;
}
html .content.alt {
background: #33393b;
}
html a {
color: #ccc;
}
html a {
color: #ccc;
}
html .nav a {
background: #000;
}
html .nav a {
background: #000;
}
html .icon-button {
background: #000;
}
html .icon-button {
background: #000;
}
html .icon-button img {
filter: brightness(999%) brightness(80%);
}
html .icon-button img {
filter: brightness(999%) brightness(80%);
}
html .devices div {
border: 1px solid #0b0c0c;
background: #2c3133;
}
html .devices div {
border: 1px solid #0b0c0c;
background: #2c3133;
}
html .devices img {
border: 1px solid #0b0c0c;
opacity: 0.8;
}
html .devices img {
border: 1px solid #0b0c0c;
opacity: 0.8;
}
html .separator {
background-image: url(/static/img/nexus5-bg-bottom-dark.jpg);
border-top: 1px solid #0b0c0c;
border-bottom: 1px solid #0b0c0c;
}
html .separator {
background-image: url(/static/img/nexus5-bg-bottom-dark.jpg);
border-top: 1px solid #0b0c0c;
border-bottom: 1px solid #0b0c0c;
}
html footer {
background-image: url(/static/img/nexus5-bg-bottom-dark.jpg);
border-left: 1px solid #0b0c0c;
border-right: 1px solid #0b0c0c;
border-top: 1px solid #0b0c0c;
}
html footer {
background-image: url(/static/img/nexus5-bg-bottom-dark.jpg);
border-left: 1px solid #0b0c0c;
border-right: 1px solid #0b0c0c;
border-top: 1px solid #0b0c0c;
}
html img.border,
html .grid-bottom img,
html .grid-bottom video {
border: 1px solid #0b0c0c;
}
html img.border,
html .grid-bottom img,
html .grid-bottom video {
border: 1px solid #0b0c0c;
}
html .codehilite {
background: black;
border: 1px solid #0b0c0c;
}
\ No newline at end of file
html .codehilite {
background: black;
border: 1px solid #0b0c0c;
}
}
......@@ -15,16 +15,9 @@
<link rel="canonical" href="https://postmarketos.org{{ request.path }}">
<link rel="shortcut icon" href="/static/img/favicon.ico">
<link rel="stylesheet" href="/static/css/base.css">
{% if config.DARK %}
<link rel="stylesheet" href="/static/css/dark.css">
{% else %}
<link rel="stylesheet" href="/static/css/dark.css" media="prefers-color-scheme: dark">
{% endif %}
<link rel="stylesheet" href="/static/css/dark.css">
<link rel="stylesheet" href="/static/css/codehilite.css">
<link rel="alternate" type="application/atom+xml" title="postmarketOS Blog" href="{{ url_for('atom') }}">
{% if config.DARK %}
<link rel="canonical" href="https://postmarketos.org{{ request.path[5:] }}">
{% endif %}
{% block extra_link %}{% endblock %}
</head>
<body>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment