Version Description
Download this release
Release Info
Developer | embedplus |
Plugin | YouTube |
Version | 14.0.1 |
Comparing to | |
See all releases |
Code changes from version 14.0 to 14.0.1
- readme.txt +11 -6
- scripts/ytprefs-wizard.js +15 -2
- scripts/ytprefs-wizard.min.js +1 -1
- scripts/ytprefs.js +20 -0
- scripts/ytprefs.min.js +1 -1
- styles/ytprefs.css +29 -1
- styles/ytprefs.min.css +1 -1
- youtube.php +20 -14
readme.txt
CHANGED
@@ -1,17 +1,17 @@
|
|
1 |
=== Embed Plus for YouTube - Embed a YouTube Gallery, Channel, Playlist, Live Stream, Facade ===
|
2 |
Contributors: embedplus
|
3 |
Plugin Name: Embed Plus for YouTube - Gallery, Channel, Playlist, Live Stream
|
4 |
-
Tags: youtube gallery,
|
5 |
Requires at least: 4.1
|
6 |
Tested up to: 5.8
|
7 |
-
Stable tag: 14.0
|
8 |
License: GPLv3 or later
|
9 |
|
10 |
YouTube Embed Plugin. Embed a responsive video, YouTube channel gallery, playlist gallery, YouTube live stream. With defer JavaScript options
|
11 |
|
12 |
== Description ==
|
13 |
|
14 |
-
**
|
15 |
|
16 |
* YouTube gallery embeds and standard videos now support Facade Mode which improves performance by loading a lighter version of the player, until it is clicked. Then the real player loads (note: for live streams, the real player is always loaded). We have tested this feature in multiple cases and found it to successfully improve your Lighthouse performance score by addressing the following recommendation: "Some third-party resources can be lazy loaded with a facade - 1 facade alternative available"
|
17 |
* Defer critical and non critical JavaScript - improve the initial load time of your pages by allowing this plugin's critical and non critical Javascript code to begin execution only after a page is loaded. That reasoning is the basis for the Defer CSS Javascript (styles and code) recommendation you'll see in various web profiling tools. We plan to allow you to defer critical and non critical CSS in the near future.
|
@@ -37,7 +37,7 @@ YouTube Embed Plugin. Embed a responsive video, YouTube channel gallery, playlis
|
|
37 |
* General playlist embedding support
|
38 |
* YouTube plugin migration support
|
39 |
|
40 |
-
**Click the Download button to start exploring
|
41 |
|
42 |
This plugin helps you easily manage the growing complexity of YouTube embedding. It provides a spectrum of basic and advanced features of the YouTube embedded player and will have you posting videos in seconds after installing it.
|
43 |
|
@@ -74,7 +74,7 @@ You can also start and end each individual video at particular times. Like the a
|
|
74 |
* start - Sets the time (in seconds) to start the video. Example: `"https://www.youtube.com/watch?v=quwebVjAEJA&width=500&height=350&start=20"`
|
75 |
* end - Sets the time (in seconds) to stop the video. Example: `"https://www.youtube.com/watch?v=quwebVjAEJA&width=500&height=350&end=100"`
|
76 |
|
77 |
-
> **About [YouTube
|
78 |
>
|
79 |
> If you like this free version, you may even upgrade to a separate Pro plugin with features like:
|
80 |
>
|
@@ -102,7 +102,7 @@ You can also start and end each individual video at particular times. Like the a
|
|
102 |
|
103 |
See more details after installing. Enjoy!
|
104 |
|
105 |
-
[
|
106 |
|
107 |
== Installation ==
|
108 |
|
@@ -152,6 +152,11 @@ You can also start and end each individual video at particular times. Like the a
|
|
152 |
|
153 |
== Changelog ==
|
154 |
|
|
|
|
|
|
|
|
|
|
|
155 |
= Embed Plus for YouTube WordPress Plugin 14.0 =
|
156 |
* New facade mode for lighter and faster page loads (see Performance tab)
|
157 |
* CSS fixes
|
1 |
=== Embed Plus for YouTube - Embed a YouTube Gallery, Channel, Playlist, Live Stream, Facade ===
|
2 |
Contributors: embedplus
|
3 |
Plugin Name: Embed Plus for YouTube - Gallery, Channel, Playlist, Live Stream
|
4 |
+
Tags: youtube gallery, youtube wordpress plugin, channel gallery, playlist gallery, defer css javascript, youtube channel, youtube live, lazy load, facade
|
5 |
Requires at least: 4.1
|
6 |
Tested up to: 5.8
|
7 |
+
Stable tag: 14.0.1
|
8 |
License: GPLv3 or later
|
9 |
|
10 |
YouTube Embed Plugin. Embed a responsive video, YouTube channel gallery, playlist gallery, YouTube live stream. With defer JavaScript options
|
11 |
|
12 |
== Description ==
|
13 |
|
14 |
+
**YouTube WordPress Plugin** to embed and customize a YouTube gallery (channel or playlist), YouTube livestream (and premiere), YouTube short, or standard YouTube video. The plugin can be customized in a wide variety of ways. It also focuses on performance with the ability to lazy load with a facade and defer JavaScript while serving minified CSS and JavaScript. Here are a few recently added features:
|
15 |
|
16 |
* YouTube gallery embeds and standard videos now support Facade Mode which improves performance by loading a lighter version of the player, until it is clicked. Then the real player loads (note: for live streams, the real player is always loaded). We have tested this feature in multiple cases and found it to successfully improve your Lighthouse performance score by addressing the following recommendation: "Some third-party resources can be lazy loaded with a facade - 1 facade alternative available"
|
17 |
* Defer critical and non critical JavaScript - improve the initial load time of your pages by allowing this plugin's critical and non critical Javascript code to begin execution only after a page is loaded. That reasoning is the basis for the Defer CSS Javascript (styles and code) recommendation you'll see in various web profiling tools. We plan to allow you to defer critical and non critical CSS in the near future.
|
37 |
* General playlist embedding support
|
38 |
* YouTube plugin migration support
|
39 |
|
40 |
+
**Click the Download button to start exploring this YouTube WordPress plugin**, or take a look at some more introductory details below.
|
41 |
|
42 |
This plugin helps you easily manage the growing complexity of YouTube embedding. It provides a spectrum of basic and advanced features of the YouTube embedded player and will have you posting videos in seconds after installing it.
|
43 |
|
74 |
* start - Sets the time (in seconds) to start the video. Example: `"https://www.youtube.com/watch?v=quwebVjAEJA&width=500&height=350&start=20"`
|
75 |
* end - Sets the time (in seconds) to stop the video. Example: `"https://www.youtube.com/watch?v=quwebVjAEJA&width=500&height=350&end=100"`
|
76 |
|
77 |
+
> **About the Pro version of the [YouTube WordPress Plugin](https://www.embedplus.com/dashboard/pro-easy-video-analytics.aspx?ref=readme)**
|
78 |
>
|
79 |
> If you like this free version, you may even upgrade to a separate Pro plugin with features like:
|
80 |
>
|
102 |
|
103 |
See more details after installing. Enjoy!
|
104 |
|
105 |
+
[This WordPress plugin is maintained by Embed Plus for YouTube >>](https://www.embedplus.com/)
|
106 |
|
107 |
== Installation ==
|
108 |
|
152 |
|
153 |
== Changelog ==
|
154 |
|
155 |
+
= Embed Plus for YouTube WordPress Plugin 14.0.1 =
|
156 |
+
* Higher resolution for facade images
|
157 |
+
* Fix CSS issue with GDPR embeds
|
158 |
+
* YouTube shorts support
|
159 |
+
|
160 |
= Embed Plus for YouTube WordPress Plugin 14.0 =
|
161 |
* New facade mode for lighter and faster page loads (see Performance tab)
|
162 |
* CSS fixes
|
scripts/ytprefs-wizard.js
CHANGED
@@ -110,7 +110,7 @@ window._EPYTWIZ_ = window._EPYTWIZ_ || {};
|
|
110 |
$('form.wizform').each(function ()
|
111 |
{
|
112 |
$thisForm = $(this);
|
113 |
-
$thisForm.find('.txturlpastecustom').on('paste', function ()
|
114 |
{
|
115 |
$thisTxtUrl = $(this);
|
116 |
setTimeout(function ()
|
@@ -119,7 +119,7 @@ window._EPYTWIZ_ = window._EPYTWIZ_ || {};
|
|
119 |
var badpaste = /<.*/i;
|
120 |
if (badpaste.test(thepaste))
|
121 |
{
|
122 |
-
var reg = new RegExp('(?:https?://)?(?:www\\.)?(?:youtu\\.be/|youtube\\.com(?:/embed/|/v/|/watch\\?v=))([\\w-]{10,12})', 'ig');
|
123 |
//get matches found for the regular expression
|
124 |
var matches = reg.exec(thepaste);
|
125 |
//check if we have found a match for a YouTube video
|
@@ -171,5 +171,18 @@ window._EPYTWIZ_ = window._EPYTWIZ_ || {};
|
|
171 |
window._EPYTWIZ_.closeme($(this).data('vid'));
|
172 |
});
|
173 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
174 |
});
|
175 |
})(jQuery);
|
110 |
$('form.wizform').each(function ()
|
111 |
{
|
112 |
$thisForm = $(this);
|
113 |
+
$thisForm.find('.txturlpastecustom').on('paste change', function ()
|
114 |
{
|
115 |
$thisTxtUrl = $(this);
|
116 |
setTimeout(function ()
|
119 |
var badpaste = /<.*/i;
|
120 |
if (badpaste.test(thepaste))
|
121 |
{
|
122 |
+
var reg = new RegExp('(?:https?://)?(?:www\\.)?(?:youtu\\.be/|youtube\\.com(?:/embed/|/shorts/|/v/|/watch\\?v=))([\\w-]{10,12})', 'ig');
|
123 |
//get matches found for the regular expression
|
124 |
var matches = reg.exec(thepaste);
|
125 |
//check if we have found a match for a YouTube video
|
171 |
window._EPYTWIZ_.closeme($(this).data('vid'));
|
172 |
});
|
173 |
|
174 |
+
$epyt_wiz_wrap.on('paste change input propertychange', '#txtUrlChannel', function ()
|
175 |
+
{
|
176 |
+
if ($(this).val().indexOf('/c/') > 0)
|
177 |
+
{
|
178 |
+
$('.error-channel-format').addClass('orange bold');
|
179 |
+
$(this).val('');
|
180 |
+
}
|
181 |
+
else
|
182 |
+
{
|
183 |
+
$('.error-channel-format').removeClass('orange bold');
|
184 |
+
}
|
185 |
+
});
|
186 |
+
|
187 |
});
|
188 |
})(jQuery);
|
scripts/ytprefs-wizard.min.js
CHANGED
@@ -1,2 +1,2 @@
|
|
1 |
|
2 |
-
window._EPYTWIZ_=window._EPYTWIZ_||{};(function(a){a.fn.followTo=function(e,b){var c=this,d=a(window);d.on("scroll",function(f){if(d.scrollTop()>e){c.css({position:"absolute",top:e})}else{c.css({position:"fixed",top:b})}})};window._EPYTWIZ_.getUrlParameter=function(b){b=b.replace(/[\[]/,"\\[").replace(/[\]]/,"\\]");var d=new RegExp("[\\?&]"+b+"=([^&#]*)");var c=d.exec(window.location.search);return c===null?"":decodeURIComponent(c[1].replace(/\+/g," "))};window._EPYTWIZ_.selectText=window._EPYTWIZ_.selectText||function(d){if(document.selection){var b=document.body.createTextRange();b.moveToElementText(d);b.select()}else{if(window.getSelection){var c=window.getSelection();var b=document.createRange();b.selectNode(d);c.removeAllRanges();c.addRange(b)}}};window._EPYTWIZ_.loadmovieplain=window._EPYTWIZ_.loadmovieplain||function(b){var c='<iframe width="600" height="368" src="//www.youtube.com/embed/~ytid?autoplay=1" frameborder="0" allowfullscreen ></iframe>';c=c.replace(/~ytid/g,b);a("#watch"+b).html(c);a("#closeme"+b).css("display","inline");a("#moviecontainer"+b).css("display","block");if(document.getElementById("scrollwatch"+b)){setTimeout(function(){a("html, body").animate({scrollTop:a("#scrollwatch"+b).offset().top-50},250,function(){})},800)}};window._EPYTWIZ_.closeme=window._EPYTWIZ_.closeme||function(b){a("#moviecontainer"+b).css("display","none");a("#watch"+b).html("")};a(document).ready(function(){a(".wiz-accordion").accordion({header:"> h3",collapsible:true,active:false,icons:{header:"ui-icon-circle-arrow-e",activeHeader:"ui-icon-circle-arrow-s"},heightStyle:"content",autoHeight:false}).find("h3.header-go").on("click",function(){window.open(a(this).find("a").attr("href"),"_blank");return false});a(".playlist-tabs").tabs();a(".livestream-tabs").tabs();if(window._EPYTWIZ_.acc_expand){a(".wiz-accordion #"+window._EPYTWIZ_.acc_expand).trigger("click")}a("form.wizform").each(function(){$thisForm=a(this);$thisForm.find(".txturlpastecustom").on("paste",function(){$thisTxtUrl=a(this);setTimeout(function(){var d=a.trim($thisTxtUrl.val());var c=/<.*/i;if(c.test(d)){var e=new RegExp("(?:https?://)?(?:www\\.)?(?:youtu\\.be/|youtube\\.com(?:/embed/|/v/|/watch\\?v=))([\\w-]{10,12})","ig");var f=e.exec(d);if(f){var g=f[1];$thisTxtUrl.val("https://www.youtube.com/watch?v="+g)}else{$thisTxtUrl.val("https://www.youtube.com/watch?v=")}$thisForm.find(".badpaste").show()}else{$thisForm.find(".badpaste").hide()}},100)})});var b=a("#epyt_wiz_wrap");b.on("click",".copycode",function(){window._EPYTWIZ_.selectText(this)});b.on("click",".inserttopost",function(){var d=window.location.toString().split("/")[0]+"//"+window.location.toString().split("/")[2];var e=a(this).attr("rel");var c=window._EPYTWIZ_.getUrlParameter("clientId");parent.postMessage("youtubeembedplus|"+e+(c?"|clientId="+c:""),d)});b.on("click",".resultdiv .load-movie",function(){window._EPYTWIZ_.loadmovieplain(a(this).closest(".resultdiv").data("vid"));return false});b.on("click",".moviecontainer a.closeme",function(){window._EPYTWIZ_.closeme(a(this).data("vid"))})})})(jQuery);
|
1 |
|
2 |
+
window._EPYTWIZ_=window._EPYTWIZ_||{};(function(a){a.fn.followTo=function(e,b){var c=this,d=a(window);d.on("scroll",function(f){if(d.scrollTop()>e){c.css({position:"absolute",top:e})}else{c.css({position:"fixed",top:b})}})};window._EPYTWIZ_.getUrlParameter=function(b){b=b.replace(/[\[]/,"\\[").replace(/[\]]/,"\\]");var d=new RegExp("[\\?&]"+b+"=([^&#]*)");var c=d.exec(window.location.search);return c===null?"":decodeURIComponent(c[1].replace(/\+/g," "))};window._EPYTWIZ_.selectText=window._EPYTWIZ_.selectText||function(d){if(document.selection){var b=document.body.createTextRange();b.moveToElementText(d);b.select()}else{if(window.getSelection){var c=window.getSelection();var b=document.createRange();b.selectNode(d);c.removeAllRanges();c.addRange(b)}}};window._EPYTWIZ_.loadmovieplain=window._EPYTWIZ_.loadmovieplain||function(b){var c='<iframe width="600" height="368" src="//www.youtube.com/embed/~ytid?autoplay=1" frameborder="0" allowfullscreen ></iframe>';c=c.replace(/~ytid/g,b);a("#watch"+b).html(c);a("#closeme"+b).css("display","inline");a("#moviecontainer"+b).css("display","block");if(document.getElementById("scrollwatch"+b)){setTimeout(function(){a("html, body").animate({scrollTop:a("#scrollwatch"+b).offset().top-50},250,function(){})},800)}};window._EPYTWIZ_.closeme=window._EPYTWIZ_.closeme||function(b){a("#moviecontainer"+b).css("display","none");a("#watch"+b).html("")};a(document).ready(function(){a(".wiz-accordion").accordion({header:"> h3",collapsible:true,active:false,icons:{header:"ui-icon-circle-arrow-e",activeHeader:"ui-icon-circle-arrow-s"},heightStyle:"content",autoHeight:false}).find("h3.header-go").on("click",function(){window.open(a(this).find("a").attr("href"),"_blank");return false});a(".playlist-tabs").tabs();a(".livestream-tabs").tabs();if(window._EPYTWIZ_.acc_expand){a(".wiz-accordion #"+window._EPYTWIZ_.acc_expand).trigger("click")}a("form.wizform").each(function(){$thisForm=a(this);$thisForm.find(".txturlpastecustom").on("paste change",function(){$thisTxtUrl=a(this);setTimeout(function(){var d=a.trim($thisTxtUrl.val());var c=/<.*/i;if(c.test(d)){var e=new RegExp("(?:https?://)?(?:www\\.)?(?:youtu\\.be/|youtube\\.com(?:/embed/|/shorts/|/v/|/watch\\?v=))([\\w-]{10,12})","ig");var f=e.exec(d);if(f){var g=f[1];$thisTxtUrl.val("https://www.youtube.com/watch?v="+g)}else{$thisTxtUrl.val("https://www.youtube.com/watch?v=")}$thisForm.find(".badpaste").show()}else{$thisForm.find(".badpaste").hide()}},100)})});var b=a("#epyt_wiz_wrap");b.on("click",".copycode",function(){window._EPYTWIZ_.selectText(this)});b.on("click",".inserttopost",function(){var d=window.location.toString().split("/")[0]+"//"+window.location.toString().split("/")[2];var e=a(this).attr("rel");var c=window._EPYTWIZ_.getUrlParameter("clientId");parent.postMessage("youtubeembedplus|"+e+(c?"|clientId="+c:""),d)});b.on("click",".resultdiv .load-movie",function(){window._EPYTWIZ_.loadmovieplain(a(this).closest(".resultdiv").data("vid"));return false});b.on("click",".moviecontainer a.closeme",function(){window._EPYTWIZ_.closeme(a(this).data("vid"))});b.on("paste change input propertychange","#txtUrlChannel",function(){if(a(this).val().indexOf("/c/")>0){a(".error-channel-format").addClass("orange bold");a(this).val("")}else{a(".error-channel-format").removeClass("orange bold")}})})})(jQuery);
|
scripts/ytprefs.js
CHANGED
@@ -506,6 +506,11 @@
|
|
506 |
}
|
507 |
});
|
508 |
|
|
|
|
|
|
|
|
|
|
|
509 |
$('button.__youtube_prefs_gdpr__').on('click', function (e)
|
510 |
{
|
511 |
e.preventDefault();
|
@@ -516,6 +521,21 @@
|
|
516 |
}
|
517 |
});
|
518 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
519 |
$('.epyt-facade-poster[data-facadeoembed]').each(function ()
|
520 |
{
|
521 |
var $facadePoster = $(this);
|
506 |
}
|
507 |
});
|
508 |
|
509 |
+
$('.__youtube_prefs_gdpr__.epyt-is-override').each(function ()
|
510 |
+
{
|
511 |
+
$(this).parent('.wp-block-embed__wrapper').addClass('epyt-is-override__wrapper');
|
512 |
+
});
|
513 |
+
|
514 |
$('button.__youtube_prefs_gdpr__').on('click', function (e)
|
515 |
{
|
516 |
e.preventDefault();
|
521 |
}
|
522 |
});
|
523 |
|
524 |
+
$('img.epyt-facade-poster').one("load", function ()
|
525 |
+
{
|
526 |
+
if (this.naturalHeight < 200)
|
527 |
+
{
|
528 |
+
var facadeOldSrc = $(this).attr("src");
|
529 |
+
$(this).attr("src", facadeOldSrc.replace('maxresdefault', 'hqdefault'));
|
530 |
+
}
|
531 |
+
}).each(function ()
|
532 |
+
{
|
533 |
+
if (this.complete)
|
534 |
+
{
|
535 |
+
$(this).trigger('load');
|
536 |
+
}
|
537 |
+
});
|
538 |
+
|
539 |
$('.epyt-facade-poster[data-facadeoembed]').each(function ()
|
540 |
{
|
541 |
var $facadePoster = $(this);
|
scripts/ytprefs.min.js
CHANGED
@@ -1,2 +1,2 @@
|
|
1 |
|
2 |
-
(function(a,b){a._EPYT_=a._EPYT_||{ajaxurl:"/wp-admin/admin-ajax.php",security:"",gallery_scrolloffset:100,eppathtoscripts:"/wp-content/plugins/youtube-embed-plus/scripts/",eppath:"/wp-content/plugins/youtube-embed-plus/",epresponsiveselector:["iframe.__youtube_prefs_widget__"],epdovol:true,evselector:'iframe.__youtube_prefs__[src], iframe[src*="youtube.com/embed/"], iframe[src*="youtube-nocookie.com/embed/"]',stopMobileBuffer:true,ajax_compat:false,usingdefault:true,ytapi_load:"light",pause_others:false};a._EPYT_.touchmoved=false;a._EPYT_.apiVideos=a._EPYT_.apiVideos||{};if(a.location.toString().indexOf("https://")===0){a._EPYT_.ajaxurl=a._EPYT_.ajaxurl.replace("http://","https://")}a._EPYT_.pageLoaded=false;b(a).on("load._EPYT_",function(){a._EPYT_.pageLoaded=true});if(!document.querySelectorAll){document.querySelectorAll=function(d){var f=document,e=f.documentElement.firstChild,c=f.createElement("STYLE");e.appendChild(c);f.__qsaels=[];c.styleSheet.cssText=d+"{x:expression(document.__qsaels.push(this))}";a.scrollBy(0,0);return f.__qsaels}}if(typeof a._EPADashboard_==="undefined"){a._EPADashboard_={initStarted:false,checkCount:0,onPlayerReady:function(h){try{if(typeof _EPYT_.epdovol!=="undefined"&&_EPYT_.epdovol){var f=parseInt(h.target.getIframe().getAttribute("data-vol"));if(!isNaN(f)){if(f===0){h.target.mute()}else{if(h.target.isMuted()){h.target.unMute()}h.target.setVolume(f)}}}var e=parseInt(h.target.getIframe().getAttribute("data-epautoplay"));if(!isNaN(e)&&e===1){h.target.playVideo()}}catch(g){}try{var d=h.target.getIframe().getAttribute("id");a._EPYT_.apiVideos[d]=h.target}catch(c){}},onPlayerStateChange:function(f){var e=f.target.getIframe();if(a._EPYT_.pause_others&&f.data===a.YT.PlayerState.PLAYING){a._EPADashboard_.pauseOthers(f.target)}if(f.data===a.YT.PlayerState.PLAYING&&f.target.ponce!==true&&e.src.indexOf("autoplay=1")===-1){f.target.ponce=true}if(f.data===a.YT.PlayerState.ENDED&&b(e).data("relstop")=="1"){if(typeof f.target.stopVideo==="function"){f.target.stopVideo()}else{var g=b(e).clone(true).off();g.attr("src",a._EPADashboard_.cleanSrc(g.attr("src").replace("autoplay=1","autoplay=0")));b(e).replaceWith(g);a._EPADashboard_.setupevents(g.attr("id"));e=g.get(0)}}var c=b(e).closest(".epyt-gallery");if(!c.length){c=b("#"+b(e).data("epytgalleryid"))}if(c.length){var d=c.find(".epyt-pagebutton").first().data("autonext")=="1";if(d&&f.data===a.YT.PlayerState.ENDED){var h=c.find(".epyt-current-video");if(!h.length){h=c.find(".epyt-gallery-thumb").first()}var i=h.find(" ~ .epyt-gallery-thumb").first();if(i.length){i.trigger("click")}else{c.find('.epyt-pagebutton.epyt-next[data-pagetoken!=""][data-pagetoken]').first().trigger("click")}}}},isMobile:function(){return/Mobi|Android/i.test(navigator.userAgent)},videoEqual:function(d,c){if(d.getIframe&&c.getIframe&&d.getIframe().id===c.getIframe().id){return true}return false},pauseOthers:function(e){if(!e){return}for(var d in a._EPYT_.apiVideos){var c=a._EPYT_.apiVideos[d];if(c&&typeof c.pauseVideo==="function"&&c!=e&&!_EPADashboard_.videoEqual(c,e)&&typeof c.getPlayerState==="function"&&[YT.PlayerState.BUFFERING,a.YT.PlayerState.PLAYING].indexOf(c.getPlayerState())>=0){c.pauseVideo()}}},justid:function(c){return new RegExp("[\\?&]v=([^&#]*)").exec(c)[1]},setupevents:function(e){if(typeof(a.YT)!=="undefined"&&a.YT!==null&&a.YT.loaded){var c=document.getElementById(e);if(!c.epytsetupdone){a._EPADashboard_.log("Setting up YT API events: "+e);c.epytsetupdone=true;var d={events:{onReady:a._EPADashboard_.onPlayerReady,onStateChange:a._EPADashboard_.onPlayerStateChange},host:(c.src||"").indexOf("nocookie")>0?"https://www.youtube-nocookie.com":"https://www.youtube.com"};return new a.YT.Player(e,d)}}},apiInit:function(){if(typeof(a.YT)!=="undefined"){a._EPADashboard_.initStarted=true;var c=document.querySelectorAll(_EPYT_.evselector);for(var d=0;d<c.length;d++){if(!c[d].hasAttribute("id")){c[d].id="_dytid_"+Math.round(Math.random()*8999+1000)}a._EPADashboard_.setupevents(c[d].id)}}},log:function(d){try{console.log(d)}catch(c){}},doubleCheck:function(){a._EPADashboard_.checkInterval=setInterval(function(){a._EPADashboard_.checkCount++;if(a._EPADashboard_.checkCount>=5||a._EPADashboard_.initStarted){clearInterval(a._EPADashboard_.checkInterval)}else{a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API init check")}},1000)},selectText:function(e){if(document.selection){var c=document.body.createTextRange();c.moveToElementText(e);c.select()}else{if(a.getSelection){var d=a.getSelection();var c=document.createRange();c.selectNode(e);d.removeAllRanges();d.addRange(c)}}},setVidSrc:function(c,d){if(c.is(".epyt-facade")){c.attr("data-facadesrc",a._EPADashboard_.cleanSrc(d));c.trigger("click")}else{c.attr("src",a._EPADashboard_.cleanSrc(d));c.get(0).epytsetupdone=false;a._EPADashboard_.setupevents(c.attr("id"))}},cleanSrc:function(d){var c=d.replace("enablejsapi=1?enablejsapi=1","enablejsapi=1");return c},loadYTAPI:function(){if(typeof a.YT==="undefined"){if(a._EPYT_.ytapi_load!=="never"&&(a._EPYT_.ytapi_load==="always"||b('iframe[src*="youtube.com/embed/"], iframe[data-src*="youtube.com/embed/"], .__youtube_prefs__').length)){var c=document.createElement("script");c.src="https://www.youtube.com/iframe_api";c.type="text/javascript";document.getElementsByTagName("head")[0].appendChild(c)}}else{if(a.YT.loaded){if(a._EPYT_.pageLoaded){a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API available")}else{b(a).on("load._EPYT_",function(){a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API available 2")})}}}},pageReady:function(){b(".epyt-gallery").each(function(){var f=b(this);if(!f.data("epytevents")||!b("body").hasClass("block-editor-page")){f.data("epytevents","1");var e=b(this).find("iframe, div.__youtube_prefs_gdpr__, div.epyt-facade").first();var c=e.data("src")||e.data("facadesrc")||e.attr("src");if(!c){c=e.data("ep-src")}var d=b(this).find(".epyt-gallery-list .epyt-gallery-thumb").first().data("videoid");if(typeof(c)!=="undefined"){c=c.replace(d,"GALLERYVIDEOID");f.data("ep-gallerysrc",c)}else{if(e.hasClass("__youtube_prefs_gdpr__")){f.data("ep-gallerysrc","")}}f.on("click touchend",".epyt-gallery-list .epyt-gallery-thumb",function(k){e=f.find("iframe, div.__youtube_prefs_gdpr__, div.epyt-facade").first();if(a._EPYT_.touchmoved){return}if(!b(this).hasClass("epyt-current-video")){f.find(".epyt-gallery-list .epyt-gallery-thumb").removeClass("epyt-current-video");b(this).addClass("epyt-current-video");var g=b(this).data("videoid");f.data("currvid",g);var l=f.data("ep-gallerysrc").replace("GALLERYVIDEOID",g);var j=f.find(".epyt-pagebutton").first().data("thumbplay");if(j!=="0"&&j!==0){if(l.indexOf("autoplay")>0){l=l.replace("autoplay=0","autoplay=1")}else{l+="&autoplay=1"}e.addClass("epyt-thumbplay")}var h=Math.max(b("body").scrollTop(),b("html").scrollTop());var i=e.offset().top-parseInt(_EPYT_.gallery_scrolloffset);if(h>i){b("html, body").animate({scrollTop:i},500,function(){a._EPADashboard_.setVidSrc(e,l)})}else{a._EPADashboard_.setVidSrc(e,l)}}}).on("touchmove",function(g){a._EPYT_.touchmoved=true}).on("touchstart",function(){a._EPYT_.touchmoved=false}).on("keydown",".epyt-gallery-list .epyt-gallery-thumb, .epyt-pagebutton",function(h){var g=h.which;if((g===13)||(g===32)){h.preventDefault();b(this).trigger("click")}});f.on("mouseenter",".epyt-gallery-list .epyt-gallery-thumb",function(){b(this).addClass("hover")});f.on("mouseleave",".epyt-gallery-list .epyt-gallery-thumb",function(){b(this).removeClass("hover")});f.on("click touchend",".epyt-pagebutton",function(k){if(a._EPYT_.touchmoved){return}if(!f.find(".epyt-gallery-list").hasClass("epyt-loading")){f.find(".epyt-gallery-list").addClass("epyt-loading");var g=typeof(k.originalEvent)!=="undefined";var j={action:"my_embedplus_gallery_page",security:_EPYT_.security,options:{playlistId:b(this).data("playlistid"),pageToken:b(this).data("pagetoken"),pageSize:b(this).data("pagesize"),columns:b(this).data("epcolumns"),showTitle:b(this).data("showtitle"),showPaging:b(this).data("showpaging"),autonext:b(this).data("autonext"),thumbplay:b(this).data("thumbplay")}};var h=b(this).hasClass("epyt-next");var i=parseInt(f.data("currpage")+"");i+=h?1:-1;f.data("currpage",i);b.post(_EPYT_.ajaxurl,j,function(l){f.find(".epyt-gallery-list").html(l);f.find(".epyt-current").each(function(){b(this).text(f.data("currpage"))});f.find('.epyt-gallery-thumb[data-videoid="'+f.data("currvid")+'"]').addClass("epyt-current-video");if(f.find(".epyt-pagebutton").first().data("autonext")=="1"&&!g){f.find(".epyt-gallery-thumb").first().trigger("click")}}).fail(function(){alert("Sorry, there was an error loading the next page.")}).always(function(){f.find(".epyt-gallery-list").removeClass("epyt-loading");if(f.find(".epyt-pagebutton").first().data("autonext")!="1"){var l=Math.max(b("body").scrollTop(),b("html").scrollTop());var m=f.find(".epyt-gallery-list").offset().top-parseInt(_EPYT_.gallery_scrolloffset);if(l>m){b("html, body").animate({scrollTop:m},500)}}})}}).on("touchmove",function(g){a._EPYT_.touchmoved=true}).on("touchstart",function(){a._EPYT_.touchmoved=false})}});b("button.__youtube_prefs_gdpr__").on("click",function(c){c.preventDefault();if(b.cookie){b.cookie("ytprefs_gdpr_consent","1",{expires:30,path:"/"});a.top.location.reload()}});b(".epyt-facade-poster[data-facadeoembed]").each(function(){var c=b(this);var d="https://www.youtube.com/"+c.data("facadeoembed");b.get("https://youtube.com/oembed",{url:d,format:"json"},function(e){c.attr("src",e.thumbnail_url)},"json").fail(function(){}).always(function(){})});b(".epyt-facade").on("click",function(j){var h=b(this);var d=h.attr("data-facadesrc");d=a._EPADashboard_.cleanSrc(d);var f=document.createElement("iframe");for(var c=0;c<this.attributes.length;c++){var g=this.attributes[c];if(["allow","class","height","id","width"].indexOf(g.name.toLowerCase())>=0||g.name.toLowerCase().indexOf("data-")==0){b(f).attr(g.name,g.value)}}b(f).removeClass("epyt-facade");b(f).attr("allowfullscreen","").attr("title",h.find("img").attr("alt")).attr("allow","accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture");a._EPADashboard_.loadYTAPI();h.replaceWith(f);b(f).attr("src",d);a._EPADashboard_.setupevents(b(f).attr("id"));setTimeout(function(){b(b(f).parent()).fitVidsEP()},1)})}}}a.onYouTubeIframeAPIReady=typeof a.onYouTubeIframeAPIReady!=="undefined"?a.onYouTubeIframeAPIReady:function(){if(a._EPYT_.pageLoaded){a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API ready")}else{b(a).on("load._EPYT_",function(){a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API ready 2")})}};a._EPADashboard_.loadYTAPI();if(a._EPYT_.pageLoaded){a._EPADashboard_.doubleCheck()}else{b(a).on("load._EPYT_",function(){a._EPADashboard_.doubleCheck()})}b(document).ready(function(){a._EPADashboard_.pageReady();a._EPADashboard_.loadYTAPI();if(a._EPYT_.ajax_compat){b(a).on("load._EPYT_",function(){b(document).ajaxSuccess(function(d,f,c){if(f&&f.responseText&&f.responseText.indexOf("<iframe ")!==-1){a._EPADashboard_.loadYTAPI();a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API AJAX");a._EPADashboard_.pageReady()}})})}})})(window,jQuery);
|
1 |
|
2 |
+
(function(a,b){a._EPYT_=a._EPYT_||{ajaxurl:"/wp-admin/admin-ajax.php",security:"",gallery_scrolloffset:100,eppathtoscripts:"/wp-content/plugins/youtube-embed-plus/scripts/",eppath:"/wp-content/plugins/youtube-embed-plus/",epresponsiveselector:["iframe.__youtube_prefs_widget__"],epdovol:true,evselector:'iframe.__youtube_prefs__[src], iframe[src*="youtube.com/embed/"], iframe[src*="youtube-nocookie.com/embed/"]',stopMobileBuffer:true,ajax_compat:false,usingdefault:true,ytapi_load:"light",pause_others:false};a._EPYT_.touchmoved=false;a._EPYT_.apiVideos=a._EPYT_.apiVideos||{};if(a.location.toString().indexOf("https://")===0){a._EPYT_.ajaxurl=a._EPYT_.ajaxurl.replace("http://","https://")}a._EPYT_.pageLoaded=false;b(a).on("load._EPYT_",function(){a._EPYT_.pageLoaded=true});if(!document.querySelectorAll){document.querySelectorAll=function(d){var f=document,e=f.documentElement.firstChild,c=f.createElement("STYLE");e.appendChild(c);f.__qsaels=[];c.styleSheet.cssText=d+"{x:expression(document.__qsaels.push(this))}";a.scrollBy(0,0);return f.__qsaels}}if(typeof a._EPADashboard_==="undefined"){a._EPADashboard_={initStarted:false,checkCount:0,onPlayerReady:function(h){try{if(typeof _EPYT_.epdovol!=="undefined"&&_EPYT_.epdovol){var f=parseInt(h.target.getIframe().getAttribute("data-vol"));if(!isNaN(f)){if(f===0){h.target.mute()}else{if(h.target.isMuted()){h.target.unMute()}h.target.setVolume(f)}}}var e=parseInt(h.target.getIframe().getAttribute("data-epautoplay"));if(!isNaN(e)&&e===1){h.target.playVideo()}}catch(g){}try{var d=h.target.getIframe().getAttribute("id");a._EPYT_.apiVideos[d]=h.target}catch(c){}},onPlayerStateChange:function(f){var e=f.target.getIframe();if(a._EPYT_.pause_others&&f.data===a.YT.PlayerState.PLAYING){a._EPADashboard_.pauseOthers(f.target)}if(f.data===a.YT.PlayerState.PLAYING&&f.target.ponce!==true&&e.src.indexOf("autoplay=1")===-1){f.target.ponce=true}if(f.data===a.YT.PlayerState.ENDED&&b(e).data("relstop")=="1"){if(typeof f.target.stopVideo==="function"){f.target.stopVideo()}else{var g=b(e).clone(true).off();g.attr("src",a._EPADashboard_.cleanSrc(g.attr("src").replace("autoplay=1","autoplay=0")));b(e).replaceWith(g);a._EPADashboard_.setupevents(g.attr("id"));e=g.get(0)}}var c=b(e).closest(".epyt-gallery");if(!c.length){c=b("#"+b(e).data("epytgalleryid"))}if(c.length){var d=c.find(".epyt-pagebutton").first().data("autonext")=="1";if(d&&f.data===a.YT.PlayerState.ENDED){var h=c.find(".epyt-current-video");if(!h.length){h=c.find(".epyt-gallery-thumb").first()}var i=h.find(" ~ .epyt-gallery-thumb").first();if(i.length){i.trigger("click")}else{c.find('.epyt-pagebutton.epyt-next[data-pagetoken!=""][data-pagetoken]').first().trigger("click")}}}},isMobile:function(){return/Mobi|Android/i.test(navigator.userAgent)},videoEqual:function(d,c){if(d.getIframe&&c.getIframe&&d.getIframe().id===c.getIframe().id){return true}return false},pauseOthers:function(e){if(!e){return}for(var d in a._EPYT_.apiVideos){var c=a._EPYT_.apiVideos[d];if(c&&typeof c.pauseVideo==="function"&&c!=e&&!_EPADashboard_.videoEqual(c,e)&&typeof c.getPlayerState==="function"&&[YT.PlayerState.BUFFERING,a.YT.PlayerState.PLAYING].indexOf(c.getPlayerState())>=0){c.pauseVideo()}}},justid:function(c){return new RegExp("[\\?&]v=([^&#]*)").exec(c)[1]},setupevents:function(e){if(typeof(a.YT)!=="undefined"&&a.YT!==null&&a.YT.loaded){var c=document.getElementById(e);if(!c.epytsetupdone){a._EPADashboard_.log("Setting up YT API events: "+e);c.epytsetupdone=true;var d={events:{onReady:a._EPADashboard_.onPlayerReady,onStateChange:a._EPADashboard_.onPlayerStateChange},host:(c.src||"").indexOf("nocookie")>0?"https://www.youtube-nocookie.com":"https://www.youtube.com"};return new a.YT.Player(e,d)}}},apiInit:function(){if(typeof(a.YT)!=="undefined"){a._EPADashboard_.initStarted=true;var c=document.querySelectorAll(_EPYT_.evselector);for(var d=0;d<c.length;d++){if(!c[d].hasAttribute("id")){c[d].id="_dytid_"+Math.round(Math.random()*8999+1000)}a._EPADashboard_.setupevents(c[d].id)}}},log:function(d){try{console.log(d)}catch(c){}},doubleCheck:function(){a._EPADashboard_.checkInterval=setInterval(function(){a._EPADashboard_.checkCount++;if(a._EPADashboard_.checkCount>=5||a._EPADashboard_.initStarted){clearInterval(a._EPADashboard_.checkInterval)}else{a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API init check")}},1000)},selectText:function(e){if(document.selection){var c=document.body.createTextRange();c.moveToElementText(e);c.select()}else{if(a.getSelection){var d=a.getSelection();var c=document.createRange();c.selectNode(e);d.removeAllRanges();d.addRange(c)}}},setVidSrc:function(c,d){if(c.is(".epyt-facade")){c.attr("data-facadesrc",a._EPADashboard_.cleanSrc(d));c.trigger("click")}else{c.attr("src",a._EPADashboard_.cleanSrc(d));c.get(0).epytsetupdone=false;a._EPADashboard_.setupevents(c.attr("id"))}},cleanSrc:function(d){var c=d.replace("enablejsapi=1?enablejsapi=1","enablejsapi=1");return c},loadYTAPI:function(){if(typeof a.YT==="undefined"){if(a._EPYT_.ytapi_load!=="never"&&(a._EPYT_.ytapi_load==="always"||b('iframe[src*="youtube.com/embed/"], iframe[data-src*="youtube.com/embed/"], .__youtube_prefs__').length)){var c=document.createElement("script");c.src="https://www.youtube.com/iframe_api";c.type="text/javascript";document.getElementsByTagName("head")[0].appendChild(c)}}else{if(a.YT.loaded){if(a._EPYT_.pageLoaded){a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API available")}else{b(a).on("load._EPYT_",function(){a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API available 2")})}}}},pageReady:function(){b(".epyt-gallery").each(function(){var f=b(this);if(!f.data("epytevents")||!b("body").hasClass("block-editor-page")){f.data("epytevents","1");var e=b(this).find("iframe, div.__youtube_prefs_gdpr__, div.epyt-facade").first();var c=e.data("src")||e.data("facadesrc")||e.attr("src");if(!c){c=e.data("ep-src")}var d=b(this).find(".epyt-gallery-list .epyt-gallery-thumb").first().data("videoid");if(typeof(c)!=="undefined"){c=c.replace(d,"GALLERYVIDEOID");f.data("ep-gallerysrc",c)}else{if(e.hasClass("__youtube_prefs_gdpr__")){f.data("ep-gallerysrc","")}}f.on("click touchend",".epyt-gallery-list .epyt-gallery-thumb",function(k){e=f.find("iframe, div.__youtube_prefs_gdpr__, div.epyt-facade").first();if(a._EPYT_.touchmoved){return}if(!b(this).hasClass("epyt-current-video")){f.find(".epyt-gallery-list .epyt-gallery-thumb").removeClass("epyt-current-video");b(this).addClass("epyt-current-video");var g=b(this).data("videoid");f.data("currvid",g);var l=f.data("ep-gallerysrc").replace("GALLERYVIDEOID",g);var j=f.find(".epyt-pagebutton").first().data("thumbplay");if(j!=="0"&&j!==0){if(l.indexOf("autoplay")>0){l=l.replace("autoplay=0","autoplay=1")}else{l+="&autoplay=1"}e.addClass("epyt-thumbplay")}var h=Math.max(b("body").scrollTop(),b("html").scrollTop());var i=e.offset().top-parseInt(_EPYT_.gallery_scrolloffset);if(h>i){b("html, body").animate({scrollTop:i},500,function(){a._EPADashboard_.setVidSrc(e,l)})}else{a._EPADashboard_.setVidSrc(e,l)}}}).on("touchmove",function(g){a._EPYT_.touchmoved=true}).on("touchstart",function(){a._EPYT_.touchmoved=false}).on("keydown",".epyt-gallery-list .epyt-gallery-thumb, .epyt-pagebutton",function(h){var g=h.which;if((g===13)||(g===32)){h.preventDefault();b(this).trigger("click")}});f.on("mouseenter",".epyt-gallery-list .epyt-gallery-thumb",function(){b(this).addClass("hover")});f.on("mouseleave",".epyt-gallery-list .epyt-gallery-thumb",function(){b(this).removeClass("hover")});f.on("click touchend",".epyt-pagebutton",function(k){if(a._EPYT_.touchmoved){return}if(!f.find(".epyt-gallery-list").hasClass("epyt-loading")){f.find(".epyt-gallery-list").addClass("epyt-loading");var g=typeof(k.originalEvent)!=="undefined";var j={action:"my_embedplus_gallery_page",security:_EPYT_.security,options:{playlistId:b(this).data("playlistid"),pageToken:b(this).data("pagetoken"),pageSize:b(this).data("pagesize"),columns:b(this).data("epcolumns"),showTitle:b(this).data("showtitle"),showPaging:b(this).data("showpaging"),autonext:b(this).data("autonext"),thumbplay:b(this).data("thumbplay")}};var h=b(this).hasClass("epyt-next");var i=parseInt(f.data("currpage")+"");i+=h?1:-1;f.data("currpage",i);b.post(_EPYT_.ajaxurl,j,function(l){f.find(".epyt-gallery-list").html(l);f.find(".epyt-current").each(function(){b(this).text(f.data("currpage"))});f.find('.epyt-gallery-thumb[data-videoid="'+f.data("currvid")+'"]').addClass("epyt-current-video");if(f.find(".epyt-pagebutton").first().data("autonext")=="1"&&!g){f.find(".epyt-gallery-thumb").first().trigger("click")}}).fail(function(){alert("Sorry, there was an error loading the next page.")}).always(function(){f.find(".epyt-gallery-list").removeClass("epyt-loading");if(f.find(".epyt-pagebutton").first().data("autonext")!="1"){var l=Math.max(b("body").scrollTop(),b("html").scrollTop());var m=f.find(".epyt-gallery-list").offset().top-parseInt(_EPYT_.gallery_scrolloffset);if(l>m){b("html, body").animate({scrollTop:m},500)}}})}}).on("touchmove",function(g){a._EPYT_.touchmoved=true}).on("touchstart",function(){a._EPYT_.touchmoved=false})}});b(".__youtube_prefs_gdpr__.epyt-is-override").each(function(){b(this).parent(".wp-block-embed__wrapper").addClass("epyt-is-override__wrapper")});b("button.__youtube_prefs_gdpr__").on("click",function(c){c.preventDefault();if(b.cookie){b.cookie("ytprefs_gdpr_consent","1",{expires:30,path:"/"});a.top.location.reload()}});b("img.epyt-facade-poster").one("load",function(){if(this.naturalHeight<200){var c=b(this).attr("src");b(this).attr("src",c.replace("maxresdefault","hqdefault"))}}).each(function(){if(this.complete){b(this).trigger("load")}});b(".epyt-facade-poster[data-facadeoembed]").each(function(){var c=b(this);var d="https://www.youtube.com/"+c.data("facadeoembed");b.get("https://youtube.com/oembed",{url:d,format:"json"},function(e){c.attr("src",e.thumbnail_url)},"json").fail(function(){}).always(function(){})});b(".epyt-facade").on("click",function(j){var h=b(this);var d=h.attr("data-facadesrc");d=a._EPADashboard_.cleanSrc(d);var f=document.createElement("iframe");for(var c=0;c<this.attributes.length;c++){var g=this.attributes[c];if(["allow","class","height","id","width"].indexOf(g.name.toLowerCase())>=0||g.name.toLowerCase().indexOf("data-")==0){b(f).attr(g.name,g.value)}}b(f).removeClass("epyt-facade");b(f).attr("allowfullscreen","").attr("title",h.find("img").attr("alt")).attr("allow","accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture");a._EPADashboard_.loadYTAPI();h.replaceWith(f);b(f).attr("src",d);a._EPADashboard_.setupevents(b(f).attr("id"));setTimeout(function(){b(b(f).parent()).fitVidsEP()},1)})}}}a.onYouTubeIframeAPIReady=typeof a.onYouTubeIframeAPIReady!=="undefined"?a.onYouTubeIframeAPIReady:function(){if(a._EPYT_.pageLoaded){a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API ready")}else{b(a).on("load._EPYT_",function(){a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API ready 2")})}};a._EPADashboard_.loadYTAPI();if(a._EPYT_.pageLoaded){a._EPADashboard_.doubleCheck()}else{b(a).on("load._EPYT_",function(){a._EPADashboard_.doubleCheck()})}b(document).ready(function(){a._EPADashboard_.pageReady();a._EPADashboard_.loadYTAPI();if(a._EPYT_.ajax_compat){b(a).on("load._EPYT_",function(){b(document).ajaxSuccess(function(d,f,c){if(f&&f.responseText&&f.responseText.indexOf("<iframe ")!==-1){a._EPADashboard_.loadYTAPI();a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API AJAX");a._EPADashboard_.pageReady()}})})}})})(window,jQuery);
|
styles/ytprefs.css
CHANGED
@@ -439,14 +439,42 @@ body .epyt-gallery-img-gdpr {
|
|
439 |
fill-opacity: 1;
|
440 |
}
|
441 |
|
442 |
-
.wp-block-embed.wp-has-aspect-ratio .wp-block-embed__wrapper .epyt-is-override.epyt-facade
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
443 |
.wp-block-embed.wp-has-aspect-ratio .wp-block-embed__wrapper .epyt-is-override.__youtube_prefs_gdpr__
|
|
|
|
|
|
|
|
|
|
|
444 |
{
|
445 |
position: absolute;
|
446 |
top: 0;
|
447 |
right: 0;
|
448 |
bottom: 0;
|
449 |
left: 0;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
450 |
}
|
451 |
|
452 |
/********* YTVI */
|
439 |
fill-opacity: 1;
|
440 |
}
|
441 |
|
442 |
+
.wp-embed-responsive .wp-block-embed.wp-has-aspect-ratio .wp-block-embed__wrapper .epyt-is-override.epyt-facade
|
443 |
+
{
|
444 |
+
position: absolute;
|
445 |
+
top: 0;
|
446 |
+
right: 0;
|
447 |
+
bottom: 0;
|
448 |
+
left: 0;
|
449 |
+
}
|
450 |
+
|
451 |
.wp-block-embed.wp-has-aspect-ratio .wp-block-embed__wrapper .epyt-is-override.__youtube_prefs_gdpr__
|
452 |
+
{
|
453 |
+
position: relative;
|
454 |
+
}
|
455 |
+
|
456 |
+
.wp-embed-responsive .wp-block-embed.wp-has-aspect-ratio .wp-block-embed__wrapper .epyt-is-override.__youtube_prefs_gdpr__
|
457 |
{
|
458 |
position: absolute;
|
459 |
top: 0;
|
460 |
right: 0;
|
461 |
bottom: 0;
|
462 |
left: 0;
|
463 |
+
overflow-y: auto;
|
464 |
+
}
|
465 |
+
|
466 |
+
.wp-embed-responsive .wp-block-embed.wp-has-aspect-ratio .wp-block-embed__wrapper.epyt-is-override__wrapper:before
|
467 |
+
{
|
468 |
+
padding: 0;
|
469 |
+
}
|
470 |
+
|
471 |
+
.wp-embed-responsive .wp-block-embed.wp-has-aspect-ratio .wp-block-embed__wrapper.epyt-is-override__wrapper .epyt-is-override.__youtube_prefs_gdpr__
|
472 |
+
{
|
473 |
+
position: relative;
|
474 |
+
top: unset;
|
475 |
+
right: unset;
|
476 |
+
bottom: unset;
|
477 |
+
left: unset;
|
478 |
}
|
479 |
|
480 |
/********* YTVI */
|
styles/ytprefs.min.css
CHANGED
@@ -1,2 +1,2 @@
|
|
1 |
|
2 |
-
.epyt-debug{cursor:pointer;text-align:left;background-color:#ddd;color:#000}iframe.__youtube_prefs__{border-width:0}.epyt-gallery{text-align:center}.epyt-gallery iframe{margin-bottom:0}.epyt-gallery.epyt-lb iframe{display:none;height:0!important}.epyt-gallery-list{margin:0 -8px 0 -8px;position:relative;transition:opacity ease-out .3s;display:block}.epyt-gallery-list .epyt-gallery-thumb{box-sizing:border-box}.epyt-gallery-list p{display:none}.epyt-gallery-clear{clear:both}.epyt-gallery-list.epyt-loading{opacity:.5;transition:opacity ease-out .3s}.epyt-gallery-thumb{position:relative;box-sizing:border-box;overflow-y:hidden;display:block!important;cursor:pointer;opacity:1;float:left;padding:0 8px 10px 8px;height:auto}.epyt-gallery-thumb.hover{position:relative;opacity:1;transition:opacity ease-out .3s;height:auto}.epyt-gallery-img-box{width:100%}.epyt-gallery-img{height:0;width:100%;padding-top:56.25%!important;position:relative;overflow:hidden!important;background-size:cover!important;background-position:center!important}.epyt-gallery-playhover{opacity:0;position:absolute;top:-10px;left:0;width:100%;height:100%;vertical-align:middle;text-align:center;transition:opacity ease-out .3s}.epyt-gallery-thumb.hover .epyt-gallery-playhover,.epyt-gallery-thumb.epyt-current-video .epyt-gallery-playhover{opacity:1;top:0;transition:all ease-out .3s}.epyt-gallery-thumb .epyt-gallery-playcrutch{display:inline-block;height:100%;vertical-align:middle;width:0}.epyt-gallery-playhover .epyt-play-img{height:auto!important;max-width:15%!important;padding:0!important;margin:0!important;min-width:30px!important;vertical-align:middle!important;display:inline-block!important;width:auto;border:0;box-sizing:border-box}.epyt-gallery-title{font-size:80%;line-height:120%;padding:10px}.epyt-gallery-notitle{padding:4px}.epyt-gallery-notitle span{display:none}.epyt-gallery-rowtitle{text-align:center;width:100%;position:absolute;left:0;top:100%;opacity:0;z-index:10;overflow-x:hidden;text-overflow:ellipsis;white-space:nowrap}.epyt-gallery-rowtitle.hover{opacity:1;transition:opacity linear .2s}.epyt-gallery-rowbreak{clear:both}.epyt-pagination{clear:both;text-align:center;padding:10px 8px 10px 8px}.epyt-pagination.epyt-hide-pagination *{display:none!important}.epyt-pagination>div,.epyt-pagenumbers>div{display:inline-block;padding:0 2px 0 2px;vertical-align:middle}.epyt-pagination .epyt-pagebutton{cursor:pointer;display:inline-block;padding:0 10px 0 10px}.epyt-pagebutton>div{display:inline}.epyt-pagination .epyt-loader{display:none}.epyt-gallery-list.epyt-loading .epyt-pagination .epyt-loader{display:inline-block}body .lity-container{width:100%;max-width:964px}.epyt-curtain .lity-opened iframe{opacity:0;transition:opacity .3s linear .5s}.epyt-gallery-allthumbs.epyt-cols-1 .epyt-gallery-thumb{width:100%}.epyt-gallery-allthumbs.epyt-cols-2 .epyt-gallery-thumb{width:50%}.epyt-gallery-allthumbs.epyt-cols-3 .epyt-gallery-thumb{width:33.333%}.epyt-gallery-allthumbs.epyt-cols-4 .epyt-gallery-thumb{width:25%}.epyt-gallery-allthumbs.epyt-cols-5 .epyt-gallery-thumb{width:20%}.epyt-gallery-allthumbs.epyt-cols-6 .epyt-gallery-thumb{width:16.666%}.epyt-gallery-allthumbs.epyt-cols-7 .epyt-gallery-thumb{width:14.285%}.epyt-gallery-allthumbs.epyt-cols-8 .epyt-gallery-thumb{width:12.5%}.epyt-gallery-allthumbs.epyt-cols-9 .epyt-gallery-thumb{width:11.111%}.epyt-gallery-allthumbs.epyt-cols-10 .epyt-gallery-thumb{width:10%}.epyt-gallery-allthumbs.epyt-cols-11 .epyt-gallery-thumb{width:9.090%}.epyt-gallery-allthumbs.epyt-cols-12 .epyt-gallery-thumb{width:8.333%}.epyt-gallery-allthumbs.epyt-cols-13 .epyt-gallery-thumb{width:7.692%}.epyt-gallery-allthumbs.epyt-cols-14 .epyt-gallery-thumb{width:7.142%}.epyt-gallery-allthumbs.epyt-cols-15 .epyt-gallery-thumb{width:6.666%}.epyt-gallery-allthumbs.epyt-cols-16 .epyt-gallery-thumb{width:6.25%}.epyt-gallery-allthumbs.epyt-cols-17 .epyt-gallery-thumb{width:5.882%}.epyt-gallery-allthumbs.epyt-cols-18 .epyt-gallery-thumb{width:5.555%}.epyt-gallery-allthumbs.epyt-cols-19 .epyt-gallery-thumb{width:5.263%}.epyt-gallery-allthumbs.epyt-cols-20 .epyt-gallery-thumb{width:5%}.epyt-pagebutton.hide,.epyt-pagenumbers.hide{display:none!important;opacity:0!important;visibility:hidden!important}.epyt-gallery-subscribe{text-align:center;padding:15px 0 10px 0;clear:both}.epyt-gallery-subscribe a.epyt-gallery-subbutton,.epyt-gallery-subscribe a.epyt-gallery-subbutton:hover{display:inline-block;padding:5px 10px;background-color:#e62117!important;color:#fff!important;text-decoration:none!important;border-radius:3px}.epyt-gallery-subscribe a.epyt-gallery-subbutton img{width:20px!important;height:auto!important;vertical-align:middle!important;padding:0 6px 3px 0;display:inline-block;background:transparent;-webkit-box-shadow:none;box-shadow:none;margin:0}body div.__youtube_prefs__.__youtube_prefs_gdpr__{background-color:#000;background-image:-webkit-linear-gradient(top,#000,#444);background-image:linear-gradient(to bottom,#000,#444);padding:25px;height:auto;text-align:left}body div.__youtube_prefs__.__youtube_prefs_gdpr__ *{color:#e3e3e3!important}body div.__youtube_prefs__.__youtube_prefs_gdpr__ a{text-decoration:underline}body div.__youtube_prefs__.__youtube_prefs_gdpr__ button.__youtube_prefs_gdpr__,body div.__youtube_prefs__.__youtube_prefs_gdpr__ button.__youtube_prefs_gdpr__:hover{display:inline-block;padding:5px 10px;background:#e62117!important;color:#fff!important;text-decoration:none!important;border-radius:3px;font-weight:normal;border-width:0;box-sizing:border-box}body div.__youtube_prefs__.__youtube_prefs_gdpr__ button.__youtube_prefs_gdpr__ img{width:20px!important;height:auto!important;vertical-align:middle!important;padding:0 6px 3px 0;display:inline-block;background:transparent;-webkit-box-shadow:none;box-shadow:none;margin-left:8px}body .epyt-gallery-img-gdpr{background-color:#000;background-image:-webkit-linear-gradient(top,#000,#444);background-image:linear-gradient(to bottom,#000,#444)}.epyt-facade{position:relative;padding-bottom:56.25%;height:0;overflow:hidden;max-width:100%;-webkit-transition:.4s all;-moz-transition:.4s all;transition:.4s all}.epyt-facade:hover{-webkit-filter:brightness(90%);-moz-filter:brightness(90%);filter:brightness(90%)}.epyt-facade img.epyt-facade-poster{display:block;margin:0;max-width:100%;width:100%;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);border:0;height:auto;cursor:pointer}.epyt-facade button.epyt-facade-play{background-color:transparent!important;position:absolute;left:50%;top:50%;width:68px;height:48px;margin-left:-34px;margin-top:-24px;-webkit-transition:opacity .25s cubic-bezier(0,0,0.2,1);transition:opacity .25s cubic-bezier(0,0,0.2,1);cursor:pointer;border-width:0!important}.epyt-facade button.epyt-facade-play svg{height:100%;left:0;position:absolute;top:0;width:100%;pointer-events:none}.epyt-facade button.epyt-facade-play svg .ytp-large-play-button-bg{-webkit-transition:fill .1s cubic-bezier(0.4,0,1,1),fill-opacity .1s cubic-bezier(0.4,0,1,1);transition:fill .1s cubic-bezier(0.4,0,1,1),fill-opacity .1s cubic-bezier(0.4,0,1,1);fill:#212121;fill-opacity:.8}.epyt-facade:hover button.epyt-facade-play svg .ytp-large-play-button-bg{-webkit-transition:fill .1s cubic-bezier(0,0,0.2,1),fill-opacity .1s cubic-bezier(0,0,0.2,1);transition:fill .1s cubic-bezier(0,0,0.2,1),fill-opacity .1s cubic-bezier(0,0,0.2,1);fill:#f00;fill-opacity:1}.wp-block-embed.wp-has-aspect-ratio .wp-block-embed__wrapper .epyt-is-override.epyt-facade
|
1 |
|
2 |
+
.epyt-debug{cursor:pointer;text-align:left;background-color:#ddd;color:#000}iframe.__youtube_prefs__{border-width:0}.epyt-gallery{text-align:center}.epyt-gallery iframe{margin-bottom:0}.epyt-gallery.epyt-lb iframe{display:none;height:0!important}.epyt-gallery-list{margin:0 -8px 0 -8px;position:relative;transition:opacity ease-out .3s;display:block}.epyt-gallery-list .epyt-gallery-thumb{box-sizing:border-box}.epyt-gallery-list p{display:none}.epyt-gallery-clear{clear:both}.epyt-gallery-list.epyt-loading{opacity:.5;transition:opacity ease-out .3s}.epyt-gallery-thumb{position:relative;box-sizing:border-box;overflow-y:hidden;display:block!important;cursor:pointer;opacity:1;float:left;padding:0 8px 10px 8px;height:auto}.epyt-gallery-thumb.hover{position:relative;opacity:1;transition:opacity ease-out .3s;height:auto}.epyt-gallery-img-box{width:100%}.epyt-gallery-img{height:0;width:100%;padding-top:56.25%!important;position:relative;overflow:hidden!important;background-size:cover!important;background-position:center!important}.epyt-gallery-playhover{opacity:0;position:absolute;top:-10px;left:0;width:100%;height:100%;vertical-align:middle;text-align:center;transition:opacity ease-out .3s}.epyt-gallery-thumb.hover .epyt-gallery-playhover,.epyt-gallery-thumb.epyt-current-video .epyt-gallery-playhover{opacity:1;top:0;transition:all ease-out .3s}.epyt-gallery-thumb .epyt-gallery-playcrutch{display:inline-block;height:100%;vertical-align:middle;width:0}.epyt-gallery-playhover .epyt-play-img{height:auto!important;max-width:15%!important;padding:0!important;margin:0!important;min-width:30px!important;vertical-align:middle!important;display:inline-block!important;width:auto;border:0;box-sizing:border-box}.epyt-gallery-title{font-size:80%;line-height:120%;padding:10px}.epyt-gallery-notitle{padding:4px}.epyt-gallery-notitle span{display:none}.epyt-gallery-rowtitle{text-align:center;width:100%;position:absolute;left:0;top:100%;opacity:0;z-index:10;overflow-x:hidden;text-overflow:ellipsis;white-space:nowrap}.epyt-gallery-rowtitle.hover{opacity:1;transition:opacity linear .2s}.epyt-gallery-rowbreak{clear:both}.epyt-pagination{clear:both;text-align:center;padding:10px 8px 10px 8px}.epyt-pagination.epyt-hide-pagination *{display:none!important}.epyt-pagination>div,.epyt-pagenumbers>div{display:inline-block;padding:0 2px 0 2px;vertical-align:middle}.epyt-pagination .epyt-pagebutton{cursor:pointer;display:inline-block;padding:0 10px 0 10px}.epyt-pagebutton>div{display:inline}.epyt-pagination .epyt-loader{display:none}.epyt-gallery-list.epyt-loading .epyt-pagination .epyt-loader{display:inline-block}body .lity-container{width:100%;max-width:964px}.epyt-curtain .lity-opened iframe{opacity:0;transition:opacity .3s linear .5s}.epyt-gallery-allthumbs.epyt-cols-1 .epyt-gallery-thumb{width:100%}.epyt-gallery-allthumbs.epyt-cols-2 .epyt-gallery-thumb{width:50%}.epyt-gallery-allthumbs.epyt-cols-3 .epyt-gallery-thumb{width:33.333%}.epyt-gallery-allthumbs.epyt-cols-4 .epyt-gallery-thumb{width:25%}.epyt-gallery-allthumbs.epyt-cols-5 .epyt-gallery-thumb{width:20%}.epyt-gallery-allthumbs.epyt-cols-6 .epyt-gallery-thumb{width:16.666%}.epyt-gallery-allthumbs.epyt-cols-7 .epyt-gallery-thumb{width:14.285%}.epyt-gallery-allthumbs.epyt-cols-8 .epyt-gallery-thumb{width:12.5%}.epyt-gallery-allthumbs.epyt-cols-9 .epyt-gallery-thumb{width:11.111%}.epyt-gallery-allthumbs.epyt-cols-10 .epyt-gallery-thumb{width:10%}.epyt-gallery-allthumbs.epyt-cols-11 .epyt-gallery-thumb{width:9.090%}.epyt-gallery-allthumbs.epyt-cols-12 .epyt-gallery-thumb{width:8.333%}.epyt-gallery-allthumbs.epyt-cols-13 .epyt-gallery-thumb{width:7.692%}.epyt-gallery-allthumbs.epyt-cols-14 .epyt-gallery-thumb{width:7.142%}.epyt-gallery-allthumbs.epyt-cols-15 .epyt-gallery-thumb{width:6.666%}.epyt-gallery-allthumbs.epyt-cols-16 .epyt-gallery-thumb{width:6.25%}.epyt-gallery-allthumbs.epyt-cols-17 .epyt-gallery-thumb{width:5.882%}.epyt-gallery-allthumbs.epyt-cols-18 .epyt-gallery-thumb{width:5.555%}.epyt-gallery-allthumbs.epyt-cols-19 .epyt-gallery-thumb{width:5.263%}.epyt-gallery-allthumbs.epyt-cols-20 .epyt-gallery-thumb{width:5%}.epyt-pagebutton.hide,.epyt-pagenumbers.hide{display:none!important;opacity:0!important;visibility:hidden!important}.epyt-gallery-subscribe{text-align:center;padding:15px 0 10px 0;clear:both}.epyt-gallery-subscribe a.epyt-gallery-subbutton,.epyt-gallery-subscribe a.epyt-gallery-subbutton:hover{display:inline-block;padding:5px 10px;background-color:#e62117!important;color:#fff!important;text-decoration:none!important;border-radius:3px}.epyt-gallery-subscribe a.epyt-gallery-subbutton img{width:20px!important;height:auto!important;vertical-align:middle!important;padding:0 6px 3px 0;display:inline-block;background:transparent;-webkit-box-shadow:none;box-shadow:none;margin:0}body div.__youtube_prefs__.__youtube_prefs_gdpr__{background-color:#000;background-image:-webkit-linear-gradient(top,#000,#444);background-image:linear-gradient(to bottom,#000,#444);padding:25px;height:auto;text-align:left}body div.__youtube_prefs__.__youtube_prefs_gdpr__ *{color:#e3e3e3!important}body div.__youtube_prefs__.__youtube_prefs_gdpr__ a{text-decoration:underline}body div.__youtube_prefs__.__youtube_prefs_gdpr__ button.__youtube_prefs_gdpr__,body div.__youtube_prefs__.__youtube_prefs_gdpr__ button.__youtube_prefs_gdpr__:hover{display:inline-block;padding:5px 10px;background:#e62117!important;color:#fff!important;text-decoration:none!important;border-radius:3px;font-weight:normal;border-width:0;box-sizing:border-box}body div.__youtube_prefs__.__youtube_prefs_gdpr__ button.__youtube_prefs_gdpr__ img{width:20px!important;height:auto!important;vertical-align:middle!important;padding:0 6px 3px 0;display:inline-block;background:transparent;-webkit-box-shadow:none;box-shadow:none;margin-left:8px}body .epyt-gallery-img-gdpr{background-color:#000;background-image:-webkit-linear-gradient(top,#000,#444);background-image:linear-gradient(to bottom,#000,#444)}.epyt-facade{position:relative;padding-bottom:56.25%;height:0;overflow:hidden;max-width:100%;-webkit-transition:.4s all;-moz-transition:.4s all;transition:.4s all}.epyt-facade:hover{-webkit-filter:brightness(90%);-moz-filter:brightness(90%);filter:brightness(90%)}.epyt-facade img.epyt-facade-poster{display:block;margin:0;max-width:100%;width:100%;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);border:0;height:auto;cursor:pointer}.epyt-facade button.epyt-facade-play{background-color:transparent!important;position:absolute;left:50%;top:50%;width:68px;height:48px;margin-left:-34px;margin-top:-24px;-webkit-transition:opacity .25s cubic-bezier(0,0,0.2,1);transition:opacity .25s cubic-bezier(0,0,0.2,1);cursor:pointer;border-width:0!important}.epyt-facade button.epyt-facade-play svg{height:100%;left:0;position:absolute;top:0;width:100%;pointer-events:none}.epyt-facade button.epyt-facade-play svg .ytp-large-play-button-bg{-webkit-transition:fill .1s cubic-bezier(0.4,0,1,1),fill-opacity .1s cubic-bezier(0.4,0,1,1);transition:fill .1s cubic-bezier(0.4,0,1,1),fill-opacity .1s cubic-bezier(0.4,0,1,1);fill:#212121;fill-opacity:.8}.epyt-facade:hover button.epyt-facade-play svg .ytp-large-play-button-bg{-webkit-transition:fill .1s cubic-bezier(0,0,0.2,1),fill-opacity .1s cubic-bezier(0,0,0.2,1);transition:fill .1s cubic-bezier(0,0,0.2,1),fill-opacity .1s cubic-bezier(0,0,0.2,1);fill:#f00;fill-opacity:1}.wp-embed-responsive .wp-block-embed.wp-has-aspect-ratio .wp-block-embed__wrapper .epyt-is-override.epyt-facade{position:absolute;top:0;right:0;bottom:0;left:0}.wp-block-embed.wp-has-aspect-ratio .wp-block-embed__wrapper .epyt-is-override.__youtube_prefs_gdpr__{position:relative}.wp-embed-responsive .wp-block-embed.wp-has-aspect-ratio .wp-block-embed__wrapper .epyt-is-override.__youtube_prefs_gdpr__{position:absolute;top:0;right:0;bottom:0;left:0;overflow-y:auto}.wp-embed-responsive .wp-block-embed.wp-has-aspect-ratio .wp-block-embed__wrapper.epyt-is-override__wrapper:before{padding:0}.wp-embed-responsive .wp-block-embed.wp-has-aspect-ratio .wp-block-embed__wrapper.epyt-is-override__wrapper .epyt-is-override.__youtube_prefs_gdpr__{position:relative;top:unset;right:unset;bottom:unset;left:unset}.ytvi-story-container{display:block;max-width:100%}
|
youtube.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
Plugin Name: Embed Plus for YouTube - Embed a YouTube Gallery, Channel, Playlist, Live Stream, Facade
|
4 |
Plugin URI: https://www.embedplus.com/dashboard/pro-easy-video-analytics.aspx?ref=plugin
|
5 |
Description: YouTube Embed Plugin. Embed a YouTube channel gallery, playlist gallery, YouTube live stream. Lite embeds with defer JavaScript and facade options
|
6 |
-
Version: 14.0
|
7 |
Author: Embed Plus for YouTube Team
|
8 |
Author URI: https://www.embedplus.com
|
9 |
Requires at least: 4.1
|
@@ -35,7 +35,7 @@ class YouTubePrefs
|
|
35 |
|
36 |
public static $folder_name = 'youtube-embed-plus';
|
37 |
public static $curltimeout = 30;
|
38 |
-
public static $version = '14.0';
|
39 |
public static $opt_version = 'version';
|
40 |
public static $optembedwidth = null;
|
41 |
public static $optembedheight = null;
|
@@ -732,6 +732,11 @@ class YouTubePrefs
|
|
732 |
{
|
733 |
throw new Exception();
|
734 |
}
|
|
|
|
|
|
|
|
|
|
|
735 |
if (preg_match(self::$justurlregex, $search))
|
736 |
{
|
737 |
//$search = esc_url($search);
|
@@ -1201,11 +1206,11 @@ class YouTubePrefs
|
|
1201 |
<div class="wiz-accordion">
|
1202 |
<h3 class="header-go"> <a href="<?php echo admin_url('admin.php?page=youtube-my-preferences#jumpdefaults'); ?>">Check my general YouTube embedding instructions and settings. </a></h3>
|
1203 |
<div class="header-go-content"></div>
|
1204 |
-
<h3 id="h3_video"> <a href="#"
|
1205 |
<div>
|
1206 |
<h4 class="center">Single video directions</h4>
|
1207 |
<p>
|
1208 |
-
Paste the url of a single video below (
|
1209 |
</p>
|
1210 |
<form name="wizform_video" method="post" action="" class="wizform" id="wizform_video">
|
1211 |
<?php wp_nonce_field('_epyt_wiz', '_epyt_nonce', true); ?>
|
@@ -1273,7 +1278,7 @@ class YouTubePrefs
|
|
1273 |
{
|
1274 |
?>
|
1275 |
<p>
|
1276 |
-
If you already know the direct link to the channel ID, enter it below. <br>Example: https://www.youtube.com
|
1277 |
</p>
|
1278 |
<p>
|
1279 |
Or, simply enter a link to any single video that belongs to the user's channel, and the plugin will find the channel for you.<br>Example: https://www.youtube.com/watch?v=YVvn8dpSAt0
|
@@ -2820,12 +2825,12 @@ class YouTubePrefs
|
|
2820 |
|
2821 |
$code1 = $begin_gb_wrapper . $begin_responsive;
|
2822 |
$code_iframe1 = $code_iframe2 = '';
|
2823 |
-
if ($videoidoutput != 'live_stream'
|
2824 |
{
|
2825 |
$facade_img_src = '';
|
2826 |
if (!empty($videoidoutput))
|
2827 |
{
|
2828 |
-
$facade_img_src = ' src="https://i.ytimg.com/vi/' . $videoidoutput . '/
|
2829 |
}
|
2830 |
else if (isset($finalparams['list']))
|
2831 |
{
|
@@ -3219,7 +3224,7 @@ class YouTubePrefs
|
|
3219 |
$new_pointer_content = '<h3>' . __('New Update') . '</h3>'; // ooopointer
|
3220 |
|
3221 |
$new_pointer_content .= '<p>'; // ooopointer
|
3222 |
-
$new_pointer_content .= "This update
|
3223 |
if (self::vi_logged_in())
|
3224 |
{
|
3225 |
$new_pointer_content .= "<br><br><strong>Note:</strong> You are currently logged into the vi intelligence feature. vi support is being deprecated in the next version, so we recommend taking the vi ads down from your site. Please contact ext@embedplus.com for questions.";
|
@@ -3256,7 +3261,7 @@ class YouTubePrefs
|
|
3256 |
<a class="nav-tab" href="#jumpapikey">API Key</a>
|
3257 |
<a class="nav-tab" href="#jumpwiz">Wizard</a>
|
3258 |
<a class="nav-tab" href="#jumpgallery">Galleries</a>
|
3259 |
-
<a class="nav-tab href-link" style="background-color: #daebf1;"
|
3260 |
<?php
|
3261 |
if (false)//(!(bool) (self::$alloptions[self::$opt_vi_hide_monetize_tab]) && self::vi_ever_logged_in())
|
3262 |
{
|
@@ -4490,6 +4495,7 @@ class YouTubePrefs
|
|
4490 |
<label for="<?php echo self::$opt_facade_mode ?>">
|
4491 |
<b class="chktitle"><?php _e('Facade Mode:', 'youtube-embed-plus'); ?> <sup class="orange">new</sup></b>
|
4492 |
<?php _e('This improves performance by loading a lighter version of the player, until it is clicked. Then the real player loads (note: for live streams, the real player is always loaded). We have tested this feature in multiple cases and found it to successfully improve your Lighthouse performance score by addressing the following recommendation: "Some third-party resources can be lazy loaded with a facade."', 'youtube-embed-plus'); ?>
|
|
|
4493 |
</label>
|
4494 |
<div class="p box_facade_mode">
|
4495 |
<input name="<?php echo self::$opt_facade_autoplay; ?>" id="<?php echo self::$opt_facade_autoplay; ?>" type="checkbox" class="checkbox" <?php checked($all[self::$opt_facade_autoplay], 1); ?>>
|
@@ -4825,15 +4831,14 @@ class YouTubePrefs
|
|
4825 |
$(document).on('click', '.wrap-ytprefs .nav-tab-wrapper a, .epyt-jumptab', function ()
|
4826 |
{
|
4827 |
$a = $(this);
|
4828 |
-
$('.wrap-ytprefs .nav-tab-wrapper a').removeClass('nav-tab-active');
|
4829 |
-
$a.addClass('nav-tab-active');
|
4830 |
-
$('.wrap-ytprefs section').hide();
|
4831 |
-
$('.wrap-ytprefs section').filter($a.attr('rel') ? $a.attr('rel') : $a.attr('href')).fadeIn(200);
|
4832 |
if (!$a.hasClass('href-link'))
|
4833 |
{
|
|
|
|
|
|
|
|
|
4834 |
return false;
|
4835 |
}
|
4836 |
-
|
4837 |
});
|
4838 |
|
4839 |
if (window.location.hash && window.location.hash == '#jumpmonetize')
|
@@ -5576,6 +5581,7 @@ class YouTubePrefs
|
|
5576 |
<label for="<?php echo self::$opt_facade_mode ?>">
|
5577 |
<b class="chktitle"><?php _e('Facade Mode:', 'youtube-embed-plus'); ?> <sup class="orange">new</sup></b>
|
5578 |
<?php _e('This improves performance by loading a lighter version of the player, until it is clicked. Then the real player loads (note: for live streams, the real player is always loaded). We have tested this feature in multiple cases and found it to successfully improve your Lighthouse performance score by addressing the following recommendation: "Some third-party resources can be lazy loaded with a facade."', 'youtube-embed-plus'); ?>
|
|
|
5579 |
</label>
|
5580 |
<div class="p box_facade_mode">
|
5581 |
<input value="1" name="<?php echo self::$opt_facade_autoplay; ?>" id="<?php echo self::$opt_facade_autoplay; ?>" type="checkbox" class="checkbox" <?php checked($all[self::$opt_facade_autoplay], 1); ?>>
|
3 |
Plugin Name: Embed Plus for YouTube - Embed a YouTube Gallery, Channel, Playlist, Live Stream, Facade
|
4 |
Plugin URI: https://www.embedplus.com/dashboard/pro-easy-video-analytics.aspx?ref=plugin
|
5 |
Description: YouTube Embed Plugin. Embed a YouTube channel gallery, playlist gallery, YouTube live stream. Lite embeds with defer JavaScript and facade options
|
6 |
+
Version: 14.0.1
|
7 |
Author: Embed Plus for YouTube Team
|
8 |
Author URI: https://www.embedplus.com
|
9 |
Requires at least: 4.1
|
35 |
|
36 |
public static $folder_name = 'youtube-embed-plus';
|
37 |
public static $curltimeout = 30;
|
38 |
+
public static $version = '14.0.1';
|
39 |
public static $opt_version = 'version';
|
40 |
public static $optembedwidth = null;
|
41 |
public static $optembedheight = null;
|
732 |
{
|
733 |
throw new Exception();
|
734 |
}
|
735 |
+
else
|
736 |
+
{
|
737 |
+
// cleanup
|
738 |
+
$search = str_replace('/shorts/', '/watch?v=', $search);
|
739 |
+
}
|
740 |
if (preg_match(self::$justurlregex, $search))
|
741 |
{
|
742 |
//$search = esc_url($search);
|
1206 |
<div class="wiz-accordion">
|
1207 |
<h3 class="header-go"> <a href="<?php echo admin_url('admin.php?page=youtube-my-preferences#jumpdefaults'); ?>">Check my general YouTube embedding instructions and settings. </a></h3>
|
1208 |
<div class="header-go-content"></div>
|
1209 |
+
<h3 id="h3_video"> <a href="#"><?php _e('Embed a single video, or YouTube short.', 'text_domain'); ?></a></h3>
|
1210 |
<div>
|
1211 |
<h4 class="center">Single video directions</h4>
|
1212 |
<p>
|
1213 |
+
<?php _e('Paste the url of a single video below (examples: <em>https://www.youtube.com/watch?v=YVvn8dpSAt0</em> or <em>https://www.youtube.com/shorts/J38Yq85ZoyY</em>)', 'text_domain'); ?>
|
1214 |
</p>
|
1215 |
<form name="wizform_video" method="post" action="" class="wizform" id="wizform_video">
|
1216 |
<?php wp_nonce_field('_epyt_wiz', '_epyt_nonce', true); ?>
|
1278 |
{
|
1279 |
?>
|
1280 |
<p>
|
1281 |
+
<?php _e('If you already know the direct link to the channel ID, enter it below. <br>Example: https://www.youtube.com<strong>/channel/</strong>UCnM5iMGiKsZg-iOlIO2ZkdQ <p class="error-channel-format smallnote">Note: the following format will not work: https://www.youtube.com<strong>/c/</strong>customchannelname If you cannot locate the proper channel ID format above, then try the other method below.</p> ', 'text_domain'); ?>
|
1282 |
</p>
|
1283 |
<p>
|
1284 |
Or, simply enter a link to any single video that belongs to the user's channel, and the plugin will find the channel for you.<br>Example: https://www.youtube.com/watch?v=YVvn8dpSAt0
|
2825 |
|
2826 |
$code1 = $begin_gb_wrapper . $begin_responsive;
|
2827 |
$code_iframe1 = $code_iframe2 = '';
|
2828 |
+
if ($videoidoutput != 'live_stream' && $finalparams[self::$opt_facade_mode] == 1)
|
2829 |
{
|
2830 |
$facade_img_src = '';
|
2831 |
if (!empty($videoidoutput))
|
2832 |
{
|
2833 |
+
$facade_img_src = ' src="https://i.ytimg.com/vi/' . $videoidoutput . '/maxresdefault.jpg" ';
|
2834 |
}
|
2835 |
else if (isset($finalparams['list']))
|
2836 |
{
|
3224 |
$new_pointer_content = '<h3>' . __('New Update') . '</h3>'; // ooopointer
|
3225 |
|
3226 |
$new_pointer_content .= '<p>'; // ooopointer
|
3227 |
+
$new_pointer_content .= "This update increases resolution for facade images, fixes a CSS issue with GDPR embeds, and adds YouTube Shorts compatibility for both Free and <a target=_blank href=" . self::$epbase . '/dashboard/pro-easy-video-analytics.aspx?ref=frompointer' . ">Pro versions (discounts throughout the holidays)</a>.";
|
3228 |
if (self::vi_logged_in())
|
3229 |
{
|
3230 |
$new_pointer_content .= "<br><br><strong>Note:</strong> You are currently logged into the vi intelligence feature. vi support is being deprecated in the next version, so we recommend taking the vi ads down from your site. Please contact ext@embedplus.com for questions.";
|
3261 |
<a class="nav-tab" href="#jumpapikey">API Key</a>
|
3262 |
<a class="nav-tab" href="#jumpwiz">Wizard</a>
|
3263 |
<a class="nav-tab" href="#jumpgallery">Galleries</a>
|
3264 |
+
<a class="nav-tab href-link" style="background-color: #daebf1;" target="_blank" href="<?php echo self::$epbase . "/dashboard/pro-easy-video-analytics.aspx?ref=protab" ?>">Upgrade?</a>
|
3265 |
<?php
|
3266 |
if (false)//(!(bool) (self::$alloptions[self::$opt_vi_hide_monetize_tab]) && self::vi_ever_logged_in())
|
3267 |
{
|
4495 |
<label for="<?php echo self::$opt_facade_mode ?>">
|
4496 |
<b class="chktitle"><?php _e('Facade Mode:', 'youtube-embed-plus'); ?> <sup class="orange">new</sup></b>
|
4497 |
<?php _e('This improves performance by loading a lighter version of the player, until it is clicked. Then the real player loads (note: for live streams, the real player is always loaded). We have tested this feature in multiple cases and found it to successfully improve your Lighthouse performance score by addressing the following recommendation: "Some third-party resources can be lazy loaded with a facade."', 'youtube-embed-plus'); ?>
|
4498 |
+
<a href="https://www.youtube.com/watch?v=W7PKUjVBDNE" target="_blank"><?php _e('See an example of this feature at work.', 'youtube-embed-plus'); ?></a>
|
4499 |
</label>
|
4500 |
<div class="p box_facade_mode">
|
4501 |
<input name="<?php echo self::$opt_facade_autoplay; ?>" id="<?php echo self::$opt_facade_autoplay; ?>" type="checkbox" class="checkbox" <?php checked($all[self::$opt_facade_autoplay], 1); ?>>
|
4831 |
$(document).on('click', '.wrap-ytprefs .nav-tab-wrapper a, .epyt-jumptab', function ()
|
4832 |
{
|
4833 |
$a = $(this);
|
|
|
|
|
|
|
|
|
4834 |
if (!$a.hasClass('href-link'))
|
4835 |
{
|
4836 |
+
$('.wrap-ytprefs .nav-tab-wrapper a').removeClass('nav-tab-active');
|
4837 |
+
$a.addClass('nav-tab-active');
|
4838 |
+
$('.wrap-ytprefs section').hide();
|
4839 |
+
$('.wrap-ytprefs section').filter($a.attr('rel') ? $a.attr('rel') : $a.attr('href')).fadeIn(200);
|
4840 |
return false;
|
4841 |
}
|
|
|
4842 |
});
|
4843 |
|
4844 |
if (window.location.hash && window.location.hash == '#jumpmonetize')
|
5581 |
<label for="<?php echo self::$opt_facade_mode ?>">
|
5582 |
<b class="chktitle"><?php _e('Facade Mode:', 'youtube-embed-plus'); ?> <sup class="orange">new</sup></b>
|
5583 |
<?php _e('This improves performance by loading a lighter version of the player, until it is clicked. Then the real player loads (note: for live streams, the real player is always loaded). We have tested this feature in multiple cases and found it to successfully improve your Lighthouse performance score by addressing the following recommendation: "Some third-party resources can be lazy loaded with a facade."', 'youtube-embed-plus'); ?>
|
5584 |
+
<a href="https://www.youtube.com/watch?v=W7PKUjVBDNE" target="_blank"><?php _e('See an example of this feature at work.', 'youtube-embed-plus'); ?></a>
|
5585 |
</label>
|
5586 |
<div class="p box_facade_mode">
|
5587 |
<input value="1" name="<?php echo self::$opt_facade_autoplay; ?>" id="<?php echo self::$opt_facade_autoplay; ?>" type="checkbox" class="checkbox" <?php checked($all[self::$opt_facade_autoplay], 1); ?>>
|