Skip to content

Commit

Permalink
Upgrade to hls.js
Browse files Browse the repository at this point in the history
  • Loading branch information
dqbd committed Oct 10, 2023
1 parent 65cebc6 commit decfc56
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 4 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"cors": "^2.8.5",
"dayjs": "^1.11.7",
"fluent-ffmpeg": "^2.1.2",
"hls.js": "1.1.2",
"hls.js": "^1.4.12",
"knex": "^0.95.5",
"mkdirp": "^1.0.4",
"mysql2": "^2.3.3",
Expand Down
7 changes: 5 additions & 2 deletions src/components/LogStream.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ export function LogStream(props: {
"playing" in playback
? now.add(playback.playing, "millisecond")
: playback.paused
).add(serverDiff, "millisecond")
).add?.(serverDiff, "millisecond")

const currentItem = log.data?.find(
({ timestamp }) => dayjs(timestamp).valueOf() <= displayDate.valueOf()
Expand Down Expand Up @@ -125,7 +125,10 @@ export function LogStream(props: {
})}
{sum !== 0 && <div>Celkem: ... {sum}</div>}
{currentItem.data.paid !== 0 && (
<div>Vrátit: ... {currentItem.data.paid}</div>
<>
<div>Zaplaceno: ... {currentItem.data.paid}</div>
<div>Vrátit: ... {currentItem.data.paid - sum}</div>
</>
)}
</div>
)}
Expand Down
7 changes: 6 additions & 1 deletion yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2513,11 +2513,16 @@ has@^1.0.3:
dependencies:
function-bind "^1.1.1"

hls.js@*, hls.js@1.1.2:
hls.js@*:
version "1.1.2"
resolved "https://registry.yarnpkg.com/hls.js/-/hls.js-1.1.2.tgz#71691e11928e54ead9696bc64b88c1b9914c394d"
integrity sha512-ujditC4vvBmZd00RRNfNPLgFVlqEeUX4sAFv5lGhBHuql8iAZodOdlZTD3em/1zo7vyjQp12up/lCVqQk8dvxA==

hls.js@^1.4.12:
version "1.4.12"
resolved "https://registry.yarnpkg.com/hls.js/-/hls.js-1.4.12.tgz#2022daa29d10c662387d80a5297f8330f8ef5ee2"
integrity sha512-1RBpx2VihibzE3WE9kGoVCtrhhDWTzydzElk/kyRbEOLnb1WIE+3ZabM/L8BqKFTCL3pUy4QzhXgD1Q6Igr1JA==

hoist-non-react-statics@^3.3.1, hoist-non-react-statics@^3.3.2:
version "3.3.2"
resolved "https://registry.yarnpkg.com/hoist-non-react-statics/-/hoist-non-react-statics-3.3.2.tgz#ece0acaf71d62c2969c2ec59feff42a4b1a85b45"
Expand Down

0 comments on commit decfc56

Please sign in to comment.