From 6426512192f4f3cbe5e00d581b3d10b6a9219539 Mon Sep 17 00:00:00 2001 From: Marc Mintel Date: Sun, 21 Jun 2026 09:08:44 +0200 Subject: [PATCH] UI: simplify reveal animations to prevent flickering and late triggers --- components/blocks/BenefitGrid.tsx | 2 +- components/blocks/CertificatesBlock.tsx | 4 ++-- components/blocks/CompanyTimeline.tsx | 2 +- components/blocks/CompetenceBentoGrid.tsx | 4 ++-- components/blocks/ContactSection.tsx | 4 ++-- components/blocks/DeepDrillAnimation.tsx | 2 +- components/blocks/GrowthChart.tsx | 6 +++--- components/blocks/JobListingBlock.tsx | 12 ++++++------ components/blocks/ReferencesSlider.tsx | 2 +- components/blocks/ServiceDetailGrid.tsx | 2 +- components/blocks/SubCompanyTiles.tsx | 2 +- components/blocks/SupportCTA.tsx | 2 +- components/blocks/TeamGrid.tsx | 2 +- 13 files changed, 23 insertions(+), 23 deletions(-) diff --git a/components/blocks/BenefitGrid.tsx b/components/blocks/BenefitGrid.tsx index 18c2b4486..de558bd2d 100644 --- a/components/blocks/BenefitGrid.tsx +++ b/components/blocks/BenefitGrid.tsx @@ -30,7 +30,7 @@ const containerVariants: Variants = { }; const itemVariants: Variants = { - hidden: { opacity: 0, y: 40 }, + hidden: { opacity: 0, y: 20 }, visible: { opacity: 1, y: 0, transition: { duration: 1.0, ease: [0.16, 1, 0.3, 1] } }, }; diff --git a/components/blocks/CertificatesBlock.tsx b/components/blocks/CertificatesBlock.tsx index a350a24b8..2b5a30d35 100644 --- a/components/blocks/CertificatesBlock.tsx +++ b/components/blocks/CertificatesBlock.tsx @@ -93,7 +93,7 @@ export function CertificatesBlock({ badge, title, description, certificates = de }; const itemVariants = { - hidden: { opacity: 0, y: 40 }, + hidden: { opacity: 0, y: 20 }, show: { opacity: 1, y: 0, transition: { duration: 1.0, ease: [0.16, 1, 0.3, 1] } }, }; @@ -140,7 +140,7 @@ export function CertificatesBlock({ badge, title, description, certificates = de variants={containerVariants} initial="hidden" whileInView="show" - viewport={{ once: true, amount: 0.1 }} + viewport={{ once: true, margin: "-50px" }} > {certificates.map((cert, index) => { const isIso = cert.type === 'iso'; diff --git a/components/blocks/CompanyTimeline.tsx b/components/blocks/CompanyTimeline.tsx index dab127511..e0dd21951 100644 --- a/components/blocks/CompanyTimeline.tsx +++ b/components/blocks/CompanyTimeline.tsx @@ -116,7 +116,7 @@ export function CompanyTimeline({ return ( = (props) => { variants={containerVariants} initial="hidden" whileInView="visible" - viewport={{ once: true, amount: 0.1 }} + viewport={{ once: true, margin: "-50px" }} > Direktkontakt Wir sind für Sie da. @@ -104,7 +104,7 @@ export const ContactSection: React.FC = (props) => { variants={formVariants} initial="hidden" whileInView="visible" - viewport={{ once: true, amount: 0.1 }} + viewport={{ once: true, margin: "-50px" }} > diff --git a/components/blocks/GrowthChart.tsx b/components/blocks/GrowthChart.tsx index aa372ae91..2fbc90e70 100644 --- a/components/blocks/GrowthChart.tsx +++ b/components/blocks/GrowthChart.tsx @@ -45,7 +45,7 @@ export function GrowthChart() { @@ -61,7 +61,7 @@ export function GrowthChart() { @@ -77,7 +77,7 @@ export function GrowthChart() { diff --git a/components/blocks/JobListingBlock.tsx b/components/blocks/JobListingBlock.tsx index cf5a4359e..8a4993da8 100644 --- a/components/blocks/JobListingBlock.tsx +++ b/components/blocks/JobListingBlock.tsx @@ -37,7 +37,7 @@ const containerVariants = { }; const itemVariants = { - hidden: { opacity: 0, y: 40 }, + hidden: { opacity: 0, y: 20 }, visible: { opacity: 1, y: 0, @@ -75,7 +75,7 @@ export const JobListingBlock = (props: JobListingBlockProps) => { @@ -86,7 +86,7 @@ export const JobListingBlock = (props: JobListingBlockProps) => { variants={containerVariants} initial="hidden" whileInView="visible" - viewport={{ once: true, amount: 0.1 }} + viewport={{ once: true, margin: "-50px" }} className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8" > {fairs.map((messe, idx) => { @@ -180,7 +180,7 @@ export const JobListingBlock = (props: JobListingBlockProps) => { @@ -192,7 +192,7 @@ export const JobListingBlock = (props: JobListingBlockProps) => { variants={containerVariants} initial="hidden" whileInView="visible" - viewport={{ once: true, amount: 0.1 }} + viewport={{ once: true, margin: "-50px" }} className="grid gap-6" > {jobs.map((job: any) => ( @@ -221,7 +221,7 @@ export const JobListingBlock = (props: JobListingBlockProps) => { diff --git a/components/blocks/ReferencesSlider.tsx b/components/blocks/ReferencesSlider.tsx index b0c52693a..c394272d9 100644 --- a/components/blocks/ReferencesSlider.tsx +++ b/components/blocks/ReferencesSlider.tsx @@ -125,7 +125,7 @@ export function ReferencesSlider(props: ReferencesSliderProps) { return ( {companiesData.map((company: any, index: number) => { const isCurrent = company.title.toUpperCase() === 'E-TIB GMBH'; diff --git a/components/blocks/SupportCTA.tsx b/components/blocks/SupportCTA.tsx index f1d59084f..60d52b536 100644 --- a/components/blocks/SupportCTA.tsx +++ b/components/blocks/SupportCTA.tsx @@ -43,7 +43,7 @@ export const SupportCTA: React.FC = (props) => { variants={containerVariants} initial="hidden" whileInView="visible" - viewport={{ once: true, margin: "-100px" }} + viewport={{ once: true, margin: "-50px" }} className="mt-12 md:mt-24 p-6 md:p-12 bg-primary-dark rounded-3xl text-white shadow-2xl relative overflow-hidden group" >
diff --git a/components/blocks/TeamGrid.tsx b/components/blocks/TeamGrid.tsx index 1a0eecb33..d9f2dc1f6 100644 --- a/components/blocks/TeamGrid.tsx +++ b/components/blocks/TeamGrid.tsx @@ -42,7 +42,7 @@ export function TeamGrid({ members }: TeamGridProps) { {members.map((member, i) => (