diff --git a/components/public/cards/logo/easyhq-w.svg b/components/public/cards/logo/easyhq-w.svg new file mode 100644 index 0000000..907d324 --- /dev/null +++ b/components/public/cards/logo/easyhq-w.svg @@ -0,0 +1,43 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/components/public/cards/logo/easyhq.svg b/components/public/cards/logo/easyhq.svg new file mode 100644 index 0000000..1589469 --- /dev/null +++ b/components/public/cards/logo/easyhq.svg @@ -0,0 +1,55 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/components/public/cards/logo/eoh.svg b/components/public/cards/logo/eoh.svg new file mode 100644 index 0000000..391ae5d --- /dev/null +++ b/components/public/cards/logo/eoh.svg @@ -0,0 +1,48 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/components/public/cards/logo/eohw.svg b/components/public/cards/logo/eohw.svg new file mode 100644 index 0000000..f5702b9 --- /dev/null +++ b/components/public/cards/logo/eohw.svg @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/components/public/cards/logo/iocow.svg b/components/public/cards/logo/iocow.svg new file mode 100644 index 0000000..84dee4d --- /dev/null +++ b/components/public/cards/logo/iocow.svg @@ -0,0 +1,75 @@ + + + + + + + + + + + + + + + + + + diff --git a/components/public/cards/logo/opco.svg b/components/public/cards/logo/opco.svg new file mode 100644 index 0000000..91a3b59 --- /dev/null +++ b/components/public/cards/logo/opco.svg @@ -0,0 +1,79 @@ + + + + + + + + + + + + + + + + + + + diff --git a/components/src/app/public/page.tsx b/components/src/app/public/page.tsx new file mode 100644 index 0000000..0b5f41b --- /dev/null +++ b/components/src/app/public/page.tsx @@ -0,0 +1,30 @@ +'use client' + +import { IUserSession } from "@/lib/types/UserSession" +import { useSearchParams } from "next/navigation" + +const PublicPage = () => { + const mode = useSearchParams().get('mode') + const session: IUserSession = { + user: { + name: 'test', + email: 'test@test.com', + image: 'https://avatars.githubusercontent.com/u/10192985?v=4', + id: '1' + }, + expires: '2024-09-26T12:00:00', + status: 'authenticated' + + } + return ( +
page +
+      {
+        JSON.stringify({ mode, session }, null, 2)
+      }
+    
+
+ ) +} + +export default PublicPage \ No newline at end of file diff --git a/components/src/components/CountDown/CountdownComponent.tsx b/components/src/components/CountDown/CountdownComponent.tsx index 6c43a4b..1884271 100644 --- a/components/src/components/CountDown/CountdownComponent.tsx +++ b/components/src/components/CountDown/CountdownComponent.tsx @@ -4,8 +4,8 @@ import React, { useState, useEffect } from 'react'; import { AnimatedBackground } from './AnimatedBackground'; import { Clock, Users, Rocket } from 'lucide-react'; import { RegisterAction } from './RegisterAction'; - -export const CountdownComponent: React.FC<{ targetDate: string,url:string }> = ({ targetDate,url='/api/auth/signup' }) => { +import { IUserSession } from '@/lib/types/UserSession'; +export const CountdownComponent: React.FC<{ targetDate: string, url: string, session?: IUserSession }> = ({ targetDate, url = '/api/auth/signup', session }) => { const [timeLeft, setTimeLeft] = useState<{ [key: string]: number }>({}); const [isClient, setIsClient] = useState(false); @@ -60,8 +60,9 @@ export const CountdownComponent: React.FC<{ targetDate: string,url:string }> = (

Register by 23 September 2024 to secure your spot!

-
- +
+ +
@@ -81,8 +82,8 @@ export const CountdownComponent: React.FC<{ targetDate: string,url:string }> = (
- - + +
); }; diff --git a/components/src/components/CountDown/RegisterAction.tsx b/components/src/components/CountDown/RegisterAction.tsx index 971e091..e9d9f89 100644 --- a/components/src/components/CountDown/RegisterAction.tsx +++ b/components/src/components/CountDown/RegisterAction.tsx @@ -1,11 +1,13 @@ +import { IUserSession } from '@/lib/types/UserSession' import Link from 'next/link' import React from 'react' -export const RegisterAction: React.FC<{url:string}> = ({url}) => { +export const RegisterAction: React.FC<{url:string, mode?: 'session'|'register', session?: IUserSession}> = ({url, mode="register", session}) => { + console.log(session) return (
- - Register Now + + {mode === 'register' ? 'Register Now' : 'Test run'}
) diff --git a/components/src/lib/types/UserSession.ts b/components/src/lib/types/UserSession.ts new file mode 100644 index 0000000..2a0f9a2 --- /dev/null +++ b/components/src/lib/types/UserSession.ts @@ -0,0 +1,11 @@ + +export declare interface IUserSession { + user: { + id: string; + name: string; + email: string; + image: string; + }; + expires: string; + status: string|null; +} \ No newline at end of file