- This is because Chrome tries _very_ hard to make anything passed into
`Date.parse()` a valid date, including nonesense such as "a 1".
- Fixes DataTables/DataTables #874.
- Issue was due to the use of `position:fixed` for the element - from
c856d0eb232ce41c76d0c30739d33e47cc7288f4. Ironically that change just
moved the issue that it was trying to solve!
- Fixes DataTables/DataTables #866
- DataTables explicitly supports only jQuery 1.7+. `on` and `off` were
introduced in 1.7, so this isn't a problem.
- jQuery migrate shows warnings if bind and unbind are used
- Fixes DataTables/DataTables #853
Previously, date sorting of values that
failed to parse as a date were sorted as
if they were 1970-01-01 (Unix and JS epoch).
Now, they sort before other dates.
Example:
https://jsfiddle.net/qae6zjty/1/
- Previously it was only used for tables which were marked with the
`table-bordered`, but that caused issues with scrolling tables which
are borderless.
- See DataTables/FixedColumns #57
- It is useful to be able to replace some of the utility methods with
your own custom ones - for example a debounce rather than tha throttle
for filtering.
- This commit reorders the code a little to make that possible. No new
code is present at such - its really about reordering the current code
to make `$.fn.dataTable.util` the host for the original functions.
Backwards compatiblity is provided by assigning the util methods to
their old variables. With the next major update they should be removed
and the util methods used directly.
- Other util methods should be added at the same time, escapeHtml,
unique, etc.
- Fixes DataTables/DataTables #810
- Fixes DataTables/DataTables #800
- Its safe to check for `.length` on `orders` at this point since it can
be either a number, an array or undefined. The number and undefined
conditions have already been checked, so it must be an array (of
whatever length).
- This is primarily for the forum
- This is quite common in markdown extensions now and has plenty of
backup from Stackoverflow etc to suggest it is a good idea. About time
I did it as well!
- Issue was due to the use of `position:fixed` for the element - from
c856d0eb232ce41c76d0c30739d33e47cc7288f4. Ironically that change just
moved the issue that it was trying to solve!
- Fixes DataTables/DataTables #866
- DataTables explicitly supports only jQuery 1.7+. `on` and `off` were
introduced in 1.7, so this isn't a problem.
- jQuery migrate shows warnings if bind and unbind are used
- Fixes DataTables/DataTables #853
Previously, date sorting of values that
failed to parse as a date were sorted as
if they were 1970-01-01 (Unix and JS epoch).
Now, they sort before other dates.
Example:
https://jsfiddle.net/qae6zjty/1/
- Previously it was only used for tables which were marked with the
`table-bordered`, but that caused issues with scrolling tables which
are borderless.
- See DataTables/FixedColumns #57
- It is useful to be able to replace some of the utility methods with
your own custom ones - for example a debounce rather than tha throttle
for filtering.
- This commit reorders the code a little to make that possible. No new
code is present at such - its really about reordering the current code
to make `$.fn.dataTable.util` the host for the original functions.
Backwards compatiblity is provided by assigning the util methods to
their old variables. With the next major update they should be removed
and the util methods used directly.
- Other util methods should be added at the same time, escapeHtml,
unique, etc.
- Fixes DataTables/DataTables #810
- Fixes DataTables/DataTables #800
- Its safe to check for `.length` on `orders` at this point since it can
be either a number, an array or undefined. The number and undefined
conditions have already been checked, so it must be an array (of
whatever length).
* `dt-api rows()` and `dt-api row()` can now be used with a cell from
the table body (not limited to only the `tr` elements
* `dt-api columns()` and `dt-api column()` can now be used with a cell
from the table body (not just the column headers as before)
* All three selector types can use an element with the `data-dt-row`
and / or `data-dt-column` (as approrirate) attributes on them or a
parent. This is useful for API integration with FixedColumns and
Responsive. For example you can now pass a cell in a fixed column
into the `dt-api cell()` method to select the original cell.
- Fix is to remove the name attribute. This would have no effect on the
column width and means the radio element isn't in a group.
- See thread 32931
- Fixes DataTables/DataTables #569
- F6 changes the paging control (for the better) to require that there
be no `a` tag for the elements which can't be clicked on in the pager.
Unforuntately F5 requires them, so we need to detect which one is to
be used. This is done using a meta tag based on this discussion:
- http://foundation.zurb.com/forum/posts/36681
- F5 remains the main version for the moment, but will be bumped to F6
when the next version of DataTables is released
- The scrolling body used to have the header content retained but
hidden, while the footer was just emptied. But if the footer content
is long enough to define the width of the column this results in
column misalignment.
- Fix is to treat the footer in the same way as the header is.
Rational for this is that the number renderer expects a number
input, not HTML, but if non-numeric input is given the value is just
returned (now escaped) - for example an empty string.
- This is so that Buttons (and others) can listen for this event and
create the buttons before the user init functions. Otherwise they
would need a setTimeoutout to be able to access the Buttons methods
immediately.
- Factory builder redesigned to pass in window and document to the
factory method, mandating a small update to the AMD and Browser
loaders
- Main change in is the CommonJS loader which can now optionally have a
window object passed in - if it is not passed in `window` will be used
(if this is the case in a CommonJS environment without a root object
being passed in an error will occur).
- DataTables caches a reference to the jQuery instance so the plug-ins
can easily reference jQuery while retaining their current return of
the module they define. This basically means that DataTables core will
include jQuery for the plug-ins.
- This does increase the core library size by ~160 bytes which is rather
frustrating, but I think this is the correct way to go about it
- With thanks to Evan Carroll for input on this:
https://github.com/DataTables/Plugins/issues/199
Fix: Force a column width if `dt-init scrollX` is specified and a column width is given. This can be overruled if the width given is too small for the content
- We already use the width attribute to determine if the table should
resize dynamically to 100% width, so it makes sense to use that when
scroll-x is enabled as well.
- This still isn't perfect as Chrome seems to change between a
box-sizing calculation depending if scrolling is required or not so
there can be a shift in column widths when changing between a
scrolling state and not (column visibility) which is ugly, but is
proving to be difficult to deal with.
to reproduce the error and it is only occuring on Chrome Mac with a
combination of the CSS in the DataTables demos specifically. This is an
edge case that I'd rather not add code for at the moment.
Fix: Chrome has an odd bug whereby the max-height needs a reflow in order to be correctly calculated - otherwise a gap could appear at the bottom of the table
- Haven't been able to reproduce the Chrome issue in a simple test case
- its something to do with the scrollbars being shown while the scroll
column calculations / updates are being done and then no longer
being needed ater that point.
Dev: Code style updated to match DataTables (unwritten!) standard
Dev: Removed some of the protection on the cell index update on row
delete - it is safe to assume that since we have a cell node, we've
assigned an index to it.
- Using just `datatables` would be difficult since I and others already
publish packages with that name. Anyone using those packages already
would run into real issues if I were to change their meaning and
contents!
- Cannot pass in a `dt` instance - will always use the one from the
jQuery instance given
- Don't check for reinitialisation or for jQuery when working in the
browser - will throw an error if in browser and no jQuery, which is
correct, DataTables needs jQuery
New: CommonJS will load jQuery if it wasn't passed in
Fix: Bootstrap, Foundation and jQuery UI integration Javascript files use module.exports correctly
Dev: Change the file include "function" name to not conflict with `require`
- AMD / RequireJS - The Require documentation strongly discorages using
a named module, but I've used this in the past as the plug-ins need a
name to depend upon themselves. This is still `datatables` but if the
developer is using Require and it resolves automatically to a
different name (which it may depending upon their configuration) they
can use a map option to map their name to `datatables`. See
https://github.com/moment/moment/issues/1095
- CommonJS - Based on the disscussion in
https://github.com/DataTables/Plugins/issues/199 it seems that some
developers like to pass a certain version of jQuery in. This
modification allows them to do so while retaining backwards
compatiblity.
- Integration files - The UMD wrapper for these files have been
restructured to be easier to follow. Also, based on the discussion in
the Plugins issue noted above you can now pass in a jQuery instance or
not and likewise a DataTables object or not.
- To avoid direct conflict with `require()` the build scripts have been
updated to use a "function" called `_buildInclude`. Ultimatily this
should really be updated to use grunt or similar.
- I just updated my PHP and HTML Tidy was not installed which resulted
in the examples in the dist repo all being rewritten unfortunately.
This should stop that happening again.
- Bootstrap's CSS doesn't allow for using rows inside the
table-responsive class, so we need to add a couple of overrides to
support this.
- See thread 29738. Thanks danielbsnake72 and bkates for the input
- This comes about from thread 29819 which highlights that inserting the
buidler string as a variable into the static file causes issues.
- This will only take effect once 1.10.10 has been released
- The fix is to loop over the data array to find the cell. Slower, but
for an edge case I think this is an approriate fix.
- This fixes DataTables/DataTables #653
- The fix is to replace with more approriate options. The jquery
`$.merge` function in particular is useful and array concat when we
don't need to maintain a refernce.
- This fixes DataTables/DataTables #651
- This was caused by using `_fnGetRowElements` to get the cells. While
it was good for performance with large number or rows to do so, it
isn't needed for a single row and a single line of jQuery is simpliler
and doesn't trigger the set function
- Fixes DataTables/DataTables #638
- The issue was effectively duplicate code - for 1.9- compatiblity when
I introduced 1.10 I had the set function run specifically if a DOM
node was given. But later in the 1.10 series when it became possible
to have the data written to an object rather than an array, that code
would itself call the setter, thus leading to two calls when there is
a DOM node present for the row.
- The first is simply to remove the code that was running the setter for
the DOM specific case.
- This fixes DataTables/DataTables #638 and thread 25846. Thanks to
@Jamaur and @strang91 for following up on this.
- The issue was caused by the check for the `bScrollOversize` option
which looks for the container being the same width as its inner
content area. Obviously that happens to be true if there is no
scrollbar. Adding a check for the clientWidth not being 100 as well
resolves this.
- I've also combined the scrollbar width detection with the other
browser detect functions. The two functions were performing very
similar operations and so easily combined
- The browser detect DOM creation will only run once, rather than for
every table initialisation, optimising multi-table loading
- Fixes DataTables/DataTables #633 - Thanks to @nddery and @epitaphmike
for the input