The weeb for the next gen discord boat - Wamellow
wamellow.com
bot
discord
1"use client";
2
3import { cn } from "@/utils/cn";
4import * as TooltipPrimitive from "@radix-ui/react-tooltip";
5import * as React from "react";
6
7const TooltipProvider = TooltipPrimitive.Provider;
8
9const Tooltip = ({ delayDuration, ...props }: React.ComponentPropsWithoutRef<typeof TooltipPrimitive.Root>) => (
10 <TooltipPrimitive.Root
11 delayDuration={delayDuration ?? 4}
12 {...props}
13 />
14);
15Tooltip.displayName = TooltipPrimitive.Root.displayName;
16
17const TooltipTrigger = TooltipPrimitive.Trigger;
18
19const TooltipContent = React.forwardRef<
20 React.ElementRef<typeof TooltipPrimitive.Content>,
21 React.ComponentPropsWithoutRef<typeof TooltipPrimitive.Content>
22>(({ className, ...props }, ref) => (
23 <TooltipPrimitive.Content
24 ref={ref}
25 className={cn(
26 "z-50 overflow-hidden rounded-md bg-popover/30 backdrop-blur-md px-3 py-1.5 text-sm text-popover-foreground shadow-md animate-in fade-in-0 zoom-in-95 max-w-md data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
27 className
28 )}
29 {...props}
30 />
31));
32TooltipContent.displayName = TooltipPrimitive.Content.displayName;
33
34export { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger };