1
1
mirror of https://github.com/theoludwig/theoludwig.git synced 2024-07-12 21:40:12 +02:00

fix(blog): headings should be aligned with the text, not shifted

This commit is contained in:
Théo LUDWIG 2024-05-21 19:06:12 +02:00
parent 5f3dfad988
commit efa33f26ec
Signed by: theoludwig
GPG Key ID: ADFE5A563D718F3B

View File

@ -26,14 +26,14 @@ const Heading = (
): JSX.Element => {
const { children, id = "" } = props
return (
<h2 {...props} className="group">
<Link
href={`#${id}`}
className="invisible !text-black group-hover:visible dark:!text-white"
>
<FontAwesomeIcon className="mr-2 inline size-4" icon={faLink} />
<h2 {...props}>
<Link href={`#${id}`} className="group relative hover:no-underline">
<FontAwesomeIcon
className="absolute bottom-2 left-[-26px] mr-2 hidden size-4 !text-black group-hover:inline dark:!text-white"
icon={faLink}
/>
{children}
</Link>
{children}
</h2>
)
}