@gcorevideo/player 2.26.7 → 2.26.9
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/core.js +1 -1
- package/dist/index.css +1189 -1189
- package/dist/index.embed.js +1 -0
- package/dist/index.js +2 -1
- package/dist/player.d.ts +18 -2
- package/docs/api/player.md +11 -11
- package/docs/api/player.thumbnails.md +1 -0
- package/docs/api/player.thumbnailspluginsettings.backdropheight.md +11 -0
- package/docs/api/player.thumbnailspluginsettings.backdropmaxopacity.md +11 -0
- package/docs/api/player.thumbnailspluginsettings.backdropminopacity.md +11 -0
- package/docs/api/player.thumbnailspluginsettings.md +154 -9
- package/docs/api/player.thumbnailspluginsettings.spotlightheight.md +11 -0
- package/docs/api/player.thumbnailspluginsettings.sprite.md +11 -0
- package/docs/api/player.thumbnailspluginsettings.vtt.md +13 -0
- package/lib/plugins/thumbnails/Thumbnails.d.ts +18 -2
- package/lib/plugins/thumbnails/Thumbnails.d.ts.map +1 -1
- package/lib/plugins/thumbnails/Thumbnails.js +1 -0
- package/package.json +1 -1
- package/src/plugins/thumbnails/Thumbnails.ts +20 -3
- package/temp/player.api.json +170 -16
- package/tsconfig.tsbuildinfo +1 -1
package/dist/index.embed.js
CHANGED
|
@@ -50695,6 +50695,7 @@ function loadImageDimensions(url) {
|
|
|
50695
50695
|
* 'https://static.gvideo.co/videoplatform/sprites/2675/2452164_3dk4NsRt6vWsffEr.mp4_sprite.jpg',
|
|
50696
50696
|
* },
|
|
50697
50697
|
* })
|
|
50698
|
+
|
|
50698
50699
|
* ```
|
|
50699
50700
|
*/
|
|
50700
50701
|
class Thumbnails extends UICorePlugin {
|
package/dist/index.js
CHANGED
|
@@ -43265,7 +43265,7 @@ class Player {
|
|
|
43265
43265
|
}
|
|
43266
43266
|
}
|
|
43267
43267
|
|
|
43268
|
-
var version$1 = "2.26.
|
|
43268
|
+
var version$1 = "2.26.9";
|
|
43269
43269
|
|
|
43270
43270
|
var packages = {
|
|
43271
43271
|
"node_modules/@clappr/core": {
|
|
@@ -52219,6 +52219,7 @@ const T$1 = 'plugins.thumbnails';
|
|
|
52219
52219
|
* 'https://static.gvideo.co/videoplatform/sprites/2675/2452164_3dk4NsRt6vWsffEr.mp4_sprite.jpg',
|
|
52220
52220
|
* },
|
|
52221
52221
|
* })
|
|
52222
|
+
|
|
52222
52223
|
* ```
|
|
52223
52224
|
*/
|
|
52224
52225
|
class Thumbnails extends UICorePlugin {
|
package/dist/player.d.ts
CHANGED
|
@@ -3103,6 +3103,7 @@ export declare class ClapprStats extends ContainerPlugin {
|
|
|
3103
3103
|
* 'https://static.gvideo.co/videoplatform/sprites/2675/2452164_3dk4NsRt6vWsffEr.mp4_sprite.jpg',
|
|
3104
3104
|
* },
|
|
3105
3105
|
* })
|
|
3106
|
+
|
|
3106
3107
|
* ```
|
|
3107
3108
|
*/
|
|
3108
3109
|
export declare class Thumbnails extends UICorePlugin {
|
|
@@ -3161,15 +3162,30 @@ export declare class ClapprStats extends ContainerPlugin {
|
|
|
3161
3162
|
/**
|
|
3162
3163
|
* Plugin configuration options for the thumbnails plugin.
|
|
3163
3164
|
* @public
|
|
3165
|
+
* @remarks
|
|
3166
|
+
* Example of a VTT file:
|
|
3167
|
+
* ```text
|
|
3168
|
+
* 1
|
|
3169
|
+
* 00:00:00,000 --> 00:00:10,000
|
|
3170
|
+
* 3dk4NsRt6vWsffEr_sprite.jpg#xywh=0,0,100,56
|
|
3171
|
+
*
|
|
3172
|
+
* 2
|
|
3173
|
+
* 00:00:10,000 --> 00:00:20,000
|
|
3174
|
+
* 3dk4NsRt6vWsffEr_sprite.jpg#xywh=100,0,100,56
|
|
3175
|
+
*
|
|
3176
|
+
* ```
|
|
3164
3177
|
*/
|
|
3165
|
-
export declare
|
|
3178
|
+
export declare interface ThumbnailsPluginSettings {
|
|
3166
3179
|
backdropHeight?: number;
|
|
3167
3180
|
backdropMaxOpacity?: number;
|
|
3168
3181
|
backdropMinOpacity?: number;
|
|
3169
3182
|
spotlightHeight?: number;
|
|
3170
3183
|
sprite: string;
|
|
3184
|
+
/**
|
|
3185
|
+
* The VTT file to use for the thumbnails.
|
|
3186
|
+
*/
|
|
3171
3187
|
vtt: string;
|
|
3172
|
-
}
|
|
3188
|
+
}
|
|
3173
3189
|
|
|
3174
3190
|
/**
|
|
3175
3191
|
* Current playback time and total duration of the media.
|
package/docs/api/player.md
CHANGED
|
@@ -699,6 +699,17 @@ Configuration options for the [QualityLevels](./player.qualitylevels.md) plugin.
|
|
|
699
699
|
**_(BETA)_** Plugin settings
|
|
700
700
|
|
|
701
701
|
|
|
702
|
+
</td></tr>
|
|
703
|
+
<tr><td>
|
|
704
|
+
|
|
705
|
+
[ThumbnailsPluginSettings](./player.thumbnailspluginsettings.md)
|
|
706
|
+
|
|
707
|
+
|
|
708
|
+
</td><td>
|
|
709
|
+
|
|
710
|
+
Plugin configuration options for the thumbnails plugin.
|
|
711
|
+
|
|
712
|
+
|
|
702
713
|
</td></tr>
|
|
703
714
|
<tr><td>
|
|
704
715
|
|
|
@@ -1077,17 +1088,6 @@ Built-in media control elements.
|
|
|
1077
1088
|
**_(BETA)_** Callback to send the telemetry record to the storage.
|
|
1078
1089
|
|
|
1079
1090
|
|
|
1080
|
-
</td></tr>
|
|
1081
|
-
<tr><td>
|
|
1082
|
-
|
|
1083
|
-
[ThumbnailsPluginSettings](./player.thumbnailspluginsettings.md)
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
</td><td>
|
|
1087
|
-
|
|
1088
|
-
Plugin configuration options for the thumbnails plugin.
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
1091
|
</td></tr>
|
|
1092
1092
|
<tr><td>
|
|
1093
1093
|
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@gcorevideo/player](./player.md) > [ThumbnailsPluginSettings](./player.thumbnailspluginsettings.md) > [backdropHeight](./player.thumbnailspluginsettings.backdropheight.md)
|
|
4
|
+
|
|
5
|
+
## ThumbnailsPluginSettings.backdropHeight property
|
|
6
|
+
|
|
7
|
+
**Signature:**
|
|
8
|
+
|
|
9
|
+
```typescript
|
|
10
|
+
backdropHeight?: number;
|
|
11
|
+
```
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@gcorevideo/player](./player.md) > [ThumbnailsPluginSettings](./player.thumbnailspluginsettings.md) > [backdropMaxOpacity](./player.thumbnailspluginsettings.backdropmaxopacity.md)
|
|
4
|
+
|
|
5
|
+
## ThumbnailsPluginSettings.backdropMaxOpacity property
|
|
6
|
+
|
|
7
|
+
**Signature:**
|
|
8
|
+
|
|
9
|
+
```typescript
|
|
10
|
+
backdropMaxOpacity?: number;
|
|
11
|
+
```
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@gcorevideo/player](./player.md) > [ThumbnailsPluginSettings](./player.thumbnailspluginsettings.md) > [backdropMinOpacity](./player.thumbnailspluginsettings.backdropminopacity.md)
|
|
4
|
+
|
|
5
|
+
## ThumbnailsPluginSettings.backdropMinOpacity property
|
|
6
|
+
|
|
7
|
+
**Signature:**
|
|
8
|
+
|
|
9
|
+
```typescript
|
|
10
|
+
backdropMinOpacity?: number;
|
|
11
|
+
```
|
|
@@ -2,19 +2,164 @@
|
|
|
2
2
|
|
|
3
3
|
[Home](./index.md) > [@gcorevideo/player](./player.md) > [ThumbnailsPluginSettings](./player.thumbnailspluginsettings.md)
|
|
4
4
|
|
|
5
|
-
## ThumbnailsPluginSettings
|
|
5
|
+
## ThumbnailsPluginSettings interface
|
|
6
6
|
|
|
7
7
|
Plugin configuration options for the thumbnails plugin.
|
|
8
8
|
|
|
9
9
|
**Signature:**
|
|
10
10
|
|
|
11
11
|
```typescript
|
|
12
|
-
export
|
|
13
|
-
backdropHeight?: number;
|
|
14
|
-
backdropMaxOpacity?: number;
|
|
15
|
-
backdropMinOpacity?: number;
|
|
16
|
-
spotlightHeight?: number;
|
|
17
|
-
sprite: string;
|
|
18
|
-
vtt: string;
|
|
19
|
-
};
|
|
12
|
+
export interface ThumbnailsPluginSettings
|
|
20
13
|
```
|
|
14
|
+
|
|
15
|
+
## Remarks
|
|
16
|
+
|
|
17
|
+
Example of a VTT file:
|
|
18
|
+
|
|
19
|
+
```text
|
|
20
|
+
1
|
|
21
|
+
00:00:00,000 --> 00:00:10,000
|
|
22
|
+
3dk4NsRt6vWsffEr_sprite.jpg#xywh=0,0,100,56
|
|
23
|
+
|
|
24
|
+
2
|
|
25
|
+
00:00:10,000 --> 00:00:20,000
|
|
26
|
+
3dk4NsRt6vWsffEr_sprite.jpg#xywh=100,0,100,56
|
|
27
|
+
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
## Properties
|
|
31
|
+
|
|
32
|
+
<table><thead><tr><th>
|
|
33
|
+
|
|
34
|
+
Property
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
</th><th>
|
|
38
|
+
|
|
39
|
+
Modifiers
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
</th><th>
|
|
43
|
+
|
|
44
|
+
Type
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
</th><th>
|
|
48
|
+
|
|
49
|
+
Description
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
</th></tr></thead>
|
|
53
|
+
<tbody><tr><td>
|
|
54
|
+
|
|
55
|
+
[backdropHeight?](./player.thumbnailspluginsettings.backdropheight.md)
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
</td><td>
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
</td><td>
|
|
62
|
+
|
|
63
|
+
number
|
|
64
|
+
|
|
65
|
+
|
|
66
|
+
</td><td>
|
|
67
|
+
|
|
68
|
+
_(Optional)_
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
</td></tr>
|
|
72
|
+
<tr><td>
|
|
73
|
+
|
|
74
|
+
[backdropMaxOpacity?](./player.thumbnailspluginsettings.backdropmaxopacity.md)
|
|
75
|
+
|
|
76
|
+
|
|
77
|
+
</td><td>
|
|
78
|
+
|
|
79
|
+
|
|
80
|
+
</td><td>
|
|
81
|
+
|
|
82
|
+
number
|
|
83
|
+
|
|
84
|
+
|
|
85
|
+
</td><td>
|
|
86
|
+
|
|
87
|
+
_(Optional)_
|
|
88
|
+
|
|
89
|
+
|
|
90
|
+
</td></tr>
|
|
91
|
+
<tr><td>
|
|
92
|
+
|
|
93
|
+
[backdropMinOpacity?](./player.thumbnailspluginsettings.backdropminopacity.md)
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
</td><td>
|
|
97
|
+
|
|
98
|
+
|
|
99
|
+
</td><td>
|
|
100
|
+
|
|
101
|
+
number
|
|
102
|
+
|
|
103
|
+
|
|
104
|
+
</td><td>
|
|
105
|
+
|
|
106
|
+
_(Optional)_
|
|
107
|
+
|
|
108
|
+
|
|
109
|
+
</td></tr>
|
|
110
|
+
<tr><td>
|
|
111
|
+
|
|
112
|
+
[spotlightHeight?](./player.thumbnailspluginsettings.spotlightheight.md)
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
</td><td>
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
</td><td>
|
|
119
|
+
|
|
120
|
+
number
|
|
121
|
+
|
|
122
|
+
|
|
123
|
+
</td><td>
|
|
124
|
+
|
|
125
|
+
_(Optional)_
|
|
126
|
+
|
|
127
|
+
|
|
128
|
+
</td></tr>
|
|
129
|
+
<tr><td>
|
|
130
|
+
|
|
131
|
+
[sprite](./player.thumbnailspluginsettings.sprite.md)
|
|
132
|
+
|
|
133
|
+
|
|
134
|
+
</td><td>
|
|
135
|
+
|
|
136
|
+
|
|
137
|
+
</td><td>
|
|
138
|
+
|
|
139
|
+
string
|
|
140
|
+
|
|
141
|
+
|
|
142
|
+
</td><td>
|
|
143
|
+
|
|
144
|
+
|
|
145
|
+
</td></tr>
|
|
146
|
+
<tr><td>
|
|
147
|
+
|
|
148
|
+
[vtt](./player.thumbnailspluginsettings.vtt.md)
|
|
149
|
+
|
|
150
|
+
|
|
151
|
+
</td><td>
|
|
152
|
+
|
|
153
|
+
|
|
154
|
+
</td><td>
|
|
155
|
+
|
|
156
|
+
string
|
|
157
|
+
|
|
158
|
+
|
|
159
|
+
</td><td>
|
|
160
|
+
|
|
161
|
+
The VTT file to use for the thumbnails.
|
|
162
|
+
|
|
163
|
+
|
|
164
|
+
</td></tr>
|
|
165
|
+
</tbody></table>
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@gcorevideo/player](./player.md) > [ThumbnailsPluginSettings](./player.thumbnailspluginsettings.md) > [spotlightHeight](./player.thumbnailspluginsettings.spotlightheight.md)
|
|
4
|
+
|
|
5
|
+
## ThumbnailsPluginSettings.spotlightHeight property
|
|
6
|
+
|
|
7
|
+
**Signature:**
|
|
8
|
+
|
|
9
|
+
```typescript
|
|
10
|
+
spotlightHeight?: number;
|
|
11
|
+
```
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@gcorevideo/player](./player.md) > [ThumbnailsPluginSettings](./player.thumbnailspluginsettings.md) > [sprite](./player.thumbnailspluginsettings.sprite.md)
|
|
4
|
+
|
|
5
|
+
## ThumbnailsPluginSettings.sprite property
|
|
6
|
+
|
|
7
|
+
**Signature:**
|
|
8
|
+
|
|
9
|
+
```typescript
|
|
10
|
+
sprite: string;
|
|
11
|
+
```
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
2
|
+
|
|
3
|
+
[Home](./index.md) > [@gcorevideo/player](./player.md) > [ThumbnailsPluginSettings](./player.thumbnailspluginsettings.md) > [vtt](./player.thumbnailspluginsettings.vtt.md)
|
|
4
|
+
|
|
5
|
+
## ThumbnailsPluginSettings.vtt property
|
|
6
|
+
|
|
7
|
+
The VTT file to use for the thumbnails.
|
|
8
|
+
|
|
9
|
+
**Signature:**
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
vtt: string;
|
|
13
|
+
```
|
|
@@ -3,15 +3,30 @@ import '../../../assets/thumbnails/style.scss';
|
|
|
3
3
|
/**
|
|
4
4
|
* Plugin configuration options for the thumbnails plugin.
|
|
5
5
|
* @public
|
|
6
|
+
* @remarks
|
|
7
|
+
* Example of a VTT file:
|
|
8
|
+
* ```text
|
|
9
|
+
* 1
|
|
10
|
+
* 00:00:00,000 --> 00:00:10,000
|
|
11
|
+
* 3dk4NsRt6vWsffEr_sprite.jpg#xywh=0,0,100,56
|
|
12
|
+
*
|
|
13
|
+
* 2
|
|
14
|
+
* 00:00:10,000 --> 00:00:20,000
|
|
15
|
+
* 3dk4NsRt6vWsffEr_sprite.jpg#xywh=100,0,100,56
|
|
16
|
+
*
|
|
17
|
+
* ```
|
|
6
18
|
*/
|
|
7
|
-
export
|
|
19
|
+
export interface ThumbnailsPluginSettings {
|
|
8
20
|
backdropHeight?: number;
|
|
9
21
|
backdropMaxOpacity?: number;
|
|
10
22
|
backdropMinOpacity?: number;
|
|
11
23
|
spotlightHeight?: number;
|
|
12
24
|
sprite: string;
|
|
25
|
+
/**
|
|
26
|
+
* The VTT file to use for the thumbnails.
|
|
27
|
+
*/
|
|
13
28
|
vtt: string;
|
|
14
|
-
}
|
|
29
|
+
}
|
|
15
30
|
/**
|
|
16
31
|
* `PLUGIN` that displays the thumbnails of the video when available.
|
|
17
32
|
* @public
|
|
@@ -38,6 +53,7 @@ export type ThumbnailsPluginSettings = {
|
|
|
38
53
|
* 'https://static.gvideo.co/videoplatform/sprites/2675/2452164_3dk4NsRt6vWsffEr.mp4_sprite.jpg',
|
|
39
54
|
* },
|
|
40
55
|
* })
|
|
56
|
+
|
|
41
57
|
* ```
|
|
42
58
|
*/
|
|
43
59
|
export declare class Thumbnails extends UICorePlugin {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Thumbnails.d.ts","sourceRoot":"","sources":["../../../src/plugins/thumbnails/Thumbnails.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,YAAY,EAKZ,IAAI,EACL,MAAM,cAAc,CAAA;AAUrB,OAAO,uCAAuC,CAAA;AAM9C
|
|
1
|
+
{"version":3,"file":"Thumbnails.d.ts","sourceRoot":"","sources":["../../../src/plugins/thumbnails/Thumbnails.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,YAAY,EAKZ,IAAI,EACL,MAAM,cAAc,CAAA;AAUrB,OAAO,uCAAuC,CAAA;AAM9C;;;;;;;;;;;;;;;GAeG;AACH,MAAM,WAAW,wBAAwB;IACvC,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAC3B,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAC3B,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,MAAM,EAAE,MAAM,CAAA;IACd;;OAEG;IACH,GAAG,EAAE,MAAM,CAAA;CACZ;AAeD;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AACH,qBAAa,UAAW,SAAQ,YAAY;IAC1C,OAAO,CAAC,qBAAqB,CAAoB;IAEjD,OAAO,CAAC,iBAAiB,CAAY;IAErC,OAAO,CAAC,gBAAgB,CAAY;IAEpC,OAAO,CAAC,aAAa,CAAI;IAEzB,OAAO,CAAC,OAAO,CAAQ;IAEvB,OAAO,CAAC,YAAY,CAAQ;IAE5B,OAAO,CAAC,eAAe,CAAI;IAE3B,OAAO,CAAC,cAAc,CAAI;IAE1B,OAAO,CAAC,MAAM,CAAsB;IAEpC;;OAEG;IACH,IAAI,IAAI,WAEP;IAED;;OAEG;IACH,IAAI,gBAAgB;;MAEnB;IAED;;OAEG;IACH,IAAa,UAAU;;MAItB;IAED,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,QAAQ,CAAuB;gBAE3C,IAAI,EAAE,IAAI;IAgBtB,OAAO,CAAC,iBAAiB;IAiCzB;;OAEG;IACM,UAAU;IAInB,OAAO,CAAC,mBAAmB;IAI3B,OAAO,CAAC,WAAW;YAmDL,eAAe;IAO7B,OAAO,CAAC,kBAAkB;IAI1B,OAAO,CAAC,IAAI;IAaZ,OAAO,CAAC,KAAK;IAMb,OAAO,CAAC,kBAAkB;IAM1B,OAAO,CAAC,YAAY;IAOpB,OAAO,CAAC,eAAe;IAwBvB,OAAO,CAAC,YAAY;IAkBpB,OAAO,CAAC,OAAO;IAUf,OAAO,CAAC,cAAc;IAuEtB,OAAO,CAAC,oBAAoB;IAiD5B,OAAO,CAAC,oBAAoB;IAa5B,OAAO,CAAC,MAAM;IAad,OAAO,CAAC,WAAW;IAgBnB,OAAO,KAAK,YAAY,GAMvB;IAEQ,MAAM;CAShB"}
|
package/package.json
CHANGED
|
@@ -24,13 +24,28 @@ import { loadImageDimensions } from './utils.js'
|
|
|
24
24
|
/**
|
|
25
25
|
* Plugin configuration options for the thumbnails plugin.
|
|
26
26
|
* @public
|
|
27
|
+
* @remarks
|
|
28
|
+
* Example of a VTT file:
|
|
29
|
+
* ```text
|
|
30
|
+
* 1
|
|
31
|
+
* 00:00:00,000 --> 00:00:10,000
|
|
32
|
+
* 3dk4NsRt6vWsffEr_sprite.jpg#xywh=0,0,100,56
|
|
33
|
+
*
|
|
34
|
+
* 2
|
|
35
|
+
* 00:00:10,000 --> 00:00:20,000
|
|
36
|
+
* 3dk4NsRt6vWsffEr_sprite.jpg#xywh=100,0,100,56
|
|
37
|
+
*
|
|
38
|
+
* ```
|
|
27
39
|
*/
|
|
28
|
-
export
|
|
40
|
+
export interface ThumbnailsPluginSettings {
|
|
29
41
|
backdropHeight?: number
|
|
30
42
|
backdropMaxOpacity?: number
|
|
31
43
|
backdropMinOpacity?: number
|
|
32
44
|
spotlightHeight?: number
|
|
33
45
|
sprite: string
|
|
46
|
+
/**
|
|
47
|
+
* The VTT file to use for the thumbnails.
|
|
48
|
+
*/
|
|
34
49
|
vtt: string
|
|
35
50
|
}
|
|
36
51
|
|
|
@@ -73,6 +88,7 @@ const T = 'plugins.thumbnails'
|
|
|
73
88
|
* 'https://static.gvideo.co/videoplatform/sprites/2675/2452164_3dk4NsRt6vWsffEr.mp4_sprite.jpg',
|
|
74
89
|
* },
|
|
75
90
|
* })
|
|
91
|
+
|
|
76
92
|
* ```
|
|
77
93
|
*/
|
|
78
94
|
export class Thumbnails extends UICorePlugin {
|
|
@@ -257,7 +273,7 @@ export class Thumbnails extends UICorePlugin {
|
|
|
257
273
|
private mount() {
|
|
258
274
|
const mediaControl = this.core.getPlugin('media_control') as MediaControl
|
|
259
275
|
mediaControl.$el.find('.seek-time').css('bottom', 56) // TODO check the offset
|
|
260
|
-
mediaControl.$el.first().after(this.$el)
|
|
276
|
+
mediaControl.$el.first().after(this.$el)
|
|
261
277
|
}
|
|
262
278
|
|
|
263
279
|
private onMouseMoveSeekbar(_: MouseEvent, pos: number) {
|
|
@@ -279,7 +295,8 @@ export class Thumbnails extends UICorePlugin {
|
|
|
279
295
|
$ref?: ZeptoResult,
|
|
280
296
|
) {
|
|
281
297
|
const scaleFactor = height / thumb.h
|
|
282
|
-
const $container =
|
|
298
|
+
const $container =
|
|
299
|
+
$ref && $ref.length ? $ref : $('<div />').addClass('thumbnail-container')
|
|
283
300
|
|
|
284
301
|
$container.css('width', thumb.w * scaleFactor)
|
|
285
302
|
$container.css('height', height)
|