Disable truncation of filter labels in searchpanes
Disable truncation of filter labels in searchpanes
timswan
Posts: 2Questions: 1Answers: 0
I've done extensive searching to try to figure out how to disable the truncation of the text in searchpanes filter labels, but have had no luck. One option I saw was to add the following to the table initialization, but the text is still truncated, since that appears the be trimmed by the javascript.
initComplete: function(settings, json) {
$('.dtsp-title, .dtsp-name').each(function() {
$(this).css({
'white-space': 'normal',
'word-wrap': 'break-word',
'overflow': 'visible',
'text-overflow': 'clip'
});
});
},
Has anyone successfully allowed the full filter label to be shown?
Answers
I haven't tried that code so not sure if it does what you want but I suspect that SearchPanes might not be completely added to the document when
initComplete
is executed. If you are using Datatables 2.0 then try that code in theready()
function which, as I understand it, should run after Datatables is complete and SearchPanes iss complete. Or if using a previous version then maybe use setTimeout() with a short timer ininitComplete
.Kevin
I finally figured out how to disable the truncation of the filter label in the searchpane by using the (possibly deprecated)
dataLength: 100
, like so: