Skip to content

Commit

Permalink
support header variant
Browse files Browse the repository at this point in the history
  • Loading branch information
stephenjwatkins committed Aug 16, 2023
1 parent 2d1836b commit 2fc737c
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions documentation/specs/Table.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,12 @@ type TableProps<C extends Column> = AriaLabelingProps & {
/** Whether or not row expansion is enabled. */
hasExpandableRows?: boolean;

/**
* Variant of the table header to use.
* @default primary
*/
headerVariant?: "primary" | "secondary";

/** Handler that is called when a user performs an action on the cell. */
onCellAction?: (key: Key) => void;

Expand Down Expand Up @@ -352,3 +358,23 @@ function CustomTable() {
);
}
```

_Header variant:_

```tsx
import { Table } from "@easypost/easy-ui/Table";

const columns = []; /*...*/
const rows = []; /*...*/

function CustomTable() {
return (
<Table
aria-label="Example basic static table"
columns={columns}
rows={rows}
headerVariant="secondary"
/>
);
}
```

0 comments on commit 2fc737c

Please sign in to comment.