<template>
  <view class="video-message" @click="onTap">
    <image class="video-player" :src="message.thumbnail.url" mode="scaleToFill" />
    <image
      class="Play"
      src="https://vv-1317974657.cos.ap-shanghai.myqcloud.com/util/Play.png"
      mode="scaleToFill"
    />
  </view>
</template>

<script>
export default {
  props: {
    message: {
      type: Object,
      default: "",
    },
  },
  data() {
    return {
      title: "Hello",
    };
  },
  onLoad() {
    // 页面加载时执行
  },
  methods: {
    onTap() {
      wx.navigateTo({
        url:
          "/pages/index/chat/messageComponent/fullscreen/videoPreview?url=" +
          this.message.video.url,
      });
    },
  },
};
</script>

<style scoped>
.video-message {
  width: 450rpx;
  height: 300rpx;
  border-radius: 20px;
  display: flex;
}
.video-player {
  width: 100%;
  height: 100%;
  border-radius: 20px;
}
.Play {
  width: 200rpx;
  height: 200rpx;
  margin-left: -330rpx;
  margin-top: 50rpx;
}
</style>
