<style lang="less">
.components-date-none {
  position: fixed;
  bottom: 43.3%;
  left: 0;
  right: 0;
  .wrap {
    text-align: center;
    &.center {
      display: flex;
      flex-direction: column;
      justify-content: center;
      height: 100%;
    }

    .desc {
      font-family: PingFang SC;
      margin-top: 32rpx;
      font-size: 34rpx;
      line-height: 48rpx;
      color: #c4c4c4;
    }

    .poster {
      margin: 0 auto;
      width: 200rpx;
      height: 200rpx;
      display: block;
    }
  }
}
</style>

<template>
  <div class="components-date-none">
    <div class="wrap {{position}}">
      <Icon
        v-if="iconName"
        :name="iconName"
        size="100"
        color="rgba(196, 196, 196, 0.4)"
        weight="200"
      />
      <img v-else-if="imgUrl" class="poster" :src="imgUrl" />

      <div class="desc">
        <span>{{ desc }}</span>
      </div>
    </div>
  </div>
</template>


<script>
import wepy from '@wepy/core';

wepy.component({
  props: {
    desc: String,
    // 有的需要在剩余位置中居中处理
    position: {
      type: String,
      default: ''
    },
    iconName: {
      type: String
    },
    iconColor: {
      type: String,
      default: ''
    },
    imgUrl: {
      type: String,
      default: ''
    }
  }
});
</script>

<config>
{
  "usingComponents": {
    "Icon": "~@/components/TUI/Icon"
  },
  "componentPlaceholder": {
    "Icon": "view"
  }
}
</config>