textarea bug,auto-height 在部分机器上高为2
发布于 5 年前 作者 xiulanchang 5239 次浏览 来自 问答

设置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()

回到顶部