Add haptic feedbacks when changing account

This commit is contained in:
Thomas Ricouard 2023-03-09 06:36:38 +01:00
parent 0709ce0958
commit 82dfeffaec

View file

@ -93,11 +93,13 @@ public struct AppAccountView: View {
let account = viewModel.account
{
routerPath.navigate(to: .accountSettingsWithAccount(account: account, appAccount: viewModel.appAccount))
HapticManager.shared.fireHaptic(of: .buttonPress)
} else {
var transation = Transaction()
transation.disablesAnimations = true
withTransaction(transation) {
appAccounts.currentAccount = viewModel.appAccount
HapticManager.shared.fireHaptic(of: .notification(.success))
}
}
}