angular / components

Component infrastructure and Material Design components for Angular
https://material.angular.io
MIT License
24.39k stars 6.76k forks source link

docs-bug(chips): Chips #29576

Open uptyler opened 3 months ago

uptyler commented 3 months ago

Documentation Feedback

There seems to be some discrepancy for m3 styling of mat-chips. While the affected documentation page shows that it is a component that is compatible with m3 styles, implementing this into a class: @include mat.chips-color($theme, $color-variant: $color); applying the class to a mat-chip does not affect the color variant.

I have labeled this as a docs bug because m3 styling options are not referenced at all in the mat-chips documentation here: https://material.angular.io/components/chips/overview and there are no examples of styling chips in the docs. If styling chips is an intended feature, this issue should be moved into m3 bug as the scss is not producing correct styling when including the mat.chips-color mixin.

EDIT: After a couple of hours of testing, I have identified that color variance only affects 'mat-chip-option' components when they are selected. This should be included in component overview documentation and potentially have an example with various styling as to show that color variance will not affect the standard mat-chip.

Affected documentation page

https://material.angular.io/guide/theming#using-component-color-variants

crisbeto commented 3 months ago

You can get the color to show up by setting the highlighted attribute on the chip.