Instagram Gallery - Version 3.1.9

Version Description

  • Fix. Instagram account feed video
  • Fix. firefox masonry
Download this release

Release Info

Developer quadlayers
Plugin Icon 128x128 Instagram Gallery
Version 3.1.9
Comparing to
See all releases

Code changes from version 3.1.8 to 3.1.9

assets/backend/js/gutenberg.asset.php CHANGED
@@ -1 +1 @@
1
- <?php return array('dependencies' => array('jquery', 'lodash', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-element', 'wp-i18n', 'wp-server-side-render'), 'version' => '3bdce00921bbe84275a8849043007c0b');
1
+ <?php return array('dependencies' => array('jquery', 'lodash', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-element', 'wp-i18n', 'wp-server-side-render'), 'version' => '01479331855c6348a038fb7b2544f7df');
assets/backend/js/gutenberg.js CHANGED
@@ -1,6 +1,6 @@
1
- !function(e){var t={};function a(n){if(t[n])return t[n].exports;var l=t[n]={i:n,l:!1,exports:{}};return e[n].call(l.exports,l,l.exports,a),l.l=!0,l.exports}a.m=e,a.c=t,a.d=function(e,t,n){a.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},a.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},a.t=function(e,t){if(1&t&&(e=a(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(a.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var l in e)a.d(n,l,function(t){return e[t]}.bind(null,l));return n},a.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return a.d(t,"a",t),t},a.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},a.p="",a(a.s=24)}([function(e,t){!function(){e.exports=this.wp.i18n}()},function(e,t){!function(){e.exports=this.wp.element}()},function(e,t){!function(){e.exports=this.wp.components}()},function(e,t){e.exports=function(e,t,a){return t in e?Object.defineProperty(e,t,{value:a,enumerable:!0,configurable:!0,writable:!0}):e[t]=a,e}},function(e,t){!function(){e.exports=this.jQuery}()},function(e,t){!function(){e.exports=this.wp.blockEditor}()},function(e,t){!function(){e.exports=this.lodash}()},function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}},function(e,t){function a(t){return e.exports=a=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},a(t)}e.exports=a},function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}},function(e,t){function a(e,t){for(var a=0;a<t.length;a++){var n=t[a];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}e.exports=function(e,t,n){return t&&a(e.prototype,t),n&&a(e,n),e}},function(e,t,a){var n=a(17);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&n(e,t)}},function(e,t,a){var n=a(18),l=a(7);e.exports=function(e,t){return!t||"object"!==n(t)&&"function"!=typeof t?l(e):t}},function(e,t){!function(){e.exports=this.wp.serverSideRender}()},function(e,t,a){var n=a(19),l=a(20),r=a(21),o=a(23);e.exports=function(e,t){return n(e)||l(e,t)||r(e,t)||o()}},function(e,t,a){var n;
2
- /*!
3
- Copyright (c) 2017 Jed Watson.
4
- Licensed under the MIT License (MIT), see
5
- http://jedwatson.github.io/classnames
6
- */!function(){"use strict";var a={}.hasOwnProperty;function l(){for(var e=[],t=0;t<arguments.length;t++){var n=arguments[t];if(n){var r=typeof n;if("string"===r||"number"===r)e.push(n);else if(Array.isArray(n)&&n.length){var o=l.apply(null,n);o&&e.push(o)}else if("object"===r)for(var i in n)a.call(n,i)&&n[i]&&e.push(i)}}return e.join(" ")}e.exports?(l.default=l,e.exports=l):void 0===(n=function(){return l}.apply(t,[]))||(e.exports=n)}()},function(e,t){!function(){e.exports=this.wp.blocks}()},function(e,t){function a(t,n){return e.exports=a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},a(t,n)}e.exports=a},function(e,t){function a(t){return"function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?e.exports=a=function(e){return typeof e}:e.exports=a=function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},a(t)}e.exports=a},function(e,t){e.exports=function(e){if(Array.isArray(e))return e}},function(e,t){e.exports=function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var a=[],n=!0,l=!1,r=void 0;try{for(var o,i=e[Symbol.iterator]();!(n=(o=i.next()).done)&&(a.push(o.value),!t||a.length!==t);n=!0);}catch(e){l=!0,r=e}finally{try{n||null==i.return||i.return()}finally{if(l)throw r}}return a}}},function(e,t,a){var n=a(22);e.exports=function(e,t){if(e){if("string"==typeof e)return n(e,t);var a=Object.prototype.toString.call(e).slice(8,-1);return"Object"===a&&e.constructor&&(a=e.constructor.name),"Map"===a||"Set"===a?Array.from(e):"Arguments"===a||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a)?n(e,t):void 0}}},function(e,t){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var a=0,n=new Array(t);a<t;a++)n[a]=e[a];return n}},function(e,t){e.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}},function(e,t,a){"use strict";a.r(t);a(25);var n=a(9),l=a.n(n),r=a(10),o=a.n(r),i=a(7),c=a.n(i),s=a(11),u=a.n(s),g=a(12),p=a.n(g),b=a(8),d=a.n(b),m=a(1),f=a(6),y=a(4),_=a.n(y),h=a(13),O=a.n(h),j=a(0),v=a(2),C=a(3),x=a.n(C),k=a(14),E=a.n(k),w=a(15),P=a.n(w),I=a(5);function q(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,n)}return a}function T(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?q(Object(a),!0).forEach((function(t){x()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):q(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var B=function(e){var t=e.attributes,a=e.setAttributes,n=Object(m.useState)({name:!0,biography:!0,picture:!0}),l=E()(n,2),r=l[0],o=l[1],i=qligg_gutenberg.image_url,c=qligg_gutenberg.accounts;return Object(m.createElement)(I.InspectorControls,{key:"inspector"},Object(m.createElement)(v.PanelBody,{initialOpen:!0,title:Object(j.__)("General","insta-gallery")},Object(m.createElement)(v.SelectControl,{label:Object(j.__)("Account","insta-gallery"),help:Object(j.__)("Please select Instagram account","insta-gallery"),value:t.username,onChange:function(e){return a({username:e})},options:Object(f.map)(c,(function(e,t){return{value:e.id,label:Object(j.__)(e.name,"insta-gallery")}}))}),Object(m.createElement)(v.SelectControl,{label:Object(j.__)("Feed","insta-gallery"),value:t.type,onChange:function(e){return a({type:e})},options:[{value:"tag",label:Object(j.__)("Tag","insta-gallery")},{value:"username",label:Object(j.__)("Username","insta-gallery")}]}),"tag"==t.type&&Object(m.createElement)(m.Fragment,null,Object(m.createElement)(v.TextControl,{label:Object(j.__)("Tag","insta-gallery"),help:Object(j.__)("Please enter Instagram tag","insta-gallery"),value:t.tag,onChange:function(e){return a({tag:e})}}),Object(m.createElement)(v.SelectControl,{label:Object(j.__)("Order by","insta-gallery"),help:Object(j.__)("Please enter Instagram tag order","insta-gallery"),value:t.order_by,onChange:function(e){return a({order_by:e})},options:[{value:"recend_media",label:Object(j.__)("Recent (Within 24 hours)","insta-gallery")},{value:"top_media",label:Object(j.__)("Top (Most popular first)","insta-gallery")}]})),Object(m.createElement)(m.Fragment,null,Object(m.createElement)("ul",{className:"qligg-list-videos"},Object(f.map)(["carousel","gallery","masonry","highlight"],(function(e,n){return Object(m.createElement)("li",{className:P()("qligg-modal-image",t.layout==e&&"active","carousel"!==e&&"gallery"!==e&&"qligg-premium-field"),onClick:function(){return a({layout:e})}},Object(m.createElement)("span",null,e.replace("-"," ")),Object(m.createElement)("img",{src:"".concat(i,"/").concat(e,".png")}))})))),Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Limit","insta-gallery"),help:Object(j.__)("Number of videos to display","insta-gallery"),value:t.limit,onChange:function(e){a({limit:e})},min:1,max:33}),"carousel"!=t.layout&&Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Columns","insta-gallery"),help:Object(j.__)("Number of videos in a row","insta-gallery"),value:t.columns,onChange:function(e){return a({columns:e})},min:1,max:20}),"highlight"==t.layout&&Object(m.createElement)(m.Fragment,null,Object(m.createElement)(v.TextControl,{label:Object(j.__)(" highlight by tag","insta-gallery"),help:Object(j.__)("highlightfeeds items with this tags","insta-gallery"),value:t.highlight.tag,onChange:function(e){return a({highlight:T(T({},t.highlight),{},x()({},"tag",e))})}}),Object(m.createElement)(v.TextControl,{label:Object(j.__)(" highlight by id","insta-gallery"),help:Object(j.__)(" highlight by id","insta-gallery"),value:t.highlight.id,onChange:function(e){return a({highlight:T(T({},t.highlight),{},x()({},"id",e))})}}),Object(m.createElement)(v.TextControl,{label:Object(j.__)(" highlight by position","insta-gallery"),help:Object(j.__)("highlightfeeds items in this positions","insta-gallery"),value:t.highlight.position,onChange:function(e){return a({highlight:T(T({},t.highlight),{},x()({},"position",e))})}}))),"carousel"==t.layout&&Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Carousel","insta-gallery")},Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Slides per view","insta-gallery"),help:Object(j.__)("Number of images per slide","insta-gallery"),value:t.carousel.slidespv,onChange:function(e){return a({carousel:T(T({},t.carousel),{},x()({},"slidespv",e))})},min:1,max:100}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Autoplay","insta-gallery"),help:Object(j.__)("Autoplay carousel items","insta-gallery"),checked:!!t.carousel.autoplay,onChange:function(e){return a({carousel:T(T({},t.carousel),{},x()({},"autoplay",e))})}}),t.carousel.autoplay&&Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Autoplay Interval","insta-gallery"),help:Object(j.__)("Moves to next picture after specified time interval","insta-gallery"),value:t.carousel.autoplay_interval,onChange:function(e){return a({carousel:T(T({},t.carousel),{},x()({},"autoplay_interval",e))})},min:1,max:1e4}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Navigation","insta-gallery"),help:Object(j.__)("Display navigation arrows","insta-gallery"),checked:!!t.carousel.navarrows,onChange:function(e){return a({carousel:T(T({},t.carousel),{},x()({},"navarrows",e))})}}),t.carousel.navarrows&&Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Navigation color","insta-gallery"),help:Object(j.__)("Change navigation arrows color","insta-gallery")},Object(m.createElement)(I.ColorPalette,{value:t.carousel.navarrows_color,onChange:function(e){return a({carousel:T(T({},t.carousel),{},x()({},"navarrows_color",e))})}})),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Pagination","insta-gallery"),help:Object(j.__)("Display pagination dots","insta-gallery"),checked:!!t.carousel.pagination,onChange:function(e){return a({carousel:T(T({},t.carousel),{},x()({},"pagination",e))})}}),t.carousel.pagination&&Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Pagination color","insta-gallery"),help:Object(j.__)("Change pagination dots color","insta-gallery")},Object(m.createElement)(I.ColorPalette,{value:t.carousel.pagination_color,onChange:function(e){return a({carousel:T(T({},t.carousel),{},x()({},"pagination_color",e))})}}))),Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Profile","insta-gallery")},Object(m.createElement)(v.TextControl,{label:Object(j.__)("Full name","insta-gallery"),help:Object(j.__)("Feed profile full name","insta-gallery"),value:!t.profile.name&&r.name&&c[t.username].name||t.profile.name,onChange:function(e){o(T(T({},r),{},x()({},"name",!1))),a({profile:T(T({},t.profile),{},x()({},"name",e))})}}),Object(m.createElement)(v.TextareaControl,{label:Object(j.__)("Biography","insta-gallery"),help:Object(j.__)("Feed profile biography","insta-gallery"),value:!t.profile.biography&&r.biography&&c[t.username].biography||t.profile.biography,onChange:function(e){o(T(T({},r),{},x()({},"biography",!1))),a({profile:T(T({},t.profile),{},x()({},"biography",e))})}}),Object(m.createElement)(m.Fragment,null,Object(m.createElement)("img",{style:{objectFit:"cover",width:"230px",height:"230px"},src:!t.profile.profile_picture_url&&r.picture&&c[t.username].profile_picture_url||t.profile.profile_picture_url}),Object(m.createElement)(I.MediaUpload,{onSelect:function(e){o(T(T({},r),{},x()({},"picture",!1))),a({profile:T(T({},t.profile),{},x()({},"profile_picture_url",e.url))})},allowedTypes:["image"],value:t.profile.profile_picture_url,render:function(e){var t=e.open;return Object(m.createElement)(v.Button,{onClick:t},Object(j.__)("Upload","insta-gallery"))}}))),Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Box","insta-gallery")},Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Box","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Display the Instagram Feed inside a customizable box","insta-gallery"),checked:!!t.box.display,onChange:function(e){return a({box:T(T({},t.box),{},x()({},"display",e))})}}),t.box.display&&Object(m.createElement)(m.Fragment,null,Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Box padding","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Add padding to the Instagram Feed","insta-gallery"),value:t.box.padding,onChange:function(e){return a({box:T(T({},t.box),{},x()({},"padding",e))})},min:1,max:100}),Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Border Radius","insta-gallery"),help:Object(j.__)("Add radius to the Instagram Feed","insta-gallery"),className:"qligg-premium-field",value:t.box.radius,onChange:function(e){return a({box:T(T({},t.box),{},x()({},"radius",e))})},min:0,max:100}),Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Box background","insta-gallery"),help:Object(j.__)("Color which is displayed on box background","insta-gallery"),className:"qligg-premium-field"},Object(m.createElement)(I.ColorPalette,{value:t.box.background,onChange:function(e){return a({box:T(T({},t.box),{},x()({},"background",e))})}})),Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Box text color","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Color which is displayed on box text","insta-gallery")},Object(m.createElement)(I.ColorPalette,{value:t.box.color_text,onChange:function(e){return a({box:T(T({},t.box),{},x()({},"color_text",e))})}})),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Profile","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Display user profile or tag info","insta-gallery"),checked:!!t.box.profile,onChange:function(e){return a({box:T(T({},t.box),{},x()({},"profile",e))})}}))),Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Image","insta-gallery")},Object(m.createElement)(v.SelectControl,{label:Object(j.__)("Account","insta-gallery"),value:t.resolution,onChange:function(e){return a({resolution:e})},options:[{value:"madium",label:Object(j.__)("Medium (320 x auto)","insta-gallery")},{value:"small",label:Object(j.__)("Small (150 x 150)","insta-gallery")}]}),Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Images spacing","insta-gallery"),help:Object(j.__)("Add blank space between images","insta-gallery"),value:t.spacing,onChange:function(e){return a({spacing:e})},min:0,max:100}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images lazy load","insta-gallery"),help:Object(j.__)("Defers feed images loading","insta-gallery"),checked:!!t.lazy,onChange:function(e){return a({lazy:e})}})),Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Image card","insta-gallery")},Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images card","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Display card gallery by clicking on image","insta-gallery"),checked:!!t.card.display,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"display",e))})}}),t.card.display&&Object(m.createElement)(m.Fragment,null,Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Card radius","insta-gallery"),help:Object(j.__)("Add radius to the Instagram Feed","insta-gallery"),className:"qligg-premium-field",value:t.card.radius,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"radius",e))})},min:0,max:100}),Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Card font size","insta-gallery"),help:Object(j.__)("Add font-size to the Instagram Feed","insta-gallery"),className:"qligg-premium-field",value:t.card.font_size,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"font_size",e))})},min:0,max:100}),Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Card background","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Color which is displayed when over images","insta-gallery")},Object(m.createElement)(I.ColorPalette,{value:t.card.background,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"background",e))})}})),Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Card text color","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Color Text","insta-gallery")},Object(m.createElement)(I.ColorPalette,{value:t.card.text_color,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"text_color",e))})}})),Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Card padding","insta-gallery"),help:Object(j.__)("Add blank space between images","insta-gallery"),className:"qligg-premium-field",value:t.card.padding,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"padding",e))})},min:0,max:100}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Card info","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Display likes count of images","insta-gallery"),checked:!!t.card.info,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"info",e))})}}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Card caption","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Display caption count of images","insta-gallery"),checked:!!t.card.caption,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"caption",e))})}}),Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Card length","insta-gallery"),help:Object(j.__)("Add blank space between images","insta-gallery"),className:"qligg-premium-field",value:t.card.length,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"length",e))})},min:0,max:100}))),Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Image mask","insta-gallery")},Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images mask","insta-gallery"),help:Object(j.__)("Image mouseover effect","insta-gallery"),checked:!!t.mask.display,onChange:function(e){return a({mask:T(T({},t.mask),{},x()({},"display",e))})}}),t.mask.display&&Object(m.createElement)(m.Fragment,null,Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Images mask color","insta-gallery"),help:Object(j.__)("Image mask background color","insta-gallery")},Object(m.createElement)(I.ColorPalette,{value:t.mask.background,onChange:function(e){return a({mask:T(T({},t.mask),{},x()({},"background",e))})}})),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images mask likes","insta-gallery"),help:Object(j.__)("Display likes count of images","insta-gallery"),checked:!!t.mask.likes,onChange:function(e){return a({mask:T(T({},t.mask),{},x()({},"likes",e))})}}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images mask comments","insta-gallery"),help:Object(j.__)("Display comments count of images","insta-gallery"),checked:!!t.mask.comments,onChange:function(e){return a({mask:T(T({},t.mask),{},x()({},"comments",e))})}}))),Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Image popup","insta-gallery")},Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images popup","insta-gallery"),help:Object(j.__)("Display popup gallery by clicking on image","insta-gallery"),checked:!!t.popup.display,onChange:function(e){return a({popup:T(T({},t.popup),{},x()({},"display",e))})}}),t.popup.display&&Object(m.createElement)(m.Fragment,null,Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images popup profile","insta-gallery"),help:Object(j.__)("Display user profile or tag info","insta-gallery"),className:"qligg-premium-field",checked:!!t.popup.profile,onChange:function(e){return a({popup:T(T({},t.popup),{},x()({},"profile",e))})}}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images popup caption","insta-gallery"),help:Object(j.__)("Display caption in the popup","insta-gallery"),className:"qligg-premium-field",checked:!!t.popup.caption,onChange:function(e){return a({popup:T(T({},t.popup),{},x()({},"caption",e))})}}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images popup likes","insta-gallery"),help:Object(j.__)("Display likes count of images","insta-gallery"),className:"qligg-premium-field",checked:!!t.popup.likes,onChange:function(e){return a({popup:T(T({},t.popup),{},x()({},"likes",e))})}}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images popup comments","insta-gallery"),help:Object(j.__)("Display comments count of images","insta-gallery"),className:"qligg-premium-field",checked:!!t.popup.comments,onChange:function(e){return a({popup:T(T({},t.popup),{},x()({},"comments",e))})}}),Object(m.createElement)(v.SelectControl,{label:Object(j.__)("Images popup align","insta-gallery"),help:Object(j.__)("Align item description in popup","insta-gallery"),className:"qligg-premium-field",value:t.popup.align,onChange:function(e){return a({popup:T(T({},t.popup),{},x()({},"align",e))})},options:[{value:"left",label:Object(j.__)("Left","insta-gallery")},{value:"right",label:Object(j.__)("Right","insta-gallery")},{value:"bottom",label:Object(j.__)("Bottom","insta-gallery")},{value:"top",label:Object(j.__)("Top","insta-gallery")}]}))),Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Botton","insta-gallery")},Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Instagram button","insta-gallery"),help:Object(j.__)("Display the button to open Instagram site link","insta-gallery"),checked:!!t.button.display,onChange:function(e){return a({button:T(T({},t.button),{},x()({},"display",e))})}}),t.button.display&&Object(m.createElement)(m.Fragment,null,Object(m.createElement)(v.TextControl,{label:Object(j.__)("Instagram button text","insta-gallery"),help:Object(j.__)("Instagram button text here","insta-gallery"),value:t.button.text,onChange:function(e){return a({button:T(T({},t.button),{},x()({},"text",e))})}}),Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Instagram button background","insta-gallery"),help:Object(j.__)("Color which is displayed on button background","insta-gallery")},Object(m.createElement)(I.ColorPalette,{value:t.button.background,onChange:function(e){return a({button:T(T({},t.button),{},x()({},"background",e))})}})),Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Instagram button hover background","insta-gallery"),help:Object(j.__)("Color which is displayed when hovered over button","insta-gallery")},Object(m.createElement)(I.ColorPalette,{value:t.button.background_hover,onChange:function(e){return a({button:T(T({},t.button),{},x()({},"background_hover",e))})}})))),Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Botton load more","insta-gallery")},Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Instagram button","insta-gallery"),help:Object(j.__)("Display the button to open Instagram site link","insta-gallery"),className:"qligg-premium-field",checked:!!t.button_load.display,onChange:function(e){return a({button_load:T(T({},t.button_load),{},x()({},"display",e))})}}),t.button_load.display&&Object(m.createElement)(m.Fragment,null,Object(m.createElement)(v.TextControl,{label:Object(j.__)("Instagram button text","insta-gallery"),help:Object(j.__)("Instagram button text here","insta-gallery"),className:"qligg-premium-field",value:t.button_load.text,onChange:function(e){return a({button_load:T(T({},t.button_load),{},x()({},"text",e))})}}),Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Instagram button background","insta-gallery"),help:Object(j.__)("Color which is displayed on button background","insta-gallery"),className:"qligg-premium-field"},Object(m.createElement)(I.ColorPalette,{value:t.button_load.background,onChange:function(e){return a({button_load:T(T({},t.button_load),{},x()({},"background",e))})}})),Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Instagram button hover background","insta-gallery"),help:Object(j.__)("Color which is displayed when hovered over button","insta-gallery"),className:"qligg-premium-field"},Object(m.createElement)(I.ColorPalette,{value:t.button_load.background_hover,onChange:function(e){return a({button_load:T(T({},t.button_load),{},x()({},"background_hover",e))})}})))))},S=(a(27),0),N={};function D(e,t){var a=_()(".insta-gallery-list",e),n=_()(".insta-gallery-spinner",e),l=e.data("feed");_.a.ajax({url:qligg.ajax_url,type:"post",timeout:3e4,data:{action:"qligg_load_item_images",next_max_id:t,feed:JSON.stringify(l)},beforeSend:function(){n.show()},success:function(e){if(!0!==e.success)return a.append(_()(e.data)),void n.hide();var t=_()(e.data);a.append(t).trigger("qligg.loaded",[t])},complete:function(){},error:function(e,t){n.hide()}})}function A(){_()(".insta-gallery-feed").on("qligg.loaded",(function(e,t){var a=_()(e.delegateTarget),n=_()(".insta-gallery-list",a),l=_()(".insta-gallery-spinner",a),r=_()(".insta-gallery-button.load",a),o=a.data("feed"),i=_()(t).length,c=0;i&&n.find(".insta-gallery-image").on("load loadstart",(function(e){++c>=i&&n.trigger("qligg.imagesLoaded",[t])})),i<o.limit&&(l.hide(),setTimeout((function(){r.fadeOut()}),300))})),_()(".insta-gallery-feed").on("qligg.imagesLoaded",(function(e){var t=_()(e.delegateTarget);_()(".insta-gallery-spinner",t).hide()})),_()(".insta-gallery-feed[data-feed_layout=gallery]").on("qligg.imagesLoaded",(function(e,t){_()(e.delegateTarget).addClass("loaded"),_()(t).each((function(e,t){setTimeout((function(){_()(t).addClass("ig-image-loaded")}),150+30*e)}))})),_()(".insta-gallery-feed[data-feed_layout=carousel]").on("qligg.imagesLoaded",(function(e,t){_()(e.delegateTarget).addClass("loaded"),_()(t).each((function(e,t){_()(t).addClass("ig-image-loaded")}))})),_()(".insta-gallery-feed[data-feed_layout=carousel]").on("qligg.imagesLoaded",(function(e,t){var a=_()(e.delegateTarget),n=_()(".swiper-container",a),l=a.data("feed");l.carousel.slides=l.carousel.slidespv,S++,N[S]=new Swiper(n,{loop:!0,autoHeight:!0,observer:!0,observeParents:!0,slidesPerView:1,spaceBetween:2,autoplay:!!l.carousel.autoplay&&{delay:parseInt(l.carousel.autoplay_interval)},pagination:{el:".swiper-pagination",dynamicBullets:!0,clickable:!0,type:"bullets"},navigation:{nextEl:".swiper-button-next",prevEl:".swiper-button-prev"},breakpoints:{320:{slidesPerView:1,spaceBetween:1},480:{spaceBetween:parseInt(l.spacing),slidesPerView:Math.min(2,parseInt(l.carousel.slides))},768:{spaceBetween:parseInt(l.spacing),slidesPerView:Math.min(3,parseInt(l.carousel.slides))},1024:{spaceBetween:parseInt(l.spacing),slidesPerView:parseInt(l.carousel.slides)}}})})),_()(".insta-gallery-feed[data-feed_layout=masonry]").on("qligg.imagesLoaded",(function(e,t){var a=_()(e.delegateTarget),n=_()(".insta-gallery-list",a);n.data("masonry")?n.masonry("appended",t,!1):n.masonry({itemSelector:".insta-gallery-item",isResizable:!0,isAnimated:!1,transitionDuration:0,percentPosition:!0,columnWidth:".insta-gallery-item:last-child"})})),_()(".insta-gallery-feed[data-feed_layout=masonry]").on("layoutComplete",(function(e,t){_()(e.delegateTarget).addClass("loaded"),_()(t).each((function(e,t){_()(t.element).addClass("ig-image-loaded")}))})),_()(".insta-gallery-feed").on("qligg.loaded",(function(e){var t=_()(e.delegateTarget),a=_()(".insta-gallery-list",t),n=t.data("feed");_()(".insta-gallery-item .insta-gallery-icon.qligg-icon-instagram",a).on("click",(function(e){e.stopPropagation()})),n.popup.display&&_()(".insta-gallery-item",a).magnificPopup({type:"inline",callbacks:{beforeOpen:function(){this.st.mainClass=this.st.mainClass+" qligg-mfp-wrap"},elementParse:function(e){var t,l="",r="",o="",i="",c="",s="",u="";l=!e.el.data("item").type||"video"!=e.el.data("item").type&&"video"!=e.el.data("item").file_type?'<img src="'+e.el.data("item").images.standard+'"/>':'\n <video autoplay>\n <source src="'+e.el.data("item").videos.standard+'" type="video/mp4">\n </video>',t='<div class="mfp-icons"><div class="mfp-counter">'+(e.index+1)+" / "+_()(".insta-gallery-item",a).length+'</div><a class="mfp-link" href="'+e.el.data("item").link+'" target="_blank" rel="noopener"><i class="qligg-icon-instagram"></i>Instagram</a></div>',n.popup.profile&&(r='<div class="mfp-user"><img src="'+n.profile.profile_picture_url+'"><a href="https://www.instagram.com/'+n.profile.username+'" title="'+n.profile.name+'" target="_blank" rel="noopener">'+n.profile.username+"</a></div>"),n.popup.caption&&(o='<div class="mfp-caption">'+e.el.data("item").caption+"</div>"),e.el.data("item").date&&(s='<div class="mfp-date">'+e.el.data("item").date+"</div>"),e.el.data("item").comments&&n.popup.comments&&(u='<div class="mfp-comments"><i class="qligg-icon-comment"></i>'+e.el.data("item").comments+"</div>"),e.el.data("item").likes&&n.popup.likes&&(c='<div class="mfp-likes"><i class="qligg-icon-heart"></i>'+e.el.data("item").likes+"</div>"),(n.popup.likes||n.popup.comments)&&(i='<div class="mfp-info">'+c+u+s+"</div>"),e.src='<div class="mfp-figure '+n.popup.align+'">'+l+'<div class="mfp-close"></div><div class="mfp-bottom-bar"><div class="mfp-title">'+r+t+o+i+"</div></div></div>"}},gallery:{enabled:!0}})})),_()(".insta-gallery-feed").on("click",".insta-gallery-button.load",(function(e){e.preventDefault();var t=_()(e.delegateTarget);if(!t.hasClass("loaded"))return!1;D(t,_()(".insta-gallery-list .insta-gallery-item:last-child",t).data("item").i)})),_()(".insta-gallery-feed").each((function(e,t){var a=_()(t);if(a.hasClass("loaded"))return!1;D(a,0)}))}function F(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,n=d()(e);if(t){var l=d()(this).constructor;a=Reflect.construct(n,arguments,l)}else a=n.apply(this,arguments);return p()(this,a)}}A(),-1!=navigator.appVersion.indexOf("MSIE 8.")&&(document.body.className+=" instagal-ie-8"),-1!=navigator.appVersion.indexOf("MSIE 9.")&&(document.body.className+=" instagal-ie-9");var R=function(e){u()(a,e);var t=F(a);function a(e){var n;return l()(this,a),(n=t.call(this,e)).method=Object(f.debounce)(n.method.bind(c()(n)),1e3),n}return o()(a,[{key:"method",value:function(){this.initLayout()}},{key:"initLayout",value:function(){var e=!1,t=setInterval((function(){_()(".tiktok-feed-feed")&&(A(),e=!0),e&&clearInterval(t)}),3e3)}},{key:"componentDidMount",value:function(){this.initLayout()}},{key:"debounceOnChange",value:function(e){var t=this,a=Object(f.debounce)((function(e){t.initLayout()}),350);a(e)}},{key:"componentDidUpdate",value:function(){this.method()}},{key:"render",value:function(){var e=this.props,t=e.attributes,a=e.setAttributes,n=qligg_gutenberg.accounts;return n&&0!=n.length?n[t.username]?Object(m.createElement)(m.Fragment,null,Object(m.createElement)(B,this.props),Object(m.createElement)("div",{className:"tiktok-site-render"}),Object(m.createElement)(O.a,{block:"qligg/box",attributes:t})):Object(m.createElement)("div",null,Object(m.createElement)(v.Placeholder,{label:Object(j.__)("Please select account","insta-gallery"),instructions:Object(m.createElement)(v.RadioControl,{value:t.username,onChange:function(e){return a({username:e})},options:Object(f.map)(n,(function(e,t){return{value:e.id,label:e.name||e.username}}))})})):Object(m.createElement)("div",null,Object(m.createElement)(v.Placeholder,{label:Object(j.__)("Please create access token","insta-gallery"),instructions:Object(m.createElement)(m.Fragment,null,Object(j.__)("Before start creating feeds, you have to create an access token. Please go to","insta-gallery")," ",Object(m.createElement)("a",{href:qligg_gutenberg.create_account,target:"_blank"},Object(j.__)("the account tab","insta-gallery")),Object(j.__)(" to connect your Instagram account and then reload this page.","insta-gallery"))}))}}]),a}(m.Component),M=a(16);Object(M.registerBlockType)("qligg/box",{title:Object(j.__)("Social Feed Gallery","insta-gallery"),description:Object(j.__)("Display beautiful and responsive galleries on your website from your Instagram feed account.","insta-gallery"),icon:"awards",category:"qligg",keywords:[Object(j.__)("qligg","insta-gallery"),Object(j.__)("instagram","insta-gallery"),Object(j.__)("quadlayers","insta-gallery")],attributes:qligg_gutenberg.attributes,edit:R})},function(e,t){},,function(e,t){}]);
1
+ !function(e){var t={};function a(n){if(t[n])return t[n].exports;var l=t[n]={i:n,l:!1,exports:{}};return e[n].call(l.exports,l,l.exports,a),l.l=!0,l.exports}a.m=e,a.c=t,a.d=function(e,t,n){a.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},a.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},a.t=function(e,t){if(1&t&&(e=a(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(a.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var l in e)a.d(n,l,function(t){return e[t]}.bind(null,l));return n},a.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return a.d(t,"a",t),t},a.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},a.p="",a(a.s=24)}([function(e,t){!function(){e.exports=this.wp.i18n}()},function(e,t){!function(){e.exports=this.wp.element}()},function(e,t){!function(){e.exports=this.wp.components}()},function(e,t){e.exports=function(e,t,a){return t in e?Object.defineProperty(e,t,{value:a,enumerable:!0,configurable:!0,writable:!0}):e[t]=a,e}},function(e,t){!function(){e.exports=this.jQuery}()},function(e,t){!function(){e.exports=this.wp.blockEditor}()},function(e,t){!function(){e.exports=this.lodash}()},function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}},function(e,t){function a(t){return e.exports=a=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},a(t)}e.exports=a},function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}},function(e,t){function a(e,t){for(var a=0;a<t.length;a++){var n=t[a];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}e.exports=function(e,t,n){return t&&a(e.prototype,t),n&&a(e,n),e}},function(e,t,a){var n=a(17);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&n(e,t)}},function(e,t,a){var n=a(18),l=a(7);e.exports=function(e,t){return!t||"object"!==n(t)&&"function"!=typeof t?l(e):t}},function(e,t){!function(){e.exports=this.wp.serverSideRender}()},function(e,t,a){var n=a(19),l=a(20),r=a(21),o=a(23);e.exports=function(e,t){return n(e)||l(e,t)||r(e,t)||o()}},function(e,t,a){var n;
2
+ /*!
3
+ Copyright (c) 2017 Jed Watson.
4
+ Licensed under the MIT License (MIT), see
5
+ http://jedwatson.github.io/classnames
6
+ */!function(){"use strict";var a={}.hasOwnProperty;function l(){for(var e=[],t=0;t<arguments.length;t++){var n=arguments[t];if(n){var r=typeof n;if("string"===r||"number"===r)e.push(n);else if(Array.isArray(n)&&n.length){var o=l.apply(null,n);o&&e.push(o)}else if("object"===r)for(var i in n)a.call(n,i)&&n[i]&&e.push(i)}}return e.join(" ")}e.exports?(l.default=l,e.exports=l):void 0===(n=function(){return l}.apply(t,[]))||(e.exports=n)}()},function(e,t){!function(){e.exports=this.wp.blocks}()},function(e,t){function a(t,n){return e.exports=a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},a(t,n)}e.exports=a},function(e,t){function a(t){return"function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?e.exports=a=function(e){return typeof e}:e.exports=a=function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},a(t)}e.exports=a},function(e,t){e.exports=function(e){if(Array.isArray(e))return e}},function(e,t){e.exports=function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var a=[],n=!0,l=!1,r=void 0;try{for(var o,i=e[Symbol.iterator]();!(n=(o=i.next()).done)&&(a.push(o.value),!t||a.length!==t);n=!0);}catch(e){l=!0,r=e}finally{try{n||null==i.return||i.return()}finally{if(l)throw r}}return a}}},function(e,t,a){var n=a(22);e.exports=function(e,t){if(e){if("string"==typeof e)return n(e,t);var a=Object.prototype.toString.call(e).slice(8,-1);return"Object"===a&&e.constructor&&(a=e.constructor.name),"Map"===a||"Set"===a?Array.from(e):"Arguments"===a||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a)?n(e,t):void 0}}},function(e,t){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var a=0,n=new Array(t);a<t;a++)n[a]=e[a];return n}},function(e,t){e.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}},function(e,t,a){"use strict";a.r(t);a(25);var n=a(9),l=a.n(n),r=a(10),o=a.n(r),i=a(7),c=a.n(i),s=a(11),u=a.n(s),g=a(12),p=a.n(g),b=a(8),d=a.n(b),m=a(1),f=a(6),y=a(4),_=a.n(y),h=a(13),O=a.n(h),j=a(0),v=a(2),C=a(3),x=a.n(C),E=a(14),k=a.n(E),w=a(15),P=a.n(w),I=a(5);function q(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,n)}return a}function T(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?q(Object(a),!0).forEach((function(t){x()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):q(Object(a)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var B=function(e){var t=e.attributes,a=e.setAttributes,n=Object(m.useState)({name:!0,biography:!0,picture:!0}),l=k()(n,2),r=l[0],o=l[1],i=qligg_gutenberg.image_url,c=qligg_gutenberg.accounts;return Object(m.createElement)(I.InspectorControls,{key:"inspector"},Object(m.createElement)(v.PanelBody,{initialOpen:!0,title:Object(j.__)("General","insta-gallery")},Object(m.createElement)(v.SelectControl,{label:Object(j.__)("Account","insta-gallery"),help:Object(j.__)("Please select Instagram account","insta-gallery"),value:t.username,onChange:function(e){return a({username:e})},options:Object(f.map)(c,(function(e,t){return{value:e.id,label:Object(j.__)(e.name,"insta-gallery")}}))}),Object(m.createElement)(v.SelectControl,{label:Object(j.__)("Feed","insta-gallery"),value:t.type,onChange:function(e){return a({type:e})},options:[{value:"tag",label:Object(j.__)("Tag","insta-gallery")},{value:"username",label:Object(j.__)("Username","insta-gallery")}]}),"tag"==t.type&&Object(m.createElement)(m.Fragment,null,Object(m.createElement)(v.TextControl,{label:Object(j.__)("Tag","insta-gallery"),help:Object(j.__)("Please enter Instagram tag","insta-gallery"),value:t.tag,onChange:function(e){return a({tag:e})}}),Object(m.createElement)(v.SelectControl,{label:Object(j.__)("Order by","insta-gallery"),help:Object(j.__)("Please enter Instagram tag order","insta-gallery"),value:t.order_by,onChange:function(e){return a({order_by:e})},options:[{value:"recend_media",label:Object(j.__)("Recent (Within 24 hours)","insta-gallery")},{value:"top_media",label:Object(j.__)("Top (Most popular first)","insta-gallery")}]})),Object(m.createElement)(m.Fragment,null,Object(m.createElement)("ul",{className:"qligg-list-videos"},Object(f.map)(["carousel","gallery","masonry","highlight"],(function(e,n){return Object(m.createElement)("li",{className:P()("qligg-modal-image",t.layout==e&&"active","carousel"!==e&&"gallery"!==e&&"qligg-premium-field"),onClick:function(){return a({layout:e})}},Object(m.createElement)("span",null,e.replace("-"," ")),Object(m.createElement)("img",{src:"".concat(i,"/").concat(e,".png")}))})))),Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Limit","insta-gallery"),help:Object(j.__)("Number of videos to display","insta-gallery"),value:t.limit,onChange:function(e){a({limit:e})},min:1,max:33}),"carousel"!=t.layout&&Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Columns","insta-gallery"),help:Object(j.__)("Number of videos in a row","insta-gallery"),value:t.columns,onChange:function(e){return a({columns:e})},min:1,max:20}),"highlight"==t.layout&&Object(m.createElement)(m.Fragment,null,Object(m.createElement)(v.TextControl,{label:Object(j.__)(" highlight by tag","insta-gallery"),help:Object(j.__)("highlightfeeds items with this tags","insta-gallery"),value:t.highlight.tag,onChange:function(e){return a({highlight:T(T({},t.highlight),{},x()({},"tag",e))})}}),Object(m.createElement)(v.TextControl,{label:Object(j.__)(" highlight by id","insta-gallery"),help:Object(j.__)(" highlight by id","insta-gallery"),value:t.highlight.id,onChange:function(e){return a({highlight:T(T({},t.highlight),{},x()({},"id",e))})}}),Object(m.createElement)(v.TextControl,{label:Object(j.__)(" highlight by position","insta-gallery"),help:Object(j.__)("highlightfeeds items in this positions","insta-gallery"),value:t.highlight.position,onChange:function(e){return a({highlight:T(T({},t.highlight),{},x()({},"position",e))})}}))),"carousel"==t.layout&&Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Carousel","insta-gallery")},Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Slides per view","insta-gallery"),help:Object(j.__)("Number of images per slide","insta-gallery"),value:t.carousel.slidespv,onChange:function(e){return a({carousel:T(T({},t.carousel),{},x()({},"slidespv",e))})},min:1,max:100}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Autoplay","insta-gallery"),help:Object(j.__)("Autoplay carousel items","insta-gallery"),checked:!!t.carousel.autoplay,onChange:function(e){return a({carousel:T(T({},t.carousel),{},x()({},"autoplay",e))})}}),t.carousel.autoplay&&Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Autoplay Interval","insta-gallery"),help:Object(j.__)("Moves to next picture after specified time interval","insta-gallery"),value:t.carousel.autoplay_interval,onChange:function(e){return a({carousel:T(T({},t.carousel),{},x()({},"autoplay_interval",e))})},min:1,max:1e4}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Navigation","insta-gallery"),help:Object(j.__)("Display navigation arrows","insta-gallery"),checked:!!t.carousel.navarrows,onChange:function(e){return a({carousel:T(T({},t.carousel),{},x()({},"navarrows",e))})}}),t.carousel.navarrows&&Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Navigation color","insta-gallery"),help:Object(j.__)("Change navigation arrows color","insta-gallery")},Object(m.createElement)(I.ColorPalette,{value:t.carousel.navarrows_color,onChange:function(e){return a({carousel:T(T({},t.carousel),{},x()({},"navarrows_color",e))})}})),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Pagination","insta-gallery"),help:Object(j.__)("Display pagination dots","insta-gallery"),checked:!!t.carousel.pagination,onChange:function(e){return a({carousel:T(T({},t.carousel),{},x()({},"pagination",e))})}}),t.carousel.pagination&&Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Pagination color","insta-gallery"),help:Object(j.__)("Change pagination dots color","insta-gallery")},Object(m.createElement)(I.ColorPalette,{value:t.carousel.pagination_color,onChange:function(e){return a({carousel:T(T({},t.carousel),{},x()({},"pagination_color",e))})}}))),Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Profile","insta-gallery")},Object(m.createElement)(v.TextControl,{label:Object(j.__)("Full name","insta-gallery"),help:Object(j.__)("Feed profile full name","insta-gallery"),value:!t.profile.name&&r.name&&c[t.username].name||t.profile.name,onChange:function(e){o(T(T({},r),{},x()({},"name",!1))),a({profile:T(T({},t.profile),{},x()({},"name",e))})}}),Object(m.createElement)(v.TextareaControl,{label:Object(j.__)("Biography","insta-gallery"),help:Object(j.__)("Feed profile biography","insta-gallery"),value:!t.profile.biography&&r.biography&&c[t.username].biography||t.profile.biography,onChange:function(e){o(T(T({},r),{},x()({},"biography",!1))),a({profile:T(T({},t.profile),{},x()({},"biography",e))})}}),Object(m.createElement)(m.Fragment,null,Object(m.createElement)("img",{style:{objectFit:"cover",width:"230px",height:"230px"},src:!t.profile.profile_picture_url&&r.picture&&c[t.username].profile_picture_url||t.profile.profile_picture_url}),Object(m.createElement)(I.MediaUpload,{onSelect:function(e){o(T(T({},r),{},x()({},"picture",!1))),a({profile:T(T({},t.profile),{},x()({},"profile_picture_url",e.url))})},allowedTypes:["image"],value:t.profile.profile_picture_url,render:function(e){var t=e.open;return Object(m.createElement)(v.Button,{onClick:t},Object(j.__)("Upload","insta-gallery"))}}))),Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Box","insta-gallery")},Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Box","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Display the Instagram Feed inside a customizable box","insta-gallery"),checked:!!t.box.display,onChange:function(e){return a({box:T(T({},t.box),{},x()({},"display",e))})}}),t.box.display&&Object(m.createElement)(m.Fragment,null,Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Box padding","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Add padding to the Instagram Feed","insta-gallery"),value:t.box.padding,onChange:function(e){return a({box:T(T({},t.box),{},x()({},"padding",e))})},min:1,max:100}),Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Border Radius","insta-gallery"),help:Object(j.__)("Add radius to the Instagram Feed","insta-gallery"),className:"qligg-premium-field",value:t.box.radius,onChange:function(e){return a({box:T(T({},t.box),{},x()({},"radius",e))})},min:0,max:100}),Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Box background","insta-gallery"),help:Object(j.__)("Color which is displayed on box background","insta-gallery"),className:"qligg-premium-field"},Object(m.createElement)(I.ColorPalette,{value:t.box.background,onChange:function(e){return a({box:T(T({},t.box),{},x()({},"background",e))})}})),Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Box text color","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Color which is displayed on box text","insta-gallery")},Object(m.createElement)(I.ColorPalette,{value:t.box.color_text,onChange:function(e){return a({box:T(T({},t.box),{},x()({},"color_text",e))})}})),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Profile","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Display user profile or tag info","insta-gallery"),checked:!!t.box.profile,onChange:function(e){return a({box:T(T({},t.box),{},x()({},"profile",e))})}}))),Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Image","insta-gallery")},Object(m.createElement)(v.SelectControl,{label:Object(j.__)("Account","insta-gallery"),value:t.resolution,onChange:function(e){return a({resolution:e})},options:[{value:"madium",label:Object(j.__)("Medium (320 x auto)","insta-gallery")},{value:"small",label:Object(j.__)("Small (150 x 150)","insta-gallery")}]}),Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Images spacing","insta-gallery"),help:Object(j.__)("Add blank space between images","insta-gallery"),value:t.spacing,onChange:function(e){return a({spacing:e})},min:0,max:100}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images lazy load","insta-gallery"),help:Object(j.__)("Defers feed images loading","insta-gallery"),checked:!!t.lazy,onChange:function(e){return a({lazy:e})}})),Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Image card","insta-gallery")},Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images card","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Display card gallery by clicking on image","insta-gallery"),checked:!!t.card.display,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"display",e))})}}),t.card.display&&Object(m.createElement)(m.Fragment,null,Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Card radius","insta-gallery"),help:Object(j.__)("Add radius to the Instagram Feed","insta-gallery"),className:"qligg-premium-field",value:t.card.radius,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"radius",e))})},min:0,max:100}),Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Card font size","insta-gallery"),help:Object(j.__)("Add font-size to the Instagram Feed","insta-gallery"),className:"qligg-premium-field",value:t.card.font_size,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"font_size",e))})},min:0,max:100}),Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Card background","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Color which is displayed when over images","insta-gallery")},Object(m.createElement)(I.ColorPalette,{value:t.card.background,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"background",e))})}})),Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Card text color","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Color Text","insta-gallery")},Object(m.createElement)(I.ColorPalette,{value:t.card.text_color,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"text_color",e))})}})),Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Card padding","insta-gallery"),help:Object(j.__)("Add blank space between images","insta-gallery"),className:"qligg-premium-field",value:t.card.padding,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"padding",e))})},min:0,max:100}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Card info","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Display likes count of images","insta-gallery"),checked:!!t.card.info,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"info",e))})}}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Card caption","insta-gallery"),className:"qligg-premium-field",help:Object(j.__)("Display caption count of images","insta-gallery"),checked:!!t.card.caption,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"caption",e))})}}),Object(m.createElement)(v.RangeControl,{label:Object(j.__)("Card length","insta-gallery"),help:Object(j.__)("Add blank space between images","insta-gallery"),className:"qligg-premium-field",value:t.card.length,onChange:function(e){return a({card:T(T({},t.card),{},x()({},"length",e))})},min:0,max:100}))),Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Image mask","insta-gallery")},Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images mask","insta-gallery"),help:Object(j.__)("Image mouseover effect","insta-gallery"),checked:!!t.mask.display,onChange:function(e){return a({mask:T(T({},t.mask),{},x()({},"display",e))})}}),t.mask.display&&Object(m.createElement)(m.Fragment,null,Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Images mask color","insta-gallery"),help:Object(j.__)("Image mask background color","insta-gallery")},Object(m.createElement)(I.ColorPalette,{value:t.mask.background,onChange:function(e){return a({mask:T(T({},t.mask),{},x()({},"background",e))})}})),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images mask likes","insta-gallery"),help:Object(j.__)("Display likes count of images","insta-gallery"),checked:!!t.mask.likes,onChange:function(e){return a({mask:T(T({},t.mask),{},x()({},"likes",e))})}}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images mask comments","insta-gallery"),help:Object(j.__)("Display comments count of images","insta-gallery"),checked:!!t.mask.comments,onChange:function(e){return a({mask:T(T({},t.mask),{},x()({},"comments",e))})}}))),Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Image popup","insta-gallery")},Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images popup","insta-gallery"),help:Object(j.__)("Display popup gallery by clicking on image","insta-gallery"),checked:!!t.popup.display,onChange:function(e){return a({popup:T(T({},t.popup),{},x()({},"display",e))})}}),t.popup.display&&Object(m.createElement)(m.Fragment,null,Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images popup profile","insta-gallery"),help:Object(j.__)("Display user profile or tag info","insta-gallery"),className:"qligg-premium-field",checked:!!t.popup.profile,onChange:function(e){return a({popup:T(T({},t.popup),{},x()({},"profile",e))})}}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images popup caption","insta-gallery"),help:Object(j.__)("Display caption in the popup","insta-gallery"),className:"qligg-premium-field",checked:!!t.popup.caption,onChange:function(e){return a({popup:T(T({},t.popup),{},x()({},"caption",e))})}}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images popup likes","insta-gallery"),help:Object(j.__)("Display likes count of images","insta-gallery"),className:"qligg-premium-field",checked:!!t.popup.likes,onChange:function(e){return a({popup:T(T({},t.popup),{},x()({},"likes",e))})}}),Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Images popup comments","insta-gallery"),help:Object(j.__)("Display comments count of images","insta-gallery"),className:"qligg-premium-field",checked:!!t.popup.comments,onChange:function(e){return a({popup:T(T({},t.popup),{},x()({},"comments",e))})}}),Object(m.createElement)(v.SelectControl,{label:Object(j.__)("Images popup align","insta-gallery"),help:Object(j.__)("Align item description in popup","insta-gallery"),className:"qligg-premium-field",value:t.popup.align,onChange:function(e){return a({popup:T(T({},t.popup),{},x()({},"align",e))})},options:[{value:"left",label:Object(j.__)("Left","insta-gallery")},{value:"right",label:Object(j.__)("Right","insta-gallery")},{value:"bottom",label:Object(j.__)("Bottom","insta-gallery")},{value:"top",label:Object(j.__)("Top","insta-gallery")}]}))),Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Botton","insta-gallery")},Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Instagram button","insta-gallery"),help:Object(j.__)("Display the button to open Instagram site link","insta-gallery"),checked:!!t.button.display,onChange:function(e){return a({button:T(T({},t.button),{},x()({},"display",e))})}}),t.button.display&&Object(m.createElement)(m.Fragment,null,Object(m.createElement)(v.TextControl,{label:Object(j.__)("Instagram button text","insta-gallery"),help:Object(j.__)("Instagram button text here","insta-gallery"),value:t.button.text,onChange:function(e){return a({button:T(T({},t.button),{},x()({},"text",e))})}}),Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Instagram button background","insta-gallery"),help:Object(j.__)("Color which is displayed on button background","insta-gallery")},Object(m.createElement)(I.ColorPalette,{value:t.button.background,onChange:function(e){return a({button:T(T({},t.button),{},x()({},"background",e))})}})),Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Instagram button hover background","insta-gallery"),help:Object(j.__)("Color which is displayed when hovered over button","insta-gallery")},Object(m.createElement)(I.ColorPalette,{value:t.button.background_hover,onChange:function(e){return a({button:T(T({},t.button),{},x()({},"background_hover",e))})}})))),Object(m.createElement)(v.PanelBody,{initialOpen:!1,title:Object(j.__)("Botton load more","insta-gallery")},Object(m.createElement)(v.ToggleControl,{label:Object(j.__)("Instagram button","insta-gallery"),help:Object(j.__)("Display the button to open Instagram site link","insta-gallery"),className:"qligg-premium-field",checked:!!t.button_load.display,onChange:function(e){return a({button_load:T(T({},t.button_load),{},x()({},"display",e))})}}),t.button_load.display&&Object(m.createElement)(m.Fragment,null,Object(m.createElement)(v.TextControl,{label:Object(j.__)("Instagram button text","insta-gallery"),help:Object(j.__)("Instagram button text here","insta-gallery"),className:"qligg-premium-field",value:t.button_load.text,onChange:function(e){return a({button_load:T(T({},t.button_load),{},x()({},"text",e))})}}),Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Instagram button background","insta-gallery"),help:Object(j.__)("Color which is displayed on button background","insta-gallery"),className:"qligg-premium-field"},Object(m.createElement)(I.ColorPalette,{value:t.button_load.background,onChange:function(e){return a({button_load:T(T({},t.button_load),{},x()({},"background",e))})}})),Object(m.createElement)(v.BaseControl,{label:Object(j.__)("Instagram button hover background","insta-gallery"),help:Object(j.__)("Color which is displayed when hovered over button","insta-gallery"),className:"qligg-premium-field"},Object(m.createElement)(I.ColorPalette,{value:t.button_load.background_hover,onChange:function(e){return a({button_load:T(T({},t.button_load),{},x()({},"background_hover",e))})}})))))},N=(a(27),0),S={};function D(e,t){var a=_()(".insta-gallery-list",e),n=_()(".insta-gallery-spinner",e),l=e.data("feed");_.a.ajax({url:qligg.ajax_url,type:"post",timeout:3e4,data:{action:"qligg_load_item_images",next_max_id:t,feed:JSON.stringify(l)},beforeSend:function(){n.show()},success:function(e){if(!0!==e.success)return a.append(_()(e.data)),void n.hide();var t=_()(e.data);a.append(t).trigger("qligg.loaded",[t])},complete:function(){},error:function(e,t){n.hide()}})}function A(){_()(".insta-gallery-feed").on("qligg.loaded",(function(e,t){var a=_()(e.delegateTarget),n=_()(".insta-gallery-list",a),l=_()(".insta-gallery-spinner",a),r=_()(".insta-gallery-button.load",a),o=a.data("feed"),i=_()(t).length,c=0;i&&n.find(".insta-gallery-image").on("load loadstart",(function(e){("loadstart"==e.type&&"VIDEO"==_()(e.target).prop("tagName")||"load"==e.type&&"IMG"==_()(e.target).prop("tagName"))&&c++,c>=i&&n.trigger("qligg.imagesLoaded",[t])})),i<o.limit&&(l.hide(),setTimeout((function(){r.fadeOut()}),300))})),_()(".insta-gallery-feed").on("qligg.imagesLoaded",(function(e){var t=_()(e.delegateTarget);_()(".insta-gallery-spinner",t).hide()})),_()(".insta-gallery-feed[data-feed_layout=gallery]").on("qligg.imagesLoaded",(function(e,t){_()(e.delegateTarget).addClass("loaded"),_()(t).each((function(e,t){setTimeout((function(){_()(t).addClass("ig-image-loaded")}),150+30*e)}))})),_()(".insta-gallery-feed[data-feed_layout=carousel]").on("qligg.imagesLoaded",(function(e,t){_()(e.delegateTarget).addClass("loaded"),_()(t).each((function(e,t){_()(t).addClass("ig-image-loaded")}))})),_()(".insta-gallery-feed[data-feed_layout=carousel]").on("qligg.imagesLoaded",(function(e,t){var a=_()(e.delegateTarget),n=_()(".swiper-container",a),l=a.data("feed");l.carousel.slides=l.carousel.slidespv,N++,S[N]=new Swiper(n,{loop:!0,autoHeight:!0,observer:!0,observeParents:!0,slidesPerView:1,spaceBetween:2,autoplay:!!l.carousel.autoplay&&{delay:parseInt(l.carousel.autoplay_interval)},pagination:{el:".swiper-pagination",dynamicBullets:!0,clickable:!0,type:"bullets"},navigation:{nextEl:".swiper-button-next",prevEl:".swiper-button-prev"},breakpoints:{320:{slidesPerView:1,spaceBetween:1},480:{spaceBetween:parseInt(l.spacing),slidesPerView:Math.min(2,parseInt(l.carousel.slides))},768:{spaceBetween:parseInt(l.spacing),slidesPerView:Math.min(3,parseInt(l.carousel.slides))},1024:{spaceBetween:parseInt(l.spacing),slidesPerView:parseInt(l.carousel.slides)}}})})),_()(".insta-gallery-feed[data-feed_layout=masonry]").on("qligg.imagesLoaded",(function(e,t){var a=_()(e.delegateTarget),n=_()(".insta-gallery-list",a);n.data("masonry")?n.masonry("appended",t,!1):n.masonry({itemSelector:".insta-gallery-item",isResizable:!0,isAnimated:!1,transitionDuration:0,percentPosition:!0,columnWidth:".insta-gallery-item:last-child"})})),_()(".insta-gallery-feed[data-feed_layout=masonry]").on("layoutComplete",(function(e,t){_()(e.delegateTarget).addClass("loaded"),_()(t).each((function(e,t){_()(t.element).addClass("ig-image-loaded")}))})),_()(".insta-gallery-feed").on("qligg.loaded",(function(e){var t=_()(e.delegateTarget),a=_()(".insta-gallery-list",t),n=t.data("feed");_()(".insta-gallery-item .insta-gallery-icon.qligg-icon-instagram",a).on("click",(function(e){e.stopPropagation()})),n.popup.display&&_()(".insta-gallery-item",a).magnificPopup({type:"inline",callbacks:{beforeOpen:function(){this.st.mainClass=this.st.mainClass+" qligg-mfp-wrap"},elementParse:function(e){var t,l="",r="",o="",i="",c="",s="",u="";l=!e.el.data("item").type||"video"!=e.el.data("item").type&&"video"!=e.el.data("item").file_type?'<img src="'+e.el.data("item").images.standard+'"/>':'\n <video autoplay>\n <source src="'+e.el.data("item").videos.standard+'" type="video/mp4">\n </video>',t='<div class="mfp-icons"><div class="mfp-counter">'+(e.index+1)+" / "+_()(".insta-gallery-item",a).length+'</div><a class="mfp-link" href="'+e.el.data("item").link+'" target="_blank" rel="noopener"><i class="qligg-icon-instagram"></i>Instagram</a></div>',n.popup.profile&&(r='<div class="mfp-user"><img src="'+n.profile.profile_picture_url+'"><a href="https://www.instagram.com/'+n.profile.username+'" title="'+n.profile.name+'" target="_blank" rel="noopener">'+n.profile.username+"</a></div>"),n.popup.caption&&(o='<div class="mfp-caption">'+e.el.data("item").caption+"</div>"),e.el.data("item").date&&(s='<div class="mfp-date">'+e.el.data("item").date+"</div>"),e.el.data("item").comments&&n.popup.comments&&(u='<div class="mfp-comments"><i class="qligg-icon-comment"></i>'+e.el.data("item").comments+"</div>"),e.el.data("item").likes&&n.popup.likes&&(c='<div class="mfp-likes"><i class="qligg-icon-heart"></i>'+e.el.data("item").likes+"</div>"),(n.popup.likes||n.popup.comments)&&(i='<div class="mfp-info">'+c+u+s+"</div>"),e.src='<div class="mfp-figure '+n.popup.align+'">'+l+'<div class="mfp-close"></div><div class="mfp-bottom-bar"><div class="mfp-title">'+r+t+o+i+"</div></div></div>"}},gallery:{enabled:!0}})})),_()(".insta-gallery-feed").on("click",".insta-gallery-button.load",(function(e){e.preventDefault();var t=_()(e.delegateTarget);if(!t.hasClass("loaded"))return!1;D(t,_()(".insta-gallery-list .insta-gallery-item:last-child",t).data("item").i)})),_()(".insta-gallery-feed").each((function(e,t){var a=_()(t);if(a.hasClass("loaded"))return!1;D(a,0)}))}function F(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var a,n=d()(e);if(t){var l=d()(this).constructor;a=Reflect.construct(n,arguments,l)}else a=n.apply(this,arguments);return p()(this,a)}}A(),-1!=navigator.appVersion.indexOf("MSIE 8.")&&(document.body.className+=" instagal-ie-8"),-1!=navigator.appVersion.indexOf("MSIE 9.")&&(document.body.className+=" instagal-ie-9");var R=function(e){u()(a,e);var t=F(a);function a(e){var n;return l()(this,a),(n=t.call(this,e)).method=Object(f.debounce)(n.method.bind(c()(n)),1e3),n}return o()(a,[{key:"method",value:function(){this.initLayout()}},{key:"initLayout",value:function(){var e=!1,t=setInterval((function(){_()(".tiktok-feed-feed")&&(A(),e=!0),e&&clearInterval(t)}),3e3)}},{key:"componentDidMount",value:function(){this.initLayout()}},{key:"debounceOnChange",value:function(e){var t=this,a=Object(f.debounce)((function(e){t.initLayout()}),350);a(e)}},{key:"componentDidUpdate",value:function(){this.method()}},{key:"render",value:function(){var e=this.props,t=e.attributes,a=e.setAttributes,n=qligg_gutenberg.accounts;return n&&0!=n.length?n[t.username]?Object(m.createElement)(m.Fragment,null,Object(m.createElement)(B,this.props),Object(m.createElement)("div",{className:"tiktok-site-render"}),Object(m.createElement)(O.a,{block:"qligg/box",attributes:t})):Object(m.createElement)("div",null,Object(m.createElement)(v.Placeholder,{label:Object(j.__)("Please select account","insta-gallery"),instructions:Object(m.createElement)(v.RadioControl,{value:t.username,onChange:function(e){return a({username:e})},options:Object(f.map)(n,(function(e,t){return{value:e.id,label:e.name||e.username}}))})})):Object(m.createElement)("div",null,Object(m.createElement)(v.Placeholder,{label:Object(j.__)("Please create access token","insta-gallery"),instructions:Object(m.createElement)(m.Fragment,null,Object(j.__)("Before start creating feeds, you have to create an access token. Please go to","insta-gallery")," ",Object(m.createElement)("a",{href:qligg_gutenberg.create_account,target:"_blank"},Object(j.__)("the account tab","insta-gallery")),Object(j.__)(" to connect your Instagram account and then reload this page.","insta-gallery"))}))}}]),a}(m.Component),M=a(16);Object(M.registerBlockType)("qligg/box",{title:Object(j.__)("Social Feed Gallery","insta-gallery"),description:Object(j.__)("Display beautiful and responsive galleries on your website from your Instagram feed account.","insta-gallery"),icon:"awards",category:"qligg",keywords:[Object(j.__)("qligg","insta-gallery"),Object(j.__)("instagram","insta-gallery"),Object(j.__)("quadlayers","insta-gallery")],attributes:qligg_gutenberg.attributes,edit:R})},function(e,t){},,function(e,t){}]);
assets/frontend/js/frontend.asset.php CHANGED
@@ -1 +1 @@
1
- <?php return array('dependencies' => array('jquery'), 'version' => '6ee3aa1abf39a279d4a5a490da084a0f');
1
+ <?php return array('dependencies' => array('jquery'), 'version' => '7f265e7030b1b97055e58ad3e7ff3766');
assets/frontend/js/frontend.js CHANGED
@@ -1 +1 @@
1
- !function(e){var a={};function t(i){if(a[i])return a[i].exports;var n=a[i]={i:i,l:!1,exports:{}};return e[i].call(n.exports,n,n.exports,t),n.l=!0,n.exports}t.m=e,t.c=a,t.d=function(e,a,i){t.o(e,a)||Object.defineProperty(e,a,{enumerable:!0,get:i})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,a){if(1&a&&(e=t(e)),8&a)return e;if(4&a&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(t.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&a&&"string"!=typeof e)for(var n in e)t.d(i,n,function(a){return e[a]}.bind(null,n));return i},t.n=function(e){var a=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(a,"a",a),a},t.o=function(e,a){return Object.prototype.hasOwnProperty.call(e,a)},t.p="",t(t.s=1)}([function(e,a){!function(){e.exports=this.jQuery}()},function(e,a,t){"use strict";t.r(a),t.d(a,"qligg_init",(function(){return r}));var i=t(0),n=t.n(i),l=(t(2),0),s={};function o(e,a){var t=n()(".insta-gallery-list",e),i=n()(".insta-gallery-spinner",e),l=e.data("feed");n.a.ajax({url:qligg.ajax_url,type:"post",timeout:3e4,data:{action:"qligg_load_item_images",next_max_id:a,feed:JSON.stringify(l)},beforeSend:function(){i.show()},success:function(e){if(!0!==e.success)return t.append(n()(e.data)),void i.hide();var a=n()(e.data);t.append(a).trigger("qligg.loaded",[a])},complete:function(){},error:function(e,a){i.hide()}})}function r(){n()(".insta-gallery-feed").on("qligg.loaded",(function(e,a){var t=n()(e.delegateTarget),i=n()(".insta-gallery-list",t),l=n()(".insta-gallery-spinner",t),s=n()(".insta-gallery-button.load",t),o=t.data("feed"),r=n()(a).length,d=0;r&&i.find(".insta-gallery-image").on("load loadstart",(function(e){++d>=r&&i.trigger("qligg.imagesLoaded",[a])})),r<o.limit&&(l.hide(),setTimeout((function(){s.fadeOut()}),300))})),n()(".insta-gallery-feed").on("qligg.imagesLoaded",(function(e){var a=n()(e.delegateTarget);n()(".insta-gallery-spinner",a).hide()})),n()(".insta-gallery-feed[data-feed_layout=gallery]").on("qligg.imagesLoaded",(function(e,a){n()(e.delegateTarget).addClass("loaded"),n()(a).each((function(e,a){setTimeout((function(){n()(a).addClass("ig-image-loaded")}),150+30*e)}))})),n()(".insta-gallery-feed[data-feed_layout=carousel]").on("qligg.imagesLoaded",(function(e,a){n()(e.delegateTarget).addClass("loaded"),n()(a).each((function(e,a){n()(a).addClass("ig-image-loaded")}))})),n()(".insta-gallery-feed[data-feed_layout=carousel]").on("qligg.imagesLoaded",(function(e,a){var t=n()(e.delegateTarget),i=n()(".swiper-container",t),o=t.data("feed");o.carousel.slides=o.carousel.slidespv,l++,s[l]=new Swiper(i,{loop:!0,autoHeight:!0,observer:!0,observeParents:!0,slidesPerView:1,spaceBetween:2,autoplay:!!o.carousel.autoplay&&{delay:parseInt(o.carousel.autoplay_interval)},pagination:{el:".swiper-pagination",dynamicBullets:!0,clickable:!0,type:"bullets"},navigation:{nextEl:".swiper-button-next",prevEl:".swiper-button-prev"},breakpoints:{320:{slidesPerView:1,spaceBetween:1},480:{spaceBetween:parseInt(o.spacing),slidesPerView:Math.min(2,parseInt(o.carousel.slides))},768:{spaceBetween:parseInt(o.spacing),slidesPerView:Math.min(3,parseInt(o.carousel.slides))},1024:{spaceBetween:parseInt(o.spacing),slidesPerView:parseInt(o.carousel.slides)}}})})),n()(".insta-gallery-feed[data-feed_layout=masonry]").on("qligg.imagesLoaded",(function(e,a){var t=n()(e.delegateTarget),i=n()(".insta-gallery-list",t);i.data("masonry")?i.masonry("appended",a,!1):i.masonry({itemSelector:".insta-gallery-item",isResizable:!0,isAnimated:!1,transitionDuration:0,percentPosition:!0,columnWidth:".insta-gallery-item:last-child"})})),n()(".insta-gallery-feed[data-feed_layout=masonry]").on("layoutComplete",(function(e,a){n()(e.delegateTarget).addClass("loaded"),n()(a).each((function(e,a){n()(a.element).addClass("ig-image-loaded")}))})),n()(".insta-gallery-feed").on("qligg.loaded",(function(e){var a=n()(e.delegateTarget),t=n()(".insta-gallery-list",a),i=a.data("feed");n()(".insta-gallery-item .insta-gallery-icon.qligg-icon-instagram",t).on("click",(function(e){e.stopPropagation()})),i.popup.display&&n()(".insta-gallery-item",t).magnificPopup({type:"inline",callbacks:{beforeOpen:function(){this.st.mainClass=this.st.mainClass+" qligg-mfp-wrap"},elementParse:function(e){var a,l="",s="",o="",r="",d="",c="",g="";l=!e.el.data("item").type||"video"!=e.el.data("item").type&&"video"!=e.el.data("item").file_type?'<img src="'+e.el.data("item").images.standard+'"/>':'\n <video autoplay>\n <source src="'+e.el.data("item").videos.standard+'" type="video/mp4">\n </video>',a='<div class="mfp-icons"><div class="mfp-counter">'+(e.index+1)+" / "+n()(".insta-gallery-item",t).length+'</div><a class="mfp-link" href="'+e.el.data("item").link+'" target="_blank" rel="noopener"><i class="qligg-icon-instagram"></i>Instagram</a></div>',i.popup.profile&&(s='<div class="mfp-user"><img src="'+i.profile.profile_picture_url+'"><a href="https://www.instagram.com/'+i.profile.username+'" title="'+i.profile.name+'" target="_blank" rel="noopener">'+i.profile.username+"</a></div>"),i.popup.caption&&(o='<div class="mfp-caption">'+e.el.data("item").caption+"</div>"),e.el.data("item").date&&(c='<div class="mfp-date">'+e.el.data("item").date+"</div>"),e.el.data("item").comments&&i.popup.comments&&(g='<div class="mfp-comments"><i class="qligg-icon-comment"></i>'+e.el.data("item").comments+"</div>"),e.el.data("item").likes&&i.popup.likes&&(d='<div class="mfp-likes"><i class="qligg-icon-heart"></i>'+e.el.data("item").likes+"</div>"),(i.popup.likes||i.popup.comments)&&(r='<div class="mfp-info">'+d+g+c+"</div>"),e.src='<div class="mfp-figure '+i.popup.align+'">'+l+'<div class="mfp-close"></div><div class="mfp-bottom-bar"><div class="mfp-title">'+s+a+o+r+"</div></div></div>"}},gallery:{enabled:!0}})})),n()(".insta-gallery-feed").on("click",".insta-gallery-button.load",(function(e){e.preventDefault();var a=n()(e.delegateTarget);if(!a.hasClass("loaded"))return!1;o(a,n()(".insta-gallery-list .insta-gallery-item:last-child",a).data("item").i)})),n()(".insta-gallery-feed").each((function(e,a){var t=n()(a);if(t.hasClass("loaded"))return!1;o(t,0)}))}r(),-1!=navigator.appVersion.indexOf("MSIE 8.")&&(document.body.className+=" instagal-ie-8"),-1!=navigator.appVersion.indexOf("MSIE 9.")&&(document.body.className+=" instagal-ie-9")},function(e,a){}]);
1
+ !function(e){var a={};function t(i){if(a[i])return a[i].exports;var n=a[i]={i:i,l:!1,exports:{}};return e[i].call(n.exports,n,n.exports,t),n.l=!0,n.exports}t.m=e,t.c=a,t.d=function(e,a,i){t.o(e,a)||Object.defineProperty(e,a,{enumerable:!0,get:i})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,a){if(1&a&&(e=t(e)),8&a)return e;if(4&a&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(t.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&a&&"string"!=typeof e)for(var n in e)t.d(i,n,function(a){return e[a]}.bind(null,n));return i},t.n=function(e){var a=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(a,"a",a),a},t.o=function(e,a){return Object.prototype.hasOwnProperty.call(e,a)},t.p="",t(t.s=1)}([function(e,a){!function(){e.exports=this.jQuery}()},function(e,a,t){"use strict";t.r(a),t.d(a,"qligg_init",(function(){return r}));var i=t(0),n=t.n(i),l=(t(2),0),s={};function o(e,a){var t=n()(".insta-gallery-list",e),i=n()(".insta-gallery-spinner",e),l=e.data("feed");n.a.ajax({url:qligg.ajax_url,type:"post",timeout:3e4,data:{action:"qligg_load_item_images",next_max_id:a,feed:JSON.stringify(l)},beforeSend:function(){i.show()},success:function(e){if(!0!==e.success)return t.append(n()(e.data)),void i.hide();var a=n()(e.data);t.append(a).trigger("qligg.loaded",[a])},complete:function(){},error:function(e,a){i.hide()}})}function r(){n()(".insta-gallery-feed").on("qligg.loaded",(function(e,a){var t=n()(e.delegateTarget),i=n()(".insta-gallery-list",t),l=n()(".insta-gallery-spinner",t),s=n()(".insta-gallery-button.load",t),o=t.data("feed"),r=n()(a).length,d=0;r&&i.find(".insta-gallery-image").on("load loadstart",(function(e){("loadstart"==e.type&&"VIDEO"==n()(e.target).prop("tagName")||"load"==e.type&&"IMG"==n()(e.target).prop("tagName"))&&d++,d>=r&&i.trigger("qligg.imagesLoaded",[a])})),r<o.limit&&(l.hide(),setTimeout((function(){s.fadeOut()}),300))})),n()(".insta-gallery-feed").on("qligg.imagesLoaded",(function(e){var a=n()(e.delegateTarget);n()(".insta-gallery-spinner",a).hide()})),n()(".insta-gallery-feed[data-feed_layout=gallery]").on("qligg.imagesLoaded",(function(e,a){n()(e.delegateTarget).addClass("loaded"),n()(a).each((function(e,a){setTimeout((function(){n()(a).addClass("ig-image-loaded")}),150+30*e)}))})),n()(".insta-gallery-feed[data-feed_layout=carousel]").on("qligg.imagesLoaded",(function(e,a){n()(e.delegateTarget).addClass("loaded"),n()(a).each((function(e,a){n()(a).addClass("ig-image-loaded")}))})),n()(".insta-gallery-feed[data-feed_layout=carousel]").on("qligg.imagesLoaded",(function(e,a){var t=n()(e.delegateTarget),i=n()(".swiper-container",t),o=t.data("feed");o.carousel.slides=o.carousel.slidespv,l++,s[l]=new Swiper(i,{loop:!0,autoHeight:!0,observer:!0,observeParents:!0,slidesPerView:1,spaceBetween:2,autoplay:!!o.carousel.autoplay&&{delay:parseInt(o.carousel.autoplay_interval)},pagination:{el:".swiper-pagination",dynamicBullets:!0,clickable:!0,type:"bullets"},navigation:{nextEl:".swiper-button-next",prevEl:".swiper-button-prev"},breakpoints:{320:{slidesPerView:1,spaceBetween:1},480:{spaceBetween:parseInt(o.spacing),slidesPerView:Math.min(2,parseInt(o.carousel.slides))},768:{spaceBetween:parseInt(o.spacing),slidesPerView:Math.min(3,parseInt(o.carousel.slides))},1024:{spaceBetween:parseInt(o.spacing),slidesPerView:parseInt(o.carousel.slides)}}})})),n()(".insta-gallery-feed[data-feed_layout=masonry]").on("qligg.imagesLoaded",(function(e,a){var t=n()(e.delegateTarget),i=n()(".insta-gallery-list",t);i.data("masonry")?i.masonry("appended",a,!1):i.masonry({itemSelector:".insta-gallery-item",isResizable:!0,isAnimated:!1,transitionDuration:0,percentPosition:!0,columnWidth:".insta-gallery-item:last-child"})})),n()(".insta-gallery-feed[data-feed_layout=masonry]").on("layoutComplete",(function(e,a){n()(e.delegateTarget).addClass("loaded"),n()(a).each((function(e,a){n()(a.element).addClass("ig-image-loaded")}))})),n()(".insta-gallery-feed").on("qligg.loaded",(function(e){var a=n()(e.delegateTarget),t=n()(".insta-gallery-list",a),i=a.data("feed");n()(".insta-gallery-item .insta-gallery-icon.qligg-icon-instagram",t).on("click",(function(e){e.stopPropagation()})),i.popup.display&&n()(".insta-gallery-item",t).magnificPopup({type:"inline",callbacks:{beforeOpen:function(){this.st.mainClass=this.st.mainClass+" qligg-mfp-wrap"},elementParse:function(e){var a,l="",s="",o="",r="",d="",c="",p="";l=!e.el.data("item").type||"video"!=e.el.data("item").type&&"video"!=e.el.data("item").file_type?'<img src="'+e.el.data("item").images.standard+'"/>':'\n <video autoplay>\n <source src="'+e.el.data("item").videos.standard+'" type="video/mp4">\n </video>',a='<div class="mfp-icons"><div class="mfp-counter">'+(e.index+1)+" / "+n()(".insta-gallery-item",t).length+'</div><a class="mfp-link" href="'+e.el.data("item").link+'" target="_blank" rel="noopener"><i class="qligg-icon-instagram"></i>Instagram</a></div>',i.popup.profile&&(s='<div class="mfp-user"><img src="'+i.profile.profile_picture_url+'"><a href="https://www.instagram.com/'+i.profile.username+'" title="'+i.profile.name+'" target="_blank" rel="noopener">'+i.profile.username+"</a></div>"),i.popup.caption&&(o='<div class="mfp-caption">'+e.el.data("item").caption+"</div>"),e.el.data("item").date&&(c='<div class="mfp-date">'+e.el.data("item").date+"</div>"),e.el.data("item").comments&&i.popup.comments&&(p='<div class="mfp-comments"><i class="qligg-icon-comment"></i>'+e.el.data("item").comments+"</div>"),e.el.data("item").likes&&i.popup.likes&&(d='<div class="mfp-likes"><i class="qligg-icon-heart"></i>'+e.el.data("item").likes+"</div>"),(i.popup.likes||i.popup.comments)&&(r='<div class="mfp-info">'+d+p+c+"</div>"),e.src='<div class="mfp-figure '+i.popup.align+'">'+l+'<div class="mfp-close"></div><div class="mfp-bottom-bar"><div class="mfp-title">'+s+a+o+r+"</div></div></div>"}},gallery:{enabled:!0}})})),n()(".insta-gallery-feed").on("click",".insta-gallery-button.load",(function(e){e.preventDefault();var a=n()(e.delegateTarget);if(!a.hasClass("loaded"))return!1;o(a,n()(".insta-gallery-list .insta-gallery-item:last-child",a).data("item").i)})),n()(".insta-gallery-feed").each((function(e,a){var t=n()(a);if(t.hasClass("loaded"))return!1;o(t,0)}))}r(),-1!=navigator.appVersion.indexOf("MSIE 8.")&&(document.body.className+=" instagal-ie-8"),-1!=navigator.appVersion.indexOf("MSIE 9.")&&(document.body.className+=" instagal-ie-9")},function(e,a){}]);
assets/frontend/js/frontend.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///./src/frontend/index.js","webpack:///./src/frontend/scss/style.scss","webpack:///external {\"this\":\"jQuery\"}"],"names":["swiper_index","$swipers","qligg_load_item_images","$item","next_max_id","$wrap","$","$spinner","feed","data","ajax","url","qligg","ajax_url","type","timeout","action","JSON","stringify","beforeSend","show","success","response","append","hide","$images","trigger","complete","error","jqXHR","textStatus","qligg_init","on","e","images","delegateTarget","$button","options","total","length","loaded","find","limit","setTimeout","fadeOut","addClass","each","i","item","$swiper","carousel","slides","slidespv","Swiper","loop","autoHeight","observer","observeParents","slidesPerView","spaceBetween","autoplay","delay","parseInt","autoplay_interval","pagination","el","dynamicBullets","clickable","navigation","nextEl","prevEl","breakpoints","spacing","Math","min","masonry","itemSelector","isResizable","isAnimated","transitionDuration","percentPosition","columnWidth","items","element","stopPropagation","popup","display","magnificPopup","callbacks","beforeOpen","st","mainClass","elementParse","media","profile","counter","caption","info","likes","date","comments","file_type","videos","standard","index","link","profile_picture_url","username","name","src","align","gallery","enabled","preventDefault","hasClass","navigator","appVersion","indexOf","document","body","className"],"mappings":";QAAA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA,0CAA0C,gCAAgC;QAC1E;QACA;;QAEA;QACA;QACA;QACA,wDAAwD,kBAAkB;QAC1E;QACA,iDAAiD,cAAc;QAC/D;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA,yCAAyC,iCAAiC;QAC1E,gHAAgH,mBAAmB,EAAE;QACrI;QACA;;QAEA;QACA;QACA;QACA,2BAA2B,0BAA0B,EAAE;QACvD,iCAAiC,eAAe;QAChD;QACA;QACA;;QAEA;QACA,sDAAsD,+DAA+D;;QAErH;QACA;;;QAGA;QACA;;;;;;;;;;;;;AClFA;AAAA;AAAA;AAAA;AAAA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Aa,iCAAiC,EAAE,I","file":"frontend.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = \"./src/frontend/index.js\");\n","import $ from 'jquery';\r\nimport './scss/style.scss';\r\n\r\n/* (function ($) { */\r\n \"use strict\";\r\n\r\n var swiper_index = 0, $swipers = {};\r\n\r\n // Ajax load\r\n // ---------------------------------------------------------------------------\r\n\r\n function qligg_load_item_images($item, next_max_id) {\r\n\r\n var $wrap = $('.insta-gallery-list', $item),\r\n $spinner = $('.insta-gallery-spinner', $item),\r\n feed = $item.data('feed');\r\n\r\n $.ajax({\r\n url: qligg.ajax_url,\r\n type: 'post',\r\n timeout: 30000,\r\n data: {\r\n action: 'qligg_load_item_images',\r\n next_max_id: next_max_id,\r\n feed: JSON.stringify(feed)\r\n },\r\n beforeSend: function () {\r\n $spinner.show();\r\n },\r\n success: function (response) {\r\n\r\n if (response.success !== true) {\r\n $wrap.append($(response.data));\r\n $spinner.hide();\r\n return;\r\n }\r\n var $images = $(response.data);\r\n\r\n $wrap.append($images).trigger('qligg.loaded', [$images]);\r\n\r\n },\r\n complete: function () {\r\n },\r\n error: function (jqXHR, textStatus) {\r\n $spinner.hide();\r\n }\r\n });\r\n\r\n }\r\n\r\n qligg_init()\r\n\r\n export function qligg_init() {\r\n\r\n\r\n // Images\r\n // ---------------------------------------------------------------------------\r\n\r\n $('.insta-gallery-feed').on('qligg.loaded', function (e, images) {\r\n\r\n var $item = $(e.delegateTarget),\r\n $wrap = $('.insta-gallery-list', $item),\r\n $spinner = $('.insta-gallery-spinner', $item),\r\n $button = $('.insta-gallery-button.load', $item),\r\n options = $item.data('feed'),\r\n total = $(images).length,\r\n loaded = 0;\r\n\r\n\r\n ////// this breaks masonry layout \r\n ///$wrap.trigger('qligg.imagesLoaded', [images]);\r\n\r\n if (total) {\r\n $wrap.find('.insta-gallery-image').on('load loadstart', (e) => {\r\n loaded++;\r\n if (loaded >= total) {\r\n $wrap.trigger('qligg.imagesLoaded', [images]);\r\n }\r\n });\r\n }\r\n\r\n if (total < options.limit) {\r\n $spinner.hide();\r\n setTimeout(function () {\r\n $button.fadeOut();\r\n }, 300);\r\n }\r\n\r\n });\r\n\r\n // Spinner\r\n // ---------------------------------------------------------------------------\r\n\r\n $('.insta-gallery-feed').on('qligg.imagesLoaded', function (e) {\r\n\r\n var $item = $(e.delegateTarget),\r\n $spinner = $('.insta-gallery-spinner', $item);\r\n\r\n $spinner.hide();\r\n\r\n });\r\n\r\n // Gallery\r\n // ---------------------------------------------------------------------------\r\n\r\n $('.insta-gallery-feed[data-feed_layout=gallery]').on('qligg.imagesLoaded', function (e, images) {\r\n\r\n var $item = $(e.delegateTarget);\r\n\r\n $item.addClass('loaded');\r\n\r\n $(images).each(function (i, item) {\r\n setTimeout(function () {\r\n $(item).addClass('ig-image-loaded');\r\n }, 150 + (i * 30));\r\n\r\n });\r\n });\r\n\r\n // Carousel\r\n // ---------------------------------------------------------------------------\r\n\r\n $('.insta-gallery-feed[data-feed_layout=carousel]').on('qligg.imagesLoaded', function (e, images) {\r\n\r\n var $item = $(e.delegateTarget);\r\n\r\n $item.addClass('loaded');\r\n\r\n $(images).each(function (i, item) {\r\n //setTimeout(function () {\r\n $(item).addClass('ig-image-loaded');\r\n //}, 500 + (i * 50));\r\n\r\n });\r\n });\r\n\r\n $('.insta-gallery-feed[data-feed_layout=carousel]').on('qligg.imagesLoaded', function (e, images) {\r\n\r\n var $item = $(e.delegateTarget),\r\n $swiper = $('.swiper-container', $item),\r\n options = $item.data('feed');\r\n options.carousel.slides = options.carousel.slidespv;\r\n /// options.carousel.interval = options.carousel.autoplay_interval;\r\n swiper_index++;\r\n\r\n $swipers[swiper_index] = new Swiper($swiper, {\r\n //direction: 'vertical',\r\n //wrapperClass: 'insta-gallery-list',\r\n //slideClass: 'insta-gallery-item',\r\n loop: true,\r\n autoHeight: true,\r\n observer: true,\r\n observeParents: true,\r\n slidesPerView: 1,\r\n spaceBetween: 2,\r\n autoplay: options.carousel.autoplay ? {\r\n delay: parseInt(options.carousel.autoplay_interval),\r\n } : false,\r\n pagination: {\r\n el: '.swiper-pagination',\r\n dynamicBullets: true,\r\n clickable: true,\r\n type: 'bullets',\r\n },\r\n navigation: {\r\n nextEl: '.swiper-button-next',\r\n prevEl: '.swiper-button-prev',\r\n },\r\n breakpoints: {\r\n 320: {\r\n slidesPerView: 1,\r\n spaceBetween: 1,\r\n },\r\n 480: {\r\n spaceBetween: parseInt(options.spacing),\r\n slidesPerView: Math.min(2, parseInt(options.carousel.slides))\r\n },\r\n 768: {\r\n spaceBetween: parseInt(options.spacing),\r\n slidesPerView: Math.min(3, parseInt(options.carousel.slides))\r\n },\r\n 1024: {\r\n spaceBetween: parseInt(options.spacing),\r\n slidesPerView: parseInt(options.carousel.slides)\r\n },\r\n }\r\n });\r\n });\r\n\r\n // Masonry\r\n // ---------------------------------------------------------------------------\r\n\r\n $('.insta-gallery-feed[data-feed_layout=masonry]').on('qligg.imagesLoaded', function (e, images) {\r\n\r\n var $item = $(e.delegateTarget),\r\n $wrap = $('.insta-gallery-list', $item);\r\n\r\n if (!$wrap.data('masonry')) {\r\n $wrap.masonry({\r\n itemSelector: '.insta-gallery-item',\r\n isResizable: true,\r\n isAnimated: false,\r\n transitionDuration: 0,\r\n percentPosition: true,\r\n columnWidth: '.insta-gallery-item:last-child'\r\n });\r\n } else {\r\n $wrap.masonry('appended', images, false);\r\n }\r\n });\r\n\r\n\r\n $('.insta-gallery-feed[data-feed_layout=masonry]').on('layoutComplete', function (e, items) {\r\n\r\n var $item = $(e.delegateTarget);\r\n\r\n $item.addClass('loaded');\r\n\r\n $(items).each(function (i, item) {\r\n // setTimeout(function () {\r\n $(item.element).addClass('ig-image-loaded');\r\n // }, 500 + (i * 50));\r\n\r\n });\r\n });\r\n\r\n // Popup\r\n // ---------------------------------------------------------------------------\r\n $('.insta-gallery-feed').on('qligg.loaded', function (e) {\r\n\r\n var $item = $(e.delegateTarget),\r\n $wrap = $('.insta-gallery-list', $item),\r\n options = $item.data('feed');\r\n\r\n // Redirect\r\n // -------------------------------------------------------------------------\r\n $('.insta-gallery-item .insta-gallery-icon.qligg-icon-instagram', $wrap).on('click', function (e) {\r\n e.stopPropagation();\r\n });\r\n\r\n // Carousel\r\n // -------------------------------------------------------------------------\r\n //$('.insta-gallery-item', $wrap).on('mfpOpen', function (e) {\r\n //});\r\n\r\n if (!options.popup.display) {\r\n return;\r\n }\r\n\r\n $('.insta-gallery-item', $wrap).magnificPopup({\r\n type: 'inline',\r\n callbacks: {\r\n beforeOpen: function () {\r\n this.st.mainClass = this.st.mainClass + ' ' + 'qligg-mfp-wrap';\r\n },\r\n elementParse: function (item) {\r\n\r\n var media = '', profile = '', counter = '', caption = '', info = '', likes = '', date = '', comments = '';\r\n\r\n if (item.el.data('item').type && (item.el.data('item').type == 'video' || item.el.data('item').file_type == 'video')) {\r\n media = '\\n\\\r\n <video autoplay>\\n\\\r\n <source src=\"' + item.el.data('item').videos.standard + '\" type=\"video/mp4\">\\n\\\r\n </video>'\r\n } else {\r\n media = '<img src=\"' + item.el.data('item').images.standard + '\"/>'\r\n }\r\n counter = '<div class=\"mfp-icons\"><div class=\"mfp-counter\">' + (item.index + 1) + ' / ' + $('.insta-gallery-item', $wrap).length + '</div><a class=\"mfp-link\" href=\"' + item.el.data('item').link + '\" target=\"_blank\" rel=\"noopener\"><i class=\"qligg-icon-instagram\"></i>Instagram</a></div>';\r\n\r\n if (options.popup.profile) {\r\n profile = '<div class=\"mfp-user\"><img src=\"' + options.profile.profile_picture_url + '\"><a href=\"https://www.instagram.com/' + options.profile.username + '\" title=\"' + options.profile.name + '\" target=\"_blank\" rel=\"noopener\">' + options.profile.username + '</a></div>';\r\n }\r\n\r\n if (options.popup.caption) {\r\n caption = '<div class=\"mfp-caption\">' + item.el.data('item').caption + '</div>';\r\n }\r\n\r\n if (item.el.data('item').date) {\r\n date = '<div class=\"mfp-date\">' + item.el.data('item').date + '</div>';\r\n }\r\n\r\n if (item.el.data('item').comments && options.popup.comments) {\r\n comments = '<div class=\"mfp-comments\"><i class=\"qligg-icon-comment\"></i>' + item.el.data('item').comments + '</div>';\r\n }\r\n\r\n if (item.el.data('item').likes && options.popup.likes) {\r\n likes = '<div class=\"mfp-likes\"><i class=\"qligg-icon-heart\"></i>' + item.el.data('item').likes + '</div>';\r\n }\r\n\r\n if (options.popup.likes || options.popup.comments) {\r\n info = '<div class=\"mfp-info\">' + likes + comments + date + '</div>';\r\n }\r\n\r\n item.src = '<div class=\"mfp-figure ' + options.popup.align + '\">' + media + '<div class=\"mfp-close\"></div><div class=\"mfp-bottom-bar\"><div class=\"mfp-title\">' + profile + counter + caption + info + '</div></div></div>';\r\n }\r\n },\r\n gallery: {\r\n enabled: true\r\n }\r\n });\r\n\r\n });\r\n\r\n // Init\r\n // ---------------------------------------------------------------------------\r\n\r\n $('.insta-gallery-feed').on('click', '.insta-gallery-button.load', function (e) {\r\n e.preventDefault();\r\n\r\n var $item = $(e.delegateTarget);\r\n\r\n if (!$item.hasClass('loaded')) {\r\n return false;\r\n }\r\n\r\n var next_max_id = $('.insta-gallery-list .insta-gallery-item:last-child', $item).data('item').i;\r\n\r\n qligg_load_item_images($item, next_max_id);\r\n\r\n });\r\n\r\n $('.insta-gallery-feed').each(function (index, item) {\r\n\r\n var $item = $(item);\r\n\r\n if ($item.hasClass('loaded')) {\r\n return false;\r\n }\r\n\r\n qligg_load_item_images($item, 0);\r\n\r\n });\r\n\r\n // IE8\r\n // ---------------------------------------------------------------------------\r\n\r\n }\r\n \r\n if (navigator.appVersion.indexOf(\"MSIE 8.\") != -1) {\r\n document.body.className += ' ' + 'instagal-ie-8';\r\n }\r\n if (navigator.appVersion.indexOf(\"MSIE 9.\") != -1) {\r\n document.body.className += ' ' + 'instagal-ie-9';\r\n }\r\n\r\n///// })(jQuery); \r\n","// removed by extract-text-webpack-plugin","(function() { module.exports = this[\"jQuery\"]; }());"],"sourceRoot":""}
1
+ {"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///./src/frontend/index.js","webpack:///./src/frontend/scss/style.scss","webpack:///external {\"this\":\"jQuery\"}"],"names":["swiper_index","$swipers","qligg_load_item_images","$item","next_max_id","$wrap","$","$spinner","feed","data","ajax","url","qligg","ajax_url","type","timeout","action","JSON","stringify","beforeSend","show","success","response","append","hide","$images","trigger","complete","error","jqXHR","textStatus","qligg_init","on","e","images","delegateTarget","$button","options","total","length","loaded","find","target","prop","limit","setTimeout","fadeOut","addClass","each","i","item","$swiper","carousel","slides","slidespv","Swiper","loop","autoHeight","observer","observeParents","slidesPerView","spaceBetween","autoplay","delay","parseInt","autoplay_interval","pagination","el","dynamicBullets","clickable","navigation","nextEl","prevEl","breakpoints","spacing","Math","min","masonry","itemSelector","isResizable","isAnimated","transitionDuration","percentPosition","columnWidth","items","element","stopPropagation","popup","display","magnificPopup","callbacks","beforeOpen","st","mainClass","elementParse","media","profile","counter","caption","info","likes","date","comments","file_type","videos","standard","index","link","profile_picture_url","username","name","src","align","gallery","enabled","preventDefault","hasClass","navigator","appVersion","indexOf","document","body","className"],"mappings":";QAAA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA,0CAA0C,gCAAgC;QAC1E;QACA;;QAEA;QACA;QACA;QACA,wDAAwD,kBAAkB;QAC1E;QACA,iDAAiD,cAAc;QAC/D;;QAEA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,CAA8B,UAAU0D,KAAV,EAAiBxD,IAAjB,EAAuB;AAEnD,QAAI/C,KAAK,GAAGG,6CAAC,CAAC4C,IAAD,CAAb;;AAEA,QAAI/C,KAAK,CAACiH,QAAN,CAAe,QAAf,CAAJ,EAA8B;AAC5B,aAAO,KAAP;AACD;;AAEDlH,0BAAsB,CAACC,KAAD,EAAQ,CAAR,CAAtB;AAED,GAVD,EAnR2B,CA+R3B;AACA;AAED;;AAED,IAAIkH,SAAS,CAACC,UAAV,CAAqBC,OAArB,CAA6B,SAA7B,KAA2C,CAAC,CAAhD,EAAmD;AACjDC,UAAQ,CAACC,IAAT,CAAcC,SAAd,IAA2B,MAAM,eAAjC;AACD;;AACD,IAAIL,SAAS,CAACC,UAAV,CAAqBC,OAArB,CAA6B,SAA7B,KAA2C,CAAC,CAAhD,EAAmD;AACjDC,UAAQ,CAACC,IAAT,CAAcC,SAAd,IAA2B,MAAM,eAAjC;AACD,C,CAED,iB;;;;;;;;;;;AC/VA,yC;;;;;;;;;;;ACAA,aAAa,iCAAiC,EAAE,I","file":"frontend.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = \"./src/frontend/index.js\");\n","import $ from 'jquery';\r\nimport './scss/style.scss';\r\n\r\n/* (function ($) { */\r\n\"use strict\";\r\n\r\nvar swiper_index = 0, $swipers = {};\r\n\r\n// Ajax load\r\n// ---------------------------------------------------------------------------\r\n\r\nfunction qligg_load_item_images($item, next_max_id) {\r\n\r\n var $wrap = $('.insta-gallery-list', $item),\r\n $spinner = $('.insta-gallery-spinner', $item),\r\n feed = $item.data('feed');\r\n\r\n $.ajax({\r\n url: qligg.ajax_url,\r\n type: 'post',\r\n timeout: 30000,\r\n data: {\r\n action: 'qligg_load_item_images',\r\n next_max_id: next_max_id,\r\n feed: JSON.stringify(feed)\r\n },\r\n beforeSend: function () {\r\n $spinner.show();\r\n },\r\n success: function (response) {\r\n\r\n if (response.success !== true) {\r\n $wrap.append($(response.data));\r\n $spinner.hide();\r\n return;\r\n }\r\n var $images = $(response.data);\r\n\r\n $wrap.append($images).trigger('qligg.loaded', [$images]);\r\n\r\n },\r\n complete: function () {\r\n },\r\n error: function (jqXHR, textStatus) {\r\n $spinner.hide();\r\n }\r\n });\r\n\r\n}\r\n\r\nqligg_init()\r\n\r\nexport function qligg_init() {\r\n\r\n\r\n // Images\r\n // ---------------------------------------------------------------------------\r\n\r\n $('.insta-gallery-feed').on('qligg.loaded', function (e, images) {\r\n\r\n var $item = $(e.delegateTarget),\r\n $wrap = $('.insta-gallery-list', $item),\r\n $spinner = $('.insta-gallery-spinner', $item),\r\n $button = $('.insta-gallery-button.load', $item),\r\n options = $item.data('feed'),\r\n total = $(images).length,\r\n loaded = 0;\r\n\r\n\r\n ////// this breaks masonry layout \r\n ///$wrap.trigger('qligg.imagesLoaded', [images]);\r\n\r\n if (total) {\r\n $wrap.find('.insta-gallery-image').on('load loadstart', (e) => {\r\n if (e.type == 'loadstart' && $(e.target).prop('tagName') == 'VIDEO') {\r\n loaded++;\r\n } else\r\n if (e.type == 'load' && $(e.target).prop('tagName') == 'IMG') {\r\n loaded++;\r\n\r\n }\r\n if (loaded >= total) {\r\n $wrap.trigger('qligg.imagesLoaded', [images]);\r\n }\r\n });\r\n }\r\n\r\n if (total < options.limit) {\r\n $spinner.hide();\r\n setTimeout(function () {\r\n $button.fadeOut();\r\n }, 300);\r\n }\r\n\r\n });\r\n\r\n // Spinner\r\n // ---------------------------------------------------------------------------\r\n\r\n $('.insta-gallery-feed').on('qligg.imagesLoaded', function (e) {\r\n\r\n var $item = $(e.delegateTarget),\r\n $spinner = $('.insta-gallery-spinner', $item);\r\n\r\n $spinner.hide();\r\n\r\n });\r\n\r\n // Gallery\r\n // ---------------------------------------------------------------------------\r\n\r\n $('.insta-gallery-feed[data-feed_layout=gallery]').on('qligg.imagesLoaded', function (e, images) {\r\n\r\n var $item = $(e.delegateTarget);\r\n\r\n $item.addClass('loaded');\r\n\r\n $(images).each(function (i, item) {\r\n setTimeout(function () {\r\n $(item).addClass('ig-image-loaded');\r\n }, 150 + (i * 30));\r\n\r\n });\r\n });\r\n\r\n // Carousel\r\n // ---------------------------------------------------------------------------\r\n\r\n $('.insta-gallery-feed[data-feed_layout=carousel]').on('qligg.imagesLoaded', function (e, images) {\r\n\r\n var $item = $(e.delegateTarget);\r\n\r\n $item.addClass('loaded');\r\n\r\n $(images).each(function (i, item) {\r\n //setTimeout(function () {\r\n $(item).addClass('ig-image-loaded');\r\n //}, 500 + (i * 50));\r\n\r\n });\r\n });\r\n\r\n $('.insta-gallery-feed[data-feed_layout=carousel]').on('qligg.imagesLoaded', function (e, images) {\r\n\r\n var $item = $(e.delegateTarget),\r\n $swiper = $('.swiper-container', $item),\r\n options = $item.data('feed');\r\n options.carousel.slides = options.carousel.slidespv;\r\n /// options.carousel.interval = options.carousel.autoplay_interval;\r\n swiper_index++;\r\n\r\n $swipers[swiper_index] = new Swiper($swiper, {\r\n //direction: 'vertical',\r\n //wrapperClass: 'insta-gallery-list',\r\n //slideClass: 'insta-gallery-item',\r\n loop: true,\r\n autoHeight: true,\r\n observer: true,\r\n observeParents: true,\r\n slidesPerView: 1,\r\n spaceBetween: 2,\r\n autoplay: options.carousel.autoplay ? {\r\n delay: parseInt(options.carousel.autoplay_interval),\r\n } : false,\r\n pagination: {\r\n el: '.swiper-pagination',\r\n dynamicBullets: true,\r\n clickable: true,\r\n type: 'bullets',\r\n },\r\n navigation: {\r\n nextEl: '.swiper-button-next',\r\n prevEl: '.swiper-button-prev',\r\n },\r\n breakpoints: {\r\n 320: {\r\n slidesPerView: 1,\r\n spaceBetween: 1,\r\n },\r\n 480: {\r\n spaceBetween: parseInt(options.spacing),\r\n slidesPerView: Math.min(2, parseInt(options.carousel.slides))\r\n },\r\n 768: {\r\n spaceBetween: parseInt(options.spacing),\r\n slidesPerView: Math.min(3, parseInt(options.carousel.slides))\r\n },\r\n 1024: {\r\n spaceBetween: parseInt(options.spacing),\r\n slidesPerView: parseInt(options.carousel.slides)\r\n },\r\n }\r\n });\r\n });\r\n\r\n // Masonry\r\n // ---------------------------------------------------------------------------\r\n\r\n $('.insta-gallery-feed[data-feed_layout=masonry]').on('qligg.imagesLoaded', function (e, images) {\r\n\r\n var $item = $(e.delegateTarget),\r\n $wrap = $('.insta-gallery-list', $item);\r\n\r\n if (!$wrap.data('masonry')) {\r\n $wrap.masonry({\r\n itemSelector: '.insta-gallery-item',\r\n isResizable: true,\r\n isAnimated: false,\r\n transitionDuration: 0,\r\n percentPosition: true,\r\n columnWidth: '.insta-gallery-item:last-child'\r\n });\r\n } else {\r\n $wrap.masonry('appended', images, false);\r\n }\r\n });\r\n\r\n\r\n $('.insta-gallery-feed[data-feed_layout=masonry]').on('layoutComplete', function (e, items) {\r\n\r\n var $item = $(e.delegateTarget);\r\n\r\n $item.addClass('loaded');\r\n\r\n $(items).each(function (i, item) {\r\n // setTimeout(function () {\r\n $(item.element).addClass('ig-image-loaded');\r\n // }, 500 + (i * 50));\r\n\r\n });\r\n });\r\n\r\n // Popup\r\n // ---------------------------------------------------------------------------\r\n $('.insta-gallery-feed').on('qligg.loaded', function (e) {\r\n\r\n var $item = $(e.delegateTarget),\r\n $wrap = $('.insta-gallery-list', $item),\r\n options = $item.data('feed');\r\n\r\n // Redirect\r\n // -------------------------------------------------------------------------\r\n $('.insta-gallery-item .insta-gallery-icon.qligg-icon-instagram', $wrap).on('click', function (e) {\r\n e.stopPropagation();\r\n });\r\n\r\n // Carousel\r\n // -------------------------------------------------------------------------\r\n //$('.insta-gallery-item', $wrap).on('mfpOpen', function (e) {\r\n //});\r\n\r\n if (!options.popup.display) {\r\n return;\r\n }\r\n\r\n $('.insta-gallery-item', $wrap).magnificPopup({\r\n type: 'inline',\r\n callbacks: {\r\n beforeOpen: function () {\r\n this.st.mainClass = this.st.mainClass + ' ' + 'qligg-mfp-wrap';\r\n },\r\n elementParse: function (item) {\r\n\r\n var media = '', profile = '', counter = '', caption = '', info = '', likes = '', date = '', comments = '';\r\n\r\n if (item.el.data('item').type && (item.el.data('item').type == 'video' || item.el.data('item').file_type == 'video')) {\r\n media = '\\n\\\r\n <video autoplay>\\n\\\r\n <source src=\"' + item.el.data('item').videos.standard + '\" type=\"video/mp4\">\\n\\\r\n </video>'\r\n } else {\r\n media = '<img src=\"' + item.el.data('item').images.standard + '\"/>'\r\n }\r\n counter = '<div class=\"mfp-icons\"><div class=\"mfp-counter\">' + (item.index + 1) + ' / ' + $('.insta-gallery-item', $wrap).length + '</div><a class=\"mfp-link\" href=\"' + item.el.data('item').link + '\" target=\"_blank\" rel=\"noopener\"><i class=\"qligg-icon-instagram\"></i>Instagram</a></div>';\r\n\r\n if (options.popup.profile) {\r\n profile = '<div class=\"mfp-user\"><img src=\"' + options.profile.profile_picture_url + '\"><a href=\"https://www.instagram.com/' + options.profile.username + '\" title=\"' + options.profile.name + '\" target=\"_blank\" rel=\"noopener\">' + options.profile.username + '</a></div>';\r\n }\r\n\r\n if (options.popup.caption) {\r\n caption = '<div class=\"mfp-caption\">' + item.el.data('item').caption + '</div>';\r\n }\r\n\r\n if (item.el.data('item').date) {\r\n date = '<div class=\"mfp-date\">' + item.el.data('item').date + '</div>';\r\n }\r\n\r\n if (item.el.data('item').comments && options.popup.comments) {\r\n comments = '<div class=\"mfp-comments\"><i class=\"qligg-icon-comment\"></i>' + item.el.data('item').comments + '</div>';\r\n }\r\n\r\n if (item.el.data('item').likes && options.popup.likes) {\r\n likes = '<div class=\"mfp-likes\"><i class=\"qligg-icon-heart\"></i>' + item.el.data('item').likes + '</div>';\r\n }\r\n\r\n if (options.popup.likes || options.popup.comments) {\r\n info = '<div class=\"mfp-info\">' + likes + comments + date + '</div>';\r\n }\r\n\r\n item.src = '<div class=\"mfp-figure ' + options.popup.align + '\">' + media + '<div class=\"mfp-close\"></div><div class=\"mfp-bottom-bar\"><div class=\"mfp-title\">' + profile + counter + caption + info + '</div></div></div>';\r\n }\r\n },\r\n gallery: {\r\n enabled: true\r\n }\r\n });\r\n\r\n });\r\n\r\n // Init\r\n // ---------------------------------------------------------------------------\r\n\r\n $('.insta-gallery-feed').on('click', '.insta-gallery-button.load', function (e) {\r\n e.preventDefault();\r\n\r\n var $item = $(e.delegateTarget);\r\n\r\n if (!$item.hasClass('loaded')) {\r\n return false;\r\n }\r\n\r\n var next_max_id = $('.insta-gallery-list .insta-gallery-item:last-child', $item).data('item').i;\r\n\r\n qligg_load_item_images($item, next_max_id);\r\n\r\n });\r\n\r\n $('.insta-gallery-feed').each(function (index, item) {\r\n\r\n var $item = $(item);\r\n\r\n if ($item.hasClass('loaded')) {\r\n return false;\r\n }\r\n\r\n qligg_load_item_images($item, 0);\r\n\r\n });\r\n\r\n // IE8\r\n // ---------------------------------------------------------------------------\r\n\r\n}\r\n\r\nif (navigator.appVersion.indexOf(\"MSIE 8.\") != -1) {\r\n document.body.className += ' ' + 'instagal-ie-8';\r\n}\r\nif (navigator.appVersion.indexOf(\"MSIE 9.\") != -1) {\r\n document.body.className += ' ' + 'instagal-ie-9';\r\n}\r\n\r\n///// })(jQuery); \r\n","// removed by extract-text-webpack-plugin","(function() { module.exports = this[\"jQuery\"]; }());"],"sourceRoot":""}
includes/api/api.php CHANGED
@@ -19,11 +19,11 @@ abstract class QLIGG_API
19
  return $qliggAPI->FEED->setupMediaItems($data, $last_id);
20
  }
21
 
22
- function setupPersonalMediaItems($data, $last_id = null)
23
  {
24
  global $qliggAPI;
25
  return $qliggAPI->FEED->setupPersonalMediaItems($data, $last_id);
26
- }
27
 
28
  function validateResponse($json = null)
29
  {
19
  return $qliggAPI->FEED->setupMediaItems($data, $last_id);
20
  }
21
 
22
+ /* function setupPersonalMediaItems($data, $last_id = null)
23
  {
24
  global $qliggAPI;
25
  return $qliggAPI->FEED->setupPersonalMediaItems($data, $last_id);
26
+ } */
27
 
28
  function validateResponse($json = null)
29
  {
includes/api/apiBusiness.php CHANGED
@@ -21,6 +21,16 @@ class QLIGG_API_Business extends QLIGG_API
21
  return self::$_instance;
22
  }
23
 
 
 
 
 
 
 
 
 
 
 
24
  function getAccessTokenLink()
25
  {
26
 
@@ -118,7 +128,7 @@ class QLIGG_API_Business extends QLIGG_API
118
  'access_token' => $account['access_token']
119
  ));
120
 
121
-
122
  return (array) $response;
123
  }
124
  }
21
  return self::$_instance;
22
  }
23
 
24
+ function renewAccessToken($access_token, $renew_count = 0)
25
+ {
26
+
27
+ global $qliggAPI;
28
+
29
+ $url = "https://socialfeed.quadlayers.com/renew_facebook.php?access_token={$access_token}&renew_count={$renew_count}";
30
+
31
+ return (array) $qliggAPI->BASIC->validate_response(wp_remote_get($url));
32
+ }
33
+
34
  function getAccessTokenLink()
35
  {
36
 
128
  'access_token' => $account['access_token']
129
  ));
130
 
131
+
132
  return (array) $response;
133
  }
134
  }
includes/api/apiFeed.php CHANGED
@@ -95,7 +95,7 @@ class QLIGG_API_Feed
95
  return 'image';
96
  }
97
 
98
- function setupPersonalMediaItems($data, $last_id = null)
99
  {
100
 
101
  static $load = false;
@@ -154,7 +154,7 @@ class QLIGG_API_Feed
154
 
155
  return $instagram_items;
156
  }
157
-
158
  function getItemMediaURL(array $item = [])
159
  {
160
  if (isset($item['media_type'])) {
95
  return 'image';
96
  }
97
 
98
+ /* function setupPersonalMediaItems($data, $last_id = null)
99
  {
100
 
101
  static $load = false;
154
 
155
  return $instagram_items;
156
  }
157
+ */
158
  function getItemMediaURL(array $item = [])
159
  {
160
  if (isset($item['media_type'])) {
includes/api/apiPersonal.php CHANGED
@@ -21,6 +21,16 @@ class QLIGG_API_Personal extends QLIGG_API
21
  return self::$_instance;
22
  }
23
 
 
 
 
 
 
 
 
 
 
 
24
  function getAccessTokenLink()
25
  {
26
 
21
  return self::$_instance;
22
  }
23
 
24
+ function renewAccessToken($access_token, $renew_count = 0)
25
+ {
26
+
27
+ global $qliggAPI;
28
+
29
+ $url = "https://socialfeed.quadlayers.com/renew_instagram.php?access_token={$access_token}&renew_count={$renew_count}";
30
+
31
+ return (array) $qliggAPI->BASIC->validate_response(wp_remote_get($url));
32
+ }
33
+
34
  function getAccessTokenLink()
35
  {
36
 
includes/controllers/AccountController.php CHANGED
@@ -26,7 +26,8 @@ class QLIGG_Account_Controller extends QLIGG_Controller
26
 
27
  function init()
28
  {
29
- add_action('admin_init', array($this, 'add_account'));
 
30
  add_action('wp_ajax_qligg_delete_account', array($this, 'ajax_delete_account'));
31
  add_action('wp_ajax_qligg_renew_access_token', array($this, 'ajax_renew_access_token'));
32
  add_action('admin_enqueue_scripts', array($this, 'add_js'));
@@ -48,6 +49,40 @@ class QLIGG_Account_Controller extends QLIGG_Controller
48
  include(QLIGG_PLUGIN_DIR . '/includes/view/backend/pages/accounts.php');
49
  }
50
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
51
  function ajax_renew_access_token()
52
  {
53
  if (!isset($_REQUEST['account_id'])) {
@@ -55,16 +90,16 @@ class QLIGG_Account_Controller extends QLIGG_Controller
55
  }
56
  $account_model = new QLIGG_Account();
57
 
58
- if ($account = $account_model->renew_acount_token(sanitize_key($_REQUEST['account_id']))) {
59
-
60
- if(isset($account['id'])){
61
- parent::success_ajax(esc_html__('The token has been updated successfully', 'insta-gallery'));
62
  }
63
 
64
- if(isset($account['error']['message'])){
65
  parent::error_ajax(esc_html($account['error']['message']));
66
  }
67
- if(isset($account['message'])){
68
  parent::error_ajax(esc_html($account['message']));
69
  }
70
  }
@@ -72,14 +107,45 @@ class QLIGG_Account_Controller extends QLIGG_Controller
72
  parent::error_ajax(esc_html__('Unknow error', 'insta-gallery'));
73
  }
74
 
75
-
76
- function add_account()
77
  {
78
 
79
- if (isset($_REQUEST['accounts'][0]['id'])) {
 
 
 
 
 
80
 
81
  $account_model = new QLIGG_Account();
82
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
83
  foreach ($_REQUEST['accounts'] as $account_data) {
84
 
85
  if (
@@ -88,26 +154,7 @@ class QLIGG_Account_Controller extends QLIGG_Controller
88
  isset($account_data['token_type']) &&
89
  isset($account_data['expires_in'])
90
  ) {
91
-
92
- delete_transient("insta_gallery_v2_user_profile_{$account_data['id']}");
93
-
94
- $feed_model = new QLIGG_Feed();
95
-
96
- $tk = "%%insta_gallery_v2_user_media_{$account_data['id']}_%%";
97
-
98
- $feed_model->clear_cache($tk);
99
-
100
- $id = sanitize_text_field($account_data['id']);
101
- $access_token = sanitize_text_field($account_data['access_token']);
102
- $token_type = sanitize_text_field($account_data['token_type']);
103
- $expires_in = sanitize_text_field($account_data['expires_in']);
104
-
105
- $account_model->add_account(array(
106
- 'id' => $id,
107
- 'access_token' => $access_token,
108
- 'token_type' => $token_type,
109
- 'expires_in' => $expires_in
110
- ));
111
  }
112
  }
113
 
@@ -144,8 +191,8 @@ class QLIGG_Account_Controller extends QLIGG_Controller
144
 
145
  function add_js()
146
  {
147
- $admin = include_once(QLIGG_PLUGIN_DIR. 'assets/backend/js/admin.asset.php');
148
- wp_register_script('qligg-admin-account', plugins_url('/assets/backend/js/admin.js', QLIGG_PLUGIN_FILE), $admin['dependencies'], $admin['version'] , true);
149
  wp_localize_script('qligg-admin-account', 'qligg_account', array(
150
  'nonce' => array(
151
  'qligg_add_account' => wp_create_nonce('qligg_add_account'),
26
 
27
  function init()
28
  {
29
+ add_action('admin_init', array($this, 'init_add_account'));
30
+ add_action('wp_ajax_qligg_add_account', array($this, 'ajax_add_account'));
31
  add_action('wp_ajax_qligg_delete_account', array($this, 'ajax_delete_account'));
32
  add_action('wp_ajax_qligg_renew_access_token', array($this, 'ajax_renew_access_token'));
33
  add_action('admin_enqueue_scripts', array($this, 'add_js'));
49
  include(QLIGG_PLUGIN_DIR . '/includes/view/backend/pages/accounts.php');
50
  }
51
 
52
+ function ajax_add_account()
53
+ {
54
+ $account_model = new QLIGG_Account();
55
+
56
+ $account_data = [
57
+ 'id' => sanitize_text_field($_REQUEST['account_data']['id']),
58
+ 'access_token' => sanitize_text_field($_REQUEST['account_data']['access_token'])
59
+ ];
60
+
61
+ if ($access_token = $account_model->renew_access_token($_REQUEST['account_data']['access_token'])) {
62
+
63
+ if (substr($access_token['access_token'], 0, 4) === 'IGQV') {
64
+ $account_data['token_type'] = 'PERSONAL';
65
+ } else {
66
+ $account_data['token_type'] = 'BUSINESS';
67
+ }
68
+
69
+ $account_data['expires_in'] = intval($access_token['expires_in']);
70
+
71
+ $account = $this->add_account($account_data);
72
+
73
+ if (isset($account['id'])) {
74
+ parent::success_ajax(esc_html__('The token has been updated successfully', 'insta-gallery'));
75
+ }
76
+
77
+ if (isset($account['error']['message'])) {
78
+ parent::error_ajax(esc_html($account['error']['message']));
79
+ }
80
+ if (isset($account['message'])) {
81
+ parent::error_ajax(esc_html($account['message']));
82
+ }
83
+ }
84
+ }
85
+
86
  function ajax_renew_access_token()
87
  {
88
  if (!isset($_REQUEST['account_id'])) {
90
  }
91
  $account_model = new QLIGG_Account();
92
 
93
+ if ($account = $account_model->renew_account_token(sanitize_key($_REQUEST['account_id']))) {
94
+
95
+ if (isset($account['id'])) {
96
+ parent::success_ajax(esc_html__('The token has been updated successfully', 'insta-gallery'));
97
  }
98
 
99
+ if (isset($account['error']['message'])) {
100
  parent::error_ajax(esc_html($account['error']['message']));
101
  }
102
+ if (isset($account['message'])) {
103
  parent::error_ajax(esc_html($account['message']));
104
  }
105
  }
107
  parent::error_ajax(esc_html__('Unknow error', 'insta-gallery'));
108
  }
109
 
110
+ function add_account(array $account_data = [])
 
111
  {
112
 
113
+ if (
114
+ isset($account_data['id']) &&
115
+ isset($account_data['access_token']) &&
116
+ isset($account_data['token_type']) &&
117
+ isset($account_data['expires_in'])
118
+ ) {
119
 
120
  $account_model = new QLIGG_Account();
121
 
122
+ delete_transient("insta_gallery_v2_user_profile_{$account_data['id']}");
123
+
124
+ $feed_model = new QLIGG_Feed();
125
+
126
+ $tk = "%%insta_gallery_v2_user_media_{$account_data['id']}_%%";
127
+
128
+ $feed_model->clear_cache($tk);
129
+
130
+ $id = sanitize_text_field($account_data['id']);
131
+ $access_token = sanitize_text_field($account_data['access_token']);
132
+ $token_type = sanitize_text_field($account_data['token_type']);
133
+ $expires_in = sanitize_text_field($account_data['expires_in']);
134
+
135
+ return $account_model->add_account(array(
136
+ 'id' => $id,
137
+ 'access_token' => $access_token,
138
+ 'token_type' => $token_type,
139
+ 'expires_in' => $expires_in
140
+ ));
141
+ }
142
+ }
143
+
144
+ function init_add_account()
145
+ {
146
+
147
+ if (isset($_REQUEST['accounts'][0]['id'])) {
148
+
149
  foreach ($_REQUEST['accounts'] as $account_data) {
150
 
151
  if (
154
  isset($account_data['token_type']) &&
155
  isset($account_data['expires_in'])
156
  ) {
157
+ $this->add_account($account_data);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
158
  }
159
  }
160
 
191
 
192
  function add_js()
193
  {
194
+ $admin = include_once(QLIGG_PLUGIN_DIR . 'assets/backend/js/admin.asset.php');
195
+ wp_register_script('qligg-admin-account', plugins_url('/assets/backend/js/admin.js', QLIGG_PLUGIN_FILE), $admin['dependencies'], $admin['version'], true);
196
  wp_localize_script('qligg-admin-account', 'qligg_account', array(
197
  'nonce' => array(
198
  'qligg_add_account' => wp_create_nonce('qligg_add_account'),
includes/helpers.php CHANGED
@@ -186,7 +186,7 @@ function qligg_get_user_media($feed, $last_id = null, $after = null)
186
  set_transient($tk, $response, absint($settings['insta_reset']) * HOUR_IN_SECONDS);
187
  }
188
 
189
- $feeds = $qliggAPI->PERSONAL->setupPersonalMediaItems($response['data'], $last_id);
190
 
191
  if (!$last_id) {
192
  return $feeds;
186
  set_transient($tk, $response, absint($settings['insta_reset']) * HOUR_IN_SECONDS);
187
  }
188
 
189
+ $feeds = $qliggAPI->PERSONAL->setupMediaItems($response['data'], $last_id);
190
 
191
  if (!$last_id) {
192
  return $feeds;
includes/models/Account.php CHANGED
@@ -43,14 +43,22 @@ class QLIGG_Account extends QLIGG_Model
43
  $this->update_account($account);
44
  }
45
 
46
- function validate_token($account)
47
  {
48
 
49
  global $qliggAPI;
50
 
51
- $url = "https://socialfeed.quadlayers.com/renew.php?access_token={$account['access_token']}&renew_count={$account['renew_count']}";
 
 
 
 
 
 
 
 
52
 
53
- $response = (array) $qliggAPI->BASIC->validate_response(wp_remote_get($url));
54
 
55
  if (isset($response['error']) || !isset($response['expires_in']) || !isset($response['access_token'])) {
56
  $this->renew_account_fail($account);
@@ -71,7 +79,7 @@ class QLIGG_Account extends QLIGG_Model
71
  }
72
  }
73
 
74
- function renew_acount_token($acount_id)
75
  {
76
  $account = $this->get_account($acount_id);
77
  if (!$this->is_about_to_expire($account)) {
@@ -91,9 +99,9 @@ class QLIGG_Account extends QLIGG_Model
91
  if ($account['renew_count'] <= -3) {
92
  return false;
93
  }
94
- if (($account['expiration_date'] - strtotime(current_time('mysql'))) / DAY_IN_SECONDS <= 10) {
95
  return true;
96
- }
97
 
98
  return false;
99
  }
43
  $this->update_account($account);
44
  }
45
 
46
+ function renew_access_token($access_token, $renew_count = 0)
47
  {
48
 
49
  global $qliggAPI;
50
 
51
+ if (substr($access_token, 0, 4) === 'IGQV') {
52
+ return $qliggAPI->PERSONAL->renewAccessToken($access_token, $renew_count);
53
+ }
54
+
55
+ return $qliggAPI->BUSINESS->renewAccessToken($access_token, $renew_count);
56
+ }
57
+
58
+ function validate_token($account)
59
+ {
60
 
61
+ $response = $this->renew_access_token($account['access_token'], $account['renew_count']);
62
 
63
  if (isset($response['error']) || !isset($response['expires_in']) || !isset($response['access_token'])) {
64
  $this->renew_account_fail($account);
79
  }
80
  }
81
 
82
+ function renew_account_token($acount_id)
83
  {
84
  $account = $this->get_account($acount_id);
85
  if (!$this->is_about_to_expire($account)) {
99
  if ($account['renew_count'] <= -3) {
100
  return false;
101
  }
102
+ if (($account['expiration_date'] - strtotime(current_time('mysql'))) / DAY_IN_SECONDS <= 10) {
103
  return true;
104
+ }
105
 
106
  return false;
107
  }
includes/view/backend/pages/accounts.php CHANGED
@@ -16,8 +16,8 @@
16
  </a>
17
  <!-- <span style="float: none; margin-top: 0;" class="spinner"></span> -->
18
  <a style="margin: 0 30px" target="_blank" href="https://quadlayers.com/documentation/instagram-feed-gallery/api/business/?utm_source=qligg_admin"><?php esc_html_e('Create business account', 'insta-gallery'); ?></a>
19
- <!-- <a id="qligg-add-token" href="javascript:;"><?php esc_html_e('Button not working?', 'insta-gallery'); ?></a> -->
20
- <span class="qligg-premium-field">
21
  <span class="description hidden"><small><?php esc_html_e('Multiple feeds are only allowed in the premium version.', 'insta-gallery'); ?></small></span>
22
  </span>
23
  </p>
16
  </a>
17
  <!-- <span style="float: none; margin-top: 0;" class="spinner"></span> -->
18
  <a style="margin: 0 30px" target="_blank" href="https://quadlayers.com/documentation/instagram-feed-gallery/api/business/?utm_source=qligg_admin"><?php esc_html_e('Create business account', 'insta-gallery'); ?></a>
19
+ <!-- <a id="qligg-add-token" href="javascript:;"><?php esc_html_e('Button not working?', 'insta-gallery'); ?></a>
20
+ --> <span class="qligg-premium-field">
21
  <span class="description hidden"><small><?php esc_html_e('Multiple feeds are only allowed in the premium version.', 'insta-gallery'); ?></small></span>
22
  </span>
23
  </p>
insta-gallery.php CHANGED
@@ -4,7 +4,7 @@
4
  * Plugin Name: Social Feed Gallery
5
  * Plugin URI: https://quadlayers.com/portfolio/instagram-feed-gallery/
6
  * Description: Display beautiful and responsive galleries on your website from your Instagram feed account.
7
- * Version: 3.1.8
8
  * Author: QuadLayers
9
  * Author URI: https://quadlayers.com
10
  * License: GPLv3
@@ -19,7 +19,7 @@ if (!defined('QLIGG_PLUGIN_NAME')) {
19
  define('QLIGG_PLUGIN_NAME', 'Social Feed Gallery');
20
  }
21
  if (!defined('QLIGG_PLUGIN_VERSION')) {
22
- define('QLIGG_PLUGIN_VERSION', '3.1.8');
23
  }
24
  if (!defined('QLIGG_PLUGIN_FILE')) {
25
  define('QLIGG_PLUGIN_FILE', __FILE__);
4
  * Plugin Name: Social Feed Gallery
5
  * Plugin URI: https://quadlayers.com/portfolio/instagram-feed-gallery/
6
  * Description: Display beautiful and responsive galleries on your website from your Instagram feed account.
7
+ * Version: 3.1.9
8
  * Author: QuadLayers
9
  * Author URI: https://quadlayers.com
10
  * License: GPLv3
19
  define('QLIGG_PLUGIN_NAME', 'Social Feed Gallery');
20
  }
21
  if (!defined('QLIGG_PLUGIN_VERSION')) {
22
+ define('QLIGG_PLUGIN_VERSION', '3.1.9');
23
  }
24
  if (!defined('QLIGG_PLUGIN_FILE')) {
25
  define('QLIGG_PLUGIN_FILE', __FILE__);
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://quadlayers.com/portfolio/instagram-gallery/
4
  Tags: Instagram, Instagram feed, Instagram gallery, Instagram photos, Instagram widget, Instagram pictures
5
  Requires at least: 3.4
6
  Tested up to: 5.6
7
- Stable tag: 3.1.8
8
  License: GPLv3
9
  License URI: https://www.gnu.org/licenses/gpl-3.0.html
10
 
@@ -105,6 +105,10 @@ There may be some other plugins(like: fancybox, elementor) which also uses image
105
 
106
  == Changelog ==
107
 
 
 
 
 
108
  = 3.1.8 =
109
  * Fix. username fix in profile button
110
 
4
  Tags: Instagram, Instagram feed, Instagram gallery, Instagram photos, Instagram widget, Instagram pictures
5
  Requires at least: 3.4
6
  Tested up to: 5.6
7
+ Stable tag: 3.1.9
8
  License: GPLv3
9
  License URI: https://www.gnu.org/licenses/gpl-3.0.html
10
 
105
 
106
  == Changelog ==
107
 
108
+ = 3.1.9 =
109
+ * Fix. Instagram account feed video
110
+ * Fix. firefox masonry
111
+
112
  = 3.1.8 =
113
  * Fix. username fix in profile button
114