dont run image preview on mobile (#1527)
This commit is contained in:
parent
746d321dfe
commit
bb065eb408
1 changed files with 8 additions and 4 deletions
|
@ -106,6 +106,7 @@ type Props = {
|
||||||
};
|
};
|
||||||
|
|
||||||
const IS_IOS = platform.isIOS();
|
const IS_IOS = platform.isIOS();
|
||||||
|
const IS_MOBILE = platform.isMobile();
|
||||||
|
|
||||||
const PLUGIN_MAP = {
|
const PLUGIN_MAP = {
|
||||||
eventTracking: eventTracking,
|
eventTracking: eventTracking,
|
||||||
|
@ -397,10 +398,13 @@ export default React.memo<Props>(function VideoJs(props: Props) {
|
||||||
const trimmedPath = response.url.substring(0, response.url.lastIndexOf('/'));
|
const trimmedPath = response.url.substring(0, response.url.lastIndexOf('/'));
|
||||||
const thumbnailPath = trimmedPath + '/stream_sprite.vtt';
|
const thumbnailPath = trimmedPath + '/stream_sprite.vtt';
|
||||||
|
|
||||||
vjsPlayer.vttThumbnails({
|
// disable thumbnails on mobile for now
|
||||||
src: thumbnailPath,
|
if (!IS_MOBILE) {
|
||||||
showTimestamp: true,
|
vjsPlayer.vttThumbnails({
|
||||||
});
|
src: thumbnailPath,
|
||||||
|
showTimestamp: true,
|
||||||
|
});
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
vjsPlayer.src(vjsPlayer.claimSrcOriginal);
|
vjsPlayer.src(vjsPlayer.claimSrcOriginal);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue