Skip to content

feat(mat-tab-group): add stretchTabs to MatTabsConfig #26645

@joelkesler

Description

@joelkesler

Feature Description

The new Material component updates changed how tabs present when used. Tabs now stretch to fill the header.

For those of us who wish to preserve the old behaviour, adding the stretchTabs settings to MatTabsConfig will be incredibly helpful to let us set the behaviour universally instead of updating each and every instance.

Please see PR #26644

Use Case

This will allow developers to globally set stretchTabs to false for all instances of mat-tab-group in an application via providers.

Ex:

providers: [
  {
    provide: MAT_TABS_CONFIG,
    useValue: {
      stretchTabs: false,
    },
  },
]

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3An issue that is relevant to core functions, but does not impede progress. Important, but not urgentarea: material/tabsfeatureThis 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