@@ -2,6 +2,20 @@ import _ from 'lodash';
2
2
import React , { Component } from 'react' ;
3
3
import { Constants , View , Text , Button , Image , FeatureHighlight } from 'react-native-ui-lib' ; // eslint-disable-line
4
4
5
+ const titles = [ 'Get Notified' , 'Title two is a long title that will get cut' , 'Title number three' ,
6
+ 'Title number four' , 'Title number five' , 'Title number six' ] ;
7
+ const messages = [
8
+ 'Important notifications appear right on your clubs and groups. Tap them to get more information about the most' +
9
+ 'important things that you should pay attention to.' ,
10
+ 'Short message with information about the above highlighted feature' ,
11
+ 'A long message, that will get cut, with information about the highlighted feature, like: Important notifications' +
12
+ ' appear right on your clubs and groups. Tap them to get the important things that you should pay attention to.' ,
13
+ 'Very short message' ,
14
+ 'Short message with information about the below highlighted feature' ,
15
+ 'Important notifications appear right on your clubs and groups. Tap them to get more information about the most' +
16
+ 'important things that you should pay attention to.' ,
17
+ ] ;
18
+
5
19
class FeatureHighlightScreen extends Component {
6
20
7
21
constructor ( props ) {
@@ -51,15 +65,15 @@ class FeatureHighlightScreen extends Component {
51
65
}
52
66
53
67
renderHighlighterOverlay ( ) {
54
- const { showFTE} = this . state ;
68
+ const { showFTE, currentTargetIndex } = this . state ;
55
69
return (
56
70
< FeatureHighlight
57
71
visible = { showFTE }
58
- title = "Get Notified"
59
- message = "Important notifications appear right on your clubs and groups.
60
- Tap them to get more information about the most important things that you should pay attention to."
72
+ title = { titles [ currentTargetIndex ] }
73
+ message = { messages [ currentTargetIndex ] }
61
74
confirmButtonProps = { { label : 'Got It' , onPress : this . moveNext } }
62
- getTarget = { ( ) => this . targets [ this . state . currentTargetIndex ] }
75
+ onBackgroundPress = { this . closeHighlight }
76
+ getTarget = { ( ) => this . targets [ currentTargetIndex ] }
63
77
// highlightFrame={{x: 30, y: 70, width: 150, height: 30}}
64
78
// highlightFrame={{x: 175, y: 334, width: 150, height: 56}}
65
79
/>
@@ -85,7 +99,8 @@ class FeatureHighlightScreen extends Component {
85
99
marginT-40 marginR-60 bg-cyan30
86
100
style = { { width : 50 , height : 70 } }
87
101
testID = { '2' }
88
- ref = { r => ( this . addTarget ( r ) ) } />
102
+ ref = { r => ( this . addTarget ( r ) ) }
103
+ />
89
104
< View marginT-40 bg-violet30 style = { { width : 70 , height : 50 } } testID = { '3' } ref = { r => ( this . addTarget ( r ) ) } />
90
105
</ View >
91
106
< View
0 commit comments