Skip to content

feat(slack): give the PR and workers context-bar items distinct icons - #39276

Merged
KiroCrewCaptain merged 2 commits into
mainfrom
fix/context-bar-icons
Nov 18, 2026
Merged

KiroCrewCaptain merged 2 commits into
mainfrom
fix/context-bar-icons

Conversation

@kyleseaman

Copy link
Copy Markdown
Contributor

Problem / Motivation

Goal: In a Slack code channel, the context bar's PR item and Workers item each get their own icon instead of both showing hierarchy.

The PR item (PR #42 is open · tests passing), the Create PR action and the Workers item (1 working · ...) all used the hierarchy icon, so the two look the same in the bar.

Why it matters

People reading a code channel cannot tell the PR item from the Workers item at a glance.

Not a goal

What changed (motivation → approach → change)

Both items used the literal "hierarchy". The icons are now named constants in src/kiro_crew/slack/code_channels/workspace/context_bar.py, with the values the user chose from Slack's fixed set:

  • PR_ICON = "link" for the PR item
  • CREATE_PR_ICON = "link" for the Create PR action
  • WORKERS_ICON = "life-ring" for the Workers item

docs/system-specs/modules/slack-gateway.md now names each bar item's icon.

Backwards compatibility

Compatible: only the icon value Slack shows changes; both values are in Slack's documented set (ICONS), which conforms and _unique already check.

Removes nothing: no key, item or function is removed; only two icon values change.

Tests

  • test_each_bar_item_has_its_own_pinned_icon (new): a full bar pins every item's icon (workers life-ring, repo folder, branch branch, stop terminal, pr link), the Create PR action's link, at most five items, every icon in ICONS, and that the PR and Workers icons differ.
  • Existing expectations in test/test_slack_code_channel_bar_budget.py and test/test_slack_code_channel_workspace.py updated to the new icons.

Manual verification

N/A — unit coverage sufficient: the change is two icon string values in the payload the tests assert verbatim.

Real-machine verification

N/A -- no Slack workspace with code channels is reachable from this environment; the diff only changes icon string values in the context-bar payload, which the unit tests assert exactly.

Related Issues

None.

Checklist

  • A Conventional Commits title (feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...); PR Hygiene does not count commits
  • 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

Contribution License Agreement

Contributions are accepted under the project's Apache-2.0 license.

The PR item, the Create PR action and the Workers item all showed
Slack's hierarchy icon, so the bar could not tell them apart. The PR
and Create PR now use link and the Workers item uses life-ring, as
named constants, and a test pins every item's icon.
@kyleseaman
kyleseaman requested review from a team and KiroCrewCaptain as code owners November 18, 2026 21:28
@github-actions github-actions Bot added the readiness: checking Automated validation is still running label Nov 18, 2026
@github-actions

github-actions Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

UX Review (Opus 5.5) — ⏭️ skipped

Revision c762440527658a77bccd0190a324b05e946666ed touches no user-facing surface (no changes under website/ or committed screenshots), so the UX review was skipped. Does not block merge.

@github-actions

github-actions Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

First Principles Review (Opus 5.5) — ✅ PASS

Premise-level review of c762440527658a77bccd0190a324b05e946666ed — 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 only swaps icon values. The PR and Workers items no longer share hierarchy, and no new surface ships.

Notes

  • Item 4 — symptom-level: the shared-icon problem moves rather than goes away. The PR item and Create PR now share "link" with dashboard (context_bar.py:229, _item(DASHBOARD_KEY, DASHBOARD_LABEL, "link", url)), and dashboard can sit next to either when a slot is free. That is 1 unfixed sibling of the same collision.
  • Item 4 — oversized: PR_ICON, CREATE_PR_ICON and WORKERS_ICON each have one consumer (grep count: 1 each). The other four icons stay literals. Subtraction: delete the three constants and pass the literals inline, as "folder"/"branch"/"terminal"/"link" already are.

What this change ships

Inventory (5 items) — 3 justified

Intent: in a Slack code channel, the PR item and the Workers item should be easy to tell apart at a glance. This is a FIX.

  1. Workers item icon changes from hierarchy to life-ring — justified
  2. PR item icon changes from hierarchy to link — justified
  3. Create PR action icon changes from hierarchy to link — rides along; Create PR is never in the bar with Workers… keeps it matching the PR slot
  4. Three new module constants name the PR, Create PR and Workers icons — oversized, one consumer each
  5. The spec now lists each bar item's icon — justified

[FIRST-PRINCIPLES-REVIEWED] c762440

Description read

[DESCRIPTION-READ] d34586f98fc0888c0614ad4c0f21467822125ec4381ac7c02562edcee6b3e481

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 18, 2026 •

Copy link
Copy Markdown
Contributor

Design Review (Opus 5.5) — ✅ PASS

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

Design-Verdict: PASS

Nothing blocks: two icon values in a Slack payload change, both from Slack's documented set, and the change is easy to revert.

Notes

  • The fix just moves the look-alike problem: PR_ICON = "link" is the same icon as the dashboard item's "link" (context_bar.py:229). When a bar has the PR item and a free slot (for example, no workers), the PR and Open in dashboard look identical. A different PR icon from ICONS would avoid the clash.

[DESIGN-REVIEWED] c762440

Description read

[DESCRIPTION-READ] 507cf51943d650150fd4230766ed05b2ed21df57ab3f3e630ec43f7e4b63869c

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 18, 2026 •

Copy link
Copy Markdown
Contributor

Opus 5.5 Review — ✅ no blocking findings

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

Review details

No findings.

[OPUS-REVIEWED] c762440

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

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

@github-actions

github-actions Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

GPT 6.1 Review — ✅ no blocking findings

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

This comment is updated in place on each push.

Review details

No findings.
[GPT-REVIEWED] c762440

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

@github-actions github-actions Bot added readiness: passed Eligible automated validation passed for the current revision and removed readiness: checking Automated validation is still running labels Nov 18, 2026
@kyleseaman

Copy link
Copy Markdown
Contributor Author

Replies to the non-blocking review notes:

  • Design Review, PR and Open in dashboard both use link: the user picked link for the PR item and the Create PR action, and life-ring for Workers. The two items have different labels (PR #42 is open … vs Open in dashboard), and the dashboard item only appears in a slot nothing else wanted. Keeping the user's choice.
  • First Principles Review, three constants with one consumer each: the task asked for the icons as named constants rather than literals, so the test and spec can name them. Keeping them.

@KiroCrewCaptain
KiroCrewCaptain enabled auto-merge (squash) November 18, 2026 23:58

@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. On this head the review checked these points. Both new icons (link, life-ring) are in ICONS, so _unique() and conforms() still keep the PR, Create PR and Workers items. Only context_bar.py builds these items, and no code branches on an icon value. No test expectation still uses hierarchy. The spec row in slack-gateway.md matches the code.
Done well: the new test pins every icon as an exact string and checks icons["pr"] != icons["workers"] directly, so reverting the change turns it red.

  • Optional: the PR item and "Open in dashboard" now both use link and can sit in the same bar. A PR icon no other built-in item uses (for example code) would keep them apart.
  • Optional: PR_ICON, CREATE_PR_ICON and WORKERS_ICON each have one consumer. The other built-in icons are plain literals.
  • Optional: the last assertion in test_each_bar_item_has_its_own_pinned_icon repeats what test_every_bar_is_within_the_documented_limits already checks.

@KiroCrewCaptain
KiroCrewCaptain merged commit a6fa0c6 into main Nov 18, 2026
99 of 103 checks passed
@KiroCrewCaptain
KiroCrewCaptain deleted the fix/context-bar-icons branch November 18, 2026 23:58
@github-actions github-actions Bot removed the readiness: passed Eligible automated validation passed for the current revision label Nov 18, 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.

2 participants