Skip to content

Commit df2eebf

Browse files
authored
fix(background-image): should be compatible to Rspress V2 (#55)
1 parent 4df5acc commit df2eebf

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/background-image/index.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,9 +47,8 @@ export const BackgroundImage: FC<BackgroundProps> = ({
4747
<>
4848
{/* For transparent navbar, overrides css only in homepage, and unmounted in other pages */}
4949
<style>
50-
{
51-
':root {--rp-c-bg: #0b0c0e;}:root:not(.dark) {--rp-c-bg: #fff;}.rspress-nav {transition: background 0.4s;}body:not(.notTopArrived) .rspress-nav {background: transparent !important;}'
52-
}
50+
{'body:not(.notTopArrived) .rp-nav {background: transparent !important; border-bottom: none !important;}' +
51+
'.rp-nav {background: color-mix(in srgb,var(--rp-c-bg) 60%,transparent);backdrop-filter: blur(25px);-webkit-backdrop-filter: blur(25px);}'}
5352
</style>
5453
<img
5554
className={styles.background}

0 commit comments

Comments
 (0)