diff --git a/.gitignore b/.gitignore index 7ceb59f..0341e09 100644 --- a/.gitignore +++ b/.gitignore @@ -23,3 +23,12 @@ dist-ssr *.sln *.sw? .env +dashboard/build/assets/index-Bv76DabZ.js +dashboard/build/assets/index-Bv76DabZ.js.map +dashboard/build/assets/index-DOOYmQEM.css +dashboard-server/frontend/build/assets/._index-Bv76DabZ.js +dashboard-server/frontend/build/assets/._index-Bv76DabZ.js.map +dashboard-server/frontend/build/assets/._index-DOOYmQEM.css +dashboard-server/frontend/build/assets/index-Bv76DabZ.js +dashboard-server/frontend/build/assets/index-Bv76DabZ.js.map +dashboard-server/frontend/build/assets/index-DOOYmQEM.css diff --git a/dashboard/src/App.jsx b/dashboard/src/App.jsx index 853604e..9834078 100644 --- a/dashboard/src/App.jsx +++ b/dashboard/src/App.jsx @@ -82,29 +82,32 @@ const SmallLayout = () => { const DashboardLayout = () => { return ( -
+
-
-
+
+
-
+
-
+
+ +
+
-
+
diff --git a/dashboard/src/components/dashboard/EventFeed.jsx b/dashboard/src/components/dashboard/EventFeed.jsx index 79b0a38..8cc8f2b 100644 --- a/dashboard/src/components/dashboard/EventFeed.jsx +++ b/dashboard/src/components/dashboard/EventFeed.jsx @@ -1121,8 +1121,7 @@ const EventCard = ({ event }) => { const DEFAULT_METRICS = Object.values(METRIC_IDS); const EventFeed = ({ - title = "Live Event Feed", - description = "Real-time event stream", + title = "Event Feed", selectedMetrics = DEFAULT_METRICS, }) => { const metrics = useMemo(() => selectedMetrics, [selectedMetrics]); @@ -1387,7 +1386,7 @@ const EventFeed = ({ ); return ( - +
@@ -1622,7 +1621,7 @@ const EventFeed = ({ )} - + {loading && !events.length ? ( diff --git a/dashboard/src/components/dashboard/Header.jsx b/dashboard/src/components/dashboard/Header.jsx index ae07cc3..6a56fc9 100644 --- a/dashboard/src/components/dashboard/Header.jsx +++ b/dashboard/src/components/dashboard/Header.jsx @@ -133,7 +133,7 @@ const Header = () => { )} > -
+
{
-
+
{weather?.main && ( <>
diff --git a/dashboard/src/components/dashboard/ProductGrid.jsx b/dashboard/src/components/dashboard/ProductGrid.jsx index b746bab..39f2946 100644 --- a/dashboard/src/components/dashboard/ProductGrid.jsx +++ b/dashboard/src/components/dashboard/ProductGrid.jsx @@ -2,7 +2,7 @@ import React, { useState, useEffect } from "react"; import axios from "axios"; import { Card, CardContent, CardHeader, CardTitle, CardDescription } from "@/components/ui/card"; import { ScrollArea } from "@/components/ui/scroll-area"; -import { Loader2, ArrowUpDown, AlertCircle, Package, Settings2, Search } from "lucide-react"; +import { Loader2, ArrowUpDown, AlertCircle, Package, Settings2, Search, X } from "lucide-react"; import { Table, TableBody, @@ -46,6 +46,7 @@ const ProductGrid = ({ direction: "desc", }); const [searchQuery, setSearchQuery] = useState(""); + const [isSearchVisible, setIsSearchVisible] = useState(false); useEffect(() => { fetchProducts(); @@ -163,41 +164,67 @@ const ProductGrid = ({ return ( -
-
- {title} - {description && ( - {description} - )} -
-
- {!error && ( -
- - setSearchQuery(e.target.value)} - className="pl-8 h-9 w-[200px]" - /> -
- )} - +
+
+
+ {title} + {description && ( + {description} + )} +
+
+ {!error && ( + + )} + +
+ {isSearchVisible && !error && ( +
+ + setSearchQuery(e.target.value)} + className="pl-9 pr-9 h-9 w-full" + autoFocus + /> + {searchQuery && ( + + )} +
+ )}
@@ -225,39 +252,39 @@ const ProductGrid = ({ - - - -
- + + + + + diff --git a/dashboard/src/components/dashboard/SalesChart.jsx b/dashboard/src/components/dashboard/SalesChart.jsx index ac7cc0f..ef85319 100644 --- a/dashboard/src/components/dashboard/SalesChart.jsx +++ b/dashboard/src/components/dashboard/SalesChart.jsx @@ -449,7 +449,7 @@ const SummaryStats = memo(({ stats = {} }) => { } = stats; return ( -
+
( const SalesChart = ({ timeRange = "last30days", title = "Sales Overview", - description = "Track your sales performance over time", }) => { const [data, setData] = useState([]); const [loading, setLoading] = useState(true); @@ -684,12 +683,12 @@ const SalesChart = ({ {title}
-
+
{!error && ( @@ -759,7 +758,7 @@ const SalesChart = ({ })) } > - Compare Prev Period + Compare Prev
@@ -875,7 +874,7 @@ const SalesChart = ({ {/* Show metric toggles only if not in error state */} {!error && ( -
+
- + +