summaryrefslogtreecommitdiff
path: root/app/assets/javascripts/behaviors/markdown/nodes/text.js
blob: 0dc77a12f5c8474df7c9f249e0184248a9a0caf1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/* eslint-disable class-methods-use-this */

import { Node } from 'tiptap';
import { defaultMarkdownSerializer } from '~/lib/prosemirror_markdown_serializer';

export default class Text extends Node {
  get name() {
    return 'text';
  }

  get schema() {
    return {
      group: 'inline',
    };
  }

  toMarkdown(state, node) {
    defaultMarkdownSerializer.nodes.text(state, node);
  }
}