Commit 9d67c67
Remove inline scroll script - IT was causing the modal jump
Final debugging revealed the smoking gun:
The inline script I added in the previous commit was CAUSING the jump,
not fixing it.
What was happening:
1. Modal opens with iframe loading Types.php
2. My inline script runs: window.scrollTo(0, 0) on DOMContentLoaded/load
3. This forced scroll INSIDE the iframe triggers layout recalculation
4. WordPress modal parent detects the change and jumps visually
The Fix:
REMOVE the inline script completely. Stop fighting the browser.
Let the modal and iframe render naturally without forced scrolling.
Removed:
- All CSS attempting to prevent layout shift
- All inline JavaScript scroll commands
- window.scrollTo(0, 0) on DOMContentLoaded
- window.scrollTo(0, 0) on load
- scrollTop assignments
The modal should now open smoothly without jumping.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>1 parent 85b6213 commit 9d67c67
1 file changed
Lines changed: 0 additions & 19 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | | - | |
66 | | - | |
67 | | - | |
68 | | - | |
69 | | - | |
70 | | - | |
71 | | - | |
72 | | - | |
73 | | - | |
74 | 55 | | |
75 | 56 | | |
76 | 57 | | |
| |||
0 commit comments