bloom-player 2.15.2 → 2.16.0-alpha.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.
- package/dist/{bloomPlayer-DZmRaLMc.css → bloomPlayer-XPqbUuvA.css} +1 -1
- package/dist/{bloomPlayer.B8cIzLLQ.js → bloomPlayer.DULzZOJ6.js} +40 -40
- package/dist/bloomplayer.htm +2 -2
- package/lib/animation.d.ts +50 -0
- package/lib/index.d.ts +1 -0
- package/lib/narration.d.ts +1 -1
- package/lib/shared.es.js +3569 -3294
- package/lib/shared.es.js.map +1 -1
- package/package.json +1 -1
- package/src/shared/index.ts +3 -0
- package/src/shared/narration.ts +24 -8
package/dist/bloomplayer.htm
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
<head>
|
|
8
8
|
<meta charset="UTF-8" />
|
|
9
9
|
<!-- At build time, we replace this with the actual css file -->
|
|
10
|
-
<link rel="stylesheet" href="bloomPlayer-
|
|
10
|
+
<link rel="stylesheet" href="bloomPlayer-XPqbUuvA.css">
|
|
11
11
|
</head>
|
|
12
12
|
|
|
13
13
|
<!-- About the background-color here... the bloomPlayer.js will set the background color
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
|
|
19
19
|
<!-- At build time, we replace the target of this script tag to point at the
|
|
20
20
|
the bloom player bundle with the cache-busting hash in its name. -->
|
|
21
|
-
<script src="bloomPlayer.
|
|
21
|
+
<script src="bloomPlayer.DULzZOJ6.js"></script>
|
|
22
22
|
</body>
|
|
23
23
|
|
|
24
24
|
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
export declare class Animation {
|
|
2
|
+
static pageHasAnimation(page: HTMLDivElement): boolean;
|
|
3
|
+
static getAnimationCanvas(page: HTMLElement): HTMLElement | null;
|
|
4
|
+
static getAnimatableCanvas(page: HTMLElement): HTMLElement;
|
|
5
|
+
private animationEngine;
|
|
6
|
+
PlayAnimations: boolean;
|
|
7
|
+
private currentPage;
|
|
8
|
+
private lastDurationPage;
|
|
9
|
+
private static wrapperClassName;
|
|
10
|
+
private animationDuration;
|
|
11
|
+
constructor();
|
|
12
|
+
HandlePageBeforeVisible(page: HTMLElement): void;
|
|
13
|
+
HandlePageVisible(page: HTMLElement): void;
|
|
14
|
+
HandlePageDurationAvailable(page: HTMLElement, duration: number): void;
|
|
15
|
+
resumeAnimation(): void;
|
|
16
|
+
PauseAnimation(): void;
|
|
17
|
+
PauseOnFirstFrame(): void;
|
|
18
|
+
animatableCanvas: HTMLElement | null;
|
|
19
|
+
private setupAnimation;
|
|
20
|
+
private createAndPlayAnimation;
|
|
21
|
+
private applyCanvasAspectRatioToAnimationWrapper;
|
|
22
|
+
private placeAnimationWrapper;
|
|
23
|
+
private placeCanvasByScale;
|
|
24
|
+
private adjustAnimationWrapper;
|
|
25
|
+
private getAnimationWrapper;
|
|
26
|
+
private removeAnimationWrappers;
|
|
27
|
+
shouldAnimate(page: HTMLElement): boolean;
|
|
28
|
+
}
|
|
29
|
+
export declare class TransformBasedAnimator {
|
|
30
|
+
private initialScale;
|
|
31
|
+
private finalScale;
|
|
32
|
+
private initialLeft;
|
|
33
|
+
private finalLeft;
|
|
34
|
+
private initialTop;
|
|
35
|
+
private finalTop;
|
|
36
|
+
private canvasToAnimate;
|
|
37
|
+
private lastFrameTime;
|
|
38
|
+
private totalElapsedTime;
|
|
39
|
+
private duration;
|
|
40
|
+
private paused;
|
|
41
|
+
constructor(initialRect: string, finalRect: string, duration: number, canvasToAnimate: HTMLElement);
|
|
42
|
+
private getScaleAndPosition;
|
|
43
|
+
private easingFunction;
|
|
44
|
+
private advanceAnimation;
|
|
45
|
+
pause(): void;
|
|
46
|
+
resume(): void;
|
|
47
|
+
startAnimation(): void;
|
|
48
|
+
endAnimation(): void;
|
|
49
|
+
showInitialState(): void;
|
|
50
|
+
}
|
package/lib/index.d.ts
CHANGED
package/lib/narration.d.ts
CHANGED
|
@@ -37,7 +37,7 @@ export declare const PlayCompleted: LiteEvent<HTMLElement>;
|
|
|
37
37
|
export declare const PlayFailed: LiteEvent<HTMLElement>;
|
|
38
38
|
export declare const ToggleImageDescription: LiteEvent<boolean>;
|
|
39
39
|
export declare function setIncludeImageDescriptions(b: boolean): void;
|
|
40
|
-
export declare function playAllSentences(page: HTMLElement | null): void;
|
|
40
|
+
export declare function playAllSentences(page: HTMLElement | null, canvasToExclude?: HTMLElement): void;
|
|
41
41
|
export declare function playAllAudio(elements: HTMLElement[], page: HTMLElement): void;
|
|
42
42
|
export declare function abortNarrationPlayback(): void;
|
|
43
43
|
export declare function pageHasAudio(page: HTMLElement): boolean;
|