Skip to content

bug(mat-input): mat input type of search shows 2 clear buttons #31298

Open
@sh977218

Description

@sh977218

Is this a regression?

  • Yes, this behavior used to work in the previous version

The previous version in which this bug was not present was

No response

Description

it looks the mat-input with type of 'search' shows both HTML's input's search button and the mat-button for clear.

Reproduction

StackBlitz link: https://stackblitz.com/edit/geoplzxh?file=src%2Fexample%2Finput-clearable-example.html
Steps to reproduce:
1.
2.

Expected Behavior

Can we hide the HTML input's clear button or cover it up with the mat-button clear button.

Actual Behavior

mat-input with type of 'search' shows two clear buttons

Environment

  • Angular: 20.0.2 or any previous
  • CDK/Material: 20.0.2 or any previous
  • Browser(s): Chrome
  • Operating System (e.g. Windows, macOS, Ubuntu): Mac/Windows

Metadata

Metadata

Assignees

Labels

P3An issue that is relevant to core functions, but does not impede progress. Important, but not urgentarea: material/input

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions