Homepages
Files: src/pages/[...lang]/index.astro, home-corporate.astro, home-family.astro, src/content/homepage/<language>/ · Skill level: Beginner to edit text, light code to reorder or swap
Covena has three homepages, each written for a different kind of firm, and each with its own header and footer. Use the one closest to your practice as your homepage, and keep, change, or delete the others.
| Homepage | URL | Route file | Content file | Header, footer |
|---|---|---|---|---|
| General practice (Home 1) | / | src/pages/[...lang]/index.astro | src/content/homepage/english/-index.md | panel over the hero, marquee |
| Corporate (Home 2) | /home-corporate/ | src/pages/[...lang]/home-corporate.astro | src/content/homepage/english/home-corporate.md | bar, columns-light |
| Family and private client (Home 3) | /home-family/ | src/pages/[...lang]/home-family.astro | src/content/homepage/english/home-family.md | transparent with quick exit, offices |
The French and Arabic content files are in french/ and arabic/ next to english/, with the same names. The route files are shared by all languages.
How A Homepage Is Built
The route file lists the sections in the order they appear, and sets the header and footer. The content file holds the page title and meta description, and any change you make to a section on this page only. Each section’s default text and images are in src/content/sections/<language>/, one file per section.
So there are two ways to change a section’s text:
- Edit its file in
src/content/sections/<language>/. This changes it on every page that uses it. - Add a block with the section’s name to the homepage content file. This changes it on this homepage only.
The comment at the top of each homepage content file lists its block names. For example, to change the Home 1 hero title on Home 1 only:
heroPortraitNavy: title: "Plain legal advice for <em>you</em>"Fields you leave out keep the default, and enable: false hides the section on this page. Sections has all the rules.
Home 1: General Practice

Sections, top to bottom, with their block name and section file:
- Hero with a portrait on a bronze panel:
heroPortraitNavy(hero-portrait-navy.md) - Three short facts about the firm:
featuresTrio(features-trio.md) - About with a photo collage:
aboutCollage(about-collage.md) - Practice areas grid on navy:
practiceGridNavy(practice-grid-navy.md) - Why clients choose us, an accordion beside a photo:
whyUsAccordionPanel(why-us-accordion-panel.md) - How we work, three steps on photo cards:
processPhotoCards(process-photo-cards.md) - Client reviews slider:
testimonialSlider(testimonial-slider.md) - Latest insights on a bronze panel:
insightsBronzePanel(insights-bronze-panel.md) - Contact form with the firm’s phone and email:
contactSplitForm(contact-split-form.md)
Home 1 also turns on the footer reveal (footerReveal: true in its content file).
Home 2: Corporate

- Hero with a framed photo and a figures card:
heroFramedLight(hero-framed-light.md) - Client logos:
logosRow(logos-row.md) - A one-paragraph statement:
aboutStatement(about-statement.md) - Practice areas as rows:
practiceRows(practice-rows.md) - Industries as scrolling cards:
industriesMarqueeCards(industries-marquee-cards.md) - Figures with portraits:
statsPortraitsBand(stats-portraits-band.md) - Lawyers carousel:
teamCarousel(team-carousel.md) - Results as stacked cards, with the past-results disclaimer:
resultsCards(results-cards.md) - A featured insight and a list:
insightsFeaturedList(insights-featured-list.md) - Navy call to action band:
ctaBandNavy(cta-band-navy.md)
Home 3: Family And Private Client

- Full photo hero:
heroPhotoFull(hero-photo-full.md) - Award badges:
recognitionAwardsBadges(recognition-awards-badges.md) - “Start with what’s happening”, a grid of life situations:
practiceSituations(practice-situations.md) - Fixed fees table:
feesFixedFees(fees-fixed-fees.md) - Steps on a line:
processStepsLine(process-steps-line.md) - A centred review quote with the rating:
testimonialQuoteCentred(testimonial-quote-centred.md) - Four lawyers:
teamGrid4(team-grid-4.md) - Questions and answers:
faqSplit(faq-split.md) - Callback request form:
contactCallbackPanel(contact-callback-panel.md)
Home 3’s header has the Quick exit button, for visitors reading about separation or domestic abuse who may need to leave the page fast. See Quick Exit.
Reorder, Add, Or Remove A Section
Open the route file. The order of the components inside <Base> is the order on the page:
<Base {...data} headerVariant="transparent" footerVariant="offices"> <HeroPhotoFull content={heroPhotoFull} /> <RecognitionAwardsBadges content={recognitionAwardsBadges} /> <PracticeSituations content={practiceSituations} /> ...</Base>- Reorder: move a line up or down.
- Hide on this page: you don’t need code. Add
enable: falseunder the section’s block in the content file. - Remove for good: delete the line and its
importat the top of the file. - Add a section from another page: copy its
importline and its component line from the other route file, and add its block name to the list in the frontmatter part of the file (between the---lines). Section Layouts explains how sections and their layouts are named.
Make Another Homepage Your Main One
The page at / is whatever src/pages/[...lang]/index.astro builds. To use Home 2 or Home 3 as your main homepage:
-
Copy everything in the route file you want (for example
home-family.astro) and paste it over everything inindex.astro. Then, inindex.astro, change"home-family"in thegetEntryCTM("homepage", "home-family", ...)line to"-index". -
In each language folder of
src/content/homepage/, copy everything inhome-family.mdand paste it over-index.md. The main homepage’s content always lives in-index.md, andllms.txtreads the description of/from it. -
Delete
src/pages/[...lang]/home-family.astroand the threehome-family.mdfiles, so the same page isn’t also built at/home-family/. -
Remove the homepage links you no longer need from the Home dropdown in
src/config/menu.<lang>.json(every language), or turn Home into a plain link to/. -
If you use
npm run verify, remove"home-family"from thepageslist at the top ofscripts/check-built-routes.mjs. It checks that each homepage is built.
Remove a homepage you don’t need: delete its route file, its content file in each language folder, its link in each menu file, and its line in scripts/check-built-routes.mjs.
Do It With AI
Make Home 3 (family and private client) the main homepage. Replace the contents ofsrc/pages/[...lang]/index.astro with the contents of src/pages/[...lang]/home-family.astro, and changethe entry name in its getEntryCTM call from "home-family" to "-index". In every language folder ofsrc/content/homepage/, replace -index.md with the contents of home-family.md, then deletehome-family.md and src/pages/[...lang]/home-family.astro. Remove "home-family" from the pages list inscripts/check-built-routes.mjs. In every src/config/menu.<lang>.json, change the "Home" item to aplain link to "/" with no children. Then run npm run build and confirm / shows the Home 3 sections.