refactor(home): move page content into per-language YAML sections
All visible text, lists, image refs, and CTAs for the home page now live in en/index.md and es/index.md as a typed `sections:` frontmatter array. HomePage.astro is reduced to a thin router; each section type is rendered by a dedicated component in src/components/home/. Adds .no-balance utility class to suppress text-wrap: balance on the commitments heading. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
---
|
||||
import type { ServicesIntroSection } from '../../types/home-sections';
|
||||
interface Props { section: ServicesIntroSection }
|
||||
const { section } = Astro.props;
|
||||
---
|
||||
<section class="section services-intro">
|
||||
<div class="container services-grid">
|
||||
<div class="feature-grid feature-grid--intro">
|
||||
<img class="gear-photo" src={`/assets/images/${section.servicesImage}`} alt={section.servicesImageAlt} />
|
||||
<div>
|
||||
<h2>{section.servicesHeading}</h2>
|
||||
<ul class="source-list">{section.services.map((item) => <li>{item}</li>)}</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="feature-grid feature-grid--intro feature-grid--reverse">
|
||||
<div>
|
||||
<h2 class="no-balance">{section.commitmentsHeading}</h2>
|
||||
<ul class="source-list two-column-list">{section.commitments.map((item) => <li>{item}</li>)}</ul>
|
||||
<a class="button" href={section.commitmentsCta.href}>{section.commitmentsCta.label}</a>
|
||||
</div>
|
||||
<img class="gear-photo gear-photo-right" src={`/assets/images/${section.commitmentsImage}`} alt={section.commitmentsImageAlt} />
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
Reference in New Issue
Block a user