view,navigator{ box-sizing: border-box; font-size: 28rpx; color: #333; } .login{ position: fixed; width: 100%; height: 100vh; z-index: 10; background: rgba(0, 0, 0, .5); left: 0; top: 0; } .login view{ width: 80%; background: #fff; border-radius: 4px; text-align: center; position: absolute; top: 0; bottom: 0; left: 0; right: 0; margin: auto; height: 100px; } .login text{ display: block; padding: 20px; } .login button{ width: 100% !important; height: 48px; color: #fff; background-color: #fa5151; border-top-left-radius: 0; border-top-right-radius: 0; padding: 0; line-height: 48px; } image{ max-height: 100%; }