-
Notifications
You must be signed in to change notification settings - Fork 51
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
Update transfer alert to display fee information #182
Conversation
Deploy preview for kind-kilby-95344f processing. Building with commit ead41b9 https://app.netlify.com/sites/kind-kilby-95344f/deploys/5c59bf86112207000811b535 |
@patitonar what the content of the window will be if we have no fees configured on the bride at all? |
@akolotov If no fees are configured, the window will remain as it was before, without any mention to fees. |
thanks!
My understanding is that we have three main cases:
So, does it make sense to introduce a method on the Fee Manager side that will inform about support of one of this case?
And the first case will be handled by the check if the Fee Manager (below as FM) contract address is set in the bridge contract. So, we will have the following combinations
Moreover for the case when we have the Fee Manager on one side but working in both direction I would suggest to have to separate variables that keep the fee for different direction. We have them configured differently in the What do you think? |
I agree with the proposed changes, they will allow us to use the correct fee to display the information. I'll work on the contracts to:
After those changes are done. We should update this implementation to work as explained in your comment |
I have created omni/tokenbridge-contracts#148 for this item. |
Created omni/tokenbridge-contracts#149 to address this. |
@akolotov Updated the code to use the new methods from contracts After changes on contracts are merge to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is my understanding correct and if we merge in develop
this as is the UI will be broken? If no, I am OK to merge this. Otherwise let's have a separate branch for this feature until we have the contracts merged to develop
.
There is no issue on merging this to |
Updated transfer alert to display fee information if contracts are using them. The values were updated to show the real value the user is going to receive on the other network.
From the contracts we can know if there are fees implemented on each sides, but there is no way to know which fee will be applied in the direction of the transfer the user is submitting. So for this implementation, we use home fee, and if not present, will use foreign fee to calculate values to display on transfer alert.
Let me know if you think we should add some text or display fee information in a different way.
It seems that there are some issues of caching on Travis CI, I had to disable caching of node_modules on travis configuration to make it work
closes #163