Skip to content

Show Estimated Output after fees in swap quote #18

Description

@mcintyre94

Context

The swap quote currently shows Output Value (before fees) and Estimated Cost (price impact + platform fee + network fee) as separate rows. The gain/loss calculation uses outUsdValue - platformFee - networkFee as the effective proceeds, but this isn't shown explicitly to the user.

Proposal

Add an "Estimated Output" row in the fees/costs section, just above the Cost Basis section. This would show:

Estimated Output    $859.49

Calculated as: outUsdValue - platformFeeUSD - networkFeeUSD

This makes the gain/loss calculation more transparent - the user can see the number that their cost basis is being compared against.

Notes

  • Should appear between the Estimated Cost row and the Cost Basis section divider
  • Only meaningful when fees are known; consider what to show when network fee is "Unable to estimate"
  • This is the same value used internally by costBasisMetrics.realizedGainLoss (outUsdValue - fees - totalCostBasis)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions