mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-09-22 13:39:35 +00:00
feat: changed user icon
This commit is contained in:
1
frontend/public/lotties/three-ellipsis.json
Normal file
1
frontend/public/lotties/three-ellipsis.json
Normal file
File diff suppressed because one or more lines are too long
1
frontend/public/lotties/user.json
Normal file
1
frontend/public/lotties/user.json
Normal file
File diff suppressed because one or more lines are too long
@@ -14,8 +14,10 @@ export const MenuIconButton = <T extends ElementType = "button">({
|
||||
description,
|
||||
// wrapping in forward ref with generic component causes the loss of ts definitions on props
|
||||
inputRef,
|
||||
lottieIconMode = "forward",
|
||||
...props
|
||||
}: MenuItemProps<T> & ComponentPropsWithRef<T>): JSX.Element => {
|
||||
}: MenuItemProps<T> &
|
||||
ComponentPropsWithRef<T> & { lottieIconMode?: "reverse" | "forward" }): JSX.Element => {
|
||||
const iconRef = useRef<DotLottie | null>(null);
|
||||
return (
|
||||
<Item
|
||||
@@ -46,6 +48,7 @@ export const MenuIconButton = <T extends ElementType = "button">({
|
||||
src={`/lotties/${icon}.json`}
|
||||
loop
|
||||
className="h-full w-full"
|
||||
mode={lottieIconMode}
|
||||
/>
|
||||
</div>
|
||||
)}
|
||||
|
||||
@@ -5,7 +5,6 @@ import {
|
||||
faBook,
|
||||
faCheck,
|
||||
faCog,
|
||||
faEllipsis,
|
||||
faEnvelope,
|
||||
faInfinity,
|
||||
faInfo,
|
||||
@@ -309,11 +308,12 @@ export const MinimizedOrgSidebar = () => {
|
||||
<DropdownMenu>
|
||||
<DropdownMenuTrigger asChild>
|
||||
<div className="w-full">
|
||||
<MenuIconButton isSelected={isMoreSelected}>
|
||||
<div className="relative flex flex-col items-center justify-center">
|
||||
<FontAwesomeIcon icon={faEllipsis} className="mb-3 text-lg" />
|
||||
<span>More</span>
|
||||
</div>
|
||||
<MenuIconButton
|
||||
lottieIconMode="reverse"
|
||||
icon="three-ellipsis"
|
||||
isSelected={isMoreSelected}
|
||||
>
|
||||
More
|
||||
</MenuIconButton>
|
||||
</div>
|
||||
</DropdownMenuTrigger>
|
||||
@@ -410,11 +410,7 @@ export const MinimizedOrgSidebar = () => {
|
||||
<DropdownMenu>
|
||||
<DropdownMenuTrigger className="w-full" asChild>
|
||||
<div>
|
||||
<MenuIconButton>
|
||||
<div className="my-1 flex h-6 w-6 items-center justify-center rounded-md bg-primary text-sm uppercase text-black">
|
||||
{user?.firstName?.charAt(0)}
|
||||
</div>
|
||||
</MenuIconButton>
|
||||
<MenuIconButton icon="user">User</MenuIconButton>
|
||||
</div>
|
||||
</DropdownMenuTrigger>
|
||||
<DropdownMenuContent align="start" className="p-1">
|
||||
|
||||
Reference in New Issue
Block a user