WooCommerce Wishlist Plugin - Version 1.30.0

Version Description

Release Date - 09 January 2022

  • WooCommerce 6.0 support
  • Updated integration with WooCommerce Product Add-Ons Ultimate plugin
  • Fixed custom AJAX endpoint issue for some customized WordPress setups
Download this release

Release Info

Developer templateinvaders
Plugin Icon 128x128 WooCommerce Wishlist Plugin
Version 1.30.0
Comparing to
See all releases

Code changes from version 1.29.0 to 1.30.0

assets/css/admin-form-rtl.min.css CHANGED
@@ -1,6 +1,6 @@
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
- * @version 1.29.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  .tiwlform-number-container{display:inline-block;margin:2px;position:relative;vertical-align:middle}
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
+ * @version 1.30.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  .tiwlform-number-container{display:inline-block;margin:2px;position:relative;vertical-align:middle}
assets/css/admin-form.min.css CHANGED
@@ -1,6 +1,6 @@
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
- * @version 1.29.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  .tiwlform-number-container{display:inline-block;margin:2px;position:relative;vertical-align:middle}
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
+ * @version 1.30.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  .tiwlform-number-container{display:inline-block;margin:2px;position:relative;vertical-align:middle}
assets/css/admin-rtl.min.css CHANGED
@@ -1,6 +1,6 @@
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
- * @version 1.29.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  *{-webkit-box-sizing:border-box;box-sizing:border-box}
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
+ * @version 1.30.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  *{-webkit-box-sizing:border-box;box-sizing:border-box}
assets/css/admin-setup-rtl.min.css CHANGED
@@ -1,6 +1,6 @@
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
- * @version 1.29.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  html{background:#f6f3ed}
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
+ * @version 1.30.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  html{background:#f6f3ed}
assets/css/admin-setup.min.css CHANGED
@@ -1,6 +1,6 @@
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
- * @version 1.29.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  html{background:#f6f3ed}
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
+ * @version 1.30.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  html{background:#f6f3ed}
assets/css/admin.min.css CHANGED
@@ -1,6 +1,6 @@
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
- * @version 1.29.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  *{-webkit-box-sizing:border-box;box-sizing:border-box}
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
+ * @version 1.30.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  *{-webkit-box-sizing:border-box;box-sizing:border-box}
assets/css/public-rtl.min.css CHANGED
@@ -1,6 +1,6 @@
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
- * @version 1.29.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  .tinv-wishlist form,.tinv-wishlist p:last-child,.tinv-wishlist table{margin-bottom:0}
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
+ * @version 1.30.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  .tinv-wishlist form,.tinv-wishlist p:last-child,.tinv-wishlist table{margin-bottom:0}
assets/css/public.min.css CHANGED
@@ -1,6 +1,6 @@
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
- * @version 1.29.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  .tinv-wishlist form,.tinv-wishlist p:last-child,.tinv-wishlist table{margin-bottom:0}
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
+ * @version 1.30.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  .tinv-wishlist form,.tinv-wishlist p:last-child,.tinv-wishlist table{margin-bottom:0}
assets/css/theme-rtl.min.css CHANGED
@@ -1,6 +1,6 @@
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
- * @version 1.29.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  .tinv-wishlist,.tinv-wishlist input,.tinv-wishlist select,.tinv-wishlist textarea,.tinv-wishlist button,.tinv-wishlist input[type=button],.tinv-wishlist input[type=reset],.tinv-wishlist input[type=submit]{font-family:Georgia,serif;font-size:14px;font-weight:400;text-transform:none;line-height:1.75}
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
+ * @version 1.30.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  .tinv-wishlist,.tinv-wishlist input,.tinv-wishlist select,.tinv-wishlist textarea,.tinv-wishlist button,.tinv-wishlist input[type=button],.tinv-wishlist input[type=reset],.tinv-wishlist input[type=submit]{font-family:Georgia,serif;font-size:14px;font-weight:400;text-transform:none;line-height:1.75}
assets/css/theme.min.css CHANGED
@@ -1,6 +1,6 @@
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
- * @version 1.29.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  .tinv-wishlist,.tinv-wishlist input,.tinv-wishlist select,.tinv-wishlist textarea,.tinv-wishlist button,.tinv-wishlist input[type=button],.tinv-wishlist input[type=reset],.tinv-wishlist input[type=submit]{font-family:Georgia,serif;font-size:14px;font-weight:400;text-transform:none;line-height:1.75}
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
+ * @version 1.30.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  .tinv-wishlist,.tinv-wishlist input,.tinv-wishlist select,.tinv-wishlist textarea,.tinv-wishlist button,.tinv-wishlist input[type=button],.tinv-wishlist input[type=reset],.tinv-wishlist input[type=submit]{font-family:Georgia,serif;font-size:14px;font-weight:400;text-transform:none;line-height:1.75}
assets/css/webfont-rtl.min.css CHANGED
@@ -1,6 +1,6 @@
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
- * @version 1.29.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  @font-face{font-family:"tinvwl-webfont";font-display:block;src:url("../fonts/tinvwl-webfont.eot?ver=xu2uyi");src:url("../fonts/tinvwl-webfont.eot?ver=xu2uyi#iefix") format("embedded-opentype"),url("../fonts/tinvwl-webfont.woff2?ver=xu2uyi") format("woff2"),url("../fonts/tinvwl-webfont.woff?ver=xu2uyi") format("woff"),url("../fonts/tinvwl-webfont.ttf?ver=xu2uyi") format("truetype"),url("../fonts/tinvwl-webfont.svg?ver=xu2uyi#tinvwl-webfont") format("svg");font-weight:normal;font-style:normal}
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
+ * @version 1.30.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  @font-face{font-family:"tinvwl-webfont";font-display:block;src:url("../fonts/tinvwl-webfont.eot?ver=xu2uyi");src:url("../fonts/tinvwl-webfont.eot?ver=xu2uyi#iefix") format("embedded-opentype"),url("../fonts/tinvwl-webfont.woff2?ver=xu2uyi") format("woff2"),url("../fonts/tinvwl-webfont.woff?ver=xu2uyi") format("woff"),url("../fonts/tinvwl-webfont.ttf?ver=xu2uyi") format("truetype"),url("../fonts/tinvwl-webfont.svg?ver=xu2uyi#tinvwl-webfont") format("svg");font-weight:normal;font-style:normal}
assets/css/webfont.min.css CHANGED
@@ -1,6 +1,6 @@
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
- * @version 1.29.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  @font-face{font-family:"tinvwl-webfont";font-display:block;src:url("../fonts/tinvwl-webfont.eot?ver=xu2uyi");src:url("../fonts/tinvwl-webfont.eot?ver=xu2uyi#iefix") format("embedded-opentype"),url("../fonts/tinvwl-webfont.woff2?ver=xu2uyi") format("woff2"),url("../fonts/tinvwl-webfont.woff?ver=xu2uyi") format("woff"),url("../fonts/tinvwl-webfont.ttf?ver=xu2uyi") format("truetype"),url("../fonts/tinvwl-webfont.svg?ver=xu2uyi#tinvwl-webfont") format("svg");font-weight:normal;font-style:normal}
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
+ * @version 1.30.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  @font-face{font-family:"tinvwl-webfont";font-display:block;src:url("../fonts/tinvwl-webfont.eot?ver=xu2uyi");src:url("../fonts/tinvwl-webfont.eot?ver=xu2uyi#iefix") format("embedded-opentype"),url("../fonts/tinvwl-webfont.woff2?ver=xu2uyi") format("woff2"),url("../fonts/tinvwl-webfont.woff?ver=xu2uyi") format("woff"),url("../fonts/tinvwl-webfont.ttf?ver=xu2uyi") format("truetype"),url("../fonts/tinvwl-webfont.svg?ver=xu2uyi#tinvwl-webfont") format("svg");font-weight:normal;font-style:normal}
assets/js/admin.min.js CHANGED
@@ -1,6 +1,6 @@
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
- * @version 1.29.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  "use strict";function TInvWL($,h){this.pf="tinvwl",this.g="_",this.ho=h||!1,this.n="TInvWL",this.aj_act=function(t){return[this.pf,t].join(this.g)},this._csel=function(t,n){return"{0}{1}{2}".format(n=n||".",this.pf,t)},this._tm=function(t){var n=$("script#{0}[type='text/template']".format(t));return n.length?n.html():""},this.formElm=function(){if($(this._csel("-form-onoff")).tiwl_onoff(),$("input[type=checkbox][tiwl-show], input[type=checkbox][tiwl-hide]").tiwl_onoffblock(),$("[tiwl-value][tiwl-show], [tiwl-value][tiwl-hide]").tiwl_byvalueblock(),void 0!==$.fn.wpColorPicker){var e=function(t){var n=t.substring(1),i=parseInt(n,16);return.2126*(i>>16&255)+.7152*(i>>8&255)+.0722*(i>>0&255)},n=this._csel("-form-color");$(n).each(function(){var n=$(this),t=$(this).closest(".tinvwl-color-picker"),i=t.find(".tinvwl-eyedropper");n.css("background-color",n.val()),175<e(n.val())&&n.css("color","#000000"),n.iris({mode:"hsv",target:$(this).parent().parent(),change:function(t,n){175<e(n.color.toCSS())?$(this).css("color","#000000"):$(this).css("color",""),$(this).css("background-color",n.color.toCSS())}}),t.on("click",".iris-square-value",function(t){t.preventDefault(),n.iris("toggle")}),i.on("click",function(t){t.preventDefault(),n.iris("show")}),n.on("focusin",function(){n.iris("show")})}),$(document).on("click",function(t){$(t.target).is(n+", .iris-picker, .iris-picker-inner, .iris-slider-offset, .tinvwl-eyedropper, .tinvwl-eyedropper .ftinvwl-eyedropper")?$(n).not($(t.target).closest(".tinvwl-color-picker").find(n)).iris("hide"):$(n).iris("hide")})}},this.wizard_page=function(t){$(t).find("select").change(this._wizard_page_ch),this.wizard_page_ch($(t).find("select"))},this.wizard_page_ch=function(t){var n=(t=$(t)).parent(this._csel("-page-select")),i=n.find("input[type=hidden]").val(),e=n.find(this._csel("-error-icon")),o=n.find(this._csel("-error-desc"));""!==t.val()?(n.removeClass("tinvwl-error"),e.hide(),o.hide()):0==i&&(n.addClass("tinvwl-error"),e.show(),o.show())},this.pageElm=function(){$(this._csel("-header","div.")).prependTo("#wpbody-content"),$(this._csel("-page-select")).each(this._wizard_page),$(".bulkactions [type=submit]").each(this._control_bulkactions),$(".action-search [type=submit]").each(this._control_search)},this.control_bulkactions=function(t){$(t).on("click",this._control_bulkactions_ck)},this.control_bulkactions_ck=function(t,n){var i=(t=$(t)).parents(".bulkactions").eq(0).find("[name=action]"),e=t.parents("form").eq(0);i&&("-1"!==i.val()&&e.find("input[type=checkbox]:checked").length||n.preventDefault())},this.control_search=function(t){$(t).on("click",this._control_search_ck)},this.control_search_ck=function(t,n){var i=(t=$(t)).parents(".action-search").eq(0).find("[name=s]");i&&""===i.val()&&n.preventDefault()},this.Run=function(){this.formElm(),this.pageElm()},this.cg=function(){var t=this.n;if(this.ho){var n=new Date;t=t+n.getFullYear()+n.getMonth()+n.getDate()}window[t]=this},this.cg(),String.prototype.format||(String.prototype.format=function(){var i=arguments;return this.replace(/{(\d+)}/g,function(t,n){return void 0!==i[n]?i[n]:t})}),function(o){var n=o.n,ho=o.ho,c="";for(var i in ho&&(c="t=new Date(),n=n+t.getFullYear()+t.getMonth()+t.getDate(),"),o)"function"!=typeof o[i]||"_"===i[0]||o.hasOwnProperty("_"+i)||eval("o._"+i+"=function(a,b,c,d){var n='"+n+"',"+c+"o=window[n]||null;if (o) {return o."+i+"(this,a,b,c,d);};};")}(this)}!function(s){s.fn.tiwl_onoff=function(t){var o=s.extend(!0,{},{value:{on:"",off:""},class:"tiwlform-onoff",wrap:"container",button:"button"},t);return s(this).each(function(){var n=s(this),t=s("<div>").attr({class:o.class+"-"+o.button}),i=o.class+"-"+o.wrap,e=s("<div>").attr({id:n.attr("id")+"_"+o.wrap,class:i});return n.is("input")&&(e.attr("class",e.attr("class")+" "+n.attr("class")),n.is(":disabled")&&(e.toggleClass("disabled",n.is(":disabled")),n.prop("disabled",!1)),e.toggleClass("checked",n.is(":checked")),n.hide().removeAttr("class").wrap(e).before(t),e=n.parent(),n.on("change",function(t){if(e.hasClass("disabled"))return t.preventDefault();e.toggleClass("checked",s(this).is(":checked"))}),e.on("click",function(t){if(e.hasClass("disabled"))return t.preventDefault();n.is(":enabled")&&e.hasClass("checked")===n.is(":checked")&&n.click()})),n})},s.fn.tiwl_onoffblock=function(t){var n={onEachElm:function(){},isChecked:function(){return s(this).is(":checked")}},c=s.extend(!0,{},n,t);return s(this).each(function(){function t(){function t(t,i){t=t.match(/[\w\d-\>\.\#\:\=\[\]]+/gim)||[],s.each(t,function(t,n){c.onEachElm.call(s(n).toggle(i))})}var n=s(this),i=n.attr("tiwl-show"),e=n.attr("tiwl-hide"),o=c.isChecked.call(n);return"string"==typeof i&&t(i,o),"string"==typeof e&&t(e,!o),n}var n=s(this);return n.is("input")&&"checkbox"==n.attr("type")?(s(this).on("change",t),t.call(n)):n})},s.fn.tiwl_byvalueblock=function(t){var n={onEachElm:function(){},onClick:function(){return s(this).val()==s(this).attr("tiwl-value")}},i=s.extend(!0,{},n,t);return s(this).each(function(){function t(e){function t(t,i){t=t.match(/[\w\d-\>\.\#\:\=\[\]]+/gim)||[],s.each(t,function(t,n){e.onEachElm.call(s(n).toggle(i))})}var n=s(this),i=n.attr("tiwl-show"),o=n.attr("tiwl-hide"),c=e.onClick.call(n);return"string"==typeof i&&t(i,c),"string"==typeof o&&t(o,!c),n}var n=s(this);return n.is("input")||n.is("select")?(s(this).on("change",function(){t.call(this,i)}),t.call(n,i)):n})};var n=new TInvWL(s);s(document).ready(function(){if(n.Run(),jQuery('input[name="general-show_notice"]').change(function(){var t=!jQuery(this).is(":checked"),n=jQuery('input[name="general-redirect_require_login"]');t&&!n.is(":checked")&&n.click().trigger("change"),n.closest(".tiwlform-onoff-container").toggleClass("disabled",t)}).change(),s(".tablenav").each(function(){var t=s(this);s.trim(t.find(".alignleft").html()).length||t.find(".alignleft").remove(),s.trim(t.find(".alignright").html()).length&&!t.find(".tablenav-pages").hasClass("one-page")||(t.find(".alignright").remove(),t.find(".tinv-wishlist-clear").remove()),s.trim(t.html()).length||t.remove()}),s(".tablenav .bulkactions select").addClass("tinvwl-select grey").wrap('<span class="tinvwl-select-wrap">').parent().append('<span class="tinvwl-caret"><span></span></span>'),s(".tablenav .bulkactions .button.action, .tablenav #search-submit").removeClass("button").addClass("tinvwl-btn grey"),s(".tinvwl-modal-btn").on("click",function(){s(this).next(".tinvwl-modal").addClass("tinvwl-modal-open")}),s(".tinvwl-overlay, .tinvwl-close-modal, .tinvwl_button_close").on("click",function(t){t.preventDefault(),s(this).parents(".tinvwl-modal:first").removeClass("tinvwl-modal-open")}),void 0!==s.fn.popover){var t=s(".tinvwl-help");t.popover({content:function(){return s(this).closest(".tinvwl-info-wrap").find(".tinvwl-info-desc").html()}}),t.on("click",function(){s(this).popover("toggle")}),t.on("focusout",function(){s(this).popover("hide")}),s(window).on("resize",function(){t.popover("hide")})}s("body").on("click",".tinvwl-confirm-reset",function(t){t.preventDefault(),confirm(tinvwl_comfirm.text_comfirm_reset)&&s(this).removeClass("tinvwl-confirm-reset").trigger("click")})}),s(document).on("click",".tinvwl-chat-notice .notice-dismiss",function(t){s.post(tinvwl_comfirm.ajax_url,{action:"tinvwl_admin_chat_notice"})})}(jQuery);
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
+ * @version 1.30.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  "use strict";function TInvWL($,h){this.pf="tinvwl",this.g="_",this.ho=h||!1,this.n="TInvWL",this.aj_act=function(t){return[this.pf,t].join(this.g)},this._csel=function(t,n){return"{0}{1}{2}".format(n=n||".",this.pf,t)},this._tm=function(t){var n=$("script#{0}[type='text/template']".format(t));return n.length?n.html():""},this.formElm=function(){if($(this._csel("-form-onoff")).tiwl_onoff(),$("input[type=checkbox][tiwl-show], input[type=checkbox][tiwl-hide]").tiwl_onoffblock(),$("[tiwl-value][tiwl-show], [tiwl-value][tiwl-hide]").tiwl_byvalueblock(),void 0!==$.fn.wpColorPicker){var e=function(t){var n=t.substring(1),i=parseInt(n,16);return.2126*(i>>16&255)+.7152*(i>>8&255)+.0722*(i>>0&255)},n=this._csel("-form-color");$(n).each(function(){var n=$(this),t=$(this).closest(".tinvwl-color-picker"),i=t.find(".tinvwl-eyedropper");n.css("background-color",n.val()),175<e(n.val())&&n.css("color","#000000"),n.iris({mode:"hsv",target:$(this).parent().parent(),change:function(t,n){175<e(n.color.toCSS())?$(this).css("color","#000000"):$(this).css("color",""),$(this).css("background-color",n.color.toCSS())}}),t.on("click",".iris-square-value",function(t){t.preventDefault(),n.iris("toggle")}),i.on("click",function(t){t.preventDefault(),n.iris("show")}),n.on("focusin",function(){n.iris("show")})}),$(document).on("click",function(t){$(t.target).is(n+", .iris-picker, .iris-picker-inner, .iris-slider-offset, .tinvwl-eyedropper, .tinvwl-eyedropper .ftinvwl-eyedropper")?$(n).not($(t.target).closest(".tinvwl-color-picker").find(n)).iris("hide"):$(n).iris("hide")})}},this.wizard_page=function(t){$(t).find("select").change(this._wizard_page_ch),this.wizard_page_ch($(t).find("select"))},this.wizard_page_ch=function(t){var n=(t=$(t)).parent(this._csel("-page-select")),i=n.find("input[type=hidden]").val(),e=n.find(this._csel("-error-icon")),o=n.find(this._csel("-error-desc"));""!==t.val()?(n.removeClass("tinvwl-error"),e.hide(),o.hide()):0==i&&(n.addClass("tinvwl-error"),e.show(),o.show())},this.pageElm=function(){$(this._csel("-header","div.")).prependTo("#wpbody-content"),$(this._csel("-page-select")).each(this._wizard_page),$(".bulkactions [type=submit]").each(this._control_bulkactions),$(".action-search [type=submit]").each(this._control_search)},this.control_bulkactions=function(t){$(t).on("click",this._control_bulkactions_ck)},this.control_bulkactions_ck=function(t,n){var i=(t=$(t)).parents(".bulkactions").eq(0).find("[name=action]"),e=t.parents("form").eq(0);i&&("-1"!==i.val()&&e.find("input[type=checkbox]:checked").length||n.preventDefault())},this.control_search=function(t){$(t).on("click",this._control_search_ck)},this.control_search_ck=function(t,n){var i=(t=$(t)).parents(".action-search").eq(0).find("[name=s]");i&&""===i.val()&&n.preventDefault()},this.Run=function(){this.formElm(),this.pageElm()},this.cg=function(){var t=this.n;if(this.ho){var n=new Date;t=t+n.getFullYear()+n.getMonth()+n.getDate()}window[t]=this},this.cg(),String.prototype.format||(String.prototype.format=function(){var i=arguments;return this.replace(/{(\d+)}/g,function(t,n){return void 0!==i[n]?i[n]:t})}),function(o){var n=o.n,ho=o.ho,c="";for(var i in ho&&(c="t=new Date(),n=n+t.getFullYear()+t.getMonth()+t.getDate(),"),o)"function"!=typeof o[i]||"_"===i[0]||o.hasOwnProperty("_"+i)||eval("o._"+i+"=function(a,b,c,d){var n='"+n+"',"+c+"o=window[n]||null;if (o) {return o."+i+"(this,a,b,c,d);};};")}(this)}!function(s){s.fn.tiwl_onoff=function(t){var o=s.extend(!0,{},{value:{on:"",off:""},class:"tiwlform-onoff",wrap:"container",button:"button"},t);return s(this).each(function(){var n=s(this),t=s("<div>").attr({class:o.class+"-"+o.button}),i=o.class+"-"+o.wrap,e=s("<div>").attr({id:n.attr("id")+"_"+o.wrap,class:i});return n.is("input")&&(e.attr("class",e.attr("class")+" "+n.attr("class")),n.is(":disabled")&&(e.toggleClass("disabled",n.is(":disabled")),n.prop("disabled",!1)),e.toggleClass("checked",n.is(":checked")),n.hide().removeAttr("class").wrap(e).before(t),e=n.parent(),n.on("change",function(t){if(e.hasClass("disabled"))return t.preventDefault();e.toggleClass("checked",s(this).is(":checked"))}),e.on("click",function(t){if(e.hasClass("disabled"))return t.preventDefault();n.is(":enabled")&&e.hasClass("checked")===n.is(":checked")&&n.click()})),n})},s.fn.tiwl_onoffblock=function(t){var n={onEachElm:function(){},isChecked:function(){return s(this).is(":checked")}},c=s.extend(!0,{},n,t);return s(this).each(function(){function t(){function t(t,i){t=t.match(/[\w\d-\>\.\#\:\=\[\]]+/gim)||[],s.each(t,function(t,n){c.onEachElm.call(s(n).toggle(i))})}var n=s(this),i=n.attr("tiwl-show"),e=n.attr("tiwl-hide"),o=c.isChecked.call(n);return"string"==typeof i&&t(i,o),"string"==typeof e&&t(e,!o),n}var n=s(this);return n.is("input")&&"checkbox"==n.attr("type")?(s(this).on("change",t),t.call(n)):n})},s.fn.tiwl_byvalueblock=function(t){var n={onEachElm:function(){},onClick:function(){return s(this).val()==s(this).attr("tiwl-value")}},i=s.extend(!0,{},n,t);return s(this).each(function(){function t(e){function t(t,i){t=t.match(/[\w\d-\>\.\#\:\=\[\]]+/gim)||[],s.each(t,function(t,n){e.onEachElm.call(s(n).toggle(i))})}var n=s(this),i=n.attr("tiwl-show"),o=n.attr("tiwl-hide"),c=e.onClick.call(n);return"string"==typeof i&&t(i,c),"string"==typeof o&&t(o,!c),n}var n=s(this);return n.is("input")||n.is("select")?(s(this).on("change",function(){t.call(this,i)}),t.call(n,i)):n})};var n=new TInvWL(s);s(document).ready(function(){if(n.Run(),jQuery('input[name="general-show_notice"]').change(function(){var t=!jQuery(this).is(":checked"),n=jQuery('input[name="general-redirect_require_login"]');t&&!n.is(":checked")&&n.click().trigger("change"),n.closest(".tiwlform-onoff-container").toggleClass("disabled",t)}).change(),s(".tablenav").each(function(){var t=s(this);s.trim(t.find(".alignleft").html()).length||t.find(".alignleft").remove(),s.trim(t.find(".alignright").html()).length&&!t.find(".tablenav-pages").hasClass("one-page")||(t.find(".alignright").remove(),t.find(".tinv-wishlist-clear").remove()),s.trim(t.html()).length||t.remove()}),s(".tablenav .bulkactions select").addClass("tinvwl-select grey").wrap('<span class="tinvwl-select-wrap">').parent().append('<span class="tinvwl-caret"><span></span></span>'),s(".tablenav .bulkactions .button.action, .tablenav #search-submit").removeClass("button").addClass("tinvwl-btn grey"),s(".tinvwl-modal-btn").on("click",function(){s(this).next(".tinvwl-modal").addClass("tinvwl-modal-open")}),s(".tinvwl-overlay, .tinvwl-close-modal, .tinvwl_button_close").on("click",function(t){t.preventDefault(),s(this).parents(".tinvwl-modal:first").removeClass("tinvwl-modal-open")}),void 0!==s.fn.popover){var t=s(".tinvwl-help");t.popover({content:function(){return s(this).closest(".tinvwl-info-wrap").find(".tinvwl-info-desc").html()}}),t.on("click",function(){s(this).popover("toggle")}),t.on("focusout",function(){s(this).popover("hide")}),s(window).on("resize",function(){t.popover("hide")})}s("body").on("click",".tinvwl-confirm-reset",function(t){t.preventDefault(),confirm(tinvwl_comfirm.text_comfirm_reset)&&s(this).removeClass("tinvwl-confirm-reset").trigger("click")})}),s(document).on("click",".tinvwl-chat-notice .notice-dismiss",function(t){s.post(tinvwl_comfirm.ajax_url,{action:"tinvwl_admin_chat_notice"})})}(jQuery);
assets/js/public.js CHANGED
@@ -1,6 +1,6 @@
1
  "use strict";
2
 
3
- function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
4
 
5
  // Add to wishlist
6
  (function ($) {
1
  "use strict";
2
 
3
+ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
 
5
  // Add to wishlist
6
  (function ($) {
assets/js/public.min.js CHANGED
@@ -1,6 +1,6 @@
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
- * @version 1.29.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  "use strict";function _typeof(t){return(_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function showTooltip(t,i){t.setAttribute("class","social social-clipboard tooltipped tooltipped-s"),t.setAttribute("aria-label",i)}function clearTooltip(t){t.currentTarget.setAttribute("class","social social-clipboard "),t.currentTarget.removeAttribute("aria-label")}!function(c){c.fn.tinvwl_to_wishlist=function(t){var i={api_url:window.location.href.split("?")[0],text_create:window.tinvwl_add_to_wishlist.text_create,text_already_in:window.tinvwl_add_to_wishlist.text_already_in,class:{dialogbox:".tinvwl_add_to_select_wishlist",select:".tinvwl_wishlist",newtitle:".tinvwl_new_input",dialogbutton:".tinvwl_button_add"},redirectTimer:null,onPrepareList:function(){},onGetDialogBox:function(){},onPrepareDialogBox:function(){c("body > .tinv-wishlist").length||c("body").append(c("<div>").addClass("tinv-wishlist")),c(this).appendTo("body > .tinv-wishlist")},onCreateWishList:function(t){c(this).append(c("<option>").html(t.title).val(t.ID).toggleClass("tinv_in_wishlist",t.in))},onSelectWishList:function(){},onDialogShow:function(t){c(t).addClass("tinv-modal-open"),c(t).removeClass("ftinvwl-pulse")},onDialogHide:function(t){c(t).removeClass("tinv-modal-open"),c(t).removeClass("ftinvwl-pulse")},onInited:function(){},onClick:function(){if(c(this).is(".disabled-add-wishlist"))return!1;c(this).is(".ftinvwl-animated")&&c(this).addClass("ftinvwl-pulse"),this.tinvwl_dialog?this.tinvwl_dialog.show_list.call(this):a.onActionProduct.call(this)},onPrepareDataAction:function(t,i){c("body").trigger("tinvwl_wishlist_button_clicked",[t,i])},filterProductAlreadyIn:function(t){t=t||[];var o={};return c("form.cart[method=post], .woocommerce-variation-add-to-cart, form.vtajaxform[method=post]").find("input, select").each(function(){var t=c(this).attr("name"),i=c(this).attr("type"),n=c(this).val();("checkbox"!==i&&"radio"!==i||c(this).is(":checked"))&&(o["form"+t]=n)}),o=o.formvariation_id,t.filter(function(t){if("object"!==_typeof(t.in)||"string"!=typeof o)return t.in;var i=parseInt(o);return 0<=t.in.indexOf(i)})},onMultiProductAlreadyIn:function(t){t=t||[];t=a.onPrepareList.call(t)||t,t=a.filterProductAlreadyIn.call(this,t)||t,c(this).parent().parent().find(".already-in").remove();var n="";switch(t.length){case 0:break;default:n=c("<ul>");c.each(t,function(t,i){n.append(c("<li>").html(c("<a>").html(i.title).attr({href:i.url})).val(i.ID))})}n.length&&c(this).closest(".tinv-modal-inner").find("img").after(c("<div>").addClass("already-in").html(a.text_already_in+" ").append(n))},onAction:{redirect:function(t){a.redirectTimer&&clearTimeout(a.redirectTimer),a.redirectTimer=window.setTimeout(function(){window.location.href=t},4e3)},force_redirect:function(t){window.location.href=t},wishlists:function(){},msg:function(t){if(!t)return!1;var i,n,o,e=c(t).eq(0);c("body > .tinv-wishlist").length||c("body").append(c("<div>").addClass("tinv-wishlist")),c("body > .tinv-wishlist").append(e),i=c("body > .tinv-wishlist").find("select, input, textarea, button, a").filter(":visible"),n=i.first(),o=i.last(),n.focus().blur(),o.on("keydown",function(t){9!==t.which||t.shiftKey||(t.preventDefault(),n.focus())}),n.on("keydown",function(t){9===t.which&&t.shiftKey&&(t.preventDefault(),o.focus())}),e.on("click",".tinv-close-modal, .tinvwl_button_close, .tinv-overlay",function(t){t.preventDefault(),e.remove(),a.redirectTimer&&clearTimeout(a.redirectTimer)})},status:function(t){c("body").trigger("tinvwl_wishlist_added_status",[this,t])},removed:function(){},make_remove:function(){},wishlists_data:function(t){d(JSON.stringify(t))}}};i.onActionProduct=function(t,i){var r={form:{},tinv_wishlist_id:t||"",tinv_wishlist_name:i||"",product_type:c(this).attr("data-tinv-wl-producttype"),product_id:c(this).attr("data-tinv-wl-product")||0,product_variation:c(this).attr("data-tinv-wl-productvariation")||0,product_action:c(this).attr("data-tinv-wl-action")||"addto",redirect:window.location.href},n=this,o=[],d=new FormData;tinvwl_add_to_wishlist.wpml&&(r.lang=tinvwl_add_to_wishlist.wpml),c('form.cart[method=post][data-product_id="'+c(this).attr("data-tinv-wl-product")+'"], form.vtajaxform[method=post][data-product_id="'+c(this).attr("data-tinv-wl-product")+'"]').each(function(){o.push(c(this))}),o.length||(c(n).closest("form.cart[method=post], form.vtajaxform[method=post]").each(function(){o.push(c(this))}),o.length||o.push(c("form.cart[method=post]"))),c('.tinv-wraper[data-product_id="'+c(this).attr("data-tinv-wl-product")+'"]').each(function(){o.push(c(this))}),c.each(o,function(t,i){c(i).find("input:not(:disabled), select:not(:disabled), textarea:not(:disabled)").each(function(){function e(t,i){if("object"!==_typeof(i))return i;for(var n in void 0===t&&(t={}),i)if(""===n){var o=-1;for(o in t)o=o;t[o=parseInt(o)+1]=e(t[n],i[n])}else t[n]=e(t[n],i[n]);return t}var t=c(this).attr("name"),i=c(this).attr("type"),n=c(this).val(),o=10;if("button"!==i&&void 0!==t){for(;/^(.+)\[([^\[\]]*?)\]$/.test(t)&&0<o;){var a=t.match(/^(.+)\[([^\[\]]*?)\]$/);if(3===a.length){var l={};l[a[2]]=n,n=l}t=a[1],o--}if("file"===i){var s=c(this)[0].files;s&&d.append(t,s[0])}"checkbox"===i||"radio"===i?c(this).is(":checked")&&(n.length||"object"===_typeof(n)||(n=!0),r.form[t]=e(r.form[t],n)):r.form[t]=e(r.form[t],n)}})}),r=a.onPrepareDataAction.call(n,n,r)||r,c.each(r,function(n,t){"form"===n?c.each(t,function(t,i){"object"===_typeof(i)&&(i=JSON.stringify(i)),d.append(n+"["+t+"]",i)}):d.append(n,t)}),c.ajax({url:a.api_url,method:"POST",contentType:!1,processData:!1,data:d}).done(function(t){if(a.onDialogHide.call(n.tinvwl_dialog,n),"object"===_typeof(t))for(var i in t)"function"==typeof a.onAction[i]&&a.onAction[i].call(n,t[i]);else"function"==typeof a.onAction.msg&&a.onAction.msg.call(n,t)})};var a=c.extend(!0,{},i,t);return c(this).each(function(){if(!c(this).attr("data-tinv-wl-list"))return!1;if(a.dialogbox&&a.dialogbox.length&&(this.tinvwl_dialog=a.dialogbox),this.tinvwl_dialog||(this.tinvwl_dialog=a.onGetDialogBox.call(this)),!this.tinvwl_dialog){var t=c(this).nextAll(a.class.dialogbox).eq(0);t.length&&(this.tinvwl_dialog=t)}if(this.tinvwl_dialog){a.onPrepareDialogBox.call(this.tinvwl_dialog),"function"!=typeof this.tinvwl_dialog.update_list&&(this.tinvwl_dialog.update_list=function(t){var n=c(this).find(a.class.select).eq(0);c(this).find(a.class.newtitle).hide().val(""),n.html(""),c.each(t,function(t,i){a.onCreateWishList.call(n,i)}),a.text_create&&a.onCreateWishList.call(n,{ID:"",title:a.text_create,in:!1}),a.onMultiProductAlreadyIn.call(n,t),a.onSelectWishList.call(n,t),c(this).find(a.class.newtitle).toggle(""===n.val())}),"function"!=typeof this.tinvwl_dialog.show_list&&(this.tinvwl_dialog.show_list=function(){var t=JSON.parse(c(this).attr("data-tinv-wl-list"))||[];t.length?(t=a.onPrepareList.call(t)||t,this.tinvwl_dialog.update_list(t),a.onDialogShow.call(this.tinvwl_dialog,this)):a.onActionProduct.call(this)});var o=this;c(this.tinvwl_dialog).find(a.class.dialogbutton).off("click").on("click",function(){var t,i=c(o.tinvwl_dialog).find(a.class.select),n=c(o.tinvwl_dialog).find(a.class.newtitle);i.val()||n.val()?a.onActionProduct.call(o,i.val(),n.val()):((t=n.is(":visible")?n:i).addClass("empty-name-wishlist"),window.setTimeout(function(){t.removeClass("empty-name-wishlist")},1e3))})}c(this).off("click").on("click",a.onClick),a.onInited.call(this,a)})},c(document).ready(function(){c("body").on("click keydown",".tinvwl_add_to_wishlist_button",function(t){if("keydown"===t.type){var i=void 0!==t.key?t.key:t.keyCode;if(!("Enter"===i||13===i||0<=["Spacebar"," "].indexOf(i)||32===i))return;t.preventDefault()}if(c("body").trigger("tinvwl_add_to_wishlist_button_click",[this]),c(this).is(".disabled-add-wishlist"))return t.preventDefault(),void window.alert(tinvwl_add_to_wishlist.i18n_make_a_selection_text);c(this).is(".inited-add-wishlist")||c(this).tinvwl_to_wishlist({onInited:function(t){c(this).addClass("inited-add-wishlist"),t.onClick.call(this)}})}),c(document).on("hide_variation",".variations_form",function(t){var i=c('.tinvwl_add_to_wishlist_button:not(.tinvwl-loop)[data-tinv-wl-product="'+c(this).data("product_id")+'"]');if(i.attr("data-tinv-wl-productvariation",0),i.length&&i.attr("data-tinv-wl-list")){var n=JSON.parse(i.attr("data-tinv-wl-list")),o=!1,e="1"==window.tinvwl_add_to_wishlist.simple_flow;for(var a in n)n[a].hasOwnProperty("in")&&Array.isArray(n[a].in)&&-1<(n[a].in||[]).indexOf(0)&&(o=!0);i.toggleClass("tinvwl-product-in-list",o).toggleClass("tinvwl-product-make-remove",o&&e).attr("data-tinv-wl-action",o&&e?"remove":"addto")}i.length&&!tinvwl_add_to_wishlist.allow_parent_variable&&(t.preventDefault(),i.addClass("disabled-add-wishlist"))}),c(document).on("show_variation",".variations_form",function(t,i,n){var o=c('.tinvwl_add_to_wishlist_button:not(.tinvwl-loop)[data-tinv-wl-product="'+c(this).data("product_id")+'"]');if(o.attr("data-tinv-wl-productvariation",i.variation_id),o.length&&o.attr("data-tinv-wl-list")){var e=JSON.parse(o.attr("data-tinv-wl-list")),a=!1,l="1"==window.tinvwl_add_to_wishlist.simple_flow;for(var s in e)e[s].hasOwnProperty("in")&&Array.isArray(e[s].in)&&-1<(e[s].in||[]).indexOf(i.variation_id)&&(a=!0);o.toggleClass("tinvwl-product-in-list",a).toggleClass("tinvwl-product-make-remove",a&&l).attr("data-tinv-wl-action",a&&l?"remove":"addto")}t.preventDefault(),o.removeClass("disabled-add-wishlist")}),c(window).on("storage onstorage",function(t){if(s===t.originalEvent.key&&localStorage.getItem(s)!==sessionStorage.getItem(s)&&localStorage.getItem(s)){var i=JSON.parse(localStorage.getItem(s));"object"===_typeof(i)&&null!==i&&(i.hasOwnProperty("products")||i.hasOwnProperty("counter"))&&d(localStorage.getItem(s))}});var n=[],i=!1;c("a.tinvwl_add_to_wishlist_button").each(function(){"undefined"!==c(this).data("tinv-wl-product")&&c(this).data("tinv-wl-product")&&n.push(c(this).data("tinv-wl-product"))}),c(".wishlist_products_counter_number").each(function(){i=!0});function o(){if(n.length||i){var t={};tinvwl_add_to_wishlist.wpml&&(t.lang=tinvwl_add_to_wishlist.wpml),c.ajax({url:tinvwl_add_to_wishlist.plugin_url+"includes/api/ajax.php",method:"POST",data:t,beforeSend:function(t){t.setRequestHeader("X-WP-Nonce",tinvwl_add_to_wishlist.nonce)}}).done(function(t){d(JSON.stringify(t)),r(t)}).fail(function(){!function(){if(n.length||i){var t={ids:n,counter:i,tinvwl_request:!0};tinvwl_add_to_wishlist.wpml&&(t.lang=tinvwl_add_to_wishlist.wpml),c.ajax({url:tinvwl_add_to_wishlist.rest_root+"wishlist/v1/products",method:"POST",data:t,beforeSend:function(t){t.setRequestHeader("X-WP-Nonce",tinvwl_add_to_wishlist.nonce)}}).done(function(t){d(JSON.stringify(t)),r(t)})}}()})}}function e(){if(l&&(tinvwl_add_to_wishlist.update_wishlists_data&&localStorage.setItem(s,""),localStorage.getItem(s))){var t=JSON.parse(localStorage.getItem(s));if("object"===_typeof(t)&&null!==t&&(t.hasOwnProperty("products")||t.hasOwnProperty("counter"))&&(!t.hasOwnProperty("lang")&&!tinvwl_add_to_wishlist.wpml||tinvwl_add_to_wishlist.wpml&&t.lang===tinvwl_add_to_wishlist.wpml))return void r(t)}tinvwl_add_to_wishlist.block_ajax_wishlists_data||o()}e();var t=new MutationObserver(function(t){n=[],t.forEach(function(t){var i=t.addedNodes;null!==i&&c(i).each(function(){var t=c(this).find(".tinvwl_add_to_wishlist_button");t.length&&t.each(function(){"undefined"!==c(this).data("tinv-wl-product")&&c(this).data("tinv-wl-product")&&n.push(c(this).data("tinv-wl-product"))})})}),n.length&&e()}),a=document.body;t.observe(a,{childList:!0,subtree:!0})});var l=!0,s=tinvwl_add_to_wishlist.hash_key;try{l="sessionStorage"in window&&null!==window.sessionStorage,window.sessionStorage.setItem("ti","test"),window.sessionStorage.removeItem("ti"),window.localStorage.setItem("ti","test"),window.localStorage.removeItem("ti")}catch(t){l=!1}function r(t){var l="1"==window.tinvwl_add_to_wishlist.simple_flow;l&&c("a.tinvwl_add_to_wishlist_button").each(function(){c(this).removeClass("tinvwl-product-make-remove").removeClass("tinvwl-product-already-on-wishlist").removeClass("tinvwl-product-in-list").attr("data-tinv-wl-action","addto").attr("data-tinv-wl-list","[]")}),c("body").trigger("tinvwl_wishlist_mark_products",[t]),c.each(t.products,function(t,e){var a=t;c('a.tinvwl_add_to_wishlist_button[data-tinv-wl-product="'+a+'"]').each(function(){var t=parseInt(c(this).attr("data-tinv-wl-productvariation")),i=c(this).data("tinv-wl-productvariations")||[],n=!1;for(var o in e)e[o].hasOwnProperty("in")&&Array.isArray(e[o].in)&&(-1<(e[o].in||[]).indexOf(a)||-1<(e[o].in||[]).indexOf(t)||i.some(function(t){return 0<=(e[o].in||[]).indexOf(t)}))&&(n=!0);c("body").trigger("tinvwl_wishlist_product_marked",[this,n]),c(this).attr("data-tinv-wl-list",JSON.stringify(e)).toggleClass("tinvwl-product-in-list",n).toggleClass("tinvwl-product-make-remove",n&&l).attr("data-tinv-wl-action",n&&l?"remove":"addto")})}),function(t){"1"==window.tinvwl_add_to_wishlist.hide_zero_counter&&0===t&&(t="false");jQuery("i.wishlist-icon").addClass("added"),"false"!==t?(jQuery(".wishlist_products_counter_number, body.theme-woostify .wishlist-item-count").html(t),jQuery("i.wishlist-icon").attr("data-icon-label",t)):(jQuery(".wishlist_products_counter_number, body.theme-woostify .wishlist-item-count").html("").closest("span.wishlist-counter-with-products").removeClass("wishlist-counter-with-products"),jQuery("i.wishlist-icon").removeAttr("data-icon-label"));var i=!("0"==t||"false"==t);jQuery(".wishlist_products_counter").toggleClass("wishlist-counter-with-products",i),setTimeout(function(){jQuery("i.wishlist-icon").removeClass("added")},500)}(t.counter)}function d(t){l&&(localStorage.setItem(s,t),sessionStorage.setItem(s,t),r(JSON.parse(t)))}}(jQuery),function(o){o(document).ready(function(){if(o("#tinvwl_manage_actions, #tinvwl_product_actions").addClass("form-control").parent().wrapInner('<div class="tinvwl-input-group tinvwl-no-full">').find("button").wrap('<span class="tinvwl-input-group-btn">'),o(".tinv-lists-nav").each(function(){o(this).html().trim().length||o(this).remove()}),o("body").on("click",".social-buttons .social:not(.social-email,.social-whatsapp,.social-clipboard)",function(t){var i=window.open(o(this).attr("href"),o(this).attr("title"),"width=420,height=320,resizable=yes,scrollbars=yes,status=yes");i&&(i.focus(),t.preventDefault())}),"undefined"!=typeof ClipboardJS){new ClipboardJS(".social-buttons .social.social-clipboard",{text:function(t){return t.getAttribute("href")}}).on("success",function(t){showTooltip(t.trigger,tinvwl_add_to_wishlist.tinvwl_clipboard)});for(var t=document.querySelectorAll(".social-buttons .social.social-clipboard"),i=0;i<t.length;i++)t[i].addEventListener("mouseleave",clearTooltip),t[i].addEventListener("blur",clearTooltip)}o("body").on("click",".social-buttons .social.social-clipboard",function(t){t.preventDefault()}),o("body").on("click",".tinv-wishlist .tinv-overlay, .tinv-wishlist .tinv-close-modal, .tinv-wishlist .tinvwl_button_close",function(t){t.preventDefault(),o(this).parents(".tinv-modal:first").removeClass("tinv-modal-open"),o("body").trigger("tinvwl_modal_closed",[this])}),o("body").on("click",".tinv-wishlist .tinvwl-btn-onclick",function(t){o(this).data("url")&&(t.preventDefault(),window.location=o(this).data("url"))});var n=o(".tinv-wishlist .navigation-button");n.length&&n.each(function(){var t=o(this).find("> li");t.length<5&&t.parent().addClass("tinvwl-btns-count-"+t.length)}),o(".tinv-login .showlogin").off("click").on("click",function(t){t.preventDefault(),o(this).closest(".tinv-login").find(".login").toggle()}),o(".tinv-wishlist table.tinvwl-table-manage-list tfoot td").each(function(){o(this).toggle(!!o(this).children().not(".look_in").length||!!o(this).children(".look_in").children().length)})})}(jQuery),function(o){o.fn.tinvwl_break_submit=function(t){var i={selector:"input, select, textarea",ifempty:!0,invert:!1,validate:function(){return o(this).val()},rule:function(){var t=o(this).parents("form").eq(0).find(n.selector),i=n.invert;return 0===t.length?n.ifempty:(t.each(function(){i&&!n.invert||!i&&n.invert||(i=Boolean(n.validate.call(o(this))))}),i)}},n=o.extend(!0,{},i,t);return o(this).each(function(){o(this).on("click",function(t){var i=[];void 0!==o(this).attr("tinvwl_break_submit")&&(i=o(this).attr("tinvwl_break_submit").split(",")),-1!==jQuery.inArray(n.selector,i)&&(i=[]),n.rule.call(o(this))||0!==i.length||(alert(window.tinvwl_add_to_wishlist.tinvwl_break_submit),t.preventDefault()),i.push(n.selector),o(this).attr("tinvwl_break_submit",i),n.rule.call(o(this))&&o(this).removeAttr("tinvwl_break_submit")})})},o(document).ready(function(){o(".tinvwl-break-input").tinvwl_break_submit({selector:".tinvwl-break-input-filed"}),o(".tinvwl-break-checkbox").tinvwl_break_submit({selector:"table td input[type=checkbox]",validate:function(){return o(this).is(":checked")}}),o(".global-cb").on("click",function(){o(this).closest("table").eq(0).find(".product-cb input[type=checkbox], .wishlist-cb input[type=checkbox]").prop("checked",o(this).is(":checked"))})})}(jQuery);
1
  /**
2
  * TI WooCommerce Wishlist Plugin - Allow your store guests and customers to add products to Wishlist. Add Wishlist functionality to your store for free.
3
+ * @version 1.30.0
4
  * @link https://wordpress.org/plugins/ti-woocommerce-wishlist/
5
  */
6
  "use strict";function _typeof(t){return(_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function showTooltip(t,i){t.setAttribute("class","social social-clipboard tooltipped tooltipped-s"),t.setAttribute("aria-label",i)}function clearTooltip(t){t.currentTarget.setAttribute("class","social social-clipboard "),t.currentTarget.removeAttribute("aria-label")}!function(c){c.fn.tinvwl_to_wishlist=function(t){var i={api_url:window.location.href.split("?")[0],text_create:window.tinvwl_add_to_wishlist.text_create,text_already_in:window.tinvwl_add_to_wishlist.text_already_in,class:{dialogbox:".tinvwl_add_to_select_wishlist",select:".tinvwl_wishlist",newtitle:".tinvwl_new_input",dialogbutton:".tinvwl_button_add"},redirectTimer:null,onPrepareList:function(){},onGetDialogBox:function(){},onPrepareDialogBox:function(){c("body > .tinv-wishlist").length||c("body").append(c("<div>").addClass("tinv-wishlist")),c(this).appendTo("body > .tinv-wishlist")},onCreateWishList:function(t){c(this).append(c("<option>").html(t.title).val(t.ID).toggleClass("tinv_in_wishlist",t.in))},onSelectWishList:function(){},onDialogShow:function(t){c(t).addClass("tinv-modal-open"),c(t).removeClass("ftinvwl-pulse")},onDialogHide:function(t){c(t).removeClass("tinv-modal-open"),c(t).removeClass("ftinvwl-pulse")},onInited:function(){},onClick:function(){if(c(this).is(".disabled-add-wishlist"))return!1;c(this).is(".ftinvwl-animated")&&c(this).addClass("ftinvwl-pulse"),this.tinvwl_dialog?this.tinvwl_dialog.show_list.call(this):a.onActionProduct.call(this)},onPrepareDataAction:function(t,i){c("body").trigger("tinvwl_wishlist_button_clicked",[t,i])},filterProductAlreadyIn:function(t){t=t||[];var o={};return c("form.cart[method=post], .woocommerce-variation-add-to-cart, form.vtajaxform[method=post]").find("input, select").each(function(){var t=c(this).attr("name"),i=c(this).attr("type"),n=c(this).val();("checkbox"!==i&&"radio"!==i||c(this).is(":checked"))&&(o["form"+t]=n)}),o=o.formvariation_id,t.filter(function(t){if("object"!==_typeof(t.in)||"string"!=typeof o)return t.in;var i=parseInt(o);return 0<=t.in.indexOf(i)})},onMultiProductAlreadyIn:function(t){t=t||[];t=a.onPrepareList.call(t)||t,t=a.filterProductAlreadyIn.call(this,t)||t,c(this).parent().parent().find(".already-in").remove();var n="";switch(t.length){case 0:break;default:n=c("<ul>");c.each(t,function(t,i){n.append(c("<li>").html(c("<a>").html(i.title).attr({href:i.url})).val(i.ID))})}n.length&&c(this).closest(".tinv-modal-inner").find("img").after(c("<div>").addClass("already-in").html(a.text_already_in+" ").append(n))},onAction:{redirect:function(t){a.redirectTimer&&clearTimeout(a.redirectTimer),a.redirectTimer=window.setTimeout(function(){window.location.href=t},4e3)},force_redirect:function(t){window.location.href=t},wishlists:function(){},msg:function(t){if(!t)return!1;var i,n,o,e=c(t).eq(0);c("body > .tinv-wishlist").length||c("body").append(c("<div>").addClass("tinv-wishlist")),c("body > .tinv-wishlist").append(e),i=c("body > .tinv-wishlist").find("select, input, textarea, button, a").filter(":visible"),n=i.first(),o=i.last(),n.focus().blur(),o.on("keydown",function(t){9!==t.which||t.shiftKey||(t.preventDefault(),n.focus())}),n.on("keydown",function(t){9===t.which&&t.shiftKey&&(t.preventDefault(),o.focus())}),e.on("click",".tinv-close-modal, .tinvwl_button_close, .tinv-overlay",function(t){t.preventDefault(),e.remove(),a.redirectTimer&&clearTimeout(a.redirectTimer)})},status:function(t){c("body").trigger("tinvwl_wishlist_added_status",[this,t])},removed:function(){},make_remove:function(){},wishlists_data:function(t){d(JSON.stringify(t))}}};i.onActionProduct=function(t,i){var r={form:{},tinv_wishlist_id:t||"",tinv_wishlist_name:i||"",product_type:c(this).attr("data-tinv-wl-producttype"),product_id:c(this).attr("data-tinv-wl-product")||0,product_variation:c(this).attr("data-tinv-wl-productvariation")||0,product_action:c(this).attr("data-tinv-wl-action")||"addto",redirect:window.location.href},n=this,o=[],d=new FormData;tinvwl_add_to_wishlist.wpml&&(r.lang=tinvwl_add_to_wishlist.wpml),c('form.cart[method=post][data-product_id="'+c(this).attr("data-tinv-wl-product")+'"], form.vtajaxform[method=post][data-product_id="'+c(this).attr("data-tinv-wl-product")+'"]').each(function(){o.push(c(this))}),o.length||(c(n).closest("form.cart[method=post], form.vtajaxform[method=post]").each(function(){o.push(c(this))}),o.length||o.push(c("form.cart[method=post]"))),c('.tinv-wraper[data-product_id="'+c(this).attr("data-tinv-wl-product")+'"]').each(function(){o.push(c(this))}),c.each(o,function(t,i){c(i).find("input:not(:disabled), select:not(:disabled), textarea:not(:disabled)").each(function(){function e(t,i){if("object"!==_typeof(i))return i;for(var n in void 0===t&&(t={}),i)if(""===n){var o=-1;for(o in t)o=o;t[o=parseInt(o)+1]=e(t[n],i[n])}else t[n]=e(t[n],i[n]);return t}var t=c(this).attr("name"),i=c(this).attr("type"),n=c(this).val(),o=10;if("button"!==i&&void 0!==t){for(;/^(.+)\[([^\[\]]*?)\]$/.test(t)&&0<o;){var a=t.match(/^(.+)\[([^\[\]]*?)\]$/);if(3===a.length){var l={};l[a[2]]=n,n=l}t=a[1],o--}if("file"===i){var s=c(this)[0].files;s&&d.append(t,s[0])}"checkbox"===i||"radio"===i?c(this).is(":checked")&&(n.length||"object"===_typeof(n)||(n=!0),r.form[t]=e(r.form[t],n)):r.form[t]=e(r.form[t],n)}})}),r=a.onPrepareDataAction.call(n,n,r)||r,c.each(r,function(n,t){"form"===n?c.each(t,function(t,i){"object"===_typeof(i)&&(i=JSON.stringify(i)),d.append(n+"["+t+"]",i)}):d.append(n,t)}),c.ajax({url:a.api_url,method:"POST",contentType:!1,processData:!1,data:d}).done(function(t){if(a.onDialogHide.call(n.tinvwl_dialog,n),"object"===_typeof(t))for(var i in t)"function"==typeof a.onAction[i]&&a.onAction[i].call(n,t[i]);else"function"==typeof a.onAction.msg&&a.onAction.msg.call(n,t)})};var a=c.extend(!0,{},i,t);return c(this).each(function(){if(!c(this).attr("data-tinv-wl-list"))return!1;if(a.dialogbox&&a.dialogbox.length&&(this.tinvwl_dialog=a.dialogbox),this.tinvwl_dialog||(this.tinvwl_dialog=a.onGetDialogBox.call(this)),!this.tinvwl_dialog){var t=c(this).nextAll(a.class.dialogbox).eq(0);t.length&&(this.tinvwl_dialog=t)}if(this.tinvwl_dialog){a.onPrepareDialogBox.call(this.tinvwl_dialog),"function"!=typeof this.tinvwl_dialog.update_list&&(this.tinvwl_dialog.update_list=function(t){var n=c(this).find(a.class.select).eq(0);c(this).find(a.class.newtitle).hide().val(""),n.html(""),c.each(t,function(t,i){a.onCreateWishList.call(n,i)}),a.text_create&&a.onCreateWishList.call(n,{ID:"",title:a.text_create,in:!1}),a.onMultiProductAlreadyIn.call(n,t),a.onSelectWishList.call(n,t),c(this).find(a.class.newtitle).toggle(""===n.val())}),"function"!=typeof this.tinvwl_dialog.show_list&&(this.tinvwl_dialog.show_list=function(){var t=JSON.parse(c(this).attr("data-tinv-wl-list"))||[];t.length?(t=a.onPrepareList.call(t)||t,this.tinvwl_dialog.update_list(t),a.onDialogShow.call(this.tinvwl_dialog,this)):a.onActionProduct.call(this)});var o=this;c(this.tinvwl_dialog).find(a.class.dialogbutton).off("click").on("click",function(){var t,i=c(o.tinvwl_dialog).find(a.class.select),n=c(o.tinvwl_dialog).find(a.class.newtitle);i.val()||n.val()?a.onActionProduct.call(o,i.val(),n.val()):((t=n.is(":visible")?n:i).addClass("empty-name-wishlist"),window.setTimeout(function(){t.removeClass("empty-name-wishlist")},1e3))})}c(this).off("click").on("click",a.onClick),a.onInited.call(this,a)})},c(document).ready(function(){c("body").on("click keydown",".tinvwl_add_to_wishlist_button",function(t){if("keydown"===t.type){var i=void 0!==t.key?t.key:t.keyCode;if(!("Enter"===i||13===i||0<=["Spacebar"," "].indexOf(i)||32===i))return;t.preventDefault()}if(c("body").trigger("tinvwl_add_to_wishlist_button_click",[this]),c(this).is(".disabled-add-wishlist"))return t.preventDefault(),void window.alert(tinvwl_add_to_wishlist.i18n_make_a_selection_text);c(this).is(".inited-add-wishlist")||c(this).tinvwl_to_wishlist({onInited:function(t){c(this).addClass("inited-add-wishlist"),t.onClick.call(this)}})}),c(document).on("hide_variation",".variations_form",function(t){var i=c('.tinvwl_add_to_wishlist_button:not(.tinvwl-loop)[data-tinv-wl-product="'+c(this).data("product_id")+'"]');if(i.attr("data-tinv-wl-productvariation",0),i.length&&i.attr("data-tinv-wl-list")){var n=JSON.parse(i.attr("data-tinv-wl-list")),o=!1,e="1"==window.tinvwl_add_to_wishlist.simple_flow;for(var a in n)n[a].hasOwnProperty("in")&&Array.isArray(n[a].in)&&-1<(n[a].in||[]).indexOf(0)&&(o=!0);i.toggleClass("tinvwl-product-in-list",o).toggleClass("tinvwl-product-make-remove",o&&e).attr("data-tinv-wl-action",o&&e?"remove":"addto")}i.length&&!tinvwl_add_to_wishlist.allow_parent_variable&&(t.preventDefault(),i.addClass("disabled-add-wishlist"))}),c(document).on("show_variation",".variations_form",function(t,i,n){var o=c('.tinvwl_add_to_wishlist_button:not(.tinvwl-loop)[data-tinv-wl-product="'+c(this).data("product_id")+'"]');if(o.attr("data-tinv-wl-productvariation",i.variation_id),o.length&&o.attr("data-tinv-wl-list")){var e=JSON.parse(o.attr("data-tinv-wl-list")),a=!1,l="1"==window.tinvwl_add_to_wishlist.simple_flow;for(var s in e)e[s].hasOwnProperty("in")&&Array.isArray(e[s].in)&&-1<(e[s].in||[]).indexOf(i.variation_id)&&(a=!0);o.toggleClass("tinvwl-product-in-list",a).toggleClass("tinvwl-product-make-remove",a&&l).attr("data-tinv-wl-action",a&&l?"remove":"addto")}t.preventDefault(),o.removeClass("disabled-add-wishlist")}),c(window).on("storage onstorage",function(t){if(s===t.originalEvent.key&&localStorage.getItem(s)!==sessionStorage.getItem(s)&&localStorage.getItem(s)){var i=JSON.parse(localStorage.getItem(s));"object"===_typeof(i)&&null!==i&&(i.hasOwnProperty("products")||i.hasOwnProperty("counter"))&&d(localStorage.getItem(s))}});var n=[],i=!1;c("a.tinvwl_add_to_wishlist_button").each(function(){"undefined"!==c(this).data("tinv-wl-product")&&c(this).data("tinv-wl-product")&&n.push(c(this).data("tinv-wl-product"))}),c(".wishlist_products_counter_number").each(function(){i=!0});function o(){if(n.length||i){var t={};tinvwl_add_to_wishlist.wpml&&(t.lang=tinvwl_add_to_wishlist.wpml),c.ajax({url:tinvwl_add_to_wishlist.plugin_url+"includes/api/ajax.php",method:"POST",data:t,beforeSend:function(t){t.setRequestHeader("X-WP-Nonce",tinvwl_add_to_wishlist.nonce)}}).done(function(t){d(JSON.stringify(t)),r(t)}).fail(function(){!function(){if(n.length||i){var t={ids:n,counter:i,tinvwl_request:!0};tinvwl_add_to_wishlist.wpml&&(t.lang=tinvwl_add_to_wishlist.wpml),c.ajax({url:tinvwl_add_to_wishlist.rest_root+"wishlist/v1/products",method:"POST",data:t,beforeSend:function(t){t.setRequestHeader("X-WP-Nonce",tinvwl_add_to_wishlist.nonce)}}).done(function(t){d(JSON.stringify(t)),r(t)})}}()})}}function e(){if(l&&(tinvwl_add_to_wishlist.update_wishlists_data&&localStorage.setItem(s,""),localStorage.getItem(s))){var t=JSON.parse(localStorage.getItem(s));if("object"===_typeof(t)&&null!==t&&(t.hasOwnProperty("products")||t.hasOwnProperty("counter"))&&(!t.hasOwnProperty("lang")&&!tinvwl_add_to_wishlist.wpml||tinvwl_add_to_wishlist.wpml&&t.lang===tinvwl_add_to_wishlist.wpml))return void r(t)}tinvwl_add_to_wishlist.block_ajax_wishlists_data||o()}e();var t=new MutationObserver(function(t){n=[],t.forEach(function(t){var i=t.addedNodes;null!==i&&c(i).each(function(){var t=c(this).find(".tinvwl_add_to_wishlist_button");t.length&&t.each(function(){"undefined"!==c(this).data("tinv-wl-product")&&c(this).data("tinv-wl-product")&&n.push(c(this).data("tinv-wl-product"))})})}),n.length&&e()}),a=document.body;t.observe(a,{childList:!0,subtree:!0})});var l=!0,s=tinvwl_add_to_wishlist.hash_key;try{l="sessionStorage"in window&&null!==window.sessionStorage,window.sessionStorage.setItem("ti","test"),window.sessionStorage.removeItem("ti"),window.localStorage.setItem("ti","test"),window.localStorage.removeItem("ti")}catch(t){l=!1}function r(t){var l="1"==window.tinvwl_add_to_wishlist.simple_flow;l&&c("a.tinvwl_add_to_wishlist_button").each(function(){c(this).removeClass("tinvwl-product-make-remove").removeClass("tinvwl-product-already-on-wishlist").removeClass("tinvwl-product-in-list").attr("data-tinv-wl-action","addto").attr("data-tinv-wl-list","[]")}),c("body").trigger("tinvwl_wishlist_mark_products",[t]),c.each(t.products,function(t,e){var a=t;c('a.tinvwl_add_to_wishlist_button[data-tinv-wl-product="'+a+'"]').each(function(){var t=parseInt(c(this).attr("data-tinv-wl-productvariation")),i=c(this).data("tinv-wl-productvariations")||[],n=!1;for(var o in e)e[o].hasOwnProperty("in")&&Array.isArray(e[o].in)&&(-1<(e[o].in||[]).indexOf(a)||-1<(e[o].in||[]).indexOf(t)||i.some(function(t){return 0<=(e[o].in||[]).indexOf(t)}))&&(n=!0);c("body").trigger("tinvwl_wishlist_product_marked",[this,n]),c(this).attr("data-tinv-wl-list",JSON.stringify(e)).toggleClass("tinvwl-product-in-list",n).toggleClass("tinvwl-product-make-remove",n&&l).attr("data-tinv-wl-action",n&&l?"remove":"addto")})}),function(t){"1"==window.tinvwl_add_to_wishlist.hide_zero_counter&&0===t&&(t="false");jQuery("i.wishlist-icon").addClass("added"),"false"!==t?(jQuery(".wishlist_products_counter_number, body.theme-woostify .wishlist-item-count").html(t),jQuery("i.wishlist-icon").attr("data-icon-label",t)):(jQuery(".wishlist_products_counter_number, body.theme-woostify .wishlist-item-count").html("").closest("span.wishlist-counter-with-products").removeClass("wishlist-counter-with-products"),jQuery("i.wishlist-icon").removeAttr("data-icon-label"));var i=!("0"==t||"false"==t);jQuery(".wishlist_products_counter").toggleClass("wishlist-counter-with-products",i),setTimeout(function(){jQuery("i.wishlist-icon").removeClass("added")},500)}(t.counter)}function d(t){l&&(localStorage.setItem(s,t),sessionStorage.setItem(s,t),r(JSON.parse(t)))}}(jQuery),function(o){o(document).ready(function(){if(o("#tinvwl_manage_actions, #tinvwl_product_actions").addClass("form-control").parent().wrapInner('<div class="tinvwl-input-group tinvwl-no-full">').find("button").wrap('<span class="tinvwl-input-group-btn">'),o(".tinv-lists-nav").each(function(){o(this).html().trim().length||o(this).remove()}),o("body").on("click",".social-buttons .social:not(.social-email,.social-whatsapp,.social-clipboard)",function(t){var i=window.open(o(this).attr("href"),o(this).attr("title"),"width=420,height=320,resizable=yes,scrollbars=yes,status=yes");i&&(i.focus(),t.preventDefault())}),"undefined"!=typeof ClipboardJS){new ClipboardJS(".social-buttons .social.social-clipboard",{text:function(t){return t.getAttribute("href")}}).on("success",function(t){showTooltip(t.trigger,tinvwl_add_to_wishlist.tinvwl_clipboard)});for(var t=document.querySelectorAll(".social-buttons .social.social-clipboard"),i=0;i<t.length;i++)t[i].addEventListener("mouseleave",clearTooltip),t[i].addEventListener("blur",clearTooltip)}o("body").on("click",".social-buttons .social.social-clipboard",function(t){t.preventDefault()}),o("body").on("click",".tinv-wishlist .tinv-overlay, .tinv-wishlist .tinv-close-modal, .tinv-wishlist .tinvwl_button_close",function(t){t.preventDefault(),o(this).parents(".tinv-modal:first").removeClass("tinv-modal-open"),o("body").trigger("tinvwl_modal_closed",[this])}),o("body").on("click",".tinv-wishlist .tinvwl-btn-onclick",function(t){o(this).data("url")&&(t.preventDefault(),window.location=o(this).data("url"))});var n=o(".tinv-wishlist .navigation-button");n.length&&n.each(function(){var t=o(this).find("> li");t.length<5&&t.parent().addClass("tinvwl-btns-count-"+t.length)}),o(".tinv-login .showlogin").off("click").on("click",function(t){t.preventDefault(),o(this).closest(".tinv-login").find(".login").toggle()}),o(".tinv-wishlist table.tinvwl-table-manage-list tfoot td").each(function(){o(this).toggle(!!o(this).children().not(".look_in").length||!!o(this).children(".look_in").children().length)})})}(jQuery),function(o){o.fn.tinvwl_break_submit=function(t){var i={selector:"input, select, textarea",ifempty:!0,invert:!1,validate:function(){return o(this).val()},rule:function(){var t=o(this).parents("form").eq(0).find(n.selector),i=n.invert;return 0===t.length?n.ifempty:(t.each(function(){i&&!n.invert||!i&&n.invert||(i=Boolean(n.validate.call(o(this))))}),i)}},n=o.extend(!0,{},i,t);return o(this).each(function(){o(this).on("click",function(t){var i=[];void 0!==o(this).attr("tinvwl_break_submit")&&(i=o(this).attr("tinvwl_break_submit").split(",")),-1!==jQuery.inArray(n.selector,i)&&(i=[]),n.rule.call(o(this))||0!==i.length||(alert(window.tinvwl_add_to_wishlist.tinvwl_break_submit),t.preventDefault()),i.push(n.selector),o(this).attr("tinvwl_break_submit",i),n.rule.call(o(this))&&o(this).removeAttr("tinvwl_break_submit")})})},o(document).ready(function(){o(".tinvwl-break-input").tinvwl_break_submit({selector:".tinvwl-break-input-filed"}),o(".tinvwl-break-checkbox").tinvwl_break_submit({selector:"table td input[type=checkbox]",validate:function(){return o(this).is(":checked")}}),o(".global-cb").on("click",function(){o(this).closest("table").eq(0).find(".product-cb input[type=checkbox], .wishlist-cb input[type=checkbox]").prop("checked",o(this).is(":checked"))})})}(jQuery);
includes/api/ajax.php CHANGED
@@ -2,112 +2,114 @@
2
 
3
  // Init
4
  // -----------------------------------------------------------------------
5
- define('DOING_AJAX', true);
6
- define('SHORTINIT', true);
7
 
8
  // WP Load
9
  // -----------------------------------------------------------------------
10
 
11
- $config_file = dirname(dirname(dirname(dirname(dirname(dirname(__FILE__)))))) . '/wp-config.php';
12
- $load_file = dirname(dirname(dirname(dirname(dirname(dirname(__FILE__)))))) . '/wp-load.php';
13
 
14
- if (file_exists($config_file)) {
15
- if (!defined('ABSPATH')) {
16
- @require($config_file);
17
  }
18
- require(ABSPATH . '/wp-load.php');
19
- } elseif (file_exists($load_file)) {
20
- require($load_file);
 
 
21
  }
22
- if (!defined('ABSPATH')) {
23
  exit;
24
  }
25
 
26
  wp_plugin_directory_constants();
27
- require_once(ABSPATH . WPINC . '/class-wp-user.php');
28
- require_once(ABSPATH . WPINC . '/class-wp-roles.php');
29
- require_once(ABSPATH . WPINC . '/class-wp-role.php');
30
- require_once(ABSPATH . WPINC . '/class-wp-session-tokens.php');
31
- require_once(ABSPATH . WPINC . '/class-wp-user-meta-session-tokens.php');
32
- require_once(ABSPATH . WPINC . '/formatting.php');
33
- require_once(ABSPATH . WPINC . '/capabilities.php');
34
  //require_once ( ABSPATH . WPINC . '/query.php' ); // - might be useful
35
- require_once(ABSPATH . WPINC . '/user.php');
36
- if (file_exists(ABSPATH . WPINC . '/class-wp-application-passwords.php')) {
37
- require_once(ABSPATH . WPINC . '/class-wp-application-passwords.php'); // From WP 5.6.0
38
  }
39
- require_once(ABSPATH . WPINC . '/meta.php');
40
 
41
  wp_cookie_constants();
42
 
43
- require_once(ABSPATH . WPINC . '/vars.php');
44
- require_once(ABSPATH . WPINC . '/kses.php');
45
- require_once(ABSPATH . WPINC . '/rest-api.php');
46
- require_once(ABSPATH . WPINC . '/pluggable.php');
47
 
48
  // Get the nonce.
49
- if (isset($_SERVER['HTTP_X_WP_NONCE'])) {
50
  $nonce = $_SERVER['HTTP_X_WP_NONCE'];
51
  } else {
52
- wp_send_json(array('error' => 'Forbidden: unauthorized request.'), 403);
53
  }
54
 
55
- if (is_user_logged_in()) {
56
  // Check the nonce.
57
- $result = wp_verify_nonce($nonce, 'wp_rest');
58
 
59
- if (!$result) {
60
- wp_send_json(array('error' => 'Forbidden: wrong nonce.'), 403);
61
  }
62
  }
63
 
64
  // Response headers
65
- @header('X-Robots-Tag: noindex');
66
  send_nosniff_header();
67
  nocache_headers();
68
 
69
  // DB query.
70
  global $wpdb;
71
 
72
- $table = sprintf('%s%s', $wpdb->prefix, 'tinvwl_items');
73
- $table_lists = sprintf('%s%s', $wpdb->prefix, 'tinvwl_lists');
74
- $table_translations = sprintf('%s%s', $wpdb->prefix, 'icl_translations');
75
- $table_languages = sprintf('%s%s', $wpdb->prefix, 'icl_languages');
76
- $lang = filter_input(INPUT_POST, 'lang', FILTER_SANITIZE_STRING);
77
 
78
  $data = $products = $wishlists = $results = array();
79
 
80
  $share_key = false;
81
 
82
- if (is_user_logged_in()) {
83
  $data['author'] = get_current_user_id();
84
  } else {
85
- $share_key = filter_input(INPUT_COOKIE, 'tinv_wishlistkey');
86
  }
87
 
88
- if ((isset($data['author']) && $data['author']) || $share_key) {
89
 
90
  $default = array(
91
- 'count' => 99999,
92
- 'field' => null,
93
- 'offset' => 0,
94
- 'order' => 'DESC',
95
  'order_by' => 'date',
96
  'external' => true,
97
- 'sql' => '',
98
  );
99
 
100
- foreach ($default as $_k => $_v) {
101
- if (array_key_exists($_k, $data)) {
102
- $default[$_k] = $data[$_k];
103
- unset($data[$_k]);
104
  }
105
  }
106
 
107
- $default['offset'] = absint($default['offset']);
108
- $default['count'] = absint($default['count']);
109
 
110
- if ($lang) {
111
  $default['field'] = $table . '.ID, t.element_id AS product_id, t2.element_id AS variation_id, ' . $table . '.formdata,' . $table . '.author,' . $table . '.date,' . $table . '.quantity,' . $table . '.price,' . $table . '.in_stock,';
112
  } else {
113
  $default['field'] = $table . '.*, ';
@@ -117,10 +119,10 @@ if ((isset($data['author']) && $data['author']) || $share_key) {
117
 
118
  $sql = "SELECT {$default[ 'field' ]} FROM `{$table}` INNER JOIN `{$table_lists}` ON `{$table}`.`wishlist_id` = `{$table_lists}`.`ID` AND `{$table_lists}`.`type` = 'default'";
119
 
120
- if ($share_key) {
121
  $sql .= " AND `{$table_lists}`.`share_key` = '{$share_key}'";
122
  }
123
- if ($lang) {
124
  $sql .= "LEFT JOIN {$table_translations} tr ON
125
  {$table}.product_id = tr.element_id AND tr.element_type = 'post_product'
126
  LEFT JOIN {$table_translations} tr2 ON
@@ -136,79 +138,79 @@ JOIN {$table_languages} l ON
136
  }
137
  $where = '1';
138
 
139
- if (!empty($data) && is_array($data)) {
140
 
141
- if (array_key_exists('meta', $data)) {
142
  $product_id = $variation_id = 0;
143
- if (array_key_exists('product_id', $data)) {
144
  $product_id = $data['product_id'];
145
  }
146
- if (array_key_exists('variation_id', $data)) {
147
  $variation_id = $data['variation_id'];
148
  }
149
  $data['formdata'] = '';
150
- unset($data['meta']);
151
  }
152
 
153
- foreach ($data as $f => $v) {
154
- $s = is_array($v) ? ' IN ' : '=';
155
- if (is_array($v)) {
156
- foreach ($v as $_f => $_v) {
157
- $v[$_f] = $wpdb->prepare('%s', $_v);
158
  }
159
- $v = implode(',', $v);
160
  $v = "($v)";
161
  } else {
162
- $v = $wpdb->prepare('%s', $v);
163
  }
164
- $data[$f] = sprintf($table . '.' . '`%s`%s%s', $f, $s, $v);
165
  }
166
 
167
- $where = implode(' AND ', $data);
168
 
169
  $sql .= ' WHERE ' . $where;
170
  }
171
 
172
- $sql .= sprintf(' ORDER BY `%s` %s LIMIT %d,%d;', $default['order_by'], $default['order'], $default['offset'], $default['count']);
173
 
174
- if (!empty($default['sql'])) {
175
- $replacer = $replace = array();
176
- $replace[0] = '{table}';
177
  $replacer[0] = $table;
178
- $replace[1] = '{where}';
179
  $replacer[1] = $where;
180
 
181
- foreach ($default as $key => $value) {
182
- $i = count($replace);
183
 
184
- $replace[$i] = '{' . $key . '}';
185
- $replacer[$i] = $value;
186
  }
187
 
188
- $sql = str_replace($replace, $replacer, $default['sql']);
189
  }
190
 
191
- $results = $wpdb->get_results($sql, ARRAY_A);
192
 
193
- if (!empty($results)) {
194
- foreach ($results as $product) {
195
- $wishlists[$product['wishlist_id']] = array(
196
- 'ID' => (int)$product['wishlist_id'],
197
- 'title' => $product['wishlist_title'],
198
- 'status' => $product['wishlist_status'],
199
  'share_key' => $product['wishlist_share_key'],
200
  );
201
 
202
  }
203
 
204
- foreach ($wishlists as $wishlist) {
205
 
206
- foreach ($results as $product) {
207
- if (array_key_exists($product['product_id'], $products)) {
208
- $products[$product['product_id']][$wishlist['ID']]['in'][] = (int)$product['variation_id'];
209
  } else {
210
- $products[$product['product_id']][$wishlist['ID']] = $wishlist;
211
- $products[$product['product_id']][$wishlist['ID']]['in'][] = (int)$product['variation_id'];
212
  }
213
 
214
  }
@@ -217,16 +219,16 @@ JOIN {$table_languages} l ON
217
 
218
  }
219
 
220
- $count = is_array($results) ? array_sum(array_column($results, 'quantity')) : 0;
221
 
222
  $response = array(
223
  'products' => $products,
224
- 'counter' => $count,
225
  );
226
 
227
- if ($lang) {
228
  $response['lang'] = $lang;
229
  }
230
 
231
 
232
- wp_send_json($response);
2
 
3
  // Init
4
  // -----------------------------------------------------------------------
5
+ define( 'DOING_AJAX', true );
6
+ define( 'SHORTINIT', true );
7
 
8
  // WP Load
9
  // -----------------------------------------------------------------------
10
 
11
+ $config_file = dirname( dirname( dirname( dirname( dirname( dirname( __FILE__ ) ) ) ) ) ) . '/wp-config.php';
12
+ $load_file = dirname( dirname( dirname( dirname( dirname( dirname( __FILE__ ) ) ) ) ) ) . '/wp-load.php';
13
 
14
+ if ( file_exists( $config_file ) ) {
15
+ if ( ! defined( 'ABSPATH' ) ) {
16
+ @require( $config_file );
17
  }
18
+ if ( defined( 'ABSPATH' ) ) {
19
+ require( ABSPATH . '/wp-load.php' );
20
+ }
21
+ } elseif ( file_exists( $load_file ) ) {
22
+ require( $load_file );
23
  }
24
+ if ( ! defined( 'ABSPATH' ) ) {
25
  exit;
26
  }
27
 
28
  wp_plugin_directory_constants();
29
+ require_once( ABSPATH . WPINC . '/class-wp-user.php' );
30
+ require_once( ABSPATH . WPINC . '/class-wp-roles.php' );
31
+ require_once( ABSPATH . WPINC . '/class-wp-role.php' );
32
+ require_once( ABSPATH . WPINC . '/class-wp-session-tokens.php' );
33
+ require_once( ABSPATH . WPINC . '/class-wp-user-meta-session-tokens.php' );
34
+ require_once( ABSPATH . WPINC . '/formatting.php' );
35
+ require_once( ABSPATH . WPINC . '/capabilities.php' );
36
  //require_once ( ABSPATH . WPINC . '/query.php' ); // - might be useful
37
+ require_once( ABSPATH . WPINC . '/user.php' );
38
+ if ( file_exists( ABSPATH . WPINC . '/class-wp-application-passwords.php' ) ) {
39
+ require_once( ABSPATH . WPINC . '/class-wp-application-passwords.php' ); // From WP 5.6.0
40
  }
41
+ require_once( ABSPATH . WPINC . '/meta.php' );
42
 
43
  wp_cookie_constants();
44
 
45
+ require_once( ABSPATH . WPINC . '/vars.php' );
46
+ require_once( ABSPATH . WPINC . '/kses.php' );
47
+ require_once( ABSPATH . WPINC . '/rest-api.php' );
48
+ require_once( ABSPATH . WPINC . '/pluggable.php' );
49
 
50
  // Get the nonce.
51
+ if ( isset( $_SERVER['HTTP_X_WP_NONCE'] ) ) {
52
  $nonce = $_SERVER['HTTP_X_WP_NONCE'];
53
  } else {
54
+ wp_send_json( array( 'error' => 'Forbidden: unauthorized request.' ), 403 );
55
  }
56
 
57
+ if ( is_user_logged_in() ) {
58
  // Check the nonce.
59
+ $result = wp_verify_nonce( $nonce, 'wp_rest' );
60
 
61
+ if ( ! $result ) {
62
+ wp_send_json( array( 'error' => 'Forbidden: wrong nonce.' ), 403 );
63
  }
64
  }
65
 
66
  // Response headers
67
+ @header( 'X-Robots-Tag: noindex' );
68
  send_nosniff_header();
69
  nocache_headers();
70
 
71
  // DB query.
72
  global $wpdb;
73
 
74
+ $table = sprintf( '%s%s', $wpdb->prefix, 'tinvwl_items' );
75
+ $table_lists = sprintf( '%s%s', $wpdb->prefix, 'tinvwl_lists' );
76
+ $table_translations = sprintf( '%s%s', $wpdb->prefix, 'icl_translations' );
77
+ $table_languages = sprintf( '%s%s', $wpdb->prefix, 'icl_languages' );
78
+ $lang = filter_input( INPUT_POST, 'lang', FILTER_SANITIZE_STRING );
79
 
80
  $data = $products = $wishlists = $results = array();
81
 
82
  $share_key = false;
83
 
84
+ if ( is_user_logged_in() ) {
85
  $data['author'] = get_current_user_id();
86
  } else {
87
+ $share_key = filter_input( INPUT_COOKIE, 'tinv_wishlistkey' );
88
  }
89
 
90
+ if ( ( isset( $data['author'] ) && $data['author'] ) || $share_key ) {
91
 
92
  $default = array(
93
+ 'count' => 99999,
94
+ 'field' => null,
95
+ 'offset' => 0,
96
+ 'order' => 'DESC',
97
  'order_by' => 'date',
98
  'external' => true,
99
+ 'sql' => '',
100
  );
101
 
102
+ foreach ( $default as $_k => $_v ) {
103
+ if ( array_key_exists( $_k, $data ) ) {
104
+ $default[ $_k ] = $data[ $_k ];
105
+ unset( $data[ $_k ] );
106
  }
107
  }
108
 
109
+ $default['offset'] = absint( $default['offset'] );
110
+ $default['count'] = absint( $default['count'] );
111
 
112
+ if ( $lang ) {
113
  $default['field'] = $table . '.ID, t.element_id AS product_id, t2.element_id AS variation_id, ' . $table . '.formdata,' . $table . '.author,' . $table . '.date,' . $table . '.quantity,' . $table . '.price,' . $table . '.in_stock,';
114
  } else {
115
  $default['field'] = $table . '.*, ';
119
 
120
  $sql = "SELECT {$default[ 'field' ]} FROM `{$table}` INNER JOIN `{$table_lists}` ON `{$table}`.`wishlist_id` = `{$table_lists}`.`ID` AND `{$table_lists}`.`type` = 'default'";
121
 
122
+ if ( $share_key ) {
123
  $sql .= " AND `{$table_lists}`.`share_key` = '{$share_key}'";
124
  }
125
+ if ( $lang ) {
126
  $sql .= "LEFT JOIN {$table_translations} tr ON
127
  {$table}.product_id = tr.element_id AND tr.element_type = 'post_product'
128
  LEFT JOIN {$table_translations} tr2 ON
138
  }
139
  $where = '1';
140
 
141
+ if ( ! empty( $data ) && is_array( $data ) ) {
142
 
143
+ if ( array_key_exists( 'meta', $data ) ) {
144
  $product_id = $variation_id = 0;
145
+ if ( array_key_exists( 'product_id', $data ) ) {
146
  $product_id = $data['product_id'];
147
  }
148
+ if ( array_key_exists( 'variation_id', $data ) ) {
149
  $variation_id = $data['variation_id'];
150
  }
151
  $data['formdata'] = '';
152
+ unset( $data['meta'] );
153
  }
154
 
155
+ foreach ( $data as $f => $v ) {
156
+ $s = is_array( $v ) ? ' IN ' : '=';
157
+ if ( is_array( $v ) ) {
158
+ foreach ( $v as $_f => $_v ) {
159
+ $v[ $_f ] = $wpdb->prepare( '%s', $_v );
160
  }
161
+ $v = implode( ',', $v );
162
  $v = "($v)";
163
  } else {
164
+ $v = $wpdb->prepare( '%s', $v );
165
  }
166
+ $data[ $f ] = sprintf( $table . '.' . '`%s`%s%s', $f, $s, $v );
167
  }
168
 
169
+ $where = implode( ' AND ', $data );
170
 
171
  $sql .= ' WHERE ' . $where;
172
  }
173
 
174
+ $sql .= sprintf( ' ORDER BY `%s` %s LIMIT %d,%d;', $default['order_by'], $default['order'], $default['offset'], $default['count'] );
175
 
176
+ if ( ! empty( $default['sql'] ) ) {
177
+ $replacer = $replace = array();
178
+ $replace[0] = '{table}';
179
  $replacer[0] = $table;
180
+ $replace[1] = '{where}';
181
  $replacer[1] = $where;
182
 
183
+ foreach ( $default as $key => $value ) {
184
+ $i = count( $replace );
185
 
186
+ $replace[ $i ] = '{' . $key . '}';
187
+ $replacer[ $i ] = $value;
188
  }
189
 
190
+ $sql = str_replace( $replace, $replacer, $default['sql'] );
191
  }
192
 
193
+ $results = $wpdb->get_results( $sql, ARRAY_A );
194
 
195
+ if ( ! empty( $results ) ) {
196
+ foreach ( $results as $product ) {
197
+ $wishlists[ $product['wishlist_id'] ] = array(
198
+ 'ID' => (int) $product['wishlist_id'],
199
+ 'title' => $product['wishlist_title'],
200
+ 'status' => $product['wishlist_status'],
201
  'share_key' => $product['wishlist_share_key'],
202
  );
203
 
204
  }
205
 
206
+ foreach ( $wishlists as $wishlist ) {
207
 
208
+ foreach ( $results as $product ) {
209
+ if ( array_key_exists( $product['product_id'], $products ) ) {
210
+ $products[ $product['product_id'] ][ $wishlist['ID'] ]['in'][] = (int) $product['variation_id'];
211
  } else {
212
+ $products[ $product['product_id'] ][ $wishlist['ID'] ] = $wishlist;
213
+ $products[ $product['product_id'] ][ $wishlist['ID'] ]['in'][] = (int) $product['variation_id'];
214
  }
215
 
216
  }
219
 
220
  }
221
 
222
+ $count = is_array( $results ) ? array_sum( array_column( $results, 'quantity' ) ) : 0;
223
 
224
  $response = array(
225
  'products' => $products,
226
+ 'counter' => $count,
227
  );
228
 
229
+ if ( $lang ) {
230
  $response['lang'] = $lang;
231
  }
232
 
233
 
234
+ wp_send_json( $response );
integrations/product-extras-for-woocommerce.php CHANGED
@@ -4,7 +4,7 @@
4
  *
5
  * @name WooCommerce Product Add-Ons Ultimate
6
  *
7
- * @version 3.6.3
8
  *
9
  * @slug product-extras-for-woocommerce
10
  *
@@ -13,7 +13,7 @@
13
  */
14
 
15
  // If this file is called directly, abort.
16
- if (!defined('ABSPATH')) {
17
  exit;
18
  }
19
 
@@ -24,24 +24,24 @@ $slug = "product-extras-for-woocommerce";
24
 
25
  $name = "WooCommerce Product Add-Ons Ultimate";
26
 
27
- $available = defined('PEWC_FILE');
28
 
29
  $tinvwl_integrations = is_array( $tinvwl_integrations ) ? $tinvwl_integrations : [];
30
 
31
- $tinvwl_integrations[$slug] = array(
32
- 'name' => $name,
33
  'available' => $available,
34
  );
35
 
36
- if (!tinv_get_option('integrations', $slug)) {
37
  return;
38
  }
39
 
40
- if (!$available) {
41
  return;
42
  }
43
 
44
- if (!function_exists('tinv_wishlist_item_meta_pewc')) {
45
 
46
  /**
47
  * Set description for meta WooCommerce Product Add-Ons Ultimate
@@ -53,103 +53,150 @@ if (!function_exists('tinv_wishlist_item_meta_pewc')) {
53
  * @return array
54
  */
55
 
56
- function tinv_wishlist_item_meta_pewc($item_data, $product_id, $variation_id)
57
- {
58
 
59
- if (defined('PEWC_FILE')) {
60
  // Check for product_extra groups
61
- $product_extra_groups = pewc_get_extra_fields($product_id);
62
- $hidden_group_types = apply_filters('pewc_hidden_field_types_in_cart', array());
63
 
64
  $posted_data = array();
65
 
66
- foreach ($item_data as $values) {
67
- $posted_data[$values['key']] = $values['display'];
68
  }
69
 
70
- if ($product_extra_groups) {
71
 
72
- foreach ($product_extra_groups as $group) {
73
 
74
- if (isset($group['items'])) {
75
 
76
- foreach ($group['items'] as $item) {
77
 
78
- if (in_array($item['field_type'], $hidden_group_types)) {
79
  // Don't add this to the cart if it's a hidden field type
80
  continue;
81
  }
82
 
83
- $is_visible = pewc_get_conditional_field_visibility($item['id'], $item, $group['items'], $product_id, $posted_data, $variation_id);
84
 
85
- if (!$is_visible) {
86
  continue;
87
  }
88
 
89
  // Don't display hidden fields
90
- if (isset($item['hidden_calculation'])) {
91
  continue;
92
  }
93
 
 
94
  // Added in 3.5.3 to allow us to link parent products with children in cart
95
- $display_product_meta = apply_filters('pewc_display_child_product_meta', false, $item);
96
 
97
- if (isset($item['field_type'])) {
98
 
99
- if ($item['field_type'] == 'products' && !$display_product_meta) {
100
  continue;
101
  }
102
 
103
- $price = '';
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
104
 
105
- if (isset($item['field_flatrate'])) {
106
- $price = '<span class="pewc-flat-rate-cart-label">(' . __('Flat rate cost', 'ti-woocommerce-wishlist') . ')</span>';
107
  }
108
 
109
- $price = apply_filters('pewc_filter_cart_item_price', $price, $item);
 
 
110
 
111
- $item['label'] = isset($item['field_label']) ? sanitize_text_field($item['field_label']) : '';
112
 
113
- $value = (isset($item_data[$item['id']]) && isset($item_data[$item['id']]['display'])) ? $item_data[$item['id']]['display'] : '';
114
 
115
- if ($item['field_type'] == 'textarea') {
116
- $value = sanitize_textarea_field(stripslashes($value));
117
- } else if (in_array($item['field_type'], array(
 
 
118
  'image_swatch',
119
  'radio',
120
  'upload'
121
- ))) {
122
- $value = wp_kses_post(stripslashes($value[0]));
123
  } else {
124
- $value = sanitize_text_field(stripslashes($value));
125
  }
126
 
127
  $item['value'] = $value;
128
 
129
- if ($item['field_type'] == 'upload' || $item['field_type'] == 'information') {
130
  continue;
131
  }
132
 
133
- if ($item['field_type'] == 'checkbox') {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
134
  $item_data[] = array(
135
- 'key' => sanitize_text_field($item['label']),
136
- 'display' => '<span class="pewc-price pewc-cart-item-price">' . sanitize_text_field($price) . '</span>',
137
  );
138
- } else if ($item['field_type'] == 'checkbox_group') {
 
139
  $item_data[] = array(
140
- 'key' => sanitize_text_field($item['label']),
141
- 'display' => str_replace(' | ', '<br>', $item['value']),
142
  );
143
- } else if ($item['field_type'] == 'name_price') {
144
- $value = wc_price($item['value']);
145
  $item_data[] = array(
146
- 'key' => sanitize_text_field($item['label']),
147
- 'display' => sanitize_text_field($value),
148
  );
149
  } else {
 
 
 
 
 
 
 
 
150
  $item_data[] = array(
151
- 'key' => sanitize_text_field($item['label']),
152
- 'display' => sanitize_text_field($item['value']),
153
  );
154
  }
155
  }
@@ -159,19 +206,19 @@ if (!function_exists('tinv_wishlist_item_meta_pewc')) {
159
  }
160
  }
161
 
162
- foreach (array_keys($item_data) as $key) {
163
- if (strpos($key, 'pewc') === 0) {
164
- unset($item_data[$key]);
165
  }
166
  }
167
 
168
  return $item_data;
169
  }
170
 
171
- add_filter('tinvwl_wishlist_item_meta_post', 'tinv_wishlist_item_meta_pewc', 10, 3);
172
  }
173
 
174
- if (!function_exists('tinvwl_item_price_pewc')) {
175
 
176
  /**
177
  * Modify price for WooCommerce Product Add-Ons Ultimate
@@ -182,68 +229,67 @@ if (!function_exists('tinvwl_item_price_pewc')) {
182
  *
183
  * @return string
184
  */
185
- function tinvwl_item_price_pewc($price, $wl_product, $product)
186
- {
187
 
188
- if (defined('PEWC_FILE')) {
189
 
190
  $product_price = $product->get_price();
191
- $product_id = $product->get_id();
192
- $extra_price = 0;
193
 
194
- $product_extra_groups = pewc_get_extra_fields($product_id);
195
 
196
- if ($product_extra_groups) {
197
 
198
- foreach ($product_extra_groups as $group) {
199
 
200
- if (isset($group['items'])) {
201
 
202
- foreach ($group['items'] as $item) {
203
 
204
- $show_option_prices_in_cart = pewc_show_option_prices_in_cart($item);
205
 
206
 
207
- $group_id = $item['group_id'];
208
- $field_id = $item['field_id'];
209
  $field_type = $item['field_type'];
210
 
211
- if (isset($item['field_type']) && $item['field_type'] != 'upload' && $item['field_type'] != 'products') {
212
 
213
- $id = $item['id'];
214
  $price = 0;
215
- $value = isset($wl_product['meta'][$id]) ? $wl_product['meta'][$id] : '';
216
 
217
 
218
  // If an extra is flat rate, it's not charged per product
219
  // It's a one-off fee that's added separately in the cart
220
- $is_flat_rate = isset($item['field_flatrate']) ? true : false;
221
 
222
- $is_percentage = !empty($item['field_percentage']) ? true : false;
223
 
224
  // Only add item if it's visible
225
- if (!empty($wl_product['meta'][$id])) {
226
 
227
- $field_price = pewc_get_field_price($item, $product);
228
 
229
  // Add the value of the field (not including the value of options)
230
- if (!$is_flat_rate) {
231
- $price = floatval($field_price);
232
  }
233
 
234
  // Check for Name Your Price
235
- if ($field_type == 'name_price') {
236
- if (!$is_flat_rate) {
237
  $price = $value;
238
  }
239
  }
240
 
241
  // Check for Calculation fields
242
- if ($field_type == 'calculation') {
243
 
244
- if (isset($item['formula_action']) && $item['formula_action'] == 'cost') {
245
 
246
- if (!$is_flat_rate) {
247
  $price = $value;
248
  }
249
 
@@ -252,75 +298,75 @@ if (!function_exists('tinvwl_item_price_pewc')) {
252
  }
253
 
254
  // Calculate price for per character fields
255
- if (!empty($item['per_character']) && ($field_type == 'text' || $field_type == 'textarea')) {
256
- $remove_line_breaks = preg_replace("/\r|\n/", "", $value);
257
- $str_length = mb_strlen(str_replace(' ', '', $remove_line_breaks));
258
- if (!empty($item['field_freechars'])) {
259
- $str_length -= absint($item['field_freechars']);
260
- $str_length = max(0, $str_length);
261
  }
262
- if (!$is_flat_rate) {
263
  $price = $str_length * $price;
264
  }
265
  }
266
 
267
  // Calculate price for multiply fields
268
- if (!empty($item['multiply']) && ($field_type == 'number' || $field_type == 'name_price')) {
269
- if (!$is_flat_rate) {
270
  $price = $value * $price;
271
  }
272
  }
273
 
274
  // Calculate price for percentage fields
275
- if ($is_percentage && $field_type != 'calculation') {
276
- if (!$is_flat_rate) {
277
- $price = pewc_calculate_percentage_price($field_price, $product);
278
  // $price = $value * $price;
279
  }
280
  }
281
 
282
  // Filtered by Bookings to include per unit cost for extras
283
- $price = apply_filters('pewc_filter_cart_item_data_price', $price, array(), $item, $group_id, $field_id);
284
 
285
  // Find any additional cost for options and select fields
286
- if (!empty($item['field_options'])) {
287
 
288
  // Record checkbox group values differently
289
  $checkbox_group_values = array();
290
  // Radio buttons are arrays, select are simple values
291
- if ($field_type == 'radio' || ($field_type == 'image_swatch' && empty($item['allow_multiple']))) {
292
  $option_value = $value[0];
293
  } else {
294
  $option_value = $value;
295
  }
296
 
297
 
298
- foreach ($item['field_options'] as $option) {
299
 
300
  // If it's a checkbox group, we need to total all selected options
301
- if ($field_type == 'checkbox_group' || ($field_type == 'image_swatch' && !empty($item['allow_multiple']))) {
302
 
303
- if (!empty($option['price']) && in_array($option['value'], $option_value)) {
304
  $option_price = $option['price'];
305
- if ($is_percentage) {
306
- $option_price = pewc_calculate_percentage_price($option_price, $product);
307
  }
308
 
309
- if (!$is_flat_rate) {
310
- $price += floatval($option_price);
311
- $option_price = pewc_maybe_include_tax($product, $option_price);
312
- $checkbox_group_values[] = $show_option_prices_in_cart === true ? $option['value'] . ' (' . wc_price($option_price) . ')' : $option['value'];
313
  }
314
  }
315
 
316
- } else if (!empty($option['price']) && $option['value'] == $option_value) {
317
  $option_price = $option['price'];
318
- if ($is_percentage) {
319
- $option_price = pewc_calculate_percentage_price($option_price, $product);
320
  }
321
 
322
- if (!$is_flat_rate) {
323
- $price += floatval($option_price);
324
  break;
325
  }
326
  }
@@ -331,20 +377,20 @@ if (!function_exists('tinvwl_item_price_pewc')) {
331
  }
332
 
333
  // Filter the price of the product extra
334
- $price = apply_filters('pewc_add_cart_item_data_price', $price, $item, $product_id);
335
 
336
- $extra_price += floatval($price);
337
  }
338
  }
339
  }
340
 
341
  // Ensure price can't be less than 0
342
- $new_price = floatval($product_price) + floatval($extra_price);
343
- if ($new_price < 0) {
344
  $new_price = 0;
345
  }
346
 
347
- return wc_price($new_price);
348
  }
349
  }
350
  }
@@ -353,5 +399,5 @@ if (!function_exists('tinvwl_item_price_pewc')) {
353
  return $price;
354
  }
355
 
356
- add_filter('tinvwl_wishlist_item_price', 'tinvwl_item_price_pewc', 10, 3);
357
  } // End if().
4
  *
5
  * @name WooCommerce Product Add-Ons Ultimate
6
  *
7
+ * @version 3.9.4
8
  *
9
  * @slug product-extras-for-woocommerce
10
  *
13
  */
14
 
15
  // If this file is called directly, abort.
16
+ if ( ! defined( 'ABSPATH' ) ) {
17
  exit;
18
  }
19
 
24
 
25
  $name = "WooCommerce Product Add-Ons Ultimate";
26
 
27
+ $available = defined( 'PEWC_FILE' );
28
 
29
  $tinvwl_integrations = is_array( $tinvwl_integrations ) ? $tinvwl_integrations : [];
30
 
31
+ $tinvwl_integrations[ $slug ] = array(
32
+ 'name' => $name,
33
  'available' => $available,
34
  );
35
 
36
+ if ( ! tinv_get_option( 'integrations', $slug ) ) {
37
  return;
38
  }
39
 
40
+ if ( ! $available ) {
41
  return;
42
  }
43
 
44
+ if ( ! function_exists( 'tinv_wishlist_item_meta_pewc' ) ) {
45
 
46
  /**
47
  * Set description for meta WooCommerce Product Add-Ons Ultimate
53
  * @return array
54
  */
55
 
56
+ function tinv_wishlist_item_meta_pewc( $item_data, $product_id, $variation_id ) {
 
57
 
58
+ if ( defined( 'PEWC_FILE' ) ) {
59
  // Check for product_extra groups
60
+ $product_extra_groups = pewc_get_extra_fields( $product_id );
61
+ $hidden_group_types = apply_filters( 'pewc_hidden_field_types_in_cart', array() );
62
 
63
  $posted_data = array();
64
 
65
+ foreach ( $item_data as $values ) {
66
+ $posted_data[ $values['key'] ] = $values['display'];
67
  }
68
 
69
+ if ( $product_extra_groups ) {
70
 
71
+ foreach ( $product_extra_groups as $group ) {
72
 
73
+ if ( isset( $group['items'] ) ) {
74
 
75
+ foreach ( $group['items'] as $item ) {
76
 
77
+ if ( in_array( $item['field_type'], $hidden_group_types ) ) {
78
  // Don't add this to the cart if it's a hidden field type
79
  continue;
80
  }
81
 
82
+ $is_visible = pewc_get_conditional_field_visibility( $item['id'], $item, $group['items'], $product_id, $posted_data, $variation_id );
83
 
84
+ if ( ! $is_visible ) {
85
  continue;
86
  }
87
 
88
  // Don't display hidden fields
89
+ if ( ! empty( $item['hidden_calculation'] ) ) {
90
  continue;
91
  }
92
 
93
+
94
  // Added in 3.5.3 to allow us to link parent products with children in cart
95
+ $display_product_meta = apply_filters( 'pewc_display_child_product_meta', false, $item );
96
 
97
+ if ( isset( $item['field_type'] ) ) {
98
 
99
+ if ( $item['field_type'] == 'products' && ! $display_product_meta ) {
100
  continue;
101
  }
102
 
103
+ $hide_zero = get_option( 'pewc_hide_zero', 'no' );
104
+ $show_prices = apply_filters( 'pewc_show_field_prices_in_cart', true, $item );
105
+
106
+ // Calculate price
107
+ if ( isset( $item['field_price'] ) ) {
108
+
109
+ if ( ( $hide_zero == 'yes' && $item['field_price'] == '0.00' ) || ! $show_prices ) {
110
+
111
+ // If price is zero and hide_zero is set, hide the price
112
+ $price = '';
113
+
114
+ } else {
115
+
116
+ /**
117
+ * Removed in 3.7.1 because tax was getting doubled
118
+ */
119
+ // $product_id = $cart_item['data']->get_id();
120
+ // $product = wc_get_product( $product_id );
121
+ // $price = pewc_maybe_include_tax( $product, $item['price'] );
122
+ $price = ' ' . wc_price( $item['field_price'] );
123
+
124
+ }
125
 
 
 
126
  }
127
 
128
+ if ( ! empty( $item['field_flatrate'] ) ) {
129
+ $price = '<span class="pewc-flat-rate-cart-label">(' . __( 'Flat rate cost', 'ti-woocommerce-wishlist' ) . ')</span>';
130
+ }
131
 
132
+ $price = apply_filters( 'pewc_filter_cart_item_price', $price, $item );
133
 
134
+ $item['label'] = ! empty( $item['field_label'] ) ? sanitize_text_field( $item['field_label'] ) : '';
135
 
136
+ $value = ( isset( $item_data[ $item['id'] ] ) && isset( $item_data[ $item['id'] ]['display'] ) ) ? $item_data[ $item['id'] ]['display'] : '';
137
+
138
+ if ( $item['field_type'] == 'textarea' ) {
139
+ $value = sanitize_textarea_field( stripslashes( $value ) );
140
+ } else if ( in_array( $item['field_type'], array(
141
  'image_swatch',
142
  'radio',
143
  'upload'
144
+ ) ) ) {
145
+ $value = isset( $value[0] ) ? wp_kses_post( stripslashes( $value[0] ) ) : '';
146
  } else {
147
+ $value = sanitize_text_field( stripslashes( $value ) );
148
  }
149
 
150
  $item['value'] = $value;
151
 
152
+ if ( $item['field_type'] == 'upload' || $item['field_type'] == 'information' ) {
153
  continue;
154
  }
155
 
156
+ if ( $item['field_type'] == 'checkbox' ) {
157
+ $display = '';
158
+ if ( pewc_show_field_prices_in_cart( $item ) ) {
159
+ $display = '<span class="pewc-price pewc-cart-item-price">' . sanitize_text_field( $price ) . '</span>';
160
+ }
161
+
162
+ $item_data[] = array(
163
+ 'key' => sanitize_text_field( $item['label'] ),
164
+ 'display' => $display,
165
+ );
166
+ } else if ( $item['field_type'] == 'checkbox_group' ) {
167
+
168
+ $display = str_replace( ' | ', '<br>', $item['value'] );
169
+ if ( pewc_show_field_prices_in_cart( $item ) ) {
170
+ $display .= '<span class="pewc-price pewc-cart-item-price">' . sanitize_text_field( $price ) . '</span>';
171
+ }
172
+
173
  $item_data[] = array(
174
+ 'key' => sanitize_text_field( $item['label'] ),
175
+ 'display' => $display,
176
  );
177
+ } else if ( $item['field_type'] == 'name_price' ) {
178
+ $value = wc_price( $item['value'] );
179
  $item_data[] = array(
180
+ 'key' => sanitize_text_field( $item['label'] ),
181
+ 'display' => sanitize_text_field( $value ),
182
  );
183
+ } else if ( $item['field_type'] == 'group_heading' ) {
 
184
  $item_data[] = array(
185
+ 'key' => '<span class="pewc-cart-group-heading">' . sanitize_text_field( $item['label'] ) . '</span>',
186
+ 'display' => '',
187
  );
188
  } else {
189
+
190
+ $show_field_prices_in_cart = pewc_show_field_prices_in_cart( $item );
191
+ $display = wp_kses_post( apply_filters( 'pewc_filter_item_value_in_cart', $item['value'], $item ) );
192
+
193
+ if ( $show_field_prices_in_cart ) {
194
+ $display .= '<span class="pewc-cart-item-price">' . $price . '</span>';
195
+ }
196
+
197
  $item_data[] = array(
198
+ 'key' => sanitize_text_field( $item['label'] ),
199
+ 'display' => $display,
200
  );
201
  }
202
  }
206
  }
207
  }
208
 
209
+ foreach ( array_keys( $item_data ) as $key ) {
210
+ if ( strpos( $key, 'pewc' ) === 0 ) {
211
+ unset( $item_data[ $key ] );
212
  }
213
  }
214
 
215
  return $item_data;
216
  }
217
 
218
+ add_filter( 'tinvwl_wishlist_item_meta_post', 'tinv_wishlist_item_meta_pewc', 10, 3 );
219
  }
220
 
221
+ if ( ! function_exists( 'tinvwl_item_price_pewc' ) ) {
222
 
223
  /**
224
  * Modify price for WooCommerce Product Add-Ons Ultimate
229
  *
230
  * @return string
231
  */
232
+ function tinvwl_item_price_pewc( $price, $wl_product, $product ) {
 
233
 
234
+ if ( defined( 'PEWC_FILE' ) ) {
235
 
236
  $product_price = $product->get_price();
237
+ $product_id = $product->get_id();
238
+ $extra_price = 0;
239
 
240
+ $product_extra_groups = pewc_get_extra_fields( $product_id );
241
 
242
+ if ( $product_extra_groups ) {
243
 
244
+ foreach ( $product_extra_groups as $group ) {
245
 
246
+ if ( isset( $group['items'] ) ) {
247
 
248
+ foreach ( $group['items'] as $item ) {
249
 
250
+ $show_option_prices_in_cart = pewc_show_option_prices_in_cart( $item );
251
 
252
 
253
+ $group_id = $item['group_id'];
254
+ $field_id = $item['field_id'];
255
  $field_type = $item['field_type'];
256
 
257
+ if ( isset( $item['field_type'] ) && $item['field_type'] != 'upload' && $item['field_type'] != 'products' ) {
258
 
259
+ $id = $item['id'];
260
  $price = 0;
261
+ $value = isset( $wl_product['meta'][ $id ] ) ? $wl_product['meta'][ $id ] : '';
262
 
263
 
264
  // If an extra is flat rate, it's not charged per product
265
  // It's a one-off fee that's added separately in the cart
266
+ $is_flat_rate = ! empty( $item['field_flatrate'] ) ? true : false;
267
 
268
+ $is_percentage = ! empty( $item['field_percentage'] ) ? true : false;
269
 
270
  // Only add item if it's visible
271
+ if ( ! empty( $wl_product['meta'][ $id ] ) ) {
272
 
273
+ $field_price = pewc_get_field_price( $item, $product );
274
 
275
  // Add the value of the field (not including the value of options)
276
+ if ( ! $is_flat_rate ) {
277
+ $price = floatval( $field_price );
278
  }
279
 
280
  // Check for Name Your Price
281
+ if ( $field_type == 'name_price' ) {
282
+ if ( ! $is_flat_rate ) {
283
  $price = $value;
284
  }
285
  }
286
 
287
  // Check for Calculation fields
288
+ if ( $field_type == 'calculation' ) {
289
 
290
+ if ( isset( $item['formula_action'] ) && $item['formula_action'] == 'cost' ) {
291
 
292
+ if ( ! $is_flat_rate ) {
293
  $price = $value;
294
  }
295
 
298
  }
299
 
300
  // Calculate price for per character fields
301
+ if ( ! empty( $item['per_character'] ) && ( $field_type == 'text' || $field_type == 'textarea' ) ) {
302
+ $remove_line_breaks = preg_replace( "/\r|\n/", "", $value );
303
+ $str_length = mb_strlen( str_replace( ' ', '', $remove_line_breaks ) );
304
+ if ( ! empty( $item['field_freechars'] ) ) {
305
+ $str_length -= absint( $item['field_freechars'] );
306
+ $str_length = max( 0, $str_length );
307
  }
308
+ if ( ! $is_flat_rate ) {
309
  $price = $str_length * $price;
310
  }
311
  }
312
 
313
  // Calculate price for multiply fields
314
+ if ( ! empty( $item['multiply'] ) && ( $field_type == 'number' || $field_type == 'name_price' ) ) {
315
+ if ( ! $is_flat_rate ) {
316
  $price = $value * $price;
317
  }
318
  }
319
 
320
  // Calculate price for percentage fields
321
+ if ( $is_percentage && $field_type != 'calculation' ) {
322
+ if ( ! $is_flat_rate ) {
323
+ $price = pewc_calculate_percentage_price( $field_price, $product );
324
  // $price = $value * $price;
325
  }
326
  }
327
 
328
  // Filtered by Bookings to include per unit cost for extras
329
+ $price = apply_filters( 'pewc_filter_cart_item_data_price', $price, array(), $item, $group_id, $field_id );
330
 
331
  // Find any additional cost for options and select fields
332
+ if ( ! empty( $item['field_options'] ) ) {
333
 
334
  // Record checkbox group values differently
335
  $checkbox_group_values = array();
336
  // Radio buttons are arrays, select are simple values
337
+ if ( $field_type == 'radio' || ( $field_type == 'image_swatch' && empty( $item['allow_multiple'] ) ) ) {
338
  $option_value = $value[0];
339
  } else {
340
  $option_value = $value;
341
  }
342
 
343
 
344
+ foreach ( $item['field_options'] as $option ) {
345
 
346
  // If it's a checkbox group, we need to total all selected options
347
+ if ( $field_type == 'checkbox_group' || ( $field_type == 'image_swatch' && ! empty( $item['allow_multiple'] ) ) ) {
348
 
349
+ if ( ! empty( $option['price'] ) && in_array( $option['value'], $option_value ) ) {
350
  $option_price = $option['price'];
351
+ if ( $is_percentage ) {
352
+ $option_price = pewc_calculate_percentage_price( $option_price, $product );
353
  }
354
 
355
+ if ( ! $is_flat_rate ) {
356
+ $price += floatval( $option_price );
357
+ $option_price = pewc_maybe_include_tax( $product, $option_price );
358
+ $checkbox_group_values[] = $show_option_prices_in_cart === true ? $option['value'] . ' (' . wc_price( $option_price ) . ')' : $option['value'];
359
  }
360
  }
361
 
362
+ } else if ( ! empty( $option['price'] ) && $option['value'] == $option_value ) {
363
  $option_price = $option['price'];
364
+ if ( $is_percentage ) {
365
+ $option_price = pewc_calculate_percentage_price( $option_price, $product );
366
  }
367
 
368
+ if ( ! $is_flat_rate ) {
369
+ $price += floatval( $option_price );
370
  break;
371
  }
372
  }
377
  }
378
 
379
  // Filter the price of the product extra
380
+ $price = apply_filters( 'pewc_add_cart_item_data_price', $price, $item, $product_id );
381
 
382
+ $extra_price += floatval( $price );
383
  }
384
  }
385
  }
386
 
387
  // Ensure price can't be less than 0
388
+ $new_price = floatval( $product_price ) + floatval( $extra_price );
389
+ if ( $new_price < 0 ) {
390
  $new_price = 0;
391
  }
392
 
393
+ return wc_price( $new_price );
394
  }
395
  }
396
  }
399
  return $price;
400
  }
401
 
402
+ add_filter( 'tinvwl_wishlist_item_price', 'tinvwl_item_price_pewc', 10, 3 );
403
  } // End if().
languages/ti-woocommerce-wishlist.pot CHANGED
@@ -1,8 +1,8 @@
1
- # Copyright (C) 2021 TI WooCommerce Wishlist Plugin - 1.29.0
2
- # This file is distributed under the same license as the TI WooCommerce Wishlist Plugin - 1.29.0 package.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: TI WooCommerce Wishlist Plugin - 1.29.0\n"
6
  "MIME-Version: 1.0\n"
7
  "Content-Type: text/plain; charset=UTF-8\n"
8
  "Content-Transfer-Encoding: 8bit\n"
@@ -1132,7 +1132,7 @@ msgstr ""
1132
  msgid "Added To Wishlist"
1133
  msgstr ""
1134
 
1135
- #: integrations/product-extras-for-woocommerce.php:106
1136
  msgid "Flat rate cost"
1137
  msgstr ""
1138
 
1
+ # Copyright (C) 2022 TI WooCommerce Wishlist Plugin - 1.30.0
2
+ # This file is distributed under the same license as the TI WooCommerce Wishlist Plugin - 1.30.0 package.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: TI WooCommerce Wishlist Plugin - 1.30.0\n"
6
  "MIME-Version: 1.0\n"
7
  "Content-Type: text/plain; charset=UTF-8\n"
8
  "Content-Transfer-Encoding: 8bit\n"
1132
  msgid "Added To Wishlist"
1133
  msgstr ""
1134
 
1135
+ #: integrations/product-extras-for-woocommerce.php:129
1136
  msgid "Flat rate cost"
1137
  msgstr ""
1138
 
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: templateinvaders
3
  Tags: woocommerce, wishlist, woocommerce wishlist, e-commerce, ecommerce
4
  Requires at least: 4.7
5
  Tested up to: 5.8
6
- Stable tag: 1.29.0
7
  License: GPLv3
8
  License URI: https://www.gnu.org/licenses/gpl-3.0.html
9
  Plugin URI: https://wordpress.org/plugins/ti-woocommerce-wishlist/
@@ -163,6 +163,13 @@ Yes, you can! Join in on our [GitHub repository](https://github.com/TemplateInva
163
 
164
 
165
  == Changelog ==
 
 
 
 
 
 
 
166
  = 1.29.0 =
167
  *Release Date - 25 November 2021*
168
 
3
  Tags: woocommerce, wishlist, woocommerce wishlist, e-commerce, ecommerce
4
  Requires at least: 4.7
5
  Tested up to: 5.8
6
+ Stable tag: 1.30.0
7
  License: GPLv3
8
  License URI: https://www.gnu.org/licenses/gpl-3.0.html
9
  Plugin URI: https://wordpress.org/plugins/ti-woocommerce-wishlist/
163
 
164
 
165
  == Changelog ==
166
+ = 1.30.0 =
167
+ *Release Date - 09 January 2022*
168
+
169
+ * WooCommerce 6.0 support
170
+ * Updated integration with WooCommerce Product Add-Ons Ultimate plugin
171
+ * Fixed custom AJAX endpoint issue for some customized WordPress setups
172
+
173
  = 1.29.0 =
174
  *Release Date - 25 November 2021*
175
 
ti-woocommerce-wishlist.php CHANGED
@@ -4,11 +4,11 @@
4
  * Plugin Name: TI WooCommerce Wishlist
5
  * Plugin URI: https://wordpress.org/plugins/ti-woocommerce-wishlist/
6
  * Description: Wishlist functionality for your WooCommerce store.
7
- * Version: 1.29.0
8
  * Requires at least: 4.7
9
  * Tested up to: 5.8
10
  * WC requires at least: 3.0
11
- * WC tested up to: 5.9
12
  * Author: TemplateInvaders
13
  * Author URI: https://templateinvaders.com/
14
  * License: GPL-2.0+
@@ -41,7 +41,7 @@ if (!defined('TINVWL_DOMAIN')) {
41
  }
42
 
43
  if (!defined('TINVWL_FVERSION')) {
44
- define('TINVWL_FVERSION', '1.29.0');
45
  }
46
 
47
  if (!defined('TINVWL_LOAD_FREE')) {
4
  * Plugin Name: TI WooCommerce Wishlist
5
  * Plugin URI: https://wordpress.org/plugins/ti-woocommerce-wishlist/
6
  * Description: Wishlist functionality for your WooCommerce store.
7
+ * Version: 1.30.0
8
  * Requires at least: 4.7
9
  * Tested up to: 5.8
10
  * WC requires at least: 3.0
11
+ * WC tested up to: 6.0
12
  * Author: TemplateInvaders
13
  * Author URI: https://templateinvaders.com/
14
  * License: GPL-2.0+
41
  }
42
 
43
  if (!defined('TINVWL_FVERSION')) {
44
+ define('TINVWL_FVERSION', '1.30.0');
45
  }
46
 
47
  if (!defined('TINVWL_LOAD_FREE')) {