@versini/ui-table 4.0.9 → 4.0.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +43 -1
- package/dist/components/Table/Table.js +475 -443
- package/dist/index.js +3 -3
- package/package.json +6 -5
package/README.md
CHANGED
|
@@ -1,3 +1,45 @@
|
|
|
1
1
|
# @versini/ui-table
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
[](https://www.npmjs.com/package/@versini/ui-table)
|
|
4
|
+
|
|
5
|
+
> An accessible and feature-rich React table component built with TypeScript and TailwindCSS.
|
|
6
|
+
|
|
7
|
+
The Table component provides data tables with sorting, accessibility features, and customizable styling for displaying tabular data.
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
## Table of Contents
|
|
11
|
+
|
|
12
|
+
- [Features](#features)
|
|
13
|
+
- [Installation](#installation)
|
|
14
|
+
- [Usage](#usage)
|
|
15
|
+
|
|
16
|
+
## Installation
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
npm install @versini/ui-table
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
> **Note**: This component requires TailwindCSS and the `@versini/ui-styles` plugin for proper styling. See the [root README](../../README.md#tailwindcss-setup) for complete setup instructions.
|
|
23
|
+
|
|
24
|
+
## Usage
|
|
25
|
+
|
|
26
|
+
```tsx
|
|
27
|
+
import { Table } from "@versini/ui-table";
|
|
28
|
+
|
|
29
|
+
function App() {
|
|
30
|
+
const data = [
|
|
31
|
+
{ id: 1, name: "John Doe", email: "john@example.com" },
|
|
32
|
+
{ id: 2, name: "Jane Smith", email: "jane@example.com" }
|
|
33
|
+
];
|
|
34
|
+
|
|
35
|
+
return (
|
|
36
|
+
<Table
|
|
37
|
+
columns={[
|
|
38
|
+
{ key: "name", label: "Name" },
|
|
39
|
+
{ key: "email", label: "Email" }
|
|
40
|
+
]}
|
|
41
|
+
data={data}
|
|
42
|
+
/>
|
|
43
|
+
);
|
|
44
|
+
}
|
|
45
|
+
```
|