From 13431dae529289e05517f7d3580e653554cebbf5 Mon Sep 17 00:00:00 2001 From: nanxiaobei Date: Tue, 24 Aug 2021 20:35:04 +0800 Subject: [PATCH] fix dark mode --- assets/app.css | 4 ++-- layouts/partials/header.html | 35 +++++++++++++---------------------- 2 files changed, 15 insertions(+), 24 deletions(-) diff --git a/assets/app.css b/assets/app.css index 308811c..2540cb3 100644 --- a/assets/app.css +++ b/assets/app.css @@ -202,7 +202,7 @@ img { white-space: nowrap; } -.btn-theme { +.btn-dark { width: 3rem; margin-left: 2rem; cursor: pointer; @@ -210,7 +210,7 @@ img { transition: background-position 0.4s steps(6); } -.dark .btn-theme { +.dark .btn-dark { background-position: right; } diff --git a/layouts/partials/header.html b/layouts/partials/header.html index be6b724..6c42ebf 100644 --- a/layouts/partials/header.html +++ b/layouts/partials/header.html @@ -1,39 +1,30 @@
{{ if .IsHome }}

- {{ site.Title }} + {{ site.Title }}

{{ else }} {{ end }} {{ $url := .RelPermalink }}