"animation" for contrast change
Peter Molnar hello@petermolnar.eu
Sun, 17 Jun 2018 20:24:35 +0000
3 files changed,
9 insertions(+),
12 deletions(-)
M
templates/block_header_close.html
→
templates/block_header_close.html
@@ -6,9 +6,8 @@ {% include 'style-light.css' %}
</style> <script> function toggleStylesheet(trigger){ - var curr = document.querySelector('#light').getAttribute("media"); var setto = 'all'; - if (curr == 'all') { + if (document.querySelector('#light').getAttribute("media") == 'all') { setto = 'none'; } document.querySelector('#light').setAttribute("media", setto);
M
templates/style-dark.css
→
templates/style-dark.css
@@ -271,6 +271,10 @@ margin: 0;
padding: 0; } +.contrast.active { + transform: rotate(180deg); +} + .contrast a { color: #ccc; }@@ -409,7 +413,6 @@ .content-footer dd {
margin-right: 1em; } - .content-footer img { width: 1em; }@@ -433,23 +436,15 @@ list-style-type: none;
margin: 0; } -/* -.h-feed .h-entry { - margin-left: 1em; -} -*/ - .h-feed h2, .h-entry.singular .e-content h2 { border-bottom: 2px solid #999; } - .h-feed h3, .h-entry.singular .e-content h3 { border-bottom: 1px dotted #777; } - .h-feed > h1 { display: none;@@ -485,7 +480,6 @@
.follow { display: block; text-align: right; - } .donation ul {
M
templates/style-light.css
→
templates/style-light.css
@@ -39,3 +39,7 @@
.h-entry.singular h1 a { color: #111; } + +.contrast svg { + transform: rotate(180deg); +}