news: categories field on news items + category filter on news-list #130

Closed
opened 2026-07-19 10:13:57 +02:00 by dominik.polakovics · 1 comment

This was generated by AI during triage.

Split out of #77 (News v2 categories). Final slice of the stack: wire categories into the news bundle's editor surface and listing element, on top of the engine multiselect field type (#128) and the taxonomy/term-page enablement (#129).

Decision record from triage on #77: full Hugo-taxonomy scope, categories only, vocabulary curated in sidecar options, work split into stacked issues.

Agent brief follows in the comments.

Blocked by

> *This was generated by AI during triage.* Split out of #77 (News v2 categories). Final slice of the stack: wire categories into the news bundle's editor surface and listing element, on top of the engine multiselect field type (#128) and the taxonomy/term-page enablement (#129). Decision record from triage on #77: full Hugo-taxonomy scope, **categories only**, vocabulary **curated in sidecar options**, work split into stacked issues. Agent brief follows in the comments. ## Blocked by - #128 - #129
Author
Owner

This was generated by AI during triage.

Agent Brief

Category: enhancement
Summary: Wire categories into the news bundle: a curated multiselect categories field on news items, category links in the news templates, and a category filter param on the news-list element.

Current behavior (once the blockers land):
The engine has a multiselect field type restricted to page-type fields (#128), and harness add news enables a categories taxonomy with working term and overview pages (#129). But news items still have no editor-visible categories — front matter must be hand-authored — and the news-list element can only filter by section and limit.

Desired behavior:

  • The news-item page-type sidecar gains a categories field of type multiselect with a small starter vocabulary in options (site owners edit the sidecar to change the vocabulary — that is the curation model decided on #77). The field key must be exactly the taxonomy key (categories) so the front-matter list the editor writes feeds the Hugo taxonomy directly.
  • The news detail template and the news section/term listings render each item's categories as links to their term pages.
  • The news-list element gains an optional category param of type select with the same vocabulary in options. When set, only items carrying that category are listed (the limit applies after filtering); when unset, behavior is unchanged. The filter is single-valued by design: element params are shortcode scalars.
  • The vocabulary is intentionally duplicated between the news-item and news-list sidecars; each sidecar carries a comment pointing at the other so site owners editing one know to update both.
  • News RSS output is unchanged.

Key interfaces:

  • The news bundle's news-item page-type sidecar (fields) and news-list element sidecar (params)
  • The news-list shortcode's filtering pipeline (currently: children of the picked section, type filter, draft filter, date-descending, limit)
  • The news bundle templates (detail, section list, term list) for rendering category links

Acceptance criteria:

  • The editor shows a multi-value categories picker on news items; saved values land as a front-matter string list and the item appears on the matching term pages
  • A news-list element with category set lists only items carrying that category, still excluding drafts and respecting limit; with category unset the output is identical to before
  • Rendered items link each category to its term page
  • Both sidecars carry the cross-referencing vocabulary comment
  • Theme/integration tests cover the filtered listing and the category links

Out of scope:

  • A shared vocabulary source between the two sidecars (duplication accepted for now)
  • Multi-category filtering on news-list
  • Tags or a second taxonomy
  • RSS changes
> *This was generated by AI during triage.* ## Agent Brief **Category:** enhancement **Summary:** Wire categories into the news bundle: a curated `multiselect` categories field on news items, category links in the news templates, and a category filter param on the news-list element. **Current behavior (once the blockers land):** The engine has a `multiselect` field type restricted to page-type fields (#128), and `harness add news` enables a `categories` taxonomy with working term and overview pages (#129). But news items still have no editor-visible categories — front matter must be hand-authored — and the news-list element can only filter by section and limit. **Desired behavior:** - The news-item page-type sidecar gains a `categories` field of type `multiselect` with a small starter vocabulary in `options` (site owners edit the sidecar to change the vocabulary — that is the curation model decided on #77). The field key must be exactly the taxonomy key (`categories`) so the front-matter list the editor writes feeds the Hugo taxonomy directly. - The news detail template and the news section/term listings render each item's categories as links to their term pages. - The news-list element gains an optional `category` param of type `select` with the same vocabulary in `options`. When set, only items carrying that category are listed (the limit applies after filtering); when unset, behavior is unchanged. The filter is single-valued by design: element params are shortcode scalars. - The vocabulary is intentionally duplicated between the news-item and news-list sidecars; each sidecar carries a comment pointing at the other so site owners editing one know to update both. - News RSS output is unchanged. **Key interfaces:** - The news bundle's news-item page-type sidecar (`fields`) and news-list element sidecar (`params`) - The news-list shortcode's filtering pipeline (currently: children of the picked section, type filter, draft filter, date-descending, limit) - The news bundle templates (detail, section list, term list) for rendering category links **Acceptance criteria:** - [ ] The editor shows a multi-value categories picker on news items; saved values land as a front-matter string list and the item appears on the matching term pages - [ ] A news-list element with `category` set lists only items carrying that category, still excluding drafts and respecting `limit`; with `category` unset the output is identical to before - [ ] Rendered items link each category to its term page - [ ] Both sidecars carry the cross-referencing vocabulary comment - [ ] Theme/integration tests cover the filtered listing and the category links **Out of scope:** - A shared vocabulary source between the two sidecars (duplication accepted for now) - Multi-category filtering on news-list - Tags or a second taxonomy - RSS changes
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Cloonar/deckle#130
No description provided.