Re:The 'Fuck You' Pattern
by NoMoreNicksLeft on Sunday June 25, 2023 @03:38PM
(#36471816)
Dev tools, look at the html and body element, and uncheck overflow:hidden. Plus a strategic delete or two on the DOM tree.
[ Parent
| on HN ]
Re:The 'Fuck You' Pattern
by DelightOne on Sunday June 25, 2023 @04:30PM
(#36472294)
Why can't UBlock Origin do that?
Re:The 'Fuck You' Pattern
by NoMoreNicksLeft on Sunday June 25, 2023 @04:57PM
(#36472515)
I dunno. Maybe it can, and I'm just too dumb to configure it right?
It can, using CSS injection:
example.com##body:style(overflow: auto !important)
Re:The 'Fuck You' Pattern
by NoMoreNicksLeft on Monday June 26, 2023 @12:01AM
(#36475611)
That's kinda nice... trying to figure out if it needs to even be per-site or not... locking overflow's almost always gotta be hinky, doesn't it?
Anyway, just wanted to say thanks.
* * *
Re:The 'Fuck You' Pattern
by EdwardDiego on Sunday June 25, 2023 @08:52PM
(#36474333)
They're getting sneaky about where the overflow:hidden is applied these days, and one site I encountered had JS that polled that attribute and reapplied it if it was modified.
I was impressed at their commitment to dickery.
Array.from(document.body.querySelectorAll('html,body, body > *, body > * > *')).forEach(e=>e.style.overflow='default!important')
Adjust number of levels as necessary. Adjust overrides as necessary. Array.from is probably overkill, but allows for more advanced queries like `e.parentNode.textContent.trim().toLowerCase().indexOf('sponsored')==0`