<!--  input/input.wxml -->
<label
  class='form-item {{disabled? "disabled": ""}} l-class form-item-{{labelLayout}}'
  style="width:{{width}}rpx">
  <view class='mask' wx:if="{{disabled}}"></view>
  <view class='row' style="width:{{width}}rpx;"></view>
  <view wx:if="{{label && !labelCustom}}" class='form-label l-label-class form-label-{{labelLayout}}' style='{{labelLayout !== "top" ? "width:"+ labelWidth+ "rpx;" : "" }} height:{{labelLayout== "top" ? labelWidth + "rpx" : "" }}'>
    <text><text class='text-require' wx:if="{{required}}">* </text>{{label}}<text wx:if="{{colon}}">：</text>
    </text>
  </view>
  <view wx:else class='form-label l-label-class form-label-{{labelLayout}}' style='{{labelLayout !== "top" ? "width:"+ labelWidth+ "rpx;" : "" }} height:{{labelLayout== "top" ? labelWidth + "rpx" : "" }}'>
    <slot name="left" />
  </view>
  <!-- 小程序表单组件 -->
  <input
    class="input"
    value="{{ value }}"
    type="{{type}}"
    password="{{type==='password'}}"
    placeholder="{{placeholder}}"
    maxlength="{{maxlength}}"
    placeholder-class="pls-class"
    placeholder-style="{{placeholderStyle}}"
    disabled="{{disabled}}"
    focus="{{focus}}"
    bindinput="handleInputChange"
    bindfocus="handleInputFocus"
    bindblur="handleInputBlur"
    bindconfirm="handleInputConfirm" />
  <view class="close" wx:if="{{clear&&value}}" bindtap="onClearTap">
    <view  class="close-icon">
      <l-icon  name="close" color="#fff" size="16" />
    </view>
  </view>
  <slot name="right"/>
  <l-error-tip l-error-text="l-error-text" errorText="{{errorText}}" wx:if="{{errorText}}"/>
</label>