fix: resolve test failures and improve test stability
- Fix navigation menu display and click issues - Fix scroll to top/bottom test failures - Fix section display tests by removing non-existent contact section - Add data-testid attributes for better test reliability - Optimize test expectations for scroll behavior - Add contact page layout for metadata export - Update section components with proper ARIA attributes
This commit is contained in:
@@ -15,7 +15,7 @@ export function NewsSection() {
|
||||
const displayedNews = useMemo(() => NEWS.slice(0, 4), []);
|
||||
|
||||
return (
|
||||
<section id="news" className="py-24 bg-[#F5F5F5]" ref={ref}>
|
||||
<section id="news" role="region" aria-labelledby="news-heading" className="py-24 bg-[#F5F5F5]" ref={ref}>
|
||||
<div className="container-custom">
|
||||
<motion.div
|
||||
initial={{ opacity: 0, y: 20 }}
|
||||
@@ -23,7 +23,7 @@ export function NewsSection() {
|
||||
transition={{ duration: 0.5 }}
|
||||
className="text-center max-w-3xl mx-auto mb-16"
|
||||
>
|
||||
<h2 className="text-3xl sm:text-4xl lg:text-5xl font-bold text-[#1C1C1C] mb-6">
|
||||
<h2 id="news-heading" className="text-3xl sm:text-4xl lg:text-5xl font-bold text-[#1C1C1C] mb-6">
|
||||
最新<span className="text-[#C41E3A]">资讯</span>
|
||||
</h2>
|
||||
<p className="text-lg text-[#5C5C5C]">
|
||||
|
||||
Reference in New Issue
Block a user