You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: vaadin-rich-text-editor-flow-parent/vaadin-rich-text-editor-flow/src/main/java/com/vaadin/flow/component/richtexteditor/RichTextEditor.java
+39-7Lines changed: 39 additions & 7 deletions
Original file line number
Diff line number
Diff line change
@@ -169,6 +169,18 @@ public void setValueChangeMode(ValueChangeMode valueChangeMode) {
169
169
* <p>
170
170
* Note: {@link Binder} will take care of the {@code null} conversion when
171
171
* integrates with the editor, as long as no new converter is defined.
172
+
* <p>
173
+
* Since v24, this method only accepts values in the HTML format, whereas in
174
+
* v23 and earlier this method would accept values in the Delta format. In
175
+
* order to prevent data corruption, passing a value that starts with either
176
+
* <code>[</code> or <code>{</code> will now throw an
177
+
* {@link IllegalArgumentException}, as it might indicate that the value is
178
+
* in the Delta format. In order to keep using the Delta format, use
179
+
* {@link #asDelta()}, which allows setting, retrieving, and binding the
180
+
* value using Binder, in the Delta format. In order to pass an HTML value
181
+
* starting with either characters, either wrap the value in a valid HTML
182
+
* tag, such as <code><p></code>, or use {@link #asHtml()} which does
183
+
* not include this check.
172
184
*
173
185
* @see #asDelta()
174
186
* @see AsDelta#setValue(String)
@@ -177,10 +189,27 @@ public void setValueChangeMode(ValueChangeMode valueChangeMode) {
Copy file name to clipboardExpand all lines: vaadin-rich-text-editor-flow-parent/vaadin-rich-text-editor-flow/src/test/java/com/vaadin/flow/component/richtexteditor/RichTextEditorTest.java
+33Lines changed: 33 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -59,6 +59,26 @@ public void initialAsDeltaValue() {
0 commit comments