<template>
  <div class="share-hide-main animate__animated animate__fadeIn " @click.self="closeShare" v-show="showShare">
    <!--    <div class="share-box">-->
    <!--      <img id="code-box" src="/img/wx_qrcode.jpg" alt="">-->
    <!--    </div>-->
  </div>
  <div class="Final op0" data-animation="animate__animated animate__fadeInUp">
    <div class="Final-container font" :style="FinalStyle">
      <div class="Final-big-box">
        <div class="Final-left-box">
          <div class="Final-icon-box">
            <img src="/img/icon/logo.png" class="icon-img" alt="">
          </div>
          <div class="Final-left-title font">阿尔文 Unity资源一站式下载</div>
          <nuxt-link class="Final-left-title font" :to=getHerf(disclaimerUrl)>
            免责申明
          </nuxt-link>
          <div class="Final-left-info font">
            <div class="Final-left-info-item">
              <div class="Final-left-info-item-icon">
                <img src="/img/icon/Final_left_img3.png" alt="">
              </div>
              <div>2679599887@qq.com</div>
            </div>
            <div class="Final-left-info-item">
              <div class="Final-left-info-item-icon">
                <img src="/img/icon/Final_left_img2.png" alt="">
              </div>
              <div>13909751407</div>

            </div>

          </div>
        </div>

      </div>
      <div class="Final-bottom-box">
        <div>
          Copyright © 佛山市顺德区昂迩文科技中心
        </div>
        <div>
          粤ICP备2023123263号-2
        </div>
      </div>
    </div>
  </div>
</template>

<script setup>
const { t, locale } = useI18n()
// 样式配置
const FinalStyle = {
  FinalLeft: {},
  FinalMiddle: {},
}
const productTypeList = ref([])
let shareList = ref([
  // {
  //   contact_scancode_icon: '',
  //   contact_scancode_img: '',
  //   contact_scancode_title: '--'
  // },
  // {
  //   contact_scancode_icon: '/img/icon/wbIcon.png',
  //   contact_scancode_img: '',
  //   contact_scancode_title: '微博'
  // },
  // {
  //   contact_scancode_icon: '/img/icon/qqIcon.png',
  //   contact_scancode_img: '',
  //   contact_scancode_title: 'QQ'
  // },
])

let showShare = ref(false)
const closeShare = function () {
  showShare.value = false
}
const createShareCode = function (code) {
  showShare.value = true
  document.getElementById('code-box').src = code
}

// 获取
let bottomData = ref({})

// useFetch('/api/contactUs/getContactInfo').then(res => {
//   let resValue = JSON.parse(res.data.value).data
//   bottomData.value = resValue
//   shareList.value = resValue.qrcode
// })
const disclaimerUrl = ref("/disclaimer")

//请求产品
useFetch('/api/product/getProductTypeTree', { params: { locale: locale.value } }).then(res => {
  let data = JSON.parse(res.data.value).data || []
  res = []
  for (let key in data) {
    let obj = {}
    obj.name = data[key].product_type_name
    obj.href = '/project/project/' + data[key]['product_type_id'] + '-1'
    res.push(obj)
  }
  productTypeList.value = res
})

onMounted(() => {
  htmlAddAnimations()
})

</script>

<style lang="scss" scoped src="~/assets/css/Final/index.scss"></style>
<style lang="scss" scoped src="~/assets/css/Final/media.scss"></style>