Commit e19921ac authored by Enrique Alcantara's avatar Enrique Alcantara

Support hard breaks in content editor

parent 49da2048
...@@ -12,6 +12,7 @@ import { ...@@ -12,6 +12,7 @@ import {
BulletList, BulletList,
OrderedList, OrderedList,
ListItem, ListItem,
HardBreak,
} from 'tiptap-extensions'; } from 'tiptap-extensions';
import { PROVIDE_SERIALIZER_OR_RENDERER_ERROR } from '../constants'; import { PROVIDE_SERIALIZER_OR_RENDERER_ERROR } from '../constants';
import CodeBlockHighlight from '../extensions/code_block_highlight'; import CodeBlockHighlight from '../extensions/code_block_highlight';
...@@ -36,6 +37,7 @@ const createEditor = async ({ content, renderMarkdown, serializer: customSeriali ...@@ -36,6 +37,7 @@ const createEditor = async ({ content, renderMarkdown, serializer: customSeriali
new ListItem(), new ListItem(),
new OrderedList(), new OrderedList(),
new CodeBlockHighlight(), new CodeBlockHighlight(),
new HardBreak(),
], ],
editorProps: { editorProps: {
attributes: { attributes: {
......
...@@ -48,3 +48,7 @@ ...@@ -48,3 +48,7 @@
3. list item 3 3. list item 3
- name: image - name: image
markdown: '![alt text](https://gitlab.com/logo.png)' markdown: '![alt text](https://gitlab.com/logo.png)'
- name: hard_break
markdown: |-
This is a line after a\
hard break
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment