@eluvio/elv-player-js 2.1.5 → 2.1.7

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.
@@ -97,6 +97,7 @@
97
97
  animation: 0.5s fadein ease;
98
98
  bottom: 100%;
99
99
  color: transparent;
100
+ display: flex;
100
101
  opacity: 0;
101
102
  pointer-events: none;
102
103
  position: absolute;
@@ -108,6 +109,19 @@
108
109
  opacity: 1;
109
110
  }
110
111
 
112
+ &__time {
113
+ background: rgba(0, 0, 0, 50%);
114
+ border-radius: 5px;
115
+ bottom: 5px;
116
+ color: white;
117
+ display: block;
118
+ font-size: 14px;
119
+ padding: 5px 10px;
120
+ position: absolute;
121
+ right: 5px;
122
+ z-index: 1;
123
+ }
124
+
111
125
  img {
112
126
  border-radius: 5px;
113
127
  height: auto;
@@ -2,7 +2,7 @@ import CommonStyles from "../static/stylesheets/common.module.scss";
2
2
 
3
3
  // eslint-disable-next-line no-unused-vars
4
4
  import React, {createRef, useEffect, useState} from "react";
5
- import {ACTIONS, SeekSliderKeyDown, VolumeSliderKeydown} from "./Common.js";
5
+ import {ACTIONS, SeekSliderKeyDown, Time, VolumeSliderKeydown} from "./Common.js";
6
6
  import {ObserveVideoBuffer, ObserveVideoTime, RegisterModal} from "./Observers.js";
7
7
  import * as Icons from "../static/icons/Icons.js";
8
8
  import {IconButton} from "./WebControls";
@@ -95,6 +95,7 @@ const Thumbnail = ({player, time, progress, videoState, visible}) => {
95
95
 
96
96
  const thumbnailImage = player.thumbnailHandler.ThumbnailImage(time);
97
97
 
98
+ console.log(videoState, Time(time, videoState.duration))
98
99
  return (
99
100
  <div
100
101
  ref={setRef}
@@ -104,6 +105,9 @@ const Thumbnail = ({player, time, progress, videoState, visible}) => {
104
105
  className={`${CommonStyles["thumbnail"]} ${visible ? CommonStyles["thumbnail--visible"] : ""}`}
105
106
  >
106
107
  <img src={thumbnailImage} alt="Thumbnail" className={CommonStyles["thumbnail__image"]} />
108
+ <div className={CommonStyles["thumbnail__time"]}>
109
+ { Time(time, videoState.duration) }
110
+ </div>
107
111
  </div>
108
112
  );
109
113
  };
@@ -125,7 +129,7 @@ export const SeekBar = ({player, videoState, setRecentUserAction, className=""})
125
129
  const disposeSettingsListener = player.controls.RegisterSettingsListener(() => {
126
130
  if(!player.controls) { return; }
127
131
 
128
- setDVREnabled(player.controls.IsDVREnabled())
132
+ setDVREnabled(player.controls.IsDVREnabled());
129
133
  });
130
134
 
131
135
  return () => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eluvio/elv-player-js",
3
- "version": "2.1.5",
3
+ "version": "2.1.7",
4
4
  "description": "![Eluvio Logo](lib/static/images/Logo.png \"Eluvio Logo\")",
5
5
  "main": "dist/elv-player-js.es.js",
6
6
  "license": "MIT",