documentation for the onImagesReplaced callback