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

multiple personas clickable [Fixes #12645] #12753

Merged
merged 12 commits into from
Sep 2, 2024

Conversation

bhargavkakadiya
Copy link
Contributor

@bhargavkakadiya bhargavkakadiya commented Apr 17, 2024

Description

Allows multi select for personas
image

For display of wallet tables, when multiple personas are selected, filters are applied after applying AND on all persona preset filters from useWalletPersonas.tsx

The current filtering logic for displaying results is open for review. I welcome any suggestions or requirements for adjustments to ensure the functionality meets our needs

Preview link

https://deploy-preview-12753--ethereumorg.netlify.app/en/wallets/find-wallet

Related issue

@github-actions github-actions bot added needs review 👀 tooling 🔧 Changes related to tooling of the project labels Apr 17, 2024
Copy link

netlify bot commented Apr 17, 2024

Deploy Preview for ethereumorg ready!

Name Link
🔨 Latest commit b84b6fc
🔍 Latest deploy log https://app.netlify.com/sites/ethereumorg/deploys/66b06b5c1e66500008ac4525
😎 Deploy Preview https://deploy-preview-12753--ethereumorg.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
7 paths audited
Performance: 44 (🔴 down 7 from production)
Accessibility: 93 (no change from production)
Best Practices: 91 (🔴 down 8 from production)
SEO: 92 (no change from production)
PWA: -
View the detailed breakdown and full score reports

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

Copy link
Member

@wackerow wackerow left a comment

Choose a reason for hiding this comment

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

Thanks @bhargavkakadiya! First glance looks like a great start, but per original issue (#12645):

Switch logic to "AND" and allow users to select multiple personas.

Looks like the logic here results in an "OR" result where it'll filter wallets that match a persona OR filters that match another persona (widening results with more checks)...

@konopkja Am I correct that we want to narrow the results as more checkboxes are added?

@konopkja
Copy link
Contributor

Thanks @bhargavkakadiya! First glance looks like a great start, but per original issue (#12645):

Switch logic to "AND" and allow users to select multiple personas.

Looks like the logic here results in an "OR" result where it'll filter wallets that match a persona OR filters that match another persona (widening results with more checks)...

@konopkja Am I correct that we want to narrow the results as more checkboxes are added?

Thanks for the contribution!!! yeas our goal is to narrow down

@bhargavkakadiya
Copy link
Contributor Author

@wackerow @konopkja
Thanks for the review and inputs, I will update the logic

@bhargavkakadiya
Copy link
Contributor Author

@wackerow I have updated to show narrowed results, can you please review it again?

@konopkja
Copy link
Contributor

ping @corwintines @wackerow

@nhsz
Copy link
Member

nhsz commented Apr 30, 2024

@bhargavkakadiya in this example, end result should be 4 wallets or less, as it was narrowed to 4 when clicking the mobile filter

Kapture 2024-04-30 at 14 21 44

@wackerow
Copy link
Member

wackerow commented May 7, 2024

So close! This is definitely nuanced logic... @bhargavkakadiya Replicated Nico's steps above and it kept narrowing down appropriately, but when I uncheck the "Finance" persona, the filters do not broaden again, and the results stay filtered to only three:

Screen.Recording.2024-05-07.at.14.17.15.mov

@corwintines corwintines self-assigned this May 7, 2024
@bhargavkakadiya
Copy link
Contributor Author

In this current version, the broadening is working upon deselecting persona.

Also, based on the example below, when mobile is checked, it checks Android and iOS, which is fine.
But, when persona Finance is unchecked, it unchecks Android and iOS as well, but mobile is still checked. I will have to work on this yet, haven't figured easy fix for that yet

Screencast.from.05-14-2024.09.46.36.AM.webm

@wackerow
Copy link
Member

Hey @bhargavkakadiya, just circling through. Any luck here? Can open this up to others in the community if needed

@wackerow wackerow added the help wanted Extra attention is needed or someone is needed to help label Jun 17, 2024
@wackerow wackerow marked this pull request as draft June 18, 2024 23:16
@wackerow
Copy link
Member

Flipping to draft for now, please flip to "Ready for review" when ready

@corwintines
Copy link
Member

Just going to leave my 2 cents here.

I think as far as the multiple personas standpoint, I think this works great. Nice work @bhargavkakadiya.

One thing that needs to be ironed out is what happens if someone selects a filter after a persona. IMO, I think the personas should deselect, but keep the applied filters. @konopkja what do you think?

I will bring this up in grooming next week to get on the same page here so we can get this across the finish line, but Just wanted to say great work @bhargavkakadiya.

@konopkja
Copy link
Contributor

konopkja commented Jul 4, 2024

Just going to leave my 2 cents here.

I think as far as the multiple personas standpoint, I think this works great. Nice work @bhargavkakadiya.

One thing that needs to be ironed out is what happens if someone selects a filter after a persona. IMO, I think the personas should deselect, but keep the applied filters. @konopkja what do you think?

I will bring this up in grooming next week to get on the same page here so we can get this across the finish line, but Just wanted to say great work @bhargavkakadiya.

Hi, its great to see progress here!

I think from clarity perspective it is not a good experience to deselect personas because there is no indication the system would behave this way (end user doesnt know personas and filters are connected unless they notice filters being activated, which may be complicated on mobile to depend on that).

Instead expected system behavior should be to keep persona filter on and ADD to the selected filters another filter that has been activated.

@bhargavkakadiya
Copy link
Contributor Author

Thanks for the kind words; please do let me know if you want me to make any additional changes

@corwintines
Copy link
Member

Hey @bhargavkakadiya.

Thanks for everything you've done so far here, this is close. Chatted with @konopkja to scope out last bit of functionality here to get this over the finish line.

At the moment the selection and deselection of personas works great.

What functionality needs to be added now is just around what happens if someone adds or removes other filters.

  • If user deselects something that is supposed to be true for a persona(s), then we deselect persona(s). Otherwise, we keep personas selected. You can add to filters for a persona, but can't have less. For example: NFT's wallet has nft_support, connect_to_dapps, and layer_2 true. If I were to select the filter swaps as well for example, the NFT persona would stay selected. But, if I remove either nft_support, connect_to_dapps, or layer_2, then the NFT persona gets deselected.
    • edge cases: If we have multiple personas selected, and we deselect a filter, the persona with that filter should be deselected, but keep the other one selected.
  • New to crypto persona make all filters false, except new_to_crypto in https://github.com/bhargavkakadiya/ethereum-org-website/blob/3ca6c7fa1992f900a81b5dcfc0672e7123d7a905/src/hooks/useWalletPersonas.tsx#L7
  • Confirm the New to crypto persona is working. Noticing this isn't matching production in this PR.

Let me know if you have any questions around this, or if anything is unclear.

@wackerow wackerow added feature ✨ This is enhancing something existing or creating something new and removed tooling 🔧 Changes related to tooling of the project labels Jul 14, 2024
@github-actions github-actions bot added the tooling 🔧 Changes related to tooling of the project label Aug 1, 2024
@bhargavkakadiya bhargavkakadiya marked this pull request as ready for review August 5, 2024 07:00
@bhargavkakadiya
Copy link
Contributor Author

bhargavkakadiya commented Aug 7, 2024

@corwintines I have pushed the requested changes. There was a bug for new to crypto persona selection; should be fine now. Please review and let me know if it needs any fixes

@konopkja
Copy link
Contributor

lgtm! @corwintines what should be the next steps?

@corwintines corwintines merged commit 69cdf4e into ethereum:dev Sep 2, 2024
7 of 11 checks passed
@bhargavkakadiya
Copy link
Contributor Author

thank you @konopkja @corwintines @wackerow for your patience. Appreciate all your feedback and helping with the contribution

This was referenced Sep 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature ✨ This is enhancing something existing or creating something new help wanted Extra attention is needed or someone is needed to help Status: Blocked 🛑 This is blocked tooling 🔧 Changes related to tooling of the project
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feature request: multiple personas clickable on list of wallets
5 participants