<template>
  <div class="no-data">
    <img :src="emptyBG" />
    <span>案件不存在</span>
    <el-button
      v-if="showBtn"
      class="btn"
      link
      text
      plain
      style="margin-top: 20px"
      @click="toHome"
      >回到首页</el-button
    >
  </div>
</template>
<script lang="ts" setup>
import emptyBG from "@/assets/image/empty__empty.png";
import { RouteName, router } from "@/router";
const props = withDefaults(
  defineProps<{
    showBtn: boolean;
  }>(),
  {
    showBtn: true,
  }
);
const toHome = () => {
  router.replace({ name: RouteName.vrmodel });
};
</script>
<style lang="scss" scoped>
.no-data {
  width: 100%;
  height: 100%;
  /* background: red; */
  min-height: 530px;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  .btn,
  span {
    color: #999;
  }
}
</style>
