import { playgroundParameters } from "@charcuterie/storybook-config/story-parameters"
import type { Meta, StoryObj } from "@storybook/react"
import {
ContainerBoard,
StoryCell,
StoryGrid,
} from "../board.storyHelpers.tsx"
import { TableViewport } from "./TableViewport.tsx"
const comparison = (count: number) => (
Printer comparison
{[
"Feature",
"Current service",
"Provider fork",
"Alternative",
"Work needed",
].map((name) => (
|
{name}
|
))}
{Array.from(
{ length: count },
(_, index) => `Feature ${index + 1}`,
).map((feature) => (
| {feature} |
Existing integration supports prepared jobs and
preserves the current workflow.
|
Provider support exists. Hardware verification
is still needed before deployment.
|
Advertised support. Exact behavior remains
unconfirmed.
|
Verify compatibility, keep the existing
controls, and test error recovery.
|
))}
)
const meta = {
title: "Components/Data/TableViewport",
component: TableViewport,
args: {
columnCount: 5,
label: "Printer comparison",
children: comparison(12),
},
} satisfies Meta
export default meta
type Story = StoryObj
export const Playground: Story = {
parameters: playgroundParameters,
}
export const AllVariants: Story = {
render: (props) => (
{comparison(2)}
{comparison(16)}
),
}
export const AllStates: Story = {
render: (props) => (
{comparison(0)}
),
}
export const Responsive: Story = {
render: (props) => (
{(width) => (
)}
),
}
export const Interactive: Story = {}