-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Layouts: Rockfield preview images not filling canvas #39351
Comments
@ianstewart Do you remember which theme you had active when you previewed that? It doesn't look like that's an issue with all themes. |
Notes on how to reproduce the issue: This issue appears to occur in the Homepage Template of Rockfield. Note that it's not tied to which theme you have currently selected, it appears with all themes including Rockfield. So in order to reproduce the issue select the Homepage Template of Rockfield in any theme. |
Updated initial observation: Continuing to look into it... |
Cause of the issue As initially assumed, the issue is caused by the combination of This doesn't surface as an issue as long as the size of the positioning context matches the site of the element with the background image. It surfaces as an issue in template previews because we need to scale the positioning context. This is so that even on smaller viewports, the user sees a good visual representation of what the page template will look like to visitors of their site. On a technical level, this is done by applying a The combination of Proposed solution The goal of the template previews is to provide the user with an idea of the result they will get when selecting a specific page template. To achieve this, the preview should match the visual appearance of the template but doesn't necessarily need to be fully interactive (in fact, we actually disable any type of user interaction with the preview). With this in mind, I recommend we opt for the following pragmatic solution: in the template preview only, we set the value for Visual result of proposed solution |
Would this be fixed by #39628, when we don't need to scale the preview anymore? |
I think the scaling of the preview has a different purpose and will stay in effect with #39628. IIRC the idea of the scaling is to always show a desktop style preview even on smaller viewports. The preview area is fairly small and without the scaling most of the time it'd show show tablet/mobile styles. This is just an assumption though, we might want to confirm with design. |
@ianstewart Can we assume you prefer images filling their canvas over the parallax effect working in template preview? It looks like we can't have both. |
That sounds reasonable to me - at least this way images don't look broken. |
Another thing to note: |
Chrome and MacOS:
I expected the images to fill the area.
The text was updated successfully, but these errors were encountered: