Tour board below — Hero block
Prohero-tour-board-below · for landing, home pages
Tour board below
The same promise centred, then a wide board across the whole window under it, toured the same way: a range to see as a whole first, wider than tall, for an opening that leads with the words (the host’s own work only)
Documentation
Installation
One command copies the block into your project with the shadcn CLI (the registry is set once: Installation).
pnpm dlx shadcn-vue@latest add @trame/hero-tour-board-belowUsage
Its demo data, shortened (Using blocks).
<script setup lang="ts">
import HeroTourBoardBelow from '@/components/trame/blocks/hero/hero-tour-board-below.vue'
const props = {
badge: {
text: "New: the autumn pieces are in the shop",
action: "news"
},
title: "Furniture and rooms, drawn and made in one workshop",
subtitle: "Atelier Brume is six cabinetmakers and a designer. We draw each piece, make it by hand in solid wood and fit whole rooms, from the kitchen to the reading corner.",
primaryAction: {
label: "Start a project",
action: "contact"
},
secondaryAction: {
label: "See the pieces",
action: "shop"
},
marks: [
{
src: "https://placehold.co/160x48?text=Hollow+Oak",
alt: "Hollow Oak Timber"
},
{
src: "https://placehold.co/160x48?text=Ferrand",
alt: "Ferrand Linen"
}
],
tiles: [
{
title: "The walnut nest",
text: "Three side tables, one log",
image: "https://images.unsplash.com/photo-1611486212355-d276af4581c0?w=1000&q=75",
action: "project",
record: {
id: "walnut-nest"
}
},
{
title: "A living room in Lyon",
image: "https://images.unsplash.com/photo-1721932423849-e9033192b190?w=1000&q=75",
action: "project",
record: {
id: "lyon-living-room"
}
}
],
options: {
marksLabel: "Our wood and cloth come from"
}
}
</script>
<template>
<HeroTourBoardBelow v-bind="props" />
</template>Props
Each prop says who changes it: Words, Picture, Action, Design, Data.* required.
| Prop | Type | Description |
|---|---|---|
| badge | Badge | a pill above the title: the latest news, a link when it has an action |
| title* | string | Wordsthe one promise, in a sentence (40 to 80 characters): the page’s h1 |
| subtitle | string | Wordswhat it is and for whom, in one or two sentences |
| primaryAction* | PrimaryAction | the main button: its words and the page action it runs |
| secondaryAction | SecondaryAction | a quieter second action beside the main one: its words and the page action |
| marks | Mark[] | the host’s own logos or its partners’ marks, in a quiet row under the actions: the merchant’s own only |
| tiles* | Tile[] | the pieces of the board, in the order they are listed: 3 or more make the toured board, 1 or 2 a simple framed pair |
| options | Options | the block’s settings: layout choices and secondary words, read by every variant |
Badge badge · 3 props
| Prop | Type | Description |
|---|---|---|
| text* | string | Wordswhat is new, in a few words ("New: the spring collection") |
| action | string | Actionthe page that tells more, if the pill is a link |
| record | Record<string, unknown> | Datathe record the action opens, if any |
PrimaryAction primaryAction · 3 props
| Prop | Type | Description |
|---|---|---|
| label* | string | Wordswhat happens ("Try for free") |
| action* | string | Actiona named action of the page |
| record | Record<string, unknown> | Datathe record the action opens, if any |
SecondaryAction secondaryAction · 3 props
| Prop | Type | Description |
|---|---|---|
| label* | string | Wordswhat happens ("Try for free") |
| action* | string | Actiona named action of the page |
| record | Record<string, unknown> | Datathe record the action opens, if any |
Mark marks[] · 2 props
| Prop | Type | Description |
|---|---|---|
| src* | string | Picturethe logo file the host gives (SVG or transparent PNG) |
| alt* | string | Wordsthe name the logo stands for |
Tile tiles[] · 6 props
| Prop | Type | Description |
|---|---|---|
| image | string | Picturea picture of the piece, any shape (it is cropped to the tile): without it, the tile is a card of words |
| title* | string | Wordsthe piece’s name, 1 to 6 words: shown on the tile, and the picture’s description |
| text | string | Wordsone short line under the name ("Oak and linen, for a flat in town") |
| tone | 'card' | 'muted' | 'brand' | 'inverse' | a card of words’ ground: the card’s (default), the muted one, the brand’s soft tint, or the text colour inverted; ignored on a picture |
| action | string | Actionwhere the tile leads: the piece’s own page, with its record |
| record | Record<string, unknown> | Datathe record the action opens, if any |
Options options · 2 props
| Prop | Type | Description |
|---|---|---|
| marksLabel | string | Wordsthe words beside the marks, and their list’s name ("Made with") |
| mood | 'inverse' | 'brand' | 'warm' | 'tint' | string | a band of the page that redefines the theme surfaces inside it |
What it asks your app for
The block never knows your app: it asks it, through one context provided once, where its links lead, what its actions do, how a price reads and which words to say (The host context).
| Member | What it is for |
|---|---|
| href | the address an action leads to, or null to hide what leads there |
| act | runs a change (subscribe, add to cart, save) and answers { ok } or { ok: false, error } |
| can | whether the page has this action |
| asset | a picture’s address as your app serves it |
| Link | your router’s link component |
| cartCount | the cart badge’s number |
| cartDrawer | whether your app has a cart drawer |
| cartOpen | whether the cart drawer is open |
| label | your word for an interface key, or undefined to keep the block’s own |
The words it says itself, in English and French; label(key) replaces any of them:
| Key | English | French |
|---|---|---|
| newsletter.already | You are already subscribed. | Vous êtes déjà inscrit. |
| newsletter.done | Done: you are subscribed. | C’est noté : vous êtes inscrit. |
| newsletter.invalid | Check the email address. | Vérifiez l’adresse e-mail. |
| newsletter.tooMany | Too many attempts, try again in a moment. | Trop de tentatives, réessayez dans un moment. |
Features
- Every word in the server HTML
- Same markup in Vue and React
- Theme tokens only: every theme, light and dark
- Shows what you give it, invents nothing
- Expressive motion, within its budget; still under reduced motion
- Real buttons and links, a visible focus
- Asks your app through actions:
badge,primaryAction,secondaryAction,tiles[]
A hero section, for landing, home pages; it uses @lucide/vue, @vueuse/core, class-variance-authority, clsx, motion, reka-ui, tailwind-merge.
Built with
The components this block is made of; each one installs on its own too.
More hero blocks
- Stage centered: the promise centred over a wide product window on a fine grid, the window rising past the backdrop’s foot: a product whose views weigh the same, the first screen of a SaaS or service site; figures and messages in the window are the merchant’s own only.
- Stage deck: the promise at the start and, at the end, a slightly tilted desktop window on two fanned cards with a phone overlapping its corner (the second view in its mobile layout), no tab row: a product used on desktop and on the phone alike, two views that tell it; figures and messages in the window are the merchant’s own only.
- Stage scroll tabs: the promise beside a phone whose view changes as the page scrolls past a rail of the views’ names (a pinned screen on large screens, plain tabs elsewhere): a mobile-first product walked through in 3 to 5 views; figures and messages in the window are the merchant’s own only.
- Store aisles: a large promise and picture with the shop’s categories as a strip of links under it: a catalogue with several ranges to enter by.
- Store mosaic: the promise beside a mosaic of the shop’s picture and its first four categories as picture tiles, the featured products as a short priced list under the words: a shop with a few strong ranges, each with a good picture.
- Trio split: the promise in its own column beside the products, the first one tall and the others stacked next to it, names and prices laid on the pictures: one lead product backed by one or two companions.
- Trio staggered: the promise above three featured products set at different heights: a small range the shop is proud of in full.
- Trusted logo strip: a B2B opening whose proof is who already uses it: the merchant’s own logos under a thin rule.