Project inquiry split form — Hero block
Prohero-project-inquiry-split-form · for home, landing pages
Project inquiry split form
Someone who wants to be written to: the key facts on one side, a short contact form on the other — the merchant’s own 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-project-inquiry-split-formUsage
Its demo data, shortened (Using blocks).
<script setup lang="ts">
import HeroProjectInquirySplitForm from '@/components/trame/blocks/hero/hero-project-inquiry-split-form.vue'
const props = {
eyebrow: "Design studio, Portland",
title: "We design brands built to last",
subtitle: "Visual identity, packaging and websites for small businesses that would rather have one right idea than ten loud ones. A studio of three, and one point of contact from the first meeting to delivery.",
facts: [
{
label: "Based in",
value: "Portland, Pearl District"
},
{
label: "Response time",
value: "Within two business days"
}
],
fields: [
{
name: "name",
label: "Your name",
type: "text"
},
{
name: "email",
label: "Your email address",
type: "email"
}
],
primaryAction: {
label: "Start a project",
action: "contact"
},
secondaryAction: {
label: "See our work",
action: "work"
},
options: {
availability: "Available from January",
factsTitle: "Write to us"
}
}
</script>
<template>
<HeroProjectInquirySplitForm v-bind="props" />
</template>Props
Each prop says who changes it: Words, Picture, Action, Design, Data.* required.
| Prop | Type | Description |
|---|---|---|
| eyebrow | string | Wordswho and where, in a few words ("Design studio, Lyon") |
| title* | string | Wordsthe name or the statement, in a sentence |
| subtitle* | string | Wordsone paragraph: what is done, for whom, how |
| facts | Fact[] | the facts shown, in order |
| fields* | Field[] | the form’s fields, in order |
| 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 |
| options | Options | the block’s settings: layout choices and secondary words, read by every variant |
Fact facts[] · 2 props
| Prop | Type | Description |
|---|---|---|
| label* | string | Wordswhat the fact is ("Based in") |
| value* | string | Wordsits value, as the owner states it |
Field fields[] · 3 props
| Prop | Type | Description |
|---|---|---|
| name* | string | Designthe form field’s name |
| label* | string | Wordswhat the field asks |
| type | string | Designtext, email or textarea |
PrimaryAction primaryAction · 3 props
| Prop | Type | Description |
|---|---|---|
| label* | string | Wordswhat happens ("Start a project") |
| 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 ("Start a project") |
| action* | string | Actiona named action of the page |
| record | Record<string, unknown> | Datathe record the action opens, if any |
Options options · 3 props
| Prop | Type | Description |
|---|---|---|
| availability | string | Wordsthe owner’s availability, in their words ("Available from January") |
| factsTitle | string | Wordsthe heading of the side card ("Awards", "Services") |
| 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 |
| 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
- Subtle motion: one short reveal; still under reduced motion
- Real buttons and links, a visible focus
- Asks your app through actions:
primaryAction,secondaryAction
A hero section, for home, landing pages; it uses @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
- Product introduction steps: an ordered list of what happens first: a product that is easy to start with — the merchant’s own only.
- Product slides framed card: a rounded frame inside the page’s margins, the words at its top left and the product card floating at the bottom right with the arrows beside it: a quieter shop, or a header that never overlays.
- Product slides fullbleed card: pictures edge to edge, the words on the calm side and the campaign’s product on a card at the other, arrows at the edges: a shop whose scenes sell and whose first click should land on a product.
- Profile facts: a studio or freelancer opening: who, what and a few key facts, with the recognitions they earned in a card beside — the merchant’s own only.
- Projects numbered: a portfolio led by its work: a short intro and a numbered list of projects with their discipline and year — the merchant’s own only.
- Prompt centered: the opening of an AI tool, a generator or a search-first product: a centred promise over a wide prompt field that glows, the example prompts under it.
- Prompt split: the same prompt as a working card beside the promise: a product whose promise needs a longer sentence, or a page whose heroes start on one side.
- Proof panel panels: an agency, a studio or a B2B tool whose proof is its track record: the promise on the left over an atmospheric picture, and on the right two frosted panels, the figures (a lead figure, a share as a bar, a ruled row) above the clients’ logos passing at the expressive level — the merchant’s own figures and clients only.