ngx-formly-zorro-antd 14.2.2 → 14.3.1
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +1 -1
- package/autocomplete/autocomplete.props.d.ts +38 -38
- package/autocomplete/index.d.ts +5 -5
- package/autocomplete/public_api.d.ts +1 -1
- package/button/button.module.d.ts +11 -11
- package/button/button.type.d.ts +66 -66
- package/button/index.d.ts +5 -5
- package/button/public_api.d.ts +2 -2
- package/card/card.module.d.ts +10 -10
- package/card/card.wrapper.d.ts +58 -58
- package/card/index.d.ts +5 -5
- package/card/public_api.d.ts +2 -2
- package/cascader/cascader.module.d.ts +12 -12
- package/cascader/cascader.type.d.ts +152 -152
- package/cascader/index.d.ts +5 -5
- package/cascader/public_api.d.ts +2 -2
- package/checkbox/checkbox.module.d.ts +12 -12
- package/checkbox/checkbox.type.d.ts +35 -35
- package/checkbox/index.d.ts +5 -5
- package/checkbox/public_api.d.ts +2 -2
- package/datepicker/datepicker.module.d.ts +12 -12
- package/datepicker/datepicker.props.d.ts +149 -149
- package/datepicker/datepicker.type.d.ts +32 -32
- package/datepicker/index.d.ts +5 -5
- package/datepicker/public_api.d.ts +2 -2
- package/esm2020/autocomplete/autocomplete.props.mjs +2 -2
- package/esm2020/autocomplete/ngx-formly-zorro-antd-autocomplete.mjs +4 -4
- package/esm2020/autocomplete/public_api.mjs +2 -2
- package/esm2020/button/button.module.mjs +61 -61
- package/esm2020/button/button.type.mjs +110 -110
- package/esm2020/button/ngx-formly-zorro-antd-button.mjs +4 -4
- package/esm2020/button/public_api.mjs +3 -3
- package/esm2020/card/card.module.mjs +43 -43
- package/esm2020/card/card.wrapper.mjs +47 -47
- package/esm2020/card/ngx-formly-zorro-antd-card.mjs +4 -4
- package/esm2020/card/public_api.mjs +3 -3
- package/esm2020/cascader/cascader.module.mjs +51 -51
- package/esm2020/cascader/cascader.type.mjs +112 -112
- package/esm2020/cascader/ngx-formly-zorro-antd-cascader.mjs +4 -4
- package/esm2020/cascader/public_api.mjs +3 -3
- package/esm2020/checkbox/checkbox.module.mjs +59 -59
- package/esm2020/checkbox/checkbox.type.mjs +69 -69
- package/esm2020/checkbox/ngx-formly-zorro-antd-checkbox.mjs +4 -4
- package/esm2020/checkbox/public_api.mjs +3 -3
- package/esm2020/datepicker/datepicker.module.mjs +51 -51
- package/esm2020/datepicker/datepicker.props.mjs +2 -2
- package/esm2020/datepicker/datepicker.type.mjs +196 -196
- package/esm2020/datepicker/ngx-formly-zorro-antd-datepicker.mjs +4 -4
- package/esm2020/datepicker/public_api.mjs +3 -3
- package/esm2020/form-field/form-field.module.mjs +45 -45
- package/esm2020/form-field/form-field.props.mjs +2 -2
- package/esm2020/form-field/form-field.wrapper.mjs +127 -127
- package/esm2020/form-field/ngx-formly-zorro-antd-form-field.mjs +4 -4
- package/esm2020/form-field/public_api.mjs +2 -2
- package/esm2020/grid/grid.module.mjs +41 -41
- package/esm2020/grid/grid.props.mjs +2 -2
- package/esm2020/grid/grid.type.mjs +71 -71
- package/esm2020/grid/ngx-formly-zorro-antd-grid.mjs +4 -4
- package/esm2020/grid/public_api.mjs +3 -3
- package/esm2020/index.mjs +2 -2
- package/esm2020/input/input.module.mjs +89 -89
- package/esm2020/input/input.props.mjs +2 -2
- package/esm2020/input/input.type.mjs +309 -309
- package/esm2020/input/ngx-formly-zorro-antd-input.mjs +4 -4
- package/esm2020/input/public_api.mjs +3 -3
- package/esm2020/input-group/input-group.module.mjs +47 -47
- package/esm2020/input-group/input-group.props.mjs +2 -2
- package/esm2020/input-group/input-group.type.mjs +71 -71
- package/esm2020/input-group/ngx-formly-zorro-antd-input-group.mjs +4 -4
- package/esm2020/input-group/public_api.mjs +3 -3
- package/esm2020/input-number/input-number.module.mjs +59 -59
- package/esm2020/input-number/input-number.props.mjs +2 -2
- package/esm2020/input-number/input-number.type.mjs +128 -128
- package/esm2020/input-number/ngx-formly-zorro-antd-input-number.mjs +4 -4
- package/esm2020/input-number/public_api.mjs +3 -3
- package/esm2020/lib/ui-ng-zorro-antd.mjs +2 -2
- package/esm2020/lib/ui-ng-zorro-antd.module.mjs +97 -97
- package/esm2020/ngx-formly-zorro-antd.mjs +4 -4
- package/esm2020/radio/ngx-formly-zorro-antd-radio.mjs +4 -4
- package/esm2020/radio/public_api.mjs +3 -3
- package/esm2020/radio/radio.module.mjs +59 -59
- package/esm2020/radio/radio.type.mjs +96 -96
- package/esm2020/rate/ngx-formly-zorro-antd-rate.mjs +4 -4
- package/esm2020/rate/public_api.mjs +3 -3
- package/esm2020/rate/rate.module.mjs +51 -51
- package/esm2020/rate/rate.type.mjs +63 -63
- package/esm2020/select/ngx-formly-zorro-antd-select.mjs +4 -4
- package/esm2020/select/public_api.mjs +3 -3
- package/esm2020/select/select.module.mjs +57 -57
- package/esm2020/select/select.props.mjs +2 -2
- package/esm2020/select/select.type.mjs +170 -167
- package/esm2020/slider/ngx-formly-zorro-antd-slider.mjs +4 -4
- package/esm2020/slider/public_api.mjs +3 -3
- package/esm2020/slider/slider.module.mjs +51 -51
- package/esm2020/slider/slider.type.mjs +67 -67
- package/esm2020/switch/ngx-formly-zorro-antd-switch.mjs +4 -4
- package/esm2020/switch/public_api.mjs +3 -3
- package/esm2020/switch/switch.module.mjs +51 -51
- package/esm2020/switch/switch.type.mjs +53 -53
- package/esm2020/tabs/ngx-formly-zorro-antd-tabs.mjs +4 -4
- package/esm2020/tabs/public_api.mjs +3 -3
- package/esm2020/tabs/tabs.module.mjs +41 -41
- package/esm2020/tabs/tabs.props.mjs +2 -2
- package/esm2020/tabs/tabs.wrapper.mjs +115 -115
- package/esm2020/textarea/ngx-formly-zorro-antd-textarea.mjs +4 -4
- package/esm2020/textarea/public_api.mjs +3 -3
- package/esm2020/textarea/textarea.module.mjs +55 -55
- package/esm2020/textarea/textarea.type.mjs +141 -141
- package/esm2020/timepicker/ngx-formly-zorro-antd-timepicker.mjs +4 -4
- package/esm2020/timepicker/public_api.mjs +3 -3
- package/esm2020/timepicker/timepicker.module.mjs +51 -51
- package/esm2020/timepicker/timepicker.type.mjs +96 -96
- package/esm2020/transfer/ngx-formly-zorro-antd-transfer.mjs +4 -4
- package/esm2020/transfer/public_api.mjs +3 -3
- package/esm2020/transfer/transfer.component.mjs +128 -128
- package/esm2020/transfer/transfer.module.mjs +52 -52
- package/esm2020/transfer/transfer.type.mjs +87 -87
- package/esm2020/tree-select/ngx-formly-zorro-antd-tree-select.mjs +4 -4
- package/esm2020/tree-select/public_api.mjs +3 -3
- package/esm2020/tree-select/tree-select.module.mjs +51 -51
- package/esm2020/tree-select/tree-select.type.mjs +100 -98
- package/esm2020/upload/ngx-formly-zorro-antd-upload.mjs +4 -4
- package/esm2020/upload/public_api.mjs +3 -3
- package/esm2020/upload/upload.component.mjs +253 -253
- package/esm2020/upload/upload.module.mjs +60 -60
- package/esm2020/upload/upload.props.mjs +2 -2
- package/esm2020/upload/upload.type.mjs +129 -129
- package/fesm2015/ngx-formly-zorro-antd-autocomplete.mjs +2 -2
- package/fesm2015/ngx-formly-zorro-antd-button.mjs +152 -152
- package/fesm2015/ngx-formly-zorro-antd-button.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-card.mjs +77 -77
- package/fesm2015/ngx-formly-zorro-antd-card.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-cascader.mjs +145 -145
- package/fesm2015/ngx-formly-zorro-antd-cascader.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-checkbox.mjs +110 -110
- package/fesm2015/ngx-formly-zorro-antd-checkbox.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-datepicker.mjs +229 -229
- package/fesm2015/ngx-formly-zorro-antd-datepicker.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-form-field.mjs +155 -155
- package/fesm2015/ngx-formly-zorro-antd-form-field.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-grid.mjs +97 -97
- package/fesm2015/ngx-formly-zorro-antd-grid.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-input-group.mjs +102 -102
- package/fesm2015/ngx-formly-zorro-antd-input-group.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-input-number.mjs +169 -169
- package/fesm2015/ngx-formly-zorro-antd-input-number.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-input.mjs +376 -376
- package/fesm2015/ngx-formly-zorro-antd-input.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-radio.mjs +134 -134
- package/fesm2015/ngx-formly-zorro-antd-radio.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-rate.mjs +97 -97
- package/fesm2015/ngx-formly-zorro-antd-rate.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-select.mjs +206 -203
- package/fesm2015/ngx-formly-zorro-antd-select.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-slider.mjs +101 -101
- package/fesm2015/ngx-formly-zorro-antd-slider.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-switch.mjs +87 -87
- package/fesm2015/ngx-formly-zorro-antd-switch.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-tabs.mjs +141 -141
- package/fesm2015/ngx-formly-zorro-antd-tabs.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-textarea.mjs +176 -176
- package/fesm2015/ngx-formly-zorro-antd-textarea.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-timepicker.mjs +129 -129
- package/fesm2015/ngx-formly-zorro-antd-timepicker.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-transfer.mjs +241 -241
- package/fesm2015/ngx-formly-zorro-antd-transfer.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-tree-select.mjs +133 -131
- package/fesm2015/ngx-formly-zorro-antd-tree-select.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd-upload.mjs +410 -410
- package/fesm2015/ngx-formly-zorro-antd-upload.mjs.map +1 -1
- package/fesm2015/ngx-formly-zorro-antd.mjs +74 -74
- package/fesm2015/ngx-formly-zorro-antd.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-autocomplete.mjs +2 -2
- package/fesm2020/ngx-formly-zorro-antd-button.mjs +152 -152
- package/fesm2020/ngx-formly-zorro-antd-button.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-card.mjs +77 -77
- package/fesm2020/ngx-formly-zorro-antd-card.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-cascader.mjs +145 -145
- package/fesm2020/ngx-formly-zorro-antd-cascader.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-checkbox.mjs +110 -110
- package/fesm2020/ngx-formly-zorro-antd-checkbox.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-datepicker.mjs +229 -229
- package/fesm2020/ngx-formly-zorro-antd-datepicker.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-form-field.mjs +155 -155
- package/fesm2020/ngx-formly-zorro-antd-form-field.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-grid.mjs +97 -97
- package/fesm2020/ngx-formly-zorro-antd-grid.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-input-group.mjs +102 -102
- package/fesm2020/ngx-formly-zorro-antd-input-group.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-input-number.mjs +169 -169
- package/fesm2020/ngx-formly-zorro-antd-input-number.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-input.mjs +376 -376
- package/fesm2020/ngx-formly-zorro-antd-input.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-radio.mjs +134 -134
- package/fesm2020/ngx-formly-zorro-antd-radio.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-rate.mjs +97 -97
- package/fesm2020/ngx-formly-zorro-antd-rate.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-select.mjs +206 -203
- package/fesm2020/ngx-formly-zorro-antd-select.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-slider.mjs +101 -101
- package/fesm2020/ngx-formly-zorro-antd-slider.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-switch.mjs +87 -87
- package/fesm2020/ngx-formly-zorro-antd-switch.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-tabs.mjs +141 -141
- package/fesm2020/ngx-formly-zorro-antd-tabs.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-textarea.mjs +176 -176
- package/fesm2020/ngx-formly-zorro-antd-textarea.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-timepicker.mjs +129 -129
- package/fesm2020/ngx-formly-zorro-antd-timepicker.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-transfer.mjs +241 -241
- package/fesm2020/ngx-formly-zorro-antd-transfer.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-tree-select.mjs +133 -131
- package/fesm2020/ngx-formly-zorro-antd-tree-select.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd-upload.mjs +409 -409
- package/fesm2020/ngx-formly-zorro-antd-upload.mjs.map +1 -1
- package/fesm2020/ngx-formly-zorro-antd.mjs +74 -74
- package/fesm2020/ngx-formly-zorro-antd.mjs.map +1 -1
- package/form-field/form-field.module.d.ts +11 -11
- package/form-field/form-field.props.d.ts +105 -105
- package/form-field/form-field.wrapper.d.ts +9 -9
- package/form-field/index.d.ts +5 -5
- package/form-field/public_api.d.ts +3 -3
- package/grid/grid.module.d.ts +10 -10
- package/grid/grid.props.d.ts +44 -44
- package/grid/grid.type.d.ts +11 -11
- package/grid/index.d.ts +5 -5
- package/grid/public_api.d.ts +3 -3
- package/index.d.ts +1 -1
- package/input/index.d.ts +5 -5
- package/input/input.module.d.ts +14 -14
- package/input/input.props.d.ts +36 -36
- package/input/input.type.d.ts +26 -26
- package/input/public_api.d.ts +2 -2
- package/input-group/index.d.ts +5 -5
- package/input-group/input-group.module.d.ts +11 -11
- package/input-group/input-group.props.d.ts +56 -56
- package/input-group/input-group.type.d.ts +22 -22
- package/input-group/public_api.d.ts +3 -3
- package/input-number/index.d.ts +5 -5
- package/input-number/input-number.module.d.ts +12 -12
- package/input-number/input-number.props.d.ts +81 -81
- package/input-number/input-number.type.d.ts +24 -24
- package/input-number/public_api.d.ts +2 -2
- package/lib/ui-ng-zorro-antd.d.ts +1 -1
- package/lib/ui-ng-zorro-antd.module.d.ts +27 -27
- package/package.json +2 -2
- package/radio/index.d.ts +5 -5
- package/radio/public_api.d.ts +2 -2
- package/radio/radio.module.d.ts +14 -14
- package/radio/radio.type.d.ts +38 -38
- package/rate/index.d.ts +5 -5
- package/rate/public_api.d.ts +2 -2
- package/rate/rate.module.d.ts +12 -12
- package/rate/rate.type.d.ts +57 -57
- package/select/index.d.ts +5 -5
- package/select/public_api.d.ts +2 -2
- package/select/select.module.d.ts +13 -13
- package/select/select.props.d.ts +171 -166
- package/select/select.type.d.ts +36 -35
- package/slider/index.d.ts +5 -5
- package/slider/public_api.d.ts +2 -2
- package/slider/slider.module.d.ts +12 -12
- package/slider/slider.type.d.ts +76 -76
- package/switch/index.d.ts +5 -5
- package/switch/public_api.d.ts +2 -2
- package/switch/switch.module.d.ts +12 -12
- package/switch/switch.type.d.ts +44 -44
- package/tabs/index.d.ts +5 -5
- package/tabs/public_api.d.ts +2 -2
- package/tabs/tabs.module.d.ts +10 -10
- package/tabs/tabs.props.d.ts +126 -126
- package/tabs/tabs.wrapper.d.ts +28 -28
- package/textarea/index.d.ts +5 -5
- package/textarea/public_api.d.ts +2 -2
- package/textarea/textarea.module.d.ts +13 -13
- package/textarea/textarea.type.d.ts +39 -39
- package/timepicker/index.d.ts +5 -5
- package/timepicker/public_api.d.ts +2 -2
- package/timepicker/timepicker.module.d.ts +12 -12
- package/timepicker/timepicker.type.d.ts +138 -138
- package/transfer/index.d.ts +5 -5
- package/transfer/public_api.d.ts +2 -2
- package/transfer/transfer.component.d.ts +26 -26
- package/transfer/transfer.module.d.ts +13 -13
- package/transfer/transfer.type.d.ts +118 -118
- package/tree-select/index.d.ts +5 -5
- package/tree-select/public_api.d.ts +2 -2
- package/tree-select/tree-select.module.d.ts +12 -12
- package/tree-select/tree-select.type.d.ts +163 -158
- package/upload/index.d.ts +5 -5
- package/upload/public_api.d.ts +2 -2
- package/upload/upload.component.d.ts +33 -33
- package/upload/upload.module.d.ts +15 -15
- package/upload/upload.props.d.ts +173 -173
- package/upload/upload.type.d.ts +29 -29
@@ -10,155 +10,155 @@ import { FormlyNzFormFieldModule } from 'ngx-formly-zorro-antd/form-field';
|
|
10
10
|
import * as i3 from 'ng-zorro-antd/cascader';
|
11
11
|
import { NzCascaderModule } from 'ng-zorro-antd/cascader';
|
12
12
|
|
13
|
-
class FormlyFieldCascader extends FieldType {
|
14
|
-
constructor() {
|
15
|
-
super(...arguments);
|
16
|
-
this.defaultOptions = {
|
17
|
-
props: {
|
18
|
-
placeholder: '请选择',
|
19
|
-
allowClear: true,
|
20
|
-
backdrop: false,
|
21
|
-
changeOnSelect: false,
|
22
|
-
expandTrigger: 'click',
|
23
|
-
labelProperty: 'label',
|
24
|
-
showArrow: true,
|
25
|
-
showInput: true,
|
26
|
-
showSearch: false,
|
27
|
-
size: 'default',
|
28
|
-
status: '',
|
29
|
-
valueProperty: 'value',
|
30
|
-
cascaderOptions: []
|
31
|
-
}
|
32
|
-
};
|
33
|
-
}
|
34
|
-
ngOnInit() {
|
35
|
-
const options = this.props['cascaderOptions'];
|
36
|
-
if (!options || options.length === 0) {
|
37
|
-
this.props['cascaderOptions'] = this.props.options;
|
38
|
-
}
|
39
|
-
}
|
40
|
-
}
|
41
|
-
FormlyFieldCascader.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyFieldCascader, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
42
|
-
FormlyFieldCascader.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.1", type: FormlyFieldCascader, selector: "formly-field-cascader", usesInheritance: true, ngImport: i0, template: `<nz-cascader
|
43
|
-
#cascader
|
44
|
-
[nzPlaceHolder]="props.placeholder ?? ''"
|
45
|
-
[formControl]="formControl"
|
46
|
-
[formlyAttributes]="field"
|
47
|
-
[ngClass]="props['className']!"
|
48
|
-
[nzAllowClear]="props['allowClear']!!"
|
49
|
-
[nzAutoFocus]="props['autoFocus']!!"
|
50
|
-
[nzBackdrop]="props['backdrop']!!"
|
51
|
-
[nzChangeOn]="props['changeOn']"
|
52
|
-
[nzChangeOnSelect]="props['changeOnSelect']!!"
|
53
|
-
[nzColumnClassName]="props['columnClassName']"
|
54
|
-
[nzExpandIcon]="props['expandIcon']!"
|
55
|
-
[nzExpandTrigger]="props['expandTrigger']!"
|
56
|
-
[nzLabelProperty]="props['labelProperty']"
|
57
|
-
[nzLabelRender]="props['labelRender'] ?? null"
|
58
|
-
[nzLoadData]="props['loadData']"
|
59
|
-
[nzMenuClassName]="props['menuClassName']"
|
60
|
-
[nzMenuStyle]="props['menuStyle'] ?? null"
|
61
|
-
[nzNotFoundContent]="props['notFoundContent']"
|
62
|
-
[nzOptionRender]="props['optionRender'] ?? null"
|
63
|
-
[nzOptions]="props['cascaderOptions'] ?? null"
|
64
|
-
[nzShowArrow]="props['showArrow']!!"
|
65
|
-
[nzShowInput]="props['showInput']!!"
|
66
|
-
[nzShowSearch]="props['showSearch']!!"
|
67
|
-
[nzSize]="props['size']!"
|
68
|
-
[nzStatus]="props['status'] ?? ''"
|
69
|
-
[nzSuffixIcon]="props['suffixIcon']!"
|
70
|
-
[nzValueProperty]="props['valueProperty']!"
|
71
|
-
(nzClear)="props['onClear'] && props['onClear'](field)"
|
72
|
-
(nzVisibleChange)="props['visibleChange'] && props['visibleChange'](field, $event)"
|
73
|
-
(nzSelectionChange)="props['selectionChange'] && props['selectionChange'](field, $event)"
|
74
|
-
(ngModelChange)="props.change && props.change(field, $event)"
|
75
|
-
></nz-cascader>`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i3.NzCascaderComponent, selector: "nz-cascader, [nz-cascader]", inputs: ["nzOptionRender", "nzShowInput", "nzShowArrow", "nzAllowClear", "nzAutoFocus", "nzChangeOnSelect", "nzDisabled", "nzColumnClassName", "nzExpandTrigger", "nzValueProperty", "nzLabelRender", "nzLabelProperty", "nzNotFoundContent", "nzSize", "nzBackdrop", "nzShowSearch", "nzPlaceHolder", "nzMenuClassName", "nzMenuStyle", "nzMouseEnterDelay", "nzMouseLeaveDelay", "nzStatus", "nzTriggerAction", "nzChangeOn", "nzLoadData", "nzSuffixIcon", "nzExpandIcon", "nzOptions"], outputs: ["nzVisibleChange", "nzSelectionChange", "nzSelect", "nzClear"], exportAs: ["nzCascader"] }, { kind: "directive", type: i4.ɵFormlyAttributes, selector: "[formlyAttributes]", inputs: ["formlyAttributes", "id"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
76
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyFieldCascader, decorators: [{
|
77
|
-
type: Component,
|
78
|
-
args: [{
|
79
|
-
selector: 'formly-field-cascader',
|
80
|
-
template: `<nz-cascader
|
81
|
-
#cascader
|
82
|
-
[nzPlaceHolder]="props.placeholder ?? ''"
|
83
|
-
[formControl]="formControl"
|
84
|
-
[formlyAttributes]="field"
|
85
|
-
[ngClass]="props['className']!"
|
86
|
-
[nzAllowClear]="props['allowClear']!!"
|
87
|
-
[nzAutoFocus]="props['autoFocus']!!"
|
88
|
-
[nzBackdrop]="props['backdrop']!!"
|
89
|
-
[nzChangeOn]="props['changeOn']"
|
90
|
-
[nzChangeOnSelect]="props['changeOnSelect']!!"
|
91
|
-
[nzColumnClassName]="props['columnClassName']"
|
92
|
-
[nzExpandIcon]="props['expandIcon']!"
|
93
|
-
[nzExpandTrigger]="props['expandTrigger']!"
|
94
|
-
[nzLabelProperty]="props['labelProperty']"
|
95
|
-
[nzLabelRender]="props['labelRender'] ?? null"
|
96
|
-
[nzLoadData]="props['loadData']"
|
97
|
-
[nzMenuClassName]="props['menuClassName']"
|
98
|
-
[nzMenuStyle]="props['menuStyle'] ?? null"
|
99
|
-
[nzNotFoundContent]="props['notFoundContent']"
|
100
|
-
[nzOptionRender]="props['optionRender'] ?? null"
|
101
|
-
[nzOptions]="props['cascaderOptions'] ?? null"
|
102
|
-
[nzShowArrow]="props['showArrow']!!"
|
103
|
-
[nzShowInput]="props['showInput']!!"
|
104
|
-
[nzShowSearch]="props['showSearch']!!"
|
105
|
-
[nzSize]="props['size']!"
|
106
|
-
[nzStatus]="props['status'] ?? ''"
|
107
|
-
[nzSuffixIcon]="props['suffixIcon']!"
|
108
|
-
[nzValueProperty]="props['valueProperty']!"
|
109
|
-
(nzClear)="props['onClear'] && props['onClear'](field)"
|
110
|
-
(nzVisibleChange)="props['visibleChange'] && props['visibleChange'](field, $event)"
|
111
|
-
(nzSelectionChange)="props['selectionChange'] && props['selectionChange'](field, $event)"
|
112
|
-
(ngModelChange)="props.change && props.change(field, $event)"
|
113
|
-
></nz-cascader>`,
|
114
|
-
changeDetection: ChangeDetectionStrategy.OnPush
|
115
|
-
}]
|
13
|
+
class FormlyFieldCascader extends FieldType {
|
14
|
+
constructor() {
|
15
|
+
super(...arguments);
|
16
|
+
this.defaultOptions = {
|
17
|
+
props: {
|
18
|
+
placeholder: '请选择',
|
19
|
+
allowClear: true,
|
20
|
+
backdrop: false,
|
21
|
+
changeOnSelect: false,
|
22
|
+
expandTrigger: 'click',
|
23
|
+
labelProperty: 'label',
|
24
|
+
showArrow: true,
|
25
|
+
showInput: true,
|
26
|
+
showSearch: false,
|
27
|
+
size: 'default',
|
28
|
+
status: '',
|
29
|
+
valueProperty: 'value',
|
30
|
+
cascaderOptions: []
|
31
|
+
}
|
32
|
+
};
|
33
|
+
}
|
34
|
+
ngOnInit() {
|
35
|
+
const options = this.props['cascaderOptions'];
|
36
|
+
if (!options || options.length === 0) {
|
37
|
+
this.props['cascaderOptions'] = this.props.options;
|
38
|
+
}
|
39
|
+
}
|
40
|
+
}
|
41
|
+
FormlyFieldCascader.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyFieldCascader, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
42
|
+
FormlyFieldCascader.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.1", type: FormlyFieldCascader, selector: "formly-field-cascader", usesInheritance: true, ngImport: i0, template: `<nz-cascader
|
43
|
+
#cascader
|
44
|
+
[nzPlaceHolder]="props.placeholder ?? ''"
|
45
|
+
[formControl]="formControl"
|
46
|
+
[formlyAttributes]="field"
|
47
|
+
[ngClass]="props['className']!"
|
48
|
+
[nzAllowClear]="props['allowClear']!!"
|
49
|
+
[nzAutoFocus]="props['autoFocus']!!"
|
50
|
+
[nzBackdrop]="props['backdrop']!!"
|
51
|
+
[nzChangeOn]="props['changeOn']"
|
52
|
+
[nzChangeOnSelect]="props['changeOnSelect']!!"
|
53
|
+
[nzColumnClassName]="props['columnClassName']"
|
54
|
+
[nzExpandIcon]="props['expandIcon']!"
|
55
|
+
[nzExpandTrigger]="props['expandTrigger']!"
|
56
|
+
[nzLabelProperty]="props['labelProperty']"
|
57
|
+
[nzLabelRender]="props['labelRender'] ?? null"
|
58
|
+
[nzLoadData]="props['loadData']"
|
59
|
+
[nzMenuClassName]="props['menuClassName']"
|
60
|
+
[nzMenuStyle]="props['menuStyle'] ?? null"
|
61
|
+
[nzNotFoundContent]="props['notFoundContent']"
|
62
|
+
[nzOptionRender]="props['optionRender'] ?? null"
|
63
|
+
[nzOptions]="props['cascaderOptions'] ?? null"
|
64
|
+
[nzShowArrow]="props['showArrow']!!"
|
65
|
+
[nzShowInput]="props['showInput']!!"
|
66
|
+
[nzShowSearch]="props['showSearch']!!"
|
67
|
+
[nzSize]="props['size']!"
|
68
|
+
[nzStatus]="props['status'] ?? ''"
|
69
|
+
[nzSuffixIcon]="props['suffixIcon']!"
|
70
|
+
[nzValueProperty]="props['valueProperty']!"
|
71
|
+
(nzClear)="props['onClear'] && props['onClear'](field)"
|
72
|
+
(nzVisibleChange)="props['visibleChange'] && props['visibleChange'](field, $event)"
|
73
|
+
(nzSelectionChange)="props['selectionChange'] && props['selectionChange'](field, $event)"
|
74
|
+
(ngModelChange)="props.change && props.change(field, $event)"
|
75
|
+
></nz-cascader>`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i3.NzCascaderComponent, selector: "nz-cascader, [nz-cascader]", inputs: ["nzOptionRender", "nzShowInput", "nzShowArrow", "nzAllowClear", "nzAutoFocus", "nzChangeOnSelect", "nzDisabled", "nzColumnClassName", "nzExpandTrigger", "nzValueProperty", "nzLabelRender", "nzLabelProperty", "nzNotFoundContent", "nzSize", "nzBackdrop", "nzShowSearch", "nzPlaceHolder", "nzMenuClassName", "nzMenuStyle", "nzMouseEnterDelay", "nzMouseLeaveDelay", "nzStatus", "nzTriggerAction", "nzChangeOn", "nzLoadData", "nzSuffixIcon", "nzExpandIcon", "nzOptions"], outputs: ["nzVisibleChange", "nzSelectionChange", "nzSelect", "nzClear"], exportAs: ["nzCascader"] }, { kind: "directive", type: i4.ɵFormlyAttributes, selector: "[formlyAttributes]", inputs: ["formlyAttributes", "id"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
76
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyFieldCascader, decorators: [{
|
77
|
+
type: Component,
|
78
|
+
args: [{
|
79
|
+
selector: 'formly-field-cascader',
|
80
|
+
template: `<nz-cascader
|
81
|
+
#cascader
|
82
|
+
[nzPlaceHolder]="props.placeholder ?? ''"
|
83
|
+
[formControl]="formControl"
|
84
|
+
[formlyAttributes]="field"
|
85
|
+
[ngClass]="props['className']!"
|
86
|
+
[nzAllowClear]="props['allowClear']!!"
|
87
|
+
[nzAutoFocus]="props['autoFocus']!!"
|
88
|
+
[nzBackdrop]="props['backdrop']!!"
|
89
|
+
[nzChangeOn]="props['changeOn']"
|
90
|
+
[nzChangeOnSelect]="props['changeOnSelect']!!"
|
91
|
+
[nzColumnClassName]="props['columnClassName']"
|
92
|
+
[nzExpandIcon]="props['expandIcon']!"
|
93
|
+
[nzExpandTrigger]="props['expandTrigger']!"
|
94
|
+
[nzLabelProperty]="props['labelProperty']"
|
95
|
+
[nzLabelRender]="props['labelRender'] ?? null"
|
96
|
+
[nzLoadData]="props['loadData']"
|
97
|
+
[nzMenuClassName]="props['menuClassName']"
|
98
|
+
[nzMenuStyle]="props['menuStyle'] ?? null"
|
99
|
+
[nzNotFoundContent]="props['notFoundContent']"
|
100
|
+
[nzOptionRender]="props['optionRender'] ?? null"
|
101
|
+
[nzOptions]="props['cascaderOptions'] ?? null"
|
102
|
+
[nzShowArrow]="props['showArrow']!!"
|
103
|
+
[nzShowInput]="props['showInput']!!"
|
104
|
+
[nzShowSearch]="props['showSearch']!!"
|
105
|
+
[nzSize]="props['size']!"
|
106
|
+
[nzStatus]="props['status'] ?? ''"
|
107
|
+
[nzSuffixIcon]="props['suffixIcon']!"
|
108
|
+
[nzValueProperty]="props['valueProperty']!"
|
109
|
+
(nzClear)="props['onClear'] && props['onClear'](field)"
|
110
|
+
(nzVisibleChange)="props['visibleChange'] && props['visibleChange'](field, $event)"
|
111
|
+
(nzSelectionChange)="props['selectionChange'] && props['selectionChange'](field, $event)"
|
112
|
+
(ngModelChange)="props.change && props.change(field, $event)"
|
113
|
+
></nz-cascader>`,
|
114
|
+
changeDetection: ChangeDetectionStrategy.OnPush
|
115
|
+
}]
|
116
116
|
}] });
|
117
117
|
|
118
|
-
class FormlyNzCascaderModule {
|
119
|
-
}
|
120
|
-
FormlyNzCascaderModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyNzCascaderModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
121
|
-
FormlyNzCascaderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.1", ngImport: i0, type: FormlyNzCascaderModule, declarations: [FormlyFieldCascader], imports: [CommonModule,
|
122
|
-
ReactiveFormsModule,
|
123
|
-
FormlyNzFormFieldModule,
|
124
|
-
NzCascaderModule, i4.FormlyModule] });
|
125
|
-
FormlyNzCascaderModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyNzCascaderModule, imports: [CommonModule,
|
126
|
-
ReactiveFormsModule,
|
127
|
-
FormlyNzFormFieldModule,
|
128
|
-
NzCascaderModule,
|
129
|
-
FormlyModule.forChild({
|
130
|
-
types: [
|
131
|
-
{
|
132
|
-
name: 'cascader',
|
133
|
-
component: FormlyFieldCascader,
|
134
|
-
wrappers: ['form-field']
|
135
|
-
}
|
136
|
-
]
|
137
|
-
})] });
|
138
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyNzCascaderModule, decorators: [{
|
139
|
-
type: NgModule,
|
140
|
-
args: [{
|
141
|
-
declarations: [FormlyFieldCascader],
|
142
|
-
imports: [
|
143
|
-
CommonModule,
|
144
|
-
ReactiveFormsModule,
|
145
|
-
FormlyNzFormFieldModule,
|
146
|
-
NzCascaderModule,
|
147
|
-
FormlyModule.forChild({
|
148
|
-
types: [
|
149
|
-
{
|
150
|
-
name: 'cascader',
|
151
|
-
component: FormlyFieldCascader,
|
152
|
-
wrappers: ['form-field']
|
153
|
-
}
|
154
|
-
]
|
155
|
-
})
|
156
|
-
]
|
157
|
-
}]
|
118
|
+
class FormlyNzCascaderModule {
|
119
|
+
}
|
120
|
+
FormlyNzCascaderModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyNzCascaderModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
121
|
+
FormlyNzCascaderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.1", ngImport: i0, type: FormlyNzCascaderModule, declarations: [FormlyFieldCascader], imports: [CommonModule,
|
122
|
+
ReactiveFormsModule,
|
123
|
+
FormlyNzFormFieldModule,
|
124
|
+
NzCascaderModule, i4.FormlyModule] });
|
125
|
+
FormlyNzCascaderModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyNzCascaderModule, imports: [CommonModule,
|
126
|
+
ReactiveFormsModule,
|
127
|
+
FormlyNzFormFieldModule,
|
128
|
+
NzCascaderModule,
|
129
|
+
FormlyModule.forChild({
|
130
|
+
types: [
|
131
|
+
{
|
132
|
+
name: 'cascader',
|
133
|
+
component: FormlyFieldCascader,
|
134
|
+
wrappers: ['form-field']
|
135
|
+
}
|
136
|
+
]
|
137
|
+
})] });
|
138
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyNzCascaderModule, decorators: [{
|
139
|
+
type: NgModule,
|
140
|
+
args: [{
|
141
|
+
declarations: [FormlyFieldCascader],
|
142
|
+
imports: [
|
143
|
+
CommonModule,
|
144
|
+
ReactiveFormsModule,
|
145
|
+
FormlyNzFormFieldModule,
|
146
|
+
NzCascaderModule,
|
147
|
+
FormlyModule.forChild({
|
148
|
+
types: [
|
149
|
+
{
|
150
|
+
name: 'cascader',
|
151
|
+
component: FormlyFieldCascader,
|
152
|
+
wrappers: ['form-field']
|
153
|
+
}
|
154
|
+
]
|
155
|
+
})
|
156
|
+
]
|
157
|
+
}]
|
158
158
|
}] });
|
159
159
|
|
160
|
-
/**
|
161
|
-
* Generated bundle index. Do not edit.
|
160
|
+
/**
|
161
|
+
* Generated bundle index. Do not edit.
|
162
162
|
*/
|
163
163
|
|
164
164
|
export { FormlyFieldCascader, FormlyNzCascaderModule };
|
@@ -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, FormlyFieldConfig } 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';\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: FormlyFieldConfig) => void;\n /**\n * 菜单浮层的显示/隐藏\n */\n visibleChange?: (field: FormlyFieldConfig, visible: boolean) => void;\n\n /**\n * 值发生变化时触发\n */\n selectionChange?: (field: FormlyFieldConfig, value: NzCascaderOption[]) => void;\n}\n\nexport interface FormlyCascaderFieldConfig extends FormlyFieldConfig<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 (ngModelChange)=\"props.change && props.change(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 any;\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;AAvCnD,IAAA,WAAA,GAAA;;QA0CW,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;AACp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C,YAAY;QACZ,mBAAmB;QACnB,uBAAuB;AAEvB,QAAA,gBAAgB,EAAAA,EAAA,CAAA,YAAA,CAAA,EAAA,CAAA,CAAA;AAaP,sBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,sBAAsB,YAjB/B,YAAY;QACZ,mBAAmB;QACnB,uBAAuB;QAEvB,gBAAgB;QAEhB,YAAY,CAAC,QAAQ,CAAC;AACpB,YAAA,KAAK,EAAE;AACL,gBAAA;AACE,oBAAA,IAAI,EAAE,UAAU;AAChB,oBAAA,SAAS,EAAE,mBAAmB;oBAC9B,QAAQ,EAAE,CAAC,YAAY,CAAC;AACzB,iBAAA;AACF,aAAA;SACF,CAAC,CAAA,EAAA,CAAA,CAAA;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;iBACF,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';\r\nimport { FieldType, FieldTypeConfig, FormlyFieldConfig } from '@ngx-formly/core';\r\nimport { FormlyFieldProps } from 'ngx-formly-zorro-antd/form-field';\r\n\r\nimport type {\r\n NzCascaderOption,\r\n NzShowSearchOptions,\r\n NzCascaderExpandTrigger,\r\n NzCascaderSize\r\n} from 'ng-zorro-antd/cascader';\r\nimport type { NzSafeAny, NzStatus, NgStyleInterface } from 'ng-zorro-antd/core/types';\r\n\r\ninterface CascaderProps extends FormlyFieldProps {\r\n /**\r\n * 是否支持清除\r\n * @default true\r\n */\r\n allowClear?: boolean;\r\n\r\n /**\r\n * 是否自动聚焦,当存在输入框时\r\n * @default false\r\n */\r\n autoFocus?: boolean;\r\n\r\n /**\r\n * 浮层是否应带有背景板\r\n * @default false\r\n */\r\n backdrop?: boolean;\r\n\r\n /**\r\n * 点击父级菜单选项时,可通过该函数判断是否允许值的变化\r\n */\r\n changeOn?: (option: NzSafeAny, index: number) => boolean;\r\n\r\n /**\r\n * 当此项为 true 时,点选每级菜单选项值都会发生变化,具体见上面的演示\r\n * @default false\r\n */\r\n changeOnSelect?: boolean;\r\n\r\n /**\r\n * 自定义浮层列类名\r\n */\r\n columnClassName?: string;\r\n\r\n /**\r\n * 自定义次级菜单展开图标\r\n */\r\n expandIcon?: string | TemplateRef<void>;\r\n\r\n /**\r\n * 次级菜单的展开方式\r\n * @default 'click'\r\n */\r\n expandTrigger?: NzCascaderExpandTrigger;\r\n\r\n /**\r\n * 选项的显示值的属性名\r\n * @default 'label'\r\n */\r\n labelProperty: string;\r\n\r\n /**\r\n * 选择后展示的渲染模板\r\n */\r\n labelRender?: TemplateRef<NzSafeAny> | null;\r\n\r\n /**\r\n * 用于动态加载选项。如果提供了ngModel初始值,且未提供nzOptions值,则会立即触发动态加载。\r\n */\r\n loadData?: (option: NzSafeAny, index?: number) => PromiseLike<NzSafeAny>;\r\n\r\n /**\r\n * 自定义浮层类名\r\n */\r\n menuClassName?: string;\r\n\r\n /**\r\n * 自定义浮层样式\r\n */\r\n menuStyle?: NgStyleInterface | null;\r\n\r\n /**\r\n * 当下拉列表为空时显示的内容\r\n */\r\n notFoundContent?: string | TemplateRef<void>;\r\n\r\n /**\r\n * 选项的渲染模板\r\n */\r\n optionRender?: TemplateRef<{ $implicit: NzCascaderOption; index: number }> | null;\r\n\r\n /**\r\n * 是否显示箭头\r\n * @default true\r\n */\r\n showArrow?: boolean;\r\n\r\n /**\r\n * 显示输入框\r\n * @default true\r\n */\r\n showInput?: boolean;\r\n\r\n /**\r\n * 是否支持搜索,默认情况下对 label 进行全匹配搜索,不能和 [nzLoadData] 同时使用\r\n * @default false\r\n */\r\n showSearch?: boolean | NzShowSearchOptions;\r\n\r\n /**\r\n * 输入框大小\r\n * @default default\r\n */\r\n size?: NzCascaderSize;\r\n\r\n /**\r\n * 设置校验状态\r\n */\r\n status?: NzStatus;\r\n\r\n /**\r\n * 自定义的选择框后缀图标\r\n */\r\n suffixIcon?: string | TemplateRef<void>;\r\n\r\n /**\r\n * 选项的实际值的属性名\r\n * @default 'value'\r\n */\r\n valueProperty?: string;\r\n\r\n /**\r\n * 可选项数据源\r\n */\r\n cascaderOptions?: NzCascaderOption[] | null;\r\n\r\n /**\r\n * 清除值时触发\r\n */\r\n onClear?: (field: FormlyFieldConfig) => void;\r\n /**\r\n * 菜单浮层的显示/隐藏\r\n */\r\n visibleChange?: (field: FormlyFieldConfig, visible: boolean) => void;\r\n\r\n /**\r\n * 值发生变化时触发\r\n */\r\n selectionChange?: (field: FormlyFieldConfig, value: NzCascaderOption[]) => void;\r\n}\r\n\r\nexport interface FormlyCascaderFieldConfig extends FormlyFieldConfig<CascaderProps> {\r\n type: 'cascader' | Type<FormlyFieldCascader>;\r\n}\r\n\r\n@Component({\r\n selector: 'formly-field-cascader',\r\n template: `<nz-cascader\r\n #cascader\r\n [nzPlaceHolder]=\"props.placeholder ?? ''\"\r\n [formControl]=\"formControl\"\r\n [formlyAttributes]=\"field\"\r\n [ngClass]=\"props['className']!\"\r\n [nzAllowClear]=\"props['allowClear']!!\"\r\n [nzAutoFocus]=\"props['autoFocus']!!\"\r\n [nzBackdrop]=\"props['backdrop']!!\"\r\n [nzChangeOn]=\"props['changeOn']\"\r\n [nzChangeOnSelect]=\"props['changeOnSelect']!!\"\r\n [nzColumnClassName]=\"props['columnClassName']\"\r\n [nzExpandIcon]=\"props['expandIcon']!\"\r\n [nzExpandTrigger]=\"props['expandTrigger']!\"\r\n [nzLabelProperty]=\"props['labelProperty']\"\r\n [nzLabelRender]=\"props['labelRender'] ?? null\"\r\n [nzLoadData]=\"props['loadData']\"\r\n [nzMenuClassName]=\"props['menuClassName']\"\r\n [nzMenuStyle]=\"props['menuStyle'] ?? null\"\r\n [nzNotFoundContent]=\"props['notFoundContent']\"\r\n [nzOptionRender]=\"props['optionRender'] ?? null\"\r\n [nzOptions]=\"props['cascaderOptions'] ?? null\"\r\n [nzShowArrow]=\"props['showArrow']!!\"\r\n [nzShowInput]=\"props['showInput']!!\"\r\n [nzShowSearch]=\"props['showSearch']!!\"\r\n [nzSize]=\"props['size']!\"\r\n [nzStatus]=\"props['status'] ?? ''\"\r\n [nzSuffixIcon]=\"props['suffixIcon']!\"\r\n [nzValueProperty]=\"props['valueProperty']!\"\r\n (nzClear)=\"props['onClear'] && props['onClear'](field)\"\r\n (nzVisibleChange)=\"props['visibleChange'] && props['visibleChange'](field, $event)\"\r\n (nzSelectionChange)=\"props['selectionChange'] && props['selectionChange'](field, $event)\"\r\n (ngModelChange)=\"props.change && props.change(field, $event)\"\r\n ></nz-cascader>`,\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class FormlyFieldCascader\r\n extends FieldType<FieldTypeConfig<CascaderProps>>\r\n implements OnInit\r\n{\r\n override defaultOptions = {\r\n props: {\r\n placeholder: '请选择',\r\n allowClear: true,\r\n backdrop: false,\r\n changeOnSelect: false,\r\n expandTrigger: 'click' as const,\r\n labelProperty: 'label',\r\n showArrow: true,\r\n showInput: true,\r\n showSearch: false,\r\n size: 'default' as const,\r\n status: '' as const,\r\n valueProperty: 'value',\r\n cascaderOptions: []\r\n }\r\n };\r\n ngOnInit(): void {\r\n const options = this.props['cascaderOptions'];\r\n if (!options || options.length === 0) {\r\n this.props['cascaderOptions'] = this.props.options as any;\r\n }\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormlyModule } from '@ngx-formly/core';\r\nimport { ReactiveFormsModule } from '@angular/forms';\r\nimport { FormlyNzFormFieldModule } from 'ngx-formly-zorro-antd/form-field';\r\n\r\nimport { NzCascaderModule } from 'ng-zorro-antd/cascader';\r\nimport { FormlyFieldCascader } from './cascader.type';\r\n\r\n@NgModule({\r\n declarations: [FormlyFieldCascader],\r\n imports: [\r\n CommonModule,\r\n ReactiveFormsModule,\r\n FormlyNzFormFieldModule,\r\n\r\n NzCascaderModule,\r\n\r\n FormlyModule.forChild({\r\n types: [\r\n {\r\n name: 'cascader',\r\n component: FormlyFieldCascader,\r\n wrappers: ['form-field']\r\n }\r\n ]\r\n })\r\n ]\r\n})\r\nexport class FormlyNzCascaderModule {}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;AAoMM,MAAO,mBACX,SAAQ,SAAyC,CAAA;AAvCnD,IAAA,WAAA,GAAA;;QA0CW,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;AAC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11
|
import { NzCheckboxModule } from 'ng-zorro-antd/checkbox';
|
12
12
|
|
13
|
-
class FormlyFieldCheckbox extends FieldType {
|
14
|
-
constructor() {
|
15
|
-
super(...arguments);
|
16
|
-
this.defaultOptions = {
|
17
|
-
props: {
|
18
|
-
indeterminate: false,
|
19
|
-
hideLabel: true
|
20
|
-
}
|
21
|
-
};
|
22
|
-
}
|
23
|
-
}
|
24
|
-
FormlyFieldCheckbox.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyFieldCheckbox, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
25
|
-
FormlyFieldCheckbox.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.1", type: FormlyFieldCheckbox, selector: "formly-field-checkbox", usesInheritance: true, ngImport: i0, template: `
|
26
|
-
<label
|
27
|
-
*ngIf="props.type !== 'group'; else checkboxgroup"
|
28
|
-
[formControl]="formControl"
|
29
|
-
[formlyAttributes]="field"
|
30
|
-
[nzIndeterminate]="props['indeterminate'] && formControl.value == null"
|
31
|
-
(ngModelChange)="props['modelChange'] && props['modelChange'](field, $event)"
|
32
|
-
nz-checkbox
|
33
|
-
>
|
34
|
-
{{ props.label }}
|
35
|
-
</label>
|
36
|
-
|
37
|
-
<ng-template #checkboxgroup>
|
38
|
-
<nz-checkbox-group
|
39
|
-
[(ngModel)]="props.options"
|
40
|
-
[formControl]="formControl"
|
41
|
-
[formlyAttributes]="field"
|
42
|
-
(ngModelChange)="props['modelChange'] && props['modelChange'](field, $event)"
|
43
|
-
></nz-checkbox-group>
|
44
|
-
</ng-template>
|
45
|
-
`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i3.NzCheckboxComponent, selector: "[nz-checkbox]", inputs: ["nzValue", "nzAutoFocus", "nzDisabled", "nzIndeterminate", "nzChecked", "nzId"], outputs: ["nzCheckedChange"], exportAs: ["nzCheckbox"] }, { kind: "component", type: i3.NzCheckboxGroupComponent, selector: "nz-checkbox-group", inputs: ["nzDisabled"], exportAs: ["nzCheckboxGroup"] }, { kind: "directive", type: i4.ɵFormlyAttributes, selector: "[formlyAttributes]", inputs: ["formlyAttributes", "id"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
46
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyFieldCheckbox, decorators: [{
|
47
|
-
type: Component,
|
48
|
-
args: [{
|
49
|
-
selector: 'formly-field-checkbox',
|
50
|
-
template: `
|
51
|
-
<label
|
52
|
-
*ngIf="props.type !== 'group'; else checkboxgroup"
|
53
|
-
[formControl]="formControl"
|
54
|
-
[formlyAttributes]="field"
|
55
|
-
[nzIndeterminate]="props['indeterminate'] && formControl.value == null"
|
56
|
-
(ngModelChange)="props['modelChange'] && props['modelChange'](field, $event)"
|
57
|
-
nz-checkbox
|
58
|
-
>
|
59
|
-
{{ props.label }}
|
60
|
-
</label>
|
61
|
-
|
62
|
-
<ng-template #checkboxgroup>
|
63
|
-
<nz-checkbox-group
|
64
|
-
[(ngModel)]="props.options"
|
65
|
-
[formControl]="formControl"
|
66
|
-
[formlyAttributes]="field"
|
67
|
-
(ngModelChange)="props['modelChange'] && props['modelChange'](field, $event)"
|
68
|
-
></nz-checkbox-group>
|
69
|
-
</ng-template>
|
70
|
-
`,
|
71
|
-
changeDetection: ChangeDetectionStrategy.OnPush
|
72
|
-
}]
|
13
|
+
class FormlyFieldCheckbox extends FieldType {
|
14
|
+
constructor() {
|
15
|
+
super(...arguments);
|
16
|
+
this.defaultOptions = {
|
17
|
+
props: {
|
18
|
+
indeterminate: false,
|
19
|
+
hideLabel: true
|
20
|
+
}
|
21
|
+
};
|
22
|
+
}
|
23
|
+
}
|
24
|
+
FormlyFieldCheckbox.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyFieldCheckbox, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
25
|
+
FormlyFieldCheckbox.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.1", type: FormlyFieldCheckbox, selector: "formly-field-checkbox", usesInheritance: true, ngImport: i0, template: `
|
26
|
+
<label
|
27
|
+
*ngIf="props.type !== 'group'; else checkboxgroup"
|
28
|
+
[formControl]="formControl"
|
29
|
+
[formlyAttributes]="field"
|
30
|
+
[nzIndeterminate]="props['indeterminate'] && formControl.value == null"
|
31
|
+
(ngModelChange)="props['modelChange'] && props['modelChange'](field, $event)"
|
32
|
+
nz-checkbox
|
33
|
+
>
|
34
|
+
{{ props.label }}
|
35
|
+
</label>
|
36
|
+
|
37
|
+
<ng-template #checkboxgroup>
|
38
|
+
<nz-checkbox-group
|
39
|
+
[(ngModel)]="props.options"
|
40
|
+
[formControl]="formControl"
|
41
|
+
[formlyAttributes]="field"
|
42
|
+
(ngModelChange)="props['modelChange'] && props['modelChange'](field, $event)"
|
43
|
+
></nz-checkbox-group>
|
44
|
+
</ng-template>
|
45
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i3.NzCheckboxComponent, selector: "[nz-checkbox]", inputs: ["nzValue", "nzAutoFocus", "nzDisabled", "nzIndeterminate", "nzChecked", "nzId"], outputs: ["nzCheckedChange"], exportAs: ["nzCheckbox"] }, { kind: "component", type: i3.NzCheckboxGroupComponent, selector: "nz-checkbox-group", inputs: ["nzDisabled"], exportAs: ["nzCheckboxGroup"] }, { kind: "directive", type: i4.ɵFormlyAttributes, selector: "[formlyAttributes]", inputs: ["formlyAttributes", "id"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
46
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyFieldCheckbox, decorators: [{
|
47
|
+
type: Component,
|
48
|
+
args: [{
|
49
|
+
selector: 'formly-field-checkbox',
|
50
|
+
template: `
|
51
|
+
<label
|
52
|
+
*ngIf="props.type !== 'group'; else checkboxgroup"
|
53
|
+
[formControl]="formControl"
|
54
|
+
[formlyAttributes]="field"
|
55
|
+
[nzIndeterminate]="props['indeterminate'] && formControl.value == null"
|
56
|
+
(ngModelChange)="props['modelChange'] && props['modelChange'](field, $event)"
|
57
|
+
nz-checkbox
|
58
|
+
>
|
59
|
+
{{ props.label }}
|
60
|
+
</label>
|
61
|
+
|
62
|
+
<ng-template #checkboxgroup>
|
63
|
+
<nz-checkbox-group
|
64
|
+
[(ngModel)]="props.options"
|
65
|
+
[formControl]="formControl"
|
66
|
+
[formlyAttributes]="field"
|
67
|
+
(ngModelChange)="props['modelChange'] && props['modelChange'](field, $event)"
|
68
|
+
></nz-checkbox-group>
|
69
|
+
</ng-template>
|
70
|
+
`,
|
71
|
+
changeDetection: ChangeDetectionStrategy.OnPush
|
72
|
+
}]
|
73
73
|
}] });
|
74
74
|
|
75
|
-
class FormlyNzCheckboxModule {
|
76
|
-
}
|
77
|
-
FormlyNzCheckboxModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyNzCheckboxModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
78
|
-
FormlyNzCheckboxModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.1", ngImport: i0, type: FormlyNzCheckboxModule, declarations: [FormlyFieldCheckbox], imports: [CommonModule,
|
79
|
-
ReactiveFormsModule,
|
80
|
-
FormlyNzFormFieldModule,
|
81
|
-
NzCheckboxModule, i4.FormlyModule] });
|
82
|
-
FormlyNzCheckboxModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyNzCheckboxModule, imports: [CommonModule,
|
83
|
-
ReactiveFormsModule,
|
84
|
-
FormlyNzFormFieldModule,
|
85
|
-
NzCheckboxModule,
|
86
|
-
FormlyModule.forChild({
|
87
|
-
types: [
|
88
|
-
{
|
89
|
-
name: 'checkbox',
|
90
|
-
component: FormlyFieldCheckbox,
|
91
|
-
wrappers: ['form-field']
|
92
|
-
},
|
93
|
-
{
|
94
|
-
name: 'boolean',
|
95
|
-
extends: 'checkbox'
|
96
|
-
}
|
97
|
-
]
|
98
|
-
})] });
|
99
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyNzCheckboxModule, decorators: [{
|
100
|
-
type: NgModule,
|
101
|
-
args: [{
|
102
|
-
declarations: [FormlyFieldCheckbox],
|
103
|
-
imports: [
|
104
|
-
CommonModule,
|
105
|
-
ReactiveFormsModule,
|
106
|
-
FormlyNzFormFieldModule,
|
107
|
-
NzCheckboxModule,
|
108
|
-
FormlyModule.forChild({
|
109
|
-
types: [
|
110
|
-
{
|
111
|
-
name: 'checkbox',
|
112
|
-
component: FormlyFieldCheckbox,
|
113
|
-
wrappers: ['form-field']
|
114
|
-
},
|
115
|
-
{
|
116
|
-
name: 'boolean',
|
117
|
-
extends: 'checkbox'
|
118
|
-
}
|
119
|
-
]
|
120
|
-
})
|
121
|
-
]
|
122
|
-
}]
|
75
|
+
class FormlyNzCheckboxModule {
|
76
|
+
}
|
77
|
+
FormlyNzCheckboxModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyNzCheckboxModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
78
|
+
FormlyNzCheckboxModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.1", ngImport: i0, type: FormlyNzCheckboxModule, declarations: [FormlyFieldCheckbox], imports: [CommonModule,
|
79
|
+
ReactiveFormsModule,
|
80
|
+
FormlyNzFormFieldModule,
|
81
|
+
NzCheckboxModule, i4.FormlyModule] });
|
82
|
+
FormlyNzCheckboxModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyNzCheckboxModule, imports: [CommonModule,
|
83
|
+
ReactiveFormsModule,
|
84
|
+
FormlyNzFormFieldModule,
|
85
|
+
NzCheckboxModule,
|
86
|
+
FormlyModule.forChild({
|
87
|
+
types: [
|
88
|
+
{
|
89
|
+
name: 'checkbox',
|
90
|
+
component: FormlyFieldCheckbox,
|
91
|
+
wrappers: ['form-field']
|
92
|
+
},
|
93
|
+
{
|
94
|
+
name: 'boolean',
|
95
|
+
extends: 'checkbox'
|
96
|
+
}
|
97
|
+
]
|
98
|
+
})] });
|
99
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: FormlyNzCheckboxModule, decorators: [{
|
100
|
+
type: NgModule,
|
101
|
+
args: [{
|
102
|
+
declarations: [FormlyFieldCheckbox],
|
103
|
+
imports: [
|
104
|
+
CommonModule,
|
105
|
+
ReactiveFormsModule,
|
106
|
+
FormlyNzFormFieldModule,
|
107
|
+
NzCheckboxModule,
|
108
|
+
FormlyModule.forChild({
|
109
|
+
types: [
|
110
|
+
{
|
111
|
+
name: 'checkbox',
|
112
|
+
component: FormlyFieldCheckbox,
|
113
|
+
wrappers: ['form-field']
|
114
|
+
},
|
115
|
+
{
|
116
|
+
name: 'boolean',
|
117
|
+
extends: 'checkbox'
|
118
|
+
}
|
119
|
+
]
|
120
|
+
})
|
121
|
+
]
|
122
|
+
}]
|
123
123
|
}] });
|
124
124
|
|
125
|
-
/**
|
126
|
-
* Generated bundle index. Do not edit.
|
125
|
+
/**
|
126
|
+
* Generated bundle index. Do not edit.
|
127
127
|
*/
|
128
128
|
|
129
129
|
export { FormlyFieldCheckbox, FormlyNzCheckboxModule };
|