Open RichardNeill opened 6 years ago
Here is the solution to this.
table.on('mouseenter', 'td, th', function () {
var target = $(this),
rowspan = parseInt(target.attr('rowspan'), 10) || 1,
colspan = parseInt(target.attr('colspan'), 10) || 1,
offsetInMatrix = target.data('wholly.offsetInMatrix');
//Avoid issues with programmatically generated tables in tempusdominus datepicker.
if (typeof(offsetInMatrix) === "undefined"){
//console.log ("Undefined offsetInMatrix, ignoring.");
return;
}
I have a table which is highlighted by wholly, and that's great. However, inside some of the table cells, I am using the bootstrap datepicker, which generates its own table. If I click the datepicker, and then mouse-over the datepicker's tooltip, then every one of these cells generates this unhelpful console.log:
I don't actually need wholly to work within the embedded datepicker (indeed, it's best that it doesn't), but it would be nice to get rid of the error messages. Maybe we need a way to tell wholly that a table within a table should not be treated as inheriting the highlightable class?