possible bug with canvas [sparklines] and fixed columns?
possible bug with canvas [sparklines] and fixed columns?
I have a datatables table setup in a standalone html doc (I've started making all my reports for management standalone html docs with datatables and they are going ga-ga over them) that is using sparklines and it looks great !!
But when I turn on fixed columns then the sparklines are reduced to a 1-pixel wide display even tho' the canvas is the right width when you inspect it...
I'm running on latest chrome over latest mac os x
thanks for your time
Al;
see this jsbin https://jsbin.com/pifaroyake/edit?html,output
search on: uncomment -- to find the change to make
// uncomment this to break the sparklines
// obj.fixedColumns = {leftColumns: 2 };
This question has an accepted answers - jump to answer
Answers
perhaps this is instead a bug in the fixedColumns() part of the api -- when I changed by code to access the static column-cells without using datatables then I was able to put in the sparklines
obviously, this is a non-optimal solution -- but it keeps me moving for now!
I think the problem is the cloning of the original table cells. Your
columns().nodes()
loop is acting upon the original cells, rather than the floating cloned cells. Your workaround above is probably the best option at the moment.Allan
Is access to the floating cloned cells planned?
Its something I would like to add, but I'm not certain what the correct API would be for it.
columnsFloating().nodes()
perhaps, but that could possibly confusing and I'm concerned about how much code that would add.Allan
columnsFixed().clonedNodes()