$(function(){ startJs(); menuJs(); }); $(document).on('click', 'a[href="#none"]', function(e) { e.preventDefault(); }); //기본js function startJs(){ $("body").addClass('ani'); $(document).on('click', 'a[href="#none"]', function(e) {e.preventDefault()}); if($('html').is('.ie67, .ie7, .ie8, .ie9')) { $('div.ie_alert_text').show().html('현재 사이트는 IE9 미만의 하위브라우저를 지원하지 않습니다.
브라우저를 최신 버전으로 업데이트해 주세요.'); } WebFont.load({google: {families: ['Noto Sans KR', 'Montserrat']}}); } function menuJs() { $(document).on("click","#nav .menu.more .dep1",function(){ $("#nav .menu").removeClass('open'); if($(this).attr("class") == "dep1 on"){ $(this).next(".dep2").slideUp(); $(this).parents("#nav .menu").removeClass('open'); }else{ $(this).next(".dep2").slideDown(300); $(this).parents("#nav .menu").addClass('open'); } $(this).toggleClass('on'); $(this).parents("#nav .menu").siblings().find(".dep1").removeClass("on"); $(this).parents("#nav .menu").siblings().find(".dep2").slideUp(); }); $(document).on("click","#hamburger_btn",function(){ $(this).addClass("close"); $("header .all_group").show(); $("#wrap").addClass("allmenuOpen"); }); $(document).on("click","#hamburger_btn.close",function(){ $(this).removeClass("close"); $("header .all_group").hide(); $("#wrap").removeClass("allmenuOpen"); }); //모바일구분 $(window).resize(function(){ windowWidth = $(window).width(); if(windowWidth < 1279){ $("body").addClass("mobile"); $("header .all_group").hide(); $("#hamburger_btn").removeClass("close"); $("#wrap").removeClass("allmenuOpen"); }else{ $("body").removeClass("mobile"); $("header .all_group").show(); } }).resize(); }