Skip to content

Commit f3394a6

Browse files
committed
Commit build artifacts dist/* for NPM delivery
Commit build artifacts dist/* for NPM delivery
1 parent 12b35df commit f3394a6

5 files changed

+48
-64
lines changed

dist/videojs-http-source-selector.cjs.js

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -21,27 +21,27 @@ function _assertThisInitialized(self) {
2121
}
2222

2323
var MenuItem = videojs.getComponent('MenuItem');
24+
var Component = videojs.getComponent('Component');
2425

2526
var SourceMenuItem =
2627
/*#__PURE__*/
2728
function (_MenuItem) {
2829
_inheritsLoose(SourceMenuItem, _MenuItem);
2930

3031
function SourceMenuItem(player, options) {
31-
var _this;
32-
33-
_this = _MenuItem.call(this, player, options) || this;
3432
options.selectable = true;
35-
return _this;
33+
options.multiSelectable = false;
34+
return _MenuItem.call(this, player, options) || this;
3635
}
3736

3837
var _proto = SourceMenuItem.prototype;
3938

4039
_proto.handleClick = function handleClick() {
4140
var selected = this.options_;
4241
console.log("Changing quality to:", selected.label);
43-
this.selected_ = true;
44-
this.selected(true);
42+
43+
_MenuItem.prototype.handleClick.call(this);
44+
4545
var levels = this.player().qualityLevels();
4646

4747
for (var i = 0; i < levels.length; i++) {
@@ -57,15 +57,15 @@ function (_MenuItem) {
5757
};
5858

5959
_proto.update = function update() {
60-
var levels = this.player().qualityLevels();
61-
var selection = levels.selectedIndex;
62-
this.selected(this.options_.index == selection);
63-
this.selected_ = this.options_.index === selection;
60+
var selectedIndex = this.player().qualityLevels().selectedIndex;
61+
this.selected(this.options_.index == selectedIndex);
6462
};
6563

6664
return SourceMenuItem;
6765
}(MenuItem);
6866

67+
Component.registerComponent('SourceMenuItem', SourceMenuItem);
68+
6969
var MenuButton = videojs.getComponent('MenuButton');
7070

7171
var SourceMenuButton =
@@ -94,9 +94,10 @@ function (_MenuButton) {
9494
}
9595
}
9696
} // Bind update to qualityLevels changes
97-
//this.player().qualityLevels.on(['change', 'addqualitylevel'], videojs.bind( this, this.update) );
9897

9998

99+
_this.player().qualityLevels().on(['change', 'addqualitylevel'], videojs.bind(_assertThisInitialized(_this), _this.update));
100+
100101
return _this;
101102
}
102103

dist/videojs-http-source-selector.es.js

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -17,27 +17,27 @@ function _assertThisInitialized(self) {
1717
}
1818

1919
var MenuItem = videojs.getComponent('MenuItem');
20+
var Component = videojs.getComponent('Component');
2021

2122
var SourceMenuItem =
2223
/*#__PURE__*/
2324
function (_MenuItem) {
2425
_inheritsLoose(SourceMenuItem, _MenuItem);
2526

2627
function SourceMenuItem(player, options) {
27-
var _this;
28-
29-
_this = _MenuItem.call(this, player, options) || this;
3028
options.selectable = true;
31-
return _this;
29+
options.multiSelectable = false;
30+
return _MenuItem.call(this, player, options) || this;
3231
}
3332

3433
var _proto = SourceMenuItem.prototype;
3534

3635
_proto.handleClick = function handleClick() {
3736
var selected = this.options_;
3837
console.log("Changing quality to:", selected.label);
39-
this.selected_ = true;
40-
this.selected(true);
38+
39+
_MenuItem.prototype.handleClick.call(this);
40+
4141
var levels = this.player().qualityLevels();
4242

4343
for (var i = 0; i < levels.length; i++) {
@@ -53,15 +53,15 @@ function (_MenuItem) {
5353
};
5454

5555
_proto.update = function update() {
56-
var levels = this.player().qualityLevels();
57-
var selection = levels.selectedIndex;
58-
this.selected(this.options_.index == selection);
59-
this.selected_ = this.options_.index === selection;
56+
var selectedIndex = this.player().qualityLevels().selectedIndex;
57+
this.selected(this.options_.index == selectedIndex);
6058
};
6159

6260
return SourceMenuItem;
6361
}(MenuItem);
6462

63+
Component.registerComponent('SourceMenuItem', SourceMenuItem);
64+
6565
var MenuButton = videojs.getComponent('MenuButton');
6666

6767
var SourceMenuButton =
@@ -90,9 +90,10 @@ function (_MenuButton) {
9090
}
9191
}
9292
} // Bind update to qualityLevels changes
93-
//this.player().qualityLevels.on(['change', 'addqualitylevel'], videojs.bind( this, this.update) );
9493

9594

95+
_this.player().qualityLevels().on(['change', 'addqualitylevel'], videojs.bind(_assertThisInitialized(_this), _this.update));
96+
9697
return _this;
9798
}
9899

dist/videojs-http-source-selector.js

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -23,27 +23,27 @@
2323
}
2424

2525
var MenuItem = videojs.getComponent('MenuItem');
26+
var Component = videojs.getComponent('Component');
2627

2728
var SourceMenuItem =
2829
/*#__PURE__*/
2930
function (_MenuItem) {
3031
_inheritsLoose(SourceMenuItem, _MenuItem);
3132

3233
function SourceMenuItem(player, options) {
33-
var _this;
34-
35-
_this = _MenuItem.call(this, player, options) || this;
3634
options.selectable = true;
37-
return _this;
35+
options.multiSelectable = false;
36+
return _MenuItem.call(this, player, options) || this;
3837
}
3938

4039
var _proto = SourceMenuItem.prototype;
4140

4241
_proto.handleClick = function handleClick() {
4342
var selected = this.options_;
4443
console.log("Changing quality to:", selected.label);
45-
this.selected_ = true;
46-
this.selected(true);
44+
45+
_MenuItem.prototype.handleClick.call(this);
46+
4747
var levels = this.player().qualityLevels();
4848

4949
for (var i = 0; i < levels.length; i++) {
@@ -59,15 +59,15 @@
5959
};
6060

6161
_proto.update = function update() {
62-
var levels = this.player().qualityLevels();
63-
var selection = levels.selectedIndex;
64-
this.selected(this.options_.index == selection);
65-
this.selected_ = this.options_.index === selection;
62+
var selectedIndex = this.player().qualityLevels().selectedIndex;
63+
this.selected(this.options_.index == selectedIndex);
6664
};
6765

6866
return SourceMenuItem;
6967
}(MenuItem);
7068

69+
Component.registerComponent('SourceMenuItem', SourceMenuItem);
70+
7171
var MenuButton = videojs.getComponent('MenuButton');
7272

7373
var SourceMenuButton =
@@ -96,9 +96,10 @@
9696
}
9797
}
9898
} // Bind update to qualityLevels changes
99-
//this.player().qualityLevels.on(['change', 'addqualitylevel'], videojs.bind( this, this.update) );
10099

101100

101+
_this.player().qualityLevels().on(['change', 'addqualitylevel'], videojs.bind(_assertThisInitialized(_this), _this.update));
102+
102103
return _this;
103104
}
104105

dist/videojs-http-source-selector.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package-lock.json

Lines changed: 11 additions & 30 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)