@veltdev/sdk 4.0.0-beta.8 → 4.0.0

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.
@@ -0,0 +1,40 @@
1
+ export declare class FolderMetadata {
2
+ folderId?: string;
3
+ /**
4
+ * Velt folder id
5
+ */
6
+ veltFolderId?: string;
7
+ /**
8
+ * Parent folder id
9
+ */
10
+ parentFolderId?: string;
11
+ /**
12
+ * Velt parent folder id
13
+ */
14
+ veltParentFolderId?: string;
15
+ /**
16
+ * Created at
17
+ */
18
+ createdAt?: number;
19
+ /**
20
+ * Last updated
21
+ */
22
+ lastUpdated?: number;
23
+ /**
24
+ * API key
25
+ */
26
+ apiKey?: string;
27
+ /**
28
+ * Organization id
29
+ */
30
+ organizationId?: string;
31
+ /**
32
+ * Client organization id
33
+ */
34
+ clientOrganizationId?: string;
35
+ /**
36
+ * Folder name
37
+ */
38
+ folderName?: string;
39
+ [key: string]: any;
40
+ }
@@ -0,0 +1,61 @@
1
+ import { BaseMetadata } from "./base-metadata.data.model";
2
+ import { CommentAnnotation, GhostComment, InlineCommentSectionConfig } from "./comment-annotation.data.model";
3
+ import { CursorPosition } from "./cursor-position.data.model";
4
+ import { Location } from "./location.model";
5
+ import { TargetElement } from "./target-element.data.model";
6
+ import { TargetTextRange } from "./target-text-range.data.model";
7
+ import { User } from "./user.data.model";
8
+ export declare class MultiThreadCommentAnnotation {
9
+ /**
10
+ * The id of the annotation.
11
+ */
12
+ annotationId: string;
13
+ /**
14
+ * The id of the area annotation.
15
+ */
16
+ areaAnnotationId?: string;
17
+ /**
18
+ * The target element of the annotation.
19
+ */
20
+ targetElement?: TargetElement | null;
21
+ /**
22
+ * The id of the target element.
23
+ */
24
+ targetElementId?: string | null;
25
+ /**
26
+ * Selected text range of comment annotation
27
+ */
28
+ targetTextRange?: TargetTextRange | null;
29
+ /**
30
+ * The id of the target inline comment element.
31
+ */
32
+ targetInlineCommentElementId?: string;
33
+ /**
34
+ * The inline comment section config.
35
+ */
36
+ inlineCommentSectionConfig?: InlineCommentSectionConfig;
37
+ commentAnnotations?: {
38
+ [commentAnnotationId: string]: boolean;
39
+ };
40
+ commentAnnotationsMap?: {
41
+ [commentAnnotationId: string]: CommentAnnotation;
42
+ };
43
+ /**
44
+ * Unique location id generated from provided location
45
+ */
46
+ locationId?: number | null;
47
+ /**
48
+ * Set location to identify user on sub document
49
+ */
50
+ location?: Location | null;
51
+ position?: CursorPosition | null;
52
+ ghostComment?: GhostComment | null;
53
+ from: User;
54
+ type: string;
55
+ isDraft?: boolean;
56
+ sourceId?: string;
57
+ metadata?: MultiThreadMetadata;
58
+ }
59
+ export declare class MultiThreadMetadata extends BaseMetadata {
60
+ [key: string]: any;
61
+ }
@@ -88,6 +88,11 @@ export declare class NotificationRawData {
88
88
  [key: string]: any;
89
89
  };
90
90
  displayBodyMessage?: string;
91
+ displayBodyMessageTemplate?: string;
92
+ displayBodyMessageTemplateData?: {
93
+ users?: User[];
94
+ [key: string]: any;
95
+ };
91
96
  customData?: any;
92
97
  notifyUsers?: {
93
98
  [email: string]: boolean;
@@ -127,6 +132,17 @@ export declare class Notification {
127
132
  * Notification body message
128
133
  */
129
134
  displayBodyMessage?: string;
135
+ /**
136
+ * Display body message template
137
+ */
138
+ displayBodyMessageTemplate?: string;
139
+ /**
140
+ * Display body message template data
141
+ */
142
+ displayBodyMessageTemplateData?: {
143
+ users?: User[];
144
+ [key: string]: any;
145
+ };
130
146
  /**
131
147
  * Display message template
132
148
  */
@@ -164,4 +164,10 @@ export declare class RecorderData {
164
164
  assets: RecorderDataAsset[];
165
165
  transcription: RecorderDataTranscription;
166
166
  }
167
+ export interface RecorderRequestQuery {
168
+ recorderIds: string[];
169
+ }
170
+ export interface GetRecordingDataResponse {
171
+ data: Record<string, RecorderData> | null;
172
+ }
167
173
  export {};
@@ -1,15 +1,7 @@
1
1
  import { RecorderEventTypes } from "../../utils/enums";
2
+ import { RecorderData } from "./recorder-annotation.data.model";
2
3
  export interface TranscriptionDoneEvent {
3
- transcription: string;
4
- id?: string;
5
- tag?: string;
6
- type?: string;
7
- thumbnailUrl?: string;
8
- thumbnailWithPlayIconUrl?: string;
9
- videoUrl?: string;
10
- audioUrl?: string;
11
- videoPlayerUrl?: string;
12
- getThumbnailTag?: (url?: string) => string;
4
+ data: Record<string, RecorderData> | null;
13
5
  }
14
6
  export type RecorderEventTypesMap = {
15
7
  [RecorderEventTypes.TRANSCRIPTION_DONE]: TranscriptionDoneEvent;
@@ -0,0 +1,5 @@
1
+ import { User } from "./user.data.model";
2
+ export interface UserDataProvider {
3
+ getUsers(userIds: string[]): Promise<Record<string, User>>;
4
+ resolveTimeout?: number;
5
+ }
@@ -8,7 +8,7 @@ import { AutocompleteData } from "../data/autocomplete.data.model";
8
8
  import { CommentSidebarCustomActionEventData, CommentSidebarData, CommentSidebarDataOptions } from "../data/comment-sidebar-config.model";
9
9
  export { ReactionMap } from '../data/reaction-annotation.data.model';
10
10
  import { AcceptCommentAnnotationRequest, AddAttachmentRequest, AddAttachmentResponse, AddCommentAnnotationRequest, AddCommentRequest, AddReactionRequest, ApproveCommentAnnotationRequest, AssignUserRequest, AssignUserEvent, CopyLinkRequest, DeleteAttachmentRequest, DeleteCommentAnnotationRequest, CommentRequestQuery, CommentRequestQuery, DeleteCommentRequest, DeleteReactionRequest, DeleteRecordingRequest, GetAttachmentRequest, GetCommentRequest, GetLinkRequest, GetRecordingRequest, RejectCommentAnnotationRequest, ResolveCommentAnnotationRequest, SubscribeCommentAnnotationRequest, UnsubscribeCommentAnnotationRequest, ToggleReactionRequest, UpdateAccessRequest, UpdateCommentRequest, UpdatePriorityRequest, UpdateStatusRequest } from "../data/comment-actions.data.model";
11
- import { UnreadCommentsCount } from "../data/comment-utils.data.model";
11
+ import { UnreadCommentsCount, TransformContext } from "../data/comment-utils.data.model";
12
12
  export declare class CommentElement {
13
13
  /**
14
14
  * Subscribe to comments on the current document.
@@ -1073,6 +1073,21 @@ export declare class CommentElement {
1073
1073
  */
1074
1074
  public disableReadOnly: () => void;
1075
1075
 
1076
+ /**
1077
+ * To enable custom autocomplete search
1078
+ */
1079
+ public enableCustomAutocompleteSearch: () => void;
1080
+
1081
+ /**
1082
+ * To disable custom autocomplete search
1083
+ */
1084
+ public disableCustomAutocompleteSearch: () => void;
1085
+
1086
+ /**
1087
+ * To set transform context
1088
+ */
1089
+ public setTransformContext: (transformContext: TransformContext) => void;
1090
+
1076
1091
  constructor();
1077
1092
  /**
1078
1093
  * Subscribe to comments on the current document.
@@ -2127,4 +2142,19 @@ export declare class CommentElement {
2127
2142
  * To disable read only
2128
2143
  */
2129
2144
  private _disableReadOnly;
2145
+
2146
+ /**
2147
+ * To enable custom autocomplete search
2148
+ */
2149
+ private _enableCustomAutocompleteSearch;
2150
+
2151
+ /**
2152
+ * To disable custom autocomplete search
2153
+ */
2154
+ private _disableCustomAutocompleteSearch;
2155
+
2156
+ /**
2157
+ * To set transform context
2158
+ */
2159
+ private _setTransformContext;
2130
2160
  }
@@ -1,6 +1,6 @@
1
1
  // @ts-nocheck
2
2
  import { Observable } from "rxjs";
3
- import { RecorderData } from "../data/recorder-annotation.data.model";
3
+ import { RecorderData, RecorderRequestQuery, GetRecordingDataResponse } from "../data/recorder-annotation.data.model";
4
4
  import { RecorderEventTypesMap } from "../data/recorder-events.data.model";
5
5
 
6
6
  export declare class RecorderElement {
@@ -21,6 +21,7 @@ export declare class RecorderElement {
21
21
 
22
22
  /**
23
23
  * To get recording data by recorder id
24
+ * @deprecated Use getRecordingData() method instead
24
25
  */
25
26
  getRecordingDataByRecorderId: (recorderId: string) => Observable<RecorderData | null>;
26
27
 
@@ -39,6 +40,11 @@ export declare class RecorderElement {
39
40
  */
40
41
  public on: <T extends keyof RecorderEventTypesMap>(action: T) => Observable<RecorderEventTypesMap[T]>;
41
42
 
43
+ /**
44
+ * To get recording data by recorder ids
45
+ */
46
+ getRecordingData: (query: RecorderRequestQuery) => Promise<GetRecordingDataResponse>;
47
+
42
48
  constructor();
43
49
 
44
50
  private _initRecording;
@@ -57,6 +63,7 @@ export declare class RecorderElement {
57
63
 
58
64
  /**
59
65
  * To get recording data by recorder id
66
+ * @deprecated Use getRecordingData() method instead
60
67
  */
61
68
  private _getRecordingDataByRecorderId;
62
69
 
@@ -74,4 +81,9 @@ export declare class RecorderElement {
74
81
  * Subscribe to recorder actions
75
82
  */
76
83
  private _on;
84
+
85
+ /**
86
+ * To get recording data by recorder ids
87
+ */
88
+ private _getRecordingData;
77
89
  }
@@ -8,10 +8,13 @@ export declare class Constants {
8
8
  static LOCALSTORAGE_DATA_ID: string;
9
9
  static NO_ORGANIZATION_ID: string;
10
10
  static DEFAULT_QUERY_HASH: string;
11
+ static LISTENER_BATCH_SIZE: number;
11
12
  static FIREBASE_PARTIAL_PATH_ORGANIZATIONS: string;
13
+ static FIREBASE_PARTIAL_PATH_FOLDERS: string;
12
14
  static FIREBASE_PARTIAL_PATH_DOCS: string;
13
15
  static FIREBASE_PARTIAL_PATH_PRESENCE: string;
14
16
  static FIREBASE_PARTIAL_PATH_ORGANIZATION_USERS: string;
17
+ static FIREBASE_PARTIAL_PATH_FOLDER_USERS: string;
15
18
  static FIREBASE_PARTIAL_PATH_DOCUMENT_USERS: string;
16
19
  static FIREBASE_PARTIAL_PATH_CURSOR: string;
17
20
  static FIREBASE_PARTIAL_PATH_ARROW: string;
@@ -242,6 +245,7 @@ export declare class Constants {
242
245
  VELT_COMMENT_DIALOG_BODY_THREAD_CARD: string;
243
246
  VELT_COMMENT_DIALOG_PRIVATE_BANNER: string;
244
247
  VELT_COMMENT_COMPOSER: string;
248
+ VELT_SKELETON_LOADER: string;
245
249
  VELT_SHADOW_DOM_INTERNAL: string;
246
250
  };
247
251
  static ATTRIBUTES: {
@@ -252,6 +256,7 @@ export declare class Constants {
252
256
  TARGET_ELEMENT_ID: string;
253
257
  VELT_ID: string;
254
258
  VELT_ELEMENT: string;
259
+ VELT_SCREEN_RECORDER_PANEL: string;
255
260
  VELT_SOURCE_ID: string;
256
261
  VELT_ANNOTATION_ID: string;
257
262
  VELT_ANNOTATION_IDS: string;
@@ -41,6 +41,8 @@ export declare const CommentEventTypes: {
41
41
  readonly TOGGLE_REACTION: "toggleReaction";
42
42
  readonly COMMENT_SIDEBAR_DATA_INIT: "commentSidebarDataInit";
43
43
  readonly COMMENT_SIDEBAR_DATA_UPDATE: "commentSidebarDataUpdate";
44
+ readonly AUTOCOMPLETE_SEARCH: "autocompleteSearch";
45
+ readonly COMPOSER_CLICKED: "composerClicked";
44
46
  };
45
47
  export declare const RecorderEventTypes: {
46
48
  readonly TRANSCRIPTION_DONE: "transcriptionDone";
package/models.d.ts CHANGED
@@ -1,6 +1,7 @@
1
1
  export * from './app/utils/enums';
2
2
  export * from './app/models/data/attachment.model';
3
3
  export * from './app/models/data/area-annotation.data.model';
4
+ export * from './app/models/data/arrow-annotation.data.model';
4
5
  export * from './app/models/data/base-metadata.data.model';
5
6
  export * from './app/models/data/button.data.model';
6
7
  export * from './app/models/data/chatgpt.data.model';
@@ -17,6 +18,7 @@ export * from './app/models/data/custom-css.data.model';
17
18
  export * from './app/models/data/custom-chip-dropdown.data.model';
18
19
  export * from './app/models/data/device-info.model';
19
20
  export * from './app/models/data/document.data.model';
21
+ export * from './app/models/data/document-events.data.model';
20
22
  export * from './app/models/data/document-iam.data.model';
21
23
  export * from './app/models/data/document-metadata.model';
22
24
  export * from './app/models/data/document-paths.data.model';
@@ -28,6 +30,7 @@ export * from './app/models/data/localstorage.data.model';
28
30
  export * from './app/models/data/location-metadata.model';
29
31
  export * from './app/models/data/location.model';
30
32
  export * from './app/models/data/media-preview-config.data.model';
33
+ export * from './app/models/data/multi-thread.data.model';
31
34
  export * from './app/models/data/notification.model';
32
35
  export * from './app/models/data/page-info.model';
33
36
  export * from './app/models/data/permission.data.model';
@@ -63,3 +66,4 @@ export * from './app/models/data/organization-groups.data.model';
63
66
  export * from './app/models/data/organization-metadata.model';
64
67
  export * from './app/models/data/user-organization.data.model';
65
68
  export * from './app/models/data/event-metadata.data.model';
69
+ export * from './app/models/data/user-resolver.data.model';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@veltdev/sdk",
3
- "version": "4.0.0-beta.8",
3
+ "version": "4.0.0",
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": [