"use strict";function Marquee(){var t=document.getElementsByClassName("vertical-list")[0];t=t||document.getElementsByClassName("comments-list")[0];var e=document.getElementsByClassName("formarea1")[0];document.getElementsByClassName("formarea2")[0].offsetTop-t.scrollTop<=0?t.scrollTop-=e.offsetHeight:t.scrollTop++}function crollfun(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:35,e=setInterval(Marquee,t),o=!0;$(".vertical-list, .comments-list").on("click",function(){o?clearInterval(e):e=setInterval(Marquee,t),o=!o})}$(function(){var e=$(".detail-tab"),t=$(window),o=$(document);if(t.on("scroll",function(){var t=[{id:"#goods-intro",height:$("#goods-intro").offset().top},{id:"#goods-spec",height:$("#goods-spec").offset().top}];t.sort(function(t,e){return t.height-e.height}),o.scrollTop()>=$(".detail-tab-t").offset().top+20?e.addClass("fixed container"):e.removeClass("fixed container"),$(".detail-tab-item span").removeClass("active"),o.scrollTop()<t[1].height-100&&$(".detail-tab-item span[data-href='"+t[0].id+"']").addClass("active")}),$(".detail-tab-item span").click(function(){var t=$(this).attr("data-href");$(".detail-tab-item span").removeClass("active"),$(this).addClass("active");var e=$(t).offset().top;return $("html,body").animate({scrollTop:e},1e3),!1}),setTimeout(function(){Util.transspace()},500),"undefined"!=typeof comment){comment({},{comment_star_position:"left",display_comment:!0,display_score_detail:!1,limit:50,totalCallback:function(t,e){5<Math.round(e)&&$("#commentNumber").html("(5.0)"),0<t&&($(".totalNum").html(t),$(".totalNum").removeClass("hide"))}});var a=setInterval(function(){if($(".gui-comment-bottom").length&&$("form .list-item").length){clearInterval(a),$(".common-dec").css("display","block");var t=$(".vertical-list, .comments-list");t.find("form").addClass("formarea1").find(".list-item").css("display","block"),$(".vertical-list, .comments-list").height()<$(".vertical-list form, .comments-list form").outerHeight()&&(t.append("<form class='formarea2'></form>"),t.find(".formarea2").html($(".formarea1").html()),crollfun())}},1e3);setTimeout(function(){a&&clearInterval(a)},2e4)}});