You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

55 lines
1.0 KiB

<template>
<view class="index">
<view class="inp-box">
<textarea @input="sumfontnum" maxlength="100" @blur="bindTextAreaBlur" placeholder-style="color:#999999;" placeholder="请填写您宝贵的反馈意见" />
<view class="fontnum">{{fontnum}}/100</view>
</view>
<view class="submit-btn">提交</view>
</view>
</template>
<script>
export default{
data(){
return {
feedBack:'',
fontnum:0
}
},
methods:{
bindTextAreaBlur: function (e) {
console.log(e.detail.value)
},
sumfontnum(e){
this.fontnum = e.detail.value.length
}
}
}
</script>
<style lang="less" scoped>
.inp-box{
width: 100%;
background: #fff;
padding: 24rpx;
font-size: 28rpx;
position: relative;
.fontnum{
font-size: 24rpx;
color: #999;
position: absolute;
right: 28rpx;
bottom: 16rpx;
}
}
.submit-btn{
width: 208rpx;
height: 80rpx;
background: #6E85EB;
color: #fff;
text-align: center;
line-height: 80rpx;
border-radius: 4rpx;
margin: 30rpx auto;
}
</style>