
<template>
  <el-dialog :visible="dialogVisible" @close="handleClose">
    <img width="100%" :src="previewUrl" alt="img">
  </el-dialog>
</template>
<script>
export default {
  name: 'PreviewImageDialog',
  data() {
    return {
      dialogVisible: false,
      previewUrl: null
    }
  },
  methods: {
    handleOpen(previewUrl) {
      this.previewUrl = previewUrl
      this.dialogVisible = true
    },
    handleClose() {
      this.dialogVisible = false
      this.previewUrl = null
    }
  }
}
</script>
<style scoped lang="scss">

</style>
