@plusscommunities/pluss-core-app 8.0.0 → 8.0.1-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 +15 -15
- 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 +43 -37
- 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 +50 -50
- package/dist/module/components/DocumentUploader.js.map +1 -1
- 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 +211 -73
- 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 +116 -96
- 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 +31 -31
- package/dist/module/components/MediaPlayer.js.map +1 -1
- package/dist/module/components/MiddlePopup.js +17 -11
- package/dist/module/components/MiddlePopup.js.map +1 -1
- package/dist/module/components/PDFPopup.js +52 -39
- package/dist/module/components/PDFPopup.js.map +1 -1
- package/dist/module/components/PlussChat.js +168 -149
- package/dist/module/components/PlussChat.js.map +1 -1
- package/dist/module/components/PlussChatMessage.js +42 -42
- 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 +78 -43
- 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 -58
- package/dist/module/components/index.js.map +1 -1
- package/dist/module/components/react-native-expo-image-cropper/ExpoImageManipulator.js +94 -64
- 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 +15 -10
- package/dist/module/config.js.map +1 -1
- package/dist/module/constants.js +3 -4
- 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 +11 -10
- 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 +6 -6
- 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 +71 -68
- 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 +96 -86
- 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 +370 -309
- package/src/components/CommentSection.js +974 -781
- package/src/components/ConfirmPopup.js +141 -110
- package/src/components/ConfirmationPopup.js +80 -69
- package/src/components/DocumentUploader.js +245 -215
- 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 -221
- package/src/components/ImageUploadProgress.js +49 -41
- package/src/components/ImageUploader.js +968 -797
- 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 +62 -33
- package/src/components/PDFPopup.js +212 -159
- package/src/components/PlussChat.js +1224 -1025
- package/src/components/PlussChatMessage.js +329 -298
- 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 +185 -134
- 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 -58
- package/src/components/react-native-expo-image-cropper/ExpoImageManipulator.js +444 -359
- package/src/components/react-native-expo-image-cropper/ImageCropOverlay.js +420 -324
- package/src/config.js +26 -21
- package/src/constants.js +8 -10
- package/src/helper.js +469 -438
- package/src/index.js +24 -12
- package/src/js/images/detectFaces.js +28 -21
- 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 +32 -32
- 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 -7
- package/src/fonts/pluss60-icons.json +0 -1097
package/dist/module/colours.js
CHANGED
|
@@ -1,50 +1,50 @@
|
|
|
1
1
|
// const COLOUR_1 = '#011d5c';
|
|
2
2
|
// const COLOUR_2 = '#3179cb';
|
|
3
3
|
// const COLOUR_3 = '#1bb7ee';
|
|
4
|
-
const TEXT_DARKEST =
|
|
4
|
+
const TEXT_DARKEST = "#3e4245";
|
|
5
5
|
const TEXT_DARK = TEXT_DARKEST;
|
|
6
|
-
const TEXT_BLUEGREY =
|
|
6
|
+
const TEXT_BLUEGREY = "#6c7a90";
|
|
7
7
|
// const TEXT_DARK_ALPHA50 = 'rgba(60, 60, 80, .5)';
|
|
8
8
|
// const TEXT_DARK_ALPHA20 = 'rgba(60, 60, 80, .2)';
|
|
9
|
-
|
|
10
|
-
const TEXT_MID =
|
|
11
|
-
|
|
12
|
-
const TEXT_LIGHT =
|
|
13
|
-
const TEXT_LIGHTER =
|
|
14
|
-
const TEXT_SUPER_LIGHT =
|
|
15
|
-
const BG_GREY =
|
|
16
|
-
const LINEGREY =
|
|
17
|
-
const BOXGREY =
|
|
18
|
-
const PINKISH_GREY =
|
|
9
|
+
const TEXT_DARK_ALPHA10 = "rgba(60, 60, 80, .1)";
|
|
10
|
+
const TEXT_MID = "#5a5a6e";
|
|
11
|
+
const TEXT_MID_ALPHA50 = "rgba(90, 90, 110, .5)";
|
|
12
|
+
const TEXT_LIGHT = "#717b81";
|
|
13
|
+
const TEXT_LIGHTER = "rgba(113, 123, 129, 0.8)";
|
|
14
|
+
const TEXT_SUPER_LIGHT = "#d1d1d1";
|
|
15
|
+
const BG_GREY = "#e9e9ef";
|
|
16
|
+
const LINEGREY = "#d5dde4";
|
|
17
|
+
const BOXGREY = "#ebeff2";
|
|
18
|
+
const PINKISH_GREY = "#c4c4c4";
|
|
19
19
|
// const PALE_GREY = '#f6f7f9';
|
|
20
|
-
const INACTIVE_BUTTON =
|
|
21
|
-
const INACTIVE_TEXT =
|
|
22
|
-
const COLOUR_TEAL =
|
|
20
|
+
const INACTIVE_BUTTON = "#d5d9e1";
|
|
21
|
+
const INACTIVE_TEXT = "rgba(113, 123, 130, 0.8)";
|
|
22
|
+
const COLOUR_TEAL = "#82d6e5";
|
|
23
23
|
// const COLOUR_TEAL_ALPHA50 = 'rgba(4, 196, 169, 0.2)';
|
|
24
24
|
// const COLOUR_BLUE = '#0083ee';
|
|
25
25
|
// const COLOUR_BLUE_LIVE = 'rgb(0, 173, 238)';
|
|
26
26
|
// const COLOUR_BLUE_ALPHA10 = 'rgba(0, 131, 238, 0.1)';
|
|
27
27
|
// const COLOUR_DARKBLUE = '#191e78';
|
|
28
28
|
// const COLOUR_PURPLE = '#8e44ad';
|
|
29
|
-
const COLOUR_RED =
|
|
30
|
-
const COLOUR_GRAPEFRUIT =
|
|
31
|
-
const COLOUR_GREEN =
|
|
32
|
-
const COLOUR_GREEN_LIGHT =
|
|
33
|
-
const COLOUR_TANGERINE =
|
|
29
|
+
const COLOUR_RED = "#C52F40";
|
|
30
|
+
const COLOUR_GRAPEFRUIT = "#FF6363";
|
|
31
|
+
const COLOUR_GREEN = "#00cc76";
|
|
32
|
+
const COLOUR_GREEN_LIGHT = "#58dba4";
|
|
33
|
+
const COLOUR_TANGERINE = "#ff8c75";
|
|
34
34
|
// const COLOUR_CITRON = '#bdbd27';
|
|
35
35
|
// const DARK_OVERLAY = 'rgba(19,19,26,.6)';
|
|
36
36
|
// const FACEBOOK_BLUE = '#3B5998';
|
|
37
37
|
// const COLOUR_NAV_GREY = '#f6f6f6';
|
|
38
|
-
const COLOUR_TRANSPARENT =
|
|
38
|
+
const COLOUR_TRANSPARENT = "rgba(0,0,0,0)";
|
|
39
39
|
// const COLOUR_SIDEBAR = '#303030';
|
|
40
|
-
const COLOUR_BRANDING_MAIN =
|
|
40
|
+
const COLOUR_BRANDING_MAIN = "#FF6363";
|
|
41
41
|
// const COLOUR_BRANDING_OFF = '#FCE1E1';
|
|
42
|
-
const COLOUR_BRANDING_LIGHT =
|
|
42
|
+
const COLOUR_BRANDING_LIGHT = "#FCE1E1";
|
|
43
43
|
// const COLOUR_BRANDING_SECONDARY = COLOUR_BRANDING_MAIN;
|
|
44
|
-
const COLOUR_BRANDING_DARK =
|
|
44
|
+
const COLOUR_BRANDING_DARK = "#D13636";
|
|
45
45
|
// const COLOUR_DAY = '#89c4f4';
|
|
46
46
|
// const COLOUR_NIGHT = '#003159';
|
|
47
|
-
const COLOUR_TAN =
|
|
47
|
+
const COLOUR_TAN = "#fff3d1";
|
|
48
48
|
|
|
49
49
|
// const hexToRGB = hex => {
|
|
50
50
|
// // Expand shorthand form (e.g. "03F") to full form (e.g. "0033FF")
|
|
@@ -129,10 +129,7 @@ export {
|
|
|
129
129
|
TEXT_DARKEST, TEXT_BLUEGREY, TEXT_DARK,
|
|
130
130
|
// TEXT_DARK_ALPHA50,
|
|
131
131
|
// TEXT_DARK_ALPHA20,
|
|
132
|
-
|
|
133
|
-
TEXT_MID,
|
|
134
|
-
// TEXT_MID_ALPHA50,
|
|
135
|
-
TEXT_LIGHT, TEXT_LIGHTER, TEXT_SUPER_LIGHT, BG_GREY, LINEGREY, PINKISH_GREY, BOXGREY,
|
|
132
|
+
TEXT_DARK_ALPHA10, TEXT_MID, TEXT_MID_ALPHA50, TEXT_LIGHT, TEXT_LIGHTER, TEXT_SUPER_LIGHT, BG_GREY, LINEGREY, PINKISH_GREY, BOXGREY,
|
|
136
133
|
// PALE_GREY,
|
|
137
134
|
INACTIVE_BUTTON, INACTIVE_TEXT, COLOUR_TEAL,
|
|
138
135
|
// COLOUR_TEAL_ALPHA50,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["TEXT_DARKEST","TEXT_DARK","TEXT_BLUEGREY","TEXT_MID","TEXT_LIGHT","TEXT_LIGHTER","TEXT_SUPER_LIGHT","BG_GREY","LINEGREY","BOXGREY","PINKISH_GREY","INACTIVE_BUTTON","INACTIVE_TEXT","COLOUR_TEAL","COLOUR_RED","COLOUR_GRAPEFRUIT","COLOUR_GREEN","COLOUR_GREEN_LIGHT","COLOUR_TANGERINE","COLOUR_TRANSPARENT","COLOUR_BRANDING_MAIN","COLOUR_BRANDING_LIGHT","COLOUR_BRANDING_DARK","COLOUR_TAN","hexToRGBAstring","hex","opacity","shorthandRegex","replace","m","r","g","b","result","exec","parseInt","getMainBrandingColourFromState","state","user","siteBranding","MainBrandingColour","getDarkBrandingColourFromState","DarkBrandingColour","getLightBrandingColourFromState","LightBrandingColour"],"sources":["colours.js"],"sourcesContent":["// const COLOUR_1 = '#011d5c';\n// const COLOUR_2 = '#3179cb';\n// const COLOUR_3 = '#1bb7ee';\nconst TEXT_DARKEST =
|
|
1
|
+
{"version":3,"names":["TEXT_DARKEST","TEXT_DARK","TEXT_BLUEGREY","TEXT_DARK_ALPHA10","TEXT_MID","TEXT_MID_ALPHA50","TEXT_LIGHT","TEXT_LIGHTER","TEXT_SUPER_LIGHT","BG_GREY","LINEGREY","BOXGREY","PINKISH_GREY","INACTIVE_BUTTON","INACTIVE_TEXT","COLOUR_TEAL","COLOUR_RED","COLOUR_GRAPEFRUIT","COLOUR_GREEN","COLOUR_GREEN_LIGHT","COLOUR_TANGERINE","COLOUR_TRANSPARENT","COLOUR_BRANDING_MAIN","COLOUR_BRANDING_LIGHT","COLOUR_BRANDING_DARK","COLOUR_TAN","hexToRGBAstring","hex","opacity","shorthandRegex","replace","m","r","g","b","result","exec","parseInt","getMainBrandingColourFromState","state","user","siteBranding","MainBrandingColour","getDarkBrandingColourFromState","DarkBrandingColour","getLightBrandingColourFromState","LightBrandingColour"],"sources":["colours.js"],"sourcesContent":["// const COLOUR_1 = '#011d5c';\n// const COLOUR_2 = '#3179cb';\n// const COLOUR_3 = '#1bb7ee';\nconst TEXT_DARKEST = \"#3e4245\";\nconst TEXT_DARK = TEXT_DARKEST;\nconst TEXT_BLUEGREY = \"#6c7a90\";\n// const TEXT_DARK_ALPHA50 = 'rgba(60, 60, 80, .5)';\n// const TEXT_DARK_ALPHA20 = 'rgba(60, 60, 80, .2)';\nconst TEXT_DARK_ALPHA10 = \"rgba(60, 60, 80, .1)\";\nconst TEXT_MID = \"#5a5a6e\";\nconst TEXT_MID_ALPHA50 = \"rgba(90, 90, 110, .5)\";\nconst TEXT_LIGHT = \"#717b81\";\nconst TEXT_LIGHTER = \"rgba(113, 123, 129, 0.8)\";\nconst TEXT_SUPER_LIGHT = \"#d1d1d1\";\nconst BG_GREY = \"#e9e9ef\";\nconst LINEGREY = \"#d5dde4\";\nconst BOXGREY = \"#ebeff2\";\nconst PINKISH_GREY = \"#c4c4c4\";\n// const PALE_GREY = '#f6f7f9';\nconst INACTIVE_BUTTON = \"#d5d9e1\";\nconst INACTIVE_TEXT = \"rgba(113, 123, 130, 0.8)\";\nconst COLOUR_TEAL = \"#82d6e5\";\n// const COLOUR_TEAL_ALPHA50 = 'rgba(4, 196, 169, 0.2)';\n// const COLOUR_BLUE = '#0083ee';\n// const COLOUR_BLUE_LIVE = 'rgb(0, 173, 238)';\n// const COLOUR_BLUE_ALPHA10 = 'rgba(0, 131, 238, 0.1)';\n// const COLOUR_DARKBLUE = '#191e78';\n// const COLOUR_PURPLE = '#8e44ad';\nconst COLOUR_RED = \"#C52F40\";\nconst COLOUR_GRAPEFRUIT = \"#FF6363\";\nconst COLOUR_GREEN = \"#00cc76\";\nconst COLOUR_GREEN_LIGHT = \"#58dba4\";\nconst COLOUR_TANGERINE = \"#ff8c75\";\n// const COLOUR_CITRON = '#bdbd27';\n// const DARK_OVERLAY = 'rgba(19,19,26,.6)';\n// const FACEBOOK_BLUE = '#3B5998';\n// const COLOUR_NAV_GREY = '#f6f6f6';\nconst COLOUR_TRANSPARENT = \"rgba(0,0,0,0)\";\n// const COLOUR_SIDEBAR = '#303030';\nconst COLOUR_BRANDING_MAIN = \"#FF6363\";\n// const COLOUR_BRANDING_OFF = '#FCE1E1';\nconst COLOUR_BRANDING_LIGHT = \"#FCE1E1\";\n// const COLOUR_BRANDING_SECONDARY = COLOUR_BRANDING_MAIN;\nconst COLOUR_BRANDING_DARK = \"#D13636\";\n// const COLOUR_DAY = '#89c4f4';\n// const COLOUR_NIGHT = '#003159';\nconst COLOUR_TAN = \"#fff3d1\";\n\n// const hexToRGB = hex => {\n// // Expand shorthand form (e.g. \"03F\") to full form (e.g. \"0033FF\")\n// const shorthandRegex = /^#?([a-f\\d])([a-f\\d])([a-f\\d])$/i;\n// hex = hex.replace(shorthandRegex, (m, r, g, b) => {\n// return r + r + g + g + b + b;\n// });\n\n// const result = /^#?([a-f\\d]{2})([a-f\\d]{2})([a-f\\d]{2})$/i.exec(hex);\n// return result\n// ? {\n// r: parseInt(result[1], 16),\n// g: parseInt(result[2], 16),\n// b: parseInt(result[3], 16),\n// }\n// : null;\n// };\n\nconst hexToRGBAstring = (hex, opacity) => {\n\t// Expand shorthand form (e.g. \"03F\") to full form (e.g. \"0033FF\")\n\tconst shorthandRegex = /^#?([a-f\\d])([a-f\\d])([a-f\\d])$/i;\n\thex = hex.replace(shorthandRegex, (m, r, g, b) => {\n\t\treturn r + r + g + g + b + b;\n\t});\n\n\tconst result = /^#?([a-f\\d]{2})([a-f\\d]{2})([a-f\\d]{2})$/i.exec(hex);\n\treturn result\n\t\t? `rgba(${parseInt(result[1], 16)}, ${parseInt(result[2], 16)}, ${parseInt(result[3], 16)}, ${opacity})`\n\t\t: null;\n};\n\n// const pctBtwnColours = (c1, c2, percentage) => {\n// const rgbC1 = hexToRGB(c1);\n// const rgbC2 = hexToRGB(c2);\n// const r = rgbC2.r + (rgbC1.r - rgbC2.r) * percentage;\n// const g = rgbC2.g + (rgbC1.g - rgbC2.g) * percentage;\n// const b = rgbC2.b + (rgbC1.b - rgbC2.b) * percentage;\n// return `rgb(${r}, ${g}, ${b})`;\n// };\n\n// const getTabIconColour = (mainColour, footerType, selected) => {\n// if (footerType !== 'white') {\n// return '#fff';\n// }\n// if (selected) {\n// return mainColour;\n// }\n// return TEXT_BLUEGREY;\n// };\n\n// const getHeaderBrandingColourFromState = state => {\n// return (state && state.user && state.user.siteBranding && state.user.siteBranding.HeaderBrandingColour) || null;\n// };\n\nconst getMainBrandingColourFromState = (state) => {\n\treturn (\n\t\t(state &&\n\t\t\tstate.user &&\n\t\t\tstate.user.siteBranding &&\n\t\t\tstate.user.siteBranding.MainBrandingColour) ||\n\t\tCOLOUR_BRANDING_MAIN\n\t);\n};\n\nconst getDarkBrandingColourFromState = (state) => {\n\treturn (\n\t\t(state &&\n\t\t\tstate.user &&\n\t\t\tstate.user.siteBranding &&\n\t\t\tstate.user.siteBranding.DarkBrandingColour) ||\n\t\tCOLOUR_BRANDING_DARK\n\t);\n};\n\nconst getLightBrandingColourFromState = (state) => {\n\treturn (\n\t\t(state &&\n\t\t\tstate.user &&\n\t\t\tstate.user.siteBranding &&\n\t\t\tstate.user.siteBranding.LightBrandingColour) ||\n\t\tCOLOUR_BRANDING_LIGHT\n\t);\n};\n\n// const getSecondaryBrandingColourFromState = state => {\n// return (state && state.user && state.user.siteBranding && state.user.siteBranding.SecondaryBrandingColour) || COLOUR_BRANDING_SECONDARY;\n// };\n\n// const getMainBrandingColourFromSite = site => {\n// return (site.Branding && site.Branding.MainBrandingColour) || COLOUR_BRANDING_MAIN;\n// };\n\n// const getDarkBrandingColourFromSite = site => {\n// return (site.Branding && site.Branding.DarkBrandingColour) || COLOUR_BRANDING_DARK;\n// };\n\n// const getLightBrandingColourFromSite = site => {\n// return (site.Branding && site.Branding.LightBrandingColour) || COLOUR_BRANDING_LIGHT;\n// };\n\nexport {\n\t// COLOUR_1,\n\t// COLOUR_2,\n\t// COLOUR_3,\n\tTEXT_DARKEST,\n\tTEXT_BLUEGREY,\n\tTEXT_DARK,\n\t// TEXT_DARK_ALPHA50,\n\t// TEXT_DARK_ALPHA20,\n\tTEXT_DARK_ALPHA10,\n\tTEXT_MID,\n\tTEXT_MID_ALPHA50,\n\tTEXT_LIGHT,\n\tTEXT_LIGHTER,\n\tTEXT_SUPER_LIGHT,\n\tBG_GREY,\n\tLINEGREY,\n\tPINKISH_GREY,\n\tBOXGREY,\n\t// PALE_GREY,\n\tINACTIVE_BUTTON,\n\tINACTIVE_TEXT,\n\tCOLOUR_TEAL,\n\t// COLOUR_TEAL_ALPHA50,\n\t// COLOUR_BLUE,\n\t// COLOUR_BLUE_LIVE,\n\t// COLOUR_BLUE_ALPHA10,\n\t// COLOUR_DARKBLUE,\n\t// COLOUR_PURPLE,\n\tCOLOUR_RED,\n\tCOLOUR_TANGERINE,\n\t// COLOUR_CITRON,\n\t// DARK_OVERLAY,\n\t// hexToRGB,\n\thexToRGBAstring,\n\t// pctBtwnColours,\n\t// FACEBOOK_BLUE,\n\t// COLOUR_NAV_GREY,\n\tCOLOUR_TRANSPARENT,\n\t// COLOUR_SIDEBAR,\n\tCOLOUR_BRANDING_MAIN,\n\t// COLOUR_BRANDING_OFF,\n\tCOLOUR_BRANDING_LIGHT,\n\tCOLOUR_BRANDING_DARK,\n\tCOLOUR_GREEN,\n\tCOLOUR_GREEN_LIGHT,\n\tCOLOUR_GRAPEFRUIT,\n\t// COLOUR_DAY,\n\t// COLOUR_NIGHT,\n\tCOLOUR_TAN,\n\t// getHeaderBrandingColourFromState,\n\tgetMainBrandingColourFromState,\n\tgetDarkBrandingColourFromState,\n\tgetLightBrandingColourFromState,\n\t// getSecondaryBrandingColourFromState,\n\t// getMainBrandingColourFromSite,\n\t// getDarkBrandingColourFromSite,\n\t// getLightBrandingColourFromSite,\n\t// getTabIconColour,\n};\n"],"mappings":"AAAA;AACA;AACA;AACA,MAAMA,YAAY,GAAG,SAAS;AAC9B,MAAMC,SAAS,GAAGD,YAAY;AAC9B,MAAME,aAAa,GAAG,SAAS;AAC/B;AACA;AACA,MAAMC,iBAAiB,GAAG,sBAAsB;AAChD,MAAMC,QAAQ,GAAG,SAAS;AAC1B,MAAMC,gBAAgB,GAAG,uBAAuB;AAChD,MAAMC,UAAU,GAAG,SAAS;AAC5B,MAAMC,YAAY,GAAG,0BAA0B;AAC/C,MAAMC,gBAAgB,GAAG,SAAS;AAClC,MAAMC,OAAO,GAAG,SAAS;AACzB,MAAMC,QAAQ,GAAG,SAAS;AAC1B,MAAMC,OAAO,GAAG,SAAS;AACzB,MAAMC,YAAY,GAAG,SAAS;AAC9B;AACA,MAAMC,eAAe,GAAG,SAAS;AACjC,MAAMC,aAAa,GAAG,0BAA0B;AAChD,MAAMC,WAAW,GAAG,SAAS;AAC7B;AACA;AACA;AACA;AACA;AACA;AACA,MAAMC,UAAU,GAAG,SAAS;AAC5B,MAAMC,iBAAiB,GAAG,SAAS;AACnC,MAAMC,YAAY,GAAG,SAAS;AAC9B,MAAMC,kBAAkB,GAAG,SAAS;AACpC,MAAMC,gBAAgB,G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B,CAAC;AAED,MAAMqB,8BAA8B,GAAIJ,KAAK,IAAK;EACjD,OACEA,KAAK,IACLA,KAAK,CAACC,IAAI,IACVD,KAAK,CAACC,IAAI,CAACC,YAAY,IACvBF,KAAK,CAACC,IAAI,CAACC,YAAY,CAACG,kBAAkB,IAC3CpB,oBAAoB;AAEtB,CAAC;AAED,MAAMqB,+BAA+B,GAAIN,KAAK,IAAK;EAClD,OACEA,KAAK,IACLA,KAAK,CAACC,IAAI,IACVD,KAAK,CAACC,IAAI,CAACC,YAAY,IACvBF,KAAK,CAACC,IAAI,CAACC,YAAY,CAACK,mBAAmB,IAC5CvB,qBAAqB;AAEvB,CAAC;;AAED;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACC;AACA;AACA;AACAvB,YAAY,EACZE,aAAa,EACbD,SAAS;AACT;AACA;AACAE,iBAAiB,EACjBC,QAAQ,EACRC,gBAAgB,EAChBC,UAAU,EACVC,YAAY,EACZC,gBAAgB,EAChBC,OAAO,EACPC,QAAQ,EACRE,YAAY,EACZD,OAAO;AACP;AACAE,eAAe,EACfC,aAAa,EACbC,WAAW;AACX;AACA;AACA;AACA;AACA;AACA;AACAC,UAAU,EACVI,gBAAgB;AAChB;AACA;AACA;AACAM,eAAe;AACf;AACA;AACA;AACAL,kBAAkB;AAClB;AACAC,oBAAoB;AACpB;AACAC,qBAAqB,EACrBC,oBAAoB,EACpBN,YAAY,EACZC,kBAAkB,EAClBF,iBAAiB;AACjB;AACA;AACAQ,UAAU;AACV;AACAa,8BAA8B,EAC9BK,8BAA8B,EAC9BE;AACA;AACA;AACA;AACA;AACA;AAAA","ignoreList":[]}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import React, { PureComponent } from
|
|
2
|
-
import { TouchableOpacity } from
|
|
3
|
-
import { connect } from
|
|
4
|
-
import Styles from
|
|
5
|
-
import {
|
|
6
|
-
import { getMainBrandingColourFromState } from
|
|
1
|
+
import React, { PureComponent } from "react";
|
|
2
|
+
import { TouchableOpacity } from "react-native";
|
|
3
|
+
import { connect } from "react-redux";
|
|
4
|
+
import Styles from "../styles";
|
|
5
|
+
import { FontAwesome } from "./Icon";
|
|
6
|
+
import { getMainBrandingColourFromState } from "../colours";
|
|
7
7
|
|
|
8
8
|
/*
|
|
9
9
|
Props-
|
|
@@ -27,8 +27,8 @@ class AddButton extends PureComponent {
|
|
|
27
27
|
backgroundColor: this.props.color
|
|
28
28
|
}, this.props.style],
|
|
29
29
|
onPress: this.props.onPress
|
|
30
|
-
}, /*#__PURE__*/React.createElement(
|
|
31
|
-
name: "
|
|
30
|
+
}, /*#__PURE__*/React.createElement(FontAwesome, {
|
|
31
|
+
name: "plus",
|
|
32
32
|
style: Styles.addButtonIcon
|
|
33
33
|
}));
|
|
34
34
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","PureComponent","TouchableOpacity","connect","Styles","
|
|
1
|
+
{"version":3,"names":["React","PureComponent","TouchableOpacity","connect","Styles","FontAwesome","getMainBrandingColourFromState","AddButton","render","size","props","diameter","radius","createElement","style","addButton","height","width","borderRadius","backgroundColor","colourBrandingMain","color","onPress","name","addButtonIcon","mapStateToProps","state"],"sources":["AddButton.js"],"sourcesContent":["import React, { PureComponent } from \"react\";\nimport { TouchableOpacity } from \"react-native\";\nimport { connect } from \"react-redux\";\nimport Styles from \"../styles\";\nimport { FontAwesome } from \"./Icon\";\nimport { getMainBrandingColourFromState } from \"../colours\";\n\n/* \nProps- \n onPress - onPress action\n diameter - size of button\n iconSize - size of inner plus\n color - default will be aveoMain\n*/\n\nclass AddButton extends PureComponent {\n\trender() {\n\t\tconst size = this.props.diameter || 48;\n\t\tconst radius = size / 2;\n\t\treturn (\n\t\t\t<TouchableOpacity\n\t\t\t\tstyle={[\n\t\t\t\t\tStyles.addButton,\n\t\t\t\t\t{\n\t\t\t\t\t\theight: size,\n\t\t\t\t\t\twidth: size,\n\t\t\t\t\t\tborderRadius: radius,\n\t\t\t\t\t\tbackgroundColor: this.props.colourBrandingMain,\n\t\t\t\t\t},\n\t\t\t\t\tthis.props.color && { backgroundColor: this.props.color },\n\t\t\t\t\tthis.props.style,\n\t\t\t\t]}\n\t\t\t\tonPress={this.props.onPress}\n\t\t\t>\n\t\t\t\t<FontAwesome name=\"plus\" style={Styles.addButtonIcon} />\n\t\t\t</TouchableOpacity>\n\t\t);\n\t}\n}\n\nconst mapStateToProps = (state) => {\n\treturn {\n\t\tcolourBrandingMain: getMainBrandingColourFromState(state),\n\t};\n};\n\nconst addButton = connect(mapStateToProps, {})(AddButton);\nexport { addButton as AddButton };\n"],"mappings":"AAAA,OAAOA,KAAK,IAAIC,aAAa,QAAQ,OAAO;AAC5C,SAASC,gBAAgB,QAAQ,cAAc;AAC/C,SAASC,OAAO,QAAQ,aAAa;AACrC,OAAOC,MAAM,MAAM,WAAW;AAC9B,SAASC,WAAW,QAAQ,QAAQ;AACpC,SAASC,8BAA8B,QAAQ,YAAY;;AAE3D;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,MAAMC,SAAS,SAASN,aAAa,CAAC;EACrCO,MAAMA,CAAA,EAAG;IACR,MAAMC,IAAI,GAAG,IAAI,CAACC,KAAK,CAACC,QAAQ,IAAI,EAAE;IACtC,MAAMC,MAAM,GAAGH,IAAI,GAAG,CAAC;IACvB,oBACCT,KAAA,CAAAa,aAAA,CAACX,gBAAgB;MAChBY,KAAK,EAAE,CACNV,MAAM,CAACW,SAAS,EAChB;QACCC,MAAM,EAAEP,IAAI;QACZQ,KAAK,EAAER,IAAI;QACXS,YAAY,EAAEN,MAAM;QACpBO,eAAe,EAAE,IAAI,CAACT,KAAK,CAACU;MAC7B,CAAC,EACD,IAAI,CAACV,KAAK,CAACW,KAAK,IAAI;QAAEF,eAAe,EAAE,IAAI,CAACT,KAAK,CAACW;MAAM,CAAC,EACzD,IAAI,CAACX,KAAK,CAACI,KAAK,CACf;MACFQ,OAAO,EAAE,IAAI,CAACZ,KAAK,CAACY;IAAQ,gBAE5BtB,KAAA,CAAAa,aAAA,CAACR,WAAW;MAACkB,IAAI,EAAC,MAAM;MAACT,KAAK,EAAEV,MAAM,CAACoB;IAAc,CAAE,CACtC,CAAC;EAErB;AACD;AAEA,MAAMC,eAAe,GAAIC,KAAK,IAAK;EAClC,OAAO;IACNN,kBAAkB,EAAEd,8BAA8B,CAACoB,KAAK;EACzD,CAAC;AACF,CAAC;AAED,MAAMX,SAAS,GAAGZ,OAAO,CAACsB,eAAe,EAAE,CAAC,CAAC,CAAC,CAAClB,SAAS,CAAC;AACzD,SAASQ,SAAS,IAAIR,SAAS","ignoreList":[]}
|
|
@@ -2,17 +2,18 @@ function _extends() { return _extends = Object.assign ? Object.assign.bind() : f
|
|
|
2
2
|
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
3
3
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
|
4
4
|
function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
5
|
-
import React, { Component } from
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
|
|
15
|
-
const
|
|
5
|
+
import React, { Component } from "react";
|
|
6
|
+
import { Text } from "@plusscommunities/pluss-core-app/components";
|
|
7
|
+
import { Platform, Linking, StyleSheet, View, TouchableOpacity, ScrollView } from "react-native";
|
|
8
|
+
import { connect } from "react-redux";
|
|
9
|
+
import _ from "lodash";
|
|
10
|
+
import * as Calendar from "expo-calendar";
|
|
11
|
+
import { TEXT_DARK, getMainBrandingColourFromState } from "../colours";
|
|
12
|
+
import { InlineButton } from "./InlineButton";
|
|
13
|
+
import { Popup } from "./Popup";
|
|
14
|
+
import { MiddlePopup } from "./MiddlePopup";
|
|
15
|
+
const DEFAULT_TITLE = "Add to Calendar";
|
|
16
|
+
const ERROR_EVENT_ADD = "There was a problem adding a calendar event.";
|
|
16
17
|
|
|
17
18
|
// Required: eventToAdd
|
|
18
19
|
// Documentation: https://docs.expo.dev/versions/latest/sdk/calendar/#event
|
|
@@ -20,7 +21,7 @@ class AddToCalendarButton extends Component {
|
|
|
20
21
|
constructor(props) {
|
|
21
22
|
super(props);
|
|
22
23
|
_defineProperty(this, "showWarningPopup", () => {
|
|
23
|
-
if (Platform.OS !==
|
|
24
|
+
if (Platform.OS !== "ios") return;
|
|
24
25
|
this.setState({
|
|
25
26
|
showPermissionWarning: true
|
|
26
27
|
});
|
|
@@ -31,7 +32,7 @@ class AddToCalendarButton extends Component {
|
|
|
31
32
|
});
|
|
32
33
|
});
|
|
33
34
|
_defineProperty(this, "goToPermissionSettings", () => {
|
|
34
|
-
Linking.openURL(
|
|
35
|
+
Linking.openURL("app-settings:");
|
|
35
36
|
this.setState({
|
|
36
37
|
showPermissionWarning: false
|
|
37
38
|
});
|
|
@@ -39,14 +40,14 @@ class AddToCalendarButton extends Component {
|
|
|
39
40
|
_defineProperty(this, "onAdd", async () => {
|
|
40
41
|
if (!this.props.eventToAdd) {
|
|
41
42
|
this.setState({
|
|
42
|
-
message:
|
|
43
|
+
message: "There is no event to add"
|
|
43
44
|
});
|
|
44
45
|
return;
|
|
45
46
|
}
|
|
46
47
|
const {
|
|
47
48
|
status
|
|
48
49
|
} = await Calendar.requestCalendarPermissionsAsync();
|
|
49
|
-
if (status !==
|
|
50
|
+
if (status !== "granted") {
|
|
50
51
|
this.showWarningPopup();
|
|
51
52
|
} else {
|
|
52
53
|
let calendars = await Calendar.getCalendarsAsync(Calendar.EntityTypes.EVENT);
|
|
@@ -61,7 +62,7 @@ class AddToCalendarButton extends Component {
|
|
|
61
62
|
type: c.type
|
|
62
63
|
};
|
|
63
64
|
});
|
|
64
|
-
calendars = _.orderBy(calendars, [
|
|
65
|
+
calendars = _.orderBy(calendars, ["source", "title"]);
|
|
65
66
|
// console.log('sorted calendars', calendars);
|
|
66
67
|
}
|
|
67
68
|
this.setState({
|
|
@@ -86,7 +87,7 @@ class AddToCalendarButton extends Component {
|
|
|
86
87
|
message: eventId ? `${eventToAdd.title} was added to ${calendar.title} successfully.` : ERROR_EVENT_ADD
|
|
87
88
|
});
|
|
88
89
|
} catch (error) {
|
|
89
|
-
console.log(
|
|
90
|
+
console.log("onSelectCalendar", error);
|
|
90
91
|
this.setState({
|
|
91
92
|
calendars: null,
|
|
92
93
|
message: ERROR_EVENT_ADD
|
|
@@ -109,11 +110,11 @@ class AddToCalendarButton extends Component {
|
|
|
109
110
|
title: "Permissions missing",
|
|
110
111
|
text: "You must grant access to the Calendars. Tap Go to settings to change your permission settings.",
|
|
111
112
|
options: [{
|
|
112
|
-
text:
|
|
113
|
+
text: "Go to settings",
|
|
113
114
|
action: this.goToPermissionSettings,
|
|
114
115
|
bold: true
|
|
115
116
|
}, {
|
|
116
|
-
text:
|
|
117
|
+
text: "Ignore",
|
|
117
118
|
action: this.closeWarningPopup
|
|
118
119
|
}]
|
|
119
120
|
});
|
|
@@ -143,9 +144,9 @@ class AddToCalendarButton extends Component {
|
|
|
143
144
|
}]
|
|
144
145
|
}, /*#__PURE__*/React.createElement(Text, {
|
|
145
146
|
style: styles.calendarText
|
|
146
|
-
}, `${cal.source}${cal.source === cal.title ?
|
|
147
|
+
}, `${cal.source}${cal.source === cal.title ? "" : `\n${cal.title}`}`)));
|
|
147
148
|
})), /*#__PURE__*/React.createElement(TouchableOpacity, {
|
|
148
|
-
key:
|
|
149
|
+
key: "cancel",
|
|
149
150
|
onPress: this.onCloseCalendars
|
|
150
151
|
}, /*#__PURE__*/React.createElement(View, {
|
|
151
152
|
style: [styles.calendarContainer, {
|
|
@@ -161,7 +162,7 @@ class AddToCalendarButton extends Component {
|
|
|
161
162
|
title: "Add to Calendar",
|
|
162
163
|
text: message,
|
|
163
164
|
options: [{
|
|
164
|
-
text:
|
|
165
|
+
text: "Ok",
|
|
165
166
|
action: this.onCloseMessage
|
|
166
167
|
}]
|
|
167
168
|
});
|
|
@@ -188,18 +189,18 @@ const styles = StyleSheet.create({
|
|
|
188
189
|
borderRadius: 12
|
|
189
190
|
},
|
|
190
191
|
calendarPopupTitle: {
|
|
191
|
-
fontFamily:
|
|
192
|
+
fontFamily: "sf-bold",
|
|
192
193
|
color: TEXT_DARK,
|
|
193
194
|
fontSize: 18,
|
|
194
195
|
marginBottom: 16
|
|
195
196
|
},
|
|
196
197
|
calendarPopupContainer: {
|
|
197
198
|
flex: 1,
|
|
198
|
-
justifyContent:
|
|
199
|
+
justifyContent: "space-between"
|
|
199
200
|
},
|
|
200
201
|
calendarContainer: {
|
|
201
|
-
flexDirection:
|
|
202
|
-
alignItems:
|
|
202
|
+
flexDirection: "row",
|
|
203
|
+
alignItems: "center",
|
|
203
204
|
width: 200,
|
|
204
205
|
height: 40,
|
|
205
206
|
paddingHorizontal: 8,
|
|
@@ -207,9 +208,9 @@ const styles = StyleSheet.create({
|
|
|
207
208
|
marginBottom: 10
|
|
208
209
|
},
|
|
209
210
|
calendarText: {
|
|
210
|
-
color:
|
|
211
|
-
textAlign:
|
|
212
|
-
fontFamily:
|
|
211
|
+
color: "#fff",
|
|
212
|
+
textAlign: "center",
|
|
213
|
+
fontFamily: "sf-semibold",
|
|
213
214
|
fontSize: 13,
|
|
214
215
|
flex: 1
|
|
215
216
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","Component","Platform","Linking","StyleSheet","Text","View","TouchableOpacity","ScrollView","connect","_","Calendar","TEXT_DARK","getMainBrandingColourFromState","InlineButton","Popup","MiddlePopup","DEFAULT_TITLE","ERROR_EVENT_ADD","AddToCalendarButton","constructor","props","_defineProperty","OS","setState","showPermissionWarning","openURL","eventToAdd","message","status","requestCalendarPermissionsAsync","showWarningPopup","calendars","getCalendarsAsync","EntityTypes","EVENT","length","filter","c","allowsModifications","map","id","title","source","name","color","type","orderBy","calendar","eventId","createEventAsync","error","console","log","state","renderPermission","createElement","text","options","action","goToPermissionSettings","bold","closeWarningPopup","renderCalendars","style","styles","calendarsPopup","height","onClose","onCloseCalendars","calendarPopupTitle","calendarPopupContainer","flex","showsVerticalScrollIndicator","cal","key","onPress","onSelectCalendar","calendarContainer","backgroundColor","calendarText","marginTop","colourBrandingMain","renderMessage","onCloseMessage","render","_extends","onAdd","children","create","width","maxHeight","padding","borderRadius","fontFamily","fontSize","marginBottom","justifyContent","flexDirection","alignItems","paddingHorizontal","textAlign","mapStateToProps","button"],"sources":["AddToCalendarButton.js"],"sourcesContent":["import React, { Component } from 'react';\nimport { Platform, Linking, StyleSheet, Text, View, TouchableOpacity, ScrollView } from 'react-native';\nimport { connect } from 'react-redux';\nimport _ from 'lodash';\nimport * as Calendar from 'expo-calendar';\nimport { TEXT_DARK, getMainBrandingColourFromState } from '../colours';\nimport { InlineButton } from './InlineButton';\nimport { Popup } from './Popup';\nimport { MiddlePopup } from './MiddlePopup';\n\nconst DEFAULT_TITLE = 'Add to Calendar';\nconst ERROR_EVENT_ADD = 'There was a problem adding a calendar event.';\n\n// Required: eventToAdd\n// Documentation: https://docs.expo.dev/versions/latest/sdk/calendar/#event\nclass AddToCalendarButton extends Component {\n constructor(props) {\n super(props);\n\n this.state = {\n showPermissionWarning: false,\n calendars: null,\n message: null,\n };\n }\n\n showWarningPopup = () => {\n if (Platform.OS !== 'ios') return;\n this.setState({ showPermissionWarning: true });\n };\n\n closeWarningPopup = () => {\n this.setState({ showPermissionWarning: false });\n };\n\n goToPermissionSettings = () => {\n Linking.openURL('app-settings:');\n this.setState({ showPermissionWarning: false });\n };\n\n onAdd = async () => {\n if (!this.props.eventToAdd) {\n this.setState({ message: 'There is no event to add' });\n return;\n }\n\n const { status } = await Calendar.requestCalendarPermissionsAsync();\n if (status !== 'granted') {\n this.showWarningPopup();\n } else {\n let calendars = await Calendar.getCalendarsAsync(Calendar.EntityTypes.EVENT);\n // console.log('all calendars', calendars);\n if (calendars && calendars.length > 0) {\n calendars = calendars\n .filter(c => c.allowsModifications)\n .map(c => {\n return {\n id: c.id,\n title: c.title,\n source: c.source.name,\n color: c.color,\n type: c.type,\n };\n });\n calendars = _.orderBy(calendars, ['source', 'title']);\n // console.log('sorted calendars', calendars);\n }\n this.setState({ calendars });\n }\n };\n\n onCloseCalendars = () => {\n this.setState({ calendars: null });\n };\n\n onSelectCalendar = async calendar => {\n try {\n const { eventToAdd } = this.props;\n if (!eventToAdd) return;\n\n const eventId = await Calendar.createEventAsync(calendar.id, eventToAdd);\n\n this.setState({\n calendars: null,\n message: eventId ? `${eventToAdd.title} was added to ${calendar.title} successfully.` : ERROR_EVENT_ADD,\n });\n } catch (error) {\n console.log('onSelectCalendar', error);\n this.setState({ calendars: null, message: ERROR_EVENT_ADD });\n }\n };\n\n onCloseMessage = () => {\n this.setState({ message: null });\n };\n\n renderPermission() {\n return (\n <Popup\n title=\"Permissions missing\"\n text=\"You must grant access to the Calendars. Tap Go to settings to change your permission settings.\"\n options={[\n {\n text: 'Go to settings',\n action: this.goToPermissionSettings,\n bold: true,\n },\n {\n text: 'Ignore',\n action: this.closeWarningPopup,\n },\n ]}\n />\n );\n }\n\n renderCalendars(calendars) {\n return (\n <MiddlePopup style={[styles.calendarsPopup, { height: calendars.length * 60 + 120 }]} onClose={this.onCloseCalendars}>\n <Text style={styles.calendarPopupTitle}>Select Calendar</Text>\n <View style={styles.calendarPopupContainer}>\n <ScrollView style={{ flex: 1 }} showsVerticalScrollIndicator={false}>\n {calendars.map(cal => {\n return (\n <TouchableOpacity key={cal.id} onPress={() => this.onSelectCalendar(cal)}>\n <View style={[styles.calendarContainer, { backgroundColor: cal.color }]}>\n <Text style={styles.calendarText}>{`${cal.source}${cal.source === cal.title ? '' : `\\n${cal.title}`}`}</Text>\n </View>\n </TouchableOpacity>\n );\n })}\n </ScrollView>\n <TouchableOpacity key={'cancel'} onPress={this.onCloseCalendars}>\n <View style={[styles.calendarContainer, { marginTop: 20, backgroundColor: this.props.colourBrandingMain }]}>\n <Text style={styles.calendarText}>Cancel</Text>\n </View>\n </TouchableOpacity>\n </View>\n </MiddlePopup>\n );\n }\n\n renderMessage(message) {\n return (\n <Popup\n title=\"Add to Calendar\"\n text={message}\n options={[\n {\n text: 'Ok',\n action: this.onCloseMessage,\n },\n ]}\n />\n );\n }\n\n render() {\n const { showPermissionWarning, calendars, message } = this.state;\n\n if (showPermissionWarning) return this.renderPermission();\n if (calendars && calendars.length > 0) return this.renderCalendars(calendars);\n if (message) return this.renderMessage(message);\n\n return (\n <InlineButton {...this.props} onPress={this.onAdd}>\n {this.props.children || DEFAULT_TITLE}\n </InlineButton>\n );\n }\n}\n\nconst styles = StyleSheet.create({\n calendarsPopup: {\n width: 250,\n maxHeight: 400,\n padding: 16,\n borderRadius: 12,\n },\n calendarPopupTitle: {\n fontFamily: 'sf-bold',\n color: TEXT_DARK,\n fontSize: 18,\n marginBottom: 16,\n },\n calendarPopupContainer: {\n flex: 1,\n justifyContent: 'space-between',\n },\n calendarContainer: {\n flexDirection: 'row',\n alignItems: 'center',\n width: 200,\n height: 40,\n paddingHorizontal: 8,\n borderRadius: 4,\n marginBottom: 10,\n },\n calendarText: {\n color: '#fff',\n textAlign: 'center',\n fontFamily: 'sf-semibold',\n fontSize: 13,\n flex: 1,\n },\n});\n\nconst mapStateToProps = state => {\n return {\n colourBrandingMain: getMainBrandingColourFromState(state),\n };\n};\n\nconst button = connect(mapStateToProps, {})(AddToCalendarButton);\nexport { button as AddToCalendarButton };\n"],"mappings":";;;;AAAA,OAAOA,KAAK,IAAIC,SAAS,QAAQ,OAAO;AACxC,SAASC,QAAQ,EAAEC,OAAO,EAAEC,UAAU,EAAEC,IAAI,EAAEC,IAAI,EAAEC,gBAAgB,EAAE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AAK,EAAE,GAAG;IACVvB,MAAM,EAAE,EAAE;IACViC,iBAAiB,EAAE,CAAC;IACpBP,YAAY,EAAE,CAAC;IACfG,YAAY,EAAE;EAChB,CAAC;EACDhB,YAAY,EAAE;IACZnC,KAAK,EAAE,MAAM;IACbwD,SAAS,EAAE,QAAQ;IACnBP,UAAU,EAAE,aAAa;IACzBC,QAAQ,EAAE,EAAE;IACZvB,IAAI,EAAE;EACR;AACF,CAAC,CAAC;AAEF,MAAM8B,eAAe,GAAGhD,KAAK,IAAI;EAC/B,OAAO;IACL4B,kBAAkB,EAAErE,8BAA8B,CAACyC,KAAK;EAC1D,CAAC;AACH,CAAC;AAED,MAAMiD,MAAM,GAAG9F,OAAO,CAAC6F,eAAe,EAAE,CAAC,CAAC,CAAC,CAACnF,mBAAmB,CAAC;AAChE,SAASoF,MAAM,IAAIpF,mBAAmB","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["React","Component","Text","Platform","Linking","StyleSheet","View","TouchableOpacity","ScrollView","connect","_","Calendar","TEXT_DARK","getMainBrandingColourFromState","InlineButton","Popup","MiddlePopup","DEFAULT_TITLE","ERROR_EVENT_ADD","AddToCalendarButton","constructor","props","_defineProperty","OS","setState","showPermissionWarning","openURL","eventToAdd","message","status","requestCalendarPermissionsAsync","showWarningPopup","calendars","getCalendarsAsync","EntityTypes","EVENT","length","filter","c","allowsModifications","map","id","title","source","name","color","type","orderBy","calendar","eventId","createEventAsync","error","console","log","state","renderPermission","createElement","text","options","action","goToPermissionSettings","bold","closeWarningPopup","renderCalendars","style","styles","calendarsPopup","height","onClose","onCloseCalendars","calendarPopupTitle","calendarPopupContainer","flex","showsVerticalScrollIndicator","cal","key","onPress","onSelectCalendar","calendarContainer","backgroundColor","calendarText","marginTop","colourBrandingMain","renderMessage","onCloseMessage","render","_extends","onAdd","children","create","width","maxHeight","padding","borderRadius","fontFamily","fontSize","marginBottom","justifyContent","flexDirection","alignItems","paddingHorizontal","textAlign","mapStateToProps","button"],"sources":["AddToCalendarButton.js"],"sourcesContent":["import React, { Component } from \"react\";\nimport { Text } from \"@plusscommunities/pluss-core-app/components\";\nimport {\n\tPlatform,\n\tLinking,\n\tStyleSheet,\n\tView,\n\tTouchableOpacity,\n\tScrollView,\n} from \"react-native\";\nimport { connect } from \"react-redux\";\nimport _ from \"lodash\";\nimport * as Calendar from \"expo-calendar\";\nimport { TEXT_DARK, getMainBrandingColourFromState } from \"../colours\";\nimport { InlineButton } from \"./InlineButton\";\nimport { Popup } from \"./Popup\";\nimport { MiddlePopup } from \"./MiddlePopup\";\n\nconst DEFAULT_TITLE = \"Add to Calendar\";\nconst ERROR_EVENT_ADD = \"There was a problem adding a calendar event.\";\n\n// Required: eventToAdd\n// Documentation: https://docs.expo.dev/versions/latest/sdk/calendar/#event\nclass AddToCalendarButton extends Component {\n\tconstructor(props) {\n\t\tsuper(props);\n\n\t\tthis.state = {\n\t\t\tshowPermissionWarning: false,\n\t\t\tcalendars: null,\n\t\t\tmessage: null,\n\t\t};\n\t}\n\n\tshowWarningPopup = () => {\n\t\tif (Platform.OS !== \"ios\") return;\n\t\tthis.setState({ showPermissionWarning: true });\n\t};\n\n\tcloseWarningPopup = () => {\n\t\tthis.setState({ showPermissionWarning: false });\n\t};\n\n\tgoToPermissionSettings = () => {\n\t\tLinking.openURL(\"app-settings:\");\n\t\tthis.setState({ showPermissionWarning: false });\n\t};\n\n\tonAdd = async () => {\n\t\tif (!this.props.eventToAdd) {\n\t\t\tthis.setState({ message: \"There is no event to add\" });\n\t\t\treturn;\n\t\t}\n\n\t\tconst { status } = await Calendar.requestCalendarPermissionsAsync();\n\t\tif (status !== \"granted\") {\n\t\t\tthis.showWarningPopup();\n\t\t} else {\n\t\t\tlet calendars = await Calendar.getCalendarsAsync(\n\t\t\t\tCalendar.EntityTypes.EVENT,\n\t\t\t);\n\t\t\t// console.log('all calendars', calendars);\n\t\t\tif (calendars && calendars.length > 0) {\n\t\t\t\tcalendars = calendars\n\t\t\t\t\t.filter((c) => c.allowsModifications)\n\t\t\t\t\t.map((c) => {\n\t\t\t\t\t\treturn {\n\t\t\t\t\t\t\tid: c.id,\n\t\t\t\t\t\t\ttitle: c.title,\n\t\t\t\t\t\t\tsource: c.source.name,\n\t\t\t\t\t\t\tcolor: c.color,\n\t\t\t\t\t\t\ttype: c.type,\n\t\t\t\t\t\t};\n\t\t\t\t\t});\n\t\t\t\tcalendars = _.orderBy(calendars, [\"source\", \"title\"]);\n\t\t\t\t// console.log('sorted calendars', calendars);\n\t\t\t}\n\t\t\tthis.setState({ calendars });\n\t\t}\n\t};\n\n\tonCloseCalendars = () => {\n\t\tthis.setState({ calendars: null });\n\t};\n\n\tonSelectCalendar = async (calendar) => {\n\t\ttry {\n\t\t\tconst { eventToAdd } = this.props;\n\t\t\tif (!eventToAdd) return;\n\n\t\t\tconst eventId = await Calendar.createEventAsync(calendar.id, eventToAdd);\n\n\t\t\tthis.setState({\n\t\t\t\tcalendars: null,\n\t\t\t\tmessage: eventId\n\t\t\t\t\t? `${eventToAdd.title} was added to ${calendar.title} successfully.`\n\t\t\t\t\t: ERROR_EVENT_ADD,\n\t\t\t});\n\t\t} catch (error) {\n\t\t\tconsole.log(\"onSelectCalendar\", error);\n\t\t\tthis.setState({ calendars: null, message: ERROR_EVENT_ADD });\n\t\t}\n\t};\n\n\tonCloseMessage = () => {\n\t\tthis.setState({ message: null });\n\t};\n\n\trenderPermission() {\n\t\treturn (\n\t\t\t<Popup\n\t\t\t\ttitle=\"Permissions missing\"\n\t\t\t\ttext=\"You must grant access to the Calendars. Tap Go to settings to change your permission settings.\"\n\t\t\t\toptions={[\n\t\t\t\t\t{\n\t\t\t\t\t\ttext: \"Go to settings\",\n\t\t\t\t\t\taction: this.goToPermissionSettings,\n\t\t\t\t\t\tbold: true,\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\ttext: \"Ignore\",\n\t\t\t\t\t\taction: this.closeWarningPopup,\n\t\t\t\t\t},\n\t\t\t\t]}\n\t\t\t/>\n\t\t);\n\t}\n\n\trenderCalendars(calendars) {\n\t\treturn (\n\t\t\t<MiddlePopup\n\t\t\t\tstyle={[styles.calendarsPopup, { height: calendars.length * 60 + 120 }]}\n\t\t\t\tonClose={this.onCloseCalendars}\n\t\t\t>\n\t\t\t\t<Text style={styles.calendarPopupTitle}>Select Calendar</Text>\n\t\t\t\t<View style={styles.calendarPopupContainer}>\n\t\t\t\t\t<ScrollView style={{ flex: 1 }} showsVerticalScrollIndicator={false}>\n\t\t\t\t\t\t{calendars.map((cal) => {\n\t\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t\t<TouchableOpacity\n\t\t\t\t\t\t\t\t\tkey={cal.id}\n\t\t\t\t\t\t\t\t\tonPress={() => this.onSelectCalendar(cal)}\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t<View\n\t\t\t\t\t\t\t\t\t\tstyle={[\n\t\t\t\t\t\t\t\t\t\t\tstyles.calendarContainer,\n\t\t\t\t\t\t\t\t\t\t\t{ backgroundColor: cal.color },\n\t\t\t\t\t\t\t\t\t\t]}\n\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t<Text\n\t\t\t\t\t\t\t\t\t\t\tstyle={styles.calendarText}\n\t\t\t\t\t\t\t\t\t\t>{`${cal.source}${cal.source === cal.title ? \"\" : `\\n${cal.title}`}`}</Text>\n\t\t\t\t\t\t\t\t\t</View>\n\t\t\t\t\t\t\t\t</TouchableOpacity>\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t})}\n\t\t\t\t\t</ScrollView>\n\t\t\t\t\t<TouchableOpacity key={\"cancel\"} onPress={this.onCloseCalendars}>\n\t\t\t\t\t\t<View\n\t\t\t\t\t\t\tstyle={[\n\t\t\t\t\t\t\t\tstyles.calendarContainer,\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tmarginTop: 20,\n\t\t\t\t\t\t\t\t\tbackgroundColor: this.props.colourBrandingMain,\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t]}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<Text style={styles.calendarText}>Cancel</Text>\n\t\t\t\t\t\t</View>\n\t\t\t\t\t</TouchableOpacity>\n\t\t\t\t</View>\n\t\t\t</MiddlePopup>\n\t\t);\n\t}\n\n\trenderMessage(message) {\n\t\treturn (\n\t\t\t<Popup\n\t\t\t\ttitle=\"Add to Calendar\"\n\t\t\t\ttext={message}\n\t\t\t\toptions={[\n\t\t\t\t\t{\n\t\t\t\t\t\ttext: \"Ok\",\n\t\t\t\t\t\taction: this.onCloseMessage,\n\t\t\t\t\t},\n\t\t\t\t]}\n\t\t\t/>\n\t\t);\n\t}\n\n\trender() {\n\t\tconst { showPermissionWarning, calendars, message } = this.state;\n\n\t\tif (showPermissionWarning) return this.renderPermission();\n\t\tif (calendars && calendars.length > 0)\n\t\t\treturn this.renderCalendars(calendars);\n\t\tif (message) return this.renderMessage(message);\n\n\t\treturn (\n\t\t\t<InlineButton {...this.props} onPress={this.onAdd}>\n\t\t\t\t{this.props.children || DEFAULT_TITLE}\n\t\t\t</InlineButton>\n\t\t);\n\t}\n}\n\nconst styles = StyleSheet.create({\n\tcalendarsPopup: {\n\t\twidth: 250,\n\t\tmaxHeight: 400,\n\t\tpadding: 16,\n\t\tborderRadius: 12,\n\t},\n\tcalendarPopupTitle: {\n\t\tfontFamily: \"sf-bold\",\n\t\tcolor: TEXT_DARK,\n\t\tfontSize: 18,\n\t\tmarginBottom: 16,\n\t},\n\tcalendarPopupContainer: {\n\t\tflex: 1,\n\t\tjustifyContent: \"space-between\",\n\t},\n\tcalendarContainer: {\n\t\tflexDirection: \"row\",\n\t\talignItems: \"center\",\n\t\twidth: 200,\n\t\theight: 40,\n\t\tpaddingHorizontal: 8,\n\t\tborderRadius: 4,\n\t\tmarginBottom: 10,\n\t},\n\tcalendarText: {\n\t\tcolor: \"#fff\",\n\t\ttextAlign: \"center\",\n\t\tfontFamily: \"sf-semibold\",\n\t\tfontSize: 13,\n\t\tflex: 1,\n\t},\n});\n\nconst mapStateToProps = (state) => {\n\treturn {\n\t\tcolourBrandingMain: getMainBrandingColourFromState(state),\n\t};\n};\n\nconst button = connect(mapStateToProps, {})(AddToCalendarButton);\nexport { button as AddToCalendarButton };\n"],"mappings":";;;;AAAA,OAAOA,KAAK,IAAIC,SAAS,QAAQ,OAAO;AACxC,SAASC,IAAI,QAAQ,6CAA6C;AAClE,SACCC,QAAQ,EACRC,OAAO,EACPC,UAAU,EACVC,IAAI,EACJC,gBAAgB,EAChBC,UAAU,QACJ,cAAc;AACrB,SAASC,OAAO,QAAQ,aAAa;AACrC,OAAOC,CAAC,MAAM,QAAQ;AACtB,OAAO,KAAKC,QAAQ,MAAM,eAAe;AACzC,SAASC,SAAS,EAAEC,8BAA8B,QAAQ,YAAY;AACtE,SAASC,YAAY,QAAQ,gBAAgB;AAC7C,SAASC,KAAK,QAAQ,SAAS;AAC/B,SAASC,WAAW,QAAQ,eAAe;AAE3C,MAAMC,aAAa,GAAG,iBAAiB;AACvC,MAAMC,eAAe,GAAG,8CAA8C;;AAEtE;AACA;AACA,MAAMC,mBAAmB,SAASlB,SAAS,CAAC;EAC3CmB,WAAWA,CAACC,KAAK,EAAE;IAClB,KAAK,CAACA,KAAK,CAAC;IAACC,eAAA,2BASK,MAAM;MACxB,IAAInB,QAAQ,CAACoB,EAAE,KAAK,KAAK,EAAE;MAC3B,IAAI,CAACC,QAAQ,CAAC;QAAEC,qBAAqB,EAAE;MAAK,CAAC,CAAC;IAC/C,CAAC;IAAAH,eAAA,4BAEmB,MAAM;MACzB,IAAI,CAACE,QAAQ,CAAC;QAAEC,qBAAqB,EAAE;MAAM,CAAC,CAAC;IAChD,CAAC;IAAAH,eAAA,iCAEwB,MAAM;MAC9BlB,OAAO,CAACsB,OAAO,CAAC,eAAe,CAAC;MAChC,IAAI,CAACF,QAAQ,CAAC;QAAEC,qBAAqB,EAAE;MAAM,CAAC,CAAC;IAChD,CAAC;IAAAH,eAA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AAE,EAAE;IACXC,YAAY,EAAE;EACf,CAAC;EACDvB,kBAAkB,EAAE;IACnBwB,UAAU,EAAE,SAAS;IACrBjD,KAAK,EAAEjC,SAAS;IAChBmF,QAAQ,EAAE,EAAE;IACZC,YAAY,EAAE;EACf,CAAC;EACDzB,sBAAsB,EAAE;IACvBC,IAAI,EAAE,CAAC;IACPyB,cAAc,EAAE;EACjB,CAAC;EACDnB,iBAAiB,EAAE;IAClBoB,aAAa,EAAE,KAAK;IACpBC,UAAU,EAAE,QAAQ;IACpBT,KAAK,EAAE,GAAG;IACVvB,MAAM,EAAE,EAAE;IACViC,iBAAiB,EAAE,CAAC;IACpBP,YAAY,EAAE,CAAC;IACfG,YAAY,EAAE;EACf,CAAC;EACDhB,YAAY,EAAE;IACbnC,KAAK,EAAE,MAAM;IACbwD,SAAS,EAAE,QAAQ;IACnBP,UAAU,EAAE,aAAa;IACzBC,QAAQ,EAAE,EAAE;IACZvB,IAAI,EAAE;EACP;AACD,CAAC,CAAC;AAEF,MAAM8B,eAAe,GAAIhD,KAAK,IAAK;EAClC,OAAO;IACN4B,kBAAkB,EAAErE,8BAA8B,CAACyC,KAAK;EACzD,CAAC;AACF,CAAC;AAED,MAAMiD,MAAM,GAAG9F,OAAO,CAAC6F,eAAe,EAAE,CAAC,CAAC,CAAC,CAACnF,mBAAmB,CAAC;AAChE,SAASoF,MAAM,IAAIpF,mBAAmB","ignoreList":[]}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import React, { PureComponent } from
|
|
2
|
-
import { TouchableOpacity, View
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
1
|
+
import React, { PureComponent } from "react";
|
|
2
|
+
import { TouchableOpacity, View } from "react-native";
|
|
3
|
+
import { Text } from "./Text";
|
|
4
|
+
import { connect } from "react-redux";
|
|
5
|
+
import { Icon } from "@rneui/themed";
|
|
6
|
+
import { getLightBrandingColourFromState, getMainBrandingColourFromState } from "../colours";
|
|
6
7
|
class Attachment extends PureComponent {
|
|
7
8
|
render() {
|
|
8
9
|
return /*#__PURE__*/React.createElement(TouchableOpacity, {
|
|
@@ -28,18 +29,18 @@ class Attachment extends PureComponent {
|
|
|
28
29
|
const styles = {
|
|
29
30
|
pdfAttachment: {
|
|
30
31
|
padding: 4,
|
|
31
|
-
flexDirection:
|
|
32
|
+
flexDirection: "row",
|
|
32
33
|
borderRadius: 2,
|
|
33
34
|
marginTop: 8,
|
|
34
|
-
alignItems:
|
|
35
|
-
alignSelf:
|
|
35
|
+
alignItems: "center",
|
|
36
|
+
alignSelf: "flex-start"
|
|
36
37
|
},
|
|
37
38
|
pdfAttachmentIcon: {
|
|
38
39
|
fontSize: 16,
|
|
39
40
|
marginRight: 4
|
|
40
41
|
},
|
|
41
42
|
pdfAttachmentText: {
|
|
42
|
-
fontFamily:
|
|
43
|
+
fontFamily: "sf-semibold",
|
|
43
44
|
fontSize: 13
|
|
44
45
|
}
|
|
45
46
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","PureComponent","TouchableOpacity","View","Text","connect","Icon","getLightBrandingColourFromState","getMainBrandingColourFromState","Attachment","render","createElement","key","props","onPress","style","styles","pdfAttachment","backgroundColor","colourBrandingLight","name","type","iconStyle","pdfAttachmentIcon","color","colourBrandingMain","pdfAttachmentText","title","padding","flexDirection","borderRadius","marginTop","alignItems","alignSelf","fontSize","marginRight","fontFamily","mapStateToProps","state","attachment"],"sources":["Attachment.js"],"sourcesContent":["import React, { PureComponent } from
|
|
1
|
+
{"version":3,"names":["React","PureComponent","TouchableOpacity","View","Text","connect","Icon","getLightBrandingColourFromState","getMainBrandingColourFromState","Attachment","render","createElement","key","props","onPress","style","styles","pdfAttachment","backgroundColor","colourBrandingLight","name","type","iconStyle","pdfAttachmentIcon","color","colourBrandingMain","pdfAttachmentText","title","padding","flexDirection","borderRadius","marginTop","alignItems","alignSelf","fontSize","marginRight","fontFamily","mapStateToProps","state","attachment"],"sources":["Attachment.js"],"sourcesContent":["import React, { PureComponent } from \"react\";\nimport { TouchableOpacity, View } from \"react-native\";\nimport { Text } from \"./Text\";\nimport { connect } from \"react-redux\";\nimport { Icon } from \"@rneui/themed\";\nimport {\n\tgetLightBrandingColourFromState,\n\tgetMainBrandingColourFromState,\n} from \"../colours\";\n\nclass Attachment extends PureComponent {\n\trender() {\n\t\treturn (\n\t\t\t<TouchableOpacity key={this.props.key} onPress={this.props.onPress}>\n\t\t\t\t<View\n\t\t\t\t\tstyle={[\n\t\t\t\t\t\tstyles.pdfAttachment,\n\t\t\t\t\t\t{ backgroundColor: this.props.colourBrandingLight },\n\t\t\t\t\t]}\n\t\t\t\t>\n\t\t\t\t\t<Icon\n\t\t\t\t\t\tname=\"paperclip\"\n\t\t\t\t\t\ttype=\"font-awesome\"\n\t\t\t\t\t\ticonStyle={[\n\t\t\t\t\t\t\tstyles.pdfAttachmentIcon,\n\t\t\t\t\t\t\t{ color: this.props.colourBrandingMain },\n\t\t\t\t\t\t]}\n\t\t\t\t\t/>\n\t\t\t\t\t<Text\n\t\t\t\t\t\tstyle={[\n\t\t\t\t\t\t\tstyles.pdfAttachmentText,\n\t\t\t\t\t\t\t{ color: this.props.colourBrandingMain },\n\t\t\t\t\t\t]}\n\t\t\t\t\t>\n\t\t\t\t\t\t{this.props.title}\n\t\t\t\t\t</Text>\n\t\t\t\t</View>\n\t\t\t</TouchableOpacity>\n\t\t);\n\t}\n}\n\nconst styles = {\n\tpdfAttachment: {\n\t\tpadding: 4,\n\t\tflexDirection: \"row\",\n\t\tborderRadius: 2,\n\t\tmarginTop: 8,\n\t\talignItems: \"center\",\n\t\talignSelf: \"flex-start\",\n\t},\n\tpdfAttachmentIcon: {\n\t\tfontSize: 16,\n\t\tmarginRight: 4,\n\t},\n\tpdfAttachmentText: {\n\t\tfontFamily: \"sf-semibold\",\n\t\tfontSize: 13,\n\t},\n};\n\nconst mapStateToProps = (state) => {\n\treturn {\n\t\tcolourBrandingMain: getMainBrandingColourFromState(state),\n\t\tcolourBrandingLight: getLightBrandingColourFromState(state),\n\t};\n};\n\nconst attachment = connect(mapStateToProps, {})(Attachment);\nexport { attachment as Attachment };\n"],"mappings":"AAAA,OAAOA,KAAK,IAAIC,aAAa,QAAQ,OAAO;AAC5C,SAASC,gBAAgB,EAAEC,IAAI,QAAQ,cAAc;AACrD,SAASC,IAAI,QAAQ,QAAQ;AAC7B,SAASC,OAAO,QAAQ,aAAa;AACrC,SAASC,IAAI,QAAQ,eAAe;AACpC,SACCC,+BAA+B,EAC/BC,8BAA8B,QACxB,YAAY;AAEnB,MAAMC,UAAU,SAASR,aAAa,CAAC;EACtCS,MAAMA,CAAA,EAAG;IACR,oBACCV,KAAA,CAAAW,aAAA,CAACT,gBAAgB;MAACU,GAAG,EAAE,IAAI,CAACC,KAAK,CAACD,GAAI;MAACE,OAAO,EAAE,IAAI,CAACD,KAAK,CAACC;IAAQ,gBAClEd,KAAA,CAAAW,aAAA,CAACR,IAAI;MACJY,KAAK,EAAE,CACNC,MAAM,CAACC,aAAa,EACpB;QAAEC,eAAe,EAAE,IAAI,CAACL,KAAK,CAACM;MAAoB,CAAC;IAClD,gBAEFnB,KAAA,CAAAW,aAAA,CAACL,IAAI;MACJc,IAAI,EAAC,WAAW;MAChBC,IAAI,EAAC,cAAc;MACnBC,SAAS,EAAE,CACVN,MAAM,CAACO,iBAAiB,EACxB;QAAEC,KAAK,EAAE,IAAI,CAACX,KAAK,CAACY;MAAmB,CAAC;IACvC,CACF,CAAC,eACFzB,KAAA,CAAAW,aAAA,CAACP,IAAI;MACJW,KAAK,EAAE,CACNC,MAAM,CAACU,iBAAiB,EACxB;QAAEF,KAAK,EAAE,IAAI,CAACX,KAAK,CAACY;MAAmB,CAAC;IACvC,GAED,IAAI,CAACZ,KAAK,CAACc,KACP,CACD,CACW,CAAC;EAErB;AACD;AAEA,MAAMX,MAAM,GAAG;EACdC,aAAa,EAAE;IACdW,OAAO,EAAE,CAAC;IACVC,aAAa,EAAE,KAAK;IACpBC,YAAY,EAAE,CAAC;IACfC,SAAS,EAAE,CAAC;IACZC,UAAU,EAAE,QAAQ;IACpBC,SAAS,EAAE;EACZ,CAAC;EACDV,iBAAiB,EAAE;IAClBW,QAAQ,EAAE,EAAE;IACZC,WAAW,EAAE;EACd,CAAC;EACDT,iBAAiB,EAAE;IAClBU,UAAU,EAAE,aAAa;IACzBF,QAAQ,EAAE;EACX;AACD,CAAC;AAED,MAAMG,eAAe,GAAIC,KAAK,IAAK;EAClC,OAAO;IACNb,kBAAkB,EAAEjB,8BAA8B,CAAC8B,KAAK,CAAC;IACzDnB,mBAAmB,EAAEZ,+BAA+B,CAAC+B,KAAK;EAC3D,CAAC;AACF,CAAC;AAED,MAAMC,UAAU,GAAGlC,OAAO,CAACgC,eAAe,EAAE,CAAC,CAAC,CAAC,CAAC5B,UAAU,CAAC;AAC3D,SAAS8B,UAAU,IAAI9B,UAAU","ignoreList":[]}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
2
2
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
|
3
3
|
function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
4
|
-
import React, { PureComponent } from
|
|
5
|
-
import { StyleSheet } from
|
|
6
|
-
import { connect } from
|
|
7
|
-
import { FormCardSectionOptionLauncher } from
|
|
8
|
-
import { getMainBrandingColourFromState, TEXT_DARK } from
|
|
9
|
-
import { Services } from
|
|
4
|
+
import React, { PureComponent } from "react";
|
|
5
|
+
import { StyleSheet } from "react-native";
|
|
6
|
+
import { connect } from "react-redux";
|
|
7
|
+
import { FormCardSectionOptionLauncher } from "./FormCardSectionOptionLauncher";
|
|
8
|
+
import { getMainBrandingColourFromState, TEXT_DARK } from "../colours";
|
|
9
|
+
import { Services } from "../config";
|
|
10
10
|
class AudienceSelectorLauncher extends PureComponent {
|
|
11
11
|
constructor(...args) {
|
|
12
12
|
super(...args);
|
|
@@ -16,9 +16,9 @@ class AudienceSelectorLauncher extends PureComponent {
|
|
|
16
16
|
audienceType,
|
|
17
17
|
audienceTypeSelection
|
|
18
18
|
} = this.props;
|
|
19
|
-
Services.navigation.navigate(
|
|
19
|
+
Services.navigation.navigate("audienceSelectorPage", {
|
|
20
20
|
site: user.site,
|
|
21
|
-
audienceType: audienceType ||
|
|
21
|
+
audienceType: audienceType || "Custom",
|
|
22
22
|
audienceTypeSelection: audienceTypeSelection || [],
|
|
23
23
|
onChange: (audienceType, audienceTypeSelection) => {
|
|
24
24
|
if (this.props.onChange) this.props.onChange(audienceType, audienceTypeSelection);
|
|
@@ -32,14 +32,14 @@ class AudienceSelectorLauncher extends PureComponent {
|
|
|
32
32
|
textStyle,
|
|
33
33
|
audienceTypeSelection
|
|
34
34
|
} = this.props;
|
|
35
|
-
const selected = audienceTypeSelection && audienceTypeSelection.length > 0 ? `Current selection: ${audienceTypeSelection.map(i => i.Title).join(
|
|
35
|
+
const selected = audienceTypeSelection && audienceTypeSelection.length > 0 ? `Current selection: ${audienceTypeSelection.map(i => i.Title).join(", ")}` : "";
|
|
36
36
|
return /*#__PURE__*/React.createElement(FormCardSectionOptionLauncher, {
|
|
37
37
|
sectionStyle: [styles.audienceSection, style],
|
|
38
38
|
textStyle: [styles.audienceText, textStyle],
|
|
39
39
|
onPress: this.onPressAudience,
|
|
40
40
|
title: "Audience",
|
|
41
41
|
description: selected,
|
|
42
|
-
value: selected ?
|
|
42
|
+
value: selected ? "Custom" : "All Users"
|
|
43
43
|
});
|
|
44
44
|
}
|
|
45
45
|
}
|
|
@@ -48,7 +48,7 @@ const styles = StyleSheet.create({
|
|
|
48
48
|
paddingHorizontal: 0
|
|
49
49
|
},
|
|
50
50
|
audienceText: {
|
|
51
|
-
fontFamily:
|
|
51
|
+
fontFamily: "sf-semibold",
|
|
52
52
|
fontSize: 16,
|
|
53
53
|
color: TEXT_DARK
|
|
54
54
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","PureComponent","StyleSheet","connect","FormCardSectionOptionLauncher","getMainBrandingColourFromState","TEXT_DARK","Services","AudienceSelectorLauncher","constructor","args","_defineProperty","user","audienceType","audienceTypeSelection","props","navigation","navigate","site","onChange","render","style","textStyle","selected","length","map","i","Title","join","createElement","sectionStyle","styles","audienceSection","audienceText","onPress","onPressAudience","title","description","value","create","paddingHorizontal","fontFamily","fontSize","color","mapStateToProps","state","colourBrandingMain","audienceSelectorLauncher"],"sources":["AudienceSelectorLauncher.js"],"sourcesContent":["import React, { PureComponent } from
|
|
1
|
+
{"version":3,"names":["React","PureComponent","StyleSheet","connect","FormCardSectionOptionLauncher","getMainBrandingColourFromState","TEXT_DARK","Services","AudienceSelectorLauncher","constructor","args","_defineProperty","user","audienceType","audienceTypeSelection","props","navigation","navigate","site","onChange","render","style","textStyle","selected","length","map","i","Title","join","createElement","sectionStyle","styles","audienceSection","audienceText","onPress","onPressAudience","title","description","value","create","paddingHorizontal","fontFamily","fontSize","color","mapStateToProps","state","colourBrandingMain","audienceSelectorLauncher"],"sources":["AudienceSelectorLauncher.js"],"sourcesContent":["import React, { PureComponent } from \"react\";\nimport { StyleSheet } from \"react-native\";\nimport { connect } from \"react-redux\";\nimport { FormCardSectionOptionLauncher } from \"./FormCardSectionOptionLauncher\";\nimport { getMainBrandingColourFromState, TEXT_DARK } from \"../colours\";\nimport { Services } from \"../config\";\n\nclass AudienceSelectorLauncher extends PureComponent {\n\tonPressAudience = () => {\n\t\tconst { user, audienceType, audienceTypeSelection } = this.props;\n\n\t\tServices.navigation.navigate(\"audienceSelectorPage\", {\n\t\t\tsite: user.site,\n\t\t\taudienceType: audienceType || \"Custom\",\n\t\t\taudienceTypeSelection: audienceTypeSelection || [],\n\t\t\tonChange: (audienceType, audienceTypeSelection) => {\n\t\t\t\tif (this.props.onChange)\n\t\t\t\t\tthis.props.onChange(audienceType, audienceTypeSelection);\n\t\t\t},\n\t\t});\n\t};\n\n\trender() {\n\t\tconst { style, textStyle, audienceTypeSelection } = this.props;\n\t\tconst selected =\n\t\t\taudienceTypeSelection && audienceTypeSelection.length > 0\n\t\t\t\t? `Current selection: ${audienceTypeSelection.map((i) => i.Title).join(\", \")}`\n\t\t\t\t: \"\";\n\n\t\treturn (\n\t\t\t<FormCardSectionOptionLauncher\n\t\t\t\tsectionStyle={[styles.audienceSection, style]}\n\t\t\t\ttextStyle={[styles.audienceText, textStyle]}\n\t\t\t\tonPress={this.onPressAudience}\n\t\t\t\ttitle=\"Audience\"\n\t\t\t\tdescription={selected}\n\t\t\t\tvalue={selected ? \"Custom\" : \"All Users\"}\n\t\t\t/>\n\t\t);\n\t}\n}\n\nconst styles = StyleSheet.create({\n\taudienceSection: {\n\t\tpaddingHorizontal: 0,\n\t},\n\taudienceText: {\n\t\tfontFamily: \"sf-semibold\",\n\t\tfontSize: 16,\n\t\tcolor: TEXT_DARK,\n\t},\n});\n\nconst mapStateToProps = (state) => {\n\treturn {\n\t\tuser: state.user,\n\t\tcolourBrandingMain: getMainBrandingColourFromState(state),\n\t};\n};\n\nconst audienceSelectorLauncher = connect(\n\tmapStateToProps,\n\t{},\n)(AudienceSelectorLauncher);\nexport { audienceSelectorLauncher as AudienceSelectorLauncher };\n"],"mappings":";;;AAAA,OAAOA,KAAK,IAAIC,aAAa,QAAQ,OAAO;AAC5C,SAASC,UAAU,QAAQ,cAAc;AACzC,SAASC,OAAO,QAAQ,aAAa;AACrC,SAASC,6BAA6B,QAAQ,iCAAiC;AAC/E,SAASC,8BAA8B,EAAEC,SAAS,QAAQ,YAAY;AACtE,SAASC,QAAQ,QAAQ,WAAW;AAEpC,MAAMC,wBAAwB,SAASP,aAAa,CA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