⚡ Quick Fix (TL;DR)
The Fix: 1. Check whether `max-height` uses `100vh` — replace with `dvh`.
2. Check whether any `scroll` event listener closes or hides the widget.
3. Check whether the popup has `position: fixed` — if not, it may reposition unexpectedly when the viewport shifts.
Two fixes applied together:
**Fix 1 — Replace `vh` with `dvh`:**
```css
@media (max-width: 600px) {
.widget-popup {
max-height: 70dvh;
position: fixed;
}
}
```
**Fix 2 — Guard the scroll listener:**
```javascript
window.addEventListener('scroll', function() {
if (popup.classList.contains('open')) return; // ignore scroll while widget is open
// hide launcher logic...
});
```
Rather not untangle this yourself? Our Done-For-You team handles exactly this kind of thing, start to finish.
See DFY options →
Was this helpful?
Thanks for the feedback!
The symptom
Tagged in :