Product information sheet drawer — Storefront block
Prostorefront-product-information-sheet-drawer · for product pages
Product information sheet drawer
Long materials, ingredients or care copy in a side panel opened from compact rows; 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/storefront-product-information-sheet-drawerUsage
Its demo data, shortened (Using blocks).
<script setup lang="ts">
import StorefrontProductInformationSheetDrawer from '@/components/trame/blocks/storefront/storefront-product-information-sheet-drawer.vue'
const props = {
title: "Specifications",
intro: "Measured on the finished product, in our workshop.",
groups: [
{
title: "Dimensions",
rows: [
{
label: "Height",
value: "20.5 in"
},
{
label: "Width",
value: "11.8 in"
}
]
},
{
title: "Materials",
rows: [
{
label: "Outside",
value: "Coated cotton canvas, 12.4 oz/yd²"
},
{
label: "Lining",
value: "Recycled polyester"
}
]
}
],
measurements: [
{
label: "Height",
value: "20.5 in"
},
{
label: "Width",
value: "11.8 in"
}
],
sheets: [
{
title: "Dimensions",
body: "Height: 20.5 in.\n\nWidth: 11.8 in.\n\nDepth: 7.5 in.\n\nEmpty weight: 2.4 lb."
},
{
title: "Materials",
body: "Outside: Coated cotton canvas, 12.4 oz/yd².\n\nLining: Recycled polyester.\n\nClosures: Brass zippers."
}
]
}
</script>
<template>
<StorefrontProductInformationSheetDrawer v-bind="props" />
</template>Props
Each prop says who changes it: Words, Picture, Action, Design, Data.* required.
| Prop | Type | Description |
|---|---|---|
| title* | string | Wordsthe block’s title ("Features") |
| intro | string | Wordsone sentence on what the details cover |
| groups | Group[] | the groups shown, in order |
| measurements | Measurement[] | the product’s measurements, each a label and a value |
| sheets* | Sheet[] | the information sheets, each a title and its text |
| options | Options | the block’s settings: layout choices and secondary words, read by every variant |
Group groups[] · 2 props
| Prop | Type | Description |
|---|---|---|
| title | string | Wordsthe group ("Dimensions", "Materials") |
| rows* | Row[] | the group’s rows, in order |
Row groups[].rows[] · 2 props
| Prop | Type | Description |
|---|---|---|
| label* | string | Wordswhat the value is about |
| value* | string | Wordsthe value, as the merchant states it |
Measurement measurements[] · 2 props
| Prop | Type | Description |
|---|---|---|
| label* | string | Wordswhat the value is about |
| value* | string | Wordsthe exact measurement supplied by the merchant |
Sheet sheets[] · 2 props
| Prop | Type | Description |
|---|---|---|
| title* | string | Wordsthe sheet’s title |
| body* | string | Wordsthe sheet’s text |
Options options · 1 props
| Prop | Type | Description |
|---|---|---|
| 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 |
| 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
A storefront section, for product pages; it uses @lucide/vue, @vueuse/core, class-variance-authority, clsx, reka-ui, tailwind-merge.
Built with
The components this block is made of; each one installs on its own too.
More storefront blocks
- Product grid editorial: one large tile every few products and an optional banner cell: a catalogue that reads like a magazine page, for a short or curated list.
- Product grid rows: a dense list, one product per row with its summary and options: for large catalogues and visitors who compare facts.
- Product grid: the catalogue’s standard grid, four columns on a wide screen: every product equal, so a visitor compares quickly.
- Product hotspots markers: a product seen as a whole where details matter (a bag, a watch): numbered markers on one picture, the list beside it.
- Product offer panel frequency: a product bought once or on subscription: two selectable cards, the saving as a number, a button that restates the choice.
- Product overview filmstrip: a strip of landscape pictures edge to edge, then the facts, the buy box and the description side by side: furniture and wide objects photographed in rooms.
- Product overview minimal spec: one picture, the options and a definition list of facts: a catalogue with few photos or technical goods.
- Product overview mosaic: one lead picture and the others as a two-column grid under it, the buy box beside: a product with 3 to 7 pictures of equal interest (a bag, a jacket).