Skip to content

Commit ad1ebb5

Browse files
nicolaskruchtenVeraZab
authored andcommitted
fix annoying newline space
1 parent ade3679 commit ad1ebb5

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • src/components/widgets/text_editors/RichText

src/components/widgets/text_editors/RichText/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ class RichText extends Component {
188188

189189
// Dispatch changes to plotly.js
190190
// TODO consider moving to render (plotly.js is a render target)
191-
const htmlContent = this.getEditorStateAsHTML(editorState);
191+
const htmlContent = this.getEditorStateAsHTML(editorState).replace(/<br>\n*/, '<br>');
192192
if (this.props.value !== htmlContent) {
193193
debounce(this.props.onChange, [htmlContent]);
194194
}

0 commit comments

Comments
 (0)