import type { Meta, StoryObj } from '@storybook/nextjs-vite'
import { ChatColumnDecorator } from './__fixtures__/chat-card-decorator'
/**
* `ChatInlineVideoPill` is a small bare-inline span defined locally in
* `dispatch.tsx` for the `video` doc type. It is the ONLY entity-card that
* stays inline alongside surrounding markdown text (no card wrapper, no
* Ask/Display affordance) — by design, since the video player itself is
* hoisted out of the paragraph by the chat's pre-scan and rendered above.
*
* Re-implemented here byte-for-byte from `dispatch.tsx:318-326` so the
* story can render in isolation without the dispatch pipeline.
*/
function ChatInlineVideoPill({ title }: { title: string }) {
return (
▶
{title}
)
}
const meta: Meta = {
title: 'Chat/EntityCards/ChatInlineVideoPill',
component: ChatInlineVideoPill,
parameters: {
layout: 'fullscreen',
docs: {
description: {
component:
'Bare-inline pill rendered for the `video` doc type. Used as a sentinel inside a paragraph; the actual video player is hoisted out by the chat pre-scan and rendered above the assistant turn.',
},
},
},
decorators: [
(Story) => (
Here is the demo from last week's call: — watch the part
where Jordan walks through the on-call rotation.
),
],
}
export default meta
type Story = StoryObj
export const Default: Story = {
args: {
title: 'On-call rotation walkthrough',
},
}
export const LongTitleTruncates: Story = {
args: {
title:
'A very long video title that should truncate cleanly inside the pill so adjacent paragraph text stays on the same line',
},
}