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

Pass labels from asset list to asset-list-item #184

Merged
merged 3 commits into from
May 19, 2024

Conversation

faneaatiku
Copy link
Contributor

labels can not be changed and the items always use the default values. They need to be passed from the list. This is the quick solution i found but there might be more elegant ones.

besides, I'm thinking button intent should be customizable too... Or the entire button. I'm open to hear sugestions and if I have time I'll try to submit a PR.

labels can not be changed and the items always use the default values. They need to be passed from the list. This is the quick solution i found but there might be more elegant ones. 

besides, I'm thinking button intent should be customizable too... Or the entire button. I'm open to hear sugestions and if I have time I'll try to submit a PR.
@@ -65,6 +65,8 @@ export default function AssetList(props: AssetListProps) {
showWithdraw={item.showWithdraw}
onDeposit={() => item?.onDeposit()}
onWithdraw={() => item?.onWithdraw()}
withdrawLabel={item.withdrawLabel ?? AssetListItem.defaultProps.withdrawLabel}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good, but I don't think you need the last bit ?? AssetListItem.defaultProps.withdrawLabel, AssetListItem already has default props for those :) remove those and I'll get it published

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done. thanks for the review

@yyyyaaa yyyyaaa merged commit 759d455 into cosmology-tech:main May 19, 2024
@yyyyaaa
Copy link
Contributor

yyyyaaa commented May 19, 2024

@faneaatiku published in 1.23.13, thanks for the PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants