[pull] next from storybookjs:next#894
Merged
Merged
Conversation
Bootstrap embed iframes at 2× viewport width before measurement, clip scaled previews inside grid cells, show a manager loader until resize settles, and re-measure on collapse/expand so spinners do not stick.
When freeze=finished is active, ignore iframe.resize.request from the parent until onContentFrozen runs so pre-freeze measurements cannot flash wrong thumbnail scales. Add broadcast cleanup for test isolation.
Replace three competing isPreviewLoading effects with one generation counter so duplicate iframe.resize payloads still clear the loader after paint instead of waiting for the fallback timeout.
Only hide the in-iframe preparing spinner when review thumbnails use embed with freeze, keeping generic embed previews on default UI.
Delete computeThumbnailScale and unused content-height defaults so Frame CSS is the single source of truth for thumbnail scale steps.
Simulate iframe.resize in play functions to assert loaders clear after measurement, duplicate resize payloads do not stick, and story swaps remount cleanly.
Thumbnail embeds always use freeze=finished for measurement; remove the ResizeObserver branch and test measurement through onContentFrozen instead.
Move shouldEmbed and shouldAutoplay into embedMode so measurement code and play-function policy live in separate modules.
…mbnail-content-resize
Keep freeze=finished thumbnails on onContentFrozen-only measurement while reinstating ResizeObserver-driven sizing for generic embed=true consumers.
Drop progressbar override so the indeterminate spinner keeps correct aria semantics without missing value attributes.
Use a FrameShell wrapper so aspect-ratio width comes from the cell, not subgrid row height, and add story coverage for frame-fit-after-resize.
…mbnail-content-resize
Cancel pending debounced RAF on embed resize teardown and assert review grid frames exist before width checks in story play functions.
Cells now display the loading indicator as soon as they enter the preview scheduler queue, instead of waiting until the iframe src is assigned.
Ignore identical DISPLAY_REVIEW payloads and only reset expanded collections when createdAt changes, so opening a story in a new tab does not collapse the summary the user left open.
… viewport. Embed previews now report the active viewport name and dimensions alongside content size so CollectionGrid can horizontally scale fixed viewports within the 3:2 frame and clip overflow vertically.
…l-content-resize Review: Improve review thumbnail scaling and loading UX
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.4)
Can you help keep this open source service alive? 💖 Please sponsor : )