<view class="box">
	<view class="title">{{language['评论']||'评论'}}</view>

	<view class="textarea-box">
		<textarea value="{{contentText}}" class="textarea" maxlength="499" placeholder="{{language['发表评论']||'发表评论'}}" bindinput='textareaInput' />
	</view>

	<view class="textarea-but">
		<van-button type="default" loading='{{loading}}' disabled="{{!contentText}}" custom-class='custom-class' bind:click="onSend">{{language['发表']||'发表'}}</van-button>
	</view>



	<view wx:for="{{list}}" wx:key="sys_datacommentid">
		<view class="item">
			<view class="headpic">
				<image class="image" wx:if="{{item.headpic}}" src="{{item.headpic}}" mode="aspectFill" lazy-load />
				<view class="createby" wx:else>
					{{item.createby[0]}}
				</view>
			</view>

			<view class="content">
				<view class="name">
					<view class="createby line-1">{{item.createby}}<text wx:if="{{item.replyusername}}" class="iconfont icon-a-shouyezuixintonggaolantiaozhuan" style="padding: 0;">{{' '+item.replyusername}}</text>
					</view>
					<text wx:if="{{userid == item.createuserid}}" class="iconfont icon-guanlian-shanchu" data-item="{{item}}" bind:tap="deleteItem" />
				</view>
				<view class="text">
					{{item.content}}
				</view>
				<view class="bottom">
					<view class="time">{{item.createdate}}</view>
					<view class="reply" data-id="{{item.sys_datacommentid}}" bind:tap="revert"><text class="iconfont icon-huifu" /><text wx:if="{{item.sys_datacommentid == replyid}}">{{language['取消回复']||'取消回复'}}</text><text wx:else>{{language['回复']||'回复'}}</text></view>
				</view>
			</view>
		</view>

		<block wx:if="{{item.sys_datacommentid == replyid}}">
			<view class="textarea-box">
				<textarea value="{{item.contentText}}" focus="true" class="textarea" maxlength="499" placeholder="{{'回复'+item.createby+':'}}" data-item="{{item}}" bindinput='itemTextareaInput' />
			</view>
			<view class="textarea-but">
				<van-button type="default" loading='{{item.loading}}' disabled="{{!item.contentText}}" custom-class='custom-class' bind:click="onSendItem">{{language['发表']||'发表'}}</van-button>
			</view>
		</block>
	</view>
</view>