Skip to content

docs-bug(COMPONENT): Mat-Form-Field #33035

@DuncanFaulkner

Description

@DuncanFaulkner

Documentation Feedback

Just wondering if we can update the Mat-Form-Field documentation. The documentation states that the mat-form-field works with the following components.

[<input matNativeControl> & <textarea matNativeControl>](https://material.angular.dev/components/input/overview)
[<select matNativeControl>](https://material.angular.dev/components/select/overview)
[<mat-select>](https://material.angular.dev/components/select/overview)
[<mat-chip-set>](https://material.angular.dev/components/chips/overview)

The mat-chip-set does not work with the mat-form-field and triggers the "must contain a MatFormFieldControl", the only mat-chip-xxx that implements the MatFormFieldControl is the mat-chip-grid and appears to be the only one that works inside a mat-form-field.

[<input matNativeControl> & <textarea matNativeControl>](https://material.angular.dev/components/input/overview)
[<select matNativeControl>](https://material.angular.dev/components/select/overview)
[<mat-select>](https://material.angular.dev/components/select/overview)
[<mat-chip-grid>](https://material.angular.dev/components/chips/overview)

Example of working mat-chip-grid within mat-form-field

<mat-form-field>
  <mat-label>Label</mat-label>
  <mat-chip-grid #chipGrid>
    <mat-chip-row>Existing chips... </mat-chip-row>
  </mat-chip-grid>
  <input placeholder="Enter chip name..." [matChipInputFor]="chipGrid" />
</mat-form-field>

Affected documentation page

https://material.angular.dev/components/form-field/overview

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: material/form-fielddocsThis issue is related to documentationgemini-triagedLabel noting that an issue has been triaged by geminineeds triageThis issue needs to be triaged by the team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions