初始化

$('.photo-gallery').on('click','.photo-gallery__figure',function (e) {
  e.preventDefault();
  createPhotoSwipe(e.currentTarget);
});