Taxo Theme Documentation
Customizing The Header
Taxo has two header layouts:
header-1usesHeader.astroheader-2usesHeaderTwo.astro
The base layout default is header-2, but the main homepage explicitly uses
header-1.
Where Header Layouts Are Chosen
const defaultHeader = "header-2";const resolveHeader = headerLayout || defaultHeader;<Base {...page?.data} headerLayout="header-1">Header 1 Structure
src/layouts/components/global/header/Header.astro renders:
TopBar.astro- logo
headerPrimarynavigation- optional navigation CTA button
- optional offcanvas toggle
TopBar.astro includes:
- working hours label from
src/i18n/*.json - phone chip from
settings.contactInfo.phone - language switcher when multilingual is enabled
- the first 4 enabled links from
src/config/social.json
Header 2 Structure
src/layouts/components/global/header/HeaderTwo.astro renders:
TopBarTwo.astro- accent logo block
headerPrimarynavigation- phone CTA block from
settings.contactInfo.phone - optional offcanvas toggle
TopBarTwo.astro includes:
- hotline block from
settings.contactInfo.phone - announcement bar text
- language switcher
Header Settings Inconfig.toml
[settings.navigationButton] enable = true label = "" url = "/contact/"
[settings.announcementBar] enable = true label = ""
[settings.headerOffcanvas] enable = true logo = "/images/logo-light.svg" description = ""
[settings.headerOffcanvas.button] enable = true label = "" url = "/contact/"Shared Text Sources
When a label is empty in config.toml, Taxo falls back to src/i18n/en.json
or src/i18n/fr.json:
{ "navigation": { "buttonLabel": "Get in Touch" }, "header": { "announcement": "Get Your Free Tax Advisor Today..." }, "headerOffcanvas": { "description": "We are a digital agency...", "buttonLabel": "Let's Talk With Us" }}Menu Source
Both header layouts use the same menu data:
{ "headerPrimary": []}That means a menu change affects:
- header 1 desktop navigation
- header 2 desktop navigation
- the mobile offcanvas navigation
Show Or Hide The Desktop Offcanvas
By default, many pages pass hideOffcanvas={true}, which keeps the offcanvas
toggle mobile-only. If you want the desktop offcanvas button visible on a page,
change the page file:
<Base {...page?.data} hideOffcanvas={false}>