From f07c8108fc0fdb09a2b6c7e00a166bad6072c780 Mon Sep 17 00:00:00 2001 From: Nick O'Leary Date: Tue, 22 Mar 2016 13:58:24 +0000 Subject: [PATCH] Change style of nodes in subflow template view --- editor/js/ui/view.js | 7 +++++-- editor/sass/flow.scss | 5 ++++- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/editor/js/ui/view.js b/editor/js/ui/view.js index a125bc4c0..b96b25890 100644 --- a/editor/js/ui/view.js +++ b/editor/js/ui/view.js @@ -1434,7 +1434,10 @@ RED.view = (function() { var node = vis.selectAll(".nodegroup").data(activeNodes,function(d){return d.id}); node.exit().remove(); - var nodeEnter = node.enter().insert("svg:g").attr("class", "node nodegroup"); + var nodeEnter = node.enter().insert("svg:g") + .attr("class", "node nodegroup") + .classed("node_subflow",function(d) { return activeSubflow != null; }); + nodeEnter.each(function(d,i) { var node = d3.select(this); node.attr("id",d.id); @@ -1891,7 +1894,7 @@ RED.view = (function() { }) l.append("svg:path").attr("class","link_outline link_path"); l.append("svg:path").attr("class","link_line link_path") - .classed("link_subflow", function(d) { return activeSubflow && (d.source.type === "subflow" || d.target.type === "subflow") }); + .classed("link_subflow", function(d) { return activeSubflow }); }); link.exit().remove(); diff --git a/editor/sass/flow.scss b/editor/sass/flow.scss index d4bf110fe..cf56abee6 100644 --- a/editor/sass/flow.scss +++ b/editor/sass/flow.scss @@ -129,7 +129,6 @@ fill-opacity: 0.5; } - .node_error { stroke: #ff0000; stroke-width: 2; @@ -165,6 +164,10 @@ .node_hovered { } +.node_subflow .node { + stroke-dasharray:8, 3; +} + .node_status_label { @include disable-selection; stroke-width: 0;