Skip to content

Commit

Permalink
Peter/fix byof not working (#1430)
Browse files Browse the repository at this point in the history
* chore: update monetary to latest 0.7.3

* fix(byof): use correct field props getter for fee token select
  • Loading branch information
peterslany authored Jul 6, 2023
1 parent 4a94ead commit 9a3f495
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/pages/AMM/Pools/components/DepositForm/DepositForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ const DepositForm = ({ pool, overlappingModalRef, onSuccess, onSigning }: Deposi
<Flex direction='column' gap='spacing4'>
<TransactionFeeDetails
{...transaction.fee.detailsProps}
selectProps={{ ...form.getFieldProps(POOL_DEPOSIT_FEE_TOKEN_FIELD), modalRef: overlappingModalRef }}
selectProps={{ ...form.getSelectFieldProps(POOL_DEPOSIT_FEE_TOKEN_FIELD), modalRef: overlappingModalRef }}
/>
<AuthCTA type='submit' size='large' disabled={isBtnDisabled}>
{t('amm.pools.add_liquidity')}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ const PoolsInsights = ({ pools, accountPoolsData, refetch }: PoolsInsightsProps)
<TransactionFeeDetails
{...transaction.fee.detailsProps}
selectProps={{
...form.getFieldProps(POOL_CLAIM_REWARDS_FEE_TOKEN_FIELD),
...form.getSelectFieldProps(POOL_CLAIM_REWARDS_FEE_TOKEN_FIELD),
modalRef: overlappingModalRef
}}
/>
Expand Down
5 changes: 4 additions & 1 deletion src/pages/AMM/Pools/components/WithdrawForm/WithdrawForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,10 @@ const WithdrawForm = ({ pool, overlappingModalRef, onSuccess, onSigning }: Withd
<Flex direction='column' gap='spacing4'>
<TransactionFeeDetails
{...transaction.fee.detailsProps}
selectProps={{ ...form.getFieldProps(POOL_WITHDRAW_FEE_TOKEN_FIELD), modalRef: overlappingModalRef }}
selectProps={{
...form.getSelectFieldProps(POOL_WITHDRAW_FEE_TOKEN_FIELD),
modalRef: overlappingModalRef
}}
/>
<AuthCTA type='submit' size='large' disabled={isBtnDisabled}>
{t('amm.pools.remove_liquidity')}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ const CollateralModal = ({ asset, position, onClose, isOpen, ...props }: Collate
<TransactionFeeDetails
{...transaction.fee.detailsProps}
selectProps={{
...form.getFieldProps(LOAN_TOGGLE_COLLATERAL_FEE_TOKEN_FIELD),
...form.getSelectFieldProps(LOAN_TOGGLE_COLLATERAL_FEE_TOKEN_FIELD),
modalRef: overlappingModalRef
}}
/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ const LoanForm = ({ asset, variant, position, overlappingModalRef, onChangeLoan
)}
<TransactionFeeDetails
{...transaction.fee.detailsProps}
selectProps={{ ...form.getFieldProps(LOAN_FEE_TOKEN_FIELD), modalRef: overlappingModalRef }}
selectProps={{ ...form.getSelectFieldProps(LOAN_FEE_TOKEN_FIELD), modalRef: overlappingModalRef }}
/>
<AuthCTA type='submit' disabled={isBtnDisabled} size='large'>
{content.title}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ const LoansInsights = ({ statistics }: LoansInsightsProps): JSX.Element => {
<TransactionFeeDetails
{...transaction.fee.detailsProps}
selectProps={{
...form.getFieldProps(LOAN_CLAIM_REWARDS_FEE_TOKEN_FIELD),
...form.getSelectFieldProps(LOAN_CLAIM_REWARDS_FEE_TOKEN_FIELD),
modalRef: overlappingModalRef
}}
/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ const DepositCollateralStep = ({
<TransactionFeeDetails
{...transaction.fee.detailsProps}
selectProps={{
...form.getFieldProps(VAULTS_DEPOSIT_COLLATERAL_FEE_TOKEN_FIELD),
...form.getSelectFieldProps(VAULTS_DEPOSIT_COLLATERAL_FEE_TOKEN_FIELD),
modalRef: overlappingModalRef
}}
/>
Expand Down

2 comments on commit 9a3f495

@vercel
Copy link

@vercel vercel bot commented on 9a3f495 Jul 6, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vercel
Copy link

@vercel vercel bot commented on 9a3f495 Jul 6, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.