<view class="login-btn auth-btn">
<text>用户一键登录</text>
<button open-type="getUserInfo" @getuserinfo="authLogin" />
</view>
.login-btn {
width: 620rpx;
height: 100rpx;
background: var(--primary-color-bg);
box-shadow: 0 0 30rpx 0 rgba(0,0,0,0.05);
border-radius: 100rpx;
margin: 76rpx auto 0;
display: flex;
align-items: center;
justify-content: center;
font-family: PingFang SC, PingFang SC;
font-weight: bold;
font-size: 32rpx;
color: var(--primary-btn-font-color);
}
.auth-btn {
background: #51A938;
color: #ffffff;
margin-top: 34rpx;
position: relative;
button {
position: absolute;
inset: 0;
opacity: 0;
z-index: 9999;
}
}
部分用户点击按钮无法拉起授权
1 个回复
DCloud_UNI_JBB
有报错吗?试试微信原生小程序这样写生不生效