feat: list authors in design - #2743
Conversation
This comment has been minimized.
This comment has been minimized.
Visual recap — screenshot failedA recap was published, but the PR-comment screenshot could not be captured or uploaded. Open the interactive recap directly: Open the full interactive recap Diagnostic: light: screenshot captured but image upload failed |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
There was a problem hiding this comment.
Builder reviewed your changes and found 2 potential issues 🟡
Review Details
Code Review Summary
PR #2743 adds owner email to the design listing action and surfaces creator bylines plus an author filter in the design library. The implementation has a good separation between action data, pure filtering helpers, localized strings, and UI state; normalization and the accompanying unit coverage handle casing, null owners, and unknown sessions safely. This is a standard-risk feature change.
Key Findings
- 🟡 MEDIUM — The author Select can retain a selected option after that author disappears from the current design data, leaving an active but invisible filter.
- 🟡 MEDIUM — The card byline eagerly mounts an avatar lookup for every visible owner in an unpaginated library, which can create a burst of requests and data-URL downloads in larger shared workspaces.
🧪 Browser testing: Will run after this review (PR touches UI code)
| {viewerHasDesigns ? ( | ||
| <SelectItem value={MY_DESIGNS}>{t("home.me")}</SelectItem> | ||
| ) : null} | ||
| {authorEmails |
There was a problem hiding this comment.
🟡 Reset the author filter when its selected option disappears
If the selected author has all of their designs removed or the list refreshes without that owner, author still contains the old email while the SelectItem is no longer rendered from authorEmails. The grid becomes empty but the control no longer exposes the active filter; reset the selection (including MY_DESIGNS when viewerHasDesigns becomes false) or derive a validated Select value from the current options.
Additional Info
Found by 1 of 3 review agents; independently confirmed from the state/options flow.
| /** Who created a design, shown on its library card in shared workspaces. */ | ||
| function DesignAuthorByline({ email }: { email: string }) { | ||
| const name = emailToName(email); | ||
| const avatarUrl = useAvatarUrl(email); |
There was a problem hiding this comment.
🟡 Avoid eager avatar requests for every design card
DesignAuthorByline mounts once per visible card and useAvatarUrl(email) fetches an avatar for each distinct owner email. Because the list is unpaginated, a shared library with many owners can trigger a burst of avatar requests and download data-URL images on initial render; consider batching/preloading the normalized author set or deferring avatar fetches while rendering the deterministic fallback.
Additional Info
Found by 1 of 3 review agents; independently confirmed against useAvatarUrl implementation.
No description provided.