Merge branch 'master' of https://github.com/elasticsearch/kibana into negatives
This commit is contained in:
commit
61b08ebfd9
|
@ -166,6 +166,8 @@ define(function (require) {
|
|||
var brush = this.createBrush(xScale, svg);
|
||||
|
||||
function brushEnd() {
|
||||
if (!validBrushClick(d3.event)) return;
|
||||
|
||||
var bar = d3.select(this);
|
||||
var startX = d3.mouse(svg.node());
|
||||
var startXInv = xScale.invert(startX[0]);
|
||||
|
@ -237,6 +239,14 @@ define(function (require) {
|
|||
svg.insert('g', 'g')
|
||||
.attr('class', 'brush')
|
||||
.call(brush)
|
||||
.call(function (brushG) {
|
||||
// hijack the brush start event to filter out right/middle clicks
|
||||
var brushHandler = brushG.on('mousedown.brush');
|
||||
if (!brushHandler) return; // touch events in use
|
||||
brushG.on('mousedown.brush', function () {
|
||||
if (validBrushClick(d3.event)) brushHandler.apply(this, arguments);
|
||||
});
|
||||
})
|
||||
.selectAll('rect')
|
||||
.attr('height', height - margin.top - margin.bottom);
|
||||
|
||||
|
@ -244,6 +254,10 @@ define(function (require) {
|
|||
}
|
||||
};
|
||||
|
||||
function validBrushClick(event) {
|
||||
return event.button === 0;
|
||||
}
|
||||
|
||||
|
||||
return Dispatch;
|
||||
};
|
||||
|
|
|
@ -48,7 +48,7 @@ define(function (require) {
|
|||
$el.toggleClass('only-visualization', !$scope.spy.mode);
|
||||
$el.toggleClass('visualization-and-spy', $scope.spy.mode && !fullSpy);
|
||||
$el.toggleClass('only-spy', Boolean(fullSpy));
|
||||
$spyEl.toggleClass('only', Boolean(fullSpy));
|
||||
if ($spyEl) $spyEl.toggleClass('only', Boolean(fullSpy));
|
||||
|
||||
// internal
|
||||
$visEl.toggleClass('spy-visible', Boolean($scope.spy.mode));
|
||||
|
|
|
@ -62,7 +62,8 @@
|
|||
<span bindonce bo-bind="opts.savedSearch.title"></span>
|
||||
<i tooltip="Reload saved query" ng-click="resetQuery();" class="fa fa-undo small"></i>
|
||||
</span>
|
||||
<strong class="discover-info-hits">{{(hits || 0) | number:0}}</strong> hits
|
||||
<strong class="discover-info-hits">{{(hits || 0) | number:0}}</strong>
|
||||
<ng-pluralize count="hits" when="{'1':'hit', 'other':'hits'}"></ng-pluralize>
|
||||
</div>
|
||||
|
||||
<div class="discover-content">
|
||||
|
|
Loading…
Reference in a new issue