Skip to content

Commit

Permalink
fix: update order form to conditionally set isApproximately based on …
Browse files Browse the repository at this point in the history
…asset amounts

# Conflicts:
#	src/pages/trade/ui/order-form/order-form-market.tsx
  • Loading branch information
vacekj committed Dec 18, 2024
1 parent 82ff5f4 commit 390c851
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/pages/trade/ui/order-form/order-form-market.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ export const MarketOrderForm = observer(({ parentStore }: { parentStore: OrderFo
value={store.baseInput}
onChange={store.setBaseInput}
isEstimating={store.baseEstimating}
isApproximately={isBuy}
isApproximately={isBuy && baseAsset.amount !== 0}

Check failure on line 69 in src/pages/trade/ui/order-form/order-form-market.tsx

View workflow job for this annotation

GitHub Actions / Lint

Cannot find name 'baseAsset'.
denominator={store.baseAsset?.symbol}
/>
</div>
Expand All @@ -76,7 +76,7 @@ export const MarketOrderForm = observer(({ parentStore }: { parentStore: OrderFo
value={store.quoteInput}
onChange={store.setQuoteInput}
isEstimating={store.quoteEstimating}
isApproximately={!isBuy}
isApproximately={!isBuy && quoteAsset.amount !== 0}

Check failure on line 79 in src/pages/trade/ui/order-form/order-form-market.tsx

View workflow job for this annotation

GitHub Actions / Lint

Cannot find name 'quoteAsset'.
denominator={store.quoteAsset?.symbol}
/>
</div>
Expand Down

0 comments on commit 390c851

Please sign in to comment.