'use client'; import { Mail, Phone, MapPin, Globe, Facebook, Twitter, Linkedin, Youtube, ArrowUp, } from 'lucide-react'; import { useState, useEffect } from 'react'; interface FooterProps { currentLang: string; translations: any; } export function Footer({ currentLang, translations }: FooterProps) { const [showScrollTop, setShowScrollTop] = useState(false); const t = translations[currentLang]; // Show scroll to top button when user scrolls down useEffect(() => { const handleScroll = () => { setShowScrollTop(window.scrollY > 300); }; window.addEventListener('scroll', handleScroll); return () => window.removeEventListener('scroll', handleScroll); }, []); const scrollToTop = () => { window.scrollTo({ top: 0, behavior: 'smooth', }); }; const footerLinks = { products: { title: currentLang === 'zh' ? '产品服务' : currentLang === 'zh-tw' ? '產品服務' : 'Products & Services', links: [ { name: currentLang === 'zh' ? '云服务器 ECS' : currentLang === 'zh-tw' ? '雲伺服器 ECS' : 'Cloud Server ECS', href: '/products/ecs', }, { name: currentLang === 'zh' ? '云数据库 RDS' : currentLang === 'zh-tw' ? '雲資料庫 RDS' : 'Cloud Database RDS', href: '/products/rds', }, { name: currentLang === 'zh' ? '负载均衡 SLB' : currentLang === 'zh-tw' ? '負載平衡 SLB' : 'Load Balancer SLB', href: '/products/slb', }, { name: currentLang === 'zh' ? '对象存储 OSS' : currentLang === 'zh-tw' ? '物件儲存 OSS' : 'Object Storage OSS', href: '/products/oss', }, { name: currentLang === 'zh' ? 'CDN 加速' : currentLang === 'zh-tw' ? 'CDN 加速' : 'CDN Acceleration', href: '/products/cdn', }, ], }, solutions: { title: currentLang === 'zh' ? '解决方案' : currentLang === 'zh-tw' ? '解決方案' : 'Solutions', links: [ { name: currentLang === 'zh' ? '企业上云' : currentLang === 'zh-tw' ? '企業上雲' : 'Enterprise Cloud', href: '/solutions/enterprise', }, { name: currentLang === 'zh' ? '数据备份' : currentLang === 'zh-tw' ? '資料備份' : 'Data Backup', href: '/solutions/backup', }, { name: currentLang === 'zh' ? '灾难恢复' : currentLang === 'zh-tw' ? '災難恢復' : 'Disaster Recovery', href: '/solutions/recovery', }, { name: currentLang === 'zh' ? '混合云' : currentLang === 'zh-tw' ? '混合雲' : 'Hybrid Cloud', href: '/solutions/hybrid', }, { name: currentLang === 'zh' ? '容器服务' : currentLang === 'zh-tw' ? '容器服務' : 'Container Service', href: '/solutions/container', }, ], }, support: { title: currentLang === 'zh' ? '支持与服务' : currentLang === 'zh-tw' ? '支援與服務' : 'Support & Service', links: [ { name: currentLang === 'zh' ? '技术文档' : currentLang === 'zh-tw' ? '技術文件' : 'Documentation', href: '/docs', }, { name: currentLang === 'zh' ? '帮助中心' : currentLang === 'zh-tw' ? '幫助中心' : 'Help Center', href: '/help', }, { name: currentLang === 'zh' ? '服务状态' : currentLang === 'zh-tw' ? '服務狀態' : 'Service Status', href: '/status', }, { name: currentLang === 'zh' ? '培训认证' : currentLang === 'zh-tw' ? '培訓認證' : 'Training & Certification', href: '/training', }, { name: currentLang === 'zh' ? '社区论坛' : currentLang === 'zh-tw' ? '社群論壇' : 'Community Forum', href: '/community', }, ], }, company: { title: currentLang === 'zh' ? '关于我们' : currentLang === 'zh-tw' ? '關於我們' : 'About Us', links: [ { name: currentLang === 'zh' ? '公司介绍' : currentLang === 'zh-tw' ? '公司介紹' : 'Company Profile', href: '/about', }, { name: currentLang === 'zh' ? '新闻动态' : currentLang === 'zh-tw' ? '新聞動態' : 'News & Events', href: '/news', }, { name: currentLang === 'zh' ? '招贤纳士' : currentLang === 'zh-tw' ? '招賢納士' : 'Careers', href: '/careers', }, { name: currentLang === 'zh' ? '合作伙伴' : currentLang === 'zh-tw' ? '合作夥伴' : 'Partners', href: '/partners', }, { name: currentLang === 'zh' ? '联系我们' : currentLang === 'zh-tw' ? '聯絡我們' : 'Contact Us', href: '/contact', }, ], }, }; const contactInfo = [ { icon: , label: currentLang === 'zh' ? '客服热线' : currentLang === 'zh-tw' ? '客服熱線' : 'Hotline', value: '+86 400-123-4567', href: 'tel:+864001234567', }, { icon: , label: currentLang === 'zh' ? '邮箱地址' : currentLang === 'zh-tw' ? '郵箱地址' : 'Email', value: 'support@cloudpro.com', href: 'mailto:support@cloudpro.com', }, { icon: , label: currentLang === 'zh' ? '公司地址' : currentLang === 'zh-tw' ? '公司地址' : 'Address', value: currentLang === 'zh' ? '北京市朝阳区科技园区' : currentLang === 'zh-tw' ? '北京市朝陽區科技園區' : 'Beijing Chaoyang Tech Park', href: '#', }, ]; const socialLinks = [ { icon: , href: '#', label: 'Facebook' }, { icon: , href: '#', label: 'Twitter' }, { icon: , href: '#', label: 'LinkedIn' }, { icon: , href: '#', label: 'YouTube' }, ]; return ( ); }