mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-12-23 03:40:14 +01:00
* style: update Assistant builder * fix(Eng): re-introduce old file_search info message * feat: new OGDialogTemplate; style: imporved tools + actions dialogs * style: fix alignment issue for delete tool dialog * chore: import order --------- Co-authored-by: Danny Avila <danny@librechat.ai>
35 lines
1.1 KiB
TypeScript
35 lines
1.1 KiB
TypeScript
import * as React from 'react';
|
|
import * as HoverCardPrimitive from '@radix-ui/react-hover-card';
|
|
|
|
import { cn } from '../../utils';
|
|
|
|
const HoverCard = HoverCardPrimitive.Root;
|
|
|
|
const HoverCardTrigger = HoverCardPrimitive.Trigger;
|
|
|
|
const HoverCardPortal = HoverCardPrimitive.Portal;
|
|
|
|
const HoverCardContent = React.forwardRef<
|
|
React.ElementRef<typeof HoverCardPrimitive.Content>,
|
|
React.ComponentPropsWithoutRef<typeof HoverCardPrimitive.Content> & { disabled?: boolean }
|
|
>(({ className = '', align = 'center', sideOffset = 6, disabled = false, ...props }, ref) => {
|
|
if (disabled) {
|
|
return null;
|
|
}
|
|
|
|
return (
|
|
<HoverCardPrimitive.Content
|
|
ref={ref}
|
|
align={align}
|
|
sideOffset={sideOffset}
|
|
className={cn(
|
|
'z-50 w-64 rounded-md border border-gray-200 bg-white p-4 shadow-md outline-none animate-in fade-in-0 dark:border-gray-800 dark:bg-gray-800',
|
|
className,
|
|
)}
|
|
{...props}
|
|
/>
|
|
);
|
|
});
|
|
HoverCardContent.displayName = HoverCardPrimitive.Content.displayName;
|
|
|
|
export { HoverCard, HoverCardTrigger, HoverCardContent, HoverCardPortal };
|