I have this select in angular material:
Its code :
The top solutions of /deep/, >>> and ::ng-deep are being deprecated and should no longer be used.
The recommended method is now view encapsulation
Our solution to ViewEncapsulation was to override very specific css using highly specific css selectors in 1) global css or 2) creating separate style files for certain views / styles / elements, importing into every component required (e.g. styleUrls: [material-table-override.css, component.css]).
I used ViewEncapsulation.None to successfully override material table styles within a single component in Angular 6.
On your component:
import { ViewEncapsulation } from '@angular/core';
// ...
@Component({
// ...
encapsulation: ViewEncapsulation.None,
})
Here's a great article on the subject