diff --git a/extensions/amp-lightbox-gallery/0.1/amp-lightbox-gallery.js b/extensions/amp-lightbox-gallery/0.1/amp-lightbox-gallery.js index 075bc36d8f01..b5726b8d4e85 100644 --- a/extensions/amp-lightbox-gallery/0.1/amp-lightbox-gallery.js +++ b/extensions/amp-lightbox-gallery/0.1/amp-lightbox-gallery.js @@ -959,6 +959,7 @@ export class AmpLightboxGallery extends AMP.BaseElement { // Prepare the actual image animation. imageAnimation = prepareImageAnimation({ styleContainer: this.getAmpDoc().getHeadNode(), + transitionContainer: this.getAmpDoc().getBody(), srcImg, targetImg, srcImgRect: undefined, @@ -1479,5 +1480,5 @@ function lightboxManagerForDoc(element) { AMP.extension(TAG, '0.1', AMP => { AMP.registerElement(TAG, AmpLightboxGallery, CSS); AMP.registerServiceForDoc('amp-lightbox-manager', LightboxManager); - Services.extensionsFor(global).addDocFactory(installLightboxGallery); + Services.extensionsFor(AMP.win).addDocFactory(installLightboxGallery); });