@zambon-dev/ui 1.4.1 → 1.5.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.
@@ -4,6 +4,10 @@ import { Observable, Subject } from "rxjs";
4
4
  import { AbstractControl, FormControl, FormGroup, FormGroupDirective, FormGroupName, ValidationErrors, ValidatorFn } from "@angular/forms";
5
5
  import { HttpErrorResponse, HttpResponse } from "@angular/common/http";
6
6
  import { ActivatedRoute, ActivatedRouteSnapshot } from "@angular/router";
7
+ /**
8
+ * Abstract base for the library's components. Gives subclasses a `destroy$` subject that emits
9
+ * and completes when the component is destroyed, for ending subscriptions with `takeUntil`.
10
+ */
7
11
  export declare abstract class BaseComponent implements OnDestroy {
8
12
  protected destroy$: Subject<boolean>;
9
13
  ngOnDestroy(): void;
@@ -34,6 +38,7 @@ export declare class ButtonComponent {
34
38
  readonly intent: InputSignal<ButtonIntent>;
35
39
  /** Native button type. `submit` works because the rendered button is inside the host's form. */
36
40
  readonly type: InputSignal<'button' | 'submit' | 'reset'>;
41
+ /** Disables the native button, so it cannot be clicked or focused. Defaults to `false`. */
37
42
  readonly disabled: InputSignal<boolean>;
38
43
  /** Shows a spinner, announces `aria-busy` and blocks activation -- by the keyboard too. */
39
44
  readonly loading: InputSignal<boolean>;
@@ -127,6 +132,12 @@ export type DataGridConfigs = GridConfigs & {
127
132
  hideBorders?: boolean;
128
133
  hideColumnHeaders?: boolean;
129
134
  multiSelect?: boolean;
135
+ /**
136
+ * Track size of the selection column. Defaults to `min-content`, the checkbox plus the row's
137
+ * padding. A range such as `minmax(1.5rem, min-content)` only reaches its upper bound when the
138
+ * grid has width to spare; in a narrow grid it stays at the minimum, and the row's padding then
139
+ * leaves the checkbox no room at all.
140
+ */
130
141
  multiSelectSize?: string;
131
142
  selectOnClick?: boolean;
132
143
  showMessageOnEmpty?: boolean;
@@ -299,26 +310,55 @@ export interface ITabView {
299
310
  declare namespace catalog_select_component_d_exports {
300
311
  export { CatalogSelectComponent };
301
312
  }
313
+ /**
314
+ * A labelled searchable dropdown. It lists entries from a static `entriesList` or from a
315
+ * `searchEndpoint`, writes the chosen value to `controlName` and its text to `displayControlName`
316
+ * in the surrounding form group.
317
+ */
302
318
  export declare class CatalogSelectComponent extends BaseComponent implements OnInit, AfterViewInit, OnDestroy {
303
319
  protected bodyMouseDown(event: MouseEvent): void;
304
320
  protected bodyMouseUp(event: MouseEvent): void;
305
321
  private readonly dropdownTemplate;
306
322
  private readonly inputElement;
323
+ /** Passed to the inner `lib-form-input`, which does not apply it yet. Defaults to `false`. */
307
324
  readonly autofocus: InputSignal<boolean>;
325
+ /** Control in the surrounding form group that receives the chosen entry's value. Required. */
308
326
  readonly controlName: InputSignal<string>;
327
+ /** Control in the surrounding form group that receives the chosen entry's text, which the input shows. Required. */
309
328
  readonly displayControlName: InputSignal<string>;
329
+ /** Property of each `entriesList` item that holds its text. Defaults to `display`. */
310
330
  readonly displayProperty: InputSignal<string>;
331
+ /**
332
+ * Static entries to choose from when there is no `searchEndpoint`. Each item's text and value
333
+ * are read from `displayProperty` and `valueProperty`; the text may be an observable, such as
334
+ * a translation. Setting a new list refreshes the dropdown.
335
+ */
311
336
  set entriesList(value: any[] | {
312
337
  key: number;
313
338
  value: Observable<any> | string;
314
339
  }[] | null | undefined);
340
+ /**
341
+ * Extra filters sent to `searchEndpoint` with every search. A changed filter set runs the search
342
+ * again. Defaults to none.
343
+ */
315
344
  set filters(value: {
316
345
  [id: string]: any;
317
346
  });
347
+ /** Text of the label, as a translation key. Defaults to empty. */
318
348
  readonly label: InputSignal<string>;
349
+ /** Maximum number of entries requested from `searchEndpoint`. Defaults to `100`. */
319
350
  readonly maxEntries: InputSignal<number>;
351
+ /**
352
+ * Characters the user must type before a search runs, when the endpoint asks for search
353
+ * criteria. Defaults to `3`.
354
+ */
320
355
  readonly minimumLengthSearch: InputSignal<number>;
356
+ /** Hint shown in small italics under the field, as a translation key. Defaults to empty. */
321
357
  readonly notes: InputSignal<string>;
358
+ /**
359
+ * Blocks typing, hides the clear button and stops the dropdown opening on focus; a click still
360
+ * opens it. Defaults to `false`.
361
+ */
322
362
  readonly readOnly: InputSignal<boolean>;
323
363
  /**
324
364
  * Whether the field accepts typing to narrow the list.
@@ -333,10 +373,16 @@ export declare class CatalogSelectComponent extends BaseComponent implements OnI
333
373
  * until it is given criteria, and there would be no way left to type any.
334
374
  */
335
375
  readonly searchable: InputSignal<boolean>;
376
+ /**
377
+ * URL the entries are searched from, with a POST of `{ maxResults, criteria, filters }`. When
378
+ * empty, `entriesList` is used instead. Changing it starts the search over.
379
+ */
336
380
  set searchEndpoint(value: string | undefined);
381
+ /** Messages per validation error key of `controlName`, as translation keys. Defaults to none. */
337
382
  readonly validations: InputSignal<{
338
383
  [id: string]: string;
339
384
  }>;
385
+ /** Property of each `entriesList` item that holds its value. Defaults to `value`. */
340
386
  readonly valueProperty: InputSignal<string>;
341
387
  protected readonly displayedEntries: WritableSignal<ICatalogEntry[]>;
342
388
  protected readonly focusedIndex: WritableSignal<number>;
@@ -369,13 +415,16 @@ export declare class CatalogSelectComponent extends BaseComponent implements OnI
369
415
  private searchSubject;
370
416
  private viewContainerRef;
371
417
  private wasClickedOutside;
418
+ /** The static entries to choose from. */
372
419
  get entriesList(): any[] | {
373
420
  key: number;
374
421
  value: Observable<any> | string;
375
422
  }[] | null | undefined;
423
+ /** The filters sent to `searchEndpoint`. */
376
424
  get filters(): {
377
425
  [id: string]: any;
378
426
  } | undefined;
427
+ /** The URL the entries are searched from. */
379
428
  get searchEndpoint(): string | undefined;
380
429
  protected get activeDescendantId(): string | null;
381
430
  protected get displayControl(): FormControl;
@@ -523,6 +572,10 @@ export declare class CatalogSelectComponent extends BaseComponent implements OnI
523
572
  };
524
573
  }, {}, never, never, true, never>;
525
574
  }
575
+ /**
576
+ * Searches a catalog endpoint for `lib-catalog-select`. Sends a POST of
577
+ * `{ maxResults, criteria, filters }` and returns the matching entries.
578
+ */
526
579
  export declare class CatalogService {
527
580
  private http;
528
581
  search(endpoint: string, maxResults: number, criteria?: string, filters?: {
@@ -531,6 +584,11 @@ export declare class CatalogService {
531
584
  static ɵfac: i0.ɵɵFactoryDeclaration<CatalogService, never>;
532
585
  static ɵprov: i0.ɵɵInjectableDeclaration<any>;
533
586
  }
587
+ /**
588
+ * Base for a service that loads, caches and saves one entity for a details view. It reads the
589
+ * record id from the route's `id` parameter; extend it and implement `loadModel`, `saveModel`
590
+ * and `getTitle`.
591
+ */
534
592
  export declare abstract class DataProviderService<TEntityModel> implements OnDestroy {
535
593
  protected activatedRoute: ActivatedRoute;
536
594
  protected destroy$: Subject<boolean>;
@@ -725,10 +783,16 @@ export declare abstract class MultiSelectResultDataset extends GridDataset {
725
783
  static ɵfac: i0.ɵɵFactoryDeclaration<MultiSelectResultDataset, never>;
726
784
  static ɵprov: i0.ɵɵInjectableDeclaration<any>;
727
785
  }
786
+ /** An empty service with no members. Nothing in the package uses it. */
728
787
  export declare class FormGroupService {
729
788
  static ɵfac: i0.ɵɵFactoryDeclaration<FormGroupService, never>;
730
789
  static ɵprov: i0.ɵɵInjectableDeclaration<any>;
731
790
  }
791
+ /**
792
+ * Holds the state of one form view: the form group, the loaded model, view or edit mode and the
793
+ * loading flag. Provide it on the view; the library's form fields read it to decide whether to
794
+ * show inputs or read-only values.
795
+ */
732
796
  export declare class FormService {
733
797
  fieldRefreshed: EventEmitter<{
734
798
  fieldName: string;
@@ -765,6 +829,10 @@ export declare class FormService {
765
829
  static ɵfac: i0.ɵɵFactoryDeclaration<FormService, never>;
766
830
  static ɵprov: i0.ɵɵInjectableDeclaration<any>;
767
831
  }
832
+ /**
833
+ * Loads and tracks the menus of `lib-sidebar`: the tree, the selected item and the collapsed and
834
+ * open states. Extend it and implement `loadMenus`, `getMenuFromUrl` and `getUserProfile`.
835
+ */
768
836
  export declare abstract class SidebarService {
769
837
  childrenFailed: EventEmitter<SidebarMenu>;
770
838
  childrenLoaded: EventEmitter<SidebarMenu>;
@@ -807,11 +875,25 @@ export declare abstract class SidebarService {
807
875
  declare namespace data_grid_component_d_exports {
808
876
  export { DataGridComponent };
809
877
  }
878
+ /**
879
+ * A virtual-scrolling grid driven by the `DataGridDataset` provided around it. The dataset holds
880
+ * the columns, rows, paging and selection; the grid renders them, loads the next page as the user
881
+ * scrolls, and shows loading, empty and error messages.
882
+ */
810
883
  export declare class DataGridComponent extends BaseComponent implements OnInit, AfterViewInit, OnDestroy {
811
884
  private readonly bodyElement;
812
885
  private readonly viewport;
886
+ /** Disables the rows, so they cannot be focused or selected. Defaults to `false`. */
813
887
  readonly disabled: InputSignal<boolean>;
888
+ /**
889
+ * When `true`, the grid does not load rows on init and shows a prompt until something else
890
+ * loads the dataset, such as a search. Defaults to `false`.
891
+ */
814
892
  readonly lazyLoadRows: InputSignal<boolean>;
893
+ /**
894
+ * Shows a bar above the header for content projected with the `buttons` attribute, and drops
895
+ * the grid's borders. Defaults to `false`.
896
+ */
815
897
  readonly showButtons: InputSignal<boolean>;
816
898
  protected dataGridDataset: DataGridDataset;
817
899
  protected readonly hasFailed: WritableSignal<boolean>;
@@ -883,9 +965,16 @@ export declare class DataGridComponent extends BaseComponent implements OnInit,
883
965
  declare namespace data_grid_row_component_d_exports {
884
966
  export { DataGridRowComponent };
885
967
  }
968
+ /**
969
+ * One row of `lib-data-grid`. Renders a cell per dataset column, using the column's template when
970
+ * it has one, plus a selection checkbox when the grid allows multiple selection.
971
+ */
886
972
  export declare class DataGridRowComponent extends BaseComponent implements OnInit {
973
+ /** Disables the row, so clicking it neither focuses nor selects it. Defaults to `false`. */
887
974
  disabled: boolean;
975
+ /** Marks the first rendered row, which measures the column widths for the header. Defaults to `false`. */
888
976
  isFirstRow: boolean;
977
+ /** The record this row shows. Setting it refreshes the row's selected state. */
889
978
  set rowData(value: any);
890
979
  /**
891
980
  * The row's index in the data, which is what the zebra stripe follows. Its position among the
@@ -893,12 +982,18 @@ export declare class DataGridRowComponent extends BaseComponent implements OnIni
893
982
  * the DOM swapped on every row whenever that window moved by an odd number of rows.
894
983
  */
895
984
  readonly rowIndex: InputSignal<number>;
985
+ /** Emits the width in pixels of the selection checkbox cell whenever it changes. */
896
986
  selectionResized: EventEmitter<number>;
987
+ /**
988
+ * Makes this row the dataset's focused row. In a multi-select grid that selects on click, it
989
+ * also syncs the checkbox. Runs on a click on the row; does nothing while disabled.
990
+ */
897
991
  setFocus(): void;
898
992
  protected dataGridDataset: DataGridDataset;
899
993
  protected readonly selected: WritableSignal<boolean>;
900
994
  private _rowData;
901
995
  private elementRef;
996
+ /** The record this row shows. */
902
997
  get rowData(): any;
903
998
  protected get columns(): IGridColumn[];
904
999
  private get isLaidOut();
@@ -937,26 +1032,57 @@ export declare class DataGridRowComponent extends BaseComponent implements OnIni
937
1032
  declare namespace form_input_component_d_exports {
938
1033
  export { FormInputComponent };
939
1034
  }
1035
+ /**
1036
+ * A single form field without a label. It edits a control of the surrounding `[formGroup]` named by
1037
+ * `controlName`, or shows `fixedValue` when there is no control. While the form is disabled and
1038
+ * the `FormService` is not in edit mode, it shows the value as text instead of an input.
1039
+ */
940
1040
  export declare class FormInputComponent extends BaseComponent implements OnInit {
1041
+ /** Accepted for parity with `lib-form-input-group`, but this component's template does not apply it. Defaults to `false`. */
941
1042
  readonly autofocus: InputSignal<boolean>;
1043
+ /** Name of the control in the surrounding form group to edit. Leave empty to show `fixedValue` instead. */
942
1044
  readonly controlName: InputSignal<string>;
1045
+ /** Control whose value is shown in read-only mode instead of `controlName`'s, for example a display name next to an ID. */
943
1046
  readonly disabledControlName: InputSignal<string | undefined>;
1047
+ /** Styles a read-only input like a disabled one. Defaults to `true`. */
944
1048
  readonly displayReadOnlyAsDisabled: InputSignal<boolean>;
1049
+ /** Shows the field in its error style. Defaults to `false`. */
945
1050
  readonly invalid: InputSignal<boolean>;
1051
+ /** Disables the input when it shows `fixedValue` (no `controlName`). Has no effect on a form control. Defaults to `true`. */
946
1052
  readonly isDisabled: InputSignal<boolean>;
1053
+ /** Lets the field grow to the full height of its container, for example a tall textarea. Defaults to `false`. */
947
1054
  readonly isFullHeight: InputSignal<boolean>;
1055
+ /** Maximum number of characters for text inputs and textareas. No limit by default. */
948
1056
  readonly maxLength: InputSignal<number | undefined>;
1057
+ /** Minimum value for a `number` field. No minimum by default. */
949
1058
  readonly min: InputSignal<number | undefined>;
1059
+ /** Makes a control-bound text-like input read-only while it stays focusable. Defaults to `false`. */
950
1060
  readonly readOnly: InputSignal<boolean>;
1061
+ /** Visible number of lines for a `textarea` field. */
951
1062
  readonly rows: InputSignal<number | undefined>;
1063
+ /** Increment for a `number` field. Defaults to `1`. */
952
1064
  readonly step: InputSignal<number>;
1065
+ /**
1066
+ * Kind of field: `textarea`, `checkbox` (shown as a switch), or any native input type such as
1067
+ * `text`, `number`, `date` or `datetime-local`. Defaults to `text`.
1068
+ */
953
1069
  readonly type: InputSignal<string>;
1070
+ /** Value shown and edited when there is no `controlName`. Supports two-way binding. */
954
1071
  readonly fixedValue: ModelSignal<any>;
1072
+ /**
1073
+ * Display format for the read-only value: a `DatePipe` pattern for date types, or a
1074
+ * `DecimalPipe` digits string for `number`. A `date` field defaults to `yyyy-MM-dd`.
1075
+ */
955
1076
  readonly format: ModelSignal<string | undefined>;
1077
+ /** Emits when the input loses focus. */
956
1078
  readonly blurred: OutputEmitterRef<void>;
1079
+ /** Emits the native `change` event of a checkbox that shows `fixedValue`. */
957
1080
  readonly changed: OutputEmitterRef<any>;
1081
+ /** Emits the new value when the user edits `fixedValue`. */
958
1082
  readonly fixedValueChanged: OutputEmitterRef<string>;
1083
+ /** Emits when the input gains focus. */
959
1084
  readonly focused: OutputEmitterRef<void>;
1085
+ /** Emits on every native `input` event, that is, each time the user types or toggles. */
960
1086
  readonly inputChanged: OutputEmitterRef<void>;
961
1087
  protected readonly formGroupDirective: FormGroupDirective;
962
1088
  protected readonly formGroupName: FormGroupName;
@@ -1084,24 +1210,49 @@ export declare class FormInputComponent extends BaseComponent implements OnInit
1084
1210
  declare namespace form_input_group_component_d_exports {
1085
1211
  export { FormInputGroupComponent };
1086
1212
  }
1213
+ /**
1214
+ * A labelled form field: a label, a `lib-form-input` (or your own template), its validation
1215
+ * messages and optional notes. It shows a placeholder while the field or the form is loading.
1216
+ */
1087
1217
  export declare class FormInputGroupComponent extends BaseComponent implements OnInit {
1218
+ /** Passed to the inner `lib-form-input`, which does not apply it yet. Defaults to `false`. */
1088
1219
  readonly autofocus: InputSignal<boolean>;
1220
+ /** Vertical alignment of the field in its cell: `start`, `center` or `end`. Defaults to `center`. */
1089
1221
  readonly alignContent: InputSignal<'center' | 'end' | 'start'>;
1222
+ /** Name of the control in the surrounding form group. Its errors and loading state drive the messages. Required. */
1090
1223
  readonly controlName: InputSignal<string>;
1224
+ /** Value passed to the inner `lib-form-input` as its `fixedValue`. */
1091
1225
  readonly fixedValue: InputSignal<any>;
1226
+ /** Display format passed to the inner `lib-form-input`: a date pattern or a number digits string. */
1092
1227
  readonly format: InputSignal<string | undefined>;
1228
+ /** Text of the label, as a translation key. Defaults to empty. */
1093
1229
  readonly label: InputSignal<string>;
1230
+ /** Passed to the inner `lib-form-input`; disables it only when it shows a fixed value. Defaults to `true`. */
1094
1231
  readonly isDisabled: InputSignal<boolean>;
1232
+ /** Lets the field grow to the full height of its container. Defaults to `false`. */
1095
1233
  readonly isFullHeight: InputSignal<boolean>;
1234
+ /** Maximum number of characters for text inputs and textareas. No limit by default. */
1096
1235
  readonly maxLength: InputSignal<number | undefined>;
1236
+ /** Minimum value for a `number` field. No minimum by default. */
1097
1237
  readonly min: InputSignal<number | undefined>;
1238
+ /** Hint shown in small italics under the field, as a translation key. Defaults to empty. */
1098
1239
  readonly notes: InputSignal<string>;
1240
+ /** Makes the input read-only while it stays focusable. Defaults to `false`. */
1099
1241
  readonly readOnly: InputSignal<boolean>;
1242
+ /** Visible number of lines for a `textarea` field. */
1100
1243
  readonly rows: InputSignal<number | undefined>;
1244
+ /** Shows the label column. When `false`, the field spans the full width. Defaults to `true`. */
1101
1245
  readonly showLabel: InputSignal<boolean>;
1246
+ /** Increment for a `number` field. Defaults to `1`. */
1102
1247
  readonly step: InputSignal<number>;
1248
+ /** Your own template to render in place of the default `lib-form-input`. */
1103
1249
  readonly template: InputSignal<TemplateRef<any> | undefined>;
1250
+ /** Kind of field, passed to the inner `lib-form-input`, for example `text`, `number`, `date`, `checkbox` or `textarea`. Defaults to `text`. */
1104
1251
  readonly type: InputSignal<string>;
1252
+ /**
1253
+ * Messages per validation error key, as translation keys, for example
1254
+ * `{ required: 'Validation-Required' }`. Only errors listed here show a message, once the control is touched.
1255
+ */
1105
1256
  readonly validations: InputSignal<{
1106
1257
  [id: string]: string;
1107
1258
  }>;
@@ -1225,8 +1376,13 @@ export declare class FormInputGroupComponent extends BaseComponent implements On
1225
1376
  declare namespace form_group_component_d_exports {
1226
1377
  export { FormGroupComponent };
1227
1378
  }
1379
+ /**
1380
+ * Groups related form fields under an optional heading. Project the fields as content.
1381
+ */
1228
1382
  export declare class FormGroupComponent {
1383
+ /** Adds the `expand` class to the host so the group grows to fill the available space. Defaults to `false`. */
1229
1384
  shouldExpand: boolean;
1385
+ /** Heading shown above the fields, as a translation key. No heading is shown when empty. */
1230
1386
  label: string;
1231
1387
  protected get hasTitle(): boolean;
1232
1388
  static ɵfac: i0.ɵɵFactoryDeclaration<FormGroupComponent, never>;
@@ -1244,11 +1400,17 @@ export declare class FormGroupComponent {
1244
1400
  declare namespace group_accordion_component_d_exports {
1245
1401
  export { GroupAccordionComponent };
1246
1402
  }
1403
+ /**
1404
+ * A titled section whose content the user can collapse and expand by clicking the title or
1405
+ * pressing Enter or Space on it. Starts expanded.
1406
+ */
1247
1407
  export declare class GroupAccordionComponent {
1248
1408
  private readonly containerElementRef;
1409
+ /** Title of the section, shown as given. Required. */
1249
1410
  readonly label: InputSignal<string>;
1250
1411
  private readonly _maxHeight;
1251
1412
  protected readonly collapsed: WritableSignal<boolean>;
1413
+ /** Height in pixels pinned on the content during the collapse animation, or `-1` when none is set. */
1252
1414
  readonly maxHeight: Signal<number>;
1253
1415
  protected onToggle(): void;
1254
1416
  private clearMaxHeight;
@@ -1265,15 +1427,31 @@ export declare class GroupAccordionComponent {
1265
1427
  declare namespace scroll_spy_directive_d_exports {
1266
1428
  export { ScrollSpyDirective };
1267
1429
  }
1430
+ /**
1431
+ * Tracks which section of a scrollable element is in view. Put it on the scrolling container;
1432
+ * it finds the descendant elements whose tag is listed in `spiedTags` and reports the index of
1433
+ * the current one as the user scrolls.
1434
+ */
1268
1435
  export declare class ScrollSpyDirective implements AfterViewInit {
1436
+ /**
1437
+ * Tag names (case-insensitive) of the elements that count as sections, for example
1438
+ * `['lib-group-accordion']`. Read once after the view initialises. Defaults to none.
1439
+ */
1269
1440
  spiedTags: Array<string>;
1441
+ /** Emits the zero-based index of the section in view whenever it changes. */
1270
1442
  activeSectionChange: EventEmitter<number>;
1271
1443
  private _el;
1272
1444
  private activeSection;
1273
1445
  private sections;
1274
1446
  ngAfterViewInit(): void;
1447
+ /** Handles the host's `scroll` event and selects the section at the current scroll position. */
1275
1448
  onScroll(event: any): void;
1449
+ /** Scrolls the host so the section at the given zero-based index is at the top. */
1276
1450
  scrollTo(section: number): void;
1451
+ /**
1452
+ * Marks the section at the given zero-based index as active and emits `activeSectionChange`
1453
+ * when it differs from the current one. Does not scroll.
1454
+ */
1277
1455
  select(section: number): void;
1278
1456
  private updateSections;
1279
1457
  static ɵfac: i0.ɵɵFactoryDeclaration<ScrollSpyDirective, never>;
@@ -1289,14 +1467,26 @@ export declare class ScrollSpyDirective implements AfterViewInit {
1289
1467
  declare namespace group_container_component_d_exports {
1290
1468
  export { GroupContainerComponent };
1291
1469
  }
1470
+ /**
1471
+ * A panel with a title bar, an optional icon and projected content. While `title` is empty the
1472
+ * title bar shows a loading spinner instead.
1473
+ */
1292
1474
  export declare class GroupContainerComponent {
1475
+ /** A scroll-spy directive in the view. The current template has none, so this stays unset. */
1293
1476
  scrollSpy: ScrollSpyDirective;
1477
+ /** The `lib-group-accordion` sections projected into the panel, at any depth. */
1294
1478
  sections: QueryList<GroupAccordionComponent>;
1479
+ /** The labels of the projected sections, in document order. */
1295
1480
  get titles(): string[];
1481
+ /** Zero-based index of the active section. Starts at `0`. */
1296
1482
  activeSection: number;
1483
+ /** Panel title, as a translation key. While empty, a loading spinner is shown in its place. */
1297
1484
  title?: string;
1485
+ /** Font Awesome icon class shown before the title, for example `fa-user`. Shown only with a title. */
1298
1486
  icon?: string;
1487
+ /** Sets the active section to the given zero-based index. */
1299
1488
  activeSectionChanged(index: number): void;
1489
+ /** Scrolls to the section at the given zero-based index. Needs `scrollSpy`, which the template does not provide. */
1300
1490
  scrollTo(section: number): void;
1301
1491
  static ɵfac: i0.ɵɵFactoryDeclaration<GroupContainerComponent, never>;
1302
1492
  static ɵcmp: i0.ɵɵComponentDeclaration<GroupContainerComponent, "lib-group-container", never, {
@@ -1313,12 +1503,22 @@ export declare class GroupContainerComponent {
1313
1503
  declare namespace group_scroll_spy_component_d_exports {
1314
1504
  export { GroupScrollSpyComponent };
1315
1505
  }
1506
+ /**
1507
+ * A scrollable container with a strip of links, one per projected `lib-group-accordion`. The link
1508
+ * of the section in view is highlighted, and clicking a link scrolls to its section.
1509
+ */
1316
1510
  export declare class GroupScrollSpyComponent {
1511
+ /** The scroll-spy directive on the scrolling content area. */
1317
1512
  readonly scrollSpy: Signal<ScrollSpyDirective | undefined>;
1513
+ /** The `lib-group-accordion` sections projected into the container, at any depth. */
1318
1514
  readonly sections: Signal<readonly GroupAccordionComponent[]>;
1515
+ /** The section labels shown as links, in document order. */
1319
1516
  readonly titles: Signal<string[]>;
1517
+ /** Zero-based index of the section in view. Starts at `0`. */
1320
1518
  readonly activeSection: WritableSignal<number>;
1519
+ /** Sets the section in view to the given zero-based index. Called by the scroll spy. */
1321
1520
  activeSectionChanged(index: number): void;
1521
+ /** Scrolls the content so the section at the given zero-based index is at the top. */
1322
1522
  scrollTo(section: number): void;
1323
1523
  static ɵfac: i0.ɵɵFactoryDeclaration<GroupScrollSpyComponent, never>;
1324
1524
  static ɵcmp: i0.ɵɵComponentDeclaration<GroupScrollSpyComponent, "lib-group-scroll-spy", never, {}, {}, ["sections"], ["*"], true, never>;
@@ -1326,18 +1526,36 @@ export declare class GroupScrollSpyComponent {
1326
1526
  declare namespace modal_component_d_exports {
1327
1527
  export { ModalComponent };
1328
1528
  }
1529
+ /**
1530
+ * A modal dialog with a header, a body and a footer. Project content with the `body` and `footer`
1531
+ * attributes, and open or close it through `toggleModal()` from a template reference or a view
1532
+ * query. The dialog is moved to `<body>` so it always renders above the rest of the app.
1533
+ */
1329
1534
  export declare class ModalComponent extends BaseComponent implements IModal, OnInit {
1535
+ /** Text of the footer's close button, shown as given. Defaults to `Close`. */
1330
1536
  readonly closeButtonText: ModelSignal<string>;
1537
+ /**
1538
+ * When `true`, a click on the backdrop outside the dialog closes it. Escape and the close
1539
+ * buttons work either way. Defaults to `true`.
1540
+ */
1331
1541
  readonly dialog: InputSignal<boolean>;
1542
+ /**
1543
+ * Marks the dialog as busy. While `true` the close button is disabled and Escape and backdrop
1544
+ * clicks are ignored. Defaults to `false`.
1545
+ */
1332
1546
  readonly modalProcessing: ModelSignal<boolean>;
1547
+ /** Where the dialog sits on screen: `top`, `left`, `right`, `bottom` or `center`. Defaults to `center`. */
1333
1548
  readonly position: InputSignal<'top' | 'left' | 'right' | 'bottom' | 'center'>;
1549
+ /** Width of the dialog. Defaults to `auto`, which fits the content. */
1334
1550
  readonly size: InputSignal<ModalSize>;
1551
+ /** Heading of the dialog, shown as given. Without a title the header and its close icon are not shown. */
1335
1552
  readonly title: InputSignal<string | undefined>;
1553
+ /** Emits after the dialog closes, however it was closed. */
1336
1554
  readonly closed: OutputEmitterRef<void>;
1337
1555
  private readonly _isOpen;
1338
1556
  private clickedOutside;
1339
1557
  private elementRef;
1340
- /** Renamed from `isShown`, and a signal now -- IModal says why. */
1558
+ /** Whether the dialog is open. */
1341
1559
  readonly isOpen: Signal<boolean>;
1342
1560
  constructor();
1343
1561
  /**
@@ -1376,7 +1594,12 @@ export declare class ModalComponent extends BaseComponent implements IModal, OnI
1376
1594
  * done its work.
1377
1595
  */
1378
1596
  protected onFormSubmit(event: Event): void;
1597
+ /** Closes the dialog if it is open. Does nothing otherwise. */
1379
1598
  closeModal(): void;
1599
+ /**
1600
+ * Opens the dialog when closed and closes it when open. Opening focuses the first element with
1601
+ * `autofocus`; closing emits `closed`.
1602
+ */
1380
1603
  toggleModal(): void;
1381
1604
  protected bodyMouseDown(event: MouseEvent): void;
1382
1605
  protected bodyMouseUp(event: MouseEvent): void;
@@ -1422,12 +1645,25 @@ export declare class ModalComponent extends BaseComponent implements IModal, OnI
1422
1645
  declare namespace multi_editor_component_d_exports {
1423
1646
  export { MultiEditorComponent };
1424
1647
  }
1648
+ /**
1649
+ * A modal for editing many records in one go: a grid of rows on one side and a form for the
1650
+ * selected row on the other. Project the form fields as content, bound to `formGroup`; changes
1651
+ * are kept per row and saved together through the provided `MultiEditorDataset` on Confirm.
1652
+ */
1425
1653
  export declare class MultiEditorComponent extends ModalComponent implements OnInit {
1426
1654
  private readonly modal;
1655
+ /** Text of the button that adds a new row, shown as given. Defaults to `Add row`. */
1427
1656
  readonly addButtonLabel: InputSignal<string>;
1657
+ /**
1658
+ * The form the projected fields are bound to. It is filled from the selected row, disabled while
1659
+ * no row is selected, and must be valid before the user can move to another row. Required.
1660
+ */
1428
1661
  readonly formGroup: InputSignal<FormGroup<any>>;
1662
+ /** Text of the button that removes the selected row, shown as given. Defaults to `Remove row`. */
1429
1663
  readonly removeButtonLabel: InputSignal<string>;
1664
+ /** Shows the button that adds a new row. Defaults to `true`. */
1430
1665
  readonly showAddButton: InputSignal<boolean>;
1666
+ /** Shows the button that removes the selected row; it appears only while a row is selected. Defaults to `true`. */
1431
1667
  readonly showDeleteButton: InputSignal<boolean>;
1432
1668
  protected readonly gridLoading: WritableSignal<boolean>;
1433
1669
  private dataGridDataset;
@@ -1442,7 +1678,9 @@ export declare class MultiEditorComponent extends ModalComponent implements OnIn
1442
1678
  protected onDeleteClick(): void;
1443
1679
  protected onNewClick(): void;
1444
1680
  protected onSaveClick(): void;
1681
+ /** Closes the modal if it is open, without saving. */
1445
1682
  closeModal(): void;
1683
+ /** Opens or closes the modal. Opening reloads the grid and clears and disables the form. */
1446
1684
  toggleModal(): void;
1447
1685
  private clearAllFormArrays;
1448
1686
  /**
@@ -1485,8 +1723,14 @@ export declare class MultiEditorComponent extends ModalComponent implements OnIn
1485
1723
  declare namespace multi_select_component_d_exports {
1486
1724
  export { MultiSelectComponent };
1487
1725
  }
1726
+ /**
1727
+ * A modal for picking many records at once: a searchable grid on one side and the current
1728
+ * selection on the other. It reads both lists from the `DataGridDataset` and
1729
+ * `MultiSelectResultDataset` provided around it, and saves through the result dataset on Confirm.
1730
+ */
1488
1731
  export declare class MultiSelectComponent extends ModalComponent implements OnInit {
1489
1732
  private readonly modal;
1733
+ /** Template that renders one selected record in the selection list. It receives the record as `rowData`. */
1490
1734
  readonly itemTemplate: InputSignal<TemplateRef<unknown> | undefined>;
1491
1735
  protected readonly isResultGridLoading: WritableSignal<boolean>;
1492
1736
  protected readonly isSearchGridLoading: WritableSignal<boolean>;
@@ -1507,7 +1751,9 @@ export declare class MultiSelectComponent extends ModalComponent implements OnIn
1507
1751
  * the template so the reason travels with the code.
1508
1752
  */
1509
1753
  protected onSearch(event?: Event): void;
1754
+ /** Closes the modal if it is open, without saving. */
1510
1755
  closeModal(): void;
1756
+ /** Opens or closes the modal. Opening clears the search and reloads the current selection. */
1511
1757
  toggleModal(): void;
1512
1758
  private clearSearch;
1513
1759
  private updateSelectedItems;
@@ -1523,14 +1769,21 @@ export declare class MultiSelectComponent extends ModalComponent implements OnIn
1523
1769
  declare namespace result_grid_component_d_exports {
1524
1770
  export { MultiSelectResultGridComponent };
1525
1771
  }
1772
+ /**
1773
+ * The selection list inside `lib-multi-select`. Shows the records of the `MultiSelectResultDataset`
1774
+ * with a remove button on each, and loads more rows as the user scrolls to the end.
1775
+ */
1526
1776
  export declare class MultiSelectResultGridComponent extends BaseComponent implements OnInit {
1777
+ /** Disables the remove buttons. Defaults to `false`. */
1527
1778
  readonly isDisabled: InputSignal<boolean>;
1779
+ /** Template that renders one record. It receives the record as `rowData`. */
1528
1780
  readonly template: InputSignal<TemplateRef<any> | undefined>;
1529
1781
  protected dataGridDataset: DataGridDataset;
1530
1782
  protected readonly isLoading: WritableSignal<boolean>;
1531
1783
  protected resultDataset: MultiSelectResultDataset;
1532
1784
  constructor();
1533
1785
  ngOnInit(): void;
1786
+ /** Marks the record at the given displayed row index for removal and unticks it in the search grid. */
1534
1787
  onItemRemoved(rowIndex: number): void;
1535
1788
  protected onScrolled(event: any): void;
1536
1789
  static ɵfac: i0.ɵɵFactoryDeclaration<MultiSelectResultGridComponent, never>;
@@ -1550,6 +1803,10 @@ export declare class MultiSelectResultGridComponent extends BaseComponent implem
1550
1803
  declare namespace sidebar_component_d_exports {
1551
1804
  export { SidebarComponent };
1552
1805
  }
1806
+ /**
1807
+ * The application's navigation sidebar. Loads its menus through `SidebarService`, groups them
1808
+ * into regions and closes itself on navigation, Escape or a click outside it on small screens.
1809
+ */
1553
1810
  export declare class SidebarComponent extends BaseComponent implements AfterViewInit, OnInit {
1554
1811
  protected onBodyMouseDown(event: MouseEvent): void;
1555
1812
  protected onBodyMouseUp(_event: MouseEvent): void;
@@ -1569,6 +1826,7 @@ export declare class SidebarComponent extends BaseComponent implements AfterView
1569
1826
  constructor();
1570
1827
  ngAfterViewInit(): void;
1571
1828
  ngOnInit(): void;
1829
+ /** Toggles the sidebar between collapsed and expanded. Collapsing also clears the selected menus. */
1572
1830
  collapse(): void;
1573
1831
  protected trackByFn(_index: number, item: SidebarMenu): number;
1574
1832
  protected trackByRegion(_index: number, region: SidebarRegion): string;
@@ -1590,18 +1848,45 @@ export declare class SidebarComponent extends BaseComponent implements AfterView
1590
1848
  declare namespace ribbon_button_component_d_exports {
1591
1849
  export { RibbonButtonComponent };
1592
1850
  }
1851
+ /**
1852
+ * A large icon button for a `lib-ribbon-group`. With `options` it becomes a split button whose
1853
+ * chevron opens a dropdown list; it can also show a spinner and a brief success, warning or
1854
+ * failure state.
1855
+ */
1593
1856
  export declare class RibbonButtonComponent implements OnDestroy {
1594
1857
  private readonly buttonContainer;
1595
1858
  private readonly optionsDropdown;
1859
+ /** CSS class that colours the icon, the spinner and the chevron. Defaults to `text-primary-500`. */
1596
1860
  readonly color: InputSignal<string>;
1861
+ /**
1862
+ * Index of the option the main button triggers directly when `options` is set. With `-1`, the
1863
+ * default, the main button opens the dropdown instead.
1864
+ */
1597
1865
  readonly defaultOption: InputSignal<number>;
1866
+ /** Disables the button and its dropdown. Defaults to `false`. */
1598
1867
  readonly disabled: InputSignal<boolean>;
1868
+ /** Font Awesome icon class, for example `fa-save`. */
1599
1869
  readonly icon: InputSignal<string | undefined>;
1870
+ /** Size of the icon: `small` or `large`. Defaults to `large`. */
1600
1871
  readonly iconSize: InputSignal<'small' | 'large'>;
1872
+ /** Text under the icon, as a translation key. Hidden when the ribbon is narrow. Defaults to empty. */
1601
1873
  readonly label: InputSignal<string>;
1874
+ /** Shows a spinner in place of the icon and blocks clicks while `true`. Defaults to `false`. */
1602
1875
  readonly loading: ModelSignal<boolean>;
1876
+ /**
1877
+ * Entries of the dropdown list. When set, the button gets a chevron that opens the list. The
1878
+ * button is disabled when none of the options is visible. Defaults to none.
1879
+ */
1603
1880
  readonly options: InputSignal<IRibbonButtonOption[]>;
1881
+ /**
1882
+ * Hover text, shown as given; the translated label is shown on hover when it is empty. Also
1883
+ * names the button for screen readers, translated, when there is no label. Defaults to empty.
1884
+ */
1604
1885
  readonly tooltip: InputSignal<string>;
1886
+ /**
1887
+ * Emits when the button is activated. Carries the `id` of the chosen option, or `undefined` for
1888
+ * a button without options.
1889
+ */
1605
1890
  readonly action: OutputEmitterRef<string | undefined>;
1606
1891
  protected bodyMouseDown(event: MouseEvent): void;
1607
1892
  protected bodyMouseUp(event: MouseEvent): void;
@@ -1639,7 +1924,9 @@ export declare class RibbonButtonComponent implements OnDestroy {
1639
1924
  protected onButtonClicked(): void;
1640
1925
  protected onOptionClicked(option: IRibbonButtonOption): void;
1641
1926
  protected onShowHideDropdown(): void;
1927
+ /** Ends the loading state and shows the given result on the button for one second. */
1642
1928
  finishLoading(status: 'failure' | 'warning' | 'success'): void;
1929
+ /** Puts the button in its loading state, the same as setting `loading` to `true`. */
1643
1930
  startLoading(): void;
1644
1931
  protected isOptionDisabled(option: IRibbonButtonOption): boolean;
1645
1932
  protected isOptionVisible(option: IRibbonButtonOption): boolean;
@@ -1716,6 +2003,10 @@ export declare class RibbonButtonComponent implements OnDestroy {
1716
2003
  declare namespace ribbon_component_d_exports {
1717
2004
  export { RibbonComponent };
1718
2005
  }
2006
+ /**
2007
+ * The toolbar strip at the top of a view. Project `lib-ribbon-group` elements as content; content
2008
+ * marked with the `right` attribute is placed at the far end.
2009
+ */
1719
2010
  export declare class RibbonComponent {
1720
2011
  static ɵfac: i0.ɵɵFactoryDeclaration<RibbonComponent, never>;
1721
2012
  static ɵcmp: i0.ɵɵComponentDeclaration<RibbonComponent, "lib-ribbon", never, {}, {}, never, ["*", "[right]"], true, never>;
@@ -1723,8 +2014,15 @@ export declare class RibbonComponent {
1723
2014
  declare namespace ribbon_group_component_d_exports {
1724
2015
  export { RibbonGroupComponent };
1725
2016
  }
2017
+ /**
2018
+ * A labelled group of buttons inside a `lib-ribbon`. The group hides itself when it holds no
2019
+ * visible `RibbonGroupChild`, such as the framework ribbon buttons. A plain `lib-ribbon-button` is
2020
+ * not one, so a group holding only those stays hidden.
2021
+ */
1726
2022
  export declare class RibbonGroupComponent {
2023
+ /** The `RibbonGroupChild` elements projected into the group, at any depth. */
1727
2024
  readonly children: Signal<readonly RibbonGroupChild[]>;
2025
+ /** Caption shown under the group's buttons. Shown as given, not translated. Defaults to empty. */
1728
2026
  label: string;
1729
2027
  protected readonly hasChildren: Signal<boolean>;
1730
2028
  static ɵfac: i0.ɵɵFactoryDeclaration<RibbonGroupComponent, never>;
@@ -1775,6 +2073,10 @@ export declare abstract class RouterFormatter {
1775
2073
  declare namespace enum_d_exports {
1776
2074
  export { EnumTranslatePipe };
1777
2075
  }
2076
+ /**
2077
+ * Turns a TypeScript enum into a list of `{ value, display }` options, where `display` is an
2078
+ * observable of the translated enum key. Use it to fill a select from an enum.
2079
+ */
1778
2080
  export declare class EnumTranslatePipe implements PipeTransform {
1779
2081
  private translate;
1780
2082
  transform(enumType: any): Array<{
@@ -1787,6 +2089,10 @@ export declare class EnumTranslatePipe implements PipeTransform {
1787
2089
  declare namespace replace_pipe_d_exports {
1788
2090
  export { ReplacePipe };
1789
2091
  }
2092
+ /**
2093
+ * Replaces one substring in a string, for example `label | replace: '{0}': count`. Only the first
2094
+ * occurrence is replaced; a `null` or `undefined` replacement becomes an empty string.
2095
+ */
1790
2096
  export declare class ReplacePipe implements PipeTransform {
1791
2097
  transform(message: string, searchValue: string, replaceValue?: string | null): string;
1792
2098
  static ɵfac: i0.ɵɵFactoryDeclaration<ReplacePipe, never>;
@@ -1795,6 +2101,11 @@ export declare class ReplacePipe implements PipeTransform {
1795
2101
  declare namespace replace_many_pipe_d_exports {
1796
2102
  export { ReplaceManyPipe };
1797
2103
  }
2104
+ /**
2105
+ * Replaces several placeholders in a string, for example
2106
+ * `'Hello {name}' | replaceMany: { '{name}': user.name }`. Only the first occurrence of each key
2107
+ * is replaced; a `null` or `undefined` value becomes an empty string.
2108
+ */
1798
2109
  export declare class ReplaceManyPipe implements PipeTransform {
1799
2110
  transform(message: string, replaceArgs?: {
1800
2111
  [id: string]: string | null | undefined;