zhangchao 4 years ago
parent
commit
81196bf8e1
1 changed files with 0 additions and 1 deletions
  1. 0
    1
      src/editor.html

+ 0
- 1
src/editor.html View File

1658
 			var contentIsEmpty = true;
1658
 			var contentIsEmpty = true;
1659
 			zss_editor.setOnChangeEmptyOrNot = function() {
1659
 			zss_editor.setOnChangeEmptyOrNot = function() {
1660
 				$('#zss_editor_content').on('input', function() {
1660
 				$('#zss_editor_content').on('input', function() {
1661
-					this.textContent = this.textContent || ''
1662
 					var textContentLength = this.textContent.trim().length - document.querySelectorAll(".caret_placeholder").length;
1661
 					var textContentLength = this.textContent.trim().length - document.querySelectorAll(".caret_placeholder").length;
1663
 					if (textContentLength < 1 && document.querySelectorAll('img, li').length === 0 && !contentIsEmpty) {
1662
 					if (textContentLength < 1 && document.querySelectorAll('img, li').length === 0 && !contentIsEmpty) {
1664
 						contentIsEmpty = true;
1663
 						contentIsEmpty = true;