1.1 KiB
1.1 KiB
Rolling Rainbow Foil Effect
Objective
Implement a "milder but more colorful" foil effect with a "rolling rainbow" animation and a mild white overlay, consistent across mobile and desktop.
Changes
- CSS Animation: Added
@keyframes bg-rolland.animate-bg-rollutility inmain.cssto create a continuous background position scrolling effect. - Enhanced Foil Overlay: Updated
FoilOverlayinCardPreview.tsx:- Layer 1 (Rolling Rainbow): Uses a wide
gradient-to-rspanning red -> blue -> red (200% width). It usesanimate-bg-rollto scroll horizontally, simulating the color shifting of a foil card as it moves. - Layer 2 (Light Glint): Retained a subtle diagonal
white/30pulse (mix-blend-overlay) for dynamic lighting. - Layer 3 (White Sheen): Added a static
white/10overlay (mix-blend-soft-light) to provide the requested "mild white overlay" for a glossy finish.
- Layer 1 (Rolling Rainbow): Uses a wide
- Lint Fix: Cast
card.finishto string to resolve TypeScript type overlap errors.
Result
Foil cards now exhibit a smooth, colorful, rolling rainbow reflection that looks premium and dynamic without being overly chaotic.