support highlighting areas right to left
Costa Tsaousis (ktsaou) committed
Nov 19, 2017 at 17:14 UTC
09209be0cf0882ee2612d1099db59f6b167a30fe
2 files changed
+8
-1
web/dashboard.js
+7
@@ -5851,6 +5851,13 @@ var NETDATA = window.NETDATA || {};
5851
context.isZooming = false;
5852
NETDATA.options.highlight_after = state.tmp.dygraph_highlight_after;
5853
NETDATA.options.highlight_before = dygraph.toDataXCoord(event.offsetX);
5854
+
5855
+ if(NETDATA.options.highlight_after > NETDATA.options.highlight_before) {
5856
+ var t = NETDATA.options.highlight_after;
5857
+ NETDATA.options.highlight_after = NETDATA.options.highlight_before;
5858
+ NETDATA.options.highlight_before = t;
5859
+ }
5860
+
5861
state.tmp.dygraph_highlight_after = null;
5862
dygraph.clearZoomRect_();
5863
dygraph.drawGraph_(false);
web/index.html
+1
-1
@@ -5318,6 +5318,6 @@
5318
</div>
5319
</div>
5320
<div id="hiddenDownloadLinks" style="display: none;" hidden></div>
5321
- <script type="text/javascript" src="dashboard.js?v20171118-5"></script>
5321
+ <script type="text/javascript" src="dashboard.js?v20171118-6"></script>
5322
</body>
5323
</html>