Render IconFolderOpen when folder is open (#8811)

closes #8809 


https://github.com/user-attachments/assets/519e03ea-ae5e-4e4b-b03f-cf60d61dea49
This commit is contained in:
nitin 2024-11-29 20:43:22 +05:30 committed by GitHub
parent 27eae53d0a
commit a7bbc9e00d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 8 additions and 2 deletions

View File

@ -20,7 +20,12 @@ import { useState } from 'react';
import { createPortal } from 'react-dom';
import { useLocation } from 'react-router-dom';
import { useRecoilState } from 'recoil';
import { IconFolder, IconHeartOff, LightIconButton } from 'twenty-ui';
import {
IconFolder,
IconFolderOpen,
IconHeartOff,
LightIconButton,
} from 'twenty-ui';
type CurrentWorkspaceMemberFavoritesProps = {
folder: {
@ -137,7 +142,7 @@ export const CurrentWorkspaceMemberFavorites = ({
<NavigationDrawerItem
key={folder.folderId}
label={folder.folderName}
Icon={IconFolder}
Icon={isOpen ? IconFolderOpen : IconFolder}
onClick={handleToggle}
rightOptions={rightOptions}
className="navigation-drawer-item"

View File

@ -133,6 +133,7 @@ export {
IconFlag,
IconFocusCentered,
IconFolder,
IconFolderOpen,
IconFolderPlus,
IconForbid,
IconFunction,