"use strict";var _slicedToArray=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var a=[],n=!0,i=!1,o=void 0;try{for(var r,s=e[Symbol.iterator]();!(n=(r=s.next()).done)&&(a.push(r.value),!t||a.length!==t);n=!0);}catch(e){i=!0,o=e}finally{try{!n&&s.return&&s.return()}finally{if(i)throw o}}return a}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")};function t(e){1\n .zopim {\n display: none !important;\n }\n \n ");else{if(~location.href.indexOf("account"))return void(location.href="/static/login");$("header .auth").addClass("visible")}}),a&&$("a").each(function(e,t){var a=$(t).attr("href");if(a && a !== "/") { if(a.startsWith("http")) { $(t).attr("href", a); } else { a = a.startsWith("/") ? a : "/" + a; $(t).attr("href", a); } }}),$(".popup .close").on("click",function(e){$(this).parents(".overlay:eq(0)").removeClass("visible")}),$("header .menu-icon").on("click",function(){$("nav#sidebar").addClass("visible"),$("body").addClass("block-scroll")}),$("nav#sidebar").on("click",function(){$(this).removeClass("visible"),$("body").removeClass("block-scroll")}),$("#sidebar .more").on("click",function(e){e.stopPropagation(),$(this).next("ul").slideToggle()}),$(".go-back.ch").on("click",function(){window.history.go(-1)}),{GetParameterByName:function(e,t){t||(t=location.href),e=e.replace(/[\[\]]/g,"\\$&");var a=new RegExp("[?&]"+e+"(=([^&#]*)|&|#|$)").exec(t);return a?a[2]?decodeURIComponent(a[2].replace(/\+/g," ")):"":null},GetCommaStr:function(e){var t=e<0,a=Math.pow(10,2);e=(e=Math.floor(e*a)/a).toFixed(2),t&&(e=e.slice(1));for(var n=e.split("."),i=_slicedToArray(n,2),o=i[0],r=i[1],s=o.length-3;0\n
\n
\n \n
\n
\n \n \n \n \n
\n
\n \n \n \n \n
\n
\n \n
\n
\n
\n
\n
\n ');$(".last-played-games").replaceWith(e),$(".last-games",e).on("click",function(e){location.pathname.includes("/casino/casino")&&(e.preventDefault(),$('.slot-categories [category="LAST_PLAYED_GAMES"]').click())})},n=function(e){if(!Array.isArray(e)||!e.length)return $(".last-played-games .swiper-wrapper").html('\n
\n '),$(".last-played-games").slideDown(),void Main.SetTexts($(".last-played-games"));var t=e.filter(function(e){return e}).map(i).join("");$(".last-played-games .swiper-wrapper").html(t),$(".last-played-games").slideDown(),Main.SetTexts($(".last-played-games")),r()},i=function(e){var t=e.GameId,a=(e.LaunchTimestamp,o.find(function(e){return e.ID===t}));if(a){var n=a.name,i=a.imageUrl;return'\n
\n \n '+n+'\n \n
'}},r=function(){new Swiper(".last-played-games .swiper-container",{slidesPerView:"auto",spaceBetween:12,loop:!0,lazy:!0,autoplay:{delay:3e3,disableOnInteraction:!1},navigation:{nextEl:".arrow-right",prevEl:".arrow-left"}})};!function t(){CasinoGame.GetAll("slot",function(e){ContentManager.directory?(o=e.games||[],CasinoGame.GetLastPlayedGames(function(e){a(),n(e),EventEmitter.emit("setLastPlayedGames",e)})):EventEmitter.on("setDirectory",function(){return t()})},!0)}()}!function(){var i=$(".email-verification");function a(){$("header select[name=lang]").empty(),ContentManager.directory.languages.forEach(function(e){if(25!=e.ID){var a="LANGUAGE__"+e.LangCodeShort.toUpperCase();$("header select[name=lang]").append("\n \n ")}}),$("header select[name=lang]").val(Lang.currentLang)}var e,o,n,r=new Validator([Validator.Rules.MATCH,Validator.Rules.REQUIRED]);function s(){var e=$("input[name=confPass]",i),a=$("input[name=newPass]",i).val(),n=e.val();r.Validate(a,!0,n),r.isInvalid?e[0].setCustomValidity(t("PASSWORDS_DO_NOT_MATCH",!0)):e[0].setCustomValidity("")}(e=Main.GetParameterByName("gameId")||Main.GetParameterByName("gameid"))&&!location.pathname.includes("gamepage")&&Game.Launch(e,{redirect:!0}),EventEmitter.on("setLanguage",function(e){EventEmitter.on("setDirectory",a,!0)},!0),n="",(o=[{className:"uppercase-char",text:"SIGNUP__AT_LEAST_ONE_UPPERCASE_CHARACTER",pattern:/^(?=.*[A-Z]).+$/},{className:"lowercase-char",text:"SIGNUP__AT_LEAST_ONE_LOWERCASE_CHARACTER",pattern:/^(?=.*[a-z]).+$/},{className:"number-char",text:"SIGNUP__AT_LEAST_ONE_NUMBER",pattern:/.*\d+.*/},{className:"8-char",text:"SIGNUP__AT_LEAST_8_CHARACTERS",pattern:/^.{7,}$/}]).forEach(function(e){n+='

'}),$(".password-validation-list").html(n),$('form input[type="password"]:not([name="confPass"]):not([name="ConfirmPassword"])').each(function(e,t){$(t).on("input",function(e){var a,n,t=$(this).closest("form");a=$(this).val(),n=t,$(".password-validation-list",n).show(),o.forEach(function(e){var t=$("."+e.className,n);e.pattern.test(a)?t.addClass("valid"):t.removeClass("valid")})})}),$("select[name=lang]").on("change",function(){localStorage.clear();var e="/"+$(this).val(),t=location.pathname.replace(/\/[a-z]{2}/,e);t+=location.search+location.hash,location.href=t}),User.emitter.on("setWallets",function(){var e=GState.currentUser;$(".balance span:last-child","header, .user-info").text(Math.floor(e.defaultWallet.BalanceDecimal)+" ₺")},!0),User.emitter.on("setInfo",function(e){$("span.username").text(e.username)},!0),$("input[name=newPass]",i).on("input",function(){r.isDirty&&s()}),$("input[name=confPass]",i).on("focusout",s),$("input",i).on("input",function(){var e=Array.from($('input[type="password"]',i)).every(function(e){return!!e.value}),t=$("input[name=newPass]",i).val()==$("input[name=confPass]",i).val()&&6==$('input[name="verification_code"]',i).val().trim().length;$("form button",i).prop("disabled",!e||!t)}),$("header .user-info").on("click",function(e){e.stopPropagation(),$("header .user-info .user-icon").toggleClass("expanded"),$(".profile-popup").toggleClass("visible")}),$("header .notifications").on("click",function(e){e.stopPropagation()}),$(".profile-popup .popup").on("click",function(e){e.stopPropagation()}),$(document).on("click",function(){$("header .user-info .user-icon").removeClass("expanded"),$(".profile-popup").removeClass("visible")}),$(".refresh-balance").on("click",function(){var e=this;$(this).addClass("rotate"),setTimeout(function(){$(e).removeClass("rotate")},500),User.SetWallets()}),$(".sign-out").on("click",function(e){Auth.LogOut(function(){location.href="/"})})}(),EventEmitter.on("setLanguage",function(){ContentManager.GetBanners("GAME_PROVIDERS",function(e){e.forEach(function(e){$("footer .providers .swiper-wrapper").append('
\n \n
')}),new Swiper("footer .providers",{slidesPerView:3,spaceBetween:60,autoplay:{delay:3e3,disableOnInteraction:!1},loop:!0})}),ContentManager.GetBanners("PAYMENT_PROVIDERS",function(e){e.forEach(function(e){$("footer .payments .swiper-wrapper").append('
\n \n
')}),new Swiper("footer .payments",{slidesPerView:3,spaceBetween:60,autoplay:{delay:3e3,disableOnInteraction:!1},loop:!0})})},!0),EventEmitter.on("setLanguage",function(){ContentManager.GetSiteText("FOOTER_TEXT",function(e){$("footer .f-terms p").html(e)}),ContentManager.GetBanners("HIDE_CONTENT_FOOTER",function(e){e.forEach(function(e){$("footer .icons ul").append('\n
  • \n \n
  • \n ')})}),ContentManager.GetSiteText("NEXT_LINK",function(e){$("marquee").html(e)})},!0),$("nav#sidebar .livechat a").on("click",function(e){e.preventDefault(),$zopim.livechat.window.show()}),function(){var n=30,i=n,r=[];EventEmitter.on("setDirectory",function(t){EventEmitter.on("setLanguage",function(e){var a=t.languagesObj[e];User.emitter.on("setInfo",function(){var e,t;e=a,new XHR({url:GState.SERVER_ADDRESS+"/api/InfoMessage/GetUserInfoMessage",data:{languageId:e},onSuccess:function(e){var o;e=(r=e).sort(function(e,t){var a=new Date(e.sendDate),n=new Date(t.sendDate);return n-a}),EventEmitter.emit("setUserMesssage",e),o="",r.slice(i-n,i).forEach(function(e){var t=e.id,a=e.header,n=(e.body,e.isRead),i=e.sendDate;o+='\n
  • \n
    "+a+"
    \n "+DateHandler.GetDateStr(i,"dd-MM-yyyy HH:mm")+"\n
  • \n "}),$(".notification-data ul").append(o)}}),t=a,new XHR({url:GState.SERVER_ADDRESS+"/api/InfoMessage/GetUserInfoMessageCount",data:{languageId:t,isRead:!1},onSuccess:function(e){e&&$(".tot-notifications").addClass("visible").text(e),EventEmitter.emit("setUserMesssageCount",e)}})},!0)},!0)},!0)}(),ContentManager.SetSiteContent(function(e){var t,a;t=e.texts,document.title=t.TITLE,$("meta[name=description]").attr("content",t.DESCRIPTION),$("meta[name=keywords]").attr("content",t.KEYWORDS),t.GOOGLE_ANALYTICS&&$("body").append(t.GOOGLE_ANALYTICS),t.LIVE_CHAT&&$("body").append(t.LIVE_CHAT),t.SCRIPT1&&$("body").append(t.SCRIPT1),t.SCRIPT2&&$("body").append(t.SCRIPT2),$("footer p.copyright").text(t.COPYRIGHT),User.emitter.on("setInfo",function(e){$zopim.livechat.setName(e.username),$zopim.livechat.setEmail(e.email)},!0),a=e.imgs,console.log(a),a.FAVICON&&$('link[rel="shortcut icon"]').attr("href",a.FAVICON.imageURL),a.LOGO_FOR_MOBILE&&$(".logo img").attr("src",a.LOGO_FOR_MOBILE.imageURL),a.CONTENT_SOCIAL.forEach(function(e){$("ul.socials").append("\n
  • \n \n "+e.imageURL+"\n \n
  • \n ")})}),function(){var e=Main.GetParameterByName("mediaid");e&&LcStorage.SetItem("mediaid",e)}(),function(){var a,n;$(".change-theme, .current-theme").on("click",function(e){e.stopPropagation()}),$(".change-theme ul li").on("click",function(){$("html").attr("class",""),1==(n=$(this).attr("value"))?a="default":2==n?a="galatasaray":3==n?a="trabzonspor":4==n?a="besiktas":5==n&&(a="fenerbahce"),$(".change-theme ul.visible").removeClass("visible"),$(".change-theme ul li").removeClass("active"),$(this).addClass("active"),$(this).hide().siblings().show();var e=$("span",this).text(),t=$(".icon img",this).attr("src");$(".current-theme p").text(e),$(".current-theme .icon img").attr("src",t),$("html").addClass(a),localStorage.setItem("theme",n),EventEmitter.emit("changeTheme",a)});var e=localStorage.getItem("theme");$(".change-theme ul li[value="+(e||1)+"]").trigger("click"),$(document).on("click",function(){$(".change-theme ul.visible").removeClass("visible")}),$(".current-theme").on("click",function(e){e.stopPropagation(),$(this).next("ul").toggleClass("visible")})}(),function(){var l,c,u=$(".email-verification"),o=!0;function n(){var n=60,i=setInterval(function(){n--;var e=Math.floor(n/60),a=n%60;a=a<10?"0"+a:a,$(".timer",u).text(t("EMAIL_VERIFICATION__CODE_SENT")+" ("+e+":"+a+")"),o=!0,$(".resend",u).addClass("disabled"),n<=0&&(clearInterval(i),o=!1,$(".resend",u).removeClass("disabled"),$(".timer",u).html(''+t("EMAIL_VERIFICATION__RESEND_CODE")+""))},1e3)}l="",c={},EventEmitter.on("show-email-verification",function(e){window.scrollTo({top:0}),l=JSON.parse(e.requestHolder.response).response.Email,c=JSON.parse(e.data),(localStorage.getItem("registrationSuccess")||localStorage.getItem("TwoFactor"))&&($(".pass",u).remove(),localStorage.removeItem("registrationSuccess")),$("main").hide(),u.addClass("visible"),n(),$(".verification-email",u).text(l)},!0),$('input[name="verification_code"]',u).on("input",function(){if(localStorage.getItem("registrationSuccess")&&localStorage.getItem("TwoFactor")){var e=6===$(this).val().trim().length;$("button",u).prop("disabled",!e)}}),$("form",u).on("submit",function(e){e.preventDefault();var a=$('input[name="verification_code"]',u).val().trim(),n=$('input[name="newPass"]',u).val()||null;$(".loader-wrapper",u).attr("style","").addClass("visible"),$("button",u).hide();var i,o,r={Code:a,Email:l,newPassword:n,LoginModel:{UserName:c.UserName,Password:c.Password}};function s(e){if(1===e)localStorage.removeItem("TwoFactor"),localStorage.setItem("FirstLogin",!0),location.href="/";else{$("button",u).show(),$(".loader-wrapper",u).removeClass("visible");var a=ContentManager.directory.statusCodesObj[e];$(".main-err",u).text(t(a)),-373===e&&($("button",u).prop("disabled",!0),$("input",u).val(""),setTimeout(function(){$(".main-err",u).text(""),$("button",u).prop("disabled",!1)},3e4))}}localStorage.getItem("TwoFactor")?(i=r,o=function(e){s(e.status)},new XHR({type:"post",data:JSON.stringify(i),url:GState.SERVER_ADDRESS+"/api/profile/AuthAccountByCode",onSuccess:function(e){o&&o(e)},onFail:function(){o&&o({status:-1})}})):User.ActivateAccountByCode(r,function(e){s(e.status)})}),$(u).on("click",".resend",function(){var e,a;o||($(".resend",u).addClass("disabled"),localStorage.getItem("TwoFactor")?(e={email:l},a=function(e){if(n(),1!=e.status){var a=ContentManager.directory.statusCodesObj[e.status];$(".main-err",u).text(t(a))}},new XHR({url:GState.SERVER_ADDRESS+"/api/profile/ResendVerificationCodeTwoFactor?email="+e.email,onSuccess:function(e){a&&a(e)}})):User.ResendVerificationCode({email:l},function(e){if(n(),1!=e.status){var a=ContentManager.directory.statusCodesObj[e.status];$(".main-err",u).text(t(a))}}))})}(),function(){var e=Main.GetParameterByName("TwoFactor");e&&(history.replaceState({},"",location.pathname),EventEmitter.emit("show-2fa-text",e)),EventEmitter.on("setDirectory",function(n){EventEmitter.on("show-2fa-text",function(e){var a=n.statusCodesObj[e];-507!==e&&(a=1==e?"RESPONSE__TFA_VALID":"RESPONSE__TFA_INVALID",$(".show-2fa-text").addClass("visible"),$(".show-2fa-text .text").attr("text_key",a).text(t(a))),localStorage.setItem("TwoFactor",1)},!0)},!0)}(),XHR.emitter.on("responsibleGamingError",function(e,t){EventEmitter.on("setDirectory",function(){EventEmitter.on("setTranslations",function(){if(-507===e)return EventEmitter.emit("show-2fa-text",e),void EventEmitter.emit("show-email-verification",t);-360===e&&EventEmitter.emit("show-email-verification",t)},!0)},!0)},!0),Auth.emitter.on("checkAuthorization",function(e){e&&setGetLastPlayedGames()},!0);