Update laydate.dev.js

保证日历控件显示不会在页面显示区域之外。 ( 保证 控件top > 0  )
pull/13/head
Relucent 2015-07-21 17:09:36 +08:00
parent 0dfe347add
commit a536f42166
1 changed files with 1 additions and 1 deletions

View File

@ -487,7 +487,7 @@ Dates.orien = function(obj, pos){
} else {
tops = rect.top > obj.offsetHeight/1.5 ? rect.top - obj.offsetHeight + 1 : Dates.winarea() - obj.offsetHeight;
}
obj.style.top = tops + (pos ? 0 : Dates.scroll()) + 'px';
obj.style.top = Math.max(tops + (pos ? 0 : Dates.scroll()),1) + 'px';
};
//吸附定位