Does some manual dirty checking on the native input `placeholder` attribute.
()
| 467 | |
| 468 | /** Does some manual dirty checking on the native input `placeholder` attribute. */ |
| 469 | private _dirtyCheckPlaceholder() { |
| 470 | const placeholder = this._getPlaceholder(); |
| 471 | if (placeholder !== this._previousPlaceholder) { |
| 472 | const element = this._elementRef.nativeElement; |
| 473 | this._previousPlaceholder = placeholder; |
| 474 | placeholder |
| 475 | ? element.setAttribute('placeholder', placeholder) |
| 476 | : element.removeAttribute('placeholder'); |
| 477 | } |
| 478 | } |
| 479 | |
| 480 | /** Gets the current placeholder of the form field. */ |
| 481 | protected _getPlaceholder(): string | null { |
no test coverage detected