How to change dash table tooltip size

I want to change dash table tooltip width.
I tried to use custom css, but did not work.

.dash-tooltip .dash-table-tooltip {
max-width: 200px;
min-width: 100px;

I also tried to use dash_table.css option


css=[{‘selector’: ‘dash-table-tooltip’, ‘rule’: ‘max-width: 200px; min-width: 100px;’}],

How can I change dash table tooltip style?

Same problem here, could you figure it out?

Okay nevermind, I finally found it!

It’s pretty simple actually, you just have to override both the width and the max-width property on .dash-table-tooltip, and remember to add !important so they get precedence.

This is the related file from the tooltips PR where you can see the default styles:

1 Like