ServiceNow for Teams - Change Font Style in Teams?

Mathias Johans1
Mega Expert

Hi!

We have successfully connected ServiceNow with Teams, but some topics is presented with different font styles in Teams

Portal:

find_real_file.png

Teams:

find_real_file.png

 

Is it possible to configure font styles for Teams?

4 REPLIES 4

Paul Curwen
Giga Sage

Hi, you can style it in your script Response Message. See example below

 

return "<p style='font-family:segoe ux;font-size:12px'>" + "I can see you are chatting with me in" + "<b>" + " Microsoft Teams." + "</b>" +  "<br><br>" +" Here are some useful tips:" + "<br><br>" + "You can type the following commands at any time:" + "<br><br>" + "<b>'hi'</b> - will start or end a conversation" + "<br><br>" + "<b>'restart'</b> - will begin a new conversation and end the current one" + "<br><br>" + "<b>'help</b>' - will remind you of these commands" + "</p>";
***If Correct/Helpful please take time mark as Correct/Helpful. It is much appreciated.***

Regards

Paul

Prakash36
ServiceNow Employee
ServiceNow Employee

You can modify topic as above suggestion. Its the RTE (Ritch Text Editor), it has implemented in Quebec release. So that it will be support text format in Msteams/slack.

 

Chris D
Mega Sage
Mega Sage

Just to add (at least for pre-Quebec users): ServiceNow renders HTML output as images in Teams which is what's unexplained in the original post.

To be honest, I've never bothered trying to change the font in the HTML style itself (apparently you can, as per Paul above), but it's more just a recognition of the differences - and then avoiding use of HTML output whenever possible for this reason. Can't wait to try out the rich text editor in Quebec!

If I recall, "\n" are no-code line breaks in the Portal, but Teams just renders them as spaces (not line breaks), so I think you'd need HTML ("<br/>") to do line breaks in Teams otherwise, which again, are rendered as images - in the ugly and obnoxious serif font - in Teams. 

Travis Rogers
ServiceNow Employee
ServiceNow Employee

As Prakash alluded to, Teams doesn't support HTML text formatting, thus why it displays as an image block. If you reconfigure your text responses to Rich Text (i.e. Markdown) they should render fine in Teams. 

Note that the rich text formatter came with Quebec. More documentation can be found here