From: Danilo M. Date: Mon, 20 Apr 2026 20:13:10 +0000 (+0200) Subject: style: add .back-to-top component class X-Git-Tag: release_22042026-1342~57 X-Git-Url: https://git.danix.xyz/?a=commitdiff_plain;h=2a8a7af673ddb83b3255770cdb886c791436ec89;p=danix.xyz-2.git style: add .back-to-top component class --- diff --git a/themes/danix-xyz-hacker/assets/css/main.css b/themes/danix-xyz-hacker/assets/css/main.css index 8229271..4219327 100644 --- a/themes/danix-xyz-hacker/assets/css/main.css +++ b/themes/danix-xyz-hacker/assets/css/main.css @@ -611,6 +611,23 @@ html.theme-light picture img[src="/images/default_thumbnail_dark.png"] { background: rgba(0, 255, 136, 0.1); color: var(--accent2); } + + /* Back to top button */ + .back-to-top { + @apply fixed bottom-6 right-6 z-40 w-11 h-11 rounded-full flex items-center justify-content-center; + background: var(--accent); + box-shadow: 0 0 12px rgba(168, 85, 247, 0.4); + transition: background 200ms ease, box-shadow 200ms ease; + color: #fff; + } + .back-to-top:hover { + background: #9333ea; + box-shadow: 0 0 20px var(--accent); + } + .back-to-top:focus-visible { + outline: 2px solid var(--accent); + outline-offset: 2px; + } } /* Prose overrides for light theme */ diff --git a/themes/danix-xyz-hacker/assets/css/main.min.css b/themes/danix-xyz-hacker/assets/css/main.min.css index fe44358..389a8b7 100644 --- a/themes/danix-xyz-hacker/assets/css/main.min.css +++ b/themes/danix-xyz-hacker/assets/css/main.min.css @@ -1733,6 +1733,8 @@ article.border.border-border\/30.rounded-lg.card.group.bg-bg { color: var(--accent2); } +/* Back to top button */ + .sr-only { position: absolute; width: 1px;