pro-editor-schema 0.1.181 → 0.1.182

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/index.d.mts CHANGED
@@ -18,6 +18,7 @@ type Schema<TRequiredAttributes = readonly AttributeDefinition[], TOptionalAttri
18
18
  optionalAttributes: TOptionalAttributes;
19
19
  defaultChildTagName?: string;
20
20
  allowedChildTagNames: ReadonlySet<AllowedChildren>;
21
+ unhierarchicalAllowedChildTagNames?: readonly string[];
21
22
  };
22
23
  type SchemaCode = ElementSchemaCode | InlineSchemaCode | AtomSchemaCode;
23
24
  type ElementSchemaCode = "degrees" | "email" | "equation" | "fignote" | "figsource" | "firstname" | "footnote" | "footnoteno" | "honorific" | "img" | "informalfigure" | "keyword" | "label1" | "li" | "line" | "lrh" | "math" | "mathphrase" | "merror" | "mfrac" | "mi" | "mmultiscripts" | "mn" | "mo" | "mover" | "mpadded" | "mphantom" | "mprescripts" | "mroot" | "mrow" | "ms" | "mspace" | "msqrt" | "mstyle" | "msub" | "msubsup" | "msup" | "mtable" | "mtd" | "mtext" | "mtr" | "munder" | "munderover" | "olink" | "org" | "orgname" | "para" | "punc" | "rrh" | "source1" | "speaker" | "subtitle1" | "surname" | "tag" | "tblfn" | "tblsource" | "thead" | "title1" | "token" | "tp" | "abstract1" | "affiliation" | "alttext" | "appendix" | "author" | "authorgroup" | "blockquote" | "caption1" | "chapter" | "dialogue" | "epigraph" | "figure1" | "footnoteSection" | "heading" | "imageobject" | "info1" | "keywordset" | "mediaobject" | "ol" | "personname" | "poem" | "sidebar" | "table" | "table1" | "tbody" | "td" | "tgroup" | "tr" | "ul";
package/dist/index.d.ts CHANGED
@@ -18,6 +18,7 @@ type Schema<TRequiredAttributes = readonly AttributeDefinition[], TOptionalAttri
18
18
  optionalAttributes: TOptionalAttributes;
19
19
  defaultChildTagName?: string;
20
20
  allowedChildTagNames: ReadonlySet<AllowedChildren>;
21
+ unhierarchicalAllowedChildTagNames?: readonly string[];
21
22
  };
22
23
  type SchemaCode = ElementSchemaCode | InlineSchemaCode | AtomSchemaCode;
23
24
  type ElementSchemaCode = "degrees" | "email" | "equation" | "fignote" | "figsource" | "firstname" | "footnote" | "footnoteno" | "honorific" | "img" | "informalfigure" | "keyword" | "label1" | "li" | "line" | "lrh" | "math" | "mathphrase" | "merror" | "mfrac" | "mi" | "mmultiscripts" | "mn" | "mo" | "mover" | "mpadded" | "mphantom" | "mprescripts" | "mroot" | "mrow" | "ms" | "mspace" | "msqrt" | "mstyle" | "msub" | "msubsup" | "msup" | "mtable" | "mtd" | "mtext" | "mtr" | "munder" | "munderover" | "olink" | "org" | "orgname" | "para" | "punc" | "rrh" | "source1" | "speaker" | "subtitle1" | "surname" | "tag" | "tblfn" | "tblsource" | "thead" | "title1" | "token" | "tp" | "abstract1" | "affiliation" | "alttext" | "appendix" | "author" | "authorgroup" | "blockquote" | "caption1" | "chapter" | "dialogue" | "epigraph" | "figure1" | "footnoteSection" | "heading" | "imageobject" | "info1" | "keywordset" | "mediaobject" | "ol" | "personname" | "poem" | "sidebar" | "table" | "table1" | "tbody" | "td" | "tgroup" | "tr" | "ul";
package/dist/index.js CHANGED
@@ -69,7 +69,8 @@ var createSchema = ({
69
69
  requiredAttributes,
70
70
  optionalAttributes,
71
71
  defaultChildTagName,
72
- allowedChildTagNames
72
+ allowedChildTagNames,
73
+ unhierarchicalAllowedChildTagNames
73
74
  }) => {
74
75
  return {
75
76
  code,
@@ -78,7 +79,8 @@ var createSchema = ({
78
79
  requiredAttributes,
79
80
  optionalAttributes,
80
81
  defaultChildTagName,
81
- allowedChildTagNames: new Set(allowedChildTagNames)
82
+ allowedChildTagNames: new Set(allowedChildTagNames),
83
+ unhierarchicalAllowedChildTagNames
82
84
  };
83
85
  };
84
86
 
@@ -2020,10 +2022,8 @@ var MATHPHRASE_SCHEMA = createSchema({
2020
2022
  tag: MATHPHRASE_TAG,
2021
2023
  requiredAttributes: [ELE_ID_ATTRIBUTE],
2022
2024
  optionalAttributes: [],
2023
- allowedChildTagNames: [
2024
- { tagName: MATH_TAG, required: true },
2025
- { tagName: SPAN_TAG, required: false }
2026
- ]
2025
+ allowedChildTagNames: [{ tagName: MATH_TAG, required: true }],
2026
+ unhierarchicalAllowedChildTagNames: [SPAN_TAG]
2027
2027
  });
2028
2028
 
2029
2029
  // src/schema/elementSchemas/elements/index.ts
package/dist/index.mjs CHANGED
@@ -6,7 +6,8 @@ var createSchema = ({
6
6
  requiredAttributes,
7
7
  optionalAttributes,
8
8
  defaultChildTagName,
9
- allowedChildTagNames
9
+ allowedChildTagNames,
10
+ unhierarchicalAllowedChildTagNames
10
11
  }) => {
11
12
  return {
12
13
  code,
@@ -15,7 +16,8 @@ var createSchema = ({
15
16
  requiredAttributes,
16
17
  optionalAttributes,
17
18
  defaultChildTagName,
18
- allowedChildTagNames: new Set(allowedChildTagNames)
19
+ allowedChildTagNames: new Set(allowedChildTagNames),
20
+ unhierarchicalAllowedChildTagNames
19
21
  };
20
22
  };
21
23
 
@@ -1957,10 +1959,8 @@ var MATHPHRASE_SCHEMA = createSchema({
1957
1959
  tag: MATHPHRASE_TAG,
1958
1960
  requiredAttributes: [ELE_ID_ATTRIBUTE],
1959
1961
  optionalAttributes: [],
1960
- allowedChildTagNames: [
1961
- { tagName: MATH_TAG, required: true },
1962
- { tagName: SPAN_TAG, required: false }
1963
- ]
1962
+ allowedChildTagNames: [{ tagName: MATH_TAG, required: true }],
1963
+ unhierarchicalAllowedChildTagNames: [SPAN_TAG]
1964
1964
  });
1965
1965
 
1966
1966
  // src/schema/elementSchemas/elements/index.ts
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pro-editor-schema",
3
- "version": "0.1.181",
3
+ "version": "0.1.182",
4
4
  "description": "Pro Editor XML schemas",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",