-
Notifications
You must be signed in to change notification settings - Fork 3.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
amp-carousel: Sometimes displays nothing due to incorrect layout box #14519
Comments
@dlehmhus I have not been able to reproduce but based on your screenshots, I am can see it is definitely happening. Likely a race condition. Does it reliably happen for you on desktop non-private mode Chrome? |
@aghassemi yes it happens reliably for me. The same happens on a couple of my coworkers computers. We all use MacBooks on macOS 10.13.3. I also witnessed the problem on a smartphone (Android 8.1.0 / Chrome 65.0.3325.109)! |
This issue seems to be in Pending Triage for awhile. @aghassemi Please triage this to an appropriate milestone. |
1 similar comment
This issue seems to be in Pending Triage for awhile. @aghassemi Please triage this to an appropriate milestone. |
We are experiencing a similar issue when navigating from a Google Search result link to the AMP page. The amp-carousel seems to not be initialized. The photos are not showing and the controls do not work. |
This sounds like it could be caused by #19876. I can try to fix a few potential issues that may be causing this, but without a page to reproduce it on, I won't be sure whether or not I fixed the issue. |
Sorry for the late reply here. This can be reproduced by:
I can reproduce this every time I repeat those steps. |
@dijs Thanks for the steps, I was able to reproduce in incognito mode, will take a look. |
I am not able to reproduce 100% of the time, but I can reproduce a fair amount of the time. Clearing the browser cache may help reproduce it more often. I tried changing network speed without much luck, but it seems related to timing. It looks like the carousel thinks it is not in the viewport ( I noticed the carousel is using $0.implementation_.getLayoutBox()
bottom: 315
height: 0
left: 0
right: 360
top: 315
width: 360
x: 0
y: 315 /cc @jridgewell @choumx |
I wonder if it is possible if the run time runs when the document has parsed the custom element, but before the browser has actually done layout + render (i.e. the developer's inlined CSS has not yet applied). Edit: I suppose not, because the run time's measuring would cause a layout. |
Where does the height get set on the carousel? I thought it had a weird container type. |
This carousel is |
Until we figure out the source of the problem, is there a temporarily fix we could implement for now? |
The likeliest explanation is this is caused by flex-box. Is it necessary for your usecase? |
We are using flexbox across all of our components. |
Closing this issue due to low activity. Please file a new issue if needed. |
What's the issue?
AMP Carousel sporadically won't initialize / won't show any images on side load.
After side load:
After resizing the browser window:
How do we reproduce the issue?
https://www.cellular.de/
Click a couple of times on the icon in the upper left corner
What browsers are affected?
Chrome Version 65.0.3325.181 (It is working fine in private mode)
Which AMP version is affected?
Version 1522422854768
The text was updated successfully, but these errors were encountered: