Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MatTabGroup pagination chevron incorrect color when using backgroundColor property #22587

Closed
MarkoSkugor opened this issue Apr 28, 2021 · 2 comments · Fixed by #22612
Closed
Assignees
Labels
area: material/tabs good first issue This issue is a good place to start for first time contributors to the project help wanted The team would appreciate a PR from the community to address this issue P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent

Comments

@MarkoSkugor
Copy link

What is the expected behavior?
mat-tab-group pagination chevron should be correct contrast color

What is the current behavior?
https://stackblitz.com/angular/manempdpqjo?file=src%2Fapp%2Ftab-group-theme-example.ts

CSS selector for mat-tab-header-pagination-chevron is broken for mat-tab-group and only works for mat-tab-nav-bar

Screenshot from Angular Material docs example:
image

This selector specifically is broken as .mat-tab-header-pagination is not a direct child of .mat-tab-group
image

What are the steps to reproduce?
go to this stackblitz and shrink screen on blue background mat-tab-group until the pagination chevrons appear
https://stackblitz.com/angular/manempdpqjo?file=src%2Fapp%2Ftab-group-theme-example.ts

Which versions of Angular, Material, OS, TypeScript, browsers are affected?
11 (confirmed this was working in 10), all browsers and OS affected

@jelbourn jelbourn added needs triage This issue needs to be triaged by the team area: material/tabs good first issue This issue is a good place to start for first time contributors to the project help wanted The team would appreciate a PR from the community to address this issue P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent and removed needs triage This issue needs to be triaged by the team labels Apr 29, 2021
@jelbourn
Copy link
Member

The issue here is with this CSS selector applies the desired border color when changing the background color:

.mat-tab-group.mat-background-primary > .mat-tab-header-pagination .mat-tab-header-pagination-chevron

The problem is that .mat-tab-header-pagination is not a direct child of .mat-tab-group, mat-tab-header is in between.

@crisbeto crisbeto self-assigned this May 2, 2021
@crisbeto crisbeto added the has pr label May 2, 2021
crisbeto added a commit to crisbeto/material2 that referenced this issue May 2, 2021
Resolves several issues related to the color of icons and ripples in the tab header, when it has a non-default `backgroundColor`.

Fixes angular#22587.
crisbeto added a commit to crisbeto/material2 that referenced this issue May 2, 2021
Resolves several issues related to the color of icons and ripples in the tab header, when it has a non-default `backgroundColor`.

Fixes angular#22587.
mmalerba pushed a commit that referenced this issue May 7, 2021
…2612)

Resolves several issues related to the color of icons and ripples in the tab header, when it has a non-default `backgroundColor`.

Fixes #22587.
mmalerba pushed a commit that referenced this issue May 7, 2021
…2612)

Resolves several issues related to the color of icons and ripples in the tab header, when it has a non-default `backgroundColor`.

Fixes #22587.

(cherry picked from commit 49e60ac)
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Jun 7, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area: material/tabs good first issue This issue is a good place to start for first time contributors to the project help wanted The team would appreciate a PR from the community to address this issue P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants