Skip to content

Commit 898113f

Browse files
committed
Only hide popovers on html click that are actually showing to avoid triggering unnecessary filter changes
1 parent 16888ee commit 898113f

File tree

2 files changed

+10
-4
lines changed

2 files changed

+10
-4
lines changed

Build/CommonAssemblyInfo.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,6 @@
1515
//
1616
// You can specify all the values or you can default the Revision and Build Numbers
1717
// by using the '*' as shown below:
18-
[assembly: AssemblyVersion("1.6.1")]
19-
[assembly: AssemblyFileVersion("1.6.1")]
18+
[assembly: AssemblyVersion("1.6.2")]
19+
[assembly: AssemblyFileVersion("1.6.2")]
2020
//[assembly: AssemblyInformationalVersion("1.4.5-editlyalpha2")]

Griddly/Scripts/griddly.js

+8-2
Original file line numberDiff line numberDiff line change
@@ -108,9 +108,15 @@
108108

109109
$("html").on("click", $.proxy(function (event)
110110
{
111-
if ($(event.target).parents('.popover.in').length == 0 && $(event.target).parents(".filter-trigger").length == 0 && !$(event.target).hasClass("filter-trigger"))
111+
if (this.options.filterMode == "Inline" && $(event.target).parents('.popover.in').length == 0 && $(event.target).parents(".filter-trigger").length == 0 && !$(event.target).hasClass("filter-trigger"))
112112
{
113-
$(".griddly-filters-inline .filter-trigger").popover("hide");
113+
$(".griddly-filters-inline .filter-trigger").each(function ()
114+
{
115+
var filter = $(this);
116+
117+
if (filter.data('bs.popover').tip().hasClass('in'))
118+
filter.popover("hide");
119+
});
114120
}
115121
}, this));
116122

0 commit comments

Comments
 (0)