cloudinary-video-player 4.1.4-edge.0 → 4.1.4-edge.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/309.min.js +2 -2
- package/dist/526.min.js +3 -3
- package/dist/689.min.js +2 -2
- package/dist/801.min.js +3 -3
- package/dist/adaptive-streaming.js +2 -2
- package/dist/adaptive-streaming.min.js +2 -2
- package/dist/chapters.js +2 -2
- package/dist/chapters.min.js +2 -2
- package/dist/cld-player-core.js +9 -9
- package/dist/cld-player-core.min.js +3 -3
- package/dist/cld-poster-url.js +2 -2
- package/dist/cld-poster-url.min.js +2 -2
- package/dist/cld-video-player.css +5 -2
- package/dist/cld-video-player.js +9 -9
- package/dist/cld-video-player.light.js +9 -9
- package/dist/cld-video-player.light.min.js +3 -3
- package/dist/cld-video-player.min.css +3 -3
- package/dist/cld-video-player.min.js +3 -3
- package/dist/colors.js +2 -2
- package/dist/colors.min.js +2 -2
- package/dist/dash.js +2 -2
- package/dist/dash.min.js +2 -2
- package/dist/debug.js +2 -2
- package/dist/debug.min.js +2 -2
- package/dist/ima.js +2 -2
- package/dist/ima.min.js +2 -2
- package/dist/interaction-areas.js +2 -2
- package/dist/interaction-areas.min.js +2 -2
- package/dist/node_modules_lodash_throttle_js.js +2 -2
- package/dist/player-full.js +9 -9
- package/dist/player-full.min.js +3 -3
- package/dist/player.css +5 -2
- package/dist/player.js +2 -2
- package/dist/player.min.css +3 -3
- package/dist/player.min.js +2 -2
- package/dist/playlist.js +2 -2
- package/dist/playlist.min.js +2 -2
- package/dist/recommendations-overlay.js +2 -2
- package/dist/recommendations-overlay.min.js +2 -2
- package/dist/share.js +2 -2
- package/dist/share.min.js +2 -2
- package/dist/shoppable.js +2 -2
- package/dist/shoppable.min.js +2 -2
- package/dist/utils_fetch-config_js.js +2 -2
- package/dist/utils_schedule_js.js +2 -2
- package/lib/cld-video-player.min.css +3 -3
- package/lib/index2.js +18 -7
- package/lib/player.min.css +3 -3
- package/lib/video-player.js +26 -34
- package/package.json +1 -1
package/lib/video-player.js
CHANGED
|
@@ -561,7 +561,7 @@ class TitleBar extends Component {
|
|
|
561
561
|
const metadataUrl = appendQueryParams(`${urlPrefix}/_applet_/video_service/video_metadata/${deliveryType}/${utf8ToBase64(publicId)}.json`, source.queryParams());
|
|
562
562
|
fetch(metadataUrl, {
|
|
563
563
|
headers: {
|
|
564
|
-
'X-Cld-Video-Player-Version': "4.1.4-edge.
|
|
564
|
+
'X-Cld-Video-Player-Version': "4.1.4-edge.2"
|
|
565
565
|
}
|
|
566
566
|
}).then(response => {
|
|
567
567
|
if (!response.ok) throw new Error(`HTTP ${response.status}`);
|
|
@@ -2906,7 +2906,9 @@ class CloudinaryContext {
|
|
|
2906
2906
|
// Inherit source transformation
|
|
2907
2907
|
const srcTx = options.transformation;
|
|
2908
2908
|
if (srcTx && !isEmpty(srcTx)) {
|
|
2909
|
-
const imageSafeTx = omitVideoOnlyTransformations(srcTx
|
|
2909
|
+
const imageSafeTx = omitVideoOnlyTransformations(srcTx, {
|
|
2910
|
+
keepAutoFormat: true
|
|
2911
|
+
});
|
|
2910
2912
|
const merged = mergeTransformations(posterOptions.transformation || {}, imageSafeTx);
|
|
2911
2913
|
// Remove height when aspect_ratio is set
|
|
2912
2914
|
if (merged.aspect_ratio) {
|
|
@@ -3211,7 +3213,7 @@ class CloudinaryAnalytics {
|
|
|
3211
3213
|
}, {
|
|
3212
3214
|
...(isPlainObject(this.analyticsOptions) ? this.analyticsOptions : {}),
|
|
3213
3215
|
videoPlayerType: 'cloudinary video player',
|
|
3214
|
-
videoPlayerVersion: "4.1.4-edge.
|
|
3216
|
+
videoPlayerVersion: "4.1.4-edge.2"
|
|
3215
3217
|
});
|
|
3216
3218
|
} else if (this.currentVideoMetadata.cloudName !== metadata.cloudName || this.currentVideoMetadata.publicId !== metadata.publicId) {
|
|
3217
3219
|
this.cloudinaryAnalytics.stopManualTracking();
|
|
@@ -4550,7 +4552,7 @@ const getTranscriptionFileUrl = function (urlPrefix, deliveryType, publicId) {
|
|
|
4550
4552
|
function textTracksManager() {
|
|
4551
4553
|
const player = this;
|
|
4552
4554
|
const textTracksData = new WeakMap();
|
|
4553
|
-
let
|
|
4555
|
+
let showingTracks = new Set();
|
|
4554
4556
|
const removeAllTextTracks = () => {
|
|
4555
4557
|
const currentTracks = player.remoteTextTracks();
|
|
4556
4558
|
if (currentTracks) {
|
|
@@ -4694,37 +4696,27 @@ function textTracksManager() {
|
|
|
4694
4696
|
addTextTrack('transcript', textTrackConfig);
|
|
4695
4697
|
}
|
|
4696
4698
|
});
|
|
4697
|
-
|
|
4698
|
-
if (defaultTextTrack) {
|
|
4699
|
-
onChangeActiveTrack(defaultTextTrack);
|
|
4700
|
-
}
|
|
4699
|
+
syncShowingTracks();
|
|
4701
4700
|
};
|
|
4702
|
-
|
|
4703
|
-
|
|
4704
|
-
|
|
4705
|
-
const
|
|
4706
|
-
|
|
4707
|
-
|
|
4708
|
-
|
|
4709
|
-
|
|
4710
|
-
|
|
4711
|
-
selectedTextTrackData.load();
|
|
4712
|
-
}
|
|
4713
|
-
};
|
|
4714
|
-
player.on('texttrackchange', () => {
|
|
4715
|
-
const textTracks = player.textTracks();
|
|
4716
|
-
let newActiveTrack = null;
|
|
4717
|
-
for (let i = 0; i < textTracks.length; i++) {
|
|
4718
|
-
const track = textTracks[i];
|
|
4719
|
-
if (track.mode === 'showing') {
|
|
4720
|
-
newActiveTrack = track;
|
|
4721
|
-
break;
|
|
4701
|
+
|
|
4702
|
+
// Several tracks can show at once (e.g. descriptions + captions), so each one needs its cues loaded
|
|
4703
|
+
const syncShowingTracks = () => {
|
|
4704
|
+
const textTracks = Array.from(player.textTracks());
|
|
4705
|
+
// texttrackchange can fire inside addRemoteTextTrack, before the track's data exists - skip it until then
|
|
4706
|
+
const nowShowing = new Set(textTracks.filter(track => track.mode === 'showing' && textTracksData.has(track)));
|
|
4707
|
+
showingTracks.forEach(track => {
|
|
4708
|
+
if (!nowShowing.has(track)) {
|
|
4709
|
+
textTracksData.get(track)?.abortLoading();
|
|
4722
4710
|
}
|
|
4723
|
-
}
|
|
4724
|
-
|
|
4725
|
-
|
|
4726
|
-
|
|
4727
|
-
|
|
4711
|
+
});
|
|
4712
|
+
nowShowing.forEach(track => {
|
|
4713
|
+
if (!showingTracks.has(track)) {
|
|
4714
|
+
textTracksData.get(track)?.load();
|
|
4715
|
+
}
|
|
4716
|
+
});
|
|
4717
|
+
showingTracks = nowShowing;
|
|
4718
|
+
};
|
|
4719
|
+
player.on('texttrackchange', syncShowingTracks);
|
|
4728
4720
|
return {
|
|
4729
4721
|
removeAllTextTracks,
|
|
4730
4722
|
addTextTracks: function () {
|
|
@@ -5195,7 +5187,7 @@ class VideoPlayer {
|
|
|
5195
5187
|
const analyticsData = getAnalyticsFromPlayerOptions(options);
|
|
5196
5188
|
const analyticsParams = new URLSearchParams(analyticsData).toString();
|
|
5197
5189
|
const baseParams = new URLSearchParams({
|
|
5198
|
-
vpVersion: "4.1.4-edge.
|
|
5190
|
+
vpVersion: "4.1.4-edge.2",
|
|
5199
5191
|
vpInstanceId: this.getVPInstanceId(),
|
|
5200
5192
|
cloudName: options.cloudinary.cloud_name,
|
|
5201
5193
|
...internalAnalyticsMetadata
|