Update site screenshots to hide scrollbars on Windows - #133
Conversation
|
@wojtekn As referenced in the PR notes, I found it difficult to replicate the display of the scrollbars consistently. In all cases on macOS, the scrollbars were hidden. In some cases on Windows, repeatedly starting and stopping the server caused the scrollbars to reappear for the Seedlet theme (but only on Windows). I think this may possibly be due to an issue where the screenshot is captured before the extra CSS to hide the scrollbars is injected into the page. I wanted to check on the priority of investigating this edge case, as the issue only seems to appear inter intermittently. WDYT? |
|
@derekblank, thanks for preparing the fix. I played with multiple sites, using different themes, started and stopped them, and I couldn't reproduce it. Let's merge and close, and we can reopen if we spot it again. FYI, I was reproducing that not only for the Seedlet theme but for the default one, too. |
Agreed, thanks for taking a look. |
Suspect IssuesThis pull request was deployed and Sentry observed the following issues:
Did you find this useful? React with a 👍 or 👎 |
Resolves Automattic/dotcom-forge#7077
Proposed Changes
Updates CSS specificity in
createScreenshotWindowwaitForCaptureto further hide scrollbars on WindowsTesting Instructions
Note
This issue is difficult to replicate consistently. While this change should improve the behavior of not displaying scrollbars in screenshots on Windows, there may be a separate issue where either the theme still overrides the injected CSS, or the screenshot is captured before the extra CSS is injected.
Pre-merge Checklist