Video.js章节打不开

Video.js Chapter doesn't work

我已经在网上搜索了几天,没有解决办法。我知道 Video.js 曾经存在问题,但 apparently 它已于 2014 年通过 v4.7.0 修复,我是 运行 v4.12.3。我检查了所有内容,但没有发现我的代码有任何问题。字幕有效,但章节根本不显示。

我的 VTT:(chapters.vtt 在 /public/ 目录中)

WEBVTT

Chapter 1
00:00:54.000 --> 00:02:46.000
What did you work on at your previous jobs?

Chapter 2
00:02:59.000 --> 00:04:25.000
When did you get started with programming?

Chapter 3
00:04:30.000 --> 00:05:35.000
What is prototypal inheritance?

Chapter 4
00:05:35.001 --> 00:09:48.000
Why is prototypal inheritance better than classical inheritance in JS?

我已将 MIME 类型添加到 Nginx,并且文件正在正确加载。

我的看法:

<video id="video" class="video-js vjs-default-skin vjs-big-play-centered"
       controls preload="auto" width="640" height="428"
       data-setup='{ "playbackRates": [1, 1.35, 1.5] }'
       poster="...path_here">
       <source src="...path_here" type='video/mp4' />
       <track kind="chapters" src="/chapters.vtt" srclang="en" label="Chapters" default="default">
</video>

<link href="//vjs.zencdn.net/4.12.3/video-js.css" rel="stylesheet">
<script src="//vjs.zencdn.net/4.12.3/video.js"></script>
<script src="/js/plugins/video/videojs.ga.min.js"></script>
<script>
var interviewVideo = videojs('video', {}, function() {
      this.ga(); // load the Analytics plugin
    });
</script>

我试过只有默认,没有默认,章节,章节,VTT 文件中没有章节,VTT 文件中没有小时。什么都没有发生,除非我将其更改为字幕。然后一切正常。

考虑在 github 上开一个问题,但这不是我第一次忽略一些愚蠢的事情。

感谢您的宝贵时间和帮助。

插件有问题:https://github.com/videojs/video.js/issues/2131

如果需要章节,请使用 4.11。