quarto-dev / quarto-dev/quarto-cli
max-items in listings will make pagination and categories fail
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 6k
- Forks
- 458
- Avg merge
- 1d 9h
- Merged PRs (30d)
- 41
Description
Bug description
In my blog, I have about 370 posts.
If I set max-items parameter in listing like this
listing:
- id: blog
contents: posts
sort: "date desc"
type: default #grid # default # table
sort-ui: false
filter-ui: false
max-items: 15 # 25
pagination and categories will fail: there is no pagination at the bottom of the listing. Categories are shown in the sidebar, but if you click on a category, nothing will happen. Each "#category=FOOBAR" will show the main listing.
If I remove max-items, then everything works again as expected.
Steps to reproduce
create a listing that has many entries. Set max-items Paramenter to e.g. 5.
Expected behavior
Listings shows the max-items ammount of entries (e.g. 5 entries),
pagination is at the bottom of the listing,
category-links will show a list of category items only
Actual behavior
There won't be any paginations, and all links of categories will just show the main listing.
Remove the max-items parameter, and pagiantions will reappear und category-links will work
Your environment
Archlinux
Quarto check output
Quarto 1.5.27
[✓] Checking versions of quarto binary dependencies...
Pandoc version 3.1.11: OK
Dart Sass version 1.70.0: OK
Deno version 1.41.0: OK
[✓] Checking versions of quarto dependencies......OK
[✓] Checking Quarto installation......OK
Version: 1.5.27
Path: /opt/quarto/bin
[✓] Checking tools....................OK
TinyTeX: (not installed)
Chromium: (not installed)
[✓] Checking LaTeX....................OK
Using: Installation From Path
Path: /sbin
Version: undefined
[✓] Checking basic markdown render....OK
[✓] Checking Python 3 installation....OK
Version: 3.11.8
Path: /sbin/python3
Jupyter: (None)
Jupyter is not available in this Python installation.
Install with python3 -m pip install jupyter
[✓] Checking R installation...........OK
Version: 4.3.3
Path: /usr/lib64/R
LibPaths:
- /home/produnis/R/x86_64-pc-linux-gnu-library/4.3
- /usr/lib/R/library
knitr: 1.45
rmarkdown: 2.25
[✓] Checking Knitr engine render......OK
...but it also happens with the current 1.4 release....
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the listing with many entries and max-items set, using the Quarto 1.5.27 configuration described in the issue. Trace the listing, pagination, and category-link entry points to find where max-items changes filtering; done means pagination appears, the item limit is respected, and category links show filtered results.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- content
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100