# Tooltips in FlexChart

Learn how to add tooltips to Wijmo's chart components in this documentation topic

## Content

The FlexChart has built-in support for tooltips. By default, the control displays tooltips when the user touches or hovers the mouse on a data point.

The tooltip content is generated using a template, which may contain the following parameters:

* __seriesName__: The name of the series that contains the chart element.
* __pointIndex__: The index of the chart element within the series.
* __x__: The x value of the chart element.
* __y__: The y value of the chart element.

By default, the tooltip template is set to:

```HTML
<b>{seriesName}</b><br/>{x} {y}
```
The tooltip content template supports bound fields from the data set:

```JavaScript
myChart.tooltip: { content: "<b>{company}</b><br/>{sales:c2}"
```
The tooltip content template supports any HTML such as tables and images.

```JavaScript
myChart.tooltip: { content: "<img src='resources/{x}.png'/> <b>{seriesName}</b><br/>{y}"
```
![Chart Tooltip with Image](https://cdn.mescius.io/document-site-files/images/3c7113e2-10b3-45ed-8f3b-9fb1e0af2b74/chart/chart-tooltip1.png)

Table Tooltip Example

```JavaScript
myChart.tooltip.content = '<b>{date:MMM dd}</b><br/>' +
      	'<table>' +
      	  '<tr><td>high</td><td>{high:c}</td><tr/>' +
      	  '<tr><td>low</td><td>{low:c}</td><tr/>' +
      	  '<tr><td>open</td><td>{open:c}</td><tr/>' +
      	  '<tr><td>close</td><td>{close:c}</td><tr/>' +
        '</table>';
```
![Chart Tooltip with Table](https://cdn.mescius.io/document-site-files/images/3c7113e2-10b3-45ed-8f3b-9fb1e0af2b74/chart/chart-candlestick-tooltip.png)

## Disabling the Tooltip
You can disable the chart tooltips by setting the template to an empty string.

```JavaScript
myChart.tooltip.content = '';
```

## Styling the Tooltip
The tooltip content can be styled using rich html. You can adjust other settings like background, border and padding through CSS styles that can be applied to the __.wj-tooltip__class.

```CSS
.wj-tooltip {
  padding: 12px;
}
```