[App.component.ts]
@Component({
selector: 'app-root',
templateUrl: 'app.component.html',
providers: [DetailRowService],
styles: [`.e-detailcell .e-grid .e-headercontent .e-headercell,.e-detailcell .e-grid .e-detailheadercell {
background-color: lightblue;
}
.e-grid .e-headercell,.e-grid .e-detailheadercell {
background-color: blue;
}`],
encapsulation: ViewEncapsulation.None
})
export class AppComponent {
public parentData: Object[];
public childGrid: GridModel;
ngOnInit(): void {
. ..
}
|
[App.component.ts]
@Component({
selector: 'app-root',
templateUrl: 'app.component.html',
providers: [DetailRowService],
styles: [`.e-detailcell .e-grid .e-headercontent .e-headercell,.e-detailcell .e-grid .e-detailheadercell {
background-color: lightblue;
}
.e-grid .e-headercell,.e-grid .e-detailheadercell {
background-color: blue;
}
.e-detailcell .e-detailrow .e-rowcell {
background-color: yellow; // here you can apply css for the grand child row’s
}
`],
encapsulation: ViewEncapsulation.None
}) |
if you are using a Hierarchical grid and you want to make the grid headers of each nested table a different colors, then use this: