From 3525d94f71b2bdc16e8ad24f4e4d339619e94752 Mon Sep 17 00:00:00 2001 From: Thomas Ricouard Date: Tue, 18 Jul 2023 08:21:34 +0200 Subject: [PATCH] Add a mention / reply button on user profile navigation --- .../Account/Sources/Account/AccountDetailView.swift | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/Packages/Account/Sources/Account/AccountDetailView.swift b/Packages/Account/Sources/Account/AccountDetailView.swift index d3ac5069..60ae3a8a 100644 --- a/Packages/Account/Sources/Account/AccountDetailView.swift +++ b/Packages/Account/Sources/Account/AccountDetailView.swift @@ -305,7 +305,18 @@ public struct AccountDetailView: View { @ToolbarContentBuilder private var toolbarContent: some ToolbarContent { - ToolbarItem(placement: .navigationBarTrailing) { + ToolbarItemGroup(placement: .navigationBarTrailing) { + if !viewModel.isCurrentUser { + Button { + if let account = viewModel.account { + routerPath.presentedSheet = .mentionStatusEditor(account: account, + visibility: preferences.postVisibility) + } + } label: { + Image(systemName: "arrowshape.turn.up.left") + } + } + Menu { AccountDetailContextMenu(viewModel: viewModel)