nft-gallery icon indicating copy to clipboard operation
nft-gallery copied to clipboard

feat: Update minter for BSX so royalty can have 2 decimal places

Open Jarsen136 opened this issue 2 years ago β€’ 9 comments

Thank you for your contribution to the KodaDot NFT gallery. πŸ‘‡ _ Let's make a quick check before the contribution.

PR type

  • [ ] Bugfix
  • [x] Feature
  • [ ] Refactoring

What's new?

  • [x] PR closes #4005, closes #4000
  • [ ] Requires deployment <rubick/magick_issue>
  • [ ] <brief_description_of_what_I've_added>

Before submitting Pull Request, please make sure:

  • [x] My contribution builds clean without any errors or warnings
  • [x] I've merged recent default branch -- main and I've no conflicts
  • [x] I've tried to respect high code quality standards
  • [x] I've didn't break any original functionality
  • [x] I've posted a screenshot of demonstrated change in this PR

Optional

  • [ ] I've tested it at </rmrk/collection/26902bc2f7c20c546a-1FVG7>
  • [ ] I've tested PR on mobile and everything seems works
  • [ ] I found edge cases
  • [ ] I've written some unit tests πŸ§ͺ

Had issue bounty label?

  • [x] Fill up your KSM address: Payout

Community participation

Screenshot

  • [x] My fix has changed something on UI; a screenshot is best to understand changes for others.
image

Jarsen136 avatar Sep 23 '22 01:09 Jarsen136

SUCCESS @Jarsen136 PR for issue #4005 which is assigned to you. Please wait for review and don't hesitate to grab another issue in the meantime!

kodabot avatar Sep 23 '22 01:09 kodabot

Deploy Preview for koda-nuxt ready!

Name Link
Latest commit c2de8218e7db9d442b57c7ba234a0e5234e5310d
Latest deploy log https://app.netlify.com/sites/koda-nuxt/deploys/6331ac79beeefd00083db6d3
Deploy Preview https://deploy-preview-4008--koda-nuxt.netlify.app
Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

netlify[bot] avatar Sep 23 '22 01:09 netlify[bot]

minted NFT with 10.11 royalty rate no problem, doesn't load on deploy (https://deploy-preview-4008--koda-nuxt.netlify.app/snek/gallery/659233203-1), but after trying to open it on local I get this: image

petersopko avatar Sep 23 '22 05:09 petersopko

minted NFT with 10.11 royalty rate no problem, doesn't load on deploy (https://deploy-preview-4008--koda-nuxt.netlify.app/snek/gallery/659233203-1), but after trying to open it on local I get this

Thanks for the test. Already fixed it. image

Jarsen136 avatar Sep 23 '22 05:09 Jarsen136

Thanks for the test. Already fixed it.

in the meantime I found out that this was actually also problem on beta, and not a problem with this specific PR. perhaps related to some of the latest snek changes

petersopko avatar Sep 23 '22 05:09 petersopko

perhaps related to some of the latest snek changes

Yes, it's because of the change of decimals of royalty.

Jarsen136 avatar Sep 23 '22 06:09 Jarsen136

setting royalty rate to 0 isn't permitted? image

petersopko avatar Sep 23 '22 06:09 petersopko

setting royalty rate to 0 isn't permitted?

Yup, the minimum limit is 0.01%. Could royalty be 0? I'm not sure about it. @petersopko

Jarsen136 avatar Sep 23 '22 10:09 Jarsen136

setting royalty rate to 0 isn't permitted?

Yup, the minimum limit is 0.01%. Could royalty be 0? I'm not sure about it. @petersopko

I found that in the original code, it limits the royalty to be greater than zero.

image

Jarsen136 avatar Sep 23 '22 15:09 Jarsen136

I'm minting okay, just one last thing regarding the UX, I think it's a little bit of overkill to set the steps to 0.01%, moving up 1% requires me to either type it or tap/click 100 times πŸ˜„ can we set it to 0.10% per step?

petersopko avatar Sep 25 '22 12:09 petersopko

I'm minting okay, just one last thing regarding the UX, I think it's a little bit of overkill to set the steps to 0.01%, moving up 1% requires me to either type it or tap/click 100 times πŸ˜„ can we set it to 0.10% per step?

Good idea! βœ… Done

Jarsen136 avatar Sep 25 '22 15:09 Jarsen136

Good idea! βœ… Done

sorry to be a nitpicker but now the user doesn't see there's a possibility to add 0.01% difference (I guess zeros get hidden), can we alter the way we present the numbers there, i.e. always show 0.01% difference (even with zero?) image

petersopko avatar Sep 26 '22 07:09 petersopko

sorry to be a nitpicker but now the user doesn't see there's a possibility to add 0.01% difference (I guess zeros get hidden), can we alter the way we present the numbers there, i.e. always show 0.01% difference (even with zero?)

How about setting the default value to 0.15% ?

image

Jarsen136 avatar Sep 26 '22 13:09 Jarsen136

Code Climate has analyzed commit c2de8218 and detected 0 issues on this pull request.

View more on Code Climate.

codeclimate[bot] avatar Sep 26 '22 13:09 codeclimate[bot]

How about setting the default value to 0.15% ?

I think it'll work for now πŸ˜„

petersopko avatar Sep 27 '22 09:09 petersopko

pay 50 usd

petersopko avatar Sep 27 '22 09:09 petersopko

😍 Perfect, I’ve sent the payout πŸ’΅ $50 @ 44.68 USD/KSM ~ 1.119 $KSM πŸ§— Caiv9TbPz68q5dC8EcHu5xKYPRnremimGzqmEejDFNpWWLG πŸ”— 0x2fb4729f55caeae55b9f6519ccce4f802e5820a1c5dc0200af4ac5d733784498

πŸͺ… Let’s grab another issue and get rewarded! πŸͺ„ github.com/kodadot/nft-gallery/issues

yangwao avatar Sep 27 '22 09:09 yangwao

isRoyaltyValid is used to know if you need to make a addiotional call :) so input should take also zero

vikiival avatar Sep 27 '22 13:09 vikiival

isRoyaltyValid is used to know if you need to make a addiotional call :) so input should take also zero

: ) I will fix it

Jarsen136 avatar Sep 27 '22 13:09 Jarsen136