';var d=H(),f=$('input[name="theme-apply"]').val()||"light";if("dark"===f&&e.addClass("ali-review-theme-dark"),"grid"===window.STYLE_LAYOUT_REVIEW){q();var p=setInterval((function(){parseInt($(".list-alireview").outerHeight())<=60?q():clearInterval(p)}),1e3)}else"carousel"===window.STYLE_LAYOUT_REVIEW?(O(),R()):setTimeout((function(){l()}),500);window.filesToUpload=[],window.uploadPhoto=new o.a(".alireview_list_image","#alireview_file_upload",filesToUpload),uploadPhoto.Init(),window.widgetsCarouselSlider=new m,widgetsCarouselSlider.Init(),$("#shopify-ali-review").on("click",".alr-count-reviews li",(function(){$("#shopify-ali-review").hasClass("un-scroll")||Object(w.b)({scrollToReviewBox:!0})}));var h=$('input[name="type-page"]').val();h&&"product"===h&&($("#shopify-ali-review").on("click",".btn-add-alireview",(function(){setTimeout((function(){j()}),250)})),$("#shopify-ali-review").on("click",".btn-cancel-review",(function(){setTimeout((function(){j()}),250)}))),$("#shopify-ali-review").on("click",".alireview-sort__type li",(function(){var e=$(this).attr("option"),t=$('input[name="summary-star"]').val()||"all";e!==$('input[name="sort-type"]').val()&&D(t,e)})),$("#shopify-ali-review").on("click",".alireview-sort__wrap",(function(){$(this).hasClass("open")?$(this).removeClass("open"):$(this).addClass("open")})),window.onclick=function(e){e.target.matches(".alireview-sort__label, img, .icon-filter")||$(".alireview-sort__type").parent().removeClass("open")},$("#shopify-ali-review").on("click",".alr-count-reviews li",(function(){var e=$(this).attr("star");e!==$('input[name="summary-star"]').val()?D(e):D("all")}));d.is_visitor;if($("#your_name").on("input",(function(){$(this).val().length>=50&&$(this).val($(this).val().substr(0,49))})),$("#content").on("input",(function(){$(this).val().length>=2e3&&$(this).val($(this).val().substr(0,1999))})),$(document).on("click",".alireview-row .more-img, .alireview-row img.lightbox-thmb, .alireview-row .ali-show-full-review",(function(e){var i=$(this).parents(".alireview-row-wrap").attr("data-comment-id"),r=$(this).attr("data-lightbox-key")||0,o=document.querySelector("input[name=id-widget]")&&document.querySelector("input[name=id-widget]").value,a=$('input[name="type-page"]').val();Object(w.b)({openModalDetailReview:!0,dataDetailReview:{shop_id:t,comment_id:i,product_id:n,lightbox_key:r,widgetId:o,type_page:a}})})),$(document).on("click",".alireview-row .count-img",(function(e){$(this).closest(".alireview-row-wrap").find("img.lightbox-thmb").click()})),$(document).on("click",".btn-add-alireview.popup",(function(e){var i=document.querySelector("input[name=id-widget]")&&document.querySelector("input[name=id-widget]").value;Object(w.b)({openModalWriteReview:!0,dataWriteReview:{shop_id:t,product_id:n,theme_apply:f,widgetId:i}})})),r)if($(".btn-add-alireview.popup").length>0)$(".btn-add-alireview.popup").trigger("click");else{$(".reviewFormHead").css("display","block"),$('input[name="alireview_email_id"]').val(r),$('input[name="alireview_star"]').val(s),$('input[name="alireview_author"]').val(u),$('input[name="alireview_email"]').val(c);var v=0;switch(s){case 5:v=0;break;case 4:v=1;break;case 3:v=2;break;case 2:v=3;break;case 1:v=4}$(".reviewFormHead .alr-rating").length&&$(".reviewFormHead .alr-rating").rating({start:v}),$('textarea[name="alireview_content"]').val(a),setTimeout((function(){Object(w.b)({scrollToReviewBox:!0})}),500)}$(".alr-rating").length>0&&($(".alr-rating").not(".done").rating(),$(".alr-rating").addClass("done")),W(),P(),"scroll"!==C&&b(C),$(document).on("click",".product_info a.alireview-product-link, .js-alireview-product-link",(function(e){var n=document.querySelector("input[name=id-widget]")&&document.querySelector("input[name=id-widget]").value,i=e.target.dataset.productId;Object(w.b)({message:x.b,data:{shopId:t,widgetId:n,productId:i}})}))}}))},PBvO:function(e,t){!function(e,t){"use strict";function n(t,n){var i;this.$input=e(t),this.$rating=e('').css({cursor:"default",whiteSpace:"nowrap"}).insertBefore(this.$input),this.options=((i=e.extend({},this.$input.data(),n)).start=parseInt(i.start,10),i.start=isNaN(i.start)?void 0:i.start,i.stop=parseInt(i.stop,10),i.stop=isNaN(i.stop)?i.start+5||void 0:i.stop,i.step=parseInt(i.step,10)||void 0,i.fractions=Math.abs(parseInt(i.fractions,10))||void 0,i.scale=Math.abs(parseInt(i.scale,10))||void 0,(i=e.extend({},e.fn.rating.defaults,i)).filledSelected=i.filledSelected||i.filled,i),this._init()}n.prototype={_init:function(){for(var t=this,n=this.$input,i=this.$rating,r=function(e){return function(t){n.prop("disabled")||n.prop("readonly")||void 0!==n.data("readonly")||e.call(this,t)}},o=1;o<=this._rateToIndex(this.options.stop);o++){var a=e('