diff --git a/.datatables-commit-sync b/.datatables-commit-sync index 00360c97..b7843355 100644 --- a/.datatables-commit-sync +++ b/.datatables-commit-sync @@ -1 +1 @@ -a4723cd28da1a8133232eb5ce83e19b8ff86a50d +4e31fb7585a9b338257edd8472de37255f924a0d diff --git a/media/js/jquery.dataTables.js b/media/js/jquery.dataTables.js index c38ef974..ba5e23b7 100644 --- a/media/js/jquery.dataTables.js +++ b/media/js/jquery.dataTables.js @@ -5693,6 +5693,9 @@ { oSettings.oScroll.iBarWidth = _fnScrollBarWidth(); } + if ( oSettings.oScroll.sX === true ) { // Easy initialisation of x-scrolling + oSettings.oScroll.sX = '100%'; + } if ( oSettings.iInitDisplayStart === undefined ) { @@ -10926,12 +10929,14 @@ /** - * Enable horizontal scrolling. When a table is too wide to fit into a certain - * layout, or you have a large number of columns in the table, you can enable - * x-scrolling to show the table in a viewport, which can be scrolled. This - * property can be any CSS unit, or a number (in which case it will be treated - * as a pixel measurement). - * @type string + * Enable horizontal scrolling. When a table is too wide to fit into a + * certain layout, or you have a large number of columns in the table, you + * can enable x-scrolling to show the table in a viewport, which can be + * scrolled. This property can be `true` which will allow the table to + * scroll horizontally when needed, or any CSS unit, or a number (in which + * case it will be treated as a pixel measurement). Setting as simply `true` + * is recommended. + * @type boolean|string * @default blank string - i.e. disabled * * @dtopt Features @@ -10940,7 +10945,7 @@ * @example * $(document).ready( function() { * $('#example').dataTable( { - * "scrollX": "100%", + * "scrollX": true, * "scrollCollapse": true * } ); * } );