@byomakase/omakase-player 0.2.4 → 0.3.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.
- package/dist/api/omakase-player-api.d.ts +4 -0
- package/dist/audio/audio-controller.d.ts +3 -2
- package/dist/common/component.d.ts +2 -2
- package/dist/dom/dom-controller.d.ts +2 -1
- package/dist/omakase-player.cjs.js +36 -36
- package/dist/omakase-player.cjs.js.map +1 -1
- package/dist/omakase-player.d.ts +10 -10
- package/dist/omakase-player.es.js +4608 -4539
- package/dist/omakase-player.es.js.map +1 -1
- package/dist/omakase-player.umd.js +37 -37
- package/dist/omakase-player.umd.js.map +1 -1
- package/dist/subtitles/subtitles-controller.d.ts +2 -2
- package/dist/timeline/audio-track/audio-track-lane-item.d.ts +1 -0
- package/dist/timeline/audio-track/audio-track-lane.d.ts +1 -0
- package/dist/timeline/subtitles/subtitles-lane-item.d.ts +1 -0
- package/dist/timeline/timeline-lane.d.ts +1 -0
- package/dist/timeline/timeline.d.ts +3 -2
- package/dist/types/common.d.ts +3 -3
- package/dist/types/types.d.ts +3 -0
- package/dist/util/object-util.d.ts +1 -0
- package/dist/util/observable-util.d.ts +6 -1
- package/dist/video/video-controller.d.ts +2 -2
- package/package.json +1 -1
|
@@ -74,4 +74,8 @@ export interface OmakasePlayerApi extends Api, OmakaseEventEmitter<OmakasePlayer
|
|
|
74
74
|
* Returns Omakase Player events enumeration
|
|
75
75
|
*/
|
|
76
76
|
get EVENTS(): OmakasePlayerEventsType;
|
|
77
|
+
/***
|
|
78
|
+
* Destroys OmakasePlayer instance and frees up memory
|
|
79
|
+
*/
|
|
80
|
+
destroy(): void;
|
|
77
81
|
}
|
|
@@ -21,12 +21,13 @@
|
|
|
21
21
|
import { AudioApi } from "../api/audio-api";
|
|
22
22
|
import { VideoController } from "../video/video-controller";
|
|
23
23
|
import { Subject } from "rxjs";
|
|
24
|
-
import { AudioEvent } from "../types";
|
|
25
|
-
export declare class AudioController implements AudioApi {
|
|
24
|
+
import { AudioEvent, Destroyable } from "../types";
|
|
25
|
+
export declare class AudioController implements AudioApi, Destroyable {
|
|
26
26
|
protected videoController: VideoController;
|
|
27
27
|
readonly onAudioSwitched$: Subject<AudioEvent>;
|
|
28
28
|
constructor(videoController: VideoController);
|
|
29
29
|
getAudioTracks(): any[];
|
|
30
30
|
getCurrentAudioTrack(): any;
|
|
31
31
|
setAudioTrack(audioTrackId: number): void;
|
|
32
|
+
destroy(): void;
|
|
32
33
|
}
|
|
@@ -21,6 +21,7 @@ import Konva from "konva";
|
|
|
21
21
|
import { Observable, Subject } from "rxjs";
|
|
22
22
|
import { StyleAdapter } from "./style-adapter";
|
|
23
23
|
import { WithOptionalPartial } from "../types/types";
|
|
24
|
+
import { Destroyable } from "../types";
|
|
24
25
|
export interface ComponentConfig<S> {
|
|
25
26
|
style: S;
|
|
26
27
|
}
|
|
@@ -29,12 +30,11 @@ export interface ComponentConfig<S> {
|
|
|
29
30
|
*/
|
|
30
31
|
export type ComponentConfigStyleComposed<T extends ComponentConfig<any>> = WithOptionalPartial<T, 'style'>;
|
|
31
32
|
export declare const composeConfigAndDefault: <T extends ComponentConfig<any>>(config: Partial<ComponentConfigStyleComposed<T>>, configDefault: T) => T;
|
|
32
|
-
export interface Component<C extends ComponentConfig<S>, S, T extends Konva.Node> {
|
|
33
|
+
export interface Component<C extends ComponentConfig<S>, S, T extends Konva.Node> extends Destroyable {
|
|
33
34
|
get style(): S;
|
|
34
35
|
set style(value: Partial<S>);
|
|
35
36
|
initCanvasNode(): T;
|
|
36
37
|
getCanvasNode(): T;
|
|
37
|
-
destroy(): any;
|
|
38
38
|
isInitialized(): boolean;
|
|
39
39
|
}
|
|
40
40
|
export declare abstract class BaseComponent<C extends ComponentConfig<S>, S, T extends Konva.Node> implements Component<C, S, T> {
|
|
@@ -19,7 +19,8 @@
|
|
|
19
19
|
*/
|
|
20
20
|
import { VideoController } from "../video/video-controller";
|
|
21
21
|
import { Timeline } from "../timeline/timeline";
|
|
22
|
-
|
|
22
|
+
import { Destroyable } from "../types";
|
|
23
|
+
export declare class DomController implements Destroyable {
|
|
23
24
|
private readonly _playerHTMLElementId;
|
|
24
25
|
private _videoElement;
|
|
25
26
|
private _timelineElement;
|