Marquee columns side — Hero block

Pro

hero-marquee-columns-side · for home, landing pages

Marquee columns side

The promise on the start side, beside two or three columns of pictures scrolling slowly up and down in opposite directions (still below the expressive level, a short still grid on a phone): a studio, a maker or a shop whose body of work is the argument and wants its words read first, the pictures as a living gallery beside them (the merchant’s own work or products 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-marquee-columns-side

Usage

Its demo data, shortened (Using blocks).

<script setup lang="ts">
import HeroMarqueeColumnsSide from '@/components/trame/blocks/hero/hero-marquee-columns-side.vue'

const props = {
eyebrow: "Spring firing, now in the shop",
title: "Stoneware thrown, glazed and fired in one small kiln",
subtitle: "Hollow Pine Pottery is two potters in a converted barn. Every bowl, cup and plate below came out of our own kiln this year.",
primaryAction: {
label: "Shop the firing",
action: "catalog"
},
secondaryAction: {
label: "Visit the studio",
action: "visit"
},
images: [
{
src: "https://images.unsplash.com/photo-1530006498959-b7884e829a04?w=900&q=75",
alt: "Two speckled white stoneware bowls, stacked",
shape: "portrait"
},
{
src: "https://images.unsplash.com/photo-1610701596007-11502861dcfa?w=900&q=75",
alt: "Pale stoneware cups and jars on a shelf"
}
]
}
</script>

<template>
<HeroMarqueeColumnsSide v-bind="props" />
</template>

Props

Each prop says who changes it: Words, Picture, Action, Design, Data.* required.

PropTypeDescription
eyebrowstringWordsa short chip above the title ("Spring firing, now in the shop")
title*stringWordsthe one promise, in a sentence (40 to 80 characters): the page’s h1
subtitlestringWordswhat it is and for whom, in one or two sentences
primaryAction*PrimaryActionthe main button: its words and the page action it runs
secondaryActionSecondaryActiona quieter second action beside the main one: its words and the page action
commandstringWordsa terminal command that installs it, shown as plain text in a pill with a copy button
images*Image[]3 to 24 pictures of the merchant’s own work or products; in rows, from 6 they alternate between two rows (two rows of 12 at most); on the cylinder, one row in order; in columns-side, two columns (three from 9 pictures); each may lead to its own page
optionsOptionsthe block’s settings: layout choices and secondary words, read by every variant
PrimaryAction primaryAction · 3 props
PropTypeDescription
label*stringWordswhat happens ("Try for free")
action*stringActiona named action of the page
recordRecord<string, unknown>Datathe record the action opens, if any
SecondaryAction secondaryAction · 3 props
PropTypeDescription
label*stringWordswhat happens ("Try for free")
action*stringActiona named action of the page
recordRecord<string, unknown>Datathe record the action opens, if any
Image images[] · 5 props
PropTypeDescription
src*stringPicturea picture: a root-relative path (/media/…) or an absolute URL
alt*stringWordswhat the picture shows, in a few words: required, it is the picture for those who do not see it, and the link’s name
shape'portrait' | 'square' | 'landscape'the picture’s shape in the row: portrait (4:5), square, or landscape (3:2, the default)
actionstringActionwhere the tile leads: the piece’s own page, with its record
recordRecord<string, unknown>Datathe record the action opens, if any
Options options · 1 props
PropTypeDescription
mood'inverse' | 'brand' | 'warm' | 'tint' | stringa 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).

MemberWhat it is for
hrefthe address an action leads to, or null to hide what leads there
actruns a change (subscribe, add to cart, save) and answers { ok } or { ok: false, error }
canwhether the page has this action
asseta picture’s address as your app serves it
Linkyour router’s link component
cartCountthe cart badge’s number
cartDrawerwhether your app has a cart drawer
cartOpenwhether the cart drawer is open
labelyour 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:

KeyEnglishFrench
newsletter.alreadyYou are already subscribed.Vous êtes déjà inscrit.
newsletter.doneDone: you are subscribed.C’est noté : vous êtes inscrit.
newsletter.invalidCheck the email address.Vérifiez l’adresse e-mail.
newsletter.tooManyToo 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: primaryAction, secondaryAction, images[]

A hero section, for home, landing pages; it uses @lucide/vue, 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

  • Globe beside: a team, a network of makers or depots, with more to say: the words at the left and a whole dotted globe at the right, its first places named on leaders; the merchant’s own places only.
  • Globe rising: a brand whose argument is where it makes or ships, told in few words: the words centred over a large dotted hemisphere rising from the bottom edge, its pins named on hover and listed under it; the merchant’s own places only.
  • Image overlay: one strong, wide picture of the shop’s own: the title and the action laid over it on a legible wash, the picture across the whole width.
  • Image quiet: a calm shop or a picture busy with detail: the title centred (or at the start) on the page, the picture under it in a wide frame.
  • Image split: a picture with a subject that must not be covered (a face, a piece in detail): the words in their own column, the picture beside them running to the page’s edge.
  • Ornament: a type-led opening with no integrations to show: the words at one corner of a large drawn object, purely decorative.
  • Photo request: a tall picture with the form panel overlapping it: a workshop, a venue or a service whose place sells the request.
  • Portrait: a person-led brand: the portrait with an availability dot beside the intro, the clients’ logos passing under it at the expressive level (a still row below it) — the merchant’s own only.

All 102 hero blocks