diff --git a/src/components/Appbar/Appbar.tsx b/src/components/Appbar/Appbar.tsx index 50f6722..4edf435 100644 --- a/src/components/Appbar/Appbar.tsx +++ b/src/components/Appbar/Appbar.tsx @@ -12,9 +12,10 @@ import { useEffect, useState } from 'react' import { FaWallet } from 'react-icons/fa6' import { useWallet } from '@solana/wallet-adapter-react' import ProfileDropDown from '../common/ProfileDropDown' +import SkeletonHeader from './SkeletonHeader' const Appbar = () => { - const { data } = useSession() + const { data, status } = useSession() const router = useRouter() const [isMounted, setIsMounted] = useState(false) const { connected } = useWallet() @@ -42,6 +43,10 @@ const Appbar = () => { }, []); return ( +
+ {status == 'loading' ? + <> + :
@@ -141,6 +146,8 @@ const Appbar = () => {
+ } + ) } diff --git a/src/components/Appbar/SkeletonHeader.tsx b/src/components/Appbar/SkeletonHeader.tsx new file mode 100644 index 0000000..4421e5b --- /dev/null +++ b/src/components/Appbar/SkeletonHeader.tsx @@ -0,0 +1,31 @@ +import React from 'react' +import Skeleton from 'react-loading-skeleton' +import 'react-loading-skeleton/dist/skeleton.css' + +export default function SkeletonHeader() { + return ( +
+
+
+
+
+ +
+
+
+ +
+
+ +
+
+
+
+ ) +} \ No newline at end of file