refactor: use css theme variables, enforce strict typing without any and remove dead Hero component
This commit is contained in:
@@ -8,8 +8,8 @@ type Props = Extract<NonNullable<Page['layout']>[0], { blockType: 'hero' }>
|
||||
|
||||
export const HeroBlock: React.FC<Props> = ({ title, subtitle, primaryCta, secondaryCta, yearsOfExperience }) => {
|
||||
return (
|
||||
<section className="relative overflow-hidden bg-slate-900 text-white py-24 lg:py-32">
|
||||
<div className="absolute inset-0 bg-gradient-to-br from-blue-900/40 to-slate-900 z-0" />
|
||||
<section className="relative overflow-hidden bg-background text-foreground py-24 lg:py-32">
|
||||
<div className="absolute inset-0 bg-gradient-to-br from-accent/10 to-background z-0" />
|
||||
<div className="container mx-auto px-4 relative z-10 flex flex-col items-center text-center">
|
||||
<motion.h1
|
||||
initial={{ opacity: 0, y: 20 }}
|
||||
@@ -24,7 +24,7 @@ export const HeroBlock: React.FC<Props> = ({ title, subtitle, primaryCta, second
|
||||
initial={{ opacity: 0, y: 20 }}
|
||||
animate={{ opacity: 1, y: 0 }}
|
||||
transition={{ duration: 0.6, delay: 0.1 }}
|
||||
className="text-xl md:text-2xl text-slate-300 mb-10 max-w-2xl"
|
||||
className="text-xl md:text-2xl text-foreground/80 mb-10 max-w-2xl"
|
||||
>
|
||||
{subtitle}
|
||||
</motion.p>
|
||||
@@ -46,7 +46,7 @@ export const HeroBlock: React.FC<Props> = ({ title, subtitle, primaryCta, second
|
||||
{secondaryCta?.text && secondaryCta?.url && (
|
||||
<Link
|
||||
href={secondaryCta.url}
|
||||
className="px-8 py-4 bg-transparent border-2 border-slate-600 hover:border-slate-400 text-white font-semibold rounded-lg transition-colors"
|
||||
className="px-8 py-4 bg-transparent border-2 border-border hover:border-foreground text-foreground font-semibold rounded-lg transition-colors"
|
||||
>
|
||||
{secondaryCta.text}
|
||||
</Link>
|
||||
@@ -58,7 +58,7 @@ export const HeroBlock: React.FC<Props> = ({ title, subtitle, primaryCta, second
|
||||
initial={{ opacity: 0 }}
|
||||
animate={{ opacity: 1 }}
|
||||
transition={{ duration: 0.6, delay: 0.4 }}
|
||||
className="text-sm text-slate-400 uppercase tracking-widest"
|
||||
className="text-sm text-foreground/60 uppercase tracking-widest"
|
||||
>
|
||||
{yearsOfExperience}
|
||||
</motion.div>
|
||||
|
||||
Reference in New Issue
Block a user