@veltdev/sdk 4.4.0 → 4.5.0-beta.10
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/app/models/data/comment-sidebar-config.model.d.ts +5 -0
- package/app/models/data/config.data.model.d.ts +4 -0
- package/app/models/data/live-state-events.data.model.d.ts +23 -0
- package/app/models/data/presence-actions.data.model.d.ts +5 -0
- package/app/models/data/presence-events.data.model.d.ts +16 -0
- package/app/models/data/presence-user.data.model.d.ts +2 -0
- package/app/models/data/recorder-annotation.data.model.d.ts +21 -0
- package/app/models/data/recorder-events.data.model.d.ts +13 -0
- package/app/models/data/recorder.model.d.ts +12 -0
- package/app/models/element/live-state-sync-element.model.d.ts +11 -0
- package/app/models/element/presence-element.model.d.ts +23 -0
- package/app/models/element/recorder-element.model.d.ts +32 -2
- package/app/utils/enums.d.ts +19 -1
- package/models.d.ts +3 -0
- package/package.json +1 -1
- package/velt.js +87 -87
|
@@ -10,6 +10,7 @@ declare class FilterTypeConfig {
|
|
|
10
10
|
}
|
|
11
11
|
export declare class CommentSidebarFilterConfig {
|
|
12
12
|
location?: FilterTypeConfig;
|
|
13
|
+
document?: FilterTypeConfig;
|
|
13
14
|
people?: FilterTypeConfig;
|
|
14
15
|
assigned?: FilterTypeConfig;
|
|
15
16
|
tagged?: FilterTypeConfig;
|
|
@@ -25,6 +26,10 @@ export declare class CommentSidebarGroupConfig {
|
|
|
25
26
|
}
|
|
26
27
|
export declare class CommentSidebarFilters {
|
|
27
28
|
location?: Location[];
|
|
29
|
+
document?: {
|
|
30
|
+
id?: string;
|
|
31
|
+
documentName?: string;
|
|
32
|
+
}[];
|
|
28
33
|
people?: {
|
|
29
34
|
userId?: string;
|
|
30
35
|
email?: string;
|
|
@@ -49,6 +49,10 @@ export declare class Config {
|
|
|
49
49
|
* Default: false
|
|
50
50
|
*/
|
|
51
51
|
advancedQueriesDisabled?: boolean;
|
|
52
|
+
/**
|
|
53
|
+
* The domain of the API proxy.
|
|
54
|
+
*/
|
|
55
|
+
apiProxyDomain?: string;
|
|
52
56
|
}
|
|
53
57
|
export interface ExtendedFirebaseOptions extends FirebaseOptions {
|
|
54
58
|
storeDbId: string;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { LiveStateSyncEventTypes } from "../../utils/enums";
|
|
2
|
+
import { User } from "./user.data.model";
|
|
3
|
+
export interface AccessRequestEvent {
|
|
4
|
+
viewer?: User;
|
|
5
|
+
editor?: User;
|
|
6
|
+
timestamp?: number;
|
|
7
|
+
status?: string;
|
|
8
|
+
}
|
|
9
|
+
export interface SEMEvent {
|
|
10
|
+
viewer?: User;
|
|
11
|
+
editor?: User;
|
|
12
|
+
timestamp?: number;
|
|
13
|
+
role?: string;
|
|
14
|
+
}
|
|
15
|
+
export type LiveStateEventTypesMap = {
|
|
16
|
+
[LiveStateSyncEventTypes.ACCESS_REQUESTED]: AccessRequestEvent;
|
|
17
|
+
[LiveStateSyncEventTypes.ACCESS_REQUEST_CANCELED]: AccessRequestEvent;
|
|
18
|
+
[LiveStateSyncEventTypes.ACCESS_ACCEPTED]: AccessRequestEvent;
|
|
19
|
+
[LiveStateSyncEventTypes.ACCESS_REJECTED]: AccessRequestEvent;
|
|
20
|
+
[LiveStateSyncEventTypes.EDITOR_ASSIGNED]: SEMEvent;
|
|
21
|
+
[LiveStateSyncEventTypes.VIEWER_ASSIGNED]: SEMEvent;
|
|
22
|
+
[LiveStateSyncEventTypes.EDITOR_ON_DIFFERENT_TAB_DETECTED]: SEMEvent;
|
|
23
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { PresenceEventTypes } from "../../utils/enums";
|
|
2
|
+
import { PresenceUser } from "./presence-user.data.model";
|
|
3
|
+
export interface PresenceMultipleUsersOnlineEvent {
|
|
4
|
+
users: PresenceUser[];
|
|
5
|
+
}
|
|
6
|
+
export interface PresenceUserStateChangeEvent {
|
|
7
|
+
user: PresenceUser;
|
|
8
|
+
state: string;
|
|
9
|
+
}
|
|
10
|
+
export type PresenceEventTypesMap = {
|
|
11
|
+
[PresenceEventTypes.MULTIPLE_USERS_ONLINE]: PresenceMultipleUsersOnlineEvent;
|
|
12
|
+
[PresenceEventTypes.USER_STATE_CHANGE]: PresenceUserStateChangeEvent;
|
|
13
|
+
};
|
|
14
|
+
export interface GetPresenceDataResponse {
|
|
15
|
+
data: PresenceUser[] | null;
|
|
16
|
+
}
|
|
@@ -163,11 +163,28 @@ export interface RecorderAnnotationEditVersion {
|
|
|
163
163
|
waveformData?: number[];
|
|
164
164
|
displayName?: string;
|
|
165
165
|
boundedTrimRanges?: RecorderBoundedTrimRange[];
|
|
166
|
+
boundedScaleRanges?: RecorderBoundedScaleRange[];
|
|
166
167
|
}
|
|
167
168
|
export interface RecorderBoundedTrimRange {
|
|
168
169
|
start: number;
|
|
169
170
|
end: number;
|
|
170
171
|
}
|
|
172
|
+
export interface RecorderBoundedScaleRange {
|
|
173
|
+
start: number;
|
|
174
|
+
end: number;
|
|
175
|
+
zoomInDuration?: number;
|
|
176
|
+
holdDuration?: number;
|
|
177
|
+
zoomOutDuration?: number;
|
|
178
|
+
zoomFactor?: number;
|
|
179
|
+
centerX?: number;
|
|
180
|
+
centerY?: number;
|
|
181
|
+
topLeftX?: number;
|
|
182
|
+
topLeftY?: number;
|
|
183
|
+
}
|
|
184
|
+
export interface RecorderEditRange {
|
|
185
|
+
trimRanges: RecorderBoundedTrimRange[];
|
|
186
|
+
scaleRanges: RecorderBoundedScaleRange[];
|
|
187
|
+
}
|
|
171
188
|
export declare class RecorderMetadata extends BaseMetadata {
|
|
172
189
|
[key: string]: any;
|
|
173
190
|
}
|
|
@@ -184,6 +201,7 @@ declare class RecorderDataTranscription {
|
|
|
184
201
|
contentSummary?: string;
|
|
185
202
|
}
|
|
186
203
|
declare class RecorderDataAsset {
|
|
204
|
+
version?: number;
|
|
187
205
|
url: string;
|
|
188
206
|
mimeType?: string;
|
|
189
207
|
fileName?: string;
|
|
@@ -201,6 +219,7 @@ export declare class RecorderData {
|
|
|
201
219
|
from?: User | null;
|
|
202
220
|
metadata?: RecorderMetadata;
|
|
203
221
|
assets: RecorderDataAsset[];
|
|
222
|
+
assetsAllVersions: RecorderDataAsset[];
|
|
204
223
|
transcription: RecorderDataTranscription;
|
|
205
224
|
}
|
|
206
225
|
export interface RecorderRequestQuery {
|
|
@@ -211,4 +230,6 @@ export interface GetRecordingDataResponse {
|
|
|
211
230
|
}
|
|
212
231
|
export interface GetRecordingsResponse extends RecorderData {
|
|
213
232
|
}
|
|
233
|
+
export interface DeleteRecordingsResponse extends RecorderData {
|
|
234
|
+
}
|
|
214
235
|
export {};
|
|
@@ -6,8 +6,21 @@ export interface RecordingDoneEvent extends RecorderData {
|
|
|
6
6
|
}
|
|
7
7
|
export interface RecordingDeleteEvent extends RecorderData {
|
|
8
8
|
}
|
|
9
|
+
export interface RecordingEditDoneEvent extends RecorderData {
|
|
10
|
+
}
|
|
11
|
+
export interface RecordingErrorEvent {
|
|
12
|
+
type: string;
|
|
13
|
+
message: string;
|
|
14
|
+
recorderId?: string;
|
|
15
|
+
}
|
|
16
|
+
export interface RecordingSaveInitiatedEvent {
|
|
17
|
+
annotationId?: string;
|
|
18
|
+
message: string;
|
|
19
|
+
type: 'edit' | 'record';
|
|
20
|
+
}
|
|
9
21
|
export type RecorderEventTypesMap = {
|
|
10
22
|
[RecorderEventTypes.TRANSCRIPTION_DONE]: TranscriptionDoneEvent;
|
|
11
23
|
[RecorderEventTypes.RECORDING_DONE]: RecordingDoneEvent;
|
|
24
|
+
[RecorderEventTypes.RECORDING_EDIT_DONE]: RecordingEditDoneEvent;
|
|
12
25
|
[RecorderEventTypes.DELETE_RECORDING]: RecordingDeleteEvent;
|
|
13
26
|
};
|
|
@@ -93,3 +93,15 @@ export declare class RecordedData {
|
|
|
93
93
|
};
|
|
94
94
|
getThumbnailTag: (url?: string) => string;
|
|
95
95
|
}
|
|
96
|
+
export declare class RecorderQualityConstraintsOptions {
|
|
97
|
+
video?: MediaTrackConstraints;
|
|
98
|
+
audio?: MediaTrackConstraints;
|
|
99
|
+
}
|
|
100
|
+
export declare class RecorderQualityConstraints {
|
|
101
|
+
safari?: RecorderQualityConstraintsOptions;
|
|
102
|
+
other?: RecorderQualityConstraintsOptions;
|
|
103
|
+
}
|
|
104
|
+
export declare class RecorderEncodingOptions {
|
|
105
|
+
safari?: MediaRecorderOptions;
|
|
106
|
+
other?: MediaRecorderOptions;
|
|
107
|
+
}
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
import { SingleEditorConfig, UserEditorAccess, EditorAccessTimer, LiveStateDataConfig, SetLiveStateDataConfig } from '../data/live-state-data.data.model';
|
|
3
3
|
import { User } from '../data/user.data.model';
|
|
4
4
|
import { ServerConnectionState } from '../../utils/enums';
|
|
5
|
+
import { LiveStateEventTypesMap } from '../data/live-state-events.data.model';
|
|
5
6
|
|
|
6
7
|
/**
|
|
7
8
|
* Represents the synchronization element for live state.
|
|
@@ -141,6 +142,11 @@ export declare class LiveStateSyncElement {
|
|
|
141
142
|
*/
|
|
142
143
|
onServerConnectionStateChange: () => Observable<ServerConnectionState>;
|
|
143
144
|
|
|
145
|
+
/**
|
|
146
|
+
* Subscribe to live state events
|
|
147
|
+
*/
|
|
148
|
+
on: <T extends keyof LiveStateEventTypesMap>(action: T) => Observable<LiveStateEventTypesMap[T]>;
|
|
149
|
+
|
|
144
150
|
/**
|
|
145
151
|
* Constructor for LiveStateSyncElement.
|
|
146
152
|
*/
|
|
@@ -278,4 +284,9 @@ export declare class LiveStateSyncElement {
|
|
|
278
284
|
* To get server connection state
|
|
279
285
|
*/
|
|
280
286
|
private _onServerConnectionStateChange;
|
|
287
|
+
|
|
288
|
+
/**
|
|
289
|
+
* Subscribe to live state events
|
|
290
|
+
*/
|
|
291
|
+
private _on;
|
|
281
292
|
}
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
// @ts-nocheck
|
|
2
2
|
import { Observable } from "rxjs";
|
|
3
3
|
import { PresenceUser } from "../data/presence-user.data.model";
|
|
4
|
+
import { GetPresenceDataResponse, PresenceEventTypesMap } from "../data/presence-events.data.model";
|
|
5
|
+
import { PresenceRequestQuery } from "../data/presence-actions.data.model";
|
|
6
|
+
|
|
4
7
|
export declare class PresenceElement {
|
|
5
8
|
|
|
6
9
|
/**
|
|
@@ -36,6 +39,16 @@ export declare class PresenceElement {
|
|
|
36
39
|
* To disable adding self to the presence list
|
|
37
40
|
*/
|
|
38
41
|
disableSelf: () => void;
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* To get the presence data
|
|
45
|
+
*/
|
|
46
|
+
getData: (query?: PresenceRequestQuery) => Observable<GetPresenceDataResponse>;
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* Subscribe to presence events
|
|
50
|
+
*/
|
|
51
|
+
on: <T extends keyof PresenceEventTypesMap>(action: T) => Observable<PresenceEventTypesMap[T]>;
|
|
39
52
|
constructor();
|
|
40
53
|
/**
|
|
41
54
|
* Subscribe to a list of all online users who are either active or inactive on the current document.
|
|
@@ -70,4 +83,14 @@ export declare class PresenceElement {
|
|
|
70
83
|
* To disable adding self to the presence list
|
|
71
84
|
*/
|
|
72
85
|
private _disableSelf;
|
|
86
|
+
|
|
87
|
+
/**
|
|
88
|
+
* To get the presence data
|
|
89
|
+
*/
|
|
90
|
+
private _getData;
|
|
91
|
+
|
|
92
|
+
/**
|
|
93
|
+
* Subscribe to presence events
|
|
94
|
+
*/
|
|
95
|
+
private _on;
|
|
73
96
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
// @ts-nocheck
|
|
2
2
|
import { Observable } from "rxjs";
|
|
3
|
-
import { RecorderData, RecorderRequestQuery, GetRecordingDataResponse, GetRecordingsResponse } from "../data/recorder-annotation.data.model";
|
|
3
|
+
import { RecorderData, RecorderRequestQuery, GetRecordingDataResponse, GetRecordingsResponse, DeleteRecordingsResponse } from "../data/recorder-annotation.data.model";
|
|
4
4
|
import { RecorderEventTypesMap } from "../data/recorder-events.data.model";
|
|
5
|
-
import { RecordedData } from "../data/recorder.model";
|
|
5
|
+
import { RecordedData, RecorderQualityConstraints, RecorderEncodingOptions } from "../data/recorder.model";
|
|
6
6
|
|
|
7
7
|
export declare class RecorderElement {
|
|
8
8
|
|
|
@@ -69,6 +69,21 @@ export declare class RecorderElement {
|
|
|
69
69
|
*/
|
|
70
70
|
fetchRecordings: (query?: RecorderRequestQuery) => Promise<GetRecordingsResponse[]>;
|
|
71
71
|
|
|
72
|
+
/**
|
|
73
|
+
* To delete recordings
|
|
74
|
+
*/
|
|
75
|
+
deleteRecordings: (query?: RecorderRequestQuery) => Promise<DeleteRecordingsResponse[]>;
|
|
76
|
+
|
|
77
|
+
/**
|
|
78
|
+
* To set recording quality constraints
|
|
79
|
+
*/
|
|
80
|
+
setRecordingQualityConstraints: (constraints: RecorderQualityConstraints) => void;
|
|
81
|
+
|
|
82
|
+
/**
|
|
83
|
+
* To set recording encoding options
|
|
84
|
+
*/
|
|
85
|
+
setRecordingEncodingOptions: (options: RecorderEncodingOptions) => void;
|
|
86
|
+
|
|
72
87
|
constructor();
|
|
73
88
|
|
|
74
89
|
private _initRecording;
|
|
@@ -133,4 +148,19 @@ export declare class RecorderElement {
|
|
|
133
148
|
* To fetch recordings
|
|
134
149
|
*/
|
|
135
150
|
private _fetchRecordings;
|
|
151
|
+
|
|
152
|
+
/**
|
|
153
|
+
* To delete recordings
|
|
154
|
+
*/
|
|
155
|
+
private _deleteRecordings;
|
|
156
|
+
|
|
157
|
+
/**
|
|
158
|
+
* To set recording quality constraints
|
|
159
|
+
*/
|
|
160
|
+
private _setRecordingQualityConstraints;
|
|
161
|
+
|
|
162
|
+
/**
|
|
163
|
+
* To set recording encoding options
|
|
164
|
+
*/
|
|
165
|
+
private _setRecordingEncodingOptions;
|
|
136
166
|
}
|
package/app/utils/enums.d.ts
CHANGED
|
@@ -58,7 +58,10 @@ export declare const CommentEventTypes: {
|
|
|
58
58
|
export declare const RecorderEventTypes: {
|
|
59
59
|
readonly TRANSCRIPTION_DONE: "transcriptionDone";
|
|
60
60
|
readonly RECORDING_DONE: "recordingDone";
|
|
61
|
+
readonly RECORDING_EDIT_DONE: "recordingEditDone";
|
|
61
62
|
readonly DELETE_RECORDING: "deleteRecording";
|
|
63
|
+
readonly ERROR: "error";
|
|
64
|
+
readonly RECORDING_SAVE_INITIATED: "recordingSaveInitiated";
|
|
62
65
|
};
|
|
63
66
|
export declare const CoreEventTypes: {
|
|
64
67
|
readonly VELT_BUTTON_CLICK: "veltButtonClick";
|
|
@@ -66,9 +69,24 @@ export declare const CoreEventTypes: {
|
|
|
66
69
|
readonly DOCUMENT_INIT: "documentInit";
|
|
67
70
|
readonly ERROR: "error";
|
|
68
71
|
};
|
|
72
|
+
export declare const LiveStateSyncEventTypes: {
|
|
73
|
+
readonly ACCESS_REQUESTED: "accessRequested";
|
|
74
|
+
readonly ACCESS_REQUEST_CANCELED: "accessRequestCanceled";
|
|
75
|
+
readonly ACCESS_ACCEPTED: "accessAccepted";
|
|
76
|
+
readonly ACCESS_REJECTED: "accessRejected";
|
|
77
|
+
readonly EDITOR_ASSIGNED: "editorAssigned";
|
|
78
|
+
readonly VIEWER_ASSIGNED: "viewerAssigned";
|
|
79
|
+
readonly EDITOR_ON_DIFFERENT_TAB_DETECTED: "editorOnDifferentTabDetected";
|
|
80
|
+
};
|
|
81
|
+
export declare const PresenceEventTypes: {
|
|
82
|
+
readonly MULTIPLE_USERS_ONLINE: "multipleUsersOnline";
|
|
83
|
+
readonly USER_STATE_CHANGE: "userStateChange";
|
|
84
|
+
};
|
|
69
85
|
export type CommentEventType = typeof CommentEventTypes[keyof typeof CommentEventTypes];
|
|
70
86
|
export type RecorderEventType = typeof RecorderEventTypes[keyof typeof RecorderEventTypes];
|
|
71
87
|
export type CoreEventType = typeof CoreEventTypes[keyof typeof CoreEventTypes];
|
|
88
|
+
export type LiveStateSyncEventType = typeof LiveStateSyncEventTypes[keyof typeof LiveStateSyncEventTypes];
|
|
89
|
+
export type PresenceEventType = typeof PresenceEventTypes[keyof typeof PresenceEventTypes];
|
|
72
90
|
export declare enum TagStatus {
|
|
73
91
|
ADDED = "added",
|
|
74
92
|
UPDATED = "updated",
|
|
@@ -238,7 +256,7 @@ export type ReactionPinType = 'timeline' | 'comment';
|
|
|
238
256
|
export type SidebarPosition = 'left' | 'right';
|
|
239
257
|
export type SidebarSortingCriteria = 'date' | 'unread' | null;
|
|
240
258
|
export type SidebarFilterCriteria = 'all' | 'read' | 'unread' | 'resolved';
|
|
241
|
-
export type SidebarFilterSearchType = 'people' | 'assigned' | 'tagged' | 'pages' | 'statuses' | 'priorities' | 'categories' | 'versions';
|
|
259
|
+
export type SidebarFilterSearchType = 'people' | 'assigned' | 'tagged' | 'pages' | 'documents' | 'statuses' | 'priorities' | 'categories' | 'versions';
|
|
242
260
|
export type InlineSortingCriteria = 'createdFirst' | 'createdLast' | 'updatedFirst' | 'updatedLast';
|
|
243
261
|
export type NotificationPanelMode = 'popover' | 'sidebar';
|
|
244
262
|
export type SidebarActionButtonType = 'default' | 'toggle';
|
package/models.d.ts
CHANGED
|
@@ -28,6 +28,7 @@ export * from './app/models/data/document-user.data.model';
|
|
|
28
28
|
export * from './app/models/data/huddle.model';
|
|
29
29
|
export * from './app/models/data/live-state-data-map.data.model';
|
|
30
30
|
export * from './app/models/data/live-state-data.data.model';
|
|
31
|
+
export * from './app/models/data/live-state-events.data.model';
|
|
31
32
|
export * from './app/models/data/localstorage.data.model';
|
|
32
33
|
export * from './app/models/data/location-metadata.model';
|
|
33
34
|
export * from './app/models/data/location.model';
|
|
@@ -37,6 +38,8 @@ export * from './app/models/data/notification.model';
|
|
|
37
38
|
export * from './app/models/data/page-info.model';
|
|
38
39
|
export * from './app/models/data/permission.data.model';
|
|
39
40
|
export * from './app/models/data/presence-user.data.model';
|
|
41
|
+
export * from './app/models/data/presence-actions.data.model';
|
|
42
|
+
export * from './app/models/data/presence-events.data.model';
|
|
40
43
|
export * from './app/models/data/recorder.model';
|
|
41
44
|
export * from './app/models/data/recorder-annotation.data.model';
|
|
42
45
|
export * from './app/models/data/recorder-events.data.model';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@veltdev/sdk",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.5.0-beta.10",
|
|
4
4
|
"description": "Velt is an SDK to add collaborative features to your product within minutes. Example: Comments like Figma, Frame.io, Google docs or sheets, Recording like Loom, Huddles like Slack and much more.",
|
|
5
5
|
"homepage": "https://velt.dev",
|
|
6
6
|
"keywords": [
|