Docs: add duplicateSpan change

This commit is contained in:
Rob Garrison 2016-04-06 22:22:18 -05:00
parent 053553d4dd
commit 6834ec74a9

View File

@ -589,12 +589,13 @@
<td><a href="#" class="permalink">duplicateSpan</a></td>
<td>Boolean</td>
<td>true</td>
<td>Any <code>colspan</code> cells in the tbody may have its content duplicated in the cache for each spanned column (<span class="version">v2.25.0</span>).
<td>Any <code>colspan</code> cells in the tbody may have its content duplicated in the cache for each spanned column (<span class="version">v2.25.0</span>; <span class="version updated">v2.25.8</span>).
<div class="collapsible">
<p>If <code>true</code>, the cache will contain duplicated cell contents for every column the <code>colspan</code> includes. This makes it easier to sort &amp; filter columns because a cell spanning all columns will only work with one parser. If <code>false</code>, the contents of cells that are spanned will be set to an empty string.</p>
<p>If <code>true</code>, the cache will contain duplicated cell contents for every column the <code>colspan</code> includes. This makes it easier to sort &amp; filter columns because a cell spanning all columns will only work with one parser.</p>
<p>In <span class="version updated">v2.25.8</span>, the contents of cells that are spanned will be set to an empty string only if the <code>textExtraction</code> setting is left as a string. If a function is added, it will be used to attempt to extract other content from the spanned cell (see <a href="">Stackoverflow</a> for an example).</p>
<pre class="prettyprint lang-js">// this row: &lt;tr&gt;&lt;td colspan="3"&gt;foo&lt;/td&gt;&lt;td&gt;bar&lt;/td&gt;&lt;/tr&gt; results in this row cache:
[ 'foo', 'foo', 'foo', 'bar' ] // if duplicateSpan = true
[ 'foo', '', '', 'bar' ] // if duplicateSpan = false</pre>
[ 'foo', '', '', 'bar' ] // if duplicateSpan = false (no textExtraction function)</pre>
<span class="label warning">*NOTE*</span>
<ul>
<li>Cells in the tbody with a <code>rowspan</code> are <em>not yet supported</em> and will not sort or filter as you would expect.</li>