Issue
The following image shows the default list page of the incident table in Service Portal.
The title columns displayed have an assigned CSS class called th-title that is rendered through the Data Table widget.
The Data Table widget is not included in any page, but the Data Table from URL Definition widget on the list page calls the Data Table widget. This means that the CSS styles of the Data Table widget are applied on the list page.
You can see the Data Table widget by going to Service Portal > Widgets. Note that under the CSS field, a styling block is already defined for the class th-title.
Release
Any supported release
Resolution
Use any of the following three methods to change the color of the column titles:
1. Override the CSS in the Data Table widget by adding the CSS to the Data Table from the URL Definition widget. For example:
.th-title {
color: white !important;
}
Note: Defining the CSS in the Data Table from URL Definition widget affects every page where this widget is used or called in.
2. Replace the color defined in CSS field in the Data Table widget. For example:
.th-title {
color: white;
}
Note: Defining the CSS in the Data Table widget affects every page where this widget is used or called in.
3. Define the CSS at the list page level and override the style done by the widget. For example:
.th-title {
color: white !important;
}
Note: Adding the "!important" definition overrides the color attribute for the class if defined somewhere else. Defining the color in the CSS at the page level is page specific.
Related Links
For more information, see Service Portal styles.