nicklabs-ui 1.0.54 → 1.0.56

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 CHANGED
@@ -755,10 +755,11 @@ A full-featured data management component combining table, pagination, filtering
755
755
  |------|------|---------|-------------|
756
756
  | `title` | `string` | — | Section title displayed in hero header |
757
757
  | `description` | `string` | — | Section description displayed in hero header |
758
- | `items` | `T[]` | `[]` | Data items (T must extend `{ id: number }`) |
758
+ | `items` | `T[]` | `[]` | Data items (T must extend `{ id: string }`) |
759
759
  | `columns` | `NTableColumn[]` | `[]` | Column definitions |
760
- | `itemKey` | `string` | `"id"` | Unique key field |
760
+ | `itemKey` | `keyof T` | `"id"` | Unique key field |
761
761
  | `totalItems` | `number` | `0` | Total item count for pagination calculation |
762
+ | `currentPage` | `number` | `1` | Current page number (controlled pagination) |
762
763
  | `pageSize` | `number` | `10` | Items per page |
763
764
  | `maxPageButtons` | `number` | `7` | Visible page buttons |
764
765
  | `creatable` | `boolean` | `false` | Show create button |
@@ -785,7 +786,7 @@ A full-featured data management component combining table, pagination, filtering
785
786
  | `delete` | `T` | Row delete clicked |
786
787
  | `pageChange` | `number` | Page changed |
787
788
  | `create` | — | Create clicked |
788
- | `batchDelete` | `number[], clearSelected: () => void` | Batch delete with selected IDs; call `clearSelected()` after deletion to reset checkboxes |
789
+ | `batchDelete` | `string[], clearSelected: () => void` | Batch delete with selected IDs; call `clearSelected()` after deletion to reset checkboxes |
789
790
  | `refresh` | — | Refresh clicked |
790
791
  | `filter` | — | Filter clicked |
791
792
  | `click` | `T` | Row clicked |
@@ -825,9 +826,9 @@ A full-featured data management component combining table, pagination, filtering
825
826
  <script setup lang="ts">
826
827
  import { NList } from 'nicklabs-ui'
827
828
 
828
- // T must extend { id: number }
829
+ // T must extend { id: string }
829
830
  interface User {
830
- id: number
831
+ id: string
831
832
  name: string
832
833
  email: string
833
834
  }