Work history compact table — Portfolio block
Proportfolio-work-history-compact-table · for about, landing pages
Work history compact table
One hairline row per position in a table of period, role and place: eight positions or more, scanned like a résumé
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/portfolio-work-history-compact-tableUsage
Its demo data, shortened (Using blocks).
<script setup lang="ts">
import PortfolioWorkHistoryCompactTable from '@/components/trame/blocks/portfolio/portfolio-work-history-compact-table.vue'
const props = {
title: "Fifteen years in the trade, from the bench to the workshop",
lead: "A career made entirely of leather, from a neighborhood shop to running a small manufacture.",
entries: [
{
id: 1,
role: "Head of production",
org: "Atelier Brise",
period: "Since 2022",
place: "Portland",
text: "Runs the short-batch production and trains apprentices at the bench.",
points: [
"Set up an inspection at every assembly step",
"Grew the cutting and sewing team from three to six people"
],
tags: [
"Production",
"Training"
]
},
{
id: 2,
role: "Senior leatherworker",
org: "Maison Roussel",
period: "2018 – 2022",
place: "San Francisco",
text: "Assembled complex pieces, from pattern to finish.",
points: [
"Developed four designs in the travel range"
],
tags: [
"Pattern making",
"Leather"
]
}
],
skills: [
{
label: "Production",
items: [
"Pattern making",
"Saddle stitching"
]
},
{
label: "Materials",
items: [
"Vegetable-tanned leather",
"Oilcloth"
]
}
],
cv: {
label: "Download resume",
action: "cv",
note: "PDF · 2 pages"
}
}
</script>
<template>
<PortfolioWorkHistoryCompactTable 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 shows ("Path", "Ten years in the trade") |
| lead | string | Wordsone sentence on the person or studio and its path |
| entries* | Entry[] | the positions or engagements, most recent first |
| skills | Skill[] | the skills, grouped |
| cv | Cv | the link to the full CV, with a note |
| options | Options | the block’s settings: layout choices and secondary words, read by every variant |
Entry entries[] · 8 props
| Prop | Type | Description |
|---|---|---|
| id | string | number | Dataa stable key for the entry |
| role* | string | Wordswhat they did ("Leatherworker", "Art direction") |
| org* | string | Wordsfor whom or where ("Atelier Lumen"), as written |
| period* | string | Wordsthe dates exactly as written ("2019 – 2022", "Since 2023"): never computed |
| place | string | Wordswhere ("Lyon") |
| text | string | Wordsone or two sentences on the work |
| points | string[] | Wordsone thing done or delivered, true and checkable |
| tags | string[] | Wordsa discipline or tool of the engagement |
Skill skills[] · 2 props
| Prop | Type | Description |
|---|---|---|
| label* | string | Wordsa group of skills or disciplines ("Production") |
| items* | string[] | Wordsone skill, tool or discipline |
Cv cv · 4 props
| Prop | Type | Description |
|---|---|---|
| label* | string | Wordswhat happens ("Download the CV") |
| action* | string | Actionthe page action that serves the file |
| record | Record<string, unknown> | Datathe record the action opens, if any |
| note | string | Wordsthe file’s kind and size as the merchant states it ("PDF · 2 pages") |
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 |
| 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:
cv
A portfolio section, for about, landing pages; it uses @lucide/vue, class-variance-authority, clsx, motion, reka-ui, tailwind-merge.
More portfolio blocks
- Work grid carousel feature: one project at a time with arrows, picture left and facts right: a few projects that each need space; the merchant’s own only.
- Work grid expandable list: rows with name, client and year that open to detail, tags and result: a long, quiet track record; the merchant’s own only.
- Work grid heading tile: an edge-to-edge two-column wall whose first cell is the heading, the pictures filling the rest in staggered columns, client and title on each picture: a portfolio of four to seven strong pictures; the merchant’s own only.
- Work grid hover reveal: picture tiles with title and kind over a soft gradient, the link appearing on hover: a visual portfolio where pictures do the talking; the merchant’s own only.
- Work grid lead with facts: one project told wide with its facts and results, the others as a short list under: a flagship case study; the merchant’s own only.
- Work grid picture bands: one wide band per project with its picture as a darkened ground, number, title and kind at the left, a two-line summary and the facts at the right: three to six flagship projects listed as bars; the merchant’s own only.
- Work grid stacked cards: full-width project cards that pile up as the page scrolls, each with its facts and result: three to six flagship projects told one after the other; the merchant’s own only.
- Work grid zigzag: picture and text alternating sides, with tags, facts and a button: three or four projects told one by one; the merchant’s own only.