1***@163.com
1***@163.com
  • 发布:2021-12-01 11:30
  • 更新:2021-12-01 11:30
  • 阅读:1986

uni-app如何用媒体查询适应不同手机样式

分类:uni-app

@media only screen and (device-width: 375px) and (device-height: 667px) and (-webkit-device-pixel-ratio: 2){
}
@media only screen and (device-width: 414px) and (device-height: 736px) and (-webkit-device-pixel-ratio:3){
}
@media only screen and (device-width: 375px) and (device-height: 812px) and (-webkit-device-pixel-ratio:3){
}

如果用下面的方法,则控制不住,方法都会走:
@media only screen and (max-width: 375px) and (max-height: 667px) {
}
@media only screen and (max-width: 414px) and (max-heigh: 736px){
}
@media only screen and (max-width: 375px) and (max-heigh: 812px){
}

2021-12-01 11:30 负责人:无 分享
已邀请:

该问题目前已经被锁定, 无法添加新回复