Skip to content

Commit

Permalink
fix(player): remove filling slider end gap for now
Browse files Browse the repository at this point in the history
  • Loading branch information
mihar-22 committed Oct 2, 2023
1 parent c983af8 commit 029037b
Showing 1 changed file with 4 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -259,17 +259,10 @@ export class SliderChapters extends Component<SliderChaptersProps> {

chapters.push(cues[cues.length - 1]);

let seenDuration = false;
effect(() => {
if (seenDuration) return;

const { duration } = this._media.$state;
if (Math.abs(cues[cues.length - 1].endTime - duration()) > 1) {
chapters.push(new window.VTTCue(cues[cues.length - 1].endTime, duration(), ''));
}

seenDuration = duration() > 0;
});
// const { duration } = this._media.$state;
// if (Math.abs(cues[cues.length - 1].endTime - duration()) > 1) {
// chapters.push(new window.VTTCue(cues[cues.length - 1].endTime, duration(), ''));
// }

return chapters;
}
Expand Down

0 comments on commit 029037b

Please sign in to comment.