amphtml icon indicating copy to clipboard operation
amphtml copied to clipboard

[amp-next-page] v1.0 not working if in first viewport

Open noodles opened this issue 6 years ago • 4 comments

#29855 What's the issue?

amp-next-page does not work at all if the component appears in the first viewport

next-page-demo glitch me_1_0issue html(Moto G4)

How do we reproduce the issue?

Create an AMP page with with the amp-next-page component but only add enough text/content so that the amp-next-component is visible in the first viewport.

v1.0 issue example

Adding more content to push the amp-next-page component out of the first viewport will fix the isse;

v1.0 fix example

What browsers are affected?

All browsers

noodles avatar Aug 20 '20 23:08 noodles

Related https://github.com/ampproject/amphtml/issues/29936

nainar avatar Aug 23 '20 01:08 nainar

@nainar @wassgha this unit test https://github.com/ampproject/amphtml/blob/master/extensions/amp-next-page/1.0/test/test-amp-next-page.js#L332 leads me to believe that amp-next-page was designed to be displayed only when the user scrolls below the first viewport. Do we want to support this use case?

dmanek avatar Jan 11 '21 05:01 dmanek

That's correct behavior. This is to avoid layout shift

wassgha avatar Jan 11 '21 15:01 wassgha

Closing this issue as WAI.

dmanek avatar Jan 11 '21 20:01 dmanek