Changeset 3216107
- Timestamp:
- 01/02/2025 06:14:22 PM (15 months ago)
- Location:
- instagram-widget-by-wpzoom
- Files:
-
- 18 edited
- 1 copied
-
tags/2.2.2 (copied) (copied from instagram-widget-by-wpzoom/trunk)
-
tags/2.2.2/class-wpzoom-instagram-widget-settings.php (modified) (3 diffs)
-
tags/2.2.2/dist/scripts/frontend/block.asset.php (modified) (1 diff)
-
tags/2.2.2/dist/scripts/frontend/block.js (modified) (1 diff)
-
tags/2.2.2/dist/scripts/frontend/index.asset.php (modified) (1 diff)
-
tags/2.2.2/dist/scripts/frontend/index.js (modified) (1 diff)
-
tags/2.2.2/instagram-widget-by-wpzoom.php (modified) (1 diff)
-
tags/2.2.2/readme.txt (modified) (2 diffs)
-
tags/2.2.2/src/scripts/frontend/block.js (modified) (4 diffs)
-
tags/2.2.2/src/scripts/frontend/index.js (modified) (3 diffs)
-
trunk/class-wpzoom-instagram-widget-settings.php (modified) (3 diffs)
-
trunk/dist/scripts/frontend/block.asset.php (modified) (1 diff)
-
trunk/dist/scripts/frontend/block.js (modified) (1 diff)
-
trunk/dist/scripts/frontend/index.asset.php (modified) (1 diff)
-
trunk/dist/scripts/frontend/index.js (modified) (1 diff)
-
trunk/instagram-widget-by-wpzoom.php (modified) (1 diff)
-
trunk/readme.txt (modified) (2 diffs)
-
trunk/src/scripts/frontend/block.js (modified) (4 diffs)
-
trunk/src/scripts/frontend/index.js (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
instagram-widget-by-wpzoom/tags/2.2.2/class-wpzoom-instagram-widget-settings.php
r3201122 r3216107 2201 2201 $account_username = isset( $account_info['username'] ) ? sanitize_text_field( $account_info['username'] ) : ''; 2202 2202 $account_name = isset( $account_info['name'] ) ? sanitize_text_field( $account_info['name'] ) : ''; 2203 $account_name = wp_encode_emoji( $account_name ); 2204 2203 2205 $account_profile_picture = isset( $account_info['profile_picture_url'] ) ? sanitize_text_field( $account_info['profile_picture_url'] ) : ''; 2204 2206 $account_bio = isset( $account_info['biography'] ) ? sanitize_text_field( $account_info['biography'] ) : ''; 2207 $account_bio = wp_encode_emoji( $account_bio ); 2205 2208 2206 2209 if ( isset( $_POST['post_id'] ) && intval( $_POST['post_id'] ) > 0 ) { … … 2287 2290 $account_username = property_exists( $info, 'username' ) && ! empty( $info->username ) ? sanitize_text_field( $info->username ) : ''; 2288 2291 $account_name = property_exists( $info, 'name' ) && ! empty( $info->name ) ? sanitize_text_field( $info->name ) : ''; 2292 $account_name = wp_encode_emoji( $account_name ); 2293 2289 2294 $account_bio = property_exists( $info, 'biography' ) && ! empty( $info->biography ) ? sanitize_text_field( $info->biography ) : ''; 2295 2296 // emoji encode 2297 $account_bio = wp_encode_emoji( $account_bio ); 2298 2290 2299 $account_type = property_exists( $info, 'account_type' ) && ! empty( $info->account_type ) ? sanitize_text_field( $info->account_type ) : 'business'; 2291 2300 $user = wp_strip_all_tags( $info->username ); … … 2324 2333 2325 2334 $account_name = property_exists( $info, 'name' ) && ! empty( $info->name ) ? sanitize_text_field( $info->name ) : ''; 2335 $account_name = wp_encode_emoji( $account_name ); 2336 2326 2337 $account_bio = property_exists( $info, 'biography' ) && ! empty( $info->biography ) ? sanitize_text_field( $info->biography ) : ''; 2338 2339 // emoji encode 2340 $account_bio = wp_encode_emoji( $account_bio ); 2327 2341 2328 2342 $user = wp_strip_all_tags( $info->username ); -
instagram-widget-by-wpzoom/tags/2.2.2/dist/scripts/frontend/block.asset.php
r3201122 r3216107 1 <?php return array('dependencies' => array('wp-polyfill'), 'version' => ' 3ee5206fc69ce42e9966d7d024ae4e4b');1 <?php return array('dependencies' => array('wp-polyfill'), 'version' => '924d653fbe9bd797288f3a2f71c3a445'); -
instagram-widget-by-wpzoom/tags/2.2.2/dist/scripts/frontend/block.js
r2861996 r3216107 1 !function(e){var t={};function n(i){if(t[i])return t[i].exports;var r=t[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}n.m=e,n.c=t,n.d=function(e,t,i){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)n.d(i,r,function(t){return e[t]}.bind(null,r));return i},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=12)}({12:function(e,t){function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function i(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var r;r=jQuery,window.wpzInstaFrontendInit=function(){r('.zoom-instagram-widget__items[data-lightbox="1"]').each((function(){var e=r(this).parent().parent().find(".wpz-insta-lightbox-wrapper > .swiper");if(e.length>0){var t,o=e.find(".image-wrapper > .swiper");new Swiper(e.get(0),(i(t={lazy:{threshold:50},watchSlidesVisibility:!0,preloadImages:!1},"lazy",!0),i(t,"direction","horizontal"),i(t,"loop",!1),i(t,"spaceBetween",20),i(t,"autoHeight",!1),i(t,"watchOverflow",!0),i(t,"navigation",{nextEl:e.find("> .swiper-button-next").get(0),prevEl:e.find("> .swiper-button-prev").get(0)}),i(t,"keyboard",{enabled:!0,onlyInViewport:!0}), t)),o.each((function(){var e;new Swiper(r(this).get(0),(i(e={lazy:{threshold:50},watchSlidesVisibility:!0,preloadImages:!1},"lazy",!0),i(e,"direction","horizontal"),i(e,"loop",!1),i(e,"spaceBetween",20),i(e,"nested",!0),i(e,"watchOverflow",!0),i(e,"pagination",{el:r(this).find("> .swiper-pagination").get(0),type:"bullets",clickable:!0,hideOnClick:!1}),i(e,"navigation",{nextEl:r(this).find("> .swiper-button-next").get(0),prevEl:r(this).find("> .swiper-button-prev").get(0)}),i(e,"keyboard",{enabled:!0,onlyInViewport:!0}),e))})),r(this).find(".zoom-instagram-link").magnificPopup({items:{type:"inline",src:r(this).parent().parent().find(".wpz-insta-lightbox-wrapper")},closeBtnInside:!1,mainClass:"wpzoom-lightbox",midClick:!0,callbacks:{open:function(){var e=r.magnificPopup.instance.st.el,t=this.content.find("> .swiper").get(0).swiper;this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"] video')&&this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"] video').trigger("play"),"object"===n(t)&&t.slideTo(this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"]').index())}}}),r(this).find(".zoom-instagram-link").addClass("magnific-active")}}))},r(window).on("load",window.wpzInstaFrontendInit)}});1 !function(e){var t={};function n(i){if(t[i])return t[i].exports;var r=t[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}n.m=e,n.c=t,n.d=function(e,t,i){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)n.d(i,r,function(t){return e[t]}.bind(null,r));return i},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=12)}({12:function(e,t){function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function i(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var r;r=jQuery,window.wpzInstaFrontendInit=function(){r('.zoom-instagram-widget__items[data-lightbox="1"]').each((function(){var e=r(this).parent().parent().find(".wpz-insta-lightbox-wrapper > .swiper");if(e.length>0){var t,o=e.find(".image-wrapper > .swiper");new Swiper(e.get(0),(i(t={lazy:{threshold:50},watchSlidesVisibility:!0,preloadImages:!1},"lazy",!0),i(t,"direction","horizontal"),i(t,"loop",!1),i(t,"spaceBetween",20),i(t,"autoHeight",!1),i(t,"watchOverflow",!0),i(t,"navigation",{nextEl:e.find("> .swiper-button-next").get(0),prevEl:e.find("> .swiper-button-prev").get(0)}),i(t,"keyboard",{enabled:!0,onlyInViewport:!0}),i(t,"on",{activeIndexChange:function(){var e=this.slides[this.activeIndex],t=r(e).find("video").get(0);t&&t.play()}}),t)),o.each((function(){var e;new Swiper(r(this).get(0),(i(e={lazy:{threshold:50},watchSlidesVisibility:!0,preloadImages:!1},"lazy",!0),i(e,"direction","horizontal"),i(e,"loop",!1),i(e,"spaceBetween",20),i(e,"nested",!0),i(e,"watchOverflow",!0),i(e,"pagination",{el:r(this).find("> .swiper-pagination").get(0),type:"bullets",clickable:!0,hideOnClick:!1}),i(e,"navigation",{nextEl:r(this).find("> .swiper-button-next").get(0),prevEl:r(this).find("> .swiper-button-prev").get(0)}),i(e,"keyboard",{enabled:!0,onlyInViewport:!0}),i(e,"on",{activeIndexChange:function(){var e=this.slides[this.activeIndex],t=r(e).find("video").get(0);t&&t.play()}}),e))})),r(this).find(".zoom-instagram-link").magnificPopup({items:{type:"inline",src:r(this).parent().parent().find(".wpz-insta-lightbox-wrapper")},closeBtnInside:!1,mainClass:"wpzoom-lightbox",midClick:!0,callbacks:{open:function(){var e=r.magnificPopup.instance.st.el,t=this.content.find("> .swiper").get(0).swiper;this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"] video')&&this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"] video').trigger("play"),"object"===n(t)&&t.slideTo(this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"]').index())}}}),r(this).find(".zoom-instagram-link").addClass("magnific-active")}}))},r(window).on("load",window.wpzInstaFrontendInit)}}); -
instagram-widget-by-wpzoom/tags/2.2.2/dist/scripts/frontend/index.asset.php
r3201122 r3216107 1 <?php return array('dependencies' => array('wp-polyfill'), 'version' => ' 81c01956ef058606671387aee77c0f95');1 <?php return array('dependencies' => array('wp-polyfill'), 'version' => 'fe65371fffa4a50658da40646b999487'); -
instagram-widget-by-wpzoom/tags/2.2.2/dist/scripts/frontend/index.js
r2861996 r3216107 1 !function( t){var e={};function i(n){if(e[n])return e[n].exports;var a=e[n]={i:n,l:!1,exports:{}};return t[n].call(a.exports,a,a.exports,i),a.l=!0,a.exports}i.m=t,i.c=e,i.d=function(t,e,n){i.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},i.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},i.t=function(t,e){if(1&e&&(t=i(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(i.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var a in t)i.d(n,a,function(e){return t[e]}.bind(null,a));return n},i.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return i.d(e,"a",e),e},i.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},i.p="",i(i.s=11)}({11:function(t,e){function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function n(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}var a;(a=jQuery)(window).on("load",(function(){var t=!1;function e(){t||(t=!0,(window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(t){window.setTimeout(t,1e3/60)})(o))}function o(){a(".zoom-instagram-widget__items").zoomInstagramWidget(),t=!1}a.fn.zoomLoadAsyncImages=function(){return a(this).each((function(){var t=a(this),e=t.data("image-width"),i=t.data("image-resolution"),n=t.find("li").filter((function(){return a(this).data("media-id")})).map((function(){return{"media-id":a(this).attr("data-media-id"),nonce:a(this).attr("data-nonce"),"regenerate-thumbnails":a(this)[0].hasAttribute("data-regenerate-thumbnails")}}));n.length&&function n(a){if(0!=a.length){var o=a.shift();wp.ajax.post("wpzoom_instagram_get_image_async",{"media-id":o["media-id"],nonce:o.nonce,"image-resolution":i,"image-width":e,"regenerate-thumbnails":o["regenerate-thumbnails"]}).done((function(e){t.find('li[data-media-id="'+o["media-id"]+'"] .zoom-instagram-link').css("background-image","url("+e.image_src+")")})).fail((function(){})).always((function(){n(a)}))}}(n.toArray())}))},a.fn.zoomLightbox=function(){return a(this).each((function(){var t=a(this).closest(".widget").find(".wpz-insta-lightbox-wrapper > .swiper");if(t.length>0){var e,o=t.find(".image-wrapper > .swiper");new Swiper(t.get(0),(n(e={lazy:{threshold:50},watchSlidesVisibility:!0,preloadImages:!1},"lazy",!0),n(e,"direction","horizontal"),n(e,"loop",!1),n(e,"spaceBetween",20),n(e,"autoHeight",!1),n(e,"watchOverflow",!0),n(e,"navigation",{nextEl:t.find("> .swiper-button-next").get(0),prevEl:t.find("> .swiper-button-prev").get(0)}),n(e,"keyboard",{enabled:!0,onlyInViewport:!0}),e)),o.each((function(){var t;new Swiper(a(this).get(0),(n(t={lazy:{threshold:50},watchSlidesVisibility:!0,preloadImages:!1},"lazy",!0),n(t,"direction","horizontal"),n(t,"loop",!1),n(t,"spaceBetween",20),n(t,"nested",!0),n(t,"watchOverflow",!0),n(t,"pagination",{el:a(this).find("> .swiper-pagination").get(0),type:"bullets",clickable:!0,hideOnClick:!1}),n(t,"navigation",{nextEl:a(this).find("> .swiper-button-next").get(0),prevEl:a(this).find("> .swiper-button-prev").get(0)}),n(t,"keyboard",{enabled:!0,onlyInViewport:!0}),t))})),a(this).find(".zoom-instagram-link").magnificPopup({items:{type:"inline",src:a(this).closest(".widget").find(".wpz-insta-lightbox-wrapper")},closeBtnInside:!1,mainClass:"wpzoom-lightbox",midClick:!0,callbacks:{open:function(){var t=a.magnificPopup.instance.st.el,e=this.content.find("> .swiper").get(0).swiper;this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+t.data("mfp-src")+'"] video')&&this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+t.data("mfp-src")+'"] video').trigger("play"),"object"===i(e)&&e.slideTo(this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+t.data("mfp-src")+'"]').index())}}}),a(this).find(".zoom-instagram-link").addClass("magnific-active")}}))},a.fn.zoomInstagramWidget=function(){return a(this).each((function(){var t,e,i=a(this),n=i.data("images-per-row"),o=i.data("image-width"),r=i.data("image-spacing"),s=(i.data("image-lazy-loading"),i.width());s/o<n?(t=n,e=Math.floor((s-1-(n-1)*r)/n)):(t=Math.floor((s-1)/o),e=Math.floor((s-1-(t-1)*r)/t)),i.find("li").each((function(e){var i=++e;i%t==1?a(this).css("clear","left"):a(this).css("clear","none"),i%t==0?a(this).css("margin-right","0"):(a(this).css("margin-right",r+"px"),a(this).css("margin-bottom",r+"px"))})),i.find("a.zoom-instagram-link").css({width:e,height:e}),i.find("a.zoom-instagram-link-old").lazy(),i.find(".zoom-instagram-link-new").lazy(),i.removeClass("zoom-instagram-widget__items--no-js")}))},a(window).on("resize orientationchange",e),e(),a(".zoom-instagram-widget__items").zoomLoadAsyncImages(),a('.zoom-instagram-widget__items[data-lightbox="1"]').zoomLightbox();var r=_.debounce((function(){a(".zoom-instagram-widget__items").length&&(a(".zoom-instagram-widget__items").zoomInstagramWidget(),a(".zoom-instagram-widget__items").zoomLoadAsyncImages())}),1500);a(document).on("panels_setup_preview",r)}))}});1 !function(e){var t={};function i(n){if(t[n])return t[n].exports;var a=t[n]={i:n,l:!1,exports:{}};return e[n].call(a.exports,a,a.exports,i),a.l=!0,a.exports}i.m=e,i.c=t,i.d=function(e,t,n){i.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(e,t){if(1&t&&(e=i(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(i.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)i.d(n,a,function(t){return e[t]}.bind(null,a));return n},i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,"a",t),t},i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},i.p="",i(i.s=11)}({11:function(e,t){function i(e){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function n(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var a;(a=jQuery)(window).on("load",(function(){var e=!1;function t(){e||(e=!0,(window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(e){window.setTimeout(e,1e3/60)})(o))}function o(){a(".zoom-instagram-widget__items").zoomInstagramWidget(),e=!1}a.fn.zoomLoadAsyncImages=function(){return a(this).each((function(){var e=a(this),t=e.data("image-width"),i=e.data("image-resolution"),n=e.find("li").filter((function(){return a(this).data("media-id")})).map((function(){return{"media-id":a(this).attr("data-media-id"),nonce:a(this).attr("data-nonce"),"regenerate-thumbnails":a(this)[0].hasAttribute("data-regenerate-thumbnails")}}));n.length&&function n(a){if(0!=a.length){var o=a.shift();wp.ajax.post("wpzoom_instagram_get_image_async",{"media-id":o["media-id"],nonce:o.nonce,"image-resolution":i,"image-width":t,"regenerate-thumbnails":o["regenerate-thumbnails"]}).done((function(t){e.find('li[data-media-id="'+o["media-id"]+'"] .zoom-instagram-link').css("background-image","url("+t.image_src+")")})).fail((function(){})).always((function(){n(a)}))}}(n.toArray())}))},a.fn.zoomLightbox=function(){return a(this).each((function(){var e=a(this).closest(".widget").find(".wpz-insta-lightbox-wrapper > .swiper");if(e.length>0){var t,o=e.find(".image-wrapper > .swiper");new Swiper(e.get(0),(n(t={lazy:{threshold:50},watchSlidesVisibility:!0,preloadImages:!1},"lazy",!0),n(t,"direction","horizontal"),n(t,"loop",!1),n(t,"spaceBetween",20),n(t,"autoHeight",!1),n(t,"watchOverflow",!0),n(t,"navigation",{nextEl:e.find("> .swiper-button-next").get(0),prevEl:e.find("> .swiper-button-prev").get(0)}),n(t,"keyboard",{enabled:!0,onlyInViewport:!0}),n(t,"on",{activeIndexChange:function(){var e=this.slides[this.activeIndex],t=a(e).find("video").get(0);t&&t.play()}}),t)),o.each((function(){var e;new Swiper(a(this).get(0),(n(e={lazy:{threshold:50},watchSlidesVisibility:!0,preloadImages:!1},"lazy",!0),n(e,"direction","horizontal"),n(e,"loop",!1),n(e,"spaceBetween",20),n(e,"nested",!0),n(e,"watchOverflow",!0),n(e,"pagination",{el:a(this).find("> .swiper-pagination").get(0),type:"bullets",clickable:!0,hideOnClick:!1}),n(e,"navigation",{nextEl:a(this).find("> .swiper-button-next").get(0),prevEl:a(this).find("> .swiper-button-prev").get(0)}),n(e,"keyboard",{enabled:!0,onlyInViewport:!0}),n(e,"on",{activeIndexChange:function(){var e=this.slides[this.activeIndex],t=a(e).find("video").get(0);t&&t.play()}}),e))})),a(this).find(".zoom-instagram-link").magnificPopup({items:{type:"inline",src:a(this).closest(".widget").find(".wpz-insta-lightbox-wrapper")},closeBtnInside:!1,mainClass:"wpzoom-lightbox",midClick:!0,callbacks:{open:function(){var e=a.magnificPopup.instance.st.el,t=this.content.find("> .swiper").get(0).swiper;this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"] video')&&this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"] video').trigger("play"),"object"===i(t)&&t.slideTo(this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"]').index())}}}),a(this).find(".zoom-instagram-link").addClass("magnific-active")}}))},a.fn.zoomInstagramWidget=function(){return a(this).each((function(){var e,t,i=a(this),n=i.data("images-per-row"),o=i.data("image-width"),r=i.data("image-spacing"),s=(i.data("image-lazy-loading"),i.width());s/o<n?(e=n,t=Math.floor((s-1-(n-1)*r)/n)):(e=Math.floor((s-1)/o),t=Math.floor((s-1-(e-1)*r)/e)),i.find("li").each((function(t){var i=++t;i%e==1?a(this).css("clear","left"):a(this).css("clear","none"),i%e==0?a(this).css("margin-right","0"):(a(this).css("margin-right",r+"px"),a(this).css("margin-bottom",r+"px"))})),i.find("a.zoom-instagram-link").css({width:t,height:t}),i.find("a.zoom-instagram-link-old").lazy(),i.find(".zoom-instagram-link-new").lazy(),i.removeClass("zoom-instagram-widget__items--no-js")}))},a(window).on("resize orientationchange",t),t(),a(".zoom-instagram-widget__items").zoomLoadAsyncImages(),a('.zoom-instagram-widget__items[data-lightbox="1"]').zoomLightbox();var r=_.debounce((function(){a(".zoom-instagram-widget__items").length&&(a(".zoom-instagram-widget__items").zoomInstagramWidget(),a(".zoom-instagram-widget__items").zoomLoadAsyncImages())}),1500);a(document).on("panels_setup_preview",r)}))}}); -
instagram-widget-by-wpzoom/tags/2.2.2/instagram-widget-by-wpzoom.php
r3201122 r3216107 4 4 * Plugin URI: https://www.wpzoom.com/plugins/instagram-widget/ 5 5 * Description: Instagram Widget is a customizable and responsive plugin, made to help you gain even more followers by showcasing your Instagram feed on your WordPress website. 6 * Version: 2.2. 16 * Version: 2.2.2 7 7 * Author: WPZOOM 8 8 * Author URI: https://www.wpzoom.com/ -
instagram-widget-by-wpzoom/tags/2.2.2/readme.txt
r3201122 r3216107 6 6 Tested up to: 6.7 7 7 Requires PHP: 7.4 8 Stable tag: 2.2. 18 Stable tag: 2.2.2 9 9 License: GPLv2 or later 10 10 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 102 102 == Changelog == 103 103 104 = 2.2.2 = 105 * Bug fix with emojis in bio and name 106 104 107 = 2.2.1 = 105 108 * Multiple improvements -
instagram-widget-by-wpzoom/tags/2.2.2/src/scripts/frontend/block.js
r2861996 r3216107 7 7 const $nested = $swipe_el.find( '.image-wrapper > .swiper' ); 8 8 9 new Swiper( $swipe_el.get(0), {9 const swiper = new Swiper( $swipe_el.get(0), { 10 10 lazy:{ 11 11 threshold: 50 … … 26 26 enabled: true, 27 27 onlyInViewport: true 28 } 28 }, 29 on: { 30 activeIndexChange: function () { 31 32 // Get the active slide 33 const activeSlide = this.slides[this.activeIndex]; 34 const $activeSlide = $(activeSlide); 35 36 // Play the video in the active slide if it exists 37 const video = $activeSlide.find('video').get(0); 38 if (video) { 39 video.play(); 40 } 41 42 }, 43 }, 29 44 } ); 30 45 … … 55 70 enabled: true, 56 71 onlyInViewport: true 57 } 72 }, 73 on: { 74 activeIndexChange: function () { 75 76 // Get the active slide 77 const activeSlide = this.slides[this.activeIndex]; 78 const $activeSlide = $(activeSlide); 79 80 // Play the video in the active slide if it exists 81 const video = $activeSlide.find('video').get(0); 82 if (video) { 83 video.play(); 84 } 85 86 }, 87 }, 58 88 } ); 59 89 } ); … … 71 101 const magnificPopup = $.magnificPopup.instance, 72 102 currentElement = magnificPopup.st.el, 73 $thisSwiper = this.content.find( '> .swiper' ).get(0).swiper; 103 $thisSwiper = this.content.find( '> .swiper' ).get(0).swiper; 104 74 105 if( this.content.find( '> .swiper > .swiper-wrapper > .swiper-slide[data-uid="' + currentElement.data( 'mfp-src' ) + '"] video' ) ) { 75 106 this.content.find( '> .swiper > .swiper-wrapper > .swiper-slide[data-uid="' + currentElement.data( 'mfp-src' ) + '"] video' ).trigger('play'); 76 107 } 77 78 //console.log( typeof $thisSwiper );79 80 108 if ( typeof $thisSwiper === 'object' ) { 81 109 $thisSwiper.slideTo( -
instagram-widget-by-wpzoom/tags/2.2.2/src/scripts/frontend/index.js
r2861996 r3216107 57 57 const $nested = $swipe_el.find( '.image-wrapper > .swiper' ); 58 58 59 new Swiper( $swipe_el.get(0), {59 const swiper = new Swiper( $swipe_el.get(0), { 60 60 lazy:{ 61 61 threshold: 50 … … 76 76 enabled: true, 77 77 onlyInViewport: true 78 } 78 }, 79 on: { 80 activeIndexChange: function () { 81 82 // Get the active slide 83 const activeSlide = this.slides[this.activeIndex]; 84 const $activeSlide = $(activeSlide); 85 86 // Play the video in the active slide if it exists 87 const video = $activeSlide.find('video').get(0); 88 if (video) { 89 video.play(); 90 } 91 92 }, 93 }, 79 94 } ); 80 95 … … 105 120 enabled: true, 106 121 onlyInViewport: true 107 } 122 }, 123 on: { 124 activeIndexChange: function () { 125 126 // Get the active slide 127 const activeSlide = this.slides[this.activeIndex]; 128 const $activeSlide = $(activeSlide); 129 130 // Play the video in the active slide if it exists 131 const video = $activeSlide.find('video').get(0); 132 if (video) { 133 video.play(); 134 } 135 136 }, 137 }, 108 138 } ); 109 139 } ); -
instagram-widget-by-wpzoom/trunk/class-wpzoom-instagram-widget-settings.php
r3201122 r3216107 2201 2201 $account_username = isset( $account_info['username'] ) ? sanitize_text_field( $account_info['username'] ) : ''; 2202 2202 $account_name = isset( $account_info['name'] ) ? sanitize_text_field( $account_info['name'] ) : ''; 2203 $account_name = wp_encode_emoji( $account_name ); 2204 2203 2205 $account_profile_picture = isset( $account_info['profile_picture_url'] ) ? sanitize_text_field( $account_info['profile_picture_url'] ) : ''; 2204 2206 $account_bio = isset( $account_info['biography'] ) ? sanitize_text_field( $account_info['biography'] ) : ''; 2207 $account_bio = wp_encode_emoji( $account_bio ); 2205 2208 2206 2209 if ( isset( $_POST['post_id'] ) && intval( $_POST['post_id'] ) > 0 ) { … … 2287 2290 $account_username = property_exists( $info, 'username' ) && ! empty( $info->username ) ? sanitize_text_field( $info->username ) : ''; 2288 2291 $account_name = property_exists( $info, 'name' ) && ! empty( $info->name ) ? sanitize_text_field( $info->name ) : ''; 2292 $account_name = wp_encode_emoji( $account_name ); 2293 2289 2294 $account_bio = property_exists( $info, 'biography' ) && ! empty( $info->biography ) ? sanitize_text_field( $info->biography ) : ''; 2295 2296 // emoji encode 2297 $account_bio = wp_encode_emoji( $account_bio ); 2298 2290 2299 $account_type = property_exists( $info, 'account_type' ) && ! empty( $info->account_type ) ? sanitize_text_field( $info->account_type ) : 'business'; 2291 2300 $user = wp_strip_all_tags( $info->username ); … … 2324 2333 2325 2334 $account_name = property_exists( $info, 'name' ) && ! empty( $info->name ) ? sanitize_text_field( $info->name ) : ''; 2335 $account_name = wp_encode_emoji( $account_name ); 2336 2326 2337 $account_bio = property_exists( $info, 'biography' ) && ! empty( $info->biography ) ? sanitize_text_field( $info->biography ) : ''; 2338 2339 // emoji encode 2340 $account_bio = wp_encode_emoji( $account_bio ); 2327 2341 2328 2342 $user = wp_strip_all_tags( $info->username ); -
instagram-widget-by-wpzoom/trunk/dist/scripts/frontend/block.asset.php
r3201122 r3216107 1 <?php return array('dependencies' => array('wp-polyfill'), 'version' => ' 3ee5206fc69ce42e9966d7d024ae4e4b');1 <?php return array('dependencies' => array('wp-polyfill'), 'version' => '924d653fbe9bd797288f3a2f71c3a445'); -
instagram-widget-by-wpzoom/trunk/dist/scripts/frontend/block.js
r2861996 r3216107 1 !function(e){var t={};function n(i){if(t[i])return t[i].exports;var r=t[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}n.m=e,n.c=t,n.d=function(e,t,i){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)n.d(i,r,function(t){return e[t]}.bind(null,r));return i},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=12)}({12:function(e,t){function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function i(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var r;r=jQuery,window.wpzInstaFrontendInit=function(){r('.zoom-instagram-widget__items[data-lightbox="1"]').each((function(){var e=r(this).parent().parent().find(".wpz-insta-lightbox-wrapper > .swiper");if(e.length>0){var t,o=e.find(".image-wrapper > .swiper");new Swiper(e.get(0),(i(t={lazy:{threshold:50},watchSlidesVisibility:!0,preloadImages:!1},"lazy",!0),i(t,"direction","horizontal"),i(t,"loop",!1),i(t,"spaceBetween",20),i(t,"autoHeight",!1),i(t,"watchOverflow",!0),i(t,"navigation",{nextEl:e.find("> .swiper-button-next").get(0),prevEl:e.find("> .swiper-button-prev").get(0)}),i(t,"keyboard",{enabled:!0,onlyInViewport:!0}), t)),o.each((function(){var e;new Swiper(r(this).get(0),(i(e={lazy:{threshold:50},watchSlidesVisibility:!0,preloadImages:!1},"lazy",!0),i(e,"direction","horizontal"),i(e,"loop",!1),i(e,"spaceBetween",20),i(e,"nested",!0),i(e,"watchOverflow",!0),i(e,"pagination",{el:r(this).find("> .swiper-pagination").get(0),type:"bullets",clickable:!0,hideOnClick:!1}),i(e,"navigation",{nextEl:r(this).find("> .swiper-button-next").get(0),prevEl:r(this).find("> .swiper-button-prev").get(0)}),i(e,"keyboard",{enabled:!0,onlyInViewport:!0}),e))})),r(this).find(".zoom-instagram-link").magnificPopup({items:{type:"inline",src:r(this).parent().parent().find(".wpz-insta-lightbox-wrapper")},closeBtnInside:!1,mainClass:"wpzoom-lightbox",midClick:!0,callbacks:{open:function(){var e=r.magnificPopup.instance.st.el,t=this.content.find("> .swiper").get(0).swiper;this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"] video')&&this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"] video').trigger("play"),"object"===n(t)&&t.slideTo(this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"]').index())}}}),r(this).find(".zoom-instagram-link").addClass("magnific-active")}}))},r(window).on("load",window.wpzInstaFrontendInit)}});1 !function(e){var t={};function n(i){if(t[i])return t[i].exports;var r=t[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}n.m=e,n.c=t,n.d=function(e,t,i){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)n.d(i,r,function(t){return e[t]}.bind(null,r));return i},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=12)}({12:function(e,t){function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function i(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var r;r=jQuery,window.wpzInstaFrontendInit=function(){r('.zoom-instagram-widget__items[data-lightbox="1"]').each((function(){var e=r(this).parent().parent().find(".wpz-insta-lightbox-wrapper > .swiper");if(e.length>0){var t,o=e.find(".image-wrapper > .swiper");new Swiper(e.get(0),(i(t={lazy:{threshold:50},watchSlidesVisibility:!0,preloadImages:!1},"lazy",!0),i(t,"direction","horizontal"),i(t,"loop",!1),i(t,"spaceBetween",20),i(t,"autoHeight",!1),i(t,"watchOverflow",!0),i(t,"navigation",{nextEl:e.find("> .swiper-button-next").get(0),prevEl:e.find("> .swiper-button-prev").get(0)}),i(t,"keyboard",{enabled:!0,onlyInViewport:!0}),i(t,"on",{activeIndexChange:function(){var e=this.slides[this.activeIndex],t=r(e).find("video").get(0);t&&t.play()}}),t)),o.each((function(){var e;new Swiper(r(this).get(0),(i(e={lazy:{threshold:50},watchSlidesVisibility:!0,preloadImages:!1},"lazy",!0),i(e,"direction","horizontal"),i(e,"loop",!1),i(e,"spaceBetween",20),i(e,"nested",!0),i(e,"watchOverflow",!0),i(e,"pagination",{el:r(this).find("> .swiper-pagination").get(0),type:"bullets",clickable:!0,hideOnClick:!1}),i(e,"navigation",{nextEl:r(this).find("> .swiper-button-next").get(0),prevEl:r(this).find("> .swiper-button-prev").get(0)}),i(e,"keyboard",{enabled:!0,onlyInViewport:!0}),i(e,"on",{activeIndexChange:function(){var e=this.slides[this.activeIndex],t=r(e).find("video").get(0);t&&t.play()}}),e))})),r(this).find(".zoom-instagram-link").magnificPopup({items:{type:"inline",src:r(this).parent().parent().find(".wpz-insta-lightbox-wrapper")},closeBtnInside:!1,mainClass:"wpzoom-lightbox",midClick:!0,callbacks:{open:function(){var e=r.magnificPopup.instance.st.el,t=this.content.find("> .swiper").get(0).swiper;this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"] video')&&this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"] video').trigger("play"),"object"===n(t)&&t.slideTo(this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"]').index())}}}),r(this).find(".zoom-instagram-link").addClass("magnific-active")}}))},r(window).on("load",window.wpzInstaFrontendInit)}}); -
instagram-widget-by-wpzoom/trunk/dist/scripts/frontend/index.asset.php
r3201122 r3216107 1 <?php return array('dependencies' => array('wp-polyfill'), 'version' => ' 81c01956ef058606671387aee77c0f95');1 <?php return array('dependencies' => array('wp-polyfill'), 'version' => 'fe65371fffa4a50658da40646b999487'); -
instagram-widget-by-wpzoom/trunk/dist/scripts/frontend/index.js
r2861996 r3216107 1 !function( t){var e={};function i(n){if(e[n])return e[n].exports;var a=e[n]={i:n,l:!1,exports:{}};return t[n].call(a.exports,a,a.exports,i),a.l=!0,a.exports}i.m=t,i.c=e,i.d=function(t,e,n){i.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},i.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},i.t=function(t,e){if(1&e&&(t=i(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(i.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var a in t)i.d(n,a,function(e){return t[e]}.bind(null,a));return n},i.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return i.d(e,"a",e),e},i.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},i.p="",i(i.s=11)}({11:function(t,e){function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function n(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}var a;(a=jQuery)(window).on("load",(function(){var t=!1;function e(){t||(t=!0,(window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(t){window.setTimeout(t,1e3/60)})(o))}function o(){a(".zoom-instagram-widget__items").zoomInstagramWidget(),t=!1}a.fn.zoomLoadAsyncImages=function(){return a(this).each((function(){var t=a(this),e=t.data("image-width"),i=t.data("image-resolution"),n=t.find("li").filter((function(){return a(this).data("media-id")})).map((function(){return{"media-id":a(this).attr("data-media-id"),nonce:a(this).attr("data-nonce"),"regenerate-thumbnails":a(this)[0].hasAttribute("data-regenerate-thumbnails")}}));n.length&&function n(a){if(0!=a.length){var o=a.shift();wp.ajax.post("wpzoom_instagram_get_image_async",{"media-id":o["media-id"],nonce:o.nonce,"image-resolution":i,"image-width":e,"regenerate-thumbnails":o["regenerate-thumbnails"]}).done((function(e){t.find('li[data-media-id="'+o["media-id"]+'"] .zoom-instagram-link').css("background-image","url("+e.image_src+")")})).fail((function(){})).always((function(){n(a)}))}}(n.toArray())}))},a.fn.zoomLightbox=function(){return a(this).each((function(){var t=a(this).closest(".widget").find(".wpz-insta-lightbox-wrapper > .swiper");if(t.length>0){var e,o=t.find(".image-wrapper > .swiper");new Swiper(t.get(0),(n(e={lazy:{threshold:50},watchSlidesVisibility:!0,preloadImages:!1},"lazy",!0),n(e,"direction","horizontal"),n(e,"loop",!1),n(e,"spaceBetween",20),n(e,"autoHeight",!1),n(e,"watchOverflow",!0),n(e,"navigation",{nextEl:t.find("> .swiper-button-next").get(0),prevEl:t.find("> .swiper-button-prev").get(0)}),n(e,"keyboard",{enabled:!0,onlyInViewport:!0}),e)),o.each((function(){var t;new Swiper(a(this).get(0),(n(t={lazy:{threshold:50},watchSlidesVisibility:!0,preloadImages:!1},"lazy",!0),n(t,"direction","horizontal"),n(t,"loop",!1),n(t,"spaceBetween",20),n(t,"nested",!0),n(t,"watchOverflow",!0),n(t,"pagination",{el:a(this).find("> .swiper-pagination").get(0),type:"bullets",clickable:!0,hideOnClick:!1}),n(t,"navigation",{nextEl:a(this).find("> .swiper-button-next").get(0),prevEl:a(this).find("> .swiper-button-prev").get(0)}),n(t,"keyboard",{enabled:!0,onlyInViewport:!0}),t))})),a(this).find(".zoom-instagram-link").magnificPopup({items:{type:"inline",src:a(this).closest(".widget").find(".wpz-insta-lightbox-wrapper")},closeBtnInside:!1,mainClass:"wpzoom-lightbox",midClick:!0,callbacks:{open:function(){var t=a.magnificPopup.instance.st.el,e=this.content.find("> .swiper").get(0).swiper;this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+t.data("mfp-src")+'"] video')&&this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+t.data("mfp-src")+'"] video').trigger("play"),"object"===i(e)&&e.slideTo(this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+t.data("mfp-src")+'"]').index())}}}),a(this).find(".zoom-instagram-link").addClass("magnific-active")}}))},a.fn.zoomInstagramWidget=function(){return a(this).each((function(){var t,e,i=a(this),n=i.data("images-per-row"),o=i.data("image-width"),r=i.data("image-spacing"),s=(i.data("image-lazy-loading"),i.width());s/o<n?(t=n,e=Math.floor((s-1-(n-1)*r)/n)):(t=Math.floor((s-1)/o),e=Math.floor((s-1-(t-1)*r)/t)),i.find("li").each((function(e){var i=++e;i%t==1?a(this).css("clear","left"):a(this).css("clear","none"),i%t==0?a(this).css("margin-right","0"):(a(this).css("margin-right",r+"px"),a(this).css("margin-bottom",r+"px"))})),i.find("a.zoom-instagram-link").css({width:e,height:e}),i.find("a.zoom-instagram-link-old").lazy(),i.find(".zoom-instagram-link-new").lazy(),i.removeClass("zoom-instagram-widget__items--no-js")}))},a(window).on("resize orientationchange",e),e(),a(".zoom-instagram-widget__items").zoomLoadAsyncImages(),a('.zoom-instagram-widget__items[data-lightbox="1"]').zoomLightbox();var r=_.debounce((function(){a(".zoom-instagram-widget__items").length&&(a(".zoom-instagram-widget__items").zoomInstagramWidget(),a(".zoom-instagram-widget__items").zoomLoadAsyncImages())}),1500);a(document).on("panels_setup_preview",r)}))}});1 !function(e){var t={};function i(n){if(t[n])return t[n].exports;var a=t[n]={i:n,l:!1,exports:{}};return e[n].call(a.exports,a,a.exports,i),a.l=!0,a.exports}i.m=e,i.c=t,i.d=function(e,t,n){i.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(e,t){if(1&t&&(e=i(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(i.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)i.d(n,a,function(t){return e[t]}.bind(null,a));return n},i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,"a",t),t},i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},i.p="",i(i.s=11)}({11:function(e,t){function i(e){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function n(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var a;(a=jQuery)(window).on("load",(function(){var e=!1;function t(){e||(e=!0,(window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(e){window.setTimeout(e,1e3/60)})(o))}function o(){a(".zoom-instagram-widget__items").zoomInstagramWidget(),e=!1}a.fn.zoomLoadAsyncImages=function(){return a(this).each((function(){var e=a(this),t=e.data("image-width"),i=e.data("image-resolution"),n=e.find("li").filter((function(){return a(this).data("media-id")})).map((function(){return{"media-id":a(this).attr("data-media-id"),nonce:a(this).attr("data-nonce"),"regenerate-thumbnails":a(this)[0].hasAttribute("data-regenerate-thumbnails")}}));n.length&&function n(a){if(0!=a.length){var o=a.shift();wp.ajax.post("wpzoom_instagram_get_image_async",{"media-id":o["media-id"],nonce:o.nonce,"image-resolution":i,"image-width":t,"regenerate-thumbnails":o["regenerate-thumbnails"]}).done((function(t){e.find('li[data-media-id="'+o["media-id"]+'"] .zoom-instagram-link').css("background-image","url("+t.image_src+")")})).fail((function(){})).always((function(){n(a)}))}}(n.toArray())}))},a.fn.zoomLightbox=function(){return a(this).each((function(){var e=a(this).closest(".widget").find(".wpz-insta-lightbox-wrapper > .swiper");if(e.length>0){var t,o=e.find(".image-wrapper > .swiper");new Swiper(e.get(0),(n(t={lazy:{threshold:50},watchSlidesVisibility:!0,preloadImages:!1},"lazy",!0),n(t,"direction","horizontal"),n(t,"loop",!1),n(t,"spaceBetween",20),n(t,"autoHeight",!1),n(t,"watchOverflow",!0),n(t,"navigation",{nextEl:e.find("> .swiper-button-next").get(0),prevEl:e.find("> .swiper-button-prev").get(0)}),n(t,"keyboard",{enabled:!0,onlyInViewport:!0}),n(t,"on",{activeIndexChange:function(){var e=this.slides[this.activeIndex],t=a(e).find("video").get(0);t&&t.play()}}),t)),o.each((function(){var e;new Swiper(a(this).get(0),(n(e={lazy:{threshold:50},watchSlidesVisibility:!0,preloadImages:!1},"lazy",!0),n(e,"direction","horizontal"),n(e,"loop",!1),n(e,"spaceBetween",20),n(e,"nested",!0),n(e,"watchOverflow",!0),n(e,"pagination",{el:a(this).find("> .swiper-pagination").get(0),type:"bullets",clickable:!0,hideOnClick:!1}),n(e,"navigation",{nextEl:a(this).find("> .swiper-button-next").get(0),prevEl:a(this).find("> .swiper-button-prev").get(0)}),n(e,"keyboard",{enabled:!0,onlyInViewport:!0}),n(e,"on",{activeIndexChange:function(){var e=this.slides[this.activeIndex],t=a(e).find("video").get(0);t&&t.play()}}),e))})),a(this).find(".zoom-instagram-link").magnificPopup({items:{type:"inline",src:a(this).closest(".widget").find(".wpz-insta-lightbox-wrapper")},closeBtnInside:!1,mainClass:"wpzoom-lightbox",midClick:!0,callbacks:{open:function(){var e=a.magnificPopup.instance.st.el,t=this.content.find("> .swiper").get(0).swiper;this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"] video')&&this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"] video').trigger("play"),"object"===i(t)&&t.slideTo(this.content.find('> .swiper > .swiper-wrapper > .swiper-slide[data-uid="'+e.data("mfp-src")+'"]').index())}}}),a(this).find(".zoom-instagram-link").addClass("magnific-active")}}))},a.fn.zoomInstagramWidget=function(){return a(this).each((function(){var e,t,i=a(this),n=i.data("images-per-row"),o=i.data("image-width"),r=i.data("image-spacing"),s=(i.data("image-lazy-loading"),i.width());s/o<n?(e=n,t=Math.floor((s-1-(n-1)*r)/n)):(e=Math.floor((s-1)/o),t=Math.floor((s-1-(e-1)*r)/e)),i.find("li").each((function(t){var i=++t;i%e==1?a(this).css("clear","left"):a(this).css("clear","none"),i%e==0?a(this).css("margin-right","0"):(a(this).css("margin-right",r+"px"),a(this).css("margin-bottom",r+"px"))})),i.find("a.zoom-instagram-link").css({width:t,height:t}),i.find("a.zoom-instagram-link-old").lazy(),i.find(".zoom-instagram-link-new").lazy(),i.removeClass("zoom-instagram-widget__items--no-js")}))},a(window).on("resize orientationchange",t),t(),a(".zoom-instagram-widget__items").zoomLoadAsyncImages(),a('.zoom-instagram-widget__items[data-lightbox="1"]').zoomLightbox();var r=_.debounce((function(){a(".zoom-instagram-widget__items").length&&(a(".zoom-instagram-widget__items").zoomInstagramWidget(),a(".zoom-instagram-widget__items").zoomLoadAsyncImages())}),1500);a(document).on("panels_setup_preview",r)}))}}); -
instagram-widget-by-wpzoom/trunk/instagram-widget-by-wpzoom.php
r3201122 r3216107 4 4 * Plugin URI: https://www.wpzoom.com/plugins/instagram-widget/ 5 5 * Description: Instagram Widget is a customizable and responsive plugin, made to help you gain even more followers by showcasing your Instagram feed on your WordPress website. 6 * Version: 2.2. 16 * Version: 2.2.2 7 7 * Author: WPZOOM 8 8 * Author URI: https://www.wpzoom.com/ -
instagram-widget-by-wpzoom/trunk/readme.txt
r3201122 r3216107 6 6 Tested up to: 6.7 7 7 Requires PHP: 7.4 8 Stable tag: 2.2. 18 Stable tag: 2.2.2 9 9 License: GPLv2 or later 10 10 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 102 102 == Changelog == 103 103 104 = 2.2.2 = 105 * Bug fix with emojis in bio and name 106 104 107 = 2.2.1 = 105 108 * Multiple improvements -
instagram-widget-by-wpzoom/trunk/src/scripts/frontend/block.js
r2861996 r3216107 7 7 const $nested = $swipe_el.find( '.image-wrapper > .swiper' ); 8 8 9 new Swiper( $swipe_el.get(0), {9 const swiper = new Swiper( $swipe_el.get(0), { 10 10 lazy:{ 11 11 threshold: 50 … … 26 26 enabled: true, 27 27 onlyInViewport: true 28 } 28 }, 29 on: { 30 activeIndexChange: function () { 31 32 // Get the active slide 33 const activeSlide = this.slides[this.activeIndex]; 34 const $activeSlide = $(activeSlide); 35 36 // Play the video in the active slide if it exists 37 const video = $activeSlide.find('video').get(0); 38 if (video) { 39 video.play(); 40 } 41 42 }, 43 }, 29 44 } ); 30 45 … … 55 70 enabled: true, 56 71 onlyInViewport: true 57 } 72 }, 73 on: { 74 activeIndexChange: function () { 75 76 // Get the active slide 77 const activeSlide = this.slides[this.activeIndex]; 78 const $activeSlide = $(activeSlide); 79 80 // Play the video in the active slide if it exists 81 const video = $activeSlide.find('video').get(0); 82 if (video) { 83 video.play(); 84 } 85 86 }, 87 }, 58 88 } ); 59 89 } ); … … 71 101 const magnificPopup = $.magnificPopup.instance, 72 102 currentElement = magnificPopup.st.el, 73 $thisSwiper = this.content.find( '> .swiper' ).get(0).swiper; 103 $thisSwiper = this.content.find( '> .swiper' ).get(0).swiper; 104 74 105 if( this.content.find( '> .swiper > .swiper-wrapper > .swiper-slide[data-uid="' + currentElement.data( 'mfp-src' ) + '"] video' ) ) { 75 106 this.content.find( '> .swiper > .swiper-wrapper > .swiper-slide[data-uid="' + currentElement.data( 'mfp-src' ) + '"] video' ).trigger('play'); 76 107 } 77 78 //console.log( typeof $thisSwiper );79 80 108 if ( typeof $thisSwiper === 'object' ) { 81 109 $thisSwiper.slideTo( -
instagram-widget-by-wpzoom/trunk/src/scripts/frontend/index.js
r2861996 r3216107 57 57 const $nested = $swipe_el.find( '.image-wrapper > .swiper' ); 58 58 59 new Swiper( $swipe_el.get(0), {59 const swiper = new Swiper( $swipe_el.get(0), { 60 60 lazy:{ 61 61 threshold: 50 … … 76 76 enabled: true, 77 77 onlyInViewport: true 78 } 78 }, 79 on: { 80 activeIndexChange: function () { 81 82 // Get the active slide 83 const activeSlide = this.slides[this.activeIndex]; 84 const $activeSlide = $(activeSlide); 85 86 // Play the video in the active slide if it exists 87 const video = $activeSlide.find('video').get(0); 88 if (video) { 89 video.play(); 90 } 91 92 }, 93 }, 79 94 } ); 80 95 … … 105 120 enabled: true, 106 121 onlyInViewport: true 107 } 122 }, 123 on: { 124 activeIndexChange: function () { 125 126 // Get the active slide 127 const activeSlide = this.slides[this.activeIndex]; 128 const $activeSlide = $(activeSlide); 129 130 // Play the video in the active slide if it exists 131 const video = $activeSlide.find('video').get(0); 132 if (video) { 133 video.play(); 134 } 135 136 }, 137 }, 108 138 } ); 109 139 } );
Note: See TracChangeset
for help on using the changeset viewer.