stream-chat-react 13.6.6 → 13.7.0
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/components/ChannelPreview/utils.js +3 -1
- package/dist/components/Chat/hooks/useChat.js +1 -1
- package/dist/components/Message/renderText/remarkPlugins/imageToLink.d.ts +12 -0
- package/dist/components/Message/renderText/remarkPlugins/imageToLink.js +27 -0
- package/dist/components/Message/renderText/remarkPlugins/index.d.ts +2 -0
- package/dist/components/Message/renderText/remarkPlugins/index.js +2 -0
- package/dist/components/Message/renderText/remarkPlugins/plusPlusToEmphasis.d.ts +6 -0
- package/dist/components/Message/renderText/remarkPlugins/plusPlusToEmphasis.js +64 -0
- package/dist/components/Message/renderText/renderText.js +4 -1
- package/dist/experimental/index.browser.cjs +105 -44
- package/dist/experimental/index.browser.cjs.map +4 -4
- package/dist/experimental/index.node.cjs +105 -44
- package/dist/experimental/index.node.cjs.map +4 -4
- package/dist/index.browser.cjs +157 -91
- package/dist/index.browser.cjs.map +4 -4
- package/dist/index.node.cjs +159 -91
- package/dist/index.node.cjs.map +4 -4
- package/package.json +1 -1
package/dist/index.node.cjs
CHANGED
|
@@ -556,6 +556,7 @@ __export(src_exports, {
|
|
|
556
556
|
hasNotMoreMessages: () => hasNotMoreMessages,
|
|
557
557
|
hiTranslations: () => hi_default,
|
|
558
558
|
htmlToTextPlugin: () => htmlToTextPlugin,
|
|
559
|
+
imageToLink: () => imageToLink,
|
|
559
560
|
insertIntro: () => insertIntro,
|
|
560
561
|
isChannel: () => isChannel,
|
|
561
562
|
isChannelArchived: () => isChannelArchived,
|
|
@@ -597,6 +598,7 @@ __export(src_exports, {
|
|
|
597
598
|
moveChannelUp: () => moveChannelUp,
|
|
598
599
|
moveChannelUpwards: () => moveChannelUpwards,
|
|
599
600
|
nlTranslations: () => nl_default,
|
|
601
|
+
plusPlusToEmphasis: () => plusPlusToEmphasis,
|
|
600
602
|
processMessages: () => processMessages,
|
|
601
603
|
ptTranslations: () => pt_default,
|
|
602
604
|
reactionHandlerWarning: () => reactionHandlerWarning,
|
|
@@ -1537,10 +1539,10 @@ function WithComponents({
|
|
|
1537
1539
|
|
|
1538
1540
|
// src/components/Attachment/AttachmentActions.tsx
|
|
1539
1541
|
var UnMemoizedAttachmentActions = (props) => {
|
|
1540
|
-
const { actionHandler, actions, id, text:
|
|
1542
|
+
const { actionHandler, actions, id, text: text8 } = props;
|
|
1541
1543
|
const { t } = useTranslationContext("UnMemoizedAttachmentActions");
|
|
1542
1544
|
const handleActionClick = (event, name2, value) => actionHandler?.(name2, value, event);
|
|
1543
|
-
return /* @__PURE__ */ import_react19.default.createElement("div", { className: "str-chat__message-attachment-actions" }, /* @__PURE__ */ import_react19.default.createElement("div", { className: "str-chat__message-attachment-actions-form" }, /* @__PURE__ */ import_react19.default.createElement("span", null,
|
|
1545
|
+
return /* @__PURE__ */ import_react19.default.createElement("div", { className: "str-chat__message-attachment-actions" }, /* @__PURE__ */ import_react19.default.createElement("div", { className: "str-chat__message-attachment-actions-form" }, /* @__PURE__ */ import_react19.default.createElement("span", null, text8), actions.map((action) => /* @__PURE__ */ import_react19.default.createElement(
|
|
1544
1546
|
"button",
|
|
1545
1547
|
{
|
|
1546
1548
|
className: `str-chat__message-attachment-actions-button str-chat__message-attachment-actions-button--${action.style}`,
|
|
@@ -4529,7 +4531,7 @@ var useChannelSearch = ({
|
|
|
4529
4531
|
]
|
|
4530
4532
|
);
|
|
4531
4533
|
const getChannels = (0, import_react48.useCallback)(
|
|
4532
|
-
async (
|
|
4534
|
+
async (text8) => {
|
|
4533
4535
|
if (!searchForChannels && !searchForUsers) return;
|
|
4534
4536
|
let results2 = [];
|
|
4535
4537
|
const promises = [];
|
|
@@ -4539,7 +4541,7 @@ var useChannelSearch = ({
|
|
|
4539
4541
|
client.queryChannels(
|
|
4540
4542
|
{
|
|
4541
4543
|
members: { $in: [client.userID] },
|
|
4542
|
-
name: { $autocomplete:
|
|
4544
|
+
name: { $autocomplete: text8 },
|
|
4543
4545
|
...searchQueryParams?.channelFilters?.filters
|
|
4544
4546
|
},
|
|
4545
4547
|
searchQueryParams?.channelFilters?.sort || {},
|
|
@@ -4551,7 +4553,7 @@ var useChannelSearch = ({
|
|
|
4551
4553
|
promises.push(
|
|
4552
4554
|
client.queryUsers(
|
|
4553
4555
|
{
|
|
4554
|
-
$or: [{ id: { $autocomplete:
|
|
4556
|
+
$or: [{ id: { $autocomplete: text8 } }, { name: { $autocomplete: text8 } }],
|
|
4555
4557
|
...searchQueryParams?.userFilters?.filters
|
|
4556
4558
|
},
|
|
4557
4559
|
{ id: 1, ...searchQueryParams?.userFilters?.sort },
|
|
@@ -5131,12 +5133,12 @@ var UnMemoizedEmptyStateIndicator = (props) => {
|
|
|
5131
5133
|
const { t } = useTranslationContext("EmptyStateIndicator");
|
|
5132
5134
|
if (listType === "thread") return null;
|
|
5133
5135
|
if (listType === "channel") {
|
|
5134
|
-
const
|
|
5135
|
-
return /* @__PURE__ */ import_react55.default.createElement(import_react55.default.Fragment, null, /* @__PURE__ */ import_react55.default.createElement("div", { className: "str-chat__channel-list-empty" }, /* @__PURE__ */ import_react55.default.createElement(ChatBubble, null), /* @__PURE__ */ import_react55.default.createElement("p", { role: "listitem" },
|
|
5136
|
+
const text8 = t("You have no channels currently");
|
|
5137
|
+
return /* @__PURE__ */ import_react55.default.createElement(import_react55.default.Fragment, null, /* @__PURE__ */ import_react55.default.createElement("div", { className: "str-chat__channel-list-empty" }, /* @__PURE__ */ import_react55.default.createElement(ChatBubble, null), /* @__PURE__ */ import_react55.default.createElement("p", { role: "listitem" }, text8)));
|
|
5136
5138
|
}
|
|
5137
5139
|
if (listType === "message") {
|
|
5138
|
-
const
|
|
5139
|
-
return /* @__PURE__ */ import_react55.default.createElement("div", { className: "str-chat__empty-channel" }, /* @__PURE__ */ import_react55.default.createElement(ChatBubble, null), /* @__PURE__ */ import_react55.default.createElement("p", { className: "str-chat__empty-channel-text", role: "listitem" },
|
|
5140
|
+
const text8 = t("No chats here yet\u2026");
|
|
5141
|
+
return /* @__PURE__ */ import_react55.default.createElement("div", { className: "str-chat__empty-channel" }, /* @__PURE__ */ import_react55.default.createElement(ChatBubble, null), /* @__PURE__ */ import_react55.default.createElement("p", { className: "str-chat__empty-channel-text", role: "listitem" }, text8));
|
|
5140
5142
|
}
|
|
5141
5143
|
return /* @__PURE__ */ import_react55.default.createElement("p", null, "No items exist");
|
|
5142
5144
|
};
|
|
@@ -10469,7 +10471,7 @@ function resolveAllAttention(events, context) {
|
|
|
10469
10471
|
let index2 = -1;
|
|
10470
10472
|
let open;
|
|
10471
10473
|
let group;
|
|
10472
|
-
let
|
|
10474
|
+
let text8;
|
|
10473
10475
|
let openingSequence;
|
|
10474
10476
|
let closingSequence;
|
|
10475
10477
|
let use;
|
|
@@ -10507,7 +10509,7 @@ function resolveAllAttention(events, context) {
|
|
|
10507
10509
|
},
|
|
10508
10510
|
end
|
|
10509
10511
|
};
|
|
10510
|
-
|
|
10512
|
+
text8 = {
|
|
10511
10513
|
type: use > 1 ? "strongText" : "emphasisText",
|
|
10512
10514
|
start: {
|
|
10513
10515
|
...events[open][1].end
|
|
@@ -10535,9 +10537,9 @@ function resolveAllAttention(events, context) {
|
|
|
10535
10537
|
if (events[open][1].end.offset - events[open][1].start.offset) {
|
|
10536
10538
|
nextEvents = push(nextEvents, [["enter", events[open][1], context], ["exit", events[open][1], context]]);
|
|
10537
10539
|
}
|
|
10538
|
-
nextEvents = push(nextEvents, [["enter", group, context], ["enter", openingSequence, context], ["exit", openingSequence, context], ["enter",
|
|
10540
|
+
nextEvents = push(nextEvents, [["enter", group, context], ["enter", openingSequence, context], ["exit", openingSequence, context], ["enter", text8, context]]);
|
|
10539
10541
|
nextEvents = push(nextEvents, resolveAll(context.parser.constructs.insideSpan.null, events.slice(open + 1, index2), context));
|
|
10540
|
-
nextEvents = push(nextEvents, [["exit",
|
|
10542
|
+
nextEvents = push(nextEvents, [["exit", text8, context], ["enter", closingSequence, context], ["exit", closingSequence, context], ["exit", group, context]]);
|
|
10541
10543
|
if (events[index2][1].end.offset - events[index2][1].start.offset) {
|
|
10542
10544
|
offset = 2;
|
|
10543
10545
|
nextEvents = push(nextEvents, [["enter", events[index2][1], context], ["exit", events[index2][1], context]]);
|
|
@@ -11979,7 +11981,7 @@ function resolveHeadingAtx(events, context) {
|
|
|
11979
11981
|
let contentEnd = events.length - 2;
|
|
11980
11982
|
let contentStart = 3;
|
|
11981
11983
|
let content3;
|
|
11982
|
-
let
|
|
11984
|
+
let text8;
|
|
11983
11985
|
if (events[contentStart][1].type === "whitespace") {
|
|
11984
11986
|
contentStart += 2;
|
|
11985
11987
|
}
|
|
@@ -11995,13 +11997,13 @@ function resolveHeadingAtx(events, context) {
|
|
|
11995
11997
|
start: events[contentStart][1].start,
|
|
11996
11998
|
end: events[contentEnd][1].end
|
|
11997
11999
|
};
|
|
11998
|
-
|
|
12000
|
+
text8 = {
|
|
11999
12001
|
type: "chunkText",
|
|
12000
12002
|
start: events[contentStart][1].start,
|
|
12001
12003
|
end: events[contentEnd][1].end,
|
|
12002
12004
|
contentType: "text"
|
|
12003
12005
|
};
|
|
12004
|
-
splice(events, contentStart, contentEnd - contentStart + 1, [["enter", content3, context], ["enter",
|
|
12006
|
+
splice(events, contentStart, contentEnd - contentStart + 1, [["enter", content3, context], ["enter", text8, context], ["exit", text8, context], ["exit", content3, context]]);
|
|
12005
12007
|
}
|
|
12006
12008
|
return events;
|
|
12007
12009
|
}
|
|
@@ -12891,7 +12893,7 @@ function resolveToLabelEnd(events, context) {
|
|
|
12891
12893
|
...events[close][1].end
|
|
12892
12894
|
}
|
|
12893
12895
|
};
|
|
12894
|
-
const
|
|
12896
|
+
const text8 = {
|
|
12895
12897
|
type: "labelText",
|
|
12896
12898
|
start: {
|
|
12897
12899
|
...events[open + offset + 2][1].end
|
|
@@ -12902,9 +12904,9 @@ function resolveToLabelEnd(events, context) {
|
|
|
12902
12904
|
};
|
|
12903
12905
|
media = [["enter", group, context], ["enter", label, context]];
|
|
12904
12906
|
media = push(media, events.slice(open + 1, open + offset + 3));
|
|
12905
|
-
media = push(media, [["enter",
|
|
12907
|
+
media = push(media, [["enter", text8, context]]);
|
|
12906
12908
|
media = push(media, resolveAll(context.parser.constructs.insideSpan.null, events.slice(open + offset + 4, close - 3), context));
|
|
12907
|
-
media = push(media, [["exit",
|
|
12909
|
+
media = push(media, [["exit", text8, context], events[close - 2], events[close - 1], ["exit", label, context]]);
|
|
12908
12910
|
media = push(media, events.slice(close + 1));
|
|
12909
12911
|
media = push(media, [["exit", group, context]]);
|
|
12910
12912
|
splice(events, open, events.length, media);
|
|
@@ -13284,7 +13286,7 @@ var setextUnderline = {
|
|
|
13284
13286
|
function resolveToSetextUnderline(events, context) {
|
|
13285
13287
|
let index2 = events.length;
|
|
13286
13288
|
let content3;
|
|
13287
|
-
let
|
|
13289
|
+
let text8;
|
|
13288
13290
|
let definition3;
|
|
13289
13291
|
while (index2--) {
|
|
13290
13292
|
if (events[index2][0] === "enter") {
|
|
@@ -13293,7 +13295,7 @@ function resolveToSetextUnderline(events, context) {
|
|
|
13293
13295
|
break;
|
|
13294
13296
|
}
|
|
13295
13297
|
if (events[index2][1].type === "paragraph") {
|
|
13296
|
-
|
|
13298
|
+
text8 = index2;
|
|
13297
13299
|
}
|
|
13298
13300
|
} else {
|
|
13299
13301
|
if (events[index2][1].type === "content") {
|
|
@@ -13307,15 +13309,15 @@ function resolveToSetextUnderline(events, context) {
|
|
|
13307
13309
|
const heading3 = {
|
|
13308
13310
|
type: "setextHeading",
|
|
13309
13311
|
start: {
|
|
13310
|
-
...events[
|
|
13312
|
+
...events[text8][1].start
|
|
13311
13313
|
},
|
|
13312
13314
|
end: {
|
|
13313
13315
|
...events[events.length - 1][1].end
|
|
13314
13316
|
}
|
|
13315
13317
|
};
|
|
13316
|
-
events[
|
|
13318
|
+
events[text8][1].type = "setextHeadingText";
|
|
13317
13319
|
if (definition3) {
|
|
13318
|
-
events.splice(
|
|
13320
|
+
events.splice(text8, 0, ["enter", heading3, context]);
|
|
13319
13321
|
events.splice(definition3 + 1, 0, ["exit", events[content3][1], context]);
|
|
13320
13322
|
events[content3][1].end = {
|
|
13321
13323
|
...events[definition3][1].end
|
|
@@ -13419,10 +13421,10 @@ function initializeFactory(field) {
|
|
|
13419
13421
|
function initializeText(effects) {
|
|
13420
13422
|
const self2 = this;
|
|
13421
13423
|
const constructs2 = this.parser.constructs[field];
|
|
13422
|
-
const
|
|
13424
|
+
const text8 = effects.attempt(constructs2, start2, notText);
|
|
13423
13425
|
return start2;
|
|
13424
13426
|
function start2(code4) {
|
|
13425
|
-
return atBreak(code4) ?
|
|
13427
|
+
return atBreak(code4) ? text8(code4) : notText(code4);
|
|
13426
13428
|
}
|
|
13427
13429
|
function notText(code4) {
|
|
13428
13430
|
if (code4 === null) {
|
|
@@ -13436,7 +13438,7 @@ function initializeFactory(field) {
|
|
|
13436
13438
|
function data(code4) {
|
|
13437
13439
|
if (atBreak(code4)) {
|
|
13438
13440
|
effects.exit("data");
|
|
13439
|
-
return
|
|
13441
|
+
return text8(code4);
|
|
13440
13442
|
}
|
|
13441
13443
|
effects.consume(code4);
|
|
13442
13444
|
return data;
|
|
@@ -14455,7 +14457,7 @@ function compiler(options) {
|
|
|
14455
14457
|
const siblings = node2.children;
|
|
14456
14458
|
let tail = siblings[siblings.length - 1];
|
|
14457
14459
|
if (!tail || tail.type !== "text") {
|
|
14458
|
-
tail =
|
|
14460
|
+
tail = text8();
|
|
14459
14461
|
tail.position = {
|
|
14460
14462
|
start: point3(token.start),
|
|
14461
14463
|
// @ts-expect-error: we’ll add `end` later.
|
|
@@ -14700,7 +14702,7 @@ function compiler(options) {
|
|
|
14700
14702
|
children: []
|
|
14701
14703
|
};
|
|
14702
14704
|
}
|
|
14703
|
-
function
|
|
14705
|
+
function text8() {
|
|
14704
14706
|
return {
|
|
14705
14707
|
type: "text",
|
|
14706
14708
|
value: ""
|
|
@@ -14982,13 +14984,13 @@ function image(state, node2) {
|
|
|
14982
14984
|
|
|
14983
14985
|
// node_modules/mdast-util-to-hast/lib/handlers/inline-code.js
|
|
14984
14986
|
function inlineCode(state, node2) {
|
|
14985
|
-
const
|
|
14986
|
-
state.patch(node2,
|
|
14987
|
+
const text8 = { type: "text", value: node2.value.replace(/\r?\n|\r/g, " ") };
|
|
14988
|
+
state.patch(node2, text8);
|
|
14987
14989
|
const result = {
|
|
14988
14990
|
type: "element",
|
|
14989
14991
|
tagName: "code",
|
|
14990
14992
|
properties: {},
|
|
14991
|
-
children: [
|
|
14993
|
+
children: [text8]
|
|
14992
14994
|
};
|
|
14993
14995
|
state.patch(node2, result);
|
|
14994
14996
|
return state.applyData(node2, result);
|
|
@@ -17714,9 +17716,9 @@ var getReadByTooltipText = (users, t, client, tooltipUserNameMapper) => {
|
|
|
17714
17716
|
}
|
|
17715
17717
|
return outStr;
|
|
17716
17718
|
};
|
|
17717
|
-
var isOnlyEmojis = (
|
|
17718
|
-
if (!
|
|
17719
|
-
const noEmojis =
|
|
17719
|
+
var isOnlyEmojis = (text8) => {
|
|
17720
|
+
if (!text8) return false;
|
|
17721
|
+
const noEmojis = text8.replace((0, import_emoji_regex.default)(), "");
|
|
17720
17722
|
const noSpace = noEmojis.replace(/[\s\n]/gm, "");
|
|
17721
17723
|
return !noSpace;
|
|
17722
17724
|
};
|
|
@@ -18154,25 +18156,25 @@ var DEFAULT_RENDERING_LETTER_COUNT = 2;
|
|
|
18154
18156
|
var useMessageTextStreaming = ({
|
|
18155
18157
|
renderingLetterCount = DEFAULT_RENDERING_LETTER_COUNT,
|
|
18156
18158
|
streamingLetterIntervalMs = DEFAULT_LETTER_INTERVAL,
|
|
18157
|
-
text:
|
|
18159
|
+
text: text8
|
|
18158
18160
|
}) => {
|
|
18159
|
-
const [streamedMessageText, setStreamedMessageText] = (0, import_react79.useState)(
|
|
18160
|
-
const textCursor = (0, import_react79.useRef)(
|
|
18161
|
+
const [streamedMessageText, setStreamedMessageText] = (0, import_react79.useState)(text8);
|
|
18162
|
+
const textCursor = (0, import_react79.useRef)(text8.length);
|
|
18161
18163
|
(0, import_react79.useEffect)(() => {
|
|
18162
|
-
const textLength =
|
|
18164
|
+
const textLength = text8.length;
|
|
18163
18165
|
const interval = setInterval(() => {
|
|
18164
|
-
if (!
|
|
18166
|
+
if (!text8 || textCursor.current >= textLength) {
|
|
18165
18167
|
clearInterval(interval);
|
|
18166
18168
|
}
|
|
18167
18169
|
const newCursorValue = textCursor.current + renderingLetterCount;
|
|
18168
|
-
const newText =
|
|
18170
|
+
const newText = text8.substring(0, newCursorValue);
|
|
18169
18171
|
textCursor.current += newText.length - textCursor.current;
|
|
18170
18172
|
setStreamedMessageText(newText);
|
|
18171
18173
|
}, streamingLetterIntervalMs);
|
|
18172
18174
|
return () => {
|
|
18173
18175
|
clearInterval(interval);
|
|
18174
18176
|
};
|
|
18175
|
-
}, [streamingLetterIntervalMs, renderingLetterCount,
|
|
18177
|
+
}, [streamingLetterIntervalMs, renderingLetterCount, text8]);
|
|
18176
18178
|
return { streamedMessageText };
|
|
18177
18179
|
};
|
|
18178
18180
|
|
|
@@ -19241,8 +19243,8 @@ var MessageActionsWrapper = (props) => {
|
|
|
19241
19243
|
};
|
|
19242
19244
|
|
|
19243
19245
|
// src/components/Message/renderText/regex.ts
|
|
19244
|
-
function escapeRegExp(
|
|
19245
|
-
return
|
|
19246
|
+
function escapeRegExp(text8) {
|
|
19247
|
+
return text8.replace(/[-[\]{}()*+?.,/\\^$|#]/g, "\\$&");
|
|
19246
19248
|
}
|
|
19247
19249
|
var detectHttp = /(http(s?):\/\/)?(www\.)?/;
|
|
19248
19250
|
var messageCodeBlocks = (message) => {
|
|
@@ -19520,6 +19522,26 @@ var transform = (tree) => {
|
|
|
19520
19522
|
};
|
|
19521
19523
|
var htmlToTextPlugin = () => transform;
|
|
19522
19524
|
|
|
19525
|
+
// src/components/Message/renderText/remarkPlugins/imageToLink.ts
|
|
19526
|
+
var text5 = (value) => ({ type: "text", value });
|
|
19527
|
+
function imageToLink({ getTextLabelFrom = "url" } = {}) {
|
|
19528
|
+
return (tree) => {
|
|
19529
|
+
const visitor3 = (node2, index2, parent) => {
|
|
19530
|
+
if (parent == null || index2 == null) return;
|
|
19531
|
+
const label = node2[getTextLabelFrom] ?? node2.url;
|
|
19532
|
+
const link3 = {
|
|
19533
|
+
children: [text5(label)],
|
|
19534
|
+
title: node2.title ?? node2.alt ?? node2.url,
|
|
19535
|
+
type: "link",
|
|
19536
|
+
url: node2.url
|
|
19537
|
+
};
|
|
19538
|
+
parent.children.splice(index2, 1, link3);
|
|
19539
|
+
return [SKIP, index2 + 1];
|
|
19540
|
+
};
|
|
19541
|
+
visit(tree, "image", visitor3);
|
|
19542
|
+
};
|
|
19543
|
+
}
|
|
19544
|
+
|
|
19523
19545
|
// src/components/Message/renderText/remarkPlugins/keepLineBreaksPlugin.ts
|
|
19524
19546
|
var visitor2 = (node2, index2, parent) => {
|
|
19525
19547
|
if (!(index2 && parent && node2.position)) return;
|
|
@@ -19546,6 +19568,45 @@ var transform2 = (tree) => {
|
|
|
19546
19568
|
};
|
|
19547
19569
|
var keepLineBreaksPlugin = () => transform2;
|
|
19548
19570
|
|
|
19571
|
+
// src/components/Message/renderText/remarkPlugins/plusPlusToEmphasis.ts
|
|
19572
|
+
var INS_REGEX = /\+\+(\S(?:[\s\S]*?\S)?)\+\+/g;
|
|
19573
|
+
var IGNORE_NODE_TYPES = /* @__PURE__ */ new Set([
|
|
19574
|
+
"code",
|
|
19575
|
+
"inlineCode",
|
|
19576
|
+
"link",
|
|
19577
|
+
"linkReference",
|
|
19578
|
+
"definition",
|
|
19579
|
+
"math",
|
|
19580
|
+
"inlineMath"
|
|
19581
|
+
]);
|
|
19582
|
+
var plusPlusToEmphasis = () => {
|
|
19583
|
+
const visitor3 = (node2, index2, parent) => {
|
|
19584
|
+
if (IGNORE_NODE_TYPES.has(node2.type)) return SKIP;
|
|
19585
|
+
if (node2.type !== "text" || parent == null || typeof index2 !== "number") return;
|
|
19586
|
+
const value = node2.value;
|
|
19587
|
+
INS_REGEX.lastIndex = 0;
|
|
19588
|
+
let match;
|
|
19589
|
+
let last = 0;
|
|
19590
|
+
const out = [];
|
|
19591
|
+
while (match = INS_REGEX.exec(value)) {
|
|
19592
|
+
const [full, inner] = match;
|
|
19593
|
+
const start2 = match.index;
|
|
19594
|
+
if (start2 > last) out.push({ type: "text", value: value.slice(last, start2) });
|
|
19595
|
+
out.push({
|
|
19596
|
+
children: [{ type: "text", value: inner }],
|
|
19597
|
+
data: { hName: "ins" },
|
|
19598
|
+
type: "emphasis"
|
|
19599
|
+
});
|
|
19600
|
+
last = start2 + full.length;
|
|
19601
|
+
}
|
|
19602
|
+
if (out.length === 0) return;
|
|
19603
|
+
if (last < value.length) out.push({ type: "text", value: value.slice(last) });
|
|
19604
|
+
parent.children.splice(index2, 1, ...out);
|
|
19605
|
+
return [SKIP, index2 + out.length];
|
|
19606
|
+
};
|
|
19607
|
+
return (tree) => visit(tree, visitor3);
|
|
19608
|
+
};
|
|
19609
|
+
|
|
19549
19610
|
// src/components/Message/renderText/renderText.tsx
|
|
19550
19611
|
var import_react103 = __toESM(require("react"));
|
|
19551
19612
|
var import_linkifyjs = require("linkifyjs");
|
|
@@ -20738,12 +20799,12 @@ function linkReference2(node2, _, state, info) {
|
|
|
20738
20799
|
let subexit = state.enter("label");
|
|
20739
20800
|
const tracker = state.createTracker(info);
|
|
20740
20801
|
let value = tracker.move("[");
|
|
20741
|
-
const
|
|
20802
|
+
const text8 = state.containerPhrasing(node2, {
|
|
20742
20803
|
before: value,
|
|
20743
20804
|
after: "]",
|
|
20744
20805
|
...tracker.current()
|
|
20745
20806
|
});
|
|
20746
|
-
value += tracker.move(
|
|
20807
|
+
value += tracker.move(text8 + "][");
|
|
20747
20808
|
subexit();
|
|
20748
20809
|
const stack = state.stack;
|
|
20749
20810
|
state.stack = [];
|
|
@@ -20756,7 +20817,7 @@ function linkReference2(node2, _, state, info) {
|
|
|
20756
20817
|
subexit();
|
|
20757
20818
|
state.stack = stack;
|
|
20758
20819
|
exit3();
|
|
20759
|
-
if (type === "full" || !
|
|
20820
|
+
if (type === "full" || !text8 || text8 !== reference) {
|
|
20760
20821
|
value += tracker.move(reference + "]");
|
|
20761
20822
|
} else if (type === "shortcut") {
|
|
20762
20823
|
value = value.slice(0, -1);
|
|
@@ -21001,7 +21062,7 @@ function strongPeek(_, _1, state) {
|
|
|
21001
21062
|
}
|
|
21002
21063
|
|
|
21003
21064
|
// node_modules/mdast-util-to-markdown/lib/handle/text.js
|
|
21004
|
-
function
|
|
21065
|
+
function text6(node2, _, state, info) {
|
|
21005
21066
|
return state.safe(node2.value, info);
|
|
21006
21067
|
}
|
|
21007
21068
|
|
|
@@ -21042,7 +21103,7 @@ var handle = {
|
|
|
21042
21103
|
paragraph: paragraph2,
|
|
21043
21104
|
root: root3,
|
|
21044
21105
|
strong: strong2,
|
|
21045
|
-
text:
|
|
21106
|
+
text: text6,
|
|
21046
21107
|
thematicBreak: thematicBreak3
|
|
21047
21108
|
};
|
|
21048
21109
|
|
|
@@ -21330,27 +21391,27 @@ var emailAutolink = {
|
|
|
21330
21391
|
tokenize: tokenizeEmailAutolink,
|
|
21331
21392
|
previous: previousEmail
|
|
21332
21393
|
};
|
|
21333
|
-
var
|
|
21394
|
+
var text7 = {};
|
|
21334
21395
|
function gfmAutolinkLiteral() {
|
|
21335
21396
|
return {
|
|
21336
|
-
text:
|
|
21397
|
+
text: text7
|
|
21337
21398
|
};
|
|
21338
21399
|
}
|
|
21339
21400
|
var code3 = 48;
|
|
21340
21401
|
while (code3 < 123) {
|
|
21341
|
-
|
|
21402
|
+
text7[code3] = emailAutolink;
|
|
21342
21403
|
code3++;
|
|
21343
21404
|
if (code3 === 58) code3 = 65;
|
|
21344
21405
|
else if (code3 === 91) code3 = 97;
|
|
21345
21406
|
}
|
|
21346
|
-
|
|
21347
|
-
|
|
21348
|
-
|
|
21349
|
-
|
|
21350
|
-
|
|
21351
|
-
|
|
21352
|
-
|
|
21353
|
-
|
|
21407
|
+
text7[43] = emailAutolink;
|
|
21408
|
+
text7[45] = emailAutolink;
|
|
21409
|
+
text7[46] = emailAutolink;
|
|
21410
|
+
text7[95] = emailAutolink;
|
|
21411
|
+
text7[72] = [emailAutolink, protocolAutolink];
|
|
21412
|
+
text7[104] = [emailAutolink, protocolAutolink];
|
|
21413
|
+
text7[87] = [emailAutolink, wwwAutolink];
|
|
21414
|
+
text7[119] = [emailAutolink, wwwAutolink];
|
|
21354
21415
|
function tokenizeEmailAutolink(effects, ok3, nok) {
|
|
21355
21416
|
const self2 = this;
|
|
21356
21417
|
let dot;
|
|
@@ -21949,17 +22010,17 @@ function gfmStrikethrough(options) {
|
|
|
21949
22010
|
start: Object.assign({}, events[open][1].start),
|
|
21950
22011
|
end: Object.assign({}, events[index2][1].end)
|
|
21951
22012
|
};
|
|
21952
|
-
const
|
|
22013
|
+
const text8 = {
|
|
21953
22014
|
type: "strikethroughText",
|
|
21954
22015
|
start: Object.assign({}, events[open][1].end),
|
|
21955
22016
|
end: Object.assign({}, events[index2][1].start)
|
|
21956
22017
|
};
|
|
21957
|
-
const nextEvents = [["enter", strikethrough2, context], ["enter", events[open][1], context], ["exit", events[open][1], context], ["enter",
|
|
22018
|
+
const nextEvents = [["enter", strikethrough2, context], ["enter", events[open][1], context], ["exit", events[open][1], context], ["enter", text8, context]];
|
|
21958
22019
|
const insideSpan2 = context.parser.constructs.insideSpan.null;
|
|
21959
22020
|
if (insideSpan2) {
|
|
21960
22021
|
splice(nextEvents, nextEvents.length, 0, resolveAll(insideSpan2, events.slice(open + 1, index2), context));
|
|
21961
22022
|
}
|
|
21962
|
-
splice(nextEvents, nextEvents.length, 0, [["exit",
|
|
22023
|
+
splice(nextEvents, nextEvents.length, 0, [["exit", text8, context], ["enter", events[index2][1], context], ["exit", events[index2][1], context], ["exit", strikethrough2, context]]);
|
|
21963
22024
|
splice(events, open - 1, index2 - open + 3, nextEvents);
|
|
21964
22025
|
index2 = open + nextEvents.length - 2;
|
|
21965
22026
|
break;
|
|
@@ -22657,7 +22718,8 @@ var defaultAllowedTagNames = [
|
|
|
22657
22718
|
"h3",
|
|
22658
22719
|
"h4",
|
|
22659
22720
|
"h5",
|
|
22660
|
-
"h6"
|
|
22721
|
+
"h6",
|
|
22722
|
+
"ins"
|
|
22661
22723
|
];
|
|
22662
22724
|
function formatUrlForDisplay(url) {
|
|
22663
22725
|
try {
|
|
@@ -22680,24 +22742,24 @@ var markDownRenderers = {
|
|
|
22680
22742
|
emoji: Emoji,
|
|
22681
22743
|
mention: Mention
|
|
22682
22744
|
};
|
|
22683
|
-
var renderText = (
|
|
22745
|
+
var renderText = (text8, mentionedUsers, {
|
|
22684
22746
|
allowedTagNames = defaultAllowedTagNames,
|
|
22685
22747
|
customMarkDownRenderers,
|
|
22686
22748
|
getRehypePlugins = getPluginsForward,
|
|
22687
22749
|
getRemarkPlugins = getPluginsForward
|
|
22688
22750
|
} = {}) => {
|
|
22689
|
-
if (!
|
|
22690
|
-
if (
|
|
22691
|
-
let newText =
|
|
22751
|
+
if (!text8) return null;
|
|
22752
|
+
if (text8.trim().length === 1) return /* @__PURE__ */ import_react103.default.createElement(import_react103.default.Fragment, null, text8);
|
|
22753
|
+
let newText = text8;
|
|
22692
22754
|
const markdownLinks = matchMarkdownLinks(newText);
|
|
22693
22755
|
const codeBlocks = messageCodeBlocks(newText);
|
|
22694
22756
|
const links = [...(0, import_linkifyjs.find)(newText, "email"), ...(0, import_linkifyjs.find)(newText, "url")];
|
|
22695
22757
|
for (let i = links.length - 1; i >= 0; i--) {
|
|
22696
22758
|
const { end, href, start: start2, type, value } = links[i];
|
|
22697
22759
|
const linkIsInBlock = codeBlocks.some((block) => block?.includes(value));
|
|
22698
|
-
const noParsingNeeded = markdownLinks && markdownLinks.filter((
|
|
22760
|
+
const noParsingNeeded = markdownLinks && markdownLinks.filter((text9) => {
|
|
22699
22761
|
const strippedHref = href?.replace(detectHttp, "");
|
|
22700
|
-
const strippedText =
|
|
22762
|
+
const strippedText = text9?.replace(detectHttp, "");
|
|
22701
22763
|
if (!strippedHref || !strippedText) return false;
|
|
22702
22764
|
return strippedHref.includes(strippedText) || strippedText.includes(strippedHref);
|
|
22703
22765
|
});
|
|
@@ -22719,13 +22781,15 @@ var renderText = (text7, mentionedUsers, {
|
|
|
22719
22781
|
const remarkPlugins2 = [
|
|
22720
22782
|
htmlToTextPlugin,
|
|
22721
22783
|
keepLineBreaksPlugin,
|
|
22722
|
-
[remarkGfm, { singleTilde: false }]
|
|
22784
|
+
[remarkGfm, { singleTilde: false }],
|
|
22785
|
+
plusPlusToEmphasis,
|
|
22786
|
+
imageToLink
|
|
22723
22787
|
];
|
|
22724
22788
|
const rehypePlugins = [emojiMarkdownPlugin];
|
|
22725
22789
|
if (mentionedUsers?.length) {
|
|
22726
22790
|
rehypePlugins.push(mentionsMarkdownPlugin(mentionedUsers));
|
|
22727
22791
|
}
|
|
22728
|
-
return /* @__PURE__ */ import_react103.default.createElement(ErrorBoundary, { fallback: /* @__PURE__ */ import_react103.default.createElement(import_react103.default.Fragment, null,
|
|
22792
|
+
return /* @__PURE__ */ import_react103.default.createElement(ErrorBoundary, { fallback: /* @__PURE__ */ import_react103.default.createElement(import_react103.default.Fragment, null, text8) }, /* @__PURE__ */ import_react103.default.createElement(
|
|
22729
22793
|
Markdown,
|
|
22730
22794
|
{
|
|
22731
22795
|
allowedElements: allowedTagNames,
|
|
@@ -23495,7 +23559,7 @@ var import_clsx27 = __toESM(require("clsx"));
|
|
|
23495
23559
|
// src/components/Form/FieldError.tsx
|
|
23496
23560
|
var import_clsx26 = __toESM(require("clsx"));
|
|
23497
23561
|
var import_react119 = __toESM(require("react"));
|
|
23498
|
-
var FieldError = ({ className, text:
|
|
23562
|
+
var FieldError = ({ className, text: text8, ...props }) => /* @__PURE__ */ import_react119.default.createElement("div", { ...props, className: (0, import_clsx26.default)("str-chat__form-field-error", className) }, text8);
|
|
23499
23563
|
|
|
23500
23564
|
// src/components/Dialog/FormDialog.tsx
|
|
23501
23565
|
var FormDialog = ({
|
|
@@ -25096,11 +25160,11 @@ var StreamedMessageText = (props) => {
|
|
|
25096
25160
|
} = props;
|
|
25097
25161
|
const { message: messageFromContext } = useMessageContext("StreamedMessageText");
|
|
25098
25162
|
const message = messageFromProps || messageFromContext;
|
|
25099
|
-
const { text:
|
|
25163
|
+
const { text: text8 = "" } = message;
|
|
25100
25164
|
const { streamedMessageText } = useMessageTextStreaming({
|
|
25101
25165
|
renderingLetterCount,
|
|
25102
25166
|
streamingLetterIntervalMs,
|
|
25103
|
-
text:
|
|
25167
|
+
text: text8
|
|
25104
25168
|
});
|
|
25105
25169
|
return /* @__PURE__ */ import_react155.default.createElement(
|
|
25106
25170
|
MessageText,
|
|
@@ -29885,10 +29949,10 @@ var import_react175 = __toESM(require("react"));
|
|
|
29885
29949
|
var UnMemoizedEventComponent = (props) => {
|
|
29886
29950
|
const { Avatar: Avatar2 = Avatar, calendar: calendar3, calendarFormats, format, message } = props;
|
|
29887
29951
|
const { t, tDateTimeParser } = useTranslationContext("EventComponent");
|
|
29888
|
-
const { created_at = "", event, text:
|
|
29952
|
+
const { created_at = "", event, text: text8, type } = message;
|
|
29889
29953
|
const getDateOptions = { messageCreatedAt: created_at.toString(), tDateTimeParser };
|
|
29890
29954
|
if (type === "system")
|
|
29891
|
-
return /* @__PURE__ */ import_react175.default.createElement("div", { className: "str-chat__message--system", "data-testid": "message-system" }, /* @__PURE__ */ import_react175.default.createElement("div", { className: "str-chat__message--system__text" }, /* @__PURE__ */ import_react175.default.createElement("div", { className: "str-chat__message--system__line" }), /* @__PURE__ */ import_react175.default.createElement("p", null,
|
|
29955
|
+
return /* @__PURE__ */ import_react175.default.createElement("div", { className: "str-chat__message--system", "data-testid": "message-system" }, /* @__PURE__ */ import_react175.default.createElement("div", { className: "str-chat__message--system__text" }, /* @__PURE__ */ import_react175.default.createElement("div", { className: "str-chat__message--system__line" }), /* @__PURE__ */ import_react175.default.createElement("p", null, text8), /* @__PURE__ */ import_react175.default.createElement("div", { className: "str-chat__message--system__line" })), /* @__PURE__ */ import_react175.default.createElement("div", { className: "str-chat__message--system__date" }, /* @__PURE__ */ import_react175.default.createElement("strong", null, getDateString({
|
|
29892
29956
|
...getDateOptions,
|
|
29893
29957
|
calendar: calendar3,
|
|
29894
29958
|
calendarFormats,
|
|
@@ -31889,9 +31953,11 @@ var Message = (props) => {
|
|
|
31889
31953
|
// src/components/ChannelPreview/utils.tsx
|
|
31890
31954
|
var remarkPlugins = [
|
|
31891
31955
|
htmlToTextPlugin,
|
|
31892
|
-
[remarkGfm, { singleTilde: false }]
|
|
31956
|
+
[remarkGfm, { singleTilde: false }],
|
|
31957
|
+
plusPlusToEmphasis,
|
|
31958
|
+
imageToLink
|
|
31893
31959
|
];
|
|
31894
|
-
var renderPreviewText = (
|
|
31960
|
+
var renderPreviewText = (text8) => /* @__PURE__ */ import_react200.default.createElement(Markdown, { remarkPlugins, skipHtml: true }, text8);
|
|
31895
31961
|
var getLatestPollVote = (latestVotesByOption) => {
|
|
31896
31962
|
let latestVote;
|
|
31897
31963
|
for (const optionVotes of Object.values(latestVotesByOption)) {
|
|
@@ -35258,7 +35324,7 @@ var TextareaComposer = ({
|
|
|
35258
35324
|
const shouldSubmit = shouldSubmitProp ?? shouldSubmitContext ?? defaultShouldSubmit;
|
|
35259
35325
|
const messageComposer = useMessageComposer();
|
|
35260
35326
|
const { textComposer } = messageComposer;
|
|
35261
|
-
const { selection, suggestions, text:
|
|
35327
|
+
const { selection, suggestions, text: text8 } = useStateStore(
|
|
35262
35328
|
textComposer.state,
|
|
35263
35329
|
textComposerStateSelector2
|
|
35264
35330
|
);
|
|
@@ -35385,15 +35451,15 @@ var TextareaComposer = ({
|
|
|
35385
35451
|
(0, import_react256.useLayoutEffect)(() => {
|
|
35386
35452
|
const textarea = textareaRef.current;
|
|
35387
35453
|
if (!textarea || isComposing) return;
|
|
35388
|
-
if (textarea.value !==
|
|
35389
|
-
textarea.value =
|
|
35454
|
+
if (textarea.value !== text8) {
|
|
35455
|
+
textarea.value = text8;
|
|
35390
35456
|
}
|
|
35391
35457
|
const length = textarea.value.length;
|
|
35392
35458
|
const start2 = Math.max(0, Math.min(selection.start, length));
|
|
35393
35459
|
const end = Math.max(start2, Math.min(selection.end, length));
|
|
35394
35460
|
if (textarea.selectionStart === start2 && textarea.selectionEnd === end) return;
|
|
35395
35461
|
textarea.setSelectionRange(start2, end, "forward");
|
|
35396
|
-
}, [
|
|
35462
|
+
}, [text8, selection.start, selection.end, isComposing, textareaRef]);
|
|
35397
35463
|
return /* @__PURE__ */ import_react256.default.createElement(
|
|
35398
35464
|
"div",
|
|
35399
35465
|
{
|
|
@@ -36045,12 +36111,12 @@ var CardHeader = (props) => {
|
|
|
36045
36111
|
) : null;
|
|
36046
36112
|
};
|
|
36047
36113
|
var CardContent = (props) => {
|
|
36048
|
-
const { author_name, og_scrape_url, text:
|
|
36114
|
+
const { author_name, og_scrape_url, text: text8, title, title_link, type } = props;
|
|
36049
36115
|
const url = title_link || og_scrape_url;
|
|
36050
|
-
return /* @__PURE__ */ import_react266.default.createElement("div", { className: "str-chat__message-attachment-card--content" }, type === "audio" ? /* @__PURE__ */ import_react266.default.createElement(CardAudio, { og: props }) : /* @__PURE__ */ import_react266.default.createElement("div", { className: "str-chat__message-attachment-card--flex" }, url && /* @__PURE__ */ import_react266.default.createElement(SourceLink, { author_name, url }), title && /* @__PURE__ */ import_react266.default.createElement("div", { className: "str-chat__message-attachment-card--title" }, title),
|
|
36116
|
+
return /* @__PURE__ */ import_react266.default.createElement("div", { className: "str-chat__message-attachment-card--content" }, type === "audio" ? /* @__PURE__ */ import_react266.default.createElement(CardAudio, { og: props }) : /* @__PURE__ */ import_react266.default.createElement("div", { className: "str-chat__message-attachment-card--flex" }, url && /* @__PURE__ */ import_react266.default.createElement(SourceLink, { author_name, url }), title && /* @__PURE__ */ import_react266.default.createElement("div", { className: "str-chat__message-attachment-card--title" }, title), text8 && /* @__PURE__ */ import_react266.default.createElement("div", { className: "str-chat__message-attachment-card--text" }, text8)));
|
|
36051
36117
|
};
|
|
36052
36118
|
var CardAudio = ({
|
|
36053
|
-
og: { asset_url, author_name, mime_type, og_scrape_url, text:
|
|
36119
|
+
og: { asset_url, author_name, mime_type, og_scrape_url, text: text8, title, title_link }
|
|
36054
36120
|
}) => {
|
|
36055
36121
|
const { audioRef, isPlaying, progress, seek, togglePlay } = useAudioController({
|
|
36056
36122
|
mimeType: mime_type
|
|
@@ -36058,7 +36124,7 @@ var CardAudio = ({
|
|
|
36058
36124
|
const url = title_link || og_scrape_url;
|
|
36059
36125
|
const dataTestId = "card-audio-widget";
|
|
36060
36126
|
const rootClassName2 = "str-chat__message-attachment-card-audio-widget";
|
|
36061
|
-
return /* @__PURE__ */ import_react266.default.createElement("div", { className: rootClassName2, "data-testid": dataTestId }, asset_url && /* @__PURE__ */ import_react266.default.createElement(import_react266.default.Fragment, null, /* @__PURE__ */ import_react266.default.createElement("audio", { ref: audioRef }, /* @__PURE__ */ import_react266.default.createElement("source", { "data-testid": "audio-source", src: asset_url, type: "audio/mp3" })), /* @__PURE__ */ import_react266.default.createElement("div", { className: "str-chat__message-attachment-card-audio-widget--first-row" }, /* @__PURE__ */ import_react266.default.createElement("div", { className: "str-chat__message-attachment-audio-widget--play-controls" }, /* @__PURE__ */ import_react266.default.createElement(PlayButton, { isPlaying, onClick: togglePlay })), /* @__PURE__ */ import_react266.default.createElement(ProgressBar, { onClick: seek, progress }))), /* @__PURE__ */ import_react266.default.createElement("div", { className: "str-chat__message-attachment-audio-widget--second-row" }, url && /* @__PURE__ */ import_react266.default.createElement(SourceLink, { author_name, url }), title && /* @__PURE__ */ import_react266.default.createElement("div", { className: "str-chat__message-attachment-audio-widget--title" }, title),
|
|
36127
|
+
return /* @__PURE__ */ import_react266.default.createElement("div", { className: rootClassName2, "data-testid": dataTestId }, asset_url && /* @__PURE__ */ import_react266.default.createElement(import_react266.default.Fragment, null, /* @__PURE__ */ import_react266.default.createElement("audio", { ref: audioRef }, /* @__PURE__ */ import_react266.default.createElement("source", { "data-testid": "audio-source", src: asset_url, type: "audio/mp3" })), /* @__PURE__ */ import_react266.default.createElement("div", { className: "str-chat__message-attachment-card-audio-widget--first-row" }, /* @__PURE__ */ import_react266.default.createElement("div", { className: "str-chat__message-attachment-audio-widget--play-controls" }, /* @__PURE__ */ import_react266.default.createElement(PlayButton, { isPlaying, onClick: togglePlay })), /* @__PURE__ */ import_react266.default.createElement(ProgressBar, { onClick: seek, progress }))), /* @__PURE__ */ import_react266.default.createElement("div", { className: "str-chat__message-attachment-audio-widget--second-row" }, url && /* @__PURE__ */ import_react266.default.createElement(SourceLink, { author_name, url }), title && /* @__PURE__ */ import_react266.default.createElement("div", { className: "str-chat__message-attachment-audio-widget--title" }, title), text8 && /* @__PURE__ */ import_react266.default.createElement("div", { className: "str-chat__message-attachment-audio-widget--description" }, text8)));
|
|
36062
36128
|
};
|
|
36063
36129
|
var UnMemoizedCard = (props) => {
|
|
36064
36130
|
const { asset_url, giphy, image_url, thumb_url, title, title_link, type } = props;
|
|
@@ -36921,12 +36987,12 @@ var useChannelContainerClasses = ({
|
|
|
36921
36987
|
|
|
36922
36988
|
// src/components/Channel/utils.ts
|
|
36923
36989
|
var import_nanoid7 = require("nanoid");
|
|
36924
|
-
var makeAddNotifications = (setNotifications, notificationTimeouts) => (
|
|
36925
|
-
if (typeof
|
|
36990
|
+
var makeAddNotifications = (setNotifications, notificationTimeouts) => (text8, type) => {
|
|
36991
|
+
if (typeof text8 !== "string" || type !== "success" && type !== "error") {
|
|
36926
36992
|
return;
|
|
36927
36993
|
}
|
|
36928
36994
|
const id = (0, import_nanoid7.nanoid)();
|
|
36929
|
-
setNotifications((prevNotifications) => [...prevNotifications, { id, text:
|
|
36995
|
+
setNotifications((prevNotifications) => [...prevNotifications, { id, text: text8, type }]);
|
|
36930
36996
|
const timeout = setTimeout(
|
|
36931
36997
|
() => setNotifications(
|
|
36932
36998
|
(prevNotifications) => prevNotifications.filter((notification) => notification.id !== id)
|
|
@@ -38041,7 +38107,7 @@ var useChat = ({
|
|
|
38041
38107
|
};
|
|
38042
38108
|
(0, import_react282.useEffect)(() => {
|
|
38043
38109
|
if (!client) return;
|
|
38044
|
-
const version = "13.
|
|
38110
|
+
const version = "13.7.0";
|
|
38045
38111
|
const userAgent = client.getUserAgent();
|
|
38046
38112
|
if (!userAgent.includes("stream-chat-react")) {
|
|
38047
38113
|
client.setUserAgent(`stream-chat-react-${version}-${userAgent}`);
|
|
@@ -38549,6 +38615,7 @@ var Window = import_react287.default.memo(UnMemoizedWindow);
|
|
|
38549
38615
|
hasNotMoreMessages,
|
|
38550
38616
|
hiTranslations,
|
|
38551
38617
|
htmlToTextPlugin,
|
|
38618
|
+
imageToLink,
|
|
38552
38619
|
insertIntro,
|
|
38553
38620
|
isChannel,
|
|
38554
38621
|
isChannelArchived,
|
|
@@ -38590,6 +38657,7 @@ var Window = import_react287.default.memo(UnMemoizedWindow);
|
|
|
38590
38657
|
moveChannelUp,
|
|
38591
38658
|
moveChannelUpwards,
|
|
38592
38659
|
nlTranslations,
|
|
38660
|
+
plusPlusToEmphasis,
|
|
38593
38661
|
processMessages,
|
|
38594
38662
|
ptTranslations,
|
|
38595
38663
|
reactionHandlerWarning,
|