Commit d10e45e1 authored by Tomas Dabasinskas's avatar Tomas Dabasinskas Committed by stuart nelson

Update routing-tree to support label values containing spaces (solves #1201) (#1202)

* Stop replacing spaces in label value

* Ignore spaces after commas
Signed-off-by: 's avatarTomas Dabasinskas <tomas@dabasinskas.net>
parent e319ebf4
...@@ -26,10 +26,10 @@ var tooltip = d3.select("body") ...@@ -26,10 +26,10 @@ var tooltip = d3.select("body")
.style("visibility", "hidden"); .style("visibility", "hidden");
function parseSearch(searchString) { function parseSearch(searchString) {
var labels = searchString.replace(/{|}|\"|\'|\s/g, "").split(","); var labels = searchString.replace(/{|}|\"|\'/g, "").split(",");
var o = {}; var o = {};
labels.forEach(function(label) { labels.forEach(function(label) {
var l = label.split("="); var l = label.trim().split("=");
o[l[0]] = l[1]; o[l[0]] = l[1];
}); });
return o; return o;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment