Skip to content

Chips: allow [value]="null" #16844

Closed
@keatkeat87

Description

@keatkeat87

i think maybe there are some confused when people using ngModel on radio, chips, button toggle.

the ngModel behavior:

radio:
without set attr value, ngModel return null.
[value]="null", ngModel return null.

button toggle:
without set attr value, ngModel return undefined.
[value]="null", ngModel return null.

chips:
without set attr value, ngModel return content string.
[value]="null", ngModel return content string.

currently these is no way to make chips ngModel return null
because of this
image

I m not sure is it by design or ... ?
but i think angular material should provide a way let people decide ngModel value.

Metadata

Metadata

Assignees

Labels

P3An issue that is relevant to core functions, but does not impede progress. Important, but not urgentfeatureThis issue represents a new feature or feature request rather than a bug or bug fix

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions