fix: back button position

This commit is contained in:
radishzzz 2025-05-26 12:36:16 +01:00
parent f54cacfedc
commit 7c12dbd301
2 changed files with 14 additions and 12 deletions

View file

@ -5,7 +5,7 @@ import GoBackIcon from '@/assets/icons/go-back.svg';
<button <button
id="back-button" id="back-button"
class="hidden" class="hidden"
lg="fixed left-[max(2.5rem,calc(50vw-37.5rem))] top-24 block aspect-square w-4.5 c-secondary/40 transition-colors ease-out hover:c-secondary/80 active:scale-90!" lg="absolute left--10 top-3.8 block aspect-square w-4.5 c-secondary/40 transition-colors ease-out hover:c-secondary/80 active:scale-90!"
aria-label="Go back" aria-label="Go back"
> >
<GoBackIcon <GoBackIcon

View file

@ -107,17 +107,19 @@ const { Content, headings, remarkPluginFrontmatter } = await render(post)
supportedLangs={supportedLangs} supportedLangs={supportedLangs}
> >
<article class="heti mb-12.6"> <article class="heti mb-12.6">
<!-- Go Back Button On Desktop --> <div class="relative">
<BackButton /> <!-- Go Back Button On Desktop -->
<!-- Title --> <BackButton />
<h1 class="post-title"> <!-- Title -->
<span <h1 class="post-title">
transition:name={`post-${post.data.abbrlink || post.id}-${lang}`} <span
data-disable-theme-transition transition:name={`post-${post.data.abbrlink || post.id}-${lang}`}
> data-disable-theme-transition
{post.data.title} >
</span> {post.data.title}
</h1> </span>
</h1>
</div>
<!-- Date --> <!-- Date -->
<div <div