fix(chat-welcome): apply suggestions gap one level down for wrapped chips#465
Merged
Conversation
…hips The `.chat-welcome__suggestions` slot in `chat-welcome` had `display: flex; gap: 8px` so projected children would be spaced. But every consumer in the cockpit (and the c-a2ui example) projects suggestions wrapped in a single `<div chatWelcomeSuggestions>` element — meaning the slot's gap fires between *zero pairs of divs* (there's only one), and the chips inside that div sit flush against each other with no gap. Visible on c-a2ui with the recently-added 'LAX → JFK' / 'SFO → SEA' chips: the two pills touched. Less visible on c-generative-ui because the chips have longer labels and natural padding masks the issue — but the same bug. Add a one-level-deeper rule that re-applies the same flex layout to any wrapping `<div>` child of the slot. Safe no-op when consumers project `<chat-welcome-suggestion>` directly (no wrapper div). Verified locally via chrome MCP: c-a2ui welcome chips now show a clear 8px gap. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
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.
Summary
The chat welcome screen's suggestion chips had no visible gap between them on c-a2ui (and a subtle one on c-generative-ui).
Root cause: `.chat-welcome__suggestions` is `display: flex; gap: 8px`, but every consumer projects chips wrapped in a single `
Fix
Add a one-level-deeper CSS rule: `.chat-welcome__suggestions > div` also gets `display: flex; gap: 8px`. Safe no-op when consumers project chips directly without a wrapper div.
Files
Test plan
🤖 Generated with Claude Code