Gorgias logo
Gorgias logo

All articles

Disable automatic font color changeUpdated a month ago

This suggestion isn't an official feature of our Chat widget, so our support for it is limited - we recommend that it be implemented by someone with a technical background.


The Chat will adjust font and icon color based on your configuration under the Appearance tab to improve accessibility and readability. Font and icon color will be dark over light background colors, and light over dark background colors, based on the contrast ratio. 

You can prevent this by using the following method:

1<script>
2 window.GORGIASCHAT_DISABLE_CONTRAST_COLOR = true
3</script>
Unlike the rest of the Gorgias Chat API scripts, the one above should be implemented without the gorgiaschat.init wrapper below due to the difference in logic on our back end.


Here's what the wrapper looks like, for reference - it should be excluded from the above script:

1<script>
2GorgiasChat.init().then(function() {
3
4})
5</script>
Was this article helpful?
Yes
No