YouTube - Version 14.0

Version Description

Download this release

Release Info

Developer embedplus
Plugin Icon 128x128 YouTube
Version 14.0
Comparing to
See all releases

Code changes from version 13.4.3 to 14.0

readme.txt CHANGED
@@ -1,10 +1,10 @@
1
- === Embed Plus for YouTube - Gallery, Channel, Playlist, Live Stream ===
2
  Contributors: embedplus
3
  Plugin Name: Embed Plus for YouTube - Gallery, Channel, Playlist, Live Stream
4
- Tags: youtube gallery, video gallery, channel gallery, playlist gallery, defer css javascript, youtube channel, youtube live, youtube playlist, embed live chat, lazy load, non critical javascript
5
  Requires at least: 4.1
6
  Tested up to: 5.8
7
- Stable tag: 13.4.3
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
@@ -13,6 +13,7 @@ YouTube Embed Plugin. Embed a responsive video, YouTube channel gallery, playlis
13
 
14
  **A WordPress YouTube embed, YouTube gallery (channel or playlist), and even YouTube livestream or premiere can be customized in a wide variety of ways. It focuses on performance with the ability to defer JavaScript, while serving minified CSS and JavaScript. Here are a few recently added features:**
15
 
 
16
  * 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.
17
  * Compatible with the WordPress Gutenberg block editor (it also stays backwards-compatible with the classic editor). Both the Gutenberg block selector and the Gutenberg classic block will show the YouTube wizard button. For the Gutenberg block selector, click on the (+) sign for the block editor list. The YouTube Wizard block is located under the "Embeds" category (make sure you choose "YouTube **Wizard**"). See more on [how to embed a YouTube video, gallery, or livestream with the WordPress Gutenberg block editor here >>](https://www.embedplus.com/embed-youtube-video-gallery-livestream-wordpress-gutenberg-block-editor.aspx) The plugin is also compatible with several popular page builders like [Elementor](https://www.youtube.com/watch?v=ldNfIGRTxDU), [Beaver Builder](https://www.youtube.com/watch?v=bPgz0jyt7TE), [SiteOrigin](https://www.youtube.com/watch?v=7QNYw_g-7WM), and [Visual Composer](https://www.youtube.com/watch?v=FWBQc9XhAqM). For these and pretty much any other page builder with a short code widget, you can also embed your video, gallery, live stream, or premiere by creating the short code in the plugin's wizard and then embedding the code in the page builder's short code widget or text widget.
18
  * Privacy and Consent - Improved privacy and GDPR compliance options like YouTube no cookie, YouTube API restrictions, and a customizable GDPR consent message
@@ -151,6 +152,10 @@ You can also start and end each individual video at particular times. Like the a
151
 
152
  == Changelog ==
153
 
 
 
 
 
154
  = Embed Plus for YouTube WordPress Plugin 13.4.3 =
155
  * Automatically turn on default dimensions for new installations, to skip oEmbed width/height lookups. Improves performance (recommended for all users, given most YouTube videos are 16:9 ratio)
156
  * Better compatibility with cookie compliance plugins that overtake the player with a placeholder
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, video gallery, channel gallery, playlist gallery, defer css javascript, youtube channel, youtube live, youtube playlist, embed live chat, lazy load, facade
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
13
 
14
  **A WordPress YouTube embed, YouTube gallery (channel or playlist), and even YouTube livestream or premiere can be customized in a wide variety of ways. It focuses on performance with the ability to 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.
18
  * Compatible with the WordPress Gutenberg block editor (it also stays backwards-compatible with the classic editor). Both the Gutenberg block selector and the Gutenberg classic block will show the YouTube wizard button. For the Gutenberg block selector, click on the (+) sign for the block editor list. The YouTube Wizard block is located under the "Embeds" category (make sure you choose "YouTube **Wizard**"). See more on [how to embed a YouTube video, gallery, or livestream with the WordPress Gutenberg block editor here >>](https://www.embedplus.com/embed-youtube-video-gallery-livestream-wordpress-gutenberg-block-editor.aspx) The plugin is also compatible with several popular page builders like [Elementor](https://www.youtube.com/watch?v=ldNfIGRTxDU), [Beaver Builder](https://www.youtube.com/watch?v=bPgz0jyt7TE), [SiteOrigin](https://www.youtube.com/watch?v=7QNYw_g-7WM), and [Visual Composer](https://www.youtube.com/watch?v=FWBQc9XhAqM). For these and pretty much any other page builder with a short code widget, you can also embed your video, gallery, live stream, or premiere by creating the short code in the plugin's wizard and then embedding the code in the page builder's short code widget or text widget.
19
  * Privacy and Consent - Improved privacy and GDPR compliance options like YouTube no cookie, YouTube API restrictions, and a customizable GDPR consent message
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
158
+
159
  = Embed Plus for YouTube WordPress Plugin 13.4.3 =
160
  * Automatically turn on default dimensions for new installations, to skip oEmbed width/height lookups. Improves performance (recommended for all users, given most YouTube videos are 16:9 ratio)
161
  * Better compatibility with cookie compliance plugins that overtake the player with a placeholder
scripts/fitvids.js CHANGED
@@ -84,6 +84,21 @@ var epdofitvids = epdofitvids || function ($)
84
  $this.parent().addClass('fluid-width-video-wrapper').attr('style', 'padding-top: ' + (aspectRatio * 100) + "% !important;");
85
  $this.removeAttr('height').removeAttr('width');
86
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
87
  setTimeout(function ()
88
  {
89
  if (parseInt($this.parent().css('padding-top'), 10) > $this.height() + 20)
@@ -107,6 +122,21 @@ var epdofitvids = epdofitvids || function ($)
107
  $this.wrap(fwvwrap).parent('.fluid-width-video-wrapper').attr('style', 'padding-top: ' + (aspectRatio * 100) + "% !important;");
108
  $this.removeAttr('height').removeAttr('width');
109
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
110
  setTimeout(function ()
111
  {
112
  if (parseInt($this.parent().css('padding-top'), 10) > $this.height() + 20)
84
  $this.parent().addClass('fluid-width-video-wrapper').attr('style', 'padding-top: ' + (aspectRatio * 100) + "% !important;");
85
  $this.removeAttr('height').removeAttr('width');
86
 
87
+ setTimeout(function ()
88
+ {
89
+ var resizeEvent = null;
90
+ if (typeof (Event) === 'function')
91
+ {
92
+ resizeEvent = new Event('resize');
93
+ }
94
+ else
95
+ {
96
+ resizeEvent = document.createEvent('Event');
97
+ resizeEvent.initEvent('resize', true, true);
98
+ }
99
+ window.dispatchEvent(resizeEvent);
100
+ }, 10);
101
+
102
  setTimeout(function ()
103
  {
104
  if (parseInt($this.parent().css('padding-top'), 10) > $this.height() + 20)
122
  $this.wrap(fwvwrap).parent('.fluid-width-video-wrapper').attr('style', 'padding-top: ' + (aspectRatio * 100) + "% !important;");
123
  $this.removeAttr('height').removeAttr('width');
124
 
125
+ setTimeout(function ()
126
+ {
127
+ var resizeEvent = null;
128
+ if (typeof (Event) === 'function')
129
+ {
130
+ resizeEvent = new Event('resize');
131
+ }
132
+ else
133
+ {
134
+ resizeEvent = document.createEvent('Event');
135
+ resizeEvent.initEvent('resize', true, true);
136
+ }
137
+ window.dispatchEvent(resizeEvent);
138
+ }, 10);
139
+
140
  setTimeout(function ()
141
  {
142
  if (parseInt($this.parent().css('padding-top'), 10) > $this.height() + 20)
scripts/fitvids.min.js CHANGED
@@ -1,2 +1,2 @@
1
 
2
- var epdofitvids=epdofitvids||function(a){a.fn.fitVidsEP=function(b){if(_EPYT_.epresponsiveselector.constructor!==Array){_EPYT_.epresponsiveselector=JSON.parse(_EPYT_.epresponsiveselector)}var c={customSelector:null};if(!document.getElementById("fit-vids-style")){var f=document.createElement("div"),d=document.getElementsByTagName("base")[0]||document.getElementsByTagName("script")[0],e="&shy;<style>.fluid-width-video-wrapper{width:100%;position:relative;padding:0;}.fluid-width-video-wrapper iframe,.fluid-width-video-wrapper object,.fluid-width-video-wrapper embed {position:absolute;top:0;left:0;width:100%;height:100%;}</style>";f.className="fit-vids-style";f.id="fit-vids-style";f.style.display="none";f.innerHTML=e;d.parentNode.insertBefore(f,d)}if(b){a.extend(c,b)}return this.each(function(){var g=_EPYT_.epresponsiveselector;if(c.customSelector){g.push(c.customSelector)}var h=a(this).find(g.join(","));h=h.not("object object");h.each(function(){var n=a(this);if(this.tagName.toLowerCase()==="embed"&&n.parent("object").length||n.parent(".fluid-width-video-wrapper").length||n.css("position")==="absolute"){return}if(n.is("[data-origwidth]:not([width])")){n.attr("width",n.data("origwidth"))}if(n.is("[data-origheight]:not([height])")){n.attr("height",n.data("origheight"))}var q=(this.tagName.toLowerCase()==="object"||(n.attr("height")&&!isNaN(parseInt(n.attr("height"),10))))?parseInt(n.attr("height"),10):n.height(),k=!isNaN(parseInt(n.attr("width"),10))?parseInt(n.attr("width"),10):n.width(),p=q/k;if(!n.attr("id")){var i="fitvid"+Math.floor(Math.random()*999999);n.attr("id",i)}var o=n.attr("width");var j=n.attr("height");if(n.parent().hasClass("epyt-video-wrapper")){try{n.parent().addClass("fluid-width-video-wrapper").attr("style","padding-top: "+(p*100)+"% !important;");n.removeAttr("height").removeAttr("width");setTimeout(function(){if(parseInt(n.parent().css("padding-top"),10)>n.height()+20){n.parent().removeClass("fluid-width-video-wrapper").css("padding-top","");n.attr("width",o);n.attr("height",j)}},100)}catch(l){}}else{var m=document.createElement("div");m.className="fluid-width-video-wrapper";try{n.wrap(m).parent(".fluid-width-video-wrapper").attr("style","padding-top: "+(p*100)+"% !important;");n.removeAttr("height").removeAttr("width");setTimeout(function(){if(parseInt(n.parent().css("padding-top"),10)>n.height()+20){n.parent().removeClass("fluid-width-video-wrapper").css("padding-top","");n.attr("width",o);n.attr("height",j)}},100)}catch(l){}}})})};a(document).ready(function(){a("body").fitVidsEP();a(document).ajaxSuccess(function(c,d,b){if(d&&d.responseText&&d.responseText.indexOf("<iframe ")!==-1){a("body").fitVidsEP()}})});return true};try{epdofitvids(window.jQuery)}catch(err){};
1
 
2
+ var epdofitvids=epdofitvids||function(a){a.fn.fitVidsEP=function(b){if(_EPYT_.epresponsiveselector.constructor!==Array){_EPYT_.epresponsiveselector=JSON.parse(_EPYT_.epresponsiveselector)}var c={customSelector:null};if(!document.getElementById("fit-vids-style")){var f=document.createElement("div"),d=document.getElementsByTagName("base")[0]||document.getElementsByTagName("script")[0],e="&shy;<style>.fluid-width-video-wrapper{width:100%;position:relative;padding:0;}.fluid-width-video-wrapper iframe,.fluid-width-video-wrapper object,.fluid-width-video-wrapper embed {position:absolute;top:0;left:0;width:100%;height:100%;}</style>";f.className="fit-vids-style";f.id="fit-vids-style";f.style.display="none";f.innerHTML=e;d.parentNode.insertBefore(f,d)}if(b){a.extend(c,b)}return this.each(function(){var g=_EPYT_.epresponsiveselector;if(c.customSelector){g.push(c.customSelector)}var h=a(this).find(g.join(","));h=h.not("object object");h.each(function(){var n=a(this);if(this.tagName.toLowerCase()==="embed"&&n.parent("object").length||n.parent(".fluid-width-video-wrapper").length||n.css("position")==="absolute"){return}if(n.is("[data-origwidth]:not([width])")){n.attr("width",n.data("origwidth"))}if(n.is("[data-origheight]:not([height])")){n.attr("height",n.data("origheight"))}var q=(this.tagName.toLowerCase()==="object"||(n.attr("height")&&!isNaN(parseInt(n.attr("height"),10))))?parseInt(n.attr("height"),10):n.height(),k=!isNaN(parseInt(n.attr("width"),10))?parseInt(n.attr("width"),10):n.width(),p=q/k;if(!n.attr("id")){var i="fitvid"+Math.floor(Math.random()*999999);n.attr("id",i)}var o=n.attr("width");var j=n.attr("height");if(n.parent().hasClass("epyt-video-wrapper")){try{n.parent().addClass("fluid-width-video-wrapper").attr("style","padding-top: "+(p*100)+"% !important;");n.removeAttr("height").removeAttr("width");setTimeout(function(){var r=null;if(typeof(Event)==="function"){r=new Event("resize")}else{r=document.createEvent("Event");r.initEvent("resize",true,true)}window.dispatchEvent(r)},10);setTimeout(function(){if(parseInt(n.parent().css("padding-top"),10)>n.height()+20){n.parent().removeClass("fluid-width-video-wrapper").css("padding-top","");n.attr("width",o);n.attr("height",j)}},100)}catch(l){}}else{var m=document.createElement("div");m.className="fluid-width-video-wrapper";try{n.wrap(m).parent(".fluid-width-video-wrapper").attr("style","padding-top: "+(p*100)+"% !important;");n.removeAttr("height").removeAttr("width");setTimeout(function(){var r=null;if(typeof(Event)==="function"){r=new Event("resize")}else{r=document.createEvent("Event");r.initEvent("resize",true,true)}window.dispatchEvent(r)},10);setTimeout(function(){if(parseInt(n.parent().css("padding-top"),10)>n.height()+20){n.parent().removeClass("fluid-width-video-wrapper").css("padding-top","");n.attr("width",o);n.attr("height",j)}},100)}catch(l){}}})})};a(document).ready(function(){a("body").fitVidsEP();a(document).ajaxSuccess(function(c,d,b){if(d&&d.responseText&&d.responseText.indexOf("<iframe ")!==-1){a("body").fitVidsEP()}})});return true};try{epdofitvids(window.jQuery)}catch(err){};
scripts/ytprefs.js CHANGED
@@ -208,7 +208,8 @@
208
  events: {
209
  "onReady": window._EPADashboard_.onPlayerReady,
210
  "onStateChange": window._EPADashboard_.onPlayerStateChange
211
- }
 
212
  };
213
  return new window.YT.Player(iframeid, ytOptions);
214
  }
@@ -281,9 +282,17 @@
281
  },
282
  setVidSrc: function ($iframe, vidSrc)
283
  {
284
- $iframe.attr('src', window._EPADashboard_.cleanSrc(vidSrc));
285
- $iframe.get(0).epytsetupdone = false;
286
- window._EPADashboard_.setupevents($iframe.attr('id'));
 
 
 
 
 
 
 
 
287
  },
288
  cleanSrc: function (srcInput)
289
  {
@@ -327,9 +336,9 @@
327
  if (!$container.data('epytevents') || !$('body').hasClass('block-editor-page'))
328
  {
329
  $container.data('epytevents', '1');
330
- var $iframe = $(this).find('iframe, div.__youtube_prefs_gdpr__').first();
331
 
332
- var initSrc = $iframe.data('src') || $iframe.attr('src');
333
  if (!initSrc)
334
  {
335
  initSrc = $iframe.data('ep-src');
@@ -346,7 +355,7 @@
346
  }
347
  $container.on('click touchend', '.epyt-gallery-list .epyt-gallery-thumb', function (e)
348
  {
349
- $iframe = $container.find('iframe, div.__youtube_prefs_gdpr__').first();
350
  if (window._EPYT_.touchmoved)
351
  {
352
  return;
@@ -507,6 +516,50 @@
507
  }
508
  });
509
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
510
  }
511
  };
512
  }
208
  events: {
209
  "onReady": window._EPADashboard_.onPlayerReady,
210
  "onStateChange": window._EPADashboard_.onPlayerStateChange
211
+ },
212
+ host: (thisvid.src || '').indexOf('nocookie') > 0 ? 'https://www.youtube-nocookie.com' : 'https://www.youtube.com'
213
  };
214
  return new window.YT.Player(iframeid, ytOptions);
215
  }
282
  },
283
  setVidSrc: function ($iframe, vidSrc)
284
  {
285
+ if ($iframe.is('.epyt-facade'))
286
+ {
287
+ $iframe.attr('data-facadesrc', window._EPADashboard_.cleanSrc(vidSrc));
288
+ $iframe.trigger('click');
289
+ }
290
+ else
291
+ {
292
+ $iframe.attr('src', window._EPADashboard_.cleanSrc(vidSrc));
293
+ $iframe.get(0).epytsetupdone = false;
294
+ window._EPADashboard_.setupevents($iframe.attr('id'));
295
+ }
296
  },
297
  cleanSrc: function (srcInput)
298
  {
336
  if (!$container.data('epytevents') || !$('body').hasClass('block-editor-page'))
337
  {
338
  $container.data('epytevents', '1');
339
+ var $iframe = $(this).find('iframe, div.__youtube_prefs_gdpr__, div.epyt-facade').first();
340
 
341
+ var initSrc = $iframe.data('src') || $iframe.data('facadesrc') || $iframe.attr('src');
342
  if (!initSrc)
343
  {
344
  initSrc = $iframe.data('ep-src');
355
  }
356
  $container.on('click touchend', '.epyt-gallery-list .epyt-gallery-thumb', function (e)
357
  {
358
+ $iframe = $container.find('iframe, div.__youtube_prefs_gdpr__, div.epyt-facade').first();
359
  if (window._EPYT_.touchmoved)
360
  {
361
  return;
516
  }
517
  });
518
 
519
+ $('.epyt-facade-poster[data-facadeoembed]').each(function ()
520
+ {
521
+ var $facadePoster = $(this);
522
+ var facadeOembedUrl = 'https://www.youtube.com/' + $facadePoster.data('facadeoembed');
523
+ $.get('https://youtube.com/oembed', {url: facadeOembedUrl, format: 'json'},
524
+ function (response)
525
+ {
526
+ $facadePoster.attr('src', response.thumbnail_url);
527
+
528
+ }, 'json')
529
+ .fail(function ()
530
+ {
531
+ })
532
+ .always(function ()
533
+ {
534
+ });
535
+ });
536
+
537
+ $('.epyt-facade').on('click', function (e)
538
+ {
539
+ var $facade = $(this);
540
+ var srcTemp = $facade.attr('data-facadesrc');
541
+ srcTemp = window._EPADashboard_.cleanSrc(srcTemp);
542
+ var iframe = document.createElement('iframe');
543
+ for (var i = 0; i < this.attributes.length; i++)
544
+ {
545
+ var attrib = this.attributes[i];
546
+ if (['allow', 'class', 'height', 'id', 'width'].indexOf(attrib.name.toLowerCase()) >= 0 || attrib.name.toLowerCase().indexOf('data-') == 0)
547
+ {
548
+ $(iframe).attr(attrib.name, attrib.value);
549
+ }
550
+ }
551
+ $(iframe).removeClass('epyt-facade');
552
+ $(iframe).attr('allowfullscreen', '').attr('title', $facade.find('img').attr('alt')).attr('allow', 'accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture');
553
+
554
+ window._EPADashboard_.loadYTAPI();
555
+ $facade.replaceWith(iframe);
556
+ $(iframe).attr('src', srcTemp);
557
+ window._EPADashboard_.setupevents($(iframe).attr('id'));
558
+ setTimeout(function ()
559
+ {
560
+ $($(iframe).parent()).fitVidsEP();
561
+ }, 1);
562
+ });
563
  }
564
  };
565
  }
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}};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){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__").first();var c=e.data("src")||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__").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()}})}}}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("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);
styles/ytprefs-onboarding.css CHANGED
@@ -199,17 +199,24 @@ input.ui-widget[type=text] {
199
  display: block;
200
  }
201
 
202
- .ytprefs-ob-step2 form #responsive ~ #boxresponsive_all {
 
203
  height: 0;
204
  visibility: none;
205
  opacity: 0;
 
206
  transition: opacity 300ms, visibility 300ms;
207
  }
208
 
209
- .ytprefs-ob-step2 form #responsive:checked ~ #boxresponsive_all {
 
210
  height: auto;
211
  visibility: visible;
212
  opacity: 1;
 
 
 
 
213
  }
214
 
215
  .gdpr-options-left {
199
  display: block;
200
  }
201
 
202
+ .ytprefs-ob-step2 form #responsive ~ #boxresponsive_all,
203
+ .ytprefs-ob-step2 form #facade_mode ~ .box_facade_mode {
204
  height: 0;
205
  visibility: none;
206
  opacity: 0;
207
+ pointer-events: none;
208
  transition: opacity 300ms, visibility 300ms;
209
  }
210
 
211
+ .ytprefs-ob-step2 form #responsive:checked ~ #boxresponsive_all,
212
+ .ytprefs-ob-step2 form #facade_mode:checked ~ .box_facade_mode {
213
  height: auto;
214
  visibility: visible;
215
  opacity: 1;
216
+ padding-left: 10px;
217
+ margin-top: 10px;
218
+ pointer-events: all;
219
+ border-left: 5px solid #cccccc;
220
  }
221
 
222
  .gdpr-options-left {
styles/ytprefs-onboarding.min.css CHANGED
@@ -1,2 +1,2 @@
1
 
2
- #wphead{display:none}#wpbody{margin-left:0}#adminmenuback{display:none}#adminmenu,adminmenuwrap{display:none}#wpcontent,.auto-fold #wpcontent{margin-left:0}#wpadminbar{display:none}html.wp-toolbar{padding:0}#footer,#wpfooter,.auto-fold #wpfooter{display:none}#screen-meta-links{display:none}#wpfooter{clear:both}.clearboth{clear:both}.pad20{padding:20px}.center{text-align:center}.bold{font-weight:bold}.orange{color:#f85d00}.smallnote{font-size:small;font-style:italic}.indent-option{margin-left:25px}.ui-widget,.ui-widget input,.ui-widget select,.ui-widget textarea,.ui-widget button{font-family:inherit}.ui-accordion .ui-accordion-header{margin-top:15px;font-weight:bold}.ui-accordion .ui-accordion-content.header-go-content{display:none!important;height:0!important}.ui-widget-content a{color:#0073aa}input.ui-widget[type=text]{margin:0;padding:.4em 1em;width:450px}.txt-button-align input.ui-widget[type=text],.txt-button-align button{vertical-align:top}#epyt_wiz_wrap .ui-button{font-weight:bold}.ui-button .ui-icon{transform:scale(1.35,1.35)}.copycode{background-color:#eef;border:2px solid #c7d6e4;display:inline-block;font-size:.9em;overflow-x:hidden;vertical-align:middle;white-space:nowrap;width:400px;padding-left:15px;padding-right:15px}.pointer{cursor:pointer}.relative{position:relative}.wrap-ytprefs-onboarding h1{line-height:40px}.wrap-ytprefs-onboarding h2{line-height:2em}.wrap-ytprefs-onboarding .box-vi-not-interested{display:none}.ytprefs-ob-step{position:absolute;visibility:hidden;opacity:0;transition:opacity 300ms,visibility 300ms;width:100%;height:0;top:-200000px}.ytprefs-ob-step.active-step{visibility:visible;opacity:1;height:auto;top:0}.ytprefs-ob-title{font-size:2em;line-height:2em;text-align:center}.ytprefs-ob-subtitle{font-size:1.4em;line-height:2em}.ytprefs-ob-content{max-width:800px;margin:0 auto}.ytprefs-ob-nav{text-align:center;margin-top:20px;padding-top:20px;border-top:2px solid #ddd;clear:both;margin-bottom:50px}.ytprefs-ob-nav .ytprefs-ob-nav-hide{display:none}.ytprefs-ob-nav button.button-secondary,.ytprefs-ob-nav button.button-primary{display:inline-block;margin:0 10px}.ytprefs-ob-nav button.ytprefs-ob-nav-prev,.ytprefs-ob-nav button.ytprefs-ob-nav-close{margin-right:25px}.ytprefs-ob-step1 ul.ytprefs-ob-filter li{margin-bottom:15px}.ytprefs-ob-step1 .ytprefs-hover-icons{width:160px;float:right;margin-left:30px;min-height:200px;position:relative}.ytprefs-ob-step1 .ytprefs-hover-icons img{position:absolute;top:0;left:0;opacity:0;display:block;width:100%;height:auto;transition:opacity 200ms}.ytprefs-ob-step1 .ytprefs-hover-icons img.yob-icon-visible{opacity:1}.ytprefs-ob-step2 .ytprefs-ob-setting{display:none;margin:10px 0 25px 0}.ytprefs-ob-step2 .ytprefs-ob-setting.yob-single-visible,.ytprefs-ob-step2 .ytprefs-ob-setting.yob-gallery-visible,.ytprefs-ob-step2 .ytprefs-ob-setting.yob-standalone-visible,.ytprefs-ob-step2 .ytprefs-ob-setting.yob-privacy-visible,.ytprefs-ob-step2 .ytprefs-ob-setting.yob-live-visible{display:block}.ytprefs-ob-step2 form #responsive ~ #boxresponsive_all{height:0;visibility:none;opacity:0;transition:opacity 300ms,visibility 300ms}.ytprefs-ob-step2 form #responsive:checked ~ #boxresponsive_all{height:auto;visibility:visible;opacity:1}.gdpr-options-left{width:65%;float:left}.gdpr-options-right{width:33%;float:right;margin-top:20px}.gdpr-options-right .img-gdpr-message{width:100%;height:auto}iframe#gdpr_consent_message_ifr{min-height:250px!important}.ytprefs-ob-step4 .ytprefs-ob-content{max-width:100%}.wiztab-screenshots{float:right;max-width:50%;height:auto;clear:right;margin-left:30px;margin-bottom:15px;display:block;border:5px solid #ddd}.ytprefs-ob-success{color:#00a000;font-weight:bold}.ytprefs-ob-success:after{content:url('../images/adstxt-valid.png')}input[type="checkbox"]+label .check-note{display:none}input[type="checkbox"]:checked+label .check-note{display:inline}#not_live_on ~ #wp-not_live_content-wrap{opacity:.3}#not_live_on:checked ~ #wp-not_live_content-wrap{opacity:1}
1
 
2
+ #wphead{display:none}#wpbody{margin-left:0}#adminmenuback{display:none}#adminmenu,adminmenuwrap{display:none}#wpcontent,.auto-fold #wpcontent{margin-left:0}#wpadminbar{display:none}html.wp-toolbar{padding:0}#footer,#wpfooter,.auto-fold #wpfooter{display:none}#screen-meta-links{display:none}#wpfooter{clear:both}.clearboth{clear:both}.pad20{padding:20px}.center{text-align:center}.bold{font-weight:bold}.orange{color:#f85d00}.smallnote{font-size:small;font-style:italic}.indent-option{margin-left:25px}.ui-widget,.ui-widget input,.ui-widget select,.ui-widget textarea,.ui-widget button{font-family:inherit}.ui-accordion .ui-accordion-header{margin-top:15px;font-weight:bold}.ui-accordion .ui-accordion-content.header-go-content{display:none!important;height:0!important}.ui-widget-content a{color:#0073aa}input.ui-widget[type=text]{margin:0;padding:.4em 1em;width:450px}.txt-button-align input.ui-widget[type=text],.txt-button-align button{vertical-align:top}#epyt_wiz_wrap .ui-button{font-weight:bold}.ui-button .ui-icon{transform:scale(1.35,1.35)}.copycode{background-color:#eef;border:2px solid #c7d6e4;display:inline-block;font-size:.9em;overflow-x:hidden;vertical-align:middle;white-space:nowrap;width:400px;padding-left:15px;padding-right:15px}.pointer{cursor:pointer}.relative{position:relative}.wrap-ytprefs-onboarding h1{line-height:40px}.wrap-ytprefs-onboarding h2{line-height:2em}.wrap-ytprefs-onboarding .box-vi-not-interested{display:none}.ytprefs-ob-step{position:absolute;visibility:hidden;opacity:0;transition:opacity 300ms,visibility 300ms;width:100%;height:0;top:-200000px}.ytprefs-ob-step.active-step{visibility:visible;opacity:1;height:auto;top:0}.ytprefs-ob-title{font-size:2em;line-height:2em;text-align:center}.ytprefs-ob-subtitle{font-size:1.4em;line-height:2em}.ytprefs-ob-content{max-width:800px;margin:0 auto}.ytprefs-ob-nav{text-align:center;margin-top:20px;padding-top:20px;border-top:2px solid #ddd;clear:both;margin-bottom:50px}.ytprefs-ob-nav .ytprefs-ob-nav-hide{display:none}.ytprefs-ob-nav button.button-secondary,.ytprefs-ob-nav button.button-primary{display:inline-block;margin:0 10px}.ytprefs-ob-nav button.ytprefs-ob-nav-prev,.ytprefs-ob-nav button.ytprefs-ob-nav-close{margin-right:25px}.ytprefs-ob-step1 ul.ytprefs-ob-filter li{margin-bottom:15px}.ytprefs-ob-step1 .ytprefs-hover-icons{width:160px;float:right;margin-left:30px;min-height:200px;position:relative}.ytprefs-ob-step1 .ytprefs-hover-icons img{position:absolute;top:0;left:0;opacity:0;display:block;width:100%;height:auto;transition:opacity 200ms}.ytprefs-ob-step1 .ytprefs-hover-icons img.yob-icon-visible{opacity:1}.ytprefs-ob-step2 .ytprefs-ob-setting{display:none;margin:10px 0 25px 0}.ytprefs-ob-step2 .ytprefs-ob-setting.yob-single-visible,.ytprefs-ob-step2 .ytprefs-ob-setting.yob-gallery-visible,.ytprefs-ob-step2 .ytprefs-ob-setting.yob-standalone-visible,.ytprefs-ob-step2 .ytprefs-ob-setting.yob-privacy-visible,.ytprefs-ob-step2 .ytprefs-ob-setting.yob-live-visible{display:block}.ytprefs-ob-step2 form #responsive ~ #boxresponsive_all,.ytprefs-ob-step2 form #facade_mode ~ .box_facade_mode{height:0;visibility:none;opacity:0;pointer-events:none;transition:opacity 300ms,visibility 300ms}.ytprefs-ob-step2 form #responsive:checked ~ #boxresponsive_all,.ytprefs-ob-step2 form #facade_mode:checked ~ .box_facade_mode{height:auto;visibility:visible;opacity:1;padding-left:10px;margin-top:10px;pointer-events:all;border-left:5px solid #ccc}.gdpr-options-left{width:65%;float:left}.gdpr-options-right{width:33%;float:right;margin-top:20px}.gdpr-options-right .img-gdpr-message{width:100%;height:auto}iframe#gdpr_consent_message_ifr{min-height:250px!important}.ytprefs-ob-step4 .ytprefs-ob-content{max-width:100%}.wiztab-screenshots{float:right;max-width:50%;height:auto;clear:right;margin-left:30px;margin-bottom:15px;display:block;border:5px solid #ddd}.ytprefs-ob-success{color:#00a000;font-weight:bold}.ytprefs-ob-success:after{content:url('../images/adstxt-valid.png')}input[type="checkbox"]+label .check-note{display:none}input[type="checkbox"]:checked+label .check-note{display:inline}#not_live_on ~ #wp-not_live_content-wrap{opacity:.3}#not_live_on:checked ~ #wp-not_live_content-wrap{opacity:1}
styles/ytprefs.css CHANGED
@@ -368,6 +368,86 @@ body .epyt-gallery-img-gdpr {
368
  background-image: linear-gradient(to bottom, #000, #444);
369
  }
370
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
371
 
372
  /********* YTVI */
373
  .ytvi-story-container {
368
  background-image: linear-gradient(to bottom, #000, #444);
369
  }
370
 
371
+ /********* facade */
372
+
373
+ .epyt-facade {
374
+ position: relative;
375
+ padding-bottom: 56.25%;
376
+ height: 0;
377
+ overflow: hidden;
378
+ max-width: 100%;
379
+ -webkit-transition: 0.4s all;
380
+ -moz-transition: 0.4s all;
381
+ transition: 0.4s all;
382
+ }
383
+
384
+ .epyt-facade:hover {
385
+ -webkit-filter: brightness(90%);
386
+ -moz-filter: brightness(90%);
387
+ filter: brightness(90%);
388
+ }
389
+
390
+ .epyt-facade img.epyt-facade-poster {
391
+ display: block;
392
+ margin: 0;
393
+ max-width: 100%;
394
+ width: 100%;
395
+ position: absolute;
396
+ top: 50%;
397
+ left: 50%;
398
+ transform: translate(-50%, -50%);
399
+ border: none;
400
+ height: auto;
401
+ cursor: pointer;
402
+ }
403
+
404
+ .epyt-facade button.epyt-facade-play {
405
+ background-color: transparent !important;
406
+ position: absolute;
407
+ left: 50%;
408
+ top: 50%;
409
+ width: 68px;
410
+ height: 48px;
411
+ margin-left: -34px;
412
+ margin-top: -24px;
413
+ -webkit-transition: opacity .25s cubic-bezier(0,0,0.2,1);
414
+ transition: opacity .25s cubic-bezier(0,0,0.2,1);
415
+ cursor: pointer;
416
+ border-width: 0 !important;
417
+ }
418
+
419
+ .epyt-facade button.epyt-facade-play svg {
420
+ height: 100%;
421
+ left: 0;
422
+ position: absolute;
423
+ top: 0;
424
+ width: 100%;
425
+ pointer-events: none;
426
+ }
427
+
428
+ .epyt-facade button.epyt-facade-play svg .ytp-large-play-button-bg {
429
+ -webkit-transition: fill .1s cubic-bezier(0.4,0,1,1),fill-opacity .1s cubic-bezier(0.4,0,1,1);
430
+ transition: fill .1s cubic-bezier(0.4,0,1,1),fill-opacity .1s cubic-bezier(0.4,0,1,1);
431
+ fill: #212121;
432
+ fill-opacity: .8;
433
+ }
434
+
435
+ .epyt-facade:hover button.epyt-facade-play svg .ytp-large-play-button-bg {
436
+ -webkit-transition: fill .1s cubic-bezier(0,0,0.2,1),fill-opacity .1s cubic-bezier(0,0,0.2,1);
437
+ transition: fill .1s cubic-bezier(0,0,0.2,1),fill-opacity .1s cubic-bezier(0,0,0.2,1);
438
+ fill: #f00;
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 */
453
  .ytvi-story-container {
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)}.ytvi-story-container{display:block;max-width:100%}
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,.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}.ytvi-story-container{display:block;max-width:100%}
youtube.php CHANGED
@@ -1,16 +1,17 @@
1
  <?php
2
  /*
3
- Plugin Name: Embed Plus for YouTube - Gallery, Channel, Playlist, Live Stream
4
  Plugin URI: https://www.embedplus.com/dashboard/pro-easy-video-analytics.aspx?ref=plugin
5
- Description: YouTube Embed and YouTube Gallery WordPress Plugin. Embed a responsive video, YouTube channel, playlist gallery, or live stream
6
- Version: 13.4.3
7
  Author: Embed Plus for YouTube Team
8
  Author URI: https://www.embedplus.com
 
9
  */
10
 
11
  /*
12
  Embed Plus for YouTube - Gallery, Channel, Playlist, Live Stream
13
- Copyright (C) 2020 EmbedPlus.com
14
 
15
  This program is free software: you can redistribute it and/or modify
16
  it under the terms of the GNU General Public License as published by
@@ -34,7 +35,7 @@ class YouTubePrefs
34
 
35
  public static $folder_name = 'youtube-embed-plus';
36
  public static $curltimeout = 30;
37
- public static $version = '13.4.3';
38
  public static $opt_version = 'version';
39
  public static $optembedwidth = null;
40
  public static $optembedheight = null;
@@ -63,6 +64,8 @@ class YouTubePrefs
63
  public static $opt_hl = 'hl';
64
  public static $opt_nocookie = 'nocookie';
65
  public static $opt_gb_compat = 'gb_compat';
 
 
66
  public static $opt_gdpr_consent = 'gdpr_consent';
67
  public static $opt_gdpr_consent_message = 'gdpr_consent_message';
68
  public static $opt_gdpr_consent_button = 'gdpr_consent_button';
@@ -1865,6 +1868,8 @@ class YouTubePrefs
1865
  $_pro = '';
1866
  $_nocookie = 0;
1867
  $_gb_compat = 1;
 
 
1868
  $_gdpr_consent = 0;
1869
  $_gdpr_consent_message = self::$dft_gdpr_consent_message;
1870
  $_gdpr_consent_button = 'Accept YouTube Content';
@@ -1963,6 +1968,8 @@ class YouTubePrefs
1963
  $_pro = self::tryget($arroptions, self::$opt_pro, '');
1964
  $_nocookie = self::tryget($arroptions, self::$opt_nocookie, 0);
1965
  $_gb_compat = self::tryget($arroptions, self::$opt_gb_compat, $_gb_compat);
 
 
1966
  $_gdpr_consent = self::tryget($arroptions, self::$opt_gdpr_consent, $_gdpr_consent);
1967
  $_gdpr_consent_message = self::tryget($arroptions, self::$opt_gdpr_consent_message, $_gdpr_consent_message);
1968
  $_gdpr_consent_button = self::tryget($arroptions, self::$opt_gdpr_consent_button, $_gdpr_consent_button);
@@ -2058,6 +2065,8 @@ class YouTubePrefs
2058
  self::$opt_pro => $_pro,
2059
  self::$opt_nocookie => $_nocookie,
2060
  self::$opt_gb_compat => $_gb_compat,
 
 
2061
  self::$opt_gdpr_consent => $_gdpr_consent,
2062
  self::$opt_gdpr_consent_message => $_gdpr_consent_message,
2063
  self::$opt_gdpr_consent_button => $_gdpr_consent_button,
@@ -2809,12 +2818,40 @@ class YouTubePrefs
2809
  }
2810
  $iframe_id = rand(10000, 99999);
2811
 
2812
- $code1 = $begin_gb_wrapper . $begin_responsive . '<iframe ' . $centercode . ' id="_ytid_' . $iframe_id . '" ' . $dim_attrs .
2813
- ' data-origwidth="' . self::$defaultwidth . '" data-origheight="' . self::$defaultheight . '" ' . $relstop .
2814
- ' src="https://www.' . $youtubebaseurl . '.com/embed/' . $videoidoutput . '?';
2815
- $code2 = '" class="__youtube_prefs__ ' . ($iscontent ? '' : ' __youtube_prefs_widget__ ') . ($isoverride ? ' epyt-is-override ' : '') .
2816
- ' no-lazyload"' . $voloutput . $acctitle . $galleryid_ifm_data . ' allow="autoplay; encrypted-media" allowfullscreen data-no-lazy="1" data-skipgform_ajax_framebjll=""></iframe>' .
2817
- $end_responsive . $end_gb_wrapper;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2818
 
2819
  $origin = '';
2820
 
@@ -2844,7 +2881,7 @@ class YouTubePrefs
2844
  }
2845
  else
2846
  {
2847
- if (!(isset($finalparams['live']) && $key == 'loop'))
2848
  {
2849
  $finalsrc .= htmlspecialchars($key) . '=' . htmlspecialchars($value) . '&';
2850
  if ($key == 'loop' && $value == 1 && !isset($finalparams['list']))
@@ -2860,7 +2897,7 @@ class YouTubePrefs
2860
  if (self::gdpr_mode())
2861
  {
2862
  $code1 = '<div ' . $centercode . ' id="_ytid_' . rand(10000, 99999) . '"'; //'" width="' . self::$defaultwidth . '" height="' . self::$defaultheight . '" ';
2863
- $code2 = ' class="__youtube_prefs__ __youtube_prefs_gdpr__ ' . ($iscontent ? '' : ' __youtube_prefs_widget__') . '" allowfullscreen data-no-lazy="1" data-skipgform_ajax_framebjll="">' .
2864
  apply_filters('ytprefs_filter_the_content_light', wp_kses_post(self::$alloptions[self::$opt_gdpr_consent_message])) .
2865
  '<button type="button" class="__youtube_prefs_gdpr__">' . trim(sanitize_text_field(self::$alloptions[self::$opt_gdpr_consent_button])) .
2866
  '<img src="' . plugins_url('images/icon-check.png', __FILE__) . '" alt="accept" data-no-lazy="1" data-skipgform_ajax_framebjll="" /></button>' .
@@ -3182,7 +3219,7 @@ class YouTubePrefs
3182
  $new_pointer_content = '<h3>' . __('New Update') . '</h3>'; // ooopointer
3183
 
3184
  $new_pointer_content .= '<p>'; // ooopointer
3185
- $new_pointer_content .= "This update provides better gallery compatibility with cookie compliance plugins, and better oEmbed performance for both Free and Pro versions, as well as live stream chat on mobile devices for the <a target=_blank href=" . self::$epbase . '/dashboard/pro-easy-video-analytics.aspx?ref=frompointer' . ">Pro version</a>.";
3186
  if (self::vi_logged_in())
3187
  {
3188
  $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.";
@@ -3372,6 +3409,7 @@ class YouTubePrefs
3372
  #boxnocookie {display: inline-block; border-radius: 3px; padding: 2px 4px 2px 4px; color: red; <?php echo $all[self::$opt_nocookie] ? '' : 'display: none;' ?>}
3373
  #boxapinever {display: none; color: red;}
3374
  input[type="radio"]:checked ~ #boxapinever {display: block;}
 
3375
  #box_gdpr_consent { color: red; <?php echo (bool) $all[self::$opt_gdpr_consent] ? 'display: block;' : 'display: none;' ?>}
3376
  .strike {text-decoration: line-through;}
3377
  .upgchecks { padding: 20px; border: 1px dotted #777777; background-color: #fcfcfc; }
@@ -3465,6 +3503,14 @@ class YouTubePrefs
3465
  #not_live_on:checked ~ #wp-not_live_content-wrap {
3466
  opacity: 1;
3467
  }
 
 
 
 
 
 
 
 
3468
 
3469
  #defer_js ~ .box_defer_jquery {
3470
  opacity: .3;
@@ -3636,7 +3682,7 @@ class YouTubePrefs
3636
  <p>
3637
  <input name="<?php echo self::$opt_pause_others; ?>" id="<?php echo self::$opt_pause_others; ?>" <?php checked($all[self::$opt_pause_others], 1); ?> type="checkbox" class="checkbox">
3638
  <label for="<?php echo self::$opt_pause_others; ?>">
3639
- <b class="chktitle"><?php _e('Simultaneous Playback Control:', 'youtube-embed-plus'); ?></b> <sup class="orange"><?php _e('new', 'youtube-embed-plus'); ?></sup>
3640
  <?php _e('You can enable/disable the ability for visitors to have separate videos running at the same time on the same page. Check this to automatically pause other players while the current player is playing. (Note: this feature is not guaranteed to work with videos embedded from other plugins).', 'youtube-embed-plus'); ?>
3641
  </label>
3642
  </p>
@@ -3836,7 +3882,7 @@ class YouTubePrefs
3836
  $selected_val = trim($all[self::$opt_cc_lang_pref]);
3837
  ?>
3838
  <p>
3839
- <label for="<?php echo self::$opt_cc_lang_pref; ?>"><b class="chktitle">Closed Captions Language:</b></label> <sup class="orange"><?php _e('new', 'youtube-embed-plus-pro'); ?></sup>
3840
  <select name="<?php echo self::$opt_cc_lang_pref; ?>" id="<?php echo self::$opt_cc_lang_pref; ?>" style="width: 260px;">
3841
  <option <?php echo '' == $selected_val ? 'selected' : '' ?> value="">Default/Unspecified</option>
3842
  <?php
@@ -4008,7 +4054,7 @@ class YouTubePrefs
4008
  <label for="<?php echo self::$opt_nocookie; ?>">
4009
  <b class="chktitle">No Cookies:</b> Prevent YouTube from leaving tracking cookies on your visitors browsers unless they actual play the videos. This is coded to apply this behavior on links in your past post as well.
4010
  <div id="boxnocookie">
4011
- Note: Checking this option may break some features such as the ones listed below:
4012
  <ul class="list-ul">
4013
  <li>Galleries</li>
4014
  <li>Hide related videos at the end of playback</li>
@@ -4361,7 +4407,7 @@ class YouTubePrefs
4361
  <section class="pattern" id="jumphowto">
4362
  <h2>Manual Embedding</h2>
4363
  <p>
4364
- <strong>We recommend using the wizard in your editor to embed.</strong> However, if you choose to manually embed code, follow the instructions below.
4365
  </p>
4366
  <h3>
4367
  Manually Embed a YouTube Video or Playlist &nbsp; <a class="smallnote" href="#jumpgallery">(For gallery directions, go here &raquo;)</a>
@@ -4439,6 +4485,22 @@ class YouTubePrefs
4439
  <p>
4440
  <?php _e('On this page, we describe performance options to help optimize page speed times of your pages containing YouTube embeds.', 'youtube-embed-plus'); ?>
4441
  </p>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4442
  <div class="p">
4443
  <input name="<?php echo self::$opt_defer_js; ?>" id="<?php echo self::$opt_defer_js; ?>" <?php checked($all[self::$opt_defer_js], 1); ?> type="checkbox" class="checkbox">
4444
  <label for="<?php echo self::$opt_defer_js ?>">
@@ -4988,6 +5050,8 @@ class YouTubePrefs
4988
  $new_options[self::$opt_color] = self::postchecked(self::$opt_color) ? 'red' : 'white';
4989
  $new_options[self::$opt_nocookie] = self::postchecked(self::$opt_nocookie) ? 1 : 0;
4990
  $new_options[self::$opt_gb_compat] = self::postchecked(self::$opt_gb_compat) ? 1 : 0;
 
 
4991
  $new_options[self::$opt_gdpr_consent] = self::postchecked(self::$opt_gdpr_consent) ? 1 : 0;
4992
  $new_options[self::$opt_playlistorder] = self::postchecked(self::$opt_playlistorder) ? 1 : 0;
4993
  $new_options[self::$opt_acctitle] = self::postchecked(self::$opt_acctitle) ? 1 : 0;
@@ -5292,6 +5356,8 @@ class YouTubePrefs
5292
  {
5293
  $input[self::$opt_ytapi_load] = 'light';
5294
  }
 
 
5295
  $input[self::$opt_gdpr_consent] = intval($input[self::$opt_gdpr_consent]);
5296
  $input[self::$opt_gdpr_consent_message] = wp_kses_post(stripslashes($input[self::$opt_gdpr_consent_message]));
5297
  $input[self::$opt_gdpr_consent_button] = wp_kses_post(stripslashes($input[self::$opt_gdpr_consent_button]));
@@ -5323,6 +5389,8 @@ class YouTubePrefs
5323
  self::$opt_not_live_content => '',
5324
  self::$opt_not_live_on => 0,
5325
  self::$opt_ytapi_load => 'light',
 
 
5326
  self::$opt_gdpr_consent => 0,
5327
  self::$opt_gdpr_consent_message => self::$dft_gdpr_consent_message,
5328
  self::$opt_gdpr_consent_button => 'Accept YouTube Content',
@@ -5503,6 +5571,22 @@ class YouTubePrefs
5503
  <input type="radio" name="<?php echo self::$opt_rel; ?>" id="<?php echo self::$opt_rel; ?>1" value="1" <?php checked($all[self::$opt_rel], 1); ?>>
5504
  <label for="<?php echo self::$opt_rel; ?>1">Show related videos</label> &nbsp;&nbsp;
5505
  </div>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5506
  <div class="ytprefs-ob-setting yob-single yob-gallery yob-standalone yob-live">
5507
  <input value="1" name="<?php echo self::$opt_modestbranding; ?>" id="<?php echo self::$opt_modestbranding; ?>" <?php checked($all[self::$opt_modestbranding], 1); ?> type="checkbox" class="checkbox">
5508
  <label for="<?php echo self::$opt_modestbranding; ?>"><?php _e('<b class="chktitle">Modest Branding:</b> No YouTube logo will be shown on the control bar. Instead, as required by YouTube, the logo will only show as a watermark when the video is paused/stopped.') ?></label>
@@ -5612,7 +5696,7 @@ class YouTubePrefs
5612
  <label for="<?php echo self::$opt_nocookie; ?>">
5613
  <b class="chktitle">No Cookies:</b> Prevent YouTube from leaving tracking cookies on your visitors browsers unless they actual play the videos. This is coded to apply this behavior on links in your past post as well.
5614
  <span id="boxnocookie">
5615
- Checking this option may break some features such as galleries and playlists. Furthermore, videos on mobile devices may have problems if you leave this checked.
5616
  </span>
5617
  </label>
5618
  </div>
@@ -5850,7 +5934,6 @@ class YouTubePrefs
5850
  {
5851
  wp_enqueue_style('__ytprefs_admin__alertify_css', plugins_url('styles/alertify/alertify' . self::$min . '.css', __FILE__), array(), self::$version);
5852
  wp_enqueue_style('__ytprefs_admin__alertify_theme_css', plugins_url('styles/alertify/themes/default' . self::$min . '.css', __FILE__), array(), self::$version);
5853
- wp_enqueue_style('wp-color-picker');
5854
  wp_enqueue_style('__ytprefs_admin__vi_css', plugins_url('styles/ytvi-admin' . self::$min . '.css', __FILE__), array(), self::$version);
5855
  wp_enqueue_script('__ytprefs_admin__alertify_js', plugins_url('scripts/alertify/alertify' . self::$min . '.js', __FILE__), array(), self::$version);
5856
  wp_enqueue_script('__ytprefs_admin__alertify_defaults_js', plugins_url('scripts/alertify/alertify-defaults' . self::$min . '.js', __FILE__), array(), self::$version);
@@ -5860,7 +5943,7 @@ class YouTubePrefs
5860
  }
5861
 
5862
  wp_enqueue_style('embedplusyoutube', plugins_url('scripts/embedplus_mce' . self::$min . '.css', __FILE__), array(), self::$version);
5863
- wp_enqueue_script('__ytprefs_admin__', plugins_url('scripts/ytprefs-admin' . self::$min . '.js', __FILE__), array('jquery', 'jquery-effects-fade', 'wp-color-picker'), self::$version, false);
5864
  $admin_script_vars = array(
5865
  'wpajaxurl' => admin_url('admin-ajax.php'),
5866
  'wizhref' => admin_url('admin.php?page=youtube-ep-wizard') . '&random=' . rand(1, 1000) . '&TB_iframe=true&width=950&height=800',
1
  <?php
2
  /*
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
10
  */
11
 
12
  /*
13
  Embed Plus for YouTube - Gallery, Channel, Playlist, Live Stream
14
+ Copyright (C) 2021 EmbedPlus.com
15
 
16
  This program is free software: you can redistribute it and/or modify
17
  it under the terms of the GNU General Public License as published by
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;
64
  public static $opt_hl = 'hl';
65
  public static $opt_nocookie = 'nocookie';
66
  public static $opt_gb_compat = 'gb_compat';
67
+ public static $opt_facade_mode = 'facade_mode';
68
+ public static $opt_facade_autoplay = 'facade_autoplay';
69
  public static $opt_gdpr_consent = 'gdpr_consent';
70
  public static $opt_gdpr_consent_message = 'gdpr_consent_message';
71
  public static $opt_gdpr_consent_button = 'gdpr_consent_button';
1868
  $_pro = '';
1869
  $_nocookie = 0;
1870
  $_gb_compat = 1;
1871
+ $_facade_mode = 0;
1872
+ $_facade_autoplay = 1;
1873
  $_gdpr_consent = 0;
1874
  $_gdpr_consent_message = self::$dft_gdpr_consent_message;
1875
  $_gdpr_consent_button = 'Accept YouTube Content';
1968
  $_pro = self::tryget($arroptions, self::$opt_pro, '');
1969
  $_nocookie = self::tryget($arroptions, self::$opt_nocookie, 0);
1970
  $_gb_compat = self::tryget($arroptions, self::$opt_gb_compat, $_gb_compat);
1971
+ $_facade_mode = self::tryget($arroptions, self::$opt_facade_mode, $_facade_mode);
1972
+ $_facade_autoplay = self::tryget($arroptions, self::$opt_facade_autoplay, $_facade_autoplay);
1973
  $_gdpr_consent = self::tryget($arroptions, self::$opt_gdpr_consent, $_gdpr_consent);
1974
  $_gdpr_consent_message = self::tryget($arroptions, self::$opt_gdpr_consent_message, $_gdpr_consent_message);
1975
  $_gdpr_consent_button = self::tryget($arroptions, self::$opt_gdpr_consent_button, $_gdpr_consent_button);
2065
  self::$opt_pro => $_pro,
2066
  self::$opt_nocookie => $_nocookie,
2067
  self::$opt_gb_compat => $_gb_compat,
2068
+ self::$opt_facade_mode => $_facade_mode,
2069
+ self::$opt_facade_autoplay => $_facade_autoplay,
2070
  self::$opt_gdpr_consent => $_gdpr_consent,
2071
  self::$opt_gdpr_consent_message => $_gdpr_consent_message,
2072
  self::$opt_gdpr_consent_button => $_gdpr_consent_button,
2818
  }
2819
  $iframe_id = rand(10000, 99999);
2820
 
2821
+ $code1 = $begin_gb_wrapper . $begin_responsive;
2822
+ $code_iframe1 = $code_iframe2 = '';
2823
+ if ($videoidoutput != 'live_stream' && $finalparams[self::$opt_facade_mode] == 1)
2824
+ {
2825
+ $facade_img_src = '';
2826
+ if (!empty($videoidoutput))
2827
+ {
2828
+ $facade_img_src = ' src="https://i.ytimg.com/vi/' . $videoidoutput . '/hqdefault.jpg" ';
2829
+ }
2830
+ else if (isset($finalparams['list']))
2831
+ {
2832
+ $facade_img_src = ' data-facadeoembed="playlist?list=' . $finalparams['list'] .'" ';
2833
+ }
2834
+ $acctitle = str_replace('title="', 'alt="', $acctitle);
2835
+ $facade_autoplay = $finalparams[self::$opt_facade_autoplay] == 1 ? ' data-epautoplay="1" ' : '';
2836
+ $code_iframe1 = '<div ' . $centercode . ' id="_ytid_' . $iframe_id . '" ' . $dim_attrs . ' data-origwidth="' . self::$defaultwidth . '" data-origheight="' . self::$defaultheight . '" ' . $relstop .
2837
+ 'data-facadesrc="https://www.' . $youtubebaseurl . '.com/embed/' . $videoidoutput . '?';
2838
+ $code_iframe2 = '" class="__youtube_prefs__ epyt-facade' . ($iscontent ? '' : ' __youtube_prefs_widget__ ') . ($isoverride ? ' epyt-is-override ' : '') . ' no-lazyload"' .
2839
+ $voloutput . $galleryid_ifm_data . $facade_autoplay . '><img class="epyt-facade-poster" loading="lazy" ' . $acctitle . $facade_img_src . ' />' .
2840
+ '<button class="epyt-facade-play" aria-label="Play"><svg height="100%" version="1.1" viewBox="0 0 68 48" width="100%"><path class="ytp-large-play-button-bg" d="M66.52,7.74c-0.78-2.93-2.49-5.41-5.42-6.19C55.79,.13,34,0,34,0S12.21,.13,6.9,1.55 C3.97,2.33,2.27,4.81,1.48,7.74C0.06,13.05,0,24,0,24s0.06,10.95,1.48,16.26c0.78,2.93,2.49,5.41,5.42,6.19 C12.21,47.87,34,48,34,48s21.79-0.13,27.1-1.55c2.93-0.78,4.64-3.26,5.42-6.19C67.94,34.95,68,24,68,24S67.94,13.05,66.52,7.74z" fill="#f00"></path><path d="M 45,24 27,14 27,34" fill="#fff"></path></svg></button>' .
2841
+ '</div>';
2842
+ }
2843
+ else
2844
+ {
2845
+ $code_iframe1 = '<iframe ' . $centercode . ' id="_ytid_' . $iframe_id . '" ' . $dim_attrs . ' data-origwidth="' . self::$defaultwidth . '" data-origheight="' . self::$defaultheight . '" ' . $relstop .
2846
+ 'src="https://www.' . $youtubebaseurl . '.com/embed/' . $videoidoutput . '?';
2847
+ $code_iframe2 = '" class="__youtube_prefs__ ' . ($iscontent ? '' : ' __youtube_prefs_widget__ ') . ($isoverride ? ' epyt-is-override ' : '') . ' no-lazyload"' .
2848
+ $voloutput . $acctitle . $galleryid_ifm_data . ' allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen data-no-lazy="1" data-skipgform_ajax_framebjll=""></iframe>';
2849
+ }
2850
+
2851
+ $code2 = $end_responsive . $end_gb_wrapper;
2852
+
2853
+ $code1 .= $code_iframe1;
2854
+ $code2 = $code_iframe2 . $code2;
2855
 
2856
  $origin = '';
2857
 
2881
  }
2882
  else
2883
  {
2884
+ if (!((isset($finalparams['live']) || isset($finalparams['live_stream'])) && $key == 'loop')) // don't add loop for channel streaming
2885
  {
2886
  $finalsrc .= htmlspecialchars($key) . '=' . htmlspecialchars($value) . '&';
2887
  if ($key == 'loop' && $value == 1 && !isset($finalparams['list']))
2897
  if (self::gdpr_mode())
2898
  {
2899
  $code1 = '<div ' . $centercode . ' id="_ytid_' . rand(10000, 99999) . '"'; //'" width="' . self::$defaultwidth . '" height="' . self::$defaultheight . '" ';
2900
+ $code2 = ' class="__youtube_prefs__ __youtube_prefs_gdpr__ ' . ($iscontent ? '' : ' __youtube_prefs_widget__') . ($isoverride ? ' epyt-is-override ' : '') . '" allowfullscreen data-no-lazy="1" data-skipgform_ajax_framebjll="">' .
2901
  apply_filters('ytprefs_filter_the_content_light', wp_kses_post(self::$alloptions[self::$opt_gdpr_consent_message])) .
2902
  '<button type="button" class="__youtube_prefs_gdpr__">' . trim(sanitize_text_field(self::$alloptions[self::$opt_gdpr_consent_button])) .
2903
  '<img src="' . plugins_url('images/icon-check.png', __FILE__) . '" alt="accept" data-no-lazy="1" data-skipgform_ajax_framebjll="" /></button>' .
3219
  $new_pointer_content = '<h3>' . __('New Update') . '</h3>'; // ooopointer
3220
 
3221
  $new_pointer_content .= '<p>'; // ooopointer
3222
+ $new_pointer_content .= "This update adds a new facade mode for lighter and faster page loads (see Performance tab) and fixes a CSS issue on both Free and <a target=_blank href=" . self::$epbase . '/dashboard/pro-easy-video-analytics.aspx?ref=frompointer' . ">Pro versions</a>.";
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.";
3409
  #boxnocookie {display: inline-block; border-radius: 3px; padding: 2px 4px 2px 4px; color: red; <?php echo $all[self::$opt_nocookie] ? '' : 'display: none;' ?>}
3410
  #boxapinever {display: none; color: red;}
3411
  input[type="radio"]:checked ~ #boxapinever {display: block;}
3412
+ #box_facade_mode { color: red; <?php echo (bool) $all[self::$opt_facade_mode] ? 'display: block;' : 'display: none;' ?>}
3413
  #box_gdpr_consent { color: red; <?php echo (bool) $all[self::$opt_gdpr_consent] ? 'display: block;' : 'display: none;' ?>}
3414
  .strike {text-decoration: line-through;}
3415
  .upgchecks { padding: 20px; border: 1px dotted #777777; background-color: #fcfcfc; }
3503
  #not_live_on:checked ~ #wp-not_live_content-wrap {
3504
  opacity: 1;
3505
  }
3506
+
3507
+ #facade_mode ~ .box_facade_mode {
3508
+ opacity: .3;
3509
+ }
3510
+
3511
+ #facade_mode:checked ~ .box_facade_mode {
3512
+ opacity: 1;
3513
+ }
3514
 
3515
  #defer_js ~ .box_defer_jquery {
3516
  opacity: .3;
3682
  <p>
3683
  <input name="<?php echo self::$opt_pause_others; ?>" id="<?php echo self::$opt_pause_others; ?>" <?php checked($all[self::$opt_pause_others], 1); ?> type="checkbox" class="checkbox">
3684
  <label for="<?php echo self::$opt_pause_others; ?>">
3685
+ <b class="chktitle"><?php _e('Simultaneous Playback Control:', 'youtube-embed-plus'); ?></b>
3686
  <?php _e('You can enable/disable the ability for visitors to have separate videos running at the same time on the same page. Check this to automatically pause other players while the current player is playing. (Note: this feature is not guaranteed to work with videos embedded from other plugins).', 'youtube-embed-plus'); ?>
3687
  </label>
3688
  </p>
3882
  $selected_val = trim($all[self::$opt_cc_lang_pref]);
3883
  ?>
3884
  <p>
3885
+ <label for="<?php echo self::$opt_cc_lang_pref; ?>"><b class="chktitle">Closed Captions Language:</b></label>
3886
  <select name="<?php echo self::$opt_cc_lang_pref; ?>" id="<?php echo self::$opt_cc_lang_pref; ?>" style="width: 260px;">
3887
  <option <?php echo '' == $selected_val ? 'selected' : '' ?> value="">Default/Unspecified</option>
3888
  <?php
4054
  <label for="<?php echo self::$opt_nocookie; ?>">
4055
  <b class="chktitle">No Cookies:</b> Prevent YouTube from leaving tracking cookies on your visitors browsers unless they actual play the videos. This is coded to apply this behavior on links in your past post as well.
4056
  <div id="boxnocookie">
4057
+ Note: Checking this option may introduce issues to features that depend YouTube's API, such as the ones listed below. We suggest testing them out to make sure you are still pleased with the results:
4058
  <ul class="list-ul">
4059
  <li>Galleries</li>
4060
  <li>Hide related videos at the end of playback</li>
4407
  <section class="pattern" id="jumphowto">
4408
  <h2>Manual Embedding</h2>
4409
  <p>
4410
+ <strong>We strongly recommend using the wizard in your editor to embed.</strong> However, if you choose to manually embed code, follow some legacy instructions below.
4411
  </p>
4412
  <h3>
4413
  Manually Embed a YouTube Video or Playlist &nbsp; <a class="smallnote" href="#jumpgallery">(For gallery directions, go here &raquo;)</a>
4485
  <p>
4486
  <?php _e('On this page, we describe performance options to help optimize page speed times of your pages containing YouTube embeds.', 'youtube-embed-plus'); ?>
4487
  </p>
4488
+ <div class="p">
4489
+ <input name="<?php echo self::$opt_facade_mode; ?>" id="<?php echo self::$opt_facade_mode; ?>" <?php checked($all[self::$opt_facade_mode], 1); ?> type="checkbox" class="checkbox">
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); ?>>
4496
+ <label for="<?php echo self::$opt_facade_autoplay ?>">
4497
+ <b class="chktitle"><?php _e('Autoplay On Facade Click:', 'youtube-embed-plus'); ?></b>
4498
+ <span>
4499
+ <?php _e('After clicking once on the facade (aka light thumbnail), it is replaced with the real player. Check this option to have the real player play immediately, otherwise it will require an additional click. Note that checking this option will use YouTube\'s autoplay feature, which will not contribute toward play counts. If you\'re embedding videos from someone else\'s channel, we recommend checking this. If you\'re embedding videos that are from your channel, then you should self-evaluate the tradeoff involving play counts and additional clicking.', 'youtube-embed-plus'); ?>
4500
+ </span>
4501
+ </label>
4502
+ </div>
4503
+ </div>
4504
  <div class="p">
4505
  <input name="<?php echo self::$opt_defer_js; ?>" id="<?php echo self::$opt_defer_js; ?>" <?php checked($all[self::$opt_defer_js], 1); ?> type="checkbox" class="checkbox">
4506
  <label for="<?php echo self::$opt_defer_js ?>">
5050
  $new_options[self::$opt_color] = self::postchecked(self::$opt_color) ? 'red' : 'white';
5051
  $new_options[self::$opt_nocookie] = self::postchecked(self::$opt_nocookie) ? 1 : 0;
5052
  $new_options[self::$opt_gb_compat] = self::postchecked(self::$opt_gb_compat) ? 1 : 0;
5053
+ $new_options[self::$opt_facade_mode] = self::postchecked(self::$opt_facade_mode) ? 1 : 0;
5054
+ $new_options[self::$opt_facade_autoplay] = self::postchecked(self::$opt_facade_autoplay) ? 1 : 0;
5055
  $new_options[self::$opt_gdpr_consent] = self::postchecked(self::$opt_gdpr_consent) ? 1 : 0;
5056
  $new_options[self::$opt_playlistorder] = self::postchecked(self::$opt_playlistorder) ? 1 : 0;
5057
  $new_options[self::$opt_acctitle] = self::postchecked(self::$opt_acctitle) ? 1 : 0;
5356
  {
5357
  $input[self::$opt_ytapi_load] = 'light';
5358
  }
5359
+ $input[self::$opt_facade_mode] = intval($input[self::$opt_facade_mode]);
5360
+ $input[self::$opt_facade_autoplay] = intval($input[self::$opt_facade_autoplay]);
5361
  $input[self::$opt_gdpr_consent] = intval($input[self::$opt_gdpr_consent]);
5362
  $input[self::$opt_gdpr_consent_message] = wp_kses_post(stripslashes($input[self::$opt_gdpr_consent_message]));
5363
  $input[self::$opt_gdpr_consent_button] = wp_kses_post(stripslashes($input[self::$opt_gdpr_consent_button]));
5389
  self::$opt_not_live_content => '',
5390
  self::$opt_not_live_on => 0,
5391
  self::$opt_ytapi_load => 'light',
5392
+ self::$opt_facade_mode => 0,
5393
+ self::$opt_facade_autoplay => 1,
5394
  self::$opt_gdpr_consent => 0,
5395
  self::$opt_gdpr_consent_message => self::$dft_gdpr_consent_message,
5396
  self::$opt_gdpr_consent_button => 'Accept YouTube Content',
5571
  <input type="radio" name="<?php echo self::$opt_rel; ?>" id="<?php echo self::$opt_rel; ?>1" value="1" <?php checked($all[self::$opt_rel], 1); ?>>
5572
  <label for="<?php echo self::$opt_rel; ?>1">Show related videos</label> &nbsp;&nbsp;
5573
  </div>
5574
+ <div class="ytprefs-ob-setting yob-single yob-gallery yob-standalone">
5575
+ <input value="1" name="<?php echo self::$opt_facade_mode; ?>" id="<?php echo self::$opt_facade_mode; ?>" <?php checked($all[self::$opt_facade_mode], 1); ?> type="checkbox" class="checkbox">
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); ?>>
5582
+ <label for="<?php echo self::$opt_facade_autoplay ?>">
5583
+ <b class="chktitle"><?php _e('Autoplay On Facade Click:', 'youtube-embed-plus'); ?></b>
5584
+ <span>
5585
+ <?php _e('After clicking once on the facade (aka light thumbnail), it is replaced with the real player. Check this option to have the real player play immediately, otherwise it will require an additional click. Note that checking this option will use YouTube\'s autoplay feature, which will not contribute toward play counts. If you\'re embedding videos from someone else\'s channel, we recommend checking this. If you\'re embedding videos that are from your channel, then you should self-evaluate the tradeoff involving play counts and additional clicking.', 'youtube-embed-plus'); ?>
5586
+ </span>
5587
+ </label>
5588
+ </div>
5589
+ </div>
5590
  <div class="ytprefs-ob-setting yob-single yob-gallery yob-standalone yob-live">
5591
  <input value="1" name="<?php echo self::$opt_modestbranding; ?>" id="<?php echo self::$opt_modestbranding; ?>" <?php checked($all[self::$opt_modestbranding], 1); ?> type="checkbox" class="checkbox">
5592
  <label for="<?php echo self::$opt_modestbranding; ?>"><?php _e('<b class="chktitle">Modest Branding:</b> No YouTube logo will be shown on the control bar. Instead, as required by YouTube, the logo will only show as a watermark when the video is paused/stopped.') ?></label>
5696
  <label for="<?php echo self::$opt_nocookie; ?>">
5697
  <b class="chktitle">No Cookies:</b> Prevent YouTube from leaving tracking cookies on your visitors browsers unless they actual play the videos. This is coded to apply this behavior on links in your past post as well.
5698
  <span id="boxnocookie">
5699
+ Checking this option may introduce issues to features that depend YouTube's API, such as galleries and playlists. Furthermore, videos on mobile devices may have problems if you leave this checked. We suggest testing this out to make sure you are pleased with the results.
5700
  </span>
5701
  </label>
5702
  </div>
5934
  {
5935
  wp_enqueue_style('__ytprefs_admin__alertify_css', plugins_url('styles/alertify/alertify' . self::$min . '.css', __FILE__), array(), self::$version);
5936
  wp_enqueue_style('__ytprefs_admin__alertify_theme_css', plugins_url('styles/alertify/themes/default' . self::$min . '.css', __FILE__), array(), self::$version);
 
5937
  wp_enqueue_style('__ytprefs_admin__vi_css', plugins_url('styles/ytvi-admin' . self::$min . '.css', __FILE__), array(), self::$version);
5938
  wp_enqueue_script('__ytprefs_admin__alertify_js', plugins_url('scripts/alertify/alertify' . self::$min . '.js', __FILE__), array(), self::$version);
5939
  wp_enqueue_script('__ytprefs_admin__alertify_defaults_js', plugins_url('scripts/alertify/alertify-defaults' . self::$min . '.js', __FILE__), array(), self::$version);
5943
  }
5944
 
5945
  wp_enqueue_style('embedplusyoutube', plugins_url('scripts/embedplus_mce' . self::$min . '.css', __FILE__), array(), self::$version);
5946
+ wp_enqueue_script('__ytprefs_admin__', plugins_url('scripts/ytprefs-admin' . self::$min . '.js', __FILE__), array('jquery', 'jquery-effects-fade'), self::$version, false);
5947
  $admin_script_vars = array(
5948
  'wpajaxurl' => admin_url('admin-ajax.php'),
5949
  'wizhref' => admin_url('admin.php?page=youtube-ep-wizard') . '&random=' . rand(1, 1000) . '&TB_iframe=true&width=950&height=800',