PageSourceSearch

https://s.restaurantguru.ru/js/min/restaurant.js?rg_assets_10.3.3.2914

js restaurantguru.ru collected 2026-10-03 19:26:40 UTC 280,538 bytes, 34 lines download raw bytes

1((e,t,o)=>{"function"==typeof define&&define.amd?define(["jquery"],e):"object"==typeof exports&&"undefined"==typeof Meteor?module.exports=e(require("jquery")):e(t||o)})(function(r){function s(d,w,b){var i,y={invalid:[],getCaret:function(){try{var e,t=0,o=d.get(0),n=document.selection,i=o.selectionStart;return n&&-1===navigator.appVersion.indexOf("MSIE 10")?((e=n.createRange()).moveStart("character",-y.val().length),t=e.text.length):!i&&"0"!==i||(t=i),t}catch(e){}},setCaret:function(e){try{var t,o;d.is(":focus")&&((o=d.get(0)).setSelectionRange?o.setSelectionRange(e,e):((t=o.createTextRange()).collapse(!0),t.moveEnd("character",e),t.moveStart("character",e),t.select()))}catch(e){}},events:function(){d.on("keydown.mask",function(e){d.data("mask-keycode",e.keyCode||e.which),d.data("mask-previus-value",d.val()),d.data("mask-previus-caret-pos",y.getCaret()),y.maskDigitPosMapOld=y.maskDigitPosMap}).on(r.jMaskGlobals.useInput?"input.mask":"keyup.mask",y.behaviour).on("paste.mask drop.mask",function(){setTimeout(function(){d.keydown().keyup()},100)}).on("change.mask",function(){d.data("changed",!0)}).on("blur.mask",function(){a===y.val()||d.data("changed")||d.trigger("change"),d.data("changed",!1)}).on("blur.mask",function(){a=y.val()}).on("focus.mask",function(e){!0===b.selectOnFocus&&r(e.target).select()}).on("focusout.mask",function(){b.clearIfNotMatch&&!i.test(y.val())&&y.val("")}
1)},getRegexMask:function(){for(var e,t,o,n,i,a=[],r=0;r<w.length;r++)(o=$.translation[w.charAt(r)])?(e=o.pattern.toString().replace(/.{1}$|^.{1}/g,""),t=o.optional,(o=o.recursive)?(a.push(w.charAt(r)),n={digit:w.charAt(r),pattern:e}):a.push(t||o?e+"?":e)):a.push(w.charAt(r).replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&"));return i=a.join(""),n&&(i=i.replace(new RegExp("("+n.digit+"(.*"+n.digit+")?)"),"($1)?").replace(new RegExp(n.digit,"g"),n.pattern)),new RegExp(i)},destroyEvents:function(){d.off(["input","keydown","keyup","paste","drop","blur","focusout",""].join(".mask "))},val:function(e){var t=d.is("input")?"val":"text",e=0<arguments.length?(d[t]()!==e&&d[t](e),d):d[t]();return e},calculateCaretPosition:function(e){var t=y.getMasked(),o=y.getCaret();if(e!==t){for(var n=d.data("mask-previus-caret-pos")||0,i=t.length,t=e.length,a=0,r=0,s=0,l=0,c=0,c=o;c<i&&y.maskDigitPosMap[c];c++)r++;for(c=o-1;0<=c&&y.maskDigitPosMap[c];c--)a++;for(c=o-1;0<=c;c--)y.maskDigitPosMap[c]&&s++;for(c=n-1;0<=c;c--)y.maskDigitPosMapOld[c]&&l++;t<o?o=10*i:o<=n&&n!==t?y.maskDigitPosMapOld[o]||(e=o,y.maskDigitPosMap[o=o-(l-s)-a]&&(o=e)):n<o&&(o=o+(s-l)+r)}return o},behaviour:function(e){e=e||window.event,y.invalid=[];var t,o,n=d.data("mask-keycode");if(-1===r.inArray(n,$.byPassKeys))return n=y.getMasked(),t=y.getCaret(),o=d.data("mask-previus-value")||"",setTimeout(function(){y.setCaret(y.calculateCaretPosition(o))},r.jMaskGlobals.keyStrokeCompensation),y.val(n),y.setCaret(t),y.callbacks(e)},getMasked:function(e,t){for(var o,n,i=[],a=void 0===t?y.val():t+"",r=0,s=w.length,l=0,c=a.length,d=1,u="push",m=-1,p=0,h=[],_=b.reverse?(u="unshift",d=-1,o=0,r=s-1,l=c-1,function(){return-1<r&&-1<l}):(o=s-1,function(){return r<s&&l<c});_();){var f=w.charAt(r),g=a.charAt(l),v=$.translation[f];v?(g.match(v.pattern)?(i[u](g),v.recursive&&(-1===m?m=r:r===o&&r!==m&&(r=m-d),o===m)&&(r-=d),r+=d):g===n?(p--,n=void 0):v.optional?(r+=d,l-=d):v.fallback?(i[u](v.fallback),r+=d,l-=d):y.invalid.push({p:l,v:g,e:v.pattern}),l+=d):(e||i[u](f),g===f?(h.push(l),l+=d):(n=f,h.push(l+p),p++),r+=d)}t=w.charAt(o),s!==c+1||$.translation[t]||i.push(t),t=i.join("");return y.mapMaskdigitPositions(t,h,c),t},mapMaskdigitPositions:function(e,t,o){var n=b.reverse?e.length-o:0;y.maskDigitPosMap={};for(var i=0;i<t.length;i++)y.maskDigitPosMap[t[i]+n]=1},callbacks:function(e){function t(e,t,o){"function"==typeof b[e]&&t&&b[e].apply(this,o)}var o=y.val(),n=o!==a,i=[o,e,d,b];t("onChange",!0==n,i),t("onKeyPress",!0==n,i),t("onComplete",o.length===w.length,i),t("onInvalid",0<y.invalid.length,[o,e,d,y.invalid,b])}},$=(d=r(d),this),a=y.val();w="function"==typeof w?w(y.val(),void 0,d,b):w,$.mask=w,$.options=b,$.remove=function(){var e=y.getCaret();return $.options.placeholder&&d.removeAttr("placeholder"),d.data("mask-maxlength")&&d.removeAttr("maxlength"),y.destroyEvents(),y.val($.getCleanVal()),y.setCaret(e),d},$.getCleanVal=function(){return y.getMasked(!0)},$.getMaskedVal=function(e){return y.getMasked(!1,e)},$.init=function(e){if(e=e||!1,b=b||{},$.clearIfNotMatch=r.jMaskGlobals.clearIfNotMatch,$.byPassKeys=r.jMaskGlobals.byPassKeys,$.translation=r.extend({},r.jMaskGlobals.translation,b.translation),$=r.extend(!0,{},$,b),i=y.getRegexMask(),e)y.events(),y.val(y.getMasked());else{b.placeholder&&d.attr("placeholder",b.placeholder),d.data("mask")&&d.attr("autocomplete","off");for(var t=0,o=!0;t<w.length;t++){var n=$.translation[w.charAt(t)];if(n&&n.recursive){o=!1;break}}o&&d.attr("maxlength",w.length).data("mask-maxlength",!0),y.destroyEvents(),y.events();e=y.getCaret();y.val(y.getMasked()),y.setCaret(e)}},$.init(!d.is("input"))}function t(){var e=r(this),t={},o="data-mask-",n=e.attr("data-mask");if(e.attr(o+"reverse")&&(t.reverse=!0),e.attr(o+"clearifnotmatch")&&(t.clearIfNotMatch=!0),"true"===e.attr(o+"selectonfocus")&&(t.selectOnFocus=!0),l(e,n,t))return e.data("mask",new s(this,n,t))}function l(e,t,o){o=o||{};var n=r(e).data("mask"),i=JSON.stringify,e=r(e).val()||r(e).text();try{return"function"==typeof t&&(t=t(e)),"object"!=typeof n||i(n.options)!==i(o)||n.mask!==t}catch(e){}}r.maskWatchers={};r.fn.mask=function(e,t){t=t||{};function o(){if(l(this,e,t))return r(this).data("mask",new s(this,e,t))}
1var n=this.selector,i=r.jMaskGlobals,a=i.watchInterval,i=t.watchInputs||i.watchInputs;return r(this).each(o),n&&""!==n&&i&&(clearInterval(r.maskWatchers[n]),r.maskWatchers[n]=setInterval(function(){r(document).find(n).each(o)},a)),this},r.fn.masked=function(e){return this.data("mask").getMaskedVal(e)},r.fn.unmask=function(){return clearInterval(r.maskWatchers[this.selector]),delete r.maskWatchers[this.selector],this.each(function(){var e=r(this).data("mask");e&&e.remove().removeData("mask")})},r.fn.cleanVal=function(){return this.data("mask").getCleanVal()},r.applyDataMask=function(e){((e=e||r.jMaskGlobals.maskElements)instanceof r?e:r(e)).filter(r.jMaskGlobals.dataMaskAttr).each(t)};var e,o,n={maskElements:"input,td,span,div",dataMaskAttr:"[data-mask]",dataMask:!0,watchInterval:300,watchInputs:!0,keyStrokeCompensation:10,useInput:!/Chrome\/[2-4][0-9]|SamsungBrowser/.test(window.navigator.userAgent)&&(n="input",o=document.createElement("div"),(e=(n="on"+n)in o)||(o.setAttribute(n,"return;"),e="function"==typeof o[n]),o=null,e),watchDataMask:!1,byPassKeys:[9,16,17,18,36,37,38,39,40,91],translation:{0:{pattern:/\d/},9:{pattern:/\d/,optional:!0},"#":{pattern:/\d/,recursive:!0},A:{pattern:/[a-zA-Z0-9]/},S:{pattern:/[a-zA-Z]/}}};r.jMaskGlobals=r.jMaskGlobals||{},(n=r.jMaskGlobals=r.extend(!0,{},n,r.jMaskGlobals)).dataMask&&r.applyDataMask(),setInterval(function(){r.jMaskGlobals.watchDataMask&&r.applyDataMask()},n.watchInterval)},window.jQuery,window.Zepto),((r,e)=>{var s,l,c,d,u,m,p,h,_,f,g,t,o,n,v;function i(e){var t=e.toLowerCase();return navigator.msPointerEnabled?"MS"+e:!!window.PointerEvent&&t}function a(e){return"on"+e in window&&e}function w(e){return!e.pointerId||void 0===s||e.pointerId===s}function b(e,t,o){for(var n=t.split(" "),i=n.length;i--;)e.addEventListener(n[i],o,!1)}function y(e){var t=Boolean(e.targetTouches&&e.targetTouches.length);switch(!0){case Boolean(e.target.touches):return e.target.touches[0];case t&&void 0!==e.targetTouches[0].pageX:return e.targetTouches[0];case t&&Boolean(e.targetTouches[0].touches):return e.targetTouches[0].touches[0];default:return e}}function $(e){return 1<(e.targetTouches||e.target.touches||[]).length}function k(){return(new Date).getTime()}function x(e,t,o,n){var i=r.createEvent("Event");if(i.originalEvent=o,(n=n||{}).x=l,n.y=c,f.useJquery&&(i=jQuery.Event(t,{originalEvent:o}),jQuery(e).trigger(i,n)),i.initEvent){for(var a in n)i[a]=n[a];i.initEvent(t,!0,!0),e.dispatchEvent(i)}for(;e;)e["on"+t]&&e["on"+t](i),e=e.parentNode}"function"==typeof r.createEvent&&(f={useJquery:!e.IGNORE_JQUERY&&"undefined"!=typeof jQuery,swipeThreshold:e.SWIPE_THRESHOLD||100,tapThreshold:e.TAP_THRESHOLD||150,dbltapThreshold:e.DBL_TAP_THRESHOLD||200,longtapThreshold:e.LONG_TAP_THRESHOLD||1e3,tapPrecision:e.TAP_PRECISION/2||30,justTouchEvents:e.JUST_ON_TOUCH_DEVICES},g=!1,t=a("touchstart")||i("PointerDown"),o=a("touchend")||i("PointerUp"),n=a("touchmove")||i("PointerMove"),v=0,b(r,t+(f.justTouchEvents?"":" mousedown"),function(e){var t;!w(e)||$(e)||(s=e.pointerId,"mousedown"!==e.type&&(g=!0),"mousedown"===e.type&&g)||(t=y(e),d=l=t.pageX,u=c=t.pageY,_=setTimeout(function(){x(e.target,"longtap",e),p=e.target},f.longtapThreshold),m=k(),v++)}),b(r,o+(f.justTouchEvents?"":" mouseup"),function(e){if(w(e)&&!$(e))if(s=void 0,"mouseup"===e.type&&g)g=!1;else{var t=[],o=k(),n=u-c,i=d-l;if(clearTimeout(h),clearTimeout(_),i<=-f.swipeThreshold&&t.push("swiperight"),i>=f.swipeThreshold&&t.push("swipeleft"),n<=-f.swipeThreshold&&t.push("swipedown"),n>=f.swipeThreshold&&t.push("swipeup"),t.length){for(var a=0;a<t.length;a++)x(e.target,t[a],e,{distance:{x:Math.abs(i),y:Math.abs(n)}});v=0}else d>=l-f.tapPrecision&&d<=l+f.tapPrecision&&u>=c-f.tapPrecision&&u<=c+f.tapPrecision&&0<=m+f.tapThreshold-o&&(x(e.target,2<=v&&p===e.target?"dbltap":"tap",e),p=e.target),h=setTimeout(function(){v=0},f.dbltapThreshold)}}),b(r,n+(f.justTouchEvents?"":" mousemove"),function(e){!w(e)||"mousemove"===e.type&&g||(e=y(e),l=e.pageX,c=e.pageY)}),e.tocca=function(e){for(var t in e)f[t]=e[t];return f})})(document,window);
1var gallery_menu,ReportProblem={$modal:$("#modal-problem-report"),xhr:null,widget_object:null,recaptcha_response:null,fieldValues:{checkboxes:[],cause:"",email:"",message:""},init:function(){var n=this,e=is_mobile()?"tap":"click";$(document).on("touchstart",function(e){window.pageYOffset||document.documentElement&&document.documentElement.scrollTop||document.body&&document.body.scrollTop,e.timeStamp,0}),$(document).on("touchmove",function(e){0}),$('[name="abuse"]').on(e,function(){var e=$("#abuse_photo_id").val(),t="Restaurant Guru"==$("#abuse_agency").val()?"image":"photo",o=n.getPhotoById(parseInt(e));return o&&"video"==o.type&&(t="video"),ReportProblem.makeReportProblemModal(e,t),!1}),$(document).on(e,".report_msg",function(){var e=$("#abuse_photo_id").val(),t="Restaurant Guru"==$("#abuse_agency").val()?"image":"photo",o=n.getPhotoById(parseInt(e));return o&&"video"==o.type&&(t="video"),ReportProblem.makeReportProblemModal(e,t),!1}),$(document).on(e,".report",function(e){return ReportProblem.makeReportProblemModal($(this).data("object_id"),$(this).data("object_type")),!1}),$(document).on(e,"#modal-problem-report .close_btn",function(e){return e.preventDefault(),ReportProblem.closeReportModal(),!1}),$(document).on("click",".report_select",function(e){e.stopPropagation();e=this.classList.contains("shown");$(".report_select").removeClass("shown"),e||this.classList.add("shown")}),$(document).on("click",function(e){$(".report_select").removeClass("shown")}),$(document).on("click",".report_option",function(e){var t=document.querySelector(".select_title");document.querySelectorAll(".report_option").forEach(e=>e.classList.remove("active")),this.classList.add("active"),t.textContent=this.dataset.name,t.dataset.value=this.dataset.value})},getPhotoById:function(t){var e=window.json_arr.photos;if(e)return e.find(function(e){return e.id===t})},makeCheckboxes:function(){let o={phone:"Phone",menu:"restaurant_menu",other:"report_cause_other"};return'<div class="modal-problem-report__checkboxes">'+["name","type","address","phone","menu","meals","opening_hours","price","other"].map(e=>{var t=_(o.hasOwnProperty(e)?o[e]:e);return'<div class="label_wrapper"><label class="report_label" for="'+e+'"><input class="checkbox--origin" type="checkbox" name="'+e+'" value="'+t+'" id="'+e+'"> <span class="checkbox--custom"></span><span class="checkbox_text">'+t+"</span></label></div>"}).join("")+"</div>"},isEmailMandatory:function(e){return"restaurant"!==e},makeForm:function(e){this.$modal&&this.$modal.remove(),this.$modal=$("<div>").addClass("modal modal_filter hide").attr("id","modal-problem-report"),this.$modal.appendTo("body"),this.$modal=$("#modal-problem-report"),t=null==window.json_arr.desktop?'<div id="reportrecaptcha" class="g_captcha recapthca"></div>':"";var t,o="video"==e?_("report_video_info"):_("report_photo_info");let n=_("report_cause");"restaurant"===e&&(n=_("report_problem_restaurant"));var i="restaurant"===e?this.makeCheckboxes():'<div class="report_select"><div class="select_title" data-name="cause" data-value="">'+_("report_select_reason")+'</div><div class="options_list">'+this.getOptions(e)+"</div></div>",o='<div class="wrapper_report '+e+'"><div class="close_btn"></div><div class="title_block">'+_("what_wrong_with_content")+'<div class="sub_title_block">'+o+'</div></div><form class="form_report"><div class="form_report_out"></div><input type="hidden" name="object_id" value=""><input type="hidden" name="object_type" value=""><div class="report_fields"><div class="inner-container inner-container__top"><div class="reportCause_wrapper"><label>'+n+'</label><span class="report_error сheckboxes сheckboxes_error""></span></div>'+i+'</div><div class="inner-container"><label>E-mail'+(this.isEmailMandatory(e)?"*":"")+'</label><span class="report_error msg email_error" ></span><input type="email" dir="ltr" name="email" value=""></div><div class="inner-container"><label>'+_("message")+'*</label><span class="report_error msg msg_error""></span><textarea name="message"></textarea></div><div class="inner-container"><div>'+t+'</div><span class="report_error msg srv_error"></span></div><input type="submit" value="'+_("send")+'" class="btn btn--primary report_submit"></div></form></div>';this.$modal.html(o),is_logged_in&&$('[name="email"]',this.$modal).parents(".inner-container:first").hide(),this.$modal.on("click touchstart",function(e){ReportProblem.$modal.find(".wrapper_report").is(e.target)||0!=ReportProblem.$modal.find(".wrapper_report").has(e.target).length||(
1ReportProblem.closeReportModal(),e.preventDefault())}),this.$modal.find("form").on("submit",function(e){return e.preventDefault(),ReportProblem.validate(),!1}),$(".report_error").innerHTML=""},addErrorToField:function(e){e.addClass("error").keyup(function(){e.removeClass("error").unbind("keyup")})},getOptions:function(e){var e="promotion"===e?[["doesnt_match",_("report_cause_doesnt_match")],["offensive_content",_("report_cause_offensive_content")],["dont_like",_("report_cause_dont_like")],["review",_("report_cause_review")]]:[["privacy_concern",_("report_cause_privacy")],["sexually",_("report_cause_sexually")],["copyright",_("report_cause_copyright")],["poor_quality",_("report_cause_poor_quality")],["not_photo",_("report_cause_not_photo")],["other",_("report_cause_other")]],o="";return $.each(e,function(e,t){o+=`<div class="report_option" data-value="${t[0]}" data-name="${t[1]}">${t[1]}</div>`}),o},validate:function(){var e=this.$modal.find("form"),t=$.trim(e.find("[name=email]").val()),o=$.trim(e.find("[name=message]").val()),n=$.trim(e.find("[name=object_id]").val()),i=$.trim(e.find("[name=object_type]").val()),a=!1,r=!1,s=!1,l=0;t?/.+@.+\..+/i.test(t)||(this.addErrorToField(e.find("[name=email]")),l++,a=_("feedback_email_notvalid")):!is_logged_in&&this.isEmailMandatory(i)&&(this.addErrorToField(e.find("[name=email]")),l++,a=_("%s is empty").replace("%s",_("email_field"))),o||(this.addErrorToField(e.find("[name=message]")),l++,r=_("%s is empty").replace("%s",_("message")));let c,d;if("restaurant"===i?0===(c=e.find('input[type="checkbox"]:checked').map(function(){return $(this).attr("name")}).get()).length&&(l++,s=_("error_no_selected_options")):(d=e.find("[data-name=cause]")[0].dataset.value)||(l++,s=_("error_no_selected_options")),$(".report_error",this.$modal).html(""),0<l)return a&&$(".email_error",this.$modal).html(a).css("display","block"),r&&$(".msg_error",this.$modal).html(r).css("display","block"),s&&$(".сheckboxes_error",this.$modal).html(s).show(),!1;var u={email:t,message:o,cause:d,object_id:n,object_type:i};"restaurant"===i&&(u.wrong_items=c.join(","));let m=this;grecaptcha.ready(function(){grecaptcha.execute(ReportProblem.widget_object,{action:"submit"}).then(function(e){u.g_recaptcha_response=e,m.sendReport(u)})})},sendReport:function(e){null==this.xhr&&(ReportProblem.$modal.find(".report_submit").hide(),$('<div class="loader"><img src="'+cdn_host+'/img/site/ajax-loader.gif"></div>').insertAfter(ReportProblem.$modal.find(".report_submit")),this.xhr=$.ajax({url:"/ajax/report-problem",dataType:"json",data:e,success:function(e){var t="";e.status?(t=_("thank_you_report_problem"),ReportProblem.$modal.find(".form_report_out").html(t),$(".form_report_out").show(),$("#modal-problem-report .title_block").remove()):(t=e.msg,ReportProblem.$modal.find(".srv_error").html(t),$(".srv_error").show()),ReportProblem.$modal.find(".loader").remove(),ReportProblem.$modal.find(".report_submit").show(),(ReportProblem.xhr=null)==window.json_arr.desktop&&grecaptcha.reset(),e.status&&($(".report_fields").hide(500),setTimeout(function(){ReportProblem.closeReportModal()},1e4)),-1!=location.hash.search(/^#report/)&&replaceHash("")}}))},closeReportModal:function(){var e,t;this.$modal.addClass("hide").removeClass("show"),"function"==typeof bodyUnfixPosition?bodyUnfixPosition():$("html, body").css({overflow:"visible"}),this.isiPhone()&&(e=parseInt($("body").css("top")),$("body").removeClass("active-modal-report-iOS "),$("body").css("top",""),window.scrollTo(0,-e)),"promotion"!=this.$modal.find("input[name=object_type]").val()&&("undefined"!=typeof ArticleGallery?(t=ArticleGallery.getPhotoSwipe())?.options&&(t.options.arrowKeys=!1):"undefined"!=typeof AIGallery?(t=AIGallery.getPhotoSwipe())?.options&&(t.options.arrowKeys=!1):Gallery.isPhotoSwipeInit()&&(t=Gallery.getPhotoSwipe())?.options&&(t.options.arrowKeys=!0)),this.getFieldValues()},renderRecaptcha:function(){$("#reportrecaptcha").each(function(){ReportProblem.widget_object=grecaptcha.render($(this).attr("id"),{sitekey:recaptcha_sitekey,size:"invisible",badge:"inline",callback:function(){$(".srv_error").html("")}})})},recaptchaInit:function(){"undefined"!=typeof grecaptcha?this.renderRecaptcha():(window.renderReportRecaptcha=this.renderRecaptcha,$.getScript("//www.google.com/recaptcha/api.js?hl=en&render=explicit&onload=renderReportRecaptcha"))},makeReportProblemModal:function(e,t){var o;this.makeForm(t),this.$modal.find('input[type="text"], input[type="email"],textarea').val(""),this.$modal.find('[name="object_id"]').val(e),this.$modal.find('[name="object_type"]').val(t),this.recaptchaInit(),$(".report_fields").show(),$(".report_error").hide(),$(".form_report_out").html(""),this.$modal.addClass("show").removeClass("hide"),"function"==typeof bodyFixPosition?bodyFixPosition():$("html, body").css({overflow:"hidden"}),["photo","image","video"].includes(t)?this.$modal.find(".sub_title_block").show():this.$modal.find(".sub_title_block").hide(),"promotion"!=t&&("undefined"!=typeof ArticleGallery?(o=ArticleGallery.getPhotoSwipe())?.options&&(o.options.arrowKeys=!1):"undefined"!=typeof AIGallery?(o=AIGallery.getPhotoSwipe())?.options&&(o.options.arrowKeys=!1):Gallery.isPhotoSwipeInit()&&(o=Gallery.getPhotoSwipe())?.options&&(o.options.arrowKeys=!1)),this.isiPhone()&&(e=window.pageYOffset||document.documentElement.scrollTop,$("body").addClass("active-modal-report-iOS"),$("body").css("top",-e+"px")),anchorAdElemModify($(".form_report")),this.setFieldValues()},isiPhone:function(){return/iPhone|iPod/.test(navigator.userAgent)}
1,getFieldValues:function(){var e=document.querySelector('#modal-problem-report input[name="email"]'),t=document.querySelector('#modal-problem-report textarea[name="message"]'),e=e?e.value:"",t=t?t.value:"",e=(this.fieldValues.email=e,this.fieldValues.message=t,document.querySelectorAll("#modal-problem-report .checkbox--origin:checked")),t=(e.length&&(this.fieldValues.checkboxes=Array.from(e).map(e=>e.id)),document.querySelector("#modal-problem-report .report_option.active"));t&&(this.fieldValues.cause=t.getAttribute("data-value"))},setFieldValues:function(){let t=this;var e=document.querySelector('#modal-problem-report input[name="email"]'),o=(e&&0<t.fieldValues.email.length&&(e.value=t.fieldValues.email),document.querySelector('#modal-problem-report textarea[name="message"]'));e&&0<t.fieldValues.message.length&&(o.value=t.fieldValues.message),document.querySelectorAll("#modal-problem-report .checkbox--origin").forEach(e=>{t.fieldValues.checkboxes.includes(e.id)?e.checked=!0:e.checked=!1}),document.querySelector("#modal-problem-report .report_select")&&t.fieldValues.cause&&$(`#modal-problem-report .report_option[data-value="${t.fieldValues.cause}"]`).click().click()}},StickyMenuNav=((()=>{function s(e){var h,_,t,o,n,i;return this instanceof s?(this.version=1,this.support=!("undefined"==typeof File||"undefined"==typeof Blob||"undefined"==typeof FileList||!Blob.prototype.webkitSlice&&!Blob.prototype.mozSlice&&!Blob.prototype.slice),!!this.support&&((h=this).files=[],h.defaults={chunkSize:1048576,forceChunkSize:!1,simultaneousUploads:3,fileParameterName:"file",chunkNumberParameterName:"resumableChunkNumber",chunkSizeParameterName:"resumableChunkSize",currentChunkSizeParameterName:"resumableCurrentChunkSize",totalSizeParameterName:"resumableTotalSize",typeParameterName:"resumableType",identifierParameterName:"resumableIdentifier",fileNameParameterName:"resumableFilename",relativePathParameterName:"resumableRelativePath",totalChunksParameterName:"resumableTotalChunks",dragOverClass:"dragover",throttleProgressCallbacks:.5,query:{},headers:{},preprocess:null,preprocessFile:null,method:"multipart",uploadMethod:"POST",testMethod:"GET",prioritizeFirstAndLastChunk:!1,target:"/",testTarget:null,parameterNamespace:"",testChunks:!0,generateUniqueIdentifier:null,getTarget:null,maxChunkRetries:100,chunkRetryInterval:void 0,permanentErrors:[400,401,403,404,409,415,500,501],maxFiles:void 0,withCredentials:!1,xhrTimeout:0,clearInput:!0,chunkFormat:"blob",setChunkTypeFromFile:!1,maxFilesErrorCallback:function(e,t){var o=h.getOpt("maxFiles");alert("Please upload no more than "+o+" file"+(1===o?"":"s")+" at a time.")},minFileSize:1,minFileSizeErrorCallback:function(e,t){alert(e.fileName||e.name+" is too small, please upload files larger than "+_.formatSize(h.getOpt("minFileSize"))+".")},maxFileSize:void 0,maxFileSizeErrorCallback:function(e,t){alert(e.fileName||e.name+" is too large, please upload files less than "+_.formatSize(h.getOpt("maxFileSize"))+".")},fileType:[],fileTypeErrorCallback:function(e,t){alert(e.fileName||e.name+" has type not allowed, please upload files of type "+h.getOpt("fileType")+".")}},h.opts=e||{},h.getOpt=function(e){var t,o=this;if(e instanceof Array)return t={},_.each(e,function(e){t[e]=o.getOpt(e)}),t;if(o instanceof r){if(void 0!==o.opts[e])return o.opts[e];o=o.fileObj}if(o instanceof f){if(void 0!==o.opts[e])return o.opts[e];o=o.resumableObj}return o instanceof s?(void 0!==o.opts[e]?o.opts:o.defaults)[e]:void 0},h.indexOf=function(e,t){if(e.indexOf)return e.indexOf(t);for(var o=0;o<e.length;o++)if(e[o]===t)return o;return-1},h.events=[],h.on=function(e,t){h.events.push(e.toLowerCase(),t)},h.fire=function(){for(var e=[],t=0;t<arguments.length;t++)e.push(arguments[t]);for(var o=e[0].toLowerCase(),t=0;t<=h.events.length;t+=2)h.events[t]==o&&h.events[t+1].apply(h,e.slice(1)),"catchall"==h.events[t]&&h.events[t+1].apply(null,e);"fileerror"==o&&h.fire("error",e[2],e[1]),"fileprogress"==o&&h.fire("progress")},_={stopEvent:function(e){e.stopPropagation(),e.preventDefault()},each:function(e,t){if(void 0!==e.length){for(var o=0;o<e.length;o++)if(!1===t(e[o]))return}else for(o in e)if(!1===t(o,e[o]))return},generateUniqueIdentifier:function(e,t){var o=h.getOpt("generateUniqueIdentifier");return"function"==typeof o?o(e,t):(o=e.webkitRelativePath||e.relativePath||e.fileName||e.name,e.size+"-"+o.replace(/[^0-9a-zA-Z_-]/gim,""))},contains:function(e,t){var o=!1;return _.each(e,function(e){return e!=t||!(o=!0)}),o},formatSize:function(e){return e<1024?e+" bytes":e<1048576?(e/1024).toFixed(0)+" KB":e<1073741824?(e/1024/1024).toFixed(1)+" MB":(e/1024/1024/1024).toFixed(1)+" GB"},getTarget:function(e,t){var o=h.getOpt("target");return"function"==typeof(o="test"===e&&h.getOpt("testTarget")?"/"===h.getOpt("testTarget")?h.getOpt("target"):h.getOpt("testTarget"):o)?o(t):(e=o.indexOf("?")<0?"?":"&",(t=t.join("&"))?o+e+t:o)}},t=function(e){e.currentTarget.classList.remove(h.getOpt("dragOverClass")),_.stopEvent(e),e.dataTransfer&&e.dataTransfer.items?a(e.dataTransfer.items,e):e.dataTransfer&&e.dataTransfer.files&&a(e.dataTransfer.files,e)},o=function(e){e.currentTarget.classList.remove(h.getOpt("dragOverClass"))},n=function(e){e.preventDefault();var t=e.dataTransfer;0<=h.indexOf(t.types,"Files")?(e.stopPropagation(),t.dropEffect="copy",t.effectAllowed="copy",e.currentTarget.classList.add(h.getOpt("dragOverClass"))):(t.dropEffect="none",t.effectAllowed="none")},i=function(e,l){var c=0,d=h.getOpt(["maxFiles","minFileSize","maxFileSize","maxFilesErrorCallback","minFileSizeErrorCallback","maxFileSizeErrorCallback","fileType","fileTypeErrorCallback"]);if(void 0!==d.maxFiles&&d.maxFiles<e.length+h.files.length){if(1!==d.maxFiles||1!==h.files.length||1!==e.length)return d.maxFilesErrorCallback(e,c++),!1;h.removeFile(h.files[0])}function u(){--t||(m.length||p.length)&&window.setTimeout(function(){h.fire("filesAdded",m,p)},0)}var m=[],p=[],t=e.length;_.each(e,function(o){var e,t=o.name,n=o.type;if(0<d.fileType.length){var i,a=!1;for(i in d.fileType){d.fileType[i]=d.fileType[i].replace(/\s/g,"").toLowerCase();var r=(d.fileType[i].match(/^[^.][^/]+$/)?".":"")+d.fileType[i];if(t.substr(-1*r.length).toLowerCase()===r||-1!==r.indexOf("/")&&(-1!==r.indexOf("*")&&n.substr(0,r.indexOf("*"))===r.substr(0,r.indexOf("*"))||n===r)){a=!0;break}}if(!a)return d.fileTypeErrorCallback(o,c++),!0}return void 0!==d.minFileSize&&o.size<d.minFileSize?(d.minFileSizeErrorCallback(o,c++),!0):void 0!==d.maxFileSize&&o.size>d.maxFileSize?(d.maxFileSizeErrorCallback(o,c++),!0):void((e=_.generateUniqueIdentifier(o,l))&&"function"==typeof e.then?e.then(function(e){s(e)},function(){u()}):s(e));function s(e){var t;h.getFromUniqueIdentifier(e)?p.push(o):(o.uniqueIdentifier=e,t=new f(h,o,e),h.files.push(t),m.push(t),t.container=void 0!==l?l.srcElement:null,window.setTimeout(function(){h.fire("fileAdded",t,l)},0)),u()}})},h.uploadNextChunk=function(){var t,o=!1;return!(!h.getOpt("prioritizeFirstAndLastChunk")||(_.each(h.files,function(e){return e.chunks.length&&"pending"==e.chunks[0].status()&&0===e.chunks[0].preprocessState?(e.chunks[0].send(),!(o=!0)):1<e.chunks.length&&"pending"==e.chunks[e.chunks.length-1].status()&&0===e.chunks[e.chunks.length-1].preprocessState?(e.chunks[e.chunks.length-1].send(),!(o=!0)):void 0}),!o))||(_.each(h.files,function(e){if(o=e.upload())return!1}),!!o)||(t=!1,_.each(h.files,function(e){if(!e.isComplete())return!(t=!0)}),t||h.fire("complete"),!1)},h.assignBrowse=function(e,o){void 0===e.length&&(e=[e]),_.each(e,function(e){"INPUT"===e.tagName&&"file"===e.type?t=e:((t=document.createElement("input")).setAttribute("type","file"),t.style.display="none",e.addEventListener("click",function(){t.style.opacity=0,t.style.display="block",t.focus(),t.click(),t.style.display="none"},!1),e.appendChild(t));var t,e=h.getOpt("maxFiles"),e=(void 0===e||1!=e?t.setAttribute("multiple","multiple"):t.removeAttribute("multiple"),o?t.setAttribute("webkitdirectory","webkitdirectory"):t.removeAttribute("webkitdirectory"),h.getOpt("fileType"));void 0!==e&&1<=e.length?t.setAttribute("accept",e.map(function(e){return e=(e=e.replace(/\s/g,"").toLowerCase()).match(/^[^.][^/]+$/)?"."+e:e}).join(",")):t.removeAttribute("accept"),t.addEventListener("change",function(e){i(e.target.files,e),h.getOpt("clearInput")&&(e.target.value="")},!1)})},h.assignDrop=function(e){void 0===e.length&&(e=[e]),_.each(e,function(e){e.addEventListener("dragover",n,!1),e.addEventListener("dragenter",n,!1),e.addEventListener("dragleave",o,!1),e.addEventListener("drop",t,!1)})},h.unAssignDrop=function(e){void 0===e.length&&(e=[e]),_.each(e,function(e){e.removeEventListener("dragover",n
1),e.removeEventListener("dragenter",n),e.removeEventListener("dragleave",o),e.removeEventListener("drop",t)})},h.isUploading=function(){var t=!1;return _.each(h.files,function(e){if(e.isUploading())return!(t=!0)}),t},h.upload=function(){if(!h.isUploading()){h.fire("uploadStart");for(var e=1;e<=h.getOpt("simultaneousUploads");e++)h.uploadNextChunk()}},h.pause=function(){_.each(h.files,function(e){e.abort()}),h.fire("pause")},h.cancel=function(){h.fire("beforeCancel");for(var e=h.files.length-1;0<=e;e--)h.files[e].cancel();h.fire("cancel")},h.progress=function(){var t=0,o=0;return _.each(h.files,function(e){t+=e.progress()*e.size,o+=e.size}),0<o?t/o:0},h.addFile=function(e,t){i([e],t)},h.addFiles=function(e,t){i(e,t)},h.removeFile=function(e){for(var t=h.files.length-1;0<=t;t--)h.files[t]===e&&h.files.splice(t,1)},h.getFromUniqueIdentifier=function(t){var o=!1;return _.each(h.files,function(e){e.uniqueIdentifier==t&&(o=e)}),o},h.getSize=function(){var t=0;return _.each(h.files,function(e){t+=e.size}),t},h.handleDropEvent=function(e){t(e)},h.handleChangeEvent=function(e){i(e.target.files,e),e.target.value=""},h.updateQuery=function(e){h.opts.query=e},this)):new s(e);function d(e,t,o,n){var i,a,r,s,l,c;if(e.isFile)return e.file(function(e){e.relativePath=t+e.name,o.push(e),n()});e.isDirectory?i=e:e instanceof File&&o.push(e),((i="function"==typeof e.webkitGetAsEntry?e.webkitGetAsEntry():i)&&i.isDirectory?(a=t+i.name+"/",r=o,s=n,l=i.createReader(),c=[],function t(){l.readEntries(function(e){if(e.length)return c=c.concat(e),t();u(c.map(function(e){return d.bind(null,e,a,r)}),s)})}):("function"==typeof e.getAsFile&&(e=e.getAsFile())instanceof File&&(e.relativePath=t+e.name,o.push(e)),n))()}function u(e,t){if(!e||0===e.length)return t();e[0](function(){u(e.slice(1),t)})}function a(e,t){var o;e.length&&(h.fire("beforeAdd"),o=[],u(Array.prototype.map.call(e,function(e){var t=e;return"function"==typeof e.webkitGetAsEntry&&(t=e.webkitGetAsEntry()),d.bind(null,t,"",o)}),function(){o.length&&i(o,t)}))}function f(e,t,o){function n(e,t){switch(e){case"progress":i.resumableObj.fire("fileProgress",i,t);break;case"error":i.abort(),a=!0,i.chunks=[],i.resumableObj.fire("fileError",i,t);break;case"success":a||(i.resumableObj.fire("fileProgress",i,t),i.isComplete()&&i.resumableObj.fire("fileSuccess",i,t));break;case"retry":i.resumableObj.fire("fileRetry",i)}}var i=this,a=(i.opts={},i.getOpt=e.getOpt,i._prevProgress=0,i.resumableObj=e,i.file=t,i.fileName=t.fileName||t.name,i.size=t.size,i.relativePath=t.relativePath||t.webkitRelativePath||i.fileName,i.uniqueIdentifier=o,i._pause=!1,i.container="",void(i.preprocessState=0)!==o);return i.chunks=[],i.abort=function(){var t=0;_.each(i.chunks,function(e){"uploading"==e.status()&&(e.abort(),t++)}),0<t&&i.resumableObj.fire("fileProgress",i)},i.cancel=function(){var e=i.chunks;i.chunks=[],_.each(e,function(e){"uploading"==e.status()&&(e.abort(),i.resumableObj.uploadNextChunk())}),i.resumableObj.removeFile(i),i.resumableObj.fire("fileProgress",i)},i.retry=function(){i.bootstrap();var e=!1;i.resumableObj.on("chunkingComplete",function(){e||i.resumableObj.upload(),e=!0})},i.bootstrap=function(){i.abort(),a=!1,i.chunks=[],i._prevProgress=0;for(var e=i.getOpt("forceChunkSize")?Math.ceil:Math.floor,t=Math.max(e(i.file.size/i.getOpt("chunkSize")),1),o=0;o<t;o++)(e=>{window.setTimeout(function(){i.chunks.push(new r(i.resumableObj,i,e,n)),i.resumableObj.fire("chunkingProgress",i,e/t)},0)})(o);window.setTimeout(function(){i.resumableObj.fire("chunkingComplete",i)},0)},i.progress=function(){var t,o;return a?1:(t=0,o=!1,_.each(i.chunks,function(e){"error"==e.status()&&(o=!0),t+=e.progress(!0)}),t=o||.99999<t?1:t,t=Math.max(i._prevProgress,t),i._prevProgress=t)},i.isUploading=function(){var t=!1;return _.each(i.chunks,function(e){if("uploading"==e.status())return!(t=!0)}),t},i.isComplete=function(){var o=!1;return 1!==i.preprocessState&&(_.each(i.chunks,function(e){var t=e.status();if("pending"==t||"uploading"==t||1===e.preprocessState)return!(o=!0)}),!o)},i.pause=function(e){i._pause=void 0===e?!i._pause:e},i.isPaused=function(){return i._pause},i.preprocessFinished=function(){i.preprocessState=2,i.upload()},i.upload=function(){var t=!1;if(!1===i.isPaused()){var e=i.getOpt("preprocessFile");
1if("function"==typeof e)switch(i.preprocessState){case 0:return i.preprocessState=1,e(i),!0;case 1:return!0}_.each(i.chunks,function(e){if("pending"==e.status()&&1!==e.preprocessState)return e.send(),!(t=!0)})}return t},i.markChunksCompleted=function(e){if(i.chunks&&!(i.chunks.length<=e))for(var t=0;t<e;t++)i.chunks[t].markComplete=!0},i.resumableObj.fire("chunkingStart",i),i.bootstrap(),this}function r(e,t,o,n){var l=this,e=(l.opts={},l.getOpt=e.getOpt,l.resumableObj=e,l.fileObj=t,l.fileObjSize=t.size,l.fileObjType=t.file.type,l.offset=o,l.callback=n,l.lastProgressCallback=new Date,l.tested=!1,l.retries=0,l.pendingRetry=!1,l.preprocessState=0,l.markComplete=!1,l.getOpt("chunkSize"));return l.loaded=0,l.startByte=l.offset*e,l.endByte=Math.min(l.fileObjSize,(l.offset+1)*e),l.fileObjSize-l.endByte<e&&!l.getOpt("forceChunkSize")&&(l.endByte=l.fileObjSize),l.xhr=null,l.test=function(){l.xhr=new XMLHttpRequest;function e(e){l.tested=!0;var t=l.status();"success"==t?(l.callback(t,l.message()),l.resumableObj.uploadNextChunk()):l.send()}l.xhr.addEventListener("load",e,!1),l.xhr.addEventListener("error",e,!1),l.xhr.addEventListener("timeout",e,!1);var o=[],n=l.getOpt("parameterNamespace"),t=l.getOpt("query"),t=("function"==typeof t&&(t=t(l.fileObj,l)),_.each(t,function(e,t){o.push([encodeURIComponent(n+e),encodeURIComponent(t)].join("="))}),o=o.concat([["chunkNumberParameterName",l.offset+1],["chunkSizeParameterName",l.getOpt("chunkSize")],["currentChunkSizeParameterName",l.endByte-l.startByte],["totalSizeParameterName",l.fileObjSize],["typeParameterName",l.fileObjType],["identifierParameterName",l.fileObj.uniqueIdentifier],["fileNameParameterName",l.fileObj.fileName],["relativePathParameterName",l.fileObj.relativePath],["totalChunksParameterName",l.fileObj.chunks.length]].filter(function(e){return l.getOpt(e[0])}).map(function(e){return[n+l.getOpt(e[0]),encodeURIComponent(e[1])].join("=")})),l.xhr.open(l.getOpt("testMethod"),_.getTarget("test",o)),l.xhr.timeout=l.getOpt("xhrTimeout"),l.xhr.withCredentials=l.getOpt("withCredentials"),l.getOpt("headers"));"function"==typeof t&&(t=t(l.fileObj,l)),_.each(t,function(e,t){l.xhr.setRequestHeader(e,t)}),l.xhr.send(null)},l.preprocessFinished=function(){l.preprocessState=2,l.send()},l.send=function(){var o,n,i,t,a,e,r,s=l.getOpt("preprocess");if("function"==typeof s)switch(l.preprocessState){case 0:return l.preprocessState=1,void s(l);case 1:return}l.getOpt("testChunks")&&!l.tested?l.test():(l.xhr=new XMLHttpRequest,l.xhr.upload.addEventListener("progress",function(e){new Date-l.lastProgressCallback>1e3*l.getOpt("throttleProgressCallbacks")&&(l.callback("progress"),l.lastProgressCallback=new Date),l.loaded=e.loaded||0},!1),l.loaded=0,l.pendingRetry=!1,l.callback("progress"),l.xhr.addEventListener("load",e=function(e){var t=l.status();"success"==t||"error"==t?(l.callback(t,l.message()),l.resumableObj.uploadNextChunk()):(l.callback("retry",l.message()),l.abort(),l.retries++,void 0!==(t=l.getOpt("chunkRetryInterval"))?(l.pendingRetry=!0,setTimeout(l.send,t)):l.send())},!1),l.xhr.addEventListener("error",e,!1),l.xhr.addEventListener("timeout",e,!1),o=[["chunkNumberParameterName",l.offset+1],["chunkSizeParameterName",l.getOpt("chunkSize")],["currentChunkSizeParameterName",l.endByte-l.startByte],["totalSizeParameterName",l.fileObjSize],["typeParameterName",l.fileObjType],["identifierParameterName",l.fileObj.uniqueIdentifier],["fileNameParameterName",l.fileObj.fileName],["relativePathParameterName",l.fileObj.relativePath],["totalChunksParameterName",l.fileObj.chunks.length]].filter(function(e){return l.getOpt(e[0])}).reduce(function(e,t){return e[l.getOpt(t[0])]=t[1],e},{}),"function"==typeof(e=l.getOpt("query"))&&(e=e(l.fileObj,l)),_.each(e,function(e,t){o[e]=t}),e=l.fileObj.file.slice?"slice":l.fileObj.file.mozSlice?"mozSlice":l.fileObj.file.webkitSlice?"webkitSlice":"slice",e=l.fileObj.file[e](l.startByte,l.endByte,l.getOpt("setChunkTypeFromFile")?l.fileObj.file.type:""),a=null,n=[],i=l.getOpt("parameterNamespace"),"octet"===l.getOpt("method")?(a=e,_.each(o,function(e,t){n.push([encodeURIComponent(i+e),encodeURIComponent(t)].join("="))})):(a=new FormData,_.each(o,function(e,t){a.append(i+e,t),n.push([encodeURIComponent(i+e),encodeURIComponent(t)].join("="))}),"blob"==l.getOpt("chunkFormat")?a.append(i+l.getOpt("fileParameterName"),e,l.fileObj.fileName):"base64"==l.getOpt("chunkFormat")&&((t=new FileReader).onload=function(e){a.append(i+l.getOpt("fileParameterName"),t.result),l.xhr.send(a)}
1,t.readAsDataURL(e))),e=_.getTarget("upload",n),r=l.getOpt("uploadMethod"),l.xhr.open(r,e),"octet"===l.getOpt("method")&&l.xhr.setRequestHeader("Content-Type","application/octet-stream"),l.xhr.timeout=l.getOpt("xhrTimeout"),l.xhr.withCredentials=l.getOpt("withCredentials"),"function"==typeof(r=l.getOpt("headers"))&&(r=r(l.fileObj,l)),_.each(r,function(e,t){l.xhr.setRequestHeader(e,t)}),"blob"==l.getOpt("chunkFormat")&&l.xhr.send(a))},l.abort=function(){l.xhr&&l.xhr.abort(),l.xhr=null},l.status=function(){return l.pendingRetry?"uploading":l.markComplete?"success":l.xhr?l.xhr.readyState<4?"uploading":200==l.xhr.status||201==l.xhr.status?"success":_.contains(l.getOpt("permanentErrors"),l.xhr.status)||l.retries>=l.getOpt("maxChunkRetries")?"error":(l.abort(),"pending"):"pending"},l.message=function(){return l.xhr?l.xhr.responseText:""},l.progress=function(e){var t=(e=void 0===e?!1:e)?(l.endByte-l.startByte)/l.fileObjSize:1;if(l.pendingRetry)return 0;switch(l.xhr&&l.xhr.status||l.markComplete||(t*=.95),l.status()){case"success":case"error":return+t;case"pending":return 0*t;default:return l.loaded/(l.endByte-l.startByte)*t}},this}}"undefined"!=typeof module?(module.exports=s,module.exports.Resumable=s):"function"==typeof define&&define.amd?define(function(){return s}):window.Resumable=s})(),{animate_in_progress:!1,conf:{photo_id:".photo-link"},init:function(e){var i=this;$.extend(!0,this.conf,e),$(document).on("sticky_nav_removed",function(){$("#stickyNav .nav_item.active").removeClass("active")}),$(document).on("click",".menu_nav",function(e){var e=e.target,t=window_match_media(1030,"max")?$(".wrapper_header").outerHeight():54,o=$(e).data("id"),n=$("#stickyNav").outerHeight();$(e).hasClass("nav_item")&&($(".menu_nav .nav_item").each(function(){$(this).removeClass("active")}),$(e).addClass("active"),i.animate_in_progress=!0,$("html, body").stop(!0,!0).animate({scrollTop:$(o).offset().top-t-n-10},500,function(){i.animate_in_progress=!1}))}),0<$(".menu_nav").length&&$(document).on("resize scroll",function(){i.scrollHandler(),i.scrollActiveMenuHandler()}),$(document).on("click",".see_all_menu",function(){var e='<div class=" menu_loading"><img src="'+cdn_host+'/img/site/AjaxLoader.gif" alt=""></div>';$(this).append(e),$.ajax({type:"GET",url:"/ajax/load-menu",data:{restaurant_id:$(".add_review_btn").data("rid")},dataType:"json",success:function(e){var t,o,n,i,a;e.status&&(t=$(".menu_nav").attr("style"),o=$("#stickyNav").attr("class"),n=$("#stickyNav").attr("style"),(i=$("#stickyNav .nav_item.active"))&&(a=i.data("id")),$(".content_bottom").html(e.content),$(".menu_nav").attr("style",t),$("#stickyNav").attr("class",o),$("#stickyNav").attr("style",n),a)&&$('#stickyNav .nav_item[data-id="'+a+'"]').addClass("active")}})})}
1,getViewport:function(){var e=$(window),t={top:e.scrollTop(),left:e.scrollLeft()};return t.right=t.left+e.width(),t.bottom=t.top+e.height(),t},getImageBounds:function(e){var t=(e=$(e)).offset();return t.right=t.left+e.outerWidth(),t.bottom=t.top+e.outerHeight(),t},isOnScreen:function(e,t,o){e=Object.assign({},e);return e.top+=o,!(e.right<t.left||e.left>t.right||e.bottom<t.top||e.top>t.bottom)},scrollActiveMenuHandler:function(){var n,i,a=this;$("#stickyNav").hasClass("sticky")&&!a.animate_in_progress&&(n=a.getViewport(),i=$(".wrapper_header").outerHeight()+$(".menu_nav").outerHeight()+10,$(a.conf.photo_id).each(function(e,t){var o=a.getImageBounds(t);return!a.isOnScreen(n,o,i)||((o=$(t).prevAll(".header_wrapper")[0])&&(t=$(o).find("h3").attr("id"))&&($("#stickyNav .nav_item.active").removeClass("active"),$('#stickyNav .nav_item[data-id="#'+t+'"]').addClass("active")),!1)}))},scrollHandler:function(){var e=$("#stickyNav"),t=$(e.parent()[0]),o=t.outerHeight(),n=$(".wrapper_header").outerHeight()-1,i=$(".header").outerHeight(),a=$(window).scrollTop(),r=$(".menu_nav").offset().top,n=$("body").hasClass("qr")?0:window_match_media(1030,"max")?n:i;r<a+n?(e.addClass("sticky").css({top:n,bottom:"auto"}),t.css("height",o+"px")):(e.removeClass("sticky").css({top:"0",bottom:"auto"}),t.css("height","auto"),$(document).trigger("sticky_nav_removed"))}}),claim_form_authorization=((d=>{function b(e,t,o){"addEventListener"in window?e.addEventListener(t,o,!1):"attachEvent"in window&&e.attachEvent("on"+t,o)}function G(e,t,o){"removeEventListener"in window?e.removeEventListener(t,o,!1):"detachEvent"in window&&e.detachEvent("on"+t,o)}function f(e){return M+"["+(t="Host page: "+(e=e),t=window.top!==window.self?window.parentIFrame&&window.parentIFrame.getId?window.parentIFrame.getId()+": "+e:"Nested host page: "+e:t)+"]";var t}function o(e){return D[e]?D[e].log:p}function y(e,t){n("log",e,t,o(e))}function $(e,t){n("info",e,t,o(e))}function k(e,t){n("warn",e,t,!0)}function n(e,t,o,n){!0===n&&"object"==typeof window.console&&console[e](f(t),o)}function g(e){function t(){o("Height"),o("Width"),j(function(){I(_),S(f),l("resizedCallback",_)},_,"init")}function o(e){var t=Number(D[f]["max"+e]),o=Number(D[f]["min"+e]),e=e.toLowerCase(),n=Number(_[e]);y(f,"Checking "+e+" is in range "+o+"-"+t),n<o&&(n=o,y(f,"Set "+e+" to min value")),t<n&&(n=t,y(f,"Set "+e+" to max value")),_[e]=""+n}function n(e){return h.substr(h.indexOf(":")+A+e)}function i(o,n){var e,t,i;e=function(){var e,t;F("Send Page Info","pageInfo:"+(e=document.body.getBoundingClientRect(),t=_.iframe.getBoundingClientRect(),JSON.stringify({iframeHeight:t.height,iframeWidth:t.width,clientHeight:Math.max(document.documentElement.clientHeight,window.innerHeight||0),clientWidth:Math.max(document.documentElement.clientWidth,window.innerWidth||0),offsetTop:parseInt(t.top-e.top,10),offsetLeft:parseInt(t.left-e.left,10),scrollTop:window.pageYOffset,scrollLeft:window.pageXOffset})),o,n)},t=32,z[i=n]||(z[i]=setTimeout(function(){z[i]=null,e()},t))}function a(e){e=e.getBoundingClientRect();return T(f),{x:Math.floor(Number(e.left)+Number(L.x)),y:Math.floor(Number(e.top)+Number(L.y))}}function r(e){var t=e?a(_.iframe):{x:0,y:0},o={x:Number(_.width)+t.x,y:Number(_.height)+t.y};y(f,"Reposition requested from iFrame (offset x:"+t.x+" y:"+t.y+")"),window.top!==window.self?window.parentIFrame?window.parentIFrame["scrollTo"+(e?"Offset":"")](o.x,o.y):k(f,"Unable to scroll to requested position, window.parentIFrame not found"):(L=o,s(),y(f,"--"))}function s(){!1!==l("scrollCallback",L)?S(f):E()}function l(e,t){return x(f,e,t)}var c,d,u,m,p,h=e.data,_={},f=null;if("[iFrameResizerChild]Ready"===h)for(var g in D)F("iFrame requested init",R(g),document.getElementById(g),g);else if(M===(""+h).substr(0,O)&&h.substr(O).split(":")[0]in D){if(p=h.substr(O).split(":"),_={iframe:D[p[0]]&&D[p[0]].iframe,id:p[0],height:p[1],width:p[2],type:p[3]},f=_.id,D[f]&&(D[f].loaded=!0),(p=_.type in{true:1,false:1,undefined:1})&&y(f,"Ignoring init message from meta parent page"),!p&&(m=!0,D[p=f]||(m=!1,k(_.type+" No settings for "+p+". Message was: "+h)),m)&&(y(f,"Received: "+h),p=!0,null===_.iframe&&(k(f,"IFrame ("+_.id+") not found"),p=!1),p&&(()=>{var n=e.origin,i=D[f]&&D[f].checkOrigin;if(i&&""+n!="null"&&!(()=>
1{if(i.constructor!==Array)return e=D[f]&&D[f].remoteHost,y(f,"Checking connection is from: "+e),n===e;var e,t=0,o=!1;for(y(f,"Checking connection is from allowed list of origins: "+i);t<i.length;t++)if(i[t]===n){o=!0;break}return o})())throw new Error("Unexpected message received from: "+n+" for "+_.iframe.id+". Message was: "+e.data+". This error can be disabled by setting the checkOrigin: false option or by providing of array of trusted domains.");return 1})())){switch(D[f]&&D[f].firstRun&&(D[f]&&(D[f].firstRun=!1)),_.type){case"close":D[f].closeRequestCallback?x(f,"closeRequestCallback",D[f].iframe):C(_.iframe);break;case"message":u=n(6),y(f,"MessageCallback passed: {iframe: "+_.iframe.id+", message: "+u+"}"),l("messageCallback",{iframe:_.iframe,message:JSON.parse(u)}),y(f,"--");break;case"scrollTo":r(!1);break;case"scrollToOffset":r(!0);break;case"pageInfo":i(D[f]&&D[f].iframe,f),d=f,v("Add ",b),D[d]&&(D[d].stopPageInfo=w);break;case"pageInfoStop":D[f]&&D[f].stopPageInfo&&(D[f].stopPageInfo(),delete D[f].stopPageInfo);break;case"inPageLink":u=(u=n(9)).split("#")[1]||"",c=decodeURIComponent(u),(c=document.getElementById(c)||document.getElementsByName(c)[0])?(c=a(c),y(f,"Moving to in page link (#"+u+") at x: "+c.x+" y: "+c.y),L={x:c.x,y:c.y},s(),y(f,"--")):window.top!==window.self?window.parentIFrame?window.parentIFrame.moveToAnchor(u):y(f,"In page link #"+u+" not found and window.parentIFrame not found"):y(f,"In page link #"+u+" not found");break;case"reset":P(_);break;case"init":t(),l("initCallback",_.iframe);break;default:t()}function v(t,o){function n(){D[d]?i(D[d].iframe,d):w()}["scroll","resize"].forEach(function(e){y(d,t+e+" listener for sendPageInfo"),o(window,e,n)})}function w(){v("Remove ",G)}}}else $(f,"Ignored: "+h)}function x(e,t,o){var n=null,i=null;if(D[e]){if("function"!=typeof(n=D[e][t]))throw new TypeError(t+" on iFrame["+e+"] is not a function");i=n(o)}return i}function u(e){e=e.id;delete D[e]}function C(e){var t=e.id;y(t,"Removing iFrame: "+t);try{e.parentNode&&e.parentNode.removeChild(e)}catch(e){}x(t,"closedCallback",t),y(t,"--"),u(e)}function T(e){null===L&&y(e,"Get page position: "+(L={x:window.pageXOffset!==d?window.pageXOffset:document.documentElement.scrollLeft,y:window.pageYOffset!==d?window.pageYOffset:document.documentElement.scrollTop}).x+","+L.y)}function S(e){null!==L&&(window.scrollTo(L.x,L.y),y(e,"Set page position: "+L.x+","+L.y),E())}function E(){L=null}function P(e){y(e.id,"Size reset requested by "+("init"===e.type?"host page":"iFrame")),T(e.id),j(function(){I(e),F("reset","reset",e.iframe,e.id)},e,"reset")}function I(i){function o(e){{var t;!c&&"0"===i[e]&&(c=!0,y(a,"Hidden iFrame detected, creating visibility listener"),e=window.MutationObserver||window.WebKitMutationObserver)&&(t=document.querySelector("body"),new e(n).observe(t,{attributes:!0,attributeOldValue:!1,characterData:!0,characterDataOldValue:!1,childList:!0,subtree:!0}))}function o(){for(var e in D)(t=>{function e(e){return"0px"===(D[t]&&D[t].iframe.style[e])}D[t]&&null!==D[t].iframe.offsetParent&&(e("height")||e("width"))&&F("Visibility change","resize",D[t].iframe,t)})(e)}function n(e){y("window","Mutation observed: "+e[0].target+" "+e[0].type),r(o,16)}}function e(e){var t;t=e,i.iframe.style[t]=i[t]+"px",y(i.id,"IFrame ("+a+") "+t+" set to "+i[t]+"px"),o(e)}var a=i.iframe.id;D[a]&&(D[a].sizeHeight&&e("height"),D[a].sizeWidth)&&e("width")}function j(e,t,o){o!==t.type&&h?(y(t.id,"Requesting animation frame"),h(e)):e()}function F(e,t,o,n,i){var a,r=!1;n=n||o.id,D[n]&&(o&&"contentWindow"in o&&null!==o.contentWindow?(a=D[n]&&D[n].targetOrigin,y(n,"["+e+"] Sending msg to iframe["+n+"] ("+t+") targetOrigin: "+a),o.contentWindow.postMessage(M+t,a)):k(n,"["+e+"] IFrame("+n+") not found"),i)&&D[n]&&D[n].warningTimeout&&(D[n].msgTimeout=setTimeout(function(){!D[n]||D[n].loaded||r||(r=!0,k(n,"IFrame has not responded within "+D[n].warningTimeout/1e3+" seconds. Check iFrameResizer.contentWindow.js has been loaded in iFrame. This message can be ignored if everything is working, or you can set the warningTimeout option to a higher value or zero to suppress this warning."))},D[n].warningTimeout))}function R(e){return e+":"+D[e].bodyMarginV1+":"+D[e].sizeWidth+":"+D[e].log+":"+D[e].interval+":"+D[e].enablePublicMethods+":"+D[e].autoResize+":"+D[e].bodyMargin+":"+D[e].heightCalculationMethod+":"+D[e].bodyBackgroun
1d+":"+D[e].bodyPadding+":"+D[e].tolerance+":"+D[e].inPageLinks+":"+D[e].resizeFrom+":"+D[e].widthCalculationMethod}function a(o,e){t=o.id,""===t&&(o.id=(a=e&&e.id||_.id+m++,null!==document.getElementById(a)&&(a+=m++),t=a),p=(e||{}).log,y(t,"Added missing iframe ID: "+t+" ("+o.src+")"));var t,n,i=t;if(i in D&&"iFrameResizer"in o)k(i,"Ignored iFrame, already setup.");else{var a=e;if(a=a||{},D[i]={firstRun:!0,iframe:o,remoteHost:o.src.split("/").slice(0,3).join("/")},"object"!=typeof a)throw new TypeError("Options is not an object");var r,s=a;for(r in _)_.hasOwnProperty(r)&&(D[i][r]=(s.hasOwnProperty(r)?s:_)[r]);switch(D[i]&&(D[i].targetOrigin=!0!==D[i].checkOrigin||""===(a=D[i].remoteHost)||"file://"===a?"*":a),y(i,"IFrame scrolling "+(D[i]&&D[i].scrolling?"enabled":"disabled")+" for "+i),o.style.overflow=!1===(D[i]&&D[i].scrolling)?"hidden":"auto",D[i]&&D[i].scrolling){case!0:o.scrolling="yes";break;case!1:o.scrolling="no";break;default:o.scrolling=D[i]?D[i].scrolling:"no"}c("Height"),c("Width"),l("maxHeight"),l("minHeight"),l("maxWidth"),l("minWidth"),"number"!=typeof(D[i]&&D[i].bodyMargin)&&"0"!==(D[i]&&D[i].bodyMargin)||(D[i].bodyMarginV1=D[i].bodyMargin,D[i].bodyMargin=D[i].bodyMargin+"px"),n=R(i),b(o,"load",function(){var e,t;F("iFrame.onload",n,o,d,!0),e=D[i]&&D[i].firstRun,t=D[i]&&D[i].heightCalculationMethod in w,!e&&t&&P({iframe:o,height:0,width:0,type:"init"})}),F("init",n,o,d,!0),Function.prototype.bind&&D[i]&&(D[i].iframe.iFrameResizer={close:C.bind(null,D[i].iframe),removeListeners:u.bind(null,D[i].iframe),resize:F.bind(null,"Window resize","resize",D[i].iframe),moveToAnchor:function(e){F("Move to anchor","moveToAnchor:"+e,D[i].iframe,i)},sendMessage:function(e){F("Send Message","message:"+(e=JSON.stringify(e)),D[i].iframe,i)}})}function l(e){1/0!==D[i][e]&&0!==D[i][e]&&(o.style[e]=D[i][e]+"px",y(i,"Set "+e+" = "+D[i][e]+"px"))}function c(e){if(D[i]["min"+e]>D[i]["max"+e])throw new Error("Value for min"+e+" can not be greater than max"+e)}}function r(e,t){null===i&&(i=setTimeout(function(){i=null,e()},t))}function s(e){y("window","Trigger event: "+e),r(function(){t("Window "+e,"resize")},16)}function l(){"hidden"!==document.visibilityState&&(y("document","Trigger event: Visiblity change"),r(function(){t("Tab Visable","resize")},16))}function t(e,t){for(var o in D)n=o,D[n]&&"parent"===D[n].resizeFrom&&D[n].autoResize&&!D[n].firstRun&&F(e,t,document.getElementById(o),o);var n}function e(){function n(e,t){if(t){if(!t.tagName)throw new TypeError("Object is not a valid DOM element");if("IFRAME"!==t.tagName.toUpperCase())throw new TypeError("Expected <IFRAME> tag, found <"+t.tagName+">");a(t,e),i.push(t)}}for(var i,e=["moz","webkit","o","ms"],t=0;t<e.length&&!h;t+=1)h=window[e[t]+"RequestAnimationFrame"];return h||y("setup","RequestAnimationFrame not supported"),b(window,"message",g),b(window,"resize",function(){s("resize")}),b(document,"visibilitychange",l),b(document,"-webkit-visibilitychange",l),b(window,"focusin",function(){s("focus")}),b(window,"focus",function(){s("focus")}),function(e,t){switch(i=[],(o=e)&&o.enablePublicMethods&&k("enablePublicMethods option has been removed, public methods are now always available in the iFrame"),typeof t){case"undefined":case"string":Array.prototype.forEach.call(document.querySelectorAll(t||"iframe"),n.bind(d,e));break;case"object":n(e,t);break;default:throw new TypeError("Unexpected data type ("+typeof t+")")}var o;return i}}function v(e){e.fn?e.fn.iFrameResize||(e.fn.iFrameResize=function(o){return this.filter("iframe").each(function(e,t){a(t,o)}).end()}):$("","Unable to bind to jQuery, it is not fully loaded.")}var m,p,c,A,M,O,L,h,w,D,i,_,z;"undefined"!=typeof window&&(m=0,c=p=!1,A="message".length,O=(M="[iFrameSizer]").length,L=null,h=window.requestAnimationFrame,_={autoResize:!(i=null),bodyBackground:null,bodyMargin:null,bodyMarginV1:8,bodyPadding:null,checkOrigin:!0,inPageLinks:!"Host Page",enablePublicMethods:!0,heightCalculationMethod:"bodyOffset",id:"iFrameResizer",interval:32,log:!(D={}),maxHeight:1/0,maxWidth:1/0,minHeight:0,minWidth:0,resizeFrom:"parent",scrolling:!(w={max:1,scroll:1,bodyScroll:1,documentElementScroll:1}),sizeHeight:!0,sizeWidth:!1,warningTimeout:5e3,tolerance:0,widthCalculationMethod:"scroll",closedCallback:function(){},initCallback:function(){},messageCallback:function(){k("MessageCallback function not defined")},resizedCallback:function(){},scrollCallback:function(){return!0}},z={},window.jQuery&&v(window.jQuery),"function"==typeof define&&define.amd?define([],e):"object"==typeof module&&"object"==typeof module.exports?module.exports=e():window.iFrameResize=window.iFrameResize||e())})(),(e=>({status:!1,conf:{url:RGPage.site_search_host_full+"/ajax/get_claim_form_authorization"},get:function(){let n=this;return n.status?new Promise((e,t)=>
1{(!0===n.status?e:t)()}):new Promise((t,o)=>{e.ajax({method:"GET",url:n.conf.url,dataType:"json",xhrFields:{withCredentials:!0},success:function(e){e.status?(n.status=!0,RGPage.claim_form_authorization_token=e.token,t()):o(e)},error:function(e){o(e)}})})}}))(jQuery)),ClaimRestaurantForm={conf:{restaurant_id:0,get_form_url:RGPage.site_search_host_full+"/ajax/get_claim_form",upload_image_url:"/ajax/menu_upload_image",submit_verification_method:RGPage.site_search_host_full+"/ajax/claim-request-code",submit_verification_code:RGPage.site_search_host_full+"/ajax/claim-send-verification-code",modal_form_id:"#modal-claim",form:"#menu_form_upload_claim",remove_image_btn:".remove-img",asterisk_email:""},all_verification_methods:{email:"email",email_domain:"email_domain",sms:"sms",call:"call",call_free:"call_free"},is_form_loaded:!1,form_content:!1,form_wrapper:'<div class="modal modal_filter show" id="modal-claim"><div class="wrapper_report"><div class="close_btn"></div><div class="title_block">'+_("claim_form_title_window")+'</div><div class="claim_wrapper"><div class="claim_text" style="height: 250px;"><img class="stub_loader" src="'+cdn_host+'/img/site/responsive/ajax-loader.gif" class="loader onLoad" /></div></div></div></div>',resumable:null,images:{},$modal:null,xhr:null,current_step:"step1",current_step2_stage:"request_code",timer:null,timer_end_date:null,admin_link:null,verification_methods:null,actions_inited:!1,need_reload:!1,init:function(e){$.extend(!0,this.conf,e),this.bindActions()},bindActions:function(){let t=this;$(document).on("click",".claim_business",function(e){return t.show(),!1}).on("click","#modal-claim .close_btn",function(e){return e.preventDefault(),t.hide(),!1}),t.$modal=$("#modal-claim")},hide:function(){$(this.conf.modal_form_id).hide(),"function"==typeof bodyUnfixPosition?bodyUnfixPosition():($("body").removeClass("noScroll"),$("html").removeClass("noScroll"))},show:function(e,t=0){var o=this;void 0!==e&&(o.conf.restaurant_id=e),$(o.conf.modal_form_id).length?$(o.conf.modal_form_id).show():$("body").append(this.form_wrapper),"function"==typeof bodyFixPosition?bodyFixPosition():($("body").addClass("noScroll"),$("html").addClass("noScroll")),!o.is_form_loaded||o.need_reload?o.getForm(t,function(){o.makeForm(),o.actions_inited||(o.initMenuUpload(),o.actions_inited=!0),o.need_reload&&o.setAvailableMethods()}):o.showForm()},getRandomDelay:(e,t)=>Math.floor(Math.random()*(t-e+1)),getForm:function(e,t){var o=this,n=this.conf.get_form_url,i=!!Object.hasOwn(RGPage,"hl")&&RGPage.hl;i&&(n+="?hl="+i),$.ajax({url:n,data:{restaurant_id:this.conf.restaurant_id,from_menu_upload:e},success:function(e){e.status&&(o.is_form_loaded=!0,o.need_reload=!1,o.form_content=e.html,t(),setTimeout(function(){claim_form_authorization.get().then().catch(e=>{console.error(e.toString())})},o.getRandomDelay(500,1500)))}})},makeForm:function(){$(this.conf.modal_form_id+" .claim_wrapper").html(this.form_content),"undefined"==typeof grecaptcha&&this.recaptchaInit()},showForm:function(){$(this.conf.modal_form_id+" .claim_wrapper").show()},activateTabStep:function(e){$(".steps li").removeClass("active"),$(".steps li.step_tab"+e).addClass("active"),$(".steps li.step_tab"+(e-1)).addClass("passed")},initMenuUpload:function(){for(var s=this,e=($(document).on("click",'.input_submit[type="button"]',function(e){"step1"==s.current_step&&(s.current_step,$(".menu_form_wrapper .step1").hide(),$(".menu_form_wrapper .step2").show(),s.activateTabStep("2"),s.hideNextButton())}),$(document).on("click",".send_code",function(e){var t=s.getActiveMethod(),o=(s.beforeSendCode(),$.isEmptyObject(s.images)?0:1);s.xhr=$.ajax({url:s.conf.submit_verification_code,headers:{Authorization:"Bearer "+RGPage.claim_form_authorization_token},dataType:"json",data:{restaurant_id:s.conf.restaurant_id,method:t,code:$(s.conf.modal_form_id+' input[name="pin_code"]').val(),has_menu:o},success:function(e){e.status?(s.afterSendCode(),s.admin_link=e.admin_link,o?s.processImages():s.showStep3()):(s.addWrongCode(),s.addBadCodeError(e.message))}}).always(function(){$("#skip_upload").is(":checked")&&s.removeButtonLoader(),$(s.conf.modal_form_id+' input[name="pin_code"]').removeClass("notActive")}
1)}),$(document).on("click",".email",function(){$("#email_domain").prop("checked",!0)}).on("click",".phone",function(){$("#call_free").prop("checked",!0)}).on("click",".cancel_option_btn",function(){var e=s.getActiveMethod(),e=s.verification_methods.indexOf(e),e=s.verification_methods[e+1];$(s.conf.modal_form_id+" .option_wrapper").addClass("hidden"),$(s.conf.modal_form_id+" .option_wrapper#"+e+"_method_wrapper").removeClass("hidden")}),$(this.conf.modal_form_id+' input[name="pin_code"]').mask("9999"),{onKeyPress:function(e,t,o,n){var e=s.isValidPhoneNumber(e),i=s.validateMessage();e&&!i?$(".send_code_option_btn").removeClass("notActive"):$(".send_code_option_btn").addClass("notActive")}}),t=($(this.conf.modal_form_id+' input[name="phone"]').mask("000000000000000",e),$(document).on("change","#skip_upload",function(){this.checked?($("#claim_upload_menu").addClass("disabled"),$("#messsage_wrapper").show(),$(".img_error").hide(),s.validateName()||s.validateEmail()||s.enableNextButton()):($("#claim_upload_menu").removeClass("disabled"),$("#messsage_wrapper").hide(),s.disableNextButton())}),$(document).on("click",".send_code_option_btn",function(){var e,t,o,n=s.getActiveMethod(),i=$(s.conf.modal_form_id+" .email").val(),a=$(s.conf.modal_form_id+" .phone").val(),r=$(s.conf.modal_form_id+" .name").val();(n!==s.all_verification_methods.email_domain||i.length)&&(e=$(s.conf.modal_form_id+" #report_email").val(),t=$(s.conf.modal_form_id+" #report_message").val(),o=$(s.conf.modal_form_id+" #email_notifications").prop("checked")?1:0,$(s.conf.modal_form_id+' input[name="pin_code"]').val(""),"call_free"!=n||e.length&&t.length&&a.length)&&(s.beforeRequestCode(),s.xhr=$.ajax({url:s.conf.submit_verification_method,headers:{Authorization:"Bearer "+RGPage.claim_form_authorization_token},dataType:"json",data:{restaurant_id:s.conf.restaurant_id,method:n,email:i,phone:a,name:r,report_email:e,report_message:t,email_notifications:o},success:function(e){e.status?s.afterRequestCode(e.timeout):s.setStepError(e)}}).always(function(){s.removeButtonLoaderOptionBtn()}))}),$(document).on("click",".back_button",function(){var e=s.getActiveMethod(),e=s.verification_methods.indexOf(e);e<=0?s.showStep1():(e=s.verification_methods[e-1],$(s.conf.modal_form_id+" .option_wrapper").addClass("hidden"),$(s.conf.modal_form_id+" .option_wrapper#"+e+"_method_wrapper").removeClass("hidden"))}
1),$(document).on("focus","#report_name",function(){var e=$(".text-error.for-name");0<e.length&&e.remove()}),$(document).on("blur","#report_name",function(){s.validateName(),s.validateName()||s.validateEmail()||!$("#skip_upload").is(":checked")&&$.isEmptyObject(ClaimRestaurantForm.images)?s.disableNextButton():s.enableNextButton()}),$(document).on("focus","#report_email",function(){var e=$(".text-error.for-email");0<e.length&&e.remove()}),$(document).on("blur","#report_email",function(){s.validateEmail()||s.validateName()||!$("#skip_upload").is(":checked")&&$.isEmptyObject(ClaimRestaurantForm.images)?s.disableNextButton():s.enableNextButton()}),$(document).on("focus","#report_message",function(){var e=$(".text-error.for-message");0<e.length&&e.remove()}),$(document).on("blur","#report_message",function(){s.validateMessage(),!s.validateMessage()&&s.isValidPhoneNumber($(s.conf.modal_form_id+' input[name="phone"]').val())?$(".send_code_option_btn").removeClass("notActive"):$(".send_code_option_btn").addClass("notActive")}),$(document).on("change",".verify_method_input",function(){console.log('.option_wrapper input[name="verification_method"]'),$(s.conf.modal_form_id+" #"+s.getActiveMethod()+"_method_wrapper .send_code_option_btn").removeClass("notActive"),$(s.conf.modal_form_id+" #"+s.getActiveMethod()+"_method_wrapper .cancel_option_btn").removeClass("notActive")}),$(".hidden_input").focus(function(){$(this).closest(".verification_methods").addClass("focus")}),$(".hidden_input").blur(function(){$(this).closest(".verification_methods").removeClass("focus")}),$(".hidden_input.email")),o=[],n=0;t.length>n;n++)o[n]=document.createElement("div"),o[n].className="buffer",t[n].parentNode.insertBefore(o[n],t[n].nextSibling),t[n].oninput=function(){this.nextElementSibling.innerHTML=this.value,this.style.width=this.nextElementSibling.clientWidth+4+"px"};s.isAdvancedUpload()?$(".form_elmnt.upload").on("drag dragstart dragend dragover dragenter dragleave drop",function(e){e.preventDefault(),e.stopPropagation()}).on("dragover dragenter",function(){$(this).addClass("is-dragover")}).on("dragleave dragend drop",function(){$(this).removeClass("is-dragover")}).on("drop",function(e){var t=$(this).hasClass("delivery");$(e.originalEvent.dataTransfer.files).each(function(){this.is_delivery=t}),s.resumable.addFiles(e.originalEvent.dataTransfer.files)}):($(s.conf.form).find("img.icon").hide(),$(s.conf.form).find(".sub_title").hide()),this.resumable=new Resumable({target:this.conf.upload_image_url,fileType:["image/png","image/jpg","image/jpeg","pdf"],maxFiles:20,simultaneousUploads:1,maxFileSize:20971520,uploadMethod:"POST",testMethod:"POST",testChunks:!1}),this.resumable.assignBrowse($('[name="file[]"]',s.conf.form)),this.resumable.on("fileProgress",function(e){s.progressFile(e)}),this.resumable.on("complete",function(){s.showStep3()}),this.resumable.on("fileAdded",function(e,t){s.renderImagePreview(e.file);var e=$(".loadMenu_box"),o=e.find("#skip_upload");o.is(":checked")&&o.removeAttr("checked"),e.hasClass("notActive")||e.addClass("notActive"),s.validateEmail()||s.validateName()||s.enableNextButton()}),this.setAvailableMethods()},isValidPhoneNumber:function(e){return 8<=e.length&&e.length<=15},addBadCodeError:function(e){var t=$(this.conf.modal_form_id+' input[name="pin_code"]');t.after('<span class="text-error for-code">'+e+"</span>"),$(".for-code").css({top:t.position().top+t.outerHeight()+2})},removeBadCodeError:function(){0<$(".text-error.for-code").length&&$(".text-error.for-code").remove()},beforeSendCode:function(){this.removeWrongCode(),this.addButtonLoader(),this.removeBadCodeError(),$(this.conf.modal_form_id+' input[name="pin_code"]').addClass("notActive")},afterSendCode:function(){this.timer&&clearInterval(this.timer),this.timer_end_date=null,$(this.conf.modal_form_id+' input[name="pin_code"]').removeClass("notActive")},afterRequestCode:function(e){this.showSendCodeFields(),this.removeButtonLoader(),$(this.conf.modal_form_id+" #"+this.getActiveMethod()+"_method_wrapper .send_code_option_btn").addClass("notActive"),$(this.conf.modal_form_id+" #"+this.getActiveMethod()+"_method_wrapper .cancel_option_btn").addClass("notActive"),$(this.conf.modal_form_id+" #"+this.getActiveMethod()+"_method_wrapper label").addClass("notActive"),this.runTimer(e)},beforeRequestCode:function(){this.addButtonLoader(),this.addButtonLoaderOptionBtn(),this.removeStepError(),$(this.conf.modal_form_id+" #"+this.getActiveMethod()+"_method_wrapper .send_code_option_btn").addClass("notActive"),$(this.conf.modal_form_id+" #"+this.getActiveMethod()+"_method_wrapper .cancel_option_btn").addClass("notActive")},showSendCodeFields:function(){$(this.conf.modal_form_id+" .enter_code_wrapper").show(),$(this.conf.modal_form_id+' input[name="pin_code"]').focus()},hideSendCodeFields:function(){$(this.conf.modal_form_id+" .enter_code_wrapper").hide()},setAvailableMethods:function(){var e=[];0<$("#email_method_wrapper").length&&e.push("email"),0<$("#email_domain_method_wrapper").length&&e.push(this.all_verification_methods.email_domain),0<$("#sms_method_wrapper").length&&e.push(this.all_verification_methods.sms),0<$("#call_method_wrapper").length&&e.push(this.all_verification_methods.call),0<$("#call_free_method_wrapper").length&&e.push(this.all_verification_methods.call_free),this.verification_methods=e},getActiveMethod:function(){return 0<$("#email_method_wrapper").not(".hidden").length?this.all_verification_methods.email:0<$("#email_domain_method_wrapper").not(".hidden").length?this.all_verification_methods.email_domain:0<$("#sms_method_wrapper").not(".hidden").length?this.all_verification_methods.sms:0<$("#call_method_wrapper").not(".hidden").length?this.all_verification_methods.call:0<$("#call_free_method_wrapper").not(".hidden").length&&this.all_verification_methods.call_free},showStep3:function(){var e=this;e.removeButtonLoader(),e.activateTabStep(3),$(".menu_form_wrapper .step2").hide(),$(".menu_form_wrapper .step3").show(),e.blockVerificationForm(),e.admin_link?$("#admin_link").attr("href",e.admin_link):($(".email_later").show(),$(".admin_wrapper").hide())},showStep1:function(){this.activateTabStep(1),$(".menu_form_wrapper .step2").hide(),$(".menu_form_wrapper .step1").show(),this.showNextButton()},addWrongCode:function(){$(this.conf.modal_form_id+' input[name="pin_code"]').addClass("wrongNumber")},removeWrongCode:function(){$(this.conf.modal_form_id+' input[name="pin_code"]').removeClass("wrongNumber")},getVerificationMethod:function(){return $("input[name=verification_method]:checked","#menu_form_upload_claim").val()},runTimer:function(e){let o=this;o.timer_end_date=new Date,o.timer_end_date.setSeconds(o.timer_end_date.getSeconds()+e),$(o.conf.modal_form_id+" .code_counter").show(),$(o.conf.modal_form_id+" .seconds_left").html(e),$(o.conf.modal_form_id+" .back_button").addClass("notActive"),o.timer=setInterval(function(){var e=(new Date).getTime(),t=o.timer_end_date.getTime()-e;o.timer_end_date.getTime()-e<=0?(o.hideSendCodeFields(),$(o.conf.modal_form_id+" #"+o.getActiveMethod()+"_method_wrapper .send_code_option_btn").removeClass("notActive"),$(o.conf.modal_form_id+" #"+o.getActiveMethod()+"_method_wrapper .cancel_option_btn").removeClass("notActive"),$(o.conf.modal_form_id+" #"+o.getActiveMethod()+"_method_wrapper label").removeClass("notActive"),$(o.conf.modal_form_id+" .code_counter").hide(),$(o.conf.modal_form_id+' input[name="pin_code"]').removeClass("notActive"),$(o.conf.modal_form_id+" .back_button").removeClass("notActive"),o.timer_end_date=null,clearInterval(o.timer)):$(o.conf.modal_form_id+" .seconds_left").html(Math.floor(t/1e3))},1e3)},addButtonLoader:function(){$(this.conf.modal_form_id+" .send_code").addClass("loaderActive")},removeButtonLoader:function(){$(this.conf.modal_form_id+" .send_code").removeClass("loaderActive")},addButtonLoaderOptionBtn:function(){$(this.conf.modal_form_id+" .send_code_option_btn").addClass("loaderActive")},removeButtonLoaderOptionBtn:function(){$(this.conf.modal_form_id+" .send_code_option_btn").removeClass("loaderActive")},blockVerificationForm:function(){var e=this;$(e.conf.modal_form_id+" label.verification_methods").removeClass("notActive"),$(e.conf.modal_form_id+" .code_counter").hide(),$(e.conf.modal_form_id+" #"+e.getActiveMethod()+"_method_wrapper .send_code_option_btn").addClass("notActive"),$(e.conf.modal_form_id+" #"+e.getActiveMethod()+"_method_wrapper .cancel_option_btn").addClass("notActive"),e.current_step2_stage="request_code"},activateVerificationForm:function(e){var t=this;t.current_step2_stage="send_code",$(t.conf.modal_form_id+" .code_counter").show(),$(t.conf.modal_form_id+" .seconds_left").html(e),$(t.conf.modal_form_id+' label.verification_methods[for!="'+t.getVerificationMethod()+'"]').addClass("notActive"),$(t.conf.modal_form_id+" #"+t.getActiveMethod()+"_method_wrapper .send_code_option_btn").addClass("notActive"),$(t.conf.modal_form_id+" #"+t.getActiveMethod()+"_method_wrapper .cancel_option_btn").addClass("notActive"),$(t.conf.modal_form_id+" .send_code").removeClass("notActive"),t.runTimer(e)},enableNextButton:function(){$("#next_button").removeClass("notActive")},disableNextButton:function(){$("#next_button").addClass("notActive")},hideNextButton:function(){$("#next_button").hide()},showNextButton:function(){$("#next_button").show()},isAdvancedUpload:function(){var e=document.createElement("div");return("draggable"in e||"ondragstart"in e&&"ondrop"in e)&&"FormData"in window&&"FileReader"in window},renderImagePreview:function(e){var t,o,n,i,a=this,r=e.name,s=r.substring(r.lastIndexOf(".")+1).toLowerCase(),r=$(".mdl-wrap-images",this.conf.modal_form_id);return $(".comments_file_error",a.conf.modal_form_id).hide(),10<a.images.length?($(".comments_file_error",a.conf.modal_form_id).html(_("error_photo_count")).show(),!1):"png"!=s&&"jpg"!=s&&"jpeg"!=s&&"pdf"!=s?($
1(".comments_file_error",a.conf.modal_form_id).html(_("error_photo_type")).show(),!1):"undefined"==typeof FileReader?($(".comments_file_error",a.conf.modal_form_id).html(_("error_photo_browser")).show(),!1):void(e.size>1024*("pdf"===s?20:6)*1024?$(".comments_file_error",a.conf.modal_form_id).html(_("error_photo_size")).show():(t=new FileReader,(o=$("<div>",{class:"img-content upload_wrapper"})).data("iter",e.name),(n=$("<img />")).appendTo(o),(i=$("<span>",{class:"delete remove-img n0"})).appendTo(o),$("<div>").addClass("progress_wrapper "+e.uniqueIdentifier).html('<div class="line_wrapper"><div class="line" style="width: 0;"></div></div><div class="btn_info"></div>').hide().appendTo(o),i.click(function(e){a.removeImage(e),Object.keys(ClaimRestaurantForm.images).length||(a.disableNextButton(),$(".loadMenu_box ").hasClass("notActive")&&$(".loadMenu_box ").removeClass("notActive"))}),o.appendTo(r),t.onload=function(e){var t,o=n;"pdf"===s?(t="data:image/svg+xml,%3C%3Fxml version='1.0' standalone='no'%3F%3E%3C!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 20010904//EN' 'http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd'%3E%3Csvg version='1.0' xmlns='http://www.w3.org/2000/svg' width='512.000000pt' height='512.000000pt' viewBox='0 0 512.000000 512.000000' preserveAspectRatio='xMidYMid meet'%3E%3Cg transform='translate(0.000000,512.000000) scale(0.100000,-0.100000)'%0Afill='%23ed1c24' stroke='none'%3E%3Cpath d='M1201 5044 c-179 -48 -330 -202 -397 -404 -18 -52 -19 -120 -22%0A-1207 l-3 -1153 -134 0 -135 0 0 -750 0 -750 134 0 133 0 6 -122 c3 -69 13%0A-147 22 -178 60 -197 218 -357 400 -405 52 -13 238 -15 1495 -15 1584 0 1472%0A-4 1605 63 77 38 190 152 233 234 18 34 41 96 52 139 20 75 20 117 20 1741 0%0A970 -4 1671 -9 1681 -5 9 -266 270 -579 580 l-571 562 -1098 -1 c-926 0 -1106%0A-3 -1152 -15z m2001 -481 c4 -316 4 -318 32 -398 57 -166 162 -288 312 -363%0A116 -58 147 -62 533 -62 l351 0 0 -1574 c0 -1541 0 -1575 -20 -1638 -36 -118%0A-130 -218 -250 -265 -42 -17 -130 -18 -1420 -21 -870 -2 -1399 1 -1439 7 -85%0A13 -161 53 -220 116 -85 89 -121 189 -121 332 l0 82 988 3 c924 3 990 5 1042%0A22 113 37 192 86 280 175 71 71 94 102 132 181 70 141 82 199 83 370 0 122 -4%0A158 -23 224 -60 207 -197 379 -369 462 -135 65 -107 64 -1170 64 l-963 0 0%0A1104 c0 699 4 1123 10 1156 31 165 165 304 317 330 26 4 467 8 979 9 l932 1 4%0A-317z m933 -442 l200 -201 -245 0 c-288 1 -372 10 -454 48 -128 60 -223 186%0A-245 322 -6 36 -11 179 -11 319 l0 253 278 -270 c152 -149 367 -361 477 -471z%0Am-2670 -2252 c30 -15 62 -42 80 -68 25 -36 30 -54 33 -115 5 -86 -15 -136 -73%0A-184 -51 -42 -96 -52 -229 -52 l-116 0 0 -145 0 -145 -60 0 -60 0 0 371 0 371%0A188 -4 c178 -3 190 -4 237 -29z m635 14 c69 -22 150 -96 179 -162 28 -65 38%0A-203 22 -297 -20 -112 -79 -192 -176 -236 -44 -20 -70 -23 -212 -26 l-163 -4%0A0 371 0 371 149 0 c112 0 161 -4 201 -17z m860 -28 l0 -45 -180 0 -180 0 0%0A-120 0 -120 150 0 150 0 0 -45 0 -45 -150 0 -150 0 0 -160 0 -160 -60 0 -60 0%0A0 370 0 370 240 0 240 0 0 -45z'/%3E%3Cpath d='M1160 1675 l0 -135 110 0 c127 0 159 11 184 64 33 70 13 150 -47 186%0A-26 17 -51 20 -139 20 l-108 0 0 -135z'/%3E%3Cpath d='M1860 1530 l0 -280 88 0 c103 0 156 20 194 71 39 52 48 93 48 209 0%0A212 -58 279 -242 280 l-88 0 0 -280z'/%3E%3C/g%3E%3C/svg%3E",n.css("object-fit","contain"),$(".comments_file_error",a.conf.modal_form_id).html("PDF files will be processed later (offline)").show()):t=e.target.result,o.attr("src",t)},r.show(),t.readAsDataURL(e),a.images[e.name]=e))},removeImage:function(e){var t=$(e.currentTarget),o=this;return e.preventDefault(),void 0===t.data("image-id")&&($(o.conf.form).find('[name="file[]"]').val(""),e=t.closest(".img-content"),o.resumable.removeFile(o.resumable.getFromUniqueIdentifier(o.images[e.data("iter")].uniqueIdentifier)),delete o.images[e.data("iter")],e.remove()),!1},processImages:function(){this.addButtonLoader(),this.resumable.opts.query={csrf_token:this.conf.csrf_token,restaurant_id:this.conf.restaurant_id,from_owner:1},null!=window.json_arr.upload_menu_source&&(this.resumable.opts.query.source=window.json_arr.upload_menu_source),this.resumable.upload()}
1,validateForm:function(){var e=$("#menu_form_upload_claim"),t=$.trim(e.find("[name=name]").val()),o=$.trim(e.find("[name=email]").val()),n=$.trim(e.find("[name=message]").val()),i=!1,a=!1,r=!1,s={};if($(".name_error",this.$modal).hide(),$(".email_error",this.$modal).hide(),$(".msg_error",this.$modal).hide(),t||(this.addErrorToField(e.find("[name=name]")),s[_("%s is empty").replace("%s",_("name"))]=!0,i=_("%s is empty").replace("%s",_("name"))),o?/.+@.+\..+/i.test(o)||(this.addErrorToField(e.find("[name=email]")),s[_("feedback_email_notvalid")]=!0,a=_("feedback_email_notvalid")):(this.addErrorToField(e.find("[name=email]")),s[_("%s is empty").replace("%s",_("email"))]=!0,a=_("%s is empty").replace("%s",_("email"))),$("#skip_upload").is(":checked")&&!n&&(this.addErrorToField(e.find("[name=message]")),s[_("%s is empty").replace("%s",_("message"))]=!0,r=_("%s is empty").replace("%s",_("message"))),!$("#skip_upload").is(":checked")&&$.isEmptyObject(this.images)&&($(".img_error").show(),s[$(".img_error").html()]=!0),!$.isEmptyObject(s)){var l,c="";for(l in s)c+=l+"<br>";return c=c.substring(0,c.length-4),i&&$("#modal-claim .name_error").html(i).show(),a&&$("#modal-claim .email_error").html(a).show(),r&&$("#modal-claim .msg_error").html(r).show(),!1}$(".claim_error",this.$modal).html("");return!0},addErrorToField:function(e){e.addClass("error").keyup(function(){e.removeClass("error").unbind("keyup"),$(this).siblings(".report_error").remove()})},progressFile:function(e){var t=$("."+e.uniqueIdentifier),o=(t.show(),t.find(".line")),e=100*e.progress();0<o.length&&o.css("width",e+"%"),100==e&&(t.find(".btn_info").addClass("done"),o.parent().hide())},recaptchaInit:function(){window.renderClaimRecaptcha=this.renderRecaptcha,$.getScript("//www.google.com/recaptcha/api.js?hl=en&render=explicit&onload=renderClaimRecaptcha")},renderRecaptcha:function(){$("#claimrecaptcha").each(function(){grecaptcha.render($(this).attr("id"),{sitekey:recaptcha_sitekey,callback:function(){$(".srv_error").html("")}})})},validateName:function(){$(".text-error.for-name").remove();var e=$("#report_name"),t=e.val().length<=2;return t&&e.after('<span class="text-error for-name">'+_("review_username_too_short")+"</span>"),$("#report_name").toggleClass("error",t),t}
1,validateEmail:function(){var e=$("#report_email");let t=!e.val();var o=$(".text-error.for-email");return t&&!o.length?e.after('<span class="text-error for-email">'+_("feedback_email_empty")+"</span>"):(this.conf.asterisk_email?e.val()===this.conf.asterisk_email:/^([a-zA-Z0-9_.-])+@([a-zA-Z0-9_.-])+\.([a-zA-Z])+([a-zA-Z])+/.test(e.val()))||(t=!0,o.length&&o.remove(),e.after('<span class="text-error for-email">'+_("feedback_email_notvalid")+"</span>")),$("#report_email").toggleClass("error",t),t},validateMessage:function(){$(".text-error.for-message").remove();var e=$("#report_message"),t=e.val().length<=5;return t?e.after('<span class="text-error for-message">'+_("too_short_text_message")+"</span>"):1024<e.val().length&&e.after('<span class="text-error for-message">'+_("too_long_text_message")+"</span>"),$("#report_message").toggleClass("error",t),t},setStepError:function(e){var t=$(this.conf.modal_form_id+" #"+this.getActiveMethod()+"_method_wrapper");t.find(".verification_methods").after(`<span class="report_error msg ">${e.message}</span>`),t.find(".send_code_option_btn").addClass("notActive")}
1,removeStepError:function(){var e=$(this.conf.modal_form_id+" #"+this.getActiveMethod()+"_method_wrapper");e.find(".report_error").remove(),e.find(".send_code_option_btn").removeClass("notActive")}},TEST=null,get_visible_map_selector=()=>$("body").hasClass("merged_template")?$(".left_column_wrapper .wrapper_map").is(":visible")?"#map_block_top":"#map_block_right":"#map_block";let restaurants_counters={counters:{menu:9340,phone:9903,gallery:10160},restaurants_new_design_splittest_counters:{split_group:{menu:10154,phone:10156,gallery:10158},control_group:{menu:10155,phone:10157,gallery:10159}},getByAction:function(e){return RGPage.hasOwnProperty("restaurants_new_design_splittest_group")&&this.restaurants_new_design_splittest_counters.hasOwnProperty(RGPage.restaurants_new_design_splittest_group)?[this.counters[e],this.restaurants_new_design_splittest_counters[RGPage.restaurants_new_design_splittest_group][e]]:this.counters[e]}};function openReviewForm(e){var t=$("#comment_form_modal");t.show(),$("body").addClass("modal-open"),bodyFixPosition(),t.find(".review_form > .error_msg").html(""),$(".form_elmnt > input,textarea",t).removeClass("error"),$(".add_review_block",t).addClass("only_photo"),$(".non_photo",t).show(),$(".comment_title_photo",t).hide(),$(".comment_title_common",t).show(),is_mobile()&&t.find(".sub_title").hide()}$(document).ready(function(){$(document).on("click","a.whatsapp_btn",function(){logH(9884)}),"undefined"!=typeof restaurant_promo_code&&restaurant_promo_code&&($(".a_button_wrap.menu").click(e=>{logPH(restaurant_id,"menu_clicks")}),$('.orderBtn:not([data-is-list="1"]), .order_wrapper .order_item').click(e=>{logPH(restaurant_id,"delivery_clicks")}),$(".a_button_wrap .call").click(e=>{logPH(restaurant_id,"phone_clicks")}),$(".a_button_wrap_63").click(e=>{logPH(restaurant_id,"reservation_clicks")})),userScale(),showHideSchedule();var e,t,o="click",n=($(".swiper-slide").on("click",".swiper-slide",function(e){return $("body").hasClass("menu_page")&&openGalleryPopUp($(this).data("index")),!1}),$(".photo-link").on(o,function(){var e,t;return $("body").hasClass("menu_page")?openGalleryPopUp($(this).data("index")):(e=!$(this).find(".all_photos").is(":visible"),t=e?$(this).data("index"):0,setTimeout(function(){Gallery.openGallery(t,e)},100)),!1}),(0<$(".swiper-slide").length||0<$(".photo-link").length)&&Gallery.init(),$(document).on("click",".add_photo.total_photo",function(){var e;Gallery.setActiveTab(0),isCollage()?(e=$(".swiper-slide").first(),$(e).hasClass("collageWrapper")&&(e=Gallery.getCollageCoords($(e)),Gallery.setCurrentCollagePhoto(e[0])),Gallery.openGallery(0,!1)):Gallery.openGallery(0)}),$("a.call").on(o,function(){null!=ga&&ga("send","event","Phone","call"),logH(restaurants_counters.getByAction("phone")),rest_header_btns.incPhoneCounter()}),$(".a_button_wrap_63").on(o,function(){rest_header_btns.incReserveCounter()}),$(".schedule_short_info").on(o,function(){let e=0;$("#android_info").length&&(e=window_match_media(740,"max")?64:0),scrollToElement(".work_time",300,$("header").outerHeight()+e,function(){$("body").hasClass("as-ds")&&($(".work_time").addClass("work_time__open work_time__open--animation"),setTimeout(function(){$(".work_time").removeClass("work_time__open--animation")},2100))})}),$("body").hasClass("wide")||0<$(".photo-menu-link").length&&($(document).on(o,".photo-menu-link",function(){return openGalleryMenu($(this).data("index")),!1}
1),$(".menu_see_all").click(function(){var e=$("#menu");if(!e.hasClass("loaded")){var t='<img data-src="{{src_lazy}}" src="'+cdn_host+'/log.gif" alt="{{title}}" title="{{title}}" class="photo-menu-link lazyload" data-index="{{i}}">';Mustache.parse(t);for(var o=3;o<window.json_arr.menu_photos.length;o++)e.append(Mustache.render(t,window.json_arr.menu_photos[o]));e.addClass("loaded"),$(this).hide(),lazyload.update()}return!1})),lazyLoadAds.init(),$(document).on(o,".expand_btn",function(){return closeMap(get_visible_map_selector()),!1}),location.hash),i=$(".claim_business"),i=(0<i.length&&(ClaimRestaurantForm.init({restaurant_id:i.data("id")}),-1!=n.search(/^#claim/))&&(null==(e=getUrlParameter(n,"id"))&&(e=i.data("id")),ClaimRestaurantForm.show(e)),ReportProblem.init(),-1!=n.search(/^#report/)&&ReportProblem.makeReportProblemModal(getUrlParameter(n,"object_id"),getUrlParameter(n,"object_type")),0<$("#report_inaccuracy__btn").length&&-1!=n.search(/^#innaccuracy/)&&ReportProblem.makeReportProblemModal(RGPage.restaurant_id,"restaurant"),$("#myLocSelect").on(o,function(){return 0!=geo_locate.user_latitude&&0!=geo_locate.user_longitude&&map.setCenter({lat:geo_locate.user_latitude,lng:geo_locate.user_longitude}),!1}),$(document).keyup(function(e){27===e.keyCode&&("block"==$("#photo-gallery").css("display")&&closeGallery(),"block"==$("#gallery_modal").css("display")&&Gallery.closeGallery(),"block"==$("#menu-gallery").css("display")&&closeGalleryMenu(),"block"==$(get_visible_map_selector()).css("display")&&closeMap(get_visible_map_selector()),"block"==$(".review_overlay").css("display")&&closeReviewForm(),"block"==$("#modal-problem-report").css("display")&&ReportProblem.closeReportModal(),"block"==$("#modal-claim").css("display"))&&ClaimRestaurantForm.hide()}),$(".user-image").bind("error",function(e){var t=$(e.target).parents("div:first").data("score"),o=cdn_host+"/img/site/new/negative.svg";0==t||3==t?o=cdn_host+"/img/site/new/neitral.svg":3<t&&(o=cdn_host+"/img/site/new/positive.svg"),$(e.target).prop("src",o)}),$(".map-img").bind("error",function(e){$(e.target).remove()}),$(".photo-link img")),a=(i.bind("error",function(e){$(e.target).parents(".photo-link:first").remove()}),i.bind("load",function(){$(this).addClass("loaded")}),get_visible_map_selector()+"+.modal_map"),r=($("#map_wrapper a").on("touchstart click",function(){return $(document.body).css({overflow:"hidden",height:"100%"}),$(a).show(),$("#info_location_modal").css("height",$(a+" .map_block").height()),google.maps.event.trigger(window.map,"resize"),window.map.setCenter(window._location),!1}),$(a+" .close_btn").on("touchstart click",function(e){return e.preventDefault(),$(a+" .restaurant_block").hide(),!1}),setTimeout(function(){loadReviewAuthors(),renderBannerLeft("&type=restaurant")},1),waitByCssLoad(function(){addFade(),"function"==typeof firstTextGroupEl&&firstTextGroupEl()}),$(".show-tags").on(o,function(){return $(this).hasClass("shown")?($(this).removeClass("shown"),$(".tags").css("max-height","")):($(this).addClass("shown"),$(".tags").css("max-height","none")),!1}),$(".add_review_action, .add_photo_action").on(o,function(e){$(e.target).hasClass("add_photo")||$(e.target).hasClass("add_photo_link")||$(e.target).hasClass("add_photo_action");comment_form_modal.show(),e.preventDefault()}),$(document).on("change",".non_photo>textarea",function(){0<$(this).val().length?$(this).closest(".add_review_block").removeClass("only_photo"):$(this).closest(".add_review_block").addClass("only_photo")}),$(document).on("scroll",function(){document.documentElement.style.setProperty("--scroll-y",window.scrollY+"px")}),"#add_photo"==location.hash&&$(".add_photo").trigger(o),"#add_review"==location.hash&&$(".add_review_btn").trigger(o),$("body").hasClass("mobile_compact"),$(".order_list a.order_item, .order_wrapper a.orderBtn ").on("click",function(e){var t=$(this).attr("href");t.match(/link\/rol\d+/)&&$.ajax({type:"POST",url:"/ajax/logOrderlink",data:{url:t,path:document.location.pathname}})}),!1),s=($(".more_ranks_load").on("click",function(e){return r||$(".more_ranks_load").hasClass("more_ranks_loaded")||(r=!0,$.ajax({type:"GET",url:"/"+RGPage.restaurant_slug+"/load-ranks",data:{},dataType:"json",success:function(e){var t=$("#ranks");t.height();$(".more_ranks_load").addClass("more_ranks_show").addClass("more_ranks_loaded"),$("#ranks > div").hide(),t.append(e.html),$(".more_ranks_show").on("click",function(e){return $("#ranks").removeClass("ranks").addClass("ranks_all"),$("#ranks > div:not(.distance_r_m)").show(),$(".r_prime").hide(),window_match_media(800,"max")?$(".more_ranks_hide").css("display","inline"):$(".more_ranks_hide").show(),$(".more_ranks_show").hide(),!1}),$(".more_ranks_hide").on("click",function(e){return $("#ranks").removeClass("ranks_all").addClass("ranks"),$("#ranks > div:not(.distance_r_m)").hide(),$(".r_prime").css("display",""),$(".more_ranks_hide").hide(),$(".more_ranks_show").css("display",""),!1}),$(".more_ranks_show").hide(),$("#ranks").removeClass("ranks").addClass("ranks_all")}})),!1}),"#wishlist_add"==location.hash&&($(".btn_like").trigger("click"),replaceHash("")),$(".show_restaurants_review").on("click",function(e){return toggleInformation($(".wrapper_description"),$(this)),!1}),$(".open-map").on(o,function(){return restMap.open($(get_visible_map_selector()+"+.modal_map")),!1}),"#modal_map"===location.hash&&(t=setInterval(function(){restMap.open($(get_visible_map_selector()+"+.modal_map")),clearInterval(t)},100)),$(".order_wrapper")),l=(s.length&&($(".order_wrapper:not(.soloItem) .orderBtn").on("click",function(e){var t=$(this).parent(),o=$(".order_list");window_match_media(740,"max")&&(t.hasClass("shownList")||o.slide
1Up(),o.slideToggle()),t.toggleClass("shownList")}),$(".order_wrapper a").on("click",function(e){var e=$(e.target),e=(logH(7982),e.data("otype")),t={doordash:7983,postmates:7984,grubhub:7985,ubereats:7986,seamless:7987};e in t&&logH(t[e])}),$(document).on("click",function(e){var e=$(e.target),t=$(".order_list");!e.parents(".order_wrapper").length&&s.hasClass("shownList")&&(window_match_media(740)&&t.slideUp(),s.removeClass("shownList"))})),$('a[data-btn="book"]').click(function(){logH(9214)}),$('a[data-btn="menu"]').click(function(){logH(restaurants_counters.getByAction("menu"))}),$(".similar-for-closed a.item").click(function(){logH(9595)}),0===$(".map_block").length||"undefined"!=typeof has_static_map&&has_static_map||setTimeout(function(){initRestaurantSmallMap(get_visible_map_selector())},1),shareRestaurant.init(),$(".expert_block.short"));if(0<l.length&&($("#expert_hide, .more_link").click(function(){l.removeClass("short"),$(".see_all.ajax.show_expert_block").addClass("shown"),$("#expert_hide").hide(),$("#expert_show").show()}),$("#expert_show").click(function(){l.addClass("short"),$(".see_all.ajax.show_expert_block").removeClass("shown"),$("#expert_show").hide(),$("#expert_hide").show()})),translateText.init(),isVietLang(),MenuPopup.init(),0<$(".comments__container:has(.link_reply)").length){let e=$(".comments__container:has(.link_reply)")[0],t=!1;function c(){$(e).offset().top<$(window).scrollTop()+$(window).height()&&!t&&(t=!0,comment_form_modal.show({style:"display: none;",only_load:!0}))}c(),t||$(document).scroll(function(){c()})}rest_header_btns.init(),setTimeout(rateTapScroll,500)}),$(window).load(function(){var e;-1!==location.hash.search("&gid=")?(e=location.hash.match(/pid=(\d+)/)[1],Gallery.openGalleryFromHash(e-1)):-1!==location.hash.search("gallery")&&(0==Gallery.items.length?Gallery.loadGalleryItems(function(){Gallery.openGalleryFromHash(0)}):Gallery.isActive()||Gallery.openGalleryFromHash(0)),$(".order_wrapper").length&&"#order_online"==location.hash&&(scrollToElement(".order_wrapper",500),$(".order_wrapper:not(.soloItem) .orderBtn").trigger("click"),replaceHash("")),0<$("body.ads_prohibited").length&&lazyload.update(),hideEmptyNavbar(),setTimeout(scrollToCommentFromAmp,100),changeEmptyAvatar(),setTimeout(iframeEventsFixer,300),setTimeout(hoverSwiper(),300),rest_types.init()}),$(document).ready(function(){setTimeout(iframeEventsFixer,300),setTimeout(adaptiveSlideSwiper,300)}),$(window).resize(function(){adaptiveSlideSwiper()}),document.addEventListener("DOMContentLoaded",function(e){cuisines_lists.init(),StickyMenuNav.init({photo_id:".photo-menu-link"})});var lazyLoadAds={$items:null,items:".async-google-ads",init:function(){lazyLoadAds.$items=$(lazyLoadAds.items),lazyLoadAds.showLazyAds(),$(document).on("scroll",function(){lazyLoadAds.showLazyAds()})},update:function(){lazyLoadAds.$items=$(lazyLoadAds.items),lazyLoadAds.showLazyAds()}
1,showLazyAds:function(){var e=$(window).height();lazyLoadAds.renderIfVisible(lazyLoadAds.$items,0,e,"top","bottom")},renderIfVisible:function(e,t,o,n,i){for(var a=0;a<e.length;a++)lazyLoadAds.isVisible(e[a],t,o,n,i)&&e[a].classList.contains("async-google-ads")&&($(e[a]).append($("<ins>").addClass("adsbygoogle").css("display","block").attr({"data-ad-client":$(e[a]).data("ad_client"),"data-ad-slot":$(e[a]).data("ad_slot"),"data-ad-format":"auto"})),e[a].classList.remove("async-google-ads"),(adsbygoogle=window.adsbygoogle||[]).push({}),lazyLoadAds.update())},isVisible:function(e,t,o,n,i){e=e.getBoundingClientRect(),n=e[n]>=t&&e[n]<=o,o=e[i]<=o&&e[i]>=t;return n||o}},restMap={is_first:1,map_data:{},is_full_map_loaded:!1,is_on_load:!1,big_map_wrapper:'<div class="modal_map modal_map_id" style="display: none;">\n  <div class="map_wrapper">\n    <div class="expand_btn"></div>\n    <div class="modal_map_wrapper"></div>\n    <div class="info_block">\n      <div class="short_info"></div>\n    </div>\n    <a rel="nofollow noopener noreferrer" href=""\n      target="_blank" class="direction_link">'+_("navigate_to")+"</a>\n  </div>\n</div>",big_map_wrapper_added:!1,get_direction_link:function(){return!("undefined"==typeof _location||!_location.lat||!_location.lng)&&"https://www.google.com/maps/dir/?api=1&destination="+_location.lat+","+_location.lng},open:function(e){var t,o;null!=ga&&ga("send","event","RestaurantMap","open"),logH(8596),window.location.hash="#modal_map",this.is_full_map_loaded?new ReactMapSplitTest(()=>({activate_location_after_search:!1,disable_point_change:!0,show_active_restaurant_info:RGPage.restaurant_id}),()=>({activeRestaurantInfo:RGPage.restaurant_id})).open():(e=e||$("#modal_map"),openModal(e),this.init_map(),this.load_map(RGPage.hasOwnProperty("restaurant_id")?RGPage.restaurant_id:$("#ranks").data("id")),this.is_first&&(o=this,$(window).on("resize orientationchange",function(){clearTimeout(t),t=setTimeout(function(){$(".modal_map_id").is(":visible")&&o.init_map()},100)}),this.is_first=!1))},init_map:function(){this.add_big_map_wrapper(),$(".modal_map_id").show(),initRestaurantSmallMap(".modal_map_wrapper"),this.add_show_best_restaurants_nearby()},add_big_map_wrapper:function(){var e;this.big_map_wrapper_added||($("body").append(this.big_map_wrapper),(e=this.get_direction_link())&&$(".modal_map_id a.direction_link").attr("href",e),this.big_map_wrapper_added=!0)},add_show_best_restaurants_nearby:function(){var e,t;0<$(".show_best_restaurants_nearby").length||((e=$(".map_wrapper")).prepend('<div class="show_best_restaurants_nearby">'+_("best_restaurants_around")+"</div>"),e.addClass("with_best_rst_around"),t=this,$(document).on("click",".show_best_restaurants_nearby",function(e){t.is_on_load||(t.is_on_load=!0,logH(9681),new ReactMapSplitTest(()=>({activate_location_after_search:!1,disable_point_change:!0,show_active_restaurant_info:RGPage.restaurant_id,on_map_ready_callback:function(){closeMap(get_visible_map_selector()),t.is_on_load=!1,t.is_full_map_loaded=!0}}),()=>({activeRestaurantInfo:RGPage.restaurant_id,onOpen:function(){closeMap(get_visible_map_selector()),t.is_on_load=!1,t.is_full_map_loaded=!0}})).open())}))},load_map:function(t){var o=this;null!=this.map_data[t]?o.show_modal(this.map_data[t]):($(".modal_map_id .info_block .short_info").html('<img src="'+cdn_host+'/img/site/responsive/ajax-loader.gif" class="loader" alt="">'),$.ajax({method:"GET",url:"/ajax/load-map-by-id?id="+t,dataType:"json",success:function(e){o.map_data[t]=e,o.show_modal(e)}}))},show_modal:function(e){var t=$(".modal_map_id");$(".info_block",t).empty().append(e.html)}};function isVietLang(){let e=$("h1 a");var t=e.text();return/[ÀÁÂÃÈÉÊÌÍÒÓÔÕÙÚĂĐĨŨƠàáâãèéêìíòóôõùúăđĩũơƯĂẠẢẤẦẨẪẬẮẰẲẴẶẸẺẼỀỀỂẾưăạảấầẩẫậắằẳẵặẹẻẽềềểếỄỆỈỊỌỎỐỒỔỖỘỚỜỞỠỢỤỦỨỪễệỉịọỏốồổỗộớờởỡợụủứừỬỮỰỲỴÝỶỸửữựỳỵỷỹ]/gi.test(t)?($("html head").append('<link type="text/css" rel="stylesheet" as="style" href="https://1014042311.rsc.cdn77.org/css/responsive/viet_lang_module.css">'),setTimeout(function(){e.css({opacity:"1"})},100)):e.css({opacity:"1"}),!1}function closeReviewForm(){"#add_photo"!=location.hash&&"#add_review"!=location.hash||window.replaceHash(""),$("#comment_form_modal").hide(),$("body").removeClass("modal-open"),bodyUnfixPosition(),r_comments_actions.isNeedReloadPage()&&location.reload()}function scrollToCommentFromAmp(){var e=window.location.search,e=new URLSearchParams(e).get("com");e&&(e=$('div[data-review-id="'+e+'"').offset().top-$(".wrapper_header").outerHeight(),$(window).scrollTop(e))}function closeMap(e){e=e||"";$(e+"+.modal_map").hide(),$("body").css({overflow:"visible",height:"auto"}),"function"==typeof history.replaceState?history.replaceState({},document.title,location.href.substr(0,location.href.length-location.hash.length)):location.hash="",$(".modal_map_id").hide()}function toggleInformation(e,t){e=e.find("div:first");"none"==e.css("max-height")?(e.attr("style",""),t.removeClass("up").addClass("down"),t.find(".on_shown").addClass("hide"),t.find(".on_hide").removeClass("hide"),e.addClass("with_fade")):showInformation(e,t)}function showInformation(e,t){e.css({"max-height":"none"}),t.addClass("up").removeClass("down"),t.find(".on_hide").addClass("hide"),t.find(".on_shown").removeClass("hide"),e.removeClass("with_fade")}function loadReviewAuthors(){}function waitByCssLoad(e){"stylesheet"==$("#restaurant_css").prop("rel")?e():setTimeout(function(){waitByCssLoad(e)},1e3)}function closeGalleryMenu(){$(document.body).css({overflow:"visible",height:"auto"}),$("#menu-gallery").hide()}var Gallery={index:0,scrolled_index:null,tpl:'<div class="item column {{class}}" data-aspect-ratio="{{ratio}}" style="{{style}}"><div class="gallery_item not-load" data-source="{{source}}" data-type="{{type}}" data-collage-num="{{collage_num}}" data-index="{{i}}" data-src="{{thumb_src}}" data-loader="custom" data-collage-type="{{collage_type}}" data-x1="{{x1}}" data-x2="{{x2}}" data-y1="{{y1}}" data-y2="{{y2}}" data-margin-size-x="{{margin_size_x}}" data-margin-size-y="{{margin_size_y}}" data-collage-category="{{collage_category}}" alt="{{alt}}"></div></div>',tpl_2:'<div class="item column video_item {{class}}" data-aspect-ratio="{{ratio}}" style="{{style}}"><div class="gallery_item not-load video_item_blur" data-type="{{type}}" data-collage-num="{{collage_num}}" data-index="{{i}}" data-src="{{thumb_src}}" data-loader="custom" data-collage-type="{{collage_type}}" data-x1="{{x1}}" data-x2="{{x2}}" data-y1="{{y1}}" data-y2="{{y2}}" data-margin-size-x="{{margin_size_x}}" data-margin-size-y="{{margin_size_y}}" alt="{{alt}}"></div><div class="gallery_item not-load gallery_item_video" data-type="{{type}}" data-collage-num="{{collage_num}}" data-index="{{i}}" data-src="{{thumb_src}}" data-loader="custom" data-collage-type="{{collage_type}}" data-x1="{{x1}}" data-x2="{{x2}}" data-y1="{{y1}}" data-y2="{{y2}}" data-margin-size-x="{{margin_size_x}}" data-margin-size-y="{{margin_size_y}}" alt="{{alt}}"></div>',$modal:$("#gallery_modal"),$photo_grid:$("#photo_grid"),$modal_navigation:$("#photo_navigation_inner"),photoswipe:null,tabsModalSwiper:null,xhr:null,is_loaded:!1,items:[],popup_category:0,scrollTop:0,last_state_resize:null,last_state_mobile_resize:null,from_hash:!0,collage_index_map:[],collage_index_map_images:[],collage_index_images:{},collage_index_real:[],current_collage_photo:null,is_gallery_init:!1,publift_ads_loaded:!1,swiper_data_loaded:!1,load_swiper_ajax:!1,onMagicScroll:!1,newSwiper:null,m_swipe:!1,wheelTimeout:null,index_
1shift:null,video_data:{},video_observer:null,video_observer_desktop:null,video_promise:null,touchesNumber:0,videoBlocks:[],video:null,video_container:null,is_active:!1,page_has_video_counter_inited:!1,video_was_open_counter_inited:!1,user_do_click:!1,resize_timeot:null,progressBar:null,video_indexes:[],video_to_photo_map:{},isVideo:e=>"is_video"in e&&e.is_video,getPhotoIndexByVideoId:function(e){return this.video_to_photo_map.hasOwnProperty(e)?this.video_to_photo_map[e]:null},init:function(){var f=this;if(!f.is_gallery_init){is_safari_browser()&&is_mobile()&&document.addEventListener("touchend",function(e){setTimeout(()=>{f.video&&f.video.src&&f.video.paused&&f.playVideo()},500)}),this.progressBar=$("#progressBar"),void(f.rg_photos_cnt=0)===json_arr.photos&&(json_arr.photos=[]);var e,t=JSON.parse(JSON.stringify(json_arr.photos));for(e in t)"is_rg"in t[e]&&t[e].is_rg&&f.rg_photos_cnt++,this.isVideo(t[e])&&(f.video_data[e]=t[e],f.video_to_photo_map[f.video_data[e].id]=parseInt(e),f.page_has_video_counter_inited||(logH(9854),f.page_has_video_counter_inited=!0));this.last_state_resize=this.getState();var o="click",n=($(document).on("click",".gallery_item",o,function(e,t){let o;var n,i,a,r,s,l,c=$(this).data("type");"collage"==c?(n=f.getCollageCoords($(this)),s=f.collage_index_real[$(this).data("collage-num")],l=f.collage_index_map[s],i=(void 0!==t?t:e).pageX,t=(void 0!==t?t:e).pageY,e=i-$(this).offset().left,i=t-$(this).offset().top,a=e/$(this).width(),r=i/$(this).height(),t=jQuery.grep(n,function(e,t){return e.x1<=a&&e.x2>=a&&e.y1<=r&&e.y2>=r}),o=l[t[0].image_num],f.current_collage_photo=t[0]):"video"==c?(e=$(this).data("source"),o="collage"===e?(s=f.collage_index_real[$(this).data("collage-num")],(l=f.collage_index_map[s])[0]):$(this).data("index"),f.setCurrentCollagePhoto(null)):(o=$(this).data("index"),o=Gallery.getDataIndex(o,!1,"index_gallery","index")),o=f.correctDataIndex(o),f.changePhoto(o)}),$(document).on(is_mobile()?"tap":"click","#toggleMuteButton",function(e){e.preventDefault(),f.video.muted=!f.video.muted;e=$(e.target);f.video.muted?(e.removeClass("off"),e.addClass("on")):(e.removeClass("on"),e.addClass("off"))}),$(document).on("click",".item.column .selected",function(e){$(this).parent().find(".gallery_item").trigger(o,e)}),$(document).on("click",".map-img",function(){f.openGallery(0)}),$(document).on("click",".photo_item",function(){f.openGalleryByUrl($(this).data("photo_id"))}),$(document).on("doubletap",".video-container, .photo_about, .pswp__top-bar, .video-block, video, .video-preloader, .video-container + .pswp__img",function(e){e.preventDefault(),e.stopPropagation()}),$(document).on("doubletap",".pswp__item, .pswp__zoom-wrap",function(e){$(this).find(".video-container").length&&(e.preventDefault(),e.stopPropagation())}),$(".gallery_back_btn",this.$modal).on(o,function(e){return"none"!=f.$modal.css("display")&&setTimeout(function(){f.closeGallery(),$("body").hasClass("reviews_page")&&$("html, body").scrollTop(f.scrollTop)},100),!1}),f.last_state_mobile_resize=f.is_mobile(),0),i=($(window).on("resize orientationchange",function(e){"block"==f.$modal.css("display")&&(is_mobile()&&"orientationchange"==e.type&&$("<div>").addClass("loader").appendTo(f.$modal.find(".photo_navigation")),clearTimeout(n),n=setTimeout(function(){f.renderImages(),f.photoswipe&&f.photoswipe.updateSize(),document.querySelector(".selected").scrollIntoView(),f.$modal.find(".loader").remove()},250),f.last_state_mobile_resize!=is_mobile())&&f.isPhotoSwipeInit()&&(f.initPhotoSwipe(),f.photoswipe.init(),f.last_state_mobile_resize=is_mobile()),Gallery.photoswipe&&Gallery.photoswipe.updateSize(),setTimeout(Gallery.videoWindowResizer,300),setTimeout(function(){Gallery.photoswipe&&Gallery.photoswipe.updateSize(),Gallery.videoWindowResizer()},750)}),$(window).on("orientationchange",function(e){Gallery.photoswipe&&Gallery.photoswipe.updateSize(),setTimeout(Gallery.videoWindowResizer,300),setTimeout(function(){Gallery.photoswipe&&Gallery.photoswipe.updateSize(),Gallery.videoWindowResizer()},750)}),$(window).on("popstate",function(e){"block"==f.$modal.css("display")&&-1===window.location.hash.search("gallery")&&f.closeGallery()}),$(document).on(o,".selected",function(e){is_mobile()&&$($(e.target).parent().find(".gallery_item")[0]).trigger(o,e)}),0<$(".screen-slider").length&&((f=this).newSwiper=new Swiper(".screen-slider",{slidesPerView:"auto",spaceBetween:1,grabCursor:!0,watchSlidesProgress:!0,watchOverflow:!0,navigation:{nextEl:".screen-slider-nav.next",prevEl:".screen-slider-nav.prev"},keyboard:{enabled:!0,onlyInViewport:!0,pageUpDown:!1},on:{init:function(o){var e=new URL(window.location.href).hash.match("#slide-([0-9]+)"),t=$(".screen-slider .swiper-slide");e&&0<e.length&&f.loadSwiperData(o,function(){o.slideTo(parseInt(e[1]),100)}),1===t.length?$(".screen-slider").addClass("one_item"):2===t.length&&$(".screen-slider").addClass("two_items"),requestAnimationFrame(()=>{a(o)}),document.addEventListener("wheel",t=>{if(($(t.target).is(".screen-slider img")||$(t.target).is(".screen-slider"))&&1<Math.abs(t.deltaX)){f.onMagicScroll=!0,f.m_swipe||(f.loadSwiperData(o,f.newSwiper.update(
1)),f.m_swipe=!0),t.preventDefault(),t.stopPropagation(),f.newSwiper.getTranslate()<f.newSwiper.maxTranslate()&&f.newSwiper.slideToClosest(200);let e=f.newSwiper.getTranslate()+-t.deltaX;((e=0<(e=e<f.newSwiper.maxTranslate()?f.newSwiper.maxTranslate():e)?0:e)<-30||e>f.newSwiper.maxTranslate()+20)&&$(".screen-slider-nav").removeClass("swiper-button-disabled_mm"),-30<e&&$(f.newSwiper.navigation.prevEl).addClass("swiper-button-disabled_mm"),e<f.newSwiper.maxTranslate()+20&&$(f.newSwiper.navigation.nextEl).addClass("swiper-button-disabled_mm"),o.setTranslate(e),o.updateActiveIndex(),clearTimeout(f.wheelTimeout),f.wheelTimeout=setTimeout(()=>{f.onMagicScroll=!1,f.onMagicScroll||(o.updateSize(),o.updateSlides(),o.updateProgress(),o.updateSlidesClasses())},100)}},{passive:!1}),$(o.el).on("mouseenter",".screen-slider-nav",function(e){$(this).addClass("btn_NoHide")}),$(o.el).on("mouseleave",".screen-slider-nav",function(e){$(this).removeClass("btn_NoHide")})},slideChangeTransitionEnd:function(e){this.isEnd||f.loadSwiperData(e),e.update(),e.updateSlides()},reachEnd:function(e){},reachBeginning:function(e){},click:function(e,t){Gallery.setActiveTab(0),t=(t.changedTouches?(n=t.changedTouches[0].pageX,t.changedTouches[0]):(n=t.pageX,t)).pageY;var o,n,i,a,r,s,l,c,d,u,m,p,h,_=$(this.clickedSlide);_.length&&($(_).hasClass("collageWrapper")?(o=Gallery.getCurrentGalleryTab(),u=n-(n=$(_).offset()).left,t=t-n.top,n=$(_).width(),i=$(_).height(),a=Gallery.getCollageCoords($(_)),r=0,s=u/n,l=t/i,c=jQuery.grep(a,function(e,t){return e.x1<=s&&e.x2>=s&&e.y1<=l&&e.y2>=l}),d=$(_).data("collage-num"),$(_).prevAll(".collageWrapper").not(function(){return d===$(this).data("collage-num")}).each(function(){var e;$(this).hasClass("hide")||(1!=(e=$(this).data("collage-type"))&&0==$(this).data("x2")&&0==$(this).data("y2")&&(e=2),r+=e)}),u=$(_).prevAll(".photo-video:not(.hide)").length,r+=u,m=c[0].image_num+r+(0<restaurant_page_photos.photos.length?restaurant_page_photos.photos.length:0),o||(m+=f.rg_photos_cnt),0<$("#gallery_modal").length&&setTimeout(function(){Gallery.setCurrentCollagePhoto(c[0]),Gallery.openGallery(m,!0)},100)):(p=!$(document).find(".all_photos").is(":visible"),h=_.hasClass("photo-video")?f.getPhotoIndexByVideoId(_.data("video-id")):$(_).data("index"),Gallery.preloadVideoOnClick(h),setTimeout(function(){Gallery.openGallery(h,p)},100)))},resize:function(e){a(e)}}}),f.tabsSwiper=new Swiper(".gallery__tabs-page",{slidesPerView:"auto",grabCursor:!0,watchOverflow:!0,spaceBetween:8,navigation:{nextEl:".gallery__tabs-button-next",prevEl:".gallery__tabs-button-prev"}})),f.is_gallery_init=!0,anchorAdElemModify($("#photo_grid")),setTimeout(function(){-1!==location.hash.search("gallery")&&$(".add_photo.total_photo").click(),Gallery.newSwiper&&Gallery.newSwiper.update()},1500),$(document).on("touchmove","#photos_gallery",function(e){e.touches&&(f.touchesNumber=e.touches.length)}),$(document).on("touchend","#photos_gallery",function(e){1<f.touchesNumber&&(f.videoWindowResizer(),setTimeout(f.videoWindowResizer,10),f.touchesNumber=0)}),$(".gallery__tabs .gallery__tabs-item"));f.requestGalleryTab=0,i.on("click",function(){var n=parseInt($(this).data("id"));if(!f.requestGalleryTab&&f.newSwiper){f.requestGalleryTab=1,$(this).addClass("gallery__tabs-item-wait"),f.setActiveTab(n);let e=function(){f.getSwiperSlide(function(e,t,o){Gallery.compareCategoryId(n,e)?o.removeClass("hide"):o.addClass("hide")}),f.photoswipe=null,f.scrolled_index=null,$(".gallery__tabs .gallery__tabs-item-wait").removeClass("gallery__tabs-item-wait"),n&&(Gallery.newSwiper.update(),Gallery.newSwiper.slideTo(0)),f.openGallery(is_mobile()?null:0),f.requestGalleryTab=0};Gallery.swiper_data_loaded?e():Gallery.loadSwiperData(f.newSwiper,function(){e()},1)}}),0<$(".gallery__tabs-modal").length&&(f.tabsModalSwiper=new Swiper(".gallery__tabs-modal",{slidesPerView:"auto",grabCursor:!0,watchOverflow:!0,spaceBetween:8,navigation:{nextEl:".gallery__tabs-button-next",prevEl:".gallery__tabs-button-prev"},on:{init:function(){f.checkTabsOverflow(this)},resize:function(){f.checkTabsOverflow(this)},update:function(){f.checkTabsOverflow(this)}}})),setTimeout(f.videoWindowResizer,500),document.addEventListener("visibilitychange",()=>
1{Gallery.photoswipe&&Gallery.photoswipe.updateSize(),setTimeout(function(){Gallery.photoswipe&&Gallery.photoswipe.updateSize()},750)}),this.isGalleryTabs("modal")||this.$modal.addClass("no-gallery-tabs"),this.is_active=!0}function a(e){var t=$(".screen-slider");e.update(),e.isLocked?t.addClass("hiddenNav"):t.removeClass("hiddenNav")}},checkTabsOverflow:function(e){var t=e.el,o=e.wrapperEl;let n=0;e.slides.forEach(e=>{n+=e.offsetWidth+8});e=t.offsetWidth;n>e?(t.classList.remove("swiper-no-overflow"),t.style.cursor="",o.style.cursor=""):(t.classList.add("swiper-no-overflow"),t.style.cursor="default",o.style.cursor="default")},isActive:function(){return this.is_active},is_mobile:function(){return $(window).outerWidth()<=1030},setCurrentCollagePhoto:function(e){this.current_collage_photo=e},loadSwiperData:function(n,t,i=0){var a=this,e=n.activeIndex,o=n.slides.length;if(i||!(e+10<o||n.isEnd)){let e=void 0!==json_arr.collages_sorted&&json_arr.collages_sorted?"&sort=new":"";i&&(e+="&loadall=1"),this.load_swiper_ajax=$.ajax({method:"GET",url:"/ajax/load-gallery-data?restaurant_id="+restaurant_id+"&slidesLength="+o+"&indexShift="+a.index_shift+e,dataType:"html",ajaxStart:function(){a.load_swiper_ajax=!0},success:function(e){var o="<div>"+e+"</div>";$.each($("div",o),function(e,t){n.appendSlide(t.outerHTML),e===$("div",o).length-1&&(a.index_shift=$(t).data("index-shift"))}),n.update(),lazyload.update(),a.swiper_data_loaded=i,"function"==typeof t&&t()}})}},replaceVideo:function(e){var t,o;this.photoswipe&&e&&((t=e.querySelector("img"))&&!e.querySelector("video")&&((o=this.findVideoDataByCurrItem())?(e.prepend(this.getVideoBlock(o,t)),this.video_container.querySelector(".video-preloader").style.display="block",this.video.style.opacity=0,is_safari_browser()&&is_mobile()||this.playVideo(),this.video.addEventListener("enterpictureinpicture",e=>{document.exitPictureInPicture()}),setTimeout(function(){Gallery.photoswipe.updateSize(),Gallery.videoWindowResizer()},100)):this.video&&(this.video.pause(),this.video.src="")),setTimeout(Gallery.swipeAnimationInsert,700))},playVideo:function(t){let o=this.video_container.querySelector(".video-preloader");this.video.play().then(e=>{o.style.display="none",this.video.style.opacity=1,t()}).catch(e=>{o.style.display="none",this.video.style.opacity=1})}
1,getState:function(){var e=$(window).outerWidth();return 740<e&&e<=1030?2:e<=740?1:0},changePhoto:function(e){this.index=e,this.getPhotoSwipe(),e!=this.photoswipe.getCurrentIndex()&&this.photoswipe.goTo(e)},getVideoBlockHeight:function(e){return is_mobile()&&(screen.orientation&&"landscape-primary"===screen.orientation.type||window.matchMedia("(orientation: landscape)").matches)?parseInt(e)-40+"px":e},getVideoBlock:function(e,t){var o,n=this.getVideoBlockHeight(t.style.height);return this.video&&e.srcVideo===this.video.src||(this.video?(this.video.src=e.srcVideo,this.video.width=t.offsetWidth,this.video.height=t.offsetHeight,this.video_container.style.width=t.offsetWidth+"px",this.video_container.style.height=t.offsetHeight+"px"):(o=`
2                    <div class="video-block" style="text-align: center;">
3                        <video 
4                            src="${e.srcVideo}" 
5                            type="video/mp4" 
6                            id="gallery-video" 
7                            class="video-go" 
8                            style="outline: none; opacity: 0" 
9                            width="${t.style.width}"
10                            height="${n}"
11                            preload="metadata"
12                            ${this.user_do_click?"":"muted"}
13                            loop
14                            disablePictureInPicture 
15                            playsinline
16                        ></video>
17                        <div class="video-preloader"></div>
18                        <div class="video-controls">
19                            <div id="toggleMuteButton" class="${this.user_do_click?"off":"on"}"></div>            
20                        </div>
21                    </div>`,this.video_container=document.createElement("div"),this.video_container.classList.add("video-container"),this.video_container.style.height=n,this.video_container.style.width=t.style.width,this.video_container.setAttribute("data-video-id",e.id),this.video_container.innerHTML=o,this.video_was_open_counter_inited||(logH(9855),this.video_was_open_counter_inited=!0),this.video=this.video_container.querySelector("video")),this.video.ontimeupdate=()=>{var e=this.video.currentTime/this.video.duration;this.progressBar.css("width",Math.floor(100*e)+"%")}),this.video_container},videoWindowResizer:function(){Gallery.isPhotoSwipeInit()&&document.querySelectorAll(".video-container").forEach(e=>{var t=e.parentNode.querySelector("img.pswp__img");t&&(e.style.width=t.style.width,e.style.height=Gallery.getVideoBlockHeight(t.style.height))})},findVideoDataByCurrItem:function(){return this.findVideoData(this.photoswipe.currItem)},findVideoData:function(e){if(e&&1==e.is_video)for(var t in this.video_data)if(this.video_data.hasOwnProperty(t)&&this.video_data[t].id===e.id)return this.video_data[t];return null},selectNavigationThumbs:function(i){this.isPubliftGalleryAds()&&i>=PubliftGalleryAds.conf.ads_position&&(i-=1);let e=this;var t=parseInt(this.getCurrentGalleryTab());if(this.scrolled_index!=i||-1!=jQuery.inArray(i,e.collage_index_map_images)){let o=!1,n=!1;$.each(this.collage_index_map,function(e,t){return-1==jQuery.inArray(i,t)||(o=e,!(n=!0))}),!1!==o&&(o+=0<restaurant_page_photos.photos.length?restaurant_page_photos.photos.length:0,0===t&&(o+=this.rg_photos_cnt),i=o);var a,t=$(".gallery_header",this.$modal).height()+4,r=($(".selected",this.$modal).remove(),this.getDataIndex(i,n)),r=$('.gallery_item[data-index="'+r+'"]',this.$modal);0<r.length&&(a=$("<div>").addClass("selected"),!1!==o&&e.current_collage_photo&&($(a).css("width",100*(e.current_collage_photo.x2-e.current_collage_photo.x1)+"%"),$(a).css("height",100*(e.current_collage_photo.y2-e.current_collage_photo.y1)+"%"),$(a).css("top",100*e.current_collage_photo.y1+"%"),$(a).css("left",100*e.current_collage_photo.x1+"%")),$(a).appendTo(r.parent()),a=r.offset().top-window.scrollY,r.height()+a>this.$modal_navigation.height()?(this.$modal_navigation.stop().animate({scrollTop:this.$modal_navigation.scrollTop()+(r.height()+a-this.$modal_navigation.height())},500,"swing",function(){e.$photo_grid.trigger("scroll")}
21),this.$photo_grid.trigger("scroll")):a-t<0&&this.$modal_navigation.stop().animate({scrollTop:a-t+this.$modal_navigation.scrollTop()},500,"swing",function(){e.$photo_grid.trigger("scroll")}),this.scrolled_index=i)}},getDataIndex(e,t,o="index",n="index_gallery"){if(!1===t)for(var i in Gallery.items)if(Gallery.items[i][n]==e)return Gallery.items[i][o];return e},loadNextElements:function(e,t=0){this.$photo_grid.find(".item.column").remove();var o=e.length,n=(Mustache.parse(this.tpl),Mustache.parse(this.tpl_2),[]);if(void 0!==restaurant_page_photos&&0<restaurant_page_photos.photos.length)for(var i in restaurant_page_photos.photos){var a=jQuery.grep(e,function(e,t){return e.id==restaurant_page_photos.photos[i].id})[0];a.ratio=1200/900,a.type="video"==a.type?"video":"photo",0<a.height&&(a.ratio=parseFloat(a.width/a.height).toFixed(3)),a.thumb_src=a.hasOwnProperty("large")?a.large:a.src,(a.is_video?$(Mustache.render(this.tpl_2,a)):$(Mustache.render(this.tpl,a))).appendTo(this.$photo_grid),n.push(a.id)}var r,s=[],l=0,c=[],d=JSON.parse(JSON.stringify(json_arr.photos));if(t<=0)for(var u in e){var m=e[u].i||0;"video"!=e[u].type&&"is_rg"in e[u]&&d[m].is_rg&&(m="in_collage"in d[m]&&d[m].in_collage,l++,e[u].ratio=1200/900,e[u].type="video"==e[u].type?"video":"photo",0<e[u].height&&(e[u].ratio=parseFloat(e[u].width/e[u].height).toFixed(3)),m||-1!=s.indexOf(e[u].id.toString())||-1!=n.indexOf(e[u].id.toString())||(e[u].thumb_src=e[u].hasOwnProperty("large")?e[u].large:e[u].src,$(Mustache.render(this.tpl,e[u])).appendTo(this.$photo_grid)))}if(0<restaurant_collages.length){var p,h,_=0,f=0<restaurant_page_photos.photos.length?restaurant_page_photos.photos.length:0;for(p in this.getCurrentGalleryTab()||(f=0),restaurant_collages)"video"===restaurant_collages[p].type&&t<=0?((h={...restaurant_collages[p]}).ratio=1200/900,0<h.height&&(h.ratio=parseFloat(h.width/h.height).toFixed(3)),h.thumb_src=h.src,h.i=_+f+l,h.collage_num=parseInt(p),$(Mustache.render(this.tpl,h)).appendTo(this.$photo_grid),c.push(h.id),_++):(h=restaurant_collages[p].collage_category||0,this.compareCategoryId(t,h)&&(restaurant_collages[p].i=_+f+l,restaurant_collages[p].type="collage",restaurant_collages[p].collage_num=parseInt(p),restaurant_collages[p].thumb_src=restaurant_collages[p].src,$(Mustache.render(this.tpl,restaurant_collages[p])).appendTo(this.$photo_grid),s.push(restaurant_collages[p].image1_id.toString()),restaurant_collages[p].image2_id&&s.push(restaurant_collages[p].image2_id.toString()),restaurant_collages[p].image3_id&&s.push(restaurant_collages[p].image3_id.toString()),restaurant_collages[p].image4_id&&s.push(restaurant_collages[p].image4_id.toString()),_++))}for(r in e){var g=e[r].i||0;"is_rg"in e[r]&&d[g].is_rg||-1!==jQuery.inArray(e[r].id,c)||(g="in_collage"in d[g]&&d[g].in_collage,e[r].ratio=1200/900,e[r].type="video"==e[r].type?"video":"photo",0<e[r].height&&(e[r].ratio=parseFloat(e[r].width/e[r].height).toFixed(3)),g)||-1!=s.indexOf(e[r].id.toString())||-1!=n.indexOf(e[r].id.toString())||(e[r].thumb_src=e[r].hasOwnProperty("large")?e[r].large:e[r].src,this.isVideo(e[r])&&c.push(e[r].id),$(Mustache.render(this.tpl,e[r])).appendTo(this.$photo_grid))}this.renderImages(),0<o&&this.initImgLoader()},renderImages:function(){for(var e=[],t=this.$photo_grid.width()-(is_mobile()&&screen.orientation&&"landscape-primary"===screen.orientation.type?12:6),o=this.$photo_grid.find(".item.column"),n=o.length,i=0;i<o.length;i++){var a,r,s=o[i],l=$(s),c=.8<=(r=180*(a=parseFloat(l.data("aspect-ratio"))))/t;l.find(".gallery_item").data("collage-category");isCollage()?($(s).find(".gallery_item").data("index"),l.css({width:"",marginRight:"",height:t/a+"px"}),l.addClass("wide2"),e=[]):n<4||c&&0==e.length||1<i&&(i+1)%4==0&&0==e.length&&1.2<a||i==o.length-1&&0==e.length&&1.2<a?(l.css({width:"",marginRight:"",height:t/a+"px"}),l.addClass("wide2"),e=[]):(l.removeClass("wide2"),l.css(0==a?{marginRight:"",width:"239.4px",height:r/1.33+"px"}:{marginRight:"",width:r+"px",height:r/a+"px"}),e.push(l),1<e.length&&(this.prepareRow(e,t),e=[]))}waterfall("#photo_grid")},prepareRow:function(e,t){var o=0,n=0,i=[],a=[];for(l in e){var r=e[l].css("width").replace("px",""),s=e[l].css("height").replace("px",""),r=(o+=r+3,a.push(r),r/parseFloat(s));n+=r,i.push(r)}if(2<Math.abs(o-t)){var l,c=Math.ceil((a[1]-(a[1]*i[0]-a[0]*i[1]-(t-3-a[0]-a[1])*i[1])/n)/i[1]);for(l in e){var d=parseFloat(e[l].css("width").replace("px",""))/parseFloat(e[l].css("height").replace("px","")),d={he
21ight:c,width:Math.floor(c*d)};l==e.length-1&&(d.marginRight=0),e[l].css(d)}}},getElem:function(e,t){return t[e]},closeGallery:function(){this.$modal.hide(),replaceHash(""),this.isPhotoSwipeInit()&&(this.photoswipe.initHistory(),this.photoswipe.close()),$(".screen-slider .swiper-slide.hide").removeClass("hide");var e=json_arr.photos.length||0,t=this.getCurrentGalleryTab();this.setTotalPhotos(e),this.newSwiper&&(this.newSwiper.update(),t)&&this.newSwiper.slideTo(0),$("body").removeClass("overflow").removeClass("black"),$(document).scrollTop(this.scrollTop),Gallery.setActiveTab(0)},searchIndexByUrl:function(e){for(var t in json_arr.photos){var o=json_arr.photos[t].src||null;if(o&&-1!=o.search(e))return t}return 0},openGalleryByUrl:function(e){var t=this.searchIndexByUrl(e),o=this;$("body").hasClass("reviews_page")&&(o.scrollTop=$(window).scrollTop()),setTimeout(function(){o.openGallery(parseInt(t),1)},100)},loadGalleryItems:function(a){var r,e;null!=this.xhr&&4!=this.xhr.readyState||(r=this,e=void 0!==json_arr.collages_sorted&&json_arr.collages_sorted?"?sort=new":"",void 0===json_arr.photos&&(json_arr.photos=[]),this.xhr=$.ajax({method:"GET",url:"/ajax"+(null!=json_arr.slug?"/"+json_arr.slug:document.location.pathname)+"/load-photos"+e,dataType:"json",success:function(t){var o=[];for(let e=0;e<t.photos.length;e++){var n=t.photos[e],i=json_arr.photos[e]||null;null===n.src&&i?o.push(i):o.push(n)}json_arr.photos=o,r.init(),null!=a&&a();var e=$("#gallery_modal").css("display");"block"!==e&&"flex"!==e||setTimeout(function(){void 0!==Gallery&&Gallery.openGalleryFromHash()},100)}}))},logClick:function(){logH(restaurants_counters.getByAction("gallery"))},openGallery:function(e,t=!1){"undefined"!=typeof android_popup&&null!==android_popup&&"function"==typeof android_popup.close&&android_popup.close(!1),null!=ga&&ga("send","event","Gallery","open"),e=this.correctDataIndex(e);var i=parseInt(this.getCurrentGalleryTab()),o=$("body"),a=(this.logClick(),is_mobile()&&this.$modal_navigation.css("-webkit-overflow-scrolling","auto"),window.history&&history.pushState&&-1===window.location.hash.search("gallery")&&history.pushState({},document.title,"#gallery"),this.index=e,this.collage_index_map=[],this.collage_index_images={},this.collage_index_real={},this.$modal.find(".loader").remove(),$("<div>").addClass("loader").appendTo(this.$modal.find(".photo_navigation")),0<restaurant_page_photos.photos.length?restaurant_page_photos.photos.length:0);if(0===i&&(a+=this.rg_photos_cnt),this.video_indexes=[],0<restaurant_collages.length){var r,s=["image1_id","image2_id","image3_id","image4_id"];let n=0;for(r in restaurant_collages){let e,t=[],o=restaurant_collages[r].collage_category||0;for(var l in s)(e=restaurant_collages[r][s[l]])&&(null===(this.collage_index_images[e]||null)&&(this.collage_index_images[e]=[]),this.collage_index_images[e].push(r));if(this.compareCategoryId(i,o)||i<0){if(this.isVideo(restaurant_collages[r])&&i<=0){var c=n+a;t.push(c),this.video_indexes.push(c),n++}else if(0<=i)for(var d in s)e=restaurant_collages[r][s[d]],restaurant_collages[r].collage_category,e&&(d=n+a,t.push(d),this.collage_index_map_images.push(d),n++);this.collage_index_real[r]=this.collage_index_map.length,this.collage_index_map.push(t)}}}this.$modal.appendTo("body"),this.$modal.show(),0==this.scrollTop&&(this.scrollTop=o.scrollTop()||$("html").scrollTop()),o.addClass("overflow");var e=this.initPopUp(i),n=this,u=(null!=n.photoswipe&&(n.photoswipe.isChangeTab=!0,n.photoswipe.initHistory(),n.photoswipe.close()),0),m=0;$("#gallery_modal .gallery__tabs-item").each(function(){$(this).hasClass("gallery__tabs-item--active")&&(m=u),u++}),m=0<m?m-1:0,n.tabsModalSwiper&&(n.tabsModalSwiper.update(),n.tabsModalSwiper.slideTo(m)),n.setTotalPhotos(e),e&&(is_mobile()||n.initPhotoSwipe(),-1===location.hash.search("&gid=")&&!t&&n.is_mobile()||n.getPhotoSwipe(),setTimeout(function(){n.$modal.find(".loader").remove(),n.is_loaded=!0},500),n.selectNavigationThumbs(n.index),waterfall("#photo_grid"),is_mobile()&&(n.$modal_navigation.css("-webkit-overflow-scrolling","touch"),waterfall("#photo_grid")),n.isPhotoSwipeInit())&&n.photoswipe.updateSize(1)},setTotalPhotos:function(e){var t,o=$(".total_photo");0<o.length&&(t=o.data("title"),o.find(".add_photo_link").html(t.replace("#",e)))},getSwiperSlide:function(n){$(".swiper-slide[data-index]").each(function(){var e=$
21(this),t=e.data("collage-category"),o=e.data("collage-type"),t=void 0===t?0:parseInt(t),o=void 0===o?1:parseInt(o);n(t,o||1,e)})},getCurrentGalleryTab:function(){var e=$(".gallery__tabs .gallery__tabs-item--active");return e.length&&e.data("id")||0},isGalleryTabs:function(e){return"page"===e?$(".gallery__tabs-page").length:"modal"===e?$(".gallery__tabs-modal").length:void console.warn("Not a valid argument type")},compareCategoryId:function(e,t){return!e||("object"==typeof t?null!==(t[e]||null):e===t)},openGalleryFromHash:function(e){var t,o=this;"stylesheet"==$("#restaurant_css").prop("rel")?(o.from_hash=!0,isCollage()?(t=$(".swiper-slide").first(),$(t).hasClass("collageWrapper")&&(t=Gallery.getCollageCoords($(t)),o.setCurrentCollagePhoto(t[0])),o.openGallery(e,!0)):o.openGallery(e)):setTimeout(function(){o.openGalleryFromHash(e)},50)},isPubliftGalleryAds:function(){return"undefined"!=typeof PubliftGalleryAds&&this.is_mobile()},getPubliftGallerySlot:function(){return PubliftGalleryAds.conf.slot},isNeedPubliftSlotAtPosition:function(e){return this.isPubliftGalleryAds()&&PubliftGalleryAds.conf.ads_position==e},isNeedPubliftLoadAtPosition:function(e){return this.isPubliftGalleryAds()&&(PubliftGalleryAds.conf.ads_position==e+1||PubliftGalleryAds.conf.ads_position==e-1)},loadPubliftAdsAtPosition:function(e){var t;this.isNeedPubliftLoadAtPosition(e)&&(t=this,setTimeout(function(){var e=t.getPubliftGallerySlot().match(/data-fuse=\"([0-9]+)\"/)[1];fusetag.loadSlotById(parseInt(e))},500))},correctDataIndex:function(e){return!this.isPubliftGalleryAds()||e<PubliftGalleryAds.conf.ads_position?e:e+1},addPhotos:function(o,n=0){var i=[],a=this.collage_index_images;if(n=parseInt(n),null!=o&&0<o.length)for(var r in this.items=[],o){this.isNeedPubliftSlotAtPosition(r)&&this.items.push({html:this.getPubliftGallerySlot()});var s,l=Object.assign({},o[r]),c=o[r].is_video?_("report_video_short"):_("report_photo_short");o[r].added_date;let e=0,t=a[o[r].id||""]||null;null===t?e=o[r].collage_category||0:(s=t.shift(),null!==(t=restaurant_collages[s].collage_category||null)&&parseInt(t)===n&&(e=n)),(this.compareCategoryId(n,e)||n<=0)&&(s=this.isVideo(o[r]),0<n&&!s||0===n||n<0&&s)&&(this.items.push({title:'<span class="photo_about">'+o[r].description+'<span class="report_msg">'+c+'</span><span class="photo_agency"><span class="photo_agency__date"></span><span class="photo_agency__plarform">'+o[r].title+"</span></span></span>",src:o[r].is_video?"img/photoswipe/black_box.jpg":o[r].src,w:o[r].is_video&&1<o[r].originalWidth?o[r].originalWidth:o[r].width,h:o[r].is_video&&1<o[r].originalHeight?o[r].originalHeight:o[r].height,alt:o[r].alt,id:o[r].id,agency:o[r].agency,is_video:o[r].is_video,added_date:"",category:e,index:r,index_gallery:this.items.length}),l.i=r,i.push(l)),o[r].i=r}return i.length&&this.loadNextElements(i,n),i.length},initPopUp:function(e=0){if(0<this.items.length&&e===this.popup_category)return this.renderImages(),this.items.length;this.popup_category=e;var t=JSON.parse(JSON.stringify(json_arr.photos));return this.addPhotos(t,e)},initImgLoader:function(){var e=this;e.$photo_grid.on("layoutComplete",function(){e.$photo_grid.trigger("scroll"),$(".gallery_item.not-load").each(function(){var e,t=this,o=$(t).data("src");let n;o.includes("|")?(e=o.split("|"),n=e[0],(window.innerWidth<=1030&&450<=window.innerWidth||220<$(t).width())&&(n=e[1]),$(t).parent().hasClass("wide2")&&(n=e[2])):n=o,$(t).is("div")?$(t).css({"background-image":"url("+n+")"}):($(t).prop("src",n),t.load()),$(t).removeClass("not-load")})})},isPhotoSwipeInit:function(){return!(null==this.photoswipe||null==this.photoswipe.getCurrentIndex())},getPhotoSwipe:function(){return this.isPhotoSwipeInit()||(this.initPhotoSwipe(),this.photoswipe.init()),this.photoswipe},initPhotoSwipe:function(){0<$('[data-anchor-shown="true"]').length&&anchorAdHeightModify($(".pswp__scroll-wrap"));var u=this,t=(u.is_mobile()&&!u.from_hash&&$("body").addClass("black"),u.from_hash=!1,document.getElementById("photos_gallery"));if(null!=t){var a=window.pageYOffset||document.documentElement.scrollTop,o={history:!1,loop:!0,preload:[1,1],index:this.index,getThumbBoundsFn:function(o){var n=!1,i=!1,e=($.each(u.collage_index_map,function(e,t){return-1==jQuery.inArray(o,t)||(n=e,!(i=!0))}),!1!==n&&(o=n),o=Gallery.getDataIndex(o,i),(i?$('.gallery_item[data-collage-num="'+n+'"]')[0]||$(".gallery_item")[o]:$('.gallery_item[data-index="'+o+'"]')[0]).getBoundingClientRect());return{x:e.left,y:e.top+a,w:e.width}}};if(this.is_mobile()||(o.closeOnScroll=!1,o.modal=!1,o.escKey=!1,o.closeElClasses=[],o.closeOnVerticalDrag=!1,o.clickToCloseNonZoomable=!1,o.getThumbBoundsFn=!1),!this.photoswipe){this.photoswipe=new PhotoSwipe(t,PhotoSwipeUI_Default,this.items,o),this.photoswipe.isChangeTab=!1,this.photoswipe.listen("beforeChange",function(e,t,o,n){is_safari_browser()&&is_mobile()||u.removeVideo(),$(this.currItem.container).find("img").attr("alt",this.currItem.alt);var i=u.photoswipe.getCurrentIndex(),a=!1;if(0<u.collage_index_map.length){var r=!1,s=0;if(-1===jQuery.inArray(i,u.video_indexes)?$.each(u.collage_index_map,function(e,t){return-1!=(s=jQuery.inArray(i,t))?(r=e,!1):(t.length,!0)}):u.setCurrentCollagePhoto(null),!1!==r){for(var l in u.collage_index_real)if(u.collage_index_real[l]==r){r=l;break}var c=$('.swiper-slide[data-collage-num="'+r+'"]'),d=$('#photo_grid .gallery_item[data-collage-num="'+r+'"]');c.length?(c=u.getCollageCoords($(d)),u.isPubliftGalleryAds()&&u.index>=PubliftGalleryAds.conf.ads_position&&0,u.current_collage_photo=c[s]):((c=document.querySelector(".screen-slider").swiper).activeIndex=i,a=!0,u.loadSwiperData(c,function(){var e=u.getCollageCoords($(d));u.isPubliftGalleryAds()&&u.index>=PubliftGalleryAds.conf.ads_position&&0,u.current_collage_photo=e[s],u.selectNavigationThumbs(i),$(".photo_about").hide()}))}}
21a||(u.selectNavigationThumbs(i),$(".photo_about").hide())}),this.photoswipe.listen("firstUpdate",function(){u.photoswipe.listen("parseVerticalMargin",function(e){is_mobile()&&e.title&&-1!=e.title.search(/photo_about">[^<]+</i)&&(e.vGap.bottom=50)});function e(){$("#photos_gallery.pswp--visible").length||($("#photos_gallery").addClass("pswp--open").addClass("pswp--visible"),setTimeout(e,100))}setTimeout(e,500);let t=setInterval(()=>{u.photoswipe&&u.photoswipe.currItem&&u.photoswipe.currItem.container&&u.photoswipe.currItem.container.querySelector("img")&&(clearInterval(t),u.replaceVideo(u.photoswipe.currItem.container),u.video)&&(u.photoswipe.updateSize(),u.videoWindowResizer(),u.playVideo(()=>u.user_do_click=!0))},100);is_mobile()&&setTimeout(()=>u.photoswipe.ui.hideControls(),200)}),this.photoswipe.listen("close",function(){u.progressBar.css("width",0),this.isChangeTab||(u.is_mobile()||$(".gallery_back_btn",u.$modal).trigger("click"),$('[name="abuse"]').hide(),u.is_mobile()&&($("body").removeClass("black"),u.photoswipe.initHistory()),u.removeVideo(),$(".video-container").each((e,t)=>{t.remove()})),u.is_active=!1,u.photoswipe=null}),this.photoswipe.listen("imageLoadComplete",function(e,t){$(t.container).find("img").attr("alt",t.alt)}),this.photoswipe.listen("afterChange",function(){u.progressBar.css("width",0),$(".video-container").each((e,t)=>{t.remove()}),u.replaceVideo(u.photoswipe.currItem.container);var e,t=u.photoswipe.getCurrentIndex();u.loadPubliftAdsAtPosition(t),is_mobile()&&(t=u.photoswipe.items.length,e=1+u.photoswipe.getCurrentIndex(),$("#photos_gallery .pswp__counter").html(e+" / "+t)),$("#abuse_photo_id").val(u.photoswipe.currItem.id),$("#abuse_agency").val(u.photoswipe.currItem.agency)}),$('[name="abuse"]').show();let e=setInterval(()=>{this.photoswipe.container&&(clearInterval(e),$(this.photoswipe.container).on("touchstart",e=>{var t,o=e.target;"VIDEO"===o.tagName&&(o=o.getBoundingClientRect(),t=(e.clientY||e.touches&&e.touches[0]&&e.touches[0].clientY||e.originalEvent.touches&&e.originalEvent.touches[0]&&e.originalEvent.touches[0].clientY)-o.top,o.height-40<=t)&&e.stopPropagation()}).on("touchmove",e=>{this.photoswipe.currItem.container.querySelector("video")&&1<(e.touches||e.originalEvent.touches).length&&(clearTimeout(this.resize_timeot),this.resize_timeot=setTimeout(()=>{this.photoswipe&&this.photoswipe.updateSize()},300))}))},100)}}},setActiveTab(e){$("#gallery_modal .gallery__tabs .gallery__tabs-item--active").removeClass("gallery__tabs-item--active"),$("#gallery_modal .gallery__tabs .gallery__tabs-item[data-id="+e+"]").addClass("gallery__tabs-item--active")},setVideoNotMuted:function(){var e;this.video&&(e=$(this.video_container.querySelector("#toggleMuteButton")),this.video.muted)&&(this.video.muted=!this.video.muted,e.removeClass("on"),e.addClass("off"))},removeVideo:function(){var e;this.video&&(e=$(this.video).parents(".pswp__item").find(".video-preloader")[0],this.video.pause(),this.video.removeAttribute("src"),this.video.load(),e)&&(e.style.display="block")},preloadVideoOnClick:function(e){var t,e=json_arr.photos[e],e=this.findVideoData(e);e&&((t=document.createElement("img")).style.width=0,t.style.height=0,e=this.getVideoBlock(e,t),this.setVideoNotMuted(),document.querySelector(".screen-slider").prepend(e),this.playVideo())},getCollageCoords:function(e){var t=$(e).data("collage-type"),o=parseFloat($(e).data("x1")),n=parseFloat($(e).data("x2")),i=parseFloat(e.data("y1")),a=parseFloat($(e).data("y2")),r=parseFloat($(e).data("margin-size-x")),e=parseFloat($(e).data("margin-size-y")),s=[];return 1==t?s[0]={x1:0,y1:0,x2:1,y2:1,image_num:0}:4==t?(s[0]={x1:0,y1:0,x2:o,y2:i,image_num:0},s[1]={x1:o+r,y1:0,x2:1,y2:i,image_num:1},s[2]={x1:0,y1:i+e,x2:n,y2:1,image_num:2},s[3]={x1:n+r,y1:i+e,x2:1,y2:1,image_num:3}):2==t?1==i?(s[0]={x1:0,y1:0,x2:o,y2:1,image_num:0},s[1]={x1:o+r,y1:0,x2:1,y2:1,image_num:1}):(s[0]={x1:0,y1:0,x2:1,y2:i,image_num:0},s[1]={x1:0,y1:i+e,x2:1,y2:1,image_num:1}):1==i&&1==a?(s[0]={x1:0,y1:0,x2:o,y2:1,image_num:0},s[1]={x1:o+r,y1:0,x2:o+r+n,y2:1,image_num:1},s[2]={x1:o+n+2*r,y1:0,x2:1,y2:1,image_num:2}):1==n&&1==a?(s[0]={x1:0,y1:0,x2:o,y2:i,image_num:0},s[1]={x1:o+r,y1:0,x2:1,y2:i,image_num:1},s[2]={x1:0,y1:i+e,x2:1,y2:1,image_num:2}):(s[0]={x1:0,y1:0,x2:1,y2:i,image_num:0},s[1]={x1:0,y1:i+e,x2:n,y2:1,image_num:1},s[2]={x1:n+r,y1:i+e,x2:1,y2:1,image_num:2}),s},handleTouchStart:function(e){2<=e.touches.length&&(this.initialDistance=this.getDistanceBetweenTouches(e.touches[0],e.touches[1]))},swipeAnimationInsert:function(){if(!getCookie("swipe_animation")){let e=document.createElement("img");e.src="https://restaurantguru.com/img/photoswipe/swipes.gif",e.id="swipes_animation";document.body.appendChild(e);var t=new Date;t.setDate(t.getDate()+7),document.cookie="swipe_animation=true; expires="+t.toUTCString()+"; path=/",setTimeout(function(){$(e).remove()},4040)}}};function renderRecaptcha(){ReportProblem.renderRecaptcha()}function initPopUpMenuImg(e){var t,o,n=document.getElementById("menu_photo_gallery");null!=n&&(t=json_arr.menu_photos,e={history:!1,preload:[1,1],index:e=null==e?0:e,closeOnScroll:!1},gallery_menu=new PhotoSwipe(n,PhotoSwipeUI_Default,t,e),o=[],gallery_menu.listen("gettingData",function(e,t){(t.w<1||t.h<1)&&(o[e]=new Image,o[e].onload=function(){t.w=this.width,t.h=this.height,gallery_menu.updateSize(!0)},o[e].src=t.src)}),gallery_menu.listen("close",function(){$("body").removeClass("overflow")}))}function getUrlParameter(e,t){for(var o,n=decodeURIComponent(e).split("&"),i=0;i<n.length;i++)if((o=n[i].split("="))[0]===t)return void 0===o[1]||o[1]}function initRestaurantSmallMap(e){null==e&&(e="#map_block");var t,o,e=document.querySelector(e);"undefined"!=typeof _location&&_location.lat&&_location.lng&&0!=e.clientWidth&&
210!=e.clientHeight&&-1==location.search.indexOf("noads")&&(o="en","ru_RU"==locale?o="ru":"fr_FR"==locale?o="fr":"de_DE"==locale?o="de":"es_ES"==locale?o="es":"pt_PT"==locale?o="pt":"it_IT"==locale&&(o="it"),0==(t=$("iframe",e)).length?(o='<iframe title="'+_("Location")+'" width="'+e.clientWidth+'" height="'+e.clientHeight+'" class="map_container" frameBorder="0" style="border:0" src="https://www.google.com/maps/embed/v1/place?key='+map_api_key+" &q="+_location.lat+","+_location.lng+"&zoom=15&language="+o+'" allowFullScreen></iframe>',$(e).append(o)):(t.prop("width",e.clientWidth),t.prop("height",e.clientHeight)))}var shareRestaurant={closed:!0,init:function(){var e=$(".share_button");e.click(function(e){e.preventDefault();var t={title:_("share_rest").replace("%s",$("h1").text().trim()),content:"",width:400};return popup.showLoading(t),popup.closed=!1,null!=ga&&ga("send","event","Share","open"),$.cachedScript(cdn_host+"/js/branchv2-latest.min.js").done(function(){branch.init("key_live_hoqHVxn5fzBbSNZ8JjZcRaddCDmqU3Nq",function(){shareRestaurant.setUrl(t)})}).fail(function(){shareRestaurant.setUrl(t)}),!1}),"#share"==location.hash&&(e.trigger("click"),replaceHash(""))},getSocialLinks:function(e,t){var o=encodeURI($("link[rel='canonical']").prop("href")),n='<a target="_blank" href="https://www.facebook.com/sharer/sharer.php?u='+o+'" onclick="shareRestaurant.hit(); window.open(this.href, \'\', \'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=300,width=600\');return false;" class="btn facebook" rel="nofollow" id="shareBtn">Facebook</a><a target="_blank" href="http://twitter.com/share?url='+o+'" rel="nofollow" onclick="shareRestaurant.hit();" class="btn twitter" id="twitterShare">Twitter</a><a target="_blank" href="https://t.me/share/url?url='+o+'" rel="nofollow" onclick="shareRestaurant.hit();" class="btn telegram" id="telegramShare">Telegram</a>';return n=RGPage&&RGPage.hasOwnProperty("r_user")&&RGPage.r_user?'<a target="_blank" href="https://t.me/share/url?url='+o+'" onclick="shareRestaurant.hit();" rel="nofollow" class="btn telegram" id="telegramShare">Telegram</a><a target="_blank" href="https://vk.com/share.php?url='+o+'" onclick="shareRestaurant.hit();" rel="nofollow" class="btn vk" id="vkShare">VK</a>':n},hit:function(){logH("10197")},setUrl:function(n){var i=this,e=(init_social_share(),{campaign:"Restaurant Guru",feature:"dashboard",stage:"new user",data:{$og_title:$('meta[property="og:title"]').text(),$og_description:$('meta[property="og:description"]').text(),$desktop_url:location.href}});branch.link(e,function(e,t){var o=$("h1").text(),o=_("share_rest_text").replace("%s",o);n.content='<div class="share_btns">'+i.getSocialLinks(t,o)+'<a href="#" rel="nofollow" class="btn copy" id="shareCopy" data-href="'+$("link[rel='canonical']").prop("href")+'">'+_("copy_link")+"</a></div>",FB_included(function(){popup.closed||(popup.show(n),shareClicks())})})}},popup={opts:null,desc_style:!0,show:function(e){popup.opts=e,void 0===popup.opts.width&&(popup.opts.width=0),void 0===popup.opts.height&&(popup.opts.height=0);e='<div class="review_overlay share_overlay"><div class="add_review_block"><div class="title"><span class="comment_title_common">'+popup.opts.title+'</span><span class="close_btn"></span></div>'+popup.opts.content+"</div></div>";0!==$(".review_overlay").length&&popup.close(),$("body").append(e).addClass("overflow"),$(".review_overlay .close_btn").click(popup.close),$(".review_overlay").click(function(e){$(e.target).hasClass("review_overlay")&&popup.close()})},showLoading:function(e){var t=$("h1").text();_("share_rest_text").replace("%s",t);e.content='<div class="share_btns"><div class="preloader_wrap"><img class="stub_loader" src="'+cdn_host+'/img/site/responsive/ajax-loader.gif" /></div><a target="_blank" href="https://t.me/share/url?url='+$("link[rel='canonical']").prop("href")+'" rel="nofollow" class="btn telegram" id="telegramShare">Telegram</a><a href="#" rel="nofollow" class="btn copy" id="shareCopy" data-href="'+$("link[rel='canonical']").prop("href")+'">'+_("copy_link")+"</a></div>",void 0!==e.height&&(e.height=130),popup.show(e)},onResize:function(){null!==popup.opts&&$(".review_overlay").length},isDesc:function(){return window_match_media(600,"min")},close:function(){$(".review_overlay.share_overlay").remove(),$("body").removeClass("overflow"),popup.closed=!0}},translateText={url:"https://translate.googleapis.com/translate_a/single?client=gtx&dt=t&ie=UTF-8&oe=UTF-8&pc=1&otf=1&trs=1&inputm=1&ssel=0&tsel=0&kc=1",translate_button:$(".gtranslation"),wrapper:$("#comments_container"),translate_loader:$(".gtc_loader"),is_translated:!1,translate_language:"en",translate_language_id:1,disabled_translate:!1,translate_reviews_id:[],queue:{},init:function(){null!=json_arr&&null!=json_arr.preferred_language&&(this.translate_language=json_arr.preferred_language),null!=json_arr&&null!=json_arr.preferred_language&&(this.translate_language_id=parseInt(json_arr.preferred_language_id)),this.translate_button.hasClass("disabled")&&(this.disabled_translate=!0),"#translate_comments"!==location.hash||$this.disabled_translate||this.translate_all();let e=$("#translate-text");e.on("click",()=>this.translateDescription($(".description"),e)),this.translate_button.on("click",()=>!this.translate_button.hasClass("disabled")&&this.translate_all())},get_translate_review_id:function(e,t){var o=$(this).attr("class")?$(this).attr("class"):"";return e.data("id")+"_"+o.replace(" ","_")},add_translate_review_id:function(e,t){e=this.get_translate_review_id(e,t);jQuery.inArray(e,this.translate_reviews_id)||this.translate_reviews_id.push(e)},remove_translate_review_id:function(e,t){let o=this.get_translate_review_id(e,t);jQuery.inArray(o,this.translate_reviews_id)&&(this.translate_reviews_id=this.translate_reviews_id.filter(e=>e!=o))},translateDescription:function(t,o){var e;showInformation($(".wrapper_description").find("div:first"),$(".show_restaurants_review")),0==t.find(".gtranslated").length?(e=t.html(),$.ajax({url:this.url,data:{q:e,sl:"en",tl:this.translate_language},success:function(e){var n="";
21null!=e[0]&&0!=e[0].length&&e[0].forEach(function(e,t,o){n+=e[0]}),t.find("div:first").prepend('<div class="gtranslated"></div>'),t.find("div:first > :not(.gtranslated)").hide(),t.find(".gtranslated").html(n.replace(/<\s{0,2}\/\s{0,2}([a-z0-9]+)(\s{0,2})?>/gi,"</$1>").replace(/& nbsp;/gi," ").replace(/& amp;/gi,"&")),o.text(_("show_original")).addClass("translated")}})):o.hasClass("translated")?(t.find("div:first > :not(.gtranslated)").show(),t.find(".gtranslated").hide(),o.text(_("translate_with_google")).removeClass("translated")):(t.find("div:first > :not(.gtranslated)").hide(),t.find(".gtranslated").show(),o.text(_("show_original")).addClass("translated"))},translate_all:function(){this.is_translated?($(".o_review").each((e,t)=>this.show_original($(t))),this.translate_button.html(_("translate_comments")),this.is_translated=!1):(this.translate_button.addClass("disabled"),$(".o_review").each((e,t)=>this.translate($(t))))},getElementsForTranslate:function(e){return e.find(".text_full").length?e.find(".text_full > .text_group").length?e.find(".text_full > .text_group"):e.find(".text_full"):e.find(".full_review").length?e.find(".text .text_snippet, .text .full_review"):[]},translate:function(a){var e=a.data("lang_id");void 0!==e&&this.translate_language_id!=parseInt(e)&&(0==a.find(".gtranslated").length?(e=this.getElementsForTranslate(a)).length&&(this.queue[a.data("id")]=e.length,e.each((e,o)=>{let i=$(o);o.classList.length||i.addClass("empty_span"),this.translate_loader.show(),this.add_translate_review_id(a,o),$.ajax({url:this.url,data:{q:i.html(),sl:"auto",tl:this.translate_language},success:e=>{this.remove_translate_review_id(a,o);let n="";null!=e[0]&&0!=e[0].length&&e[0].forEach(function(e,t,o){n+=e[0]});var e=$(o).is(":visible")?"":'style="display: none;"',t=n.replace(/<\/\s+.{0,2}b(\s.{0,2})?>/gi,"</b>").replace(/<\s*\/b>/gi,"</b>").replace(/& nbsp;/gi," ").replace(/& amp;/gi,"&").replace(/&lt;/gi,"<").replace("&lt; span","<").replace(/&gt;/gi,">").replace("&gt;",">").replace("< /","</").replace("< span","<span").replace(/&ZeroWidthSpace;/gi,"").replace("&ZeroWidthSpace;","");i.before('<span class="gtranslated '+i.attr("class")+'" '+e+">"+t+"</span>"),i.is(":visible")&&i.hide(),a.addClass("translated"),--this.queue[a.data("id")],this.queue[a.data("id")]||(delete this.queue[a.data("id")],Object.keys(this.queue).length)||(this.translate_loader.hide(),this.is_translated=!0,this.translate_button.html(_("show_original")),this.translate_button.removeClass("disabled"))},error:()=>{this.is_translated=!1,$(".translate_button_container").addClass("error"),setTimeout(function(){$(".translate_button_container").removeClass("error")},2500),this.translate_loader.hide()}})})):(this.getElementsForTranslate(a).each((e,t)=>{t=$(t);t.hasClass("gtranslated")?0!==a.find(".full_review").length&&(a.find(".fade").length?t.hasClass("full_review"):t.hasClass("text_snippet"))||t.show():t.hide()}),this.is_translated=!0,this.translate_button.html(_("show_original")),this.translate_button.removeClass("disabled")))},show_original:function(o){this.getElementsForTranslate(o).each((e,t)=>{t=$(t);t.hasClass("gtranslated")?t.hide():0!==o.find(".full_review").length&&(o.find(".fade").length?t.hasClass("full_review"):t.hasClass("text_snippet"))||t.show()})},translate_ajax:function(){var e=this;e.translate_button.removeClass("disabled"),e.is_translated&&$(".o_review:not(.translated)").each(function(){e.translate($(this))})}};function openGalleryMenu(e){initPopUpMenuImg(e),gallery_menu.init(),$("body").addClass("overflow")}function FB_included(e){"undefined"==typeof FB&&RGPage&&RGPage.hasOwnProperty("r_user")&&!RGPage.r_user?setTimeout(function(){FB_included(e)},100):e()}function wideRestRotation(){}function narrowRestRotation(){var e,t,o,n,i,a;$("body").hasClass("mobile_template")||(e=$(".more_ranks_show.more_ranks_load"),t=isCollage()?$(".screen-slider"):$(".screens_list_wrap"),o=$(".breadcrumbs"),n=$("div.recent"),i=$("div.info-block"),a=$("#ratings"),window_match_media(740,"max")?($(".left_bottom").prepend(a),$("#ranks .r_prime div").hide(),$("#ranks .r_prime div:first").show(),e.length&&!$("#ranks .r_prime div:first").find(".more_ranks_show").length&&$("#ranks .r_prime div:first").append(e),t.length&&(a.length?a.after(t):$(".left_column").prepend(t),t.after($(".actions_mobile"))),o.length&&($(".info-block>.short_info").length?$(".info-block>.short_info").after(o):i.append(o))):($("#ranks .r_prime div").show(),e.length&&!$("#ranks .r_prime div").last().find(".more_ranks_show").length&&$("#ranks .r_prime div").last().append(e),t.length&&$("#gallery_modal").before(t),o.length&&n.length&&$(".wrapper_header").after(o)))}
21function hideEmptyNavbar(){var e=$("#stickyNav>.content");0===e.children().length&&e.closest(".menu_nav").hide()}function userScale(){var e=$('head meta[name="viewport"]');is_mobile()&&window_match_media(740,"max")?e.attr("content","width=device-width, initial-scale=1, maximum-scale=4.0, user-scalable=1"):e.attr("content","width=device-width, initial-scale=1")}function rotationElems(e,t,o){}function orderHint(){var e=$(".orderBtn"),t=e.find("span"),o='<span class="wrapper_order_hint">\n\t\t\t\t\t<span class="hint order_hint">\n\t\t\t\t\t\t<span class="text_overflow">'+e.find("span").html()+"</span>\n\t\t\t\t\t</span>\n\t\t\t\t</span>";e.on("mouseenter",function(){e.width()<=t.width()&&e.after(o)}),e.on("mouseleave ",function(){$(".wrapper_order_hint").remove()})}function check_awards_code_submit(){var e=$("#request_code").val(),t=$("#show_unknown_code");t.hide();try{$.ajax({type:"POST",url:"/ajax/check_award_code",dataType:"json",data:{code:e},success:function(e){"ok"===e.status?window.location=e.url:t.show()}})}catch(e){t.show()}return!1}function changeEmptyAvatar(){let o=["#B7621C","#116E6E","#169216","#DBA375","#61B6B6","#6BC96B","#DB5050","#895A32","#286E28","#B71C1C"],e,t=1,n=setInterval(function(){e=$(".not_loaded"),t<=200?(0<e.length&&e.each(function(){var e=$
21(this).data("author-id")?$(this).data("author-id").toString().slice(-1):9,t=$(this).attr("alt")?$(this).attr("alt").slice(0,1):"U";$(this).parent().prepend('<div class="icon50 block_ava"  style="background-color: '+o[e]+'">'+t+"</div>"),$(this).remove()}),t++):clearInterval(n)},100)}function iframeEventsFixer(){var e,t=document.getElementById("recommended_dishes");null!==t&&(e=t.contentWindow.document.getElementById("my-swiper"),t.addEventListener("mouseleave",function(){e.swiper.slideToClosest(520),e.swiper.touchEventsData.allowTouchCallbacks=!1,e.swiper.touchEventsData.isMoved=!1,e.swiper.touchEventsData.isTouched=!1,e.swiper.touchEventsData.startMoving=!1,e.classList.remove("active-hover")}))}function hoverSwiper(){if(1231<=$(window).width()){var o=document.getElementById("recommended_dishes");if(null!==o){let a=o.contentWindow.document.getElementById("my-swiper"),r=a.swiper,e=r.activeIndex,s=r.slides[0],l=r.slides[1],c=r.slides[2],d=r.slides[3],u=r.slides[4],t=r.slides;var n=a.querySelector(".advertising-from-competitors__swiper-button-prev"),i=a.querySelector(".advertising-from-competitors__swiper-button-next");function f(e,t,o,n,i,a,r,s,l,c){e===t&&$(o).hasClass(n)&&($(i)[a](r),$(s)[l](c))}function g(e,t,o,n,i,a,r,s,l,c){e.addEventListener(t,function(){o===n&&($(i)[a](r),$(s)[l](c))})}function v(e,t,o,n,i,a,r){e.addEventListener(t,function(){o===n&&$(i)[a](r)})}function w(e,t,o,n,i,a,r,s,l,c,d,u){e.addEventListener(t,function(){o===n&&$(i).hasClass(a)&&($(r)[s](l),$(c)[d](u))})}function b(e,t,o,n,i,a,r,s,l,c){e.addEventListener(t,function(){o===n?$(i)[a](r):$(s)[l](c)})}let m=function(){0===e&&$(d).addClass("active-current-hovered")},p=function(){0===e&&$(a).removeClass("active-hover")},h=function(){0===e&&$(a).addClass("active-hover")},_=function(){0===e&&($(s).addClass("active-current-hovered"),$(a).addClass("active-hover"))};i.addEventListener("mouseenter",m),l.addEventListener("mouseenter",p),s.addEventListener("mouseenter",h),n.addEventListener("mouseenter",_),o.addEventListener("mouseleave",function(){$(t).removeClass("active-current-hovered"),$(a).removeClass("active-hover")}),r.on("slideNextTransitionEnd",function(e){var t=r.activeIndex;f(t,0,d,"active-current-hovered",d,"removeClass","active-current-hovered",u,"addClass","active-current-hovered"),2===t&&$(u).hasClass("active-current-hovered")&&$(a).addClass("active-hover-last-slide"),f(t,1,s,"active-current-hovered",s,"removeClass","active-current-hovered",l,"addClass","active-current-hovered")}),r.on("slidePrevTransitionEnd",function(){1===r.activeIndex&&!$(u).hasClass("active-current-hovered")&&$(a).hasClass("active-hover-last-slide")&&$(a).removeClass("active-hover-last-slide")}),r.on("reachBeginning",function(){0===r.activeIndex&&$(d).hasClass("active-current-hovered")&&$(d).removeClass("active-current-hovered")}),r.on("slideChange",function(e){let t=r.activeIndex;var o=a.querySelector(".advertising-from-competitors__swiper-button-next"),n=a.querySelector(".advertising-from-competitors__swiper-button-prev");let i=!o.contains(e.target);e=!n.contains(e.target);o.removeEventListener("mouseenter",m),l.removeEventListener("mouseenter",p),s.removeEventListener("mouseenter",h),n.removeEventListener("mouseenter",_);s.addEventListener("mouseenter",function(){0===t&&$(a).addClass("active-hover")}),n.addEventListener("mouseenter",function(){0===t?($(s).addClass("active-current-hovered"),$(l).removeClass("active-current-hovered"),$(a).addClass("active-hover")):(2===t&&$(l).addClass("active-current-hovered"),$(s).removeClass("active-current-hovered"),$(a).removeClass("active-hover"))}),0===t&&e&&$(a).removeClass("active-hover"),o.addEventListener("mouseenter",function(){0!==t&&(0!==t||$(u).hasClass("active-current-hovered"))||($(d).addClass("active-current-hovered"),$(a).removeClass("active-hover-last-slide"))}),g(o,"click",t,0,d,"removeClass","active-current-hovered",a,"removeClass","active-hover-last-slide"),g(n,"click",t,2,l,"addClass","active-current-hovered",s,"removeClass","active-current-hovered"),1===t&&i&&$(l).hasClass("active-current-hovered")&&$(a).addClass("active-hover"),g(c,"mouseenter",t,1,l,"removeClass","active-current-hovered",a,"removeClass","active-hover"),g(d,"mouseenter",t,1,l,"removeClass","active-current-hovered",a,"removeClass","active-hover"),g(u,"mouseenter",t,1,l,"removeClass","active-current-hovered",a,"removeClass","active-hover"),g(o,"mouseenter",t,1,u,"addClass","active-current-hovered",d,"removeClass","active-current-hovered"),v(o,"click",t,1,u,"addClass","active-current-hovered"),g(n,"mouseenter",t,1,l,"addClass","active-current-hovered",a,"addClass","active-hover"),v(n,"click",t,1,l,"removeClass","active-current-hovered"),g(n,"click",t,1,a,"addClass","active-hover",s,"addClass","active-current-hovered"),b(l,"mouseenter",t,1,a,"addClass","active-hover",a,"removeClass","active-hover"),v(l,"mouseleave",t,1,a,"removeClass","active-hover"),w(o,"mouseenter",t,1,u,"active-current-hovered",a,"removeClass","active-hover-last-slide",d,"removeClass","active-current-hovered"),v(o,"mouseenter",t,2,d,"removeClass","active-current-hovered"),b(u,"mouseenter",t,2,a,"addClass","active-hover-last-slide",a,"removeClass","active-hover-last-slide"),v(u,"mouseleave",t,2,a,"removeClass","active-hover-last-slide"),g(o,"mouseenter",t,2,a,"addClass","active-hover-last-slide",u,"addClass","active-current-hovered"),o.addEventListener("mouseleave",function(){2===t&&i&&!$(u).hasClass("active-hover-last-slide")&&($(a).removeClass("active-hover-last-slide"),$(u).removeClass("active-current-hovered"))}),w(o,"click",t,1,u,"active-current-hovered",a,"addClass","active-hover-last-slide",d,"removeClass","active-current-hovered")}),t.forEach(function(e,t){e.addEventListener("mouseenter",function(){this.classList.add("active-current-hovered")}),e.addEventListener("mouseleave",function(){this.classList.remove("active-current-hovered")})}),g(i,"click",e,0,d,"removeClass","active-current-hovered",u,"addClass","active-current-hovered")}}}function adaptiveSlideSwiper(){var e=document.getElementById("recommended_dishes");null!==e&&null!==(e=e.contentWindow.document.getElementById("my-swiper"))&&($(window).width()<=1220?$(e).addClass("active-no-animate"):$(e).removeClass("active-no-animate"),$(window).width()<=740&&200<=$(window).width()?$(e).addClass("active-width-slide-mob"):$(e).removeClass("active-width-slide-mob"),$(window).width()<=1030&&741<=$(window).width()?$(e).addClass("active-width-slide-tablet"):$(e).removeClass("active-width-slide-tablet"))}function firstTextGroupEl(){$(".o_review.hide_txt").each(function(){var e=$
21(this).find(".text_full"),t=e.find(".text_group");(75<e.find(".text_group").first().height()||0===t.length)&&$(this).addClass("active-big-first-text_group")})}(()=>{var t,o,e,n=document.getElementById("recommended_dishes");function i(){e=e||setInterval(function(){var e=t.body.scrollHeight;e!==o&&(o=e,n.style.height=e+"px")},500)}function a(){e&&(clearInterval(e),e=null)}null!==n&&(t=n.contentWindow.document,o=(n.contentDocument||n.contentWindow.document).documentElement.scrollHeight,window.addEventListener("orientationchange",function(){(90===window.orientation||0===window.orientation)&&(a(),i(),setTimeout(function(){a()},5e3))}))})(),$(document).ready(function(){firstTextGroupEl()}),$(document).ready(function(){let e=$("#group-link-desktop");0<e.length&&$(document).on("click","#link-group-mobile",function(){window.location.href=e.attr("href")})});let rest_header_btns={counters:{float_buttons:{phone:9797,reserve:9798},control:{phone:9799,reserve:9800}},container:null,bookBtn:null,callBtn:null,menuBtn:null,directionBtn:null,appearPoint:null,mainBtnsContainer:null,total_btns:0,init:function(){var e,t,o,n,i=this;document.body.classList.contains("merged_template")||(e=".whatsapp_btn",t="#call_wrap>.call",o=".a_button_wrap.menu>.menuBtn",n=(n=document.querySelector(".direction_link__txt"))?n.textContent:"",i.totalBtnsCounter([e,t,o]),i.mainBtnsContainer=document.querySelector(".buttons_wrapper"),i.container=document.createElement("div"),i.container.id="head_btns",document.querySelector("body").appendChild(i.container),i.addNewBtn(i.callBtn,t,"head_btns__tel",_("call_short")),i.addNewBtn(i.bookBtn,e,"head_btns__write",_("Write")),i.addNewBtn(i.directionBtn,".direction_link","head_btns__direction",n),i.addNewBtn(i.menuBtn,o,"head_btns__menu",_("menu_short")),document.addEventListener("scroll",i.onScroll))},addNewBtn(e,t,o,n){document.querySelector(t)&&((e=this.makeBtn(o)).textContent=1<this.total_btns?n:this.getContent(t),e.addEventListener("click",function(){document.querySelector(t).click()}))},makeBtn(e){var t=document.createElement("span");return e&&(t.className=e),!!this.container&&(this.container.appendChild(t),t)},getContent(e){var e=document.querySelector(e);if(!e)return!1;let t=e.querySelector("span");return(t=t||e.querySelector("h2"))&&0<(e=t.textContent).length?e:void 0},onScroll(){var e;rest_header_btns.mainBtnsContainer&&(e=$(rest_header_btns.mainBtnsContainer).offset().top+$(rest_header_btns.mainBtnsContainer).outerHeight()-$(".wrapper_header").outerHeight(),rest_header_btns.appearPoint=e!==rest_header_btns.appearPoint?e:rest_header_btns.appearPoint,$(window).scrollTop()>rest_header_btns.appearPoint?$(rest_header_btns.container).css("transform","translateY(0)"):$(rest_header_btns.container).css("transform","translateY(120%)"),rest_header_btns.menUploadPopupMoving())},menUploadPopupMoving(){var e=$("#menu_upload_popup");e.length&&($(window).scrollTop()>rest_header_btns.appearPoint?e.addClass("menu_upload_popup__sticky"):e.removeClass("menu_upload_popup__sticky"))},incPhoneCounter(){if(!RGPage.hasOwnProperty("float_buttons_split_test_group")||!this.counters.hasOwnProperty(RGPage.float_buttons_split_test_group))return!1;logH(this.counters[RGPage.float_buttons_split_test_group].phone)},incReserveCounter(){if(!RGPage.hasOwnProperty("float_buttons_split_test_group")||!this.counters.hasOwnProperty(RGPage.float_buttons_split_test_group))return!1;logH(this.counters[RGPage.float_buttons_split_test_group].reserve)},totalBtnsCounter(e){this.total_btns=e.filter(e=>document.querySelector(e)).length}},cuisines_lists={show_btn:null,hide_btn:null,small_container:null,full_container:null,init:function(){let t=this;t.show_btn=$("body").hasClass("merged_template")?$(".more_cuisines__show"):$("#more_cuisines__show"),t.hide_btn=$("body").hasClass("merged_template")?$(".more_cuisines__hide"):$("#more_cuisines__hide"),t.small_container=$(".cuisine_shown"),t.full_container=$(".cuisine_hidden"),t.show_btn.length&&t.hide_btn.length&&t.small_container.length&&(t.show_btn.each(function(){$(this).on("click",function(e){t.show_event(e)})}),t.hide_btn.each(function(){$(this).on("click",function(e){t.hide_event(e)})}))},show_event:function(e){e=$(e.target).closest(".cuisine_wrapper");e.find(".cuisine_shown").hide(),e.find(".cuisine_hidden").show()},hide_event:function(e){e=$(e.target).closest(".cuisine_wrapper");e.find(".cuisine_shown").show(),e.find(".cuisine_hidden").hide()}},rest_types={show_btn:null,hide_btn:null,main_container:null,init:function(){var e=this;e.main_container=$("#types"),e.show_btn=e.main_container.find(".all_types__show"),e.hide_btn=e.main_container.find(".all_types__hide"),e.show_btn.on("click",e.show_event),e.hide_btn.on("click",e.hide_event)},show_event:function(){rest_types.show_btn.hide(),rest_types.main_container.find(".hidden").each(function(){$(this).show()})},hide_event:function(){rest_types.show_btn.show(),rest_types.main_container.find(".hidden").each(function(){$(this).hide()})}},MenuPopup=($(document).ready(function(){let t=$(".js-icon_tooltip"),o=$(".tooltip_for_business"),n=is_mobile()?$(".wrapper_header"):$(".header");
21var e=$(".container_tooltip");let i=$('<span class="tooltip_for_business">'+_("business_tooltip")+"</span>");function a(e){o.removeClass("shown upside"),e.addClass("shown");var t=e.hasClass("js-icon_tooltip")?e:e.find(".js-icon_tooltip");e[0].getBoundingClientRect().top-n.height()-115<=0?t.addClass("upside"):t.removeClass("upside"),i.prependTo(e)}function r(e){(e||o).removeClass("shown upside"),i.remove()}is_mobile()?(t.on("click",function(e){e.preventDefault();e=$(this);(e.hasClass("shown")?r:a)(e)}),$(document).on("touchstart",function(e){$(e.target).hasClass("js-icon_tooltip")||r(t)})):(e.on("mouseenter",".js-link_tooltip",function(){a($(this).prev(".js-icon_tooltip"))}),e.on("mouseleave",".js-link_tooltip",function(){r($(this).prev(".js-icon_tooltip"))}),e.on("mouseenter",".js-icon_tooltip",function(){a($(this))}),e.on("mouseleave",".js-icon_tooltip",function(){r($(this))})),action_tooltips()}),{init:function(){$(".call").on("click",function(e){if(e.preventDefault(),!(0<$("#menu_upload_popup").length||0==$("#call_wrap").data("popup"))){let t=$(this),o=t.find("span").text().replace(/[ -]/g,"");var n,i,a,e=t.attr("href"),e='<div id="menu_upload_popup" title=""><div class="mup_wrapper"><p>'+_("phone_menu_disclaimer2")+'</p><div class="btn_wrap"><a href="'+e+'" class="mup_btn">'+o+'</a><span title="Copy" class="copy_btn">'+_("copy_number")+'</span></div><span class="mup_cross"></span></div></div>';t.addClass("mup_shown"),$("body").hasClass("merged_template")?((window_match_media(740)?$("body"):t.closest("#call_wrap")).append(e),$("#menu_upload_popup").addClass("mup_desk").find(".mup_btn").text(_("call_short"))):is_mobile()?(i=t.offset().top+t.outerHeight()+3,$("body").append(e),(n=$("#menu_upload_popup")).css({top:i+"px"}),window_match_media(551,"min")&&(i=t.outerWidth(),a=t.offset().left,n.addClass("mup_tablet"),n.css({width:i+"px"}),n.css({left:a+"px"}),n.find(".mup_btn").text(_("call_short"))),MenuPopup.changeDirection(n,t)):(t.closest("#call_wrap").append(e),$("#menu_upload_popup").addClass("mup_desk").find(".mup_btn").text(_("call_short"))),rest_header_btns.menUploadPopupMoving(),$(".mup_cross").on("click",function(e){e.preventDefault(),e.stopPropagation(),$(this).closest("#menu_upload_popup").remove(),t.removeClass("mup_shown mup_on_top")}),$(".copy_btn").on("click",function(){var e,t=o.replace(/[ -]/g,"");navigator.clipboard?(navigator.clipboard.writeText(t).then(function(e){console.error("Async: Could not copy text: ",e)}),$(this).addClass("mup_copied").text(_("copied_number"))):(e=$("<textarea style='position: fixed; height: 0; width: 0; top: 0'>"),$("body").after(e),e.val(t).select(),document.execCommand("copy"),e.remove())})}}),$(document).on("click",function(e){$(e.target).is("#menu_upload_popup")||$(e.target).closest("#menu_upload_popup").length||$(e.target).is("#call_wrap")||$(e.target).is(".head_btns__tel")||$(e.target).closest("#call_wrap").length||MenuPopup.hidePopup()}),$(window).on("resize",function(){MenuPopup.hidePopup()}),$(window).on("orientationchange",function(){MenuPopup.hidePopup()})},hidePopup:function(){$("#menu_upload_popup").remove(),$(".call").removeClass("mup_shown mup_on_top")},changeDirection:function(e,t){var o=$(".wrapper_header").outerHeight(),n=e.offset().top-$(window).scrollTop(),i=e.outerHeight(),a=$(window).outerHeight(),r=t.offset().top,s=i+15+o<=r,r=r-($(window).scrollTop()+o)>i/2+35;a<n+i&&s&&r&&(o=t.offset().top-(i+15),e.css({top:o+"px",margin:"0"}),t.addClass("mup_on_top"))}});function action_tooltips(){"undefined"!=typeof Tooltip&&(new Tooltip(_("save_to_favorites"),".add_to_wishlist_btn ",{alignElement:".action_buttons",alignX:"right",specClass:"tooltip__action-btns"}),new Tooltip(_("add_compare"),".btn_compare.add_to_compare ",{alignElement:".action_buttons",alignX:"right",specClass:"tooltip__action-btns"}),new Tooltip(_("save_link"),".btn_share.share_button ",{alignElement:".action_buttons",alignX:"right",specClass:"tooltip__action-btns"}))}function rateTapScroll(){var e=$(".card__rating-stars--tapscroll"),t=$("#ratings");
21e.length&&t.length&&e.on("click",function(){var e=$(".wrapper_header").outerHeight(),t=$(".pierre-assist-button").length?$(".pierre-assist-button").outerHeight():0,e=$("#ratings").offset().top-(e+t);$("html, body").animate({scrollTop:e},300)})}function showHideSchedule(){$(document).off("click.schedule").on("click.schedule",".work_time > .div_h3",function(){$(this).closest(".work_time").toggleClass("work_time__open")})}var rfq={conf:{u:0,r:0},questions:[],current_question_id:0,questions_block:".poll_wrapper",html:"",cuisine_question_yes_limit:1,cuisine_question_counter:0,page_height:100,init:function(e){$(this.questions_block).hide(),$.extend(!0,this.conf,e);let t=this,o=(is_mobile()&&(t.page_height=window.innerHeight),function(){window.scrollY>=t.page_height&&(t.getQuestions(t.conf),$(document).off("scroll",o))});$(document).on("scroll",o),document.documentElement.scrollHeight-window.innerHeight<=window.innerHeight&&(t.getQuestions(t.conf),$(document).off("scroll",o))},getQuestions:function(e){let t=this;$.ajax({type:"POST",url:"/ajax/getRFQ",dataType:"json",data:e,success:function(e){e.success&&t.showResults(e)}})},showResults:function(e){null!=e.html&&(this.questions=e.questions,this.html=e.html,this.renderNextQuestion())},sendLog:function(e){return $.ajax({type:"POST",url:"/ajax/logRFQ",dataType:"json",data:e})},getNextQuestion:function(){var e;return 0<this.questions.length?(e=this.questions.shift())&&"cuisine"==e.type&&this.cuisine_question_counter>=this.cuisine_question_yes_limit?this.getNextQuestion():e:null},renderNextQuestion:function(){var e,t,o=this.getNextQuestion();o?($(this.questions_block).html(this.html),o.img_url&&$(this.questions_block).find(".poll_img img").attr("src",o.img_url),$(this.questions_block).find(".poll_text").text(o.text),$(this.questions_block).find(".poll_btns").attr("data-id",o.id),$(this.questions_block).find(".poll_btns").attr("data-type",o.type),this.bindActions(),$(this.questions_block).show()):(o=$(this.questions_block).find(".poll"),e=$(this.questions_block).find(".poll_img img"),t=$(this.questions_block).find(".poll_text"),e.attr("src","/img/tick.png").attr("alt","submitted"),o.addClass("submitted"),t.text(_("feature_poll_thanks")),$(this.questions_block).delay(3e3).fadeOut())},bindActions:function(){let i=this;$(this.questions_block).off("click",".poll_btn"),$(this.questions_block).on("click",".poll_btn",function(e){var e=$(e.currentTarget),t=$(i.questions_block).find(".poll_btns").data("id"),o=$(i.questions_block).find(".poll_btns").data("type");let n=null;e.hasClass("poll_btn--yes")?(n="yes","cuisine"==o&&i.cuisine_question_counter++):e.hasClass("poll_btn--no")?n="no":e.hasClass("poll_btn--hesitate")&&(n="hesitate"),n&&(i.sendLog({u:i.conf.u,r:i.conf.r,q:t,a:n}),i.renderNextQuestion())})}};function init_social_share(){(a=document.createElement("script")).type="text/javascript",a.async=!0,a.src="https://apis.google.com/js/plusone.js";var e=document.getElementsByTagName("script")[0];e.parentNode.insertBefore(a,e),window.___gcfg={lang:"en_US",parsetags:"onload"},(a=document.createElement("script")).type="text/javascript",a.async=!0,a.src="https://apis.google.com/js/platform.js",(e=document.getElementsByTagName("script")[0]).parentNode.insertBefore(a,e),RGPage&&RGPage.hasOwnProperty("r_user")&&RGPage.r_user||("undefined"!=typeof FB?FB.XFBML.parse():((a=document.createElement("script")).type="text/javascript",a.async=!0,a.src="https://connect.facebook.net/en_US/sdk.js#version=v2.2&status=true&cookie=true&xfbml=true",document.head.appendChild(a)),(a=document.createElement("script")).type="text/javascript",a.async=!0,a.src="https://platform.twitter.com/widgets.js",(e=document.getElementsByTagName("script")[0]).parentNode.insertBefore(a,e))}function init_fb_share(){"undefined"!=typeof FB?FB.XFBML.parse():((a=document.createElement("script")).type="text/javascript",a.async=!0,a.src="https://connect.facebook.net/en_US/sdk.js#version=v2.2&status=true&cookie=true&xfbml=true",document.head.appendChild(a))}function shareClicks(){$("a#shareBtn").on("click",function(){return null!=FB&&(FB.init({status:!0,cookie
21:!0,xfbml:!0,version:"v2.10",appId:"2033474010272363"}),FB.ui({method:"share",display:"popup",href:$(this).data("href")},function(e){e&&!e.error_message&&(popup.close(),$.ajax({type:"GET",url:"/ajax/lshare",data:{provider:"Facebook",uhash:this.href},dataType:"html",success:function(e){}}))})),!1}),$("#twitterShare").on("click",function(){return window.open(this.href,"","toolbar=0, status=0, width=548, height=325").opener=null,$.ajax({type:"GET",url:"/ajax/lshare",data:{provider:"Twitter",uhash:this.href},dataType:"html",success:function(e){}}),!1}),$("#shareCopy").on("click",function(){copyToClipboard($(this).data("href")),$("<span>").addClass("tooltip").text(_("copied")).appendTo($(this));var e=$(this).find(".tooltip");return setTimeout(function(){e.remove()},3e3),!1})}function setSelectTextarea(e){var t,o,n,i;navigator.userAgent&&/iPad|iPhone|iPod/.test(navigator.userAgent)?(t=e.contentEditable,o=e.readOnly,e.contentEditable=!0,e.readOnly=!0,(n=document.createRange()).selectNodeContents(e),(i=window.getSelection()).removeAllRanges(),i.addRange(n),e.setSelectionRange(0,300),e.contentEditable=t,e.readOnly=o):e.select()}function copyToClipboard(i){return navigator.clipboard&&navigator.clipboard.writeText?navigator.clipboard.writeText(i).then(()=>gtag_report_conversion()):new Promise((e,t)=>{var o=document.createElement("textarea");o.value=i,o.style.position="fixed",o.style.top="0",o.style.left="0",o.style.width="1px",o.style.height="1px",o.style.opacity="0",document.body.appendChild(o),setSelectTextarea(o);try{var n=document.execCommand("copy");document.body.removeChild(o),n?(gtag_report_conversion(),e()):t(new Error("copy command was unsuccessful"))}catch(e){document.body.removeChild(o),t(e)}})}((e,t)=>{"function"==typeof define&&define.amd?define("ev-emitter/ev-emitter",t):"object"==typeof module&&module.exports?module.exports=t():e.EvEmitter=t()})("undefined"!=typeof window?window:this,function(){function e(){}var t=e.prototype;return t.on=function(e,t){var o;if(e&&t)return-1==(o=(o=this._events=this._events||{})[e]=o[e]||[]).indexOf(t)&&o.push(t),this},t.once=function(e,t){var o;if(e&&t)return this.on(e,t),((o=this._onceEvents=this._onceEvents||{})[e]=o[e]||{})[t]=!0,this},t.off=function(e,t){e=this._events&&this._events[e];if(e&&e.length)return-1!=(t=e.indexOf(t))&&e.splice(t,1),this},t.emitEvent=function(e,t){var o=this._events&&this._events[e];if(o&&o.length){o=o.slice(0),t=t||[];for(var n=this._onceEvents&&this._onceEvents[e],i=0;i<o.length;i++){var a=o[i];n&&n[a]&&(this.off(e,a),delete n[a]),a.apply(this,t)}return this}},t.allOff=function(){delete this._events,delete this._onceEvents},e}),((t,o)=>{"function"==typeof define&&define.amd?define(["ev-emitter/ev-emitter"],function(e){return o(t,e)}):"object"==typeof module&&module.exports?module.exports=o(t,require("ev-emitter")):t.imagesLoaded=o(t,t.EvEmitter)})("undefined"!=typeof window?window:this,function(t,e){function a(e,t){for(var o in t)e[o]=t[o];return e}function r(e,t,o){var n,i;return this instanceof r?(n="string"==typeof(n=e)?document.querySelectorAll(e):n)?(this.elements=(i=n,Array.isArray(i)?i:"object"==typeof i&&"number"==typeof i.length?c.call(i):[i]),this.options=a({},this.options),"function"==typeof t?o=t:a(this.options,t),o&&this.on("always",o),this.getImages(),s&&(this.jqDeferred=new s.Deferred),void setTimeout(this.check.bind(this))):void l.error("Bad element for imagesLoaded "+(n||e)):new r(e,t,o)}function o(e){this.img=e}function n(e,t){this.url=e,this.element=t,this.img=new Image}var s=t.jQuery,l=t.console,c=Array.prototype.slice,d=((r.prototype=Object.create(e.prototype)).options={},r.prototype.getImages=function(){this.images=[],this.elements.forEach(this.addElementImages,this)},r.prototype.addElementImages=function(e){"IMG"==e.nodeName&&this.addImage(e),!0===this.options.background&&this.addElementBackgroundImages(e);var t=e.nodeType;if(t&&d[t]){for(var o=e.querySelectorAll("img"),n=0;n<o.length;n++){var i=o[n];this.addImage(i)}if("string"==typeof this.options.background)for(var a=e.querySelectorAll(this.options.background),n=0;n<a.length;n++){var r=a[n];
21this.addElementBackgroundImages(r)}}},{1:!0,9:!0,11:!0});return r.prototype.addElementBackgroundImages=function(e){var t=getComputedStyle(e);if(t)for(var o=/url\((['"])?(.*?)\1\)/gi,n=o.exec(t.backgroundImage);null!==n;){var i=n&&n[2];i&&this.addBackground(i,e),n=o.exec(t.backgroundImage)}},r.prototype.addImage=function(e){e=new o(e);this.images.push(e)},r.prototype.addBackground=function(e,t){e=new n(e,t);this.images.push(e)},r.prototype.check=function(){function t(e,t,o){setTimeout(function(){n.progress(e,t,o)})}var n=this;return this.progressedCount=0,this.hasAnyBroken=!1,this.images.length?void this.images.forEach(function(e){e.once("progress",t),e.check()}):void this.complete()},r.prototype.progress=function(e,t,o){this.progressedCount++,this.hasAnyBroken=this.hasAnyBroken||!e.isLoaded,this.emitEvent("progress",[this,e,t]),this.jqDeferred&&this.jqDeferred.notify&&this.jqDeferred.notify(this,e),this.progressedCount==this.images.length&&this.complete(),this.options.debug&&l&&l.log("progress: "+o,e,t)},r.prototype.complete=function(){var e=this.hasAnyBroken?"fail":"done";this.isComplete=!0,this.emitEvent(e,[this]),this.emitEvent("always",[this]),this.jqDeferred&&(e=this.hasAnyBroken?"reject":"resolve",this.jqDeferred[e](this))},(o.prototype=Object.create(e.prototype)).check=function(){return this.getIsImageComplete()?void this.confirm(0!==this.img.naturalWidth,"naturalWidth"):(this.proxyImage=new Image,this.proxyImage.addEventListener("load",this),this.proxyImage.addEventListener("error",this),this.img.addEventListener("load",this),this.img.addEventListener("error",this),void(this.proxyImage.src=this.img.src))},o.prototype.getIsImageComplete=function(){return this.img.complete&&this.img.naturalWidth},o.prototype.confirm=function(e,t){this.isLoaded=e,this.emitEvent("progress",[this,this.img,t])},o.prototype.handleEvent=function(e){var t="on"+e.type;this[t]&&this[t](e)},o.prototype.onload=function(){this.confirm(!0,"onload"),this.unbindEvents()},o.prototype.onerror=function(){this.confirm(!1,"onerror"),this.unbindEvents()},o.prototype.unbindEvents=function(){this.proxyImage.removeEventListener("load",this),this.proxyImage.removeEventListener("error",this),this.img.removeEventListener("load",this),this.img.removeEventListener("error",this)},(n.prototype=Object.create(o.prototype)).check=function(){this.img.addEventListener("load",this),this.img.addEventListener("error",this),this.img.src=this.url,this.getIsImageComplete()&&(this.confirm(0!==this.img.naturalWidth,"naturalWidth"),this.unbindEvents())},n.prototype.unbindEvents=function(){this.img.removeEventListener("load",this),this.img.removeEventListener("error",this)},n.prototype.confirm=function(e,t){this.isLoaded=e,this.emitEvent("progress",[this,this.element,t])},(r.makeJQueryPlugin=function(e){(e=e||t.jQuery)&&((s=e).fn.imagesLoaded=function(e,t){return new r(this,e,t).jqDeferred.promise(s(this))})})(),r}),((e,t)=>{"function"==typeof define&&define.amd?define(t):"object"==typeof exports?module.exports=t():e.PhotoSwipe=t()})(this,function(){return function(m,D,e,t){var p={features:null,bind:function(e,t,o,n){var i=(n?"remove":"add")+"EventListener";t=t.split(" ");for(var a=0;a<t.length;a++)t[a]&&e[i](t[a],o,!1)},isArray:function(e){return e instanceof Array},createEl:function(e,t){t=document.createElement(t||"div");return e&&(t.className=e),t},getScrollY:function(){var e=window.pageYOffset;return void 0!==e?e:document.documentElement.scrollTop},unbind:function(e,t,o){p.bind(e,t,o,!0)},removeClass:function(e,t){t=new RegExp("(\\s|^)"+t+"(\\s|$)");e.className=e.className.replace(t," ").replace(/^\s\s*/,"").replace(/\s\s*$/,"")},addClass:function(e,t){p.hasClass(e,t)||(e.className+=(e.className?" ":"")+t)},hasClass:function(e,t){return e.className&&new RegExp("(^|\\s)"+t+"(\\s|$)").test(e.className)},getChildByClass:function(e,t){for(var o=e.firstChild;o;){if(p.hasClass(o,t))return o;o=o.nextSibling}},arraySearch:function(e,t,o){for(var n=e.length;n--;)if(e[n][o]===t)return n;return-1},extend:function(e,t,o){for(var n in t)if(t.hasOwnProperty(n)){if(o&&e.hasOwnProperty(n))continue;e[n]=t[n]}},easing:{sine:{out:function(e){return Math.sin(e*(Math.PI/2))},inOut:function(e){return-(Math.cos(Math.PI*e)-1)/2}},cubic:{out:function(e){return--e*e*e+1}}},detectFeatures:function(){if(p.features)return p.features;var e,t,o=p.createEl().style,n="",i={};i.oldIE=document.all&&!document.addEventListener,i.touch="ontouchstart"in window,window.requestAnimationFrame&&(i.raf=window.requestAnimationFrame,i.caf=window.cancelAnimationFrame),i.pointerEvent=navigator.pointerEnabled||navigator.msPointerEnabled,i.pointerEvent||(e=navigator.userAgent,/iP(hone|od)/.test(navigator.platform)&&(t=navigator.appVersion.match(/OS (\d+)_(\d+)_?(\d+)?/))&&0<t.length&&1<=(t=parseInt(t[1],10))&&t<8&&(i.isOldIOSPhone=!0),t=(t=e.match(/Android\s([0-9\.]*)/))?t[1]:0,1<=(t=parseFloat(t))&&(t<4.4&&(i.isOldAndroid=!0),i.androidVersion=t),i.isMobileOpera=/opera mini|o
21pera mobi/i.test(e));for(var a,r,s,l=["transform","perspective","animationName"],c=["","webkit","Moz","ms","O"],d=0;d<4;d++){for(var n=c[d],u=0;u<3;u++)a=l[u],r=n+(n?a.charAt(0).toUpperCase()+a.slice(1):a),!i[a]&&r in o&&(i[a]=r);n&&!i.raf&&(n=n.toLowerCase(),i.raf=window[n+"RequestAnimationFrame"],i.raf)&&(i.caf=window[n+"CancelAnimationFrame"]||window[n+"CancelRequestAnimationFrame"])}return i.raf||(s=0,i.raf=function(e){var t=(new Date).getTime(),o=Math.max(0,16-(t-s)),n=window.setTimeout(function(){e(t+o)},o);return s=t+o,n},i.caf=function(e){clearTimeout(e)}),i.svg=!!document.createElementNS&&!!document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGRect,p.features=i}},h=(p.detectFeatures(),p.features.oldIE&&(p.bind=function(e,t,o,n){t=t.split(" ");for(var i,a=(n?"detach":"attach")+"Event",r=function(){o.handleEvent.call(o)},s=0;s<t.length;s++)if(i=t[s])if("object"==typeof o&&o.handleEvent){if(n){if(!o["oldIE"+i])return!1}else o["oldIE"+i]=r;e[a]("on"+i,o["oldIE"+i])}else e[a]("on"+i,o)}),this),z=25,_={allowPanToNext:!0,spacing:.12,bgOpacity:1,mouseUsed:!1,loop:!0,pinchToClose:!0,closeOnScroll:!0,closeOnVerticalDrag:!0,verticalDragRange:.75,hideAnimationDuration:333,showAnimationDuration:333,showHideOpacity:!1,focus:!0,escKey:!0,arrowKeys:!0,mainScrollEndFriction:.35,panEndFriction:.35,isClickableElement:function(e){return"A"===e.tagName},getDoubleTapZoom:function(e,t){return e||t.initialZoomLevel<.7?1:1.33},maxSpreadZoom:1.33,modal:!0,scaleMode:"fit"};p.extend(_,t);function G(){return{x:0,y:0}}function B(e,t){p.extend(h,t.publicMethods),qe.push(e)}function N(e){var t=A();return t-1<e?e-t:e<0?t+e:e}function a(e,t){return We[e]||(We[e]=[]),We[e].push(t)}function q(e,t,o,n){n===h.currItem.initialZoomLevel?o[e]=h.currItem.initialPosition[e]:(o[e]=Qe(e,n),o[e]>t.min[e]?o[e]=t.min[e]:o[e]<t.max[e]&&(o[e]=t.max[e]))}function H(e){var t="";_.escKey&&27===e.keyCode?t="close":_.arrowKeys&&(37===e.keyCode?t="prev":39===e.keyCode&&(t="next")),!t||e.ctrlKey||e.altKey||e.shiftKey||e.metaKey||(e.preventDefault?e.preventDefault():e.returnValue=!1,h[t]())}function U(e){e&&(Ee||Se||v||xe)&&(e.preventDefault(),e.stopPropagation())}function W(e){var t;"mousedown"===e.type&&0<e.button||(Xt?e.preventDefault():Ce&&"mousedown"===e.type||(It(e,!0)&&e.preventDefault(),x("pointerDown"),pe&&((t=p.arraySearch(ht,e.pointerId,"id"))<0&&(t=ht.length),ht[t]={x:e.pageX,y:e.pageY,id:e.pointerId}),e=(t=Dt(e)).length,c=null,lt(),l&&1!==e||(l=Ae=!0,p.bind(window,ee,h),ke=Le=Me=xe=Ie=Ee=Te=Se=!1,Re=null,x("firstTouchStart",t),E(Ge,w),ze.x=ze.y=0,E(F,t[0]),E(pt,F),_t.x=$.x*y,ft=[{x:F.x,y:F.y}],ye=be=C(),tt(g,!0),Ct(),Tt()),!d&&1<e&&!v&&!Ie&&(oe=g,d=Te=!(Se=!1),ze.y=ze.x=0,E(Ge,w),E(I,t[0]),E(mt,t[1]),Ft(I,mt,$t),yt.x=Math.abs($t.x)-w.x,yt.y=Math.abs($t.y)-w.y,je=xt(I,mt))))}function V(e){var t;e.preventDefault(),pe&&-1<(t=p.arraySearch(ht,e.pointerId,"id"))&&((t=ht[t]).x=e.pageX,t.y=e.pageY),l&&(t=Dt(e),Re||Ee||d?c=t:R.x!==$.x*y?Re="h":(e=Math.abs(t[0].x-F.x)-Math.abs(t[0].y-F.y),Math.abs(e)>=ut&&(Re=0<e?"h":"v",c=t)))}function Z(e){if(s.isOldAndroid){if(Ce&&"mouseup"===e.type)return;-1<e.type.indexOf("touch")&&(clearTimeout(Ce),Ce=setTimeout(function(){Ce=0},600))}var t;x("pointerUp"),It(e,!1)&&e.preventDefault(),pe&&-1<(a=p.arraySearch(ht,e.pointerId,"id"))&&(t=ht.splice(a,1)[0],!navigator.pointerEnabled&&(t.type={4:"mouse",2:"touch",3:"pen"}[e.pointerType],t.type)||(t.type=e.pointerType||"mouse"));var o=(a=Dt(e)).length;if(2===(o="mouseup"===e.type?0:o))return!(c=null);1===o&&E(pt,a[0]),0!==o||Re||v||(t||("mouseup"===e.type?t={x:e.pageX,y:e.pageY,type:"mouse"}:e.changedTouches&&e.changedTouches[0]&&(t={x:e.changedTouches[0].pageX,y:e.changedTouches[0].pageY,type:"touch"})),x("touchRelease",e,t));var n,i,a=-1;if(0===o&&(l=!1,p.unbind(window,ee,h),Ct(),d?a=0:-1!==bt&&(a=C()-bt)),bt=1===o?C():-1,e=-1!==a&&a<150?"zoom":"swipe",d&&o<2&&(d=!1,1===o&&(e="zoomPointerUp"),x("zoomGestureEnded")),c=null,Ee||Se||v||xe)if(lt(),($e=$e||Bt()).calculateSwipeSpeed("x"),xe)At()<_.verticalDragRange?h.close():(n=w.y,i=Oe,ct("verticalDrag",0,1,300,p.easing.cubic.out,function(e){w.y=(h.currItem.initialPosition.y-n)*e+n,T((1-i)*e+i),S()}),x("onVerticalDrag",1));else{if((Ie||v)&&0===o){if(qt(e,$e))return;e="zoomPointerUp"}if(!v)return"swipe"!==e?void Ut():void(!Ie&&g>
21h.currItem.fitRatio&&Nt($e))}}var K,Y,Q,f,X,J,ee,te,n,g,oe,ne,ie,ae,re,r,se,le,ce,de,ue,me,pe,i,he,_e,fe,ge,ve,we,s,be,ye,$e,ke,xe,Ce,l,Te,Se,Ee,Pe,Ie,c,d,je,u,Fe,v,Re,Ae,Me,Oe,Le,De,ze=G(),Ge=G(),w=G(),b={},y=0,Be={},$=G(),k=0,Ne=!0,qe=[],He={},Ue=!1,We={},x=function(e){var t=We[e];if(t){var o=Array.prototype.slice.call(arguments);o.shift();for(var n=0;n<t.length;n++)t[n].apply(h,o)}},C=function(){return(new Date).getTime()},T=function(e){Oe=e,h.bg.style.opacity=e*_.bgOpacity},Ve=function(e,t,o,n,i){(!Ue||i&&i!==h.currItem)&&(n/=(i||h.currItem).fitRatio),e[me]=ne+t+"px, "+o+"px"+ie+" scale("+n+")"},S=function(e){Fe&&(e&&(g>h.currItem.fitRatio?Ue||(so(h.currItem,!1,!0),Ue=!0):Ue&&(so(h.currItem),Ue=!1)),Ve(Fe,w.x,w.y,g))},Ze=function(e){e.container&&Ve(e.container.style,e.initialPosition.x,e.initialPosition.y,e.initialZoomLevel,e)},Ke=function(e,t){t[me]=ne+e+"px, 0px"+ie},Ye=function(e,t){var o;!_.loop&&t&&(t=f+($.x*y-e)/$.x,o=Math.round(e-R.x),t<0&&0<o||t>=A()-1&&o<0)&&(e=R.x+o*_.mainScrollEndFriction),R.x=e,Ke(e,X)},Qe=function(e,t){var o=yt[e]-Be[e];return Ge[e]+ze[e]+o-t/oe*o},E=function(e,t){e.x=t.x,e.y=t.y,t.id&&(e.id=t.id)},Xe=function(e){e.x=Math.round(e.x),e.y=Math.round(e.y)},Je=null,et=function(){Je&&(p.unbind(document,"mousemove",et),p.addClass(m,"pswp--has_mouse"),_.mouseUsed=!0,x("mouseUsed")),Je=setTimeout(function(){Je=null},100)},tt=function(e,t){e=ao(h.currItem,b,e);return t&&(u=e),e},ot=function(e){return(e=e||h.currItem).initialZoomLevel},nt=function(e){return 0<(e=e||h.currItem).w?_.maxSpreadZoom:1},it=function(){h.setScrollOffset(0,p.getScrollY())},P={},at=0,rt=function(e){P[e]&&(P[e].raf&&_e(P[e].raf),at--,delete P[e])},st=function(e){P[e]&&rt(e),P[e]||(at++,P[e]={})},lt=function(){for(var e in P)P.hasOwnProperty(e)&&rt(e)},ct=function(e,t,o,n,i,a,r){function s(){P[e]&&(l=C()-c,n<=l?(rt(e),a(o),r&&r()):(a((o-t)*i(l/n)+t),P[e].raf=he(s)))}var l,c=C();st(e);s()},t={shout:x,listen:a,viewportSize:b,options:_,isMainScrollAnimating:function(){return v},getZoomLevel:function(){return g},getCurrentIndex:function(){return f},isDragging:function(){return l},isZooming:function(){return d},setScrollOffset:function(e,t){Be.x=e,we=Be.y=t,x("updateScrollOffset",Be)},applyZoomPan:function(e,t,o,n){w.x=t,w.y=o,g=e,S(n)},init:function(){if(!K&&!Y){h.framework=p,h.template=m,h.bg=p.getChildByClass(m,"pswp__bg"),fe=m.className,K=!0,s=p.detectFeatures(),he=s.raf,_e=s.caf,me=s.transform,ve=s.oldIE,h.scrollWrap=p.getChildByClass(m,"pswp__scroll-wrap"),h.container=p.getChildByClass(h.scrollWrap,"pswp__container"),X=h.container.style,h.itemHolders=r=[{el:h.container.children[0],wrap:0,index:-1},{el:h.container.children[1],wrap:0,index:-1},{el:h.container.children[2],wrap:0,index:-1}],r[0].el.style.display=r[2].el.style.display="none",me?(t=s.perspective&&!i,ne="translate"+(t?"3d(":"("),ie=s.perspective?", 0px)":")"):(me="left",p.addClass(m,"pswp--ie"),Ke=function(e,t){t.left=e+"px"},Ze=function(e){var t=1<e.fitRatio?1:e.fitRatio,o=e.container.style,n=t*e.h;o.width=t*e.w+"px",o.height=n+"px",o.left=e.initialPosition.x+"px",o.top=e.initialPosition.y+"px"},S=function(){var e,t,o,n;Fe&&(e=Fe,n=(o=1<(t=h.currItem).fitRatio?1:t.fitRatio)*t.h,e.width=o*t.w+"px",e.height=n+"px",e.left=w.x+"px",e.top=w.y+"px")}),n={resize:h.updateSize,scroll:it,keydown:H,click:U};var e,t=s.isOldIOSPhone||s.isOldAndroid||s.isMobileOpera;for(s.animationName&&s.transform&&!t||(_.showAnimationDuration=_.hideAnimationDuration=0),e=0;e<qe.length;e++)h["init"+qe[e]]();D&&(h.ui=new D(h,p)).init(),x("firstUpdate"),f=f||_.index||0,(isNaN(f)||f<0||f>=A())&&(f=0),h.currItem=Jt(f),(s.isOldIOSPhone||s.isOldAndroid)&&(Ne=!1),m.setAttribute("aria-hidden","false"),_.modal&&(Ne?m.style.position="fixed":(m.style.position="absolute",m.style.top=p.getScrollY()+"px")),void 0===we&&(x("initialLayout"),we=ge=p.getScrollY());var o="pswp--open ";for(_.mainClass&&(o+=_.mainClass+" "),_.showHideOpacity&&(o+="pswp--animate_opacity "),o=(o=(o+=i?"pswp--touch":"pswp--notouch")+(s.animationName?" pswp--css_animation":""))+(s.svg?" pswp--svg":""),p.addClass(m,o),h.updateSize(),J=-1,k=null,e=0;e<3;e++)Ke((e+J)*$.x,r[e].el.style);ve||p.bind(h.scrollWrap,te,h),a("initialZoomInEnd",function(){h.setContent(r[0],f-1),h.setContent(r[2],f+1),r[0].el.style.display=r[2].el.style.display="block",_.focus&&m.focus(),p.bind(document,"keydown",h),s.transform&&p.bind(h.scrollWrap,"click",h),_.mouseUsed||p.bind(document,"mousemove",et),p.bind(window,"resize scroll",h),x("bindEvents")}),h.setContent(r[1],f),h.updateCurrItem(),x("afterInit"),Ne||(ae=setInterval(function(){at||l||d||g!==h.currItem.initialZoomLevel||h.updateSize()},1e3)),p.addClass(m,"pswp--visible")}var t},close:function(){K&&(Y=!(K=!1),x("close"),p.unbind(window,"resize",h),p.unbind(window,"scroll",n.scroll),p.unbind(document,"keydown",h),p.unbind(document,"mousemove",et),s.transform&&p.unbind(h.scrollWrap,"click",h),l&&p.unbind(window,ee,h),x("unbindEvents"),eo(h.currItem,
21null,!0,h.destroy))},destroy:function(){x("destroy"),Kt&&clearTimeout(Kt),m.setAttribute("aria-hidden","true"),m.className=fe,ae&&clearInterval(ae),p.unbind(h.scrollWrap,te,h),p.unbind(window,"scroll",h),Ct(),lt(),We=null},panTo:function(e,t,o){o||(e>u.min.x?e=u.min.x:e<u.max.x&&(e=u.max.x),t>u.min.y?t=u.min.y:t<u.max.y&&(t=u.max.y)),w.x=e,w.y=t,S()},handleEvent:function(e){e=e||window.event,n[e.type]&&n[e.type](e)},goTo:function(e){var t=(e=N(e))-f;k=t,f=e,h.currItem=Jt(f),y-=t,Ye($.x*y),lt(),v=!1,h.updateCurrItem()},next:function(){h.goTo(f+1)},prev:function(){h.goTo(f-1)},updateCurrZoomItem:function(e){var t;e&&x("beforeChange",0),Fe=r[1].el.children.length&&(t=r[1].el.children[0],p.hasClass(t,"pswp__zoom-wrap"))?t.style:null,u=h.currItem.bounds,oe=g=h.currItem.initialZoomLevel,w.x=u.center.x,w.y=u.center.y,e&&x("afterChange")},invalidateCurrItems:function(){re=!0;for(var e=0;e<3;e++)r[e].item&&(r[e].item.needsUpdate=!0)},updateCurrItem:function(e){if(0!==k){var t,o=Math.abs(k);if(!(e&&o<2)){h.currItem=Jt(f),Ue=!1,x("beforeChange",k),3<=o&&(J+=k+(0<k?-3:3),o=3);for(var n=0;n<o;n++)0<k?(t=r.shift(),r[2]=t,Ke((++J+2)*$.x,t.el.style),h.setContent(t,f-o+n+1+1)):(t=r.pop(),r.unshift(t),Ke(--J*$.x,t.el.style),h.setContent(t,f+o-n-1-1));Fe&&1===Math.abs(k)&&(e=Jt(se)).initialZoomLevel!==g&&(ao(e,b),so(e),Ze(e)),k=0,h.updateCurrZoomItem(),se=f,x("afterChange")}}},updateSize:function(e){if(!Ne&&_.modal){var t=p.getScrollY();if(we!==t&&(m.style.top=t+"px",we=t),!e&&He.x===window.innerWidth&&He.y===window.innerHeight)return;He.x=window.innerWidth,He.y=window.innerHeight,m.style.height=He.y+"px"}if(b.x=h.scrollWrap.clientWidth,b.y=h.scrollWrap.clientHeight,it(),$.x=b.x+Math.round(b.x*_.spacing),$.y=b.y,Ye($.x*y),x("beforeResize"),void 0!==J){for(var o,n,i,a=0;a<3;a++)o=r[a],Ke((a+J)*$.x,o.el.style),i=f+a-1,_.loop&&2<A()&&(i=N(i)),(n=Jt(i))&&(re||n.needsUpdate||!n.bounds)?(h.cleanSlide(n),h.setContent(o,i),1===a&&(h.currItem=n,h.updateCurrZoomItem(!0)),n.needsUpdate=!1):-1===o.index&&0<=i&&h.setContent(o,i),n&&n.container&&(ao(n,b),so(n),Ze(n));re=!1}oe=g=h.currItem.initialZoomLevel,(u=h.currItem.bounds)&&(w.x=u.center.x,w.y=u.center.y,S(!0)),x("resize")},zoomTo:function(t,e,o,n,i){e&&(oe=g,yt.x=Math.abs(e.x)-w.x,yt.y=Math.abs(e.y)-w.y,E(Ge,w));function a(e){1===e?(g=t,w.x=r.x,w.y=r.y):(g=(t-s)*e+s,w.x=(r.x-l.x)*e+l.x,w.y=(r.y-l.y)*e+l.y),i&&i(e),S(1===e)}var e=tt(t,!1),r={},s=(q("x",e,r,t),q("y",e,r,t),g),l={x:w.x,y:w.y};Xe(r);o?ct("customZoomTo",0,1,o,n||p.easing.sine.inOut,a):a(1)}},dt=30,ut=10,I={},mt={},j={},F={},pt={},ht=[],_t={},ft=[],gt={},vt=0,wt=G(),bt=0,R=G(),yt=G(),$t=G(),kt=function(e,t){return e.x===t.x&&e.y===t.y},xt=function(e,t){return gt.x=Math.abs(e.x-t.x),gt.y=Math.abs(e.y-t.y),Math.sqrt(gt.x*gt.x+gt.y*gt.y)},Ct=function(){Pe&&(_e(Pe),Pe=null)},Tt=function(){l&&(Pe=he(Tt),Gt())},St=function(){return!("fit"===_.scaleMode&&g===h.currItem.initialZoomLevel)},Et=function(e,t){return!(!e||e===document||e.getAttribute("class")&&-1<e.getAttribute("class").indexOf("pswp__scroll-wrap"))&&(t(e)?e:Et(e.parentNode,t))},Pt={},It=function(e,t){return Pt.prevent=!Et(e.target,_.isClickableElement),x("preventDragEvent",e,t,Pt),Pt.prevent},jt=function(e,t){return t.x=e.pageX,t.y=e.pageY,t.id=e.identifier,t},Ft=function(e,t,o){o.x=.5*(e.x+t.x),o.y=.5*(e.y+t.y)},Rt=function(e,t,o){var n;50<e-ye&&((n=2<ft.length?ft.shift():{}).x=t,n.y=o,ft.push(n),ye=e)},At=function(){var e=w.y-h.currItem.initialPosition.y;return 1-Math.abs(e/(b.y/2))},Mt={},Ot={},Lt=[],Dt=function(e){for(;0<Lt.length;)Lt.pop();return pe?(De=0,ht.forEach(function(e){0===De?Lt[0]=e:1===De&&(Lt[1]=e),De++})):-1<e.type.indexOf("touch")?e.touches&&0<e.touches.length&&(Lt[0]=jt(e.touches[0],Mt),1<e.touches.length)&&(Lt[1]=jt(e.touches[1],Ot)):(Mt.x=e.pageX,Mt.y=e.pageY,Mt.id="",Lt[0]=Mt),Lt},zt=function(e,t){var o,n,i,a=w[e]+t[e],r=R.x+t.x,s=R.x-_t.x,l=a>u.min[e]||a<u.max[e]?_.panEndFriction:1,a=w[e]+t[e]*l;return!_.allowPanToNext&&g!==h.currItem.initialZoomLevel||(Fe?"h"!==Re||"x"!==e||Se||(0<t[e]?(a>u.min[e]&&(l=_.panEndFriction,u.min[e],o=u.min[e]-Ge[e]),(o<=0||s<0)&&1<A()?(i=r,s<0&&r>_t.x&&(i=_t.x)):u.min.x!==u.max.x&&(n=a)):(a<u.max[e]&&(l=_.panEndFriction,u.max[e],o=Ge[e]-u.max[e]),(o<=0||0<s)&&1<A()?(i=r,0<s&&r<_t.x&&(i=_t.x)):u.min.x!==u.max.x&&(n=a))):i=r,"x"!==e)?void(v||Ie||g>h.currItem.fitRatio&&(w[e]+=t[e]*l)):(void 0!==i&&(Ye(i,!0),Ie=i!==_t.x),u.min.x!==u.max.x&&(void 0!==n?w.x=n:Ie||(w.x+=t.x*l)),void 0!==i)},Gt=function(){var e,t,o,n,i,a;c&&0!==(e=c.length)&&(E(I,c[0]),j.x=I.x-F.x,j.y=I.y-F.y,d&&1<e?(F.x=I.x,F.y=I.y,!j.x&&!j.y&&kt(c[1],mt)||(E(mt,c[1]),Se||(Se=!0,x("zoomGestureStarted")),e=xt(I,mt),(t=Ht(e))>h.currItem.initialZoomLevel+h.currItem.initialZoomLevel/15&&(Le=!0),o=1,n=ot(),i=nt(),t<n?_.pinchToClose&&!Le&&oe<=h.currItem.initialZoomLevel?(T(a=1-(n-t)/(n/1.2)),x("onPinchClose",a),Me=!0):t=n-(o=1<(o=(n-t)/n)?1:o)*(n/3):i<t&&(t=i+(o=1<(o=(t-i)/(6*n))?1:o)*n),o<0&&(o=0),Ft(I,mt,wt),ze.x+=wt.x-$t.x,ze.y+=wt.y-$t.y,E($t,wt),w.x=Qe("x",t),w.y=Qe("y",t),ke=g<t,g=t,S())):Re&&(Ae&&(Ae=!1,Math.abs(j.x)>=ut&&(j.x-=c[0].x-pt.x),Math.abs(j.y)>=ut)&&(j.y-=c[0].y-pt.y),F.x=I.x,F.y=I.y,0===j.x&&0===j.y||("v"===Re&&_.closeOnVerticalDrag&&!St()?(ze.y+=j.y,w.y+=j.y,a=At(),xe=!0,x("onVerticalDrag",a),T(a),S()):(Rt(C(),I.x,I.y),Ee=!0,u=h.currItem.bounds,zt("x",j)||(zt("y",j),Xe(w),S())))))},Bt=function(){var t,o,n={lastFlickOffset:{},lastFlickDist:{},lastFlickSpeed:{},slowDownRatio:{},slowDownRatioReverse:{},speedDecelerationRatio:{},speedDecelerationRatioAbs:{},distanceOffset:{}
21,backAnimDestination:{},backAnimStarted:{},calculateSwipeSpeed:function(e){o=(1<ft.length?(t=C()-ye+50,ft[ft.length-2]):(t=C()-be,pt))[e],n.lastFlickOffset[e]=F[e]-o,n.lastFlickDist[e]=Math.abs(n.lastFlickOffset[e]),20<n.lastFlickDist[e]?n.lastFlickSpeed[e]=n.lastFlickOffset[e]/t:n.lastFlickSpeed[e]=0,Math.abs(n.lastFlickSpeed[e])<.1&&(n.lastFlickSpeed[e]=0),n.slowDownRatio[e]=.95,n.slowDownRatioReverse[e]=1-n.slowDownRatio[e],n.speedDecelerationRatio[e]=1},calculateOverBoundsAnimOffset:function(t,e){n.backAnimStarted[t]||(w[t]>u.min[t]?n.backAnimDestination[t]=u.min[t]:w[t]<u.max[t]&&(n.backAnimDestination[t]=u.max[t]),void 0!==n.backAnimDestination[t]&&(n.slowDownRatio[t]=.7,n.slowDownRatioReverse[t]=1-n.slowDownRatio[t],n.speedDecelerationRatioAbs[t]<.05)&&(n.lastFlickSpeed[t]=0,n.backAnimStarted[t]=!0,ct("bounceZoomPan"+t,w[t],n.backAnimDestination[t],e||300,p.easing.sine.out,function(e){w[t]=e,S()})))},calculateAnimOffset:function(e){n.backAnimStarted[e]||(n.speedDecelerationRatio[e]=n.speedDecelerationRatio[e]*(n.slowDownRatio[e]+n.slowDownRatioReverse[e]-n.slowDownRatioReverse[e]*n.timeDiff/10),n.speedDecelerationRatioAbs[e]=Math.abs(n.lastFlickSpeed[e]*n.speedDecelerationRatio[e]),n.distanceOffset[e]=n.lastFlickSpeed[e]*n.speedDecelerationRatio[e]*n.timeDiff,w[e]+=n.distanceOffset[e])},panAnimLoop:function(){return P.zoomPan&&(P.zoomPan.raf=he(n.panAnimLoop),n.now=C(),n.timeDiff=n.now-n.lastNow,n.lastNow=n.now,n.calculateAnimOffset("x"),n.calculateAnimOffset("y"),S(),n.calculateOverBoundsAnimOffset("x"),n.calculateOverBoundsAnimOffset("y"),n.speedDecelerationRatioAbs.x<.05)&&n.speedDecelerationRatioAbs.y<.05?(w.x=Math.round(w.x),w.y=Math.round(w.y),S(),void rt("zoomPan")):void 0}};return n},Nt=function(e){return e.calculateSwipeSpeed("y"),u=h.currItem.bounds,e.backAnimDestination={},e.backAnimStarted={},Math.abs(e.lastFlickSpeed.x)<=.05&&Math.abs(e.lastFlickSpeed.y)<=.05?(e.speedDecelerationRatioAbs.x=e.speedDecelerationRatioAbs.y=0,e.calculateOverBoundsAnimOffset("x"),e.calculateOverBoundsAnimOffset("y"),!0):(st("zoomPan"),e.lastNow=C(),void e.panAnimLoop())},qt=function(e,t){var o,n,i;v||(vt=f),"swipe"===e&&(e=F.x-pt.x,a=t.lastFlickDist.x<10,dt<e&&(a||20<t.lastFlickOffset.x)?n=-1:e<-dt&&(a||t.lastFlickOffset.x<-20)&&(n=1)),n&&((f+=n)<0?(f=_.loop?A()-1:0,i=!0):f>=A()&&(f=_.loop?0:A()-1,i=!0),!i||_.loop)&&(k+=n,y-=n,o=!0);var e=$.x*y,a=Math.abs(e-R.x),r=o||e>R.x==0<t.lastFlickSpeed.x?(r=0<Math.abs(t.lastFlickSpeed.x)?a/Math.abs(t.lastFlickSpeed.x):333,r=Math.min(r,400),Math.max(r,250)):333;return vt===f&&(o=!1),v=!0,x("mainScrollAnimStart"),ct("mainScroll",R.x,e,r,p.easing.cubic.out,Ye,function(){lt(),v=!1,vt=-1,!o&&vt===f||h.updateCurrItem(),x("mainScrollAnimComplete")}),o&&h.updateCurrItem(!0),o},Ht=function(e){return 1/je*e*oe},Ut=function(){var e=g,t=ot(),o=nt();g<t?e=t:o<g&&(e=o);var n,i=Oe;return Me&&!ke&&!Le&&g<t?h.close():(Me&&(n=function(e){T((1-i)*e+i)}),h.zoomTo(e,0,200,p.easing.cubic.out,n)),!0};B("Gestures",{publicMethods:{initGestures:function(){function e(e,t,o,n,i){le=e+t,ce=e+o,de=e+n,ue=i?e+i:""}(pe=s.pointerEvent)&&s.touch&&(s.touch=!1),pe?navigator.pointerEnabled?e("pointer","down","move","up","cancel"):e("MSPointer","Down","Move","Up","Cancel"):s.touch?(e("touch","start","move","end","cancel"),i=!0):e("mouse","down","move","up"),ee=ce+" "+de+" "+ue,te=le,pe&&!i&&(i=1<navigator.maxTouchPoints||1<navigator.msMaxTouchPoints),h.likelyTouchDevice=i,n[le]=W,n[ce]=V,n[de]=Z,ue&&(n[ue]=n[de]),s.touch&&(te+=" mousedown",ee+=" mousemove mouseup",n.mousedown=n[le],n.mousemove=n[ce],n.mouseup=n[de]),i||(_.allowPanToNext=!1)}}});function Wt(e){function t(){e.loading=!1,e.loaded=!0,(e.w<1||e.h<1)&&(e.w=o.width,e.h=o.height,h.currItem==e&&(it(),$.x=b.x+Math.round(b.x*_.spacing),$.y=b.y,Ye($.x*y),h.updateCurrZoomItem(!0)),e&&e.container&&(ao(e,b),so(e),Ze(e)),h.currItem==e)&&(oe=g=h.currItem.initialZoomLevel,u=h.currItem.bounds)&&(w.x=u.center.x,w.y=u.center.y,S(!0)),e.loadComplete?e.loadComplete(e):e.img=null,o.onload=o.onerror=null,o=null}e.loading=!0,e.loaded=!1;var o=e.img=p.createEl("pswp__img","img");o.onload=t,o.onerror=function(){e.loadError=!0,t()},o.src=e.src}function Vt(e,t){return e.src&&e.loadError&&e.container?(t&&(e.container.innerHTML=""),e.container.innerHTML=_.errorMsg.replace("%url%",e.
21src),!0):void 0}function Zt(){if(to.length){for(var e,t=0;t<to.length;t++)(e=to[t]).holder.index===e.index&&ro(e.index,e.item,e.baseDiv,e.img,!1,e.clearPlaceholder);to=[]}}var Kt,Yt,Qt,Xt,Jt,A,eo=function(a,e,r,t){function s(){rt("initialZoom"),r?(h.template.removeAttribute("style"),h.bg.removeAttribute("style")):(T(1),e&&(e.style.display="block"),p.addClass(m,"pswp--animated-in"),x("initialZoom"+(r?"OutEnd":"InEnd"))),t&&t(),Xt=!1}Kt&&clearTimeout(Kt),Qt=Xt=!0,a.initialLayout?(l=a.initialLayout,a.initialLayout=null):l=_.getThumbBoundsFn&&_.getThumbBoundsFn(f);var l,c,d,u=r?_.hideAnimationDuration:_.showAnimationDuration;u&&l&&void 0!==l.x?(c=Q,d=!h.currItem.src||h.currItem.loadError||_.showHideOpacity,a.miniImg&&(a.miniImg.style.webkitBackfaceVisibility="hidden"),r||(g=l.w/a.w,w.x=l.x,w.y=l.y-ge,h[d?"template":"bg"].style.opacity=.001,S()),st("initialZoom"),r&&!c&&p.removeClass(m,"pswp--animated-in"),d&&(r?p[(c?"remove":"add")+"Class"](m,"pswp--animate_opacity"):setTimeout(function(){p.addClass(m,"pswp--animate_opacity")},30)),Kt=setTimeout(function(){var t,o,n,i,e;x("initialZoom"+(r?"Out":"In")),r?(t=l.w/a.w,o={x:w.x,y:w.y},n=g,i=Oe,e=function(e){1===e?(g=t,w.x=l.x,w.y=l.y-we):(g=(t-n)*e+n,w.x=(l.x-o.x)*e+o.x,w.y=(l.y-we-o.y)*e+o.y),S(),d?m.style.opacity=1-e:T(i-e*i)},c?ct("initialZoom",0,1,u,p.easing.cubic.out,e,s):(e(1),Kt=setTimeout(s,u+20))):(g=a.initialZoomLevel,E(w,a.initialPosition),S(),T(1),d?m.style.opacity=1:T(1),Kt=setTimeout(s,u+20))},r?25:90)):(x("initialZoom"+(r?"Out":"In")),g=a.initialZoomLevel,E(w,a.initialPosition),S(),m.style.opacity=r?0:1,T(1),u?setTimeout(function(){s()},u):s())},M={},to=[],oo={index:0,errorMsg:'<div class="pswp__error-msg">image not loaded</div>',forceProgressiveLoading:!1,preload:[1,1],getNumItemsFn:function(){return Yt.length}},no=function(){return{center:{x:0,y:0},max:{x:0,y:0},min:{x:0,y:0}}},io=function(e,t,o){var n=e.bounds;n.center.x=Math.round((M.x-t)/2),n.center.y=Math.round((M.y-o)/2)+e.vGap.top,n.max.x=t>M.x?Math.round(M.x-t):n.center.x,n.max.y=o>M.y?Math.round(M.y-o)+e.vGap.top:n.center.y,n.min.x=t>M.x?0:n.center.x,n.min.y=o>M.y?e.vGap.top:n.center.y},ao=function(e,t,o){var n,i;return e.src&&!e.loadError?((n=!o)&&(e.vGap||(e.vGap={top:0,bottom:0}),x("parseVerticalMargin",e)),M.x=t.x,M.y=t.y-e.vGap.top-e.vGap.bottom,n&&(t=M.x/e.w,i=M.y/e.h,e.fitRatio=t<i?t:i,"orig"===(t=_.scaleMode)?o=1:"fit"===t&&(o=e.fitRatio),e.initialZoomLevel=o=1<o?1:o,e.bounds||(e.bounds=no())),o?(io(e,e.w*o,e.h*o),n&&o===e.initialZoomLevel&&(e.initialPosition=e.bounds.center),e.bounds):void 0):(e.w=e.h=0,e.initialZoomLevel=e.fitRatio=1,e.bounds=no(),e.initialPosition=e.bounds.center,e.bounds)},ro=function(e,t,o,n,i,a){t.loadError||n&&(t.imageAppended=!0,so(t,n,t===h.currItem&&Ue),o.appendChild(n),a)&&setTimeout(function(){t&&t.loaded&&t.placeholder&&(t.placeholder.style.display="none",t.placeholder=null)},500)},so=function(e,t,o){var n;e.src&&(t=t||e.container.lastChild,n=o?e.w:Math.round(e.w*e.fitRatio),o=o?e.h:Math.round(e.h*e.fitRatio),e.placeholder&&!e.loaded&&(e.placeholder.style.width=n+"px",e.placeholder.style.height=o+"px"),t.style.width=n+"px",t.style.height=o+"px")};B("Controller",{publicMethods:{lazyLoadItem:function(e){e=N(e);var t=Jt(e);t&&(!t.loaded&&!t.loading||re)&&(x("gettingData",e,t),t.src)&&Wt(t)},initController:function(){p.extend(_,oo,!0),h.items=Yt=e,Jt=h.getItemAt,A=_.getNumItemsFn,_.loop,A()<3&&(_.loop=!1),a("beforeChange",function(e){for(var t=_.preload,o=null===e||0<=e,n=Math.min(t[0],A()),i=Math.min(t[1],A()),a=1;a<=(o?i:n);a++)h.lazyLoadItem(f+a);for(a=1;a<=(o?n:i);a++)h.lazyLoadItem(f-a)}),a("initialLayout",function(){h.currItem.initialLayout=_.getThumbBoundsFn&&_.getThumbBoundsFn(f)}),a("mainScrollAnimComplete",Zt),a("initialZoomInEnd",Zt),a("destroy",function(){for(var e,t=0;t<Yt.length;t++)(e=Yt[t]).container&&(e.container=null),e.placeholder&&(e.placeholder=null),e.img&&(e.img=null),e.preloader&&(e.preloader=null),e.loadError&&(e.loaded=e.loadError=!1);to=null})},getItemAt:function(e){return 0<=e&&void 0!==Yt[e]&&Yt[e]},allowProgressiveImg:function(){return _.forceProgressiveLoading||!i||_.mouseUsed||1200<screen.width},setContent:function(t,o){_.loop&&(o=N(o));var e=h.getItemAt(t.index);e&&(e.container=null);var n,i,a,e=h.getItemAt(o);e?(x("gettingData",o,e),t.index=o,i=(t.item=e).container=p.createEl("pswp__zoom-wrap"),!e.src&&e.html&&(e.html.tagName?i.appendChild(e.html):i.innerHTML=e.html),Vt(e),ao(e,b),!e.src||e.loadError||e.loaded?e.src&&!e.loadError&&((n=
21p.createEl("pswp__img","img")).style.opacity=1,n.src=e.src,so(e,n),ro(o,e,i,n,!0)):(e.loadComplete=function(e){if(K){if(t&&t.index===o){if(Vt(e,!0))return e.loadComplete=e.img=null,ao(e,b),Ze(e),void(t.index===f&&h.updateCurrZoomItem());e.imageAppended?!Xt&&e.placeholder&&(e.placeholder.style.display="none",e.placeholder=null):s.transform&&(v||Xt)?to.push({item:e,baseDiv:i,img:e.img,index:o,holder:t,clearPlaceholder:!0}):ro(o,e,i,e.img,v||Xt,!0)}e.loadComplete=null,e.img=null,x("imageLoadComplete",o,e)}},p.features.transform&&(a="pswp__img pswp__img--placeholder",a+=e.msrc?"":" pswp__img--placeholder--blank",a=p.createEl(a,e.msrc?"img":""),e.msrc&&(a.src=e.msrc),so(e,a),i.appendChild(a),e.placeholder=a),e.loading||Wt(e),h.allowProgressiveImg()&&(!Qt&&s.transform?to.push({item:e,baseDiv:i,img:e.img,index:o,holder:t}):ro(o,e,i,e.img,!0,!0))),Qt||o!==f?Ze(e):(Fe=i.style,eo(e,n||e.img)),t.el.innerHTML="",t.el.appendChild(i)):t.el.innerHTML=""},cleanSlide:function(e){e.img&&(e.img.onload=e.img.onerror=null),e.loaded=e.loading=e.img=e.imageAppended=!1}}});function lo(e,t,o){var n=document.createEvent("CustomEvent"),t={origEvent:e,target:e.target,releasePoint:t,pointerType:o||"touch"};n.initCustomEvent("pswpTap",!0,!0,t),e.target.dispatchEvent(n)}var co,O,uo={};B("Tap",{publicMethods:{initTap:function(){a("firstTouchStart",h.onTapStart),a("touchRelease",h.onTapRelease),a("destroy",function(){uo={},co=null})},onTapStart:function(e){1<e.length&&(clearTimeout(co),co=null)},onTapRelease:function(e,t){var o,n,i;!t||Ee||Te||at||(o=t,co&&(clearTimeout(co),co=null,n=o,i=uo,Math.abs(n.x-i.x)<z)&&Math.abs(n.y-i.y)<z?x("doubleTap",o):"mouse"===t.type?lo(e,t,"mouse"):"BUTTON"===e.target.tagName.toUpperCase()||p.hasClass(e.target,"pswp__single-tap")?lo(e,t):(E(uo,o),co=setTimeout(function(){lo(e,t),co=null},300)))}}}),B("DesktopZoom",{publicMethods:{initDesktopZoom:function(){ve||(i?a("mouseUsed",function(){h.setupDesktopZoom()}):h.setupDesktopZoom(!0))},setupDesktopZoom:function(e){O={};var t="wheel mousewheel DOMMouseScroll";a("bindEvents",function(){p.bind(m,t,h.handleMouseWheel)}),a("unbindEvents",function(){O&&p.unbind(m,t,h.handleMouseWheel)}),h.mouseZoomedIn=!1;function o(){h.mouseZoomedIn&&(p.removeClass(m,"pswp--zoomed-in"),h.mouseZoomedIn=!1),g<1?p.addClass(m,"pswp--zoom-allowed"):p.removeClass(m,"pswp--zoom-allowed"),i()}var n,i=function(){n&&(p.removeClass(m,"pswp--dragging"),n=!1)};a("resize",o),a("afterChange",o),a("pointerDown",function(){h.mouseZoomedIn&&(n=!0,p.addClass(m,"pswp--dragging"))}),a("pointerUp",i),e||o()},handleMouseWheel:function(e){if(g<=h.currItem.fitRatio)return _.modal&&(!_.closeOnScroll||at||l?e.preventDefault():me&&2<Math.abs(e.deltaY)&&(Q=!0,h.close())),!0;if(e.stopPropagation(),O.x=0,"deltaX"in e)1===e.deltaMode?(O.x=18*e.deltaX,O.y=18*e.deltaY):(O.x=e.deltaX,O.y=e.deltaY);else if("wheelDelta"in e)e.wheelDeltaX&&(O.x=-.16*e.wheelDeltaX),O.y=e.wheelDeltaY?-.16*e.wheelDeltaY:-.16*e.wheelDelta;else{if(!("detail"in e))return;O.y=e.detail}tt(g,!0);var t=w.x-O.x,o=w.y-O.y;(_.modal||t<=u.min.x&&t>=u.max.x&&o<=u.min.y&&o>=u.max.y)&&e.preventDefault(),h.panTo(t,o)},toggleDesktopZoom:function(e){e=e||{x:b.x/2+Be.x,y:b.y/2+Be.y};var t=_.getDoubleTapZoom(!0,h.currItem),o=g===t;h.mouseZoomedIn=!o,h.zoomTo(o?h.currItem.initialZoomLevel:t,e,333),p[(o?"remove":"add")+"Class"](m,"pswp--zoomed-in")}}});function mo(){ho&&clearTimeout(ho),fo&&clearTimeout(fo)}function po(){var e=Co(),t={};if(!(e.length<5)){var o,n=e.split("&");for(a=0;a<n.length;a++)!n[a]||(o=n[a].split("=")).length<2||(t[o[0]]=o[1]);if(_.galleryPIDs){for(var i=t.pid,a=t.pid=0;a<Yt.length;a++)if(Yt[a].pid===i){t.pid=a;break}}else t.pid=parseInt(t.pid,10)-1;t.pid<0&&(t.pid=0)}return t}var ho,_o,fo,go,vo,wo,o,bo,yo,$o,L,ko,xo={history:!0,galleryUID:1},Co=function(){return L.hash.substring(1)},To=function(){var e,t;fo&&clearTimeout(fo),at||l?fo=setTimeout(To,500):(go?clearTimeout(_o):go=!0,t=f+1,(e=Jt(f)).hasOwnProperty("pid")&&(t=e.pid),e=o+"&gid="+_.galleryUID+"&pid="+t,bo||-1===L.hash.indexOf(e)&&($o=!0),t=L.href.split("#")[0]+"#"+e,ko?"#"+e!==window.location.hash&&history[bo?"replaceState":"pushState"]("",document.title,t):bo?L.replace(t):L.hash=e,bo=!0,_o=setTimeout(function(){go=!1},60))};B("History",{publicMethods:{initHistory:function(){var e,t;p.extend(_,xo,!0),_.history&&(L=window.location,bo=yo=$o=!1,o=Co(),ko="pushState"in history,-1<o.indexOf("gid=")&&(o=(o=o.split("&gid=")[0]).split("?gid=")[0]),a("afterChange",h.updateURL),a("unbindEvents",function(){p.unbind(window,"hashchange",h.onHashChange)}),e=function(){wo=!0,yo||($o?history.back():o?L.hash=o:ko?history.pushState("",document.title,L.pathname+L.search):L.hash=""),mo()},a("unbindEvents",function(){Q&&e()}),a("destroy",function(){wo||e()}),a("firstUpdate",function(){f=po().pid}),-1<(t=o.indexOf("pid="))&&"&"===(o=o.substring(0,t)).slice(-1)&&(o=o.slice(0,-1)),setTimeout(function(){K&&p.bind(window,"hashchange",h.onHashChange)},40))},onHashChange:function(){return Co()===o?(yo=!0,void h.close()):void(go||(vo=!0,h.goTo(po().pid),vo=!1))},updateURL:function(){mo(),vo||(bo?ho=setTimeout(To,800):To())}}}),p.extend(h,t)}}),((e,t)=>{"function"==typeof define&&define.amd?define(t):"object"==typeof exports?module.exports=t():e.PhotoSwipeUI_Default=t()})(this,function(){return function(n,s){function e(e){if(C)return!0;e=e||window.event,x.timeToIdle&&x.mouseUsed&&!v&&r();for(var t,o,n=(e.target||e.srcElement).getAttribute("class")||"",i=0;i<M.length;i++)(t=M[i]).onTap&&-1<n.indexOf("pswp__"+t.name)&&(t.onTap(),o=!0);o&&(e.stopPropagation&&e.stopPropagation(),C=!0,e=s.features.isOldAndroid?600:30,setTimeout(function(){C=!1},e))}function o(){var e=1===x.getNumItemsFn();e!==k&&(F(u,"ui--one-slide",e),k=e)}
21function t(){F(f,"share-modal--hidden",j)}function i(){for(var e,t,o,n,i="",a=0;a<x.shareButtons.length;a++)e=x.shareButtons[a],t=x.getImageURLForShare(e),o=x.getPageURLForShare(e),n=x.getTextForShare(e),i+='<a href="'+e.url.replace("{{url}}",encodeURIComponent(o)).replace("{{image_url}}",encodeURIComponent(t)).replace("{{raw_image_url}}",t).replace("{{text}}",encodeURIComponent(n))+'" target="_blank" class="pswp__share--'+e.id+'"'+(e.download?"download":"")+">"+e.label+"</a>",x.parseShareButtonOut&&(i=x.parseShareButtonOut(e,i));f.children[0].innerHTML=i,f.children[0].onclick=z}function a(e){for(var t=0;t<x.closeElClasses.length;t++)if(s.hasClass(e,"pswp__"+x.closeElClasses[t]))return!0}function r(){clearTimeout(S),A=0,v&&E.setIdle(!1)}function l(e){(e=(e=e||window.event).relatedTarget||e.toElement)&&"HTML"!==e.nodeName||(clearTimeout(S),S=setTimeout(function(){E.setIdle(!0)},x.timeToIdleOutside))}function c(e){y!==e&&(F(b,"preloader--active",!e),y=e)}function O(e){var t,o=e.vGap;!n.likelyTouchDevice||x.mouseUsed||screen.width>x.fitControlsWidth?(t=x.barsSize,x.captionEl&&"auto"===t.bottom?(p||((p=s.createEl("pswp__caption pswp__caption--fake")).appendChild(s.createEl("pswp__caption__center")),u.insertBefore(p,m),s.addClass(u,"pswp__ui--fit")),x.addCaptionHTMLFn(e,p,!0)?(e=p.clientHeight,o.bottom=parseInt(e,10)||44):o.bottom=t.top):o.bottom="auto"===t.bottom?0:t.bottom,o.top=t.top):o.top=o.bottom=0}function L(){function e(e){if(e)for(var t=e.length,o=0;o<t;o++){i=e[o],a=i.className;for(var n=0;n<M.length;n++)r=M[n],-1<a.indexOf("pswp__"+r.name)&&(x[r.option]?(s.removeClass(i,"pswp__element--disabled"),r.onInit&&r.onInit(i)):s.addClass(i,"pswp__element--disabled"))}}e(u.children);var i,a,r,t=s.getChildByClass(u,"pswp__top-bar");t&&e(t.children)}var d,u,m,p,h,_,f,g,v,w,b,y,$,k,x,C,T,S,E=this,P=!1,I=!0,j=!0,D={barsSize:{top:44,bottom:"auto"},closeElClasses:["item","caption","zoom-wrap","ui","top-bar"],timeToIdle:4e3,timeToIdleOutside:1e3,loadingIndicatorDelay:1e3,addCaptionHTMLFn:function(e,t){return e.title?(t.children[0].innerHTML=e.title,!0):(t.children[0].innerHTML="",!1)},closeEl:!0,captionEl:!0,fullscreenEl:!0,zoomEl:!0,shareEl:!0,counterEl:!0,arrowEl:!0,preloaderEl:!0,tapToClose:!1,tapToToggleControls:!0,clickToCloseNonZoomable:!0,shareButtons:[{id:"facebook",label:"Share on Facebook",url:"https://www.facebook.com/sharer/sharer.php?u={{url}}"},{id:"twitter",label:"Tweet",url:"https://twitter.com/intent/tweet?text={{text}}&url={{url}}"},{id:"pinterest",label:"Pin it",url:"http://www.pinterest.com/pin/create/button/?url={{url}}&media={{image_url}}&description={{text}}"},{id:"download",label:"Download image",url:"{{raw_image_url}}",download:!0}],getImageURLForShare:function(){return n.currItem.src||""},getPageURLForShare:function(){return window.location.href},getTextForShare:function(){return n.currItem.title||""},indexIndicatorSep:" / ",fitControlsWidth:1200},F=function(e,t,o){s[(o?"add":"remove")+"Class"](e,"pswp__"+t)},R=function(){return(j=!j)?(s.removeClass(f,"pswp__share-modal--fade-in"),setTimeout(function(){j&&t()},300)):(t(),setTimeout(function(){j||s.addClass(f,"pswp__share-modal--fade-in")},30)),j||i(),!1},z=function(e){var t=(e=e||window.event).target||e.srcElement;return n.shout("shareLinkClick",e,t),!(!t.href||!t.hasAttribute("download")&&(window.open(t.href,"pswp_share","scrollbars=yes,resizable=yes,toolbar=no,location=yes,width=550,height=420,top=100,left="+(window.screen?Math.round(screen.width/2-275):100)),j||R(),1))},A=0,M=[{name:"caption",option:"captionEl",onInit:function(e){m=e}},{name:"share-modal",option:"shareEl",onInit:function(e){f=e},onTap:function(){R()}},{name:"button--share",option:"shareEl",onInit:function(e){_=e},onTap:function(){R()}},{name:"button--zoom",option:"zoomEl",onTap:n.toggleDesktopZoom},{name:"counter",option:"counterEl",onInit:function(e){h=e}},{name:"button--close",option:"closeEl",onTap:n.close},{name:"button--arrow--left",option:"arrowEl",onTap:n.prev},{name:"button--arrow--right",option:"arrowEl",onTap:n.next},{name:"button--fs",option:"fullscreenEl",onTap:function(){d.isFullscreen()?d.exit():d.enter()}},{name:"preloader",option:"preloaderEl",onInit:function(e){b=e}}];E.init=function(){var t;s.extend(n.options,D,!0),x=n.options,u=s.getChildByClass(n.scrollWrap,"pswp__ui"),(w=n.listen)("onVerticalDrag",function(e){I&&e<.95?E.hideControls():!I&&.95<=e&&E.showControls()}),w("onPinchClose",function(e){I&&e<.9?(E.hideControls(),t=!0):t&&!I&&.9<e&&E.showControls()}),w("zoomGestureEnded",function(){(t=!1)&&!I&&E.showControls()}),w("beforeChange",E.update),w("doubleTap",function(e){var t=n.currItem.initialZoomLevel;n.getZoomLevel()!==t?n.zoomTo(t,e,333):n.zoomTo(x.getDoubleTapZoom(!1,n.currItem),e,333)}),w("preventDragEvent",function(e,t,o){var n=e.target||e.srcElement;
21n&&n.getAttribute("class")&&-1<e.type.indexOf("mouse")&&(0<n.getAttribute("class").indexOf("__caption")||/(SMALL|STRONG|EM)/i.test(n.tagName))&&(o.prevent=!1)}),w("bindEvents",function(){s.bind(u,"pswpTap click",e),s.bind(n.scrollWrap,"pswpTap",E.onGlobalTap),n.likelyTouchDevice||s.bind(n.scrollWrap,"mouseover",E.onMouseOver)}),w("unbindEvents",function(){j||R(),T&&clearInterval(T),s.unbind(document,"mouseout",l),s.unbind(document,"mousemove",r),s.unbind(u,"pswpTap click",e),s.unbind(n.scrollWrap,"pswpTap",E.onGlobalTap),s.unbind(n.scrollWrap,"mouseover",E.onMouseOver),d&&(s.unbind(document,d.eventK,E.updateFullscreen),d.isFullscreen()&&(x.hideAnimationDuration=0,d.exit()),d=null)}),w("destroy",function(){x.captionEl&&(p&&u.removeChild(p),s.removeClass(m,"pswp__caption--empty")),f&&(f.children[0].onclick=null),s.removeClass(u,"pswp__ui--over-close"),s.addClass(u,"pswp__ui--hidden"),E.setIdle(!1)}),x.showAnimationDuration||s.removeClass(u,"pswp__ui--hidden"),w("initialZoomIn",function(){x.showAnimationDuration&&s.removeClass(u,"pswp__ui--hidden")}),w("initialZoomOut",function(){s.addClass(u,"pswp__ui--hidden")}),w("parseVerticalMargin",O),L(),x.shareEl&&_&&f&&(j=!0),o(),x.timeToIdle&&w("mouseUsed",function(){s.bind(document,"mousemove",r),s.bind(document,"mouseout",l),T=setInterval(function(){2===++A&&E.setIdle(!0)},x.timeToIdle/2)}),x.fullscreenEl&&!s.features.isOldAndroid&&((d=d||E.getFullscreenAPI())?(s.bind(document,d.eventK,E.updateFullscreen),E.updateFullscreen(),s.addClass(n.template,"pswp--supports-fs")):s.removeClass(n.template,"pswp--supports-fs")),x.preloaderEl&&(c(!0),w("beforeChange",function(){clearTimeout($),$=setTimeout(function(){n.currItem&&n.currItem.loading?n.allowProgressiveImg()&&(!n.currItem.img||n.currItem.img.naturalWidth)||c(!1):c(!0)},x.loadingIndicatorDelay)}),w("imageLoadComplete",function(e,t){n.currItem===t&&c(!0)}))},E.setIdle=function(e){F(u,"ui--idle",v=e)},E.update=function(){P=!(!I||!n.currItem||(E.updateIndexIndicator(),x.captionEl&&(x.addCaptionHTMLFn(n.currItem,m),F(m,"caption--empty",!n.currItem.title)),0)),j||R(),o()},E.updateFullscreen=function(e){e&&setTimeout(function(){n.setScrollOffset(0,s.getScrollY())},50),s[(d.isFullscreen()?"add":"remove")+"Class"](n.template,"pswp--fs")},E.updateIndexIndicator=function(){x.counterEl&&(h.innerHTML=n.getCurrentIndex()+1+x.indexIndicatorSep+x.getNumItemsFn())},E.onGlobalTap=function(e){var t=(e=e||window.event).target||e.srcElement;if(!C)if(e.detail&&"mouse"===e.detail.pointerType)a(t)?n.close():s.hasClass(t,"pswp__img")&&(1===n.getZoomLevel()&&n.getZoomLevel()<=n.currItem.fitRatio?x.clickToCloseNonZoomable&&n.close():n.toggleDesktopZoom(e.detail.releasePoint));else if(x.tapToToggleControls&&(I?E.hideControls():E.showControls()),x.tapToClose&&(s.hasClass(t,"pswp__img")||a(t)))return void n.close()},E.onMouseOver=function(e){e=(e=e||window.event).target||e.srcElement;F(u,"ui--over-close",a(e))},E.hideControls=function(){s.addClass(u,"pswp__ui--hidden"),I=!1},E.showControls=function(){I=!0,P||E.update(),s.removeClass(u,"pswp__ui--hidden")},E.supportsFullscreen=function(){var e=document;return!!(e.exitFullscreen||e.mozCancelFullScreen||e.webkitExitFullscreen||e.msExitFullscreen)},E.getFullscreenAPI=function(){var e,t=document.documentElement,o="fullscreenchange";return t.requestFullscreen?e={enterK:"requestFullscreen",exitK:"exitFullscreen",elementK:"fullscreenElement",eventK:o}:t.mozRequestFullScreen?e={enterK:"mozRequestFullScreen",exitK:"mozCancelFullScreen",elementK:"mozFullScreenElement",eventK:"moz"+o}:t.webkitRequestFullscreen?e={enterK:"webkitRequestFullscreen",exitK:"webkitExitFullscreen",elementK:"webkitFullscreenElement",eventK:"webkit"+o}:t.msRequestFullscreen&&(e={enterK:"msRequestFullscreen",exitK:"msExitFullscreen",elementK:"msFullscreenElement",eventK:"MSFullscreenChange"}),e&&(e.enter=function(){return g=x.closeOnScroll,x.closeOnScroll=!1,"webkitRequestFullscreen"!==this.enterK?n.template[this.enterK]():void n.template[this.enterK](Element.ALLOW_KEYBOARD_INPUT)},e.exit=function(){return x.closeOnScroll=g,document[this.exitK]()},e.isFullscreen=function(){return document[this.elementK]}),e}}}),((e,t)=>{"function"==typeof define&&define.amd?define("waterfall",function(){return t}):"object"==typeof module&&module.exports?module.exports=t:e.waterfall=t})(this,function(o){function n(e){return window.getComputedStyle(e)}function t(e,t){return parseFloat(n(t)["margin"+e])||0}function i(e){return parseFloat(e)+"px"}function a(e){return parseFloat(e.style.top)}function r(e){return parseFloat(e.style.left||0)}function s(e){return parseFloat(n(e).width)}function l(e){return a(e)+parseFloat(n(e).height)+t("Bottom",e)}function c(e){return r(e)+s(e)+t("Right",e)}function d(e){e.sort(function(e,t){return l(t)-l(e)||r(t)-r(e)})}function e(e,t,o){e.style.position="absolute",e.style.top=i(t),e.style.left=i(o)}function u(e,t){return c(e[t-1])+s(e[t])<=s(o)}var m=(o="string"==typeof o?document.querySelector(o):o).children;m.length&&e(v=m[0],0,t("Left",v));for(var p,h,_=1;_<m.length&&u(m,_);_++)p=m[_-1],e(h=m[_],p.style.top,c(p)+t("Left",h));for(var f,g,v,w,b=new function(e){var t=e;d(t),this.add=function(e){t.push(e),d(t),t.pop()},this.min=function(){return t[t.length-1]},this.max=function(){return t[0]}}([].slice.call(m,0,_));_<m.length;_++)u(m,_)?(g=b.max(),e(m[_],a(g),c(g))):(g=b.max(),e(f=m[_],l(g),t("Left",f))),b.add(m[_]);v=o,w=b.max(),v.style.position="relative",v.style.height=i(l(w)+t("Bottom",w)),$(o).trigger("layoutComplete")}
21),$(document).ready(function(){var e=$(".meals_list .see_all");e.on("click",function(e){e.preventDefault();var t=$(this),o=t.siblings(".tags");t.hasClass("shown")?(t.removeClass("shown"),o.find(".ajaxed").hide(),o.find(".f_meals").show(),o.find(".words_padding").show(),scrollToElement(".meals_list",300),window.history&&history.pushState&&(e=location.href.substr(0,location.href.length-location.hash.length),history.replaceState({},document.title,e))):(t.addClass("shown"),0!==o.find(".ajaxed").length?(o.find(".f_meals").hide(),o.find(".words_padding").hide(),o.find(".ajaxed").show()):(o.append("<div class=loading-big></div>"),e={},t.hasClass("no_tags")&&(e={no_tags:1}),t.data("limit")&&(e.review_limit=t.data("limit")),$.ajax({type:"GET",url:document.location.pathname+($("body").hasClass("menu_page")?"/..":"")+"/load-meals",data:e,dataType:"json",success:function(e){o.find(".f_meals").hide(),o.find(".words_padding").hide(),o.append("<div class=ajaxed>"+e.html+"</div>"),o.find(".loading-big").remove(),t.hasClass("shown")||o.find(".ajaxed").hide()}})),window.history&&history.pushState&&history.replaceState({},document.title,"#allmeals"))}),"#load-meals"==location.hash&&(e.trigger("click"),scrollToElement(".meals_list",300),replaceHash("")),"#allmeals"!==location.hash||e.hasClass("shown")||e.click()}),$(document).ready(function(){AddMenu.init()});
21var AddMenu={init:function(){var e=$(".add_menu");e.length&&(e.click(AddMenu.show_form),"#upload_menu"===location.hash)&&e.click()},show_form:function(e){var n;return e.preventDefault(),logH(9341),$("#menu_upload_modal").length?openMenuForm():(n=is_mobile()?"tap":"click",e='<div class="review_overlay" id="menu_upload_modal"><div class="add_review_block only_photo" style="height:130px"><div class="title"><span class="comment_title_menu"></span><span class="close_btn"></span></div><img class="stub_loader" src="'+cdn_host+'/img/site/responsive/ajax-loader.gif" class="loader" /></div></div>',$("body").append(e),$.ajax({type:"GET",url:"/ajax/get_menu_add_form",data:{restaurant_id:$(".add_menu").data("rid")},dataType:"html",success:function(e){var t=$("#menu_upload_modal"),o=$(".add_review_block",t);o.html(e),openMenuForm(),$(".add_review_block .stub_loader").remove(),o.css("height",""),$(".close_btn",t).on(n,function(e){e.preventDefault(),menu_upload_action.conf.uploadInProgress||closeMenuForm()}),$(".close_btn_grey",t).on(n,function(e){e.preventDefault(),menu_upload_action.conf.uploadInProgress?menu_upload_action.abortUpload():closeMenuForm()}),t.on(n,function(e){$(e.target).hasClass("remove-img")||t.find(".add_review_block").is(e.target)||0!=t.find(".add_review_block").has(e.target).length||(closeMenuForm(),e.preventDefault())}),0<$("div[data-fuse]").length&&0<$(".publift-widget").length&&$(".review_overlay").css({bottom:"90px"})}})),!1}};function openMenuForm(){var e=$("#menu_upload_modal");e.show(),$("body").addClass("overflow"),$(".review_form > .error_msg",e).html(""),$(".form_elmnt > input,textarea",e).removeClass("error"),$(".add_review_block",e).addClass("only_photo"),$(".non_photo",e).hide(),$(".comment_title_photo",e).show(),$(".comment_title_common",e).hide()}function closeMenuForm(){if(logH(9342),menu_upload_action.conf.uploadInProgress)return alert("Uploading in progress. Use cancel button for force quit"),!1;"#upload"==location.hash&&window.replaceHash(""),menu_upload_action.conf.resetMenuForm?$("#menu_upload_modal").remove():$("#menu_upload_modal").hide(),$("body").removeClass("overflow"),menu_upload_action.isNeedReloadPage()&&location.reload()}$(document).ready(function(){function o(e){return"rg-widget-"+e}function t(e,t){$('<div id="'+o(t)+'" class="rgw_wrap"><div class="rgw_frame"><a class="rgw_link" href="'+e+'" >by Restaurant Guru </a></div></div>').appendTo(document.body),$("<script />",{type:"text/javascript",src:"https://cdn.restaurantguru.com/js/photo_widget.js?9",async:!0}).appendTo(document.body)}function n(e){"undefined"!=typeof RGWdgt?e():(RestaurantGuruWidgetInitCallbacks=window.RestaurantGuruWidgetInitCallbacks||[]).push(e)}var i,e=new URL(window.location.href);"undefined"!=typeof PhotoWidgetConfig&&PhotoWidgetConfig.website_link?(t(window.location.href.split("?")[0],PhotoWidgetConfig.restaurant_id),$("body").addClass("overflow"),$('<iframe  id="website-iframe" sandbox="allow-modals allow-scripts allow-same-origin"></iframe>').prependTo(document.body),$("#website-iframe").load(function(){$(".rgw_wrap").addClass("loaded"),n(function(){RGWdgt.show({container_id:o(PhotoWidgetConfig.restaurant_id),title:PhotoWidgetConfig.title,address:PhotoWidgetConfig.address,nomination:PhotoWidgetConfig.nomination,share_url:PhotoWidgetConfig.share_url,copy_url:PhotoWidgetConfig.copy_url})})}),$("#website-iframe").attr({src:PhotoWidgetConfig.website_link})):"#rg-photo-widget"!=e.hash&&!e.searchParams.has("rg_photo_widget")||(i=$(".add_review_btn.add_review_action").data("rid"),$.ajax({method:"GET",url:"/ajax/get-photo-widget-data?id="+i,dataType:"json",success:function(e){e.status&&(t(window.location.href.split("?")[0],i),n(function(){RGWdgt.show({container_id:o(i),title:e.title,address:e.address,nomination:e.nomination,share_url:e.share_url,copy_url:e.copy_url})}))}}))});var comments_actions=(h=>({conf:{object_id:0,object_url:"",object_title:"",object_type:"program",comment_id:0,lang_id:0,user_id:0,comment_form_hidden:!1,vote_delete_url:"/ajax/comment_vote_delete",vote_toggle_url:"/ajax/comment_vote_toggle",vote_create_url:"/ajax/comment_vote_create",load_comments_url:"/ajax/load_comments",add_comment_url:"",delete_comment_url:"/ajax/comment_delete",remove_image_url:"",translate_comment_url:"",rating_actions:".votelinks:not(.no_vote) .comment-up, .votelinks:not(.no_vote) .comment-down",up_class:"comment-up",down_class:"comment-down",rating:".comment-rating",positive_rating:"green",reply_class:"link_reply",edit_class:"cmnt_edit",delete_class:"link_delete",cancel_class:"link_cancel",wrap_comment_form:".wrap_form",moderation_info:".moderation_info",comment_form:"#comment_form",comment_form_:"#comment_form_",comments_holder:".wrap_comments",native_comments_nav:"#wrap_comments_ml",reply_text:"Reply",cancel_text:"Cancel",invalid_email:"Invalid e-mail format",wrap_comment_reply:"form_reply",replies_notice:"replies_notice",translate_button:"translate_button",comment_mdl_window_btn:"",comment_mdl_close_btn:"",comment_mdl_window:"",comment_mdl_window_ovrl:"",remove_image_btn:".remove-img",one_comment_for_object:"",fb_app_id:"",fb_comm_url:"",object_rating:{enabled:!1,url:"",vote_stars_btn:".stars-rating .one-star",stars_in_article_wrap_cl:"stars-in-article",stars_in_article:".rate_blue",stars_in_article_my:"#my_vote",all_rating_info:"#rate_info",all_rating_number:"#rating",all_rating_votes:"#votes_count",all_rating_stars:".rate_red",rate_thx:".rate_thx"},comment_subscribe_link:"#comment_subscribe_link",subscribe_form_wrapper:"#subscribe_form_wrapper",subscribe_to_comments_url:"",comment_subscribe_form:"#comment_subscribe_form",form_subscribed_message:"",subscribe_comments_error:"#subscribe_comments_error",form_subscription_error_message:"",form_subscription_error_block:"#form_subscription_error_block",subscribe_comments_result_block:"#subscribe_comments_result",domain:document.location.hostname,show_fb_comments:!1,dont_clear_on_load:!1,comments_count_selector:".cc",comment_pics_url:"/ajax/load_comment_pics",max_image_size:6291456,max_images_count:5,author_node_selector:".comments__author .author_name",comments_container_selector:"#comments_container",comment_selector:".comments__container",comment_text_selector:".comments__text",user_info__name:".user_info .user_info__name",comment_reply_link_selector:"a.reply_link",comment_form_loading_selector:".comment_form_loading",comment_form_pics_selector:".cmnt_pics",comment_pics_selector:".cmnt_pics.wrap-images",cancel_images_uploading:"/ajax/cancel_images_uploading"},iter:0,autosaveTimer:!1,is_fb_form_loaded:!1,comment_images:{},sorting:null,$form_comment_node:null,deletion_comment_node:null,fileType:["image/png","image/jpg","image/jpeg"],cancel_uploading_trigger:!1,comment_data_authform:null,max_comment_id:0,canCheckNeuro:!0,init:function(e){h.extend(!0,this.conf,e);e=document.querySelector(this.conf.comments_container_selector).dataset;this.initial_count=+e.initial_count,this.initForm(),this.comments_holder_node=document.querySelector(this.conf.comments_holder),this.bindActions(),this.conf.one_comment_for_object||h(this.conf.comment_form).find('[name="content"]').val("")},onLoadActions:function(e){this.checkIsNeedFBinit(e)},bindActions:function(){var o=this;this.initSort(),h(this.conf.comments_holder).on("click",".cmnt_load_answers",this.loadComments.bind(this)),h(this.conf.comments_holder).on("click",".cmnt_load_parents",this.loadParents.bind(this)),this.initCommentsActions(this.comments_holder_node),this.initPics(this.comments_holder_node),this.initConfirmNode(),h(o.conf.comments_holder).on("click","."+o.conf.cancel_class,e=>{this.cancelUploading(),this.cancelReplyForm(e)}),h(o.conf.comment_form_).on("submit",function(e){o.validateCommentForm(e)}),h(o.conf.comment_form_).on("change","#"+o.conf.replies_notice,function(e){o.setDenialRepliesNotice(e)}),h(o.conf.comment_form_).on("click",'[name="content"]',function(e){o.showCommentFormFields()}),h(o.conf.comments_holder).on("click","."+o.conf.translate_button,function(e){o.commentTranslate(e)}
21),h(o.conf.comment_mdl_window_btn).click(function(e){o.showHideCommentForm(e)}),h(o.conf.comment_mdl_close_btn).click(function(e){o.showHideCommentForm(e)}),h(o.conf.comment_mdl_window_ovrl).click(function(e){h(e.target).parents().hasClass("dm-modal")||h(e.target).hasClass("remove-img")||o.showHideCommentForm(e)}),h(o.conf.remove_image_btn).click(function(e){o.removeImage(e)}),h(function(e){o.onLoadActions(e)}),o.conf.object_rating.enabled&&h(o.conf.object_rating.vote_stars_btn).on("click",function(e){o.addObjectVote(e)}),h("."+o.conf.cancel_class).hide(),h(o.conf.comment_subscribe_form).on("submit",function(e){o.validateSubscribeForm(e)}),o.resizeTextareaOnInput(),h(document).on("scroll.fbInit",function(e){o.checkIsNeedFBinit(e)}),h(document).on("scroll",function(e){window.scrollY>h(".wrapper_comments").position().top&&!o.is_fb_form_loaded&&(o.is_fb_form_loaded=!0,o.showFBCommentsForm(e))}),h(document).on("fb.loaded",function(e,t){o.scrollToCommentIfHash()}),h(document).on("fb.comment_create",function(e,t){o.onFbCommentCreate(t)}),h(document).on("fb.comment_remove",function(e,t){o.onFbCommentRemove(t)}),o.loadCommentDelay(),this.initResumable(),h(window).load(function(){var e=new URLSearchParams(location.search).get("comment");h.scrollTo("#comment-"+e)})},initForm:function(){this.form_node=document.querySelector(this.conf.comment_form_),this.form_imgs=this.form_node.querySelector('input[name="file[]"]'),this.form_pics=this.form_node.querySelector(this.conf.comment_form_pics_selector),this.form_img_ids_for_deletion=[],"undefined"!=typeof app_params&&void 0!==app_params.pierre_check_comments&&this.checkComment(this,+app_params.pierre_check_comments)},initResumable:function(){let o=this;this.r=new Resumable({target:this.conf.comment_upload_image_url,fileType:this.fileType,maxFiles:this.conf.max_images_count,simultaneousUploads:1,maxFileSize:this.conf.max_image_size,uploadMethod:"POST",testMethod:"POST",testChunks:!1,maxFilesErrorCallback:()=>{h(".comments_file_error",o.conf.comment_form_).html(_("error_photo_count")).show()}}),this.r.assignBrowse(h('[name="file[]"]',o.conf.comment_form_)[0]),this.r.on("fileProgress",function(e){o.progressFile(e)}),this.r.on("complete",this.resumableComplete.bind(this)),this.r.on("fileAdded",function(e,t){o.canCheckNeuro=!1,o.renderImagePreview(e.file)})},resumableComplete:function(){this.comment_data_authform?(this.getLoginForm(this.comment_data_authform),this.comment_data_authform=null):this.cancel_uploading_trigger?(this.cancel_uploading_trigger=!1,this.afterSubmitComment()):(null!=window.replaceHash&&"#upload"===location.hash&&window.replaceHash(""),+this.form_data.get("cid")?this.submitCommentForm(this.form_data,!0):this.handleFormResponse())},cancelUploading:function(){if(this.form_data&&!h.isEmptyObject(this.comment_images))if(this.cancel_uploading_trigger=!0,void 0!==this.r&&this.r.cancel(),+this.form_data.get("cid")){var e=+this.form_data.get("cid");let t=0,o=h(`#comment-${e} ${this.conf.comment_pics_selector} img`);o.each(e=>{e=+o[e].dataset?.ci_id;e>t&&(t=e)}),this.send(this.conf.cancel_images_uploading,{comment_id:e,max_ci_id:t},null)}else this.send(this.conf.delete_comment_url,{id:this.form_resp.comment_id,parent_id:this.form_data.parent},null)},initConfirmNode:function(){this.$confirm_node=h(`
22                <div class="comments__notice${is_mobile()?" mobile":" desktop"}">
23                    <p>${_("delete_comment_question")}</p>
24                    <div class="comments__buttons">
25                        <button class="delete" type="button">${_("delete")}</button>
26                        <button class="cancel" type="button">${_("cancel")}</button>
27                    </div>
28                </div>
29            `),this.$confirm_node.find(".delete").click(this.deleteComment.bind(this)),this.$confirm_node.find(".cancel").click(()=>{this.closeConfirmationDeletion()})},initCommentsActions:function(t){h(t).on("click","."+this.conf.delete_class,this.showConfirmDeletion.bind(this)),h(t).on("click","."+this.conf.reply_class,this.showReplyForm.bind(this)),h(t).on("click","."+this.conf.edit_class,this.showEditForm.bind(this)),h(t).on("click",this.conf.rating_actions,this.voteToComment.bind(this)),t.querySelectorAll(this.conf.comment_selector+':not([data-parent="0"])').forEach(e
29=>this.init_reply_link(e,t))},initPics:function(e){CommentsGallery.init(e)},init_reply_link:function(e,t=null){var o="#comment-"+e.dataset.reply;let n=t?.querySelector(o)||document.querySelector(o);n&&(t=n.dataset.author,0===(e=e.querySelector(this.conf.comment_text_selector)).innerHTML.trim().indexOf("@"+t)&&(e.innerHTML=e.innerHTML.replace("@"+t,`<a class="reply_link" href="${o}">@${t}</a>`)),o=e.querySelector(this.conf.comment_reply_link_selector))&&(o.onclick=e=>{e.preventDefault(),this.scrollIntoView(n)})},scrollIntoView:function(e){console.log(e);var t=window_match_media(1030,"max")?h(".wrapper_header").outerHeight():54,e=h(e).offset().top;h(document).scrollTop(e-(t+5))},initSort:function(){var e=document.querySelector(".sorting_block");if(e){let n=e.querySelector(".sorting_link"),i=e.querySelector(".sorting_dropdown_list"),a=i.querySelector(".active"),r=(this.sorting=a.dataset.sorting,document.querySelector(".cmnt_load_parents"));i.querySelectorAll("li").forEach(e=>e.onclick=o=>{if(!o.currentTarget.classList.contains("active")){let t=o.target.dataset.sorting;var e={object_id:this.conf.object_id,lang_id:this.conf.lang_id,object_type:this.conf.object_type,sorting:t};this.send(this.conf.load_comments_url,e,e=>{e.status&&(this.cancelReplyForm(),o.target.classList.add("active"),a.classList.remove("active"),n.innerHTML=o.target.innerHTML,a=o.target,this.sorting=t,i.classList.remove("show_dropdown"),document.querySelector(this.conf.comments_container_selector).innerHTML=e.html,this.initCommentsActions(this.comments_holder_node),this.initPics(this.comments_holder_node),r.dataset.fragment_id=0,r.dataset.current_cnt=this.initial_count,r.dataset.cnt=e.parent_cnt,0<(e=e.parent_cnt-this.initial_count)?(r.classList.remove("hide"),r.querySelector("span").innerHTML="("+e+")"):r.classList.add("hide"),this.cntHandle())})}}),n.onclick=e=>{e.preventDefault(),i.classList.toggle("show_dropdown")},h(document).on("click",function(e){n.contains(e.target)||i.contains(e.target)||i.classList.remove("show_dropdown")})}},loadParents:function(e){this.loadComments(e,!1)},loadComments:function(o,n=!0,i=10){if(o.preventDefault(),!+o.currentTarget.dataset?.lock){o.currentTarget.dataset.lock=1;let e,t;var a=+o.currentTarget.dataset.current_cnt,a=(o.currentTarget.dataset.cnt,{object_id:this.conf.object_id,lang_id:this.conf.lang_id,object_type:this.conf.object_type,offset:a,limit:i,parent_id:0,max_comment_id:this.max_comment_id,fragment_id:o.currentTarget.dataset.fragment_id});n?(e=o.currentTarget.closest(this.conf.comment_selector),(t=e.querySelector(".childs")).classList.add("filled"),a.parent_id=e.dataset.cid):(t=document.querySelector(this.conf.comments_container_selector),a.sorting=this.sorting),this.send(this.conf.load_comments_url,a,this.loadCommentsHandler.bind(this,o,t,i))}},loadCommentsHandler:function(e,t,o,n){var i,a;!n.status||(i=+e.currentTarget.dataset.current_cnt,a=+e.currentTarget.dataset.cnt,h(t).append(this.handleHTML(n.html)),a<=(i+=o))?e.currentTarget.classList.add("hide"):(e.currentTarget.dataset.current_cnt=i,e.currentTarget.querySelector("span").innerHTML="("+(a-i)+")"),e.currentTarget.dataset.lock=0},handleHTML:function(e,t=this.conf.comment_selector,o=this.initCommentsActions.bind(this)){var n=document.createElement("div");return n.innerHTML=e,o(n),n.querySelectorAll(t)},loadCommentDelay:function(){if(!(0<parseInt(this.conf.user_id)))return!1;var e=getCookie("comment_delay");if(!e)return!1;e=JSON.parse(e);if(!parseInt(e.object_id)||parseInt(e.object_id)!=parseInt(this.conf.object_id))return!1;0<parseInt(e.reply)&&(t=h("#comment-"+e.reply).find("."+this.conf.reply_class))&&t.click();var t=h(this.conf.comment_form_);t.find("#comment_reply").html(e.reply),t.find("#comment_parent").html(e.parent),h(this.conf.comment_form_).find("textarea").val(e.content),this.unsetCommentDelay()},fbInit:function(e){var t=this,o={status:!0,cookie:!0,xfbml:!0,version:"v2.10",appId:e};"undefined"!=typeof FB?t.fbInitEvents(o):h.getScript("//connect.facebook.net/"+this.langToFbLang(t.conf.recaptcha.lang)+"/sdk.js",function(){t.fbInitEvents(o)})},fbInitEvents:function(e){FB.init(e),FB.Event.subscribe("xfbml.render",function(e){h(document).trigger("fb.loaded",e)}),FB.Event.subscribe("comment.create",function(e){h(document).trigger("fb.comment_create",e)}),FB.Event.subscribe("comment.remove",function(e){h(document).trigger("fb.comment_remove",e)})},checkIsNeedFBinit:function(e){h(".fb_wrap").is(":visible")&&h("#comment_conteiner").offset().top<=h(e.target).scrollTop()+h(window).height()&&(this.fbInit(this.conf.fb_app_id),h(document).off("scroll.fbInit"))},showFBCommentsForm:function(e){var t,o,n,i;this.conf.show_fb_comments?h.scrollTo(".fb_wrap",{duration:100}):(n=(t=h("#comment_conteiner")).height(),o=h(".link_fb"),t.height(n),n=h(".fb_wrap"),i=n.find(".fb-loading"),n.show(),i.show(),this.fbInit(this.conf.fb_app_id),h(document).on("fb.loaded",function(){t.he
29ight(""),i.hide(),o.removeClass("btn-loading").hide()}),h(document).off("scroll.fbInit"))},onFbCommentCreate:function(e){var t={object_id:this.conf.object_id,object_type:this.conf.object_type,type:"create"};this.sendPostRequest(this.conf.fb_comm_url,t)},onFbCommentRemove:function(e){var t={object_id:this.conf.object_id,object_type:this.conf.object_type,type:"remove"};this.sendPostRequest(this.conf.fb_comm_url,t)},sendPostRequest:function(e,t){h.ajax({type:"POST",url:e,data:t,dataType:"json"})},scrollToCommentIfHash:function(){-1!==location.hash.indexOf("comment-")&&setTimeout(function(){h.scrollTo(location.hash)},1e3)},langToFbLang:function(e){var t={ar:"ar_AR",de:"de_DE",el:"el_GR",en:"en_US",es:"es_ES",fr:"fr_FR",it:"it_IT",ja:"ja_JP",nl:"nl_NL",pt:"pt_BR",ro:"ro_RO",ru:"ru_RU",tr:"tr_TR"};return e in t?t[e]:"en_US"},resizeTextareaOnInput:function(){},renderRecaptcha:function(){grecaptcha.render("googlerecaptcha",{sitekey:comments_actions.conf.recaptcha.sitekey})},recaptchaInit:function(){"undefined"!=typeof grecaptcha?this.renderRecaptcha():(window.renderRecaptcha=this.renderRecaptcha,h.getScript("//www.google.com/recaptcha/api.js?hl="+this.conf.recaptcha.lang+"&render=explicit&onload=renderRecaptcha"))},showCommentFormFields:function(){var e,t=h(this.conf.comment_form_);t.find("[name=content]").addClass("height80"),t.find("#cmtnInputWrapper").removeClass("hide"),this.conf.user_id||(t.find(".top_wrap.first").fadeIn(600),t.find(".top_wrap.second").fadeIn(600)),t.find(".c-input-submit").fadeIn(600),t.find(".gray").fadeIn(600),!this.conf.recaptcha.enabled||(e=h("#googlerecaptcha")).length&&!e.is(":empty")||(t.find(".submit-block").addClass("height80"),t.find(".c-voting").addClass("flright"),this.recaptchaInit())},voteToComment:function(e){e.preventDefault();let i,t,a,r=e.currentTarget,s=r.closest(".votelinks");if(!+s.dataset?.lock){s.dataset.lock=1;let o=r.classList.contains("comment-up"),n=o?s.querySelector(".comment-up-cnt"):s.querySelector(".comment-down-cnt");if(r.classList.contains("selected"))i=this.conf.vote_delete_url,a=e=>{e.status&&(n.innerHTML=+n.innerHTML-1,r.classList.remove("selected"))};else{let t=o?s.querySelector(".comment-down"):s.querySelector(".comment-up");a=t.classList.contains("selected")?(i=this.conf.vote_toggle_url,e=>{e.status&&(e=o?s.querySelector(".comment-down-cnt"):s.querySelector(".comment-up-cnt"),n.innerHTML=+n.innerHTML+1,e.innerHTML=+e.innerHTML-1,r.classList.add("selected"),t.classList.remove("selected"))}):(i=this.conf.vote_create_url,e=>{e.status&&(n.innerHTML=+n.innerHTML+1,r.classList.add("selected"))})}e=s.closest(this.conf.comment_selector);t=this.makeVoteRequest(e,o),this.send(i,t,e=>{a(e),s.dataset.lock=0})}},makeVoteRequest:function(e,t){return{is_like:t?1:0,comment_id:e.dataset.cid}},deleteComment:function(e){e.preventDefault();var t=e.currentTarget;+e.currentTarget.dataset?.lock||(e.currentTarget.dataset.lock=1,this.deleteCommentDirectly(this.deletion_comment_node,t))},deleteCommentDirectly:function(t,o=null){let n=t.dataset.cid;this.send(this.conf.delete_comment_url,this.makeDeletionRequest(t),e=>{if(e.status){let e;+t.dataset.parent||(t.querySelectorAll(this.conf.comment_selector).length,(e=t.querySelector(".cmnt_load_answers"))&&!e.classList.contains("hide")&&(e.dataset.cnt,e.dataset.current_cnt)),this.cntHandle(),n<this.max_comment_id&&(e=+t.dataset.parent?t.closest('[data-parent="0"]').querySelector(".cmnt_load_answers"):document.querySelector(".cmnt_load_parents"))&&(e.dataset.current_cnt=+e.dataset.current_cnt-1,e.dataset.cnt=+e.dataset.cnt-1),o?(o.dataset.lock=0,this.closeConfirmationDeletion(!0)):t.remove()}})},makeDeletionRequest:function(e){return{object_id:this.conf.object_id,object_type:this.conf.object_type,id:e.dataset.cid,parent_id:e.dataset.parent}},showConfirmDeletion:function(e){e.preventDefault(),this.closeConfirmationDeletion(),this.cancelReplyForm(),this.deletion_comment_node=e.currentTarget.closest(this.conf.comment_selector),this.deletion_comment_node.classList.add("delete_action"),h(this.deletion_comment_node.querySelector(".comments__panel")).after(this.$confirm_node)},closeConfirmationDeletion:function(e=!1){this.$confirm_node[0].remove(),this.deletion_comment_node&&(this.deletion_comment_node.classList.remove("delete_action"),e&&this.deletion_comment_node.remove(),this.deletion_comment_node=null)},send:function(e,t,o){h.ajax({type:"POST",url:e,data:t,dataType:"json"}).done(o)}
29,showEditForm:function(e){this.showForm(e);var e=h(this.conf.wrap_comment_form),t=this.$form_comment_node.data("cid");this.commentPicsToForm(this.$form_comment_node,e),e.find("#comment_cid").val(t),e.find("textarea").val(this.getCommentText()),e.find("#replies_notice_wrapper").hide()},commentPicsToForm:function(e,t){let o=this;e=e.find(this.conf.comment_pics_selector);e&&e.find("img").each(function(){var e=h("<img />",{src:h(this).attr("src"),"data-ci_id":h(this).data("ci_id")});o.renderFormPic(e,t.find(o.conf.comment_form_pics_selector))})},getCommentText:function(){let e;var t=this.$form_comment_node[0].querySelector(this.conf.comment_text_selector),o=t.querySelector(this.conf.comment_reply_link_selector),t=t.innerHTML.trim();return e=o?o.innerHTML.trim()+" "+t.substring(t.indexOf("/a>")+4):t},showReplyForm:function(e){this.showForm(e);e=this.$form_comment_node.find(this.conf.author_node_selector)[0];e.querySelector("a")||(e.innerHTML=`<a href="#">${this.$form_comment_node.data("author")}</a>`),document.querySelector('#comment_form_ textarea[name="content"]').value=`@${this.$form_comment_node.data("author")} `},showForm:function(e){e.preventDefault(),this.cancelReplyForm(e);var e=h(e.currentTarget),t=(this.$form_comment_node=e.closest(this.conf.comment_selector),this.closeConfirmationDeletion(),this),o=h(t.conf.wrap_comment_form),n=this.$form_comment_node.data("parent")||this.$form_comment_node.data("cid"),i=this.$form_comment_node.data("cid")||0;this.scrollIntoView(o[0]),h("."+t.conf.cancel_class).show(),e.parents(".comments__panel").after(o),o.find("#comment_parent").val(n),o.find("#comment_reply").val(i),h(this.conf.comments_container_selector).find("."+t.conf.wrap_comment_reply).removeClass(t.conf.wrap_comment_reply),h("#comment-"+i).find(".comments__item").addClass(t.conf.wrap_comment_reply),t.showCommentFormFields(),o.find(".error").removeClass("error"),o.find(".comments_error").html(""),h(".link_fb").hide(),t.conf.comment_form_hidden&&o.show()},cancelReplyForm:function(e=null){e&&e.preventDefault(),this.cancelImgs();var t,o,e=this,n=h(e.conf.wrap_comment_form),i=n.find("#comment_reply").val();h(".wrapper_cmnt_form .content").append(n),h("#comment-"+n.find("#comment_reply").val()).find(".comments__item").removeClass(e.conf.wrap_comment_reply),!+n.find("#comment_cid").val()&&+i&&(o=(t=document.querySelector(`#comment-${i} `+this.conf.author_node_selector)).querySelector('a[href="#"]'))&&(t.innerHTML=o.innerHTML),n.find("#comment_parent").val(0),n.find("#comment_reply").val(0),n.find("#comment_cid").val(0),n.find("#replies_notice_wrapper").show(),h("."+e.conf.cancel_class).hide(),e.conf.one_comment_for_object||n.find("textarea").val(""),n.find(".error").removeClass("error"),n.find(".comments_error").html(""),this.conf.comment_form_hidden?n.hide():h(".link_fb").show(),+i&&document.querySelector("#comment-"+i).scrollIntoView(),e.afterSubmitComment(),this.$form_comment_node=null},cancelImgs:function(){this.comment_images={},this.form_img_ids_for_deletion=[],this.form_imgs.value="",this.form_pics.innerHTML="",void 0!==this.r&&this.r.cancel()},setCommentDelay:function(e){var t={path:"/",domain:window.location.hostname,expires:3600};setCookie("comment_delay",e,t)},unsetCommentDelay:function(){var e={path:"/",domain:window.location.hostname,expires:0};e.expires=0,setCookie("comment_delay","",e)}
29,validateCommentForm:function(e){e.preventDefault();var e=h(e.currentTarget),t=(e.find("[name=content]"),h.trim(e.find("[name=name]").val())),o=h.trim(e.find("[name=email]").val()),n=h.trim(e.find("[name=content]").val()),i=e.find("#comment_parent").val(),a=e.find("#comment_reply").val(),r=a?h("#comment-"+a).data("author"):"",r=r?h.trim(r+","):"",s=e.find("#replies_notice").prop("checked")?"1":"0",l=+e.find("#comment_cid").val(),c={};if(this.conf.user_id||l||(t||(this.addErrorToField(e.find("[name=name]")),c[this.conf.no_fields_text]=!0),o&&(/.+@.+\..+/i.test(o)||(this.addErrorToField(e.find("[name=email]")),c[this.conf.invalid_email]=!0))),n&&n!=r||(this.addErrorToField(e.find("[name=content]")),c[this.conf.no_fields_text]=!0),!h.isEmptyObject(c)){var d,u="";for(d in c)u+=d+"<br>";return u=u.substring(0,u.length-4),h(".comments_error").html(u).addClass("show"),!1}h(".comments_error").html("").removeClass("show");var m,p=new FormData;for(m of this.form_img_ids_for_deletion)p.append("img_ids_for_deletion[]",m);r={cid:l,name:t,email:o,content:n,parent:i,reply:a,replies_notice:s,object_id:this.conf.object_id,object_url:this.conf.object_url,object_title:this.conf.object_title,object_type:this.conf.object_type,lang_id:this.conf.lang_id,user_id:this.conf.user_id,g_recaptcha_response:h("#g-recaptcha-response").val()};if(h.each(r,function(e,t){p.append(e,t)}),!r.user_id&&r.email&&0<r.email.length)return this.needLoginOrSubmit(r,p),!1;this.submitCommentForm(p)},addErrorToField:function(e){e.addClass("error").keyup(function(){e.removeClass("error").unbind("keyup")})},needLoginOrSubmit:function(e,t){var n=this,i=h('#comment_form_ [type="submit"]'),a=h(".comment_form_loading"),r=e,s=t;n.comment_data_authform=null,i.prop("disabled",!0).addClass("btn-loading"),a.css("display","inline-block"),h.ajax({type:"POST",url:this.conf.comment_get_user,data:t,dataType:"json",processData:!1,contentType:!1}).done(function(e){h(n.conf.comment_form);if(i.prop("disabled",!1).removeClass("btn-loading"),a.css("display","none"),e&&e.status&&1==e.status){var t,o=[];for(t in n.comment_images)o.push({name:n.comment_images[t].name,size:n.comment_images[t].size});n.comment_data_authform=r,n.comment_data_authform.cmt_images=o,n.comment_data_authform.img_ids_for_deletion=n.form_img_ids_for_deletion,n.r.upload()}else n.submitCommentForm(s)})},getLoginForm:function(e){this.setCommentDelay(JSON.stringify(e)),getLoginForm(h(this.conf.comment_form_+' input[name="email"]').val())},checkComment:function(o,e){let n=0,i='<span class="moderation_info test">'+_("comment_moderation")+"</span>",a=setInterval(function(){if(n<20){let t=h("#comment-"+e);0<t.length&&o.canCheckNeuro&&(t.find(".user_info__head .moderation_info").length||t.find(".user_info__head").append(i),h.ajax({type:"POST",url:h(location).attr("origin")+"/ajax/check_comment",data:{id:e},dataType:"json"}).done(e=>{"approved"===e.status&&t.find(o.conf.moderation_info).remove()}),clearInterval(a)),n++}else clearInterval(a)},300)},submitCommentForm:function(e,i=!1){var a=this,t=(void 0!==this.conf.csrf_token&&e.append("csrf_token",this.conf.csrf_token),this.form_data=e,h(this.conf.comment_form_+' [type="submit"]')),r=h(this.conf.comment_form_loading_selector);if(t.prop("disabled",!0).addClass("btn-loading"),r.css("display","inline-block"),!i&&+e.get("cid")&&!h.isEmptyObject(this.comment_images))return this.processImages(+e.get("cid"));h.ajax({type:"POST",url:this.conf.add_comment_url,data:e,dataType:"json",processData:!1,contentType:!1}).done(e=>{var t=e.comment_id,o=h(a.conf.comment_form),n=e.skip_neuro;e.status?(this.form_resp=e,a.conf.one_comment_for_object&&h("#comment-"+t).remove(),h(a.conf.comments_holder).closest(".comments_section").show(),i||h.isEmptyObject(this.comment_images)?this.handleFormResponse():this.processImages(t)):(h(".comments_error").html(e.msg).show(),void 0===e.recaptcha?this.cancelReplyForm():(r.css("display","none"),o.find(".error").removeClass("error"),o.find(".comments_error").html(""),h(this.conf.comment_form_+' [type="submit"]').prop("disabled",!1))),n||a.checkComment(a,t)})},handleFormResponse:function(){var e,t,o=this.form_data,n=this.form_resp;+o.get("cid")?((o=document.querySelector("#comment-"+o.get("cid"))).querySelector(this.conf.comment_text_selector).innerHTML=n.comment,void 0!==n.author_name&&n.author_name&&(e=o.querySelector(this.conf.user_info__name))&&(t=e.innerHTML.replace(/^[^<(]*/,n.author_name+" "),e.innerHTML=t.trim()),+o.dataset.reply&&this.init_reply_link(o),this.renderCommentPics(o)):this.handleFormResponseOnNew(),n.show_captcha&&(!(e=h("#googlerecaptcha")).length||e.is(":empty")?((t=h(this.form_node)).find(".submit-block").addClass("height80"),t.find(".c-voting").addClass("flright"),t.find(".rating_title").show(),this.recaptchaInit()):grecaptcha.reset()),this.cancelReplyForm()},renderCommentPics:function(t,e=!1){!e&&h.isEmptyObject(this.comment_images)&&!this.form_img_ids_for_deleti
29on.length||this.send(this.conf.comment_pics_url,{id:t.dataset.cid},e=>{this.commentPicsHandler(e,t)})},handleFormResponseOnNew:function(){let e=+this.form_data.get("parent"),t=+this.form_data.get("reply"),o=h(this.form_resp.comment)[0],n=!h.isEmptyObject(this.comment_images)||this.form_img_ids_for_deletion.length;this.cntHandle(()=>{this.init_reply_link(o),0<t?e==t?h("#comment-"+e+" .childs").prepend(o):h("#comment-"+t).after(o):h(this.conf.comments_container_selector).prepend(o),0===this.max_comment_id&&(this.max_comment_id=this.form_resp.comment_id),this.renderCommentPics(o,n)})},commentPicsHandler:function(e,t){var o;e.status&&(o=t.querySelector(this.conf.comment_pics_selector),e.html?o?o.replaceWith(h(e.html)[0]):t.querySelector(this.conf.comment_text_selector).after(h(e.html)[0]):o&&o.remove(),this.initPics(t))},afterSubmitComment:function(){h(this.conf.comment_form_).find('[type="submit"]').prop("disabled",!1).removeClass("btn-loading"),h(".comment_form_loading").css("display","none")},cntHandle:function(e=null){this.send("/ajax/get_comment_count",{object_id:this.conf.object_id,locale:window.locale,lang_id:this.conf.lang_id,object_type:this.conf.object_type},t=>{t.status&&(document.querySelectorAll(".cc_wrap").forEach(e=>{0<+t.count?e.classList.remove("hide"):e.classList.add("hide"),e.querySelector(this.conf.comments_count_selector).innerHTML=t.count+" "+t.word}),e)&&e()})},processImages:function(e){this.r.opts.query={csrf_token:this.conf.csrf_token,comment_id:e,object_type:"restaurant"},null!=window.json_arr.upload_menu_source&&(this.r.opts.query.source=window.json_arr.upload_menu_source),this.r.upload()},progressFile:function(e){var t=h("."+e.uniqueIdentifier),o=(t.show(),t.find(".line")),e=100*e.progress();o.css("width",e+"%"),100==e&&(t.find(".btn_info").addClass("done"),t.hide())},renderImagePreview:function(t){var o=this;let e=_("error_photo_type");var n,i=h(".mdl-wrap-images",this.conf.comment_form_);if(h(".comments_file_error",o.conf.comment_form_).hide(),i.find("img").length>this.conf.max_images_count)h(".comments_file_error",o.conf.comment_form_).html(_("error_photo_count")).show();else{if(this.fileType.includes(t.type)){if("undefined"!=typeof FileReader)return t.size>this.conf.max_image_size?void h(".comments_file_error",o.conf.comment_form_).html(_("error_photo_size")).show():((n=new FileReader).onload=function(e){h("<img />",{src:e.target.result,error:()=>{h(".comments_file_error",o.conf.comment_form_).html(_("error_photo_broken")).show()},load:function(){o.renderFormPic(h(this),i,t),i.show(),o.comment_images[t.name]=t}})},n.readAsDataURL(t),!0);e=_("error_photo_browser")}h(".comments_file_error",o.conf.comment_form_).html(e).show()}return!1},renderFormPic:function(e,t,o=null){var n=h("<div>",{class:"img-content upload_wrapper"}),e=(e.appendTo(n),h("<span>",{class:"delete remove-img"}));e.appendTo(n),o&&(n.data("iter",o.name),h("<div>").addClass("progress_wrapper "+o.uniqueIdentifier).html('<div class="line_wrapper"><div class="line" style="width: 0;"></div></div><div class="btn_info"></div>').hide().appendTo(n)),e.click(e=>{this.removeImage(e)}),n.appendTo(t)},showHideCommentForm:function(e){var t;e.preventDefault(),h(this.conf.comment_mdl_window).is(":visible")?(t=(e=document.body).style.top,e.style.position="",e.style.top="",window.scrollTo(0,-1*parseInt(t||"0")),h(this.conf.comment_mdl_window).hide(),h(this.conf.comment_mdl_window_ovrl).hide(),h("body").removeClass("modal-open")):(h(this.conf.comment_mdl_window).show(),h(this.conf.comment_mdl_window_ovrl).show())},setDenialRepliesNotice:function(e){var e=h(e.currentTarget),t={path:"/",domain:"."+this.conf.domain};e.prop("checked")?(t.expires=0,setCookie("denial_replies_notice","",t)):(t.expires=31536e3,setCookie("denial_replies_notice",1,t))},commentTranslate:function(e){e.preventDefault();e=h(e.currentTarget);e.hasClass("original")?this.setCommentOriginal(e):this.setCommentTranslate(e)},setCommentTranslate:function(t){0===t.closest(".cmnt").find(".translate_loading").length&&h("img#load-"+t.data("id")).attr("style","");var e={comment_id:t.data("id"),lang_id:this.conf.lang_id,object_title_encoded:this.conf.object_title_encoded};
29h.ajax({type:"GET",url:this.conf.translate_comment_url,data:e,dataType:"json"}).done(function(e){e.status?(h("#comment-"+t.data("id")+" > .comment_content").hide(),h("#comment-"+t.data("id")+" > .comment_translate").html(e.content).show(),t.addClass("original").html(t.data("original"))):alert(e.error),h("img#load-"+t.data("id")).attr("style","display: none;")})},setCommentOriginal:function(e){h("#comment-"+e.data("id")+" > .comment_content").show(),h("#comment-"+e.data("id")+" > .comment_translate").hide(),e.removeClass("original").html(e.data("translate"))},addObjectVote:function(e){e.preventDefault();var t=h(e.currentTarget),e=t.hasClass("active")?0:t.attr("data-rating"),o=this,e={star:e,object_id:o.conf.object_id};return h.ajax({type:"POST",url:o.conf.object_rating.url,data:e,dataType:"json"}).done(function(e){e.status?(h(o.conf.object_rating.vote_stars_btn).removeClass("active"),0!=e.my_vote&&h(o.conf.object_rating.vote_stars_btn+".st"+e.my_vote).addClass("active"),h(o.conf.object_rating.stars_in_article_my).html(e.my_vote),h(o.conf.object_rating.stars_in_article_my).attr("data-my-vote",e.my_vote),h(o.conf.object_rating.all_rating_number).length?(h(o.conf.object_rating.all_rating_number).html(e.rating),h(o.conf.object_rating.all_rating_votes).html(e.votes_count)):h(o.conf.object_rating.all_rating_info).html(e.votes_string),h(o.conf.object_rating.stars_in_article).css("width",20*e.my_vote+"%"),h(o.conf.object_rating.all_rating_stars).css("width",20*e.rating+"%"),t.parent().hasClass(o.conf.object_rating.stars_in_article_wrap_cl)&&0!=e.my_vote&&(h("."+o.conf.cancel_class).click(),h(o.conf.comment_form).find("textarea").focus(),o.showCommentFormFields(),h("html,body").animate({scrollTop:h(o.conf.native_comments_nav).offset().top},500),h(o.conf.object_rating.rate_thx).delay(300).fadeIn())):alert(e.error)}),!1},removeImage:function(e){var t=h(e.currentTarget),e=(e.preventDefault(),t.closest(".img-content")),t=e.find("img").data("ci_id");return t?this.form_img_ids_for_deletion.push(+t):(this.r.removeFile(this.r.getFromUniqueIdentifier(this.comment_images[e.data("iter")].uniqueIdentifier)),delete this.comment_images[e.data("iter")]),e.remove(),!1},showCloseSubscribeForm:function(e){e.preventDefault(),h(this.conf.subscribe_form_wrapper).is(":visible")?h(this.conf.subscribe_form_wrapper).hide():h(this.conf.subscribe_form_wrapper).show()},validateSubscribeForm:function(e){e.preventDefault();var t=this,e=h(e.currentTarget).find("[name=email]").val(),o=!1;if(/.+@.+\..+/i.test(e)||(h(this.conf.subscribe_comments_result_block).addClass("fail"),h(this.conf.subscribe_comments_result_block).html("<span></span>&nbsp;"+this.conf.form_subscription_error_message),h(this.conf.subscribe_comments_result_block).css("display","block"),h("#comment_subscribe_email_field").focus(),setTimeout(function(){h(t.conf.subscribe_comments_result_block).hide(),h(t.conf.subscribe_comments_result_block).removeClass("fail"),h(t.conf.subscribe_comments_result_block).html(""),h("#comment_subscribe_email_field").focus()},3e3),o=!0),o)return!1;h(this.conf.subscribe_comments_result_block).html("");o={email:e,object_id:this.conf.object_id,object_url:this.conf.object_url,object_title:this.conf.object_title,object_type:this.conf.object_type,lang_id:this.conf.lang_id};this.submitSubscribeForm(o)},submitSubscribeForm:function(e){var t=this,o=h('#comment_subscribe_form [type="submit"]');o.prop("disabled",!0),h.ajax({type:"POST",url:this.conf.subscribe_to_comments_url,data:e,dataType:"json"}).done(function(e){o.prop("disabled",!1),e.status?(h(t.conf.subscribe_comments_result_block).addClass("success"),h(t.conf.subscribe_comments_result_block).html("<span></span>&nbsp;"+t.conf.form_subscribed_message),h(t.conf.subscribe_comments_result_block).css("display","inline"),h('#comment_subscribe_form [name="email"]').val(""),setTimeout(function(){h(t.conf.subscribe_comments_result_block).hide(),h(t.conf.subscribe_comments_result_block).removeClass("success"),h(t.conf.subscribe_comments_result_block).html(""),h('#comment_subscribe_form [name="email"]').val("")},3e3)):(h(t.conf.subscribe_comments_result_block).addClass("fail"),h(t.conf.subscribe_comments_result_block).html("<span></span>&nbsp;"+e.msg),h(t.conf.subscribe_comments_result_block).css("display","inline"))})},submitCommentRestForm:function(){var e,t=new FormData,o=h("#comments_file_error");for(e in o.html(""),o.hide(),h("#input_submit_form").prop("disabled",!0),comments_actions.comment_images)t.append("file"+e,comments_actions.comment_images[e]);return t.append("desc",h("#description").val()),h.ajax({type:"POST",url:"/restaurant-questions?"+slug+"&resumableFilename=",data:t,dataType:"json",processData:!1,contentType:!1}).done(function(e){"ok"===e.status?window.location="/restaurant-questions?"+slug+"&success":(o.show(),o.html(e.error)),h("#input_submit_form").prop("disabled",!1)}),!1},autoSaveQuestionaire:function(){h("#comments_file_error").hide(),this.autosaveTimer&&clearTimeout(this.autosaveTimer),this.autosaveTimer=setTimeout(function(){h.ajax({type:"POST",url:"/restaurant-questions?"+slug,data:{draft:!0,desc:h("#description").val()},dataType:"json"})}.bind(this),2e3)},clearQuestionFields:function(){return h("#description").val(""),h(".mdl-wrap-images .upload_wrapper").remove(),this.comment_images=[],this.autoSaveQuestionaire(),!1}}))(jQuery);let eventsAndStocks={loadSwiperAjax:!1,eventSwiper:null,loadSwiperEventsData:function(t){this.loadSwiperAjax||(this.loadSwiperAjax=$.ajax({method:"GET",url:"",dataType:"html",ajaxStart:function(){}
29,success:function(e){t.update(),eventsAndStocks.updateSwiper(eventsAndStocks.eventSwiper)}}))},init:function(){if(0<$(".events-stocks").length){let i=this;i.eventSwiper=new Swiper(".js-events-and-stocks-slider",{slidesPerView:"auto",allowSlidePrev:!1,allowSlideNext:!1,spaceBetween:8,grabCursor:!0,freeMode:!1,keyboard:{enabled:!0,onlyInViewport:!0,pageUpDown:!1},navigation:{nextEl:".swiper-button-next.next",prevEl:".swiper-button-prev.prev"},on:{init:function(o){i.loadSwiperEventsData(o),o.el.addEventListener("wheel",t=>{if(1<Math.abs(t.deltaX)){t.preventDefault(),t.stopPropagation(),o.getTranslate()<o.maxTranslate()&&o.slideToClosest(200);let e=o.getTranslate()+-t.deltaX;((e=0<(e=e<o.maxTranslate()?o.maxTranslate():e)?0:e)<-30||e>o.maxTranslate()+20)&&$(".screen-slider-nav").removeClass("swiper-button-disabled_mm"),-30<e&&$(o.navigation.prevEl).addClass("swiper-button-disabled_mm"),e<o.maxTranslate()+20&&$(o.navigation.nextEl).addClass("swiper-button-disabled_mm"),o.setTranslate(e),o.updateActiveIndex()}},{passive:!1}),window.addEventListener("resize",function(){eventsAndStocks.updateSwiper(eventsAndStocks.eventSwiper),o.update()}.bind(this)),$(o.el).on("mouseenter",".swiper_btn",function(e){$(this).addClass("btn_NoHide")}),$(o.el).on("mouseleave",".swiper_btn",function(e){$(this).removeClass("btn_NoHide")})},slideChange:function(e){i.loadSwiperEventsData(e)},resize:function(e){e.updateSize()}}}),$(".js-tab-events").on("click",function(){$(".js-tab-events").removeClass("active-event-tab");var t=$(this).data("tab-type");
29$(".swiper-slide").each(function(){var e=$(this).data("slide-type");"all"===t||t===e?$(this).show():$(this).hide()}),$(this).addClass("active-event-tab"),i.eventSwiper.update()}),$(document).ready(function(){function e(){var t=i.setSlideWidth(i.eventSwiper)+"px",o=i.setSlideHeight(i.eventSwiper)+"px";for(let e=0;e<i.eventSwiper.slides.length;e++){var n=i.eventSwiper.slides[e].querySelector(".events-stocks__img-content");n.style.width=t,n.style.height=o}}"#load-events"===location.hash&&(scrollToElement(".events-stocks",300),replaceHash("")),1<i.eventSwiper.slides.length&&(setTimeout(function(){$(i.eventSwiper.navigation.prevEl).css({top:$(".events-stocks__img-content").outerHeight()/2+"px"}),$(i.eventSwiper.navigation.nextEl).css({top:$(".events-stocks__img-content").outerHeight()/2+"px"})},100),e(),$(window).on("resize orientationchange",function(){600<$(window).width()&&e(),setTimeout(function(){i.eventSwiper.update()},150)}))})}},setSlideWidth:function(o){if(o){var n=[];for(let e=0;e<o.slides.length;e++)n.push(o.slides[e].getElementsByTagName("img"));let t=n[0][0].width;for(let e=1;e<n.length;e++)n[e][0].width>t&&(t=n[e][0].width);return t}},setSlideHeight:function(o){if(o){var n=[];for(let e=0;e<o.slides.length;e++)n.push(o.slides[e].getElementsByTagName("img"));let t=n[0][0].height;for(let e=1;e<n.length;e++)n[e][0].height>t&&(t=n[e][0].height);return t}},updateSwiper:function(e){var t=e.slides.length;let o=0;e.slides.each(function(){o+=$(this).outerWidth(!0)}),1<t&&o>$(".js-events-and-stocks-slider").width()?(e.allowSlidePrev=!0,e.allowSlideNext=!0,e.$el.removeClass("locked")):o<=this.width&&(e.allowSlidePrev=!1,e.allowSlideNext=!1,e.$el.addClass("locked")),1===t&&e.$el.addClass("single-slide locked")}};$(document).ready(function(){0<$(".js-events-and-stocks-slider").length&&eventsAndStocks.init()});var FavoritePromotions={is_loading:!1,link:null,cookie_name:"favorite-promotions-elem-to-add",init:function(){var o=this;$(document).on("click",".events-stocks__like",function(e){var t;return e.preventDefault(),o.link=$(this),o.is_loading||o.link.hasClass("loading")||(o.link.addClass("loading"),t=o.link.data("promotion_id"),o.link.hasClass("add_to_favorite_promotions")?(o.link.hasClass("like")||o.link.hasClass("active")?o.remove({promotion_id:t}):o.add({promotion_id:t}),e.stopPropagation()):void 0!==o.getCookieVal()?o.unsetCookie():(setCookie(o.cookie_name,t,{expires:300,path:"/"}),getLoginForm()),o.link.removeClass("loading")),!1}),o.addFavoritePromotionFromCookie()},before_load:function(){$("<img>").prop({alt:"",src:cdn_host+"/img/site/small_loader.gif"}).addClass("adding").insertBefore(this.compare_link)},after_load:function(){this.is_loading=!1,$(".adding",this.link.parent()).remove()},add:function(e){var o=this,n=e.promotion_id;o.is_loading=!0,o.before_load(),e.csrf_token=window.json_arr.csrf_token,$.ajax({type:"POST",url:"/ajax/add_to_favorite_promotions",dataType:"json",data:e,success:function(e){var t;null!=e&&((t=$(`.add_to_favorite_promotions[data-promotion_id=${n}]`)).removeClass("unlike").addClass("like").addClass("active"),t.prop("title",_("wishlist_remove")),$(".add_to_favorite_promotions"),$(".favorite_promotions_count").text("("+e.count+")"),o.isFavoritePromotionsPage())&&$(".favorite_promotions_count_raw").text(e.count),o.after_load()},error:function(){o.after_load()}})},remove:function(e){var o=this,n=e.promotion_id;o.is_loading=!0,o.before_load(),e.csrf_token=window.json_arr.csrf_token,$.ajax({type:"POST",url:"/ajax/remove_from_favorite_promotions",dataType:"json",data:e,success:function(e){var t;null!=e&&((t=$(`.add_to_favorite_promotions[data-promotion_id=${n}]`)).removeClass("like").removeClass("active").addClass("unlike"),t.prop("title",_("wishlist_add")),t=0<e.count?"("+e.count+")":"",$(".favorite_promotions_count").text(t),o.isFavoritePromotionsPage())&&$(".favorite_promotions_count_raw").text(e.count),o.after_load()},error:function(){o.after_load()}})},isFavoritePromotionsPage:function(){return $("body").hasClass("favorite_promotions_page")},addFavoritePromotionFromCookie:function(){var e=this.getCookieVal();void 0!==e&&((e=$(`.events-stocks__like[data-promotion_id=${e}]`)).hasClass("active")||e.trigger("click"),this.unsetCookie())},unsetCookie:function(){setCookie(this.cookie_name,"",{path:"/",domain:window.location.hostname,expires:-1})},getCookieVal:function(){return getCookie(this.cookie_name)}},map=($(document).ready(function(){$(".events-stocks__like").length&&FavoritePromotions.init()}),null),width_a=0,width_b=0;let screenWidth_a=0,screenWidth_b=0;function wideRestRotation(){var e,t,o,n,i,a,r,s,l,c,d,u,m,p,h,_,f,g,v;$("body").hasClass("mobile_template")||$("body").hasClass("merged_template")||(e=$(".wrapper_main_info"),t=$("#ranks"),o=$(".similar-for-closed"),n=$(".buttons_wrapper"),i=$(".wrapper_map"),a=$(".wrapper_similar "),r=$(".right_bottom"),s=$(".title_container"),l=$("#ratings"),c=$("#types"),d=$("#link-group-mobile"),u=$(".nearme-side"),m=$(".poll_wrapper"),p=$(".info-section"),h=$(".right_top"),_=$("#rest_navigation"),f=$(".ads_block.mh100_silent"),g=$(".breadcrumbs "),v=$(".footer"),window_match_media(740,"max")?(n.addClass("mob"),(t.length?t:s).after(e),e.after(n),d.after(n),n.after(i),0<a.length?a.after(r):$(".content_wide").append(r),n.before(f),$("body").hasClass("all-promotions")||v.before(g),n.append($(".a_button_wrap.menu")),$(".left_bottom").prepend(u),$(".left_bottom").prepend(l),o.length&&(t.after(o),o.after(f)),s.after(c)):(n.removeClass("mob"),p.before(i),i.before(e),e.before(n),h.after(r),_.before(f),s.after(c),$(".left_top").after(l),$(".right_top").after(u),h.after(m),(0<$(".meals_list").length?$(".meals_list"):($(".left_top").length,$(".left_top"))).before($(".a_button_wrap.menu"))))}function isCollage(){return $("body").hasClass("body_has_collage")}function narrowRestRotation(){}function onResizeWindow(){renderBannerLeft("&type=restaurant"),null!=map&&(google.maps.event.trigger(window.map,"resize"),window.map.setCenter(window._location)),"function"==typeof setMinHeight&&setMinHeight(),popup.onResize(),window_match_media(740,"min")&&$(".order_list").removeAttr("style"),width_b=$(window).width(),20<Math.abs(width_a-width_b)&&($("body").hasClass("mobile_compact")&&narrowRestRotation(),$("body").hasClass("wide")?wideRestRotation():$(".order_wrapper"),initFade(),width_a=$(window).width())}
29function initFade(){var e=$(".description"),t=e.find("div:first");e.css("max-height",""),1.5*e.outerHeight()<t.outerHeight()||400<t.outerHeight()?(e.parent().find(".link_more").removeClass("hide"),e.parent().removeClass("short"),e.addClass("with_fade"),e.next(".link_more").find(".on_hide").removeClass("hide"),e.next(".link_more").find(".on_shown").addClass("hide")):(e.css("max-height","none"),e.parent().find(".link_more").addClass("hide"),e.parent().addClass("short"),e.removeClass("with_fade"))}function iframeDishesResizer(){var e,t=document.getElementById("recommended_dishes");null!==t&&(t.style.height="auto",e=(t.contentDocument||t.contentWindow.document).documentElement.scrollHeight,t.style.height=e+"px",200<$(t).height())&&($(t).addClass("active-show"),$(".plug-for-iframe").addClass("active-plug-hide"))}function setMinHeight(){var e,t=$(".wrapper_columns").not(".not_resize").parents(".content:first"),o=(0!==t.length&&(null!=window.json_arr.desktop?(t.css("min-height",1100),$(".footer").hide()):1010<=window.innerWidth?(o=$(".footer"),$("body").outerHeight()-t.offset().top-t.outerHeight()<o.offset().top&&t.css("min-height",t.outerHeight()+(o.offset().top-$("body").outerHeight()-10))):t.css("min-height","auto")),$(".left_column")),t=$(".info-block");0!==o.length&&0!==t.length&&(e=parseInt(t.css("top").replace("px","")),$(".wrapper_buttons").is(":visible")&&(e-=$(".wrapper_buttons").outerHeight()),t.outerHeight()+e>o.outerHeight()&&740<window.innerWidth?o.css("min-height",t.outerHeight()+e+60):window.innerWidth<=740&&o.css("min-height","auto"))}function moveScroller(){var e=$("#scroller"),t=$("#head_btns");(e.length||t.length)&&($(window).width()-t.outerWidth()<e.outerWidth()+40?e.css("bottom","100px"):$(".pierre-assist-button").length||$(".nearme_map__header").length?e.css({bottom:"60px"}):e.css("bottom","20px"))}$(window).load(function(){"function"==typeof setMinHeight&&setMinHeight(),width_a=$(window).width(),iframeDishesResizer(),screenWidth_a=$(window).width()}),$(document).ready(function(){onResizeWindow(),moveScroller(),$(window).on("resize orientationchange",function(){onResizeWindow(),moveScroller(),setTimeout(function(){screenWidth_b=$(window).width(),20<Math.abs(screenWidth_a-screenWidth_b)&&iframeDishesResizer(),screenWidth_a=$(window).width()},300)}),$(window).on("orientationchange",function(){setTimeout(function(){wideRestRotation()},300),moveScroller()}),$(window).on("scroll",moveScroller),setTimeout(moveScroller,1500),setTimeout(iframeDishesResizer,300)}),(t=>({conf:{cookie_name:"redirect_restaurants_list",redirect_delay:300},init:function(){let e=this;t(document).on("click","#ranks .type_set_5",function(){return e.setCookie(),!0}),t(document).ready(function(){e.redirect()})},setCookie:function(){setCookie(this.conf.cookie_name,1,{path:"/",samesite:"None",secure:!0})},redirect:function(){!RGPage.hasOwnProperty("redirect_restaurants_list")||!RGPage.redirect_restaurants_list||0<location.hash.length||setTimeout(function(){location.href="#restaurant-list"},this.conf.redirect_delay)}}))(jQuery).init();var comment_form_modal={config:{wrapper:"#comment_form_modal"},loaded:!1,xhr_request:null,$modal:null,init:function(){},show:function(e){e=e||{};this.load(e)},add_modal:function(e){var t;0<$(this.config.wrapper).length||(e=void 0!==e.style?e.style:"",t=$("h1").text(),e='<div class="review_overlay" id="comment_form_modal" style="'+e+'"><div class="add_review_block" style="height:130px"><div class="title"><span class="comment_title_common">'+_("write_review_restaurant_name").replace("%s",t)+'</span><span class="comment_title_photo" style="display: none;">'+_("add_photo").replace("%s",t)+'</span><span class="close_btn"></span></div><img class="stub_loader" src="'+cdn_host+'/img/site/responsive/ajax-loader.gif" class="loader" /></div></div>',$("body").append(e),this.$modal=$(this.config.wrapper))},load:function(o){if(this.loaded)this.show_modal(o);else{var n=this;let t=document.documentElement.style.getPropertyValue("--scroll-y");this.xhr_request=$.ajax({type:"GET",url:"/ajax/get_comment_form",data:{restaurant_id:$(".add_review_btn").data("rid"),cur_design:1},dataType:"html",success:function(e){n.loaded=!0,n.add_modal(o),document.documentElement.style.setProperty("--scroll-y",t+"px"),$(".add_review_block",n.$modal).html(e),$(".add_review_block .stub_loader",n.$modal).remove(),$("#comment_form").removeClass("hide"),$(".add_review_block",n.$modal).css("height",""),$(".review_overlay").on("click",function(e){$(e.target).hasClass("remove-img")||n.$modal.find(".add_review_block").is(e.target)||0!=n.$modal.find(".add_review_block").has(e.target).length||("undefined"!=typeof r_comments_actions?(r_comments_actions.cancelUploading(),r_comments_actions.hideCommentForm(!0)):(closeReviewForm(),e.preventDefault()))}),n.show_modal(o)}})}},call_callback:function(e){e.hasOwnProperty("callback")&&"function"==typeof e.callback&&e.callback.call()},show_modal:function(e){e.hasOwnProperty("only_load")&&e.only_load||(this.$modal.show(),$("body").addClass("modal-open"),bodyFixPosition(),this.$modal.find(".review_form > .error_msg").html(""),$(".form_elmnt > input,textarea",this.$modal).removeClass("error"),$(".add_review_block",this.$modal).addClass("only_photo"),$(".non_photo",this.$modal).show(),$(".comment_title_photo",this.$modal).hide(),$(".comment_title_common",this.$modal).show(),is_mobile()&&this.$modal.find(".sub_title").hide())}};function fontResize(e){document.querySelectorAll(".text-changeable").forEach(e
29=>{25<e.clientHeight&&e.classList.add("small")})}comment_form_modal.init(),void 0===window.Tooltip&&(window.Tooltip=class{constructor(e,t,o=!0,n={}){e?(this.specClass=n.specClass??"",this.sideMargin=n.sideMargin??0,this.baseTooltipMarkup=`
30                    <div class="tooltip ${this.specClass}">
31                        <div class="tooltip-arrow"></div>
32                        <div class="tooltip-content"></div>
33                    </div>
34                `,this.content=e,this.targetElement=$(t),this.isMobile="function"==typeof is_mobile?is_mobile():/iPhone|iPad|iPod|Android/i.test(navigator.userAgent)||"ontouchstart"in window||0<navigator.maxTouchPoints,0===this.targetElement.length?console.warn('Target element "'+t+'" not found in the DOM.'):(this.alignElement=n.alignElement&&$(n.alignElement).length?$(n.alignElement):this.targetElement,this.alignX=n.alignX||"center",this.tooltip=null,this.blockMobileEvents=o,this.disabled=this.isMobile&&this.blockMobileEvents,this.bindEvents())):console.warn("Tooltip content is empty.")}bindEvents(){this.disabled||(this.isMobile&&!this.blockMobileEvents?(this.targetElement.on("touchstart",e=>this.showTooltip(e)),this.targetElement.on("touchend",()=>this.hideTooltip()),$(window).on("touchstart",e=>{!this.tooltip||$(e.target).closest(this.tooltip).length||$(e.target).is(this.targetElement)||this.hideTooltip()})):(this.targetElement.on("mouseenter",e=>this.showTooltip(e)),this.targetElement.on("mouseleave",()=>this.hideTooltip())),$(window).on("resize",()=>this.hideTooltip()))}showTooltip(e){e.preventDefault(),e.stopPropagation(),this.tooltip=$(this.baseTooltipMarkup),this.tooltip.find(".tooltip-content").html(this.content),$("body").append(this.tooltip);var e=this.targetElement.offset(),t=this.targetElement.outerWidth(),o=this.targetElement.outerHeight(),n=this.alignElement.offset(),i=this.alignElement.outerWidth(),a=this.tooltip.outerWidth(),r=this.tooltip.outerHeight(),s=$(window).width(),l=$(window).height();let c=e.top+o+10,d;o=this.tooltip.find(".tooltip-arrow"),n.left,t=e.left+t/2;c+r>$(window).scrollTop()+l?0<e.top-r-10&&(c=e.top-r-10,o.removeClass("tooltip-arrow-bottom").addClass("tooltip-arrow-top"),o.css({top:"auto",transform:"translateX(-50%) rotate(180deg)"})):(o.removeClass("tooltip-arrow-top").addClass("tooltip-arrow-bottom"),o.css({bottom:"100%",transform:"translateX(-50%)"})),(d="left"===this.alignX?n.left:"right"===this.alignX?n.left+i-a:n.left+i/2-a/2)<0?d=this.sideMargin:d+a>s&&(d=s-a-this.sideMargin);let u=t-d-10;u<10?(u=10,console.log("1: "+u)):u+10>a-10&&(u=a-20,console.log("2: "+u)),o.css({left:u+10+"px"}),this.tooltip.css({top:c+"px",left:d+"px",display:"flex"})}hideTooltip(){this.tooltip&&this.tooltip.fadeOut(0,()=>{null!==this.tooltip&&(this.tooltip.remove(),this.tooltip=null)})}}),document.fonts.ready.then(()=>{setTimeout(fontResize,1e3)}),((i,s)=>{var e,a,n,o,r,l,c,d,u,m,p,h,_,f;function t(e){e=e||{},a=String(e.measurementId||"").trim(),n=String(e.openPanelClientId||"").trim(),o=String(e.openPanelApiUrl||"").trim(),r=!0===e.debug||"true"===e.debug,l=/^G-[A-Z0-9]+$/.test(a),null!=e.restaurantId&&(f.restaurant_id=String(e.restaurantId)),e.locale&&(f.locale=String(e.locale))}function g(e,t){c[e]||(c[e]=!0,i.console&&i.console.warn("[Restaurant analytics] "+t))}function v(e){return String(e||"").toLowerCase().replace(/[^a-z0-9_-]+/g,"_").replace(/^_+|_+$/g,"").slice(0,80)}function w(o){var n={};return Object.keys(o||{}).forEach(function(e){var t=o[e];null!=t&&""!==t&&(n[e]=t)}),n}function b(){var e,t;!u&&n&&o&&(u=!0,(e=function(){e.q.push(Array.prototype.slice.call(arguments))}).q=[],(i.op=e)("init",{clientId:n,apiUrl:o,trackScreenViews:!1,trackOutgoingLinks:!1,trackAttributes:!1,sessionReplay:{enabled:!1},filter:function(e){var t;return!("track"!==e.type||!e.payload||"screen_view"!==(e=e.payload).name&&"session_end"!==e.name&&-1===p.indexOf(e.name)||((t=e.properties||{}).__path=i.location.origin+i.location.pathname,["__path","__referrer","__previousPath"].forEach(function(e){t[e]&&(t[e]=(e=>{try{var t=new i.URL(e,i.location.href);return t.origin+t.pathname}catch(e){return""}})(t[e]))}),e.properties=t,0))}}),e("setGlobalProperties",w(f)),(t=s.createElement("script")).src="https://openpanel.dev/op1.js",t.async=!0,t.onerror=function(){e.q.length=0,i.op=function(){},g("openpanel-sdk","OpenPanel SDK could not be loaded.")},s.head.appendChild(t))}function y(e,t){if(n){b();try{m=Math.max(Date.now(),m+1);var o=w(t);o.__timestamp=new Date(m).toISOString(),i.op("track",e,o)}catch(e){g("openpanel","OpenPanel could not track an event; GA4 tracking continues.")}}}function $(e,t){var o,n;-1!==p.indexOf(e)&&(o=t,n=w(f),h.forEach(function(e){o&&null!=o[e]&&""!==o[e]&&(n[e]=o[e])}),y(e,t=n),l&&"function"==typeof i.gtag?(t.send_to=a,t.transport_type="beacon",r&&(t.debug_mode=!0),i.gtag("event",e,t)):g("gtag","GA4 is unavailable or the measurement ID is invali
34d."))}function k(e,t){var o=(o=_[e])||(/^contentGroup\d+$/.test(e)?"ua_content_group_"+e.replace(/\D/g,""):/^dimension\d+$/.test(e)?"ua_dimension_"+e.replace(/\D/g,""):v(e));o&&null!=t&&""!==t&&(f[o]=t,u)&&"function"==typeof i.op&&((e={})[o]=t,i.op("setGlobalProperties",e))}function x(e){return e.closest('a[href], button, input:not([type="hidden"]), select, textarea, summary, [role="button"], [onclick], [tabindex]:not([tabindex="-1"]), .link_more, .see_all, .add_review_action, .add_photo_action, .orderBtn, .order_item, .book, .group-link')}function C(e){var t,o=x(e);if(!o)return null;var n=e.closest("[data-restaurant-related-block]"),i=n&&n.getAttribute("data-restaurant-related-block");if(n&&-1!==["similar_restaurants","popular_collections","tasty_dishes","restaurant_features","food_guides","branches"].indexOf(i))t=n,r=i;else if(t=e.closest(".similar-for-closed, .sidebar-establishments__container.nearby"))r="similar_restaurants";else if(t=e.closest(".sidebar-establishments__container.article_block, .article_block"))r="food_guides";else if(t=e.closest(".sidebar-establishments__container.set-cuisine, .right_bottom > .set, .sidebar-establishments__container.set"))r="popular_collections";else if(e.closest(".group-link, #link-group-mobile, .sidebar-address__info-link"))t=e.closest(".restaurant-page__header, .sidebar-address, .short_info")||s,r="branches";else{if(!(t=e.closest(".wrapper_similar .tags_block")))return null;var a=t.parentElement,r=0===Array.prototype.filter.call(a.querySelectorAll(".tags_block"),function(e){return e.parentElement===a}).indexOf(t)?"tasty_dishes":"restaurant_features"}return{block_id:r,click_type:o.matches(".show_all, .all_results")?"see_all":"item",item_position:(n=o,i='a[href], button, [role="button"], .group-link',e=((e=t)||s).querySelectorAll(i),Array.prototype.indexOf.call(e,n)+1||null)}}function T(e){var t=C(e);return t?{name:"restaurant_related_click",params:t}:e.closest(".add_review_action")?{name:"restaurant_add_review_click"}:e.closest(".total_photo, .all_photos")?{name:"restaurant_gallery_click"}:e.closest(".add_photo_action, .add_photo_link")?{name:"restaurant_add_photo_click"}:e.closest('.direction_link, a[href*="google.com/maps/dir"]')?{name:"restaurant_directions_click"}:e.closest('a[href^="tel:"], .call, .header_call')?{name:"restaurant_phone_click"}:e.closest(".orderBtn, .order_item, .order_wrapper a")?{name:"restaurant_order_click"}:e.closest('.book, [name="book_table"], .reservation')?{name:"restaurant_booking_click"}:e.closest(".menuBtn, .action-menu__btn")?{name:"restaurant_menu_click"}:e.closest(".website a, .website_block a")?{name:"restaurant_website_click"}:e.closest(".claim_business")?{name:"restaurant_claim_click"}:e.closest("#report_inaccuracy__btn, .report_inaccuracy .report")?{name:"restaurant_report_click",params:{report_type:"incorrect_information"}}:e.closest('.report[data-object_type="review"], a[href*="request_content_removal"]')?{name:"restaurant_report_click",params:{report_type:"content_removal"}}:e.closest(".more_ranks_show, .more_ranks_load")?{name:"restaurant_rating_expand_click"}:e.closest(".schedule_short_info, .work_time > .div_h3")?{name:"restaurant_opening_hours_expand_click"}:e.closest(".instagram a, .sidebar-details__instagram a, a.insta_btn, a.sidebar-details__inst-link")?{name:"restaurant_instagram_click"}:e.closest("#ranks a.number, a.rank_tag, a.restaurant-rank")?{name:"restaurant_rating_click",params:{rating_source:"restaurant_guru_rank"}}:(t=e.closest(".rating_list_right, .wrapper_ratings a.row, .main-restaurant__ratings a"))?{name:"restaurant_rating_click",params:{rating_source:(e=>{for(var t=["tripadvisor","trip","foursquare","google","facebook","zomato","yandex","opentable"],o=String(e.className||"").toLowerCase(),n=0;n<t.length;n++)if(-1!==o.indexOf(t[n]))return t[n];return"other"})(t)}}:e.closest(".photo-link, .screen-slider, .gallery__tabs-page")?{name:"restaurant_gallery_click"}:e.closest('.map_block, [id^="map_block"], .wrapper_map, #info_location, .info_address')?{name:"restaurant_map_click"}:e.closest(".restaurant__description, .description_section, .wrapper_description")?x(e)?{name:"restaurant_description_click"}:null:e.closest(".restaurant-page__reviews, #comments_container, .wrapper_reviews, .search_reviews__wrap")&&x(e)?{name:"restaurant_review_click"}:null}i.RGRestaurantAnalytics||(e=i.ga&&i.ga.q?Array.prototype.slice.call(i.ga.q):[],o=n=a="",l=r=!1,u=d=!(c={}),m=0,p=["restaurant_menu_click","restaurant_phone_click","restaurant_directions_click","restaurant_map_click","restaurant_website_click","restaurant_booking_click","restaurant_order_click","restaurant_add_review_click","restaurant_add_photo_click","restaurant_claim_click","restaurant_report_click","restaurant_gallery_click","restaurant_rating_click","restaurant_rating_expand_click","restaurant_review_click","restaurant_description_click","restaurant_opening_hours_expand_click","restaurant_instagram_click","restaurant_related_click","legacy_ui_event"],h=["report_type","rating_source","block_id","click_type","item_position","event_category","event_action","event_label","event_value"],_={contentGroup1:"city_group",contentGroup2:"neuro_text_group",contentGroup3:"country_group",contentGroup4:"content_group",contentGroup5:"chatgpt_menu_group",contentGroup6:"mobile_template_group",dimension1:"emoji_group",dimension2:"ar_photos_group",dimension
345:"cache_status",dimension6:"menu_images_group",dimension8:"lists_page_group",dimension9:"restaurant_design_group"},f={page_type:"restaurant",locale:(s.documentElement.lang||"").trim()},t(i.RGRestaurantAnalyticsConfig),i.ga=function(){var e,t,o=Array.prototype.slice.call(arguments);"create"!==o[0]&&("set"===o[0]?"object"==typeof o[1]&&o[1]?Object.keys(o[1]).forEach(function(e){k(e,o[1][e])}):k(o[1],o[2]):"send"===o[0]&&("pageview"===o[1]||o[1]&&"pageview"===o[1].hitType)?(e="object"==typeof o[1]?o[1].page:o[2],d||(d=!0,t=w(f),e&&"string"==typeof e&&(t.page_path=e),y("screen_view",t),l&&"function"==typeof i.gtag?((e=w(f)).send_page_view=!1,e.transport_type="beacon",r&&(e.debug_mode=!0),i.gtag("config",a,e),t.send_to=a,t.transport_type="beacon",r&&(t.debug_mode=!0),i.gtag("event","page_view",t)):g("gtag","GA4 is unavailable or the measurement ID is invalid."))):"send"===o[0]&&("event"===o[1]||o[1]&&"event"===o[1].hitType)?$("legacy_ui_event",(t="object"==typeof(e=o)[1]&&e[1]?e[1]:"object"==typeof e[2]&&e[2]?e[2]:null)?{event_category:t.eventCategory,event_action:t.eventAction,event_label:t.eventLabel,event_value:t.eventValue}:{event_category:e[2],event_action:e[3],event_label:e[4],event_value:e[5]}):g("legacy-"+v(o[0]+"-"+o[1]),"An unsupported legacy ga call was ignored."))},s.addEventListener("click",function(e){try{var t,o=e.target;!(o=o&&1!==o.nodeType?o.parentElement:o)||"function"!=typeof o.closest||o.closest("[data-ad], .adsbygoogle, iframe")||(t=T(o))&&$(t.name,t.params)}catch(e){g("click","Could not classify a click: "+e.message)}},!0),i.RGRestaurantAnalytics={version:"1.0.0",configure:t,send:$,context:f,classify:T},e.forEach(function(e){i.ga.apply(i,e)}))})(window,document);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.