<template>
  <footer class="overflow-hidden">
    <div class="sm:h-[100px] h-[50px]"></div>
    <div class="text-center bg-white text-red-7 py-10" style="display: none">
      本网站为小象CMS演示站，提供的电视剧和电影资源均系收集于各大视频网站<br />
      若本站收录的节目无意侵犯了贵司版权,请给我们留言,我们会及时逐步删除和规避程序自动搜索采集到的不提供分享的版权影视。<br />
      本站仅供测试和学习交流。请大家支持正版。
    </div>
    <div class="w-full flex flex-col sm:bg-black justify-between">
      <!-- PC版 -->
      <div class="sub-menu w-full md:w-3/4 m-auto flex justify-between py-10 text-center p-2 hidden-sm-and-down">

        <!-- 底部菜单 -->
          <div class="left flex flex-col sm:flex-row sm:flex-wrap justify-between gap-3xl sm:w-8/12 flex-wrap w-full">
            <template v-for="item in subMenu">
              <div class="sub-menu-item text-left pr-10">
                <div class="pb-4">
                  <text class="text-gray-400 hover:text-gray-300 font-bold text-[16px]">{{ item.title }}</text>
                </div>
                <template v-if="item.children">
                  <div class="sub-menu-children flex flex-col gap-xs">
                    <template v-for="sub in item.children">
                      <a :href="sub.path" class="text-gray-400 hover:text-gray-300">{{ sub.title }}</a>
                    </template>
                  </div>
                </template>
              </div>
            </template>
          </div>

          <!-- 关注我们 -->
          <div class="right w-3/12">
            <el-image src="https://oss.wsdns.cn/20240327/f1175cc5aae741d3af05484747270bd5.jpeg" class="w-[100px]" />
          </div>
        </div>

      <div class="mx-3 sm:hidden p-5 bg-white rounded-xl">
        <el-collapse v-model="activeNames" accordion>
          <template v-for="(item,index) in subMenu">
            <el-collapse-item :title="item.title" :name="index">
              <template v-if="item.children">
                <template v-for="sub in item.children">
                  <a :href="sub.path" class="block cursor-pointer text-gray-600 hover:text-gray-900">{{ sub.title }}</a>
                </template>
              </template>
            </el-collapse-item>
          </template>
        </el-collapse>
      </div>

<!--      <div class="sm:hidden p-4 mt-3">-->
<!--        <el-button type="primary" class="w-full" size="large">联系我们</el-button>-->
<!--      </div>-->

      <!-- 版权信息 -->
      <div class="w-full md:w-3/4 w-full m-auto flex justify-between sm:py-10 pt-6 pb-6 text-center p-2">
        <div class="text-gray-400 gap-xl flex flex-col sm:flex-row m-auto">
          <span>Copyright © {{ new Date().getFullYear() }} {{ config?.copyright }}</span>
          <a class="text-gray-400 hover:text-gray-400" href="https://beian.miit.gov.cn/" target="_blank"> 备案号：{{ config?.icpNo }}</a>
        </div>
      </div>
    </div>
  </footer>
  <el-backtop></el-backtop>
</template>

<script setup lang="ts">
// 请求数据
import {useConfigInfo} from "#imports";
import {useSubMenu, useWebsite} from "~/composables/configState";
import Breadcrumb from "~/components/Breadcrumb.vue";

const config = useConfigInfo();
const website = useWebsite();
const subMenu = useSubMenu();
console.log('---------config---------',config.value)
console.log('---------website---------',website.value)
console.log('---------subMenu---------',subMenu.value)

const activeNames = ref(['1'])

</script>

<style lang="scss">

</style>
