...
|
...
|
@@ -66,7 +66,7 @@ exports.init = function() { |
|
|
thumbContainer
|
|
|
.addClass('fixed-bottom')
|
|
|
.removeClass('static');
|
|
|
} else if (sTop <= containerTop - wH + tContainerH) {
|
|
|
} else if (sTop <= containerTop) {
|
|
|
thumbContainer
|
|
|
.addClass('static')
|
|
|
.removeClass('fixed-bottom fixed-top');
|
...
|
...
|
@@ -94,5 +94,24 @@ exports.init = function() { |
|
|
if ($(document).scrollTop() === 0) {
|
|
|
$(document).scroll();
|
|
|
}
|
|
|
|
|
|
//计算小箭头位置
|
|
|
(function (doc, win) {
|
|
|
var docEl = doc.documentElement,
|
|
|
resizeEvt = 'orientationchange' in window ? 'orientationchange' : 'resize',
|
|
|
arrowPosition = function () {
|
|
|
var clientWidth = docEl.clientWidth;
|
|
|
if (!clientWidth) {
|
|
|
return;
|
|
|
}
|
|
|
docEl.style.fontSize = 20 * (clientWidth / 320) + 'px';
|
|
|
};
|
|
|
|
|
|
if (!doc.addEventListener) {
|
|
|
return;
|
|
|
}
|
|
|
win.addEventListener(resizeEvt, arrowPosition, false);
|
|
|
doc.addEventListener('DOMContentLoaded', arrowPosition, false);
|
|
|
})(document, window);
|
|
|
});
|
|
|
}; |
|
|
\ No newline at end of file |
...
|
...
|
|