<template>
  <div class="custom-tel-component">
    <div class="custom-tel-component-left" v-if="showTel">
      {{ num }}
    </div>
    <a :href="'tel:' + num" class="custom-tel-component-right">
      <i class="iconfont icon-dianhua1"></i>
    </a>
  </div>
</template>

<script>
export default {
  props: {
    showTel: {
      // 是否显示电话号码
      type: Boolean,
      default: true,
    },
    num: {
      // 电话号码
      type: String | Number,
      default: "",
    },
  },
};
</script>

<style lang="scss" type="text/scss" scoped>
.custom-tel-component {
  display: flex;
  justify-content: space-between;
  align-items: center;
  .custom-tel-component-left {
    flex: 1;
    font-size: 24px;
    line-height: 66px;
    color: $text3;
  }
  .custom-tel-component-right {
    width: 50px;
    height: 50px;
    background-color: $main;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    i {
      color: #fff;
      font-size: 25px;
    }
  }
}
</style>
