liquid-long-client's People
liquid-long-client's Issues
When exchange costs are 0, subtotal doesn't work.
Consider: Adjust chart gradient based on leverage.
As the user slides the leverage around, the gradient should follow the lines as you move them around, so it is more clear how compressed/expanded the upside and downside are.
Confirm page should link to CDP.
When the user completes their transaction, they should be given a link out to Maker UI so they can see their new CDP.
3x leverage doesn't push the current price line down to the bottom of the chart.
Going back from fail/success page results in price delaying showing up.
I believe this has to do with the 10 second polling interval for price updates. For some reason, when we route away from that page and then back it doesn't pull down the last observed value for price and instead waits until a new price is pushed in.
Disable exchange costs slider and set tiny default values.
The exchange cost currently defaults to 0-250 and starts in the middle, which is silly. Also, the slider is dragable before it can actually function.
Recommend disabling the cost component until the user fills in the first two components, then enabling it once it is changeable. We should also disable the confirm button until after this point as well.
Set max leverage based on contract WETH balance.
The UI should adjust the maximum leverage to be based on how much WETH is in the contract. By setting it to WETH/2, we can ensure there will be enough to cover their position no matter how big it is. This would solve 3 problems:
- When we drain the contract during an upgrade, it will result in letting the user know they can't open a position.
- As the contract accumulates WETH from fees, the limit will increase.
- If we add WETH to the contract it will correctly decrease the limit.
Turn exchange cost component into a spinner while loading.
When you change the leverage amount or leverage size we have to do an eth_call
to update the exchange costs. We should make it clear to the user that they are waiting on something so they don't rush ahead without seeing the exchange cost (we'll auto-change their cost when the call returns, which could result in unexpected costs for the user if they don't notice the change).
If user hits "Try again" on fail page, the "authorize MM" banner doesn't appear.
- Don't allow access to MetaMask.
- Try to create a CDP.
- Refuse access again.
- On error page, click Try again.
--> Notice that you no longer have the "please authorize" banner.
Consider: a zoom slider on chart
A Google Maps zoom style slider or buttons on the right side of the chart that adjusts what the top of the chart represents. Defaults to 100%, but you can adjust it to 1000%, or 10,000% if you want to dream about moons. Not a super useful feature for technical users, but a fun one that may incentivize more poorly thought out usage.
Change chart legend for 0% of your money.
This is the starting point, and a user trying to figure out how to use the graph should be guided better that that is where they started with.
Change exchange costs wording.
We can hard-code exchange costs to the min we calculate and change the slider to something like "Slippage Protection". Perhaps this would make it more clear to new users that adjusting the slider up is protecting them from price movements while they wait for their transaction to mine, rather than a cost they will pay.
Consider: Hide exchange costs in an advanced dropdown and instead show
Exchange costs are complicated, and most users will just choose the minimum. There is no need to have the information so much in their face.
Don't prompt for MetaMask access until necessary.
We should not be asking for MetaMask access until the user actually needs it, which is at open position time.
Put amount first, leverage second in the UI.
We can fill in a reasonable default for leverage and exchange costs, but we cannot have a reasonable default for amount. If we put amount first, the user could create a reasonable leveraged position by filling in a single value, and that should be the first interaction point.
Link to makerscan.io instead of mkr.tools.
PRO: https://makerscan.io/cups/5675/ has similar info as mkr.tools, but it also has CDP management functions.
CON: Such an external link could be seen as an endorsement, and if makerscan.io is malicious or hacked users will blame us. With mkr.tools, people have to find their own place to go to manage their CDP, which means they can't blame us when they end up someplace sketchy.
Long term we'll have our own management interface, but that is a ways off and changing the link is a quick thing.
Switch to anchor routing instead of path routing.
Since we host the site with IPFS, if someone tries to navigate to a deep link (e.g., fail or success page) the request will fail because IPFS can't resolve the path. If we use anchor routing instead, then the request will be for the base page and the routing will occur entirely client side.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.