textarea bug,auto-height 在部分机器上高为2

发布于 6 年前作者 xiulanchang5384 次浏览最后编辑 6 年前来自 ask

设置textarea 为auto-height 在小米,vivo都是正常的,在荣耀H60-L01上时,高变成2了,不清楚在别的机型上是否也是这样,

//```.wxml

<textarea auto-height bindinput=‘textInput’ id=‘{{item_id}}_textarea’  bindfocus=‘textHaveFocus’ bindblur=‘textLostFocuse’ style=“border: 2rpx solid blue;” type=“text” value=“{{item_value}}” />

// ```.js

  wx.createSelectorQuery().selectAll(‘.editTextItem’).boundingClientRect(function(rects) {

  rects.forEach(function(rect){

  console.log(‘rect’, rect)

  })

  }).exec()

0 回复
暂无回复