quivr/frontend/lib/components/ui/Avatar.tsx
Matthieu Jacq ee7af51c4d
feat: upgrade button in user settings (#1484)
# Description

Epic: #1429
User Story: #1431

- Add an upgrade button in user settings.
- Remove hover links on sidebar buttons (otherwise the link could
partially hide the button)

## Screenshots (if appropriate):

<img width="749" alt="image"
src="https://github.com/StanGirard/quivr/assets/67386567/6265ba2b-8d91-4ee8-abb3-98417ad91076">

<img width="803" alt="image"
src="https://github.com/StanGirard/quivr/assets/67386567/c13ce60b-a54d-44d7-a622-bcb1200ddb81">
2023-10-25 12:42:53 +02:00

27 lines
497 B
TypeScript

import Image from "next/image";
import { cn } from "@/lib/utils";
type AvatarProps = {
url: string;
imgClassName?: string;
className?: string;
};
export const Avatar = ({
url,
imgClassName,
className,
}: AvatarProps): JSX.Element => {
return (
<div className={cn("relative w-8 h-8 shrink-0", className)}>
<Image
alt="avatar"
fill={true}
sizes="32px"
src={url}
className={cn("rounded-xl", imgClassName)}
/>
</div>
);
};