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

DataViews: (List view) Only one primary action is shown, and there is a offset #66814

Closed
2 of 8 tasks
doekenorg opened this issue Nov 7, 2024 · 2 comments · Fixed by #67778
Closed
2 of 8 tasks

DataViews: (List view) Only one primary action is shown, and there is a offset #66814

doekenorg opened this issue Nov 7, 2024 · 2 comments · Fixed by #67778
Assignees
Labels
[Feature] DataViews Work surrounding upgrading and evolving views in the site editor and beyond [Status] In Progress Tracking issues with work in progress [Type] Bug An existing feature does not function as intended

Comments

@doekenorg
Copy link

Description

On the list view, only the first primary action is shown. Others are only visible in the action dropdown menu. But that menu is also hidden by a visual offset. So it's not apparent there is even more.

So two bugs:

  • All primary actions should be shown
  • The action dropdown button should be visible

Step-by-step reproduction instructions

  1. Add multiple primary actions
  2. See the list view

Screenshots, screen recording, code snippet

I've reproduced this on the storybook:

Image

Environment info

No response

Please confirm that you have searched existing issues in the repo.

  • Yes

Please confirm that you have tested with all plugins deactivated except Gutenberg.

  • Yes

Please confirm which theme type you used for testing.

  • Block
  • Classic
  • Hybrid (e.g. classic with theme.json)
  • Not sure
@doekenorg doekenorg added the [Type] Bug An existing feature does not function as intended label Nov 7, 2024
@oandregal oandregal added the [Feature] DataViews Work surrounding upgrading and evolving views in the site editor and beyond label Nov 7, 2024
@oandregal
Copy link
Member

The action dropdown button should be visible

What WordPress & Gutenberg versions do you have? I cannot reproduce with WordPress 6.6/6.5 (with or without Gutenberg 19.6 active).

All primary actions should be shown

This is intentional. The list view has very few space so we limited to a single one. This may change in the future, but it's not a bug.

@doekenorg
Copy link
Author

The action dropdown button should be visible

What WordPress & Gutenberg versions do you have? I cannot reproduce with WordPress 6.6/6.5 (with or without Gutenberg 19.6 active).

This is reproduced on the storybook. https://wordpress.github.io/gutenberg/?path=/docs/dataviews-dataviews--docs If you check the first one, and switch to List layout; you see this happening. Locally I had the same with the latest branch. I didn't test this on the WordPress components, but on DataKit we have the same issue. I'm pretty sure this will be another css discrepancy.

All primary actions should be shown

This is intentional. The list view has very few space so we limited to a single one. This may change in the future, but it's not a bug.

Ok, I wasn't aware of that limitation on a List. I guess it depends on the amount of data on the list. In that case it might be useful to have influence on the actions on the layout type. Where isPrimary is a callback, that at least receives the current layout context. Then you can make a choice which Primary action should stay. (just thinking out loud).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] DataViews Work surrounding upgrading and evolving views in the site editor and beyond [Status] In Progress Tracking issues with work in progress [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants