Commit 28e677e6 authored by Kushal Pandya's avatar Kushal Pandya

Merge branch 'renovate/content-editor-packages' into 'master'

Update Content Editor Packages

See merge request gitlab-org/gitlab!75743
parents 9b1fc854 8e4d852e
...@@ -35,31 +35,33 @@ const trackInputRule = (contentType, inputRule) => { ...@@ -35,31 +35,33 @@ const trackInputRule = (contentType, inputRule) => {
}; };
const trackInputRulesAndShortcuts = (tiptapExtension) => { const trackInputRulesAndShortcuts = (tiptapExtension) => {
return tiptapExtension.extend({ return tiptapExtension
addKeyboardShortcuts() { .extend({
const shortcuts = this.parent?.() || {}; addKeyboardShortcuts() {
const { name } = this; const shortcuts = this.parent?.() || {};
/** const { name } = this;
* We don’t want to track keyboard shortcuts /**
* that are not deliberately executed to create * We don’t want to track keyboard shortcuts
* new types of content * that are not deliberately executed to create
*/ * new types of content
const dotNotTrackKeys = [ENTER_KEY, BACKSPACE_KEY]; */
const decorated = mapValues(shortcuts, (commandFn, shortcut) => const dotNotTrackKeys = [ENTER_KEY, BACKSPACE_KEY];
dotNotTrackKeys.includes(shortcut) const decorated = mapValues(shortcuts, (commandFn, shortcut) =>
? commandFn dotNotTrackKeys.includes(shortcut)
: trackKeyboardShortcut(name, commandFn, shortcut), ? commandFn
); : trackKeyboardShortcut(name, commandFn, shortcut),
);
return decorated; return decorated;
}, },
addInputRules() { addInputRules() {
const inputRules = this.parent?.() || []; const inputRules = this.parent?.() || [];
const { name } = this; const { name } = this;
return inputRules.map((inputRule) => trackInputRule(name, inputRule)); return inputRules.map((inputRule) => trackInputRule(name, inputRule));
}, },
}); })
.configure(tiptapExtension.options);
}; };
export default trackInputRulesAndShortcuts; export default trackInputRulesAndShortcuts;
...@@ -63,36 +63,36 @@ ...@@ -63,36 +63,36 @@
"@rails/ujs": "6.1.4-1", "@rails/ujs": "6.1.4-1",
"@sentry/browser": "5.30.0", "@sentry/browser": "5.30.0",
"@sourcegraph/code-host-integration": "0.0.60", "@sourcegraph/code-host-integration": "0.0.60",
"@tiptap/core": "^2.0.0-beta.143", "@tiptap/core": "^2.0.0-beta.160",
"@tiptap/extension-blockquote": "^2.0.0-beta.25", "@tiptap/extension-blockquote": "^2.0.0-beta.26",
"@tiptap/extension-bold": "^2.0.0-beta.24", "@tiptap/extension-bold": "^2.0.0-beta.25",
"@tiptap/extension-bullet-list": "^2.0.0-beta.23", "@tiptap/extension-bullet-list": "^2.0.0-beta.26",
"@tiptap/extension-code": "^2.0.0-beta.25", "@tiptap/extension-code": "^2.0.0-beta.26",
"@tiptap/extension-code-block-lowlight": "2.0.0-beta.57", "@tiptap/extension-code-block-lowlight": "2.0.0-beta.63",
"@tiptap/extension-document": "^2.0.0-beta.15", "@tiptap/extension-document": "^2.0.0-beta.15",
"@tiptap/extension-dropcursor": "^2.0.0-beta.25", "@tiptap/extension-dropcursor": "^2.0.0-beta.25",
"@tiptap/extension-gapcursor": "^2.0.0-beta.33", "@tiptap/extension-gapcursor": "^2.0.0-beta.34",
"@tiptap/extension-hard-break": "^2.0.0-beta.30", "@tiptap/extension-hard-break": "^2.0.0-beta.30",
"@tiptap/extension-heading": "^2.0.0-beta.23", "@tiptap/extension-heading": "^2.0.0-beta.24",
"@tiptap/extension-history": "^2.0.0-beta.21", "@tiptap/extension-history": "^2.0.0-beta.21",
"@tiptap/extension-horizontal-rule": "^2.0.0-beta.30", "@tiptap/extension-horizontal-rule": "^2.0.0-beta.30",
"@tiptap/extension-image": "^2.0.0-beta.24", "@tiptap/extension-image": "^2.0.0-beta.24",
"@tiptap/extension-italic": "^2.0.0-beta.24", "@tiptap/extension-italic": "^2.0.0-beta.25",
"@tiptap/extension-link": "^2.0.0-beta.28", "@tiptap/extension-link": "^2.0.0-beta.34",
"@tiptap/extension-list-item": "^2.0.0-beta.19", "@tiptap/extension-list-item": "^2.0.0-beta.20",
"@tiptap/extension-ordered-list": "^2.0.0-beta.24", "@tiptap/extension-ordered-list": "^2.0.0-beta.27",
"@tiptap/extension-paragraph": "^2.0.0-beta.22", "@tiptap/extension-paragraph": "^2.0.0-beta.23",
"@tiptap/extension-strike": "^2.0.0-beta.26", "@tiptap/extension-strike": "^2.0.0-beta.27",
"@tiptap/extension-subscript": "^2.0.0-beta.9", "@tiptap/extension-subscript": "^2.0.0-beta.10",
"@tiptap/extension-superscript": "^2.0.0-beta.9", "@tiptap/extension-superscript": "^2.0.0-beta.10",
"@tiptap/extension-table": "^2.0.0-beta.43", "@tiptap/extension-table": "^2.0.0-beta.46",
"@tiptap/extension-table-cell": "^2.0.0-beta.20", "@tiptap/extension-table-cell": "^2.0.0-beta.20",
"@tiptap/extension-table-header": "^2.0.0-beta.22", "@tiptap/extension-table-header": "^2.0.0-beta.22",
"@tiptap/extension-table-row": "^2.0.0-beta.19", "@tiptap/extension-table-row": "^2.0.0-beta.19",
"@tiptap/extension-task-item": "^2.0.0-beta.29", "@tiptap/extension-task-item": "^2.0.0-beta.30",
"@tiptap/extension-task-list": "^2.0.0-beta.23", "@tiptap/extension-task-list": "^2.0.0-beta.26",
"@tiptap/extension-text": "^2.0.0-beta.15", "@tiptap/extension-text": "^2.0.0-beta.15",
"@tiptap/vue-2": "^2.0.0-beta.69", "@tiptap/vue-2": "^2.0.0-beta.74",
"@toast-ui/editor": "^2.5.2", "@toast-ui/editor": "^2.5.2",
"@toast-ui/vue-editor": "^2.5.2", "@toast-ui/vue-editor": "^2.5.2",
"apollo-cache-inmemory": "^1.6.6", "apollo-cache-inmemory": "^1.6.6",
...@@ -162,11 +162,11 @@ ...@@ -162,11 +162,11 @@
"popper.js": "^1.16.1", "popper.js": "^1.16.1",
"portal-vue": "^2.1.7", "portal-vue": "^2.1.7",
"prismjs": "^1.21.0", "prismjs": "^1.21.0",
"prosemirror-markdown": "^1.6.0", "prosemirror-markdown": "1.6.0",
"prosemirror-model": "^1.15.0", "prosemirror-model": "^1.16.1",
"prosemirror-state": "^1.3.4", "prosemirror-state": "^1.3.4",
"prosemirror-tables": "^1.1.1", "prosemirror-tables": "^1.1.1",
"prosemirror-view": "^1.23.3", "prosemirror-view": "^1.23.5",
"raphael": "^2.2.7", "raphael": "^2.2.7",
"raw-loader": "^4.0.2", "raw-loader": "^4.0.2",
"scrollparent": "^2.0.1", "scrollparent": "^2.0.1",
......
...@@ -33,7 +33,7 @@ describe('content_editor/extensions/link', () => { ...@@ -33,7 +33,7 @@ describe('content_editor/extensions/link', () => {
${'documentation](readme.md'} | ${() => p('documentation](readme.md')} ${'documentation](readme.md'} | ${() => p('documentation](readme.md')}
${'http://example.com '} | ${() => p(link({ href: 'http://example.com' }, 'http://example.com'))} ${'http://example.com '} | ${() => p(link({ href: 'http://example.com' }, 'http://example.com'))}
${'https://example.com '} | ${() => p(link({ href: 'https://example.com' }, 'https://example.com'))} ${'https://example.com '} | ${() => p(link({ href: 'https://example.com' }, 'https://example.com'))}
${'www.example.com '} | ${() => p(link({ href: 'www.example.com' }, 'www.example.com'))} ${'www.example.com '} | ${() => p(link({ href: 'http://www.example.com' }, 'www.example.com'))}
${'example.com/ab.html '} | ${() => p('example.com/ab.html')} ${'example.com/ab.html '} | ${() => p('example.com/ab.html')}
${'https://www.google.com '} | ${() => p(link({ href: 'https://www.google.com' }, 'https://www.google.com'))} ${'https://www.google.com '} | ${() => p(link({ href: 'https://www.google.com' }, 'https://www.google.com'))}
`('with input=$input, then should insert a $insertedNode', ({ input, insertedNode }) => { `('with input=$input, then should insert a $insertedNode', ({ input, insertedNode }) => {
......
This diff is collapsed.
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