Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

Hi Team custom widget to add bold text and change the color

AnilM99
Tera Expert

Hi team,

 

I have a requirement. I am using the below HTML and server script to show the title of the custom widget.

HTML:

<div>
<span class="panel-title"><i ng-if="options.glyph" class="fa fa-{{options.glyph}} m-r"></i>{{data.title || data.table_plural}}</span>
<div class="alert alert-danger" ng-if="data.invalid_table">
${Table not defined} '{{data.table_label}}'
</div>
<sp-widget ng-if="data.dataTableWidget" widget="data.dataTableWidget"></sp-widget>
</div>

 

Server Script:

title: options.title,
 
It's showing like below:
AnilM99_0-1742543155252.png

 

Now i want to change the color of the title and set bold

 

Thanks,

Anil!

2 REPLIES 2

Sanjay191
Tera Sage
Tera Sage

Hello @AnilM99 

Please make change in class and add the CSS  like below 

<div>
<span class="panel-title">
<i ng-if="options.glyph" class="fa fa-{{options.glyph}} m-r"></i>
{{data.title || data.table_plural}}
</span>
<div class="alert alert-danger" ng-if="data.invalid_table">
${Table not defined} '{{data.table_label}}'
</div>
<sp-widget ng-if="data.dataTableWidget" widget="data.dataTableWidget"></sp-widget>
</div>

and CSS is like below for the title colored and bold

.panel-title {
color: red;
font-weight: bold;
}

Sanjay191_0-1742545259815.pngSanjay191_1-1742545285238.png




If you found this helpful, please give a thumbs up OR mark it as the solution. Thank you!







Ankur Bawiskar
Tera Patron
Tera Patron

@AnilM99 

which text you want in bold?

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader