@liveblocks/react 2.14.0 → 2.15.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.
@@ -1,8 +1,9 @@
1
+ import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import * as react from 'react';
3
+ import { Context, PropsWithChildren, ReactNode } from 'react';
1
4
  import { JsonObject, LsonObject, BaseUserMeta, LiveObject, User, Json, RoomNotificationSettings, Room, Status, BroadcastOptions, OthersEvent, LostConnectionEvent, History, BaseMetadata as BaseMetadata$1, Client as Client$1, ClientOptions, StorageStatus as StorageStatus$1, ThreadData as ThreadData$1, CommentData as CommentData$1 } from '@liveblocks/client';
2
5
  import * as _liveblocks_core from '@liveblocks/core';
3
- import { BaseMetadata, CommentBody, Patchable, StorageStatus, QueryMetadata, AsyncResult, DRI, AsyncSuccess, Resolve, CommentAttachment, PartialUnless, InboxNotificationData, ToImmutable, AsyncLoading, AsyncError, ThreadData, HistoryVersion, Client, SyncStatus, LiveblocksError, RoomEventMessage, CommentData, ThreadDataWithDeleteInfo, OpaqueClient, Permission, CommentUserReaction, ThreadDeleteInfo, InboxNotificationDeleteInfo, RoomNotificationSettings as RoomNotificationSettings$1, DistributiveOmit, DU, DM, OpaqueRoom, TextEditorType, DP, DS, DE } from '@liveblocks/core';
4
- import * as React$1 from 'react';
5
- import React__default, { PropsWithChildren } from 'react';
6
+ import { BaseMetadata, CommentBody, Patchable, StorageStatus, QueryMetadata, AsyncResult, DRI, AsyncSuccess, Resolve, CommentAttachment, PartialUnless, InboxNotificationData, ToImmutable, AsyncLoading, AsyncError, ThreadData, HistoryVersion, Client, SyncStatus, LiveblocksError, RoomEventMessage, CommentData, MutableSignal, ThreadDataWithDeleteInfo, ThreadDeleteInfo, DerivedSignal, OpaqueClient, CommentUserReaction, InboxNotificationDeleteInfo, RoomNotificationSettings as RoomNotificationSettings$1, Permission, BaseUserMeta as BaseUserMeta$1, DistributiveOmit, DU, DM, OpaqueRoom, TextEditorType, IYjsProvider, DP, DS, DE } from '@liveblocks/core';
6
7
 
7
8
  /**
8
9
  * @private Internal API, do not rely on it.
@@ -232,7 +233,7 @@ declare type RoomProviderProps<P extends JsonObject, S extends LsonObject> = Res
232
233
  * The id of the room you want to connect to
233
234
  */
234
235
  id: string;
235
- children: React.ReactNode;
236
+ children: ReactNode;
236
237
  /**
237
238
  * Whether or not the room should connect to Liveblocks servers
238
239
  * when the RoomProvider is rendered.
@@ -242,21 +243,6 @@ declare type RoomProviderProps<P extends JsonObject, S extends LsonObject> = Res
242
243
  * only on the client side.
243
244
  */
244
245
  autoConnect?: boolean;
245
- /**
246
- * If you're on React 17 or lower, pass in a reference to
247
- * `ReactDOM.unstable_batchedUpdates` or
248
- * `ReactNative.unstable_batchedUpdates` here.
249
- *
250
- * @example
251
- * import { unstable_batchedUpdates } from "react-dom";
252
- *
253
- * <RoomProvider ... unstable_batchedUpdates={unstable_batchedUpdates} />
254
- *
255
- * This will prevent you from running into the so-called "stale props"
256
- * and/or "zombie child" problem that React 17 and lower can suffer from.
257
- * Not necessary when you're on React v18 or later.
258
- */
259
- unstable_batchedUpdates?: (cb: () => void) => void;
260
246
  } & PartialUnless<P, {
261
247
  /**
262
248
  * The initial Presence to use and announce when you enter the Room. The
@@ -379,7 +365,7 @@ declare type RoomContextBundleCommon<P extends JsonObject, S extends LsonObject,
379
365
  * it can be necessary if you're building an advanced app where you need to
380
366
  * set up a context bridge between two React renderers.
381
367
  */
382
- RoomContext: React.Context<Room<P, S, U, E, M> | null>;
368
+ RoomContext: Context<Room<P, S, U, E, M> | null>;
383
369
  /**
384
370
  * Makes a Room available in the component hierarchy below.
385
371
  * Joins the room when the component is mounted, and automatically leaves
@@ -1101,7 +1087,7 @@ declare type LiveblocksContextBundle<U extends BaseUserMeta, M extends BaseMetad
1101
1087
  }>;
1102
1088
  }>;
1103
1089
 
1104
- declare type ReadonlyThreadDB<M extends BaseMetadata> = Omit<ThreadDB<M>, "upsert" | "delete">;
1090
+ declare type ReadonlyThreadDB<M extends BaseMetadata> = Omit<ThreadDB<M>, "upsert" | "delete" | "signal">;
1105
1091
  /**
1106
1092
  * This class implements a lightweight, in-memory, "database" for all Thread
1107
1093
  * instances.
@@ -1120,14 +1106,10 @@ declare type ReadonlyThreadDB<M extends BaseMetadata> = Omit<ThreadDB<M>, "upser
1120
1106
  *
1121
1107
  */
1122
1108
  declare class ThreadDB<M extends BaseMetadata> {
1123
- private _byId;
1124
- private _asc;
1125
- private _desc;
1126
- private _version;
1109
+ #private;
1110
+ readonly signal: MutableSignal<this>;
1127
1111
  constructor();
1128
1112
  clone(): ThreadDB<M>;
1129
- /** Gets the transaction count for this DB. Increments any time the DB is modified. */
1130
- get version(): number;
1131
1113
  /** Returns an existing thread by ID. Will never return a deleted thread. */
1132
1114
  get(threadId: string): ThreadData<M> | undefined;
1133
1115
  /** Returns the (possibly deleted) thread by ID. */
@@ -1136,6 +1118,10 @@ declare class ThreadDB<M extends BaseMetadata> {
1136
1118
  upsert(thread: ThreadDataWithDeleteInfo<M>): void;
1137
1119
  /** Like .upsert(), except it won't update if a thread by this ID already exists. */
1138
1120
  upsertIfNewer(thread: ThreadDataWithDeleteInfo<M>): void;
1121
+ applyDelta(updates: {
1122
+ newThreads: ThreadData<M>[];
1123
+ deletedThreads: ThreadDeleteInfo[];
1124
+ }): void;
1139
1125
  /**
1140
1126
  * Marks a thread as deleted. It will no longer pop up in .findMany()
1141
1127
  * queries, but it can still be accessed via `.getEvenIfDeleted()`.
@@ -1153,7 +1139,6 @@ declare class ThreadDB<M extends BaseMetadata> {
1153
1139
  * Will never return deleted threads in the result.
1154
1140
  */
1155
1141
  findMany(roomId: string | undefined, query: ThreadsQuery<M>, direction: "asc" | "desc"): ThreadData<M>[];
1156
- private touch;
1157
1142
  }
1158
1143
 
1159
1144
  declare type OptimisticUpdate<M extends BaseMetadata> = CreateThreadOptimisticUpdate<M> | DeleteThreadOptimisticUpdate | EditThreadMetadataOptimisticUpdate<M> | MarkThreadAsResolvedOptimisticUpdate | MarkThreadAsUnresolvedOptimisticUpdate | CreateCommentOptimisticUpdate | EditCommentOptimisticUpdate | DeleteCommentOptimisticUpdate | AddReactionOptimisticUpdate | RemoveReactionOptimisticUpdate | MarkInboxNotificationAsReadOptimisticUpdate | MarkAllInboxNotificationsAsReadOptimisticUpdate | DeleteInboxNotificationOptimisticUpdate | DeleteAllInboxNotificationsOptimisticUpdate | UpdateNotificationSettingsOptimisticUpdate;
@@ -1265,62 +1250,112 @@ declare type UsablePromise<T> = Promise<T> & ({
1265
1250
  status: "fulfilled";
1266
1251
  value: T;
1267
1252
  });
1253
+ declare type RoomId = string;
1254
+ /**
1255
+ * A lookup table (LUT) for all the history versions.
1256
+ */
1257
+ declare type VersionsLUT = Map<RoomId, Map<string, HistoryVersion>>;
1258
+ /**
1259
+ * Versions by roomId
1260
+ * e.g. { 'room-abc': {versions: "all versions"}}
1261
+ */
1262
+ declare type VersionsByRoomId = Record<RoomId, Record<string, HistoryVersion>>;
1268
1263
  /**
1269
- * Externally observable state of the store, which will have:
1270
- * - Optimistic updates applied
1271
- * - All deleted threads removed from the threads list
1264
+ * A lookup table (LUT) for all the inbox notifications.
1272
1265
  */
1273
- declare type UmbrellaStoreState<M extends BaseMetadata> = {
1266
+ declare type NotificationsLUT = Map<string, InboxNotificationData>;
1267
+ /**
1268
+ * A lookup table (LUT) for all the room notification settings.
1269
+ */
1270
+ declare type SettingsLUT = Map<RoomId, RoomNotificationSettings$1>;
1271
+ /**
1272
+ * Notification settings by room ID.
1273
+ * e.g. { 'room-abc': { threads: "all" },
1274
+ * 'room-def': { threads: "replies_and_mentions" },
1275
+ * 'room-xyz': { threads: "none" },
1276
+ * }
1277
+ */
1278
+ declare type SettingsByRoomId = Record<RoomId, RoomNotificationSettings$1>;
1279
+ declare type PermissionHintsByRoomId = Record<RoomId, Set<Permission>>;
1280
+ declare type CleanThreadifications<M extends BaseMetadata> = CleanThreads<M> & CleanNotifications;
1281
+ declare type CleanThreads<M extends BaseMetadata> = {
1274
1282
  /**
1275
1283
  * Keep track of loading and error status of all the queries made by the client.
1276
1284
  * e.g. 'room-abc-{"color":"red"}' - ok
1277
1285
  * e.g. 'room-abc-{}' - loading
1278
1286
  */
1279
1287
  threadsDB: ReadonlyThreadDB<M>;
1288
+ };
1289
+ declare type CleanNotifications = {
1280
1290
  /**
1281
1291
  * All inbox notifications in a sorted array, optimistic updates applied.
1282
1292
  */
1283
- cleanedNotifications: InboxNotificationData[];
1293
+ sortedNotifications: InboxNotificationData[];
1284
1294
  /**
1285
1295
  * Inbox notifications by ID.
1286
1296
  * e.g. `in_${string}`
1287
1297
  */
1288
1298
  notificationsById: Record<string, InboxNotificationData>;
1289
- /**
1290
- * Notification settings by room ID.
1291
- * e.g. { 'room-abc': { threads: "all" },
1292
- * 'room-def': { threads: "replies_and_mentions" },
1293
- * 'room-xyz': { threads: "none" },
1294
- * }
1295
- */
1296
- settingsByRoomId: Record<string, RoomNotificationSettings$1>;
1297
- /**
1298
- * Versions by roomId
1299
- * e.g. { 'room-abc': {versions: "all versions"}}
1300
- */
1301
- versionsByRoomId: Record<string, Record<string, HistoryVersion>>;
1299
+ };
1300
+ declare function createStore_forNotifications(): {
1301
+ signal: _liveblocks_core.ISignal<NotificationsLUT>;
1302
+ markAllRead: (readAt: Date) => void;
1303
+ markRead: (notificationId: string, readAt: Date) => void;
1304
+ delete: (inboxNotificationId: string) => void;
1305
+ applyDelta: (newInboxNotifications: InboxNotificationData[], deletedNotifications: InboxNotificationDeleteInfo[]) => void;
1306
+ clear: () => void;
1307
+ updateAssociatedNotification: (newComment: CommentData) => void;
1308
+ force_set: (mutationCallback: (lut: NotificationsLUT) => void | undefined | boolean) => void;
1309
+ invalidate: () => void;
1310
+ };
1311
+ declare function createStore_forRoomNotificationSettings(): {
1312
+ signal: _liveblocks_core.ISignal<SettingsLUT>;
1313
+ update: (roomId: string, settings: RoomNotificationSettings$1) => void;
1314
+ invalidate: () => void;
1315
+ };
1316
+ declare function createStore_forHistoryVersions(): {
1317
+ signal: _liveblocks_core.ISignal<VersionsLUT>;
1318
+ update: (roomId: string, versions: HistoryVersion[]) => void;
1319
+ force_set: (callback: (lut: VersionsLUT) => void | boolean) => void;
1320
+ invalidate: () => void;
1321
+ };
1322
+ declare function createStore_forPermissionHints(): {
1323
+ signal: _liveblocks_core.ISignal<PermissionHintsByRoomId>;
1324
+ update: (newHints: Record<string, Permission[]>) => void;
1325
+ invalidate: () => void;
1326
+ };
1327
+ declare function createStore_forOptimistic<M extends BaseMetadata>(client: Client<BaseUserMeta$1, M>): {
1328
+ signal: _liveblocks_core.ISignal<readonly OptimisticUpdate<M>[]>;
1329
+ add: (optimisticUpdate: DistributiveOmit<OptimisticUpdate<M>, "id">) => string;
1330
+ remove: (optimisticId: string) => void;
1331
+ invalidate: () => void;
1302
1332
  };
1303
1333
  declare class UmbrellaStore<M extends BaseMetadata> {
1304
- private _client;
1305
- private _syncSource;
1306
- private _rawThreadsDB;
1307
- private _prevVersion;
1308
- private _store;
1309
- private _prevState;
1310
- private _stateCached;
1311
- private _notificationsLastRequestedAt;
1312
- private _notifications;
1313
- private _roomThreadsLastRequestedAtByRoom;
1314
- private _roomThreads;
1315
- private _userThreadsLastRequestedAt;
1316
- private _userThreads;
1317
- private _roomVersions;
1318
- private _roomVersionsLastRequestedAtByRoom;
1319
- private _roomNotificationSettings;
1334
+ #private;
1335
+ readonly threads: ThreadDB<M>;
1336
+ readonly notifications: ReturnType<typeof createStore_forNotifications>;
1337
+ readonly roomNotificationSettings: ReturnType<typeof createStore_forRoomNotificationSettings>;
1338
+ readonly historyVersions: ReturnType<typeof createStore_forHistoryVersions>;
1339
+ readonly permissionHints: ReturnType<typeof createStore_forPermissionHints>;
1340
+ readonly optimisticUpdates: ReturnType<typeof createStore_forOptimistic<M>>;
1341
+ readonly outputs: {
1342
+ readonly threadifications: DerivedSignal<CleanThreadifications<M>>;
1343
+ readonly threads: DerivedSignal<CleanThreads<M>>;
1344
+ readonly notifications: DerivedSignal<CleanNotifications>;
1345
+ readonly settingsByRoomId: DerivedSignal<SettingsByRoomId>;
1346
+ readonly versionsByRoomId: DerivedSignal<VersionsByRoomId>;
1347
+ };
1320
1348
  constructor(client: OpaqueClient);
1321
- private get;
1322
- batch(callback: () => void): void;
1323
- getFullState(): UmbrellaStoreState<M>;
1349
+ get1_both(): CleanThreadifications<M>;
1350
+ subscribe1_both(callback: () => void): () => void;
1351
+ get1_threads(): CleanThreads<M>;
1352
+ subscribe1_threads(callback: () => void): () => void;
1353
+ get1_notifications(): CleanNotifications;
1354
+ subscribe1_notifications(callback: () => void): () => void;
1355
+ get2(): SettingsByRoomId;
1356
+ subscribe2(callback: () => void): () => void;
1357
+ get3(): VersionsByRoomId;
1358
+ subscribe3(callback: () => void): () => void;
1324
1359
  /**
1325
1360
  * Returns the async result of the given query and room id. If the query is success,
1326
1361
  * then it will return the threads that match that provided query and room id.
@@ -1331,89 +1366,62 @@ declare class UmbrellaStore<M extends BaseMetadata> {
1331
1366
  getInboxNotificationsLoadingState(): InboxNotificationsAsyncResult;
1332
1367
  getNotificationSettingsLoadingState(roomId: string): RoomNotificationSettingsAsyncResult;
1333
1368
  getRoomVersionsLoadingState(roomId: string): AsyncResult<HistoryVersion[], "versions">;
1334
- subscribe(callback: () => void): () => void;
1335
- _getPermissions(roomId: string): Set<Permission> | undefined;
1336
- private mutateThreadsDB;
1337
- private updateInboxNotificationsCache;
1338
- private setNotificationSettings;
1339
- private updateRoomVersions;
1340
- private updateOptimisticUpdatesCache;
1341
1369
  /**
1342
1370
  * Updates an existing inbox notification with a new value, replacing the
1343
1371
  * corresponding optimistic update.
1344
1372
  *
1345
- * This will not update anything if the inbox notification ID isn't found in
1346
- * the cache.
1347
- */
1348
- updateInboxNotification(inboxNotificationId: string, optimisticUpdateId: string, callback: (notification: Readonly<InboxNotificationData>) => Readonly<InboxNotificationData>): void;
1349
- /**
1350
- * Updates *all* inbox notifications by running a mapper function over all of
1351
- * them, replacing the corresponding optimistic update.
1373
+ * This will not update anything if the inbox notification ID isn't found.
1352
1374
  */
1353
- updateAllInboxNotifications(optimisticUpdateId: string, mapFn: (notification: Readonly<InboxNotificationData>) => Readonly<InboxNotificationData>): void;
1375
+ markInboxNotificationRead(inboxNotificationId: string, readAt: Date, optimisticId: string): void;
1376
+ markAllInboxNotificationsRead(optimisticId: string, readAt: Date): void;
1354
1377
  /**
1355
1378
  * Deletes an existing inbox notification, replacing the corresponding
1356
1379
  * optimistic update.
1357
1380
  */
1358
- deleteInboxNotification(inboxNotificationId: string, optimisticUpdateId: string): void;
1381
+ deleteInboxNotification(inboxNotificationId: string, optimisticId: string): void;
1359
1382
  /**
1360
1383
  * Deletes *all* inbox notifications, replacing the corresponding optimistic
1361
1384
  * update.
1362
1385
  */
1363
- deleteAllInboxNotifications(optimisticUpdateId: string): void;
1386
+ deleteAllInboxNotifications(optimisticId: string): void;
1364
1387
  /**
1365
1388
  * Creates an new thread, replacing the corresponding optimistic update.
1366
1389
  */
1367
- createThread(optimisticUpdateId: string, thread: Readonly<ThreadDataWithDeleteInfo<M>>): void;
1368
- /**
1369
- * Updates an existing thread with a new value, replacing the corresponding
1370
- * optimistic update.
1371
- *
1372
- * This will not update anything if:
1373
- * - The thread ID isn't found in the cache; or
1374
- * - The thread ID was already deleted from the cache; or
1375
- * - The thread ID in the cache was updated more recently than the optimistic
1376
- * update's timestamp (if given)
1377
- */
1378
- private updateThread;
1379
- patchThread(threadId: string, optimisticUpdateId: string | null, patch: {
1390
+ createThread(optimisticId: string, thread: Readonly<ThreadDataWithDeleteInfo<M>>): void;
1391
+ patchThread(threadId: string, optimisticId: string | null, patch: {
1380
1392
  metadata?: M;
1381
1393
  resolved?: boolean;
1382
1394
  }, updatedAt: Date): void;
1383
- addReaction(threadId: string, optimisticUpdateId: string | null, commentId: string, reaction: CommentUserReaction, createdAt: Date): void;
1384
- removeReaction(threadId: string, optimisticUpdateId: string | null, commentId: string, emoji: string, userId: string, removedAt: Date): void;
1395
+ addReaction(threadId: string, optimisticId: string | null, commentId: string, reaction: CommentUserReaction, createdAt: Date): void;
1396
+ removeReaction(threadId: string, optimisticId: string | null, commentId: string, emoji: string, userId: string, removedAt: Date): void;
1385
1397
  /**
1386
1398
  * Soft-deletes an existing thread by setting its `deletedAt` value,
1387
1399
  * replacing the corresponding optimistic update.
1388
1400
  *
1389
1401
  * This will not update anything if:
1390
- * - The thread ID isn't found in the cache; or
1391
- * - The thread ID was already deleted from the cache
1402
+ * - The thread ID isn't found; or
1403
+ * - The thread ID was already deleted
1392
1404
  */
1393
- deleteThread(threadId: string, optimisticUpdateId: string | null): void;
1405
+ deleteThread(threadId: string, optimisticId: string | null): void;
1394
1406
  /**
1395
1407
  * Creates an existing comment and ensures the associated notification is
1396
1408
  * updated correctly, replacing the corresponding optimistic update.
1397
1409
  */
1398
- createComment(newComment: CommentData, optimisticUpdateId: string): void;
1399
- editComment(threadId: string, optimisticUpdateId: string, editedComment: CommentData): void;
1400
- deleteComment(threadId: string, optimisticUpdateId: string, commentId: string, deletedAt: Date): void;
1401
- updateThreadAndNotification(thread: ThreadData<M>, inboxNotification?: InboxNotificationData): void;
1402
- updateThreadsAndNotifications(threads: ThreadData<M>[], inboxNotifications: InboxNotificationData[]): void;
1403
- updateThreadsAndNotifications(threads: ThreadData<M>[], inboxNotifications: InboxNotificationData[], deletedThreads: ThreadDeleteInfo[], deletedInboxNotifications: InboxNotificationDeleteInfo[]): void;
1410
+ createComment(newComment: CommentData, optimisticId: string): void;
1411
+ editComment(threadId: string, optimisticId: string, editedComment: CommentData): void;
1412
+ deleteComment(threadId: string, optimisticId: string, commentId: string, deletedAt: Date): void;
1413
+ updateThreadifications(threads: ThreadData<M>[], notifications: InboxNotificationData[], deletedThreads?: ThreadDeleteInfo[], deletedNotifications?: InboxNotificationDeleteInfo[]): void;
1404
1414
  /**
1405
1415
  * Updates existing notification setting for a room with a new value,
1406
1416
  * replacing the corresponding optimistic update.
1407
1417
  */
1408
- updateRoomNotificationSettings_confirmOptimisticUpdate(roomId: string, optimisticUpdateId: string, settings: Readonly<RoomNotificationSettings$1>): void;
1409
- addOptimisticUpdate(optimisticUpdate: DistributiveOmit<OptimisticUpdate<M>, "id">): string;
1410
- removeOptimisticUpdate(optimisticUpdateId: string): void;
1418
+ updateRoomNotificationSettings(roomId: string, optimisticId: string, settings: Readonly<RoomNotificationSettings$1>): void;
1411
1419
  fetchNotificationsDeltaUpdate(signal: AbortSignal): Promise<void>;
1412
1420
  waitUntilNotificationsLoaded(): UsablePromise<void>;
1413
- private updateRoomPermissions;
1414
1421
  waitUntilRoomThreadsLoaded(roomId: string, query: ThreadsQuery<M> | undefined): UsablePromise<void>;
1415
1422
  fetchRoomThreadsDeltaUpdate(roomId: string, signal: AbortSignal): Promise<void>;
1416
1423
  waitUntilUserThreadsLoaded(query: ThreadsQuery<M> | undefined): UsablePromise<void>;
1424
+ invalidateEntireStore(): void;
1417
1425
  fetchUserThreadsDeltaUpdate(signal: AbortSignal): Promise<void>;
1418
1426
  waitUntilRoomVersionsLoaded(roomId: string): UsablePromise<void>;
1419
1427
  fetchRoomVersionsDeltaUpdate(roomId: string, signal: AbortSignal): Promise<void>;
@@ -1427,7 +1435,7 @@ declare class UmbrellaStore<M extends BaseMetadata> {
1427
1435
  *
1428
1436
  * @private This is a private/advanced API. Do not rely on it.
1429
1437
  */
1430
- declare const ClientContext: React__default.Context<OpaqueClient | null>;
1438
+ declare const ClientContext: react.Context<OpaqueClient | null>;
1431
1439
  /**
1432
1440
  * Gets or creates a unique Umbrella store for each unique client instance.
1433
1441
  *
@@ -1450,7 +1458,7 @@ declare function useClient<U extends BaseUserMeta>(): Client$1<U, BaseMetadata$1
1450
1458
  * Unlike `RoomProvider`, `LiveblocksProvider` doesn’t call Liveblocks servers when mounted,
1451
1459
  * and it should be placed higher in your app’s component tree.
1452
1460
  */
1453
- declare function LiveblocksProvider<U extends BaseUserMeta = DU>(props: PropsWithChildren<ClientOptions<U>>): React__default.JSX.Element;
1461
+ declare function LiveblocksProvider<U extends BaseUserMeta = DU>(props: PropsWithChildren<ClientOptions<U>>): react_jsx_runtime.JSX.Element;
1454
1462
  /**
1455
1463
  * Creates a LiveblocksProvider and a set of typed hooks. Note that any
1456
1464
  * LiveblocksProvider created in this way takes no props, because it uses
@@ -1624,7 +1632,7 @@ declare function useSyncStatus(options?: UseSyncStatusOptions): SyncStatus;
1624
1632
  *
1625
1633
  * @private This is a private/advanced API. Do not rely on it.
1626
1634
  */
1627
- declare const RoomContext: React$1.Context<OpaqueRoom | null>;
1635
+ declare const RoomContext: react.Context<OpaqueRoom | null>;
1628
1636
  /** @private */
1629
1637
  declare function useRoomOrNull<P extends JsonObject, S extends LsonObject, U extends BaseUserMeta, E extends Json, M extends BaseMetadata$1>(): Room<P, S, U, E, M> | null;
1630
1638
 
@@ -1635,6 +1643,16 @@ declare function useRoomOrNull<P extends JsonObject, S extends LsonObject, U ext
1635
1643
  declare function useStatus(): Status;
1636
1644
  /** @private - Internal API, do not rely on it. */
1637
1645
  declare function useReportTextEditor(editor: TextEditorType, rootKey: string): void;
1646
+ /** @private - Internal API, do not rely on it. */
1647
+ declare function useYjsProvider(): IYjsProvider | undefined;
1648
+ /** @private - Internal API, do not rely on it. */
1649
+ declare function useCreateTextMention(): (userId: string, mentionId: string) => void;
1650
+ /** @private - Internal API, do not rely on it. */
1651
+ declare function useDeleteTextMention(): (mentionId: string) => void;
1652
+ /** @private - Internal API, do not rely on it. */
1653
+ declare function useResolveMentionSuggestions(): ((args: _liveblocks_core.ResolveMentionSuggestionsArgs) => _liveblocks_core.OptionalPromise<string[]>) | undefined;
1654
+ /** @private - Internal API, do not rely on it. */
1655
+ declare function useMentionSuggestionsCache(): Map<string, string[]>;
1638
1656
  /**
1639
1657
  * Returns the current storage status for the Room, and triggers
1640
1658
  * a re-render whenever it changes. Can be used to render a "Saving..."
@@ -1891,7 +1909,7 @@ declare function useAttachmentUrlSuspense(attachmentId: string): {
1891
1909
  /**
1892
1910
  * @private For internal use only. Do not rely on this hook.
1893
1911
  */
1894
- declare function useRoomPermissions(roomId: string): Set<_liveblocks_core.Permission>;
1912
+ declare function useRoomPermissions(roomId: string): Set<unknown>;
1895
1913
  /**
1896
1914
  * Creates a RoomProvider and a set of typed hooks to use in your app. Note
1897
1915
  * that any RoomProvider created in this way does not need to be nested in
@@ -2036,7 +2054,7 @@ declare const _useEditThreadMetadata: TypedBundle["useEditThreadMetadata"];
2036
2054
  declare const _useEventListener: TypedBundle["useEventListener"];
2037
2055
  /**
2038
2056
  * Returns the presence of the current user of the current room, and a function to update it.
2039
- * It is different from the setState function returned by the useState hook from React.
2057
+ * It is different from the setState function returned by the useState hook from
2040
2058
  * You don't need to pass the full presence object to update it.
2041
2059
  *
2042
2060
  * @example
@@ -2368,4 +2386,4 @@ declare const _useStorageRoot: TypedBundle["useStorageRoot"];
2368
2386
  */
2369
2387
  declare const _useUpdateMyPresence: TypedBundle["useUpdateMyPresence"];
2370
2388
 
2371
- export { _useMutation as $, createRoomContext as A, _RoomProvider as B, CreateThreadError as C, _useAddReaction as D, useBatch as E, _useBroadcastEvent as F, useCanRedo as G, useCanUndo as H, useCreateComment as I, _useCreateThread as J, useDeleteComment as K, LiveblocksProvider as L, type MutationContext as M, _useDeleteThread as N, useEditComment as O, _useEditThreadMetadata as P, useMarkThreadAsResolved as Q, RoomContext as R, useMarkThreadAsUnresolved as S, useErrorListener as T, type UseStorageStatusOptions as U, _useEventListener as V, useHistory as W, _useIsInsideRoom as X, useLostConnectionListener as Y, useMarkThreadAsRead as Z, _useInboxNotificationThread as _, useClientOrNull as a, _useMyPresence as a0, _useOthersListener as a1, useRedo as a2, useRemoveReaction as a3, _useRoom as a4, useStatus as a5, _useStorageRoot as a6, useThreadSubscription as a7, useUndo as a8, _useUpdateMyPresence as a9, _useThreadsSuspense as aA, useAttachmentUrlSuspense as aB, _useHistoryVersionsSuspense as aC, _useRoomNotificationSettingsSuspense as aD, useInboxNotificationsSuspense as aE, useRoomInfoSuspense as aF, useUnreadInboxNotificationsCountSuspense as aG, _useUserSuspense as aH, _useUserThreadsSuspense_experimental as aI, useUpdateRoomNotificationSettings as aa, useHistoryVersionData as ab, useCommentsErrorListener as ac, _useOther as ad, _useOthers as ae, useOthersConnectionIds as af, _useOthersMapped as ag, _useSelf as ah, _useStorage as ai, useStorageStatus as aj, _useThreads as ak, useAttachmentUrl as al, _useHistoryVersions as am, _useRoomNotificationSettings as an, useInboxNotifications as ao, _useUserThreads_experimental as ap, useRoomInfo as aq, useUnreadInboxNotificationsCount as ar, _useUser as as, _useOtherSuspense as at, _useOthersSuspense as au, useOthersConnectionIdsSuspense as av, _useOthersMappedSuspense as aw, _useSelfSuspense as ax, _useStorageSuspense as ay, useStorageStatusSuspense as az, useAddRoomCommentReaction as b, useCreateRoomComment as c, useCreateRoomThread as d, useDeleteRoomComment as e, useDeleteRoomThread as f, getUmbrellaStoreForClient as g, useEditRoomComment as h, useEditRoomThreadMetadata as i, useMarkRoomThreadAsRead as j, useMarkRoomThreadAsResolved as k, useMarkRoomThreadAsUnresolved as l, useRemoveRoomCommentReaction as m, useReportTextEditor as n, useRoomAttachmentUrl as o, useRoomPermissions as p, type UseThreadsOptions as q, ClientContext as r, createLiveblocksContext as s, useClient as t, useRoomOrNull as u, useDeleteAllInboxNotifications as v, useDeleteInboxNotification as w, useMarkAllInboxNotificationsAsRead as x, useMarkInboxNotificationAsRead as y, useSyncStatus as z };
2389
+ export { _useEventListener as $, useDeleteAllInboxNotifications as A, useDeleteInboxNotification as B, CreateThreadError as C, useMarkAllInboxNotificationsAsRead as D, useMarkInboxNotificationAsRead as E, useSyncStatus as F, createRoomContext as G, _RoomProvider as H, _useAddReaction as I, useBatch as J, _useBroadcastEvent as K, LiveblocksProvider as L, type MutationContext as M, useCanRedo as N, useCanUndo as O, useCreateComment as P, _useCreateThread as Q, RoomContext as R, useDeleteComment as S, _useDeleteThread as T, type UseStorageStatusOptions as U, useEditComment as V, _useEditThreadMetadata as W, useMarkThreadAsResolved as X, useMarkThreadAsUnresolved as Y, useErrorListener as Z, _useInboxNotificationThread as _, useClientOrNull as a, useHistory as a0, _useIsInsideRoom as a1, useLostConnectionListener as a2, useMarkThreadAsRead as a3, _useMutation as a4, _useMyPresence as a5, _useOthersListener as a6, useRedo as a7, useRemoveReaction as a8, _useRoom as a9, useOthersConnectionIdsSuspense as aA, _useOthersMappedSuspense as aB, _useSelfSuspense as aC, _useStorageSuspense as aD, useStorageStatusSuspense as aE, _useThreadsSuspense as aF, useAttachmentUrlSuspense as aG, _useHistoryVersionsSuspense as aH, _useRoomNotificationSettingsSuspense as aI, useInboxNotificationsSuspense as aJ, useRoomInfoSuspense as aK, useUnreadInboxNotificationsCountSuspense as aL, _useUserSuspense as aM, _useUserThreadsSuspense_experimental as aN, useStatus as aa, _useStorageRoot as ab, useThreadSubscription as ac, useUndo as ad, _useUpdateMyPresence as ae, useUpdateRoomNotificationSettings as af, useHistoryVersionData as ag, useCommentsErrorListener as ah, _useOther as ai, _useOthers as aj, useOthersConnectionIds as ak, _useOthersMapped as al, _useSelf as am, _useStorage as an, useStorageStatus as ao, _useThreads as ap, useAttachmentUrl as aq, _useHistoryVersions as ar, _useRoomNotificationSettings as as, useInboxNotifications as at, _useUserThreads_experimental as au, useRoomInfo as av, useUnreadInboxNotificationsCount as aw, _useUser as ax, _useOtherSuspense as ay, _useOthersSuspense as az, useAddRoomCommentReaction as b, useCreateRoomComment as c, useCreateRoomThread as d, useCreateTextMention as e, useDeleteRoomComment as f, getUmbrellaStoreForClient as g, useDeleteRoomThread as h, useDeleteTextMention as i, useEditRoomComment as j, useEditRoomThreadMetadata as k, useMarkRoomThreadAsRead as l, useMarkRoomThreadAsResolved as m, useMarkRoomThreadAsUnresolved as n, useMentionSuggestionsCache as o, useRemoveRoomCommentReaction as p, useReportTextEditor as q, useResolveMentionSuggestions as r, useRoomAttachmentUrl as s, useRoomPermissions as t, useRoomOrNull as u, useYjsProvider as v, type UseThreadsOptions as w, ClientContext as x, createLiveblocksContext as y, useClient as z };
@@ -1,5 +1,6 @@
1
1
  export { ClientSideSuspense } from './index.mjs';
2
- export { r as ClientContext, L as LiveblocksProvider, M as MutationContext, R as RoomContext, B as RoomProvider, U as UseStorageStatusOptions, q as UseThreadsOptions, D as useAddReaction, aB as useAttachmentUrl, E as useBatch, F as useBroadcastEvent, G as useCanRedo, H as useCanUndo, t as useClient, I as useCreateComment, J as useCreateThread, v as useDeleteAllInboxNotifications, K as useDeleteComment, w as useDeleteInboxNotification, N as useDeleteThread, O as useEditComment, P as useEditThreadMetadata, T as useErrorListener, V as useEventListener, W as useHistory, aC as useHistoryVersions, _ as useInboxNotificationThread, aE as useInboxNotifications, X as useIsInsideRoom, Y as useLostConnectionListener, x as useMarkAllInboxNotificationsAsRead, y as useMarkInboxNotificationAsRead, Z as useMarkThreadAsRead, Q as useMarkThreadAsResolved, S as useMarkThreadAsUnresolved, $ as useMutation, a0 as useMyPresence, at as useOther, au as useOthers, av as useOthersConnectionIds, a1 as useOthersListener, aw as useOthersMapped, a2 as useRedo, a3 as useRemoveReaction, a4 as useRoom, aF as useRoomInfo, aD as useRoomNotificationSettings, ax as useSelf, a5 as useStatus, ay as useStorage, a6 as useStorageRoot, az as useStorageStatus, z as useSyncStatus, a7 as useThreadSubscription, aA as useThreads, a8 as useUndo, aG as useUnreadInboxNotificationsCount, a9 as useUpdateMyPresence, aa as useUpdateRoomNotificationSettings, aH as useUser, aI as useUserThreads_experimental } from './room-Rl_QnQMY.mjs';
2
+ export { x as ClientContext, L as LiveblocksProvider, M as MutationContext, R as RoomContext, H as RoomProvider, U as UseStorageStatusOptions, w as UseThreadsOptions, I as useAddReaction, aG as useAttachmentUrl, J as useBatch, K as useBroadcastEvent, N as useCanRedo, O as useCanUndo, z as useClient, P as useCreateComment, Q as useCreateThread, A as useDeleteAllInboxNotifications, S as useDeleteComment, B as useDeleteInboxNotification, T as useDeleteThread, V as useEditComment, W as useEditThreadMetadata, Z as useErrorListener, $ as useEventListener, a0 as useHistory, aH as useHistoryVersions, _ as useInboxNotificationThread, aJ as useInboxNotifications, a1 as useIsInsideRoom, a2 as useLostConnectionListener, D as useMarkAllInboxNotificationsAsRead, E as useMarkInboxNotificationAsRead, a3 as useMarkThreadAsRead, X as useMarkThreadAsResolved, Y as useMarkThreadAsUnresolved, a4 as useMutation, a5 as useMyPresence, ay as useOther, az as useOthers, aA as useOthersConnectionIds, a6 as useOthersListener, aB as useOthersMapped, a7 as useRedo, a8 as useRemoveReaction, a9 as useRoom, aK as useRoomInfo, aI as useRoomNotificationSettings, aC as useSelf, aa as useStatus, aD as useStorage, ab as useStorageRoot, aE as useStorageStatus, F as useSyncStatus, ac as useThreadSubscription, aF as useThreads, ad as useUndo, aL as useUnreadInboxNotificationsCount, ae as useUpdateMyPresence, af as useUpdateRoomNotificationSettings, aM as useUser, aN as useUserThreads_experimental } from './room-XbmI0Hoh.mjs';
3
3
  export { Json, JsonObject, shallow } from '@liveblocks/client';
4
+ import 'react/jsx-runtime';
4
5
  import 'react';
5
6
  import '@liveblocks/core';
@@ -1,5 +1,6 @@
1
1
  export { ClientSideSuspense } from './index.js';
2
- export { r as ClientContext, L as LiveblocksProvider, M as MutationContext, R as RoomContext, B as RoomProvider, U as UseStorageStatusOptions, q as UseThreadsOptions, D as useAddReaction, aB as useAttachmentUrl, E as useBatch, F as useBroadcastEvent, G as useCanRedo, H as useCanUndo, t as useClient, I as useCreateComment, J as useCreateThread, v as useDeleteAllInboxNotifications, K as useDeleteComment, w as useDeleteInboxNotification, N as useDeleteThread, O as useEditComment, P as useEditThreadMetadata, T as useErrorListener, V as useEventListener, W as useHistory, aC as useHistoryVersions, _ as useInboxNotificationThread, aE as useInboxNotifications, X as useIsInsideRoom, Y as useLostConnectionListener, x as useMarkAllInboxNotificationsAsRead, y as useMarkInboxNotificationAsRead, Z as useMarkThreadAsRead, Q as useMarkThreadAsResolved, S as useMarkThreadAsUnresolved, $ as useMutation, a0 as useMyPresence, at as useOther, au as useOthers, av as useOthersConnectionIds, a1 as useOthersListener, aw as useOthersMapped, a2 as useRedo, a3 as useRemoveReaction, a4 as useRoom, aF as useRoomInfo, aD as useRoomNotificationSettings, ax as useSelf, a5 as useStatus, ay as useStorage, a6 as useStorageRoot, az as useStorageStatus, z as useSyncStatus, a7 as useThreadSubscription, aA as useThreads, a8 as useUndo, aG as useUnreadInboxNotificationsCount, a9 as useUpdateMyPresence, aa as useUpdateRoomNotificationSettings, aH as useUser, aI as useUserThreads_experimental } from './room-Rl_QnQMY.js';
2
+ export { x as ClientContext, L as LiveblocksProvider, M as MutationContext, R as RoomContext, H as RoomProvider, U as UseStorageStatusOptions, w as UseThreadsOptions, I as useAddReaction, aG as useAttachmentUrl, J as useBatch, K as useBroadcastEvent, N as useCanRedo, O as useCanUndo, z as useClient, P as useCreateComment, Q as useCreateThread, A as useDeleteAllInboxNotifications, S as useDeleteComment, B as useDeleteInboxNotification, T as useDeleteThread, V as useEditComment, W as useEditThreadMetadata, Z as useErrorListener, $ as useEventListener, a0 as useHistory, aH as useHistoryVersions, _ as useInboxNotificationThread, aJ as useInboxNotifications, a1 as useIsInsideRoom, a2 as useLostConnectionListener, D as useMarkAllInboxNotificationsAsRead, E as useMarkInboxNotificationAsRead, a3 as useMarkThreadAsRead, X as useMarkThreadAsResolved, Y as useMarkThreadAsUnresolved, a4 as useMutation, a5 as useMyPresence, ay as useOther, az as useOthers, aA as useOthersConnectionIds, a6 as useOthersListener, aB as useOthersMapped, a7 as useRedo, a8 as useRemoveReaction, a9 as useRoom, aK as useRoomInfo, aI as useRoomNotificationSettings, aC as useSelf, aa as useStatus, aD as useStorage, ab as useStorageRoot, aE as useStorageStatus, F as useSyncStatus, ac as useThreadSubscription, aF as useThreads, ad as useUndo, aL as useUnreadInboxNotificationsCount, ae as useUpdateMyPresence, af as useUpdateRoomNotificationSettings, aM as useUser, aN as useUserThreads_experimental } from './room-XbmI0Hoh.js';
3
3
  export { Json, JsonObject, shallow } from '@liveblocks/client';
4
+ import 'react/jsx-runtime';
4
5
  import 'react';
5
6
  import '@liveblocks/core';
package/dist/suspense.js CHANGED
@@ -3,7 +3,7 @@
3
3
 
4
4
 
5
5
 
6
- var _chunkL2RWXPYAjs = require('./chunk-L2RWXPYA.js');
6
+ var _chunk36VCTTYLjs = require('./chunk-36VCTTYL.js');
7
7
 
8
8
 
9
9
 
@@ -63,12 +63,12 @@ var _chunkL2RWXPYAjs = require('./chunk-L2RWXPYA.js');
63
63
 
64
64
 
65
65
 
66
- var _chunkX4DDEZYLjs = require('./chunk-X4DDEZYL.js');
66
+ var _chunkUKPVXB7Djs = require('./chunk-UKPVXB7D.js');
67
67
 
68
68
  // src/suspense.ts
69
69
  var _core = require('@liveblocks/core');
70
70
  var _client = require('@liveblocks/client');
71
- _core.detectDupes.call(void 0, _chunkL2RWXPYAjs.PKG_NAME, _chunkL2RWXPYAjs.PKG_VERSION, _chunkL2RWXPYAjs.PKG_FORMAT);
71
+ _core.detectDupes.call(void 0, _chunk36VCTTYLjs.PKG_NAME, _chunk36VCTTYLjs.PKG_VERSION, _chunk36VCTTYLjs.PKG_FORMAT);
72
72
 
73
73
 
74
74
 
@@ -130,5 +130,5 @@ _core.detectDupes.call(void 0, _chunkL2RWXPYAjs.PKG_NAME, _chunkL2RWXPYAjs.PKG_V
130
130
 
131
131
 
132
132
 
133
- exports.ClientContext = _chunkX4DDEZYLjs.ClientContext; exports.ClientSideSuspense = _chunkL2RWXPYAjs.ClientSideSuspense; exports.LiveblocksProvider = _chunkX4DDEZYLjs.LiveblocksProvider; exports.RoomContext = _chunkX4DDEZYLjs.RoomContext; exports.RoomProvider = _chunkX4DDEZYLjs._RoomProvider; exports.shallow = _client.shallow; exports.useAddReaction = _chunkX4DDEZYLjs._useAddReaction; exports.useAttachmentUrl = _chunkX4DDEZYLjs.useAttachmentUrlSuspense; exports.useBatch = _chunkX4DDEZYLjs.useBatch; exports.useBroadcastEvent = _chunkX4DDEZYLjs._useBroadcastEvent; exports.useCanRedo = _chunkX4DDEZYLjs.useCanRedo; exports.useCanUndo = _chunkX4DDEZYLjs.useCanUndo; exports.useClient = _chunkX4DDEZYLjs.useClient; exports.useCreateComment = _chunkX4DDEZYLjs.useCreateComment; exports.useCreateThread = _chunkX4DDEZYLjs._useCreateThread; exports.useDeleteAllInboxNotifications = _chunkX4DDEZYLjs.useDeleteAllInboxNotifications; exports.useDeleteComment = _chunkX4DDEZYLjs.useDeleteComment; exports.useDeleteInboxNotification = _chunkX4DDEZYLjs.useDeleteInboxNotification; exports.useDeleteThread = _chunkX4DDEZYLjs._useDeleteThread; exports.useEditComment = _chunkX4DDEZYLjs.useEditComment; exports.useEditThreadMetadata = _chunkX4DDEZYLjs._useEditThreadMetadata; exports.useErrorListener = _chunkX4DDEZYLjs.useErrorListener; exports.useEventListener = _chunkX4DDEZYLjs._useEventListener; exports.useHistory = _chunkX4DDEZYLjs.useHistory; exports.useHistoryVersions = _chunkX4DDEZYLjs._useHistoryVersionsSuspense; exports.useInboxNotificationThread = _chunkX4DDEZYLjs._useInboxNotificationThread; exports.useInboxNotifications = _chunkX4DDEZYLjs.useInboxNotificationsSuspense; exports.useIsInsideRoom = _chunkX4DDEZYLjs._useIsInsideRoom; exports.useLostConnectionListener = _chunkX4DDEZYLjs.useLostConnectionListener; exports.useMarkAllInboxNotificationsAsRead = _chunkX4DDEZYLjs.useMarkAllInboxNotificationsAsRead; exports.useMarkInboxNotificationAsRead = _chunkX4DDEZYLjs.useMarkInboxNotificationAsRead; exports.useMarkThreadAsRead = _chunkX4DDEZYLjs.useMarkThreadAsRead; exports.useMarkThreadAsResolved = _chunkX4DDEZYLjs.useMarkThreadAsResolved; exports.useMarkThreadAsUnresolved = _chunkX4DDEZYLjs.useMarkThreadAsUnresolved; exports.useMutation = _chunkX4DDEZYLjs._useMutation; exports.useMyPresence = _chunkX4DDEZYLjs._useMyPresence; exports.useOther = _chunkX4DDEZYLjs._useOtherSuspense; exports.useOthers = _chunkX4DDEZYLjs._useOthersSuspense; exports.useOthersConnectionIds = _chunkX4DDEZYLjs.useOthersConnectionIdsSuspense; exports.useOthersListener = _chunkX4DDEZYLjs._useOthersListener; exports.useOthersMapped = _chunkX4DDEZYLjs._useOthersMappedSuspense; exports.useRedo = _chunkX4DDEZYLjs.useRedo; exports.useRemoveReaction = _chunkX4DDEZYLjs.useRemoveReaction; exports.useRoom = _chunkX4DDEZYLjs._useRoom; exports.useRoomInfo = _chunkX4DDEZYLjs.useRoomInfoSuspense; exports.useRoomNotificationSettings = _chunkX4DDEZYLjs._useRoomNotificationSettingsSuspense; exports.useSelf = _chunkX4DDEZYLjs._useSelfSuspense; exports.useStatus = _chunkX4DDEZYLjs.useStatus; exports.useStorage = _chunkX4DDEZYLjs._useStorageSuspense; exports.useStorageRoot = _chunkX4DDEZYLjs._useStorageRoot; exports.useStorageStatus = _chunkX4DDEZYLjs.useStorageStatusSuspense; exports.useSyncStatus = _chunkX4DDEZYLjs.useSyncStatus; exports.useThreadSubscription = _chunkX4DDEZYLjs.useThreadSubscription; exports.useThreads = _chunkX4DDEZYLjs._useThreadsSuspense; exports.useUndo = _chunkX4DDEZYLjs.useUndo; exports.useUnreadInboxNotificationsCount = _chunkX4DDEZYLjs.useUnreadInboxNotificationsCountSuspense; exports.useUpdateMyPresence = _chunkX4DDEZYLjs._useUpdateMyPresence; exports.useUpdateRoomNotificationSettings = _chunkX4DDEZYLjs.useUpdateRoomNotificationSettings; exports.useUser = _chunkX4DDEZYLjs._useUserSuspense; exports.useUserThreads_experimental = _chunkX4DDEZYLjs._useUserThreadsSuspense_experimental;
133
+ exports.ClientContext = _chunkUKPVXB7Djs.ClientContext; exports.ClientSideSuspense = _chunk36VCTTYLjs.ClientSideSuspense; exports.LiveblocksProvider = _chunkUKPVXB7Djs.LiveblocksProvider; exports.RoomContext = _chunkUKPVXB7Djs.RoomContext; exports.RoomProvider = _chunkUKPVXB7Djs._RoomProvider; exports.shallow = _client.shallow; exports.useAddReaction = _chunkUKPVXB7Djs._useAddReaction; exports.useAttachmentUrl = _chunkUKPVXB7Djs.useAttachmentUrlSuspense; exports.useBatch = _chunkUKPVXB7Djs.useBatch; exports.useBroadcastEvent = _chunkUKPVXB7Djs._useBroadcastEvent; exports.useCanRedo = _chunkUKPVXB7Djs.useCanRedo; exports.useCanUndo = _chunkUKPVXB7Djs.useCanUndo; exports.useClient = _chunkUKPVXB7Djs.useClient; exports.useCreateComment = _chunkUKPVXB7Djs.useCreateComment; exports.useCreateThread = _chunkUKPVXB7Djs._useCreateThread; exports.useDeleteAllInboxNotifications = _chunkUKPVXB7Djs.useDeleteAllInboxNotifications; exports.useDeleteComment = _chunkUKPVXB7Djs.useDeleteComment; exports.useDeleteInboxNotification = _chunkUKPVXB7Djs.useDeleteInboxNotification; exports.useDeleteThread = _chunkUKPVXB7Djs._useDeleteThread; exports.useEditComment = _chunkUKPVXB7Djs.useEditComment; exports.useEditThreadMetadata = _chunkUKPVXB7Djs._useEditThreadMetadata; exports.useErrorListener = _chunkUKPVXB7Djs.useErrorListener; exports.useEventListener = _chunkUKPVXB7Djs._useEventListener; exports.useHistory = _chunkUKPVXB7Djs.useHistory; exports.useHistoryVersions = _chunkUKPVXB7Djs._useHistoryVersionsSuspense; exports.useInboxNotificationThread = _chunkUKPVXB7Djs._useInboxNotificationThread; exports.useInboxNotifications = _chunkUKPVXB7Djs.useInboxNotificationsSuspense; exports.useIsInsideRoom = _chunkUKPVXB7Djs._useIsInsideRoom; exports.useLostConnectionListener = _chunkUKPVXB7Djs.useLostConnectionListener; exports.useMarkAllInboxNotificationsAsRead = _chunkUKPVXB7Djs.useMarkAllInboxNotificationsAsRead; exports.useMarkInboxNotificationAsRead = _chunkUKPVXB7Djs.useMarkInboxNotificationAsRead; exports.useMarkThreadAsRead = _chunkUKPVXB7Djs.useMarkThreadAsRead; exports.useMarkThreadAsResolved = _chunkUKPVXB7Djs.useMarkThreadAsResolved; exports.useMarkThreadAsUnresolved = _chunkUKPVXB7Djs.useMarkThreadAsUnresolved; exports.useMutation = _chunkUKPVXB7Djs._useMutation; exports.useMyPresence = _chunkUKPVXB7Djs._useMyPresence; exports.useOther = _chunkUKPVXB7Djs._useOtherSuspense; exports.useOthers = _chunkUKPVXB7Djs._useOthersSuspense; exports.useOthersConnectionIds = _chunkUKPVXB7Djs.useOthersConnectionIdsSuspense; exports.useOthersListener = _chunkUKPVXB7Djs._useOthersListener; exports.useOthersMapped = _chunkUKPVXB7Djs._useOthersMappedSuspense; exports.useRedo = _chunkUKPVXB7Djs.useRedo; exports.useRemoveReaction = _chunkUKPVXB7Djs.useRemoveReaction; exports.useRoom = _chunkUKPVXB7Djs._useRoom; exports.useRoomInfo = _chunkUKPVXB7Djs.useRoomInfoSuspense; exports.useRoomNotificationSettings = _chunkUKPVXB7Djs._useRoomNotificationSettingsSuspense; exports.useSelf = _chunkUKPVXB7Djs._useSelfSuspense; exports.useStatus = _chunkUKPVXB7Djs.useStatus; exports.useStorage = _chunkUKPVXB7Djs._useStorageSuspense; exports.useStorageRoot = _chunkUKPVXB7Djs._useStorageRoot; exports.useStorageStatus = _chunkUKPVXB7Djs.useStorageStatusSuspense; exports.useSyncStatus = _chunkUKPVXB7Djs.useSyncStatus; exports.useThreadSubscription = _chunkUKPVXB7Djs.useThreadSubscription; exports.useThreads = _chunkUKPVXB7Djs._useThreadsSuspense; exports.useUndo = _chunkUKPVXB7Djs.useUndo; exports.useUnreadInboxNotificationsCount = _chunkUKPVXB7Djs.useUnreadInboxNotificationsCountSuspense; exports.useUpdateMyPresence = _chunkUKPVXB7Djs._useUpdateMyPresence; exports.useUpdateRoomNotificationSettings = _chunkUKPVXB7Djs.useUpdateRoomNotificationSettings; exports.useUser = _chunkUKPVXB7Djs._useUserSuspense; exports.useUserThreads_experimental = _chunkUKPVXB7Djs._useUserThreadsSuspense_experimental;
134
134
  //# sourceMappingURL=suspense.js.map
package/dist/suspense.mjs CHANGED
@@ -3,7 +3,7 @@ import {
3
3
  PKG_FORMAT,
4
4
  PKG_NAME,
5
5
  PKG_VERSION
6
- } from "./chunk-IQJWVOHM.mjs";
6
+ } from "./chunk-4HZJQXE5.mjs";
7
7
  import {
8
8
  ClientContext,
9
9
  LiveblocksProvider,
@@ -63,7 +63,7 @@ import {
63
63
  useUndo,
64
64
  useUnreadInboxNotificationsCountSuspense,
65
65
  useUpdateRoomNotificationSettings
66
- } from "./chunk-BRCWZCNY.mjs";
66
+ } from "./chunk-NZZCQLBR.mjs";
67
67
 
68
68
  // src/suspense.ts
69
69
  import { detectDupes } from "@liveblocks/core";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@liveblocks/react",
3
- "version": "2.14.0",
3
+ "version": "2.15.0",
4
4
  "description": "A set of React hooks and providers to use Liveblocks declaratively. Liveblocks is the all-in-one toolkit to build collaborative products like Figma, Notion, and more.",
5
5
  "license": "Apache-2.0",
6
6
  "type": "commonjs",
@@ -61,12 +61,11 @@
61
61
  "showdeps": "depcruise src --include-only '^src' --exclude='__tests__' --output-type dot | dot -T svg > /tmp/dependency-graph.svg && open /tmp/dependency-graph.svg"
62
62
  },
63
63
  "dependencies": {
64
- "@liveblocks/client": "2.14.0",
65
- "@liveblocks/core": "2.14.0",
66
- "use-sync-external-store": "^1.2.2"
64
+ "@liveblocks/client": "2.15.0",
65
+ "@liveblocks/core": "2.15.0"
67
66
  },
68
67
  "peerDependencies": {
69
- "react": "^16.14.0 || ^17 || ^18 || ^19 || ^19.0.0-rc"
68
+ "react": "^18 || ^19 || ^19.0.0-rc"
70
69
  },
71
70
  "devDependencies": {
72
71
  "@liveblocks/eslint-config": "*",
@@ -74,7 +73,6 @@
74
73
  "@liveblocks/query-parser": "^0.0.4",
75
74
  "@testing-library/jest-dom": "6.4.6",
76
75
  "@testing-library/react": "14.1.2",
77
- "@types/use-sync-external-store": "^0.0.6",
78
76
  "date-fns": "^3.6.0",
79
77
  "eslint-plugin-react-hooks": "^4.6.2",
80
78
  "itertools": "^2.3.2",