22
33import { useUpdateCheck } from "../hooks/use-update-check" ;
44import { useSidebar , SidebarGroup , SidebarGroupContent , SidebarMenu , SidebarMenuItem , SidebarMenuButton } from "@/components/ui/sidebar" ;
5- import { X , ArrowUpCircle } from "lucide-react" ;
5+ import { X , ArrowUpCircle , MoveRight } from "lucide-react" ;
66import Link from "next/link" ;
7- import { cn } from "@/lib/utils" ;
87
98export const UpdateNotification = ( ) => {
109 const { isUpdateAvailable, latestRelease, dismissUpdate } = useUpdateCheck ( ) ;
@@ -28,28 +27,27 @@ export const UpdateNotification = () => {
2827 < span className = "sr-only" > Dismiss</ span >
2928 </ button >
3029
31- < div className = "flex items-center gap-2" >
32- < div className = "flex size-6 items-center justify-center rounded-md bg-primary/10 text-primary" >
30+ < div className = "flex items-center gap-2.5 " >
31+ < div className = "flex size-7 shrink-0 items-center justify-center rounded-full bg-primary/10 text-primary" >
3332 < ArrowUpCircle className = "size-4" />
3433 </ div >
35- < div className = "flex flex-col gap-0.5" >
36- < span className = "text-[12px] font-semibold leading-none" > Update available</ span >
37- < span className = "text-[10px] text-muted-foreground font-medium" >
38- v{ latestRelease . tag_name . replace ( / ^ v / , "" ) }
39- </ span >
34+ < div className = "flex flex-col min-w-0" >
35+ < div className = "flex items-center gap-1.5" >
36+ < span className = "text-[12px] font-semibold leading-none" > Update available</ span >
37+ < span className = "text-[10px] text-muted-foreground font-medium px-1.5 py-0.5 bg-primary/10 rounded-full" >
38+ v{ latestRelease . tag_name . replace ( / ^ v / , "" ) }
39+ </ span >
40+ </ div >
41+ < Link
42+ href = { latestRelease . html_url }
43+ target = "_blank"
44+ className = "group inline-flex items-center gap-1 text-[11px] text-primary hover:underline font-medium mt-1"
45+ >
46+ See what's new
47+ < MoveRight className = "size-3 transition-transform group-hover:translate-x-0.5" />
48+ </ Link >
4049 </ div >
4150 </ div >
42-
43- < SidebarMenuButton
44- asChild
45- variant = "outline"
46- size = "sm"
47- className = "h-7 w-full justify-center bg-background text-[10px] font-medium shadow-none hover:bg-primary/5 hover:text-primary hover:border-primary/30"
48- >
49- < Link href = { latestRelease . html_url } target = "_blank" >
50- See what's new
51- </ Link >
52- </ SidebarMenuButton >
5351 </ div >
5452 </ SidebarMenuItem >
5553 </ SidebarMenu >
0 commit comments