Commit 85b289fe by doszhang

dos

parent d449ed0c
...@@ -46,6 +46,7 @@ if ($('div').length > 0) { ...@@ -46,6 +46,7 @@ if ($('div').length > 0) {
$('.loading-page').show(); $('.loading-page').show();
preloadimages(preloadImageList, function () { preloadimages(preloadImageList, function () {
initPage();
$('.loading-page').hide(); $('.loading-page').hide();
$('.home-page').show(); $('.home-page').show();
}, function (progress) { }, function (progress) {
...@@ -126,8 +127,6 @@ $(document).ready(function () { ...@@ -126,8 +127,6 @@ $(document).ready(function () {
//滚动条 //滚动条
$('.rule-block').on('scroll', ruleScroll); $('.rule-block').on('scroll', ruleScroll);
$(".index-block").on("touchstart", function (e) { $(".index-block").on("touchstart", function (e) {
// 判断默认行为是否可以被禁用 // 判断默认行为是否可以被禁用
if (e.cancelable) { if (e.cancelable) {
...@@ -162,6 +161,14 @@ $(document).ready(function () { ...@@ -162,6 +161,14 @@ $(document).ready(function () {
}); });
}); });
function initPage() {
let displacement = parseInt(getTranslateDistance());
if (displacement > 0) {
let height = 61.9 + ((displacement + 10) / fontSize);
$('.wrap-inner,.page,.bg,.personal-wrap').css('height', height + 'rem');
}
}
function ruleScroll() { function ruleScroll() {
//7.9-46.9 //7.9-46.9
if (timer) { if (timer) {
......
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 sign in to comment