fix(ui): keep full owner/name for tap chips in config editor#33
Merged
Conversation
displayName() unconditionally took the last slash-separated segment, which is right for three-segment package paths (cirruslabs/cli/tart -> tart) but destroys a tap's identity: a tap name *is* owner/name, so cirruslabs/cli rendered as "cli" and openbootdotdev/tap as "tap". Taps now keep their full name, matching the Homebrew taps section in ConfigDetail.svelte, which already renders p.name unabridged. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01NExRvhpGqvdcoj5zZFtoQL
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
In the dashboard config editor, Homebrew taps rendered as meaningless single words: the tap
cirruslabs/clishowed as cli, andopenbootdotdev/tapshowed as tap.Why
displayName()inPackageManager.svelteunconditionally took the last slash-separated segment:That's correct for three-segment package paths (
cirruslabs/cli/tart→tart), but a tap's name isowner/name— stripping the prefix throws away its identity and leaves an unrecognizable tail.Not a CSS truncation; the name was discarded at render time.
Fix
Taps keep their full name; every other type is unchanged. This also makes the editor consistent with the public config page —
ConfigDetail.svelte's "Homebrew taps" section already rendersp.nameunabridged.Verification
No Svelte component test infrastructure exists in this repo (no
@testing-library/svelte, no component tests), so rather than add a test dependency for a two-line display fix, this was verified by rendering the real page: the four affected entries from a live config were seeded into local D1, the edit page was rendered with headless Chrome (--dump-dom, so client-side JS runs), and each chip's visible text was compared against the real name in itsaria-label.tartcirruslabs/cli/tartopenbootopenbootdotdev/tap/openbootwranglerwranglercirruslabs/clicirruslabs/clicli)openbootdotdev/tapopenbootdotdev/taptap)npm run validatepasses: lint 0 errors, svelte-check 0 errors, 289 tests passed, build succeeds.🤖 Generated with Claude Code
https://claude.ai/code/session_01NExRvhpGqvdcoj5zZFtoQL