Images duplicated in Reader View for all New York Times articles because we keep `visibility: hidden` images in the DOM and strip the styles
Categories
(Toolkit :: Reader Mode, defect, P3)
Tracking
()
People
(Reporter: punnamvarun, Unassigned)
References
()
Details
(Whiteboard: [reader-mode-readability-algorithm])
Attachments
(2 files)
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:73.0) Gecko/20100101 Firefox/73.0
Steps to reproduce:
- Open any New York Times article that begins with an image
- Enter Reader View
Actual results:
Once in Reader View, one is presented with the opening image displayed twice, one right above the other. Attached is an image displayed one such duplication on the article "Pier 1 Imports Files for Bankruptcy and Seeks a Buyer."
Expected results:
Reader view should have displayed the initial image only once
Comment 1•5 years ago
|
||
Bugbug thinks this bug should belong to this component, but please revert this change in case of error.
Comment 2•5 years ago
|
||
Looks like the NYT have some kind of lazy-loading setup that uses visibility:hidden
to hide the image and then clone it to another node, or something like that (either way, they end up with 2 images in the DOM), and readability doesn't strip the hidden one, leading to 2 visible images in reader mode.
Comment 3•5 years ago
|
||
On nightlies with the changes from bug 1618969, this appears to be fixed. \o/
Comment 4•5 years ago
|
||
For reference, I couldn't reproduce the issue with every article; https://www.nytimes.com/2020/02/17/business/pier1-bankruptcy.html seems to be broken on beta and working on current nightly though, so I hope/assume that means it's fixed.
Updated•5 years ago
|
Comment 5•5 years ago
|
||
I can still reproduce this issue using https://www.nytimes.com/2020/02/17/business/pier1-bankruptcy.html or https://www.nytimes.com/2020/03/18/us/politics/china-virus.html?action=click&module=Spotlight&pgtype=Homepage article on Fx 76.0a1 and 75.0b5. The reproducibility is hovever not consistent.
Updated•5 years ago
|
Updated•5 years ago
|
Updated•5 years ago
|
Updated•2 years ago
|
Comment 6•11 months ago
|
||
bug 1870886 (using readability 0.5.0) should fix this.
Comment 7•11 months ago
|
||
This should be fixed in Nightly 123 later today (once a build with bug 1870886 appears).
Comment 8•10 months ago
•
|
||
I have reproduced this issue using Firefox 75.0a1 (2020.02.17) on Windows 10.
I can confirm this issue is fixed, I verified using latest Nightly Firefox 123.0a1 on Windows 10, macOS 12 and on Ubuntu 22, Reader view displayed the initial image only once.
I can still reproduce the issue on Firefox 122.0b9 and on Firefox 122.0.
Updated•10 months ago
|
Updated•10 months ago
|
Description
•