@mobilon-dev/chotto 0.3.127 → 0.3.129
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/3_compounds/Feed/Feed.vue.js +2 -2
- package/dist/components/3_compounds/Feed/Feed.vue2.js +228 -218
- package/dist/components/3_compounds/Feed/composables/useFeedLoadMore.js +28 -23
- package/dist/components/3_compounds/Feed/composables/useFeedTopSpacer.js +45 -0
- package/dist/types/src/components/3_compounds/Feed/composables/index.d.ts +1 -0
- package/dist/types/src/components/3_compounds/Feed/composables/useFeedLoadMore.d.ts +3 -1
- package/dist/types/src/components/3_compounds/Feed/composables/useFeedTopSpacer.d.ts +16 -0
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./Feed.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import t from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const
|
|
4
|
+
const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-92226131"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
p as default
|
|
7
7
|
};
|
|
@@ -1,36 +1,37 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import { useFeedButton as
|
|
11
|
-
import { useFeedComponents as
|
|
12
|
-
import { useFeedGrouping as
|
|
13
|
-
import { useFeedKeyboard as
|
|
14
|
-
import { useFeedLoadMore as
|
|
15
|
-
import { useFeedMessageVisibility as
|
|
16
|
-
import { useFeedProgressiveRender as
|
|
17
|
-
import { provideFeedReactionsOverlay as
|
|
18
|
-
import { useFeedReply as
|
|
19
|
-
import { useFeedScroll as
|
|
20
|
-
import { useFeedScrollTo as
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
1
|
+
import { defineComponent as Oe, ref as A, computed as i, provide as B, inject as Q, unref as t, watch as T, nextTick as F, onMounted as $e, createElementBlock as y, openBlock as l, createVNode as p, createBlock as f, createCommentVNode as u, normalizeStyle as C, renderSlot as X, createElementVNode as I, withDirectives as je, vShow as Le, Transition as D, withCtx as w, Fragment as Ne, renderList as Pe, isMemoSame as Ue, resolveDynamicComponent as qe, mergeProps as Ee, toDisplayString as Ve, Teleport as Y } from "vue";
|
|
2
|
+
import We from "../../2_feed_elements/DateMessageSticky/DateMessageSticky.vue.js";
|
|
3
|
+
import ze from "../../2_feed_elements/BaseReplyMessage/BaseReplyMessage.vue.js";
|
|
4
|
+
import Ge from "../../2_feed_elements/BaseEditMessage/BaseEditMessage.vue.js";
|
|
5
|
+
import He from "../../2_feed_elements/MessageKeyboard/MessageKeyboard.vue.js";
|
|
6
|
+
import Je from "../../2_feed_elements/FeedKeyboard/FeedKeyboard.vue.js";
|
|
7
|
+
import Qe from "../../2_feed_elements/TypingMessage/TypingMessage.vue.js";
|
|
8
|
+
import Xe from "../../1_atoms/LoadingIndicator/LoadingIndicator.vue.js";
|
|
9
|
+
import Ye from "../../2_feed_elements/MessageReactions/MessageReactionsOverlay.vue.js";
|
|
10
|
+
import { useFeedButton as Ze } from "./composables/useFeedButton.js";
|
|
11
|
+
import { useFeedComponents as _e } from "./composables/useFeedComponents.js";
|
|
12
|
+
import { useFeedGrouping as et } from "./composables/useFeedGrouping.js";
|
|
13
|
+
import { useFeedKeyboard as tt } from "./composables/useFeedKeyboard.js";
|
|
14
|
+
import { useFeedLoadMore as st } from "./composables/useFeedLoadMore.js";
|
|
15
|
+
import { useFeedMessageVisibility as ot } from "./composables/useFeedMessageVisibility.js";
|
|
16
|
+
import { useFeedProgressiveRender as at } from "./composables/useFeedProgressiveRender.js";
|
|
17
|
+
import { provideFeedReactionsOverlay as nt } from "./composables/useFeedReactionsOverlay.js";
|
|
18
|
+
import { useFeedReply as rt } from "./composables/useFeedReply.js";
|
|
19
|
+
import { useFeedScroll as it } from "./composables/useFeedScroll.js";
|
|
20
|
+
import { useFeedScrollTo as lt } from "./composables/useFeedScrollTo.js";
|
|
21
|
+
import { useFeedTopSpacer as dt } from "./composables/useFeedTopSpacer.js";
|
|
22
|
+
import { useStickyDate as ct } from "./composables/useStickyDate.js";
|
|
23
|
+
import { throttle as ut } from "./functions/throttle.js";
|
|
24
|
+
import { getDefaultMessageMenuActions as mt } from "./utils/getDefaultMessageMenuActions.js";
|
|
25
|
+
import { isSmsFeedMessage as ft } from "../../../functions/isSmsChannel.js";
|
|
25
26
|
import "../../../functions/parseMarkdown.js";
|
|
26
|
-
import
|
|
27
|
-
const
|
|
27
|
+
import gt from "./assets/chat-background.svg.js";
|
|
28
|
+
const yt = {
|
|
28
29
|
class: "message-feed-wrapper",
|
|
29
30
|
"data-testid": "feed"
|
|
30
|
-
},
|
|
31
|
+
}, pt = ["id"], bt = { class: "message-feed__loading" }, kt = { style: { margin: "auto" } }, ht = {
|
|
31
32
|
key: 0,
|
|
32
33
|
class: "message-feed__unread-amount"
|
|
33
|
-
},
|
|
34
|
+
}, Ht = /* @__PURE__ */ Oe({
|
|
34
35
|
__name: "Feed",
|
|
35
36
|
props: {
|
|
36
37
|
/**
|
|
@@ -128,7 +129,7 @@ const mt = {
|
|
|
128
129
|
*/
|
|
129
130
|
messageMenuActions: {
|
|
130
131
|
type: Array,
|
|
131
|
-
default: () =>
|
|
132
|
+
default: () => mt()
|
|
132
133
|
}
|
|
133
134
|
},
|
|
134
135
|
emits: [
|
|
@@ -143,318 +144,327 @@ const mt = {
|
|
|
143
144
|
"smsInvite",
|
|
144
145
|
"delimiterRead"
|
|
145
146
|
],
|
|
146
|
-
setup(a, { emit:
|
|
147
|
-
const n = a,
|
|
147
|
+
setup(a, { emit: Z }) {
|
|
148
|
+
const n = a, h = A(), c = A(), x = A(), {
|
|
148
149
|
isShowButton: K,
|
|
149
|
-
isKeyboardPlace:
|
|
150
|
-
checkButtonVisibility:
|
|
151
|
-
} =
|
|
152
|
-
feedRef:
|
|
153
|
-
keyboardRef:
|
|
154
|
-
}), { componentsMap:
|
|
155
|
-
|
|
156
|
-
const
|
|
157
|
-
|
|
150
|
+
isKeyboardPlace: _,
|
|
151
|
+
checkButtonVisibility: ee
|
|
152
|
+
} = Ze({
|
|
153
|
+
feedRef: c,
|
|
154
|
+
keyboardRef: x
|
|
155
|
+
}), { componentsMap: te } = _e(), O = i(() => n.reactionsEnabled);
|
|
156
|
+
nt();
|
|
157
|
+
const se = i(() => n.reactionsMode), $ = i(() => n.currentUserId), j = i(() => n.reactionUserNames);
|
|
158
|
+
B("currentUserId", $), B("reactionUserNames", j), B(
|
|
158
159
|
"messageMenuActions",
|
|
159
|
-
|
|
160
|
+
i(() => n.messageMenuActions)
|
|
160
161
|
);
|
|
161
|
-
const { seriesFlags:
|
|
162
|
-
objects:
|
|
162
|
+
const { seriesFlags: L } = et({
|
|
163
|
+
objects: i(() => n.objects)
|
|
163
164
|
}), {
|
|
164
|
-
visibleObjects:
|
|
165
|
-
renderStart:
|
|
166
|
-
isBackfilling:
|
|
167
|
-
revealThroughIndex:
|
|
168
|
-
accelerateBackfill:
|
|
169
|
-
} =
|
|
170
|
-
objectsRef:
|
|
171
|
-
feedRef:
|
|
172
|
-
}), b =
|
|
173
|
-
if (
|
|
174
|
-
return
|
|
165
|
+
visibleObjects: oe,
|
|
166
|
+
renderStart: v,
|
|
167
|
+
isBackfilling: ae,
|
|
168
|
+
revealThroughIndex: ne,
|
|
169
|
+
accelerateBackfill: re
|
|
170
|
+
} = at({
|
|
171
|
+
objectsRef: i(() => n.objects),
|
|
172
|
+
feedRef: c
|
|
173
|
+
}), b = Q("chatAppId"), N = Q("selectedChat", void 0), P = i(() => {
|
|
174
|
+
if (N)
|
|
175
|
+
return t(N);
|
|
175
176
|
});
|
|
176
|
-
function
|
|
177
|
-
return
|
|
177
|
+
function ie(s) {
|
|
178
|
+
return s.timestamp;
|
|
178
179
|
}
|
|
179
|
-
function M(
|
|
180
|
-
return
|
|
180
|
+
function M(s, o) {
|
|
181
|
+
return s.messageId || `mid-${v.value + o}`;
|
|
181
182
|
}
|
|
182
|
-
function
|
|
183
|
+
function le(s) {
|
|
183
184
|
var e;
|
|
184
|
-
const
|
|
185
|
-
return
|
|
185
|
+
const o = (e = s.reactions) == null ? void 0 : e.items;
|
|
186
|
+
return o != null && o.length ? o.map((r) => `${r.key}:${r.userId}`).join(",") : "";
|
|
186
187
|
}
|
|
187
|
-
function
|
|
188
|
+
function U(s) {
|
|
188
189
|
var m, d, k;
|
|
189
|
-
const
|
|
190
|
+
const o = s, e = o.channelId || ((m = o.channel) == null ? void 0 : m.channelId) || ((d = o.meta) == null ? void 0 : d.channelId);
|
|
190
191
|
if (e) return String(e);
|
|
191
|
-
if (!
|
|
192
|
+
if (!o.dialogId || !((k = P.value) != null && k.dialogs))
|
|
192
193
|
return;
|
|
193
|
-
const r =
|
|
194
|
+
const r = P.value.dialogs.find((R) => R.dialogId === o.dialogId);
|
|
194
195
|
return r == null ? void 0 : r.channelId;
|
|
195
196
|
}
|
|
196
|
-
function
|
|
197
|
-
return
|
|
197
|
+
function de(s) {
|
|
198
|
+
return s.type === "message.call" && typeof n.callMessageOnCallback == "function" ? { onCall: n.callMessageOnCallback } : {};
|
|
198
199
|
}
|
|
199
|
-
const g =
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
} =
|
|
205
|
-
feedRef:
|
|
200
|
+
const g = Z, {
|
|
201
|
+
isInitialized: ce,
|
|
202
|
+
stickToBottom: q,
|
|
203
|
+
initializeScroll: ue,
|
|
204
|
+
smoothScrollToBottom: me
|
|
205
|
+
} = it({
|
|
206
|
+
feedRef: c,
|
|
207
|
+
objectsRef: i(() => n.objects),
|
|
208
|
+
scrollToBottomRef: i(() => n.scrollToBottom)
|
|
209
|
+
}), { topSpacerPx: fe, scheduleMeasure: ge } = dt({
|
|
210
|
+
feedRef: c,
|
|
211
|
+
objectsLengthRef: i(() => n.objects.length)
|
|
212
|
+
}), {
|
|
213
|
+
checkScrollPosition: ye,
|
|
214
|
+
startScrollWatch: E,
|
|
215
|
+
stopScrollWatch: V,
|
|
216
|
+
resetAllowFlags: pe
|
|
217
|
+
} = st({
|
|
218
|
+
feedRef: c,
|
|
206
219
|
emit: g,
|
|
207
|
-
isLoadingMoreRef:
|
|
220
|
+
isLoadingMoreRef: i(() => n.isLoadingMore),
|
|
221
|
+
stickToBottomRef: q
|
|
208
222
|
}), {
|
|
209
223
|
getMessage: S,
|
|
210
|
-
messageAction:
|
|
211
|
-
handleClickReplied:
|
|
212
|
-
feedObjectDoubleClick:
|
|
213
|
-
handleResetReply:
|
|
214
|
-
handleResetEdit:
|
|
215
|
-
} =
|
|
224
|
+
messageAction: be,
|
|
225
|
+
handleClickReplied: ke,
|
|
226
|
+
feedObjectDoubleClick: he,
|
|
227
|
+
handleResetReply: ve,
|
|
228
|
+
handleResetEdit: Me
|
|
229
|
+
} = rt({
|
|
216
230
|
enableDoubleClickReply: n.enableDoubleClickReply,
|
|
217
231
|
emit: g,
|
|
218
|
-
isReplyAllowed: (
|
|
232
|
+
isReplyAllowed: (s) => !ft(s, U(s))
|
|
219
233
|
});
|
|
220
|
-
function
|
|
221
|
-
g("smsInvite",
|
|
234
|
+
function Se(s) {
|
|
235
|
+
g("smsInvite", s);
|
|
222
236
|
}
|
|
223
|
-
function
|
|
224
|
-
g("delimiterRead",
|
|
237
|
+
function Re(s) {
|
|
238
|
+
g("delimiterRead", s);
|
|
225
239
|
}
|
|
226
240
|
const {
|
|
227
|
-
showKeyboard:
|
|
228
|
-
keyboardAction:
|
|
229
|
-
feedKeyboardAction:
|
|
230
|
-
} =
|
|
231
|
-
isKeyboardPlace:
|
|
232
|
-
objects:
|
|
241
|
+
showKeyboard: Ie,
|
|
242
|
+
keyboardAction: Ae,
|
|
243
|
+
feedKeyboardAction: Be
|
|
244
|
+
} = tt({
|
|
245
|
+
isKeyboardPlace: _,
|
|
246
|
+
objects: i(() => n.objects),
|
|
233
247
|
emit: g
|
|
234
248
|
}), {
|
|
235
|
-
showStickyDate:
|
|
236
|
-
stickyDateText:
|
|
237
|
-
show:
|
|
238
|
-
hide:
|
|
239
|
-
} =
|
|
240
|
-
feedRef:
|
|
241
|
-
trackingObjects:
|
|
242
|
-
}), {
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
smoothScrollToBottom: Ce
|
|
247
|
-
} = nt({
|
|
248
|
-
feedRef: u,
|
|
249
|
-
objectsRef: l(() => n.objects),
|
|
250
|
-
scrollToBottomRef: l(() => n.scrollToBottom)
|
|
251
|
-
}), P = l(() => n.chatBackground ?? `data:image/svg+xml;charset=utf-8,${encodeURIComponent(ut)}`);
|
|
252
|
-
function V() {
|
|
253
|
-
if (Be.value || !K.value) {
|
|
254
|
-
Ie();
|
|
249
|
+
showStickyDate: Te,
|
|
250
|
+
stickyDateText: Fe,
|
|
251
|
+
show: Ce,
|
|
252
|
+
hide: De
|
|
253
|
+
} = ct({
|
|
254
|
+
feedRef: c,
|
|
255
|
+
trackingObjects: h
|
|
256
|
+
}), W = i(() => n.chatBackground ?? `data:image/svg+xml;charset=utf-8,${encodeURIComponent(gt)}`);
|
|
257
|
+
function z() {
|
|
258
|
+
if (q.value || !K.value) {
|
|
259
|
+
De();
|
|
255
260
|
return;
|
|
256
261
|
}
|
|
257
|
-
|
|
262
|
+
Ce();
|
|
258
263
|
}
|
|
259
|
-
function
|
|
260
|
-
if (
|
|
261
|
-
const
|
|
262
|
-
|
|
264
|
+
function G(s = !0) {
|
|
265
|
+
if (ee(), ae.value) {
|
|
266
|
+
const o = c.value;
|
|
267
|
+
o && o.scrollTop < 300 && re(), z();
|
|
263
268
|
return;
|
|
264
269
|
}
|
|
265
|
-
|
|
270
|
+
ye(s), z();
|
|
266
271
|
}
|
|
267
|
-
const
|
|
268
|
-
function
|
|
269
|
-
g("forceScrollToBottom"),
|
|
272
|
+
const we = ut(() => G(), 250);
|
|
273
|
+
function xe() {
|
|
274
|
+
g("forceScrollToBottom"), me();
|
|
270
275
|
}
|
|
271
|
-
function
|
|
272
|
-
const
|
|
273
|
-
if (
|
|
274
|
-
const e = parseInt(
|
|
275
|
-
return
|
|
276
|
+
function Ke(s) {
|
|
277
|
+
const o = n.objects;
|
|
278
|
+
if (s.startsWith("mid-")) {
|
|
279
|
+
const e = parseInt(s.slice(4), 10);
|
|
280
|
+
return o[e];
|
|
276
281
|
}
|
|
277
|
-
return
|
|
282
|
+
return o.find((e) => e.messageId === s);
|
|
278
283
|
}
|
|
279
|
-
const { restartObserving:
|
|
280
|
-
trackingObjects:
|
|
284
|
+
const { restartObserving: H } = ot({
|
|
285
|
+
trackingObjects: h,
|
|
281
286
|
chatAppId: b,
|
|
282
|
-
getMessageById:
|
|
283
|
-
onMessageVisible: (
|
|
287
|
+
getMessageById: Ke,
|
|
288
|
+
onMessageVisible: (s) => g("messageVisible", s)
|
|
284
289
|
});
|
|
285
|
-
return
|
|
290
|
+
return T(
|
|
286
291
|
() => n.objects,
|
|
287
292
|
() => {
|
|
288
293
|
F(() => {
|
|
289
294
|
requestAnimationFrame(() => {
|
|
290
|
-
|
|
295
|
+
pe(), G(!1), ge(), h.value = document.querySelectorAll(".tracking-message"), H();
|
|
291
296
|
});
|
|
292
297
|
});
|
|
293
298
|
},
|
|
294
299
|
{ immediate: !0 }
|
|
295
|
-
),
|
|
300
|
+
), T(v, () => {
|
|
296
301
|
F(() => {
|
|
297
|
-
|
|
302
|
+
h.value = document.querySelectorAll(".tracking-message"), H();
|
|
298
303
|
});
|
|
299
|
-
}),
|
|
304
|
+
}), T(
|
|
300
305
|
() => n.scrollTo,
|
|
301
|
-
(
|
|
302
|
-
if (!
|
|
303
|
-
const
|
|
306
|
+
(s) => {
|
|
307
|
+
if (!s) return;
|
|
308
|
+
const o = n.objects, e = s.trim(), r = e.startsWith("msg-") ? e.slice(4) : e;
|
|
304
309
|
let m = -1;
|
|
305
|
-
r.startsWith("mid-") ? m = Number.parseInt(r.slice(4), 10) : m =
|
|
310
|
+
r.startsWith("mid-") ? m = Number.parseInt(r.slice(4), 10) : m = o.findIndex((d) => d.messageId === r || d.messageId === e), Number.isFinite(m) && ne(m);
|
|
306
311
|
}
|
|
307
|
-
),
|
|
308
|
-
targetIdRef:
|
|
312
|
+
), lt({
|
|
313
|
+
targetIdRef: i(() => n.scrollTo),
|
|
309
314
|
feedContainerId: `feed-container-${b}`
|
|
310
|
-
}),
|
|
315
|
+
}), $e(() => {
|
|
311
316
|
F(() => {
|
|
312
|
-
n.objects.length > 0 && !
|
|
317
|
+
n.objects.length > 0 && !ce.value && ue();
|
|
313
318
|
});
|
|
314
|
-
}), (
|
|
315
|
-
a.objects.length > 0 || a.typing ? (
|
|
319
|
+
}), (s, o) => (l(), y("div", yt, [
|
|
320
|
+
a.objects.length > 0 || a.typing ? (l(), y("div", {
|
|
316
321
|
key: 0,
|
|
317
|
-
id: "feed-container-" +
|
|
322
|
+
id: "feed-container-" + t(b),
|
|
318
323
|
ref_key: "refFeed",
|
|
319
|
-
ref:
|
|
324
|
+
ref: c,
|
|
320
325
|
class: "message-feed",
|
|
321
326
|
"data-testid": "feed-scroll",
|
|
322
|
-
style:
|
|
323
|
-
onScroll:
|
|
324
|
-
onMousedown:
|
|
325
|
-
(...e) =>
|
|
326
|
-
onMouseup:
|
|
327
|
-
(...e) =>
|
|
327
|
+
style: C({ backgroundImage: `url(${W.value})` }),
|
|
328
|
+
onScroll: o[2] || (o[2] = (e) => t(we)()),
|
|
329
|
+
onMousedown: o[3] || (o[3] = //@ts-ignore
|
|
330
|
+
(...e) => t(E) && t(E)(...e)),
|
|
331
|
+
onMouseup: o[4] || (o[4] = //@ts-ignore
|
|
332
|
+
(...e) => t(V) && t(V)(...e))
|
|
328
333
|
}, [
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
334
|
+
X(s.$slots, "prepend", {}, void 0, !0),
|
|
335
|
+
I("div", {
|
|
336
|
+
class: "message-feed__top-spacer",
|
|
337
|
+
style: C({ height: `${t(fe)}px` }),
|
|
338
|
+
"aria-hidden": "true"
|
|
339
|
+
}, null, 4),
|
|
340
|
+
je(I("div", bt, [
|
|
341
|
+
p(Xe, {
|
|
332
342
|
"is-loading": a.isLoadingMore,
|
|
333
343
|
size: "small",
|
|
334
344
|
position: "top"
|
|
335
345
|
}, null, 8, ["is-loading"])
|
|
336
346
|
], 512), [
|
|
337
|
-
[
|
|
347
|
+
[Le, a.isLoadingMore]
|
|
338
348
|
]),
|
|
339
|
-
p(
|
|
340
|
-
default:
|
|
341
|
-
|
|
349
|
+
p(D, null, {
|
|
350
|
+
default: w(() => [
|
|
351
|
+
t(Te) && !a.isLoadingMore ? (l(), f(We, {
|
|
342
352
|
key: 0,
|
|
343
353
|
class: "message-feed__sticky-date",
|
|
344
|
-
text:
|
|
345
|
-
}, null, 8, ["text"])) :
|
|
354
|
+
text: t(Fe)
|
|
355
|
+
}, null, 8, ["text"])) : u("", !0)
|
|
346
356
|
]),
|
|
347
357
|
_: 1
|
|
348
358
|
}),
|
|
349
|
-
(
|
|
350
|
-
const k = [e.messageId, e.text, e.status, e.reply, e.deleted,
|
|
359
|
+
(l(!0), y(Ne, null, Pe(t(oe), (e, r, m, d) => {
|
|
360
|
+
const k = [e.messageId, e.text, e.status, e.reply, e.deleted, t(L)[t(v) + r], le(e)];
|
|
351
361
|
if (d && d.key === M(e, r) && Ue(d, k)) return d;
|
|
352
|
-
const R = (
|
|
362
|
+
const R = (l(), y("div", {
|
|
353
363
|
id: "msg-" + M(e, r),
|
|
354
364
|
key: M(e, r),
|
|
355
|
-
"data-timestamp":
|
|
365
|
+
"data-timestamp": ie(e),
|
|
356
366
|
"data-testid": "feed-message",
|
|
357
367
|
"data-message-id": e.messageId,
|
|
358
368
|
class: "tracking-message",
|
|
359
|
-
onDblclick: (
|
|
369
|
+
onDblclick: (J) => t(he)(J, e)
|
|
360
370
|
}, [
|
|
361
|
-
(
|
|
371
|
+
(l(), f(qe(t(te)(e)), Ee({
|
|
362
372
|
key: M(e, r),
|
|
363
373
|
class: "message-feed__message",
|
|
364
374
|
message: e,
|
|
365
375
|
"apply-style": a.applyStyle,
|
|
366
|
-
"is-first-in-series":
|
|
367
|
-
"reactions-enabled":
|
|
368
|
-
"reactions-mode":
|
|
369
|
-
"current-user-id":
|
|
370
|
-
"reaction-user-names":
|
|
376
|
+
"is-first-in-series": t(L)[t(v) + r],
|
|
377
|
+
"reactions-enabled": O.value,
|
|
378
|
+
"reactions-mode": se.value,
|
|
379
|
+
"current-user-id": $.value,
|
|
380
|
+
"reaction-user-names": j.value,
|
|
371
381
|
"subtext-tooltip-data": a.subtextTooltipData,
|
|
372
|
-
channel:
|
|
373
|
-
}, { ref_for: !0 },
|
|
374
|
-
onAction:
|
|
375
|
-
onReply:
|
|
376
|
-
onSmsInvite: (
|
|
377
|
-
onRead:
|
|
382
|
+
channel: U(e)
|
|
383
|
+
}, { ref_for: !0 }, de(e), {
|
|
384
|
+
onAction: t(be),
|
|
385
|
+
onReply: t(ke),
|
|
386
|
+
onSmsInvite: (J) => Se(e),
|
|
387
|
+
onRead: Re
|
|
378
388
|
}), null, 16, ["message", "apply-style", "is-first-in-series", "reactions-enabled", "reactions-mode", "current-user-id", "reaction-user-names", "subtext-tooltip-data", "channel", "onAction", "onReply", "onSmsInvite"]))
|
|
379
389
|
], 40, ["id", "data-timestamp", "data-message-id", "onDblclick"]));
|
|
380
390
|
return R.memo = k, R;
|
|
381
|
-
},
|
|
382
|
-
a.typing ? (
|
|
391
|
+
}, o, 0), 128)),
|
|
392
|
+
a.typing ? (l(), f(Qe, {
|
|
383
393
|
key: 0,
|
|
384
394
|
message: {
|
|
385
395
|
subText: a.typing.title,
|
|
386
396
|
avatar: a.typing.avatar
|
|
387
397
|
}
|
|
388
|
-
}, null, 8, ["message"])) :
|
|
389
|
-
p(
|
|
390
|
-
default:
|
|
391
|
-
|
|
398
|
+
}, null, 8, ["message"])) : u("", !0),
|
|
399
|
+
p(D, null, {
|
|
400
|
+
default: w(() => [
|
|
401
|
+
t(Ie) ? (l(), f(He, {
|
|
392
402
|
key: 0,
|
|
393
403
|
ref_key: "keyboardRef",
|
|
394
|
-
ref:
|
|
404
|
+
ref: x,
|
|
395
405
|
class: "message-feed__keyboard",
|
|
396
406
|
keyboard: a.objects[a.objects.length - 1].keyboard,
|
|
397
407
|
align: a.keyboardAlign,
|
|
398
|
-
onAction:
|
|
399
|
-
}, null, 8, ["keyboard", "align", "onAction"])) :
|
|
408
|
+
onAction: t(Ae)
|
|
409
|
+
}, null, 8, ["keyboard", "align", "onAction"])) : u("", !0)
|
|
400
410
|
]),
|
|
401
411
|
_: 1
|
|
402
412
|
}),
|
|
403
|
-
a.feedKeyboards && a.feedKeyboards.length > 0 ? (
|
|
413
|
+
a.feedKeyboards && a.feedKeyboards.length > 0 ? (l(), f(Je, {
|
|
404
414
|
key: 1,
|
|
405
415
|
class: "message-feed__feed-keyboard",
|
|
406
416
|
buttons: a.feedKeyboards,
|
|
407
417
|
align: a.feedKeyboardAlign,
|
|
408
|
-
onAction:
|
|
409
|
-
}, null, 8, ["buttons", "align", "onAction"])) :
|
|
410
|
-
], 44,
|
|
418
|
+
onAction: t(Be)
|
|
419
|
+
}, null, 8, ["buttons", "align", "onAction"])) : u("", !0)
|
|
420
|
+
], 44, pt)) : (l(), y("div", {
|
|
411
421
|
key: 1,
|
|
412
422
|
ref_key: "refFeed",
|
|
413
|
-
ref:
|
|
423
|
+
ref: c,
|
|
414
424
|
class: "message-feed",
|
|
415
|
-
style:
|
|
425
|
+
style: C({ backgroundImage: `url(${W.value})` })
|
|
416
426
|
}, [
|
|
417
|
-
|
|
418
|
-
|
|
427
|
+
I("div", kt, [
|
|
428
|
+
X(s.$slots, "empty-feed", {}, void 0, !0)
|
|
419
429
|
])
|
|
420
430
|
], 4)),
|
|
421
|
-
p(
|
|
422
|
-
default:
|
|
423
|
-
|
|
431
|
+
p(D, null, {
|
|
432
|
+
default: w(() => [
|
|
433
|
+
t(K) ? (l(), y("button", {
|
|
424
434
|
key: 0,
|
|
425
435
|
class: "message-feed__button-down",
|
|
426
|
-
onClick:
|
|
436
|
+
onClick: xe
|
|
427
437
|
}, [
|
|
428
|
-
a.buttonParams ? (
|
|
429
|
-
|
|
430
|
-
])) :
|
|
438
|
+
a.buttonParams ? (l(), y("div", ht, Ve(a.buttonParams.unreadAmount), 1)) : u("", !0),
|
|
439
|
+
o[5] || (o[5] = I("span", { class: "pi pi-angle-down message-feed__icon-down" }, null, -1))
|
|
440
|
+
])) : u("", !0)
|
|
431
441
|
]),
|
|
432
442
|
_: 1
|
|
433
443
|
}),
|
|
434
|
-
|
|
444
|
+
t(S)().reply ? (l(), f(Y, {
|
|
435
445
|
key: 2,
|
|
436
|
-
to: "#chat-input-reply-line-" +
|
|
446
|
+
to: "#chat-input-reply-line-" + t(b)
|
|
437
447
|
}, [
|
|
438
|
-
p(
|
|
448
|
+
p(ze, {
|
|
439
449
|
class: "chat-input-reply",
|
|
440
|
-
message:
|
|
441
|
-
onReset:
|
|
450
|
+
message: t(S)().reply,
|
|
451
|
+
onReset: t(ve)
|
|
442
452
|
}, null, 8, ["message", "onReset"])
|
|
443
|
-
], 8, ["to"])) :
|
|
444
|
-
|
|
453
|
+
], 8, ["to"])) : u("", !0),
|
|
454
|
+
t(S)().edit ? (l(), f(Y, {
|
|
445
455
|
key: 3,
|
|
446
|
-
to: "#chat-input-reply-line-" +
|
|
456
|
+
to: "#chat-input-reply-line-" + t(b)
|
|
447
457
|
}, [
|
|
448
|
-
p(
|
|
458
|
+
p(Ge, {
|
|
449
459
|
class: "chat-input-reply",
|
|
450
|
-
message:
|
|
451
|
-
onReset:
|
|
460
|
+
message: t(S)().edit,
|
|
461
|
+
onReset: t(Me)
|
|
452
462
|
}, null, 8, ["message", "onReset"])
|
|
453
|
-
], 8, ["to"])) :
|
|
454
|
-
|
|
463
|
+
], 8, ["to"])) : u("", !0),
|
|
464
|
+
O.value ? (l(), f(Ye, { key: 4 })) : u("", !0)
|
|
455
465
|
]));
|
|
456
466
|
}
|
|
457
467
|
});
|
|
458
468
|
export {
|
|
459
|
-
|
|
469
|
+
Ht as default
|
|
460
470
|
};
|