@tft/crispr-forms 13.0.23 → 14.0.1-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 +77 -76
- package/esm2020/lib/abstracts/autocomplete-field.abstract.mjs +3 -3
- package/esm2020/lib/abstracts/crispr-field.abstract.mjs +3 -3
- package/esm2020/lib/crispr-forms.module.mjs +20 -21
- package/esm2020/lib/field-container/field-container.component.mjs +12 -14
- package/esm2020/lib/field.directive.mjs +8 -10
- package/esm2020/lib/form/form.component.mjs +45 -10
- package/esm2020/lib/form-group-list/form-group-list.component.mjs +8 -8
- package/esm2020/lib/form-group-list/form-group-list.module.mjs +12 -14
- package/esm2020/lib/form.helpers.mjs +1 -1
- package/esm2020/lib/material/autocomplete-chiplist-field/autocomplete-chiplist-field.component.mjs +70 -16
- package/esm2020/lib/material/autocomplete-field/autocomplete-field.component.mjs +62 -16
- package/esm2020/lib/material/button/button.component.mjs +47 -12
- package/esm2020/lib/material/checkbox-field/checkbox-field.component.mjs +49 -11
- package/esm2020/lib/material/datepicker-field/datepicker-field.component.mjs +60 -14
- package/esm2020/lib/material/divider/divider.component.mjs +31 -7
- package/esm2020/lib/material/file-upload/file-dropzone.directive.mjs +3 -3
- package/esm2020/lib/material/file-upload/file-upload.component.mjs +22 -24
- package/esm2020/lib/material/heading/heading.component.mjs +13 -15
- package/esm2020/lib/material/image-upload-field/image-upload-field.component.mjs +26 -28
- package/esm2020/lib/material/info/info.component.mjs +13 -15
- package/esm2020/lib/material/input-field/input-field.component.mjs +51 -12
- package/esm2020/lib/material/material.module.mjs +64 -168
- package/esm2020/lib/material/option/option.component.mjs +31 -7
- package/esm2020/lib/material/radio-field/radio-field.component.mjs +41 -10
- package/esm2020/lib/material/select-field/select-field.component.mjs +64 -14
- package/esm2020/lib/material/selected-file/selected-file.component.mjs +11 -13
- package/esm2020/lib/material/slider-field/slider-field.component.mjs +48 -9
- package/esm2020/lib/material/textarea-field/textarea-field.component.mjs +52 -13
- package/esm2020/lib/material/unit-conversion-field/unit-conversion-field.component.mjs +62 -16
- package/esm2020/lib/models/button.config.mjs +1 -1
- package/esm2020/lib/models/crispr-field.config.mjs +1 -1
- package/esm2020/lib/models/datepicker-field.config.mjs +1 -1
- package/esm2020/lib/pipes/crispr-pipes.module.mjs +5 -7
- package/esm2020/lib/pipes/initial-control-value.pipe.mjs +3 -3
- package/esm2020/lib/sub-group/sub-group.component.mjs +8 -8
- package/esm2020/lib/sub-group/sub-group.module.mjs +10 -12
- package/fesm2015/tft-crispr-forms.mjs +889 -505
- package/fesm2015/tft-crispr-forms.mjs.map +1 -1
- package/fesm2020/tft-crispr-forms.mjs +874 -490
- package/fesm2020/tft-crispr-forms.mjs.map +1 -1
- package/lib/abstracts/autocomplete-field.abstract.d.ts +4 -4
- package/lib/abstracts/crispr-field.abstract.d.ts +1 -1
- package/lib/crispr-forms.module.d.ts +11 -11
- package/lib/field-container/field-container.component.d.ts +2 -2
- package/lib/field.directive.d.ts +1 -1
- package/lib/form/form.component.d.ts +12 -2
- package/lib/form-group-list/form-group-list.component.d.ts +3 -3
- package/lib/form.helpers.d.ts +2 -2
- package/lib/material/autocomplete-chiplist-field/autocomplete-chiplist-field.component.d.ts +16 -1
- package/lib/material/autocomplete-field/autocomplete-field.component.d.ts +14 -1
- package/lib/material/button/button.component.d.ts +11 -1
- package/lib/material/checkbox-field/checkbox-field.component.d.ts +14 -3
- package/lib/material/datepicker-field/datepicker-field.component.d.ts +18 -6
- package/lib/material/divider/divider.component.d.ts +8 -1
- package/lib/material/file-upload/file-dropzone.directive.d.ts +1 -1
- package/lib/material/file-upload/file-upload.component.d.ts +3 -3
- package/lib/material/heading/heading.component.d.ts +1 -1
- package/lib/material/image-upload-field/image-upload-field.component.d.ts +3 -3
- package/lib/material/info/info.component.d.ts +1 -1
- package/lib/material/input-field/input-field.component.d.ts +14 -3
- package/lib/material/material.module.d.ts +21 -39
- package/lib/material/option/option.component.d.ts +8 -1
- package/lib/material/radio-field/radio-field.component.d.ts +12 -3
- package/lib/material/select-field/select-field.component.d.ts +17 -3
- package/lib/material/selected-file/selected-file.component.d.ts +1 -1
- package/lib/material/slider-field/slider-field.component.d.ts +14 -3
- package/lib/material/textarea-field/textarea-field.component.d.ts +14 -3
- package/lib/material/unit-conversion-field/unit-conversion-field.component.d.ts +18 -5
- package/lib/models/crispr-field.config.d.ts +8 -1
- package/lib/models/datepicker-field.config.d.ts +3 -4
- package/lib/pipes/initial-control-value.pipe.d.ts +1 -1
- package/lib/sub-group/sub-group.component.d.ts +3 -3
- package/package.json +12 -14
- package/tft-crispr-forms-14.0.1-rc.0.tgz +0 -0
- package/tft-crispr-forms-13.0.23.tgz +0 -0
- package/tft-crispr-forms.d.ts +0 -5
|
@@ -8,7 +8,7 @@ export declare class SelectedFileComponent {
|
|
|
8
8
|
showProgress: boolean;
|
|
9
9
|
color: ThemePalette;
|
|
10
10
|
static ɵfac: i0.ɵɵFactoryDeclaration<SelectedFileComponent, never>;
|
|
11
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<SelectedFileComponent, "crispr-selected-file", never, { "fileName": "fileName"; "progress": "progress"; "showProgress": "showProgress"; "color": "color"; }, {}, never, never>;
|
|
11
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SelectedFileComponent, "crispr-selected-file", never, { "fileName": "fileName"; "progress": "progress"; "showProgress": "showProgress"; "color": "color"; }, {}, never, never, false>;
|
|
12
12
|
}
|
|
13
13
|
export declare class SelectedFileModule {
|
|
14
14
|
static ɵfac: i0.ɵɵFactoryDeclaration<SelectedFileModule, never>;
|
|
@@ -1,11 +1,17 @@
|
|
|
1
1
|
import { OnInit } from '@angular/core';
|
|
2
2
|
import { SliderFieldConfig } from '../../models';
|
|
3
3
|
import * as i0 from "@angular/core";
|
|
4
|
+
import * as i1 from "@angular/common";
|
|
5
|
+
import * as i2 from "../info/info.component";
|
|
6
|
+
import * as i3 from "../option/option.component";
|
|
7
|
+
import * as i4 from "../../field-container/field-container.component";
|
|
8
|
+
import * as i5 from "@angular/forms";
|
|
9
|
+
import * as i6 from "@angular/material/slider";
|
|
4
10
|
declare const SliderFieldMixin: {
|
|
5
11
|
new (): {
|
|
6
12
|
config: SliderFieldConfig;
|
|
7
|
-
group: import("@angular/forms").FormGroup
|
|
8
|
-
control: import("@angular/forms").AbstractControl
|
|
13
|
+
group: import("@angular/forms").FormGroup<any>;
|
|
14
|
+
control: import("@angular/forms").AbstractControl<any, any>;
|
|
9
15
|
_value: any;
|
|
10
16
|
value: any;
|
|
11
17
|
ngOnInit(): void;
|
|
@@ -22,6 +28,11 @@ export declare class SliderFieldComponent extends SliderFieldMixin implements On
|
|
|
22
28
|
get flexDirection(): "column" | "row";
|
|
23
29
|
ngOnInit(): void;
|
|
24
30
|
static ɵfac: i0.ɵɵFactoryDeclaration<SliderFieldComponent, never>;
|
|
25
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<SliderFieldComponent, "crispr-slider-field", never, {}, {}, never, never>;
|
|
31
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SliderFieldComponent, "crispr-slider-field", never, {}, {}, never, never, false>;
|
|
32
|
+
}
|
|
33
|
+
export declare class SliderFieldModule {
|
|
34
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SliderFieldModule, never>;
|
|
35
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<SliderFieldModule, [typeof SliderFieldComponent], [typeof i1.CommonModule, typeof i2.InfoModule, typeof i3.OptionModule, typeof i4.FieldContainerModule, typeof i5.ReactiveFormsModule, typeof i6.MatSliderModule], [typeof SliderFieldComponent]>;
|
|
36
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<SliderFieldModule>;
|
|
26
37
|
}
|
|
27
38
|
export {};
|
|
@@ -2,11 +2,17 @@ import { OnInit } from '@angular/core';
|
|
|
2
2
|
import { FormGroup } from '@angular/forms';
|
|
3
3
|
import { TextareaFieldConfig } from '../../models';
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
|
+
import * as i1 from "@angular/common";
|
|
6
|
+
import * as i2 from "../info/info.component";
|
|
7
|
+
import * as i3 from "@angular/forms";
|
|
8
|
+
import * as i4 from "../../field-container/field-container.component";
|
|
9
|
+
import * as i5 from "@angular/material/form-field";
|
|
10
|
+
import * as i6 from "@angular/material/input";
|
|
5
11
|
declare const TextareaFieldMixin: {
|
|
6
12
|
new (): {
|
|
7
13
|
config: TextareaFieldConfig;
|
|
8
|
-
group: FormGroup
|
|
9
|
-
control: import("@angular/forms").AbstractControl
|
|
14
|
+
group: FormGroup<any>;
|
|
15
|
+
control: import("@angular/forms").AbstractControl<any, any>;
|
|
10
16
|
_value: any;
|
|
11
17
|
value: any;
|
|
12
18
|
ngOnInit(): void;
|
|
@@ -19,6 +25,11 @@ export declare class TextareaFieldComponent extends TextareaFieldMixin implement
|
|
|
19
25
|
defaultConfig: Partial<TextareaFieldConfig>;
|
|
20
26
|
ngOnInit(): void;
|
|
21
27
|
static ɵfac: i0.ɵɵFactoryDeclaration<TextareaFieldComponent, never>;
|
|
22
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<TextareaFieldComponent, "crispr-textarea-field", never, {}, {}, never, never>;
|
|
28
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<TextareaFieldComponent, "crispr-textarea-field", never, {}, {}, never, never, false>;
|
|
29
|
+
}
|
|
30
|
+
export declare class TextareaFieldModule {
|
|
31
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<TextareaFieldModule, never>;
|
|
32
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<TextareaFieldModule, [typeof TextareaFieldComponent], [typeof i1.CommonModule, typeof i2.InfoModule, typeof i3.ReactiveFormsModule, typeof i4.FieldContainerModule, typeof i5.MatFormFieldModule, typeof i6.MatInputModule], [typeof TextareaFieldComponent]>;
|
|
33
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<TextareaFieldModule>;
|
|
23
34
|
}
|
|
24
35
|
export {};
|
|
@@ -4,11 +4,19 @@ import { Observable, Subscription } from 'rxjs';
|
|
|
4
4
|
import { SelectOption } from '../../models';
|
|
5
5
|
import { UnitConversionFieldConfig } from '../../models/unit-conversion-field.config';
|
|
6
6
|
import * as i0 from "@angular/core";
|
|
7
|
+
import * as i1 from "@angular/common";
|
|
8
|
+
import * as i2 from "../info/info.component";
|
|
9
|
+
import * as i3 from "../option/option.component";
|
|
10
|
+
import * as i4 from "@angular/forms";
|
|
11
|
+
import * as i5 from "../../field-container/field-container.component";
|
|
12
|
+
import * as i6 from "@angular/material/input";
|
|
13
|
+
import * as i7 from "@angular/material/select";
|
|
14
|
+
import * as i8 from "@angular/material/core";
|
|
7
15
|
declare const UnitConversionFieldMixin: {
|
|
8
16
|
new (): {
|
|
9
17
|
config: UnitConversionFieldConfig<unknown, unknown>;
|
|
10
|
-
group: import("@angular/forms").FormGroup
|
|
11
|
-
control: import("@angular/forms").AbstractControl
|
|
18
|
+
group: import("@angular/forms").FormGroup<any>;
|
|
19
|
+
control: import("@angular/forms").AbstractControl<any, any>;
|
|
12
20
|
_value: any;
|
|
13
21
|
value: any;
|
|
14
22
|
ngOnInit(): void;
|
|
@@ -19,8 +27,8 @@ declare const UnitConversionFieldMixin: {
|
|
|
19
27
|
};
|
|
20
28
|
export declare class UnitConversionFieldComponent extends UnitConversionFieldMixin implements OnInit, OnDestroy {
|
|
21
29
|
defaultConfig: Partial<UnitConversionFieldConfig<unknown, unknown>>;
|
|
22
|
-
displayValueControl: FormControl
|
|
23
|
-
unitSelectControl: FormControl
|
|
30
|
+
displayValueControl: FormControl<any>;
|
|
31
|
+
unitSelectControl: FormControl<any>;
|
|
24
32
|
unitOptions$: Observable<SelectOption[]>;
|
|
25
33
|
transformationSubscription: Subscription;
|
|
26
34
|
ngOnInit(): void;
|
|
@@ -34,6 +42,11 @@ export declare class UnitConversionFieldComponent extends UnitConversionFieldMix
|
|
|
34
42
|
*/
|
|
35
43
|
setControlValue(value: any): void;
|
|
36
44
|
static ɵfac: i0.ɵɵFactoryDeclaration<UnitConversionFieldComponent, never>;
|
|
37
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<UnitConversionFieldComponent, "crispr-unit-conversion-field", never, {}, {}, never, never>;
|
|
45
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<UnitConversionFieldComponent, "crispr-unit-conversion-field", never, {}, {}, never, never, false>;
|
|
46
|
+
}
|
|
47
|
+
export declare class UnitConversionFieldModule {
|
|
48
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<UnitConversionFieldModule, never>;
|
|
49
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<UnitConversionFieldModule, [typeof UnitConversionFieldComponent], [typeof i1.CommonModule, typeof i2.InfoModule, typeof i3.OptionModule, typeof i4.ReactiveFormsModule, typeof i5.FieldContainerModule, typeof i6.MatInputModule, typeof i7.MatSelectModule, typeof i8.MatOptionModule], [typeof UnitConversionFieldComponent]>;
|
|
50
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<UnitConversionFieldModule>;
|
|
38
51
|
}
|
|
39
52
|
export {};
|
|
@@ -48,7 +48,14 @@ export interface CrisprControlConfig<M = null> extends CrisprFieldConfig {
|
|
|
48
48
|
computeFieldConfig?: ComputeFieldConfig;
|
|
49
49
|
computeValue?: (group: FormGroup) => Observable<unknown>;
|
|
50
50
|
disabledCallback?: (group: FormGroup, config?: any) => Observable<boolean>;
|
|
51
|
+
/**
|
|
52
|
+
* @deprecated this configuration isn't needed as all situations can be handled using `disabledCallback`
|
|
53
|
+
*/
|
|
51
54
|
disabledCallbackConfig?: CheckControlConfig | CheckControlsConfig | any;
|
|
55
|
+
/**
|
|
56
|
+
* Hide the control when disabled
|
|
57
|
+
* @default false
|
|
58
|
+
*/
|
|
52
59
|
hideDisabled?: boolean;
|
|
53
60
|
heading?: HeadingConfig;
|
|
54
61
|
hint?: string;
|
|
@@ -85,7 +92,7 @@ export interface FormConfig<C = AnyFieldConfig> extends AbstractGroupConfig<C> {
|
|
|
85
92
|
/**
|
|
86
93
|
* Configuration for SubGroup components
|
|
87
94
|
*/
|
|
88
|
-
export interface SubGroupConfig extends CrisprControlConfig, AbstractGroupConfig {
|
|
95
|
+
export interface SubGroupConfig extends CrisprControlConfig, AbstractGroupConfig<any> {
|
|
89
96
|
controlType: ControlType.SUB_GROUP;
|
|
90
97
|
}
|
|
91
98
|
export declare type AnyFieldConfig = InputFieldConfig | SelectFieldConfig | RadioFieldConfig | FormGroupListConfig | SubGroupConfig | AutocompleteFieldConfig | AutocompleteChiplistFieldConfig | TextareaFieldConfig | CheckboxFieldConfig | DatepickerFieldConfig | SliderFieldConfig | FileUploadFieldConfig | ImageUploadFieldConfig | HeadingConfig | ButtonConfig | DividerConfig | UnitConversionFieldConfig;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { CrisprControlConfig, ControlType } from '../models';
|
|
2
|
-
import { Moment } from 'moment';
|
|
3
2
|
import { FieldDescriptors, MatFieldProperties } from './crispr-field.config';
|
|
4
3
|
import { MatCalendarCellClassFunction } from '@angular/material/datepicker';
|
|
5
4
|
import { Observable } from 'rxjs';
|
|
@@ -12,9 +11,9 @@ export interface DatepickerFieldConfig extends CrisprControlConfig, Pick<FieldDe
|
|
|
12
11
|
startView?: 'month' | 'year' | 'multi-year';
|
|
13
12
|
startAt?: Date | ((group: FormGroup) => Observable<Date>) | null;
|
|
14
13
|
touchUi?: boolean;
|
|
15
|
-
datepickerFilter?: (date:
|
|
16
|
-
cellClassFunction?: MatCalendarCellClassFunction<
|
|
17
|
-
dateClass?: (parentGroup: FormGroup) => Observable<MatCalendarCellClassFunction<
|
|
14
|
+
datepickerFilter?: (date: Date) => boolean;
|
|
15
|
+
cellClassFunction?: MatCalendarCellClassFunction<Date>;
|
|
16
|
+
dateClass?: (parentGroup: FormGroup) => Observable<MatCalendarCellClassFunction<Date>>;
|
|
18
17
|
/**
|
|
19
18
|
* Pass a component into mat-datepicker-actions component see [docs](https://material.angular.io/components/datepicker/overview#confirmation-action-buttons)
|
|
20
19
|
*/
|
|
@@ -6,5 +6,5 @@ export declare class InitialControlValuePipe implements PipeTransform {
|
|
|
6
6
|
[key: string]: ControlValue | any;
|
|
7
7
|
}, fieldConfig: AnyFieldConfig): unknown;
|
|
8
8
|
static ɵfac: i0.ɵɵFactoryDeclaration<InitialControlValuePipe, never>;
|
|
9
|
-
static ɵpipe: i0.ɵɵPipeDeclaration<InitialControlValuePipe, "initialControlValue">;
|
|
9
|
+
static ɵpipe: i0.ɵɵPipeDeclaration<InitialControlValuePipe, "initialControlValue", false>;
|
|
10
10
|
}
|
|
@@ -5,8 +5,8 @@ import * as i0 from "@angular/core";
|
|
|
5
5
|
declare const FormGroupMixin: {
|
|
6
6
|
new (): {
|
|
7
7
|
config: SubGroupConfig;
|
|
8
|
-
group: FormGroup
|
|
9
|
-
control: import("@angular/forms").AbstractControl
|
|
8
|
+
group: FormGroup<any>;
|
|
9
|
+
control: import("@angular/forms").AbstractControl<any, any>;
|
|
10
10
|
_value: any;
|
|
11
11
|
value: any;
|
|
12
12
|
ngOnInit(): void;
|
|
@@ -19,6 +19,6 @@ export declare class SubGroupComponent extends FormGroupMixin implements OnInit
|
|
|
19
19
|
group: FormGroup;
|
|
20
20
|
ngOnInit(): void;
|
|
21
21
|
static ɵfac: i0.ɵɵFactoryDeclaration<SubGroupComponent, never>;
|
|
22
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<SubGroupComponent, "crispr-sub-group", never, {}, {}, never, never>;
|
|
22
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SubGroupComponent, "crispr-sub-group", never, {}, {}, never, never, false>;
|
|
23
23
|
}
|
|
24
24
|
export {};
|
package/package.json
CHANGED
|
@@ -1,19 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tft/crispr-forms",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "14.0.1-rc.0",
|
|
4
4
|
"peerDependencies": {
|
|
5
|
-
"@angular/common": "^
|
|
6
|
-
"@angular/forms": "^
|
|
7
|
-
"@angular/core": "^
|
|
8
|
-
"@angular/material": "^
|
|
9
|
-
"@angular/cdk": "^
|
|
10
|
-
"@tft/form-validation-handler": "^
|
|
11
|
-
"@angular/material-
|
|
5
|
+
"@angular/common": "^14.0.0",
|
|
6
|
+
"@angular/forms": "^14.0.0",
|
|
7
|
+
"@angular/core": "^14.0.0",
|
|
8
|
+
"@angular/material": "^14.0.0",
|
|
9
|
+
"@angular/cdk": "^14.0.0",
|
|
10
|
+
"@tft/form-validation-handler": "^14.0.0",
|
|
11
|
+
"@angular/material-date-fns-adapter": "14.0.1",
|
|
12
12
|
"browser-image-compression": "^1.0.0",
|
|
13
|
-
"
|
|
14
|
-
"
|
|
15
|
-
"@angular/platform-browser-dynamic": "13.2.1",
|
|
16
|
-
"@angular/platform-browser": "13.2.1"
|
|
13
|
+
"date-fns": "^2.28.0",
|
|
14
|
+
"@angular/platform-browser": "14.0.1"
|
|
17
15
|
},
|
|
18
16
|
"dependencies": {
|
|
19
17
|
"tslib": "^2.0.0"
|
|
@@ -23,13 +21,13 @@
|
|
|
23
21
|
"esm2020": "esm2020/tft-crispr-forms.mjs",
|
|
24
22
|
"fesm2020": "fesm2020/tft-crispr-forms.mjs",
|
|
25
23
|
"fesm2015": "fesm2015/tft-crispr-forms.mjs",
|
|
26
|
-
"typings": "
|
|
24
|
+
"typings": "index.d.ts",
|
|
27
25
|
"exports": {
|
|
28
26
|
"./package.json": {
|
|
29
27
|
"default": "./package.json"
|
|
30
28
|
},
|
|
31
29
|
".": {
|
|
32
|
-
"types": "./
|
|
30
|
+
"types": "./index.d.ts",
|
|
33
31
|
"esm2020": "./esm2020/tft-crispr-forms.mjs",
|
|
34
32
|
"es2020": "./fesm2020/tft-crispr-forms.mjs",
|
|
35
33
|
"es2015": "./fesm2015/tft-crispr-forms.mjs",
|
|
Binary file
|
|
Binary file
|