diff --git a/app/Http/Controllers/FrontHomeController.php b/app/Http/Controllers/FrontHomeController.php
index f30982e..3e5b6f1 100644
--- a/app/Http/Controllers/FrontHomeController.php
+++ b/app/Http/Controllers/FrontHomeController.php
@@ -2,7 +2,10 @@
namespace App\Http\Controllers;
+use App\Models\BackgroundMedia;
+use App\Models\MemeMedia;
use Illuminate\Support\Facades\App;
+use Illuminate\Support\Facades\Cache;
use Inertia\Inertia;
class FrontHomeController extends Controller
@@ -13,6 +16,16 @@ public function index()
return Inertia::render('comingsoon');
}
- return Inertia::render('home/home');
+ // Cache the counts for 1 day to reduce server calls
+ $stats = Cache::remember('home_stats', 60 * 60 * 24, function () {
+ return [
+ 'meme_count' => MemeMedia::count(),
+ 'background_count' => BackgroundMedia::count(),
+ ];
+ });
+
+ return Inertia::render('home/home', [
+ 'stats' => $stats,
+ ]);
}
}
diff --git a/resources/js/pages/home/partials/FAQDiscord.jsx b/resources/js/pages/home/partials/FAQDiscord.jsx
index 0d5b1e4..734e9f3 100644
--- a/resources/js/pages/home/partials/FAQDiscord.jsx
+++ b/resources/js/pages/home/partials/FAQDiscord.jsx
@@ -28,6 +28,10 @@ const FAQDiscord = () => {
q: 'How often do you add new content?',
a: 'We just started building this platform and will gradually add more meme templates and backgrounds over time, so everyone can continue using it for free with fresh content!
Want a certain content? Let us know in our Discord group.',
},
+ {
+ q: 'I found a bug!',
+ a: "Great, report it into the Discord group and we'll fix it as soon as possible!",
+ },
{
q: 'I have more questions!',
a: 'Great! Join our Discord group and ask away!',
diff --git a/resources/js/pages/home/partials/Footer.jsx b/resources/js/pages/home/partials/Footer.jsx
index 9ea6535..7b9ee06 100644
--- a/resources/js/pages/home/partials/Footer.jsx
+++ b/resources/js/pages/home/partials/Footer.jsx
@@ -1,6 +1,6 @@
import { Switch } from '@/components/ui/switch';
import { useTheme } from '@/hooks/useTheme';
-import { Sun, Moon } from 'lucide-react';
+import { Moon, Sun } from 'lucide-react';
const Footer = () => {
const currentYear = new Date().getFullYear();
@@ -12,35 +12,41 @@ const Footer = () => {