diff --git a/vendor/assets/javascripts/active_admin_date_range_preset.js b/vendor/assets/javascripts/active_admin_date_range_preset.js index 4ed2d9a..44b565f 100644 --- a/vendor/assets/javascripts/active_admin_date_range_preset.js +++ b/vendor/assets/javascripts/active_admin_date_range_preset.js @@ -103,12 +103,11 @@ $(function () { return additional_items_html += '
' + el['title'] + '
'; }); - // Bind in the same tick the popup is appended. jQuery 3 reimplemented - // .ready() on top of a Deferred, whose .then schedules through - // setTimeout, so handlers attached inside it landed a macrotask late - // and the popup was on screen but inert until then. jQuery 4 keeps - // that implementation, so waiting buys nothing there either, and - // .ready() on a non-document collection has been deprecated since 3.0. + // Bind in the same tick the popup is appended. Active Admin 3 ships + // jQuery 3, which rebuilt .ready() on top of a Deferred whose .then + // schedules through setTimeout, so handlers attached inside it landed + // a macrotask late and the popup was on screen but inert until then. + // On a non-document collection the method is deprecated anyway. let container = $('
' + '
Today
' + '
Yesterday
' +