mirror of
https://github.com/beilunyang/moemail.git
synced 2026-04-22 23:07:25 +08:00
42 lines
1.2 KiB
TypeScript
42 lines
1.2 KiB
TypeScript
"use client"
|
|
|
|
import { useTranslations } from "next-intl"
|
|
import { Github } from "lucide-react"
|
|
import { Button } from "@/components/ui/button"
|
|
import {
|
|
Tooltip,
|
|
TooltipContent,
|
|
TooltipProvider,
|
|
TooltipTrigger,
|
|
} from "@/components/ui/tooltip"
|
|
|
|
export function FloatMenu() {
|
|
const t = useTranslations("common")
|
|
|
|
return (
|
|
<div className="fixed bottom-6 right-6">
|
|
<TooltipProvider>
|
|
<Tooltip>
|
|
<TooltipTrigger asChild>
|
|
<Button
|
|
variant="outline"
|
|
size="icon"
|
|
className="bg-white dark:bg-background rounded-full shadow-lg group relative border-primary/20"
|
|
onClick={() => window.open("https://github.com/beilunyang/moemail", "_blank")}
|
|
>
|
|
<Github
|
|
className="w-4 h-4 transition-all duration-300 text-primary group-hover:scale-110"
|
|
/>
|
|
<span className="sr-only">{t("github")}</span>
|
|
</Button>
|
|
</TooltipTrigger>
|
|
<TooltipContent>
|
|
<div className="text-sm">
|
|
<p>{t("github")}</p>
|
|
</div>
|
|
</TooltipContent>
|
|
</Tooltip>
|
|
</TooltipProvider>
|
|
</div>
|
|
)
|
|
}
|