snap-records 1.1.7 → 1.1.9
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 +13 -13
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -5,20 +5,20 @@
|
|
|
5
5
|
</p>
|
|
6
6
|
|
|
7
7
|
<p align="center">
|
|
8
|
-
<a href="https://www.npmjs.com/package/snap-records"
|
|
9
|
-
<a href="https://github.com/lbassuncao/SnapRecords/blob/main/LICENSE"
|
|
10
|
-
<a href="https://github.com/lbassuncao/SnapRecords/actions/workflows/ci.yml"
|
|
8
|
+
<a href="https://www.npmjs.com/package/snap-records"><img src="https://img.shields.io/npm/v/snap-records.svg?style=flat-square&color=007acc" alt="NPM Version"></a>
|
|
9
|
+
<a href="https://github.com/lbassuncao/SnapRecords/blob/main/LICENSE"><img src="https://img.shields.io/npm/l/snap-records.svg?style=flat-square&color=007acc" alt="License"></a>
|
|
10
|
+
<a href="https://github.com/lbassuncao/SnapRecords/actions/workflows/ci.yml"><img src="https://github.com/lbassuncao/SnapRecords/actions/workflows/ci.yml/badge.svg" alt="Build Status"></a>
|
|
11
11
|
</p>
|
|
12
12
|
|
|
13
13
|
<br>
|
|
14
14
|
|
|
15
15
|
<p align="center" style="font-size: 1.15rem">
|
|
16
|
-
<strong><a href="https://github.com/lbassuncao/SnapRecords/blob/main/docs/CONFIG.md"
|
|
17
|
-
<strong><a href="https://github.com/lbassuncao/SnapRecords/blob/main/docs/BUILD.md"
|
|
18
|
-
<strong><a href="https://github.com/lbassuncao/SnapRecords/blob/main/docs/KEYBOARD.md"
|
|
19
|
-
<strong><a href="https://github.com/lbassuncao/SnapRecords/blob/main/CONTRIBUTING.md"
|
|
20
|
-
<strong><a href="https://github.com/lbassuncao/SnapRecords/blob/main/LICENSE"
|
|
21
|
-
<strong><a href="https://github.com/lbassuncao/SnapRecords/blob/main/docs/COC.md"
|
|
16
|
+
<strong><a href="https://github.com/lbassuncao/SnapRecords/blob/main/docs/CONFIG.md">Configuration</a></strong> |
|
|
17
|
+
<strong><a href="https://github.com/lbassuncao/SnapRecords/blob/main/docs/BUILD.md">Build Guide</a></strong> |
|
|
18
|
+
<strong><a href="https://github.com/lbassuncao/SnapRecords/blob/main/docs/KEYBOARD.md">Keyboard Navigation</a></strong> |
|
|
19
|
+
<strong><a href="https://github.com/lbassuncao/SnapRecords/blob/main/CONTRIBUTING.md">Contributing</a></strong> |
|
|
20
|
+
<strong><a href="https://github.com/lbassuncao/SnapRecords/blob/main/LICENSE">License</a></strong> |
|
|
21
|
+
<strong><a href="https://github.com/lbassuncao/SnapRecords/blob/main/docs/COC.md">Code of Conduct</a></strong>
|
|
22
22
|
</p>
|
|
23
23
|
|
|
24
24
|
<br>
|
|
@@ -65,7 +65,7 @@ To quickly set up SnapRecords:
|
|
|
65
65
|
import { SnapRecords, RowsPerPage } from './SnapRecords';
|
|
66
66
|
|
|
67
67
|
new SnapRecords('table-container', {
|
|
68
|
-
url: '
|
|
68
|
+
url: 'https://api.example.com/data',
|
|
69
69
|
columns: ['id', 'name'],
|
|
70
70
|
rowsPerPage: RowsPerPage.DEFAULT,
|
|
71
71
|
// No theme specified, so it uses 'default' and inherits host page styles
|
|
@@ -234,7 +234,7 @@ api.setRenderMode(RenderType.MOBILE_CARDS);
|
|
|
234
234
|
|
|
235
235
|
## Configuration Options
|
|
236
236
|
|
|
237
|
-
The `SnapRecordsOptions<T>` interface defines all configuration options. Key options include (see
|
|
237
|
+
The `SnapRecordsOptions<T>` interface defines all configuration options. Key options include (see [config.md](https://github.com/lbassuncao/SnapRecords/blob/main/docs/CONFIG.md) for full details):
|
|
238
238
|
|
|
239
239
|
- `url` (string, required): API URL for data fetching.
|
|
240
240
|
- `columns` (string[], required): Column keys to display.
|
|
@@ -311,7 +311,7 @@ Override styles in your CSS as needed.
|
|
|
311
311
|
SnapRecords prioritizes accessibility:
|
|
312
312
|
|
|
313
313
|
- **ARIA Attributes**: Supports `aria-sort`, `aria-selected`, `aria-label` for table, list, and card modes.
|
|
314
|
-
- **Keyboard Navigation**: ArrowUp/Down for row navigation, Enter/Space for selection, PageUp/Down for pagination (see
|
|
314
|
+
- **Keyboard Navigation**: ArrowUp/Down for row navigation, Enter/Space for selection, PageUp/Down for pagination (see [keyboard.md](https://github.com/lbassuncao/SnapRecords/blob/main/docs/KEYBOARD.md)).
|
|
315
315
|
- **Screen Reader Support**: Announces updates (e.g., row selection, mode changes) via ARIA live regions.
|
|
316
316
|
|
|
317
317
|
## State Management
|
|
@@ -464,7 +464,7 @@ Customize rendering or event handling by providing custom `renderer`, `eventMana
|
|
|
464
464
|
|
|
465
465
|
## License
|
|
466
466
|
|
|
467
|
-
MIT License. See [
|
|
467
|
+
MIT License. See [LICENSE](https://github.com/lbassuncao/SnapRecords/blob/main/LICENSE) for details.
|
|
468
468
|
|
|
469
469
|
## Support
|
|
470
470
|
|