Permalink
Browse files

Close issue #3 by removing the regular expression that tried to inser…

…t newlines into description labels on transformation boxes
  • Loading branch information...
1 parent 040f849 commit 2dbc595c8a022519259a2dad7e8d6b592da3064b @tamc committed May 30, 2012
Showing with 2 additions and 10 deletions.
  1. +1 −7 js/sankey.js
  2. +1 −3 src/sankey.coffee
View
@@ -500,13 +500,7 @@
return this.sankey.convert_box_value_labels_callback(this.flow());
};
TransformationBox.prototype.descriptionLabelText = function() {
- if (this.is_left_box()) {
- return this.label_text;
- }
- if (this.is_right_box()) {
- return this.label_text;
- }
- return this.label_text.replace(/[^a-zA-Z0-9]/, "\n");
+ return this.label_text;
};
TransformationBox.prototype.labelPositionX = function() {
if (this.is_left_box()) {
View
@@ -367,9 +367,7 @@ class TransformationBox
@sankey.convert_box_value_labels_callback(@flow())
descriptionLabelText: () ->
- return @label_text if @is_left_box()
- return @label_text if @is_right_box()
- @label_text.replace(/[^a-zA-Z0-9]/,"\n")
+ @label_text
labelPositionX: () ->
return @x-3.0 if @is_left_box()

0 comments on commit 2dbc595

Please sign in to comment.