@liveblocks/react 3.16.0-flow3 → 3.16.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/_private.cjs +7 -13
- package/dist/_private.cjs.map +1 -1
- package/dist/_private.d.cts +3 -11
- package/dist/_private.d.ts +3 -11
- package/dist/_private.js +1 -7
- package/dist/_private.js.map +1 -1
- package/dist/{chunk-5YUDJVMF.js → chunk-A7EFQVZ3.js} +2 -2
- package/dist/{chunk-2VF57BZV.js → chunk-EEXHY3OA.js} +462 -39
- package/dist/chunk-EEXHY3OA.js.map +1 -0
- package/dist/{chunk-QEGVIJNN.cjs → chunk-HFTIBRCD.cjs} +497 -74
- package/dist/chunk-HFTIBRCD.cjs.map +1 -0
- package/dist/{chunk-HULSMHSU.cjs → chunk-VSO26OCO.cjs} +2 -2
- package/dist/{chunk-HULSMHSU.cjs.map → chunk-VSO26OCO.cjs.map} +1 -1
- package/dist/index.cjs +20 -4
- 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 +18 -2
- package/dist/index.js.map +1 -1
- package/dist/{room-BvPZu216.d.cts → room-kE9R5ats.d.cts} +249 -19
- package/dist/{room-BvPZu216.d.ts → room-kE9R5ats.d.ts} +249 -19
- package/dist/suspense.cjs +20 -4
- package/dist/suspense.cjs.map +1 -1
- package/dist/suspense.d.cts +1 -1
- package/dist/suspense.d.ts +1 -1
- package/dist/suspense.js +18 -2
- package/dist/suspense.js.map +1 -1
- package/package.json +3 -3
- package/dist/chunk-2VF57BZV.js.map +0 -1
- package/dist/chunk-QEGVIJNN.cjs.map +0 -1
- /package/dist/{chunk-5YUDJVMF.js.map → chunk-A7EFQVZ3.js.map} +0 -0
|
@@ -27,25 +27,6 @@ function useLatest(value) {
|
|
|
27
27
|
return ref;
|
|
28
28
|
}
|
|
29
29
|
|
|
30
|
-
// src/lib/use-initial.ts
|
|
31
|
-
|
|
32
|
-
function useInitial(value, roomId) {
|
|
33
|
-
return _react.useMemo.call(void 0, () => value, [roomId]);
|
|
34
|
-
}
|
|
35
|
-
function useInitialUnlessFunction(latestValue, roomId) {
|
|
36
|
-
const frozenValue = useInitial(latestValue, roomId);
|
|
37
|
-
const ref = useLatest(latestValue);
|
|
38
|
-
const wrapper = _react.useCallback.call(void 0,
|
|
39
|
-
(...args) => ref.current(...args),
|
|
40
|
-
[ref]
|
|
41
|
-
);
|
|
42
|
-
if (typeof frozenValue === "function") {
|
|
43
|
-
return wrapper;
|
|
44
|
-
} else {
|
|
45
|
-
return frozenValue;
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
|
|
49
30
|
// src/ai.tsx
|
|
50
31
|
|
|
51
32
|
|
|
@@ -250,6 +231,25 @@ function ensureNotServerSide() {
|
|
|
250
231
|
}
|
|
251
232
|
}
|
|
252
233
|
|
|
234
|
+
// src/lib/use-initial.ts
|
|
235
|
+
|
|
236
|
+
function useInitial(value, roomId) {
|
|
237
|
+
return _react.useMemo.call(void 0, () => value, [roomId]);
|
|
238
|
+
}
|
|
239
|
+
function useInitialUnlessFunction(latestValue, roomId) {
|
|
240
|
+
const frozenValue = useInitial(latestValue, roomId);
|
|
241
|
+
const ref = useLatest(latestValue);
|
|
242
|
+
const wrapper = _react.useCallback.call(void 0,
|
|
243
|
+
(...args) => ref.current(...args),
|
|
244
|
+
[ref]
|
|
245
|
+
);
|
|
246
|
+
if (typeof frozenValue === "function") {
|
|
247
|
+
return wrapper;
|
|
248
|
+
} else {
|
|
249
|
+
return frozenValue;
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
|
|
253
253
|
// src/lib/use-polyfill.ts
|
|
254
254
|
|
|
255
255
|
var reactUse = React[" use ".trim().toString()];
|
|
@@ -512,6 +512,12 @@ function makeAiChatsQueryKey(query) {
|
|
|
512
512
|
function makeInboxNotificationsQueryKey(query) {
|
|
513
513
|
return _core.stableStringify.call(void 0, _nullishCoalesce(query, () => ( {})));
|
|
514
514
|
}
|
|
515
|
+
function makeFeedsQueryKey(roomId, options) {
|
|
516
|
+
return _core.stableStringify.call(void 0, [roomId, _nullishCoalesce(options, () => ( {}))]);
|
|
517
|
+
}
|
|
518
|
+
function makeFeedMessagesQueryKey(roomId, feedId, options) {
|
|
519
|
+
return _core.stableStringify.call(void 0, [roomId, feedId, _nullishCoalesce(options, () => ( {}))]);
|
|
520
|
+
}
|
|
515
521
|
function usify(promise) {
|
|
516
522
|
if ("status" in promise) {
|
|
517
523
|
return promise;
|
|
@@ -536,10 +542,12 @@ var PaginatedResource = class {
|
|
|
536
542
|
|
|
537
543
|
#fetchPage;
|
|
538
544
|
#pendingFetchMore;
|
|
539
|
-
|
|
545
|
+
#autoRetry;
|
|
546
|
+
constructor(fetchPage, options) {
|
|
540
547
|
this.#signal = new (0, _core.Signal)(ASYNC_LOADING);
|
|
541
548
|
this.#fetchPage = fetchPage;
|
|
542
549
|
this.#pendingFetchMore = null;
|
|
550
|
+
this.#autoRetry = _nullishCoalesce(_optionalChain([options, 'optionalAccess', _4 => _4.autoRetry]), () => ( true));
|
|
543
551
|
this.signal = this.#signal.asReadonly();
|
|
544
552
|
autobind(this);
|
|
545
553
|
}
|
|
@@ -553,7 +561,7 @@ var PaginatedResource = class {
|
|
|
553
561
|
}
|
|
554
562
|
async #fetchMore() {
|
|
555
563
|
const state = this.#signal.get();
|
|
556
|
-
if (!_optionalChain([state, 'access',
|
|
564
|
+
if (!_optionalChain([state, 'access', _5 => _5.data, 'optionalAccess', _6 => _6.cursor]) || state.data.isFetchingMore) {
|
|
557
565
|
return;
|
|
558
566
|
}
|
|
559
567
|
this.#patch({ isFetchingMore: true });
|
|
@@ -576,7 +584,7 @@ var PaginatedResource = class {
|
|
|
576
584
|
}
|
|
577
585
|
fetchMore() {
|
|
578
586
|
const state = this.#signal.get();
|
|
579
|
-
if (!_optionalChain([state, 'access',
|
|
587
|
+
if (!_optionalChain([state, 'access', _7 => _7.data, 'optionalAccess', _8 => _8.cursor])) return noop;
|
|
580
588
|
if (!this.#pendingFetchMore) {
|
|
581
589
|
this.#pendingFetchMore = this.#fetchMore();
|
|
582
590
|
}
|
|
@@ -587,14 +595,17 @@ var PaginatedResource = class {
|
|
|
587
595
|
if (this.#cachedPromise) {
|
|
588
596
|
return this.#cachedPromise;
|
|
589
597
|
}
|
|
590
|
-
const initialPageFetch$ = _core.autoRetry.call(void 0,
|
|
598
|
+
const initialPageFetch$ = this.#autoRetry ? _core.autoRetry.call(void 0,
|
|
591
599
|
() => this.#fetchPage(
|
|
592
600
|
/* cursor */
|
|
593
601
|
void 0
|
|
594
602
|
),
|
|
595
603
|
5,
|
|
596
604
|
[5e3, 5e3, 1e4, 15e3]
|
|
597
|
-
)
|
|
605
|
+
) : Promise.resolve().then(() => this.#fetchPage(
|
|
606
|
+
/* cursor */
|
|
607
|
+
void 0
|
|
608
|
+
));
|
|
598
609
|
const promise = usify(initialPageFetch$);
|
|
599
610
|
promise.then(
|
|
600
611
|
(cursor) => {
|
|
@@ -610,10 +621,12 @@ var PaginatedResource = class {
|
|
|
610
621
|
},
|
|
611
622
|
(err) => {
|
|
612
623
|
this.#signal.set(ASYNC_ERR(err));
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
624
|
+
if (this.#autoRetry) {
|
|
625
|
+
setTimeout(() => {
|
|
626
|
+
this.#cachedPromise = null;
|
|
627
|
+
this.#signal.set(ASYNC_LOADING);
|
|
628
|
+
}, 5e3);
|
|
629
|
+
}
|
|
617
630
|
}
|
|
618
631
|
);
|
|
619
632
|
this.#cachedPromise = promise;
|
|
@@ -912,6 +925,82 @@ function createStore_forOptimistic(client) {
|
|
|
912
925
|
remove
|
|
913
926
|
};
|
|
914
927
|
}
|
|
928
|
+
function createStore_forFeeds() {
|
|
929
|
+
const signal = new (0, _core.MutableSignal)(/* @__PURE__ */ new Map());
|
|
930
|
+
function upsert(roomId, feeds) {
|
|
931
|
+
signal.mutate((map) => {
|
|
932
|
+
let roomMap = map.get(roomId);
|
|
933
|
+
if (!roomMap) {
|
|
934
|
+
roomMap = /* @__PURE__ */ new Map();
|
|
935
|
+
map.set(roomId, roomMap);
|
|
936
|
+
}
|
|
937
|
+
for (const feed of feeds) {
|
|
938
|
+
roomMap.set(feed.feedId, feed);
|
|
939
|
+
}
|
|
940
|
+
});
|
|
941
|
+
}
|
|
942
|
+
function deleteOne(roomId, feedId) {
|
|
943
|
+
signal.mutate((map) => {
|
|
944
|
+
_optionalChain([map, 'access', _9 => _9.get, 'call', _10 => _10(roomId), 'optionalAccess', _11 => _11.delete, 'call', _12 => _12(feedId)]);
|
|
945
|
+
});
|
|
946
|
+
}
|
|
947
|
+
function findMany(feedsByRoomId, roomId, options) {
|
|
948
|
+
const filtered = Array.from(
|
|
949
|
+
_nullishCoalesce(_optionalChain([feedsByRoomId, 'access', _13 => _13.get, 'call', _14 => _14(roomId), 'optionalAccess', _15 => _15.values, 'call', _16 => _16()]), () => ( []))
|
|
950
|
+
).filter((feed) => {
|
|
951
|
+
if (_optionalChain([options, 'optionalAccess', _17 => _17.since]) !== void 0 && feed.updatedAt < options.since && feed.createdAt < options.since) {
|
|
952
|
+
return false;
|
|
953
|
+
}
|
|
954
|
+
if (_optionalChain([options, 'optionalAccess', _18 => _18.metadata]) !== void 0) {
|
|
955
|
+
const meta = feed.metadata;
|
|
956
|
+
if (!Object.entries(options.metadata).every(([k, v]) => meta[k] === v)) {
|
|
957
|
+
return false;
|
|
958
|
+
}
|
|
959
|
+
}
|
|
960
|
+
return true;
|
|
961
|
+
});
|
|
962
|
+
filtered.sort((a, b) => {
|
|
963
|
+
const byTime = a.createdAt - b.createdAt;
|
|
964
|
+
if (byTime !== 0) return byTime;
|
|
965
|
+
return a.feedId < b.feedId ? -1 : a.feedId > b.feedId ? 1 : 0;
|
|
966
|
+
});
|
|
967
|
+
return filtered;
|
|
968
|
+
}
|
|
969
|
+
return { signal, upsert, delete: deleteOne, findMany };
|
|
970
|
+
}
|
|
971
|
+
function createStore_forFeedMessages() {
|
|
972
|
+
const signal = new (0, _core.MutableSignal)(
|
|
973
|
+
/* @__PURE__ */ new Map()
|
|
974
|
+
);
|
|
975
|
+
function upsert(feedId, messages) {
|
|
976
|
+
signal.mutate((map) => {
|
|
977
|
+
let feedMap = map.get(feedId);
|
|
978
|
+
if (!feedMap) {
|
|
979
|
+
feedMap = /* @__PURE__ */ new Map();
|
|
980
|
+
map.set(feedId, feedMap);
|
|
981
|
+
}
|
|
982
|
+
for (const msg of messages) {
|
|
983
|
+
feedMap.set(msg.id, msg);
|
|
984
|
+
}
|
|
985
|
+
});
|
|
986
|
+
}
|
|
987
|
+
function deleteOne(feedId, messageIds) {
|
|
988
|
+
signal.mutate((map) => {
|
|
989
|
+
const feedMap = map.get(feedId);
|
|
990
|
+
if (feedMap) {
|
|
991
|
+
for (const id of messageIds) {
|
|
992
|
+
feedMap.delete(id);
|
|
993
|
+
}
|
|
994
|
+
}
|
|
995
|
+
});
|
|
996
|
+
}
|
|
997
|
+
function findMany(messagesByFeedId, feedId) {
|
|
998
|
+
return Array.from(_nullishCoalesce(_optionalChain([messagesByFeedId, 'access', _19 => _19.get, 'call', _20 => _20(feedId), 'optionalAccess', _21 => _21.values, 'call', _22 => _22()]), () => ( []))).sort(
|
|
999
|
+
(a, b) => a.createdAt - b.createdAt
|
|
1000
|
+
);
|
|
1001
|
+
}
|
|
1002
|
+
return { signal, upsert, delete: deleteOne, findMany };
|
|
1003
|
+
}
|
|
915
1004
|
var UmbrellaStore = class {
|
|
916
1005
|
#client;
|
|
917
1006
|
//
|
|
@@ -979,6 +1068,9 @@ var UmbrellaStore = class {
|
|
|
979
1068
|
#roomVersionsLastRequestedAtByRoom = /* @__PURE__ */ new Map();
|
|
980
1069
|
// Notification Settings
|
|
981
1070
|
#notificationSettings;
|
|
1071
|
+
// Feeds
|
|
1072
|
+
#feeds = createStore_forFeeds();
|
|
1073
|
+
#feedMessages = createStore_forFeedMessages();
|
|
982
1074
|
constructor(client) {
|
|
983
1075
|
this.#client = client[_core.kInternal].as();
|
|
984
1076
|
this.optimisticUpdates = createStore_forOptimistic(this.#client);
|
|
@@ -1350,6 +1442,97 @@ var UmbrellaStore = class {
|
|
|
1350
1442
|
return { signal, waitUntilLoaded: resource.waitUntilLoaded };
|
|
1351
1443
|
}
|
|
1352
1444
|
);
|
|
1445
|
+
const loadingFeeds = new (0, _core.DefaultMap)(
|
|
1446
|
+
(queryKey) => {
|
|
1447
|
+
const [roomId, options] = JSON.parse(queryKey);
|
|
1448
|
+
const resource = new PaginatedResource(
|
|
1449
|
+
async (cursor) => {
|
|
1450
|
+
const room = this.#client.getRoom(roomId);
|
|
1451
|
+
if (room === null) {
|
|
1452
|
+
throw new Error(
|
|
1453
|
+
`Room '${roomId}' is not available on client. Make sure you're calling useFeeds inside a RoomProvider.`
|
|
1454
|
+
);
|
|
1455
|
+
}
|
|
1456
|
+
const result = await room.fetchFeeds({
|
|
1457
|
+
cursor,
|
|
1458
|
+
since: _optionalChain([options, 'optionalAccess', _23 => _23.since]),
|
|
1459
|
+
metadata: _optionalChain([options, 'optionalAccess', _24 => _24.metadata]),
|
|
1460
|
+
limit: _optionalChain([options, 'optionalAccess', _25 => _25.limit])
|
|
1461
|
+
});
|
|
1462
|
+
this.upsertFeeds(roomId, result.feeds);
|
|
1463
|
+
return _nullishCoalesce(result.nextCursor, () => ( null));
|
|
1464
|
+
},
|
|
1465
|
+
{ autoRetry: false }
|
|
1466
|
+
);
|
|
1467
|
+
const signal = _core.DerivedSignal.from(
|
|
1468
|
+
resource.signal,
|
|
1469
|
+
this.#feeds.signal,
|
|
1470
|
+
(resourceResult, feedsByRoomId) => {
|
|
1471
|
+
if (resourceResult.isLoading || resourceResult.error) {
|
|
1472
|
+
return resourceResult;
|
|
1473
|
+
}
|
|
1474
|
+
const feeds = this.#feeds.findMany(feedsByRoomId, roomId, options);
|
|
1475
|
+
const page = resourceResult.data;
|
|
1476
|
+
return {
|
|
1477
|
+
isLoading: false,
|
|
1478
|
+
feeds,
|
|
1479
|
+
hasFetchedAll: page.hasFetchedAll,
|
|
1480
|
+
isFetchingMore: page.isFetchingMore,
|
|
1481
|
+
fetchMoreError: page.fetchMoreError,
|
|
1482
|
+
fetchMore: page.fetchMore
|
|
1483
|
+
};
|
|
1484
|
+
},
|
|
1485
|
+
_core.shallow2
|
|
1486
|
+
);
|
|
1487
|
+
return { signal, waitUntilLoaded: resource.waitUntilLoaded };
|
|
1488
|
+
}
|
|
1489
|
+
);
|
|
1490
|
+
const loadingFeedMessages = new (0, _core.DefaultMap)(
|
|
1491
|
+
(queryKey) => {
|
|
1492
|
+
const [roomId, feedId, options] = JSON.parse(queryKey);
|
|
1493
|
+
const resource = new PaginatedResource(
|
|
1494
|
+
async (cursor) => {
|
|
1495
|
+
const room = this.#client.getRoom(roomId);
|
|
1496
|
+
if (room === null) {
|
|
1497
|
+
throw new Error(
|
|
1498
|
+
`Room '${roomId}' is not available on client. Make sure you're calling useFeedMessages inside a RoomProvider.`
|
|
1499
|
+
);
|
|
1500
|
+
}
|
|
1501
|
+
const result = await room.fetchFeedMessages(feedId, {
|
|
1502
|
+
cursor,
|
|
1503
|
+
limit: _optionalChain([options, 'optionalAccess', _26 => _26.limit])
|
|
1504
|
+
});
|
|
1505
|
+
this.upsertFeedMessages(roomId, feedId, result.messages);
|
|
1506
|
+
return _nullishCoalesce(result.nextCursor, () => ( null));
|
|
1507
|
+
},
|
|
1508
|
+
{ autoRetry: false }
|
|
1509
|
+
);
|
|
1510
|
+
const signal = _core.DerivedSignal.from(
|
|
1511
|
+
resource.signal,
|
|
1512
|
+
this.#feedMessages.signal,
|
|
1513
|
+
(resourceResult, messagesByFeedId) => {
|
|
1514
|
+
if (resourceResult.isLoading || resourceResult.error) {
|
|
1515
|
+
return resourceResult;
|
|
1516
|
+
}
|
|
1517
|
+
const messages = this.#feedMessages.findMany(
|
|
1518
|
+
messagesByFeedId,
|
|
1519
|
+
feedId
|
|
1520
|
+
);
|
|
1521
|
+
const page = resourceResult.data;
|
|
1522
|
+
return {
|
|
1523
|
+
isLoading: false,
|
|
1524
|
+
messages,
|
|
1525
|
+
hasFetchedAll: page.hasFetchedAll,
|
|
1526
|
+
isFetchingMore: page.isFetchingMore,
|
|
1527
|
+
fetchMoreError: page.fetchMoreError,
|
|
1528
|
+
fetchMore: page.fetchMore
|
|
1529
|
+
};
|
|
1530
|
+
},
|
|
1531
|
+
_core.shallow2
|
|
1532
|
+
);
|
|
1533
|
+
return { signal, waitUntilLoaded: resource.waitUntilLoaded };
|
|
1534
|
+
}
|
|
1535
|
+
);
|
|
1353
1536
|
this.outputs = {
|
|
1354
1537
|
threadifications,
|
|
1355
1538
|
threads,
|
|
@@ -1365,7 +1548,9 @@ var UmbrellaStore = class {
|
|
|
1365
1548
|
aiChats,
|
|
1366
1549
|
messagesByChatId,
|
|
1367
1550
|
aiChatById,
|
|
1368
|
-
urlMetadataByUrl
|
|
1551
|
+
urlMetadataByUrl,
|
|
1552
|
+
loadingFeeds,
|
|
1553
|
+
loadingFeedMessages
|
|
1369
1554
|
};
|
|
1370
1555
|
autobind(this);
|
|
1371
1556
|
}
|
|
@@ -1586,6 +1771,30 @@ var UmbrellaStore = class {
|
|
|
1586
1771
|
result.subscriptions.deleted
|
|
1587
1772
|
);
|
|
1588
1773
|
}
|
|
1774
|
+
/**
|
|
1775
|
+
* Upserts feeds in the cache (for list/added/updated operations).
|
|
1776
|
+
*/
|
|
1777
|
+
upsertFeeds(roomId, feeds) {
|
|
1778
|
+
this.#feeds.upsert(roomId, feeds);
|
|
1779
|
+
}
|
|
1780
|
+
/**
|
|
1781
|
+
* Removes a feed from the cache (for deleted operations).
|
|
1782
|
+
*/
|
|
1783
|
+
deleteFeed(roomId, feedId) {
|
|
1784
|
+
this.#feeds.delete(roomId, feedId);
|
|
1785
|
+
}
|
|
1786
|
+
/**
|
|
1787
|
+
* Upserts feed messages in the cache (for list/added/updated operations).
|
|
1788
|
+
*/
|
|
1789
|
+
upsertFeedMessages(_roomId, feedId, messages) {
|
|
1790
|
+
this.#feedMessages.upsert(feedId, messages);
|
|
1791
|
+
}
|
|
1792
|
+
/**
|
|
1793
|
+
* Removes feed messages from the cache (for deleted operations).
|
|
1794
|
+
*/
|
|
1795
|
+
deleteFeedMessages(_roomId, feedId, messageIds) {
|
|
1796
|
+
this.#feedMessages.delete(feedId, messageIds);
|
|
1797
|
+
}
|
|
1589
1798
|
async fetchUnreadNotificationsCount(queryKey, signal) {
|
|
1590
1799
|
const query = JSON.parse(queryKey);
|
|
1591
1800
|
const result = await this.#client.getUnreadInboxNotificationsCount({
|
|
@@ -1996,7 +2205,7 @@ function applyUpsertComment(thread, comment) {
|
|
|
1996
2205
|
updatedAt: new Date(
|
|
1997
2206
|
Math.max(
|
|
1998
2207
|
thread.updatedAt.getTime(),
|
|
1999
|
-
_optionalChain([comment, 'access',
|
|
2208
|
+
_optionalChain([comment, 'access', _27 => _27.editedAt, 'optionalAccess', _28 => _28.getTime, 'call', _29 => _29()]) || comment.createdAt.getTime()
|
|
2000
2209
|
)
|
|
2001
2210
|
),
|
|
2002
2211
|
comments: updatedComments
|
|
@@ -2153,7 +2362,7 @@ function selectorFor_useUnreadInboxNotificationsCount(result) {
|
|
|
2153
2362
|
return ASYNC_OK("count", result.count);
|
|
2154
2363
|
}
|
|
2155
2364
|
function selectorFor_useUser(state, userId) {
|
|
2156
|
-
if (state === void 0 || _optionalChain([state, 'optionalAccess',
|
|
2365
|
+
if (state === void 0 || _optionalChain([state, 'optionalAccess', _30 => _30.isLoading])) {
|
|
2157
2366
|
return _nullishCoalesce(state, () => ( { isLoading: true }));
|
|
2158
2367
|
}
|
|
2159
2368
|
if (state.error) {
|
|
@@ -2171,7 +2380,7 @@ function selectorFor_useUser(state, userId) {
|
|
|
2171
2380
|
};
|
|
2172
2381
|
}
|
|
2173
2382
|
function selectorFor_useRoomInfo(state, roomId) {
|
|
2174
|
-
if (state === void 0 || _optionalChain([state, 'optionalAccess',
|
|
2383
|
+
if (state === void 0 || _optionalChain([state, 'optionalAccess', _31 => _31.isLoading])) {
|
|
2175
2384
|
return _nullishCoalesce(state, () => ( { isLoading: true }));
|
|
2176
2385
|
}
|
|
2177
2386
|
if (state.error) {
|
|
@@ -2189,7 +2398,7 @@ function selectorFor_useRoomInfo(state, roomId) {
|
|
|
2189
2398
|
};
|
|
2190
2399
|
}
|
|
2191
2400
|
function selectorFor_useGroupInfo(state, groupId) {
|
|
2192
|
-
if (state === void 0 || _optionalChain([state, 'optionalAccess',
|
|
2401
|
+
if (state === void 0 || _optionalChain([state, 'optionalAccess', _32 => _32.isLoading])) {
|
|
2193
2402
|
return _nullishCoalesce(state, () => ( { isLoading: true }));
|
|
2194
2403
|
}
|
|
2195
2404
|
if (state.error) {
|
|
@@ -2359,7 +2568,7 @@ function makeLiveblocksContextBundle(client) {
|
|
|
2359
2568
|
}
|
|
2360
2569
|
function useInboxNotifications_withClient(client, selector, isEqual, options) {
|
|
2361
2570
|
const { store, notificationsPoller: poller } = getLiveblocksExtrasForClient(client);
|
|
2362
|
-
const queryKey = makeInboxNotificationsQueryKey(_optionalChain([options, 'optionalAccess',
|
|
2571
|
+
const queryKey = makeInboxNotificationsQueryKey(_optionalChain([options, 'optionalAccess', _33 => _33.query]));
|
|
2363
2572
|
_react.useEffect.call(void 0,
|
|
2364
2573
|
() => void store.outputs.loadingNotifications.getOrCreate(queryKey).waitUntilLoaded()
|
|
2365
2574
|
// NOTE: Deliberately *not* using a dependency array here!
|
|
@@ -2387,7 +2596,7 @@ function useInboxNotifications_withClient(client, selector, isEqual, options) {
|
|
|
2387
2596
|
function useInboxNotificationsSuspense_withClient(client, options) {
|
|
2388
2597
|
ensureNotServerSide();
|
|
2389
2598
|
const store = getLiveblocksExtrasForClient(client).store;
|
|
2390
|
-
const queryKey = makeInboxNotificationsQueryKey(_optionalChain([options, 'optionalAccess',
|
|
2599
|
+
const queryKey = makeInboxNotificationsQueryKey(_optionalChain([options, 'optionalAccess', _34 => _34.query]));
|
|
2391
2600
|
use(
|
|
2392
2601
|
store.outputs.loadingNotifications.getOrCreate(queryKey).waitUntilLoaded()
|
|
2393
2602
|
);
|
|
@@ -2403,7 +2612,7 @@ function useInboxNotificationsSuspense_withClient(client, options) {
|
|
|
2403
2612
|
}
|
|
2404
2613
|
function useUnreadInboxNotificationsCount_withClient(client, options) {
|
|
2405
2614
|
const { store, unreadNotificationsCountPollersByQueryKey: pollers } = getLiveblocksExtrasForClient(client);
|
|
2406
|
-
const queryKey = makeInboxNotificationsQueryKey(_optionalChain([options, 'optionalAccess',
|
|
2615
|
+
const queryKey = makeInboxNotificationsQueryKey(_optionalChain([options, 'optionalAccess', _35 => _35.query]));
|
|
2407
2616
|
const poller = pollers.getOrCreate(queryKey);
|
|
2408
2617
|
_react.useEffect.call(void 0,
|
|
2409
2618
|
() => void store.outputs.unreadNotificationsCount.getOrCreate(queryKey).waitUntilLoaded()
|
|
@@ -2432,7 +2641,7 @@ function useUnreadInboxNotificationsCount_withClient(client, options) {
|
|
|
2432
2641
|
function useUnreadInboxNotificationsCountSuspense_withClient(client, options) {
|
|
2433
2642
|
ensureNotServerSide();
|
|
2434
2643
|
const store = getLiveblocksExtrasForClient(client).store;
|
|
2435
|
-
const queryKey = makeInboxNotificationsQueryKey(_optionalChain([options, 'optionalAccess',
|
|
2644
|
+
const queryKey = makeInboxNotificationsQueryKey(_optionalChain([options, 'optionalAccess', _36 => _36.query]));
|
|
2436
2645
|
use(
|
|
2437
2646
|
store.outputs.unreadNotificationsCount.getOrCreate(queryKey).waitUntilLoaded()
|
|
2438
2647
|
);
|
|
@@ -2603,7 +2812,7 @@ function useUpdateNotificationSettings_withClient(client) {
|
|
|
2603
2812
|
store.optimisticUpdates.remove(optimisticUpdateId);
|
|
2604
2813
|
if (err instanceof _core.HttpError) {
|
|
2605
2814
|
if (err.status === 422) {
|
|
2606
|
-
const msg = [_optionalChain([err, 'access',
|
|
2815
|
+
const msg = [_optionalChain([err, 'access', _37 => _37.details, 'optionalAccess', _38 => _38.error]), _optionalChain([err, 'access', _39 => _39.details, 'optionalAccess', _40 => _40.reason])].filter(Boolean).join("\n");
|
|
2607
2816
|
_core.console.error(msg);
|
|
2608
2817
|
}
|
|
2609
2818
|
client[_core.kInternal].emitError(
|
|
@@ -2838,7 +3047,7 @@ function useGroupInfoSuspense_withClient(client, groupId) {
|
|
|
2838
3047
|
function useAiChats(options) {
|
|
2839
3048
|
const client = useClient();
|
|
2840
3049
|
const store = getUmbrellaStoreForClient(client);
|
|
2841
|
-
const queryKey = makeAiChatsQueryKey(_optionalChain([options, 'optionalAccess',
|
|
3050
|
+
const queryKey = makeAiChatsQueryKey(_optionalChain([options, 'optionalAccess', _41 => _41.query]));
|
|
2842
3051
|
useEnsureAiConnection(client);
|
|
2843
3052
|
_react.useEffect.call(void 0,
|
|
2844
3053
|
() => void store.outputs.aiChats.getOrCreate(queryKey).waitUntilLoaded()
|
|
@@ -2862,7 +3071,7 @@ function useAiChatsSuspense(options) {
|
|
|
2862
3071
|
const client = useClient();
|
|
2863
3072
|
const store = getUmbrellaStoreForClient(client);
|
|
2864
3073
|
useEnsureAiConnection(client);
|
|
2865
|
-
const queryKey = makeAiChatsQueryKey(_optionalChain([options, 'optionalAccess',
|
|
3074
|
+
const queryKey = makeAiChatsQueryKey(_optionalChain([options, 'optionalAccess', _42 => _42.query]));
|
|
2866
3075
|
use(store.outputs.aiChats.getOrCreate(queryKey).waitUntilLoaded());
|
|
2867
3076
|
const result = useAiChats(options);
|
|
2868
3077
|
_core.assert.call(void 0, !result.error, "Did not expect error");
|
|
@@ -2874,7 +3083,7 @@ function useAiChatMessages(chatId, options) {
|
|
|
2874
3083
|
const store = getUmbrellaStoreForClient(client);
|
|
2875
3084
|
useEnsureAiConnection(client);
|
|
2876
3085
|
_react.useEffect.call(void 0,
|
|
2877
|
-
() => void store.outputs.messagesByChatId.getOrCreate(chatId).getOrCreate(_nullishCoalesce(_optionalChain([options, 'optionalAccess',
|
|
3086
|
+
() => void store.outputs.messagesByChatId.getOrCreate(chatId).getOrCreate(_nullishCoalesce(_optionalChain([options, 'optionalAccess', _43 => _43.branchId]), () => ( null))).waitUntilLoaded()
|
|
2878
3087
|
// NOTE: Deliberately *not* using a dependency array here!
|
|
2879
3088
|
//
|
|
2880
3089
|
// It is important to call waitUntil on *every* render.
|
|
@@ -2885,7 +3094,7 @@ function useAiChatMessages(chatId, options) {
|
|
|
2885
3094
|
// *next* render after that, a *new* fetch/promise will get created.
|
|
2886
3095
|
);
|
|
2887
3096
|
return useSignal(
|
|
2888
|
-
store.outputs.messagesByChatId.getOrCreate(chatId).getOrCreate(_nullishCoalesce(_optionalChain([options, 'optionalAccess',
|
|
3097
|
+
store.outputs.messagesByChatId.getOrCreate(chatId).getOrCreate(_nullishCoalesce(_optionalChain([options, 'optionalAccess', _44 => _44.branchId]), () => ( null))).signal
|
|
2889
3098
|
);
|
|
2890
3099
|
}
|
|
2891
3100
|
function useAiChatMessagesSuspense(chatId, options) {
|
|
@@ -2894,7 +3103,7 @@ function useAiChatMessagesSuspense(chatId, options) {
|
|
|
2894
3103
|
const store = getUmbrellaStoreForClient(client);
|
|
2895
3104
|
useEnsureAiConnection(client);
|
|
2896
3105
|
use(
|
|
2897
|
-
store.outputs.messagesByChatId.getOrCreate(chatId).getOrCreate(_nullishCoalesce(_optionalChain([options, 'optionalAccess',
|
|
3106
|
+
store.outputs.messagesByChatId.getOrCreate(chatId).getOrCreate(_nullishCoalesce(_optionalChain([options, 'optionalAccess', _45 => _45.branchId]), () => ( null))).waitUntilLoaded()
|
|
2898
3107
|
);
|
|
2899
3108
|
const result = useAiChatMessages(chatId, options);
|
|
2900
3109
|
_core.assert.call(void 0, !result.error, "Did not expect error");
|
|
@@ -3013,12 +3222,12 @@ function useAiChatStatus(chatId, branchId) {
|
|
|
3013
3222
|
if (result.error) return IDLE;
|
|
3014
3223
|
const messages = result.messages;
|
|
3015
3224
|
const lastMessage = messages[messages.length - 1];
|
|
3016
|
-
if (_optionalChain([lastMessage, 'optionalAccess',
|
|
3225
|
+
if (_optionalChain([lastMessage, 'optionalAccess', _46 => _46.role]) !== "assistant") return IDLE;
|
|
3017
3226
|
if (lastMessage.status !== "generating" && lastMessage.status !== "awaiting-tool")
|
|
3018
3227
|
return IDLE;
|
|
3019
3228
|
const contentSoFar = lastMessage.contentSoFar;
|
|
3020
3229
|
const lastPart = contentSoFar[contentSoFar.length - 1];
|
|
3021
|
-
if (_optionalChain([lastPart, 'optionalAccess',
|
|
3230
|
+
if (_optionalChain([lastPart, 'optionalAccess', _47 => _47.type]) === "tool-invocation") {
|
|
3022
3231
|
return {
|
|
3023
3232
|
status: "generating",
|
|
3024
3233
|
partType: "tool-invocation",
|
|
@@ -3027,7 +3236,7 @@ function useAiChatStatus(chatId, branchId) {
|
|
|
3027
3236
|
} else {
|
|
3028
3237
|
return {
|
|
3029
3238
|
status: "generating",
|
|
3030
|
-
partType: _optionalChain([lastPart, 'optionalAccess',
|
|
3239
|
+
partType: _optionalChain([lastPart, 'optionalAccess', _48 => _48.type])
|
|
3031
3240
|
};
|
|
3032
3241
|
}
|
|
3033
3242
|
},
|
|
@@ -3055,7 +3264,7 @@ function useSendAiMessage(chatId, options) {
|
|
|
3055
3264
|
"chatId must be provided to either `useSendAiMessage` or its returned function."
|
|
3056
3265
|
)));
|
|
3057
3266
|
const messages = client[_core.kInternal].ai.signals.getChatMessagesForBranch\u03A3(resolvedChatId).get();
|
|
3058
|
-
if (process.env.NODE_ENV !== "production" && !messageOptionsCopilotId && !_optionalChain([options, 'optionalAccess',
|
|
3267
|
+
if (process.env.NODE_ENV !== "production" && !messageOptionsCopilotId && !_optionalChain([options, 'optionalAccess', _49 => _49.copilotId])) {
|
|
3059
3268
|
_core.console.warn(
|
|
3060
3269
|
`No copilot ID was provided to useSendAiMessage when sending the message "${messageText.slice(
|
|
3061
3270
|
0,
|
|
@@ -3067,8 +3276,8 @@ To ensure the correct copilot ID is used, specify it either through the hook as
|
|
|
3067
3276
|
)}\u2026", copilotId: "co_xxx" })'`
|
|
3068
3277
|
);
|
|
3069
3278
|
}
|
|
3070
|
-
const resolvedCopilotId = _nullishCoalesce(_nullishCoalesce(messageOptionsCopilotId, () => ( _optionalChain([options, 'optionalAccess',
|
|
3071
|
-
const lastMessageId = _nullishCoalesce(_optionalChain([messages, 'access',
|
|
3279
|
+
const resolvedCopilotId = _nullishCoalesce(_nullishCoalesce(messageOptionsCopilotId, () => ( _optionalChain([options, 'optionalAccess', _50 => _50.copilotId]))), () => ( client[_core.kInternal].ai.getLastUsedCopilotId(resolvedChatId)));
|
|
3280
|
+
const lastMessageId = _nullishCoalesce(_optionalChain([messages, 'access', _51 => _51[messages.length - 1], 'optionalAccess', _52 => _52.id]), () => ( null));
|
|
3072
3281
|
const content = [{ type: "text", text: messageText }];
|
|
3073
3282
|
const newMessageId = client[_core.kInternal].ai[_core.kInternal].context.messagesStore.createOptimistically(
|
|
3074
3283
|
resolvedChatId,
|
|
@@ -3088,14 +3297,14 @@ To ensure the correct copilot ID is used, specify it either through the hook as
|
|
|
3088
3297
|
{ id: newMessageId, parentMessageId: lastMessageId, content },
|
|
3089
3298
|
targetMessageId,
|
|
3090
3299
|
{
|
|
3091
|
-
stream: _nullishCoalesce(messageOptions.stream, () => ( _optionalChain([options, 'optionalAccess',
|
|
3300
|
+
stream: _nullishCoalesce(messageOptions.stream, () => ( _optionalChain([options, 'optionalAccess', _53 => _53.stream]))),
|
|
3092
3301
|
copilotId: resolvedCopilotId,
|
|
3093
|
-
timeout: _nullishCoalesce(messageOptions.timeout, () => ( _optionalChain([options, 'optionalAccess',
|
|
3302
|
+
timeout: _nullishCoalesce(messageOptions.timeout, () => ( _optionalChain([options, 'optionalAccess', _54 => _54.timeout])))
|
|
3094
3303
|
}
|
|
3095
3304
|
);
|
|
3096
3305
|
return newMessage;
|
|
3097
3306
|
},
|
|
3098
|
-
[client, chatId, _optionalChain([options, 'optionalAccess',
|
|
3307
|
+
[client, chatId, _optionalChain([options, 'optionalAccess', _55 => _55.copilotId]), _optionalChain([options, 'optionalAccess', _56 => _56.stream]), _optionalChain([options, 'optionalAccess', _57 => _57.timeout])]
|
|
3099
3308
|
);
|
|
3100
3309
|
}
|
|
3101
3310
|
function createSharedContext(client) {
|
|
@@ -3130,7 +3339,7 @@ function createSharedContext(client) {
|
|
|
3130
3339
|
}
|
|
3131
3340
|
function useEnsureNoLiveblocksProvider(options) {
|
|
3132
3341
|
const existing = useClientOrNull();
|
|
3133
|
-
if (!_optionalChain([options, 'optionalAccess',
|
|
3342
|
+
if (!_optionalChain([options, 'optionalAccess', _58 => _58.allowNesting]) && existing !== null) {
|
|
3134
3343
|
throw new Error(
|
|
3135
3344
|
"You cannot nest multiple LiveblocksProvider instances in the same React tree."
|
|
3136
3345
|
);
|
|
@@ -3293,7 +3502,7 @@ var _useAiChatMessagesSuspense = useAiChatMessagesSuspense;
|
|
|
3293
3502
|
var _useUrlMetadata = useUrlMetadata;
|
|
3294
3503
|
var _useUrlMetadataSuspense = useUrlMetadataSuspense;
|
|
3295
3504
|
function useSyncStatus_withClient(client, options) {
|
|
3296
|
-
const smooth = useInitial(_nullishCoalesce(_optionalChain([options, 'optionalAccess',
|
|
3505
|
+
const smooth = useInitial(_nullishCoalesce(_optionalChain([options, 'optionalAccess', _59 => _59.smooth]), () => ( false)));
|
|
3297
3506
|
if (smooth) {
|
|
3298
3507
|
return useSyncStatusSmooth_withClient(client);
|
|
3299
3508
|
} else {
|
|
@@ -3465,8 +3674,8 @@ function makeRoomExtrasForClient(client) {
|
|
|
3465
3674
|
if (innerError.status === 403) {
|
|
3466
3675
|
const detailedMessage = [
|
|
3467
3676
|
innerError.message,
|
|
3468
|
-
_optionalChain([innerError, 'access',
|
|
3469
|
-
_optionalChain([innerError, 'access',
|
|
3677
|
+
_optionalChain([innerError, 'access', _60 => _60.details, 'optionalAccess', _61 => _61.suggestion]),
|
|
3678
|
+
_optionalChain([innerError, 'access', _62 => _62.details, 'optionalAccess', _63 => _63.docs])
|
|
3470
3679
|
].filter(Boolean).join("\n");
|
|
3471
3680
|
_core.console.error(detailedMessage);
|
|
3472
3681
|
}
|
|
@@ -3647,6 +3856,33 @@ function RoomProviderInner(props) {
|
|
|
3647
3856
|
(message) => void handleCommentEvent(message)
|
|
3648
3857
|
);
|
|
3649
3858
|
}, [client, room]);
|
|
3859
|
+
_react.useEffect.call(void 0, () => {
|
|
3860
|
+
const { store } = getRoomExtrasForClient(client);
|
|
3861
|
+
function handleFeedEvent(message) {
|
|
3862
|
+
switch (message.type) {
|
|
3863
|
+
case _core.ServerMsgCode.FEEDS_ADDED:
|
|
3864
|
+
case _core.ServerMsgCode.FEEDS_UPDATED:
|
|
3865
|
+
store.upsertFeeds(room.id, message.feeds);
|
|
3866
|
+
break;
|
|
3867
|
+
case _core.ServerMsgCode.FEED_DELETED:
|
|
3868
|
+
store.deleteFeed(room.id, message.feedId);
|
|
3869
|
+
break;
|
|
3870
|
+
case _core.ServerMsgCode.FEED_MESSAGES_ADDED:
|
|
3871
|
+
case _core.ServerMsgCode.FEED_MESSAGES_UPDATED:
|
|
3872
|
+
store.upsertFeedMessages(room.id, message.feedId, message.messages);
|
|
3873
|
+
break;
|
|
3874
|
+
case _core.ServerMsgCode.FEED_MESSAGES_DELETED:
|
|
3875
|
+
store.deleteFeedMessages(room.id, message.feedId, message.messageIds);
|
|
3876
|
+
break;
|
|
3877
|
+
// FEEDS_LIST and FEED_MESSAGES_LIST are handled by fetch promise resolution in room.ts
|
|
3878
|
+
default:
|
|
3879
|
+
break;
|
|
3880
|
+
}
|
|
3881
|
+
}
|
|
3882
|
+
return room.events.feeds.subscribe(
|
|
3883
|
+
(message) => void handleFeedEvent(message)
|
|
3884
|
+
);
|
|
3885
|
+
}, [client, room]);
|
|
3650
3886
|
_react.useEffect.call(void 0, () => {
|
|
3651
3887
|
const pair = stableEnterRoom(roomId, frozenProps);
|
|
3652
3888
|
setRoomLeavePair(pair);
|
|
@@ -3662,7 +3898,7 @@ function RoomProviderInner(props) {
|
|
|
3662
3898
|
}
|
|
3663
3899
|
function useRoom_withRoomContext(RoomContext, options) {
|
|
3664
3900
|
const room = useRoomOrNull(RoomContext);
|
|
3665
|
-
if (room === null && !_optionalChain([options, 'optionalAccess',
|
|
3901
|
+
if (room === null && !_optionalChain([options, 'optionalAccess', _64 => _64.allowOutsideRoom])) {
|
|
3666
3902
|
throw new Error("RoomProvider is missing from the React tree.");
|
|
3667
3903
|
}
|
|
3668
3904
|
return room;
|
|
@@ -4089,6 +4325,126 @@ function useThreads_withRoomContext(RoomContext, options = {}) {
|
|
|
4089
4325
|
useScrollToCommentOnLoadEffect(scrollOnLoad, result);
|
|
4090
4326
|
return result;
|
|
4091
4327
|
}
|
|
4328
|
+
function useFeeds_withRoomContext(RoomContext, options) {
|
|
4329
|
+
const room = useRoom_withRoomContext(RoomContext);
|
|
4330
|
+
const client = useClient();
|
|
4331
|
+
const { store } = getRoomExtrasForClient(client);
|
|
4332
|
+
const queryKey = makeFeedsQueryKey(room.id, options);
|
|
4333
|
+
const loadableResource = store.outputs.loadingFeeds.getOrCreate(queryKey);
|
|
4334
|
+
_react.useEffect.call(void 0, () => {
|
|
4335
|
+
void loadableResource.waitUntilLoaded();
|
|
4336
|
+
}, [room, loadableResource]);
|
|
4337
|
+
return useSignal(loadableResource.signal);
|
|
4338
|
+
}
|
|
4339
|
+
function useFeeds(options) {
|
|
4340
|
+
return useFeeds_withRoomContext(GlobalRoomContext, options);
|
|
4341
|
+
}
|
|
4342
|
+
function useFeedMessages_withRoomContext(RoomContext, feedId, options) {
|
|
4343
|
+
const room = useRoom_withRoomContext(RoomContext);
|
|
4344
|
+
const client = useClient();
|
|
4345
|
+
const { store } = getRoomExtrasForClient(client);
|
|
4346
|
+
const queryKey = makeFeedMessagesQueryKey(room.id, feedId, options);
|
|
4347
|
+
_react.useEffect.call(void 0, () => {
|
|
4348
|
+
void store.outputs.loadingFeedMessages.getOrCreate(queryKey).waitUntilLoaded();
|
|
4349
|
+
});
|
|
4350
|
+
return useSignal(
|
|
4351
|
+
store.outputs.loadingFeedMessages.getOrCreate(queryKey).signal
|
|
4352
|
+
);
|
|
4353
|
+
}
|
|
4354
|
+
function useFeedMessages(feedId, options) {
|
|
4355
|
+
return useFeedMessages_withRoomContext(GlobalRoomContext, feedId, options);
|
|
4356
|
+
}
|
|
4357
|
+
function useFeedsSuspense_withRoomContext(RoomContext, options) {
|
|
4358
|
+
ensureNotServerSide();
|
|
4359
|
+
const client = useClient();
|
|
4360
|
+
const room = useRoom_withRoomContext(RoomContext);
|
|
4361
|
+
const { store } = getRoomExtrasForClient(client);
|
|
4362
|
+
const queryKey = makeFeedsQueryKey(room.id, options);
|
|
4363
|
+
use(store.outputs.loadingFeeds.getOrCreate(queryKey).waitUntilLoaded());
|
|
4364
|
+
const result = useFeeds_withRoomContext(RoomContext, options);
|
|
4365
|
+
_core.assert.call(void 0, !result.error, "Did not expect error");
|
|
4366
|
+
_core.assert.call(void 0, !result.isLoading, "Did not expect loading");
|
|
4367
|
+
return result;
|
|
4368
|
+
}
|
|
4369
|
+
function useFeedsSuspense(options) {
|
|
4370
|
+
return useFeedsSuspense_withRoomContext(GlobalRoomContext, options);
|
|
4371
|
+
}
|
|
4372
|
+
function useFeedMessagesSuspense_withRoomContext(RoomContext, feedId, options) {
|
|
4373
|
+
ensureNotServerSide();
|
|
4374
|
+
const client = useClient();
|
|
4375
|
+
const room = useRoom_withRoomContext(RoomContext);
|
|
4376
|
+
const { store } = getRoomExtrasForClient(client);
|
|
4377
|
+
const queryKey = makeFeedMessagesQueryKey(room.id, feedId, options);
|
|
4378
|
+
use(store.outputs.loadingFeedMessages.getOrCreate(queryKey).waitUntilLoaded());
|
|
4379
|
+
const result = useFeedMessages_withRoomContext(RoomContext, feedId, options);
|
|
4380
|
+
_core.assert.call(void 0, !result.error, "Did not expect error");
|
|
4381
|
+
_core.assert.call(void 0, !result.isLoading, "Did not expect loading");
|
|
4382
|
+
return result;
|
|
4383
|
+
}
|
|
4384
|
+
function useFeedMessagesSuspense(feedId, options) {
|
|
4385
|
+
return useFeedMessagesSuspense_withRoomContext(
|
|
4386
|
+
GlobalRoomContext,
|
|
4387
|
+
feedId,
|
|
4388
|
+
options
|
|
4389
|
+
);
|
|
4390
|
+
}
|
|
4391
|
+
function useCreateFeed_withRoomContext(RoomContext) {
|
|
4392
|
+
const room = useRoom_withRoomContext(RoomContext);
|
|
4393
|
+
return _react.useCallback.call(void 0,
|
|
4394
|
+
(feedId, options) => room.addFeed(feedId, options),
|
|
4395
|
+
[room]
|
|
4396
|
+
);
|
|
4397
|
+
}
|
|
4398
|
+
function useCreateFeed() {
|
|
4399
|
+
return useCreateFeed_withRoomContext(GlobalRoomContext);
|
|
4400
|
+
}
|
|
4401
|
+
function useDeleteFeed_withRoomContext(RoomContext) {
|
|
4402
|
+
const room = useRoom_withRoomContext(RoomContext);
|
|
4403
|
+
return _react.useCallback.call(void 0, (feedId) => room.deleteFeed(feedId), [room]);
|
|
4404
|
+
}
|
|
4405
|
+
function useDeleteFeed() {
|
|
4406
|
+
return useDeleteFeed_withRoomContext(GlobalRoomContext);
|
|
4407
|
+
}
|
|
4408
|
+
function useUpdateFeedMetadata_withRoomContext(RoomContext) {
|
|
4409
|
+
const room = useRoom_withRoomContext(RoomContext);
|
|
4410
|
+
return _react.useCallback.call(void 0,
|
|
4411
|
+
(feedId, metadata) => room.updateFeed(feedId, metadata),
|
|
4412
|
+
[room]
|
|
4413
|
+
);
|
|
4414
|
+
}
|
|
4415
|
+
function useUpdateFeedMetadata() {
|
|
4416
|
+
return useUpdateFeedMetadata_withRoomContext(GlobalRoomContext);
|
|
4417
|
+
}
|
|
4418
|
+
function useCreateFeedMessage_withRoomContext(RoomContext) {
|
|
4419
|
+
const room = useRoom_withRoomContext(RoomContext);
|
|
4420
|
+
return _react.useCallback.call(void 0,
|
|
4421
|
+
(feedId, data, options) => room.addFeedMessage(feedId, data, options),
|
|
4422
|
+
[room]
|
|
4423
|
+
);
|
|
4424
|
+
}
|
|
4425
|
+
function useCreateFeedMessage() {
|
|
4426
|
+
return useCreateFeedMessage_withRoomContext(GlobalRoomContext);
|
|
4427
|
+
}
|
|
4428
|
+
function useDeleteFeedMessage_withRoomContext(RoomContext) {
|
|
4429
|
+
const room = useRoom_withRoomContext(RoomContext);
|
|
4430
|
+
return _react.useCallback.call(void 0,
|
|
4431
|
+
(feedId, messageId) => room.deleteFeedMessage(feedId, messageId),
|
|
4432
|
+
[room]
|
|
4433
|
+
);
|
|
4434
|
+
}
|
|
4435
|
+
function useDeleteFeedMessage() {
|
|
4436
|
+
return useDeleteFeedMessage_withRoomContext(GlobalRoomContext);
|
|
4437
|
+
}
|
|
4438
|
+
function useUpdateFeedMessage_withRoomContext(RoomContext) {
|
|
4439
|
+
const room = useRoom_withRoomContext(RoomContext);
|
|
4440
|
+
return _react.useCallback.call(void 0,
|
|
4441
|
+
(feedId, messageId, data, options) => room.updateFeedMessage(feedId, messageId, data, options),
|
|
4442
|
+
[room]
|
|
4443
|
+
);
|
|
4444
|
+
}
|
|
4445
|
+
function useUpdateFeedMessage() {
|
|
4446
|
+
return useUpdateFeedMessage_withRoomContext(GlobalRoomContext);
|
|
4447
|
+
}
|
|
4092
4448
|
function useThreads(options = {}) {
|
|
4093
4449
|
return useThreads_withRoomContext(GlobalRoomContext, options);
|
|
4094
4450
|
}
|
|
@@ -4102,7 +4458,7 @@ function useSearchComments_withRoomContext(RoomContext, options) {
|
|
|
4102
4458
|
const room = useRoom_withRoomContext(RoomContext);
|
|
4103
4459
|
const queryKey = _core.stableStringify.call(void 0, [room.id, options.query]);
|
|
4104
4460
|
_react.useEffect.call(void 0, () => {
|
|
4105
|
-
const currentRequestId = (_nullishCoalesce(_optionalChain([currentRequestInfo, 'access',
|
|
4461
|
+
const currentRequestId = (_nullishCoalesce(_optionalChain([currentRequestInfo, 'access', _65 => _65.current, 'optionalAccess', _66 => _66.id]), () => ( 0))) + 1;
|
|
4106
4462
|
const controller = new AbortController();
|
|
4107
4463
|
currentRequestInfo.current = { id: currentRequestId, controller };
|
|
4108
4464
|
setResult((result2) => {
|
|
@@ -4119,12 +4475,12 @@ function useSearchComments_withRoomContext(RoomContext, options) {
|
|
|
4119
4475
|
{ signal: controller.signal }
|
|
4120
4476
|
).then(({ data }) => {
|
|
4121
4477
|
if (controller.signal.aborted) return;
|
|
4122
|
-
if (_optionalChain([currentRequestInfo, 'access',
|
|
4478
|
+
if (_optionalChain([currentRequestInfo, 'access', _67 => _67.current, 'optionalAccess', _68 => _68.id]) !== currentRequestId) return;
|
|
4123
4479
|
setResult({ isLoading: false, results: data });
|
|
4124
4480
|
currentRequestInfo.current = null;
|
|
4125
4481
|
}).catch((err) => {
|
|
4126
4482
|
if (controller.signal.aborted) return;
|
|
4127
|
-
if (_optionalChain([currentRequestInfo, 'access',
|
|
4483
|
+
if (_optionalChain([currentRequestInfo, 'access', _69 => _69.current, 'optionalAccess', _70 => _70.id]) !== currentRequestId) return;
|
|
4128
4484
|
setResult({ isLoading: false, error: err });
|
|
4129
4485
|
currentRequestInfo.current = null;
|
|
4130
4486
|
});
|
|
@@ -4191,7 +4547,7 @@ function useCreateRoomThread(roomId) {
|
|
|
4191
4547
|
thread: newThread,
|
|
4192
4548
|
roomId
|
|
4193
4549
|
});
|
|
4194
|
-
const attachmentIds = _optionalChain([attachments, 'optionalAccess',
|
|
4550
|
+
const attachmentIds = _optionalChain([attachments, 'optionalAccess', _71 => _71.map, 'call', _72 => _72((attachment) => attachment.id)]);
|
|
4195
4551
|
client[_core.kInternal].httpClient.createThread({
|
|
4196
4552
|
roomId,
|
|
4197
4553
|
threadId,
|
|
@@ -4236,7 +4592,7 @@ function useDeleteRoomThread(roomId) {
|
|
|
4236
4592
|
const { store, onMutationFailure } = getRoomExtrasForClient(client);
|
|
4237
4593
|
const userId = getCurrentUserId(client);
|
|
4238
4594
|
const existing = store.outputs.threads.get().get(threadId);
|
|
4239
|
-
if (_optionalChain([existing, 'optionalAccess',
|
|
4595
|
+
if (_optionalChain([existing, 'optionalAccess', _73 => _73.comments, 'optionalAccess', _74 => _74[0], 'optionalAccess', _75 => _75.userId]) !== userId) {
|
|
4240
4596
|
throw new Error("Only the thread creator can delete the thread");
|
|
4241
4597
|
}
|
|
4242
4598
|
const optimisticId = store.optimisticUpdates.add({
|
|
@@ -4388,7 +4744,7 @@ function useCreateRoomComment(roomId) {
|
|
|
4388
4744
|
type: "create-comment",
|
|
4389
4745
|
comment
|
|
4390
4746
|
});
|
|
4391
|
-
const attachmentIds = _optionalChain([attachments, 'optionalAccess',
|
|
4747
|
+
const attachmentIds = _optionalChain([attachments, 'optionalAccess', _76 => _76.map, 'call', _77 => _77((attachment) => attachment.id)]);
|
|
4392
4748
|
client[_core.kInternal].httpClient.createComment({
|
|
4393
4749
|
roomId,
|
|
4394
4750
|
threadId,
|
|
@@ -4466,7 +4822,7 @@ function useEditRoomComment(roomId) {
|
|
|
4466
4822
|
metadata: updatedMetadata
|
|
4467
4823
|
}
|
|
4468
4824
|
});
|
|
4469
|
-
const attachmentIds = _optionalChain([attachments, 'optionalAccess',
|
|
4825
|
+
const attachmentIds = _optionalChain([attachments, 'optionalAccess', _78 => _78.map, 'call', _79 => _79((attachment) => attachment.id)]);
|
|
4470
4826
|
client[_core.kInternal].httpClient.editComment({
|
|
4471
4827
|
roomId,
|
|
4472
4828
|
threadId,
|
|
@@ -4852,7 +5208,7 @@ function useRoomThreadSubscription(roomId, threadId) {
|
|
|
4852
5208
|
}
|
|
4853
5209
|
return {
|
|
4854
5210
|
status: "subscribed",
|
|
4855
|
-
unreadSince: _nullishCoalesce(_optionalChain([notification, 'optionalAccess',
|
|
5211
|
+
unreadSince: _nullishCoalesce(_optionalChain([notification, 'optionalAccess', _80 => _80.readAt]), () => ( null)),
|
|
4856
5212
|
subscribe,
|
|
4857
5213
|
unsubscribe
|
|
4858
5214
|
};
|
|
@@ -5030,9 +5386,6 @@ function useSuspendUntilPresenceReady_withRoomContext(RoomContext) {
|
|
|
5030
5386
|
const room = useRoom_withRoomContext(RoomContext);
|
|
5031
5387
|
use(room.waitUntilPresenceReady());
|
|
5032
5388
|
}
|
|
5033
|
-
function useSuspendUntilPresenceReady() {
|
|
5034
|
-
return useSuspendUntilPresenceReady_withRoomContext(GlobalRoomContext);
|
|
5035
|
-
}
|
|
5036
5389
|
function useSelfSuspense_withRoomContext(RoomContext, selector, isEqual) {
|
|
5037
5390
|
useSuspendUntilPresenceReady_withRoomContext(RoomContext);
|
|
5038
5391
|
return useSelf_withRoomContext(
|
|
@@ -5107,9 +5460,6 @@ function useSuspendUntilStorageReady_withRoomContext(RoomContext) {
|
|
|
5107
5460
|
const room = useRoom_withRoomContext(RoomContext);
|
|
5108
5461
|
use(room.waitUntilStorageReady());
|
|
5109
5462
|
}
|
|
5110
|
-
function useSuspendUntilStorageReady() {
|
|
5111
|
-
return useSuspendUntilStorageReady_withRoomContext(GlobalRoomContext);
|
|
5112
|
-
}
|
|
5113
5463
|
function useStorageSuspense_withRoomContext(RoomContext, selector, isEqual) {
|
|
5114
5464
|
useSuspendUntilStorageReady_withRoomContext(RoomContext);
|
|
5115
5465
|
return useStorage_withRoomContext(
|
|
@@ -5141,7 +5491,7 @@ function useThreadsSuspense(options = {}) {
|
|
|
5141
5491
|
return useThreadsSuspense_withRoomContext(GlobalRoomContext, options);
|
|
5142
5492
|
}
|
|
5143
5493
|
function selectorFor_useAttachmentUrl(state) {
|
|
5144
|
-
if (state === void 0 || _optionalChain([state, 'optionalAccess',
|
|
5494
|
+
if (state === void 0 || _optionalChain([state, 'optionalAccess', _81 => _81.isLoading])) {
|
|
5145
5495
|
return _nullishCoalesce(state, () => ( { isLoading: true }));
|
|
5146
5496
|
}
|
|
5147
5497
|
if (state.error) {
|
|
@@ -5398,6 +5748,36 @@ function createRoomContext(client) {
|
|
|
5398
5748
|
function useUpdateRoomSubscriptionSettings_withBoundRoomContext() {
|
|
5399
5749
|
return useUpdateRoomSubscriptionSettings_withRoomContext(BoundRoomContext);
|
|
5400
5750
|
}
|
|
5751
|
+
function useFeeds_withBoundRoomContext(...args) {
|
|
5752
|
+
return useFeeds_withRoomContext(BoundRoomContext, ...args);
|
|
5753
|
+
}
|
|
5754
|
+
function useFeedMessages_withBoundRoomContext(...args) {
|
|
5755
|
+
return useFeedMessages_withRoomContext(BoundRoomContext, ...args);
|
|
5756
|
+
}
|
|
5757
|
+
function useFeedsSuspense_withBoundRoomContext(...args) {
|
|
5758
|
+
return useFeedsSuspense_withRoomContext(BoundRoomContext, ...args);
|
|
5759
|
+
}
|
|
5760
|
+
function useFeedMessagesSuspense_withBoundRoomContext(...args) {
|
|
5761
|
+
return useFeedMessagesSuspense_withRoomContext(BoundRoomContext, ...args);
|
|
5762
|
+
}
|
|
5763
|
+
function useCreateFeed_withBoundRoomContext() {
|
|
5764
|
+
return useCreateFeed_withRoomContext(BoundRoomContext);
|
|
5765
|
+
}
|
|
5766
|
+
function useDeleteFeed_withBoundRoomContext() {
|
|
5767
|
+
return useDeleteFeed_withRoomContext(BoundRoomContext);
|
|
5768
|
+
}
|
|
5769
|
+
function useUpdateFeedMetadata_withBoundRoomContext() {
|
|
5770
|
+
return useUpdateFeedMetadata_withRoomContext(BoundRoomContext);
|
|
5771
|
+
}
|
|
5772
|
+
function useCreateFeedMessage_withBoundRoomContext() {
|
|
5773
|
+
return useCreateFeedMessage_withRoomContext(BoundRoomContext);
|
|
5774
|
+
}
|
|
5775
|
+
function useDeleteFeedMessage_withBoundRoomContext() {
|
|
5776
|
+
return useDeleteFeedMessage_withRoomContext(BoundRoomContext);
|
|
5777
|
+
}
|
|
5778
|
+
function useUpdateFeedMessage_withBoundRoomContext() {
|
|
5779
|
+
return useUpdateFeedMessage_withRoomContext(BoundRoomContext);
|
|
5780
|
+
}
|
|
5401
5781
|
const shared = createSharedContext(client);
|
|
5402
5782
|
const bundle = {
|
|
5403
5783
|
RoomContext: BoundRoomContext,
|
|
@@ -5447,6 +5827,22 @@ function createRoomContext(client) {
|
|
|
5447
5827
|
// prettier-ignore
|
|
5448
5828
|
useThreads: useThreads_withBoundRoomContext,
|
|
5449
5829
|
// prettier-ignore
|
|
5830
|
+
useFeeds: useFeeds_withBoundRoomContext,
|
|
5831
|
+
// prettier-ignore
|
|
5832
|
+
useFeedMessages: useFeedMessages_withBoundRoomContext,
|
|
5833
|
+
// prettier-ignore
|
|
5834
|
+
useCreateFeed: useCreateFeed_withBoundRoomContext,
|
|
5835
|
+
// prettier-ignore
|
|
5836
|
+
useDeleteFeed: useDeleteFeed_withBoundRoomContext,
|
|
5837
|
+
// prettier-ignore
|
|
5838
|
+
useUpdateFeedMetadata: useUpdateFeedMetadata_withBoundRoomContext,
|
|
5839
|
+
// prettier-ignore
|
|
5840
|
+
useCreateFeedMessage: useCreateFeedMessage_withBoundRoomContext,
|
|
5841
|
+
// prettier-ignore
|
|
5842
|
+
useDeleteFeedMessage: useDeleteFeedMessage_withBoundRoomContext,
|
|
5843
|
+
// prettier-ignore
|
|
5844
|
+
useUpdateFeedMessage: useUpdateFeedMessage_withBoundRoomContext,
|
|
5845
|
+
// prettier-ignore
|
|
5450
5846
|
useCreateThread: useCreateThread_withBoundRoomContext,
|
|
5451
5847
|
// prettier-ignore
|
|
5452
5848
|
useDeleteThread: useDeleteThread_withBoundRoomContext,
|
|
@@ -5537,6 +5933,22 @@ function createRoomContext(client) {
|
|
|
5537
5933
|
// prettier-ignore
|
|
5538
5934
|
useThreads: useThreadsSuspense_withBoundRoomContext,
|
|
5539
5935
|
// prettier-ignore
|
|
5936
|
+
useFeeds: useFeedsSuspense_withBoundRoomContext,
|
|
5937
|
+
// prettier-ignore
|
|
5938
|
+
useFeedMessages: useFeedMessagesSuspense_withBoundRoomContext,
|
|
5939
|
+
// prettier-ignore
|
|
5940
|
+
useCreateFeed: useCreateFeed_withBoundRoomContext,
|
|
5941
|
+
// prettier-ignore
|
|
5942
|
+
useDeleteFeed: useDeleteFeed_withBoundRoomContext,
|
|
5943
|
+
// prettier-ignore
|
|
5944
|
+
useUpdateFeedMetadata: useUpdateFeedMetadata_withBoundRoomContext,
|
|
5945
|
+
// prettier-ignore
|
|
5946
|
+
useCreateFeedMessage: useCreateFeedMessage_withBoundRoomContext,
|
|
5947
|
+
// prettier-ignore
|
|
5948
|
+
useDeleteFeedMessage: useDeleteFeedMessage_withBoundRoomContext,
|
|
5949
|
+
// prettier-ignore
|
|
5950
|
+
useUpdateFeedMessage: useUpdateFeedMessage_withBoundRoomContext,
|
|
5951
|
+
// prettier-ignore
|
|
5540
5952
|
useCreateThread: useCreateThread_withBoundRoomContext,
|
|
5541
5953
|
// prettier-ignore
|
|
5542
5954
|
useDeleteThread: useDeleteThread_withBoundRoomContext,
|
|
@@ -5601,6 +6013,10 @@ var _useMyPresence = useMyPresence;
|
|
|
5601
6013
|
var _useOthersMapped = useOthersMapped;
|
|
5602
6014
|
var _useOthersMappedSuspense = useOthersMappedSuspense;
|
|
5603
6015
|
var _useThreads = useThreads;
|
|
6016
|
+
var _useFeeds = useFeeds;
|
|
6017
|
+
var _useFeedMessages = useFeedMessages;
|
|
6018
|
+
var _useFeedsSuspense = useFeedsSuspense;
|
|
6019
|
+
var _useFeedMessagesSuspense = useFeedMessagesSuspense;
|
|
5604
6020
|
var _useSearchComments = useSearchComments;
|
|
5605
6021
|
var _useThreadsSuspense = useThreadsSuspense;
|
|
5606
6022
|
var _useRoomSubscriptionSettings = useRoomSubscriptionSettings;
|
|
@@ -5752,5 +6168,12 @@ var _useUpdateMyPresence = useUpdateMyPresence;
|
|
|
5752
6168
|
|
|
5753
6169
|
|
|
5754
6170
|
|
|
5755
|
-
|
|
5756
|
-
|
|
6171
|
+
|
|
6172
|
+
|
|
6173
|
+
|
|
6174
|
+
|
|
6175
|
+
|
|
6176
|
+
|
|
6177
|
+
|
|
6178
|
+
exports.ClientContext = ClientContext; exports.useClientOrNull = useClientOrNull; exports.useClient = useClient; exports.GlobalRoomContext = GlobalRoomContext; 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.useCreateFeed = useCreateFeed; exports.useDeleteFeed = useDeleteFeed; exports.useUpdateFeedMetadata = useUpdateFeedMetadata; exports.useCreateFeedMessage = useCreateFeedMessage; exports.useDeleteFeedMessage = useDeleteFeedMessage; exports.useUpdateFeedMessage = useUpdateFeedMessage; 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.useMarkRoomThreadAsRead = useMarkRoomThreadAsRead; exports.useMarkThreadAsRead = useMarkThreadAsRead; 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._useFeeds = _useFeeds; exports._useFeedMessages = _useFeedMessages; exports._useFeedsSuspense = _useFeedsSuspense; exports._useFeedMessagesSuspense = _useFeedMessagesSuspense; 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;
|
|
6179
|
+
//# sourceMappingURL=chunk-HFTIBRCD.cjs.map
|