@manuscripts/body-editor 2.6.40 → 2.7.0
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.
- package/dist/cjs/commands.js +6 -1
- package/dist/cjs/versions.js +1 -1
- package/dist/es/commands.js +6 -1
- package/dist/es/versions.js +1 -1
- package/dist/types/versions.d.ts +1 -1
- package/package.json +2 -2
package/dist/cjs/commands.js
CHANGED
|
@@ -725,6 +725,10 @@ function toggleOffList(state, dispatch) {
|
|
|
725
725
|
}
|
|
726
726
|
if (rootList) {
|
|
727
727
|
state.doc.nodesBetween(rootList.pos, rootList.pos + rootList.node.nodeSize, (node, pos) => {
|
|
728
|
+
if (pos < rootList.pos ||
|
|
729
|
+
node.nodeSize > rootList.pos + rootList.node.nodeSize) {
|
|
730
|
+
return true;
|
|
731
|
+
}
|
|
728
732
|
const $fromPos = tr.doc.resolve(tr.mapping.map(pos));
|
|
729
733
|
const $toPos = tr.doc.resolve(tr.mapping.map(pos + node.nodeSize - 1));
|
|
730
734
|
const nodeRange = $fromPos.blockRange($toPos);
|
|
@@ -734,9 +738,10 @@ function toggleOffList(state, dispatch) {
|
|
|
734
738
|
const targetLiftDepth = (0, prosemirror_transform_1.liftTarget)(nodeRange);
|
|
735
739
|
if (targetLiftDepth || targetLiftDepth === 0) {
|
|
736
740
|
tr.lift(nodeRange, targetLiftDepth);
|
|
741
|
+
return false;
|
|
737
742
|
}
|
|
738
743
|
});
|
|
739
|
-
dispatch(
|
|
744
|
+
dispatch(tr);
|
|
740
745
|
return true;
|
|
741
746
|
}
|
|
742
747
|
else {
|
package/dist/cjs/versions.js
CHANGED
package/dist/es/commands.js
CHANGED
|
@@ -690,6 +690,10 @@ function toggleOffList(state, dispatch) {
|
|
|
690
690
|
}
|
|
691
691
|
if (rootList) {
|
|
692
692
|
state.doc.nodesBetween(rootList.pos, rootList.pos + rootList.node.nodeSize, (node, pos) => {
|
|
693
|
+
if (pos < rootList.pos ||
|
|
694
|
+
node.nodeSize > rootList.pos + rootList.node.nodeSize) {
|
|
695
|
+
return true;
|
|
696
|
+
}
|
|
693
697
|
const $fromPos = tr.doc.resolve(tr.mapping.map(pos));
|
|
694
698
|
const $toPos = tr.doc.resolve(tr.mapping.map(pos + node.nodeSize - 1));
|
|
695
699
|
const nodeRange = $fromPos.blockRange($toPos);
|
|
@@ -699,9 +703,10 @@ function toggleOffList(state, dispatch) {
|
|
|
699
703
|
const targetLiftDepth = liftTarget(nodeRange);
|
|
700
704
|
if (targetLiftDepth || targetLiftDepth === 0) {
|
|
701
705
|
tr.lift(nodeRange, targetLiftDepth);
|
|
706
|
+
return false;
|
|
702
707
|
}
|
|
703
708
|
});
|
|
704
|
-
dispatch(
|
|
709
|
+
dispatch(tr);
|
|
705
710
|
return true;
|
|
706
711
|
}
|
|
707
712
|
else {
|
package/dist/es/versions.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '2.
|
|
1
|
+
export const VERSION = '2.7.0';
|
|
2
2
|
export const MATHJAX_VERSION = '3.2.2';
|
package/dist/types/versions.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "2.
|
|
1
|
+
export declare const VERSION = "2.7.0";
|
|
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.
|
|
4
|
+
"version": "2.7.0",
|
|
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.28",
|
|
36
|
-
"@manuscripts/track-changes-plugin": "1.
|
|
36
|
+
"@manuscripts/track-changes-plugin": "1.9.0",
|
|
37
37
|
"@manuscripts/transform": "3.0.28",
|
|
38
38
|
"@popperjs/core": "^2.11.8",
|
|
39
39
|
"astrocite-eutils": "^0.16.4",
|