(
opts: {onlySelf?: boolean; emitEvent?: boolean; sourceControl?: AbstractControl} = {},
)
| 1082 | sourceControl?: AbstractControl; |
| 1083 | }): void; |
| 1084 | markAsUntouched( |
| 1085 | opts: {onlySelf?: boolean; emitEvent?: boolean; sourceControl?: AbstractControl} = {}, |
| 1086 | ): void { |
| 1087 | const changed = this.touched === true; |
| 1088 | this.touched = false; |
| 1089 | this._pendingTouched = false; |
| 1090 | |
| 1091 | const sourceControl = opts.sourceControl ?? this; |
| 1092 | this._forEachChild((control: AbstractControl) => { |
| 1093 | control.markAsUntouched({onlySelf: true, emitEvent: opts.emitEvent, sourceControl}); |
| 1094 | }); |
| 1095 | |
| 1096 | if (!opts.onlySelf) { |
| 1097 | this._parent?._updateTouched(opts, sourceControl); |
| 1098 | } |
| 1099 | |
| 1100 | if (changed && opts.emitEvent !== false) { |
| 1101 | this._events.next(new TouchedChangeEvent(false, sourceControl)); |
| 1102 | } |
| 1103 | } |
| 1104 | |
| 1105 | /** |
| 1106 | * Marks the control as `dirty`. A control becomes dirty when |
nothing calls this directly
no test coverage detected
searching dependent graphs…