Welcome to mirror list, hosted at ThFree Co, Russian Federation.

footnotes_section.js « extensions « content_editor « javascripts « assets « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 914a89347348ccf7bcb1eb48242678c2cdf76308 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
import { mergeAttributes, Node } from '@tiptap/core';

export default Node.create({
  name: 'footnotesSection',

  content: 'footnoteDefinition+',

  group: 'block',

  isolating: true,

  parseHTML() {
    return [{ tag: 'section.footnotes > ol' }];
  },

  renderHTML({ HTMLAttributes }) {
    return ['ol', mergeAttributes(HTMLAttributes, { class: 'footnotes gl-font-sm' }), 0];
  },
});