From b0c84700996c70c39a819cd331463c806c2f59a0 Mon Sep 17 00:00:00 2001 From: Louis Knight-Webb Date: Sat, 14 Jun 2025 19:10:28 -0400 Subject: [PATCH] Edit tasks --- frontend/src/pages/home.tsx | 137 ++++++++++++++++++------------------ 1 file changed, 67 insertions(+), 70 deletions(-) diff --git a/frontend/src/pages/home.tsx b/frontend/src/pages/home.tsx index d2f7ce11..c048b77a 100644 --- a/frontend/src/pages/home.tsx +++ b/frontend/src/pages/home.tsx @@ -1,37 +1,53 @@ -import { useState } from 'react' -import { Link } from 'react-router-dom' -import { Button } from '@/components/ui/button' -import { Card, CardContent, CardDescription, CardHeader, CardTitle } from '@/components/ui/card' -import { Alert, AlertDescription } from '@/components/ui/alert' -import { Badge } from '@/components/ui/badge' -import { Separator } from '@/components/ui/separator' -import { ApiResponse } from 'shared/types' -import { authStorage, makeAuthenticatedRequest } from '@/lib/auth' -import { Heart, Activity, FolderOpen, Users, CheckCircle, AlertCircle, Zap, Shield, Code } from 'lucide-react' +import { useState } from "react"; +import { Link } from "react-router-dom"; +import { Button } from "@/components/ui/button"; +import { + Card, + CardContent, + CardDescription, + CardHeader, + CardTitle, +} from "@/components/ui/card"; +import { Alert, AlertDescription } from "@/components/ui/alert"; +import { Badge } from "@/components/ui/badge"; +import { Separator } from "@/components/ui/separator"; +import { ApiResponse } from "shared/types"; +import { authStorage, makeAuthenticatedRequest } from "@/lib/auth"; +import { + Heart, + Activity, + FolderOpen, + Users, + CheckCircle, + AlertCircle, + Zap, + Shield, + Code, +} from "lucide-react"; export function HomePage() { - const [message, setMessage] = useState('') - const [messageType, setMessageType] = useState<'success' | 'error'>('success') - const [loading, setLoading] = useState(false) - - const currentUser = authStorage.getUser() - + const [message, setMessage] = useState(""); + const [messageType, setMessageType] = useState<"success" | "error">( + "success" + ); + const [loading, setLoading] = useState(false); + const currentUser = authStorage.getUser(); const checkHealth = async () => { - setLoading(true) + setLoading(true); try { - const response = await makeAuthenticatedRequest('/api/health') - const data: ApiResponse = await response.json() - setMessage(data.message || 'Health check completed') - setMessageType('success') + const response = await makeAuthenticatedRequest("/api/health"); + const data: ApiResponse = await response.json(); + setMessage(data.message || "Health check completed"); + setMessageType("success"); } catch (error) { - setMessage('Backend health check failed') - setMessageType('error') + setMessage("Backend health check failed"); + setMessageType("error"); } finally { - setLoading(false) + setLoading(false); } - } + }; return (
@@ -54,30 +70,10 @@ export function HomePage() {

Welcome to Bloop

-

- A modern full-stack monorepo built with Rust backend and React frontend. - Get started by exploring our features below. -

-
- - - Secure - - - - Type-Safe - - - - Real-time - -
{/* Feature Cards */}
- -
@@ -87,22 +83,24 @@ export function HomePage() {
Health Check
- Monitor + + Monitor + Monitor the health status of your backend services - @@ -116,14 +114,20 @@ export function HomePage() { Projects - CRUD + + CRUD + Manage your projects with full CRUD operations -