Skip to content

Commit

Permalink
IOS-2575 Fix featured relation height
Browse files Browse the repository at this point in the history
  • Loading branch information
joe-pusya committed Apr 2, 2024
1 parent 1d5222d commit e99814a
Showing 1 changed file with 6 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,14 @@ final class FeaturedRelationsBlockViewModel: BlockViewModelProtocol {
self.collectionController = collectionController
self.onRelationTap = onRelationValueTap

document.featuredRelationsForEditorPublisher.receiveOnMain().sink { [weak self] newFeaturedRelations in
guard let self else { return }
if featuredRelationValues != newFeaturedRelations {
document.featuredRelationsForEditorPublisher
.receiveOnMain()
.removeDuplicates()
.sink { [weak self] newFeaturedRelations in
guard let self else { return }
self.featuredRelationValues = newFeaturedRelations
collectionController.reconfigure(items: [.block(self)])
}
}.store(in: &cancellables)
}.store(in: &cancellables)
}

func makeContentConfiguration(maxWidth _: CGFloat) -> UIContentConfiguration {
Expand Down

0 comments on commit e99814a

Please sign in to comment.