Files
Cloud-Home/app/components/SkillsSection.vue
RhenCloud ba95a16f21 refactor:删除已弃用的组件和样式,迁移到 Tailwind CSS
- 改进项目页面、网站页面、友链页面
- 从 styles.css 中移除全局样式。
- 添加 tailwind.config.ts 以配置 Tailwind CSS。
- 更新 tsconfig.json,加入 Vue 组件的新路径映射。
2025-12-15 23:38:44 +08:00

29 lines
1.5 KiB
Vue

<template>
<section class="card flex flex-col gap-2.5">
<div>
<h2 class="m-0 mb-1">技能专长</h2>
<p class="text-text-muted text-sm m-0 mb-3">我常用的工具与技术 · Skills & Technologies</p>
</div>
<div class="grid grid-cols-1 sm:grid-cols-2 gap-3">
<article v-for="group in skills" :key="group.title"
class="bg-gradient-to-br from-white/5 to-white/2 border border-white/10 rounded-2xl p-3.5 shadow-md-dark transition-all duration-300 hover:-translate-y-1 hover:border-primary/50 hover:shadow-lg-dark hover:bg-gradient-to-br hover:from-primary/8">
<header class="mb-3">
<h3 class="text-base font-semibold m-0">{{ group.title }}</h3>
</header>
<div class="flex flex-wrap gap-2">
<span v-for="item in group.items" :key="item"
class="inline-flex items-center p-1.5 rounded-2xl bg-primary/14 border border-primary/18 transition-all duration-200 hover:bg-primary/24 hover:border-primary/40 hover:scale-110">
<img :src="iconSrc(item)" :alt="item" :title="item" loading="lazy"
class="w-7 h-7 rounded-2xl" />
</span>
</div>
</article>
</div>
</section>
</template>
<script setup>
defineProps({ skills: { type: Array, default: () => [] } });
const iconSrc = (id) => `https://skillicons.dev/icons?i=${encodeURIComponent(id)}&theme=dark`;
</script>