score:0
there should be a chart-options attribute for the canvas.
you can add it like: chart-options="chartoptions"
.
then on your controller you can change the tooltip template by using this code:
$scope.chartoptions = {
tooltiptemplate: "<%= value %>"
}
but i am not sure if it works properly in chartjs 2.0. for that you can check this issue here : https://github.com/chartjs/chart.js/issues/2322
score:0
you could pass this to the attribute chart-options="options"
:
$scope.options= {
tooltips: {
callbacks: {
title: function(tooltipitem, data) {
return $scope.profile['detail']['freq-histogram']['long-labels'][tooltipitem[0].index];
}
}
}
};
Source: stackoverflow.com
Related Query
- Make Chart.js ToolTip different then data
- chart js tooltip how to control the data that show
- Add all data in the tooltip of Chart JS
- ng2-charts customize data and whole html content of tooltip displayed when hovering on bar chart
- Chartjs - Insert additional data into chart tooltip
- ChartJS (React) Line Chart - How to show single tooltip with data and labels from 3 (multiple) dataset?
- How can I have different values for the chart and the tooltip in chart.js?
- create different labels for different data chart js
- How to reuse a Chartjs Chart component in with different Data and get past the **Canvas is already in use** error?
- Make chartjs pie chart wiyh dynamic data
- How to show tooltip value of all data falling on the same axis in chart js?
- ng2-Chart: can we show the tooltip data of pie chart on load?
- Charts JS: Doughnut chart and hiding tooltip for specific data index within each dataset
- How to show tooltip only when data available in chart js?
- How to assign different background colors to chart.js pie chart data set?
- How to stop displaying the data values from different data objects on Chart JS 2.x?
- ng2-charts doughnut chart with different data per series
- React Chart.js Match API data to what Title is displaying, then update chart on data/Title change
- How to start the chart from specific time and offest hour and then show the data on chart from target datetime in chartjs
- How do i have a single Chart.vue component instead of different chart components and then display charts from it by changing id of the API
- Two data sets with different time instances on the same ChartJs chart
- How do I destroy/update Chart Data in this chart.js code example?
- getting additional value fields from data source for dx.chartjs doughnut chart
- Chart.js how to make chart only show the most recent data
- concatenate on tooltip from data array in chart js
- Grouped bar chart having each group with different data using chart.js
- Chart JS - Make chart scrollable if too much data
- how can I make selected data is highlighted on chart js?
- chart.js mixed chart with different data points
- Chart JS: Donut/Doughnut Chart: Tooltip to be shown always for all the data. All tooltip is not shown when multiple data are with 0 data
More Query from same tag
- Custom empty screen for ng2-charts
- ng2-charts : Newly added rows not getting displayed on phone devices
- Chart.js - Increase space between y Axes and the first column bar
- How to change font weight of footer in tooltips in Chart JS
- Having issues with running npm start after installing chartjs
- How to insert php in data chart.js
- Extjs with Devexpress ChartJS
- ChartJS chart not scaling after adding values
- Label is too long in Doughnut Chart
- How to add label square to Bar Chart using Chart.js
- Add data dynamically to chart
- Chart JS - Horizontal Bar Chart Not Filling Canvas
- Razor chart.js labels/data not in sync
- chartjs-plugin-datalabels not showing on stacked horizontal bar
- Acceptable Range Highlighting of Background in Chart.js 2.0
- chart.js barchart without set fill color
- Page break in Angular with Chartjs and tables
- Chart.js error Cannot read property 'length' of null
- Error: $injector:modulerr Module Error - chart.js
- How do I display a chart with chart.js?
- Prime NG Customise tool tip on Bar Chart
- How pass a variable from code behind to javascript
- ChartJS / Chartjs-plugin-annotation How to draw multiple vertical lines using an array?
- Chart.js - Define custom y-axis scale
- Line chart: align x axis (timestamps) for multiple data sets
- ChartJS v2.6.0 unintended behaviour in Internet Explorer
- "Responsive" Chart.js chart is taller than the containing window
- Filling area between two lines - Chart.js v2
- Hide the element text on line charts since it overlaps with the line
- Bar chart legend adjustments - Chart JS