@liveblocks/react 2.25.0-aiprivatebeta0 → 2.25.0-aiprivatebeta10
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 +5 -5
- package/dist/_private.cjs.map +1 -1
- package/dist/_private.d.cts +2 -2
- package/dist/_private.d.ts +2 -2
- package/dist/_private.js +1 -1
- package/dist/_private.js.map +1 -1
- package/dist/{chunk-STFFVL4D.cjs → chunk-MSLJX4ZW.cjs} +2 -2
- package/dist/{chunk-STFFVL4D.cjs.map → chunk-MSLJX4ZW.cjs.map} +1 -1
- package/dist/{chunk-3FZLUESM.js → chunk-Y2RSQZ5R.js} +2 -2
- package/dist/{chunk-ZGVKI7OM.cjs → chunk-Y6Z36KDP.cjs} +175 -49
- package/dist/chunk-Y6Z36KDP.cjs.map +1 -0
- package/dist/{chunk-E6PCFJWE.js → chunk-Y7BGHNHH.js} +269 -143
- package/dist/chunk-Y7BGHNHH.js.map +1 -0
- package/dist/index.cjs +10 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +30 -11
- package/dist/index.d.ts +30 -11
- package/dist/index.js +8 -2
- package/dist/index.js.map +1 -1
- package/dist/{room-DmsjrDvP.d.cts → room-BYtyYCxu.d.cts} +162 -24
- package/dist/{room-DmsjrDvP.d.ts → room-BYtyYCxu.d.ts} +162 -24
- package/dist/suspense.cjs +10 -4
- package/dist/suspense.cjs.map +1 -1
- package/dist/suspense.d.cts +2 -2
- package/dist/suspense.d.ts +2 -2
- package/dist/suspense.js +8 -2
- package/dist/suspense.js.map +1 -1
- package/package.json +13 -3
- package/dist/chunk-E6PCFJWE.js.map +0 -1
- package/dist/chunk-ZGVKI7OM.cjs.map +0 -1
- /package/dist/{chunk-3FZLUESM.js.map → chunk-Y2RSQZ5R.js.map} +0 -0
|
@@ -1,9 +1,32 @@
|
|
|
1
|
+
import * as react from 'react';
|
|
2
|
+
import { ComponentType, Context, PropsWithChildren, ReactNode } from 'react';
|
|
3
|
+
import { BaseUserMeta, Client, JsonObject, LsonObject, LiveObject, User, Json, RoomSubscriptionSettings, Room, Status, BroadcastOptions, OthersEvent, LostConnectionEvent, History, BaseMetadata as BaseMetadata$1, ClientOptions, StorageStatus as StorageStatus$1, ThreadData as ThreadData$1, CommentData as CommentData$1 } from '@liveblocks/client';
|
|
1
4
|
import * as _liveblocks_core from '@liveblocks/core';
|
|
2
|
-
import { BaseMetadata, StorageStatus, QueryMetadata, AsyncResult, DRI, AsyncSuccess, Resolve, CommentBody, CommentAttachment, PartialUnless, Patchable, InboxNotificationData, NotificationSettings, Relax, ToImmutable, PartialNotificationSettings, AsyncLoading, AsyncError, ThreadData, HistoryVersion, AiChat, UiChatMessage, Client, LiveblocksError, SyncStatus, RoomEventMessage, CommentData, MutableSignal, ThreadDataWithDeleteInfo, ThreadDeleteInfo, DerivedSignal, DefaultMap, MessageId,
|
|
5
|
+
import { OpaqueClient, OpaqueRoom, BaseMetadata, StorageStatus, QueryMetadata, AsyncResult, DRI, AsyncSuccess, Resolve, CommentBody, CommentAttachment, PartialUnless, Patchable, InboxNotificationData, NotificationSettings, Relax, ToImmutable, PartialNotificationSettings, AsyncLoading, AsyncError, ThreadData, HistoryVersion, AiChat, UiChatMessage, Client as Client$1, LiveblocksError, SyncStatus, AiKnowledgeSource, RoomEventMessage, CommentData, MutableSignal, ThreadDataWithDeleteInfo, ThreadDeleteInfo, DerivedSignal, DefaultMap, MessageId, SubscriptionData, SubscriptionKey, CommentUserReaction, InboxNotificationDeleteInfo, SubscriptionDeleteInfo, RoomSubscriptionSettings as RoomSubscriptionSettings$1, ISignal, Permission, BaseUserMeta as BaseUserMeta$1, DistributiveOmit, DU, DM, TextEditorType, IYjsProvider, DP, DS, DE } from '@liveblocks/core';
|
|
3
6
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* Raw access to the React context where the LiveblocksProvider stores the
|
|
10
|
+
* current client. Exposed for advanced use cases only.
|
|
11
|
+
*
|
|
12
|
+
* @private This is a private/advanced API. Do not rely on it.
|
|
13
|
+
*/
|
|
14
|
+
declare const ClientContext: react.Context<OpaqueClient | null>;
|
|
15
|
+
/**
|
|
16
|
+
* @private This is an internal API.
|
|
17
|
+
*/
|
|
18
|
+
declare function useClientOrNull<U extends BaseUserMeta>(): Client<U> | null;
|
|
19
|
+
/**
|
|
20
|
+
* Obtains a reference to the current Liveblocks client.
|
|
21
|
+
*/
|
|
22
|
+
declare function useClient<U extends BaseUserMeta>(): Client<U>;
|
|
23
|
+
/**
|
|
24
|
+
* Raw access to the React context where the RoomProvider stores the current
|
|
25
|
+
* room. Exposed for advanced use cases only.
|
|
26
|
+
*
|
|
27
|
+
* @private This is a private/advanced API. Do not rely on it.
|
|
28
|
+
*/
|
|
29
|
+
declare const RoomContext: react.Context<OpaqueRoom | null>;
|
|
7
30
|
|
|
8
31
|
type UseSyncStatusOptions = {
|
|
9
32
|
/**
|
|
@@ -14,6 +37,12 @@ type UseSyncStatusOptions = {
|
|
|
14
37
|
*/
|
|
15
38
|
smooth?: boolean;
|
|
16
39
|
};
|
|
40
|
+
type SendAiMessageOptions = {
|
|
41
|
+
/**
|
|
42
|
+
* The id of the copilot to use to send the message.
|
|
43
|
+
*/
|
|
44
|
+
copilotId?: string;
|
|
45
|
+
};
|
|
17
46
|
type UseStorageStatusOptions = UseSyncStatusOptions;
|
|
18
47
|
type StorageStatusSuccess = Exclude<StorageStatus, "not-loaded" | "loading">;
|
|
19
48
|
type ThreadsQuery<M extends BaseMetadata> = {
|
|
@@ -108,6 +137,8 @@ type HistoryVersionsAsyncSuccess = AsyncSuccess<HistoryVersion[], "versions">;
|
|
|
108
137
|
type HistoryVersionsAsyncResult = AsyncResult<HistoryVersion[], "versions">;
|
|
109
138
|
type AiChatsAsyncSuccess = PagedAsyncSuccess<AiChat[], "chats">;
|
|
110
139
|
type AiChatsAsyncResult = PagedAsyncResult<AiChat[], "chats">;
|
|
140
|
+
type AiChatAsyncSuccess = AsyncSuccess<AiChat, "chat">;
|
|
141
|
+
type AiChatAsyncResult = AsyncResult<AiChat, "chat">;
|
|
111
142
|
type AiChatMessagesAsyncSuccess = AsyncSuccess<readonly UiChatMessage[], "messages">;
|
|
112
143
|
type AiChatMessagesAsyncResult = AsyncResult<readonly UiChatMessage[], "messages">;
|
|
113
144
|
type RoomProviderProps<P extends JsonObject, S extends LsonObject> = Resolve<{
|
|
@@ -170,7 +201,7 @@ type SharedContextBundle<U extends BaseUserMeta> = {
|
|
|
170
201
|
/**
|
|
171
202
|
* Obtains a reference to the current Liveblocks client.
|
|
172
203
|
*/
|
|
173
|
-
useClient(): Client<U>;
|
|
204
|
+
useClient(): Client$1<U>;
|
|
174
205
|
/**
|
|
175
206
|
* Returns user info from a given user ID.
|
|
176
207
|
*
|
|
@@ -214,12 +245,38 @@ type SharedContextBundle<U extends BaseUserMeta> = {
|
|
|
214
245
|
* const syncStatus = useSyncStatus({ smooth: true });
|
|
215
246
|
*/
|
|
216
247
|
useSyncStatus(options?: UseSyncStatusOptions): SyncStatus;
|
|
248
|
+
/**
|
|
249
|
+
* Make knowledge about your application state available to any AI used in
|
|
250
|
+
* a chat or a one-off request.
|
|
251
|
+
*
|
|
252
|
+
* For example:
|
|
253
|
+
*
|
|
254
|
+
* <RegisterAiKnowledge
|
|
255
|
+
* description="The current mode of my application"
|
|
256
|
+
* value="dark" />
|
|
257
|
+
*
|
|
258
|
+
* <RegisterAiKnowledge
|
|
259
|
+
* description="The current list of todos"
|
|
260
|
+
* value={todos} />
|
|
261
|
+
*
|
|
262
|
+
* By mounting this component, the AI will get access to this knwoledge.
|
|
263
|
+
* By unmounting this component, the AI will no longer have access to it.
|
|
264
|
+
* It can choose to use or ignore this knowledge in its responses.
|
|
265
|
+
*/
|
|
266
|
+
RegisterAiKnowledge: ComponentType<AiKnowledgeSource & {
|
|
267
|
+
/**
|
|
268
|
+
* An optional unique key for this knowledge source. If multiple components
|
|
269
|
+
* register knowledge under the same key, the last one to mount takes
|
|
270
|
+
* precedence.
|
|
271
|
+
*/
|
|
272
|
+
id?: string;
|
|
273
|
+
}>;
|
|
217
274
|
};
|
|
218
275
|
suspense: {
|
|
219
276
|
/**
|
|
220
277
|
* Obtains a reference to the current Liveblocks client.
|
|
221
278
|
*/
|
|
222
|
-
useClient(): Client<U>;
|
|
279
|
+
useClient(): Client$1<U>;
|
|
223
280
|
/**
|
|
224
281
|
* Returns user info from a given user ID.
|
|
225
282
|
*
|
|
@@ -263,6 +320,32 @@ type SharedContextBundle<U extends BaseUserMeta> = {
|
|
|
263
320
|
* const syncStatus = useSyncStatus({ smooth: true });
|
|
264
321
|
*/
|
|
265
322
|
useSyncStatus(options?: UseSyncStatusOptions): SyncStatus;
|
|
323
|
+
/**
|
|
324
|
+
* Make knowledge about your application state available to any AI used in
|
|
325
|
+
* a chat or a one-off request.
|
|
326
|
+
*
|
|
327
|
+
* For example:
|
|
328
|
+
*
|
|
329
|
+
* <RegisterAiKnowledge
|
|
330
|
+
* description="The current mode of my application"
|
|
331
|
+
* value="dark" />
|
|
332
|
+
*
|
|
333
|
+
* <RegisterAiKnowledge
|
|
334
|
+
* description="The current list of todos"
|
|
335
|
+
* value={todos} />
|
|
336
|
+
*
|
|
337
|
+
* By mounting this component, the AI will get access to this knwoledge.
|
|
338
|
+
* By unmounting this component, the AI will no longer have access to it.
|
|
339
|
+
* It can choose to use or ignore this knowledge in its responses.
|
|
340
|
+
*/
|
|
341
|
+
RegisterAiKnowledge: ComponentType<AiKnowledgeSource & {
|
|
342
|
+
/**
|
|
343
|
+
* An optional unique key for this knowledge source. If multiple components
|
|
344
|
+
* register knowledge under the same key, the last one to mount takes
|
|
345
|
+
* precedence.
|
|
346
|
+
*/
|
|
347
|
+
id?: string;
|
|
348
|
+
}>;
|
|
266
349
|
};
|
|
267
350
|
};
|
|
268
351
|
/**
|
|
@@ -998,12 +1081,17 @@ type LiveblocksContextBundleCommon<M extends BaseMetadata> = {
|
|
|
998
1081
|
/**
|
|
999
1082
|
* Returns a function that creates an AI chat.
|
|
1000
1083
|
*
|
|
1084
|
+
* If you do not pass a title for the chat, it will be automatically computed
|
|
1085
|
+
* after the first AI response.
|
|
1086
|
+
*
|
|
1001
1087
|
* @example
|
|
1002
1088
|
* const createAiChat = useCreateAiChat();
|
|
1003
|
-
* createAiChat({ id: "ai-chat-id" });
|
|
1089
|
+
* createAiChat({ id: "ai-chat-id", title: "My AI chat" });
|
|
1004
1090
|
*/
|
|
1005
1091
|
useCreateAiChat(): (options: {
|
|
1006
1092
|
id: string;
|
|
1093
|
+
title?: string;
|
|
1094
|
+
metadata?: Record<string, string | string[]>;
|
|
1007
1095
|
}) => void;
|
|
1008
1096
|
/**
|
|
1009
1097
|
* Returns a function that deletes the AI chat with the specified id.
|
|
@@ -1013,6 +1101,14 @@ type LiveblocksContextBundleCommon<M extends BaseMetadata> = {
|
|
|
1013
1101
|
* deleteAiChat("ai-chat-id");
|
|
1014
1102
|
*/
|
|
1015
1103
|
useDeleteAiChat(): (chatId: string) => void;
|
|
1104
|
+
/**
|
|
1105
|
+
* Returns a function to send a message in an AI chat.
|
|
1106
|
+
*
|
|
1107
|
+
* @example
|
|
1108
|
+
* const sendMessage = useSendAiMessage(chatId);
|
|
1109
|
+
* sendMessage("Hello, Liveblocks AI!");
|
|
1110
|
+
*/
|
|
1111
|
+
useSendAiMessage(chatId: string, options?: SendAiMessageOptions): (message: string) => void;
|
|
1016
1112
|
};
|
|
1017
1113
|
type LiveblocksContextBundle<U extends BaseUserMeta, M extends BaseMetadata> = Resolve<LiveblocksContextBundleCommon<M> & SharedContextBundle<U>["classic"] & {
|
|
1018
1114
|
/**
|
|
@@ -1050,6 +1146,13 @@ type LiveblocksContextBundle<U extends BaseUserMeta, M extends BaseMetadata> = R
|
|
|
1050
1146
|
* const { messages, error, isLoading } = useAiChatMessages("my-chat");
|
|
1051
1147
|
*/
|
|
1052
1148
|
useAiChatMessages(chatId: string): AiChatMessagesAsyncResult;
|
|
1149
|
+
/**
|
|
1150
|
+
* (Private beta) Returns the information of the given chat.
|
|
1151
|
+
*
|
|
1152
|
+
* @example
|
|
1153
|
+
* const { chat, error, isLoading } = useAiChat("my-chat");
|
|
1154
|
+
*/
|
|
1155
|
+
useAiChat(chatId: string): AiChatAsyncResult;
|
|
1053
1156
|
suspense: Resolve<LiveblocksContextBundleCommon<M> & SharedContextBundle<U>["suspense"] & {
|
|
1054
1157
|
/**
|
|
1055
1158
|
* Returns the inbox notifications for the current user.
|
|
@@ -1096,6 +1199,13 @@ type LiveblocksContextBundle<U extends BaseUserMeta, M extends BaseMetadata> = R
|
|
|
1096
1199
|
* const { messages } = useAiChatMessages("my-chat");
|
|
1097
1200
|
*/
|
|
1098
1201
|
useAiChatMessages(chatId: string): AiChatMessagesAsyncSuccess;
|
|
1202
|
+
/**
|
|
1203
|
+
* (Private beta) Returns the information of the given chat.
|
|
1204
|
+
*
|
|
1205
|
+
* @example
|
|
1206
|
+
* const { chat, error, isLoading } = useAiChat("my-chat");
|
|
1207
|
+
*/
|
|
1208
|
+
useAiChat(chatId: string): AiChatAsyncSuccess;
|
|
1099
1209
|
}>;
|
|
1100
1210
|
}>;
|
|
1101
1211
|
|
|
@@ -1297,7 +1407,6 @@ type NotificationsLUT = Map<string, InboxNotificationData>;
|
|
|
1297
1407
|
*/
|
|
1298
1408
|
type RoomSubscriptionSettingsByRoomId = Record<RoomId, RoomSubscriptionSettings$1>;
|
|
1299
1409
|
type SubscriptionsByKey = Record<SubscriptionKey, SubscriptionData>;
|
|
1300
|
-
type PermissionHintsLUT = DefaultMap<RoomId, Set<Permission>>;
|
|
1301
1410
|
type CleanThreadifications<M extends BaseMetadata> = CleanThreads<M> & CleanNotifications;
|
|
1302
1411
|
type CleanThreads<M extends BaseMetadata> = {
|
|
1303
1412
|
/**
|
|
@@ -1362,7 +1471,7 @@ declare function createStore_forHistoryVersions(): {
|
|
|
1362
1471
|
update: (roomId: string, versions: HistoryVersion[]) => void;
|
|
1363
1472
|
};
|
|
1364
1473
|
declare function createStore_forPermissionHints(): {
|
|
1365
|
-
|
|
1474
|
+
getPermissionForRoomΣ: (roomId: string) => ISignal<Set<Permission>>;
|
|
1366
1475
|
update: (newHints: Record<string, Permission[]>) => void;
|
|
1367
1476
|
};
|
|
1368
1477
|
/**
|
|
@@ -1387,7 +1496,7 @@ declare function createStore_forNotificationSettings(updates: ISignal<readonly O
|
|
|
1387
1496
|
signal: DerivedSignal<NotificationSettings>;
|
|
1388
1497
|
update: (settings: NotificationSettings) => void;
|
|
1389
1498
|
};
|
|
1390
|
-
declare function createStore_forOptimistic<M extends BaseMetadata>(client: Client<BaseUserMeta$1, M>): {
|
|
1499
|
+
declare function createStore_forOptimistic<M extends BaseMetadata>(client: Client$1<BaseUserMeta$1, M>): {
|
|
1391
1500
|
signal: ISignal<readonly OptimisticUpdate<M>[]>;
|
|
1392
1501
|
add: (optimisticUpdate: DistributiveOmit<OptimisticUpdate<M>, "id">) => string;
|
|
1393
1502
|
remove: (optimisticId: string) => void;
|
|
@@ -1415,6 +1524,7 @@ declare class UmbrellaStore<M extends BaseMetadata> {
|
|
|
1415
1524
|
readonly notificationSettings: LoadableResource<NotificationSettingsAsyncResult>;
|
|
1416
1525
|
readonly aiChats: LoadableResource<AiChatsAsyncResult>;
|
|
1417
1526
|
readonly messagesByChatId: DefaultMap<string, DefaultMap<MessageId | null, LoadableResource<AiChatMessagesAsyncResult>>>;
|
|
1527
|
+
readonly aiChatById: DefaultMap<string, LoadableResource<AiChatAsyncResult>>;
|
|
1418
1528
|
};
|
|
1419
1529
|
constructor(client: OpaqueClient);
|
|
1420
1530
|
/**
|
|
@@ -1493,31 +1603,45 @@ declare class UmbrellaStore<M extends BaseMetadata> {
|
|
|
1493
1603
|
updateNotificationSettings_confirmOptimisticUpdate(settings: NotificationSettings, optimisticUpdateId: string): void;
|
|
1494
1604
|
}
|
|
1495
1605
|
|
|
1496
|
-
/**
|
|
1497
|
-
* Raw access to the React context where the LiveblocksProvider stores the
|
|
1498
|
-
* current client. Exposed for advanced use cases only.
|
|
1499
|
-
*
|
|
1500
|
-
* @private This is a private/advanced API. Do not rely on it.
|
|
1501
|
-
*/
|
|
1502
|
-
declare const ClientContext: react.Context<OpaqueClient | null>;
|
|
1503
1606
|
/**
|
|
1504
1607
|
* Gets or creates a unique Umbrella store for each unique client instance.
|
|
1505
1608
|
*
|
|
1506
1609
|
* @private
|
|
1507
1610
|
*/
|
|
1508
1611
|
declare function getUmbrellaStoreForClient<M extends BaseMetadata$1>(client: OpaqueClient): UmbrellaStore<M>;
|
|
1612
|
+
/**
|
|
1613
|
+
* Returns a function that creates an AI chat.
|
|
1614
|
+
*
|
|
1615
|
+
* If you do not pass a title for the chat, it will be automatically computed
|
|
1616
|
+
* after the first AI response.
|
|
1617
|
+
*
|
|
1618
|
+
* @example
|
|
1619
|
+
* const createAiChat = useCreateAiChat();
|
|
1620
|
+
* createAiChat({ id: "ai-chat-id", title: "My AI chat" });
|
|
1621
|
+
*/
|
|
1509
1622
|
declare function useCreateAiChat(): (options: {
|
|
1510
1623
|
id: string;
|
|
1624
|
+
title?: string;
|
|
1625
|
+
metadata?: Record<string, string | string[]>;
|
|
1511
1626
|
}) => void;
|
|
1512
|
-
declare function useDeleteAiChat(): (chatId: string) => void;
|
|
1513
1627
|
/**
|
|
1514
|
-
*
|
|
1628
|
+
* Returns a function that deletes the AI chat with the specified id.
|
|
1629
|
+
*
|
|
1630
|
+
* @example
|
|
1631
|
+
* const deleteAiChat = useDeleteAiChat();
|
|
1632
|
+
* deleteAiChat("ai-chat-id");
|
|
1515
1633
|
*/
|
|
1516
|
-
declare function
|
|
1634
|
+
declare function useDeleteAiChat(): (chatId: string) => void;
|
|
1517
1635
|
/**
|
|
1518
|
-
*
|
|
1636
|
+
* Returns a function to send a message in an AI chat.
|
|
1637
|
+
*
|
|
1638
|
+
* @example
|
|
1639
|
+
* const sendMessage = useSendAiMessage(chatId);
|
|
1640
|
+
* sendMessage("Hello, Liveblocks AI!");
|
|
1519
1641
|
*/
|
|
1520
|
-
declare function
|
|
1642
|
+
declare function useSendAiMessage(chatId: string, options?: {
|
|
1643
|
+
copilotId?: string;
|
|
1644
|
+
}): (message: string) => void;
|
|
1521
1645
|
/**
|
|
1522
1646
|
* Sets up a client for connecting to Liveblocks, and is the recommended way to do
|
|
1523
1647
|
* this for React apps. You must define either `authEndpoint` or `publicApiKey`.
|
|
@@ -1722,6 +1846,20 @@ declare const _useAiChats: TypedBundle$1["useAiChats"];
|
|
|
1722
1846
|
* const { chats, error, isLoading } = useAiChats();
|
|
1723
1847
|
*/
|
|
1724
1848
|
declare const _useAiChatsSuspense: TypedBundle$1["suspense"]["useAiChats"];
|
|
1849
|
+
/**
|
|
1850
|
+
* (Private beta) Returns the information of the given chat.
|
|
1851
|
+
*
|
|
1852
|
+
* @example
|
|
1853
|
+
* const { chat, error, isLoading } = useAiChat("my-chat");
|
|
1854
|
+
*/
|
|
1855
|
+
declare const _useAiChat: TypedBundle$1["useAiChat"];
|
|
1856
|
+
/**
|
|
1857
|
+
* (Private beta) Returns the information of the given chat.
|
|
1858
|
+
*
|
|
1859
|
+
* @example
|
|
1860
|
+
* const { chat, error, isLoading } = useAiChat("my-chat");
|
|
1861
|
+
*/
|
|
1862
|
+
declare const _useAiChatSuspense: TypedBundle$1["suspense"]["useAiChat"];
|
|
1725
1863
|
/**
|
|
1726
1864
|
* (Private beta) Returns the messages in the given chat.
|
|
1727
1865
|
*
|
|
@@ -2046,7 +2184,7 @@ declare function useAttachmentUrlSuspense(attachmentId: string): {
|
|
|
2046
2184
|
/**
|
|
2047
2185
|
* @private For internal use only. Do not rely on this hook.
|
|
2048
2186
|
*/
|
|
2049
|
-
declare function useRoomPermissions(roomId: string): Set<
|
|
2187
|
+
declare function useRoomPermissions(roomId: string): Set<_liveblocks_core.Permission>;
|
|
2050
2188
|
/**
|
|
2051
2189
|
* Creates a RoomProvider and a set of typed hooks to use in your app. Note
|
|
2052
2190
|
* that any RoomProvider created in this way does not need to be nested in
|
|
@@ -2537,4 +2675,4 @@ declare const _useStorageRoot: TypedBundle["useStorageRoot"];
|
|
|
2537
2675
|
*/
|
|
2538
2676
|
declare const _useUpdateMyPresence: TypedBundle["useUpdateMyPresence"];
|
|
2539
2677
|
|
|
2540
|
-
export {
|
|
2678
|
+
export { useUnsubscribeFromThread as $, useDeleteInboxNotification as A, useErrorListener as B, ClientContext 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, useSubscribeToThread as Z, _useInboxNotificationThread as _, useAddRoomCommentReaction as a, _useAiChatMessagesSuspense as a$, _useEventListener as a0, useHistory as a1, _useIsInsideRoom as a2, useLostConnectionListener as a3, useMarkThreadAsRead as a4, _useMutation as a5, _useMyPresence as a6, _useOthersListener as a7, useRedo as a8, useRemoveReaction as a9, useSendAiMessage as aA, _useUserThreads_experimental as aB, useRoomInfo as aC, useUnreadInboxNotificationsCount as aD, _useUser as aE, _useAiChat as aF, _useAiChats as aG, _useAiChatMessages as aH, _useOtherSuspense as aI, _useOthersSuspense as aJ, useOthersConnectionIdsSuspense as aK, _useOthersMappedSuspense as aL, _useSelfSuspense as aM, _useStorageSuspense as aN, useStorageStatusSuspense as aO, _useThreadsSuspense as aP, useAttachmentUrlSuspense as aQ, _useHistoryVersionsSuspense as aR, _useRoomNotificationSettingsSuspense as aS, _useRoomSubscriptionSettingsSuspense as aT, useInboxNotificationsSuspense as aU, useNotificationSettingsSuspense as aV, useRoomInfoSuspense as aW, useUnreadInboxNotificationsCountSuspense as aX, _useUserSuspense as aY, _useUserThreadsSuspense_experimental as aZ, _useAiChatsSuspense as a_, _useRoom as aa, useStatus as ab, _useStorageRoot as ac, useThreadSubscription as ad, useUndo as ae, _useUpdateMyPresence as af, useUpdateRoomNotificationSettings as ag, useUpdateRoomSubscriptionSettings as ah, useHistoryVersionData as ai, _useOther as aj, _useOthers as ak, useOthersConnectionIds as al, _useOthersMapped as am, _useSelf as an, _useStorage as ao, useStorageStatus as ap, _useThreads as aq, useAttachmentUrl as ar, _useHistoryVersions as as, _useRoomNotificationSettings as at, _useRoomSubscriptionSettings as au, useInboxNotifications as av, useNotificationSettings as aw, useUpdateNotificationSettings as ax, useCreateAiChat as ay, useDeleteAiChat as az, useCreateRoomComment as b, _useAiChatSuspense as b0, useCreateRoomThread as c, useCreateTextMention as d, useDeleteRoomComment as e, useDeleteRoomThread as f, getUmbrellaStoreForClient as g, useDeleteTextMention as h, useEditRoomComment as i, useEditRoomThreadMetadata as j, useMarkRoomThreadAsRead as k, useMarkRoomThreadAsResolved as l, useMarkRoomThreadAsUnresolved as m, useMentionSuggestionsCache as n, useRemoveRoomCommentReaction as o, useReportTextEditor as p, useResolveMentionSuggestions as q, useRoomAttachmentUrl as r, useRoomPermissions as s, useRoomThreadSubscription as t, useClientOrNull as u, useYjsProvider as v, type UseThreadsOptions as w, useClient as x, createLiveblocksContext as y, useDeleteAllInboxNotifications as z };
|
package/dist/suspense.cjs
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunkMSLJX4ZWcjs = require('./chunk-MSLJX4ZW.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
@@ -73,12 +73,18 @@ var _chunkSTFFVL4Dcjs = require('./chunk-STFFVL4D.cjs');
|
|
|
73
73
|
|
|
74
74
|
|
|
75
75
|
|
|
76
|
-
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
|
|
79
|
+
var _chunkY6Z36KDPcjs = require('./chunk-Y6Z36KDP.cjs');
|
|
77
80
|
|
|
78
81
|
// src/suspense.ts
|
|
79
82
|
var _core = require('@liveblocks/core');
|
|
80
83
|
var _client = require('@liveblocks/client');
|
|
81
|
-
_core.detectDupes.call(void 0,
|
|
84
|
+
_core.detectDupes.call(void 0, _chunkMSLJX4ZWcjs.PKG_NAME, _chunkMSLJX4ZWcjs.PKG_VERSION, _chunkMSLJX4ZWcjs.PKG_FORMAT);
|
|
85
|
+
|
|
86
|
+
|
|
87
|
+
|
|
82
88
|
|
|
83
89
|
|
|
84
90
|
|
|
@@ -151,5 +157,5 @@ _core.detectDupes.call(void 0, _chunkSTFFVL4Dcjs.PKG_NAME, _chunkSTFFVL4Dcjs.PKG
|
|
|
151
157
|
|
|
152
158
|
|
|
153
159
|
|
|
154
|
-
exports.ClientContext =
|
|
160
|
+
exports.ClientContext = _chunkY6Z36KDPcjs.ClientContext; exports.ClientSideSuspense = _chunkMSLJX4ZWcjs.ClientSideSuspense; exports.LiveblocksProvider = _chunkY6Z36KDPcjs.LiveblocksProvider; exports.RegisterAiKnowledge = _chunkY6Z36KDPcjs.RegisterAiKnowledge; exports.RoomContext = _chunkY6Z36KDPcjs.RoomContext; exports.RoomProvider = _chunkY6Z36KDPcjs._RoomProvider; exports.isNotificationChannelEnabled = _client.isNotificationChannelEnabled; exports.shallow = _client.shallow; exports.useAddReaction = _chunkY6Z36KDPcjs._useAddReaction; exports.useAiChat = _chunkY6Z36KDPcjs._useAiChatSuspense; exports.useAiChatMessages = _chunkY6Z36KDPcjs._useAiChatMessagesSuspense; exports.useAiChats = _chunkY6Z36KDPcjs._useAiChatsSuspense; exports.useAttachmentUrl = _chunkY6Z36KDPcjs.useAttachmentUrlSuspense; exports.useBatch = _chunkY6Z36KDPcjs.useBatch; exports.useBroadcastEvent = _chunkY6Z36KDPcjs._useBroadcastEvent; exports.useCanRedo = _chunkY6Z36KDPcjs.useCanRedo; exports.useCanUndo = _chunkY6Z36KDPcjs.useCanUndo; exports.useClient = _chunkY6Z36KDPcjs.useClient; exports.useCreateAiChat = _chunkY6Z36KDPcjs.useCreateAiChat; exports.useCreateComment = _chunkY6Z36KDPcjs.useCreateComment; exports.useCreateThread = _chunkY6Z36KDPcjs._useCreateThread; exports.useDeleteAiChat = _chunkY6Z36KDPcjs.useDeleteAiChat; exports.useDeleteAllInboxNotifications = _chunkY6Z36KDPcjs.useDeleteAllInboxNotifications; exports.useDeleteComment = _chunkY6Z36KDPcjs.useDeleteComment; exports.useDeleteInboxNotification = _chunkY6Z36KDPcjs.useDeleteInboxNotification; exports.useDeleteThread = _chunkY6Z36KDPcjs._useDeleteThread; exports.useEditComment = _chunkY6Z36KDPcjs.useEditComment; exports.useEditThreadMetadata = _chunkY6Z36KDPcjs._useEditThreadMetadata; exports.useErrorListener = _chunkY6Z36KDPcjs.useErrorListener; exports.useEventListener = _chunkY6Z36KDPcjs._useEventListener; exports.useHistory = _chunkY6Z36KDPcjs.useHistory; exports.useHistoryVersions = _chunkY6Z36KDPcjs._useHistoryVersionsSuspense; exports.useInboxNotificationThread = _chunkY6Z36KDPcjs._useInboxNotificationThread; exports.useInboxNotifications = _chunkY6Z36KDPcjs.useInboxNotificationsSuspense; exports.useIsInsideRoom = _chunkY6Z36KDPcjs._useIsInsideRoom; exports.useLostConnectionListener = _chunkY6Z36KDPcjs.useLostConnectionListener; exports.useMarkAllInboxNotificationsAsRead = _chunkY6Z36KDPcjs.useMarkAllInboxNotificationsAsRead; exports.useMarkInboxNotificationAsRead = _chunkY6Z36KDPcjs.useMarkInboxNotificationAsRead; exports.useMarkThreadAsRead = _chunkY6Z36KDPcjs.useMarkThreadAsRead; exports.useMarkThreadAsResolved = _chunkY6Z36KDPcjs.useMarkThreadAsResolved; exports.useMarkThreadAsUnresolved = _chunkY6Z36KDPcjs.useMarkThreadAsUnresolved; exports.useMutation = _chunkY6Z36KDPcjs._useMutation; exports.useMyPresence = _chunkY6Z36KDPcjs._useMyPresence; exports.useNotificationSettings = _chunkY6Z36KDPcjs.useNotificationSettingsSuspense; exports.useOther = _chunkY6Z36KDPcjs._useOtherSuspense; exports.useOthers = _chunkY6Z36KDPcjs._useOthersSuspense; exports.useOthersConnectionIds = _chunkY6Z36KDPcjs.useOthersConnectionIdsSuspense; exports.useOthersListener = _chunkY6Z36KDPcjs._useOthersListener; exports.useOthersMapped = _chunkY6Z36KDPcjs._useOthersMappedSuspense; exports.useRedo = _chunkY6Z36KDPcjs.useRedo; exports.useRemoveReaction = _chunkY6Z36KDPcjs.useRemoveReaction; exports.useRoom = _chunkY6Z36KDPcjs._useRoom; exports.useRoomInfo = _chunkY6Z36KDPcjs.useRoomInfoSuspense; exports.useRoomNotificationSettings = _chunkY6Z36KDPcjs._useRoomNotificationSettingsSuspense; exports.useRoomSubscriptionSettings = _chunkY6Z36KDPcjs._useRoomSubscriptionSettingsSuspense; exports.useSelf = _chunkY6Z36KDPcjs._useSelfSuspense; exports.useSendAiMessage = _chunkY6Z36KDPcjs.useSendAiMessage; exports.useStatus = _chunkY6Z36KDPcjs.useStatus; exports.useStorage = _chunkY6Z36KDPcjs._useStorageSuspense; exports.useStorageRoot = _chunkY6Z36KDPcjs._useStorageRoot; exports.useStorageStatus = _chunkY6Z36KDPcjs.useStorageStatusSuspense; exports.useSubscribeToThread = _chunkY6Z36KDPcjs.useSubscribeToThread; exports.useSyncStatus = _chunkY6Z36KDPcjs.useSyncStatus; exports.useThreadSubscription = _chunkY6Z36KDPcjs.useThreadSubscription; exports.useThreads = _chunkY6Z36KDPcjs._useThreadsSuspense; exports.useUndo = _chunkY6Z36KDPcjs.useUndo; exports.useUnreadInboxNotificationsCount = _chunkY6Z36KDPcjs.useUnreadInboxNotificationsCountSuspense; exports.useUnsubscribeFromThread = _chunkY6Z36KDPcjs.useUnsubscribeFromThread; exports.useUpdateMyPresence = _chunkY6Z36KDPcjs._useUpdateMyPresence; exports.useUpdateNotificationSettings = _chunkY6Z36KDPcjs.useUpdateNotificationSettings; exports.useUpdateRoomNotificationSettings = _chunkY6Z36KDPcjs.useUpdateRoomNotificationSettings; exports.useUpdateRoomSubscriptionSettings = _chunkY6Z36KDPcjs.useUpdateRoomSubscriptionSettings; exports.useUser = _chunkY6Z36KDPcjs._useUserSuspense; exports.useUserThreads_experimental = _chunkY6Z36KDPcjs._useUserThreadsSuspense_experimental;
|
|
155
161
|
//# sourceMappingURL=suspense.cjs.map
|
package/dist/suspense.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["/home/runner/work/liveblocks/liveblocks/packages/liveblocks-react/dist/suspense.cjs","../src/suspense.ts"],"names":[],"mappings":"AAAA;AACE;AACA;AACA;AACA;AACF,wDAA6B;AAC7B;AACE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACF,wDAA6B;AAC7B;AACA;
|
|
1
|
+
{"version":3,"sources":["/home/runner/work/liveblocks/liveblocks/packages/liveblocks-react/dist/suspense.cjs","../src/suspense.ts"],"names":[],"mappings":"AAAA;AACE;AACA;AACA;AACA;AACF,wDAA6B;AAC7B;AACE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACF,wDAA6B;AAC7B;AACA;AC/EA,wCAA4B;AAc5B,4CAAsD;AAXtD,+BAAA,0BAAY,EAAU,6BAAA,EAAa,4BAAU,CAAA;ADgF7C;AACE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACF,84JAAC","file":"/home/runner/work/liveblocks/liveblocks/packages/liveblocks-react/dist/suspense.cjs","sourcesContent":[null,"/* eslint-disable simple-import-sort/exports */\nimport { detectDupes } from \"@liveblocks/core\";\n\nimport { PKG_FORMAT, PKG_NAME, PKG_VERSION } from \"./version\";\ndetectDupes(PKG_NAME, PKG_VERSION, PKG_FORMAT);\n\nexport { ClientSideSuspense } from \"./ClientSideSuspense\";\nexport type {\n MutationContext,\n UseStorageStatusOptions,\n UseThreadsOptions,\n} from \"./types\";\n\n// Re-exports from @liveblocks/client, for convenience\nexport type { Json, JsonObject } from \"@liveblocks/client\";\nexport { shallow, isNotificationChannelEnabled } from \"@liveblocks/client\";\n\n// Export all the top-level hooks\nexport { ClientContext, RoomContext, useClient } from \"./contexts\";\nexport { RegisterAiKnowledge } from \"./ai\";\nexport {\n LiveblocksProvider,\n useInboxNotificationThread,\n useMarkAllInboxNotificationsAsRead,\n useMarkInboxNotificationAsRead,\n useDeleteAllInboxNotifications,\n useDeleteInboxNotification,\n useUpdateNotificationSettings,\n useCreateAiChat,\n useDeleteAiChat,\n useSendAiMessage,\n useSyncStatus,\n useErrorListener,\n} from \"./liveblocks\";\nexport {\n RoomProvider,\n useAddReaction,\n useBatch,\n useBroadcastEvent,\n useCanRedo,\n useCanUndo,\n useCreateComment,\n useCreateThread,\n useDeleteComment,\n useDeleteThread,\n useEditComment,\n useEditThreadMetadata,\n useMarkThreadAsResolved,\n useMarkThreadAsUnresolved,\n useSubscribeToThread,\n useUnsubscribeFromThread,\n useEventListener,\n useHistory,\n useIsInsideRoom,\n useLostConnectionListener,\n useMarkThreadAsRead,\n useMutation,\n useMyPresence,\n useOthersListener,\n useRedo,\n useRemoveReaction,\n useRoom,\n useStatus,\n useStorageRoot,\n useThreadSubscription,\n useUndo,\n useUpdateMyPresence,\n useUpdateRoomNotificationSettings,\n useUpdateRoomSubscriptionSettings,\n} from \"./room\";\n\n// Export the Suspense versions of our hooks\n// (This part differs from src/index.ts)\nexport {\n useOtherSuspense as useOther,\n useOthersSuspense as useOthers,\n useOthersConnectionIdsSuspense as useOthersConnectionIds,\n useOthersMappedSuspense as useOthersMapped,\n useSelfSuspense as useSelf,\n useStorageSuspense as useStorage,\n useStorageStatusSuspense as useStorageStatus,\n useThreadsSuspense as useThreads,\n useAttachmentUrlSuspense as useAttachmentUrl,\n useHistoryVersionsSuspense as useHistoryVersions,\n useRoomNotificationSettingsSuspense as useRoomNotificationSettings,\n useRoomSubscriptionSettingsSuspense as useRoomSubscriptionSettings,\n} from \"./room\";\nexport {\n useInboxNotificationsSuspense as useInboxNotifications,\n useNotificationSettingsSuspense as useNotificationSettings,\n useRoomInfoSuspense as useRoomInfo,\n useUnreadInboxNotificationsCountSuspense as useUnreadInboxNotificationsCount,\n useUserSuspense as useUser,\n useUserThreadsSuspense_experimental as useUserThreads_experimental,\n useAiChatsSuspense as useAiChats,\n useAiChatMessagesSuspense as useAiChatMessages,\n useAiChatSuspense as useAiChat,\n} from \"./liveblocks\";\n"]}
|
package/dist/suspense.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { ClientSideSuspense,
|
|
2
|
-
export { C as ClientContext, L as LiveblocksProvider, M as MutationContext, H as RoomProvider, U as UseStorageStatusOptions, w as UseThreadsOptions, I as useAddReaction,
|
|
1
|
+
export { ClientSideSuspense, RegisterAiKnowledge } from './index.cjs';
|
|
2
|
+
export { C as ClientContext, L as LiveblocksProvider, M as MutationContext, R as RoomContext, H as RoomProvider, U as UseStorageStatusOptions, w as UseThreadsOptions, I as useAddReaction, b0 as useAiChat, a$ as useAiChatMessages, a_ as useAiChats, aQ as useAttachmentUrl, J as useBatch, K as useBroadcastEvent, N as useCanRedo, O as useCanUndo, x as useClient, ay as useCreateAiChat, P as useCreateComment, Q as useCreateThread, az as useDeleteAiChat, z as useDeleteAllInboxNotifications, S as useDeleteComment, A as useDeleteInboxNotification, T as useDeleteThread, V as useEditComment, W as useEditThreadMetadata, B as useErrorListener, a0 as useEventListener, a1 as useHistory, aR as useHistoryVersions, _ as useInboxNotificationThread, aU as useInboxNotifications, a2 as useIsInsideRoom, a3 as useLostConnectionListener, D as useMarkAllInboxNotificationsAsRead, E as useMarkInboxNotificationAsRead, a4 as useMarkThreadAsRead, X as useMarkThreadAsResolved, Y as useMarkThreadAsUnresolved, a5 as useMutation, a6 as useMyPresence, aV as useNotificationSettings, aI as useOther, aJ as useOthers, aK as useOthersConnectionIds, a7 as useOthersListener, aL as useOthersMapped, a8 as useRedo, a9 as useRemoveReaction, aa as useRoom, aW as useRoomInfo, aS as useRoomNotificationSettings, aT as useRoomSubscriptionSettings, aM as useSelf, aA as useSendAiMessage, ab as useStatus, aN as useStorage, ac as useStorageRoot, aO as useStorageStatus, Z as useSubscribeToThread, F as useSyncStatus, ad as useThreadSubscription, aP as useThreads, ae as useUndo, aX as useUnreadInboxNotificationsCount, $ as useUnsubscribeFromThread, af as useUpdateMyPresence, ax as useUpdateNotificationSettings, ag as useUpdateRoomNotificationSettings, ah as useUpdateRoomSubscriptionSettings, aY as useUser, aZ as useUserThreads_experimental } from './room-BYtyYCxu.cjs';
|
|
3
3
|
export { Json, JsonObject, isNotificationChannelEnabled, shallow } from '@liveblocks/client';
|
|
4
4
|
import 'react/jsx-runtime';
|
|
5
5
|
import 'react';
|
package/dist/suspense.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { ClientSideSuspense,
|
|
2
|
-
export { C as ClientContext, L as LiveblocksProvider, M as MutationContext, H as RoomProvider, U as UseStorageStatusOptions, w as UseThreadsOptions, I as useAddReaction,
|
|
1
|
+
export { ClientSideSuspense, RegisterAiKnowledge } from './index.js';
|
|
2
|
+
export { C as ClientContext, L as LiveblocksProvider, M as MutationContext, R as RoomContext, H as RoomProvider, U as UseStorageStatusOptions, w as UseThreadsOptions, I as useAddReaction, b0 as useAiChat, a$ as useAiChatMessages, a_ as useAiChats, aQ as useAttachmentUrl, J as useBatch, K as useBroadcastEvent, N as useCanRedo, O as useCanUndo, x as useClient, ay as useCreateAiChat, P as useCreateComment, Q as useCreateThread, az as useDeleteAiChat, z as useDeleteAllInboxNotifications, S as useDeleteComment, A as useDeleteInboxNotification, T as useDeleteThread, V as useEditComment, W as useEditThreadMetadata, B as useErrorListener, a0 as useEventListener, a1 as useHistory, aR as useHistoryVersions, _ as useInboxNotificationThread, aU as useInboxNotifications, a2 as useIsInsideRoom, a3 as useLostConnectionListener, D as useMarkAllInboxNotificationsAsRead, E as useMarkInboxNotificationAsRead, a4 as useMarkThreadAsRead, X as useMarkThreadAsResolved, Y as useMarkThreadAsUnresolved, a5 as useMutation, a6 as useMyPresence, aV as useNotificationSettings, aI as useOther, aJ as useOthers, aK as useOthersConnectionIds, a7 as useOthersListener, aL as useOthersMapped, a8 as useRedo, a9 as useRemoveReaction, aa as useRoom, aW as useRoomInfo, aS as useRoomNotificationSettings, aT as useRoomSubscriptionSettings, aM as useSelf, aA as useSendAiMessage, ab as useStatus, aN as useStorage, ac as useStorageRoot, aO as useStorageStatus, Z as useSubscribeToThread, F as useSyncStatus, ad as useThreadSubscription, aP as useThreads, ae as useUndo, aX as useUnreadInboxNotificationsCount, $ as useUnsubscribeFromThread, af as useUpdateMyPresence, ax as useUpdateNotificationSettings, ag as useUpdateRoomNotificationSettings, ah as useUpdateRoomSubscriptionSettings, aY as useUser, aZ as useUserThreads_experimental } from './room-BYtyYCxu.js';
|
|
3
3
|
export { Json, JsonObject, isNotificationChannelEnabled, shallow } from '@liveblocks/client';
|
|
4
4
|
import 'react/jsx-runtime';
|
|
5
5
|
import 'react';
|
package/dist/suspense.js
CHANGED
|
@@ -3,14 +3,16 @@ import {
|
|
|
3
3
|
PKG_FORMAT,
|
|
4
4
|
PKG_NAME,
|
|
5
5
|
PKG_VERSION
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-Y2RSQZ5R.js";
|
|
7
7
|
import {
|
|
8
8
|
ClientContext,
|
|
9
9
|
LiveblocksProvider,
|
|
10
|
+
RegisterAiKnowledge,
|
|
10
11
|
RoomContext,
|
|
11
12
|
_RoomProvider,
|
|
12
13
|
_useAddReaction,
|
|
13
14
|
_useAiChatMessagesSuspense,
|
|
15
|
+
_useAiChatSuspense,
|
|
14
16
|
_useAiChatsSuspense,
|
|
15
17
|
_useBroadcastEvent,
|
|
16
18
|
_useCreateThread,
|
|
@@ -62,6 +64,7 @@ import {
|
|
|
62
64
|
useRedo,
|
|
63
65
|
useRemoveReaction,
|
|
64
66
|
useRoomInfoSuspense,
|
|
67
|
+
useSendAiMessage,
|
|
65
68
|
useStatus,
|
|
66
69
|
useStorageStatusSuspense,
|
|
67
70
|
useSubscribeToThread,
|
|
@@ -73,7 +76,7 @@ import {
|
|
|
73
76
|
useUpdateNotificationSettings,
|
|
74
77
|
useUpdateRoomNotificationSettings,
|
|
75
78
|
useUpdateRoomSubscriptionSettings
|
|
76
|
-
} from "./chunk-
|
|
79
|
+
} from "./chunk-Y7BGHNHH.js";
|
|
77
80
|
|
|
78
81
|
// src/suspense.ts
|
|
79
82
|
import { detectDupes } from "@liveblocks/core";
|
|
@@ -83,11 +86,13 @@ export {
|
|
|
83
86
|
ClientContext,
|
|
84
87
|
ClientSideSuspense,
|
|
85
88
|
LiveblocksProvider,
|
|
89
|
+
RegisterAiKnowledge,
|
|
86
90
|
RoomContext,
|
|
87
91
|
_RoomProvider as RoomProvider,
|
|
88
92
|
isNotificationChannelEnabled,
|
|
89
93
|
shallow,
|
|
90
94
|
_useAddReaction as useAddReaction,
|
|
95
|
+
_useAiChatSuspense as useAiChat,
|
|
91
96
|
_useAiChatMessagesSuspense as useAiChatMessages,
|
|
92
97
|
_useAiChatsSuspense as useAiChats,
|
|
93
98
|
useAttachmentUrlSuspense as useAttachmentUrl,
|
|
@@ -134,6 +139,7 @@ export {
|
|
|
134
139
|
_useRoomNotificationSettingsSuspense as useRoomNotificationSettings,
|
|
135
140
|
_useRoomSubscriptionSettingsSuspense as useRoomSubscriptionSettings,
|
|
136
141
|
_useSelfSuspense as useSelf,
|
|
142
|
+
useSendAiMessage,
|
|
137
143
|
useStatus,
|
|
138
144
|
_useStorageSuspense as useStorage,
|
|
139
145
|
_useStorageRoot as useStorageRoot,
|
package/dist/suspense.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/suspense.ts"],"sourcesContent":["/* eslint-disable simple-import-sort/exports */\nimport { detectDupes } from \"@liveblocks/core\";\n\nimport { PKG_FORMAT, PKG_NAME, PKG_VERSION } from \"./version\";\ndetectDupes(PKG_NAME, PKG_VERSION, PKG_FORMAT);\n\nexport { ClientSideSuspense } from \"./ClientSideSuspense\";\nexport type {\n MutationContext,\n UseStorageStatusOptions,\n UseThreadsOptions,\n} from \"./types\";\n\n// Re-exports from @liveblocks/client, for convenience\nexport type { Json, JsonObject } from \"@liveblocks/client\";\nexport { shallow, isNotificationChannelEnabled } from \"@liveblocks/client\";\n\n// Export all the top-level hooks\nexport {\n
|
|
1
|
+
{"version":3,"sources":["../src/suspense.ts"],"sourcesContent":["/* eslint-disable simple-import-sort/exports */\nimport { detectDupes } from \"@liveblocks/core\";\n\nimport { PKG_FORMAT, PKG_NAME, PKG_VERSION } from \"./version\";\ndetectDupes(PKG_NAME, PKG_VERSION, PKG_FORMAT);\n\nexport { ClientSideSuspense } from \"./ClientSideSuspense\";\nexport type {\n MutationContext,\n UseStorageStatusOptions,\n UseThreadsOptions,\n} from \"./types\";\n\n// Re-exports from @liveblocks/client, for convenience\nexport type { Json, JsonObject } from \"@liveblocks/client\";\nexport { shallow, isNotificationChannelEnabled } from \"@liveblocks/client\";\n\n// Export all the top-level hooks\nexport { ClientContext, RoomContext, useClient } from \"./contexts\";\nexport { RegisterAiKnowledge } from \"./ai\";\nexport {\n LiveblocksProvider,\n useInboxNotificationThread,\n useMarkAllInboxNotificationsAsRead,\n useMarkInboxNotificationAsRead,\n useDeleteAllInboxNotifications,\n useDeleteInboxNotification,\n useUpdateNotificationSettings,\n useCreateAiChat,\n useDeleteAiChat,\n useSendAiMessage,\n useSyncStatus,\n useErrorListener,\n} from \"./liveblocks\";\nexport {\n RoomProvider,\n useAddReaction,\n useBatch,\n useBroadcastEvent,\n useCanRedo,\n useCanUndo,\n useCreateComment,\n useCreateThread,\n useDeleteComment,\n useDeleteThread,\n useEditComment,\n useEditThreadMetadata,\n useMarkThreadAsResolved,\n useMarkThreadAsUnresolved,\n useSubscribeToThread,\n useUnsubscribeFromThread,\n useEventListener,\n useHistory,\n useIsInsideRoom,\n useLostConnectionListener,\n useMarkThreadAsRead,\n useMutation,\n useMyPresence,\n useOthersListener,\n useRedo,\n useRemoveReaction,\n useRoom,\n useStatus,\n useStorageRoot,\n useThreadSubscription,\n useUndo,\n useUpdateMyPresence,\n useUpdateRoomNotificationSettings,\n useUpdateRoomSubscriptionSettings,\n} from \"./room\";\n\n// Export the Suspense versions of our hooks\n// (This part differs from src/index.ts)\nexport {\n useOtherSuspense as useOther,\n useOthersSuspense as useOthers,\n useOthersConnectionIdsSuspense as useOthersConnectionIds,\n useOthersMappedSuspense as useOthersMapped,\n useSelfSuspense as useSelf,\n useStorageSuspense as useStorage,\n useStorageStatusSuspense as useStorageStatus,\n useThreadsSuspense as useThreads,\n useAttachmentUrlSuspense as useAttachmentUrl,\n useHistoryVersionsSuspense as useHistoryVersions,\n useRoomNotificationSettingsSuspense as useRoomNotificationSettings,\n useRoomSubscriptionSettingsSuspense as useRoomSubscriptionSettings,\n} from \"./room\";\nexport {\n useInboxNotificationsSuspense as useInboxNotifications,\n useNotificationSettingsSuspense as useNotificationSettings,\n useRoomInfoSuspense as useRoomInfo,\n useUnreadInboxNotificationsCountSuspense as useUnreadInboxNotificationsCount,\n useUserSuspense as useUser,\n useUserThreadsSuspense_experimental as useUserThreads_experimental,\n useAiChatsSuspense as useAiChats,\n useAiChatMessagesSuspense as useAiChatMessages,\n useAiChatSuspense as useAiChat,\n} from \"./liveblocks\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,SAAS,mBAAmB;AAc5B,SAAS,SAAS,oCAAoC;AAXtD,YAAY,UAAU,aAAa,UAAU;","names":[]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@liveblocks/react",
|
|
3
|
-
"version": "2.25.0-
|
|
3
|
+
"version": "2.25.0-aiprivatebeta10",
|
|
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": "module",
|
|
@@ -61,12 +61,22 @@
|
|
|
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.25.0-
|
|
65
|
-
"@liveblocks/core": "2.25.0-
|
|
64
|
+
"@liveblocks/client": "2.25.0-aiprivatebeta10",
|
|
65
|
+
"@liveblocks/core": "2.25.0-aiprivatebeta10"
|
|
66
66
|
},
|
|
67
67
|
"peerDependencies": {
|
|
68
|
+
"@types/react": "*",
|
|
69
|
+
"@types/react-dom": "*",
|
|
68
70
|
"react": "^18 || ^19 || ^19.0.0-rc"
|
|
69
71
|
},
|
|
72
|
+
"peerDependenciesMeta": {
|
|
73
|
+
"@types/react": {
|
|
74
|
+
"optional": true
|
|
75
|
+
},
|
|
76
|
+
"@types/react-dom": {
|
|
77
|
+
"optional": true
|
|
78
|
+
}
|
|
79
|
+
},
|
|
70
80
|
"devDependencies": {
|
|
71
81
|
"@liveblocks/eslint-config": "*",
|
|
72
82
|
"@liveblocks/jest-config": "*",
|