Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
123 changes: 64 additions & 59 deletions webapp_front/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

29 changes: 12 additions & 17 deletions webapp_front/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,14 @@ import { onAuthStateChanged, type User } from 'firebase/auth';

import "./App.css"; // Ensure Tailwind is working


import { auth } from './_libs/firebase';

import RootLayout from "./_components/layouts";

import Home from "./_components/home";
import { Auth, Explore } from "./_components/socializing";
import Auth from "./_components/auth";
import { Explore } from "./_components/socializing";
import Goodbye from "./_components/goodbye";

import { auth } from './_libs/firebase';
import { useAuthDataStore } from "./_stores/user_auth_data";


Expand All @@ -34,23 +33,19 @@ const App = () => {

return (
<Routes>
{/* Auth route without layout */}
<Route path="/get-started" element={<Auth />} />

{/* All other routes with RootLayout */}
<Route element={<RootLayout />}>
<Route index element={<Home />} />
{
useAuthStore.signInData
?
<>
<Route path="/socialize/explore" element={<Explore />} />
</>
:
<>
<Route path="/socialize" element={<Auth />} />
</>
}
{useAuthStore.signInData && (
<Route path="/socialize/explore" element={<Explore />} />
)}
<Route path="/goodbye" element={<Goodbye />} />
{/* <Route path="/qr" element={<><QRCustomize /></>} /> */}
<Route path="*" element={<div className="grid place-items-center h-full text-3xl">no chai here</div>} />
</Route>

<Route path="*" element={<div className="grid place-items-center h-full text-3xl">no chai here</div>} />
</Routes>
);
};
Expand Down
Loading