From 24b467360cde59306addf8565b85ef52733c00c3 Mon Sep 17 00:00:00 2001 From: Shadowfacts Date: Sun, 7 May 2023 14:16:40 -0400 Subject: [PATCH] temp poll --- .../PollFinishedNotificationCollectionViewCell.swift | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Tusker/Screens/Notifications/PollFinishedNotificationCollectionViewCell.swift b/Tusker/Screens/Notifications/PollFinishedNotificationCollectionViewCell.swift index 8dbb39fc..41ab1ef5 100644 --- a/Tusker/Screens/Notifications/PollFinishedNotificationCollectionViewCell.swift +++ b/Tusker/Screens/Notifications/PollFinishedNotificationCollectionViewCell.swift @@ -91,6 +91,9 @@ class PollFinishedNotificationCollectionViewCell: UICollectionViewCell { contentView.addSubview(iconView) vStack.translatesAutoresizingMaskIntoConstraints = false contentView.addSubview(vStack) + let vStackBottomConstraint = vStack.bottomAnchor.constraint(equalTo: contentView.bottomAnchor, constant: -8) + // need something to break during intermediate layouts when the cell imposes a 44pt height :S + vStackBottomConstraint.priority = .init(999) NSLayoutConstraint.activate([ iconView.topAnchor.constraint(equalTo: vStack.topAnchor), iconView.trailingAnchor.constraint(equalTo: contentView.leadingAnchor, constant: 16 + 50), @@ -98,7 +101,7 @@ class PollFinishedNotificationCollectionViewCell: UICollectionViewCell { vStack.leadingAnchor.constraint(equalTo: iconView.trailingAnchor, constant: 8), vStack.trailingAnchor.constraint(equalTo: contentView.trailingAnchor, constant: -16), vStack.topAnchor.constraint(equalTo: contentView.topAnchor, constant: 8), - vStack.bottomAnchor.constraint(equalTo: contentView.bottomAnchor, constant: -8), + vStackBottomConstraint, ]) NotificationCenter.default.addObserver(self, selector: #selector(updateUIForPreferences), name: .preferencesChanged, object: nil)