@liveblocks/core 1.10.0-beta2 → 1.10.0-beta4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -179,12 +179,15 @@ interface IWebSocket {
179
179
  /**
180
180
  * The following ranges will be respected by the client:
181
181
  *
182
+ * 10xx: client will reauthorize (just like 41xx)
182
183
  * 40xx: client will disconnect
183
184
  * 41xx: client will reauthorize
184
185
  * 42xx: client will retry without reauthorizing (currently not used)
185
186
  *
186
187
  */
187
188
  declare enum WebsocketCloseCodes {
189
+ /** Normal close of connection, the connection fulfilled its purpose. */
190
+ CLOSE_NORMAL = 1000,
188
191
  /** Unexpected error happened with the network/infra level. In spirit akin to HTTP 503 */
189
192
  CLOSE_ABNORMAL = 1006,
190
193
  /** Unexpected error happened. In spirit akin to HTTP 500 */
@@ -203,6 +206,8 @@ declare enum WebsocketCloseCodes {
203
206
  MAX_NUMBER_OF_MESSAGES_PER_DAY_PER_APP = 4004,
204
207
  /** Room is full, disconnect */
205
208
  MAX_NUMBER_OF_CONCURRENT_CONNECTIONS_PER_ROOM = 4005,
209
+ /** The server kicked the connection from the room. */
210
+ KICKED = 4100,
206
211
  /** The auth token is expired, reauthorize to get a fresh one. In spirit akin to HTTP 401 */
207
212
  TOKEN_EXPIRED = 4109,
208
213
  /** Disconnect immediately */
@@ -237,6 +242,9 @@ declare type LostConnectionEvent = "lost" | "restored" | "failed";
237
242
  * any value (except null).
238
243
  */
239
244
  declare type BaseAuthResult = NonNullable<Json>;
245
+ declare class LiveblocksError extends Error {
246
+ code: number;
247
+ }
240
248
  declare type Delegates<T extends BaseAuthResult> = {
241
249
  authenticate: () => Promise<T>;
242
250
  createSocket: (authValue: T) => IWebSocketInstance;
@@ -1271,6 +1279,13 @@ declare type InboxNotificationThreadData = {
1271
1279
  declare type InboxNotificationData = InboxNotificationThreadData;
1272
1280
  declare type InboxNotificationDataPlain = DateToString<InboxNotificationData>;
1273
1281
 
1282
+ declare type InboxNotificationDeleteInfo = {
1283
+ type: "deletedInboxNotification";
1284
+ id: string;
1285
+ roomId: string;
1286
+ deletedAt: Date;
1287
+ };
1288
+
1274
1289
  /**
1275
1290
  * Represents a user connected in a room. Treated as immutable.
1276
1291
  */
@@ -1325,6 +1340,7 @@ declare type InternalOthersEvent<TPresence extends JsonObject, TUserMeta extends
1325
1340
  updates: Partial<TPresence>;
1326
1341
  } | {
1327
1342
  type: "reset";
1343
+ user?: never;
1328
1344
  };
1329
1345
  declare type OthersEvent<TPresence extends JsonObject, TUserMeta extends BaseUserMeta> = Resolve<InternalOthersEvent<TPresence, TUserMeta> & {
1330
1346
  others: readonly User<TPresence, TUserMeta>[];
@@ -1351,11 +1367,21 @@ declare type ThreadData<TThreadMetadata extends BaseMetadata = never> = {
1351
1367
  comments: CommentData[];
1352
1368
  metadata: [TThreadMetadata] extends [never] ? Record<string, never> : TThreadMetadata;
1353
1369
  };
1370
+ interface ThreadDataWithDeleteInfo<TThreadMetadata extends BaseMetadata = never> extends ThreadData<TThreadMetadata> {
1371
+ deletedAt?: Date;
1372
+ }
1354
1373
  declare type ThreadDataPlain<TThreadMetadata extends BaseMetadata = never> = Omit<DateToString<ThreadData<TThreadMetadata>>, "comments" | "metadata"> & {
1355
1374
  comments: CommentDataPlain[];
1356
1375
  metadata: [TThreadMetadata] extends [never] ? Record<string, never> : TThreadMetadata;
1357
1376
  };
1358
1377
 
1378
+ declare type ThreadDeleteInfo = {
1379
+ type: "deletedThread";
1380
+ id: string;
1381
+ roomId: string;
1382
+ deletedAt: Date;
1383
+ };
1384
+
1359
1385
  declare type LegacyOthersEvent<TPresence extends JsonObject, TUserMeta extends BaseUserMeta> = {
1360
1386
  type: "leave";
1361
1387
  user: User<TPresence, TUserMeta>;
@@ -1523,7 +1549,7 @@ declare type SubscribeFn<TPresence extends JsonObject, _TStorage extends LsonObj
1523
1549
  * @returns Unsubscribe function.
1524
1550
  *
1525
1551
  */
1526
- (type: "error", listener: ErrorCallback): () => void;
1552
+ (type: "error", listener: Callback<LiveblocksError>): () => void;
1527
1553
  /**
1528
1554
  * @deprecated This API will be removed in a future version of Liveblocks.
1529
1555
  * Prefer using the newer `.subscribe('status')` API.
@@ -1636,81 +1662,60 @@ declare type GetThreadsOptions<TThreadMetadata extends BaseMetadata> = {
1636
1662
  query?: {
1637
1663
  metadata?: Partial<TThreadMetadata>;
1638
1664
  };
1665
+ since?: Date;
1639
1666
  };
1640
- declare type CommentsApi<TThreadMetadata extends BaseMetadata = never> = {
1641
- /**
1642
- * @private
1643
- */
1644
- getThreads(options?: GetThreadsOptions<TThreadMetadata>): Promise<{
1667
+ declare type CommentsApi = {
1668
+ getThreads<TThreadMetadata extends BaseMetadata = never>(options?: GetThreadsOptions<TThreadMetadata>): Promise<{
1645
1669
  threads: ThreadData<TThreadMetadata>[];
1646
1670
  inboxNotifications: InboxNotificationData[];
1671
+ deletedThreads: ThreadDeleteInfo[];
1672
+ deletedInboxNotifications: InboxNotificationDeleteInfo[];
1673
+ meta: {
1674
+ requestedAt: Date;
1675
+ };
1647
1676
  }>;
1648
- /**
1649
- * @private
1650
- */
1651
- getThread(options: {
1677
+ getThread<TThreadMetadata extends BaseMetadata = never>(options: {
1652
1678
  threadId: string;
1653
1679
  }): Promise<{
1654
1680
  thread: ThreadData<TThreadMetadata>;
1655
1681
  inboxNotification?: InboxNotificationData;
1656
1682
  } | undefined>;
1657
- /**
1658
- * @private
1659
- */
1660
- createThread(options: {
1683
+ createThread<TThreadMetadata extends BaseMetadata = never>(options: {
1661
1684
  threadId: string;
1662
1685
  commentId: string;
1663
1686
  metadata: TThreadMetadata | undefined;
1664
1687
  body: CommentBody;
1665
1688
  }): Promise<ThreadData<TThreadMetadata>>;
1666
- /**
1667
- * @private
1668
- */
1669
- editThreadMetadata(options: {
1689
+ editThreadMetadata<TThreadMetadata extends BaseMetadata = never>(options: {
1670
1690
  metadata: PartialNullable<TThreadMetadata>;
1671
1691
  threadId: string;
1672
1692
  }): Promise<TThreadMetadata>;
1673
- /**
1674
- * @private
1675
- */
1676
1693
  createComment(options: {
1677
1694
  threadId: string;
1678
1695
  commentId: string;
1679
1696
  body: CommentBody;
1680
1697
  }): Promise<CommentData>;
1681
- /**
1682
- * @private
1683
- */
1684
1698
  editComment(options: {
1685
1699
  threadId: string;
1686
1700
  commentId: string;
1687
1701
  body: CommentBody;
1688
1702
  }): Promise<CommentData>;
1689
- /**
1690
- * @private
1691
- */
1692
1703
  deleteComment(options: {
1693
1704
  threadId: string;
1694
1705
  commentId: string;
1695
1706
  }): Promise<void>;
1696
- /**
1697
- * @private
1698
- */
1699
1707
  addReaction(options: {
1700
1708
  threadId: string;
1701
1709
  commentId: string;
1702
1710
  emoji: string;
1703
1711
  }): Promise<CommentUserReaction>;
1704
- /**
1705
- * @private
1706
- */
1707
1712
  removeReaction(options: {
1708
1713
  threadId: string;
1709
1714
  commentId: string;
1710
1715
  emoji: string;
1711
1716
  }): Promise<void>;
1712
1717
  };
1713
- declare type Room<TPresence extends JsonObject, TStorage extends LsonObject, TUserMeta extends BaseUserMeta, TRoomEvent extends Json> = CommentsApi<any> & {
1718
+ declare type Room<TPresence extends JsonObject, TStorage extends LsonObject, TUserMeta extends BaseUserMeta, TRoomEvent extends Json> = {
1714
1719
  /**
1715
1720
  * @private
1716
1721
  *
@@ -1843,7 +1848,7 @@ declare type Room<TPresence extends JsonObject, TStorage extends LsonObject, TUs
1843
1848
  readonly self: Observable<User<TPresence, TUserMeta>>;
1844
1849
  readonly myPresence: Observable<TPresence>;
1845
1850
  readonly others: Observable<OthersEvent<TPresence, TUserMeta>>;
1846
- readonly error: Observable<Error>;
1851
+ readonly error: Observable<LiveblocksError>;
1847
1852
  readonly storage: Observable<StorageUpdate[]>;
1848
1853
  readonly history: Observable<HistoryEvent>;
1849
1854
  /**
@@ -1856,14 +1861,6 @@ declare type Room<TPresence extends JsonObject, TStorage extends LsonObject, TUs
1856
1861
  readonly ydoc: Observable<YDocUpdateServerMsg | UpdateYDocClientMsg>;
1857
1862
  readonly comments: Observable<CommentsEventServerMsg>;
1858
1863
  };
1859
- /**
1860
- * @private
1861
- */
1862
- getRoomNotificationSettings(): Promise<RoomNotificationSettings>;
1863
- /**
1864
- * @private
1865
- */
1866
- updateRoomNotificationSettings(settings: Partial<RoomNotificationSettings>): Promise<RoomNotificationSettings>;
1867
1864
  /**
1868
1865
  * Batches modifications made during the given function.
1869
1866
  * All the modifications are sent to other clients in a single message.
@@ -1929,6 +1926,12 @@ declare type PrivateRoomApi = {
1929
1926
  explicitClose(event: IWebSocketCloseEvent): void;
1930
1927
  rawSend(data: string): void;
1931
1928
  };
1929
+ comments: CommentsApi;
1930
+ notifications: {
1931
+ getRoomNotificationSettings(): Promise<RoomNotificationSettings>;
1932
+ updateRoomNotificationSettings(settings: Partial<RoomNotificationSettings>): Promise<RoomNotificationSettings>;
1933
+ markInboxNotificationAsRead(notificationId: string): Promise<void>;
1934
+ };
1932
1935
  };
1933
1936
  declare type HistoryOp<TPresence extends JsonObject> = Op | {
1934
1937
  readonly type: "presence";
@@ -1994,6 +1997,11 @@ declare type Store<T> = {
1994
1997
  subscribe: (callback: (state: T) => void) => () => void;
1995
1998
  };
1996
1999
 
2000
+ declare type GetInboxNotificationsOptions = {
2001
+ limit?: number;
2002
+ since?: Date;
2003
+ };
2004
+
1997
2005
  declare type OptimisticUpdate<TThreadMetadata extends BaseMetadata> = CreateThreadOptimisticUpdate<TThreadMetadata> | EditThreadMetadataOptimisticUpdate<TThreadMetadata> | CreateCommentOptimisticUpdate | EditCommentOptimisticUpdate | DeleteCommentOptimisticUpdate | AddReactionOptimisticUpdate | RemoveReactionOptimisticUpdate | MarkInboxNotificationAsReadOptimisticUpdate | MarkAllInboxNotificationsAsReadOptimisticUpdate | UpdateNotificationSettingsOptimisticUpdate;
1998
2006
  declare type CreateThreadOptimisticUpdate<TThreadMetadata extends BaseMetadata> = {
1999
2007
  type: "create-thread";
@@ -2005,20 +2013,17 @@ declare type EditThreadMetadataOptimisticUpdate<TThreadMetadata extends BaseMeta
2005
2013
  id: string;
2006
2014
  threadId: string;
2007
2015
  metadata: Resolve<PartialNullable<TThreadMetadata>>;
2016
+ updatedAt: Date;
2008
2017
  };
2009
2018
  declare type CreateCommentOptimisticUpdate = {
2010
2019
  type: "create-comment";
2011
2020
  id: string;
2012
2021
  comment: CommentData;
2013
- inboxNotificationId?: string;
2014
2022
  };
2015
2023
  declare type EditCommentOptimisticUpdate = {
2016
2024
  type: "edit-comment";
2017
2025
  id: string;
2018
- threadId: string;
2019
- editedAt: Date;
2020
- commentId: string;
2021
- body: CommentBody;
2026
+ comment: CommentData;
2022
2027
  };
2023
2028
  declare type DeleteCommentOptimisticUpdate = {
2024
2029
  type: "delete-comment";
@@ -2032,9 +2037,7 @@ declare type AddReactionOptimisticUpdate = {
2032
2037
  id: string;
2033
2038
  threadId: string;
2034
2039
  commentId: string;
2035
- emoji: string;
2036
- createdAt: Date;
2037
- userId: string;
2040
+ reaction: CommentUserReaction;
2038
2041
  };
2039
2042
  declare type RemoveReactionOptimisticUpdate = {
2040
2043
  type: "remove-reaction";
@@ -2043,6 +2046,7 @@ declare type RemoveReactionOptimisticUpdate = {
2043
2046
  commentId: string;
2044
2047
  emoji: string;
2045
2048
  userId: string;
2049
+ removedAt: Date;
2046
2050
  };
2047
2051
  declare type MarkInboxNotificationAsReadOptimisticUpdate = {
2048
2052
  type: "mark-inbox-notification-as-read";
@@ -2072,7 +2076,7 @@ declare type CacheState<TThreadMetadata extends BaseMetadata> = {
2072
2076
  /**
2073
2077
  * Threads by ID.
2074
2078
  */
2075
- threads: Record<string, ThreadData<TThreadMetadata>>;
2079
+ threads: Record<string, ThreadDataWithDeleteInfo<TThreadMetadata>>;
2076
2080
  /**
2077
2081
  * Keep track of loading and error status of all the queries made by the client.
2078
2082
  */
@@ -2094,11 +2098,16 @@ declare type CacheState<TThreadMetadata extends BaseMetadata> = {
2094
2098
  interface CacheStore<TThreadMetadata extends BaseMetadata> extends Store<CacheState<TThreadMetadata>> {
2095
2099
  deleteThread(threadId: string): void;
2096
2100
  updateThreadAndNotification(thread: ThreadData<TThreadMetadata>, inboxNotification?: InboxNotificationData): void;
2097
- updateThreadsAndNotifications(threads: ThreadData<TThreadMetadata>[], inboxNotifications: InboxNotificationData[], queryKey?: string): void;
2101
+ updateThreadsAndNotifications(threads: ThreadData<TThreadMetadata>[], inboxNotifications: InboxNotificationData[], deletedThreads: ThreadDeleteInfo[], deletedInboxNotifications: InboxNotificationDeleteInfo[], queryKey?: string): void;
2102
+ updateRoomInboxNotificationSettings(roomId: string, settings: RoomNotificationSettings, queryKey: string): void;
2098
2103
  pushOptimisticUpdate(optimisticUpdate: OptimisticUpdate<TThreadMetadata>): void;
2099
2104
  setQueryState(queryKey: string, queryState: QueryState): void;
2100
2105
  }
2101
2106
  declare function applyOptimisticUpdates<TThreadMetadata extends BaseMetadata>(state: CacheState<TThreadMetadata>): Pick<CacheState<TThreadMetadata>, "threads" | "inboxNotifications" | "notificationSettings">;
2107
+ declare function upsertComment<TThreadMetadata extends BaseMetadata>(thread: ThreadDataWithDeleteInfo<TThreadMetadata>, comment: CommentData): ThreadDataWithDeleteInfo<TThreadMetadata>;
2108
+ declare function deleteComment<TThreadMetadata extends BaseMetadata>(thread: ThreadDataWithDeleteInfo<TThreadMetadata>, commentId: string, deletedAt: Date): ThreadDataWithDeleteInfo<TThreadMetadata>;
2109
+ declare function addReaction<TThreadMetadata extends BaseMetadata>(thread: ThreadDataWithDeleteInfo<TThreadMetadata>, commentId: string, reaction: CommentUserReaction): ThreadDataWithDeleteInfo<TThreadMetadata>;
2110
+ declare function removeReaction<TThreadMetadata extends BaseMetadata>(thread: ThreadDataWithDeleteInfo<TThreadMetadata>, commentId: string, emoji: string, userId: string, removedAt: Date): ThreadDataWithDeleteInfo<TThreadMetadata>;
2102
2111
 
2103
2112
  declare type OptionalPromise<T> = T | Promise<T>;
2104
2113
 
@@ -2107,6 +2116,10 @@ declare type RoomInfo = {
2107
2116
  * The name of the room.
2108
2117
  */
2109
2118
  name?: string;
2119
+ /**
2120
+ * The URL of the room.
2121
+ */
2122
+ url?: string;
2110
2123
  };
2111
2124
 
2112
2125
  declare type ResolveMentionSuggestionsArgs = {
@@ -2150,34 +2163,29 @@ declare type EnterOptions<TPresence extends JsonObject, TStorage extends LsonObj
2150
2163
  * will probably happen if you do.
2151
2164
  */
2152
2165
  declare type PrivateClientApi<TUserMeta extends BaseUserMeta> = {
2166
+ notifications: NotificationsApi;
2153
2167
  currentUserIdStore: Store<string | null>;
2154
2168
  resolveMentionSuggestions: ClientOptions["resolveMentionSuggestions"];
2155
2169
  cacheStore: CacheStore<BaseMetadata>;
2156
2170
  usersStore: BatchStore<TUserMeta["info"] | undefined, [string]>;
2157
2171
  roomsInfoStore: BatchStore<RoomInfo | undefined, [string]>;
2172
+ getRoomIds: () => string[];
2158
2173
  };
2159
- declare type InboxNotificationsApi<TThreadMetadata extends BaseMetadata = never> = {
2160
- /**
2161
- * @private
2162
- */
2163
- getInboxNotifications(): Promise<{
2174
+ declare type NotificationsApi<TThreadMetadata extends BaseMetadata = never> = {
2175
+ getInboxNotifications(options?: GetInboxNotificationsOptions): Promise<{
2164
2176
  inboxNotifications: InboxNotificationData[];
2165
2177
  threads: ThreadData<TThreadMetadata>[];
2178
+ deletedThreads: ThreadDeleteInfo[];
2179
+ deletedInboxNotifications: InboxNotificationDeleteInfo[];
2180
+ meta: {
2181
+ requestedAt: Date;
2182
+ };
2166
2183
  }>;
2167
- /**
2168
- * @private
2169
- */
2170
2184
  getUnreadInboxNotificationsCount(): Promise<number>;
2171
- /**
2172
- * @private
2173
- */
2174
2185
  markAllInboxNotificationsAsRead(): Promise<void>;
2175
- /**
2176
- * @private
2177
- */
2178
2186
  markInboxNotificationAsRead(inboxNotificationId: string): Promise<void>;
2179
2187
  };
2180
- declare type Client<TUserMeta extends BaseUserMeta = BaseUserMeta> = InboxNotificationsApi & {
2188
+ declare type Client<TUserMeta extends BaseUserMeta = BaseUserMeta> = {
2181
2189
  /**
2182
2190
  * Gets a room. Returns null if {@link Client.enter} has not been called previously.
2183
2191
  *
@@ -2770,4 +2778,4 @@ declare type EnsureJson<T> = [
2770
2778
  [K in keyof T]: EnsureJson<T[K]>;
2771
2779
  };
2772
2780
 
2773
- export { type AckOp, type BaseAuthResult, type BaseMetadata, type BaseUserMeta, type Brand, type BroadcastEventClientMsg, type BroadcastOptions, type BroadcastedEventServerMsg, type CacheState, type CacheStore, type Client, type ClientMsg, ClientMsgCode, type CommentBody, type CommentBodyBlockElement, type CommentBodyElement, type CommentBodyInlineElement, type CommentBodyLink, type CommentBodyLinkElementArgs, type CommentBodyMention, type CommentBodyMentionElementArgs, type CommentBodyParagraph, type CommentBodyParagraphElementArgs, type CommentBodyText, type CommentBodyTextElementArgs, type CommentData, type CommentDataPlain, type CommentReaction, type CommentUserReaction, type CommentUserReactionPlain, CommentsApiError, type CommentsEventServerMsg, CrdtType, type CreateListOp, type CreateMapOp, type CreateObjectOp, type CreateOp, type CreateRegisterOp, type CustomAuthenticationResult, type Delegates, type DeleteCrdtOp, type DeleteObjectKeyOp, DevToolsTreeNode as DevTools, protocol as DevToolsMsg, type EnsureJson, type EnterOptions, type EventSource, type FetchStorageClientMsg, type FetchYDocClientMsg, type GetThreadsOptions, type History, type IUserInfo, type IWebSocket, type IWebSocketCloseEvent, type IWebSocketEvent, type IWebSocketInstance, type IWebSocketMessageEvent, type IdTuple, type Immutable, type InboxNotificationData, type InboxNotificationDataPlain, type InboxNotificationThreadData, type InitialDocumentStateServerMsg, type Json, type JsonArray, type JsonObject, type JsonScalar, type LegacyConnectionStatus, LiveList, type LiveListUpdate, LiveMap, type LiveMapUpdate, type LiveNode, LiveObject, type LiveObjectUpdate, type LiveStructure, type LostConnectionEvent, type Lson, type LsonObject, type NodeMap, NotificationsApiError, type Op, OpCode, type OptionalPromise, type Others, type OthersEvent, type ParentToChildNodeMap, type PartialNullable, type PlainLson, type PlainLsonFields, type PlainLsonList, type PlainLsonMap, type PlainLsonObject, type RejectedStorageOpServerMsg, type Resolve, type ResolveMentionSuggestionsArgs, type ResolveRoomsInfoArgs, type ResolveUsersArgs, type Room, type RoomEventMessage, type RoomInfo, type RoomInitializers, type RoomNotificationSettings, type RoomStateServerMsg, type SerializedChild, type SerializedCrdt, type SerializedList, type SerializedMap, type SerializedObject, type SerializedRegister, type SerializedRootObject, type ServerMsg, ServerMsgCode, type SetParentKeyOp, type Status, type StorageStatus, type StorageUpdate, type Store, type StringifyCommentBodyElements, type StringifyCommentBodyOptions, type ThreadData, type ThreadDataPlain, type ToImmutable, type ToJson, type UnsubscribeCallback, type UpdateObjectOp, type UpdatePresenceClientMsg, type UpdatePresenceServerMsg, type UpdateStorageClientMsg, type UpdateStorageServerMsg, type UpdateYDocClientMsg, type User, type UserJoinServerMsg, type UserLeftServerMsg, WebsocketCloseCodes, type YDocUpdateServerMsg, ackOp, applyOptimisticUpdates, asPos, assert, assertNever, b64decode, cloneLson, fancyConsole as console, convertToCommentData, convertToCommentUserReaction, convertToThreadData, createClient, deprecate, deprecateIf, detectDupes, errorIf, freeze, getMentionedIdsFromCommentBody, isChildCrdt, isJsonArray, isJsonObject, isJsonScalar, isLiveNode, isPlainObject, isRootCrdt, kInternal, legacy_patchImmutableObject, lsonToJson, makeEventSource, makePoller, makePosition, nn, patchLiveObjectKey, raise, shallow, stringify, stringifyCommentBody, throwUsageError, toPlainLson, tryParseJson, withTimeout };
2781
+ export { type AckOp, type BaseAuthResult, type BaseMetadata, type BaseUserMeta, type Brand, type BroadcastEventClientMsg, type BroadcastOptions, type BroadcastedEventServerMsg, type CacheState, type CacheStore, type Client, type ClientMsg, ClientMsgCode, type CommentBody, type CommentBodyBlockElement, type CommentBodyElement, type CommentBodyInlineElement, type CommentBodyLink, type CommentBodyLinkElementArgs, type CommentBodyMention, type CommentBodyMentionElementArgs, type CommentBodyParagraph, type CommentBodyParagraphElementArgs, type CommentBodyText, type CommentBodyTextElementArgs, type CommentData, type CommentDataPlain, type CommentReaction, type CommentUserReaction, type CommentUserReactionPlain, CommentsApiError, type CommentsEventServerMsg, CrdtType, type CreateListOp, type CreateMapOp, type CreateObjectOp, type CreateOp, type CreateRegisterOp, type CustomAuthenticationResult, type Delegates, type DeleteCrdtOp, type DeleteObjectKeyOp, DevToolsTreeNode as DevTools, protocol as DevToolsMsg, type EnsureJson, type EnterOptions, type EventSource, type FetchStorageClientMsg, type FetchYDocClientMsg, type GetThreadsOptions, type History, type IUserInfo, type IWebSocket, type IWebSocketCloseEvent, type IWebSocketEvent, type IWebSocketInstance, type IWebSocketMessageEvent, type IdTuple, type Immutable, type InboxNotificationData, type InboxNotificationDataPlain, type InboxNotificationDeleteInfo, type InboxNotificationThreadData, type InitialDocumentStateServerMsg, type Json, type JsonArray, type JsonObject, type JsonScalar, type LegacyConnectionStatus, LiveList, type LiveListUpdate, LiveMap, type LiveMapUpdate, type LiveNode, LiveObject, type LiveObjectUpdate, type LiveStructure, LiveblocksError, type LostConnectionEvent, type Lson, type LsonObject, type NodeMap, NotificationsApiError, type Op, OpCode, type OptionalPromise, type Others, type OthersEvent, type ParentToChildNodeMap, type PartialNullable, type PlainLson, type PlainLsonFields, type PlainLsonList, type PlainLsonMap, type PlainLsonObject, type RejectedStorageOpServerMsg, type Resolve, type ResolveMentionSuggestionsArgs, type ResolveRoomsInfoArgs, type ResolveUsersArgs, type Room, type RoomEventMessage, type RoomInfo, type RoomInitializers, type RoomNotificationSettings, type RoomStateServerMsg, type SerializedChild, type SerializedCrdt, type SerializedList, type SerializedMap, type SerializedObject, type SerializedRegister, type SerializedRootObject, type ServerMsg, ServerMsgCode, type SetParentKeyOp, type Status, type StorageStatus, type StorageUpdate, type Store, type StringifyCommentBodyElements, type StringifyCommentBodyOptions, type ThreadData, type ThreadDataPlain, type ThreadDeleteInfo, type ToImmutable, type ToJson, type UnsubscribeCallback, type UpdateObjectOp, type UpdatePresenceClientMsg, type UpdatePresenceServerMsg, type UpdateStorageClientMsg, type UpdateStorageServerMsg, type UpdateYDocClientMsg, type User, type UserJoinServerMsg, type UserLeftServerMsg, WebsocketCloseCodes, type YDocUpdateServerMsg, ackOp, addReaction, applyOptimisticUpdates, asPos, assert, assertNever, b64decode, cloneLson, fancyConsole as console, convertToCommentData, convertToCommentUserReaction, convertToThreadData, createClient, deleteComment, deprecate, deprecateIf, detectDupes, errorIf, freeze, getMentionedIdsFromCommentBody, isChildCrdt, isJsonArray, isJsonObject, isJsonScalar, isLiveNode, isPlainObject, isRootCrdt, kInternal, legacy_patchImmutableObject, lsonToJson, makeEventSource, makePoller, makePosition, nn, patchLiveObjectKey, raise, removeReaction, shallow, stringify, stringifyCommentBody, throwUsageError, toPlainLson, tryParseJson, upsertComment, withTimeout };