<template>
  <div>
    <img
      :class="['preview-image', `preview-image--${imageName}`]"
      :src="dashboard"
    />
    <div class="preview-popup">
      <div class="preview-content">
        <img :src='demision' />
        <p>微信扫码体验</p>
      </div>
    </div>
  </div>
</template>

<script>
import kyWeappImg from '../images/ky_weapp.png';
import dashboard from '../images/dashboard.png';

export default {
  data() {
    return {
      demision: kyWeappImg,
      dashboard:dashboard,
    }
  },
  computed: {

  },
};
</script>

<style lang="less">
body {
  margin: 0;
  color: #323233;
  font-family: -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Helvetica,
    Segoe UI, Arial, Roboto, 'PingFang SC', 'Hiragino Sans GB',
    'Microsoft Yahei', sans-serif;
  line-height: 1;
  background-color: #f7f8fa;
  -webkit-font-smoothing: antialiased;
}

.preview {
  &-image {
    display: block;
    width: 100%;

    &--transition {
      margin-top: -62px;
    }
  }

  &-popup {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1;
    width: 100%;
    height: 100%;
    text-align: center;
    background-color: rgba(255, 255, 255, 0.95);
    opacity: 0;
    transition: 0.3s;

    &:hover {
      opacity: 1;
    }
  }

  &-content {
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 200px;
    text-align: center;
    transform: translateY(-60%);
    user-select: none;

    img {
      display: inline-block;
      width: 180px;
      height: 180px;
      margin-bottom: 15px;
    }

    p {
      margin: 0;
      color: #34495e;
      font-size: 16px;
      line-height: 1.5;
    }
  }
}
</style>
