@liveblocks/react 3.13.1-hackathon → 3.13.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/_private.cjs +7 -7
- package/dist/_private.d.cts +2 -2
- package/dist/_private.d.ts +2 -2
- package/dist/_private.js +1 -1
- package/dist/{chunk-73OAUQFM.cjs → chunk-2KKSJSO6.cjs} +2 -2
- package/dist/chunk-2KKSJSO6.cjs.map +1 -0
- package/dist/{chunk-VSUKKNOK.js → chunk-ERRJHA6O.js} +2 -256
- package/dist/chunk-ERRJHA6O.js.map +1 -0
- package/dist/{chunk-JXNC4PPG.cjs → chunk-QFAOGFJK.cjs} +40 -294
- package/dist/chunk-QFAOGFJK.cjs.map +1 -0
- package/dist/{chunk-A3DIFDDH.js → chunk-SRBVM766.js} +2 -2
- package/dist/index.cjs +4 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +2 -6
- package/dist/index.js.map +1 -1
- package/dist/{room-CVCL9bCW.d.cts → room-CEMGQ1Mj.d.cts} +2 -88
- package/dist/{room-CVCL9bCW.d.ts → room-CEMGQ1Mj.d.ts} +2 -88
- package/dist/suspense.cjs +4 -4
- package/dist/suspense.d.cts +1 -1
- package/dist/suspense.d.ts +1 -1
- package/dist/suspense.js +2 -2
- package/package.json +3 -3
- package/dist/chunk-73OAUQFM.cjs.map +0 -1
- package/dist/chunk-JXNC4PPG.cjs.map +0 -1
- package/dist/chunk-VSUKKNOK.js.map +0 -1
- /package/dist/{chunk-A3DIFDDH.js.map → chunk-SRBVM766.js.map} +0 -0
|
@@ -512,12 +512,6 @@ function makeAiChatsQueryKey(query) {
|
|
|
512
512
|
function makeInboxNotificationsQueryKey(query) {
|
|
513
513
|
return _core.stableStringify.call(void 0, _nullishCoalesce(query, () => ( {})));
|
|
514
514
|
}
|
|
515
|
-
function makeAgentSessionsQueryKey(roomId, options) {
|
|
516
|
-
return _core.stableStringify.call(void 0, [roomId, _nullishCoalesce(options, () => ( {}))]);
|
|
517
|
-
}
|
|
518
|
-
function makeAgentMessagesQueryKey(roomId, sessionId, options) {
|
|
519
|
-
return _core.stableStringify.call(void 0, [roomId, sessionId, _nullishCoalesce(options, () => ( {}))]);
|
|
520
|
-
}
|
|
521
515
|
function usify(promise) {
|
|
522
516
|
if ("status" in promise) {
|
|
523
517
|
return promise;
|
|
@@ -984,19 +978,6 @@ var UmbrellaStore = class {
|
|
|
984
978
|
#roomVersionsLastRequestedAtByRoom = /* @__PURE__ */ new Map();
|
|
985
979
|
// Notification Settings
|
|
986
980
|
#notificationSettings;
|
|
987
|
-
// Agent Sessions
|
|
988
|
-
#roomsByRoomId = /* @__PURE__ */ new Map();
|
|
989
|
-
// TODO: the need for this seems wrong, i need to explore if maybe this stuff belongs in in RoomContext and not here
|
|
990
|
-
#agentSessionsByRoomId = /* @__PURE__ */ new Map();
|
|
991
|
-
#agentMessagesBySessionId = /* @__PURE__ */ new Map();
|
|
992
|
-
// Signals for agent sessions and messages to trigger reactivity
|
|
993
|
-
// We use a version counter to track changes
|
|
994
|
-
#agentSessionsSignal = new (0, _core.MutableSignal)({
|
|
995
|
-
version: 0
|
|
996
|
-
});
|
|
997
|
-
#agentMessagesSignal = new (0, _core.MutableSignal)({
|
|
998
|
-
version: 0
|
|
999
|
-
});
|
|
1000
981
|
constructor(client) {
|
|
1001
982
|
this.#client = client[_core.kInternal].as();
|
|
1002
983
|
this.optimisticUpdates = createStore_forOptimistic(this.#client);
|
|
@@ -1368,94 +1349,6 @@ var UmbrellaStore = class {
|
|
|
1368
1349
|
return { signal, waitUntilLoaded: resource.waitUntilLoaded };
|
|
1369
1350
|
}
|
|
1370
1351
|
);
|
|
1371
|
-
const loadingAgentSessions = new (0, _core.DefaultMap)(
|
|
1372
|
-
(queryKey) => {
|
|
1373
|
-
const [roomId, options] = JSON.parse(queryKey);
|
|
1374
|
-
const resource = new PaginatedResource(async (cursor) => {
|
|
1375
|
-
const room = this.#roomsByRoomId.get(roomId);
|
|
1376
|
-
if (!room) {
|
|
1377
|
-
throw new Error(
|
|
1378
|
-
`Room ${roomId} not found. Make sure you're calling useAgentSessions inside a RoomProvider.`
|
|
1379
|
-
);
|
|
1380
|
-
}
|
|
1381
|
-
const typedRoom = room;
|
|
1382
|
-
const result = await typedRoom.fetchAgentSessions({
|
|
1383
|
-
cursor,
|
|
1384
|
-
since: _optionalChain([options, 'optionalAccess', _8 => _8.since]),
|
|
1385
|
-
metadata: _optionalChain([options, 'optionalAccess', _9 => _9.metadata])
|
|
1386
|
-
});
|
|
1387
|
-
this.updateAgentSessions(roomId, result.sessions, "list");
|
|
1388
|
-
return _nullishCoalesce(result.nextCursor, () => ( null));
|
|
1389
|
-
});
|
|
1390
|
-
const signal = _core.DerivedSignal.from(
|
|
1391
|
-
resource.signal,
|
|
1392
|
-
this.#agentSessionsSignal,
|
|
1393
|
-
(resourceResult, _signalState) => {
|
|
1394
|
-
if (resourceResult.isLoading || resourceResult.error) {
|
|
1395
|
-
return resourceResult;
|
|
1396
|
-
}
|
|
1397
|
-
const sessionsMap = this.#agentSessionsByRoomId.get(roomId);
|
|
1398
|
-
const sessions = sessionsMap ? Array.from(sessionsMap.values()) : [];
|
|
1399
|
-
const page = resourceResult.data;
|
|
1400
|
-
return {
|
|
1401
|
-
isLoading: false,
|
|
1402
|
-
sessions,
|
|
1403
|
-
hasFetchedAll: page.hasFetchedAll,
|
|
1404
|
-
isFetchingMore: page.isFetchingMore,
|
|
1405
|
-
fetchMoreError: page.fetchMoreError,
|
|
1406
|
-
fetchMore: page.fetchMore
|
|
1407
|
-
};
|
|
1408
|
-
},
|
|
1409
|
-
_core.shallow2
|
|
1410
|
-
);
|
|
1411
|
-
return { signal, waitUntilLoaded: resource.waitUntilLoaded };
|
|
1412
|
-
}
|
|
1413
|
-
);
|
|
1414
|
-
const loadingAgentMessages = new (0, _core.DefaultMap)(
|
|
1415
|
-
(queryKey) => {
|
|
1416
|
-
const [roomId, sessionId, options] = JSON.parse(queryKey);
|
|
1417
|
-
const resource = new PaginatedResource(async (cursor) => {
|
|
1418
|
-
const room = this.#roomsByRoomId.get(roomId);
|
|
1419
|
-
if (!room) {
|
|
1420
|
-
throw new Error(
|
|
1421
|
-
`Room ${roomId} not found. Make sure you're calling useAgentSession inside a RoomProvider.`
|
|
1422
|
-
);
|
|
1423
|
-
}
|
|
1424
|
-
const typedRoom = room;
|
|
1425
|
-
const result = await typedRoom.fetchAgentMessages(sessionId, {
|
|
1426
|
-
cursor,
|
|
1427
|
-
limit: _optionalChain([options, 'optionalAccess', _10 => _10.limit])
|
|
1428
|
-
});
|
|
1429
|
-
this.updateAgentMessages(roomId, sessionId, result.messages, "list");
|
|
1430
|
-
return _nullishCoalesce(result.nextCursor, () => ( null));
|
|
1431
|
-
});
|
|
1432
|
-
const signal = _core.DerivedSignal.from(
|
|
1433
|
-
resource.signal,
|
|
1434
|
-
this.#agentMessagesSignal,
|
|
1435
|
-
(resourceResult, _signalState) => {
|
|
1436
|
-
if (resourceResult.isLoading || resourceResult.error) {
|
|
1437
|
-
return resourceResult;
|
|
1438
|
-
}
|
|
1439
|
-
const messagesMap = this.#agentMessagesBySessionId.get(sessionId);
|
|
1440
|
-
const messages = messagesMap ? Array.from(messagesMap.values()).sort(
|
|
1441
|
-
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
|
|
1442
|
-
(a, b) => a.timestamp - b.timestamp
|
|
1443
|
-
) : [];
|
|
1444
|
-
const page = resourceResult.data;
|
|
1445
|
-
return {
|
|
1446
|
-
isLoading: false,
|
|
1447
|
-
messages,
|
|
1448
|
-
hasFetchedAll: page.hasFetchedAll,
|
|
1449
|
-
isFetchingMore: page.isFetchingMore,
|
|
1450
|
-
fetchMoreError: page.fetchMoreError,
|
|
1451
|
-
fetchMore: page.fetchMore
|
|
1452
|
-
};
|
|
1453
|
-
},
|
|
1454
|
-
_core.shallow2
|
|
1455
|
-
);
|
|
1456
|
-
return { signal, waitUntilLoaded: resource.waitUntilLoaded };
|
|
1457
|
-
}
|
|
1458
|
-
);
|
|
1459
1352
|
this.outputs = {
|
|
1460
1353
|
threadifications,
|
|
1461
1354
|
threads,
|
|
@@ -1471,9 +1364,7 @@ var UmbrellaStore = class {
|
|
|
1471
1364
|
aiChats,
|
|
1472
1365
|
messagesByChatId,
|
|
1473
1366
|
aiChatById,
|
|
1474
|
-
urlMetadataByUrl
|
|
1475
|
-
loadingAgentSessions,
|
|
1476
|
-
loadingAgentMessages
|
|
1367
|
+
urlMetadataByUrl
|
|
1477
1368
|
};
|
|
1478
1369
|
autobind(this);
|
|
1479
1370
|
}
|
|
@@ -1694,61 +1585,6 @@ var UmbrellaStore = class {
|
|
|
1694
1585
|
result.subscriptions.deleted
|
|
1695
1586
|
);
|
|
1696
1587
|
}
|
|
1697
|
-
/**
|
|
1698
|
-
* Registers a room instance for agent session fetching.
|
|
1699
|
-
* Called by RoomProvider when it mounts.
|
|
1700
|
-
*/
|
|
1701
|
-
registerRoom(roomId, room) {
|
|
1702
|
-
this.#roomsByRoomId.set(roomId, room);
|
|
1703
|
-
}
|
|
1704
|
-
/**
|
|
1705
|
-
* Unregisters a room instance.
|
|
1706
|
-
* Called by RoomProvider when it unmounts.
|
|
1707
|
-
*/
|
|
1708
|
-
unregisterRoom(roomId) {
|
|
1709
|
-
this.#roomsByRoomId.delete(roomId);
|
|
1710
|
-
this.#agentSessionsByRoomId.delete(roomId);
|
|
1711
|
-
}
|
|
1712
|
-
/**
|
|
1713
|
-
* Updates the agent sessions cache based on WebSocket events.
|
|
1714
|
-
*/
|
|
1715
|
-
updateAgentSessions(roomId, sessions, operation) {
|
|
1716
|
-
let sessionsMap = this.#agentSessionsByRoomId.get(roomId);
|
|
1717
|
-
if (!sessionsMap) {
|
|
1718
|
-
sessionsMap = /* @__PURE__ */ new Map();
|
|
1719
|
-
this.#agentSessionsByRoomId.set(roomId, sessionsMap);
|
|
1720
|
-
}
|
|
1721
|
-
for (const session of sessions) {
|
|
1722
|
-
if (operation === "deleted") {
|
|
1723
|
-
sessionsMap.delete(session.sessionId);
|
|
1724
|
-
} else {
|
|
1725
|
-
sessionsMap.set(session.sessionId, session);
|
|
1726
|
-
}
|
|
1727
|
-
}
|
|
1728
|
-
this.#agentSessionsSignal.mutate((state) => {
|
|
1729
|
-
state.version++;
|
|
1730
|
-
});
|
|
1731
|
-
}
|
|
1732
|
-
/**
|
|
1733
|
-
* Updates the agent messages cache based on WebSocket events.
|
|
1734
|
-
*/
|
|
1735
|
-
updateAgentMessages(_roomId, sessionId, messages, operation) {
|
|
1736
|
-
let messagesMap = this.#agentMessagesBySessionId.get(sessionId);
|
|
1737
|
-
if (!messagesMap) {
|
|
1738
|
-
messagesMap = /* @__PURE__ */ new Map();
|
|
1739
|
-
this.#agentMessagesBySessionId.set(sessionId, messagesMap);
|
|
1740
|
-
}
|
|
1741
|
-
for (const message of messages) {
|
|
1742
|
-
if (operation === "deleted") {
|
|
1743
|
-
messagesMap.delete(message.id);
|
|
1744
|
-
} else {
|
|
1745
|
-
messagesMap.set(message.id, message);
|
|
1746
|
-
}
|
|
1747
|
-
}
|
|
1748
|
-
this.#agentMessagesSignal.mutate((state) => {
|
|
1749
|
-
state.version++;
|
|
1750
|
-
});
|
|
1751
|
-
}
|
|
1752
1588
|
async fetchUnreadNotificationsCount(queryKey, signal) {
|
|
1753
1589
|
const query = JSON.parse(queryKey);
|
|
1754
1590
|
const result = await this.#client.getUnreadInboxNotificationsCount({
|
|
@@ -2159,7 +1995,7 @@ function applyUpsertComment(thread, comment) {
|
|
|
2159
1995
|
updatedAt: new Date(
|
|
2160
1996
|
Math.max(
|
|
2161
1997
|
thread.updatedAt.getTime(),
|
|
2162
|
-
_optionalChain([comment, 'access',
|
|
1998
|
+
_optionalChain([comment, 'access', _8 => _8.editedAt, 'optionalAccess', _9 => _9.getTime, 'call', _10 => _10()]) || comment.createdAt.getTime()
|
|
2163
1999
|
)
|
|
2164
2000
|
),
|
|
2165
2001
|
comments: updatedComments
|
|
@@ -2316,7 +2152,7 @@ function selectorFor_useUnreadInboxNotificationsCount(result) {
|
|
|
2316
2152
|
return ASYNC_OK("count", result.count);
|
|
2317
2153
|
}
|
|
2318
2154
|
function selectorFor_useUser(state, userId) {
|
|
2319
|
-
if (state === void 0 || _optionalChain([state, 'optionalAccess',
|
|
2155
|
+
if (state === void 0 || _optionalChain([state, 'optionalAccess', _11 => _11.isLoading])) {
|
|
2320
2156
|
return _nullishCoalesce(state, () => ( { isLoading: true }));
|
|
2321
2157
|
}
|
|
2322
2158
|
if (state.error) {
|
|
@@ -2334,7 +2170,7 @@ function selectorFor_useUser(state, userId) {
|
|
|
2334
2170
|
};
|
|
2335
2171
|
}
|
|
2336
2172
|
function selectorFor_useRoomInfo(state, roomId) {
|
|
2337
|
-
if (state === void 0 || _optionalChain([state, 'optionalAccess',
|
|
2173
|
+
if (state === void 0 || _optionalChain([state, 'optionalAccess', _12 => _12.isLoading])) {
|
|
2338
2174
|
return _nullishCoalesce(state, () => ( { isLoading: true }));
|
|
2339
2175
|
}
|
|
2340
2176
|
if (state.error) {
|
|
@@ -2352,7 +2188,7 @@ function selectorFor_useRoomInfo(state, roomId) {
|
|
|
2352
2188
|
};
|
|
2353
2189
|
}
|
|
2354
2190
|
function selectorFor_useGroupInfo(state, groupId) {
|
|
2355
|
-
if (state === void 0 || _optionalChain([state, 'optionalAccess',
|
|
2191
|
+
if (state === void 0 || _optionalChain([state, 'optionalAccess', _13 => _13.isLoading])) {
|
|
2356
2192
|
return _nullishCoalesce(state, () => ( { isLoading: true }));
|
|
2357
2193
|
}
|
|
2358
2194
|
if (state.error) {
|
|
@@ -2522,7 +2358,7 @@ function makeLiveblocksContextBundle(client) {
|
|
|
2522
2358
|
}
|
|
2523
2359
|
function useInboxNotifications_withClient(client, selector, isEqual, options) {
|
|
2524
2360
|
const { store, notificationsPoller: poller } = getLiveblocksExtrasForClient(client);
|
|
2525
|
-
const queryKey = makeInboxNotificationsQueryKey(_optionalChain([options, 'optionalAccess',
|
|
2361
|
+
const queryKey = makeInboxNotificationsQueryKey(_optionalChain([options, 'optionalAccess', _14 => _14.query]));
|
|
2526
2362
|
_react.useEffect.call(void 0,
|
|
2527
2363
|
() => void store.outputs.loadingNotifications.getOrCreate(queryKey).waitUntilLoaded()
|
|
2528
2364
|
// NOTE: Deliberately *not* using a dependency array here!
|
|
@@ -2550,7 +2386,7 @@ function useInboxNotifications_withClient(client, selector, isEqual, options) {
|
|
|
2550
2386
|
function useInboxNotificationsSuspense_withClient(client, options) {
|
|
2551
2387
|
ensureNotServerSide();
|
|
2552
2388
|
const store = getLiveblocksExtrasForClient(client).store;
|
|
2553
|
-
const queryKey = makeInboxNotificationsQueryKey(_optionalChain([options, 'optionalAccess',
|
|
2389
|
+
const queryKey = makeInboxNotificationsQueryKey(_optionalChain([options, 'optionalAccess', _15 => _15.query]));
|
|
2554
2390
|
use(
|
|
2555
2391
|
store.outputs.loadingNotifications.getOrCreate(queryKey).waitUntilLoaded()
|
|
2556
2392
|
);
|
|
@@ -2566,7 +2402,7 @@ function useInboxNotificationsSuspense_withClient(client, options) {
|
|
|
2566
2402
|
}
|
|
2567
2403
|
function useUnreadInboxNotificationsCount_withClient(client, options) {
|
|
2568
2404
|
const { store, unreadNotificationsCountPollersByQueryKey: pollers } = getLiveblocksExtrasForClient(client);
|
|
2569
|
-
const queryKey = makeInboxNotificationsQueryKey(_optionalChain([options, 'optionalAccess',
|
|
2405
|
+
const queryKey = makeInboxNotificationsQueryKey(_optionalChain([options, 'optionalAccess', _16 => _16.query]));
|
|
2570
2406
|
const poller = pollers.getOrCreate(queryKey);
|
|
2571
2407
|
_react.useEffect.call(void 0,
|
|
2572
2408
|
() => void store.outputs.unreadNotificationsCount.getOrCreate(queryKey).waitUntilLoaded()
|
|
@@ -2595,7 +2431,7 @@ function useUnreadInboxNotificationsCount_withClient(client, options) {
|
|
|
2595
2431
|
function useUnreadInboxNotificationsCountSuspense_withClient(client, options) {
|
|
2596
2432
|
ensureNotServerSide();
|
|
2597
2433
|
const store = getLiveblocksExtrasForClient(client).store;
|
|
2598
|
-
const queryKey = makeInboxNotificationsQueryKey(_optionalChain([options, 'optionalAccess',
|
|
2434
|
+
const queryKey = makeInboxNotificationsQueryKey(_optionalChain([options, 'optionalAccess', _17 => _17.query]));
|
|
2599
2435
|
use(
|
|
2600
2436
|
store.outputs.unreadNotificationsCount.getOrCreate(queryKey).waitUntilLoaded()
|
|
2601
2437
|
);
|
|
@@ -2766,7 +2602,7 @@ function useUpdateNotificationSettings_withClient(client) {
|
|
|
2766
2602
|
store.optimisticUpdates.remove(optimisticUpdateId);
|
|
2767
2603
|
if (err instanceof _core.HttpError) {
|
|
2768
2604
|
if (err.status === 422) {
|
|
2769
|
-
const msg = [_optionalChain([err, 'access',
|
|
2605
|
+
const msg = [_optionalChain([err, 'access', _18 => _18.details, 'optionalAccess', _19 => _19.error]), _optionalChain([err, 'access', _20 => _20.details, 'optionalAccess', _21 => _21.reason])].filter(Boolean).join("\n");
|
|
2770
2606
|
_core.console.error(msg);
|
|
2771
2607
|
}
|
|
2772
2608
|
client[_core.kInternal].emitError(
|
|
@@ -3001,7 +2837,7 @@ function useGroupInfoSuspense_withClient(client, groupId) {
|
|
|
3001
2837
|
function useAiChats(options) {
|
|
3002
2838
|
const client = useClient();
|
|
3003
2839
|
const store = getUmbrellaStoreForClient(client);
|
|
3004
|
-
const queryKey = makeAiChatsQueryKey(_optionalChain([options, 'optionalAccess',
|
|
2840
|
+
const queryKey = makeAiChatsQueryKey(_optionalChain([options, 'optionalAccess', _22 => _22.query]));
|
|
3005
2841
|
useEnsureAiConnection(client);
|
|
3006
2842
|
_react.useEffect.call(void 0,
|
|
3007
2843
|
() => void store.outputs.aiChats.getOrCreate(queryKey).waitUntilLoaded()
|
|
@@ -3025,7 +2861,7 @@ function useAiChatsSuspense(options) {
|
|
|
3025
2861
|
const client = useClient();
|
|
3026
2862
|
const store = getUmbrellaStoreForClient(client);
|
|
3027
2863
|
useEnsureAiConnection(client);
|
|
3028
|
-
const queryKey = makeAiChatsQueryKey(_optionalChain([options, 'optionalAccess',
|
|
2864
|
+
const queryKey = makeAiChatsQueryKey(_optionalChain([options, 'optionalAccess', _23 => _23.query]));
|
|
3029
2865
|
use(store.outputs.aiChats.getOrCreate(queryKey).waitUntilLoaded());
|
|
3030
2866
|
const result = useAiChats(options);
|
|
3031
2867
|
_core.assert.call(void 0, !result.error, "Did not expect error");
|
|
@@ -3037,7 +2873,7 @@ function useAiChatMessages(chatId, options) {
|
|
|
3037
2873
|
const store = getUmbrellaStoreForClient(client);
|
|
3038
2874
|
useEnsureAiConnection(client);
|
|
3039
2875
|
_react.useEffect.call(void 0,
|
|
3040
|
-
() => void store.outputs.messagesByChatId.getOrCreate(chatId).getOrCreate(_nullishCoalesce(_optionalChain([options, 'optionalAccess',
|
|
2876
|
+
() => void store.outputs.messagesByChatId.getOrCreate(chatId).getOrCreate(_nullishCoalesce(_optionalChain([options, 'optionalAccess', _24 => _24.branchId]), () => ( null))).waitUntilLoaded()
|
|
3041
2877
|
// NOTE: Deliberately *not* using a dependency array here!
|
|
3042
2878
|
//
|
|
3043
2879
|
// It is important to call waitUntil on *every* render.
|
|
@@ -3048,7 +2884,7 @@ function useAiChatMessages(chatId, options) {
|
|
|
3048
2884
|
// *next* render after that, a *new* fetch/promise will get created.
|
|
3049
2885
|
);
|
|
3050
2886
|
return useSignal(
|
|
3051
|
-
store.outputs.messagesByChatId.getOrCreate(chatId).getOrCreate(_nullishCoalesce(_optionalChain([options, 'optionalAccess',
|
|
2887
|
+
store.outputs.messagesByChatId.getOrCreate(chatId).getOrCreate(_nullishCoalesce(_optionalChain([options, 'optionalAccess', _25 => _25.branchId]), () => ( null))).signal
|
|
3052
2888
|
);
|
|
3053
2889
|
}
|
|
3054
2890
|
function useAiChatMessagesSuspense(chatId, options) {
|
|
@@ -3057,7 +2893,7 @@ function useAiChatMessagesSuspense(chatId, options) {
|
|
|
3057
2893
|
const store = getUmbrellaStoreForClient(client);
|
|
3058
2894
|
useEnsureAiConnection(client);
|
|
3059
2895
|
use(
|
|
3060
|
-
store.outputs.messagesByChatId.getOrCreate(chatId).getOrCreate(_nullishCoalesce(_optionalChain([options, 'optionalAccess',
|
|
2896
|
+
store.outputs.messagesByChatId.getOrCreate(chatId).getOrCreate(_nullishCoalesce(_optionalChain([options, 'optionalAccess', _26 => _26.branchId]), () => ( null))).waitUntilLoaded()
|
|
3061
2897
|
);
|
|
3062
2898
|
const result = useAiChatMessages(chatId, options);
|
|
3063
2899
|
_core.assert.call(void 0, !result.error, "Did not expect error");
|
|
@@ -3176,12 +3012,12 @@ function useAiChatStatus(chatId, branchId) {
|
|
|
3176
3012
|
if (result.error) return IDLE;
|
|
3177
3013
|
const messages = result.messages;
|
|
3178
3014
|
const lastMessage = messages[messages.length - 1];
|
|
3179
|
-
if (_optionalChain([lastMessage, 'optionalAccess',
|
|
3015
|
+
if (_optionalChain([lastMessage, 'optionalAccess', _27 => _27.role]) !== "assistant") return IDLE;
|
|
3180
3016
|
if (lastMessage.status !== "generating" && lastMessage.status !== "awaiting-tool")
|
|
3181
3017
|
return IDLE;
|
|
3182
3018
|
const contentSoFar = lastMessage.contentSoFar;
|
|
3183
3019
|
const lastPart = contentSoFar[contentSoFar.length - 1];
|
|
3184
|
-
if (_optionalChain([lastPart, 'optionalAccess',
|
|
3020
|
+
if (_optionalChain([lastPart, 'optionalAccess', _28 => _28.type]) === "tool-invocation") {
|
|
3185
3021
|
return {
|
|
3186
3022
|
status: "generating",
|
|
3187
3023
|
partType: "tool-invocation",
|
|
@@ -3190,7 +3026,7 @@ function useAiChatStatus(chatId, branchId) {
|
|
|
3190
3026
|
} else {
|
|
3191
3027
|
return {
|
|
3192
3028
|
status: "generating",
|
|
3193
|
-
partType: _optionalChain([lastPart, 'optionalAccess',
|
|
3029
|
+
partType: _optionalChain([lastPart, 'optionalAccess', _29 => _29.type])
|
|
3194
3030
|
};
|
|
3195
3031
|
}
|
|
3196
3032
|
},
|
|
@@ -3218,7 +3054,7 @@ function useSendAiMessage(chatId, options) {
|
|
|
3218
3054
|
"chatId must be provided to either `useSendAiMessage` or its returned function."
|
|
3219
3055
|
)));
|
|
3220
3056
|
const messages = client[_core.kInternal].ai.signals.getChatMessagesForBranch\u03A3(resolvedChatId).get();
|
|
3221
|
-
if (process.env.NODE_ENV !== "production" && !messageOptionsCopilotId && !_optionalChain([options, 'optionalAccess',
|
|
3057
|
+
if (process.env.NODE_ENV !== "production" && !messageOptionsCopilotId && !_optionalChain([options, 'optionalAccess', _30 => _30.copilotId])) {
|
|
3222
3058
|
_core.console.warn(
|
|
3223
3059
|
`No copilot ID was provided to useSendAiMessage when sending the message "${messageText.slice(
|
|
3224
3060
|
0,
|
|
@@ -3230,8 +3066,8 @@ To ensure the correct copilot ID is used, specify it either through the hook as
|
|
|
3230
3066
|
)}\u2026", copilotId: "co_xxx" })'`
|
|
3231
3067
|
);
|
|
3232
3068
|
}
|
|
3233
|
-
const resolvedCopilotId = _nullishCoalesce(_nullishCoalesce(messageOptionsCopilotId, () => ( _optionalChain([options, 'optionalAccess',
|
|
3234
|
-
const lastMessageId = _nullishCoalesce(_optionalChain([messages, 'access',
|
|
3069
|
+
const resolvedCopilotId = _nullishCoalesce(_nullishCoalesce(messageOptionsCopilotId, () => ( _optionalChain([options, 'optionalAccess', _31 => _31.copilotId]))), () => ( client[_core.kInternal].ai.getLastUsedCopilotId(resolvedChatId)));
|
|
3070
|
+
const lastMessageId = _nullishCoalesce(_optionalChain([messages, 'access', _32 => _32[messages.length - 1], 'optionalAccess', _33 => _33.id]), () => ( null));
|
|
3235
3071
|
const content = [{ type: "text", text: messageText }];
|
|
3236
3072
|
const newMessageId = client[_core.kInternal].ai[_core.kInternal].context.messagesStore.createOptimistically(
|
|
3237
3073
|
resolvedChatId,
|
|
@@ -3251,14 +3087,14 @@ To ensure the correct copilot ID is used, specify it either through the hook as
|
|
|
3251
3087
|
{ id: newMessageId, parentMessageId: lastMessageId, content },
|
|
3252
3088
|
targetMessageId,
|
|
3253
3089
|
{
|
|
3254
|
-
stream: _nullishCoalesce(messageOptions.stream, () => ( _optionalChain([options, 'optionalAccess',
|
|
3090
|
+
stream: _nullishCoalesce(messageOptions.stream, () => ( _optionalChain([options, 'optionalAccess', _34 => _34.stream]))),
|
|
3255
3091
|
copilotId: resolvedCopilotId,
|
|
3256
|
-
timeout: _nullishCoalesce(messageOptions.timeout, () => ( _optionalChain([options, 'optionalAccess',
|
|
3092
|
+
timeout: _nullishCoalesce(messageOptions.timeout, () => ( _optionalChain([options, 'optionalAccess', _35 => _35.timeout])))
|
|
3257
3093
|
}
|
|
3258
3094
|
);
|
|
3259
3095
|
return newMessage;
|
|
3260
3096
|
},
|
|
3261
|
-
[client, chatId, _optionalChain([options, 'optionalAccess',
|
|
3097
|
+
[client, chatId, _optionalChain([options, 'optionalAccess', _36 => _36.copilotId]), _optionalChain([options, 'optionalAccess', _37 => _37.stream]), _optionalChain([options, 'optionalAccess', _38 => _38.timeout])]
|
|
3262
3098
|
);
|
|
3263
3099
|
}
|
|
3264
3100
|
function createSharedContext(client) {
|
|
@@ -3293,7 +3129,7 @@ function createSharedContext(client) {
|
|
|
3293
3129
|
}
|
|
3294
3130
|
function useEnsureNoLiveblocksProvider(options) {
|
|
3295
3131
|
const existing = useClientOrNull();
|
|
3296
|
-
if (!_optionalChain([options, 'optionalAccess',
|
|
3132
|
+
if (!_optionalChain([options, 'optionalAccess', _39 => _39.allowNesting]) && existing !== null) {
|
|
3297
3133
|
throw new Error(
|
|
3298
3134
|
"You cannot nest multiple LiveblocksProvider instances in the same React tree."
|
|
3299
3135
|
);
|
|
@@ -3460,7 +3296,7 @@ var _useAiChatMessagesSuspense = useAiChatMessagesSuspense;
|
|
|
3460
3296
|
var _useUrlMetadata = useUrlMetadata;
|
|
3461
3297
|
var _useUrlMetadataSuspense = useUrlMetadataSuspense;
|
|
3462
3298
|
function useSyncStatus_withClient(client, options) {
|
|
3463
|
-
const smooth = useInitial(_nullishCoalesce(_optionalChain([options, 'optionalAccess',
|
|
3299
|
+
const smooth = useInitial(_nullishCoalesce(_optionalChain([options, 'optionalAccess', _40 => _40.smooth]), () => ( false)));
|
|
3464
3300
|
if (smooth) {
|
|
3465
3301
|
return useSyncStatusSmooth_withClient(client);
|
|
3466
3302
|
} else {
|
|
@@ -3640,8 +3476,8 @@ function makeRoomExtrasForClient(client) {
|
|
|
3640
3476
|
if (innerError.status === 403) {
|
|
3641
3477
|
const detailedMessage = [
|
|
3642
3478
|
innerError.message,
|
|
3643
|
-
_optionalChain([innerError, 'access',
|
|
3644
|
-
_optionalChain([innerError, 'access',
|
|
3479
|
+
_optionalChain([innerError, 'access', _41 => _41.details, 'optionalAccess', _42 => _42.suggestion]),
|
|
3480
|
+
_optionalChain([innerError, 'access', _43 => _43.details, 'optionalAccess', _44 => _44.docs])
|
|
3645
3481
|
].filter(Boolean).join("\n");
|
|
3646
3482
|
_core.console.error(detailedMessage);
|
|
3647
3483
|
}
|
|
@@ -3742,8 +3578,6 @@ function makeRoomContextBundle(client) {
|
|
|
3742
3578
|
// prettier-ignore
|
|
3743
3579
|
useMutation,
|
|
3744
3580
|
useThreads,
|
|
3745
|
-
useAgentSessions,
|
|
3746
|
-
useAgentSession,
|
|
3747
3581
|
useSearchComments,
|
|
3748
3582
|
// prettier-ignore
|
|
3749
3583
|
useCreateThread,
|
|
@@ -3793,8 +3627,6 @@ function makeRoomContextBundle(client) {
|
|
|
3793
3627
|
// prettier-ignore
|
|
3794
3628
|
useMutation,
|
|
3795
3629
|
useThreads: useThreadsSuspense,
|
|
3796
|
-
useAgentSessions: useAgentSessionsSuspense,
|
|
3797
|
-
useAgentSession: useAgentSessionSuspense,
|
|
3798
3630
|
// prettier-ignore
|
|
3799
3631
|
useCreateThread,
|
|
3800
3632
|
useDeleteThread,
|
|
@@ -3934,41 +3766,6 @@ function RoomProviderInner(props) {
|
|
|
3934
3766
|
(message) => void handleCommentEvent(message)
|
|
3935
3767
|
);
|
|
3936
3768
|
}, [client, room]);
|
|
3937
|
-
_react.useEffect.call(void 0, () => {
|
|
3938
|
-
const { store } = getRoomExtrasForClient(client);
|
|
3939
|
-
function handleAgentSessionEvent(message) {
|
|
3940
|
-
if (message.type === _core.ServerMsgCode.AGENT_SESSIONS) {
|
|
3941
|
-
const agentSessionsMsg = message;
|
|
3942
|
-
if (agentSessionsMsg.operation !== "list") {
|
|
3943
|
-
store.updateAgentSessions(
|
|
3944
|
-
room.id,
|
|
3945
|
-
agentSessionsMsg.sessions,
|
|
3946
|
-
agentSessionsMsg.operation
|
|
3947
|
-
);
|
|
3948
|
-
}
|
|
3949
|
-
} else if (message.type === _core.ServerMsgCode.AGENT_MESSAGES) {
|
|
3950
|
-
const agentMessagesMsg = message;
|
|
3951
|
-
if (agentMessagesMsg.operation !== "list") {
|
|
3952
|
-
store.updateAgentMessages(
|
|
3953
|
-
room.id,
|
|
3954
|
-
agentMessagesMsg.sessionId,
|
|
3955
|
-
agentMessagesMsg.messages,
|
|
3956
|
-
agentMessagesMsg.operation
|
|
3957
|
-
);
|
|
3958
|
-
}
|
|
3959
|
-
}
|
|
3960
|
-
}
|
|
3961
|
-
return room.events.agentSessions.subscribe(
|
|
3962
|
-
(message) => void handleAgentSessionEvent(message)
|
|
3963
|
-
);
|
|
3964
|
-
}, [client, room]);
|
|
3965
|
-
_react.useEffect.call(void 0, () => {
|
|
3966
|
-
const { store } = getRoomExtrasForClient(client);
|
|
3967
|
-
store.registerRoom(room.id, room);
|
|
3968
|
-
return () => {
|
|
3969
|
-
store.unregisterRoom(room.id);
|
|
3970
|
-
};
|
|
3971
|
-
}, [client, room]);
|
|
3972
3769
|
_react.useEffect.call(void 0, () => {
|
|
3973
3770
|
const pair = stableEnterRoom(roomId, frozenProps);
|
|
3974
3771
|
setRoomLeavePair(pair);
|
|
@@ -3984,7 +3781,7 @@ function RoomProviderInner(props) {
|
|
|
3984
3781
|
}
|
|
3985
3782
|
function useRoom(options) {
|
|
3986
3783
|
const room = useRoomOrNull();
|
|
3987
|
-
if (room === null && !_optionalChain([options, 'optionalAccess',
|
|
3784
|
+
if (room === null && !_optionalChain([options, 'optionalAccess', _45 => _45.allowOutsideRoom])) {
|
|
3988
3785
|
throw new Error("RoomProvider is missing from the React tree.");
|
|
3989
3786
|
}
|
|
3990
3787
|
return room;
|
|
@@ -4294,53 +4091,6 @@ function useThreads(options = {}) {
|
|
|
4294
4091
|
useScrollToCommentOnLoadEffect(scrollOnLoad, result);
|
|
4295
4092
|
return result;
|
|
4296
4093
|
}
|
|
4297
|
-
function useAgentSessions(options) {
|
|
4298
|
-
const room = useRoom();
|
|
4299
|
-
const client = useClient();
|
|
4300
|
-
const { store } = getRoomExtrasForClient(client);
|
|
4301
|
-
const queryKey = makeAgentSessionsQueryKey(room.id, options);
|
|
4302
|
-
const loadableResource = store.outputs.loadingAgentSessions.getOrCreate(queryKey);
|
|
4303
|
-
_react.useEffect.call(void 0, () => {
|
|
4304
|
-
void loadableResource.waitUntilLoaded();
|
|
4305
|
-
});
|
|
4306
|
-
return useSignal(loadableResource.signal);
|
|
4307
|
-
}
|
|
4308
|
-
function useAgentSession(sessionId, options) {
|
|
4309
|
-
const room = useRoom();
|
|
4310
|
-
const client = useClient();
|
|
4311
|
-
const { store } = getRoomExtrasForClient(client);
|
|
4312
|
-
const queryKey = makeAgentMessagesQueryKey(room.id, sessionId, options);
|
|
4313
|
-
_react.useEffect.call(void 0, () => {
|
|
4314
|
-
void store.outputs.loadingAgentMessages.getOrCreate(queryKey).waitUntilLoaded();
|
|
4315
|
-
});
|
|
4316
|
-
return useSignal(
|
|
4317
|
-
store.outputs.loadingAgentMessages.getOrCreate(queryKey).signal
|
|
4318
|
-
);
|
|
4319
|
-
}
|
|
4320
|
-
function useAgentSessionsSuspense(options) {
|
|
4321
|
-
ensureNotServerSide();
|
|
4322
|
-
const client = useClient();
|
|
4323
|
-
const room = useRoom();
|
|
4324
|
-
const { store } = getRoomExtrasForClient(client);
|
|
4325
|
-
const queryKey = makeAgentSessionsQueryKey(room.id, options);
|
|
4326
|
-
use(store.outputs.loadingAgentSessions.getOrCreate(queryKey).waitUntilLoaded());
|
|
4327
|
-
const result = useAgentSessions(options);
|
|
4328
|
-
_core.assert.call(void 0, !result.error, "Did not expect error");
|
|
4329
|
-
_core.assert.call(void 0, !result.isLoading, "Did not expect loading");
|
|
4330
|
-
return result;
|
|
4331
|
-
}
|
|
4332
|
-
function useAgentSessionSuspense(sessionId, options) {
|
|
4333
|
-
ensureNotServerSide();
|
|
4334
|
-
const client = useClient();
|
|
4335
|
-
const room = useRoom();
|
|
4336
|
-
const { store } = getRoomExtrasForClient(client);
|
|
4337
|
-
const queryKey = makeAgentMessagesQueryKey(room.id, sessionId, options);
|
|
4338
|
-
use(store.outputs.loadingAgentMessages.getOrCreate(queryKey).waitUntilLoaded());
|
|
4339
|
-
const result = useAgentSession(sessionId, options);
|
|
4340
|
-
_core.assert.call(void 0, !result.error, "Did not expect error");
|
|
4341
|
-
_core.assert.call(void 0, !result.isLoading, "Did not expect loading");
|
|
4342
|
-
return result;
|
|
4343
|
-
}
|
|
4344
4094
|
function useSearchComments(options) {
|
|
4345
4095
|
const [result, setResult] = _react.useState.call(void 0, {
|
|
4346
4096
|
isLoading: true
|
|
@@ -4351,7 +4101,7 @@ function useSearchComments(options) {
|
|
|
4351
4101
|
const room = useRoom();
|
|
4352
4102
|
const queryKey = _core.stableStringify.call(void 0, [room.id, options.query]);
|
|
4353
4103
|
_react.useEffect.call(void 0, () => {
|
|
4354
|
-
const currentRequestId = (_nullishCoalesce(_optionalChain([currentRequestInfo, 'access',
|
|
4104
|
+
const currentRequestId = (_nullishCoalesce(_optionalChain([currentRequestInfo, 'access', _46 => _46.current, 'optionalAccess', _47 => _47.id]), () => ( 0))) + 1;
|
|
4355
4105
|
const controller = new AbortController();
|
|
4356
4106
|
currentRequestInfo.current = { id: currentRequestId, controller };
|
|
4357
4107
|
setResult((result2) => {
|
|
@@ -4368,12 +4118,12 @@ function useSearchComments(options) {
|
|
|
4368
4118
|
{ signal: controller.signal }
|
|
4369
4119
|
).then(({ data }) => {
|
|
4370
4120
|
if (controller.signal.aborted) return;
|
|
4371
|
-
if (_optionalChain([currentRequestInfo, 'access',
|
|
4121
|
+
if (_optionalChain([currentRequestInfo, 'access', _48 => _48.current, 'optionalAccess', _49 => _49.id]) !== currentRequestId) return;
|
|
4372
4122
|
setResult({ isLoading: false, results: data });
|
|
4373
4123
|
currentRequestInfo.current = null;
|
|
4374
4124
|
}).catch((err) => {
|
|
4375
4125
|
if (controller.signal.aborted) return;
|
|
4376
|
-
if (_optionalChain([currentRequestInfo, 'access',
|
|
4126
|
+
if (_optionalChain([currentRequestInfo, 'access', _50 => _50.current, 'optionalAccess', _51 => _51.id]) !== currentRequestId) return;
|
|
4377
4127
|
setResult({ isLoading: false, error: err });
|
|
4378
4128
|
currentRequestInfo.current = null;
|
|
4379
4129
|
});
|
|
@@ -4434,7 +4184,7 @@ function useCreateRoomThread(roomId) {
|
|
|
4434
4184
|
thread: newThread,
|
|
4435
4185
|
roomId
|
|
4436
4186
|
});
|
|
4437
|
-
const attachmentIds = _optionalChain([attachments, 'optionalAccess',
|
|
4187
|
+
const attachmentIds = _optionalChain([attachments, 'optionalAccess', _52 => _52.map, 'call', _53 => _53((attachment) => attachment.id)]);
|
|
4438
4188
|
client[_core.kInternal].httpClient.createThread({
|
|
4439
4189
|
roomId,
|
|
4440
4190
|
threadId,
|
|
@@ -4476,7 +4226,7 @@ function useDeleteRoomThread(roomId) {
|
|
|
4476
4226
|
const { store, onMutationFailure } = getRoomExtrasForClient(client);
|
|
4477
4227
|
const userId = getCurrentUserId(client);
|
|
4478
4228
|
const existing = store.outputs.threads.get().get(threadId);
|
|
4479
|
-
if (_optionalChain([existing, 'optionalAccess',
|
|
4229
|
+
if (_optionalChain([existing, 'optionalAccess', _54 => _54.comments, 'optionalAccess', _55 => _55[0], 'optionalAccess', _56 => _56.userId]) !== userId) {
|
|
4480
4230
|
throw new Error("Only the thread creator can delete the thread");
|
|
4481
4231
|
}
|
|
4482
4232
|
const optimisticId = store.optimisticUpdates.add({
|
|
@@ -4617,7 +4367,7 @@ function useCreateRoomComment(roomId) {
|
|
|
4617
4367
|
type: "create-comment",
|
|
4618
4368
|
comment
|
|
4619
4369
|
});
|
|
4620
|
-
const attachmentIds = _optionalChain([attachments, 'optionalAccess',
|
|
4370
|
+
const attachmentIds = _optionalChain([attachments, 'optionalAccess', _57 => _57.map, 'call', _58 => _58((attachment) => attachment.id)]);
|
|
4621
4371
|
client[_core.kInternal].httpClient.createComment({
|
|
4622
4372
|
roomId,
|
|
4623
4373
|
threadId,
|
|
@@ -4692,7 +4442,7 @@ function useEditRoomComment(roomId) {
|
|
|
4692
4442
|
metadata: updatedMetadata
|
|
4693
4443
|
}
|
|
4694
4444
|
});
|
|
4695
|
-
const attachmentIds = _optionalChain([attachments, 'optionalAccess',
|
|
4445
|
+
const attachmentIds = _optionalChain([attachments, 'optionalAccess', _59 => _59.map, 'call', _60 => _60((attachment) => attachment.id)]);
|
|
4696
4446
|
client[_core.kInternal].httpClient.editComment({
|
|
4697
4447
|
roomId,
|
|
4698
4448
|
threadId,
|
|
@@ -5047,7 +4797,7 @@ function useRoomThreadSubscription(roomId, threadId) {
|
|
|
5047
4797
|
}
|
|
5048
4798
|
return {
|
|
5049
4799
|
status: "subscribed",
|
|
5050
|
-
unreadSince: _nullishCoalesce(_optionalChain([notification, 'optionalAccess',
|
|
4800
|
+
unreadSince: _nullishCoalesce(_optionalChain([notification, 'optionalAccess', _61 => _61.readAt]), () => ( null)),
|
|
5051
4801
|
subscribe,
|
|
5052
4802
|
unsubscribe
|
|
5053
4803
|
};
|
|
@@ -5258,7 +5008,7 @@ function useThreadsSuspense(options = {}) {
|
|
|
5258
5008
|
return result;
|
|
5259
5009
|
}
|
|
5260
5010
|
function selectorFor_useAttachmentUrl(state) {
|
|
5261
|
-
if (state === void 0 || _optionalChain([state, 'optionalAccess',
|
|
5011
|
+
if (state === void 0 || _optionalChain([state, 'optionalAccess', _62 => _62.isLoading])) {
|
|
5262
5012
|
return _nullishCoalesce(state, () => ( { isLoading: true }));
|
|
5263
5013
|
}
|
|
5264
5014
|
if (state.error) {
|
|
@@ -5346,8 +5096,6 @@ var _useMyPresence = useMyPresence;
|
|
|
5346
5096
|
var _useOthersMapped = useOthersMapped;
|
|
5347
5097
|
var _useOthersMappedSuspense = useOthersMappedSuspense;
|
|
5348
5098
|
var _useThreads = useThreads;
|
|
5349
|
-
var _useAgentSessions = useAgentSessions;
|
|
5350
|
-
var _useAgentSession = useAgentSession;
|
|
5351
5099
|
var _useSearchComments = useSearchComments;
|
|
5352
5100
|
var _useThreadsSuspense = useThreadsSuspense;
|
|
5353
5101
|
var _useRoomSubscriptionSettings = useRoomSubscriptionSettings;
|
|
@@ -5496,7 +5244,5 @@ var _useUpdateMyPresence = useUpdateMyPresence;
|
|
|
5496
5244
|
|
|
5497
5245
|
|
|
5498
5246
|
|
|
5499
|
-
|
|
5500
|
-
|
|
5501
|
-
exports.ClientContext = ClientContext; exports.useClientOrNull = useClientOrNull; exports.useClient = useClient; exports.RoomContext = RoomContext; exports.useLatest = useLatest; exports.RegisterAiKnowledge = RegisterAiKnowledge; exports.RegisterAiTool = RegisterAiTool; exports.useSyncExternalStoreWithSelector = useSyncExternalStoreWithSelector; exports.useSignal = useSignal; exports.getUmbrellaStoreForClient = getUmbrellaStoreForClient; exports.useCreateAiChat = useCreateAiChat; exports.useDeleteAiChat = useDeleteAiChat; exports.useAiChatStatus = useAiChatStatus; exports.useSendAiMessage = useSendAiMessage; exports.LiveblocksProvider = LiveblocksProvider; exports.createLiveblocksContext = createLiveblocksContext; exports.useInboxNotifications = useInboxNotifications; exports.useInboxNotificationsSuspense = useInboxNotificationsSuspense; exports.useMarkAllInboxNotificationsAsRead = useMarkAllInboxNotificationsAsRead; exports.useMarkInboxNotificationAsRead = useMarkInboxNotificationAsRead; exports.useDeleteAllInboxNotifications = useDeleteAllInboxNotifications; exports.useDeleteInboxNotification = useDeleteInboxNotification; exports.useUnreadInboxNotificationsCount = useUnreadInboxNotificationsCount; exports.useUnreadInboxNotificationsCountSuspense = useUnreadInboxNotificationsCountSuspense; exports.useNotificationSettings = useNotificationSettings; exports.useNotificationSettingsSuspense = useNotificationSettingsSuspense; exports.useUpdateNotificationSettings = useUpdateNotificationSettings; exports.useRoomInfo = useRoomInfo; exports.useRoomInfoSuspense = useRoomInfoSuspense; exports.useGroupInfo = useGroupInfo; exports.useGroupInfoSuspense = useGroupInfoSuspense; exports._useInboxNotificationThread = _useInboxNotificationThread; exports._useUser = _useUser; exports._useUserSuspense = _useUserSuspense; exports._useUserThreads_experimental = _useUserThreads_experimental; exports._useUserThreadsSuspense_experimental = _useUserThreadsSuspense_experimental; exports._useAiChats = _useAiChats; exports._useAiChatsSuspense = _useAiChatsSuspense; exports._useAiChat = _useAiChat; exports._useAiChatSuspense = _useAiChatSuspense; exports._useAiChatMessages = _useAiChatMessages; exports._useAiChatMessagesSuspense = _useAiChatMessagesSuspense; exports._useUrlMetadata = _useUrlMetadata; exports._useUrlMetadataSuspense = _useUrlMetadataSuspense; exports.useSyncStatus = useSyncStatus; exports.useErrorListener = useErrorListener; exports.useStatus = useStatus; exports.useReportTextEditor = useReportTextEditor; exports.useYjsProvider = useYjsProvider; exports.useCreateTextMention = useCreateTextMention; exports.useDeleteTextMention = useDeleteTextMention; exports.useResolveMentionSuggestions = useResolveMentionSuggestions; exports.useMentionSuggestionsCache = useMentionSuggestionsCache; exports.useLostConnectionListener = useLostConnectionListener; exports.useHistory = useHistory; exports.useUndo = useUndo; exports.useRedo = useRedo; exports.useCanUndo = useCanUndo; exports.useCanRedo = useCanRedo; exports.useOthersConnectionIds = useOthersConnectionIds; exports.useCreateRoomThread = useCreateRoomThread; exports.useDeleteRoomThread = useDeleteRoomThread; exports.useEditRoomThreadMetadata = useEditRoomThreadMetadata; exports.useCreateRoomComment = useCreateRoomComment; exports.useEditRoomComment = useEditRoomComment; exports.useDeleteComment = useDeleteComment; exports.useDeleteRoomComment = useDeleteRoomComment; exports.useAddRoomCommentReaction = useAddRoomCommentReaction; exports.useRemoveReaction = useRemoveReaction; exports.useRemoveRoomCommentReaction = useRemoveRoomCommentReaction; exports.useMarkThreadAsRead = useMarkThreadAsRead; exports.useMarkRoomThreadAsRead = useMarkRoomThreadAsRead; exports.useMarkThreadAsResolved = useMarkThreadAsResolved; exports.useMarkRoomThreadAsResolved = useMarkRoomThreadAsResolved; exports.useMarkThreadAsUnresolved = useMarkThreadAsUnresolved; exports.useMarkRoomThreadAsUnresolved = useMarkRoomThreadAsUnresolved; exports.useSubscribeToThread = useSubscribeToThread; exports.useUnsubscribeFromThread = useUnsubscribeFromThread; exports.useThreadSubscription = useThreadSubscription; exports.useRoomThreadSubscription = useRoomThreadSubscription; exports.useHistoryVersionData = useHistoryVersionData; exports.useUpdateRoomSubscriptionSettings = useUpdateRoomSubscriptionSettings; exports.useOthersConnectionIdsSuspense = useOthersConnectionIdsSuspense; exports.useAttachmentUrl = useAttachmentUrl; exports.useRoomAttachmentUrl = useRoomAttachmentUrl; exports.useAttachmentUrlSuspense = useAttachmentUrlSuspense; exports.useRoomPermissions = useRoomPermissions; exports.createRoomContext = createRoomContext; exports._RoomProvider = _RoomProvider; exports._useBroadcastEvent = _useBroadcastEvent; exports._useOthersListener = _useOthersListener; exports._useRoom = _useRoom; exports._useIsInsideRoom = _useIsInsideRoom; exports._useAddReaction = _useAddReaction; exports._useMutation = _useMutation; exports._useCreateThread = _useCreateThread; exports._useDeleteThread = _useDeleteThread; exports._useEditThreadMetadata = _useEditThreadMetadata; exports._useCreateComment = _useCreateComment; exports._useEditComment = _useEditComment; exports._useEditCommentMetadata = _useEditCommentMetadata; exports._useEventListener = _useEventListener; exports._useMyPresence = _useMyPresence; exports._useOthersMapped = _useOthersMapped; exports._useOthersMappedSuspense = _useOthersMappedSuspense; exports._useThreads = _useThreads; exports._useAgentSessions = _useAgentSessions; exports._useAgentSession = _useAgentSession; exports._useSearchComments = _useSearchComments; exports._useThreadsSuspense = _useThreadsSuspense; exports._useRoomSubscriptionSettings = _useRoomSubscriptionSettings; exports._useRoomSubscriptionSettingsSuspense = _useRoomSubscriptionSettingsSuspense; exports._useHistoryVersions = _useHistoryVersions; exports._useHistoryVersionsSuspense = _useHistoryVersionsSuspense; exports._useOther = _useOther; exports._useOthers = _useOthers; exports._useOtherSuspense = _useOtherSuspense; exports._useOthersSuspense = _useOthersSuspense; exports._useStorage = _useStorage; exports._useStorageSuspense = _useStorageSuspense; exports._useSelf = _useSelf; exports._useSelfSuspense = _useSelfSuspense; exports._useStorageRoot = _useStorageRoot; exports._useUpdateMyPresence = _useUpdateMyPresence;
|
|
5502
|
-
//# sourceMappingURL=chunk-JXNC4PPG.cjs.map
|
|
5247
|
+
exports.ClientContext = ClientContext; exports.useClientOrNull = useClientOrNull; exports.useClient = useClient; exports.RoomContext = RoomContext; exports.useLatest = useLatest; exports.RegisterAiKnowledge = RegisterAiKnowledge; exports.RegisterAiTool = RegisterAiTool; exports.useSyncExternalStoreWithSelector = useSyncExternalStoreWithSelector; exports.useSignal = useSignal; exports.getUmbrellaStoreForClient = getUmbrellaStoreForClient; exports.useCreateAiChat = useCreateAiChat; exports.useDeleteAiChat = useDeleteAiChat; exports.useAiChatStatus = useAiChatStatus; exports.useSendAiMessage = useSendAiMessage; exports.LiveblocksProvider = LiveblocksProvider; exports.createLiveblocksContext = createLiveblocksContext; exports.useInboxNotifications = useInboxNotifications; exports.useInboxNotificationsSuspense = useInboxNotificationsSuspense; exports.useMarkAllInboxNotificationsAsRead = useMarkAllInboxNotificationsAsRead; exports.useMarkInboxNotificationAsRead = useMarkInboxNotificationAsRead; exports.useDeleteAllInboxNotifications = useDeleteAllInboxNotifications; exports.useDeleteInboxNotification = useDeleteInboxNotification; exports.useUnreadInboxNotificationsCount = useUnreadInboxNotificationsCount; exports.useUnreadInboxNotificationsCountSuspense = useUnreadInboxNotificationsCountSuspense; exports.useNotificationSettings = useNotificationSettings; exports.useNotificationSettingsSuspense = useNotificationSettingsSuspense; exports.useUpdateNotificationSettings = useUpdateNotificationSettings; exports.useRoomInfo = useRoomInfo; exports.useRoomInfoSuspense = useRoomInfoSuspense; exports.useGroupInfo = useGroupInfo; exports.useGroupInfoSuspense = useGroupInfoSuspense; exports._useInboxNotificationThread = _useInboxNotificationThread; exports._useUser = _useUser; exports._useUserSuspense = _useUserSuspense; exports._useUserThreads_experimental = _useUserThreads_experimental; exports._useUserThreadsSuspense_experimental = _useUserThreadsSuspense_experimental; exports._useAiChats = _useAiChats; exports._useAiChatsSuspense = _useAiChatsSuspense; exports._useAiChat = _useAiChat; exports._useAiChatSuspense = _useAiChatSuspense; exports._useAiChatMessages = _useAiChatMessages; exports._useAiChatMessagesSuspense = _useAiChatMessagesSuspense; exports._useUrlMetadata = _useUrlMetadata; exports._useUrlMetadataSuspense = _useUrlMetadataSuspense; exports.useSyncStatus = useSyncStatus; exports.useErrorListener = useErrorListener; exports.useStatus = useStatus; exports.useReportTextEditor = useReportTextEditor; exports.useYjsProvider = useYjsProvider; exports.useCreateTextMention = useCreateTextMention; exports.useDeleteTextMention = useDeleteTextMention; exports.useResolveMentionSuggestions = useResolveMentionSuggestions; exports.useMentionSuggestionsCache = useMentionSuggestionsCache; exports.useLostConnectionListener = useLostConnectionListener; exports.useHistory = useHistory; exports.useUndo = useUndo; exports.useRedo = useRedo; exports.useCanUndo = useCanUndo; exports.useCanRedo = useCanRedo; exports.useOthersConnectionIds = useOthersConnectionIds; exports.useCreateRoomThread = useCreateRoomThread; exports.useDeleteRoomThread = useDeleteRoomThread; exports.useEditRoomThreadMetadata = useEditRoomThreadMetadata; exports.useCreateRoomComment = useCreateRoomComment; exports.useEditRoomComment = useEditRoomComment; exports.useDeleteComment = useDeleteComment; exports.useDeleteRoomComment = useDeleteRoomComment; exports.useAddRoomCommentReaction = useAddRoomCommentReaction; exports.useRemoveReaction = useRemoveReaction; exports.useRemoveRoomCommentReaction = useRemoveRoomCommentReaction; exports.useMarkThreadAsRead = useMarkThreadAsRead; exports.useMarkRoomThreadAsRead = useMarkRoomThreadAsRead; exports.useMarkThreadAsResolved = useMarkThreadAsResolved; exports.useMarkRoomThreadAsResolved = useMarkRoomThreadAsResolved; exports.useMarkThreadAsUnresolved = useMarkThreadAsUnresolved; exports.useMarkRoomThreadAsUnresolved = useMarkRoomThreadAsUnresolved; exports.useSubscribeToThread = useSubscribeToThread; exports.useUnsubscribeFromThread = useUnsubscribeFromThread; exports.useThreadSubscription = useThreadSubscription; exports.useRoomThreadSubscription = useRoomThreadSubscription; exports.useHistoryVersionData = useHistoryVersionData; exports.useUpdateRoomSubscriptionSettings = useUpdateRoomSubscriptionSettings; exports.useOthersConnectionIdsSuspense = useOthersConnectionIdsSuspense; exports.useAttachmentUrl = useAttachmentUrl; exports.useRoomAttachmentUrl = useRoomAttachmentUrl; exports.useAttachmentUrlSuspense = useAttachmentUrlSuspense; exports.useRoomPermissions = useRoomPermissions; exports.createRoomContext = createRoomContext; exports._RoomProvider = _RoomProvider; exports._useBroadcastEvent = _useBroadcastEvent; exports._useOthersListener = _useOthersListener; exports._useRoom = _useRoom; exports._useIsInsideRoom = _useIsInsideRoom; exports._useAddReaction = _useAddReaction; exports._useMutation = _useMutation; exports._useCreateThread = _useCreateThread; exports._useDeleteThread = _useDeleteThread; exports._useEditThreadMetadata = _useEditThreadMetadata; exports._useCreateComment = _useCreateComment; exports._useEditComment = _useEditComment; exports._useEditCommentMetadata = _useEditCommentMetadata; exports._useEventListener = _useEventListener; exports._useMyPresence = _useMyPresence; exports._useOthersMapped = _useOthersMapped; exports._useOthersMappedSuspense = _useOthersMappedSuspense; exports._useThreads = _useThreads; exports._useSearchComments = _useSearchComments; exports._useThreadsSuspense = _useThreadsSuspense; exports._useRoomSubscriptionSettings = _useRoomSubscriptionSettings; exports._useRoomSubscriptionSettingsSuspense = _useRoomSubscriptionSettingsSuspense; exports._useHistoryVersions = _useHistoryVersions; exports._useHistoryVersionsSuspense = _useHistoryVersionsSuspense; exports._useOther = _useOther; exports._useOthers = _useOthers; exports._useOtherSuspense = _useOtherSuspense; exports._useOthersSuspense = _useOthersSuspense; exports._useStorage = _useStorage; exports._useStorageSuspense = _useStorageSuspense; exports._useSelf = _useSelf; exports._useSelfSuspense = _useSelfSuspense; exports._useStorageRoot = _useStorageRoot; exports._useUpdateMyPresence = _useUpdateMyPresence;
|
|
5248
|
+
//# sourceMappingURL=chunk-QFAOGFJK.cjs.map
|