@annoto/widget-api 2.10.0-alpha.2 → 3.0.0-alpha.6

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 (94) hide show
  1. package/CHANGELOG.md +43 -0
  2. package/dist/build/api/device-detector.d.ts +12 -0
  3. package/dist/build/api/device-detector.d.ts.map +1 -0
  4. package/dist/build/api/device-detector.js +3 -0
  5. package/dist/build/api/device-detector.js.map +1 -0
  6. package/dist/build/api/index.d.ts +50 -0
  7. package/dist/build/api/index.d.ts.map +1 -0
  8. package/dist/build/api/index.js +18 -0
  9. package/dist/build/api/index.js.map +1 -0
  10. package/dist/build/api/metadata.d.ts +45 -0
  11. package/dist/build/api/metadata.d.ts.map +1 -0
  12. package/dist/build/api/metadata.js +3 -0
  13. package/dist/build/api/metadata.js.map +1 -0
  14. package/dist/build/config/backend.d.ts +11 -0
  15. package/dist/build/config/backend.d.ts.map +1 -0
  16. package/dist/build/config/backend.js +3 -0
  17. package/dist/build/config/backend.js.map +1 -0
  18. package/dist/build/config/features.d.ts +46 -0
  19. package/dist/build/config/features.d.ts.map +1 -0
  20. package/dist/build/config/features.js +3 -0
  21. package/dist/build/config/features.js.map +1 -0
  22. package/dist/build/config/group-details.d.ts +28 -0
  23. package/dist/build/config/group-details.d.ts.map +1 -0
  24. package/dist/build/config/group-details.js +3 -0
  25. package/dist/build/config/group-details.js.map +1 -0
  26. package/dist/build/config/hooks.d.ts +87 -0
  27. package/dist/build/config/hooks.d.ts.map +1 -0
  28. package/dist/build/config/hooks.js +3 -0
  29. package/dist/build/config/hooks.js.map +1 -0
  30. package/dist/build/config/index.d.ts +88 -0
  31. package/dist/build/config/index.d.ts.map +1 -0
  32. package/dist/build/config/index.js +25 -0
  33. package/dist/build/config/index.js.map +1 -0
  34. package/dist/build/config/launch-source.d.ts +10 -0
  35. package/dist/build/config/launch-source.d.ts.map +1 -0
  36. package/dist/build/config/launch-source.js +3 -0
  37. package/dist/build/config/launch-source.js.map +1 -0
  38. package/dist/build/config/media-details.d.ts +28 -0
  39. package/dist/build/config/media-details.d.ts.map +1 -0
  40. package/dist/build/config/media-details.js +3 -0
  41. package/dist/build/config/media-details.js.map +1 -0
  42. package/dist/build/config/timeline.d.ts +30 -0
  43. package/dist/build/config/timeline.d.ts.map +1 -0
  44. package/dist/build/config/timeline.js +3 -0
  45. package/dist/build/config/timeline.js.map +1 -0
  46. package/dist/build/config/ux.d.ts +153 -0
  47. package/dist/build/config/ux.d.ts.map +1 -0
  48. package/dist/build/config/ux.js +3 -0
  49. package/dist/build/config/ux.js.map +1 -0
  50. package/dist/build/config/widget.d.ts +70 -0
  51. package/dist/build/config/widget.d.ts.map +1 -0
  52. package/dist/build/config/widget.js +3 -0
  53. package/dist/build/config/widget.js.map +1 -0
  54. package/dist/build/events/index.d.ts +8 -0
  55. package/dist/build/events/index.d.ts.map +1 -0
  56. package/dist/build/events/index.js +20 -0
  57. package/dist/build/events/index.js.map +1 -0
  58. package/dist/build/events/my-activity.d.ts +48 -0
  59. package/dist/build/events/my-activity.d.ts.map +1 -0
  60. package/dist/build/events/my-activity.js +3 -0
  61. package/dist/build/events/my-activity.js.map +1 -0
  62. package/dist/build/events/stats-event.d.ts +54 -0
  63. package/dist/build/events/stats-event.d.ts.map +1 -0
  64. package/dist/build/events/stats-event.js +28 -0
  65. package/dist/build/events/stats-event.js.map +1 -0
  66. package/dist/build/events/ux-event.d.ts +5 -0
  67. package/dist/build/events/ux-event.d.ts.map +1 -0
  68. package/dist/build/events/ux-event.js +3 -0
  69. package/dist/build/events/ux-event.js.map +1 -0
  70. package/dist/build/events/video-benchmark-event.d.ts +70 -0
  71. package/dist/build/events/video-benchmark-event.d.ts.map +1 -0
  72. package/dist/build/events/video-benchmark-event.js +3 -0
  73. package/dist/build/events/video-benchmark-event.js.map +1 -0
  74. package/dist/build/index.d.ts +22 -0
  75. package/dist/build/index.d.ts.map +1 -0
  76. package/dist/build/index.js +20 -0
  77. package/dist/build/index.js.map +1 -0
  78. package/dist/build/player-adapter/controls-descriptor.d.ts +174 -0
  79. package/dist/build/player-adapter/controls-descriptor.d.ts.map +1 -0
  80. package/dist/build/player-adapter/controls-descriptor.js +7 -0
  81. package/dist/build/player-adapter/controls-descriptor.js.map +1 -0
  82. package/dist/build/player-adapter/index.d.ts +291 -0
  83. package/dist/build/player-adapter/index.d.ts.map +1 -0
  84. package/dist/build/player-adapter/index.js +17 -0
  85. package/dist/build/player-adapter/index.js.map +1 -0
  86. package/dist/build_esm/api/index.d.ts +11 -1
  87. package/dist/build_esm/api/index.d.ts.map +1 -1
  88. package/dist/build_esm/config/hooks.d.ts +18 -2
  89. package/dist/build_esm/config/hooks.d.ts.map +1 -1
  90. package/dist/build_esm/config/ux.d.ts +6 -6
  91. package/dist/build_esm/config/ux.d.ts.map +1 -1
  92. package/dist/tsconfig.module.tsbuildinfo +1 -1
  93. package/dist/tsconfig.tsbuildinfo +1 -1
  94. package/package.json +2 -2
package/CHANGELOG.md CHANGED
@@ -3,6 +3,49 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [3.0.0-alpha.6](https://bitbucket.org/annototeam/annoto/compare/v3.0.0-alpha.5...v3.0.0-alpha.6) (2022-01-06)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * **widget:** fix wistia adaptor side panel func ([673f091](https://bitbucket.org/annototeam/annoto/commits/673f0915a42663eb3d1546c4ea2a4b2bacb81a8d))
12
+
13
+
14
+ ### Features
15
+
16
+ * **widget:** implemented autoplay triggers ([0e932d3](https://bitbucket.org/annototeam/annoto/commits/0e932d3809357eed7c35c59a675325adf036c8e8))
17
+
18
+
19
+
20
+
21
+
22
+ # [3.0.0-alpha.2](https://bitbucket.org/annototeam/annoto/compare/v3.0.0-alpha.1...v3.0.0-alpha.2) (2021-12-19)
23
+
24
+
25
+ ### Features
26
+
27
+ * **widget-api:** added optional setup hook ([3f23f19](https://bitbucket.org/annototeam/annoto/commits/3f23f19c91b599252e438d3101ad2140eb63f0ab))
28
+
29
+
30
+
31
+
32
+
33
+ # [3.0.0-alpha.0](https://bitbucket.org/annototeam/annoto/compare/v2.10.0-alpha.3...v3.0.0-alpha.0) (2021-12-13)
34
+
35
+ **Note:** Version bump only for package @annoto/widget-api
36
+
37
+
38
+
39
+
40
+
41
+ # [2.10.0-alpha.3](https://bitbucket.org/annototeam/annoto/compare/v2.10.0-alpha.2...v2.10.0-alpha.3) (2021-12-08)
42
+
43
+ **Note:** Version bump only for package @annoto/widget-api
44
+
45
+
46
+
47
+
48
+
6
49
  # [2.10.0-alpha.2](https://bitbucket.org/annototeam/annoto/compare/v2.10.0-alpha.1...v2.10.0-alpha.2) (2021-12-08)
7
50
 
8
51
  **Note:** Version bump only for package @annoto/widget-api
@@ -0,0 +1,12 @@
1
+ /**
2
+ * @internal
3
+ */
4
+ export interface IDeviceDetectorApi {
5
+ isSmallScreen(): boolean;
6
+ isPhone(): boolean;
7
+ isTablet(): boolean;
8
+ isDesktop(): boolean;
9
+ isLandscape?(): boolean;
10
+ detect?(): void;
11
+ }
12
+ //# sourceMappingURL=device-detector.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"device-detector.d.ts","sourceRoot":"","sources":["../../../lib/api/device-detector.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,kBAAkB;IAC/B,aAAa,IAAI,OAAO,CAAC;IACzB,OAAO,IAAI,OAAO,CAAC;IACnB,QAAQ,IAAI,OAAO,CAAC;IACpB,SAAS,IAAI,OAAO,CAAC;IACrB,WAAW,CAAC,IAAI,OAAO,CAAC;IACxB,MAAM,CAAC,IAAI,IAAI,CAAC;CACnB"}
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=device-detector.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"device-detector.js","sourceRoot":"","sources":["../../../lib/api/device-detector.ts"],"names":[],"mappings":""}
@@ -0,0 +1,50 @@
1
+ /**
2
+ * @module Api
3
+ */
4
+ import { IConfig } from '../config';
5
+ import { IMetadata } from './metadata';
6
+ export * from './metadata';
7
+ export * from './device-detector';
8
+ export interface IAnnotoApi {
9
+ /**
10
+ * Single Sign On (SSO) user authentication
11
+ * @param token
12
+ */
13
+ auth(token: string): Promise<void>;
14
+ /**
15
+ * Load new application configuration
16
+ * @param config
17
+ */
18
+ load(config: IConfig): Promise<void>;
19
+ /**
20
+ * Destroy single or all the widgets
21
+ * @param index if provided destroy specific widget
22
+ */
23
+ destroy(index?: number): Promise<void>;
24
+ /**
25
+ * Logout current user
26
+ */
27
+ logout(): Promise<void>;
28
+ /**
29
+ * Show single or all the widgets
30
+ * @param index if provided show specific widget
31
+ */
32
+ show(index?: number): Promise<void>;
33
+ /**
34
+ * Hide single or all the widgets
35
+ * @param index if provided hide specific widget
36
+ */
37
+ hide(index?: number): Promise<void>;
38
+ /**
39
+ * get metrics stats
40
+ * @param index widget index, 0 by default
41
+ */
42
+ getMetadata(index?: number): IMetadata;
43
+ /**
44
+ * Get state of the a widget
45
+ * @param index widget index, 0 by default
46
+ */
47
+ getWidgetState(index?: number): WidgetStateType;
48
+ }
49
+ export declare type WidgetStateType = 'open' | 'closed' | 'mini' | 'hidden';
50
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../lib/api/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AACvC,cAAc,YAAY,CAAC;AAC3B,cAAc,mBAAmB,CAAC;AAElC,MAAM,WAAW,UAAU;IACvB;;;OAGG;IACH,IAAI,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACnC;;;OAGG;IACH,IAAI,CAAC,MAAM,EAAE,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACrC;;;OAGG;IACH,OAAO,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACvC;;OAEG;IACH,MAAM,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IACxB;;;OAGG;IACH,IAAI,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACpC;;;OAGG;IACH,IAAI,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACpC;;;OAGG;IACH,WAAW,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACvC;;;OAGG;IACH,cAAc,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,eAAe,CAAC;CACnD;AAED,oBAAY,eAAe,GAAG,MAAM,GAAG,QAAQ,GAAG,MAAM,GAAG,QAAQ,CAAC"}
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+ /**
3
+ * @module Api
4
+ */
5
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
8
+ }) : (function(o, m, k, k2) {
9
+ if (k2 === undefined) k2 = k;
10
+ o[k2] = m[k];
11
+ }));
12
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
13
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
14
+ };
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ __exportStar(require("./metadata"), exports);
17
+ __exportStar(require("./device-detector"), exports);
18
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../lib/api/index.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;AAIH,6CAA2B;AAC3B,oDAAkC"}
@@ -0,0 +1,45 @@
1
+ interface IContentCountersBase {
2
+ rootCount?: number;
3
+ count?: number;
4
+ emotions?: any;
5
+ }
6
+ export interface IContentCounters extends IContentCountersBase {
7
+ emotions?: {
8
+ [key: string]: number;
9
+ };
10
+ }
11
+ export interface ICommentsCounters extends IContentCounters {
12
+ rootCountDiff?: number;
13
+ countDiff?: number;
14
+ }
15
+ export interface IVisibleEmotionData {
16
+ vn: number;
17
+ cn: number;
18
+ rcn: number;
19
+ tvn: number;
20
+ }
21
+ export interface IVisibleCountersData extends IContentCountersBase {
22
+ emotions?: {
23
+ [key: string]: IVisibleEmotionData;
24
+ };
25
+ }
26
+ export interface IThreadMetrics {
27
+ emotionsCount?: number;
28
+ emotionsVotes?: {
29
+ [key: string]: number;
30
+ };
31
+ rating?: number;
32
+ ratingDiff?: number;
33
+ live?: boolean;
34
+ pbResolution?: number;
35
+ createdAt?: Date;
36
+ updatedAt?: Date;
37
+ }
38
+ export interface IMetadata {
39
+ thread: IThreadMetrics;
40
+ comments: ICommentsCounters;
41
+ notes?: IContentCounters;
42
+ visible?: IVisibleCountersData;
43
+ }
44
+ export {};
45
+ //# sourceMappingURL=metadata.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"metadata.d.ts","sourceRoot":"","sources":["../../../lib/api/metadata.ts"],"names":[],"mappings":"AAAA,UAAU,oBAAoB;IAC1B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,GAAG,CAAC;CAClB;AAED,MAAM,WAAW,gBAAiB,SAAQ,oBAAoB;IAC1D,QAAQ,CAAC,EAAE;QACP,CAAC,GAAG,EAAC,MAAM,GAAG,MAAM,CAAC;KACxB,CAAC;CACL;AAED,MAAM,WAAW,iBAAkB,SAAQ,gBAAgB;IACvD,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,SAAS,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,WAAW,mBAAmB;IAChC,EAAE,EAAE,MAAM,CAAC;IACX,EAAE,EAAE,MAAM,CAAC;IACX,GAAG,EAAE,MAAM,CAAC;IACZ,GAAG,EAAE,MAAM,CAAC;CACf;AAED,MAAM,WAAW,oBAAqB,SAAQ,oBAAoB;IAC9D,QAAQ,CAAC,EAAE;QACP,CAAC,GAAG,EAAC,MAAM,GAAG,mBAAmB,CAAC;KACrC,CAAC;CACL;AAED,MAAM,WAAW,cAAc;IAC3B,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,aAAa,CAAC,EAAE;QACZ,CAAC,GAAG,EAAC,MAAM,GAAG,MAAM,CAAC;KACxB,CAAA;IACD,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,SAAS,CAAC,EAAE,IAAI,CAAC;IACjB,SAAS,CAAC,EAAE,IAAI,CAAC;CACpB;AAED,MAAM,WAAW,SAAS;IACtB,MAAM,EAAE,cAAc,CAAC;IACvB,QAAQ,EAAE,iBAAiB,CAAC;IAC5B,KAAK,CAAC,EAAE,gBAAgB,CAAC;IACzB,OAAO,CAAC,EAAE,oBAAoB,CAAC;CAClC"}
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=metadata.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"metadata.js","sourceRoot":"","sources":["../../../lib/api/metadata.ts"],"names":[],"mappings":""}
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Backend domain and api endpoints configuration
3
+ */
4
+ export interface IWidgetBackendOptions {
5
+ domain?: string;
6
+ apiUrl?: string;
7
+ apiV2Url?: string;
8
+ authUrl?: string;
9
+ insightsUrl?: string;
10
+ }
11
+ //# sourceMappingURL=backend.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"backend.d.ts","sourceRoot":"","sources":["../../../lib/config/backend.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,qBAAqB;IAClC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,CAAC;CACxB"}
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=backend.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"backend.js","sourceRoot":"","sources":["../../../lib/config/backend.ts"],"names":[],"mappings":""}
@@ -0,0 +1,46 @@
1
+ export interface IFeatures {
2
+ comments?: ICommentsFeature;
3
+ notes?: INotesFeature;
4
+ voting?: IVotingFeature;
5
+ timeline?: ITimelineFeature;
6
+ /**
7
+ * @internal
8
+ */
9
+ cta?: IFeatureBase;
10
+ /**
11
+ * @internal
12
+ */
13
+ stats?: IFeatureBase;
14
+ }
15
+ export interface IFeatureBase {
16
+ enabled: boolean;
17
+ }
18
+ /**
19
+ * Collaborative public comments
20
+ */
21
+ export interface ICommentsFeature extends IFeatureBase {
22
+ /**
23
+ * * if set to true comments are loaded in read only
24
+ */
25
+ readonly?: boolean;
26
+ }
27
+ /**
28
+ * Private notes
29
+ */
30
+ export interface INotesFeature extends IFeatureBase {
31
+ /**
32
+ * If set to true, private notes are loaded in read only
33
+ */
34
+ readonly?: boolean;
35
+ }
36
+ /**
37
+ * Vote directly on threads via button on the timeline
38
+ */
39
+ export interface IVotingFeature extends IFeatureBase {
40
+ }
41
+ /**
42
+ * Interactive Video timeline
43
+ */
44
+ export interface ITimelineFeature extends IFeatureBase {
45
+ }
46
+ //# sourceMappingURL=features.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"features.d.ts","sourceRoot":"","sources":["../../../lib/config/features.ts"],"names":[],"mappings":"AACA,MAAM,WAAW,SAAS;IACtB,QAAQ,CAAC,EAAE,gBAAgB,CAAC;IAC5B,KAAK,CAAC,EAAE,aAAa,CAAC;IACtB,MAAM,CAAC,EAAE,cAAc,CAAC;IACxB,QAAQ,CAAC,EAAE,gBAAgB,CAAC;IAC5B;;OAEG;IACH,GAAG,CAAC,EAAE,YAAY,CAAC;IACnB;;OAEG;IACH,KAAK,CAAC,EAAE,YAAY,CAAC;CACxB;AAED,MAAM,WAAW,YAAY;IACzB,OAAO,EAAE,OAAO,CAAC;CACpB;AAED;;GAEG;AACH,MAAM,WAAW,gBAAiB,SAAQ,YAAY;IAClD;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;CACtB;AAED;;GAEG;AACH,MAAM,WAAW,aAAc,SAAQ,YAAY;IAC/C;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;CACtB;AAED;;GAEG;AACH,MAAM,WAAW,cAAe,SAAQ,YAAY;CAAI;AAExD;;GAEG;AACH,MAAM,WAAW,gBAAiB,SAAQ,YAAY;CAAI"}
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=features.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"features.js","sourceRoot":"","sources":["../../../lib/config/features.ts"],"names":[],"mappings":""}
@@ -0,0 +1,28 @@
1
+ /**
2
+ * Course/group details
3
+ * If provided the discussions on the media will be categorized by groups
4
+ * allowing private discussions per group for same media
5
+ */
6
+ export interface IGroupDetails {
7
+ /**
8
+ * Unique group identifier
9
+ */
10
+ id: string | number;
11
+ /**
12
+ * Group title
13
+ */
14
+ title: string;
15
+ /**
16
+ * Group description
17
+ */
18
+ description?: string;
19
+ /**
20
+ * Group thumbnail
21
+ */
22
+ thumbnails?: IGroupThumbnails;
23
+ }
24
+ export interface IGroupThumbnails {
25
+ default: string;
26
+ mobile?: string;
27
+ }
28
+ //# sourceMappingURL=group-details.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"group-details.d.ts","sourceRoot":"","sources":["../../../lib/config/group-details.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,MAAM,WAAW,aAAa;IAC1B;;OAEG;IACH,EAAE,EAAE,MAAM,GAAG,MAAM,CAAC;IACpB;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,UAAU,CAAC,EAAE,gBAAgB,CAAC;CACjC;AAED,MAAM,WAAW,gBAAgB;IAC7B,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;CACnB"}
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=group-details.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"group-details.js","sourceRoot":"","sources":["../../../lib/config/group-details.ts"],"names":[],"mappings":""}
@@ -0,0 +1,87 @@
1
+ import { IConfig } from '.';
2
+ import { IMediaDetails } from './media-details';
3
+ /**
4
+ * Callback hooks for triggering actions such as auth and getting info
5
+ */
6
+ export interface IHooks {
7
+ /**
8
+ * Callback that allows to modify the configuration
9
+ * This callback is called when media is ready and it's preferences is loaded from the backend
10
+ * @remarks
11
+ * This is the prefered way of modifying the configuration.
12
+ * The best practice is to keep the widget bootstrap configuration to a minimum.
13
+ *
14
+ * @param params
15
+ * @returns the modified configuration to use instead of the provided config in params
16
+ */
17
+ setup?(params: {
18
+ widgetIndex: number;
19
+ config: IConfig;
20
+ mediaSrc: string;
21
+ }): Promise<IConfig | undefined>;
22
+ /**
23
+ * Callback that allows to enrich details about the played media.
24
+ * If provided the function is called by the widget to obtain additional details about the media.
25
+ * @param details media details obtained from the player
26
+ * @returns additional details about the played media, such as title
27
+ */
28
+ mediaDetails?(params: {
29
+ widgetIndex: number;
30
+ mediaSrc: string;
31
+ details?: IMediaDetails;
32
+ }): IMediaDetails | Promise<IMediaDetails>;
33
+ /**
34
+ * For SSO enabled integrations only.
35
+ * If Provided, Will be called when user triggers Authentication.
36
+ * If not provided a message in the form is shown.
37
+ * @returns If possible the promise should reslove/reject when the auth flow is finished.
38
+ */
39
+ ssoAuthRequestHandle?(): Promise<void> | void;
40
+ /**
41
+ * For SSO enabled integrations only.
42
+ * If Provided, Will be called when user triggers Logout action and "Logout" option will appear in the drawer menu.
43
+ * @returns If possible the promise should reslove/reject when the logout flow is finished.
44
+ */
45
+ logoutRequestHandle?(): Promise<void> | void;
46
+ /**
47
+ * Url to the video page.
48
+ * Useful if Annoto is embedded inside iframe for example.
49
+ * default: window.location.href is used.
50
+ */
51
+ getPageUrl?(): string;
52
+ /**
53
+ * Url to the video page and specific playback time of currentTime.
54
+ * If provided will be used by annoto for email notifications, in the dashboard, etc.
55
+ * @param currentTime current playback time of the player in seconds
56
+ * @param mediaSrc the media source of the player
57
+ */
58
+ getMediaDeepLinkUrl?(params: {
59
+ widgetIndex: number;
60
+ currentTime: number;
61
+ mediaSrc: string;
62
+ }): string;
63
+ /**
64
+ * @internal
65
+ * If people and presence are enabled for the site, this api can be implemented to add invites to one on one meetings
66
+ * @param params
67
+ */
68
+ getOneOnOneSessionInvite?(params: IOneOnOneSessionInviteParams): Promise<IOneOnOneSessionInviteResult> | IOneOnOneSessionInviteResult;
69
+ }
70
+ /**
71
+ * @internal
72
+ */
73
+ export interface IOneOnOneSessionInviteParams {
74
+ authorId: string;
75
+ invitedUserId: string;
76
+ }
77
+ /**
78
+ * @internal
79
+ */
80
+ export interface IOneOnOneSessionInviteResult {
81
+ inviteUrl: string;
82
+ inviteUrlText?: string;
83
+ title?: string;
84
+ message?: string;
85
+ inviteButton?: string;
86
+ }
87
+ //# sourceMappingURL=hooks.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hooks.d.ts","sourceRoot":"","sources":["../../../lib/config/hooks.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,GAAG,CAAC;AAC5B,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAEhD;;GAEG;AACH,MAAM,WAAW,MAAM;IACnB;;;;;;;;;OASG;IACH,KAAK,CAAC,CAAC,MAAM,EAAE;QAAE,WAAW,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,OAAO,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAC;KAAE,GAAG,OAAO,CAAC,OAAO,GAAG,SAAS,CAAC,CAAC;IAC1G;;;;;OAKG;IACH,YAAY,CAAC,CAAC,MAAM,EAAE;QAAE,WAAW,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAC;QAAC,OAAO,CAAC,EAAE,aAAa,CAAC;KAAE,GAAG,aAAa,GAAG,OAAO,CAAC,aAAa,CAAC,CAAC;IACnI;;;;;OAKG;IACH,oBAAoB,CAAC,IAAI,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,CAAC;IAC9C;;;;OAIG;IACH,mBAAmB,CAAC,IAAI,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,CAAC;IAC7C;;;;OAIG;IACH,UAAU,CAAC,IAAI,MAAM,CAAC;IACtB;;;;;OAKG;IACH,mBAAmB,CAAC,CAAC,MAAM,EAAE;QAAE,WAAW,EAAE,MAAM,CAAC;QAAC,WAAW,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAC;KAAE,GAAG,MAAM,CAAC;IACtG;;;;OAIG;IACH,wBAAwB,CAAC,CAAC,MAAM,EAAE,4BAA4B,GAAG,OAAO,CAAC,4BAA4B,CAAC,GAAG,4BAA4B,CAAC;CACzI;AAED;;GAEG;AACH,MAAM,WAAW,4BAA4B;IACzC,QAAQ,EAAE,MAAM,CAAC;IACjB,aAAa,EAAE,MAAM,CAAC;CACzB;AACD;;GAEG;AACH,MAAM,WAAW,4BAA4B;IACzC,SAAS,EAAE,MAAM,CAAC;IAClB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE,MAAM,CAAC;CACzB"}
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=hooks.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hooks.js","sourceRoot":"","sources":["../../../lib/config/hooks.ts"],"names":[],"mappings":""}
@@ -0,0 +1,88 @@
1
+ /**
2
+ * @module Config
3
+ */
4
+ import { IWidgetBackendOptions } from './backend';
5
+ import { IFeatures } from './features';
6
+ import { IGroupDetails } from './group-details';
7
+ import { IHooks } from './hooks';
8
+ import { ILaunchSourceConfig } from './launch-source';
9
+ import { IUx } from './ux';
10
+ import { IWidgetConfig } from './widget';
11
+ export * from './backend';
12
+ export * from './features';
13
+ export * from './group-details';
14
+ export * from './hooks';
15
+ export * from './launch-source';
16
+ export * from './media-details';
17
+ export * from './timeline';
18
+ export * from './ux';
19
+ export * from './widget';
20
+ export interface IConfig<F = IFeatures> {
21
+ /**
22
+ * The client ID key provided by Annoto
23
+ * @remarks
24
+ * If not set, the widget will load in demo mode
25
+ */
26
+ clientId?: string;
27
+ /**
28
+ * Widget configuration settings.
29
+ * @remarks
30
+ * only single widget is supported. the array is for future use.
31
+ */
32
+ widgets: IWidgetConfig<F>[];
33
+ /**
34
+ * Course/group details
35
+ * If provided the discussions on the media will be categorized by groups
36
+ * allowing private discussions per group for same media
37
+ */
38
+ group?: IGroupDetails;
39
+ /**
40
+ * Enable/disable and configure features
41
+ * Modifying the features will override the backend configured features.
42
+ * @remarks
43
+ * If Feature is not enabled on backend it cannot be enabled via this api.
44
+ */
45
+ features?: F;
46
+ /**
47
+ * Configuration options that affect the user experience
48
+ */
49
+ ux?: IUx;
50
+ /**
51
+ * Callback hooks for triggering actions such as auth and getting info
52
+ */
53
+ hooks?: IHooks;
54
+ /**
55
+ * If set to true, the widget will load in demo mode
56
+ */
57
+ demoMode?: boolean;
58
+ /**
59
+ * @internal
60
+ * Demo discussion for the demo mode
61
+ */
62
+ demoDiscussion?: string;
63
+ /**
64
+ * Language code in IETF BCP 47 or ISO/IEC 15897.
65
+ * @default 'en'
66
+ */
67
+ locale?: string;
68
+ /**
69
+ * Launch source credentials for widget integration via proxy domain
70
+ * For example LTI
71
+ */
72
+ launchSource?: ILaunchSourceConfig;
73
+ /**
74
+ * Set the zIndex to appropriate value to make the app visible and not iterfer with other elements.
75
+ * @default 100
76
+ */
77
+ zIndex?: number;
78
+ /**
79
+ * same as zIndex, only for when the player is in fullscreen.
80
+ * @default 100
81
+ */
82
+ fsZIndex?: number;
83
+ /**
84
+ * setup the backend endpoints to override the default
85
+ */
86
+ backend?: IWidgetBackendOptions;
87
+ }
88
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../lib/config/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,qBAAqB,EAAE,MAAM,WAAW,CAAC;AAClD,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AACvC,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AACjC,OAAO,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AACtD,OAAO,EAAE,GAAG,EAAE,MAAM,MAAM,CAAC;AAC3B,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAGzC,cAAc,WAAW,CAAC;AAC1B,cAAc,YAAY,CAAC;AAC3B,cAAc,iBAAiB,CAAC;AAChC,cAAc,SAAS,CAAC;AACxB,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,YAAY,CAAC;AAC3B,cAAc,MAAM,CAAC;AACrB,cAAc,UAAU,CAAC;AAEzB,MAAM,WAAW,OAAO,CAAC,CAAC,GAAG,SAAS;IAClC;;;;OAIG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;;;OAIG;IACH,OAAO,EAAE,aAAa,CAAC,CAAC,CAAC,EAAE,CAAC;IAC5B;;;;OAIG;IACH,KAAK,CAAC,EAAE,aAAa,CAAC;IACtB;;;;;OAKG;IACH,QAAQ,CAAC,EAAE,CAAC,CAAC;IACb;;OAEG;IACH,EAAE,CAAC,EAAE,GAAG,CAAC;IACT;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAA;IACd;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB;;;OAGG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;;OAGG;IACH,YAAY,CAAC,EAAE,mBAAmB,CAAC;IACnC;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;OAEG;IACH,OAAO,CAAC,EAAE,qBAAqB,CAAC;CACnC"}
@@ -0,0 +1,25 @@
1
+ "use strict";
2
+ /**
3
+ * @module Config
4
+ */
5
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
8
+ }) : (function(o, m, k, k2) {
9
+ if (k2 === undefined) k2 = k;
10
+ o[k2] = m[k];
11
+ }));
12
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
13
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
14
+ };
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ __exportStar(require("./backend"), exports);
17
+ __exportStar(require("./features"), exports);
18
+ __exportStar(require("./group-details"), exports);
19
+ __exportStar(require("./hooks"), exports);
20
+ __exportStar(require("./launch-source"), exports);
21
+ __exportStar(require("./media-details"), exports);
22
+ __exportStar(require("./timeline"), exports);
23
+ __exportStar(require("./ux"), exports);
24
+ __exportStar(require("./widget"), exports);
25
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../lib/config/index.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;AAWH,4CAA0B;AAC1B,6CAA2B;AAC3B,kDAAgC;AAChC,0CAAwB;AACxB,kDAAgC;AAChC,kDAAgC;AAChC,6CAA2B;AAC3B,uCAAqB;AACrB,2CAAyB"}
@@ -0,0 +1,10 @@
1
+ /**
2
+ * Launch source credentials for widget integration via proxy domain
3
+ * For example LTI
4
+ */
5
+ export interface ILaunchSourceConfig {
6
+ accessToken?: string;
7
+ consumerKey?: string;
8
+ origin?: string;
9
+ }
10
+ //# sourceMappingURL=launch-source.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"launch-source.d.ts","sourceRoot":"","sources":["../../../lib/config/launch-source.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,WAAW,mBAAmB;IAChC,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,MAAM,CAAC;CACnB"}
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=launch-source.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"launch-source.js","sourceRoot":"","sources":["../../../lib/config/launch-source.ts"],"names":[],"mappings":""}
@@ -0,0 +1,28 @@
1
+ export interface IMediaDetails {
2
+ /**
3
+ * Media Title
4
+ */
5
+ title: string;
6
+ /**
7
+ * If provided will be used as the media identifier instead of obtaining it from the player
8
+ * Can be any unique id string
9
+ */
10
+ id?: string;
11
+ /**
12
+ * Media description
13
+ */
14
+ description?: string;
15
+ /**
16
+ * Media thumbnail
17
+ */
18
+ thumbnails?: IMediaThumbnails;
19
+ /**
20
+ * author name of the media
21
+ */
22
+ authorName?: string;
23
+ }
24
+ export interface IMediaThumbnails {
25
+ default: string;
26
+ mobile?: string;
27
+ }
28
+ //# sourceMappingURL=media-details.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"media-details.d.ts","sourceRoot":"","sources":["../../../lib/config/media-details.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,aAAa;IAC1B;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;;OAGG;IACH,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,UAAU,CAAC,EAAE,gBAAgB,CAAC;IAC9B;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,WAAW,gBAAgB;IAC7B,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;CACnB"}
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=media-details.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"media-details.js","sourceRoot":"","sources":["../../../lib/config/media-details.ts"],"names":[],"mappings":""}