@plusscommunities/pluss-core-app 6.1.7 → 6.1.8-auth.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/FollowerActions.js +4 -4
- package/dist/module/actions/FollowerActions.js.map +1 -1
- package/dist/module/actions/MediaActions.js +1 -1
- package/dist/module/actions/MediaActions.js.map +1 -1
- package/dist/module/actions/ResidentActions.js +1 -1
- package/dist/module/actions/ResidentActions.js.map +1 -1
- package/dist/module/actions/UserActions.js +1 -1
- package/dist/module/actions/UserActions.js.map +1 -1
- package/dist/module/actions/UserSettingsActions.js +1 -1
- package/dist/module/actions/UserSettingsActions.js.map +1 -1
- package/dist/module/actions/index.js +5 -5
- package/dist/module/actions/index.js.map +1 -1
- package/dist/module/actions/types.js +16 -16
- package/dist/module/actions/types.js.map +1 -1
- package/dist/module/apis/analyticsActions.js +5 -5
- package/dist/module/apis/analyticsActions.js.map +1 -1
- package/dist/module/apis/contactActions.js +6 -6
- package/dist/module/apis/contactActions.js.map +1 -1
- package/dist/module/apis/eventActions.js +28 -28
- package/dist/module/apis/eventActions.js.map +1 -1
- package/dist/module/apis/fileActions.js +21 -28
- package/dist/module/apis/fileActions.js.map +1 -1
- package/dist/module/apis/followerActions.js +8 -8
- package/dist/module/apis/followerActions.js.map +1 -1
- package/dist/module/apis/index.js +12 -12
- package/dist/module/apis/index.js.map +1 -1
- package/dist/module/apis/notificationActions.js +17 -17
- package/dist/module/apis/notificationActions.js.map +1 -1
- package/dist/module/apis/profileActions.js +4 -4
- package/dist/module/apis/profileActions.js.map +1 -1
- package/dist/module/apis/reactionActions.js +15 -15
- package/dist/module/apis/reactionActions.js.map +1 -1
- package/dist/module/apis/settingActions.js +6 -6
- package/dist/module/apis/settingActions.js.map +1 -1
- package/dist/module/apis/stringActions.js +8 -8
- package/dist/module/apis/stringActions.js.map +1 -1
- package/dist/module/apis/typeActions.js +4 -4
- package/dist/module/apis/typeActions.js.map +1 -1
- package/dist/module/apis/userActions.js +8 -8
- package/dist/module/apis/userActions.js.map +1 -1
- package/dist/module/assets/icons/fontawesome/fa-brands-400.ttf +0 -0
- package/dist/module/assets/icons/fontawesome/fa-light-300.ttf +0 -0
- package/dist/module/assets/icons/fontawesome/fa-regular-400.ttf +0 -0
- package/dist/module/assets/icons/fontawesome/fa-solid-900.ttf +0 -0
- package/dist/module/assets/icons/fontawesome/fa-thin-100.ttf +0 -0
- package/dist/module/assets/icons/fontawesome/fa7-glyphmap.json +4205 -0
- package/dist/module/colours.js +26 -29
- package/dist/module/colours.js.map +1 -1
- package/dist/module/components/AddButton.js +8 -8
- package/dist/module/components/AddButton.js.map +1 -1
- package/dist/module/components/AddToCalendarButton.js +30 -29
- package/dist/module/components/AddToCalendarButton.js.map +1 -1
- package/dist/module/components/Attachment.js +10 -9
- package/dist/module/components/Attachment.js.map +1 -1
- package/dist/module/components/AudienceSelectorLauncher.js +11 -11
- package/dist/module/components/AudienceSelectorLauncher.js.map +1 -1
- package/dist/module/components/AudienceSelectorPage.js +45 -44
- package/dist/module/components/AudienceSelectorPage.js.map +1 -1
- package/dist/module/components/AutoOffsetImage.js +13 -13
- package/dist/module/components/AutoOffsetImage.js.map +1 -1
- package/dist/module/components/BackButton.js +10 -10
- package/dist/module/components/BackButton.js.map +1 -1
- package/dist/module/components/CalendarPopup.js +21 -21
- package/dist/module/components/CalendarPopup.js.map +1 -1
- package/dist/module/components/CategoryTabs.js +30 -29
- package/dist/module/components/CategoryTabs.js.map +1 -1
- package/dist/module/components/CommentReply.js +36 -34
- package/dist/module/components/CommentReply.js.map +1 -1
- package/dist/module/components/CommentSection.js +74 -74
- package/dist/module/components/CommentSection.js.map +1 -1
- package/dist/module/components/ConfirmPopup.js +21 -20
- package/dist/module/components/ConfirmPopup.js.map +1 -1
- package/dist/module/components/ConfirmationPopup.js +11 -11
- package/dist/module/components/ConfirmationPopup.js.map +1 -1
- package/dist/module/components/DocumentUploader.js +253 -0
- package/dist/module/components/DocumentUploader.js.map +1 -0
- package/dist/module/components/DropDownItem.js +14 -13
- package/dist/module/components/DropDownItem.js.map +1 -1
- package/dist/module/components/DropDownMenu.js +5 -5
- package/dist/module/components/DropDownMenu.js.map +1 -1
- package/dist/module/components/EmptyStateMain.js +10 -9
- package/dist/module/components/EmptyStateMain.js.map +1 -1
- package/dist/module/components/EmptyStateWidget.js +7 -6
- package/dist/module/components/EmptyStateWidget.js.map +1 -1
- package/dist/module/components/FontScaleButton.js +5 -4
- package/dist/module/components/FontScaleButton.js.map +1 -1
- package/dist/module/components/FontScalePopup.js +11 -10
- package/dist/module/components/FontScalePopup.js.map +1 -1
- package/dist/module/components/Forbidden.js +13 -13
- package/dist/module/components/Forbidden.js.map +1 -1
- package/dist/module/components/FormCard.js +4 -4
- package/dist/module/components/FormCard.js.map +1 -1
- package/dist/module/components/FormCardSection.js +20 -18
- package/dist/module/components/FormCardSection.js.map +1 -1
- package/dist/module/components/FormCardSectionOptionLauncher.js +13 -12
- package/dist/module/components/FormCardSectionOptionLauncher.js.map +1 -1
- package/dist/module/components/FormattedText.js +18 -16
- package/dist/module/components/FormattedText.js.map +1 -1
- package/dist/module/components/GenericInput.js +24 -21
- package/dist/module/components/GenericInput.js.map +1 -1
- package/dist/module/components/GenericInputSection.js +27 -26
- package/dist/module/components/GenericInputSection.js.map +1 -1
- package/dist/module/components/Header.js +70 -69
- package/dist/module/components/Header.js.map +1 -1
- package/dist/module/components/Icon.js +109 -0
- package/dist/module/components/Icon.js.map +1 -0
- package/dist/module/components/ImagePopup.js +237 -77
- package/dist/module/components/ImagePopup.js.map +1 -1
- package/dist/module/components/ImageUploadProgress.js +10 -9
- package/dist/module/components/ImageUploadProgress.js.map +1 -1
- package/dist/module/components/ImageUploader.js +22 -13
- package/dist/module/components/ImageUploader.js.map +1 -1
- package/dist/module/components/InlineButton.js +9 -8
- package/dist/module/components/InlineButton.js.map +1 -1
- package/dist/module/components/Input.js +28 -26
- package/dist/module/components/Input.js.map +1 -1
- package/dist/module/components/LoadingCircles.js +20 -20
- package/dist/module/components/LoadingCircles.js.map +1 -1
- package/dist/module/components/LoadingIndicator.js +11 -11
- package/dist/module/components/LoadingIndicator.js.map +1 -1
- package/dist/module/components/LoadingStateWidget.js +5 -5
- package/dist/module/components/LoadingStateWidget.js.map +1 -1
- package/dist/module/components/MediaPlayer.js +32 -32
- package/dist/module/components/MediaPlayer.js.map +1 -1
- package/dist/module/components/MiddlePopup.js +9 -9
- package/dist/module/components/MiddlePopup.js.map +1 -1
- package/dist/module/components/PDFPopup.js +36 -36
- package/dist/module/components/PDFPopup.js.map +1 -1
- package/dist/module/components/PlussChat.js +234 -146
- package/dist/module/components/PlussChat.js.map +1 -1
- package/dist/module/components/PlussChatMessage.js +75 -38
- package/dist/module/components/PlussChatMessage.js.map +1 -1
- package/dist/module/components/PlussChatTime.js +18 -17
- package/dist/module/components/PlussChatTime.js.map +1 -1
- package/dist/module/components/Popup.js +20 -19
- package/dist/module/components/Popup.js.map +1 -1
- package/dist/module/components/PopupMenu.js +15 -14
- package/dist/module/components/PopupMenu.js.map +1 -1
- package/dist/module/components/PositionedImage.js +20 -20
- package/dist/module/components/PositionedImage.js.map +1 -1
- package/dist/module/components/ProfilePic.js +10 -10
- package/dist/module/components/ProfilePic.js.map +1 -1
- package/dist/module/components/RadioButton.js +10 -9
- package/dist/module/components/RadioButton.js.map +1 -1
- package/dist/module/components/Reaction.js +18 -17
- package/dist/module/components/Reaction.js.map +1 -1
- package/dist/module/components/Reactions.js +7 -7
- package/dist/module/components/Reactions.js.map +1 -1
- package/dist/module/components/SharingTools.js +29 -28
- package/dist/module/components/SharingTools.js.map +1 -1
- package/dist/module/components/Spinner.js +5 -5
- package/dist/module/components/Spinner.js.map +1 -1
- package/dist/module/components/StickyFooter.js +6 -6
- package/dist/module/components/StickyFooter.js.map +1 -1
- package/dist/module/components/Text.js +57 -0
- package/dist/module/components/Text.js.map +1 -0
- package/dist/module/components/TickIcon.js +6 -6
- package/dist/module/components/TickIcon.js.map +1 -1
- package/dist/module/components/Toggle.js +10 -9
- package/dist/module/components/Toggle.js.map +1 -1
- package/dist/module/components/TouchableSearchBar.js +18 -17
- package/dist/module/components/TouchableSearchBar.js.map +1 -1
- package/dist/module/components/UserListPopup.js +20 -19
- package/dist/module/components/UserListPopup.js.map +1 -1
- package/dist/module/components/UserListing.js +41 -40
- package/dist/module/components/UserListing.js.map +1 -1
- package/dist/module/components/VideoPopup.js +20 -20
- package/dist/module/components/VideoPopup.js.map +1 -1
- package/dist/module/components/WarningPopup.js +21 -20
- package/dist/module/components/WarningPopup.js.map +1 -1
- package/dist/module/components/expo-image-picker-multiple/ImageBrowser.js +13 -13
- package/dist/module/components/expo-image-picker-multiple/ImageBrowser.js.map +1 -1
- package/dist/module/components/expo-image-picker-multiple/ImageTile.js +24 -23
- package/dist/module/components/expo-image-picker-multiple/ImageTile.js.map +1 -1
- package/dist/module/components/index.js +59 -57
- package/dist/module/components/index.js.map +1 -1
- package/dist/module/components/react-native-expo-image-cropper/ExpoImageManipulator.js +90 -58
- package/dist/module/components/react-native-expo-image-cropper/ExpoImageManipulator.js.map +1 -1
- package/dist/module/components/react-native-expo-image-cropper/ImageCropOverlay.js +64 -64
- package/dist/module/components/react-native-expo-image-cropper/ImageCropOverlay.js.map +1 -1
- package/dist/module/config.js +6 -1
- package/dist/module/config.js.map +1 -1
- package/dist/module/constants.js +3 -3
- package/dist/module/constants.js.map +1 -1
- package/dist/module/helper.js +83 -82
- package/dist/module/helper.js.map +1 -1
- package/dist/module/index.js +12 -12
- package/dist/module/index.js.map +1 -1
- package/dist/module/js/images/detectFaces.js +6 -6
- package/dist/module/js/images/detectFaces.js.map +1 -1
- package/dist/module/js/images/findLandmarkRange.js +8 -8
- package/dist/module/js/images/findLandmarkRange.js.map +1 -1
- package/dist/module/js/images/getScaledOffset.js.map +1 -1
- package/dist/module/js/site/getSiteLevelFromState.js +2 -2
- package/dist/module/js/site/getSiteLevelFromState.js.map +1 -1
- package/dist/module/js/site/isTVEnabled.js +2 -2
- package/dist/module/js/site/isTVEnabled.js.map +1 -1
- package/dist/module/session.js +2 -2
- package/dist/module/session.js.map +1 -1
- package/dist/module/styles.js +17 -17
- package/dist/module/styles.js.map +1 -1
- package/dist/module/withNavigationFocus.js +30 -0
- package/dist/module/withNavigationFocus.js.map +1 -0
- package/package.json +4 -1
- package/src/actions/FollowerActions.js +36 -32
- package/src/actions/MediaActions.js +25 -20
- package/src/actions/ResidentActions.js +26 -21
- package/src/actions/UserActions.js +22 -22
- package/src/actions/UserSettingsActions.js +11 -11
- package/src/actions/index.js +5 -5
- package/src/actions/types.js +16 -16
- package/src/apis/analyticsActions.js +17 -17
- package/src/apis/contactActions.js +20 -20
- package/src/apis/eventActions.js +153 -144
- package/src/apis/fileActions.js +19 -27
- package/src/apis/followerActions.js +29 -29
- package/src/apis/index.js +12 -12
- package/src/apis/notificationActions.js +44 -44
- package/src/apis/profileActions.js +8 -8
- package/src/apis/reactionActions.js +81 -73
- package/src/apis/settingActions.js +15 -15
- package/src/apis/stringActions.js +29 -25
- package/src/apis/typeActions.js +10 -10
- package/src/apis/userActions.js +93 -93
- package/src/assets/icons/fontawesome/fa-brands-400.ttf +0 -0
- package/src/assets/icons/fontawesome/fa-light-300.ttf +0 -0
- package/src/assets/icons/fontawesome/fa-regular-400.ttf +0 -0
- package/src/assets/icons/fontawesome/fa-solid-900.ttf +0 -0
- package/src/assets/icons/fontawesome/fa-thin-100.ttf +0 -0
- package/src/assets/icons/fontawesome/fa7-glyphmap.json +4205 -0
- package/src/colours.js +116 -96
- package/src/components/AddButton.js +32 -27
- package/src/components/AddToCalendarButton.js +236 -202
- package/src/components/Attachment.js +59 -36
- package/src/components/AudienceSelectorLauncher.js +52 -48
- package/src/components/AudienceSelectorPage.js +353 -311
- package/src/components/AutoOffsetImage.js +237 -196
- package/src/components/BackButton.js +57 -41
- package/src/components/CalendarPopup.js +127 -97
- package/src/components/CategoryTabs.js +208 -163
- package/src/components/CommentReply.js +363 -309
- package/src/components/CommentSection.js +974 -782
- package/src/components/ConfirmPopup.js +141 -110
- package/src/components/ConfirmationPopup.js +80 -69
- package/src/components/DocumentUploader.js +255 -0
- package/src/components/DropDownItem.js +70 -60
- package/src/components/DropDownMenu.js +31 -27
- package/src/components/EmptyStateMain.js +51 -44
- package/src/components/EmptyStateWidget.js +47 -38
- package/src/components/FontScaleButton.js +29 -25
- package/src/components/FontScalePopup.js +67 -56
- package/src/components/Forbidden.js +48 -46
- package/src/components/FormCard.js +21 -17
- package/src/components/FormCardSection.js +284 -233
- package/src/components/FormCardSectionOptionLauncher.js +72 -46
- package/src/components/FormattedText.js +128 -111
- package/src/components/GenericInput.js +168 -136
- package/src/components/GenericInputSection.js +209 -161
- package/src/components/Header.js +620 -474
- package/src/components/Icon.js +119 -0
- package/src/components/ImagePopup.js +425 -206
- package/src/components/ImageUploadProgress.js +49 -41
- package/src/components/ImageUploader.js +23 -13
- package/src/components/InlineButton.js +79 -69
- package/src/components/Input.js +190 -156
- package/src/components/LoadingCircles.js +233 -233
- package/src/components/LoadingIndicator.js +87 -76
- package/src/components/LoadingStateWidget.js +47 -37
- package/src/components/MediaPlayer.js +416 -387
- package/src/components/MiddlePopup.js +50 -32
- package/src/components/PDFPopup.js +198 -159
- package/src/components/PlussChat.js +1271 -986
- package/src/components/PlussChatMessage.js +330 -262
- package/src/components/PlussChatTime.js +57 -53
- package/src/components/Popup.js +138 -116
- package/src/components/PopupMenu.js +140 -110
- package/src/components/PositionedImage.js +281 -237
- package/src/components/ProfilePic.js +122 -113
- package/src/components/RadioButton.js +76 -52
- package/src/components/Reaction.js +134 -96
- package/src/components/Reactions.js +65 -63
- package/src/components/SharingTools.js +136 -122
- package/src/components/Spinner.js +13 -13
- package/src/components/StickyFooter.js +36 -26
- package/src/components/Text.js +62 -0
- package/src/components/TickIcon.js +20 -20
- package/src/components/Toggle.js +74 -73
- package/src/components/TouchableSearchBar.js +68 -50
- package/src/components/UserListPopup.js +161 -124
- package/src/components/UserListing.js +273 -238
- package/src/components/VideoPopup.js +110 -96
- package/src/components/WarningPopup.js +92 -71
- package/src/components/expo-image-picker-multiple/ImageBrowser.js +288 -256
- package/src/components/expo-image-picker-multiple/ImageTile.js +108 -84
- package/src/components/index.js +59 -57
- package/src/components/react-native-expo-image-cropper/ExpoImageManipulator.js +442 -358
- package/src/components/react-native-expo-image-cropper/ImageCropOverlay.js +420 -324
- package/src/config.js +5 -0
- package/src/constants.js +8 -8
- package/src/helper.js +469 -438
- package/src/index.js +24 -12
- package/src/js/images/detectFaces.js +27 -20
- package/src/js/images/findLandmarkRange.js +97 -90
- package/src/js/images/getScaledOffset.js +80 -75
- package/src/js/site/getSiteLevelFromState.js +26 -26
- package/src/js/site/isTVEnabled.js +10 -10
- package/src/session.js +2 -2
- package/src/styles.js +61 -61
- package/src/withNavigationFocus.js +28 -0
- package/dist/module/components/TextStyle.js +0 -45
- package/dist/module/components/TextStyle.js.map +0 -1
- package/dist/module/fonts/index.js +0 -2
- package/dist/module/fonts/index.js.map +0 -1
- package/dist/module/fonts/pluss60-icons.js +0 -5
- package/dist/module/fonts/pluss60-icons.js.map +0 -1
- package/dist/module/fonts/pluss60-icons.json +0 -1097
- package/src/components/TextStyle.js +0 -48
- package/src/fonts/index.js +0 -1
- package/src/fonts/pluss60-icons.js +0 -6
- package/src/fonts/pluss60-icons.json +0 -1097
package/src/components/Header.js
CHANGED
|
@@ -1,8 +1,17 @@
|
|
|
1
|
-
import React, { Component } from
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import React, { Component } from "react";
|
|
2
|
+
import { Text } from "@plusscommunities/pluss-core-app/components";
|
|
3
|
+
import {
|
|
4
|
+
Animated,
|
|
5
|
+
View,
|
|
6
|
+
StatusBar,
|
|
7
|
+
Image,
|
|
8
|
+
Dimensions,
|
|
9
|
+
TouchableOpacity,
|
|
10
|
+
Platform,
|
|
11
|
+
} from "react-native";
|
|
12
|
+
import { Icon } from "@rneui/themed";
|
|
13
|
+
import { LinearGradient } from "expo-linear-gradient";
|
|
14
|
+
import { connect } from "react-redux";
|
|
6
15
|
// import {
|
|
7
16
|
// StatusBarHeight,
|
|
8
17
|
// COLOUR_TRANSPARENT,
|
|
@@ -14,493 +23,630 @@ import { connect } from 'react-redux';
|
|
|
14
23
|
// hexToRGBAstring,
|
|
15
24
|
// getSiteSettingFromState,
|
|
16
25
|
// } from '../../js';
|
|
17
|
-
import { StatusBarHeight, getSiteSettingFromState } from
|
|
26
|
+
import { StatusBarHeight, getSiteSettingFromState } from "../helper";
|
|
18
27
|
import {
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
} from
|
|
27
|
-
import {
|
|
28
|
-
import Config from
|
|
28
|
+
COLOUR_TRANSPARENT,
|
|
29
|
+
TEXT_DARK,
|
|
30
|
+
TEXT_LIGHT,
|
|
31
|
+
LINEGREY,
|
|
32
|
+
COLOUR_GREEN,
|
|
33
|
+
getMainBrandingColourFromState,
|
|
34
|
+
hexToRGBAstring,
|
|
35
|
+
} from "../colours";
|
|
36
|
+
import { FontAwesome } from "./Icon";
|
|
37
|
+
import Config from "../config";
|
|
29
38
|
// import { HAS_GRADIENT_HEADER } from '../../config';
|
|
30
39
|
|
|
31
40
|
class Header extends Component {
|
|
32
|
-
|
|
33
|
-
|
|
41
|
+
constructor(props) {
|
|
42
|
+
super(props);
|
|
34
43
|
|
|
35
|
-
|
|
36
|
-
|
|
44
|
+
this.state = {};
|
|
45
|
+
}
|
|
37
46
|
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
+
UNSAFE_componentWillMount() {
|
|
48
|
+
let barStyle = Platform.select({ ios: "dark-content", android: "default" });
|
|
49
|
+
if (this.props.barStyle) {
|
|
50
|
+
barStyle = this.props.barStyle;
|
|
51
|
+
} else if (
|
|
52
|
+
this.props.headerType !== "white" &&
|
|
53
|
+
!this.props.noGradient &&
|
|
54
|
+
!this.props.transparent
|
|
55
|
+
) {
|
|
56
|
+
barStyle = "light-content";
|
|
57
|
+
}
|
|
58
|
+
this.setState({ windowWidth: Dimensions.get("window").width, barStyle });
|
|
59
|
+
}
|
|
47
60
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
61
|
+
getTextColourStyle() {
|
|
62
|
+
if (this.props.textColour) {
|
|
63
|
+
return { color: this.props.textColour };
|
|
64
|
+
}
|
|
65
|
+
if (
|
|
66
|
+
this.props.headerType !== "white" &&
|
|
67
|
+
!this.props.noGradient &&
|
|
68
|
+
!this.props.transparent
|
|
69
|
+
) {
|
|
70
|
+
return { color: "#fff" };
|
|
71
|
+
}
|
|
72
|
+
return null;
|
|
73
|
+
}
|
|
57
74
|
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
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
|
-
|
|
75
|
+
renderBackground() {
|
|
76
|
+
if (this.props.headerBackground) return this.props.headerBackground;
|
|
77
|
+
if (this.props.headerImage) {
|
|
78
|
+
return (
|
|
79
|
+
<Image
|
|
80
|
+
style={[styles.thumbnailStyle, { width: this.state.windowWidth }]}
|
|
81
|
+
source={{ uri: this.props.headerImage }}
|
|
82
|
+
/>
|
|
83
|
+
);
|
|
84
|
+
}
|
|
85
|
+
if (
|
|
86
|
+
this.props.headerType === "pattern" &&
|
|
87
|
+
!this.props.noGradient &&
|
|
88
|
+
!this.props.transparent
|
|
89
|
+
) {
|
|
90
|
+
return (
|
|
91
|
+
<View
|
|
92
|
+
style={[
|
|
93
|
+
styles.thumbnailStyle,
|
|
94
|
+
this.props.contentContainerStyle,
|
|
95
|
+
{
|
|
96
|
+
backgroundColor: this.props.colourBrandingMain,
|
|
97
|
+
width: this.state.windowWidth,
|
|
98
|
+
},
|
|
99
|
+
this.props.popupHeader && styles.thumbnailPopupHeader,
|
|
100
|
+
]}
|
|
101
|
+
>
|
|
102
|
+
<Image
|
|
103
|
+
style={[
|
|
104
|
+
styles.headerPattern,
|
|
105
|
+
this.props.patternColour && {
|
|
106
|
+
tintColor: this.props.patternColour,
|
|
107
|
+
},
|
|
108
|
+
]}
|
|
109
|
+
source={{ uri: this.props.headerPattern }}
|
|
110
|
+
/>
|
|
111
|
+
</View>
|
|
112
|
+
);
|
|
113
|
+
}
|
|
114
|
+
if (
|
|
115
|
+
this.props.headerType === "block" &&
|
|
116
|
+
!this.props.noGradient &&
|
|
117
|
+
!this.props.transparent
|
|
118
|
+
) {
|
|
119
|
+
return (
|
|
120
|
+
<View
|
|
121
|
+
style={[
|
|
122
|
+
styles.thumbnailStyle,
|
|
123
|
+
this.props.contentContainerStyle,
|
|
124
|
+
{
|
|
125
|
+
backgroundColor: this.props.colourBrandingMain,
|
|
126
|
+
width: this.state.windowWidth,
|
|
127
|
+
},
|
|
128
|
+
this.props.popupHeader && styles.thumbnailPopupHeader,
|
|
129
|
+
]}
|
|
130
|
+
/>
|
|
131
|
+
);
|
|
132
|
+
}
|
|
133
|
+
if (
|
|
134
|
+
this.props.headerType === "gradient" &&
|
|
135
|
+
!this.props.noGradient &&
|
|
136
|
+
!this.props.transparent
|
|
137
|
+
) {
|
|
138
|
+
return (
|
|
139
|
+
<View
|
|
140
|
+
style={[
|
|
141
|
+
styles.thumbnailStyle,
|
|
142
|
+
this.props.contentContainerStyle,
|
|
143
|
+
{ width: this.state.windowWidth },
|
|
144
|
+
this.props.popupHeader && styles.thumbnailPopupHeader,
|
|
145
|
+
]}
|
|
146
|
+
>
|
|
147
|
+
<LinearGradient
|
|
148
|
+
style={{ flex: 1 }}
|
|
149
|
+
colors={[
|
|
150
|
+
this.props.colourBrandingMain,
|
|
151
|
+
hexToRGBAstring(this.props.colourBrandingMain, 0.7),
|
|
152
|
+
]}
|
|
153
|
+
start={{ x: 0, y: 0 }}
|
|
154
|
+
end={{ x: 1, y: 1 }}
|
|
155
|
+
locations={[0.4, 1]}
|
|
156
|
+
/>
|
|
157
|
+
</View>
|
|
158
|
+
);
|
|
159
|
+
}
|
|
160
|
+
return null;
|
|
161
|
+
}
|
|
114
162
|
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
163
|
+
renderLeftBubble() {
|
|
164
|
+
if (!this.props.hasLeftBubble) {
|
|
165
|
+
return null;
|
|
166
|
+
}
|
|
167
|
+
return <View style={[styles.counter, styles.smallCounter]} />;
|
|
168
|
+
}
|
|
121
169
|
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
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
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
+
renderLeftIcon() {
|
|
171
|
+
if (
|
|
172
|
+
(!this.props.leftIcon && !this.props.leftText) ||
|
|
173
|
+
!this.props.onPressLeft
|
|
174
|
+
) {
|
|
175
|
+
return null;
|
|
176
|
+
}
|
|
177
|
+
if (this.props.leftText) {
|
|
178
|
+
return (
|
|
179
|
+
<View style={[styles.headerContentIcon, { width: "auto" }]}>
|
|
180
|
+
<TouchableOpacity
|
|
181
|
+
onPress={this.props.onPressLeft}
|
|
182
|
+
activeOpacity={0.6}
|
|
183
|
+
>
|
|
184
|
+
<Text
|
|
185
|
+
style={[
|
|
186
|
+
styles.buttonText,
|
|
187
|
+
{
|
|
188
|
+
paddingRight: 5,
|
|
189
|
+
paddingLeft: 15,
|
|
190
|
+
color: this.props.colourBrandingMain,
|
|
191
|
+
},
|
|
192
|
+
this.props.leftTextStyle,
|
|
193
|
+
this.props.headerType !== "white" &&
|
|
194
|
+
!this.props.noGradient &&
|
|
195
|
+
!this.props.transparent && { color: "#fff" },
|
|
196
|
+
]}
|
|
197
|
+
>
|
|
198
|
+
{this.props.leftText}
|
|
199
|
+
</Text>
|
|
200
|
+
</TouchableOpacity>
|
|
201
|
+
</View>
|
|
202
|
+
);
|
|
203
|
+
}
|
|
204
|
+
if (this.props.leftIconType && this.props.leftIconType === "pluss") {
|
|
205
|
+
return (
|
|
206
|
+
<View style={styles.headerContentIcon}>
|
|
207
|
+
<TouchableOpacity
|
|
208
|
+
onPress={this.props.onPressLeft}
|
|
209
|
+
activeOpacity={0.6}
|
|
210
|
+
>
|
|
211
|
+
<View style={styles.headerContentIcon}>
|
|
212
|
+
<FontAwesome
|
|
213
|
+
name={this.props.leftIcon}
|
|
214
|
+
style={[
|
|
215
|
+
styles.leftIcon,
|
|
216
|
+
this.props.leftIconStyle,
|
|
217
|
+
this.getTextColourStyle(),
|
|
218
|
+
]}
|
|
219
|
+
/>
|
|
220
|
+
{this.renderLeftBubble()}
|
|
221
|
+
</View>
|
|
222
|
+
</TouchableOpacity>
|
|
223
|
+
</View>
|
|
224
|
+
);
|
|
225
|
+
}
|
|
226
|
+
return (
|
|
227
|
+
<View style={styles.headerContentIcon}>
|
|
228
|
+
<TouchableOpacity onPress={this.props.onPressLeft} activeOpacity={0.6}>
|
|
229
|
+
<Icon
|
|
230
|
+
name={this.props.leftIcon}
|
|
231
|
+
style={styles.headerContentIcon}
|
|
232
|
+
type="font-awesome"
|
|
233
|
+
iconStyle={[
|
|
234
|
+
styles.leftIcon,
|
|
235
|
+
this.props.leftIconStyle,
|
|
236
|
+
this.getTextColourStyle(),
|
|
237
|
+
]}
|
|
238
|
+
/>
|
|
239
|
+
{this.renderLeftBubble()}
|
|
240
|
+
</TouchableOpacity>
|
|
241
|
+
</View>
|
|
242
|
+
);
|
|
243
|
+
}
|
|
170
244
|
|
|
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
|
-
|
|
245
|
+
renderHeaderText() {
|
|
246
|
+
if (!this.props.text) {
|
|
247
|
+
if (this.props.centerContent) {
|
|
248
|
+
return this.props.centerContent;
|
|
249
|
+
}
|
|
250
|
+
return null;
|
|
251
|
+
}
|
|
252
|
+
if (this.props.onTextPress) {
|
|
253
|
+
return (
|
|
254
|
+
<TouchableOpacity
|
|
255
|
+
onPress={this.props.onTextPress}
|
|
256
|
+
activeOpacity={0.6}
|
|
257
|
+
style={[
|
|
258
|
+
styles.headerTextContainer,
|
|
259
|
+
this.props.leftIcon &&
|
|
260
|
+
((!this.props.rightIcon && !this.props.rightText) ||
|
|
261
|
+
this.props.absoluteRight) && { paddingRight: 55 },
|
|
262
|
+
this.props.textContainerStyle,
|
|
263
|
+
]}
|
|
264
|
+
>
|
|
265
|
+
<Text
|
|
266
|
+
style={[
|
|
267
|
+
styles.headerText,
|
|
268
|
+
this.props.textStyle,
|
|
269
|
+
this.getTextColourStyle(),
|
|
270
|
+
]}
|
|
271
|
+
numberOfLines={1}
|
|
272
|
+
ellipsizeMode="tail"
|
|
273
|
+
>
|
|
274
|
+
{this.props.text}
|
|
275
|
+
</Text>
|
|
276
|
+
</TouchableOpacity>
|
|
277
|
+
);
|
|
278
|
+
}
|
|
279
|
+
return (
|
|
280
|
+
<View
|
|
281
|
+
style={[
|
|
282
|
+
styles.headerTextContainer,
|
|
283
|
+
this.props.leftIcon &&
|
|
284
|
+
((!this.props.rightIcon && !this.props.rightText) ||
|
|
285
|
+
this.props.absoluteRight) && { paddingRight: 55 },
|
|
286
|
+
this.props.rightIcon &&
|
|
287
|
+
((!this.props.leftIcon && !this.props.leftText) ||
|
|
288
|
+
this.props.absoluteLeft) && { paddingLeft: 55 },
|
|
289
|
+
this.props.textContainerStyle,
|
|
290
|
+
]}
|
|
291
|
+
>
|
|
292
|
+
<Text
|
|
293
|
+
style={[
|
|
294
|
+
styles.headerText,
|
|
295
|
+
this.props.textStyle,
|
|
296
|
+
this.getTextColourStyle(),
|
|
297
|
+
]}
|
|
298
|
+
numberOfLines={1}
|
|
299
|
+
ellipsizeMode="tail"
|
|
300
|
+
>
|
|
301
|
+
{this.props.text}
|
|
302
|
+
</Text>
|
|
303
|
+
</View>
|
|
304
|
+
);
|
|
305
|
+
}
|
|
210
306
|
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
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
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
307
|
+
renderRightIcon() {
|
|
308
|
+
if (this.props.rightContent) {
|
|
309
|
+
return this.props.rightContent;
|
|
310
|
+
}
|
|
311
|
+
if (!this.props.onPressRight) {
|
|
312
|
+
return null;
|
|
313
|
+
}
|
|
314
|
+
if (this.props.rightText && this.props.onPressRight) {
|
|
315
|
+
return (
|
|
316
|
+
<View
|
|
317
|
+
style={[
|
|
318
|
+
styles.headerContentIcon,
|
|
319
|
+
{ width: "auto" },
|
|
320
|
+
this.props.absoluteRight && styles.absoluteRight,
|
|
321
|
+
this.props.rightContainerStyle,
|
|
322
|
+
]}
|
|
323
|
+
>
|
|
324
|
+
<TouchableOpacity
|
|
325
|
+
onPress={this.props.onPressRight}
|
|
326
|
+
activeOpacity={0.6}
|
|
327
|
+
>
|
|
328
|
+
<Text
|
|
329
|
+
style={[
|
|
330
|
+
styles.buttonText,
|
|
331
|
+
{
|
|
332
|
+
paddingRight: 15,
|
|
333
|
+
paddingLeft: 5,
|
|
334
|
+
textAlign: "right",
|
|
335
|
+
fontFamily: "sf-semibold",
|
|
336
|
+
color: this.props.colourBrandingMain,
|
|
337
|
+
},
|
|
338
|
+
this.getTextColourStyle(),
|
|
339
|
+
this.props.optionalRightStyle,
|
|
340
|
+
]}
|
|
341
|
+
>
|
|
342
|
+
{this.props.rightText}
|
|
343
|
+
</Text>
|
|
344
|
+
</TouchableOpacity>
|
|
345
|
+
</View>
|
|
346
|
+
);
|
|
347
|
+
}
|
|
348
|
+
if (!this.props.rightIcon) {
|
|
349
|
+
if (this.props.rightImage) {
|
|
350
|
+
return (
|
|
351
|
+
<TouchableOpacity
|
|
352
|
+
onPress={this.props.onPressRight}
|
|
353
|
+
activeOpacity={0.6}
|
|
354
|
+
>
|
|
355
|
+
<View style={styles.headerContentIcon}>
|
|
356
|
+
<Image
|
|
357
|
+
source={{ uri: this.props.rightImage }}
|
|
358
|
+
style={styles.rightImage}
|
|
359
|
+
resizeMode="contain"
|
|
360
|
+
/>
|
|
361
|
+
</View>
|
|
362
|
+
</TouchableOpacity>
|
|
363
|
+
);
|
|
364
|
+
}
|
|
365
|
+
return null;
|
|
366
|
+
}
|
|
367
|
+
return (
|
|
368
|
+
<TouchableOpacity onPress={this.props.onPressRight} activeOpacity={0.6}>
|
|
369
|
+
{this.props.rightIconType && this.props.rightIconType === "pluss" ? (
|
|
370
|
+
<View style={styles.headerContentIcon}>
|
|
371
|
+
<FontAwesome
|
|
372
|
+
name={this.props.rightIcon}
|
|
373
|
+
style={[
|
|
374
|
+
styles.rightIcon,
|
|
375
|
+
this.getTextColourStyle(),
|
|
376
|
+
this.props.rightIconStyle,
|
|
377
|
+
]}
|
|
378
|
+
/>
|
|
379
|
+
</View>
|
|
380
|
+
) : (
|
|
381
|
+
<Icon
|
|
382
|
+
name={this.props.rightIcon}
|
|
383
|
+
style={styles.headerContentIcon}
|
|
384
|
+
type={
|
|
385
|
+
this.props.rightIconType
|
|
386
|
+
? this.props.rightIconType
|
|
387
|
+
: "font-awesome"
|
|
388
|
+
}
|
|
389
|
+
iconStyle={[
|
|
390
|
+
styles.rightIcon,
|
|
391
|
+
this.getTextColourStyle(),
|
|
392
|
+
this.props.rightIconStyle,
|
|
393
|
+
]}
|
|
394
|
+
/>
|
|
395
|
+
)}
|
|
396
|
+
</TouchableOpacity>
|
|
397
|
+
);
|
|
398
|
+
}
|
|
272
399
|
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
400
|
+
render() {
|
|
401
|
+
if (this.props.animatedHeader) {
|
|
402
|
+
return (
|
|
403
|
+
<Animated.View
|
|
404
|
+
style={[
|
|
405
|
+
styles.container,
|
|
406
|
+
!this.props.noShadow && styles.containerShadow,
|
|
407
|
+
this.props.transparent && styles.transparentContainer,
|
|
408
|
+
this.props.style,
|
|
409
|
+
{
|
|
410
|
+
backgroundColor: this.props.headerColourOffset,
|
|
411
|
+
elevation: this.props.headerElev,
|
|
412
|
+
shadowColor: this.props.headerShadow,
|
|
413
|
+
},
|
|
414
|
+
]}
|
|
415
|
+
>
|
|
416
|
+
{this.renderBackground()}
|
|
417
|
+
<StatusBar barStyle={this.state.barStyle} translucent />
|
|
418
|
+
<View style={styles.headerContent}>
|
|
419
|
+
{this.renderLeftIcon()}
|
|
420
|
+
{this.renderHeaderText()}
|
|
421
|
+
{this.renderRightIcon()}
|
|
422
|
+
{this.props.children}
|
|
423
|
+
</View>
|
|
424
|
+
{this.props.extraHeaderContent}
|
|
425
|
+
</Animated.View>
|
|
426
|
+
);
|
|
427
|
+
}
|
|
428
|
+
return (
|
|
429
|
+
<View
|
|
430
|
+
style={[
|
|
431
|
+
styles.container,
|
|
432
|
+
!this.props.noShadow && styles.containerShadow,
|
|
433
|
+
this.props.transparent && styles.transparentContainer,
|
|
434
|
+
this.props.lineSeparated && styles.lineSeparated,
|
|
435
|
+
this.props.popupHeader && styles.popupHeader,
|
|
436
|
+
this.props.style,
|
|
437
|
+
this.props.colourBrandingHeader && {
|
|
438
|
+
backgroundColor: this.props.colourBrandingHeader,
|
|
439
|
+
},
|
|
440
|
+
]}
|
|
441
|
+
>
|
|
442
|
+
<View
|
|
443
|
+
style={[
|
|
444
|
+
styles.contentContainer,
|
|
445
|
+
this.props.popupHeader && styles.popupContentContainer,
|
|
446
|
+
this.props.contentContainerStyle,
|
|
447
|
+
this.props.colourBrandingHeader && {
|
|
448
|
+
backgroundColor: this.props.colourBrandingHeader,
|
|
449
|
+
},
|
|
450
|
+
]}
|
|
451
|
+
>
|
|
452
|
+
{this.renderBackground()}
|
|
453
|
+
<StatusBar barStyle={this.state.barStyle} translucent />
|
|
454
|
+
<View
|
|
455
|
+
style={[
|
|
456
|
+
styles.headerContent,
|
|
457
|
+
this.props.popupHeader && styles.headerContentPopup,
|
|
458
|
+
]}
|
|
459
|
+
>
|
|
460
|
+
{this.renderLeftIcon()}
|
|
461
|
+
{this.renderHeaderText()}
|
|
462
|
+
{this.renderRightIcon()}
|
|
463
|
+
{this.props.children}
|
|
464
|
+
</View>
|
|
465
|
+
</View>
|
|
466
|
+
{this.props.extraHeaderContent}
|
|
467
|
+
</View>
|
|
468
|
+
);
|
|
469
|
+
}
|
|
330
470
|
}
|
|
331
471
|
|
|
332
472
|
const styles = {
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
473
|
+
container: {
|
|
474
|
+
alignSelf: "stretch",
|
|
475
|
+
backgroundColor: "#fff",
|
|
476
|
+
zIndex: 10,
|
|
477
|
+
},
|
|
478
|
+
containerShadow: {
|
|
479
|
+
shadowColor: "#000",
|
|
480
|
+
shadowOffset: {
|
|
481
|
+
width: 0,
|
|
482
|
+
height: 1,
|
|
483
|
+
},
|
|
484
|
+
shadowOpacity: 0.1,
|
|
485
|
+
shadowRadius: 6,
|
|
486
|
+
elevation: 3,
|
|
487
|
+
},
|
|
488
|
+
lineSeparated: {
|
|
489
|
+
borderBottomWidth: 1,
|
|
490
|
+
borderColor: LINEGREY,
|
|
491
|
+
shadowOpacity: 0,
|
|
492
|
+
elevation: 0,
|
|
493
|
+
},
|
|
494
|
+
popupHeader: {
|
|
495
|
+
borderBottomWidth: 1,
|
|
496
|
+
borderColor: LINEGREY,
|
|
497
|
+
shadowOpacity: 0,
|
|
498
|
+
elevation: 0,
|
|
499
|
+
borderTopLeftRadius: 12,
|
|
500
|
+
borderTopRightRadius: 12,
|
|
501
|
+
},
|
|
502
|
+
contentContainer: {
|
|
503
|
+
height: StatusBarHeight(70),
|
|
504
|
+
alignSelf: "stretch",
|
|
505
|
+
flexDirection: "row",
|
|
506
|
+
},
|
|
507
|
+
popupContentContainer: {
|
|
508
|
+
height: 70,
|
|
509
|
+
borderTopLeftRadius: 12,
|
|
510
|
+
borderTopRightRadius: 12,
|
|
511
|
+
},
|
|
512
|
+
transparentContainer: {
|
|
513
|
+
backgroundColor: COLOUR_TRANSPARENT,
|
|
514
|
+
shadowColor: COLOUR_TRANSPARENT,
|
|
515
|
+
elevation: 0,
|
|
516
|
+
},
|
|
517
|
+
thumbnailStyle: {
|
|
518
|
+
height: StatusBarHeight(70),
|
|
519
|
+
width: null,
|
|
520
|
+
position: "absolute",
|
|
521
|
+
top: 0,
|
|
522
|
+
left: 0,
|
|
523
|
+
resizeMode: "cover",
|
|
524
|
+
},
|
|
525
|
+
thumbnailPopupHeader: {
|
|
526
|
+
height: 70,
|
|
527
|
+
width: "100%",
|
|
528
|
+
borderTopLeftRadius: 12,
|
|
529
|
+
borderTopRightRadius: 12,
|
|
530
|
+
overflow: "hidden",
|
|
531
|
+
},
|
|
532
|
+
headerContent: {
|
|
533
|
+
alignSelf: "stretch",
|
|
534
|
+
flexDirection: "row",
|
|
535
|
+
flex: 1,
|
|
536
|
+
paddingTop: StatusBarHeight(0),
|
|
537
|
+
},
|
|
538
|
+
headerContentPopup: {
|
|
539
|
+
paddingTop: 0,
|
|
540
|
+
},
|
|
541
|
+
headerContentIcon: {
|
|
542
|
+
height: 70,
|
|
543
|
+
width: 55,
|
|
544
|
+
alignItems: "center",
|
|
545
|
+
flexDirection: "row",
|
|
546
|
+
justifyContent: "space-between",
|
|
547
|
+
},
|
|
548
|
+
absoluteRight: {
|
|
549
|
+
height: 70,
|
|
550
|
+
justifyContent: "center",
|
|
551
|
+
position: "absolute",
|
|
552
|
+
right: 0,
|
|
553
|
+
top: StatusBarHeight(0),
|
|
554
|
+
},
|
|
555
|
+
leftIcon: {
|
|
556
|
+
fontSize: 25,
|
|
557
|
+
padding: 15,
|
|
558
|
+
width: 55,
|
|
559
|
+
textAlign: "center",
|
|
560
|
+
color: TEXT_LIGHT,
|
|
561
|
+
},
|
|
562
|
+
headerTextContainer: {
|
|
563
|
+
height: 70,
|
|
564
|
+
flex: 1,
|
|
565
|
+
alignItems: "center",
|
|
566
|
+
flexDirection: "row",
|
|
567
|
+
justifyContent: "space-between",
|
|
568
|
+
},
|
|
569
|
+
headerText: {
|
|
570
|
+
fontSize: 16,
|
|
571
|
+
flex: 1,
|
|
572
|
+
fontFamily: "sf-semibold",
|
|
573
|
+
color: TEXT_DARK,
|
|
574
|
+
textAlign: "center",
|
|
575
|
+
backgroundColor: "rgba(255,255,255,0)",
|
|
576
|
+
},
|
|
577
|
+
buttonText: {
|
|
578
|
+
fontSize: 15,
|
|
579
|
+
fontFamily: "sf-regular",
|
|
580
|
+
width: 80,
|
|
581
|
+
backgroundColor: "rgba(255,255,255,0)",
|
|
582
|
+
},
|
|
583
|
+
rightIcon: {
|
|
584
|
+
fontSize: 25,
|
|
585
|
+
padding: 15,
|
|
586
|
+
width: 55,
|
|
587
|
+
textAlign: "center",
|
|
588
|
+
color: TEXT_LIGHT,
|
|
589
|
+
},
|
|
590
|
+
rightImage: {
|
|
591
|
+
width: 24,
|
|
592
|
+
height: 24,
|
|
593
|
+
marginRight: 15,
|
|
594
|
+
marginLeft: 13,
|
|
595
|
+
},
|
|
596
|
+
counter: {
|
|
597
|
+
top: 15,
|
|
598
|
+
right: 5,
|
|
599
|
+
borderRadius: 10,
|
|
600
|
+
position: "absolute",
|
|
601
|
+
height: 20,
|
|
602
|
+
minWidth: 20,
|
|
603
|
+
backgroundColor: COLOUR_GREEN,
|
|
604
|
+
justifyContent: "center",
|
|
605
|
+
},
|
|
606
|
+
counterText: {
|
|
607
|
+
color: "#fff",
|
|
608
|
+
textAlign: "center",
|
|
609
|
+
fontFamily: "sf-bold",
|
|
610
|
+
fontSize: 10,
|
|
611
|
+
lineHeight: 12,
|
|
612
|
+
backgroundColor: "transparent",
|
|
613
|
+
},
|
|
614
|
+
smallCounter: {
|
|
615
|
+
width: 5,
|
|
616
|
+
height: 5,
|
|
617
|
+
minWidth: 5,
|
|
618
|
+
top: 20,
|
|
619
|
+
right: 10,
|
|
620
|
+
},
|
|
621
|
+
headerPattern: {
|
|
622
|
+
position: "absolute",
|
|
623
|
+
top: 0,
|
|
624
|
+
left: 0,
|
|
625
|
+
right: 0,
|
|
626
|
+
bottom: 0,
|
|
627
|
+
width: "100%",
|
|
628
|
+
height: "100%",
|
|
629
|
+
resizeMode: "cover",
|
|
630
|
+
},
|
|
491
631
|
};
|
|
492
632
|
|
|
493
|
-
const mapStateToProps = state => {
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
633
|
+
const mapStateToProps = (state) => {
|
|
634
|
+
return {
|
|
635
|
+
colourBrandingMain: getMainBrandingColourFromState(state),
|
|
636
|
+
headerType: getSiteSettingFromState(
|
|
637
|
+
state,
|
|
638
|
+
"HeaderType",
|
|
639
|
+
getSiteSettingFromState(
|
|
640
|
+
state,
|
|
641
|
+
"UseGradientHeader",
|
|
642
|
+
Config.env.hasGradientHeader,
|
|
643
|
+
)
|
|
644
|
+
? "gradient"
|
|
645
|
+
: "white",
|
|
646
|
+
),
|
|
647
|
+
headerPattern: getSiteSettingFromState(state, "HeaderPattern"),
|
|
648
|
+
patternColour: getSiteSettingFromState(state, "PatternColour"),
|
|
649
|
+
};
|
|
504
650
|
};
|
|
505
651
|
|
|
506
652
|
export default connect(mapStateToProps, {})(Header);
|