stream-chat-react-native-core 5.26.0-beta.7 → 5.26.1-beta.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.
Files changed (63) hide show
  1. package/lib/commonjs/components/ChannelPreview/ChannelPreviewMessenger.js +2 -1
  2. package/lib/commonjs/components/ChannelPreview/ChannelPreviewMessenger.js.map +1 -1
  3. package/lib/commonjs/components/ChannelPreview/ChannelPreviewStatus.js +4 -4
  4. package/lib/commonjs/components/ChannelPreview/ChannelPreviewStatus.js.map +1 -1
  5. package/lib/commonjs/i18n/en.json +1 -1
  6. package/lib/commonjs/i18n/es.json +36 -36
  7. package/lib/commonjs/i18n/fr.json +36 -36
  8. package/lib/commonjs/i18n/he.json +36 -36
  9. package/lib/commonjs/i18n/hi.json +36 -36
  10. package/lib/commonjs/i18n/it.json +36 -36
  11. package/lib/commonjs/i18n/ja.json +36 -36
  12. package/lib/commonjs/i18n/ko.json +36 -36
  13. package/lib/commonjs/i18n/nl.json +35 -35
  14. package/lib/commonjs/i18n/pt-BR.json +35 -35
  15. package/lib/commonjs/i18n/ru.json +35 -35
  16. package/lib/commonjs/i18n/tr.json +35 -35
  17. package/lib/commonjs/version.json +1 -1
  18. package/lib/module/components/ChannelPreview/ChannelPreviewMessenger.js +2 -1
  19. package/lib/module/components/ChannelPreview/ChannelPreviewMessenger.js.map +1 -1
  20. package/lib/module/components/ChannelPreview/ChannelPreviewStatus.js +4 -4
  21. package/lib/module/components/ChannelPreview/ChannelPreviewStatus.js.map +1 -1
  22. package/lib/module/i18n/en.json +1 -1
  23. package/lib/module/i18n/es.json +36 -36
  24. package/lib/module/i18n/fr.json +36 -36
  25. package/lib/module/i18n/he.json +36 -36
  26. package/lib/module/i18n/hi.json +36 -36
  27. package/lib/module/i18n/it.json +36 -36
  28. package/lib/module/i18n/ja.json +36 -36
  29. package/lib/module/i18n/ko.json +36 -36
  30. package/lib/module/i18n/nl.json +35 -35
  31. package/lib/module/i18n/pt-BR.json +35 -35
  32. package/lib/module/i18n/ru.json +35 -35
  33. package/lib/module/i18n/tr.json +35 -35
  34. package/lib/module/version.json +1 -1
  35. package/lib/typescript/components/ChannelPreview/ChannelPreviewStatus.d.ts +2 -1
  36. package/lib/typescript/i18n/en.json +1 -1
  37. package/lib/typescript/i18n/es.json +36 -36
  38. package/lib/typescript/i18n/fr.json +36 -36
  39. package/lib/typescript/i18n/he.json +36 -36
  40. package/lib/typescript/i18n/hi.json +36 -36
  41. package/lib/typescript/i18n/it.json +36 -36
  42. package/lib/typescript/i18n/ja.json +36 -36
  43. package/lib/typescript/i18n/ko.json +36 -36
  44. package/lib/typescript/i18n/nl.json +35 -35
  45. package/lib/typescript/i18n/pt-BR.json +35 -35
  46. package/lib/typescript/i18n/ru.json +35 -35
  47. package/lib/typescript/i18n/tr.json +35 -35
  48. package/package.json +1 -1
  49. package/src/components/ChannelPreview/ChannelPreviewMessenger.tsx +1 -0
  50. package/src/components/ChannelPreview/ChannelPreviewStatus.tsx +3 -1
  51. package/src/i18n/en.json +1 -1
  52. package/src/i18n/es.json +36 -36
  53. package/src/i18n/fr.json +36 -36
  54. package/src/i18n/he.json +36 -36
  55. package/src/i18n/hi.json +36 -36
  56. package/src/i18n/it.json +36 -36
  57. package/src/i18n/ja.json +36 -36
  58. package/src/i18n/ko.json +36 -36
  59. package/src/i18n/nl.json +35 -35
  60. package/src/i18n/pt-BR.json +35 -35
  61. package/src/i18n/ru.json +35 -35
  62. package/src/i18n/tr.json +35 -35
  63. package/src/version.json +1 -1
@@ -4,31 +4,31 @@
4
4
  "Allow access to your Gallery": "Permitir acesso à sua Galeria",
5
5
  "Allow camera access in device settings": "Permitir acesso à câmera nas configurações do dispositivo",
6
6
  "Also send to channel": "",
7
- "Are you sure you want to permanently delete this message?": "",
8
- "Are you sure?": "",
9
- "Block User": "",
10
- "Cancel": "",
11
- "Cannot Flag Message": "",
12
- "Consider how your comment might make others feel and be sure to follow our Community Guidelines": "",
13
- "Copy Message": "",
14
- "Delete": "",
15
- "Delete Message": "",
7
+ "Are you sure you want to permanently delete this message?": "Tem certeza de que deseja excluir esta mensagem permanentemente?",
8
+ "Are you sure?": "Tem certeza?",
9
+ "Block User": "Bloquear Usuário",
10
+ "Cancel": "Cancelar",
11
+ "Cannot Flag Message": "Não é possível reportar a mensagem",
12
+ "Consider how your comment might make others feel and be sure to follow our Community Guidelines": "Considere como seu comentário pode fazer os outros se sentirem e certifique-se de seguir nossas Diretrizes da Comunidade",
13
+ "Copy Message": "Copiar Mensagem",
14
+ "Delete": "Excluir",
15
+ "Delete Message": "Excluir Mensagem",
16
16
  "Device camera is used to take photos or videos.": "A câmera do dispositivo é usada para tirar fotos ou vídeos.",
17
- "Do you want to send a copy of this message to a moderator for further investigation?": "",
18
- "Edit Message": "",
17
+ "Do you want to send a copy of this message to a moderator for further investigation?": "Deseja enviar uma cópia desta mensagem para um moderador para investigação adicional?",
18
+ "Edit Message": "Editar Mensagem",
19
19
  "Editing Message": "",
20
- "Emoji matching": "Correspondência de Emoji",
20
+ "Emoji matching": "",
21
21
  "Empty message...": "",
22
22
  "Error loading": "",
23
23
  "Error loading channel list...": "",
24
24
  "Error loading messages for this channel...": "",
25
25
  "Error while loading, please reload/refresh": "",
26
- "File type not supported": "",
27
- "Flag": "",
28
- "Flag Message": "",
29
- "Flag action failed either due to a network issue or the message is already flagged": "",
26
+ "File type not supported": "Tipo de arquivo não suportado",
27
+ "Flag": "Reportar",
28
+ "Flag Message": "Reportar Mensagem",
29
+ "Flag action failed either due to a network issue or the message is already flagged": "A ação para reportar a mensagem falhou devido a um problema de rede ou a mensagem já foi reportada.",
30
30
  "How about sending your first message to a friend?": "",
31
- "Instant Commands": "Comandos Instantâneos",
31
+ "Instant Commands": "",
32
32
  "Let's start chatting!": "",
33
33
  "Links are disabled": "",
34
34
  "Loading channels...": "",
@@ -37,43 +37,43 @@
37
37
  "Maximum file size upload limit reached. Please upload a file below {{MAX_FILE_SIZE_TO_UPLOAD_IN_MB}} MB.": "",
38
38
  "Message Reactions": "",
39
39
  "Message deleted": "",
40
- "Message flagged": "",
41
- "Mute User": "",
42
- "Not supported": "",
40
+ "Message flagged": "Mensagem sinalizada",
41
+ "Mute User": "Silenciar Usuário",
42
+ "Not supported": "Não suportado",
43
43
  "Nothing yet...": "",
44
- "Ok": "",
44
+ "Ok": "Ok",
45
45
  "Only visible to you": "",
46
46
  "Open Settings": "Abrir Configurações",
47
- "Photo": "Foto",
47
+ "Photo": "",
48
48
  "Photos and Videos": "Fotos e Vídeos",
49
- "Pin to Conversation": "",
49
+ "Pin to Conversation": "Fixar na Conversa",
50
50
  "Pinned by": "",
51
51
  "Please enable access to your photos and videos so you can share them.": "Por favor, habilite o acesso às suas fotos e vídeos para poder compartilhá-los.",
52
52
  "Please select a channel first": "",
53
53
  "Reconnecting...": "",
54
- "Reply": "",
54
+ "Reply": "Responder",
55
55
  "Reply to Message": "",
56
- "Resend": "",
56
+ "Resend": "Reenviar",
57
57
  "Search GIFs": "",
58
58
  "Select More Photos": "Selecionar Mais Fotos",
59
- "Send Anyway": "",
59
+ "Send Anyway": "Enviar de qualquer maneira",
60
60
  "Send a message": "",
61
61
  "Sending links is not allowed in this conversation": "",
62
62
  "Slow mode ON": "",
63
- "The message has been reported to a moderator.": "",
64
- "Thread Reply": "",
65
- "Unblock User": "",
63
+ "The message has been reported to a moderator.": "A mensagem foi relatada a um moderador.",
64
+ "Thread Reply": "Respostas de Tópico",
65
+ "Unblock User": "Desbloquear Usuário",
66
66
  "Unknown User": "Usuário Desconhecido",
67
- "Unmute User": "",
68
- "Unpin from Conversation": "",
69
- "Unread Messages": "",
70
- "Video": "Vídeo",
67
+ "Unmute User": "Remover usuário do modo silencioso",
68
+ "Unpin from Conversation": "Desmarcar como fixado na conversa",
69
+ "Unread Messages": "Mensagens não lidas",
70
+ "Video": "",
71
71
  "You": "",
72
72
  "You can't send messages in this channel": "",
73
- "{{ firstUser }} and {{ nonSelfUserLength }} more are typing": "{{ firstUser }} e mais {{ nonSelfUserLength }} pessoa(s) estão digitando",
73
+ "{{ firstUser }} and {{ nonSelfUserLength }} more are typing": "",
74
74
  "{{ index }} of {{ photoLength }}": "{{ index }} de {{ photoLength }}",
75
75
  "{{ replyCount }} Replies": "{{ replyCount }} Respostas",
76
76
  "{{ replyCount }} Thread Replies": "",
77
- "{{ user }} is typing": "{{ user }} está digitando",
77
+ "{{ user }} is typing": "",
78
78
  "🏙 Attachment...": ""
79
79
  }
@@ -4,31 +4,31 @@
4
4
  "Allow access to your Gallery": "Разрешить доступ к вашей галерее",
5
5
  "Allow camera access in device settings": "Разрешите доступ к камере в настройках устройства.",
6
6
  "Also send to channel": "",
7
- "Are you sure you want to permanently delete this message?": "",
8
- "Are you sure?": "",
9
- "Block User": "",
10
- "Cancel": "",
11
- "Cannot Flag Message": "",
12
- "Consider how your comment might make others feel and be sure to follow our Community Guidelines": "",
13
- "Copy Message": "",
14
- "Delete": "",
15
- "Delete Message": "",
7
+ "Are you sure you want to permanently delete this message?": "Вы действительно хотите удалить это сообщение без возможности восстановления?",
8
+ "Are you sure?": "Вы уверены?",
9
+ "Block User": "Заблокировать пользователя",
10
+ "Cancel": "Отмена",
11
+ "Cannot Flag Message": "Невозможно пожаловаться на сообщение",
12
+ "Consider how your comment might make others feel and be sure to follow our Community Guidelines": "Обдумайте, как ваш комментарий может повлиять на других, и убедитесь, что вы следуете нашим правилам сообщества",
13
+ "Copy Message": "Копировать сообщение",
14
+ "Delete": "удалять",
15
+ "Delete Message": "Удалить сообщение",
16
16
  "Device camera is used to take photos or videos.": "Камера устройства используется для съемки фотографий или видео.",
17
- "Do you want to send a copy of this message to a moderator for further investigation?": "",
18
- "Edit Message": "",
17
+ "Do you want to send a copy of this message to a moderator for further investigation?": "Вы хотите отправить копию этого сообщения модератору для дальнейшего изучения?",
18
+ "Edit Message": "Редактировать сообщение",
19
19
  "Editing Message": "",
20
- "Emoji matching": "Соответствие эмодзи",
20
+ "Emoji matching": "",
21
21
  "Empty message...": "",
22
22
  "Error loading": "",
23
23
  "Error loading channel list...": "",
24
24
  "Error loading messages for this channel...": "",
25
25
  "Error while loading, please reload/refresh": "",
26
- "File type not supported": "",
27
- "Flag": "",
28
- "Flag Message": "",
29
- "Flag action failed either due to a network issue or the message is already flagged": "",
26
+ "File type not supported": "Тип файла не поддерживается",
27
+ "Flag": "Пометить",
28
+ "Flag Message": "Пометить сообщение",
29
+ "Flag action failed either due to a network issue or the message is already flagged": "Не удалось отправить жалобу. Возможные причины: проблема с подключением к интернету или ваша жалоба уже была принята.",
30
30
  "How about sending your first message to a friend?": "",
31
- "Instant Commands": "Мгновенные Команды",
31
+ "Instant Commands": "",
32
32
  "Let's start chatting!": "",
33
33
  "Links are disabled": "",
34
34
  "Loading channels...": "",
@@ -37,43 +37,43 @@
37
37
  "Maximum file size upload limit reached. Please upload a file below {{MAX_FILE_SIZE_TO_UPLOAD_IN_MB}} MB.": "",
38
38
  "Message Reactions": "",
39
39
  "Message deleted": "",
40
- "Message flagged": "",
41
- "Mute User": "",
42
- "Not supported": "",
40
+ "Message flagged": "Сообщение отмечено",
41
+ "Mute User": "Отключить пользователя",
42
+ "Not supported": "не поддерживается",
43
43
  "Nothing yet...": "",
44
- "Ok": "",
44
+ "Ok": "",
45
45
  "Only visible to you": "",
46
46
  "Open Settings": "Открыть настройки",
47
- "Photo": "Фото",
47
+ "Photo": "",
48
48
  "Photos and Videos": "Фото и видео",
49
- "Pin to Conversation": "",
49
+ "Pin to Conversation": "Закрепить к беседе",
50
50
  "Pinned by": "",
51
51
  "Please enable access to your photos and videos so you can share them.": "Разрешите доступ к своим фотографиям и видео, чтобы вы могли ими поделиться.",
52
52
  "Please select a channel first": "",
53
53
  "Reconnecting...": "",
54
- "Reply": "",
54
+ "Reply": "Ответить",
55
55
  "Reply to Message": "",
56
- "Resend": "",
56
+ "Resend": "Отправить",
57
57
  "Search GIFs": "",
58
58
  "Select More Photos": "Выбрать больше фотографий",
59
- "Send Anyway": "",
59
+ "Send Anyway": "Всё равно отправить",
60
60
  "Send a message": "",
61
61
  "Sending links is not allowed in this conversation": "",
62
62
  "Slow mode ON": "",
63
- "The message has been reported to a moderator.": "",
64
- "Thread Reply": "",
65
- "Unblock User": "",
63
+ "The message has been reported to a moderator.": "Сообщение отправлено модератору.",
64
+ "Thread Reply": "Тема Ответить",
65
+ "Unblock User": "Разблокировать пользователя",
66
66
  "Unknown User": "Неизвестный пользователь",
67
- "Unmute User": "",
68
- "Unpin from Conversation": "",
69
- "Unread Messages": "",
70
- "Video": "видео",
67
+ "Unmute User": "Включить микрофон",
68
+ "Unpin from Conversation": "Открепить от беседы",
69
+ "Unread Messages": "Непрочитанные Сообщения",
70
+ "Video": "",
71
71
  "You": "",
72
72
  "You can't send messages in this channel": "",
73
- "{{ firstUser }} and {{ nonSelfUserLength }} more are typing": "{{ firstUser }} и еще {{ nonSelfUserLength }} пишут",
73
+ "{{ firstUser }} and {{ nonSelfUserLength }} more are typing": "",
74
74
  "{{ index }} of {{ photoLength }}": "{{ index }} из {{ photoLength }}",
75
75
  "{{ replyCount }} Replies": "{{ replyCount }} Ответов",
76
76
  "{{ replyCount }} Thread Replies": "",
77
- "{{ user }} is typing": "{{ user }} пишет",
77
+ "{{ user }} is typing": "",
78
78
  "🏙 Attachment...": ""
79
79
  }
@@ -4,31 +4,31 @@
4
4
  "Allow access to your Gallery": "Galerinize erişime izin verin",
5
5
  "Allow camera access in device settings": "Cihaz ayarlarında kamera erişimine izin ver",
6
6
  "Also send to channel": "",
7
- "Are you sure you want to permanently delete this message?": "",
8
- "Are you sure?": "",
9
- "Block User": "",
10
- "Cancel": "",
11
- "Cannot Flag Message": "",
12
- "Consider how your comment might make others feel and be sure to follow our Community Guidelines": "",
13
- "Copy Message": "",
14
- "Delete": "",
15
- "Delete Message": "",
7
+ "Are you sure you want to permanently delete this message?": "Bu mesajı kalıcı olarak silmek istediğinizden emin misiniz?",
8
+ "Are you sure?": "Emin misiniz?",
9
+ "Block User": "Kullanıcıyı engelle",
10
+ "Cancel": "İptal",
11
+ "Cannot Flag Message": "Raporlama Başarısız",
12
+ "Consider how your comment might make others feel and be sure to follow our Community Guidelines": "Yorumunuzun diğerlerini nasıl hissettirebileceğini düşünün ve topluluk kurallarımızı takip ettiğinizden emin olun",
13
+ "Copy Message": "Mesajı Kopyala",
14
+ "Delete": "Sil",
15
+ "Delete Message": "Mesajı Sil",
16
16
  "Device camera is used to take photos or videos.": "Cihaz kamerası fotoğraf veya video çekmek için kullanılır.",
17
- "Do you want to send a copy of this message to a moderator for further investigation?": "",
18
- "Edit Message": "",
17
+ "Do you want to send a copy of this message to a moderator for further investigation?": "Detaylı inceleme için bu mesajın kopyasını moderatöre göndermek istiyor musunuz?",
18
+ "Edit Message": "Mesajı Düzenle",
19
19
  "Editing Message": "",
20
- "Emoji matching": "Emoji eşleştirme",
20
+ "Emoji matching": "",
21
21
  "Empty message...": "",
22
22
  "Error loading": "",
23
23
  "Error loading channel list...": "",
24
24
  "Error loading messages for this channel...": "",
25
25
  "Error while loading, please reload/refresh": "",
26
- "File type not supported": "",
27
- "Flag": "",
28
- "Flag Message": "",
29
- "Flag action failed either due to a network issue or the message is already flagged": "",
26
+ "File type not supported": "Dosya türü desteklenmiyor",
27
+ "Flag": "Raporla",
28
+ "Flag Message": "Mesajı Raporla",
29
+ "Flag action failed either due to a network issue or the message is already flagged": "Mesajın daha önce raporlanmış olması veya bir ağ bağlantısı sorunu nedeniyle raporlama işlemi başarısız oldu.",
30
30
  "How about sending your first message to a friend?": "",
31
- "Instant Commands": "Anlık Komutlar",
31
+ "Instant Commands": "",
32
32
  "Let's start chatting!": "",
33
33
  "Links are disabled": "",
34
34
  "Loading channels...": "",
@@ -37,43 +37,43 @@
37
37
  "Maximum file size upload limit reached. Please upload a file below {{MAX_FILE_SIZE_TO_UPLOAD_IN_MB}} MB.": "",
38
38
  "Message Reactions": "",
39
39
  "Message deleted": "",
40
- "Message flagged": "",
41
- "Mute User": "",
42
- "Not supported": "",
40
+ "Message flagged": "Mesaj işaretlendi",
41
+ "Mute User": "Kullanıcıyı sessize al",
42
+ "Not supported": "Desteklenmiyor",
43
43
  "Nothing yet...": "",
44
- "Ok": "",
44
+ "Ok": "Tamam",
45
45
  "Only visible to you": "",
46
46
  "Open Settings": "Ayarları aç",
47
- "Photo": "Fotoğraf",
47
+ "Photo": "",
48
48
  "Photos and Videos": "Fotoğraflar ve Videolar",
49
- "Pin to Conversation": "",
49
+ "Pin to Conversation": "Konuşmaya sabitle",
50
50
  "Pinned by": "",
51
51
  "Please enable access to your photos and videos so you can share them.": "Paylaşım yapabilmek için lutfen fotoğraflarınıza ve videolarınıza erişimi etkinleştirin.",
52
52
  "Please select a channel first": "",
53
53
  "Reconnecting...": "",
54
- "Reply": "",
54
+ "Reply": "Yanıtla",
55
55
  "Reply to Message": "",
56
- "Resend": "",
56
+ "Resend": "Yeniden gönder",
57
57
  "Search GIFs": "",
58
58
  "Select More Photos": "Daha Fazla Fotoğraf Seçin",
59
- "Send Anyway": "",
59
+ "Send Anyway": "Yine de Gönder",
60
60
  "Send a message": "",
61
61
  "Sending links is not allowed in this conversation": "",
62
62
  "Slow mode ON": "",
63
- "The message has been reported to a moderator.": "",
64
- "Thread Reply": "",
65
- "Unblock User": "",
63
+ "The message has been reported to a moderator.": "Mesaj moderatöre bildirildi.",
64
+ "Thread Reply": "Konu Yanıtı",
65
+ "Unblock User": "Kullanıcının engelini kaldır",
66
66
  "Unknown User": "Bilinmeyen kullanıcı",
67
- "Unmute User": "",
68
- "Unpin from Conversation": "",
69
- "Unread Messages": "",
70
- "Video": "Video",
67
+ "Unmute User": "Kullanıcının sesini aç",
68
+ "Unpin from Conversation": "Sabitlemeyi kaldır",
69
+ "Unread Messages": "Okunmamış Mesajlar",
70
+ "Video": "",
71
71
  "You": "",
72
72
  "You can't send messages in this channel": "",
73
- "{{ firstUser }} and {{ nonSelfUserLength }} more are typing": "{{ firstUser }} ve {{ nonSelfUserLength }} kişi daha yazıyor",
73
+ "{{ firstUser }} and {{ nonSelfUserLength }} more are typing": "",
74
74
  "{{ index }} of {{ photoLength }}": "{{ index }} / {{ photoLength }}",
75
75
  "{{ replyCount }} Replies": "{{ replyCount }} Cevap",
76
76
  "{{ replyCount }} Thread Replies": "",
77
- "{{ user }} is typing": "{{ user }} yazıyor",
77
+ "{{ user }} is typing": "",
78
78
  "🏙 Attachment...": ""
79
79
  }
@@ -1,3 +1,3 @@
1
1
  {
2
- "version": "5.26.0-beta.7"
2
+ "version": "5.26.1-beta.1"
3
3
  }
@@ -194,6 +194,7 @@ var ChannelPreviewMessengerWithContext = function ChannelPreviewMessengerWithCon
194
194
  columnNumber: 11
195
195
  }
196
196
  }), _react["default"].createElement(PreviewStatus, {
197
+ channel: channel,
197
198
  formatLatestMessageDate: formatLatestMessageDate,
198
199
  latestMessagePreview: latestMessagePreview,
199
200
  __self: _this,
@@ -228,7 +229,7 @@ var ChannelPreviewMessenger = function ChannelPreviewMessenger(props) {
228
229
  __self: _this,
229
230
  __source: {
230
231
  fileName: _jsxFileName,
231
- lineNumber: 223,
232
+ lineNumber: 224,
232
233
  columnNumber: 5
233
234
  }
234
235
  }));
@@ -1 +1 @@
1
- {"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_reactNativeGestureHandler","_ChannelAvatar","_ChannelPreviewMessage","_ChannelPreviewMutedStatus","_ChannelPreviewStatus","_ChannelPreviewTitle","_ChannelPreviewUnreadCount","_useChannelPreviewDisplayName","_ChannelsContext","_ChatContext","_ThemeContext","_useViewport2","_this","_jsxFileName","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","_typeof","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","styles","StyleSheet","create","container","borderBottomWidth","flex","flexDirection","paddingHorizontal","paddingVertical","contentContainer","row","alignItems","justifyContent","paddingLeft","statusContainer","display","title","fontSize","fontWeight","ChannelPreviewMessengerWithContext","props","channel","formatLatestMessageDate","latestMessagePreview","maxUnreadCount","onSelect","_props$PreviewAvatar","PreviewAvatar","ChannelAvatar","_props$PreviewMessage","PreviewMessage","ChannelPreviewMessage","_props$PreviewStatus","PreviewStatus","ChannelPreviewStatus","_props$PreviewTitle","PreviewTitle","ChannelPreviewTitle","_props$PreviewUnreadC","PreviewUnreadCount","ChannelPreviewUnreadCount","_props$PreviewMutedSt","PreviewMutedStatus","ChannelPreviewMutedStatus","unread","_useViewport","useViewport","vw","maxWidth","_useTheme","useTheme","_useTheme$theme","theme","_useTheme$theme$chann","channelPreview","_useTheme$theme$color","colors","border","white_snow","_useChatContext","useChatContext","client","displayName","useChannelPreviewDisplayName","Math","floor","_useState","useState","muteStatus","muted","_useState2","_slicedToArray2","isChannelMuted","setIsChannelMuted","useEffect","handleEvent","on","off","createElement","TouchableOpacity","onPress","style","backgroundColor","borderBottomColor","testID","__self","__source","fileName","lineNumber","columnNumber","View","id","MemoizedChannelPreviewMessengerWithContext","React","memo","ChannelPreviewMessenger","_useChannelsContext","useChannelsContext","_extends2","exports"],"sources":["ChannelPreviewMessenger.tsx"],"sourcesContent":["import React, { useEffect, useState } from 'react';\nimport { StyleSheet, View } from 'react-native';\nimport { TouchableOpacity } from 'react-native-gesture-handler';\n\nimport { ChannelAvatar } from './ChannelAvatar';\nimport type { ChannelPreviewProps } from './ChannelPreview';\nimport { ChannelPreviewMessage } from './ChannelPreviewMessage';\nimport { ChannelPreviewMutedStatus } from './ChannelPreviewMutedStatus';\nimport { ChannelPreviewStatus } from './ChannelPreviewStatus';\nimport { ChannelPreviewTitle } from './ChannelPreviewTitle';\nimport { ChannelPreviewUnreadCount } from './ChannelPreviewUnreadCount';\nimport { useChannelPreviewDisplayName } from './hooks/useChannelPreviewDisplayName';\n\nimport type { LatestMessagePreview } from './hooks/useLatestMessagePreview';\n\nimport {\n ChannelsContextValue,\n useChannelsContext,\n} from '../../contexts/channelsContext/ChannelsContext';\nimport { useChatContext } from '../../contexts/chatContext/ChatContext';\nimport { useTheme } from '../../contexts/themeContext/ThemeContext';\nimport { useViewport } from '../../hooks/useViewport';\nimport type { DefaultStreamChatGenerics } from '../../types/types';\n\nconst styles = StyleSheet.create({\n container: {\n borderBottomWidth: 1,\n flex: 1,\n flexDirection: 'row',\n paddingHorizontal: 8,\n paddingVertical: 12,\n },\n contentContainer: { flex: 1 },\n row: {\n alignItems: 'center',\n flex: 1,\n flexDirection: 'row',\n justifyContent: 'space-between',\n paddingLeft: 8,\n },\n statusContainer: {\n display: 'flex',\n flexDirection: 'row',\n },\n title: { fontSize: 14, fontWeight: '700' },\n});\n\nexport type ChannelPreviewMessengerPropsWithContext<\n StreamChatGenerics extends DefaultStreamChatGenerics = DefaultStreamChatGenerics,\n> = Pick<ChannelPreviewProps<StreamChatGenerics>, 'channel'> &\n Pick<\n ChannelsContextValue<StreamChatGenerics>,\n | 'maxUnreadCount'\n | 'onSelect'\n | 'PreviewAvatar'\n | 'PreviewMessage'\n | 'PreviewMutedStatus'\n | 'PreviewStatus'\n | 'PreviewTitle'\n | 'PreviewUnreadCount'\n > & {\n /**\n * Latest message on a channel, formatted for preview\n *\n * e.g.,\n *\n * ```json\n * {\n * created_at: '' ,\n * messageObject: { ... },\n * previews: {\n * bold: true,\n * text: 'This is the message preview text'\n * },\n * status: 0 | 1 | 2 // read states of the latest message.\n * }\n * ```\n *\n * The read status is either of the following:\n *\n * 0: The message was not sent by the current user\n * 1: The message was sent by the current user and is unread\n * 2: The message was sent by the current user and is read\n *\n * @overrideType object\n */\n latestMessagePreview: LatestMessagePreview<StreamChatGenerics>;\n /**\n * Formatter function for date of latest message.\n * @param date Message date\n * @returns Formatted date string\n *\n * By default today's date is shown in 'HH:mm A' format and other dates\n * are displayed in 'DD/MM/YY' format. props.latestMessage.created_at is the\n * default formatted date. This default logic is part of ChannelPreview component.\n */\n formatLatestMessageDate?: (date: Date) => string;\n /** Number of unread messages on the channel */\n unread?: number;\n };\n\nconst ChannelPreviewMessengerWithContext = <\n StreamChatGenerics extends DefaultStreamChatGenerics = DefaultStreamChatGenerics,\n>(\n props: ChannelPreviewMessengerPropsWithContext<StreamChatGenerics>,\n) => {\n const {\n channel,\n formatLatestMessageDate,\n latestMessagePreview,\n maxUnreadCount,\n onSelect,\n PreviewAvatar = ChannelAvatar,\n PreviewMessage = ChannelPreviewMessage,\n PreviewStatus = ChannelPreviewStatus,\n PreviewTitle = ChannelPreviewTitle,\n PreviewUnreadCount = ChannelPreviewUnreadCount,\n PreviewMutedStatus = ChannelPreviewMutedStatus,\n unread,\n } = props;\n const { vw } = useViewport();\n\n const maxWidth = vw(80) - 16 - 40;\n\n const {\n theme: {\n channelPreview: { container, contentContainer, row, title },\n colors: { border, white_snow },\n },\n } = useTheme();\n\n const { client } = useChatContext<StreamChatGenerics>();\n\n const displayName = useChannelPreviewDisplayName(\n channel,\n Math.floor(maxWidth / ((title.fontSize || styles.title.fontSize) / 2)),\n );\n\n const [isChannelMuted, setIsChannelMuted] = useState(() => channel.muteStatus().muted);\n\n useEffect(() => {\n const handleEvent = () => setIsChannelMuted(channel.muteStatus().muted);\n\n client.on('notification.channel_mutes_updated', handleEvent);\n return () => client.off('notification.channel_mutes_updated', handleEvent);\n }, [client]);\n\n return (\n <TouchableOpacity\n onPress={() => {\n if (onSelect) {\n onSelect(channel);\n }\n }}\n style={[\n styles.container,\n { backgroundColor: white_snow, borderBottomColor: border },\n container,\n ]}\n testID='channel-preview-button'\n >\n <PreviewAvatar channel={channel} />\n <View\n style={[styles.contentContainer, contentContainer]}\n testID={`channel-preview-content-${channel.id}`}\n >\n <View style={[styles.row, row]}>\n <PreviewTitle channel={channel} displayName={displayName} />\n <View style={[styles.statusContainer, row]}>\n {isChannelMuted && <PreviewMutedStatus />}\n <PreviewUnreadCount channel={channel} maxUnreadCount={maxUnreadCount} unread={unread} />\n </View>\n </View>\n <View style={[styles.row, row]}>\n <PreviewMessage latestMessagePreview={latestMessagePreview} />\n <PreviewStatus\n formatLatestMessageDate={formatLatestMessageDate}\n latestMessagePreview={latestMessagePreview}\n />\n </View>\n </View>\n </TouchableOpacity>\n );\n};\n\nexport type ChannelPreviewMessengerProps<\n StreamChatGenerics extends DefaultStreamChatGenerics = DefaultStreamChatGenerics,\n> = Partial<\n Omit<\n ChannelPreviewMessengerPropsWithContext<StreamChatGenerics>,\n 'channel' | 'latestMessagePreview'\n >\n> &\n Pick<\n ChannelPreviewMessengerPropsWithContext<StreamChatGenerics>,\n 'channel' | 'latestMessagePreview'\n >;\n\nconst MemoizedChannelPreviewMessengerWithContext = React.memo(\n ChannelPreviewMessengerWithContext,\n) as typeof ChannelPreviewMessengerWithContext;\n\n/**\n * This UI component displays an individual preview item for each channel in a list. It also receives all props\n * from the ChannelPreview component.\n */\nexport const ChannelPreviewMessenger = <\n StreamChatGenerics extends DefaultStreamChatGenerics = DefaultStreamChatGenerics,\n>(\n props: ChannelPreviewMessengerProps<StreamChatGenerics>,\n) => {\n const {\n maxUnreadCount,\n onSelect,\n PreviewAvatar,\n PreviewMessage,\n PreviewMutedStatus,\n PreviewStatus,\n PreviewTitle,\n PreviewUnreadCount,\n } = useChannelsContext<StreamChatGenerics>();\n return (\n <MemoizedChannelPreviewMessengerWithContext\n {...{\n maxUnreadCount,\n onSelect,\n PreviewAvatar,\n PreviewMessage,\n PreviewMutedStatus,\n PreviewStatus,\n PreviewTitle,\n PreviewUnreadCount,\n }}\n {...props}\n />\n );\n};\n\nChannelPreviewMessenger.displayName = 'ChannelPreviewMessenger{channelPreview}';\n"],"mappings":";;;;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,0BAAA,GAAAF,OAAA;AAEA,IAAAG,cAAA,GAAAH,OAAA;AAEA,IAAAI,sBAAA,GAAAJ,OAAA;AACA,IAAAK,0BAAA,GAAAL,OAAA;AACA,IAAAM,qBAAA,GAAAN,OAAA;AACA,IAAAO,oBAAA,GAAAP,OAAA;AACA,IAAAQ,0BAA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BAAkB;IAClBT,aAAa,GAAA+D,mBAAA,CAAb/D,aAAa;IACbG,YAAY,GAAA4D,mBAAA,CAAZ5D,YAAY;IACZG,kBAAkB,GAAAyD,mBAAA,CAAlBzD,kBAAkB;EAEpB,OACE/E,MAAA,YAAAsH,aAAA,CAACc,0CAA0C,MAAAM,SAAA;IAEvC1E,cAAc,EAAdA,cAAc;IACdC,QAAQ,EAARA,QAAQ;IACRE,aAAa,EAAbA,aAAa;IACbG,cAAc,EAAdA,cAAc;IACdY,kBAAkB,EAAlBA,kBAAkB;IAClBT,aAAa,EAAbA,aAAa;IACbG,YAAY,EAAZA,YAAY;IACZG,kBAAkB,EAAlBA;EAAkB,GAEhBnB,KAAK;IAAAiE,MAAA,EAAA7G,KAAA;IAAA8G,QAAA;MAAAC,QAAA,EAAA9G,YAAA;MAAA+G,UAAA;MAAAC,YAAA;IAAA;EAAA,EACV,CAAC;AAEN,CAAC;AAACU,OAAA,CAAAJ,uBAAA,GAAAA,uBAAA;AAEFA,uBAAuB,CAACjC,WAAW,GAAG,yCAAyC"}
1
+ {"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_reactNativeGestureHandler","_ChannelAvatar","_ChannelPreviewMessage","_ChannelPreviewMutedStatus","_ChannelPreviewStatus","_ChannelPreviewTitle","_ChannelPreviewUnreadCount","_useChannelPreviewDisplayName","_ChannelsContext","_ChatContext","_ThemeContext","_useViewport2","_this","_jsxFileName","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","_typeof","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","styles","StyleSheet","create","container","borderBottomWidth","flex","flexDirection","paddingHorizontal","paddingVertical","contentContainer","row","alignItems","justifyContent","paddingLeft","statusContainer","display","title","fontSize","fontWeight","ChannelPreviewMessengerWithContext","props","channel","formatLatestMessageDate","latestMessagePreview","maxUnreadCount","onSelect","_props$PreviewAvatar","PreviewAvatar","ChannelAvatar","_props$PreviewMessage","PreviewMessage","ChannelPreviewMessage","_props$PreviewStatus","PreviewStatus","ChannelPreviewStatus","_props$PreviewTitle","PreviewTitle","ChannelPreviewTitle","_props$PreviewUnreadC","PreviewUnreadCount","ChannelPreviewUnreadCount","_props$PreviewMutedSt","PreviewMutedStatus","ChannelPreviewMutedStatus","unread","_useViewport","useViewport","vw","maxWidth","_useTheme","useTheme","_useTheme$theme","theme","_useTheme$theme$chann","channelPreview","_useTheme$theme$color","colors","border","white_snow","_useChatContext","useChatContext","client","displayName","useChannelPreviewDisplayName","Math","floor","_useState","useState","muteStatus","muted","_useState2","_slicedToArray2","isChannelMuted","setIsChannelMuted","useEffect","handleEvent","on","off","createElement","TouchableOpacity","onPress","style","backgroundColor","borderBottomColor","testID","__self","__source","fileName","lineNumber","columnNumber","View","id","MemoizedChannelPreviewMessengerWithContext","React","memo","ChannelPreviewMessenger","_useChannelsContext","useChannelsContext","_extends2","exports"],"sources":["ChannelPreviewMessenger.tsx"],"sourcesContent":["import React, { useEffect, useState } from 'react';\nimport { StyleSheet, View } from 'react-native';\nimport { TouchableOpacity } from 'react-native-gesture-handler';\n\nimport { ChannelAvatar } from './ChannelAvatar';\nimport type { ChannelPreviewProps } from './ChannelPreview';\nimport { ChannelPreviewMessage } from './ChannelPreviewMessage';\nimport { ChannelPreviewMutedStatus } from './ChannelPreviewMutedStatus';\nimport { ChannelPreviewStatus } from './ChannelPreviewStatus';\nimport { ChannelPreviewTitle } from './ChannelPreviewTitle';\nimport { ChannelPreviewUnreadCount } from './ChannelPreviewUnreadCount';\nimport { useChannelPreviewDisplayName } from './hooks/useChannelPreviewDisplayName';\n\nimport type { LatestMessagePreview } from './hooks/useLatestMessagePreview';\n\nimport {\n ChannelsContextValue,\n useChannelsContext,\n} from '../../contexts/channelsContext/ChannelsContext';\nimport { useChatContext } from '../../contexts/chatContext/ChatContext';\nimport { useTheme } from '../../contexts/themeContext/ThemeContext';\nimport { useViewport } from '../../hooks/useViewport';\nimport type { DefaultStreamChatGenerics } from '../../types/types';\n\nconst styles = StyleSheet.create({\n container: {\n borderBottomWidth: 1,\n flex: 1,\n flexDirection: 'row',\n paddingHorizontal: 8,\n paddingVertical: 12,\n },\n contentContainer: { flex: 1 },\n row: {\n alignItems: 'center',\n flex: 1,\n flexDirection: 'row',\n justifyContent: 'space-between',\n paddingLeft: 8,\n },\n statusContainer: {\n display: 'flex',\n flexDirection: 'row',\n },\n title: { fontSize: 14, fontWeight: '700' },\n});\n\nexport type ChannelPreviewMessengerPropsWithContext<\n StreamChatGenerics extends DefaultStreamChatGenerics = DefaultStreamChatGenerics,\n> = Pick<ChannelPreviewProps<StreamChatGenerics>, 'channel'> &\n Pick<\n ChannelsContextValue<StreamChatGenerics>,\n | 'maxUnreadCount'\n | 'onSelect'\n | 'PreviewAvatar'\n | 'PreviewMessage'\n | 'PreviewMutedStatus'\n | 'PreviewStatus'\n | 'PreviewTitle'\n | 'PreviewUnreadCount'\n > & {\n /**\n * Latest message on a channel, formatted for preview\n *\n * e.g.,\n *\n * ```json\n * {\n * created_at: '' ,\n * messageObject: { ... },\n * previews: {\n * bold: true,\n * text: 'This is the message preview text'\n * },\n * status: 0 | 1 | 2 // read states of the latest message.\n * }\n * ```\n *\n * The read status is either of the following:\n *\n * 0: The message was not sent by the current user\n * 1: The message was sent by the current user and is unread\n * 2: The message was sent by the current user and is read\n *\n * @overrideType object\n */\n latestMessagePreview: LatestMessagePreview<StreamChatGenerics>;\n /**\n * Formatter function for date of latest message.\n * @param date Message date\n * @returns Formatted date string\n *\n * By default today's date is shown in 'HH:mm A' format and other dates\n * are displayed in 'DD/MM/YY' format. props.latestMessage.created_at is the\n * default formatted date. This default logic is part of ChannelPreview component.\n */\n formatLatestMessageDate?: (date: Date) => string;\n /** Number of unread messages on the channel */\n unread?: number;\n };\n\nconst ChannelPreviewMessengerWithContext = <\n StreamChatGenerics extends DefaultStreamChatGenerics = DefaultStreamChatGenerics,\n>(\n props: ChannelPreviewMessengerPropsWithContext<StreamChatGenerics>,\n) => {\n const {\n channel,\n formatLatestMessageDate,\n latestMessagePreview,\n maxUnreadCount,\n onSelect,\n PreviewAvatar = ChannelAvatar,\n PreviewMessage = ChannelPreviewMessage,\n PreviewStatus = ChannelPreviewStatus,\n PreviewTitle = ChannelPreviewTitle,\n PreviewUnreadCount = ChannelPreviewUnreadCount,\n PreviewMutedStatus = ChannelPreviewMutedStatus,\n unread,\n } = props;\n const { vw } = useViewport();\n\n const maxWidth = vw(80) - 16 - 40;\n\n const {\n theme: {\n channelPreview: { container, contentContainer, row, title },\n colors: { border, white_snow },\n },\n } = useTheme();\n\n const { client } = useChatContext<StreamChatGenerics>();\n\n const displayName = useChannelPreviewDisplayName(\n channel,\n Math.floor(maxWidth / ((title.fontSize || styles.title.fontSize) / 2)),\n );\n\n const [isChannelMuted, setIsChannelMuted] = useState(() => channel.muteStatus().muted);\n\n useEffect(() => {\n const handleEvent = () => setIsChannelMuted(channel.muteStatus().muted);\n\n client.on('notification.channel_mutes_updated', handleEvent);\n return () => client.off('notification.channel_mutes_updated', handleEvent);\n }, [client]);\n\n return (\n <TouchableOpacity\n onPress={() => {\n if (onSelect) {\n onSelect(channel);\n }\n }}\n style={[\n styles.container,\n { backgroundColor: white_snow, borderBottomColor: border },\n container,\n ]}\n testID='channel-preview-button'\n >\n <PreviewAvatar channel={channel} />\n <View\n style={[styles.contentContainer, contentContainer]}\n testID={`channel-preview-content-${channel.id}`}\n >\n <View style={[styles.row, row]}>\n <PreviewTitle channel={channel} displayName={displayName} />\n <View style={[styles.statusContainer, row]}>\n {isChannelMuted && <PreviewMutedStatus />}\n <PreviewUnreadCount channel={channel} maxUnreadCount={maxUnreadCount} unread={unread} />\n </View>\n </View>\n <View style={[styles.row, row]}>\n <PreviewMessage latestMessagePreview={latestMessagePreview} />\n <PreviewStatus\n channel={channel}\n formatLatestMessageDate={formatLatestMessageDate}\n latestMessagePreview={latestMessagePreview}\n />\n </View>\n </View>\n </TouchableOpacity>\n );\n};\n\nexport type ChannelPreviewMessengerProps<\n StreamChatGenerics extends DefaultStreamChatGenerics = DefaultStreamChatGenerics,\n> = Partial<\n Omit<\n ChannelPreviewMessengerPropsWithContext<StreamChatGenerics>,\n 'channel' | 'latestMessagePreview'\n >\n> &\n Pick<\n ChannelPreviewMessengerPropsWithContext<StreamChatGenerics>,\n 'channel' | 'latestMessagePreview'\n >;\n\nconst MemoizedChannelPreviewMessengerWithContext = React.memo(\n ChannelPreviewMessengerWithContext,\n) as typeof ChannelPreviewMessengerWithContext;\n\n/**\n * This UI component displays an individual preview item for each channel in a list. It also receives all props\n * from the ChannelPreview component.\n */\nexport const ChannelPreviewMessenger = <\n StreamChatGenerics extends DefaultStreamChatGenerics = DefaultStreamChatGenerics,\n>(\n props: ChannelPreviewMessengerProps<StreamChatGenerics>,\n) => {\n const {\n maxUnreadCount,\n onSelect,\n PreviewAvatar,\n PreviewMessage,\n PreviewMutedStatus,\n PreviewStatus,\n PreviewTitle,\n PreviewUnreadCount,\n } = useChannelsContext<StreamChatGenerics>();\n return (\n <MemoizedChannelPreviewMessengerWithContext\n {...{\n maxUnreadCount,\n onSelect,\n PreviewAvatar,\n PreviewMessage,\n PreviewMutedStatus,\n PreviewStatus,\n PreviewTitle,\n PreviewUnreadCount,\n }}\n {...props}\n />\n );\n};\n\nChannelPreviewMessenger.displayName = 'ChannelPreviewMessenger{channelPreview}';\n"],"mappings":";;;;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,0BAAA,GAAAF,OAAA;AAEA,IAAAG,cAAA,GAAAH,OAAA;AAEA,IAAAI,sBAAA,GAAAJ,OAAA;AACA,IAAAK,0BAAA,GAAAL,OAAA;AACA,IAAAM,qBAAA,GAAAN,OAAA;AACA,IAAAO,oBAAA,GAAAP,OAAA;AACA,IAAAQ,0BAAA,GAAAR,OAAA;AACA,IAAAS,6BAAA,GAAAT,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,aAAa,GAAA+D,mBAAA,CAAb/D,aAAa;IACbG,YAAY,GAAA4D,mBAAA,CAAZ5D,YAAY;IACZG,kBAAkB,GAAAyD,mBAAA,CAAlBzD,kBAAkB;EAEpB,OACE/E,MAAA,YAAAsH,aAAA,CAACc,0CAA0C,MAAAM,SAAA;IAEvC1E,cAAc,EAAdA,cAAc;IACdC,QAAQ,EAARA,QAAQ;IACRE,aAAa,EAAbA,aAAa;IACbG,cAAc,EAAdA,cAAc;IACdY,kBAAkB,EAAlBA,kBAAkB;IAClBT,aAAa,EAAbA,aAAa;IACbG,YAAY,EAAZA,YAAY;IACZG,kBAAkB,EAAlBA;EAAkB,GAEhBnB,KAAK;IAAAiE,MAAA,EAAA7G,KAAA;IAAA8G,QAAA;MAAAC,QAAA,EAAA9G,YAAA;MAAA+G,UAAA;MAAAC,YAAA;IAAA;EAAA,EACV,CAAC;AAEN,CAAC;AAACU,OAAA,CAAAJ,uBAAA,GAAAA,uBAAA;AAEFA,uBAAuB,CAACjC,WAAW,GAAG,yCAAyC"}
@@ -42,7 +42,7 @@ var ChannelPreviewStatus = function ChannelPreviewStatus(props) {
42
42
  __self: _this,
43
43
  __source: {
44
44
  fileName: _jsxFileName,
45
- lineNumber: 48,
45
+ lineNumber: 50,
46
46
  columnNumber: 5
47
47
  }
48
48
  }, status === _useLatestMessagePreview.MessageReadStatus.READ ? _react["default"].createElement(_icons.CheckAll, (0, _extends2["default"])({
@@ -51,7 +51,7 @@ var ChannelPreviewStatus = function ChannelPreviewStatus(props) {
51
51
  __self: _this,
52
52
  __source: {
53
53
  fileName: _jsxFileName,
54
- lineNumber: 50,
54
+ lineNumber: 52,
55
55
  columnNumber: 9
56
56
  }
57
57
  })) : status === _useLatestMessagePreview.MessageReadStatus.UNREAD ? _react["default"].createElement(_icons.Check, (0, _extends2["default"])({
@@ -60,7 +60,7 @@ var ChannelPreviewStatus = function ChannelPreviewStatus(props) {
60
60
  __self: _this,
61
61
  __source: {
62
62
  fileName: _jsxFileName,
63
- lineNumber: 52,
63
+ lineNumber: 54,
64
64
  columnNumber: 9
65
65
  }
66
66
  })) : null, _react["default"].createElement(_reactNative.Text, {
@@ -70,7 +70,7 @@ var ChannelPreviewStatus = function ChannelPreviewStatus(props) {
70
70
  __self: _this,
71
71
  __source: {
72
72
  fileName: _jsxFileName,
73
- lineNumber: 54,
73
+ lineNumber: 56,
74
74
  columnNumber: 7
75
75
  }
76
76
  }, formatLatestMessageDate && latestMessageDate ? formatLatestMessageDate(latestMessageDate) : latestMessagePreview.created_at));
@@ -1 +1 @@
1
- {"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_useLatestMessagePreview","_ThemeContext","_icons","_this","_jsxFileName","styles","StyleSheet","create","date","fontSize","marginLeft","textAlign","flexRow","flexDirection","ChannelPreviewStatus","props","_latestMessagePreview","formatLatestMessageDate","latestMessagePreview","_useTheme","useTheme","_useTheme$theme","theme","_useTheme$theme$chann","channelPreview","checkAllIcon","checkIcon","_useTheme$theme$color","colors","accent_blue","grey","created_at","messageObject","latestMessageDate","Date","status","createElement","View","style","__self","__source","fileName","lineNumber","columnNumber","MessageReadStatus","READ","CheckAll","_extends2","pathFill","UNREAD","Check","Text","color","exports"],"sources":["ChannelPreviewStatus.tsx"],"sourcesContent":["import React from 'react';\nimport { StyleSheet, Text, View } from 'react-native';\n\nimport type { ChannelPreviewMessengerPropsWithContext } from './ChannelPreviewMessenger';\nimport { MessageReadStatus } from './hooks/useLatestMessagePreview';\n\nimport { useTheme } from '../../contexts/themeContext/ThemeContext';\nimport { Check, CheckAll } from '../../icons';\n\nimport type { DefaultStreamChatGenerics } from '../../types/types';\n\nconst styles = StyleSheet.create({\n date: {\n fontSize: 12,\n marginLeft: 2,\n textAlign: 'right',\n },\n flexRow: {\n flexDirection: 'row',\n },\n});\n\nexport type ChannelPreviewStatusProps<\n StreamChatGenerics extends DefaultStreamChatGenerics = DefaultStreamChatGenerics,\n> = Pick<\n ChannelPreviewMessengerPropsWithContext<StreamChatGenerics>,\n 'latestMessagePreview' | 'formatLatestMessageDate'\n>;\n\nexport const ChannelPreviewStatus = <\n StreamChatGenerics extends DefaultStreamChatGenerics = DefaultStreamChatGenerics,\n>(\n props: ChannelPreviewStatusProps<StreamChatGenerics>,\n) => {\n const { formatLatestMessageDate, latestMessagePreview } = props;\n const {\n theme: {\n channelPreview: { checkAllIcon, checkIcon, date },\n colors: { accent_blue, grey },\n },\n } = useTheme();\n\n const created_at = latestMessagePreview.messageObject?.created_at;\n const latestMessageDate = created_at ? new Date(created_at) : new Date();\n const status = latestMessagePreview.status;\n\n return (\n <View style={styles.flexRow}>\n {status === MessageReadStatus.READ ? (\n <CheckAll pathFill={accent_blue} {...checkAllIcon} />\n ) : status === MessageReadStatus.UNREAD ? (\n <Check pathFill={grey} {...checkIcon} />\n ) : null}\n <Text style={[styles.date, { color: grey }, date]}>\n {formatLatestMessageDate && latestMessageDate\n ? formatLatestMessageDate(latestMessageDate)\n : latestMessagePreview.created_at}\n </Text>\n </View>\n );\n};\n"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAGA,IAAAE,wBAAA,GAAAF,OAAA;AAEA,IAAAG,aAAA,GAAAH,OAAA;AACA,IAAAI,MAAA,GAAAJ,OAAA;AAA8C,IAAAK,KAAA;EAAAC,YAAA;AAI9C,IAAMC,MAAM,GAAGC,uBAAU,CAACC,MAAM,CAAC;EAC/BC,IAAI,EAAE;IACJC,QAAQ,EAAE,EAAE;IACZC,UAAU,EAAE,CAAC;IACbC,SAAS,EAAE;EACb,CAAC;EACDC,OAAO,EAAE;IACPC,aAAa,EAAE;EACjB;AACF,CAAC,CAAC;AASK,IAAMC,oBAAoB,GAAG,SAAvBA,oBAAoBA,CAG/BC,KAAoD,EACjD;EAAA,IAAAC,qBAAA;EACH,IAAQC,uBAAuB,GAA2BF,KAAK,CAAvDE,uBAAuB;IAAEC,oBAAoB,GAAKH,KAAK,CAA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IAACC,QAAQ,EAAElB;EAAK,GAAKJ,SAAS;IAAAa,MAAA,EAAApC,KAAA;IAAAqC,QAAA;MAAAC,QAAA,EAAArC,YAAA;MAAAsC,UAAA;MAAAC,YAAA;IAAA;EAAA,EAAG,CAAC,GACtC,IAAI,EACR/C,MAAA,YAAAwC,aAAA,CAACrC,YAAA,CAAAoD,IAAI;IAACb,KAAK,EAAE,CAACjC,MAAM,CAACG,IAAI,EAAE;MAAE4C,KAAK,EAAEtB;IAAK,CAAC,EAAEtB,IAAI,CAAE;IAAA+B,MAAA,EAAApC,KAAA;IAAAqC,QAAA;MAAAC,QAAA,EAAArC,YAAA;MAAAsC,UAAA;MAAAC,YAAA;IAAA;EAAA,GAC/C1B,uBAAuB,IAAIgB,iBAAiB,GACzChB,uBAAuB,CAACgB,iBAAiB,CAAC,GAC1Cf,oBAAoB,CAACa,UACrB,CACF,CAAC;AAEX,CAAC;AAACsB,OAAA,CAAAvC,oBAAA,GAAAA,oBAAA"}
1
+ {"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_useLatestMessagePreview","_ThemeContext","_icons","_this","_jsxFileName","styles","StyleSheet","create","date","fontSize","marginLeft","textAlign","flexRow","flexDirection","ChannelPreviewStatus","props","_latestMessagePreview","formatLatestMessageDate","latestMessagePreview","_useTheme","useTheme","_useTheme$theme","theme","_useTheme$theme$chann","channelPreview","checkAllIcon","checkIcon","_useTheme$theme$color","colors","accent_blue","grey","created_at","messageObject","latestMessageDate","Date","status","createElement","View","style","__self","__source","fileName","lineNumber","columnNumber","MessageReadStatus","READ","CheckAll","_extends2","pathFill","UNREAD","Check","Text","color","exports"],"sources":["ChannelPreviewStatus.tsx"],"sourcesContent":["import React from 'react';\nimport { StyleSheet, Text, View } from 'react-native';\n\nimport { ChannelPreviewProps } from './ChannelPreview';\nimport type { ChannelPreviewMessengerPropsWithContext } from './ChannelPreviewMessenger';\nimport { MessageReadStatus } from './hooks/useLatestMessagePreview';\n\nimport { useTheme } from '../../contexts/themeContext/ThemeContext';\nimport { Check, CheckAll } from '../../icons';\n\nimport type { DefaultStreamChatGenerics } from '../../types/types';\n\nconst styles = StyleSheet.create({\n date: {\n fontSize: 12,\n marginLeft: 2,\n textAlign: 'right',\n },\n flexRow: {\n flexDirection: 'row',\n },\n});\n\nexport type ChannelPreviewStatusProps<\n StreamChatGenerics extends DefaultStreamChatGenerics = DefaultStreamChatGenerics,\n> = Pick<\n ChannelPreviewMessengerPropsWithContext<StreamChatGenerics>,\n 'latestMessagePreview' | 'formatLatestMessageDate'\n> &\n Pick<ChannelPreviewProps<StreamChatGenerics>, 'channel'>;\n\nexport const ChannelPreviewStatus = <\n StreamChatGenerics extends DefaultStreamChatGenerics = DefaultStreamChatGenerics,\n>(\n props: ChannelPreviewStatusProps<StreamChatGenerics>,\n) => {\n const { formatLatestMessageDate, latestMessagePreview } = props;\n const {\n theme: {\n channelPreview: { checkAllIcon, checkIcon, date },\n colors: { accent_blue, grey },\n },\n } = useTheme();\n\n const created_at = latestMessagePreview.messageObject?.created_at;\n const latestMessageDate = created_at ? new Date(created_at) : new Date();\n const status = latestMessagePreview.status;\n\n return (\n <View style={styles.flexRow}>\n {status === MessageReadStatus.READ ? (\n <CheckAll pathFill={accent_blue} {...checkAllIcon} />\n ) : status === MessageReadStatus.UNREAD ? (\n <Check pathFill={grey} {...checkIcon} />\n ) : null}\n <Text style={[styles.date, { color: grey }, date]}>\n {formatLatestMessageDate && latestMessageDate\n ? formatLatestMessageDate(latestMessageDate)\n : latestMessagePreview.created_at}\n </Text>\n </View>\n );\n};\n"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAIA,IAAAE,wBAAA,GAAAF,OAAA;AAEA,IAAAG,aAAA,GAAAH,OAAA;AACA,IAAAI,MAAA,GAAAJ,OAAA;AAA8C,IAAAK,KAAA;EAAAC,YAAA;AAI9C,IAAMC,MAAM,GAAGC,uBAAU,CAACC,MA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CjD,MAAA,YAAAwC,aAAA,CAAClC,MAAA,CAAA4C,QAAQ,MAAAC,SAAA;IAACC,QAAQ,EAAEnB;EAAY,GAAKJ,YAAY;IAAAc,MAAA,EAAApC,KAAA;IAAAqC,QAAA;MAAAC,QAAA,EAAArC,YAAA;MAAAsC,UAAA;MAAAC,YAAA;IAAA;EAAA,EAAG,CAAC,GACnDR,MAAM,KAAKS,0CAAiB,CAACK,MAAM,GACrCrD,MAAA,YAAAwC,aAAA,CAAClC,MAAA,CAAAgD,KAAK,MAAAH,SAAA;IAACC,QAAQ,EAAElB;EAAK,GAAKJ,SAAS;IAAAa,MAAA,EAAApC,KAAA;IAAAqC,QAAA;MAAAC,QAAA,EAAArC,YAAA;MAAAsC,UAAA;MAAAC,YAAA;IAAA;EAAA,EAAG,CAAC,GACtC,IAAI,EACR/C,MAAA,YAAAwC,aAAA,CAACrC,YAAA,CAAAoD,IAAI;IAACb,KAAK,EAAE,CAACjC,MAAM,CAACG,IAAI,EAAE;MAAE4C,KAAK,EAAEtB;IAAK,CAAC,EAAEtB,IAAI,CAAE;IAAA+B,MAAA,EAAApC,KAAA;IAAAqC,QAAA;MAAAC,QAAA,EAAArC,YAAA;MAAAsC,UAAA;MAAAC,YAAA;IAAA;EAAA,GAC/C1B,uBAAuB,IAAIgB,iBAAiB,GACzChB,uBAAuB,CAACgB,iBAAiB,CAAC,GAC1Cf,oBAAoB,CAACa,UACrB,CACF,CAAC;AAEX,CAAC;AAACsB,OAAA,CAAAvC,oBAAA,GAAAA,oBAAA"}
@@ -26,7 +26,7 @@
26
26
  "File type not supported": "File type not supported",
27
27
  "Flag": "Flag",
28
28
  "Flag Message": "Flag Message",
29
- "Flag action failed either due to a network issue or the message is already flagged": "Flag action failed either due to a network issue or the message is already flagged",
29
+ "Flag action failed either due to a network issue or the message is already flagged": "Flag action failed either due to a network issue or the message is already flagged.",
30
30
  "How about sending your first message to a friend?": "How about sending your first message to a friend?",
31
31
  "Instant Commands": "Instant Commands",
32
32
  "Let's start chatting!": "Let's start chatting!",