fix(stories): drop iframe body styles causing expanding docs preview#221
Open
jsakamoto wants to merge 1 commit into
Open
fix(stories): drop iframe body styles causing expanding docs preview#221jsakamoto wants to merge 1 commit into
jsakamoto wants to merge 1 commit into
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR fixes an iframe layout feedback loop in the Blazing Story Docs preview by removing <body> inline styles in IFramePage.razor that forced a viewport-based minimum height (and added spacing), which could cause the preview frame to grow on successive renders.
Changes:
- Removed
min-height: calc(100vh - 32px)from the iframe page<body>to prevent height self-amplification. - Removed
<body>marginandpaddinginline styles so the iframe can size naturally based on content.
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.
Description
Remove
margin,padding, andmin-heightstyles from the<body>element inIFramePage.razorto fix the ever-growing preview window height in the Blazing Story Docs page.Motivation / Context
Blazing Story v1.0.0-preview.81 resolved unpredictable zoom behavior in preview frames as part of its layout mechanism improvements. With that fix in place, the
min-height: calc(100vh - 32px)style that had been applied to the<body>element of the iframe page became unnecessary and started causing a new problem.Because the iframe's own height expanded to match the content height, which in turn was set to
100vhof that iframe, this created a feedback loop that kept stretching the story preview window taller on every render cycle, especially noticeable on the Docs page.This PR removes the
margin,padding, andmin-heightproperties from the<body>inline style to align with the layout behavior introduced in Blazing Story v1.0.0-preview.81, and allows the preview to size itself naturally based on its actual content.Type of Change (check all that apply):
Component(s) / Area(s) Affected:
Blazing Story / Stories iframe page (
IFramePage.razor)How Has This Been Tested?
Opened the Blazing Story Docs page and confirmed that the story preview window no longer grows beyond the expected height.
Test Configuration:
Screenshots / Recordings
Checklist:
README.MDCHANGELOG.MDupdates for newly added functionality