<template>
  <div class="free-tips-wrapper" @click="buyCard">
    <div class="left">
      <img src="../../images/question/warning-h.png" alt />
      <span class="text">免费练习{{total}}题，解锁全部题目需完成购买</span>
    </div>
    <img class="right" src="../../images/question/arror-right.png" alt />
  </div>
</template>
<script>
export default {
  props: {
    total: {
      type: String | Number,
      default: 5
    }
  },
  methods: {
    buyCard() {
      this.$emit("buyCard");
    }
  },
}
</script>
<style lang="less" scoped>
.free-tips-wrapper {
  width: 100%;
  position: fixed;
  left: 0;
  bottom: 60px;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  height: 40px;
  line-clamp: 40px;
  padding-left: 15px;
  background: #FEFAF5;
  .left {
    display: flex;
    flex-direction: row;
    align-items: center;
    & > img {
      width: 13px;
      height: 13px;
      margin-right: 4px;
    }
    & > span {
      font-size: 13px;
      color: #E6A23C;
    }
  }
  .right {
    padding: 10px 15px;
    width: 15px;
    height: 15px;
  }
}
</style>