@cometchat/chat-uikit-react-native 4.3.16 → 4.3.18
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/package.json +1 -1
- package/src/AI/AIAssistBot/AIAssistBotDecorator.tsx +20 -15
- package/src/AI/AIAssistBot/AIAssistBotStyle.ts +2 -2
- package/src/AI/AIAssistBot/AIAssistBotView.tsx +16 -14
- package/src/AI/AIAssistBot/configuration.ts +8 -7
- package/src/AI/AIAssistBot/resources/index.ts +1 -0
- package/src/AI/AIBaseConfiguration.ts +1 -0
- package/src/AI/AIConversationStarter/AIConversationStarterDecorator.tsx +27 -26
- package/src/AI/AIConversationStarter/AIConversationStarterStyle.ts +1 -0
- package/src/AI/AIConversationStarter/style.ts +29 -31
- package/src/AI/AIConversationSummary/AIConversationSummaryDecorator.tsx +14 -13
- package/src/AI/AIConversationSummary/AIConversationSummaryView.tsx +5 -4
- package/src/AI/AIConversationSummary/resources/index.ts +1 -0
- package/src/AI/AIExtensionDataSource.ts +1 -0
- package/src/AI/AISmartReplies/AISmartRepliesDecorator.tsx +28 -27
- package/src/AI/AISmartReplies/configuration.ts +2 -0
- package/src/AI/CardView.tsx +5 -5
- package/src/AI/resources/index.ts +3 -0
- package/src/AI/style.ts +68 -80
- package/src/CometChatAddMembers/AddMembersConfiguration.tsx +1 -0
- package/src/CometChatAddMembers/CometChatAddMembers.tsx +14 -13
- package/src/CometChatAddMembers/index.ts +10 -8
- package/src/CometChatBannedMembers/BannedMembersConfiguration.tsx +1 -0
- package/src/CometChatBannedMembers/CometChatBannedMembers.tsx +11 -8
- package/src/CometChatBannedMembers/index.ts +12 -7
- package/src/CometChatBannedMembers/resources/index.ts +1 -0
- package/src/CometChatContacts/CometChatContacts.tsx +9 -9
- package/src/CometChatContacts/ContactsConfiguration.tsx +1 -0
- package/src/CometChatContacts/Header.tsx +4 -4
- package/src/CometChatContacts/index.ts +5 -3
- package/src/CometChatConversations/CometChatConversations.tsx +289 -221
- package/src/CometChatConversations/ConversationsConfiguration.ts +14 -0
- package/src/CometChatConversations/index.ts +21 -10
- package/src/CometChatConversations/resources/index.ts +14 -0
- package/src/CometChatConversationsWithMessages/CometChatConversationsWithMessages.tsx +7 -5
- package/src/CometChatConversationsWithMessages/index.ts +6 -5
- package/src/CometChatConversationsWithMessages/resources/index.ts +1 -0
- package/src/CometChatCreateGroup/CometChatCreateGroup.tsx +30 -30
- package/src/CometChatCreateGroup/CreateGroupConfiguration.ts +1 -0
- package/src/CometChatCreateGroup/Header.tsx +1 -1
- package/src/CometChatCreateGroup/index.ts +5 -6
- package/src/CometChatCreateGroup/resources/index.ts +3 -0
- package/src/CometChatDetails/CometChatDetails.tsx +29 -28
- package/src/CometChatDetails/DetailsConfiguration.tsx +1 -0
- package/src/CometChatDetails/Header.tsx +1 -1
- package/src/CometChatDetails/index.ts +17 -15
- package/src/CometChatDetails/listners.ts +16 -16
- package/src/CometChatDetails/resources/index.ts +5 -0
- package/src/CometChatGroupMembers/CometChatGroupMembers.tsx +62 -52
- package/src/CometChatGroupMembers/GroupMemberConfiguration.ts +1 -1
- package/src/CometChatGroupMembers/GroupMemberStyle.ts +3 -3
- package/src/CometChatGroupMembers/index.ts +8 -16
- package/src/CometChatGroupMembers/resources/index.ts +5 -0
- package/src/CometChatGroups/CometChatGroups.tsx +46 -46
- package/src/CometChatGroups/GroupsConfiguration.ts +10 -9
- package/src/CometChatGroups/GroupsStyle.ts +1 -1
- package/src/CometChatGroups/index.ts +11 -10
- package/src/CometChatGroups/resources/index.ts +10 -0
- package/src/CometChatGroupsWithMessages/CometChatGroupsWithMessages.tsx +9 -8
- package/src/CometChatGroupsWithMessages/index.ts +6 -5
- package/src/CometChatGroupsWithMessages/resources/index.ts +1 -0
- package/src/CometChatJoinProtectedGroup/CometChatJoinProtectedGroup.tsx +22 -21
- package/src/CometChatJoinProtectedGroup/Header.tsx +1 -1
- package/src/CometChatJoinProtectedGroup/JoinProtectedGroupConfiguration.ts +1 -0
- package/src/CometChatJoinProtectedGroup/index.ts +5 -6
- package/src/CometChatJoinProtectedGroup/resources/index.ts +2 -0
- package/src/CometChatMessageComposer/CometChatMessageComposer.tsx +62 -59
- package/src/CometChatMessageComposer/MessageComposerConfiguration.tsx +1 -0
- package/src/CometChatMessageComposer/index.ts +6 -7
- package/src/CometChatMessageComposer/resources/index.ts +10 -0
- package/src/CometChatMessageHeader/CometChatMessageHeader.tsx +33 -31
- package/src/CometChatMessageHeader/MessageHeaderConfiguration.tsx +1 -0
- package/src/CometChatMessageHeader/index.ts +12 -13
- package/src/CometChatMessageHeader/listners.ts +18 -18
- package/src/CometChatMessageHeader/resources/index.ts +3 -0
- package/src/CometChatMessageInformation/CometChatMessageInformation.tsx +28 -24
- package/src/CometChatMessageInformation/index.ts +8 -8
- package/src/CometChatMessageInformation/resources/index.ts +1 -0
- package/src/CometChatMessageList/CometChatMessageList.tsx +289 -227
- package/src/CometChatMessageList/MessageListConfiguration.ts +50 -25
- package/src/CometChatMessageList/index.ts +16 -18
- package/src/CometChatMessageList/resources/index.ts +7 -0
- package/src/CometChatMessages/CometChatMessages.tsx +29 -26
- package/src/CometChatMessages/MessagesConfiguration.ts +2 -0
- package/src/CometChatMessages/index.ts +8 -7
- package/src/CometChatMessages/resources/index.ts +1 -0
- package/src/CometChatTabs/CometChatTabs.tsx +13 -23
- package/src/CometChatTabs/CometChatTabsStyle.ts +2 -0
- package/src/CometChatTabs/index.ts +3 -8
- package/src/CometChatThreadedMessages/CometChatThreadedMessages.tsx +37 -37
- package/src/CometChatThreadedMessages/Header.tsx +2 -2
- package/src/CometChatThreadedMessages/ThreadedMessagesConfiguration.ts +1 -0
- package/src/CometChatThreadedMessages/index.ts +11 -12
- package/src/CometChatThreadedMessages/resources/index.ts +6 -0
- package/src/CometChatTransferOwnership/CometChatTransferOwnership.tsx +5 -5
- package/src/CometChatTransferOwnership/TransferOwnershipConfiguration.ts +1 -0
- package/src/CometChatTransferOwnership/index.ts +10 -11
- package/src/CometChatUsers/CometChatUsers.tsx +11 -11
- package/src/CometChatUsers/UsersConfiguration.tsx +1 -0
- package/src/CometChatUsers/index.ts +8 -6
- package/src/CometChatUsersWithMessages/CometChatUsersWithMessages.tsx +6 -5
- package/src/CometChatUsersWithMessages/index.ts +6 -5
- package/src/calls/CallUtils.ts +4 -3
- package/src/calls/CallingDetailsUtils.tsx +9 -8
- package/src/calls/CallingExtension.tsx +2 -2
- package/src/calls/CallingExtentionDecorator.tsx +17 -17
- package/src/calls/CometChatCallBubble/CometChatCallBubble.tsx +3 -2
- package/src/calls/CometChatCallBubble/index.ts +14 -10
- package/src/calls/CometChatCallBubble/resources/index.ts +3 -0
- package/src/calls/CometChatCallButtons/CometChatCallButtonConfiguration.ts +1 -0
- package/src/calls/CometChatCallButtons/CometChatCallButtons.tsx +19 -18
- package/src/calls/CometChatCallButtons/index.ts +10 -8
- package/src/calls/CometChatCallButtons/resources/index.ts +2 -0
- package/src/calls/CometChatCallLogDetails/CallLogDetailsConfiguration.ts +2 -0
- package/src/calls/CometChatCallLogDetails/CometChatCallLogDetails.tsx +14 -13
- package/src/calls/CometChatCallLogDetails/index.ts +21 -10
- package/src/calls/CometChatCallLogDetails/resources/index.ts +1 -0
- package/src/calls/CometChatCallLogHistory/CallLogHistoryConfiguration.ts +3 -1
- package/src/calls/CometChatCallLogHistory/CometChatCallLogHistory.tsx +25 -24
- package/src/calls/CometChatCallLogHistory/index.ts +21 -10
- package/src/calls/CometChatCallLogHistory/resources/index.ts +13 -0
- package/src/calls/CometChatCallLogParticipants/CallLogParticipantsConfiguration.ts +4 -2
- package/src/calls/CometChatCallLogParticipants/CometChatCallLogParticipants.tsx +13 -12
- package/src/calls/CometChatCallLogParticipants/index.ts +21 -10
- package/src/calls/CometChatCallLogParticipants/resources/index.ts +1 -0
- package/src/calls/CometChatCallLogRecordings/CallLogRecordingsConfiguration.ts +5 -3
- package/src/calls/CometChatCallLogRecordings/CometChatCallLogRecordings.tsx +14 -13
- package/src/calls/CometChatCallLogRecordings/index.ts +21 -10
- package/src/calls/CometChatCallLogRecordings/resources/index.ts +2 -0
- package/src/calls/CometChatCallLogs/CallLogsConfiguration.ts +5 -3
- package/src/calls/CometChatCallLogs/CometChatCallLogs.tsx +37 -36
- package/src/calls/CometChatCallLogs/index.ts +14 -10
- package/src/calls/CometChatCallLogs/resources/index.ts +11 -0
- package/src/calls/CometChatCallLogsWithDetails/CallLogsWithDetailsConfiguration.ts +1 -0
- package/src/calls/CometChatCallLogsWithDetails/CometChatCallLogsWithDetails.tsx +3 -2
- package/src/calls/CometChatCallLogsWithDetails/index.ts +2 -4
- package/src/calls/CometChatIncomingCall/CometChatIncomingCall.tsx +19 -15
- package/src/calls/CometChatIncomingCall/index.ts +10 -8
- package/src/calls/CometChatIncomingCall/resources/index.ts +4 -0
- package/src/calls/CometChatIncomingCall/styles.ts +0 -1
- package/src/calls/CometChatOngoingCall/CometChatOngoingCall.tsx +5 -4
- package/src/calls/CometChatOngoingCall/index.ts +6 -6
- package/src/calls/CometChatOutgoingCall/CometChatOutgoingCall.tsx +15 -13
- package/src/calls/CometChatOutgoingCall/index.ts +8 -6
- package/src/calls/CometChatOutgoingCall/resources/index.ts +1 -0
- package/src/calls/index.ts +99 -60
- package/src/calls/resources/index.ts +3 -0
- package/src/extensions/CollaborativeBubble/CometChatCollaborativeBubble.tsx +1 -0
- package/src/extensions/CollaborativeBubble/resources/index.ts +1 -0
- package/src/extensions/CollaborativeBubble/styles.ts +1 -1
- package/src/extensions/CollaborativeDocument/CollaborativeDocumentConfiguration.tsx +1 -1
- package/src/extensions/CollaborativeDocument/CollaborativeDocumentExtensionDecorator.tsx +10 -9
- package/src/extensions/CollaborativeDocument/index.ts +12 -9
- package/src/extensions/CollaborativeDocument/resources/index.ts +2 -0
- package/src/extensions/CollaborativeWhiteboard/CollaborativeWhiteboardConfiguration.tsx +1 -1
- package/src/extensions/CollaborativeWhiteboard/CollaborativeWhiteboardExtensionDecorator.tsx +15 -14
- package/src/extensions/CollaborativeWhiteboard/index.ts +12 -9
- package/src/extensions/CollaborativeWhiteboard/resources/index.ts +2 -0
- package/src/extensions/ExtensionModerator.tsx +4 -4
- package/src/extensions/ImageModeration/ImageModerationDecorator.tsx +1 -1
- package/src/extensions/ImageModeration/ImageModerationFilter.tsx +2 -1
- package/src/extensions/ImageModeration/index.ts +15 -7
- package/src/extensions/ImageModeration/resources/index.ts +1 -0
- package/src/extensions/LinkPreview/LinkPreviewBubble.tsx +8 -8
- package/src/extensions/LinkPreview/LinkPreviewExtention.tsx +1 -1
- package/src/extensions/LinkPreview/LinkPreviewExtentionDecorator.tsx +2 -1
- package/src/extensions/LinkPreview/index.ts +18 -10
- package/src/extensions/LinkPreview/resources/index.ts +1 -0
- package/src/extensions/MessageTranslation/MessageTranslationBubble.tsx +7 -7
- package/src/extensions/MessageTranslation/MessageTranslationDecorator.tsx +19 -17
- package/src/extensions/MessageTranslation/index.ts +7 -7
- package/src/extensions/MessageTranslation/resources/index.ts +1 -0
- package/src/extensions/Polls/Header.tsx +8 -8
- package/src/extensions/Polls/Polls.tsx +38 -33
- package/src/extensions/Polls/PollsBubble.tsx +35 -33
- package/src/extensions/Polls/PollsDecorator.tsx +7 -7
- package/src/extensions/Polls/index.ts +4 -5
- package/src/extensions/Polls/resources/index.ts +5 -0
- package/src/extensions/SmartReplies/SmartRepliesDecorator.tsx +11 -11
- package/src/extensions/SmartReplies/SmartRepliesView.tsx +4 -3
- package/src/extensions/SmartReplies/index.ts +6 -2
- package/src/extensions/SmartReplies/resources/index.ts +1 -0
- package/src/extensions/Stickers/CometChatStickerKeyboard/CometChatStickerKeyboard.tsx +12 -10
- package/src/extensions/Stickers/CometChatStickerKeyboard/StickerKeyboardConfiguration.ts +2 -1
- package/src/extensions/Stickers/CometChatStickerKeyboard/hooks.ts +19 -17
- package/src/extensions/Stickers/StickersBubble.tsx +4 -4
- package/src/extensions/Stickers/StickersExtensionDecorator.tsx +11 -10
- package/src/extensions/Stickers/index.ts +13 -8
- package/src/extensions/Stickers/resources/index.ts +1 -0
- package/src/extensions/TextModeration/TextModerationConfiguration.tsx +1 -1
- package/src/extensions/TextModeration/TextModerationExtension.tsx +1 -0
- package/src/extensions/TextModeration/TextModerationExtensionDecorator.tsx +1 -0
- package/src/extensions/TextModeration/index.ts +5 -4
- package/src/extensions/ThumbnailGeneration/ThumbnailGenerationDecorator.tsx +5 -5
- package/src/extensions/ThumbnailGeneration/index.ts +6 -2
- package/src/extensions/ThumbnailGeneration/resources/index.ts +1 -0
- package/src/extensions/index.ts +92 -47
- package/src/index.ts +225 -232
- package/src/shared/CometChatContext.tsx +1 -1
- package/src/shared/CometChatUiKit/CometChatUIKit.ts +40 -36
- package/src/shared/CometChatUiKit/CometChatUIKitHelper.ts +1 -0
- package/src/shared/assets/images/index.ts +16 -0
- package/src/shared/assets/images/search.png +0 -0
- package/src/shared/base/FontStyle.ts +2 -2
- package/src/shared/base/index.ts +8 -11
- package/src/shared/base/vars.ts +2 -2
- package/src/shared/constants/UIKitConstants.ts +16 -1
- package/src/shared/events/CometChatMessageEvents/index.ts +6 -4
- package/src/shared/events/CometChatUIEventHandler/CometChatUIEventHandler.ts +221 -219
- package/src/shared/events/CometChatUIEventHandler/Listener.ts +39 -37
- package/src/shared/events/ListenerInitializer.ts +8 -1
- package/src/shared/events/messages.ts +2 -0
- package/src/shared/formatters/CometChatMentionsFormatter/CometChatMentionsFormatter.tsx +11 -15
- package/src/shared/formatters/CometChatTextFormatter.ts +6 -5
- package/src/shared/formatters/CometChatUrlsFormatter/index.tsx +8 -10
- package/src/shared/framework/DataSource.ts +17 -17
- package/src/shared/framework/DataSourceDecorator.tsx +3 -2
- package/src/shared/framework/ExtensionsDataSource.tsx +1 -0
- package/src/shared/framework/MessageDataSource.tsx +125 -117
- package/src/shared/framework/index.ts +12 -6
- package/src/shared/framework/resources/index.ts +20 -0
- package/src/shared/helper/helperFunctions.ts +7 -5
- package/src/shared/index.ts +109 -100
- package/src/shared/libs/CometChatCalendar/Calendars/BaseCalendar.tsx +6 -3
- package/src/shared/libs/CometChatCalendar/Calendars/DateSelectionCalendar.tsx +2 -0
- package/src/shared/libs/CometChatCalendar/Calendars/MultiDateSelectionCalendar.tsx +2 -0
- package/src/shared/libs/CometChatCalendar/Components/Day.tsx +2 -0
- package/src/shared/libs/CometChatCalendar/Components/Days.tsx +1 -0
- package/src/shared/libs/CometChatCalendar/Components/Month.tsx +1 -0
- package/src/shared/libs/CometChatCalendar/Components/Months.tsx +1 -0
- package/src/shared/libs/CometChatCalendar/Components/Title.tsx +2 -0
- package/src/shared/libs/CometChatCalendar/Hooks/useSurroundingTimeUnits.ts +3 -0
- package/src/shared/libs/CometChatCalendar/Locales/index.ts +1 -0
- package/src/shared/libs/CometChatCalendar/Utils/dateRange.ts +1 -0
- package/src/shared/libs/CometChatCalendar/Utils/getExtraDays.ts +1 -0
- package/src/shared/libs/CometChatCalendar/Utils/getSurroundingTimeUnits.ts +1 -0
- package/src/shared/libs/ImageZoom/ReactNativeZoomableView.tsx +45 -42
- package/src/shared/libs/ImageZoom/ReactNativeZoomableViewWithGestures.tsx +13 -11
- package/src/shared/libs/ImageZoom/types/index.ts +12 -12
- package/src/shared/libs/VideoPlayerControls/OSSupport/TVOSSupport.tsx +1 -0
- package/src/shared/libs/VideoPlayerControls/VideoPlayer.tsx +1 -0
- package/src/shared/libs/datePickerModal/Modal.js +1 -1
- package/src/shared/modals/CometChatDetailsOption.ts +2 -2
- package/src/shared/modals/CometChatMessageTemplate.ts +13 -12
- package/src/shared/modals/InteractiveData/InteractiveElements/DateTimeElement.ts +7 -7
- package/src/shared/modals/InteractiveData/InteractiveMessage/CardMessage.ts +1 -0
- package/src/shared/modals/InteractiveData/InteractiveMessage/CustomInteractiveMessage.ts +1 -0
- package/src/shared/modals/InteractiveData/InteractiveMessage/FormMessage.ts +1 -0
- package/src/shared/modals/InteractiveData/InteractiveMessage/SchedulerMessage.ts +6 -7
- package/src/shared/modals/index.ts +37 -14
- package/src/shared/resources/CometChatLocalize/CometChatLocalize.ts +5 -5
- package/src/shared/resources/CometChatSoundManager/index.ts +1 -0
- package/src/shared/resources/CometChatTheme/Palette.ts +57 -55
- package/src/shared/resources/CometChatTheme/Typography.ts +30 -30
- package/src/shared/utils/CometChatLiveReactions/CometChatLiveReaction.tsx +17 -13
- package/src/shared/utils/CometChatLiveReactions/resources/index.ts +1 -0
- package/src/shared/utils/CometChatMessageHelper/index.ts +2 -2
- package/src/shared/utils/CometChatMessagePreview/{index.js → index.ts} +3 -0
- package/src/shared/utils/CometChatMessagePreview/resources/index.ts +1 -0
- package/src/shared/utils/CommonUtils.ts +85 -1
- package/src/shared/utils/DetailsUtils/DetailsUtils.tsx +3 -2
- package/src/shared/utils/DetailsUtils/resources/index.ts +7 -0
- package/src/shared/utils/InteractiveMessageUtils.ts +6 -5
- package/src/shared/utils/MessageUtils.tsx +108 -18
- package/src/shared/utils/NetworkUtils.tsx +1 -1
- package/src/shared/utils/PermissionUtil.ts +7 -6
- package/src/shared/utils/SchedulerUtils.ts +8 -6
- package/src/shared/utils/TypeUtils.ts +3 -0
- package/src/shared/utils/conversationUtils.ts +7 -5
- package/src/shared/utils/index.ts +2 -0
- package/src/shared/views/CometChatAICard/CometChatAICard.tsx +7 -6
- package/src/shared/views/CometChatAICard/resources/index.ts +2 -0
- package/src/shared/views/CometChatActionSheet/ActionSheetStyle.ts +3 -0
- package/src/shared/views/CometChatActionSheet/CometChatActionSheet.tsx +5 -5
- package/src/shared/views/CometChatActionSheet/hooks.ts +2 -2
- package/src/shared/views/CometChatActionSheet/index.ts +5 -3
- package/src/shared/views/CometChatActionSheet/resources/index.ts +2 -0
- package/src/shared/views/CometChatAudioBubble/CometChatAudioBubble.tsx +6 -6
- package/src/shared/views/CometChatAudioBubble/index.ts +8 -12
- package/src/shared/views/CometChatAudioBubble/resources/index.ts +2 -0
- package/src/shared/views/CometChatAvatar/CometChatAvatar.tsx +6 -5
- package/src/shared/views/CometChatAvatar/index.ts +7 -9
- package/src/shared/views/CometChatBadge/CometChatBadge.tsx +3 -3
- package/src/shared/views/CometChatBadge/index.ts +7 -9
- package/src/shared/views/CometChatBottomSheet/CometChatBottomSheet.tsx +51 -48
- package/src/shared/views/CometChatBottomSheet/index.ts +6 -2
- package/src/shared/views/CometChatButton/CometChatButton.tsx +5 -5
- package/src/shared/views/CometChatButton/index.ts +4 -14
- package/src/shared/views/CometChatCard/CometChatCard.tsx +3 -3
- package/src/shared/views/CometChatCard/index.ts +6 -7
- package/src/shared/views/CometChatCardBubble/CometChatCardBubble.tsx +11 -10
- package/src/shared/views/CometChatCardBubble/index.tsx +2 -1
- package/src/shared/views/CometChatCheckBox/CometChatCheckBox.tsx +6 -6
- package/src/shared/views/CometChatConfirmDialog/CometChatConfirmDialog.tsx +9 -9
- package/src/shared/views/CometChatConfirmDialog/CometChatConfirmDialogStyle.ts +1 -0
- package/src/shared/views/CometChatConfirmDialog/index.ts +9 -6
- package/src/shared/views/CometChatDate/CometChatDate.tsx +2 -2
- package/src/shared/views/CometChatDate/index.ts +12 -11
- package/src/shared/views/CometChatDateTimePicker/CometChatDateTimePicker.tsx +20 -17
- package/src/shared/views/CometChatDateTimePicker/index.ts +3 -5
- package/src/shared/views/CometChatDropDown/CometChatDropDown.tsx +8 -7
- package/src/shared/views/CometChatEmojiKeyboard/CometChatEmojiKeyboard.tsx +24 -33
- package/src/shared/views/CometChatEmojiKeyboard/Emoji.ts +1 -1
- package/src/shared/views/CometChatEmojiKeyboard/EmojiCategory.ts +1 -1
- package/src/shared/views/CometChatEmojiKeyboard/EmojiKeyboardConfiguration.ts +2 -1
- package/src/shared/views/CometChatEmojiKeyboard/EmojiKeyboardStyle.ts +2 -1
- package/src/shared/views/CometChatEmojiKeyboard/emojis.ts +8 -0
- package/src/shared/views/CometChatEmojiKeyboard/resources/index.ts +8 -0
- package/src/shared/views/CometChatEmojiKeyboard/style.ts +2 -2
- package/src/shared/views/CometChatFileBubble/CometChatFileBubble.tsx +3 -3
- package/src/shared/views/CometChatFileBubble/FileBubbleStyle.ts +1 -1
- package/src/shared/views/CometChatFileBubble/index.ts +7 -8
- package/src/shared/views/CometChatFileBubble/resources/index.ts +2 -0
- package/src/shared/views/CometChatFormBubble/CometChatFormBubble.tsx +33 -29
- package/src/shared/views/CometChatFormBubble/index.tsx +2 -1
- package/src/shared/views/CometChatImageBubble/CometChatImageBubble.tsx +63 -17
- package/src/shared/views/CometChatImageBubble/ImageBubbleStyle.ts +1 -1
- package/src/shared/views/CometChatImageBubble/assets/default_image.png +0 -0
- package/src/shared/views/CometChatImageBubble/assets/index.ts +3 -0
- package/src/shared/views/CometChatImageBubble/index.ts +10 -8
- package/src/shared/views/CometChatImageViewerModal/ImageViewerModal.tsx +1 -1
- package/src/shared/views/CometChatImageViewerModal/resources/index.ts +1 -0
- package/src/shared/views/CometChatLabel/CometChatLabel.tsx +2 -2
- package/src/shared/views/CometChatList/CometChatList.tsx +46 -42
- package/src/shared/views/CometChatList/index.ts +3 -3
- package/src/shared/views/CometChatList/resources/index.ts +5 -0
- package/src/shared/views/CometChatListItem/CometChatListItem.tsx +18 -13
- package/src/shared/views/CometChatListItem/ListItemConfiguration.tsx +1 -0
- package/src/shared/views/CometChatListItem/index.ts +8 -7
- package/src/shared/views/CometChatMediaRecorder/CometChatMediaRecorder.tsx +34 -31
- package/src/shared/views/CometChatMediaRecorder/index.ts +8 -9
- package/src/shared/views/CometChatMessageBubble/CometChatMessageBubble.tsx +22 -15
- package/src/shared/views/CometChatMessageBubble/MessageBubbleStyle.ts +4 -0
- package/src/shared/views/CometChatMessageBubble/index.ts +6 -5
- package/src/shared/views/CometChatMessageInput/CometChatMessageInput.tsx +10 -9
- package/src/shared/views/CometChatMessageInput/index.ts +2 -1
- package/src/shared/views/CometChatPanel/CometChatPanel.tsx +3 -3
- package/src/shared/views/CometChatPanel/resources/index.ts +1 -0
- package/src/shared/views/CometChatQuickReactions/CometChatQuickReactions.tsx +4 -4
- package/src/shared/views/CometChatQuickReactions/QuickReactionsConfiguration.tsx +1 -0
- package/src/shared/views/CometChatQuickReactions/index.ts +3 -7
- package/src/shared/views/CometChatQuickReactions/resources/index.ts +1 -0
- package/src/shared/views/CometChatQuickView/CometChatQuickView.tsx +6 -6
- package/src/shared/views/CometChatRadioButton/CometChatRadioButton.tsx +4 -4
- package/src/shared/views/CometChatReactionList/CometChatReactionList.tsx +29 -28
- package/src/shared/views/CometChatReactionList/ReactionListConfiguration.tsx +1 -0
- package/src/shared/views/CometChatReactionList/index.ts +3 -7
- package/src/shared/views/CometChatReactionList/resources/index.ts +1 -0
- package/src/shared/views/CometChatReactions/CometChatReactions.tsx +14 -14
- package/src/shared/views/CometChatReactions/ReactionsConfiguration.tsx +1 -0
- package/src/shared/views/CometChatReactions/index.ts +15 -11
- package/src/shared/views/CometChatReceipt/CometChatReceipt.tsx +5 -5
- package/src/shared/views/CometChatReceipt/index.ts +10 -8
- package/src/shared/views/CometChatSchedulerBubble/CometChatSchedulerBubble.tsx +59 -53
- package/src/shared/views/CometChatSchedulerBubble/index.ts +3 -5
- package/src/shared/views/CometChatSchedulerBubble/styles.ts +1 -1
- package/src/shared/views/CometChatSingleSelect/CometChatSingleSelect.tsx +4 -4
- package/src/shared/views/CometChatStatusIndicator/CometChatStatusIndicator.tsx +4 -4
- package/src/shared/views/CometChatStatusIndicator/StatusIndicatorConfiguration.ts +2 -2
- package/src/shared/views/CometChatStatusIndicator/index.ts +21 -10
- package/src/shared/views/CometChatSuggestionList/CometChatSuggestionList.tsx +1 -1
- package/src/shared/views/CometChatSuggestionList/SuggestionItem.ts +5 -5
- package/src/shared/views/CometChatSuggestionList/SuggestionListConfiguration.ts +3 -3
- package/src/shared/views/CometChatSuggestionList/index.ts +14 -10
- package/src/shared/views/CometChatTextBubble/CometChatTextBubble.tsx +6 -5
- package/src/shared/views/CometChatTextBubble/index.ts +6 -7
- package/src/shared/views/CometChatTextInput/CometChatTextInput.tsx +2 -2
- package/src/shared/views/CometChatTimeSlotSelector/CometChatTimeSlotSelector.tsx +5 -5
- package/src/shared/views/CometChatTimeSlotSelector/index.ts +3 -5
- package/src/shared/views/CometChatVideoBubble/CometChatVideoBubble.tsx +9 -8
- package/src/shared/views/CometChatVideoBubble/index.ts +10 -8
- package/src/shared/views/CometChatVideoBubble/resources/index.ts +2 -0
- package/src/shared/views/CometChatVideoPlayer/CometChatVideoPlayer.tsx +1 -1
- package/src/shared/views/SwipeRow/SwipeRow.tsx +4 -3
- package/src/shared/views/index.ts +151 -86
- package/ios/CometchatUiKit.xcodeproj/project.xcworkspace/xcuserdata/admin.xcuserdatad/UserInterfaceState.xcuserstate +0 -0
- package/ios/CometchatUiKit.xcodeproj/xcuserdata/admin.xcuserdatad/xcschemes/xcschememanagement.plist +0 -14
- package/src/shared/libs/CometChatCalendar/Components/Arrow.test.tsx +0 -112
- package/src/shared/libs/CometChatCalendar/Components/Day.test.tsx +0 -396
- package/src/shared/libs/CometChatCalendar/Components/Days.test.tsx +0 -216
- package/src/shared/libs/CometChatCalendar/Components/Month.test.tsx +0 -160
- package/src/shared/libs/CometChatCalendar/Components/Months.test.tsx +0 -262
- package/src/shared/libs/CometChatCalendar/Components/Title.test.tsx +0 -111
- package/src/shared/libs/CometChatCalendar/Components/Weekdays.test.tsx +0 -69
- package/src/shared/libs/CometChatCalendar/Hooks/useSurroundingTimeUnits.test.ts +0 -44
- package/src/shared/libs/CometChatCalendar/Utils/addOpacity.test.ts +0 -49
- package/src/shared/libs/CometChatCalendar/Utils/clamp.test.ts +0 -39
- package/src/shared/libs/CometChatCalendar/Utils/dateRange.test.ts +0 -20
- package/src/shared/libs/CometChatCalendar/Utils/getExtraDays.test.ts +0 -48
- package/src/shared/libs/CometChatCalendar/Utils/getSurroundingTimeUnits.test.ts +0 -60
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { anyObject } from "../../utils";
|
|
2
|
+
|
|
1
3
|
type modeType = 'light' | 'dark'
|
|
2
4
|
const modes = {
|
|
3
5
|
light: 'light',
|
|
@@ -43,7 +45,7 @@ const opacity = {
|
|
|
43
45
|
},
|
|
44
46
|
};
|
|
45
47
|
|
|
46
|
-
const getAccentOpacity = (colorCode, opacity) => {
|
|
48
|
+
const getAccentOpacity = (colorCode: string, opacity: any) => {
|
|
47
49
|
if (colorCode.startsWith('#')) {
|
|
48
50
|
return hexToRGBA(colorCode, opacity);
|
|
49
51
|
}
|
|
@@ -51,7 +53,7 @@ const getAccentOpacity = (colorCode, opacity) => {
|
|
|
51
53
|
return RGBToRGBA(colorCode, opacity);
|
|
52
54
|
};
|
|
53
55
|
|
|
54
|
-
const hexToRGBA = (hex, opacity) => {
|
|
56
|
+
const hexToRGBA = (hex: string, opacity: string) => {
|
|
55
57
|
const r = parseInt(hex.slice(1, 3), 16);
|
|
56
58
|
const g = parseInt(hex.slice(3, 5), 16);
|
|
57
59
|
const b = parseInt(hex.slice(5, 7), 16);
|
|
@@ -59,7 +61,7 @@ const hexToRGBA = (hex, opacity) => {
|
|
|
59
61
|
return 'rgba(' + +r + ',' + +g + ',' + +b + ',' + opacity + ')';
|
|
60
62
|
};
|
|
61
63
|
|
|
62
|
-
const RGBToRGBA = (rgb, opacity) => {
|
|
64
|
+
const RGBToRGBA = (rgb: any, opacity: string) => {
|
|
63
65
|
// Choose correct separator
|
|
64
66
|
let sep = rgb.indexOf(',') > -1 ? ',' : ' ';
|
|
65
67
|
// Turn "rgb(r,g,b)" into [r,g,b]
|
|
@@ -80,7 +82,7 @@ const RGBToRGBA = (rgb, opacity) => {
|
|
|
80
82
|
class PaletteItem {
|
|
81
83
|
light: string
|
|
82
84
|
dark: string
|
|
83
|
-
constructor({ light = '', dark = '' }) {
|
|
85
|
+
constructor({ light = '', dark = '' }: anyObject) {
|
|
84
86
|
this.light = light;
|
|
85
87
|
this.dark = dark;
|
|
86
88
|
}
|
|
@@ -257,129 +259,129 @@ class Palette {
|
|
|
257
259
|
* Getters
|
|
258
260
|
*/
|
|
259
261
|
getAccent = (mode?: modeType) => {
|
|
260
|
-
return this.accent[mode || this.mode];
|
|
262
|
+
return this.accent[mode || this.mode as keyof PaletteItem];
|
|
261
263
|
};
|
|
262
264
|
getAccent50 = (mode?: modeType) => {
|
|
263
|
-
return this.accent50[mode || this.mode];
|
|
265
|
+
return this.accent50[mode || this.mode as keyof PaletteItem];
|
|
264
266
|
};
|
|
265
267
|
getAccent100 = (mode?: modeType) => {
|
|
266
|
-
return this.accent100[mode || this.mode];
|
|
268
|
+
return this.accent100[mode || this.mode as keyof PaletteItem];
|
|
267
269
|
};
|
|
268
270
|
getAccent200 = (mode?: modeType) => {
|
|
269
|
-
return this.accent200[mode || this.mode];
|
|
271
|
+
return this.accent200[mode || this.mode as keyof PaletteItem];
|
|
270
272
|
};
|
|
271
273
|
getAccent300 = (mode?: modeType) => {
|
|
272
|
-
return this.accent300[mode || this.mode];
|
|
274
|
+
return this.accent300[mode || this.mode as keyof PaletteItem];
|
|
273
275
|
};
|
|
274
276
|
getAccent400 = (mode?: modeType) => {
|
|
275
|
-
return this.accent400[mode || this.mode];
|
|
277
|
+
return this.accent400[mode || this.mode as keyof PaletteItem];
|
|
276
278
|
};
|
|
277
279
|
getAccent500 = (mode?: modeType) => {
|
|
278
|
-
return this.accent500[mode || this.mode];
|
|
280
|
+
return this.accent500[mode || this.mode as keyof PaletteItem];
|
|
279
281
|
};
|
|
280
282
|
getAccent600 = (mode?: modeType) => {
|
|
281
|
-
return this.accent600[mode || this.mode];
|
|
283
|
+
return this.accent600[mode || this.mode as keyof PaletteItem];
|
|
282
284
|
};
|
|
283
285
|
getAccent700 = (mode?: modeType) => {
|
|
284
|
-
return this.accent700[mode || this.mode];
|
|
286
|
+
return this.accent700[mode || this.mode as keyof PaletteItem];
|
|
285
287
|
};
|
|
286
288
|
getAccent800 = (mode?: modeType) => {
|
|
287
|
-
return this.accent800[mode || this.mode];
|
|
289
|
+
return this.accent800[mode || this.mode as keyof PaletteItem];
|
|
288
290
|
};
|
|
289
291
|
getAccent900 = (mode?: modeType) => {
|
|
290
|
-
return this.accent900[mode || this.mode];
|
|
292
|
+
return this.accent900[mode || this.mode as keyof PaletteItem];
|
|
291
293
|
};
|
|
292
294
|
getSuccess = (mode?: modeType) => {
|
|
293
|
-
return this.success[mode || this.mode];
|
|
295
|
+
return this.success[mode || this.mode as keyof PaletteItem];
|
|
294
296
|
};
|
|
295
297
|
getError = (mode?: modeType) => {
|
|
296
|
-
return this.error[mode || this.mode];
|
|
298
|
+
return this.error[mode || this.mode as keyof PaletteItem];
|
|
297
299
|
};
|
|
298
300
|
getPrimary = (mode?: modeType) => {
|
|
299
|
-
return this.primary[mode || this.mode];
|
|
301
|
+
return this.primary[mode || this.mode as keyof PaletteItem];
|
|
300
302
|
};
|
|
301
303
|
getPrimary13 = (mode?: modeType) => {
|
|
302
|
-
return this.primary13[mode || this.mode];
|
|
304
|
+
return this.primary13[mode || this.mode as keyof PaletteItem];
|
|
303
305
|
};
|
|
304
306
|
getPrimary40 = (mode?: modeType) => {
|
|
305
|
-
return this.primary40[mode || this.mode];
|
|
307
|
+
return this.primary40[mode || this.mode as keyof PaletteItem];
|
|
306
308
|
}
|
|
307
309
|
getPrimary150 = (mode?: modeType) => {
|
|
308
|
-
return this.primary150[mode || this.mode];
|
|
310
|
+
return this.primary150[mode || this.mode as keyof PaletteItem];
|
|
309
311
|
}
|
|
310
312
|
getPrimary500 = (mode?: modeType) => {
|
|
311
|
-
return this.primary500[mode || this.mode];
|
|
313
|
+
return this.primary500[mode || this.mode as keyof PaletteItem];
|
|
312
314
|
}
|
|
313
315
|
getSecondary = (mode?: modeType) => {
|
|
314
|
-
return this.secondary[mode || this.mode];
|
|
316
|
+
return this.secondary[mode || this.mode as keyof PaletteItem];
|
|
315
317
|
};
|
|
316
318
|
getTertiary = (mode?: modeType) => {
|
|
317
|
-
return this.tertiary[mode || this.mode];
|
|
319
|
+
return this.tertiary[mode || this.mode as keyof PaletteItem];
|
|
318
320
|
};
|
|
319
321
|
getBackgroundColor = (mode?: modeType) => {
|
|
320
|
-
return this.backgroundColor[mode || this.mode];
|
|
322
|
+
return this.backgroundColor[mode || this.mode as keyof PaletteItem];
|
|
321
323
|
};
|
|
322
324
|
|
|
323
325
|
|
|
324
|
-
setMode(mode) {
|
|
326
|
+
setMode(mode: string) {
|
|
325
327
|
this.mode = mode;
|
|
326
328
|
}
|
|
327
329
|
|
|
328
|
-
setBackground(colorset) {
|
|
329
|
-
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
330
|
+
setBackground(colorset: PaletteItem) {
|
|
331
|
+
if (colorset && colorset[modes.light as keyof PaletteItem] && colorset[modes.dark as keyof PaletteItem]) {
|
|
330
332
|
this.backgroundColor = colorset;
|
|
331
333
|
}
|
|
332
334
|
}
|
|
333
335
|
|
|
334
|
-
setPrimary(colorset) {
|
|
335
|
-
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
336
|
+
setPrimary(colorset: PaletteItem) {
|
|
337
|
+
if (colorset && colorset[modes.light as keyof PaletteItem] && colorset[modes.dark as keyof PaletteItem]) {
|
|
336
338
|
this.primary = colorset;
|
|
337
339
|
}
|
|
338
340
|
}
|
|
339
341
|
|
|
340
|
-
setPrimary13(colorset) {
|
|
341
|
-
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
342
|
+
setPrimary13(colorset: PaletteItem) {
|
|
343
|
+
if (colorset && colorset[modes.light as keyof PaletteItem] && colorset[modes.dark as keyof PaletteItem]) {
|
|
342
344
|
this.primary13 = colorset;
|
|
343
345
|
}
|
|
344
346
|
}
|
|
345
347
|
|
|
346
|
-
setPrimary40(colorset) {
|
|
347
|
-
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
348
|
+
setPrimary40(colorset: PaletteItem) {
|
|
349
|
+
if (colorset && colorset[modes.light as keyof PaletteItem] && colorset[modes.dark as keyof PaletteItem]) {
|
|
348
350
|
this.primary40 = colorset;
|
|
349
351
|
}
|
|
350
352
|
}
|
|
351
353
|
|
|
352
|
-
setSecondary(colorset) {
|
|
353
|
-
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
354
|
+
setSecondary(colorset: PaletteItem) {
|
|
355
|
+
if (colorset && colorset[modes.light as keyof PaletteItem] && colorset[modes.dark as keyof PaletteItem]) {
|
|
354
356
|
this.secondary = colorset;
|
|
355
357
|
}
|
|
356
358
|
}
|
|
357
359
|
|
|
358
|
-
setTertiary(colorset) {
|
|
359
|
-
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
360
|
+
setTertiary(colorset: PaletteItem) {
|
|
361
|
+
if (colorset && colorset[modes.light as keyof PaletteItem] && colorset[modes.dark as keyof PaletteItem]) {
|
|
360
362
|
this.tertiary = colorset;
|
|
361
363
|
}
|
|
362
364
|
}
|
|
363
365
|
|
|
364
|
-
setPrimary150(colorset) {
|
|
365
|
-
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
366
|
+
setPrimary150(colorset: PaletteItem) {
|
|
367
|
+
if (colorset && colorset[modes.light as keyof PaletteItem] && colorset[modes.dark as keyof PaletteItem]) {
|
|
366
368
|
this.primary150 = colorset;
|
|
367
369
|
}
|
|
368
370
|
}
|
|
369
371
|
|
|
370
|
-
setPrimary500(colorset) {
|
|
371
|
-
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
372
|
+
setPrimary500(colorset: PaletteItem) {
|
|
373
|
+
if (colorset && colorset[modes.light as keyof PaletteItem] && colorset[modes.dark as keyof PaletteItem]) {
|
|
372
374
|
this.primary500 = colorset;
|
|
373
375
|
}
|
|
374
376
|
}
|
|
375
377
|
|
|
376
|
-
setError(colorset) {
|
|
377
|
-
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
378
|
+
setError(colorset: PaletteItem) {
|
|
379
|
+
if (colorset && colorset[modes.light as keyof PaletteItem] && colorset[modes.dark as keyof PaletteItem]) {
|
|
378
380
|
this.error = colorset;
|
|
379
381
|
}
|
|
380
382
|
}
|
|
381
383
|
|
|
382
|
-
setAccent(colorset) {
|
|
384
|
+
setAccent(colorset: { [x: string]: any; light: any; dark: any; }) {
|
|
383
385
|
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
384
386
|
this.setAccent900({
|
|
385
387
|
[modes.light]: colorset[modes.dark],
|
|
@@ -487,7 +489,7 @@ class Palette {
|
|
|
487
489
|
}
|
|
488
490
|
}
|
|
489
491
|
|
|
490
|
-
setAccent50(colorset) {
|
|
492
|
+
setAccent50(colorset: any) {
|
|
491
493
|
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
492
494
|
this.accent50 = new PaletteItem({
|
|
493
495
|
[modes.light]: colorset[modes.light],
|
|
@@ -496,7 +498,7 @@ class Palette {
|
|
|
496
498
|
}
|
|
497
499
|
}
|
|
498
500
|
|
|
499
|
-
setAccent100(colorset) {
|
|
501
|
+
setAccent100(colorset: any) {
|
|
500
502
|
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
501
503
|
this.accent100 = new PaletteItem({
|
|
502
504
|
[modes.light]: colorset[modes.light],
|
|
@@ -505,7 +507,7 @@ class Palette {
|
|
|
505
507
|
}
|
|
506
508
|
}
|
|
507
509
|
|
|
508
|
-
setAccent200(colorset) {
|
|
510
|
+
setAccent200(colorset: any) {
|
|
509
511
|
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
510
512
|
this.accent200 = new PaletteItem({
|
|
511
513
|
[modes.light]: colorset[modes.light],
|
|
@@ -514,7 +516,7 @@ class Palette {
|
|
|
514
516
|
}
|
|
515
517
|
}
|
|
516
518
|
|
|
517
|
-
setAccent300(colorset) {
|
|
519
|
+
setAccent300(colorset: any) {
|
|
518
520
|
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
519
521
|
this.accent300 = new PaletteItem({
|
|
520
522
|
[modes.light]: colorset[modes.light],
|
|
@@ -523,7 +525,7 @@ class Palette {
|
|
|
523
525
|
}
|
|
524
526
|
}
|
|
525
527
|
|
|
526
|
-
setAccent400(colorset) {
|
|
528
|
+
setAccent400(colorset: any) {
|
|
527
529
|
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
528
530
|
this.accent400 = new PaletteItem({
|
|
529
531
|
[modes.light]: colorset[modes.light],
|
|
@@ -532,7 +534,7 @@ class Palette {
|
|
|
532
534
|
}
|
|
533
535
|
}
|
|
534
536
|
|
|
535
|
-
setAccent500(colorset) {
|
|
537
|
+
setAccent500(colorset: any) {
|
|
536
538
|
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
537
539
|
this.accent500 = new PaletteItem({
|
|
538
540
|
[modes.light]: colorset[modes.light],
|
|
@@ -541,7 +543,7 @@ class Palette {
|
|
|
541
543
|
}
|
|
542
544
|
}
|
|
543
545
|
|
|
544
|
-
setAccent600(colorset) {
|
|
546
|
+
setAccent600(colorset: any) {
|
|
545
547
|
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
546
548
|
this.accent600 = new PaletteItem({
|
|
547
549
|
[modes.light]: colorset[modes.light],
|
|
@@ -550,7 +552,7 @@ class Palette {
|
|
|
550
552
|
}
|
|
551
553
|
}
|
|
552
554
|
|
|
553
|
-
setAccent700(colorset) {
|
|
555
|
+
setAccent700(colorset: any) {
|
|
554
556
|
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
555
557
|
this.accent700 = new PaletteItem({
|
|
556
558
|
[modes.light]: colorset[modes.light],
|
|
@@ -559,7 +561,7 @@ class Palette {
|
|
|
559
561
|
}
|
|
560
562
|
}
|
|
561
563
|
|
|
562
|
-
setAccent800(colorset) {
|
|
564
|
+
setAccent800(colorset: any) {
|
|
563
565
|
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
564
566
|
this.accent800 = new PaletteItem({
|
|
565
567
|
[modes.light]: colorset[modes.light],
|
|
@@ -568,7 +570,7 @@ class Palette {
|
|
|
568
570
|
}
|
|
569
571
|
}
|
|
570
572
|
|
|
571
|
-
setAccent900(colorset) {
|
|
573
|
+
setAccent900(colorset: any) {
|
|
572
574
|
if (colorset && colorset[modes.light] && colorset[modes.dark]) {
|
|
573
575
|
this.accent900 = new PaletteItem({
|
|
574
576
|
[modes.light]: colorset[modes.light],
|
|
@@ -30,11 +30,11 @@ import { FontStyle } from "../../../shared/base";
|
|
|
30
30
|
*/
|
|
31
31
|
|
|
32
32
|
class Typography {
|
|
33
|
-
fontFamily
|
|
34
|
-
fontWeightRegular: "400"
|
|
35
|
-
fontWeightMedium: "500"
|
|
36
|
-
fontWeightSemibold: "600"
|
|
37
|
-
fontWeightBold: "700"
|
|
33
|
+
fontFamily: any
|
|
34
|
+
fontWeightRegular: string | "400"
|
|
35
|
+
fontWeightMedium: string | "500"
|
|
36
|
+
fontWeightSemibold: string | "600"
|
|
37
|
+
fontWeightBold: string | "700"
|
|
38
38
|
heading: FontStyle
|
|
39
39
|
heading2: FontStyle
|
|
40
40
|
heading3: FontStyle
|
|
@@ -165,7 +165,7 @@ class Typography {
|
|
|
165
165
|
fontWeight: fontWeightRegular,
|
|
166
166
|
fontSize: 17,
|
|
167
167
|
}),
|
|
168
|
-
}) {
|
|
168
|
+
}: any) {
|
|
169
169
|
this.fontFamily = fontFamily;
|
|
170
170
|
this.fontWeightRegular = fontWeightRegular;
|
|
171
171
|
this.fontWeightMedium = fontWeightMedium;
|
|
@@ -190,29 +190,29 @@ class Typography {
|
|
|
190
190
|
this.caption2 = new FontStyle(caption2);
|
|
191
191
|
this.caption3 = new FontStyle(caption3);
|
|
192
192
|
this.body = new FontStyle(body);
|
|
193
|
-
}
|
|
193
|
+
}
|
|
194
194
|
|
|
195
|
-
setFontFamily(fontFamily) {
|
|
195
|
+
setFontFamily(fontFamily: any[]) {
|
|
196
196
|
this.fontFamily = fontFamily.join(',');
|
|
197
197
|
}
|
|
198
198
|
|
|
199
|
-
setFontWeightRegular(fontWeightRegular) {
|
|
199
|
+
setFontWeightRegular(fontWeightRegular: string) {
|
|
200
200
|
this.fontWeightRegular = fontWeightRegular;
|
|
201
201
|
}
|
|
202
202
|
|
|
203
|
-
setFontWeightMedium(fontWeightMedium) {
|
|
203
|
+
setFontWeightMedium(fontWeightMedium: string) {
|
|
204
204
|
this.fontWeightMedium = fontWeightMedium;
|
|
205
205
|
}
|
|
206
206
|
|
|
207
|
-
setFontWeightSemibold(fontWeightSemibold) {
|
|
207
|
+
setFontWeightSemibold(fontWeightSemibold: string) {
|
|
208
208
|
this.fontWeightSemibold = fontWeightSemibold;
|
|
209
209
|
}
|
|
210
210
|
|
|
211
|
-
setFontWeightBold(fontWeightBold) {
|
|
211
|
+
setFontWeightBold(fontWeightBold: string) {
|
|
212
212
|
this.fontWeightBold = fontWeightBold;
|
|
213
213
|
}
|
|
214
214
|
|
|
215
|
-
setHeading(headingFont) {
|
|
215
|
+
setHeading(headingFont: any) {
|
|
216
216
|
if (headingFont && headingFont.fontSize) {
|
|
217
217
|
this.heading.fontSize = headingFont.fontSize;
|
|
218
218
|
}
|
|
@@ -222,7 +222,7 @@ class Typography {
|
|
|
222
222
|
}
|
|
223
223
|
}
|
|
224
224
|
|
|
225
|
-
setHeading2(headingFont) {
|
|
225
|
+
setHeading2(headingFont: any) {
|
|
226
226
|
if (headingFont && headingFont.fontSize) {
|
|
227
227
|
this.heading2.fontSize = headingFont.fontSize;
|
|
228
228
|
}
|
|
@@ -232,7 +232,7 @@ class Typography {
|
|
|
232
232
|
}
|
|
233
233
|
}
|
|
234
234
|
|
|
235
|
-
setHeading3(headingFont) {
|
|
235
|
+
setHeading3(headingFont: any) {
|
|
236
236
|
if (headingFont && headingFont.fontSize) {
|
|
237
237
|
this.heading3.fontSize = headingFont.fontSize;
|
|
238
238
|
}
|
|
@@ -242,7 +242,7 @@ class Typography {
|
|
|
242
242
|
}
|
|
243
243
|
}
|
|
244
244
|
|
|
245
|
-
setName(nameFont) {
|
|
245
|
+
setName(nameFont: any) {
|
|
246
246
|
if (nameFont && nameFont.fontSize) {
|
|
247
247
|
this.name.fontSize = nameFont.fontSize;
|
|
248
248
|
}
|
|
@@ -252,7 +252,7 @@ class Typography {
|
|
|
252
252
|
}
|
|
253
253
|
}
|
|
254
254
|
|
|
255
|
-
setTitle1(titleFont) {
|
|
255
|
+
setTitle1(titleFont: any) {
|
|
256
256
|
if (titleFont && titleFont.fontSize) {
|
|
257
257
|
this.title1.fontSize = titleFont.fontSize;
|
|
258
258
|
}
|
|
@@ -262,7 +262,7 @@ class Typography {
|
|
|
262
262
|
}
|
|
263
263
|
}
|
|
264
264
|
|
|
265
|
-
setTitle2(titleFont) {
|
|
265
|
+
setTitle2(titleFont: any) {
|
|
266
266
|
if (titleFont && titleFont.fontSize) {
|
|
267
267
|
this.title2.fontSize = titleFont.fontSize;
|
|
268
268
|
}
|
|
@@ -272,7 +272,7 @@ class Typography {
|
|
|
272
272
|
}
|
|
273
273
|
}
|
|
274
274
|
|
|
275
|
-
setSubtitle1(subtitleFont) {
|
|
275
|
+
setSubtitle1(subtitleFont: any) {
|
|
276
276
|
if (subtitleFont && subtitleFont.fontSize) {
|
|
277
277
|
this.subtitle1.fontSize = subtitleFont.fontSize;
|
|
278
278
|
}
|
|
@@ -282,7 +282,7 @@ class Typography {
|
|
|
282
282
|
}
|
|
283
283
|
}
|
|
284
284
|
|
|
285
|
-
setSubtitle2(subtitleFont) {
|
|
285
|
+
setSubtitle2(subtitleFont: any) {
|
|
286
286
|
if (subtitleFont && subtitleFont.fontSize) {
|
|
287
287
|
this.subtitle2.fontSize = subtitleFont.fontSize;
|
|
288
288
|
}
|
|
@@ -292,7 +292,7 @@ class Typography {
|
|
|
292
292
|
}
|
|
293
293
|
}
|
|
294
294
|
|
|
295
|
-
setSubtitle3(subtitleFont) {
|
|
295
|
+
setSubtitle3(subtitleFont: any) {
|
|
296
296
|
if (subtitleFont && subtitleFont.fontSize) {
|
|
297
297
|
this.subtitle3.fontSize = subtitleFont.fontSize;
|
|
298
298
|
}
|
|
@@ -302,7 +302,7 @@ class Typography {
|
|
|
302
302
|
}
|
|
303
303
|
}
|
|
304
304
|
|
|
305
|
-
setSubtitle4(subtitleFont) {
|
|
305
|
+
setSubtitle4(subtitleFont: any) {
|
|
306
306
|
if (subtitleFont && subtitleFont.fontSize) {
|
|
307
307
|
this.subtitle4.fontSize = subtitleFont.fontSize;
|
|
308
308
|
}
|
|
@@ -312,7 +312,7 @@ class Typography {
|
|
|
312
312
|
}
|
|
313
313
|
}
|
|
314
314
|
|
|
315
|
-
setSubtitle5(subtitleFont) {
|
|
315
|
+
setSubtitle5(subtitleFont: any) {
|
|
316
316
|
if (subtitleFont && subtitleFont.fontSize) {
|
|
317
317
|
this.subtitle5.fontSize = subtitleFont.fontSize;
|
|
318
318
|
}
|
|
@@ -322,7 +322,7 @@ class Typography {
|
|
|
322
322
|
}
|
|
323
323
|
}
|
|
324
324
|
|
|
325
|
-
setSubtitle6(subtitleFont) {
|
|
325
|
+
setSubtitle6(subtitleFont: any) {
|
|
326
326
|
if (subtitleFont && subtitleFont.fontSize) {
|
|
327
327
|
this.subtitle6.fontSize = subtitleFont.fontSize;
|
|
328
328
|
}
|
|
@@ -332,7 +332,7 @@ class Typography {
|
|
|
332
332
|
}
|
|
333
333
|
}
|
|
334
334
|
|
|
335
|
-
setText1(textFont) {
|
|
335
|
+
setText1(textFont: any) {
|
|
336
336
|
if (textFont && textFont.fontSize) {
|
|
337
337
|
this.text1.fontSize = textFont.fontSize;
|
|
338
338
|
}
|
|
@@ -342,7 +342,7 @@ class Typography {
|
|
|
342
342
|
}
|
|
343
343
|
}
|
|
344
344
|
|
|
345
|
-
setText2(textFont) {
|
|
345
|
+
setText2(textFont: any) {
|
|
346
346
|
if (textFont && textFont.fontSize) {
|
|
347
347
|
this.text2.fontSize = textFont.fontSize;
|
|
348
348
|
}
|
|
@@ -352,7 +352,7 @@ class Typography {
|
|
|
352
352
|
}
|
|
353
353
|
}
|
|
354
354
|
|
|
355
|
-
setCaption1(captionFont) {
|
|
355
|
+
setCaption1(captionFont: any) {
|
|
356
356
|
if (captionFont && captionFont.fontSize) {
|
|
357
357
|
this.caption1.fontSize = captionFont.fontSize;
|
|
358
358
|
}
|
|
@@ -362,7 +362,7 @@ class Typography {
|
|
|
362
362
|
}
|
|
363
363
|
}
|
|
364
364
|
|
|
365
|
-
setCaption2(captionFont) {
|
|
365
|
+
setCaption2(captionFont: any) {
|
|
366
366
|
if (captionFont && captionFont.fontSize) {
|
|
367
367
|
this.caption2.fontSize = captionFont.fontSize;
|
|
368
368
|
}
|
|
@@ -372,7 +372,7 @@ class Typography {
|
|
|
372
372
|
}
|
|
373
373
|
}
|
|
374
374
|
|
|
375
|
-
setCaption3(captionFont) {
|
|
375
|
+
setCaption3(captionFont: any) {
|
|
376
376
|
if (captionFont && captionFont.fontSize) {
|
|
377
377
|
this.caption3.fontSize = captionFont.fontSize;
|
|
378
378
|
}
|
|
@@ -382,7 +382,7 @@ class Typography {
|
|
|
382
382
|
}
|
|
383
383
|
}
|
|
384
384
|
|
|
385
|
-
setBody(bodyFont) {
|
|
385
|
+
setBody(bodyFont: any) {
|
|
386
386
|
if (bodyFont && bodyFont.fontSize) {
|
|
387
387
|
this.body.fontSize = bodyFont.fontSize;
|
|
388
388
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { View, Animated, Dimensions, Easing, SafeAreaView } from "react-native";
|
|
3
3
|
import { Style } from "./style";
|
|
4
|
+
//@ts-ignore
|
|
4
5
|
import heart from "./resources/heart.png";
|
|
5
6
|
import { LiveReactionStyles, LiveReactionStylesInterface } from "./LiveReactionstyles";
|
|
6
7
|
import { ImageType } from "../../base";
|
|
@@ -64,19 +65,22 @@ const AnimteReaction = ({ left = 0, timeout = 0, onComplete = () => { }, reactio
|
|
|
64
65
|
left,
|
|
65
66
|
...style
|
|
66
67
|
}}>
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
68
|
+
{
|
|
69
|
+
//@ts-ignore
|
|
70
|
+
<Animated.Image
|
|
71
|
+
source={reactionIcon}
|
|
72
|
+
style={{
|
|
73
|
+
resizeMode: 'contain',
|
|
74
|
+
height: 25,
|
|
75
|
+
width: 25,
|
|
76
|
+
opacity: opacity,
|
|
77
|
+
transform: [
|
|
78
|
+
{ translateX: signWave },
|
|
79
|
+
{ translateY: signWaveY }
|
|
80
|
+
]
|
|
81
|
+
}}>
|
|
82
|
+
</Animated.Image>
|
|
83
|
+
}
|
|
80
84
|
</View>
|
|
81
85
|
)
|
|
82
86
|
}
|
|
@@ -6,7 +6,7 @@ const wordBoundary = {
|
|
|
6
6
|
end: `(?=$|:|;|'|"|,|{|}|\\.|\\s|\\!|\\?|\\(|\\)|\\[|\\]|\\*)`,
|
|
7
7
|
};
|
|
8
8
|
|
|
9
|
-
export const makeExtentionCall = (extentionType, callMethod, extentionAction, parameters) => {
|
|
9
|
+
export const makeExtentionCall = (extentionType: string, callMethod: string, extentionAction: string, parameters: any) => {
|
|
10
10
|
return CometChat.callExtension(extentionType, callMethod, extentionAction, parameters);
|
|
11
11
|
}
|
|
12
12
|
|
|
@@ -46,7 +46,7 @@ export const getUnixTimestampInMilliseconds = () => {
|
|
|
46
46
|
return Math.round(+new Date());
|
|
47
47
|
}
|
|
48
48
|
|
|
49
|
-
export const formatBytes = (bytes, decimals = 2) => {
|
|
49
|
+
export const formatBytes = (bytes: number, decimals = 2) => {
|
|
50
50
|
if (bytes === 0) return "0 Bytes";
|
|
51
51
|
|
|
52
52
|
const k = 1024;
|
|
@@ -1,5 +1,8 @@
|
|
|
1
|
+
//@ts-ignore
|
|
1
2
|
import { CometChatMessagePreview } from "./CometChatMessagePreview";
|
|
3
|
+
//@ts-ignore
|
|
2
4
|
import { MessagePreviewConfiguration } from './MessagePreviewConfiguration';
|
|
5
|
+
//@ts-ignore
|
|
3
6
|
import { MessagePreviewStyle } from "./MessagePreviewStyle";
|
|
4
7
|
|
|
5
8
|
export { CometChatMessagePreview, MessagePreviewConfiguration, MessagePreviewStyle }
|