@mobilon-dev/chotto 0.3.98 → 0.3.99
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 +61 -42
- 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 +38 -22
- package/dist/components/1_atoms/EmojiGlyph/EmojiGlyph.vue2.js +2 -33
- 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/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/WhatsAppIcon.vue.js +20 -32
- package/dist/components/2_blocks/CommunicationPanel/CommunicationPanel.vue.js +396 -546
- 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 +42 -8
- 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 -61
- package/dist/components/2_chatinput_elements/ButtonEmojiPicker/ButtonEmojiPicker.vue2.js +96 -79
- 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 +51 -80
- package/dist/components/2_chatinput_elements/FilePreview/FilePreview.vue.js +4 -182
- package/dist/components/2_chatinput_elements/FilePreview/FilePreview.vue2.js +135 -25
- package/dist/components/2_chatinput_elements/FileUploader/FileUploader.vue.js +4 -78
- package/dist/components/2_chatinput_elements/FileUploader/FileUploader.vue2.js +95 -73
- 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 +60 -34
- 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 +33 -39
- package/dist/components/2_chatlist_elements/ChatItem/ChatItem.vue.js +4 -306
- package/dist/components/2_chatlist_elements/ChatItem/ChatItem.vue2.js +311 -134
- 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 +67 -35
- package/dist/components/2_elements/ChannelSelector/ChannelSelector.vue.js +38 -72
- package/dist/components/2_elements/ChatInfo/ChatInfo.vue.js +57 -76
- 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 +39 -19
- package/dist/components/2_feed_elements/AudioMessage/AudioMessage.vue.js +4 -458
- package/dist/components/2_feed_elements/AudioMessage/AudioMessage.vue2.js +471 -160
- 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/DeletedMessageContent/icons/DeletedMessageIcon.vue.js +10 -16
- package/dist/components/2_feed_elements/DelimiterMessage/DelimiterMessage.vue.js +4 -60
- package/dist/components/2_feed_elements/DelimiterMessage/DelimiterMessage.vue2.js +53 -36
- 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/FileMessage/FileMessage.vue.js +4 -250
- package/dist/components/2_feed_elements/FileMessage/FileMessage.vue2.js +233 -67
- package/dist/components/2_feed_elements/ImageMessage/ImageMessage.vue.js +4 -315
- package/dist/components/2_feed_elements/ImageMessage/ImageMessage.vue2.js +319 -98
- 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 -155
- package/dist/components/2_feed_elements/MessageReactions/MessageReactions.vue2.js +212 -110
- 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 +120 -36
- 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 -75
- package/dist/components/2_feed_elements/ReplyVideoMessage/ReplyVideoMessage.vue2.js +63 -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 -346
- package/dist/components/2_feed_elements/StickerMessage/StickerMessage.vue2.js +307 -73
- 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 -307
- package/dist/components/2_feed_elements/TextMessage/TextMessage.vue2.js +269 -65
- 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 -307
- package/dist/components/2_feed_elements/VideoMessage/VideoMessage.vue2.js +298 -76
- 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 +18 -35
- 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 -85
- package/dist/components/3_compounds/ChatInput/ChatInput.vue2.js +210 -149
- 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 +163 -253
- package/dist/components/3_compounds/ChatList/ChatListHeader.vue.js +32 -50
- package/dist/components/3_compounds/ChatList/icons/LogoIcon.vue.js +6 -6
- package/dist/components/3_compounds/Feed/Feed.vue.js +4 -172
- package/dist/components/3_compounds/Feed/Feed.vue2.js +257 -126
- 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 -31
- package/dist/components/5_containers/FloatContainer/FloatContainer.vue.js +56 -85
- package/package.json +1 -1
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as N, inject as O, ref as c, watch as U, onMounted as W, onUnmounted as X, createBlock as P, openBlock as z, Teleport as Q, createVNode as D, Transition as G, withCtx as J, createElementBlock as K, createCommentVNode as Z, normalizeStyle as ee, unref as u, createElementVNode as o, nextTick as te } from "vue";
|
|
2
2
|
import "../../../hooks/useMessageDraft.js";
|
|
3
3
|
import "../../../hooks/useSearchModel.js";
|
|
4
|
-
import { useTheme as
|
|
4
|
+
import { useTheme as oe } from "../../../hooks/useTheme.js";
|
|
5
5
|
import "../../../hooks/useEmojiNative.js";
|
|
6
6
|
/* empty css */
|
|
7
7
|
/* empty css */
|
|
8
|
-
import { t as
|
|
8
|
+
import { t as f } from "../../../locale/useLocale.js";
|
|
9
9
|
/* empty css */
|
|
10
10
|
import "../../../node_modules/linkifyjs/dist/linkify.js";
|
|
11
11
|
import "../../../node_modules/linkify-string/dist/linkify-string.js";
|
|
12
12
|
import "../../../functions/parseMarkdown.js";
|
|
13
|
-
const le = /* @__PURE__ */
|
|
13
|
+
const ne = ["data-theme"], ie = ["title"], se = ["title"], re = ["title"], le = ["title"], ae = ["title"], ue = ["title"], Le = /* @__PURE__ */ N({
|
|
14
14
|
__name: "TextFormatToolbar",
|
|
15
15
|
props: {
|
|
16
16
|
textarea: {
|
|
@@ -19,107 +19,195 @@ const le = /* @__PURE__ */ I({
|
|
|
19
19
|
}
|
|
20
20
|
},
|
|
21
21
|
emits: ["format-applied"],
|
|
22
|
-
setup(
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
const O = {
|
|
22
|
+
setup(H, { emit: R }) {
|
|
23
|
+
const m = H, F = R, A = O("chatAppId"), { getTheme: k } = oe(A), x = c(), h = c(!1), q = c({ top: "0px", left: "0px" }), S = c(""), $ = c(0), y = c(0);
|
|
24
|
+
let b = !1, a = null, i = null, B = 0, T = 0;
|
|
25
|
+
const V = {
|
|
27
26
|
bold: { prefix: "**", suffix: "**" },
|
|
28
27
|
italic: { prefix: "*", suffix: "*" },
|
|
29
28
|
underline: { prefix: "<u>", suffix: "</u>" },
|
|
30
29
|
strikethrough: { prefix: "~~", suffix: "~~" },
|
|
31
30
|
code: { prefix: "`", suffix: "`" },
|
|
32
31
|
quote: { prefix: "> ", suffix: "" }
|
|
33
|
-
},
|
|
34
|
-
|
|
35
|
-
},
|
|
36
|
-
const
|
|
37
|
-
if (!
|
|
32
|
+
}, g = (t) => {
|
|
33
|
+
B = t.clientX, T = t.clientY;
|
|
34
|
+
}, r = () => {
|
|
35
|
+
const t = i || m.textarea;
|
|
36
|
+
if (!t)
|
|
38
37
|
return;
|
|
39
|
-
const
|
|
40
|
-
if (
|
|
41
|
-
|
|
38
|
+
const e = t.selectionStart, n = t.selectionEnd;
|
|
39
|
+
if (e === n) {
|
|
40
|
+
w();
|
|
42
41
|
return;
|
|
43
42
|
}
|
|
44
|
-
const
|
|
45
|
-
|
|
46
|
-
},
|
|
47
|
-
const
|
|
48
|
-
!
|
|
49
|
-
},
|
|
50
|
-
|
|
51
|
-
},
|
|
52
|
-
|
|
53
|
-
if (!
|
|
54
|
-
const
|
|
55
|
-
let
|
|
56
|
-
|
|
57
|
-
top: `${
|
|
58
|
-
left: `${
|
|
43
|
+
const s = t.value.substring(e, n);
|
|
44
|
+
s.trim().length > 0 ? (S.value = s, $.value = e, y.value = n, Y(), h.value = !0, a && (clearTimeout(a), a = null)) : w();
|
|
45
|
+
}, M = () => {
|
|
46
|
+
const t = i || m.textarea;
|
|
47
|
+
!t || document.activeElement !== t || r();
|
|
48
|
+
}, _ = (t) => {
|
|
49
|
+
i && (i.removeEventListener("mouseup", r), i.removeEventListener("keyup", r), i.removeEventListener("select", r), i.removeEventListener("mousemove", g)), document.removeEventListener("selectionchange", M), t ? (i = t, t.addEventListener("mouseup", r), t.addEventListener("keyup", r), t.addEventListener("select", r), t.addEventListener("mousemove", g), document.addEventListener("selectionchange", M)) : i = null;
|
|
50
|
+
}, Y = () => {
|
|
51
|
+
te(() => {
|
|
52
|
+
if (!x.value) return;
|
|
53
|
+
const t = x.value.getBoundingClientRect(), e = window.innerWidth, n = window.innerHeight;
|
|
54
|
+
let s = B - t.width / 2, l = T - t.height - 10;
|
|
55
|
+
s < 10 ? s = 10 : s + t.width > e - 10 && (s = e - t.width - 10), l < 10 ? l = T + 20 : l + t.height > n - 10 && (l = n - t.height - 10), q.value = {
|
|
56
|
+
top: `${l}px`,
|
|
57
|
+
left: `${s}px`
|
|
59
58
|
};
|
|
60
59
|
});
|
|
61
|
-
},
|
|
62
|
-
const
|
|
63
|
-
if (!
|
|
64
|
-
const
|
|
65
|
-
if (!
|
|
66
|
-
const
|
|
67
|
-
let
|
|
68
|
-
|
|
60
|
+
}, d = (t) => {
|
|
61
|
+
const e = m.textarea;
|
|
62
|
+
if (!e) return;
|
|
63
|
+
const n = V[t];
|
|
64
|
+
if (!n) return;
|
|
65
|
+
const s = e.value, l = $.value, p = y.value, C = s.substring(l, p);
|
|
66
|
+
let v, L;
|
|
67
|
+
t === "quote" ? (v = C.split(`
|
|
69
68
|
`).map(
|
|
70
|
-
(
|
|
69
|
+
(E) => E.trim() ? `${n.prefix}${E}${n.suffix}` : E
|
|
71
70
|
).join(`
|
|
72
|
-
`),
|
|
73
|
-
format:
|
|
74
|
-
selectedText:
|
|
75
|
-
start:
|
|
76
|
-
end:
|
|
77
|
-
newText:
|
|
71
|
+
`), L = s.substring(0, l) + v + s.substring(p)) : (v = `${n.prefix}${C}${n.suffix}`, L = s.substring(0, l) + v + s.substring(p)), F("format-applied", {
|
|
72
|
+
format: t,
|
|
73
|
+
selectedText: C,
|
|
74
|
+
start: l,
|
|
75
|
+
end: p,
|
|
76
|
+
newText: L
|
|
78
77
|
}), setTimeout(() => {
|
|
79
|
-
|
|
78
|
+
r();
|
|
80
79
|
}, 10);
|
|
81
|
-
},
|
|
82
|
-
|
|
83
|
-
},
|
|
84
|
-
|
|
85
|
-
},
|
|
86
|
-
|
|
87
|
-
|
|
80
|
+
}, w = () => {
|
|
81
|
+
b || (h.value = !1);
|
|
82
|
+
}, j = () => {
|
|
83
|
+
b = !0, a && (clearTimeout(a), a = null);
|
|
84
|
+
}, I = () => {
|
|
85
|
+
b = !1, a = setTimeout(() => {
|
|
86
|
+
w();
|
|
88
87
|
}, 200);
|
|
89
88
|
};
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
}, { immediate: !0 }),
|
|
93
|
-
|
|
94
|
-
}),
|
|
95
|
-
|
|
96
|
-
})
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
89
|
+
return U(() => m.textarea, (t, e) => {
|
|
90
|
+
t !== e && _(t);
|
|
91
|
+
}, { immediate: !0 }), W(() => {
|
|
92
|
+
m.textarea && _(m.textarea);
|
|
93
|
+
}), X(() => {
|
|
94
|
+
i && (i.removeEventListener("mouseup", r), i.removeEventListener("keyup", r), i.removeEventListener("select", r), i.removeEventListener("mousemove", g)), document.removeEventListener("selectionchange", M), a && clearTimeout(a);
|
|
95
|
+
}), (t, e) => (z(), P(Q, { to: "body" }, [
|
|
96
|
+
D(G, { name: "fade" }, {
|
|
97
|
+
default: J(() => [
|
|
98
|
+
h.value ? (z(), K("div", {
|
|
99
|
+
key: 0,
|
|
100
|
+
ref_key: "toolbarRef",
|
|
101
|
+
ref: x,
|
|
102
|
+
"data-theme": u(k)().theme ? u(k)().theme : "light",
|
|
103
|
+
class: "text-format-toolbar",
|
|
104
|
+
style: ee(q.value),
|
|
105
|
+
onMouseenter: j,
|
|
106
|
+
onMouseleave: I
|
|
107
|
+
}, [
|
|
108
|
+
o("button", {
|
|
109
|
+
class: "text-format-toolbar__button",
|
|
110
|
+
title: u(f)("component.TextFormatToolbar.Bold"),
|
|
111
|
+
onClick: e[0] || (e[0] = (n) => d("bold"))
|
|
112
|
+
}, [...e[6] || (e[6] = [
|
|
113
|
+
o("svg", {
|
|
114
|
+
viewBox: "0 0 24 24",
|
|
115
|
+
width: "20",
|
|
116
|
+
preserveAspectRatio: "xMidYMid meet",
|
|
117
|
+
class: "",
|
|
118
|
+
fill: "currentColor"
|
|
119
|
+
}, [
|
|
120
|
+
o("path", { d: "M6.8 19V5h5.525q1.624 0 3 1T16.7 8.775q0 1.275-.575 1.963-.575.687-1.075.987.626.275 1.387 1.025.763.75.763 2.25 0 2.224-1.625 3.113-1.625.887-3.05.887zm3.025-2.8h2.6q1.2 0 1.462-.612.263-.614.263-.888 0-.275-.263-.887-.262-.613-1.537-.613H9.825zm0-5.7h2.325q.825 0 1.2-.425a1.4 1.4 0 0 0 .375-.95q0-.6-.425-.975t-1.1-.375H9.825z" })
|
|
121
|
+
], -1)
|
|
122
|
+
])], 8, ie),
|
|
123
|
+
o("button", {
|
|
124
|
+
class: "text-format-toolbar__button",
|
|
125
|
+
title: u(f)("component.TextFormatToolbar.Italic"),
|
|
126
|
+
onClick: e[1] || (e[1] = (n) => d("italic"))
|
|
127
|
+
}, [...e[7] || (e[7] = [
|
|
128
|
+
o("svg", {
|
|
129
|
+
viewBox: "0 0 24 24",
|
|
130
|
+
width: "20",
|
|
131
|
+
preserveAspectRatio: "xMidYMid meet",
|
|
132
|
+
class: "",
|
|
133
|
+
fill: "currentColor"
|
|
134
|
+
}, [
|
|
135
|
+
o("path", { d: "M5 19v-2.5h4l3-9H8V5h10v2.5h-3.5l-3 9H15V19z" })
|
|
136
|
+
], -1)
|
|
137
|
+
])], 8, se),
|
|
138
|
+
o("button", {
|
|
139
|
+
class: "text-format-toolbar__button",
|
|
140
|
+
title: u(f)("component.TextFormatToolbar.Underline"),
|
|
141
|
+
onClick: e[2] || (e[2] = (n) => d("underline"))
|
|
142
|
+
}, [...e[8] || (e[8] = [
|
|
143
|
+
o("svg", {
|
|
144
|
+
viewBox: "0 0 512 512",
|
|
145
|
+
width: "13",
|
|
146
|
+
height: "13",
|
|
147
|
+
preserveAspectRatio: "xMidYMid meet",
|
|
148
|
+
class: "",
|
|
149
|
+
fill: "currentColor"
|
|
150
|
+
}, [
|
|
151
|
+
o("rect", {
|
|
152
|
+
x: "16.65",
|
|
153
|
+
y: "443.317",
|
|
154
|
+
width: "478.699",
|
|
155
|
+
height: "68.683"
|
|
156
|
+
}),
|
|
157
|
+
o("path", { d: `M303.383,0h-94L87.689,376.715h88.041l21.225-72.846H315.81l21.496,72.846h88.043L303.383,0z M216.38,235.187
|
|
158
|
+
l39.103-133.203h1.544l39.362,133.203H216.38z` })
|
|
159
|
+
], -1)
|
|
160
|
+
])], 8, re),
|
|
161
|
+
o("button", {
|
|
162
|
+
class: "text-format-toolbar__button",
|
|
163
|
+
title: u(f)("component.TextFormatToolbar.Strikethrough"),
|
|
164
|
+
onClick: e[3] || (e[3] = (n) => d("strikethrough"))
|
|
165
|
+
}, [...e[9] || (e[9] = [
|
|
166
|
+
o("svg", {
|
|
167
|
+
viewBox: "0 0 24 24",
|
|
168
|
+
width: "20",
|
|
169
|
+
preserveAspectRatio: "xMidYMid meet",
|
|
170
|
+
class: "",
|
|
171
|
+
fill: "currentColor"
|
|
172
|
+
}, [
|
|
173
|
+
o("path", { d: "M13.99 15.27q0-.83-.586-1.27-.585-.45-2.11-.937L11.107 13H4v-2h16v2h-3.76q.69.96.69 2.25 0 1.845-1.397 2.9-1.396 1.045-3.76 1.045-1.64 0-2.988-.595-1.347-.606-2.06-1.65a4 4 0 0 1-.472-.951l2.451-.98c.145.303.363.651.667.962l.014.019h.004a2.87 2.87 0 0 0 1.971.867q.199.014.413.014 1.045 0 1.631-.42.586-.43.586-1.191M10.548 10h-3.79a3.5 3.5 0 0 1-.297-1.44q0-1.152.644-2.05.655-.909 1.866-1.416 1.22-.508 2.734-.508 1.523 0 2.715.557 1.191.546 1.846 1.552.26.394.418.831l-2.492.997C13.85 7.823 13 7 11.656 6.92q-1.074 0-1.67.459a1.42 1.42 0 0 0-.595 1.191q0 .694.693 1.162.204.136.464.268" })
|
|
174
|
+
], -1)
|
|
175
|
+
])], 8, le),
|
|
176
|
+
o("button", {
|
|
177
|
+
class: "text-format-toolbar__button",
|
|
178
|
+
title: u(f)("component.TextFormatToolbar.Code"),
|
|
179
|
+
onClick: e[4] || (e[4] = (n) => d("code"))
|
|
180
|
+
}, [...e[10] || (e[10] = [
|
|
181
|
+
o("span", { class: "pi pi-code" }, null, -1)
|
|
182
|
+
])], 8, ae),
|
|
183
|
+
o("button", {
|
|
184
|
+
class: "text-format-toolbar__button",
|
|
185
|
+
title: u(f)("component.TextFormatToolbar.Quote"),
|
|
186
|
+
onClick: e[5] || (e[5] = (n) => d("quote"))
|
|
187
|
+
}, [...e[11] || (e[11] = [
|
|
188
|
+
o("svg", {
|
|
189
|
+
viewBox: "0 0 512 512",
|
|
190
|
+
width: "13",
|
|
191
|
+
height: "13",
|
|
192
|
+
preserveAspectRatio: "xMidYMid meet",
|
|
193
|
+
class: "",
|
|
194
|
+
fill: "currentColor"
|
|
195
|
+
}, [
|
|
196
|
+
o("path", { d: `M119.472,66.59C53.489,66.59,0,120.094,0,186.1c0,65.983,53.489,119.487,119.472,119.487
|
|
197
|
+
c0,0-0.578,44.392-36.642,108.284c-4.006,12.802,3.135,26.435,15.945,30.418c9.089,2.859,18.653,0.08,24.829-6.389
|
|
198
|
+
c82.925-90.7,115.385-197.448,115.385-251.8C238.989,120.094,185.501,66.59,119.472,66.59z` }),
|
|
199
|
+
o("path", { d: `M392.482,66.59c-65.983,0-119.472,53.505-119.472,119.51c0,65.983,53.489,119.487,119.472,119.487
|
|
200
|
+
c0,0-0.578,44.392-36.642,108.284c-4.006,12.802,3.136,26.435,15.945,30.418c9.089,2.859,18.653,0.08,24.828-6.389
|
|
201
|
+
C479.539,347.2,512,240.452,512,186.1C512,120.094,458.511,66.59,392.482,66.59z` })
|
|
202
|
+
], -1)
|
|
203
|
+
])], 8, ue)
|
|
204
|
+
], 44, ne)) : Z("", !0)
|
|
205
|
+
]),
|
|
206
|
+
_: 1
|
|
207
|
+
})
|
|
208
|
+
]));
|
|
121
209
|
}
|
|
122
210
|
});
|
|
123
211
|
export {
|
|
124
|
-
|
|
212
|
+
Le as default
|
|
125
213
|
};
|
package/dist/components/2_chatinput_elements/WABAAttachmentSection/WABAAttachmentSection.vue.js
CHANGED
|
@@ -1,76 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { createElementBlock as i, openBlock as n, Fragment as s, createBlock as _, createCommentVNode as a, normalizeClass as m, createElementVNode as t, toDisplayString as r } from "vue";
|
|
1
|
+
import t from "./WABAAttachmentSection.vue2.js";
|
|
3
2
|
/* empty css */
|
|
4
|
-
import
|
|
5
|
-
const
|
|
6
|
-
key: 2,
|
|
7
|
-
class: "attachment-section__error-text"
|
|
8
|
-
};
|
|
9
|
-
function v(u, o, c, e, y, A) {
|
|
10
|
-
return n(), i(
|
|
11
|
-
s,
|
|
12
|
-
null,
|
|
13
|
-
[
|
|
14
|
-
e.uploadStatus !== "success" ? (n(), i(
|
|
15
|
-
"div",
|
|
16
|
-
{
|
|
17
|
-
key: 0,
|
|
18
|
-
class: m(["attachment-section", { "attachment-section__error": e.error }]),
|
|
19
|
-
onClick: e.triggerFileUpload
|
|
20
|
-
},
|
|
21
|
-
[
|
|
22
|
-
t("input", {
|
|
23
|
-
id: "file-upload",
|
|
24
|
-
ref: "fileInput",
|
|
25
|
-
type: "file",
|
|
26
|
-
style: { display: "none" },
|
|
27
|
-
accept: e.fileInfo[c.type].accept,
|
|
28
|
-
onChange: e.handleFileChange
|
|
29
|
-
}, null, 40, f),
|
|
30
|
-
o[1] || (o[1] = t(
|
|
31
|
-
"span",
|
|
32
|
-
{ class: "pi pi-paperclip attachment-section__icon" },
|
|
33
|
-
null,
|
|
34
|
-
-1
|
|
35
|
-
/* CACHED */
|
|
36
|
-
)),
|
|
37
|
-
t("div", null, [
|
|
38
|
-
o[0] || (o[0] = t(
|
|
39
|
-
"p",
|
|
40
|
-
{ class: "attachment-section__title" },
|
|
41
|
-
" Прикрепить файл ",
|
|
42
|
-
-1
|
|
43
|
-
/* CACHED */
|
|
44
|
-
)),
|
|
45
|
-
t(
|
|
46
|
-
"p",
|
|
47
|
-
p,
|
|
48
|
-
r(e.fileInfo[c.type].text),
|
|
49
|
-
1
|
|
50
|
-
/* TEXT */
|
|
51
|
-
)
|
|
52
|
-
])
|
|
53
|
-
],
|
|
54
|
-
2
|
|
55
|
-
/* CLASS */
|
|
56
|
-
)) : e.uploadStatus === "success" && e.preview ? (n(), _(e.FilePreview, {
|
|
57
|
-
key: 1,
|
|
58
|
-
"file-info": e.preview,
|
|
59
|
-
onReset: e.handleFileDecline
|
|
60
|
-
}, null, 8, ["file-info"])) : a("v-if", !0),
|
|
61
|
-
e.error ? (n(), i(
|
|
62
|
-
"div",
|
|
63
|
-
h,
|
|
64
|
-
r(e.error),
|
|
65
|
-
1
|
|
66
|
-
/* TEXT */
|
|
67
|
-
)) : a("v-if", !0)
|
|
68
|
-
],
|
|
69
|
-
64
|
|
70
|
-
/* STABLE_FRAGMENT */
|
|
71
|
-
);
|
|
72
|
-
}
|
|
73
|
-
const x = /* @__PURE__ */ d(l, [["render", v], ["__scopeId", "data-v-cdbee945"], ["__file", "/var/store/dev-space/repos-projects/chotto/chotto/src/components/2_chatinput_elements/WABAAttachmentSection/WABAAttachmentSection.vue"]]);
|
|
3
|
+
import o from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
+
const a = /* @__PURE__ */ o(t, [["__scopeId", "data-v-8c8d4b41"]]);
|
|
74
5
|
export {
|
|
75
|
-
|
|
6
|
+
a as default
|
|
76
7
|
};
|
package/dist/components/2_chatinput_elements/WABAAttachmentSection/WABAAttachmentSection.vue2.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import { uploadFile as
|
|
1
|
+
import { defineComponent as E, ref as n, inject as F, watch as h, createElementBlock as v, openBlock as u, Fragment as A, createBlock as D, createCommentVNode as S, normalizeClass as P, createElementVNode as r, toDisplayString as _, unref as U } from "vue";
|
|
2
|
+
import V from "../FilePreview/FilePreview.vue.js";
|
|
3
|
+
import { uploadFile as N } from "../../../hooks/uploadFile/uploadFile.js";
|
|
4
4
|
import "../../../hooks/useMessageDraft.js";
|
|
5
5
|
import "../../../hooks/useSearchModel.js";
|
|
6
6
|
import "../../../hooks/useTheme.js";
|
|
@@ -12,7 +12,10 @@ import "../../../locale/useLocale.js";
|
|
|
12
12
|
import "../../../node_modules/linkifyjs/dist/linkify.js";
|
|
13
13
|
import "../../../node_modules/linkify-string/dist/linkify-string.js";
|
|
14
14
|
import "../../../functions/parseMarkdown.js";
|
|
15
|
-
const
|
|
15
|
+
const O = ["accept"], B = { class: "attachment-section__info" }, G = {
|
|
16
|
+
key: 2,
|
|
17
|
+
class: "attachment-section__error-text"
|
|
18
|
+
}, $ = /* @__PURE__ */ E({
|
|
16
19
|
__name: "WABAAttachmentSection",
|
|
17
20
|
props: {
|
|
18
21
|
type: {
|
|
@@ -25,10 +28,9 @@ const T = /* @__PURE__ */ I({
|
|
|
25
28
|
}
|
|
26
29
|
},
|
|
27
30
|
emits: ["fileSelected"],
|
|
28
|
-
setup(
|
|
29
|
-
w()
|
|
30
|
-
|
|
31
|
-
p.value && i.value != "success" && p.value.click();
|
|
31
|
+
setup(m, { emit: w }) {
|
|
32
|
+
const c = m, z = n(F("filebumpUrl")), p = n(null), o = n(), l = n(""), i = n(""), f = n(), d = w, k = () => {
|
|
33
|
+
o.value && i.value != "success" && o.value.click();
|
|
32
34
|
}, s = {
|
|
33
35
|
DOCUMENT: {
|
|
34
36
|
text: "Документ до 100 МБ",
|
|
@@ -51,21 +53,21 @@ const T = /* @__PURE__ */ I({
|
|
|
51
53
|
error: "Некорректный тип файла, выберите MP4 или MOV",
|
|
52
54
|
icon: "pi pi-video"
|
|
53
55
|
}
|
|
54
|
-
},
|
|
55
|
-
var
|
|
56
|
-
const
|
|
57
|
-
if (
|
|
58
|
-
|
|
59
|
-
const
|
|
60
|
-
if (s[
|
|
61
|
-
|
|
62
|
-
else if (
|
|
63
|
-
|
|
64
|
-
else if (!
|
|
65
|
-
|
|
66
|
-
const
|
|
67
|
-
|
|
68
|
-
i.value = e.status, e.status == "success" && (
|
|
56
|
+
}, I = (a) => {
|
|
57
|
+
var x;
|
|
58
|
+
const t = (x = a.target.files) == null ? void 0 : x[0];
|
|
59
|
+
if (t) {
|
|
60
|
+
l.value = "";
|
|
61
|
+
const y = t.name.split(".");
|
|
62
|
+
if (s[c.type].accept.indexOf(y[y.length - 1]) == -1)
|
|
63
|
+
l.value = s[c.type].error;
|
|
64
|
+
else if (t.size > s[c.type].maxSize)
|
|
65
|
+
l.value = "Файл слишком большого размера";
|
|
66
|
+
else if (!l.value) {
|
|
67
|
+
p.value = t, i.value = "uploading";
|
|
68
|
+
const g = U(z.value);
|
|
69
|
+
N(typeof g == "string" ? g : null, t).then((e) => {
|
|
70
|
+
i.value = e.status, e.status == "success" && (d("fileSelected", {
|
|
69
71
|
url: e.url,
|
|
70
72
|
filename: e.name,
|
|
71
73
|
filesize: e.size,
|
|
@@ -81,24 +83,48 @@ const T = /* @__PURE__ */ I({
|
|
|
81
83
|
});
|
|
82
84
|
}
|
|
83
85
|
}
|
|
84
|
-
},
|
|
85
|
-
|
|
86
|
+
}, C = () => {
|
|
87
|
+
p.value && (p.value = null, i.value = "");
|
|
86
88
|
};
|
|
87
|
-
|
|
89
|
+
return h(
|
|
88
90
|
() => i.value,
|
|
89
|
-
(
|
|
90
|
-
|
|
91
|
+
(a) => {
|
|
92
|
+
a === "" && (o.value && (o.value.value = ""), p.value = null, d("fileSelected", null));
|
|
91
93
|
}
|
|
92
|
-
),
|
|
93
|
-
() =>
|
|
94
|
+
), h(
|
|
95
|
+
() => c.templateId,
|
|
94
96
|
() => {
|
|
95
97
|
i.value = "";
|
|
96
98
|
}
|
|
97
|
-
)
|
|
98
|
-
|
|
99
|
-
|
|
99
|
+
), (a, t) => (u(), v(A, null, [
|
|
100
|
+
i.value !== "success" ? (u(), v("div", {
|
|
101
|
+
key: 0,
|
|
102
|
+
class: P(["attachment-section", { "attachment-section__error": l.value }]),
|
|
103
|
+
onClick: k
|
|
104
|
+
}, [
|
|
105
|
+
r("input", {
|
|
106
|
+
id: "file-upload",
|
|
107
|
+
ref_key: "fileInput",
|
|
108
|
+
ref: o,
|
|
109
|
+
type: "file",
|
|
110
|
+
style: { display: "none" },
|
|
111
|
+
accept: s[m.type].accept,
|
|
112
|
+
onChange: I
|
|
113
|
+
}, null, 40, O),
|
|
114
|
+
t[1] || (t[1] = r("span", { class: "pi pi-paperclip attachment-section__icon" }, null, -1)),
|
|
115
|
+
r("div", null, [
|
|
116
|
+
t[0] || (t[0] = r("p", { class: "attachment-section__title" }, " Прикрепить файл ", -1)),
|
|
117
|
+
r("p", B, _(s[m.type].text), 1)
|
|
118
|
+
])
|
|
119
|
+
], 2)) : i.value === "success" && f.value ? (u(), D(V, {
|
|
120
|
+
key: 1,
|
|
121
|
+
"file-info": f.value,
|
|
122
|
+
onReset: C
|
|
123
|
+
}, null, 8, ["file-info"])) : S("", !0),
|
|
124
|
+
l.value ? (u(), v("div", G, _(l.value), 1)) : S("", !0)
|
|
125
|
+
], 64));
|
|
100
126
|
}
|
|
101
127
|
});
|
|
102
128
|
export {
|
|
103
|
-
|
|
129
|
+
$ as default
|
|
104
130
|
};
|
package/dist/components/2_chatinput_elements/WABAQuickReplyButtons/WABAQuickReplyButtons.vue.js
CHANGED
|
@@ -1,50 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { createElementBlock as s, openBlock as n, Fragment as u, renderList as p, createElementVNode as e, normalizeClass as a, toDisplayString as _ } from "vue";
|
|
1
|
+
import o from "./WABAQuickReplyButtons.vue2.js";
|
|
3
2
|
/* empty css */
|
|
4
|
-
import
|
|
5
|
-
const
|
|
6
|
-
function f(h, l, o, c, v, B) {
|
|
7
|
-
return n(), s("div", k, [
|
|
8
|
-
(n(!0), s(
|
|
9
|
-
u,
|
|
10
|
-
null,
|
|
11
|
-
p(o.buttons.slice(0, 3), (r, t) => (n(), s("div", {
|
|
12
|
-
key: t,
|
|
13
|
-
class: "quick-reply-buttons__preview-action",
|
|
14
|
-
onClick: (b) => c.handleQuickReplyClick(t)
|
|
15
|
-
}, [
|
|
16
|
-
l[0] || (l[0] = e(
|
|
17
|
-
"hr",
|
|
18
|
-
{ class: "quick-reply-buttons__separator" },
|
|
19
|
-
null,
|
|
20
|
-
-1
|
|
21
|
-
/* CACHED */
|
|
22
|
-
)),
|
|
23
|
-
e("div", y, [
|
|
24
|
-
e(
|
|
25
|
-
"span",
|
|
26
|
-
{
|
|
27
|
-
class: a(["quick-reply-buttons__icon pi pi-arrow-up-left", t == 2 && o.buttons.length > 3 ? "pi-list" : c.icons[r.type]])
|
|
28
|
-
},
|
|
29
|
-
null,
|
|
30
|
-
2
|
|
31
|
-
/* CLASS */
|
|
32
|
-
),
|
|
33
|
-
e(
|
|
34
|
-
"p",
|
|
35
|
-
null,
|
|
36
|
-
_(t == 2 && o.buttons.length > 3 ? "Смотреть все варианты" : r.text),
|
|
37
|
-
1
|
|
38
|
-
/* TEXT */
|
|
39
|
-
)
|
|
40
|
-
])
|
|
41
|
-
], 8, m))),
|
|
42
|
-
128
|
|
43
|
-
/* KEYED_FRAGMENT */
|
|
44
|
-
))
|
|
45
|
-
]);
|
|
46
|
-
}
|
|
47
|
-
const Q = /* @__PURE__ */ d(i, [["render", f], ["__scopeId", "data-v-c7dd3663"], ["__file", "/var/store/dev-space/repos-projects/chotto/chotto/src/components/2_chatinput_elements/WABAQuickReplyButtons/WABAQuickReplyButtons.vue"]]);
|
|
3
|
+
import t from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
+
const e = /* @__PURE__ */ t(o, [["__scopeId", "data-v-ce7b10d6"]]);
|
|
48
5
|
export {
|
|
49
|
-
|
|
6
|
+
e as default
|
|
50
7
|
};
|
package/dist/components/2_chatinput_elements/WABAQuickReplyButtons/WABAQuickReplyButtons.vue2.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
const
|
|
1
|
+
import { defineComponent as k, createElementBlock as s, openBlock as l, Fragment as m, renderList as y, createElementVNode as n, normalizeClass as b, toDisplayString as d } from "vue";
|
|
2
|
+
const h = { class: "quick-reply-buttons" }, f = ["onClick"], g = { class: "quick-reply-buttons__line" }, v = /* @__PURE__ */ k({
|
|
3
3
|
__name: "WABAQuickReplyButtons",
|
|
4
4
|
props: {
|
|
5
5
|
buttons: {
|
|
@@ -8,18 +8,31 @@ const u = /* @__PURE__ */ p({
|
|
|
8
8
|
}
|
|
9
9
|
},
|
|
10
10
|
emits: ["selectAllVariants"],
|
|
11
|
-
setup(
|
|
12
|
-
|
|
13
|
-
const e = o, t = s, n = { emit: e, props: t, icons: {
|
|
11
|
+
setup(t, { emit: c }) {
|
|
12
|
+
const u = c, a = t, p = {
|
|
14
13
|
URL: "pi-arrow-up-right",
|
|
15
14
|
PHONE_NUMBER: "pi-phone",
|
|
16
15
|
QUICK_REPLY: "pi-arrow-up-left"
|
|
17
|
-
},
|
|
18
|
-
|
|
19
|
-
}
|
|
20
|
-
return
|
|
16
|
+
}, _ = (o) => {
|
|
17
|
+
o == 2 && a.buttons.length > 3 && u("selectAllVariants");
|
|
18
|
+
};
|
|
19
|
+
return (o, i) => (l(), s("div", h, [
|
|
20
|
+
(l(!0), s(m, null, y(t.buttons.slice(0, 3), (r, e) => (l(), s("div", {
|
|
21
|
+
key: e,
|
|
22
|
+
class: "quick-reply-buttons__preview-action",
|
|
23
|
+
onClick: (C) => _(e)
|
|
24
|
+
}, [
|
|
25
|
+
i[0] || (i[0] = n("hr", { class: "quick-reply-buttons__separator" }, null, -1)),
|
|
26
|
+
n("div", g, [
|
|
27
|
+
n("span", {
|
|
28
|
+
class: b(["quick-reply-buttons__icon pi pi-arrow-up-left", e == 2 && t.buttons.length > 3 ? "pi-list" : p[r.type]])
|
|
29
|
+
}, null, 2),
|
|
30
|
+
n("p", null, d(e == 2 && t.buttons.length > 3 ? "Смотреть все варианты" : r.text), 1)
|
|
31
|
+
])
|
|
32
|
+
], 8, f))), 128))
|
|
33
|
+
]));
|
|
21
34
|
}
|
|
22
35
|
});
|
|
23
36
|
export {
|
|
24
|
-
|
|
37
|
+
v as default
|
|
25
38
|
};
|