From 6e51a62684d0833d685477f1bf83278ca59def45 Mon Sep 17 00:00:00 2001 From: Allan Jardine Date: Thu, 21 May 2020 09:24:54 +0000 Subject: [PATCH] Avoid applying padding to non sortable items on small tables I don't know if there are more to this or if it would break some other rules but as of my testing it should be fine to remove this rule for headers that have no sorting applied to them. This is the case already for "normal sized" tables as the padding-right rule is only applied if there is a sorting class to the element. But it has been forgotten for the table-sm variant. So there are two options that I can see. Specify this rule does not apply if there is a sorting_disabled class Do the same as what was done for the normal sized table in the following commit: 4e611f31ff84deae5ae4666c7ba60ad8cb1012c3 --- .datatables-commit-sync | 2 +- composer.json | 2 +- dataTables.jquery.json | 2 +- examples/advanced_init/column_render.html | 34 +- examples/advanced_init/complex_header.html | 36 +- examples/advanced_init/defaults.html | 34 +- .../advanced_init/dom_multiple_elements.html | 36 +- examples/advanced_init/dom_toolbar.html | 34 +- examples/advanced_init/dt_events.html | 34 +- examples/advanced_init/events_live.html | 34 +- examples/advanced_init/footer_callback.html | 26 +- .../advanced_init/html5-data-attributes.html | 34 +- .../advanced_init/html5-data-options.html | 14 +- examples/advanced_init/index.html | 4 +- examples/advanced_init/language_file.html | 34 +- examples/advanced_init/length_menu.html | 34 +- examples/advanced_init/object_dom_read.html | 34 +- examples/advanced_init/row_callback.html | 34 +- examples/advanced_init/row_grouping.html | 60 ++-- .../advanced_init/sort_direction_control.html | 36 +- examples/ajax/custom_data_flat.html | 10 +- examples/ajax/custom_data_property.html | 14 +- examples/ajax/data/arrays.txt | 4 +- examples/ajax/data/arrays_custom_prop.txt | 4 +- examples/ajax/data/arrays_subobjects.txt | 4 +- examples/ajax/data/objects.txt | 4 +- examples/ajax/data/objects_deep.txt | 4 +- examples/ajax/data/objects_root_array.txt | 4 +- examples/ajax/data/objects_subarrays.txt | 4 +- examples/ajax/data/orthogonal.txt | 4 +- examples/ajax/deep.html | 10 +- examples/ajax/defer_render.html | 10 +- examples/ajax/index.html | 4 +- examples/ajax/null_data_source.html | 12 +- examples/ajax/objects.html | 10 +- examples/ajax/objects_subarrays.html | 10 +- examples/ajax/orthogonal-data.html | 10 +- examples/ajax/simple.html | 12 +- examples/api/add_row.html | 24 +- examples/api/api_in_init.html | 34 +- examples/api/counter_columns.html | 36 +- examples/api/form.html | 40 +-- examples/api/highlight.html | 40 +-- examples/api/index.html | 4 +- examples/api/multi_filter.html | 44 +-- examples/api/multi_filter_select.html | 53 ++- examples/api/regex.html | 34 +- examples/api/row_details.html | 22 +- examples/api/select_row.html | 46 +-- examples/api/select_single_row.html | 47 +-- examples/api/show_hide.html | 44 +-- examples/api/tabs_and_scrolling.html | 17 +- examples/basic_init/alt_pagination.html | 36 +- examples/basic_init/comma-decimal.html | 34 +- examples/basic_init/complex_header.html | 34 +- examples/basic_init/dom.html | 34 +- examples/basic_init/filter_only.html | 38 +- examples/basic_init/flexible_width.html | 36 +- examples/basic_init/hidden_columns.html | 34 +- examples/basic_init/index.html | 6 +- examples/basic_init/language.html | 36 +- examples/basic_init/multi_col_sort.html | 14 +- examples/basic_init/multiple_tables.html | 48 +-- examples/basic_init/scroll_x.html | 14 +- examples/basic_init/scroll_xy.html | 14 +- examples/basic_init/scroll_y.html | 34 +- examples/basic_init/scroll_y_dynamic.html | 34 +- examples/basic_init/state_save.html | 34 +- examples/basic_init/table_sorting.html | 34 +- examples/basic_init/zero_configuration.html | 34 +- examples/data_sources/ajax.html | 10 +- examples/data_sources/dom.html | 36 +- examples/data_sources/index.html | 8 +- examples/data_sources/js_array.html | 16 +- examples/data_sources/server_side.html | 10 +- examples/index.html | 6 +- examples/plug-ins/api.html | 36 +- examples/plug-ins/dom_sort.html | 34 +- examples/plug-ins/index.html | 4 +- examples/plug-ins/range_filtering.html | 38 +- examples/plug-ins/sorting_auto.html | 41 +-- examples/plug-ins/sorting_manual.html | 42 +-- examples/resources/demo.js | 12 +- examples/resources/syntax/shCore.css | 17 +- examples/server_side/custom_vars.html | 10 +- examples/server_side/defer_loading.html | 32 +- examples/server_side/ids.html | 10 +- examples/server_side/index.html | 12 +- examples/server_side/jsonp.html | 12 +- examples/server_side/object_data.html | 10 +- examples/server_side/pipeline.html | 18 +- examples/server_side/post.html | 10 +- examples/server_side/row_details.html | 10 +- examples/server_side/scripts/firebird.sql | 73 ---- examples/server_side/scripts/ids-arrays.php | 2 +- examples/server_side/scripts/ids-objects.php | 2 +- examples/server_side/scripts/jsonp.php | 2 +- examples/server_side/scripts/mysql.sql | 4 +- examples/server_side/scripts/oracle.sql | 144 ++++---- examples/server_side/scripts/post.php | 2 +- examples/server_side/scripts/postgres.sql | 4 +- .../server_side/scripts/server_processing.php | 2 +- examples/server_side/scripts/sqlite.sql | 117 +++--- examples/server_side/scripts/sqlserver.sql | 116 +++--- examples/server_side/scripts/ssp.class.php | 39 +- examples/server_side/select_rows.html | 14 +- examples/server_side/simple.html | 16 +- examples/styling/bootstrap.html | 43 ++- examples/styling/bootstrap4.html | 40 +-- examples/styling/cell-border.html | 34 +- examples/styling/compact.html | 37 +- examples/styling/display.html | 34 +- examples/styling/foundation.html | 42 +-- examples/styling/hover.html | 38 +- examples/styling/index.html | 6 +- examples/styling/jqueryUI.html | 38 +- examples/styling/material.html | 48 ++- examples/styling/no-classes.html | 34 +- examples/styling/order-column.html | 34 +- examples/styling/row-border.html | 34 +- examples/styling/semanticui.html | 44 ++- examples/styling/stripe.html | 34 +- examples/styling/uikit.html | 44 +-- media/css/dataTables.bootstrap4.css | 8 +- media/css/dataTables.bootstrap4.min.css | 2 +- media/css/dataTables.jqueryui.css | 2 +- media/css/dataTables.jqueryui.min.css | 2 +- media/css/dataTables.material.css | 43 +-- media/css/dataTables.material.min.css | 2 +- media/css/dataTables.semanticui.css | 2 +- media/css/dataTables.semanticui.min.css | 2 +- media/css/dataTables.uikit.css | 70 ++-- media/css/dataTables.uikit.min.css | 2 +- media/css/jquery.dataTables.css | 2 +- media/css/jquery.dataTables.min.css | 2 +- media/js/dataTables.bootstrap.min.js | 2 +- media/js/dataTables.bootstrap4.js | 4 +- media/js/dataTables.bootstrap4.min.js | 8 +- media/js/dataTables.foundation.js | 4 +- media/js/dataTables.foundation.min.js | 7 +- media/js/dataTables.jqueryui.min.js | 2 +- media/js/dataTables.material.js | 93 +---- media/js/dataTables.material.min.js | 17 +- media/js/dataTables.semanticui.js | 10 +- media/js/dataTables.semanticui.min.js | 6 +- media/js/dataTables.uikit.js | 6 +- media/js/dataTables.uikit.min.js | 6 +- media/js/jquery.dataTables.js | 322 ++++++----------- media/js/jquery.dataTables.min.js | 334 +++++++++--------- media/js/jquery.js | 10 +- package.json | 2 +- 151 files changed, 1946 insertions(+), 2306 deletions(-) delete mode 100644 examples/server_side/scripts/firebird.sql diff --git a/.datatables-commit-sync b/.datatables-commit-sync index 102fabed..3023a24c 100644 --- a/.datatables-commit-sync +++ b/.datatables-commit-sync @@ -1 +1 @@ -67abd45d6995d914a0f4c6eb06f9ec1c4f8035dd +8f9daac0fedf3de08b191c663e2ccbcccdb6ae44 diff --git a/composer.json b/composer.json index d4b1cb17..ae0b450a 100644 --- a/composer.json +++ b/composer.json @@ -1,6 +1,6 @@ { "name": "datatables/datatables", - "version": "1.10.21-dev", + "version": "1.10.21", "description": "DataTables is a plug-in for the jQuery Javascript library. It is a highly flexible tool, based upon the foundations of progressive enhancement, which will add advanced interaction controls to any HTML table.", "homepage": "http://www.datatables.net/", "author": "SpryMedia", diff --git a/dataTables.jquery.json b/dataTables.jquery.json index 836843da..efd81803 100644 --- a/dataTables.jquery.json +++ b/dataTables.jquery.json @@ -1,6 +1,6 @@ { "name": "DataTables", - "version": "1.10.21-dev", + "version": "1.10.21", "description": "DataTables enhances HTML tables with the ability to sort, filter and page the data in the table very easily. It provides a comprehensive API and set of configuration options, allowing you to consume data from virtually any data source.", "homepage": "http://datatables.net/", "docs": "http://datatables.net/", diff --git a/examples/advanced_init/column_render.html b/examples/advanced_init/column_render.html index 386527e6..4c02f0ed 100644 --- a/examples/advanced_init/column_render.html +++ b/examples/advanced_init/column_render.html @@ -3,7 +3,7 @@ - + DataTables example - Column rendering @@ -11,7 +11,7 @@ - + @@ -52,7 +52,7 @@ $(document).ready(function() { assigning colours based on content rules and any other form of text manipulation you require.

- +
@@ -63,6 +63,16 @@ $(document).ready(function() { + + + + + + + + + + @@ -251,7 +261,7 @@ $(document).ready(function() { - + @@ -307,7 +317,7 @@ $(document).ready(function() { - + @@ -521,16 +531,6 @@ $(document).ready(function() { - - - - - - - - - -
NameSalary
NamePositionOfficeAgeStart dateSalary
Tiger Nixon
Doris Wilder Sales AssistantSydneySidney 23 2010/09/20 $85,600
Michelle House Integration SpecialistSydneySidney 37 2011/06/02 $95,400$112,000
NamePositionOfficeAgeStart dateSalary