ng-hub-ui-paginable 21.0.0 → 21.2.0
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
|
@@ -115,6 +115,10 @@ This library arises from the need to offer highly configurable, accessible, and
|
|
|
115
115
|
|
|
116
116
|
All components are built as standalone Angular components with full Angular Signals support.
|
|
117
117
|
|
|
118
|
+
> ⚠️ **Breaking changes in v21.2.0**
|
|
119
|
+
> This major release removes the `color` property from `PaginableActionButton` and unifies action button contracts.
|
|
120
|
+
> Review migration steps in [BREAKING_CHANGES.md](./BREAKING_CHANGES.md) before upgrading.
|
|
121
|
+
|
|
118
122
|
---
|
|
119
123
|
|
|
120
124
|
## 🎯 Features
|
|
@@ -145,6 +149,8 @@ All components are built as standalone Angular components with full Angular Sign
|
|
|
145
149
|
- **🔍 Menu Filters**: Advanced filtering with dedicated filter panels
|
|
146
150
|
- **🧩 Multi-rule Menu Filters**: AND/OR operators, null checks, and match modes per rule
|
|
147
151
|
- **📋 Hierarchical Lists**: Tree-like data structures with expandable/collapsible nodes
|
|
152
|
+
- **🎛 Context-aware Pagination Theming**: Paginator styles can inherit Table/List theme tokens without duplicating paginator variables
|
|
153
|
+
- **↔️ Bottom Bar Layout Tokens**: Reorder and align paginator/settings/info blocks in both Table and List using CSS variables
|
|
148
154
|
|
|
149
155
|
## 🏗️ Component Architecture
|
|
150
156
|
|
|
@@ -441,7 +447,7 @@ const headers: PaginableTableHeader[] = [
|
|
|
441
447
|
| `sortable` | `boolean` | Enable sorting for this column | `false` | `true` |
|
|
442
448
|
| `wrapping` | `'wrap' \| 'nowrap'` | Text wrapping behavior | `'wrap'` | `'nowrap'` for IDs |
|
|
443
449
|
| `sticky` | `'start' \| 'end'` | Make column sticky during scroll | - | `'end'` for actions |
|
|
444
|
-
| `buttons` | `Array<
|
|
450
|
+
| `buttons` | `Array<PaginableActionButton \| PaginableTableDropdown>` | Action buttons in this column | - | See [Action Buttons](#action-buttons) |
|
|
445
451
|
| `filter` | `InputFilter \| DropdownFilter \| BooleanFilter` | Filter configuration | - | See [Column Filters](#column-filters) |
|
|
446
452
|
| `onlyButtons` | `boolean` | Optimize layout for button-only columns | `false` | `true` for action columns |
|
|
447
453
|
| `hidden` | `boolean \| Function` | Control column visibility | `false` | See [Column Visibility](#column-visibility) |
|
|
@@ -725,17 +731,16 @@ interface PaginableTableDropdown {
|
|
|
725
731
|
tooltip?: string | Observable<string>; // Supports reactive translations
|
|
726
732
|
icon?: string;
|
|
727
733
|
color?: string;
|
|
728
|
-
buttons:
|
|
734
|
+
buttons: PaginableActionButton[];
|
|
729
735
|
position?: 'left' | 'right' | 'start' | 'end';
|
|
730
736
|
fill?: 'clear' | 'outline';
|
|
731
737
|
}
|
|
732
738
|
|
|
733
|
-
interface
|
|
739
|
+
interface PaginableActionButton<T = any> {
|
|
734
740
|
title?: string | Observable<string>; // Button text (supports Observable)
|
|
735
741
|
label?: string | Observable<string>; // Display label (priority over title)
|
|
736
742
|
tooltip?: string | Observable<string>; // Hover tooltip (supports Observable)
|
|
737
743
|
icon?: string | Icon;
|
|
738
|
-
color?: string;
|
|
739
744
|
handler?: (event: TableRowEvent<T>) => void;
|
|
740
745
|
hidden?: boolean | ((row: TableRow<T>) => boolean);
|
|
741
746
|
classlist?: string[] | string;
|
|
@@ -989,7 +994,7 @@ filters = signal({
|
|
|
989
994
|
| `paginationPosition` | `'top' \| 'bottom' \| 'both'` | `'bottom'` | Where to display pagination controls. |
|
|
990
995
|
| `paginationInfo` | `boolean` | `true` | Whether to show pagination info (e.g., "Showing 1 to 10 of 100"). |
|
|
991
996
|
| `stickyActions` | `boolean` | `false` | Whether action buttons should stick during scrolling. |
|
|
992
|
-
| `batchActions` | `Array<PaginableTableDropdown \|
|
|
997
|
+
| `batchActions` | `Array<PaginableTableDropdown \| PaginableActionButton>` | `[]` | Actions available for selected rows. |
|
|
993
998
|
| `responsive` | `TableBreakpoint` | `null` | Responsive breakpoint for table layout. |
|
|
994
999
|
| `options` | `PaginableTableOptions` | `{}` | Visual configuration (cursor, hover, striped, variant). |
|
|
995
1000
|
| `clickFn` | `(event: TableRowEvent<T>) => void` | `null` | Handler for row click events. |
|
|
@@ -1033,7 +1038,7 @@ interface TableRowEvent<T> {
|
|
|
1033
1038
|
| `bindChildren` | `string` | `'children'` | Property containing child items. |
|
|
1034
1039
|
| `selectable` | `string` | `null` | Selection mode configuration. |
|
|
1035
1040
|
| `options` | `PaginableTableOptions` | `{}` | Visual and behavioral options. |
|
|
1036
|
-
| `batchActions` | `Array<PaginableTableDropdown \|
|
|
1041
|
+
| `batchActions` | `Array<PaginableTableDropdown \| PaginableActionButton>` | `[]` | Actions for selected items. |
|
|
1037
1042
|
| `clickFn` | `(event: ListClickEvent<T>) => void` | `null` | Handler for item click events. |
|
|
1038
1043
|
| `rowClass` | `string \| ((item: T) => string)` | `null` | Custom CSS class for a list item. Can be a fixed string or a function that returns a class based on item data. |
|
|
1039
1044
|
|
|
@@ -1163,6 +1168,7 @@ You can also use `tableRowTpt` with expandable components.
|
|
|
1163
1168
|
The `ng-hub-ui-paginable` library is fully style-configurable through **CSS custom properties (CSS variables)** for **Table**, **List**, and **Paginator**.
|
|
1164
1169
|
|
|
1165
1170
|
For a complete and up-to-date token catalog, see [CSS Variables Reference](./docs/css-variables-reference.md).
|
|
1171
|
+
Table and List also expose context pagination tokens (`--hub-table-pagination-*`, `--hub-list-pagination-*`) so embedded paginators follow component themes by default.
|
|
1166
1172
|
|
|
1167
1173
|
### 🔗 Import styles
|
|
1168
1174
|
|