1$(function () { 2 $(document).ready(function() { 3 //ë©ë´ 4 gnb(); 5 //모ë°ì¼ë©ë´í´ë¦ 6 gnb_mobile() 7 8 //모ë°ì¼ ë©ë´ë²í¼ 9 hamburger_menu(); 10 11 // ì¤í¬ë¡¤ ë ë ì¤í 12 window.lastScrollTop = 0; // íì¬ ì¤í¬ë¡¤ ì´ì ì ì¤í¬ë¡¤ ìì¹ 13 $(window).scroll(function() { 14 gnb_fixed(); 15 }); 16 17 // ë¸ë¼ì°ì í¬ê¸° ë³ê²½ì´ ì¼ì´ë ë ì¤í 18 $(window).resize(function() { 19 gnb(); 20 gnb_fixed(); 21 //menu_swiper(); 22 }); 23 24 25 //ë©ì¸ë¼ë²¨ë°°ê²½ì´ë¯¸ì§ 26 //main_label(); 27 }); 28 29 // 모ë°ì¼ì¸ì§ ì¬ë¶ 30 function isMobile() { 31 return window.innerWidth <= 1023; 32 } 33 34 function isMobile_02() { 35 return window.innerWidth <= 640; 36 } 37 38 //gnb 39 function gnb(){ 40 41 42 var gnb_gnm1 = $('#header #gnb .gnb_menu > ul'); 43 // ì´ê¸°í ìì 44 gnb_gnm1.find('.gnm2').css('display', ''); 45 gnb_gnm1.css('height', ''); 46 gnb_gnm1.find('li').removeClass('active'); 47 $('.bg_layer').css({ 48 'opacity':'0', 49 'height':'0' 50 }); 51 $('.gnb_new').css({ 52 'height':'0' 53 }); 54 // ì´ê¸°í ì¢ ë£ 55 gnb_gnm1.on('mouseenter focusin', function(){ 56 if(isMobile() == false) { 57 $(this).addClass('on'); 58 if($(this).find('.gnm2').length == 0){ 59 $('#gnb .gnb_menu > ul').stop(true,false).animate({ 60 'height':$('#header .hd_fixed.fix').length > 0 ? 60 : 120+'px' 61 }, 300); 62 gnb_gnm1.find('.gnm2').stop(true,false).css('height','0px'); 63 } else { 64 $('#gnb .gnb_menu > ul').stop(true,false).animate({ 65 'height':'320px' 66 }, 300); 67 $('.bg_layer').stop(true,false).animate({ 68 'opacity':'1', 69 'height':'250px' 70 }, 300); 71 gnb_gnm1.find('.gnm2').stop(true,false).css('display','block'); 72 //setTimeout(function () { 73 gnb_gnm1.find('.gnm2').stop(true,false).css('height','auto'); 74 //}, 300); 75 76 $('.gnb_new').stop(true,false).animate({ 77 'height':'289px' 78 }, 300); 79 } 80 81 82 $('.hd_content .gnb_left').css ('background-image', 'url(/dob_comm_img/gnb_left_menubg.gif)'); 83 $('.hd_content .gnb_left').css ('background-position','left top'); 84 } 85 }); 86 87 gnb_gnm1.on('mouseleave focusout', function(){ 88 if(isMobile() == false) { 89 $(this).removeClass('on'); 90 $('#gnb .gnb_menu > ul').stop(true,false).animate({ 91 'height':$('#header .hd_fixed.fix').length > 0 ? 60 : 120+'px' 92 }, 300); 93 94 $('.bg_layer').stop(true,false).animate({ 95 'opacity':'0', 96 'height':'0' 97 }, 300); 98 99 gnb_gnm1.find('.gnm2').stop().css('height',''); 100 //setTimeout(function () { 101 gnb_gnm1.find('.gnm2').stop().css('display','none'); 102 //}, 300); 103 104 $('.gnb_new').stop(true,false).animate({ 105 'height':'0' 106 }, 300); 107 } 108 109 $('.hd_content .gnb_left').css ('background-image', 'url("")'); 110 }); 111 } 112 113 //gnb_mobile 114 function gnb_mobile(){ 115 var gnb_gnm1 = $('#header #gnb .gnb_menu > ul > li.gnm1'); 116 gnb_gnm1.on('click', function(){ 117 if(isMobile() == true) { 118 $(this).addClass('active').siblings('li').removeClass('active'); 119 } 120 }); 121 } 122 123 //mobile_gnb_btn 124 function hamburger_menu() { 125 $(".hamburger").click(function(e){ 126 if(isMobile() == true) { 127 e.preventDefault(); 128 129 if ($('.hamburger').hasClass('is-active')) 130 { 131 $('body').removeClass('fixed').css('height', ''); 132 $('#container').css('position', 'relative'); 133 $('#header').removeClass('on'); 134 $('.hamburger').removeClass("is-active"); 135 setTimeout(function () { 136 $('body').removeClass('fixed').css('height', ''); 137 $('.bg_layer').stop(true,false).animate({ 138 'opacity':'0', 139 'height':'0' 140 }) 141 }, 100) 142 $('.gnb_menu').css ('background-image', 'url("/sg_comm_img/gnb_bg.gif")'); 143 $('.gnb_menu').css ('background-repeat','repeat-x'); 144 $('.gnb_area').css ('background', ''); 145 146 }else { 147 setTimeout(function () { 148 $('#header').addClass('on'); 149 $('.hamburger').addClass("is-active");
150 $('.bg_layer').stop(true,false).animate({ 151 'opacity':'0.7', 152 'height':'100%' 153 }) 154 setTimeout(function () { 155 $('body').css('height', $(window).height()).addClass('fixed'); 156 $('#container').css('position', 'absolute'); 157 }, 500) 158 }) 159 160 $('.gnb_menu').css ('background-image', 'url("")'); 161 $('.gnb_area').css ('background', '#fff'); 162 } 163 } 164 }); 165 }; 166 167 //gnb_fixed 168 function gnb_fixed() { 169 window.nowScrollTop = $(window).scrollTop(); // íì¬ ì¤í¬ë¡¤ ìì¹ 170 var isScrollUpGnbOffset = window.nowScrollTop <= 50; // 50pxë³´ë¤ ìì ì¤í¬ë¡¤ì´ ìì ë true 171 172 173 if(isMobile() == false) { // PC 174 $( '.hd_fixed' ).toggleClass('fix', isScrollUpGnbOffset == false); 175 $( '.hd_fixed' ).css('height', ''); 176 $( '#header' ).css('height', ''); 177 } else { // MOBILE 178 $( '.hd_fixed' ).css('height', '0px'); 179 $( '#header' ).css('height', '0px'); 180 } 181 182 183 var gnbHeight = 400; 184 if(isMobile() == true) { 185 gnbHeight = 80; 186 } 187 if(isScrollUpGnbOffset == false && Math.abs(window.lastScrollTop - window.nowScrollTop) > 10 && window.nowScrollTop >= gnbHeight) { 188 var isScrollUp = window.lastScrollTop > window.nowScrollTop; // ì¤í¬ë¡¤ì´ ìë¡ ì¬ë¼ê°ë true 189 $( '.hd_fixed' ).toggle(isScrollUp); 190 191 } else if(isScrollUpGnbOffset) { 192 $( '.hd_fixed' ).show(); 193 194 } 195 196 window.lastScrollTop = window.nowScrollTop; 197 } 198 199 200 //main_label 201 function main_label() { 202 $(".label_bg").on('mouseenter', function(){ 203 $(this).addClass('on'); 204 }) 205 206 $(".label_bg").on('mouseleave', function(){ 207 $(this).removeClass('on'); 208 }); 209 }; 210 211 /* scale */ 212 $('.store_listwrap .storelist .storebox .store_img') 213 .on('mouseover', function(){ 214 $(this).find('img').stop(true).animate({ 215 scale:'1.05'},500 216 ); 217 }) 218 .on('mouseout', function(){ 219 $(this).find('img').stop(true).animate({ 220 scale:'1'},500 221 ); 222 }); 223}); 224 225function openPopup(event, url) { 226 event.preventDefault(); 227 window.open( 228 url, 229 'popup', 230 'width=600,height=600,left=200,top=150' 231 ); 232} 233 234 235$(document).ready(function(){ 236 $('.open-popup').click(function(e) { 237 e.preventDefault(); let thisPopup = $(this).closest('.popup-wrap').find('.popup-box'); $('.popup-box').not(thisPopup).css('display', 'none'); thisPopup.toggle(); 238 }); $('.close-popup').click(function(e) { 239 e.preventDefault(); 240 $(this).closest('.popup-box').css('display', 'none'); 241 }); 242});/* ë²í¸ë³µì¬ */ 243function copyToClipboard(e, selector) { 244 e.preventDefault(); var text = $(selector).val(); var $temp = $("<input>"); 245 $("body").append($temp); 246 $temp.val(text).select(); document.execCommand("copy"); $temp.remove(); alert('URLì´ ë³µì¬ëììµëë¤.'); 247}
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.