MCPcopy Create free account
hub / github.com/angular/components / _onEditFinish

Method _onEditFinish

src/material/chips/chip-row.ts:222–234  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

220 }
221
222 private _onEditFinish() {
223 this._isEditing = this._editStartPending = false;
224 this.edited.emit({chip: this, value: this._getEditInput().getValue()});
225
226 // If the edit input is still focused or focus was returned to the body after it was destroyed,
227 // return focus to the chip contents.
228 if (
229 this._document.activeElement === this._getEditInput().getNativeElement() ||
230 this._document.activeElement === this._document.body
231 ) {
232 this.primaryAction.focus();
233 }
234 }
235
236 override _isRippleDisabled(): boolean {
237 return super._isRippleDisabled() || this._isEditing;

Callers 2

constructorMethod · 0.95
_handleKeydownMethod · 0.95

Calls 4

_getEditInputMethod · 0.95
focusMethod · 0.65
getValueMethod · 0.45
getNativeElementMethod · 0.45

Tested by

no test coverage detected