1(function($) { 2 $(function() { 3 // ABOUT 4 $('.card_head > span').click(function() { 5 var target = $(this).attr("data-target"); 6 $(".card_box, .card_head > span").removeClass("active"); 7 $(this).addClass("active"); 8 $(target).addClass("active"); 9 }); 10 11 var moveto = function(href) { 12 var target = $(href); 13 var speed = 400; 14 var position = target.offset().top; 15 $('body,html').animate({ 16 scrollTop: position - 512 - 100 17 }, speed, 'swing'); 18 } 19 20 $('nav.g_nav li a').on("mouseover", function() { 21 $(this).addClass("active"); 22 var target = $(this).attr("data-target"); 23 $(target).addClass("active"); 24 }); 25 $('nav.g_nav li a').on("mouseout", function() { 26 $(this).removeClass("active"); 27 var target = $(this).attr("data-target"); 28 $(target).removeClass("active"); 29 }); 30 $('.mega_menu').on("mouseover", function() { 31 $(this).addClass("active"); 32 var target = $(this).attr("data-target"); 33 $(target).addClass("active"); 34 }); 35 $('.mega_menu').on("mouseout", function() { 36 $(this).removeClass("active"); 37 var target = $(this).attr("data-target"); 38 $(target).removeClass("active"); 39 }); 40 41 $('.mega_menu > a').click(function() { 42 // var target = $(this).attr("data-target"); 43 // $(".card_box, .card_head > span").removeClass("active"); 44 $(this).toggleClass("active"); 45 $(this).next().toggleClass("active"); 46 }); 47 $('#menu_btn').click(function() { 48 $("#menu_btn_icon").toggleClass("menu_close"); 49 $('.mega_box').toggleClass('active'); 50 $('body').toggleClass('fixed'); 51 }); 52 53 var page = 0; 54 $('#add_btn').click(function() { 55 $.ajax('add_card.html/'+page, { 56 timeout : 1000, // 1000 ms 57 datatype:'html' 58 }).then(function(data){ 59 page++; 60 var out_html = $($.parseHTML(data));//parse 61 $('#add_box').before(data);//insert 62 63 // $(".fade").fadeIn(100, function() { 64 $(".fade").removeClass("fade"); 65 // }); 66 moveto("#add_btn"); 67 },function(jqXHR, textStatus) { 68 }); 69 }); 70 71 var window_cash = $(window); 72 var pos_fix = function() { 73 now = window_cash.scrollTop(); 74 under = 400; 75 if (now > under) { 76 var btm_pos = $("footer nav.cta li").height(); 77 $(".pagetop_btn").addClass("active").css("bottom", btm_pos + "px"); 78 } else { 79 $(".pagetop_btn").removeClass("active"); 80 } 81 } 82 $(window).on("load scroll resize", function() { 83 pos_fix(); 84 }); 85 $('.pagetop_btn').click(function() { 86 $('html,body').animate({ 87 scrollTop: 0 88 }, 'slow'); 89 }); 90 // ãµã¤ãã¡ãã¥ã¼ã¢ã¯ãã£ã 91 var url = window.location.pathname; 92 $('.side_menu li a[href="'+url+'"]').parent().addClass('active'); 93 }); 94})( jQuery );
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.