Skip to content

Commit c013305

Browse files
authored
feat: target liquidity (#629)
1 parent 4c94079 commit c013305

File tree

4 files changed

+11
-0
lines changed

4 files changed

+11
-0
lines changed

packages/contract-helpers/src/umbrella/StakeDataProvider.test.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ const mockStakeData: StakeDataStruct = {
3535
symbol: 'MST',
3636
price: BigNumber.from('1000000000000000000'),
3737
totalAssets: BigNumber.from('1000000000000000000000000'),
38+
targetLiquidity: BigNumber.from('2000000000000000000000000'),
3839
underlyingTokenAddress: '0xabcdefabcdefabcdefabcdefabcdefabcdefabcd',
3940
underlyingTokenName: 'Mock Underlying Token',
4041
underlyingTokenSymbol: 'MUT',
@@ -119,6 +120,7 @@ describe('Umbrella StakeDataProvider', () => {
119120
...mockStakeData,
120121
totalAssets: '1000000000000000000000000',
121122
price: '1000000000000000000',
123+
targetLiquidity: '2000000000000000000000000',
122124
cooldownSeconds: 86400,
123125
unstakeWindowSeconds: 43200,
124126
rewards: [

packages/contract-helpers/src/umbrella/StakeDataProvider.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ export interface StakeData {
88
symbol: string;
99
price: string;
1010
totalAssets: string;
11+
targetLiquidity: string;
1112
underlyingTokenAddress: string;
1213
underlyingTokenName: string;
1314
underlyingTokenSymbol: string;
@@ -96,6 +97,7 @@ export class StakeDataProviderService {
9697
symbol: r.symbol,
9798
price: r.price.toString(),
9899
totalAssets: r.totalAssets.toString(),
100+
targetLiquidity: r.targetLiquidity.toString(),
99101
underlyingTokenAddress: r.underlyingTokenAddress,
100102
underlyingTokenName: r.underlyingTokenName,
101103
underlyingTokenSymbol: r.underlyingTokenSymbol,

packages/contract-helpers/src/umbrella/typechain/StakeDataProvider.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,7 @@ export type StakeDataStruct = {
8787
symbol: string;
8888
price: BigNumberish;
8989
totalAssets: BigNumberish;
90+
targetLiquidity: BigNumberish;
9091
underlyingTokenAddress: string;
9192
underlyingTokenName: string;
9293
underlyingTokenSymbol: string;
@@ -119,6 +120,7 @@ export type StakeDataStructOutput = [
119120
symbol: string;
120121
price: BigNumber;
121122
totalAssets: BigNumber;
123+
targetLiquidity: BigNumber;
122124
underlyingTokenAddress: string;
123125
underlyingTokenName: string;
124126
underlyingTokenSymbol: string;

packages/contract-helpers/src/umbrella/typechain/StakeDataProvider__factory.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,11 @@ const _abi = [
8282
type: 'uint256',
8383
internalType: 'uint256',
8484
},
85+
{
86+
name: 'targetLiquidity',
87+
type: 'uint256',
88+
internalType: 'uint256',
89+
},
8590
{
8691
name: 'underlyingTokenAddress',
8792
type: 'address',

0 commit comments

Comments
 (0)