@manuscripts/transform 2.0.1-LEAN-3083-2 → 2.0.1-LEAN-3074-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.
@@ -6,7 +6,6 @@ exports.contributor = {
6
6
  attrs: {
7
7
  id: { default: '' },
8
8
  role: { default: '' },
9
- email: { default: '' },
10
9
  affiliations: { default: [] },
11
10
  footnote: { default: undefined },
12
11
  corresp: { default: undefined },
@@ -14,7 +13,6 @@ exports.contributor = {
14
13
  userID: { default: undefined },
15
14
  invitationID: { default: undefined },
16
15
  isCorresponding: { default: undefined },
17
- isJointContributor: { default: undefined },
18
16
  ORCIDIdentifier: { default: undefined },
19
17
  priority: { default: undefined },
20
18
  dataTracked: { default: null },
@@ -17,7 +17,7 @@
17
17
  Object.defineProperty(exports, "__esModule", { value: true });
18
18
  exports.tableElement = void 0;
19
19
  exports.tableElement = {
20
- content: '(table | placeholder) figcaption? table_element_footer? (listing | placeholder)',
20
+ content: '(table | placeholder) table_element_footer? figcaption? (listing | placeholder)',
21
21
  attrs: {
22
22
  id: { default: '' },
23
23
  paragraphStyle: { default: '' },
@@ -91,7 +91,7 @@ class Decoder {
91
91
  const contributors = getContributors(this.modelMap)
92
92
  .map((c) => this.decode(c))
93
93
  .filter(Boolean);
94
- return schema_1.schema.nodes.contributors.createAndFill({}, contributors.sort((a, b) => Number(a.attrs.priority) - Number(b.attrs.priority)));
94
+ return schema_1.schema.nodes.contributors.createAndFill({}, contributors);
95
95
  }
96
96
  createKeywordsNode() {
97
97
  const elements = getKeywordElements(this.modelMap)
@@ -564,7 +564,7 @@ class Decoder {
564
564
  const comments = this.createCommentNodes(model);
565
565
  comments.forEach((c) => this.comments.set(c.attrs.id, c));
566
566
  const content = tableElementFooter
567
- ? [table, figcaption, tableElementFooter]
567
+ ? [table, tableElementFooter, figcaption]
568
568
  : [table, figcaption];
569
569
  if (model.listingID) {
570
570
  const listing = this.createListing(model.listingID);
@@ -629,7 +629,6 @@ class Decoder {
629
629
  id: model._id,
630
630
  role: model.role,
631
631
  affiliations: model.affiliations,
632
- email: model.email,
633
632
  bibliographicName: model.bibliographicName,
634
633
  userID: model.userID,
635
634
  invitationID: model.invitationID,
@@ -3,7 +3,6 @@ export const contributor = {
3
3
  attrs: {
4
4
  id: { default: '' },
5
5
  role: { default: '' },
6
- email: { default: '' },
7
6
  affiliations: { default: [] },
8
7
  footnote: { default: undefined },
9
8
  corresp: { default: undefined },
@@ -11,7 +10,6 @@ export const contributor = {
11
10
  userID: { default: undefined },
12
11
  invitationID: { default: undefined },
13
12
  isCorresponding: { default: undefined },
14
- isJointContributor: { default: undefined },
15
13
  ORCIDIdentifier: { default: undefined },
16
14
  priority: { default: undefined },
17
15
  dataTracked: { default: null },
@@ -14,7 +14,7 @@
14
14
  * limitations under the License.
15
15
  */
16
16
  export const tableElement = {
17
- content: '(table | placeholder) figcaption? table_element_footer? (listing | placeholder)',
17
+ content: '(table | placeholder) table_element_footer? figcaption? (listing | placeholder)',
18
18
  attrs: {
19
19
  id: { default: '' },
20
20
  paragraphStyle: { default: '' },
@@ -82,7 +82,7 @@ export class Decoder {
82
82
  const contributors = getContributors(this.modelMap)
83
83
  .map((c) => this.decode(c))
84
84
  .filter(Boolean);
85
- return schema.nodes.contributors.createAndFill({}, contributors.sort((a, b) => Number(a.attrs.priority) - Number(b.attrs.priority)));
85
+ return schema.nodes.contributors.createAndFill({}, contributors);
86
86
  }
87
87
  createKeywordsNode() {
88
88
  const elements = getKeywordElements(this.modelMap)
@@ -555,7 +555,7 @@ export class Decoder {
555
555
  const comments = this.createCommentNodes(model);
556
556
  comments.forEach((c) => this.comments.set(c.attrs.id, c));
557
557
  const content = tableElementFooter
558
- ? [table, figcaption, tableElementFooter]
558
+ ? [table, tableElementFooter, figcaption]
559
559
  : [table, figcaption];
560
560
  if (model.listingID) {
561
561
  const listing = this.createListing(model.listingID);
@@ -620,7 +620,6 @@ export class Decoder {
620
620
  id: model._id,
621
621
  role: model.role,
622
622
  affiliations: model.affiliations,
623
- email: model.email,
624
623
  bibliographicName: model.bibliographicName,
625
624
  userID: model.userID,
626
625
  invitationID: model.invitationID,
@@ -1,13 +1,12 @@
1
- import { BibliographicName } from '@manuscripts/json-schema';
1
+ import { Affiliation, BibliographicName } from '@manuscripts/json-schema';
2
2
  import { NodeSpec } from 'prosemirror-model';
3
3
  import { ManuscriptNode } from '../types';
4
4
  interface Attrs {
5
5
  id: string;
6
6
  role: string;
7
- affiliations: string[];
7
+ affiliations: Affiliation[];
8
8
  bibliographicName: BibliographicName;
9
9
  userID: string;
10
- email: string;
11
10
  invitationID: string;
12
11
  isCorresponding: boolean;
13
12
  ORCIDIdentifier: string;
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.0.1-LEAN-3083-2",
4
+ "version": "2.0.1-LEAN-3074-0",
5
5
  "repository": "github:Atypon-OpenSource/manuscripts-transform",
6
6
  "license": "Apache-2.0",
7
7
  "main": "dist/cjs",
@@ -77,4 +77,4 @@
77
77
  "rimraf": "^3.0.2",
78
78
  "typescript": "^4.0.5"
79
79
  }
80
- }
80
+ }