ngx-formly-zorro-antd 16.1.2 → 16.1.3
Sign up to get free protection for your applications and to get access to all the features.
- package/cascader/cascader.type.d.ts +4 -4
- package/esm2022/cascader/cascader.type.mjs +1 -1
- package/esm2022/lib/ui-ng-zorro-antd.module.mjs +8 -4
- package/esm2022/radio/radio.type.mjs +1 -3
- package/esm2022/ref-template/ngx-formly-zorro-antd-ref-template.mjs +5 -0
- package/esm2022/ref-template/public_api.mjs +3 -0
- package/esm2022/ref-template/ref-template.module.mjs +44 -0
- package/esm2022/ref-template/ref-template.type.mjs +89 -0
- package/esm2022/space/space.type.mjs +1 -1
- package/fesm2022/ngx-formly-zorro-antd-cascader.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-radio.mjs +0 -2
- package/fesm2022/ngx-formly-zorro-antd-radio.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-ref-template.mjs +136 -0
- package/fesm2022/ngx-formly-zorro-antd-ref-template.mjs.map +1 -0
- package/fesm2022/ngx-formly-zorro-antd-space.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd.mjs +7 -3
- package/fesm2022/ngx-formly-zorro-antd.mjs.map +1 -1
- package/lib/ui-ng-zorro-antd.module.d.ts +2 -1
- package/package.json +25 -19
- package/ref-template/index.d.ts +5 -0
- package/ref-template/public_api.d.ts +2 -0
- package/ref-template/ref-template.module.d.ts +11 -0
- package/ref-template/ref-template.type.d.ts +79 -0
@@ -3,7 +3,7 @@ import { FieldType, FieldTypeConfig } from '@ngx-formly/core';
|
|
3
3
|
import { FormlyFieldProps } from 'ngx-formly-zorro-antd/form-field';
|
4
4
|
import type { NzCascaderOption, NzShowSearchOptions, NzCascaderExpandTrigger, NzCascaderSize } from 'ng-zorro-antd/cascader';
|
5
5
|
import type { NzSafeAny, NzStatus, NgStyleInterface } from 'ng-zorro-antd/core/types';
|
6
|
-
import type { NzFormlyFieldConfig } from 'ngx-formly-zorro-antd/common';
|
6
|
+
import type { NzFormlyFieldConfig, FormlyAttributeEvent } from 'ngx-formly-zorro-antd/common';
|
7
7
|
import * as i0 from "@angular/core";
|
8
8
|
interface CascaderProps extends FormlyFieldProps {
|
9
9
|
/**
|
@@ -115,15 +115,15 @@ interface CascaderProps extends FormlyFieldProps {
|
|
115
115
|
/**
|
116
116
|
* 清除值时触发
|
117
117
|
*/
|
118
|
-
onClear?:
|
118
|
+
onClear?: FormlyAttributeEvent;
|
119
119
|
/**
|
120
120
|
* 菜单浮层的显示/隐藏
|
121
121
|
*/
|
122
|
-
visibleChange?:
|
122
|
+
visibleChange?: FormlyAttributeEvent<boolean>;
|
123
123
|
/**
|
124
124
|
* 值发生变化时触发
|
125
125
|
*/
|
126
|
-
selectionChange?:
|
126
|
+
selectionChange?: FormlyAttributeEvent<NzCascaderOption[]>;
|
127
127
|
}
|
128
128
|
export interface FormlyCascaderFieldConfig extends NzFormlyFieldConfig<CascaderProps> {
|
129
129
|
type: 'cascader' | Type<FormlyFieldCascader>;
|
@@ -107,4 +107,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.5", ngImpor
|
|
107
107
|
changeDetection: ChangeDetectionStrategy.OnPush
|
108
108
|
}]
|
109
109
|
}] });
|
110
|
-
//# sourceMappingURL=data:application/json;base64,
|
110
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY2FzY2FkZXIudHlwZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3BhY2thZ2VzL2Zvcm1seWFudGQvY2FzY2FkZXIvc3JjL2Nhc2NhZGVyLnR5cGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFNBQVMsRUFBcUIsdUJBQXVCLEVBQVUsTUFBTSxlQUFlLENBQUM7QUFDOUYsT0FBTyxFQUFFLFNBQVMsRUFBbUIsTUFBTSxrQkFBa0IsQ0FBQzs7Ozs7O0FBbU05RCxNQU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hXCJcbiAgICBbbnpDb2x1bW5DbGFzc05hbWVdPVwicHJvcHNbJ2NvbHVtbkNsYXNzTmFtZSddXCJcbiAgICBbbnpFeHBhbmRJY29uXT1cInByb3BzWydleHBhbmRJY29uJ10hXCJcbiAgICBbbnpFeHBhbmRUcmlnZ2VyXT1cInByb3BzWydleHBhbmRUcmlnZ2VyJ10hXCJcbiAgICBbbnpMYWJlbFByb3BlcnR5XT1cInByb3BzWydsYWJlbFByb3BlcnR5J11cIlxuICAgIFtuekxhYmVsUmVuZGVyXT1cInByb3BzWydsYWJlbFJlbmRlciddID8/IG51bGxcIlxuICAgIFtuekxvYWREYXRhXT1cInByb3BzWydsb2FkRGF0YSddXCJcbiAgICBbbnpNZW51Q2xhc3NOYW1lXT1cInByb3BzWydtZW51Q2xhc3NOYW1lJ11cIlxuICAgIFtuek1lbnVTdHlsZV09XCJwcm9wc1snbWVudVN0eWxlJ10gPz8gbnVsbFwiXG4gICAgW256Tm90Rm91bmRDb250ZW50XT1cInByb3BzWydub3RGb3VuZENvbnRlbnQnXVwiXG4gICAgW256T3B0aW9uUmVuZGVyXT1cInByb3BzWydvcHRpb25SZW5kZXInXSA/PyBudWxsXCJcbiAgICBbbnpPcHRpb25zXT1cInByb3BzWydjYXNjYWRlck9wdGlvbnMnXSA/PyBudWxsXCJcbiAgICBbbnpTaG93QXJyb3ddPVwicHJvcHNbJ3Nob3dBcnJvdyddISFcIlxuICAgIFtuelNob3dJbnB1dF09XCJwcm9wc1snc2hvd0lucHV0J10hIVwiXG4gICAgW256U2hvd1NlYXJjaF09XCJwcm9wc1snc2hvd1NlYXJjaCddISFcIlxuICAgIFtuelNpemVdPVwicHJvcHNbJ3NpemUnXSFcIlxuICAgIFtuelN0YXR1c109XCJwcm9wc1snc3RhdHVzJ10gPz8gJydcIlxuICAgIFtuelN1ZmZpeEljb25dPVwicHJvcHNbJ3N1ZmZpeEljb24nXSFcIlxuICAgIFtuelZhbHVlUHJvcGVydHldPVwicHJvcHNbJ3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N0LFxuICAgICAgdmFsdWVQcm9wZXJ0eTogJ3ZhbHVlJyxcbiAgICAgIGNhc2NhZGVyT3B0aW9uczogW11cbiAgICB9XG4gIH07XG5cbiAgbmdPbkluaXQoKTogdm9pZCB7XG4gICAgY29uc3Qgb3B0aW9ucyA9IHRoaXMucHJvcHNbJ2Nhc2NhZGVyT3B0aW9ucyddO1xuICAgIGlmICghb3B0aW9ucyB8fCBvcHRpb25zLmxlbmd0aCA9PT0gMCkge1xuICAgICAgdGhpcy5wcm9wc1snY2FzY2FkZXJPcHRpb25zJ10gPSB0aGlzLnByb3BzLm9wdGlvbnMgYXMgTnpTYWZlQW55O1xuICAgIH1cbiAgfVxufVxuIl19
|
@@ -23,6 +23,7 @@ import { FormlyNzCardWrapperModule } from 'ngx-formly-zorro-antd/card-wrapper';
|
|
23
23
|
import { FormlyNzButtonModule } from 'ngx-formly-zorro-antd/button';
|
24
24
|
import { FormlyNzGridModule } from 'ngx-formly-zorro-antd/grid';
|
25
25
|
import { FormlyNzSpaceModule } from 'ngx-formly-zorro-antd/space';
|
26
|
+
import { FormlyRefTemplateModule } from 'ngx-formly-zorro-antd/ref-template';
|
26
27
|
import * as i0 from "@angular/core";
|
27
28
|
export class FormlyNgAntdModule {
|
28
29
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.5", ngImport: i0, type: FormlyNgAntdModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
@@ -49,7 +50,8 @@ export class FormlyNgAntdModule {
|
|
49
50
|
FormlyNzCardWrapperModule,
|
50
51
|
FormlyNzButtonModule,
|
51
52
|
FormlyNzGridModule,
|
52
|
-
FormlyNzSpaceModule
|
53
|
+
FormlyNzSpaceModule,
|
54
|
+
FormlyRefTemplateModule] }); }
|
53
55
|
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.5", ngImport: i0, type: FormlyNgAntdModule, imports: [FormlyNzFormFieldModule,
|
54
56
|
FormlyCommonModule,
|
55
57
|
FormlyNzInputModule,
|
@@ -73,7 +75,8 @@ export class FormlyNgAntdModule {
|
|
73
75
|
FormlyNzCardWrapperModule,
|
74
76
|
FormlyNzButtonModule,
|
75
77
|
FormlyNzGridModule,
|
76
|
-
FormlyNzSpaceModule
|
78
|
+
FormlyNzSpaceModule,
|
79
|
+
FormlyRefTemplateModule] }); }
|
77
80
|
}
|
78
81
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.5", ngImport: i0, type: FormlyNgAntdModule, decorators: [{
|
79
82
|
type: NgModule,
|
@@ -102,8 +105,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.5", ngImpor
|
|
102
105
|
FormlyNzCardWrapperModule,
|
103
106
|
FormlyNzButtonModule,
|
104
107
|
FormlyNzGridModule,
|
105
|
-
FormlyNzSpaceModule
|
108
|
+
FormlyNzSpaceModule,
|
109
|
+
FormlyRefTemplateModule
|
106
110
|
]
|
107
111
|
}]
|
108
112
|
}] });
|
109
|
-
//# sourceMappingURL=data:application/json;base64,
|
113
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidWktbmctem9ycm8tYW50ZC5tb2R1bGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wYWNrYWdlcy9mb3JtbHlhbnRkL3NyYy9saWIvdWktbmctem9ycm8tYW50ZC5tb2R1bGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFFBQVEsRUFBRSxNQUFNLGVBQWUsQ0FBQztBQUV6QyxPQUFPLEVBQUUsdUJBQXVCLEVBQUUsTUFBTSxrQ0FBa0MsQ0FBQztBQUMzRSxPQUFPLEVBQUUsa0JBQWtCLEVBQUUsTUFBTSw4QkFBOEIsQ0FBQztBQUNsRSxPQUFPLEVBQUUsbUJBQW1CLEVBQUUsTUFBTSw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4gIF1cbn0pXG5leHBvcnQgY2xhc3MgRm9ybWx5TmdBbnRkTW9kdWxlIHt9XG4iXX0=
|
@@ -24,7 +24,6 @@ export class FormlyFieldRadio extends FieldType {
|
|
24
24
|
[nzName]="field.name ?? null"
|
25
25
|
[nzSize]="props['size']!"
|
26
26
|
[nzButtonStyle]="props['buttonStyle']!"
|
27
|
-
(ngModelChange)="props.change && props.change(field, $event)"
|
28
27
|
>
|
29
28
|
<ng-container *ngIf="props.type !== 'button'; else button">
|
30
29
|
<label
|
@@ -63,7 +62,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.5", ngImpor
|
|
63
62
|
[nzName]="field.name ?? null"
|
64
63
|
[nzSize]="props['size']!"
|
65
64
|
[nzButtonStyle]="props['buttonStyle']!"
|
66
|
-
(ngModelChange)="props.change && props.change(field, $event)"
|
67
65
|
>
|
68
66
|
<ng-container *ngIf="props.type !== 'button'; else button">
|
69
67
|
<label
|
@@ -93,4 +91,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.5", ngImpor
|
|
93
91
|
changeDetection: ChangeDetectionStrategy.OnPush
|
94
92
|
}]
|
95
93
|
}] });
|
96
|
-
//# sourceMappingURL=data:application/json;base64,
|
94
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmFkaW8udHlwZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3BhY2thZ2VzL2Zvcm1seWFudGQvcmFkaW8vc3JjL3JhZGlvLnR5cGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFNBQVMsRUFBRSx1QkFBdUIsRUFBUSxNQUFNLGVBQWUsQ0FBQztBQUN6RSxPQUFPLEVBQUUsU0FBUyxFQUFtQixNQUFNLGtCQUFrQixDQUFDOzs7Ozs7O0FBb0U5RCxNQUFNLE9BQ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bGRcIlxuICAgICAgW256TmFtZV09XCJmaWVsZC5uYW1lID8/IG51bGxcIlxuICAgICAgW256U2l6ZV09XCJwcm9wc1snc2l6ZSddIVwiXG4gICAgICBbbnpCdXR0b25TdHlsZV09XCJwcm9wc1snYnV0dG9uU3R5bGUnXSFcIlxuICAgID5cbiAgICAgIDxuZy1jb250YWluZXIgKm5nSWY9XCJwcm9wcy50eXBlICE9PSAnYnV0dG9uJzsgZWxzZSBidXR0b25cIj5cbiAgICAgICAgPGxhYmVsXG4gICAgICAgICAgKm5nRm9yPVwibGV0IG9wdGlvbiBvZiBwcm9wcy5vcHRpb25zIHwgZm9ybWx5U2VsZWN0T3B0aW9uczogZmllbGQgfCBhc3luYzsgbGV0IGkgPSBpbmRleFwiXG4gICAgICAgICAgW2lkXT1cImlkICsgJ18nICsgaVwiXG4gICAgICAgICAgW256RGlzYWJsZWRdPVwib3B0aW9uLmRpc2FibGVkID09PSB0cnVlXCJcbiAgICAgICAgICBbbnpWYWx1ZV09XCJvcHRpb24udmFsdWVcIlxuICAgICAgICAgIG56LXJhZGlvXG4gICAgICAgID5cbiAgICAgICAgICB7eyBvcHRpb24ubGFiZWwgfX1cbiAgICAgICAgPC9sYWJlbD5cbiAgICAgIDwvbmctY29udGFpbmVyPlxuXG4gICAgICA8bmctdGVtcGxhdGUgI2J1dHRvbj5cbiAgICAgICAgPGxhYmVsXG4gICAgICAgICAgKm5nRm9yPVwibGV0IG9wdGlvbiBvZiBwcm9wcy5vcHRpb25zIHwgZm9ybWx5U2VsZWN0T3B0aW9uczogZmllbGQgfCBhc3luYzsgbGV0IGkgPSBpbmRleFwiXG4gICAgICAgICAgW2lkXT1cImlkICsgJ18nICsgaVwiXG4gICAgICAgICAgW256RGlzYWJsZWRdPVwib3B0aW9uLmRpc2FibGVkID09PSB0cnVlXCJcbiAgICAgICAgICBbbnpWYWx1ZV09XCJvcHRpb24udmFsdWVcIlxuICAgICAgICAgIG56LXJhZGlvLWJ1dHRvblxuICAgICAgICA+XG4gICAgICAgICAge3sgb3B0aW9uLmxhYmVsIH19XG4gICAgICAgIDwvbGFiZWw+XG4gICAgICA8L25nLXRlbXBsYXRlPlxuICAgIDwvbnotcmFkaW8tZ3JvdXA+XG4gIGAsXG4gIGNoYW5nZURldGVjdGlvbjogQ2hhbmdlRGV0ZWN0aW9uU3RyYXRlZ3kuT25QdXNoXG59KVxuZXhwb3J0IGNsYXNzIEZvcm1seUZpZWxkUmFkaW8gZXh0ZW5kcyBGaWVsZFR5cGU8RmllbGRUeXBlQ29uZmlnPFJhZGlvUHJvcHM+PiB7XG4gIG92ZXJyaWRlIGRlZmF1bHRPcHRpb25zID0ge1xuICAgIHByb3BzOiB7XG4gICAgICBzaXplOiAnZGVmYXVsdCcgYXMgY29uc3QsXG4gICAgICBidXR0b25TdHlsZTogJ291dGxpbmUnIGFzIGNvbnN0XG4gICAgfVxuICB9O1xufVxuIl19
|
@@ -0,0 +1,5 @@
|
|
1
|
+
/**
|
2
|
+
* Generated bundle index. Do not edit.
|
3
|
+
*/
|
4
|
+
export * from './public_api';
|
5
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibmd4LWZvcm1seS16b3Jyby1hbnRkLXJlZi10ZW1wbGF0ZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3BhY2thZ2VzL2Zvcm1seWFudGQvcmVmLXRlbXBsYXRlL3NyYy9uZ3gtZm9ybWx5LXpvcnJvLWFudGQtcmVmLXRlbXBsYXRlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBRUgsY0FBYyxjQUFjLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIEdlbmVyYXRlZCBidW5kbGUgaW5kZXguIERvIG5vdCBlZGl0LlxuICovXG5cbmV4cG9ydCAqIGZyb20gJy4vcHVibGljX2FwaSc7XG4iXX0=
|
@@ -0,0 +1,3 @@
|
|
1
|
+
export { FormlyRefTemplateModule } from './ref-template.module';
|
2
|
+
export { FormlyFieldRefTemplate } from './ref-template.type';
|
3
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVibGljX2FwaS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3BhY2thZ2VzL2Zvcm1seWFudGQvcmVmLXRlbXBsYXRlL3NyYy9wdWJsaWNfYXBpLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSx1QkFBdUIsRUFBRSxNQUFNLHVCQUF1QixDQUFDO0FBQ2hFLE9BQU8sRUFBRSxzQkFBc0IsRUFBZ0MsTUFBTSxxQkFBcUIsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbImV4cG9ydCB7IEZvcm1seVJlZlRlbXBsYXRlTW9kdWxlIH0gZnJvbSAnLi9yZWYtdGVtcGxhdGUubW9kdWxlJztcbmV4cG9ydCB7IEZvcm1seUZpZWxkUmVmVGVtcGxhdGUsIEZvcm1seVJlZlRlbXBsYXRlRmllbGRDb25maWcgfSBmcm9tICcuL3JlZi10ZW1wbGF0ZS50eXBlJztcbiJdfQ==
|
@@ -0,0 +1,44 @@
|
|
1
|
+
import { NgModule } from '@angular/core';
|
2
|
+
import { CommonModule } from '@angular/common';
|
3
|
+
import { FormlyModule } from '@ngx-formly/core';
|
4
|
+
import { NzOutletModule } from 'ng-zorro-antd/core/outlet';
|
5
|
+
import { TrustedHtmlPipe } from '@pkt/ng.core';
|
6
|
+
import { FormlyFieldRefTemplate } from './ref-template.type';
|
7
|
+
import * as i0 from "@angular/core";
|
8
|
+
import * as i1 from "@ngx-formly/core";
|
9
|
+
export class FormlyRefTemplateModule {
|
10
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.5", ngImport: i0, type: FormlyRefTemplateModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
11
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.5", ngImport: i0, type: FormlyRefTemplateModule, declarations: [FormlyFieldRefTemplate], imports: [CommonModule,
|
12
|
+
NzOutletModule,
|
13
|
+
TrustedHtmlPipe, i1.FormlyModule] }); }
|
14
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.5", ngImport: i0, type: FormlyRefTemplateModule, imports: [CommonModule,
|
15
|
+
NzOutletModule,
|
16
|
+
FormlyModule.forChild({
|
17
|
+
types: [
|
18
|
+
{
|
19
|
+
name: 'ref-template',
|
20
|
+
component: FormlyFieldRefTemplate
|
21
|
+
}
|
22
|
+
]
|
23
|
+
})] }); }
|
24
|
+
}
|
25
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.5", ngImport: i0, type: FormlyRefTemplateModule, decorators: [{
|
26
|
+
type: NgModule,
|
27
|
+
args: [{
|
28
|
+
declarations: [FormlyFieldRefTemplate],
|
29
|
+
imports: [
|
30
|
+
CommonModule,
|
31
|
+
NzOutletModule,
|
32
|
+
TrustedHtmlPipe,
|
33
|
+
FormlyModule.forChild({
|
34
|
+
types: [
|
35
|
+
{
|
36
|
+
name: 'ref-template',
|
37
|
+
component: FormlyFieldRefTemplate
|
38
|
+
}
|
39
|
+
]
|
40
|
+
})
|
41
|
+
]
|
42
|
+
}]
|
43
|
+
}] });
|
44
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVmLXRlbXBsYXRlLm1vZHVsZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3BhY2thZ2VzL2Zvcm1seWFudGQvcmVmLXRlbXBsYXRlL3NyYy9yZWYtdGVtcGxhdGUubW9kdWxlLnRzIl0sIm5hbWVzIjpbXSwibWFw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250ZW50IjpbImltcG9ydCB7IE5nTW9kdWxlIH0gZnJvbSAnQGFuZ3VsYXIvY29yZSc7XG5pbXBvcnQgeyBDb21tb25Nb2R1bGUgfSBmcm9tICdAYW5ndWxhci9jb21tb24nO1xuaW1wb3J0IHsgRm9ybWx5TW9kdWxlIH0gZnJvbSAnQG5neC1mb3JtbHkvY29yZSc7XG5pbXBvcnQgeyBOek91dGxldE1vZHVsZSB9IGZyb20gJ25nLXpvcnJvLWFudGQvY29yZS9vdXRsZXQnO1xuXG5pbXBvcnQgeyBUcnVzdGVkSHRtbFBpcGUgfSBmcm9tICdAcGt0L25nLmNvcmUnO1xuaW1wb3J0IHsgRm9ybWx5RmllbGRSZWZUZW1wbGF0ZSB9IGZyb20gJy4vcmVmLXRlbXBsYXRlLnR5cGUnO1xuXG5ATmdNb2R1bGUoe1xuICBkZWNsYXJhdGlvbnM6IFtGb3JtbHlGaWVsZFJlZlRlbXBsYXRlXSxcbiAgaW1wb3J0czogW1xuICAgIENvbW1vbk1vZHVsZSxcbiAgICBOek91dGxldE1vZHVsZSxcbiAgICBUcnVzdGVkSHRtbFBpcGUsXG4gICAgRm9ybWx5TW9kdWxlLmZvckNoaWxkKHtcbiAgICAgIHR5cGVzOiBbXG4gICAgICAgIHtcbiAgICAgICAgICBuYW1lOiAncmVmLXRlbXBsYXRlJyxcbiAgICAgICAgICBjb21wb25lbnQ6IEZvcm1seUZpZWxkUmVmVGVtcGxhdGVcbiAgICAgICAgfVxuICAgICAgXVxuICAgIH0pXG4gIF1cbn0pXG5leHBvcnQgY2xhc3MgRm9ybWx5UmVmVGVtcGxhdGVNb2R1bGUge31cbiJdfQ==
|
@@ -0,0 +1,89 @@
|
|
1
|
+
import { Component, Optional, ChangeDetectionStrategy } from '@angular/core';
|
2
|
+
import { FieldType } from '@ngx-formly/core';
|
3
|
+
import { FormlyBoxTemplates, resolveTplName } from 'ngx-formly-zorro-antd/common';
|
4
|
+
import * as i0 from "@angular/core";
|
5
|
+
import * as i1 from "ngx-formly-zorro-antd/common";
|
6
|
+
import * as i2 from "ng-zorro-antd/core/outlet";
|
7
|
+
import * as i3 from "@pkt/ng.core";
|
8
|
+
/**
|
9
|
+
* 引用模板,支持HTML,TemplateRef对象,或者NamedTemplate
|
10
|
+
* @example
|
11
|
+
*
|
12
|
+
* 用法1: 使用NamedTemplate(推荐)
|
13
|
+
*
|
14
|
+
* html
|
15
|
+
* ```html
|
16
|
+
* <formly-form formly-box>
|
17
|
+
* <ng-template named="test"></ng-template>
|
18
|
+
* </formly-form>
|
19
|
+
* ```
|
20
|
+
*
|
21
|
+
* 配置
|
22
|
+
* ```js
|
23
|
+
* {
|
24
|
+
* type: 'ref-template',
|
25
|
+
* props: {
|
26
|
+
* refName: 'test'
|
27
|
+
* }
|
28
|
+
* }
|
29
|
+
* ```
|
30
|
+
*
|
31
|
+
* 用法2:TemplateRef对象
|
32
|
+
* ```html
|
33
|
+
* <ng-template #test2></ng-template>
|
34
|
+
* ```
|
35
|
+
*
|
36
|
+
* 配置
|
37
|
+
* @viewChild('test2') test2: TemplateRef<{}>;
|
38
|
+
*
|
39
|
+
* ```js
|
40
|
+
* {
|
41
|
+
* type: 'ref-template',
|
42
|
+
* props: {
|
43
|
+
* ref: this.test2
|
44
|
+
* }
|
45
|
+
* }
|
46
|
+
* ```
|
47
|
+
*
|
48
|
+
* 用法3: 使用html
|
49
|
+
*
|
50
|
+
* 配置
|
51
|
+
* ```js
|
52
|
+
* {
|
53
|
+
* type: 'ref-template',
|
54
|
+
* props: {
|
55
|
+
* ref: '<div>test text</div>'
|
56
|
+
* }
|
57
|
+
* }
|
58
|
+
* ```
|
59
|
+
*/
|
60
|
+
export class FormlyFieldRefTemplate extends FieldType {
|
61
|
+
constructor(fieldTemplates) {
|
62
|
+
super();
|
63
|
+
this.fieldTemplates = fieldTemplates;
|
64
|
+
}
|
65
|
+
get ref() {
|
66
|
+
return resolveTplName(this.props, this.fieldTemplates, 'ref');
|
67
|
+
}
|
68
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.5", ngImport: i0, type: FormlyFieldRefTemplate, deps: [{ token: i1.FormlyBoxTemplates, optional: true }], target: i0.ɵɵFactoryTarget.Component }); }
|
69
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.1.5", type: FormlyFieldRefTemplate, selector: "formly-ref-template", usesInheritance: true, ngImport: i0, template: `
|
70
|
+
<ng-container *nzStringTemplateOutlet="ref; context: { $implicit: field, props: props }">
|
71
|
+
<div [innerHTML]="$any(ref) | trustedHtml"></div>
|
72
|
+
</ng-container>
|
73
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i2.NzStringTemplateOutletDirective, selector: "[nzStringTemplateOutlet]", inputs: ["nzStringTemplateOutletContext", "nzStringTemplateOutlet"], exportAs: ["nzStringTemplateOutlet"] }, { kind: "pipe", type: i3.TrustedHtmlPipe, name: "trustedHtml" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
74
|
+
}
|
75
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.5", ngImport: i0, type: FormlyFieldRefTemplate, decorators: [{
|
76
|
+
type: Component,
|
77
|
+
args: [{
|
78
|
+
selector: 'formly-ref-template',
|
79
|
+
template: `
|
80
|
+
<ng-container *nzStringTemplateOutlet="ref; context: { $implicit: field, props: props }">
|
81
|
+
<div [innerHTML]="$any(ref) | trustedHtml"></div>
|
82
|
+
</ng-container>
|
83
|
+
`,
|
84
|
+
changeDetection: ChangeDetectionStrategy.OnPush
|
85
|
+
}]
|
86
|
+
}], ctorParameters: function () { return [{ type: i1.FormlyBoxTemplates, decorators: [{
|
87
|
+
type: Optional
|
88
|
+
}] }]; } });
|
89
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVmLXRlbXBsYXRlLnR5cGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8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dGVPdXRsZXQ9XCJyZWY7IGNvbnRleHQ6IHsgJGltcGxpY2l0OiBmaWVsZCwgcHJvcHM6IHByb3BzIH1cIj5cbiAgICAgIDxkaXYgW2lubmVySFRNTF09XCIkYW55KHJlZikgfCB0cnVzdGVkSHRtbFwiPjwvZGl2PlxuICAgIDwvbmctY29udGFpbmVyPlxuICBgLFxuICBjaGFuZ2VEZXRlY3Rpb246IENoYW5nZURldGVjdGlvblN0cmF0ZWd5Lk9uUHVzaFxufSlcbmV4cG9ydCBjbGFzcyBGb3JtbHlGaWVsZFJlZlRlbXBsYXRlIGV4dGVuZHMgRmllbGRUeXBlPEZpZWxkVHlwZUNvbmZpZzxSZWZUZW1wbGF0ZVByb3BzPj4ge1xuICBjb25zdHJ1Y3RvcihAT3B0aW9uYWwoKSBwdWJsaWMgZmllbGRUZW1wbGF0ZXM6IEZvcm1seUJveFRlbXBsYXRlcykge1xuICAgIHN1cGVyKCk7XG4gIH1cblxuICBnZXQgcmVmKCkge1xuICAgIHJldHVybiByZXNvbHZlVHBsTmFtZSh0aGlzLnByb3BzLCB0aGlzLmZpZWxkVGVtcGxhdGVzLCAncmVmJyk7XG4gIH1cbn1cbiJdfQ==
|
@@ -60,4 +60,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.5", ngImpor
|
|
60
60
|
}], ctorParameters: function () { return [{ type: i1.FormlyBoxTemplates, decorators: [{
|
61
61
|
type: Optional
|
62
62
|
}] }]; } });
|
63
|
-
//# sourceMappingURL=data:application/json;base64,
|
63
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic3BhY2UudHlwZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3BhY2thZ2VzL2Zvcm1seWFudGQvc3BhY2Uvc3JjL3NwYWNlLnR5cGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBT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4gICAgcHJvcHM6IHtcbiAgICAgIHNpemU6ICdzbWFsbCcgYXMgY29uc3QsXG4gICAgICBkaXJlY3Rpb246ICdob3Jpem9udGFsJyBhcyBjb25zdCxcbiAgICAgIHdyYXA6IGZhbHNlXG4gICAgfVxuICB9O1xuICBjb25zdHJ1Y3RvcihAT3B0aW9uYWwoKSBwdWJsaWMgZmllbGRUZW1wbGF0ZXM6IEZvcm1seUJveFRlbXBsYXRlcykge1xuICAgIHN1cGVyKCk7XG4gIH1cbiAgZ2V0IG56U3BsaXQoKSB7XG4gICAgcmV0dXJuIHJlc29sdmVUcGxOYW1lKHRoaXMucHJvcHMsIHRoaXMuZmllbGRUZW1wbGF0ZXMsICdzcGxpdCcpO1xuICB9XG59XG4iXX0=
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ngx-formly-zorro-antd-cascader.mjs","sources":["../../../../packages/formlyantd/cascader/src/cascader.type.ts","../../../../packages/formlyantd/cascader/src/cascader.module.ts","../../../../packages/formlyantd/cascader/src/ngx-formly-zorro-antd-cascader.ts"],"sourcesContent":["import { Component, TemplateRef, Type, ChangeDetectionStrategy, OnInit } from '@angular/core';\nimport { FieldType, FieldTypeConfig } from '@ngx-formly/core';\nimport { FormlyFieldProps } from 'ngx-formly-zorro-antd/form-field';\n\nimport type {\n NzCascaderOption,\n NzShowSearchOptions,\n NzCascaderExpandTrigger,\n NzCascaderSize\n} from 'ng-zorro-antd/cascader';\nimport type { NzSafeAny, NzStatus, NgStyleInterface } from 'ng-zorro-antd/core/types';\nimport type { NzFormlyFieldConfig } from 'ngx-formly-zorro-antd/common';\n\ninterface CascaderProps extends FormlyFieldProps {\n /**\n * 是否支持清除\n * @default true\n */\n allowClear?: boolean;\n\n /**\n * 是否自动聚焦,当存在输入框时\n * @default false\n */\n autoFocus?: boolean;\n\n /**\n * 浮层是否应带有背景板\n * @default false\n */\n backdrop?: boolean;\n\n /**\n * 点击父级菜单选项时,可通过该函数判断是否允许值的变化\n */\n changeOn?: (option: NzSafeAny, index: number) => boolean;\n\n /**\n * 当此项为 true 时,点选每级菜单选项值都会发生变化,具体见上面的演示\n * @default false\n */\n changeOnSelect?: boolean;\n\n /**\n * 自定义浮层列类名\n */\n columnClassName?: string;\n\n /**\n * 自定义次级菜单展开图标\n */\n expandIcon?: string | TemplateRef<void>;\n\n /**\n * 次级菜单的展开方式\n * @default 'click'\n */\n expandTrigger?: NzCascaderExpandTrigger;\n\n /**\n * 选项的显示值的属性名\n * @default 'label'\n */\n labelProperty: string;\n\n /**\n * 选择后展示的渲染模板\n */\n labelRender?: TemplateRef<NzSafeAny> | null;\n\n /**\n * 用于动态加载选项。如果提供了ngModel初始值,且未提供nzOptions值,则会立即触发动态加载。\n */\n loadData?: (option: NzSafeAny, index?: number) => PromiseLike<NzSafeAny>;\n\n /**\n * 自定义浮层类名\n */\n menuClassName?: string;\n\n /**\n * 自定义浮层样式\n */\n menuStyle?: NgStyleInterface | null;\n\n /**\n * 当下拉列表为空时显示的内容\n */\n notFoundContent?: string | TemplateRef<void>;\n\n /**\n * 选项的渲染模板\n */\n optionRender?: TemplateRef<{ $implicit: NzCascaderOption; index: number }> | null;\n\n /**\n * 是否显示箭头\n * @default true\n */\n showArrow?: boolean;\n\n /**\n * 显示输入框\n * @default true\n */\n showInput?: boolean;\n\n /**\n * 是否支持搜索,默认情况下对 label 进行全匹配搜索,不能和 [nzLoadData] 同时使用\n * @default false\n */\n showSearch?: boolean | NzShowSearchOptions;\n\n /**\n * 输入框大小\n * @default default\n */\n size?: NzCascaderSize;\n\n /**\n * 设置校验状态\n */\n status?: NzStatus;\n\n /**\n * 自定义的选择框后缀图标\n */\n suffixIcon?: string | TemplateRef<void>;\n\n /**\n * 选项的实际值的属性名\n * @default 'value'\n */\n valueProperty?: string;\n\n /**\n * 可选项数据源\n */\n cascaderOptions?: NzCascaderOption[] | null;\n\n /**\n * 清除值时触发\n */\n onClear?: (field: NzFormlyFieldConfig) => void;\n /**\n * 菜单浮层的显示/隐藏\n */\n visibleChange?: (field: NzFormlyFieldConfig, visible: boolean) => void;\n\n /**\n * 值发生变化时触发\n */\n selectionChange?: (field: NzFormlyFieldConfig, value: NzCascaderOption[]) => void;\n}\n\nexport interface FormlyCascaderFieldConfig extends NzFormlyFieldConfig<CascaderProps> {\n type: 'cascader' | Type<FormlyFieldCascader>;\n}\n\n@Component({\n selector: 'formly-field-cascader',\n template: `<nz-cascader\n #cascader\n [nzPlaceHolder]=\"props.placeholder ?? ''\"\n [formControl]=\"formControl\"\n [formlyAttributes]=\"field\"\n [ngClass]=\"props['className']!\"\n [nzAllowClear]=\"props['allowClear']!!\"\n [nzAutoFocus]=\"props['autoFocus']!!\"\n [nzBackdrop]=\"props['backdrop']!!\"\n [nzChangeOn]=\"props['changeOn']\"\n [nzChangeOnSelect]=\"props['changeOnSelect']!!\"\n [nzColumnClassName]=\"props['columnClassName']\"\n [nzExpandIcon]=\"props['expandIcon']!\"\n [nzExpandTrigger]=\"props['expandTrigger']!\"\n [nzLabelProperty]=\"props['labelProperty']\"\n [nzLabelRender]=\"props['labelRender'] ?? null\"\n [nzLoadData]=\"props['loadData']\"\n [nzMenuClassName]=\"props['menuClassName']\"\n [nzMenuStyle]=\"props['menuStyle'] ?? null\"\n [nzNotFoundContent]=\"props['notFoundContent']\"\n [nzOptionRender]=\"props['optionRender'] ?? null\"\n [nzOptions]=\"props['cascaderOptions'] ?? null\"\n [nzShowArrow]=\"props['showArrow']!!\"\n [nzShowInput]=\"props['showInput']!!\"\n [nzShowSearch]=\"props['showSearch']!!\"\n [nzSize]=\"props['size']!\"\n [nzStatus]=\"props['status'] ?? ''\"\n [nzSuffixIcon]=\"props['suffixIcon']!\"\n [nzValueProperty]=\"props['valueProperty']!\"\n (nzClear)=\"props['onClear'] && props['onClear'](field)\"\n (nzVisibleChange)=\"props['visibleChange'] && props['visibleChange'](field, $event)\"\n (nzSelectionChange)=\"props['selectionChange'] && props['selectionChange'](field, $event)\"\n ></nz-cascader>`,\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class FormlyFieldCascader\n extends FieldType<FieldTypeConfig<CascaderProps>>\n implements OnInit\n{\n override defaultOptions = {\n props: {\n placeholder: '请选择',\n allowClear: true,\n backdrop: false,\n changeOnSelect: false,\n expandTrigger: 'click' as const,\n labelProperty: 'label',\n showArrow: true,\n showInput: true,\n showSearch: false,\n size: 'default' as const,\n status: '' as const,\n valueProperty: 'value',\n cascaderOptions: []\n }\n };\n ngOnInit(): void {\n const options = this.props['cascaderOptions'];\n if (!options || options.length === 0) {\n this.props['cascaderOptions'] = this.props.options as NzSafeAny;\n }\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { FormlyModule } from '@ngx-formly/core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { FormlyNzFormFieldModule } from 'ngx-formly-zorro-antd/form-field';\n\nimport { NzCascaderModule } from 'ng-zorro-antd/cascader';\nimport { FormlyFieldCascader } from './cascader.type';\n\n@NgModule({\n declarations: [FormlyFieldCascader],\n imports: [\n CommonModule,\n ReactiveFormsModule,\n FormlyNzFormFieldModule,\n\n NzCascaderModule,\n\n FormlyModule.forChild({\n types: [\n {\n name: 'cascader',\n component: FormlyFieldCascader,\n wrappers: ['form-field']\n }\n ]\n })\n ]\n})\nexport class FormlyNzCascaderModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;AAoMM,MAAO,mBACX,SAAQ,SAAyC,CAAA;AAtCnD,IAAA,WAAA,GAAA;;AAyCW,QAAA,IAAA,CAAA,cAAc,GAAG;AACxB,YAAA,KAAK,EAAE;AACL,gBAAA,WAAW,EAAE,KAAK;AAClB,gBAAA,UAAU,EAAE,IAAI;AAChB,gBAAA,QAAQ,EAAE,KAAK;AACf,gBAAA,cAAc,EAAE,KAAK;AACrB,gBAAA,aAAa,EAAE,OAAgB;AAC/B,gBAAA,aAAa,EAAE,OAAO;AACtB,gBAAA,SAAS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AA;yBACF,CAAC;AACH,qBAAA;AACF,iBAAA,CAAA;;;AC5BD;;AAEG;;;;"}
|
1
|
+
{"version":3,"file":"ngx-formly-zorro-antd-cascader.mjs","sources":["../../../../packages/formlyantd/cascader/src/cascader.type.ts","../../../../packages/formlyantd/cascader/src/cascader.module.ts","../../../../packages/formlyantd/cascader/src/ngx-formly-zorro-antd-cascader.ts"],"sourcesContent":["import { Component, TemplateRef, Type, ChangeDetectionStrategy, OnInit } from '@angular/core';\nimport { FieldType, FieldTypeConfig } from '@ngx-formly/core';\nimport { FormlyFieldProps } from 'ngx-formly-zorro-antd/form-field';\n\nimport type {\n NzCascaderOption,\n NzShowSearchOptions,\n NzCascaderExpandTrigger,\n NzCascaderSize\n} from 'ng-zorro-antd/cascader';\nimport type { NzSafeAny, NzStatus, NgStyleInterface } from 'ng-zorro-antd/core/types';\nimport type { NzFormlyFieldConfig, FormlyAttributeEvent } from 'ngx-formly-zorro-antd/common';\n\ninterface CascaderProps extends FormlyFieldProps {\n /**\n * 是否支持清除\n * @default true\n */\n allowClear?: boolean;\n\n /**\n * 是否自动聚焦,当存在输入框时\n * @default false\n */\n autoFocus?: boolean;\n\n /**\n * 浮层是否应带有背景板\n * @default false\n */\n backdrop?: boolean;\n\n /**\n * 点击父级菜单选项时,可通过该函数判断是否允许值的变化\n */\n changeOn?: (option: NzSafeAny, index: number) => boolean;\n\n /**\n * 当此项为 true 时,点选每级菜单选项值都会发生变化,具体见上面的演示\n * @default false\n */\n changeOnSelect?: boolean;\n\n /**\n * 自定义浮层列类名\n */\n columnClassName?: string;\n\n /**\n * 自定义次级菜单展开图标\n */\n expandIcon?: string | TemplateRef<void>;\n\n /**\n * 次级菜单的展开方式\n * @default 'click'\n */\n expandTrigger?: NzCascaderExpandTrigger;\n\n /**\n * 选项的显示值的属性名\n * @default 'label'\n */\n labelProperty: string;\n\n /**\n * 选择后展示的渲染模板\n */\n labelRender?: TemplateRef<NzSafeAny> | null;\n\n /**\n * 用于动态加载选项。如果提供了ngModel初始值,且未提供nzOptions值,则会立即触发动态加载。\n */\n loadData?: (option: NzSafeAny, index?: number) => PromiseLike<NzSafeAny>;\n\n /**\n * 自定义浮层类名\n */\n menuClassName?: string;\n\n /**\n * 自定义浮层样式\n */\n menuStyle?: NgStyleInterface | null;\n\n /**\n * 当下拉列表为空时显示的内容\n */\n notFoundContent?: string | TemplateRef<void>;\n\n /**\n * 选项的渲染模板\n */\n optionRender?: TemplateRef<{ $implicit: NzCascaderOption; index: number }> | null;\n\n /**\n * 是否显示箭头\n * @default true\n */\n showArrow?: boolean;\n\n /**\n * 显示输入框\n * @default true\n */\n showInput?: boolean;\n\n /**\n * 是否支持搜索,默认情况下对 label 进行全匹配搜索,不能和 [nzLoadData] 同时使用\n * @default false\n */\n showSearch?: boolean | NzShowSearchOptions;\n\n /**\n * 输入框大小\n * @default default\n */\n size?: NzCascaderSize;\n\n /**\n * 设置校验状态\n */\n status?: NzStatus;\n\n /**\n * 自定义的选择框后缀图标\n */\n suffixIcon?: string | TemplateRef<void>;\n\n /**\n * 选项的实际值的属性名\n * @default 'value'\n */\n valueProperty?: string;\n\n /**\n * 可选项数据源\n */\n cascaderOptions?: NzCascaderOption[] | null;\n\n /**\n * 清除值时触发\n */\n onClear?: FormlyAttributeEvent;\n /**\n * 菜单浮层的显示/隐藏\n */\n visibleChange?: FormlyAttributeEvent<boolean>;\n\n /**\n * 值发生变化时触发\n */\n selectionChange?: FormlyAttributeEvent<NzCascaderOption[]>;\n}\n\nexport interface FormlyCascaderFieldConfig extends NzFormlyFieldConfig<CascaderProps> {\n type: 'cascader' | Type<FormlyFieldCascader>;\n}\n\n@Component({\n selector: 'formly-field-cascader',\n template: `<nz-cascader\n #cascader\n [nzPlaceHolder]=\"props.placeholder ?? ''\"\n [formControl]=\"formControl\"\n [formlyAttributes]=\"field\"\n [ngClass]=\"props['className']!\"\n [nzAllowClear]=\"props['allowClear']!!\"\n [nzAutoFocus]=\"props['autoFocus']!!\"\n [nzBackdrop]=\"props['backdrop']!!\"\n [nzChangeOn]=\"props['changeOn']\"\n [nzChangeOnSelect]=\"props['changeOnSelect']!!\"\n [nzColumnClassName]=\"props['columnClassName']\"\n [nzExpandIcon]=\"props['expandIcon']!\"\n [nzExpandTrigger]=\"props['expandTrigger']!\"\n [nzLabelProperty]=\"props['labelProperty']\"\n [nzLabelRender]=\"props['labelRender'] ?? null\"\n [nzLoadData]=\"props['loadData']\"\n [nzMenuClassName]=\"props['menuClassName']\"\n [nzMenuStyle]=\"props['menuStyle'] ?? null\"\n [nzNotFoundContent]=\"props['notFoundContent']\"\n [nzOptionRender]=\"props['optionRender'] ?? null\"\n [nzOptions]=\"props['cascaderOptions'] ?? null\"\n [nzShowArrow]=\"props['showArrow']!!\"\n [nzShowInput]=\"props['showInput']!!\"\n [nzShowSearch]=\"props['showSearch']!!\"\n [nzSize]=\"props['size']!\"\n [nzStatus]=\"props['status'] ?? ''\"\n [nzSuffixIcon]=\"props['suffixIcon']!\"\n [nzValueProperty]=\"props['valueProperty']!\"\n (nzClear)=\"props['onClear'] && props['onClear'](field)\"\n (nzVisibleChange)=\"props['visibleChange'] && props['visibleChange'](field, $event)\"\n (nzSelectionChange)=\"props['selectionChange'] && props['selectionChange'](field, $event)\"\n ></nz-cascader>`,\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class FormlyFieldCascader\n extends FieldType<FieldTypeConfig<CascaderProps>>\n implements OnInit\n{\n override defaultOptions = {\n props: {\n placeholder: '请选择',\n allowClear: true,\n backdrop: false,\n changeOnSelect: false,\n expandTrigger: 'click' as const,\n labelProperty: 'label',\n showArrow: true,\n showInput: true,\n showSearch: false,\n size: 'default' as const,\n status: '' as const,\n valueProperty: 'value',\n cascaderOptions: []\n }\n };\n\n ngOnInit(): void {\n const options = this.props['cascaderOptions'];\n if (!options || options.length === 0) {\n this.props['cascaderOptions'] = this.props.options as NzSafeAny;\n }\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { FormlyModule } from '@ngx-formly/core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { FormlyNzFormFieldModule } from 'ngx-formly-zorro-antd/form-field';\n\nimport { NzCascaderModule } from 'ng-zorro-antd/cascader';\nimport { FormlyFieldCascader } from './cascader.type';\n\n@NgModule({\n declarations: [FormlyFieldCascader],\n imports: [\n CommonModule,\n ReactiveFormsModule,\n FormlyNzFormFieldModule,\n\n NzCascaderModule,\n\n FormlyModule.forChild({\n types: [\n {\n name: 'cascader',\n component: FormlyFieldCascader,\n wrappers: ['form-field']\n }\n ]\n })\n ]\n})\nexport class FormlyNzCascaderModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;AAoMM,MAAO,mBACX,SAAQ,SAAyC,CAAA;AAtCnD,IAAA,WAAA,GAAA;;AAyCW,QAAA,IAAA,CAAA,cAAc,GAAG;AACxB,YAAA,KAAK,EAAE;AACL,gBAAA,WAAW,EAAE,KAAK;AAClB,gBAAA,UAAU,EAAE,IAAI;AAChB,gBAAA,QAAQ,EAAE,KAAK;AACf,gBAAA,cAAc,EAAE,KAAK;AACrB,gBAAA,aAAa,EAAE,OAAgB;AAC/B,gBAAA,aAAa,EAAE,OAAO;AACtB,gBAAA,SAAS,EAAE,IAAI;AACf,gBAAA,SAAS,EAAE,IAAI;AACf,gBAAA,UAAU,EAAE,KAAK;AACjB,gBAAA,IAAI,EAAE,SAAkB;AACxB,gBAAA,MAAM,EAAE,EAAW;AACnB,gBAAA,aAAa,EAAE,OAAO;AACtB,gBAAA,eAAe,EAAE,EAAE;AACpB,aAAA;SACF,CAAC;AAQH,KAAA;IANC,QAAQ,GAAA;QACN,MAAM,OAAO,GAAG,IAAI,CAAC,KAAK,CAAC,iBAAiB,CAAC,CAAC;QAC9C,IAAI,CAAC,OAAO,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC,EAAE;YACpC,IAAI,CAAC,KAAK,CAAC,iBAAiB,CAAC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AA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,sBAAsB,YAjB/B,YAAY;YACZ,mBAAmB;YACnB,uBAAuB;YAEvB,gBAAgB;YAEhB,YAAY,CAAC,QAAQ,CAAC;AACpB,gBAAA,KAAK,EAAE;AACL,oBAAA;AACE,wBAAA,IAAI,EAAE,UAAU;AAChB,wBAAA,SAAS,EAAE,mBAAmB;wBAC9B,QAAQ,EAAE,CAAC,YAAY,CAAC;AACzB,qBAAA;AACF,iBAAA;aACF,CAAC,CAAA,EAAA,CAAA,CAAA,EAAA;;2FAGO,sBAAsB,EAAA,UAAA,EAAA,CAAA;kBApBlC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,YAAY,EAAE,CAAC,mBAAmB,CAAC;AACnC,oBAAA,OAAO,EAAE;wBACP,YAAY;wBACZ,mBAAmB;wBACnB,uBAAuB;wBAEvB,gBAAgB;wBAEhB,YAAY,CAAC,QAAQ,CAAC;AACpB,4BAAA,KAAK,EAAE;AACL,gCAAA;AACE,oCAAA,IAAI,EAAE,UAAU;AAChB,oCAAA,SAAS,EAAE,mBAAmB;oCAC9B,QAAQ,EAAE,CAAC,YAAY,CAAC;AACzB,iCAAA;AACF,6BAAA;yBACF,CAAC;AACH,qBAAA;AACF,iBAAA,CAAA;;;AC5BD;;AAEG;;;;"}
|
@@ -31,7 +31,6 @@ class FormlyFieldRadio extends FieldType {
|
|
31
31
|
[nzName]="field.name ?? null"
|
32
32
|
[nzSize]="props['size']!"
|
33
33
|
[nzButtonStyle]="props['buttonStyle']!"
|
34
|
-
(ngModelChange)="props.change && props.change(field, $event)"
|
35
34
|
>
|
36
35
|
<ng-container *ngIf="props.type !== 'button'; else button">
|
37
36
|
<label
|
@@ -70,7 +69,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.5", ngImpor
|
|
70
69
|
[nzName]="field.name ?? null"
|
71
70
|
[nzSize]="props['size']!"
|
72
71
|
[nzButtonStyle]="props['buttonStyle']!"
|
73
|
-
(ngModelChange)="props.change && props.change(field, $event)"
|
74
72
|
>
|
75
73
|
<ng-container *ngIf="props.type !== 'button'; else button">
|
76
74
|
<label
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ngx-formly-zorro-antd-radio.mjs","sources":["../../../../packages/formlyantd/radio/src/radio.type.ts","../../../../packages/formlyantd/radio/src/radio.module.ts","../../../../packages/formlyantd/radio/src/ngx-formly-zorro-antd-radio.ts"],"sourcesContent":["import { Component, ChangeDetectionStrategy, Type } from '@angular/core';\nimport { FieldType, FieldTypeConfig } from '@ngx-formly/core';\nimport type { NzFormlyFieldConfig } from 'ngx-formly-zorro-antd/common';\nimport type { FormlyFieldProps } from 'ngx-formly-zorro-antd/form-field';\n\nimport type { FormlyFieldSelectProps } from '@ngx-formly/core/select';\nimport type { NzSizeLDSType } from 'ng-zorro-antd/core/types';\nimport type { NzRadioButtonStyle } from 'ng-zorro-antd/radio';\n\ninterface RadioProps extends FormlyFieldProps, FormlyFieldSelectProps {\n type?: 'button';\n\n /**\n * nz-radio-group 下所有 input[type=\"radio\"] 的 name 属性\n */\n name?: string | null;\n /**\n * 大小,只对按钮样式生效\n * @default default\n */\n size?: NzSizeLDSType;\n /**\n * RadioButton 的风格样式,目前有描边和填色两种风格\n * @default outline\n */\n buttonStyle?: NzRadioButtonStyle;\n}\n\nexport interface FormlyRadioFieldConfig extends NzFormlyFieldConfig<RadioProps> {\n type: 'radio' | Type<FormlyFieldRadio>;\n}\n\n@Component({\n selector: 'formly-field-radio',\n template: `\n <nz-radio-group\n [formControl]=\"formControl\"\n [formlyAttributes]=\"field\"\n [nzName]=\"field.name ?? null\"\n [nzSize]=\"props['size']!\"\n [nzButtonStyle]=\"props['buttonStyle']!\"\n
|
1
|
+
{"version":3,"file":"ngx-formly-zorro-antd-radio.mjs","sources":["../../../../packages/formlyantd/radio/src/radio.type.ts","../../../../packages/formlyantd/radio/src/radio.module.ts","../../../../packages/formlyantd/radio/src/ngx-formly-zorro-antd-radio.ts"],"sourcesContent":["import { Component, ChangeDetectionStrategy, Type } from '@angular/core';\nimport { FieldType, FieldTypeConfig } from '@ngx-formly/core';\nimport type { NzFormlyFieldConfig } from 'ngx-formly-zorro-antd/common';\nimport type { FormlyFieldProps } from 'ngx-formly-zorro-antd/form-field';\n\nimport type { FormlyFieldSelectProps } from '@ngx-formly/core/select';\nimport type { NzSizeLDSType } from 'ng-zorro-antd/core/types';\nimport type { NzRadioButtonStyle } from 'ng-zorro-antd/radio';\n\ninterface RadioProps extends FormlyFieldProps, FormlyFieldSelectProps {\n type?: 'button';\n\n /**\n * nz-radio-group 下所有 input[type=\"radio\"] 的 name 属性\n */\n name?: string | null;\n /**\n * 大小,只对按钮样式生效\n * @default default\n */\n size?: NzSizeLDSType;\n /**\n * RadioButton 的风格样式,目前有描边和填色两种风格\n * @default outline\n */\n buttonStyle?: NzRadioButtonStyle;\n}\n\nexport interface FormlyRadioFieldConfig extends NzFormlyFieldConfig<RadioProps> {\n type: 'radio' | Type<FormlyFieldRadio>;\n}\n\n@Component({\n selector: 'formly-field-radio',\n template: `\n <nz-radio-group\n [formControl]=\"formControl\"\n [formlyAttributes]=\"field\"\n [nzName]=\"field.name ?? null\"\n [nzSize]=\"props['size']!\"\n [nzButtonStyle]=\"props['buttonStyle']!\"\n >\n <ng-container *ngIf=\"props.type !== 'button'; else button\">\n <label\n *ngFor=\"let option of props.options | formlySelectOptions: field | async; let i = index\"\n [id]=\"id + '_' + i\"\n [nzDisabled]=\"option.disabled === true\"\n [nzValue]=\"option.value\"\n nz-radio\n >\n {{ option.label }}\n </label>\n </ng-container>\n\n <ng-template #button>\n <label\n *ngFor=\"let option of props.options | formlySelectOptions: field | async; let i = index\"\n [id]=\"id + '_' + i\"\n [nzDisabled]=\"option.disabled === true\"\n [nzValue]=\"option.value\"\n nz-radio-button\n >\n {{ option.label }}\n </label>\n </ng-template>\n </nz-radio-group>\n `,\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class FormlyFieldRadio extends FieldType<FieldTypeConfig<RadioProps>> {\n override defaultOptions = {\n props: {\n size: 'default' as const,\n buttonStyle: 'outline' as const\n }\n };\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { FormlyModule } from '@ngx-formly/core';\nimport { FormlySelectModule } from '@ngx-formly/core/select';\n\nimport { FormlyNzFormFieldModule } from 'ngx-formly-zorro-antd/form-field';\nimport { FormlyFieldRadio } from './radio.type';\n\nimport { NzFormModule } from 'ng-zorro-antd/form';\nimport { NzRadioModule } from 'ng-zorro-antd/radio';\n\n@NgModule({\n declarations: [FormlyFieldRadio],\n imports: [\n CommonModule,\n ReactiveFormsModule,\n FormlyNzFormFieldModule,\n FormlySelectModule,\n NzFormModule,\n\n NzRadioModule,\n FormlyModule.forChild({\n types: [\n {\n name: 'radio',\n component: FormlyFieldRadio,\n wrappers: ['form-field']\n }\n ]\n })\n ]\n})\nexport class FormlyNzRadioModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;;;;AAqEM,MAAO,gBAAiB,SAAQ,SAAsC,CAAA;AArC5E,IAAA,WAAA,GAAA;;AAsCW,QAAA,IAAA,CAAA,cAAc,GAAG;AACxB,YAAA,KAAK,EAAE;AACL,gBAAA,IAAI,EAAE,SAAkB;AACxB,gBAAA,WAAW,EAAE,SAAkB;AAChC,aAAA;SACF,CAAC;AACH,KAAA;8GAPY,gBAAgB,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA,EAAA;AAAhB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,gB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EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,mBAAmB,YAlB5B,YAAY;YACZ,mBAAmB;YACnB,uBAAuB;YACvB,kBAAkB;YAClB,YAAY;YAEZ,aAAa;YACb,YAAY,CAAC,QAAQ,CAAC;AACpB,gBAAA,KAAK,EAAE;AACL,oBAAA;AACE,wBAAA,IAAI,EAAE,OAAO;AACb,wBAAA,SAAS,EAAE,gBAAgB;wBAC3B,QAAQ,EAAE,CAAC,YAAY,CAAC;AACzB,qBAAA;AACF,iBAAA;aACF,CAAC,CAAA,EAAA,CAAA,CAAA,EAAA;;2FAGO,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBArB/B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,YAAY,EAAE,CAAC,gBAAgB,CAAC;AAChC,oBAAA,OAAO,EAAE;wBACP,YAAY;wBACZ,mBAAmB;wBACnB,uBAAuB;wBACvB,kBAAkB;wBAClB,YAAY;wBAEZ,aAAa;wBACb,YAAY,CAAC,QAAQ,CAAC;AACpB,4BAAA,KAAK,EAAE;AACL,gCAAA;AACE,oCAAA,IAAI,EAAE,OAAO;AACb,oCAAA,SAAS,EAAE,gBAAgB;oCAC3B,QAAQ,EAAE,CAAC,YAAY,CAAC;AACzB,iCAAA;AACF,6BAAA;yBACF,CAAC;AACH,qBAAA;AACF,iBAAA,CAAA;;;AChCD;;AAEG;;;;"}
|
@@ -0,0 +1,136 @@
|
|
1
|
+
import * as i0 from '@angular/core';
|
2
|
+
import { Component, ChangeDetectionStrategy, Optional, NgModule } from '@angular/core';
|
3
|
+
import { CommonModule } from '@angular/common';
|
4
|
+
import * as i1$1 from '@ngx-formly/core';
|
5
|
+
import { FieldType, FormlyModule } from '@ngx-formly/core';
|
6
|
+
import * as i2 from 'ng-zorro-antd/core/outlet';
|
7
|
+
import { NzOutletModule } from 'ng-zorro-antd/core/outlet';
|
8
|
+
import * as i3 from '@pkt/ng.core';
|
9
|
+
import { TrustedHtmlPipe } from '@pkt/ng.core';
|
10
|
+
import * as i1 from 'ngx-formly-zorro-antd/common';
|
11
|
+
import { resolveTplName } from 'ngx-formly-zorro-antd/common';
|
12
|
+
|
13
|
+
/**
|
14
|
+
* 引用模板,支持HTML,TemplateRef对象,或者NamedTemplate
|
15
|
+
* @example
|
16
|
+
*
|
17
|
+
* 用法1: 使用NamedTemplate(推荐)
|
18
|
+
*
|
19
|
+
* html
|
20
|
+
* ```html
|
21
|
+
* <formly-form formly-box>
|
22
|
+
* <ng-template named="test"></ng-template>
|
23
|
+
* </formly-form>
|
24
|
+
* ```
|
25
|
+
*
|
26
|
+
* 配置
|
27
|
+
* ```js
|
28
|
+
* {
|
29
|
+
* type: 'ref-template',
|
30
|
+
* props: {
|
31
|
+
* refName: 'test'
|
32
|
+
* }
|
33
|
+
* }
|
34
|
+
* ```
|
35
|
+
*
|
36
|
+
* 用法2:TemplateRef对象
|
37
|
+
* ```html
|
38
|
+
* <ng-template #test2></ng-template>
|
39
|
+
* ```
|
40
|
+
*
|
41
|
+
* 配置
|
42
|
+
* @viewChild('test2') test2: TemplateRef<{}>;
|
43
|
+
*
|
44
|
+
* ```js
|
45
|
+
* {
|
46
|
+
* type: 'ref-template',
|
47
|
+
* props: {
|
48
|
+
* ref: this.test2
|
49
|
+
* }
|
50
|
+
* }
|
51
|
+
* ```
|
52
|
+
*
|
53
|
+
* 用法3: 使用html
|
54
|
+
*
|
55
|
+
* 配置
|
56
|
+
* ```js
|
57
|
+
* {
|
58
|
+
* type: 'ref-template',
|
59
|
+
* props: {
|
60
|
+
* ref: '<div>test text</div>'
|
61
|
+
* }
|
62
|
+
* }
|
63
|
+
* ```
|
64
|
+
*/
|
65
|
+
class FormlyFieldRefTemplate extends FieldType {
|
66
|
+
constructor(fieldTemplates) {
|
67
|
+
super();
|
68
|
+
this.fieldTemplates = fieldTemplates;
|
69
|
+
}
|
70
|
+
get ref() {
|
71
|
+
return resolveTplName(this.props, this.fieldTemplates, 'ref');
|
72
|
+
}
|
73
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.5", ngImport: i0, type: FormlyFieldRefTemplate, deps: [{ token: i1.FormlyBoxTemplates, optional: true }], target: i0.ɵɵFactoryTarget.Component }); }
|
74
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.1.5", type: FormlyFieldRefTemplate, selector: "formly-ref-template", usesInheritance: true, ngImport: i0, template: `
|
75
|
+
<ng-container *nzStringTemplateOutlet="ref; context: { $implicit: field, props: props }">
|
76
|
+
<div [innerHTML]="$any(ref) | trustedHtml"></div>
|
77
|
+
</ng-container>
|
78
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i2.NzStringTemplateOutletDirective, selector: "[nzStringTemplateOutlet]", inputs: ["nzStringTemplateOutletContext", "nzStringTemplateOutlet"], exportAs: ["nzStringTemplateOutlet"] }, { kind: "pipe", type: i3.TrustedHtmlPipe, name: "trustedHtml" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
79
|
+
}
|
80
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.5", ngImport: i0, type: FormlyFieldRefTemplate, decorators: [{
|
81
|
+
type: Component,
|
82
|
+
args: [{
|
83
|
+
selector: 'formly-ref-template',
|
84
|
+
template: `
|
85
|
+
<ng-container *nzStringTemplateOutlet="ref; context: { $implicit: field, props: props }">
|
86
|
+
<div [innerHTML]="$any(ref) | trustedHtml"></div>
|
87
|
+
</ng-container>
|
88
|
+
`,
|
89
|
+
changeDetection: ChangeDetectionStrategy.OnPush
|
90
|
+
}]
|
91
|
+
}], ctorParameters: function () { return [{ type: i1.FormlyBoxTemplates, decorators: [{
|
92
|
+
type: Optional
|
93
|
+
}] }]; } });
|
94
|
+
|
95
|
+
class FormlyRefTemplateModule {
|
96
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.5", ngImport: i0, type: FormlyRefTemplateModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
97
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.5", ngImport: i0, type: FormlyRefTemplateModule, declarations: [FormlyFieldRefTemplate], imports: [CommonModule,
|
98
|
+
NzOutletModule,
|
99
|
+
TrustedHtmlPipe, i1$1.FormlyModule] }); }
|
100
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.5", ngImport: i0, type: FormlyRefTemplateModule, imports: [CommonModule,
|
101
|
+
NzOutletModule,
|
102
|
+
FormlyModule.forChild({
|
103
|
+
types: [
|
104
|
+
{
|
105
|
+
name: 'ref-template',
|
106
|
+
component: FormlyFieldRefTemplate
|
107
|
+
}
|
108
|
+
]
|
109
|
+
})] }); }
|
110
|
+
}
|
111
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.5", ngImport: i0, type: FormlyRefTemplateModule, decorators: [{
|
112
|
+
type: NgModule,
|
113
|
+
args: [{
|
114
|
+
declarations: [FormlyFieldRefTemplate],
|
115
|
+
imports: [
|
116
|
+
CommonModule,
|
117
|
+
NzOutletModule,
|
118
|
+
TrustedHtmlPipe,
|
119
|
+
FormlyModule.forChild({
|
120
|
+
types: [
|
121
|
+
{
|
122
|
+
name: 'ref-template',
|
123
|
+
component: FormlyFieldRefTemplate
|
124
|
+
}
|
125
|
+
]
|
126
|
+
})
|
127
|
+
]
|
128
|
+
}]
|
129
|
+
}] });
|
130
|
+
|
131
|
+
/**
|
132
|
+
* Generated bundle index. Do not edit.
|
133
|
+
*/
|
134
|
+
|
135
|
+
export { FormlyFieldRefTemplate, FormlyRefTemplateModule };
|
136
|
+
//# sourceMappingURL=ngx-formly-zorro-antd-ref-template.mjs.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"ngx-formly-zorro-antd-ref-template.mjs","sources":["../../../../packages/formlyantd/ref-template/src/ref-template.type.ts","../../../../packages/formlyantd/ref-template/src/ref-template.module.ts","../../../../packages/formlyantd/ref-template/src/ngx-formly-zorro-antd-ref-template.ts"],"sourcesContent":["import { Component, TemplateRef, Optional, Type, ChangeDetectionStrategy } from '@angular/core';\nimport { FieldType, FieldTypeConfig } from '@ngx-formly/core';\nimport type { FormlyFieldProps } from 'ngx-formly-zorro-antd/form-field';\nimport type { NzFormlyFieldConfig } from 'ngx-formly-zorro-antd/common';\nimport { FormlyBoxTemplates, resolveTplName } from 'ngx-formly-zorro-antd/common';\n\ninterface RefTemplateProps extends FormlyFieldProps {\n ref?: string | TemplateRef<{ $implicit: FormlyRefTemplateFieldConfig; props: RefTemplateProps }>;\n refName?: string;\n}\n\n/**\n * RefTemplate 配置\n */\nexport interface FormlyRefTemplateFieldConfig extends NzFormlyFieldConfig<RefTemplateProps> {\n type: 'ref-template' | Type<FormlyFieldRefTemplate>;\n}\n\n/**\n * 引用模板,支持HTML,TemplateRef对象,或者NamedTemplate\n * @example\n *\n * 用法1: 使用NamedTemplate(推荐)\n *\n * html\n * ```html\n * <formly-form formly-box>\n * <ng-template named=\"test\"></ng-template>\n * </formly-form>\n * ```\n *\n * 配置\n * ```js\n * {\n * type: 'ref-template',\n * props: {\n * refName: 'test'\n * }\n * }\n * ```\n *\n * 用法2:TemplateRef对象\n * ```html\n * <ng-template #test2></ng-template>\n * ```\n *\n * 配置\n * @viewChild('test2') test2: TemplateRef<{}>;\n *\n * ```js\n * {\n * type: 'ref-template',\n * props: {\n * ref: this.test2\n * }\n * }\n * ```\n *\n * 用法3: 使用html\n *\n * 配置\n * ```js\n * {\n * type: 'ref-template',\n * props: {\n * ref: '<div>test text</div>'\n * }\n * }\n * ```\n */\n@Component({\n selector: 'formly-ref-template',\n template: `\n <ng-container *nzStringTemplateOutlet=\"ref; context: { $implicit: field, props: props }\">\n <div [innerHTML]=\"$any(ref) | trustedHtml\"></div>\n </ng-container>\n `,\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class FormlyFieldRefTemplate extends FieldType<FieldTypeConfig<RefTemplateProps>> {\n constructor(@Optional() public fieldTemplates: FormlyBoxTemplates) {\n super();\n }\n\n get ref() {\n return resolveTplName(this.props, this.fieldTemplates, 'ref');\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { FormlyModule } from '@ngx-formly/core';\nimport { NzOutletModule } from 'ng-zorro-antd/core/outlet';\n\nimport { TrustedHtmlPipe } from '@pkt/ng.core';\nimport { FormlyFieldRefTemplate } from './ref-template.type';\n\n@NgModule({\n declarations: [FormlyFieldRefTemplate],\n imports: [\n CommonModule,\n NzOutletModule,\n TrustedHtmlPipe,\n FormlyModule.forChild({\n types: [\n {\n name: 'ref-template',\n component: FormlyFieldRefTemplate\n }\n ]\n })\n ]\n})\nexport class FormlyRefTemplateModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;AAkBA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAmDG;AAUG,MAAO,sBAAuB,SAAQ,SAA4C,CAAA;AACtF,IAAA,WAAA,CAA+B,cAAkC,EAAA;AAC/D,QAAA,KAAK,EAAE,CAAC;QADqB,IAAc,CAAA,cAAA,GAAd,cAAc,CAAoB;KAEhE;AAED,IAAA,IAAI,GAAG,GAAA;AACL,QAAA,OAAO,cAAc,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,CAAC,cAAc,EAAE,KAAK,CAAC,CAAC;KAC/D;8GAPU,sBAAsB,EAAA,IAAA,EAAA,CAAA,EAAA,KAAA,EAAA,EAAA,CAAA,kBAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA,EAAA;AAAtB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,C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,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,uBAAuB,YAbhC,YAAY;YACZ,cAAc;YAEd,YAAY,CAAC,QAAQ,CAAC;AACpB,gBAAA,KAAK,EAAE;AACL,oBAAA;AACE,wBAAA,IAAI,EAAE,cAAc;AACpB,wBAAA,SAAS,EAAE,sBAAsB;AAClC,qBAAA;AACF,iBAAA;aACF,CAAC,CAAA,EAAA,CAAA,CAAA,EAAA;;2FAGO,uBAAuB,EAAA,UAAA,EAAA,CAAA;kBAhBnC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,YAAY,EAAE,CAAC,sBAAsB,CAAC;AACtC,oBAAA,OAAO,EAAE;wBACP,YAAY;wBACZ,cAAc;wBACd,eAAe;wBACf,YAAY,CAAC,QAAQ,CAAC;AACpB,4BAAA,KAAK,EAAE;AACL,gCAAA;AACE,oCAAA,IAAI,EAAE,cAAc;AACpB,oCAAA,SAAS,EAAE,sBAAsB;AAClC,iCAAA;AACF,6BAAA;yBACF,CAAC;AACH,qBAAA;AACF,iBAAA,CAAA;;;ACvBD;;AAEG;;;;"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ngx-formly-zorro-antd-space.mjs","sources":["../../../../packages/formlyantd/space/src/space.type.ts","../../../../packages/formlyantd/space/src/space.module.ts","../../../../packages/formlyantd/space/src/ngx-formly-zorro-antd-space.ts"],"sourcesContent":["import { Component, ChangeDetectionStrategy, Type, TemplateRef, Optional } from '@angular/core';\nimport { FieldType, FieldTypeConfig } from '@ngx-formly/core';\nimport type { FormlyFieldProps } from 'ngx-formly-zorro-antd/form-field';\nimport { FormlyBoxTemplates, resolveTplName } from 'ngx-formly-zorro-antd/common';\nimport type { NzFormlyFieldConfig } from 'ngx-formly-zorro-antd/common';\nimport type { NzSpaceDirection, NzSpaceSize, NzSpaceAlign } from 'ng-zorro-antd/space';\n\ninterface SpaceProps extends FormlyFieldProps {\n type?: 'space';\n\n /**\n * 间距大小\n */\n size?: NzSpaceSize;\n /**\n * 间距方向\n */\n direction?: NzSpaceDirection;\n /**\n * 对齐方式\n */\n align?: NzSpaceAlign;\n /**\n * 是否自动换行,仅在 horizontal 时有效\n */\n wrap?: boolean;\n /**\n * 设置分隔符\n */\n split?: TemplateRef<{\n $implicit: number;\n }> | null;\n
|
1
|
+
{"version":3,"file":"ngx-formly-zorro-antd-space.mjs","sources":["../../../../packages/formlyantd/space/src/space.type.ts","../../../../packages/formlyantd/space/src/space.module.ts","../../../../packages/formlyantd/space/src/ngx-formly-zorro-antd-space.ts"],"sourcesContent":["import { Component, ChangeDetectionStrategy, Type, TemplateRef, Optional } from '@angular/core';\nimport { FieldType, FieldTypeConfig } from '@ngx-formly/core';\nimport type { FormlyFieldProps } from 'ngx-formly-zorro-antd/form-field';\nimport { FormlyBoxTemplates, resolveTplName } from 'ngx-formly-zorro-antd/common';\nimport type { NzFormlyFieldConfig } from 'ngx-formly-zorro-antd/common';\nimport type { NzSpaceDirection, NzSpaceSize, NzSpaceAlign } from 'ng-zorro-antd/space';\n\ninterface SpaceProps extends FormlyFieldProps {\n type?: 'space';\n\n /**\n * 间距大小\n */\n size?: NzSpaceSize;\n /**\n * 间距方向\n */\n direction?: NzSpaceDirection;\n /**\n * 对齐方式\n */\n align?: NzSpaceAlign;\n /**\n * 是否自动换行,仅在 horizontal 时有效\n */\n wrap?: boolean;\n /**\n * 设置分隔符\n */\n split?: TemplateRef<{\n $implicit: number;\n }> | null;\n splitName?: string;\n}\n\nexport interface FormlySpaceFieldConfig extends NzFormlyFieldConfig<SpaceProps> {\n type: 'space' | Type<FormlyFieldSpace>;\n}\n\n@Component({\n selector: 'formly-field-space',\n template: `\n <nz-space\n [nzSize]=\"props.size!\"\n [nzAlign]=\"props.align\"\n [nzDirection]=\"props.direction!\"\n [nzSplit]=\"nzSplit ?? null\"\n [nzWrap]=\"props.wrap\"\n [formlyAttributes]=\"field\"\n >\n <ng-container *ngFor=\"let item of field.fieldGroup\">\n <formly-field *nzSpaceItem [field]=\"item\"></formly-field>\n </ng-container>\n </nz-space>\n `,\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class FormlyFieldSpace extends FieldType<FieldTypeConfig<SpaceProps>> {\n override defaultOptions = {\n props: {\n size: 'small' as const,\n direction: 'horizontal' as const,\n wrap: false\n }\n };\n constructor(@Optional() public fieldTemplates: FormlyBoxTemplates) {\n super();\n }\n get nzSplit() {\n return resolveTplName(this.props, this.fieldTemplates, 'split');\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { FormlyModule } from '@ngx-formly/core';\nimport { FormlyCommonModule } from 'ngx-formly-zorro-antd/common';\nimport { FormlyFieldSpace } from './space.type';\n\nimport { NzSpaceModule } from 'ng-zorro-antd/space';\n\n@NgModule({\n declarations: [FormlyFieldSpace],\n imports: [\n CommonModule,\n FormlyCommonModule,\n NzSpaceModule,\n FormlyModule.forChild({\n types: [\n {\n name: 'space',\n component: FormlyFieldSpace\n }\n ]\n })\n ]\n})\nexport class FormlyNzSpaceModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i1"],"mappings":";;;;;;;;;;;AAyDM,MAAO,gBAAiB,SAAQ,SAAsC,CAAA;AAQ1E,IAAA,WAAA,CAA+B,cAAkC,EAAA;AAC/D,QAAA,KAAK,EAAE,CAAC;QADqB,IAAc,CAAA,cAAA,GAAd,cAAc,CAAoB;AAPxD,QAAA,IAAA,CAAA,cAAc,GAAG;AACxB,YAAA,KAAK,EAAE;AACL,gBAAA,IAAI,EAAE,OAAgB;AACtB,gBAAA,SAAS,EAAE,YAAqB;AAChC,gBAAA,IAAI,EAAE,KAAK;AACZ,aAAA;SACF,CAAC;KAGD;AACD,IAAA,IAAI,OAAO,GAAA;AACT,QAAA,OAAO,cAAc,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,CAAC,cAAc,EAAE,OAAO,CAAC,CAAC;KACjE;8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Y;wBACZ,kBAAkB;wBAClB,aAAa;wBACb,YAAY,CAAC,QAAQ,CAAC;AACpB,4BAAA,KAAK,EAAE;AACL,gCAAA;AACE,oCAAA,IAAI,EAAE,OAAO;AACb,oCAAA,SAAS,EAAE,gBAAgB;AAC5B,iCAAA;AACF,6BAAA;yBACF,CAAC;AACH,qBAAA;AACF,iBAAA,CAAA;;;ACvBD;;AAEG;;;;"}
|
@@ -24,6 +24,7 @@ import { FormlyNzCardWrapperModule } from 'ngx-formly-zorro-antd/card-wrapper';
|
|
24
24
|
import { FormlyNzButtonModule } from 'ngx-formly-zorro-antd/button';
|
25
25
|
import { FormlyNzGridModule } from 'ngx-formly-zorro-antd/grid';
|
26
26
|
import { FormlyNzSpaceModule } from 'ngx-formly-zorro-antd/space';
|
27
|
+
import { FormlyRefTemplateModule } from 'ngx-formly-zorro-antd/ref-template';
|
27
28
|
|
28
29
|
class FormlyNgAntdModule {
|
29
30
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.5", ngImport: i0, type: FormlyNgAntdModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
@@ -50,7 +51,8 @@ class FormlyNgAntdModule {
|
|
50
51
|
FormlyNzCardWrapperModule,
|
51
52
|
FormlyNzButtonModule,
|
52
53
|
FormlyNzGridModule,
|
53
|
-
FormlyNzSpaceModule
|
54
|
+
FormlyNzSpaceModule,
|
55
|
+
FormlyRefTemplateModule] }); }
|
54
56
|
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.5", ngImport: i0, type: FormlyNgAntdModule, imports: [FormlyNzFormFieldModule,
|
55
57
|
FormlyCommonModule,
|
56
58
|
FormlyNzInputModule,
|
@@ -74,7 +76,8 @@ class FormlyNgAntdModule {
|
|
74
76
|
FormlyNzCardWrapperModule,
|
75
77
|
FormlyNzButtonModule,
|
76
78
|
FormlyNzGridModule,
|
77
|
-
FormlyNzSpaceModule
|
79
|
+
FormlyNzSpaceModule,
|
80
|
+
FormlyRefTemplateModule] }); }
|
78
81
|
}
|
79
82
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.5", ngImport: i0, type: FormlyNgAntdModule, decorators: [{
|
80
83
|
type: NgModule,
|
@@ -103,7 +106,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.5", ngImpor
|
|
103
106
|
FormlyNzCardWrapperModule,
|
104
107
|
FormlyNzButtonModule,
|
105
108
|
FormlyNzGridModule,
|
106
|
-
FormlyNzSpaceModule
|
109
|
+
FormlyNzSpaceModule,
|
110
|
+
FormlyRefTemplateModule
|
107
111
|
]
|
108
112
|
}]
|
109
113
|
}] });
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ngx-formly-zorro-antd.mjs","sources":["../../../../packages/formlyantd/src/lib/ui-ng-zorro-antd.module.ts","../../../../packages/formlyantd/src/ngx-formly-zorro-antd.ts"],"sourcesContent":["import { NgModule } from '@angular/core';\n\nimport { FormlyNzFormFieldModule } from 'ngx-formly-zorro-antd/form-field';\nimport { FormlyCommonModule } from 'ngx-formly-zorro-antd/common';\nimport { FormlyNzInputModule } from 'ngx-formly-zorro-antd/input';\nimport { FormlyNzInputNumberModule } from 'ngx-formly-zorro-antd/input-number';\nimport { FormlyNzInputGroupModule } from 'ngx-formly-zorro-antd/input-group';\nimport { FormlyNzTextareaModule } from 'ngx-formly-zorro-antd/textarea';\nimport { FormlyNzRadioModule } from 'ngx-formly-zorro-antd/radio';\nimport { FormlyNzCheckboxModule } from 'ngx-formly-zorro-antd/checkbox';\nimport { FormlyNzSelectModule } from 'ngx-formly-zorro-antd/select';\nimport { FormlyNzSwitchModule } from 'ngx-formly-zorro-antd/switch';\nimport { FormlyNzCascaderModule } from 'ngx-formly-zorro-antd/cascader';\nimport { FormlyNzDatepickerModule } from 'ngx-formly-zorro-antd/datepicker';\nimport { FormlyNzRateModule } from 'ngx-formly-zorro-antd/rate';\nimport { FormlyNzSliderModule } from 'ngx-formly-zorro-antd/slider';\nimport { FormlyNzTimepickerModule } from 'ngx-formly-zorro-antd/timepicker';\nimport { FormlyNzTransferModule } from 'ngx-formly-zorro-antd/transfer';\nimport { FormlyNzTreeSelectModule } from 'ngx-formly-zorro-antd/tree-select';\nimport { FormlyNzUploadModule } from 'ngx-formly-zorro-antd/upload';\nimport { FormlyNzTabsModule } from 'ngx-formly-zorro-antd/tabs';\nimport { FormlyNzCardModule } from 'ngx-formly-zorro-antd/card';\nimport { FormlyNzCardWrapperModule } from 'ngx-formly-zorro-antd/card-wrapper';\nimport { FormlyNzButtonModule } from 'ngx-formly-zorro-antd/button';\nimport { FormlyNzGridModule } from 'ngx-formly-zorro-antd/grid';\nimport { FormlyNzSpaceModule } from 'ngx-formly-zorro-antd/space';\n\n@NgModule({\n imports: [\n FormlyNzFormFieldModule,\n FormlyCommonModule,\n FormlyNzInputModule,\n FormlyNzInputNumberModule,\n FormlyNzInputGroupModule,\n FormlyNzTextareaModule,\n FormlyNzRadioModule,\n FormlyNzCheckboxModule,\n FormlyNzSelectModule,\n FormlyNzSwitchModule,\n FormlyNzCascaderModule,\n FormlyNzDatepickerModule,\n FormlyNzRateModule,\n FormlyNzSliderModule,\n FormlyNzTimepickerModule,\n FormlyNzTransferModule,\n FormlyNzTreeSelectModule,\n FormlyNzUploadModule,\n FormlyNzTabsModule,\n FormlyNzCardModule,\n FormlyNzCardWrapperModule,\n FormlyNzButtonModule,\n FormlyNzGridModule,\n FormlyNzSpaceModule\n ]\n})\nexport class FormlyNgAntdModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":"
|
1
|
+
{"version":3,"file":"ngx-formly-zorro-antd.mjs","sources":["../../../../packages/formlyantd/src/lib/ui-ng-zorro-antd.module.ts","../../../../packages/formlyantd/src/ngx-formly-zorro-antd.ts"],"sourcesContent":["import { NgModule } from '@angular/core';\n\nimport { FormlyNzFormFieldModule } from 'ngx-formly-zorro-antd/form-field';\nimport { FormlyCommonModule } from 'ngx-formly-zorro-antd/common';\nimport { FormlyNzInputModule } from 'ngx-formly-zorro-antd/input';\nimport { FormlyNzInputNumberModule } from 'ngx-formly-zorro-antd/input-number';\nimport { FormlyNzInputGroupModule } from 'ngx-formly-zorro-antd/input-group';\nimport { FormlyNzTextareaModule } from 'ngx-formly-zorro-antd/textarea';\nimport { FormlyNzRadioModule } from 'ngx-formly-zorro-antd/radio';\nimport { FormlyNzCheckboxModule } from 'ngx-formly-zorro-antd/checkbox';\nimport { FormlyNzSelectModule } from 'ngx-formly-zorro-antd/select';\nimport { FormlyNzSwitchModule } from 'ngx-formly-zorro-antd/switch';\nimport { FormlyNzCascaderModule } from 'ngx-formly-zorro-antd/cascader';\nimport { FormlyNzDatepickerModule } from 'ngx-formly-zorro-antd/datepicker';\nimport { FormlyNzRateModule } from 'ngx-formly-zorro-antd/rate';\nimport { FormlyNzSliderModule } from 'ngx-formly-zorro-antd/slider';\nimport { FormlyNzTimepickerModule } from 'ngx-formly-zorro-antd/timepicker';\nimport { FormlyNzTransferModule } from 'ngx-formly-zorro-antd/transfer';\nimport { FormlyNzTreeSelectModule } from 'ngx-formly-zorro-antd/tree-select';\nimport { FormlyNzUploadModule } from 'ngx-formly-zorro-antd/upload';\nimport { FormlyNzTabsModule } from 'ngx-formly-zorro-antd/tabs';\nimport { FormlyNzCardModule } from 'ngx-formly-zorro-antd/card';\nimport { FormlyNzCardWrapperModule } from 'ngx-formly-zorro-antd/card-wrapper';\nimport { FormlyNzButtonModule } from 'ngx-formly-zorro-antd/button';\nimport { FormlyNzGridModule } from 'ngx-formly-zorro-antd/grid';\nimport { FormlyNzSpaceModule } from 'ngx-formly-zorro-antd/space';\nimport { FormlyRefTemplateModule } from 'ngx-formly-zorro-antd/ref-template';\n\n@NgModule({\n imports: [\n FormlyNzFormFieldModule,\n FormlyCommonModule,\n FormlyNzInputModule,\n FormlyNzInputNumberModule,\n FormlyNzInputGroupModule,\n FormlyNzTextareaModule,\n FormlyNzRadioModule,\n FormlyNzCheckboxModule,\n FormlyNzSelectModule,\n FormlyNzSwitchModule,\n FormlyNzCascaderModule,\n FormlyNzDatepickerModule,\n FormlyNzRateModule,\n FormlyNzSliderModule,\n FormlyNzTimepickerModule,\n FormlyNzTransferModule,\n FormlyNzTreeSelectModule,\n FormlyNzUploadModule,\n FormlyNzTabsModule,\n FormlyNzCardModule,\n FormlyNzCardWrapperModule,\n FormlyNzButtonModule,\n FormlyNzGridModule,\n FormlyNzSpaceModule,\n FormlyRefTemplateModule\n ]\n})\nexport class FormlyNgAntdModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;MAyDa,kBAAkB,CAAA;8GAAlB,kBAAkB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA,EAAA;AAAlB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,kBAAkB,YA3B3B,uBAAuB;YACvB,kBAAkB;YAClB,mBAAmB;YACnB,yBAAyB;YACzB,wBAAwB;YACxB,sBAAsB;YACtB,mBAAmB;YACnB,sBAAsB;YACtB,oBAAoB;YACpB,oBAAoB;YACpB,sBAAsB;YACtB,wBAAwB;YACxB,kBAAkB;YAClB,oBAAoB;YACpB,wBAAwB;YACxB,sBAAsB;YACtB,wBAAwB;YACxB,oBAAoB;YACpB,kBAAkB;YAClB,kBAAkB;YAClB,yBAAyB;YACzB,oBAAoB;YACpB,kBAAkB;YAClB,mBAAmB;YACnB,uBAAuB,CAAA,EAAA,CAAA,CAAA,EAAA;AAGd,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,kBAAkB,YA3B3B,uBAAuB;YACvB,kBAAkB;YAClB,mBAAmB;YACnB,yBAAyB;YACzB,wBAAwB;YACxB,sBAAsB;YACtB,mBAAmB;YACnB,sBAAsB;YACtB,oBAAoB;YACpB,oBAAoB;YACpB,sBAAsB;YACtB,wBAAwB;YACxB,kBAAkB;YAClB,oBAAoB;YACpB,wBAAwB;YACxB,sBAAsB;YACtB,wBAAwB;YACxB,oBAAoB;YACpB,kBAAkB;YAClB,kBAAkB;YAClB,yBAAyB;YACzB,oBAAoB;YACpB,kBAAkB;YAClB,mBAAmB;YACnB,uBAAuB,CAAA,EAAA,CAAA,CAAA,EAAA;;2FAGd,kBAAkB,EAAA,UAAA,EAAA,CAAA;kBA7B9B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE;wBACP,uBAAuB;wBACvB,kBAAkB;wBAClB,mBAAmB;wBACnB,yBAAyB;wBACzB,wBAAwB;wBACxB,sBAAsB;wBACtB,mBAAmB;wBACnB,sBAAsB;wBACtB,oBAAoB;wBACpB,oBAAoB;wBACpB,sBAAsB;wBACtB,wBAAwB;wBACxB,kBAAkB;wBAClB,oBAAoB;wBACpB,wBAAwB;wBACxB,sBAAsB;wBACtB,wBAAwB;wBACxB,oBAAoB;wBACpB,kBAAkB;wBAClB,kBAAkB;wBAClB,yBAAyB;wBACzB,oBAAoB;wBACpB,kBAAkB;wBAClB,mBAAmB;wBACnB,uBAAuB;AACxB,qBAAA;AACF,iBAAA,CAAA;;;ACxDD;;AAEG;;;;"}
|
@@ -23,8 +23,9 @@ import * as i21 from "ngx-formly-zorro-antd/card-wrapper";
|
|
23
23
|
import * as i22 from "ngx-formly-zorro-antd/button";
|
24
24
|
import * as i23 from "ngx-formly-zorro-antd/grid";
|
25
25
|
import * as i24 from "ngx-formly-zorro-antd/space";
|
26
|
+
import * as i25 from "ngx-formly-zorro-antd/ref-template";
|
26
27
|
export declare class FormlyNgAntdModule {
|
27
28
|
static ɵfac: i0.ɵɵFactoryDeclaration<FormlyNgAntdModule, never>;
|
28
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<FormlyNgAntdModule, never, [typeof i1.FormlyNzFormFieldModule, typeof i2.FormlyCommonModule, typeof i3.FormlyNzInputModule, typeof i4.FormlyNzInputNumberModule, typeof i5.FormlyNzInputGroupModule, typeof i6.FormlyNzTextareaModule, typeof i7.FormlyNzRadioModule, typeof i8.FormlyNzCheckboxModule, typeof i9.FormlyNzSelectModule, typeof i10.FormlyNzSwitchModule, typeof i11.FormlyNzCascaderModule, typeof i12.FormlyNzDatepickerModule, typeof i13.FormlyNzRateModule, typeof i14.FormlyNzSliderModule, typeof i15.FormlyNzTimepickerModule, typeof i16.FormlyNzTransferModule, typeof i17.FormlyNzTreeSelectModule, typeof i18.FormlyNzUploadModule, typeof i19.FormlyNzTabsModule, typeof i20.FormlyNzCardModule, typeof i21.FormlyNzCardWrapperModule, typeof i22.FormlyNzButtonModule, typeof i23.FormlyNzGridModule, typeof i24.FormlyNzSpaceModule], never>;
|
29
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<FormlyNgAntdModule, never, [typeof i1.FormlyNzFormFieldModule, typeof i2.FormlyCommonModule, typeof i3.FormlyNzInputModule, typeof i4.FormlyNzInputNumberModule, typeof i5.FormlyNzInputGroupModule, typeof i6.FormlyNzTextareaModule, typeof i7.FormlyNzRadioModule, typeof i8.FormlyNzCheckboxModule, typeof i9.FormlyNzSelectModule, typeof i10.FormlyNzSwitchModule, typeof i11.FormlyNzCascaderModule, typeof i12.FormlyNzDatepickerModule, typeof i13.FormlyNzRateModule, typeof i14.FormlyNzSliderModule, typeof i15.FormlyNzTimepickerModule, typeof i16.FormlyNzTransferModule, typeof i17.FormlyNzTreeSelectModule, typeof i18.FormlyNzUploadModule, typeof i19.FormlyNzTabsModule, typeof i20.FormlyNzCardModule, typeof i21.FormlyNzCardWrapperModule, typeof i22.FormlyNzButtonModule, typeof i23.FormlyNzGridModule, typeof i24.FormlyNzSpaceModule, typeof i25.FormlyRefTemplateModule], never>;
|
29
30
|
static ɵinj: i0.ɵɵInjectorDeclaration<FormlyNgAntdModule>;
|
30
31
|
}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "ngx-formly-zorro-antd",
|
3
|
-
"version": "16.1.
|
3
|
+
"version": "16.1.3",
|
4
4
|
"publishConfig": {
|
5
5
|
"registry": "https://registry.npmjs.org",
|
6
6
|
"access": "public"
|
@@ -44,36 +44,36 @@
|
|
44
44
|
"esm": "./esm2022/button/ngx-formly-zorro-antd-button.mjs",
|
45
45
|
"default": "./fesm2022/ngx-formly-zorro-antd-button.mjs"
|
46
46
|
},
|
47
|
+
"./checkbox": {
|
48
|
+
"types": "./checkbox/index.d.ts",
|
49
|
+
"esm2022": "./esm2022/checkbox/ngx-formly-zorro-antd-checkbox.mjs",
|
50
|
+
"esm": "./esm2022/checkbox/ngx-formly-zorro-antd-checkbox.mjs",
|
51
|
+
"default": "./fesm2022/ngx-formly-zorro-antd-checkbox.mjs"
|
52
|
+
},
|
47
53
|
"./card-wrapper": {
|
48
54
|
"types": "./card-wrapper/index.d.ts",
|
49
55
|
"esm2022": "./esm2022/card-wrapper/ngx-formly-zorro-antd-card-wrapper.mjs",
|
50
56
|
"esm": "./esm2022/card-wrapper/ngx-formly-zorro-antd-card-wrapper.mjs",
|
51
57
|
"default": "./fesm2022/ngx-formly-zorro-antd-card-wrapper.mjs"
|
52
58
|
},
|
59
|
+
"./common": {
|
60
|
+
"types": "./common/index.d.ts",
|
61
|
+
"esm2022": "./esm2022/common/ngx-formly-zorro-antd-common.mjs",
|
62
|
+
"esm": "./esm2022/common/ngx-formly-zorro-antd-common.mjs",
|
63
|
+
"default": "./fesm2022/ngx-formly-zorro-antd-common.mjs"
|
64
|
+
},
|
53
65
|
"./cascader": {
|
54
66
|
"types": "./cascader/index.d.ts",
|
55
67
|
"esm2022": "./esm2022/cascader/ngx-formly-zorro-antd-cascader.mjs",
|
56
68
|
"esm": "./esm2022/cascader/ngx-formly-zorro-antd-cascader.mjs",
|
57
69
|
"default": "./fesm2022/ngx-formly-zorro-antd-cascader.mjs"
|
58
70
|
},
|
59
|
-
"./checkbox": {
|
60
|
-
"types": "./checkbox/index.d.ts",
|
61
|
-
"esm2022": "./esm2022/checkbox/ngx-formly-zorro-antd-checkbox.mjs",
|
62
|
-
"esm": "./esm2022/checkbox/ngx-formly-zorro-antd-checkbox.mjs",
|
63
|
-
"default": "./fesm2022/ngx-formly-zorro-antd-checkbox.mjs"
|
64
|
-
},
|
65
71
|
"./card": {
|
66
72
|
"types": "./card/index.d.ts",
|
67
73
|
"esm2022": "./esm2022/card/ngx-formly-zorro-antd-card.mjs",
|
68
74
|
"esm": "./esm2022/card/ngx-formly-zorro-antd-card.mjs",
|
69
75
|
"default": "./fesm2022/ngx-formly-zorro-antd-card.mjs"
|
70
76
|
},
|
71
|
-
"./common": {
|
72
|
-
"types": "./common/index.d.ts",
|
73
|
-
"esm2022": "./esm2022/common/ngx-formly-zorro-antd-common.mjs",
|
74
|
-
"esm": "./esm2022/common/ngx-formly-zorro-antd-common.mjs",
|
75
|
-
"default": "./fesm2022/ngx-formly-zorro-antd-common.mjs"
|
76
|
-
},
|
77
77
|
"./datepicker": {
|
78
78
|
"types": "./datepicker/index.d.ts",
|
79
79
|
"esm2022": "./esm2022/datepicker/ngx-formly-zorro-antd-datepicker.mjs",
|
@@ -92,18 +92,18 @@
|
|
92
92
|
"esm": "./esm2022/form-field/ngx-formly-zorro-antd-form-field.mjs",
|
93
93
|
"default": "./fesm2022/ngx-formly-zorro-antd-form-field.mjs"
|
94
94
|
},
|
95
|
-
"./grid": {
|
96
|
-
"types": "./grid/index.d.ts",
|
97
|
-
"esm2022": "./esm2022/grid/ngx-formly-zorro-antd-grid.mjs",
|
98
|
-
"esm": "./esm2022/grid/ngx-formly-zorro-antd-grid.mjs",
|
99
|
-
"default": "./fesm2022/ngx-formly-zorro-antd-grid.mjs"
|
100
|
-
},
|
101
95
|
"./input": {
|
102
96
|
"types": "./input/index.d.ts",
|
103
97
|
"esm2022": "./esm2022/input/ngx-formly-zorro-antd-input.mjs",
|
104
98
|
"esm": "./esm2022/input/ngx-formly-zorro-antd-input.mjs",
|
105
99
|
"default": "./fesm2022/ngx-formly-zorro-antd-input.mjs"
|
106
100
|
},
|
101
|
+
"./grid": {
|
102
|
+
"types": "./grid/index.d.ts",
|
103
|
+
"esm2022": "./esm2022/grid/ngx-formly-zorro-antd-grid.mjs",
|
104
|
+
"esm": "./esm2022/grid/ngx-formly-zorro-antd-grid.mjs",
|
105
|
+
"default": "./fesm2022/ngx-formly-zorro-antd-grid.mjs"
|
106
|
+
},
|
107
107
|
"./input-group": {
|
108
108
|
"types": "./input-group/index.d.ts",
|
109
109
|
"esm2022": "./esm2022/input-group/ngx-formly-zorro-antd-input-group.mjs",
|
@@ -122,6 +122,12 @@
|
|
122
122
|
"esm": "./esm2022/radio/ngx-formly-zorro-antd-radio.mjs",
|
123
123
|
"default": "./fesm2022/ngx-formly-zorro-antd-radio.mjs"
|
124
124
|
},
|
125
|
+
"./ref-template": {
|
126
|
+
"types": "./ref-template/index.d.ts",
|
127
|
+
"esm2022": "./esm2022/ref-template/ngx-formly-zorro-antd-ref-template.mjs",
|
128
|
+
"esm": "./esm2022/ref-template/ngx-formly-zorro-antd-ref-template.mjs",
|
129
|
+
"default": "./fesm2022/ngx-formly-zorro-antd-ref-template.mjs"
|
130
|
+
},
|
125
131
|
"./rate": {
|
126
132
|
"types": "./rate/index.d.ts",
|
127
133
|
"esm2022": "./esm2022/rate/ngx-formly-zorro-antd-rate.mjs",
|
@@ -0,0 +1,11 @@
|
|
1
|
+
import * as i0 from "@angular/core";
|
2
|
+
import * as i1 from "./ref-template.type";
|
3
|
+
import * as i2 from "@angular/common";
|
4
|
+
import * as i3 from "ng-zorro-antd/core/outlet";
|
5
|
+
import * as i4 from "@pkt/ng.core";
|
6
|
+
import * as i5 from "@ngx-formly/core";
|
7
|
+
export declare class FormlyRefTemplateModule {
|
8
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FormlyRefTemplateModule, never>;
|
9
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<FormlyRefTemplateModule, [typeof i1.FormlyFieldRefTemplate], [typeof i2.CommonModule, typeof i3.NzOutletModule, typeof i4.TrustedHtmlPipe, typeof i5.FormlyModule], never>;
|
10
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<FormlyRefTemplateModule>;
|
11
|
+
}
|
@@ -0,0 +1,79 @@
|
|
1
|
+
import { TemplateRef, Type } from '@angular/core';
|
2
|
+
import { FieldType, FieldTypeConfig } from '@ngx-formly/core';
|
3
|
+
import type { FormlyFieldProps } from 'ngx-formly-zorro-antd/form-field';
|
4
|
+
import type { NzFormlyFieldConfig } from 'ngx-formly-zorro-antd/common';
|
5
|
+
import { FormlyBoxTemplates } from 'ngx-formly-zorro-antd/common';
|
6
|
+
import * as i0 from "@angular/core";
|
7
|
+
interface RefTemplateProps extends FormlyFieldProps {
|
8
|
+
ref?: string | TemplateRef<{
|
9
|
+
$implicit: FormlyRefTemplateFieldConfig;
|
10
|
+
props: RefTemplateProps;
|
11
|
+
}>;
|
12
|
+
refName?: string;
|
13
|
+
}
|
14
|
+
/**
|
15
|
+
* RefTemplate 配置
|
16
|
+
*/
|
17
|
+
export interface FormlyRefTemplateFieldConfig extends NzFormlyFieldConfig<RefTemplateProps> {
|
18
|
+
type: 'ref-template' | Type<FormlyFieldRefTemplate>;
|
19
|
+
}
|
20
|
+
/**
|
21
|
+
* 引用模板,支持HTML,TemplateRef对象,或者NamedTemplate
|
22
|
+
* @example
|
23
|
+
*
|
24
|
+
* 用法1: 使用NamedTemplate(推荐)
|
25
|
+
*
|
26
|
+
* html
|
27
|
+
* ```html
|
28
|
+
* <formly-form formly-box>
|
29
|
+
* <ng-template named="test"></ng-template>
|
30
|
+
* </formly-form>
|
31
|
+
* ```
|
32
|
+
*
|
33
|
+
* 配置
|
34
|
+
* ```js
|
35
|
+
* {
|
36
|
+
* type: 'ref-template',
|
37
|
+
* props: {
|
38
|
+
* refName: 'test'
|
39
|
+
* }
|
40
|
+
* }
|
41
|
+
* ```
|
42
|
+
*
|
43
|
+
* 用法2:TemplateRef对象
|
44
|
+
* ```html
|
45
|
+
* <ng-template #test2></ng-template>
|
46
|
+
* ```
|
47
|
+
*
|
48
|
+
* 配置
|
49
|
+
* @viewChild('test2') test2: TemplateRef<{}>;
|
50
|
+
*
|
51
|
+
* ```js
|
52
|
+
* {
|
53
|
+
* type: 'ref-template',
|
54
|
+
* props: {
|
55
|
+
* ref: this.test2
|
56
|
+
* }
|
57
|
+
* }
|
58
|
+
* ```
|
59
|
+
*
|
60
|
+
* 用法3: 使用html
|
61
|
+
*
|
62
|
+
* 配置
|
63
|
+
* ```js
|
64
|
+
* {
|
65
|
+
* type: 'ref-template',
|
66
|
+
* props: {
|
67
|
+
* ref: '<div>test text</div>'
|
68
|
+
* }
|
69
|
+
* }
|
70
|
+
* ```
|
71
|
+
*/
|
72
|
+
export declare class FormlyFieldRefTemplate extends FieldType<FieldTypeConfig<RefTemplateProps>> {
|
73
|
+
fieldTemplates: FormlyBoxTemplates;
|
74
|
+
constructor(fieldTemplates: FormlyBoxTemplates);
|
75
|
+
get ref(): TemplateRef<any> | undefined;
|
76
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FormlyFieldRefTemplate, [{ optional: true; }]>;
|
77
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FormlyFieldRefTemplate, "formly-ref-template", never, {}, {}, never, never, false, never>;
|
78
|
+
}
|
79
|
+
export {};
|