<template>
  <view>
    <up-popup
      :show="show"
      @close="close"
      mode="center"
      :safe-area-inset-bottom="false"
    >
      <view class="u-flex top justify-between u-p-32">
        <text class="title">{{props.tipsType}}</text>
        <up-icon name="close" @click="close"></up-icon>
      </view>
      <view class="u-p-30 font-14" style="width: 500rpx">
        {{ popupText }}
      </view>
    </up-popup>
  </view>
</template>


<script setup>
import { ref, computed } from "vue";

const show = defineModel({
  type: Boolean,
  default: false,
});
const props = defineProps({
  tipsType: {
    type: String,
    default: "",
  },
});
function close() {
  show.value = false;
}

const popupText = computed(() => {
  if (props.tipsType === "总收益") {
    return "总收益：即您在所有店铺通过分销获得总金额，包括待入账金额，但不包含已退款订单";
  }
  if (props.tipsType === "待入账") {
    return "待入账：即已通过订单分销获得但未达到结算时间的金额，结算时间达到后将会计入可提现金额";
  }
});
</script>

<style  lang="scss">
  .title {
    color: #000000;
    font-size: 32rpx;
    font-weight: 700;
  }
  .top {
    border-bottom: 2rpx solid #ededed;
  }
</style>