Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(limit): recreate order #3845

Merged
merged 53 commits into from
Feb 29, 2024
Merged

feat(limit): recreate order #3845

merged 53 commits into from
Feb 29, 2024

Conversation

alfetopito
Copy link
Collaborator

@alfetopito alfetopito commented Feb 13, 2024

Summary

Recreate LIMIT orders based on filled/cancelled/expired orders

  • Open on its own modal
  • Separated state (where needed)
    • independent settings
  • Everything else identical to regular limit orders flow
  • Suuuuuper not pretty, out of the scope

To Test

  1. Go to LIMIT orders history
  2. Click on the dot menu
  • Should have recreate order button
    image
  1. Click on it
  • Should load a "pretty" modal with the exact same data as used on the initial order
    image
    • Same sell/buy tokens (should not be changeable)
    • Same sell/buy amounts
    • Order type (buy or sell order)
    • Same duration
    • Same recipient, if any
    • Same sub-type (fill-or-kill OR partially-fillable)
  1. Place order
  • Should take you back to the regular LIMIT orders screen, with the same values you had previously
  • Settings state should remain the same as before
  1. Repeat with different combinations of order type, sub-type, tokens, durations, etc
  2. Placing regular LIMIT orders should remain the same as before
  3. Does not affect SWAP or TWAP, so there shouldn't be any changes there either

Copy link

vercel bot commented Feb 13, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
cosmos ✅ Ready (Inspect) Visit Preview Feb 29, 2024 0:05am
explorer-dev ✅ Ready (Inspect) Visit Preview Feb 29, 2024 0:05am
swap-dev ✅ Ready (Inspect) Visit Preview Feb 29, 2024 0:05am
widget-configurator ✅ Ready (Inspect) Visit Preview Feb 29, 2024 0:05am

* fix: clear existing market rate when alternative limit order form is loaded

* fix: use pure JS numbers math to avoid issue with Fraction division
* feat: progress

* feat: progress

* feat: progress

* feat: progress

* feat: progress

* feat: cleanup
@alfetopito
Copy link
Collaborator Author

There's only 1 pending task related to mobile #3930 (comment)

I'll merge as is, since that can be addressed later.

@alfetopito alfetopito merged commit dd31431 into develop Feb 29, 2024
10 of 11 checks passed
@alfetopito alfetopito deleted the feat/recreate-v2 branch February 29, 2024 13:57
@github-actions github-actions bot locked and limited conversation to collaborators Feb 29, 2024
@alfetopito alfetopito linked an issue Mar 28, 2024 that may be closed by this pull request
6 tasks
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Limit orders] Modify order (cancel+create)
5 participants