Commit f27c375f authored by 임지연_이모션's avatar 임지연_이모션

[임지연/이모션]입력창 포커스 시 고정 헤더 바로 아래위치(키패트 이슈)

parent 682df334
......@@ -2517,4 +2517,16 @@ $(".seller-wrap").length && UI.sellerFront();
/* 공통 : input : number only */
$("input:text[numberOnly]").on("keyup", function() {
$(this).val($(this).val().replace(/[^0-9]/g,""));
});
\ No newline at end of file
});
/* 공통 : input focus scrollTop */
$("input[type='text'], textarea" , ".c-input").on("focus", function () {
//alert();
var $topHeadHeight = $('.header-sub').height();
var $stickyHeight = $('.sticky-top').height();
$('html, body').animate({
scrollTop: $(this).offset().top - $topHeadHeight - $stickyHeight - 40
}, 400);
console.log($(this).offset())
});
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment