From 2f3fc4fe4e799084799631323b73fc97820144c8 Mon Sep 17 00:00:00 2001
From: Paul Frazee <pfrazee@gmail.com>
Date: Mon, 6 Mar 2023 21:37:48 -0600
Subject: Handle-change modal with custom domain support (#273)

* Dont append the server's domain name when a custom domain is used

* Update the settings look & feel and add a tool to remove accounts from the switcher

* Try not rendering the bottomsheet when no modal is active.

There are cases where the bottomsheet decides to show itself when
it's not supposed to. It seems obvious to do what this change is
doing -- just dont render bottomsheet if no modal is active -- but
previously we experienced issues with that approach. This time it
seems to be working, so we're gonna yolo try it.

* Implement a handle-change modal with support for custom domains (closes #65)
---
 src/view/com/modals/Modal.tsx | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

(limited to 'src/view/com/modals/Modal.tsx')

diff --git a/src/view/com/modals/Modal.tsx b/src/view/com/modals/Modal.tsx
index 1346f12f3..d3a02e0da 100644
--- a/src/view/com/modals/Modal.tsx
+++ b/src/view/com/modals/Modal.tsx
@@ -12,6 +12,7 @@ import * as ReportPostModal from './ReportPost'
 import * as RepostModal from './Repost'
 import * as ReportAccountModal from './ReportAccount'
 import * as DeleteAccountModal from './DeleteAccount'
+import * as ChangeHandleModal from './ChangeHandle'
 import {usePalette} from 'lib/hooks/usePalette'
 import {StyleSheet} from 'react-native'
 
@@ -65,8 +66,11 @@ export const ModalsContainer = observer(function ModalsContainer() {
   } else if (activeModal?.name === 'repost') {
     snapPoints = RepostModal.snapPoints
     element = <RepostModal.Component {...activeModal} />
+  } else if (activeModal?.name === 'change-handle') {
+    snapPoints = ChangeHandleModal.snapPoints
+    element = <ChangeHandleModal.Component {...activeModal} />
   } else {
-    element = <View />
+    return <View />
   }
 
   return (
-- 
cgit 1.4.1

