@ngx-formly/core 6.3.11 → 7.0.0-alpha.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 -0
- package/esm2022/json-schema/formly-json-schema.service.mjs +628 -0
- package/esm2022/lib/components/formly.field.mjs +292 -0
- package/esm2022/lib/components/formly.form.mjs +164 -0
- package/{esm2020 → esm2022}/lib/components/formly.template.mjs +7 -7
- package/esm2022/lib/core.config.mjs +36 -0
- package/esm2022/lib/core.mjs +20 -0
- package/esm2022/lib/core.module.mjs +74 -0
- package/esm2022/lib/extensions/core/core.mjs +148 -0
- package/esm2022/lib/extensions/field-expression/field-expression.mjs +250 -0
- package/esm2022/lib/extensions/field-expression/utils.mjs +17 -0
- package/esm2022/lib/extensions/field-form/field-form.mjs +141 -0
- package/esm2022/lib/extensions/field-form/utils.mjs +100 -0
- package/esm2022/lib/extensions/index.mjs +2 -0
- package/esm2022/lib/models/fieldconfig.cache.mjs +2 -0
- package/esm2022/lib/models/fieldconfig.mjs +2 -0
- package/esm2022/lib/services/formly.builder.mjs +100 -0
- package/esm2022/lib/services/formly.config.mjs +229 -0
- package/esm2022/lib/templates/field-array.type.mjs +84 -0
- package/{esm2020 → esm2022}/lib/templates/field-template.type.mjs +9 -9
- package/esm2022/lib/templates/field.type.mjs +57 -0
- package/{esm2020 → esm2022}/lib/templates/field.wrapper.mjs +4 -4
- package/esm2022/lib/templates/formly.attributes.mjs +187 -0
- package/{esm2020 → esm2022}/lib/templates/formly.group.mjs +8 -8
- package/{esm2020 → esm2022}/lib/templates/formly.validation-message.mjs +4 -4
- package/esm2022/lib/utils.mjs +312 -0
- package/esm2022/preset/preset.config.mjs +11 -0
- package/esm2022/preset/preset.module.mjs +18 -0
- package/{esm2020 → esm2022}/select/select-options.pipe.mjs +4 -4
- package/{esm2020 → esm2022}/select/select.module.mjs +5 -5
- package/{esm2020 → esm2022}/testing/component-factory.mjs +5 -4
- package/{fesm2020 → fesm2022}/ngx-formly-core-json-schema.mjs +6 -6
- package/fesm2022/ngx-formly-core-json-schema.mjs.map +1 -0
- package/{fesm2020 → fesm2022}/ngx-formly-core-preset.mjs +14 -19
- package/fesm2022/ngx-formly-core-preset.mjs.map +1 -0
- package/{fesm2020 → fesm2022}/ngx-formly-core-select.mjs +7 -7
- package/{fesm2020 → fesm2022}/ngx-formly-core-select.mjs.map +1 -1
- package/{fesm2020 → fesm2022}/ngx-formly-core-testing.mjs +4 -3
- package/fesm2022/ngx-formly-core-testing.mjs.map +1 -0
- package/{fesm2020 → fesm2022}/ngx-formly-core.mjs +1750 -1705
- package/fesm2022/ngx-formly-core.mjs.map +1 -0
- package/lib/components/formly.field.d.ts +5 -1
- package/lib/components/formly.form.d.ts +8 -4
- package/lib/components/formly.template.d.ts +1 -1
- package/lib/core.config.d.ts +10 -0
- package/lib/core.d.ts +4 -3
- package/lib/core.module.d.ts +2 -5
- package/lib/extensions/field-expression/utils.d.ts +1 -1
- package/lib/extensions/index.d.ts +1 -0
- package/lib/models/config.d.ts +1 -1
- package/lib/models/fieldconfig.cache.d.ts +3 -3
- package/lib/models/fieldconfig.d.ts +8 -7
- package/lib/services/formly.builder.d.ts +5 -5
- package/lib/services/formly.config.d.ts +2 -6
- package/lib/templates/field-array.type.d.ts +3 -3
- package/lib/templates/field-template.type.d.ts +1 -1
- package/lib/templates/field.type.d.ts +5 -5
- package/lib/templates/field.wrapper.d.ts +1 -1
- package/lib/templates/formly.attributes.d.ts +1 -1
- package/lib/templates/formly.group.d.ts +1 -1
- package/lib/templates/formly.validation-message.d.ts +1 -1
- package/lib/utils.d.ts +3 -3
- package/package.json +23 -37
- package/preset/preset.config.d.ts +2 -0
- package/select/select-options.pipe.d.ts +1 -1
- package/esm2020/json-schema/formly-json-schema.service.mjs +0 -628
- package/esm2020/lib/components/formly.field.mjs +0 -284
- package/esm2020/lib/components/formly.form.mjs +0 -147
- package/esm2020/lib/core.mjs +0 -19
- package/esm2020/lib/core.module.mjs +0 -91
- package/esm2020/lib/extensions/core/core.mjs +0 -148
- package/esm2020/lib/extensions/field-expression/field-expression.mjs +0 -250
- package/esm2020/lib/extensions/field-expression/utils.mjs +0 -17
- package/esm2020/lib/extensions/field-form/field-form.mjs +0 -141
- package/esm2020/lib/extensions/field-form/utils.mjs +0 -100
- package/esm2020/lib/models/fieldconfig.cache.mjs +0 -2
- package/esm2020/lib/models/fieldconfig.mjs +0 -2
- package/esm2020/lib/services/formly.builder.mjs +0 -93
- package/esm2020/lib/services/formly.config.mjs +0 -229
- package/esm2020/lib/templates/field-array.type.mjs +0 -84
- package/esm2020/lib/templates/field.type.mjs +0 -57
- package/esm2020/lib/templates/formly.attributes.mjs +0 -187
- package/esm2020/lib/utils.mjs +0 -312
- package/esm2020/preset/preset.module.mjs +0 -32
- package/fesm2015/ngx-formly-core-json-schema.mjs +0 -615
- package/fesm2015/ngx-formly-core-json-schema.mjs.map +0 -1
- package/fesm2015/ngx-formly-core-preset.mjs +0 -69
- package/fesm2015/ngx-formly-core-preset.mjs.map +0 -1
- package/fesm2015/ngx-formly-core-select.mjs +0 -120
- package/fesm2015/ngx-formly-core-select.mjs.map +0 -1
- package/fesm2015/ngx-formly-core-testing.mjs +0 -87
- package/fesm2015/ngx-formly-core-testing.mjs.map +0 -1
- package/fesm2015/ngx-formly-core.mjs +0 -2417
- package/fesm2015/ngx-formly-core.mjs.map +0 -1
- package/fesm2020/ngx-formly-core-json-schema.mjs.map +0 -1
- package/fesm2020/ngx-formly-core-preset.mjs.map +0 -1
- package/fesm2020/ngx-formly-core-testing.mjs.map +0 -1
- package/fesm2020/ngx-formly-core.mjs.map +0 -1
- package/json-schema/package.json +0 -10
- package/preset/package.json +0 -10
- package/select/package.json +0 -10
- package/testing/package.json +0 -10
- /package/{esm2020 → esm2022}/json-schema/ngx-formly-core-json-schema.mjs +0 -0
- /package/{esm2020 → esm2022}/json-schema/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/extensions/field-validation/field-validation.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/models/config.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/models/index.mjs +0 -0
- /package/{esm2020 → esm2022}/ngx-formly-core.mjs +0 -0
- /package/{esm2020 → esm2022}/preset/ngx-formly-core-preset.mjs +0 -0
- /package/{esm2020 → esm2022}/preset/preset-substitution.extension.mjs +0 -0
- /package/{esm2020 → esm2022}/preset/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/select/ngx-formly-core-select.mjs +0 -0
- /package/{esm2020 → esm2022}/select/public_api.mjs +0 -0
- /package/{esm2020 → esm2022}/testing/ngx-formly-core-testing.mjs +0 -0
- /package/{esm2020 → esm2022}/testing/public_api.mjs +0 -0
- /package/{ngx-formly-core.d.ts → index.d.ts} +0 -0
- /package/json-schema/{ngx-formly-core-json-schema.d.ts → index.d.ts} +0 -0
- /package/preset/{ngx-formly-core-preset.d.ts → index.d.ts} +0 -0
- /package/select/{ngx-formly-core-select.d.ts → index.d.ts} +0 -0
- /package/testing/{ngx-formly-core-testing.d.ts → index.d.ts} +0 -0
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { ComponentRef, ElementRef, EmbeddedViewRef, Injector, ViewContainerRef } from '@angular/core';
|
|
2
|
-
import { AsyncValidatorFn, ValidatorFn,
|
|
2
|
+
import { AsyncValidatorFn, ValidatorFn, UntypedFormArray, UntypedFormGroup, AbstractControl } from '@angular/forms';
|
|
3
3
|
import { Observable, Subscription } from 'rxjs';
|
|
4
4
|
import { FieldType } from '../templates/field.type';
|
|
5
5
|
import { FormlyExtension } from './config';
|
|
6
6
|
import { FormlyFieldConfig, FormlyFormOptions } from './fieldconfig';
|
|
7
7
|
export interface FormlyFieldConfigCache extends FormlyFieldConfig {
|
|
8
|
-
form?:
|
|
8
|
+
form?: UntypedFormGroup | UntypedFormArray;
|
|
9
9
|
model?: any;
|
|
10
10
|
formControl?: AbstractControl & {
|
|
11
11
|
_fields?: FormlyFieldConfigCache[];
|
|
12
12
|
_childrenErrors?: {
|
|
13
|
-
[id: string]:
|
|
13
|
+
[id: string]: () => void;
|
|
14
14
|
};
|
|
15
15
|
};
|
|
16
16
|
parent?: FormlyFieldConfigCache;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { UntypedFormGroup, UntypedFormArray, AbstractControl, FormGroupDirective, ValidatorFn, AsyncValidatorFn } from '@angular/forms';
|
|
2
2
|
import { Subject, Observable } from 'rxjs';
|
|
3
3
|
import { FieldType } from '../templates/field.type';
|
|
4
4
|
import { FieldWrapper } from '../templates/field.wrapper';
|
|
5
5
|
import { ValidationMessageOption } from '../models';
|
|
6
6
|
import { Type } from '@angular/core';
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
type FieldExpression<T = any> = string | ((field: FormlyFieldConfig) => T) | Observable<T>;
|
|
8
|
+
type FieldExpressions = {
|
|
9
9
|
[property: string]: FieldExpression;
|
|
10
10
|
} & {
|
|
11
11
|
className?: FieldExpression<string>;
|
|
@@ -157,7 +157,7 @@ export interface FormlyFieldConfig<Props = FormlyFieldProps & {
|
|
|
157
157
|
/**
|
|
158
158
|
* The parent form.
|
|
159
159
|
*/
|
|
160
|
-
readonly form?:
|
|
160
|
+
readonly form?: UntypedFormGroup | UntypedFormArray;
|
|
161
161
|
/**
|
|
162
162
|
* This is the [FormControl](https://angular.io/api/forms/FormControl) for the field.
|
|
163
163
|
* It provides you more control like running validators, calculating status, and resetting state.
|
|
@@ -166,7 +166,7 @@ export interface FormlyFieldConfig<Props = FormlyFieldProps & {
|
|
|
166
166
|
/** @deprecated */
|
|
167
167
|
optionsTypes?: string[];
|
|
168
168
|
}
|
|
169
|
-
export
|
|
169
|
+
export type FormlyAttributeEvent = (field: FormlyFieldConfig, event?: any) => void;
|
|
170
170
|
/** @deprecated */
|
|
171
171
|
export interface FormlyTemplateOptions extends FormlyFieldProps {
|
|
172
172
|
[additionalProperties: string]: any;
|
|
@@ -204,8 +204,9 @@ export interface FormlyFieldProps {
|
|
|
204
204
|
click?: FormlyAttributeEvent;
|
|
205
205
|
change?: FormlyAttributeEvent;
|
|
206
206
|
keypress?: FormlyAttributeEvent;
|
|
207
|
+
wheel?: FormlyAttributeEvent;
|
|
207
208
|
}
|
|
208
|
-
export
|
|
209
|
+
export type FormlyHookFn = (field: FormlyFieldConfig) => void;
|
|
209
210
|
export interface FormlyHookConfig {
|
|
210
211
|
onInit?: FormlyHookFn | ((field: FormlyFieldConfig) => Observable<any>);
|
|
211
212
|
onChanges?: FormlyHookFn;
|
|
@@ -234,7 +235,7 @@ interface FormlyValidation<T, R> {
|
|
|
234
235
|
validation?: (string | T)[] | any;
|
|
235
236
|
[key: string]: FormlyValidatorFn<R> | FormlyValidatorExpressionFn<R> | any;
|
|
236
237
|
}
|
|
237
|
-
|
|
238
|
+
type FormlyValidatorFn<T> = (control: AbstractControl, field: FormlyFieldConfig) => T;
|
|
238
239
|
interface FormlyValidatorExpressionFn<T> {
|
|
239
240
|
expression: FormlyValidatorFn<T>;
|
|
240
241
|
message: string | ((error: any, field: FormlyFieldConfig) => string | Observable<string>);
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import { Injector, ViewContainerRef } from '@angular/core';
|
|
2
|
-
import {
|
|
2
|
+
import { UntypedFormGroup, UntypedFormArray, FormGroupDirective } from '@angular/forms';
|
|
3
3
|
import { FormlyConfig } from './formly.config';
|
|
4
|
-
import { FormlyFieldConfig, FormlyFormOptions } from '../models';
|
|
4
|
+
import { FormlyFieldConfig, FormlyFormOptions, ConfigOption } from '../models';
|
|
5
5
|
import * as i0 from "@angular/core";
|
|
6
6
|
export declare class FormlyFormBuilder {
|
|
7
7
|
private config;
|
|
8
8
|
private injector;
|
|
9
9
|
private viewContainerRef;
|
|
10
10
|
private parentForm;
|
|
11
|
-
constructor(config: FormlyConfig, injector: Injector, viewContainerRef: ViewContainerRef, parentForm: FormGroupDirective);
|
|
12
|
-
buildForm(form:
|
|
11
|
+
constructor(config: FormlyConfig, injector: Injector, viewContainerRef: ViewContainerRef, parentForm: FormGroupDirective, configs?: ConfigOption[]);
|
|
12
|
+
buildForm(form: UntypedFormGroup | UntypedFormArray, fieldGroup: FormlyFieldConfig[], model: any, options: FormlyFormOptions): void;
|
|
13
13
|
build(field: FormlyFieldConfig): void;
|
|
14
14
|
private _build;
|
|
15
15
|
private _setOptions;
|
|
16
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<FormlyFormBuilder, [null, null, { optional: true; }, { optional: true; }]>;
|
|
16
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FormlyFormBuilder, [null, null, { optional: true; }, { optional: true; }, { optional: true; }]>;
|
|
17
17
|
static ɵprov: i0.ɵɵInjectableDeclaration<FormlyFormBuilder>;
|
|
18
18
|
}
|
|
@@ -1,12 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ComponentRef, Type } from '@angular/core';
|
|
2
2
|
import { FieldType } from './../templates/field.type';
|
|
3
3
|
import { FormlyFieldConfig, FormlyFieldConfigCache, ConfigOption, TypeOption, ValidatorOption, WrapperOption, FormlyExtension, ValidationMessageOption, FormlyFieldConfigPresetProvider } from '../models';
|
|
4
4
|
import { FieldWrapper } from '../templates/field.wrapper';
|
|
5
5
|
import * as i0 from "@angular/core";
|
|
6
|
-
/**
|
|
7
|
-
* An InjectionToken for registering additional formly config options (types, wrappers ...).
|
|
8
|
-
*/
|
|
9
|
-
export declare const FORMLY_CONFIG: InjectionToken<ConfigOption[]>;
|
|
10
6
|
/**
|
|
11
7
|
* Maintains list of formly config options. This can be used to register new field type.
|
|
12
8
|
*/
|
|
@@ -31,7 +27,7 @@ export declare class FormlyConfig {
|
|
|
31
27
|
[name: string]: FormlyFieldConfig | FormlyFieldConfigPresetProvider;
|
|
32
28
|
};
|
|
33
29
|
private extensionsByPriority;
|
|
34
|
-
addConfig(config: ConfigOption): void;
|
|
30
|
+
addConfig(config: ConfigOption | ConfigOption[]): void;
|
|
35
31
|
/**
|
|
36
32
|
* Allows you to specify a custom type which you can use in your field configuration.
|
|
37
33
|
* You can pass an object of options, or an array of objects of options.
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { UntypedFormArray } from '@angular/forms';
|
|
2
2
|
import { FieldType } from './field.type';
|
|
3
3
|
import { FormlyFieldConfig, FormlyExtension } from '../models';
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
5
|
export interface FieldArrayTypeConfig<T = FormlyFieldConfig['props']> extends FormlyFieldConfig<T> {
|
|
6
|
-
formControl:
|
|
6
|
+
formControl: UntypedFormArray;
|
|
7
7
|
props: NonNullable<T>;
|
|
8
8
|
}
|
|
9
9
|
export declare abstract class FieldArrayType<F extends FormlyFieldConfig = FieldArrayTypeConfig> extends FieldType<F> implements FormlyExtension<F> {
|
|
@@ -18,5 +18,5 @@ export declare abstract class FieldArrayType<F extends FormlyFieldConfig = Field
|
|
|
18
18
|
private updateArrayElementKey;
|
|
19
19
|
private markFieldForCheck;
|
|
20
20
|
static ɵfac: i0.ɵɵFactoryDeclaration<FieldArrayType<any>, never>;
|
|
21
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<FieldArrayType<any>, never, never, {}, {}, never>;
|
|
21
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<FieldArrayType<any>, never, never, {}, {}, never, never, false, never>;
|
|
22
22
|
}
|
|
@@ -8,5 +8,5 @@ export declare class FormlyTemplateType extends FieldType {
|
|
|
8
8
|
private innerHtml;
|
|
9
9
|
constructor(sanitizer: DomSanitizer);
|
|
10
10
|
static ɵfac: i0.ɵɵFactoryDeclaration<FormlyTemplateType, never>;
|
|
11
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<FormlyTemplateType, "formly-template", never, {}, {}, never, never>;
|
|
11
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FormlyTemplateType, "formly-template", never, {}, {}, never, never, false, never>;
|
|
12
12
|
}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { QueryList } from '@angular/core';
|
|
2
|
-
import {
|
|
2
|
+
import { UntypedFormControl, NgControl, UntypedFormGroup } from '@angular/forms';
|
|
3
3
|
import { FormlyFieldConfig } from '../models';
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
5
|
export interface FieldTypeConfig<T = FormlyFieldConfig['props']> extends FormlyFieldConfig<T> {
|
|
6
|
-
formControl:
|
|
6
|
+
formControl: UntypedFormControl;
|
|
7
7
|
props: NonNullable<T>;
|
|
8
8
|
}
|
|
9
9
|
export interface FieldGroupTypeConfig<T = FormlyFieldConfig['props']> extends FormlyFieldConfig<T> {
|
|
10
|
-
formControl:
|
|
10
|
+
formControl: UntypedFormGroup;
|
|
11
11
|
props: NonNullable<T>;
|
|
12
12
|
}
|
|
13
13
|
export declare abstract class FieldType<F extends FormlyFieldConfig = FormlyFieldConfig> {
|
|
@@ -15,7 +15,7 @@ export declare abstract class FieldType<F extends FormlyFieldConfig = FormlyFiel
|
|
|
15
15
|
field: F;
|
|
16
16
|
defaultOptions?: Partial<F>;
|
|
17
17
|
get model(): any;
|
|
18
|
-
get form():
|
|
18
|
+
get form(): UntypedFormGroup | import("@angular/forms").UntypedFormArray;
|
|
19
19
|
get options(): import("../models").FormlyFormOptions;
|
|
20
20
|
get key(): string | number | (string | number)[];
|
|
21
21
|
get formControl(): NonNullable<F["formControl"]>;
|
|
@@ -26,5 +26,5 @@ export declare abstract class FieldType<F extends FormlyFieldConfig = FormlyFiel
|
|
|
26
26
|
get id(): string;
|
|
27
27
|
get formState(): any;
|
|
28
28
|
static ɵfac: i0.ɵɵFactoryDeclaration<FieldType<any>, never>;
|
|
29
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<FieldType<any>, never, never, { "field": "field"; }, {}, never>;
|
|
29
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<FieldType<any>, never, never, { "field": { "alias": "field"; "required": false; }; }, {}, never, never, false, never>;
|
|
30
30
|
}
|
|
@@ -8,5 +8,5 @@ export declare abstract class FieldWrapper<F extends FormlyFieldConfig = FormlyF
|
|
|
8
8
|
fieldComponent: ViewContainerRef;
|
|
9
9
|
set _staticContent(content: ViewContainerRef);
|
|
10
10
|
static ɵfac: i0.ɵɵFactoryDeclaration<FieldWrapper<any>, never>;
|
|
11
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<FieldWrapper<any>, never, never, {}, {}, never>;
|
|
11
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<FieldWrapper<any>, never, never, {}, {}, never, never, false, never>;
|
|
12
12
|
}
|
|
@@ -44,5 +44,5 @@ export declare class FormlyAttributes implements OnChanges, DoCheck, OnDestroy {
|
|
|
44
44
|
private setAttribute;
|
|
45
45
|
private removeAttribute;
|
|
46
46
|
static ɵfac: i0.ɵɵFactoryDeclaration<FormlyAttributes, never>;
|
|
47
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<FormlyAttributes, "[formlyAttributes]", never, { "field": "formlyAttributes"; "id": "id"; }, {}, never>;
|
|
47
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<FormlyAttributes, "[formlyAttributes]", never, { "field": { "alias": "formlyAttributes"; "required": false; }; "id": { "alias": "id"; "required": false; }; }, {}, never, never, false, never>;
|
|
48
48
|
}
|
|
@@ -3,5 +3,5 @@ import * as i0 from "@angular/core";
|
|
|
3
3
|
/** @ignore */
|
|
4
4
|
export declare class FormlyGroup extends FieldType<FieldGroupTypeConfig> {
|
|
5
5
|
static ɵfac: i0.ɵɵFactoryDeclaration<FormlyGroup, never>;
|
|
6
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<FormlyGroup, "formly-group", never, {}, {}, never, ["*"]>;
|
|
6
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FormlyGroup, "formly-group", never, {}, {}, never, ["*"], false, never>;
|
|
7
7
|
}
|
|
@@ -15,5 +15,5 @@ export declare class FormlyValidationMessage implements OnChanges {
|
|
|
15
15
|
ngOnChanges(): void;
|
|
16
16
|
get errorMessage(): string | Observable<string>;
|
|
17
17
|
static ɵfac: i0.ɵɵFactoryDeclaration<FormlyValidationMessage, never>;
|
|
18
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<FormlyValidationMessage, "formly-validation-message", never, { "field": "field"; }, {}, never, never>;
|
|
18
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FormlyValidationMessage, "formly-validation-message", never, { "field": { "alias": "field"; "required": false; }; }, {}, never, never, false, never>;
|
|
19
19
|
}
|
package/lib/utils.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { FormlyFieldConfig } from './models';
|
|
2
2
|
import { FormlyFieldConfigCache } from './models';
|
|
3
3
|
import { NgZone } from '@angular/core';
|
|
4
|
-
export declare function disableTreeValidityCall(form: any, callback:
|
|
4
|
+
export declare function disableTreeValidityCall(form: any, callback: () => void): void;
|
|
5
5
|
export declare function getFieldId(formId: string, field: FormlyFieldConfig, index: string | number): string;
|
|
6
6
|
export declare function hasKey(field: FormlyFieldConfig): boolean;
|
|
7
7
|
export declare function getKeyPath(field: FormlyFieldConfigCache): string[];
|
|
@@ -19,14 +19,14 @@ export declare function isObject(x: any): boolean;
|
|
|
19
19
|
export declare function isPromise(obj: any): obj is Promise<any>;
|
|
20
20
|
export declare function clone(value: any): any;
|
|
21
21
|
export declare function defineHiddenProp(field: any, prop: string, defaultValue: any): void;
|
|
22
|
-
|
|
22
|
+
type IObserveFn<T> = (change: {
|
|
23
23
|
currentValue: T;
|
|
24
24
|
previousValue?: T;
|
|
25
25
|
firstChange: boolean;
|
|
26
26
|
}) => void;
|
|
27
27
|
export interface IObserver<T> {
|
|
28
28
|
setValue: (value: T, emitEvent?: boolean) => void;
|
|
29
|
-
unsubscribe:
|
|
29
|
+
unsubscribe: () => void;
|
|
30
30
|
}
|
|
31
31
|
interface IObserveTarget<T> {
|
|
32
32
|
[prop: string]: any;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ngx-formly/core",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "7.0.0-alpha.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"dependencies": {
|
|
6
6
|
"tslib": "^2.0.0"
|
|
@@ -9,55 +9,41 @@
|
|
|
9
9
|
"@angular/forms": ">=13.2.0",
|
|
10
10
|
"rxjs": "^6.5.3 || ^7.0.0"
|
|
11
11
|
},
|
|
12
|
-
"module": "
|
|
13
|
-
"
|
|
14
|
-
"esm2020": "esm2020/ngx-formly-core.mjs",
|
|
15
|
-
"fesm2020": "fesm2020/ngx-formly-core.mjs",
|
|
16
|
-
"fesm2015": "fesm2015/ngx-formly-core.mjs",
|
|
17
|
-
"typings": "ngx-formly-core.d.ts",
|
|
12
|
+
"module": "fesm2022/ngx-formly-core.mjs",
|
|
13
|
+
"typings": "index.d.ts",
|
|
18
14
|
"exports": {
|
|
19
15
|
"./package.json": {
|
|
20
16
|
"default": "./package.json"
|
|
21
17
|
},
|
|
22
18
|
".": {
|
|
23
|
-
"types": "./
|
|
24
|
-
"
|
|
25
|
-
"
|
|
26
|
-
"
|
|
27
|
-
"node": "./fesm2015/ngx-formly-core.mjs",
|
|
28
|
-
"default": "./fesm2020/ngx-formly-core.mjs"
|
|
19
|
+
"types": "./index.d.ts",
|
|
20
|
+
"esm2022": "./esm2022/ngx-formly-core.mjs",
|
|
21
|
+
"esm": "./esm2022/ngx-formly-core.mjs",
|
|
22
|
+
"default": "./fesm2022/ngx-formly-core.mjs"
|
|
29
23
|
},
|
|
30
24
|
"./json-schema": {
|
|
31
|
-
"types": "./json-schema/
|
|
32
|
-
"
|
|
33
|
-
"
|
|
34
|
-
"
|
|
35
|
-
"node": "./fesm2015/ngx-formly-core-json-schema.mjs",
|
|
36
|
-
"default": "./fesm2020/ngx-formly-core-json-schema.mjs"
|
|
25
|
+
"types": "./json-schema/index.d.ts",
|
|
26
|
+
"esm2022": "./esm2022/json-schema/ngx-formly-core-json-schema.mjs",
|
|
27
|
+
"esm": "./esm2022/json-schema/ngx-formly-core-json-schema.mjs",
|
|
28
|
+
"default": "./fesm2022/ngx-formly-core-json-schema.mjs"
|
|
37
29
|
},
|
|
38
30
|
"./preset": {
|
|
39
|
-
"types": "./preset/
|
|
40
|
-
"
|
|
41
|
-
"
|
|
42
|
-
"
|
|
43
|
-
"node": "./fesm2015/ngx-formly-core-preset.mjs",
|
|
44
|
-
"default": "./fesm2020/ngx-formly-core-preset.mjs"
|
|
31
|
+
"types": "./preset/index.d.ts",
|
|
32
|
+
"esm2022": "./esm2022/preset/ngx-formly-core-preset.mjs",
|
|
33
|
+
"esm": "./esm2022/preset/ngx-formly-core-preset.mjs",
|
|
34
|
+
"default": "./fesm2022/ngx-formly-core-preset.mjs"
|
|
45
35
|
},
|
|
46
36
|
"./select": {
|
|
47
|
-
"types": "./select/
|
|
48
|
-
"
|
|
49
|
-
"
|
|
50
|
-
"
|
|
51
|
-
"node": "./fesm2015/ngx-formly-core-select.mjs",
|
|
52
|
-
"default": "./fesm2020/ngx-formly-core-select.mjs"
|
|
37
|
+
"types": "./select/index.d.ts",
|
|
38
|
+
"esm2022": "./esm2022/select/ngx-formly-core-select.mjs",
|
|
39
|
+
"esm": "./esm2022/select/ngx-formly-core-select.mjs",
|
|
40
|
+
"default": "./fesm2022/ngx-formly-core-select.mjs"
|
|
53
41
|
},
|
|
54
42
|
"./testing": {
|
|
55
|
-
"types": "./testing/
|
|
56
|
-
"
|
|
57
|
-
"
|
|
58
|
-
"
|
|
59
|
-
"node": "./fesm2015/ngx-formly-core-testing.mjs",
|
|
60
|
-
"default": "./fesm2020/ngx-formly-core-testing.mjs"
|
|
43
|
+
"types": "./testing/index.d.ts",
|
|
44
|
+
"esm2022": "./esm2022/testing/ngx-formly-core-testing.mjs",
|
|
45
|
+
"esm": "./esm2022/testing/ngx-formly-core-testing.mjs",
|
|
46
|
+
"default": "./fesm2022/ngx-formly-core-testing.mjs"
|
|
61
47
|
}
|
|
62
48
|
},
|
|
63
49
|
"sideEffects": false,
|
|
@@ -25,5 +25,5 @@ export declare class FormlySelectOptionsPipe implements PipeTransform, OnDestroy
|
|
|
25
25
|
private dispose;
|
|
26
26
|
private observableOf;
|
|
27
27
|
static ɵfac: i0.ɵɵFactoryDeclaration<FormlySelectOptionsPipe, never>;
|
|
28
|
-
static ɵpipe: i0.ɵɵPipeDeclaration<FormlySelectOptionsPipe, "formlySelectOptions">;
|
|
28
|
+
static ɵpipe: i0.ɵɵPipeDeclaration<FormlySelectOptionsPipe, "formlySelectOptions", false>;
|
|
29
29
|
}
|