@veltdev/react 1.0.140 → 1.0.141
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/cjs/index.js +22 -5
- package/cjs/index.js.map +1 -1
- package/cjs/types/constants.d.ts +1 -1
- package/cjs/types/hooks/LiveStateSyncElement.d.ts +8 -3
- package/cjs/types/hooks/index.d.ts +1 -1
- package/esm/index.js +22 -6
- package/esm/index.js.map +1 -1
- package/esm/types/constants.d.ts +1 -1
- package/esm/types/hooks/LiveStateSyncElement.d.ts +8 -3
- package/esm/types/hooks/index.d.ts +1 -1
- package/index.d.ts +8 -4
- package/package.json +1 -1
package/esm/types/constants.d.ts
CHANGED
|
@@ -1,6 +1,9 @@
|
|
|
1
|
-
import { EditorAccessTimer, LiveStateSyncElement, User, UserEditorAccess } from "@veltdev/types";
|
|
1
|
+
import { EditorAccessTimer, LiveStateSyncElement, ServerConnectionState, User, UserEditorAccess } from "@veltdev/types";
|
|
2
|
+
declare class LiveStateDataConfig {
|
|
3
|
+
listenToNewChangesOnly?: boolean;
|
|
4
|
+
}
|
|
2
5
|
export declare function useLiveStateSyncUtils(): LiveStateSyncElement | undefined;
|
|
3
|
-
export declare function useLiveStateData(liveStateDataId?: string,
|
|
6
|
+
export declare function useLiveStateData(liveStateDataId?: string, liveStateDataConfig?: LiveStateDataConfig): any;
|
|
4
7
|
export declare function useSetLiveStateData(liveStateDataId: string, liveStateData: any): any;
|
|
5
8
|
export declare function useUserEditorState(): UserEditorAccess | null;
|
|
6
9
|
export declare function useEditor(): User | null;
|
|
@@ -9,8 +12,10 @@ export declare function useEditorAccessRequestHandler(): {
|
|
|
9
12
|
requestStatus: string;
|
|
10
13
|
requestedBy: User;
|
|
11
14
|
} | null;
|
|
15
|
+
export declare function useServerConnectionStateChangeHandler(): ServerConnectionState | undefined;
|
|
12
16
|
export declare function useLiveState<T>(liveStateDataId: string, initialValue?: any, options?: {
|
|
13
17
|
syncDuration?: number;
|
|
14
18
|
resetLiveState?: boolean;
|
|
15
19
|
listenToNewChangesOnly?: boolean;
|
|
16
|
-
}): [T, (value: T) => void];
|
|
20
|
+
}): [T, (value: T) => void, ServerConnectionState | undefined];
|
|
21
|
+
export {};
|
|
@@ -2,7 +2,7 @@ export { useSetLocation, useSetDocumentId, useUnsetDocumentId, useIdentify, useC
|
|
|
2
2
|
export { useCommentUtils, useCommentAnnotations, useCommentAddHandler, useCommentModeState, useCommentUpdateHandler, useCommentDialogSidebarClickHandler, useCommentSelectionChangeHandler, } from './CommentElement';
|
|
3
3
|
export { useCursorUtils, useCursorUsers, } from './CursorElement';
|
|
4
4
|
export { useHuddleUtils, } from './HuddleElement';
|
|
5
|
-
export { useLiveStateSyncUtils, useLiveStateData, useSetLiveStateData, useUserEditorState, useEditor, useEditorAccessTimer, useEditorAccessRequestHandler, useLiveState, } from './LiveStateSyncElement';
|
|
5
|
+
export { useLiveStateSyncUtils, useLiveStateData, useSetLiveStateData, useUserEditorState, useEditor, useEditorAccessTimer, useEditorAccessRequestHandler, useServerConnectionStateChangeHandler, useLiveState, } from './LiveStateSyncElement';
|
|
6
6
|
export { usePresenceUtils, usePresenceUsers, } from './PresenceElement';
|
|
7
7
|
export { useRecorderUtils, useRecorderAddHandler, } from './RecorderElement';
|
|
8
8
|
export { useAIRewriterUtils, } from './RewriterElement';
|
package/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { Config, Velt, ReactionMap, AutocompleteItem, User, Options, Location as Location$1, CommentElement, CommentAnnotation, CommentSelectionChangeData, CursorElement, CursorUser, LiveStateSyncElement, UserEditorAccess, EditorAccessTimer, PresenceElement, PresenceUser, RecorderElement, RewriterElement, SelectionElement, TagElement, TagAnnotation, ViewsElement, ViewsByUser, ViewsByDate, NotificationElement, Notification, AutocompleteElement, AutocompleteChipData } from '@veltdev/types';
|
|
3
|
+
import { Config, Velt, ReactionMap, AutocompleteItem, User, Options, Location as Location$1, CommentElement, CommentAnnotation, CommentSelectionChangeData, CursorElement, CursorUser, LiveStateSyncElement, UserEditorAccess, EditorAccessTimer, ServerConnectionState, PresenceElement, PresenceUser, RecorderElement, RewriterElement, SelectionElement, TagElement, TagAnnotation, ViewsElement, ViewsByUser, ViewsByDate, NotificationElement, Notification, AutocompleteElement, AutocompleteChipData } from '@veltdev/types';
|
|
4
4
|
|
|
5
5
|
interface IVeltProps extends React.DetailedHTMLProps<React.HTMLAttributes<HTMLElement>, HTMLElement> {
|
|
6
6
|
apiKey: string;
|
|
@@ -1381,8 +1381,11 @@ declare function useCursorUsers(): CursorUser[] | null;
|
|
|
1381
1381
|
|
|
1382
1382
|
declare function useHuddleUtils(): any | undefined;
|
|
1383
1383
|
|
|
1384
|
+
declare class LiveStateDataConfig {
|
|
1385
|
+
listenToNewChangesOnly?: boolean;
|
|
1386
|
+
}
|
|
1384
1387
|
declare function useLiveStateSyncUtils(): LiveStateSyncElement | undefined;
|
|
1385
|
-
declare function useLiveStateData(liveStateDataId?: string,
|
|
1388
|
+
declare function useLiveStateData(liveStateDataId?: string, liveStateDataConfig?: LiveStateDataConfig): any;
|
|
1386
1389
|
declare function useSetLiveStateData(liveStateDataId: string, liveStateData: any): any;
|
|
1387
1390
|
declare function useUserEditorState(): UserEditorAccess | null;
|
|
1388
1391
|
declare function useEditor(): User | null;
|
|
@@ -1391,11 +1394,12 @@ declare function useEditorAccessRequestHandler(): {
|
|
|
1391
1394
|
requestStatus: string;
|
|
1392
1395
|
requestedBy: User;
|
|
1393
1396
|
} | null;
|
|
1397
|
+
declare function useServerConnectionStateChangeHandler(): ServerConnectionState | undefined;
|
|
1394
1398
|
declare function useLiveState<T>(liveStateDataId: string, initialValue?: any, options?: {
|
|
1395
1399
|
syncDuration?: number;
|
|
1396
1400
|
resetLiveState?: boolean;
|
|
1397
1401
|
listenToNewChangesOnly?: boolean;
|
|
1398
|
-
}): [T, (value: T) => void];
|
|
1402
|
+
}): [T, (value: T) => void, ServerConnectionState | undefined];
|
|
1399
1403
|
|
|
1400
1404
|
declare function usePresenceUtils(): PresenceElement | undefined;
|
|
1401
1405
|
declare function usePresenceUsers(): PresenceUser[] | null;
|
|
@@ -1431,4 +1435,4 @@ declare const createLiveStateMiddleware: (config?: LiveStateMiddlewareConfig) =>
|
|
|
1431
1435
|
updateLiveStateDataId: (newId?: string) => void;
|
|
1432
1436
|
};
|
|
1433
1437
|
|
|
1434
|
-
export { SnippylyArrowTool as VeltArrowTool, SnippylyArrows as VeltArrows, VeltAutocomplete, VeltAutocompleteChipTooltipWireframe, VeltAutocompleteOptionWireframe, VeltChartComment, SnippylyCommentBubble as VeltCommentBubble, VeltCommentBubbleWireframe, VeltCommentDialogOptionsDropdownContentWireframe, VeltCommentDialogOptionsDropdownTriggerWireframe, VeltCommentDialogPriorityDropdownContentWireframe, VeltCommentDialogPriorityDropdownTriggerWireframe, VeltCommentDialogStatusDropdownContentWireframe, VeltCommentDialogStatusDropdownTriggerWireframe, VeltCommentDialogWireframe, VeltCommentPinWireframe, VeltCommentPlayerTimeline, VeltCommentThread, SnippylyCommentTool as VeltCommentTool, VeltCommentToolWireframe, SnippylyComments as VeltComments, SnippylyCommentsSidebar as VeltCommentsSidebar, VeltCommentsSidebarWireframe, SnippylyCursor as VeltCursor, VeltHighChartComments, SnippylyHuddle as VeltHuddle, SnippylyHuddleTool as VeltHuddleTool, VeltNivoChartComments, VeltNotificationsHistoryPanel, VeltNotificationsPanel, VeltNotificationsTool, SnippylyPresence as VeltPresence, SnippylyProvider as VeltProvider, VeltReactionPinTooltipWireframe, VeltReactionPinWireframe, VeltReactionToolWireframe, VeltReactionsPanelWireframe, SnippylyRecorderControlPanel as VeltRecorderControlPanel, SnippylyRecorderNotes as VeltRecorderNotes, SnippylyRecorderPlayer as VeltRecorderPlayer, SnippylyRecorderTool as VeltRecorderTool, SnippylySidebarButton as VeltSidebarButton, VeltSidebarButtonWireframe, SnippylyTagTool as VeltTagTool, SnippylyTags as VeltTags, VeltTextCommentToolWireframe, VeltTextCommentToolbar as VeltTextCommentToolbarWireframe, SnippylyUserInviteTool as VeltUserInviteTool, SnippylyUserRequestTool as VeltUserRequestTool, VeltUserSelectorDropdown as VeltUserSelectorDropdownWireframe, VeltVideoPlayer, VeltViewAnalytics, VeltWireframe, createLiveStateMiddleware, useAIRewriterUtils, useAutocompleteChipClick, useAutocompleteUtils, useClient, useCommentAddHandler, useCommentAnnotations, useCommentDialogSidebarClickHandler, useCommentModeState, useCommentSelectionChangeHandler, useCommentUpdateHandler, useCommentUtils, useCursorUsers, useCursorUtils, useEditor, useEditorAccessRequestHandler, useEditorAccessTimer, useHuddleUtils, useIdentify, useLiveSelectionUtils, useLiveState, useLiveStateData, useLiveStateSyncUtils, useNotificationUtils, useNotificationsData, usePresenceUsers, usePresenceUtils, useRecorderAddHandler, useRecorderUtils, useSetDocumentId, useSetLiveStateData, useSetLocation, useTagAnnotations, useTagUtils, useUniqueViewsByDate, useUniqueViewsByUser, useUnsetDocumentId, useUserEditorState, useVeltClient, useVeltInitState, useViewsUtils };
|
|
1438
|
+
export { SnippylyArrowTool as VeltArrowTool, SnippylyArrows as VeltArrows, VeltAutocomplete, VeltAutocompleteChipTooltipWireframe, VeltAutocompleteOptionWireframe, VeltChartComment, SnippylyCommentBubble as VeltCommentBubble, VeltCommentBubbleWireframe, VeltCommentDialogOptionsDropdownContentWireframe, VeltCommentDialogOptionsDropdownTriggerWireframe, VeltCommentDialogPriorityDropdownContentWireframe, VeltCommentDialogPriorityDropdownTriggerWireframe, VeltCommentDialogStatusDropdownContentWireframe, VeltCommentDialogStatusDropdownTriggerWireframe, VeltCommentDialogWireframe, VeltCommentPinWireframe, VeltCommentPlayerTimeline, VeltCommentThread, SnippylyCommentTool as VeltCommentTool, VeltCommentToolWireframe, SnippylyComments as VeltComments, SnippylyCommentsSidebar as VeltCommentsSidebar, VeltCommentsSidebarWireframe, SnippylyCursor as VeltCursor, VeltHighChartComments, SnippylyHuddle as VeltHuddle, SnippylyHuddleTool as VeltHuddleTool, VeltNivoChartComments, VeltNotificationsHistoryPanel, VeltNotificationsPanel, VeltNotificationsTool, SnippylyPresence as VeltPresence, SnippylyProvider as VeltProvider, VeltReactionPinTooltipWireframe, VeltReactionPinWireframe, VeltReactionToolWireframe, VeltReactionsPanelWireframe, SnippylyRecorderControlPanel as VeltRecorderControlPanel, SnippylyRecorderNotes as VeltRecorderNotes, SnippylyRecorderPlayer as VeltRecorderPlayer, SnippylyRecorderTool as VeltRecorderTool, SnippylySidebarButton as VeltSidebarButton, VeltSidebarButtonWireframe, SnippylyTagTool as VeltTagTool, SnippylyTags as VeltTags, VeltTextCommentToolWireframe, VeltTextCommentToolbar as VeltTextCommentToolbarWireframe, SnippylyUserInviteTool as VeltUserInviteTool, SnippylyUserRequestTool as VeltUserRequestTool, VeltUserSelectorDropdown as VeltUserSelectorDropdownWireframe, VeltVideoPlayer, VeltViewAnalytics, VeltWireframe, createLiveStateMiddleware, useAIRewriterUtils, useAutocompleteChipClick, useAutocompleteUtils, useClient, useCommentAddHandler, useCommentAnnotations, useCommentDialogSidebarClickHandler, useCommentModeState, useCommentSelectionChangeHandler, useCommentUpdateHandler, useCommentUtils, useCursorUsers, useCursorUtils, useEditor, useEditorAccessRequestHandler, useEditorAccessTimer, useHuddleUtils, useIdentify, useLiveSelectionUtils, useLiveState, useLiveStateData, useLiveStateSyncUtils, useNotificationUtils, useNotificationsData, usePresenceUsers, usePresenceUtils, useRecorderAddHandler, useRecorderUtils, useServerConnectionStateChangeHandler, useSetDocumentId, useSetLiveStateData, useSetLocation, useTagAnnotations, useTagUtils, useUniqueViewsByDate, useUniqueViewsByUser, useUnsetDocumentId, useUserEditorState, useVeltClient, useVeltInitState, useViewsUtils };
|