diff --git a/iOS/MainTimeline/Cells/MainTimelineCollectionViewCell.swift b/iOS/MainTimeline/Cells/MainTimelineCollectionViewCell.swift index 0603ea272..6431efd71 100644 --- a/iOS/MainTimeline/Cells/MainTimelineCollectionViewCell.swift +++ b/iOS/MainTimeline/Cells/MainTimelineCollectionViewCell.swift @@ -118,16 +118,7 @@ class MainTimelineCollectionViewCell: UICollectionViewCell { } private func updateIndicatorView(_ state: UICellConfigurationState) { - if cellData.read == false { - if indicatorView.alpha == 0.0 { - indicatorView.alpha = 1.0 - } - UIView.animate(withDuration: Self.indicatorAnimationDuration) { - self.indicatorView.iconImage = Assets.Images.unreadCellIndicator - self.indicatorView.tintColor = (state.isSelected && !state.isSwiped) ? .white : Assets.Colors.secondaryAccent - } - return - } else if cellData.starred { + if cellData.starred { if indicatorView.alpha == 0.0 { indicatorView.alpha = 1.0 } @@ -136,6 +127,15 @@ class MainTimelineCollectionViewCell: UICollectionViewCell { self.indicatorView.tintColor = (state.isSelected && !state.isSwiped) ? .white : Assets.Colors.star } return + } else if cellData.read == false { + if indicatorView.alpha == 0.0 { + indicatorView.alpha = 1.0 + } + UIView.animate(withDuration: Self.indicatorAnimationDuration) { + self.indicatorView.iconImage = Assets.Images.unreadCellIndicator + self.indicatorView.tintColor = (state.isSelected && !state.isSwiped) ? .white : Assets.Colors.secondaryAccent + } + return } else if indicatorView.alpha == 1.0 { UIView.animate(withDuration: Self.indicatorAnimationDuration) { self.indicatorView.alpha = 0.0