How to set font color of ToolTip in fluent-ui

1.2k views Asked by At

Not able to set font color of ToolTipHost in fluent-ui, I tried below code but it is not working.

<TooltipHost content="Tooltip Content"
    calloutProps: {
      styles: {
        calloutMain: { background: 'red',color:'white' },
      },
    },
/>
1

There are 1 answers

0
Marko Savic On BEST ANSWER

Use tooltipProps and styles inside it:

<TooltipHost
   ...
   tooltipProps={{
     styles: {
       content: { color: '#f00' }
     }
   }}
/>

Full working example Codepen.