@coolon/angular-ui-powerups 16.1.0-alpha.335 → 16.1.0-alpha.336

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.
@@ -217,7 +217,11 @@ export declare abstract class AbstractTableModel<Row extends object> extends Gar
217
217
  addFooterRow<C>(component: ComponentType<C>, initialiseCallback?: (component: C) => void): FooterRowModel.Impl;
218
218
  addTemplateColumn<V>(columnId: string): CustomTemplateColumnModel<Row>;
219
219
  addRowClass(className: string, predicate: (row: Row) => boolean, options?: DependsOnOptions): void;
220
- addRowAttribute(attributeName: string, getValue: (row: Row) => string): void;
220
+ /**
221
+ * Gives each row an attribute named [attributeName]. A row whose value is nil goes without the
222
+ * attribute, rather than carrying the text "undefined".
223
+ */
224
+ addRowAttribute(attributeName: string, getValue: (row: Row) => string | undefined): void;
221
225
  getRowClasses(row: Row): string[];
222
226
  getRowAttributes(row: Row): Record<string, string>;
223
227
  protected addColumn<C extends ColumnModel<Row>>(column: C, position?: ColumnOrderManager.Position): C;
@@ -246,5 +250,9 @@ export declare abstract class AbstractTableModel<Row extends object> extends Gar
246
250
  scrollToTop(): void;
247
251
  /** Called by the table body, which scrolls when a page asks with {@link scrollToTop}. */
248
252
  _onScrollToTop(scroll: () => void): Disposable;
253
+ /**
254
+ * A click selects its row only when the selection model accepts that row, as the row's hover and
255
+ * cursor already say. Row click listeners hear of every click.
256
+ */
249
257
  _notifyCellClicked(columnModel: ColumnModel<Row>, row: Row): void;
250
258
  }
@@ -17,6 +17,18 @@ export declare class TreeExpansionModel<T> extends GarbageCollector implements O
17
17
  canCollapse(node: T): boolean;
18
18
  isCollapsed(node: T): boolean;
19
19
  isExpanded(node: T): boolean;
20
+ /** Shows the children of every node, in one change however many nodes were collapsed. */
21
+ expandAll(): void;
22
+ /** Hides the children of every node that has any, in one change, so the table redraws once. */
23
+ collapseAll(): void;
24
+ /**
25
+ * Expands every ancestor of [node], so the node shows. Its own children stay as they were.
26
+ */
20
27
  ensureAncestorsAndSelfVisible(node: T): void;
28
+ /**
29
+ * Visits every node of the tree, collapsed or not. A node under a collapsed parent has not been
30
+ * shown, so it has no decorator until its parent's children are read; walking from the roots reads them.
31
+ */
32
+ private forEachNode;
21
33
  private updatePredicate;
22
34
  }
@@ -19,6 +19,8 @@ export declare class TreeTableModel<Row extends object> extends AbstractTableMod
19
19
  collapse(node: Row): void;
20
20
  isCollapsed(node: Row): boolean;
21
21
  ensureAncestorsAndSelfVisible(node: Row): void;
22
+ expandAll(): void;
23
+ collapseAll(): void;
22
24
  isExpanded(row: Row): boolean;
23
25
  }
24
26
  export declare namespace TreeTableModel {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@coolon/angular-ui-powerups",
3
- "version": "16.1.0-alpha.335",
3
+ "version": "16.1.0-alpha.336",
4
4
  "peerDependencies": {
5
5
  "@angular/animations": "^16.2.9",
6
6
  "@angular/common": "^16.2.9",