Use mesh tooltips on any element to display extra information on hover.
Usage
Using a tooltip with mesh is a piece of cake, you can have the tooltips come in from different directions, as
well as a dark mode. See the notation below to get started.
The tooltip attribute should be added which contains the text of the tooltip.
Note: The tooltip can be applied to any semantic element.
<button class="btn btn-secondary" tooltip="I am a tooltip">Default</button>
Position
The default position of the tooltip as at the top, but if you wish to change this, add the tooltip-position attribute equal to one of four properties:
top
right
bottom
left
<button class="btn btn-secondary" tooltip="I am a tooltip" tooltip-position="top">Top</button>
<button class="btn btn-secondary" tooltip="I am a tooltip" tooltip-position="right">Right</button>
<button class="btn btn-secondary" tooltip="I am a tooltip" tooltip-position="bottom">Bottom</button>
<button class="btn btn-secondary" tooltip="I am a tooltip" tooltip-position="left">Left</button>
Dark mode
To invert the colors of the tooltip to create a dark effect, add the tooltip-color
attribute set equal to dark, see below.
<button class="btn btn-dark" tooltip="I am a dark tooltip" tooltip-color="dark">Default</button>
Variables
Add a description here:
Variable
Value
Description
$tooltip-enable-dark: true !default;
Boolean
Enables/disables the dark mode of the tooltip component.
$tooltip-font-color: #666 !default;
Color
Font color of the default tooltip.
$tooltip-dark-color: #323232 !default;
Color
Background color of the dark tooltip, the font color will autotmatically be black/white
dependant on input.