ngx-formly-zorro-antd 19.3.3 → 20.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/autocomplete/index.d.ts +39 -5
- package/button/index.d.ts +108 -3
- package/card/index.d.ts +55 -3
- package/card-wrapper/index.d.ts +95 -3
- package/cascader/index.d.ts +199 -3
- package/checkbox/index.d.ts +60 -3
- package/common/index.d.ts +115 -3
- package/datepicker/index.d.ts +211 -3
- package/extension/index.d.ts +25 -3
- package/fesm2022/ngx-formly-zorro-antd-autocomplete.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-button.mjs +136 -139
- package/fesm2022/ngx-formly-zorro-antd-button.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-card-wrapper.mjs +50 -53
- package/fesm2022/ngx-formly-zorro-antd-card-wrapper.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-card.mjs +61 -64
- package/fesm2022/ngx-formly-zorro-antd-card.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-cascader.mjs +85 -85
- package/fesm2022/ngx-formly-zorro-antd-cascader.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-checkbox.mjs +53 -52
- package/fesm2022/ngx-formly-zorro-antd-checkbox.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-common.mjs +7 -7
- package/fesm2022/ngx-formly-zorro-antd-common.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-datepicker.mjs +154 -149
- package/fesm2022/ngx-formly-zorro-antd-datepicker.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-extension.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-flex.mjs +40 -40
- package/fesm2022/ngx-formly-zorro-antd-flex.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-form-field.mjs +155 -158
- package/fesm2022/ngx-formly-zorro-antd-form-field.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-grid.mjs +64 -64
- package/fesm2022/ngx-formly-zorro-antd-grid.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-helpers.mjs +0 -5
- package/fesm2022/ngx-formly-zorro-antd-helpers.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-input-group.mjs +47 -49
- package/fesm2022/ngx-formly-zorro-antd-input-group.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-input-number.mjs +94 -95
- package/fesm2022/ngx-formly-zorro-antd-input-number.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-input-otp.mjs +30 -30
- package/fesm2022/ngx-formly-zorro-antd-input-otp.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-input.mjs +301 -304
- package/fesm2022/ngx-formly-zorro-antd-input.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-radio.mjs +50 -50
- package/fesm2022/ngx-formly-zorro-antd-radio.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-rate.mjs +36 -36
- package/fesm2022/ngx-formly-zorro-antd-rate.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-ref-template.mjs +23 -26
- package/fesm2022/ngx-formly-zorro-antd-ref-template.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-select.mjs +113 -109
- package/fesm2022/ngx-formly-zorro-antd-select.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-slider.mjs +36 -36
- package/fesm2022/ngx-formly-zorro-antd-slider.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-space-compact.mjs +18 -18
- package/fesm2022/ngx-formly-zorro-antd-space-compact.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-space.mjs +38 -41
- package/fesm2022/ngx-formly-zorro-antd-space.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-switch.mjs +30 -30
- package/fesm2022/ngx-formly-zorro-antd-switch.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-tabs.mjs +80 -80
- package/fesm2022/ngx-formly-zorro-antd-tabs.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-text-value.mjs +14 -14
- package/fesm2022/ngx-formly-zorro-antd-text-value.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-textarea.mjs +117 -114
- package/fesm2022/ngx-formly-zorro-antd-textarea.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-timepicker.mjs +68 -65
- package/fesm2022/ngx-formly-zorro-antd-timepicker.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-transfer.mjs +101 -101
- package/fesm2022/ngx-formly-zorro-antd-transfer.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-tree-select.mjs +88 -88
- package/fesm2022/ngx-formly-zorro-antd-tree-select.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-types.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd-upload.mjs +243 -246
- package/fesm2022/ngx-formly-zorro-antd-upload.mjs.map +1 -1
- package/fesm2022/ngx-formly-zorro-antd.mjs +4 -9
- package/fesm2022/ngx-formly-zorro-antd.mjs.map +1 -1
- package/flex/index.d.ts +66 -3
- package/form-field/index.d.ts +217 -3
- package/grid/index.d.ts +84 -3
- package/helpers/index.d.ts +142 -5
- package/index.d.ts +41 -1
- package/input/index.d.ts +93 -3
- package/input-group/index.d.ts +96 -3
- package/input-number/index.d.ts +124 -3
- package/input-otp/index.d.ts +70 -3
- package/package.json +12 -16
- package/radio/index.d.ts +65 -3
- package/rate/index.d.ts +80 -3
- package/ref-template/index.d.ts +95 -3
- package/select/index.d.ts +233 -3
- package/slider/index.d.ts +97 -3
- package/space/index.d.ts +67 -3
- package/space-compact/index.d.ts +54 -3
- package/switch/index.d.ts +63 -3
- package/tabs/index.d.ts +183 -3
- package/text-value/index.d.ts +54 -3
- package/textarea/index.d.ts +64 -3
- package/timepicker/index.d.ts +162 -3
- package/transfer/index.d.ts +162 -3
- package/tree-select/index.d.ts +204 -3
- package/types/index.d.ts +26 -5
- package/upload/index.d.ts +264 -3
- package/autocomplete/autocomplete.props.d.ts +0 -36
- package/autocomplete/public_api.d.ts +0 -1
- package/button/button.config.d.ts +0 -2
- package/button/button.module.d.ts +0 -12
- package/button/button.type.d.ts +0 -93
- package/button/public_api.d.ts +0 -4
- package/button-group/button-group.config.d.ts +0 -2
- package/button-group/button-group.module.d.ts +0 -11
- package/button-group/button-group.type.d.ts +0 -41
- package/button-group/index.d.ts +0 -5
- package/button-group/public_api.d.ts +0 -4
- package/card/card.config.d.ts +0 -2
- package/card/card.module.d.ts +0 -11
- package/card/card.type.d.ts +0 -42
- package/card/public_api.d.ts +0 -4
- package/card-wrapper/card-wrapper.config.d.ts +0 -2
- package/card-wrapper/card-wrapper.module.d.ts +0 -10
- package/card-wrapper/card-wrapper.props.d.ts +0 -58
- package/card-wrapper/card.wrapper.d.ts +0 -27
- package/card-wrapper/public_api.d.ts +0 -5
- package/cascader/cascader.config.d.ts +0 -2
- package/cascader/cascader.module.d.ts +0 -12
- package/cascader/cascader.type.d.ts +0 -182
- package/cascader/public_api.d.ts +0 -4
- package/checkbox/checkbox.config.d.ts +0 -2
- package/checkbox/checkbox.module.d.ts +0 -12
- package/checkbox/checkbox.type.d.ts +0 -41
- package/checkbox/public_api.d.ts +0 -4
- package/common/common.module.d.ts +0 -9
- package/common/formly-box-templates.directive.d.ts +0 -49
- package/common/formly-utils.d.ts +0 -31
- package/common/interface.d.ts +0 -27
- package/common/public_api.d.ts +0 -4
- package/datepicker/datepicker.config.d.ts +0 -2
- package/datepicker/datepicker.module.d.ts +0 -12
- package/datepicker/datepicker.props.d.ts +0 -158
- package/datepicker/datepicker.type.d.ts +0 -36
- package/datepicker/public_api.d.ts +0 -5
- package/extension/public_api.d.ts +0 -1
- package/extension/value-changes-extension.d.ts +0 -23
- package/fesm2022/ngx-formly-zorro-antd-button-group.mjs +0 -158
- package/fesm2022/ngx-formly-zorro-antd-button-group.mjs.map +0 -1
- package/flex/flex.config.d.ts +0 -2
- package/flex/flex.module.d.ts +0 -10
- package/flex/flex.type.d.ts +0 -53
- package/flex/public_api.d.ts +0 -4
- package/form-field/form-field.config.d.ts +0 -2
- package/form-field/form-field.module.d.ts +0 -12
- package/form-field/form-field.props.d.ts +0 -180
- package/form-field/form-field.wrapper.d.ts +0 -25
- package/form-field/public_api.d.ts +0 -4
- package/grid/grid.config.d.ts +0 -2
- package/grid/grid.module.d.ts +0 -10
- package/grid/grid.props.d.ts +0 -59
- package/grid/grid.type.d.ts +0 -15
- package/grid/public_api.d.ts +0 -5
- package/helpers/common.d.ts +0 -7
- package/helpers/formly.d.ts +0 -87
- package/helpers/public_api.d.ts +0 -53
- package/input/input.config.d.ts +0 -2
- package/input/input.module.d.ts +0 -14
- package/input/input.props.d.ts +0 -41
- package/input/input.type.d.ts +0 -35
- package/input/public_api.d.ts +0 -5
- package/input-group/input-group.config.d.ts +0 -2
- package/input-group/input-group.module.d.ts +0 -11
- package/input-group/input-group.props.d.ts +0 -65
- package/input-group/input-group.type.d.ts +0 -24
- package/input-group/public_api.d.ts +0 -5
- package/input-number/input-number.config.d.ts +0 -2
- package/input-number/input-number.module.d.ts +0 -12
- package/input-number/input-number.props.d.ts +0 -85
- package/input-number/input-number.type.d.ts +0 -28
- package/input-number/public_api.d.ts +0 -5
- package/input-otp/input-otp.config.d.ts +0 -2
- package/input-otp/input-otp.module.d.ts +0 -12
- package/input-otp/input-otp.props.d.ts +0 -30
- package/input-otp/input-otp.type.d.ts +0 -25
- package/input-otp/public_api.d.ts +0 -5
- package/lib/ui-ng-zorro-antd.config.d.ts +0 -1
- package/lib/ui-ng-zorro-antd.d.ts +0 -2
- package/lib/ui-ng-zorro-antd.module.d.ts +0 -36
- package/radio/public_api.d.ts +0 -4
- package/radio/radio.config.d.ts +0 -2
- package/radio/radio.module.d.ts +0 -14
- package/radio/radio.type.d.ts +0 -48
- package/rate/public_api.d.ts +0 -4
- package/rate/rate.config.d.ts +0 -2
- package/rate/rate.module.d.ts +0 -12
- package/rate/rate.type.d.ts +0 -65
- package/ref-template/public_api.d.ts +0 -4
- package/ref-template/ref-template.config.d.ts +0 -2
- package/ref-template/ref-template.module.d.ts +0 -11
- package/ref-template/ref-template.type.d.ts +0 -82
- package/select/public_api.d.ts +0 -5
- package/select/select.config.d.ts +0 -2
- package/select/select.module.d.ts +0 -13
- package/select/select.props.d.ts +0 -176
- package/select/select.type.d.ts +0 -38
- package/slider/public_api.d.ts +0 -4
- package/slider/slider.config.d.ts +0 -2
- package/slider/slider.module.d.ts +0 -12
- package/slider/slider.type.d.ts +0 -82
- package/space/public_api.d.ts +0 -4
- package/space/space.config.d.ts +0 -2
- package/space/space.module.d.ts +0 -10
- package/space/space.type.d.ts +0 -55
- package/space-compact/public_api.d.ts +0 -4
- package/space-compact/space-compact.config.d.ts +0 -2
- package/space-compact/space-compact.module.d.ts +0 -10
- package/space-compact/space-compact.type.d.ts +0 -41
- package/switch/public_api.d.ts +0 -4
- package/switch/switch.config.d.ts +0 -2
- package/switch/switch.module.d.ts +0 -12
- package/switch/switch.type.d.ts +0 -48
- package/tabs/public_api.d.ts +0 -4
- package/tabs/tabs.config.d.ts +0 -2
- package/tabs/tabs.module.d.ts +0 -10
- package/tabs/tabs.props.d.ts +0 -143
- package/tabs/tabs.wrapper.d.ts +0 -30
- package/text-value/public_api.d.ts +0 -4
- package/text-value/text-value.config.d.ts +0 -2
- package/text-value/text-value.module.d.ts +0 -11
- package/text-value/text-value.type.d.ts +0 -40
- package/textarea/public_api.d.ts +0 -4
- package/textarea/textarea.config.d.ts +0 -2
- package/textarea/textarea.module.d.ts +0 -13
- package/textarea/textarea.type.d.ts +0 -43
- package/timepicker/public_api.d.ts +0 -4
- package/timepicker/timepicker.config.d.ts +0 -2
- package/timepicker/timepicker.module.d.ts +0 -12
- package/timepicker/timepicker.type.d.ts +0 -143
- package/transfer/public_api.d.ts +0 -4
- package/transfer/transfer.component.d.ts +0 -27
- package/transfer/transfer.config.d.ts +0 -2
- package/transfer/transfer.module.d.ts +0 -13
- package/transfer/transfer.type.d.ts +0 -123
- package/tree-select/public_api.d.ts +0 -4
- package/tree-select/tree-select.config.d.ts +0 -2
- package/tree-select/tree-select.module.d.ts +0 -12
- package/tree-select/tree-select.type.d.ts +0 -187
- package/types/public_api.d.ts +0 -27
- package/upload/public_api.d.ts +0 -5
- package/upload/upload.component.d.ts +0 -37
- package/upload/upload.config.d.ts +0 -2
- package/upload/upload.module.d.ts +0 -15
- package/upload/upload.props.d.ts +0 -183
- package/upload/upload.type.d.ts +0 -36
@@ -1,31 +1,29 @@
|
|
1
1
|
import * as i0 from '@angular/core';
|
2
|
-
import {
|
2
|
+
import { inject, ChangeDetectionStrategy, Component, NgModule } from '@angular/core';
|
3
3
|
import { CommonModule } from '@angular/common';
|
4
|
-
import * as
|
4
|
+
import * as i5 from '@ngx-formly/core';
|
5
5
|
import { FieldType, FormlyModule } from '@ngx-formly/core';
|
6
|
-
import * as
|
6
|
+
import * as i1 from '@angular/forms';
|
7
7
|
import { ReactiveFormsModule } from '@angular/forms';
|
8
8
|
import { FormlyNzFormFieldModule } from 'ngx-formly-zorro-antd/form-field';
|
9
|
-
import * as
|
9
|
+
import * as i2 from 'ng-zorro-antd/input';
|
10
10
|
import { NzInputModule } from 'ng-zorro-antd/input';
|
11
|
-
import * as
|
11
|
+
import * as i3 from 'ng-zorro-antd/auto-complete';
|
12
12
|
import { NzAutocompleteModule } from 'ng-zorro-antd/auto-complete';
|
13
|
-
import * as
|
13
|
+
import * as i4 from 'ng-zorro-antd/icon';
|
14
14
|
import { NzIconModule } from 'ng-zorro-antd/icon';
|
15
|
-
import
|
16
|
-
import { resolveTplName } from 'ngx-formly-zorro-antd/common';
|
15
|
+
import { FormlyBoxTemplates, resolveTplName } from 'ngx-formly-zorro-antd/common';
|
17
16
|
|
18
17
|
/**
|
19
18
|
* @private
|
20
19
|
*/
|
21
20
|
class FormlyFieldInput extends FieldType {
|
22
|
-
constructor(
|
21
|
+
constructor() {
|
23
22
|
super();
|
24
|
-
this.fieldTemplates = fieldTemplates;
|
25
23
|
this.defaultOptions = {
|
26
24
|
props: {
|
27
25
|
borderless: false,
|
28
|
-
|
26
|
+
variant: 'outlined',
|
29
27
|
search: false,
|
30
28
|
allowClear: false,
|
31
29
|
autocompleteOptions: {
|
@@ -36,6 +34,7 @@ class FormlyFieldInput extends FieldType {
|
|
36
34
|
}
|
37
35
|
};
|
38
36
|
this.passVisible = false;
|
37
|
+
this.fieldTemplates = inject(FormlyBoxTemplates, { optional: true });
|
39
38
|
}
|
40
39
|
get addOnBefore() {
|
41
40
|
return resolveTplName(this.props, this.fieldTemplates, 'addOnBefore');
|
@@ -43,302 +42,300 @@ class FormlyFieldInput extends FieldType {
|
|
43
42
|
get addOnAfter() {
|
44
43
|
return resolveTplName(this.props, this.fieldTemplates, 'addOnAfter');
|
45
44
|
}
|
46
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
47
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
48
|
-
@switch (props.type) {
|
49
|
-
@case ('password') {
|
50
|
-
<nz-input-group
|
51
|
-
[nzPrefixIcon]="props['prefixIcon']"
|
52
|
-
[nzSuffixIcon]="props['suffixIcon']"
|
53
|
-
[nzAddOnAfterIcon]="props['addOnAfterIcon']"
|
54
|
-
[nzAddOnBeforeIcon]="props['addOnBeforeIcon']"
|
55
|
-
[nzAddOnBefore]="addOnBefore"
|
56
|
-
[nzAddOnAfter]="addOnAfter"
|
57
|
-
[class]="props['className']"
|
58
|
-
[style]="props['style']"
|
59
|
-
[nzPrefix]="props['prefix']"
|
60
|
-
[
|
61
|
-
[
|
62
|
-
[
|
63
|
-
[
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
[
|
70
|
-
[
|
71
|
-
[
|
72
|
-
(ngModelChange)="props['modelChange']?.(field, $event)"
|
73
|
-
/>
|
74
|
-
</nz-input-group>
|
75
|
-
}
|
76
|
-
@case ('autoComplete') {
|
77
|
-
<nz-input-group
|
78
|
-
[nzSize]="props['size']"
|
79
|
-
[nzPrefixIcon]="props['prefixIcon']"
|
80
|
-
[nzSuffixIcon]="props['suffixIcon']"
|
81
|
-
[nzAddOnAfterIcon]="props['addOnAfterIcon']"
|
82
|
-
[nzAddOnBeforeIcon]="props['addOnBeforeIcon']"
|
83
|
-
[nzAddOnBefore]="addOnBefore"
|
84
|
-
[nzAddOnAfter]="addOnAfter"
|
85
|
-
[class]="props['className']"
|
86
|
-
[style]="props['style']"
|
87
|
-
[nzPrefix]="props['prefix']"
|
88
|
-
[nzSuffix]="props['allowClear'] ? inputClearTpl : props['suffix']"
|
89
|
-
>
|
90
|
-
<input
|
91
|
-
nz-input
|
92
|
-
[nzBorderless]="!!props['borderless']"
|
93
|
-
[
|
94
|
-
[
|
95
|
-
[
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
[
|
100
|
-
[
|
101
|
-
[
|
102
|
-
[
|
103
|
-
[
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
[
|
118
|
-
[
|
119
|
-
[
|
120
|
-
[
|
121
|
-
[
|
122
|
-
[
|
123
|
-
[
|
124
|
-
[
|
125
|
-
[
|
126
|
-
[
|
127
|
-
[nzSearch]="!!props['search']"
|
128
|
-
[nzSize]="props['size']!"
|
129
|
-
[nzStatus]="props['status']!"
|
130
|
-
>
|
131
|
-
<input
|
132
|
-
nz-input
|
133
|
-
type="text"
|
134
|
-
[formControl]="formControl"
|
135
|
-
[formlyAttributes]="field"
|
136
|
-
[nzBorderless]="!!props['borderless']"
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
[
|
147
|
-
[
|
148
|
-
[
|
149
|
-
[
|
150
|
-
[
|
151
|
-
[
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
class="ant-input-clear-icon"
|
182
|
-
nzTheme="fill"
|
183
|
-
nzType="close-circle"
|
184
|
-
(click)="formControl.setValue(undefined)"
|
185
|
-
|
186
|
-
}
|
187
|
-
</ng-template>
|
188
|
-
`, isInline: true, dependencies: [{ kind: "directive", type:
|
45
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: FormlyFieldInput, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
46
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.0.6", type: FormlyFieldInput, isStandalone: false, selector: "formly-field-input", usesInheritance: true, ngImport: i0, template: `
|
47
|
+
@switch (props.type) {
|
48
|
+
@case ('password') {
|
49
|
+
<nz-input-group
|
50
|
+
[nzPrefixIcon]="props['prefixIcon']"
|
51
|
+
[nzSuffixIcon]="props['suffixIcon']"
|
52
|
+
[nzAddOnAfterIcon]="props['addOnAfterIcon']"
|
53
|
+
[nzAddOnBeforeIcon]="props['addOnBeforeIcon']"
|
54
|
+
[nzAddOnBefore]="addOnBefore"
|
55
|
+
[nzAddOnAfter]="addOnAfter"
|
56
|
+
[class]="props['className']"
|
57
|
+
[style]="props['style']"
|
58
|
+
[nzPrefix]="props['prefix']"
|
59
|
+
[nzSearch]="!!props['search']"
|
60
|
+
[nzSize]="props['size']!"
|
61
|
+
[nzStatus]="props['status']!"
|
62
|
+
[nzSuffix]="passwordEyeTpl"
|
63
|
+
>
|
64
|
+
<input
|
65
|
+
[type]="passVisible ? 'text' : 'password'"
|
66
|
+
nz-input
|
67
|
+
[formControl]="formControl"
|
68
|
+
[formlyAttributes]="field"
|
69
|
+
[nzBorderless]="!!props['borderless']"
|
70
|
+
[nzVariant]="props['variant']"
|
71
|
+
(ngModelChange)="props['modelChange']?.(field, $event)"
|
72
|
+
/>
|
73
|
+
</nz-input-group>
|
74
|
+
}
|
75
|
+
@case ('autoComplete') {
|
76
|
+
<nz-input-group
|
77
|
+
[nzSize]="props['size']"
|
78
|
+
[nzPrefixIcon]="props['prefixIcon']"
|
79
|
+
[nzSuffixIcon]="props['suffixIcon']"
|
80
|
+
[nzAddOnAfterIcon]="props['addOnAfterIcon']"
|
81
|
+
[nzAddOnBeforeIcon]="props['addOnBeforeIcon']"
|
82
|
+
[nzAddOnBefore]="addOnBefore"
|
83
|
+
[nzAddOnAfter]="addOnAfter"
|
84
|
+
[class]="props['className']"
|
85
|
+
[style]="props['style']"
|
86
|
+
[nzPrefix]="props['prefix']"
|
87
|
+
[nzSuffix]="props['allowClear'] ? inputClearTpl : props['suffix']"
|
88
|
+
>
|
89
|
+
<input
|
90
|
+
nz-input
|
91
|
+
[nzBorderless]="!!props['borderless']"
|
92
|
+
[nzVariant]="props['variant']"
|
93
|
+
[nzAutocomplete]="auto"
|
94
|
+
[formControl]="formControl"
|
95
|
+
[formlyAttributes]="field"
|
96
|
+
/>
|
97
|
+
<nz-autocomplete
|
98
|
+
[nzBackfill]="props['autocompleteOptions']?.backfill"
|
99
|
+
[nzDefaultActiveFirstOption]="props['autocompleteOptions']?.defaultActiveFirstOption"
|
100
|
+
[nzWidth]="props['autocompleteOptions']?.width"
|
101
|
+
[nzOverlayClassName]="props['autocompleteOptions']?.overlayClassName"
|
102
|
+
[nzOverlayStyle]="props['autocompleteOptions']?.overlayStyle"
|
103
|
+
[compareWith]="props['autocompleteOptions']?.compareWith"
|
104
|
+
#auto
|
105
|
+
>
|
106
|
+
@for (option of props['autocompleteOptions'].dataSource; track option) {
|
107
|
+
<nz-auto-option [nzLabel]="option.label" [nzValue]="option.value" [attr.title]="option.label">
|
108
|
+
{{ option.label }}
|
109
|
+
</nz-auto-option>
|
110
|
+
}
|
111
|
+
</nz-autocomplete>
|
112
|
+
</nz-input-group>
|
113
|
+
}
|
114
|
+
@case ('group') {
|
115
|
+
<nz-input-group
|
116
|
+
[nzPrefixIcon]="props['prefixIcon']"
|
117
|
+
[nzSuffixIcon]="props['suffixIcon']"
|
118
|
+
[nzAddOnAfterIcon]="props['addOnAfterIcon']"
|
119
|
+
[nzAddOnBeforeIcon]="props['addOnBeforeIcon']"
|
120
|
+
[nzAddOnBefore]="addOnBefore"
|
121
|
+
[nzAddOnAfter]="addOnAfter"
|
122
|
+
[class]="props['className']"
|
123
|
+
[style]="props['style']"
|
124
|
+
[nzPrefix]="props['prefix']"
|
125
|
+
[nzSuffix]="props['allowClear'] ? inputClearTpl : props['suffix']"
|
126
|
+
[nzSearch]="!!props['search']"
|
127
|
+
[nzSize]="props['size']!"
|
128
|
+
[nzStatus]="props['status']!"
|
129
|
+
>
|
130
|
+
<input
|
131
|
+
nz-input
|
132
|
+
type="text"
|
133
|
+
[formControl]="formControl"
|
134
|
+
[formlyAttributes]="field"
|
135
|
+
[nzBorderless]="!!props['borderless']"
|
136
|
+
[nzVariant]="props['variant']"
|
137
|
+
(ngModelChange)="props['modelChange']?.(field, $event)"
|
138
|
+
/>
|
139
|
+
</nz-input-group>
|
140
|
+
}
|
141
|
+
@default {
|
142
|
+
<input
|
143
|
+
nz-input
|
144
|
+
type="text"
|
145
|
+
[class]="props['className']"
|
146
|
+
[style]="props['style']"
|
147
|
+
[formControl]="formControl"
|
148
|
+
[formlyAttributes]="field"
|
149
|
+
[nzSize]="props['size']"
|
150
|
+
[nzStatus]="props['status']"
|
151
|
+
[nzBorderless]="!!props['borderless']"
|
152
|
+
[nzVariant]="props['variant']"
|
153
|
+
(ngModelChange)="props['modelChange']?.(field, $event)"
|
154
|
+
/>
|
155
|
+
}
|
156
|
+
}
|
157
|
+
|
158
|
+
<!-- 查看密码 -->
|
159
|
+
<ng-template #passwordEyeTpl>
|
160
|
+
<nz-icon
|
161
|
+
nz-icon
|
162
|
+
class="cursor-pointer"
|
163
|
+
[nzType]="passVisible ? 'eye-invisible' : 'eye'"
|
164
|
+
(click)="passVisible = !passVisible"
|
165
|
+
/>
|
166
|
+
|
167
|
+
@if (formControl.value && props['allowClear']!!) {
|
168
|
+
<nz-icon
|
169
|
+
class="ant-input-clear-icon"
|
170
|
+
nzTheme="fill"
|
171
|
+
nzType="close-circle"
|
172
|
+
(click)="formControl.setValue(undefined)"
|
173
|
+
/>
|
174
|
+
}
|
175
|
+
</ng-template>
|
176
|
+
<!-- 清除数据 -->
|
177
|
+
<ng-template #inputClearTpl>
|
178
|
+
@if (formControl.value && !props['disabled'] && !props['readonly']) {
|
179
|
+
<nz-icon
|
180
|
+
class="ant-input-clear-icon"
|
181
|
+
nzTheme="fill"
|
182
|
+
nzType="close-circle"
|
183
|
+
(click)="formControl.setValue(undefined)"
|
184
|
+
/>
|
185
|
+
}
|
186
|
+
</ng-template>
|
187
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.NzInputDirective, selector: "input[nz-input],textarea[nz-input]", inputs: ["nzBorderless", "nzVariant", "nzSize", "nzStepperless", "nzStatus", "disabled"], exportAs: ["nzInput"] }, { kind: "component", type: i2.NzInputGroupComponent, selector: "nz-input-group", inputs: ["nzAddOnBeforeIcon", "nzAddOnAfterIcon", "nzPrefixIcon", "nzSuffixIcon", "nzAddOnBefore", "nzAddOnAfter", "nzPrefix", "nzStatus", "nzSuffix", "nzSize", "nzSearch"], exportAs: ["nzInputGroup"] }, { kind: "directive", type: i2.NzInputGroupWhitSuffixOrPrefixDirective, selector: "nz-input-group[nzSuffix], nz-input-group[nzPrefix]" }, { kind: "component", type: i3.NzAutocompleteComponent, selector: "nz-autocomplete", inputs: ["nzWidth", "nzOverlayClassName", "nzOverlayStyle", "nzDefaultActiveFirstOption", "nzBackfill", "compareWith", "nzDataSource"], outputs: ["selectionChange"], exportAs: ["nzAutocomplete"] }, { kind: "component", type: i3.NzAutocompleteOptionComponent, selector: "nz-auto-option", inputs: ["nzValue", "nzLabel", "nzDisabled"], outputs: ["selectionChange", "mouseEntered"], exportAs: ["nzAutoOption"] }, { kind: "directive", type: i3.NzAutocompleteTriggerDirective, selector: "input[nzAutocomplete], textarea[nzAutocomplete]", inputs: ["nzAutocomplete"], exportAs: ["nzAutocompleteTrigger"] }, { kind: "directive", type: i4.NzIconDirective, selector: "nz-icon,[nz-icon]", inputs: ["nzSpin", "nzRotate", "nzType", "nzTheme", "nzTwotoneColor", "nzIconfont"], exportAs: ["nzIcon"] }, { kind: "directive", type: i5.ɵFormlyAttributes, selector: "[formlyAttributes]", inputs: ["formlyAttributes", "id"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
189
188
|
}
|
190
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
189
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: FormlyFieldInput, decorators: [{
|
191
190
|
type: Component,
|
192
191
|
args: [{
|
193
192
|
selector: 'formly-field-input',
|
194
|
-
template: `
|
195
|
-
@switch (props.type) {
|
196
|
-
@case ('password') {
|
197
|
-
<nz-input-group
|
198
|
-
[nzPrefixIcon]="props['prefixIcon']"
|
199
|
-
[nzSuffixIcon]="props['suffixIcon']"
|
200
|
-
[nzAddOnAfterIcon]="props['addOnAfterIcon']"
|
201
|
-
[nzAddOnBeforeIcon]="props['addOnBeforeIcon']"
|
202
|
-
[nzAddOnBefore]="addOnBefore"
|
203
|
-
[nzAddOnAfter]="addOnAfter"
|
204
|
-
[class]="props['className']"
|
205
|
-
[style]="props['style']"
|
206
|
-
[nzPrefix]="props['prefix']"
|
207
|
-
[
|
208
|
-
[
|
209
|
-
[
|
210
|
-
[
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
215
|
-
|
216
|
-
[
|
217
|
-
[
|
218
|
-
[
|
219
|
-
(ngModelChange)="props['modelChange']?.(field, $event)"
|
220
|
-
/>
|
221
|
-
</nz-input-group>
|
222
|
-
}
|
223
|
-
@case ('autoComplete') {
|
224
|
-
<nz-input-group
|
225
|
-
[nzSize]="props['size']"
|
226
|
-
[nzPrefixIcon]="props['prefixIcon']"
|
227
|
-
[nzSuffixIcon]="props['suffixIcon']"
|
228
|
-
[nzAddOnAfterIcon]="props['addOnAfterIcon']"
|
229
|
-
[nzAddOnBeforeIcon]="props['addOnBeforeIcon']"
|
230
|
-
[nzAddOnBefore]="addOnBefore"
|
231
|
-
[nzAddOnAfter]="addOnAfter"
|
232
|
-
[class]="props['className']"
|
233
|
-
[style]="props['style']"
|
234
|
-
[nzPrefix]="props['prefix']"
|
235
|
-
[nzSuffix]="props['allowClear'] ? inputClearTpl : props['suffix']"
|
236
|
-
>
|
237
|
-
<input
|
238
|
-
nz-input
|
239
|
-
[nzBorderless]="!!props['borderless']"
|
240
|
-
[
|
241
|
-
[
|
242
|
-
[
|
243
|
-
|
244
|
-
|
245
|
-
|
246
|
-
[
|
247
|
-
[
|
248
|
-
[
|
249
|
-
[
|
250
|
-
[
|
251
|
-
|
252
|
-
|
253
|
-
|
254
|
-
|
255
|
-
|
256
|
-
|
257
|
-
|
258
|
-
|
259
|
-
|
260
|
-
|
261
|
-
|
262
|
-
|
263
|
-
|
264
|
-
[
|
265
|
-
[
|
266
|
-
[
|
267
|
-
[
|
268
|
-
[
|
269
|
-
[
|
270
|
-
[
|
271
|
-
[
|
272
|
-
[
|
273
|
-
[
|
274
|
-
[nzSearch]="!!props['search']"
|
275
|
-
[nzSize]="props['size']!"
|
276
|
-
[nzStatus]="props['status']!"
|
277
|
-
>
|
278
|
-
<input
|
279
|
-
nz-input
|
280
|
-
type="text"
|
281
|
-
[formControl]="formControl"
|
282
|
-
[formlyAttributes]="field"
|
283
|
-
[nzBorderless]="!!props['borderless']"
|
284
|
-
|
285
|
-
|
286
|
-
|
287
|
-
|
288
|
-
|
289
|
-
|
290
|
-
|
291
|
-
|
292
|
-
|
293
|
-
[
|
294
|
-
[
|
295
|
-
[
|
296
|
-
[
|
297
|
-
[
|
298
|
-
[
|
299
|
-
|
300
|
-
|
301
|
-
|
302
|
-
|
303
|
-
|
304
|
-
|
305
|
-
|
306
|
-
|
307
|
-
|
308
|
-
|
309
|
-
|
310
|
-
|
311
|
-
|
312
|
-
|
313
|
-
|
314
|
-
|
315
|
-
|
316
|
-
|
317
|
-
|
318
|
-
|
319
|
-
|
320
|
-
|
321
|
-
|
322
|
-
|
323
|
-
|
324
|
-
|
325
|
-
|
326
|
-
|
327
|
-
|
328
|
-
class="ant-input-clear-icon"
|
329
|
-
nzTheme="fill"
|
330
|
-
nzType="close-circle"
|
331
|
-
(click)="formControl.setValue(undefined)"
|
332
|
-
|
333
|
-
}
|
334
|
-
</ng-template>
|
193
|
+
template: `
|
194
|
+
@switch (props.type) {
|
195
|
+
@case ('password') {
|
196
|
+
<nz-input-group
|
197
|
+
[nzPrefixIcon]="props['prefixIcon']"
|
198
|
+
[nzSuffixIcon]="props['suffixIcon']"
|
199
|
+
[nzAddOnAfterIcon]="props['addOnAfterIcon']"
|
200
|
+
[nzAddOnBeforeIcon]="props['addOnBeforeIcon']"
|
201
|
+
[nzAddOnBefore]="addOnBefore"
|
202
|
+
[nzAddOnAfter]="addOnAfter"
|
203
|
+
[class]="props['className']"
|
204
|
+
[style]="props['style']"
|
205
|
+
[nzPrefix]="props['prefix']"
|
206
|
+
[nzSearch]="!!props['search']"
|
207
|
+
[nzSize]="props['size']!"
|
208
|
+
[nzStatus]="props['status']!"
|
209
|
+
[nzSuffix]="passwordEyeTpl"
|
210
|
+
>
|
211
|
+
<input
|
212
|
+
[type]="passVisible ? 'text' : 'password'"
|
213
|
+
nz-input
|
214
|
+
[formControl]="formControl"
|
215
|
+
[formlyAttributes]="field"
|
216
|
+
[nzBorderless]="!!props['borderless']"
|
217
|
+
[nzVariant]="props['variant']"
|
218
|
+
(ngModelChange)="props['modelChange']?.(field, $event)"
|
219
|
+
/>
|
220
|
+
</nz-input-group>
|
221
|
+
}
|
222
|
+
@case ('autoComplete') {
|
223
|
+
<nz-input-group
|
224
|
+
[nzSize]="props['size']"
|
225
|
+
[nzPrefixIcon]="props['prefixIcon']"
|
226
|
+
[nzSuffixIcon]="props['suffixIcon']"
|
227
|
+
[nzAddOnAfterIcon]="props['addOnAfterIcon']"
|
228
|
+
[nzAddOnBeforeIcon]="props['addOnBeforeIcon']"
|
229
|
+
[nzAddOnBefore]="addOnBefore"
|
230
|
+
[nzAddOnAfter]="addOnAfter"
|
231
|
+
[class]="props['className']"
|
232
|
+
[style]="props['style']"
|
233
|
+
[nzPrefix]="props['prefix']"
|
234
|
+
[nzSuffix]="props['allowClear'] ? inputClearTpl : props['suffix']"
|
235
|
+
>
|
236
|
+
<input
|
237
|
+
nz-input
|
238
|
+
[nzBorderless]="!!props['borderless']"
|
239
|
+
[nzVariant]="props['variant']"
|
240
|
+
[nzAutocomplete]="auto"
|
241
|
+
[formControl]="formControl"
|
242
|
+
[formlyAttributes]="field"
|
243
|
+
/>
|
244
|
+
<nz-autocomplete
|
245
|
+
[nzBackfill]="props['autocompleteOptions']?.backfill"
|
246
|
+
[nzDefaultActiveFirstOption]="props['autocompleteOptions']?.defaultActiveFirstOption"
|
247
|
+
[nzWidth]="props['autocompleteOptions']?.width"
|
248
|
+
[nzOverlayClassName]="props['autocompleteOptions']?.overlayClassName"
|
249
|
+
[nzOverlayStyle]="props['autocompleteOptions']?.overlayStyle"
|
250
|
+
[compareWith]="props['autocompleteOptions']?.compareWith"
|
251
|
+
#auto
|
252
|
+
>
|
253
|
+
@for (option of props['autocompleteOptions'].dataSource; track option) {
|
254
|
+
<nz-auto-option [nzLabel]="option.label" [nzValue]="option.value" [attr.title]="option.label">
|
255
|
+
{{ option.label }}
|
256
|
+
</nz-auto-option>
|
257
|
+
}
|
258
|
+
</nz-autocomplete>
|
259
|
+
</nz-input-group>
|
260
|
+
}
|
261
|
+
@case ('group') {
|
262
|
+
<nz-input-group
|
263
|
+
[nzPrefixIcon]="props['prefixIcon']"
|
264
|
+
[nzSuffixIcon]="props['suffixIcon']"
|
265
|
+
[nzAddOnAfterIcon]="props['addOnAfterIcon']"
|
266
|
+
[nzAddOnBeforeIcon]="props['addOnBeforeIcon']"
|
267
|
+
[nzAddOnBefore]="addOnBefore"
|
268
|
+
[nzAddOnAfter]="addOnAfter"
|
269
|
+
[class]="props['className']"
|
270
|
+
[style]="props['style']"
|
271
|
+
[nzPrefix]="props['prefix']"
|
272
|
+
[nzSuffix]="props['allowClear'] ? inputClearTpl : props['suffix']"
|
273
|
+
[nzSearch]="!!props['search']"
|
274
|
+
[nzSize]="props['size']!"
|
275
|
+
[nzStatus]="props['status']!"
|
276
|
+
>
|
277
|
+
<input
|
278
|
+
nz-input
|
279
|
+
type="text"
|
280
|
+
[formControl]="formControl"
|
281
|
+
[formlyAttributes]="field"
|
282
|
+
[nzBorderless]="!!props['borderless']"
|
283
|
+
[nzVariant]="props['variant']"
|
284
|
+
(ngModelChange)="props['modelChange']?.(field, $event)"
|
285
|
+
/>
|
286
|
+
</nz-input-group>
|
287
|
+
}
|
288
|
+
@default {
|
289
|
+
<input
|
290
|
+
nz-input
|
291
|
+
type="text"
|
292
|
+
[class]="props['className']"
|
293
|
+
[style]="props['style']"
|
294
|
+
[formControl]="formControl"
|
295
|
+
[formlyAttributes]="field"
|
296
|
+
[nzSize]="props['size']"
|
297
|
+
[nzStatus]="props['status']"
|
298
|
+
[nzBorderless]="!!props['borderless']"
|
299
|
+
[nzVariant]="props['variant']"
|
300
|
+
(ngModelChange)="props['modelChange']?.(field, $event)"
|
301
|
+
/>
|
302
|
+
}
|
303
|
+
}
|
304
|
+
|
305
|
+
<!-- 查看密码 -->
|
306
|
+
<ng-template #passwordEyeTpl>
|
307
|
+
<nz-icon
|
308
|
+
nz-icon
|
309
|
+
class="cursor-pointer"
|
310
|
+
[nzType]="passVisible ? 'eye-invisible' : 'eye'"
|
311
|
+
(click)="passVisible = !passVisible"
|
312
|
+
/>
|
313
|
+
|
314
|
+
@if (formControl.value && props['allowClear']!!) {
|
315
|
+
<nz-icon
|
316
|
+
class="ant-input-clear-icon"
|
317
|
+
nzTheme="fill"
|
318
|
+
nzType="close-circle"
|
319
|
+
(click)="formControl.setValue(undefined)"
|
320
|
+
/>
|
321
|
+
}
|
322
|
+
</ng-template>
|
323
|
+
<!-- 清除数据 -->
|
324
|
+
<ng-template #inputClearTpl>
|
325
|
+
@if (formControl.value && !props['disabled'] && !props['readonly']) {
|
326
|
+
<nz-icon
|
327
|
+
class="ant-input-clear-icon"
|
328
|
+
nzTheme="fill"
|
329
|
+
nzType="close-circle"
|
330
|
+
(click)="formControl.setValue(undefined)"
|
331
|
+
/>
|
332
|
+
}
|
333
|
+
</ng-template>
|
335
334
|
`,
|
336
335
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
337
336
|
standalone: false
|
338
337
|
}]
|
339
|
-
}], ctorParameters: () => [
|
340
|
-
type: Optional
|
341
|
-
}] }] });
|
338
|
+
}], ctorParameters: () => [] });
|
342
339
|
|
343
340
|
function withFormlyFieldInput() {
|
344
341
|
return {
|
@@ -368,14 +365,14 @@ function withFormlyFieldInput() {
|
|
368
365
|
}
|
369
366
|
|
370
367
|
class FormlyNzInputModule {
|
371
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
372
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "
|
368
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: FormlyNzInputModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
369
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.0.6", ngImport: i0, type: FormlyNzInputModule, declarations: [FormlyFieldInput], imports: [CommonModule,
|
373
370
|
ReactiveFormsModule,
|
374
371
|
NzInputModule,
|
375
372
|
NzAutocompleteModule,
|
376
373
|
NzIconModule,
|
377
|
-
FormlyNzFormFieldModule,
|
378
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
374
|
+
FormlyNzFormFieldModule, i5.FormlyModule] }); }
|
375
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: FormlyNzInputModule, imports: [CommonModule,
|
379
376
|
ReactiveFormsModule,
|
380
377
|
NzInputModule,
|
381
378
|
NzAutocompleteModule,
|
@@ -383,7 +380,7 @@ class FormlyNzInputModule {
|
|
383
380
|
FormlyNzFormFieldModule,
|
384
381
|
FormlyModule.forChild(withFormlyFieldInput())] }); }
|
385
382
|
}
|
386
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
383
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: FormlyNzInputModule, decorators: [{
|
387
384
|
type: NgModule,
|
388
385
|
args: [{
|
389
386
|
declarations: [FormlyFieldInput],
|