Skip to content
Vitops
GuidesComponentsPackagesThemeReferenceChangelog

Start here

VitopsInstallationStart a new EmDash siteYour design systemYour config

Live preview

Theme previewAnimation libraryIconsPatternsMastheadConfigure a site

Components

OverviewCSS classesWeb componentsAstro componentsBricks elementsEmDash blocks

Packages

@getvitops/cli@getvitops/astro@getvitops/vite@getvitops/generator@getvitops/core@getvitops/utils@getvitops/emdash@getvitops/create

Reference

Config referenceOutput formatsColour systemType & space scalesComponent patternsIconsConsent gateConversion trackingSearchLegal documentsCSS class vocabularyBricks elements

Releases

Changelog

Astro components

Tier 3 — authoring conveniences that emit the correct markup at build time: which wrap a web component, and which emit plain tier-1 markup.

Tier 3 is authoring convenience. Each component renders the correct markup and classes so you don't hand-write boilerplate, and none of them requires runtime JavaScript — Subgrid emits a subgrid list, Popover uses the native Popover API with Anchor Positioning, Details/Drawer/NavShellcompose <details> with Invoker Commands. If a wrapper would need runtime JS it is the wrong tier: that becomes a web component, and the wrapper emits its tag instead.

Tier 3 has two platforms and these are one of them — theBricks elements are the other, at the same tier rather than above it. Both generate HTML from the classes and elements of tiers 1 and 2; which you use is decided by your platform, and no project uses both.

Read the "emits" column before you write markup

Where a component wraps a web component, it emits that tag with the accessible fallback inside it — so the one call is the whole composition, and adding your own wrapper nests two elements on one tree:

<!-- wrong -->
<wc-tree><Tree items={…} /></wc-tree>

<!-- right -->
<Tree items={…} />

<Breadcrumbs />

Pattern
breadcrumbs
Import
@getvitops/astro/components/Breadcrumbs.astro
Emits
tier-1 markup — no web component
Recommended call
<Breadcrumbs items={[{ label, href }, …, { label }]} />. The last item is the current page (aria-current, never a link). Emits the BreadcrumbList JSON-LD from the same items unless schema={false}. Hand-written: <nav aria-label="Breadcrumb" class="breadcrumbs"><ol><li>…. No JS.
Also in
CSS

<Cards />

Pattern
card
Import
@getvitops/astro/components/Cards.astro
Emits
the <wc-cards> tag, fallback inside
Recommended call
<Cards> — it emits <wc-cards> itself, so do NOT add your own wrapper. <Subgrid> is the same grid without the click enhancement.
Also in
CSS, Web component, EmDash

<Carousel />

Pattern
carousel
Import
@getvitops/astro/components/Carousel.astro
Emits
the <wc-carousel> tag, fallback inside
Recommended call
<Carousel slides={…} label="…" /> — it emits <wc-carousel> itself, so do NOT add your own wrapper. .carousel is the shell and .carousel__track the scroller; add loop for the cloned infinite strip (autoplay implies it).
Also in
CSS, Web component, Bricks, EmDash

<Combobox />

Pattern
combobox
Import
@getvitops/astro/components/Combobox.astro
Emits
the <wc-combobox> tag, fallback inside
Recommended call
<Combobox name inputId options={[…]} /> with your own <label for>. With no JS it is an <input list> + <datalist>: native autocomplete. What is typed is what is submitted, so it suggests and does not constrain; use <select> for a closed set. Do NOT wrap it in <wc-combobox>: it emits its own. By hand: <wc-combobox class="combobox"><input class="combobox__input" list="x"><datalist id="x">…</datalist></wc-combobox>.
Also in
CSS, Web component

<ConfigForm />

Pattern
config-form
Import
@getvitops/astro/components/ConfigForm.astro
Emits
the <wc-config-form> tag, fallback inside
Recommended call
<ConfigForm id schema paths output><form method="post">…</form></ConfigForm>, with the fields from renderStepHtml / renderProjectionHtml (@getvitops/utils/forms). With no JS it is a plain form posting the names formToConfig parses and the server validates. Its own Lit-free bundle (@getvitops/core/config-form): the validator and the form codec. Do NOT wrap it in <wc-config-form>: it emits its own. paths narrows the schema to the fields shown; novalidate lets the server decide a submit.
Also in
Web component

<ConfigPreview />

Pattern
config-preview
Import
@getvitops/astro/components/ConfigPreview.astro
Emits
the <wc-config-preview> tag, fallback inside
Recommended call
<ConfigPreview for="<wc-config-form id>" base="<script id>" /> beside a <ConfigForm>; it emits its own <wc-config-preview>, so do NOT wrap it. It loads @getvitops/generator/preview (a colour engine) only when the first edit arrives, and no JS means no preview, stated rather than excused. A contrast failure or an unknown palette hue is reported and the last good CSS stays.
Also in
Web component

<CookieConsent />

Pattern
consent
Import
@getvitops/astro/CookieConsent.astro
Emits
the <wc-consent> tag, fallback inside
Recommended call
<CookieConsent />. Its own Lit-free bundle so a site needing consent does not download a rendering framework.
Also in
CSS, Web component

<ContrastToggle />

Pattern
contrast-toggle
Import
@getvitops/astro/components/ContrastToggle.astro
Emits
the <wc-contrast-toggle> tag, fallback inside
Recommended call
<ContrastToggle /> — it emits <wc-contrast-toggle> itself, so do NOT add your own wrapper. Set site.accessibility.contrastToggle: true so a baseline contrast miss warns instead of failing the build (the generated [data-contrast="more"] layer is the conforming version it switches to).
Also in
CSS, Web component

<Counter />

Pattern
counter
Import
@getvitops/astro/components/Counter.astro
Emits
the <wc-counter> tag, fallback inside
Recommended call
<Counter value="94%" /> — it emits <wc-counter> itself, so do NOT add your own wrapper. The final value is parsed from the fallback text, never passed separately.
Also in
CSS, Web component, EmDash

<Details />

Pattern
details
Import
@getvitops/astro/components/Details.astro
Emits
tier-1 markup — no web component
Recommended call
<Details> — or hand-write <details>. No JS at either tier; ::details-content animates in CSS.
Also in
CSS, EmDash

<Drawer />

Pattern
drawer
Import
@getvitops/astro/components/Drawer.astro
Emits
tier-1 markup — no web component
Recommended call
<Drawer> — <dialog class="drawer"> plus an Invoker Commands trigger. No JS.
Also in
CSS

<Entries />

Pattern
entries
Import
@getvitops/astro/components/Entries.astro
Emits
the <wc-entries> tag, fallback inside
Recommended call
<Entries entries={[{ heading, pairs: [{ term, value }] }]} /> — it emits <wc-entries> itself, so do NOT add your own wrapper. By hand: <wc-entries> around <h3> + <dl> pairs. The tier-2 exemplar: semantic pairs with no JS, a table with it.
Also in
CSS, Web component, Bricks, EmDash

<Field />

Pattern
field
Import
@getvitops/astro/components/Field.astro
Emits
the <wc-field> tag, fallback inside
Recommended call
<Field label help error optional><input name … /></Field>: the label nests the control, so no id/for is needed. With no JS it is a labelled control and a server error is already under it. It is not form-associated: the native control still submits, validates and takes focus. Do NOT wrap it in <wc-field>: it emits its own. By hand: <wc-field class="field"><label class="field__control"><span class="field__label">Name</span><input name="n"></label><small class="field__help">…</small></wc-field>. Use .form-group for a field whose label and control are siblings.
Also in
CSS, Web component

<Format />

Pattern
format
Import
@getvitops/astro/components/Format.astro
Emits
the <wc-format> tag, fallback inside
Recommended call
<Format type="relative" value="2026-11-03T14:05:00Z">November 3, 2026</Format>: the slot is the no-JS text, and title keeps it after upgrade. type is relative, date, datetime, time, number, percent or currency (needs currency="CAD"). fields="year" shows only those date parts and now formats the current date instead of value (<Format type="date" fields="year" now>2026</Format>). Anything it cannot format is left as written. Do NOT wrap it in <wc-format>: it emits its own. By hand: <wc-format type="relative"><time datetime="…">text</time></wc-format>.
Also in
Web component

<ContactForm />

Pattern
forms
Import
@getvitops/astro/components/ContactForm.astro
Emits
tier-1 markup — no web component
Recommended call
Wrap text controls in .form-group or .input-group — a bare <input> gets browser defaults. For a contact or enquiry form use <ContactForm /> (name, email, phone, message, or fields={[{ label, type, required }]}): a real <form method="post"> to createConversionRoute() with the honeypot and, when site.security.turnstile.siteKey is set, Turnstile. Do not hand-write that form: the route drops a field named phone (it is the tel-click payload) and treats website/honeypot as bot traps, and <ContactForm> submits a phone as tel. In EmDash, vitops_form is the same form with editor-defined fields.
Also in
CSS, EmDash

<Gallery />

Pattern
gallery
Import
@getvitops/astro/components/Gallery.astro
Emits
the <wc-gallery> tag, fallback inside
Recommended call
<Gallery images={…} label="…" /> — it emits <wc-gallery> wrapping a <Carousel /> (which emits its own <wc-carousel>) itself, so do NOT add your own wrapper around either. Each thumbnail is a plain <a href="#slide-id"> into the carousel's own <li id="slide-id"> inside a single <dialog class="lightbox-dialog"> (see lightbox), so it is a working modal lightbox — WITH prev/next — before any script runs. Stepping between images is the carousel's job, not the gallery's.
Also in
CSS, Web component, EmDash

<Icon />

Pattern
icon
Import
@getvitops/astro/components/Icon.astro
Emits
tier-1 markup — no web component
Recommended call
<Icon name="menu" />. Names are semantic and resolve per configured set; a name containing : passes through.
Also in
CSS, Bricks

<LocationPage />

Pattern
location-pages
Import
@getvitops/astro/components/LocationPage.astro
Emits
tier-1 markup — no web component
Recommended call
<LocationPage location={…} defaultLocale> and <ServicePage service={…} defaultLocale providerName>: one organization.locations / organization.services entry as a page (name, address, hours table, photos, offers) plus its LocalBusiness / Service JSON-LD, with a slot for your own copy. In EmDash, vitops_location places one location in content (a build-time import of organization.locations, virtual:getvitops/organization, served by vitops()). Nothing scaffolds the route: write src/pages/locations/[slug].astro with getStaticPaths() over the record and resolveSlug() from @getvitops/astro/schemas/graph-adapters.ts (the idiom is in LocationPage's docblock). The key of the record, not the slug, is the entry's identity.
Also in
EmDash

<ServicePage />

Pattern
location-pages
Import
@getvitops/astro/components/ServicePage.astro
Emits
tier-1 markup — no web component
Recommended call
<LocationPage location={…} defaultLocale> and <ServicePage service={…} defaultLocale providerName>: one organization.locations / organization.services entry as a page (name, address, hours table, photos, offers) plus its LocalBusiness / Service JSON-LD, with a slot for your own copy. In EmDash, vitops_location places one location in content (a build-time import of organization.locations, virtual:getvitops/organization, served by vitops()). Nothing scaffolds the route: write src/pages/locations/[slug].astro with getStaticPaths() over the record and resolveSlug() from @getvitops/astro/schemas/graph-adapters.ts (the idiom is in LocationPage's docblock). The key of the record, not the slug, is the entry's identity.
Also in
EmDash

<Marquee />

Pattern
marquee
Import
@getvitops/astro/components/Marquee.astro
Emits
the <wc-marquee> tag, fallback inside
Recommended call
<Marquee> around one .marquee__content, or <wc-marquee> by hand. Scrolls via CSS alone; JS only removes the seam.
Also in
CSS, Web component, EmDash

<Masthead />

Pattern
masthead
Import
@getvitops/astro/components/Masthead.astro
Emits
tier-1 markup — no web component
Recommended call
<Masthead config={site}> from site.chrome.masthead (position static|sticky|fixed, surface solid|glass|transparent, layout full|inset|floating, inset and height lengths — fluid ones like clamp(3.5rem, 8cqi, 4.5rem) are fine — elevation shadow/border, and states: a partial look per scroll state — atStart, atEnd, scrollingToEnd, scrollingToStart, later wins, animated — taking layout, height, inset, surface, elevation (or false) and hidden; e.g. a full-width banner at the top that floats once scrolled, a bar hidden until first scroll, hide-on-scroll). A prop overrides one field for a layout. A state that hides the bar at the start, or changes its size or layout, makes it fixed. Slots brand (default: organization.logo linked to brandHref, logo={false} to omit), default (the <SiteNav>), actions. Pure CSS: states are scroll-state() queries that only override a settled bar, so a browser without them (Firefox today) shows a visible, solid, elevated one. It never takes role="banner": a body-level <header> already is the landmark, and .banner means the announcement bar.
Also in
CSS

<NavShell />

Pattern
navshell
Import
@getvitops/astro/components/NavShell.astro
Emits
tier-1 markup — no web component
Recommended call
<NavShell> with a nav slot, plus <NavShellToggle> if the toggle must live outside the shell.
Also in
CSS

<NavShellToggle />

Pattern
navshell
Import
@getvitops/astro/components/NavShellToggle.astro
Emits
tier-1 markup — no web component
Recommended call
<NavShell> with a nav slot, plus <NavShellToggle> if the toggle must live outside the shell.
Also in
CSS

<Notifications />

Pattern
notification
Import
@getvitops/astro/components/Notifications.astro
Emits
the <wc-notifications> tag, fallback inside
Recommended call
<Notifications /> once per layout, in the same place on every page; it emits its own <wc-notifications>, so do NOT wrap it. Show one with element.show({ message, title?, tone?, duration?, actions? }) or document.dispatchEvent(new CustomEvent("vitops:notify", { detail })). A server-rendered <div class="notification" role="status"> inside it is the no-JS fallback and is adopted into the stack on upgrade. tone is info, success, warning or danger. For something the visitor must act on use a banner or a dialog, not this; for one message that closes itself without a stack use .notification in <wc-dismissable>.
Also in
CSS, Web component

<Popover />

Pattern
popover
Import
@getvitops/astro/components/Popover.astro
Emits
tier-1 markup — no web component
Recommended call
<Popover> — native Popover API + CSS Anchor Positioning. No JS.
Also in
CSS

<Range />

Pattern
range
Import
@getvitops/astro/components/Range.astro
Emits
the <wc-range> tag, fallback inside
Recommended call
A single slider needs no element: a bare <input type="range"> is themed by forms.css (accent-color). For its value shown, or for two thumbs, use <Range name label min max value output /> or <Range names labels values />: with no JS those are native range inputs (two submit as two fields). Every input needs a label. Do NOT wrap it in <wc-range>: it emits its own.
Also in
CSS, Web component

<ReviewCard />

Pattern
review
Import
@getvitops/astro/components/ReviewCard.astro
Emits
tier-1 markup — no web component
Recommended call
<ReviewCard review={…} /> — one card, from vitops reviews' .vitops/reviews.json cache. Put several inside <Carousel> slides or <Marquee> items; there is no group component and no wc-review. In EmDash, vitops_reviews is that whole row: it reads the cache as a build-time import (virtual:getvitops/reviews, served by vitops(); empty when the file is absent), picks reviews with selectReviews(), and lays them out as a grid, carousel or marquee. A new review appears after vitops reviews is re-run, committed and the site rebuilt.
Also in
CSS, EmDash

<BackToTop />

Pattern
scroll-button
Import
@getvitops/astro/components/BackToTop.astro
Emits
tier-1 markup — no web component
Recommended call
<BackToTop /> (or site.chrome.backToTop, rendered by <SiteFooter config>) for a floating link that shows once the page has scrolled; <ScrollCue /> as the LAST child of a position: relative hero, a chevron to the end of that section that hides once scrolling starts. Plain <a href="#…">; hiding is a scroll-state() query, so a browser without it (Firefox today) shows both always. The hero block has a scrollCue toggle.
Also in
CSS

<ScrollCue />

Pattern
scroll-button
Import
@getvitops/astro/components/ScrollCue.astro
Emits
tier-1 markup — no web component
Recommended call
<BackToTop /> (or site.chrome.backToTop, rendered by <SiteFooter config>) for a floating link that shows once the page has scrolled; <ScrollCue /> as the LAST child of a position: relative hero, a chevron to the end of that section that hides once scrolling starts. Plain <a href="#…">; hiding is a scroll-state() query, so a browser without it (Firefox today) shows both always. The hero block has a scrollCue toggle.
Also in
CSS

<ScrollEdges />

Pattern
scroll-edges
Import
@getvitops/astro/components/ScrollEdges.astro
Emits
tier-1 markup — no web component
Recommended call
<ScrollEdges> (or .scroll-edges with the two aria-hidden .scroll-edges__start / __end children by hand) for a horizontally scrolling strip that fades at an edge while there is more that way. The scroll-state vocabulary is the masthead's (at-start, at-end) on the inline axis; hooks --scroll-edges-fade, --scroll-edges-bg, --scroll-edges-<state>-fade-opacity. scroll-state() cannot style the scroller itself, so the fades are sticky child elements. Without it (Firefox today) both fades stay on. Give a strip with nothing focusable in it focusable + a label.
Also in
CSS

<Toc />

Pattern
scroll-target
Import
@getvitops/astro/components/Toc.astro
Emits
tier-1 markup — no web component
Recommended call
<Toc headings={headings} /> (Astro's MarkdownHeading[]) or .scroll-target-group by hand. The current section is :target-current where scroll-target-group exists (Chromium); elsewhere polyfills.js loads an IntersectionObserver that sets .is-current + aria-current="location".
Also in
CSS

<SiteNav />

Pattern
sitenav
Import
@getvitops/astro/components/SiteNav.astro
Emits
tier-1 markup — no web component
Recommended call
.sitenav with --bp-* and a drawer direction. <details> + Invoker Commands, no JS. In Astro: <SiteNav {...await loadNavMenus(getMenu)} /> renders EmDash menu primary (the default: dropdowns from md, drawer below) and, if they exist, primary-mobile (depth-1 nav below md) and primary-mega (mega panels from xl) — adding the menu in the admin is the whole change. An item's titleAttr is its description. Per-site behaviour lives in site.chrome.nav — <SiteNav {...nav} {...resolveNavOptions(site)} /> sets compact (drawer | dropdown: an anchored, columnar panel under the toggle), drawerSide, the breakpoints and depths. For a mega panel's featured column pass megaPanel={VitopsMegaPanel} (@getvitops/emdash/astro): it renders the widget area mega-<item slug> (or the item's mega-area:<name> class) and nothing when there is none. <SiteFooter sitemap legal name config={site}> renders footer-sitemap + footer-legal + the copyright line, plus organization.logo and a contact column (address, tel:/mailto: links, one location's hours, profile links) from the same config: nothing to hand-write, contact={false} / logo={false} to omit, a brand slot to replace the logo, location to pick whose hours. For a menu inside page content (a site map, a section's links, footer-style columns) use .navlist — plain nested lists, --inline / --columns — or, in EmDash, the vitops_nav block (menu, layout list|inline|columns|sitenav, depth 1–3, heading, tone). Name each <nav> uniquely: the header is Primary and the footer Site map / Legal, and the block never reuses those.
Also in
CSS, Bricks, EmDash

<SiteFooter />

Pattern
sitenav
Import
@getvitops/astro/components/SiteFooter.astro
Emits
tier-1 markup — no web component
Recommended call
.sitenav with --bp-* and a drawer direction. <details> + Invoker Commands, no JS. In Astro: <SiteNav {...await loadNavMenus(getMenu)} /> renders EmDash menu primary (the default: dropdowns from md, drawer below) and, if they exist, primary-mobile (depth-1 nav below md) and primary-mega (mega panels from xl) — adding the menu in the admin is the whole change. An item's titleAttr is its description. Per-site behaviour lives in site.chrome.nav — <SiteNav {...nav} {...resolveNavOptions(site)} /> sets compact (drawer | dropdown: an anchored, columnar panel under the toggle), drawerSide, the breakpoints and depths. For a mega panel's featured column pass megaPanel={VitopsMegaPanel} (@getvitops/emdash/astro): it renders the widget area mega-<item slug> (or the item's mega-area:<name> class) and nothing when there is none. <SiteFooter sitemap legal name config={site}> renders footer-sitemap + footer-legal + the copyright line, plus organization.logo and a contact column (address, tel:/mailto: links, one location's hours, profile links) from the same config: nothing to hand-write, contact={false} / logo={false} to omit, a brand slot to replace the logo, location to pick whose hours. For a menu inside page content (a site map, a section's links, footer-style columns) use .navlist — plain nested lists, --inline / --columns — or, in EmDash, the vitops_nav block (menu, layout list|inline|columns|sitenav, depth 1–3, heading, tone). Name each <nav> uniquely: the header is Primary and the footer Site map / Legal, and the block never reuses those.
Also in
CSS, Bricks, EmDash

<Stepper />

Pattern
stepper
Import
@getvitops/astro/components/Stepper.astro
Emits
the <wc-stepper> tag, fallback inside
Recommended call
<Stepper steps> around one <form> of <section id data-step><h2>…</h2>…</section>s: with no JS a complete long form with #anchor links, with JS one step at a time. <StepperNav steps current status hrefFor> is the same .stepper list for a flow where each step is its own page (no JS at all). Do NOT wrap <Stepper> in <wc-stepper>: it emits its own. Its own Lit-free bundle (@getvitops/core/stepper, ~1 KB gzipped), outside elements.js.
Also in
CSS, Web component

<StepperNav />

Pattern
stepper
Import
@getvitops/astro/components/StepperNav.astro
Emits
tier-1 markup — no web component
Recommended call
<Stepper steps> around one <form> of <section id data-step><h2>…</h2>…</section>s: with no JS a complete long form with #anchor links, with JS one step at a time. <StepperNav steps current status hrefFor> is the same .stepper list for a flow where each step is its own page (no JS at all). Do NOT wrap <Stepper> in <wc-stepper>: it emits its own. Its own Lit-free bundle (@getvitops/core/stepper, ~1 KB gzipped), outside elements.js.
Also in
CSS, Web component

<Subgrid />

Pattern
subgrid
Import
@getvitops/astro/components/Subgrid.astro
Emits
tier-1 markup — no web component
Recommended call
<Subgrid> — emits <ul class="subgrid" role="list">; author <li class="card subgrid-card"> items yourself, so tranches align across the set.
Also in
CSS, EmDash

<Tabs />

Pattern
tabs
Import
@getvitops/astro/components/Tabs.astro
Emits
the <wc-tabs> tag, fallback inside
Recommended call
<Tabs items={[{ label, body }]} />, or <Tabs> around your own <section><h3>…</h3>…</section> panels. With no JS every panel is readable under its heading. orientation="vertical" runs the list down the side; hash writes the selected panel into the URL; selected sets the first tab. Do NOT wrap it in <wc-tabs>: it emits its own. By hand: <wc-tabs class="tabs"> around <section>s that each open with a heading.
Also in
CSS, Web component, EmDash

<Tooltip />

Pattern
tooltip
Import
@getvitops/astro/components/Tooltip.astro
Emits
tier-1 markup — no web component
Recommended call
<Tooltip id label>text</Tooltip> for what a control does, <Tooltip toggle> for a "?" that reveals more than a phrase (touch and screen readers). Not an element: the markup is .tooltip-trigger + a .tooltip popover, linked by popovertarget (the no-JS click toggle), and deferred.js adds hover, keyboard focus and Escape, a per-pair anchor, role="tooltip", and aria-describedby (plain) or aria-expanded (toggletip).
Also in
CSS

<Tree />

Pattern
tree
Import
@getvitops/astro/components/Tree.astro
Emits
the <wc-tree> tag, fallback inside
Recommended call
<Tree items={…} /> — it emits <wc-tree> itself, so do NOT add your own wrapper. In EmDash, vitops_tree takes an indented outline (one node per line, indent to nest, | badge for a chip) and builds the tree from it; it never sets descriptionHtml.
Also in
CSS, Web component, EmDash

Installing and configuring the integration is covered inInstallation; the package's full surface is on @getvitops/astro.

Built with the design system it documents.

@getvitops on npm