@truenas/ui-components 0.4.8 → 0.4.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/package.json
CHANGED
|
@@ -4711,6 +4711,11 @@ declare class TnMenuTriggerDirective implements OnDestroy {
|
|
|
4711
4711
|
tnMenuPosition: _angular_core.InputSignal<"below" | "above" | "before" | "after">;
|
|
4712
4712
|
private overlayRef?;
|
|
4713
4713
|
private isMenuOpen;
|
|
4714
|
+
/**
|
|
4715
|
+
* Whether the menu is currently open. Exposed (with `exportAs: 'tnMenuTrigger'`) so a template
|
|
4716
|
+
* can reflect the state — e.g. keeping a row's action button visible while its menu is open.
|
|
4717
|
+
*/
|
|
4718
|
+
readonly isOpen: _angular_core.Signal<boolean>;
|
|
4714
4719
|
private itemClickSub?;
|
|
4715
4720
|
/**
|
|
4716
4721
|
* RxJS subscriptions for the current overlay's `backdropClick()` and
|
|
@@ -6324,6 +6329,12 @@ declare class TnTableComponent<T = unknown> implements OnInit {
|
|
|
6324
6329
|
displayedColumns: _angular_core.InputSignal<string[]>;
|
|
6325
6330
|
trackBy: _angular_core.InputSignal<((index: number, item: T) => unknown) | undefined>;
|
|
6326
6331
|
emptyMessage: _angular_core.InputSignal<string>;
|
|
6332
|
+
/**
|
|
6333
|
+
* Optional second line under `emptyMessage`, for empty states that carry both a headline and an
|
|
6334
|
+
* explanation (e.g. "No search results" plus what to try instead). Omitted when empty, so tables
|
|
6335
|
+
* with a single-line empty state are unaffected.
|
|
6336
|
+
*/
|
|
6337
|
+
emptyDescription: _angular_core.InputSignal<string>;
|
|
6327
6338
|
emptyIcon: _angular_core.InputSignal<string>;
|
|
6328
6339
|
selectable: _angular_core.InputSignal<boolean>;
|
|
6329
6340
|
expandable: _angular_core.InputSignal<boolean>;
|
|
@@ -6389,6 +6400,47 @@ declare class TnTableComponent<T = unknown> implements OnInit {
|
|
|
6389
6400
|
* details" patterns. Independent of `selectable` (checkbox) and `expandable`.
|
|
6390
6401
|
*/
|
|
6391
6402
|
clickable: _angular_core.InputSignal<boolean>;
|
|
6403
|
+
/**
|
|
6404
|
+
* When true, activating a row (click or Enter/Space) toggles its expansion, in addition to the
|
|
6405
|
+
* chevron. Requires `clickable` — that is what makes rows activatable at all — and `expandable`;
|
|
6406
|
+
* rows the `isRowExpandable` predicate rejects are unaffected, since `toggleRowExpansion` gates
|
|
6407
|
+
* on it. `rowClick` still emits, so a consumer can both expand and react to the click.
|
|
6408
|
+
*/
|
|
6409
|
+
expandOnRowClick: _angular_core.InputSignal<boolean>;
|
|
6410
|
+
/**
|
|
6411
|
+
* When true, expanding a row collapses whichever row was expanded before, so at most one detail
|
|
6412
|
+
* row is open at a time. Default (false) allows any number.
|
|
6413
|
+
*/
|
|
6414
|
+
singleExpand: _angular_core.InputSignal<boolean>;
|
|
6415
|
+
/**
|
|
6416
|
+
* Lays the table out `fixed` at full width, so every column without an explicit `[width]` gets
|
|
6417
|
+
* an equal share and none can grow to dominate the row.
|
|
6418
|
+
*
|
|
6419
|
+
* Cells wrap regardless of this (that is the table's default), so reach for it only when equal
|
|
6420
|
+
* columns are actually wanted: it gives up the `auto` layout's content-proportional sizing,
|
|
6421
|
+
* which a table with one long text column among short ones usually wants to keep.
|
|
6422
|
+
*/
|
|
6423
|
+
fixedLayout: _angular_core.InputSignal<boolean>;
|
|
6424
|
+
/**
|
|
6425
|
+
* Smallest width a column is allowed to shrink to before the host scrolls horizontally instead.
|
|
6426
|
+
* Any CSS length.
|
|
6427
|
+
*
|
|
6428
|
+
* `fixedLayout` makes the table fit its container exactly — so without a floor a narrow viewport
|
|
6429
|
+
* just keeps shrinking the columns, wrapping every cell to a couple of characters per line:
|
|
6430
|
+
* technically visible, unreadable, and never scrollable. The floor is derived as this times the
|
|
6431
|
+
* column count, so it scales with the table rather than needing a hand-picked number per page.
|
|
6432
|
+
*
|
|
6433
|
+
* Only applies with `fixedLayout`. Without it the table lays out `auto`, sizing to its content
|
|
6434
|
+
* and overflowing the host — which scrolls on its own.
|
|
6435
|
+
*/
|
|
6436
|
+
minColumnWidth: _angular_core.InputSignal<string>;
|
|
6437
|
+
/**
|
|
6438
|
+
* Explicit width floor, overriding the {@link minColumnWidth} derivation. Any CSS length. Reach
|
|
6439
|
+
* for this only when a specific table needs a floor its column count doesn't imply.
|
|
6440
|
+
*/
|
|
6441
|
+
minWidth: _angular_core.InputSignal<string>;
|
|
6442
|
+
/** The floor actually applied to the table — explicit if given, else derived. */
|
|
6443
|
+
protected readonly resolvedMinWidth: _angular_core.Signal<string | null>;
|
|
6392
6444
|
sortChange: _angular_core.OutputEmitterRef<TnSortEvent>;
|
|
6393
6445
|
selectionChange: _angular_core.OutputEmitterRef<T[]>;
|
|
6394
6446
|
/** Emits the row when a clickable row is activated (click or Enter/Space). */
|
|
@@ -6402,8 +6454,13 @@ declare class TnTableComponent<T = unknown> implements OnInit {
|
|
|
6402
6454
|
rowDoubleClick: _angular_core.OutputEmitterRef<T>;
|
|
6403
6455
|
columnDefs: _angular_core.Signal<readonly TnTableColumnDirective[]>;
|
|
6404
6456
|
detailRowDef: _angular_core.Signal<TnDetailRowDefDirective | undefined>;
|
|
6405
|
-
|
|
6406
|
-
|
|
6457
|
+
/**
|
|
6458
|
+
* Sorted column and direction. Two-way bindable (`[(sortColumn)]`), so a consumer that owns the
|
|
6459
|
+
* sort — a data provider, a table destroyed and rebuilt when its list empties out — can restore
|
|
6460
|
+
* the header's arrow instead of reaching in and setting the signal from an effect.
|
|
6461
|
+
*/
|
|
6462
|
+
sortColumn: _angular_core.ModelSignal<string>;
|
|
6463
|
+
sortDirection: _angular_core.ModelSignal<"" | "desc" | "asc">;
|
|
6407
6464
|
/**
|
|
6408
6465
|
* Set of currently expanded row references.
|
|
6409
6466
|
* Note: uses object identity. If the consumer replaces the data array
|
|
@@ -6434,6 +6491,14 @@ declare class TnTableComponent<T = unknown> implements OnInit {
|
|
|
6434
6491
|
canExpandRow(row: T): boolean;
|
|
6435
6492
|
toggleRowExpansion(row: T): void;
|
|
6436
6493
|
isRowExpanded(row: T): boolean;
|
|
6494
|
+
/**
|
|
6495
|
+
* Whether the row element itself acts as the expand/collapse control, which is what makes an
|
|
6496
|
+
* `aria-expanded` on it meaningful: a screen-reader user who focuses the row and presses Enter
|
|
6497
|
+
* otherwise gets no announcement that anything expanded, since only the chevron carries the
|
|
6498
|
+
* state. Also requires `clickable` — without it the row isn't activatable and
|
|
6499
|
+
* {@link onRowClick} returns before toggling anything.
|
|
6500
|
+
*/
|
|
6501
|
+
isRowExpandTrigger(row: T): boolean;
|
|
6437
6502
|
isRowActive(row: T): boolean;
|
|
6438
6503
|
onRowClick(row: T): void;
|
|
6439
6504
|
onRowDoubleClick(row: T): void;
|
|
@@ -6444,7 +6509,7 @@ declare class TnTableComponent<T = unknown> implements OnInit {
|
|
|
6444
6509
|
getColumnDef(columnName: string): TnTableColumnDirective | undefined;
|
|
6445
6510
|
getCellValue(row: T, column: string): unknown;
|
|
6446
6511
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<TnTableComponent<any>, never>;
|
|
6447
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<TnTableComponent<any>, "tn-table", never, { "dataSource": { "alias": "dataSource"; "required": false; "isSignal": true; }; "displayedColumns": { "alias": "displayedColumns"; "required": false; "isSignal": true; }; "trackBy": { "alias": "trackBy"; "required": false; "isSignal": true; }; "emptyMessage": { "alias": "emptyMessage"; "required": false; "isSignal": true; }; "emptyIcon": { "alias": "emptyIcon"; "required": false; "isSignal": true; }; "selectable": { "alias": "selectable"; "required": false; "isSignal": true; }; "expandable": { "alias": "expandable"; "required": false; "isSignal": true; }; "bordered": { "alias": "bordered"; "required": false; "isSignal": true; }; "isRowExpandable": { "alias": "isRowExpandable"; "required": false; "isSignal": true; }; "activeRow": { "alias": "activeRow"; "required": false; "isSignal": true; }; "activeWhen": { "alias": "activeWhen"; "required": false; "isSignal": true; }; "activeBg": { "alias": "activeBg"; "required": false; "isSignal": true; }; "activeIndicator": { "alias": "activeIndicator"; "required": false; "isSignal": true; }; "loading": { "alias": "loading"; "required": false; "isSignal": true; }; "loadingMessage": { "alias": "loadingMessage"; "required": false; "isSignal": true; }; "clickable": { "alias": "clickable"; "required": false; "isSignal": true; }; }, { "sortChange": "sortChange"; "selectionChange": "selectionChange"; "rowClick": "rowClick"; "rowDoubleClick": "rowDoubleClick"; }, ["columnDefs", "detailRowDef"], never, true, [{ directive: typeof TnTestIdDirective; inputs: { "tnTestId": "testId"; }; outputs: {}; }]>;
|
|
6512
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<TnTableComponent<any>, "tn-table", never, { "dataSource": { "alias": "dataSource"; "required": false; "isSignal": true; }; "displayedColumns": { "alias": "displayedColumns"; "required": false; "isSignal": true; }; "trackBy": { "alias": "trackBy"; "required": false; "isSignal": true; }; "emptyMessage": { "alias": "emptyMessage"; "required": false; "isSignal": true; }; "emptyDescription": { "alias": "emptyDescription"; "required": false; "isSignal": true; }; "emptyIcon": { "alias": "emptyIcon"; "required": false; "isSignal": true; }; "selectable": { "alias": "selectable"; "required": false; "isSignal": true; }; "expandable": { "alias": "expandable"; "required": false; "isSignal": true; }; "bordered": { "alias": "bordered"; "required": false; "isSignal": true; }; "isRowExpandable": { "alias": "isRowExpandable"; "required": false; "isSignal": true; }; "activeRow": { "alias": "activeRow"; "required": false; "isSignal": true; }; "activeWhen": { "alias": "activeWhen"; "required": false; "isSignal": true; }; "activeBg": { "alias": "activeBg"; "required": false; "isSignal": true; }; "activeIndicator": { "alias": "activeIndicator"; "required": false; "isSignal": true; }; "loading": { "alias": "loading"; "required": false; "isSignal": true; }; "loadingMessage": { "alias": "loadingMessage"; "required": false; "isSignal": true; }; "clickable": { "alias": "clickable"; "required": false; "isSignal": true; }; "expandOnRowClick": { "alias": "expandOnRowClick"; "required": false; "isSignal": true; }; "singleExpand": { "alias": "singleExpand"; "required": false; "isSignal": true; }; "fixedLayout": { "alias": "fixedLayout"; "required": false; "isSignal": true; }; "minColumnWidth": { "alias": "minColumnWidth"; "required": false; "isSignal": true; }; "minWidth": { "alias": "minWidth"; "required": false; "isSignal": true; }; "sortColumn": { "alias": "sortColumn"; "required": false; "isSignal": true; }; "sortDirection": { "alias": "sortDirection"; "required": false; "isSignal": true; }; }, { "sortChange": "sortChange"; "selectionChange": "selectionChange"; "rowClick": "rowClick"; "rowDoubleClick": "rowDoubleClick"; "sortColumn": "sortColumnChange"; "sortDirection": "sortDirectionChange"; }, ["columnDefs", "detailRowDef"], never, true, [{ directive: typeof TnTestIdDirective; inputs: { "tnTestId": "testId"; }; outputs: {}; }]>;
|
|
6448
6513
|
}
|
|
6449
6514
|
|
|
6450
6515
|
/**
|
|
@@ -9832,6 +9897,12 @@ declare class TnSidePanelComponent implements OnDestroy {
|
|
|
9832
9897
|
* Test-id applied to the panel's close (×) button.
|
|
9833
9898
|
*/
|
|
9834
9899
|
closeButtonTestId: _angular_core.InputSignal<string | undefined>;
|
|
9900
|
+
/**
|
|
9901
|
+
* Accessible name for the close button. Defaults to "Dismiss"; override to translate it, or to
|
|
9902
|
+
* name what is being closed ("Close Add Dataset form") — a screen-reader user tabbing to it out
|
|
9903
|
+
* of context otherwise hears only "Dismiss".
|
|
9904
|
+
*/
|
|
9905
|
+
closeButtonAriaLabel: _angular_core.InputSignal<string>;
|
|
9835
9906
|
opened: _angular_core.OutputEmitterRef<void>;
|
|
9836
9907
|
closed: _angular_core.OutputEmitterRef<void>;
|
|
9837
9908
|
private actionContent;
|
|
@@ -9848,7 +9919,7 @@ declare class TnSidePanelComponent implements OnDestroy {
|
|
|
9848
9919
|
private restoreFocus;
|
|
9849
9920
|
private registerMdiIcons;
|
|
9850
9921
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<TnSidePanelComponent, never>;
|
|
9851
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<TnSidePanelComponent, "tn-side-panel", never, { "open": { "alias": "open"; "required": false; "isSignal": true; }; "title": { "alias": "title"; "required": false; "isSignal": true; }; "width": { "alias": "width"; "required": false; "isSignal": true; }; "hasBackdrop": { "alias": "hasBackdrop"; "required": false; "isSignal": true; }; "closeOnBackdropClick": { "alias": "closeOnBackdropClick"; "required": false; "isSignal": true; }; "closeOnEscape": { "alias": "closeOnEscape"; "required": false; "isSignal": true; }; "closeGuard": { "alias": "closeGuard"; "required": false; "isSignal": true; }; "testId": { "alias": "testId"; "required": false; "isSignal": true; }; "closeButtonTestId": { "alias": "closeButtonTestId"; "required": false; "isSignal": true; }; }, { "open": "openChange"; "opened": "opened"; "closed": "closed"; }, ["actionContent"], ["[tnSidePanelHeaderAction]", "*", "[tnSidePanelAction]"], true, never>;
|
|
9922
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<TnSidePanelComponent, "tn-side-panel", never, { "open": { "alias": "open"; "required": false; "isSignal": true; }; "title": { "alias": "title"; "required": false; "isSignal": true; }; "width": { "alias": "width"; "required": false; "isSignal": true; }; "hasBackdrop": { "alias": "hasBackdrop"; "required": false; "isSignal": true; }; "closeOnBackdropClick": { "alias": "closeOnBackdropClick"; "required": false; "isSignal": true; }; "closeOnEscape": { "alias": "closeOnEscape"; "required": false; "isSignal": true; }; "closeGuard": { "alias": "closeGuard"; "required": false; "isSignal": true; }; "testId": { "alias": "testId"; "required": false; "isSignal": true; }; "closeButtonTestId": { "alias": "closeButtonTestId"; "required": false; "isSignal": true; }; "closeButtonAriaLabel": { "alias": "closeButtonAriaLabel"; "required": false; "isSignal": true; }; }, { "open": "openChange"; "opened": "opened"; "closed": "closed"; }, ["actionContent"], ["[tnSidePanelHeaderAction]", "*", "[tnSidePanelAction]"], true, never>;
|
|
9852
9923
|
}
|
|
9853
9924
|
|
|
9854
9925
|
interface SidePanelHarnessFilters extends BaseHarnessFilters {
|