<!--
 * @Author: LiZhiWei
 * @Date: 2025-04-24 15:29:17
 * @LastEditors: LiZhiWei
 * @LastEditTime: 2025-04-24 16:24:34
 * @Description: 
-->
<template>
  <div>
    <!-- <img v-for="item in images" alt="图片" :src="item.src" :key="item.index" class="image" /> -->
    <el-image
      :src="images[0]"
      :preview-src-list="images"
      width="100%"
      height="100%"
      :preview="true"
    />
  </div>
</template>

<script setup>
import { computed } from "vue"
const props = defineProps({
  image: String,
})

const images = computed(() => {
  return props.image ? [props.image] : []
})
</script>

<style scoped>
.image {
  display: block;
  width: auto;
  height: 100%;
  margin: 0 auto;
}
</style>
