THIS IS A TEST INSTANCE ONLY! REPOSITORIES CAN BE DELETED AT ANY TIME!

Browse Source

issue: Fix the bug of missing new line highlight in email noti

pull/360/head
Mijeong Park 2 years ago
parent
commit
7527fae410
2 changed files with 4 additions and 4 deletions
  1. +1
    -1
      app/utils/DiffUtil.java
  2. +3
    -3
      test/utils/DiffUtilTest.java

+ 1
- 1
app/utils/DiffUtil.java View File

@ -57,7 +57,7 @@ public class DiffUtil {
}
}
return sb.toString().replaceAll("\n", "<br/>\n");
return sb.toString().replaceAll("\n", "&amp;nbsp&lt;br/>\n");
}
public static String getDiffPlainText(String oldValue, String newValue) {

+ 3
- 3
test/utils/DiffUtilTest.java View File

@ -17,9 +17,9 @@ public class DiffUtilTest {
String DIFF_INSERT_PREFIX = "<span style='background-color: #abdd52;padding: 2px 0;'>";
String DIFF_INSERT_POSTFIX = "</span>";
String DIFF_EQUAL_PREFIX = "<span style='color: #bdbdbd;font-size: 16px;font-family: serif;'>...<br/>\n"
+ "......<br/>\n"
+ "......<br/>\n"
String DIFF_EQUAL_PREFIX = "<span style='color: #bdbdbd;font-size: 16px;font-family: serif;'>...&amp;nbsp&lt;br/>\n"
+ "......&amp;nbsp&lt;br/>\n"
+ "......&amp;nbsp&lt;br/>\n"
+ "...</span>";
String DIFF_NEW_LINE = "\n";

Loading…
Cancel
Save