Auto-scroll window as needed to ensure drop-down choices are visible

This commit is contained in:
Lance Edgar 2017-11-22 11:21:59 -06:00
parent 40d2251844
commit 43ce0fb44f
3 changed files with 60 additions and 2 deletions

View file

@ -58,6 +58,10 @@
}
});
this.add_filter.on('selectmenuopen', function(event, ui) {
show_all_options($(this));
});
// Intercept filters form submittal, and submit via AJAX instead.
this.filters_form.on('submit', function() {
var settings = {filter: true, partial: true};
@ -258,6 +262,10 @@
}
});
this.verb_select.on('selectmenuopen', function(event, ui) {
show_all_options($(this));
});
// Enhance any date values with datepicker widget.
this.inputs.find('.value input[type="date"]').datepicker({
dateFormat: 'yy-mm-dd',
@ -267,7 +275,12 @@
// Enhance any choice/dropdown values with selectmenu.
this.inputs.find('.value select').selectmenu({
width: '15em'
// TODO: don't remember why this was here, but seems unwanted
// width: '15em'
});
this.inputs.find('.value select').on('selectmenuopen', function(event, ui) {
show_all_options($(this));
});
// Listen for button click, to keep checkbox in sync.