From 2e5f73ff6149f9ac2834b0417c84b76763ef5ee2 Mon Sep 17 00:00:00 2001
From: Paul Frazee <pfrazee@gmail.com>
Date: Thu, 28 Sep 2023 12:41:44 -0700
Subject: Account quick switch modal (#1567)

* quick switch menu

* Some small tweaks and fixes to the account switch modal

* Factor out the account switcher logic to a hook

* Add haptic feedback on account switcher open

* Fix bad merge

---------

Co-authored-by: Samuel Newman <mozzius@protonmail.com>
---
 src/view/shell/bottom-bar/BottomBar.tsx | 4 ++++
 1 file changed, 4 insertions(+)

(limited to 'src/view/shell/bottom-bar/BottomBar.tsx')

diff --git a/src/view/shell/bottom-bar/BottomBar.tsx b/src/view/shell/bottom-bar/BottomBar.tsx
index 8ba74da2e..4758c5e01 100644
--- a/src/view/shell/bottom-bar/BottomBar.tsx
+++ b/src/view/shell/bottom-bar/BottomBar.tsx
@@ -75,6 +75,9 @@ export const BottomBar = observer(function BottomBarImpl({
   const onPressProfile = React.useCallback(() => {
     onPressTab('MyProfile')
   }, [onPressTab])
+  const onLongPressProfile = React.useCallback(() => {
+    store.shell.openModal({name: 'switch-account'})
+  }, [store])
 
   return (
     <Animated.View
@@ -202,6 +205,7 @@ export const BottomBar = observer(function BottomBarImpl({
           </View>
         }
         onPress={onPressProfile}
+        onLongPress={onLongPressProfile}
         accessibilityRole="tab"
         accessibilityLabel="Profile"
         accessibilityHint=""
-- 
cgit 1.4.1

