Se rendre au contenu
Menu
Cette question a été signalée
1 Répondre
2647 Vues

 I want to change the style of Odoo tooltip (help="My help text" option in fields). But I am having probles including my custom style. I want to change the color of the tooltip box, heading and font size. Hint: I have backend_theme_v14, so maybe i need to put my style on top of that. This is what I have done so far:

https://stackoverflow.com/questions/75940325/how-to-change-style-of-tooltip-in-odoo-v14

assets.xml

Note that i already had a js file included



tooltip.css

I don't need every option. I just want to change the color of the tooltip box. the heading and make the font size bigger


/* Tooltip container */ .tooltip { position: relative; display: inline-block; border-bottom: 1px dotted rgb(80, 42, 231); /* If you want dots under the hoverable text */ } /* Tooltip text */ .tooltip .tooltiptext { visibility: hidden; width: 120px; background-color: rgb(42, 206, 75); color: rgb(205, 35, 35); text-align: center; padding: 5px 0; border-radius: 6px; /* Position the tooltip text - see examples below! */ position: absolute; z-index: 1; } /* Show the tooltip text when you mouse over the tooltip container */ .tooltip:hover .tooltiptext { visibility: visible; }
    
Avatar
Ignorer
Meilleure réponse

Hi,

Instead of a tooltip try o-tooltip

.o-tooltip {
position: relative;
display: inline-block;
background: red;
border-bottom: 1px dotted rgb(80, 42, 231); /* If you want dots under the hoverable text */
}

/* Tooltip text */
.o-tooltip .o-tooltip--technical--title {
visibility: hidden;
width: 120px;
background-color: rgb(42, 206, 75);
color: rgb(205, 35, 35);
text-align: center;
padding: 5px 0;
border-radius: 6px;
position: absolute;
z-index: 1;
}

/* Show the tooltip text when you mouse over the tooltip container */
.o-tooltip:hover .o-tooltip--technical--title {
visibility: visible;
}

Regards

Avatar
Ignorer
Publications associées Réponses Vues Activité
0
avr. 22
2108
1
févr. 22
3585
1
févr. 24
11731
2
juil. 25
1314
1
mai 25
828