@mobilon-dev/chotto 0.3.33 → 0.3.34
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 +2 -2
- package/dist/components/1_atoms/ButtonContextMenu/ButtonContextMenu.vue2.js +28 -27
- package/dist/components/1_atoms/ContextMenu/ContextMenu.vue.js +36 -22
- package/dist/components/1_icons/SettingsIcon.vue.js +6 -6
- package/dist/components/2_blocks/CommunicationPanel/CommunicationPanel.vue.js +164 -156
- package/dist/components/2_chatinput_elements/ButtonEmojiPicker/ButtonEmojiPicker.vue.js +4 -103
- package/dist/components/2_chatinput_elements/ButtonEmojiPicker/ButtonEmojiPicker.vue2.js +135 -0
- package/dist/components/2_chatinput_elements/ButtonEmojiPicker/icons/SmilesIcon.vue.js +33 -11
- package/dist/components/2_chatinput_elements/ButtonEmojiPicker/icons/SmilesIcon.vue2.js +4 -0
- package/dist/components/2_chatinput_elements/ButtonTemplateSelector/ButtonTemplateSelector.vue.js +4 -102
- package/dist/components/2_chatinput_elements/ButtonTemplateSelector/ButtonTemplateSelector.vue2.js +135 -0
- package/dist/components/2_chatinput_elements/ButtonTemplateSelector/icons/ChatTemplatesIcon.vue.js +21 -18
- package/dist/components/2_chatinput_elements/ButtonTemplateSelector/icons/ChatTemplatesIcon.vue2.js +4 -0
- package/dist/components/2_chatinput_elements/FileUploader/FileUploader.vue.js +2 -2
- package/dist/components/2_chatinput_elements/FileUploader/FileUploader.vue2.js +89 -55
- package/dist/components/2_chatinput_elements/FileUploader/icons/FileUploaderIcon.vue.js +17 -14
- package/dist/components/2_chatinput_elements/FileUploader/icons/FileUploaderIcon.vue2.js +4 -0
- package/dist/components/2_chatinput_elements/StickerPicker/StickerPicker.vue.js +4 -337
- package/dist/components/2_chatinput_elements/StickerPicker/StickerPicker.vue2.js +360 -0
- package/dist/components/2_chatinput_elements/StickerPicker/icons/StickerIcon.vue.js +56 -11
- package/dist/components/2_chatinput_elements/StickerPicker/icons/StickerIcon.vue2.js +4 -0
- package/dist/components/2_chatlist_elements/ChatItem/ChatItem.vue.js +2 -2
- package/dist/components/2_chatlist_elements/ChatItem/ChatItem.vue2.js +164 -100
- package/dist/components/2_feed_elements/ImageMessage/ImageMessage.vue.js +1 -1
- package/dist/components/2_feed_elements/ImageMessage/ImageMessage.vue2.js +184 -134
- package/dist/components/2_feed_elements/VideoMessage/VideoMessage.vue.js +3 -3
- package/dist/components/2_feed_elements/VideoMessage/VideoMessage.vue2.js +1 -1
- package/dist/components/3_compounds/ChatList/ChatList.vue.js +101 -91
- package/dist/components/3_compounds/SideBar/SideBar.vue.js +68 -67
- package/dist/hooks/messages/useChannelAccentColor.js +35 -19
- package/dist/themes/dark.css +1 -1
- package/dist/themes/default.css +1 -1
- package/dist/themes/glass.css +1 -0
- package/dist/themes/green.css +1 -1
- package/dist/themes/mobilon1.css +1 -1
- package/dist/types/apps/data/messages.d.ts +117 -86
- package/dist/types/components/1_atoms/ContextMenu/ContextMenu.vue.d.ts +5 -1
- package/dist/types/components/2_blocks/CommunicationPanel/CommunicationPanel.vue.d.ts +2 -0
- package/dist/types/components/2_blocks/CommunicationPanel/stories/CommunicationPanel.stories.d.ts +2 -0
- package/dist/types/components/2_blocks/CommunicationPanel/styles/types.d.ts +4 -0
- package/dist/types/components/2_chatinput_elements/ButtonEmojiPicker/ButtonEmojiPicker.vue.d.ts +31 -7
- package/dist/types/components/2_chatinput_elements/ButtonEmojiPicker/icons/SmilesIcon.vue.d.ts +6 -1
- package/dist/types/components/2_chatinput_elements/ButtonEmojiPicker/styles/types.d.ts +6 -0
- package/dist/types/components/2_chatinput_elements/ButtonTemplateSelector/ButtonTemplateSelector.vue.d.ts +59 -11
- package/dist/types/components/2_chatinput_elements/ButtonTemplateSelector/icons/ChatTemplatesIcon.vue.d.ts +6 -1
- package/dist/types/components/2_chatinput_elements/FileUploader/icons/FileUploaderIcon.vue.d.ts +6 -1
- package/dist/types/components/2_chatinput_elements/StickerPicker/StickerPicker.vue.d.ts +22 -10
- package/dist/types/components/2_chatinput_elements/StickerPicker/icons/StickerIcon.vue.d.ts +6 -1
- package/dist/types/components/2_chatlist_elements/ChatItem/ChatItem.vue.d.ts +2 -0
- package/dist/types/components/2_chatlist_elements/ChatItem/styles/types.d.ts +2 -0
- package/dist/types/components/2_elements/ChatInfo/styles/types.d.ts +2 -0
- package/dist/types/components/2_feed_elements/AudioMessage/styles/types.d.ts +18 -0
- package/dist/types/components/2_feed_elements/CallMessage/styles/types.d.ts +24 -0
- package/dist/types/components/2_feed_elements/DateMessage/styles/types.d.ts +6 -0
- package/dist/types/components/2_feed_elements/DateMessageSticky/styles/types.d.ts +4 -0
- package/dist/types/components/2_feed_elements/FeedKeyboard/styles/types.d.ts +2 -0
- package/dist/types/components/2_feed_elements/FileMessage/styles/types.d.ts +12 -0
- package/dist/types/components/2_feed_elements/ImageMessage/styles/types.d.ts +126 -0
- package/dist/types/components/2_feed_elements/MessageReactions/styles/types.d.ts +8 -0
- package/dist/types/components/2_feed_elements/TextMessage/styles/types.d.ts +16 -0
- package/dist/types/components/3_compounds/ChatInput/styles/types.d.ts +2 -0
- package/dist/types/components/3_compounds/ChatList/ChatList.vue.d.ts +2 -0
- package/dist/types/components/3_compounds/ChatList/styles/types.d.ts +8 -0
- package/dist/types/components/3_compounds/SideBar/styles/types.d.ts +6 -16
- package/dist/types/components/4_layouts/ChatWrapper/styles/types.d.ts +4 -0
- package/dist/types/components/4_layouts/ExtendedLayout/styles/types.d.ts +8 -0
- package/package.json +2 -1
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { ref as
|
|
2
|
-
import
|
|
3
|
-
import { useCommunicationChannels as
|
|
4
|
-
import { useCommunicationMenu as
|
|
1
|
+
import { ref as m, computed as p, watch as Re, onMounted as Ee, onUnmounted as xe, createElementBlock as l, openBlock as o, createElementVNode as a, createCommentVNode as r, Fragment as E, renderList as q, unref as e, normalizeClass as c, createBlock as d, createVNode as Se, withCtx as H, resolveDynamicComponent as v, normalizeStyle as te, toDisplayString as f } from "vue";
|
|
2
|
+
import F from "../../1_atoms/Tooltip/Tooltip.vue.js";
|
|
3
|
+
import { useCommunicationChannels as ze } from "./composables/useCommunicationChannels.js";
|
|
4
|
+
import { useCommunicationMenu as _e } from "./composables/useCommunicationMenu.js";
|
|
5
5
|
import { useCommunicationAttributes as Le } from "./composables/useCommunicationAttributes.js";
|
|
6
6
|
import { useCommunicationActions as De } from "./composables/useCommunicationActions.js";
|
|
7
7
|
import { useCommunicationSubMenu as $e } from "./composables/useCommunicationSubMenu.js";
|
|
8
|
-
import { useCommunicationDialogSync as
|
|
8
|
+
import { useCommunicationDialogSync as qe } from "./composables/useCommunicationDialogSync.js";
|
|
9
9
|
/* empty css */
|
|
10
|
-
import
|
|
11
|
-
const Fe = ["onClick", "onMouseenter"], Oe = { class: "channel-icon" },
|
|
10
|
+
import He from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
11
|
+
const Fe = ["onClick", "onMouseenter"], Oe = { class: "channel-icon" }, Be = { class: "channel-icon" }, Pe = { class: "menu-header" }, je = { class: "attribute-info" }, Ne = { class: "attribute-value" }, Ve = { class: "attribute-info" }, We = { class: "attribute-value" }, Ue = {
|
|
12
12
|
key: 2,
|
|
13
13
|
class: "menu-divider"
|
|
14
14
|
}, Ge = ["onMouseenter", "onClick"], Je = { class: "attribute-info" }, Ke = { class: "attribute-value" }, Qe = { class: "menu-icon" }, Xe = {
|
|
@@ -41,157 +41,162 @@ const Fe = ["onClick", "onMouseenter"], Oe = { class: "channel-icon" }, Pe = { c
|
|
|
41
41
|
type: Object,
|
|
42
42
|
required: !1,
|
|
43
43
|
default: () => ({})
|
|
44
|
+
},
|
|
45
|
+
showChannelIcons: {
|
|
46
|
+
type: Boolean,
|
|
47
|
+
required: !1,
|
|
48
|
+
default: !1
|
|
44
49
|
}
|
|
45
50
|
},
|
|
46
51
|
emits: ["select-attribute-channel", "phone-call"],
|
|
47
|
-
setup(
|
|
48
|
-
const
|
|
52
|
+
setup(h, { emit: ne }) {
|
|
53
|
+
const u = h, oe = ne, y = m(null), O = m(null), x = m(null), S = m(null), b = m(!1), M = m(null), z = m({}), _ = p(() => u.channels ?? []), se = p(() => u.channelTooltips ?? {}), {
|
|
49
54
|
channelsTypes: le,
|
|
50
55
|
getTooltipText: ie,
|
|
51
|
-
getChannelTypeFromId:
|
|
52
|
-
hasMultipleChannels:
|
|
53
|
-
isChannelActive:
|
|
54
|
-
getSingleChannelForType:
|
|
55
|
-
getMenuChannelIconComponent:
|
|
56
|
+
getChannelTypeFromId: ae,
|
|
57
|
+
hasMultipleChannels: A,
|
|
58
|
+
isChannelActive: k,
|
|
59
|
+
getSingleChannelForType: ue,
|
|
60
|
+
getMenuChannelIconComponent: B,
|
|
56
61
|
getMenuChannelIconComponentForChannelId: re,
|
|
57
62
|
getSingleMenuChannelIconComponent: ce,
|
|
58
63
|
getAvailableChannels: de
|
|
59
|
-
} =
|
|
60
|
-
channels:
|
|
64
|
+
} = ze({
|
|
65
|
+
channels: _,
|
|
61
66
|
channelTooltips: se,
|
|
62
|
-
selectedChannelType:
|
|
67
|
+
selectedChannelType: M
|
|
63
68
|
}), {
|
|
64
69
|
activeChannelType: s,
|
|
65
|
-
hoveredChannel:
|
|
70
|
+
hoveredChannel: g,
|
|
66
71
|
showMenu: me,
|
|
67
|
-
showSubMenu:
|
|
72
|
+
showSubMenu: L,
|
|
68
73
|
menuWidth: pe,
|
|
69
|
-
updateMenuWidth:
|
|
74
|
+
updateMenuWidth: D,
|
|
70
75
|
handleChannelClick: ve,
|
|
71
|
-
closeMenu:
|
|
76
|
+
closeMenu: he,
|
|
72
77
|
handleClickOutside: P
|
|
73
|
-
} =
|
|
74
|
-
panelRef:
|
|
75
|
-
channelsPanelRef:
|
|
76
|
-
selectedChannelType:
|
|
77
|
-
frozenAttribute:
|
|
78
|
-
isRecentAttributeHovered:
|
|
79
|
-
}),
|
|
80
|
-
organizedContactAttributes:
|
|
81
|
-
organizeContactAttributes:
|
|
82
|
-
recentAttribute:
|
|
83
|
-
showRecentAttribute:
|
|
84
|
-
isAttributeFrozen:
|
|
78
|
+
} = _e({
|
|
79
|
+
panelRef: y,
|
|
80
|
+
channelsPanelRef: O,
|
|
81
|
+
selectedChannelType: M,
|
|
82
|
+
frozenAttribute: S,
|
|
83
|
+
isRecentAttributeHovered: b
|
|
84
|
+
}), be = p(() => u.contactAttributes ?? []), j = p(() => u.recentAttributeChannels ?? {}), {
|
|
85
|
+
organizedContactAttributes: N,
|
|
86
|
+
organizeContactAttributes: Ce,
|
|
87
|
+
recentAttribute: T,
|
|
88
|
+
showRecentAttribute: $,
|
|
89
|
+
isAttributeFrozen: fe
|
|
85
90
|
} = Le({
|
|
86
|
-
contactAttributes:
|
|
91
|
+
contactAttributes: be,
|
|
87
92
|
recentAttributeChannels: j,
|
|
88
93
|
activeChannelType: s,
|
|
89
|
-
frozenAttribute:
|
|
94
|
+
frozenAttribute: S
|
|
90
95
|
}), {
|
|
91
|
-
handleRecentAttributeClick:
|
|
96
|
+
handleRecentAttributeClick: V,
|
|
92
97
|
handleAttributeClick: ye,
|
|
93
98
|
selectChannel: Me,
|
|
94
99
|
availableChannels: Ae
|
|
95
100
|
} = De({
|
|
96
101
|
activeChannelType: s,
|
|
97
|
-
channels:
|
|
102
|
+
channels: _,
|
|
98
103
|
recentAttributeChannels: j,
|
|
99
|
-
selectedChannel:
|
|
100
|
-
selectedChannelType:
|
|
101
|
-
isRecentAttributeHovered:
|
|
102
|
-
hoveredAttribute:
|
|
103
|
-
closeMenu:
|
|
104
|
-
hasMultipleChannels:
|
|
105
|
-
getSingleChannelForType:
|
|
104
|
+
selectedChannel: z,
|
|
105
|
+
selectedChannelType: M,
|
|
106
|
+
isRecentAttributeHovered: b,
|
|
107
|
+
hoveredAttribute: x,
|
|
108
|
+
closeMenu: he,
|
|
109
|
+
hasMultipleChannels: A,
|
|
110
|
+
getSingleChannelForType: ue,
|
|
106
111
|
getAvailableChannels: de,
|
|
107
112
|
emit: oe
|
|
108
113
|
}), {
|
|
109
114
|
subMenuTop: ke,
|
|
110
|
-
resetRegularAttributeHover:
|
|
115
|
+
resetRegularAttributeHover: w,
|
|
111
116
|
handleRecentAttributeMouseEnter: ge,
|
|
112
|
-
handleRecentAttributeMouseLeave:
|
|
113
|
-
handleAttributeMouseEnter:
|
|
114
|
-
handleAttributeMouseLeave:
|
|
115
|
-
keepSubMenuOpen:
|
|
116
|
-
closeSubMenu:
|
|
117
|
-
alignSubMenuWithTarget:
|
|
117
|
+
handleRecentAttributeMouseLeave: I,
|
|
118
|
+
handleAttributeMouseEnter: Te,
|
|
119
|
+
handleAttributeMouseLeave: W,
|
|
120
|
+
keepSubMenuOpen: U,
|
|
121
|
+
closeSubMenu: G,
|
|
122
|
+
alignSubMenuWithTarget: J
|
|
118
123
|
} = $e({
|
|
119
124
|
activeChannelType: s,
|
|
120
|
-
showSubMenu:
|
|
121
|
-
frozenAttribute:
|
|
122
|
-
hoveredAttribute:
|
|
123
|
-
isRecentAttributeHovered:
|
|
124
|
-
hasMultipleChannels:
|
|
125
|
+
showSubMenu: L,
|
|
126
|
+
frozenAttribute: S,
|
|
127
|
+
hoveredAttribute: x,
|
|
128
|
+
isRecentAttributeHovered: b,
|
|
129
|
+
hasMultipleChannels: A
|
|
125
130
|
});
|
|
126
|
-
|
|
127
|
-
selectedChannelType:
|
|
128
|
-
selectedChannel:
|
|
129
|
-
channels:
|
|
130
|
-
selectedDialog:
|
|
131
|
+
qe({
|
|
132
|
+
selectedChannelType: M,
|
|
133
|
+
selectedChannel: z,
|
|
134
|
+
channels: _,
|
|
135
|
+
selectedDialog: p(() => u.selectedDialog ?? null)
|
|
131
136
|
});
|
|
132
|
-
const
|
|
137
|
+
const K = p(
|
|
133
138
|
() => Ae()
|
|
134
|
-
),
|
|
135
|
-
() =>
|
|
136
|
-
),
|
|
137
|
-
const n = ge(
|
|
138
|
-
n instanceof HTMLElement &&
|
|
139
|
-
},
|
|
140
|
-
const
|
|
141
|
-
|
|
139
|
+
), we = p(
|
|
140
|
+
() => L.value && x.value && K.value.length > 0 && s.value !== "phone" && A(s.value)
|
|
141
|
+
), Q = (R) => {
|
|
142
|
+
const n = ge(R.currentTarget);
|
|
143
|
+
n instanceof HTMLElement && J(y, n);
|
|
144
|
+
}, Ie = (R, n) => {
|
|
145
|
+
const C = Te(R, n.currentTarget);
|
|
146
|
+
C instanceof HTMLElement && J(y, C);
|
|
142
147
|
};
|
|
143
|
-
return
|
|
144
|
-
}, { deep: !0 }),
|
|
145
|
-
|
|
148
|
+
return Re(() => u.selectedDialog, () => {
|
|
149
|
+
}, { deep: !0 }), Ee(() => {
|
|
150
|
+
D(), window.addEventListener("resize", D), document.addEventListener("click", P), Ce();
|
|
146
151
|
}), xe(() => {
|
|
147
|
-
window.removeEventListener("resize",
|
|
148
|
-
}), (
|
|
149
|
-
var
|
|
150
|
-
return o(),
|
|
152
|
+
window.removeEventListener("resize", D), document.removeEventListener("click", P);
|
|
153
|
+
}), (R, n) => {
|
|
154
|
+
var C, X, Y, Z;
|
|
155
|
+
return o(), l("div", {
|
|
151
156
|
ref_key: "panelRef",
|
|
152
|
-
ref:
|
|
157
|
+
ref: y,
|
|
153
158
|
class: "communication-panel"
|
|
154
159
|
}, [
|
|
155
|
-
|
|
160
|
+
a("div", {
|
|
156
161
|
ref_key: "channelsPanelRef",
|
|
157
|
-
ref:
|
|
162
|
+
ref: O,
|
|
158
163
|
class: "channels-panel"
|
|
159
164
|
}, [
|
|
160
|
-
(o(!0),
|
|
165
|
+
(o(!0), l(E, null, q(e(le), (t) => {
|
|
161
166
|
var i;
|
|
162
|
-
return o(),
|
|
167
|
+
return o(), l("button", {
|
|
163
168
|
key: t.type,
|
|
164
|
-
class:
|
|
165
|
-
active: e(
|
|
166
|
-
hover: e(
|
|
169
|
+
class: c(["channel-btn", {
|
|
170
|
+
active: e(k)(t.type),
|
|
171
|
+
hover: e(g) === t.type && !e(k)(t.type) || e(g) === t.type && e(k)(t.type)
|
|
167
172
|
}]),
|
|
168
|
-
onClick: (
|
|
169
|
-
onMouseenter: (
|
|
170
|
-
onMouseleave: n[0] || (n[0] = (
|
|
173
|
+
onClick: (ee) => e(ve)(t.type),
|
|
174
|
+
onMouseenter: (ee) => g.value = t.type,
|
|
175
|
+
onMouseleave: n[0] || (n[0] = (ee) => g.value = null)
|
|
171
176
|
}, [
|
|
172
|
-
e(
|
|
173
|
-
|
|
174
|
-
text: (i =
|
|
177
|
+
e(k)(t.type) ? (o(), l(E, { key: 0 }, [
|
|
178
|
+
Se(F, {
|
|
179
|
+
text: (i = z.value) == null ? void 0 : i.title,
|
|
175
180
|
position: "bottom",
|
|
176
181
|
offset: 8
|
|
177
182
|
}, {
|
|
178
183
|
default: H(() => [
|
|
179
|
-
|
|
180
|
-
(o(),
|
|
184
|
+
a("span", Oe, [
|
|
185
|
+
(o(), d(v(t.component)))
|
|
181
186
|
])
|
|
182
187
|
]),
|
|
183
188
|
_: 2
|
|
184
189
|
}, 1032, ["text"]),
|
|
185
|
-
n[12] || (n[12] =
|
|
186
|
-
], 64)) : (o(),
|
|
190
|
+
n[12] || (n[12] = a("span", { class: "active-indicator" }, null, -1))
|
|
191
|
+
], 64)) : (o(), d(F, {
|
|
187
192
|
key: 1,
|
|
188
193
|
text: e(ie)(t.type),
|
|
189
194
|
position: "bottom",
|
|
190
195
|
offset: 8
|
|
191
196
|
}, {
|
|
192
197
|
default: H(() => [
|
|
193
|
-
|
|
194
|
-
(o(),
|
|
198
|
+
a("span", Be, [
|
|
199
|
+
(o(), d(v(t.component)))
|
|
195
200
|
])
|
|
196
201
|
]),
|
|
197
202
|
_: 2
|
|
@@ -199,109 +204,112 @@ const Fe = ["onClick", "onMouseenter"], Oe = { class: "channel-icon" }, Pe = { c
|
|
|
199
204
|
], 42, Fe);
|
|
200
205
|
}), 128))
|
|
201
206
|
], 512),
|
|
202
|
-
e(me) && e(s) ? (o(),
|
|
207
|
+
e(me) && e(s) ? (o(), l("div", {
|
|
203
208
|
key: 0,
|
|
204
209
|
class: "attributes-menu",
|
|
205
|
-
style:
|
|
210
|
+
style: te({ width: e(pe) })
|
|
206
211
|
}, [
|
|
207
|
-
|
|
208
|
-
e(
|
|
212
|
+
a("div", Pe, f(e(s) === "phone" ? "Телефон" : "Недавний"), 1),
|
|
213
|
+
e($) && ((C = u.recentAttributeChannels[e(s)]) != null && C.tooltip) ? (o(), d(F, {
|
|
209
214
|
key: 0,
|
|
210
|
-
text: (
|
|
215
|
+
text: (X = u.recentAttributeChannels[e(s)]) == null ? void 0 : X.tooltip,
|
|
211
216
|
position: "bottom",
|
|
212
217
|
offset: 8
|
|
213
218
|
}, {
|
|
214
219
|
default: H(() => {
|
|
215
220
|
var t;
|
|
216
221
|
return [
|
|
217
|
-
|
|
218
|
-
class:
|
|
219
|
-
"frozen-hover":
|
|
222
|
+
a("div", {
|
|
223
|
+
class: c(["recent-attribute", {
|
|
224
|
+
"frozen-hover": b.value
|
|
220
225
|
}]),
|
|
221
|
-
onMouseenter: n[1] || (n[1] = (i) =>
|
|
222
|
-
onMouseleave: n[2] || (n[2] = (...i) => e(
|
|
223
|
-
onMouseover: n[3] || (n[3] = (...i) => e(
|
|
224
|
-
onClick: n[4] || (n[4] = (i) => e(
|
|
226
|
+
onMouseenter: n[1] || (n[1] = (i) => Q(i)),
|
|
227
|
+
onMouseleave: n[2] || (n[2] = (...i) => e(I) && e(I)(...i)),
|
|
228
|
+
onMouseover: n[3] || (n[3] = (...i) => e(w) && e(w)(...i)),
|
|
229
|
+
onClick: n[4] || (n[4] = (i) => e(V)(e(T)))
|
|
225
230
|
}, [
|
|
226
|
-
|
|
227
|
-
|
|
231
|
+
a("div", je, [
|
|
232
|
+
a("span", Ne, f((t = e(T)) == null ? void 0 : t.value), 1)
|
|
228
233
|
]),
|
|
229
|
-
l("span", {
|
|
230
|
-
|
|
234
|
+
h.showChannelIcons ? (o(), l("span", {
|
|
235
|
+
key: 0,
|
|
236
|
+
class: c(["channel-icon-small", { "menu-icon-grey": e(s) !== "sms" }])
|
|
231
237
|
}, [
|
|
232
|
-
(o(),
|
|
233
|
-
], 2)
|
|
238
|
+
(o(), d(v(e(B)(e(s)))))
|
|
239
|
+
], 2)) : r("", !0)
|
|
234
240
|
], 34)
|
|
235
241
|
];
|
|
236
242
|
}),
|
|
237
243
|
_: 1
|
|
238
|
-
}, 8, ["text"])) : e(
|
|
244
|
+
}, 8, ["text"])) : e($) ? (o(), l("div", {
|
|
239
245
|
key: 1,
|
|
240
|
-
class:
|
|
241
|
-
"frozen-hover":
|
|
246
|
+
class: c(["recent-attribute", {
|
|
247
|
+
"frozen-hover": b.value
|
|
242
248
|
}]),
|
|
243
|
-
onMouseenter: n[5] || (n[5] = (t) =>
|
|
244
|
-
onMouseleave: n[6] || (n[6] = (...t) => e(
|
|
245
|
-
onMouseover: n[7] || (n[7] = (...t) => e(
|
|
246
|
-
onClick: n[8] || (n[8] = (t) => e(
|
|
249
|
+
onMouseenter: n[5] || (n[5] = (t) => Q(t)),
|
|
250
|
+
onMouseleave: n[6] || (n[6] = (...t) => e(I) && e(I)(...t)),
|
|
251
|
+
onMouseover: n[7] || (n[7] = (...t) => e(w) && e(w)(...t)),
|
|
252
|
+
onClick: n[8] || (n[8] = (t) => e(V)(e(T)))
|
|
247
253
|
}, [
|
|
248
|
-
|
|
249
|
-
|
|
254
|
+
a("div", Ve, [
|
|
255
|
+
a("span", We, f((Y = e(T)) == null ? void 0 : Y.value), 1)
|
|
250
256
|
]),
|
|
251
|
-
l("span", {
|
|
252
|
-
|
|
257
|
+
h.showChannelIcons ? (o(), l("span", {
|
|
258
|
+
key: 0,
|
|
259
|
+
class: c(["channel-icon-small", { "menu-icon-grey": e(s) !== "sms" }])
|
|
253
260
|
}, [
|
|
254
|
-
(o(),
|
|
255
|
-
], 2)
|
|
256
|
-
], 34)) :
|
|
257
|
-
e(
|
|
258
|
-
(o(!0),
|
|
261
|
+
(o(), d(v(e(B)(e(s)))))
|
|
262
|
+
], 2)) : r("", !0)
|
|
263
|
+
], 34)) : r("", !0),
|
|
264
|
+
e($) && ((Z = e(N)[e(s)]) != null && Z.length) && e(s) !== "phone" ? (o(), l("div", Ue)) : r("", !0),
|
|
265
|
+
(o(!0), l(E, null, q(e(N)[e(s)], (t) => (o(), l("div", {
|
|
259
266
|
key: t.attributeId,
|
|
260
|
-
class:
|
|
261
|
-
"frozen-hover": e(
|
|
267
|
+
class: c(["attribute-item", {
|
|
268
|
+
"frozen-hover": e(fe)(t)
|
|
262
269
|
}]),
|
|
263
|
-
onMouseenter: (i) =>
|
|
264
|
-
onMouseleave: n[9] || (n[9] = (...i) => e(
|
|
270
|
+
onMouseenter: (i) => Ie(t, i),
|
|
271
|
+
onMouseleave: n[9] || (n[9] = (...i) => e(W) && e(W)(...i)),
|
|
265
272
|
onClick: (i) => e(ye)(t)
|
|
266
273
|
}, [
|
|
267
|
-
|
|
268
|
-
|
|
274
|
+
a("div", Je, [
|
|
275
|
+
a("span", Ke, f(t.value), 1)
|
|
269
276
|
]),
|
|
270
|
-
|
|
271
|
-
e(
|
|
277
|
+
a("span", Qe, [
|
|
278
|
+
e(A)(e(s)) ? (o(), l("span", Xe)) : h.showChannelIcons ? (o(), l("span", {
|
|
272
279
|
key: 1,
|
|
273
|
-
class:
|
|
280
|
+
class: c(["channel-icon-small", { "menu-icon-grey": e(s) !== "sms" }])
|
|
274
281
|
}, [
|
|
275
|
-
(o(),
|
|
276
|
-
], 2))
|
|
282
|
+
(o(), d(v(e(ce)(e(s)))))
|
|
283
|
+
], 2)) : r("", !0)
|
|
277
284
|
])
|
|
278
285
|
], 42, Ge))), 128)),
|
|
279
|
-
e(
|
|
286
|
+
e(L) && we.value ? (o(), l("div", {
|
|
280
287
|
key: 3,
|
|
281
288
|
class: "sub-menu left",
|
|
282
|
-
style:
|
|
283
|
-
onMouseenter: n[10] || (n[10] = (...t) => e(
|
|
284
|
-
onMouseleave: n[11] || (n[11] = (...t) => e(
|
|
289
|
+
style: te({ top: e(ke) + "px" }),
|
|
290
|
+
onMouseenter: n[10] || (n[10] = (...t) => e(U) && e(U)(...t)),
|
|
291
|
+
onMouseleave: n[11] || (n[11] = (...t) => e(G) && e(G)(...t))
|
|
285
292
|
}, [
|
|
286
|
-
n[13] || (n[13] =
|
|
287
|
-
(o(!0),
|
|
293
|
+
n[13] || (n[13] = a("div", { class: "sub-menu-header" }, " Канал связи ", -1)),
|
|
294
|
+
(o(!0), l(E, null, q(K.value, (t) => (o(), l("div", {
|
|
288
295
|
key: t.channelId,
|
|
289
296
|
class: "sub-menu-item",
|
|
290
297
|
onClick: (i) => e(Me)(t.channelId)
|
|
291
298
|
}, [
|
|
292
|
-
|
|
293
|
-
l("span", {
|
|
294
|
-
|
|
299
|
+
a("span", Ze, f(t.title || t.channelId), 1),
|
|
300
|
+
h.showChannelIcons ? (o(), l("span", {
|
|
301
|
+
key: 0,
|
|
302
|
+
class: c(["sub-menu-icon", { "menu-icon-grey": e(ae)(t.channelId) !== "sms" }])
|
|
295
303
|
}, [
|
|
296
|
-
(o(),
|
|
297
|
-
], 2)
|
|
304
|
+
(o(), d(v(e(re)(t.channelId))))
|
|
305
|
+
], 2)) : r("", !0)
|
|
298
306
|
], 8, Ye))), 128))
|
|
299
|
-
], 36)) :
|
|
300
|
-
], 4)) :
|
|
307
|
+
], 36)) : r("", !0)
|
|
308
|
+
], 4)) : r("", !0)
|
|
301
309
|
], 512);
|
|
302
310
|
};
|
|
303
311
|
}
|
|
304
|
-
}, dt = /* @__PURE__ */
|
|
312
|
+
}, dt = /* @__PURE__ */ He(et, [["__scopeId", "data-v-06f38e2d"]]);
|
|
305
313
|
export {
|
|
306
314
|
dt as default
|
|
307
315
|
};
|
|
@@ -1,106 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
import z from "../../../node_modules/vue3-emoji-picker-ru/dist/emoji-picker.es.js";
|
|
3
|
-
/* empty css */
|
|
4
|
-
import { useMessageDraft as F } from "../../../hooks/useMessageDraft.js";
|
|
5
|
-
import "../../../hooks/useSearchModel.js";
|
|
6
|
-
import "../../../hooks/useTheme.js";
|
|
7
|
-
/* empty css */
|
|
8
|
-
import R from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
9
|
-
/* empty css */
|
|
10
|
-
import "../../../node_modules/linkifyjs/dist/linkify.js";
|
|
11
|
-
import "../../../functions/parseMarkdown.js";
|
|
12
|
-
import U from "./icons/SmilesIcon.vue.js";
|
|
1
|
+
import o from "./ButtonEmojiPicker.vue2.js";
|
|
13
2
|
/* empty css */
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
props: {
|
|
17
|
-
state: {
|
|
18
|
-
type: String,
|
|
19
|
-
default: "active"
|
|
20
|
-
},
|
|
21
|
-
mode: {
|
|
22
|
-
type: String,
|
|
23
|
-
default: "click",
|
|
24
|
-
// или 'hover'
|
|
25
|
-
validator: (i) => ["click", "hover"].includes(i)
|
|
26
|
-
},
|
|
27
|
-
native: {
|
|
28
|
-
type: Boolean,
|
|
29
|
-
default: !0
|
|
30
|
-
}
|
|
31
|
-
},
|
|
32
|
-
setup(i) {
|
|
33
|
-
const t = i, c = r(null), l = r(null), o = r(!1), v = r("light"), f = S("chatAppId"), { setMessageText: E, getMessage: p } = F(f);
|
|
34
|
-
let n = !1, a = !1;
|
|
35
|
-
const b = () => {
|
|
36
|
-
var u;
|
|
37
|
-
const e = document.getElementById(f);
|
|
38
|
-
return (u = e == null ? void 0 : e.getAttribute("data-theme")) != null && u.includes("dark") ? "dark" : "light";
|
|
39
|
-
}, B = (e) => {
|
|
40
|
-
E(p().text + e.i), t.mode === "click" && (o.value = !1);
|
|
41
|
-
}, k = () => {
|
|
42
|
-
t.state === "active" && (v.value = b(), o.value = !0);
|
|
43
|
-
}, s = () => {
|
|
44
|
-
o.value = !1;
|
|
45
|
-
}, P = () => {
|
|
46
|
-
t.mode === "click" && (o.value = !o.value, o.value && k());
|
|
47
|
-
}, _ = () => {
|
|
48
|
-
t.mode === "hover" && (n = !0, k());
|
|
49
|
-
}, y = () => {
|
|
50
|
-
t.mode === "hover" && (n = !1, setTimeout(() => {
|
|
51
|
-
!a && !n && s();
|
|
52
|
-
}, 150));
|
|
53
|
-
}, x = () => {
|
|
54
|
-
t.mode === "hover" && (a = !0);
|
|
55
|
-
}, C = () => {
|
|
56
|
-
t.mode === "hover" && (a = !1, setTimeout(() => {
|
|
57
|
-
!n && !a && s();
|
|
58
|
-
}, 150));
|
|
59
|
-
}, h = (e) => {
|
|
60
|
-
t.mode === "click" && o.value && l.value && c.value && !l.value.contains(e.target) && !c.value.contains(e.target) && s();
|
|
61
|
-
};
|
|
62
|
-
return T(() => {
|
|
63
|
-
document.addEventListener("click", h);
|
|
64
|
-
}), I(() => {
|
|
65
|
-
document.removeEventListener("click", h);
|
|
66
|
-
}), (e, u) => (M(), g(L, null, [
|
|
67
|
-
d(p)().isRecording ? V("", !0) : (M(), g("button", {
|
|
68
|
-
key: 0,
|
|
69
|
-
ref_key: "emojiButton",
|
|
70
|
-
ref: l,
|
|
71
|
-
class: w(["button", { "button-disabled": i.state === "disabled" }]),
|
|
72
|
-
onClick: P,
|
|
73
|
-
onMouseenter: _,
|
|
74
|
-
onMouseleave: y
|
|
75
|
-
}, [
|
|
76
|
-
j("span", null, [
|
|
77
|
-
m(d(U))
|
|
78
|
-
])
|
|
79
|
-
], 34)),
|
|
80
|
-
m(A, null, {
|
|
81
|
-
default: D(() => [
|
|
82
|
-
N(j("div", {
|
|
83
|
-
ref_key: "emoji",
|
|
84
|
-
ref: c,
|
|
85
|
-
class: "emoji",
|
|
86
|
-
onMouseenter: x,
|
|
87
|
-
onMouseleave: C
|
|
88
|
-
}, [
|
|
89
|
-
m(d(z), {
|
|
90
|
-
native: i.native,
|
|
91
|
-
theme: v.value,
|
|
92
|
-
"picker-type": "",
|
|
93
|
-
onSelect: B
|
|
94
|
-
}, null, 8, ["native", "theme"])
|
|
95
|
-
], 544), [
|
|
96
|
-
[O, o.value]
|
|
97
|
-
])
|
|
98
|
-
]),
|
|
99
|
-
_: 1
|
|
100
|
-
})
|
|
101
|
-
], 64));
|
|
102
|
-
}
|
|
103
|
-
}, ie = /* @__PURE__ */ R(q, [["__scopeId", "data-v-5bb0871b"]]);
|
|
3
|
+
import t from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
+
const e = /* @__PURE__ */ t(o, [["__scopeId", "data-v-bce30537"]]);
|
|
104
5
|
export {
|
|
105
|
-
|
|
6
|
+
e as default
|
|
106
7
|
};
|