ImportMapper
Bind the columns in someone's file to your fields, with real sample data.
Signature
Density
Viewport
Theme and light/dark are set in the top barWhen to use
Bind the columns in someone's file to your fields, with real sample data.
Accessibility
Fully keyboard operable: Tab to focus, Enter/Space to activate. The visible focus ring uses --focus-ring — never remove it. Provide an accessible label (aria-label) for icon-only controls.
Install and import
npx shadcn@latest add @prism/import-mapper
import { ImportMapper } from '@/components/prism/ImportMapper';
In a no-build prototype, read it from the bundle instead: const { ImportMapper } = window.PrismDesignSystem_39d121;
Props
| Prop | Type | Required | Description |
|---|---|---|---|
columns | ImportColumn[] | — | |
fields | ImportField[] | — | |
mapping | Record<string, string> | — | { [columnKey]: fieldKey }. An empty string means deliberately skipped. |
onChange | (columnKey: string, fieldKey: string) => void | — | |
rowCount | number | — | |
fileName | React.ReactNode | — | |
className | string | — |