Commit 150bc6da authored by Enrique Alcantara's avatar Enrique Alcantara

Do not apply markdown styles to top toolbar

parent fa424e62
...@@ -17,8 +17,8 @@ export default { ...@@ -17,8 +17,8 @@ export default {
}; };
</script> </script>
<template> <template>
<div class="md md-area" :class="{ 'is-focused': contentEditor.tiptapEditor.isFocused }"> <div class="md-area" :class="{ 'is-focused': contentEditor.tiptapEditor.isFocused }">
<top-toolbar class="gl-mb-4" :content-editor="contentEditor" /> <top-toolbar class="gl-mb-4" :content-editor="contentEditor" />
<tiptap-editor-content :editor="contentEditor.tiptapEditor" /> <tiptap-editor-content class="md" :editor="contentEditor.tiptapEditor" />
</div> </div>
</template> </template>
...@@ -27,7 +27,10 @@ describe('ContentEditor', () => { ...@@ -27,7 +27,10 @@ describe('ContentEditor', () => {
it('renders editor content component and attaches editor instance', () => { it('renders editor content component and attaches editor instance', () => {
createWrapper(editor); createWrapper(editor);
expect(wrapper.findComponent(EditorContent).props().editor).toBe(editor.tiptapEditor); const editorContent = wrapper.findComponent(EditorContent);
expect(editorContent.props().editor).toBe(editor.tiptapEditor);
expect(editorContent.classes()).toContain('md');
}); });
it('renders top toolbar component and attaches editor instance', () => { it('renders top toolbar component and attaches editor instance', () => {
...@@ -38,8 +41,8 @@ describe('ContentEditor', () => { ...@@ -38,8 +41,8 @@ describe('ContentEditor', () => {
it.each` it.each`
isFocused | classes isFocused | classes
${true} | ${['md', 'md-area', 'is-focused']} ${true} | ${['md-area', 'is-focused']}
${false} | ${['md', 'md-area']} ${false} | ${['md-area']}
`( `(
'has $classes class selectors when tiptapEditor.isFocused = $isFocused', 'has $classes class selectors when tiptapEditor.isFocused = $isFocused',
({ isFocused, classes }) => { ({ isFocused, classes }) => {
......
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