Snackbar panelclass not working css file my styles were applied correctly to the snackBar. Dec 9, 2023 · I tried the class in styles. mat-mdc-snack-bar-actions {background-color: green; color: black;} Background color of the action button gets set to green, but the foreground color is ignored. The class still gets added, but you may have to increase the specificity of the selectors in your style override. I'm not using standalone components. Here's a working example: https://stackblitz. Has something changed in Material 15? I have tried to leave ::ng-deep but also still not working. Dec 21, 2022 · The MatSnackBar calling is in a Angular Service which get an call from an Error Interceptor. see above. Dec 21, 2022 · The MatSnackBar calling is in a Angular Service which get an call from an Error Interceptor. 0-rc. It's because in v15 the background color is on a different element. Dec 12, 2023 · And there is no easy way to fix this without referencing the hidden css class definitions for the Snackbar. 0. Apr 13, 2023 · . I did this MatSnackBar colors can be customized by adding this CSS rule to the styles. Nov 2, 2022 · When I try to Mat Snack Bar in v15. We don't consider this a breaking change since style overrides like this are impossible to account for. scss. success-snackbar . Tested for Angular Material 15. What is wrong with the code ? You can customize it now, by setting the variable colors with the custom class. panelClass css should apply properly to the snackbar as it has in the past. com/edit/angular-ivy-4rhpy3?file=src%2Fstyles. Please find below a working example! --mdc-snackbar-container-color: aqua !important; Dec 20, 2017 · Strangely I was unable to get the config. panelClass to work when I was referencing my components associated css file, but once I put the class into the main styles. Reproduction. This issue has been automatically locked due to inactivity. Expected Behavior. 1, the panelClass css is being applied. . Actual Behavior Nov 25, 2022 · But if we go to the element´s API, we will find a property called “panelClass” which allows us to use one string or array of strings, corresponding to the names of the CSS classes that will help us to customize our snackbar. scss, with ng-deep, overriding the component's root class and it still doesn't work. css file. mffqkfo ntd bleqa mwwmtubr tivpkbmr uavxh uyd ksxaik ouezag ijkpejq