@liveblocks/react 3.15.0-feeds2 → 3.15.0-rc1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_private.cjs +7 -7
- package/dist/_private.d.cts +2 -2
- package/dist/_private.d.ts +2 -2
- package/dist/_private.js +1 -1
- package/dist/{chunk-GWYQHSXI.js → chunk-7TVEKSIE.js} +725 -527
- package/dist/chunk-7TVEKSIE.js.map +1 -0
- package/dist/{chunk-NHU725OF.cjs → chunk-L3D3UECF.cjs} +761 -563
- package/dist/chunk-L3D3UECF.cjs.map +1 -0
- package/dist/{chunk-7I2IBAFZ.cjs → chunk-SBRWCEYI.cjs} +2 -2
- package/dist/{chunk-7I2IBAFZ.cjs.map → chunk-SBRWCEYI.cjs.map} +1 -1
- package/dist/{chunk-H7GF5P7X.js → chunk-XWDDGVZ4.js} +2 -2
- package/dist/index.cjs +4 -20
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +4 -20
- package/dist/index.js.map +1 -1
- package/dist/{room-c0k0bfIo.d.cts → room-C3ujtNzt.d.cts} +20 -182
- package/dist/{room-c0k0bfIo.d.ts → room-C3ujtNzt.d.ts} +20 -182
- package/dist/suspense.cjs +4 -20
- package/dist/suspense.cjs.map +1 -1
- package/dist/suspense.d.cts +1 -1
- package/dist/suspense.d.ts +1 -1
- package/dist/suspense.js +4 -20
- package/dist/suspense.js.map +1 -1
- package/package.json +3 -3
- package/dist/chunk-GWYQHSXI.js.map +0 -1
- package/dist/chunk-NHU725OF.cjs.map +0 -1
- /package/dist/{chunk-H7GF5P7X.js.map → chunk-XWDDGVZ4.js.map} +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});// src/version.ts
|
|
2
2
|
var PKG_NAME = "@liveblocks/react";
|
|
3
|
-
var PKG_VERSION = "3.15.0-
|
|
3
|
+
var PKG_VERSION = "3.15.0-rc1";
|
|
4
4
|
var PKG_FORMAT = "cjs";
|
|
5
5
|
|
|
6
6
|
// src/ClientSideSuspense.tsx
|
|
@@ -20,4 +20,4 @@ function ClientSideSuspense(props) {
|
|
|
20
20
|
|
|
21
21
|
|
|
22
22
|
exports.PKG_NAME = PKG_NAME; exports.PKG_VERSION = PKG_VERSION; exports.PKG_FORMAT = PKG_FORMAT; exports.ClientSideSuspense = ClientSideSuspense;
|
|
23
|
-
//# sourceMappingURL=chunk-
|
|
23
|
+
//# sourceMappingURL=chunk-SBRWCEYI.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["/home/runner/work/liveblocks/liveblocks/packages/liveblocks-react/dist/chunk-
|
|
1
|
+
{"version":3,"sources":["/home/runner/work/liveblocks/liveblocks/packages/liveblocks-react/dist/chunk-SBRWCEYI.cjs","../src/version.ts","../src/ClientSideSuspense.tsx"],"names":[],"mappings":"AAAA;ACGO,IAAM,SAAA,EAAW,mBAAA;AACjB,IAAM,YAAA,EAAiD,YAAA;AACvD,IAAM,WAAA,EAAgD,KAAA;ADD7D;AACA;AEJA,8BAA8C;AAkC1C,+CAAA;AAVG,SAAS,kBAAA,CAAmB,KAAA,EAAc;AAC/C,EAAA,MAAM,CAAC,OAAA,EAAS,UAAU,EAAA,EAAI,6BAAA,KAAc,CAAA;AAE5C,EAAA,8BAAA,CAAU,EAAA,GAAM;AAGd,IAAA,UAAA,CAAW,IAAI,CAAA;AAAA,EACjB,CAAA,EAAG,CAAC,CAAC,CAAA;AAEL,EAAA,uBACE,6BAAA,eAAC,EAAA,EAAS,QAAA,EAAU,KAAA,CAAM,QAAA,EACvB,QAAA,EAAA,QAAA,EACG,OAAO,KAAA,CAAM,SAAA,IAAa,WAAA,EACxB,KAAA,CAAM,QAAA,CAAS,EAAA,EACf,KAAA,CAAM,SAAA,EACR,KAAA,CAAM,SAAA,CACZ,CAAA;AAEJ;AF5BA;AACA;AACE;AACA;AACA;AACA;AACF,iJAAC","file":"/home/runner/work/liveblocks/liveblocks/packages/liveblocks-react/dist/chunk-SBRWCEYI.cjs","sourcesContent":[null,"declare const __VERSION__: string;\ndeclare const TSUP_FORMAT: string;\n\nexport const PKG_NAME = \"@liveblocks/react\";\nexport const PKG_VERSION = typeof __VERSION__ === \"string\" && __VERSION__;\nexport const PKG_FORMAT = typeof TSUP_FORMAT === \"string\" && TSUP_FORMAT;\n","import type { ReactNode } from \"react\";\nimport { Suspense, useEffect, useState } from \"react\";\n\ntype Props = {\n fallback: ReactNode;\n children: (() => ReactNode | undefined) | ReactNode | undefined;\n};\n\n/**\n * Almost like a normal <Suspense> component, except that for server-side\n * renders, the fallback will be used.\n *\n * The child props will have to be provided in a function, i.e. change:\n *\n * <Suspense fallback={<Loading />}>\n * <MyRealComponent a={1} />\n * </Suspense>\n *\n * To:\n *\n * <ClientSideSuspense fallback={<Loading />}>\n * <MyRealComponent a={1} />\n * </ClientSideSuspense>\n *\n */\nexport function ClientSideSuspense(props: Props) {\n const [mounted, setMounted] = useState(false);\n\n useEffect(() => {\n // Effects are never executed on the server side. The point of this is to\n // delay the flipping of this boolean until after hydration has happened.\n setMounted(true);\n }, []);\n\n return (\n <Suspense fallback={props.fallback}>\n {mounted\n ? typeof props.children === \"function\"\n ? props.children()\n : props.children\n : props.fallback}\n </Suspense>\n );\n}\n"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// src/version.ts
|
|
2
2
|
var PKG_NAME = "@liveblocks/react";
|
|
3
|
-
var PKG_VERSION = "3.15.0-
|
|
3
|
+
var PKG_VERSION = "3.15.0-rc1";
|
|
4
4
|
var PKG_FORMAT = "esm";
|
|
5
5
|
|
|
6
6
|
// src/ClientSideSuspense.tsx
|
|
@@ -20,4 +20,4 @@ export {
|
|
|
20
20
|
PKG_FORMAT,
|
|
21
21
|
ClientSideSuspense
|
|
22
22
|
};
|
|
23
|
-
//# sourceMappingURL=chunk-
|
|
23
|
+
//# sourceMappingURL=chunk-XWDDGVZ4.js.map
|
package/dist/index.cjs
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunkSBRWCEYIcjs = require('./chunk-SBRWCEYI.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
@@ -81,28 +81,12 @@ var _chunk7I2IBAFZcjs = require('./chunk-7I2IBAFZ.cjs');
|
|
|
81
81
|
|
|
82
82
|
|
|
83
83
|
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
var _chunkNHU725OFcjs = require('./chunk-NHU725OF.cjs');
|
|
84
|
+
var _chunkL3D3UECFcjs = require('./chunk-L3D3UECF.cjs');
|
|
93
85
|
|
|
94
86
|
// src/index.ts
|
|
95
87
|
var _core = require('@liveblocks/core');
|
|
96
88
|
var _client = require('@liveblocks/client');
|
|
97
|
-
_core.detectDupes.call(void 0,
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
89
|
+
_core.detectDupes.call(void 0, _chunkSBRWCEYIcjs.PKG_NAME, _chunkSBRWCEYIcjs.PKG_VERSION, _chunkSBRWCEYIcjs.PKG_FORMAT);
|
|
106
90
|
|
|
107
91
|
|
|
108
92
|
|
|
@@ -183,5 +167,5 @@ _core.detectDupes.call(void 0, _chunk7I2IBAFZcjs.PKG_NAME, _chunk7I2IBAFZcjs.PKG
|
|
|
183
167
|
|
|
184
168
|
|
|
185
169
|
|
|
186
|
-
exports.ClientContext =
|
|
170
|
+
exports.ClientContext = _chunkL3D3UECFcjs.ClientContext; exports.ClientSideSuspense = _chunkSBRWCEYIcjs.ClientSideSuspense; exports.LiveblocksProvider = _chunkL3D3UECFcjs.LiveblocksProvider; exports.RegisterAiKnowledge = _chunkL3D3UECFcjs.RegisterAiKnowledge; exports.RegisterAiTool = _chunkL3D3UECFcjs.RegisterAiTool; exports.RoomContext = _chunkL3D3UECFcjs.GlobalRoomContext; exports.RoomProvider = _chunkL3D3UECFcjs._RoomProvider; exports.createLiveblocksContext = _chunkL3D3UECFcjs.createLiveblocksContext; exports.createRoomContext = _chunkL3D3UECFcjs.createRoomContext; exports.isNotificationChannelEnabled = _client.isNotificationChannelEnabled; exports.shallow = _client.shallow; exports.useAddReaction = _chunkL3D3UECFcjs._useAddReaction; exports.useAiChat = _chunkL3D3UECFcjs._useAiChat; exports.useAiChatMessages = _chunkL3D3UECFcjs._useAiChatMessages; exports.useAiChatStatus = _chunkL3D3UECFcjs.useAiChatStatus; exports.useAiChats = _chunkL3D3UECFcjs._useAiChats; exports.useAttachmentUrl = _chunkL3D3UECFcjs.useAttachmentUrl; exports.useBroadcastEvent = _chunkL3D3UECFcjs._useBroadcastEvent; exports.useCanRedo = _chunkL3D3UECFcjs.useCanRedo; exports.useCanUndo = _chunkL3D3UECFcjs.useCanUndo; exports.useClient = _chunkL3D3UECFcjs.useClient; exports.useCreateAiChat = _chunkL3D3UECFcjs.useCreateAiChat; exports.useCreateComment = _chunkL3D3UECFcjs._useCreateComment; exports.useCreateThread = _chunkL3D3UECFcjs._useCreateThread; exports.useDeleteAiChat = _chunkL3D3UECFcjs.useDeleteAiChat; exports.useDeleteAllInboxNotifications = _chunkL3D3UECFcjs.useDeleteAllInboxNotifications; exports.useDeleteComment = _chunkL3D3UECFcjs.useDeleteComment; exports.useDeleteInboxNotification = _chunkL3D3UECFcjs.useDeleteInboxNotification; exports.useDeleteThread = _chunkL3D3UECFcjs._useDeleteThread; exports.useEditComment = _chunkL3D3UECFcjs._useEditComment; exports.useEditCommentMetadata = _chunkL3D3UECFcjs._useEditCommentMetadata; exports.useEditThreadMetadata = _chunkL3D3UECFcjs._useEditThreadMetadata; exports.useErrorListener = _chunkL3D3UECFcjs.useErrorListener; exports.useEventListener = _chunkL3D3UECFcjs._useEventListener; exports.useGroupInfo = _chunkL3D3UECFcjs.useGroupInfo; exports.useHistory = _chunkL3D3UECFcjs.useHistory; exports.useHistoryVersionData = _chunkL3D3UECFcjs.useHistoryVersionData; exports.useHistoryVersions = _chunkL3D3UECFcjs._useHistoryVersions; exports.useInboxNotificationThread = _chunkL3D3UECFcjs._useInboxNotificationThread; exports.useInboxNotifications = _chunkL3D3UECFcjs.useInboxNotifications; exports.useIsInsideRoom = _chunkL3D3UECFcjs._useIsInsideRoom; exports.useLostConnectionListener = _chunkL3D3UECFcjs.useLostConnectionListener; exports.useMarkAllInboxNotificationsAsRead = _chunkL3D3UECFcjs.useMarkAllInboxNotificationsAsRead; exports.useMarkInboxNotificationAsRead = _chunkL3D3UECFcjs.useMarkInboxNotificationAsRead; exports.useMarkThreadAsRead = _chunkL3D3UECFcjs.useMarkThreadAsRead; exports.useMarkThreadAsResolved = _chunkL3D3UECFcjs.useMarkThreadAsResolved; exports.useMarkThreadAsUnresolved = _chunkL3D3UECFcjs.useMarkThreadAsUnresolved; exports.useMutation = _chunkL3D3UECFcjs._useMutation; exports.useMyPresence = _chunkL3D3UECFcjs._useMyPresence; exports.useNotificationSettings = _chunkL3D3UECFcjs.useNotificationSettings; exports.useOther = _chunkL3D3UECFcjs._useOther; exports.useOthers = _chunkL3D3UECFcjs._useOthers; exports.useOthersConnectionIds = _chunkL3D3UECFcjs.useOthersConnectionIds; exports.useOthersListener = _chunkL3D3UECFcjs._useOthersListener; exports.useOthersMapped = _chunkL3D3UECFcjs._useOthersMapped; exports.useRedo = _chunkL3D3UECFcjs.useRedo; exports.useRemoveReaction = _chunkL3D3UECFcjs.useRemoveReaction; exports.useRoom = _chunkL3D3UECFcjs._useRoom; exports.useRoomInfo = _chunkL3D3UECFcjs.useRoomInfo; exports.useRoomSubscriptionSettings = _chunkL3D3UECFcjs._useRoomSubscriptionSettings; exports.useSearchComments = _chunkL3D3UECFcjs._useSearchComments; exports.useSelf = _chunkL3D3UECFcjs._useSelf; exports.useSendAiMessage = _chunkL3D3UECFcjs.useSendAiMessage; exports.useStatus = _chunkL3D3UECFcjs.useStatus; exports.useStorage = _chunkL3D3UECFcjs._useStorage; exports.useStorageRoot = _chunkL3D3UECFcjs._useStorageRoot; exports.useSubscribeToThread = _chunkL3D3UECFcjs.useSubscribeToThread; exports.useSyncStatus = _chunkL3D3UECFcjs.useSyncStatus; exports.useThreadSubscription = _chunkL3D3UECFcjs.useThreadSubscription; exports.useThreads = _chunkL3D3UECFcjs._useThreads; exports.useUndo = _chunkL3D3UECFcjs.useUndo; exports.useUnreadInboxNotificationsCount = _chunkL3D3UECFcjs.useUnreadInboxNotificationsCount; exports.useUnsubscribeFromThread = _chunkL3D3UECFcjs.useUnsubscribeFromThread; exports.useUpdateMyPresence = _chunkL3D3UECFcjs._useUpdateMyPresence; exports.useUpdateNotificationSettings = _chunkL3D3UECFcjs.useUpdateNotificationSettings; exports.useUpdateRoomSubscriptionSettings = _chunkL3D3UECFcjs.useUpdateRoomSubscriptionSettings; exports.useUrlMetadata = _chunkL3D3UECFcjs._useUrlMetadata; exports.useUser = _chunkL3D3UECFcjs._useUser; exports.useUserThreads_experimental = _chunkL3D3UECFcjs._useUserThreads_experimental;
|
|
187
171
|
//# sourceMappingURL=index.cjs.map
|
package/dist/index.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["/home/runner/work/liveblocks/liveblocks/packages/liveblocks-react/dist/index.cjs","../src/index.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;AACA;AACA;AACA;AACA;AACA;
|
|
1
|
+
{"version":3,"sources":["/home/runner/work/liveblocks/liveblocks/packages/liveblocks-react/dist/index.cjs","../src/index.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;AACA;AACA;AACA;AACA;AACA;AACF,wDAA6B;AAC7B;AACA;ACpFA,wCAA4B;AAe5B,4CAAsD;AAZtD,+BAAA,0BAAY,EAAU,6BAAA,EAAa,4BAAU,CAAA;ADqF7C;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;AACA;AACA;AACA;AACA;AACA;AACF,yhKAAC","file":"/home/runner/work/liveblocks/liveblocks/packages/liveblocks-react/dist/index.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 UseSendAiMessageOptions,\n UseThreadsOptions,\n SendAiMessageOptions,\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 { RegisterAiKnowledge, RegisterAiTool } from \"./ai\";\nexport type {\n AiChatStatus,\n RegisterAiKnowledgeProps,\n RegisterAiToolProps,\n} from \"./types/ai\";\nexport {\n ClientContext,\n GlobalRoomContext as RoomContext,\n useClient,\n} from \"./contexts\";\nexport {\n createLiveblocksContext,\n LiveblocksProvider,\n useDeleteAllInboxNotifications,\n useDeleteInboxNotification,\n useErrorListener,\n useInboxNotificationThread,\n useMarkAllInboxNotificationsAsRead,\n useMarkInboxNotificationAsRead,\n useSyncStatus,\n} from \"./liveblocks\";\nexport {\n createRoomContext,\n RoomProvider,\n useAddReaction,\n useBroadcastEvent,\n useCanRedo,\n useCanUndo,\n useCreateComment,\n useCreateThread,\n useDeleteComment,\n useDeleteThread,\n useEditComment,\n useEditThreadMetadata,\n useEditCommentMetadata,\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 useUpdateRoomSubscriptionSettings,\n useHistoryVersionData,\n} from \"./room\";\n\n// Export the classic (non-Suspense) versions of our hooks\n// (This part differs from src/suspense.ts)\nexport {\n useOther,\n useOthers,\n useOthersConnectionIds,\n useOthersMapped,\n useSelf,\n useStorage,\n useThreads,\n useSearchComments,\n useAttachmentUrl,\n useHistoryVersions,\n useRoomSubscriptionSettings,\n} from \"./room\";\nexport {\n useInboxNotifications,\n useNotificationSettings,\n useUpdateNotificationSettings,\n useCreateAiChat,\n useDeleteAiChat,\n useSendAiMessage,\n useUserThreads_experimental as useUserThreads_experimental,\n useRoomInfo,\n useGroupInfo,\n useUnreadInboxNotificationsCount,\n useUser,\n useAiChat,\n useAiChats,\n useAiChatMessages,\n useAiChatStatus,\n useUrlMetadata,\n} from \"./liveblocks\";\n"]}
|
package/dist/index.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { R as RegisterAiKnowledgeProps, w as RegisterAiToolProps } from './room-
|
|
2
|
-
export { A as AiChatStatus, C as ClientContext, L as LiveblocksProvider, M as MutationContext, y as RoomContext, N as RoomProvider, S as SendAiMessageOptions, U as UseSendAiMessageOptions, x as UseThreadsOptions, B as createLiveblocksContext, K as createRoomContext, O as useAddReaction,
|
|
1
|
+
import { R as RegisterAiKnowledgeProps, w as RegisterAiToolProps } from './room-C3ujtNzt.cjs';
|
|
2
|
+
export { A as AiChatStatus, C as ClientContext, L as LiveblocksProvider, M as MutationContext, y as RoomContext, N as RoomProvider, S as SendAiMessageOptions, U as UseSendAiMessageOptions, x as UseThreadsOptions, B as createLiveblocksContext, K as createRoomContext, O as useAddReaction, aJ as useAiChat, aL as useAiChatMessages, aM as useAiChatStatus, aK as useAiChats, av as useAttachmentUrl, P as useBroadcastEvent, Q as useCanRedo, T as useCanUndo, z as useClient, aB as useCreateAiChat, V as useCreateComment, W as useCreateThread, aC as useDeleteAiChat, D as useDeleteAllInboxNotifications, X as useDeleteComment, E as useDeleteInboxNotification, Y as useDeleteThread, Z as useEditComment, a0 as useEditCommentMetadata, $ as useEditThreadMetadata, F as useErrorListener, a5 as useEventListener, aG as useGroupInfo, a6 as useHistory, am as useHistoryVersionData, aw as useHistoryVersions, _ as useInboxNotificationThread, ay as useInboxNotifications, a7 as useIsInsideRoom, a8 as useLostConnectionListener, H as useMarkAllInboxNotificationsAsRead, I as useMarkInboxNotificationAsRead, a9 as useMarkThreadAsRead, a1 as useMarkThreadAsResolved, a2 as useMarkThreadAsUnresolved, aa as useMutation, ab as useMyPresence, az as useNotificationSettings, an as useOther, ao as useOthers, ap as useOthersConnectionIds, ac as useOthersListener, aq as useOthersMapped, ad as useRedo, ae as useRemoveReaction, af as useRoom, aF as useRoomInfo, ax as useRoomSubscriptionSettings, au as useSearchComments, ar as useSelf, aD as useSendAiMessage, ag as useStatus, as as useStorage, ah as useStorageRoot, a3 as useSubscribeToThread, J as useSyncStatus, ai as useThreadSubscription, at as useThreads, aj as useUndo, aH as useUnreadInboxNotificationsCount, a4 as useUnsubscribeFromThread, ak as useUpdateMyPresence, aA as useUpdateNotificationSettings, al as useUpdateRoomSubscriptionSettings, aN as useUrlMetadata, aI as useUser, aE as useUserThreads_experimental } from './room-C3ujtNzt.cjs';
|
|
3
3
|
export { Json, JsonObject, isNotificationChannelEnabled, shallow } from '@liveblocks/client';
|
|
4
4
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
5
5
|
import * as react from 'react';
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { R as RegisterAiKnowledgeProps, w as RegisterAiToolProps } from './room-
|
|
2
|
-
export { A as AiChatStatus, C as ClientContext, L as LiveblocksProvider, M as MutationContext, y as RoomContext, N as RoomProvider, S as SendAiMessageOptions, U as UseSendAiMessageOptions, x as UseThreadsOptions, B as createLiveblocksContext, K as createRoomContext, O as useAddReaction,
|
|
1
|
+
import { R as RegisterAiKnowledgeProps, w as RegisterAiToolProps } from './room-C3ujtNzt.js';
|
|
2
|
+
export { A as AiChatStatus, C as ClientContext, L as LiveblocksProvider, M as MutationContext, y as RoomContext, N as RoomProvider, S as SendAiMessageOptions, U as UseSendAiMessageOptions, x as UseThreadsOptions, B as createLiveblocksContext, K as createRoomContext, O as useAddReaction, aJ as useAiChat, aL as useAiChatMessages, aM as useAiChatStatus, aK as useAiChats, av as useAttachmentUrl, P as useBroadcastEvent, Q as useCanRedo, T as useCanUndo, z as useClient, aB as useCreateAiChat, V as useCreateComment, W as useCreateThread, aC as useDeleteAiChat, D as useDeleteAllInboxNotifications, X as useDeleteComment, E as useDeleteInboxNotification, Y as useDeleteThread, Z as useEditComment, a0 as useEditCommentMetadata, $ as useEditThreadMetadata, F as useErrorListener, a5 as useEventListener, aG as useGroupInfo, a6 as useHistory, am as useHistoryVersionData, aw as useHistoryVersions, _ as useInboxNotificationThread, ay as useInboxNotifications, a7 as useIsInsideRoom, a8 as useLostConnectionListener, H as useMarkAllInboxNotificationsAsRead, I as useMarkInboxNotificationAsRead, a9 as useMarkThreadAsRead, a1 as useMarkThreadAsResolved, a2 as useMarkThreadAsUnresolved, aa as useMutation, ab as useMyPresence, az as useNotificationSettings, an as useOther, ao as useOthers, ap as useOthersConnectionIds, ac as useOthersListener, aq as useOthersMapped, ad as useRedo, ae as useRemoveReaction, af as useRoom, aF as useRoomInfo, ax as useRoomSubscriptionSettings, au as useSearchComments, ar as useSelf, aD as useSendAiMessage, ag as useStatus, as as useStorage, ah as useStorageRoot, a3 as useSubscribeToThread, J as useSyncStatus, ai as useThreadSubscription, at as useThreads, aj as useUndo, aH as useUnreadInboxNotificationsCount, a4 as useUnsubscribeFromThread, ak as useUpdateMyPresence, aA as useUpdateNotificationSettings, al as useUpdateRoomSubscriptionSettings, aN as useUrlMetadata, aI as useUser, aE as useUserThreads_experimental } from './room-C3ujtNzt.js';
|
|
3
3
|
export { Json, JsonObject, isNotificationChannelEnabled, shallow } from '@liveblocks/client';
|
|
4
4
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
5
5
|
import * as react from 'react';
|
package/dist/index.js
CHANGED
|
@@ -3,13 +3,13 @@ import {
|
|
|
3
3
|
PKG_FORMAT,
|
|
4
4
|
PKG_NAME,
|
|
5
5
|
PKG_VERSION
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-XWDDGVZ4.js";
|
|
7
7
|
import {
|
|
8
8
|
ClientContext,
|
|
9
|
+
GlobalRoomContext,
|
|
9
10
|
LiveblocksProvider,
|
|
10
11
|
RegisterAiKnowledge,
|
|
11
12
|
RegisterAiTool,
|
|
12
|
-
RoomContext,
|
|
13
13
|
_RoomProvider,
|
|
14
14
|
_useAddReaction,
|
|
15
15
|
_useAiChat,
|
|
@@ -23,8 +23,6 @@ import {
|
|
|
23
23
|
_useEditCommentMetadata,
|
|
24
24
|
_useEditThreadMetadata,
|
|
25
25
|
_useEventListener,
|
|
26
|
-
_useFeedMessages,
|
|
27
|
-
_useFeeds,
|
|
28
26
|
_useHistoryVersions,
|
|
29
27
|
_useInboxNotificationThread,
|
|
30
28
|
_useIsInsideRoom,
|
|
@@ -53,13 +51,9 @@ import {
|
|
|
53
51
|
useCanUndo,
|
|
54
52
|
useClient,
|
|
55
53
|
useCreateAiChat,
|
|
56
|
-
useCreateFeed,
|
|
57
|
-
useCreateFeedMessage,
|
|
58
54
|
useDeleteAiChat,
|
|
59
55
|
useDeleteAllInboxNotifications,
|
|
60
56
|
useDeleteComment,
|
|
61
|
-
useDeleteFeed,
|
|
62
|
-
useDeleteFeedMessage,
|
|
63
57
|
useDeleteInboxNotification,
|
|
64
58
|
useErrorListener,
|
|
65
59
|
useGroupInfo,
|
|
@@ -85,11 +79,9 @@ import {
|
|
|
85
79
|
useUndo,
|
|
86
80
|
useUnreadInboxNotificationsCount,
|
|
87
81
|
useUnsubscribeFromThread,
|
|
88
|
-
useUpdateFeedMessage,
|
|
89
|
-
useUpdateFeedMetadata,
|
|
90
82
|
useUpdateNotificationSettings,
|
|
91
83
|
useUpdateRoomSubscriptionSettings
|
|
92
|
-
} from "./chunk-
|
|
84
|
+
} from "./chunk-7TVEKSIE.js";
|
|
93
85
|
|
|
94
86
|
// src/index.ts
|
|
95
87
|
import { detectDupes } from "@liveblocks/core";
|
|
@@ -101,7 +93,7 @@ export {
|
|
|
101
93
|
LiveblocksProvider,
|
|
102
94
|
RegisterAiKnowledge,
|
|
103
95
|
RegisterAiTool,
|
|
104
|
-
RoomContext,
|
|
96
|
+
GlobalRoomContext as RoomContext,
|
|
105
97
|
_RoomProvider as RoomProvider,
|
|
106
98
|
createLiveblocksContext,
|
|
107
99
|
createRoomContext,
|
|
@@ -119,14 +111,10 @@ export {
|
|
|
119
111
|
useClient,
|
|
120
112
|
useCreateAiChat,
|
|
121
113
|
_useCreateComment as useCreateComment,
|
|
122
|
-
useCreateFeed,
|
|
123
|
-
useCreateFeedMessage,
|
|
124
114
|
_useCreateThread as useCreateThread,
|
|
125
115
|
useDeleteAiChat,
|
|
126
116
|
useDeleteAllInboxNotifications,
|
|
127
117
|
useDeleteComment,
|
|
128
|
-
useDeleteFeed,
|
|
129
|
-
useDeleteFeedMessage,
|
|
130
118
|
useDeleteInboxNotification,
|
|
131
119
|
_useDeleteThread as useDeleteThread,
|
|
132
120
|
_useEditComment as useEditComment,
|
|
@@ -134,8 +122,6 @@ export {
|
|
|
134
122
|
_useEditThreadMetadata as useEditThreadMetadata,
|
|
135
123
|
useErrorListener,
|
|
136
124
|
_useEventListener as useEventListener,
|
|
137
|
-
_useFeedMessages as useFeedMessages,
|
|
138
|
-
_useFeeds as useFeeds,
|
|
139
125
|
useGroupInfo,
|
|
140
126
|
useHistory,
|
|
141
127
|
useHistoryVersionData,
|
|
@@ -175,8 +161,6 @@ export {
|
|
|
175
161
|
useUndo,
|
|
176
162
|
useUnreadInboxNotificationsCount,
|
|
177
163
|
useUnsubscribeFromThread,
|
|
178
|
-
useUpdateFeedMessage,
|
|
179
|
-
useUpdateFeedMetadata,
|
|
180
164
|
_useUpdateMyPresence as useUpdateMyPresence,
|
|
181
165
|
useUpdateNotificationSettings,
|
|
182
166
|
useUpdateRoomSubscriptionSettings,
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/index.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 UseSendAiMessageOptions,\n UseThreadsOptions,\n SendAiMessageOptions,\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 { RegisterAiKnowledge, RegisterAiTool } from \"./ai\";\nexport type {\n AiChatStatus,\n RegisterAiKnowledgeProps,\n RegisterAiToolProps,\n} from \"./types/ai\";\nexport {
|
|
1
|
+
{"version":3,"sources":["../src/index.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 UseSendAiMessageOptions,\n UseThreadsOptions,\n SendAiMessageOptions,\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 { RegisterAiKnowledge, RegisterAiTool } from \"./ai\";\nexport type {\n AiChatStatus,\n RegisterAiKnowledgeProps,\n RegisterAiToolProps,\n} from \"./types/ai\";\nexport {\n ClientContext,\n GlobalRoomContext as RoomContext,\n useClient,\n} from \"./contexts\";\nexport {\n createLiveblocksContext,\n LiveblocksProvider,\n useDeleteAllInboxNotifications,\n useDeleteInboxNotification,\n useErrorListener,\n useInboxNotificationThread,\n useMarkAllInboxNotificationsAsRead,\n useMarkInboxNotificationAsRead,\n useSyncStatus,\n} from \"./liveblocks\";\nexport {\n createRoomContext,\n RoomProvider,\n useAddReaction,\n useBroadcastEvent,\n useCanRedo,\n useCanUndo,\n useCreateComment,\n useCreateThread,\n useDeleteComment,\n useDeleteThread,\n useEditComment,\n useEditThreadMetadata,\n useEditCommentMetadata,\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 useUpdateRoomSubscriptionSettings,\n useHistoryVersionData,\n} from \"./room\";\n\n// Export the classic (non-Suspense) versions of our hooks\n// (This part differs from src/suspense.ts)\nexport {\n useOther,\n useOthers,\n useOthersConnectionIds,\n useOthersMapped,\n useSelf,\n useStorage,\n useThreads,\n useSearchComments,\n useAttachmentUrl,\n useHistoryVersions,\n useRoomSubscriptionSettings,\n} from \"./room\";\nexport {\n useInboxNotifications,\n useNotificationSettings,\n useUpdateNotificationSettings,\n useCreateAiChat,\n useDeleteAiChat,\n useSendAiMessage,\n useUserThreads_experimental as useUserThreads_experimental,\n useRoomInfo,\n useGroupInfo,\n useUnreadInboxNotificationsCount,\n useUser,\n useAiChat,\n useAiChats,\n useAiChatMessages,\n useAiChatStatus,\n useUrlMetadata,\n} from \"./liveblocks\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,SAAS,mBAAmB;AAe5B,SAAS,SAAS,oCAAoC;AAZtD,YAAY,UAAU,aAAa,UAAU;","names":[]}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import * as react from 'react';
|
|
2
|
-
import { ComponentType, Context, PropsWithChildren, ReactNode } from 'react';
|
|
3
1
|
import { BaseUserMeta, Client, JsonObject, LsonObject, LiveObject, User, Json, RoomSubscriptionSettings, Room, Status, BroadcastOptions, OthersEvent, LostConnectionEvent, History, BaseMetadata as BaseMetadata$1, ClientOptions, ThreadData as ThreadData$1, CommentData as CommentData$1 } from '@liveblocks/client';
|
|
4
2
|
import * as _liveblocks_core from '@liveblocks/core';
|
|
5
|
-
import { OpaqueClient, OpaqueRoom, AiKnowledgeSource, AiOpaqueToolDefinition, Relax, AiAssistantContentPart, BaseMetadata, QueryMetadata, AsyncResult, DRI, AsyncSuccess, DGI, GroupData, Resolve, CommentBody, CommentAttachment, PartialUnless, Patchable, InboxNotificationData, NotificationSettings, ToImmutable, MessageId, PartialNotificationSettings, AiChatsQuery, AsyncLoading, AsyncError, ThreadData, SearchCommentsResult,
|
|
3
|
+
import { OpaqueClient, OpaqueRoom, AiKnowledgeSource, AiOpaqueToolDefinition, Relax, AiAssistantContentPart, BaseMetadata, QueryMetadata, AsyncResult, DRI, AsyncSuccess, DGI, GroupData, Resolve, CommentBody, CommentAttachment, PartialUnless, Patchable, InboxNotificationData, NotificationSettings, ToImmutable, MessageId, PartialNotificationSettings, AiChatsQuery, AsyncLoading, AsyncError, ThreadData, SearchCommentsResult, HistoryVersion, AiChat, UrlMetadata, Client as Client$1, LiveblocksError, SyncStatus, RoomEventMessage, CommentData, AiUserMessage, WithRequired, AiChatMessage, WithNavigation, MutableSignal, ThreadDataWithDeleteInfo, ThreadDeleteInfo, SubscriptionKey, SubscriptionData, DerivedSignal, DefaultMap, CommentUserReaction, InboxNotificationDeleteInfo, SubscriptionDeleteInfo, RoomSubscriptionSettings as RoomSubscriptionSettings$1, ISignal, Permission, BaseUserMeta as BaseUserMeta$1, DistributiveOmit, DU, DTM, DCM, TextEditorType, IYjsProvider, MentionData, DP, DS, DE } from '@liveblocks/core';
|
|
4
|
+
import { Context, ComponentType, PropsWithChildren, ReactNode } from 'react';
|
|
6
5
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
7
6
|
|
|
8
7
|
/**
|
|
@@ -11,7 +10,7 @@ import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
|
11
10
|
*
|
|
12
11
|
* @private This is a private/advanced API. Do not rely on it.
|
|
13
12
|
*/
|
|
14
|
-
declare const ClientContext:
|
|
13
|
+
declare const ClientContext: Context<OpaqueClient | null>;
|
|
15
14
|
/**
|
|
16
15
|
* @private This is an internal API.
|
|
17
16
|
*/
|
|
@@ -25,8 +24,11 @@ declare function useClient<U extends BaseUserMeta>(): Client<U>;
|
|
|
25
24
|
* room. Exposed for advanced use cases only.
|
|
26
25
|
*
|
|
27
26
|
* @private This is a private/advanced API. Do not rely on it.
|
|
27
|
+
*
|
|
28
|
+
* This context is exported publicly as `import { RoomContext } from "@liveblocks/react"`,
|
|
29
|
+
* not `GlobalRoomContext`.
|
|
28
30
|
*/
|
|
29
|
-
declare const
|
|
31
|
+
declare const GlobalRoomContext: Context<OpaqueRoom | null>;
|
|
30
32
|
|
|
31
33
|
type RegisterAiKnowledgeProps = AiKnowledgeSource & {
|
|
32
34
|
/**
|
|
@@ -206,26 +208,6 @@ type UseInboxNotificationsOptions = {
|
|
|
206
208
|
*/
|
|
207
209
|
query?: InboxNotificationsQuery;
|
|
208
210
|
};
|
|
209
|
-
type UseFeedsOptions = {
|
|
210
|
-
/**
|
|
211
|
-
* Optional timestamp filter. Only feeds created or updated after this timestamp will be returned.
|
|
212
|
-
*/
|
|
213
|
-
since?: number;
|
|
214
|
-
/**
|
|
215
|
-
* Optional metadata filter. Only feeds with matching metadata will be returned.
|
|
216
|
-
*/
|
|
217
|
-
metadata?: Record<string, Json>;
|
|
218
|
-
};
|
|
219
|
-
type UseFeedMessagesOptions = {
|
|
220
|
-
/**
|
|
221
|
-
* Optional cursor for pagination.
|
|
222
|
-
*/
|
|
223
|
-
cursor?: string;
|
|
224
|
-
/**
|
|
225
|
-
* Optional limit for the number of messages to fetch.
|
|
226
|
-
*/
|
|
227
|
-
limit?: number;
|
|
228
|
-
};
|
|
229
211
|
type UserAsyncResult<T> = AsyncResult<T, "user">;
|
|
230
212
|
type UserAsyncSuccess<T> = AsyncSuccess<T, "user">;
|
|
231
213
|
type RoomInfoAsyncResult = AsyncResult<DRI, "info">;
|
|
@@ -288,10 +270,6 @@ type ThreadsAsyncResult<TM extends BaseMetadata, CM extends BaseMetadata> = Page
|
|
|
288
270
|
type SearchCommentsAsyncResult = AsyncResult<Array<SearchCommentsResult>, "results">;
|
|
289
271
|
type InboxNotificationsAsyncSuccess = PagedAsyncSuccess<InboxNotificationData[], "inboxNotifications">;
|
|
290
272
|
type InboxNotificationsAsyncResult = PagedAsyncResult<InboxNotificationData[], "inboxNotifications">;
|
|
291
|
-
type FeedsAsyncSuccess<FM extends Json = Json> = PagedAsyncSuccess<Feed<FM>[], "feeds">;
|
|
292
|
-
type FeedsAsyncResult<FM extends Json = Json> = PagedAsyncResult<Feed<FM>[], "feeds">;
|
|
293
|
-
type FeedMessagesAsyncSuccess<FMD extends Json = Json> = PagedAsyncSuccess<FeedMessage<FMD>[], "messages">;
|
|
294
|
-
type FeedMessagesAsyncResult<FMD extends Json = Json> = PagedAsyncResult<FeedMessage<FMD>[], "messages">;
|
|
295
273
|
type UnreadInboxNotificationsCountAsyncSuccess = AsyncSuccess<number, "count">;
|
|
296
274
|
type UnreadInboxNotificationsCountAsyncResult = AsyncResult<number, "count">;
|
|
297
275
|
type NotificationSettingsAsyncResult = AsyncResult<NotificationSettings, "settings">;
|
|
@@ -527,13 +505,13 @@ type SharedContextBundle<U extends BaseUserMeta> = {
|
|
|
527
505
|
/**
|
|
528
506
|
* Properties that are the same in RoomContext and RoomContext["suspense"].
|
|
529
507
|
*/
|
|
530
|
-
type RoomContextBundleCommon<P extends JsonObject, S extends LsonObject, U extends BaseUserMeta, E extends Json, TM extends BaseMetadata, CM extends BaseMetadata
|
|
508
|
+
type RoomContextBundleCommon<P extends JsonObject, S extends LsonObject, U extends BaseUserMeta, E extends Json, TM extends BaseMetadata, CM extends BaseMetadata> = {
|
|
531
509
|
/**
|
|
532
510
|
* You normally don't need to directly interact with the RoomContext, but
|
|
533
511
|
* it can be necessary if you're building an advanced app where you need to
|
|
534
512
|
* set up a context bridge between two React renderers.
|
|
535
513
|
*/
|
|
536
|
-
RoomContext: Context<Room<P, S, U, E, TM, CM
|
|
514
|
+
RoomContext: Context<Room<P, S, U, E, TM, CM> | null>;
|
|
537
515
|
/**
|
|
538
516
|
* Makes a Room available in the component hierarchy below.
|
|
539
517
|
* Joins the room when the component is mounted, and automatically leaves
|
|
@@ -546,10 +524,10 @@ type RoomContextBundleCommon<P extends JsonObject, S extends LsonObject, U exten
|
|
|
546
524
|
*/
|
|
547
525
|
useRoom(options?: {
|
|
548
526
|
allowOutsideRoom: false;
|
|
549
|
-
}): Room<P, S, U, E, TM, CM
|
|
527
|
+
}): Room<P, S, U, E, TM, CM>;
|
|
550
528
|
useRoom(options: {
|
|
551
529
|
allowOutsideRoom: boolean;
|
|
552
|
-
}): Room<P, S, U, E, TM, CM
|
|
530
|
+
}): Room<P, S, U, E, TM, CM> | null;
|
|
553
531
|
/**
|
|
554
532
|
* Returns the current connection status for the Room, and triggers
|
|
555
533
|
* a re-render whenever it changes. Can be used to render a status badge.
|
|
@@ -947,7 +925,7 @@ type RoomContextBundleCommon<P extends JsonObject, S extends LsonObject, U exten
|
|
|
947
925
|
*/
|
|
948
926
|
useThreadSubscription(threadId: string): ThreadSubscription;
|
|
949
927
|
};
|
|
950
|
-
type RoomContextBundle<P extends JsonObject, S extends LsonObject, U extends BaseUserMeta, E extends Json, TM extends BaseMetadata, CM extends BaseMetadata
|
|
928
|
+
type RoomContextBundle<P extends JsonObject, S extends LsonObject, U extends BaseUserMeta, E extends Json, TM extends BaseMetadata, CM extends BaseMetadata> = Resolve<RoomContextBundleCommon<P, S, U, E, TM, CM> & SharedContextBundle<U>["classic"] & {
|
|
951
929
|
/**
|
|
952
930
|
* Extract arbitrary data from the Liveblocks Storage state, using an
|
|
953
931
|
* arbitrary selector function.
|
|
@@ -1009,74 +987,6 @@ type RoomContextBundle<P extends JsonObject, S extends LsonObject, U extends Bas
|
|
|
1009
987
|
* const { threads, error, isLoading } = useThreads();
|
|
1010
988
|
*/
|
|
1011
989
|
useThreads(options?: UseThreadsOptions<TM>): ThreadsAsyncResult<TM, CM>;
|
|
1012
|
-
/**
|
|
1013
|
-
* Returns feeds for the current room.
|
|
1014
|
-
*
|
|
1015
|
-
* @example
|
|
1016
|
-
* const { feeds, error, isLoading } = useFeeds();
|
|
1017
|
-
*/
|
|
1018
|
-
useFeeds(options?: UseFeedsOptions): FeedsAsyncResult<SM>;
|
|
1019
|
-
/**
|
|
1020
|
-
* Returns messages for a specific feed in the current room.
|
|
1021
|
-
*
|
|
1022
|
-
* @example
|
|
1023
|
-
* const { messages, error, isLoading } = useFeedMessages("feed-id");
|
|
1024
|
-
*/
|
|
1025
|
-
useFeedMessages(feedId: string, options?: UseFeedMessagesOptions): FeedMessagesAsyncResult<MD>;
|
|
1026
|
-
/**
|
|
1027
|
-
* Returns a function that creates a new feed in the current room.
|
|
1028
|
-
*
|
|
1029
|
-
* @example
|
|
1030
|
-
* const createFeed = useCreateFeed();
|
|
1031
|
-
* createFeed("feed-id", { metadata: { name: "My Feed" } });
|
|
1032
|
-
*/
|
|
1033
|
-
useCreateFeed(): (feedId: string, options?: {
|
|
1034
|
-
metadata?: JsonObject;
|
|
1035
|
-
timestamp?: number;
|
|
1036
|
-
}) => void;
|
|
1037
|
-
/**
|
|
1038
|
-
* Returns a function that deletes a feed from the current room.
|
|
1039
|
-
*
|
|
1040
|
-
* @example
|
|
1041
|
-
* const deleteFeed = useDeleteFeed();
|
|
1042
|
-
* deleteFeed("feed-id");
|
|
1043
|
-
*/
|
|
1044
|
-
useDeleteFeed(): (feedId: string) => void;
|
|
1045
|
-
/**
|
|
1046
|
-
* Returns a function that updates a feed's metadata in the current room.
|
|
1047
|
-
*
|
|
1048
|
-
* @example
|
|
1049
|
-
* const updateFeedMetadata = useUpdateFeedMetadata();
|
|
1050
|
-
* updateFeedMetadata("feed-id", { name: "Updated Name" });
|
|
1051
|
-
*/
|
|
1052
|
-
useUpdateFeedMetadata(): (feedId: string, metadata: JsonObject) => void;
|
|
1053
|
-
/**
|
|
1054
|
-
* Returns a function that adds a message to a feed in the current room.
|
|
1055
|
-
*
|
|
1056
|
-
* @example
|
|
1057
|
-
* const createFeedMessage = useCreateFeedMessage();
|
|
1058
|
-
* createFeedMessage("feed-id", { text: "Hello" });
|
|
1059
|
-
*/
|
|
1060
|
-
useCreateFeedMessage(): (feedId: string, data: JsonObject, options?: {
|
|
1061
|
-
id?: string;
|
|
1062
|
-
timestamp?: number;
|
|
1063
|
-
}) => void;
|
|
1064
|
-
/**
|
|
1065
|
-
* Returns a function that deletes a message from a feed in the current room.
|
|
1066
|
-
*
|
|
1067
|
-
* @example
|
|
1068
|
-
* const deleteFeedMessage = useDeleteFeedMessage();
|
|
1069
|
-
* deleteFeedMessage("feed-id", "message-id");
|
|
1070
|
-
*/
|
|
1071
|
-
useDeleteFeedMessage(): (feedId: string, messageId: string) => void;
|
|
1072
|
-
/**
|
|
1073
|
-
* Returns a function that updates a feed message in the current room.
|
|
1074
|
-
*
|
|
1075
|
-
* @example
|
|
1076
|
-
* const updateFeedMessage = useUpdateFeedMessage();
|
|
1077
|
-
* updateFeedMessage("feed-id", "message-id", { text: "Updated" });
|
|
1078
|
-
*/
|
|
1079
|
-
useUpdateFeedMessage(): (feedId: string, messageId: string, data: JsonObject) => void;
|
|
1080
990
|
/**
|
|
1081
991
|
* Returns the result of searching comments by text in the current room. The result includes the id and the plain text content of the matched comments along with the parent thread id of the comment.
|
|
1082
992
|
*
|
|
@@ -1116,7 +1026,7 @@ type RoomContextBundle<P extends JsonObject, S extends LsonObject, U extends Bas
|
|
|
1116
1026
|
* const { data, error, isLoading } = useHistoryVersionData(version.id);
|
|
1117
1027
|
*/
|
|
1118
1028
|
useHistoryVersionData(id: string): HistoryVersionDataAsyncResult;
|
|
1119
|
-
suspense: Resolve<RoomContextBundleCommon<P, S, U, E, TM, CM
|
|
1029
|
+
suspense: Resolve<RoomContextBundleCommon<P, S, U, E, TM, CM> & SharedContextBundle<U>["suspense"] & {
|
|
1120
1030
|
/**
|
|
1121
1031
|
* Extract arbitrary data from the Liveblocks Storage state, using an
|
|
1122
1032
|
* arbitrary selector function.
|
|
@@ -1172,32 +1082,6 @@ type RoomContextBundle<P extends JsonObject, S extends LsonObject, U extends Bas
|
|
|
1172
1082
|
* const { threads } = useThreads();
|
|
1173
1083
|
*/
|
|
1174
1084
|
useThreads(options?: UseThreadsOptions<TM>): ThreadsAsyncSuccess<TM, CM>;
|
|
1175
|
-
/**
|
|
1176
|
-
* Returns feeds for the current room.
|
|
1177
|
-
*
|
|
1178
|
-
* @example
|
|
1179
|
-
* const { feeds } = useFeeds();
|
|
1180
|
-
*/
|
|
1181
|
-
useFeeds(options?: UseFeedsOptions): FeedsAsyncSuccess<SM>;
|
|
1182
|
-
/**
|
|
1183
|
-
* Returns messages for a specific feed in the current room.
|
|
1184
|
-
*
|
|
1185
|
-
* @example
|
|
1186
|
-
* const { messages } = useFeedMessages("feed-id");
|
|
1187
|
-
*/
|
|
1188
|
-
useFeedMessages(feedId: string, options?: UseFeedMessagesOptions): FeedMessagesAsyncSuccess<MD>;
|
|
1189
|
-
useCreateFeed(): (feedId: string, options?: {
|
|
1190
|
-
metadata?: JsonObject;
|
|
1191
|
-
timestamp?: number;
|
|
1192
|
-
}) => void;
|
|
1193
|
-
useDeleteFeed(): (feedId: string) => void;
|
|
1194
|
-
useUpdateFeedMetadata(): (feedId: string, metadata: JsonObject) => void;
|
|
1195
|
-
useCreateFeedMessage(): (feedId: string, data: JsonObject, options?: {
|
|
1196
|
-
id?: string;
|
|
1197
|
-
timestamp?: number;
|
|
1198
|
-
}) => void;
|
|
1199
|
-
useDeleteFeedMessage(): (feedId: string, messageId: string) => void;
|
|
1200
|
-
useUpdateFeedMessage(): (feedId: string, messageId: string, data: JsonObject) => void;
|
|
1201
1085
|
/**
|
|
1202
1086
|
* (Private beta) Returns a history of versions of the current room.
|
|
1203
1087
|
*
|
|
@@ -1905,8 +1789,6 @@ declare class UmbrellaStore<TM extends BaseMetadata, CM extends BaseMetadata> {
|
|
|
1905
1789
|
readonly messagesByChatId: DefaultMap<string, DefaultMap<MessageId | null, LoadableResource<AiChatMessagesAsyncResult>>>;
|
|
1906
1790
|
readonly aiChatById: DefaultMap<string, LoadableResource<AiChatAsyncResult>>;
|
|
1907
1791
|
readonly urlMetadataByUrl: DefaultMap<string, LoadableResource<UrlMetadataAsyncResult>>;
|
|
1908
|
-
readonly loadingFeeds: DefaultMap<string, LoadableResource<FeedsAsyncResult>>;
|
|
1909
|
-
readonly loadingFeedMessages: DefaultMap<string, LoadableResource<FeedMessagesAsyncResult>>;
|
|
1910
1792
|
};
|
|
1911
1793
|
constructor(client: OpaqueClient);
|
|
1912
1794
|
/**
|
|
@@ -1971,22 +1853,6 @@ declare class UmbrellaStore<TM extends BaseMetadata, CM extends BaseMetadata> {
|
|
|
1971
1853
|
*/
|
|
1972
1854
|
updateRoomSubscriptionSettings(roomId: string, optimisticId: string, settings: Readonly<RoomSubscriptionSettings$1>): void;
|
|
1973
1855
|
fetchNotificationsDeltaUpdate(signal: AbortSignal): Promise<void>;
|
|
1974
|
-
/**
|
|
1975
|
-
* Upserts feeds in the cache (for list/added/updated operations).
|
|
1976
|
-
*/
|
|
1977
|
-
upsertFeeds(roomId: RoomId, feeds: readonly Feed[]): void;
|
|
1978
|
-
/**
|
|
1979
|
-
* Removes feeds from the cache (for deleted operations).
|
|
1980
|
-
*/
|
|
1981
|
-
deleteFeeds(roomId: RoomId, feeds: readonly Feed[]): void;
|
|
1982
|
-
/**
|
|
1983
|
-
* Upserts feed messages in the cache (for list/added/updated operations).
|
|
1984
|
-
*/
|
|
1985
|
-
upsertFeedMessages(_roomId: RoomId, feedId: string, messages: readonly FeedMessage[]): void;
|
|
1986
|
-
/**
|
|
1987
|
-
* Removes feed messages from the cache (for deleted operations).
|
|
1988
|
-
*/
|
|
1989
|
-
deleteFeedMessages(_roomId: RoomId, feedId: string, messages: readonly FeedMessage[]): void;
|
|
1990
1856
|
fetchUnreadNotificationsCount(queryKey: InboxNotificationsQueryKey, signal: AbortSignal): Promise<void>;
|
|
1991
1857
|
fetchRoomThreadsDeltaUpdate(roomId: string, signal: AbortSignal): Promise<void>;
|
|
1992
1858
|
fetchUserThreadsDeltaUpdate(signal: AbortSignal): Promise<void>;
|
|
@@ -2454,18 +2320,6 @@ declare function useCanRedo(): boolean;
|
|
|
2454
2320
|
* // [2, 4, 7]
|
|
2455
2321
|
*/
|
|
2456
2322
|
declare function useOthersConnectionIds(): readonly number[];
|
|
2457
|
-
declare function useCreateFeed(): (feedId: string, options?: {
|
|
2458
|
-
metadata?: JsonObject;
|
|
2459
|
-
timestamp?: number;
|
|
2460
|
-
}) => void;
|
|
2461
|
-
declare function useDeleteFeed(): (feedId: string) => void;
|
|
2462
|
-
declare function useUpdateFeedMetadata(): (feedId: string, metadata: JsonObject) => void;
|
|
2463
|
-
declare function useCreateFeedMessage(): (feedId: string, data: JsonObject, options?: {
|
|
2464
|
-
id?: string;
|
|
2465
|
-
timestamp?: number;
|
|
2466
|
-
}) => void;
|
|
2467
|
-
declare function useDeleteFeedMessage(): (feedId: string, messageId: string) => void;
|
|
2468
|
-
declare function useUpdateFeedMessage(): (feedId: string, messageId: string, data: JsonObject) => void;
|
|
2469
2323
|
/**
|
|
2470
2324
|
* @private
|
|
2471
2325
|
*/
|
|
@@ -2509,6 +2363,10 @@ declare function useRemoveReaction(): ({ threadId, commentId, emoji }: CommentRe
|
|
|
2509
2363
|
* @private
|
|
2510
2364
|
*/
|
|
2511
2365
|
declare function useRemoveRoomCommentReaction(roomId: string): ({ threadId, commentId, emoji }: CommentReactionOptions) => void;
|
|
2366
|
+
/**
|
|
2367
|
+
* @private
|
|
2368
|
+
*/
|
|
2369
|
+
declare function useMarkRoomThreadAsRead(roomId: string): (threadId: string) => void;
|
|
2512
2370
|
/**
|
|
2513
2371
|
* Returns a function that marks a thread as read.
|
|
2514
2372
|
*
|
|
@@ -2517,10 +2375,6 @@ declare function useRemoveRoomCommentReaction(roomId: string): ({ threadId, comm
|
|
|
2517
2375
|
* markThreadAsRead("th_xxx");
|
|
2518
2376
|
*/
|
|
2519
2377
|
declare function useMarkThreadAsRead(): (threadId: string) => void;
|
|
2520
|
-
/**
|
|
2521
|
-
* @private
|
|
2522
|
-
*/
|
|
2523
|
-
declare function useMarkRoomThreadAsRead(roomId: string): (threadId: string) => void;
|
|
2524
2378
|
/**
|
|
2525
2379
|
* Returns a function that marks a thread as resolved.
|
|
2526
2380
|
*
|
|
@@ -2635,8 +2489,8 @@ declare function useRoomPermissions(roomId: string): Set<_liveblocks_core.Permis
|
|
|
2635
2489
|
* that any RoomProvider created in this way does not need to be nested in
|
|
2636
2490
|
* LiveblocksProvider, as it already has access to the client.
|
|
2637
2491
|
*/
|
|
2638
|
-
declare function createRoomContext<P extends JsonObject = DP, S extends LsonObject = DS, U extends BaseUserMeta = DU, E extends Json = DE, TM extends BaseMetadata$1 = DTM, CM extends BaseMetadata$1 = DCM
|
|
2639
|
-
type TypedBundle = RoomContextBundle<DP, DS, DU, DE, DTM, DCM
|
|
2492
|
+
declare function createRoomContext<P extends JsonObject = DP, S extends LsonObject = DS, U extends BaseUserMeta = DU, E extends Json = DE, TM extends BaseMetadata$1 = DTM, CM extends BaseMetadata$1 = DCM>(client: OpaqueClient): RoomContextBundle<P, S, U, E, TM, CM>;
|
|
2493
|
+
type TypedBundle = RoomContextBundle<DP, DS, DU, DE, DTM, DCM>;
|
|
2640
2494
|
/**
|
|
2641
2495
|
* Makes a Room available in the component hierarchy below.
|
|
2642
2496
|
* Joins the room when the component is mounted, and automatically leaves
|
|
@@ -2867,22 +2721,6 @@ declare const _useOthersMappedSuspense: TypedBundle["suspense"]["useOthersMapped
|
|
|
2867
2721
|
* const { threads, error, isLoading } = useThreads();
|
|
2868
2722
|
*/
|
|
2869
2723
|
declare const _useThreads: TypedBundle["useThreads"];
|
|
2870
|
-
/**
|
|
2871
|
-
* Returns feeds for the current room.
|
|
2872
|
-
*
|
|
2873
|
-
* @example
|
|
2874
|
-
* const { feeds, error, isLoading } = useFeeds();
|
|
2875
|
-
*/
|
|
2876
|
-
declare const _useFeeds: TypedBundle["useFeeds"];
|
|
2877
|
-
/**
|
|
2878
|
-
* Returns messages for a specific feed in the current room.
|
|
2879
|
-
*
|
|
2880
|
-
* @example
|
|
2881
|
-
* const { messages, error, isLoading } = useFeedMessages("feed-id");
|
|
2882
|
-
*/
|
|
2883
|
-
declare const _useFeedMessages: TypedBundle["useFeedMessages"];
|
|
2884
|
-
declare const _useFeedsSuspense: TypedBundle["suspense"]["useFeeds"];
|
|
2885
|
-
declare const _useFeedMessagesSuspense: TypedBundle["suspense"]["useFeedMessages"];
|
|
2886
2724
|
/**
|
|
2887
2725
|
* Returns the result of searching comments by text in the current room. The result includes the id and the plain text content of the matched comments along with the parent thread id of the comment.
|
|
2888
2726
|
*
|
|
@@ -3154,4 +2992,4 @@ declare const _useStorageRoot: TypedBundle["useStorageRoot"];
|
|
|
3154
2992
|
*/
|
|
3155
2993
|
declare const _useUpdateMyPresence: TypedBundle["useUpdateMyPresence"];
|
|
3156
2994
|
|
|
3157
|
-
export { _useEditThreadMetadata as $, type AiChatStatus as A, createLiveblocksContext as B, ClientContext as C, useDeleteAllInboxNotifications as D, useDeleteInboxNotification as E, useErrorListener as F, type GroupAsyncResult as G, useMarkAllInboxNotificationsAsRead as H, useMarkInboxNotificationAsRead as I, useSyncStatus as J, createRoomContext as K, LiveblocksProvider as L, type MutationContext as M, _RoomProvider as N, _useAddReaction as O, _useBroadcastEvent as P, useCanRedo as Q, type RegisterAiKnowledgeProps as R, type SendAiMessageOptions as S, useCanUndo as T, type UseSendAiMessageOptions as U, _useCreateComment as V, _useCreateThread as W, useDeleteComment as X, _useDeleteThread as Y, _useEditComment as Z, _useInboxNotificationThread as _, useAddRoomCommentReaction as a,
|
|
2995
|
+
export { _useEditThreadMetadata as $, type AiChatStatus as A, createLiveblocksContext as B, ClientContext as C, useDeleteAllInboxNotifications as D, useDeleteInboxNotification as E, useErrorListener as F, type GroupAsyncResult as G, useMarkAllInboxNotificationsAsRead as H, useMarkInboxNotificationAsRead as I, useSyncStatus as J, createRoomContext as K, LiveblocksProvider as L, type MutationContext as M, _RoomProvider as N, _useAddReaction as O, _useBroadcastEvent as P, useCanRedo as Q, type RegisterAiKnowledgeProps as R, type SendAiMessageOptions as S, useCanUndo as T, type UseSendAiMessageOptions as U, _useCreateComment as V, _useCreateThread as W, useDeleteComment as X, _useDeleteThread as Y, _useEditComment as Z, _useInboxNotificationThread as _, useAddRoomCommentReaction as a, useGroupInfoSuspense as a$, _useEditCommentMetadata as a0, useMarkThreadAsResolved as a1, useMarkThreadAsUnresolved as a2, useSubscribeToThread as a3, useUnsubscribeFromThread as a4, _useEventListener as a5, useHistory as a6, _useIsInsideRoom as a7, useLostConnectionListener as a8, useMarkThreadAsRead as a9, useUpdateNotificationSettings as aA, useCreateAiChat as aB, useDeleteAiChat as aC, useSendAiMessage as aD, _useUserThreads_experimental as aE, useRoomInfo as aF, useGroupInfo as aG, useUnreadInboxNotificationsCount as aH, _useUser as aI, _useAiChat as aJ, _useAiChats as aK, _useAiChatMessages as aL, useAiChatStatus as aM, _useUrlMetadata as aN, _useOtherSuspense as aO, _useOthersSuspense as aP, useOthersConnectionIdsSuspense as aQ, _useOthersMappedSuspense as aR, _useSelfSuspense as aS, _useStorageSuspense as aT, _useThreadsSuspense as aU, useAttachmentUrlSuspense as aV, _useHistoryVersionsSuspense as aW, _useRoomSubscriptionSettingsSuspense as aX, useInboxNotificationsSuspense as aY, useNotificationSettingsSuspense as aZ, useRoomInfoSuspense as a_, _useMutation as aa, _useMyPresence as ab, _useOthersListener as ac, useRedo as ad, useRemoveReaction as ae, _useRoom as af, useStatus as ag, _useStorageRoot as ah, useThreadSubscription as ai, useUndo as aj, _useUpdateMyPresence as ak, useUpdateRoomSubscriptionSettings as al, useHistoryVersionData as am, _useOther as an, _useOthers as ao, useOthersConnectionIds as ap, _useOthersMapped as aq, _useSelf as ar, _useStorage as as, _useThreads as at, _useSearchComments as au, useAttachmentUrl as av, _useHistoryVersions as aw, _useRoomSubscriptionSettings as ax, useInboxNotifications as ay, useNotificationSettings as az, useCreateRoomComment as b, useUnreadInboxNotificationsCountSuspense as b0, _useUserSuspense as b1, _useUserThreadsSuspense_experimental as b2, _useAiChatsSuspense as b3, _useAiChatMessagesSuspense as b4, _useAiChatSuspense as b5, _useUrlMetadataSuspense as b6, 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 RegisterAiToolProps as w, type UseThreadsOptions as x, GlobalRoomContext as y, useClient as z };
|