@awinogrodzki/embed-plugin-youtube
Advanced tools
Comparing version 5.0.5 to 5.0.6
{ | ||
"name": "@awinogrodzki/embed-plugin-youtube", | ||
"version": "5.0.5", | ||
"version": "5.0.6", | ||
"description": "An embed-js plugin to embed youtube videos.", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
@@ -24,3 +24,3 @@ import extend from "just-extend" | ||
url: `${baseUrl}watch?v=${id}`, | ||
embedUrl: `${baseUrl}embed/${id}?modestbranding=1` | ||
embedUrl: `${baseUrl}embed/${id}` | ||
} | ||
@@ -48,10 +48,2 @@ } | ||
function prepareEmbedUrl(url) { | ||
if (url.includes('?')) { | ||
return url + "&modestbranding=1"; | ||
} | ||
return url + "?modestbranding=1"; | ||
} | ||
/** | ||
@@ -74,3 +66,3 @@ * Function executed when a content is rendered on the client site. | ||
url += "?autoplay=1" | ||
this.parentNode.innerHTML = withoutDetailsTemplate(prepareEmbedUrl(url), height, id) | ||
this.parentNode.innerHTML = withoutDetailsTemplate(url, height, id) | ||
} | ||
@@ -101,3 +93,3 @@ } | ||
? withDetailsTemplate(formatData(data), clickClass, true) | ||
: withoutDetailsTemplate(prepareEmbedUrl(embedUrl), height, id) | ||
: withoutDetailsTemplate(embedUrl, height, id) | ||
} | ||
@@ -104,0 +96,0 @@ } |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
78374
718