使用媒体查询来做
//iphoneX、iphoneXs
@media only screen and (device-width: 375px) and (device-height: 812px)
//iphone Xs Max
@media only screen and (device-width: 414px) and (device-height: 896px)
// iphone 12
@media only screen and (device-width: 390px) and (device-height: 844px)
// iphone 12max
@media only screen and (device-width: 428px) and (device-height: 926px)
然后在响应式设置里面加上这些尺寸的手机就可以了。