@@ -5,11 +5,14 @@ import {
5
5
StyleSheet ,
6
6
Alert ,
7
7
ScrollView ,
8
- Modal
8
+ Modal ,
9
+ Platform
9
10
} from 'react-native' ;
10
11
import Icon from 'react-native-vector-icons/Feather' ;
11
12
import { inject , observer } from 'mobx-react' ;
12
13
14
+ import Info from '../assets/images/SVG/info.svg' ;
15
+
13
16
import Header from '../components/Header' ;
14
17
import Button from '../components/Button' ;
15
18
import TextInput from '../components/TextInput' ;
@@ -45,6 +48,7 @@ interface ActivityExportOptionsState {
45
48
isActivityFetching : boolean ;
46
49
filteredActivity : any ;
47
50
isModalVisible : boolean ;
51
+ showInfoModal : boolean ;
48
52
customFileName : string ;
49
53
fromDate : any ;
50
54
toDate : any ;
@@ -65,6 +69,7 @@ export default class ActivityExportOptions extends React.Component<
65
69
isActivityFetching : true ,
66
70
filteredActivity : [ ] ,
67
71
isModalVisible : false ,
72
+ showInfoModal : false ,
68
73
customFileName : '' ,
69
74
fromDate : null ,
70
75
toDate : null ,
@@ -401,6 +406,59 @@ export default class ActivityExportOptions extends React.Component<
401
406
) ;
402
407
} ;
403
408
409
+ renderInfoModal = ( ) => {
410
+ const { showInfoModal } = this . state ;
411
+ return (
412
+ < Modal
413
+ animationType = "slide"
414
+ transparent
415
+ visible = { showInfoModal }
416
+ onRequestClose = { ( ) => this . setState ( { showInfoModal : false } ) }
417
+ >
418
+ < View
419
+ style = { {
420
+ flex : 1 ,
421
+ justifyContent : 'center' ,
422
+ alignItems : 'center'
423
+ } }
424
+ >
425
+ < View
426
+ style = { {
427
+ backgroundColor : themeColor ( 'secondary' ) ,
428
+ borderRadius : 24 ,
429
+ padding : 20 ,
430
+ alignItems : 'center'
431
+ } }
432
+ >
433
+ < Text
434
+ style = { {
435
+ fontFamily : 'PPNeueMontreal-Book' ,
436
+ color : themeColor ( 'text' ) ,
437
+ fontSize : 20 ,
438
+ marginBottom : 20
439
+ } }
440
+ >
441
+ { Platform . OS === 'android'
442
+ ? localeString (
443
+ 'views.activityExport.explainerAndroid'
444
+ )
445
+ : localeString (
446
+ 'views.activityExport.explaineriOS'
447
+ ) }
448
+ </ Text >
449
+ < Button
450
+ title = { localeString ( 'general.close' ) }
451
+ onPress = { ( ) =>
452
+ this . setState ( { showInfoModal : false } )
453
+ }
454
+ secondary
455
+ />
456
+ </ View >
457
+ </ View >
458
+ </ Modal >
459
+ ) ;
460
+ } ;
461
+
404
462
render ( ) {
405
463
const { isActivityFetching } = this . state ;
406
464
@@ -415,9 +473,25 @@ export default class ActivityExportOptions extends React.Component<
415
473
fontFamily : 'PPNeueMontreal-Book'
416
474
}
417
475
} }
476
+ rightComponent = {
477
+ < TouchableOpacity
478
+ style = { { marginRight : 6 } }
479
+ onPress = { ( ) =>
480
+ this . setState ( { showInfoModal : true } )
481
+ }
482
+ >
483
+ < Info
484
+ stroke = { themeColor ( 'text' ) }
485
+ fill = { themeColor ( 'text' ) }
486
+ width = { 24 }
487
+ height = { 24 }
488
+ />
489
+ </ TouchableOpacity >
490
+ }
418
491
navigation = { this . props . navigation }
419
492
/>
420
493
{ this . renderModal ( ) }
494
+ { this . renderInfoModal ( ) }
421
495
422
496
< View
423
497
style = { {
0 commit comments