Fixed issue when control value is null inside textarea component
This commit is contained in:
@@ -50,12 +50,12 @@ export class TextareaComponent implements AfterViewInit, ControlValueAccessor, O
|
|||||||
|
|
||||||
onTouched: () => {};
|
onTouched: () => {};
|
||||||
private onChange: (value: any) => {};
|
private onChange: (value: any) => {};
|
||||||
private _value: string = '';
|
private _value: string;
|
||||||
|
|
||||||
constructor(private injector: Injector, private changeDetectorRef: ChangeDetectorRef) {}
|
constructor(private injector: Injector, private changeDetectorRef: ChangeDetectorRef) {}
|
||||||
|
|
||||||
get currentValue(): string {
|
get currentValue(): string {
|
||||||
return this._value;
|
return this._value || '';
|
||||||
}
|
}
|
||||||
|
|
||||||
get charactersLeft(): number {
|
get charactersLeft(): number {
|
||||||
|
|||||||
Reference in New Issue
Block a user