Commit 20d6b853 authored by Jose Ivan Vargas's avatar Jose Ivan Vargas

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

Update Content Editor Packages

See merge request gitlab-org/gitlab!72867
parents 7174cbff fe10b7ed
......@@ -5,9 +5,11 @@ import { handleFileEvent } from '../services/upload_helpers';
export default Extension.create({
name: 'attachment',
defaultOptions: {
addOptions() {
return {
uploadsPath: null,
renderMarkdown: null,
};
},
addCommands() {
......
......@@ -2,8 +2,10 @@ import Playable from './playable';
export default Playable.extend({
name: 'audio',
defaultOptions: {
...Playable.options,
addOptions() {
return {
...this.parent?.(),
mediaType: 'audio',
};
},
});
......@@ -31,13 +31,12 @@ const attrs = {
export default marks.map((name) =>
Mark.create({
name,
inclusive: false,
defaultOptions: {
addOptions() {
return {
HTMLAttributes: {},
};
},
addAttributes() {
return (attrs[name] || []).reduce(
(acc, attr) => ({
......
......@@ -7,9 +7,11 @@ const resolveImageEl = (element) =>
element.nodeName === 'IMG' ? element : element.querySelector('img');
export default Image.extend({
defaultOptions: {
...Image.options,
addOptions() {
return {
...this.parent?.(),
inline: true,
};
},
addAttributes() {
return {
......
......@@ -3,8 +3,10 @@ import { Mark, markInputRule, mergeAttributes } from '@tiptap/core';
export default Mark.create({
name: 'inlineDiff',
defaultOptions: {
addOptions() {
return {
HTMLAttributes: {},
};
},
addAttributes() {
......
......@@ -18,10 +18,13 @@ export const extractHrefFromMarkdownLink = (match) => {
};
export default Link.extend({
defaultOptions: {
...Link.options,
addOptions() {
return {
...this.parent?.(),
openOnClick: false,
};
},
addInputRules() {
const markdownLinkSyntaxInputRuleRegExp = /(?:^|\s)\[([\w|\s|-]+)\]\((?<href>.+?)\)$/gm;
const urlSyntaxRegExp = /(?:^|\s)(?<href>(?:https?:\/\/|www\.)[\S]+)(?:\s|\n)$/gim;
......
......@@ -2,9 +2,11 @@ import { TaskItem } from '@tiptap/extension-task-item';
import { PARSE_HTML_PRIORITY_HIGHEST } from '../constants';
export default TaskItem.extend({
defaultOptions: {
addOptions() {
return {
nested: true,
HTMLAttributes: {},
};
},
addAttributes() {
......
......@@ -2,9 +2,11 @@ import Playable from './playable';
export default Playable.extend({
name: 'video',
defaultOptions: {
...Playable.options,
addOptions() {
return {
...this.parent?.(),
mediaType: 'video',
extraElementAttrs: { width: '400' },
};
},
});
......@@ -7,10 +7,12 @@ export default Node.create({
selectable: false,
atom: true,
defaultOptions: {
addOptions() {
return {
HTMLAttributes: {
class: 'gl-display-inline-flex gl-px-1 gl-bg-blue-100 gl-rounded-base gl-font-sm',
},
};
},
parseHTML() {
......
......@@ -63,36 +63,36 @@
"@rails/ujs": "6.1.4-1",
"@sentry/browser": "5.30.0",
"@sourcegraph/code-host-integration": "0.0.60",
"@tiptap/core": "^2.0.0-beta.125",
"@tiptap/extension-blockquote": "^2.0.0-beta.19",
"@tiptap/extension-bold": "^2.0.0-beta.19",
"@tiptap/extension-bullet-list": "^2.0.0-beta.18",
"@tiptap/extension-code": "^2.0.0-beta.20",
"@tiptap/extension-code-block-lowlight": "2.0.0-beta.47",
"@tiptap/extension-document": "^2.0.0-beta.13",
"@tiptap/extension-dropcursor": "^2.0.0-beta.19",
"@tiptap/extension-gapcursor": "^2.0.0-beta.27",
"@tiptap/extension-hard-break": "^2.0.0-beta.24",
"@tiptap/extension-heading": "^2.0.0-beta.18",
"@tiptap/extension-history": "^2.0.0-beta.16",
"@tiptap/extension-horizontal-rule": "^2.0.0-beta.24",
"@tiptap/extension-image": "^2.0.0-beta.19",
"@tiptap/extension-italic": "^2.0.0-beta.19",
"@tiptap/extension-link": "^2.0.0-beta.23",
"@tiptap/extension-list-item": "^2.0.0-beta.14",
"@tiptap/extension-ordered-list": "^2.0.0-beta.19",
"@tiptap/extension-paragraph": "^2.0.0-beta.17",
"@tiptap/extension-strike": "^2.0.0-beta.21",
"@tiptap/extension-subscript": "^2.0.0-beta.4",
"@tiptap/extension-superscript": "^2.0.0-beta.4",
"@tiptap/extension-table": "^2.0.0-beta.34",
"@tiptap/extension-table-cell": "^2.0.0-beta.15",
"@tiptap/extension-table-header": "^2.0.0-beta.17",
"@tiptap/extension-table-row": "^2.0.0-beta.14",
"@tiptap/extension-task-item": "^2.0.0-beta.21",
"@tiptap/extension-task-list": "^2.0.0-beta.18",
"@tiptap/extension-text": "^2.0.0-beta.13",
"@tiptap/vue-2": "^2.0.0-beta.60",
"@tiptap/core": "^2.0.0-beta.138",
"@tiptap/extension-blockquote": "^2.0.0-beta.24",
"@tiptap/extension-bold": "^2.0.0-beta.24",
"@tiptap/extension-bullet-list": "^2.0.0-beta.23",
"@tiptap/extension-code": "^2.0.0-beta.25",
"@tiptap/extension-code-block-lowlight": "2.0.0-beta.55",
"@tiptap/extension-document": "^2.0.0-beta.15",
"@tiptap/extension-dropcursor": "^2.0.0-beta.24",
"@tiptap/extension-gapcursor": "^2.0.0-beta.33",
"@tiptap/extension-hard-break": "^2.0.0-beta.30",
"@tiptap/extension-heading": "^2.0.0-beta.23",
"@tiptap/extension-history": "^2.0.0-beta.21",
"@tiptap/extension-horizontal-rule": "^2.0.0-beta.30",
"@tiptap/extension-image": "^2.0.0-beta.24",
"@tiptap/extension-italic": "^2.0.0-beta.24",
"@tiptap/extension-link": "^2.0.0-beta.28",
"@tiptap/extension-list-item": "^2.0.0-beta.19",
"@tiptap/extension-ordered-list": "^2.0.0-beta.24",
"@tiptap/extension-paragraph": "^2.0.0-beta.22",
"@tiptap/extension-strike": "^2.0.0-beta.26",
"@tiptap/extension-subscript": "^2.0.0-beta.9",
"@tiptap/extension-superscript": "^2.0.0-beta.9",
"@tiptap/extension-table": "^2.0.0-beta.42",
"@tiptap/extension-table-cell": "^2.0.0-beta.20",
"@tiptap/extension-table-header": "^2.0.0-beta.22",
"@tiptap/extension-table-row": "^2.0.0-beta.19",
"@tiptap/extension-task-item": "^2.0.0-beta.28",
"@tiptap/extension-task-list": "^2.0.0-beta.23",
"@tiptap/extension-text": "^2.0.0-beta.15",
"@tiptap/vue-2": "^2.0.0-beta.68",
"@toast-ui/editor": "^2.5.2",
"@toast-ui/vue-editor": "^2.5.2",
"apollo-cache-inmemory": "^1.6.6",
......@@ -162,10 +162,10 @@
"portal-vue": "^2.1.7",
"prismjs": "^1.21.0",
"prosemirror-markdown": "^1.6.0",
"prosemirror-model": "^1.14.3",
"prosemirror-model": "^1.15.0",
"prosemirror-state": "^1.3.4",
"prosemirror-tables": "^1.1.1",
"prosemirror-view": "^1.20.3",
"prosemirror-view": "^1.23.1",
"raphael": "^2.2.7",
"raw-loader": "^4.0.2",
"scrollparent": "^2.0.1",
......
......@@ -28,7 +28,6 @@ import TableHeader from '~/content_editor/extensions/table_header';
import TableRow from '~/content_editor/extensions/table_row';
import TaskItem from '~/content_editor/extensions/task_item';
import TaskList from '~/content_editor/extensions/task_list';
import Text from '~/content_editor/extensions/text';
import markdownSerializer from '~/content_editor/services/markdown_serializer';
import { createTestEditor, createDocBuilder } from '../test_utils';
......@@ -58,7 +57,6 @@ const tiptapEditor = createTestEditor({
Link,
ListItem,
OrderedList,
Paragraph,
Strike,
Table,
TableCell,
......@@ -66,7 +64,6 @@ const tiptapEditor = createTestEditor({
TableRow,
TaskItem,
TaskList,
Text,
],
});
......
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