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

Data views: allow users/consumers to pin rows in table layout #64678

Open
jameskoster opened this issue Aug 21, 2024 · 7 comments
Open

Data views: allow users/consumers to pin rows in table layout #64678

jameskoster opened this issue Aug 21, 2024 · 7 comments
Assignees
Labels
[Feature] DataViews Work surrounding upgrading and evolving views in the site editor and beyond Needs Design Needs design efforts. [Type] Enhancement A suggestion for improvement.

Comments

@jameskoster
Copy link
Contributor

jameskoster commented Aug 21, 2024

Related #57669

A pinned row would be positioned first in the list of rows, and remain visible regardless of scroll position.

@jameskoster jameskoster added [Type] Enhancement A suggestion for improvement. Needs Design Needs design efforts. [Feature] DataViews Work surrounding upgrading and evolving views in the site editor and beyond labels Aug 21, 2024
@vcanales vcanales self-assigned this Sep 25, 2024
@priethor
Copy link
Contributor

To clarify, should pinning be limited to rows at the top of the table (e.g. like Google Docs does)? Otherwise, it will create confusion when sorting.

@jameskoster
Copy link
Contributor Author

jameskoster commented Sep 30, 2024

Otherwise, it will create confusion when sorting.

In this case I think the purpose of pinning is to ensure that the chosen items are always within reach, so it's kind of implied that sorting will be ignored for those items. It will be important to communicate in the design which items are pinned so that users can reason about the sorting. We've begun exploring this a bit in #65629.

If there are concerns that this will be too confusing then we should explore alternatives. A different approach could be 'starring'/'favoriting' rather than 'pinning', and creating a section above the table for starred items. In the (rough) mockup below "Homepage", "Blog", and "Contact" pages are starred:

starred

A benefit to this approach is that it can be applied across all layout types rather than being restricted to Table.

@jameskoster
Copy link
Contributor Author

It may be worth discussing whether we want to offer both;

  • Favorites/pinning (like the mockup above)
  • Freezing (like Google Sheets)

@jorgefilipecosta
Copy link
Member

Given that the PR for this issue was closed I am assigned my self to this issue and will give it a try.

@jameskoster
Copy link
Contributor Author

I think we still need to define how pinning works. Perhaps the simplest approach would be to say:

  • Pinned rows appear first in the list of records, regardless of sorting
  • They stick in position as you scroll (similar to the table header)
  • They remain visible as you paginate, but disappear if you search (unless they would naturally appear in the results)

These characteristics could be applied in both List and Table layouts, but I'm not sure about Grid layout.

We'll need an accessible way for users understand why pinned records do not respect sort order.

What do y'all think?

@jorgefilipecosta
Copy link
Member

I think we still need to define how pinning works. Perhaps the simplest approach would be to say:

  • Pinned rows appear first in the list of records, regardless of sorting
  • They stick in position as you scroll (similar to the table header)
  • They remain visible as you paginate, but disappear if you search (unless they would naturally appear in the results)

These characteristics could be applied in both List and Table layouts, but I'm not sure about Grid layout.

We'll need an accessible way for users understand why pinned records do not respect sort order.

What do y'all think?

The suggestion seems like something we can follow. For the grid, I guess pinned items can be the first items regardless of sorting and if you paginate they persist, but they may not be visible on a scroll as in a grid that's strange.

@jameskoster
Copy link
Contributor Author

I still think pinning is a valuable feature, but there was some discussion in #56244 (comment) about a simpler approach to making the homepage easier to find. Perhaps it's worth prioritising that instead.

What do you think @jorgefilipecosta?

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 Needs Design Needs design efforts. [Type] Enhancement A suggestion for improvement.
Projects
None yet
Development

No branches or pull requests

4 participants