Socket
Socket
Sign inDemoInstall

videojs-contrib-quality-levels

Package Overview
Dependencies
Maintainers
12
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

videojs-contrib-quality-levels - npm Package Compare versions

Comparing version 2.1.0 to 2.2.0

scripts/jsdoc.config.json

23

CHANGELOG.md

@@ -0,1 +1,24 @@

<a name="2.2.0"></a>
# [2.2.0](https://github.com/videojs/videojs-contrib-quality-levels/compare/v2.1.0...v2.2.0) (2022-09-09)
### Features
* add frameRate property to the quality level (#134) ([13998a7](https://github.com/videojs/videojs-contrib-quality-levels/commit/13998a7)), closes [#134](https://github.com/videojs/videojs-contrib-quality-levels/issues/134)
### Chores
* update jsdoc (#132) ([dbcc7b4](https://github.com/videojs/videojs-contrib-quality-levels/commit/dbcc7b4)), closes [#132](https://github.com/videojs/videojs-contrib-quality-levels/issues/132)
### Code Refactoring
* remove IE8 specific changes (#133) ([316f405](https://github.com/videojs/videojs-contrib-quality-levels/commit/316f405)), closes [#133](https://github.com/videojs/videojs-contrib-quality-levels/issues/133)
### Documentation
* Fix typo in README (#135) ([7036132](https://github.com/videojs/videojs-contrib-quality-levels/commit/7036132)), closes [#135](https://github.com/videojs/videojs-contrib-quality-levels/issues/135)
### Tests
* update karma-config to fix local tests (#137) ([77bb0f1](https://github.com/videojs/videojs-contrib-quality-levels/commit/77bb0f1)), closes [#137](https://github.com/videojs/videojs-contrib-quality-levels/issues/137)
<a name="2.1.0"></a>

@@ -2,0 +25,0 @@ # [2.1.0](https://github.com/videojs/videojs-contrib-quality-levels/compare/v2.0.9...v2.1.0) (2021-04-05)

29

dist/videojs-contrib-quality-levels.cjs.js

@@ -1,2 +0,2 @@

/*! @name videojs-contrib-quality-levels @version 2.1.0 @license Apache-2.0 */
/*! @name videojs-contrib-quality-levels @version 2.2.0 @license Apache-2.0 */
'use strict';

@@ -7,3 +7,2 @@

var videojs = _interopDefault(require('video.js'));
var document = _interopDefault(require('global/document'));

@@ -38,3 +37,2 @@ function _inheritsLoose(subClass, superClass) {

*/
var QualityLevel =

@@ -49,2 +47,3 @@ /**

* @param {number} representation.bandwidth Bitrate of the QualityLevel
* @param {number=} representation.frameRate Frame-rate of the QualityLevel
* @param {Function} representation.enabled Callback to enable/disable QualityLevel

@@ -55,12 +54,2 @@ */

if (videojs.browser.IS_IE8) {
level = document.createElement('custom');
for (var prop in QualityLevel.prototype) {
if (prop !== 'constructor') {
level[prop] = QualityLevel.prototype[prop];
}
}
}
level.id = representation.id;

@@ -71,2 +60,3 @@ level.label = level.id;

level.bitrate = representation.bandwidth;
level.frameRate = representation.frameRate;
level.enabled_ = representation.enabled;

@@ -129,12 +119,2 @@ Object.defineProperty(level, 'enabled', {

if (videojs.browser.IS_IE8) {
list = document.createElement('custom');
for (var prop in QualityLevelList.prototype) {
if (prop !== 'constructor') {
list[prop] = QualityLevelList.prototype[prop];
}
}
}
list.levels_ = [];

@@ -176,2 +156,3 @@ list.selectedIndex_ = -1;

* @param {number} representation.bandwidth Bitrate of the QualityLevel
* @param {number=} representation.frameRate Frame-rate of the QualityLevel
* @param {Function} representation.enabled Callback to enable/disable QualityLevel

@@ -296,3 +277,3 @@ * @return {QualityLevel} the QualityLevel added to the list

var version = "2.1.0";
var version = "2.2.0";

@@ -299,0 +280,0 @@ var registerPlugin = videojs.registerPlugin || videojs.plugin;

@@ -1,4 +0,3 @@

/*! @name videojs-contrib-quality-levels @version 2.1.0 @license Apache-2.0 */
/*! @name videojs-contrib-quality-levels @version 2.2.0 @license Apache-2.0 */
import videojs from 'video.js';
import document from 'global/document';

@@ -33,3 +32,2 @@ function _inheritsLoose(subClass, superClass) {

*/
var QualityLevel =

@@ -44,2 +42,3 @@ /**

* @param {number} representation.bandwidth Bitrate of the QualityLevel
* @param {number=} representation.frameRate Frame-rate of the QualityLevel
* @param {Function} representation.enabled Callback to enable/disable QualityLevel

@@ -50,12 +49,2 @@ */

if (videojs.browser.IS_IE8) {
level = document.createElement('custom');
for (var prop in QualityLevel.prototype) {
if (prop !== 'constructor') {
level[prop] = QualityLevel.prototype[prop];
}
}
}
level.id = representation.id;

@@ -66,2 +55,3 @@ level.label = level.id;

level.bitrate = representation.bandwidth;
level.frameRate = representation.frameRate;
level.enabled_ = representation.enabled;

@@ -124,12 +114,2 @@ Object.defineProperty(level, 'enabled', {

if (videojs.browser.IS_IE8) {
list = document.createElement('custom');
for (var prop in QualityLevelList.prototype) {
if (prop !== 'constructor') {
list[prop] = QualityLevelList.prototype[prop];
}
}
}
list.levels_ = [];

@@ -171,2 +151,3 @@ list.selectedIndex_ = -1;

* @param {number} representation.bandwidth Bitrate of the QualityLevel
* @param {number=} representation.frameRate Frame-rate of the QualityLevel
* @param {Function} representation.enabled Callback to enable/disable QualityLevel

@@ -291,3 +272,3 @@ * @return {QualityLevel} the QualityLevel added to the list

var version = "2.1.0";
var version = "2.2.0";

@@ -294,0 +275,0 @@ var registerPlugin = videojs.registerPlugin || videojs.plugin;

@@ -1,10 +0,9 @@

/*! @name videojs-contrib-quality-levels @version 2.1.0 @license Apache-2.0 */
/*! @name videojs-contrib-quality-levels @version 2.2.0 @license Apache-2.0 */
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('video.js'), require('global/document')) :
typeof define === 'function' && define.amd ? define(['video.js', 'global/document'], factory) :
(global.videojsContribQualityLevels = factory(global.videojs,global.document));
}(this, (function (videojs,document) { 'use strict';
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('video.js')) :
typeof define === 'function' && define.amd ? define(['video.js'], factory) :
(global.videojsContribQualityLevels = factory(global.videojs));
}(this, (function (videojs) { 'use strict';
videojs = videojs && videojs.hasOwnProperty('default') ? videojs['default'] : videojs;
document = document && document.hasOwnProperty('default') ? document['default'] : document;

@@ -39,3 +38,2 @@ function _inheritsLoose(subClass, superClass) {

*/
var QualityLevel =

@@ -50,2 +48,3 @@ /**

* @param {number} representation.bandwidth Bitrate of the QualityLevel
* @param {number=} representation.frameRate Frame-rate of the QualityLevel
* @param {Function} representation.enabled Callback to enable/disable QualityLevel

@@ -56,12 +55,2 @@ */

if (videojs.browser.IS_IE8) {
level = document.createElement('custom');
for (var prop in QualityLevel.prototype) {
if (prop !== 'constructor') {
level[prop] = QualityLevel.prototype[prop];
}
}
}
level.id = representation.id;

@@ -72,2 +61,3 @@ level.label = level.id;

level.bitrate = representation.bandwidth;
level.frameRate = representation.frameRate;
level.enabled_ = representation.enabled;

@@ -130,12 +120,2 @@ Object.defineProperty(level, 'enabled', {

if (videojs.browser.IS_IE8) {
list = document.createElement('custom');
for (var prop in QualityLevelList.prototype) {
if (prop !== 'constructor') {
list[prop] = QualityLevelList.prototype[prop];
}
}
}
list.levels_ = [];

@@ -177,2 +157,3 @@ list.selectedIndex_ = -1;

* @param {number} representation.bandwidth Bitrate of the QualityLevel
* @param {number=} representation.frameRate Frame-rate of the QualityLevel
* @param {Function} representation.enabled Callback to enable/disable QualityLevel

@@ -297,3 +278,3 @@ * @return {QualityLevel} the QualityLevel added to the list

var version = "2.1.0";
var version = "2.2.0";

@@ -300,0 +281,0 @@ var registerPlugin = videojs.registerPlugin || videojs.plugin;

@@ -1,2 +0,2 @@

/*! @name videojs-contrib-quality-levels @version 2.1.0 @license Apache-2.0 */
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("video.js"),require("global/document")):"function"==typeof define&&define.amd?define(["video.js","global/document"],t):e.videojsContribQualityLevels=t(e.videojs,e.document)}(this,function(e,t){"use strict";function n(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}e=e&&e.hasOwnProperty("default")?e.default:e,t=t&&t.hasOwnProperty("default")?t.default:t;var r=function(r){var i,l;function o(){var i,l=n(n(i=r.call(this)||this));if(e.browser.IS_IE8)for(var s in l=t.createElement("custom"),o.prototype)"constructor"!==s&&(l[s]=o.prototype[s]);return l.levels_=[],l.selectedIndex_=-1,Object.defineProperty(l,"selectedIndex",{get:function(){return l.selectedIndex_}}),Object.defineProperty(l,"length",{get:function(){return l.levels_.length}}),l||n(i)}l=r,(i=o).prototype=Object.create(l.prototype),i.prototype.constructor=i,i.__proto__=l;var s=o.prototype;return s.addQualityLevel=function(n){var r=this.getQualityLevelById(n.id);if(r)return r;var i=this.levels_.length;return r=new function n(r){var i=this;if(e.browser.IS_IE8)for(var l in i=t.createElement("custom"),n.prototype)"constructor"!==l&&(i[l]=n.prototype[l]);return i.id=r.id,i.label=i.id,i.width=r.width,i.height=r.height,i.bitrate=r.bandwidth,i.enabled_=r.enabled,Object.defineProperty(i,"enabled",{get:function(){return i.enabled_()},set:function(e){i.enabled_(e)}}),i}(n),""+i in this||Object.defineProperty(this,i,{get:function(){return this.levels_[i]}}),this.levels_.push(r),this.trigger({qualityLevel:r,type:"addqualitylevel"}),r},s.removeQualityLevel=function(e){for(var t=null,n=0,r=this.length;n<r;n++)if(this[n]===e){t=this.levels_.splice(n,1)[0],this.selectedIndex_===n?this.selectedIndex_=-1:this.selectedIndex_>n&&this.selectedIndex_--;break}return t&&this.trigger({qualityLevel:e,type:"removequalitylevel"}),t},s.getQualityLevelById=function(e){for(var t=0,n=this.length;t<n;t++){var r=this[t];if(r.id===e)return r}return null},s.dispose=function(){this.selectedIndex_=-1,this.levels_.length=0},o}(e.EventTarget);for(var i in r.prototype.allowedEvents_={change:"change",addqualitylevel:"addqualitylevel",removequalitylevel:"removequalitylevel"},r.prototype.allowedEvents_)r.prototype["on"+i]=null;var l=function(t){return n=this,e.mergeOptions({},t),i=n.qualityLevels,l=new r,n.on("dispose",function e(){l.dispose(),n.qualityLevels=i,n.off("dispose",e)}),n.qualityLevels=function(){return l},n.qualityLevels.VERSION="2.1.0",l;var n,i,l};return(e.registerPlugin||e.plugin)("qualityLevels",l),l.VERSION="2.1.0",l});
/*! @name videojs-contrib-quality-levels @version 2.2.0 @license Apache-2.0 */
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("video.js")):"function"==typeof define&&define.amd?define(["video.js"],t):e.videojsContribQualityLevels=t(e.videojs)}(this,function(e){"use strict";function t(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var i=function(e){var i,n;function l(){var i,n=t(t(i=e.call(this)||this));return n.levels_=[],n.selectedIndex_=-1,Object.defineProperty(n,"selectedIndex",{get:function(){return n.selectedIndex_}}),Object.defineProperty(n,"length",{get:function(){return n.levels_.length}}),n||t(i)}n=e,(i=l).prototype=Object.create(n.prototype),i.prototype.constructor=i,i.__proto__=n;var r=l.prototype;return r.addQualityLevel=function(e){var t=this.getQualityLevelById(e.id);if(t)return t;var i=this.levels_.length;return t=new function(e){var t=this;return t.id=e.id,t.label=t.id,t.width=e.width,t.height=e.height,t.bitrate=e.bandwidth,t.frameRate=e.frameRate,t.enabled_=e.enabled,Object.defineProperty(t,"enabled",{get:function(){return t.enabled_()},set:function(e){t.enabled_(e)}}),t}(e),""+i in this||Object.defineProperty(this,i,{get:function(){return this.levels_[i]}}),this.levels_.push(t),this.trigger({qualityLevel:t,type:"addqualitylevel"}),t},r.removeQualityLevel=function(e){for(var t=null,i=0,n=this.length;i<n;i++)if(this[i]===e){t=this.levels_.splice(i,1)[0],this.selectedIndex_===i?this.selectedIndex_=-1:this.selectedIndex_>i&&this.selectedIndex_--;break}return t&&this.trigger({qualityLevel:e,type:"removequalitylevel"}),t},r.getQualityLevelById=function(e){for(var t=0,i=this.length;t<i;t++){var n=this[t];if(n.id===e)return n}return null},r.dispose=function(){this.selectedIndex_=-1,this.levels_.length=0},l}((e=e&&e.hasOwnProperty("default")?e.default:e).EventTarget);for(var n in i.prototype.allowedEvents_={change:"change",addqualitylevel:"addqualitylevel",removequalitylevel:"removequalitylevel"},i.prototype.allowedEvents_)i.prototype["on"+n]=null;var l=function(t){return n=this,e.mergeOptions({},t),l=n.qualityLevels,r=new i,n.on("dispose",function e(){r.dispose(),n.qualityLevels=l,n.off("dispose",e)}),n.qualityLevels=function(){return r},n.qualityLevels.VERSION="2.2.0",r;var n,l,r};return(e.registerPlugin||e.plugin)("qualityLevels",l),l.VERSION="2.2.0",l});
{
"name": "videojs-contrib-quality-levels",
"version": "2.1.0",
"version": "2.2.0",
"description": "Exposes a list of quality levels available for the source.",

@@ -18,3 +18,3 @@ "main": "dist/videojs-contrib-quality-levels.cjs.js",

"docs": "npm-run-all docs:*",
"docs:api": "jsdoc src -g plugins/markdown -r -d docs/api",
"docs:api": "jsdoc src -c scripts/jsdoc.config.json -r -d docs/api",
"docs:toc": "doctoc README.md",

@@ -72,3 +72,3 @@ "lint": "vjsstandard",

"husky": "^1.0.0-rc.13",
"jsdoc": "https://github.com/BrandonOCasey/jsdoc#feat/plugin-from-cli",
"jsdoc": "^3.6.10",
"karma": "^3.0.0",

@@ -84,4 +84,3 @@ "lint-staged": "^7.2.2",

"sinon": "^6.1.5",
"videojs-contrib-hls": "^5.14.1",
"videojs-generate-karma-config": "~5.0.1",
"videojs-generate-karma-config": "^7.1.0",
"videojs-generate-rollup-config": "~2.2.0",

@@ -88,0 +87,0 @@ "videojs-generator-verify": "~1.0.3",

@@ -17,2 +17,3 @@ # videojs-contrib-quality-levels

- [Installation](#installation)
- [Installation](#installation-1)
- [Using](#using)

@@ -58,3 +59,3 @@ - [Supporting Quality Levels for your source](#supporting-quality-levels-for-your-source)

The list of `QualiyLevels` can be accessed using `qualityLevels()` on the Player object.
The list of `QualityLevels` can be accessed using `qualityLevels()` on the Player object.
With this list, you can:

@@ -116,3 +117,3 @@ * See which quality levels are available for the current source

### Populating the list
Initially the list of quality levels will be empty. You can add quality levels to the list by using `QualityLevelList.addQualityLevel` for each quality level specific to your source. `QualityLevelList.addQualityLevel` takes in a `Representation` object (or generic object with the required properties). All properties are required except `width` and `height`.
Initially the list of quality levels will be empty. You can add quality levels to the list by using `QualityLevelList.addQualityLevel` for each quality level specific to your source. `QualityLevelList.addQualityLevel` takes in a `Representation` object (or generic object with the required properties). All properties are required except `width`, `height` and `frameRate`.

@@ -126,2 +127,3 @@ Example Representation

bitrate: number,
frameRate: number,
enabled: function

@@ -128,0 +130,0 @@ }

import videojs from 'video.js';
import document from 'global/document';
import QualityLevel from './quality-level.js';

@@ -31,11 +30,2 @@

if (videojs.browser.IS_IE8) {
list = document.createElement('custom');
for (const prop in QualityLevelList.prototype) {
if (prop !== 'constructor') {
list[prop] = QualityLevelList.prototype[prop];
}
}
}
list.levels_ = [];

@@ -79,2 +69,3 @@ list.selectedIndex_ = -1;

* @param {number} representation.bandwidth Bitrate of the QualityLevel
* @param {number=} representation.frameRate Frame-rate of the QualityLevel
* @param {Function} representation.enabled Callback to enable/disable QualityLevel

@@ -81,0 +72,0 @@ * @return {QualityLevel} the QualityLevel added to the list

@@ -1,4 +0,1 @@

import videojs from 'video.js';
import document from 'global/document';
/**

@@ -28,2 +25,3 @@ * A single QualityLevel.

* @param {number} representation.bandwidth Bitrate of the QualityLevel
* @param {number=} representation.frameRate Frame-rate of the QualityLevel
* @param {Function} representation.enabled Callback to enable/disable QualityLevel

@@ -35,11 +33,2 @@ */

if (videojs.browser.IS_IE8) {
level = document.createElement('custom');
for (const prop in QualityLevel.prototype) {
if (prop !== 'constructor') {
level[prop] = QualityLevel.prototype[prop];
}
}
}
level.id = representation.id;

@@ -50,2 +39,3 @@ level.label = level.id;

level.bitrate = representation.bandwidth;
level.frameRate = representation.frameRate;
level.enabled_ = representation.enabled;

@@ -52,0 +42,0 @@

@@ -1,2 +0,2 @@

/*! @name videojs-contrib-quality-levels @version 2.1.0 @license Apache-2.0 */
/*! @name videojs-contrib-quality-levels @version 2.2.0 @license Apache-2.0 */
(function (videojs,QUnit,sinon) {

@@ -53,3 +53,3 @@ 'use strict';

var path = '/Users/gkatsevman/p/videojs-contrib-quality-levels/src/quality-level.js',
hash = '1ba161d6a22d909003d6224cd4464ed09cd1c517',
hash = 'b9e3e06774df7a60c14fdd2dccb93e74e62d1aad',
Function = function () {}.constructor,

@@ -63,7 +63,7 @@ global = new Function('return this')(),

start: {
line: 32,
line: 30,
column: 16
},
end: {
line: 32,
line: 30,
column: 20

@@ -74,8 +74,8 @@ }

start: {
line: 34,
line: 32,
column: 4
},
end: {
line: 41,
column: 5
line: 32,
column: 33
}

@@ -85,8 +85,8 @@ },

start: {
line: 35,
column: 6
line: 33,
column: 4
},
end: {
line: 35,
column: 47
line: 33,
column: 27
}

@@ -96,8 +96,8 @@ },

start: {
line: 36,
column: 6
line: 34,
column: 4
},
end: {
line: 40,
column: 7
line: 34,
column: 39
}

@@ -107,8 +107,8 @@ },

start: {
line: 37,
column: 8
line: 35,
column: 4
},
end: {
line: 39,
column: 9
line: 35,
column: 41
}

@@ -118,8 +118,8 @@ },

start: {
line: 38,
column: 10
line: 36,
column: 4
},
end: {
line: 38,
column: 53
line: 36,
column: 45
}

@@ -129,8 +129,8 @@ },

start: {
line: 43,
line: 37,
column: 4
},
end: {
line: 43,
column: 33
line: 37,
column: 47
}

@@ -140,8 +140,8 @@ },

start: {
line: 44,
line: 38,
column: 4
},
end: {
line: 44,
column: 27
line: 38,
column: 44
}

@@ -151,8 +151,8 @@ },

start: {
line: 45,
line: 40,
column: 4
},
end: {
line: 45,
column: 39
line: 58,
column: 7
}

@@ -162,67 +162,27 @@ },

start: {
line: 46,
column: 4
},
end: {
line: 46,
column: 41
}
},
'10': {
start: {
line: 47,
column: 4
column: 8
},
end: {
line: 47,
column: 45
}
},
'11': {
start: {
line: 48,
column: 4
},
end: {
line: 48,
column: 44
}
},
'12': {
start: {
line: 50,
column: 4
},
end: {
line: 68,
column: 7
}
},
'13': {
start: {
line: 57,
column: 8
},
end: {
line: 57,
column: 32
}
},
'14': {
'10': {
start: {
line: 66,
line: 56,
column: 8
},
end: {
line: 66,
line: 56,
column: 31
}
},
'15': {
'11': {
start: {
line: 70,
line: 60,
column: 4
},
end: {
line: 70,
line: 60,
column: 17

@@ -237,7 +197,7 @@ }

start: {
line: 30,
line: 28,
column: 2
},
end: {
line: 30,
line: 28,
column: 3

@@ -248,81 +208,14 @@ }

start: {
line: 30,
line: 28,
column: 30
},
end: {
line: 71,
line: 61,
column: 3
}
},
line: 30
line: 28
}
},
branchMap: {
'0': {
loc: {
start: {
line: 34,
column: 4
},
end: {
line: 41,
column: 5
}
},
type: 'if',
locations: [{
start: {
line: 34,
column: 4
},
end: {
line: 41,
column: 5
}
}, {
start: {
line: 34,
column: 4
},
end: {
line: 41,
column: 5
}
}],
line: 34
},
'1': {
loc: {
start: {
line: 37,
column: 8
},
end: {
line: 39,
column: 9
}
},
type: 'if',
locations: [{
start: {
line: 37,
column: 8
},
end: {
line: 39,
column: 9
}
}, {
start: {
line: 37,
column: 8
},
end: {
line: 39,
column: 9
}
}],
line: 37
}
},
branchMap: {},
s: {

@@ -340,7 +233,3 @@ '0': 0,

'10': 0,
'11': 0,
'12': 0,
'13': 0,
'14': 0,
'15': 0
'11': 0
},

@@ -350,6 +239,3 @@ f: {

},
b: {
'0': [0, 0],
'1': [0, 0]
},
b: {},
_coverageSchema: '332fd63041d2c1bcb487cc26dd0d5f7d97098a6c'

@@ -371,48 +257,27 @@ },

cov_19hafjbjq6.s[1]++;
if (videojs.browser.IS_IE8) {
cov_19hafjbjq6.b[0][0]++;
cov_19hafjbjq6.s[2]++;
level = document_1.createElement('custom');
cov_19hafjbjq6.s[3]++;
for (var prop in QualityLevel.prototype) {
cov_19hafjbjq6.s[4]++;
if (prop !== 'constructor') {
cov_19hafjbjq6.b[1][0]++;
cov_19hafjbjq6.s[5]++;
level[prop] = QualityLevel.prototype[prop];
} else {
cov_19hafjbjq6.b[1][1]++;
}
}
} else {
cov_19hafjbjq6.b[0][1]++;
}
cov_19hafjbjq6.s[6]++;
level.id = representation.id;
cov_19hafjbjq6.s[7]++;
cov_19hafjbjq6.s[2]++;
level.label = level.id;
cov_19hafjbjq6.s[8]++;
cov_19hafjbjq6.s[3]++;
level.width = representation.width;
cov_19hafjbjq6.s[9]++;
cov_19hafjbjq6.s[4]++;
level.height = representation.height;
cov_19hafjbjq6.s[10]++;
cov_19hafjbjq6.s[5]++;
level.bitrate = representation.bandwidth;
cov_19hafjbjq6.s[11]++;
cov_19hafjbjq6.s[6]++;
level.frameRate = representation.frameRate;
cov_19hafjbjq6.s[7]++;
level.enabled_ = representation.enabled;
cov_19hafjbjq6.s[12]++;
cov_19hafjbjq6.s[8]++;
Object.defineProperty(level, 'enabled', {
get: function get() {
cov_19hafjbjq6.s[13]++;
cov_19hafjbjq6.s[9]++;
return level.enabled_();
},
set: function set(enable) {
cov_19hafjbjq6.s[14]++;
cov_19hafjbjq6.s[10]++;
level.enabled_(enable);
}
});
cov_19hafjbjq6.s[15]++;
cov_19hafjbjq6.s[11]++;
return level;

@@ -423,3 +288,3 @@ };

var path = '/Users/gkatsevman/p/videojs-contrib-quality-levels/src/quality-level-list.js',
hash = '58808d65013331fcfebb698f4845b73274d7c068',
hash = '1c1c94ace37d917b0ab99fd2f2e8ade016d1c101',
Function = function () {}.constructor,

@@ -433,7 +298,7 @@ global = new Function('return this')(),

start: {
line: 27,
line: 26,
column: 4
},
end: {
line: 27,
line: 26,
column: 12

@@ -444,7 +309,7 @@ }

start: {
line: 29,
line: 28,
column: 15
},
end: {
line: 29,
line: 28,
column: 19

@@ -455,8 +320,8 @@ }

start: {
line: 31,
line: 30,
column: 4
},
end: {
line: 38,
column: 5
line: 30,
column: 22
}

@@ -466,8 +331,8 @@ },

start: {
line: 32,
column: 6
line: 31,
column: 4
},
end: {
line: 32,
column: 46
line: 31,
column: 29
}

@@ -477,7 +342,7 @@ },

start: {
line: 33,
column: 6
line: 39,
column: 4
},
end: {
line: 37,
line: 43,
column: 7

@@ -488,8 +353,8 @@ }

start: {
line: 34,
line: 41,
column: 8
},
end: {
line: 36,
column: 9
line: 41,
column: 35
}

@@ -499,407 +364,357 @@ },

start: {
line: 35,
column: 10
},
end: {
line: 35,
column: 56
}
},
'7': {
start: {
line: 40,
column: 4
},
end: {
line: 40,
column: 22
}
},
'8': {
start: {
line: 41,
column: 4
},
end: {
line: 41,
column: 29
}
},
'9': {
start: {
line: 49,
column: 4
},
end: {
line: 53,
column: 7
}
},
'10': {
start: {
line: 51,
column: 8
},
end: {
line: 51,
column: 35
}
},
'11': {
start: {
line: 61,
column: 4
},
end: {
line: 65,
line: 55,
column: 7
}
},
'12': {
'7': {
start: {
line: 63,
line: 53,
column: 8
},
end: {
line: 63,
line: 53,
column: 35
}
},
'13': {
'8': {
start: {
line: 67,
line: 57,
column: 4
},
end: {
line: 67,
line: 57,
column: 16
}
},
'14': {
'9': {
start: {
line: 83,
line: 74,
column: 23
},
end: {
line: 83,
line: 74,
column: 66
}
},
'15': {
'10': {
start: {
line: 86,
line: 77,
column: 4
},
end: {
line: 88,
line: 79,
column: 5
}
},
'16': {
'11': {
start: {
line: 87,
line: 78,
column: 6
},
end: {
line: 87,
line: 78,
column: 26
}
},
'17': {
'12': {
start: {
line: 90,
line: 81,
column: 18
},
end: {
line: 90,
line: 81,
column: 37
}
},
'18': {
'13': {
start: {
line: 92,
line: 83,
column: 4
},
end: {
line: 92,
line: 83,
column: 52
}
},
'19': {
'14': {
start: {
line: 94,
line: 85,
column: 4
},
end: {
line: 100,
line: 91,
column: 5
}
},
'20': {
'15': {
start: {
line: 95,
line: 86,
column: 6
},
end: {
line: 99,
line: 90,
column: 9
}
},
'21': {
'16': {
start: {
line: 97,
line: 88,
column: 10
},
end: {
line: 97,
line: 88,
column: 37
}
},
'22': {
'17': {
start: {
line: 102,
line: 93,
column: 4
},
end: {
line: 102,
line: 93,
column: 36
}
},
'23': {
'18': {
start: {
line: 104,
line: 95,
column: 4
},
end: {
line: 107,
line: 98,
column: 7
}
},
'24': {
'19': {
start: {
line: 109,
line: 100,
column: 4
},
end: {
line: 109,
line: 100,
column: 24
}
},
'25': {
'20': {
start: {
line: 120,
line: 111,
column: 18
},
end: {
line: 120,
line: 111,
column: 22
}
},
'26': {
'21': {
start: {
line: 122,
line: 113,
column: 4
},
end: {
line: 133,
line: 124,
column: 5
}
},
'27': {
'22': {
start: {
line: 123,
line: 114,
column: 6
},
end: {
line: 132,
line: 123,
column: 7
}
},
'28': {
'23': {
start: {
line: 124,
line: 115,
column: 8
},
end: {
line: 124,
line: 115,
column: 47
}
},
'29': {
'24': {
start: {
line: 126,
line: 117,
column: 8
},
end: {
line: 130,
line: 121,
column: 9
}
},
'30': {
'25': {
start: {
line: 127,
line: 118,
column: 10
},
end: {
line: 127,
line: 118,
column: 35
}
},
'31': {
'26': {
start: {
line: 128,
line: 119,
column: 15
},
end: {
line: 130,
line: 121,
column: 9
}
},
'32': {
'27': {
start: {
line: 129,
line: 120,
column: 10
},
end: {
line: 129,
line: 120,
column: 32
}
},
'33': {
'28': {
start: {
line: 131,
line: 122,
column: 8
},
end: {
line: 131,
line: 122,
column: 14
}
},
'34': {
'29': {
start: {
line: 135,
line: 126,
column: 4
},
end: {
line: 140,
line: 131,
column: 5
}
},
'35': {
'30': {
start: {
line: 136,
line: 127,
column: 6
},
end: {
line: 139,
line: 130,
column: 9
}
},
'36': {
'31': {
start: {
line: 142,
line: 133,
column: 4
},
end: {
line: 142,
line: 133,
column: 19
}
},
'37': {
'32': {
start: {
line: 153,
line: 144,
column: 4
},
end: {
line: 159,
line: 150,
column: 5
}
},
'38': {
'33': {
start: {
line: 154,
line: 145,
column: 20
},
end: {
line: 154,
line: 145,
column: 27
}
},
'39': {
'34': {
start: {
line: 156,
line: 147,
column: 6
},
end: {
line: 158,
line: 149,
column: 7
}
},
'40': {
'35': {
start: {
line: 157,
line: 148,
column: 8
},
end: {
line: 157,
line: 148,
column: 21
}
},
'41': {
'36': {
start: {
line: 160,
line: 151,
column: 4
},
end: {
line: 160,
line: 151,
column: 16
}
},
'42': {
'37': {
start: {
line: 169,
line: 160,
column: 4
},
end: {
line: 169,
line: 160,
column: 29
}
},
'43': {
'38': {
start: {
line: 170,
line: 161,
column: 4
},
end: {
line: 170,
line: 161,
column: 28
}
},
'44': {
'39': {
start: {
line: 179,
line: 170,
column: 0
},
end: {
line: 183,
line: 174,
column: 2
}
},
'45': {
'40': {
start: {
line: 186,
line: 177,
column: 0
},
end: {
line: 188,
line: 179,
column: 1
}
},
'46': {
'41': {
start: {
line: 187,
line: 178,
column: 2
},
end: {
line: 187,
line: 178,
column: 50

@@ -914,7 +729,7 @@ }

start: {
line: 26,
line: 25,
column: 2
},
end: {
line: 26,
line: 25,
column: 3

@@ -925,11 +740,11 @@ }

start: {
line: 26,
line: 25,
column: 16
},
end: {
line: 68,
line: 58,
column: 3
}
},
line: 26
line: 25
},

@@ -940,7 +755,7 @@ '1': {

start: {
line: 82,
line: 73,
column: 2
},
end: {
line: 82,
line: 73,
column: 3

@@ -951,11 +766,11 @@ }

start: {
line: 82,
line: 73,
column: 34
},
end: {
line: 110,
line: 101,
column: 3
}
},
line: 82
line: 73
},

@@ -966,7 +781,7 @@ '2': {

start: {
line: 119,
line: 110,
column: 2
},
end: {
line: 119,
line: 110,
column: 3

@@ -977,11 +792,11 @@ }

start: {
line: 119,
line: 110,
column: 35
},
end: {
line: 143,
line: 134,
column: 3
}
},
line: 119
line: 110
},

@@ -992,7 +807,7 @@ '3': {

start: {
line: 152,
line: 143,
column: 2
},
end: {
line: 152,
line: 143,
column: 3

@@ -1003,11 +818,11 @@ }

start: {
line: 152,
line: 143,
column: 26
},
end: {
line: 161,
line: 152,
column: 3
}
},
line: 152
line: 143
},

@@ -1018,7 +833,7 @@ '4': {

start: {
line: 168,
line: 159,
column: 2
},
end: {
line: 168,
line: 159,
column: 3

@@ -1029,11 +844,11 @@ }

start: {
line: 168,
line: 159,
column: 12
},
end: {
line: 171,
line: 162,
column: 3
}
},
line: 168
line: 159
}

@@ -1045,7 +860,7 @@ },

start: {
line: 31,
line: 77,
column: 4
},
end: {
line: 38,
line: 79,
column: 5

@@ -1057,7 +872,7 @@ }

start: {
line: 31,
line: 77,
column: 4
},
end: {
line: 38,
line: 79,
column: 5

@@ -1067,11 +882,11 @@ }

start: {
line: 31,
line: 77,
column: 4
},
end: {
line: 38,
line: 79,
column: 5
}
}],
line: 31
line: 77
},

@@ -1081,40 +896,7 @@ '1': {

start: {
line: 34,
column: 8
},
end: {
line: 36,
column: 9
}
},
type: 'if',
locations: [{
start: {
line: 34,
column: 8
},
end: {
line: 36,
column: 9
}
}, {
start: {
line: 34,
column: 8
},
end: {
line: 36,
column: 9
}
}],
line: 34
},
'2': {
loc: {
start: {
line: 86,
line: 85,
column: 4
},
end: {
line: 88,
line: 91,
column: 5

@@ -1126,7 +908,7 @@ }

start: {
line: 86,
line: 85,
column: 4
},
end: {
line: 88,
line: 91,
column: 5

@@ -1136,53 +918,20 @@ }

start: {
line: 86,
line: 85,
column: 4
},
end: {
line: 88,
line: 91,
column: 5
}
}],
line: 86
line: 85
},
'3': {
'2': {
loc: {
start: {
line: 94,
column: 4
line: 114,
column: 6
},
end: {
line: 100,
column: 5
}
},
type: 'if',
locations: [{
start: {
line: 94,
column: 4
},
end: {
line: 100,
column: 5
}
}, {
start: {
line: 94,
column: 4
},
end: {
line: 100,
column: 5
}
}],
line: 94
},
'4': {
loc: {
start: {
line: 123,
column: 6
},
end: {
line: 132,
column: 7

@@ -1194,7 +943,7 @@ }

start: {
line: 123,
line: 114,
column: 6
},
end: {
line: 132,
line: 123,
column: 7

@@ -1204,20 +953,20 @@ }

start: {
line: 123,
line: 114,
column: 6
},
end: {
line: 132,
line: 123,
column: 7
}
}],
line: 123
line: 114
},
'5': {
'3': {
loc: {
start: {
line: 126,
line: 117,
column: 8
},
end: {
line: 130,
line: 121,
column: 9

@@ -1229,7 +978,7 @@ }

start: {
line: 126,
line: 117,
column: 8
},
end: {
line: 130,
line: 121,
column: 9

@@ -1239,20 +988,20 @@ }

start: {
line: 126,
line: 117,
column: 8
},
end: {
line: 130,
line: 121,
column: 9
}
}],
line: 126
line: 117
},
'6': {
'4': {
loc: {
start: {
line: 128,
line: 119,
column: 15
},
end: {
line: 130,
line: 121,
column: 9

@@ -1264,7 +1013,7 @@ }

start: {
line: 128,
line: 119,
column: 15
},
end: {
line: 130,
line: 121,
column: 9

@@ -1274,20 +1023,20 @@ }

start: {
line: 128,
line: 119,
column: 15
},
end: {
line: 130,
line: 121,
column: 9
}
}],
line: 128
line: 119
},
'7': {
'5': {
loc: {
start: {
line: 135,
line: 126,
column: 4
},
end: {
line: 140,
line: 131,
column: 5

@@ -1299,7 +1048,7 @@ }

start: {
line: 135,
line: 126,
column: 4
},
end: {
line: 140,
line: 131,
column: 5

@@ -1309,20 +1058,20 @@ }

start: {
line: 135,
line: 126,
column: 4
},
end: {
line: 140,
line: 131,
column: 5
}
}],
line: 135
line: 126
},
'8': {
'6': {
loc: {
start: {
line: 156,
line: 147,
column: 6
},
end: {
line: 158,
line: 149,
column: 7

@@ -1334,7 +1083,7 @@ }

start: {
line: 156,
line: 147,
column: 6
},
end: {
line: 158,
line: 149,
column: 7

@@ -1344,11 +1093,11 @@ }

start: {
line: 156,
line: 147,
column: 6
},
end: {
line: 158,
line: 149,
column: 7
}
}],
line: 156
line: 147
}

@@ -1398,8 +1147,3 @@ },

'40': 0,
'41': 0,
'42': 0,
'43': 0,
'44': 0,
'45': 0,
'46': 0
'41': 0
},

@@ -1420,5 +1164,3 @@ f: {

'5': [0, 0],
'6': [0, 0],
'7': [0, 0],
'8': [0, 0]
'6': [0, 0]
},

@@ -1450,43 +1192,20 @@ _coverageSchema: '332fd63041d2c1bcb487cc26dd0d5f7d97098a6c'

cov_ewsbgpa6j.s[2]++;
if (videojs.browser.IS_IE8) {
cov_ewsbgpa6j.b[0][0]++;
cov_ewsbgpa6j.s[3]++;
list = document_1.createElement('custom');
cov_ewsbgpa6j.s[4]++;
for (var prop in QualityLevelList.prototype) {
cov_ewsbgpa6j.s[5]++;
if (prop !== 'constructor') {
cov_ewsbgpa6j.b[1][0]++;
cov_ewsbgpa6j.s[6]++;
list[prop] = QualityLevelList.prototype[prop];
} else {
cov_ewsbgpa6j.b[1][1]++;
}
}
} else {
cov_ewsbgpa6j.b[0][1]++;
}
cov_ewsbgpa6j.s[7]++;
list.levels_ = [];
cov_ewsbgpa6j.s[8]++;
cov_ewsbgpa6j.s[3]++;
list.selectedIndex_ = -1;
cov_ewsbgpa6j.s[9]++;
cov_ewsbgpa6j.s[4]++;
Object.defineProperty(list, 'selectedIndex', {
get: function get() {
cov_ewsbgpa6j.s[10]++;
cov_ewsbgpa6j.s[5]++;
return list.selectedIndex_;
}
});
cov_ewsbgpa6j.s[11]++;
cov_ewsbgpa6j.s[6]++;
Object.defineProperty(list, 'length', {
get: function get() {
cov_ewsbgpa6j.s[12]++;
cov_ewsbgpa6j.s[7]++;
return list.levels_.length;
}
});
cov_ewsbgpa6j.s[13]++;
cov_ewsbgpa6j.s[8]++;
return list || _assertThisInitialized(_this);

@@ -1499,24 +1218,24 @@ }

cov_ewsbgpa6j.f[1]++;
var qualityLevel = (cov_ewsbgpa6j.s[14]++, this.getQualityLevelById(representation.id));
cov_ewsbgpa6j.s[15]++;
var qualityLevel = (cov_ewsbgpa6j.s[9]++, this.getQualityLevelById(representation.id));
cov_ewsbgpa6j.s[10]++;
if (qualityLevel) {
cov_ewsbgpa6j.b[2][0]++;
cov_ewsbgpa6j.s[16]++;
cov_ewsbgpa6j.b[0][0]++;
cov_ewsbgpa6j.s[11]++;
return qualityLevel;
} else {
cov_ewsbgpa6j.b[2][1]++;
cov_ewsbgpa6j.b[0][1]++;
}
var index = (cov_ewsbgpa6j.s[17]++, this.levels_.length);
cov_ewsbgpa6j.s[18]++;
var index = (cov_ewsbgpa6j.s[12]++, this.levels_.length);
cov_ewsbgpa6j.s[13]++;
qualityLevel = new QualityLevel(representation);
cov_ewsbgpa6j.s[19]++;
cov_ewsbgpa6j.s[14]++;
if (!('' + index in this)) {
cov_ewsbgpa6j.b[3][0]++;
cov_ewsbgpa6j.s[20]++;
cov_ewsbgpa6j.b[1][0]++;
cov_ewsbgpa6j.s[15]++;
Object.defineProperty(this, index, {
get: function get() {
cov_ewsbgpa6j.s[21]++;
cov_ewsbgpa6j.s[16]++;
return this.levels_[index];

@@ -1526,8 +1245,8 @@ }

} else {
cov_ewsbgpa6j.b[3][1]++;
cov_ewsbgpa6j.b[1][1]++;
}
cov_ewsbgpa6j.s[22]++;
cov_ewsbgpa6j.s[17]++;
this.levels_.push(qualityLevel);
cov_ewsbgpa6j.s[23]++;
cov_ewsbgpa6j.s[18]++;
this.trigger({

@@ -1537,3 +1256,3 @@ qualityLevel: qualityLevel,

});
cov_ewsbgpa6j.s[24]++;
cov_ewsbgpa6j.s[19]++;
return qualityLevel;

@@ -1544,43 +1263,43 @@ };

cov_ewsbgpa6j.f[2]++;
var removed = (cov_ewsbgpa6j.s[25]++, null);
cov_ewsbgpa6j.s[26]++;
var removed = (cov_ewsbgpa6j.s[20]++, null);
cov_ewsbgpa6j.s[21]++;
for (var i = 0, l = this.length; i < l; i++) {
cov_ewsbgpa6j.s[27]++;
cov_ewsbgpa6j.s[22]++;
if (this[i] === qualityLevel) {
cov_ewsbgpa6j.b[4][0]++;
cov_ewsbgpa6j.s[28]++;
cov_ewsbgpa6j.b[2][0]++;
cov_ewsbgpa6j.s[23]++;
removed = this.levels_.splice(i, 1)[0];
cov_ewsbgpa6j.s[29]++;
cov_ewsbgpa6j.s[24]++;
if (this.selectedIndex_ === i) {
cov_ewsbgpa6j.b[5][0]++;
cov_ewsbgpa6j.s[30]++;
cov_ewsbgpa6j.b[3][0]++;
cov_ewsbgpa6j.s[25]++;
this.selectedIndex_ = -1;
} else {
cov_ewsbgpa6j.b[5][1]++;
cov_ewsbgpa6j.s[31]++;
cov_ewsbgpa6j.b[3][1]++;
cov_ewsbgpa6j.s[26]++;
if (this.selectedIndex_ > i) {
cov_ewsbgpa6j.b[6][0]++;
cov_ewsbgpa6j.s[32]++;
cov_ewsbgpa6j.b[4][0]++;
cov_ewsbgpa6j.s[27]++;
this.selectedIndex_--;
} else {
cov_ewsbgpa6j.b[6][1]++;
cov_ewsbgpa6j.b[4][1]++;
}
}
cov_ewsbgpa6j.s[33]++;
cov_ewsbgpa6j.s[28]++;
break;
} else {
cov_ewsbgpa6j.b[4][1]++;
cov_ewsbgpa6j.b[2][1]++;
}
}
cov_ewsbgpa6j.s[34]++;
cov_ewsbgpa6j.s[29]++;
if (removed) {
cov_ewsbgpa6j.b[7][0]++;
cov_ewsbgpa6j.s[35]++;
cov_ewsbgpa6j.b[5][0]++;
cov_ewsbgpa6j.s[30]++;
this.trigger({

@@ -1591,6 +1310,6 @@ qualityLevel: qualityLevel,

} else {
cov_ewsbgpa6j.b[7][1]++;
cov_ewsbgpa6j.b[5][1]++;
}
cov_ewsbgpa6j.s[36]++;
cov_ewsbgpa6j.s[31]++;
return removed;

@@ -1601,18 +1320,18 @@ };

cov_ewsbgpa6j.f[3]++;
cov_ewsbgpa6j.s[37]++;
cov_ewsbgpa6j.s[32]++;
for (var i = 0, l = this.length; i < l; i++) {
var level = (cov_ewsbgpa6j.s[38]++, this[i]);
cov_ewsbgpa6j.s[39]++;
var level = (cov_ewsbgpa6j.s[33]++, this[i]);
cov_ewsbgpa6j.s[34]++;
if (level.id === id) {
cov_ewsbgpa6j.b[8][0]++;
cov_ewsbgpa6j.s[40]++;
cov_ewsbgpa6j.b[6][0]++;
cov_ewsbgpa6j.s[35]++;
return level;
} else {
cov_ewsbgpa6j.b[8][1]++;
cov_ewsbgpa6j.b[6][1]++;
}
}
cov_ewsbgpa6j.s[41]++;
cov_ewsbgpa6j.s[36]++;
return null;

@@ -1623,5 +1342,5 @@ };

cov_ewsbgpa6j.f[4]++;
cov_ewsbgpa6j.s[42]++;
cov_ewsbgpa6j.s[37]++;
this.selectedIndex_ = -1;
cov_ewsbgpa6j.s[43]++;
cov_ewsbgpa6j.s[38]++;
this.levels_.length = 0;

@@ -1633,3 +1352,3 @@ };

cov_ewsbgpa6j.s[44]++;
cov_ewsbgpa6j.s[39]++;
QualityLevelList.prototype.allowedEvents_ = {

@@ -1640,10 +1359,10 @@ change: 'change',

};
cov_ewsbgpa6j.s[45]++;
cov_ewsbgpa6j.s[40]++;
for (var event in QualityLevelList.prototype.allowedEvents_) {
cov_ewsbgpa6j.s[46]++;
cov_ewsbgpa6j.s[41]++;
QualityLevelList.prototype['on' + event] = null;
}
var version = "2.1.0";
var version = "2.2.0";

@@ -2083,2 +1802,3 @@ var cov_2erotfic4r = function () {

bandwidth: 100,
frameRate: 29.956,
enabled: function enabled() {

@@ -2092,2 +1812,3 @@ return true;

bandwidth: 200,
frameRate: 29.956,
enabled: function enabled() {

@@ -2101,2 +1822,3 @@ return true;

bandwidth: 300,
frameRate: 30,
enabled: function enabled() {

@@ -2110,2 +1832,3 @@ return true;

bandwidth: 400,
frameRate: 60,
enabled: function enabled() {

@@ -2112,0 +1835,0 @@ return true;

@@ -7,2 +7,3 @@ export const representations = [

bandwidth: 100,
frameRate: 29.956,
enabled() {

@@ -17,2 +18,3 @@ return true;

bandwidth: 200,
frameRate: 29.956,
enabled() {

@@ -27,2 +29,3 @@ return true;

bandwidth: 300,
frameRate: 30,
enabled() {

@@ -37,2 +40,3 @@ return true;

bandwidth: 400,
frameRate: 60,
enabled() {

@@ -39,0 +43,0 @@ return true;

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc