@liveblocks/core 3.19.0 → 3.19.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/index.cjs +7 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +7 -4
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -6,7 +6,7 @@ var __export = (target, all) => {
|
|
|
6
6
|
|
|
7
7
|
// src/version.ts
|
|
8
8
|
var PKG_NAME = "@liveblocks/core";
|
|
9
|
-
var PKG_VERSION = "3.19.
|
|
9
|
+
var PKG_VERSION = "3.19.2";
|
|
10
10
|
var PKG_FORMAT = "esm";
|
|
11
11
|
|
|
12
12
|
// src/dupe-detection.ts
|
|
@@ -9296,10 +9296,10 @@ function createRoom(options, config) {
|
|
|
9296
9296
|
// - The `backgroundKeepAliveTimeout` client option is configured
|
|
9297
9297
|
// - The browser window has been in the background for at least
|
|
9298
9298
|
// `backgroundKeepAliveTimeout` milliseconds
|
|
9299
|
-
// - There are no pending changes
|
|
9299
|
+
// - There are no pending changes scoped to this room (Storage, Yjs)
|
|
9300
9300
|
//
|
|
9301
9301
|
canZombie() {
|
|
9302
|
-
return config.backgroundKeepAliveTimeout !== void 0 && inBackgroundSince.current !== null && Date.now() > inBackgroundSince.current + config.backgroundKeepAliveTimeout &&
|
|
9302
|
+
return config.backgroundKeepAliveTimeout !== void 0 && inBackgroundSince.current !== null && Date.now() > inBackgroundSince.current + config.backgroundKeepAliveTimeout && syncSourceForStorage.getStatus() !== "synchronizing" && syncSourceForYjs.getStatus() !== "synchronizing";
|
|
9303
9303
|
}
|
|
9304
9304
|
};
|
|
9305
9305
|
const managedSocket = new ManagedSocket(
|
|
@@ -11394,6 +11394,9 @@ function createClient(options) {
|
|
|
11394
11394
|
function setSyncStatus(status) {
|
|
11395
11395
|
source.set(status);
|
|
11396
11396
|
}
|
|
11397
|
+
function getStatus() {
|
|
11398
|
+
return source.get();
|
|
11399
|
+
}
|
|
11397
11400
|
function destroy() {
|
|
11398
11401
|
unsub();
|
|
11399
11402
|
const index = syncStatusSources.findIndex((item) => item === source);
|
|
@@ -11405,7 +11408,7 @@ function createClient(options) {
|
|
|
11405
11408
|
}
|
|
11406
11409
|
}
|
|
11407
11410
|
}
|
|
11408
|
-
return { setSyncStatus, destroy };
|
|
11411
|
+
return { setSyncStatus, getStatus, destroy };
|
|
11409
11412
|
}
|
|
11410
11413
|
{
|
|
11411
11414
|
const maybePreventClose = (e) => {
|