Version Description
- Bug Fix
Download this release
Release Info
Developer | designemotions |
Plugin | Enjoy Instagram feed on website with WordPress Widget and Shortcode |
Version | 5.0.3 |
Comparing to | |
See all releases |
Code changes from version 5.0.1 to 5.0.3
- assets/css/enjoy-instagram.css +24 -0
- assets/js/jquery.gridrotator.js +14 -13
- assets/js/jquery.gridrotator.min.js +1 -1
- enjoyinstagram.php +2 -2
- includes/class.enjoyinstagram-shortcodes.php +3 -1
- readme.txt +6 -2
- templates/shortcodes/carousel-widget.php +1 -1
- templates/shortcodes/carousel.php +2 -1
- templates/shortcodes/grid-widget.php +1 -1
- templates/shortcodes/grid.php +1 -1
assets/css/enjoy-instagram.css
ADDED
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
.ei-media-type-video {
|
2 |
+
position: relative;
|
3 |
+
cursor: pointer;
|
4 |
+
}
|
5 |
+
|
6 |
+
.ei-media-type-video:before {
|
7 |
+
position:absolute;
|
8 |
+
left: 0;
|
9 |
+
top: 0;
|
10 |
+
width: 100%;
|
11 |
+
bottom: 0;
|
12 |
+
background-image: url('../images/play_overlay.png');
|
13 |
+
background-size: cover;
|
14 |
+
background-position: center center;
|
15 |
+
background-repeat: no-repeat;
|
16 |
+
content: " ";
|
17 |
+
z-index: 10;
|
18 |
+
opacity: 0.6;
|
19 |
+
pointer-events: none;
|
20 |
+
}
|
21 |
+
|
22 |
+
.ei-media-type-video:hover:before {
|
23 |
+
opacity: 1;
|
24 |
+
}
|
assets/js/jquery.gridrotator.js
CHANGED
@@ -53,17 +53,18 @@
|
|
53 |
threshold: 100
|
54 |
};
|
55 |
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
|
|
|
|
|
64 |
}
|
65 |
-
|
66 |
-
};
|
67 |
|
68 |
// HTML5 PageVisibility API
|
69 |
// http://www.html5rocks.com/en/tutorials/pagevisibility/intro/
|
@@ -251,11 +252,11 @@
|
|
251 |
++loaded;
|
252 |
var video = $img.parent().attr('data-video');
|
253 |
if(video==="yes"){
|
254 |
-
$img.parent().parent().css( 'background-image', 'url(' + GridRotator.
|
255 |
$img.parent().parent().css( 'background-size', 'cover');
|
256 |
$img.parent().css( 'background-image', 'url(' + src + ')' );
|
257 |
$img.parent().css( 'opacity', '0.45');
|
258 |
-
|
259 |
}else{
|
260 |
$img.parent().css( 'background-image', 'url(' + src + ')' );
|
261 |
}
|
@@ -731,7 +732,7 @@
|
|
731 |
var video = $inA.attr('data-video');
|
732 |
var bg = $inA.attr('style');
|
733 |
if(video==="yes"){
|
734 |
-
$inA.parent().css( 'background-image', 'url(' + GridRotator.
|
735 |
$inA.parent().css( 'background-size', 'cover' );
|
736 |
$inA.css( 'opacity', '0.45');
|
737 |
}
|
53 |
threshold: 100
|
54 |
};
|
55 |
|
56 |
+
Object.defineProperty(Array.prototype, 'shuffle', {
|
57 |
+
value: function() {
|
58 |
+
var i=this.length,p,t;
|
59 |
+
while (i--) {
|
60 |
+
p = Math.floor(Math.random()*i);
|
61 |
+
t = this[i];
|
62 |
+
this[i]=this[p];
|
63 |
+
this[p]=t;
|
64 |
+
}
|
65 |
+
return this;
|
66 |
}
|
67 |
+
});
|
|
|
68 |
|
69 |
// HTML5 PageVisibility API
|
70 |
// http://www.html5rocks.com/en/tutorials/pagevisibility/intro/
|
252 |
++loaded;
|
253 |
var video = $img.parent().attr('data-video');
|
254 |
if(video==="yes"){
|
255 |
+
$img.parent().parent().css( 'background-image', 'url(' + GridRotator.assetsUrl + '/images/play_overlay.png' + ')' );
|
256 |
$img.parent().parent().css( 'background-size', 'cover');
|
257 |
$img.parent().css( 'background-image', 'url(' + src + ')' );
|
258 |
$img.parent().css( 'opacity', '0.45');
|
259 |
+
|
260 |
}else{
|
261 |
$img.parent().css( 'background-image', 'url(' + src + ')' );
|
262 |
}
|
732 |
var video = $inA.attr('data-video');
|
733 |
var bg = $inA.attr('style');
|
734 |
if(video==="yes"){
|
735 |
+
$inA.parent().css( 'background-image', 'url(' + GridRotator.assetsUrl + '/images/play_overlay.png' + ')' );
|
736 |
$inA.parent().css( 'background-size', 'cover' );
|
737 |
$inA.css( 'opacity', '0.45');
|
738 |
}
|
assets/js/jquery.gridrotator.min.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
!function(t,e,s){"use strict";var o,i,a=t.event;function n(){var t=["webkit","moz","ms","o"];if("hidden"in document)return"hidden";for(var e=0;e<t.length;e++)if(t[e]+"Hidden"in document)return t[e]+"Hidden";return null}function r(t){return 0===Object.keys(t).length}o=a.special.debouncedresize={setup:function(){t(this).on("resize",o.handler)},teardown:function(){t(this).off("resize",o.handler)},handler:function(t,e){var s=this,n=arguments,r=function(){t.type="debouncedresize",a.dispatch.apply(s,n)};i&&clearTimeout(i),e?r():i=setTimeout(r,o.threshold)},threshold:100},Array.prototype.shuffle=function(){for(var t,e,s=this.length;s--;)t=Math.floor(Math.random()*s),e=this[s],this[s]=this[t],this[t]=e;return this};var h=t(e),l=e.Modernizr;t.GridRotator=function(e,s){if(this.$el=t(s),l.backgroundsize){this.$el.addClass("ri-grid-loading"),this._init(e)}},t.GridRotator.defaults={rows:4,columns:10,w1024:{rows:3,columns:8},w768:{rows:3,columns:7},w480:{rows:3,columns:5},w320:{rows:2,columns:4},w240:{rows:2,columns:3},step:"random",maxStep:3,preventClick:!0,animType:"random",animSpeed:800,animEasingOut:"linear",animEasingIn:"linear",interval:3e3,slideshow:!0,onhover:!1,nochange:[],onDraw:function(){},heightToWidthRatio:1,subImg:!1},t.GridRotator.prototype={_init:function(e){this.options=t.extend(!0,{},t.GridRotator.defaults,e),this._config()},_config:function(){var e=this;this.supportTransitions=l.csstransitions,this.supportTransforms3D=l.csstransforms3d,this.transEndEventName={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd",msTransition:"MSTransitionEnd",transition:"transitionend"}[l.prefixed("transition")]+".gridrotator",this.animTypes=this.supportTransforms3D?["fadeInOut","slideLeft","slideRight","slideTop","slideBottom","rotateLeft","rotateRight","rotateTop","rotateBottom","scale","rotate3d","rotateLeftScale","rotateRightScale","rotateTopScale","rotateBottomScale"]:["fadeInOut","slideLeft","slideRight","slideTop","slideBottom"],this.animType=this.options.animType,"random"===this.animType||this.supportTransforms3D||-1!==t.inArray(this.animType,this.animTypes)||"showHide"===this.animType||(this.animType="fadeInOut"),this.animTypesTotal=this.animTypes.length,this.$list=this.$el.children("ul"),this.$list.css("padding-left","0");var s=0,o=0,i=this.$list.find("img"),a=i.length,n=["#D92727","#FFE433","#0DB8B5"];e.options.subImg&&t("<img/>").error(function(){e.options.subImg=!1}).attr("src",e.options.subImg),i.each(function(){var r=t(this),h=r.attr("src");t("<img/>").load(function(){++s,"yes"===r.parent().attr("data-video")?(r.parent().parent().css("background-image","url("+GridRotator.pluginsUrl+"/enjoy-instagram-instagram-responsive-images-gallery-and-carousel/images/play_overlay.png)"),r.parent().parent().css("background-size","cover"),r.parent().css("background-image","url("+h+")"),r.parent().css("opacity","0.45"),console.log(r.parent().attr("href"))):r.parent().css("background-image","url("+h+")"),s+o===a&&(i.remove(),e.$el.removeClass("ri-grid-loading"),e.$items=e.$list.children("li"),e.$itemsCache=e.$items.clone(),e.itemsTotal=e.$items.length,e.outItems=[],e._layout(function(){e._initEvents()}),e._start())}).attr("src",h),t("<img/>").error(function(){if(++o,e.options.subImg)r.parent().css("background-image","url("+e.options.subImg+")");else{var t=Math.floor(3*Math.random());r.parent().css("background",n[t])}s+o===a&&(i.remove(),e.$el.removeClass("ri-grid-loading"),e.$items=e.$list.children("li"),e.$itemsCache=e.$items.clone(),e.itemsTotal=e.$items.length,e.outItems=[],e._layout(function(){e._initEvents()}),e._start())}).attr("src",h)})},_layout:function(e){var s=this;this._setGridDim(),this.$list.empty(),this.$items=this.$itemsCache.clone().appendTo(this.$list);var o=this.$items.filter(":gt("+(this.showTotal-1)+")"),i=o.children("a");this.outItems.length=0,i.each(function(e){s.outItems.push(t(this))}),o.remove();for(var a=document.defaultView?parseInt(document.defaultView.getComputedStyle(this.$el.get(0),null).width):this.$el.width(),n=Math.floor(a/this.columns),r=a-this.columns*Math.floor(n),h=0;h<this.rows;++h)for(var l=0;l<this.columns;++l){var c=this.columns*h+l,d=this.$items.eq(c);d.css({width:l<Math.floor(r)?n+1:n,height:Math.floor(n*this.options.heightToWidthRatio)}),-1!==t.inArray(c,this.options.nochange)&&d.addClass("ri-nochange").data("nochange",!0)}this.options.preventClick&&this.$items.children().css("cursor","default").on("click.gridrotator",!1),e&&e.call(),this.options.onDraw.call(this)},_setGridDim:function(){var t=this.$el.width();switch(!0){case t<240:this.rows=this.options.w240.rows,this.columns=this.options.w240.columns;break;case t<320:this.rows=this.options.w320.rows,this.columns=this.options.w320.columns;break;case t<480:this.rows=this.options.w480.rows,this.columns=this.options.w480.columns;break;case t<768:this.rows=this.options.w768.rows,this.columns=this.options.w768.columns;break;case t<1024:this.rows=this.options.w1024.rows,this.columns=this.options.w1024.columns;break;default:this.rows=this.options.rows,this.columns=this.options.columns}this.showTotal=this.rows*this.columns},_initEvents:function(){var e=this;h.on("debouncedresize.gridrotator",function(){e._layout()});var s=n();if(s){var o=s.replace(/[H|h]idden/,"")+"visibilitychange";document.addEventListener(o,function(){e._visChange()})}!l.touch&&this.options.onhover&&e.$items.on("mouseenter.gridrotator",function(){var s=t(this);s.data("active")||s.data("hovered")||s.data("nochange")||(s.data("hovered",!0),e._replace(s))}).on("mouseleave.gridrotator",function(){t(this).data("hovered",!1)})},_visChange:function(){var t;(t=n())&&document[t]?clearTimeout(this.playtimeout):this._start()},_start:function(){this.showTotal<this.itemsTotal&&this.options.slideshow&&this._showNext()},_getAnimType:function(){return"random"===this.animType?this.animTypes[Math.floor(Math.random()*this.animTypesTotal)]:this.animType},_getAnimProperties:function(t){var e,s={},o={},i={},a={},n=0;switch(this._getAnimType()){case"showHide":e=0,a.opacity=0;break;case"fadeInOut":a.opacity=0;break;case"slideLeft":s.left=t.width(),i.left=0,a.left=-t.width();break;case"slideRight":s.left=-t.width(),i.left=0,a.left=t.width();break;case"slideTop":s.top=t.height(),i.top=0,a.top=-t.height();break;case"slideBottom":s.top=-t.height(),i.top=0,a.top=t.height();break;case"rotateLeft":e=this.options.animSpeed/2,s.transform="rotateY(90deg)",i.transform="rotateY(0deg)",n=e,a.transform="rotateY(-90deg)";break;case"rotateRight":e=this.options.animSpeed/2,s.transform="rotateY(-90deg)",i.transform="rotateY(0deg)",n=e,a.transform="rotateY(90deg)";break;case"rotateTop":e=this.options.animSpeed/2,s.transform="rotateX(90deg)",i.transform="rotateX(0deg)",n=e,a.transform="rotateX(-90deg)";break;case"rotateBottom":e=this.options.animSpeed/2,s.transform="rotateX(-90deg)",i.transform="rotateX(0deg)",n=e,a.transform="rotateX(90deg)";break;case"scale":e=this.options.animSpeed/2,s.transform="scale(0)",o.transform="scale(1)",i.transform="scale(1)",n=e,a.transform="scale(0)";break;case"rotateLeftScale":o.transform="scale(1)",e=this.options.animSpeed/2,s.transform="scale(0.3) rotateY(90deg)",i.transform="scale(1) rotateY(0deg)",n=e,a.transform="scale(0.3) rotateY(-90deg)";break;case"rotateRightScale":o.transform="scale(1)",e=this.options.animSpeed/2,s.transform="scale(0.3) rotateY(-90deg)",i.transform="scale(1) rotateY(0deg)",n=e,a.transform="scale(0.3) rotateY(90deg)";break;case"rotateTopScale":o.transform="scale(1)",e=this.options.animSpeed/2,s.transform="scale(0.3) rotateX(90deg)",i.transform="scale(1) rotateX(0deg)",n=e,a.transform="scale(0.3) rotateX(-90deg)";break;case"rotateBottomScale":o.transform="scale(1)",e=this.options.animSpeed/2,s.transform="scale(0.3) rotateX(-90deg)",i.transform="scale(1) rotateX(0deg)",n=e,a.transform="scale(0.3) rotateX(90deg)";break;case"rotate3d":e=this.options.animSpeed/2,s.transform="rotate3d( 1, 1, 0, 90deg )",i.transform="rotate3d( 1, 1, 0, 0deg )",n=e,a.transform="rotate3d( 1, 1, 0, -90deg )"}return{startInProp:s,startOutProp:o,endInProp:i,endOutProp:a,delay:n,animSpeed:null!=e?e:this.options.animSpeed}},_showNext:function(t){var e=this;clearTimeout(this.playtimeout),this.playtimeout=setTimeout(function(){var t=e.options.step,s=e.options.maxStep;s>e.showTotal&&(s=e.showTotal);for(var o="random"===t?Math.floor(Math.random()*s+1):Math.min(Math.abs(t),s),i=e._getRandom(o,e.showTotal),a=0;a<o;++a){var n=e.$items.eq(i[a]);if(n.data("active")||n.data("nochange"))return e._showNext(1),!1;e._replace(n)}e._showNext()},t||Math.max(Math.abs(this.options.interval),300))},_replace:function(e){e.data("active",!0);var s=this,o=e.children("a:last"),i={width:o.width(),height:o.height()};e.data("active",!0);var a=this.outItems.shift();this.outItems.push(o.clone().css("transition","none")),a.css(i).prependTo(e);var n=this._getAnimProperties(o);a.css(n.startInProp),o.css(n.startOutProp),this._setTransition(a,"all",n.animSpeed,n.delay,this.options.animEasingIn),this._setTransition(o,"all",n.animSpeed,0,this.options.animEasingOut),this._applyTransition(a,n.endInProp,n.animSpeed,function(){var e=t(this),o=n.animSpeed===s.options.animSpeed&&r(n.endInProp)?n.animSpeed:0;setTimeout(function(){s.supportTransitions&&e.off(s.transEndEventName),e.next().remove(),e.parent().data("active",!1)},o)},0===n.animSpeed||r(n.endInProp)),this._applyTransition(o,n.endOutProp,n.animSpeed);var h=a.attr("data-video");a.attr("style");"yes"===h&&(a.parent().css("background-image","url("+GridRotator.pluginsUrl+"/enjoy-instagram-instagram-responsive-images-gallery-and-carousel/images/play_overlay.png)"),a.parent().css("background-size","cover"),a.css("opacity","0.45"))},_getRandom:function(t,e){for(var s=[],o=0;o<e;++o)s.push(o);return s.shuffle().slice(0,t)},_setTransition:function(t,e,s,o,i){setTimeout(function(){t.css("transition",e+" "+s+"ms "+o+"ms "+i)},25)},_applyTransition:function(e,s,o,i,a){var n=this;setTimeout(function(){t.fn.applyStyle=n.supportTransitions?t.fn.css:t.fn.animate,i&&n.supportTransitions&&(e.on(n.transEndEventName,i),a&&i.call(e)),i=i||function(){return!1},e.stop().applyStyle(s,t.extend(!0,[],{duration:o+"ms",complete:i}))},25)}};var c=function(t){e.console&&e.console.error(t)};t.fn.gridrotator=function(e){var s=t.data(this,"gridrotator");if("string"==typeof e){var o=Array.prototype.slice.call(arguments,1);this.each(function(){s?t.isFunction(s[e])&&"_"!==e.charAt(0)?s[e].apply(s,o):c("no such method '"+e+"' for gridrotator instance"):c("cannot call methods on gridrotator prior to initialization; attempted to call method '"+e+"'")})}else this.each(function(){s?s._init():s=t.data(this,"gridrotator",new t.GridRotator(e,this))});return s}}(jQuery,window);
|
1 |
+
!function(l,e){"use strict";var a,n,r=l.event;function o(){var t=["webkit","moz","ms","o"];if("hidden"in document)return"hidden";for(var e=0;e<t.length;e++)if(t[e]+"Hidden"in document)return t[e]+"Hidden";return null}function h(t){return 0===Object.keys(t).length}a=r.special.debouncedresize={setup:function(){l(this).on("resize",a.handler)},teardown:function(){l(this).off("resize",a.handler)},handler:function(t,e){function s(){t.type="debouncedresize",r.dispatch.apply(o,i)}var o=this,i=arguments;n&&clearTimeout(n),e?s():n=setTimeout(s,a.threshold)},threshold:100},Object.defineProperty(Array.prototype,"shuffle",{value:function(){for(var t,e,s=this.length;s--;)t=Math.floor(Math.random()*s),e=this[s],this[s]=this[t],this[t]=e;return this}});var i=l(e),c=e.Modernizr;l.GridRotator=function(t,e){if(this.$el=l(e),c.backgroundsize){this.$el.addClass("ri-grid-loading"),this._init(t)}},l.GridRotator.defaults={rows:4,columns:10,w1024:{rows:3,columns:8},w768:{rows:3,columns:7},w480:{rows:3,columns:5},w320:{rows:2,columns:4},w240:{rows:2,columns:3},step:"random",maxStep:3,preventClick:!0,animType:"random",animSpeed:800,animEasingOut:"linear",animEasingIn:"linear",interval:3e3,slideshow:!0,onhover:!1,nochange:[],onDraw:function(){},heightToWidthRatio:1,subImg:!1},l.GridRotator.prototype={_init:function(t){this.options=l.extend(!0,{},l.GridRotator.defaults,t),this._config()},_config:function(){var s=this;this.supportTransitions=c.csstransitions,this.supportTransforms3D=c.csstransforms3d,this.transEndEventName={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd",msTransition:"MSTransitionEnd",transition:"transitionend"}[c.prefixed("transition")]+".gridrotator",this.animTypes=this.supportTransforms3D?["fadeInOut","slideLeft","slideRight","slideTop","slideBottom","rotateLeft","rotateRight","rotateTop","rotateBottom","scale","rotate3d","rotateLeftScale","rotateRightScale","rotateTopScale","rotateBottomScale"]:["fadeInOut","slideLeft","slideRight","slideTop","slideBottom"],this.animType=this.options.animType,"random"===this.animType||this.supportTransforms3D||-1!==l.inArray(this.animType,this.animTypes)||"showHide"===this.animType||(this.animType="fadeInOut"),this.animTypesTotal=this.animTypes.length,this.$list=this.$el.children("ul"),this.$list.css("padding-left","0");var o=0,i=0,a=this.$list.find("img"),n=a.length,r=["#D92727","#FFE433","#0DB8B5"];s.options.subImg&&l("<img/>").error(function(){s.options.subImg=!1}).attr("src",s.options.subImg),a.each(function(){var e=l(this),t=e.attr("src");l("<img/>").load(function(){++o,"yes"===e.parent().attr("data-video")?(e.parent().parent().css("background-image","url("+GridRotator.assetsUrl+"/images/play_overlay.png)"),e.parent().parent().css("background-size","cover"),e.parent().css("background-image","url("+t+")"),e.parent().css("opacity","0.45")):e.parent().css("background-image","url("+t+")"),o+i===n&&(a.remove(),s.$el.removeClass("ri-grid-loading"),s.$items=s.$list.children("li"),s.$itemsCache=s.$items.clone(),s.itemsTotal=s.$items.length,s.outItems=[],s._layout(function(){s._initEvents()}),s._start())}).attr("src",t),l("<img/>").error(function(){if(++i,s.options.subImg)e.parent().css("background-image","url("+s.options.subImg+")");else{var t=Math.floor(3*Math.random());e.parent().css("background",r[t])}o+i===n&&(a.remove(),s.$el.removeClass("ri-grid-loading"),s.$items=s.$list.children("li"),s.$itemsCache=s.$items.clone(),s.itemsTotal=s.$items.length,s.outItems=[],s._layout(function(){s._initEvents()}),s._start())}).attr("src",t)})},_layout:function(t){var e=this;this._setGridDim(),this.$list.empty(),this.$items=this.$itemsCache.clone().appendTo(this.$list);var s=this.$items.filter(":gt("+(this.showTotal-1)+")"),o=s.children("a");this.outItems.length=0,o.each(function(t){e.outItems.push(l(this))}),s.remove();for(var i=document.defaultView?parseInt(document.defaultView.getComputedStyle(this.$el.get(0),null).width):this.$el.width(),a=Math.floor(i/this.columns),n=i-this.columns*Math.floor(a),r=0;r<this.rows;++r)for(var h=0;h<this.columns;++h){var c=this.columns*r+h,d=this.$items.eq(c);d.css({width:h<Math.floor(n)?a+1:a,height:Math.floor(a*this.options.heightToWidthRatio)}),-1!==l.inArray(c,this.options.nochange)&&d.addClass("ri-nochange").data("nochange",!0)}this.options.preventClick&&this.$items.children().css("cursor","default").on("click.gridrotator",!1),t&&t.call(),this.options.onDraw.call(this)},_setGridDim:function(){var t=this.$el.width();switch(!0){case t<240:this.rows=this.options.w240.rows,this.columns=this.options.w240.columns;break;case t<320:this.rows=this.options.w320.rows,this.columns=this.options.w320.columns;break;case t<480:this.rows=this.options.w480.rows,this.columns=this.options.w480.columns;break;case t<768:this.rows=this.options.w768.rows,this.columns=this.options.w768.columns;break;case t<1024:this.rows=this.options.w1024.rows,this.columns=this.options.w1024.columns;break;default:this.rows=this.options.rows,this.columns=this.options.columns}this.showTotal=this.rows*this.columns},_initEvents:function(){var e=this;i.on("debouncedresize.gridrotator",function(){e._layout()});var t=o();if(t){var s=t.replace(/[H|h]idden/,"")+"visibilitychange";document.addEventListener(s,function(){e._visChange()})}!c.touch&&this.options.onhover&&e.$items.on("mouseenter.gridrotator",function(){var t=l(this);t.data("active")||t.data("hovered")||t.data("nochange")||(t.data("hovered",!0),e._replace(t))}).on("mouseleave.gridrotator",function(){l(this).data("hovered",!1)})},_visChange:function(){var t;(t=o())&&document[t]?clearTimeout(this.playtimeout):this._start()},_start:function(){this.showTotal<this.itemsTotal&&this.options.slideshow&&this._showNext()},_getAnimType:function(){return"random"===this.animType?this.animTypes[Math.floor(Math.random()*this.animTypesTotal)]:this.animType},_getAnimProperties:function(t){var e,s={},o={},i={},a={},n=0;switch(this._getAnimType()){case"showHide":e=0,a.opacity=0;break;case"fadeInOut":a.opacity=0;break;case"slideLeft":s.left=t.width(),i.left=0,a.left=-t.width();break;case"slideRight":s.left=-t.width(),i.left=0,a.left=t.width();break;case"slideTop":s.top=t.height(),i.top=0,a.top=-t.height();break;case"slideBottom":s.top=-t.height(),i.top=0,a.top=t.height();break;case"rotateLeft":e=this.options.animSpeed/2,s.transform="rotateY(90deg)",i.transform="rotateY(0deg)",n=e,a.transform="rotateY(-90deg)";break;case"rotateRight":e=this.options.animSpeed/2,s.transform="rotateY(-90deg)",i.transform="rotateY(0deg)",n=e,a.transform="rotateY(90deg)";break;case"rotateTop":e=this.options.animSpeed/2,s.transform="rotateX(90deg)",i.transform="rotateX(0deg)",n=e,a.transform="rotateX(-90deg)";break;case"rotateBottom":e=this.options.animSpeed/2,s.transform="rotateX(-90deg)",i.transform="rotateX(0deg)",n=e,a.transform="rotateX(90deg)";break;case"scale":e=this.options.animSpeed/2,s.transform="scale(0)",o.transform="scale(1)",i.transform="scale(1)",n=e,a.transform="scale(0)";break;case"rotateLeftScale":o.transform="scale(1)",e=this.options.animSpeed/2,s.transform="scale(0.3) rotateY(90deg)",i.transform="scale(1) rotateY(0deg)",n=e,a.transform="scale(0.3) rotateY(-90deg)";break;case"rotateRightScale":o.transform="scale(1)",e=this.options.animSpeed/2,s.transform="scale(0.3) rotateY(-90deg)",i.transform="scale(1) rotateY(0deg)",n=e,a.transform="scale(0.3) rotateY(90deg)";break;case"rotateTopScale":o.transform="scale(1)",e=this.options.animSpeed/2,s.transform="scale(0.3) rotateX(90deg)",i.transform="scale(1) rotateX(0deg)",n=e,a.transform="scale(0.3) rotateX(-90deg)";break;case"rotateBottomScale":o.transform="scale(1)",e=this.options.animSpeed/2,s.transform="scale(0.3) rotateX(-90deg)",i.transform="scale(1) rotateX(0deg)",n=e,a.transform="scale(0.3) rotateX(90deg)";break;case"rotate3d":e=this.options.animSpeed/2,s.transform="rotate3d( 1, 1, 0, 90deg )",i.transform="rotate3d( 1, 1, 0, 0deg )",n=e,a.transform="rotate3d( 1, 1, 0, -90deg )"}return{startInProp:s,startOutProp:o,endInProp:i,endOutProp:a,delay:n,animSpeed:null!=e?e:this.options.animSpeed}},_showNext:function(t){var n=this;clearTimeout(this.playtimeout),this.playtimeout=setTimeout(function(){var t=n.options.step,e=n.options.maxStep;e>n.showTotal&&(e=n.showTotal);for(var s="random"===t?Math.floor(Math.random()*e+1):Math.min(Math.abs(t),e),o=n._getRandom(s,n.showTotal),i=0;i<s;++i){var a=n.$items.eq(o[i]);if(a.data("active")||a.data("nochange"))return n._showNext(1),!1;n._replace(a)}n._showNext()},t||Math.max(Math.abs(this.options.interval),300))},_replace:function(t){t.data("active",!0);var s=this,e=t.children("a:last"),o={width:e.width(),height:e.height()};t.data("active",!0);var i=this.outItems.shift();this.outItems.push(e.clone().css("transition","none")),i.css(o).prependTo(t);var a=this._getAnimProperties(e);i.css(a.startInProp),e.css(a.startOutProp),this._setTransition(i,"all",a.animSpeed,a.delay,this.options.animEasingIn),this._setTransition(e,"all",a.animSpeed,0,this.options.animEasingOut),this._applyTransition(i,a.endInProp,a.animSpeed,function(){var t=l(this),e=a.animSpeed===s.options.animSpeed&&h(a.endInProp)?a.animSpeed:0;setTimeout(function(){s.supportTransitions&&t.off(s.transEndEventName),t.next().remove(),t.parent().data("active",!1)},e)},0===a.animSpeed||h(a.endInProp)),this._applyTransition(e,a.endOutProp,a.animSpeed);var n=i.attr("data-video");i.attr("style");"yes"===n&&(i.parent().css("background-image","url("+GridRotator.assetsUrl+"/images/play_overlay.png)"),i.parent().css("background-size","cover"),i.css("opacity","0.45"))},_getRandom:function(t,e){for(var s=[],o=0;o<e;++o)s.push(o);return s.shuffle().slice(0,t)},_setTransition:function(t,e,s,o,i){setTimeout(function(){t.css("transition",e+" "+s+"ms "+o+"ms "+i)},25)},_applyTransition:function(t,e,s,o,i){var a=this;setTimeout(function(){l.fn.applyStyle=a.supportTransitions?l.fn.css:l.fn.animate,o&&a.supportTransitions&&(t.on(a.transEndEventName,o),i&&o.call(t)),o=o||function(){return!1},t.stop().applyStyle(e,l.extend(!0,[],{duration:s+"ms",complete:o}))},25)}};function d(t){e.console&&e.console.error(t)}l.fn.gridrotator=function(t){var e=l.data(this,"gridrotator");if("string"==typeof t){var s=Array.prototype.slice.call(arguments,1);this.each(function(){e?l.isFunction(e[t])&&"_"!==t.charAt(0)?e[t].apply(e,s):d("no such method '"+t+"' for gridrotator instance"):d("cannot call methods on gridrotator prior to initialization; attempted to call method '"+t+"'")})}else this.each(function(){e?e._init():e=l.data(this,"gridrotator",new l.GridRotator(t,this))});return e}}(jQuery,window);
|
enjoyinstagram.php
CHANGED
@@ -2,13 +2,13 @@
|
|
2 |
/*
|
3 |
Plugin Name: Enjoy Plugin for Instagram
|
4 |
Description: Instagram Responsive Images Gallery and Carousel, works with Shortcodes and Widgets.
|
5 |
-
Version: 5.0.
|
6 |
Author: Mediabeta Srl
|
7 |
Text Domain: enjoy-instagram-instagram-responsive-images-gallery-and-carousel
|
8 |
Author URI: http://www.mediabeta.com/team/
|
9 |
*/
|
10 |
|
11 |
-
! defined( 'ENJOYINSTAGRAM_VERSION' ) && define( 'ENJOYINSTAGRAM_VERSION', '5.0.
|
12 |
! defined( 'ENJOYINSTAGRAM_FILE' ) && define( 'ENJOYINSTAGRAM_FILE', __FILE__ );
|
13 |
! defined( 'ENJOYINSTAGRAM_URL' ) && define( 'ENJOYINSTAGRAM_URL', plugin_dir_url( __FILE__ ) );
|
14 |
! defined( 'ENJOYINSTAGRAM_DIR' ) && define( 'ENJOYINSTAGRAM_DIR', plugin_dir_path( __FILE__ ) );
|
2 |
/*
|
3 |
Plugin Name: Enjoy Plugin for Instagram
|
4 |
Description: Instagram Responsive Images Gallery and Carousel, works with Shortcodes and Widgets.
|
5 |
+
Version: 5.0.3
|
6 |
Author: Mediabeta Srl
|
7 |
Text Domain: enjoy-instagram-instagram-responsive-images-gallery-and-carousel
|
8 |
Author URI: http://www.mediabeta.com/team/
|
9 |
*/
|
10 |
|
11 |
+
! defined( 'ENJOYINSTAGRAM_VERSION' ) && define( 'ENJOYINSTAGRAM_VERSION', '5.0.3' );
|
12 |
! defined( 'ENJOYINSTAGRAM_FILE' ) && define( 'ENJOYINSTAGRAM_FILE', __FILE__ );
|
13 |
! defined( 'ENJOYINSTAGRAM_URL' ) && define( 'ENJOYINSTAGRAM_URL', plugin_dir_url( __FILE__ ) );
|
14 |
! defined( 'ENJOYINSTAGRAM_DIR' ) && define( 'ENJOYINSTAGRAM_DIR', plugin_dir_path( __FILE__ ) );
|
includes/class.enjoyinstagram-shortcodes.php
CHANGED
@@ -87,6 +87,7 @@ class EnjoyInstagram_Shortcodes {
|
|
87 |
wp_register_style( 'swipebox_css', ENJOYINSTAGRAM_ASSETS_URL . '/css/swipebox.css' );
|
88 |
wp_register_style( 'grid_fallback', ENJOYINSTAGRAM_ASSETS_URL . '/css/grid_fallback.css' );
|
89 |
wp_register_style( 'grid_style', ENJOYINSTAGRAM_ASSETS_URL . '/css/grid_style.css' );
|
|
|
90 |
}
|
91 |
|
92 |
/**
|
@@ -101,7 +102,7 @@ class EnjoyInstagram_Shortcodes {
|
|
101 |
}
|
102 |
wp_enqueue_script( 'modernizr.custom.26633' );
|
103 |
wp_enqueue_script( 'gridrotator' );
|
104 |
-
wp_localize_script( 'gridrotator', 'GridRotator', array( '
|
105 |
wp_enqueue_script( 'owl' );
|
106 |
wp_enqueue_script( 'swipebox' );
|
107 |
wp_enqueue_script( 'orientationchange' );
|
@@ -111,6 +112,7 @@ class EnjoyInstagram_Shortcodes {
|
|
111 |
wp_enqueue_style( 'swipebox_css' );
|
112 |
wp_enqueue_style( 'grid_fallback' );
|
113 |
wp_enqueue_style( 'grid_style' );
|
|
|
114 |
|
115 |
$this->enqueued = true;
|
116 |
}
|
87 |
wp_register_style( 'swipebox_css', ENJOYINSTAGRAM_ASSETS_URL . '/css/swipebox.css' );
|
88 |
wp_register_style( 'grid_fallback', ENJOYINSTAGRAM_ASSETS_URL . '/css/grid_fallback.css' );
|
89 |
wp_register_style( 'grid_style', ENJOYINSTAGRAM_ASSETS_URL . '/css/grid_style.css' );
|
90 |
+
wp_register_style( 'enjoy_instagramm_css', ENJOYINSTAGRAM_ASSETS_URL . '/css/enjoy-instagram.css' );
|
91 |
}
|
92 |
|
93 |
/**
|
102 |
}
|
103 |
wp_enqueue_script( 'modernizr.custom.26633' );
|
104 |
wp_enqueue_script( 'gridrotator' );
|
105 |
+
wp_localize_script( 'gridrotator', 'GridRotator', array( 'assetsUrl' => ENJOYINSTAGRAM_ASSETS_URL, ) );
|
106 |
wp_enqueue_script( 'owl' );
|
107 |
wp_enqueue_script( 'swipebox' );
|
108 |
wp_enqueue_script( 'orientationchange' );
|
112 |
wp_enqueue_style( 'swipebox_css' );
|
113 |
wp_enqueue_style( 'grid_fallback' );
|
114 |
wp_enqueue_style( 'grid_style' );
|
115 |
+
wp_enqueue_style( 'enjoy_instagramm_css' );
|
116 |
|
117 |
$this->enqueued = true;
|
118 |
}
|
readme.txt
CHANGED
@@ -4,8 +4,8 @@ Donate link: https://www.google.com/url?q=https%3A%2F%2Fwww.paypal.com%2Fcgi-bin
|
|
4 |
Tags: Instagram, Instagram feed, Instagram Widget, Instagram grid, Instagram carousel, Embed Instagram, Embed Instagram feed, Instagram feed on website, responsive carousel, WordPress carousel, Instagram gallery, Instagram WordPress, Instagram pictures
|
5 |
Requires at least: 4.0
|
6 |
Tested up to: 5.4
|
7 |
-
Version: 5.0.
|
8 |
-
Stable tag: 5.0.
|
9 |
License: GPLv2 or later
|
10 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
11 |
|
@@ -210,6 +210,10 @@ In the Setting section yon can customize grid and/or Carousel view
|
|
210 |
|
211 |
== Changelog ==
|
212 |
|
|
|
|
|
|
|
|
|
213 |
= 5.0.1 =
|
214 |
* Fix bug video
|
215 |
= 5.0 =
|
4 |
Tags: Instagram, Instagram feed, Instagram Widget, Instagram grid, Instagram carousel, Embed Instagram, Embed Instagram feed, Instagram feed on website, responsive carousel, WordPress carousel, Instagram gallery, Instagram WordPress, Instagram pictures
|
5 |
Requires at least: 4.0
|
6 |
Tested up to: 5.4
|
7 |
+
Version: 5.0.3
|
8 |
+
Stable tag: 5.0.3
|
9 |
License: GPLv2 or later
|
10 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
11 |
|
210 |
|
211 |
== Changelog ==
|
212 |
|
213 |
+
= 5.0.3 =
|
214 |
+
* Bug Fix
|
215 |
+
= 5.0.2 =
|
216 |
+
* Bug Fix
|
217 |
= 5.0.1 =
|
218 |
* Fix bug video
|
219 |
= 5.0 =
|
templates/shortcodes/carousel-widget.php
CHANGED
@@ -51,7 +51,7 @@ if ( ! defined( 'ABSPATH' ) ) {
|
|
51 |
|
52 |
$link_style = "style=\"background-image: url('{$entry['images']['thumbnail']['url']}'); background-size: cover; display: block; opacity: 1;\"";
|
53 |
?>
|
54 |
-
<div class="box">
|
55 |
<a title="<?php echo $entry['caption']['text'] ?>" rel="gallery_swypebox"
|
56 |
class="<?php echo $entry['type'] === 'video' ? 'swipebox swipebox_video' : 'swipebox' ?>"
|
57 |
href="<?php echo $url ?>" <?php echo $link_style ?>>
|
51 |
|
52 |
$link_style = "style=\"background-image: url('{$entry['images']['thumbnail']['url']}'); background-size: cover; display: block; opacity: 1;\"";
|
53 |
?>
|
54 |
+
<div class="box <?php echo $entry['type'] === 'video' ? 'ei-media-type-video' : 'ei-media-type-image' ?>">
|
55 |
<a title="<?php echo $entry['caption']['text'] ?>" rel="gallery_swypebox"
|
56 |
class="<?php echo $entry['type'] === 'video' ? 'swipebox swipebox_video' : 'swipebox' ?>"
|
57 |
href="<?php echo $url ?>" <?php echo $link_style ?>>
|
templates/shortcodes/carousel.php
CHANGED
@@ -57,8 +57,9 @@ if ( ! defined( 'ABSPATH' ) ) {
|
|
57 |
}
|
58 |
|
59 |
$link_style = "style=\"background-image: url('{$entry['images']['thumbnail']['url']}'); background-size: cover; display: block; opacity: 1;\"";
|
|
|
60 |
?>
|
61 |
-
<div class="box">
|
62 |
<a title="<?php echo $entry['caption']['text'] ?>" rel="gallery_swypebox" class="<?php echo $entry['type'] === 'video' ? 'swipebox swipebox_video' : 'swipebox' ?>"
|
63 |
href="<?php echo $url ?>" <?php echo $link_style ?>>
|
64 |
<img alt="<?php echo $entry['caption']['text'] ?>"
|
57 |
}
|
58 |
|
59 |
$link_style = "style=\"background-image: url('{$entry['images']['thumbnail']['url']}'); background-size: cover; display: block; opacity: 1;\"";
|
60 |
+
|
61 |
?>
|
62 |
+
<div class="box <?php echo $entry['type'] === 'video' ? 'ei-media-type-video' : 'ei-media-type-image' ?>">
|
63 |
<a title="<?php echo $entry['caption']['text'] ?>" rel="gallery_swypebox" class="<?php echo $entry['type'] === 'video' ? 'swipebox swipebox_video' : 'swipebox' ?>"
|
64 |
href="<?php echo $url ?>" <?php echo $link_style ?>>
|
65 |
<img alt="<?php echo $entry['caption']['text'] ?>"
|
templates/shortcodes/grid-widget.php
CHANGED
@@ -19,7 +19,7 @@ if ( ! defined( 'ABSPATH' ) ) {
|
|
19 |
|
20 |
?>
|
21 |
<li>
|
22 |
-
<a title="<?php echo $entry['caption']['text'] ?>" class="swipebox_grid"
|
23 |
href="<?php echo $url ?>">
|
24 |
<img alt="<?php echo $entry['caption']['text'] ?>"
|
25 |
src="<?php echo $entry['images']['thumbnail']['url'] ?>">
|
19 |
|
20 |
?>
|
21 |
<li>
|
22 |
+
<a title="<?php echo $entry['caption']['text'] ?>" class="swipebox_grid <?php echo $entry['type'] === 'video' ? 'ei-media-type-video' : 'ei-media-type-image' ?>"
|
23 |
href="<?php echo $url ?>">
|
24 |
<img alt="<?php echo $entry['caption']['text'] ?>"
|
25 |
src="<?php echo $entry['images']['thumbnail']['url'] ?>">
|
templates/shortcodes/grid.php
CHANGED
@@ -57,7 +57,7 @@ if ( ! defined( 'ABSPATH' ) ) {
|
|
57 |
|
58 |
?>
|
59 |
<li>
|
60 |
-
<a title="<?php echo $entry['caption']['text'] ?>" class="swipebox_grid"
|
61 |
href="<?php echo $url ?>">
|
62 |
<img alt="<?php echo $entry['caption']['text'] ?>"
|
63 |
src="<?php echo $entry['images']['thumbnail']['url'] ?>">
|
57 |
|
58 |
?>
|
59 |
<li>
|
60 |
+
<a title="<?php echo $entry['caption']['text'] ?>" class="swipebox_grid <?php echo $entry['type'] === 'video' ? 'ei-media-type-video' : 'ei-media-type-image' ?>"
|
61 |
href="<?php echo $url ?>">
|
62 |
<img alt="<?php echo $entry['caption']['text'] ?>"
|
63 |
src="<?php echo $entry['images']['thumbnail']['url'] ?>">
|