-
Notifications
You must be signed in to change notification settings - Fork 163
Feat/send-taro-asset #656
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/send-taro-asset #656
Conversation
56dbb36
to
35110f8
Compare
Initial first pass on the UX.
This PR can now be rebased to drop the duplicate commits. |
887b71a
to
62311d0
Compare
Awesome, thanks for this feed back. I was thinking the same thing about #4 today too. |
Thanks for the updates. This is much better. Just a couple remaining suggestions:
Once these updates are made, this PR will be ready for code review. Please don't forget to rebase. |
85b7d08
to
ea48f71
Compare
Added tarp send asset functionality.
9480c7e
to
2ed4503
Compare
Fixed test to check for label to deposit enough funds for mint asset modal
NewAddressResponse renamed to AddressResponse
Hey, after the rebase I'm having trouble with the decode throwing an error. I will investigate and fix. |
The diff looks pretty good after the rebase. Let me know when you're ready for me to do another review. |
I think it was a bad refresh. I just took it for a spin and had successful sends. |
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.
For the UX, the comments from my last review still remain. Also, i think it would be better to put "Send Asset" at the top of the context menu and Actions sidebar since I suspect this would be the most used action.
I did an initial pass over the code. Can you try to work on more tests to get coverage over all the new code paths. Just run yarn ci
to see which lines in the code aren't covered. You can also open the generated ./coverage/lcov-report/index.html
file in a browser to get a more detailed look at the coverage of each file.
Hit notes and made sure tests hit coverage.
Cleaned up the tests
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.
Functionality is still good but I have some suggestions for your updates.
Also, there's still linter warnings and code not covered by tests. Remember to run yarn ci
to find these locally.
linting errors, missing parameter, and testing conventions
Sorry for missing those linter errors. Is there away I can configure git to not submit unless the linter passes? |
The current husky config only prevents committing when there are linter errors, not warnings. I'm fine with adding warnings since it'll make it easier to catch those as well. You can do it in this branch by changing the eslint command to The coverage is still not at 100 in all 4 columns. Are you still working on this? If you are unable to figure out how to test all code paths, please let me know which specific issues you're facing and I'll try to help. |
addItemIf( | ||
'sendAsset', | ||
<SendAssetButton type={'menu'} node={node as TaroNode} />, | ||
isStarted && isTaro, | ||
), |
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.
I mentioned in the previous review: i think it would be better to put "Send Asset" at the top of the context menu and Actions sidebar since I suspect this would be the most used action.
@@ -24,6 +24,7 @@ const ActionsTab: React.FC<Props> = ({ node }) => { | |||
<> | |||
<MintAssetButton node={node} /> | |||
<NewAddressButton node={node} /> | |||
<SendAssetButton node={node} /> |
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.
Move this to the top of the list as well.
I am actually struggling to hit some code paths. Sometimes it's with if statements, I looked it up on google, and it has something to do when an if is missing an else statement after. I'll give it another shot asap. example:
This was the reason for the previous
The above has better coverage results. |
Send asset is at the top now.
This is ready to review. 100% code coverage. Excellent learning experience. Thanks for taking the time on this and for all the added tests you did in the previous commit to bring the coverage up. Moving forward Ill make sure all prs have 100% coverage. |
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.
This looks good to go! Great work on the PR. Thanks for continuing to iterate on it.
SendAssetModal is blocked out.
Description
Rework from our previous conversations. I can't really see this being more than this, all that send asset needs is the taro address which seems a lot like an lnd invoice.
I want to put a menu on the bottom to help create a quick address like I did on the new address form. I'm thinking of the same idea, a collapsible one that allows you to select a taro node, asset, and amount to populate the address field.
This is branched from new-address-modal