@clickview/player 0.0.3 → 0.0.4-rc.1
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/.storybook/main.js +1 -0
- package/.storybook/stories/Base.stories.tsx +6 -5
- package/.storybook/stories/Interactives.stories.tsx +45 -49
- package/.storybook/stories/utils/mock-playerapi.ts +44 -12
- package/dist/en.json +1 -393
- package/dist/libs/analytics/src/interfaces/AnalyticsTypes.d.ts +5 -1
- package/dist/libs/common/src/backbone/utils/LocalStorageHelper.d.ts +58 -0
- package/dist/libs/common/src/react/flight/FlightHelpers.d.ts +2 -1
- package/dist/libs/common/src/react/utils/ArrayHelper.d.ts +17 -1
- package/dist/libs/shared/src/components/actions/ActionButton.d.ts +2 -0
- package/dist/libs/shared/src/components/actions/ActionsDropdown.d.ts +1 -1
- package/dist/libs/shared/src/components/icon-button/IconButton.d.ts +2 -0
- package/dist/libs/shared/src/components/interactive-questions/InteractionLabel.d.ts +20 -0
- package/dist/libs/shared/src/components/popup/Popup.d.ts +2 -0
- package/dist/libs/shared/src/enums/ObjectStatus.d.ts +3 -3
- package/dist/libs/shared/src/enums/UserGroup.d.ts +3 -3
- package/dist/libs/shared/src/enums/UserRole.d.ts +4 -4
- package/dist/libs/shared/src/hooks/UseGrabCursorProps.d.ts +15 -0
- package/dist/libs/shared/src/images/svg/ImportedSvgs.d.ts +3 -1
- package/dist/libs/shared/src/images/svg/objects/index.d.ts +3 -1
- package/dist/libs/shared/src/interfaces/models/Classroom.d.ts +2 -1
- package/dist/libs/shared/src/interfaces/models/Clip.d.ts +4 -1
- package/dist/libs/shared/src/interfaces/models/Config.d.ts +1 -7
- package/dist/libs/shared/src/interfaces/models/Customer.d.ts +1 -2
- package/dist/libs/shared/src/interfaces/models/InteractiveMetadata.d.ts +4 -0
- package/dist/libs/shared/src/interfaces/models/Series.d.ts +3 -0
- package/dist/libs/shared/src/interfaces/models/User.d.ts +12 -37
- package/dist/libs/shared/src/interfaces/models/Video.d.ts +5 -0
- package/dist/libs/shared/src/interfaces/models/interactive-results/StudentAttempt.d.ts +1 -1
- package/dist/libs/shared/src/utils/InteractiveCorrectnessHelper.d.ts +16 -0
- package/dist/player-app.css +45 -2391
- package/dist/player-app.js +122 -5657
- package/dist/projects/player/src/components/collapserator/collapserator.d.ts +2 -0
- package/dist/projects/player/src/components/landing-splash/landing-splash.d.ts +65 -0
- package/dist/projects/player/src/components/landing-splash/metadata/splash-metadata.d.ts +63 -0
- package/dist/projects/player/src/components/landing-splash/metadata/splash-title/splash-title.d.ts +62 -0
- package/dist/projects/player/src/components/landing-splash/metadata/splash-warning/splash-warning.d.ts +60 -0
- package/dist/projects/player/src/components/logo/clickview-logo.d.ts +1 -0
- package/dist/projects/player/src/components/menu/menu.d.ts +16 -0
- package/dist/projects/player/src/components/menu-button/menu-button.d.ts +1 -0
- package/dist/projects/player/src/components/player/player.d.ts +2 -0
- package/dist/projects/player/src/components/subs-caps-button/SubCapsMenuItem.d.ts +52 -0
- package/dist/projects/player/src/components/subs-caps-button/subtitle-search-menu-item.d.ts +54 -0
- package/dist/projects/player/src/components/subs-caps-button/subtitle-size-menu-item.d.ts +53 -0
- package/dist/projects/player/src/components/subtitle-search-button/subtitle-result-menu-item.d.ts +15 -0
- package/dist/projects/player/src/components/subtitle-search-button/subtitle-search-button.d.ts +30 -0
- package/dist/projects/player/src/components/subtitle-search-button/subtitle-search-input.d.ts +27 -0
- package/dist/projects/player/src/components/subtitle-size-button/subtitle-size-button.d.ts +1 -0
- package/dist/projects/player/src/components/text-track-settings/text-track-settings.d.ts +56 -0
- package/dist/projects/player/src/components/thumbnail-display/thumbnail-display.d.ts +1 -0
- package/dist/projects/player/src/interfaces/models/PlaybackObject.d.ts +13 -0
- package/dist/projects/player/src/players/base-player.d.ts +9 -0
- package/dist/projects/player/src/players/interactive-player.d.ts +2 -0
- package/dist/projects/player/src/plugins/chromecast-plugin/chromecast-plugin.d.ts +11 -0
- package/dist/projects/player/src/plugins/chromecast-plugin/components/chromecast-button.d.ts +1 -0
- package/dist/projects/player/src/plugins/chromecast-plugin/session-manager.d.ts +73 -0
- package/dist/projects/player/src/plugins/chromecast-plugin/tech/chromecast-tech-ui/chromecast-tech-ui.d.ts +67 -0
- package/dist/projects/player/src/plugins/chromecast-plugin/tech/chromecast-tech.d.ts +1 -0
- package/dist/projects/player/src/plugins/interactive-plugin/components/seek-bar/interactive-bar-items.d.ts +4 -4
- package/dist/projects/player/src/plugins/interactive-plugin/components/sliding-timepoint/sliding-timepoints.d.ts +1 -0
- package/dist/projects/player/src/plugins/interactive-plugin/components/timepoint/timepoint-component.d.ts +1 -0
- package/dist/projects/player/src/plugins/interactive-plugin/hooks/useInteractiveTrack.d.ts +4 -2
- package/dist/projects/player/src/plugins/interactive-plugin/interactive-plugin.d.ts +1 -0
- package/dist/projects/player/src/plugins/interactive-plugin/utils/helpers.d.ts +1 -1
- package/dist/projects/player/src/plugins/persist-quality-settings-plugin/persist-quality-settings-plugin.d.ts +33 -0
- package/dist/projects/player/src/plugins/persist-subtitle-settings-plugin/persist-subtitle-settings-plugin.d.ts +38 -0
- package/dist/projects/player/src/plugins/whiteboard-mode-plugin/components/drag-handle/drag-handle.d.ts +53 -0
- package/dist/projects/player/src/plugins/whiteboard-mode-plugin/components/drag-targets/drag-targets.d.ts +54 -0
- package/dist/projects/player/src/plugins/whiteboard-mode-plugin/components/whiteboard-mode-button/whiteboard-mode-button.d.ts +23 -0
- package/dist/projects/player/src/plugins/whiteboard-mode-plugin/components/whiteboard-mode-button/whiteboard-mode-menu-item.d.ts +15 -0
- package/dist/projects/player/src/plugins/whiteboard-mode-plugin/contants/WhiteboardSides.d.ts +5 -0
- package/dist/projects/player/src/plugins/whiteboard-mode-plugin/interfaces/WhiteboardSide.d.ts +1 -0
- package/dist/projects/player/src/plugins/whiteboard-mode-plugin/whiteboard-mode-plugin.d.ts +34 -0
- package/dist/projects/player/src/utils/fn.d.ts +30 -0
- package/dist/projects/player/src/utils/local-storage-helper.d.ts +6 -0
- package/dist/projects/player/src/utils/track-helper.d.ts +1 -0
- package/package.json +70 -66
- package/typings/utils/imports.d.ts +1 -1
- package/dist/libs/shared/src/enums/CustomerType.d.ts +0 -11
- package/dist/projects/player/src/plugins/interactive-plugin/components/create-components/create-short-answer.ts/create-short-answer.d.ts +0 -12
- package/dist/projects/player/src/plugins/interactive-plugin/components/incomplete-alert/incomplete-alert.d.ts +0 -2
- package/dist/projects/player/src/plugins/interactive-plugin/components/interactive/create-interaction-buttons.d.ts +0 -13
- package/dist/projects/player/src/plugins/interactive-plugin/components/interactive/useInteractiveTrack.d.ts +0 -20
- package/dist/projects/player/src/plugins/interactive-plugin/components/interactive/view-iteraction-buttons.d.ts +0 -13
- package/dist/projects/player/src/plugins/interactive-plugin/interfaces/CreateInteractionState.d.ts +0 -4
- package/dist/projects/player/src/plugins/interactive-plugin/interfaces/ViewInteractionState.d.ts +0 -3
|
@@ -2,7 +2,13 @@ import { VideoJsPlayer, VideoJsPlayerOptions } from 'video.js';
|
|
|
2
2
|
import 'videojs-contrib-quality-levels';
|
|
3
3
|
import 'projects/player/plugins/progressive-files-plugin/progressive-files-plugin';
|
|
4
4
|
import 'projects/player/plugins/localcache-plugin/localcache-plugin';
|
|
5
|
+
import 'projects/player/plugins/persist-subtitle-settings-plugin/persist-subtitle-settings-plugin';
|
|
6
|
+
import 'projects/player/plugins/persist-quality-settings-plugin/persist-quality-settings-plugin';
|
|
5
7
|
import 'projects/player/plugins/progress-reporter-plugin/progress-reporter-plugin';
|
|
8
|
+
import 'projects/player/plugins/whiteboard-mode-plugin/whiteboard-mode-plugin';
|
|
9
|
+
import 'projects/player/plugins/chromecast-plugin/chromecast-plugin';
|
|
10
|
+
import 'projects/player/components/menu/menu';
|
|
11
|
+
import 'projects/player/components/menu-button/menu-button';
|
|
6
12
|
import 'projects/player/components/time-wrapper/time-wrapper';
|
|
7
13
|
import 'projects/player/components/collapserator/collapserator';
|
|
8
14
|
import 'projects/player/components/chapter-seek-bar/chapter-seek-bar';
|
|
@@ -12,6 +18,7 @@ import 'projects/player/components/chapters-button/chapters-button';
|
|
|
12
18
|
import 'projects/player/components/subs-caps-button/subs-caps-button';
|
|
13
19
|
import 'projects/player/components/quality-selector/quality-button';
|
|
14
20
|
import 'projects/player/components/playback-rate-button/playback-rate-button';
|
|
21
|
+
import 'projects/player/components/text-track-settings/text-track-settings';
|
|
15
22
|
import 'projects/player/components/player/player';
|
|
16
23
|
/**
|
|
17
24
|
* *.scss imports must be relative
|
|
@@ -20,6 +27,7 @@ import '../components/control-bar/control-bar.scss';
|
|
|
20
27
|
import '../components/volume-control/volume-control.scss';
|
|
21
28
|
import '../components/menu/menu.scss';
|
|
22
29
|
import '../components/big-play-button/big-play-button.scss';
|
|
30
|
+
import '../components/text-track-display/text-track-display.scss';
|
|
23
31
|
import { ExternalLinkOptions } from 'projects/player/plugins/open-externally-plugin/interfaces/ExternalLinkOptions';
|
|
24
32
|
import { PlaybackObject } from 'projects/player/interfaces/models/PlaybackObject';
|
|
25
33
|
import { AnalyticsPlayerType, AnalyticsService } from 'projects/player/services/analytics-service';
|
|
@@ -79,6 +87,7 @@ export declare abstract class BasePlayer {
|
|
|
79
87
|
currentTime(time?: number): number | void;
|
|
80
88
|
private bindEventListeners;
|
|
81
89
|
private setupSeekBar;
|
|
90
|
+
private setupSplash;
|
|
82
91
|
protected getSeekBarOptions(): any;
|
|
83
92
|
protected getSeekBarName(): string;
|
|
84
93
|
private configureMenuDimensions;
|
|
@@ -23,6 +23,8 @@ export declare class InteractivePlayer extends BasePlayer {
|
|
|
23
23
|
constructor(id: string | Element, options: InteractivePlayerOptions);
|
|
24
24
|
protected onFlushProgress(events: ProgressEvent[]): void;
|
|
25
25
|
protected additionalSetup(playbackObject: PlaybackObject): Promise<void>;
|
|
26
|
+
private setupUpClipPlugin;
|
|
27
|
+
private setupViewInteractivePlugin;
|
|
26
28
|
protected getSeekBarOptions(): any;
|
|
27
29
|
protected getAnalyticsPlayerType(): AnalyticsPlayerType;
|
|
28
30
|
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import './tech/chromecast-tech';
|
|
2
|
+
import 'projects/player/plugins/chromecast-plugin/components/chromecast-button';
|
|
3
|
+
interface ChromecastPluginOptions {
|
|
4
|
+
title: string;
|
|
5
|
+
}
|
|
6
|
+
declare module 'video.js' {
|
|
7
|
+
interface VideoJsPlayer {
|
|
8
|
+
chromecast(options: ChromecastPluginOptions): void;
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import './chromecast-button.scss';
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
/// <reference types="chromecast-caf-sender" />
|
|
2
|
+
import videojs from 'video.js';
|
|
3
|
+
declare const Component: {
|
|
4
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions, ready?: videojs.Component.ReadyCallback): videojs.Component;
|
|
5
|
+
prototype: videojs.Component;
|
|
6
|
+
getComponent(name: "Button" | "button"): {
|
|
7
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions): videojs.Button;
|
|
8
|
+
prototype: videojs.Button;
|
|
9
|
+
};
|
|
10
|
+
getComponent(name: "ClickableComponent" | "clickablecomponent"): {
|
|
11
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions): videojs.ClickableComponent;
|
|
12
|
+
prototype: videojs.ClickableComponent;
|
|
13
|
+
};
|
|
14
|
+
getComponent(name: "ModalDialog" | "modaldialog"): {
|
|
15
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ModalDialogOptions): videojs.ModalDialog;
|
|
16
|
+
prototype: videojs.ModalDialog;
|
|
17
|
+
};
|
|
18
|
+
getComponent(name: "Menu" | "menu"): {
|
|
19
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.MenuOptions): videojs.Menu;
|
|
20
|
+
prototype: videojs.Menu;
|
|
21
|
+
};
|
|
22
|
+
getComponent(name: "MenuButton" | "menubutton"): {
|
|
23
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.MenuButtonOptions): videojs.MenuButton;
|
|
24
|
+
prototype: videojs.MenuButton;
|
|
25
|
+
};
|
|
26
|
+
getComponent(name: "MenuItem" | "menuitem"): {
|
|
27
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.MenuItemOptions): videojs.MenuItem;
|
|
28
|
+
prototype: videojs.MenuItem;
|
|
29
|
+
};
|
|
30
|
+
getComponent(name: "MouseTimeDisplay" | "mouseTimeDisplay"): {
|
|
31
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions): videojs.MouseTimeDisplay;
|
|
32
|
+
prototype: videojs.MouseTimeDisplay;
|
|
33
|
+
};
|
|
34
|
+
getComponent(name: "Spacer" | "spacer"): {
|
|
35
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions, ready?: videojs.Component.ReadyCallback): videojs.Spacer;
|
|
36
|
+
prototype: videojs.Spacer;
|
|
37
|
+
};
|
|
38
|
+
getComponent(name: "Player" | "player"): {
|
|
39
|
+
new (player: import("video.js").VideoJsPlayer, options?: import("video.js").VideoJsPlayerOptions): import("video.js").VideoJsPlayer;
|
|
40
|
+
prototype: import("video.js").VideoJsPlayer;
|
|
41
|
+
getTagSettings(tag: Element): any;
|
|
42
|
+
};
|
|
43
|
+
getComponent(name: "timeTooltip" | "TimeTooltip"): {
|
|
44
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions): videojs.TimeToolTip;
|
|
45
|
+
prototype: videojs.TimeToolTip;
|
|
46
|
+
};
|
|
47
|
+
getComponent(name: string): any;
|
|
48
|
+
registerComponent(name: string, ComponentToRegister: any): any;
|
|
49
|
+
};
|
|
50
|
+
declare class SessionManagerSingleton extends Component {
|
|
51
|
+
private play;
|
|
52
|
+
private get castConext();
|
|
53
|
+
setOptions(): void;
|
|
54
|
+
remotePlayer: cast.framework.RemotePlayer;
|
|
55
|
+
remotePlayerController: cast.framework.RemotePlayerController;
|
|
56
|
+
get castState(): cast.framework.CastState;
|
|
57
|
+
get castSession(): cast.framework.CastSession;
|
|
58
|
+
isConnected(): boolean;
|
|
59
|
+
/**
|
|
60
|
+
* We inherit from component to get access to events
|
|
61
|
+
* but we don't pass a player in
|
|
62
|
+
*/
|
|
63
|
+
constructor();
|
|
64
|
+
private bindListeners;
|
|
65
|
+
private onIsConnectedChanged;
|
|
66
|
+
dispose(): void;
|
|
67
|
+
private onCastStateChange;
|
|
68
|
+
stopCasting(): void;
|
|
69
|
+
getDeviceName(): string;
|
|
70
|
+
hasAvailableDevices(castState?: cast.framework.CastState): boolean;
|
|
71
|
+
}
|
|
72
|
+
export declare let SessionManager: SessionManagerSingleton;
|
|
73
|
+
export {};
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import videojs from 'video.js';
|
|
2
|
+
import './chromecast-tech-ui.scss';
|
|
3
|
+
declare const Component: {
|
|
4
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions, ready?: videojs.Component.ReadyCallback): videojs.Component;
|
|
5
|
+
prototype: videojs.Component;
|
|
6
|
+
getComponent(name: "Button" | "button"): {
|
|
7
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions): videojs.Button;
|
|
8
|
+
prototype: videojs.Button;
|
|
9
|
+
};
|
|
10
|
+
getComponent(name: "ClickableComponent" | "clickablecomponent"): {
|
|
11
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions): videojs.ClickableComponent;
|
|
12
|
+
prototype: videojs.ClickableComponent;
|
|
13
|
+
};
|
|
14
|
+
getComponent(name: "ModalDialog" | "modaldialog"): {
|
|
15
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ModalDialogOptions): videojs.ModalDialog;
|
|
16
|
+
prototype: videojs.ModalDialog;
|
|
17
|
+
};
|
|
18
|
+
getComponent(name: "Menu" | "menu"): {
|
|
19
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.MenuOptions): videojs.Menu;
|
|
20
|
+
prototype: videojs.Menu;
|
|
21
|
+
};
|
|
22
|
+
getComponent(name: "MenuButton" | "menubutton"): {
|
|
23
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.MenuButtonOptions): videojs.MenuButton;
|
|
24
|
+
prototype: videojs.MenuButton;
|
|
25
|
+
};
|
|
26
|
+
getComponent(name: "MenuItem" | "menuitem"): {
|
|
27
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.MenuItemOptions): videojs.MenuItem;
|
|
28
|
+
prototype: videojs.MenuItem;
|
|
29
|
+
};
|
|
30
|
+
getComponent(name: "MouseTimeDisplay" | "mouseTimeDisplay"): {
|
|
31
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions): videojs.MouseTimeDisplay;
|
|
32
|
+
prototype: videojs.MouseTimeDisplay;
|
|
33
|
+
};
|
|
34
|
+
getComponent(name: "Spacer" | "spacer"): {
|
|
35
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions, ready?: videojs.Component.ReadyCallback): videojs.Spacer;
|
|
36
|
+
prototype: videojs.Spacer;
|
|
37
|
+
};
|
|
38
|
+
getComponent(name: "Player" | "player"): {
|
|
39
|
+
new (player: import("video.js").VideoJsPlayer, options?: import("video.js").VideoJsPlayerOptions): import("video.js").VideoJsPlayer;
|
|
40
|
+
prototype: import("video.js").VideoJsPlayer;
|
|
41
|
+
getTagSettings(tag: Element): any;
|
|
42
|
+
};
|
|
43
|
+
getComponent(name: "timeTooltip" | "TimeTooltip"): {
|
|
44
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions): videojs.TimeToolTip;
|
|
45
|
+
prototype: videojs.TimeToolTip;
|
|
46
|
+
};
|
|
47
|
+
getComponent(name: string): any;
|
|
48
|
+
registerComponent(name: string, ComponentToRegister: any): any;
|
|
49
|
+
};
|
|
50
|
+
export declare class ChromecastTechUi extends Component {
|
|
51
|
+
play(): void;
|
|
52
|
+
private title;
|
|
53
|
+
private poster;
|
|
54
|
+
constructor();
|
|
55
|
+
createEl(): Element;
|
|
56
|
+
setTitle(title: string): void;
|
|
57
|
+
setPoster(poster: string): void;
|
|
58
|
+
private disconnect;
|
|
59
|
+
/**
|
|
60
|
+
* Unfortunately we can't use the traditional way
|
|
61
|
+
* of building out components and click handlers
|
|
62
|
+
* because this component is ultimately detached
|
|
63
|
+
* from the player so much of it's functionality won't work
|
|
64
|
+
*/
|
|
65
|
+
update(): void;
|
|
66
|
+
}
|
|
67
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -4,7 +4,7 @@ import './interactive-bar-items.scss';
|
|
|
4
4
|
declare const Component: {
|
|
5
5
|
new (player: VideoJsPlayer, options?: videojs.ComponentOptions, ready?: videojs.Component.ReadyCallback): videojs.Component;
|
|
6
6
|
prototype: videojs.Component;
|
|
7
|
-
getComponent(name: "
|
|
7
|
+
getComponent(name: "Button" | "button"): {
|
|
8
8
|
new (player: VideoJsPlayer, options?: videojs.ComponentOptions): videojs.Button;
|
|
9
9
|
prototype: videojs.Button;
|
|
10
10
|
};
|
|
@@ -16,7 +16,7 @@ declare const Component: {
|
|
|
16
16
|
new (player: VideoJsPlayer, options?: videojs.ModalDialogOptions): videojs.ModalDialog;
|
|
17
17
|
prototype: videojs.ModalDialog;
|
|
18
18
|
};
|
|
19
|
-
getComponent(name: "
|
|
19
|
+
getComponent(name: "Menu" | "menu"): {
|
|
20
20
|
new (player: VideoJsPlayer, options?: videojs.MenuOptions): videojs.Menu;
|
|
21
21
|
prototype: videojs.Menu;
|
|
22
22
|
};
|
|
@@ -24,7 +24,7 @@ declare const Component: {
|
|
|
24
24
|
new (player: VideoJsPlayer, options?: videojs.MenuButtonOptions): videojs.MenuButton;
|
|
25
25
|
prototype: videojs.MenuButton;
|
|
26
26
|
};
|
|
27
|
-
getComponent(name: "
|
|
27
|
+
getComponent(name: "MenuItem" | "menuitem"): {
|
|
28
28
|
new (player: VideoJsPlayer, options?: videojs.MenuItemOptions): videojs.MenuItem;
|
|
29
29
|
prototype: videojs.MenuItem;
|
|
30
30
|
};
|
|
@@ -36,7 +36,7 @@ declare const Component: {
|
|
|
36
36
|
new (player: VideoJsPlayer, options?: videojs.ComponentOptions, ready?: videojs.Component.ReadyCallback): videojs.Spacer;
|
|
37
37
|
prototype: videojs.Spacer;
|
|
38
38
|
};
|
|
39
|
-
getComponent(name: "
|
|
39
|
+
getComponent(name: "Player" | "player"): {
|
|
40
40
|
new (player: VideoJsPlayer, options?: import("video.js").VideoJsPlayerOptions): VideoJsPlayer;
|
|
41
41
|
prototype: VideoJsPlayer;
|
|
42
42
|
getTagSettings(tag: Element): any;
|
|
@@ -6,6 +6,7 @@ import './sliding-timepoints.scss';
|
|
|
6
6
|
interface SlidingTimepointProps extends Omit<TimepointProps, 'currentIndex'> {
|
|
7
7
|
nextInteraction: Interaction;
|
|
8
8
|
nextInteractionState: InteractionState;
|
|
9
|
+
delayFocus: boolean;
|
|
9
10
|
}
|
|
10
11
|
export declare function SlidingTimepoint(props: SlidingTimepointProps): React.ReactElement;
|
|
11
12
|
export {};
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import { VideoJsPlayer } from 'video.js';
|
|
3
2
|
import { Interactive, Timepoint } from 'libs/shared/interfaces';
|
|
4
3
|
import { InteractiveMode } from 'projects/player/plugins/interactive-plugin/interfaces';
|
|
@@ -7,15 +6,18 @@ interface useInteractiveOptions {
|
|
|
7
6
|
track: TextTrack;
|
|
8
7
|
interactive: Interactive;
|
|
9
8
|
mode: InteractiveMode;
|
|
9
|
+
clipOffset?: number;
|
|
10
10
|
}
|
|
11
11
|
export declare const useInteractiveTrack: (options: useInteractiveOptions) => {
|
|
12
12
|
open: boolean;
|
|
13
|
-
setOpen:
|
|
13
|
+
setOpen: (val: boolean) => void;
|
|
14
|
+
wasOpen: boolean;
|
|
14
15
|
timepoint: Timepoint;
|
|
15
16
|
continueInteractive: () => void;
|
|
16
17
|
updateCue: (oldTimepointId: string, timepointId: string) => void;
|
|
17
18
|
addCue: (timepointId: string) => void;
|
|
18
19
|
removeCue: (visibleAt: number) => void;
|
|
19
20
|
moveTimepoint: (newTime: number) => void;
|
|
21
|
+
getClipOffset: (time: number) => number;
|
|
20
22
|
};
|
|
21
23
|
export {};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const SLIDING_TIME =
|
|
1
|
+
export declare const SLIDING_TIME = 400;
|
|
2
2
|
export declare function isNewId(id: string): boolean;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import videojs, { VideoJsPlayer } from 'video.js';
|
|
2
|
+
declare const Plugin: {
|
|
3
|
+
new (player: VideoJsPlayer, options?: any): videojs.Plugin;
|
|
4
|
+
prototype: videojs.Plugin;
|
|
5
|
+
BASE_PLUGIN_NAME: string;
|
|
6
|
+
deregisterPlugin(name: string): void;
|
|
7
|
+
getPlugin(name: string): any;
|
|
8
|
+
getPluginVersion(name: string): string;
|
|
9
|
+
getPlugins(names?: string[]): {
|
|
10
|
+
[name: string]: videojs.Plugin;
|
|
11
|
+
};
|
|
12
|
+
isBasic(plugin: string | (() => any)): boolean;
|
|
13
|
+
registerPlugin<T, K>(name: string, plugin: (this: VideoJsPlayer, ...options: K[]) => T): (...options: K[]) => T;
|
|
14
|
+
registerPlugin<T_1 extends any>(name: string, plugin: T_1): () => T_1;
|
|
15
|
+
};
|
|
16
|
+
interface PersistQualitySettingsPluginOptions {
|
|
17
|
+
playbackProfile: string;
|
|
18
|
+
playbackProfileLocalCache: string;
|
|
19
|
+
}
|
|
20
|
+
declare class PersistQualitySettingsPlugin extends Plugin {
|
|
21
|
+
private options;
|
|
22
|
+
constructor(player: VideoJsPlayer, options: PersistQualitySettingsPluginOptions);
|
|
23
|
+
private initialize;
|
|
24
|
+
private onQualityLevelsChange;
|
|
25
|
+
private isLocalCacheActive;
|
|
26
|
+
private getStorageKey;
|
|
27
|
+
}
|
|
28
|
+
declare module 'video.js' {
|
|
29
|
+
interface VideoJsPlayer {
|
|
30
|
+
persistQualitySettingsPlugin(options: PersistQualitySettingsPluginOptions): PersistQualitySettingsPlugin;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
export {};
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import videojs, { VideoJsPlayer } from 'video.js';
|
|
2
|
+
import { SubtitleSizes } from 'projects/player/components/text-track-settings/text-track-settings';
|
|
3
|
+
declare const Plugin: {
|
|
4
|
+
new (player: VideoJsPlayer, options?: any): videojs.Plugin;
|
|
5
|
+
prototype: videojs.Plugin;
|
|
6
|
+
BASE_PLUGIN_NAME: string;
|
|
7
|
+
deregisterPlugin(name: string): void;
|
|
8
|
+
getPlugin(name: string): any;
|
|
9
|
+
getPluginVersion(name: string): string;
|
|
10
|
+
getPlugins(names?: string[]): {
|
|
11
|
+
[name: string]: videojs.Plugin;
|
|
12
|
+
};
|
|
13
|
+
isBasic(plugin: string | (() => any)): boolean;
|
|
14
|
+
registerPlugin<T, K>(name: string, plugin: (this: VideoJsPlayer, ...options: K[]) => T): (...options: K[]) => T;
|
|
15
|
+
registerPlugin<T_1 extends any>(name: string, plugin: T_1): () => T_1;
|
|
16
|
+
};
|
|
17
|
+
interface PersistSubtitleSettingsPluginOptions {
|
|
18
|
+
showSubtitles: boolean;
|
|
19
|
+
subtitleSize: SubtitleSizes;
|
|
20
|
+
}
|
|
21
|
+
declare class PersistSubtitleSettingsPlugin extends Plugin {
|
|
22
|
+
private options;
|
|
23
|
+
private trackGuess;
|
|
24
|
+
constructor(player: VideoJsPlayer, options: PersistSubtitleSettingsPluginOptions);
|
|
25
|
+
private initialize;
|
|
26
|
+
private safeGet;
|
|
27
|
+
private onSelectedLanguageChange;
|
|
28
|
+
private bindEventListeners;
|
|
29
|
+
private onChangeSubtitleSize;
|
|
30
|
+
private guessWhichTrack;
|
|
31
|
+
private getLanguageParts;
|
|
32
|
+
}
|
|
33
|
+
declare module 'video.js' {
|
|
34
|
+
interface VideoJsPlayer {
|
|
35
|
+
persistSubtitleSettingsPlugin(options?: PersistSubtitleSettingsPluginOptions): PersistSubtitleSettingsPlugin;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
export {};
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import videojs from 'video.js';
|
|
2
|
+
import './drag-handle.scss';
|
|
3
|
+
declare const Component: {
|
|
4
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions, ready?: videojs.Component.ReadyCallback): videojs.Component;
|
|
5
|
+
prototype: videojs.Component;
|
|
6
|
+
getComponent(name: "Button" | "button"): {
|
|
7
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions): videojs.Button;
|
|
8
|
+
prototype: videojs.Button;
|
|
9
|
+
};
|
|
10
|
+
getComponent(name: "ClickableComponent" | "clickablecomponent"): {
|
|
11
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions): videojs.ClickableComponent;
|
|
12
|
+
prototype: videojs.ClickableComponent;
|
|
13
|
+
};
|
|
14
|
+
getComponent(name: "ModalDialog" | "modaldialog"): {
|
|
15
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ModalDialogOptions): videojs.ModalDialog;
|
|
16
|
+
prototype: videojs.ModalDialog;
|
|
17
|
+
};
|
|
18
|
+
getComponent(name: "Menu" | "menu"): {
|
|
19
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.MenuOptions): videojs.Menu;
|
|
20
|
+
prototype: videojs.Menu;
|
|
21
|
+
};
|
|
22
|
+
getComponent(name: "MenuButton" | "menubutton"): {
|
|
23
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.MenuButtonOptions): videojs.MenuButton;
|
|
24
|
+
prototype: videojs.MenuButton;
|
|
25
|
+
};
|
|
26
|
+
getComponent(name: "MenuItem" | "menuitem"): {
|
|
27
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.MenuItemOptions): videojs.MenuItem;
|
|
28
|
+
prototype: videojs.MenuItem;
|
|
29
|
+
};
|
|
30
|
+
getComponent(name: "MouseTimeDisplay" | "mouseTimeDisplay"): {
|
|
31
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions): videojs.MouseTimeDisplay;
|
|
32
|
+
prototype: videojs.MouseTimeDisplay;
|
|
33
|
+
};
|
|
34
|
+
getComponent(name: "Spacer" | "spacer"): {
|
|
35
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions, ready?: videojs.Component.ReadyCallback): videojs.Spacer;
|
|
36
|
+
prototype: videojs.Spacer;
|
|
37
|
+
};
|
|
38
|
+
getComponent(name: "Player" | "player"): {
|
|
39
|
+
new (player: import("video.js").VideoJsPlayer, options?: import("video.js").VideoJsPlayerOptions): import("video.js").VideoJsPlayer;
|
|
40
|
+
prototype: import("video.js").VideoJsPlayer;
|
|
41
|
+
getTagSettings(tag: Element): any;
|
|
42
|
+
};
|
|
43
|
+
getComponent(name: "timeTooltip" | "TimeTooltip"): {
|
|
44
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.ComponentOptions): videojs.TimeToolTip;
|
|
45
|
+
prototype: videojs.TimeToolTip;
|
|
46
|
+
};
|
|
47
|
+
getComponent(name: string): any;
|
|
48
|
+
registerComponent(name: string, ComponentToRegister: any): any;
|
|
49
|
+
};
|
|
50
|
+
export declare class DragHandle extends Component {
|
|
51
|
+
createEl(): HTMLButtonElement;
|
|
52
|
+
}
|
|
53
|
+
export {};
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import videojs, { VideoJsPlayer } from 'video.js';
|
|
2
|
+
import './drag-targets.scss';
|
|
3
|
+
declare const Component: {
|
|
4
|
+
new (player: VideoJsPlayer, options?: videojs.ComponentOptions, ready?: videojs.Component.ReadyCallback): videojs.Component;
|
|
5
|
+
prototype: videojs.Component;
|
|
6
|
+
getComponent(name: "Button" | "button"): {
|
|
7
|
+
new (player: VideoJsPlayer, options?: videojs.ComponentOptions): videojs.Button;
|
|
8
|
+
prototype: videojs.Button;
|
|
9
|
+
};
|
|
10
|
+
getComponent(name: "ClickableComponent" | "clickablecomponent"): {
|
|
11
|
+
new (player: VideoJsPlayer, options?: videojs.ComponentOptions): videojs.ClickableComponent;
|
|
12
|
+
prototype: videojs.ClickableComponent;
|
|
13
|
+
};
|
|
14
|
+
getComponent(name: "ModalDialog" | "modaldialog"): {
|
|
15
|
+
new (player: VideoJsPlayer, options?: videojs.ModalDialogOptions): videojs.ModalDialog;
|
|
16
|
+
prototype: videojs.ModalDialog;
|
|
17
|
+
};
|
|
18
|
+
getComponent(name: "Menu" | "menu"): {
|
|
19
|
+
new (player: VideoJsPlayer, options?: videojs.MenuOptions): videojs.Menu;
|
|
20
|
+
prototype: videojs.Menu;
|
|
21
|
+
};
|
|
22
|
+
getComponent(name: "MenuButton" | "menubutton"): {
|
|
23
|
+
new (player: VideoJsPlayer, options?: videojs.MenuButtonOptions): videojs.MenuButton;
|
|
24
|
+
prototype: videojs.MenuButton;
|
|
25
|
+
};
|
|
26
|
+
getComponent(name: "MenuItem" | "menuitem"): {
|
|
27
|
+
new (player: VideoJsPlayer, options?: videojs.MenuItemOptions): videojs.MenuItem;
|
|
28
|
+
prototype: videojs.MenuItem;
|
|
29
|
+
};
|
|
30
|
+
getComponent(name: "MouseTimeDisplay" | "mouseTimeDisplay"): {
|
|
31
|
+
new (player: VideoJsPlayer, options?: videojs.ComponentOptions): videojs.MouseTimeDisplay;
|
|
32
|
+
prototype: videojs.MouseTimeDisplay;
|
|
33
|
+
};
|
|
34
|
+
getComponent(name: "Spacer" | "spacer"): {
|
|
35
|
+
new (player: VideoJsPlayer, options?: videojs.ComponentOptions, ready?: videojs.Component.ReadyCallback): videojs.Spacer;
|
|
36
|
+
prototype: videojs.Spacer;
|
|
37
|
+
};
|
|
38
|
+
getComponent(name: "Player" | "player"): {
|
|
39
|
+
new (player: VideoJsPlayer, options?: import("video.js").VideoJsPlayerOptions): VideoJsPlayer;
|
|
40
|
+
prototype: VideoJsPlayer;
|
|
41
|
+
getTagSettings(tag: Element): any;
|
|
42
|
+
};
|
|
43
|
+
getComponent(name: "timeTooltip" | "TimeTooltip"): {
|
|
44
|
+
new (player: VideoJsPlayer, options?: videojs.ComponentOptions): videojs.TimeToolTip;
|
|
45
|
+
prototype: videojs.TimeToolTip;
|
|
46
|
+
};
|
|
47
|
+
getComponent(name: string): any;
|
|
48
|
+
registerComponent(name: string, ComponentToRegister: any): any;
|
|
49
|
+
};
|
|
50
|
+
export declare class DragTargets extends Component {
|
|
51
|
+
constructor(player: VideoJsPlayer, options?: videojs.ComponentOptions);
|
|
52
|
+
private addChildren;
|
|
53
|
+
}
|
|
54
|
+
export {};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { CollapsibleComponent } from 'projects/player/interfaces/CollapsibleComponent';
|
|
2
|
+
import videojs from 'video.js';
|
|
3
|
+
import { WhiteboardModeMenuItem } from './whiteboard-mode-menu-item';
|
|
4
|
+
declare const MenuButton: {
|
|
5
|
+
new (player: import("video.js").VideoJsPlayer, options?: videojs.MenuButtonOptions): videojs.MenuButton;
|
|
6
|
+
prototype: videojs.MenuButton;
|
|
7
|
+
};
|
|
8
|
+
export declare class WhiteboardModeButton extends MenuButton implements CollapsibleComponent {
|
|
9
|
+
createItems(): WhiteboardModeMenuItem[];
|
|
10
|
+
buildWrapperCSSClass(): string;
|
|
11
|
+
/**
|
|
12
|
+
* CollapsibileComponent interface implementation
|
|
13
|
+
* from here onward
|
|
14
|
+
*/
|
|
15
|
+
alwaysCollapsed: boolean;
|
|
16
|
+
isCollapsed: boolean;
|
|
17
|
+
isCollabsible: boolean;
|
|
18
|
+
getCollabsibleName(): string;
|
|
19
|
+
getCollabsibleValue(): string;
|
|
20
|
+
showInCollabsibleMenu(): boolean;
|
|
21
|
+
showCollapsibleMenu(): void;
|
|
22
|
+
}
|
|
23
|
+
export {};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import videojs, { VideoJsPlayer } from 'video.js';
|
|
2
|
+
import { WhiteboardSide } from '../../interfaces/WhiteboardSide';
|
|
3
|
+
declare const MenuItem: {
|
|
4
|
+
new (player: VideoJsPlayer, options?: videojs.MenuItemOptions): videojs.MenuItem;
|
|
5
|
+
prototype: videojs.MenuItem;
|
|
6
|
+
};
|
|
7
|
+
interface WhiteboardModeMenuItemOptions extends videojs.MenuItemOptions {
|
|
8
|
+
side: WhiteboardSide;
|
|
9
|
+
}
|
|
10
|
+
export declare class WhiteboardModeMenuItem extends MenuItem {
|
|
11
|
+
options_: WhiteboardModeMenuItemOptions;
|
|
12
|
+
constructor(player: VideoJsPlayer, options: WhiteboardModeMenuItemOptions);
|
|
13
|
+
handleClick(): void;
|
|
14
|
+
}
|
|
15
|
+
export {};
|
package/dist/projects/player/src/plugins/whiteboard-mode-plugin/interfaces/WhiteboardSide.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare type WhiteboardSide = 'top' | 'bottom' | 'left' | 'right';
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import videojs, { VideoJsPlayer } from 'video.js';
|
|
2
|
+
import { WhiteboardSide } from './interfaces/WhiteboardSide';
|
|
3
|
+
import './whiteboard-mode.scss';
|
|
4
|
+
declare const Plugin: {
|
|
5
|
+
new (player: VideoJsPlayer, options?: any): videojs.Plugin;
|
|
6
|
+
prototype: videojs.Plugin;
|
|
7
|
+
BASE_PLUGIN_NAME: string;
|
|
8
|
+
deregisterPlugin(name: string): void;
|
|
9
|
+
getPlugin(name: string): any;
|
|
10
|
+
getPluginVersion(name: string): string;
|
|
11
|
+
getPlugins(names?: string[]): {
|
|
12
|
+
[name: string]: videojs.Plugin;
|
|
13
|
+
};
|
|
14
|
+
isBasic(plugin: string | (() => any)): boolean;
|
|
15
|
+
registerPlugin<T, K>(name: string, plugin: (this: VideoJsPlayer, ...options: K[]) => T): (...options: K[]) => T;
|
|
16
|
+
registerPlugin<T_1 extends any>(name: string, plugin: T_1): () => T_1;
|
|
17
|
+
};
|
|
18
|
+
declare class WhiteboardModePlugin extends Plugin {
|
|
19
|
+
side: WhiteboardSide;
|
|
20
|
+
private button;
|
|
21
|
+
constructor(player: VideoJsPlayer);
|
|
22
|
+
private initialize;
|
|
23
|
+
private initCollapserator;
|
|
24
|
+
private initDragTargets;
|
|
25
|
+
private initFullscreenListener;
|
|
26
|
+
setWhiteboardMode(side: WhiteboardSide): void;
|
|
27
|
+
private update;
|
|
28
|
+
}
|
|
29
|
+
declare module 'video.js' {
|
|
30
|
+
interface VideoJsPlayer {
|
|
31
|
+
whiteboardModePlugin(): WhiteboardModePlugin;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
export {};
|
|
@@ -12,3 +12,33 @@
|
|
|
12
12
|
* @return {Function}
|
|
13
13
|
*/
|
|
14
14
|
export declare const throttle: (fn: any, wait: any) => any;
|
|
15
|
+
/**
|
|
16
|
+
* Creates a debounced function that delays invoking `func` until after `wait`
|
|
17
|
+
* milliseconds have elapsed since the last time the debounced function was
|
|
18
|
+
* invoked.
|
|
19
|
+
*
|
|
20
|
+
* Inspired by lodash and underscore implementations.
|
|
21
|
+
*
|
|
22
|
+
* @function
|
|
23
|
+
* @param {Function} func
|
|
24
|
+
* The function to wrap with debounce behavior.
|
|
25
|
+
*
|
|
26
|
+
* @param {number} wait
|
|
27
|
+
* The number of milliseconds to wait after the last invocation.
|
|
28
|
+
*
|
|
29
|
+
* @param {boolean} [immediate]
|
|
30
|
+
* Whether or not to invoke the function immediately upon creation.
|
|
31
|
+
*
|
|
32
|
+
* @param {Object} [context=window]
|
|
33
|
+
* The "context" in which the debounced function should debounce. For
|
|
34
|
+
* example, if this function should be tied to a Video.js player,
|
|
35
|
+
* the player can be passed here. Alternatively, defaults to the
|
|
36
|
+
* global `window` object.
|
|
37
|
+
*
|
|
38
|
+
* @return {Function}
|
|
39
|
+
* A debounced function.
|
|
40
|
+
*/
|
|
41
|
+
export declare const debounce: (func: any, wait: any, immediate: any, context?: any) => {
|
|
42
|
+
(...args: any[]): void;
|
|
43
|
+
cancel: () => void;
|
|
44
|
+
};
|
|
@@ -3,5 +3,6 @@ declare type TrackKind = 'metadata' | 'chapters';
|
|
|
3
3
|
declare type TrackLabel = 'interactive' | 'thumbnails' | false;
|
|
4
4
|
export declare const TrackHelper: {
|
|
5
5
|
useTrack(player: VideoJsPlayer, kind: TrackKind, label: TrackLabel, callback: (track: TextTrack) => void): void;
|
|
6
|
+
getCurrentTextTrack(player: VideoJsPlayer): TextTrack;
|
|
6
7
|
};
|
|
7
8
|
export {};
|