diff --git a/packages/devextreme/js/__internal/ui/html_editor/m_html_editor.ts b/packages/devextreme/js/__internal/ui/html_editor/m_html_editor.ts index 30d5b3afd2dd..25ff7fd2ee7c 100644 --- a/packages/devextreme/js/__internal/ui/html_editor/m_html_editor.ts +++ b/packages/devextreme/js/__internal/ui/html_editor/m_html_editor.ts @@ -236,17 +236,17 @@ const HtmlEditor = Editor.inherit({ return sanitizedHtml; }, - _applyHtmlConverterFromHtml(value: string): string { - const result = isFunction(this._htmlConverter?.fromHtml) - ? String(this._htmlConverter.fromHtml(value)) + _applyHtmlConverterToHtml(value: string): string { + const result = isFunction(this._htmlConverter?.toHtml) + ? String(this._htmlConverter.toHtml(value)) : value; return result; }, - _applyHtmlConverterToHtml(value: string): string { - const result = isFunction(this._htmlConverter?.toHtml) - ? String(this._htmlConverter.toHtml(value)) + _applyHtmlConverterFromHtml(value: string): string { + const result = isFunction(this._htmlConverter?.fromHtml) + ? String(this._htmlConverter.fromHtml(value)) : value; return result;