@manuscripts/transform 3.0.11 → 3.0.12-LEAN-3961.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.
Files changed (37) hide show
  1. package/dist/cjs/index.js +1 -1
  2. package/dist/cjs/jats/exporter/jats-exporter.js +5 -5
  3. package/dist/cjs/jats/importer/jats-dom-parser.js +977 -945
  4. package/dist/cjs/jats/importer/jats-transformations.js +5 -6
  5. package/dist/cjs/jats/importer/parse-jats-article.js +7 -5
  6. package/dist/cjs/lib/section-categories.js +22 -0
  7. package/dist/cjs/schema/migration/migration-scripts/3.0.12.js +26 -0
  8. package/dist/cjs/schema/migration/migration-scripts/index.js +6 -1
  9. package/dist/cjs/transformer/index.js +0 -1
  10. package/dist/cjs/version.js +1 -1
  11. package/dist/es/index.js +1 -1
  12. package/dist/es/jats/exporter/jats-exporter.js +6 -6
  13. package/dist/es/jats/importer/jats-dom-parser.js +975 -944
  14. package/dist/es/jats/importer/jats-transformations.js +5 -6
  15. package/dist/es/jats/importer/parse-jats-article.js +8 -6
  16. package/dist/es/lib/section-categories.js +17 -0
  17. package/dist/es/schema/migration/migration-scripts/3.0.12.js +22 -0
  18. package/dist/es/schema/migration/migration-scripts/index.js +6 -1
  19. package/dist/es/transformer/index.js +0 -1
  20. package/dist/es/version.js +1 -1
  21. package/dist/types/index.d.ts +1 -1
  22. package/dist/types/jats/importer/jats-dom-parser.d.ts +25 -9
  23. package/dist/types/jats/importer/jats-transformations.d.ts +2 -1
  24. package/dist/types/jats/importer/parse-jats-article.d.ts +2 -2
  25. package/dist/types/lib/section-categories.d.ts +18 -0
  26. package/dist/types/schema/migration/migration-scripts/3.0.12.d.ts +9 -0
  27. package/dist/types/schema/migration/migration-scripts/index.d.ts +2 -1
  28. package/dist/types/schema/types.d.ts +21 -1
  29. package/dist/types/transformer/index.d.ts +0 -1
  30. package/dist/types/version.d.ts +1 -1
  31. package/package.json +2 -2
  32. package/dist/cjs/lib/table-cell-styles.js +0 -52
  33. package/dist/cjs/transformer/section-category.js +0 -268
  34. package/dist/es/lib/table-cell-styles.js +0 -47
  35. package/dist/es/transformer/section-category.js +0 -254
  36. package/dist/types/lib/table-cell-styles.d.ts +0 -27
  37. package/dist/types/transformer/section-category.d.ts +0 -31
package/dist/cjs/index.js CHANGED
@@ -21,9 +21,9 @@ Object.defineProperty(exports, "getVersion", { enumerable: true, get: function (
21
21
  __exportStar(require("./jats"), exports);
22
22
  __exportStar(require("./jats/types"), exports);
23
23
  __exportStar(require("./lib/section-group-type"), exports);
24
- __exportStar(require("./lib/table-cell-styles"), exports);
25
24
  __exportStar(require("./lib/footnotes"), exports);
26
25
  __exportStar(require("./lib/utils"), exports);
26
+ __exportStar(require("./lib/section-categories"), exports);
27
27
  __exportStar(require("./schema"), exports);
28
28
  var migrate_1 = require("./schema/migration/migrate");
29
29
  Object.defineProperty(exports, "migrateFor", { enumerable: true, get: function () { return migrate_1.migrateFor; } });
@@ -784,7 +784,7 @@ class JATSExporter {
784
784
  id: normalizeID(node.attrs.id),
785
785
  };
786
786
  if (node.attrs.category) {
787
- attrs['sec-type'] = (0, transformer_1.chooseSecType)(node.attrs.category);
787
+ attrs['sec-type'] = node.attrs.category;
788
788
  }
789
789
  return ['sec', attrs, 0];
790
790
  },
@@ -1386,7 +1386,7 @@ class JATSExporter {
1386
1386
  if (availabilitySection) {
1387
1387
  back.insertBefore(availabilitySection, back.firstChild);
1388
1388
  }
1389
- const section = body.querySelector('sec[sec-type="acknowledgments"]');
1389
+ const section = body.querySelector('sec[sec-type="acknowledgements"]');
1390
1390
  if (section) {
1391
1391
  const ack = this.document.createElement('ack');
1392
1392
  while (section.firstChild) {
@@ -1423,7 +1423,7 @@ class JATSExporter {
1423
1423
  'supported-by',
1424
1424
  'financial-disclosure',
1425
1425
  'ethics-statement',
1426
- 'competing-interests',
1426
+ 'coi-statement',
1427
1427
  ];
1428
1428
  const sections = body.querySelectorAll('sec');
1429
1429
  for (const currentSection of sections) {
@@ -1574,7 +1574,7 @@ class JATSExporter {
1574
1574
  const fnGroups = back.querySelectorAll('fn-group');
1575
1575
  fnGroups.forEach((fnGroup) => {
1576
1576
  if (fnGroup) {
1577
- const coiStatement = fnGroup.querySelector('fn[fn-type="competing-interests"]');
1577
+ const coiStatement = fnGroup.querySelector('fn[fn-type="coi-statement"]');
1578
1578
  if (coiStatement) {
1579
1579
  const authorNotes = this.document.createElement('author-notes');
1580
1580
  authorNotes.append(coiStatement);
@@ -1616,7 +1616,7 @@ class JATSExporter {
1616
1616
  footnotes.forEach((fn) => {
1617
1617
  const fnType = fn.getAttribute('fn-type');
1618
1618
  if (fnType) {
1619
- fn.setAttribute('fn-type', (0, transformer_1.chooseJatsFnType)(fnType));
1619
+ fn.setAttribute('fn-type', fnType);
1620
1620
  }
1621
1621
  });
1622
1622
  }