@manuscripts/transform 2.3.7 → 2.3.8-LEAN-1330.1
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/schema/nodes/manuscript.js +1 -0
- package/dist/cjs/transformer/decode.js +8 -0
- package/dist/cjs/version.js +1 -1
- package/dist/es/schema/nodes/manuscript.js +1 -0
- package/dist/es/transformer/decode.js +8 -0
- package/dist/es/version.js +1 -1
- package/dist/types/schema/nodes/manuscript.d.ts +1 -0
- package/dist/types/transformer/decode.d.ts +1 -0
- package/dist/types/version.d.ts +1 -1
- package/package.json +1 -1
|
@@ -736,6 +736,7 @@ class Decoder {
|
|
|
736
736
|
];
|
|
737
737
|
return schema_1.schema.nodes.manuscript.create({
|
|
738
738
|
id: manuscriptID || this.getManuscriptID(),
|
|
739
|
+
doi: this.getManuscriptDOI() || '',
|
|
739
740
|
}, contents);
|
|
740
741
|
};
|
|
741
742
|
this.addGeneratedLabels = (sections) => {
|
|
@@ -781,6 +782,13 @@ class Decoder {
|
|
|
781
782
|
}
|
|
782
783
|
}
|
|
783
784
|
};
|
|
785
|
+
this.getManuscriptDOI = () => {
|
|
786
|
+
for (const item of this.modelMap.values()) {
|
|
787
|
+
if ((0, object_types_1.isManuscript)(item)) {
|
|
788
|
+
return item.DOI;
|
|
789
|
+
}
|
|
790
|
+
}
|
|
791
|
+
};
|
|
784
792
|
this.getFigcaption = (model) => {
|
|
785
793
|
const titleNode = schema_1.schema.nodes.caption_title.create();
|
|
786
794
|
const captionTitle = model.title
|
package/dist/cjs/version.js
CHANGED
|
@@ -727,6 +727,7 @@ export class Decoder {
|
|
|
727
727
|
];
|
|
728
728
|
return schema.nodes.manuscript.create({
|
|
729
729
|
id: manuscriptID || this.getManuscriptID(),
|
|
730
|
+
doi: this.getManuscriptDOI() || '',
|
|
730
731
|
}, contents);
|
|
731
732
|
};
|
|
732
733
|
this.addGeneratedLabels = (sections) => {
|
|
@@ -772,6 +773,13 @@ export class Decoder {
|
|
|
772
773
|
}
|
|
773
774
|
}
|
|
774
775
|
};
|
|
776
|
+
this.getManuscriptDOI = () => {
|
|
777
|
+
for (const item of this.modelMap.values()) {
|
|
778
|
+
if (isManuscript(item)) {
|
|
779
|
+
return item.DOI;
|
|
780
|
+
}
|
|
781
|
+
}
|
|
782
|
+
};
|
|
775
783
|
this.getFigcaption = (model) => {
|
|
776
784
|
const titleNode = schema.nodes.caption_title.create();
|
|
777
785
|
const captionTitle = model.title
|
package/dist/es/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = "2.3.
|
|
1
|
+
export const VERSION = "2.3.8-LEAN-1330.1";
|
|
@@ -41,6 +41,7 @@ export declare class Decoder {
|
|
|
41
41
|
addGeneratedLabels: (sections: Section[]) => Section[];
|
|
42
42
|
parseContents: (contents: string, wrapper?: string, commentAnnotations?: CommentAnnotation[], options?: ParseOptions) => ManuscriptNode;
|
|
43
43
|
private getManuscriptID;
|
|
44
|
+
private getManuscriptDOI;
|
|
44
45
|
private getFigcaption;
|
|
45
46
|
private createTable;
|
|
46
47
|
private createTableColGroup;
|
package/dist/types/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const VERSION = "2.3.
|
|
1
|
+
export declare const VERSION = "2.3.8-LEAN-1330.1";
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@manuscripts/transform",
|
|
3
3
|
"description": "ProseMirror transformer for Manuscripts applications",
|
|
4
|
-
"version": "2.3.
|
|
4
|
+
"version": "2.3.8-LEAN-1330.1",
|
|
5
5
|
"repository": "github:Atypon-OpenSource/manuscripts-transform",
|
|
6
6
|
"license": "Apache-2.0",
|
|
7
7
|
"main": "dist/cjs",
|