diff --git a/astro.config.ts b/astro.config.ts
index 5e0ac715..b51dd4b5 100644
--- a/astro.config.ts
+++ b/astro.config.ts
@@ -10,7 +10,7 @@ import type { CSSOptions } from 'vite'
import defaultGenerateScopedName from 'postcss-modules/build/generateScopedName'
import { isDev } from './src/utils/config'
-const PATH_PREFIX = '/src/components/'
+const PATH_PREFIX = '/src/'
const getDevCssClassPrefix = (filename: string): string => {
return filename
diff --git a/src/components/Layouts/MainLayout.tsx b/src/components/Layouts/MainLayout.tsx
index 4a0e8c49..355e5a19 100644
--- a/src/components/Layouts/MainLayout.tsx
+++ b/src/components/Layouts/MainLayout.tsx
@@ -7,12 +7,15 @@ import '../../styles/app.scss'
type Props = {
headerTitle?: string
children: JSX.Element
+ isHeaderFixed?: boolean
}
export const MainLayout = (props: Props) => {
+ const isHeaderFixed = props.isHeaderFixed !== undefined ? props.isHeaderFixed : true
+
return (
<>
-
+
{props.children}
>
diff --git a/src/components/Nav/Header.scss b/src/components/Nav/Header.scss
index 18c9d962..b4c922a6 100644
--- a/src/components/Nav/Header.scss
+++ b/src/components/Nav/Header.scss
@@ -1,8 +1,6 @@
header {
background: #fff;
margin-bottom: 2.2rem;
- position: fixed;
- top: 0;
width: 100%;
z-index: 10;
@@ -15,8 +13,10 @@ header {
}
}
-.header--scrolled-bottom,
-.header--scrolled-top {
+.header--fixed {
+ position: fixed;
+ top: 0;
+
.main-logo {
height: 56px;
diff --git a/src/components/Nav/Header.tsx b/src/components/Nav/Header.tsx
index aa8d80db..2e4728f5 100644
--- a/src/components/Nav/Header.tsx
+++ b/src/components/Nav/Header.tsx
@@ -1,4 +1,4 @@
-import { For, Show, createSignal, createMemo, createEffect, onMount, onCleanup, Suspense } from 'solid-js'
+import { For, Show, createSignal, createMemo, createEffect, onMount, onCleanup } from 'solid-js'
import Private from './Private'
import Notifications from './Notifications'
import { Icon } from './Icon'
@@ -27,6 +27,7 @@ const handleEnterClick = () => {
type Props = {
title?: string
+ isHeaderFixed?: boolean
}
export const Header = (props: Props) => {
@@ -82,82 +83,82 @@ export const Header = (props: Props) => {
})
return (
-
-