@hestia-earth/ui-components 0.21.7 → 0.21.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.
Files changed (92) hide show
  1. package/common/bar-chart/bar-chart.component.d.ts +66 -0
  2. package/common/click-outside.directive.d.ts +1 -1
  3. package/common/common.light.module.d.ts +15 -15
  4. package/common/common.module.d.ts +15 -8
  5. package/common/control.value.accessor.d.ts +8 -0
  6. package/common/filter/filter.component.d.ts +35 -0
  7. package/common/filter/filterStore.d.ts +16 -0
  8. package/common/filter/has-options.pipe.d.ts +9 -0
  9. package/common/filter/index.d.ts +5 -0
  10. package/common/filter/models/filter-data.d.ts +14 -0
  11. package/common/filter/models/filter-fn.d.ts +2 -0
  12. package/common/filter/models/filter-state.d.ts +12 -0
  13. package/common/filter/models/index.d.ts +3 -0
  14. package/common/filter/utils/count-option-descendants.d.ts +2 -0
  15. package/common/filter/utils/flat-filter-node.d.ts +3 -0
  16. package/common/filter/utils/index.d.ts +5 -0
  17. package/common/filter/utils/map-filter-data.d.ts +2 -0
  18. package/common/filter/utils/populate-with-track-ids-filter-data.d.ts +2 -0
  19. package/common/filter/utils/search-filter-data.d.ts +2 -0
  20. package/common/index.d.ts +8 -0
  21. package/common/mobile-shell/mobile-shell.component.d.ts +19 -0
  22. package/common/resized.directive.d.ts +21 -0
  23. package/common/rxjs-utils.d.ts +5 -0
  24. package/common/select/directives/index.d.ts +3 -0
  25. package/common/select/directives/node-element.directive.d.ts +27 -0
  26. package/common/select/directives/node-element.token.d.ts +15 -0
  27. package/common/select/directives/toggle-option.directive.d.ts +9 -0
  28. package/common/select/index.d.ts +7 -0
  29. package/common/select/select-option/index.d.ts +2 -0
  30. package/common/select/select-option/select-option.component.d.ts +22 -0
  31. package/common/select/select-option/select-option.token.d.ts +14 -0
  32. package/common/select/select-option-group/index.d.ts +2 -0
  33. package/common/select/select-option-group/select-option-group.component.d.ts +29 -0
  34. package/common/select/select-option-group/select-option-group.token.d.ts +9 -0
  35. package/common/select/select-value.d.ts +1 -0
  36. package/common/select/select.component.d.ts +70 -0
  37. package/common/select/select.module.d.ts +15 -0
  38. package/common/select/selectToken.d.ts +28 -0
  39. package/common/shell/shell.component.d.ts +24 -0
  40. package/common/sort-select/sort-select.component.d.ts +27 -0
  41. package/esm2022/common/bar-chart/bar-chart.component.mjs +142 -0
  42. package/esm2022/common/click-outside.directive.mjs +5 -4
  43. package/esm2022/common/common.light.module.mjs +7 -6
  44. package/esm2022/common/common.module.mjs +47 -13
  45. package/esm2022/common/control.value.accessor.mjs +15 -0
  46. package/esm2022/common/filter/filter.component.mjs +138 -0
  47. package/esm2022/common/filter/filterStore.mjs +57 -0
  48. package/esm2022/common/filter/has-options.pipe.mjs +18 -0
  49. package/esm2022/common/filter/index.mjs +6 -0
  50. package/esm2022/common/filter/models/filter-data.mjs +2 -0
  51. package/esm2022/common/filter/models/filter-fn.mjs +2 -0
  52. package/esm2022/common/filter/models/filter-state.mjs +11 -0
  53. package/esm2022/common/filter/models/index.mjs +4 -0
  54. package/esm2022/common/filter/utils/count-option-descendants.mjs +4 -0
  55. package/esm2022/common/filter/utils/flat-filter-node.mjs +11 -0
  56. package/esm2022/common/filter/utils/index.mjs +6 -0
  57. package/esm2022/common/filter/utils/map-filter-data.mjs +13 -0
  58. package/esm2022/common/filter/utils/populate-with-track-ids-filter-data.mjs +4 -0
  59. package/esm2022/common/filter/utils/search-filter-data.mjs +15 -0
  60. package/esm2022/common/index.mjs +9 -1
  61. package/esm2022/common/mobile-shell/mobile-shell.component.mjs +49 -0
  62. package/esm2022/common/resized.directive.mjs +40 -0
  63. package/esm2022/common/rxjs-utils.mjs +6 -0
  64. package/esm2022/common/select/directives/index.mjs +4 -0
  65. package/esm2022/common/select/directives/node-element.directive.mjs +101 -0
  66. package/esm2022/common/select/directives/node-element.token.mjs +3 -0
  67. package/esm2022/common/select/directives/toggle-option.directive.mjs +37 -0
  68. package/esm2022/common/select/index.mjs +8 -0
  69. package/esm2022/common/select/select-option/index.mjs +3 -0
  70. package/esm2022/common/select/select-option/select-option.component.mjs +82 -0
  71. package/esm2022/common/select/select-option/select-option.token.mjs +3 -0
  72. package/esm2022/common/select/select-option-group/index.mjs +3 -0
  73. package/esm2022/common/select/select-option-group/select-option-group.component.mjs +125 -0
  74. package/esm2022/common/select/select-option-group/select-option-group.token.mjs +3 -0
  75. package/esm2022/common/select/select-value.mjs +2 -0
  76. package/esm2022/common/select/select.component.mjs +325 -0
  77. package/esm2022/common/select/select.module.mjs +59 -0
  78. package/esm2022/common/select/selectToken.mjs +3 -0
  79. package/esm2022/common/shell/shell.component.mjs +58 -0
  80. package/esm2022/common/sort-select/sort-select.component.mjs +67 -0
  81. package/esm2022/cycles/cycles-activity/cycles-activity.component.mjs +3 -3
  82. package/esm2022/cycles/cycles-emissions/cycles-emissions.component.mjs +3 -3
  83. package/esm2022/cycles/cycles-practices/cycles-practices.component.mjs +3 -3
  84. package/esm2022/engine/engine-orchestrator-edit/engine-orchestrator-edit.component.mjs +5 -6
  85. package/esm2022/fontawesome/fontawesome.module.mjs +8 -15
  86. package/esm2022/impact-assessments/impact-assessments-products/impact-assessments-products.component.mjs +3 -3
  87. package/esm2022/node/node-csv-select-headers/node-csv-select-headers.component.mjs +3 -4
  88. package/esm2022/sites/sites-measurements/sites-measurements.component.mjs +3 -3
  89. package/fesm2022/hestia-earth-ui-components.mjs +1472 -163
  90. package/fesm2022/hestia-earth-ui-components.mjs.map +1 -1
  91. package/package.json +8 -2
  92. package/styles.scss +1 -0
@@ -0,0 +1,66 @@
1
+ import { InjectionToken } from '@angular/core';
2
+ import * as i0 from "@angular/core";
3
+ export interface ChartDataItem {
4
+ label: string;
5
+ count: number;
6
+ color: string;
7
+ }
8
+ export declare const CHART_SETTINGS_TOKEN: InjectionToken<{
9
+ type: string;
10
+ options: {
11
+ events: any[];
12
+ animation: {
13
+ duration: number;
14
+ };
15
+ responsive: boolean;
16
+ maintainAspectRatio: boolean;
17
+ legend: {
18
+ display: boolean;
19
+ };
20
+ tooltips: {
21
+ enabled: boolean;
22
+ };
23
+ scales: {
24
+ yAxes: {
25
+ display: boolean;
26
+ position: string;
27
+ gridLines: {
28
+ display: boolean;
29
+ };
30
+ ticks: {
31
+ crossAlign: string;
32
+ };
33
+ }[];
34
+ };
35
+ };
36
+ }>;
37
+ export declare const DATASETS_SETTINGS_TOKEN: InjectionToken<{
38
+ axis: string;
39
+ barPercentage: number;
40
+ barThickness: number;
41
+ maxBarThickness: number;
42
+ }>;
43
+ export declare class BarChartComponent {
44
+ private customDatasetsOptions;
45
+ private customOptions;
46
+ private maxValue;
47
+ private dataItems;
48
+ private maxOptions;
49
+ private dataOptions;
50
+ private defaultChartSettings;
51
+ private options;
52
+ private defaultDatasetsSettings;
53
+ private datasets;
54
+ private ngZone;
55
+ private updateChartEffect;
56
+ private chartRef;
57
+ private chartRefExits;
58
+ private chart;
59
+ set max(value: number);
60
+ set data(value: ChartDataItem[]);
61
+ set customDatasets(value: any);
62
+ set custom(value: any);
63
+ private _updateChart;
64
+ static ɵfac: i0.ɵɵFactoryDeclaration<BarChartComponent, never>;
65
+ static ɵcmp: i0.ɵɵComponentDeclaration<BarChartComponent, "he-bar-chart", never, { "max": { "alias": "max"; "required": false; }; "data": { "alias": "data"; "required": false; }; "customDatasets": { "alias": "customDatasets"; "required": false; }; "custom": { "alias": "custom"; "required": false; }; }, {}, never, never, true, never>;
66
+ }
@@ -6,5 +6,5 @@ export declare class ClickOutsideDirective {
6
6
  constructor(elementRef: ElementRef);
7
7
  onClick(event: MouseEvent): void;
8
8
  static ɵfac: i0.ɵɵFactoryDeclaration<ClickOutsideDirective, never>;
9
- static ɵdir: i0.ɵɵDirectiveDeclaration<ClickOutsideDirective, "[clickOutside]", never, {}, { "clickOutside": "clickOutside"; }, never, never, false, never>;
9
+ static ɵdir: i0.ɵɵDirectiveDeclaration<ClickOutsideDirective, "[clickOutside]", never, {}, { "clickOutside": "clickOutside"; }, never, never, true, never>;
10
10
  }
@@ -5,22 +5,22 @@ import * as i3 from "./social-tags/social-tags.component";
5
5
  import * as i4 from "./toast/toast.component";
6
6
  import * as i5 from "./apply-pure.pipe";
7
7
  import * as i6 from "./bind-once.directive";
8
- import * as i7 from "./click-outside.directive";
9
- import * as i8 from "./compound.directive";
10
- import * as i9 from "./compound.pipe";
11
- import * as i10 from "./default.pipe";
12
- import * as i11 from "./ellipsis.pipe";
13
- import * as i12 from "./keys.pipe";
14
- import * as i13 from "./no-ext.pipe";
15
- import * as i14 from "./pluralize.pipe";
16
- import * as i15 from "./key-to-label.pipe";
17
- import * as i16 from "./precision.pipe";
18
- import * as i17 from "@angular/common";
19
- import * as i18 from "@angular/forms";
20
- import * as i19 from "@angular/router";
21
- import * as i20 from "../fontawesome/fontawesome.module";
8
+ import * as i7 from "./compound.directive";
9
+ import * as i8 from "./compound.pipe";
10
+ import * as i9 from "./default.pipe";
11
+ import * as i10 from "./ellipsis.pipe";
12
+ import * as i11 from "./keys.pipe";
13
+ import * as i12 from "./no-ext.pipe";
14
+ import * as i13 from "./pluralize.pipe";
15
+ import * as i14 from "./key-to-label.pipe";
16
+ import * as i15 from "./precision.pipe";
17
+ import * as i16 from "@angular/common";
18
+ import * as i17 from "@angular/forms";
19
+ import * as i18 from "@angular/router";
20
+ import * as i19 from "../fontawesome/fontawesome.module";
21
+ import * as i20 from "./click-outside.directive";
22
22
  export declare class HeCommonLightModule {
23
23
  static ɵfac: i0.ɵɵFactoryDeclaration<HeCommonLightModule, never>;
24
- static ɵmod: i0.ɵɵNgModuleDeclaration<HeCommonLightModule, [typeof i1.IssueConfirmComponent, typeof i2.NavigationMenuComponent, typeof i3.SocialTagsComponent, typeof i4.ToastComponent, typeof i5.ApplyPurePipe, typeof i6.BindOnceDirective, typeof i7.ClickOutsideDirective, typeof i8.CompoundDirective, typeof i9.CompoundPipe, typeof i10.DefaultPipe, typeof i11.EllipsisPipe, typeof i12.KeysPipe, typeof i13.NoExtPipe, typeof i14.PluralizePipe, typeof i15.KeyToLabelPipe, typeof i16.PrecisionPipe], [typeof i17.CommonModule, typeof i18.FormsModule, typeof i19.RouterModule, typeof i20.HeFontawesomeModule], [typeof i20.HeFontawesomeModule, typeof i1.IssueConfirmComponent, typeof i2.NavigationMenuComponent, typeof i3.SocialTagsComponent, typeof i4.ToastComponent, typeof i5.ApplyPurePipe, typeof i6.BindOnceDirective, typeof i7.ClickOutsideDirective, typeof i8.CompoundDirective, typeof i9.CompoundPipe, typeof i10.DefaultPipe, typeof i11.EllipsisPipe, typeof i12.KeysPipe, typeof i13.NoExtPipe, typeof i14.PluralizePipe, typeof i15.KeyToLabelPipe, typeof i16.PrecisionPipe]>;
24
+ static ɵmod: i0.ɵɵNgModuleDeclaration<HeCommonLightModule, [typeof i1.IssueConfirmComponent, typeof i2.NavigationMenuComponent, typeof i3.SocialTagsComponent, typeof i4.ToastComponent, typeof i5.ApplyPurePipe, typeof i6.BindOnceDirective, typeof i7.CompoundDirective, typeof i8.CompoundPipe, typeof i9.DefaultPipe, typeof i10.EllipsisPipe, typeof i11.KeysPipe, typeof i12.NoExtPipe, typeof i13.PluralizePipe, typeof i14.KeyToLabelPipe, typeof i15.PrecisionPipe], [typeof i16.CommonModule, typeof i17.FormsModule, typeof i18.RouterModule, typeof i19.HeFontawesomeModule, typeof i20.ClickOutsideDirective], [typeof i19.HeFontawesomeModule, typeof i1.IssueConfirmComponent, typeof i2.NavigationMenuComponent, typeof i3.SocialTagsComponent, typeof i4.ToastComponent, typeof i5.ApplyPurePipe, typeof i6.BindOnceDirective, typeof i7.CompoundDirective, typeof i8.CompoundPipe, typeof i9.DefaultPipe, typeof i10.EllipsisPipe, typeof i11.KeysPipe, typeof i12.NoExtPipe, typeof i13.PluralizePipe, typeof i14.KeyToLabelPipe, typeof i15.PrecisionPipe]>;
25
25
  static ɵinj: i0.ɵɵInjectorDeclaration<HeCommonLightModule>;
26
26
  }
@@ -18,15 +18,22 @@ import * as i16 from "./get.pipe";
18
18
  import * as i17 from "./is-array.pipe";
19
19
  import * as i18 from "./is-object.pipe";
20
20
  import * as i19 from "./remove-markdown.pipe";
21
- import * as i20 from "./sort-by.pipe";
22
- import * as i21 from "@angular/common";
23
- import * as i22 from "@angular/forms";
24
- import * as i23 from "@angular/router";
25
- import * as i24 from "@ng-bootstrap/ng-bootstrap";
26
- import * as i25 from "@angular/google-maps";
27
- import * as i26 from "./common.light.module";
21
+ import * as i20 from "./resized.directive";
22
+ import * as i21 from "./sort-by.pipe";
23
+ import * as i22 from "@angular/common";
24
+ import * as i23 from "@angular/forms";
25
+ import * as i24 from "@angular/router";
26
+ import * as i25 from "@ng-bootstrap/ng-bootstrap";
27
+ import * as i26 from "@angular/google-maps";
28
+ import * as i27 from "./common.light.module";
29
+ import * as i28 from "./bar-chart/bar-chart.component";
30
+ import * as i29 from "./filter/filter.component";
31
+ import * as i30 from "./mobile-shell/mobile-shell.component";
32
+ import * as i31 from "./select/select.module";
33
+ import * as i32 from "./shell/shell.component";
34
+ import * as i33 from "./sort-select/sort-select.component";
28
35
  export declare class HeCommonModule {
29
36
  static ɵfac: i0.ɵɵFactoryDeclaration<HeCommonModule, never>;
30
- static ɵmod: i0.ɵɵNgModuleDeclaration<HeCommonModule, [typeof i1.BlankNodeStateComponent, typeof i2.BlankNodeStateNoticeComponent, typeof i3.BlankNodeValueDeltaComponent, typeof i4.ClipboardComponent, typeof i5.DataTableComponent, typeof i6.LinkKeyValueComponent, typeof i7.MapsDrawingConfirmComponent, typeof i8.PopoverComponent, typeof i9.PopoverConfirmComponent, typeof i10.SchemaVersionLinkComponent, typeof i11.SearchExtendComponent, typeof i12.SkeletonTextComponent, typeof i13.UnitConverterComponent, typeof i14.TagsInputDirective, typeof i15.TimesPipe, typeof i16.GetPipe, typeof i17.IsArrayPipe, typeof i18.IsObjectPipe, typeof i19.RemoveMarkdownPipe, typeof i20.SortByPipe], [typeof i21.CommonModule, typeof i22.FormsModule, typeof i23.RouterModule, typeof i24.NgbTypeaheadModule, typeof i24.NgbTooltipModule, typeof i24.NgbPopoverModule, typeof i25.GoogleMapsModule, typeof i26.HeCommonLightModule], [typeof i24.NgbTypeaheadModule, typeof i24.NgbTooltipModule, typeof i24.NgbPopoverModule, typeof i25.GoogleMapsModule, typeof i26.HeCommonLightModule, typeof i1.BlankNodeStateComponent, typeof i2.BlankNodeStateNoticeComponent, typeof i3.BlankNodeValueDeltaComponent, typeof i4.ClipboardComponent, typeof i5.DataTableComponent, typeof i6.LinkKeyValueComponent, typeof i7.MapsDrawingConfirmComponent, typeof i8.PopoverComponent, typeof i9.PopoverConfirmComponent, typeof i10.SchemaVersionLinkComponent, typeof i11.SearchExtendComponent, typeof i12.SkeletonTextComponent, typeof i13.UnitConverterComponent, typeof i14.TagsInputDirective, typeof i15.TimesPipe, typeof i16.GetPipe, typeof i17.IsArrayPipe, typeof i18.IsObjectPipe, typeof i19.RemoveMarkdownPipe, typeof i20.SortByPipe]>;
37
+ static ɵmod: i0.ɵɵNgModuleDeclaration<HeCommonModule, [typeof i1.BlankNodeStateComponent, typeof i2.BlankNodeStateNoticeComponent, typeof i3.BlankNodeValueDeltaComponent, typeof i4.ClipboardComponent, typeof i5.DataTableComponent, typeof i6.LinkKeyValueComponent, typeof i7.MapsDrawingConfirmComponent, typeof i8.PopoverComponent, typeof i9.PopoverConfirmComponent, typeof i10.SchemaVersionLinkComponent, typeof i11.SearchExtendComponent, typeof i12.SkeletonTextComponent, typeof i13.UnitConverterComponent, typeof i14.TagsInputDirective, typeof i15.TimesPipe, typeof i16.GetPipe, typeof i17.IsArrayPipe, typeof i18.IsObjectPipe, typeof i19.RemoveMarkdownPipe, typeof i20.ResizedDirective, typeof i21.SortByPipe], [typeof i22.CommonModule, typeof i23.FormsModule, typeof i24.RouterModule, typeof i25.NgbTypeaheadModule, typeof i25.NgbTooltipModule, typeof i25.NgbPopoverModule, typeof i26.GoogleMapsModule, typeof i27.HeCommonLightModule, typeof i28.BarChartComponent, typeof i29.FilterComponent, typeof i30.MobileShellComponent, typeof i31.SelectModule, typeof i32.ShellComponent, typeof i33.SortSelectComponent], [typeof i25.NgbTypeaheadModule, typeof i25.NgbTooltipModule, typeof i25.NgbPopoverModule, typeof i26.GoogleMapsModule, typeof i27.HeCommonLightModule, typeof i1.BlankNodeStateComponent, typeof i2.BlankNodeStateNoticeComponent, typeof i3.BlankNodeValueDeltaComponent, typeof i4.ClipboardComponent, typeof i5.DataTableComponent, typeof i6.LinkKeyValueComponent, typeof i7.MapsDrawingConfirmComponent, typeof i8.PopoverComponent, typeof i9.PopoverConfirmComponent, typeof i10.SchemaVersionLinkComponent, typeof i11.SearchExtendComponent, typeof i12.SkeletonTextComponent, typeof i13.UnitConverterComponent, typeof i14.TagsInputDirective, typeof i15.TimesPipe, typeof i16.GetPipe, typeof i17.IsArrayPipe, typeof i18.IsObjectPipe, typeof i19.RemoveMarkdownPipe, typeof i20.ResizedDirective, typeof i21.SortByPipe, typeof i28.BarChartComponent, typeof i29.FilterComponent, typeof i30.MobileShellComponent, typeof i31.SelectModule, typeof i32.ShellComponent, typeof i33.SortSelectComponent]>;
31
38
  static ɵinj: i0.ɵɵInjectorDeclaration<HeCommonModule>;
32
39
  }
@@ -0,0 +1,8 @@
1
+ import { ControlValueAccessor as NgControlValueAccessor } from '@angular/forms';
2
+ export declare abstract class ControlValueAccessor<T = any> implements NgControlValueAccessor {
3
+ abstract writeValue(value: T): void;
4
+ onChange?: (value: T | null) => void;
5
+ onTouched?: () => void;
6
+ registerOnChange(fn: (value: T | null) => void): void;
7
+ registerOnTouched(fn: () => void): void;
8
+ }
@@ -0,0 +1,35 @@
1
+ import { EventEmitter, OnInit } from '@angular/core';
2
+ import { FormControl } from '@angular/forms';
3
+ import { SelectToken, SelectValue } from '../select';
4
+ import { ControlValueAccessor } from '../control.value.accessor';
5
+ import { FilterData, FilterFn } from './models';
6
+ import { FilterStore } from './filterStore';
7
+ import * as i0 from "@angular/core";
8
+ export declare class FilterComponent<T> extends ControlValueAccessor<SelectValue<T>> implements OnInit {
9
+ filterStore: FilterStore;
10
+ multiple: boolean;
11
+ expandOnFilter: boolean;
12
+ placeholder: string;
13
+ valuePlaceholder: string;
14
+ value: SelectValue<T>;
15
+ readonly selectionChanged: EventEmitter<SelectValue<T>>;
16
+ protected select: SelectToken<FilterData>;
17
+ protected filter: import("@angular/core").Signal<string>;
18
+ protected limitValue: import("@angular/core").Signal<number>;
19
+ protected selectControl: FormControl<T>;
20
+ set data(data: FilterData[]);
21
+ set disabled(value: boolean);
22
+ set limit(limit: number);
23
+ set filterFn(filterFn: FilterFn);
24
+ set mapFn(mapFn: (node: FilterData) => FilterData);
25
+ writeValue(value: T): void;
26
+ ngOnInit(): void;
27
+ protected onClose(): void;
28
+ protected displayWith: (item: string) => string;
29
+ protected onSearchFilter(search: string): void;
30
+ protected onSelectionChange($event: SelectValue<T>): void;
31
+ protected trackByFn: (index: number, item: FilterData) => string;
32
+ private _focusNeighbourItem;
33
+ static ɵfac: i0.ɵɵFactoryDeclaration<FilterComponent<any>, never>;
34
+ static ɵcmp: i0.ɵɵComponentDeclaration<FilterComponent<any>, "he-filter", never, { "multiple": { "alias": "multiple"; "required": false; }; "expandOnFilter": { "alias": "expandOnFilter"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "valuePlaceholder": { "alias": "valuePlaceholder"; "required": false; }; "value": { "alias": "value"; "required": false; }; "data": { "alias": "data"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "limit": { "alias": "limit"; "required": false; }; "filterFn": { "alias": "filterFn"; "required": false; }; "mapFn": { "alias": "mapFn"; "required": false; }; }, { "selectionChanged": "selectionChanged"; }, never, never, true, never>;
35
+ }
@@ -0,0 +1,16 @@
1
+ import { ComponentStore } from '@ngrx/component-store';
2
+ import { FilterData, FilterOption, FilterState } from './models';
3
+ import * as i0 from "@angular/core";
4
+ export declare class FilterStore extends ComponentStore<FilterState> {
5
+ readonly setValue: (() => void) | ((observableOrValue: any) => import("rxjs").Subscription);
6
+ readonly setData: (observableOrValue: FilterData[] | import("rxjs").Observable<FilterData[]>) => import("rxjs").Subscription;
7
+ readonly flattenOptions: import("@angular/core").Signal<FilterOption[]>;
8
+ readonly flattenOptionsDictionary: import("@angular/core").Signal<import("lodash").Dictionary<FilterOption>>;
9
+ readonly value: import("@angular/core").Signal<any>;
10
+ readonly selectedOptions: import("@angular/core").Signal<FilterOption[]>;
11
+ readonly filteredData: import("@angular/core").Signal<FilterData[]>;
12
+ constructor();
13
+ private _getFilteredData;
14
+ static ɵfac: i0.ɵɵFactoryDeclaration<FilterStore, never>;
15
+ static ɵprov: i0.ɵɵInjectableDeclaration<FilterStore>;
16
+ }
@@ -0,0 +1,9 @@
1
+ import { PipeTransform } from '@angular/core';
2
+ import { FilterData, FilterGroup } from './models';
3
+ import * as i0 from "@angular/core";
4
+ export declare const hasLeafWithValue: (root?: FilterData) => boolean;
5
+ export declare class FilterHasOptionsPipe implements PipeTransform {
6
+ transform(group: FilterGroup): boolean;
7
+ static ɵfac: i0.ɵɵFactoryDeclaration<FilterHasOptionsPipe, never>;
8
+ static ɵpipe: i0.ɵɵPipeDeclaration<FilterHasOptionsPipe, "filterHasOptions", true>;
9
+ }
@@ -0,0 +1,5 @@
1
+ export * from './utils';
2
+ export * from './filter.component';
3
+ export * from './models';
4
+ export { populateWithTrackIdsFilterData } from './utils/populate-with-track-ids-filter-data';
5
+ export { FilterStore } from './filterStore';
@@ -0,0 +1,14 @@
1
+ export type FilterData = FilterOption | FilterGroup;
2
+ export interface FilterElement {
3
+ label: string;
4
+ trackId?: string;
5
+ }
6
+ export interface FilterOption extends FilterElement {
7
+ value: string;
8
+ type: 'option';
9
+ }
10
+ export interface FilterGroup extends FilterElement {
11
+ type: 'group';
12
+ toggleButton?: boolean;
13
+ options: FilterData[];
14
+ }
@@ -0,0 +1,2 @@
1
+ import { FilterData } from './filter-data';
2
+ export type FilterFn = (node: FilterData, filter: string) => boolean;
@@ -0,0 +1,12 @@
1
+ import { FilterData } from './filter-data';
2
+ import { FilterFn } from './filter-fn';
3
+ import { SelectValue } from '../../select';
4
+ export interface FilterState {
5
+ limit: number;
6
+ filter: string;
7
+ data: FilterData[];
8
+ filterFn?: FilterFn;
9
+ mapFn: (node: FilterData) => FilterData;
10
+ value: SelectValue<any>;
11
+ }
12
+ export declare const initialFilterState: FilterState;
@@ -0,0 +1,3 @@
1
+ export * from './filter-data';
2
+ export * from './filter-fn';
3
+ export * from './filter-state';
@@ -0,0 +1,2 @@
1
+ import { FilterData } from '../models';
2
+ export declare const countOptionDescendants: (data: FilterData) => number;
@@ -0,0 +1,3 @@
1
+ import { FilterData } from '../models';
2
+ export declare const flatFilterData: (nodes?: FilterData[]) => FilterData[];
3
+ export declare const flatFilterNode: (node?: FilterData) => FilterData[];
@@ -0,0 +1,5 @@
1
+ export * from './search-filter-data';
2
+ export * from './flat-filter-node';
3
+ export * from './populate-with-track-ids-filter-data';
4
+ export * from './map-filter-data';
5
+ export { countOptionDescendants } from './count-option-descendants';
@@ -0,0 +1,2 @@
1
+ import { FilterData } from '../models';
2
+ export declare const mapFilterData: (data: FilterData[], fn: (node: FilterData) => FilterData) => FilterData[];
@@ -0,0 +1,2 @@
1
+ import { FilterData } from '../models';
2
+ export declare const populateWithTrackIdsFilterData: (data: FilterData[]) => FilterData[];
@@ -0,0 +1,2 @@
1
+ import { FilterData } from '../models';
2
+ export declare const searchFilterData: (data: FilterData[], filterFn: (node: FilterData) => boolean) => FilterData[];
package/common/index.d.ts CHANGED
@@ -10,20 +10,26 @@ export * from './logs-utils';
10
10
  export * from './navigation-menu.service';
11
11
  export * from './maps-utils';
12
12
  export * from './pluralize';
13
+ export * from './rxjs-utils';
13
14
  export * from './utils';
15
+ export * from './bar-chart/bar-chart.component';
14
16
  export { BlankNodeStateComponent } from './blank-node-state/blank-node-state.component';
15
17
  export { BlankNodeStateNoticeComponent } from './blank-node-state-notice/blank-node-state-notice.component';
16
18
  export { BlankNodeValueDeltaComponent } from './blank-node-value-delta/blank-node-value-delta.component';
17
19
  export { ClipboardComponent } from './clipboard/clipboard.component';
18
20
  export { DataTableComponent } from './data-table/data-table.component';
21
+ export * from './filter';
19
22
  export { IssueConfirmComponent } from './issue-confirm/issue-confirm.component';
20
23
  export { LinkKeyValueComponent } from './link-key-value/link-key-value.component';
21
24
  export { MapsDrawingConfirmComponent } from './maps-drawing-confirm/maps-drawing-confirm.component';
25
+ export * from './mobile-shell/mobile-shell.component';
22
26
  export { NavigationMenuComponent } from './navigation-menu/navigation-menu.component';
23
27
  export { PopoverComponent } from './popover/popover.component';
24
28
  export { PopoverConfirmComponent } from './popover-confirm/popover-confirm.component';
25
29
  export { SchemaVersionLinkComponent } from './schema-version-link/schema-version-link.component';
26
30
  export { SearchExtendComponent } from './search-extend/search-extend.component';
31
+ export * from './select';
32
+ export * from './shell/shell.component';
27
33
  export { SkeletonTextComponent } from './skeleton-text/skeleton-text.component';
28
34
  export { SocialTagsComponent } from './social-tags/social-tags.component';
29
35
  export { ToastComponent } from './toast/toast.component';
@@ -44,6 +50,8 @@ export { NoExtPipe } from './no-ext.pipe';
44
50
  export { PluralizePipe } from './pluralize.pipe';
45
51
  export { PrecisionPipe } from './precision.pipe';
46
52
  export { RemoveMarkdownPipe } from './remove-markdown.pipe';
53
+ export * from './resized.directive';
47
54
  export { TagsInputDirective } from './tags-input.directive';
48
55
  export { TimesPipe } from './times.pipe';
49
56
  export { SortByPipe } from './sort-by.pipe';
57
+ export * from './sort-select/sort-select.component';
@@ -0,0 +1,19 @@
1
+ import { TemplateRef } from '@angular/core';
2
+ import * as i0 from "@angular/core";
3
+ export interface IMobileShellMenuButton {
4
+ icon: any;
5
+ label?: string;
6
+ onClick: () => void;
7
+ menuRef?: TemplateRef<any>;
8
+ }
9
+ export declare class MobileShellComponent {
10
+ menuButtons: IMobileShellMenuButton[];
11
+ protected activeButton: IMobileShellMenuButton | null;
12
+ protected expanded: boolean;
13
+ protected menuRef: TemplateRef<any> | null;
14
+ hideMenu(): void;
15
+ showMenu(): void;
16
+ protected onMenuButtonClick(button: IMobileShellMenuButton): void;
17
+ static ɵfac: i0.ɵɵFactoryDeclaration<MobileShellComponent, never>;
18
+ static ɵcmp: i0.ɵɵComponentDeclaration<MobileShellComponent, "he-mobile-shell", never, { "menuButtons": { "alias": "menuButtons"; "required": false; }; }, {}, never, ["*"], true, never>;
19
+ }
@@ -0,0 +1,21 @@
1
+ import { ElementRef, NgZone, OnDestroy, OnInit } from '@angular/core';
2
+ import * as i0 from "@angular/core";
3
+ export declare class ResizedEvent {
4
+ newRect: DOMRectReadOnly;
5
+ oldRect?: DOMRectReadOnly;
6
+ isFirst: boolean;
7
+ constructor(newRect: DOMRectReadOnly, oldRect: DOMRectReadOnly | undefined);
8
+ }
9
+ export declare class ResizedDirective implements OnInit, OnDestroy {
10
+ private readonly element;
11
+ private readonly zone;
12
+ private observer;
13
+ private oldRect?;
14
+ readonly resized: any;
15
+ constructor(element: ElementRef, zone: NgZone);
16
+ ngOnInit(): void;
17
+ ngOnDestroy(): void;
18
+ private observe;
19
+ static ɵfac: i0.ɵɵFactoryDeclaration<ResizedDirective, never>;
20
+ static ɵdir: i0.ɵɵDirectiveDeclaration<ResizedDirective, "[resized]", never, {}, { "resized": "resized"; }, never, never, false, never>;
21
+ }
@@ -0,0 +1,5 @@
1
+ import { take } from 'rxjs/operators';
2
+ export declare const distinctUntilChangedDeep: <T>() => import("rxjs").MonoTypeOperatorFunction<T>;
3
+ export declare const takeAfterViewInit: <T>(fn: () => T, settings?: {
4
+ take: number;
5
+ }) => import("rxjs").Observable<T>;
@@ -0,0 +1,3 @@
1
+ export * from './node-element.token';
2
+ export * from './toggle-option.directive';
3
+ export * from './node-element.directive';
@@ -0,0 +1,27 @@
1
+ import { QueryList } from '@angular/core';
2
+ import { Highlightable } from '@angular/cdk/a11y';
3
+ import { NodeElementToken } from './node-element.token';
4
+ import * as i0 from "@angular/core";
5
+ export declare class NodeElementDirective implements Highlightable, NodeElementToken {
6
+ descendants: QueryList<NodeElementToken>;
7
+ isActive: boolean;
8
+ private option;
9
+ private optionGroup;
10
+ private toggleDirective;
11
+ private _cd;
12
+ private el;
13
+ private parentNode;
14
+ get isVisible(): boolean;
15
+ get isOption(): boolean;
16
+ get isOptionGroup(): boolean;
17
+ get value(): any;
18
+ setActiveStyles(): void;
19
+ setInactiveStyles(): void;
20
+ expanded(): boolean;
21
+ showChildren(): void;
22
+ hideChildren(): void;
23
+ enterClick(): void;
24
+ scrollIntoView(options?: ScrollIntoViewOptions): void;
25
+ static ɵfac: i0.ɵɵFactoryDeclaration<NodeElementDirective, never>;
26
+ static ɵdir: i0.ɵɵDirectiveDeclaration<NodeElementDirective, "he-select-option, he-select-option-group", never, {}, {}, ["descendants"], never, true, never>;
27
+ }
@@ -0,0 +1,15 @@
1
+ import { InjectionToken } from '@angular/core';
2
+ import { Highlightable } from '@angular/cdk/a11y';
3
+ export declare const NODE_ELEMENT_TOKEN: InjectionToken<NodeElementToken<any>>;
4
+ export interface NodeElementToken<T = any> extends Highlightable {
5
+ isActive: boolean;
6
+ readonly isVisible: boolean;
7
+ readonly isOption: boolean;
8
+ readonly isOptionGroup: boolean;
9
+ readonly value: T;
10
+ expanded(): any;
11
+ showChildren(): void;
12
+ hideChildren(): void;
13
+ scrollIntoView(options?: ScrollIntoViewOptions): void;
14
+ enterClick(): void;
15
+ }
@@ -0,0 +1,9 @@
1
+ import * as i0 from "@angular/core";
2
+ export declare class ToggleOptionDirective {
3
+ private _parentOptionGroup;
4
+ private _option;
5
+ toggle(): void;
6
+ protected click(): void;
7
+ static ɵfac: i0.ɵɵFactoryDeclaration<ToggleOptionDirective, never>;
8
+ static ɵdir: i0.ɵɵDirectiveDeclaration<ToggleOptionDirective, "[toggleGroup]", never, {}, {}, never, never, true, never>;
9
+ }
@@ -0,0 +1,7 @@
1
+ export * from './select.component';
2
+ export * from './select-option-group';
3
+ export * from './select-option';
4
+ export * from './directives';
5
+ export * from './select-value';
6
+ export * from './select.module';
7
+ export * from './selectToken';
@@ -0,0 +1,2 @@
1
+ export * from './select-option.token';
2
+ export * from './select-option.component';
@@ -0,0 +1,22 @@
1
+ import { EventEmitter } from '@angular/core';
2
+ import { OptionToken } from './select-option.token';
3
+ import * as i0 from "@angular/core";
4
+ export declare class SelectOptionComponent<T> implements OptionToken<T> {
5
+ static nextId: number;
6
+ value: T | null;
7
+ staticChecked: boolean | undefined;
8
+ disabled: boolean;
9
+ selected: EventEmitter<SelectOptionComponent<T>>;
10
+ isSelected: boolean;
11
+ id: string;
12
+ private _cd;
13
+ private _parent;
14
+ protected get isChecked(): boolean;
15
+ select(): void;
16
+ highlightAsSelected(): void;
17
+ deselect(): void;
18
+ checkboxClicked($event: any): void;
19
+ protected isMultiple(): boolean;
20
+ static ɵfac: i0.ɵɵFactoryDeclaration<SelectOptionComponent<any>, never>;
21
+ static ɵcmp: i0.ɵɵComponentDeclaration<SelectOptionComponent<any>, "he-select-option", never, { "value": { "alias": "value"; "required": false; }; "staticChecked": { "alias": "staticChecked"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; }, { "selected": "selected"; }, never, ["*"], true, never>;
22
+ }
@@ -0,0 +1,14 @@
1
+ import { EventEmitter, InjectionToken } from '@angular/core';
2
+ export interface OptionToken<T> {
3
+ value: T | null;
4
+ staticChecked: boolean | undefined;
5
+ disabled: boolean;
6
+ selected: EventEmitter<OptionToken<T>>;
7
+ isSelected: boolean;
8
+ id: string;
9
+ select(): void;
10
+ highlightAsSelected(): void;
11
+ deselect(): void;
12
+ checkboxClicked($event: any): void;
13
+ }
14
+ export declare const SELECT_OPTION_TOKEN: InjectionToken<OptionToken<any>>;
@@ -0,0 +1,2 @@
1
+ export * from './select-option-group.token';
2
+ export * from './select-option-group.component';
@@ -0,0 +1,29 @@
1
+ import { ChangeDetectorRef } from '@angular/core';
2
+ import { OptionGroupToken } from './select-option-group.token';
3
+ import { NodeElementToken } from '../directives';
4
+ import { SelectToken } from '../selectToken';
5
+ import * as i0 from "@angular/core";
6
+ export declare class SelectOptionGroupComponent<T> implements OptionGroupToken {
7
+ private cd;
8
+ private _parent;
9
+ static nextId: number;
10
+ label: string;
11
+ disabled: boolean;
12
+ id: string;
13
+ protected expanded: boolean;
14
+ private _descendants;
15
+ constructor(cd: ChangeDetectorRef, _parent: SelectToken<T>);
16
+ get isAllSelected(): boolean;
17
+ protected get suffixIcon(): import("@fortawesome/fontawesome-common-types").IconDefinition;
18
+ protected get allOptionNodes(): NodeElementToken<any>[];
19
+ onGroupLabelClick($event: MouseEvent): void;
20
+ showChildren(): void;
21
+ hideChildren(): void;
22
+ toggleMenu(): void;
23
+ isExpanded(): boolean;
24
+ toggleSelectAll(): void;
25
+ selectAll(): void;
26
+ unselectAll(): void;
27
+ static ɵfac: i0.ɵɵFactoryDeclaration<SelectOptionGroupComponent<any>, never>;
28
+ static ɵcmp: i0.ɵɵComponentDeclaration<SelectOptionGroupComponent<any>, "he-select-option-group", never, { "label": { "alias": "label"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; }, {}, ["_descendants"], ["*"], true, never>;
29
+ }
@@ -0,0 +1,9 @@
1
+ import { InjectionToken } from '@angular/core';
2
+ export interface OptionGroupToken {
3
+ showChildren(): void;
4
+ hideChildren(): void;
5
+ toggleSelectAll(): void;
6
+ selectAll(): void;
7
+ unselectAll(): void;
8
+ }
9
+ export declare const OPTION_GROUP_TOKEN: InjectionToken<OptionGroupToken>;
@@ -0,0 +1 @@
1
+ export type SelectValue<T> = T | T[] | null;
@@ -0,0 +1,70 @@
1
+ import { AfterContentInit, ChangeDetectorRef, DestroyRef, ElementRef, EventEmitter, OnChanges, QueryList, SimpleChanges, TemplateRef } from '@angular/core';
2
+ import { ActiveDescendantKeyManager } from '@angular/cdk/a11y';
3
+ import { OptionToken } from './select-option';
4
+ import { SelectValue } from './select-value';
5
+ import { NodeElementToken } from './directives';
6
+ import { ControlValueAccessor } from '../control.value.accessor';
7
+ import { SelectToken } from './selectToken';
8
+ import * as i0 from "@angular/core";
9
+ export declare class SelectComponent<T> extends ControlValueAccessor<SelectValue<T>> implements OnChanges, AfterContentInit, SelectToken<T> {
10
+ private _cd;
11
+ private _hostEl;
12
+ private _destroyRef;
13
+ placeholder: string;
14
+ searchPlaceholder: string;
15
+ searchable: boolean;
16
+ disabled: boolean;
17
+ tabindex: string;
18
+ displayWith: ((value: T) => string | number) | null;
19
+ valueTemplate: TemplateRef<any>;
20
+ readonly opened: EventEmitter<void>;
21
+ readonly selectionChanged: EventEmitter<SelectValue<T>>;
22
+ readonly closed: EventEmitter<void>;
23
+ readonly searchChanged: EventEmitter<string>;
24
+ nodes: QueryList<NodeElementToken>;
25
+ options: QueryList<OptionToken<T>>;
26
+ searchInputEl: ElementRef<HTMLInputElement>;
27
+ isOpen: boolean;
28
+ private _selectionModel;
29
+ private _optionMap;
30
+ private _listKeyManager;
31
+ private _keyboardDictionary;
32
+ constructor(_cd: ChangeDetectorRef, _hostEl: ElementRef, _destroyRef: DestroyRef);
33
+ private _multiple;
34
+ set multiple(value: string | boolean);
35
+ get value(): SelectValue<T>;
36
+ set value(value: SelectValue<T>);
37
+ protected get displayValue(): string | number | (string | number)[] | SelectValue<T>;
38
+ protected get icon(): import("@fortawesome/fontawesome-common-types").IconDefinition;
39
+ protected get labelState(): "search" | "value";
40
+ protected get width(): string;
41
+ compareWith: (v1: T | null, v2: T | null) => boolean;
42
+ markAsTouched(): void;
43
+ open(): void;
44
+ close(): void;
45
+ writeValue(value: SelectValue<T>): void;
46
+ expandAll(): void;
47
+ setDisabledState?(isDisabled: boolean): void;
48
+ isMultiple(): boolean;
49
+ ngOnChanges(changes: SimpleChanges): void;
50
+ ngAfterContentInit(): void;
51
+ clearSelection(e?: Event): void;
52
+ handleSelection(option: OptionToken<T>): void;
53
+ getListKeyManager(): ActiveDescendantKeyManager<NodeElementToken<any>>;
54
+ emitChangeEvent(): void;
55
+ protected onKeyDown(e: KeyboardEvent): void;
56
+ protected onHandleInput(e: Event): void;
57
+ private _onEsc;
58
+ private _onEnter;
59
+ private _onArrowLeft;
60
+ private _onArrowRight;
61
+ private _onArrowDown;
62
+ private _onArrowUp;
63
+ private _horizontalNavigationHandler;
64
+ private _setupValue;
65
+ private _refreshOptionsMap;
66
+ private _highlightSelectedOptions;
67
+ private _findOptionsByValue;
68
+ static ɵfac: i0.ɵɵFactoryDeclaration<SelectComponent<any>, never>;
69
+ static ɵcmp: i0.ɵɵComponentDeclaration<SelectComponent<any>, "he-select", never, { "placeholder": { "alias": "placeholder"; "required": false; }; "searchPlaceholder": { "alias": "searchPlaceholder"; "required": false; }; "searchable": { "alias": "searchable"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "displayWith": { "alias": "displayWith"; "required": false; }; "valueTemplate": { "alias": "valueTemplate"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "value": { "alias": "value"; "required": false; }; "compareWith": { "alias": "compareWith"; "required": false; }; }, { "opened": "opened"; "selectionChanged": "selectionChanged"; "closed": "closed"; "searchChanged": "searchChanged"; }, ["nodes", "options"], ["*"], false, never>;
70
+ }