iview-weapp icon indicating copy to clipboard operation
iview-weapp copied to clipboard

微信更新了v2版本的button,好像会影响i-button

Open jbnjvc10000 opened this issue 4 years ago • 4 comments

微信开发工具默认启用了v2,目前我遇到i-button的大小无法正常显示的情况

jbnjvc10000 avatar Mar 14 '20 09:03 jbnjvc10000

改line-height:28px;

798714773 avatar Mar 20 '20 09:03 798714773

改line-height:28px;

并不只有这一个问题。。。v2开启后i-button的width莫名其妙变短了。。。

AliveGh0st avatar May 13 '20 18:05 AliveGh0st

微信开发工具默认启用了v2,目前我遇到i-button的大小无法正常显示的情况

知道原因了,v2中,有一个多出来的按钮样式,叫button:not([size='mini']),不知道为啥这个样式在 所有样式里优先级最高,这里把按钮样式设置成固定的宽度并且更改了button组件的行高,导致iview的行高和宽度都出现了异常,简单的解决 办法是在app.wxss里面将button样式里面添加width:95% !important;才能修改按钮高度。。太坑了

AliveGh0st avatar May 13 '20 19:05 AliveGh0st

微信开发工具默认启用了v2,目前我遇到i-button的大小无法正常显示的情况

另外i-button的shape属性也生效不了,原因也是这个,自行在dist/button/index.wxss中的border-radius后面加上!important才行

AliveGh0st avatar May 13 '20 19:05 AliveGh0st