feat(website): 三轮视觉改造与页面过渡动画
改造概要(30项): - 第一轮:Hero重构/Section差异化/SocialProof强化/CTA对比度/About架构 - 第二轮:字体优化/背景交替/Solutions差异化/Footer五列/MegaDropdown修复 - 第三轮:卡片交互/表单层级/CTA统一/时间线标记/连接线/三列布局/移动导航/Button微交互/SEO Schema - P3-2:template.tsx+Framer Motion页面过渡/loading.tsx加载状态 - 清理:删除未用组件/hooks,修复重复移动导航,清理冗余CSS
This commit is contained in:
@@ -36,29 +36,29 @@ export function Toast({
|
||||
};
|
||||
|
||||
const bgColors = {
|
||||
success: 'bg-green-50 border-green-200',
|
||||
error: 'bg-red-50 border-red-200',
|
||||
info: 'bg-blue-50 border-blue-200'
|
||||
success: 'bg-[var(--color-toast-success-bg)] border-[var(--color-toast-success-border)]',
|
||||
error: 'bg-[var(--color-toast-error-bg)] border-[var(--color-toast-error-border)]',
|
||||
info: 'bg-[var(--color-toast-info-bg)] border-[var(--color-toast-info-border)]'
|
||||
};
|
||||
|
||||
return (
|
||||
<div
|
||||
data-testid={dataTestId}
|
||||
data-type={type}
|
||||
className={`fixed bottom-4 right-4 z-50 flex items-center gap-3 px-4 py-3 bg-white rounded-lg shadow-lg border transition-all duration-300 ${
|
||||
className={`fixed bottom-4 right-4 z-50 flex items-center gap-3 px-4 py-3 bg-[var(--color-bg-primary)] rounded-lg shadow-lg border transition-all duration-300 ${
|
||||
isVisible ? 'opacity-100 translate-y-0' : 'opacity-0 translate-y-2'
|
||||
} ${bgColors[type]}`}
|
||||
role="alert"
|
||||
aria-live="polite"
|
||||
>
|
||||
{icons[type]}
|
||||
<p className="text-sm font-medium text-[#1C1C1C]">{message}</p>
|
||||
<p className="text-sm font-medium text-[var(--color-text-primary)]">{message}</p>
|
||||
<button
|
||||
onClick={() => {
|
||||
setIsVisible(false);
|
||||
setTimeout(onClose, 300);
|
||||
}}
|
||||
className="ml-2 text-gray-400 hover:text-gray-600 transition-colors"
|
||||
className="ml-2 text-[var(--color-toast-close)] hover:text-[var(--color-toast-close-hover)] transition-colors"
|
||||
aria-label="关闭提示"
|
||||
>
|
||||
<X className="h-4 w-4" />
|
||||
|
||||
Reference in New Issue
Block a user