-
Notifications
You must be signed in to change notification settings - Fork 255
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
Add search result page navigation #2684
Comments
According to the spec, the only pagination parameter we are guaranteed to have is the |
Unfortunately, I don't see how we can build out these pagination controls. The IIIF response The spec says there |
Maybe we can discuss this post-standup today. My first designs actually just assumed access to the next page, so instead of pagination controls there was a "More results" action that would trigger fetching the next page of results: I guess at some point in trying to improve the designs we lost track of the fact that the last page reference was not a MUST and assumed we'd always have first and last page values (the example search response documents we were using had them) and so could calculate the number of pages. Trying to fetch all pages sequentially seems risky, since I can imagine there will be cases with many, many pages in the response. |
My first designs actually just assumed access to the next page, so instead of pagination controls there was a "More results" action that would trigger fetching the next page of results:
Superseded information
This ticket assumes work outlined in #2683 has been completed.
If the search service returns results using a paged structure (example: https://exist.scta.info/exist/apps/scta-app/iiif2/lon/search?q=contradictio), not all result items are necessarily immediately available. But we do know how many pages the results have been split into, so we can provide paging navigation for the user.
In the mockup above, the highlighted part in the search panel header has been added to the
hits
version of results described in #2683, because this search service returns paged results.firstPageSharp
andlastPageSharp
icons for the outermost icons of the page navigation element. Usepadding: 12px;
for the icons.chevronLeftSharp
andchevronRightSharp
icons, withpadding: 12px;
for previous and next page navigation.12px
padding.Page navigation interaction
This probably doesn't need much explanation, but when the user navigates to a new page, the page navigation element, the hit result navigation element, the panel body content, and the canvas should all be updated accordingly.
For example, in the mockup above the user is on page 2 of the results, which this search service returns in pages of 5. If the user then selects the next page icon:
The text was updated successfully, but these errors were encountered: