Skip to content
Open
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
11 changes: 11 additions & 0 deletions package-lock.json

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

2 changes: 2 additions & 0 deletions src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import { BrowserRouter, Route, Routes } from "react-router-dom";
import Index from "./pages/Index";
import Worlds from "./pages/Worlds";
import FitnessWorld from "./pages/FitnessWorld";
import FinanceWorld from "./pages/FinanceWorld";
import StudyWorld from "./pages/StudyWorld";
import NotFound from "./pages/NotFound";
import SocialWorld from "./pages/SocialWorld";
Expand All @@ -25,6 +26,7 @@ const App = () => (
<Route path="/worlds/study" element={<StudyWorld />} />
<Route path="/worlds/social" element={<SocialWorld />} />
<Route path="/worlds/creative" element={<CreativeWorld />} />
<Route path="/worlds/finance" element={<FinanceWorld />} />
<Route path="/random" element={<RandomQuest />} />
<Route path="/about" element={<About />} />
<Route path="*" element={<NotFound />} />
Expand Down
15 changes: 15 additions & 0 deletions src/data/financeQuests.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
export interface Quest {
id: string;
title: string;
}

export const financeQuests = [
{ id: "f1", title: "Track today's expenses" },
{ id: "f2", title: "Save β‚Ή50" },
{ id: "f3", title: "Avoid impulse buying" },
{ id: "f4", title: "Review bank balance" },
{ id: "f5", title: "Learn one finance concept" },
{ id: "f6", title: "Set a weekly budget" },
{ id: "f7", title: "Cook instead of ordering" },
{ id: "f8", title: "Compare prices before buying" },
];
17 changes: 17 additions & 0 deletions src/pages/FinanceWorld.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import WorldLayout from "@/components/WorldLayout";
import QuestList from "@/components/QuestList";
import { financeQuests } from "@/data/financeQuests";

const FinanceWorld = () => {
return (
<WorldLayout worldName="Finance World">
<QuestList
worldId="finance"
worldEmoji="πŸ’°"
quests={financeQuests}
/>
</WorldLayout>
);
};

export default FinanceWorld;
9 changes: 7 additions & 2 deletions src/pages/Worlds.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ const worlds: WorldCard[] = [
{ id: "study", name: "Study World", emoji: "πŸ“š", description: "Learn something new every day.", active: true, path: "/worlds/study" },
{ id: "social", name: "Social World", emoji: "🀝", description: "Build connections, grow your network.", active: true, path: "/worlds/social" },
{ id: "creative", name: "Creative World", emoji: "🎨", description: "Express yourself through creation.", active: true, path: "/worlds/creative" },
{
id: "finance", name: "Finance World", emoji: "πŸ’°", description: "Build smart money habits.", active: true, path: "/worlds/finance",
},
];

const triggerConfetti = () => {
Expand Down Expand Up @@ -72,7 +75,7 @@ const Worlds = () => {
navigate(world.path!);
}, 150);
};

return (
<div className="fixed inset-0 flex flex-col grid-bg">
{/* Header */}
Expand Down Expand Up @@ -134,7 +137,7 @@ const Worlds = () => {
return (
<div
key={world.id}
className={`animate-fade-up animate-fade-up-delay-${i + 1} relative group ${
className={`animate-fade-up relative group ${
world.active ? "cursor-pointer" : "cursor-not-allowed"
} p-5 flex flex-col gap-3 border transition-all duration-300 ease-in-out
hover:scale-[1.03] hover:-translate-y-2 ${
Expand Down Expand Up @@ -211,6 +214,8 @@ const Worlds = () => {
})}

{/* Add world */}


<div
className="add-world-card border-2 border-dashed border-border p-5 flex flex-col items-center justify-center gap-2 cursor-pointer transition-all duration-300 hover:border-primary hover:shadow-[0_0_20px_hsl(var(--primary)/0.15)] bg-card group animate-fade-up"
onClick={() =>
Expand Down