LearnNewsExamplesServices
Frontmatter
id12314
titlefeat(portal): discussions tree shows open vs closed/answered state per discussion
stateClosed
labels
enhancementai
assigneesneo-gpt
createdAtJun 1, 2026, 6:59 PM
updatedAtJun 7, 2026, 7:17 PM
githubUrlhttps://github.com/neomjs/neo/issues/12314
authorneo-opus-ada
commentsCount0
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
blockedBy[]
blocking[]
closedAtJun 1, 2026, 9:45 PM

feat(portal): discussions tree shows open vs closed/answered state per discussion

neo-opus-ada
neo-opus-ada commented on Jun 1, 2026, 6:59 PM

Context

Operator input (2026-06-01) on the Portal news discussions view: the lazy-load tree should show, per discussion leaf, whether it is open vs closed/answered — so the tree communicates discussion status at a glance (like GitHub's open/answered markers).

The Problem

Portal.model.Discussion.treeNodeName renders a discussion leaf as <b>${id}</b> <span class="discussion-title">${title}</span> — no state affordance. The discussion state (open / closed / answered) is available in the synced markdown frontmatter but is not surfaced in the tree.

The Fix (direction)

Surface discussion open/closed (answered) state in the discussions tree leaf — e.g. a leading state icon or color class driven by a state field on Portal.model.Discussion, mirroring the 3-state badge pattern the tickets/pulls timeline views already use (getStateBadgeHtml). Requires:

  • The discussions index generator (buildScripts/docs/index/discussions.mjs) to carry the discussion state into the chunk leaf records.
  • Portal.model.Discussion to expose a state field and fold it into treeNodeName (icon/cls).
  • Theme vars for the state colors (the shared --gh-state-* palette already exists on the content base after #12312).

Acceptance Criteria

  • AC1 — Each discussion leaf in the tree visually indicates open vs closed/answered state.
  • AC2 — State is sourced from synced frontmatter via the generator → chunk leaf → model (no client-side guessing).
  • AC3 — Light + dark theme coverage for the state affordance.

Out of Scope

  • Chunk-folder naming scheme for discussions (the broader cross-view folder-UX brainstorm).
  • tickets/pulls tree state (their timeline views already badge state; this is the discussions tree).

Related

  • Epic #12204 (Portal news views & chunked tree).
  • Shared --gh-* palette now on the content base (#12312).
tobiu referenced in commit bac732b - "feat(portal): add discussion tree state badges (#12314) (#12323) on Jun 1, 2026, 9:45 PM
tobiu closed this issue on Jun 1, 2026, 9:45 PM