-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Description
I tried to change the dimensions of an iframe by using this methods:
https://github.com/ampproject/amphtml/tree/master/ads#ad-resizing
I'm sending a request for 320x50 to resize to 300x250.
After this i see the amp-ad container having a height attribute of 50200, while cssText still has "width: 320px; height: 50px;"
I then tried to sniff the code by break on nodes attribute changes and have been stoppen within layoutCallback() method.
There is a line where const newHeight is defined and some comments inline saying /OK/, and here my Chrome on Mac returns 50200. Since one has to define width and height by calling requestResize you never shouldn't have to calc the height here, isn't it? Sure, if responsive is set, but normally...
To reproduce, select the iframe "frame_doubleclick_1" already there in demointegration.
Then send window.context.requestResize('300','250') and the conatiner will get a height of 50200px...