Skip to content

Commit

Permalink
Merge pull request #5149 from nextcloud/backport/5148/stable28
Browse files Browse the repository at this point in the history
[stable28] fix(gapcursor): Don't allow gap cursor in tables
  • Loading branch information
juliushaertl committed Dec 21, 2023
2 parents 0fa957d + 5e3cdab commit 03ff5b1
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/nodes/Table/TableCaption.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import { Node } from '@tiptap/core'
export default Node.create({
name: 'tableCaption',
content: 'inline*',
allowGapCursor: false,
addAttributes() {
return {}
},
Expand Down
1 change: 1 addition & 0 deletions src/nodes/Table/TableHeadRow.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import TableRow from './TableRow.js'
export default TableRow.extend({
name: 'tableHeadRow',
content: 'tableHeader*',
allowGapCursor: false,

toMarkdown(state, node) {
state.write('|')
Expand Down
1 change: 1 addition & 0 deletions src/nodes/Table/TableRow.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { TableRow } from '@tiptap/extension-table-row'

export default TableRow.extend({
content: 'tableCell*',
allowGapCursor: false,

toMarkdown(state, node) {
state.write('|')
Expand Down

0 comments on commit 03ff5b1

Please sign in to comment.