Update CoinControl.tsx

This commit is contained in:
Marcos Rodriguez Velez 2024-11-15 17:34:02 -04:00
parent d2e05fd930
commit b53af08c75

View File

@ -457,13 +457,15 @@ const CoinControl: React.FC = () => {
}
}, [output]);
const toolTipActions = useMemo((): Action[] => {
const toolTipActions = useMemo((): Action[] | Action[][] => {
return [
sortDirection === ESortDirections.asc ? CommonToolTipActions.SortASC : CommonToolTipActions.SortDESC,
{ ...CommonToolTipActions.SortHeight, menuState: sortType === ESortTypes.height },
{ ...CommonToolTipActions.SortValue, menuState: sortType === ESortTypes.value },
{ ...CommonToolTipActions.SortLabel, menuState: sortType === ESortTypes.label },
{ ...CommonToolTipActions.SortStatus, menuState: sortType === ESortTypes.frozen },
[sortDirection === ESortDirections.asc ? CommonToolTipActions.SortASC : CommonToolTipActions.SortDESC],
[
{ ...CommonToolTipActions.SortHeight, menuState: sortType === ESortTypes.height },
{ ...CommonToolTipActions.SortValue, menuState: sortType === ESortTypes.value },
{ ...CommonToolTipActions.SortLabel, menuState: sortType === ESortTypes.label },
{ ...CommonToolTipActions.SortStatus, menuState: sortType === ESortTypes.frozen },
],
];
}, [sortDirection, sortType]);