diff --git a/src/assets/wechat_qr.jpg b/src/assets/wechat_qr.jpg index aea450df..32a1dd4e 100644 Binary files a/src/assets/wechat_qr.jpg and b/src/assets/wechat_qr.jpg differ diff --git a/src/components/ui/WordCarousel/WordCarousel.css b/src/components/ui/WordCarousel/WordCarousel.css index 373e81c9..cef47ebb 100644 --- a/src/components/ui/WordCarousel/WordCarousel.css +++ b/src/components/ui/WordCarousel/WordCarousel.css @@ -3,11 +3,13 @@ display: inline-block; background: var(--word-gradient); background-size: 200% 100%; - background-position: 50% 50%; + background-position: 0% 50%; -webkit-background-clip: text; background-clip: text; color: transparent; white-space: nowrap; + animation: gradient-sweep var(--sweep-duration, 2200ms) linear infinite; + will-change: background-position, opacity; } .word-carousel.is-fading { @@ -15,14 +17,26 @@ opacity: 0.35; } -/* Kept for API compatibility; the decorative gradient remains static. */ +/* run once, left-to-right */ .word-carousel.sweep-once { - background-position: 50% 50%; + animation-iteration-count: 1; + animation-fill-mode: forwards; + animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1); +} + +@keyframes gradient-sweep { + 0% { + background-position: 0% 50%; + } + 100% { + background-position: 100% 50%; + } } @media (prefers-reduced-motion: reduce) { .word-carousel, .word-carousel.sweep-once { + animation: none; background-position: 50% 50%; }