Easy FancyBox - Version 1.9.2

Version Description

Bugfix release.

=

Download this release

Release Info

Developer RavanH
Plugin Icon 128x128 Easy FancyBox
Version 1.9.2
Comparing to
See all releases

Code changes from version 1.9.1 to 1.9.2

easy-fancybox.php CHANGED
@@ -5,7 +5,7 @@ Plugin URI: http://status301.net/wordpress-plugins/easy-fancybox/
5
  Description: Easily enable the FancyBox jQuery light box on all media file links. Also supports iframe, inline content and well known video hosts.
6
  Text Domain: easy-fancybox
7
  Domain Path: languages
8
- Version: 1.9.1
9
  Author: RavanH
10
  Author URI: http://status301.net/
11
  */
@@ -31,10 +31,10 @@ if ( ! defined( 'ABSPATH' ) ) exit;
31
  * CONSTANTS
32
  **************/
33
 
34
- define( 'EASY_FANCYBOX_VERSION', '1.9.1' );
35
  define( 'FANCYBOX_VERSIONS', array(
36
  'legacy' => '1.3.27',
37
- 'classic' => '1.5.1',
38
  'fancyBox2' => '2.2.0',
39
  //'fancyBox3' => '3.5.7'
40
  ) );
@@ -42,7 +42,7 @@ define( 'MOUSEWHEEL_VERSION', '3.1.13' );
42
  define( 'EASING_VERSION', '1.4.1' );
43
  define( 'METADATA_VERSION', '2.22.1' );
44
  define( 'EASY_FANCYBOX_DIR', dirname( __FILE__ ) );
45
- define( 'EASY_FANCYBOX_BASENAME', plugin_basename(__FILE__) );
46
 
47
  /**************
48
  * CLASSES
@@ -55,3 +55,17 @@ if ( is_admin() ) {
55
  require_once EASY_FANCYBOX_DIR . '/inc/class-easyfancybox-admin.php';
56
  new easyFancyBox_Admin();
57
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5
  Description: Easily enable the FancyBox jQuery light box on all media file links. Also supports iframe, inline content and well known video hosts.
6
  Text Domain: easy-fancybox
7
  Domain Path: languages
8
+ Version: 1.9.2
9
  Author: RavanH
10
  Author URI: http://status301.net/
11
  */
31
  * CONSTANTS
32
  **************/
33
 
34
+ define( 'EASY_FANCYBOX_VERSION', '1.9.2' );
35
  define( 'FANCYBOX_VERSIONS', array(
36
  'legacy' => '1.3.27',
37
+ 'classic' => '1.5.2',
38
  'fancyBox2' => '2.2.0',
39
  //'fancyBox3' => '3.5.7'
40
  ) );
42
  define( 'EASING_VERSION', '1.4.1' );
43
  define( 'METADATA_VERSION', '2.22.1' );
44
  define( 'EASY_FANCYBOX_DIR', dirname( __FILE__ ) );
45
+ define( 'EASY_FANCYBOX_BASENAME', plugin_basename( __FILE__ ) );
46
 
47
  /**************
48
  * CLASSES
55
  require_once EASY_FANCYBOX_DIR . '/inc/class-easyfancybox-admin.php';
56
  new easyFancyBox_Admin();
57
  }
58
+
59
+ /**
60
+ * Upgrade plugin data.
61
+ *
62
+ * @since 1.9.2
63
+ */
64
+
65
+ add_action( 'init', function() {
66
+ $old_version = get_option( 'easy_fancybox_version', 0 );
67
+
68
+ if ( 0 !== version_compare( EASY_FANCYBOX_VERSION, $old_version ) ) {
69
+ include EASY_FANCYBOX_DIR . '/upgrade.php';
70
+ }
71
+ } );
fancybox/1.3.27/jquery.fancybox.css CHANGED
@@ -7,7 +7,7 @@
7
  * Copyright (c) 2008 - 2010 Janis Skarnelis
8
  * That said, it is hardly a one-person project. Many people have submitted bugs, code, and offered their advice freely. Their support is greatly appreciated.
9
  *
10
- * Version: 1.3.26 (2018/10/01)
11
  *
12
  * Dual licensed under the MIT and GPL licenses:
13
  * http://www.opensource.org/licenses/mit-license.php
@@ -94,8 +94,8 @@
94
  padding: 0;
95
  position: relative;
96
  /*overflow: hidden;*/
97
- -webkit-overflow-scrolling:touch;
98
- overflow-y:auto;
99
  z-index: 111102;
100
  border: 0px solid #fff;
101
  background: #fff;
7
  * Copyright (c) 2008 - 2010 Janis Skarnelis
8
  * That said, it is hardly a one-person project. Many people have submitted bugs, code, and offered their advice freely. Their support is greatly appreciated.
9
  *
10
+ * Version: 1.3.27 (2018/10/01)
11
  *
12
  * Dual licensed under the MIT and GPL licenses:
13
  * http://www.opensource.org/licenses/mit-license.php
94
  padding: 0;
95
  position: relative;
96
  /*overflow: hidden;*/
97
+ -webkit-overflow-scrolling: touch;
98
+ overflow-y: auto;
99
  z-index: 111102;
100
  border: 0px solid #fff;
101
  background: #fff;
fancybox/1.5.1/jquery.fancybox.min.css DELETED
@@ -1 +0,0 @@
1
- html.fancybox-active,html.fancybox-active body{touch-action:none;overscroll-behavior:none;-webkit-overflow-scrolling:auto;overflow:hidden;}html.fancybox-active body{margin-right:var(--vertical-scrollbar);margin-bottom:var(--horizontal-scrollbar);}html.fancybox-active body.rtl{margin-right:0;margin-left:var(--vertical-scrollbar);}#fancybox-loading,#fancybox-loading div,#fancybox-overlay,#fancybox-wrap *,#fancybox-wrap *::before,#fancybox-wrap *::after{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;}#fancybox-overlay{position:fixed;top:0;left:0;width:100%;height:100%;background-color:rgba(0,0,0,.7);z-index:111100;display:none;}#fancybox-tmp{padding:0;margin:0;border:0;overflow:auto;display:none;}#fancybox-wrap{position:absolute;top:0;left:0;z-index:111101;display:none;outline:none!important;}#fancybox-outer{position:relative;width:100%;height:100%;box-shadow:0 0 20px #111;-moz-box-shadow:0 0 20px #111;-webkit-box-shadow:0 0 20px #111;}#fancybox-content{position:relative;width:100%;height:100%;-webkit-overflow-scrolling:touch;overflow-y:auto;z-index:111102;border:0 solid #fff;background:#fff;background-clip:padding-box;}#fancybox-content>div{max-width:100%;max-height:100%;}#fancybox-error{color:#444;padding:14px;margin:0;}#fancybox-frame,#fancybox-img{width:100%;height:100%;border:none;}#fancybox-img{position:absolute;padding:0;margin:0;line-height:0;vertical-align:top;max-width:none!important;max-height:none!important}#fancybox-frame{display:block;z-index:0}.fancy-ico{position:absolute;width:48px;height:48px;border-radius:50%;}.fancy-ico span{display:block;position:relative;left:12px;top:12px;width:24px;height:24px;border-radius:50%;background:#000;border:2px solid white;box-shadow:0 0 4px #000;transition:transform .25s ease-in-out;}#fancybox-close:hover span,#fancybox-next:hover span,body.rtl #fancybox-prev:hover span{transform:rotate(360deg);}#fancybox-prev:hover span,body.rtl #fancybox-next:hover span{transform:rotate(-360deg);}#fancybox-close{top:-24px;right:-24px;cursor:pointer;z-index:111105;display:none;}#fancybox-close span::after,#fancybox-close span::before{content:'';position:absolute;top:9px;left:4px;width:12px;height:2px;background-color:#fff;}#fancybox-close span::before{transform:rotate(45deg);}#fancybox-close span::after{transform:rotate(-45deg);}#fancybox-prev,#fancybox-next{top:50%;margin-top:-24px;cursor:pointer;z-index:111102;display:none;}#fancybox-next,body.rtl #fancybox-prev{left:auto;right:-24px;}#fancybox-prev,body.rtl #fancybox-next{left:-24px;right:auto;}#fancybox-prev span::after,#fancybox-next span::after{content:'';position:absolute;top:6px;width:8px;height:8px;border-top:2px solid #fff;border-right:2px solid #fff;}#fancybox-prev span::after,body.rtl #fancybox-next span::after{transform:rotate(-135deg);left:7px;}#fancybox-next span::after,body.rtl #fancybox-prev span::after{transform:rotate(45deg);left:initial;right:7px;}#fancybox-title-wrap{z-index:111104;}.fancybox-title-inside{padding-bottom:10px;text-align:center;color:#333;background-color:#fff;position:relative;}.fancybox-title-outside{padding-top:10px;color:#fff;font-weight:600;}.fancybox-title-over{position:absolute;width:100%;bottom:0;left:0;color:#fff;text-align:left;}body.rtl .fancybox-title-over{text-align:right}.fancybox-title-over #fancybox-title{padding:10px;background:rgba(0,0,0,.6);display:block;}.fancybox-title-float{text-align:center;}.fancybox-title-float #fancybox-title{display:table;margin:-12px auto;height:24px;padding:0 15px;line-height:20px;font-size:16px;color:#fff;background:#000;border:2px solid #fff;border-radius:12px;box-shadow:0 0 4px #000;position:relative;z-index:111104;}#fancybox-loading{position:fixed;top:50%;left:50%;width:40px;height:40px;margin-top:-20px;margin-left:-20px;background-color:rgba(0,0,0,.9);border-radius:5px;cursor:pointer;overflow:hidden;z-index:111104;display:none;}#fancybox-loading div{transform-origin:20px 20px;animation:fancybox-loading 1.2s linear infinite;}#fancybox-loading div::after{content:'';display:block;position:absolute;top:7px;left:19px;width:2px;height:7px;border-radius:20%;background:#fff;}#fancybox-loading div:nth-child(1){transform:rotate(0deg);animation-delay:-1.1s;}#fancybox-loading div:nth-child(2){transform:rotate(30deg);animation-delay:-1s;}#fancybox-loading div:nth-child(3){transform:rotate(60deg);animation-delay:-.9s;}#fancybox-loading div:nth-child(4){transform:rotate(90deg);animation-delay:-.8s;}#fancybox-loading div:nth-child(5){transform:rotate(120deg);animation-delay:-.7s;}#fancybox-loading div:nth-child(6){transform:rotate(150deg);animation-delay:-.6s;}#fancybox-loading div:nth-child(7){transform:rotate(180deg);animation-delay:-.5s;}#fancybox-loading div:nth-child(8){transform:rotate(210deg);animation-delay:-.4s;}#fancybox-loading div:nth-child(9){transform:rotate(240deg);animation-delay:-.3s;}#fancybox-loading div:nth-child(10){transform:rotate(270deg);animation-delay:-.2s;}#fancybox-loading div:nth-child(11){transform:rotate(300deg);animation-delay:-.1s;}#fancybox-loading div:nth-child(12){transform:rotate(330deg);animation-delay:0s;}@keyframes fancybox-loading{0%{opacity:1}100%{opacity:0}}.fancybox-hidden{display:none;}#fancybox-content .fancybox-hidden,#fancybox-tmp .fancybox-hidden{display:revert;}
 
fancybox/1.5.1/jquery.fancybox.min.js DELETED
@@ -1 +0,0 @@
1
- !function(e){var t,n,o,i,a,r,c,d,s,l,f,h,u,p,b,g=0,m={},v=[],y=0,w={},x=[],_=null,C=new Image,k=/\.(jpg|gif|png|bmp|jpeg|webp)(.*)?$/i,I=/[^\.]\.(svg)\s*$/i,N=/[^\.]\.(pdf)\s*$/i,S=0,T="",O=!1,j=!1,A=(window.devicePixelRatio,"ontouchstart"in window||window.DocumentTouch&&document instanceof DocumentTouch||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0);_abort=function(){e.fancybox.hideActivity(),C.onerror=C.onload=null,_&&_.abort(),t.empty()},_error=function(n){if(!1===m.onError(v,g,m))return e.fancybox.hideActivity(),void(O=!1);void 0===n&&(n=m.txt.error.later),m.type="html",m.enableSwipeNav=!1,m.titleShow=!1,m.width="auto",m.height="auto",t.html('<p id="fancybox-error">'+m.txt.error.content+"<br />"+n+"</p>"),_process_inline()},_start=function(){var n,o,i,a,c=v[g];if(_abort(),m=e.extend({},e.fn.fancybox.defaults,void 0===e(c).data("fancybox")?m:e(c).data("fancybox")),e("html").addClass("fancybox-active"),e(document).trigger("fancybox-start",[v,g,m]),!1!==(a=m.onStart(v,g,m)))if("object"==typeof a&&(m=e.extend(m,a)),i=m.title||(c.nodeName?e(c).attr("title"):c.title)||"",c.nodeName&&!m.orig&&(m.orig=e(c).find("img:first").length?e(c).find("img:first"):e(c)),""===i&&m.orig&&(i=m.orig.attr("title")||(m.titleFromAlt?m.orig.attr("alt"):"")),n=m.href||(c.nodeName?e(c).attr("href"):c.href)||null,(/^(?:javascript)/i.test(n)||"#"==n)&&(n=null),m.type?(o=m.type,n||(n=m.content)):m.content?o="html":e(c).hasClass("iframe")?o="iframe":n&&(o=n.match(k)||e(c).hasClass("image")?"image":n.match(I)?"svg":n.match(N)?"pdf":0===n.indexOf("#")?"inline":"ajax"),o)switch(e(c).hasClass("modal")&&(m.modal=!0),"inline"==o&&(c=n.substr(n.indexOf("#")),o=e(c).length>0?"inline":"ajax"),m.type=o,m.href=n,m.title=i,m.autoDimensions&&("html"==m.type||"inline"==m.type||"ajax"==m.type?(m.width="auto",m.height="auto"):m.autoDimensions=!1),m.modal&&(m.overlayShow=!0,m.hideOnOverlayClick=!1,m.hideOnContentClick=!1,m.enableEscapeButton=!1,m.showCloseButton=!1),m.padding=parseInt(m.padding,10),m.margin=parseInt(m.margin,10),t.css("padding",m.padding+m.margin),m.enableEscapeButton&&e(document).on("keydown.fb",(function(t){if(27==t.keyCode)return t.preventDefault(),e.fancybox.cancel(),!1})),o){case"html":t.html(m.content),m.enableSwipeNav=!1,_process_inline();break;case"inline":if(!0===e(c).parent().is("#fancybox-content"))return void(O=!1);m.enableSwipeNav=!1,e(c).clone().attr("id",e(c).attr("id")+"-tmp").insertBefore(e(c)),e(document).on("fancybox-cleanup fancybox-change",(function(){let t=r.children().children();e("#"+t.attr("id")+"-tmp").replaceWith(t)})).on("fancybox-cancel",(function(){let n=t.children();n.length||(n=r.children().children()),e("#"+n.attr("id")+"-tmp").replaceWith(n)})),e(c).appendTo(t),_process_inline();break;case"image":m.keepRatio=!0,O=!1,(C=new Image).onerror=function(){_error(m.txt.error.image)},C.onload=function(){O=!0,e.fancybox.hideActivity(),C.onerror=C.onload=null,m.width=C.width,m.height=C.height,e("<img />").attr({id:"fancybox-img",src:C.src,alt:m.title}).appendTo(t),_show()},C.src=n,e.fancybox.showActivity();break;case"svg":m.scrolling="no",m.keepRatio=!0;var d='<object type="image/svg+xml" width="'+m.width+'" height="'+m.height+'" data="'+n+'"></object>';t.html(d),_process_inline();break;case"pdf":m.scrolling="no",m.enableSwipeNav=!1;d='<object type="application/pdf" width="100%" height="100%" data="'+n+'"><a href="'+n+'" style="display:block;position:absolute;top:48%;width:100%;text-align:center">'+e(c).html()+"</a></object>";t.html(d),_process_inline();break;case"ajax":m.enableKeyboardNav=!1,m.showNavArrows=!1,m.enableSwipeNav=!1,O=!1,e.fancybox.showActivity(),m.ajax.win=m.ajax.success,_=e.ajax(e.extend({},m.ajax,{url:n,data:m.ajax.data||{},error:function(){arguments[0].status>0&&_error(arguments[2])},success:function(o,i,r){if(200==("object"==typeof r?r:_).status){if("function"==typeof m.ajax.win){if(!1===(a=m.ajax.win(n,o,i,r)))return void e.fancybox.hideActivity();"string"!=typeof a&&"object"!=typeof a||(o=a)}o.indexOf("<!DOCTYPE")>-1||o.indexOf("<html")>-1||o.indexOf("<body")>-1?_error(m.txt.error.unexpected):(t.html(o),_process_inline())}}}));break;case"iframe":m.enableSwipeNav=!1,e.fancybox.showActivity(),_show();break}else _error(m.txt.error.type);else O=!1},_process_inline=function(){var n=m.width,o=m.height;e.fancybox.hideActivity(),n=n.toString().indexOf("%")>-1?parseInt((window.innerWidth-2*m.margin)*parseFloat(n)/100,10)+"px":"auto"==n?"auto":n+"px",o=o.toString().indexOf("%")>-1?parseInt((window.innerHeight-2*m.margin)*parseFloat(o)/100,10)+"px":"auto"==o?"auto":o+"px",t.wrapInner('<div style="width:'+n+";height:"+o+';overflow:hidden;position:relative;"></div>'),m.width=t.width(),m.height=t.height(),_show()},_show=function(){if(O=!0,e(r.add(o)).off(),e(window).off("resize.fb"),h=w.type,x=v,y=g,(w=m).overlayShow?(w.overlayColor&&o.css("background-color",w.overlayColor),w.hideOnOverlayClick&&o.css("cursor","pointer"),o.is(":visible")||o.fadeIn("fast")):o.hide(),_process_title(),u=_get_zoom_to(),i.is(":visible"))return e(c.add(s).add(l)).hide(),void("image"===h&&"image"===w.type?(r.prepend(t.contents()),r.children().first().next().fadeOut(w.changeSpeed,(function(){e(this).remove()})),r.css("border-width",w.padding),i.animate(u,{duration:w.changeSpeed,easing:w.easingChange,complete:_finish})):r.fadeTo(w.changeFade,.3,(function(){r.css("border-width",w.padding),i.animate(u,{duration:w.changeSpeed,easing:w.easingChange,complete:function(){r.html(t.contents()).fadeTo(w.changeFade,1,_finish)}})})));i.removeAttr("style"),r.css("border-width",w.padding),r.html(t.contents()),"elastic"==w.transitionIn?(i.css(_get_orig_pos()).show(),u.opacity=1,i.attr("aria-hidden","false").animate(u,{duration:w.speedIn,easing:w.easingIn,complete:_finish})):i.css(u).attr("aria-hidden","false").fadeIn("none"==w.transitionIn?0:w.speedIn,_finish)},_format_title=function(e){return!(!e||!e.length)&&'<div id="fancybox-title">'+e+"</div>"},_process_title=function(){if(T=w.title||"",S=0,d.empty().removeAttr("style").removeClass(),!1!==w.titleShow)if((T=e.isFunction(w.titleFormat)?w.titleFormat(T,x,y,w):_format_title(T))&&""!==T){switch(d.addClass("fancybox-title-"+w.titlePosition).html(T).appendTo("body").show(),w.titlePosition){case"outside":case"inside":S=d.outerHeight(!0),d.appendTo(a);break;case"over":r.is(":visible")?d.appendTo(r):d.appendTo(t);break;default:d.css({paddingLeft:w.padding,paddingRight:w.padding}).appendTo(i)}d.hide()}else d.hide();else d.hide()},_swipe=function(){let t=p-b;p=b=0,Math.abs(t)<w.swipeThreshold||(t<0?e.fancybox.prev():e.fancybox.next())},_set_navigation=function(){1!==x.length&&(w.enableSwipeNav&&(i.css("cursor","move"),i.on("mousedown.fb",(function(e){e.preventDefault(),p=b=void 0!==e.clientX?e.clientX:e.originalEvent.clientX,i.on("mousemove.fb",(function(e){b=void 0!==e.clientX?e.clientX:e.originalEvent.clientX}))})),i.on("mouseup.fb",(function(){i.off("mousemove.fb"),_swipe()})),A&&(i.on("touchstart.fb",(function(e){j=1===e.touches.length,p=b=void 0!==e.touches?e.touches[0].clientX:e.originalEvent.touches[0].clientX,i.on("touchmove.fb",(function(e){1===e.touches.length?b=void 0!==e.touches?e.touches[0].clientX:e.originalEvent.touches[0].clientX:(j=!1,i.off("touchmove.fb"))}))})),i.on("touchend.fb",(function(){i.off("touchmove.fb"),j&&(j=!1,_swipe())})))),e.fn.mousewheel&&i.on("mousewheel.fb",(function(t,n){O?t.preventDefault():"image"!=w.type||0!=e(t.target).outerHeight()&&e(t.target).prop("scrollHeight")!==e(t.target).outerHeight()||(t.preventDefault(),e.fancybox[n>0?"prev":"next"]())})),e(document).off("keydown.fb"),(w.enableEscapeButton||w.enableKeyboardNav)&&e(document).on("keydown.fb",(function(t){if(w.enableEscapeButton&&27==t.keyCode)return t.preventDefault(),e.fancybox.close(),!1;!w.enableKeyboardNav||37!=t.keyCode&&39!=t.keyCode||"INPUT"===t.target.tagName||"TEXTAREA"===t.target.tagName||"SELECT"===t.target.tagName?w.enableKeyboardNav&&9==t.keyCode&&"INPUT"!==t.target.tagName&&"TEXTAREA"!==t.target.tagName&&"SELECT"!==t.target.tagName&&(t.preventDefault(),e.fancybox[t.shiftKey?"prev":"next"]()):(t.preventDefault(),e.fancybox[37==t.keyCode?"prev":"next"]())})),w.showNavArrows&&((w.cyclic||0!==y)&&s.attr("title",w.txt.prev).show(),(w.cyclic||y!=x.length-1)&&l.attr("title",w.txt.next).show()))},_finish=function(){T&&T.length&&d.fadeIn(),w.showCloseButton&&c.attr("title",w.txt.close).show(),_set_navigation(),w.hideOnContentClick&&r.on("click",e.fancybox.close).css("cursor","pointer"),w.hideOnOverlayClick&&o.on("click",e.fancybox.close),w.autoResize&&e(window).on("resize.fb",e.fancybox.resize),"iframe"==w.type&&e('<iframe id="fancybox-frame" name="fancybox-frame'+(new Date).getTime()+'" style="border:0;margin:0;overflow:'+("auto"==w.scrolling?"auto":"yes"==w.scrolling?"scroll":"hidden")+'" src="'+w.href+'"'+(!1===w.allowfullscreen?"":" allowfullscreen")+' allow="autoplay; encrypted-media" tabindex="999"></iframe>').appendTo(r).on("load",(function(){e.fancybox.hideActivity()})),"inline"!=w.type&&"html"!=w.type||e(r).children().css("overflow","auto"==w.scrolling?"auto":"yes"==w.scrolling?"scroll":"hidden"),i.show().focus(),O=!1,e(document).trigger("fancybox-complete",[x,y,w]),w.onComplete(x,y,w),x.length>1&&(_preload_next(),_preload_prev())},_preload_next=function(){var e="number"==typeof arguments[0]?arguments[0]:y+1;if(e>=x.length){if(!w.cyclic)return;e=0}if(e==y)return w.enableKeyboardNav=!1,w.enableSwipeNav=!1,i.off("mousewheel.fb touchstart.fb touchmove.fb touchend.fb mousedown.fb mousemove.fb mouseup.fb"),void l.hide();_preload_image(e)||_preload_next(e+1)},_preload_prev=function(){var e="number"==typeof arguments[0]?arguments[0]:y-1;if(e<0){if(!w.cyclic)return;e=x.length-1}if(e==y)return w.enableKeyboardNav=!1,w.enableSwipeNav=!1,i.off("mousewheel.fb touchstart.fb touchmove.fb touchend.fb mousedown.fb mousemove.fb mouseup.fb"),void s.hide();_preload_image(e)||_preload_prev(e-1)},_preload_image=function(t){var n=x[t];return!(void 0===n||void 0===n.href||n.href===w.href||!n.href.match(k)&&!e(n).hasClass("image"))&&((new Image).src=n.href,!0)},_get_zoom_to=function(){var t=[window.innerWidth-2*w.margin,window.innerHeight-2*w.margin-S,e(document).scrollLeft()+w.margin,e(document).scrollTop()+w.margin],n={},o=w.keepRatio&&w.height?w.width/w.height:1;return w.width.toString().indexOf("%")>-1?n.width=parseInt(t[0]*parseFloat(w.width)/100,10):n.width=w.width+2*w.padding,w.height.toString().indexOf("%")>-1?n.height=parseInt(t[1]*parseFloat(w.height)/100,10):n.height=w.height+2*w.padding,w.autoScale&&n.width>t[0]&&(n.width=t[0]-2*w.padding,n.height=parseInt(n.width/o,10)),w.autoScale&&n.height>t[1]&&(n.height=t[1]-2*w.padding,n.width=parseInt(n.height*o,10)),n.left=parseInt(Math.max(t[2],t[2]+(t[0]-n.width)/2),10),n.top=parseInt(Math.max(t[3],t[3]+(t[1]-n.height)/2),10),n},_get_orig_pos=function(){if(!m.orig)return!1;var t=e(m.orig);if(!t.length)return!1;var n=t.offset();return n.top+=parseInt(t.css("paddingTop"),10)||parseInt(t.css("border-top-width"),10)||0,n.left+=parseInt(t.css("paddingLeft"),10)||parseInt(t.css("border-left-width"),10)||0,{width:t.width()+2*w.padding,height:t.height()+2*w.padding,top:n.top-w.padding,left:n.left-w.padding,opacity:0}},_closed=function(){o.fadeOut("fast"),e(document).trigger("fancybox-closed",[x,y,w]),w.onClosed(x,y,w),_cleanup()},_cleanup=function(){o.hide(),d.empty().hide(),i.hide().attr("aria-hidden","true"),r.empty(),x=v=[],y=g=0,w=m={},e("html").css({"--vertical-scrollbar":"","--horizontal-scrollbar":""}),e("html").removeClass("fancybox-active"),e(document).off("fancybox-cancel fancybox-change fancybox-cleanup fancybox-closed"),O=!1},e.fn.fancybox=function(t){if(!e(this).length)return this;let n=e.extend({},t,e.metadata?e(this).metadata():{});return(!n.minViewportWidth||document.documentElement.clientWidth>=n.minViewportWidth)&&e(this).data("fancybox",n).attr({"aria-controls":"fancybox","aria-haspopup":"dialog"}).off("click.fb").on("click.fb",(function(t){if(t.preventDefault(),O)return!1;O=!0,e(this).blur(),v=[],g=0;var n=e(this).attr("rel")||"";return""==n||""==n.replace(/alternate|external|help|license|nofollow|noreferrer|noopener|\s+/gi,"")?v.push(this):(v=e('a[rel="'+n+'"], area[rel="'+n+'"]'),g=v.index(this)),e("html").css({"--vertical-scrollbar":window.innerWidth-e(window).width()+"px","--horizontal-scrollbar":window.innerHeight-e(window).height()+"px"}),_start(),!1})),this},e.fancybox=function(t){var n;if(!O){if(O=!0,n=void 0!==arguments[1]?arguments[1]:{},v=[],g=parseInt(n.index,10)||0,e.isArray(t)){for(var o=0,i=t.length;o<i;o++)"object"==typeof t[o]?e(t[o]).data("fancybox",e.extend({},n,t[o])):t[o]=e({}).data("fancybox",e.extend({content:t[o]},n));v=jQuery.merge(v,t)}else"object"==typeof t?e(t).data("fancybox",e.extend({},n,t)):t=e({}).data("fancybox",e.extend({content:t},n)),v.push(t);(g>v.length||g<0)&&(g=0),e("html").css({"--vertical-scrollbar":window.innerWidth-e(window).width()+"px","--horizontal-scrollbar":window.innerHeight-e(window).height()+"px"}),_start()}},e.fancybox.showActivity=function(){n.attr("title",m.txt.loading).show()},e.fancybox.hideActivity=function(){n.hide()},e.fancybox.next=function(){var t,n="number"==typeof arguments[0]?arguments[0]:y+1;if(n>=x.length){if(!w.cyclic)return;n=0}t=x[n],n!=y&&void 0!==t&&void 0!==t.href&&t.href===w.href?e.fancybox.next(n+1):e.fancybox.pos(n)},e.fancybox.prev=function(){var t,n="number"==typeof arguments[0]?arguments[0]:y-1;if(n<0){if(!w.cyclic)return;n=x.length-1}t=x[n],n!=y&&void 0!==t&&void 0!==t.href&&t.href===w.href?e.fancybox.prev(n-1):e.fancybox.pos(n)},e.fancybox.pos=function(t){O||(t=parseInt(t),x.length>1&&t!=y&&t>-1&&t<x.length&&(e(document).trigger("fancybox-change"),v=x,g=t,i.off("mousewheel.fb touchstart.fb touchmove.fb touchend.fb mousedown.fb mousemove.fb mouseup.fb").css("cursor","initial"),r.off("click"),_start()))},e.fancybox.cancel=function(){O=!0,_abort(),e(document).trigger("fancybox-cancel",[v,g,m]),m&&!1===m.onCancel(v,g,m)?O=!1:(e(v[g]).focus(),e(c.add(s).add(l)).hide(),e(r.add(o)).off(),e(window).off("resize.fb"),e(i).off("mousewheel.fb touchstart.fb touchmove.fb touchend.fb mousedown.fb mousemove.fb mouseup.fb"),e(document).off("keydown.fb"),/MSIE|Trident/.test(window.navigator.userAgent)&&r.find("iframe#fancybox-frame").attr("src","//about:blank"),i.stop(),_cleanup())},e.fancybox.close=function(){O||i.is(":hidden")||(O=!0,_abort(),e(document).trigger("fancybox-cleanup",[x,y,w]),w&&!1===w.onCleanup(x,y,w)?O=!1:(e(x[y]).focus(),e(c.add(s).add(l)).hide(),e(r.add(o)).off(),e(window).off("resize.fb"),e(i).off("mousewheel.fb touchstart.fb touchmove.fb touchend.fb mousedown.fb mousemove.fb mouseup.fb"),e(document).off("keydown.fb"),/MSIE|Trident/.test(window.navigator.userAgent)&&r.find("iframe#fancybox-frame").attr("src","//about:blank"),"inside"!==w.titlePosition&&d.empty(),i.stop(),"elastic"==w.transitionOut?(d.empty().hide(),i.animate(_get_orig_pos(),{duration:w.speedOut,easing:w.easingOut,complete:_closed})):i.fadeOut("none"==w.transitionOut?0:w.speedOut,_closed)))},e.fancybox.resize=function(){clearTimeout(f),f=setTimeout((function(){var e=[];O=!0,_process_title(),u=_get_zoom_to(),c.is(":visible")&&e.push(c)&&c.hide(),s.is(":visible")&&e.push(s)&&s.hide(),l.is(":visible")&&e.push(l)&&l.hide(),i.animate(u,{duration:w.changeSpeed,easing:w.easingChange,complete:function(){T&&T.length&&d.fadeIn(),e.forEach((function(e){e.show()})),O=!1}})}),500)},e.fancybox.init=function(){e("#fancybox-wrap").length||(e("body").append(t=e('<div id="fancybox-tmp"></div>'),n=e('<div id="fancybox-loading" title="Cancel"><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div></div>'),o=e('<div id="fancybox-overlay"></div>'),i=e('<div id="fancybox-wrap" role="dialog" aria-hidden="true" aria-labelledby="fancybox-title" tabindex="-1"></div>')),i.append(a=e('<div id="fancybox-outer"></div>')),a.append(r=e('<div id="fancybox-content"></div>'),c=e('<a id="fancybox-close" href="javascript:;" title="Close" class="fancy-ico" tabindex="1"><span></span></a>'),l=e('<a id="fancybox-next" href="javascript:;" title="Next" class="fancy-ico" tabindex="2"><span></span></a>'),s=e('<a id="fancybox-prev" href="javascript:;" title="Previous" class="fancy-ico" tabindex="3"><span></span></a>'),d=e('<div id="fancybox-title-wrap"></div>')),c.click(e.fancybox.close),n.click(e.fancybox.cancel),s.click((function(t){t.preventDefault(),e.fancybox.prev()})),l.click((function(t){t.preventDefault(),e.fancybox.next()})))},e.fn.fancybox.defaults={padding:10,margin:40,modal:!1,cyclic:!1,allowfullscreen:!1,scrolling:"auto",width:560,height:340,autoScale:!0,autoDimensions:!0,autoResize:!0,keepRatio:!1,minViewportWidth:0,swipeThreshold:100,ajax:{},svg:{wmode:"opaque"},hideOnOverlayClick:!0,hideOnContentClick:!1,overlayShow:!0,overlayColor:"",titleShow:!0,titlePosition:"float",titleFormat:null,titleFromAlt:!0,transitionIn:"fade",transitionOut:"fade",speedIn:400,speedOut:400,changeSpeed:200,changeFade:200,easingIn:"swing",easingOut:"swing",showCloseButton:!0,showNavArrows:!0,enableEscapeButton:!0,enableKeyboardNav:!0,enableSwipeNav:!0,txt:{error:{content:"The requested content cannot be loaded.",later:"Please try again later.",type:"No content type found.",image:"No image found.",unexpected:"Unexpected response."},loading:"Cancel",close:"Close",next:"Next",prev:"Previous"},onStart:function(){},onCancel:function(){},onComplete:function(){},onCleanup:function(){},onClosed:function(){},onError:function(){}},e(document).ready((function(){e.fancybox.init()}))}(jQuery);
 
fancybox/{1.5.1 → 1.5.2}/jquery.fancybox.css RENAMED
@@ -8,7 +8,7 @@
8
  * That said, it is hardly a one-person project. Many people have submitted bugs, code, and offered their advice freely. Their support is greatly appreciated.
9
  *
10
  * Copyright (c) 2020 - RavanH
11
- * Version: 1.5.0 (2020/11/09)
12
  *
13
  * Dual licensed under the MIT and GPL licenses:
14
  * http://www.opensource.org/licenses/mit-license.php
@@ -108,7 +108,6 @@ html.fancybox-active body.rtl {
108
  }
109
 
110
  #fancybox-img {
111
- position: absolute;
112
  padding: 0;
113
  margin: 0;
114
  line-height: 0;
@@ -259,7 +258,7 @@ body.rtl .fancybox-title-over {
259
  height: 24px;
260
  padding: 0 15px;
261
  line-height: 20px;
262
- font-size: 16px;
263
  color: #fff;
264
  background: #000;
265
  border: 2px solid #fff;
8
  * That said, it is hardly a one-person project. Many people have submitted bugs, code, and offered their advice freely. Their support is greatly appreciated.
9
  *
10
  * Copyright (c) 2020 - RavanH
11
+ * Version: 1.5.2 (2020/11/09)
12
  *
13
  * Dual licensed under the MIT and GPL licenses:
14
  * http://www.opensource.org/licenses/mit-license.php
108
  }
109
 
110
  #fancybox-img {
 
111
  padding: 0;
112
  margin: 0;
113
  line-height: 0;
258
  height: 24px;
259
  padding: 0 15px;
260
  line-height: 20px;
261
+ font-size: 14px;
262
  color: #fff;
263
  background: #000;
264
  border: 2px solid #fff;
fancybox/{1.5.1 → 1.5.2}/jquery.fancybox.js RENAMED
@@ -8,7 +8,7 @@
8
  * That said, it is hardly a one-person project. Many people have submitted bugs, code, and offered their advice freely. Their support is greatly appreciated.
9
  *
10
  * Copyright (c) 2020 - RavanH
11
- * Version: 1.5.1 (2020/11/09)
12
  * Requires: jQuery v1.7+
13
  *
14
  * Dual licensed under the MIT and GPL licenses:
@@ -358,11 +358,11 @@
358
  currentOpts = selectedOpts;
359
 
360
  if (currentOpts.overlayShow) {
361
- if (currentOpts.overlayColor)
362
- overlay.css('background-color',currentOpts.overlayColor);
363
-
364
- if (currentOpts.hideOnOverlayClick)
365
- overlay.css('cursor','pointer');
366
 
367
  if (!overlay.is(':visible')) {
368
  overlay.fadeIn('fast');
@@ -387,13 +387,13 @@
387
  .first()
388
  .next().fadeOut(currentOpts.changeSpeed, function(){ $( this ).remove(); } );
389
 
390
- content.css('border-width', currentOpts.padding);
391
 
392
- wrap.animate(final_pos, {
393
- duration : currentOpts.changeSpeed,
394
- easing : currentOpts.easingChange,
395
- complete : _finish
396
- });
397
  } else {
398
  content.fadeTo(currentOpts.changeFade, 0.3, function() {
399
 
@@ -1141,7 +1141,8 @@
1141
  hideOnContentClick : false,
1142
 
1143
  overlayShow : true,
1144
- overlayColor : '',
 
1145
 
1146
  titleShow : true,
1147
  titlePosition : 'float', // 'float', 'outside', 'inside' or 'over'
8
  * That said, it is hardly a one-person project. Many people have submitted bugs, code, and offered their advice freely. Their support is greatly appreciated.
9
  *
10
  * Copyright (c) 2020 - RavanH
11
+ * Version: 1.5.2 (2020/11/09)
12
  * Requires: jQuery v1.7+
13
  *
14
  * Dual licensed under the MIT and GPL licenses:
358
  currentOpts = selectedOpts;
359
 
360
  if (currentOpts.overlayShow) {
361
+ overlay.css({
362
+ 'background-color' : currentOpts.overlayColor,
363
+ 'opacity' : currentOpts.overlayOpacity,
364
+ 'cursor' : currentOpts.hideOnOverlayClick ? 'pointer' : 'auto'
365
+ });
366
 
367
  if (!overlay.is(':visible')) {
368
  overlay.fadeIn('fast');
387
  .first()
388
  .next().fadeOut(currentOpts.changeSpeed, function(){ $( this ).remove(); } );
389
 
390
+ content.css('border-width', currentOpts.padding);
391
 
392
+ wrap.animate(final_pos, {
393
+ duration : currentOpts.changeSpeed,
394
+ easing : currentOpts.easingChange,
395
+ complete : _finish
396
+ });
397
  } else {
398
  content.fadeTo(currentOpts.changeFade, 0.3, function() {
399
 
1141
  hideOnContentClick : false,
1142
 
1143
  overlayShow : true,
1144
+ overlayColor : '#000',
1145
+ overlayOpacity : 0.6,
1146
 
1147
  titleShow : true,
1148
  titlePosition : 'float', // 'float', 'outside', 'inside' or 'over'
fancybox/1.5.2/jquery.fancybox.min.css ADDED
@@ -0,0 +1 @@
 
1
+ html.fancybox-active,html.fancybox-active body{touch-action:none;overscroll-behavior:none;-webkit-overflow-scrolling:auto;overflow:hidden;}html.fancybox-active body{margin-right:var(--vertical-scrollbar);margin-bottom:var(--horizontal-scrollbar);}html.fancybox-active body.rtl{margin-right:0;margin-left:var(--vertical-scrollbar);}#fancybox-loading,#fancybox-loading div,#fancybox-overlay,#fancybox-wrap *,#fancybox-wrap *::before,#fancybox-wrap *::after{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;}#fancybox-overlay{position:fixed;top:0;left:0;width:100%;height:100%;background-color:rgba(0,0,0,.7);z-index:111100;display:none;}#fancybox-tmp{padding:0;margin:0;border:0;overflow:auto;display:none;}#fancybox-wrap{position:absolute;top:0;left:0;z-index:111101;display:none;outline:none!important;}#fancybox-outer{position:relative;width:100%;height:100%;box-shadow:0 0 20px #111;-moz-box-shadow:0 0 20px #111;-webkit-box-shadow:0 0 20px #111;}#fancybox-content{position:relative;width:100%;height:100%;-webkit-overflow-scrolling:touch;overflow-y:auto;z-index:111102;border:0 solid #fff;background:#fff;background-clip:padding-box;}#fancybox-content>div{max-width:100%;max-height:100%;}#fancybox-error{color:#444;padding:14px;margin:0;}#fancybox-frame,#fancybox-img{width:100%;height:100%;border:none;}#fancybox-img{padding:0;margin:0;line-height:0;vertical-align:top;max-width:none!important;max-height:none!important}#fancybox-frame{display:block;z-index:0}.fancy-ico{position:absolute;width:48px;height:48px;border-radius:50%;}.fancy-ico span{display:block;position:relative;left:12px;top:12px;width:24px;height:24px;border-radius:50%;background:#000;border:2px solid white;box-shadow:0 0 4px #000;transition:transform .25s ease-in-out;}#fancybox-close:hover span,#fancybox-next:hover span,body.rtl #fancybox-prev:hover span{transform:rotate(360deg);}#fancybox-prev:hover span,body.rtl #fancybox-next:hover span{transform:rotate(-360deg);}#fancybox-close{top:-24px;right:-24px;cursor:pointer;z-index:111105;display:none;}#fancybox-close span::after,#fancybox-close span::before{content:'';position:absolute;top:9px;left:4px;width:12px;height:2px;background-color:#fff;}#fancybox-close span::before{transform:rotate(45deg);}#fancybox-close span::after{transform:rotate(-45deg);}#fancybox-prev,#fancybox-next{top:50%;margin-top:-24px;cursor:pointer;z-index:111102;display:none;}#fancybox-next,body.rtl #fancybox-prev{left:auto;right:-24px;}#fancybox-prev,body.rtl #fancybox-next{left:-24px;right:auto;}#fancybox-prev span::after,#fancybox-next span::after{content:'';position:absolute;top:6px;width:8px;height:8px;border-top:2px solid #fff;border-right:2px solid #fff;}#fancybox-prev span::after,body.rtl #fancybox-next span::after{transform:rotate(-135deg);left:7px;}#fancybox-next span::after,body.rtl #fancybox-prev span::after{transform:rotate(45deg);left:initial;right:7px;}#fancybox-title-wrap{z-index:111104;}.fancybox-title-inside{padding-bottom:10px;text-align:center;color:#333;background-color:#fff;position:relative;}.fancybox-title-outside{padding-top:10px;color:#fff;font-weight:600;}.fancybox-title-over{position:absolute;width:100%;bottom:0;left:0;color:#fff;text-align:left;}body.rtl .fancybox-title-over{text-align:right}.fancybox-title-over #fancybox-title{padding:10px;background:rgba(0,0,0,.6);display:block;}.fancybox-title-float{text-align:center;}.fancybox-title-float #fancybox-title{display:table;margin:-12px auto;height:24px;padding:0 15px;line-height:20px;font-size:16px;color:#fff;background:#000;border:2px solid #fff;border-radius:12px;box-shadow:0 0 4px #000;position:relative;z-index:111104;}#fancybox-loading{position:fixed;top:50%;left:50%;width:40px;height:40px;margin-top:-20px;margin-left:-20px;background-color:rgba(0,0,0,.9);border-radius:5px;cursor:pointer;overflow:hidden;z-index:111104;display:none;}#fancybox-loading div{transform-origin:20px 20px;animation:fancybox-loading 1.2s linear infinite;}#fancybox-loading div::after{content:'';display:block;position:absolute;top:7px;left:19px;width:2px;height:7px;border-radius:20%;background:#fff;}#fancybox-loading div:nth-child(1){transform:rotate(0deg);animation-delay:-1.1s;}#fancybox-loading div:nth-child(2){transform:rotate(30deg);animation-delay:-1s;}#fancybox-loading div:nth-child(3){transform:rotate(60deg);animation-delay:-.9s;}#fancybox-loading div:nth-child(4){transform:rotate(90deg);animation-delay:-.8s;}#fancybox-loading div:nth-child(5){transform:rotate(120deg);animation-delay:-.7s;}#fancybox-loading div:nth-child(6){transform:rotate(150deg);animation-delay:-.6s;}#fancybox-loading div:nth-child(7){transform:rotate(180deg);animation-delay:-.5s;}#fancybox-loading div:nth-child(8){transform:rotate(210deg);animation-delay:-.4s;}#fancybox-loading div:nth-child(9){transform:rotate(240deg);animation-delay:-.3s;}#fancybox-loading div:nth-child(10){transform:rotate(270deg);animation-delay:-.2s;}#fancybox-loading div:nth-child(11){transform:rotate(300deg);animation-delay:-.1s;}#fancybox-loading div:nth-child(12){transform:rotate(330deg);animation-delay:0s;}@keyframes fancybox-loading{0%{opacity:1}100%{opacity:0}}.fancybox-hidden{display:none;}#fancybox-content .fancybox-hidden,#fancybox-tmp .fancybox-hidden{display:revert;}
fancybox/1.5.2/jquery.fancybox.min.js ADDED
@@ -0,0 +1 @@
 
1
+ !function(e){var t,n,i,o,a,r,c,d,s,l,f,h,u,p,b,g=0,m={},v=[],y=0,w={},x=[],_=null,C=new Image,k=/\.(jpg|gif|png|bmp|jpeg|webp)(.*)?$/i,I=/[^\.]\.(svg)\s*$/i,N=/[^\.]\.(pdf)\s*$/i,O=0,S="",T=!1,j=!1,A=(window.devicePixelRatio,"ontouchstart"in window||window.DocumentTouch&&document instanceof DocumentTouch||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0);_abort=function(){e.fancybox.hideActivity(),C.onerror=C.onload=null,_&&_.abort(),t.empty()},_error=function(n){if(!1===m.onError(v,g,m))return e.fancybox.hideActivity(),void(T=!1);void 0===n&&(n=m.txt.error.later),m.type="html",m.enableSwipeNav=!1,m.titleShow=!1,m.width="auto",m.height="auto",t.html('<p id="fancybox-error">'+m.txt.error.content+"<br />"+n+"</p>"),_process_inline()},_start=function(){var n,i,o,a,c=v[g];if(_abort(),m=e.extend({},e.fn.fancybox.defaults,void 0===e(c).data("fancybox")?m:e(c).data("fancybox")),e("html").addClass("fancybox-active"),e(document).trigger("fancybox-start",[v,g,m]),!1!==(a=m.onStart(v,g,m)))if("object"==typeof a&&(m=e.extend(m,a)),o=m.title||(c.nodeName?e(c).attr("title"):c.title)||"",c.nodeName&&!m.orig&&(m.orig=e(c).find("img:first").length?e(c).find("img:first"):e(c)),""===o&&m.orig&&(o=m.orig.attr("title")||(m.titleFromAlt?m.orig.attr("alt"):"")),n=m.href||(c.nodeName?e(c).attr("href"):c.href)||null,(/^(?:javascript)/i.test(n)||"#"==n)&&(n=null),m.type?(i=m.type,n||(n=m.content)):m.content?i="html":e(c).hasClass("iframe")?i="iframe":n&&(i=n.match(k)||e(c).hasClass("image")?"image":n.match(I)?"svg":n.match(N)?"pdf":0===n.indexOf("#")?"inline":"ajax"),i)switch(e(c).hasClass("modal")&&(m.modal=!0),"inline"==i&&(c=n.substr(n.indexOf("#")),i=e(c).length>0?"inline":"ajax"),m.type=i,m.href=n,m.title=o,m.autoDimensions&&("html"==m.type||"inline"==m.type||"ajax"==m.type?(m.width="auto",m.height="auto"):m.autoDimensions=!1),m.modal&&(m.overlayShow=!0,m.hideOnOverlayClick=!1,m.hideOnContentClick=!1,m.enableEscapeButton=!1,m.showCloseButton=!1),m.padding=parseInt(m.padding,10),m.margin=parseInt(m.margin,10),t.css("padding",m.padding+m.margin),m.enableEscapeButton&&e(document).on("keydown.fb",(function(t){if(27==t.keyCode)return t.preventDefault(),e.fancybox.cancel(),!1})),i){case"html":t.html(m.content),m.enableSwipeNav=!1,_process_inline();break;case"inline":if(!0===e(c).parent().is("#fancybox-content"))return void(T=!1);m.enableSwipeNav=!1,e(c).clone().attr("id",e(c).attr("id")+"-tmp").insertBefore(e(c)),e(document).on("fancybox-cleanup fancybox-change",(function(){let t=r.children().children();e("#"+t.attr("id")+"-tmp").replaceWith(t)})).on("fancybox-cancel",(function(){let n=t.children();n.length||(n=r.children().children()),e("#"+n.attr("id")+"-tmp").replaceWith(n)})),e(c).appendTo(t),_process_inline();break;case"image":m.keepRatio=!0,T=!1,(C=new Image).onerror=function(){_error(m.txt.error.image)},C.onload=function(){T=!0,e.fancybox.hideActivity(),C.onerror=C.onload=null,m.width=C.width,m.height=C.height,e("<img />").attr({id:"fancybox-img",src:C.src,alt:m.title}).appendTo(t),_show()},C.src=n,e.fancybox.showActivity();break;case"svg":m.scrolling="no",m.keepRatio=!0;var d='<object type="image/svg+xml" width="'+m.width+'" height="'+m.height+'" data="'+n+'"></object>';t.html(d),_process_inline();break;case"pdf":m.scrolling="no",m.enableSwipeNav=!1;d='<object type="application/pdf" width="100%" height="100%" data="'+n+'"><a href="'+n+'" style="display:block;position:absolute;top:48%;width:100%;text-align:center">'+e(c).html()+"</a></object>";t.html(d),_process_inline();break;case"ajax":m.enableKeyboardNav=!1,m.showNavArrows=!1,m.enableSwipeNav=!1,T=!1,e.fancybox.showActivity(),m.ajax.win=m.ajax.success,_=e.ajax(e.extend({},m.ajax,{url:n,data:m.ajax.data||{},error:function(){arguments[0].status>0&&_error(arguments[2])},success:function(i,o,r){if(200==("object"==typeof r?r:_).status){if("function"==typeof m.ajax.win){if(!1===(a=m.ajax.win(n,i,o,r)))return void e.fancybox.hideActivity();"string"!=typeof a&&"object"!=typeof a||(i=a)}i.indexOf("<!DOCTYPE")>-1||i.indexOf("<html")>-1||i.indexOf("<body")>-1?_error(m.txt.error.unexpected):(t.html(i),_process_inline())}}}));break;case"iframe":m.enableSwipeNav=!1,e.fancybox.showActivity(),_show();break}else _error(m.txt.error.type);else T=!1},_process_inline=function(){var n=m.width,i=m.height;e.fancybox.hideActivity(),n=n.toString().indexOf("%")>-1?parseInt((window.innerWidth-2*m.margin)*parseFloat(n)/100,10)+"px":"auto"==n?"auto":n+"px",i=i.toString().indexOf("%")>-1?parseInt((window.innerHeight-2*m.margin)*parseFloat(i)/100,10)+"px":"auto"==i?"auto":i+"px",t.wrapInner('<div style="width:'+n+";height:"+i+';overflow:hidden;position:relative;"></div>'),m.width=t.width(),m.height=t.height(),_show()},_show=function(){if(T=!0,e(r.add(i)).off(),e(window).off("resize.fb"),h=w.type,x=v,y=g,(w=m).overlayShow?(i.css({"background-color":w.overlayColor,opacity:w.overlayOpacity,cursor:w.hideOnOverlayClick?"pointer":"auto"}),i.is(":visible")||i.fadeIn("fast")):i.hide(),_process_title(),u=_get_zoom_to(),o.is(":visible"))return e(c.add(s).add(l)).hide(),void("image"===h&&"image"===w.type?(r.prepend(t.contents()),r.children().first().next().fadeOut(w.changeSpeed,(function(){e(this).remove()})),r.css("border-width",w.padding),o.animate(u,{duration:w.changeSpeed,easing:w.easingChange,complete:_finish})):r.fadeTo(w.changeFade,.3,(function(){r.css("border-width",w.padding),o.animate(u,{duration:w.changeSpeed,easing:w.easingChange,complete:function(){r.html(t.contents()).fadeTo(w.changeFade,1,_finish)}})})));o.removeAttr("style"),r.css("border-width",w.padding),r.html(t.contents()),"elastic"==w.transitionIn?(o.css(_get_orig_pos()).show(),u.opacity=1,o.attr("aria-hidden","false").animate(u,{duration:w.speedIn,easing:w.easingIn,complete:_finish})):o.css(u).attr("aria-hidden","false").fadeIn("none"==w.transitionIn?0:w.speedIn,_finish)},_format_title=function(e){return!(!e||!e.length)&&'<div id="fancybox-title">'+e+"</div>"},_process_title=function(){if(S=w.title||"",O=0,d.empty().removeAttr("style").removeClass(),!1!==w.titleShow)if((S=e.isFunction(w.titleFormat)?w.titleFormat(S,x,y,w):_format_title(S))&&""!==S){switch(d.addClass("fancybox-title-"+w.titlePosition).html(S).appendTo("body").show(),w.titlePosition){case"outside":case"inside":O=d.outerHeight(!0),d.appendTo(a);break;case"over":r.is(":visible")?d.appendTo(r):d.appendTo(t);break;default:d.css({paddingLeft:w.padding,paddingRight:w.padding}).appendTo(o)}d.hide()}else d.hide();else d.hide()},_swipe=function(){let t=p-b;p=b=0,Math.abs(t)<w.swipeThreshold||(t<0?e.fancybox.prev():e.fancybox.next())},_set_navigation=function(){1!==x.length&&(w.enableSwipeNav&&(o.css("cursor","move"),o.on("mousedown.fb",(function(e){e.preventDefault(),p=b=void 0!==e.clientX?e.clientX:e.originalEvent.clientX,o.on("mousemove.fb",(function(e){b=void 0!==e.clientX?e.clientX:e.originalEvent.clientX}))})),o.on("mouseup.fb",(function(){o.off("mousemove.fb"),_swipe()})),A&&(o.on("touchstart.fb",(function(e){j=1===e.touches.length,p=b=void 0!==e.touches?e.touches[0].clientX:e.originalEvent.touches[0].clientX,o.on("touchmove.fb",(function(e){1===e.touches.length?b=void 0!==e.touches?e.touches[0].clientX:e.originalEvent.touches[0].clientX:(j=!1,o.off("touchmove.fb"))}))})),o.on("touchend.fb",(function(){o.off("touchmove.fb"),j&&(j=!1,_swipe())})))),e.fn.mousewheel&&o.on("mousewheel.fb",(function(t,n){T?t.preventDefault():"image"!=w.type||0!=e(t.target).outerHeight()&&e(t.target).prop("scrollHeight")!==e(t.target).outerHeight()||(t.preventDefault(),e.fancybox[n>0?"prev":"next"]())})),e(document).off("keydown.fb"),(w.enableEscapeButton||w.enableKeyboardNav)&&e(document).on("keydown.fb",(function(t){if(w.enableEscapeButton&&27==t.keyCode)return t.preventDefault(),e.fancybox.close(),!1;!w.enableKeyboardNav||37!=t.keyCode&&39!=t.keyCode||"INPUT"===t.target.tagName||"TEXTAREA"===t.target.tagName||"SELECT"===t.target.tagName?w.enableKeyboardNav&&9==t.keyCode&&"INPUT"!==t.target.tagName&&"TEXTAREA"!==t.target.tagName&&"SELECT"!==t.target.tagName&&(t.preventDefault(),e.fancybox[t.shiftKey?"prev":"next"]()):(t.preventDefault(),e.fancybox[37==t.keyCode?"prev":"next"]())})),w.showNavArrows&&((w.cyclic||0!==y)&&s.attr("title",w.txt.prev).show(),(w.cyclic||y!=x.length-1)&&l.attr("title",w.txt.next).show()))},_finish=function(){S&&S.length&&d.fadeIn(),w.showCloseButton&&c.attr("title",w.txt.close).show(),_set_navigation(),w.hideOnContentClick&&r.on("click",e.fancybox.close).css("cursor","pointer"),w.hideOnOverlayClick&&i.on("click",e.fancybox.close),w.autoResize&&e(window).on("resize.fb",e.fancybox.resize),"iframe"==w.type&&e('<iframe id="fancybox-frame" name="fancybox-frame'+(new Date).getTime()+'" style="border:0;margin:0;overflow:'+("auto"==w.scrolling?"auto":"yes"==w.scrolling?"scroll":"hidden")+'" src="'+w.href+'"'+(!1===w.allowfullscreen?"":" allowfullscreen")+' allow="autoplay; encrypted-media" tabindex="999"></iframe>').appendTo(r).on("load",(function(){e.fancybox.hideActivity()})),"inline"!=w.type&&"html"!=w.type||e(r).children().css("overflow","auto"==w.scrolling?"auto":"yes"==w.scrolling?"scroll":"hidden"),o.show().focus(),T=!1,e(document).trigger("fancybox-complete",[x,y,w]),w.onComplete(x,y,w),x.length>1&&(_preload_next(),_preload_prev())},_preload_next=function(){var e="number"==typeof arguments[0]?arguments[0]:y+1;if(e>=x.length){if(!w.cyclic)return;e=0}if(e==y)return w.enableKeyboardNav=!1,w.enableSwipeNav=!1,o.off("mousewheel.fb touchstart.fb touchmove.fb touchend.fb mousedown.fb mousemove.fb mouseup.fb"),void l.hide();_preload_image(e)||_preload_next(e+1)},_preload_prev=function(){var e="number"==typeof arguments[0]?arguments[0]:y-1;if(e<0){if(!w.cyclic)return;e=x.length-1}if(e==y)return w.enableKeyboardNav=!1,w.enableSwipeNav=!1,o.off("mousewheel.fb touchstart.fb touchmove.fb touchend.fb mousedown.fb mousemove.fb mouseup.fb"),void s.hide();_preload_image(e)||_preload_prev(e-1)},_preload_image=function(t){var n=x[t];return!(void 0===n||void 0===n.href||n.href===w.href||!n.href.match(k)&&!e(n).hasClass("image"))&&((new Image).src=n.href,!0)},_get_zoom_to=function(){var t=[window.innerWidth-2*w.margin,window.innerHeight-2*w.margin-O,e(document).scrollLeft()+w.margin,e(document).scrollTop()+w.margin],n={},i=w.keepRatio&&w.height?w.width/w.height:1;return w.width.toString().indexOf("%")>-1?n.width=parseInt(t[0]*parseFloat(w.width)/100,10):n.width=w.width+2*w.padding,w.height.toString().indexOf("%")>-1?n.height=parseInt(t[1]*parseFloat(w.height)/100,10):n.height=w.height+2*w.padding,w.autoScale&&n.width>t[0]&&(n.width=t[0]-2*w.padding,n.height=parseInt(n.width/i,10)),w.autoScale&&n.height>t[1]&&(n.height=t[1]-2*w.padding,n.width=parseInt(n.height*i,10)),n.left=parseInt(Math.max(t[2],t[2]+(t[0]-n.width)/2),10),n.top=parseInt(Math.max(t[3],t[3]+(t[1]-n.height)/2),10),n},_get_orig_pos=function(){if(!m.orig)return!1;var t=e(m.orig);if(!t.length)return!1;var n=t.offset();return n.top+=parseInt(t.css("paddingTop"),10)||parseInt(t.css("border-top-width"),10)||0,n.left+=parseInt(t.css("paddingLeft"),10)||parseInt(t.css("border-left-width"),10)||0,{width:t.width()+2*w.padding,height:t.height()+2*w.padding,top:n.top-w.padding,left:n.left-w.padding,opacity:0}},_closed=function(){i.fadeOut("fast"),e(document).trigger("fancybox-closed",[x,y,w]),w.onClosed(x,y,w),_cleanup()},_cleanup=function(){i.hide(),d.empty().hide(),o.hide().attr("aria-hidden","true"),r.empty(),x=v=[],y=g=0,w=m={},e("html").css({"--vertical-scrollbar":"","--horizontal-scrollbar":""}),e("html").removeClass("fancybox-active"),e(document).off("fancybox-cancel fancybox-change fancybox-cleanup fancybox-closed"),T=!1},e.fn.fancybox=function(t){if(!e(this).length)return this;let n=e.extend({},t,e.metadata?e(this).metadata():{});return(!n.minViewportWidth||document.documentElement.clientWidth>=n.minViewportWidth)&&e(this).data("fancybox",n).attr({"aria-controls":"fancybox","aria-haspopup":"dialog"}).off("click.fb").on("click.fb",(function(t){if(t.preventDefault(),T)return!1;T=!0,e(this).blur(),v=[],g=0;var n=e(this).attr("rel")||"";return""==n||""==n.replace(/alternate|external|help|license|nofollow|noreferrer|noopener|\s+/gi,"")?v.push(this):(v=e('a[rel="'+n+'"], area[rel="'+n+'"]'),g=v.index(this)),e("html").css({"--vertical-scrollbar":window.innerWidth-e(window).width()+"px","--horizontal-scrollbar":window.innerHeight-e(window).height()+"px"}),_start(),!1})),this},e.fancybox=function(t){var n;if(!T){if(T=!0,n=void 0!==arguments[1]?arguments[1]:{},v=[],g=parseInt(n.index,10)||0,e.isArray(t)){for(var i=0,o=t.length;i<o;i++)"object"==typeof t[i]?e(t[i]).data("fancybox",e.extend({},n,t[i])):t[i]=e({}).data("fancybox",e.extend({content:t[i]},n));v=jQuery.merge(v,t)}else"object"==typeof t?e(t).data("fancybox",e.extend({},n,t)):t=e({}).data("fancybox",e.extend({content:t},n)),v.push(t);(g>v.length||g<0)&&(g=0),e("html").css({"--vertical-scrollbar":window.innerWidth-e(window).width()+"px","--horizontal-scrollbar":window.innerHeight-e(window).height()+"px"}),_start()}},e.fancybox.showActivity=function(){n.attr("title",m.txt.loading).show()},e.fancybox.hideActivity=function(){n.hide()},e.fancybox.next=function(){var t,n="number"==typeof arguments[0]?arguments[0]:y+1;if(n>=x.length){if(!w.cyclic)return;n=0}t=x[n],n!=y&&void 0!==t&&void 0!==t.href&&t.href===w.href?e.fancybox.next(n+1):e.fancybox.pos(n)},e.fancybox.prev=function(){var t,n="number"==typeof arguments[0]?arguments[0]:y-1;if(n<0){if(!w.cyclic)return;n=x.length-1}t=x[n],n!=y&&void 0!==t&&void 0!==t.href&&t.href===w.href?e.fancybox.prev(n-1):e.fancybox.pos(n)},e.fancybox.pos=function(t){T||(t=parseInt(t),x.length>1&&t!=y&&t>-1&&t<x.length&&(e(document).trigger("fancybox-change"),v=x,g=t,o.off("mousewheel.fb touchstart.fb touchmove.fb touchend.fb mousedown.fb mousemove.fb mouseup.fb").css("cursor","initial"),r.off("click"),_start()))},e.fancybox.cancel=function(){T=!0,_abort(),e(document).trigger("fancybox-cancel",[v,g,m]),m&&!1===m.onCancel(v,g,m)?T=!1:(e(v[g]).focus(),e(c.add(s).add(l)).hide(),e(r.add(i)).off(),e(window).off("resize.fb"),e(o).off("mousewheel.fb touchstart.fb touchmove.fb touchend.fb mousedown.fb mousemove.fb mouseup.fb"),e(document).off("keydown.fb"),/MSIE|Trident/.test(window.navigator.userAgent)&&r.find("iframe#fancybox-frame").attr("src","//about:blank"),o.stop(),_cleanup())},e.fancybox.close=function(){T||o.is(":hidden")||(T=!0,_abort(),e(document).trigger("fancybox-cleanup",[x,y,w]),w&&!1===w.onCleanup(x,y,w)?T=!1:(e(x[y]).focus(),e(c.add(s).add(l)).hide(),e(r.add(i)).off(),e(window).off("resize.fb"),e(o).off("mousewheel.fb touchstart.fb touchmove.fb touchend.fb mousedown.fb mousemove.fb mouseup.fb"),e(document).off("keydown.fb"),/MSIE|Trident/.test(window.navigator.userAgent)&&r.find("iframe#fancybox-frame").attr("src","//about:blank"),"inside"!==w.titlePosition&&d.empty(),o.stop(),"elastic"==w.transitionOut?(d.empty().hide(),o.animate(_get_orig_pos(),{duration:w.speedOut,easing:w.easingOut,complete:_closed})):o.fadeOut("none"==w.transitionOut?0:w.speedOut,_closed)))},e.fancybox.resize=function(){clearTimeout(f),f=setTimeout((function(){var e=[];T=!0,_process_title(),u=_get_zoom_to(),c.is(":visible")&&e.push(c)&&c.hide(),s.is(":visible")&&e.push(s)&&s.hide(),l.is(":visible")&&e.push(l)&&l.hide(),o.animate(u,{duration:w.changeSpeed,easing:w.easingChange,complete:function(){S&&S.length&&d.fadeIn(),e.forEach((function(e){e.show()})),T=!1}})}),500)},e.fancybox.init=function(){e("#fancybox-wrap").length||(e("body").append(t=e('<div id="fancybox-tmp"></div>'),n=e('<div id="fancybox-loading" title="Cancel"><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div></div>'),i=e('<div id="fancybox-overlay"></div>'),o=e('<div id="fancybox-wrap" role="dialog" aria-hidden="true" aria-labelledby="fancybox-title" tabindex="-1"></div>')),o.append(a=e('<div id="fancybox-outer"></div>')),a.append(r=e('<div id="fancybox-content"></div>'),c=e('<a id="fancybox-close" href="javascript:;" title="Close" class="fancy-ico" tabindex="1"><span></span></a>'),l=e('<a id="fancybox-next" href="javascript:;" title="Next" class="fancy-ico" tabindex="2"><span></span></a>'),s=e('<a id="fancybox-prev" href="javascript:;" title="Previous" class="fancy-ico" tabindex="3"><span></span></a>'),d=e('<div id="fancybox-title-wrap"></div>')),c.click(e.fancybox.close),n.click(e.fancybox.cancel),s.click((function(t){t.preventDefault(),e.fancybox.prev()})),l.click((function(t){t.preventDefault(),e.fancybox.next()})))},e.fn.fancybox.defaults={padding:10,margin:40,modal:!1,cyclic:!1,allowfullscreen:!1,scrolling:"auto",width:560,height:340,autoScale:!0,autoDimensions:!0,autoResize:!0,keepRatio:!1,minViewportWidth:0,swipeThreshold:100,ajax:{},svg:{wmode:"opaque"},hideOnOverlayClick:!0,hideOnContentClick:!1,overlayShow:!0,overlayColor:"#000",overlayOpacity:.6,titleShow:!0,titlePosition:"float",titleFormat:null,titleFromAlt:!0,transitionIn:"fade",transitionOut:"fade",speedIn:400,speedOut:400,changeSpeed:200,changeFade:200,easingIn:"swing",easingOut:"swing",showCloseButton:!0,showNavArrows:!0,enableEscapeButton:!0,enableKeyboardNav:!0,enableSwipeNav:!0,txt:{error:{content:"The requested content cannot be loaded.",later:"Please try again later.",type:"No content type found.",image:"No image found.",unexpected:"Unexpected response."},loading:"Cancel",close:"Close",next:"Next",prev:"Previous"},onStart:function(){},onCancel:function(){},onComplete:function(){},onCleanup:function(){},onClosed:function(){},onError:function(){}},e(document).ready((function(){e.fancybox.init()}))}(jQuery);
fancybox/2.2.0/jquery.fancybox.css CHANGED
@@ -191,7 +191,7 @@
191
  overflow: hidden;
192
  display: none;
193
  z-index: 100010;
194
- background-color: rgba(0,0,0,.7);
195
  }
196
 
197
  .fancybox-overlay-fixed {
191
  overflow: hidden;
192
  display: none;
193
  z-index: 100010;
194
+ background-color: rgba(0,0,0,.6);
195
  }
196
 
197
  .fancybox-overlay-fixed {
fancybox/2.2.0/jquery.fancybox.min.css CHANGED
@@ -1 +1 @@
1
- .fancybox-wrap,.fancybox-skin,.fancybox-outer,.fancybox-inner,.fancybox-wrap img,.fancybox-wrap iframe,.fancybox-wrap object,.fancybox-nav,.fancybox-nav span,.fancybox-tmp{padding:0;margin:0;border:0;outline:none;vertical-align:top;}.fancybox-wrap{position:absolute;top:0;left:0;transform:translate3d(0,0,0);z-index:100020;}.fancybox-skin{position:relative;background:#f9f9f9;color:#444;text-shadow:none;}.fancybox-opened{z-index:100030;}.fancybox-opened .fancybox-skin{box-shadow:0 10px 25px rgba(0,0,0,.5);}.fancybox-outer,.fancybox-inner{position:relative;}.fancybox-inner{overflow:hidden;}.fancybox-type-iframe .fancybox-inner{-webkit-overflow-scrolling:touch;}.fancybox-error{color:#444;font:14px/20px "Helvetica Neue",Helvetica,Arial,sans-serif;margin:0;padding:15px;white-space:nowrap;}.fancybox-wrap .fancybox-image,.fancybox-wrap .fancybox-iframe{display:block;width:100%;height:100%;}.fancybox-wrap .fancybox-image{max-width:100%;max-height:100%;}#fancybox-loading,.fancybox-close,.fancybox-prev span,.fancybox-next span{background-image:url(fancybox_sprite.png);}#fancybox-loading{position:fixed;top:50%;left:50%;margin-top:-22px;margin-left:-22px;background-position:0 -108px;opacity:.8;cursor:pointer;z-index:100060;}#fancybox-loading div{width:44px;height:44px;background:url(fancybox_loading.gif) center center no-repeat;}.fancybox-close{position:absolute;top:-18px;right:-18px;width:36px;height:36px;cursor:pointer;z-index:100040;}.fancybox-nav{position:absolute;top:0;width:40%;height:100%;cursor:pointer;text-decoration:none;background:transparent;-webkit-tap-highlight-color:rgba(0,0,0,0);z-index:100040;}.fancybox-prev{left:0;}.fancybox-next{right:0;}.fancybox-nav span{position:absolute;top:50%;width:36px;height:34px;margin-top:-18px;cursor:pointer;z-index:100040;visibility:hidden;}.fancybox-prev span{left:10px;background-position:0 -36px;}.fancybox-next span{right:10px;background-position:0 -72px;}.fancybox-nav:hover span{visibility:visible;}.fancybox-tmp{position:absolute;top:-99999px;left:-99999px;max-width:99999px;max-height:99999px;overflow:visible!important;}.fancybox-lock{overflow:visible!important;width:auto;}.fancybox-lock body{overflow:hidden!important;}.fancybox-lock-test{overflow-y:hidden!important;}.fancybox-overlay{position:absolute;top:0;left:0;overflow:hidden;display:none;z-index:100010;background-color:rgba(0,0,0,.7);}.fancybox-overlay-fixed{position:fixed;bottom:0;right:0;}.fancybox-lock .fancybox-overlay{overflow:auto;overflow-y:scroll;}.fancybox-title{visibility:hidden;font:normal 13px/20px "Helvetica Neue",Helvetica,Arial,sans-serif;position:relative;text-shadow:none;z-index:100050;}.fancybox-opened .fancybox-title{visibility:visible;}.fancybox-title-float-wrap{position:absolute;bottom:0;right:50%;margin-bottom:-37px;z-index:100050;text-align:center;}.fancybox-title-float-wrap .child{display:inline-block;margin-right:-100%;padding:2px 20px;background:black;border:2px solid white;border-radius:15px;color:#FFF;font-weight:bold;line-height:22px;white-space:nowrap;}.fancybox-title-outside-wrap{position:relative;margin-top:10px;color:#fff;}.fancybox-title-outside-wrap:first-child{margin-top:0;margin-bottom:10px;}.fancybox-title-inside-wrap{padding-top:10px;}.fancybox-title-inside-wrap:first-child{padding-top:0;padding-bottom:10px;}.fancybox-title-over-wrap{position:absolute;bottom:0;left:0;right:0;color:#fff;padding:10px;background:#000;background:rgba(0,0,0,.8);}.fancybox-hidden{display:none;}.fancybox-inner .fancybox-hidden{display:revert;}@media only screen and (-webkit-min-device-pixel-ratio:1.5),only screen and (min--moz-device-pixel-ratio:1.5),only screen and (min-device-pixel-ratio:1.5){#fancybox-loading,.fancybox-close,.fancybox-prev span,.fancybox-next span{background-image:url(fancybox_sprite@2x.png);background-size:44px 152px}#fancybox-loading div{background-image:url(fancybox_loading@2x.gif);background-size:24px 24px}}
1
+ .fancybox-wrap,.fancybox-skin,.fancybox-outer,.fancybox-inner,.fancybox-wrap img,.fancybox-wrap iframe,.fancybox-wrap object,.fancybox-nav,.fancybox-nav span,.fancybox-tmp{padding:0;margin:0;border:0;outline:none;vertical-align:top;}.fancybox-wrap{position:absolute;top:0;left:0;transform:translate3d(0,0,0);z-index:100020;}.fancybox-skin{position:relative;background:#f9f9f9;color:#444;text-shadow:none;}.fancybox-opened{z-index:100030;}.fancybox-opened .fancybox-skin{box-shadow:0 10px 25px rgba(0,0,0,.5);}.fancybox-outer,.fancybox-inner{position:relative;}.fancybox-inner{overflow:hidden;}.fancybox-type-iframe .fancybox-inner{-webkit-overflow-scrolling:touch;}.fancybox-error{color:#444;font:14px/20px "Helvetica Neue",Helvetica,Arial,sans-serif;margin:0;padding:15px;white-space:nowrap;}.fancybox-wrap .fancybox-image,.fancybox-wrap .fancybox-iframe{display:block;width:100%;height:100%;}.fancybox-wrap .fancybox-image{max-width:100%;max-height:100%;}#fancybox-loading,.fancybox-close,.fancybox-prev span,.fancybox-next span{background-image:url(fancybox_sprite.png);}#fancybox-loading{position:fixed;top:50%;left:50%;margin-top:-22px;margin-left:-22px;background-position:0 -108px;opacity:.8;cursor:pointer;z-index:100060;}#fancybox-loading div{width:44px;height:44px;background:url(fancybox_loading.gif) center center no-repeat;}.fancybox-close{position:absolute;top:-18px;right:-18px;width:36px;height:36px;cursor:pointer;z-index:100040;}.fancybox-nav{position:absolute;top:0;width:40%;height:100%;cursor:pointer;text-decoration:none;background:transparent;-webkit-tap-highlight-color:rgba(0,0,0,0);z-index:100040;}.fancybox-prev{left:0;}.fancybox-next{right:0;}.fancybox-nav span{position:absolute;top:50%;width:36px;height:34px;margin-top:-18px;cursor:pointer;z-index:100040;visibility:hidden;}.fancybox-prev span{left:10px;background-position:0 -36px;}.fancybox-next span{right:10px;background-position:0 -72px;}.fancybox-nav:hover span{visibility:visible;}.fancybox-tmp{position:absolute;top:-99999px;left:-99999px;max-width:99999px;max-height:99999px;overflow:visible!important;}.fancybox-lock{overflow:visible!important;width:auto;}.fancybox-lock body{overflow:hidden!important;}.fancybox-lock-test{overflow-y:hidden!important;}.fancybox-overlay{position:absolute;top:0;left:0;overflow:hidden;display:none;z-index:100010;background-color:rgba(0,0,0,.6);}.fancybox-overlay-fixed{position:fixed;bottom:0;right:0;}.fancybox-lock .fancybox-overlay{overflow:auto;overflow-y:scroll;}.fancybox-title{visibility:hidden;font:normal 13px/20px "Helvetica Neue",Helvetica,Arial,sans-serif;position:relative;text-shadow:none;z-index:100050;}.fancybox-opened .fancybox-title{visibility:visible;}.fancybox-title-float-wrap{position:absolute;bottom:0;right:50%;margin-bottom:-37px;z-index:100050;text-align:center;}.fancybox-title-float-wrap .child{display:inline-block;margin-right:-100%;padding:2px 20px;background:black;border:2px solid white;border-radius:15px;color:#FFF;font-weight:bold;line-height:22px;white-space:nowrap;}.fancybox-title-outside-wrap{position:relative;margin-top:10px;color:#fff;}.fancybox-title-outside-wrap:first-child{margin-top:0;margin-bottom:10px;}.fancybox-title-inside-wrap{padding-top:10px;}.fancybox-title-inside-wrap:first-child{padding-top:0;padding-bottom:10px;}.fancybox-title-over-wrap{position:absolute;bottom:0;left:0;right:0;color:#fff;padding:10px;background:#000;background:rgba(0,0,0,.8);}.fancybox-hidden{display:none;}.fancybox-inner .fancybox-hidden{display:revert;}@media only screen and (-webkit-min-device-pixel-ratio:1.5),only screen and (min--moz-device-pixel-ratio:1.5),only screen and (min-device-pixel-ratio:1.5){#fancybox-loading,.fancybox-close,.fancybox-prev span,.fancybox-next span{background-image:url(fancybox_sprite@2x.png);background-size:44px 152px}#fancybox-loading div{background-image:url(fancybox_loading@2x.gif);background-size:24px 24px}}
inc/class-easyfancybox-admin.php CHANGED
@@ -353,29 +353,27 @@ class easyFancyBox_Admin {
353
  $setting = trim( $setting );
354
  $sanitized = '';
355
 
356
- // Is it a hex value?
357
- if ( substr( $setting, 0, 1 ) == '#' ) {
358
- // Strip #.
359
- $setting = substr( $setting, 1 );
360
-
361
- // Only allow hex values or empty string.
362
- $sanitized = ctype_xdigit( $setting ) ? '#'.$setting : '';
363
- }
364
 
365
  // Is it an rgb value?
366
- if ( substr( $setting, 0, 3 ) == 'rgb' ) {
367
  // Strip...
368
  $setting = str_replace( array('rgb(','rgba(',')'), '', $setting );
369
 
370
  $rgb_array = explode( ',', $setting );
371
 
372
- if ( $rgb_array ) {
373
- $r = isset( $rgb_array[0] ) ? (int) $rgb_array[0] : 119;
374
- $g = isset( $rgb_array[1] ) ? (int) $rgb_array[1] : 119;
375
- $b = isset( $rgb_array[2] ) ? (int) $rgb_array[2] : 119;
376
- $a = isset( $rgb_array[3] ) ? (float) $rgb_array[3] : 0.7;
377
- $sanitized = 'rgba('.$r.','.$g.','.$b.','.$a.')';
378
- }
 
 
 
 
379
  }
380
 
381
  return $sanitized;
353
  $setting = trim( $setting );
354
  $sanitized = '';
355
 
356
+ // Strip #.
357
+ $setting = ltrim( $setting, '#' );
 
 
 
 
 
 
358
 
359
  // Is it an rgb value?
360
+ if ( substr( $setting, 0, 3 ) === 'rgb' ) {
361
  // Strip...
362
  $setting = str_replace( array('rgb(','rgba(',')'), '', $setting );
363
 
364
  $rgb_array = explode( ',', $setting );
365
 
366
+ $r = ! empty( $rgb_array[0] ) ? (int) $rgb_array[0] : 0;
367
+ $g = ! empty( $rgb_array[1] ) ? (int) $rgb_array[1] : 0;
368
+ $b = ! empty( $rgb_array[2] ) ? (int) $rgb_array[2] : 0;
369
+ $a = ! empty( $rgb_array[3] ) ? (float) $rgb_array[3] : 0.6;
370
+
371
+ $sanitized = 'rgba('.$r.','.$g.','.$b.','.$a.')';
372
+ }
373
+ // Is it a hex value?
374
+ elseif ( ctype_xdigit( $setting ) ) {
375
+ // Only allow max 6 hexdigit values.
376
+ $sanitized = '#'. substr( $setting, 0, 6 );
377
  }
378
 
379
  return $sanitized;
inc/class-easyfancybox.php CHANGED
@@ -181,47 +181,6 @@ class easyFancyBox {
181
  return $html;
182
  }
183
 
184
- public static function maybe_upgrade()
185
- {
186
- $old_version = get_option( 'easy_fancybox_version', 0 );
187
-
188
- if ( 0 !== version_compare( EASY_FANCYBOX_VERSION, $old_version ) ) {
189
- self::upgrade( $old_version );
190
- }
191
- }
192
-
193
- public static function upgrade( $old_version )
194
- {
195
- // Upgrade from 1.7 or older.
196
- if ( ! $old_version ) {
197
- delete_option( 'fancybox_PDFclassType' );
198
- }
199
-
200
- // Upgrade from before 1.9.
201
- if ( version_compare( $old_version, '0', '>' ) && version_compare( $old_version, '1.9.1', '<' ) ) {
202
- // Introducing script version.
203
- add_option( 'fancybox_scriptVersion', 'classic' );
204
-
205
- // Change PDF embed option default.
206
- $onstart = get_option('fancybox_PDFonStart');
207
- $replaces = array(
208
- 'function(a,i,o){o.type=\'pdf\';}' => '{{object}}',
209
- 'function(a,i,o){o.type=\'html\';o.content=\'<embed src="\'+a[i].href+\'" type="application/pdf" height="100%" width="100%" />\'}' => '{{embed}}',
210
- 'function(a,i,o){o.href=\'https://docs.google.com/viewer?embedded=true&url=\'+a[i].href;}' => '{{googleviewer}}'
211
- );
212
- if ( false === $onstart ) {
213
- add_option( 'fancybox_PDFonStart', '{{object}}' );
214
- } elseif ( array_key_exists( $onstart, $replaces ) ) {
215
- update_option( 'fancybox_PDFonStart', $replaces[$onstart] );
216
- } else {
217
- update_option( 'fancybox_PDFonStart', '' );
218
- }
219
- }
220
-
221
- // Save new version.
222
- update_option( 'easy_fancybox_version', EASY_FANCYBOX_VERSION );
223
- }
224
-
225
  public static function priority()
226
  {
227
  if ( null === self::$priority ) {
@@ -323,7 +282,6 @@ class easyFancyBox {
323
  // VARS
324
  self::$plugin_url = plugins_url( '/', EASY_FANCYBOX_BASENAME /* EASY_FANCYBOX_DIR.'/easy-fancybox.php' */ );
325
 
326
- add_action( 'init', array( __CLASS__, 'maybe_upgrade' ), 9 );
327
  add_action( 'init', array( __CLASS__, 'extend' ), 9 );
328
  }
329
  }
181
  return $html;
182
  }
183
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
184
  public static function priority()
185
  {
186
  if ( null === self::$priority ) {
282
  // VARS
283
  self::$plugin_url = plugins_url( '/', EASY_FANCYBOX_BASENAME /* EASY_FANCYBOX_DIR.'/easy-fancybox.php' */ );
284
 
 
285
  add_action( 'init', array( __CLASS__, 'extend' ), 9 );
286
  }
287
  }
inc/fancybox-2-options.php CHANGED
@@ -121,9 +121,9 @@ $efb_options = array (
121
  'description' => esc_html__('Close FancyBox when overlay is clicked.','easy-fancybox')
122
  ),
123
  'overlayColor' => array (
124
- 'id' => 'fancybox_overlayColor',
125
  'title' => esc_html__('Color','easy-fancybox'),
126
- 'label_for' => 'fancybox_overlayColor',
127
  'input' => 'text',
128
  'hide' => true,
129
  'sanitize_callback' => 'colorval',
121
  'description' => esc_html__('Close FancyBox when overlay is clicked.','easy-fancybox')
122
  ),
123
  'overlayColor' => array (
124
+ 'id' => 'fancybox_overlayColor2',
125
  'title' => esc_html__('Color','easy-fancybox'),
126
+ 'label_for' => 'fancybox_overlayColor2',
127
  'input' => 'text',
128
  'hide' => true,
129
  'sanitize_callback' => 'colorval',
inc/fancybox-2.php CHANGED
@@ -56,10 +56,10 @@ function prepare_inline_scripts() {
56
  if ( ! \get_option( 'fancybox_hideOnOverlayClick', true ) ) {
57
  $fb_opts['helpers']['overlay']['closeClick'] = false;
58
  }
59
- if ( \get_option( 'fancybox_overlayColor' ) ) {
60
  $fb_opts['helpers']['overlay']['css'] = array(
61
  'background' =>
62
- \esc_attr( \get_option('fancybox_overlayColor') )
63
  );
64
  }
65
  } else {
56
  if ( ! \get_option( 'fancybox_hideOnOverlayClick', true ) ) {
57
  $fb_opts['helpers']['overlay']['closeClick'] = false;
58
  }
59
+ if ( \get_option( 'fancybox_overlayColor2' ) ) {
60
  $fb_opts['helpers']['overlay']['css'] = array(
61
  'background' =>
62
+ \esc_attr( \get_option('fancybox_overlayColor2') )
63
  );
64
  }
65
  } else {
inc/fancybox-legacy-options.php CHANGED
@@ -645,6 +645,7 @@ $efb_options = array (
645
  ),
646
  'onStart' => array (
647
  'id' => '',
 
648
  'input' => 'checkbox',
649
  'status' => 'disabled',
650
  'default' => '',
645
  ),
646
  'onStart' => array (
647
  'id' => '',
648
+ 'hide' => true,
649
  'input' => 'checkbox',
650
  'status' => 'disabled',
651
  'default' => '',
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=ravan
4
  Tags: fancybox, lightbox, gallery, image, photo, video, overlay, youtube, vimeo, dailymotion, pdf, svg, iframe, jquery, webp
5
  Requires at least: 3.3
6
  Tested up to: 6.1-RC1
7
- Stable tag: 1.9.1
8
 
9
  Easily enable the FancyBox light box on just about all media links. Multi-Site compatible. Supports iframe, inline content and well known video hosts.
10
 
@@ -32,8 +32,8 @@ Supported media and content types:
32
  Also supports:
33
 
34
  - WordPress Galleries (option "Link to" must be set to "Media File")
35
- - NextGEN galleries (see [instructions in the FAQs](https://wordpress.org/plugins/easy-fancybox#can%20nextgen%20gallery%20work%20with%20easy%20fancybox%20%3F))
36
- - Image maps
37
  - WordPress menu items (see [instructions in the FAQs](https://wordpress.org/plugins/easy-fancybox#can%20i%20make%20a%20menu%20item%20open%20in%20a%20fancybox%20overlay%20%3F))
38
  - Jetpack Infinite Scroll
39
 
@@ -82,7 +82,7 @@ If you wish to help build this plugin, you're very welcome to [translate Easy Fa
82
 
83
  - **Outbound click or Download tracking** in some of the stats plugins can interfere with FancyBox. Disable such options or exclude links manually with a class if possible (see instructions for SlimStat below)
84
  - Most plugins and themes that already include a light box script. Continue reading to see if you are using one of the know ones or follow the troubleshooting steps to find out what is conflicting on your site.
85
- - Any theme that is missing the obligatory `<?php wp_footer(); ?>` call in the footer.php template.
86
  - When showing an iframe as inline content in FancyBox -- not advised, use fancybox-iframe instead! -- the iframe will become blank after opening and closing it. The solution is to link directly to the iframe source and use `class="fancybox-iframe"` instead.
87
 
88
  = Plugin conflicts =
@@ -188,57 +188,15 @@ Yes. All links with class **nolightbox** that would normally get auto-enabled, w
188
  `<a href="url/to/fullimg.jpg" class="nolightbox"><img src="url/to/thumbnail.jpg" /></a>`
189
 
190
 
191
- = Can NextGEN Gallery work with Easy FancyBox ? =
192
 
193
- NetxGEN has its own built in FancyBox version along with a choice of other light box scripts but if you prefer to use Easy FancyBox (because of better customizability and other media support) then you need to take some steps to make the two plugins compatible.
194
 
195
- 1. Go to your Settings > Media admin page and switch OFF the FancyBox "Auto-gallery" option in the Images section;
196
- 1. Go to Gallery > Other Options and set the Lightbox Effects option to "Custom" and click on **Show Advanced Settings**;
197
- 1. fill the Code field with
198
- `class="fancybox" rel="%GALLERY_NAME%"`
199
- 1. Leave the other fields empty and save your settings.
200
 
 
201
 
202
- = Can I use ONE thumbnail to open a complete gallery ? =
203
 
204
- It can be done manually (using the internal WordPress gallery feature, or not) _or_ in combination with NextGen Gallery.
205
-
206
- **Manual**
207
-
208
- **A.** Open your post for editing in HTML mode and insert the first image thumbnail in your post content (linking to the images file, not page) to serve as the gallery thumbnail.
209
-
210
- **B.** Place the following code to start a hidden div containing all the other images that should only be visible in FancyBox:
211
- `
212
- <div class="fancybox-hidden">
213
- `
214
-
215
- **C.** Right after that starting on a new line, insert all other images you want to show in your gallery. You can even use the WordPress internal gallery feature with the shortcode `[ gallery link="file" ]`. NOTE: if the gallery thumbnail is attached to the post, it will be show a second time when flipping through the gallery in FancyBox. If you do not want that, use an image that is not attached to the post as gallery thumbnail.
216
-
217
- **D.** Close the hidden div with the following code on a new line:
218
- `
219
- </div>
220
- `
221
-
222
- **With NextGEN Gallery**
223
-
224
- You can choose between two shortcodes to show a gallery that (1) limits images per gallery using the shortcode `[nggallery id=x]` or (2) per tag name (accross galleries; you need to set tag name manually => more work but more control) using the shortcode `[nggtags gallery=YourTagName,AnotherTagName]`.
225
-
226
- General steps:
227
-
228
- **A.** Place the shortcode of your choice in your page/post content.
229
-
230
- **B.** Configure NextGen on **Gallery > Gallery Settings** to Display galleries as "NextGEN Basic Thumbnails" and then under the NextGEN Basic Thumbnails to at least have the following options set like this:
231
-
232
- 1. Number of images per page: 1
233
- 1. Use imagebrowser effect: No
234
- 1. Add hidden images: Yes
235
-
236
- **C.** Optional: add the following new CSS rule to your theme stylesheet (or install [Custom CSS](https://wordpress.org/plugins/safecss/) or [Jetpack](https://wordpress.org/plugins/jetpack/) and add it on the new Appearance > Edit CSS admin page) to hide the page browsing links below the gallery thumbnail.
237
- `
238
- .ngg-navigation {
239
- display:none;
240
- }
241
- `
242
 
243
  = Can I play YouTube, Dailymotion and Vimeo movies in a FancyBox overlay? =
244
 
@@ -252,11 +210,6 @@ Both YouTube and Vimeo movies can be made to play immediately after opening by a
252
  `
253
 
254
 
255
- = I want that 'Show in full-screen' button on my YouTube movies =
256
-
257
- Append `&fs=1` to your YouTube share URL.
258
-
259
-
260
  = Can I show a Youtube playlist in FancyBox? =
261
 
262
  Yes, just go to Youtube page of any movie that's in the playlist and use the Share button to get the share URL just like with single movies, but this time place a checkmark at the 'Share with playlist' option.
@@ -264,24 +217,7 @@ Yes, just go to Youtube page of any movie that's in the playlist and use the Sha
264
 
265
  = Can I link a NextGEN thumbnail to a Youtube movie in FancyBox? =
266
 
267
- User Mark Szoldan shared a neat trick how to do this:
268
-
269
- 1. Follow the instructions to make Easy FancyBox work smoothly with NextGEN above and make sure it all works correctly for normal thumbnails linked to their full-size version.
270
- 1. Then give the image that you want to link to a Youtube movie the URL to the Youtube page as title.
271
- 1. Finally paste the code below into a Custom HTML widget that will live in your sidebar or footer bar, or you can hard-code it into your theme but make sure it come before the `wp_footer()` call...
272
-
273
- `
274
- <script type="text/javascript">
275
- jQuery('.fancybox [title*="www.youtube.com"]').each(function() {
276
- var title = jQuery(this).attr('title');
277
- var desc = jQuery(this).parent().attr('title');
278
- jQuery(this).attr('title', desc);
279
- jQuery(this).parent().attr('href', title);
280
- });
281
- </script>
282
- `
283
-
284
- This script snippet will scan the image titles and if it finds a Youtube URL there, it will replace the links href attribute value accordingly.
285
 
286
 
287
  = Can I create a gallery of Youtube thumbnails which open in FancyBox? =
@@ -334,41 +270,9 @@ For example, an SVG file with different size:
334
  <a class="fancybox-svg {width:1024,height:675}" href="_your_svg_"></a>
335
  `
336
 
337
- = How can I display INLINE content in a FancyBox overlay ? =
338
-
339
- First go to your **Settings > Media** admin page and activate the **Inline** option under the FancyBox settings. After saving, the amin page will show a new section called Inline where you can tweak its parameters.
340
-
341
- Next, open your page/post for editing in the HTML tab and wrap the inline content in
342
- `
343
- <div style="display:none" class="fancybox-hidden"><div id="fancyboxID-1" class="hentry" style="width:460px;max-width:100%;">
344
- ...inline content here...
345
- </div></div>
346
- `
347
-
348
- Then place a FancyBox link tag with class attribute "fancybox-inline" anywhere else in the post/page content that will point to the inline content like
349
- `
350
- <a href="#fancyboxID-1" class="fancybox-inline">Read my inline content</a>
351
- `
352
-
353
- NOTE: The wrapping divs ID *must* be unique and it must correspond with the links HREF with a # in front of it. When using the above example for more FancyBox inline content (hidden div + opening link) combinations on one page, give the second one the ID fancyboxID-2 and so on...
354
-
355
- NOTE 2: If you find that the inline content shown in FancyBox is styled very different than the rests of the page content, then you might want to change the div tag attribute `class="hentry"` to something else that matches your theme. Find out what class name is used for the main content on your site and re-use that.
356
 
357
-
358
- = Can I display a contact form in FancyBox? =
359
-
360
- Yes. There are several methods imaginable but the easiest would be to use the Inline method. First go to your Settings > Media admin page and enable the Inline Content option. Next, go back to edit your post or page in the Text editor tab. The inline content can be a shortcode like in this example using Contact Forms 7 and Easy FancyBox:
361
-
362
- `
363
- <a href="#contact_form_pop" class="fancybox-inline">Contact Us</a>
364
-
365
- <div style="display:none" class="fancybox-hidden">
366
- <div id="contact_form_pop" class="hentry" style="width:460px;max-width:100%;">
367
- [contact-form-7 id="87" title="Contact form 1"]
368
- </div>
369
- </div>
370
- `
371
- Where you replace the shortcode (between the [ and ] characters) with the one given by the plugin. It can also work with shortcode by other plugins like Jetpack's Contact Form module. Change the class attribute to reflect the class used for the div that wraps your post content to have any form CSS style rules that are limited to post content, be applied to the inline content inside FancyBox.
372
 
373
 
374
  = Can I make an image or hidden content to pop up in FancyBox on page load? =
@@ -380,7 +284,7 @@ Use the instructions above for inline content but this time give the link also `
380
  Same can be done with any other media or iframe link! But please remember there can be only **one** item using the ID fancybox-auto per page...
381
 
382
 
383
- = Can I have a modal window ? =
384
 
385
  Yes, just create a hidden inline content light box (can be auto-popup) as described above and give the link an extra class "modal". This will remove all options to close the light box, like the close button, an overlay click or escape key.
386
 
@@ -391,7 +295,12 @@ This means there is NO option to close the light box, unless you create a link l
391
  `
392
 
393
 
394
- = Can I make a menu item open in a FancyBox overlay ? =
 
 
 
 
 
395
 
396
  Yes. But it depends on you theme what you need to do to make it work. If you are on WordPress 3+ and your theme supports the new internal Custom Menu feature or if you are using a custom menu in a sidebar widget, it's easy:
397
 
@@ -403,7 +312,7 @@ Yes. But it depends on you theme what you need to do to make it work. If you are
403
  If you are on an older version of WordPress or if you cannot use WP's Menus, you will need to do some heavy theme hacking to get it to work. Basically, what you need to achieve is that the menu item you want opened in a lightbox overlay, should get a `class="fancybox-iframe"` attribute.
404
 
405
 
406
- = How can I make AJAX loaded content be seen by FancyBox ? =
407
 
408
  Easy FancyBox initially scans the page source for media links on the "Document Loaded" event. This means right after the page source has become available to and read by the browser. When content is added or modified through AJAX (meaning after initial page load) by your theme or another plugin, then FancyBox will not be aware of any media links in that new content.
409
 
@@ -462,12 +371,16 @@ If you still do not get to see your images in FancyBox, ask on the [Easy FancyBo
462
 
463
  == Upgrade Notice ==
464
 
465
- = 1.9.1 =
466
 
467
  Bugfix release.
468
 
469
  == Changelog ==
470
 
 
 
 
 
471
  = 1.9.1 =
472
  * FIX: Passing event parameters failing
473
  * FIX: Case insesitive selectors failing
4
  Tags: fancybox, lightbox, gallery, image, photo, video, overlay, youtube, vimeo, dailymotion, pdf, svg, iframe, jquery, webp
5
  Requires at least: 3.3
6
  Tested up to: 6.1-RC1
7
+ Stable tag: 1.9.2
8
 
9
  Easily enable the FancyBox light box on just about all media links. Multi-Site compatible. Supports iframe, inline content and well known video hosts.
10
 
32
  Also supports:
33
 
34
  - WordPress Galleries (option "Link to" must be set to "Media File")
35
+ - NextGEN galleries (see [instructions](https://premium.status301.com/knowledge-base/easy-fancybox/nextgen-gallery/))
36
+ - Image maps (see [instructions](https://premium.status301.com/knowledge-base/easy-fancybox/image-maps/))
37
  - WordPress menu items (see [instructions in the FAQs](https://wordpress.org/plugins/easy-fancybox#can%20i%20make%20a%20menu%20item%20open%20in%20a%20fancybox%20overlay%20%3F))
38
  - Jetpack Infinite Scroll
39
 
82
 
83
  - **Outbound click or Download tracking** in some of the stats plugins can interfere with FancyBox. Disable such options or exclude links manually with a class if possible (see instructions for SlimStat below)
84
  - Most plugins and themes that already include a light box script. Continue reading to see if you are using one of the know ones or follow the troubleshooting steps to find out what is conflicting on your site.
85
+ - Any theme that is missing the obligatory `<?php wp_footer();?>` call in the footer.php template.
86
  - When showing an iframe as inline content in FancyBox -- not advised, use fancybox-iframe instead! -- the iframe will become blank after opening and closing it. The solution is to link directly to the iframe source and use `class="fancybox-iframe"` instead.
87
 
88
  = Plugin conflicts =
188
  `<a href="url/to/fullimg.jpg" class="nolightbox"><img src="url/to/thumbnail.jpg" /></a>`
189
 
190
 
191
+ = Can NextGEN Gallery work with Easy FancyBox? =
192
 
193
+ Yes, see [instructions](https://premium.status301.com/knowledge-base/easy-fancybox/nextgen-gallery/)
194
 
 
 
 
 
 
195
 
196
+ = Can I use ONE thumbnail to open a complete gallery? =
197
 
198
+ Yes, see [instructions](https://premium.status301.com/knowledge-base/easy-fancybox/one-thumbnail-to-open-a-complete-gallery-slideshow/)
199
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
200
 
201
  = Can I play YouTube, Dailymotion and Vimeo movies in a FancyBox overlay? =
202
 
210
  `
211
 
212
 
 
 
 
 
 
213
  = Can I show a Youtube playlist in FancyBox? =
214
 
215
  Yes, just go to Youtube page of any movie that's in the playlist and use the Share button to get the share URL just like with single movies, but this time place a checkmark at the 'Share with playlist' option.
217
 
218
  = Can I link a NextGEN thumbnail to a Youtube movie in FancyBox? =
219
 
220
+ Yes, see [instructions](https://premium.status301.com/knowledge-base/easy-fancybox/nextgen-gallery/)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
221
 
222
 
223
  = Can I create a gallery of Youtube thumbnails which open in FancyBox? =
270
  <a class="fancybox-svg {width:1024,height:675}" href="_your_svg_"></a>
271
  `
272
 
273
+ = How can I display INLINE content in a FancyBox overlay? =
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
274
 
275
+ Follow the [Inline content instructions](https://premium.status301.com/show-inline-content-in-a-light-box/).
 
 
 
 
 
 
 
 
 
 
 
 
 
 
276
 
277
 
278
  = Can I make an image or hidden content to pop up in FancyBox on page load? =
284
  Same can be done with any other media or iframe link! But please remember there can be only **one** item using the ID fancybox-auto per page...
285
 
286
 
287
+ = Can I have a modal window? =
288
 
289
  Yes, just create a hidden inline content light box (can be auto-popup) as described above and give the link an extra class "modal". This will remove all options to close the light box, like the close button, an overlay click or escape key.
290
 
295
  `
296
 
297
 
298
+ = Can I make a popup open from an image map? =
299
+
300
+ Yes, see [instructions](https://premium.status301.com/knowledge-base/easy-fancybox/image-maps/)
301
+
302
+
303
+ = Can I make a menu item open in a FancyBox overlay? =
304
 
305
  Yes. But it depends on you theme what you need to do to make it work. If you are on WordPress 3+ and your theme supports the new internal Custom Menu feature or if you are using a custom menu in a sidebar widget, it's easy:
306
 
312
  If you are on an older version of WordPress or if you cannot use WP's Menus, you will need to do some heavy theme hacking to get it to work. Basically, what you need to achieve is that the menu item you want opened in a lightbox overlay, should get a `class="fancybox-iframe"` attribute.
313
 
314
 
315
+ = How can I make AJAX loaded content be seen by FancyBox? =
316
 
317
  Easy FancyBox initially scans the page source for media links on the "Document Loaded" event. This means right after the page source has become available to and read by the browser. When content is added or modified through AJAX (meaning after initial page load) by your theme or another plugin, then FancyBox will not be aware of any media links in that new content.
318
 
371
 
372
  == Upgrade Notice ==
373
 
374
+ = 1.9.2 =
375
 
376
  Bugfix release.
377
 
378
  == Changelog ==
379
 
380
+ = 1.9.2 =
381
+ * FIX: overlay opacity ignored (classic)
382
+ * FIX: onStart not a function (legacy)
383
+
384
  = 1.9.1 =
385
  * FIX: Passing event parameters failing
386
  * FIX: Case insesitive selectors failing
uninstall.php CHANGED
@@ -72,6 +72,7 @@ class easyFancyBox_Uninstall {
72
  delete_option( 'fancybox_overlayShow' );
73
  delete_option( 'fancybox_hideOnOverlayClick' );
74
  delete_option( 'fancybox_overlayColor' );
 
75
  delete_option( 'fancybox_overlaySpotlight' );
76
  delete_option( 'fancybox_overlayOpacity' );
77
 
@@ -127,7 +128,7 @@ class easyFancyBox_Uninstall {
127
  delete_option( 'fancybox_changeSpeed' );
128
  delete_option( 'fancybox_changeFade' );
129
  delete_option( 'fancybox_autoSelector' );
130
- delete_option( 'fancybox_autoPlay' ); // fb 2
131
 
132
  // Inline.
133
  delete_option( 'fancybox_autoDimensions' );
@@ -205,9 +206,9 @@ class easyFancyBox_Uninstall {
205
  delete_option( 'fancybox_allowFullScreen' );
206
 
207
  // Google Maps.
208
- delete_option( 'fancybox_enableGoogleMaps' ); // fb 2
209
  // Instagram
210
- delete_option( 'fancybox_enableInstagram' ); // fb 2
211
 
212
  // Kilroy was here.
213
  if ( defined( 'WP_DEBUG' ) && WP_DEBUG ) {
72
  delete_option( 'fancybox_overlayShow' );
73
  delete_option( 'fancybox_hideOnOverlayClick' );
74
  delete_option( 'fancybox_overlayColor' );
75
+ delete_option( 'fancybox_overlayColor2' ); // fb2
76
  delete_option( 'fancybox_overlaySpotlight' );
77
  delete_option( 'fancybox_overlayOpacity' );
78
 
128
  delete_option( 'fancybox_changeSpeed' );
129
  delete_option( 'fancybox_changeFade' );
130
  delete_option( 'fancybox_autoSelector' );
131
+ delete_option( 'fancybox_autoPlay' ); // fb2
132
 
133
  // Inline.
134
  delete_option( 'fancybox_autoDimensions' );
206
  delete_option( 'fancybox_allowFullScreen' );
207
 
208
  // Google Maps.
209
+ delete_option( 'fancybox_enableGoogleMaps' ); // fb2
210
  // Instagram
211
+ delete_option( 'fancybox_enableInstagram' ); // fb2
212
 
213
  // Kilroy was here.
214
  if ( defined( 'WP_DEBUG' ) && WP_DEBUG ) {
upgrade.php ADDED
@@ -0,0 +1,88 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Easy FancyBox upgrade routines.
4
+ *
5
+ * Uses $old_version, EASY_FANCYBOX_PRO_VERSION
6
+ *
7
+ * @since 1.9.2
8
+ */
9
+
10
+ // Exit if not called from within WordPress.
11
+ defined( 'ABSPATH' ) || exit();
12
+
13
+ // Upgrade from 1.7 or older.
14
+ if ( ! $old_version ) {
15
+ delete_option( 'fancybox_PDFclassType' );
16
+ }
17
+
18
+ // Upgrade from before 1.9.
19
+ if ( version_compare( $old_version, '0', '>' ) && version_compare( $old_version, '1.9', '<' ) ) {
20
+ // Introducing script version.
21
+ add_option( 'fancybox_scriptVersion', 'classic' );
22
+
23
+ // Change PDF embed option default.
24
+ $onstart = get_option('fancybox_PDFonStart');
25
+ $replaces = array(
26
+ 'function(a,i,o){o.type=\'pdf\';}' => '{{object}}',
27
+ 'function(a,i,o){o.type=\'html\';o.content=\'<embed src="\'+a[i].href+\'" type="application/pdf" height="100%" width="100%" />\'}' => '{{embed}}',
28
+ 'function(a,i,o){o.href=\'https://docs.google.com/viewer?embedded=true&url=\'+a[i].href;}' => '{{googleviewer}}'
29
+ );
30
+ if ( false === $onstart ) {
31
+ add_option( 'fancybox_PDFonStart', '{{object}}' );
32
+ } elseif ( array_key_exists( $onstart, $replaces ) ) {
33
+ update_option( 'fancybox_PDFonStart', $replaces[$onstart] );
34
+ } else {
35
+ update_option( 'fancybox_PDFonStart', '' );
36
+ }
37
+
38
+ }
39
+
40
+ // Upgrade from before 1.9.2
41
+ if ( version_compare( $old_version, '0', '>' ) && version_compare( $old_version, '1.9.2', '<' ) ) {
42
+ // Convert fancybox_overlayColor + fancybox_overlayOpacity to fancybox_overlayColor2.
43
+ $color = get_option( 'fancybox_overlayColor' );
44
+ $opacity = get_option( 'fancybox_overlayOpacity' );
45
+ if ( ! empty( $color ) ) {
46
+ $color = ltrim( $color, '#' );
47
+ // Is it a hex value?
48
+ if ( ctype_xdigit( $color ) ) {
49
+ // Convert 3 hexdigit to 6 hexdigit
50
+ if ( strlen( $color ) === 3 ) {
51
+ $c_array = array();
52
+ foreach( str_split( $color ) as $value ) {
53
+ $c_array[] = $value . $value;
54
+ }
55
+ } else {
56
+ $c_array = str_split( substr( $color, 0, 6 ), 2 );
57
+ }
58
+ // Convert to RGB
59
+ list( $r, $g, $b ) = array_map( "hexdec", $c_array );
60
+ // Add A
61
+ $a = ! empty( $opacity ) ? floatval( $opacity ) : 0.6;
62
+ }
63
+ // Is it an rgb(a) value?
64
+ elseif ( substr( $color, 0, 3 ) === 'rgb' ) {
65
+ // Strip...
66
+ $color = str_replace( array('rgb(','rgba(',')'), '', $color );
67
+
68
+ $rgb_array = explode( ',', $color );
69
+
70
+ $r = isset( $rgb_array[0] ) ? (int) $rgb_array[0] : 0;
71
+ $g = isset( $rgb_array[1] ) ? (int) $rgb_array[1] : 0;
72
+ $b = isset( $rgb_array[2] ) ? (int) $rgb_array[2] : 0;
73
+ $a = isset( $rgb_array[3] ) ? (float) $rgb_array[3] : ( ! empty( $opacity ) ? floatval( $opacity ) : 0.6 );
74
+ }
75
+ $color2 = 'rgba('.$r.','.$g.','.$b.','.$a.')';
76
+ } elseif ( ! empty( $opacity ) ) {
77
+ $color2 = 'rgba(0,0,0,' . floatval($opacity) . ')';
78
+ }
79
+ update_option( 'fancybox_overlayColor2', $color2 );
80
+ }
81
+
82
+ // Save new version.
83
+ update_option( 'easy_fancybox_version', EASY_FANCYBOX_VERSION );
84
+
85
+ // Kilroy was here.
86
+ if ( defined('WP_DEBUG') && WP_DEBUG ) {
87
+ error_log( 'Easy FancyBox was upgraded from ' . $old_version . ' to version '. EASY_FANCYBOX_VERSION );
88
+ }