1
0
Fork 0
mirror of https://github.com/muerwre/vault-frontend.git synced 2025-04-26 21:36:40 +07:00

added dynamic routes

This commit is contained in:
Fedor Katurov 2022-07-17 12:36:09 +07:00
parent 8c17c02b3e
commit 0a1d2cbf99
16 changed files with 143 additions and 89 deletions

View file

@ -21,7 +21,7 @@ import { useUpdates } from '~/hooks/updates/useUpdates';
import styles from './styles.module.scss';
type HeaderProps = {};
export interface HeaderProps {}
const Header: FC<HeaderProps> = observer(() => {
const labStats = useGetLabStats();

View file

@ -0,0 +1,12 @@
import dynamic from 'next/dynamic';
import type { HeaderProps } from '~/containers/main/Header/index';
import styles from './styles.module.scss';
export const HeaderSSR = dynamic<HeaderProps>(() => import('./index').then(it => it.Header), {
ssr: false,
loading: () => <div className={styles.wrap} />,
});
export const HeaderSSRPlaceholder = () => <div className={styles.wrap} />;

View file

@ -1,5 +1,16 @@
@import "../../../styles/variables";
@keyframes appear {
from {
opacity: 0;
transform: translate(0, -$header_height);
}
to {
opacity: 1;
transform: translate(0, 0);
}
}
.wrap {
height: $header_height;
z-index: 25;
@ -10,7 +21,8 @@
align-items: stretch;
justify-content: center;
box-sizing: border-box;
transition: background-color 0.5s;
transition: background-color 0.75s;
animation: appear 500ms forwards;
@include desktop {
height: 64px;