From 16a814a27c4df96e6a1a11bcdc84df93dbd3528e Mon Sep 17 00:00:00 2001 From: Jed Fox Date: Fri, 2 Dec 2022 16:02:05 -0500 Subject: [PATCH] Cap the height of the status card --- .../Sources/MastodonUI/View/Content/StatusCardControl.swift | 3 +++ 1 file changed, 3 insertions(+) diff --git a/MastodonSDK/Sources/MastodonUI/View/Content/StatusCardControl.swift b/MastodonSDK/Sources/MastodonUI/View/Content/StatusCardControl.swift index 6b5a02da0..6bc8d6789 100644 --- a/MastodonSDK/Sources/MastodonUI/View/Content/StatusCardControl.swift +++ b/MastodonSDK/Sources/MastodonUI/View/Content/StatusCardControl.swift @@ -144,6 +144,9 @@ public final class StatusCardControl: UIControl { // This priority is important or constraints break; // it still renders the card correctly. .priority(.defaultLow - 1), + // set a reasonable max height for very tall images + imageView.heightAnchor + .constraint(lessThanOrEqualToConstant: 400) ] case .compact: containerStackView.alignment = .center