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

[PUI] Make actions recognisable #8005

Merged

Conversation

matmair
Copy link
Member

@matmair matmair commented Aug 26, 2024

Action Dropdowns are not very recognisable right now. Therefore, I propose adding indicators similar to the screenshots below to buttons with more than 1 action. I am not sure how to style that, below solution is not the final goal - maybe a single indicator could be enough for example.

Current
grafik

Proposed
grafik

Fixes invenhost#98

@matmair matmair added the Platform UI Related to the React based User Interface label Aug 26, 2024
@matmair matmair added this to the 0.17.0 milestone Aug 26, 2024
@matmair matmair self-assigned this Aug 26, 2024
Copy link

netlify bot commented Aug 26, 2024

Deploy Preview for inventree-web-pui-preview ready!

Name Link
🔨 Latest commit f4cb6e0
🔍 Latest deploy log https://app.netlify.com/sites/inventree-web-pui-preview/deploys/66d437ebe8724c00080a20c0
😎 Deploy Preview https://deploy-preview-8005--inventree-web-pui-preview.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 100 (no change from production)
Accessibility: 86 (no change from production)
Best Practices: 92 (no change from production)
SEO: 70 (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

codecov bot commented Aug 27, 2024

Codecov Report

Attention: Patch coverage is 75.00000% with 2 lines in your changes missing coverage. Please review.

Project coverage is 83.63%. Comparing base (1634258) to head (f4cb6e0).
Report is 327 commits behind head on master.

Files with missing lines Patch % Lines
...c/frontend/src/components/items/ActionDropdown.tsx 75.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #8005      +/-   ##
==========================================
+ Coverage   83.57%   83.63%   +0.05%     
==========================================
  Files        1140     1141       +1     
  Lines       50874    50878       +4     
  Branches     1774     1783       +9     
==========================================
+ Hits        42520    42552      +32     
+ Misses       7913     7882      -31     
- Partials      441      444       +3     
Flag Coverage Δ
pui 65.20% <75.00%> (+0.35%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@SchrodingersGat
Copy link
Member

SchrodingersGat commented Aug 27, 2024

Maybe a "down caret" indicator would be clearer here? It seems a bit more "traditional". But I agree with the concept in general

image

@wolflu05
Copy link
Contributor

I like the suggestion from @SchrodingersGat

@matmair
Copy link
Member Author

matmair commented Aug 27, 2024

What do we think about this:
grafik

@SchrodingersGat
Copy link
Member

That's pretty clean IMO

@wolflu05
Copy link
Contributor

wolflu05 commented Aug 27, 2024

I think now its really hard to tell, which "down caret" belongs to what action, maybe an outline would help to add some separation, but not sure how that will look like.

@matmair
Copy link
Member Author

matmair commented Aug 27, 2024

It looks atrocious with an outline
grafik

@wolflu05
Copy link
Contributor

That's true. Maybe its just me having problems to see the separation.

@SchrodingersGat
Copy link
Member

What about a mantine indicator with the caret attached directly to the button

https://mantine.dev/core/indicator/

@matmair
Copy link
Member Author

matmair commented Aug 27, 2024

I find that more confusing than not having them
grafik

@matmair
Copy link
Member Author

matmair commented Aug 27, 2024

I have tried another thing: light
grafik

@matmair
Copy link
Member Author

matmair commented Aug 27, 2024

I find vertical dots also match the flow better:
grafik

@matmair
Copy link
Member Author

matmair commented Aug 27, 2024

And the same thing in dark mode with dots instead of chevrons
grafik

@SchrodingersGat
Copy link
Member

SchrodingersGat commented Aug 27, 2024

Light with chevrons is my pick :)

And maybe we add the chevron to the vertical dot menu too?

@matmair matmair marked this pull request as ready for review August 28, 2024 05:51
@matmair
Copy link
Member Author

matmair commented Aug 28, 2024

Ok then this is ready for merge - light with chevron is the current state of the PR.

And maybe we add the chevron to the vertical dot menu too?

I would not add chevrons to the dot menu, I think that 3 dots are universally understood as "more" - that is why I suggested usage of them in the first place.

@SchrodingersGat
Copy link
Member

I would not add chevrons to the dot menu, I think that 3 dots are universally understood as "more" - that is why I suggested usage of them in the first place.

In this case, should we add a special dropdown menu just for the "more" actions - I see that you have added a lot of instances of noindicator - this could be refactored into a special dropdown with the dots icon and no indicator?

@matmair
Copy link
Member Author

matmair commented Aug 29, 2024

Sure, I can look into that.

@matmair
Copy link
Member Author

matmair commented Sep 1, 2024

@SchrodingersGat I have added a special dropdown to adress this

@matmair
Copy link
Member Author

matmair commented Sep 2, 2024

@SchrodingersGat this is ready for review and merge

@SchrodingersGat
Copy link
Member

Nice work, thanks for this!

@SchrodingersGat SchrodingersGat merged commit 355b493 into inventree:master Sep 3, 2024
26 checks passed
@SchrodingersGat SchrodingersGat deleted the pui-make-actions-recognisable branch September 3, 2024 03:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Platform UI Related to the React based User Interface refactor
Projects
None yet
Development

Successfully merging this pull request may close these issues.

System: A lot of dropdowns look like single actions
3 participants