120 line width, package upgrade
This commit is contained in:
		@ -218,7 +218,12 @@ export function matches(element, selector) {
 | 
			
		||||
        return Array.from(document.querySelectorAll(selector)).includes(this);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    const matches = prototype.matches || prototype.webkitMatchesSelector || prototype.mozMatchesSelector || prototype.msMatchesSelector || match;
 | 
			
		||||
    const matches =
 | 
			
		||||
        prototype.matches ||
 | 
			
		||||
        prototype.webkitMatchesSelector ||
 | 
			
		||||
        prototype.mozMatchesSelector ||
 | 
			
		||||
        prototype.msMatchesSelector ||
 | 
			
		||||
        match;
 | 
			
		||||
 | 
			
		||||
    return matches.call(element, selector);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@ -113,7 +113,8 @@ export function unbindListeners() {
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
// Run method when / if player is ready
 | 
			
		||||
export function ready () {
 | 
			
		||||
    return new Promise(resolve => this.ready ? setTimeout(resolve, 0) : on.call(this, this.elements.container, 'ready', resolve))
 | 
			
		||||
        .then(() => {});
 | 
			
		||||
export function ready() {
 | 
			
		||||
    return new Promise(
 | 
			
		||||
        resolve => (this.ready ? setTimeout(resolve, 0) : on.call(this, this.elements.container, 'ready', resolve)),
 | 
			
		||||
    ).then(() => {});
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@ -47,7 +47,10 @@ const is = {
 | 
			
		||||
        return instanceOf(input, TextTrack) || (!is.nullOrUndefined(input) && is.string(input.kind));
 | 
			
		||||
    },
 | 
			
		||||
    url(input) {
 | 
			
		||||
        return !is.nullOrUndefined(input) && /(ftp|http|https):\/\/(\w+:{0,1}\w*@)?(\S+)(:[0-9]+)?(\/|\/([\w#!:.?+=&%@!\-/]))?/.test(input);
 | 
			
		||||
        return (
 | 
			
		||||
            !is.nullOrUndefined(input) &&
 | 
			
		||||
            /(ftp|http|https):\/\/(\w+:{0,1}\w*@)?(\S+)(:[0-9]+)?(\/|\/([\w#!:.?+=&%@!\-/]))?/.test(input)
 | 
			
		||||
        );
 | 
			
		||||
    },
 | 
			
		||||
    nullOrUndefined(input) {
 | 
			
		||||
        return input === null || typeof input === 'undefined';
 | 
			
		||||
 | 
			
		||||
@ -29,7 +29,10 @@ export function getPercentage(current, max) {
 | 
			
		||||
 | 
			
		||||
// Replace all occurances of a string in a string
 | 
			
		||||
export function replaceAll(input = '', find = '', replace = '') {
 | 
			
		||||
    return input.replace(new RegExp(find.toString().replace(/([.*+?^=!:${}()|[\]/\\])/g, '\\$1'), 'g'), replace.toString());
 | 
			
		||||
    return input.replace(
 | 
			
		||||
        new RegExp(find.toString().replace(/([.*+?^=!:${}()|[\]/\\])/g, '\\$1'), 'g'),
 | 
			
		||||
        replace.toString(),
 | 
			
		||||
    );
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
// Convert to title case
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user