Tell us what’s happening:
my tooltip is not visible whatsoever. I have tried every outcome visible to me. Nothing works. Some solutions make the problem worse and some give a complete different error.
link to my project is:
Your code so far
.on('mouseenter', (d, i) => {
tooltip.classList.add('toolbar');
tooltip.style.left = i * barWidth + padding * 2 + 'px';
tooltip.style.top = h - padding * 4 + 'px';
tooltip.setAttribute('data-date', d[0])
console.log(tooltip);
tooltip.innerHTML = `
<small>${d[0]}</small>
$${d[1]} billions
`;
}).on('mouseout', () => {
tooltip.classList.remove('toolbar');
console.log(tooltip);
});
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/84.0.4147.105 Safari/537.36
.
Challenge: Visualize Data with a Bar Chart
Link to the challenge: