Favorites Folders Fast Followups (#8920)

Fixes :
<img width="716" alt="Screenshot 2024-12-06 at 3 45 41 PM"
src="https://github.com/user-attachments/assets/61fdf355-0d0a-4ed7-befa-ada23341a58f">

Fixes: Reduce menu width to 160px and it should appear below three dots
<img width="394" alt="Screenshot 2024-12-06 at 3 46 49 PM"
src="https://github.com/user-attachments/assets/b1266f83-9b6f-445b-9409-d7f691776bd0">

Fixes: The right margin should be 2px
<img width="1134" alt="Screenshot 2024-12-06 at 3 47 45 PM"
src="https://github.com/user-attachments/assets/b6dd857c-6575-418d-8e32-64cd4e5d4e85">

Fixes:
Requirement: Clicking the heart Icon should put the record as favorite.
It shouldn't open the menu on first click. It should only on second
click, when the record is already a favorite.

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
This commit is contained in:
nitin
2024-12-17 16:45:36 +05:30
committed by GitHub
parent ac2894c87c
commit c63842925f
5 changed files with 63 additions and 87 deletions

View File

@ -34,13 +34,20 @@ export const RecordShowPageBaseHeader = ({
{!isMobile && (
<>
{isFavoriteFolderEnabled ? (
<PageFavoriteFoldersDropdown
key={FAVORITE_FOLDER_PICKER_DROPDOWN_ID}
dropdownId={FAVORITE_FOLDER_PICKER_DROPDOWN_ID}
isFavorite={isFavorite}
record={record}
objectNameSingular={objectNameSingular}
/>
isFavorite ? (
<PageFavoriteFoldersDropdown
key={FAVORITE_FOLDER_PICKER_DROPDOWN_ID}
dropdownId={FAVORITE_FOLDER_PICKER_DROPDOWN_ID}
isFavorite={isFavorite}
record={record}
objectNameSingular={objectNameSingular}
/>
) : (
<PageFavoriteButton
isFavorite={isFavorite}
onClick={handleFavoriteButtonClick}
/>
)
) : (
<PageFavoriteButton
isFavorite={isFavorite}