@manuscripts/body-editor 2.0.13 → 2.0.14-JSR
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 +1 -1
- package/dist/cjs/configs/editor-plugins.js +1 -1
- package/dist/cjs/plugins/objects.js +3 -3
- package/dist/cjs/testing/default-editor-data.js +0 -1
- package/dist/cjs/versions.js +1 -1
- package/dist/es/commands.js +1 -1
- package/dist/es/configs/editor-plugins.js +1 -1
- package/dist/es/plugins/objects.js +3 -3
- package/dist/es/testing/default-editor-data.js +0 -1
- package/dist/es/versions.js +1 -1
- package/dist/types/components/outline/ManuscriptOutline.d.ts +0 -2
- package/dist/types/configs/ManuscriptsEditor.d.ts +1 -2
- package/dist/types/plugins/objects.d.ts +1 -5
- package/dist/types/versions.d.ts +1 -1
- package/package.json +3 -3
- package/styles/Editor.css +12 -0
package/dist/cjs/commands.js
CHANGED
|
@@ -807,8 +807,8 @@ const createAndFillTableElement = (state, tableConfig) => {
|
|
|
807
807
|
tableRows.push(createRow('table_cell'));
|
|
808
808
|
}
|
|
809
809
|
return nodes.table_element.createChecked({}, [
|
|
810
|
-
nodes.table.create({}, tableRows),
|
|
811
810
|
createAndFillFigcaptionElement(state),
|
|
811
|
+
nodes.table.create({}, tableRows),
|
|
812
812
|
nodes.listing.create(),
|
|
813
813
|
]);
|
|
814
814
|
};
|
|
@@ -64,7 +64,7 @@ exports.default = (props) => {
|
|
|
64
64
|
(0, sections_1.default)(),
|
|
65
65
|
(0, toc_1.default)(),
|
|
66
66
|
(0, bibliography_1.default)(props),
|
|
67
|
-
(0, objects_1.default)(
|
|
67
|
+
(0, objects_1.default)(),
|
|
68
68
|
(0, affiliations_1.default)(),
|
|
69
69
|
(0, comments_1.default)(),
|
|
70
70
|
(0, paragraphs_1.default)(),
|
|
@@ -21,15 +21,15 @@ const prosemirror_model_1 = require("prosemirror-model");
|
|
|
21
21
|
const prosemirror_state_1 = require("prosemirror-state");
|
|
22
22
|
const prosemirror_view_1 = require("prosemirror-view");
|
|
23
23
|
exports.objectsKey = new prosemirror_state_1.PluginKey('objects');
|
|
24
|
-
exports.default = (
|
|
24
|
+
exports.default = () => {
|
|
25
25
|
return new prosemirror_state_1.Plugin({
|
|
26
26
|
key: exports.objectsKey,
|
|
27
27
|
state: {
|
|
28
28
|
init: (config, state) => {
|
|
29
|
-
return (0, transform_1.buildTargets)(prosemirror_model_1.Fragment.from(state.doc.content)
|
|
29
|
+
return (0, transform_1.buildTargets)(prosemirror_model_1.Fragment.from(state.doc.content));
|
|
30
30
|
},
|
|
31
31
|
apply: (tr) => {
|
|
32
|
-
return (0, transform_1.buildTargets)(prosemirror_model_1.Fragment.from(tr.doc.content)
|
|
32
|
+
return (0, transform_1.buildTargets)(prosemirror_model_1.Fragment.from(tr.doc.content));
|
|
33
33
|
},
|
|
34
34
|
},
|
|
35
35
|
props: {
|
package/dist/cjs/versions.js
CHANGED
package/dist/es/commands.js
CHANGED
|
@@ -768,8 +768,8 @@ export const createAndFillTableElement = (state, tableConfig) => {
|
|
|
768
768
|
tableRows.push(createRow('table_cell'));
|
|
769
769
|
}
|
|
770
770
|
return nodes.table_element.createChecked({}, [
|
|
771
|
-
nodes.table.create({}, tableRows),
|
|
772
771
|
createAndFillFigcaptionElement(state),
|
|
772
|
+
nodes.table.create({}, tableRows),
|
|
773
773
|
nodes.listing.create(),
|
|
774
774
|
]);
|
|
775
775
|
};
|
|
@@ -18,15 +18,15 @@ import { Fragment } from 'prosemirror-model';
|
|
|
18
18
|
import { Plugin, PluginKey } from 'prosemirror-state';
|
|
19
19
|
import { Decoration, DecorationSet } from 'prosemirror-view';
|
|
20
20
|
export const objectsKey = new PluginKey('objects');
|
|
21
|
-
export default (
|
|
21
|
+
export default () => {
|
|
22
22
|
return new Plugin({
|
|
23
23
|
key: objectsKey,
|
|
24
24
|
state: {
|
|
25
25
|
init: (config, state) => {
|
|
26
|
-
return buildTargets(Fragment.from(state.doc.content)
|
|
26
|
+
return buildTargets(Fragment.from(state.doc.content));
|
|
27
27
|
},
|
|
28
28
|
apply: (tr) => {
|
|
29
|
-
return buildTargets(Fragment.from(tr.doc.content)
|
|
29
|
+
return buildTargets(Fragment.from(tr.doc.content));
|
|
30
30
|
},
|
|
31
31
|
},
|
|
32
32
|
props: {
|
package/dist/es/versions.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '2.0.
|
|
1
|
+
export const VERSION = '2.0.14-JSR';
|
|
2
2
|
export const MATHJAX_VERSION = '3.2.2';
|
|
@@ -13,12 +13,10 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import { Manuscript } from '@manuscripts/json-schema';
|
|
17
16
|
import { Capabilities } from '@manuscripts/style-guide';
|
|
18
17
|
import { ManuscriptEditorView, ManuscriptNode } from '@manuscripts/transform';
|
|
19
18
|
import React from 'react';
|
|
20
19
|
export interface ManuscriptOutlineProps {
|
|
21
|
-
manuscript: Manuscript;
|
|
22
20
|
doc: ManuscriptNode | null;
|
|
23
21
|
can?: Capabilities;
|
|
24
22
|
view?: ManuscriptEditorView;
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
16
|
import 'prosemirror-view/style/prosemirror.css';
|
|
17
|
-
import {
|
|
17
|
+
import { UserProfile } from '@manuscripts/json-schema';
|
|
18
18
|
import { Capabilities } from '@manuscripts/style-guide';
|
|
19
19
|
import { ManuscriptNode } from '@manuscripts/transform';
|
|
20
20
|
import { EditorState } from 'prosemirror-state';
|
|
@@ -37,7 +37,6 @@ export interface EditorProps {
|
|
|
37
37
|
getCurrentUser: () => UserProfile;
|
|
38
38
|
projectID: string;
|
|
39
39
|
doc: ManuscriptNode;
|
|
40
|
-
getManuscript: () => Manuscript;
|
|
41
40
|
getFiles: () => FileAttachment[];
|
|
42
41
|
fileManagement: FileManagement;
|
|
43
42
|
popper: PopperManager;
|
|
@@ -13,12 +13,8 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import { Manuscript } from '@manuscripts/json-schema';
|
|
17
16
|
import { Target } from '@manuscripts/transform';
|
|
18
17
|
import { Plugin, PluginKey } from 'prosemirror-state';
|
|
19
18
|
export declare const objectsKey: PluginKey<Map<string, Target>>;
|
|
20
|
-
|
|
21
|
-
getManuscript: () => Manuscript;
|
|
22
|
-
}
|
|
23
|
-
declare const _default: (props: Props) => Plugin<Map<string, Target>>;
|
|
19
|
+
declare const _default: () => Plugin<Map<string, Target>>;
|
|
24
20
|
export default _default;
|
package/dist/types/versions.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "2.0.
|
|
1
|
+
export declare const VERSION = "2.0.14-JSR";
|
|
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.0.
|
|
4
|
+
"version": "2.0.14-JSR",
|
|
5
5
|
"repository": "github:Atypon-OpenSource/manuscripts-body-editor",
|
|
6
6
|
"license": "Apache-2.0",
|
|
7
7
|
"main": "dist/cjs",
|
|
@@ -32,9 +32,9 @@
|
|
|
32
32
|
"@iarna/word-count": "^1.1.2",
|
|
33
33
|
"@manuscripts/json-schema": "2.2.10",
|
|
34
34
|
"@manuscripts/library": "1.3.10",
|
|
35
|
-
"@manuscripts/style-guide": "2.0.
|
|
35
|
+
"@manuscripts/style-guide": "2.0.3",
|
|
36
36
|
"@manuscripts/track-changes-plugin": "1.7.17",
|
|
37
|
-
"@manuscripts/transform": "2.3.
|
|
37
|
+
"@manuscripts/transform": "2.3.22-JSR",
|
|
38
38
|
"@popperjs/core": "^2.11.8",
|
|
39
39
|
"astrocite-eutils": "^0.16.4",
|
|
40
40
|
"codemirror": "^5.58.1",
|
package/styles/Editor.css
CHANGED
|
@@ -296,6 +296,10 @@
|
|
|
296
296
|
word-wrap: break-word;
|
|
297
297
|
}
|
|
298
298
|
|
|
299
|
+
.ProseMirror .block-table_element figcaption {
|
|
300
|
+
text-align: left;
|
|
301
|
+
}
|
|
302
|
+
|
|
299
303
|
.ProseMirror .caption-title:not(.empty-node) {
|
|
300
304
|
font-weight: bold;
|
|
301
305
|
}
|
|
@@ -316,6 +320,14 @@
|
|
|
316
320
|
content: 'Caption...';
|
|
317
321
|
}
|
|
318
322
|
|
|
323
|
+
.ProseMirror .block-table_element .caption-description.empty-node::before {
|
|
324
|
+
content: 'Table caption';
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
.ProseMirror .block-table_element .caption-title.empty-node::before {
|
|
328
|
+
content: 'Table title';
|
|
329
|
+
}
|
|
330
|
+
|
|
319
331
|
.ProseMirror .suppress-caption .caption-description {
|
|
320
332
|
display: none;
|
|
321
333
|
}
|