imm-element-ui 0.9.2 → 0.9.4
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/lib/crumb-action/crumb-action.component.mjs +4 -3
- package/esm2022/lib/form/form/form.component.mjs +31 -3
- package/esm2022/lib/form/form-field/context-menu.mjs +76 -0
- package/esm2022/lib/form/form-field/field-utils.mjs +9 -1
- package/esm2022/lib/form/form-field/form-field.mjs +20 -5
- package/esm2022/lib/form/form-field/label.directive.mjs +37 -18
- package/esm2022/lib/form/form-type/image.type.mjs +36 -18
- package/esm2022/lib/form/form-type/upload.type.mjs +20 -16
- package/esm2022/lib/grid/grid/grid.component.mjs +4 -3
- package/esm2022/lib/page-form/page-form.component.mjs +30 -6
- package/esm2022/lib/page-grid-list/page-grid-list.component.mjs +2 -2
- package/esm2022/lib/row-selector/row-selector.component.mjs +2 -2
- package/fesm2022/imm-element-ui.mjs +291 -101
- package/fesm2022/imm-element-ui.mjs.map +1 -1
- package/lib/crumb-action/crumb-action.component.d.ts +3 -2
- package/lib/form/form/form.component.d.ts +23 -0
- package/lib/form/form-field/context-menu.d.ts +15 -0
- package/lib/form/form-field/field-utils.d.ts +1 -0
- package/lib/form/form-field/label.directive.d.ts +6 -2
- package/lib/form/form-type/image.type.d.ts +2 -0
- package/lib/grid/grid/grid.component.d.ts +2 -1
- package/lib/page-form/page-form.component.d.ts +4 -0
- package/package.json +1 -1
|
@@ -37,6 +37,7 @@ export declare class CrumbActionComponent extends AmComponent implements OnInit
|
|
|
37
37
|
auth: number;
|
|
38
38
|
}[];
|
|
39
39
|
isSave: import("@angular/core").Signal<boolean>;
|
|
40
|
+
saveBtnDisable: import("@angular/core").InputSignal<boolean>;
|
|
40
41
|
constructor();
|
|
41
42
|
resize(event: any): void;
|
|
42
43
|
ngOnInit(): void;
|
|
@@ -49,8 +50,8 @@ export declare class CrumbActionComponent extends AmComponent implements OnInit
|
|
|
49
50
|
listAct(item: any): void;
|
|
50
51
|
actEvent(item: any): void;
|
|
51
52
|
toggleAct(event: any): void;
|
|
52
|
-
setSaveClass(): "
|
|
53
|
+
setSaveClass(): "secondary" | "danger";
|
|
53
54
|
ngOnDestroy(): void;
|
|
54
55
|
static ɵfac: i0.ɵɵFactoryDeclaration<CrumbActionComponent, never>;
|
|
55
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<CrumbActionComponent, "app-crumb-action", never, { "isShowCog": { "alias": "isShowCog"; "required": false; "isSignal": true; }; "addVisible": { "alias": "addVisible"; "required": false; "isSignal": true; }; "newUrl": { "alias": "newUrl"; "required": false; "isSignal": true; }; "onExport": { "alias": "onExport"; "required": false; "isSignal": true; }; "outlined": { "alias": "outlined"; "required": false; "isSignal": true; }; "isList": { "alias": "isList"; "required": false; "isSignal": true; }; "authLevel": { "alias": "authLevel"; "required": false; "isSignal": true; }; "actionList": { "alias": "actionList"; "required": false; "isSignal": true; }; "data": { "alias": "data"; "required": false; "isSignal": true; }; "menus": { "alias": "menus"; "required": false; "isSignal": true; }; }, { "saveEvent": "saveEvent"; "cancelEvent": "cancelEvent"; "actionEvent": "actionEvent"; }, ["newBtnTemplateRef"], never, true, never>;
|
|
56
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CrumbActionComponent, "app-crumb-action", never, { "isShowCog": { "alias": "isShowCog"; "required": false; "isSignal": true; }; "addVisible": { "alias": "addVisible"; "required": false; "isSignal": true; }; "newUrl": { "alias": "newUrl"; "required": false; "isSignal": true; }; "onExport": { "alias": "onExport"; "required": false; "isSignal": true; }; "outlined": { "alias": "outlined"; "required": false; "isSignal": true; }; "isList": { "alias": "isList"; "required": false; "isSignal": true; }; "authLevel": { "alias": "authLevel"; "required": false; "isSignal": true; }; "actionList": { "alias": "actionList"; "required": false; "isSignal": true; }; "data": { "alias": "data"; "required": false; "isSignal": true; }; "menus": { "alias": "menus"; "required": false; "isSignal": true; }; "saveBtnDisable": { "alias": "saveBtnDisable"; "required": false; "isSignal": true; }; }, { "saveEvent": "saveEvent"; "cancelEvent": "cancelEvent"; "actionEvent": "actionEvent"; }, ["newBtnTemplateRef"], never, true, never>;
|
|
56
57
|
}
|
|
@@ -19,6 +19,11 @@ export interface FormOptions {
|
|
|
19
19
|
type?: string;
|
|
20
20
|
fk?: string;
|
|
21
21
|
}
|
|
22
|
+
export interface ExternalData {
|
|
23
|
+
key?: string;
|
|
24
|
+
value?: any;
|
|
25
|
+
label?: string;
|
|
26
|
+
}
|
|
22
27
|
export declare class FormComponent {
|
|
23
28
|
private cdr;
|
|
24
29
|
private datePipe;
|
|
@@ -37,6 +42,7 @@ export declare class FormComponent {
|
|
|
37
42
|
labelMinWidth: import("@angular/core").WritableSignal<string | undefined>;
|
|
38
43
|
isMain: boolean;
|
|
39
44
|
subsert: any;
|
|
45
|
+
extra: any;
|
|
40
46
|
actions: ActionService;
|
|
41
47
|
onResize(): void;
|
|
42
48
|
constructor(cdr: ChangeDetectorRef, datePipe: DatePipe);
|
|
@@ -56,7 +62,24 @@ export declare class FormComponent {
|
|
|
56
62
|
reCalcLabelSize(): void;
|
|
57
63
|
handleFieldLabels(): void;
|
|
58
64
|
getFieldLabels(fieldComponents: QueryList<FormFieldComponent> | undefined, fieldLabels: ElementRef[]): void;
|
|
65
|
+
/**
|
|
66
|
+
* 触发模型变动,针对表单字段数据
|
|
67
|
+
* @param model 需要变动的数据
|
|
68
|
+
*/
|
|
59
69
|
triggerModelEffect(model: any): void;
|
|
70
|
+
/**
|
|
71
|
+
* 触发数据变动,针对非表单字段数据
|
|
72
|
+
* @param dataList 外部数据列表
|
|
73
|
+
*/
|
|
74
|
+
triggerDataEffect(dataList: ExternalData[]): void;
|
|
75
|
+
/**
|
|
76
|
+
* 动态设置字段禁用,禁用前清除字段dirty标记
|
|
77
|
+
* @param key 字段key
|
|
78
|
+
*/
|
|
79
|
+
setFieldDisabled(key: string): void;
|
|
80
|
+
/**
|
|
81
|
+
* 表单提交后的收尾处理,一般在提交接口的回调函数执行
|
|
82
|
+
*/
|
|
60
83
|
finalize(): void;
|
|
61
84
|
static ɵfac: i0.ɵɵFactoryDeclaration<FormComponent, never>;
|
|
62
85
|
static ɵcmp: i0.ɵɵComponentDeclaration<FormComponent, "custom-form", never, { "options": { "alias": "options"; "required": false; "isSignal": true; }; "model": { "alias": "model"; "required": false; "isSignal": true; }; "upsert": { "alias": "upsert"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { MenuItem } from 'primeng/api';
|
|
2
|
+
import { ContextMenu } from 'primeng/contextmenu';
|
|
3
|
+
import { Clipboard } from '@angular/cdk/clipboard';
|
|
4
|
+
import { FormField } from './form-field';
|
|
5
|
+
import * as i0 from "@angular/core";
|
|
6
|
+
export declare class ContextMenuComponent {
|
|
7
|
+
private clipboard;
|
|
8
|
+
cm?: ContextMenu;
|
|
9
|
+
target: import("@angular/core").InputSignal<any>;
|
|
10
|
+
field: import("@angular/core").InputSignal<FormField | undefined>;
|
|
11
|
+
items?: MenuItem[];
|
|
12
|
+
constructor(clipboard: Clipboard);
|
|
13
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ContextMenuComponent, never>;
|
|
14
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ContextMenuComponent, "app-context-menu", never, { "target": { "alias": "target"; "required": false; "isSignal": true; }; "field": { "alias": "field"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
15
|
+
}
|
|
@@ -4,6 +4,7 @@ import { I18nService } from '../../service/i18n.service';
|
|
|
4
4
|
export declare const fieldUtils: {
|
|
5
5
|
props: (field: FormField) => FieldProps;
|
|
6
6
|
label: (field: FormField, i18nService: I18nService) => string | undefined;
|
|
7
|
+
fieldHandler: (field: FormField) => void;
|
|
7
8
|
triggerHookAndSetValue: (field: FormField, value: any, emitEvent: boolean, detectModelChange: boolean, hookObservers: any[], callback: any, datePipe: DatePipe) => void;
|
|
8
9
|
fromFieldValue: (field: FormField, target: any, datePipe: DatePipe) => any;
|
|
9
10
|
preloadLog: (rawModel: any, fieldList: FormField[], datePipe: DatePipe) => any;
|
|
@@ -1,14 +1,18 @@
|
|
|
1
|
+
import { ViewContainerRef } from '@angular/core';
|
|
1
2
|
import { ActionService } from '../../service/action.service';
|
|
2
3
|
import { FormField } from './form-field';
|
|
3
4
|
import * as i0 from "@angular/core";
|
|
4
5
|
export declare class LabelDirective {
|
|
5
6
|
private action;
|
|
6
|
-
|
|
7
|
+
container?: ViewContainerRef;
|
|
8
|
+
field: import("@angular/core").InputSignal<FormField | undefined>;
|
|
9
|
+
contextMenu: import("@angular/core").InputSignal<any>;
|
|
7
10
|
constructor(action: ActionService);
|
|
8
11
|
onMouseEnter(): void;
|
|
9
12
|
onMouseLeave(): void;
|
|
10
13
|
onClick(): void;
|
|
11
14
|
onDoubleClick(): void;
|
|
15
|
+
onRightClick(event: MouseEvent): void;
|
|
12
16
|
static ɵfac: i0.ɵɵFactoryDeclaration<LabelDirective, never>;
|
|
13
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<LabelDirective, "[fieldLabel]", never, { "
|
|
17
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<LabelDirective, "[fieldLabel], [fieldLabel][field], [fieldLabel][contextMenu]", never, { "field": { "alias": "field"; "required": false; "isSignal": true; }; "contextMenu": { "alias": "contextMenu"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
14
18
|
}
|
|
@@ -18,6 +18,7 @@ export interface ImageProps extends FieldProps {
|
|
|
18
18
|
cancelStyleClass?: string;
|
|
19
19
|
removeStyleClass?: string;
|
|
20
20
|
chooseStyleClass?: string;
|
|
21
|
+
adjustable?: boolean;
|
|
21
22
|
onBeforeUpload?: AttributeEvent;
|
|
22
23
|
onSend?: AttributeEvent;
|
|
23
24
|
onUpload?: AttributeEvent;
|
|
@@ -45,6 +46,7 @@ export declare class ImageComponent {
|
|
|
45
46
|
handleModelChange(): void;
|
|
46
47
|
afterSubmit(): void;
|
|
47
48
|
handleDisabled(): void;
|
|
49
|
+
ajustedImage(event: any): void;
|
|
48
50
|
static ɵfac: i0.ɵɵFactoryDeclaration<ImageComponent, never>;
|
|
49
51
|
static ɵcmp: i0.ɵɵComponentDeclaration<ImageComponent, "form-image", never, { "field": { "alias": "field"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
50
52
|
}
|
|
@@ -263,6 +263,7 @@ export declare class GridComponent {
|
|
|
263
263
|
ngZone: NgZone;
|
|
264
264
|
cdr: ChangeDetectorRef;
|
|
265
265
|
showDelete: import("@angular/core").InputSignal<boolean>;
|
|
266
|
+
gridDisable: import("@angular/core").InputSignal<boolean>;
|
|
266
267
|
richMultMap: Record<string, any>;
|
|
267
268
|
horizontalScrollBarObserver: any;
|
|
268
269
|
horizontalScrollBarHeight: number;
|
|
@@ -303,5 +304,5 @@ export declare class GridComponent {
|
|
|
303
304
|
rowDragEnter(event: any): void;
|
|
304
305
|
onRowDragEnd(event: RowDragEndEvent): void;
|
|
305
306
|
static ɵfac: i0.ɵɵFactoryDeclaration<GridComponent, never>;
|
|
306
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<GridComponent, "custom-grid", never, { "gridOptions": { "alias": "gridOptions"; "required": false; "isSignal": true; }; "upsert": { "alias": "upsert"; "required": false; "isSignal": true; }; "rowData": { "alias": "rowData"; "required": false; "isSignal": true; }; "searchPrm": { "alias": "searchPrm"; "required": false; "isSignal": true; }; "addType": { "alias": "addType"; "required": false; "isSignal": true; }; "selectData": { "alias": "selectData"; "required": false; "isSignal": true; }; "showAct": { "alias": "showAct"; "required": false; "isSignal": true; }; "actPos": { "alias": "actPos"; "required": false; "isSignal": true; }; "authLevel": { "alias": "authLevel"; "required": false; "isSignal": true; }; "showDelete": { "alias": "showDelete"; "required": false; "isSignal": true; }; }, { "deleteEmit": "deleteEmit"; "addEmit": "addEmit"; }, never, never, true, never>;
|
|
307
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<GridComponent, "custom-grid", never, { "gridOptions": { "alias": "gridOptions"; "required": false; "isSignal": true; }; "upsert": { "alias": "upsert"; "required": false; "isSignal": true; }; "rowData": { "alias": "rowData"; "required": false; "isSignal": true; }; "searchPrm": { "alias": "searchPrm"; "required": false; "isSignal": true; }; "addType": { "alias": "addType"; "required": false; "isSignal": true; }; "selectData": { "alias": "selectData"; "required": false; "isSignal": true; }; "showAct": { "alias": "showAct"; "required": false; "isSignal": true; }; "actPos": { "alias": "actPos"; "required": false; "isSignal": true; }; "authLevel": { "alias": "authLevel"; "required": false; "isSignal": true; }; "showDelete": { "alias": "showDelete"; "required": false; "isSignal": true; }; "gridDisable": { "alias": "gridDisable"; "required": false; "isSignal": true; }; }, { "deleteEmit": "deleteEmit"; "addEmit": "addEmit"; }, never, never, true, never>;
|
|
307
308
|
}
|
|
@@ -41,6 +41,8 @@ export declare class PageFormComponent extends AmComponent implements OnInit {
|
|
|
41
41
|
hrefs: any[];
|
|
42
42
|
action: ActionService;
|
|
43
43
|
subFormModel: any;
|
|
44
|
+
saveBtnDisable: boolean;
|
|
45
|
+
gridDisable: boolean;
|
|
44
46
|
constructor();
|
|
45
47
|
ngOnInit(): void;
|
|
46
48
|
submitForm(): any;
|
|
@@ -56,6 +58,8 @@ export declare class PageFormComponent extends AmComponent implements OnInit {
|
|
|
56
58
|
authClick(btn: any): void;
|
|
57
59
|
statusChange(value: any, customSteps: StepsComponent): void;
|
|
58
60
|
formDisFunc(): void;
|
|
61
|
+
disableForm(disable: boolean): void;
|
|
62
|
+
disabeldChild(disabeld: boolean): void;
|
|
59
63
|
setDisabled(): void;
|
|
60
64
|
tabClick(): void;
|
|
61
65
|
static ɵfac: i0.ɵɵFactoryDeclaration<PageFormComponent, never>;
|