vant框架van-field输入栏添加外边框
van-field标签默认是无外边框的,如下图:
添加外边框后的样式,如下图:
采用样式穿透的方式,上代码:
<div class="rowTextArea">
<van-field
v-model="ruleForm.address"
name="地址"
label="地址"
required
type="textarea"
placeholder="请输入详细地址"
/>
</div>
添加外边框
.rowTextArea::v-deep .van-field__value{
border: 1px solid #ccc;
}
换行
.rowTextArea::v-deep .van-cell{
display: flow-root;
}