Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

魅族 M3 的手机样式乱了,bar 高度对不上 #16

Open
yxhlance opened this issue Nov 19, 2019 · 10 comments
Open

魅族 M3 的手机样式乱了,bar 高度对不上 #16

yxhlance opened this issue Nov 19, 2019 · 10 comments

Comments

@yxhlance
Copy link

9800580

@lingxiaoyi
Copy link
Owner

你使用最新的代码测试的吗?最近一版我又最了多个容错处理

@yxhlance
Copy link
Author

TIM截图20191119115934
我这个是昨天下载的

@lingxiaoyi
Copy link
Owner

那不至于啊 你调试一下你那里获取的胶囊信息,发这里我看一下?

@yxhlance
Copy link
Author

TIM截图20191119133945
你看看

@lingxiaoyi
Copy link
Owner

//取值为0的情况
if (!rect.width) {
throw 'getMenuButtonBoundingClientRect error';
}
上方这段代码改成下边这样试试
if (!rect.width || !rect.top || !rect.left) {
throw 'getMenuButtonBoundingClientRect error';
}
没想到这款机子胶囊信息这么奇葩

@lingxiaoyi
Copy link
Owner

if (!rect.width || !rect.top || !rect.left || !rect.height) {
throw 'getMenuButtonBoundingClientRect error';
}
把高度的判断也加进去

@yxhlance
Copy link
Author

可以呀! 好厉害。
最后就是下面这个内容的高度问题了,你现在的效果是滚动的区域也包括了上面的导航,所以会被挡住部分内容,如果是动态计算下面内容的高度就不会。
TIM截图20191119135946

@lingxiaoyi
Copy link
Owner

导航条默认会有一个占位高度的,你这个我不知道什么情况导致默认高度没了,你测下其他手机.是不是这个手机的问题

@yxhlance
Copy link
Author

好像不仅是手机,开发工具也会
TIM截图20191120105620

@lingxiaoyi
Copy link
Owner

image
我这里没问题啊,你先查查什么问题导致的

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants