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

Method toggleSelected

src/material/chips/chip-option.ts:167–170  ·  view source on GitHub ↗

Toggles the current selected state of this chip.

(isUserInput: boolean = false)

Source from the content-addressed store, hash-verified

165
166 /** Toggles the current selected state of this chip. */
167 toggleSelected(isUserInput: boolean = false): boolean {
168 this._setSelectedState(!this.selected, isUserInput, true);
169 return this.selected;
170 }
171
172 override _handlePrimaryActionInteraction() {
173 if (!this.disabled) {

Callers 1

Calls 1

_setSelectedStateMethod · 0.95

Tested by

no test coverage detected