Skip to content

Commit

Permalink
feat: Migrate reward type (#351)
Browse files Browse the repository at this point in the history
  • Loading branch information
jinoosss authored May 24, 2024
1 parent cfc56e8 commit 67a6854
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,7 @@ const MyLiquidityContent: React.FC<MyLiquidityContentProps> = ({
SWAP_FEE: {},
STAKING: {},
EXTERNAL: {},
INTERNAL: {},
};
positions
.flatMap(position => position.reward)
Expand Down Expand Up @@ -188,6 +189,7 @@ const MyLiquidityContent: React.FC<MyLiquidityContentProps> = ({
SWAP_FEE: Object.values(infoMap["SWAP_FEE"]),
STAKING: Object.values(infoMap["STAKING"]),
EXTERNAL: Object.values(infoMap["EXTERNAL"]),
INTERNAL: Object.values(infoMap["INTERNAL"]),
};
}, [isDisplay, positions, tokenPrices]);

Expand All @@ -203,6 +205,7 @@ const MyLiquidityContent: React.FC<MyLiquidityContentProps> = ({
SWAP_FEE: {},
STAKING: {},
EXTERNAL: {},
INTERNAL: {},
};
positions
.flatMap(position => position.reward)
Expand All @@ -229,6 +232,7 @@ const MyLiquidityContent: React.FC<MyLiquidityContentProps> = ({
SWAP_FEE: Object.values(infoMap["SWAP_FEE"]),
STAKING: Object.values(infoMap["STAKING"]),
EXTERNAL: Object.values(infoMap["EXTERNAL"]),
INTERNAL: Object.values(infoMap["INTERNAL"]),
};
}, [isDisplay, positions, tokenPrices]);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,7 @@ const MyPositionCard: React.FC<MyPositionCardProps> = ({
SWAP_FEE: [],
STAKING: [],
EXTERNAL: [],
INTERNAL: [],
},
);

Expand Down Expand Up @@ -282,6 +283,7 @@ const MyPositionCard: React.FC<MyPositionCardProps> = ({
SWAP_FEE: [],
STAKING: [],
EXTERNAL: [],
INTERNAL: [],
},
);
return aprRewardInfo;
Expand Down
2 changes: 1 addition & 1 deletion packages/web/src/constants/option.constant.ts
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,7 @@ export type AddLiquiditySubmitType =
| "SELECT_TOKEN"
| "AMOUNT_TOO_LOW";

export type RewardType = "SWAP_FEE" | "STAKING" | "EXTERNAL";
export type RewardType = "SWAP_FEE" | "STAKING" | "EXTERNAL" | "INTERNAL";

export type StakingPeriodType = "5D" | "10D" | "30D" | "MAX";

Expand Down

0 comments on commit 67a6854

Please sign in to comment.