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

Saved blocks list doesn't show all saved blocks (only a maximum of 10) #4632

Closed
ghost opened this issue Jan 22, 2018 · 6 comments
Closed

Saved blocks list doesn't show all saved blocks (only a maximum of 10) #4632

ghost opened this issue Jan 22, 2018 · 6 comments
Labels
[Feature] Synced Patterns Related to synced patterns (formerly reusable blocks) [Priority] High Used to indicate top priority items that need quick attention REST API Interaction Related to REST API [Type] Bug An existing feature does not function as intended [Type] Task Issues or PRs that have been broken down into an individual action to take

Comments

@ghost
Copy link

ghost commented Jan 22, 2018

Issue Overview

Saved blocks list does not show all saved blocks.

Only currently used in post and max. 10 additional saved blocks are shown.

Steps to Reproduce (for bugs)

  1. WordPress 4.9.2, Gutenberg 2.0.0
  2. 25 saved blocks
  3. Create new post
  4. Add block -> saved blocks

Expected Behavior

List of 25 saved blocks

Current Behavior

List of 10 saved blocks

Possible Solution

Use higher per_page (currently 10) and X-WP-TotalPages and/or X-WP-Total headers in REST API response to get missing entries.

@danielbachhuber danielbachhuber added the [Type] Bug An existing feature does not function as intended label Jan 23, 2018
@danielbachhuber danielbachhuber changed the title Saved blocks missing entries Saved blocks list doesn't show all saved blocks (only a maximum of 10) Jan 23, 2018
@danielbachhuber danielbachhuber added [Feature] Synced Patterns Related to synced patterns (formerly reusable blocks) REST API Interaction Related to REST API labels Jan 23, 2018
@karmatosed karmatosed added this to the Merge Proposal milestone Jan 25, 2018
@mtias mtias added the [Type] Task Issues or PRs that have been broken down into an individual action to take label Feb 5, 2018
@jeffpaul
Copy link
Member

This ticket was mentioned in Slack in #core-editor by jeffpaul. View the logs.

@karmatosed karmatosed modified the milestones: Merge Proposal, Merge Proposal: REST API Apr 12, 2018
@danielbachhuber
Copy link
Member

@WordPress/gutenberg-core For this issue, I think we need some design input. I see at least two directions we can head:

  1. Introduce infinite scroll to the Saved Blocks list. However, this will run into potential accessibility issues.
  2. Include pagination on the Saved Blocks list. I'm not sure if there's prior art we can use.

Opinions? Other ideas?

@karmatosed
Copy link
Member

karmatosed commented Apr 24, 2018

Are we talking in the library? I am going to assume so in my reply. I don't like the idea of adding pagination as no other blocks have this. Can't we just show all blocks like we do with the other blocks in the library?

@danielbachhuber
Copy link
Member

Can't we just show all blocks like we do with the other blocks in the library?

What if there are 1000 saved blocks? The problem space is similar to the media library. We don't load all attachments at once, but rather fetch them in batches of 40 via an infinite scroll experience.

@karmatosed
Copy link
Member

karmatosed commented Apr 24, 2018

What if there are 1000 saved blocks? The problem space is similar to the media library. We don't load all attachments at once, but rather fetch them in batches of 40 via an infinite scroll experience.

This is a problem of scale the library itself faces over one to solve just for saved blocks. Right now we are working on ways to get around this. I don't agree handling saved blocks differently is a good route. We need a scaling interface approach for all blocks. After all the idea is for previews to happen on all potentially.

For now, whilst other ways are being worked on outside this for the entire library we should have them display just as we do in other blocks.

2018-04-24 at 12 47

@danielbachhuber
Copy link
Member

Right now we are working on ways to get around this.

Where is this work happening?

For now, whilst other ways are being worked on outside this for the entire library we should have them display just as we do in other blocks.

How do you suggest this should work?

@danielbachhuber danielbachhuber added the [Priority] High Used to indicate top priority items that need quick attention label Apr 26, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Synced Patterns Related to synced patterns (formerly reusable blocks) [Priority] High Used to indicate top priority items that need quick attention REST API Interaction Related to REST API [Type] Bug An existing feature does not function as intended [Type] Task Issues or PRs that have been broken down into an individual action to take
Projects
None yet
Development

No branches or pull requests

4 participants