Skip to content

Tab group does not change "selectedIndex" when programmatically changed #12233

@neelchanda

Description

@neelchanda

Bug, feature request, or proposal:

mat-tab-group is unable to update according to selectedIndex variable after view

What is the expected behavior?

mat-tab-group should update and show correct tab index based on the variable set

What is the current behavior?

mat-tab-group stays on the originally selected tab regardless of how many times the variable is changed.

What are the steps to reproduce?

See Angular Material Tab example documentation (https://material.angular.io/components/tabs/examples)

When selecting the checkbox to "Select tab after adding", after clicking "Add new tab", the tab stays on the original tab.

What is the use-case or motivation for changing an existing behavior?

Would like to programmatically change selected index for an angular material automated text carousel/slideshow type behavior.

Which versions of Angular, Material, OS, TypeScript, browsers are affected?

Angular 6

Is there anything else we should know?

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions