|
|
|
@ -4,7 +4,7 @@ import Link from 'next/link';
|
|
|
|
|
import { useRouter } from 'next/router';
|
|
|
|
|
import { useState } from 'react';
|
|
|
|
|
import { MapPinIcon } from '@heroicons/react/24/outline';
|
|
|
|
|
import { Banner } from '@tih/ui';
|
|
|
|
|
import { Banner, Spinner } from '@tih/ui';
|
|
|
|
|
|
|
|
|
|
import { useGoogleAnalytics } from '~/components/global/GoogleAnalytics';
|
|
|
|
|
import OffersTable from '~/components/offers/admin/OffersTable';
|
|
|
|
@ -52,8 +52,11 @@ export default function OffersHomePage({
|
|
|
|
|
if (!isLoading && !isAuthorized) {
|
|
|
|
|
router.push('/offers');
|
|
|
|
|
}
|
|
|
|
|
return (
|
|
|
|
|
isAuthorized && (
|
|
|
|
|
return isLoading ? (
|
|
|
|
|
<div className="flex justify-center py-32">
|
|
|
|
|
<Spinner display="block" size="lg" />
|
|
|
|
|
</div>
|
|
|
|
|
) : (
|
|
|
|
|
<>
|
|
|
|
|
<Head>
|
|
|
|
|
<title>Admin Home - Tech Offers Repo</title>
|
|
|
|
@ -173,6 +176,5 @@ export default function OffersHomePage({
|
|
|
|
|
</Container>
|
|
|
|
|
</main>
|
|
|
|
|
</>
|
|
|
|
|
)
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|