@planningcenter/chat-react-native 3.42.2-qa-staging.2 → 3.42.2-qa-821.1
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/build/components/conversation/attachments/attachment_card.d.ts +3 -3
- package/build/components/conversation/attachments/attachment_card.d.ts.map +1 -1
- package/build/components/conversation/attachments/attachment_card.js +3 -7
- package/build/components/conversation/attachments/attachment_card.js.map +1 -1
- package/build/components/conversation/attachments/attachment_deleting_overlay.d.ts +1 -2
- package/build/components/conversation/attachments/attachment_deleting_overlay.d.ts.map +1 -1
- package/build/components/conversation/attachments/attachment_deleting_overlay.js +12 -7
- package/build/components/conversation/attachments/attachment_deleting_overlay.js.map +1 -1
- package/build/components/conversation/attachments/audio_attachment.d.ts +1 -2
- package/build/components/conversation/attachments/audio_attachment.d.ts.map +1 -1
- package/build/components/conversation/attachments/audio_attachment.js +6 -23
- package/build/components/conversation/attachments/audio_attachment.js.map +1 -1
- package/build/components/conversation/attachments/expanded_link.d.ts +1 -2
- package/build/components/conversation/attachments/expanded_link.d.ts.map +1 -1
- package/build/components/conversation/attachments/expanded_link.js +2 -8
- package/build/components/conversation/attachments/expanded_link.js.map +1 -1
- package/build/components/conversation/attachments/generic_file_attachment.d.ts +1 -2
- package/build/components/conversation/attachments/generic_file_attachment.d.ts.map +1 -1
- package/build/components/conversation/attachments/generic_file_attachment.js +2 -12
- package/build/components/conversation/attachments/generic_file_attachment.js.map +1 -1
- package/build/components/conversation/attachments/giphy_attachment.d.ts +1 -2
- package/build/components/conversation/attachments/giphy_attachment.d.ts.map +1 -1
- package/build/components/conversation/attachments/giphy_attachment.js +2 -7
- package/build/components/conversation/attachments/giphy_attachment.js.map +1 -1
- package/build/components/conversation/attachments/image_attachment.d.ts +1 -2
- package/build/components/conversation/attachments/image_attachment.d.ts.map +1 -1
- package/build/components/conversation/attachments/image_attachment.js +16 -53
- package/build/components/conversation/attachments/image_attachment.js.map +1 -1
- package/build/components/conversation/attachments/video_attachment.d.ts +1 -2
- package/build/components/conversation/attachments/video_attachment.d.ts.map +1 -1
- package/build/components/conversation/attachments/video_attachment.js +3 -13
- package/build/components/conversation/attachments/video_attachment.js.map +1 -1
- package/build/components/conversation/conversation_start_banner.d.ts +1 -2
- package/build/components/conversation/conversation_start_banner.d.ts.map +1 -1
- package/build/components/conversation/conversation_start_banner.js +2 -14
- package/build/components/conversation/conversation_start_banner.js.map +1 -1
- package/build/components/conversation/empty_conversation_blank_state.d.ts +1 -1
- package/build/components/conversation/empty_conversation_blank_state.d.ts.map +1 -1
- package/build/components/conversation/empty_conversation_blank_state.js +2 -9
- package/build/components/conversation/empty_conversation_blank_state.js.map +1 -1
- package/build/components/conversation/jump_to_bottom_button.d.ts +1 -1
- package/build/components/conversation/jump_to_bottom_button.d.ts.map +1 -1
- package/build/components/conversation/jump_to_bottom_button.js +2 -10
- package/build/components/conversation/jump_to_bottom_button.js.map +1 -1
- package/build/components/conversation/message.d.ts +1 -2
- package/build/components/conversation/message.d.ts.map +1 -1
- package/build/components/conversation/message.js +2 -53
- package/build/components/conversation/message.js.map +1 -1
- package/build/components/conversation/message_attachments.d.ts +1 -2
- package/build/components/conversation/message_attachments.d.ts.map +1 -1
- package/build/components/conversation/message_attachments.js +17 -21
- package/build/components/conversation/message_attachments.js.map +1 -1
- package/build/components/conversation/message_form/message_form_attachment_file.d.ts +1 -2
- package/build/components/conversation/message_form/message_form_attachment_file.d.ts.map +1 -1
- package/build/components/conversation/message_form/message_form_attachment_file.js +2 -2
- package/build/components/conversation/message_form/message_form_attachment_file.js.map +1 -1
- package/build/components/conversation/message_form/message_form_attachment_image.d.ts +1 -2
- package/build/components/conversation/message_form/message_form_attachment_image.d.ts.map +1 -1
- package/build/components/conversation/message_form/message_form_attachment_image.js +2 -2
- package/build/components/conversation/message_form/message_form_attachment_image.js.map +1 -1
- package/build/components/conversation/message_form/message_form_attachment_video.d.ts +1 -2
- package/build/components/conversation/message_form/message_form_attachment_video.d.ts.map +1 -1
- package/build/components/conversation/message_form/message_form_attachment_video.js +2 -2
- package/build/components/conversation/message_form/message_form_attachment_video.js.map +1 -1
- package/build/components/conversation/message_form.d.ts +5 -6
- package/build/components/conversation/message_form.d.ts.map +1 -1
- package/build/components/conversation/message_form.js +20 -82
- package/build/components/conversation/message_form.js.map +1 -1
- package/build/components/conversation/message_markdown.d.ts +1 -2
- package/build/components/conversation/message_markdown.d.ts.map +1 -1
- package/build/components/conversation/message_markdown.js +8 -16
- package/build/components/conversation/message_markdown.js.map +1 -1
- package/build/components/conversation/message_reaction.d.ts +1 -2
- package/build/components/conversation/message_reaction.d.ts.map +1 -1
- package/build/components/conversation/message_reaction.js +3 -5
- package/build/components/conversation/message_reaction.js.map +1 -1
- package/build/components/conversation/message_read_receipts.d.ts +1 -2
- package/build/components/conversation/message_read_receipts.d.ts.map +1 -1
- package/build/components/conversation/message_read_receipts.js +3 -13
- package/build/components/conversation/message_read_receipts.js.map +1 -1
- package/build/components/conversation/messages_disabled_banners.d.ts +3 -3
- package/build/components/conversation/messages_disabled_banners.d.ts.map +1 -1
- package/build/components/conversation/messages_disabled_banners.js +5 -8
- package/build/components/conversation/messages_disabled_banners.js.map +1 -1
- package/build/components/conversation/reply_connectors.d.ts +2 -2
- package/build/components/conversation/reply_connectors.d.ts.map +1 -1
- package/build/components/conversation/reply_connectors.js +18 -50
- package/build/components/conversation/reply_connectors.js.map +1 -1
- package/build/components/conversation/reply_shadow_message.d.ts +1 -2
- package/build/components/conversation/reply_shadow_message.d.ts.map +1 -1
- package/build/components/conversation/reply_shadow_message.js +16 -46
- package/build/components/conversation/reply_shadow_message.js.map +1 -1
- package/build/components/conversation/system_message.d.ts +1 -2
- package/build/components/conversation/system_message.d.ts.map +1 -1
- package/build/components/conversation/system_message.js +3 -12
- package/build/components/conversation/system_message.js.map +1 -1
- package/build/components/conversation/typing_indicator.d.ts +1 -2
- package/build/components/conversation/typing_indicator.d.ts.map +1 -1
- package/build/components/conversation/typing_indicator.js +3 -13
- package/build/components/conversation/typing_indicator.js.map +1 -1
- package/build/components/conversations/conversation_actions.d.ts +2 -2
- package/build/components/conversations/conversation_actions.d.ts.map +1 -1
- package/build/components/conversations/conversation_actions.js +4 -10
- package/build/components/conversations/conversation_actions.js.map +1 -1
- package/build/components/conversations/conversation_preview.d.ts +2 -3
- package/build/components/conversations/conversation_preview.d.ts.map +1 -1
- package/build/components/conversations/conversation_preview.js +12 -76
- package/build/components/conversations/conversation_preview.js.map +1 -1
- package/build/components/conversations/conversations.d.ts +1 -1
- package/build/components/conversations/conversations.d.ts.map +1 -1
- package/build/components/conversations/conversations.js +16 -17
- package/build/components/conversations/conversations.js.map +1 -1
- package/build/components/conversations/conversations_blank_state.d.ts +1 -2
- package/build/components/conversations/conversations_blank_state.d.ts.map +1 -1
- package/build/components/conversations/conversations_blank_state.js +2 -12
- package/build/components/conversations/conversations_blank_state.js.map +1 -1
- package/build/components/conversations/mute_indicator.d.ts +1 -2
- package/build/components/conversations/mute_indicator.d.ts.map +1 -1
- package/build/components/conversations/mute_indicator.js +2 -2
- package/build/components/conversations/mute_indicator.js.map +1 -1
- package/build/components/conversations/swipeable_toggle_button.d.ts +1 -2
- package/build/components/conversations/swipeable_toggle_button.d.ts.map +1 -1
- package/build/components/conversations/swipeable_toggle_button.js +3 -10
- package/build/components/conversations/swipeable_toggle_button.js.map +1 -1
- package/build/components/conversations/unread_count_badge.d.ts +2 -4
- package/build/components/conversations/unread_count_badge.d.ts.map +1 -1
- package/build/components/conversations/unread_count_badge.js +7 -12
- package/build/components/conversations/unread_count_badge.js.map +1 -1
- package/build/components/display/action_button.d.ts +1 -1
- package/build/components/display/action_button.d.ts.map +1 -1
- package/build/components/display/action_button.js +3 -13
- package/build/components/display/action_button.js.map +1 -1
- package/build/components/display/adult_requirement_notice.d.ts +1 -2
- package/build/components/display/adult_requirement_notice.d.ts.map +1 -1
- package/build/components/display/adult_requirement_notice.js +2 -4
- package/build/components/display/adult_requirement_notice.js.map +1 -1
- package/build/components/display/avatar.d.ts +1 -2
- package/build/components/display/avatar.d.ts.map +1 -1
- package/build/components/display/avatar.js +2 -7
- package/build/components/display/avatar.js.map +1 -1
- package/build/components/display/avatar_group.d.ts +1 -2
- package/build/components/display/avatar_group.d.ts.map +1 -1
- package/build/components/display/avatar_group.js +2 -9
- package/build/components/display/avatar_group.js.map +1 -1
- package/build/components/display/badge.d.ts +1 -2
- package/build/components/display/badge.d.ts.map +1 -1
- package/build/components/display/badge.js +6 -37
- package/build/components/display/badge.js.map +1 -1
- package/build/components/display/banner.d.ts +3 -3
- package/build/components/display/banner.d.ts.map +1 -1
- package/build/components/display/banner.js +4 -11
- package/build/components/display/banner.js.map +1 -1
- package/build/components/display/banner_collapsible.d.ts +2 -2
- package/build/components/display/banner_collapsible.d.ts.map +1 -1
- package/build/components/display/banner_collapsible.js +2 -10
- package/build/components/display/banner_collapsible.js.map +1 -1
- package/build/components/display/button.d.ts +1 -2
- package/build/components/display/button.d.ts.map +1 -1
- package/build/components/display/button.js +3 -14
- package/build/components/display/button.js.map +1 -1
- package/build/components/display/child_notice.d.ts +1 -2
- package/build/components/display/child_notice.d.ts.map +1 -1
- package/build/components/display/child_notice.js +3 -15
- package/build/components/display/child_notice.js.map +1 -1
- package/build/components/display/conversation_avatar.d.ts +1 -2
- package/build/components/display/conversation_avatar.d.ts.map +1 -1
- package/build/components/display/conversation_avatar.js +5 -9
- package/build/components/display/conversation_avatar.js.map +1 -1
- package/build/components/display/emoji_avatar.d.ts +1 -2
- package/build/components/display/emoji_avatar.d.ts.map +1 -1
- package/build/components/display/emoji_avatar.js +2 -12
- package/build/components/display/emoji_avatar.js.map +1 -1
- package/build/components/display/file_attachment_preview.d.ts +1 -1
- package/build/components/display/file_attachment_preview.d.ts.map +1 -1
- package/build/components/display/file_attachment_preview.js +3 -17
- package/build/components/display/file_attachment_preview.js.map +1 -1
- package/build/components/display/heading.d.ts +1 -2
- package/build/components/display/heading.d.ts.map +1 -1
- package/build/components/display/heading.js +2 -4
- package/build/components/display/heading.js.map +1 -1
- package/build/components/display/icon.d.ts +1 -2
- package/build/components/display/icon.d.ts.map +1 -1
- package/build/components/display/icon.js +4 -4
- package/build/components/display/icon.js.map +1 -1
- package/build/components/display/icon_avatar.d.ts +1 -2
- package/build/components/display/icon_avatar.d.ts.map +1 -1
- package/build/components/display/icon_avatar.js +2 -12
- package/build/components/display/icon_avatar.js.map +1 -1
- package/build/components/display/icon_button.d.ts +1 -2
- package/build/components/display/icon_button.d.ts.map +1 -1
- package/build/components/display/icon_button.js +3 -5
- package/build/components/display/icon_button.js.map +1 -1
- package/build/components/display/image.d.ts +1 -2
- package/build/components/display/image.d.ts.map +1 -1
- package/build/components/display/image.js +3 -7
- package/build/components/display/image.js.map +1 -1
- package/build/components/display/image_attachment_preview.d.ts +1 -1
- package/build/components/display/image_attachment_preview.d.ts.map +1 -1
- package/build/components/display/image_attachment_preview.js +2 -7
- package/build/components/display/image_attachment_preview.js.map +1 -1
- package/build/components/display/keyboard_view.d.ts +1 -2
- package/build/components/display/keyboard_view.d.ts.map +1 -1
- package/build/components/display/keyboard_view.js +4 -9
- package/build/components/display/keyboard_view.js.map +1 -1
- package/build/components/display/person.d.ts +1 -2
- package/build/components/display/person.d.ts.map +1 -1
- package/build/components/display/person.js +2 -12
- package/build/components/display/person.js.map +1 -1
- package/build/components/display/platform_modal_header_buttons.d.ts +3 -3
- package/build/components/display/platform_modal_header_buttons.d.ts.map +1 -1
- package/build/components/display/platform_modal_header_buttons.js +5 -10
- package/build/components/display/platform_modal_header_buttons.js.map +1 -1
- package/build/components/display/pressable_row.d.ts +1 -1
- package/build/components/display/pressable_row.d.ts.map +1 -1
- package/build/components/display/pressable_row.js +2 -7
- package/build/components/display/pressable_row.js.map +1 -1
- package/build/components/display/spinner.d.ts +1 -2
- package/build/components/display/spinner.d.ts.map +1 -1
- package/build/components/display/spinner.js +3 -9
- package/build/components/display/spinner.js.map +1 -1
- package/build/components/display/switch.d.ts +1 -2
- package/build/components/display/switch.d.ts.map +1 -1
- package/build/components/display/switch.js +2 -2
- package/build/components/display/switch.js.map +1 -1
- package/build/components/display/tabs.d.ts +1 -1
- package/build/components/display/tabs.d.ts.map +1 -1
- package/build/components/display/tabs.js +21 -31
- package/build/components/display/tabs.js.map +1 -1
- package/build/components/display/text.d.ts +1 -2
- package/build/components/display/text.d.ts.map +1 -1
- package/build/components/display/text.js +2 -4
- package/build/components/display/text.js.map +1 -1
- package/build/components/display/text_button.d.ts +1 -2
- package/build/components/display/text_button.d.ts.map +1 -1
- package/build/components/display/text_button.js +3 -8
- package/build/components/display/text_button.js.map +1 -1
- package/build/components/display/text_inline_button.d.ts +1 -2
- package/build/components/display/text_inline_button.d.ts.map +1 -1
- package/build/components/display/text_inline_button.js +4 -5
- package/build/components/display/text_inline_button.js.map +1 -1
- package/build/components/display/text_input.d.ts +1 -1
- package/build/components/display/text_input.d.ts.map +1 -1
- package/build/components/display/text_input.js +2 -1
- package/build/components/display/text_input.js.map +1 -1
- package/build/components/display/toggle_button.d.ts +1 -2
- package/build/components/display/toggle_button.d.ts.map +1 -1
- package/build/components/display/toggle_button.js +3 -9
- package/build/components/display/toggle_button.js.map +1 -1
- package/build/components/display/video_attachment_preview.d.ts +1 -1
- package/build/components/display/video_attachment_preview.d.ts.map +1 -1
- package/build/components/display/video_attachment_preview.js +3 -20
- package/build/components/display/video_attachment_preview.js.map +1 -1
- package/build/components/group_conversation_list.d.ts +1 -1
- package/build/components/group_conversation_list.d.ts.map +1 -1
- package/build/components/group_conversation_list.js +4 -14
- package/build/components/group_conversation_list.js.map +1 -1
- package/build/components/page/component_error_boundary.d.ts +2 -2
- package/build/components/page/component_error_boundary.d.ts.map +1 -1
- package/build/components/page/component_error_boundary.js +2 -4
- package/build/components/page/component_error_boundary.js.map +1 -1
- package/build/components/page/loading.d.ts +1 -2
- package/build/components/page/loading.d.ts.map +1 -1
- package/build/components/page/loading.js +2 -4
- package/build/components/page/loading.js.map +1 -1
- package/build/components/page/page_error_boundary.d.ts +2 -2
- package/build/components/page/page_error_boundary.d.ts.map +1 -1
- package/build/components/page/page_error_boundary.js +11 -32
- package/build/components/page/page_error_boundary.js.map +1 -1
- package/build/components/primitive/avatar_primitive.js +14 -41
- package/build/components/primitive/avatar_primitive.js.map +1 -1
- package/build/components/primitive/banner_primitive.js +10 -18
- package/build/components/primitive/banner_primitive.js.map +1 -1
- package/build/components/primitive/blank_state_primitive.js +8 -12
- package/build/components/primitive/blank_state_primitive.js.map +1 -1
- package/build/components/primitive/form_sheet.d.ts +1 -1
- package/build/components/primitive/form_sheet.d.ts.map +1 -1
- package/build/components/primitive/form_sheet.js +9 -22
- package/build/components/primitive/form_sheet.js.map +1 -1
- package/build/components/safe_area_modal.d.ts +1 -1
- package/build/components/safe_area_modal.d.ts.map +1 -1
- package/build/components/safe_area_modal.js +2 -3
- package/build/components/safe_area_modal.js.map +1 -1
- package/build/contexts/api_provider.d.ts +1 -2
- package/build/contexts/api_provider.d.ts.map +1 -1
- package/build/contexts/api_provider.js +3 -5
- package/build/contexts/api_provider.js.map +1 -1
- package/build/contexts/chat_context.d.ts +1 -1
- package/build/contexts/chat_context.d.ts.map +1 -1
- package/build/contexts/chat_context.js +2 -1
- package/build/contexts/chat_context.js.map +1 -1
- package/build/contexts/conversation_context.d.ts +2 -2
- package/build/contexts/conversation_context.d.ts.map +1 -1
- package/build/contexts/conversation_context.js +3 -2
- package/build/contexts/conversation_context.js.map +1 -1
- package/build/contexts/conversations_context.d.ts +2 -2
- package/build/contexts/conversations_context.d.ts.map +1 -1
- package/build/contexts/conversations_context.js +3 -2
- package/build/contexts/conversations_context.js.map +1 -1
- package/build/contexts/session_context.d.ts +1 -1
- package/build/contexts/session_context.d.ts.map +1 -1
- package/build/contexts/session_context.js +3 -2
- package/build/contexts/session_context.js.map +1 -1
- package/build/hooks/use_animated_message_background_color.d.ts +2 -2
- package/build/hooks/use_conversation.d.ts +1 -1
- package/build/hooks/use_conversation.d.ts.map +1 -1
- package/build/hooks/use_conversation.js +0 -2
- package/build/hooks/use_conversation.js.map +1 -1
- package/build/hooks/use_conversation_jolt_events.d.ts.map +1 -1
- package/build/hooks/use_conversation_jolt_events.js +19 -4
- package/build/hooks/use_conversation_jolt_events.js.map +1 -1
- package/build/hooks/use_conversation_membership.d.ts +1 -1
- package/build/hooks/use_conversation_membership.d.ts.map +1 -1
- package/build/hooks/use_conversation_messages.d.ts +1 -0
- package/build/hooks/use_conversation_messages.d.ts.map +1 -1
- package/build/hooks/use_conversation_messages.js +2 -2
- package/build/hooks/use_conversation_messages.js.map +1 -1
- package/build/hooks/use_conversations_actions.d.ts +36 -36
- package/build/hooks/use_conversations_actions.d.ts.map +1 -1
- package/build/hooks/use_conversations_actions.js +1 -3
- package/build/hooks/use_conversations_actions.js.map +1 -1
- package/build/hooks/use_mark_latest_message_read.d.ts.map +1 -1
- package/build/hooks/use_mark_latest_message_read.js +4 -3
- package/build/hooks/use_mark_latest_message_read.js.map +1 -1
- package/build/hooks/use_person_settings.d.ts +1 -1
- package/build/index.d.ts +2 -1
- package/build/index.d.ts.map +1 -1
- package/build/index.js.map +1 -1
- package/build/navigation/chat_access_gate.d.ts +2 -2
- package/build/navigation/chat_access_gate.d.ts.map +1 -1
- package/build/navigation/chat_access_gate.js +6 -5
- package/build/navigation/chat_access_gate.js.map +1 -1
- package/build/navigation/index.d.ts +35 -36
- package/build/navigation/index.d.ts.map +1 -1
- package/build/navigation/index.js +19 -21
- package/build/navigation/index.js.map +1 -1
- package/build/navigation/screenLayout.d.ts +2 -2
- package/build/navigation/screenLayout.d.ts.map +1 -1
- package/build/navigation/screenLayout.js +3 -9
- package/build/navigation/screenLayout.js.map +1 -1
- package/build/polyfills/events/EventTarget.d.ts +1 -1
- package/build/polyfills/events/EventTarget.d.ts.map +1 -1
- package/build/polyfills/events/EventTarget.js.map +1 -1
- package/build/screens/age_check/age_check_required_screen.d.ts +1 -2
- package/build/screens/age_check/age_check_required_screen.d.ts.map +1 -1
- package/build/screens/age_check/age_check_required_screen.js +3 -46
- package/build/screens/age_check/age_check_required_screen.js.map +1 -1
- package/build/screens/age_check/age_check_underage_screen.d.ts +1 -2
- package/build/screens/age_check/age_check_underage_screen.d.ts.map +1 -1
- package/build/screens/age_check/age_check_underage_screen.js +2 -25
- package/build/screens/age_check/age_check_underage_screen.js.map +1 -1
- package/build/screens/age_check/components/age_check_select_birthdate_modal.d.ts +1 -2
- package/build/screens/age_check/components/age_check_select_birthdate_modal.d.ts.map +1 -1
- package/build/screens/age_check/components/age_check_select_birthdate_modal.js +6 -25
- package/build/screens/age_check/components/age_check_select_birthdate_modal.js.map +1 -1
- package/build/screens/attachment_actions/attachment_actions_screen.d.ts +1 -2
- package/build/screens/attachment_actions/attachment_actions_screen.d.ts.map +1 -1
- package/build/screens/attachment_actions/attachment_actions_screen.js +3 -5
- package/build/screens/attachment_actions/attachment_actions_screen.js.map +1 -1
- package/build/screens/avatar_picker/avatar_picker_screen.d.ts +1 -2
- package/build/screens/avatar_picker/avatar_picker_screen.d.ts.map +1 -1
- package/build/screens/avatar_picker/avatar_picker_screen.js +9 -36
- package/build/screens/avatar_picker/avatar_picker_screen.js.map +1 -1
- package/build/screens/avatar_picker/avatar_preview.d.ts +1 -1
- package/build/screens/avatar_picker/avatar_preview.d.ts.map +1 -1
- package/build/screens/avatar_picker/avatar_preview.js +5 -9
- package/build/screens/avatar_picker/avatar_preview.js.map +1 -1
- package/build/screens/avatar_picker/color_picker.d.ts +1 -2
- package/build/screens/avatar_picker/color_picker.d.ts.map +1 -1
- package/build/screens/avatar_picker/color_picker.js +4 -5
- package/build/screens/avatar_picker/color_picker.js.map +1 -1
- package/build/screens/avatar_picker/emoji_tab.d.ts +1 -2
- package/build/screens/avatar_picker/emoji_tab.d.ts.map +1 -1
- package/build/screens/avatar_picker/emoji_tab.js +12 -13
- package/build/screens/avatar_picker/emoji_tab.js.map +1 -1
- package/build/screens/avatar_picker/icon_grid.d.ts +1 -2
- package/build/screens/avatar_picker/icon_grid.d.ts.map +1 -1
- package/build/screens/avatar_picker/icon_grid.js +4 -5
- package/build/screens/avatar_picker/icon_grid.js.map +1 -1
- package/build/screens/avatar_picker/upload_tab.d.ts +1 -2
- package/build/screens/avatar_picker/upload_tab.d.ts.map +1 -1
- package/build/screens/avatar_picker/upload_tab.js +3 -4
- package/build/screens/avatar_picker/upload_tab.js.map +1 -1
- package/build/screens/bug_report_screen.d.ts +1 -2
- package/build/screens/bug_report_screen.d.ts.map +1 -1
- package/build/screens/bug_report_screen.js +11 -117
- package/build/screens/bug_report_screen.js.map +1 -1
- package/build/screens/conversation/message_read_receipts_screen.d.ts +1 -2
- package/build/screens/conversation/message_read_receipts_screen.d.ts.map +1 -1
- package/build/screens/conversation/message_read_receipts_screen.js +4 -20
- package/build/screens/conversation/message_read_receipts_screen.js.map +1 -1
- package/build/screens/conversation_details_screen.d.ts +1 -2
- package/build/screens/conversation_details_screen.d.ts.map +1 -1
- package/build/screens/conversation_details_screen.js +43 -106
- package/build/screens/conversation_details_screen.js.map +1 -1
- package/build/screens/conversation_filter_recipients/components/checkbox_row.d.ts +1 -1
- package/build/screens/conversation_filter_recipients/components/checkbox_row.d.ts.map +1 -1
- package/build/screens/conversation_filter_recipients/components/checkbox_row.js +3 -9
- package/build/screens/conversation_filter_recipients/components/checkbox_row.js.map +1 -1
- package/build/screens/conversation_filter_recipients/components/header_row.d.ts +1 -1
- package/build/screens/conversation_filter_recipients/components/header_row.d.ts.map +1 -1
- package/build/screens/conversation_filter_recipients/components/header_row.js +2 -12
- package/build/screens/conversation_filter_recipients/components/header_row.js.map +1 -1
- package/build/screens/conversation_filter_recipients/conversation_filter_recipients_screen.d.ts +1 -2
- package/build/screens/conversation_filter_recipients/conversation_filter_recipients_screen.d.ts.map +1 -1
- package/build/screens/conversation_filter_recipients/conversation_filter_recipients_screen.js +20 -44
- package/build/screens/conversation_filter_recipients/conversation_filter_recipients_screen.js.map +1 -1
- package/build/screens/conversation_filters/components/conversation_filters.d.ts +1 -2
- package/build/screens/conversation_filters/components/conversation_filters.d.ts.map +1 -1
- package/build/screens/conversation_filters/components/conversation_filters.js +10 -11
- package/build/screens/conversation_filters/components/conversation_filters.js.map +1 -1
- package/build/screens/conversation_filters/components/rows.d.ts +6 -6
- package/build/screens/conversation_filters/components/rows.d.ts.map +1 -1
- package/build/screens/conversation_filters/components/rows.js +7 -34
- package/build/screens/conversation_filters/components/rows.js.map +1 -1
- package/build/screens/conversation_filters/context/conversation_filter_context.d.ts +1 -1
- package/build/screens/conversation_filters/context/conversation_filter_context.d.ts.map +1 -1
- package/build/screens/conversation_filters/context/conversation_filter_context.js +2 -1
- package/build/screens/conversation_filters/context/conversation_filter_context.js.map +1 -1
- package/build/screens/conversation_filters/group_filters.d.ts +1 -2
- package/build/screens/conversation_filters/group_filters.d.ts.map +1 -1
- package/build/screens/conversation_filters/group_filters.js +2 -2
- package/build/screens/conversation_filters/group_filters.js.map +1 -1
- package/build/screens/conversation_filters/team_filters.d.ts +1 -2
- package/build/screens/conversation_filters/team_filters.d.ts.map +1 -1
- package/build/screens/conversation_filters/team_filters.js +2 -2
- package/build/screens/conversation_filters/team_filters.js.map +1 -1
- package/build/screens/conversation_filters_screen.d.ts +1 -2
- package/build/screens/conversation_filters_screen.d.ts.map +1 -1
- package/build/screens/conversation_filters_screen.js +4 -16
- package/build/screens/conversation_filters_screen.js.map +1 -1
- package/build/screens/conversation_new/components/avatar_selection_row.d.ts +2 -3
- package/build/screens/conversation_new/components/avatar_selection_row.d.ts.map +1 -1
- package/build/screens/conversation_new/components/avatar_selection_row.js +6 -16
- package/build/screens/conversation_new/components/avatar_selection_row.js.map +1 -1
- package/build/screens/conversation_new/components/filter_by_plan.d.ts +3 -4
- package/build/screens/conversation_new/components/filter_by_plan.d.ts.map +1 -1
- package/build/screens/conversation_new/components/filter_by_plan.js +22 -46
- package/build/screens/conversation_new/components/filter_by_plan.js.map +1 -1
- package/build/screens/conversation_new/components/form_list.d.ts +2 -3
- package/build/screens/conversation_new/components/form_list.d.ts.map +1 -1
- package/build/screens/conversation_new/components/form_list.js +4 -6
- package/build/screens/conversation_new/components/form_list.js.map +1 -1
- package/build/screens/conversation_new/components/gender_filter_toggle.d.ts +1 -2
- package/build/screens/conversation_new/components/gender_filter_toggle.d.ts.map +1 -1
- package/build/screens/conversation_new/components/gender_filter_toggle.js +4 -20
- package/build/screens/conversation_new/components/gender_filter_toggle.js.map +1 -1
- package/build/screens/conversation_new/components/groups_form.d.ts +1 -2
- package/build/screens/conversation_new/components/groups_form.d.ts.map +1 -1
- package/build/screens/conversation_new/components/groups_form.js +4 -30
- package/build/screens/conversation_new/components/groups_form.js.map +1 -1
- package/build/screens/conversation_new/components/services_form.d.ts +1 -2
- package/build/screens/conversation_new/components/services_form.d.ts.map +1 -1
- package/build/screens/conversation_new/components/services_form.js +27 -61
- package/build/screens/conversation_new/components/services_form.js.map +1 -1
- package/build/screens/conversation_new/components/source_app_error_card.d.ts +1 -1
- package/build/screens/conversation_new/components/source_app_error_card.d.ts.map +1 -1
- package/build/screens/conversation_new/components/source_app_error_card.js +2 -3
- package/build/screens/conversation_new/components/source_app_error_card.js.map +1 -1
- package/build/screens/conversation_new/conversation_new_screen.d.ts +1 -2
- package/build/screens/conversation_new/conversation_new_screen.d.ts.map +1 -1
- package/build/screens/conversation_new/conversation_new_screen.js +4 -4
- package/build/screens/conversation_new/conversation_new_screen.js.map +1 -1
- package/build/screens/conversation_notification_level_select_screen.d.ts +1 -2
- package/build/screens/conversation_notification_level_select_screen.d.ts.map +1 -1
- package/build/screens/conversation_notification_level_select_screen.js +4 -6
- package/build/screens/conversation_notification_level_select_screen.js.map +1 -1
- package/build/screens/conversation_screen.d.ts +2 -3
- package/build/screens/conversation_screen.d.ts.map +1 -1
- package/build/screens/conversation_screen.js +25 -66
- package/build/screens/conversation_screen.js.map +1 -1
- package/build/screens/conversation_select_recipients/components/groups_recipient_row.d.ts +1 -1
- package/build/screens/conversation_select_recipients/components/groups_recipient_row.d.ts.map +1 -1
- package/build/screens/conversation_select_recipients/components/groups_recipient_row.js +2 -1
- package/build/screens/conversation_select_recipients/components/groups_recipient_row.js.map +1 -1
- package/build/screens/conversation_select_recipients/components/recipient_link_row.d.ts +1 -2
- package/build/screens/conversation_select_recipients/components/recipient_link_row.d.ts.map +1 -1
- package/build/screens/conversation_select_recipients/components/recipient_link_row.js +2 -15
- package/build/screens/conversation_select_recipients/components/recipient_link_row.js.map +1 -1
- package/build/screens/conversation_select_recipients/components/restricted_group_row.d.ts +1 -2
- package/build/screens/conversation_select_recipients/components/restricted_group_row.d.ts.map +1 -1
- package/build/screens/conversation_select_recipients/components/restricted_group_row.js +2 -14
- package/build/screens/conversation_select_recipients/components/restricted_group_row.js.map +1 -1
- package/build/screens/conversation_select_recipients/components/team_recipient_row.d.ts +1 -1
- package/build/screens/conversation_select_recipients/components/team_recipient_row.d.ts.map +1 -1
- package/build/screens/conversation_select_recipients/components/team_recipient_row.js +2 -1
- package/build/screens/conversation_select_recipients/components/team_recipient_row.js.map +1 -1
- package/build/screens/conversation_select_recipients/components/view_more_link_row.d.ts +1 -1
- package/build/screens/conversation_select_recipients/components/view_more_link_row.d.ts.map +1 -1
- package/build/screens/conversation_select_recipients/components/view_more_link_row.js +2 -5
- package/build/screens/conversation_select_recipients/components/view_more_link_row.js.map +1 -1
- package/build/screens/conversation_select_recipients/conversation_new_entry_screen.d.ts +1 -2
- package/build/screens/conversation_select_recipients/conversation_new_entry_screen.d.ts.map +1 -1
- package/build/screens/conversation_select_recipients/conversation_new_entry_screen.js +4 -11
- package/build/screens/conversation_select_recipients/conversation_new_entry_screen.js.map +1 -1
- package/build/screens/conversation_select_recipients/conversation_select_direct_message_recipients_screen.d.ts +1 -1
- package/build/screens/conversation_select_recipients/conversation_select_direct_message_recipients_screen.d.ts.map +1 -1
- package/build/screens/conversation_select_recipients/conversation_select_direct_message_recipients_screen.js +11 -83
- package/build/screens/conversation_select_recipients/conversation_select_direct_message_recipients_screen.js.map +1 -1
- package/build/screens/conversation_select_recipients/conversation_select_group_recipients_screen.d.ts +1 -2
- package/build/screens/conversation_select_recipients/conversation_select_group_recipients_screen.d.ts.map +1 -1
- package/build/screens/conversation_select_recipients/conversation_select_group_recipients_screen.js +7 -14
- package/build/screens/conversation_select_recipients/conversation_select_group_recipients_screen.js.map +1 -1
- package/build/screens/conversation_select_recipients/conversation_select_teams_i_lead_recipients_screen.d.ts +1 -2
- package/build/screens/conversation_select_recipients/conversation_select_teams_i_lead_recipients_screen.d.ts.map +1 -1
- package/build/screens/conversation_select_recipients/conversation_select_teams_i_lead_recipients_screen.js +15 -18
- package/build/screens/conversation_select_recipients/conversation_select_teams_i_lead_recipients_screen.js.map +1 -1
- package/build/screens/conversation_select_type_screen.d.ts +1 -2
- package/build/screens/conversation_select_type_screen.d.ts.map +1 -1
- package/build/screens/conversation_select_type_screen.js +3 -10
- package/build/screens/conversation_select_type_screen.js.map +1 -1
- package/build/screens/conversations/components/chat_group_badge.d.ts +1 -2
- package/build/screens/conversations/components/chat_group_badge.d.ts.map +1 -1
- package/build/screens/conversations/components/chat_group_badge.js +3 -4
- package/build/screens/conversations/components/chat_group_badge.js.map +1 -1
- package/build/screens/conversations/components/list_header_action_button.d.ts +1 -2
- package/build/screens/conversations/components/list_header_action_button.d.ts.map +1 -1
- package/build/screens/conversations/components/list_header_action_button.js +3 -5
- package/build/screens/conversations/components/list_header_action_button.js.map +1 -1
- package/build/screens/conversations/components/list_header_component.d.ts +1 -2
- package/build/screens/conversations/components/list_header_component.d.ts.map +1 -1
- package/build/screens/conversations/components/list_header_component.js +19 -42
- package/build/screens/conversations/components/list_header_component.js.map +1 -1
- package/build/screens/conversations/conversations_screen.d.ts +1 -2
- package/build/screens/conversations/conversations_screen.d.ts.map +1 -1
- package/build/screens/conversations/conversations_screen.js +2 -6
- package/build/screens/conversations/conversations_screen.js.map +1 -1
- package/build/screens/design_system_screen.d.ts +1 -2
- package/build/screens/design_system_screen.d.ts.map +1 -1
- package/build/screens/design_system_screen.js +35 -558
- package/build/screens/design_system_screen.js.map +1 -1
- package/build/screens/get_help_screen.d.ts +1 -1
- package/build/screens/get_help_screen.d.ts.map +1 -1
- package/build/screens/get_help_screen.js +4 -25
- package/build/screens/get_help_screen.js.map +1 -1
- package/build/screens/group_notification_level_select_screen.d.ts +1 -2
- package/build/screens/group_notification_level_select_screen.d.ts.map +1 -1
- package/build/screens/group_notification_level_select_screen.js +2 -4
- package/build/screens/group_notification_level_select_screen.js.map +1 -1
- package/build/screens/group_notification_settings_screen.d.ts +1 -2
- package/build/screens/group_notification_settings_screen.d.ts.map +1 -1
- package/build/screens/group_notification_settings_screen.js +3 -25
- package/build/screens/group_notification_settings_screen.js.map +1 -1
- package/build/screens/message_actions_screen.d.ts +1 -2
- package/build/screens/message_actions_screen.d.ts.map +1 -1
- package/build/screens/message_actions_screen.js +12 -28
- package/build/screens/message_actions_screen.js.map +1 -1
- package/build/screens/message_report/components/message_preview.d.ts +1 -2
- package/build/screens/message_report/components/message_preview.d.ts.map +1 -1
- package/build/screens/message_report/components/message_preview.js +2 -22
- package/build/screens/message_report/components/message_preview.js.map +1 -1
- package/build/screens/message_report/components/report_reason_list.d.ts +1 -2
- package/build/screens/message_report/components/report_reason_list.d.ts.map +1 -1
- package/build/screens/message_report/components/report_reason_list.js +4 -13
- package/build/screens/message_report/components/report_reason_list.js.map +1 -1
- package/build/screens/message_report_screen.d.ts +1 -2
- package/build/screens/message_report_screen.d.ts.map +1 -1
- package/build/screens/message_report_screen.js +9 -61
- package/build/screens/message_report_screen.js.map +1 -1
- package/build/screens/not_found.d.ts +1 -2
- package/build/screens/not_found.d.ts.map +1 -1
- package/build/screens/not_found.js +2 -5
- package/build/screens/not_found.js.map +1 -1
- package/build/screens/notification_settings/hooks/groups.d.ts +1 -1
- package/build/screens/notification_settings/hooks/groups.d.ts.map +1 -1
- package/build/screens/notification_settings_screen.d.ts +1 -2
- package/build/screens/notification_settings_screen.d.ts.map +1 -1
- package/build/screens/notification_settings_screen.js +28 -66
- package/build/screens/notification_settings_screen.js.map +1 -1
- package/build/screens/preferred_app_selection_screen.d.ts +1 -2
- package/build/screens/preferred_app_selection_screen.d.ts.map +1 -1
- package/build/screens/preferred_app_selection_screen.js +3 -21
- package/build/screens/preferred_app_selection_screen.js.map +1 -1
- package/build/screens/reactions_screen.d.ts +1 -2
- package/build/screens/reactions_screen.d.ts.map +1 -1
- package/build/screens/reactions_screen.js +7 -19
- package/build/screens/reactions_screen.js.map +1 -1
- package/build/screens/send_giphy_screen.d.ts +1 -2
- package/build/screens/send_giphy_screen.d.ts.map +1 -1
- package/build/screens/send_giphy_screen.js +5 -31
- package/build/screens/send_giphy_screen.js.map +1 -1
- package/build/screens/settings_screen.d.ts +1 -2
- package/build/screens/settings_screen.d.ts.map +1 -1
- package/build/screens/settings_screen.js +4 -26
- package/build/screens/settings_screen.js.map +1 -1
- package/build/screens/system_message_people_screen.d.ts +1 -2
- package/build/screens/system_message_people_screen.d.ts.map +1 -1
- package/build/screens/system_message_people_screen.js +4 -10
- package/build/screens/system_message_people_screen.js.map +1 -1
- package/build/screens/team_conversation_screen.d.ts +1 -1
- package/build/screens/team_conversation_screen.d.ts.map +1 -1
- package/build/screens/team_conversation_screen.js +4 -12
- package/build/screens/team_conversation_screen.js.map +1 -1
- package/build/types/resources/conversation.d.ts +1 -10
- package/build/types/resources/conversation.d.ts.map +1 -1
- package/build/types/resources/conversation.js.map +1 -1
- package/build/utils/request/conversation.d.ts.map +1 -1
- package/build/utils/request/conversation.js +0 -2
- package/build/utils/request/conversation.js.map +1 -1
- package/build/utils/sha_256.js.map +1 -1
- package/build/utils/system_messages.d.ts +1 -1
- package/build/utils/system_messages.d.ts.map +1 -1
- package/build/utils/system_messages.js.map +1 -1
- package/build/utils/theme.d.ts +2 -2
- package/build/utils/theme.d.ts.map +1 -1
- package/build/utils/theme.js.map +1 -1
- package/package.json +12 -12
- package/src/__tests__/hooks/use_attachment_uploader.test.tsx +1 -0
- package/src/__tests__/hooks/use_font_scale.test.ts +7 -3
- package/src/__tests__/utils/native_adapters/configuration.ts +1 -1
- package/src/__tests__/utils/system_messages.ts +1 -1
- package/src/__tests__/utils/uri.ts +8 -50
- package/src/__utils__/handlers.ts +5 -6
- package/src/components/conversation/attachments/attachment_deleting_overlay.tsx +10 -3
- package/src/components/conversations/conversation_preview.tsx +23 -58
- package/src/components/conversations/unread_count_badge.tsx +4 -13
- package/src/components/page/__tests__/component_error_boundary.test.tsx +1 -1
- package/src/components/page/__tests__/error_boundary.test.tsx +6 -2
- package/src/components/page/__tests__/page_error_boundary.test.tsx +1 -1
- package/src/hooks/use_conversation.ts +0 -2
- package/src/hooks/use_conversation_jolt_events.ts +19 -3
- package/src/hooks/use_conversation_messages.ts +6 -5
- package/src/hooks/use_conversations_actions.ts +1 -3
- package/src/hooks/use_mark_latest_message_read.ts +4 -3
- package/src/index.tsx +2 -1
- package/src/polyfills/events/EventTarget.ts +1 -1
- package/src/screens/conversation_screen.tsx +4 -2
- package/src/screens/conversations/components/list_header_component.tsx +6 -6
- package/src/types/resources/conversation.ts +1 -11
- package/src/utils/request/conversation.ts +0 -2
- package/src/utils/sha_256.ts +24 -24
- package/src/utils/system_messages.ts +1 -1
- package/src/utils/theme.ts +3 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"team_conversation_screen.js","sourceRoot":"","sources":["../../src/screens/team_conversation_screen.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAqB,aAAa,EAAE,MAAM,0BAA0B,CAAA;AACzF,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAA;AAChE,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACjC,OAAO,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAA;AAC3D,OAAO,UAAU,MAAM,+CAA+C,CAAA;AACtE,OAAO,EAAE,YAAY,EAAE,MAAM,UAAU,CAAA;AACvC,OAAO,EAAE,gCAAgC,EAAE,MAAM,4DAA4D,CAAA;AAC7G,OAAO,EAAE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C,OAAO,eACjB,KAAC,UAAU,CAAC,OAAO,gDAAmD,EACtE,KAAC,UAAU,CAAC,IAAI,cACb,MAAM,IAAI,wDAAwD,GACnD,IACC,EACrB,KAAC,UAAU,CAAC,MAAM,IAAC,KAAK,EAAC,SAAS,EAAC,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAC,IAAI,EAAC,iBAAiB,EAAC,MAAM,GAAG,IAC3E,CACnB,CAAA;AACH,CAAC","sourcesContent":["import { StackActions, StaticScreenProps, useNavigation } from '@react-navigation/native'\nimport { useQuery, useQueryClient } from '@tanstack/react-query'\nimport { useEffect } from 'react'\nimport { DefaultLoading } from '../components/page/loading'\nimport BlankState from '../components/primitive/blank_state_primitive'\nimport { useApiClient } from '../hooks'\nimport { findOrCreateServicesConversation } from '../hooks/services/use_find_or_create_services_conversation'\nimport { ResponseError } from '../utils/response_error'\n\nexport type TeamConversationRouteProps = {\n plan_id?: number\n team_ids?: number[]\n}\n\nexport type TeamConversationScreenProps = StaticScreenProps<TeamConversationRouteProps>\n\nexport const TeamConversationScreen = ({ route }: TeamConversationScreenProps) => {\n const apiClient = useApiClient()\n const queryClient = useQueryClient()\n const navigation = useNavigation()\n const {\n data: conversation,\n isError,\n error,\n } = useQuery({\n queryKey: ['team-conversation', route.params.team_ids, route.params.plan_id],\n queryFn: () =>\n findOrCreateServicesConversation({\n apiClient,\n teamIds: route.params.team_ids ?? [],\n planId: route.params.plan_id,\n }).then(r => r.conversation),\n retry: (failureCount, err) => !(err instanceof ResponseError) && failureCount < 3,\n })\n\n useEffect(() => {\n if (!conversation?.id) return\n\n navigation.dispatch(\n StackActions.replace('Conversation', {\n conversation_id: conversation.id,\n title: conversation.title,\n })\n )\n\n return () => {\n queryClient.removeQueries({ queryKey: ['team-conversation'] })\n }\n }, [conversation?.id, conversation?.title, navigation, queryClient])\n\n if (isError) return <TeamConversationError error={error} onGoBack={navigation.goBack} />\n\n return <DefaultLoading />\n}\n\nfunction TeamConversationError({ error, onGoBack }: { error: Error; onGoBack: () => void }) {\n const detail =\n error instanceof ResponseError\n ? error.errors\n .map(e => e.detail)\n .filter(Boolean)\n .join('\\n')\n : ''\n\n return (\n <BlankState.Root>\n <BlankState.Imagery name=\"people.noTextMessage\" />\n <BlankState.Content>\n <BlankState.Heading>Can't start this conversation</BlankState.Heading>\n <BlankState.Text>\n {detail || 'Something went wrong while starting this conversation.'}\n </BlankState.Text>\n </BlankState.Content>\n <BlankState.Button title=\"Go back\" onPress={onGoBack} size=\"md\" accessibilityRole=\"link\" />\n </BlankState.Root>\n )\n}\n"]}
|
|
@@ -3,22 +3,13 @@ import { ConversationBadgeResource } from './conversation_badge';
|
|
|
3
3
|
import { ConversationMembershipResource } from './conversation_membership';
|
|
4
4
|
import { GroupResource } from './group_resource';
|
|
5
5
|
import { MemberAbilityResource } from './member_ability';
|
|
6
|
-
import { ReactionCountResource } from './reaction';
|
|
7
6
|
export type ConversationDisabledReason = 'safety_check' | 'direct_messages_disabled';
|
|
8
|
-
export interface ConversationPreviewData {
|
|
9
|
-
kind: 'reaction' | 'message';
|
|
10
|
-
authorName: string;
|
|
11
|
-
value: ReactionCountResource['value'] | null;
|
|
12
|
-
text: string;
|
|
13
|
-
createdAt: string;
|
|
14
|
-
}
|
|
15
7
|
export interface ConversationResource {
|
|
16
8
|
type: 'Conversation';
|
|
17
9
|
id: number;
|
|
18
10
|
badges?: ConversationBadgeResource[];
|
|
19
11
|
analyticsMetadata?: AnalyticsMetadataResource;
|
|
20
12
|
conversationMembership?: Partial<ConversationMembershipResource>;
|
|
21
|
-
conversationPreview: ConversationPreviewData | null;
|
|
22
13
|
createdAt: string;
|
|
23
14
|
deleted?: boolean;
|
|
24
15
|
directMessage?: boolean;
|
|
@@ -41,7 +32,7 @@ export interface ConversationResource {
|
|
|
41
32
|
repliesDisabled: boolean;
|
|
42
33
|
title: string;
|
|
43
34
|
unreadCount: number;
|
|
44
|
-
|
|
35
|
+
unreadReactionCount?: number;
|
|
45
36
|
updatedAt: string;
|
|
46
37
|
}
|
|
47
38
|
//# sourceMappingURL=conversation.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"conversation.d.ts","sourceRoot":"","sources":["../../../src/types/resources/conversation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,sBAAsB,CAAA;AACrE,OAAO,EAAE,yBAAyB,EAAE,MAAM,sBAAsB,CAAA;AAChE,OAAO,EAAE,8BAA8B,EAAE,MAAM,2BAA2B,CAAA;AAC1E,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAA;AAChD,OAAO,EAAE,qBAAqB,EAAE,MAAM,kBAAkB,CAAA;
|
|
1
|
+
{"version":3,"file":"conversation.d.ts","sourceRoot":"","sources":["../../../src/types/resources/conversation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,sBAAsB,CAAA;AACrE,OAAO,EAAE,yBAAyB,EAAE,MAAM,sBAAsB,CAAA;AAChE,OAAO,EAAE,8BAA8B,EAAE,MAAM,2BAA2B,CAAA;AAC1E,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAA;AAChD,OAAO,EAAE,qBAAqB,EAAE,MAAM,kBAAkB,CAAA;AAExD,MAAM,MAAM,0BAA0B,GAAG,cAAc,GAAG,0BAA0B,CAAA;AAEpF,MAAM,WAAW,oBAAoB;IACnC,IAAI,EAAE,cAAc,CAAA;IACpB,EAAE,EAAE,MAAM,CAAA;IACV,MAAM,CAAC,EAAE,yBAAyB,EAAE,CAAA;IACpC,iBAAiB,CAAC,EAAE,yBAAyB,CAAA;IAC7C,sBAAsB,CAAC,EAAE,OAAO,CAAC,8BAA8B,CAAC,CAAA;IAChE,SAAS,EAAE,MAAM,CAAA;IACjB,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,aAAa,CAAC,EAAE,OAAO,CAAA;IACvB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,cAAc,CAAC,EAAE,0BAA0B,CAAA;IAC3C,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IAC5B,MAAM,CAAC,EAAE,aAAa,EAAE,CAAA;IACxB,iBAAiB,CAAC,EAAE,MAAM,EAAE,CAAA;IAC5B,gBAAgB,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,OAAO,GAAG,IAAI,CAAA;IACpD,eAAe,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IAC/B,iBAAiB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IACjC,oBAAoB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IACpC,mBAAmB,CAAC,EAAE,MAAM,CAAA;IAC5B,qBAAqB,CAAC,EAAE,MAAM,CAAA;IAC9B,oBAAoB,CAAC,EAAE,MAAM,CAAA;IAC7B,sBAAsB,CAAC,EAAE,MAAM,CAAA;IAC/B,wBAAwB,CAAC,EAAE,MAAM,CAAA;IACjC,aAAa,CAAC,EAAE,qBAAqB,CAAA;IACrC,KAAK,EAAE,OAAO,CAAA;IACd,eAAe,EAAE,OAAO,CAAA;IACxB,KAAK,EAAE,MAAM,CAAA;IACb,WAAW,EAAE,MAAM,CAAA;IACnB,mBAAmB,CAAC,EAAE,MAAM,CAAA;IAC5B,SAAS,EAAE,MAAM,CAAA;CAClB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"conversation.js","sourceRoot":"","sources":["../../../src/types/resources/conversation.ts"],"names":[],"mappings":"","sourcesContent":["import type { AnalyticsMetadataResource } from './analytics_metadata'\nimport { ConversationBadgeResource } from './conversation_badge'\nimport { ConversationMembershipResource } from './conversation_membership'\nimport { GroupResource } from './group_resource'\nimport { MemberAbilityResource } from './member_ability'\
|
|
1
|
+
{"version":3,"file":"conversation.js","sourceRoot":"","sources":["../../../src/types/resources/conversation.ts"],"names":[],"mappings":"","sourcesContent":["import type { AnalyticsMetadataResource } from './analytics_metadata'\nimport { ConversationBadgeResource } from './conversation_badge'\nimport { ConversationMembershipResource } from './conversation_membership'\nimport { GroupResource } from './group_resource'\nimport { MemberAbilityResource } from './member_ability'\n\nexport type ConversationDisabledReason = 'safety_check' | 'direct_messages_disabled'\n\nexport interface ConversationResource {\n type: 'Conversation'\n id: number\n badges?: ConversationBadgeResource[]\n analyticsMetadata?: AnalyticsMetadataResource\n conversationMembership?: Partial<ConversationMembershipResource>\n createdAt: string\n deleted?: boolean\n directMessage?: boolean\n disabled?: boolean\n disabledReason?: ConversationDisabledReason\n genderOption?: string | null\n groups?: GroupResource[]\n previewAvatarUrls?: string[]\n customAvatarType?: 'image' | 'icon' | 'emoji' | null\n customAvatarKey?: string | null\n customAvatarColor?: string | null\n customAvatarImageUrl?: string | null\n lastMessageAuthorId?: string\n lastMessageAuthorName?: string\n lastMessageCreatedAt?: string\n lastMessageTextPreview?: string\n latestReadMessageSortKey?: string\n memberAbility?: MemberAbilityResource\n muted: boolean\n repliesDisabled: boolean\n title: string\n unreadCount: number\n unreadReactionCount?: number // Derived from Jolt events\n updatedAt: string\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"conversation.d.ts","sourceRoot":"","sources":["../../../src/utils/request/conversation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,sCAAsC,CAAA;AAC9D,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;AAE5C,MAAM,WAAW,uBAAuB;IACtC,IAAI,EAAE,MAAM,CAAA;IACZ,mBAAmB,CAAC,EAAE,OAAO,CAAA;IAC7B,qBAAqB,CAAC,EAAE,MAAM,CAAA;IAC9B,oBAAoB,CAAC,EAAE,OAAO,CAAA;CAC/B;AAED,eAAO,MAAM,2BAA2B,GAAI,8EAKzC,OAAO,CAAC,uBAAuB,CAAM,KAAG,
|
|
1
|
+
{"version":3,"file":"conversation.d.ts","sourceRoot":"","sources":["../../../src/utils/request/conversation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,sCAAsC,CAAA;AAC9D,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;AAE5C,MAAM,WAAW,uBAAuB;IACtC,IAAI,EAAE,MAAM,CAAA;IACZ,mBAAmB,CAAC,EAAE,OAAO,CAAA;IAC7B,qBAAqB,CAAC,EAAE,MAAM,CAAA;IAC9B,oBAAoB,CAAC,EAAE,OAAO,CAAA;CAC/B;AAED,eAAO,MAAM,2BAA2B,GAAI,8EAKzC,OAAO,CAAC,uBAAuB,CAAM,KAAG,UAkD1C,CAAA"}
|
|
@@ -25,7 +25,6 @@ export const getConversationsRequestArgs = ({ gids, chat_group_graph_id, group_s
|
|
|
25
25
|
Conversation: [
|
|
26
26
|
'created_at',
|
|
27
27
|
'badges',
|
|
28
|
-
'conversation_preview',
|
|
29
28
|
'disabled',
|
|
30
29
|
'disabled_reason',
|
|
31
30
|
'groups',
|
|
@@ -43,7 +42,6 @@ export const getConversationsRequestArgs = ({ gids, chat_group_graph_id, group_s
|
|
|
43
42
|
'replies_disabled',
|
|
44
43
|
'title',
|
|
45
44
|
'unread_count',
|
|
46
|
-
'unread_reaction',
|
|
47
45
|
'updated_at',
|
|
48
46
|
],
|
|
49
47
|
AnalyticsMetadata: ['metadata'],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"conversation.js","sourceRoot":"","sources":["../../../src/utils/request/conversation.ts"],"names":[],"mappings":"AAUA,MAAM,CAAC,MAAM,2BAA2B,GAAG,CAAC,EAC1C,IAAI,EACJ,mBAAmB,EACnB,qBAAqB,EACrB,oBAAoB,MACgB,EAAE,EAAc,EAAE;IACtD,IAAI,MAAc,CAAA;IAClB,IAAI,mBAAmB,EAAE,CAAC;QACxB,MAAM,GAAG,yBAAyB,CAAA;IACpC,CAAC;SAAM,IAAI,oBAAoB,EAAE,CAAC;QAChC,MAAM,GAAG,kCAAkC,CAAA;IAC7C,CAAC;SAAM,IAAI,qBAAqB,EAAE,CAAC;QACjC,MAAM,GAAG,yCAAyC,CAAA;IACpD,CAAC;SAAM,CAAC;QACN,MAAM,GAAG,mBAAmB,CAAA;IAC9B,CAAC;IAED,OAAO;QACL,GAAG,EAAE,mBAAmB;QACxB,IAAI,EAAE;YACJ,OAAO,EAAE,EAAE;YACX,KAAK,EAAE,eAAe;YACtB,MAAM;YACN,IAAI;YACJ,KAAK,EAAE,mBAAmB;YAC1B,qBAAqB;YACrB,MAAM,EAAE;gBACN,YAAY,EAAE;oBACZ,YAAY;oBACZ,QAAQ;oBACR,
|
|
1
|
+
{"version":3,"file":"conversation.js","sourceRoot":"","sources":["../../../src/utils/request/conversation.ts"],"names":[],"mappings":"AAUA,MAAM,CAAC,MAAM,2BAA2B,GAAG,CAAC,EAC1C,IAAI,EACJ,mBAAmB,EACnB,qBAAqB,EACrB,oBAAoB,MACgB,EAAE,EAAc,EAAE;IACtD,IAAI,MAAc,CAAA;IAClB,IAAI,mBAAmB,EAAE,CAAC;QACxB,MAAM,GAAG,yBAAyB,CAAA;IACpC,CAAC;SAAM,IAAI,oBAAoB,EAAE,CAAC;QAChC,MAAM,GAAG,kCAAkC,CAAA;IAC7C,CAAC;SAAM,IAAI,qBAAqB,EAAE,CAAC;QACjC,MAAM,GAAG,yCAAyC,CAAA;IACpD,CAAC;SAAM,CAAC;QACN,MAAM,GAAG,mBAAmB,CAAA;IAC9B,CAAC;IAED,OAAO;QACL,GAAG,EAAE,mBAAmB;QACxB,IAAI,EAAE;YACJ,OAAO,EAAE,EAAE;YACX,KAAK,EAAE,eAAe;YACtB,MAAM;YACN,IAAI;YACJ,KAAK,EAAE,mBAAmB;YAC1B,qBAAqB;YACrB,MAAM,EAAE;gBACN,YAAY,EAAE;oBACZ,YAAY;oBACZ,QAAQ;oBACR,UAAU;oBACV,iBAAiB;oBACjB,QAAQ;oBACR,wBAAwB;oBACxB,0BAA0B;oBAC1B,yBAAyB;oBACzB,2BAA2B;oBAC3B,qBAAqB;oBACrB,oBAAoB;oBACpB,mBAAmB;oBACnB,qBAAqB;oBACrB,yBAAyB;oBACzB,gBAAgB;oBAChB,OAAO;oBACP,kBAAkB;oBAClB,OAAO;oBACP,cAAc;oBACd,YAAY;iBACb;gBACD,iBAAiB,EAAE,CAAC,UAAU,CAAC;gBAC/B,iBAAiB,EAAE,CAAC,UAAU,EAAE,mBAAmB,EAAE,MAAM,CAAC;aAC7D;YACD,OAAO,EAAE,CAAC,QAAQ,EAAE,oBAAoB,CAAC;SAC1C;KACF,CAAA;AACH,CAAC,CAAA","sourcesContent":["import { GraphId } from '../../types/resources/group_resource'\nimport { GetRequest } from '../client/types'\n\nexport interface ConversationRequestArgs {\n gids: string\n chat_group_graph_id?: GraphId\n group_source_app_name?: string\n show_direct_messages?: boolean\n}\n\nexport const getConversationsRequestArgs = ({\n gids,\n chat_group_graph_id,\n group_source_app_name,\n show_direct_messages,\n}: Partial<ConversationRequestArgs> = {}): GetRequest => {\n let filter: string\n if (chat_group_graph_id) {\n filter = 'mine_or_not_empty,group'\n } else if (show_direct_messages) {\n filter = 'mine_or_not_empty,direct_message'\n } else if (group_source_app_name) {\n filter = 'mine_or_not_empty,group_source_app_name'\n } else {\n filter = 'mine_or_not_empty'\n }\n\n return {\n url: '/me/conversations',\n data: {\n perPage: 20,\n order: '-last_message',\n filter,\n gids,\n group: chat_group_graph_id,\n group_source_app_name,\n fields: {\n Conversation: [\n 'created_at',\n 'badges',\n 'disabled',\n 'disabled_reason',\n 'groups',\n 'last_message_author_id',\n 'last_message_author_name',\n 'last_message_created_at',\n 'last_message_text_preview',\n 'preview_avatar_urls',\n 'custom_avatar_type',\n 'custom_avatar_key',\n 'custom_avatar_color',\n 'custom_avatar_image_url',\n 'member_ability',\n 'muted',\n 'replies_disabled',\n 'title',\n 'unread_count',\n 'updated_at',\n ],\n AnalyticsMetadata: ['metadata'],\n ConversationBadge: ['app_name', 'pco_resource_type', 'text'],\n },\n include: ['badges', 'analytics_metadata'],\n },\n }\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3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AAC,CAAC,EAAE,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,EAAE,CAAC;CACzF,CAAA;AAED;;;;GAIG;AACH,MAAM,UAAU,MAAM,CAAC,OAAe;IACpC,MAAM,IAAI,GAAG,SAAS,CAAC,OAAO,CAAC,CAAA;IAC/B,OAAO,IAAI,UAAU,CAAC,IAAI,CAAC,CAAA;AAC7B,CAAC;AAED,gDAAgD;AAChD,MAAM,CAAC,MAAM,GAAG,GAAG;IACjB,GAAG;CACJ,CAAA","sourcesContent":["/**\n * Pure JavaScript SHA-256 implementation\n * Conforms to the crypto-js API for drop-in replacement\n */\n\n/* eslint-disable no-bitwise */\n\n// SHA-256 constants (first 32 bits of the fractional parts of the cube roots of the first 64 primes)\nconst K = [\n 0x428a2f98, 0x71374491, 0xb5c0fbcf, 0xe9b5dba5, 0x3956c25b, 0x59f111f1, 0x923f82a4, 0xab1c5ed5,\n 0xd807aa98, 0x12835b01, 0x243185be, 0x550c7dc3, 0x72be5d74, 0x80deb1fe, 0x9bdc06a7, 0xc19bf174,\n 0xe49b69c1, 0xefbe4786, 0x0fc19dc6, 0x240ca1cc, 0x2de92c6f, 0x4a7484aa, 0x5cb0a9dc, 0x76f988da,\n 0x983e5152, 0xa831c66d, 0xb00327c8, 0xbf597fc7, 0xc6e00bf3, 0xd5a79147, 0x06ca6351, 0x14292967,\n 0x27b70a85, 0x2e1b2138, 0x4d2c6dfc, 0x53380d13, 0x650a7354, 0x766a0abb, 0x81c2c92e, 0x92722c85,\n 0xa2bfe8a1, 0xa81a664b, 0xc24b8b70, 0xc76c51a3, 0xd192e819, 0xd6990624, 0xf40e3585, 0x106aa070,\n 0x19a4c116, 0x1e376c08, 0x2748774c, 0x34b0bcb5, 0x391c0cb3, 0x4ed8aa4a, 0x5b9cca4f, 0x682e6ff3,\n 0x748f82ee, 0x78a5636f, 0x84c87814, 0x8cc70208, 0x90befffa, 0xa4506ceb, 0xbef9a3f7, 0xc67178f2,\n]\n\n// Initial hash values (first 32 bits of the fractional parts of the square roots of the first 8 primes)\nconst H = [\n 0x6a09e667, 0xbb67ae85, 0x3c6ef372, 0xa54ff53a, 0x510e527f, 0x9b05688c, 0x1f83d9ab, 0x5be0cd19,\n]\n\n/** Right rotate 32-bit integer */\nfunction rotr(n: number, x: number): number {\n return (x >>> n) | (x << (32 - n))\n}\n\n/** SHA-256 choice function */\nfunction ch(x: number, y: number, z: number): number {\n return (x & y) ^ (~x & z)\n}\n\n/** SHA-256 majority function */\nfunction maj(x: number, y: number, z: number): number {\n return (x & y) ^ (x & z) ^ (y & z)\n}\n\n/** SHA-256 Σ0 function */\nfunction sigma0(x: number): number {\n return rotr(2, x) ^ rotr(13, x) ^ rotr(22, x)\n}\n\n/** SHA-256 Σ1 function */\nfunction sigma1(x: number): number {\n return rotr(6, x) ^ rotr(11, x) ^ rotr(25, x)\n}\n\n/** SHA-256 σ0 function */\nfunction gamma0(x: number): number {\n return rotr(7, x) ^ rotr(18, x) ^ (x >>> 3)\n}\n\n/** SHA-256 σ1 function */\nfunction gamma1(x: number): number {\n return rotr(17, x) ^ rotr(19, x) ^ (x >>> 10)\n}\n\n/** Convert string to UTF-8 byte array */\nfunction stringToBytes(str: string): number[] {\n const bytes: number[] = []\n for (let i = 0; i < str.length; i++) {\n let charCode = str.charCodeAt(i)\n if (charCode < 0x80) {\n bytes.push(charCode)\n } else if (charCode < 0x800) {\n bytes.push(0xc0 | (charCode >> 6), 0x80 | (charCode & 0x3f))\n } else if (charCode < 0xd800 || charCode >= 0xe000) {\n bytes.push(0xe0 | (charCode >> 12), 0x80 | ((charCode >> 6) & 0x3f), 0x80 | (charCode & 0x3f))\n } else {\n // Surrogate pair\n i++\n charCode = 0x10000 + (((charCode & 0x3ff) << 10) | (str.charCodeAt(i) & 0x3ff))\n bytes.push(\n 0xf0 | (charCode >> 18),\n 0x80 | ((charCode >> 12) & 0x3f),\n 0x80 | ((charCode >> 6) & 0x3f),\n 0x80 | (charCode & 0x3f)\n )\n }\n }\n return bytes\n}\n\n/** Preprocess message: pad and convert to 512-bit blocks */\nfunction preprocessMessage(message: number[]): Uint32Array {\n const messageLength = message.length\n const bitLength = messageLength * 8\n\n // Append the '1' bit (plus zero padding to make 8 bits)\n message.push(0x80)\n\n // Append zeros until message length ≡ 448 (mod 512)\n // This leaves 64 bits for the length\n while (message.length % 64 !== 56) {\n message.push(0x00)\n }\n\n // Append original message length as 64-bit big-endian integer\n // JavaScript numbers are 53-bit safe, so we split into two 32-bit parts\n const lengthHigh = Math.floor(bitLength / 0x100000000)\n const lengthLow = bitLength >>> 0\n\n for (let i = 24; i >= 0; i -= 8) {\n message.push((lengthHigh >>> i) & 0xff)\n }\n for (let i = 24; i >= 0; i -= 8) {\n message.push((lengthLow >>> i) & 0xff)\n }\n\n // Convert byte array to 32-bit word array\n const words = new Uint32Array(message.length / 4)\n for (let i = 0; i < message.length; i += 4) {\n words[i / 4] =\n (message[i] << 24) | (message[i + 1] << 16) | (message[i + 2] << 8) | message[i + 3]\n }\n\n return words\n}\n\n/** Process a single 512-bit chunk */\nfunction processChunk(chunk: Uint32Array, hash: number[]): void {\n const W = new Uint32Array(64)\n\n // Prepare message schedule\n for (let t = 0; t < 16; t++) {\n W[t] = chunk[t]\n }\n for (let t = 16; t < 64; t++) {\n W[t] = (gamma1(W[t - 2]) + W[t - 7] + gamma0(W[t - 15]) + W[t - 16]) >>> 0\n }\n\n // Initialize working variables\n let a = hash[0]\n let b = hash[1]\n let c = hash[2]\n let d = hash[3]\n let e = hash[4]\n let f = hash[5]\n let g = hash[6]\n let h = hash[7]\n\n // Main loop\n for (let t = 0; t < 64; t++) {\n const T1 = (h + sigma1(e) + ch(e, f, g) + K[t] + W[t]) >>> 0\n const T2 = (sigma0(a) + maj(a, b, c)) >>> 0\n h = g\n g = f\n f = e\n e = (d + T1) >>> 0\n d = c\n c = b\n b = a\n a = (T1 + T2) >>> 0\n }\n\n // Add compressed chunk to current hash value\n hash[0] = (hash[0] + a) >>> 0\n hash[1] = (hash[1] + b) >>> 0\n hash[2] = (hash[2] + c) >>> 0\n hash[3] = (hash[3] + d) >>> 0\n hash[4] = (hash[4] + e) >>> 0\n hash[5] = (hash[5] + f) >>> 0\n hash[6] = (hash[6] + g) >>> 0\n hash[7] = (hash[7] + h) >>> 0\n}\n\n/** Compute SHA-256 hash and return as byte array */\nfunction sha256Raw(message: string): number[] {\n const bytes = stringToBytes(message)\n const preprocessed = preprocessMessage(bytes)\n const hash = [...H] // Copy initial hash values\n\n // Process each 512-bit chunk\n for (let i = 0; i < preprocessed.length; i += 16) {\n const chunk = preprocessed.subarray(i, i + 16)\n processChunk(chunk, hash)\n }\n\n // Convert hash to byte array\n const result: number[] = []\n for (let i = 0; i < 8; i++) {\n result.push((hash[i] >>> 24) & 0xff)\n result.push((hash[i] >>> 16) & 0xff)\n result.push((hash[i] >>> 8) & 0xff)\n result.push(hash[i] & 0xff)\n }\n\n return result\n}\n\n/** Hash result object with toString methods */\nclass HashResult {\n private bytes: number[]\n\n constructor(bytes: number[]) {\n this.bytes = bytes\n }\n\n /** Convert hash to hexadecimal string */\n toString(encoding?: { stringify: (bytes: number[]) => string }): string {\n if (encoding === Hex) {\n return this.bytes.map(b => b.toString(16).padStart(2, '0')).join('')\n }\n // Default to hex if no encoding specified\n return this.bytes.map(b => b.toString(16).padStart(2, '0')).join('')\n }\n}\n\n/** Hex encoding object (mimics crypto-js enc.Hex) */\nexport const Hex = {\n stringify: (bytes: number[]) => bytes.map(b => b.toString(16).padStart(2, '0')).join(''),\n}\n\n/**\n * Compute SHA-256 hash of a string\n * @param message - The message to hash\n * @returns HashResult object with toString method\n */\nexport function SHA256(message: string): HashResult {\n const hash = sha256Raw(message)\n return new HashResult(hash)\n}\n\n/** Encoding utilities (mimics crypto-js enc) */\nexport const enc = {\n Hex,\n}\n"]}
|
|
1
|
+
{"version":3,"file":"sha_256.js","sourceRoot":"","sources":["../../src/utils/sha_256.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,+BAA+B;AAE/B,q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AACH,MAAM,UAAU,MAAM,CAAC,OAAe;IACpC,MAAM,IAAI,GAAG,SAAS,CAAC,OAAO,CAAC,CAAA;IAC/B,OAAO,IAAI,UAAU,CAAC,IAAI,CAAC,CAAA;AAC7B,CAAC;AAED,gDAAgD;AAChD,MAAM,CAAC,MAAM,GAAG,GAAG;IACjB,GAAG;CACJ,CAAA","sourcesContent":["/**\n * Pure JavaScript SHA-256 implementation\n * Conforms to the crypto-js API for drop-in replacement\n */\n\n/* eslint-disable no-bitwise */\n\n// SHA-256 constants (first 32 bits of the fractional parts of the cube roots of the first 64 primes)\nconst K = [\n 0x428a2f98, 0x71374491, 0xb5c0fbcf, 0xe9b5dba5, 0x3956c25b, 0x59f111f1, 0x923f82a4, 0xab1c5ed5,\n 0xd807aa98, 0x12835b01, 0x243185be, 0x550c7dc3, 0x72be5d74, 0x80deb1fe, 0x9bdc06a7, 0xc19bf174,\n 0xe49b69c1, 0xefbe4786, 0x0fc19dc6, 0x240ca1cc, 0x2de92c6f, 0x4a7484aa, 0x5cb0a9dc, 0x76f988da,\n 0x983e5152, 0xa831c66d, 0xb00327c8, 0xbf597fc7, 0xc6e00bf3, 0xd5a79147, 0x06ca6351, 0x14292967,\n 0x27b70a85, 0x2e1b2138, 0x4d2c6dfc, 0x53380d13, 0x650a7354, 0x766a0abb, 0x81c2c92e, 0x92722c85,\n 0xa2bfe8a1, 0xa81a664b, 0xc24b8b70, 0xc76c51a3, 0xd192e819, 0xd6990624, 0xf40e3585, 0x106aa070,\n 0x19a4c116, 0x1e376c08, 0x2748774c, 0x34b0bcb5, 0x391c0cb3, 0x4ed8aa4a, 0x5b9cca4f, 0x682e6ff3,\n 0x748f82ee, 0x78a5636f, 0x84c87814, 0x8cc70208, 0x90befffa, 0xa4506ceb, 0xbef9a3f7, 0xc67178f2,\n]\n\n// Initial hash values (first 32 bits of the fractional parts of the square roots of the first 8 primes)\nconst H = [\n 0x6a09e667, 0xbb67ae85, 0x3c6ef372, 0xa54ff53a, 0x510e527f, 0x9b05688c, 0x1f83d9ab, 0x5be0cd19,\n]\n\n/** Right rotate 32-bit integer */\nfunction rotr(n: number, x: number): number {\n return (x >>> n) | (x << (32 - n))\n}\n\n/** SHA-256 choice function */\nfunction ch(x: number, y: number, z: number): number {\n return (x & y) ^ (~x & z)\n}\n\n/** SHA-256 majority function */\nfunction maj(x: number, y: number, z: number): number {\n return (x & y) ^ (x & z) ^ (y & z)\n}\n\n/** SHA-256 Σ0 function */\nfunction sigma0(x: number): number {\n return rotr(2, x) ^ rotr(13, x) ^ rotr(22, x)\n}\n\n/** SHA-256 Σ1 function */\nfunction sigma1(x: number): number {\n return rotr(6, x) ^ rotr(11, x) ^ rotr(25, x)\n}\n\n/** SHA-256 σ0 function */\nfunction gamma0(x: number): number {\n return rotr(7, x) ^ rotr(18, x) ^ (x >>> 3)\n}\n\n/** SHA-256 σ1 function */\nfunction gamma1(x: number): number {\n return rotr(17, x) ^ rotr(19, x) ^ (x >>> 10)\n}\n\n/** Convert string to UTF-8 byte array */\nfunction stringToBytes(str: string): number[] {\n const bytes: number[] = []\n for (let i = 0; i < str.length; i++) {\n let charCode = str.charCodeAt(i)\n if (charCode < 0x80) {\n bytes.push(charCode)\n } else if (charCode < 0x800) {\n bytes.push(0xc0 | (charCode >> 6), 0x80 | (charCode & 0x3f))\n } else if (charCode < 0xd800 || charCode >= 0xe000) {\n bytes.push(0xe0 | (charCode >> 12), 0x80 | ((charCode >> 6) & 0x3f), 0x80 | (charCode & 0x3f))\n } else {\n // Surrogate pair\n i++\n charCode = 0x10000 + (((charCode & 0x3ff) << 10) | (str.charCodeAt(i) & 0x3ff))\n bytes.push(\n 0xf0 | (charCode >> 18),\n 0x80 | ((charCode >> 12) & 0x3f),\n 0x80 | ((charCode >> 6) & 0x3f),\n 0x80 | (charCode & 0x3f)\n )\n }\n }\n return bytes\n}\n\n/** Preprocess message: pad and convert to 512-bit blocks */\nfunction preprocessMessage(message: number[]): Uint32Array {\n const messageLength = message.length\n const bitLength = messageLength * 8\n\n // Append the '1' bit (plus zero padding to make 8 bits)\n message.push(0x80)\n\n // Append zeros until message length ≡ 448 (mod 512)\n // This leaves 64 bits for the length\n while (message.length % 64 !== 56) {\n message.push(0x00)\n }\n\n // Append original message length as 64-bit big-endian integer\n // JavaScript numbers are 53-bit safe, so we split into two 32-bit parts\n const lengthHigh = Math.floor(bitLength / 0x100000000)\n const lengthLow = bitLength >>> 0\n\n for (let i = 24; i >= 0; i -= 8) {\n message.push((lengthHigh >>> i) & 0xff)\n }\n for (let i = 24; i >= 0; i -= 8) {\n message.push((lengthLow >>> i) & 0xff)\n }\n\n // Convert byte array to 32-bit word array\n const words = new Uint32Array(message.length / 4)\n for (let i = 0; i < message.length; i += 4) {\n words[i / 4] =\n (message[i]! << 24) | (message[i + 1]! << 16) | (message[i + 2]! << 8) | message[i + 3]!\n }\n\n return words\n}\n\n/** Process a single 512-bit chunk */\nfunction processChunk(chunk: Uint32Array, hash: number[]): void {\n const W = new Uint32Array(64)\n\n // Prepare message schedule\n for (let t = 0; t < 16; t++) {\n W[t] = chunk[t]!\n }\n for (let t = 16; t < 64; t++) {\n W[t] = (gamma1(W[t - 2]!) + W[t - 7]! + gamma0(W[t - 15]!) + W[t - 16]!) >>> 0\n }\n\n // Initialize working variables\n let a = hash[0]!\n let b = hash[1]!\n let c = hash[2]!\n let d = hash[3]!\n let e = hash[4]!\n let f = hash[5]!\n let g = hash[6]!\n let h = hash[7]!\n\n // Main loop\n for (let t = 0; t < 64; t++) {\n const T1 = (h + sigma1(e) + ch(e, f, g) + K[t]! + W[t]!) >>> 0\n const T2 = (sigma0(a) + maj(a, b, c)) >>> 0\n h = g\n g = f\n f = e\n e = (d + T1) >>> 0\n d = c\n c = b\n b = a\n a = (T1 + T2) >>> 0\n }\n\n // Add compressed chunk to current hash value\n hash[0] = (hash[0]! + a) >>> 0\n hash[1] = (hash[1]! + b) >>> 0\n hash[2] = (hash[2]! + c) >>> 0\n hash[3] = (hash[3]! + d) >>> 0\n hash[4] = (hash[4]! + e) >>> 0\n hash[5] = (hash[5]! + f) >>> 0\n hash[6] = (hash[6]! + g) >>> 0\n hash[7] = (hash[7]! + h) >>> 0\n}\n\n/** Compute SHA-256 hash and return as byte array */\nfunction sha256Raw(message: string): number[] {\n const bytes = stringToBytes(message)\n const preprocessed = preprocessMessage(bytes)\n const hash = [...H] // Copy initial hash values\n\n // Process each 512-bit chunk\n for (let i = 0; i < preprocessed.length; i += 16) {\n const chunk = preprocessed.subarray(i, i + 16)\n processChunk(chunk, hash)\n }\n\n // Convert hash to byte array\n const result: number[] = []\n for (let i = 0; i < 8; i++) {\n result.push((hash[i]! >>> 24) & 0xff)\n result.push((hash[i]! >>> 16) & 0xff)\n result.push((hash[i]! >>> 8) & 0xff)\n result.push(hash[i]! & 0xff)\n }\n\n return result\n}\n\n/** Hash result object with toString methods */\nclass HashResult {\n private bytes: number[]\n\n constructor(bytes: number[]) {\n this.bytes = bytes\n }\n\n /** Convert hash to hexadecimal string */\n toString(encoding?: { stringify: (bytes: number[]) => string }): string {\n if (encoding === Hex) {\n return this.bytes.map(b => b.toString(16).padStart(2, '0')).join('')\n }\n // Default to hex if no encoding specified\n return this.bytes.map(b => b.toString(16).padStart(2, '0')).join('')\n }\n}\n\n/** Hex encoding object (mimics crypto-js enc.Hex) */\nexport const Hex = {\n stringify: (bytes: number[]) => bytes.map(b => b.toString(16).padStart(2, '0')).join(''),\n}\n\n/**\n * Compute SHA-256 hash of a string\n * @param message - The message to hash\n * @returns HashResult object with toString method\n */\nexport function SHA256(message: string): HashResult {\n const hash = sha256Raw(message)\n return new HashResult(hash)\n}\n\n/** Encoding utilities (mimics crypto-js enc) */\nexport const enc = {\n Hex,\n}\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { MessageResource } from '../types';
|
|
1
|
+
import type { MessageResource } from '../types';
|
|
2
2
|
declare const SYSTEM_MESSAGE_TYPES: readonly ["user_joined"];
|
|
3
3
|
type SystemMessageType = (typeof SYSTEM_MESSAGE_TYPES)[number];
|
|
4
4
|
export interface SystemMessageResource extends MessageResource {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"system_messages.d.ts","sourceRoot":"","sources":["../../src/utils/system_messages.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,UAAU,CAAA;
|
|
1
|
+
{"version":3,"file":"system_messages.d.ts","sourceRoot":"","sources":["../../src/utils/system_messages.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,UAAU,CAAA;AAE/C,QAAA,MAAM,oBAAoB,0BAA2B,CAAA;AAErD,KAAK,iBAAiB,GAAG,CAAC,OAAO,oBAAoB,CAAC,CAAC,MAAM,CAAC,CAAA;AAE9D,MAAM,WAAW,qBAAsB,SAAQ,eAAe;IAC5D,WAAW,EAAE,iBAAiB,CAAA;IAC9B,eAAe,EAAE;QAAE,KAAK,EAAE,MAAM,EAAE,CAAC;QAAC,aAAa,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAA;IAC3E,uBAAuB,EAAE,MAAM,EAAE,CAAA;CAClC;AAED,eAAO,MAAM,eAAe,GAAI,SAAS,eAAe,KAAG,OAAO,IAAI,qBAG7B,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"system_messages.js","sourceRoot":"","sources":["../../src/utils/system_messages.ts"],"names":[],"mappings":"AAEA,MAAM,oBAAoB,GAAG,CAAC,aAAa,CAAU,CAAA;AAUrD,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC,OAAwB,EAAoC,EAAE,CAC5F,oBAAoB,CAAC,QAAQ,CAAC,OAAO,CAAC,WAAgC,CAAC;IACvE,OAAO,CAAC,eAAe,IAAI,IAAI;IAC/B,OAAO,CAAC,uBAAuB,IAAI,IAAI,CAAA","sourcesContent":["import { MessageResource } from '../types'\n\nconst SYSTEM_MESSAGE_TYPES = ['user_joined'] as const\n\ntype SystemMessageType = (typeof SYSTEM_MESSAGE_TYPES)[number]\n\nexport interface SystemMessageResource extends MessageResource {\n messageType: SystemMessageType\n systemTextParts: { names: string[]; overflowCount: number; action: string }\n personIdsForSystemEvent: number[]\n}\n\nexport const isSystemMessage = (message: MessageResource): message is SystemMessageResource =>\n SYSTEM_MESSAGE_TYPES.includes(message.messageType as SystemMessageType) &&\n message.systemTextParts != null &&\n message.personIdsForSystemEvent != null\n"]}
|
|
1
|
+
{"version":3,"file":"system_messages.js","sourceRoot":"","sources":["../../src/utils/system_messages.ts"],"names":[],"mappings":"AAEA,MAAM,oBAAoB,GAAG,CAAC,aAAa,CAAU,CAAA;AAUrD,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC,OAAwB,EAAoC,EAAE,CAC5F,oBAAoB,CAAC,QAAQ,CAAC,OAAO,CAAC,WAAgC,CAAC;IACvE,OAAO,CAAC,eAAe,IAAI,IAAI;IAC/B,OAAO,CAAC,uBAAuB,IAAI,IAAI,CAAA","sourcesContent":["import type { MessageResource } from '../types'\n\nconst SYSTEM_MESSAGE_TYPES = ['user_joined'] as const\n\ntype SystemMessageType = (typeof SYSTEM_MESSAGE_TYPES)[number]\n\nexport interface SystemMessageResource extends MessageResource {\n messageType: SystemMessageType\n systemTextParts: { names: string[]; overflowCount: number; action: string }\n personIdsForSystemEvent: number[]\n}\n\nexport const isSystemMessage = (message: MessageResource): message is SystemMessageResource =>\n SYSTEM_MESSAGE_TYPES.includes(message.messageType as SystemMessageType) &&\n message.systemTextParts != null &&\n message.personIdsForSystemEvent != null\n"]}
|
package/build/utils/theme.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ColorSchemeName, ColorValue, OpaqueColorValue } from 'react-native';
|
|
1
|
+
import type { ColorSchemeName, ColorValue, OpaqueColorValue } from 'react-native';
|
|
2
2
|
import { aliasTokensColorMap } from '../vendor/tapestry/alias_tokens_color_map';
|
|
3
3
|
export interface ChatTheme extends DefaultTheme {
|
|
4
4
|
colors: DefaultTheme['colors'] & (typeof aliasTokensColorMap.light | typeof aliasTokensColorMap.dark);
|
|
@@ -24,7 +24,7 @@ export interface DefaultTheme {
|
|
|
24
24
|
};
|
|
25
25
|
showBadgeProductLogo: boolean;
|
|
26
26
|
}
|
|
27
|
-
export declare const defaultTheme: (colorScheme: ColorSchemeName) => ChatTheme;
|
|
27
|
+
export declare const defaultTheme: (colorScheme: ColorSchemeName | null) => ChatTheme;
|
|
28
28
|
export type TemporaryDefaultColorsType = Partial<ChatColors>;
|
|
29
29
|
interface ChatColors {
|
|
30
30
|
name: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../src/utils/theme.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../src/utils/theme.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,eAAe,EAAE,UAAU,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAA;AACjF,OAAO,EAAE,mBAAmB,EAAE,MAAM,2CAA2C,CAAA;AAG/E,MAAM,WAAW,SAAU,SAAQ,YAAY;IAC7C,MAAM,EAAE,YAAY,CAAC,QAAQ,CAAC,GAC5B,CAAC,OAAO,mBAAmB,CAAC,KAAK,GAAG,OAAO,mBAAmB,CAAC,IAAI,CAAC,CAAA;CACvE;AAED;;;;;;;;;;;;;gDAagD;AAEhD,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,UAAU,CAAA;IAClB,MAAM,EAAE;QACN,YAAY,EAAE,MAAM,CAAA;KACrB,CAAA;IACD,oBAAoB,EAAE,OAAO,CAAA;CAC9B;AAED,eAAO,MAAM,YAAY,GAAI,aAAa,eAAe,GAAG,IAAI,KAAG,SAelE,CAAA;AAED,MAAM,MAAM,0BAA0B,GAAG,OAAO,CAAC,UAAU,CAAC,CAAA;AAE5D,UAAU,UAAU;IAClB,IAAI,EAAE,MAAM,CAAA;IACZ,WAAW,EAAE,MA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BAA+B,EAAE,MAAM,CAAC,+BAA+B;IACvE,uBAAuB,EAAE,MAAM,CAAC,+BAA+B;IAC/D,uBAAuB,EAAE,MAAM,CAAC,wBAAwB;IACxD,6BAA6B,EAAE,MAAM,CAAC,6BAA6B;IACnE,yBAAyB,EAAE,MAAM,CAAC,iCAAiC;IACnE,yBAAyB,EAAE,MAAM,CAAC,0BAA0B;IAC5D,+BAA+B,EAAE,MAAM,CAAC,+BAA+B;CACxE,CAAA;AAED,MAAM,iBAAiB,GAAG;IACxB,KAAK,EAAE,eAAe;IACtB,IAAI,EAAE,cAAc;CACrB,CAAA","sourcesContent":["import { ColorSchemeName, ColorValue, OpaqueColorValue, PlatformColor } from 'react-native'\nimport { aliasTokensColorMap } from '../vendor/tapestry/alias_tokens_color_map'\nimport { tokens } from '../vendor/tapestry/tokens'\n\nexport interface ChatTheme extends DefaultTheme {\n colors: DefaultTheme['colors'] &\n (typeof aliasTokensColorMap.light | typeof aliasTokensColorMap.dark)\n}\n\n/** =============================================\n NOTE: The specific values for `colors` and the `productBadge` are temporary examples that can be replaced once we start building out UI. This line's comment can be removed at that time too.\n\n The default theme is intended to support two types of customizations:\n 1. Specific color properties for a chat component (eg. `primaryButtonBackgroundColor`)\n 2. Any styles for a specific component. (Use only one level of nesting.)\n ```\n primaryButton: {\n borderRadius: number\n container: ViewStyle\n text: TextStyle\n }\n ```\n============================================= */\n\nexport interface DefaultTheme {\n colors: ChatColors\n button: {\n borderRadius: number\n }\n showBadgeProductLogo: boolean\n}\n\nexport const defaultTheme = (colorScheme: ColorSchemeName): ChatTheme => {\n const scheme: 'light' | 'dark' = colorScheme === 'dark' ? 'dark' : 'light'\n\n const defaultColors = {\n ...chatThemeColorMap[scheme],\n ...aliasTokensColorMap[scheme],\n }\n\n return {\n colors: defaultColors,\n button: {\n borderRadius: 40,\n },\n showBadgeProductLogo: true, // Overrides visibility of the product logo in `src/display/badge.tsx`\n }\n}\n\nexport type TemporaryDefaultColorsType = Partial<ChatColors>\n\ninterface ChatColors {\n name: string\n buttonStart: string | undefined\n buttonEnd: string | undefined\n interaction: string\n androidModalHeaderButtonTextColor: ColorValue | string | undefined\n iOSModalHeaderButtonTextColor: OpaqueColorValue | string | undefined\n androidSwitchThumbColor: string | undefined\n conversationActionsBackground: string\n testColor: string\n statusSuccessIcon: string\n statusSuccessText: string\n statusSuccessBorder: string\n statusSuccessFill: string\n statusInfoIcon: string\n statusInfoText: string\n statusInfoBorder: string\n statusInfoFill: string\n statusWarningIcon: string\n statusWarningText: string\n statusWarningBorder: string\n statusWarningFill: string\n statusErrorIcon: string\n statusErrorText: string\n statusErrorBorder: string\n statusErrorFill: string\n statusSuccessComposedIcon: string\n statusSuccessComposedText: string\n statusSuccessComposedBackground: string\n statusInfoComposedIcon: string\n statusInfoComposedText: string\n statusInfoComposedBackground: string\n statusWarningComposedIcon: string\n statusWarningComposedText: string\n statusWarningComposedBackground: string\n statusErrorComposedIcon: string\n statusErrorComposedText: string\n statusErrorComposedBackground: string\n statusNeutralComposedIcon: string\n statusNeutralComposedText: string\n statusNeutralComposedBackground: string\n}\n\nconst colorsChatLight: ChatColors = {\n name: 'light',\n androidModalHeaderButtonTextColor: tokens.fillColorInteractionDefault,\n iOSModalHeaderButtonTextColor: PlatformColor('link'),\n buttonStart: undefined,\n buttonEnd: undefined,\n interaction: tokens.fillColorInteractionDefault,\n androidSwitchThumbColor: undefined,\n conversationActionsBackground: tokens.colorNeutral100White,\n testColor: 'hotpink',\n statusInfoIcon: tokens.iconColorStatusInfoPrimary,\n statusInfoText: tokens.textColorStatusInfo,\n statusInfoBorder: tokens.borderColorStatusInfo,\n statusInfoFill: tokens.fillColorStatusInfoSolid,\n statusSuccessIcon: tokens.iconColorStatusSuccessPrimary,\n statusSuccessText: tokens.textColorStatusSuccess,\n statusSuccessBorder: tokens.borderColorStatusSuccess,\n statusSuccessFill: tokens.fillColorStatusSuccessSolid,\n statusWarningIcon: tokens.iconColorStatusWarningPrimary,\n statusWarningText: tokens.textColorStatusWarning,\n statusWarningBorder: tokens.borderColorStatusWarning,\n statusWarningFill: tokens.fillColorStatusWarningSolid,\n statusErrorIcon: tokens.iconColorStatusErrorPrimary,\n statusErrorText: tokens.textColorStatusError,\n statusErrorBorder: tokens.borderColorStatusError,\n statusErrorFill: tokens.fillColorStatusErrorSolid,\n statusInfoComposedIcon: tokens.iconColorStatusInfoPrimary,\n statusInfoComposedText: tokens.textColorStatusInfo,\n statusInfoComposedBackground: tokens.fillColorStatusInfoGhost,\n statusSuccessComposedIcon: tokens.iconColorStatusSuccessPrimary,\n statusSuccessComposedText: tokens.textColorStatusSuccess,\n statusSuccessComposedBackground: tokens.fillColorStatusSuccessGhost,\n statusWarningComposedIcon: tokens.iconColorStatusWarningPrimary,\n statusWarningComposedText: tokens.textColorStatusWarning,\n statusWarningComposedBackground: tokens.fillColorStatusWarningGhost,\n statusErrorComposedIcon: tokens.iconColorStatusErrorPrimary,\n statusErrorComposedText: tokens.textColorStatusError,\n statusErrorComposedBackground: tokens.fillColorStatusErrorGhost,\n statusNeutralComposedIcon: tokens.iconColorStatusNeutralPrimary,\n statusNeutralComposedText: tokens.textColorStatusNeutral,\n statusNeutralComposedBackground: tokens.fillColorStatusNeutralGhost,\n}\n\nconst colorsChatDark: ChatColors = {\n name: 'dark',\n androidModalHeaderButtonTextColor: tokens.fillColorInteractionDefaultDark,\n iOSModalHeaderButtonTextColor: PlatformColor('link'),\n buttonStart: undefined,\n buttonEnd: undefined,\n interaction: tokens.fillColorInteractionDefaultDark,\n androidSwitchThumbColor: undefined,\n conversationActionsBackground: tokens.colorNeutral7,\n testColor: 'pink',\n statusInfoIcon: tokens.iconColorStatusInfoPrimaryDark,\n statusInfoText: tokens.textColorStatusInfoDark,\n statusInfoBorder: tokens.borderColorStatusInfoDark,\n statusInfoFill: tokens.fillColorStatusInfoSolidDark,\n statusSuccessIcon: tokens.iconColorStatusSuccessPrimaryDark,\n statusSuccessText: tokens.textColorStatusSuccessDark,\n statusSuccessBorder: tokens.borderColorStatusSuccessDark,\n statusSuccessFill: tokens.fillColorStatusSuccessSolidDark,\n statusWarningIcon: tokens.iconColorStatusWarningPrimaryDark,\n statusWarningText: tokens.textColorStatusWarningDark,\n statusWarningBorder: tokens.borderColorStatusWarningDark,\n statusWarningFill: tokens.fillColorStatusWarningSolidDark,\n statusErrorIcon: tokens.iconColorStatusErrorPrimaryDark,\n statusErrorText: tokens.textColorStatusErrorDark,\n statusErrorBorder: tokens.borderColorStatusErrorDark,\n statusErrorFill: tokens.fillColorStatusErrorSolidDark,\n\n // Note: CCA inverts composed status colors in dark mode\n statusInfoComposedIcon: tokens.iconColorStatusInfoPrimaryDark,\n statusInfoComposedText: tokens.textColorStatusInfoDark,\n statusInfoComposedBackground: tokens.fillColorStatusInfoGhostDark,\n statusSuccessComposedIcon: tokens.iconColorStatusSuccessPrimaryDark,\n statusSuccessComposedText: tokens.textColorStatusSuccessDark,\n statusSuccessComposedBackground: tokens.fillColorStatusSuccessGhostDark,\n statusWarningComposedIcon: tokens.iconColorStatusWarningPrimaryDark,\n statusWarningComposedText: tokens.textColorStatusWarningDark,\n statusWarningComposedBackground: tokens.fillColorStatusWarningGhostDark,\n statusErrorComposedIcon: tokens.iconColorStatusErrorPrimaryDark,\n statusErrorComposedText: tokens.textColorStatusErrorDark,\n statusErrorComposedBackground: tokens.fillColorStatusErrorGhostDark,\n statusNeutralComposedIcon: tokens.iconColorStatusNeutralPrimaryDark,\n statusNeutralComposedText: tokens.textColorStatusNeutralDark,\n statusNeutralComposedBackground: tokens.fillColorStatusNeutralGhostDark,\n}\n\nconst chatThemeColorMap = {\n light: colorsChatLight,\n dark: colorsChatDark,\n}\n"]}
|
|
1
|
+
{"version":3,"file":"theme.js","sourceRoot":"","sources":["../../src/utils/theme.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAA;AAE5C,OAAO,EAAE,mBAAmB,EAAE,MAAM,2CAA2C,CAAA;AAC/E,OAAO,EAAE,MA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;IACtB,IAAI,EAAE,cAAc;CACrB,CAAA","sourcesContent":["import { PlatformColor } from 'react-native'\nimport type { ColorSchemeName, ColorValue, OpaqueColorValue } from 'react-native'\nimport { aliasTokensColorMap } from '../vendor/tapestry/alias_tokens_color_map'\nimport { tokens } from '../vendor/tapestry/tokens'\n\nexport interface ChatTheme extends DefaultTheme {\n colors: DefaultTheme['colors'] &\n (typeof aliasTokensColorMap.light | typeof aliasTokensColorMap.dark)\n}\n\n/** =============================================\n NOTE: The specific values for `colors` and the `productBadge` are temporary examples that can be replaced once we start building out UI. This line's comment can be removed at that time too.\n\n The default theme is intended to support two types of customizations:\n 1. Specific color properties for a chat component (eg. `primaryButtonBackgroundColor`)\n 2. Any styles for a specific component. (Use only one level of nesting.)\n ```\n primaryButton: {\n borderRadius: number\n container: ViewStyle\n text: TextStyle\n }\n ```\n============================================= */\n\nexport interface DefaultTheme {\n colors: ChatColors\n button: {\n borderRadius: number\n }\n showBadgeProductLogo: boolean\n}\n\nexport const defaultTheme = (colorScheme: ColorSchemeName | null): ChatTheme => {\n const scheme: 'light' | 'dark' = colorScheme === 'dark' ? 'dark' : 'light'\n\n const defaultColors = {\n ...chatThemeColorMap[scheme],\n ...aliasTokensColorMap[scheme],\n }\n\n return {\n colors: defaultColors,\n button: {\n borderRadius: 40,\n },\n showBadgeProductLogo: true, // Overrides visibility of the product logo in `src/display/badge.tsx`\n }\n}\n\nexport type TemporaryDefaultColorsType = Partial<ChatColors>\n\ninterface ChatColors {\n name: string\n buttonStart: string | undefined\n buttonEnd: string | undefined\n interaction: string\n androidModalHeaderButtonTextColor: ColorValue | string | undefined\n iOSModalHeaderButtonTextColor: OpaqueColorValue | string | undefined\n androidSwitchThumbColor: string | undefined\n conversationActionsBackground: string\n testColor: string\n statusSuccessIcon: string\n statusSuccessText: string\n statusSuccessBorder: string\n statusSuccessFill: string\n statusInfoIcon: string\n statusInfoText: string\n statusInfoBorder: string\n statusInfoFill: string\n statusWarningIcon: string\n statusWarningText: string\n statusWarningBorder: string\n statusWarningFill: string\n statusErrorIcon: string\n statusErrorText: string\n statusErrorBorder: string\n statusErrorFill: string\n statusSuccessComposedIcon: string\n statusSuccessComposedText: string\n statusSuccessComposedBackground: string\n statusInfoComposedIcon: string\n statusInfoComposedText: string\n statusInfoComposedBackground: string\n statusWarningComposedIcon: string\n statusWarningComposedText: string\n statusWarningComposedBackground: string\n statusErrorComposedIcon: string\n statusErrorComposedText: string\n statusErrorComposedBackground: string\n statusNeutralComposedIcon: string\n statusNeutralComposedText: string\n statusNeutralComposedBackground: string\n}\n\nconst colorsChatLight: ChatColors = {\n name: 'light',\n androidModalHeaderButtonTextColor: tokens.fillColorInteractionDefault,\n iOSModalHeaderButtonTextColor: PlatformColor('link'),\n buttonStart: undefined,\n buttonEnd: undefined,\n interaction: tokens.fillColorInteractionDefault,\n androidSwitchThumbColor: undefined,\n conversationActionsBackground: tokens.colorNeutral100White,\n testColor: 'hotpink',\n statusInfoIcon: tokens.iconColorStatusInfoPrimary,\n statusInfoText: tokens.textColorStatusInfo,\n statusInfoBorder: tokens.borderColorStatusInfo,\n statusInfoFill: tokens.fillColorStatusInfoSolid,\n statusSuccessIcon: tokens.iconColorStatusSuccessPrimary,\n statusSuccessText: tokens.textColorStatusSuccess,\n statusSuccessBorder: tokens.borderColorStatusSuccess,\n statusSuccessFill: tokens.fillColorStatusSuccessSolid,\n statusWarningIcon: tokens.iconColorStatusWarningPrimary,\n statusWarningText: tokens.textColorStatusWarning,\n statusWarningBorder: tokens.borderColorStatusWarning,\n statusWarningFill: tokens.fillColorStatusWarningSolid,\n statusErrorIcon: tokens.iconColorStatusErrorPrimary,\n statusErrorText: tokens.textColorStatusError,\n statusErrorBorder: tokens.borderColorStatusError,\n statusErrorFill: tokens.fillColorStatusErrorSolid,\n statusInfoComposedIcon: tokens.iconColorStatusInfoPrimary,\n statusInfoComposedText: tokens.textColorStatusInfo,\n statusInfoComposedBackground: tokens.fillColorStatusInfoGhost,\n statusSuccessComposedIcon: tokens.iconColorStatusSuccessPrimary,\n statusSuccessComposedText: tokens.textColorStatusSuccess,\n statusSuccessComposedBackground: tokens.fillColorStatusSuccessGhost,\n statusWarningComposedIcon: tokens.iconColorStatusWarningPrimary,\n statusWarningComposedText: tokens.textColorStatusWarning,\n statusWarningComposedBackground: tokens.fillColorStatusWarningGhost,\n statusErrorComposedIcon: tokens.iconColorStatusErrorPrimary,\n statusErrorComposedText: tokens.textColorStatusError,\n statusErrorComposedBackground: tokens.fillColorStatusErrorGhost,\n statusNeutralComposedIcon: tokens.iconColorStatusNeutralPrimary,\n statusNeutralComposedText: tokens.textColorStatusNeutral,\n statusNeutralComposedBackground: tokens.fillColorStatusNeutralGhost,\n}\n\nconst colorsChatDark: ChatColors = {\n name: 'dark',\n androidModalHeaderButtonTextColor: tokens.fillColorInteractionDefaultDark,\n iOSModalHeaderButtonTextColor: PlatformColor('link'),\n buttonStart: undefined,\n buttonEnd: undefined,\n interaction: tokens.fillColorInteractionDefaultDark,\n androidSwitchThumbColor: undefined,\n conversationActionsBackground: tokens.colorNeutral7,\n testColor: 'pink',\n statusInfoIcon: tokens.iconColorStatusInfoPrimaryDark,\n statusInfoText: tokens.textColorStatusInfoDark,\n statusInfoBorder: tokens.borderColorStatusInfoDark,\n statusInfoFill: tokens.fillColorStatusInfoSolidDark,\n statusSuccessIcon: tokens.iconColorStatusSuccessPrimaryDark,\n statusSuccessText: tokens.textColorStatusSuccessDark,\n statusSuccessBorder: tokens.borderColorStatusSuccessDark,\n statusSuccessFill: tokens.fillColorStatusSuccessSolidDark,\n statusWarningIcon: tokens.iconColorStatusWarningPrimaryDark,\n statusWarningText: tokens.textColorStatusWarningDark,\n statusWarningBorder: tokens.borderColorStatusWarningDark,\n statusWarningFill: tokens.fillColorStatusWarningSolidDark,\n statusErrorIcon: tokens.iconColorStatusErrorPrimaryDark,\n statusErrorText: tokens.textColorStatusErrorDark,\n statusErrorBorder: tokens.borderColorStatusErrorDark,\n statusErrorFill: tokens.fillColorStatusErrorSolidDark,\n\n // Note: CCA inverts composed status colors in dark mode\n statusInfoComposedIcon: tokens.iconColorStatusInfoPrimaryDark,\n statusInfoComposedText: tokens.textColorStatusInfoDark,\n statusInfoComposedBackground: tokens.fillColorStatusInfoGhostDark,\n statusSuccessComposedIcon: tokens.iconColorStatusSuccessPrimaryDark,\n statusSuccessComposedText: tokens.textColorStatusSuccessDark,\n statusSuccessComposedBackground: tokens.fillColorStatusSuccessGhostDark,\n statusWarningComposedIcon: tokens.iconColorStatusWarningPrimaryDark,\n statusWarningComposedText: tokens.textColorStatusWarningDark,\n statusWarningComposedBackground: tokens.fillColorStatusWarningGhostDark,\n statusErrorComposedIcon: tokens.iconColorStatusErrorPrimaryDark,\n statusErrorComposedText: tokens.textColorStatusErrorDark,\n statusErrorComposedBackground: tokens.fillColorStatusErrorGhostDark,\n statusNeutralComposedIcon: tokens.iconColorStatusNeutralPrimaryDark,\n statusNeutralComposedText: tokens.textColorStatusNeutralDark,\n statusNeutralComposedBackground: tokens.fillColorStatusNeutralGhostDark,\n}\n\nconst chatThemeColorMap = {\n light: colorsChatLight,\n dark: colorsChatDark,\n}\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@planningcenter/chat-react-native",
|
|
3
|
-
"version": "3.42.2-qa-
|
|
3
|
+
"version": "3.42.2-qa-821.1",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "build/index.js",
|
|
6
6
|
"react-native": "./src/index.tsx",
|
|
@@ -16,17 +16,17 @@
|
|
|
16
16
|
"./build/icons/font_awesome.js"
|
|
17
17
|
],
|
|
18
18
|
"scripts": {
|
|
19
|
-
"build": "expo-module build",
|
|
19
|
+
"build": "expo-module build --project tsconfig.build.json",
|
|
20
20
|
"clean": "expo-module clean",
|
|
21
21
|
"lint": "expo-module lint",
|
|
22
22
|
"test": "expo-module test",
|
|
23
|
-
"prepublishOnly": "expo-module
|
|
23
|
+
"prepublishOnly": "expo-module clean && expo-module build --project tsconfig.build.json"
|
|
24
24
|
},
|
|
25
25
|
"target": "18",
|
|
26
26
|
"dependencies": {
|
|
27
27
|
"@fortawesome/fontawesome-svg-core": "^7.2.0",
|
|
28
28
|
"@fortawesome/react-native-fontawesome": "^0.3.2",
|
|
29
|
-
"@planningcenter/emoji-keyboard": "3.42.2-qa-
|
|
29
|
+
"@planningcenter/emoji-keyboard": "3.42.2-qa-821.1",
|
|
30
30
|
"lodash-inflection": "^1.5.0",
|
|
31
31
|
"react-compiler-runtime": "^1.0.0"
|
|
32
32
|
},
|
|
@@ -52,25 +52,25 @@
|
|
|
52
52
|
"react-native-svg": "*"
|
|
53
53
|
},
|
|
54
54
|
"devDependencies": {
|
|
55
|
-
"@react-native/eslint-config": "~0.
|
|
55
|
+
"@react-native/eslint-config": "~0.86.0",
|
|
56
56
|
"@testing-library/react-native": "^13.2.0",
|
|
57
57
|
"@types/color": "^3.0.0",
|
|
58
58
|
"@types/jest": "^29.5.14",
|
|
59
|
-
"@typescript-eslint/parser": "^8.
|
|
59
|
+
"@typescript-eslint/parser": "^8.63.0",
|
|
60
60
|
"color": "^3.1.2",
|
|
61
61
|
"eslint": "8.57.1",
|
|
62
62
|
"eslint-plugin-react-compiler": "^19.1.0-rc.2",
|
|
63
|
-
"expo-module-scripts": "^
|
|
63
|
+
"expo-module-scripts": "^56.0.3",
|
|
64
64
|
"fast-text-encoding": "^1.0.6",
|
|
65
65
|
"jest": "^29.7.0",
|
|
66
66
|
"jest-fetch-mock": "^3.0.3",
|
|
67
67
|
"msw": "^2.7.3",
|
|
68
68
|
"prettier": "^3.4.2",
|
|
69
|
-
"react": "19.2.
|
|
70
|
-
"react-native": "0.
|
|
71
|
-
"react-native-svg": "15.15.
|
|
69
|
+
"react": "19.2.3",
|
|
70
|
+
"react-native": "0.86.0",
|
|
71
|
+
"react-native-svg": "15.15.4",
|
|
72
72
|
"react-native-url-polyfill": "^2.0.0",
|
|
73
|
-
"typescript": "~
|
|
73
|
+
"typescript": "~6.0.3"
|
|
74
74
|
},
|
|
75
|
-
"gitHead": "
|
|
75
|
+
"gitHead": "ecac801039c37ab8ca4d5f07f6056fb60bbf862a"
|
|
76
76
|
}
|
|
@@ -38,6 +38,7 @@ const createWrapper = () => {
|
|
|
38
38
|
const setChatConfiguration = (overrides: Partial<ReturnType<typeof useChatConfiguration>> = {}) => {
|
|
39
39
|
mockedUseChatConfiguration.mockReturnValue({
|
|
40
40
|
allowedFileExtensions: ['.pdf', '.jpg'],
|
|
41
|
+
allowedMimeTypes: [],
|
|
41
42
|
maxFileSizeInBytes: 50 * 1024 * 1024,
|
|
42
43
|
maxAttachmentsPerMessage: 10,
|
|
43
44
|
...overrides,
|
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
import { renderHook } from '@testing-library/react-native'
|
|
2
2
|
import { useFontScale } from '../../hooks/use_font_scale'
|
|
3
3
|
|
|
4
|
-
jest.mock('react-native', () =>
|
|
5
|
-
|
|
6
|
-
|
|
4
|
+
jest.mock('react-native', () => {
|
|
5
|
+
const actual = jest.requireActual('react-native')
|
|
6
|
+
return Object.defineProperty(actual, 'useWindowDimensions', {
|
|
7
|
+
value: jest.fn(),
|
|
8
|
+
configurable: true,
|
|
9
|
+
})
|
|
10
|
+
})
|
|
7
11
|
|
|
8
12
|
const mockUseWindowDimensions = require('react-native').useWindowDimensions
|
|
9
13
|
const DEFAULT_NATIVE_FONT_SCALE = 1
|
|
@@ -113,7 +113,7 @@ describe('ChatAdapters', () => {
|
|
|
113
113
|
describe('document picker adapter', () => {
|
|
114
114
|
it('uses the configured adapter when provided', () => {
|
|
115
115
|
const documentPicker = new DocumentPickerAdapter({
|
|
116
|
-
openAsync: jest.fn(async () => ({ canceled: true, assets: null })),
|
|
116
|
+
openAsync: jest.fn(async () => ({ canceled: true as true, assets: null })),
|
|
117
117
|
})
|
|
118
118
|
|
|
119
119
|
ChatAdapters.configure({
|
|
@@ -11,7 +11,7 @@ const makeMessage = (overrides: Partial<MessageResource> = {}): MessageResource
|
|
|
11
11
|
textEditedAt: null,
|
|
12
12
|
mine: false,
|
|
13
13
|
attachments: [],
|
|
14
|
-
author: { id: -1, name: 'System', avatar: '' },
|
|
14
|
+
author: { id: -1, type: 'Person', name: 'System', avatar: '' },
|
|
15
15
|
reactionCounts: [],
|
|
16
16
|
replyCount: 0,
|
|
17
17
|
replyRootId: null,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Uri } from '../../utils'
|
|
1
|
+
import { Session, Uri } from '../../utils'
|
|
2
2
|
|
|
3
3
|
describe('URI', () => {
|
|
4
4
|
it('should be defined', () => {
|
|
@@ -7,13 +7,7 @@ describe('URI', () => {
|
|
|
7
7
|
|
|
8
8
|
it('should create a new instance', () => {
|
|
9
9
|
const uri = new Uri({
|
|
10
|
-
session: {
|
|
11
|
-
env: 'production',
|
|
12
|
-
token: undefined,
|
|
13
|
-
type: 'OAuth',
|
|
14
|
-
isAuthenticated: false,
|
|
15
|
-
isChurchCenterToken: false,
|
|
16
|
-
},
|
|
10
|
+
session: new Session({ env: 'production', type: 'OAuth' }),
|
|
17
11
|
})
|
|
18
12
|
expect(uri).toBeDefined()
|
|
19
13
|
})
|
|
@@ -22,39 +16,21 @@ describe('URI', () => {
|
|
|
22
16
|
describe('planning center', () => {
|
|
23
17
|
it('should return the correct base URL for production', () => {
|
|
24
18
|
const uri = new Uri({
|
|
25
|
-
session: {
|
|
26
|
-
env: 'production',
|
|
27
|
-
token: undefined,
|
|
28
|
-
type: 'OAuth',
|
|
29
|
-
isAuthenticated: false,
|
|
30
|
-
isChurchCenterToken: false,
|
|
31
|
-
},
|
|
19
|
+
session: new Session({ env: 'production', type: 'OAuth' }),
|
|
32
20
|
})
|
|
33
21
|
expect(uri.baseUrl).toBe('https://api.planningcenteronline.com')
|
|
34
22
|
})
|
|
35
23
|
|
|
36
24
|
it('should return the correct base URL for staging', () => {
|
|
37
25
|
const uri = new Uri({
|
|
38
|
-
session: {
|
|
39
|
-
env: 'staging',
|
|
40
|
-
token: undefined,
|
|
41
|
-
type: 'OAuth',
|
|
42
|
-
isAuthenticated: false,
|
|
43
|
-
isChurchCenterToken: false,
|
|
44
|
-
},
|
|
26
|
+
session: new Session({ env: 'staging', type: 'OAuth' }),
|
|
45
27
|
})
|
|
46
28
|
expect(uri.baseUrl).toBe('https://api-staging.planningcenteronline.com')
|
|
47
29
|
})
|
|
48
30
|
|
|
49
31
|
it('should return the correct base URL for development', () => {
|
|
50
32
|
const uri = new Uri({
|
|
51
|
-
session: {
|
|
52
|
-
env: 'development',
|
|
53
|
-
token: undefined,
|
|
54
|
-
type: 'OAuth',
|
|
55
|
-
isAuthenticated: false,
|
|
56
|
-
isChurchCenterToken: false,
|
|
57
|
-
},
|
|
33
|
+
session: new Session({ env: 'development', type: 'OAuth' }),
|
|
58
34
|
})
|
|
59
35
|
expect(uri.baseUrl).toBe('https://api.pco.test')
|
|
60
36
|
})
|
|
@@ -63,13 +39,7 @@ describe('URI', () => {
|
|
|
63
39
|
describe('church center', () => {
|
|
64
40
|
it('should return the correct base URL for production', () => {
|
|
65
41
|
const uri = new Uri({
|
|
66
|
-
session: {
|
|
67
|
-
env: 'production',
|
|
68
|
-
token: undefined,
|
|
69
|
-
type: 'ChurchCenterOauth',
|
|
70
|
-
isAuthenticated: false,
|
|
71
|
-
isChurchCenterToken: true,
|
|
72
|
-
},
|
|
42
|
+
session: new Session({ env: 'production', type: 'ChurchCenterOauth' }),
|
|
73
43
|
graph: 'churchcenter',
|
|
74
44
|
})
|
|
75
45
|
expect(uri.baseUrl).toBe('https://api.churchcenter.com')
|
|
@@ -77,13 +47,7 @@ describe('URI', () => {
|
|
|
77
47
|
|
|
78
48
|
it('should return the correct base URL for staging', () => {
|
|
79
49
|
const uri = new Uri({
|
|
80
|
-
session: {
|
|
81
|
-
env: 'staging',
|
|
82
|
-
token: undefined,
|
|
83
|
-
type: 'ChurchCenterOauth',
|
|
84
|
-
isAuthenticated: false,
|
|
85
|
-
isChurchCenterToken: true,
|
|
86
|
-
},
|
|
50
|
+
session: new Session({ env: 'staging', type: 'ChurchCenterOauth' }),
|
|
87
51
|
graph: 'churchcenter',
|
|
88
52
|
})
|
|
89
53
|
expect(uri.baseUrl).toBe('https://api.staging.churchcenter.com')
|
|
@@ -91,13 +55,7 @@ describe('URI', () => {
|
|
|
91
55
|
|
|
92
56
|
it('should return the correct base URL for development', () => {
|
|
93
57
|
const uri = new Uri({
|
|
94
|
-
session: {
|
|
95
|
-
env: 'development',
|
|
96
|
-
token: undefined,
|
|
97
|
-
type: 'ChurchCenterOauth',
|
|
98
|
-
isAuthenticated: false,
|
|
99
|
-
isChurchCenterToken: true,
|
|
100
|
-
},
|
|
58
|
+
session: new Session({ env: 'development', type: 'ChurchCenterOauth' }),
|
|
101
59
|
graph: 'churchcenter',
|
|
102
60
|
})
|
|
103
61
|
expect(uri.baseUrl).toBe('https://api.churchcenter.test')
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { http, HttpResponse } from 'msw'
|
|
2
|
-
import { JSONAPIResponse } from '../types'
|
|
1
|
+
import { http, HttpResponse, type JsonBodyType } from 'msw'
|
|
3
2
|
import DefaultFixtures from './fixtures/defaults'
|
|
4
3
|
|
|
5
4
|
export const BASE_URL = 'https://api.pco.test/chat/v2'
|
|
@@ -13,25 +12,25 @@ export const handlers = [
|
|
|
13
12
|
del(BASE_URL + '/records/:id'),
|
|
14
13
|
]
|
|
15
14
|
|
|
16
|
-
function get(url: string, mockedResponse:
|
|
15
|
+
function get(url: string, mockedResponse: JsonBodyType, mockedStatus: number = 200) {
|
|
17
16
|
return http.get(url, () => {
|
|
18
17
|
return HttpResponse.json(mockedResponse, { status: mockedStatus })
|
|
19
18
|
})
|
|
20
19
|
}
|
|
21
20
|
|
|
22
|
-
function post(url: string, mockedResponse:
|
|
21
|
+
function post(url: string, mockedResponse: JsonBodyType, mockedStatus: number = 200) {
|
|
23
22
|
return http.post(url, () => {
|
|
24
23
|
return HttpResponse.json(mockedResponse, { status: mockedStatus })
|
|
25
24
|
})
|
|
26
25
|
}
|
|
27
26
|
|
|
28
|
-
function del(url: string, mockedResponse?:
|
|
27
|
+
function del(url: string, mockedResponse?: JsonBodyType, mockedStatus: number = 200) {
|
|
29
28
|
return http.delete(url, () => {
|
|
30
29
|
return HttpResponse.json(mockedResponse, { status: mockedStatus })
|
|
31
30
|
})
|
|
32
31
|
}
|
|
33
32
|
|
|
34
|
-
function patch(url: string, mockedResponse:
|
|
33
|
+
function patch(url: string, mockedResponse: JsonBodyType, mockedStatus: number = 200) {
|
|
35
34
|
return http.patch(url, () => {
|
|
36
35
|
return HttpResponse.json(mockedResponse, { status: mockedStatus })
|
|
37
36
|
})
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import React from 'react'
|
|
2
1
|
import { View, StyleSheet } from 'react-native'
|
|
3
2
|
import { useTheme } from '../../../hooks'
|
|
4
3
|
import { Spinner } from '../../display'
|
|
@@ -19,14 +18,22 @@ const useStyles = () => {
|
|
|
19
18
|
|
|
20
19
|
return StyleSheet.create({
|
|
21
20
|
container: {
|
|
22
|
-
|
|
21
|
+
position: 'absolute',
|
|
22
|
+
top: 0,
|
|
23
|
+
left: 0,
|
|
24
|
+
right: 0,
|
|
25
|
+
bottom: 0,
|
|
23
26
|
justifyContent: 'center',
|
|
24
27
|
alignItems: 'center',
|
|
25
28
|
borderRadius: 8,
|
|
26
29
|
overflow: 'hidden',
|
|
27
30
|
},
|
|
28
31
|
overlay: {
|
|
29
|
-
|
|
32
|
+
position: 'absolute',
|
|
33
|
+
top: 0,
|
|
34
|
+
left: 0,
|
|
35
|
+
right: 0,
|
|
36
|
+
bottom: 0,
|
|
30
37
|
backgroundColor: colors.fillColorNeutral070,
|
|
31
38
|
opacity: 0.5,
|
|
32
39
|
},
|