diff --git a/native/account/logged-out-modal.react.js b/native/account/logged-out-modal.react.js --- a/native/account/logged-out-modal.react.js +++ b/native/account/logged-out-modal.react.js @@ -466,12 +466,7 @@ } if (this.state.mode === 'siwe') { - panel = ( - - ); + panel = ; } else if (this.state.mode === 'log-in') { panel = ( void, - +opacityValue: Animated.Node, -}; -type Props = { - ...BaseProps, - // Redux state - +logInExtraInfo: () => LogInExtraInfo, - // Redux dispatch functions - +dispatchActionPromise: DispatchActionPromise, - // async functions that hit server APIs - +registerAction: (registerInfo: RegisterInfo) => Promise, -}; +function SIWEPanel(): React.Node { + const navContext = React.useContext(NavContext); + const dispatchActionPromise = useDispatchActionPromise(); + const registerAction = useServerCall(register); + + const logInExtraInfo = useSelector(state => + nativeLogInExtraInfoSelector({ + redux: state, + navContext, + }), + ); -function SIWEPanel({ - logInExtraInfo, - dispatchActionPromise, - registerAction, -}: Props) { const handleSIWE = React.useCallback( ({ address, signature }) => { // this is all mocked from register-panel @@ -73,31 +60,9 @@ }, [handleSIWE], ); + const source = React.useMemo(() => ({ uri: commSIWE }), []); return ; } -const ConnectedSIWEPanel: React.ComponentType = React.memo( - function ConnectedRegisterPanel(props: BaseProps) { - const navContext = React.useContext(NavContext); - const logInExtraInfo = useSelector(state => - nativeLogInExtraInfoSelector({ - redux: state, - navContext, - }), - ); - - const dispatchActionPromise = useDispatchActionPromise(); - const callRegister = useServerCall(register); - - return ( - - ); - }, -); -export default ConnectedSIWEPanel; +export default SIWEPanel;