Fix responsive breakpoints for web component deployment#173
Merged
Conversation
Replace CSS @media queries with @container queries so breakpoints respond to the component's container width instead of the viewport, which doesn't work when embedded as a web component. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
Visit the preview URL for this PR (updated for commit a97cc60): https://profile-cloud-dev--pr173-suku-fix-responsive-k3k3x84m.web.app (expires Thu, 12 Mar 2026 14:30:51 GMT) 🔥 via Firebase Hosting GitHub Action 🌎 Sign: 2a004f867edf1347070dd9beedb18755187a6d4e |
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
@mediaqueries with@containerqueries inProfileCloudTreeItem.svelteandBrowserLayout.svelte@mediaqueries respond to the viewport width, which doesn't work when the app is embedded as a web component inside another application (e.g. Grid Editor) — the viewport is the full browser window, not the component's panel@containerqueries respond to the nearest ancestor's container width, so breakpoints now trigger correctly based on the actual available spaceTest plan
ProfileCloudTreeItemwhen the tree panel is narrower than 400px in the web component deploymentBrowserLayoutswitches from 1 → 2 → 3 columns at the correct breakpoints in the web component deployment🤖 Generated with Claude Code