Skip to content

Commit

Permalink
fix: fix the flickering caused by custom scrollbar initialization (#60)
Browse files Browse the repository at this point in the history
  • Loading branch information
saicaca committed Sep 19, 2024
1 parent 93209a5 commit 8565724
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/layouts/Layout.astro
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,9 @@ const bannerOffset = bannerOffsetByPosition[siteConfig.banner.position || 'cente
---

<!DOCTYPE html>
<html lang={siteLang} class="bg-[var(--page-bg)] transition text-[14px] md:text-[16px]">
<html lang={siteLang} class="bg-[var(--page-bg)] transition text-[14px] md:text-[16px]"
data-overlayscrollbars-initialize
>
<head>

<title>{pageTitle}</title>
Expand Down Expand Up @@ -131,7 +133,9 @@ const bannerOffset = bannerOffsetByPosition[siteConfig.banner.position || 'cente
<style define:vars={{ configHue }}></style> <!-- defines global css variables. This will be applied to <html> <body> and some other elements idk why -->

</head>
<body class=" min-h-screen transition " class:list={[{"lg:is-home": isHomePage, "enable-banner": enableBanner}]}>
<body class=" min-h-screen transition " class:list={[{"lg:is-home": isHomePage, "enable-banner": enableBanner}]}
data-overlayscrollbars-initialize
>
<ConfigCarrier></ConfigCarrier>
<GlobalStyles>
{siteConfig.banner.enable && <div id="banner-wrapper" class="absolute -top-[30vh] w-full transition duration-700 overflow-hidden">
Expand Down

0 comments on commit 8565724

Please sign in to comment.