diff --git a/.gitignore b/.gitignore index 99b3c47..3f14eb5 100644 --- a/.gitignore +++ b/.gitignore @@ -23,4 +23,6 @@ logs .env.* !.env.example -repomix-output.xml \ No newline at end of file +repomix-output.xml + +content/members/members.csv \ No newline at end of file diff --git a/app/layouts/default.vue b/app/layouts/default.vue index 3f83856..b063a53 100644 --- a/app/layouts/default.vue +++ b/app/layouts/default.vue @@ -105,6 +105,11 @@ const bannerActions = ref([ const items = computed(() => [ { label: "首页", to: "/" }, { label: "新闻", to: "/news", active: route.path.startsWith("/news") }, + { + label: "会员", + to: "/members", + active: route.path.startsWith("/members"), + }, { label: "活动", to: "/events", @@ -122,7 +127,7 @@ const items = computed(() => [ ], }, { - label: "关于校友会", + label: "关于", to: "/about", active: route.path.startsWith("/about"), children: [ @@ -143,12 +148,12 @@ const items = computed(() => [ description: "永平中学补习班(1956年):一封迟来的贴文", to: "/about/middle-highschool-tuition-class", active: route.path.startsWith("/about/middle-highschool-tuition-class"), - icon: "mdi:mail" - } + icon: "mdi:mail", + }, ], }, { - label: "友情链接", + label: "链接", children: [ { label: "永平中学官网", diff --git a/app/pages/about/org-structure/[slug].vue b/app/pages/about/org-structure/[slug].vue index 29557e8..12b10cc 100644 --- a/app/pages/about/org-structure/[slug].vue +++ b/app/pages/about/org-structure/[slug].vue @@ -58,6 +58,7 @@ const generation = route.params.slug; const categories = ref(["领导团队", "职能部门", "专项部门"]); +// TODO: Fetch from api const orgStructure = ref([ { name: "李煜斌", @@ -132,14 +133,14 @@ const orgStructure = ref([ }, { name: "胡少菲", - position: "总务", + position: "康乐", category: "职能部门", photo: "/org-structure/胡少菲.png", description: "文化活动策划、康乐项目组织与会员联谊活动。", }, { name: "林剑宝", - position: "副总务", + position: "副康乐", category: "职能部门", photo: "/org-structure/林剑宝.png", description: "协助文康组织文体活动、兴趣小组与社交聚会。", diff --git a/app/pages/index.vue b/app/pages/index.vue index 61e9005..36eef2b 100644 --- a/app/pages/index.vue +++ b/app/pages/index.vue @@ -5,6 +5,8 @@ class="bg-cover bg-center" style=" background-image: url("/hero-image.jpg"); + background-position-y: -40px; + background-repeat: no-repeat; background-color: rgba(255, 255, 255, 0.5); /* Semi-transparent black */ background-blend-mode: lighten; " diff --git a/app/pages/members/index.vue b/app/pages/members/index.vue new file mode 100644 index 0000000..0aaa2a5 --- /dev/null +++ b/app/pages/members/index.vue @@ -0,0 +1,111 @@ + + + + + diff --git a/content.config.ts b/content.config.ts index 10a275f..13d66d7 100644 --- a/content.config.ts +++ b/content.config.ts @@ -36,7 +36,7 @@ export default defineContentConfig({ // 名人堂 hallOfFames: defineCollection({ type: "page", - source: "hall-of-fames/*md", + source: "hall-of-fames/*.md", schema: z.object({ name: z.string(), photo: z.string().url(), @@ -45,5 +45,27 @@ export default defineContentConfig({ gallery: z.array(z.string()), }), }), + // 会员名册 + members: defineCollection({ + type: "data", + source: "members/members.csv", + schema: z.object({ + // chinese_name: z.string(), + // english_name: z.string(), + // ic: z.string(), + // mobile: z.string(), + // home: z.string(), + // email: z.string(), + // graduate_level: z.string(), + // graduate_year: z.string(), + // marriage_status: z.string(), + // living_country: z.string(), + // address_line_1: z.string(), + // address_line_2: z.string(), + // address_line_3: z.string(), + // joined_year: z.string(), + // receipt_number: z.string(), + }), + }), }, }); diff --git a/content/members/members-sample.csv b/content/members/members-sample.csv new file mode 100644 index 0000000..ad169da --- /dev/null +++ b/content/members/members-sample.csv @@ -0,0 +1 @@ +chineseName,englishName,ic,mobile,home,email,graduateLevel,,graduateYear,marriageStatus,livingCountry,addressLine1,addressLine2,addressLine3,joinedYear,receiptNumber diff --git a/public/hero-image-2.jpg b/public/hero-image-2.jpg new file mode 100644 index 0000000..e77c678 Binary files /dev/null and b/public/hero-image-2.jpg differ diff --git a/public/hero-image.jpg b/public/hero-image.jpg index e77c678..e6b5096 100644 Binary files a/public/hero-image.jpg and b/public/hero-image.jpg differ