@esfaenza/forms-and-validations 11.2.148 → 11.2.149-beta1
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 +99 -16
- 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 +78 -11
- package/esm2015/lib/forms/form-input/form-input.component.js +8 -2
- package/esm2015/lib/forms/form-select/form-select.component.js +2 -2
- package/esm2015/lib/validations/validation-select/validation-select.component.js +3 -3
- package/fesm2015/esfaenza-forms-and-validations.js +87 -14
- package/fesm2015/esfaenza-forms-and-validations.js.map +1 -1
- package/lib/forms/base-form-control.d.ts +46 -8
- package/lib/forms/form-input/form-input.component.d.ts +2 -0
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ControlValueAccessor, NgControl, NgForm, NgModel } from "@angular/forms";
|
|
2
|
-
import { EventEmitter, ChangeDetectorRef } from "@angular/core";
|
|
2
|
+
import { EventEmitter, ChangeDetectorRef, ElementRef } 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";
|
|
@@ -140,20 +140,24 @@ export declare abstract class BaseFormControl implements ControlValueAccessor {
|
|
|
140
140
|
* @param {string} input Input nel formato "X Y"
|
|
141
141
|
*/
|
|
142
142
|
set LabelInputRatio(input: string);
|
|
143
|
+
/**
|
|
144
|
+
* Elemento HTML rappresentante l'Input
|
|
145
|
+
*/
|
|
146
|
+
htmlInput: ElementRef;
|
|
143
147
|
/** val-qualcosa che fa effettivamente da input, o eventualmente il singolo input in casi particolari (es checkbox) */
|
|
144
148
|
protected validationControl: NgModel;
|
|
145
149
|
/**
|
|
146
|
-
* Query sull'elemento '
|
|
150
|
+
* Query sull'elemento 'baseInput' che funziona in ambiente statico
|
|
147
151
|
*
|
|
148
|
-
* @param {NgModel} comp Elemento HTML marcato con "#
|
|
152
|
+
* @param {NgModel} comp Elemento HTML marcato con "#baseInput"
|
|
149
153
|
*/
|
|
150
|
-
set
|
|
154
|
+
set baseInput(comp: NgModel);
|
|
151
155
|
/**
|
|
152
|
-
* Query sull'elemento '
|
|
156
|
+
* Query sull'elemento 'baseInput' che funziona in ambiente dinamico
|
|
153
157
|
*
|
|
154
|
-
* @param {NgModel} comp Elemento HTML marcato con "#
|
|
158
|
+
* @param {NgModel} comp Elemento HTML marcato con "#baseInput"
|
|
155
159
|
*/
|
|
156
|
-
set
|
|
160
|
+
set baseInput_static(comp: NgModel);
|
|
157
161
|
/** Evento chiamato alla modifica del valore collegato a questo campo */
|
|
158
162
|
inputChange: EventEmitter<ChangeEvent>;
|
|
159
163
|
/** Evento chiamato al focus del campo di testo/combo/quelcheè, riemitta l'evento originale Javascript */
|
|
@@ -216,7 +220,7 @@ export declare abstract class BaseFormControl implements ControlValueAccessor {
|
|
|
216
220
|
*
|
|
217
221
|
* @param {NgModel} comp Elemento HTML marcato con "#validationControl"
|
|
218
222
|
*/
|
|
219
|
-
|
|
223
|
+
registerBaseInput(comp: NgModel): void;
|
|
220
224
|
registerForm(ngForm: NgForm): void;
|
|
221
225
|
/**
|
|
222
226
|
* Aggiorna il valore e la validità dell'input sottostante. Non viene chiamato per input nativi come le checkbox
|
|
@@ -253,4 +257,38 @@ export declare abstract class BaseFormControl implements ControlValueAccessor {
|
|
|
253
257
|
log(message: string): void;
|
|
254
258
|
/** @ignore */
|
|
255
259
|
abstract onNotNullValueSet(): void;
|
|
260
|
+
/**
|
|
261
|
+
* Variabile per tenere in memoria lo stato di submit di questo componente
|
|
262
|
+
*/
|
|
263
|
+
protected _submitted: boolean;
|
|
264
|
+
/**
|
|
265
|
+
* Variabile per tenere in memoria il fatto che il componente è forzato a invalido o no
|
|
266
|
+
*/
|
|
267
|
+
protected _forceInvalid: boolean;
|
|
268
|
+
/**
|
|
269
|
+
* Imposta il componente come "submitted" scatenandone le validazioni ed eventualmente la visualizzazione del tooltip di errore
|
|
270
|
+
*
|
|
271
|
+
* @param {boolean} val **true** se si vuole impostare questo controllo come submitted, **false** altrimenti
|
|
272
|
+
*/
|
|
273
|
+
set submitted(val: boolean);
|
|
274
|
+
/**
|
|
275
|
+
* Imposta il componente come "invalid" a prescindere dai validatori
|
|
276
|
+
*/
|
|
277
|
+
set forceInvalid(val: boolean);
|
|
278
|
+
/**
|
|
279
|
+
* @ignore
|
|
280
|
+
*/
|
|
281
|
+
setDisabledState?(isDisabled: boolean): void;
|
|
282
|
+
/**
|
|
283
|
+
* Subscription alle richieste di focus
|
|
284
|
+
*/
|
|
285
|
+
observable: any;
|
|
286
|
+
/**
|
|
287
|
+
* Registra il Subject per ricevere le richieste di Focus dall'esterno
|
|
288
|
+
*/
|
|
289
|
+
registerFocusRequest(): any;
|
|
290
|
+
/**
|
|
291
|
+
* Deregistra il Subject delle richieste di focus
|
|
292
|
+
*/
|
|
293
|
+
deregisterFocusRequest(): void;
|
|
256
294
|
}
|