amphtml icon indicating copy to clipboard operation
amphtml copied to clipboard

[AMP native app install banner] - The banner didn't appear on the bottom portion of the screen (landscape mode).

Open gkamasheva opened this issue 10 years ago • 7 comments

Short description of your issue:

The banner didn't appear on the bottom portion of the screen, without having to scroll all the way down to the bottom of the page (landscape mode).

How do we reproduce the issue?

  1. Open Safari Browser.
  2. Navigate to https://amp-mk-3.herokuapp.com/examples/viewer.html
  3. Rotate the device to landscape mode.
  4. Click on "Two" at the top of the page
  5. Scroll down page and find a banner. 5.

What browsers are affected?

Device: Apple iPhone 5C MG2E2LL/A (IOS 9.2.1, Safari browser)

gkamasheva avatar Sep 26 '16 21:09 gkamasheva

/to @mkhatib

jridgewell avatar Sep 26 '16 21:09 jridgewell

I am unable to repro this exactly. But I can see the viewer example have problems rendering correctly on older iOS - fixing this soon.

mkhatib avatar Sep 27 '16 00:09 mkhatib

Actually nevermind, I am able to reproduce. Looking into it.

image

mkhatib avatar Sep 27 '16 00:09 mkhatib

@dvoytenko looks like we might have a problem with the fixed layer on iOS in landscape mode. This seems to affect both sticky-ads and amp-app-banner inside viewer.html only.

I am thinking this might be about the viewer.html example code. Are we missing something there?

mkhatib avatar Sep 27 '16 02:09 mkhatib

@mkhatib So what's happening? Does it not recalculate offsets when orientation changes?

dvoytenko avatar Sep 28 '16 19:09 dvoytenko

I don't think it's about orientation changes, because even when the page is loaded in landscape mode it seems this happens. Not entirely sure what's happening.

I am wondering if this might already be happening in the google.com AMP viewer - will try to look for examples that triggers a sticky ad or see if the user notification have the same issue or not - that might be easier to trigger.

mkhatib avatar Sep 28 '16 19:09 mkhatib

@dvoytenko tracked the issue down to iOS window.innerHeight and the height of the viewer being set larger than that. Setting the proper size of the viewer fixes it.

As this is not a bug in amp-app-banner I am closing this one.

mkhatib avatar Sep 30 '16 20:09 mkhatib