@mediusinc/mng-commons 4.0.0-rc.1 → 4.0.0-rc.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2022/index.mjs +12 -2
- package/esm2022/lib/api/utils/medius-rest.util.mjs +15 -7
- package/esm2022/lib/api/utils/object-serializer.util.mjs +8 -4
- package/esm2022/lib/components/action/action.component.mjs +16 -45
- package/esm2022/lib/components/action/editor/action-editor.component.mjs +60 -434
- package/esm2022/lib/components/action/editor/injector-context/action-editor-injector-context.component.mjs +394 -0
- package/esm2022/lib/components/action/index.mjs +2 -1
- package/esm2022/lib/components/action/localization/data-language-dropdown.component.mjs +6 -7
- package/esm2022/lib/components/action/models/action-component.model.mjs +1 -1
- package/esm2022/lib/components/action/models/action-execution.model.mjs +3 -6
- package/esm2022/lib/components/action/models/index.mjs +1 -2
- package/esm2022/lib/components/action/route/action-route.component.mjs +14 -30
- package/esm2022/lib/components/action/table/action-table.component.mjs +154 -0
- package/esm2022/lib/components/form/editor/form-editor.component.mjs +5 -11
- package/esm2022/lib/components/form/formly/fields/formly-field-custom/formly-field-custom.component.mjs +1 -1
- package/esm2022/lib/components/form/formly/fields/formly-field-lookup-dialog/formly-field-lookup-dialog.component.mjs +5 -5
- package/esm2022/lib/components/form/formly/fields/formly-field-table-dialog-form/formly-field-table-dialog-form.component.mjs +6 -7
- package/esm2022/lib/components/form/formly/fields/formly-field-table-dialog-multiselect/formly-field-table-dialog-multiselect.component.mjs +5 -5
- package/esm2022/lib/components/form/formly/wrappers/formly-field-wrapper/formly-field-wrapper.component.mjs +1 -1
- package/esm2022/lib/components/layout/main-layout.component.mjs +21 -25
- package/esm2022/lib/components/layout/topbar.component.mjs +8 -8
- package/esm2022/lib/components/layoutV2/main-layout.component.mjs +13 -10
- package/esm2022/lib/components/layoutV2/menu-item.component.mjs +48 -5
- package/esm2022/lib/components/layoutV2/menu.component.mjs +13 -4
- package/esm2022/lib/components/layoutV2/services/main-layout.component.service.mjs +11 -2
- package/esm2022/lib/components/layoutV2/sidebar.component.mjs +5 -5
- package/esm2022/lib/components/layoutV2/topbar.component.mjs +7 -12
- package/esm2022/lib/components/notification/notification-wrapper.component.mjs +50 -0
- package/esm2022/lib/components/table/column-filter-full/column-filter-full.component.mjs +466 -0
- package/esm2022/lib/components/table/column-value/column-value.component.mjs +87 -0
- package/esm2022/lib/components/table/models/table.event.mjs +16 -0
- package/esm2022/lib/components/table/models/table.interface.mjs +2 -0
- package/esm2022/lib/components/table/table-column-filter-class/table-column-filter-class.pipe.mjs +25 -0
- package/esm2022/lib/components/table/table.component.mjs +717 -0
- package/esm2022/lib/components/tableview/index.mjs +1 -4
- package/esm2022/lib/components/tableview/route/tableview-route.abstract.component.mjs +5 -5
- package/esm2022/lib/components/tableview/route/tableview-route.component.mjs +3 -9
- package/esm2022/lib/components/tableview/tableview.component.mjs +18 -78
- package/esm2022/lib/descriptors/editor/editor.descriptor.mjs +1 -1
- package/esm2022/lib/descriptors/editor/field-lookup.descriptor.mjs +1 -2
- package/esm2022/lib/descriptors/filter/filter.descriptor.mjs +20 -20
- package/esm2022/lib/descriptors/table/table.descriptor.mjs +16 -17
- package/esm2022/lib/descriptors/tableview/tableview.descriptor.mjs +1 -1
- package/esm2022/lib/directives/component.directive.mjs +8 -4
- package/esm2022/lib/helpers/coercion.mjs +8 -1
- package/esm2022/lib/models/action-editor.model.mjs +1 -1
- package/esm2022/lib/models/config.model.mjs +1 -1
- package/esm2022/lib/models/index.mjs +2 -2
- package/esm2022/lib/models/layout-config.model.mjs +2 -0
- package/esm2022/lib/models/view-container.model.mjs +1 -1
- package/esm2022/lib/provide-commons.mjs +7 -1
- package/esm2022/lib/registry/type.registry.mjs +2 -3
- package/esm2022/lib/router/route-builder.mjs +1 -1
- package/esm2022/lib/services/action/action-executor.service.mjs +725 -0
- package/esm2022/lib/services/action/component-action-executor.service.mjs +19 -0
- package/esm2022/lib/services/action/index.mjs +5 -0
- package/esm2022/lib/services/action/provide-action-executor.mjs +9 -0
- package/esm2022/lib/services/action/root-action-executor.service.mjs +18 -0
- package/esm2022/lib/services/commons.service.mjs +5 -5
- package/esm2022/lib/services/index.mjs +1 -3
- package/esm2022/lib/services/logger.service.mjs +2 -2
- package/esm2022/lib/services/view/index.mjs +3 -0
- package/esm2022/lib/services/view/provide-view-container.mjs +17 -0
- package/esm2022/lib/services/view/view-container.service.mjs +59 -0
- package/esm2022/lib/utils/date.util.mjs +33 -23
- package/esm2022/lib/utils/notification.util.mjs +9 -16
- package/esm2022/lib/utils/string.util.mjs +2 -2
- package/esm2022/lib/utils/tableview.util.mjs +2 -2
- package/fesm2022/mediusinc-mng-commons.mjs +4305 -4121
- package/fesm2022/mediusinc-mng-commons.mjs.map +1 -1
- package/index.d.ts +10 -1
- package/lib/components/action/action.component.d.ts +11 -17
- package/lib/components/action/editor/action-editor.component.d.ts +20 -80
- package/lib/components/action/editor/injector-context/action-editor-injector-context.component.d.ts +80 -0
- package/lib/components/action/index.d.ts +1 -0
- package/lib/components/action/localization/data-language-dropdown.component.d.ts +2 -3
- package/lib/components/action/models/action-component.model.d.ts +0 -2
- package/lib/components/action/models/action-execution.model.d.ts +6 -6
- package/lib/components/action/models/index.d.ts +0 -1
- package/lib/components/action/route/action-route.component.d.ts +6 -12
- package/lib/components/action/table/action-table.component.d.ts +50 -0
- package/lib/components/form/editor/form-editor.component.d.ts +4 -7
- package/lib/components/form/formly/fields/formly-field-lookup-dialog/formly-field-lookup-dialog.component.d.ts +2 -4
- package/lib/components/form/formly/fields/formly-field-table-dialog-form/formly-field-table-dialog-form.component.d.ts +0 -2
- package/lib/components/form/formly/fields/formly-field-table-dialog-multiselect/formly-field-table-dialog-multiselect.component.d.ts +1 -3
- package/lib/components/layout/main-layout.component.d.ts +4 -7
- package/lib/components/layoutV2/main-layout.component.d.ts +4 -3
- package/lib/components/layoutV2/menu-item.component.d.ts +7 -3
- package/lib/components/layoutV2/menu.component.d.ts +2 -0
- package/lib/components/layoutV2/services/main-layout.component.service.d.ts +3 -0
- package/lib/components/layoutV2/sidebar.component.d.ts +1 -1
- package/lib/components/layoutV2/topbar.component.d.ts +2 -3
- package/lib/components/notification/notification-wrapper.component.d.ts +12 -0
- package/lib/components/{tableview/table → table}/column-filter-full/column-filter-full.component.d.ts +2 -2
- package/lib/components/{tableview/table → table}/column-value/column-value.component.d.ts +3 -3
- package/lib/components/{tableview/table → table}/models/table.interface.d.ts +3 -1
- package/lib/components/table/table-column-filter-class/table-column-filter-class.pipe.d.ts +8 -0
- package/lib/components/table/table.component.d.ts +122 -0
- package/lib/components/tableview/index.d.ts +0 -3
- package/lib/components/tableview/route/tableview-route.abstract.component.d.ts +2 -3
- package/lib/components/tableview/route/tableview-route.component.d.ts +0 -3
- package/lib/components/tableview/tableview.component.d.ts +4 -20
- package/lib/descriptors/editor/editor.descriptor.d.ts +1 -1
- package/lib/descriptors/filter/filter.descriptor.d.ts +7 -7
- package/lib/descriptors/table/table.descriptor.d.ts +15 -12
- package/lib/descriptors/tableview/tableview.descriptor.d.ts +1 -1
- package/lib/directives/component.directive.d.ts +3 -2
- package/lib/models/action-editor.model.d.ts +11 -0
- package/lib/models/config.model.d.ts +3 -13
- package/lib/models/index.d.ts +1 -1
- package/lib/models/layout-config.model.d.ts +33 -0
- package/lib/models/view-container.model.d.ts +0 -25
- package/lib/router/route-builder.d.ts +1 -1
- package/lib/services/{action-executor.service.d.ts → action/action-executor.service.d.ts} +32 -31
- package/lib/services/action/component-action-executor.service.d.ts +9 -0
- package/lib/services/action/index.d.ts +4 -0
- package/lib/services/action/provide-action-executor.d.ts +2 -0
- package/lib/services/action/root-action-executor.service.d.ts +9 -0
- package/lib/services/index.d.ts +0 -2
- package/lib/services/view/index.d.ts +2 -0
- package/lib/services/view/provide-view-container.d.ts +2 -0
- package/lib/services/view/view-container.service.d.ts +32 -0
- package/lib/utils/date.util.d.ts +12 -2
- package/lib/utils/notification.util.d.ts +6 -6
- package/openapi/angular/README.mustache +226 -0
- package/openapi/angular/api.module.mustache +39 -0
- package/openapi/angular/api.service.mustache +253 -0
- package/openapi/angular/apiInterface.mustache +47 -0
- package/openapi/angular/apis.mustache +12 -0
- package/openapi/angular/configuration.mustache +128 -0
- package/openapi/angular/custom/base-api.service.mustache +14 -0
- package/openapi/angular/custom/helpers.mustache +71 -0
- package/openapi/angular/custom/modelSchema.mustache +46 -0
- package/openapi/angular/custom/schema.mustache +18 -0
- package/openapi/angular/encoder.mustache +20 -0
- package/openapi/angular/git_push.sh.mustache +57 -0
- package/openapi/angular/index.mustache +0 -0
- package/openapi/angular/licenseInfo.mustache +11 -0
- package/openapi/angular/model.mustache +16 -0
- package/openapi/angular/modelAlias.mustache +1 -0
- package/openapi/angular/modelEnum.mustache +24 -0
- package/openapi/angular/modelGeneric.mustache +14 -0
- package/openapi/angular/modelGenericAdditionalProperties.mustache +5 -0
- package/openapi/angular/modelGenericEnums.mustache +30 -0
- package/openapi/angular/modelOneOf.mustache +14 -0
- package/openapi/angular/modelTaggedUnion.mustache +21 -0
- package/openapi/angular/models.mustache +5 -0
- package/openapi/angular/ng-package.mustache +6 -0
- package/openapi/angular/package.mustache +39 -0
- package/openapi/angular/param.mustache +69 -0
- package/openapi/angular/tsconfig.mustache +28 -0
- package/openapi/angular/variables.mustache +9 -0
- package/openapi/{templates → node}/model.mustache +3 -17
- package/package.json +2 -2
- package/scss/mng-commons-dark-v2.scss +1 -1
- package/scss/mng-commons-light-v2.scss +1 -1
- package/scss/mng-overrides/_theme_datatable.scss +24 -10
- package/scss/v2/layout/layout.scss +2 -2
- package/scss/v2/layout/mng/_mng_layout_topbar.scss +2 -0
- package/scss/v2/layout/preloading.scss +8 -8
- package/scss/v2/theme/theme-base/mng/_mng_theme_datatable.scss +24 -9
- package/scss/v2/theme/theme-dark/_variables.scss +24 -12
- package/scss/v2/theme/theme-dark/blue/theme.scss +4 -4
- package/scss/v2/theme/theme-light/_variables.scss +23 -11
- package/scss/v2/theme/theme-light/blue/theme.scss +2 -2
- package/esm2022/lib/components/action/models/action-confirmation-service.model.mjs +0 -2
- package/esm2022/lib/components/tableview/models/index.mjs +0 -2
- package/esm2022/lib/components/tableview/models/table.event.mjs +0 -16
- package/esm2022/lib/components/tableview/table/column-filter-full/column-filter-full.component.mjs +0 -467
- package/esm2022/lib/components/tableview/table/column-value/column-value.component.mjs +0 -87
- package/esm2022/lib/components/tableview/table/models/index.mjs +0 -2
- package/esm2022/lib/components/tableview/table/models/table.interface.mjs +0 -2
- package/esm2022/lib/components/tableview/table/table.component.mjs +0 -752
- package/esm2022/lib/models/menu-config.model.mjs +0 -2
- package/esm2022/lib/services/action-executor.service.mjs +0 -747
- package/esm2022/lib/services/view-container.component.service.mjs +0 -65
- package/lib/components/action/models/action-confirmation-service.model.d.ts +0 -6
- package/lib/components/tableview/models/index.d.ts +0 -1
- package/lib/components/tableview/table/models/index.d.ts +0 -1
- package/lib/components/tableview/table/table.component.d.ts +0 -147
- package/lib/models/menu-config.model.d.ts +0 -15
- package/lib/services/view-container.component.service.d.ts +0 -36
- /package/lib/components/{tableview → table}/models/table.event.d.ts +0 -0
- /package/openapi/{templates → node}/models.mustache +0 -0
|
@@ -1,20 +1,17 @@
|
|
|
1
1
|
import { OnInit, QueryList, Type } from '@angular/core';
|
|
2
|
-
import { ActivatedRoute } from '@angular/router';
|
|
3
2
|
import { MngTemplateDirective } from '../../directives';
|
|
4
|
-
import { MngModuleConfig } from '../../models';
|
|
5
3
|
import { MngCommonsService } from '../../services';
|
|
6
4
|
import { MngMainLayoutComponentService } from './services';
|
|
7
5
|
import * as i0 from "@angular/core";
|
|
8
6
|
export declare class MngMainLayoutComponent implements OnInit {
|
|
9
|
-
private route;
|
|
10
|
-
mngCommons: MngCommonsService;
|
|
11
|
-
mainLayoutService: MngMainLayoutComponentService;
|
|
12
|
-
private config;
|
|
13
7
|
templates: QueryList<MngTemplateDirective>;
|
|
8
|
+
readonly mngCommons: MngCommonsService;
|
|
9
|
+
readonly mainLayoutService: MngMainLayoutComponentService;
|
|
10
|
+
readonly config: import("@mediusinc/mng-commons").MngModuleConfig;
|
|
11
|
+
useNotificationWrapper: boolean;
|
|
14
12
|
topbarComponent: Type<any>;
|
|
15
13
|
menuComponent: Type<any>;
|
|
16
14
|
footerComponent: Type<any>;
|
|
17
|
-
constructor(route: ActivatedRoute, mngCommons: MngCommonsService, mainLayoutService: MngMainLayoutComponentService, config: MngModuleConfig);
|
|
18
15
|
ngOnInit(): void;
|
|
19
16
|
onWindowResize(event: UIEvent): void;
|
|
20
17
|
static ɵfac: i0.ɵɵFactoryDeclaration<MngMainLayoutComponent, never>;
|
|
@@ -9,9 +9,10 @@ export declare class MngMainLayoutV2Component implements OnInit, OnDestroy {
|
|
|
9
9
|
private readonly renderer;
|
|
10
10
|
appTopbar?: ElementRef;
|
|
11
11
|
private menuOutsideClickListener;
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
12
|
+
useNotificationWrapper: boolean;
|
|
13
|
+
topbarComponent: Type<any> | false;
|
|
14
|
+
breadcrumbsComponent: Type<any> | false;
|
|
15
|
+
footerComponent: Type<any> | false;
|
|
15
16
|
constructor();
|
|
16
17
|
ngOnInit(): void;
|
|
17
18
|
blockBodyScroll(): void;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AnimationEvent } from '@angular/animations';
|
|
2
|
+
import { AfterViewChecked, ElementRef, EventEmitter, OnDestroy, OnInit } from '@angular/core';
|
|
2
3
|
import { MngMenuItem } from '../../models';
|
|
3
4
|
import * as i0 from "@angular/core";
|
|
4
|
-
export declare class MngMenuItemV2Component implements OnInit, OnDestroy {
|
|
5
|
+
export declare class MngMenuItemV2Component implements OnInit, OnDestroy, AfterViewChecked {
|
|
5
6
|
private readonly router;
|
|
6
7
|
private readonly injector;
|
|
7
8
|
private readonly destroyRef;
|
|
@@ -25,11 +26,14 @@ export declare class MngMenuItemV2Component implements OnInit, OnDestroy {
|
|
|
25
26
|
visible: import("@angular/core").WritableSignal<boolean>;
|
|
26
27
|
constructor();
|
|
27
28
|
ngOnInit(): void;
|
|
29
|
+
ngAfterViewChecked(): void;
|
|
28
30
|
ngOnDestroy(): void;
|
|
29
|
-
get submenuAnimation(): "collapsed" | "expanded";
|
|
31
|
+
get submenuAnimation(): "hidden" | "visible" | "collapsed" | "expanded";
|
|
30
32
|
get activeClass(): boolean;
|
|
31
33
|
itemClick(event: Event): void;
|
|
34
|
+
onSubmenuAnimated(event: AnimationEvent): void;
|
|
32
35
|
onChildVisibleChange(visible: boolean, item: MngMenuItem, idx: number): void;
|
|
36
|
+
private calculatePosition;
|
|
33
37
|
private checkIfMenuItemIsAllowedFromGuard;
|
|
34
38
|
private updateActiveStateFromRoute;
|
|
35
39
|
private processItemChildrenVisibility;
|
|
@@ -5,8 +5,10 @@ export declare class MngMenuV2Component implements OnInit {
|
|
|
5
5
|
private readonly route;
|
|
6
6
|
private readonly menuService;
|
|
7
7
|
private readonly mngCommons;
|
|
8
|
+
private readonly layoutService;
|
|
8
9
|
menuItems: Array<MngMenuItem>;
|
|
9
10
|
ngOnInit(): void;
|
|
11
|
+
private wrapMenuItems;
|
|
10
12
|
static ɵfac: i0.ɵɵFactoryDeclaration<MngMenuV2Component, never>;
|
|
11
13
|
static ɵcmp: i0.ɵɵComponentDeclaration<MngMenuV2Component, "mng-menu-v2", never, {}, {}, never, never, true, never>;
|
|
12
14
|
}
|
|
@@ -6,7 +6,10 @@ export declare class MngMainLayoutComponentV2Service {
|
|
|
6
6
|
private overlayOpen;
|
|
7
7
|
overlayOpen$: import("rxjs").Observable<any>;
|
|
8
8
|
onMenuToggle(): void;
|
|
9
|
+
onOverlaySubmenuOpen(): void;
|
|
9
10
|
isOverlay(): boolean;
|
|
11
|
+
isSlim(): boolean;
|
|
12
|
+
isSlimPlus(): boolean;
|
|
10
13
|
isDesktop(): boolean;
|
|
11
14
|
isMobile(): boolean;
|
|
12
15
|
static ɵfac: i0.ɵɵFactoryDeclaration<MngMainLayoutComponentV2Service, never>;
|
|
@@ -9,7 +9,7 @@ export declare class MngSidebarV2Component implements OnInit {
|
|
|
9
9
|
el: ElementRef<any>;
|
|
10
10
|
timeout: any;
|
|
11
11
|
menuContainer: ElementRef;
|
|
12
|
-
menuComponent: Type<any
|
|
12
|
+
menuComponent: Type<any> | false;
|
|
13
13
|
ngOnInit(): void;
|
|
14
14
|
onMouseEnter(): void;
|
|
15
15
|
onMouseLeave(): void;
|
|
@@ -9,10 +9,9 @@ export declare class MngTopbarV2Component implements OnInit {
|
|
|
9
9
|
mainLayoutService: MngMainLayoutComponentV2Service;
|
|
10
10
|
private config;
|
|
11
11
|
menuButton: ElementRef;
|
|
12
|
-
topbarInjectionRef: ElementRef;
|
|
13
12
|
appSidebar: MngSidebarV2Component;
|
|
14
|
-
breadcrumbComponent: Type<any
|
|
15
|
-
topbarUserComponent: Type<any
|
|
13
|
+
breadcrumbComponent: Type<any> | false;
|
|
14
|
+
topbarUserComponent: Type<any> | false;
|
|
16
15
|
languages: Array<string>;
|
|
17
16
|
selectedLanguage: string;
|
|
18
17
|
ngOnInit(): void;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Message } from 'primeng/api';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export declare class NotificationWrapperComponent {
|
|
4
|
+
readonly notificationCutoff = 70;
|
|
5
|
+
isDialogNotificationVisible: import("@angular/core").Signal<boolean>;
|
|
6
|
+
dialogNotification: import("@angular/core").WritableSignal<Message | null>;
|
|
7
|
+
getNotificationIconClass(message: Message | null): string;
|
|
8
|
+
onShowNotificationInDialog(message: Message): void;
|
|
9
|
+
onDialogNotificationVisibilityChange(visible: boolean): void;
|
|
10
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NotificationWrapperComponent, never>;
|
|
11
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NotificationWrapperComponent, "mng-notification-wrapper", never, {}, {}, never, ["*"], true, never>;
|
|
12
|
+
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { ElementRef, OnDestroy, OnInit, WritableSignal } from '@angular/core';
|
|
2
2
|
import { FilterMetadata, SelectItem } from 'primeng/api';
|
|
3
3
|
import { Nullable } from 'primeng/ts-helpers';
|
|
4
|
-
import { FilterDescriptor, FilterLookupDescriptor } from '
|
|
5
|
-
import { FilterLookupTypeEnum, FilterMatchModeEnum } from '
|
|
4
|
+
import { FilterDescriptor, FilterLookupDescriptor } from '../../../descriptors/filter';
|
|
5
|
+
import { FilterLookupTypeEnum, FilterMatchModeEnum } from '../../../descriptors/types';
|
|
6
6
|
import * as i0 from "@angular/core";
|
|
7
7
|
/**
|
|
8
8
|
* Cannot be on push change detection strategy because of filter updates triggered from route which causes to force update values in force metadata
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { ElementRef, OnInit } from '@angular/core';
|
|
2
2
|
import { TranslateService } from '@ngx-translate/core';
|
|
3
3
|
import { MessageService } from 'primeng/api';
|
|
4
|
-
import { ColumnDescriptor } from '
|
|
5
|
-
import { ColumnDisplayTypeEnum } from '
|
|
6
|
-
import { JsonPathPipe, MngGetterPipe, MngTemplatePipe } from '
|
|
4
|
+
import { ColumnDescriptor } from '../../../descriptors/table';
|
|
5
|
+
import { ColumnDisplayTypeEnum } from '../../../descriptors/types';
|
|
6
|
+
import { JsonPathPipe, MngGetterPipe, MngTemplatePipe } from '../../../pipes';
|
|
7
7
|
import * as i0 from "@angular/core";
|
|
8
8
|
export declare class MngTableColumnValueComponent<T, TT> implements OnInit {
|
|
9
9
|
private elementRef;
|
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
import { ColumnDescriptor } from '
|
|
1
|
+
import { ColumnDescriptor } from '../../../descriptors/table';
|
|
2
2
|
export interface ColumnWithPreferences {
|
|
3
|
+
id: string;
|
|
3
4
|
descriptor: ColumnDescriptor<any, any>;
|
|
4
5
|
disabled: boolean;
|
|
5
6
|
isVisible: boolean;
|
|
6
7
|
width?: number;
|
|
8
|
+
orderIdx?: number;
|
|
7
9
|
}
|
|
8
10
|
export interface TableLayoutPreferences {
|
|
9
11
|
columnWidths?: Record<string, number>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { PipeTransform } from '@angular/core';
|
|
2
|
+
import { ColumnDescriptor } from '../../../descriptors/table/column.descriptor';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
export declare class MngTableColumnFilterClassPipe implements PipeTransform {
|
|
5
|
+
transform(value: unknown, column: ColumnDescriptor<any, any>, isEnabled: boolean): string;
|
|
6
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<MngTableColumnFilterClassPipe, never>;
|
|
7
|
+
static ɵpipe: i0.ɵɵPipeDeclaration<MngTableColumnFilterClassPipe, "mngTableColumnFilterClass", true>;
|
|
8
|
+
}
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
import { AfterContentInit, EventEmitter, OnChanges, OnDestroy, OnInit, QueryList, SimpleChanges, TemplateRef, Type, WritableSignal } from '@angular/core';
|
|
2
|
+
import { FilterMetadata, SortMeta } from 'primeng/api';
|
|
3
|
+
import { MultiSelectChangeEvent } from 'primeng/multiselect';
|
|
4
|
+
import { Table, TableLazyLoadEvent } from 'primeng/table';
|
|
5
|
+
import { TableColumnReorderEvent } from 'primeng/table/table.interface';
|
|
6
|
+
import { Observable } from 'rxjs';
|
|
7
|
+
import { MediusQueryResult } from '../../api/models';
|
|
8
|
+
import { ITableDataProvider } from '../../data-providers';
|
|
9
|
+
import { ColumnDescriptor, TableDescriptorInst } from '../../descriptors/table';
|
|
10
|
+
import { MngComponentDirective, MngTemplateDirective } from '../../directives';
|
|
11
|
+
import { MngTableCellClickEvent, MngTableLoadEvent } from './models/table.event';
|
|
12
|
+
import { ColumnWithPreferences } from './models/table.interface';
|
|
13
|
+
import * as i0 from "@angular/core";
|
|
14
|
+
export declare class MngTableComponent<T = any, S = any> implements OnInit, OnChanges, AfterContentInit, OnDestroy {
|
|
15
|
+
readonly cmpTypeName = "MngTableComponent";
|
|
16
|
+
private readonly logger;
|
|
17
|
+
private readonly injector;
|
|
18
|
+
private readonly router;
|
|
19
|
+
private readonly route;
|
|
20
|
+
private readonly translate;
|
|
21
|
+
private readonly mngCommonsService;
|
|
22
|
+
private readonly localStorageService;
|
|
23
|
+
private readonly destroyRef;
|
|
24
|
+
private readonly viewContainer;
|
|
25
|
+
private readonly messageService;
|
|
26
|
+
descriptorInput: TableDescriptorInst<T>;
|
|
27
|
+
items?: Observable<Array<T>>;
|
|
28
|
+
queryResult?: Observable<MediusQueryResult<T> | undefined>;
|
|
29
|
+
loadingInput?: Observable<boolean>;
|
|
30
|
+
dataProvider?: ITableDataProvider;
|
|
31
|
+
useQueryParams: boolean;
|
|
32
|
+
selectionMode: 'single' | 'multiple';
|
|
33
|
+
selectionEnabled: boolean;
|
|
34
|
+
columnLastMinWidth?: number;
|
|
35
|
+
captionComponent?: Type<any>;
|
|
36
|
+
columnCustomLastComponent?: Type<any>;
|
|
37
|
+
globalFilterFieldsInput?: string[];
|
|
38
|
+
loadEventEmitter: EventEmitter<MngTableLoadEvent>;
|
|
39
|
+
cellClickEventEmitter: EventEmitter<MngTableCellClickEvent<T>>;
|
|
40
|
+
selectionChangeEventEmitter: EventEmitter<T[]>;
|
|
41
|
+
captionCmpInstEventEmitter: EventEmitter<any>;
|
|
42
|
+
columnCustomLastCmpInstEventEmitter: EventEmitter<any>;
|
|
43
|
+
templates: QueryList<MngTemplateDirective>;
|
|
44
|
+
components: QueryList<MngComponentDirective<any>>;
|
|
45
|
+
primeTable: Table;
|
|
46
|
+
captionTemplate: WritableSignal<TemplateRef<any> | undefined>;
|
|
47
|
+
columnCustomLastTemplate: WritableSignal<TemplateRef<any> | undefined>;
|
|
48
|
+
footerTemplate: WritableSignal<TemplateRef<any> | undefined>;
|
|
49
|
+
private useDataProvider;
|
|
50
|
+
isLazy: WritableSignal<boolean>;
|
|
51
|
+
isPagination: WritableSignal<boolean>;
|
|
52
|
+
useQueryParamsInitialized: WritableSignal<boolean>;
|
|
53
|
+
data: WritableSignal<T[]>;
|
|
54
|
+
count: WritableSignal<number>;
|
|
55
|
+
loading: WritableSignal<boolean>;
|
|
56
|
+
rowsPerPageOptions: WritableSignal<number[]>;
|
|
57
|
+
rows: WritableSignal<number>;
|
|
58
|
+
offset: WritableSignal<number>;
|
|
59
|
+
sortMeta: WritableSignal<SortMeta[] | null>;
|
|
60
|
+
filterMeta: WritableSignal<Record<string, FilterMetadata>>;
|
|
61
|
+
globalFilterFields: WritableSignal<string[]>;
|
|
62
|
+
infiniteScroll: WritableSignal<boolean>;
|
|
63
|
+
className: WritableSignal<string>;
|
|
64
|
+
tableFullHeightOffset: WritableSignal<number | undefined>;
|
|
65
|
+
rowHeight: WritableSignal<number | undefined>;
|
|
66
|
+
private dataProviderService;
|
|
67
|
+
private dataProviderLatestLazyLoadEvent?;
|
|
68
|
+
private dataProviderLatestLazyLoadEventVersion;
|
|
69
|
+
private dataProviderLatestQueryParam?;
|
|
70
|
+
private dataProviderLatestQueryParamVersion;
|
|
71
|
+
private dataProviderSubscription?;
|
|
72
|
+
descriptor: WritableSignal<TableDescriptorInst<any>>;
|
|
73
|
+
columns: WritableSignal<ColumnWithPreferences[]>;
|
|
74
|
+
visibleColumns: import("@angular/core").Signal<ColumnWithPreferences[]>;
|
|
75
|
+
hasColumnFilters: import("@angular/core").Signal<boolean>;
|
|
76
|
+
private filterDescriptors;
|
|
77
|
+
private isFilterChanged;
|
|
78
|
+
private isSortChanged;
|
|
79
|
+
anyColumnVisible: import("@angular/core").Signal<boolean>;
|
|
80
|
+
hasCustomLastColumn: WritableSignal<boolean>;
|
|
81
|
+
hasLastColumn: import("@angular/core").Signal<boolean>;
|
|
82
|
+
areColumnsReorderable: import("@angular/core").Signal<boolean>;
|
|
83
|
+
areColumnsToggleable: import("@angular/core").Signal<boolean>;
|
|
84
|
+
private layoutPreferences;
|
|
85
|
+
private localstorageKey;
|
|
86
|
+
private routerIsNavigationOutsideInProgress;
|
|
87
|
+
ngOnInit(): void;
|
|
88
|
+
ngAfterContentInit(): void;
|
|
89
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
90
|
+
ngOnDestroy(): void;
|
|
91
|
+
reload(emitEvent?: boolean, resetParams?: boolean): void;
|
|
92
|
+
onTableLazyLoad(event: TableLazyLoadEvent): void;
|
|
93
|
+
onTableSort(event: any): void;
|
|
94
|
+
onTableFilter(event: any): void;
|
|
95
|
+
onCellClick(event: Event, col: ColumnDescriptor<any, T>, item: T, idx: number): void;
|
|
96
|
+
onSelectionChange(event: Array<T>): void;
|
|
97
|
+
/**
|
|
98
|
+
* Method is called on column resize
|
|
99
|
+
* @param element event's element
|
|
100
|
+
*/
|
|
101
|
+
onTableColumnResize({ element }: any): void;
|
|
102
|
+
private loadTableWithDataProvider;
|
|
103
|
+
private loadTableFromRouteUpdate;
|
|
104
|
+
private setMainAndRelatedDescriptors;
|
|
105
|
+
private updatePrimeSortAndFilter;
|
|
106
|
+
private createFilterMeta;
|
|
107
|
+
private createSortMeta;
|
|
108
|
+
private initializeDataLoadingTriggers;
|
|
109
|
+
onColumnToggle(event: MultiSelectChangeEvent): void;
|
|
110
|
+
onColumnToggleAll(): void;
|
|
111
|
+
onColumnReorder(event: TableColumnReorderEvent): void;
|
|
112
|
+
private saveLayoutPreferences;
|
|
113
|
+
/**
|
|
114
|
+
* Reset column order and column visibility to default settings
|
|
115
|
+
*/
|
|
116
|
+
resetDefaultLayout(): void;
|
|
117
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<MngTableComponent<any, any>, never>;
|
|
118
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<MngTableComponent<any, any>, "mng-table", never, { "descriptorInput": { "alias": "descriptor"; "required": true; }; "items": { "alias": "items"; "required": false; }; "queryResult": { "alias": "queryResult"; "required": false; }; "loadingInput": { "alias": "loading"; "required": false; }; "dataProvider": { "alias": "dataProvider"; "required": false; }; "useQueryParams": { "alias": "useQueryParams"; "required": false; }; "selectionMode": { "alias": "selectionMode"; "required": false; }; "selectionEnabled": { "alias": "selectionEnabled"; "required": false; }; "columnLastMinWidth": { "alias": "columnLastMinWidth"; "required": false; }; "captionComponent": { "alias": "captionComponent"; "required": false; }; "columnCustomLastComponent": { "alias": "columnCustomLastComponent"; "required": false; }; "globalFilterFieldsInput": { "alias": "globalFilterFields"; "required": false; }; }, { "loadEventEmitter": "tableLoad"; "cellClickEventEmitter": "cellClick"; "selectionChangeEventEmitter": "selectionChange"; "captionCmpInstEventEmitter": "captionComponentInstance"; "columnCustomLastCmpInstEventEmitter": "columnCustomLastComponentInstance"; }, ["templates"], never, true, never>;
|
|
119
|
+
static ngAcceptInputType_items: unknown;
|
|
120
|
+
static ngAcceptInputType_queryResult: unknown;
|
|
121
|
+
static ngAcceptInputType_loadingInput: unknown;
|
|
122
|
+
}
|
|
@@ -1,6 +1,3 @@
|
|
|
1
1
|
export * from './tableview.component';
|
|
2
2
|
export * from './route/tableview-route.abstract.component';
|
|
3
3
|
export * from './route/tableview-route.component';
|
|
4
|
-
export * from './table/table.component';
|
|
5
|
-
export * from './table/column-filter-full/column-filter-full.component';
|
|
6
|
-
export * from './table/column-value/column-value.component';
|
|
@@ -9,12 +9,11 @@ import { TableviewDescriptorInst } from '../../../descriptors/tableview';
|
|
|
9
9
|
import { MngRouterData } from '../../../router/models';
|
|
10
10
|
import * as i0 from "@angular/core";
|
|
11
11
|
export declare abstract class AMngTableviewRouteComponent<T = any, S = undefined> implements OnInit {
|
|
12
|
+
protected readonly route: ActivatedRoute;
|
|
13
|
+
protected readonly translateService: TranslateService;
|
|
12
14
|
descriptor: TableviewDescriptorInst<T>;
|
|
13
15
|
dataProvider: ITableviewDataProvider<T, S>;
|
|
14
16
|
actions: Array<ActionDescriptorInst<any>>;
|
|
15
|
-
protected route: ActivatedRoute;
|
|
16
|
-
protected translateService: TranslateService;
|
|
17
|
-
constructor();
|
|
18
17
|
protected get routeData(): MngRouterData;
|
|
19
18
|
ngOnInit(): void;
|
|
20
19
|
protected abstract createTableviewDescriptor(): TableviewDescriptorInst<T>;
|
|
@@ -2,18 +2,15 @@ import { OnInit } from '@angular/core';
|
|
|
2
2
|
import { ITableviewDataProvider } from '../../../data-providers';
|
|
3
3
|
import { ActionDescriptorInst } from '../../../descriptors/action';
|
|
4
4
|
import { TableviewDescriptorInst } from '../../../descriptors/tableview';
|
|
5
|
-
import { MngTableviewComponent } from '../tableview.component';
|
|
6
5
|
import { AMngTableviewRouteComponent } from './tableview-route.abstract.component';
|
|
7
6
|
import * as i0 from "@angular/core";
|
|
8
7
|
export declare class MngTableviewRouteComponent<T, S = undefined> extends AMngTableviewRouteComponent<T, S> implements OnInit {
|
|
9
8
|
descriptorInit?: TableviewDescriptorInst<T>;
|
|
10
9
|
dataProviderInit?: ITableviewDataProvider<T, S>;
|
|
11
10
|
actionsInit?: Array<ActionDescriptorInst<T>>;
|
|
12
|
-
tableviewComponent?: MngTableviewComponent<T, S>;
|
|
13
11
|
protected createTableviewDescriptor(): TableviewDescriptorInst<T>;
|
|
14
12
|
protected createTableviewDataProvider(): ITableviewDataProvider<T, S>;
|
|
15
13
|
protected createActionDescriptors(): Array<ActionDescriptorInst<T>>;
|
|
16
|
-
reloadTable(): void;
|
|
17
14
|
static ɵfac: i0.ɵɵFactoryDeclaration<MngTableviewRouteComponent<any, any>, never>;
|
|
18
15
|
static ɵcmp: i0.ɵɵComponentDeclaration<MngTableviewRouteComponent<any, any>, "mng-tableview-route", never, { "descriptorInit": { "alias": "descriptor"; "required": false; }; "dataProviderInit": { "alias": "dataProvider"; "required": false; }; "actionsInit": { "alias": "actions"; "required": false; }; }, {}, never, never, true, never>;
|
|
19
16
|
}
|
|
@@ -1,22 +1,16 @@
|
|
|
1
1
|
import { AfterContentInit, OnDestroy, OnInit, QueryList, TemplateRef } from '@angular/core';
|
|
2
|
-
import { Message, MessageService } from 'primeng/api';
|
|
3
2
|
import { MediusQueryParam } from '../../api/models';
|
|
4
|
-
import {
|
|
3
|
+
import { ITableviewDataProvider } from '../../data-providers';
|
|
5
4
|
import { ActionDescriptorInst } from '../../descriptors/action';
|
|
6
5
|
import { TableviewDescriptorInst } from '../../descriptors/tableview';
|
|
7
6
|
import { MngTemplateDirective } from '../../directives';
|
|
8
|
-
import {
|
|
9
|
-
import { MngViewContainerComponentService } from '../../services';
|
|
10
|
-
import { MngTableLoadEvent } from './models';
|
|
11
|
-
import { MngTableComponent } from './table/table.component';
|
|
7
|
+
import { MngTableLoadEvent } from '../table/models/table.event';
|
|
12
8
|
import * as i0 from "@angular/core";
|
|
13
|
-
export declare class MngTableviewComponent<T, S> implements OnInit, OnDestroy, AfterContentInit
|
|
14
|
-
private
|
|
15
|
-
private viewContainerService;
|
|
9
|
+
export declare class MngTableviewComponent<T, S> implements OnInit, OnDestroy, AfterContentInit {
|
|
10
|
+
private readonly viewContainer;
|
|
16
11
|
descriptor: TableviewDescriptorInst<T>;
|
|
17
12
|
dataProvider?: ITableviewDataProvider<T, S>;
|
|
18
13
|
actions: Array<ActionDescriptorInst<any>>;
|
|
19
|
-
tableComponent?: MngTableComponent<T, S>;
|
|
20
14
|
tableActions: ActionDescriptorInst<T>[];
|
|
21
15
|
toolbarLeftActions: ActionDescriptorInst<T>[];
|
|
22
16
|
toolbarRightActions: ActionDescriptorInst<T>[];
|
|
@@ -26,21 +20,11 @@ export declare class MngTableviewComponent<T, S> implements OnInit, OnDestroy, A
|
|
|
26
20
|
selectedItems: T[];
|
|
27
21
|
templates: QueryList<MngTemplateDirective>;
|
|
28
22
|
footerTemplate?: TemplateRef<any>;
|
|
29
|
-
isDialogNotificationVisible: boolean;
|
|
30
|
-
dialogNotification: Message | null;
|
|
31
|
-
readonly notificationCutoff = 70;
|
|
32
|
-
constructor(messageService: MessageService, viewContainerService: MngViewContainerComponentService<T, S>);
|
|
33
23
|
ngOnInit(): void;
|
|
34
24
|
ngAfterContentInit(): void;
|
|
35
25
|
ngOnDestroy(): void;
|
|
36
|
-
getMessageService(): MessageService;
|
|
37
|
-
getDataProvider(): IDataProvider<T, S> | undefined;
|
|
38
|
-
getActions(): ActionDescriptorInst<any, any>[];
|
|
39
|
-
reloadTable(): void;
|
|
40
26
|
onTableLoad(event: MngTableLoadEvent): void;
|
|
41
27
|
selectionChange(selectedItems: Array<T>): void;
|
|
42
|
-
onShowNotificationInDialog(message: Message): void;
|
|
43
|
-
getNotificationIconClass(message: Message | null): string;
|
|
44
28
|
static ɵfac: i0.ɵɵFactoryDeclaration<MngTableviewComponent<any, any>, never>;
|
|
45
29
|
static ɵcmp: i0.ɵɵComponentDeclaration<MngTableviewComponent<any, any>, "mng-tableview", never, { "descriptor": { "alias": "descriptor"; "required": true; }; "dataProvider": { "alias": "dataProvider"; "required": false; }; "actions": { "alias": "actions"; "required": false; }; }, {}, ["templates"], never, true, never>;
|
|
46
30
|
}
|
|
@@ -251,7 +251,7 @@ export declare class EditorDescriptorInst<EditorModel> implements IEditorDescrip
|
|
|
251
251
|
}
|
|
252
252
|
export declare class EditorDescriptor extends EditorDescriptorInst<any> {
|
|
253
253
|
protected constructor();
|
|
254
|
-
static create<EditorModel>(idProperty
|
|
254
|
+
static create<EditorModel>(idProperty?: keyof EditorModel, titleProperty?: keyof EditorModel, i18nBaseKey?: string | ClassType<unknown>, tableviewEditorType?: TableviewEditorTypeEnum): EditorDescriptorInst<EditorModel>;
|
|
255
255
|
static fromClass<EditorModel>(type: ClassType<EditorModel>, idProperty?: keyof EditorModel, titleProperty?: keyof EditorModel, i18nBaseKey?: ClassType<unknown> | string, tableviewEditorType?: TableviewEditorTypeEnum): EditorDescriptorInst<EditorModel>;
|
|
256
256
|
static fromModel<EditorModel>(model: ModelDescriptor<EditorModel>, tableviewEditorType?: TableviewEditorTypeEnum): EditorDescriptorInst<EditorModel>;
|
|
257
257
|
/**
|
|
@@ -13,9 +13,9 @@ export declare class FilterDescriptor<FilterModel> {
|
|
|
13
13
|
protected _numberUseGrouping: boolean;
|
|
14
14
|
protected _datePickerFormat?: string;
|
|
15
15
|
protected _datePickerShowTime: boolean;
|
|
16
|
-
protected
|
|
17
|
-
protected
|
|
18
|
-
protected
|
|
16
|
+
protected _datePickerValueNoTime?: boolean;
|
|
17
|
+
protected _datePickerValueNoTimezone?: boolean;
|
|
18
|
+
protected _datePickerValueUtc?: boolean;
|
|
19
19
|
protected _placeholder?: string;
|
|
20
20
|
protected _className: string;
|
|
21
21
|
protected _columnClassName: string;
|
|
@@ -34,9 +34,9 @@ export declare class FilterDescriptor<FilterModel> {
|
|
|
34
34
|
get numberUseGrouping(): boolean;
|
|
35
35
|
get datePickerFormat(): string | undefined;
|
|
36
36
|
get datePickerShowTime(): boolean;
|
|
37
|
-
get
|
|
38
|
-
get
|
|
39
|
-
get
|
|
37
|
+
get datePickerValueUtc(): boolean | undefined;
|
|
38
|
+
get datePickerValueNoTimezone(): boolean | undefined;
|
|
39
|
+
get datePickerValueNoTime(): boolean | undefined;
|
|
40
40
|
get placeholder(): string | undefined;
|
|
41
41
|
get className(): string;
|
|
42
42
|
get columnClassName(): string;
|
|
@@ -53,7 +53,7 @@ export declare class FilterDescriptor<FilterModel> {
|
|
|
53
53
|
withNumberFractions(min?: number, max?: number): this;
|
|
54
54
|
withNumberGrouping(useGrouping?: boolean): this;
|
|
55
55
|
withDateFormat(format?: string, showTime?: boolean): this;
|
|
56
|
-
withDateValue(
|
|
56
|
+
withDateValue(utc?: boolean, noTimezone?: boolean, noTime?: boolean): this;
|
|
57
57
|
withPlaceholder(placeholder: string): this;
|
|
58
58
|
withClassName(className: string): this;
|
|
59
59
|
withColumnClassName(className: string): this;
|
|
@@ -10,11 +10,12 @@ import { ITableDescriptorInternal } from './internal/table.model';
|
|
|
10
10
|
export declare class TableDescriptorInst<TableModel> implements ITableDescriptorInternal<TableModel>, IColumnsManageInterface<TableModel> {
|
|
11
11
|
private readonly _model;
|
|
12
12
|
protected readonly _autoGenerated: boolean;
|
|
13
|
+
private _identifier?;
|
|
13
14
|
private _trackProperty?;
|
|
14
15
|
private _filterDisplay;
|
|
15
16
|
private _paginationMode?;
|
|
16
|
-
private _rowsPerPageOptions
|
|
17
|
-
private _defaultNumRows
|
|
17
|
+
private _rowsPerPageOptions?;
|
|
18
|
+
private _defaultNumRows?;
|
|
18
19
|
protected _columns: Array<ColumnDescriptor<any, TableModel>>;
|
|
19
20
|
private _title?;
|
|
20
21
|
private _hideHeader;
|
|
@@ -23,27 +24,28 @@ export declare class TableDescriptorInst<TableModel> implements ITableDescriptor
|
|
|
23
24
|
private _hasDefaultSort;
|
|
24
25
|
private _defaultSortProperty;
|
|
25
26
|
private _defaultSortAsc;
|
|
26
|
-
private _className;
|
|
27
|
-
private _size;
|
|
28
|
-
private _tableFullHeightOffset?;
|
|
29
|
-
private _rowHeight?;
|
|
30
27
|
private _hasHover;
|
|
31
28
|
private _hasGridlines;
|
|
32
29
|
private _hasResizableColumns;
|
|
33
|
-
private _columnResizeMode
|
|
30
|
+
private _columnResizeMode?;
|
|
34
31
|
private _selectionColumnFrozen?;
|
|
35
32
|
private _actionColumnFrozen?;
|
|
33
|
+
private _size;
|
|
34
|
+
private _className;
|
|
36
35
|
private _headerClassName?;
|
|
37
36
|
private _rowClassName?;
|
|
38
37
|
private _rowClassNameMapFn?;
|
|
38
|
+
private _tableFullHeightOffset?;
|
|
39
|
+
private _rowHeight?;
|
|
39
40
|
private _isLocalized;
|
|
40
41
|
private _localizationLocaleProperty?;
|
|
41
42
|
protected constructor(model: ModelDescriptor<TableModel>, autoGenerated?: boolean);
|
|
43
|
+
get identifier(): string | undefined;
|
|
42
44
|
get trackProperty(): string | undefined;
|
|
43
45
|
get filterDisplay(): TableFilterDisplayEnum;
|
|
44
46
|
get paginationMode(): TablePaginationModeEnum | undefined;
|
|
45
|
-
get rowsPerPageOptions(): number[];
|
|
46
|
-
get defaultNumRows(): number;
|
|
47
|
+
get rowsPerPageOptions(): number[] | undefined;
|
|
48
|
+
get defaultNumRows(): number | undefined;
|
|
47
49
|
get columns(): ColumnDescriptor<any, TableModel, any, string>[];
|
|
48
50
|
get title(): string | undefined;
|
|
49
51
|
get hideHeader(): boolean;
|
|
@@ -60,7 +62,7 @@ export declare class TableDescriptorInst<TableModel> implements ITableDescriptor
|
|
|
60
62
|
get hasHover(): boolean;
|
|
61
63
|
get hasGridlines(): boolean;
|
|
62
64
|
get hasResizableColumns(): boolean;
|
|
63
|
-
get columnResizeMode(): "fit" | "expand";
|
|
65
|
+
get columnResizeMode(): "fit" | "expand" | undefined;
|
|
64
66
|
get rowClassName(): string | undefined;
|
|
65
67
|
get rowClassNameMapFn(): ((className?: string | undefined, item?: TableModel | undefined) => string) | undefined;
|
|
66
68
|
get selectionColumnFrozen(): boolean | undefined;
|
|
@@ -71,8 +73,9 @@ export declare class TableDescriptorInst<TableModel> implements ITableDescriptor
|
|
|
71
73
|
/**
|
|
72
74
|
* Track property is used for the purpose of combined saving user preferences in localstorage if 2 tables have the same track properties they will share the same localstorage entry.
|
|
73
75
|
* Similarly, this property can also be used to differentiate two tables of the same model on the same url (so that they have separate entries in localstorage).
|
|
74
|
-
* @param
|
|
76
|
+
* @param identifier
|
|
75
77
|
*/
|
|
78
|
+
withIdentifier(identifier: string): this;
|
|
76
79
|
withTrackProperty(property?: keyof TableModel): this;
|
|
77
80
|
withTrackPropertyUnsafe(property?: string): this;
|
|
78
81
|
getColumn(property: keyof TableModel): ColumnDescriptor<any, TableModel, any, string> | null;
|
|
@@ -162,7 +165,7 @@ export declare class TableDescriptorInst<TableModel> implements ITableDescriptor
|
|
|
162
165
|
}
|
|
163
166
|
export declare class TableDescriptor extends TableDescriptorInst<any> {
|
|
164
167
|
protected constructor();
|
|
165
|
-
static create<TableModel>(idProperty
|
|
168
|
+
static create<TableModel>(idProperty?: keyof TableModel, titleProperty?: keyof TableModel, i18nBaseKey?: string | ClassType<unknown>): TableDescriptorInst<TableModel>;
|
|
166
169
|
static fromClass<TableModel>(type: ClassType<TableModel>, idProperty?: keyof TableModel, titleProperty?: keyof TableModel, i18nBaseKey?: ClassType<unknown> | string, isAutoGenerated?: boolean): TableDescriptorInst<TableModel>;
|
|
167
170
|
static fromModel<TableModel>(model: ModelDescriptor<TableModel>): TableDescriptorInst<TableModel>;
|
|
168
171
|
/**
|
|
@@ -115,7 +115,7 @@ export declare class TableviewDescriptorInst<TableviewModel> implements ITablevi
|
|
|
115
115
|
}
|
|
116
116
|
export declare class TableviewDescriptor extends TableviewDescriptorInst<any> {
|
|
117
117
|
protected constructor();
|
|
118
|
-
static create<TableviewModel>(idProperty
|
|
118
|
+
static create<TableviewModel>(idProperty?: keyof TableviewModel, titleProperty?: keyof TableviewModel, i18nBaseKey?: string | ClassType<unknown>): TableviewDescriptorInst<TableviewModel>;
|
|
119
119
|
static fromClass<TableviewModel>(type: ClassType<TableviewModel>, idProperty?: keyof TableviewModel, titleProperty?: keyof TableviewModel, i18nBaseKey?: ClassType<unknown> | string): TableviewDescriptorInst<TableviewModel>;
|
|
120
120
|
static fromModel<TableviewModel>(model: ModelDescriptor<TableviewModel>): TableviewDescriptorInst<TableviewModel>;
|
|
121
121
|
/**
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ComponentRef, OnInit, Type } from '@angular/core';
|
|
1
|
+
import { ComponentRef, Injector, OnInit, Type } from '@angular/core';
|
|
2
2
|
import * as i0 from "@angular/core";
|
|
3
3
|
export declare class MngComponentDirective<C> implements OnInit {
|
|
4
4
|
private readonly injector;
|
|
@@ -10,10 +10,11 @@ export declare class MngComponentDirective<C> implements OnInit {
|
|
|
10
10
|
[key: string]: any;
|
|
11
11
|
};
|
|
12
12
|
attachToHost: boolean;
|
|
13
|
+
nodeInjector?: Injector;
|
|
13
14
|
private componentInstanceEventEmitter;
|
|
14
15
|
componentRef: ComponentRef<C>;
|
|
15
16
|
ngOnInit(): void;
|
|
16
17
|
private isCmpInstanceOfColumnValue;
|
|
17
18
|
static ɵfac: i0.ɵɵFactoryDeclaration<MngComponentDirective<any>, never>;
|
|
18
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<MngComponentDirective<any>, "[mngComponent]", never, { "component": { "alias": "mngComponent"; "required": true; }; "inputs": { "alias": "inputs"; "required": false; }; "attachToHost": { "alias": "attachToHost"; "required": false; }; }, { "componentInstanceEventEmitter": "instanceCreated"; }, never, never, true, never>;
|
|
19
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<MngComponentDirective<any>, "[mngComponent]", never, { "component": { "alias": "mngComponent"; "required": true; }; "inputs": { "alias": "inputs"; "required": false; }; "attachToHost": { "alias": "attachToHost"; "required": false; }; "nodeInjector": { "alias": "nodeInjector"; "required": false; }; }, { "componentInstanceEventEmitter": "instanceCreated"; }, never, never, true, never>;
|
|
19
20
|
}
|
|
@@ -1,4 +1,15 @@
|
|
|
1
|
+
import { Injector } from '@angular/core';
|
|
1
2
|
import { Observable } from 'rxjs';
|
|
3
|
+
import { ActionInstance } from '../components/action/models';
|
|
4
|
+
import { ActionEditorDescriptorInst } from '../descriptors/action';
|
|
2
5
|
export interface IActionEditorComponent {
|
|
3
6
|
closeWithUnsavedChangesConfirmation(callFromGuard: boolean): Observable<boolean>;
|
|
4
7
|
}
|
|
8
|
+
export interface ActionEditorDialogData<T, S> {
|
|
9
|
+
action: {
|
|
10
|
+
descriptor: ActionEditorDescriptorInst<T>;
|
|
11
|
+
instance: ActionInstance<T, S>;
|
|
12
|
+
previousInstance?: ActionInstance<any, any>;
|
|
13
|
+
};
|
|
14
|
+
injector: Injector;
|
|
15
|
+
}
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import { Type } from '@angular/core';
|
|
2
1
|
import { ValidatorOption, WrapperOption } from '@ngx-formly/core/lib/models/config';
|
|
3
2
|
import { TranslateService } from '@ngx-translate/core';
|
|
4
3
|
import { MngFormlyTypeConfig } from '../components/form/formly/models';
|
|
4
|
+
import { MngLayoutConfig, MngLayoutConfigV2 } from './layout-config.model';
|
|
5
5
|
import { MngLogConfig } from './log.model';
|
|
6
|
-
import { MngMenuConfig, MngMenuConfigV2 } from './menu-config.model';
|
|
7
6
|
import { VersionConfigType } from './version.model';
|
|
8
7
|
export type ColorScheme = 'light' | 'dark';
|
|
9
8
|
export interface MngModuleConfig {
|
|
@@ -25,8 +24,8 @@ export interface MngModuleConfig {
|
|
|
25
24
|
/**
|
|
26
25
|
* @deprecated use menuV2 instead
|
|
27
26
|
*/
|
|
28
|
-
|
|
29
|
-
|
|
27
|
+
layout?: MngLayoutConfig;
|
|
28
|
+
layoutV2?: MngLayoutConfigV2;
|
|
30
29
|
configuration?: {
|
|
31
30
|
projectEnvironment?: any;
|
|
32
31
|
jsonSource?: string | Array<string>;
|
|
@@ -41,15 +40,6 @@ export interface MngModuleConfig {
|
|
|
41
40
|
validators?: ValidatorOption[];
|
|
42
41
|
getValidationMessages?: (translate: TranslateService) => any[];
|
|
43
42
|
};
|
|
44
|
-
components?: {
|
|
45
|
-
layout?: {
|
|
46
|
-
topbar?: Type<any>;
|
|
47
|
-
menu?: Type<any>;
|
|
48
|
-
footer?: Type<any>;
|
|
49
|
-
breadcrumb?: Type<any>;
|
|
50
|
-
topbarUser?: Type<any>;
|
|
51
|
-
};
|
|
52
|
-
};
|
|
53
43
|
serialization?: {
|
|
54
44
|
dateTimeInUtc?: boolean;
|
|
55
45
|
dateTimeWithTimezone?: boolean;
|
package/lib/models/index.d.ts
CHANGED