@esfaenza/forms-and-validations 11.2.125 → 11.2.126
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/bundles/esfaenza-forms-and-validations.umd.js +42 -26
- package/bundles/esfaenza-forms-and-validations.umd.js.map +1 -1
- package/esfaenza-forms-and-validations.metadata.json +1 -1
- package/esm2015/lib/forms/base-form-control.js +4 -3
- package/esm2015/lib/forms/form-adaptive/form-adaptive.component.js +4 -4
- package/esm2015/lib/forms/form-autocomplete/form-autocomplete.component.js +3 -2
- package/esm2015/lib/forms/form-date/form-date.component.js +4 -4
- package/esm2015/lib/forms/form-datetime/form-datetime.component.js +4 -4
- package/esm2015/lib/models/ChangeEvent.js +7 -0
- package/esm2015/lib/validations/base-validation.js +1 -1
- package/esm2015/lib/validations/validation-autocomplete/validation-autocomplete.component.js +4 -3
- package/esm2015/lib/validations/validation-autocomplete-multi/validation-autocomplete-multi.component.js +4 -3
- package/esm2015/lib/validations/validation-date/validation-date.component.js +5 -4
- package/esm2015/lib/validations/validation-datetime/validation-datetime.component.js +5 -4
- package/esm2015/lib/validations/validation-input/validation-input.component.js +4 -3
- package/esm2015/lib/validations/validation-select/validation-select.component.js +4 -3
- package/fesm2015/esfaenza-forms-and-validations.js +34 -26
- package/fesm2015/esfaenza-forms-and-validations.js.map +1 -1
- package/lib/forms/base-form-control.d.ts +3 -2
- package/lib/forms/form-adaptive/form-adaptive.component.d.ts +2 -1
- package/lib/forms/form-autocomplete/form-autocomplete.component.d.ts +2 -1
- package/lib/forms/form-date/form-date.component.d.ts +2 -1
- package/lib/forms/form-datetime/form-datetime.component.d.ts +2 -1
- package/lib/models/ChangeEvent.d.ts +5 -0
- package/lib/validations/base-validation.d.ts +2 -1
- package/lib/validations/validation-autocomplete/validation-autocomplete.component.d.ts +1 -1
- package/lib/validations/validation-autocomplete-multi/validation-autocomplete-multi.component.d.ts +1 -1
- package/lib/validations/validation-date/validation-date.component.d.ts +1 -1
- package/lib/validations/validation-datetime/validation-datetime.component.d.ts +1 -1
- package/lib/validations/validation-input/validation-input.component.d.ts +1 -1
- package/lib/validations/validation-select/validation-select.component.d.ts +1 -1
- package/package.json +1 -1
|
@@ -3,6 +3,7 @@ import { EventEmitter, ChangeDetectorRef } from "@angular/core";
|
|
|
3
3
|
import { AccessControlService, ComponentContext } from "@esfaenza/access-control";
|
|
4
4
|
import { Subject } from "rxjs";
|
|
5
5
|
import { TemplateRef } from "@angular/core";
|
|
6
|
+
import { ChangeEvent } from "../models/ChangeEvent";
|
|
6
7
|
/** Componente base da cui tutti i componenti Form implementano */
|
|
7
8
|
export declare abstract class BaseFormControl implements ControlValueAccessor {
|
|
8
9
|
protected cdr: ChangeDetectorRef;
|
|
@@ -148,7 +149,7 @@ export declare abstract class BaseFormControl implements ControlValueAccessor {
|
|
|
148
149
|
*/
|
|
149
150
|
set validationControl_static(comp: NgModel);
|
|
150
151
|
/** Evento chiamato alla modifica del valore collegato a questo campo */
|
|
151
|
-
inputChange: EventEmitter<
|
|
152
|
+
inputChange: EventEmitter<ChangeEvent>;
|
|
152
153
|
/** Evento chiamato al focus del campo di testo/combo/quelcheè, riemitta l'evento originale Javascript */
|
|
153
154
|
inputFocus: EventEmitter<any>;
|
|
154
155
|
/** Evento chiamato al finalize del campo di testo/combo/quelcheè */
|
|
@@ -222,7 +223,7 @@ export declare abstract class BaseFormControl implements ControlValueAccessor {
|
|
|
222
223
|
*
|
|
223
224
|
* Non posso tenerlo protected altrimenti posso eseguirlo solo dal .ts e non dall' .html
|
|
224
225
|
*/
|
|
225
|
-
changed(forcedValue?: any, markForCheck?: boolean, modelEvaluationHandled?: boolean): void;
|
|
226
|
+
changed(forcedValue?: any, markForCheck?: boolean, modelEvaluationHandled?: boolean, internal?: boolean): void;
|
|
226
227
|
/**
|
|
227
228
|
* @ignore
|
|
228
229
|
* Classico "spara fuori" sul focus. Mantengo lo stesso nome dell'evento dei <val-*> (inputChange) per retrocompatibilità.
|
|
@@ -7,6 +7,7 @@ import { NgxMatDateAdapter } from "@angular-material-components/datetime-picker"
|
|
|
7
7
|
import { BaseFormControl } from "../base-form-control";
|
|
8
8
|
import { AppFile } from "../../models/AppFile";
|
|
9
9
|
import { Observable } from "rxjs";
|
|
10
|
+
import { ChangeEvent } from "../../models/ChangeEvent";
|
|
10
11
|
/** Componente in grado di assumere la forma di un qualsiasi altro componente form in base al tipo specificato. Utile per la creazione di form dinamici */
|
|
11
12
|
export declare class FormAdaptiveComponent extends BaseFormControl implements ControlValueAccessor {
|
|
12
13
|
private utiExts;
|
|
@@ -75,7 +76,7 @@ export declare class FormAdaptiveComponent extends BaseFormControl implements Co
|
|
|
75
76
|
/** @ignore */
|
|
76
77
|
private removeFilteredSourceOnDescriptionSelection;
|
|
77
78
|
/** Metodo richiamato quando viene modificato il modello del campo di input */
|
|
78
|
-
changed(): void;
|
|
79
|
+
changed(event?: ChangeEvent): void;
|
|
79
80
|
/** @ignore */
|
|
80
81
|
finalized(): void;
|
|
81
82
|
/** Metodo richiamato quando viene selezionato il campo col mouse */
|
|
@@ -4,6 +4,7 @@ import { BaseFormControl } from "../base-form-control";
|
|
|
4
4
|
import { AccessControlService, ComponentContext } from '@esfaenza/access-control';
|
|
5
5
|
import { LocalizationService } from "@esfaenza/localizations";
|
|
6
6
|
import { Observable } from "rxjs";
|
|
7
|
+
import { ChangeEvent } from "../../models/ChangeEvent";
|
|
7
8
|
/** Componente di input che si auto-completa in base al valore attuale */
|
|
8
9
|
export declare class FormAutocompleteComponent extends BaseFormControl implements ControlValueAccessor {
|
|
9
10
|
lc: LocalizationService;
|
|
@@ -56,7 +57,7 @@ export declare class FormAutocompleteComponent extends BaseFormControl implement
|
|
|
56
57
|
*
|
|
57
58
|
* @param {string} event Input utente
|
|
58
59
|
*/
|
|
59
|
-
filterSource(event:
|
|
60
|
+
filterSource($event: ChangeEvent): void;
|
|
60
61
|
/** @ignore */
|
|
61
62
|
private removeFilteredSourceOnDescriptionSelection;
|
|
62
63
|
/** @ignore */
|
|
@@ -3,6 +3,7 @@ import { AccessControlService, ComponentContext } from '@esfaenza/access-control
|
|
|
3
3
|
import { DateService } from "@esfaenza/extensions";
|
|
4
4
|
import { BaseFormControl } from "../base-form-control";
|
|
5
5
|
import { ChangeDetectorRef } from "@angular/core";
|
|
6
|
+
import { ChangeEvent } from "../../models/ChangeEvent";
|
|
6
7
|
/** Componente che dà all'utente la possibilità di selezionare una data */
|
|
7
8
|
export declare class FormDateComponent extends BaseFormControl implements ControlValueAccessor {
|
|
8
9
|
private datesExts;
|
|
@@ -12,7 +13,7 @@ export declare class FormDateComponent extends BaseFormControl implements Contro
|
|
|
12
13
|
constructor(datesExts: DateService, cdr: ChangeDetectorRef, ngControl: NgControl, _validators: Array<any>, ac: AccessControlService, AppContext: ComponentContext, ACO_CUSTOMKEY: string, FAV_DEBUG_MODE: boolean);
|
|
13
14
|
/** @ignore */
|
|
14
15
|
writeValue(obj: any): void;
|
|
15
|
-
changed(): void;
|
|
16
|
+
changed(event: ChangeEvent): void;
|
|
16
17
|
/** @ignore */
|
|
17
18
|
onNotNullValueSet(): void;
|
|
18
19
|
}
|
|
@@ -3,6 +3,7 @@ import { AccessControlService, ComponentContext } from '@esfaenza/access-control
|
|
|
3
3
|
import { DateService } from "@esfaenza/extensions";
|
|
4
4
|
import { BaseFormControl } from "../base-form-control";
|
|
5
5
|
import { ChangeDetectorRef } from "@angular/core";
|
|
6
|
+
import { ChangeEvent } from "../../models/ChangeEvent";
|
|
6
7
|
/**
|
|
7
8
|
* Componente che dà all'utente la possibilità di selezionare una data insieme ad un orario
|
|
8
9
|
*/
|
|
@@ -14,7 +15,7 @@ export declare class FormDateTimeComponent extends BaseFormControl implements Co
|
|
|
14
15
|
constructor(datesExts: DateService, cdr: ChangeDetectorRef, ngControl: NgControl, _validators: Array<any>, ac: AccessControlService, AppContext: ComponentContext, ACO_CUSTOMKEY: string, FAV_DEBUG_MODE: boolean);
|
|
15
16
|
/** @ignore */
|
|
16
17
|
writeValue(obj: any): void;
|
|
17
|
-
changed(): void;
|
|
18
|
+
changed(event: ChangeEvent): void;
|
|
18
19
|
/** @ignore */
|
|
19
20
|
onNotNullValueSet(): void;
|
|
20
21
|
}
|
|
@@ -3,6 +3,7 @@ import { NgModel } from "@angular/forms";
|
|
|
3
3
|
import { LocalizationService } from "@esfaenza/localizations";
|
|
4
4
|
import { TooltipDirective } from "ngx-bootstrap/tooltip";
|
|
5
5
|
import { Subject } from "rxjs";
|
|
6
|
+
import { ChangeEvent } from "../models/ChangeEvent";
|
|
6
7
|
/**
|
|
7
8
|
* Classe astratta base che contiene le logiche / proprietà in comune a tutti i validatori
|
|
8
9
|
*
|
|
@@ -119,7 +120,7 @@ export declare abstract class BaseValidation {
|
|
|
119
120
|
/**
|
|
120
121
|
* Evento che sostituisce l'ngModelChange facendolo funzionare in maniera un po' più consistente
|
|
121
122
|
*/
|
|
122
|
-
inputChange: EventEmitter<
|
|
123
|
+
inputChange: EventEmitter<ChangeEvent>;
|
|
123
124
|
/**
|
|
124
125
|
* Evento che indica il focus avvenuto su un controllo
|
|
125
126
|
*/
|
|
@@ -47,7 +47,7 @@ export declare class ValidationAutocompleteComponent extends BaseValidation impl
|
|
|
47
47
|
*
|
|
48
48
|
* @param {any} toEmit valore da propagare all'esterno
|
|
49
49
|
*/
|
|
50
|
-
onModelChange(toEmit: any): void;
|
|
50
|
+
onModelChange(toEmit: any, internal?: boolean): void;
|
|
51
51
|
/** @ignore */
|
|
52
52
|
registerOnChange(fn: any): void;
|
|
53
53
|
/** @ignore */
|
package/lib/validations/validation-autocomplete-multi/validation-autocomplete-multi.component.d.ts
CHANGED
|
@@ -62,7 +62,7 @@ export declare class ValidationAutocompleteMultiComponent extends BaseValidation
|
|
|
62
62
|
*
|
|
63
63
|
* @param {any} toEmit valore da propagare all'esterno
|
|
64
64
|
*/
|
|
65
|
-
onModelChange(toEmit: any, finalValue?: boolean): void;
|
|
65
|
+
onModelChange(toEmit: any, finalValue?: boolean, internal?: boolean): void;
|
|
66
66
|
/** @ignore */
|
|
67
67
|
registerOnChange(fn: any): void;
|
|
68
68
|
/** @ignore */
|
|
@@ -65,7 +65,7 @@ export declare class ValidationDateComponent extends BaseValidation implements C
|
|
|
65
65
|
*
|
|
66
66
|
* @param {any} toEmit valore da propagare all'esterno
|
|
67
67
|
*/
|
|
68
|
-
outputValue(toEmit: any): void;
|
|
68
|
+
outputValue(toEmit: any, internal?: boolean): void;
|
|
69
69
|
/**
|
|
70
70
|
* @ignore
|
|
71
71
|
*/
|
|
@@ -95,7 +95,7 @@ export declare class ValidationDateTimeComponent extends BaseValidation implemen
|
|
|
95
95
|
*
|
|
96
96
|
* @param {any} toEmit valore da propagare all'esterno
|
|
97
97
|
*/
|
|
98
|
-
outputValue(toEmit: any): void;
|
|
98
|
+
outputValue(toEmit: any, internal?: boolean): void;
|
|
99
99
|
/**
|
|
100
100
|
* @ignore
|
|
101
101
|
*/
|
|
@@ -112,7 +112,7 @@ export declare class ValidationInputComponent extends BaseValidation implements
|
|
|
112
112
|
*
|
|
113
113
|
* @param {any} toEmit valore da propagare all'esterno
|
|
114
114
|
*/
|
|
115
|
-
onModelChange(toEmit: any): void;
|
|
115
|
+
onModelChange(toEmit: any, internal?: boolean): void;
|
|
116
116
|
/**
|
|
117
117
|
* @ignore
|
|
118
118
|
*/
|
|
@@ -81,7 +81,7 @@ export declare class ValidationSelectComponent extends BaseValidation implements
|
|
|
81
81
|
*
|
|
82
82
|
* @param {any} toEmit valore da propagare all'esterno
|
|
83
83
|
*/
|
|
84
|
-
onModelChange(toEmit: any): void;
|
|
84
|
+
onModelChange(toEmit: any, internal?: boolean): void;
|
|
85
85
|
/**
|
|
86
86
|
* @ignore
|
|
87
87
|
*/
|