Files
yphsalumni.org/app/layouts/default.vue
xiaomai c468da8780 feat(about): add page for 1956 middle highschool tuition class
This commit introduces a new page dedicated to the 'Middle Highschool Tuition Class' of 1956 (中补班). The page displays a letter written in 2022, calling for a reunion of these special alumni. A navigation
link has been added to the 'About' section for easy access to this historical content.
2025-10-27 22:18:07 +08:00

202 lines
4.7 KiB
Vue
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<template>
<UPage>
<UBanner
title="永中校友会 40 周年庆典活动火热筹募中!"
icon="hugeicons:party"
close
:actions="bannerActions"
/>
<UHeader>
<template #left>
<NuxtLink to="/">
<div class="flex gap-4 items-center">
<img class="inline h-12 w-auto" src="/Logo.svg" alt="YPHS Alumni" />
<h1
class="text-xl font-bold text-gray-900 hover:text-primary hidden md:inline"
>
永平中学校友会
</h1>
</div>
</NuxtLink>
</template>
<template #default>
<UNavigationMenu :items="items" content-orientation="vertical" />
</template>
<template #right>
<UColorModeButton />
<UButton
v-for="link in socialLinks"
color="neutral"
variant="ghost"
v-bind="link"
/>
<UButton
icon="line-md:account-add"
to="/join-us"
color="primary"
variant="solid"
label="加入"
/>
</template>
<template #body>
<UNavigationMenu
:items="items"
orientation="vertical"
class="-mx-2.5"
/>
</template>
</UHeader>
<UMain>
<Transition name="page" mode="out-in">
<NuxtPage />
</Transition>
</UMain>
<UFooter>
<template #left>
<p>© 2025 永平中学校友会. 保留所有权利.</p>
</template>
<template #default>
<p class="mt-1">
Powered by:
<a
href="https://tootaio.com"
target="_blank"
class="font-semibold hover:underline"
style="color: #e24545"
>
Tootaio Studio
</a>
<span class="mt-1 text-sm">2018 级毕业学长麦祖奕</span>
</p>
</template>
<template #right>
<UButton
v-for="link in socialLinks"
color="neutral"
variant="ghost"
v-bind="link"
/>
</template>
</UFooter>
</UPage>
</template>
<script setup lang="ts">
import type { NavigationMenuItem, ButtonProps } from "@nuxt/ui";
const route = useRoute();
const bannerActions = ref<ButtonProps[]>([
{
label: "查看策划书",
variant: "outline",
icon: "lucide:arrow-right",
to: "/40th-anniversary/proposal",
},
]);
const items = computed<NavigationMenuItem[]>(() => [
{ label: "首页", to: "/" },
{ label: "新闻", to: "/news", active: route.path.startsWith("/news") },
{
label: "活动",
to: "/events",
active: route.path.startsWith("/events"),
children: [
{
label: "40 周年庆",
to: "/40th-anniversary",
active: route.path.startsWith("/40th-anniversary"),
badge: {
label: "Hot",
color: "error",
},
},
],
},
{
label: "关于校友会",
to: "/about",
active: route.path.startsWith("/about"),
children: [
{
label: "创会简史",
to: "/about/founded-history",
active: route.path.startsWith("/about/founded-history"),
icon: "mdi:history",
},
{
label: "特殊校友:中补班",
description: "永平中学补习班1956年一封迟来的贴文",
to: "/about/middle-highschool-tuition-class",
active: route.path.startsWith("/about/middle-highschool-tuition-class"),
icon: "mdi:mail"
}
],
},
{
label: "友情链接",
children: [
{
label: "永平中学官网",
icon: "mdi:book-education",
to: "https://yphs.edu.my/",
target: "_blank",
},
{
label: "桃李教育网",
icon: "mdi:web",
to: "https://efuxi.vtour.my/",
target: "_blank",
},
{
label: "董总 Dong Zong",
icon: "mdi:web",
to: "https://www.dongzong.my/",
target: "_blank",
},
{
label: "永中校友网 - 旧站",
icon: "mdi:web-clock",
to: "https://vtour.my/yphsalumni/",
target: "_blank",
},
],
},
// { label: "捐赠", to: "#donate", active: route.path.startsWith("#donate") },
// { label: "关于", to: "#about", active: route.path.startsWith("#about") },
]);
const socialLinks = ref<ButtonProps[]>([
{
icon: "line-md:tiktok",
to: "https://www.tiktok.com/@yphs.alumni",
target: "_blank",
},
{
icon: "line-md:facebook",
to: "https://www.facebook.com/YPHS.Alumni/",
target: "_blank",
},
]);
</script>
<style lang="css" scoped>
.page-enter-active,
.page-leave-active {
transition: all 0.4s;
}
.page-enter-from,
.page-leave-to {
opacity: 0;
filter: blur(1rem);
}
</style>