From c8c7f2d29d275770c9ffd64baf2ac1a8fa1e7461 Mon Sep 17 00:00:00 2001 From: Thomas Ricouard Date: Wed, 22 Feb 2023 18:49:17 +0100 Subject: [PATCH] Don't include post actions button in capture mode --- Packages/Status/Sources/Status/Row/StatusRowView.swift | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Packages/Status/Sources/Status/Row/StatusRowView.swift b/Packages/Status/Sources/Status/Row/StatusRowView.swift index 9aa5098f..8ce37c17 100644 --- a/Packages/Status/Sources/Status/Row/StatusRowView.swift +++ b/Packages/Status/Sources/Status/Row/StatusRowView.swift @@ -7,6 +7,7 @@ import Shimmer import SwiftUI public struct StatusRowView: View { + @Environment(\.isInCaptureMode) private var isInCaptureMode: Bool @Environment(\.redactionReasons) private var reasons @Environment(\.isCompact) private var isCompact: Bool @@ -69,7 +70,7 @@ public struct StatusRowView: View { .accessibilityAction { viewModel.navigateToDetail() } - if viewModel.showActions, theme.statusActionsDisplay != .none { + if viewModel.showActions, theme.statusActionsDisplay != .none, !isInCaptureMode { StatusRowActionsView(viewModel: viewModel) .padding(.top, 8) .tint(viewModel.isFocused ? theme.tintColor : .gray)