@stemy/ngx-utils 17.2.1 → 17.3.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.
Files changed (27) hide show
  1. package/esm2022/ngx-utils/common-types.mjs +1 -1
  2. package/esm2022/ngx-utils/components/dropdown-box/dropdown-box.component.mjs +59 -0
  3. package/esm2022/ngx-utils/components/dynamic-table/dynamic-table.component.mjs +88 -35
  4. package/esm2022/ngx-utils/components/pagination-menu/pagination-menu.component.mjs +7 -28
  5. package/esm2022/ngx-utils/directives/dropdown-content.directive.mjs +152 -0
  6. package/esm2022/ngx-utils/directives/dropdown-toggle.directive.mjs +46 -0
  7. package/esm2022/ngx-utils/directives/dropdown.directive.mjs +157 -0
  8. package/esm2022/ngx-utils/ngx-utils.imports.mjs +11 -1
  9. package/esm2022/ngx-utils/ngx-utils.module.mjs +42 -37
  10. package/esm2022/ngx-utils/pipes/includes.pipe.mjs +21 -0
  11. package/esm2022/ngx-utils/utils/misc.mjs +21 -0
  12. package/esm2022/public_api.mjs +7 -1
  13. package/fesm2022/stemy-ngx-utils.mjs +526 -59
  14. package/fesm2022/stemy-ngx-utils.mjs.map +1 -1
  15. package/ngx-utils/common-types.d.ts +1 -1
  16. package/ngx-utils/components/dropdown-box/dropdown-box.component.d.ts +55 -0
  17. package/ngx-utils/components/dynamic-table/dynamic-table.component.d.ts +31 -12
  18. package/ngx-utils/components/pagination-menu/pagination-menu.component.d.ts +1 -8
  19. package/ngx-utils/directives/dropdown-content.directive.d.ts +22 -0
  20. package/ngx-utils/directives/dropdown-toggle.directive.d.ts +16 -0
  21. package/ngx-utils/directives/dropdown.directive.d.ts +56 -0
  22. package/ngx-utils/ngx-utils.imports.d.ts +9 -4
  23. package/ngx-utils/ngx-utils.module.d.ts +42 -37
  24. package/ngx-utils/pipes/includes.pipe.d.ts +8 -0
  25. package/ngx-utils/utils/misc.d.ts +1 -0
  26. package/package.json +2 -1
  27. package/public_api.d.ts +6 -0
@@ -314,7 +314,7 @@ export interface ITableTemplates {
314
314
  [column: string]: ITableTemplate;
315
315
  }
316
316
  export interface ITableDataQuery {
317
- [column: string]: string;
317
+ [column: string]: string | string[] | boolean;
318
318
  }
319
319
  export type TableDataLoader = (page: number, rowsPerPage: number, orderBy: string, orderDescending: boolean, filter: string, query: ITableDataQuery) => Promise<IPaginationData>;
320
320
  export declare class ResourceIfContext {
@@ -0,0 +1,55 @@
1
+ import { AfterViewInit, OnChanges } from "@angular/core";
2
+ import { Placement } from "@floating-ui/utils";
3
+ import { Alignment, AutoPlacementOptions } from "@floating-ui/dom";
4
+ import { DropdownContentDirective } from "../../directives/dropdown-content.directive";
5
+ import * as i0 from "@angular/core";
6
+ export declare class DropdownBoxComponent implements AfterViewInit, OnChanges {
7
+ /**
8
+ * Determines if the dropdown should be closed even if we click inside it
9
+ */
10
+ closeInside: boolean;
11
+ /**
12
+ * Determines if the floating element needs to be placed in the root node or keep where it was before
13
+ */
14
+ attachToRoot: boolean;
15
+ /**
16
+ * Where to place the floating element relative to the reference element.
17
+ */
18
+ placement: Placement;
19
+ /**
20
+ * The axis that runs along the alignment of the floating element. Determines
21
+ * whether to check for most space along this axis.
22
+ * @default false
23
+ */
24
+ crossAxis?: boolean;
25
+ /**
26
+ * Choose placements with a particular alignment.
27
+ * @default undefined
28
+ */
29
+ alignment?: Alignment | null;
30
+ /**
31
+ * Whether to choose placements with the opposite alignment if the preferred
32
+ * alignment does not fit.
33
+ * @default true
34
+ */
35
+ autoAlignment?: boolean;
36
+ /**
37
+ * Which placements are allowed to be chosen. Placements must be within the
38
+ * `alignment` option if explicitly set.
39
+ * @default allPlacements (variable)
40
+ */
41
+ allowedPlacements?: Array<Placement>;
42
+ /**
43
+ * Adds a class to the main div element and also to the content
44
+ * ('drop' by default which translates to 'drop-content-wrapper' in case of content)
45
+ */
46
+ componentClass: string;
47
+ autoPlacement: AutoPlacementOptions;
48
+ content: DropdownContentDirective;
49
+ constructor();
50
+ protected makeAutoPlacementOpts(): void;
51
+ ngAfterViewInit(): void;
52
+ ngOnChanges(): void;
53
+ static ɵfac: i0.ɵɵFactoryDeclaration<DropdownBoxComponent, never>;
54
+ static ɵcmp: i0.ɵɵComponentDeclaration<DropdownBoxComponent, "dropdown-box", never, { "closeInside": { "alias": "closeInside"; "required": false; }; "attachToRoot": { "alias": "attachToRoot"; "required": false; }; "placement": { "alias": "placement"; "required": false; }; "crossAxis": { "alias": "crossAxis"; "required": false; }; "alignment": { "alias": "alignment"; "required": false; }; "autoAlignment": { "alias": "autoAlignment"; "required": false; }; "allowedPlacements": { "alias": "allowedPlacements"; "required": false; }; "componentClass": { "alias": "componentClass"; "required": false; }; }, {}, never, ["[toggle-content]", "*"], false, never>;
55
+ }
@@ -1,18 +1,37 @@
1
- import { AfterContentInit, AfterViewInit, OnChanges, QueryList, SimpleChanges, TemplateRef } from "@angular/core";
2
- import { IPaginationData, ITableColumns, ITableDataQuery, ITableTemplates, TableColumns, TableDataLoader } from "../../common-types";
1
+ import { AfterContentInit, AfterViewInit, ElementRef, OnChanges, QueryList, SimpleChanges, TemplateRef } from "@angular/core";
2
+ import { IPaginationData, ITableColumns, ITableDataQuery, ITableTemplates, PaginationItemContext, TableColumns, TableDataLoader } from "../../common-types";
3
3
  import { DynamicTableTemplateDirective } from "../../directives/dynamic-table-template.directive";
4
4
  import { PaginationDirective } from "../../directives/pagination.directive";
5
+ import { DropdownDirective } from "../../directives/dropdown.directive";
5
6
  import * as i0 from "@angular/core";
6
7
  export declare class DynamicTableComponent implements AfterContentInit, AfterViewInit, OnChanges {
7
- label: string;
8
- placeholder: string;
8
+ protected element: ElementRef<HTMLElement>;
9
9
  dataLoader: TableDataLoader;
10
10
  data: any[];
11
+ selected: any;
11
12
  page: number;
12
13
  urlParam: string;
13
14
  parallelData: any[];
14
15
  columns: TableColumns;
16
+ /**
17
+ * Parameter for displaying a simple filter search box
18
+ */
15
19
  showFilter: boolean;
20
+ /**
21
+ * Parameter for specifying a label for filter
22
+ */
23
+ filterLabel: string;
24
+ /**
25
+ * Parameter for specifying a placeholder for filter
26
+ */
27
+ placeholder: string;
28
+ /**
29
+ * Parameter for displaying an item per page selector dropdown with the specified numbers
30
+ */
31
+ showItems: number[];
32
+ /**
33
+ * Parameter for setting how many items should be displayed by default
34
+ */
16
35
  itemsPerPage: number;
17
36
  updateTime: number;
18
37
  filterTime: number;
@@ -33,24 +52,24 @@ export declare class DynamicTableComponent implements AfterContentInit, AfterVie
33
52
  get items(): any[];
34
53
  rowTemplate: TemplateRef<any>;
35
54
  wrapperTemplate: TemplateRef<any>;
36
- filterTemplate: TemplateRef<any>;
37
55
  columnsTemplate: TemplateRef<any>;
38
56
  defaultRowTemplate: TemplateRef<any>;
39
57
  defaultWrapperTemplate: TemplateRef<any>;
40
- defaultFilterTemplate: TemplateRef<any>;
41
58
  protected pagination: PaginationDirective;
42
59
  protected templateDirectives: QueryList<DynamicTableTemplateDirective>;
43
- private static compare;
44
- constructor();
60
+ protected static compare(orderBy: string, a: PaginationItemContext, b: PaginationItemContext): number;
61
+ constructor(element: ElementRef<HTMLElement>);
62
+ setProperty(name: string, value: any): void;
45
63
  ngAfterContentInit(): void;
46
64
  ngAfterViewInit(): void;
47
65
  ngOnChanges(changes: SimpleChanges): void;
48
66
  refresh(time?: number): void;
49
67
  setFilter(filter: string): void;
50
- setOrder(column: string): void;
51
- updateQuery(col: string, value: string): void;
68
+ setSorting(column: string, toggle?: DropdownDirective): void;
69
+ setQueryValue(c: string, value: string | boolean): void;
70
+ setItemsPerPage(count: number): void;
52
71
  loadData: (page: number, itemsPerPage: number) => Promise<IPaginationData>;
53
- private loadLocalData;
72
+ protected loadLocalData(page: number, rowsPerPage: number, orderBy: string, orderDescending: boolean, filter: string): Promise<IPaginationData>;
54
73
  static ɵfac: i0.ɵɵFactoryDeclaration<DynamicTableComponent, never>;
55
- static ɵcmp: i0.ɵɵComponentDeclaration<DynamicTableComponent, "dynamic-table", never, { "label": { "alias": "label"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "dataLoader": { "alias": "dataLoader"; "required": false; }; "data": { "alias": "data"; "required": false; }; "page": { "alias": "page"; "required": false; }; "urlParam": { "alias": "urlParam"; "required": false; }; "parallelData": { "alias": "parallelData"; "required": false; }; "columns": { "alias": "columns"; "required": false; }; "showFilter": { "alias": "showFilter"; "required": false; }; "itemsPerPage": { "alias": "itemsPerPage"; "required": false; }; "updateTime": { "alias": "updateTime"; "required": false; }; "filterTime": { "alias": "filterTime"; "required": false; }; "maxPages": { "alias": "maxPages"; "required": false; }; "directionLinks": { "alias": "directionLinks"; "required": false; }; "boundaryLinks": { "alias": "boundaryLinks"; "required": false; }; "orderBy": { "alias": "orderBy"; "required": false; }; "orderDescending": { "alias": "orderDescending"; "required": false; }; "testId": { "alias": "testId"; "required": false; }; "titlePrefix": { "alias": "titlePrefix"; "required": false; }; }, {}, ["rowTemplate", "wrapperTemplate", "filterTemplate", "templateDirectives"], never, false, never>;
74
+ static ɵcmp: i0.ɵɵComponentDeclaration<DynamicTableComponent, "dynamic-table", never, { "dataLoader": { "alias": "dataLoader"; "required": false; }; "data": { "alias": "data"; "required": false; }; "selected": { "alias": "selected"; "required": false; }; "page": { "alias": "page"; "required": false; }; "urlParam": { "alias": "urlParam"; "required": false; }; "parallelData": { "alias": "parallelData"; "required": false; }; "columns": { "alias": "columns"; "required": false; }; "showFilter": { "alias": "showFilter"; "required": false; }; "filterLabel": { "alias": "filterLabel"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "showItems": { "alias": "showItems"; "required": false; }; "itemsPerPage": { "alias": "itemsPerPage"; "required": false; }; "updateTime": { "alias": "updateTime"; "required": false; }; "filterTime": { "alias": "filterTime"; "required": false; }; "maxPages": { "alias": "maxPages"; "required": false; }; "directionLinks": { "alias": "directionLinks"; "required": false; }; "boundaryLinks": { "alias": "boundaryLinks"; "required": false; }; "orderBy": { "alias": "orderBy"; "required": false; }; "orderDescending": { "alias": "orderDescending"; "required": false; }; "testId": { "alias": "testId"; "required": false; }; "titlePrefix": { "alias": "titlePrefix"; "required": false; }; }, {}, ["rowTemplate", "wrapperTemplate", "templateDirectives"], ["[table-features-before]", "[table-features-after]", "[table-top]", "[table-bottom]"], false, never>;
56
75
  }
@@ -1,30 +1,23 @@
1
1
  import { OnChanges, OnDestroy, OnInit, SimpleChanges } from "@angular/core";
2
2
  import { StateService } from "../../services/state.service";
3
3
  import { PaginationDirective } from "../../directives/pagination.directive";
4
- import { IIconService } from "../../common-types";
5
4
  import * as i0 from "@angular/core";
6
5
  export declare class PaginationMenuComponent implements OnInit, OnDestroy, OnChanges {
7
6
  state: StateService;
8
7
  pagination: PaginationDirective;
9
- icons: IIconService;
10
8
  maxSize: number;
11
9
  urlParam: string;
12
10
  directionLinks: boolean;
13
11
  boundaryLinks: boolean;
14
12
  pages: number[];
15
- firstLabel: string;
16
- prevLabel: string;
17
- nextLabel: string;
18
- lastLabel: string;
19
13
  get hasPrev(): boolean;
20
14
  get hasNext(): boolean;
21
15
  private onRefresh;
22
- constructor(state: StateService, pagination: PaginationDirective, icons: IIconService);
16
+ constructor(state: StateService, pagination: PaginationDirective);
23
17
  ngOnInit(): void;
24
18
  ngOnDestroy(): void;
25
19
  ngOnChanges(changes: SimpleChanges): void;
26
20
  paginate(page: number): void;
27
- protected setIcon(labelName: string, icon: string): void;
28
21
  protected setPages(): number;
29
22
  static ɵfac: i0.ɵɵFactoryDeclaration<PaginationMenuComponent, never>;
30
23
  static ɵcmp: i0.ɵɵComponentDeclaration<PaginationMenuComponent, "pagination-menu", never, { "maxSize": { "alias": "maxSize"; "required": false; }; "urlParam": { "alias": "urlParam"; "required": false; }; "directionLinks": { "alias": "directionLinks"; "required": false; }; "boundaryLinks": { "alias": "boundaryLinks"; "required": false; }; }, {}, never, never, false, never>;
@@ -0,0 +1,22 @@
1
+ import { OnDestroy, OnInit, TemplateRef, ViewContainerRef } from "@angular/core";
2
+ import { Subscription } from "rxjs";
3
+ import { DropdownDirective } from "./dropdown.directive";
4
+ import * as i0 from "@angular/core";
5
+ export declare class DropdownContentDirective implements OnInit, OnDestroy {
6
+ protected vcr: ViewContainerRef;
7
+ protected rootElem: HTMLElement;
8
+ protected dropdown: DropdownDirective;
9
+ readonly templateRef: TemplateRef<any>;
10
+ protected subscription: Subscription;
11
+ protected lastPlacement: string;
12
+ protected cleanUp: () => void;
13
+ constructor(vcr: ViewContainerRef, rootElem: HTMLElement, dropdown: DropdownDirective, templateRef: TemplateRef<any>);
14
+ ngOnInit(): void;
15
+ ngOnDestroy(): void;
16
+ protected createView(init?: boolean): void;
17
+ protected destroyView(): void;
18
+ protected createWrapper(): HTMLDivElement;
19
+ initialize(): void;
20
+ static ɵfac: i0.ɵɵFactoryDeclaration<DropdownContentDirective, [null, { optional: true; }, { optional: true; }, { optional: true; }]>;
21
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DropdownContentDirective, "[dropdownContent]", ["dropdown-content"], {}, {}, never, never, false, never>;
22
+ }
@@ -0,0 +1,16 @@
1
+ import { ChangeDetectorRef, ElementRef } from "@angular/core";
2
+ import { DropdownDirective } from "./dropdown.directive";
3
+ import { AsyncMethodBase } from "./async-method.base";
4
+ import { AsyncMethod, IToasterService } from "../common-types";
5
+ import * as i0 from "@angular/core";
6
+ export declare class DropdownToggleDirective extends AsyncMethodBase {
7
+ readonly element: ElementRef;
8
+ readonly dropdown: DropdownDirective;
9
+ beforeOpen: AsyncMethod;
10
+ switch: boolean;
11
+ constructor(element: ElementRef, dropdown: DropdownDirective, toaster: IToasterService, cdr: ChangeDetectorRef);
12
+ protected getMethod(): AsyncMethod;
13
+ callMethod(): boolean;
14
+ static ɵfac: i0.ɵɵFactoryDeclaration<DropdownToggleDirective, never>;
15
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DropdownToggleDirective, "[dropdownToggle]", ["dropdown-toggle"], { "beforeOpen": { "alias": "beforeOpen"; "required": false; }; "switch": { "alias": "switch"; "required": false; }; }, {}, never, never, false, never>;
16
+ }
@@ -0,0 +1,56 @@
1
+ import { ElementRef, EventEmitter, OnDestroy } from "@angular/core";
2
+ import { AutoPlacementOptions, Placement } from "@floating-ui/dom";
3
+ import * as i0 from "@angular/core";
4
+ export declare class DropdownDirective implements OnDestroy {
5
+ protected element: ElementRef<HTMLElement>;
6
+ protected static active: DropdownDirective;
7
+ protected opened: boolean;
8
+ protected disabled: boolean;
9
+ /**
10
+ * Determines if the dropdown should be closed even if we click inside it
11
+ */
12
+ closeInside: boolean;
13
+ /**
14
+ * Determines if the floating element needs to be placed in the root node or keep where it was before
15
+ */
16
+ attachToRoot: boolean;
17
+ /**
18
+ * Where to place the floating element relative to the reference element.
19
+ */
20
+ placement: Placement;
21
+ /**
22
+ * Optimizes the visibility of the floating element by choosing the placement
23
+ * that has the most space available automatically, without needing to specify a
24
+ * preferred placement. Alternative to `flip`.
25
+ * @see https://floating-ui.com/docs/autoPlacement
26
+ */
27
+ autoPlacement: AutoPlacementOptions;
28
+ /**
29
+ * Determines if the dropdown content should be displayed in a fixed full screen view under this window width
30
+ * @default 0
31
+ */
32
+ mobileViewUnder: number;
33
+ /**
34
+ * Determines if the dropdown should react to keys to close like 'Esc'
35
+ * @default true
36
+ */
37
+ keyboardHandler: boolean;
38
+ onShown: EventEmitter<DropdownDirective>;
39
+ onHidden: EventEmitter<DropdownDirective>;
40
+ onKeyboard: EventEmitter<KeyboardEvent>;
41
+ contentElement: HTMLElement;
42
+ private readonly onClick;
43
+ private readonly onKeyDown;
44
+ get nativeElement(): HTMLElement;
45
+ get isOpened(): boolean;
46
+ get getDisabled(): boolean;
47
+ set isDisabled(value: boolean);
48
+ constructor(element: ElementRef<HTMLElement>);
49
+ ngOnDestroy(): void;
50
+ showEvent(): void;
51
+ hideEvent(): void;
52
+ show($event?: Event): boolean;
53
+ hide(): boolean;
54
+ static ɵfac: i0.ɵɵFactoryDeclaration<DropdownDirective, never>;
55
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DropdownDirective, "[dd],[drop-down]", ["dropdown"], { "closeInside": { "alias": "closeInside"; "required": false; }; "attachToRoot": { "alias": "attachToRoot"; "required": false; }; "placement": { "alias": "placement"; "required": false; }; "autoPlacement": { "alias": "autoPlacement"; "required": false; }; "mobileViewUnder": { "alias": "mobileViewUnder"; "required": false; }; "keyboardHandler": { "alias": "keyboardHandler"; "required": false; }; "isDisabled": { "alias": "isDisabled"; "required": false; }; }, { "onShown": "onShown"; "onHidden": "onHidden"; "onKeyboard": "onKeyboard"; }, never, never, false, never>;
56
+ }
@@ -26,6 +26,9 @@ import { ResizeEventPlugin } from "./plugins/resize-event.plugin";
26
26
  import { ScrollEventPlugin } from "./plugins/scroll-event.plugin";
27
27
  import { AsyncMethodBase } from "./directives/async-method.base";
28
28
  import { BackgroundDirective } from "./directives/background.directive";
29
+ import { DropdownDirective } from "./directives/dropdown.directive";
30
+ import { DropdownContentDirective } from "./directives/dropdown-content.directive";
31
+ import { DropdownToggleDirective } from "./directives/dropdown-toggle.directive";
29
32
  import { DynamicTableTemplateDirective } from "./directives/dynamic-table-template.directive";
30
33
  import { GlobalTemplateDirective } from "./directives/global-template.directive";
31
34
  import { IconDirective } from "./directives/icon.directive";
@@ -40,17 +43,19 @@ import { UnorderedListTemplateDirective } from "./directives/unordered-list-temp
40
43
  import { FilterPipe } from "./pipes/filter.pipe";
41
44
  import { FormatNumberPipe } from "./pipes/format-number.pipe";
42
45
  import { GlobalTemplatePipe } from "./pipes/global-template.pipe";
46
+ import { IncludesPipe } from "./pipes/includes.pipe";
43
47
  import { ReducePipe } from "./pipes/reduce.pipe";
44
48
  import { RoundPipe } from "./pipes/round.pipe";
45
49
  import { SafeHtmlPipe } from "./pipes/safe-html.pipe";
46
50
  import { TranslatePipe } from "./pipes/translate.pipe";
51
+ import { DropdownBoxComponent } from "./components/dropdown-box/dropdown-box.component";
47
52
  import { DynamicTableComponent } from "./components/dynamic-table/dynamic-table.component";
48
53
  import { PaginationMenuComponent } from "./components/pagination-menu/pagination-menu.component";
49
54
  import { UnorderedListComponent } from "./components/unordered-list/unordered-list.component";
50
- export declare const pipes: (typeof FilterPipe | typeof FormatNumberPipe | typeof GlobalTemplatePipe | typeof ReducePipe | typeof RoundPipe | typeof SafeHtmlPipe | typeof TranslatePipe)[];
51
- export declare const directives: (typeof AsyncMethodBase | typeof BackgroundDirective | typeof DynamicTableTemplateDirective | typeof GlobalTemplateDirective | typeof IconDirective | typeof NgxTemplateOutletDirective | typeof PaginationDirective | typeof PaginationItemDirective | typeof ResourceIfDirective | typeof StickyDirective | typeof StickyClassDirective | typeof UnorderedListItemDirective | typeof UnorderedListTemplateDirective)[];
52
- export declare const components: (typeof UnorderedListComponent | typeof DynamicTableComponent | typeof PaginationMenuComponent)[];
53
- export declare const providers: (typeof UniversalService | typeof StateService | typeof AuthGuard | typeof BaseHttpClient | typeof StorageService | typeof BaseHttpService | typeof WasmService | typeof AclService | typeof StaticAuthService | typeof ConfigService | typeof ErrorHandlerService | typeof EventsService | typeof FormatterService | typeof GlobalTemplateService | typeof IconService | typeof StaticLanguageService | typeof OpenApiService | typeof ConsoleToasterService | typeof TranslatedUrlSerializer | typeof PromiseService | typeof FilterPipe | typeof FormatNumberPipe | typeof GlobalTemplatePipe | typeof ReducePipe | typeof RoundPipe | typeof SafeHtmlPipe | typeof TranslatePipe | typeof DeviceDetectorService | {
55
+ export declare const pipes: (typeof FilterPipe | typeof FormatNumberPipe | typeof GlobalTemplatePipe | typeof IncludesPipe | typeof ReducePipe | typeof RoundPipe | typeof SafeHtmlPipe | typeof TranslatePipe)[];
56
+ export declare const directives: (typeof AsyncMethodBase | typeof BackgroundDirective | typeof DropdownDirective | typeof DropdownContentDirective | typeof DropdownToggleDirective | typeof DynamicTableTemplateDirective | typeof GlobalTemplateDirective | typeof IconDirective | typeof NgxTemplateOutletDirective | typeof PaginationDirective | typeof PaginationItemDirective | typeof ResourceIfDirective | typeof StickyDirective | typeof StickyClassDirective | typeof UnorderedListItemDirective | typeof UnorderedListTemplateDirective)[];
57
+ export declare const components: (typeof DropdownBoxComponent | typeof DynamicTableComponent | typeof PaginationMenuComponent | typeof UnorderedListComponent)[];
58
+ export declare const providers: (typeof FilterPipe | typeof FormatNumberPipe | typeof GlobalTemplatePipe | typeof IncludesPipe | typeof ReducePipe | typeof RoundPipe | typeof SafeHtmlPipe | typeof TranslatePipe | typeof BaseHttpClient | typeof BaseHttpService | typeof AuthGuard | typeof AclService | typeof StaticAuthService | typeof ConfigService | typeof ErrorHandlerService | typeof EventsService | typeof FormatterService | typeof GlobalTemplateService | typeof IconService | typeof StaticLanguageService | typeof OpenApiService | typeof PromiseService | typeof StateService | typeof StorageService | typeof ConsoleToasterService | typeof TranslatedUrlSerializer | typeof UniversalService | typeof WasmService | typeof DeviceDetectorService | {
54
59
  provide: import("@angular/core").InjectionToken<import("@angular/platform-browser").EventManagerPlugin[]>;
55
60
  useClass: typeof ResizeEventPlugin;
56
61
  multi: boolean;
@@ -12,42 +12,47 @@ import * as i8 from "./pipes/get-type.pipe";
12
12
  import * as i9 from "./pipes/get-value.pipe";
13
13
  import * as i10 from "./pipes/global-template.pipe";
14
14
  import * as i11 from "./pipes/group-by.pipe";
15
- import * as i12 from "./pipes/is-type.pipe";
16
- import * as i13 from "./pipes/join.pipe";
17
- import * as i14 from "./pipes/keys.pipe";
18
- import * as i15 from "./pipes/map.pipe";
19
- import * as i16 from "./pipes/max.pipe";
20
- import * as i17 from "./pipes/min.pipe";
21
- import * as i18 from "./pipes/pop.pipe";
22
- import * as i19 from "./pipes/reduce.pipe";
23
- import * as i20 from "./pipes/remap.pipe";
24
- import * as i21 from "./pipes/replace.pipe";
25
- import * as i22 from "./pipes/reverse.pipe";
26
- import * as i23 from "./pipes/round.pipe";
27
- import * as i24 from "./pipes/safe-html.pipe";
28
- import * as i25 from "./pipes/shift.pipe";
29
- import * as i26 from "./pipes/split.pipe";
30
- import * as i27 from "./pipes/translate.pipe";
31
- import * as i28 from "./pipes/values.pipe";
32
- import * as i29 from "./directives/async-method.base";
33
- import * as i30 from "./directives/async-method.directive";
34
- import * as i31 from "./directives/background.directive";
35
- import * as i32 from "./directives/dynamic-table-template.directive";
36
- import * as i33 from "./directives/global-template.directive";
37
- import * as i34 from "./directives/icon.directive";
38
- import * as i35 from "./directives/ngx-template-outlet.directive";
39
- import * as i36 from "./directives/pagination.directive";
40
- import * as i37 from "./directives/pagination-item.directive";
41
- import * as i38 from "./directives/resource-if.directive";
42
- import * as i39 from "./directives/sticky.directive";
43
- import * as i40 from "./directives/sticky-class.directive";
44
- import * as i41 from "./directives/unordered-list-item.directive";
45
- import * as i42 from "./directives/unordered-list-template.directive";
46
- import * as i43 from "./components/dynamic-table/dynamic-table.component";
47
- import * as i44 from "./components/pagination-menu/pagination-menu.component";
48
- import * as i45 from "./components/unordered-list/unordered-list.component";
49
- import * as i46 from "@angular/common";
50
- import * as i47 from "@angular/forms";
15
+ import * as i12 from "./pipes/includes.pipe";
16
+ import * as i13 from "./pipes/is-type.pipe";
17
+ import * as i14 from "./pipes/join.pipe";
18
+ import * as i15 from "./pipes/keys.pipe";
19
+ import * as i16 from "./pipes/map.pipe";
20
+ import * as i17 from "./pipes/max.pipe";
21
+ import * as i18 from "./pipes/min.pipe";
22
+ import * as i19 from "./pipes/pop.pipe";
23
+ import * as i20 from "./pipes/reduce.pipe";
24
+ import * as i21 from "./pipes/remap.pipe";
25
+ import * as i22 from "./pipes/replace.pipe";
26
+ import * as i23 from "./pipes/reverse.pipe";
27
+ import * as i24 from "./pipes/round.pipe";
28
+ import * as i25 from "./pipes/safe-html.pipe";
29
+ import * as i26 from "./pipes/shift.pipe";
30
+ import * as i27 from "./pipes/split.pipe";
31
+ import * as i28 from "./pipes/translate.pipe";
32
+ import * as i29 from "./pipes/values.pipe";
33
+ import * as i30 from "./directives/async-method.base";
34
+ import * as i31 from "./directives/async-method.directive";
35
+ import * as i32 from "./directives/background.directive";
36
+ import * as i33 from "./directives/dropdown.directive";
37
+ import * as i34 from "./directives/dropdown-content.directive";
38
+ import * as i35 from "./directives/dropdown-toggle.directive";
39
+ import * as i36 from "./directives/dynamic-table-template.directive";
40
+ import * as i37 from "./directives/global-template.directive";
41
+ import * as i38 from "./directives/icon.directive";
42
+ import * as i39 from "./directives/ngx-template-outlet.directive";
43
+ import * as i40 from "./directives/pagination.directive";
44
+ import * as i41 from "./directives/pagination-item.directive";
45
+ import * as i42 from "./directives/resource-if.directive";
46
+ import * as i43 from "./directives/sticky.directive";
47
+ import * as i44 from "./directives/sticky-class.directive";
48
+ import * as i45 from "./directives/unordered-list-item.directive";
49
+ import * as i46 from "./directives/unordered-list-template.directive";
50
+ import * as i47 from "./components/dropdown-box/dropdown-box.component";
51
+ import * as i48 from "./components/dynamic-table/dynamic-table.component";
52
+ import * as i49 from "./components/pagination-menu/pagination-menu.component";
53
+ import * as i50 from "./components/unordered-list/unordered-list.component";
54
+ import * as i51 from "@angular/common";
55
+ import * as i52 from "@angular/forms";
51
56
  export declare function loadBaseUrl(): string;
52
57
  export declare function loadBaseHref(baseUrl: string): string;
53
58
  export declare class NgxUtilsModule {
@@ -56,6 +61,6 @@ export declare class NgxUtilsModule {
56
61
  static provideUtils(config?: IModuleConfig): EnvironmentProviders;
57
62
  constructor();
58
63
  static ɵfac: i0.ɵɵFactoryDeclaration<NgxUtilsModule, never>;
59
- static ɵmod: i0.ɵɵNgModuleDeclaration<NgxUtilsModule, [typeof i1.ChunkPipe, typeof i2.EntriesPipe, typeof i3.ExtraItemPropertiesPipe, typeof i4.FilterPipe, typeof i5.FindPipe, typeof i6.FormatNumberPipe, typeof i7.GetOffsetPipe, typeof i8.GetTypePipe, typeof i9.GetValuePipe, typeof i10.GlobalTemplatePipe, typeof i11.GroupByPipe, typeof i12.IsTypePipe, typeof i13.JoinPipe, typeof i14.KeysPipe, typeof i15.MapPipe, typeof i16.MaxPipe, typeof i17.MinPipe, typeof i18.PopPipe, typeof i19.ReducePipe, typeof i20.RemapPipe, typeof i21.ReplacePipe, typeof i22.ReversePipe, typeof i23.RoundPipe, typeof i24.SafeHtmlPipe, typeof i25.ShiftPipe, typeof i26.SplitPipe, typeof i27.TranslatePipe, typeof i28.ValuesPipe, typeof i29.AsyncMethodBase, typeof i30.AsyncMethodDirective, typeof i31.BackgroundDirective, typeof i32.DynamicTableTemplateDirective, typeof i33.GlobalTemplateDirective, typeof i34.IconDirective, typeof i35.NgxTemplateOutletDirective, typeof i36.PaginationDirective, typeof i37.PaginationItemDirective, typeof i38.ResourceIfDirective, typeof i39.StickyDirective, typeof i40.StickyClassDirective, typeof i41.UnorderedListItemDirective, typeof i42.UnorderedListTemplateDirective, typeof i43.DynamicTableComponent, typeof i44.PaginationMenuComponent, typeof i45.UnorderedListComponent], [typeof i46.CommonModule, typeof i47.FormsModule], [typeof i1.ChunkPipe, typeof i2.EntriesPipe, typeof i3.ExtraItemPropertiesPipe, typeof i4.FilterPipe, typeof i5.FindPipe, typeof i6.FormatNumberPipe, typeof i7.GetOffsetPipe, typeof i8.GetTypePipe, typeof i9.GetValuePipe, typeof i10.GlobalTemplatePipe, typeof i11.GroupByPipe, typeof i12.IsTypePipe, typeof i13.JoinPipe, typeof i14.KeysPipe, typeof i15.MapPipe, typeof i16.MaxPipe, typeof i17.MinPipe, typeof i18.PopPipe, typeof i19.ReducePipe, typeof i20.RemapPipe, typeof i21.ReplacePipe, typeof i22.ReversePipe, typeof i23.RoundPipe, typeof i24.SafeHtmlPipe, typeof i25.ShiftPipe, typeof i26.SplitPipe, typeof i27.TranslatePipe, typeof i28.ValuesPipe, typeof i29.AsyncMethodBase, typeof i30.AsyncMethodDirective, typeof i31.BackgroundDirective, typeof i32.DynamicTableTemplateDirective, typeof i33.GlobalTemplateDirective, typeof i34.IconDirective, typeof i35.NgxTemplateOutletDirective, typeof i36.PaginationDirective, typeof i37.PaginationItemDirective, typeof i38.ResourceIfDirective, typeof i39.StickyDirective, typeof i40.StickyClassDirective, typeof i41.UnorderedListItemDirective, typeof i42.UnorderedListTemplateDirective, typeof i43.DynamicTableComponent, typeof i44.PaginationMenuComponent, typeof i45.UnorderedListComponent, typeof i47.FormsModule]>;
64
+ static ɵmod: i0.ɵɵNgModuleDeclaration<NgxUtilsModule, [typeof i1.ChunkPipe, typeof i2.EntriesPipe, typeof i3.ExtraItemPropertiesPipe, typeof i4.FilterPipe, typeof i5.FindPipe, typeof i6.FormatNumberPipe, typeof i7.GetOffsetPipe, typeof i8.GetTypePipe, typeof i9.GetValuePipe, typeof i10.GlobalTemplatePipe, typeof i11.GroupByPipe, typeof i12.IncludesPipe, typeof i13.IsTypePipe, typeof i14.JoinPipe, typeof i15.KeysPipe, typeof i16.MapPipe, typeof i17.MaxPipe, typeof i18.MinPipe, typeof i19.PopPipe, typeof i20.ReducePipe, typeof i21.RemapPipe, typeof i22.ReplacePipe, typeof i23.ReversePipe, typeof i24.RoundPipe, typeof i25.SafeHtmlPipe, typeof i26.ShiftPipe, typeof i27.SplitPipe, typeof i28.TranslatePipe, typeof i29.ValuesPipe, typeof i30.AsyncMethodBase, typeof i31.AsyncMethodDirective, typeof i32.BackgroundDirective, typeof i33.DropdownDirective, typeof i34.DropdownContentDirective, typeof i35.DropdownToggleDirective, typeof i36.DynamicTableTemplateDirective, typeof i37.GlobalTemplateDirective, typeof i38.IconDirective, typeof i39.NgxTemplateOutletDirective, typeof i40.PaginationDirective, typeof i41.PaginationItemDirective, typeof i42.ResourceIfDirective, typeof i43.StickyDirective, typeof i44.StickyClassDirective, typeof i45.UnorderedListItemDirective, typeof i46.UnorderedListTemplateDirective, typeof i47.DropdownBoxComponent, typeof i48.DynamicTableComponent, typeof i49.PaginationMenuComponent, typeof i50.UnorderedListComponent], [typeof i51.CommonModule, typeof i52.FormsModule], [typeof i1.ChunkPipe, typeof i2.EntriesPipe, typeof i3.ExtraItemPropertiesPipe, typeof i4.FilterPipe, typeof i5.FindPipe, typeof i6.FormatNumberPipe, typeof i7.GetOffsetPipe, typeof i8.GetTypePipe, typeof i9.GetValuePipe, typeof i10.GlobalTemplatePipe, typeof i11.GroupByPipe, typeof i12.IncludesPipe, typeof i13.IsTypePipe, typeof i14.JoinPipe, typeof i15.KeysPipe, typeof i16.MapPipe, typeof i17.MaxPipe, typeof i18.MinPipe, typeof i19.PopPipe, typeof i20.ReducePipe, typeof i21.RemapPipe, typeof i22.ReplacePipe, typeof i23.ReversePipe, typeof i24.RoundPipe, typeof i25.SafeHtmlPipe, typeof i26.ShiftPipe, typeof i27.SplitPipe, typeof i28.TranslatePipe, typeof i29.ValuesPipe, typeof i30.AsyncMethodBase, typeof i31.AsyncMethodDirective, typeof i32.BackgroundDirective, typeof i33.DropdownDirective, typeof i34.DropdownContentDirective, typeof i35.DropdownToggleDirective, typeof i36.DynamicTableTemplateDirective, typeof i37.GlobalTemplateDirective, typeof i38.IconDirective, typeof i39.NgxTemplateOutletDirective, typeof i40.PaginationDirective, typeof i41.PaginationItemDirective, typeof i42.ResourceIfDirective, typeof i43.StickyDirective, typeof i44.StickyClassDirective, typeof i45.UnorderedListItemDirective, typeof i46.UnorderedListTemplateDirective, typeof i47.DropdownBoxComponent, typeof i48.DynamicTableComponent, typeof i49.PaginationMenuComponent, typeof i50.UnorderedListComponent, typeof i52.FormsModule]>;
60
65
  static ɵinj: i0.ɵɵInjectorDeclaration<NgxUtilsModule>;
61
66
  }
@@ -0,0 +1,8 @@
1
+ import { PipeTransform } from "@angular/core";
2
+ import * as i0 from "@angular/core";
3
+ export declare function defaultFilter(): boolean;
4
+ export declare class IncludesPipe implements PipeTransform {
5
+ transform(array: any, ...values: any[]): boolean;
6
+ static ɵfac: i0.ɵɵFactoryDeclaration<IncludesPipe, never>;
7
+ static ɵpipe: i0.ɵɵPipeDeclaration<IncludesPipe, "includes", false>;
8
+ }
@@ -0,0 +1 @@
1
+ export declare function getCssVariables(elem: HTMLElement): Record<string, string>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stemy/ngx-utils",
3
- "version": "17.2.1",
3
+ "version": "17.3.0",
4
4
  "license": "MIT",
5
5
  "public": true,
6
6
  "repository": "https://github.com/stemyke/ngx-utils.git",
@@ -22,6 +22,7 @@
22
22
  "moment": "^2.27.0",
23
23
  "invokable": "^1.0.3",
24
24
  "ngx-device-detector": "^5.0.1",
25
+ "@floating-ui/dom": "^1.6.13",
25
26
  "json5": "^2.2.3"
26
27
  },
27
28
  "main": "dist/bundles/stemy-ngx-utils.umd.js",
package/public_api.d.ts CHANGED
@@ -14,6 +14,7 @@ export { JSONfn } from "./ngx-utils/utils/jsonfn";
14
14
  export { ReflectUtils } from "./ngx-utils/utils/reflect.utils";
15
15
  export { LoaderUtils } from "./ngx-utils/utils/loader.utils";
16
16
  export { MathUtils } from "./ngx-utils/utils/math.utils";
17
+ export { getCssVariables } from "./ngx-utils/utils/misc";
17
18
  export { ObjectUtils } from "./ngx-utils/utils/object.utils";
18
19
  export { ObservableUtils, ISubscriberInfo } from "./ngx-utils/utils/observable.utils";
19
20
  export { CancelablePromise, cancelablePromise, impatientPromise } from "./ngx-utils/utils/promise.utils";
@@ -58,6 +59,7 @@ export { GetTypePipe } from "./ngx-utils/pipes/get-type.pipe";
58
59
  export { GetValuePipe } from "./ngx-utils/pipes/get-value.pipe";
59
60
  export { GlobalTemplatePipe } from "./ngx-utils/pipes/global-template.pipe";
60
61
  export { GroupByPipe } from "./ngx-utils/pipes/group-by.pipe";
62
+ export { IncludesPipe } from "./ngx-utils/pipes/includes.pipe";
61
63
  export { IsTypePipe } from "./ngx-utils/pipes/is-type.pipe";
62
64
  export { JoinPipe } from "./ngx-utils/pipes/join.pipe";
63
65
  export { KeysPipe } from "./ngx-utils/pipes/keys.pipe";
@@ -78,6 +80,9 @@ export { ValuesPipe } from "./ngx-utils/pipes/values.pipe";
78
80
  export { AsyncMethodBase } from "./ngx-utils/directives/async-method.base";
79
81
  export { AsyncMethodDirective } from "./ngx-utils/directives/async-method.directive";
80
82
  export { BackgroundDirective } from "./ngx-utils/directives/background.directive";
83
+ export { DropdownDirective } from "./ngx-utils/directives/dropdown.directive";
84
+ export { DropdownContentDirective } from "./ngx-utils/directives/dropdown-content.directive";
85
+ export { DropdownToggleDirective } from "./ngx-utils/directives/dropdown-toggle.directive";
81
86
  export { DynamicTableTemplateDirective } from "./ngx-utils/directives/dynamic-table-template.directive";
82
87
  export { GlobalTemplateDirective } from "./ngx-utils/directives/global-template.directive";
83
88
  export { IconDirective } from "./ngx-utils/directives/icon.directive";
@@ -90,6 +95,7 @@ export { StickyClassDirective } from "./ngx-utils/directives/sticky-class.direct
90
95
  export { UnorderedListItemDirective } from "./ngx-utils/directives/unordered-list-item.directive";
91
96
  export { UnorderedListTemplateDirective } from "./ngx-utils/directives/unordered-list-template.directive";
92
97
  export { UnorderedListComponent } from "./ngx-utils/components/unordered-list/unordered-list.component";
98
+ export { DropdownBoxComponent } from "./ngx-utils/components/dropdown-box/dropdown-box.component";
93
99
  export { DynamicTableComponent } from "./ngx-utils/components/dynamic-table/dynamic-table.component";
94
100
  export { PaginationMenuComponent } from "./ngx-utils/components/pagination-menu/pagination-menu.component";
95
101
  export { NgxUtilsModule } from "./ngx-utils/ngx-utils.module";