@veltdev/types-dev 6.0.0-beta.18 → 6.0.0-beta.2

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.
Files changed (29) hide show
  1. package/app/client/snippyly.model.d.ts +3 -2
  2. package/app/models/data/comment-events.data.model.d.ts +0 -29
  3. package/app/models/data/reaction-resolver.data.model.d.ts +0 -1
  4. package/app/models/data/selection.model.d.ts +8 -10
  5. package/app/models/data/user-resolver.data.model.d.ts +9 -11
  6. package/app/models/data/user.data.model.d.ts +18 -21
  7. package/app/models/element/activity-element.model.d.ts +1 -0
  8. package/app/models/element/area-element.model.d.ts +1 -0
  9. package/app/models/element/arrow-element.model.d.ts +2 -1
  10. package/app/models/element/autocomplete-element.model.d.ts +1 -0
  11. package/app/models/element/comment-element.model.d.ts +77 -103
  12. package/app/models/element/contact-element.model.d.ts +2 -1
  13. package/app/models/element/crdt-element.model.d.ts +1 -1
  14. package/app/models/element/cursor-element.model.d.ts +2 -1
  15. package/app/models/element/huddle-element.model.d.ts +2 -1
  16. package/app/models/element/live-state-sync-element.model.d.ts +1 -1
  17. package/app/models/element/notification-element.model.d.ts +2 -33
  18. package/app/models/element/presence-element.model.d.ts +11 -32
  19. package/app/models/element/reaction-element.model.d.ts +1 -1
  20. package/app/models/element/recorder-element.model.d.ts +2 -21
  21. package/app/models/element/rewriter-element.model.d.ts +1 -43
  22. package/app/models/element/selection-element.model.d.ts +1 -1
  23. package/app/models/element/suggestion-element.model.d.ts +1 -0
  24. package/app/models/element/tag-element.model.d.ts +8 -7
  25. package/app/models/element/views-element.model.d.ts +1 -1
  26. package/app/utils/enums.d.ts +82 -95
  27. package/package.json +2 -8
  28. package/types.d.ts +22 -22
  29. package/velt.d.ts +3 -2
@@ -1,8 +1,9 @@
1
+ // @ts-nocheck
1
2
  import { Observable } from "rxjs";
2
3
  import { Config, DisableLogsConfig } from "../models/data/config.data.model";
3
4
  import { DocumentUser } from "../models/data/document-user.data.model";
4
5
  import { Location } from "../models/data/location.model";
5
- import { User, Options, VeltAuthProvider, VeltPermissionProvider } from "../models/data/user.data.model";
6
+ import { User, UserOptions, VeltAuthProvider, VeltPermissionProvider } from "../models/data/user.data.model";
6
7
  import { CustomCss } from "../models/data/custom-css.data.model";
7
8
  import { ActivityElement } from "../models/element/activity-element.model";
8
9
  import { AreaElement } from "../models/element/area-element.model";
@@ -39,7 +40,7 @@ import { HeartbeatConfig, Heartbeat, GetHeartbeatResponse } from "../models/data
39
40
  export declare class Snippyly {
40
41
  constructor();
41
42
  initConfig: (apiKey: string, config?: Config) => void;
42
- identify: (user: User, userOptions?: Options) => Promise<unknown>;
43
+ identify: (user: User, userOptions?: UserOptions) => Promise<unknown>;
43
44
  setVeltAuthProvider: (veltAuthProvider: VeltAuthProvider) => Promise<User | null>;
44
45
  /**
45
46
  * Tell us who the currently logged in user is.
@@ -89,10 +89,6 @@ export type CommentEventTypesMap = {
89
89
  [CommentEventTypes.COMMENT_TOOL_CLICKED]: CommentToolClickedEvent;
90
90
  [CommentEventTypes.SIDEBAR_BUTTON_CLICK]: SidebarButtonClickEvent;
91
91
  [CommentEventTypes.SIDEBAR_BUTTON_CLICKED]: SidebarButtonClickedEvent;
92
- [CommentEventTypes.SIDEBAR_OPEN]: SidebarOpenEvent;
93
- [CommentEventTypes.SIDEBAR_CLOSE]: SidebarCloseEvent;
94
- [CommentEventTypes.COMMENT_CLICK]: CommentClickEvent;
95
- [CommentEventTypes.COMMENT_NAVIGATION_BUTTON_CLICK]: CommentNavigationButtonClickEvent;
96
92
  [CommentEventTypes.ATTACHMENT_DOWNLOAD_CLICKED]: AttachmentDownloadClickedEvent;
97
93
  [CommentEventTypes.COMMENT_SAVED]: CommentSavedEvent;
98
94
  [CommentEventTypes.COMMENT_SAVE_TRIGGERED]: CommentSaveTriggeredEvent;
@@ -351,31 +347,6 @@ export interface SidebarButtonClickEvent {
351
347
  }
352
348
  export interface SidebarButtonClickedEvent extends SidebarButtonClickEvent {
353
349
  }
354
- /** Fired when the comment sidebar opens. Subscribe via `commentElement.on('sidebarOpen')`. */
355
- export interface SidebarOpenEvent {
356
- metadata?: VeltEventMetadata;
357
- }
358
- /** Fired when the comment sidebar closes. Subscribe via `commentElement.on('sidebarClose')`. */
359
- export interface SidebarCloseEvent {
360
- metadata?: VeltEventMetadata;
361
- }
362
- /** Fired when a comment is clicked in the sidebar list. Subscribe via `commentElement.on('commentClick')`. */
363
- export interface CommentClickEvent {
364
- documentId?: string | null;
365
- location?: Location | null;
366
- targetElementId?: string | null;
367
- context?: {
368
- [key: string]: any;
369
- };
370
- annotation?: CommentAnnotation;
371
- metadata?: VeltEventMetadata;
372
- }
373
- /**
374
- * Fired when the navigation ("go to") button on a sidebar comment is clicked.
375
- * Subscribe via `commentElement.on('commentNavigationButtonClick')`.
376
- */
377
- export interface CommentNavigationButtonClickEvent extends CommentClickEvent {
378
- }
379
350
  export interface AttachmentDownloadClickedEvent {
380
351
  annotationId: string;
381
352
  commentAnnotation: CommentAnnotation;
@@ -39,5 +39,4 @@ export interface PartialReactionAnnotation {
39
39
  metadata?: BaseMetadata;
40
40
  icon?: string;
41
41
  from?: PartialUser;
42
- [key: string]: any;
43
42
  }
@@ -21,16 +21,14 @@ export declare class Selection {
21
21
  pageInfo: PageInfo;
22
22
  timestamp: number;
23
23
  }
24
- export declare const UserIndicatorPosition: {
25
- readonly Start: "start";
26
- readonly End: "end";
27
- };
28
- export type UserIndicatorPosition = (typeof UserIndicatorPosition)[keyof typeof UserIndicatorPosition];
29
- export declare const UserIndicatorType: {
30
- readonly Avatar: "avatar";
31
- readonly Label: "label";
32
- };
33
- export type UserIndicatorType = (typeof UserIndicatorType)[keyof typeof UserIndicatorType];
24
+ export declare enum UserIndicatorPosition {
25
+ Start = "start",
26
+ End = "end"
27
+ }
28
+ export declare enum UserIndicatorType {
29
+ Avatar = "avatar",
30
+ Label = "label"
31
+ }
34
32
  export declare class LiveSelectionData {
35
33
  [userIdHash: string]: Selection;
36
34
  }
@@ -61,14 +61,12 @@ export interface GetUserPermissionsResponse {
61
61
  };
62
62
  };
63
63
  }
64
- export declare const UserPermissionAccessRole: {
65
- readonly EDITOR: "editor";
66
- readonly VIEWER: "viewer";
67
- };
68
- export type UserPermissionAccessRole = (typeof UserPermissionAccessRole)[keyof typeof UserPermissionAccessRole];
69
- export declare const UserPermissionAccessRoleResult: {
70
- readonly DOES_NOT_EXIST: "does_not_exist";
71
- readonly PERMISSION_DENIED: "permission_denied";
72
- readonly SOMETHING_WENT_WRONG: "something_went_wrong";
73
- };
74
- export type UserPermissionAccessRoleResult = (typeof UserPermissionAccessRoleResult)[keyof typeof UserPermissionAccessRoleResult];
64
+ export declare enum UserPermissionAccessRole {
65
+ EDITOR = "editor",
66
+ VIEWER = "viewer"
67
+ }
68
+ export declare enum UserPermissionAccessRoleResult {
69
+ DOES_NOT_EXIST = "does_not_exist",
70
+ PERMISSION_DENIED = "permission_denied",
71
+ SOMETHING_WENT_WRONG = "something_went_wrong"
72
+ }
@@ -125,20 +125,18 @@ export interface VeltAuthProvider {
125
125
  generateToken?: () => Promise<string>;
126
126
  onError?: (err: unknown) => void;
127
127
  }
128
- export declare const RevokeAccessOnType: {
129
- readonly DOCUMENT_UNSET: "document_unset";
130
- readonly USER_LOGOUT: "user_logout";
131
- };
132
- export type RevokeAccessOnType = (typeof RevokeAccessOnType)[keyof typeof RevokeAccessOnType];
133
- export declare const PermissionSource: {
134
- readonly SET_DOCUMENTS: "setDocuments";
135
- readonly IDENTIFY: "identify";
136
- readonly GET_NOTIFICATIONS: "getNotifications";
137
- readonly SET_NOTIFICATIONS: "setNotifications";
138
- readonly REVOKE_ACCESS_ON_USER_LOGOUT: "revokeAccessOnUserLogout";
139
- readonly REVOKE_ACCESS_ON_DOCUMENT_UNSET: "revokeAccessOnDocumentUnset";
140
- };
141
- export type PermissionSource = (typeof PermissionSource)[keyof typeof PermissionSource];
128
+ export declare enum RevokeAccessOnType {
129
+ DOCUMENT_UNSET = "document_unset",
130
+ USER_LOGOUT = "user_logout"
131
+ }
132
+ export declare enum PermissionSource {
133
+ SET_DOCUMENTS = "setDocuments",
134
+ IDENTIFY = "identify",
135
+ GET_NOTIFICATIONS = "getNotifications",
136
+ SET_NOTIFICATIONS = "setNotifications",
137
+ REVOKE_ACCESS_ON_USER_LOGOUT = "revokeAccessOnUserLogout",
138
+ REVOKE_ACCESS_ON_DOCUMENT_UNSET = "revokeAccessOnDocumentUnset"
139
+ }
142
140
  export interface RevokeAccessOn {
143
141
  type: RevokeAccessOnType;
144
142
  revokeOrganizationAccess?: boolean;
@@ -194,13 +192,12 @@ export interface PermissionResolverRequest {
194
192
  requests: PermissionQuery[];
195
193
  };
196
194
  }
197
- export declare const PermissionResourceType: {
198
- readonly FOLDER: "folder";
199
- readonly DOCUMENT: "document";
200
- readonly ORGANIZATION: "organization";
201
- readonly CONTEXT: "context";
202
- };
203
- export type PermissionResourceType = (typeof PermissionResourceType)[keyof typeof PermissionResourceType];
195
+ export declare enum PermissionResourceType {
196
+ FOLDER = "folder",
197
+ DOCUMENT = "document",
198
+ ORGANIZATION = "organization",
199
+ CONTEXT = "context"
200
+ }
204
201
  export interface PermissionQuery {
205
202
  userId: string;
206
203
  resource: {
@@ -1,3 +1,4 @@
1
+ // @ts-nocheck
1
2
  import { Observable } from "rxjs";
2
3
  import { ActivityRecord, ActivitySubscribeConfig, CreateActivityData } from "../data/activity.data.model";
3
4
 
@@ -1,3 +1,4 @@
1
+ // @ts-nocheck
1
2
  export declare class AreaElement {
2
3
  /**
3
4
  * To enable area feature
@@ -1,9 +1,10 @@
1
+ // @ts-nocheck
1
2
  export declare class ArrowElement {
2
3
  /**
3
4
  * To allow arrow in specific elements only
4
5
  * @param elementIds Element ids to be allowed for arrow
5
6
  */
6
- public allowedElementIds: (elementIds: string[]) => void;
7
+ public allowedElementIds: (elementIds: string[]) => any;
7
8
 
8
9
  constructor();
9
10
 
@@ -1,3 +1,4 @@
1
+ // @ts-nocheck
1
2
  import { Observable } from "rxjs";
2
3
  import { AutocompleteData, AutocompleteChipData } from "../data/autocomplete.data.model";
3
4
  export declare class AutocompleteElement {