       }
       oldRightSideSnapshotView.image = UIGraphicsGetImageFromCurrentImageContext()
       UIGraphicsEndImageContext()
-      addSubview(oldRightSideSnapshotView)
+      containerView.addSubview(oldRightSideSnapshotView)
       oldRightSideSnapshotView.frame = CGRect(x: oldCellFrame.maxX + space, y: cellFrame.minY, width: cellFrame.width, height: cellFrame.height)
       oldRightSideSnapshotView.tag = AnimationItem.oldRightSide.tag
     }
     
     
     // MARK: Reload collection view & force to layout
+    collectionView.collectionViewLayout.invalidateLayout()
     if collectionView.numberOfItems(inSection: 0) > 0 {
       let path = IndexPath(item: 0, section: 0)
       collectionView.scrollToItem(at: path, at: UICollectionViewScrollPosition.centeredHorizontally, animated: false)

    
    // Set new index to temporary property
    lastExpandedItemIndex = expandedItemIndex
  }
  
  @objc fileprivate func handlePanGesture(_ gesture: UIPanGestureRecognizer) {

    
    // Remove all snapshot layers
    let tags = AnimationItem.all.map { $0.tag }
    for subview in subviews + containerView.subviews {
      if tags.contains(subview.tag) {
        subview.removeFromSuperview()
      }
