@mobilon-dev/chotto 0.3.121 → 0.3.123
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chotto.css +1 -1
- package/dist/components/1_atoms/ButtonContextMenu/ButtonContextMenu.vue.js +4 -29
- package/dist/components/1_atoms/ButtonContextMenu/ButtonContextMenu.vue2.js +59 -40
- package/dist/components/1_atoms/ContactContextMenu/ContactContextMenu.vue.js +4 -47
- package/dist/components/1_atoms/ContactContextMenu/ContactContextMenu.vue2.js +82 -55
- package/dist/components/1_atoms/ContextMenu/ContextMenu.vue.js +51 -86
- package/dist/components/1_atoms/EmbedPreview/EmbedPreview.vue.js +4 -32
- package/dist/components/1_atoms/EmbedPreview/EmbedPreview.vue2.js +28 -7
- package/dist/components/1_atoms/EmojiGlyph/EmojiGlyph.vue.js +35 -22
- package/dist/components/1_atoms/EmojiGlyph/EmojiGlyph.vue2.js +2 -30
- package/dist/components/1_atoms/LinkPreview/LinkPreview.vue.js +4 -37
- package/dist/components/1_atoms/LinkPreview/LinkPreview.vue2.js +21 -7
- package/dist/components/1_atoms/LoadingIndicator/LoadingIndicator.vue.js +19 -30
- package/dist/components/1_atoms/Tooltip/Tooltip.vue.js +4 -70
- package/dist/components/1_atoms/Tooltip/Tooltip.vue2.js +108 -76
- package/dist/components/1_icons/AvatarIcon.vue.js +8 -8
- package/dist/components/1_icons/CheckIcon.vue.js +13 -26
- package/dist/components/1_icons/CloseButtonIcon.vue.js +10 -16
- package/dist/components/1_icons/CloseIcon.vue.js +10 -16
- package/dist/components/1_icons/ContactCRMIcon.vue.js +10 -16
- package/dist/components/1_icons/DeletedMessageIcon.vue.js +11 -17
- package/dist/components/1_icons/MenuIcon.vue.js +10 -16
- package/dist/components/1_icons/MessageStatus/ErrorStatusIcon.vue.js +3 -23
- package/dist/components/1_icons/MessageStatus/ErrorStatusIcon.vue2.js +21 -12
- package/dist/components/1_icons/MessageStatus/PendingStatusIcon.vue.js +4 -36
- package/dist/components/1_icons/MessageStatus/PendingStatusIcon.vue2.js +26 -11
- package/dist/components/1_icons/MessageStatus/ReadStatusIcon.vue.js +3 -23
- package/dist/components/1_icons/MessageStatus/ReadStatusIcon.vue2.js +21 -12
- package/dist/components/1_icons/MessageStatus/ReceivedStatusIcon.vue.js +3 -23
- package/dist/components/1_icons/MessageStatus/ReceivedStatusIcon.vue2.js +20 -11
- package/dist/components/1_icons/MessageStatus/SentStatusIcon.vue.js +4 -33
- package/dist/components/1_icons/MessageStatus/SentStatusIcon.vue2.js +23 -11
- package/dist/components/1_icons/SearchIcon.vue.js +17 -29
- package/dist/components/1_icons/SettingsIcon.vue.js +8 -8
- package/dist/components/1_icons/TelegramIcon.vue.js +20 -32
- package/dist/components/1_icons/VerifiedBadge.vue.js +19 -25
- package/dist/components/1_icons/WhatsAppIcon.vue.js +20 -32
- package/dist/components/2_blocks/CommunicationPanel/CommunicationPanel.vue.js +402 -552
- package/dist/components/2_blocks/CommunicationPanel/CommunicationPanelAttributeIndicator.vue.js +58 -101
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelCheckIcon.vue.js +8 -14
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelConfirmSpinner.vue.js +7 -7
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelMaxIcon.vue.js +7 -7
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelPhoneIcon.vue.js +13 -19
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelSMSIcon.vue.js +10 -16
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelSubmenuMaxIcon.vue.js +23 -35
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelSubmenuPhoneIcon.vue.js +20 -32
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelSubmenuSMSIcon.vue.js +11 -17
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelSubmenuTelegramIcon.vue.js +8 -8
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelSubmenuWhatsAppIcon.vue.js +20 -32
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelTelegramIcon.vue.js +21 -33
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelUnconfirmedIcon.vue.js +7 -7
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelWhatsAppIcon.vue.js +8 -8
- package/dist/components/2_blocks/FeedFoundItem/FeedFoundItem.vue.js +4 -74
- package/dist/components/2_blocks/FeedFoundItem/FeedFoundItem.vue2.js +46 -12
- package/dist/components/2_blocks/FeedFoundObjects/FeedFoundObjects.vue.js +4 -62
- package/dist/components/2_blocks/FeedFoundObjects/FeedFoundObjects.vue2.js +36 -15
- package/dist/components/2_blocks/FeedSearch/FeedSearch.vue.js +4 -49
- package/dist/components/2_blocks/FeedSearch/FeedSearch.vue2.js +45 -22
- package/dist/components/2_chatinput_elements/ButtonCommandsSelector/ButtonCommandsSelector.vue.js +4 -36
- package/dist/components/2_chatinput_elements/ButtonCommandsSelector/ButtonCommandsSelector.vue2.js +37 -19
- package/dist/components/2_chatinput_elements/ButtonEmojiPicker/ButtonEmojiPicker.vue.js +4 -62
- package/dist/components/2_chatinput_elements/ButtonEmojiPicker/ButtonEmojiPicker.vue2.js +98 -80
- package/dist/components/2_chatinput_elements/ButtonEmojiPicker/icons/SmilesIcon.vue.js +27 -31
- package/dist/components/2_chatinput_elements/ButtonEmojiPicker/icons/SmilesIcon.vue2.js +2 -13
- package/dist/components/2_chatinput_elements/ButtonTemplateSelector/ButtonTemplateSelector.vue.js +4 -72
- package/dist/components/2_chatinput_elements/ButtonTemplateSelector/ButtonTemplateSelector.vue2.js +83 -47
- package/dist/components/2_chatinput_elements/ButtonTemplateSelector/icons/ChatTemplatesIcon.vue.js +21 -19
- package/dist/components/2_chatinput_elements/ButtonTemplateSelector/icons/ChatTemplatesIcon.vue2.js +2 -13
- package/dist/components/2_chatinput_elements/ButtonWabaTemplateSelector/ButtonWabaTemplateSelector.vue.js +45 -76
- package/dist/components/2_chatinput_elements/FilePreview/FilePreview.vue.js +4 -100
- package/dist/components/2_chatinput_elements/FilePreview/FilePreview.vue2.js +91 -16
- package/dist/components/2_chatinput_elements/FileUploader/FileUploader.vue.js +4 -79
- package/dist/components/2_chatinput_elements/FileUploader/FileUploader.vue2.js +111 -88
- package/dist/components/2_chatinput_elements/FileUploader/icons/FileUploaderIcon.vue.js +17 -15
- package/dist/components/2_chatinput_elements/FileUploader/icons/FileUploaderIcon.vue2.js +2 -13
- package/dist/components/2_chatinput_elements/PlaceholderComponent/PlaceholderComponent.vue.js +33 -39
- package/dist/components/2_chatinput_elements/StickerPicker/StickerPicker.vue.js +4 -220
- package/dist/components/2_chatinput_elements/StickerPicker/StickerPicker.vue2.js +256 -146
- package/dist/components/2_chatinput_elements/StickerPicker/icons/StickerIcon.vue.js +41 -39
- package/dist/components/2_chatinput_elements/StickerPicker/icons/StickerIcon.vue2.js +2 -13
- package/dist/components/2_chatinput_elements/TemplateSelector/TemplateSelector.vue.js +163 -233
- package/dist/components/2_chatinput_elements/TextFormatToolbar/TextFormatToolbar.vue.js +4 -164
- package/dist/components/2_chatinput_elements/TextFormatToolbar/TextFormatToolbar.vue2.js +175 -87
- package/dist/components/2_chatinput_elements/WABAAttachmentSection/WABAAttachmentSection.vue.js +4 -73
- package/dist/components/2_chatinput_elements/WABAAttachmentSection/WABAAttachmentSection.vue2.js +58 -32
- package/dist/components/2_chatinput_elements/WABAQuickReplyButtons/WABAQuickReplyButtons.vue.js +4 -47
- package/dist/components/2_chatinput_elements/WABAQuickReplyButtons/WABAQuickReplyButtons.vue2.js +23 -10
- package/dist/components/2_chatinput_elements/WABASeparatedQuickButtons/WABASeparatedQuickButtons.vue.js +4 -52
- package/dist/components/2_chatinput_elements/WABASeparatedQuickButtons/WABASeparatedQuickButtons.vue2.js +26 -8
- package/dist/components/2_chatinput_elements/WABATemplateSelector/WABATemplateSelector.vue.js +220 -299
- package/dist/components/2_chatlist_elements/ChatFilter/ChatFilter.vue.js +35 -41
- package/dist/components/2_chatlist_elements/ChatItem/ChatItem.vue.js +4 -306
- package/dist/components/2_chatlist_elements/ChatItem/ChatItem.vue2.js +314 -131
- package/dist/components/2_chatlist_elements/ChatItem/icons/AudioIcon.vue.js +12 -18
- package/dist/components/2_chatlist_elements/ChatItem/icons/FileIcon.vue.js +11 -23
- package/dist/components/2_chatlist_elements/ChatItem/icons/ImageIcon.vue.js +7 -7
- package/dist/components/2_chatlist_elements/ChatItem/icons/MissedCallIcon.vue.js +22 -34
- package/dist/components/2_chatlist_elements/ChatItem/icons/StickerIcon.vue.js +9 -15
- package/dist/components/2_chatlist_elements/ChatItem/icons/VideoIcon.vue.js +14 -26
- package/dist/components/2_chatlist_elements/ChatItem/icons/VoiceIcon.vue.js +7 -7
- package/dist/components/2_chatlist_elements/ChatTabs/ChatTabs.vue.js +24 -52
- package/dist/components/2_elements/AudioRecorder/AudioRecorder.vue.js +4 -84
- package/dist/components/2_elements/AudioRecorder/AudioRecorder.vue2.js +68 -36
- package/dist/components/2_elements/ChannelSelector/ChannelSelector.vue.js +37 -71
- package/dist/components/2_elements/ChatInfo/ChatInfo.vue.js +62 -83
- package/dist/components/2_elements/ChatPanel/ChatPanel.vue.js +29 -41
- package/dist/components/2_elements/ContactInfo/ContactInfo.vue.js +115 -176
- package/dist/components/2_elements/ThemeMode/ThemeMode.vue.js +27 -48
- package/dist/components/2_elements/UserProfile/UserProfile.vue.js +28 -58
- package/dist/components/2_elements/VideoRecorder/VideoRecorder.vue.js +4 -54
- package/dist/components/2_elements/VideoRecorder/VideoRecorder.vue2.js +42 -22
- package/dist/components/2_feed_elements/AudioMessage/AudioMessage.vue.js +4 -460
- package/dist/components/2_feed_elements/AudioMessage/AudioMessage.vue2.js +499 -181
- package/dist/components/2_feed_elements/BaseEditMessage/BaseEditMessage.vue.js +4 -19
- package/dist/components/2_feed_elements/BaseEditMessage/BaseEditMessage.vue2.js +22 -12
- package/dist/components/2_feed_elements/BaseReplyMessage/BaseReplyMessage.vue.js +4 -26
- package/dist/components/2_feed_elements/BaseReplyMessage/BaseReplyMessage.vue2.js +39 -26
- package/dist/components/2_feed_elements/CallMessage/CallMessage.vue.js +4 -482
- package/dist/components/2_feed_elements/CallMessage/CallMessage.vue2.js +448 -148
- package/dist/components/2_feed_elements/CallMessage/icons/IncomingCallIcon.vue.js +19 -17
- package/dist/components/2_feed_elements/CallMessage/icons/IncomingCallIcon.vue2.js +2 -13
- package/dist/components/2_feed_elements/CallMessage/icons/OutgoingCallIcon.vue.js +19 -17
- package/dist/components/2_feed_elements/CallMessage/icons/OutgoingCallIcon.vue2.js +2 -13
- package/dist/components/2_feed_elements/DateMessage/DateMessage.vue.js +4 -17
- package/dist/components/2_feed_elements/DateMessage/DateMessage.vue2.js +7 -7
- package/dist/components/2_feed_elements/DateMessageSticky/DateMessageSticky.vue.js +3 -16
- package/dist/components/2_feed_elements/DateMessageSticky/DateMessageSticky.vue2.js +7 -7
- package/dist/components/2_feed_elements/DeletedMessageContent/DeletedMessageContent.vue.js +4 -67
- package/dist/components/2_feed_elements/DeletedMessageContent/DeletedMessageContent.vue2.js +43 -11
- package/dist/components/2_feed_elements/DelimiterMessage/DelimiterMessage.vue.js +4 -47
- package/dist/components/2_feed_elements/DelimiterMessage/DelimiterMessage.vue2.js +46 -37
- package/dist/components/2_feed_elements/EditTextMessage/EditTextMessage.vue.js +4 -22
- package/dist/components/2_feed_elements/EditTextMessage/EditTextMessage.vue2.js +15 -8
- package/dist/components/2_feed_elements/FeedKeyboard/FeedKeyboard.vue.js +4 -43
- package/dist/components/2_feed_elements/FeedKeyboard/FeedKeyboard.vue2.js +25 -10
- package/dist/components/2_feed_elements/FeedReplyQuote/FeedReplyQuote.vue.js +4 -52
- package/dist/components/2_feed_elements/FeedReplyQuote/FeedReplyQuote.vue2.js +39 -16
- package/dist/components/2_feed_elements/FileMessage/FileMessage.vue.js +4 -270
- package/dist/components/2_feed_elements/FileMessage/FileMessage.vue2.js +274 -95
- package/dist/components/2_feed_elements/ImageMessage/ImageMessage.vue.js +4 -409
- package/dist/components/2_feed_elements/ImageMessage/ImageMessage.vue2.js +422 -143
- package/dist/components/2_feed_elements/MessageKeyboard/MessageKeyboard.vue.js +4 -39
- package/dist/components/2_feed_elements/MessageKeyboard/MessageKeyboard.vue2.js +22 -12
- package/dist/components/2_feed_elements/MessageReactions/MessageReactions.vue.js +4 -57
- package/dist/components/2_feed_elements/MessageReactions/MessageReactions.vue2.js +69 -41
- package/dist/components/2_feed_elements/MessageReactions/MessageReactionsOverlay.vue.js +4 -97
- package/dist/components/2_feed_elements/MessageReactions/MessageReactionsOverlay.vue2.js +173 -102
- package/dist/components/2_feed_elements/MessageReactions/icons/DeleteIcon.vue.js +20 -32
- package/dist/components/2_feed_elements/MessageReactions/icons/EditIcon.vue.js +20 -32
- package/dist/components/2_feed_elements/MessageReactions/icons/ExpandReactionsIcon.vue.js +11 -17
- package/dist/components/2_feed_elements/MessageReactions/icons/MessageActionsIcon.vue.js +10 -16
- package/dist/components/2_feed_elements/MessageReactions/icons/ReplyIcon.vue.js +11 -17
- package/dist/components/2_feed_elements/MessageSmsInvite/MessageSmsInvite.vue.js +4 -22
- package/dist/components/2_feed_elements/MessageSmsInvite/MessageSmsInvite.vue2.js +23 -17
- package/dist/components/2_feed_elements/MessageStatusIndicator/MessageStatusIndicator.vue.js +4 -28
- package/dist/components/2_feed_elements/MessageStatusIndicator/MessageStatusIndicator.vue2.js +29 -27
- package/dist/components/2_feed_elements/MissedCallMessage/MissedCallMessage.vue.js +4 -142
- package/dist/components/2_feed_elements/MissedCallMessage/MissedCallMessage.vue2.js +121 -33
- package/dist/components/2_feed_elements/MissedCallMessage/icons/MissedCallIcon.vue.js +22 -34
- package/dist/components/2_feed_elements/ReplyAudioMessage/ReplyAudioMessage.vue.js +4 -55
- package/dist/components/2_feed_elements/ReplyAudioMessage/ReplyAudioMessage.vue2.js +30 -8
- package/dist/components/2_feed_elements/ReplyCallMessage/ReplyCallMessage.vue.js +4 -47
- package/dist/components/2_feed_elements/ReplyCallMessage/ReplyCallMessage.vue2.js +25 -9
- package/dist/components/2_feed_elements/ReplyFileMessage/ReplyFileMessage.vue.js +4 -56
- package/dist/components/2_feed_elements/ReplyFileMessage/ReplyFileMessage.vue2.js +37 -8
- package/dist/components/2_feed_elements/ReplyImageMessage/ReplyImageMessage.vue.js +4 -72
- package/dist/components/2_feed_elements/ReplyImageMessage/ReplyImageMessage.vue2.js +59 -10
- package/dist/components/2_feed_elements/ReplyStickerMessage/ReplyStickerMessage.vue.js +4 -142
- package/dist/components/2_feed_elements/ReplyStickerMessage/ReplyStickerMessage.vue2.js +118 -34
- package/dist/components/2_feed_elements/ReplyTextMessage/ReplyTextMessage.vue.js +4 -49
- package/dist/components/2_feed_elements/ReplyTextMessage/ReplyTextMessage.vue2.js +53 -15
- package/dist/components/2_feed_elements/ReplyVideoMessage/ReplyVideoMessage.vue.js +4 -94
- package/dist/components/2_feed_elements/ReplyVideoMessage/ReplyVideoMessage.vue2.js +76 -10
- package/dist/components/2_feed_elements/SplashScreen/SplashScreen.vue.js +4 -18
- package/dist/components/2_feed_elements/SplashScreen/SplashScreen.vue2.js +17 -9
- package/dist/components/2_feed_elements/StickerMessage/StickerMessage.vue.js +4 -348
- package/dist/components/2_feed_elements/StickerMessage/StickerMessage.vue2.js +339 -97
- package/dist/components/2_feed_elements/SystemMessage/SystemMessage.vue.js +4 -17
- package/dist/components/2_feed_elements/SystemMessage/SystemMessage.vue2.js +7 -7
- package/dist/components/2_feed_elements/TextMessage/TextMessage.vue.js +4 -308
- package/dist/components/2_feed_elements/TextMessage/TextMessage.vue2.js +299 -89
- package/dist/components/2_feed_elements/TypingMessage/TypingMessage.vue.js +4 -37
- package/dist/components/2_feed_elements/TypingMessage/TypingMessage.vue2.js +21 -7
- package/dist/components/2_feed_elements/VideoMessage/VideoMessage.vue.js +4 -321
- package/dist/components/2_feed_elements/VideoMessage/VideoMessage.vue2.js +338 -96
- package/dist/components/2_modals/ConfirmDeleteMessage/ConfirmDeleteMessage.vue.js +4 -64
- package/dist/components/2_modals/ConfirmDeleteMessage/ConfirmDeleteMessage.vue3.js +45 -10
- package/dist/components/2_modals/CreateChat/CreateChat.vue.js +19 -36
- package/dist/components/2_modals/CreateChat2/CreateChat2.vue.js +92 -140
- package/dist/components/2_modals/CreateDialog/CreateDialog.vue.js +49 -96
- package/dist/components/2_modals/Modal/Modal.vue.js +50 -59
- package/dist/components/2_modals/ModalFullscreen/ModalFullscreen.vue.js +38 -51
- package/dist/components/2_modals/ModalNoFooter/ModalNoFooter.vue.js +30 -39
- package/dist/components/2_modals/ModalVideoRecorder/ModalVideoRecorder.vue.js +4 -155
- package/dist/components/2_modals/ModalVideoRecorder/ModalVideoRecorder.vue2.js +121 -49
- package/dist/components/2_modals/SelectUser/SelectUser.vue.js +43 -60
- package/dist/components/2_modals/SelectUser2/SelectUser2.vue.js +24 -41
- package/dist/components/3_compounds/ChatInput/ChatInput.vue.js +4 -170
- package/dist/components/3_compounds/ChatInput/ChatInput.vue2.js +336 -239
- package/dist/components/3_compounds/ChatInput/icons/ArrowIcon.vue.js +25 -43
- package/dist/components/3_compounds/ChatInput/icons/SendIcon.vue.js +21 -25
- package/dist/components/3_compounds/ChatInput/icons/SendIcon.vue2.js +2 -13
- package/dist/components/3_compounds/ChatList/ChatList.vue.js +166 -256
- package/dist/components/3_compounds/ChatList/ChatListHeader.vue.js +39 -57
- package/dist/components/3_compounds/ChatList/icons/LogoIcon.vue.js +6 -6
- package/dist/components/3_compounds/Feed/Feed.vue.js +4 -185
- package/dist/components/3_compounds/Feed/Feed.vue2.js +314 -161
- package/dist/components/3_compounds/Feed/composables/useFeedScroll.js +19 -17
- package/dist/components/3_compounds/SideBar/SideBar.vue.js +202 -279
- package/dist/components/4_layouts/AdaptiveExtendedLayout/AdaptiveExtendedLayout.vue.js +36 -43
- package/dist/components/4_layouts/BaseLayout/BaseLayout.vue.js +5 -5
- package/dist/components/4_layouts/ChatWrapper/ChatWrapper.vue.js +4 -32
- package/dist/components/4_layouts/ChatWrapper/ChatWrapper.vue2.js +29 -7
- package/dist/components/4_layouts/ExtendedLayout/ExtendedLayout.vue.js +7 -7
- package/dist/components/4_layouts/FeedLayout/FeedLayout.vue.js +8 -8
- package/dist/components/5_containers/BaseContainer/BaseContainer.vue.js +18 -33
- package/dist/components/5_containers/FloatContainer/FloatContainer.vue.js +59 -90
- package/dist/types/src/components/3_compounds/Feed/composables/useFeedScroll.d.ts +2 -0
- package/package.json +1 -1
|
@@ -1,31 +1,55 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import { useMessageActions as
|
|
12
|
-
import { useMessageHoverActions as
|
|
13
|
-
import { useMessageReactionsInFeed as
|
|
14
|
-
import { useMessageMenuActions as
|
|
15
|
-
import { useMessageLinks as
|
|
16
|
-
import { useChannelAccentColor as
|
|
17
|
-
import { useSubtextTooltip as
|
|
18
|
-
import { useStartReply as
|
|
1
|
+
import { defineComponent as us, ref as g, computed as r, inject as ls, watch as G, createElementBlock as m, openBlock as l, unref as o, normalizeStyle as Y, normalizeClass as C, createCommentVNode as d, createElementVNode as i, createVNode as w, withCtx as Z, createTextVNode as rs, toDisplayString as p, Fragment as q, createBlock as k, withDirectives as z, vShow as Ce, vModelText as ms, Transition as we, Teleport as ds, nextTick as cs } from "vue";
|
|
2
|
+
import vs from "../../1_atoms/ContextMenu/ContextMenu.vue.js";
|
|
3
|
+
import gs from "../../1_atoms/LinkPreview/LinkPreview.vue.js";
|
|
4
|
+
import fs from "../../1_atoms/EmbedPreview/EmbedPreview.vue.js";
|
|
5
|
+
import ys from "../FeedReplyQuote/FeedReplyQuote.vue.js";
|
|
6
|
+
import ps from "../MessageReactions/MessageReactions.vue.js";
|
|
7
|
+
import xe from "../MessageStatusIndicator/MessageStatusIndicator.vue.js";
|
|
8
|
+
import hs from "../MessageSmsInvite/MessageSmsInvite.vue.js";
|
|
9
|
+
import bs from "../DeletedMessageContent/DeletedMessageContent.vue.js";
|
|
10
|
+
import Cs from "../../1_atoms/Tooltip/Tooltip.vue.js";
|
|
11
|
+
import { useMessageActions as ws } from "../../../hooks/messages/useMessageActions.js";
|
|
12
|
+
import { useMessageHoverActions as xs } from "../../../hooks/messages/useMessageHoverActions.js";
|
|
13
|
+
import { useMessageReactionsInFeed as Ms } from "../../../hooks/messages/useMessageReactionsInFeed.js";
|
|
14
|
+
import { useMessageMenuActions as ks } from "../../../hooks/messages/useMessageMenuActions.js";
|
|
15
|
+
import { useMessageLinks as Rs } from "../../../hooks/messages/useMessageLinks.js";
|
|
16
|
+
import { useChannelAccentColor as Ts } from "../../../hooks/messages/useChannelAccentColor.js";
|
|
17
|
+
import { useSubtextTooltip as Ss } from "../../../hooks/messages/useSubtextTooltip.js";
|
|
18
|
+
import { useStartReply as Is } from "../../../hooks/messages/useStartReply.js";
|
|
19
19
|
/* empty css */
|
|
20
20
|
/* empty css */
|
|
21
21
|
import "../../../locale/useLocale.js";
|
|
22
22
|
/* empty css */
|
|
23
|
-
import { buildReplyPayload as
|
|
24
|
-
import { getStatus as
|
|
25
|
-
import { getMessageClass as
|
|
26
|
-
import { createReactionHandlers as
|
|
23
|
+
import { buildReplyPayload as Me } from "../../../hooks/messages/buildReplyPayload.js";
|
|
24
|
+
import { getStatus as Ns, getStatusTitle as _s } from "../../../functions/getStatusMessage.js";
|
|
25
|
+
import { getMessageClass as Es } from "../../../functions/getMessageClass.js";
|
|
26
|
+
import { createReactionHandlers as As } from "../../../functions/createReactionHandlers.js";
|
|
27
27
|
import "../../../functions/parseMarkdown.js";
|
|
28
|
-
const
|
|
28
|
+
const Fs = ["messageId"], Ls = ["src"], Os = {
|
|
29
|
+
key: 1,
|
|
30
|
+
class: "audio-message__subtext"
|
|
31
|
+
}, Ps = { class: "audio-message__footer" }, Ds = { class: "audio-message__info-container" }, Us = {
|
|
32
|
+
key: 0,
|
|
33
|
+
class: "audio-message__time"
|
|
34
|
+
}, $s = { class: "audio-message__audio-container" }, Hs = ["src"], Vs = { class: "audio-message__progress-wrapper" }, Bs = ["max"], js = { class: "audio-message__speed-btn-container" }, Gs = { class: "audio-message__player-controls" }, Ys = { class: "audio-message__current-time" }, Zs = { class: "audio-message__duration" }, qs = {
|
|
35
|
+
key: 1,
|
|
36
|
+
class: "audio-message__text-container"
|
|
37
|
+
}, zs = ["innerHTML"], Qs = { class: "audio-message__footer" }, Ws = { class: "audio-message__info-container" }, Js = {
|
|
38
|
+
key: 0,
|
|
39
|
+
class: "audio-message__actions"
|
|
40
|
+
}, Ks = { class: "audio-message__time" }, Xs = {
|
|
41
|
+
key: 0,
|
|
42
|
+
class: "audio-message__expand-panel"
|
|
43
|
+
}, et = { class: "audio-message__expand-inner" }, st = {
|
|
44
|
+
key: 0,
|
|
45
|
+
class: "audio-message__expand-placeholder"
|
|
46
|
+
}, tt = ["innerHTML"], at = {
|
|
47
|
+
key: 1,
|
|
48
|
+
class: "audio-message__expand-plain"
|
|
49
|
+
}, nt = {
|
|
50
|
+
key: 0,
|
|
51
|
+
class: "audio-message__expand-placeholder"
|
|
52
|
+
}, ot = ["innerHTML"], it = { class: "audio-message__expand-close-wrap" }, ut = "RECOGNITION_READY", lt = "SUMMARY_READY", Dt = /* @__PURE__ */ us({
|
|
29
53
|
__name: "AudioMessage",
|
|
30
54
|
props: {
|
|
31
55
|
message: {
|
|
@@ -47,7 +71,7 @@ const se = "RECOGNITION_READY", oe = "SUMMARY_READY", zt = /* @__PURE__ */ ze({
|
|
|
47
71
|
reactionsMode: {
|
|
48
72
|
type: String,
|
|
49
73
|
default: "single",
|
|
50
|
-
validator: (
|
|
74
|
+
validator: (t) => ["single", "multi"].includes(t)
|
|
51
75
|
},
|
|
52
76
|
currentUserId: {
|
|
53
77
|
type: [String, Number],
|
|
@@ -69,9 +93,8 @@ const se = "RECOGNITION_READY", oe = "SUMMARY_READY", zt = /* @__PURE__ */ ze({
|
|
|
69
93
|
}
|
|
70
94
|
},
|
|
71
95
|
emits: ["action", "reply", "sms-invite"],
|
|
72
|
-
setup(
|
|
73
|
-
|
|
74
|
-
const n = N, R = u([
|
|
96
|
+
setup(t, { emit: ke }) {
|
|
97
|
+
const u = t, O = g([
|
|
75
98
|
{
|
|
76
99
|
text: "1.0x",
|
|
77
100
|
speed: 1
|
|
@@ -88,96 +111,96 @@ const se = "RECOGNITION_READY", oe = "SUMMARY_READY", zt = /* @__PURE__ */ ze({
|
|
|
88
111
|
text: "2.0x",
|
|
89
112
|
speed: 2
|
|
90
113
|
}
|
|
91
|
-
]),
|
|
92
|
-
|
|
93
|
-
},
|
|
94
|
-
() =>
|
|
95
|
-
() =>
|
|
96
|
-
() =>
|
|
97
|
-
),
|
|
98
|
-
var
|
|
99
|
-
const e =
|
|
100
|
-
return e.url || (typeof ((
|
|
101
|
-
}),
|
|
114
|
+
]), P = g(0), D = r(() => O.value[P.value] ?? O.value[0]), Re = () => {
|
|
115
|
+
P.value = (P.value + 1) % O.value.length, n.value && (n.value.playbackRate = D.value.speed);
|
|
116
|
+
}, R = ke, { menuActions: S } = ks(() => u.message), { hoverActionsEnabled: Q, reactionsActive: W } = xs(
|
|
117
|
+
() => u.channel,
|
|
118
|
+
() => u.reactionsEnabled,
|
|
119
|
+
() => u.message
|
|
120
|
+
), Te = ls("chatAppId"), { startReply: Se } = Is(Te || ""), n = g(null), x = g(void 0), c = g(!1), h = g(0), f = g(0), b = g(!1), U = r(() => {
|
|
121
|
+
var s, a;
|
|
122
|
+
const e = u.message;
|
|
123
|
+
return e.url || (typeof ((s = e.meta) == null ? void 0 : s.url) == "string" ? e.meta.url : void 0) || ((a = e.data) == null ? void 0 : a.url);
|
|
124
|
+
}), $ = (e) => {
|
|
102
125
|
if (e == null) return;
|
|
103
126
|
if (typeof e == "number")
|
|
104
127
|
return !Number.isFinite(e) || e < 0 ? void 0 : Math.floor(e);
|
|
105
|
-
const
|
|
106
|
-
if (!
|
|
107
|
-
if (/^\d+$/.test(
|
|
108
|
-
const
|
|
109
|
-
return Number.isFinite(
|
|
128
|
+
const s = String(e).trim();
|
|
129
|
+
if (!s) return;
|
|
130
|
+
if (/^\d+$/.test(s)) {
|
|
131
|
+
const v = Number(s);
|
|
132
|
+
return Number.isFinite(v) && v >= 0 ? Math.floor(v) : void 0;
|
|
110
133
|
}
|
|
111
|
-
const
|
|
112
|
-
if (
|
|
113
|
-
const
|
|
114
|
-
return
|
|
134
|
+
const a = s.match(/^(\d+):([0-5]\d):([0-5]\d)$/);
|
|
135
|
+
if (a) {
|
|
136
|
+
const v = Number(a[1]), B = Number(a[2]), j = Number(a[3]);
|
|
137
|
+
return v * 3600 + B * 60 + j;
|
|
115
138
|
}
|
|
116
|
-
const
|
|
117
|
-
if (
|
|
118
|
-
},
|
|
119
|
-
|
|
139
|
+
const M = s.match(/^(\d+):([0-5]\d)$/);
|
|
140
|
+
if (M) return Number(M[1]) * 60 + Number(M[2]);
|
|
141
|
+
}, J = () => {
|
|
142
|
+
c.value = !1, f.value = 0, h.value = $(u.message.duration) ?? 0, b.value = !1;
|
|
120
143
|
};
|
|
121
|
-
|
|
122
|
-
() =>
|
|
123
|
-
(e,
|
|
124
|
-
e !==
|
|
144
|
+
J(), G(
|
|
145
|
+
() => U.value,
|
|
146
|
+
(e, s) => {
|
|
147
|
+
e !== s && (J(), x.value = void 0, n.value && (n.value.pause(), n.value.currentTime = 0, n.value.removeAttribute("src"), n.value.load()));
|
|
125
148
|
}
|
|
126
|
-
),
|
|
127
|
-
() =>
|
|
149
|
+
), G(
|
|
150
|
+
() => u.message.duration,
|
|
128
151
|
() => {
|
|
129
|
-
|
|
152
|
+
x.value === void 0 && (h.value = $(u.message.duration) ?? 0);
|
|
130
153
|
}
|
|
131
154
|
);
|
|
132
155
|
const {
|
|
133
|
-
isOpenMenu:
|
|
134
|
-
buttonMenuVisible:
|
|
135
|
-
menuAnchorRef:
|
|
136
|
-
menuRef:
|
|
137
|
-
menuStyle:
|
|
138
|
-
menuTheme:
|
|
139
|
-
showMenu:
|
|
140
|
-
hideMenu:
|
|
141
|
-
openMenu:
|
|
142
|
-
toggleMenu:
|
|
143
|
-
onMenuMouseEnter:
|
|
144
|
-
onMenuMouseLeave:
|
|
145
|
-
clickAction:
|
|
146
|
-
viewsAction:
|
|
147
|
-
handleClickReplied:
|
|
148
|
-
} =
|
|
149
|
-
onReply: () =>
|
|
150
|
-
}),
|
|
151
|
-
var
|
|
152
|
-
const e =
|
|
153
|
-
return !
|
|
154
|
-
}),
|
|
155
|
-
var
|
|
156
|
-
const e =
|
|
157
|
-
return !
|
|
158
|
-
}),
|
|
159
|
-
var
|
|
160
|
-
const e = (
|
|
156
|
+
isOpenMenu: Ie,
|
|
157
|
+
buttonMenuVisible: Ne,
|
|
158
|
+
menuAnchorRef: _e,
|
|
159
|
+
menuRef: Ee,
|
|
160
|
+
menuStyle: Ae,
|
|
161
|
+
menuTheme: Fe,
|
|
162
|
+
showMenu: Le,
|
|
163
|
+
hideMenu: H,
|
|
164
|
+
openMenu: Oe,
|
|
165
|
+
toggleMenu: K,
|
|
166
|
+
onMenuMouseEnter: Pe,
|
|
167
|
+
onMenuMouseLeave: De,
|
|
168
|
+
clickAction: Ue,
|
|
169
|
+
viewsAction: X,
|
|
170
|
+
handleClickReplied: $e
|
|
171
|
+
} = ws(u.message, R, {
|
|
172
|
+
onReply: () => Se(Me(u.message, "message.audio"))
|
|
173
|
+
}), y = g(null), I = g({ text: !1, summary: !1 }), N = r(() => {
|
|
174
|
+
var a;
|
|
175
|
+
const e = u.message, s = e.transcript ?? ((a = e.meta) == null ? void 0 : a.transcript);
|
|
176
|
+
return !s || typeof s != "object" ? null : s;
|
|
177
|
+
}), _ = r(() => {
|
|
178
|
+
var a;
|
|
179
|
+
const e = u.message, s = e.summary ?? ((a = e.meta) == null ? void 0 : a.summary);
|
|
180
|
+
return !s || typeof s != "object" ? null : s;
|
|
181
|
+
}), ee = r(() => {
|
|
182
|
+
var s;
|
|
183
|
+
const e = (s = N.value) == null ? void 0 : s.html;
|
|
161
184
|
return typeof e != "string" ? "" : e.trim();
|
|
162
|
-
}),
|
|
185
|
+
}), se = r(() => {
|
|
163
186
|
var e;
|
|
164
|
-
return ((e =
|
|
165
|
-
}),
|
|
166
|
-
var
|
|
167
|
-
const e = (
|
|
187
|
+
return ((e = N.value) == null ? void 0 : e.status) === ut && ee.value.length > 0;
|
|
188
|
+
}), te = r(() => {
|
|
189
|
+
var s;
|
|
190
|
+
const e = (s = _.value) == null ? void 0 : s.html;
|
|
168
191
|
return typeof e != "string" ? "" : e.trim();
|
|
169
|
-
}),
|
|
192
|
+
}), ae = r(() => {
|
|
170
193
|
var e;
|
|
171
|
-
return ((e =
|
|
172
|
-
}),
|
|
194
|
+
return ((e = _.value) == null ? void 0 : e.status) === lt && te.value.length > 0;
|
|
195
|
+
}), E = r(() => {
|
|
173
196
|
var e;
|
|
174
|
-
return !!((e =
|
|
175
|
-
}),
|
|
197
|
+
return !!((e = N.value) != null && e.status);
|
|
198
|
+
}), A = r(() => {
|
|
176
199
|
var e;
|
|
177
|
-
return !!((e =
|
|
178
|
-
}),
|
|
200
|
+
return !!((e = _.value) != null && e.status);
|
|
201
|
+
}), He = r(() => y.value === "text" ? E.value : y.value === "summary" ? A.value : !1), Ve = r(() => {
|
|
179
202
|
var e;
|
|
180
|
-
switch ((e =
|
|
203
|
+
switch ((e = N.value) == null ? void 0 : e.status) {
|
|
181
204
|
case "RECOGNITION_PLANNED":
|
|
182
205
|
return "Распознаем сообщение, пожалуйста подождите...";
|
|
183
206
|
case "RECOGNITION_ERROR":
|
|
@@ -187,9 +210,9 @@ const se = "RECOGNITION_READY", oe = "SUMMARY_READY", zt = /* @__PURE__ */ ze({
|
|
|
187
210
|
default:
|
|
188
211
|
return "Текст сообщения недоступен";
|
|
189
212
|
}
|
|
190
|
-
}),
|
|
213
|
+
}), Be = r(() => {
|
|
191
214
|
var e;
|
|
192
|
-
switch ((e =
|
|
215
|
+
switch ((e = _.value) == null ? void 0 : e.status) {
|
|
193
216
|
case "SUMMARY_PLANNED":
|
|
194
217
|
return "Формируем резюме, пожалуйста подождите...";
|
|
195
218
|
case "SUMMARY_ERROR":
|
|
@@ -199,19 +222,19 @@ const se = "RECOGNITION_READY", oe = "SUMMARY_READY", zt = /* @__PURE__ */ ze({
|
|
|
199
222
|
default:
|
|
200
223
|
return "Резюме недоступно";
|
|
201
224
|
}
|
|
202
|
-
}),
|
|
203
|
-
var
|
|
204
|
-
const e =
|
|
225
|
+
}), je = async () => {
|
|
226
|
+
var s, a, M;
|
|
227
|
+
const e = U.value;
|
|
205
228
|
if (e)
|
|
206
229
|
try {
|
|
207
|
-
const
|
|
230
|
+
const v = await fetch(e, {
|
|
208
231
|
headers: {
|
|
209
232
|
Accept: "audio/*"
|
|
210
233
|
}
|
|
211
234
|
});
|
|
212
|
-
if (!
|
|
213
|
-
throw new Error(`HTTP error! status: ${
|
|
214
|
-
const
|
|
235
|
+
if (!v.ok)
|
|
236
|
+
throw new Error(`HTTP error! status: ${v.status}`);
|
|
237
|
+
const B = v.headers.get("content-type") || "", j = await v.blob(), F = ((a = (s = e.split(".").pop()) == null ? void 0 : s.split("?")[0]) == null ? void 0 : a.toLowerCase()) || "", os = {
|
|
215
238
|
"audio/mpeg": "mp3",
|
|
216
239
|
"audio/mp3": "mp3",
|
|
217
240
|
"audio/wav": "wav",
|
|
@@ -222,98 +245,393 @@ const se = "RECOGNITION_READY", oe = "SUMMARY_READY", zt = /* @__PURE__ */ ze({
|
|
|
222
245
|
"audio/flac": "flac",
|
|
223
246
|
"audio/m4a": "m4a",
|
|
224
247
|
"audio/x-m4a": "m4a",
|
|
225
|
-
"application/octet-stream":
|
|
226
|
-
},
|
|
227
|
-
|
|
228
|
-
} catch (
|
|
229
|
-
console.error("Ошибка при скачивании аудио:",
|
|
248
|
+
"application/octet-stream": F || "mp3"
|
|
249
|
+
}, pe = F && ["mp3", "wav", "ogg", "webm", "aac", "flac", "m4a"].includes(F) ? F : os[B] || "mp3", he = e.split("/"), L = decodeURIComponent(((M = he[he.length - 1]) == null ? void 0 : M.split("?")[0]) || ""), is = L ? L.includes(".") ? L : `${L}.${pe}` : `audio-${u.message.messageId}.${pe}`, be = window.URL.createObjectURL(j), T = document.createElement("a");
|
|
250
|
+
T.href = be, T.download = is, document.body.appendChild(T), T.click(), document.body.removeChild(T), window.URL.revokeObjectURL(be);
|
|
251
|
+
} catch (v) {
|
|
252
|
+
console.error("Ошибка при скачивании аудио:", v), e && window.open(e, "_blank");
|
|
230
253
|
}
|
|
231
|
-
},
|
|
232
|
-
e.action === "download" ? (
|
|
233
|
-
}, { linkedHtml:
|
|
234
|
-
|
|
254
|
+
}, Ge = (e) => {
|
|
255
|
+
e.action === "download" ? (je(), H()) : Ue(e);
|
|
256
|
+
}, { linkedHtml: Ye, inNewWindow: ne } = Rs(() => u.message.text), oe = r(() => Ns(u.message.status)), ie = r(() => _s(u.message.status, u.message.statusMsg)), { bubbleStyle: Ze } = Ts(
|
|
257
|
+
r(() => u.message),
|
|
235
258
|
{ cssVariable: "--chotto-audiomessage-right-background-color", position: "right" }
|
|
236
|
-
),
|
|
237
|
-
const e =
|
|
238
|
-
if (!(!
|
|
239
|
-
if (
|
|
240
|
-
|
|
259
|
+
), ue = async () => {
|
|
260
|
+
const e = U.value;
|
|
261
|
+
if (!(!n.value || !e))
|
|
262
|
+
if (c.value)
|
|
263
|
+
n.value.pause(), c.value = !1;
|
|
241
264
|
else
|
|
242
265
|
try {
|
|
243
|
-
|
|
244
|
-
} catch (
|
|
245
|
-
console.error("Не удалось воспроизвести аудио",
|
|
266
|
+
x.value || (x.value = e, await cs(), n.value.load()), await n.value.play(), c.value = !0;
|
|
267
|
+
} catch (s) {
|
|
268
|
+
console.error("Не удалось воспроизвести аудио", s), c.value = !1;
|
|
246
269
|
}
|
|
247
|
-
},
|
|
248
|
-
const
|
|
249
|
-
return `${
|
|
250
|
-
},
|
|
251
|
-
|
|
252
|
-
() =>
|
|
270
|
+
}, le = (e) => {
|
|
271
|
+
const s = Math.floor(e / 60), a = Math.floor(e % 60);
|
|
272
|
+
return `${s.toString().padStart(2, "0")}:${a.toString().padStart(2, "0")}`;
|
|
273
|
+
}, qe = r(() => le(f.value));
|
|
274
|
+
G(
|
|
275
|
+
() => f.value,
|
|
253
276
|
() => {
|
|
254
|
-
|
|
277
|
+
n.value && b.value && (n.value.duration != 1 / 0 && !Number.isNaN(n.value.duration) && (n.value.currentTime = f.value), Math.abs(f.value - h.value) < 0.1 && (c.value = !1));
|
|
255
278
|
}
|
|
256
279
|
);
|
|
257
|
-
const
|
|
258
|
-
|
|
259
|
-
},
|
|
260
|
-
if (!
|
|
261
|
-
const e =
|
|
262
|
-
if (
|
|
280
|
+
const re = () => {
|
|
281
|
+
n.value && b.value && n.value.duration != 1 / 0 && !Number.isNaN(n.value.duration) && (n.value.currentTime = f.value), b.value = !1;
|
|
282
|
+
}, ze = r(() => le(h.value)), Qe = () => {
|
|
283
|
+
if (!n.value) return;
|
|
284
|
+
const e = n.value;
|
|
285
|
+
if (f.value = e.currentTime || 0, e.duration === 1 / 0 || Number.isNaN(e.duration)) {
|
|
263
286
|
e.currentTime = 1e101;
|
|
264
|
-
const
|
|
265
|
-
|
|
287
|
+
const s = () => {
|
|
288
|
+
n.value && (h.value = n.value.duration || 0, f.value = 0, n.value.currentTime = 0);
|
|
266
289
|
};
|
|
267
|
-
e.addEventListener("timeupdate",
|
|
290
|
+
e.addEventListener("timeupdate", s, { once: !0 });
|
|
268
291
|
} else
|
|
269
|
-
|
|
270
|
-
e.playbackRate =
|
|
271
|
-
},
|
|
272
|
-
|
|
273
|
-
},
|
|
274
|
-
|
|
275
|
-
},
|
|
276
|
-
console.error("Не удалось загрузить аудио"),
|
|
292
|
+
h.value = e.duration || 0;
|
|
293
|
+
e.playbackRate = D.value.speed;
|
|
294
|
+
}, We = () => {
|
|
295
|
+
n.value && (b.value || (f.value = n.value.currentTime), n.value.ended && c.value && (c.value = !1));
|
|
296
|
+
}, Je = () => {
|
|
297
|
+
c.value = !1;
|
|
298
|
+
}, Ke = () => {
|
|
299
|
+
console.error("Не удалось загрузить аудио"), c.value = !1, x.value = void 0, n.value && (n.value.pause(), n.value.currentTime = 0, n.value.removeAttribute("src"), n.value.load()), h.value = $(u.message.duration) ?? 0;
|
|
277
300
|
};
|
|
278
|
-
function
|
|
279
|
-
return
|
|
301
|
+
function V(e) {
|
|
302
|
+
return Es(e.position, "audio-message");
|
|
280
303
|
}
|
|
281
|
-
const { onToggleReaction:
|
|
282
|
-
var
|
|
283
|
-
const e = (
|
|
304
|
+
const { onToggleReaction: me, onAddReaction: de, onRemoveReaction: ce } = As(R), ve = g(null), ge = g(null), Xe = r(() => {
|
|
305
|
+
var s;
|
|
306
|
+
const e = (s = ge.value) == null ? void 0 : s.$el;
|
|
284
307
|
return e instanceof HTMLElement ? e : null;
|
|
285
|
-
}), { showReactions:
|
|
286
|
-
message: () =>
|
|
287
|
-
messageId: () =>
|
|
288
|
-
reactions: () =>
|
|
289
|
-
reactionsActive:
|
|
290
|
-
reactionsMode: () =>
|
|
291
|
-
reply: () =>
|
|
292
|
-
menuEnabled: () =>
|
|
293
|
-
contentRef:
|
|
294
|
-
chipsRef:
|
|
308
|
+
}), { showReactions: es, onContentPointerEnter: fe, onContentPointerLeave: ye } = Ms({
|
|
309
|
+
message: () => u.message,
|
|
310
|
+
messageId: () => u.message.messageId,
|
|
311
|
+
reactions: () => u.message.reactions,
|
|
312
|
+
reactionsActive: W,
|
|
313
|
+
reactionsMode: () => u.reactionsMode,
|
|
314
|
+
reply: () => Me(u.message, "message.audio"),
|
|
315
|
+
menuEnabled: () => S.value.length > 0,
|
|
316
|
+
contentRef: ve,
|
|
317
|
+
chipsRef: Xe,
|
|
295
318
|
handlers: {
|
|
296
|
-
onToggleReaction:
|
|
297
|
-
onAddReaction:
|
|
298
|
-
onRemoveReaction:
|
|
299
|
-
onMenu:
|
|
319
|
+
onToggleReaction: me,
|
|
320
|
+
onAddReaction: de,
|
|
321
|
+
onRemoveReaction: ce,
|
|
322
|
+
onMenu: Oe
|
|
300
323
|
}
|
|
301
|
-
}),
|
|
302
|
-
function
|
|
303
|
-
|
|
324
|
+
}), ss = Ss(() => u.message, () => u.subtextTooltipData);
|
|
325
|
+
function ts() {
|
|
326
|
+
R("sms-invite", u.message);
|
|
304
327
|
}
|
|
305
|
-
const
|
|
328
|
+
const as = () => {
|
|
329
|
+
if (!E.value) return;
|
|
330
|
+
const e = y.value === "text" ? null : "text";
|
|
331
|
+
y.value = e, e === "text" && !se.value && !I.value.text && (I.value.text = !0, R("action", { action: "fetchTranscript", messageId: u.message.messageId }));
|
|
332
|
+
}, ns = () => {
|
|
306
333
|
if (!A.value) return;
|
|
307
|
-
const e =
|
|
308
|
-
|
|
309
|
-
}
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
334
|
+
const e = y.value === "summary" ? null : "summary";
|
|
335
|
+
y.value = e, e === "summary" && !ae.value && !I.value.summary && (I.value.summary = !0, R("action", { action: "fetchSummary", messageId: u.message.messageId }));
|
|
336
|
+
};
|
|
337
|
+
return (e, s) => (l(), m("div", {
|
|
338
|
+
ref_key: "menuAnchorRef",
|
|
339
|
+
ref: _e,
|
|
340
|
+
class: C(["audio-message", [
|
|
341
|
+
V(t.message),
|
|
342
|
+
t.applyStyle(t.message)
|
|
343
|
+
]]),
|
|
344
|
+
messageId: t.message.messageId,
|
|
345
|
+
style: Y(o(Ze)),
|
|
346
|
+
onMouseleave: s[10] || (s[10] = //@ts-ignore
|
|
347
|
+
(...a) => o(H) && o(H)(...a))
|
|
348
|
+
}, [
|
|
349
|
+
t.message.avatar && t.isFirstInSeries ? (l(), m("img", {
|
|
350
|
+
key: 0,
|
|
351
|
+
class: "audio-message__avatar",
|
|
352
|
+
src: t.message.avatar,
|
|
353
|
+
height: "32",
|
|
354
|
+
width: "32",
|
|
355
|
+
style: Y({ gridRow: t.message.subText ? "2" : "1" })
|
|
356
|
+
}, null, 12, Ls)) : d("", !0),
|
|
357
|
+
t.message.subText && t.isFirstInSeries ? (l(), m("p", Os, [
|
|
358
|
+
w(Cs, {
|
|
359
|
+
text: o(ss),
|
|
360
|
+
position: t.message.position === "left" ? "right" : "left",
|
|
361
|
+
offset: 8
|
|
362
|
+
}, {
|
|
363
|
+
default: Z(() => [
|
|
364
|
+
rs(p(t.message.subText), 1)
|
|
365
|
+
]),
|
|
366
|
+
_: 1
|
|
367
|
+
}, 8, ["text", "position"])
|
|
368
|
+
])) : d("", !0),
|
|
369
|
+
i("div", {
|
|
370
|
+
ref_key: "contentRef",
|
|
371
|
+
ref: ve,
|
|
372
|
+
class: C(["audio-message__content", { "is-first": t.isFirstInSeries, "with-avatar-indent": !t.isFirstInSeries && t.message.avatar }]),
|
|
373
|
+
onMouseenter: s[7] || (s[7] = (a) => o(Q) && o(Le)()),
|
|
374
|
+
onPointerenter: s[8] || (s[8] = //@ts-ignore
|
|
375
|
+
(...a) => o(fe) && o(fe)(...a)),
|
|
376
|
+
onPointerleave: s[9] || (s[9] = //@ts-ignore
|
|
377
|
+
(...a) => o(ye) && o(ye)(...a))
|
|
378
|
+
}, [
|
|
379
|
+
s[15] || (s[15] = i("div", {
|
|
380
|
+
class: "audio-message__bottom-shadow",
|
|
381
|
+
"aria-hidden": "true"
|
|
382
|
+
}, null, -1)),
|
|
383
|
+
t.message.deleted ? (l(), m(q, { key: 0 }, [
|
|
384
|
+
w(bs),
|
|
385
|
+
i("div", Ps, [
|
|
386
|
+
i("div", Ds, [
|
|
387
|
+
t.message.time ? (l(), m("span", Us, p(t.message.time), 1)) : d("", !0),
|
|
388
|
+
w(xe, {
|
|
389
|
+
"base-class": "audio-message",
|
|
390
|
+
"message-class": V(t.message),
|
|
391
|
+
"message-status": t.message.status,
|
|
392
|
+
"status-class": oe.value,
|
|
393
|
+
"status-title": ie.value
|
|
394
|
+
}, null, 8, ["message-class", "message-status", "status-class", "status-title"])
|
|
395
|
+
])
|
|
396
|
+
])
|
|
397
|
+
], 64)) : (l(), m(q, { key: 1 }, [
|
|
398
|
+
t.message.reply ? (l(), k(ys, {
|
|
399
|
+
key: 0,
|
|
400
|
+
style: { "grid-column": "1/3" },
|
|
401
|
+
message: t.message.reply,
|
|
402
|
+
class: C(t.message.position),
|
|
403
|
+
onReply: o($e)
|
|
404
|
+
}, null, 8, ["message", "class", "onReply"])) : d("", !0),
|
|
405
|
+
i("div", $s, [
|
|
406
|
+
i("audio", {
|
|
407
|
+
ref_key: "player",
|
|
408
|
+
ref: n,
|
|
409
|
+
src: x.value,
|
|
410
|
+
type: "audio/webm",
|
|
411
|
+
onLoadedmetadata: Qe,
|
|
412
|
+
onTimeupdate: We,
|
|
413
|
+
onEnded: Je,
|
|
414
|
+
onError: Ke
|
|
415
|
+
}, null, 40, Hs),
|
|
416
|
+
z(i("button", {
|
|
417
|
+
class: "audio-message__play",
|
|
418
|
+
onClick: ue
|
|
419
|
+
}, [...s[11] || (s[11] = [
|
|
420
|
+
i("div", { class: "audio-message__play-icon" }, [
|
|
421
|
+
i("svg", {
|
|
422
|
+
width: "20",
|
|
423
|
+
height: "23",
|
|
424
|
+
viewBox: "0 0 20 23",
|
|
425
|
+
fill: "none",
|
|
426
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
427
|
+
}, [
|
|
428
|
+
i("path", {
|
|
429
|
+
d: "M18.99 12.9934L3.0825 22.2234C1.7325 23.0059 0 22.0584 0 20.4809V2.02087C0 0.44587 1.73 -0.50413 3.0825 0.28087L18.99 9.51087C19.2971 9.68618 19.5524 9.93959 19.7299 10.2454C19.9075 10.5512 20.001 10.8985 20.001 11.2521C20.001 11.6057 19.9075 11.953 19.7299 12.2589C19.5524 12.5647 19.2971 12.8181 18.99 12.9934Z",
|
|
430
|
+
fill: "#5F5F5F"
|
|
431
|
+
})
|
|
432
|
+
])
|
|
433
|
+
], -1)
|
|
434
|
+
])], 512), [
|
|
435
|
+
[Ce, !c.value]
|
|
436
|
+
]),
|
|
437
|
+
z(i("button", {
|
|
438
|
+
class: "audio-message__pause",
|
|
439
|
+
onClick: ue
|
|
440
|
+
}, [...s[12] || (s[12] = [
|
|
441
|
+
i("div", { class: "audio-message__pause-icon" }, [
|
|
442
|
+
i("svg", {
|
|
443
|
+
width: "20",
|
|
444
|
+
height: "23",
|
|
445
|
+
viewBox: "0 0 20 23",
|
|
446
|
+
fill: "none",
|
|
447
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
448
|
+
}, [
|
|
449
|
+
i("path", {
|
|
450
|
+
d: "M3.75 0C4.74456 0 5.69839 0.395088 6.40165 1.09835C7.10491 1.80161 7.5 2.75544 7.5 3.75V18.75C7.5 19.7446 7.10491 20.6984 6.40165 21.4017C5.69839 22.1049 4.74456 22.5 3.75 22.5C2.75544 22.5 1.80161 22.1049 1.09835 21.4017C0.395088 20.6984 2.09588e-08 19.7446 0 18.75V3.75C0 2.75544 0.395088 1.80161 1.09835 1.09835C1.80161 0.395088 2.75544 0 3.75 0ZM16.25 0C17.2446 0 18.1984 0.395088 18.9017 1.09835C19.6049 1.80161 20 2.75544 20 3.75V18.75C20 19.7446 19.6049 20.6984 18.9017 21.4017C18.1984 22.1049 17.2446 22.5 16.25 22.5C15.2554 22.5 14.3016 22.1049 13.5983 21.4017C12.8951 20.6984 12.5 19.7446 12.5 18.75V3.75C12.5 2.75544 12.8951 1.80161 13.5983 1.09835C14.3016 0.395088 15.2554 0 16.25 0Z",
|
|
451
|
+
fill: "#5F5F5F"
|
|
452
|
+
})
|
|
453
|
+
])
|
|
454
|
+
], -1)
|
|
455
|
+
])], 512), [
|
|
456
|
+
[Ce, c.value]
|
|
457
|
+
]),
|
|
458
|
+
i("div", Vs, [
|
|
459
|
+
z(i("input", {
|
|
460
|
+
"onUpdate:modelValue": s[0] || (s[0] = (a) => f.value = a),
|
|
461
|
+
class: "audio-message__progress-bar-container",
|
|
462
|
+
type: "range",
|
|
463
|
+
min: 0,
|
|
464
|
+
max: h.value,
|
|
465
|
+
step: "0.1",
|
|
466
|
+
onMousedown: s[1] || (s[1] = (a) => b.value = !0),
|
|
467
|
+
onMouseup: re,
|
|
468
|
+
onTouchstartPassive: s[2] || (s[2] = (a) => b.value = !0),
|
|
469
|
+
onTouchendPassive: re
|
|
470
|
+
}, null, 40, Bs), [
|
|
471
|
+
[ms, f.value]
|
|
472
|
+
]),
|
|
473
|
+
i("div", js, [
|
|
474
|
+
i("button", {
|
|
475
|
+
type: "button",
|
|
476
|
+
class: "audio-message__speed-btn",
|
|
477
|
+
onClick: Re
|
|
478
|
+
}, p(D.value.text), 1)
|
|
479
|
+
])
|
|
480
|
+
]),
|
|
481
|
+
i("div", Gs, [
|
|
482
|
+
i("p", Ys, p(qe.value), 1),
|
|
483
|
+
i("p", Zs, p(ze.value), 1)
|
|
484
|
+
])
|
|
485
|
+
]),
|
|
486
|
+
t.message.text ? (l(), m("div", qs, [
|
|
487
|
+
i("p", {
|
|
488
|
+
onClick: s[3] || (s[3] = //@ts-ignore
|
|
489
|
+
(...a) => o(ne) && o(ne)(...a)),
|
|
490
|
+
innerHTML: o(Ye)
|
|
491
|
+
}, null, 8, zs)
|
|
492
|
+
])) : d("", !0),
|
|
493
|
+
t.message.linkPreview ? (l(), k(gs, {
|
|
494
|
+
key: 2,
|
|
495
|
+
class: C(["audio-message__link-preview", t.message.position]),
|
|
496
|
+
"link-preview": t.message.linkPreview
|
|
497
|
+
}, null, 8, ["class", "link-preview"])) : d("", !0),
|
|
498
|
+
t.message.embed ? (l(), k(fs, {
|
|
499
|
+
key: 3,
|
|
500
|
+
class: C(t.message.position),
|
|
501
|
+
embed: t.message.embed
|
|
502
|
+
}, null, 8, ["class", "embed"])) : d("", !0),
|
|
503
|
+
i("div", Qs, [
|
|
504
|
+
o(es) ? (l(), k(ps, {
|
|
505
|
+
key: 0,
|
|
506
|
+
ref_key: "reactionsRef",
|
|
507
|
+
ref: ge,
|
|
508
|
+
reactions: t.message.reactions,
|
|
509
|
+
"message-id": t.message.messageId,
|
|
510
|
+
enabled: o(W),
|
|
511
|
+
mode: t.reactionsMode,
|
|
512
|
+
"current-user-id": t.currentUserId,
|
|
513
|
+
"reaction-user-names": t.reactionUserNames,
|
|
514
|
+
onToggleReaction: o(me),
|
|
515
|
+
onAddReaction: o(de),
|
|
516
|
+
onRemoveReaction: o(ce)
|
|
517
|
+
}, null, 8, ["reactions", "message-id", "enabled", "mode", "current-user-id", "reaction-user-names", "onToggleReaction", "onAddReaction", "onRemoveReaction"])) : d("", !0),
|
|
518
|
+
i("div", Ws, [
|
|
519
|
+
E.value || A.value ? (l(), m("div", Js, [
|
|
520
|
+
E.value ? (l(), m("button", {
|
|
521
|
+
key: 0,
|
|
522
|
+
class: C([
|
|
523
|
+
"audio-message__action-button",
|
|
524
|
+
{ "audio-message__action-button--active": y.value === "text" }
|
|
525
|
+
]),
|
|
526
|
+
type: "button",
|
|
527
|
+
onClick: as
|
|
528
|
+
}, " Текст ", 2)) : d("", !0),
|
|
529
|
+
A.value ? (l(), m("button", {
|
|
530
|
+
key: 1,
|
|
531
|
+
class: C([
|
|
532
|
+
"audio-message__action-button",
|
|
533
|
+
{ "audio-message__action-button--active": y.value === "summary" }
|
|
534
|
+
]),
|
|
535
|
+
type: "button",
|
|
536
|
+
onClick: ns
|
|
537
|
+
}, " Резюме ", 2)) : d("", !0)
|
|
538
|
+
])) : d("", !0),
|
|
539
|
+
t.message.views ? (l(), m("div", {
|
|
540
|
+
key: 1,
|
|
541
|
+
class: "audio-message__views",
|
|
542
|
+
onClick: s[4] || (s[4] = //@ts-ignore
|
|
543
|
+
(...a) => o(X) && o(X)(...a))
|
|
544
|
+
}, [
|
|
545
|
+
s[13] || (s[13] = i("span", { class: "pi pi-eye" }, null, -1)),
|
|
546
|
+
i("p", null, p(t.message.views), 1)
|
|
547
|
+
])) : d("", !0),
|
|
548
|
+
i("span", Ks, p(t.message.time), 1),
|
|
549
|
+
w(xe, {
|
|
550
|
+
"base-class": "audio-message",
|
|
551
|
+
"message-class": V(t.message),
|
|
552
|
+
"message-status": t.message.status,
|
|
553
|
+
"status-class": oe.value,
|
|
554
|
+
"status-title": ie.value
|
|
555
|
+
}, null, 8, ["message-class", "message-status", "status-class", "status-title"])
|
|
556
|
+
])
|
|
557
|
+
]),
|
|
558
|
+
w(we, { name: "audio-message-expand" }, {
|
|
559
|
+
default: Z(() => [
|
|
560
|
+
He.value ? (l(), m("div", Xs, [
|
|
561
|
+
i("div", et, [
|
|
562
|
+
y.value === "text" ? (l(), m(q, { key: 0 }, [
|
|
563
|
+
se.value ? (l(), m("p", {
|
|
564
|
+
key: 1,
|
|
565
|
+
class: "audio-message__expand-plain",
|
|
566
|
+
innerHTML: ee.value
|
|
567
|
+
}, null, 8, tt)) : (l(), m("p", st, p(Ve.value), 1))
|
|
568
|
+
], 64)) : (l(), m("p", at, [
|
|
569
|
+
ae.value ? (l(), m("span", {
|
|
570
|
+
key: 1,
|
|
571
|
+
innerHTML: te.value
|
|
572
|
+
}, null, 8, ot)) : (l(), m("span", nt, p(Be.value), 1))
|
|
573
|
+
]))
|
|
574
|
+
]),
|
|
575
|
+
i("div", it, [
|
|
576
|
+
i("button", {
|
|
577
|
+
type: "button",
|
|
578
|
+
class: "audio-message__expand-close",
|
|
579
|
+
onClick: s[5] || (s[5] = (a) => y.value = null)
|
|
580
|
+
}, " Закрыть ")
|
|
581
|
+
])
|
|
582
|
+
])) : d("", !0)
|
|
583
|
+
]),
|
|
584
|
+
_: 1
|
|
585
|
+
}),
|
|
586
|
+
w(hs, {
|
|
587
|
+
status: t.message.status,
|
|
588
|
+
"has-messenger-account": t.message.hasMessengerAccount,
|
|
589
|
+
channel: t.channel,
|
|
590
|
+
onSmsInvite: ts
|
|
591
|
+
}, null, 8, ["status", "has-messenger-account", "channel"]),
|
|
592
|
+
o(Ne) && o(S).length && !t.reactionsEnabled && o(Q) ? (l(), m("button", {
|
|
593
|
+
key: 4,
|
|
594
|
+
class: "audio-message__menu-button",
|
|
595
|
+
onClick: s[6] || (s[6] = //@ts-ignore
|
|
596
|
+
(...a) => o(K) && o(K)(...a))
|
|
597
|
+
}, [...s[14] || (s[14] = [
|
|
598
|
+
i("svg", {
|
|
599
|
+
width: "4",
|
|
600
|
+
height: "17",
|
|
601
|
+
viewBox: "0 0 4 17",
|
|
602
|
+
fill: "none",
|
|
603
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
604
|
+
}, [
|
|
605
|
+
i("path", {
|
|
606
|
+
d: "M3.75 14.375C3.75 14.8723 3.55246 15.3492 3.20083 15.7008C2.84919 16.0525 2.37228 16.25 1.875 16.25C1.37772 16.25 0.900805 16.0525 0.549175 15.7008C0.197544 15.3492 0 14.8723 0 14.375C0 13.8777 0.197544 13.4008 0.549175 13.0492C0.900805 12.6975 1.37772 12.5 1.875 12.5C2.37228 12.5 2.84919 12.6975 3.20083 13.0492C3.55246 13.4008 3.75 13.8777 3.75 14.375ZM3.75 8.125C3.75 8.62228 3.55246 9.09919 3.20083 9.45083C2.84919 9.80246 2.37228 10 1.875 10C1.37772 10 0.900805 9.80246 0.549175 9.45083C0.197544 9.09919 0 8.62228 0 8.125C0 7.62772 0.197544 7.15081 0.549175 6.79917C0.900805 6.44754 1.37772 6.25 1.875 6.25C2.37228 6.25 2.84919 6.44754 3.20083 6.79917C3.55246 7.15081 3.75 7.62772 3.75 8.125ZM3.75 1.875C3.75 2.37228 3.55246 2.84919 3.20083 3.20083C2.84919 3.55246 2.37228 3.75 1.875 3.75C1.37772 3.75 0.900805 3.55246 0.549175 3.20083C0.197544 2.84919 0 2.37228 0 1.875C0 1.37772 0.197544 0.900806 0.549175 0.549175C0.900805 0.197544 1.37772 0 1.875 0C2.37228 0 2.84919 0.197544 3.20083 0.549175C3.55246 0.900806 3.75 1.37772 3.75 1.875Z",
|
|
607
|
+
fill: "#5F5F5F"
|
|
608
|
+
})
|
|
609
|
+
], -1)
|
|
610
|
+
])])) : d("", !0),
|
|
611
|
+
(l(), k(ds, { to: "body" }, [
|
|
612
|
+
w(we, null, {
|
|
613
|
+
default: Z(() => [
|
|
614
|
+
o(Ie) && o(S).length ? (l(), k(vs, {
|
|
615
|
+
key: 0,
|
|
616
|
+
ref_key: "menuRef",
|
|
617
|
+
ref: Ee,
|
|
618
|
+
class: "audio-message__context-menu message-actions-menu",
|
|
619
|
+
style: Y(o(Ae)),
|
|
620
|
+
"data-theme": o(Fe),
|
|
621
|
+
actions: o(S),
|
|
622
|
+
onClick: Ge,
|
|
623
|
+
onMouseenter: o(Pe),
|
|
624
|
+
onMouseleave: o(De)
|
|
625
|
+
}, null, 8, ["style", "data-theme", "actions", "onMouseenter", "onMouseleave"])) : d("", !0)
|
|
626
|
+
]),
|
|
627
|
+
_: 1
|
|
628
|
+
})
|
|
629
|
+
]))
|
|
630
|
+
], 64))
|
|
631
|
+
], 34)
|
|
632
|
+
], 46, Fs));
|
|
315
633
|
}
|
|
316
634
|
});
|
|
317
635
|
export {
|
|
318
|
-
|
|
636
|
+
Dt as default
|
|
319
637
|
};
|