[Bug]: Headless Firefox gives every element `scrollbar-width: none`, whatever the page sets
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 55/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- playwright, typescript
- Domain
- backend, testing-qa
Research direction
Start with browser_patches/firefox/juggler/content/hidden-scrollbars.css and how Juggler.js registers that stylesheet for headless Firefox. Run the linked reproduction with Node 20 or later to confirm the computed values across browsers. Done when headless Firefox reports the page's specified scrollbar-width values while keeping scrollbars hidden.
Written by the indexing model from the issue text.
Description
Version
main (28c4b2e), with the Firefox it pins, 159.0
Steps to reproduce
- Clone https://github.com/YevheniiKotyrlo/playwright-firefox-headless-scrollbar-width
- Run
node repro.mjswith Node 20 or later and git. It clonesmain, runsnpm ciandnpm run build, installs the browsersmainpins, and in Chromium, Firefox and WebKit, each launched headless, sets this page and readsgetComputedStyle(element).getPropertyValue('scrollbar-width')for<html>and each<div>:
<!doctype html>
<style>div { width: 100px; height: 50px; overflow: auto } p { height: 200px }</style>
<div style="scrollbar-width: auto"><p></p></div>
<div style="scrollbar-width: thin"><p></p></div>
<div style="scrollbar-width: none"><p></p></div>
<div style="scrollbar-width: thin !important"><p></p></div>
Expected behavior
Each element reads the scrollbar-width the page gives it, as in headless Chromium and WebKit: auto for <html>, which sets no scrollbar-width (the initial value), then auto, thin, none and thin. The scrollbars can stay hidden: headless Chromium hides them with --hide-scrollbars and reads the page's values.
Actual behavior
Headless Firefox reads none for every element, thin !important included:
microsoft/playwright 28c4b2e, Chromium 159.0.8154.6, Firefox 159.0, WebKit 27.2, each headless; Node v26.12.1, win32 10.0.26300 x64
element expected chromium firefox webkit
<html>, which sets no scrollbar-width auto auto none auto
<div style="scrollbar-width: auto"> auto auto none auto
<div style="scrollbar-width: thin"> thin thin none thin
<div style="scrollbar-width: none"> none none none none
<div style="scrollbar-width: thin !important"> thin thin none thin
summary: microsoft/playwright 28c4b2e: headless Firefox 159.0 reads scrollbar-width none for 4 of the 4 elements that should read auto or thin; headless Chromium 159.0.8154.6 and WebKit 27.2 read the expected value for all 5 elements
Additional context
The value comes from hidden-scrollbars.css, which Juggler.js registers as a user-agent style sheet when Firefox runs headless.
Environment
microsoft/playwright 28c4b2e, Chromium 159.0.8154.6, Firefox 159.0, WebKit 27.2, each headless; Node v26.12.1, win32 10.0.26300 x64
- Dominant language
- TypeScript
- Stars
- 100k
- Forks
- 6.9k
- Avg merge
- 16h 8m
- Merged PRs (30d)
- 281
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from microsoft/playwright
-
[MCP]: page snapshots in .playwright-mcp/ are not git-ignored (.playwright-cli/ is, since #42318)Open
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
microsoft/playwright#44289 ·
Maintainers usually reply within 1 day
-
agent-triage-done
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
microsoft/playwright#44264 · 2 comments ·
Maintainers usually reply within 1 day
-
Difficulty 5/5 Over a week Newbie friendliness 12/100
microsoft/playwright#44290 ·
Maintainers usually reply within 1 day
-
Difficulty 4/5 3-5 days Newbie friendliness 22/100
microsoft/playwright#44288 ·
Maintainers usually reply within 1 day
-
[Bug]: page.goto never returns for a load started as a newer service worker takes over (Chromium)Open
Difficulty 5/5 Over a week Newbie friendliness 12/100
microsoft/playwright#44287 ·
Maintainers usually reply within 1 day
All issues in microsoft/playwright
Similar issues
-
clawsweeper:needs-maintainer-review clawsweeper:needs-product-decision clawsweeper:no-new-fix-pr clawsweeper:source-repro impact:ux-friction issue-rating: 🦞 diamond lobster P3
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
openclaw/openclaw#203385 · 1 comment · 1 reaction ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
nwverse/persona#12800 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 80/100
Maintainers usually reply within 1 day
-
good first issue
Difficulty 2/5 Half a day Newbie friendliness 65/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
WISE-Community/WISE-Client#2404 ·
Maintainers usually reply within 1 day