mirror of
https://github.com/Such-Software/such.software.git
synced 2026-12-03 12:13:59 +01:00
Splash logo: drop framer wrapper + CSS filter (cleaner LCP); nudge tracer
- Logo is a plain <img fetchPriority=high> in a plain div (no framer-motion, no drop-shadow filter) so it is a clean, statically-painted LCP candidate. Water filter + a CSS zoom apply only on enter. - Tracer target nudged to computerX/Y +1.5 (between the low-right +2.5 and the high-left +0.5).
This commit is contained in:
@@ -227,4 +227,9 @@
|
|||||||
transition-duration: 0.01ms !important;
|
transition-duration: 0.01ms !important;
|
||||||
scroll-behavior: auto !important;
|
scroll-behavior: auto !important;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Splash logo zoom on click-to-enter (CSS, so the logo needs no framer-motion
|
||||||
|
wrapper and stays a clean LCP candidate). */
|
||||||
|
@keyframes splash-zoom { 0% { transform: scale(1); } 50% { transform: scale(1.06); } 100% { transform: scale(1.14); } }
|
||||||
|
.splash-zoom { animation: splash-zoom 0.8s ease-in-out forwards; }
|
||||||
@@ -104,18 +104,19 @@ export function HeroSplash({ onEnter, sectionRef, leaving }: { onEnter: () => vo
|
|||||||
className="pointer-events-none absolute h-[120%] w-[120%] rounded-full bg-[radial-gradient(circle,rgba(34,211,238,0.2),transparent_65%)] motion-safe:animate-pulse"
|
className="pointer-events-none absolute h-[120%] w-[120%] rounded-full bg-[radial-gradient(circle,rgba(34,211,238,0.2),transparent_65%)] motion-safe:animate-pulse"
|
||||||
style={{ animationDuration: "4.5s" }}
|
style={{ animationDuration: "4.5s" }}
|
||||||
/>
|
/>
|
||||||
<motion.div
|
{/* Plain div, no framer: keeps the logo (the LCP element) a clean,
|
||||||
|
statically-painted image. The water filter + zoom only apply on enter. */}
|
||||||
|
<div
|
||||||
|
className={entering ? "splash-zoom" : undefined}
|
||||||
style={{ filter: entering ? "url(#splash-water)" : undefined }}
|
style={{ filter: entering ? "url(#splash-water)" : undefined }}
|
||||||
initial={{ opacity: 1, scale: 1 }}
|
|
||||||
animate={entering ? { scale: [1, 1.06, 1.14] } : undefined}
|
|
||||||
transition={entering ? { duration: 0.8, ease: "easeInOut" } : undefined}
|
|
||||||
>
|
>
|
||||||
<img
|
<img
|
||||||
src="/images/branding/splash-such.svg"
|
src="/images/branding/splash-such.svg"
|
||||||
alt="Such Software"
|
alt="Such Software"
|
||||||
className="h-auto w-[min(72vw,42vh)] drop-shadow-[0_0_40px_rgba(34,211,238,0.25)]"
|
fetchPriority="high"
|
||||||
|
className="h-auto w-[min(72vw,42vh)]"
|
||||||
/>
|
/>
|
||||||
</motion.div>
|
</div>
|
||||||
</button>
|
</button>
|
||||||
|
|
||||||
{/* Cover text hidden on mobile (logo + corner icons carry it there); fades out on enter */}
|
{/* Cover text hidden on mobile (logo + corner icons carry it there); fades out on enter */}
|
||||||
|
|||||||
@@ -95,8 +95,8 @@ export const NebulaField = ({ className, density = 8, themeMode = 'dark', positi
|
|||||||
// Aim the streamers at the monitor's screen. +2.5 hit low-and-right; -1/-1.5 hit
|
// Aim the streamers at the monitor's screen. +2.5 hit low-and-right; -1/-1.5 hit
|
||||||
// high-and-left, so this is the midpoint. Tweak these two offsets to move the
|
// high-and-left, so this is the midpoint. Tweak these two offsets to move the
|
||||||
// convergence point.
|
// convergence point.
|
||||||
const targetX = computerX + 0.5;
|
const targetX = computerX + 1.5;
|
||||||
const targetY = computerY + 0.5;
|
const targetY = computerY + 1.5;
|
||||||
|
|
||||||
// Check for reduced motion preference
|
// Check for reduced motion preference
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
|
|||||||
Reference in New Issue
Block a user