From 03fdf3f9bc36c4b8c8304b0711b9984f2e386fc6 Mon Sep 17 00:00:00 2001 From: aken1023 Date: Fri, 1 Aug 2025 12:47:59 +0800 Subject: [PATCH] Add IP address display component to navigation Introduced a new IpDisplay component that fetches and shows the user's IP address using the ipify API. Integrated the component into both desktop and mobile navigation areas, with a simplified display for mobile devices. --- app/page.tsx | 11 ++++++++ components/ip-display.tsx | 57 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 68 insertions(+) create mode 100644 components/ip-display.tsx diff --git a/app/page.tsx b/app/page.tsx index cc6d98b..f92cb67 100644 --- a/app/page.tsx +++ b/app/page.tsx @@ -5,6 +5,7 @@ import Link from "next/link" import { Button } from "@/components/ui/button" import { Sparkles, MessageCircle, Users, BarChart3 } from "lucide-react" import HeaderMusicControl from "@/components/header-music-control" +import IpDisplay from "@/components/ip-display" interface Star { id: number; @@ -88,6 +89,11 @@ export default function HomePage() { {/* 導航區域 */}