Retired products rows — Storefront block
Prostorefront-retired-products-rows · for about, product pages
Retired products rows
Products no longer made with their years, quantity and reason: an honest page about what was stopped
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-retired-products-rowsUsage
Its demo data, shortened (Using blocks).
<script setup lang="ts">
import StorefrontRetiredProductsRows from '@/components/trame/blocks/storefront/storefront-retired-products-rows.vue'
const props = {
title: "What we no longer make",
lead: "Retiring a product is a choice too: here are our reasons.",
retired: [
{
name: "Tide linen jacket",
years: "2016 to 2022",
quantity: "1,200 pieces",
reason: "Our linen supplier went out of business."
},
{
name: "Mist beanie",
years: "2019 to 2023",
quantity: "3,400 pieces",
reason: "Too many returns: the knit pilled. We chose to stop."
}
]
}
</script>
<template>
<StorefrontRetiredProductsRows v-bind="props" />
</template>Props
Each prop says who changes it: Words, Picture, Action, Design, Data.* required.
| Prop | Type | Description |
|---|---|---|
| title* | string | Wordswhat the page says about what stopped ("What we no longer make") |
| lead | string | Wordsone sentence on how the merchant chooses and visits them |
| retired* | Retired[] | products no longer made |
| footnote | string | Wordsa line on the makers we left, or how often audits are done |
| options | Options | the block’s settings: layout choices and secondary words, read by every variant |
Retired retired[] · 4 props
| Prop | Type | Description |
|---|---|---|
| name* | string | Wordsthe product no longer made |
| years* | string | Wordsthe years it was made ("2016 to 2023") |
| quantity | string | Wordshow many were made, as written ("1,200 pieces") |
| reason* | string | Wordswhy it stopped, honestly |
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 about, product pages; it uses clsx, motion, tailwind-merge.
More storefront blocks
- Request status steps: a request waiting on someone: the steps so far, who decides, and what the customer can do meanwhile.
- Restock notice email form: a sold-out category: the merchant’s restocks and an email field to be told.
- Restock notify card: a sold-out product on its own: its picture, its state, one field and the shop’s promise about the address.
- Restock notify inline row: a product page or a sold-out list: one compact row per sold-out variant with its own field and bell button.
- Return request stepped: the request on one page in three numbered steps (items, reason, way back), a summary beside it.
- Returning order review bag first: a signed-in customer: the bag first, saved address and card as rows, and who is signed in at the top.
- Review form card: one form card with the product named on top: under the reviews of a product page, or on a page of its own.
- Review form page: the product large on one side and the form beside it: the page a post-purchase email leads to.