在点击评论按钮时,键盘自动弹起,同时键盘上出现输入框
输入框代码大多数使用了官方提供的组件属性,建议多翻文档
https://developers.weixin.qq.com/miniprogram/dev/component/input.html
https://developers.weixin.qq.com/miniprogram/dev/component/textarea.html
代码如下
.wxml
<view>
<view class="good-main">
<!-- 评论框 -->
<view
id="ctInput"
class="ct-input"
wx:if="{
{ showComtBox }}"
style="top: {
{ ctInput_top }}px;"
>
<textarea
placeholder="说点什么吧…"
focus="{