CSS
0
Вклад в тег
var topOffset = $("#map-search").offset();
function mapSearchScroll(top,topOffset){
if(top > topOffset.top){
$("#map-search").css({
"-webkit-transform":"translate(0," + (top - topOffset.top) +"px)",
"-ms-transform":"translate(0," + (top - topOffset.top) +"px)",
"transform":"translate(0," + (top - topOffset.top) +"px)"
});
}else{
$("#map-search").css({
"-webkit-transform":"translate(0,0)",
"-ms-transform":"translate(0,0)",
"transform":"translate(0,0)"
});
}
}