<!--module/chats/pages/analysis/analysis.wxml-->
<t-navbar title="舌面象上传" left-arrow />
<scroll-view class="page-scroll__container" type="list" scroll-y style="{{containerStyle}}">
  <view class="upload-card" wx:for="{{uploadList}}" wx:key="{{item.target}}" mark:index="{{index}}" mark:target="{{item.target}}" bind:tap="handle">
    <view class="upload-card__header">
      <text>{{item.label}}上传</text>
      <text wx:if="{{item.required}}" style="color: #ff611b;">（必传）</text>
    </view>
    <view class="upload-card__content">
      <view class="row">
        <image class="col example" mark:handle="preview" src="{{item.src}}" mode="aspectFit" />
        <image wx:if="{{thumbnail[index]}}" class="col picture" mark:handle="preview:thumbnail" src="{{thumbnail[index]}}" mode="aspectFit"></image>
        <!-- <image wx:elif="{{original[index]}}" class="col picture" mark:handle="preview:original" src="{{original[index]}}" mode="aspectFit"></image> -->
        <image wx:else class="col picture" mark:handle="upload" src="../../assets/upload-picture.bg.png" mode="aspectFit" />
      </view>
      <view class="row">
        <view class="col">示例</view>
        <view class="col">
          <text>（上传）</text>
          <block wx:if="{{thumbnail[index]}}">
            <t-icon wx:if="{{original[index]}}" style="color: #ff611b;" name="delete-1" mark:handle="upload:delete" />
            <t-loading wx:else="" theme="spinner" size="40rpx" class="wrapper" />
          </block>
        </view>
      </view>
    </view>
  </view>

  <t-cell title="拍摄注意事项" required bordered="{{false}}">
    <view slot="description">
      <view style="margin-top: 8px;">光线：</view>
      <view>白天充足、柔和的自然光线下效果最佳，避免背光、偏暗、曝光。</view>
      <view style="margin-top: 8px;">禁忌：</view>
      <view>不要在食用有色饮食或药物后、有色光源下、早晨起床时、饭后半小时内拍摄舌象。</view>
    </view>
  </t-cell>

  <form bind:submit="onSubmit">
    <form-button block index="2"></form-button>
  </form>
</scroll-view>