Session recording split player — Events block
Proevents-session-recording-split-player · for landing, home pages
Session recording split player
A session that already happened: the recording to play, the chapters and speakers, a form to receive the material — 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/events-session-recording-split-playerUsage
Its demo data, shortened (Using blocks).
<script setup lang="ts">
import EventsSessionRecordingSplitPlayer from '@/components/trame/blocks/events/events-session-recording-split-player.vue'
const props = {
title: "Launch your online shop in three weeks",
lead: "One hour to see, step by step, how to go from a catalog in a spreadsheet to a shop that takes orders. Questions are welcome.",
date: "Thursday, November 14",
time: "2 – 3 p.m. Pacific Time",
format: "Online and live, with a Q&A at the end",
speakers: [
{
name: "Camille Roussel",
role: "Head of customer success"
},
{
name: "Mathis Bernard",
role: "Shop advisor"
}
],
agenda: [
{
time: "2:00 p.m.",
title: "Prepare your catalog",
text: "Photos, variants, prices: what to have at hand."
},
{
time: "2:15 p.m.",
title: "Set up payments and shipping",
text: "The settings that prevent nasty surprises."
}
],
replay: {
video: "/media/films/webinaire.mp4",
poster: "https://images.unsplash.com/photo-1791298043001-d6488112d8da?w=1600&q=80",
alt: "People around a workshop table, with pencils and markers in front of them",
duration: "58 min"
},
registerAction: "webinar.register",
submitLabel: "Get the materials",
consent: "We use your email only to send you the link and the session materials.",
options: {
eyebrow: "Replay",
formTitle: "Get the materials"
}
}
</script>
<template>
<EventsSessionRecordingSplitPlayer v-bind="props" />
</template>Props
Each prop says who changes it: Words, Picture, Action, Design, Data.* required.
| Prop | Type | Description |
|---|---|---|
| title* | string | Wordsthe session’s title, an h2 ("Launching a shop in three weeks") |
| lead | string | Wordswhat the session covers, one or two sentences |
| date | string | Wordsthe day as the merchant writes it ("Thursday 14 November"): never computed, no countdown |
| time | string | Wordsthe hour and its zone as written ("2 pm – 3 pm, Paris time") |
| format | string | Wordshow it takes place ("Online, live, questions at the end") |
| speakers | Speaker[] | who speaks |
| agenda | Agenda[] | what the session covers, with time marks |
| replay* | Replay | the recording, loaded only when played |
| registerAction* | string | Actionthe page action the registration form posts to |
| submitLabel* | string | Wordsthe form’s button ("Sign me up") |
| consent | string | Wordsthe line under the form about the address ("We only use your email for this session.") |
| options | Options | the block’s settings: layout choices and secondary words, read by every variant |
Speaker speakers[] · 4 props
| Prop | Type | Description |
|---|---|---|
| name* | string | Wordsthe person’s name |
| role | string | Wordstheir role or job title |
| avatar | string | Picturea picture: a root-relative path (/media/…) or an absolute URL |
| alt | string | Wordsthe picture’s description |
Agenda agenda[] · 3 props
| Prop | Type | Description |
|---|---|---|
| time | string | Wordsa minute mark or a duration ("0:00", "10 min") |
| title* | string | Wordsthe part, in a few words |
| text | string | Wordsone sentence about it |
Replay replay · 4 props
| Prop | Type | Description |
|---|---|---|
| video* | string | Picturethe recording: a file (.mp4,.webm) or an embed address. Loads only when the visitor presses play |
| poster | string | Picturea picture: a root-relative path (/media/…) or an absolute URL |
| alt | string | Wordswhat the poster shows |
| duration | string | Wordsits length as the merchant knows it |
Options options · 6 props
| Prop | Type | Description |
|---|---|---|
| eyebrow | string | Wordsa label above the title ("Webinar") |
| formTitle | string | Wordsthe form’s title ("Book my place") |
| askName | boolean | true: the registration form also asks for a name |
| status | 'success' | 'error' | Datathe answer to the last submission, when the host re-renders with it |
| statusText | string | Wordswhat that answer says |
| 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 |
| asset | a picture’s address as your app serves it |
| 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:
registerAction
A events section, for landing, home pages; it uses @lucide/vue, @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 events blocks
- Season calendar this month: twelve month buttons and, under them, what arrives, what is at its best and what ends in the chosen month: a shop that wants to say what to buy now.
- Session program columns: one to three columns of timed sessions, one per day or track: a programme with parallel sessions; the merchant’s own only.
- Session program rail: a single vertical rail of hours with notes: the schedule of one day; the merchant’s own only.
- Session programme dated list: a recurring programme: a dated list of sessions, each open, full or in replay, with one form to follow the series — the merchant’s own only.
- Tour dates by month: a long run of dates grouped under their month: a season or a year of shows.
- Tour dates list: a clear agenda of a few dates: day, city and venue, status, tickets: when the dates are the information.
- Tour dates poster: the dates as big type, like a tour poster: a short run of dates that must be felt, not only read.
- Upcoming list: a date chip, the title, details and a reserve action per row: a handful of dated events to book; the merchant’s own only.