@manuscripts/body-editor 2.2.5-LEAN-4013.0 → 2.2.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -15,7 +15,7 @@
15
15
  * limitations under the License.
16
16
  */
17
17
  Object.defineProperty(exports, "__esModule", { value: true });
18
- exports.autoComplete = exports.mergeCellsWithSpace = exports.addColumns = exports.addRows = exports.insertTableFootnote = exports.addInlineComment = exports.addNodeComment = exports.createAndFillTableElement = exports.selectAllIsolating = exports.ignoreAtomBlockNodeForward = exports.isAtEndOfTextBlock = exports.ignoreMetaNodeBackspaceCommand = exports.ignoreAtomBlockNodeBackward = exports.isTextSelection = exports.isAtStartOfTextBlock = exports.insertTOCSection = exports.insertBibliographySection = exports.insertList = exports.insertKeywords = exports.insertContributors = exports.insertAbstract = exports.insertBackMatterSection = exports.insertSection = exports.insertGraphicalAbstract = exports.insertInlineFootnote = exports.insertFootnote = exports.createFootnote = exports.insertInlineEquation = exports.insertCrossReference = exports.insertInlineCitation = exports.insertLink = exports.insertSectionLabel = exports.findPosBeforeFirstSubsection = exports.insertBreak = exports.deleteBlock = exports.insertBlock = exports.insertSupplement = exports.insertTable = exports.insertFigure = exports.insertGeneralFootnote = exports.undoFootnoteDelete = exports.createBlock = exports.createSelection = exports.canInsert = exports.blockActive = exports.isNodeSelection = exports.markActive = void 0;
18
+ exports.autoComplete = exports.mergeCellsWithSpace = exports.addColumns = exports.addRows = exports.insertTableFootnote = exports.addInlineComment = exports.addNodeComment = exports.createAndFillTableElement = exports.selectAllIsolating = exports.ignoreAtomBlockNodeForward = exports.isAtEndOfTextBlock = exports.ignoreMetaNodeBackspaceCommand = exports.ignoreAtomBlockNodeBackward = exports.isTextSelection = exports.isAtStartOfTextBlock = exports.insertTOCSection = exports.insertBibliographySection = exports.insertList = exports.insertKeywords = exports.insertContributors = exports.insertAbstract = exports.insertBackMatterSection = exports.insertSection = exports.insertGraphicalAbstract = exports.insertInlineFootnote = exports.insertFootnote = exports.createFootnote = exports.insertInlineEquation = exports.insertCrossReference = exports.insertInlineCitation = exports.insertLink = exports.insertSectionLabel = exports.findPosBeforeFirstSubsection = exports.insertBreak = exports.deleteBlock = exports.insertBlock = exports.insertSupplement = exports.insertTable = exports.insertFigure = exports.insertGeneralFootnote = exports.undoFootnoteDelete = exports.createBlock = exports.createSelection = exports.canInsert = exports.blockActive = exports.isNodeSelection = exports.markActive = exports.addToStart = void 0;
19
19
  const json_schema_1 = require("@manuscripts/json-schema");
20
20
  const track_changes_plugin_1 = require("@manuscripts/track-changes-plugin");
21
21
  const transform_1 = require("@manuscripts/transform");
@@ -36,6 +36,28 @@ const comments_2 = require("./plugins/comments");
36
36
  const editor_props_1 = require("./plugins/editor-props");
37
37
  const footnotes_2 = require("./plugins/footnotes");
38
38
  const autocompletion_1 = require("./plugins/section_title/autocompletion");
39
+ const addToStart = (state, dispatch) => {
40
+ const { selection } = state;
41
+ if (!dispatch ||
42
+ !(selection instanceof prosemirror_state_1.TextSelection) ||
43
+ selection.$from.node().type !== transform_1.schema.nodes.paragraph) {
44
+ return false;
45
+ }
46
+ const { $anchor: { parentOffset: startOffset }, $head: { parentOffset: endOffset }, $from, $to, } = selection;
47
+ const parentSize = $from.node().content.size;
48
+ if ((startOffset === 0 && endOffset === 0) ||
49
+ startOffset === parentSize ||
50
+ endOffset === parentSize) {
51
+ const side = (!$from.parentOffset && $to.index() < $to.parent.childCount ? $from : $to)
52
+ .pos - (startOffset === 0 ? 1 : 0);
53
+ const tr = state.tr.insert(side, $from.node().type.createAndFill());
54
+ tr.setSelection(prosemirror_state_1.TextSelection.create(tr.doc, side + 1));
55
+ dispatch(tr.scrollIntoView());
56
+ return true;
57
+ }
58
+ return false;
59
+ };
60
+ exports.addToStart = addToStart;
39
61
  const markActive = (type) => (state) => {
40
62
  const { from, $from, to, empty } = state.selection;
41
63
  return empty
@@ -39,7 +39,7 @@ const customKeymap = {
39
39
  'Mod-Alt-=': (0, prosemirror_commands_1.toggleMark)(transform_1.schema.marks.superscript),
40
40
  'Mod-Alt--': (0, prosemirror_commands_1.toggleMark)(transform_1.schema.marks.subscript),
41
41
  'Ctrl->': (0, prosemirror_commands_1.wrapIn)(transform_1.schema.nodes.blockquote),
42
- Enter: (0, prosemirror_commands_1.chainCommands)(commands_1.autoComplete, prosemirror_commands_1.newlineInCode, prosemirror_commands_1.createParagraphNear, prosemirror_commands_1.liftEmptyBlock, prosemirror_commands_1.splitBlock),
42
+ Enter: (0, prosemirror_commands_1.chainCommands)(commands_1.autoComplete, commands_1.addToStart, prosemirror_commands_1.newlineInCode, prosemirror_commands_1.createParagraphNear, prosemirror_commands_1.liftEmptyBlock, prosemirror_commands_1.splitBlock),
43
43
  'Shift-Mod-Enter': (0, commands_1.insertSection)(true),
44
44
  'Mod-Enter': (0, prosemirror_commands_1.chainCommands)(prosemirror_commands_1.exitCode, (0, commands_1.insertSection)()),
45
45
  'Shift-Enter': (0, prosemirror_commands_1.chainCommands)(prosemirror_commands_1.exitCode, commands_1.insertBreak),
@@ -53,7 +53,9 @@ const handlePaste = (view, event, slice) => {
53
53
  if (event.type !== 'paste') {
54
54
  return false;
55
55
  }
56
- const { state: { tr }, dispatch, } = view;
56
+ const { state: { tr, selection }, dispatch, } = view;
57
+ tr.setMeta('uiEvent', 'paste');
58
+ tr.setMeta('paste', true);
57
59
  const parent = (0, prosemirror_utils_1.findParentNode)((node) => node.type === transform_1.schema.nodes.section)(tr.selection);
58
60
  if (((_a = slice.content.firstChild) === null || _a === void 0 ? void 0 : _a.type) === transform_1.schema.nodes.section && parent) {
59
61
  const $pos = tr.doc.resolve(parent.start);
@@ -62,6 +64,17 @@ const handlePaste = (view, event, slice) => {
62
64
  dispatch(tr.setSelection(prosemirror_state_1.TextSelection.create(tr.doc, insertPos)).scrollIntoView());
63
65
  return true;
64
66
  }
67
+ if (selection instanceof prosemirror_state_1.TextSelection &&
68
+ selection.$anchor.parentOffset === 0 &&
69
+ selection.$head.parentOffset === 0 &&
70
+ selection.$from.node().type === transform_1.schema.nodes.paragraph) {
71
+ const { $from, $to } = selection;
72
+ const side = (!$from.parentOffset && $to.index() < $to.parent.childCount ? $from : $to)
73
+ .pos - 1;
74
+ tr.insert(side, slice.content);
75
+ dispatch(tr.setSelection(prosemirror_state_1.TextSelection.create(tr.doc, side + 1)).scrollIntoView());
76
+ return true;
77
+ }
65
78
  return false;
66
79
  };
67
80
  exports.handlePaste = handlePaste;
@@ -60,11 +60,23 @@ const deleteFootnoteWidget = (node, props, id, tableElement, tableElementFooter)
60
60
  if (node.type === transform_1.schema.nodes.footnote && pos) {
61
61
  const targetNode = tableElement ? tableElement.node : view.state.doc;
62
62
  const inlineFootnotes = (0, footnotes_1.getInlineFootnotes)(id, targetNode);
63
- const footnote = (0, prosemirror_utils_1.findParentNodeClosestToPos)(tr.doc.resolve(pos), (node) => node.type === transform_1.schema.nodes.footnote);
64
- if (footnote) {
65
- const { pos: fnPos, node: fnNode } = footnote;
63
+ const footnotesElement = (0, prosemirror_utils_1.findParentNodeClosestToPos)(tr.doc.resolve(pos), (node) => node.type === transform_1.schema.nodes.footnotes_element);
64
+ if ((footnotesElement === null || footnotesElement === void 0 ? void 0 : footnotesElement.node.childCount) === 1 &&
65
+ (tableElementFooter === null || tableElementFooter === void 0 ? void 0 : tableElementFooter.node.childCount) === 1) {
66
+ const { pos: fnPos, node: fnNode } = tableElementFooter;
66
67
  tr.delete(fnPos, fnPos + fnNode.nodeSize + 1);
67
68
  }
69
+ else if ((footnotesElement === null || footnotesElement === void 0 ? void 0 : footnotesElement.node.childCount) === 1) {
70
+ const { pos: fnPos, node: fnNode } = footnotesElement;
71
+ tr.delete(fnPos, fnPos + fnNode.nodeSize + 1);
72
+ }
73
+ else {
74
+ const footnote = (0, prosemirror_utils_1.findParentNodeClosestToPos)(tr.doc.resolve(pos), (node) => node.type === transform_1.schema.nodes.footnote);
75
+ if (footnote) {
76
+ const { pos: fnPos, node: fnNode } = footnote;
77
+ tr.delete(fnPos, fnPos + fnNode.nodeSize + 1);
78
+ }
79
+ }
68
80
  if (inlineFootnotes) {
69
81
  inlineFootnotes.forEach((footnote) => {
70
82
  const pos = footnote.pos + (tableElement ? tableElement.pos + 1 : 0);
@@ -79,24 +91,6 @@ const deleteFootnoteWidget = (node, props, id, tableElement, tableElementFooter)
79
91
  }
80
92
  }
81
93
  view.dispatch(tr);
82
- if (pos) {
83
- const footnotesElement = (0, prosemirror_utils_1.findParentNodeClosestToPos)(view.state.doc.resolve(pos), (node) => node.type === transform_1.schema.nodes.footnotes_element);
84
- if (footnotesElement) {
85
- let allFootnotesDeleted = true;
86
- footnotesElement.node.descendants((child) => {
87
- if (child.type === transform_1.schema.nodes.footnote && !(0, track_changes_utils_1.isDeleted)(child)) {
88
- allFootnotesDeleted = false;
89
- return false;
90
- }
91
- });
92
- if (allFootnotesDeleted) {
93
- const { pos: fnPos, node: fnNode } = footnotesElement;
94
- const tr2 = view.state.tr;
95
- tr2.delete(fnPos, fnPos + fnNode.nodeSize + 1);
96
- view.dispatch(tr2);
97
- }
98
- }
99
- }
100
94
  };
101
95
  const componentProps = {
102
96
  footnoteType: footnote.type,
@@ -43,10 +43,12 @@ const buildPluginState = (state) => {
43
43
  }
44
44
  };
45
45
  const getEffectiveSelection = ($pos) => {
46
+ var _a;
46
47
  let current;
47
48
  for (let depth = $pos.depth; depth > 0; depth--) {
48
49
  const node = $pos.node(depth);
49
- if (node.attrs.dataTracked) {
50
+ if (node.attrs.dataTracked &&
51
+ !((_a = node.attrs.dataTracked) === null || _a === void 0 ? void 0 : _a.find((c) => c.operation === 'reference'))) {
50
52
  current = {
51
53
  node,
52
54
  from: $pos.before(depth),
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.MATHJAX_VERSION = exports.VERSION = void 0;
4
- exports.VERSION = '2.2.5-LEAN-4013.0';
4
+ exports.VERSION = '2.2.6';
5
5
  exports.MATHJAX_VERSION = '3.2.2';
@@ -49,12 +49,12 @@ class BlockView extends base_node_view_1.BaseNodeView {
49
49
  this.contentDOM.classList.toggle('empty-node', !this.node.childCount);
50
50
  };
51
51
  this.updateAttributes = () => {
52
- var _a;
53
52
  if (!this.contentDOM) {
54
53
  return;
55
54
  }
56
- if ((_a = this.node.attrs.dataTracked) === null || _a === void 0 ? void 0 : _a.length) {
57
- const lastChange = this.node.attrs.dataTracked[this.node.attrs.dataTracked.length - 1];
55
+ const dataTracked = (this.node.attrs.dataTracked || []).filter((attr) => attr.operation !== 'reference');
56
+ if (dataTracked === null || dataTracked === void 0 ? void 0 : dataTracked.length) {
57
+ const lastChange = dataTracked[dataTracked.length - 1];
58
58
  this.dom.setAttribute('data-track-status', lastChange.status);
59
59
  this.dom.setAttribute('data-track-op', lastChange.operation);
60
60
  }
@@ -33,6 +33,27 @@ import { setCommentSelection } from './plugins/comments';
33
33
  import { getEditorProps } from './plugins/editor-props';
34
34
  import { footnotesKey } from './plugins/footnotes';
35
35
  import { checkForCompletion } from './plugins/section_title/autocompletion';
36
+ export const addToStart = (state, dispatch) => {
37
+ const { selection } = state;
38
+ if (!dispatch ||
39
+ !(selection instanceof TextSelection) ||
40
+ selection.$from.node().type !== schema.nodes.paragraph) {
41
+ return false;
42
+ }
43
+ const { $anchor: { parentOffset: startOffset }, $head: { parentOffset: endOffset }, $from, $to, } = selection;
44
+ const parentSize = $from.node().content.size;
45
+ if ((startOffset === 0 && endOffset === 0) ||
46
+ startOffset === parentSize ||
47
+ endOffset === parentSize) {
48
+ const side = (!$from.parentOffset && $to.index() < $to.parent.childCount ? $from : $to)
49
+ .pos - (startOffset === 0 ? 1 : 0);
50
+ const tr = state.tr.insert(side, $from.node().type.createAndFill());
51
+ tr.setSelection(TextSelection.create(tr.doc, side + 1));
52
+ dispatch(tr.scrollIntoView());
53
+ return true;
54
+ }
55
+ return false;
56
+ };
36
57
  export const markActive = (type) => (state) => {
37
58
  const { from, $from, to, empty } = state.selection;
38
59
  return empty
@@ -18,7 +18,7 @@ import { chainCommands, createParagraphNear, exitCode, joinDown, joinUp, lift, l
18
18
  import { redo, undo } from 'prosemirror-history';
19
19
  import { undoInputRule } from 'prosemirror-inputrules';
20
20
  import { goToNextCell } from 'prosemirror-tables';
21
- import { autoComplete, ignoreAtomBlockNodeBackward, ignoreAtomBlockNodeForward, ignoreMetaNodeBackspaceCommand, insertBlock, insertBreak, insertCrossReference, insertInlineCitation, insertInlineEquation, insertSection, selectAllIsolating, } from '../commands';
21
+ import { autoComplete, addToStart, ignoreAtomBlockNodeBackward, ignoreAtomBlockNodeForward, ignoreMetaNodeBackspaceCommand, insertBlock, insertBreak, insertCrossReference, insertInlineCitation, insertInlineEquation, insertSection, selectAllIsolating, } from '../commands';
22
22
  const customKeymap = {
23
23
  Backspace: chainCommands(undoInputRule, ignoreAtomBlockNodeBackward, ignoreMetaNodeBackspaceCommand),
24
24
  Delete: ignoreAtomBlockNodeForward,
@@ -37,7 +37,7 @@ const customKeymap = {
37
37
  'Mod-Alt-=': toggleMark(schema.marks.superscript),
38
38
  'Mod-Alt--': toggleMark(schema.marks.subscript),
39
39
  'Ctrl->': wrapIn(schema.nodes.blockquote),
40
- Enter: chainCommands(autoComplete, newlineInCode, createParagraphNear, liftEmptyBlock, splitBlock),
40
+ Enter: chainCommands(autoComplete, addToStart, newlineInCode, createParagraphNear, liftEmptyBlock, splitBlock),
41
41
  'Shift-Mod-Enter': insertSection(true),
42
42
  'Mod-Enter': chainCommands(exitCode, insertSection()),
43
43
  'Shift-Enter': chainCommands(exitCode, insertBreak),
@@ -49,7 +49,9 @@ export const handlePaste = (view, event, slice) => {
49
49
  if (event.type !== 'paste') {
50
50
  return false;
51
51
  }
52
- const { state: { tr }, dispatch, } = view;
52
+ const { state: { tr, selection }, dispatch, } = view;
53
+ tr.setMeta('uiEvent', 'paste');
54
+ tr.setMeta('paste', true);
53
55
  const parent = findParentNode((node) => node.type === schema.nodes.section)(tr.selection);
54
56
  if (((_a = slice.content.firstChild) === null || _a === void 0 ? void 0 : _a.type) === schema.nodes.section && parent) {
55
57
  const $pos = tr.doc.resolve(parent.start);
@@ -58,5 +60,16 @@ export const handlePaste = (view, event, slice) => {
58
60
  dispatch(tr.setSelection(TextSelection.create(tr.doc, insertPos)).scrollIntoView());
59
61
  return true;
60
62
  }
63
+ if (selection instanceof TextSelection &&
64
+ selection.$anchor.parentOffset === 0 &&
65
+ selection.$head.parentOffset === 0 &&
66
+ selection.$from.node().type === schema.nodes.paragraph) {
67
+ const { $from, $to } = selection;
68
+ const side = (!$from.parentOffset && $to.index() < $to.parent.childCount ? $from : $to)
69
+ .pos - 1;
70
+ tr.insert(side, slice.content);
71
+ dispatch(tr.setSelection(TextSelection.create(tr.doc, side + 1)).scrollIntoView());
72
+ return true;
73
+ }
61
74
  return false;
62
75
  };
@@ -21,7 +21,7 @@ import { createElement } from 'react';
21
21
  import { renderToStaticMarkup } from 'react-dom/server';
22
22
  import { DeleteFootnoteDialog, } from '../../components/views/DeleteFootnoteDialog';
23
23
  import { getInlineFootnotes } from '../../lib/footnotes';
24
- import { getActualAttrs, isDeleted } from '../../lib/track-changes-utils';
24
+ import { getActualAttrs } from '../../lib/track-changes-utils';
25
25
  import { getChildOfType } from '../../lib/utils';
26
26
  import ReactSubView from '../../views/ReactSubView';
27
27
  export const deleteFootnoteWidget = (node, props, id, tableElement, tableElementFooter) => (view, getPos) => {
@@ -54,11 +54,23 @@ export const deleteFootnoteWidget = (node, props, id, tableElement, tableElement
54
54
  if (node.type === schema.nodes.footnote && pos) {
55
55
  const targetNode = tableElement ? tableElement.node : view.state.doc;
56
56
  const inlineFootnotes = getInlineFootnotes(id, targetNode);
57
- const footnote = findParentNodeClosestToPos(tr.doc.resolve(pos), (node) => node.type === schema.nodes.footnote);
58
- if (footnote) {
59
- const { pos: fnPos, node: fnNode } = footnote;
57
+ const footnotesElement = findParentNodeClosestToPos(tr.doc.resolve(pos), (node) => node.type === schema.nodes.footnotes_element);
58
+ if ((footnotesElement === null || footnotesElement === void 0 ? void 0 : footnotesElement.node.childCount) === 1 &&
59
+ (tableElementFooter === null || tableElementFooter === void 0 ? void 0 : tableElementFooter.node.childCount) === 1) {
60
+ const { pos: fnPos, node: fnNode } = tableElementFooter;
60
61
  tr.delete(fnPos, fnPos + fnNode.nodeSize + 1);
61
62
  }
63
+ else if ((footnotesElement === null || footnotesElement === void 0 ? void 0 : footnotesElement.node.childCount) === 1) {
64
+ const { pos: fnPos, node: fnNode } = footnotesElement;
65
+ tr.delete(fnPos, fnPos + fnNode.nodeSize + 1);
66
+ }
67
+ else {
68
+ const footnote = findParentNodeClosestToPos(tr.doc.resolve(pos), (node) => node.type === schema.nodes.footnote);
69
+ if (footnote) {
70
+ const { pos: fnPos, node: fnNode } = footnote;
71
+ tr.delete(fnPos, fnPos + fnNode.nodeSize + 1);
72
+ }
73
+ }
62
74
  if (inlineFootnotes) {
63
75
  inlineFootnotes.forEach((footnote) => {
64
76
  const pos = footnote.pos + (tableElement ? tableElement.pos + 1 : 0);
@@ -73,24 +85,6 @@ export const deleteFootnoteWidget = (node, props, id, tableElement, tableElement
73
85
  }
74
86
  }
75
87
  view.dispatch(tr);
76
- if (pos) {
77
- const footnotesElement = findParentNodeClosestToPos(view.state.doc.resolve(pos), (node) => node.type === schema.nodes.footnotes_element);
78
- if (footnotesElement) {
79
- let allFootnotesDeleted = true;
80
- footnotesElement.node.descendants((child) => {
81
- if (child.type === schema.nodes.footnote && !isDeleted(child)) {
82
- allFootnotesDeleted = false;
83
- return false;
84
- }
85
- });
86
- if (allFootnotesDeleted) {
87
- const { pos: fnPos, node: fnNode } = footnotesElement;
88
- const tr2 = view.state.tr;
89
- tr2.delete(fnPos, fnPos + fnNode.nodeSize + 1);
90
- view.dispatch(tr2);
91
- }
92
- }
93
- }
94
88
  };
95
89
  const componentProps = {
96
90
  footnoteType: footnote.type,
@@ -40,10 +40,12 @@ const buildPluginState = (state) => {
40
40
  }
41
41
  };
42
42
  const getEffectiveSelection = ($pos) => {
43
+ var _a;
43
44
  let current;
44
45
  for (let depth = $pos.depth; depth > 0; depth--) {
45
46
  const node = $pos.node(depth);
46
- if (node.attrs.dataTracked) {
47
+ if (node.attrs.dataTracked &&
48
+ !((_a = node.attrs.dataTracked) === null || _a === void 0 ? void 0 : _a.find((c) => c.operation === 'reference'))) {
47
49
  current = {
48
50
  node,
49
51
  from: $pos.before(depth),
@@ -1,2 +1,2 @@
1
- export const VERSION = '2.2.5-LEAN-4013.0';
1
+ export const VERSION = '2.2.6';
2
2
  export const MATHJAX_VERSION = '3.2.2';
@@ -47,12 +47,12 @@ export default class BlockView extends BaseNodeView {
47
47
  this.contentDOM.classList.toggle('empty-node', !this.node.childCount);
48
48
  };
49
49
  this.updateAttributes = () => {
50
- var _a;
51
50
  if (!this.contentDOM) {
52
51
  return;
53
52
  }
54
- if ((_a = this.node.attrs.dataTracked) === null || _a === void 0 ? void 0 : _a.length) {
55
- const lastChange = this.node.attrs.dataTracked[this.node.attrs.dataTracked.length - 1];
53
+ const dataTracked = (this.node.attrs.dataTracked || []).filter((attr) => attr.operation !== 'reference');
54
+ if (dataTracked === null || dataTracked === void 0 ? void 0 : dataTracked.length) {
55
+ const lastChange = dataTracked[dataTracked.length - 1];
56
56
  this.dom.setAttribute('data-track-status', lastChange.status);
57
57
  this.dom.setAttribute('data-track-op', lastChange.operation);
58
58
  }
@@ -21,6 +21,7 @@ import { EditorView } from 'prosemirror-view';
21
21
  import { FileAttachment } from './lib/files';
22
22
  import { EditorAction } from './types';
23
23
  export type Dispatch = (tr: ManuscriptTransaction) => void;
24
+ export declare const addToStart: (state: ManuscriptEditorState, dispatch?: Dispatch) => boolean;
24
25
  export declare const markActive: (type: ManuscriptMarkType) => (state: ManuscriptEditorState) => boolean;
25
26
  export declare const isNodeSelection: (selection: Selection) => selection is NodeSelection;
26
27
  export declare const blockActive: (type: ManuscriptNodeType) => (state: ManuscriptEditorState) => boolean;
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "2.2.5-LEAN-4013.0";
1
+ export declare const VERSION = "2.2.6";
2
2
  export declare const MATHJAX_VERSION = "3.2.2";
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@manuscripts/body-editor",
3
3
  "description": "Prosemirror components for editing and viewing manuscripts",
4
- "version": "2.2.5-LEAN-4013.0",
4
+ "version": "2.2.6",
5
5
  "repository": "github:Atypon-OpenSource/manuscripts-body-editor",
6
6
  "license": "Apache-2.0",
7
7
  "main": "dist/cjs",
@@ -33,7 +33,7 @@
33
33
  "@manuscripts/json-schema": "2.2.11",
34
34
  "@manuscripts/library": "1.3.11",
35
35
  "@manuscripts/style-guide": "2.0.21",
36
- "@manuscripts/track-changes-plugin": "1.7.22",
36
+ "@manuscripts/track-changes-plugin": "1.7.23",
37
37
  "@manuscripts/transform": "2.6.0",
38
38
  "@popperjs/core": "^2.11.8",
39
39
  "astrocite-eutils": "^0.16.4",
@@ -512,7 +512,9 @@ span.accepted .selected-suggestion,
512
512
  }
513
513
 
514
514
  .ProseMirror .inserted.pending,
515
- .ProseMirror [data-track-op='insert'][data-track-status='pending'] .block {
515
+ .ProseMirror [data-track-op='insert'][data-track-status='pending'] .block,
516
+ .ProseMirror [data-track-op='node_split'][data-track-status='pending'] .block,
517
+ .ProseMirror [data-track-op='wrap_with_node'][data-track-status='pending'] .block {
516
518
  background: var(--inserted-pending-bg-color);
517
519
  color: var(--inserted-pending-color);
518
520
  text-decoration: underline;