@plusscommunities/pluss-circles-app 8.0.4 → 8.0.6-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/module/actions/ChatActions.js +3 -3
- package/dist/module/actions/ChatActions.js.map +1 -1
- package/dist/module/actions/GroupActions.js +18 -18
- package/dist/module/actions/GroupActions.js.map +1 -1
- package/dist/module/actions/index.js +3 -3
- package/dist/module/actions/index.js.map +1 -1
- package/dist/module/actions/types.js +2 -2
- package/dist/module/actions/types.js.map +1 -1
- package/dist/module/assets/fonts.js +1 -1
- package/dist/module/assets/fonts.js.map +1 -1
- package/dist/module/components/chat/Chat.js +83 -101
- package/dist/module/components/chat/Chat.js.map +1 -1
- package/dist/module/components/chat/ChatList.js +49 -49
- package/dist/module/components/chat/ChatList.js.map +1 -1
- package/dist/module/components/chat/ContactsList.js +21 -21
- package/dist/module/components/chat/ContactsList.js.map +1 -1
- package/dist/module/components/chat/KioskPeoplePage.js +38 -37
- package/dist/module/components/chat/KioskPeoplePage.js.map +1 -1
- package/dist/module/components/chat/PeopleContainer.js +5 -5
- package/dist/module/components/chat/PeopleContainer.js.map +1 -1
- package/dist/module/components/chat/PeoplePage.js +41 -41
- package/dist/module/components/chat/PeoplePage.js.map +1 -1
- package/dist/module/components/common/SwipeableUserListing.js +22 -22
- package/dist/module/components/common/SwipeableUserListing.js.map +1 -1
- package/dist/module/components/common/index.js +2 -2
- package/dist/module/components/common/index.js.map +1 -1
- package/dist/module/components/events/EventInvitePopup.js +40 -40
- package/dist/module/components/events/EventInvitePopup.js.map +1 -1
- package/dist/module/components/groups/EditGroup.js +62 -62
- package/dist/module/components/groups/EditGroup.js.map +1 -1
- package/dist/module/components/groups/GroupDetails.js +32 -32
- package/dist/module/components/groups/GroupDetails.js.map +1 -1
- package/dist/module/components/groups/GroupsList.js +10 -10
- package/dist/module/components/groups/GroupsList.js.map +1 -1
- package/dist/module/components/groups/GroupsWidget.js +18 -18
- package/dist/module/components/groups/GroupsWidget.js.map +1 -1
- package/dist/module/components/groups/NewGroup.js +101 -101
- package/dist/module/components/groups/NewGroup.js.map +1 -1
- package/dist/module/components/groups/PublicGroup.js +17 -17
- package/dist/module/components/groups/PublicGroup.js.map +1 -1
- package/dist/module/components/groups/PublicGroupAction.js +39 -39
- package/dist/module/components/groups/PublicGroupAction.js.map +1 -1
- package/dist/module/components/notifications/GroupInvite.js +25 -25
- package/dist/module/components/notifications/GroupInvite.js.map +1 -1
- package/dist/module/components/notifications/GroupInviteAction.js +44 -44
- package/dist/module/components/notifications/GroupInviteAction.js.map +1 -1
- package/dist/module/components/notifications/GroupMessage.js +17 -17
- package/dist/module/components/notifications/GroupMessage.js.map +1 -1
- package/dist/module/components/takeover/TakeoverBackground.js +5 -5
- package/dist/module/components/takeover/TakeoverBackground.js.map +1 -1
- package/dist/module/config/index.js +2 -2
- package/dist/module/config/index.js.map +1 -1
- package/dist/module/core.config.js +1 -1
- package/dist/module/core.config.js.map +1 -1
- package/dist/module/feature.config.js +27 -27
- package/dist/module/feature.config.js.map +1 -1
- package/dist/module/index.js +14 -14
- package/dist/module/index.js.map +1 -1
- package/dist/module/js/Colors.js +1 -1
- package/dist/module/js/Colors.js.map +1 -1
- package/dist/module/js/NavigationService.js +1 -1
- package/dist/module/js/NavigationService.js.map +1 -1
- package/dist/module/js/Styles.js +1 -1
- package/dist/module/js/Styles.js.map +1 -1
- package/dist/module/js/circles/MapStateToDirectMessages.js +2 -2
- package/dist/module/js/circles/MapStateToDirectMessages.js.map +1 -1
- package/dist/module/js/index.js +3 -3
- package/dist/module/js/index.js.map +1 -1
- package/dist/module/reducers/ChatsReducer.js +4 -4
- package/dist/module/reducers/ChatsReducer.js.map +1 -1
- package/dist/module/reducers/GroupsReducer.js +5 -5
- package/dist/module/reducers/GroupsReducer.js.map +1 -1
- package/dist/module/reducers/reducerKeys.js +1 -1
- package/dist/module/reducers/reducerKeys.js.map +1 -1
- package/dist/module/values.config.default.js +25 -25
- package/dist/module/values.config.default.js.map +1 -1
- package/dist/module/values.config.groups.js +25 -25
- package/dist/module/values.config.groups.js.map +1 -1
- package/dist/module/values.config.js +25 -25
- package/dist/module/values.config.js.map +1 -1
- package/dist/module/webapi/circleActions.js +31 -31
- package/dist/module/webapi/circleActions.js.map +1 -1
- package/dist/module/webapi/helper.js +1 -1
- package/dist/module/webapi/helper.js.map +1 -1
- package/dist/module/webapi/index.js +3 -3
- package/dist/module/webapi/index.js.map +1 -1
- package/dist/module/webapi/messageActions.js +10 -10
- package/dist/module/webapi/messageActions.js.map +1 -1
- package/package.json +54 -54
- package/src/actions/ChatActions.js +55 -55
- package/src/actions/GroupActions.js +245 -237
- package/src/actions/index.js +3 -3
- package/src/actions/types.js +2 -2
- package/src/assets/fonts.js +1 -1
- package/src/components/chat/Chat.js +730 -669
- package/src/components/chat/ChatList.js +603 -512
- package/src/components/chat/ContactsList.js +186 -169
- package/src/components/chat/KioskPeoplePage.js +315 -291
- package/src/components/chat/PeopleContainer.js +14 -14
- package/src/components/chat/PeoplePage.js +450 -383
- package/src/components/common/SwipeableUserListing.js +118 -106
- package/src/components/common/index.js +2 -2
- package/src/components/events/EventInvitePopup.js +587 -505
- package/src/components/groups/EditGroup.js +607 -538
- package/src/components/groups/GroupDetails.js +385 -305
- package/src/components/groups/GroupsList.js +91 -79
- package/src/components/groups/GroupsWidget.js +122 -116
- package/src/components/groups/NewGroup.js +758 -639
- package/src/components/groups/PublicGroup.js +129 -101
- package/src/components/groups/PublicGroupAction.js +312 -244
- package/src/components/notifications/GroupInvite.js +167 -139
- package/src/components/notifications/GroupInviteAction.js +371 -273
- package/src/components/notifications/GroupMessage.js +110 -102
- package/src/components/takeover/TakeoverBackground.js +24 -18
- package/src/config/index.js +4 -4
- package/src/core.config.js +27 -3
- package/src/feature.config.js +257 -245
- package/src/index.js +24 -21
- package/src/js/Colors.js +5 -3
- package/src/js/NavigationService.js +5 -4
- package/src/js/Styles.js +1 -1
- package/src/js/circles/MapStateToDirectMessages.js +6 -6
- package/src/js/index.js +3 -3
- package/src/reducers/ChatsReducer.js +66 -53
- package/src/reducers/GroupsReducer.js +203 -190
- package/src/reducers/reducerKeys.js +1 -1
- package/src/values.config.default.js +29 -29
- package/src/values.config.groups.js +29 -29
- package/src/values.config.js +29 -29
- package/src/webapi/circleActions.js +109 -109
- package/src/webapi/helper.js +1 -1
- package/src/webapi/index.js +3 -3
- package/src/webapi/messageActions.js +47 -47
|
@@ -1,295 +1,393 @@
|
|
|
1
|
-
import React, { Component } from
|
|
2
|
-
import { ScrollView, Text, View, ImageBackground, Dimensions } from 'react-native';
|
|
3
|
-
import { connect } from 'react-redux';
|
|
4
|
-
import _ from 'lodash';
|
|
5
|
-
import moment from 'moment';
|
|
6
|
-
import { LinearGradient } from 'expo-linear-gradient';
|
|
1
|
+
import React, { Component } from "react";
|
|
7
2
|
import {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
|
|
3
|
+
ScrollView,
|
|
4
|
+
Text,
|
|
5
|
+
View,
|
|
6
|
+
ImageBackground,
|
|
7
|
+
Dimensions,
|
|
8
|
+
} from "react-native";
|
|
9
|
+
import { connect } from "react-redux";
|
|
10
|
+
import _ from "lodash";
|
|
11
|
+
import moment from "moment";
|
|
12
|
+
import { LinearGradient } from "expo-linear-gradient";
|
|
13
|
+
import {
|
|
14
|
+
getImageSource,
|
|
15
|
+
TEXT_DARK,
|
|
16
|
+
TEXT_BLUEGREY,
|
|
17
|
+
getFirstName,
|
|
18
|
+
COLOUR_TRANSPARENT,
|
|
19
|
+
LINEGREY,
|
|
20
|
+
getMainBrandingColourFromState,
|
|
21
|
+
StatusBarHeight,
|
|
22
|
+
} from "../../js";
|
|
23
|
+
import {
|
|
24
|
+
Spinner,
|
|
25
|
+
ProfilePic,
|
|
26
|
+
MiddlePopup,
|
|
27
|
+
InlineButton,
|
|
28
|
+
BackButton,
|
|
29
|
+
} from "../common";
|
|
30
|
+
import { handleGroupInvite } from "../../actions";
|
|
31
|
+
import { values } from "../../values.config";
|
|
20
32
|
|
|
21
|
-
const SCREEN_HEIGHT = Dimensions.get(
|
|
33
|
+
const SCREEN_HEIGHT = Dimensions.get("window").height;
|
|
22
34
|
const CARD_IMAGE_HEIGHT = SCREEN_HEIGHT * 0.3;
|
|
23
|
-
const SCREEN_WIDTH = Dimensions.get(
|
|
35
|
+
const SCREEN_WIDTH = Dimensions.get("window").width;
|
|
24
36
|
|
|
25
37
|
class GroupInviteAction extends Component {
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
38
|
+
constructor(props) {
|
|
39
|
+
super(props);
|
|
40
|
+
this.state = {
|
|
41
|
+
group: {},
|
|
42
|
+
loading: false,
|
|
43
|
+
};
|
|
44
|
+
}
|
|
33
45
|
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
46
|
+
UNSAFE_componentWillMount() {
|
|
47
|
+
// this.loadEvent();
|
|
48
|
+
this.setState({ group: this.props.group });
|
|
49
|
+
}
|
|
38
50
|
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
51
|
+
componentWillUnmount() {
|
|
52
|
+
this.props.onClose();
|
|
53
|
+
}
|
|
42
54
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
55
|
+
getShortName(name) {
|
|
56
|
+
if (!name) {
|
|
57
|
+
return name;
|
|
58
|
+
}
|
|
59
|
+
const names = name.split(",")[0].match(/\b\w/g);
|
|
60
|
+
return names && names.length > 0
|
|
61
|
+
? `${names[0]}${names.length > 1 ? names[names.length - 1] : ""}`
|
|
62
|
+
: "";
|
|
63
|
+
}
|
|
50
64
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
65
|
+
acceptInvite() {
|
|
66
|
+
if (this.state.loading) {
|
|
67
|
+
return;
|
|
68
|
+
}
|
|
69
|
+
this.setState({ loading: true });
|
|
70
|
+
this.props.handleGroupInvite(this.state.group, true, this.props.user.uid);
|
|
71
|
+
}
|
|
58
72
|
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
73
|
+
declineInvite() {
|
|
74
|
+
if (!this.state.loading) {
|
|
75
|
+
this.props.handleGroupInvite(this.state.group, false);
|
|
76
|
+
this.props.onClose();
|
|
77
|
+
}
|
|
78
|
+
}
|
|
65
79
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
80
|
+
backClose() {
|
|
81
|
+
// if (!this.state.loading) {
|
|
82
|
+
this.props.onClose();
|
|
83
|
+
// }
|
|
84
|
+
}
|
|
71
85
|
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
86
|
+
renderButtons() {
|
|
87
|
+
if (this.state.loading) {
|
|
88
|
+
return (
|
|
89
|
+
<View
|
|
90
|
+
style={{
|
|
91
|
+
paddingTop: 15,
|
|
92
|
+
flexDirection: "row",
|
|
93
|
+
width: "100%",
|
|
94
|
+
justifyContent: "space-between",
|
|
95
|
+
borderTopWidth: 1,
|
|
96
|
+
borderTopColor: LINEGREY,
|
|
97
|
+
}}
|
|
98
|
+
>
|
|
99
|
+
<Spinner />
|
|
100
|
+
</View>
|
|
101
|
+
);
|
|
102
|
+
}
|
|
103
|
+
return (
|
|
104
|
+
<View
|
|
105
|
+
style={{
|
|
106
|
+
paddingTop: 15,
|
|
107
|
+
flexDirection: "row",
|
|
108
|
+
width: "100%",
|
|
109
|
+
justifyContent: "space-between",
|
|
110
|
+
borderTopWidth: 1,
|
|
111
|
+
borderTopColor: LINEGREY,
|
|
112
|
+
}}
|
|
113
|
+
>
|
|
114
|
+
<InlineButton
|
|
115
|
+
large
|
|
116
|
+
color="#fff"
|
|
117
|
+
style={{
|
|
118
|
+
borderWidth: 1,
|
|
119
|
+
borderColor: this.props.colourBrandingMain,
|
|
120
|
+
width: SCREEN_WIDTH / 2 - 24,
|
|
121
|
+
}}
|
|
122
|
+
onPress={() => {
|
|
123
|
+
this.declineInvite();
|
|
124
|
+
}}
|
|
125
|
+
textStyle={{ color: this.props.colourBrandingMain }}
|
|
126
|
+
>
|
|
127
|
+
Decline Invite
|
|
128
|
+
</InlineButton>
|
|
129
|
+
<InlineButton
|
|
130
|
+
large
|
|
131
|
+
color={this.props.colourBrandingMain}
|
|
132
|
+
style={{
|
|
133
|
+
borderWidth: 1,
|
|
134
|
+
borderColor: this.props.colourBrandingMain,
|
|
135
|
+
width: SCREEN_WIDTH / 2 - 24,
|
|
136
|
+
}}
|
|
137
|
+
onPress={() => {
|
|
138
|
+
this.acceptInvite();
|
|
139
|
+
}}
|
|
140
|
+
>
|
|
141
|
+
{`Join ${_.capitalize(values.entityName)}`}
|
|
142
|
+
</InlineButton>
|
|
143
|
+
</View>
|
|
144
|
+
);
|
|
145
|
+
}
|
|
124
146
|
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
147
|
+
renderPeople() {
|
|
148
|
+
// const source = _.filter([...this.state.group.Audience, ...this.state.group.Invites], item => {
|
|
149
|
+
// return item != null && item.userId !== this.props.user.uid;
|
|
150
|
+
// });
|
|
151
|
+
const source = _.filter([...this.state.group.Audience], (item) => {
|
|
152
|
+
return item != null && item.userId !== this.props.user.uid;
|
|
153
|
+
});
|
|
154
|
+
if (_.isEmpty(source)) {
|
|
155
|
+
return null;
|
|
156
|
+
}
|
|
157
|
+
return (
|
|
158
|
+
<View
|
|
159
|
+
style={{
|
|
160
|
+
borderTopColor: LINEGREY,
|
|
161
|
+
borderTopWidth: 1,
|
|
162
|
+
paddingTop: 8,
|
|
163
|
+
paddingBottom: 16,
|
|
164
|
+
}}
|
|
165
|
+
>
|
|
166
|
+
<Text
|
|
167
|
+
style={[styles.normalText, { fontFamily: "sf-semibold" }]}
|
|
168
|
+
>{`Members (${source.length})`}</Text>
|
|
169
|
+
{source.map((user) => {
|
|
170
|
+
return (
|
|
171
|
+
<View
|
|
172
|
+
key={user.userId}
|
|
173
|
+
style={{
|
|
174
|
+
flexDirection: "row",
|
|
175
|
+
position: "relative",
|
|
176
|
+
marginTop: 8,
|
|
177
|
+
alignItems: "center",
|
|
178
|
+
}}
|
|
179
|
+
>
|
|
180
|
+
<ProfilePic Diameter={40} ProfilePic={user.profilePic} />
|
|
181
|
+
<Text
|
|
182
|
+
style={[
|
|
183
|
+
styles.normalText,
|
|
184
|
+
{
|
|
185
|
+
fontFamily: "sf-semibold",
|
|
186
|
+
marginTop: 0,
|
|
187
|
+
marginLeft: 14,
|
|
188
|
+
lineHeight: 16,
|
|
189
|
+
},
|
|
190
|
+
]}
|
|
191
|
+
>
|
|
192
|
+
{getFirstName(user.displayName)}
|
|
193
|
+
</Text>
|
|
194
|
+
</View>
|
|
195
|
+
);
|
|
196
|
+
})}
|
|
197
|
+
</View>
|
|
198
|
+
);
|
|
199
|
+
}
|
|
151
200
|
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
201
|
+
render() {
|
|
202
|
+
if (_.isEmpty(this.state.group)) {
|
|
203
|
+
return null;
|
|
204
|
+
}
|
|
205
|
+
if (this.props.showingAction) {
|
|
206
|
+
return (
|
|
207
|
+
<MiddlePopup
|
|
208
|
+
onClose={() => {
|
|
209
|
+
this.backClose();
|
|
210
|
+
}}
|
|
211
|
+
>
|
|
212
|
+
<View style={styles.popupContainer}>
|
|
213
|
+
{/* Top Back Button */}
|
|
214
|
+
<View style={styles.backButton}>
|
|
215
|
+
<View style={styles.headerContent}>
|
|
216
|
+
<BackButton
|
|
217
|
+
onPress={() => {
|
|
218
|
+
this.backClose();
|
|
219
|
+
}}
|
|
220
|
+
style={{
|
|
221
|
+
marginLeft: 16,
|
|
222
|
+
}}
|
|
223
|
+
/>
|
|
224
|
+
</View>
|
|
225
|
+
</View>
|
|
226
|
+
<ScrollView
|
|
227
|
+
style={styles.scroll}
|
|
228
|
+
keyboardShouldPersistTaps="always"
|
|
229
|
+
>
|
|
230
|
+
<View
|
|
231
|
+
style={[
|
|
232
|
+
styles.mainHeader,
|
|
233
|
+
this.state.group.Image == null && { height: 80 },
|
|
234
|
+
]}
|
|
235
|
+
>
|
|
236
|
+
<ImageBackground
|
|
237
|
+
Id="image"
|
|
238
|
+
style={[styles.image, { backgroundColor: TEXT_BLUEGREY }]}
|
|
239
|
+
key={this.state.group.Id}
|
|
240
|
+
source={getImageSource(this.state.group.Image)}
|
|
241
|
+
>
|
|
242
|
+
<LinearGradient
|
|
243
|
+
style={styles.gradientOverlay}
|
|
244
|
+
colors={["rgba(0,0,0,0.7)", COLOUR_TRANSPARENT]}
|
|
245
|
+
start={{ x: 0, y: 0 }}
|
|
246
|
+
end={{ x: 0, y: 1 }}
|
|
247
|
+
locations={[0, 0.5]}
|
|
248
|
+
/>
|
|
249
|
+
</ImageBackground>
|
|
250
|
+
</View>
|
|
251
|
+
<View style={{ paddingHorizontal: 16, paddingBottom: 16 }}>
|
|
252
|
+
<View style={styles.titleContainer}>
|
|
253
|
+
<Text style={styles.eventTitle}>
|
|
254
|
+
{this.state.group.Title}
|
|
255
|
+
</Text>
|
|
256
|
+
<View
|
|
257
|
+
style={{
|
|
258
|
+
flexDirection: "row",
|
|
259
|
+
marginTop: 2,
|
|
260
|
+
paddingBottom: 8,
|
|
261
|
+
}}
|
|
262
|
+
>
|
|
263
|
+
<Text
|
|
264
|
+
style={[
|
|
265
|
+
styles.eventTitle,
|
|
266
|
+
{ fontFamily: "sf-semibold", fontSize: 14 },
|
|
267
|
+
]}
|
|
268
|
+
>
|
|
269
|
+
Invited on
|
|
270
|
+
</Text>
|
|
271
|
+
<Text
|
|
272
|
+
style={[
|
|
273
|
+
styles.eventTitle,
|
|
274
|
+
{
|
|
275
|
+
marginLeft: 24,
|
|
276
|
+
fontSize: 14,
|
|
277
|
+
fontFamily: "sf-regular",
|
|
278
|
+
},
|
|
279
|
+
]}
|
|
280
|
+
>
|
|
281
|
+
{moment(this.state.group.Timestamp).format(
|
|
282
|
+
"MMMM Do, YYYY",
|
|
283
|
+
)}
|
|
284
|
+
</Text>
|
|
285
|
+
</View>
|
|
286
|
+
</View>
|
|
287
|
+
{!_.isEmpty(this.state.group.Description) && (
|
|
288
|
+
<View
|
|
289
|
+
style={{
|
|
290
|
+
borderTopColor: LINEGREY,
|
|
291
|
+
borderTopWidth: 1,
|
|
292
|
+
paddingTop: 8,
|
|
293
|
+
paddingBottom: 16,
|
|
294
|
+
}}
|
|
295
|
+
>
|
|
296
|
+
<Text
|
|
297
|
+
style={[styles.normalText, { fontFamily: "sf-semibold" }]}
|
|
298
|
+
>
|
|
299
|
+
Description
|
|
300
|
+
</Text>
|
|
301
|
+
<Text style={[styles.normalText]}>
|
|
302
|
+
{this.state.group.Description}
|
|
303
|
+
</Text>
|
|
304
|
+
</View>
|
|
305
|
+
)}
|
|
306
|
+
{this.renderPeople()}
|
|
307
|
+
</View>
|
|
308
|
+
</ScrollView>
|
|
309
|
+
<View style={styles.buttonContainer}>{this.renderButtons()}</View>
|
|
310
|
+
</View>
|
|
311
|
+
</MiddlePopup>
|
|
312
|
+
);
|
|
313
|
+
}
|
|
314
|
+
return null;
|
|
315
|
+
}
|
|
220
316
|
}
|
|
221
317
|
|
|
222
318
|
const styles = {
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
319
|
+
backButton: {
|
|
320
|
+
position: "absolute",
|
|
321
|
+
left: 0,
|
|
322
|
+
top: 0,
|
|
323
|
+
zIndex: 10,
|
|
324
|
+
elevation: 10,
|
|
325
|
+
height: 70,
|
|
326
|
+
},
|
|
327
|
+
headerContent: {
|
|
328
|
+
alignSelf: "stretch",
|
|
329
|
+
flexDirection: "row",
|
|
330
|
+
flex: 1,
|
|
331
|
+
paddingTop: StatusBarHeight(10),
|
|
332
|
+
},
|
|
333
|
+
popupContainer: {
|
|
334
|
+
borderRadius: 0,
|
|
335
|
+
backgroundColor: "#fff",
|
|
336
|
+
width: SCREEN_WIDTH,
|
|
337
|
+
flex: 1,
|
|
338
|
+
},
|
|
339
|
+
scroll: {
|
|
340
|
+
flex: 1,
|
|
341
|
+
backgroundColor: "#fff",
|
|
342
|
+
},
|
|
343
|
+
buttonContainer: {
|
|
344
|
+
paddingBottom: 16,
|
|
345
|
+
paddingHorizontal: 16,
|
|
346
|
+
},
|
|
347
|
+
mainHeader: {
|
|
348
|
+
position: "relative",
|
|
349
|
+
height: CARD_IMAGE_HEIGHT,
|
|
350
|
+
width: SCREEN_WIDTH,
|
|
351
|
+
},
|
|
352
|
+
gradientOverlay: {
|
|
353
|
+
flex: 1,
|
|
354
|
+
},
|
|
355
|
+
image: {
|
|
356
|
+
backgroundColor: "#fff",
|
|
357
|
+
position: "relative",
|
|
358
|
+
width: undefined,
|
|
359
|
+
height: undefined,
|
|
360
|
+
flex: 1,
|
|
361
|
+
},
|
|
362
|
+
titleContainer: {
|
|
363
|
+
/* flex: 1,
|
|
268
364
|
flexDirection: 'row-reverse', */
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
365
|
+
paddingTop: 20,
|
|
366
|
+
},
|
|
367
|
+
eventTitle: {
|
|
368
|
+
fontFamily: "sf-bold",
|
|
369
|
+
fontSize: 24,
|
|
370
|
+
lineHeight: 32,
|
|
371
|
+
color: TEXT_DARK,
|
|
372
|
+
backgroundColor: "transparent",
|
|
373
|
+
},
|
|
374
|
+
normalText: {
|
|
375
|
+
fontFamily: "sf-regular",
|
|
376
|
+
fontSize: 14,
|
|
377
|
+
lineHeight: 20,
|
|
378
|
+
color: TEXT_DARK,
|
|
379
|
+
marginTop: 6,
|
|
380
|
+
backgroundColor: "transparent",
|
|
381
|
+
},
|
|
286
382
|
};
|
|
287
383
|
|
|
288
|
-
const mapStateToProps = state => {
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
384
|
+
const mapStateToProps = (state) => {
|
|
385
|
+
return {
|
|
386
|
+
user: state.user,
|
|
387
|
+
colourBrandingMain: getMainBrandingColourFromState(state),
|
|
388
|
+
};
|
|
293
389
|
};
|
|
294
390
|
|
|
295
|
-
export default connect(mapStateToProps, { handleGroupInvite })(
|
|
391
|
+
export default connect(mapStateToProps, { handleGroupInvite })(
|
|
392
|
+
GroupInviteAction,
|
|
393
|
+
);
|