@mobilon-dev/chotto 0.3.97 → 0.3.98
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 +29 -4
- package/dist/components/1_atoms/ButtonContextMenu/ButtonContextMenu.vue2.js +42 -61
- package/dist/components/1_atoms/ContactContextMenu/ContactContextMenu.vue.js +47 -4
- package/dist/components/1_atoms/ContactContextMenu/ContactContextMenu.vue2.js +55 -82
- package/dist/components/1_atoms/ContextMenu/ContextMenu.vue.js +86 -51
- package/dist/components/1_atoms/EmbedPreview/EmbedPreview.vue.js +32 -4
- package/dist/components/1_atoms/EmbedPreview/EmbedPreview.vue2.js +7 -28
- package/dist/components/1_atoms/EmojiGlyph/EmojiGlyph.vue.js +22 -38
- package/dist/components/1_atoms/EmojiGlyph/EmojiGlyph.vue2.js +33 -2
- package/dist/components/1_atoms/LinkPreview/LinkPreview.vue.js +37 -4
- package/dist/components/1_atoms/LinkPreview/LinkPreview.vue2.js +7 -21
- package/dist/components/1_atoms/LoadingIndicator/LoadingIndicator.vue.js +30 -19
- package/dist/components/1_atoms/Tooltip/Tooltip.vue.js +70 -4
- package/dist/components/1_atoms/Tooltip/Tooltip.vue2.js +76 -108
- package/dist/components/1_icons/AvatarIcon.vue.js +8 -8
- package/dist/components/1_icons/CheckIcon.vue.js +26 -13
- package/dist/components/1_icons/CloseButtonIcon.vue.js +16 -10
- package/dist/components/1_icons/CloseIcon.vue.js +16 -10
- package/dist/components/1_icons/ContactCRMIcon.vue.js +16 -10
- package/dist/components/1_icons/MenuIcon.vue.js +16 -10
- package/dist/components/1_icons/MessageStatus/ErrorStatusIcon.vue.js +23 -3
- package/dist/components/1_icons/MessageStatus/ErrorStatusIcon.vue2.js +12 -21
- package/dist/components/1_icons/MessageStatus/PendingStatusIcon.vue.js +36 -4
- package/dist/components/1_icons/MessageStatus/PendingStatusIcon.vue2.js +11 -26
- package/dist/components/1_icons/MessageStatus/ReadStatusIcon.vue.js +23 -3
- package/dist/components/1_icons/MessageStatus/ReadStatusIcon.vue2.js +12 -21
- package/dist/components/1_icons/MessageStatus/ReceivedStatusIcon.vue.js +23 -3
- package/dist/components/1_icons/MessageStatus/ReceivedStatusIcon.vue2.js +11 -20
- package/dist/components/1_icons/MessageStatus/SentStatusIcon.vue.js +33 -4
- package/dist/components/1_icons/MessageStatus/SentStatusIcon.vue2.js +11 -23
- package/dist/components/1_icons/SearchIcon.vue.js +29 -17
- package/dist/components/1_icons/SettingsIcon.vue.js +8 -8
- package/dist/components/1_icons/TelegramIcon.vue.js +32 -20
- package/dist/components/1_icons/WhatsAppIcon.vue.js +32 -20
- package/dist/components/2_blocks/CommunicationPanel/CommunicationPanel.vue.js +546 -396
- package/dist/components/2_blocks/CommunicationPanel/CommunicationPanelAttributeIndicator.vue.js +101 -58
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelCheckIcon.vue.js +14 -8
- 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 +19 -13
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelSMSIcon.vue.js +16 -10
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelSubmenuMaxIcon.vue.js +35 -23
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelSubmenuPhoneIcon.vue.js +32 -20
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelSubmenuSMSIcon.vue.js +17 -11
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelSubmenuTelegramIcon.vue.js +8 -8
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelSubmenuWhatsAppIcon.vue.js +32 -20
- package/dist/components/2_blocks/CommunicationPanel/icons/CommunicationPanelTelegramIcon.vue.js +33 -21
- 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 +74 -4
- package/dist/components/2_blocks/FeedFoundItem/FeedFoundItem.vue2.js +8 -42
- package/dist/components/2_blocks/FeedFoundObjects/FeedFoundObjects.vue.js +62 -4
- package/dist/components/2_blocks/FeedFoundObjects/FeedFoundObjects.vue2.js +15 -36
- package/dist/components/2_blocks/FeedSearch/FeedSearch.vue.js +49 -4
- package/dist/components/2_blocks/FeedSearch/FeedSearch.vue2.js +22 -45
- package/dist/components/2_chatinput_elements/ButtonCommandsSelector/ButtonCommandsSelector.vue.js +36 -4
- package/dist/components/2_chatinput_elements/ButtonCommandsSelector/ButtonCommandsSelector.vue2.js +19 -37
- package/dist/components/2_chatinput_elements/ButtonEmojiPicker/ButtonEmojiPicker.vue.js +61 -4
- package/dist/components/2_chatinput_elements/ButtonEmojiPicker/ButtonEmojiPicker.vue2.js +79 -96
- package/dist/components/2_chatinput_elements/ButtonEmojiPicker/icons/SmilesIcon.vue.js +31 -27
- package/dist/components/2_chatinput_elements/ButtonEmojiPicker/icons/SmilesIcon.vue2.js +13 -2
- package/dist/components/2_chatinput_elements/ButtonTemplateSelector/ButtonTemplateSelector.vue.js +72 -4
- package/dist/components/2_chatinput_elements/ButtonTemplateSelector/ButtonTemplateSelector.vue2.js +47 -83
- package/dist/components/2_chatinput_elements/ButtonTemplateSelector/icons/ChatTemplatesIcon.vue.js +19 -21
- package/dist/components/2_chatinput_elements/ButtonTemplateSelector/icons/ChatTemplatesIcon.vue2.js +13 -2
- package/dist/components/2_chatinput_elements/ButtonWabaTemplateSelector/ButtonWabaTemplateSelector.vue.js +80 -51
- package/dist/components/2_chatinput_elements/FilePreview/FilePreview.vue.js +182 -4
- package/dist/components/2_chatinput_elements/FilePreview/FilePreview.vue2.js +25 -135
- package/dist/components/2_chatinput_elements/FileUploader/FileUploader.vue.js +78 -4
- package/dist/components/2_chatinput_elements/FileUploader/FileUploader.vue2.js +73 -95
- package/dist/components/2_chatinput_elements/FileUploader/icons/FileUploaderIcon.vue.js +15 -17
- package/dist/components/2_chatinput_elements/FileUploader/icons/FileUploaderIcon.vue2.js +13 -2
- package/dist/components/2_chatinput_elements/PlaceholderComponent/PlaceholderComponent.vue.js +39 -33
- package/dist/components/2_chatinput_elements/StickerPicker/StickerPicker.vue.js +220 -4
- package/dist/components/2_chatinput_elements/StickerPicker/StickerPicker.vue2.js +146 -256
- package/dist/components/2_chatinput_elements/StickerPicker/icons/StickerIcon.vue.js +39 -41
- package/dist/components/2_chatinput_elements/StickerPicker/icons/StickerIcon.vue2.js +13 -2
- package/dist/components/2_chatinput_elements/TemplateSelector/TemplateSelector.vue.js +233 -163
- package/dist/components/2_chatinput_elements/TextFormatToolbar/TextFormatToolbar.vue.js +164 -4
- package/dist/components/2_chatinput_elements/TextFormatToolbar/TextFormatToolbar.vue2.js +87 -175
- package/dist/components/2_chatinput_elements/WABAAttachmentSection/WABAAttachmentSection.vue.js +73 -4
- package/dist/components/2_chatinput_elements/WABAAttachmentSection/WABAAttachmentSection.vue2.js +34 -60
- package/dist/components/2_chatinput_elements/WABAQuickReplyButtons/WABAQuickReplyButtons.vue.js +47 -4
- package/dist/components/2_chatinput_elements/WABAQuickReplyButtons/WABAQuickReplyButtons.vue2.js +10 -23
- package/dist/components/2_chatinput_elements/WABASeparatedQuickButtons/WABASeparatedQuickButtons.vue.js +52 -4
- package/dist/components/2_chatinput_elements/WABASeparatedQuickButtons/WABASeparatedQuickButtons.vue2.js +8 -26
- package/dist/components/2_chatinput_elements/WABATemplateSelector/WABATemplateSelector.vue.js +299 -220
- package/dist/components/2_chatlist_elements/ChatFilter/ChatFilter.vue.js +39 -33
- package/dist/components/2_chatlist_elements/ChatItem/ChatItem.vue.js +306 -4
- package/dist/components/2_chatlist_elements/ChatItem/ChatItem.vue2.js +134 -311
- package/dist/components/2_chatlist_elements/ChatItem/icons/AudioIcon.vue.js +18 -12
- package/dist/components/2_chatlist_elements/ChatItem/icons/FileIcon.vue.js +23 -11
- package/dist/components/2_chatlist_elements/ChatItem/icons/ImageIcon.vue.js +7 -7
- package/dist/components/2_chatlist_elements/ChatItem/icons/MissedCallIcon.vue.js +34 -22
- package/dist/components/2_chatlist_elements/ChatItem/icons/StickerIcon.vue.js +15 -9
- package/dist/components/2_chatlist_elements/ChatItem/icons/VideoIcon.vue.js +26 -14
- package/dist/components/2_chatlist_elements/ChatItem/icons/VoiceIcon.vue.js +7 -7
- package/dist/components/2_chatlist_elements/ChatTabs/ChatTabs.vue.js +52 -24
- package/dist/components/2_elements/AudioRecorder/AudioRecorder.vue.js +84 -4
- package/dist/components/2_elements/AudioRecorder/AudioRecorder.vue2.js +35 -67
- package/dist/components/2_elements/ChannelSelector/ChannelSelector.vue.js +72 -38
- package/dist/components/2_elements/ChatInfo/ChatInfo.vue.js +76 -57
- package/dist/components/2_elements/ChatPanel/ChatPanel.vue.js +41 -29
- package/dist/components/2_elements/ContactInfo/ContactInfo.vue.js +176 -115
- package/dist/components/2_elements/ThemeMode/ThemeMode.vue.js +48 -27
- package/dist/components/2_elements/UserProfile/UserProfile.vue.js +58 -28
- package/dist/components/2_elements/VideoRecorder/VideoRecorder.vue.js +54 -4
- package/dist/components/2_elements/VideoRecorder/VideoRecorder.vue2.js +19 -39
- package/dist/components/2_feed_elements/AudioMessage/AudioMessage.vue.js +458 -4
- package/dist/components/2_feed_elements/AudioMessage/AudioMessage.vue2.js +160 -471
- package/dist/components/2_feed_elements/BaseEditMessage/BaseEditMessage.vue.js +19 -4
- package/dist/components/2_feed_elements/BaseEditMessage/BaseEditMessage.vue2.js +12 -22
- package/dist/components/2_feed_elements/BaseReplyMessage/BaseReplyMessage.vue.js +26 -4
- package/dist/components/2_feed_elements/BaseReplyMessage/BaseReplyMessage.vue2.js +26 -39
- package/dist/components/2_feed_elements/CallMessage/CallMessage.vue.js +482 -4
- package/dist/components/2_feed_elements/CallMessage/CallMessage.vue2.js +148 -448
- package/dist/components/2_feed_elements/CallMessage/icons/IncomingCallIcon.vue.js +17 -19
- package/dist/components/2_feed_elements/CallMessage/icons/IncomingCallIcon.vue2.js +13 -2
- package/dist/components/2_feed_elements/CallMessage/icons/OutgoingCallIcon.vue.js +17 -19
- package/dist/components/2_feed_elements/CallMessage/icons/OutgoingCallIcon.vue2.js +13 -2
- package/dist/components/2_feed_elements/DateMessage/DateMessage.vue.js +17 -4
- package/dist/components/2_feed_elements/DateMessage/DateMessage.vue2.js +7 -7
- package/dist/components/2_feed_elements/DateMessageSticky/DateMessageSticky.vue.js +16 -3
- package/dist/components/2_feed_elements/DateMessageSticky/DateMessageSticky.vue2.js +7 -7
- package/dist/components/2_feed_elements/DeletedMessageContent/DeletedMessageContent.vue.js +67 -4
- package/dist/components/2_feed_elements/DeletedMessageContent/DeletedMessageContent.vue2.js +11 -43
- package/dist/components/2_feed_elements/DeletedMessageContent/icons/DeletedMessageIcon.vue.js +16 -10
- package/dist/components/2_feed_elements/DelimiterMessage/DelimiterMessage.vue.js +60 -4
- package/dist/components/2_feed_elements/DelimiterMessage/DelimiterMessage.vue2.js +36 -53
- package/dist/components/2_feed_elements/EditTextMessage/EditTextMessage.vue.js +22 -4
- package/dist/components/2_feed_elements/EditTextMessage/EditTextMessage.vue2.js +8 -15
- package/dist/components/2_feed_elements/FeedKeyboard/FeedKeyboard.vue.js +43 -4
- package/dist/components/2_feed_elements/FeedKeyboard/FeedKeyboard.vue2.js +10 -25
- package/dist/components/2_feed_elements/FileMessage/FileMessage.vue.js +250 -4
- package/dist/components/2_feed_elements/FileMessage/FileMessage.vue2.js +67 -233
- package/dist/components/2_feed_elements/ImageMessage/ImageMessage.vue.js +315 -4
- package/dist/components/2_feed_elements/ImageMessage/ImageMessage.vue2.js +98 -319
- package/dist/components/2_feed_elements/MessageKeyboard/MessageKeyboard.vue.js +39 -4
- package/dist/components/2_feed_elements/MessageKeyboard/MessageKeyboard.vue2.js +12 -22
- package/dist/components/2_feed_elements/MessageReactions/MessageReactions.vue.js +155 -4
- package/dist/components/2_feed_elements/MessageReactions/MessageReactions.vue2.js +110 -212
- package/dist/components/2_feed_elements/MessageReactions/icons/DeleteIcon.vue.js +32 -20
- package/dist/components/2_feed_elements/MessageReactions/icons/EditIcon.vue.js +32 -20
- package/dist/components/2_feed_elements/MessageReactions/icons/ExpandReactionsIcon.vue.js +17 -11
- package/dist/components/2_feed_elements/MessageReactions/icons/MessageActionsIcon.vue.js +16 -10
- package/dist/components/2_feed_elements/MessageReactions/icons/ReplyIcon.vue.js +17 -11
- package/dist/components/2_feed_elements/MessageSmsInvite/MessageSmsInvite.vue.js +22 -4
- package/dist/components/2_feed_elements/MessageSmsInvite/MessageSmsInvite.vue2.js +17 -23
- package/dist/components/2_feed_elements/MessageStatusIndicator/MessageStatusIndicator.vue.js +28 -4
- package/dist/components/2_feed_elements/MessageStatusIndicator/MessageStatusIndicator.vue2.js +27 -29
- package/dist/components/2_feed_elements/MissedCallMessage/MissedCallMessage.vue.js +142 -4
- package/dist/components/2_feed_elements/MissedCallMessage/MissedCallMessage.vue2.js +33 -121
- package/dist/components/2_feed_elements/MissedCallMessage/icons/MissedCallIcon.vue.js +34 -22
- package/dist/components/2_feed_elements/ReplyAudioMessage/ReplyAudioMessage.vue.js +55 -4
- package/dist/components/2_feed_elements/ReplyAudioMessage/ReplyAudioMessage.vue2.js +8 -30
- package/dist/components/2_feed_elements/ReplyCallMessage/ReplyCallMessage.vue.js +47 -4
- package/dist/components/2_feed_elements/ReplyCallMessage/ReplyCallMessage.vue2.js +9 -25
- package/dist/components/2_feed_elements/ReplyFileMessage/ReplyFileMessage.vue.js +56 -4
- package/dist/components/2_feed_elements/ReplyFileMessage/ReplyFileMessage.vue2.js +8 -37
- package/dist/components/2_feed_elements/ReplyImageMessage/ReplyImageMessage.vue.js +72 -4
- package/dist/components/2_feed_elements/ReplyImageMessage/ReplyImageMessage.vue2.js +10 -59
- package/dist/components/2_feed_elements/ReplyStickerMessage/ReplyStickerMessage.vue.js +142 -4
- package/dist/components/2_feed_elements/ReplyStickerMessage/ReplyStickerMessage.vue2.js +36 -120
- package/dist/components/2_feed_elements/ReplyTextMessage/ReplyTextMessage.vue.js +49 -4
- package/dist/components/2_feed_elements/ReplyTextMessage/ReplyTextMessage.vue2.js +15 -53
- package/dist/components/2_feed_elements/ReplyVideoMessage/ReplyVideoMessage.vue.js +75 -4
- package/dist/components/2_feed_elements/ReplyVideoMessage/ReplyVideoMessage.vue2.js +10 -63
- package/dist/components/2_feed_elements/SplashScreen/SplashScreen.vue.js +18 -4
- package/dist/components/2_feed_elements/SplashScreen/SplashScreen.vue2.js +9 -17
- package/dist/components/2_feed_elements/StickerMessage/StickerMessage.vue.js +346 -4
- package/dist/components/2_feed_elements/StickerMessage/StickerMessage.vue2.js +73 -307
- package/dist/components/2_feed_elements/SystemMessage/SystemMessage.vue.js +17 -4
- package/dist/components/2_feed_elements/SystemMessage/SystemMessage.vue2.js +7 -7
- package/dist/components/2_feed_elements/TextMessage/TextMessage.vue.js +307 -4
- package/dist/components/2_feed_elements/TextMessage/TextMessage.vue2.js +65 -269
- package/dist/components/2_feed_elements/TypingMessage/TypingMessage.vue.js +37 -4
- package/dist/components/2_feed_elements/TypingMessage/TypingMessage.vue2.js +7 -21
- package/dist/components/2_feed_elements/VideoMessage/VideoMessage.vue.js +307 -4
- package/dist/components/2_feed_elements/VideoMessage/VideoMessage.vue2.js +76 -298
- package/dist/components/2_modals/ConfirmDeleteMessage/ConfirmDeleteMessage.vue.js +64 -4
- package/dist/components/2_modals/ConfirmDeleteMessage/ConfirmDeleteMessage.vue3.js +10 -45
- package/dist/components/2_modals/CreateChat/CreateChat.vue.js +35 -18
- package/dist/components/2_modals/CreateChat2/CreateChat2.vue.js +140 -92
- package/dist/components/2_modals/CreateDialog/CreateDialog.vue.js +96 -49
- package/dist/components/2_modals/Modal/Modal.vue.js +59 -50
- package/dist/components/2_modals/ModalFullscreen/ModalFullscreen.vue.js +51 -38
- package/dist/components/2_modals/ModalNoFooter/ModalNoFooter.vue.js +39 -30
- package/dist/components/2_modals/ModalVideoRecorder/ModalVideoRecorder.vue.js +155 -4
- package/dist/components/2_modals/ModalVideoRecorder/ModalVideoRecorder.vue2.js +49 -121
- package/dist/components/2_modals/SelectUser/SelectUser.vue.js +60 -43
- package/dist/components/2_modals/SelectUser2/SelectUser2.vue.js +41 -24
- package/dist/components/3_compounds/ChatInput/ChatInput.vue.js +85 -4
- package/dist/components/3_compounds/ChatInput/ChatInput.vue2.js +149 -210
- package/dist/components/3_compounds/ChatInput/icons/SendIcon.vue.js +25 -21
- package/dist/components/3_compounds/ChatInput/icons/SendIcon.vue2.js +13 -2
- package/dist/components/3_compounds/ChatList/ChatList.vue.js +253 -163
- package/dist/components/3_compounds/ChatList/ChatListHeader.vue.js +50 -32
- package/dist/components/3_compounds/ChatList/icons/LogoIcon.vue.js +6 -6
- package/dist/components/3_compounds/Feed/Feed.vue.js +172 -4
- package/dist/components/3_compounds/Feed/Feed.vue2.js +126 -257
- package/dist/components/3_compounds/SideBar/SideBar.vue.js +279 -202
- package/dist/components/4_layouts/AdaptiveExtendedLayout/AdaptiveExtendedLayout.vue.js +43 -36
- package/dist/components/4_layouts/BaseLayout/BaseLayout.vue.js +5 -5
- package/dist/components/4_layouts/ChatWrapper/ChatWrapper.vue.js +32 -4
- package/dist/components/4_layouts/ChatWrapper/ChatWrapper.vue2.js +7 -29
- 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 +31 -18
- package/dist/components/5_containers/FloatContainer/FloatContainer.vue.js +85 -56
- package/package.json +1 -1
|
@@ -1,19 +1,19 @@
|
|
|
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 { useMessageMenuActions as
|
|
13
|
-
import { useMessageLinks as
|
|
14
|
-
import { useChannelAccentColor as
|
|
15
|
-
import { useSubtextTooltip as
|
|
16
|
-
import { useStartReply as
|
|
1
|
+
import { defineComponent as je, ref as l, computed as o, inject as Fe, watch as D, nextTick as Be } from "vue";
|
|
2
|
+
import Ge from "../../1_atoms/ContextMenu/ContextMenu.vue.js";
|
|
3
|
+
import Ye from "../../1_atoms/LinkPreview/LinkPreview.vue.js";
|
|
4
|
+
import He from "../../1_atoms/EmbedPreview/EmbedPreview.vue.js";
|
|
5
|
+
import qe from "../BaseReplyMessage/BaseReplyMessage.vue.js";
|
|
6
|
+
import Ve from "../MessageReactions/MessageReactions.vue.js";
|
|
7
|
+
import ze from "../MessageStatusIndicator/MessageStatusIndicator.vue.js";
|
|
8
|
+
import We from "../MessageSmsInvite/MessageSmsInvite.vue.js";
|
|
9
|
+
import Je from "../DeletedMessageContent/DeletedMessageContent.vue.js";
|
|
10
|
+
import Ke from "../../1_atoms/Tooltip/Tooltip.vue.js";
|
|
11
|
+
import { useMessageActions as Qe } from "../../../hooks/messages/useMessageActions.js";
|
|
12
|
+
import { useMessageMenuActions as Xe } from "../../../hooks/messages/useMessageMenuActions.js";
|
|
13
|
+
import { useMessageLinks as Ze } from "../../../hooks/messages/useMessageLinks.js";
|
|
14
|
+
import { useChannelAccentColor as et } from "../../../hooks/messages/useChannelAccentColor.js";
|
|
15
|
+
import { useSubtextTooltip as tt } from "../../../hooks/messages/useSubtextTooltip.js";
|
|
16
|
+
import { useStartReply as at } from "../../../hooks/messages/useStartReply.js";
|
|
17
17
|
import "../../../hooks/useMessageDraft.js";
|
|
18
18
|
import "../../../hooks/useSearchModel.js";
|
|
19
19
|
import "../../../hooks/useTheme.js";
|
|
@@ -22,36 +22,12 @@ import "../../../hooks/useEmojiNative.js";
|
|
|
22
22
|
/* empty css */
|
|
23
23
|
import "../../../locale/useLocale.js";
|
|
24
24
|
/* empty css */
|
|
25
|
-
import { buildReplyPayload as
|
|
26
|
-
import { getStatus as
|
|
27
|
-
import { getMessageClass as
|
|
28
|
-
import { createReactionHandlers as
|
|
25
|
+
import { buildReplyPayload as W } from "../../../hooks/messages/buildReplyPayload.js";
|
|
26
|
+
import { getStatus as nt, getStatusTitle as st } from "../../../functions/getStatusMessage.js";
|
|
27
|
+
import { getMessageClass as ot } from "../../../functions/getMessageClass.js";
|
|
28
|
+
import { createReactionHandlers as rt } from "../../../functions/createReactionHandlers.js";
|
|
29
29
|
import "../../../functions/parseMarkdown.js";
|
|
30
|
-
const
|
|
31
|
-
key: 1,
|
|
32
|
-
class: "audio-message__subtext"
|
|
33
|
-
}, Tt = { class: "audio-message__footer" }, St = { class: "audio-message__info-container" }, Nt = {
|
|
34
|
-
key: 0,
|
|
35
|
-
class: "audio-message__time"
|
|
36
|
-
}, _t = { class: "audio-message__audio-container" }, It = ["src"], Et = { class: "audio-message__progress-wrapper" }, At = ["max"], Ot = { class: "audio-message__speed-btn-container" }, Ft = { class: "audio-message__player-controls" }, Lt = { class: "audio-message__current-time" }, Dt = { class: "audio-message__duration" }, Pt = {
|
|
37
|
-
key: 1,
|
|
38
|
-
class: "audio-message__text-container"
|
|
39
|
-
}, Ut = ["innerHTML"], Vt = { class: "audio-message__footer" }, $t = { class: "audio-message__info-container" }, Bt = {
|
|
40
|
-
key: 0,
|
|
41
|
-
class: "audio-message__actions"
|
|
42
|
-
}, Ht = { class: "audio-message__time" }, jt = {
|
|
43
|
-
key: 0,
|
|
44
|
-
class: "audio-message__expand-panel"
|
|
45
|
-
}, Gt = { class: "audio-message__expand-inner" }, Yt = {
|
|
46
|
-
key: 0,
|
|
47
|
-
class: "audio-message__expand-placeholder"
|
|
48
|
-
}, Zt = ["innerHTML"], qt = {
|
|
49
|
-
key: 1,
|
|
50
|
-
class: "audio-message__expand-plain"
|
|
51
|
-
}, zt = {
|
|
52
|
-
key: 0,
|
|
53
|
-
class: "audio-message__expand-placeholder"
|
|
54
|
-
}, Wt = ["innerHTML"], Jt = { class: "audio-message__expand-close-wrap" }, Kt = "RECOGNITION_READY", Qt = "SUMMARY_READY", _s = /* @__PURE__ */ Xe({
|
|
30
|
+
const J = "RECOGNITION_READY", K = "SUMMARY_READY", jt = /* @__PURE__ */ je({
|
|
55
31
|
__name: "AudioMessage",
|
|
56
32
|
props: {
|
|
57
33
|
message: {
|
|
@@ -73,7 +49,7 @@ const Mt = ["messageId"], kt = ["src"], Rt = {
|
|
|
73
49
|
reactionsMode: {
|
|
74
50
|
type: String,
|
|
75
51
|
default: "single",
|
|
76
|
-
validator: (
|
|
52
|
+
validator: (N) => ["single", "multi"].includes(N)
|
|
77
53
|
},
|
|
78
54
|
currentUserId: {
|
|
79
55
|
type: [String, Number],
|
|
@@ -95,8 +71,9 @@ const Mt = ["messageId"], kt = ["src"], Rt = {
|
|
|
95
71
|
}
|
|
96
72
|
},
|
|
97
73
|
emits: ["action", "reply", "sms-invite"],
|
|
98
|
-
setup(
|
|
99
|
-
|
|
74
|
+
setup(N, { expose: Q, emit: X }) {
|
|
75
|
+
Q();
|
|
76
|
+
const n = N, R = l([
|
|
100
77
|
{
|
|
101
78
|
text: "1.0x",
|
|
102
79
|
speed: 1
|
|
@@ -113,92 +90,92 @@ const Mt = ["messageId"], kt = ["src"], Rt = {
|
|
|
113
90
|
text: "2.0x",
|
|
114
91
|
speed: 2
|
|
115
92
|
}
|
|
116
|
-
]),
|
|
117
|
-
|
|
118
|
-
},
|
|
119
|
-
var
|
|
120
|
-
const e =
|
|
121
|
-
return e.url || (typeof ((
|
|
122
|
-
}),
|
|
93
|
+
]), S = l(0), I = o(() => R.value[S.value] ?? R.value[0]), Z = () => {
|
|
94
|
+
S.value = (S.value + 1) % R.value.length, t.value && (t.value.playbackRate = I.value.speed);
|
|
95
|
+
}, d = X, { menuActions: ee } = Xe(() => n.message), P = Fe("chatAppId"), { startReply: U } = at(P || ""), t = l(null), p = l(void 0), u = l(!1), c = l(0), i = l(0), v = l(!1), x = o(() => {
|
|
96
|
+
var a, s;
|
|
97
|
+
const e = n.message;
|
|
98
|
+
return e.url || (typeof ((a = e.meta) == null ? void 0 : a.url) == "string" ? e.meta.url : void 0) || ((s = e.data) == null ? void 0 : s.url);
|
|
99
|
+
}), M = (e) => {
|
|
123
100
|
if (e == null) return;
|
|
124
101
|
if (typeof e == "number")
|
|
125
102
|
return !Number.isFinite(e) || e < 0 ? void 0 : Math.floor(e);
|
|
126
|
-
const
|
|
127
|
-
if (!
|
|
128
|
-
if (/^\d+$/.test(
|
|
129
|
-
const
|
|
130
|
-
return Number.isFinite(
|
|
103
|
+
const a = String(e).trim();
|
|
104
|
+
if (!a) return;
|
|
105
|
+
if (/^\d+$/.test(a)) {
|
|
106
|
+
const r = Number(a);
|
|
107
|
+
return Number.isFinite(r) && r >= 0 ? Math.floor(r) : void 0;
|
|
131
108
|
}
|
|
132
|
-
const
|
|
133
|
-
if (
|
|
134
|
-
const
|
|
135
|
-
return
|
|
109
|
+
const s = a.match(/^(\d+):([0-5]\d):([0-5]\d)$/);
|
|
110
|
+
if (s) {
|
|
111
|
+
const r = Number(s[1]), C = Number(s[2]), k = Number(s[3]);
|
|
112
|
+
return r * 3600 + C * 60 + k;
|
|
136
113
|
}
|
|
137
|
-
const
|
|
138
|
-
if (
|
|
139
|
-
},
|
|
140
|
-
|
|
114
|
+
const f = a.match(/^(\d+):([0-5]\d)$/);
|
|
115
|
+
if (f) return Number(f[1]) * 60 + Number(f[2]);
|
|
116
|
+
}, A = () => {
|
|
117
|
+
u.value = !1, i.value = 0, c.value = M(n.message.duration) ?? 0, v.value = !1;
|
|
141
118
|
};
|
|
142
|
-
|
|
143
|
-
() =>
|
|
144
|
-
(e,
|
|
145
|
-
e !==
|
|
119
|
+
A(), D(
|
|
120
|
+
() => x.value,
|
|
121
|
+
(e, a) => {
|
|
122
|
+
e !== a && (A(), p.value = void 0, t.value && (t.value.pause(), t.value.currentTime = 0, t.value.removeAttribute("src"), t.value.load()));
|
|
146
123
|
}
|
|
147
|
-
),
|
|
148
|
-
() =>
|
|
124
|
+
), D(
|
|
125
|
+
() => n.message.duration,
|
|
149
126
|
() => {
|
|
150
|
-
|
|
127
|
+
p.value === void 0 && (c.value = M(n.message.duration) ?? 0);
|
|
151
128
|
}
|
|
152
129
|
);
|
|
153
130
|
const {
|
|
154
|
-
isOpenMenu:
|
|
155
|
-
buttonMenuVisible:
|
|
156
|
-
menuAnchorRef:
|
|
157
|
-
menuRef:
|
|
158
|
-
menuStyle:
|
|
159
|
-
menuTheme:
|
|
160
|
-
showMenu:
|
|
161
|
-
hideMenu:
|
|
162
|
-
openMenu:
|
|
163
|
-
toggleMenu:
|
|
164
|
-
onMenuMouseEnter:
|
|
165
|
-
onMenuMouseLeave:
|
|
166
|
-
clickAction:
|
|
167
|
-
viewsAction:
|
|
168
|
-
handleClickReplied:
|
|
169
|
-
} =
|
|
170
|
-
onReply: () =>
|
|
171
|
-
}),
|
|
172
|
-
var
|
|
173
|
-
const e =
|
|
174
|
-
return !
|
|
175
|
-
}),
|
|
176
|
-
var
|
|
177
|
-
const e =
|
|
178
|
-
return !
|
|
179
|
-
}),
|
|
180
|
-
var
|
|
181
|
-
const e = (
|
|
131
|
+
isOpenMenu: te,
|
|
132
|
+
buttonMenuVisible: ae,
|
|
133
|
+
menuAnchorRef: ne,
|
|
134
|
+
menuRef: se,
|
|
135
|
+
menuStyle: oe,
|
|
136
|
+
menuTheme: re,
|
|
137
|
+
showMenu: ue,
|
|
138
|
+
hideMenu: L,
|
|
139
|
+
openMenu: ie,
|
|
140
|
+
toggleMenu: le,
|
|
141
|
+
onMenuMouseEnter: ce,
|
|
142
|
+
onMenuMouseLeave: me,
|
|
143
|
+
clickAction: $,
|
|
144
|
+
viewsAction: de,
|
|
145
|
+
handleClickReplied: pe
|
|
146
|
+
} = Qe(n.message, d, {
|
|
147
|
+
onReply: () => U(W(n.message, "message.audio"))
|
|
148
|
+
}), m = l(null), g = l({ text: !1, summary: !1 }), y = o(() => {
|
|
149
|
+
var s;
|
|
150
|
+
const e = n.message, a = e.transcript ?? ((s = e.meta) == null ? void 0 : s.transcript);
|
|
151
|
+
return !a || typeof a != "object" ? null : a;
|
|
152
|
+
}), h = o(() => {
|
|
153
|
+
var s;
|
|
154
|
+
const e = n.message, a = e.summary ?? ((s = e.meta) == null ? void 0 : s.summary);
|
|
155
|
+
return !a || typeof a != "object" ? null : a;
|
|
156
|
+
}), j = o(() => {
|
|
157
|
+
var a;
|
|
158
|
+
const e = (a = y.value) == null ? void 0 : a.html;
|
|
182
159
|
return typeof e != "string" ? "" : e.trim();
|
|
183
|
-
}),
|
|
160
|
+
}), F = o(() => {
|
|
184
161
|
var e;
|
|
185
|
-
return ((e =
|
|
186
|
-
}),
|
|
187
|
-
var
|
|
188
|
-
const e = (
|
|
162
|
+
return ((e = y.value) == null ? void 0 : e.status) === J && j.value.length > 0;
|
|
163
|
+
}), B = o(() => {
|
|
164
|
+
var a;
|
|
165
|
+
const e = (a = h.value) == null ? void 0 : a.html;
|
|
189
166
|
return typeof e != "string" ? "" : e.trim();
|
|
190
|
-
}),
|
|
167
|
+
}), G = o(() => {
|
|
191
168
|
var e;
|
|
192
|
-
return ((e =
|
|
193
|
-
}), E =
|
|
169
|
+
return ((e = h.value) == null ? void 0 : e.status) === K && B.value.length > 0;
|
|
170
|
+
}), E = o(() => {
|
|
194
171
|
var e;
|
|
195
|
-
return !!((e =
|
|
196
|
-
}),
|
|
172
|
+
return !!((e = y.value) != null && e.status);
|
|
173
|
+
}), O = o(() => {
|
|
197
174
|
var e;
|
|
198
|
-
return !!((e =
|
|
199
|
-
}),
|
|
175
|
+
return !!((e = h.value) != null && e.status);
|
|
176
|
+
}), ve = o(() => m.value === "text" ? E.value : m.value === "summary" ? O.value : !1), fe = o(() => {
|
|
200
177
|
var e;
|
|
201
|
-
switch ((e =
|
|
178
|
+
switch ((e = y.value) == null ? void 0 : e.status) {
|
|
202
179
|
case "RECOGNITION_PLANNED":
|
|
203
180
|
return "Распознаем сообщение, пожалуйста подождите...";
|
|
204
181
|
case "RECOGNITION_ERROR":
|
|
@@ -208,9 +185,9 @@ const Mt = ["messageId"], kt = ["src"], Rt = {
|
|
|
208
185
|
default:
|
|
209
186
|
return "Текст сообщения недоступен";
|
|
210
187
|
}
|
|
211
|
-
}),
|
|
188
|
+
}), ge = o(() => {
|
|
212
189
|
var e;
|
|
213
|
-
switch ((e =
|
|
190
|
+
switch ((e = h.value) == null ? void 0 : e.status) {
|
|
214
191
|
case "SUMMARY_PLANNED":
|
|
215
192
|
return "Формируем резюме, пожалуйста подождите...";
|
|
216
193
|
case "SUMMARY_ERROR":
|
|
@@ -220,19 +197,19 @@ const Mt = ["messageId"], kt = ["src"], Rt = {
|
|
|
220
197
|
default:
|
|
221
198
|
return "Резюме недоступно";
|
|
222
199
|
}
|
|
223
|
-
}),
|
|
224
|
-
var
|
|
225
|
-
const e =
|
|
200
|
+
}), Y = async () => {
|
|
201
|
+
var a, s, f;
|
|
202
|
+
const e = x.value;
|
|
226
203
|
if (e)
|
|
227
204
|
try {
|
|
228
|
-
const
|
|
205
|
+
const r = await fetch(e, {
|
|
229
206
|
headers: {
|
|
230
207
|
Accept: "audio/*"
|
|
231
208
|
}
|
|
232
209
|
});
|
|
233
|
-
if (!
|
|
234
|
-
throw new Error(`HTTP error! status: ${
|
|
235
|
-
const
|
|
210
|
+
if (!r.ok)
|
|
211
|
+
throw new Error(`HTTP error! status: ${r.status}`);
|
|
212
|
+
const C = r.headers.get("content-type") || "", k = await r.blob(), T = ((s = (a = e.split(".").pop()) == null ? void 0 : a.split("?")[0]) == null ? void 0 : s.toLowerCase()) || "", Le = {
|
|
236
213
|
"audio/mpeg": "mp3",
|
|
237
214
|
"audio/mp3": "mp3",
|
|
238
215
|
"audio/wav": "wav",
|
|
@@ -243,368 +220,80 @@ const Mt = ["messageId"], kt = ["src"], Rt = {
|
|
|
243
220
|
"audio/flac": "flac",
|
|
244
221
|
"audio/m4a": "m4a",
|
|
245
222
|
"audio/x-m4a": "m4a",
|
|
246
|
-
"application/octet-stream":
|
|
247
|
-
},
|
|
248
|
-
|
|
249
|
-
} catch (
|
|
250
|
-
console.error("Ошибка при скачивании аудио:",
|
|
223
|
+
"application/octet-stream": T || "mp3"
|
|
224
|
+
}, q = T && ["mp3", "wav", "ogg", "webm", "aac", "flac", "m4a"].includes(T) ? T : Le[C] || "mp3", V = e.split("/"), w = decodeURIComponent(((f = V[V.length - 1]) == null ? void 0 : f.split("?")[0]) || ""), $e = w ? w.includes(".") ? w : `${w}.${q}` : `audio-${n.message.messageId}.${q}`, z = window.URL.createObjectURL(k), b = document.createElement("a");
|
|
225
|
+
b.href = z, b.download = $e, document.body.appendChild(b), b.click(), document.body.removeChild(b), window.URL.revokeObjectURL(z);
|
|
226
|
+
} catch (r) {
|
|
227
|
+
console.error("Ошибка при скачивании аудио:", r), e && window.open(e, "_blank");
|
|
251
228
|
}
|
|
252
|
-
},
|
|
253
|
-
e.action === "download" ? (
|
|
254
|
-
}, { linkedHtml:
|
|
255
|
-
|
|
229
|
+
}, ye = (e) => {
|
|
230
|
+
e.action === "download" ? (Y(), L()) : $(e);
|
|
231
|
+
}, { linkedHtml: he, inNewWindow: be } = Ze(() => n.message.text), Re = o(() => nt(n.message.status)), Se = o(() => st(n.message.status, n.message.statusMsg)), { bubbleStyle: xe } = et(
|
|
232
|
+
o(() => n.message),
|
|
256
233
|
{ cssVariable: "--chotto-audiomessage-right-background-color", position: "right" }
|
|
257
|
-
),
|
|
258
|
-
const e =
|
|
259
|
-
if (!(!
|
|
260
|
-
if (
|
|
261
|
-
|
|
234
|
+
), Me = async () => {
|
|
235
|
+
const e = x.value;
|
|
236
|
+
if (!(!t.value || !e))
|
|
237
|
+
if (u.value)
|
|
238
|
+
t.value.pause(), u.value = !1;
|
|
262
239
|
else
|
|
263
240
|
try {
|
|
264
|
-
|
|
265
|
-
} catch (
|
|
266
|
-
console.error("Не удалось воспроизвести аудио",
|
|
241
|
+
p.value || (p.value = e, await Be(), t.value.load()), await t.value.play(), u.value = !0;
|
|
242
|
+
} catch (a) {
|
|
243
|
+
console.error("Не удалось воспроизвести аудио", a), u.value = !1;
|
|
267
244
|
}
|
|
268
|
-
},
|
|
269
|
-
const
|
|
270
|
-
return `${
|
|
271
|
-
},
|
|
272
|
-
|
|
273
|
-
() =>
|
|
245
|
+
}, _ = (e) => {
|
|
246
|
+
const a = Math.floor(e / 60), s = Math.floor(e % 60);
|
|
247
|
+
return `${a.toString().padStart(2, "0")}:${s.toString().padStart(2, "0")}`;
|
|
248
|
+
}, Te = o(() => _(i.value));
|
|
249
|
+
D(
|
|
250
|
+
() => i.value,
|
|
274
251
|
() => {
|
|
275
|
-
|
|
252
|
+
t.value && v.value && (t.value.duration != 1 / 0 && !Number.isNaN(t.value.duration) && (t.value.currentTime = i.value), Math.abs(i.value - c.value) < 0.1 && (u.value = !1));
|
|
276
253
|
}
|
|
277
254
|
);
|
|
278
|
-
const
|
|
279
|
-
|
|
280
|
-
},
|
|
281
|
-
if (!
|
|
282
|
-
const e =
|
|
283
|
-
if (
|
|
255
|
+
const we = () => {
|
|
256
|
+
t.value && v.value && t.value.duration != 1 / 0 && !Number.isNaN(t.value.duration) && (t.value.currentTime = i.value), v.value = !1;
|
|
257
|
+
}, Ne = o(() => _(c.value)), Ie = () => {
|
|
258
|
+
if (!t.value) return;
|
|
259
|
+
const e = t.value;
|
|
260
|
+
if (i.value = e.currentTime || 0, e.duration === 1 / 0 || Number.isNaN(e.duration)) {
|
|
284
261
|
e.currentTime = 1e101;
|
|
285
|
-
const
|
|
286
|
-
|
|
262
|
+
const a = () => {
|
|
263
|
+
t.value && (c.value = t.value.duration || 0, i.value = 0, t.value.currentTime = 0);
|
|
287
264
|
};
|
|
288
|
-
e.addEventListener("timeupdate",
|
|
265
|
+
e.addEventListener("timeupdate", a, { once: !0 });
|
|
289
266
|
} else
|
|
290
|
-
|
|
291
|
-
e.playbackRate =
|
|
292
|
-
},
|
|
293
|
-
|
|
294
|
-
},
|
|
295
|
-
|
|
296
|
-
},
|
|
297
|
-
console.error("Не удалось загрузить аудио"),
|
|
267
|
+
c.value = e.duration || 0;
|
|
268
|
+
e.playbackRate = I.value.speed;
|
|
269
|
+
}, Ae = () => {
|
|
270
|
+
t.value && (v.value || (i.value = t.value.currentTime), t.value.ended && u.value && (u.value = !1));
|
|
271
|
+
}, Ee = () => {
|
|
272
|
+
u.value = !1;
|
|
273
|
+
}, Oe = () => {
|
|
274
|
+
console.error("Не удалось загрузить аудио"), u.value = !1, p.value = void 0, t.value && (t.value.pause(), t.value.currentTime = 0, t.value.removeAttribute("src"), t.value.load()), c.value = M(n.message.duration) ?? 0;
|
|
298
275
|
};
|
|
299
|
-
function
|
|
300
|
-
return
|
|
276
|
+
function _e(e) {
|
|
277
|
+
return ot(e.position, "audio-message");
|
|
301
278
|
}
|
|
302
|
-
const { onToggleReaction:
|
|
303
|
-
function
|
|
304
|
-
|
|
279
|
+
const { onToggleReaction: Ce, onAddReaction: ke, onRemoveReaction: De } = rt(d), Pe = tt(() => n.message, () => n.subtextTooltipData);
|
|
280
|
+
function Ue() {
|
|
281
|
+
d("sms-invite", n.message);
|
|
305
282
|
}
|
|
306
|
-
const
|
|
283
|
+
const H = { props: n, speed: R, speedIndex: S, currentSpeed: I, cycleSpeed: Z, emit: d, menuActions: ee, chatAppId: P, startReply: U, player: t, lazyAudioSrc: p, isPlaying: u, audioDuration: c, currentTime: i, isSeeking: v, audioSrc: x, parseMessageDurationToSeconds: M, resetAudioState: A, isOpenMenu: te, buttonMenuVisible: ae, menuAnchorRef: ne, menuRef: se, menuStyle: oe, menuTheme: re, showMenu: ue, hideMenu: L, openMenu: ie, toggleMenu: le, onMenuMouseEnter: ce, onMenuMouseLeave: me, clickAction: $, viewsAction: de, handleClickReplied: pe, expandedPanel: m, requestedOnDemand: g, recognitionReadyStatus: J, summaryReadyStatus: K, transcriptData: y, summaryData: h, transcriptHtml: j, isTranscriptReady: F, summaryHtml: B, isSummaryReady: G, hasTextOption: E, hasSummaryOption: O, isExpandedPanelVisible: ve, transcriptPlaceholderText: fe, summaryPlaceholderText: ge, downloadAudio: Y, handleActionClick: ye, linkedHtml: he, inNewWindow: be, status: Re, statusTitle: Se, rightBubbleStyle: xe, togglePlayPause: Me, formatTime: _, formatCurrentTime: Te, handleSeekEnd: we, formatDuration: Ne, handleLoadedMetadata: Ie, handleTimeUpdate: Ae, handleEnded: Ee, handleAudioError: Oe, getClass: _e, onToggleReaction: Ce, onAddReaction: ke, onRemoveReaction: De, channelInfo: Pe, handleSmsInvite: Ue, handleText: () => {
|
|
307
284
|
if (!E.value) return;
|
|
308
|
-
const e =
|
|
309
|
-
|
|
310
|
-
},
|
|
311
|
-
if (!
|
|
312
|
-
const e =
|
|
313
|
-
|
|
314
|
-
}
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
class: w(["audio-message", [
|
|
319
|
-
B(s.message),
|
|
320
|
-
s.applyStyle(s.message)
|
|
321
|
-
]]),
|
|
322
|
-
messageId: s.message.messageId,
|
|
323
|
-
style: Y(i(Pe)),
|
|
324
|
-
onMouseleave: t[8] || (t[8] = //@ts-ignore
|
|
325
|
-
(...n) => i($) && i($)(...n))
|
|
326
|
-
}, [
|
|
327
|
-
s.message.avatar && s.isFirstInSeries ? (u(), r("img", {
|
|
328
|
-
key: 0,
|
|
329
|
-
class: "audio-message__avatar",
|
|
330
|
-
src: s.message.avatar,
|
|
331
|
-
height: "32",
|
|
332
|
-
width: "32",
|
|
333
|
-
style: Y({ gridRow: s.message.subText ? "2" : "1" })
|
|
334
|
-
}, null, 12, kt)) : d("", !0),
|
|
335
|
-
s.message.subText && s.isFirstInSeries ? (u(), r("p", Rt, [
|
|
336
|
-
b(ct, {
|
|
337
|
-
text: i(qe),
|
|
338
|
-
position: s.message.position === "left" ? "right" : "left",
|
|
339
|
-
offset: 8
|
|
340
|
-
}, {
|
|
341
|
-
default: Z(() => [
|
|
342
|
-
tt(p(s.message.subText), 1)
|
|
343
|
-
]),
|
|
344
|
-
_: 1
|
|
345
|
-
}, 8, ["text", "position"])
|
|
346
|
-
])) : d("", !0),
|
|
347
|
-
o("div", {
|
|
348
|
-
class: w(["audio-message__content", { "is-first": s.isFirstInSeries, "with-avatar-indent": !s.isFirstInSeries && s.message.avatar }]),
|
|
349
|
-
onMouseenter: t[7] || (t[7] = //@ts-ignore
|
|
350
|
-
(...n) => i(J) && i(J)(...n))
|
|
351
|
-
}, [
|
|
352
|
-
t[13] || (t[13] = o("div", {
|
|
353
|
-
class: "audio-message__bottom-shadow",
|
|
354
|
-
"aria-hidden": "true"
|
|
355
|
-
}, null, -1)),
|
|
356
|
-
s.message.deleted ? (u(), r(q, { key: 0 }, [
|
|
357
|
-
b(dt),
|
|
358
|
-
o("div", Tt, [
|
|
359
|
-
o("div", St, [
|
|
360
|
-
s.message.time ? (u(), r("span", Nt, p(s.message.time), 1)) : d("", !0),
|
|
361
|
-
b(ge, {
|
|
362
|
-
"base-class": "audio-message",
|
|
363
|
-
"message-class": B(s.message),
|
|
364
|
-
"message-status": s.message.status,
|
|
365
|
-
"status-class": ne.value,
|
|
366
|
-
"status-title": oe.value
|
|
367
|
-
}, null, 8, ["message-class", "message-status", "status-class", "status-title"])
|
|
368
|
-
])
|
|
369
|
-
])
|
|
370
|
-
], 64)) : (u(), r(q, { key: 1 }, [
|
|
371
|
-
s.message.reply ? (u(), T(lt, {
|
|
372
|
-
key: 0,
|
|
373
|
-
style: { "grid-column": "1/3" },
|
|
374
|
-
message: s.message.reply,
|
|
375
|
-
class: w(s.message.position),
|
|
376
|
-
onReply: i(Ie)
|
|
377
|
-
}, null, 8, ["message", "class", "onReply"])) : d("", !0),
|
|
378
|
-
o("div", _t, [
|
|
379
|
-
o("audio", {
|
|
380
|
-
ref_key: "player",
|
|
381
|
-
ref: a,
|
|
382
|
-
src: x.value,
|
|
383
|
-
type: "audio/webm",
|
|
384
|
-
onLoadedmetadata: $e,
|
|
385
|
-
onTimeupdate: Be,
|
|
386
|
-
onEnded: He,
|
|
387
|
-
onError: je
|
|
388
|
-
}, null, 40, It),
|
|
389
|
-
z(o("button", {
|
|
390
|
-
class: "audio-message__play",
|
|
391
|
-
onClick: ie
|
|
392
|
-
}, [...t[9] || (t[9] = [
|
|
393
|
-
o("div", { class: "audio-message__play-icon" }, [
|
|
394
|
-
o("svg", {
|
|
395
|
-
width: "20",
|
|
396
|
-
height: "23",
|
|
397
|
-
viewBox: "0 0 20 23",
|
|
398
|
-
fill: "none",
|
|
399
|
-
xmlns: "http://www.w3.org/2000/svg"
|
|
400
|
-
}, [
|
|
401
|
-
o("path", {
|
|
402
|
-
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",
|
|
403
|
-
fill: "#5F5F5F"
|
|
404
|
-
})
|
|
405
|
-
])
|
|
406
|
-
], -1)
|
|
407
|
-
])], 512), [
|
|
408
|
-
[ce, !c.value]
|
|
409
|
-
]),
|
|
410
|
-
z(o("button", {
|
|
411
|
-
class: "audio-message__pause",
|
|
412
|
-
onClick: ie
|
|
413
|
-
}, [...t[10] || (t[10] = [
|
|
414
|
-
o("div", { class: "audio-message__pause-icon" }, [
|
|
415
|
-
o("svg", {
|
|
416
|
-
width: "20",
|
|
417
|
-
height: "23",
|
|
418
|
-
viewBox: "0 0 20 23",
|
|
419
|
-
fill: "none",
|
|
420
|
-
xmlns: "http://www.w3.org/2000/svg"
|
|
421
|
-
}, [
|
|
422
|
-
o("path", {
|
|
423
|
-
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",
|
|
424
|
-
fill: "#5F5F5F"
|
|
425
|
-
})
|
|
426
|
-
])
|
|
427
|
-
], -1)
|
|
428
|
-
])], 512), [
|
|
429
|
-
[ce, c.value]
|
|
430
|
-
]),
|
|
431
|
-
o("div", Et, [
|
|
432
|
-
z(o("input", {
|
|
433
|
-
"onUpdate:modelValue": t[0] || (t[0] = (n) => g.value = n),
|
|
434
|
-
class: "audio-message__progress-bar-container",
|
|
435
|
-
type: "range",
|
|
436
|
-
min: 0,
|
|
437
|
-
max: h.value,
|
|
438
|
-
step: "0.1",
|
|
439
|
-
onMousedown: t[1] || (t[1] = (n) => C.value = !0),
|
|
440
|
-
onMouseup: le,
|
|
441
|
-
onTouchstartPassive: t[2] || (t[2] = (n) => C.value = !0),
|
|
442
|
-
onTouchendPassive: le
|
|
443
|
-
}, null, 40, At), [
|
|
444
|
-
[st, g.value]
|
|
445
|
-
]),
|
|
446
|
-
o("div", Ot, [
|
|
447
|
-
o("button", {
|
|
448
|
-
type: "button",
|
|
449
|
-
class: "audio-message__speed-btn",
|
|
450
|
-
onClick: pe
|
|
451
|
-
}, p(P.value.text), 1)
|
|
452
|
-
])
|
|
453
|
-
]),
|
|
454
|
-
o("div", Ft, [
|
|
455
|
-
o("p", Lt, p(Ue.value), 1),
|
|
456
|
-
o("p", Dt, p(Ve.value), 1)
|
|
457
|
-
])
|
|
458
|
-
]),
|
|
459
|
-
s.message.text ? (u(), r("div", Pt, [
|
|
460
|
-
o("p", {
|
|
461
|
-
onClick: t[3] || (t[3] = //@ts-ignore
|
|
462
|
-
(...n) => i(ae) && i(ae)(...n)),
|
|
463
|
-
innerHTML: i(De)
|
|
464
|
-
}, null, 8, Ut)
|
|
465
|
-
])) : d("", !0),
|
|
466
|
-
s.message.linkPreview ? (u(), T(it, {
|
|
467
|
-
key: 2,
|
|
468
|
-
class: w(["audio-message__link-preview", s.message.position]),
|
|
469
|
-
"link-preview": s.message.linkPreview
|
|
470
|
-
}, null, 8, ["class", "link-preview"])) : d("", !0),
|
|
471
|
-
s.message.embed ? (u(), T(ut, {
|
|
472
|
-
key: 3,
|
|
473
|
-
class: w(s.message.position),
|
|
474
|
-
embed: s.message.embed
|
|
475
|
-
}, null, 8, ["class", "embed"])) : d("", !0),
|
|
476
|
-
o("div", Vt, [
|
|
477
|
-
b(rt, {
|
|
478
|
-
reactions: s.message.reactions,
|
|
479
|
-
"message-id": s.message.messageId,
|
|
480
|
-
reply: i(fe)(s.message, "message.audio"),
|
|
481
|
-
enabled: s.reactionsEnabled,
|
|
482
|
-
mode: s.reactionsMode,
|
|
483
|
-
"current-user-id": s.currentUserId,
|
|
484
|
-
"reaction-user-names": s.reactionUserNames,
|
|
485
|
-
"menu-enabled": i(S).length > 0,
|
|
486
|
-
onToggleReaction: i(Ge),
|
|
487
|
-
onAddReaction: i(Ye),
|
|
488
|
-
onRemoveReaction: i(Ze),
|
|
489
|
-
onMenu: i(Te)
|
|
490
|
-
}, null, 8, ["reactions", "message-id", "reply", "enabled", "mode", "current-user-id", "reaction-user-names", "menu-enabled", "onToggleReaction", "onAddReaction", "onRemoveReaction", "onMenu"]),
|
|
491
|
-
o("div", $t, [
|
|
492
|
-
E.value || A.value ? (u(), r("div", Bt, [
|
|
493
|
-
E.value ? (u(), r("button", {
|
|
494
|
-
key: 0,
|
|
495
|
-
class: w([
|
|
496
|
-
"audio-message__action-button",
|
|
497
|
-
{ "audio-message__action-button--active": f.value === "text" }
|
|
498
|
-
]),
|
|
499
|
-
type: "button",
|
|
500
|
-
onClick: We
|
|
501
|
-
}, " Текст ", 2)) : d("", !0),
|
|
502
|
-
A.value ? (u(), r("button", {
|
|
503
|
-
key: 1,
|
|
504
|
-
class: w([
|
|
505
|
-
"audio-message__action-button",
|
|
506
|
-
{ "audio-message__action-button--active": f.value === "summary" }
|
|
507
|
-
]),
|
|
508
|
-
type: "button",
|
|
509
|
-
onClick: Je
|
|
510
|
-
}, " Резюме ", 2)) : d("", !0)
|
|
511
|
-
])) : d("", !0),
|
|
512
|
-
s.message.views ? (u(), r("div", {
|
|
513
|
-
key: 1,
|
|
514
|
-
class: "audio-message__views",
|
|
515
|
-
onClick: t[4] || (t[4] = //@ts-ignore
|
|
516
|
-
(...n) => i(Q) && i(Q)(...n))
|
|
517
|
-
}, [
|
|
518
|
-
t[11] || (t[11] = o("span", { class: "pi pi-eye" }, null, -1)),
|
|
519
|
-
o("p", null, p(s.message.views), 1)
|
|
520
|
-
])) : d("", !0),
|
|
521
|
-
o("span", Ht, p(s.message.time), 1),
|
|
522
|
-
b(ge, {
|
|
523
|
-
"base-class": "audio-message",
|
|
524
|
-
"message-class": B(s.message),
|
|
525
|
-
"message-status": s.message.status,
|
|
526
|
-
"status-class": ne.value,
|
|
527
|
-
"status-title": oe.value
|
|
528
|
-
}, null, 8, ["message-class", "message-status", "status-class", "status-title"])
|
|
529
|
-
])
|
|
530
|
-
]),
|
|
531
|
-
b(ve, { name: "audio-message-expand" }, {
|
|
532
|
-
default: Z(() => [
|
|
533
|
-
Ee.value ? (u(), r("div", jt, [
|
|
534
|
-
o("div", Gt, [
|
|
535
|
-
f.value === "text" ? (u(), r(q, { key: 0 }, [
|
|
536
|
-
ee.value ? (u(), r("p", {
|
|
537
|
-
key: 1,
|
|
538
|
-
class: "audio-message__expand-plain",
|
|
539
|
-
innerHTML: X.value
|
|
540
|
-
}, null, 8, Zt)) : (u(), r("p", Yt, p(Ae.value), 1))
|
|
541
|
-
], 64)) : (u(), r("p", qt, [
|
|
542
|
-
se.value ? (u(), r("span", {
|
|
543
|
-
key: 1,
|
|
544
|
-
innerHTML: te.value
|
|
545
|
-
}, null, 8, Wt)) : (u(), r("span", zt, p(Oe.value), 1))
|
|
546
|
-
]))
|
|
547
|
-
]),
|
|
548
|
-
o("div", Jt, [
|
|
549
|
-
o("button", {
|
|
550
|
-
type: "button",
|
|
551
|
-
class: "audio-message__expand-close",
|
|
552
|
-
onClick: t[5] || (t[5] = (n) => f.value = null)
|
|
553
|
-
}, " Закрыть ")
|
|
554
|
-
])
|
|
555
|
-
])) : d("", !0)
|
|
556
|
-
]),
|
|
557
|
-
_: 1
|
|
558
|
-
}),
|
|
559
|
-
b(mt, {
|
|
560
|
-
status: s.message.status,
|
|
561
|
-
"has-messenger-account": s.message.hasMessengerAccount,
|
|
562
|
-
channel: s.channel,
|
|
563
|
-
onSmsInvite: ze
|
|
564
|
-
}, null, 8, ["status", "has-messenger-account", "channel"]),
|
|
565
|
-
i(we) && i(S).length && !s.reactionsEnabled ? (u(), r("button", {
|
|
566
|
-
key: 4,
|
|
567
|
-
class: "audio-message__menu-button",
|
|
568
|
-
onClick: t[6] || (t[6] = //@ts-ignore
|
|
569
|
-
(...n) => i(K) && i(K)(...n))
|
|
570
|
-
}, [...t[12] || (t[12] = [
|
|
571
|
-
o("svg", {
|
|
572
|
-
width: "4",
|
|
573
|
-
height: "17",
|
|
574
|
-
viewBox: "0 0 4 17",
|
|
575
|
-
fill: "none",
|
|
576
|
-
xmlns: "http://www.w3.org/2000/svg"
|
|
577
|
-
}, [
|
|
578
|
-
o("path", {
|
|
579
|
-
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",
|
|
580
|
-
fill: "#5F5F5F"
|
|
581
|
-
})
|
|
582
|
-
], -1)
|
|
583
|
-
])])) : d("", !0),
|
|
584
|
-
(u(), T(at, { to: "body" }, [
|
|
585
|
-
b(ve, null, {
|
|
586
|
-
default: Z(() => [
|
|
587
|
-
i(Ce) && i(S).length ? (u(), T(ot, {
|
|
588
|
-
key: 0,
|
|
589
|
-
ref_key: "menuRef",
|
|
590
|
-
ref: Me,
|
|
591
|
-
class: "audio-message__context-menu message-actions-menu",
|
|
592
|
-
style: Y(i(ke)),
|
|
593
|
-
"data-theme": i(Re),
|
|
594
|
-
actions: i(S),
|
|
595
|
-
onClick: Le,
|
|
596
|
-
onMouseenter: i(Se),
|
|
597
|
-
onMouseleave: i(Ne)
|
|
598
|
-
}, null, 8, ["style", "data-theme", "actions", "onMouseenter", "onMouseleave"])) : d("", !0)
|
|
599
|
-
]),
|
|
600
|
-
_: 1
|
|
601
|
-
})
|
|
602
|
-
]))
|
|
603
|
-
], 64))
|
|
604
|
-
], 34)
|
|
605
|
-
], 46, Mt));
|
|
285
|
+
const e = m.value === "text" ? null : "text";
|
|
286
|
+
m.value = e, e === "text" && !F.value && !g.value.text && (g.value.text = !0, d("action", { action: "fetchTranscript", messageId: n.message.messageId }));
|
|
287
|
+
}, handleSummary: () => {
|
|
288
|
+
if (!O.value) return;
|
|
289
|
+
const e = m.value === "summary" ? null : "summary";
|
|
290
|
+
m.value = e, e === "summary" && !G.value && !g.value.summary && (g.value.summary = !0, d("action", { action: "fetchSummary", messageId: n.message.messageId }));
|
|
291
|
+
}, ContextMenu: Ge, LinkPreview: Ye, EmbedPreview: He, BaseReplyMessage: qe, MessageReactions: Ve, MessageStatusIndicator: ze, MessageSmsInvite: We, DeletedMessageContent: Je, Tooltip: Ke, get buildReplyPayload() {
|
|
292
|
+
return W;
|
|
293
|
+
} };
|
|
294
|
+
return Object.defineProperty(H, "__isScriptSetup", { enumerable: !1, value: !0 }), H;
|
|
606
295
|
}
|
|
607
296
|
});
|
|
608
297
|
export {
|
|
609
|
-
|
|
298
|
+
jt as default
|
|
610
299
|
};
|