Skip to content

feat(org-chart): offer show all from the filtered empty state - #31790

Merged
bolichen97 merged 1 commit into
mainfrom
fix/22291-org-chart-show-all
Nov 7, 2026
Merged

bolichen97 merged 1 commit into
mainfrom
fix/22291-org-chart-show-all

Conversation

@bolichen97

Copy link
Copy Markdown
Contributor

Problem / Motivation

Goal: When the org-chart page's Open or Closed filter has nothing to show, the reader can get back to All in one click.

Picking Open or Closed on the org-chart dashboard page draws a plain line when nothing matches ("No open task to show." / "No closed task to show."). The line states the absence and offers no next step: the reader has to notice the filter pills above it and pick All themselves.

Why it matters

A reader who lands on an empty filtered view sees a dead end. A one-click way back is the usual empty-state pattern, and this page's filter was shipped without one (deferred from #21476).

Not a goal

  • No count or hint of what the other state holds: the filter pills already carry each state's count.
  • No change to the filter itself, its pills, the All view or the no-board empty line.
  • No change to any other dashboard template.

What changed (motivation → approach → change)

The filtered empty line in org-chart/template.html was a bare text div. It now ends with a Show all button, in English and Simplified Chinese, styled as the filter pills are.

Pressing it does exactly what pressing the All pill does, because it clicks that pill, and then moves focus to the pill: the button disappears with the line, so without this a keyboard reader would land on the page body. The page already rebuilds the graph on every host push and puts focus back on a fold button that had it; the Show all button gets the same treatment.

Backwards compatibility

Compatible: the button appears only in the filtered empty state, which had no control before; every other render path draws what it drew on main.

Removes nothing: the change adds a button and a string key; no element, key or behaviour is taken away.

Tests

website/src/test/orgChartFilterPage.test.ts adds two jsdom cases that run the page's real script:

  • offers a way back to All from that line, in English and Simplified Chinese: Open with no open task shows a Show all button; pressing it presses All, draws the task, removes the empty line and puts focus on the All pill; under zh-CN the label is the Chinese one.
  • keeps focus on Show all across a host push: with the button focused, a kirocrew-dashboard push rebuilds it and focus is on the new button.

Both fail with the production change reverted (main's template), and the second fails with only the focus-restore line removed. Determinism: each passed 20 repeated runs, and the three org-chart / template-i18n spec files passed in a shuffled order (--sequence.shuffle --sequence.seed=16191, 123 tests). The backend template suites (test_dashboard_templates_builtin.py, test_dashboard_template_views.py, the sink-ban, motion-guide, redraw and page-text suites) pass unchanged.

Manual verification

Rendered the template in headless Chromium with a one-board fixture whose only task is accepted, picked Open, and pressed Show all from the keyboard: the All pill is pressed, holds focus with its focus ring, and the graph and card draw.

Screenshots / video

Before (main): the line alone.

before, Open with nothing to show

After: the line with a Show all button, English and Simplified Chinese.

after, Open with nothing to show, English

after, Open with nothing to show, Simplified Chinese

After pressing Show all with the keyboard: All is pressed and focused, the board is drawn.

after pressing Show all

Related Issues

Closes #22291

Follows up on #21476.

Sibling sweep

N/A: a feat PR, not a fix.

Pattern harvest

N/A: a feat PR, not a fix.

Checklist

  • At most two commits (one is the norm), with a Conventional Commits title (feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)
  • Existing tests pass and new tests added for new functionality
  • Self-review completed; code follows project style guidelines
  • Documentation updated (if applicable)
  • No secrets, credentials, or internal references in the diff

@bolichen97
bolichen97 requested review from a team and KiroCrewCaptain as code owners November 6, 2026 20:40
@bolichen97
bolichen97 requested a review from Zedmor November 6, 2026 20:40
@github-actions github-actions Bot added the readiness: checking Automated validation is still running label Nov 6, 2026
@bolichen97
bolichen97 enabled auto-merge (squash) November 6, 2026 20:43
@github-actions

github-actions Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

GPT 6.1 Review — ✅ no blocking findings

GPT 6.1 completed its review of 1a2372d45db8e437270af439d29e49329b3153a2 and found no blocking issues.

This comment is updated in place on each push.

Review details

No findings.
[GPT-REVIEWED] 1a2372d

False positive or not applicable? A repository writer can comment:
/ai-review override gpt 1a2372d45db8e437270af439d29e49329b3153a2 false-positive: <reason, 20 to 500 characters>

@github-actions

github-actions Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

Design Review (Opus 5.5) — ✅ PASS

Design-level review of 1a2372d45db8e437270af439d29e49329b3153a2 — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

Design-Verdict: PASS

Nothing blocks. This is a small, reversible fix to the empty state. Show all reuses the All pill's own click path, so filtering logic still lives in one place. Before and after screenshots are attached.

[DESIGN-REVIEWED] 1a2372d

Description read

[DESCRIPTION-READ] a40d1d1eceace0414809674b89c63bb4784c6fbe80cbacf4359f73aeb7597949

That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions

github-actions Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

Opus 5.5 Review — ✅ no blocking findings

Reviewed 1a2372d45db8e437270af439d29e49329b3153a2 — this comment is updated in place on each push.

Review details

No findings.

[OPUS-REVIEWED] 1a2372d

Verdict parsed from the review's SHA-scoped output markers for commit 1a2372d45db8e437270af439d29e49329b3153a2.

False positive or not applicable? A repository writer can comment:
/ai-review override fable 1a2372d45db8e437270af439d29e49329b3153a2 false-positive: <reason, 20 to 500 characters>

@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed readiness: checking Automated validation is still running labels Nov 6, 2026
@bolichen97
bolichen97 force-pushed the fix/22291-org-chart-show-all branch from a3242d2 to cb82e76 Compare November 7, 2026 00:53
@bolichen97

Copy link
Copy Markdown
Contributor Author

Rebased: main moved in test/test_builtin_adoption_pins.py since this head's CI ran (39717a0 -> f71f5dd); main also now carries #31803, the fix for the unrelated test/test_pull_request_target_allowlist.py red on Backend Tests shard 7. The diff is unchanged; CI re-running.

[operator: bolichen97]

@bolichen97
bolichen97 force-pushed the fix/22291-org-chart-show-all branch from cb82e76 to f806fdc Compare November 7, 2026 04:51
@bolichen97

Copy link
Copy Markdown
Contributor Author

Rebased: main moved in test/test_builtin_skill_sync_safety.py since this head's CI ran (f71f5dd -> e4611c5). The previous run's red lanes all failed on a GitHub API rate limit in CI, not on this change. The diff is unchanged; CI re-running.

[operator: bolichen97]

@bolichen97
bolichen97 force-pushed the fix/22291-org-chart-show-all branch from f806fdc to f55f62e Compare November 7, 2026 07:38
@bolichen97

Copy link
Copy Markdown
Contributor Author

Rebased: main moved in test/test_builtin_host_grants.py since this head's CI ran (e4611c5 -> 75e43c83); CI re-running. The previous run's red lanes (the AI review lanes, Sensitive Change Review, Dependency License Gate, Publish readiness) again all failed reading the GitHub API under the CI installation rate limit, not on this change. The diff is byte-identical after the rebase; the org-chart backend tests, the builtin tests whose files moved on main, and the org-chart frontend tests pass locally on the new base.

[operator: bolichen97]

@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention labels Nov 7, 2026
@github-actions

github-actions Bot commented Nov 7, 2026 •

Copy link
Copy Markdown
Contributor

First Principles Review (Opus 5.5) — ✅ PASS

Premise-level review of 1a2372d45db8e437270af439d29e49329b3153a2 — why this exists and whether the shipped surface is the smallest honest version. Updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

First-Principles-Verdict: PASS

This adds a single-purpose control that a linked issue asked for (#22291). It reuses the All pill's own click handler and doesn't change any default.

What this change ships

Inventory (4 items) — 4 justified

Intent: when an Open/Closed filter on the org chart shows nothing, a reader can get back to All in one click. This is an ADDITION.

  1. The filtered empty line now ends with a "Show all" button (English and zh-CN): justified
  2. Pressing "Show all" turns on All and moves focus to the All pill: justified
  3. Keyboard focus on "Show all" is kept when a host push redraws the page: justified
  4. A new string key filter_show_all in both locales: justified

[FIRST-PRINCIPLES-REVIEWED] 1a2372d

Description read

[DESCRIPTION-READ] 414c72bd3ae8a5e8fe4cc017360d493e54b88f71f7387ceebdc582f0ff8767d5

That sha256 names the PR description this verdict read. Recompute it with .github/scripts/pr-description-capture.sh; if it differs, the description changed after this verdict was formed and any finding drawn from the description is unproven.

@github-actions

github-actions Bot commented Nov 7, 2026 •

Copy link
Copy Markdown
Contributor

UX Review (Opus 5.5) — ✅ PASS

UX-level review of 1a2372d45db8e437270af439d29e49329b3153a2 — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

UX-Verdict: PASS

Nothing blocks. The screenshots show every new state, and the blind reader correctly read "Show all" as a switch back to the All filter.

Notes

  • The page's existing jargon, which this PR does not change, is still unreadable to the blind reader: "last fold write", the "The fold aliases the session key…" footnote, and "- worker(s) past the fold's cap". They said: "I don't understand it at all." This needs a separate copy pass.

[UX-REVIEWED] 1a2372d

Description read

[DESCRIPTION-READ] 0598007a6957fc54f3fb6e4071aae87e86d0cbf1be753e05e9b44a18e2615062

That sha256 names everything this verdict read: the PR description, plus the 7 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed readiness: checking Automated validation is still running labels Nov 7, 2026
@bolichen97

Copy link
Copy Markdown
Contributor Author

[operator: bolichen97] The red on this head is one test, test/test_security_gate_liveness.py::test_the_package_stays_within_its_line_budget (Backend Tests shard 2 on Linux and Windows, and the Coverage Gate that fails closed on them). It fails on main itself: the security package is 34,855 lines against a budget of 34,845, and this PR touches neither file. #32183 raises the budget to main's measured size. This PR waits for that to land and re-runs then; no change here.

When the org-chart page's Open or Closed filter has nothing to show,
the empty line now ends with a Show all button, in English and
Simplified Chinese. It presses the All pill and moves focus there, and
keeps its own focus across a host push the way the fold buttons do.

Closes #22291
@bolichen97
bolichen97 force-pushed the fix/22291-org-chart-show-all branch from f55f62e to 1a2372d Compare November 7, 2026 13:48
@bolichen97

Copy link
Copy Markdown
Contributor Author

[operator: bolichen97] Rebased onto main (75e43c83 -> f58c3cf) to pick up #32252, which raised the security package line budget to the package's measured size on main. That budget was the only red here (test/test_security_gate_liveness.py::test_the_package_stays_within_its_line_budget on Backend Tests shard 2, Linux and Windows, plus the Coverage Gate that fails closed behind it), and main has been green on it since #32252 landed; #32183 was closed without merging. A rerun could not pick that up, since it reuses the old merge commit. The diff is unchanged (same patch id); CI re-running.

@github-actions github-actions Bot added readiness: checking Automated validation is still running readiness: passed Eligible automated validation passed for the current revision and removed readiness: action required A blocking check or review needs attention readiness: checking Automated validation is still running labels Nov 7, 2026

@KiroCrewCaptain KiroCrewCaptain left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved: PR Readiness passed on 1a2372d, and all five review lanes (Opus 5.5, GPT 6.1, Design, UX, First Principles) report no blocking finding on this head. No conflict and no open change request.

@bolichen97
bolichen97 merged commit 8faf18d into main Nov 7, 2026
154 of 155 checks passed
@bolichen97
bolichen97 deleted the fix/22291-org-chart-show-all branch November 7, 2026 19:47
@github-actions github-actions Bot removed the readiness: passed Eligible automated validation passed for the current revision label Nov 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

org-chart filter: give the empty state a next step

2 participants