You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
description: A table is used to organize and display structured data in rows and columns.
7
7
---
8
8
9
+
import {
10
+
Table,
11
+
TableBody,
12
+
TableCell,
13
+
TableContainer,
14
+
TableHead,
15
+
TableRow
16
+
} from"@sistent/sistent"
17
+
9
18
Tables are used to present structured data in a clear and organized way. They help users scan information quickly, compare values, and understand relationships between data.
10
19
11
-
## Types
20
+
## Overview
21
+
22
+
Tables help organize data into rows and columns, making it easier to read and analyze information.
23
+
24
+
---
25
+
26
+
## Usage
27
+
28
+
Tables should be used when:
29
+
30
+
- Displaying structured data
31
+
- Comparing values
32
+
- Showing logs or metrics
33
+
- Listing users or resources
34
+
35
+
---
12
36
13
-
Different types of tables help present information based on use cases and data complexity.
37
+
## Examples
14
38
15
39
### Basic Table
16
40
17
41
Basic tables are used to display structured data in rows and columns.
18
42
19
-
<table>
20
-
<thead>
21
-
<tr>
22
-
<th>Name</th>
23
-
<th>Role</th>
24
-
<th>Status</th>
25
-
</tr>
26
-
</thead>
27
-
<tbody>
28
-
<tr>
29
-
<td>User 1</td>
30
-
<td>Contributor</td>
31
-
<td>Active</td>
32
-
</tr>
33
-
</tbody>
34
-
</table>
43
+
<TableContainer>
44
+
<Table>
45
+
<TableHead>
46
+
<TableRow>
47
+
<TableCell>Name</TableCell>
48
+
<TableCell>Role</TableCell>
49
+
<TableCell>Status</TableCell>
50
+
</TableRow>
51
+
</TableHead>
52
+
<TableBody>
53
+
<TableRow>
54
+
<TableCell>User 1</TableCell>
55
+
<TableCell>Contributor</TableCell>
56
+
<TableCell>Active</TableCell>
57
+
</TableRow>
58
+
</TableBody>
59
+
</Table>
60
+
</TableContainer>
61
+
62
+
---
35
63
36
64
### Striped Table
37
65
38
66
Striped tables improve readability by alternating row colors.
39
67
40
-
<table>
41
-
<thead>
42
-
<tr>
43
-
<th>Name</th>
44
-
<th>Role</th>
45
-
</tr>
46
-
</thead>
47
-
<tbody>
48
-
<tr>
49
-
<td>User 1</td>
50
-
<td>Contributor</td>
51
-
</tr>
52
-
</tbody>
53
-
</table>
68
+
<TableContainer>
69
+
<Tablestriped>
70
+
<TableHead>
71
+
<TableRow>
72
+
<TableCell>Name</TableCell>
73
+
<TableCell>Role</TableCell>
74
+
</TableRow>
75
+
</TableHead>
76
+
<TableBody>
77
+
<TableRow>
78
+
<TableCell>User 1</TableCell>
79
+
<TableCell>Contributor</TableCell>
80
+
</TableRow>
81
+
</TableBody>
82
+
</Table>
83
+
</TableContainer>
54
84
55
-
## Usage
85
+
---
56
86
57
-
Tables should be used when:
87
+
## States
58
88
59
-
- Displaying structured data
60
-
- Comparing values
61
-
- Showing logs or metrics
62
-
- Listing users or resources
89
+
### Sortable Table
63
90
64
-
## Best Practices
91
+
Tables can support sorting to help users organize data.
0 commit comments