From 1cf89bacba59c1edbc5a65d3f6e3ea2b575b89c4 Mon Sep 17 00:00:00 2001
From: Biswa Kalyan Bhuyan <biswa@surgot.in>
Date: Thu, 29 May 2025 01:50:36 +0530
Subject: fix: Improved UI and NavBar Menu

- Fixed alignment issues in the frontend
- Fixed the box border hover selection in the menu bar (mobile)
- Changed the theme toggle button color to standard frontend theme
- Enhanced UI components
---
 frontend/src/components/theme-toggle.tsx | 35 +++++++++++++++-----------------
 1 file changed, 16 insertions(+), 19 deletions(-)

(limited to 'frontend/src/components/theme-toggle.tsx')

diff --git a/frontend/src/components/theme-toggle.tsx b/frontend/src/components/theme-toggle.tsx
index 53d8286..7532775 100644
--- a/frontend/src/components/theme-toggle.tsx
+++ b/frontend/src/components/theme-toggle.tsx
@@ -26,10 +26,10 @@ export function ThemeToggle() {
       <Button 
         variant="ghost" 
         size="icon" 
-        className="nav-button-transparent backdrop-blur-sm relative overflow-hidden transition-all duration-300 hover:scale-105 active:scale-95"
+        className="nav-button-transparent backdrop-blur-sm min-w-[44px] min-h-[44px]"
         disabled
       >
-        <Monitor className="h-[1.1rem] w-[1.1rem] text-muted-foreground/60" />
+        <Monitor className="h-5 w-5" />
         <span className="sr-only">Toggle theme</span>
       </Button>
     )
@@ -41,14 +41,11 @@ export function ThemeToggle() {
         <Button 
           variant="ghost" 
           size="icon" 
-          className="nav-button-transparent backdrop-blur-sm relative overflow-hidden transition-all duration-300 hover:scale-105 active:scale-95 group"
+          className="nav-button-transparent backdrop-blur-sm min-w-[44px] min-h-[44px]"
         >
-          {/* Enhanced icon transitions with better positioning */}
-          <Sun className="h-[1.1rem] w-[1.1rem] rotate-0 scale-100 transition-all duration-500 ease-in-out dark:-rotate-180 dark:scale-0 text-amber-500 dark:text-amber-400 group-hover:text-amber-600 dark:group-hover:text-amber-300" />
-          <Moon className="absolute h-[1.1rem] w-[1.1rem] rotate-180 scale-0 transition-all duration-500 ease-in-out dark:rotate-0 dark:scale-100 text-blue-600 dark:text-blue-400 group-hover:text-blue-700 dark:group-hover:text-blue-300" />
-          
-          {/* Subtle background glow effect on hover */}
-          <div className="absolute inset-0 rounded-full bg-gradient-to-r from-amber-500/0 to-blue-500/0 group-hover:from-amber-500/10 group-hover:to-blue-500/10 dark:group-hover:from-amber-400/10 dark:group-hover:to-blue-400/10 transition-all duration-300" />
+          {/* Simple icon transitions with consistent styling */}
+          <Sun className="h-5 w-5 rotate-0 scale-100 transition-all duration-500 ease-in-out dark:-rotate-180 dark:scale-0" />
+          <Moon className="absolute h-5 w-5 rotate-180 scale-0 transition-all duration-500 ease-in-out dark:rotate-0 dark:scale-100" />
           
           <span className="sr-only">Toggle theme</span>
         </Button>
@@ -56,39 +53,39 @@ export function ThemeToggle() {
       
       <DropdownMenuContent 
         align="end" 
-        className="nav-dropdown-transparent min-w-[140px] animate-in fade-in-0 zoom-in-95 slide-in-from-top-2 duration-200"
+        className="nav-dropdown-transparent"
         sideOffset={8}
       >
         <DropdownMenuItem 
           onClick={() => setTheme("light")} 
-          className="flex items-center gap-3 nav-dropdown-item cursor-pointer group/item"
+          className="flex items-center gap-3 nav-dropdown-item cursor-pointer"
         >
-          <Sun className="h-4 w-4 text-amber-500 group-hover/item:text-amber-600 transition-colors duration-200" />
+          <Sun className="h-4 w-4" />
           <span className="flex-1">Light</span>
           {theme === "light" && (
-            <span className="text-xs text-emerald-600 dark:text-emerald-400 font-medium animate-in fade-in-0 scale-in-75 duration-200">✓</span>
+            <span className="text-xs font-medium">✓</span>
           )}
         </DropdownMenuItem>
         
         <DropdownMenuItem 
           onClick={() => setTheme("dark")} 
-          className="flex items-center gap-3 nav-dropdown-item cursor-pointer group/item"
+          className="flex items-center gap-3 nav-dropdown-item cursor-pointer"
         >
-          <Moon className="h-4 w-4 text-blue-600 dark:text-blue-400 group-hover/item:text-blue-700 dark:group-hover/item:text-blue-300 transition-colors duration-200" />
+          <Moon className="h-4 w-4" />
           <span className="flex-1">Dark</span>
           {theme === "dark" && (
-            <span className="text-xs text-emerald-600 dark:text-emerald-400 font-medium animate-in fade-in-0 scale-in-75 duration-200">✓</span>
+            <span className="text-xs font-medium">✓</span>
           )}
         </DropdownMenuItem>
         
         <DropdownMenuItem 
           onClick={() => setTheme("system")} 
-          className="flex items-center gap-3 nav-dropdown-item cursor-pointer group/item"
+          className="flex items-center gap-3 nav-dropdown-item cursor-pointer"
         >
-          <Monitor className="h-4 w-4 text-slate-600 dark:text-slate-400 group-hover/item:text-slate-700 dark:group-hover/item:text-slate-300 transition-colors duration-200" />
+          <Monitor className="h-4 w-4" />
           <span className="flex-1">System</span>
           {theme === "system" && (
-            <span className="text-xs text-emerald-600 dark:text-emerald-400 font-medium animate-in fade-in-0 scale-in-75 duration-200">✓</span>
+            <span className="text-xs font-medium">✓</span>
           )}
         </DropdownMenuItem>
       </DropdownMenuContent>
-- 
cgit v1.2.3-59-g8ed1b

