<template>
  <div class="md:w-screen-xl m-auto relative sm:flex">
    <el-row :gutter="24" class="flex">
      <template v-for="(item,index) in list" :key="index">
        <el-col :span="6" class="mb-5 min-w-xs">
          <el-card shadow="hover" :body-style="{ padding: '0px' }">
            <el-image src="https://nuxt.com/_vercel/image?url=%2Fassets%2Ftemplates%2Fwoonuxt.png&w=640&q=100"
                      class="w-full cursor-pointer" @click="navigateTo(`/product/website`)" />
            <div class="flex-1 px-4 py-5 sm:p-6 !p-4">
              <p class="text-gray-900 dark:text-white text-base font-semibold truncate flex items-center gap-1.5">
                <a class="flex-1 truncate cursor-pointer" @click="navigateTo(`/product/website`)">模版名称</a>
              </p>
              <div class="text-[15px] text-gray-500 dark:text-gray-400 mt-1 line-clamp-2 sm:min-h-[45px]">
                使用Nuxt、Vue 构建的web模版。
              </div>
              <div class="button-group flex justify-center">
                  <el-button class="w-full" :icon="ElIconView">演示</el-button>
                  <el-button  class="w-full" :icon="ElIconShoppingCart">购买</el-button>
              </div>
            </div>
          </el-card>
        </el-col>
      </template>
    </el-row>

  </div>
</template>

<script setup lang="ts">
import {useConfigInfo} from "~/composables/configState";
import {openSpmUrl} from "~/utils/common";

const token = useToken();
const sysDomain = useSysDomain();

withDefaults(
    defineProps<{
      layout?: any;
      list?: any[];
    }>(),
    {}
);

const config = useConfigInfo();

</script>
