-
-
+
);
}
diff --git a/src/app/(navgroup)/logo.tsx b/src/app/(navgroup)/logo.tsx
new file mode 100644
index 0000000..07b5ba6
--- /dev/null
+++ b/src/app/(navgroup)/logo.tsx
@@ -0,0 +1,73 @@
+"use client";
+import Image from "next/image";
+import React, { useState } from "react";
+
+interface LogoLetterKeys
{
+ [letterKey: string]: T;
+}
+
+const UNPRESSED_LETTERS: LogoLetterKeys = {
+ L: "/keyboard_logo/unpressed/unpressed0.png",
+ O1: "/keyboard_logo/unpressed/unpressed1.png",
+ A: "/keyboard_logo/unpressed/unpressed2.png",
+ D: "/keyboard_logo/unpressed/unpressed3.png",
+ O2: "/keyboard_logo/unpressed/unpressed4.png",
+ U: "/keyboard_logo/unpressed/unpressed5.png",
+ T: "/keyboard_logo/unpressed/unpressed6.png",
+};
+
+const PRESSED_LETTERS: LogoLetterKeys = {
+ L: "/keyboard_logo/pressed/pressed0.png",
+ O1: "/keyboard_logo/pressed/pressed1.png",
+ A: "/keyboard_logo/pressed/pressed2.png",
+ D: "/keyboard_logo/pressed/pressed3.png",
+ O2: "/keyboard_logo/pressed/pressed4.png",
+ U: "/keyboard_logo/pressed/pressed5.png",
+ T: "/keyboard_logo/pressed/pressed6.png",
+};
+
+function LogoLetters({
+ letterKey,
+}: {
+ letterKey: keyof typeof UNPRESSED_LETTERS;
+}) {
+ const [hover, setHover] = useState(false);
+
+ return (
+ <>
+ {hover ? (
+ setHover(true)}
+ onMouseLeave={() => setHover(false)}
+ width={104}
+ height={96}
+ />
+ ) : (
+ setHover(true)}
+ onMouseLeave={() => setHover(false)}
+ width={104}
+ height={96}
+ />
+ )}
+ >
+ );
+}
+
+export default function Logo() {
+ return (
+
+
+
+
+
+
+
+
+
+ );
+}
diff --git a/src/app/(navgroup)/navbar.tsx b/src/app/(navgroup)/navbar.tsx
index e54c758..d12f923 100644
--- a/src/app/(navgroup)/navbar.tsx
+++ b/src/app/(navgroup)/navbar.tsx
@@ -2,7 +2,7 @@
import Link from "next/link";
import { useState } from "react";
-export default function Navbar({ isVerified }: { isVerified: boolean }) {
+export default function Navigation({ isVerified }: { isVerified: boolean }) {
const [isMenuOpen, setIsMenuOpen] = useState(false);
const navbarItems: string[] = [];
const toggleMenu = () => {
@@ -16,7 +16,7 @@ export default function Navbar({ isVerified }: { isVerified: boolean }) {
}
return (
-
@@ -37,6 +37,6 @@ export default function Navbar({ isVerified }: { isVerified: boolean }) {
);
})}
-
+
);
}
diff --git a/src/app/api/igdb/gameCount/route.ts b/src/app/api/igdb/gameCount/route.ts
new file mode 100644
index 0000000..b1fef71
--- /dev/null
+++ b/src/app/api/igdb/gameCount/route.ts
@@ -0,0 +1,22 @@
+import { NextResponse } from "next/server";
+import Game from "@/models/gameModel.js";
+import mongoose from "mongoose";
+import { connectToDatabase } from "@/dbConfig/dbConfig";
+
+export async function GET() {
+ try {
+ if (mongoose.connection.readyState !== 1) {
+ await connectToDatabase();
+ }
+
+ const gameCount = await Game.countDocuments();
+
+ return NextResponse.json({ gameCount });
+ } catch (error: any) {
+ console.error("Error fetching game count:", error);
+ return NextResponse.json(
+ { error: "Failed to fetch game count" },
+ { status: 500 }
+ );
+ }
+}
diff --git a/src/app/api/users/userCount/route.ts b/src/app/api/users/userCount/route.ts
new file mode 100644
index 0000000..e3bc24a
--- /dev/null
+++ b/src/app/api/users/userCount/route.ts
@@ -0,0 +1,22 @@
+import { NextResponse } from "next/server";
+import User from "@/models/userModel";
+import mongoose from "mongoose";
+import { connectToDatabase } from "@/dbConfig/dbConfig";
+
+export async function GET() {
+ try {
+ if (mongoose.connection.readyState !== 1) {
+ await connectToDatabase();
+ }
+
+ const userCount = await User.countDocuments();
+
+ return NextResponse.json({ userCount });
+ } catch (error: any) {
+ console.error("Error fetching user count:", error);
+ return NextResponse.json(
+ { error: "Failed to fetch user count" },
+ { status: 500 }
+ );
+ }
+}
diff --git a/src/app/globals.css b/src/app/globals.css
index d72dec3..b321aad 100644
--- a/src/app/globals.css
+++ b/src/app/globals.css
@@ -1,3 +1,4 @@
+@import "nes.css/css/nes.min.css";
@import "tailwindcss";
@plugin "daisyui";
@@ -29,8 +30,43 @@
src: url("../../public/fonts/ThaleahFat.ttf") format("truetype");
}
+:-moz-focusring,
+:focus,
+button::-moz-focus-inner,
+:-moz-focusring *,
+:focus * {
+ outline: revert !important;
+ outline-offset: revert !important;
+ -moz-outline-radius: revert !important;
+ box-shadow: revert !important;
+}
+
+a {
+ color: black;
+ text-decoration: none;
+}
+
+a:hover {
+ color: white;
+ text-decoration: none;
+}
+
body {
- background: var(--background);
- color: var(--foreground);
+ margin: 0;
+ background-color: transparent;
font-family: PixelFont, Arial, Helvetica, sans-serif;
+ color: var(--foreground);
+}
+
+@keyframes scroll-left {
+ from {
+ transform: translateX(0);
+ }
+ to {
+ transform: translateX(-100%);
+ }
+}
+
+.animate-scroll-left {
+ animation: scroll-left 30s linear infinite;
}
diff --git a/src/app/layout.tsx b/src/app/layout.tsx
index f46558d..f794364 100644
--- a/src/app/layout.tsx
+++ b/src/app/layout.tsx
@@ -25,9 +25,11 @@ export default function RootLayout({
return (
-
- {children}
+
+
{children}
);