Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 32 additions & 3 deletions app/components/Footer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@

import { motion } from "framer-motion";
import { useTranslation } from "react-i18next";
import { GITHUB_URLS, QQ_GROUPS } from "../constants";
import Image from "next/image";
import { FRIEND_LINKS, GITHUB_URLS, QQ_GROUPS } from "../constants";

export default function Footer() {
const { t } = useTranslation();
Expand Down Expand Up @@ -34,8 +35,8 @@ export default function Footer() {
</motion.div>
</div>

<div className="container mx-auto grid grid-cols-1 gap-12 px-6 md:grid-cols-4">
<div className="col-span-2">
<div className="container mx-auto grid grid-cols-1 gap-12 px-6 md:grid-cols-6">
<div className="col-span-1 md:col-span-2">
<h3 className="font-heading mb-4 text-2xl text-black dark:text-white">
MaaEnd
</h3>
Expand Down Expand Up @@ -101,6 +102,34 @@ export default function Footer() {
</li>
</ul>
</div>
<div className="col-span-1 md:col-span-2">
<h4 className="mb-4 font-mono text-black dark:text-white">
{t("footer.friendLinks")}
</h4>
<ul className="flex flex-wrap gap-x-4 gap-y-2 text-sm text-black/80 dark:text-white/70">
{FRIEND_LINKS.map((friend) => (
<li key={friend.id} className="w-40">
<a
href={friend.href}
target="_blank"
rel="noopener noreferrer"
className="group flex items-center gap-2 transition-colors hover:text-[#c49102] dark:hover:text-[#FFE600]"
>
<span className="rounded-sm border border-black/10 bg-white/90 p-1.5 dark:border-white/15 dark:bg-white/10">
<Image
src={friend.iconSrc}
alt={friend.iconAlt}
width={24}
height={24}
className="h-6 w-6 object-contain"
/>
</span>
<span className="min-w-0 truncate">{friend.name}</span>
</a>
</li>
))}
</ul>
</div>
</div>

<div className="mt-20 text-center font-mono text-xs text-black/30 dark:text-white/20">
Expand Down
54 changes: 54 additions & 0 deletions app/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,57 @@ export const QQ_GROUPS = {
DEV_GROUP: "1072587329",
DEV_GROUP_LINK: "https://qm.qq.com/q/EyirQpBiW4",
} as const;

export interface FriendLink {
id: string;
name: string;
href: string;
iconSrc: string;
iconAlt: string;
}

// 友情链接:图标来自 public/friend
export const FRIEND_LINKS: FriendLink[] = [
{
id: "MAA",
name: "MAA",
href: "https://maa.plus/",
iconSrc: "/friend/maa.png",
iconAlt: "MAA",
},
{
id: "MaaFramework",
name: "MaaFramework",
href: "https://maafw.com/",
iconSrc: "/friend/maa.png",
iconAlt: "MAA",
},
{
id: "ef-yituliu",
name: "终末地一图流",
href: "https://www.yituliu.cn/",
iconSrc: "/friend/ef-yituliu.png",
iconAlt: "终末地一图流",
},
{
id: "mirrorchyan",
name: "Mirror酱",
href: "https://mirrorchyan.com/zh/projects?rid=MaaEnd&os=windows&arch=x64&channel=stable",
iconSrc: "/friend/mirrorchyan.png",
iconAlt: "Mirror酱",
},
{
id: "endfield-terminal",
name: "终末地-协议终端",
href: "https://end.shallow.ink",
iconSrc: "https://end.shallow.ink/icon.svg",
iconAlt: "终末地-协议终端",
},
{
id: "zmd-map",
name: "终末地地图站",
href: "https://www.zmdmap.com/",
iconSrc: "https://assets.zmdmap.com/logo.png",
iconAlt: "终末地地图站",
},
];
1 change: 1 addition & 0 deletions locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@
"userGroup": "User QQ Group",
"devGroup": "Dev QQ Group",
"project": "PROJECT",
"friendLinks": "Friendly Links",
"github": "GitHub",
"releases": "Releases",
"issues": "Issues",
Expand Down
1 change: 1 addition & 0 deletions locales/zh.json
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@
"userGroup": "用户 QQ 群",
"devGroup": "开发 QQ 群",
"project": "PROJECT",
"friendLinks": "友情链接",
"github": "源码",
"releases": "发行版",
"issues": "问题反馈",
Expand Down
12 changes: 11 additions & 1 deletion next.config.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,19 @@
import type { NextConfig } from "next";

const nextConfig: NextConfig = {
output: 'export',
output: "export",
images: {
unoptimized: true,
remotePatterns: [
{
protocol: "https",
hostname: "end.shallow.ink",
},
{
protocol: "https",
hostname: "assets.zmdmap.com",
},
],
},
trailingSlash: true,
};
Expand Down
Binary file added public/friend/ef-yituliu.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/friend/maa.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/friend/mirrorchyan.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading