@life-cockpit/angular-ui-kit 1.11.7 → 1.11.8
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/package.json
CHANGED
|
@@ -3761,6 +3761,8 @@ declare class TableCellDirective {
|
|
|
3761
3761
|
static ɵdir: _angular_core.ɵɵDirectiveDeclaration<TableCellDirective, "[lcTableCell]", never, { "columnKey": { "alias": "lcTableCell"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
3762
3762
|
}
|
|
3763
3763
|
|
|
3764
|
+
type TableCellClass = string | ((value: unknown, row: Record<string, unknown>, column: TableColumn, rowIndex: number) => string);
|
|
3765
|
+
type TableCellStyle = Record<string, string> | ((value: unknown, row: Record<string, unknown>, column: TableColumn, rowIndex: number) => Record<string, string>);
|
|
3764
3766
|
interface TableColumn {
|
|
3765
3767
|
key: string;
|
|
3766
3768
|
label: string;
|
|
@@ -3770,6 +3772,10 @@ interface TableColumn {
|
|
|
3770
3772
|
width?: string;
|
|
3771
3773
|
/** Optional CSS class(es) applied to both th and td cells */
|
|
3772
3774
|
cssClass?: string;
|
|
3775
|
+
/** Optional CSS class(es) for td cells only (string or resolver callback) */
|
|
3776
|
+
cellClass?: TableCellClass;
|
|
3777
|
+
/** Optional inline styles for td cells only (object or resolver callback) */
|
|
3778
|
+
cellStyle?: TableCellStyle;
|
|
3773
3779
|
/** Optional tooltip shown on hover over the column header */
|
|
3774
3780
|
tooltip?: string;
|
|
3775
3781
|
/** Optional formatter for cell output when no custom template is used */
|
|
@@ -3805,6 +3811,7 @@ type TableSize = 'sm' | 'md' | 'lg';
|
|
|
3805
3811
|
* - Size presets (sm, md, lg)
|
|
3806
3812
|
* - Hoverable row highlighting
|
|
3807
3813
|
* - Per-column formatter callbacks for display values
|
|
3814
|
+
* - Per-cell class/style callbacks for conditional styling
|
|
3808
3815
|
* - Custom cell templates via content projection
|
|
3809
3816
|
* - Composed cells (e.g. avatar + badge + actions)
|
|
3810
3817
|
* - Responsive horizontal scrolling
|
|
@@ -3913,6 +3920,8 @@ declare class TableComponent {
|
|
|
3913
3920
|
getHeaderClasses(column: TableColumn): string;
|
|
3914
3921
|
getCellValue(row: Record<string, unknown>, columnKey: string): unknown;
|
|
3915
3922
|
getFormattedCellValue(row: Record<string, unknown>, column: TableColumn, relativeRowIndex: number): unknown;
|
|
3923
|
+
getCellClasses(row: Record<string, unknown>, column: TableColumn, relativeRowIndex: number): string;
|
|
3924
|
+
getCellStyles(row: Record<string, unknown>, column: TableColumn, relativeRowIndex: number): Record<string, string> | null;
|
|
3916
3925
|
getCellTemplate(columnKey: string): TableCellDirective | undefined;
|
|
3917
3926
|
hasCustomTemplate(columnKey: string): boolean;
|
|
3918
3927
|
onRowClick(row: Record<string, unknown>): void;
|