@stemy/ngx-dynamic-form 19.6.7 → 19.6.9
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.
|
@@ -307,12 +307,15 @@ function getFieldsByPredicate(field, cb) {
|
|
|
307
307
|
function getFieldsByKey(field, key) {
|
|
308
308
|
return getFieldsByPredicate(field, f => f.key === key);
|
|
309
309
|
}
|
|
310
|
-
async function getSelectOptions(
|
|
311
|
-
const options =
|
|
310
|
+
async function getSelectOptions(fieldOrOpts) {
|
|
311
|
+
const options = fieldOrOpts.props?.options || fieldOrOpts;
|
|
312
312
|
if (options instanceof Observable) {
|
|
313
313
|
return firstValueFrom(options);
|
|
314
314
|
}
|
|
315
|
-
|
|
315
|
+
if (options instanceof Promise) {
|
|
316
|
+
return await options;
|
|
317
|
+
}
|
|
318
|
+
return Array.isArray(options) ? options : [];
|
|
316
319
|
}
|
|
317
320
|
function replaceFieldArray(field, items) {
|
|
318
321
|
const model = field.model || [];
|
|
@@ -354,10 +357,10 @@ function setFieldProp(field, prop, value) {
|
|
|
354
357
|
return setFieldProps(field, { [prop]: value });
|
|
355
358
|
}
|
|
356
359
|
function setFieldHidden(field, hidden = true) {
|
|
357
|
-
setFieldProp(field, "
|
|
360
|
+
setFieldProp(field, "__hidden", ObjectUtils.isFunction(hidden) ? hidden : () => hidden);
|
|
358
361
|
}
|
|
359
362
|
function setFieldDisabled(field, disabled = true) {
|
|
360
|
-
setFieldProp(field, "
|
|
363
|
+
setFieldProp(field, "__disabled", ObjectUtils.isFunction(disabled) ? disabled : () => disabled);
|
|
361
364
|
}
|
|
362
365
|
function setFieldHooks(field, hooks) {
|
|
363
366
|
field.hooks = field.hooks || {};
|
|
@@ -379,6 +382,10 @@ const MAX_INPUT_NUM = 1999999999;
|
|
|
379
382
|
const EDITOR_FORMATS = ["php", "json", "html", "css", "scss"];
|
|
380
383
|
|
|
381
384
|
class ConfigForSchemaWrap {
|
|
385
|
+
opts;
|
|
386
|
+
mode;
|
|
387
|
+
injector;
|
|
388
|
+
schema;
|
|
382
389
|
get labelPrefix() {
|
|
383
390
|
return this.opts.labelPrefix;
|
|
384
391
|
}
|
|
@@ -391,6 +398,7 @@ class ConfigForSchemaWrap {
|
|
|
391
398
|
get context() {
|
|
392
399
|
return this.opts.context;
|
|
393
400
|
}
|
|
401
|
+
fieldCustomizer;
|
|
394
402
|
constructor(opts, mode, injector, schema) {
|
|
395
403
|
this.opts = opts;
|
|
396
404
|
this.mode = mode;
|
|
@@ -480,6 +488,11 @@ function getFormValidationErrors(controls, parentPath = "") {
|
|
|
480
488
|
}
|
|
481
489
|
|
|
482
490
|
class DynamicFormBuilderService {
|
|
491
|
+
injector;
|
|
492
|
+
events;
|
|
493
|
+
api;
|
|
494
|
+
languages;
|
|
495
|
+
language;
|
|
483
496
|
constructor(injector, events, api, languages) {
|
|
484
497
|
this.injector = injector;
|
|
485
498
|
this.events = events;
|
|
@@ -511,48 +524,46 @@ class DynamicFormBuilderService {
|
|
|
511
524
|
}, data, parent, options);
|
|
512
525
|
}
|
|
513
526
|
createFieldSets(fields, parent, options) {
|
|
514
|
-
const
|
|
527
|
+
const result = [];
|
|
515
528
|
const groups = {};
|
|
516
|
-
fields
|
|
529
|
+
fields.forEach(f => {
|
|
517
530
|
if (Array.isArray(f.fieldGroup) && Array.isArray(f.wrappers) && f.wrappers[0] === "form-fieldset") {
|
|
518
531
|
// This field is an already existing set
|
|
519
532
|
groups[f.id] = f.fieldGroup;
|
|
520
|
-
return false;
|
|
521
533
|
}
|
|
522
|
-
return true;
|
|
523
534
|
});
|
|
524
535
|
for (const field of fields) {
|
|
525
536
|
const fsName = String(field.fieldSet || "");
|
|
526
537
|
// If we have a fieldset name defined, then push the property fields into a group
|
|
527
538
|
if (fsName) {
|
|
528
|
-
const
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
539
|
+
const id = !parent?.path ? fsName : `${parent.path}.${fsName}`;
|
|
540
|
+
let fieldGroup = groups[id];
|
|
541
|
+
if (!fieldGroup) {
|
|
542
|
+
fieldGroup = [];
|
|
543
|
+
const fieldSet = {
|
|
544
|
+
id,
|
|
545
|
+
parent,
|
|
546
|
+
fieldGroup,
|
|
547
|
+
wrappers: ["form-fieldset"],
|
|
548
|
+
props: {
|
|
549
|
+
label: this.getLabel(fsName, fsName, parent, options),
|
|
550
|
+
hidden: false,
|
|
551
|
+
className: `dynamic-form-fieldset dynamic-form-fieldset-${id}`
|
|
552
|
+
},
|
|
553
|
+
hooks: {},
|
|
554
|
+
expressions: {}
|
|
555
|
+
};
|
|
556
|
+
this.setExpressions(fieldSet, options);
|
|
557
|
+
groups[id] = fieldGroup;
|
|
558
|
+
result.push(fieldSet);
|
|
559
|
+
}
|
|
560
|
+
fieldGroup.push(field);
|
|
532
561
|
continue;
|
|
533
562
|
}
|
|
534
|
-
// Otherwise
|
|
535
|
-
|
|
563
|
+
// Otherwise just push to result
|
|
564
|
+
result.push(field);
|
|
536
565
|
}
|
|
537
|
-
|
|
538
|
-
return Object.keys(groups).map(id => {
|
|
539
|
-
const key = id.split(".").pop();
|
|
540
|
-
const fieldSet = {
|
|
541
|
-
id,
|
|
542
|
-
parent,
|
|
543
|
-
fieldGroup: groups[id],
|
|
544
|
-
wrappers: ["form-fieldset"],
|
|
545
|
-
props: {
|
|
546
|
-
label: this.getLabel(key, key, parent, options),
|
|
547
|
-
hidden: false,
|
|
548
|
-
className: `dynamic-form-fieldset dynamic-form-fieldset-${id}`
|
|
549
|
-
},
|
|
550
|
-
hooks: {},
|
|
551
|
-
expressions: {}
|
|
552
|
-
};
|
|
553
|
-
this.setExpressions(fieldSet, options);
|
|
554
|
-
return fieldSet;
|
|
555
|
-
}).concat(others);
|
|
566
|
+
return result;
|
|
556
567
|
}
|
|
557
568
|
createFormInput(key, data, parent, options) {
|
|
558
569
|
data = data || {};
|
|
@@ -604,12 +615,13 @@ class DynamicFormBuilderService {
|
|
|
604
615
|
}, parent, options);
|
|
605
616
|
setFieldHooks(field, {
|
|
606
617
|
onInit: target => {
|
|
607
|
-
const
|
|
618
|
+
const factory = ReflectUtils.resolve(data.options, this.injector);
|
|
619
|
+
const options = factory(target, this.injector);
|
|
608
620
|
const root = target.formControl.root;
|
|
609
621
|
setFieldProp(target, "options", options instanceof Observable
|
|
610
622
|
? options
|
|
611
623
|
: controlValues(root).pipe(combineLatestWith(this.language), switchMap(async () => {
|
|
612
|
-
const results = await
|
|
624
|
+
const results = await factory(target, this.injector) || [];
|
|
613
625
|
return this.fixSelectOptions(target, results);
|
|
614
626
|
})));
|
|
615
627
|
}
|
|
@@ -745,6 +757,8 @@ class DynamicFormBuilderService {
|
|
|
745
757
|
if (type !== "array") {
|
|
746
758
|
wrappers.unshift(!type ? "form-group" : "form-field");
|
|
747
759
|
}
|
|
760
|
+
const disabled = ReflectUtils.resolve(data.disabled, this.injector);
|
|
761
|
+
const hidden = ReflectUtils.resolve(data.hidden, this.injector);
|
|
748
762
|
const field = {
|
|
749
763
|
key,
|
|
750
764
|
wrappers,
|
|
@@ -756,8 +770,6 @@ class DynamicFormBuilderService {
|
|
|
756
770
|
props: {
|
|
757
771
|
...(data.props || {}),
|
|
758
772
|
...props,
|
|
759
|
-
disabled: data.disabled === true,
|
|
760
|
-
hidden: data.hidden === true,
|
|
761
773
|
label: options.labelCustomizer?.(key, data.label, parent, options.labelPrefix)
|
|
762
774
|
?? this.getLabel(key, data.label, parent, options),
|
|
763
775
|
hideLabel: data.hideLabel === true,
|
|
@@ -766,7 +778,9 @@ class DynamicFormBuilderService {
|
|
|
766
778
|
className: data.className || "",
|
|
767
779
|
hideRequiredMarker: data.hideRequiredMarker === true,
|
|
768
780
|
formCheck: "nolabel",
|
|
769
|
-
labelPosition: "before"
|
|
781
|
+
labelPosition: "before",
|
|
782
|
+
__disabled: ObjectUtils.isFunction(disabled) ? disabled : () => disabled,
|
|
783
|
+
__hidden: ObjectUtils.isFunction(hidden) ? hidden : () => hidden
|
|
770
784
|
},
|
|
771
785
|
modelOptions: {
|
|
772
786
|
updateOn: "change"
|
|
@@ -776,7 +790,15 @@ class DynamicFormBuilderService {
|
|
|
776
790
|
serializer: () => data.serializer,
|
|
777
791
|
serialize: () => data.serialize,
|
|
778
792
|
"props.hideRequiredMarker": target => target.type === "checkbox",
|
|
779
|
-
"props.required": target => !!target.validators?.required
|
|
793
|
+
"props.required": target => !!target.validators?.required,
|
|
794
|
+
"props.disabled": target => {
|
|
795
|
+
const disabled = target.props?.__disabled;
|
|
796
|
+
return !!disabled(target, this.injector);
|
|
797
|
+
},
|
|
798
|
+
"props.hidden": target => {
|
|
799
|
+
const hidden = target.props?.__hidden;
|
|
800
|
+
return !!hidden(target, this.injector);
|
|
801
|
+
}
|
|
780
802
|
}
|
|
781
803
|
};
|
|
782
804
|
// Parent object will be available for customizers as a property, until it gets redefined by formly
|
|
@@ -841,8 +863,8 @@ class DynamicFormBuilderService {
|
|
|
841
863
|
}
|
|
842
864
|
});
|
|
843
865
|
}
|
|
844
|
-
static
|
|
845
|
-
static
|
|
866
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormBuilderService, deps: [{ token: i0.Injector }, { token: i2.EventsService }, { token: API_SERVICE }, { token: LANGUAGE_SERVICE }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
867
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormBuilderService });
|
|
846
868
|
}
|
|
847
869
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormBuilderService, decorators: [{
|
|
848
870
|
type: Injectable
|
|
@@ -855,6 +877,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
855
877
|
}] }] });
|
|
856
878
|
|
|
857
879
|
class DynamicFormSchemaService {
|
|
880
|
+
openApi;
|
|
881
|
+
injector;
|
|
882
|
+
builder;
|
|
858
883
|
get api() {
|
|
859
884
|
return this.openApi.api;
|
|
860
885
|
}
|
|
@@ -1214,14 +1239,18 @@ class DynamicFormSchemaService {
|
|
|
1214
1239
|
validators.itemsMaxValue = maxValueValidation(items.maximum, true);
|
|
1215
1240
|
}
|
|
1216
1241
|
}
|
|
1217
|
-
static
|
|
1218
|
-
static
|
|
1242
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormSchemaService, deps: [{ token: i2.OpenApiService }, { token: i0.Injector }, { token: DynamicFormBuilderService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1243
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormSchemaService });
|
|
1219
1244
|
}
|
|
1220
1245
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormSchemaService, decorators: [{
|
|
1221
1246
|
type: Injectable
|
|
1222
1247
|
}], ctorParameters: () => [{ type: i2.OpenApiService }, { type: i0.Injector }, { type: DynamicFormBuilderService }] });
|
|
1223
1248
|
|
|
1224
1249
|
class DynamicFormService {
|
|
1250
|
+
fs;
|
|
1251
|
+
fb;
|
|
1252
|
+
injector;
|
|
1253
|
+
api;
|
|
1225
1254
|
constructor(fs, fb, injector, api) {
|
|
1226
1255
|
this.fs = fs;
|
|
1227
1256
|
this.fb = fb;
|
|
@@ -1353,8 +1382,8 @@ class DynamicFormService {
|
|
|
1353
1382
|
}
|
|
1354
1383
|
});
|
|
1355
1384
|
}
|
|
1356
|
-
static
|
|
1357
|
-
static
|
|
1385
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormService, deps: [{ token: DynamicFormSchemaService }, { token: DynamicFormBuilderService }, { token: i0.Injector }, { token: API_SERVICE }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1386
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormService });
|
|
1358
1387
|
}
|
|
1359
1388
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormService, decorators: [{
|
|
1360
1389
|
type: Injectable
|
|
@@ -1364,6 +1393,25 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
1364
1393
|
}] }] });
|
|
1365
1394
|
|
|
1366
1395
|
class AsyncSubmitDirective {
|
|
1396
|
+
method = input(null, { alias: "async-submit" });
|
|
1397
|
+
mode = input("click");
|
|
1398
|
+
form = input();
|
|
1399
|
+
context = input();
|
|
1400
|
+
onSuccess = output();
|
|
1401
|
+
onError = output();
|
|
1402
|
+
toaster = inject(TOASTER_SERVICE);
|
|
1403
|
+
renderer = inject(Renderer2);
|
|
1404
|
+
elem = inject(ElementRef);
|
|
1405
|
+
status = computed(() => {
|
|
1406
|
+
const form = this.form();
|
|
1407
|
+
return form?.status() || null;
|
|
1408
|
+
});
|
|
1409
|
+
group = computed(() => {
|
|
1410
|
+
const form = this.form();
|
|
1411
|
+
return form?.group() || null;
|
|
1412
|
+
});
|
|
1413
|
+
loading = signal(false);
|
|
1414
|
+
callback = signal(null);
|
|
1367
1415
|
get isDisabled() {
|
|
1368
1416
|
return this.status() !== "VALID";
|
|
1369
1417
|
}
|
|
@@ -1371,25 +1419,6 @@ class AsyncSubmitDirective {
|
|
|
1371
1419
|
return this.loading();
|
|
1372
1420
|
}
|
|
1373
1421
|
constructor() {
|
|
1374
|
-
this.method = input(null, { alias: "async-submit" });
|
|
1375
|
-
this.mode = input("click");
|
|
1376
|
-
this.form = input();
|
|
1377
|
-
this.context = input();
|
|
1378
|
-
this.onSuccess = output();
|
|
1379
|
-
this.onError = output();
|
|
1380
|
-
this.toaster = inject(TOASTER_SERVICE);
|
|
1381
|
-
this.renderer = inject(Renderer2);
|
|
1382
|
-
this.elem = inject(ElementRef);
|
|
1383
|
-
this.status = computed(() => {
|
|
1384
|
-
const form = this.form();
|
|
1385
|
-
return form?.status() || null;
|
|
1386
|
-
});
|
|
1387
|
-
this.group = computed(() => {
|
|
1388
|
-
const form = this.form();
|
|
1389
|
-
return form?.group() || null;
|
|
1390
|
-
});
|
|
1391
|
-
this.loading = signal(false);
|
|
1392
|
-
this.callback = signal(null);
|
|
1393
1422
|
if (this.elem.nativeElement.tagName === "BUTTON") {
|
|
1394
1423
|
this.renderer.setAttribute(this.elem.nativeElement, "type", "button");
|
|
1395
1424
|
}
|
|
@@ -1444,8 +1473,8 @@ class AsyncSubmitDirective {
|
|
|
1444
1473
|
this.toaster.error(reason.message, reason.context);
|
|
1445
1474
|
});
|
|
1446
1475
|
}
|
|
1447
|
-
static
|
|
1448
|
-
static
|
|
1476
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: AsyncSubmitDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1477
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.14", type: AsyncSubmitDirective, isStandalone: false, selector: "[async-submit]", inputs: { method: { classPropertyName: "method", publicName: "async-submit", isSignal: true, isRequired: false, transformFunction: null }, mode: { classPropertyName: "mode", publicName: "mode", isSignal: true, isRequired: false, transformFunction: null }, form: { classPropertyName: "form", publicName: "form", isSignal: true, isRequired: false, transformFunction: null }, context: { classPropertyName: "context", publicName: "context", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onSuccess: "onSuccess", onError: "onError" }, host: { listeners: { "click": "click()" }, properties: { "class.disabled": "this.isDisabled", "class.loading": "this.isLoading" } }, exportAs: ["async-submit"], ngImport: i0 });
|
|
1449
1478
|
}
|
|
1450
1479
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: AsyncSubmitDirective, decorators: [{
|
|
1451
1480
|
type: Directive,
|
|
@@ -1466,12 +1495,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
1466
1495
|
}] } });
|
|
1467
1496
|
|
|
1468
1497
|
class DynamicFieldType extends FieldType {
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
this._errorState = false;
|
|
1473
|
-
this._focused = false;
|
|
1474
|
-
}
|
|
1498
|
+
stateChanges = new Subject();
|
|
1499
|
+
_errorState = false;
|
|
1500
|
+
_focused = false;
|
|
1475
1501
|
ngOnDestroy() {
|
|
1476
1502
|
delete this.formField?._control;
|
|
1477
1503
|
this.stateChanges.complete();
|
|
@@ -1558,8 +1584,8 @@ class DynamicFieldType extends FieldType {
|
|
|
1558
1584
|
};
|
|
1559
1585
|
}
|
|
1560
1586
|
}
|
|
1561
|
-
static
|
|
1562
|
-
static
|
|
1587
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFieldType, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
1588
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: DynamicFieldType, isStandalone: false, selector: "dynamic-field-type", usesInheritance: true, ngImport: i0, template: "", isInline: true });
|
|
1563
1589
|
}
|
|
1564
1590
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFieldType, decorators: [{
|
|
1565
1591
|
type: Component,
|
|
@@ -1571,57 +1597,57 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
1571
1597
|
}] });
|
|
1572
1598
|
|
|
1573
1599
|
class DynamicFormComponent {
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1578
|
-
|
|
1579
|
-
|
|
1580
|
-
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
testId: this.testId(),
|
|
1596
|
-
};
|
|
1597
|
-
const fields = this.fields() || this.builder.resolveFormFields(this.data()?.constructor, null, options);
|
|
1598
|
-
return [
|
|
1599
|
-
this.builder.createFormGroup(null, () => fields, {
|
|
1600
|
-
label: "",
|
|
1601
|
-
useTabs: this.useTabs(),
|
|
1602
|
-
hidden: false,
|
|
1603
|
-
className: "dynamic-form-root-group"
|
|
1604
|
-
}, null, options)
|
|
1605
|
-
];
|
|
1606
|
-
});
|
|
1607
|
-
this.group = computed(() => {
|
|
1608
|
-
this.config();
|
|
1609
|
-
return new FormGroup$1({});
|
|
1610
|
-
});
|
|
1611
|
-
this.status$ = rxResource({
|
|
1612
|
-
request: () => this.group(),
|
|
1613
|
-
loader: p => controlStatus(p.request),
|
|
1614
|
-
defaultValue: "PENDING"
|
|
1615
|
-
});
|
|
1616
|
-
this.status = computed(() => this.status$.value());
|
|
1617
|
-
this.onSubmit = output();
|
|
1618
|
-
this.onChanges = outputFromObservable(this.fieldChanges);
|
|
1619
|
-
this.options = {
|
|
1620
|
-
fieldChanges: this.fieldChanges,
|
|
1621
|
-
formState: {
|
|
1622
|
-
injector: inject(Injector)
|
|
1623
|
-
}
|
|
1600
|
+
builder = inject(DynamicFormBuilderService);
|
|
1601
|
+
events = inject(EventsService);
|
|
1602
|
+
languages = inject(LANGUAGE_SERVICE);
|
|
1603
|
+
labelPrefix = input("label");
|
|
1604
|
+
labelCustomizer = input(null);
|
|
1605
|
+
testId = input("");
|
|
1606
|
+
useTabs = input(false);
|
|
1607
|
+
data = input({});
|
|
1608
|
+
fields = input(null);
|
|
1609
|
+
fieldChanges = new Subject();
|
|
1610
|
+
language = toSignal(this.events.languageChanged, {
|
|
1611
|
+
initialValue: this.languages.currentLanguage
|
|
1612
|
+
});
|
|
1613
|
+
enableTranslations = toSignal(this.events.translationsEnabled, {
|
|
1614
|
+
initialValue: this.languages.enableTranslations
|
|
1615
|
+
});
|
|
1616
|
+
config = computed(() => {
|
|
1617
|
+
const options = {
|
|
1618
|
+
labelPrefix: this.labelPrefix(),
|
|
1619
|
+
labelCustomizer: this.labelCustomizer(),
|
|
1620
|
+
testId: this.testId(),
|
|
1624
1621
|
};
|
|
1622
|
+
const fields = this.fields() || this.builder.resolveFormFields(this.data()?.constructor, null, options);
|
|
1623
|
+
return [
|
|
1624
|
+
this.builder.createFormGroup(null, () => fields, {
|
|
1625
|
+
label: "",
|
|
1626
|
+
useTabs: this.useTabs(),
|
|
1627
|
+
hidden: false,
|
|
1628
|
+
className: "dynamic-form-root-group"
|
|
1629
|
+
}, null, options)
|
|
1630
|
+
];
|
|
1631
|
+
});
|
|
1632
|
+
group = computed(() => {
|
|
1633
|
+
this.config();
|
|
1634
|
+
return new FormGroup$1({});
|
|
1635
|
+
});
|
|
1636
|
+
status$ = rxResource({
|
|
1637
|
+
request: () => this.group(),
|
|
1638
|
+
loader: p => controlStatus(p.request),
|
|
1639
|
+
defaultValue: "PENDING"
|
|
1640
|
+
});
|
|
1641
|
+
status = computed(() => this.status$.value());
|
|
1642
|
+
onSubmit = output();
|
|
1643
|
+
onChanges = outputFromObservable(this.fieldChanges);
|
|
1644
|
+
options = {
|
|
1645
|
+
fieldChanges: this.fieldChanges,
|
|
1646
|
+
formState: {
|
|
1647
|
+
injector: inject(Injector)
|
|
1648
|
+
}
|
|
1649
|
+
};
|
|
1650
|
+
constructor() {
|
|
1625
1651
|
effect(() => {
|
|
1626
1652
|
this.language();
|
|
1627
1653
|
this.enableTranslations();
|
|
@@ -1638,8 +1664,8 @@ class DynamicFormComponent {
|
|
|
1638
1664
|
reset() {
|
|
1639
1665
|
this.options?.resetModel?.();
|
|
1640
1666
|
}
|
|
1641
|
-
static
|
|
1642
|
-
static
|
|
1667
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1668
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.14", type: DynamicFormComponent, isStandalone: false, selector: "dynamic-form", inputs: { labelPrefix: { classPropertyName: "labelPrefix", publicName: "labelPrefix", isSignal: true, isRequired: false, transformFunction: null }, labelCustomizer: { classPropertyName: "labelCustomizer", publicName: "labelCustomizer", isSignal: true, isRequired: false, transformFunction: null }, testId: { classPropertyName: "testId", publicName: "testId", isSignal: true, isRequired: false, transformFunction: null }, useTabs: { classPropertyName: "useTabs", publicName: "useTabs", isSignal: true, isRequired: false, transformFunction: null }, data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: false, transformFunction: null }, fields: { classPropertyName: "fields", publicName: "fields", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onSubmit: "onSubmit", onChanges: "onChanges" }, ngImport: i0, template: "@if (config() && group()) {\n <form [formGroup]=\"group()\" (ngSubmit)=\"submit()\" autocomplete=\"off\" role=\"presentation\">\n <input type=\"submit\" [hidden]=\"true\" />\n <formly-form [model]=\"data()\"\n [fields]=\"config()\"\n [form]=\"group()\"\n [options]=\"options\"></formly-form>\n <ng-content></ng-content>\n </form>\n}\n", styles: [".dynamic-form-field.dynamic-form-hidden{display:none}\n"], dependencies: [{ kind: "directive", type: i1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i3.LegacyFormlyForm, selector: "formly-form" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1643
1669
|
}
|
|
1644
1670
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormComponent, decorators: [{
|
|
1645
1671
|
type: Component,
|
|
@@ -1647,10 +1673,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
1647
1673
|
}], ctorParameters: () => [] });
|
|
1648
1674
|
|
|
1649
1675
|
class DynamicFormArrayComponent extends FieldArrayType {
|
|
1650
|
-
|
|
1651
|
-
super(...arguments);
|
|
1652
|
-
this.currentTab = signal(0);
|
|
1653
|
-
}
|
|
1676
|
+
currentTab = signal(0);
|
|
1654
1677
|
clearItems() {
|
|
1655
1678
|
const control = this.formControl;
|
|
1656
1679
|
while (control.length > 0) {
|
|
@@ -1668,8 +1691,8 @@ class DynamicFormArrayComponent extends FieldArrayType {
|
|
|
1668
1691
|
const length = this.field.fieldGroup.length;
|
|
1669
1692
|
this.currentTab.set(Math.min(this.currentTab(), length - 1));
|
|
1670
1693
|
}
|
|
1671
|
-
static
|
|
1672
|
-
static
|
|
1694
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormArrayComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
1695
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.14", type: DynamicFormArrayComponent, isStandalone: false, selector: "dynamic-form-array", usesInheritance: true, ngImport: i0, template: "@if (field.display) {\n @if (props.label && props.hideLabel !== true) {\n <label class=\"field-label\">\n {{ props.label | translate }}\n <p class=\"field-description\" *ngIf=\"props.description\">{{ props.description | translate }}</p>\n </label>\n }\n <div class=\"field-container\">\n <tabs class=\"form-array-items\" [(value)]=\"currentTab\">\n @for (itemField of field.fieldGroup; track itemField.key; let ix = $index) {\n <ng-template #fieldContent>\n <div class=\"form-array-buttons\">\n @if (itemField.removeItem) {\n <btn icon=\"trash\" (click)=\"removeItem(ix)\"></btn>\n }\n @if (itemField.insertItem) {\n <btn icon=\"plus\" (click)=\"addItem(ix)\"></btn>\n }\n </div>\n <formly-field [field]=\"itemField\"></formly-field>\n </ng-template>\n @if (props.useTabs) {\n <div class=\"form-array-item\"\n [tabsItem]=\"ix\"\n [label]=\"(itemField.formControl.value | getValue : props.tabsLabel) || ix + 1\">\n <ng-container [ngTemplateOutlet]=\"fieldContent\"></ng-container>\n </div>\n } @else {\n <div class=\"form-array-item\">\n <ng-container [ngTemplateOutlet]=\"fieldContent\"></ng-container>\n </div>\n }\n }\n </tabs>\n\n <div class=\"form-array-buttons\">\n @if (props.clearItems) {\n <btn icon=\"trash\" label=\"button.clear-items\" (click)=\"clearItems()\"></btn>\n }\n @if (props.addItem) {\n <btn icon=\"plus\" label=\"button.insert-item\" (click)=\"addItem()\"></btn>\n }\n </div>\n </div>\n}\n", styles: [".form-array-item.hidden-tab{display:none}.form-array-buttons{display:flex;gap:5px;margin-bottom:5px}\n"], dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.TabsItemDirective, selector: "[tabsItem]", inputs: ["tabsItem", "label", "tooltip", "icon", "disabled", "classes"] }, { kind: "component", type: i2.BtnComponent, selector: "btn", inputs: ["label", "tooltip", "icon", "disabled", "type", "size"] }, { kind: "component", type: i2.TabsComponent, selector: "tabs", inputs: ["value", "options", "type", "size", "testId", "tabsClass"], outputs: ["valueChange", "selectedChange"] }, { kind: "component", type: i3.LegacyFormlyField, selector: "formly-field" }, { kind: "pipe", type: i2.GetValuePipe, name: "getValue" }, { kind: "pipe", type: i2.TranslatePipe, name: "translate" }], encapsulation: i0.ViewEncapsulation.None });
|
|
1673
1696
|
}
|
|
1674
1697
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormArrayComponent, decorators: [{
|
|
1675
1698
|
type: Component,
|
|
@@ -1677,8 +1700,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
1677
1700
|
}] });
|
|
1678
1701
|
|
|
1679
1702
|
class DynamicFormChipsComponent extends DynamicFieldType {
|
|
1680
|
-
static
|
|
1681
|
-
static
|
|
1703
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormChipsComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
1704
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: DynamicFormChipsComponent, isStandalone: false, selector: "dynamic-form-chips", usesInheritance: true, ngImport: i0, template: "<chips [formControl]=\"formControl\"\n [type]=\"props.type\"\n [step]=\"props.step\"\n [minLength]=\"props.minLength\"\n [maxLength]=\"props.maxLength\"\n [min]=\"props.min\"\n [max]=\"props.max\"\n [multiple]=\"props.multiple\"\n [formlyAttributes]=\"field\">\n</chips>\n", dependencies: [{ 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: "component", type: i2.ChipsComponent, selector: "chips", inputs: ["value", "multiple", "disabled", "type", "min", "max", "minLength", "maxLength", "step", "placeholder", "unique", "options"], outputs: ["valueChange"] }, { kind: "directive", type: i3.LegacyFormlyAttributes, selector: "[formlyAttributes]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1682
1705
|
}
|
|
1683
1706
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormChipsComponent, decorators: [{
|
|
1684
1707
|
type: Component,
|
|
@@ -1686,8 +1709,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
1686
1709
|
}] });
|
|
1687
1710
|
|
|
1688
1711
|
class DynamicFormUploadComponent extends DynamicFieldType {
|
|
1689
|
-
static
|
|
1690
|
-
static
|
|
1712
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormUploadComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
1713
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: DynamicFormUploadComponent, isStandalone: false, selector: "dynamic-form-upload", usesInheritance: true, ngImport: i0, template: "<upload [formControl]=\"formControl\"\n [multiple]=\"props.multiple\"\n [inline]=\"props.inline\"\n [accept]=\"props.accept\"\n [baseUrl]=\"props.url\"\n [makeUpload]=\"props.createUploadData\"\n [formlyAttributes]=\"field\">\n</upload>\n", dependencies: [{ 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: "component", type: i2.UploadComponent, selector: "upload", inputs: ["value", "disabled", "inline", "accept", "baseUrl", "message", "multiple", "buttonText", "makeUpload", "preProcess"], outputs: ["onUploaded", "onRemove"] }, { kind: "directive", type: i3.LegacyFormlyAttributes, selector: "[formlyAttributes]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1691
1714
|
}
|
|
1692
1715
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormUploadComponent, decorators: [{
|
|
1693
1716
|
type: Component,
|
|
@@ -1698,8 +1721,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
1698
1721
|
* This is just a test wrapper component
|
|
1699
1722
|
*/
|
|
1700
1723
|
class DynamicFormAlertComponent extends FieldWrapper {
|
|
1701
|
-
static
|
|
1702
|
-
static
|
|
1724
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormAlertComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
1725
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.14", type: DynamicFormAlertComponent, isStandalone: false, selector: "dynamic-form-alert", usesInheritance: true, ngImport: i0, template: "<div class=\"dynamic-form-alert\">\n <ng-container #fieldComponent></ng-container>\n</div>\n", styles: [".dynamic-form-alert{border:2px dashed red;width:100%}\n"], encapsulation: i0.ViewEncapsulation.None });
|
|
1703
1726
|
}
|
|
1704
1727
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormAlertComponent, decorators: [{
|
|
1705
1728
|
type: Component,
|
|
@@ -1707,8 +1730,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
1707
1730
|
}] });
|
|
1708
1731
|
|
|
1709
1732
|
class DynamicFormFieldComponent extends FieldWrapper {
|
|
1710
|
-
static
|
|
1711
|
-
static
|
|
1733
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormFieldComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
1734
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.14", type: DynamicFormFieldComponent, isStandalone: false, selector: "dynamic-form-field", usesInheritance: true, ngImport: i0, template: "@if (props.label && props.hideLabel !== true) {\n <label class=\"field-label\" [for]=\"id\">\n {{ props.label | translate }}\n <p class=\"field-description\" *ngIf=\"props.description\">{{ props.description | translate }}</p>\n @if (props.required && props.hideRequiredMarker !== true) {\n <span class=\"field-required\" aria-hidden=\"true\">*</span>\n }\n </label>\n}\n<div class=\"field-container\">\n <ng-container #fieldComponent></ng-container>\n <div *ngIf=\"showError\" class=\"field-errors invalid-feedback\">\n <formly-validation-message\n [field]=\"field\"\n id=\"{{ id }}-formly-validation-error\"\n role=\"alert\"\n ></formly-validation-message>\n </div>\n</div>\n", dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i3.LegacyFormlyValidationMessage, selector: "formly-validation-message" }, { kind: "pipe", type: i2.TranslatePipe, name: "translate" }], encapsulation: i0.ViewEncapsulation.None });
|
|
1712
1735
|
}
|
|
1713
1736
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormFieldComponent, decorators: [{
|
|
1714
1737
|
type: Component,
|
|
@@ -1716,8 +1739,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
1716
1739
|
}] });
|
|
1717
1740
|
|
|
1718
1741
|
class DynamicFormFieldsetComponent extends FieldWrapper {
|
|
1719
|
-
static
|
|
1720
|
-
static
|
|
1742
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormFieldsetComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
1743
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.14", type: DynamicFormFieldsetComponent, isStandalone: false, selector: "dynamic-form-fieldset", usesInheritance: true, ngImport: i0, template: "@if (field.display) {\n <legend class=\"field-legend\" *ngIf=\"props.label && !field.parent.props.useTabs\">\n {{ props.label | translate }}\n </legend>\n <div class=\"field-container\">\n @for (itemField of field.fieldGroup; track itemField) {\n @if (itemField.display) {\n <formly-field [field]=\"itemField\"></formly-field>\n }\n }\n </div>\n}\n", dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i3.LegacyFormlyField, selector: "formly-field" }, { kind: "pipe", type: i2.TranslatePipe, name: "translate" }], encapsulation: i0.ViewEncapsulation.None });
|
|
1721
1744
|
}
|
|
1722
1745
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormFieldsetComponent, decorators: [{
|
|
1723
1746
|
type: Component,
|
|
@@ -1725,8 +1748,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
|
|
|
1725
1748
|
}] });
|
|
1726
1749
|
|
|
1727
1750
|
class DynamicFormGroupComponent extends FieldWrapper {
|
|
1728
|
-
static
|
|
1729
|
-
static
|
|
1751
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormGroupComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
1752
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.14", type: DynamicFormGroupComponent, isStandalone: false, selector: "dynamic-form-group", usesInheritance: true, ngImport: i0, template: "@if (field.display) {\n @if (props.label && props.hideLabel !== true) {\n <label class=\"field-label\">\n {{ props.label | translate }}\n <p class=\"field-description\" *ngIf=\"props.description\">{{ props.description | translate }}</p>\n </label>\n }\n <tabs class=\"field-container\">\n @for (itemField of field.fieldGroup; track itemField; let ix = $index) {\n @if (itemField.display) {\n @if (props.useTabs && itemField.wrappers | includes: 'form-fieldset') {\n <div class=\"form-fieldset-item\"\n [tabsItem]=\"ix\"\n [classes]=\"['form-fieldset-tab', itemField.valid ? 'valid' : 'invalid']\"\n [label]=\"itemField.props.label\">\n <formly-field [field]=\"itemField\"></formly-field>\n </div>\n } @else {\n <formly-field [field]=\"itemField\"></formly-field>\n }\n }\n }\n </tabs>\n}\n", styles: [".form-fieldset-item.hidden-tab{display:none}.form-fieldset-tab{position:relative;--invalid-bg: rgba(184, 38, 38, 1);--invalid-border: rgba(184, 38, 38, .6);--invalid-color: #ececec;--invalid-box-size: 15px;--invalid-box-pull: -3px}.form-fieldset-tab.invalid>btn .async-target{border:1px solid var(--invalid-border)}.form-fieldset-tab.invalid:after{background:var(--invalid-bg);color:var(--invalid-color);font-size:10px;line-height:var(--invalid-box-size);width:var(--invalid-box-size);height:var(--invalid-box-size);text-align:center;border-radius:5px;content:\"!\";display:block;position:absolute;top:var(--invalid-box-pull);right:var(--invalid-box-pull)}\n"], dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.TabsItemDirective, selector: "[tabsItem]", inputs: ["tabsItem", "label", "tooltip", "icon", "disabled", "classes"] }, { kind: "component", type: i2.TabsComponent, selector: "tabs", inputs: ["value", "options", "type", "size", "testId", "tabsClass"], outputs: ["valueChange", "selectedChange"] }, { kind: "component", type: i3.LegacyFormlyField, selector: "formly-field" }, { kind: "pipe", type: i2.IncludesPipe, name: "includes" }, { kind: "pipe", type: i2.TranslatePipe, name: "translate" }], encapsulation: i0.ViewEncapsulation.None });
|
|
1730
1753
|
}
|
|
1731
1754
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: DynamicFormGroupComponent, decorators: [{
|
|
1732
1755
|
type: Component,
|
|
@@ -1788,16 +1811,16 @@ class NgxDynamicFormModule {
|
|
|
1788
1811
|
static provideForms(config) {
|
|
1789
1812
|
return makeEnvironmentProviders(NgxDynamicFormModule.getProviders(config));
|
|
1790
1813
|
}
|
|
1791
|
-
static
|
|
1792
|
-
static
|
|
1814
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: NgxDynamicFormModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1815
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.2.14", ngImport: i0, type: NgxDynamicFormModule, declarations: [DynamicFieldType, DynamicFormComponent, DynamicFormArrayComponent, DynamicFormChipsComponent, DynamicFormUploadComponent, DynamicFormAlertComponent, DynamicFormFieldComponent, DynamicFormFieldsetComponent, DynamicFormGroupComponent, AsyncSubmitDirective], imports: [CommonModule,
|
|
1793
1816
|
FormsModule,
|
|
1794
1817
|
ReactiveFormsModule,
|
|
1795
1818
|
NgxUtilsModule,
|
|
1796
1819
|
FormlyModule], exports: [DynamicFieldType, DynamicFormComponent, DynamicFormArrayComponent, DynamicFormChipsComponent, DynamicFormUploadComponent, DynamicFormAlertComponent, DynamicFormFieldComponent, DynamicFormFieldsetComponent, DynamicFormGroupComponent, AsyncSubmitDirective, FormsModule,
|
|
1797
1820
|
ReactiveFormsModule,
|
|
1798
1821
|
NgxUtilsModule,
|
|
1799
|
-
FormlyModule] });
|
|
1800
|
-
static
|
|
1822
|
+
FormlyModule] });
|
|
1823
|
+
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: NgxDynamicFormModule, providers: [
|
|
1801
1824
|
...pipes
|
|
1802
1825
|
], imports: [CommonModule,
|
|
1803
1826
|
FormsModule,
|
|
@@ -1806,7 +1829,7 @@ class NgxDynamicFormModule {
|
|
|
1806
1829
|
FormlyModule, FormsModule,
|
|
1807
1830
|
ReactiveFormsModule,
|
|
1808
1831
|
NgxUtilsModule,
|
|
1809
|
-
FormlyModule] });
|
|
1832
|
+
FormlyModule] });
|
|
1810
1833
|
}
|
|
1811
1834
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: NgxDynamicFormModule, decorators: [{
|
|
1812
1835
|
type: NgModule,
|