@@ -7,6 +7,7 @@ import React, {
7
7
} from 'react' ;
8
8
import { useTranslation } from 'react-i18next' ;
9
9
import { StyleSheet , TouchableOpacity , View } from 'react-native' ;
10
+ import { FadeIn , FadeOut } from 'react-native-reanimated' ;
10
11
11
12
import AmountToggle from '../../../components/AmountToggle' ;
12
13
import Biometrics from '../../../components/Biometrics' ;
@@ -16,6 +17,7 @@ import LightningSyncing from '../../../components/LightningSyncing';
16
17
import SafeAreaInset from '../../../components/SafeAreaInset' ;
17
18
import SwipeToConfirm from '../../../components/SwipeToConfirm' ;
18
19
import useColors from '../../../hooks/colors' ;
20
+ import useKeyboard , { Keyboard } from '../../../hooks/keyboard' ;
19
21
import { useAppDispatch , useAppSelector } from '../../../hooks/redux' ;
20
22
import type { SendScreenProps } from '../../../navigation/types' ;
21
23
import {
@@ -25,7 +27,7 @@ import {
25
27
} from '../../../store/reselect/settings' ;
26
28
import { addPendingPayment } from '../../../store/slices/lightning' ;
27
29
import { EActivityType } from '../../../store/types/activity' ;
28
- import { BottomSheetTextInput } from '../../../styles/components' ;
30
+ import { AnimatedView , BottomSheetTextInput } from '../../../styles/components' ;
29
31
import { Checkmark , LightningHollow } from '../../../styles/icons' ;
30
32
import { BodySSB , Caption13Up } from '../../../styles/text' ;
31
33
import { FeeText } from '../../../utils/fees' ;
@@ -34,7 +36,6 @@ import {
34
36
payLightningInvoice ,
35
37
} from '../../../utils/lightning' ;
36
38
import { handleLnurlPay } from '../../../utils/lnurl' ;
37
- import { Keyboard } from '../../../hooks/keyboard' ;
38
39
39
40
const Section = memo (
40
41
( {
@@ -67,6 +68,7 @@ const LNURLConfirm = ({
67
68
} : SendScreenProps < 'LNURLConfirm' > ) : ReactElement => {
68
69
const { t } = useTranslation ( 'wallet' ) ;
69
70
const { amount, pParams, url } = route . params ;
71
+ const { keyboardShown } = useKeyboard ( ) ;
70
72
const dispatch = useAppDispatch ( ) ;
71
73
const pin = useAppSelector ( pinSelector ) ;
72
74
const pinForPayments = useAppSelector ( pinForPaymentsSelector ) ;
@@ -183,33 +185,43 @@ const LNURLConfirm = ({
183
185
onPress = { fixedAmount ? undefined : handleGoBack }
184
186
/>
185
187
186
- < View style = { styles . sectionContainer } >
187
- < Section
188
- title = { t ( 'send_invoice' ) }
189
- value = {
190
- < BodySSB numberOfLines = { 1 } ellipsizeMode = "middle" >
191
- { url }
192
- </ BodySSB >
193
- }
194
- />
195
- </ View >
188
+ { ! keyboardShown && (
189
+ < AnimatedView
190
+ style = { styles . sectionContainer }
191
+ entering = { FadeIn }
192
+ exiting = { FadeOut } >
193
+ < Section
194
+ title = { t ( 'send_invoice' ) }
195
+ value = {
196
+ < BodySSB numberOfLines = { 1 } ellipsizeMode = "middle" >
197
+ { url }
198
+ </ BodySSB >
199
+ }
200
+ />
201
+ </ AnimatedView >
202
+ ) }
196
203
197
- < View style = { styles . sectionContainer } >
198
- < Section
199
- title = { t ( 'send_fee_and_speed' ) }
200
- value = {
201
- < >
202
- < LightningHollow
203
- style = { styles . icon }
204
- color = "purple"
205
- height = { 16 }
206
- width = { 16 }
207
- />
208
- < BodySSB > { FeeText . instant . title } (±$0.01)</ BodySSB >
209
- </ >
210
- }
211
- />
212
- </ View >
204
+ { ! keyboardShown && (
205
+ < AnimatedView
206
+ style = { styles . sectionContainer }
207
+ entering = { FadeIn }
208
+ exiting = { FadeOut } >
209
+ < Section
210
+ title = { t ( 'send_fee_and_speed' ) }
211
+ value = {
212
+ < >
213
+ < LightningHollow
214
+ style = { styles . icon }
215
+ color = "purple"
216
+ height = { 16 }
217
+ width = { 16 }
218
+ />
219
+ < BodySSB > { FeeText . instant . title } (±$0.01)</ BodySSB >
220
+ </ >
221
+ }
222
+ />
223
+ </ AnimatedView >
224
+ ) }
213
225
214
226
{ pParams . commentAllowed > 0 && (
215
227
< View style = { styles . sectionContainer } >
0 commit comments