在小程序中需要button来进行开发功能的实现。但是button的默认样式,并不是项目中需要的。
html部分
<button open-type="getPhoneNumber" @getphonenumber="getphonenumber">授权登录</button>
css部分
去除默认样式:
button::after{
border: none;
}
button{
position: relative;
display: block;
margin-left: auto;
margin-right: auto;
padding-left: 0px;
padding-right: 0px;
box-sizing: border-box;
// font-size: 18px;
text-align: center;
text-decoration: none;
// line-height: 1;
line-height: 1.35;
// border-radius: 5px;
-webkit-tap-highlight-color: transparent;
overflow: hidden;
color: #000000;
background-color: #fff;
width: 100%;
height: 100%;
}