diff --git a/.gitignore b/.gitignore index 5f6a045ca1..1bed78b263 100644 --- a/.gitignore +++ b/.gitignore @@ -39,3 +39,4 @@ packages/extension-koni-base/src/api/dotsama/ignore-staking.spec.ts packages/extension-koni-base/src/api/nft/evm_nft/ignore-moonbeam.api.spec.ts test.ts /packages/extension-koni-base/src/test-api/ +/packages/extension-base/src/koni/test-api/ diff --git a/packages/extension-koni-ui/src/Popup/Home/Staking/MoreActionModal.tsx b/packages/extension-koni-ui/src/Popup/Home/Staking/MoreActionModal.tsx index b0d9c42740..a2f4e6f1a0 100644 --- a/packages/extension-koni-ui/src/Popup/Home/Staking/MoreActionModal.tsx +++ b/packages/extension-koni-ui/src/Popup/Home/Staking/MoreActionModal.tsx @@ -136,15 +136,21 @@ const Component: React.FC = (props: Props) => { }); }, [nominatorMetadata, notify, t]); + const handleClaimRewardAction = useCallback(() => { + console.log(reward); + }, [reward]); + const onPressItem = useCallback( (item: ActionListType) => { if (item.action === StakingAction.WITHDRAW) { return () => handleWithdrawalAction(); + } else if (item.action === StakingAction.CLAIM_REWARD) { + return () => handleClaimRewardAction(); } return () => navigate(item.value, { state: { chainStakingMetadata, nominatorMetadata, staking, reward, hideTabList: true } as StakingDataOption }); }, - [chainStakingMetadata, handleWithdrawalAction, navigate, nominatorMetadata, reward, staking] + [chainStakingMetadata, handleClaimRewardAction, handleWithdrawalAction, navigate, nominatorMetadata, reward, staking] ); const availableActions = useCallback(() => {