i want to set the table header background to blue color.
this is my html:
<ngx-datatable class="material" [rows]="rows" [columnMode]="'force'" [headerHeight]="50" [footerHeight]="50"
[rowHeight]="'auto'" ngClass="{'table-striped': false}">
<ngx-datatable-column name="ID RECLAMO" prop="idReclamo" class="bg-dark"></ngx-datatable-column>
<ngx-datatable-column name="SEGNALTO" prop="dataSegnalizione">
<ng-template let-row="row" ngx-datatable-cell-template>
{{ row.dataSegnalizione | date:'dd/MM/yyyy' }}
</ng-template>
</ngx-datatable-column>
<ngx-datatable-column name="PRESO IN CARICO IL" prop="dataPresoInCarico">
<ng-template let-row="row" ngx-datatable-cell-template>
{{ row.dataChiusura | date:'dd/MM/yyyy' }}
</ng-template>
</ngx-datatable-column>
<ngx-datatable-column name="CHIUSO IL" prop="dataChiusura">
<ng-template let-row="row" ngx-datatable-cell-template>
{{ row.dataPresoInCarico | date:'dd/MM/yyyy' }}
</ng-template>
</ngx-datatable-column>
<ngx-datatable-column name="NEGOZIO" prop="codiceNegozio"></ngx-datatable-column>
<ngx-datatable-column name="MANAGER" prop="manager"></ngx-datatable-column>
<ngx-datatable-column name="CLIENTE" prop="cliente"></ngx-datatable-column>
<ngx-datatable-column name="STATO" prop="stato"></ngx-datatable-column>
<ngx-datatable-column name="GESTIONE" prop="gestione"></ngx-datatable-column>
<ngx-datatable-column name="CAUSALE RECLAMO" prop="causaleReclamo"></ngx-datatable-column>
<ngx-datatable-column name="SODDISFAZIONE" prop="soddisfazione"></ngx-datatable-column> </ngx-datatable>
i tried forcing it using "deep" "host" but without a result.
2
Answers
Try the below CSS
Stackblitz Demo
If you use
css
, you need to add following styles in yourcss
file.And if you use
scss
, you need to add following styles in yourscss
file.Please check this stackblitz.
Best Regards.