stream-chat 9.36.0 → 9.36.2
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/cjs/index.browser.js +7 -2
- package/dist/cjs/index.browser.js.map +2 -2
- package/dist/cjs/index.node.js +7 -2
- package/dist/cjs/index.node.js.map +2 -2
- package/dist/esm/index.mjs +7 -2
- package/dist/esm/index.mjs.map +2 -2
- package/dist/types/client.d.ts +5 -0
- package/dist/types/types.d.ts +73 -4
- package/package.json +1 -1
- package/src/channel_state.ts +6 -1
- package/src/client.ts +5 -0
- package/src/types.ts +75 -4
|
@@ -1525,7 +1525,7 @@ var ChannelState = class {
|
|
|
1525
1525
|
if (message.user && this._channel?.cid) {
|
|
1526
1526
|
this._channel.getClient().state.updateUserReference(message.user, this._channel.cid);
|
|
1527
1527
|
}
|
|
1528
|
-
if (initializing && message.id && this.threads[message.id]) {
|
|
1528
|
+
if (initializing && message.id && this.threads[message.id] && !this._channel.getClient().preventThreadCleanup) {
|
|
1529
1529
|
delete this.threads[message.id];
|
|
1530
1530
|
}
|
|
1531
1531
|
const shouldSkipLastMessageAtUpdate = this._channel.getConfig()?.skip_last_msg_update_for_system_msgs && message.type === "system";
|
|
@@ -12750,6 +12750,11 @@ function isString2(x) {
|
|
|
12750
12750
|
}
|
|
12751
12751
|
var StreamChat = class _StreamChat {
|
|
12752
12752
|
constructor(key, secretOrOptions, options) {
|
|
12753
|
+
/**
|
|
12754
|
+
* If true, we will not clean up threads when channel state is in initializing state.
|
|
12755
|
+
* The main use case for SDKs who do independent state recovery for channels.
|
|
12756
|
+
*/
|
|
12757
|
+
this.preventThreadCleanup = false;
|
|
12753
12758
|
this.nextRequestAbortController = null;
|
|
12754
12759
|
/**
|
|
12755
12760
|
* @private
|
|
@@ -15108,7 +15113,7 @@ var StreamChat = class _StreamChat {
|
|
|
15108
15113
|
if (this.userAgent) {
|
|
15109
15114
|
return this.userAgent;
|
|
15110
15115
|
}
|
|
15111
|
-
const version = "9.36.
|
|
15116
|
+
const version = "9.36.2";
|
|
15112
15117
|
const clientBundle = "browser-cjs";
|
|
15113
15118
|
let userAgentString = "";
|
|
15114
15119
|
if (this.sdkIdentifier) {
|