Repository navigation
v5.3.0
-
BSDateRangePicker: no JQuery anymore.- The bundled date range picker (
lib/components/daterangepicker) is now
vanilla-datetimerange-picker (commit32608b3): Dan
Grossman'sdaterangepicker3.1 (the previous one) without JQuery. Same options, behavior and CSS (the open
picker renders identically). It still uses Moment. load: doesn't load JQuery.- The picker is created with
new DateRangePicker(element, config, callback). - New
jsPicker: the JSDateRangePickerinstance. - The JS picker is removed (its container in
document.body, and its listeners) on a new render,clearand
dispose(it used to be left there). Deferred, so a render triggered by the picker callback (e.g.onChange
→refresh) doesn't break the picker while it's applying. - If
daterangepicker.jsfailed to load, renders only the date text (no error). daterangepicker.jslocal patches: the 2 previous ones, plus:clickApply/clickCancel: theapply/cancelevents dispatched on the picker element, as in the original
(the port failed when called without an event).remove: removes the picker container from the document and the windowresizelistener, and sets
isShowing = false, as in the original.outsideClick: "inside the picker" by element identity, as in the original (the port matched any element with
the same tag and classes, e.g. another picker field, keeping two pickers open).
- The bundled date range picker (
-
JQuery is no longer loaded by this package (only with
JQuery.load()): callJQuery.load()if the app uses it. -
README: JQuery and Date Range Picker in the bundled libraries; new "See also" section with the related projects.
-
Tests:
- New
bones_ui_bootstrap_daterangepicker_test.dart:BSDateRangePickerwithout JQuery, two pickers in the page
(loading, JS selection calling back into Dart, opening on click, a click on the other picker field closing the
open one, a click inside keeping it open, a new render orclearremoving the JS picker, a render from
onChangewhile applying). - Integration tests use
BSDateRangePicker.jsPicker(not JQuerydata). - Consistency: the new
daterangepicker.jslocal patches, and no JQuery in it.
- New