diff --git a/src/layouts/AdminLayout.tsx b/src/layouts/AdminLayout.tsx index 98494a5..d1b5f15 100644 --- a/src/layouts/AdminLayout.tsx +++ b/src/layouts/AdminLayout.tsx @@ -1,4 +1,4 @@ -import React, { useState } from 'react' +import { useState } from 'react' import { Outlet } from 'react-router-dom' @@ -125,13 +125,9 @@ const AdminLayout = () => {
} - searchSlot={ - - } />
diff --git a/src/shared/composites/AvatarMenu/AvatarMenu.tsx b/src/shared/composites/AvatarMenu/AvatarMenu.tsx index 150db77..c232bdf 100644 --- a/src/shared/composites/AvatarMenu/AvatarMenu.tsx +++ b/src/shared/composites/AvatarMenu/AvatarMenu.tsx @@ -79,7 +79,6 @@ export function AvatarMenu({
Moderator account
- {/* Items */} -
- -
+ { + const newTheme = checked ? 'dark' : 'light' + + setTheme(newTheme) + + toast.info(`Theme changed to ${newTheme}`) + }} + /> +
{' '} +
{/* Desktop Search */} - {searchSlot && ( -
-
{searchSlot}
+ {(showSearch || searchSlot) && ( +
+
+ {searchSlot || ( +
+ + + +
+ )} +
)} diff --git a/src/views/LoginPage.tsx b/src/views/LoginPage.tsx index 51940c8..22b4c3b 100644 --- a/src/views/LoginPage.tsx +++ b/src/views/LoginPage.tsx @@ -1,4 +1,5 @@ -import LoginCard from '@/LoginCard' +// import LoginCard from '@/LoginCard' +import MetricCard from '@/shared/composites/MetricCard' // import { SidebarNav } from '@/shared/composites/SidebarNav' @@ -13,9 +14,54 @@ import LoginCard from '@/LoginCard' // import { useState } from 'react' const LoginPage = () => { + const metricCardData = [ + { + idx: 1, + label: 'Pending', + value: 3, + subLabel: 'awaiting action', + valueColor: 'warning', + }, + { + idx: 2, + label: 'Escalated', + value: 1, + subLabel: 'needs review', + valueColor: 'danger', + }, + { + idx: 3, + label: 'AI Auto-resolved', + value: 8, + subLabel: 'this week', + valueColor: 'success', + }, + { + idx: 4, + label: 'Escalation Rate', + value: '34%', + subLabel: 'of all reports', + valueColor: 'default', + }, + ] as const + return ( -
- +
+ {' '} +
+ {metricCardData.map((item) => { + return ( + + ) + })} +
+ {/* */}
) }