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

#3463 Master offers component

Open prachi00 opened this issue 2 years ago β€’ 11 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 #3463
  • [ ] Requires deployment <rubick/magick_issue>
  • [x] route is /bsx/offers

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. Screen Shot 2022-08-06 at 5 17 53 PM

Screen Shot 2022-08-06 at 5 15 58 PM

prachi00 avatar Aug 07 '22 00:08 prachi00

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

kodabot avatar Aug 07 '22 00:08 kodabot

Deploy Preview for koda-nuxt ready!

Name Link
Latest commit 7f03f212413b875821958f5731e439027e1ceccc
Latest deploy log https://app.netlify.com/sites/koda-nuxt/deploys/6309eb1d46126e000a6ae253
Deploy Preview https://deploy-preview-3692--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 Aug 07 '22 00:08 netlify[bot]

tested without wallet logged in, received 400 network error, pls check

petersopko avatar Aug 08 '22 09:08 petersopko

https://deploy-preview-3692--koda-nuxt.netlify.app

where? because if you are not logged in, then the option is hidden Screen Shot 2022-08-08 at 1 04 47 PM

prachi00 avatar Aug 08 '22 20:08 prachi00

So some feedback after checking this more thoroughly:

  1. the tabs should be filter (F2) with two options as described in the issue, but let's make it three with first one being All offers, dropdown as the one for the offer status (F1). If there isn't valid address inserted, the F2 can be disabled dropdown (stuck at All offers), becoming enabled once there's valid address, giving two more filtering options, i.e. Offers Created and Incoming Offers

  2. logged out user should be able to land at this page, and still see all of the offers (without entering address), data should be fetched the same way as in /bsx/stats

  3. the entry field for address doesn't need Check offers button next to it, it could be 2 sec debounce and offers can be fetched once there's valid address

petersopko avatar Aug 09 '22 10:08 petersopko

So some feedback after checking this more thoroughly:

  1. the tabs should be filter (F2) with two options as described in the issue, but let's make it three with first one being All offers, dropdown as the one for the offer status (F1). If there isn't valid address inserted, the F2 can be disabled dropdown (stuck at All offers), becoming enabled once there's valid address, giving two more filtering options, i.e. Offers Created and Incoming Offers
  2. logged out user should be able to land at this page, and still see all of the offers (without entering address), data should be fetched the same way as in /bsx/stats
  3. the entry field for address doesn't need Check offers button next to it, it could be 2 sec debounce and offers can be fetched once there's valid address

Regarding 2nd, can logged out users see the input box?

prachi00 avatar Aug 10 '22 01:08 prachi00

also initially, when the user reloads, there will be address in the input box and option will be all, so wouldn't it be confusing that what the address id doing?

prachi00 avatar Aug 10 '22 01:08 prachi00

can logged out users see the input box?

yes

also initially, when the user reloads, there will be address in the input box and option will be all, so wouldn't it be confusing that what the address id doing?

Hmm maybe we don't understand each other here, if there will be an address in the input field, you will be fetching all of the offers related to the address (incoming offers and made offers), if there isn't address, you're fetching all of the offers.

petersopko avatar Aug 10 '22 09:08 petersopko

Also, if logged out users can see the input box, can they enter address and view incoming or created? because I was under the assumption that they cant do that

prachi00 avatar Aug 10 '22 18:08 prachi00

Also, if logged out users can see the input box, can they enter address and view incoming or created? because I was under the assumption that they cant do that

@petersopko ⬆️

prachi00 avatar Aug 11 '22 20:08 prachi00

Also, if logged out users can see the input box, can they enter address and view incoming or created? because I was under the assumption that they cant do that

yes, they can enter address and view incoming/created. input field is always enabled to enter an address, thing which is disabled is the filter until the valid address it's entered

petersopko avatar Aug 12 '22 07:08 petersopko

@prachi00 any updates on this one? :)

petersopko avatar Aug 15 '22 14:08 petersopko

@prachi00 any updates on this one? :)

sorry about the delay, I was out the whole last week but getting back to this from today

prachi00 avatar Aug 15 '22 17:08 prachi00

@petersopko initially when the user first opens it, should they see their own offers or general offers same as stats?

prachi00 avatar Aug 17 '22 05:08 prachi00

@petersopko initially when the user first opens it, should they see their own offers or general offers same as stats?

to quote from the initial issue description

When the logged-in user visits /bsx/offers it lands on its own address stats by default, i.e. in my case /bsx/offers?u=bXgvP2cQzEnPvuPQHRghz9dUYovqzyPhXBRXbNwVCef7nsmqb where default would be incoming offers

petersopko avatar Aug 17 '22 07:08 petersopko

@petersopko fixed the issues mentioned

prachi00 avatar Aug 18 '22 01:08 prachi00

@petersopko fixed the issues mentioned

Test failed, and deepsource seems to have some kind of problem with the code tho ?

petersopko avatar Aug 18 '22 06:08 petersopko

On mobile it looks like this image

petersopko avatar Aug 18 '22 06:08 petersopko

On mobile it looks like this image

just merged with the main branch, should be fixed now

prachi00 avatar Aug 19 '22 01:08 prachi00

I have fixed the failing tests for you, please check this part of CONTRIBUTING.md for further reference on how to make the tests happy once you change some of the tested subjects :)

petersopko avatar Aug 19 '22 12:08 petersopko

I have fixed the failing tests for you, please check this part of CONTRIBUTING.md for further reference on how to make the tests happy once you change some of the tested subjects :)

got it, thank you for fixing this time, I'll make sure to do it from next time

prachi00 avatar Aug 20 '22 23:08 prachi00

4. Offers

for 1 and 2, I actually depend on the url to fill out the address in the input /bsx/offers?target=bXjGftu3aagU6RzMCKHi66X84jap3RKtvv6t1kxD2KXbJMiG2 because not doing this was creating a lot of edge cases for example, if you erase the input bar to view all the offers and then reload, it would show user's offers again

prachi00 avatar Aug 21 '22 00:08 prachi00

  1. Offers

for 1 and 2, I actually depend on the url to fill out the address in the input /bsx/offers?target=bXjGftu3aagU6RzMCKHi66X84jap3RKtvv6t1kxD2KXbJMiG2 because not doing this was creating a lot of edge cases for example, if you erase the input bar to view all the offers and then reload, it would show user's offers again

@petersopko let me know if this seems okay to you?

prachi00 avatar Aug 23 '22 02:08 prachi00

let's resolve conflicts :)

yangwao avatar Aug 25 '22 17:08 yangwao

let's resolve conflicts :)

done

prachi00 avatar Aug 25 '22 18:08 prachi00

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

View more on Code Climate.

codeclimate[bot] avatar Aug 27 '22 10:08 codeclimate[bot]

@petersopko let me know if this seems okay to you?

it's not ideal, but this issue wasn't defined in great detail, so let's follow up with some tweaks

petersopko avatar Aug 27 '22 11:08 petersopko

pay 150 usd

petersopko avatar Aug 27 '22 11:08 petersopko

😍 Perfect, I’ve sent the payout πŸ’΅ $150 @ 45.38 USD/KSM ~ 3.305 $KSM πŸ§— EzGc4s9PgCPx1YnF3fqzhLzVHpHMTL4LWPScwpDrR8JKgSU πŸ”— 0x6ae7f9ab6b7fc3ea6a5dd18664c064f823e5b730ab15ec746513dc9f50c0c07b

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

yangwao avatar Aug 27 '22 11:08 yangwao