@ngx-formly/bootstrap 10.0.1 → 11.1.0-rc.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 +88 -177
- package/fesm2022/ngx-formly-bootstrap-addons.mjs +150 -65
- package/fesm2022/ngx-formly-bootstrap-addons.mjs.map +1 -1
- package/fesm2022/ngx-formly-bootstrap-checkbox.mjs +173 -79
- package/fesm2022/ngx-formly-bootstrap-checkbox.mjs.map +1 -1
- package/fesm2022/ngx-formly-bootstrap-form-field.mjs +204 -72
- package/fesm2022/ngx-formly-bootstrap-form-field.mjs.map +1 -1
- package/fesm2022/ngx-formly-bootstrap-input.mjs +169 -84
- package/fesm2022/ngx-formly-bootstrap-input.mjs.map +1 -1
- package/fesm2022/ngx-formly-bootstrap-multicheckbox.mjs +161 -91
- package/fesm2022/ngx-formly-bootstrap-multicheckbox.mjs.map +1 -1
- package/fesm2022/ngx-formly-bootstrap-radio.mjs +181 -79
- package/fesm2022/ngx-formly-bootstrap-radio.mjs.map +1 -1
- package/fesm2022/ngx-formly-bootstrap-select.mjs +189 -79
- package/fesm2022/ngx-formly-bootstrap-select.mjs.map +1 -1
- package/fesm2022/ngx-formly-bootstrap-textarea.mjs +152 -71
- package/fesm2022/ngx-formly-bootstrap-textarea.mjs.map +1 -1
- package/fesm2022/ngx-formly-bootstrap.mjs +89 -66
- package/fesm2022/ngx-formly-bootstrap.mjs.map +1 -1
- package/package.json +2 -2
- package/types/ngx-formly-bootstrap-addons.d.ts +30 -34
- package/types/ngx-formly-bootstrap-checkbox.d.ts +27 -32
- package/types/ngx-formly-bootstrap-form-field.d.ts +26 -30
- package/types/ngx-formly-bootstrap-input.d.ts +21 -27
- package/types/ngx-formly-bootstrap-multicheckbox.d.ts +27 -32
- package/types/ngx-formly-bootstrap-radio.d.ts +27 -32
- package/types/ngx-formly-bootstrap-select.d.ts +27 -32
- package/types/ngx-formly-bootstrap-textarea.d.ts +26 -31
- package/types/ngx-formly-bootstrap.d.ts +16 -20
|
@@ -1,28 +1,41 @@
|
|
|
1
|
-
import * as i0 from
|
|
2
|
-
import { ChangeDetectionStrategy, Component, NgModule } from
|
|
3
|
-
import { FieldType, FormlyBootstrapFormFieldModule } from
|
|
4
|
-
import * as i1 from
|
|
5
|
-
import { ReactiveFormsModule } from
|
|
6
|
-
import * as i2 from
|
|
7
|
-
import { FormlyModule } from
|
|
8
|
-
import * as i3 from
|
|
9
|
-
import { CommonModule } from
|
|
10
|
-
import * as i4 from
|
|
11
|
-
import { FormlySelectModule } from
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import { ChangeDetectionStrategy, Component, NgModule } from "@angular/core";
|
|
3
|
+
import { FieldType, FormlyBootstrapFormFieldModule } from "@ngx-formly/bootstrap/form-field";
|
|
4
|
+
import * as i1 from "@angular/forms";
|
|
5
|
+
import { ReactiveFormsModule } from "@angular/forms";
|
|
6
|
+
import * as i2 from "@ngx-formly/core";
|
|
7
|
+
import { FormlyModule } from "@ngx-formly/core";
|
|
8
|
+
import * as i3 from "@angular/common";
|
|
9
|
+
import { CommonModule } from "@angular/common";
|
|
10
|
+
import * as i4 from "@ngx-formly/core/select";
|
|
11
|
+
import { FormlySelectModule } from "@ngx-formly/core/select";
|
|
12
|
+
var FormlyFieldSelect = class FormlyFieldSelect extends FieldType {
|
|
13
|
+
constructor() {
|
|
14
|
+
super(...arguments);
|
|
15
|
+
this.defaultOptions = { props: { compareWith(o1, o2) {
|
|
16
|
+
return o1 === o2;
|
|
17
|
+
} } };
|
|
18
|
+
}
|
|
19
|
+
static {
|
|
20
|
+
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
21
|
+
minVersion: "12.0.0",
|
|
22
|
+
version: "22.2.2",
|
|
23
|
+
ngImport: i0,
|
|
24
|
+
type: FormlyFieldSelect,
|
|
25
|
+
deps: null,
|
|
26
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
27
|
+
});
|
|
28
|
+
}
|
|
29
|
+
static {
|
|
30
|
+
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
31
|
+
minVersion: "17.0.0",
|
|
32
|
+
version: "22.2.2",
|
|
33
|
+
type: FormlyFieldSelect,
|
|
34
|
+
isStandalone: false,
|
|
35
|
+
selector: "formly-field-select",
|
|
36
|
+
usesInheritance: true,
|
|
37
|
+
ngImport: i0,
|
|
38
|
+
template: `
|
|
26
39
|
<ng-template #fieldTypeTemplate>
|
|
27
40
|
@if (props.multiple) {
|
|
28
41
|
<select
|
|
@@ -86,13 +99,80 @@ class FormlyFieldSelect extends FieldType {
|
|
|
86
99
|
</select>
|
|
87
100
|
}
|
|
88
101
|
</ng-template>
|
|
89
|
-
`,
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
102
|
+
`,
|
|
103
|
+
isInline: true,
|
|
104
|
+
dependencies: [
|
|
105
|
+
{
|
|
106
|
+
kind: "directive",
|
|
107
|
+
type: i1.NgSelectOption,
|
|
108
|
+
selector: "option",
|
|
109
|
+
inputs: ["ngValue", "value"]
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
kind: "directive",
|
|
113
|
+
type: i1.ɵNgSelectMultipleOption,
|
|
114
|
+
selector: "option",
|
|
115
|
+
inputs: ["ngValue", "value"]
|
|
116
|
+
},
|
|
117
|
+
{
|
|
118
|
+
kind: "directive",
|
|
119
|
+
type: i1.SelectControlValueAccessor,
|
|
120
|
+
selector: "select:not([multiple]):not([ngNoCva])[formControlName],select:not([multiple]):not([ngNoCva])[formControl],select:not([multiple]):not([ngNoCva])[ngModel]",
|
|
121
|
+
inputs: ["compareWith"]
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
kind: "directive",
|
|
125
|
+
type: i1.SelectMultipleControlValueAccessor,
|
|
126
|
+
selector: "select[multiple]:not([ngNoCva])[formControlName],select[multiple]:not([ngNoCva])[formControl],select[multiple]:not([ngNoCva])[ngModel]",
|
|
127
|
+
inputs: ["compareWith"]
|
|
128
|
+
},
|
|
129
|
+
{
|
|
130
|
+
kind: "directive",
|
|
131
|
+
type: i1.NgControlStatus,
|
|
132
|
+
selector: "[formControlName],[ngModel],[formControl]"
|
|
133
|
+
},
|
|
134
|
+
{
|
|
135
|
+
kind: "directive",
|
|
136
|
+
type: i1.FormControlDirective,
|
|
137
|
+
selector: "[formControl]",
|
|
138
|
+
inputs: [
|
|
139
|
+
"formControl",
|
|
140
|
+
"disabled",
|
|
141
|
+
"ngModel"
|
|
142
|
+
],
|
|
143
|
+
outputs: ["ngModelChange"],
|
|
144
|
+
exportAs: ["ngForm"]
|
|
145
|
+
},
|
|
146
|
+
{
|
|
147
|
+
kind: "directive",
|
|
148
|
+
type: i2.LegacyFormlyAttributes,
|
|
149
|
+
selector: "[formlyAttributes]"
|
|
150
|
+
},
|
|
151
|
+
{
|
|
152
|
+
kind: "pipe",
|
|
153
|
+
type: i3.AsyncPipe,
|
|
154
|
+
name: "async"
|
|
155
|
+
},
|
|
156
|
+
{
|
|
157
|
+
kind: "pipe",
|
|
158
|
+
type: i4.LegacyFormlySelectOptionsPipe,
|
|
159
|
+
name: "formlySelectOptions"
|
|
160
|
+
}
|
|
161
|
+
],
|
|
162
|
+
changeDetection: i0.ChangeDetectionStrategy.OnPush
|
|
163
|
+
});
|
|
164
|
+
}
|
|
165
|
+
};
|
|
166
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
167
|
+
minVersion: "12.0.0",
|
|
168
|
+
version: "22.2.2",
|
|
169
|
+
ngImport: i0,
|
|
170
|
+
type: FormlyFieldSelect,
|
|
171
|
+
decorators: [{
|
|
172
|
+
type: Component,
|
|
173
|
+
args: [{
|
|
174
|
+
selector: "formly-field-select",
|
|
175
|
+
template: `
|
|
96
176
|
<ng-template #fieldTypeTemplate>
|
|
97
177
|
@if (props.multiple) {
|
|
98
178
|
<select
|
|
@@ -157,53 +237,83 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImpo
|
|
|
157
237
|
}
|
|
158
238
|
</ng-template>
|
|
159
239
|
`,
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
240
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
241
|
+
standalone: false
|
|
242
|
+
}]
|
|
243
|
+
}]
|
|
244
|
+
});
|
|
165
245
|
function withFormlyFieldSelect() {
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
],
|
|
175
|
-
};
|
|
246
|
+
return { types: [{
|
|
247
|
+
name: "select",
|
|
248
|
+
component: FormlyFieldSelect,
|
|
249
|
+
wrappers: ["form-field"]
|
|
250
|
+
}, {
|
|
251
|
+
name: "enum",
|
|
252
|
+
extends: "select"
|
|
253
|
+
}] };
|
|
176
254
|
}
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
255
|
+
var FormlyBootstrapSelectModule = class FormlyBootstrapSelectModule {
|
|
256
|
+
static {
|
|
257
|
+
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
258
|
+
minVersion: "12.0.0",
|
|
259
|
+
version: "22.2.2",
|
|
260
|
+
ngImport: i0,
|
|
261
|
+
type: FormlyBootstrapSelectModule,
|
|
262
|
+
deps: [],
|
|
263
|
+
target: i0.ɵɵFactoryTarget.NgModule
|
|
264
|
+
});
|
|
265
|
+
}
|
|
266
|
+
static {
|
|
267
|
+
this.ɵmod = i0.ɵɵngDeclareNgModule({
|
|
268
|
+
minVersion: "14.0.0",
|
|
269
|
+
version: "22.2.2",
|
|
270
|
+
ngImport: i0,
|
|
271
|
+
type: FormlyBootstrapSelectModule,
|
|
272
|
+
declarations: [FormlyFieldSelect],
|
|
273
|
+
imports: [
|
|
274
|
+
CommonModule,
|
|
275
|
+
ReactiveFormsModule,
|
|
276
|
+
FormlyBootstrapFormFieldModule,
|
|
277
|
+
FormlySelectModule,
|
|
278
|
+
i2.FormlyModule
|
|
279
|
+
]
|
|
280
|
+
});
|
|
281
|
+
}
|
|
282
|
+
static {
|
|
283
|
+
this.ɵinj = i0.ɵɵngDeclareInjector({
|
|
284
|
+
minVersion: "12.0.0",
|
|
285
|
+
version: "22.2.2",
|
|
286
|
+
ngImport: i0,
|
|
287
|
+
type: FormlyBootstrapSelectModule,
|
|
288
|
+
imports: [
|
|
289
|
+
CommonModule,
|
|
290
|
+
ReactiveFormsModule,
|
|
291
|
+
FormlyBootstrapFormFieldModule,
|
|
292
|
+
FormlySelectModule,
|
|
293
|
+
FormlyModule.forChild(withFormlyFieldSelect())
|
|
294
|
+
]
|
|
295
|
+
});
|
|
296
|
+
}
|
|
297
|
+
};
|
|
298
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
299
|
+
minVersion: "12.0.0",
|
|
300
|
+
version: "22.2.2",
|
|
301
|
+
ngImport: i0,
|
|
302
|
+
type: FormlyBootstrapSelectModule,
|
|
303
|
+
decorators: [{
|
|
304
|
+
type: NgModule,
|
|
305
|
+
args: [{
|
|
306
|
+
declarations: [FormlyFieldSelect],
|
|
307
|
+
imports: [
|
|
308
|
+
CommonModule,
|
|
309
|
+
ReactiveFormsModule,
|
|
310
|
+
FormlyBootstrapFormFieldModule,
|
|
311
|
+
FormlySelectModule,
|
|
312
|
+
FormlyModule.forChild(withFormlyFieldSelect())
|
|
313
|
+
]
|
|
314
|
+
}]
|
|
315
|
+
}]
|
|
316
|
+
});
|
|
208
317
|
export { FormlyBootstrapSelectModule, FormlyFieldSelect, withFormlyFieldSelect };
|
|
209
|
-
|
|
318
|
+
|
|
319
|
+
//# sourceMappingURL=ngx-formly-bootstrap-select.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ngx-formly-bootstrap-select.mjs","sources":["../../../../src/ui/bootstrap/select/src/select.type.ts","../../../../src/ui/bootstrap/select/src/select.config.ts","../../../../src/ui/bootstrap/select/src/select.module.ts"
|
|
1
|
+
{"version":3,"file":"ngx-formly-bootstrap-select.mjs","names":[],"sources":["../../../../src/ui/bootstrap/select/src/select.type.ts","../../../../src/ui/bootstrap/select/src/select.config.ts","../../../../src/ui/bootstrap/select/src/select.module.ts"],"sourcesContent":["import { Component, ChangeDetectionStrategy, Type } from '@angular/core';\nimport { FieldTypeConfig, FormlyFieldConfig } from '@ngx-formly/core';\nimport { FieldType, FormlyFieldProps } from '@ngx-formly/bootstrap/form-field';\nimport { FormlyFieldSelectProps } from '@ngx-formly/core/select';\n\ninterface SelectProps extends FormlyFieldProps, FormlyFieldSelectProps {\n multiple?: boolean;\n compareWith?: (o1: any, o2: any) => boolean;\n}\n\nexport interface FormlySelectFieldConfig extends FormlyFieldConfig<SelectProps> {\n type: 'select' | Type<FormlyFieldSelect>;\n}\n\n@Component({\n selector: 'formly-field-select',\n template: `\n <ng-template #fieldTypeTemplate>\n @if (props.multiple) {\n <select\n class=\"form-select\"\n multiple\n [formControl]=\"formControl\"\n [compareWith]=\"props.compareWith\"\n [class.is-invalid]=\"showError\"\n [formlyAttributes]=\"field\"\n [attr.aria-describedby]=\"id + '-formly-validation-error'\"\n [attr.aria-invalid]=\"showError\"\n >\n @if (props.options | formlySelectOptions: field | async; as opts) {\n @for (opt of opts; track opt) {\n @if (!opt.group) {\n <option [ngValue]=\"opt.value\" [disabled]=\"opt.disabled\">\n {{ opt.label }}\n </option>\n } @else {\n <optgroup [label]=\"opt.label\">\n @for (child of opt.group; track child) {\n <option [ngValue]=\"child.value\" [disabled]=\"child.disabled\">\n {{ child.label }}\n </option>\n }\n </optgroup>\n }\n }\n }\n </select>\n } @else {\n <select\n class=\"form-select\"\n [formControl]=\"formControl\"\n [compareWith]=\"props.compareWith\"\n [class.is-invalid]=\"showError\"\n [formlyAttributes]=\"field\"\n [attr.aria-describedby]=\"id + '-formly-validation-error'\"\n [attr.aria-invalid]=\"showError\"\n >\n @if (props.placeholder) {\n <option [ngValue]=\"undefined\">{{ props.placeholder }}</option>\n }\n @if (props.options | formlySelectOptions: field | async; as opts) {\n @for (opt of opts; track opt) {\n @if (!opt.group) {\n <option [ngValue]=\"opt.value\" [disabled]=\"opt.disabled\">\n {{ opt.label }}\n </option>\n } @else {\n <optgroup [label]=\"opt.label\">\n @for (child of opt.group; track child) {\n <option [ngValue]=\"child.value\" [disabled]=\"child.disabled\">\n {{ child.label }}\n </option>\n }\n </optgroup>\n }\n }\n }\n </select>\n }\n </ng-template>\n `,\n changeDetection: ChangeDetectionStrategy.OnPush,\n standalone: false,\n})\nexport class FormlyFieldSelect extends FieldType<FieldTypeConfig<SelectProps>> {\n override defaultOptions = {\n props: {\n compareWith(o1: any, o2: any) {\n return o1 === o2;\n },\n },\n };\n}\n","import { ConfigOption } from '@ngx-formly/core';\nimport { FormlyFieldSelect } from './select.type';\n\nexport function withFormlyFieldSelect(): ConfigOption {\n return {\n types: [\n {\n name: 'select',\n component: FormlyFieldSelect,\n wrappers: ['form-field'],\n },\n { name: 'enum', extends: 'select' },\n ],\n };\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { FormlyModule } from '@ngx-formly/core';\nimport { FormlySelectModule } from '@ngx-formly/core/select';\n\nimport { FormlyBootstrapFormFieldModule } from '@ngx-formly/bootstrap/form-field';\nimport { FormlyFieldSelect } from './select.type';\nimport { withFormlyFieldSelect } from './select.config';\n\n@NgModule({\n declarations: [FormlyFieldSelect],\n imports: [\n CommonModule,\n ReactiveFormsModule,\n\n FormlyBootstrapFormFieldModule,\n FormlySelectModule,\n FormlyModule.forChild(withFormlyFieldSelect()),\n ],\n})\nexport class FormlyBootstrapSelectModule {}\n"],"mappings":";;;;;;;;;;;AAoFA,IAAa,oBAAb,MAAa,0BAA0B,UAAuC;CAtE9E,cAAA;;EAuEW,KAAA,iBAAiB,EACxB,OAAO,EACL,YAAY,IAAS,IAAO;GAC1B,OAAO,OAAO;EAChB,EACD,EACF;CACF;CARY;EAAA,KAAA,OAAA,GAAA,mBAAA;GAAA,YAAA;GAAA,SAAA;GAAA,UAAA;GAAA,MAAA;GAAiB,MAAA;GAAA,QAAA,GAAA,gBAAA;EAAA,CAAA;CAAA;CAAjB;EAAA,KAAA,OAAA,GAAA,qBAAA;GAAA,YAAA;GAAA,SAAA;GAAA,MAAA;GAAiB,cAAA;GAAA,UAAA;GAAA,iBAAA;GAAA,UAAA;GAAA,UApElB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgET,UAAA;GAAA,cAAA;IAAA;KAAA,MAAA;KAAA,MAAA,GAAA;KAAA,UAAA;KAAA,QAAA,CAAA,WAAA,OAAA;IAAA;IAAA;KAAA,MAAA;KAAA,MAAA,GAAA;KAAA,UAAA;KAAA,QAAA,CAAA,WAAA,OAAA;IAAA;IAAA;KAAA,MAAA;KAAA,MAAA,GAAA;KAAA,UAAA;KAAA,QAAA,CAAA,aAAA;IAAA;IAAA;KAAA,MAAA;KAAA,MAAA,GAAA;KAAA,UAAA;KAAA,QAAA,CAAA,aAAA;IAAA;IAAA;KAAA,MAAA;KAAA,MAAA,GAAA;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A;GAAA,MAAA;GAA2B,SAAA;IARpC;IACA;IAEA;IACA;IACA,aAAa,SAAS,sBAAqB,CAAE;GAAC;EAAA,CAAA;CAAA;;AAGrC,GAAA,yBAAA;CAAA,YAAA;CAAA,SAAA;CAAA,UAAA;CAAA,MAAA;CAA2B,YAAA,CAAA;EAXvC,MAAA;EAAS,MAAA,CAAA;GACR,cAAc,CAAC,iBAAiB;GAChC,SAAS;IACP;IACA;IAEA;IACA;IACA,aAAa,SAAS,sBAAqB,CAAE;GAC9C;EACF,CAAA"}
|
|
@@ -1,24 +1,39 @@
|
|
|
1
|
-
import * as i0 from
|
|
2
|
-
import { ChangeDetectionStrategy, Component, NgModule } from
|
|
3
|
-
import { FieldType, FormlyBootstrapFormFieldModule } from
|
|
4
|
-
import * as i1 from
|
|
5
|
-
import { ReactiveFormsModule } from
|
|
6
|
-
import * as i2 from
|
|
7
|
-
import { FormlyModule } from
|
|
8
|
-
import { CommonModule } from
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import { ChangeDetectionStrategy, Component, NgModule } from "@angular/core";
|
|
3
|
+
import { FieldType, FormlyBootstrapFormFieldModule } from "@ngx-formly/bootstrap/form-field";
|
|
4
|
+
import * as i1 from "@angular/forms";
|
|
5
|
+
import { ReactiveFormsModule } from "@angular/forms";
|
|
6
|
+
import * as i2 from "@ngx-formly/core";
|
|
7
|
+
import { FormlyModule } from "@ngx-formly/core";
|
|
8
|
+
import { CommonModule } from "@angular/common";
|
|
9
|
+
var FormlyFieldTextArea = class FormlyFieldTextArea extends FieldType {
|
|
10
|
+
constructor() {
|
|
11
|
+
super(...arguments);
|
|
12
|
+
this.defaultOptions = { props: {
|
|
13
|
+
cols: 1,
|
|
14
|
+
rows: 1
|
|
15
|
+
} };
|
|
16
|
+
}
|
|
17
|
+
static {
|
|
18
|
+
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
19
|
+
minVersion: "12.0.0",
|
|
20
|
+
version: "22.2.2",
|
|
21
|
+
ngImport: i0,
|
|
22
|
+
type: FormlyFieldTextArea,
|
|
23
|
+
deps: null,
|
|
24
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
static {
|
|
28
|
+
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
29
|
+
minVersion: "14.0.0",
|
|
30
|
+
version: "22.2.2",
|
|
31
|
+
type: FormlyFieldTextArea,
|
|
32
|
+
isStandalone: false,
|
|
33
|
+
selector: "formly-field-textarea",
|
|
34
|
+
usesInheritance: true,
|
|
35
|
+
ngImport: i0,
|
|
36
|
+
template: `
|
|
22
37
|
<ng-template #fieldTypeTemplate>
|
|
23
38
|
<textarea
|
|
24
39
|
[formControl]="formControl"
|
|
@@ -31,13 +46,51 @@ class FormlyFieldTextArea extends FieldType {
|
|
|
31
46
|
[attr.aria-invalid]="showError"
|
|
32
47
|
></textarea>
|
|
33
48
|
</ng-template>
|
|
34
|
-
`,
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
49
|
+
`,
|
|
50
|
+
isInline: true,
|
|
51
|
+
dependencies: [
|
|
52
|
+
{
|
|
53
|
+
kind: "directive",
|
|
54
|
+
type: i1.DefaultValueAccessor,
|
|
55
|
+
selector: "input:not([type=checkbox]):not([ngNoCva])[formControlName],textarea:not([ngNoCva])[formControlName],input:not([type=checkbox]):not([ngNoCva])[formControl],textarea:not([ngNoCva])[formControl],input:not([type=checkbox]):not([ngNoCva])[ngModel],textarea:not([ngNoCva])[ngModel],[ngDefaultControl]"
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
kind: "directive",
|
|
59
|
+
type: i1.NgControlStatus,
|
|
60
|
+
selector: "[formControlName],[ngModel],[formControl]"
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
kind: "directive",
|
|
64
|
+
type: i1.FormControlDirective,
|
|
65
|
+
selector: "[formControl]",
|
|
66
|
+
inputs: [
|
|
67
|
+
"formControl",
|
|
68
|
+
"disabled",
|
|
69
|
+
"ngModel"
|
|
70
|
+
],
|
|
71
|
+
outputs: ["ngModelChange"],
|
|
72
|
+
exportAs: ["ngForm"]
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
kind: "directive",
|
|
76
|
+
type: i2.LegacyFormlyAttributes,
|
|
77
|
+
selector: "[formlyAttributes]"
|
|
78
|
+
}
|
|
79
|
+
],
|
|
80
|
+
changeDetection: i0.ChangeDetectionStrategy.OnPush
|
|
81
|
+
});
|
|
82
|
+
}
|
|
83
|
+
};
|
|
84
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
85
|
+
minVersion: "12.0.0",
|
|
86
|
+
version: "22.2.2",
|
|
87
|
+
ngImport: i0,
|
|
88
|
+
type: FormlyFieldTextArea,
|
|
89
|
+
decorators: [{
|
|
90
|
+
type: Component,
|
|
91
|
+
args: [{
|
|
92
|
+
selector: "formly-field-textarea",
|
|
93
|
+
template: `
|
|
41
94
|
<ng-template #fieldTypeTemplate>
|
|
42
95
|
<textarea
|
|
43
96
|
[formControl]="formControl"
|
|
@@ -51,49 +104,77 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImpo
|
|
|
51
104
|
></textarea>
|
|
52
105
|
</ng-template>
|
|
53
106
|
`,
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
107
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
108
|
+
standalone: false
|
|
109
|
+
}]
|
|
110
|
+
}]
|
|
111
|
+
});
|
|
59
112
|
function withFormlyFieldTextArea() {
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
wrappers: ['form-field'],
|
|
66
|
-
},
|
|
67
|
-
],
|
|
68
|
-
};
|
|
113
|
+
return { types: [{
|
|
114
|
+
name: "textarea",
|
|
115
|
+
component: FormlyFieldTextArea,
|
|
116
|
+
wrappers: ["form-field"]
|
|
117
|
+
}] };
|
|
69
118
|
}
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
119
|
+
var FormlyBootstrapTextAreaModule = class FormlyBootstrapTextAreaModule {
|
|
120
|
+
static {
|
|
121
|
+
this.ɵfac = i0.ɵɵngDeclareFactory({
|
|
122
|
+
minVersion: "12.0.0",
|
|
123
|
+
version: "22.2.2",
|
|
124
|
+
ngImport: i0,
|
|
125
|
+
type: FormlyBootstrapTextAreaModule,
|
|
126
|
+
deps: [],
|
|
127
|
+
target: i0.ɵɵFactoryTarget.NgModule
|
|
128
|
+
});
|
|
129
|
+
}
|
|
130
|
+
static {
|
|
131
|
+
this.ɵmod = i0.ɵɵngDeclareNgModule({
|
|
132
|
+
minVersion: "14.0.0",
|
|
133
|
+
version: "22.2.2",
|
|
134
|
+
ngImport: i0,
|
|
135
|
+
type: FormlyBootstrapTextAreaModule,
|
|
136
|
+
declarations: [FormlyFieldTextArea],
|
|
137
|
+
imports: [
|
|
138
|
+
CommonModule,
|
|
139
|
+
ReactiveFormsModule,
|
|
140
|
+
FormlyBootstrapFormFieldModule,
|
|
141
|
+
i2.FormlyModule
|
|
142
|
+
]
|
|
143
|
+
});
|
|
144
|
+
}
|
|
145
|
+
static {
|
|
146
|
+
this.ɵinj = i0.ɵɵngDeclareInjector({
|
|
147
|
+
minVersion: "12.0.0",
|
|
148
|
+
version: "22.2.2",
|
|
149
|
+
ngImport: i0,
|
|
150
|
+
type: FormlyBootstrapTextAreaModule,
|
|
151
|
+
imports: [
|
|
152
|
+
CommonModule,
|
|
153
|
+
ReactiveFormsModule,
|
|
154
|
+
FormlyBootstrapFormFieldModule,
|
|
155
|
+
FormlyModule.forChild(withFormlyFieldTextArea())
|
|
156
|
+
]
|
|
157
|
+
});
|
|
158
|
+
}
|
|
159
|
+
};
|
|
160
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
161
|
+
minVersion: "12.0.0",
|
|
162
|
+
version: "22.2.2",
|
|
163
|
+
ngImport: i0,
|
|
164
|
+
type: FormlyBootstrapTextAreaModule,
|
|
165
|
+
decorators: [{
|
|
166
|
+
type: NgModule,
|
|
167
|
+
args: [{
|
|
168
|
+
declarations: [FormlyFieldTextArea],
|
|
169
|
+
imports: [
|
|
170
|
+
CommonModule,
|
|
171
|
+
ReactiveFormsModule,
|
|
172
|
+
FormlyBootstrapFormFieldModule,
|
|
173
|
+
FormlyModule.forChild(withFormlyFieldTextArea())
|
|
174
|
+
]
|
|
175
|
+
}]
|
|
176
|
+
}]
|
|
177
|
+
});
|
|
98
178
|
export { FormlyBootstrapTextAreaModule, FormlyFieldTextArea, withFormlyFieldTextArea };
|
|
99
|
-
|
|
179
|
+
|
|
180
|
+
//# sourceMappingURL=ngx-formly-bootstrap-textarea.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ngx-formly-bootstrap-textarea.mjs","sources":["../../../../src/ui/bootstrap/textarea/src/textarea.type.ts","../../../../src/ui/bootstrap/textarea/src/textarea.config.ts","../../../../src/ui/bootstrap/textarea/src/textarea.module.ts"
|
|
1
|
+
{"version":3,"file":"ngx-formly-bootstrap-textarea.mjs","names":[],"sources":["../../../../src/ui/bootstrap/textarea/src/textarea.type.ts","../../../../src/ui/bootstrap/textarea/src/textarea.config.ts","../../../../src/ui/bootstrap/textarea/src/textarea.module.ts"],"sourcesContent":["import { Component, ChangeDetectionStrategy, Type } from '@angular/core';\nimport { FieldTypeConfig, FormlyFieldConfig } from '@ngx-formly/core';\nimport { FieldType, FormlyFieldProps } from '@ngx-formly/bootstrap/form-field';\n\ninterface TextAreaProps extends FormlyFieldProps {\n cols?: number;\n rows?: number;\n}\n\nexport interface FormlyTextAreaFieldConfig extends FormlyFieldConfig<TextAreaProps> {\n type: 'textarea' | Type<FormlyFieldTextArea>;\n}\n\n@Component({\n selector: 'formly-field-textarea',\n template: `\n <ng-template #fieldTypeTemplate>\n <textarea\n [formControl]=\"formControl\"\n [cols]=\"props.cols\"\n [rows]=\"props.rows\"\n class=\"form-control\"\n [class.is-invalid]=\"showError\"\n [formlyAttributes]=\"field\"\n [attr.aria-describedby]=\"id + '-formly-validation-error'\"\n [attr.aria-invalid]=\"showError\"\n ></textarea>\n </ng-template>\n `,\n changeDetection: ChangeDetectionStrategy.OnPush,\n standalone: false,\n})\nexport class FormlyFieldTextArea extends FieldType<FieldTypeConfig<TextAreaProps>> {\n override defaultOptions = {\n props: {\n cols: 1,\n rows: 1,\n },\n };\n}\n","import { ConfigOption } from '@ngx-formly/core';\nimport { FormlyFieldTextArea } from './textarea.type';\n\nexport function withFormlyFieldTextArea(): ConfigOption {\n return {\n types: [\n {\n name: 'textarea',\n component: FormlyFieldTextArea,\n wrappers: ['form-field'],\n },\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';\n\nimport { FormlyBootstrapFormFieldModule } from '@ngx-formly/bootstrap/form-field';\nimport { FormlyFieldTextArea } from './textarea.type';\nimport { withFormlyFieldTextArea } from './textarea.config';\n\n@NgModule({\n declarations: [FormlyFieldTextArea],\n imports: [\n CommonModule,\n ReactiveFormsModule,\n\n Formly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