Skip to content

bug(mat-stepper): Undocumented breaking change in Angular 20 #31532

@Sergiobop

Description

@Sergiobop

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

19

Description

Previously to Angular 20 we could customize the stepper header to hide icons with this workaround:

@ViewChild(MatHorizontalStepper) stepper: MatHorizontalStepper;

ngAfterViewInit() {
  this.stepper._getIndicatorType = () => 'number';
}

Now, in Angular 20, we can't, since the method was removed in c8f942d

How can we customize the indicator type now? It should be an input. Thanks!

Related:
#10513
#18307

Reproduction

StackBlitz link:
Steps to reproduce:

  1. Try to customize the stepper like we did before
    2: ✘ [ERROR] TS2339: Property '_getIndicatorType' does not exist on type 'MatStepper'. [plugin angular-compiler]

Expected Behavior

Input to customize the indicatorType

Actual Behavior

IndicatorType is not customizable anymore

Environment

  • Angular: 20.1
  • CDK/Material: 20.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    needs 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