Repository navigation
Show a neutral initial when an avatar fails to load - #295
Conversation
|
Review: Looks good Checked in a worktree on :8924 with github.com photos aborted, delayed 3s, and real. Three handles (octocat, alice, bob) were in one document.
Non-blocking:
|
|
Applied the four nits: chat Face is now decorative and untitled; Face is keyed by handle so load state resets; face.tsx comment rewrapped; excerpt tests renamed and a boundary case (space at index 60) added. face.tsx new hash in the PR body: 830c3d5275279f75c3fa0da9d01f5d4802daff0deb0923f95df1072150b9d11e. The design-contract check is still the only failing job. |
# Conflicts: # apps/web/src/project-sidebar.tsx
Fixes that only exist because several open PRs now share one tree: - Drop #290's duplicate ImageIcon and its LineIcon titles, which #287 removed. - Remove the import #302 left unused after #276's inline code. - Renew design-contract pins for files more than one PR edited, and record #290's new icons and #295's face colours as reviewed exceptions. - Find icons by path rather than the titles #287 removed, and faces by the label #295 gives them. - A tool that returns after its turn was stopped ends as failed, so #314's early completion keeps #272's stopped-question outcome. Assistant-model: Claude Opus 5.5 Assistant-workflow: inline Assistant-verification: typecheck passed: bun run types Assistant-verification: dprint/oxlint/design checks passed: bun run ci Assistant-verification: bun test passed: 3860 pass, 0 fail Co-authored-by: Alex Lavaee <lavaman131@github.com>
86f2f67 to
4092977
Compare
|
Commit pushed:
|
This comment has been minimized.
This comment has been minimized.
50234ca to
e19de1c
Compare
|
CI babysitter rechecked the current failed Root cause:
I did not queue another commit from this runner because
Warning Firewall blocked 1 domainThe following domain was blocked by the firewall during workflow execution:
To allow these domains, add them to the network:
allowed:
- defaults
- "releaseassets.githubusercontent.com"See Network Configuration for more information.
|
e19de1c to
8f39562
Compare
8f39562 to
30911b8
Compare
…xcerpts on a word Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… text Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…undary excerpt Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
99a11d7 to
ebb08b1
Compare




Integration and validation
Use one shared human avatar with a tinted initial while loading or after failure. Keep the current Chopin mark, make faces decorative beside visible names, and reset load state when the handle changes. Preserve word-boundary comment excerpts and the exact-limit regression.
Rebased onto current main. Reviewed the changed Face colour expressions and merged sidebar boundary before renewing their source pins. Formatting/lint/design checks, types, 30 focused tests and all 21 avatar/mention/navigation browser tests pass locally. Final required CI is running.
Original proposal and screenshots
Why
When an avatar URL failed to load, the sidebar account row showed the browser's broken-image icon. Chat and presence faces fell back to a solid account-colour block. The sidebar used the API's
avatarUrlwhile chat and presence usedhttps://github.com/<login>.png. Separately, the "dismissed a comment" notice cut its quoted excerpt mid-word with no ellipsis.What changed
Face(packages/editor/src/face.tsx) is now the one avatar. Until the photo loads, and if it fails, it shows a tile tinted with the person's cursor colour (18% over--color-page, opaque so overlapping faces stay clean) with the initial in the same hue mixed 80% toward--color-text-primary(text-xs, weight 600), same size and radius as the photo. Presence, chat, the evidence popover, the mention picker and the sidebar account row all use it.https://github.com/<login>.png, which chat and presence already used. The login is the identity we hold everywhere, andavatarUrlis only on the session user, so it cannot serve other people. The mention picker's private copy ofFaceis removed.Faceuses for people (the agent keeps its circle), so the account row avatar goes from a circle to a rounded square. This follows the existing "a person is a square, the agent a circle" rule inface.tsx; say if you want the account row to stay round.Facegets adecorativeprop (empty alt) for places where the name is written next to it.excerpt()inapps/server/src/comments/service.tsnow cuts at a word boundary (falling back to a hard cut if no boundary leaves at least half) and appends…. Exported and unit tested.color(handle)design exception forface.tsxis kept as it was, but its expressions changed (see below).The notice before:
@octocat dismissed a comment on "…reach a share".After: the excerpt ends on a whole word followed by….Screenshots
Photos blocked on both servers to force the failure (the fake GitHub's
example.invalidURLs fail on their own).Sidebar account row. Before:
After:
Chat author. Before:
After:
Presence stack. Before:
After:
The notice is covered by unit tests rather than a screenshot.
Testing
bun test apps/server/src/comments/excerpt.test.ts: 4 passbun test apps/web/src/chat/mentions.test.ts apps/web/src/navigation-chrome.test.ts: 34 pass (mention test updated: the loading-state initial is aria-hidden)bun test apps/web packages/editor: all pass except one design-contract focus test that timed out at 10s under load and passes alonebun run types: pass.bun run fix: no further changes.bun run ci: fails only on the design-contract review below.Needs a design-contract review
apps/web/src/project-sidebar.tsx,scripts/design-contract/exceptions/dynamic-web.json(NavigationIconclassNamecase). New hash:74828419d9903e2784093b4f9bee1ab52ddf0b939f27870cabed13d139224ddb. The edit swaps the account-row<img>for<Face>and adds no class or style logic toNavigationIcon.packages/editor/src/face.tsx,scripts/design-contract/exceptions/preserved-values.json. The old casebackground: color(handle)is replaced by two cases:background: color-mix(in srgb, ${tone} 18%, var(--color-page))andcolor: color-mix(in srgb, ${tone} 80%, var(--color-text-primary)), wheretoneis stillcolor(handle). New hash:830c3d5275279f75c3fa0da9d01f5d4802daff0deb0923f95df1072150b9d11e. Same reviewed purpose (identity colour from the handle, matching the cursor), now as a tint with a darker initial built from tokens.🤖 Generated with Claude Code