@manuscripts/transform 3.0.63-LEAN-4527.0 → 3.0.64

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.
@@ -963,10 +963,7 @@ class JATSExporter {
963
963
  const createBoxElement = (node) => {
964
964
  const element = createElement(node, 'boxed-text');
965
965
  appendLabels(element, node);
966
- const child = node.firstChild;
967
- if ((child === null || child === void 0 ? void 0 : child.type) === schema_1.schema.nodes.figcaption) {
968
- appendChildNodeOfType(element, node, node.type.schema.nodes.figcaption);
969
- }
966
+ appendChildNodeOfType(element, node, node.type.schema.nodes.figcaption);
970
967
  processChildNodes(element, node, node.type.schema.nodes.section);
971
968
  return element;
972
969
  };
@@ -51,12 +51,6 @@ const buildTargets = (node) => {
51
51
  if (parent && excludedTypes.includes(parent.type)) {
52
52
  return;
53
53
  }
54
- if (node.type === schema_1.schema.nodes.box_element) {
55
- const child = node.firstChild;
56
- if (!child || child.type !== schema_1.schema.nodes.figcaption) {
57
- return;
58
- }
59
- }
60
54
  const label = buildLabel(node.type);
61
55
  targets.set(node.attrs.id, {
62
56
  type: node.type.name,
@@ -15,7 +15,7 @@
15
15
  * limitations under the License.
16
16
  */
17
17
  Object.defineProperty(exports, "__esModule", { value: true });
18
- exports.link = void 0;
18
+ exports.isLinkNode = exports.link = void 0;
19
19
  exports.link = {
20
20
  content: 'inline*',
21
21
  attrs: {
@@ -58,3 +58,5 @@ exports.link = {
58
58
  return ['a', attrs, 0];
59
59
  },
60
60
  };
61
+ const isLinkNode = (node) => node.type === node.type.schema.nodes.link;
62
+ exports.isLinkNode = isLinkNode;
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = "3.0.63-LEAN-4527.0";
4
+ exports.VERSION = "3.0.64";
@@ -955,10 +955,7 @@ export class JATSExporter {
955
955
  const createBoxElement = (node) => {
956
956
  const element = createElement(node, 'boxed-text');
957
957
  appendLabels(element, node);
958
- const child = node.firstChild;
959
- if ((child === null || child === void 0 ? void 0 : child.type) === schema.nodes.figcaption) {
960
- appendChildNodeOfType(element, node, node.type.schema.nodes.figcaption);
961
- }
958
+ appendChildNodeOfType(element, node, node.type.schema.nodes.figcaption);
962
959
  processChildNodes(element, node, node.type.schema.nodes.section);
963
960
  return element;
964
961
  };
@@ -48,12 +48,6 @@ export const buildTargets = (node) => {
48
48
  if (parent && excludedTypes.includes(parent.type)) {
49
49
  return;
50
50
  }
51
- if (node.type === schema.nodes.box_element) {
52
- const child = node.firstChild;
53
- if (!child || child.type !== schema.nodes.figcaption) {
54
- return;
55
- }
56
- }
57
51
  const label = buildLabel(node.type);
58
52
  targets.set(node.attrs.id, {
59
53
  type: node.type.name,
@@ -55,3 +55,4 @@ export const link = {
55
55
  return ['a', attrs, 0];
56
56
  },
57
57
  };
58
+ export const isLinkNode = (node) => node.type === node.type.schema.nodes.link;
@@ -1 +1 @@
1
- export const VERSION = "3.0.63-LEAN-4527.0";
1
+ export const VERSION = "3.0.64";
@@ -15,10 +15,11 @@
15
15
  */
16
16
  import { NodeSpec } from 'prosemirror-model';
17
17
  import { ManuscriptNode } from '../types';
18
- export interface BoxElementAttrs {
18
+ interface Attrs {
19
19
  id: string;
20
20
  }
21
21
  export interface BoxElementNode extends ManuscriptNode {
22
- attrs: BoxElementAttrs;
22
+ attrs: Attrs;
23
23
  }
24
24
  export declare const box_element: NodeSpec;
25
+ export {};
@@ -23,4 +23,5 @@ export interface LinkNode extends ManuscriptNode {
23
23
  attrs: Attrs;
24
24
  }
25
25
  export declare const link: NodeSpec;
26
+ export declare const isLinkNode: (node: ManuscriptNode) => node is LinkNode;
26
27
  export {};
@@ -1 +1 @@
1
- export declare const VERSION = "3.0.63-LEAN-4527.0";
1
+ export declare const VERSION = "3.0.64";
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": "3.0.63-LEAN-4527.0",
4
+ "version": "3.0.64",
5
5
  "repository": "github:Atypon-OpenSource/manuscripts-transform",
6
6
  "license": "Apache-2.0",
7
7
  "main": "dist/cjs",