function setSortLive(t,e,a){sortLoadEvent!=e&&($(".action-view-live a").removeClass("active"),$(a).addClass("active"),sortLoadEvent=e,$.get("/news/load-content-live.html?id="+t+"&timeLine=&sort="+e,function(t){$("#load-live-event").html(t)}))}function loadFootballData(t){$("#content-data-football").html('

'),$.get("/files/load-data-football.html?id="+t,function(t){$("#content-data-football").html(t),loadCustomSelect()})}function loadFootballDataSeason(t,e){$("#content-data-football").html('

'),$.get("/files/load-data-football.html?id="+t+"&season="+e,function(t){$("#content-data-football").html(t),loadCustomSelect()})}function loadFootballDataDate(t,e){$("#content-data-football").html('

'),$.get("/files/load-data-football.html?id="+t+"&date="+e,function(t){$("#content-data-football").html(t),loadCustomSelect()})}function loadFootballDataRound(t,e){$("#content-data-football").html('

'),$.get("/files/load-data-football.html?id="+t+"&round="+e,function(t){$("#content-data-football").html(t),loadCustomSelect()})}function loadCustomSelect(){$(".select-league").length&&$(".select-league").click(function(){$(this).toggleClass("active"),$(this).next(".cate-bars .menu-cate-bar").toggle()})}function countdownTime(t){let e=setInterval(function(){let a=t-(new Date).getTime();$(".countdown-day").text(Math.floor(a/864e5)),$(".countdown-hours").text(Math.floor(a%864e5/36e5).toString().padStart(2,"0")),$(".countdown-minute").text(Math.floor(a%36e5/6e4).toString().padStart(2,"0")),$(".countdown-second").text(Math.floor(a%6e4/1e3).toString().padStart(2,"0")),a<0&&clearInterval(e)},1e3)}function loadWidgetCalendar(t){$.get(t,function(t){$("#box-calendar-fb-widget").html(t)})}$(document).ready(function(){$(".btn-menu").on("click",function(){$(".menu").toggleClass("menu-active"),$(this).toggleClass("btn-menu-active"),$(".btn-lastest-news").removeClass("active"),$("#tin-moi-thethao").hide(),$(".menu").hasClass("menu-active")?($("#admicro-top").addClass("menu-active"),$("header").addClass("fixed")):($("#admicro-top").removeClass("menu-active"),$("header").removeClass("fixed"))}),$(".btn-lastest-news").on("click",function(){$(this).toggleClass("active"),$("#tin-moi-thethao").toggle(),$(".menu").removeClass("menu-active"),$(".btn-menu").removeClass("btn-menu-active"),$(".btn-lastest-news").hasClass("active")?($("#admicro-top").addClass("menu-active"),$("header").addClass("fixed")):($("#admicro-top").removeClass("menu-active"),$("header").removeClass("fixed"))}),$("iframe.auto-wh").length&&$("iframe.auto-wh").each(function(){var t=$(this).width(),e=$(this).attr("width"),a=$(this).attr("height");isNaN(e)||isNaN(a)||$(this).height(t*(a/e))}),$(".scroll.auto-height").length&&$(".scroll.auto-height").each(function(){var t=$(this).parent().height();$(this).next().length&&(t-=$(this).next().height()),$(this).prev().length&&(t-=$(this).prev().height()),isNaN(t)||$(this).height(t)}),$(".slide-stoires.run-slide").length&&$(".slide-stoires.run-slide").slick({dots:!0,speed:500,swipe:!0,centerMode:!1,variableWidth:!0,swipeToSlide:!0,arrows:!1}),loadCustomSelect(),$(".icon-menu-bar").length&&$(".icon-menu-bar").click(function(){$(this).toggleClass("active"),$(this).next(".cate-bars .menu-cate-bar").toggle()}),$(window).scroll(function(){$(this).scrollTop()>300?($("#sub-menu-bottom").show().fadeIn(),$("#back-to-top").show().fadeIn(),$("#banner-mobile-first").css({bottom:"36px"})):($("#sub-menu-bottom").fadeOut().hide(),$("#back-to-top").fadeOut().hide(),$("#banner-mobile-first").css({bottom:"-5px"}))})});var sortLoadEvent="desc",intervalLoad=null;$(window).resize(function(){$("iframe.auto-wh").length&&$("iframe.auto-wh").each(function(){var t=$(this).width(),e=$(this).attr("width"),a=$(this).attr("height");isNaN(e)||isNaN(a)||$(this).height(t*(a/e))})});var Liverscore={setLivescore:function(){this.setLivescoreByTime(),this.runLivescore()},setLivescoreByTime:function(){var t=this;setInterval(function(){t.runLivescore()},3e4)},runLivescore:function(){var t=this;$.get("/files/tiktok.txt",function(e){if(e){for(var a=e.length,o=0;o0)if($("#home-name-"+e[0]+" .red-card-show").length)$("#home-name-"+e[0]+" .red-card-show").text(e[6]);else{var o=$("#home-name-"+e[0]).text();this.changeOneScoreCell("#home-name-"+e[0],''+e[6]+""+o)}if(e[7]>0)if($("#away-name-"+e[0]+" .red-card-show").length)$("#away-name-"+e[0]+" .red-card-show").text(e[7]);else{var n=$("#away-name-"+e[0]).text();this.changeOneScoreCell("#away-name-"+e[0],n+''+e[7]+"")}this.changeOneScoreCell("span#"+a+"-home-goal",e[2]),this.changeOneScoreCell("span#"+a+"-away-goal",e[3]);var i=e[4]&&0!==e[4].length?e[4]:e[2],l=e[5]&&0!==e[5].length?e[5]:e[3];this.changeOneScoreCell("span#"+a+"-ht-home-goal",i),this.changeOneScoreCell("span#"+a+"-ht-away-goal",l)}},changeOneScoreCell:function(t,e){var a=$(t).html();$(t).html(e),a!=e&&$(t).addClass("match-score-change")}};