pro-editor-schema 0.1.0 → 0.1.12

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
@@ -210,7 +210,7 @@ declare const KEYWORDSET_SCHEMA: Schema<readonly ["store", "ele-id", {
210
210
 
211
211
  declare const KEYWORD_SCHEMA: Schema<readonly ["store", "ele-id"], readonly ["data-pos"]>;
212
212
 
213
- declare const PUNC_SCHEMA: Schema<readonly ["store"], readonly ["ele-id", "data-role"]>;
213
+ declare const PUNC_SCHEMA: Schema<readonly ["store", "ele-id"], readonly ["data-role"]>;
214
214
 
215
215
  declare const LABEL_SCHEMA: Schema<readonly ["store", "ele-id"], readonly ["data-alignment", "data-left-indent", "data-right-indent", "data-special-indent", "data-space-above", "data-space-below", "data-indent-type", "data-layout-user", "data-cell-width", "data-paragraph-style", "data-table-orientation", "data-table-placement", "data-figure-placement", {
216
216
  readonly name: "fm-role";
@@ -381,7 +381,7 @@ declare const GROUP_ELEMENT_SCHEMAS: ReadonlyArray<Schema>;
381
381
 
382
382
  declare const FOOTNOTE_LINK_TAG = "FOOTNOTE1";
383
383
  declare const INLINEEQUATION_TAG = "INLINEEQUATION";
384
- declare const LINK_TAG = "LINK";
384
+ declare const LINK_TAG = "LINK1";
385
385
  declare const URI_TAG = "URI";
386
386
  declare const INLINE_ELEMENT_TAGS_ALLOWED_CHILDREN: {
387
387
  tagName: string;
package/dist/index.d.ts CHANGED
@@ -210,7 +210,7 @@ declare const KEYWORDSET_SCHEMA: Schema<readonly ["store", "ele-id", {
210
210
 
211
211
  declare const KEYWORD_SCHEMA: Schema<readonly ["store", "ele-id"], readonly ["data-pos"]>;
212
212
 
213
- declare const PUNC_SCHEMA: Schema<readonly ["store"], readonly ["ele-id", "data-role"]>;
213
+ declare const PUNC_SCHEMA: Schema<readonly ["store", "ele-id"], readonly ["data-role"]>;
214
214
 
215
215
  declare const LABEL_SCHEMA: Schema<readonly ["store", "ele-id"], readonly ["data-alignment", "data-left-indent", "data-right-indent", "data-special-indent", "data-space-above", "data-space-below", "data-indent-type", "data-layout-user", "data-cell-width", "data-paragraph-style", "data-table-orientation", "data-table-placement", "data-figure-placement", {
216
216
  readonly name: "fm-role";
@@ -381,7 +381,7 @@ declare const GROUP_ELEMENT_SCHEMAS: ReadonlyArray<Schema>;
381
381
 
382
382
  declare const FOOTNOTE_LINK_TAG = "FOOTNOTE1";
383
383
  declare const INLINEEQUATION_TAG = "INLINEEQUATION";
384
- declare const LINK_TAG = "LINK";
384
+ declare const LINK_TAG = "LINK1";
385
385
  declare const URI_TAG = "URI";
386
386
  declare const INLINE_ELEMENT_TAGS_ALLOWED_CHILDREN: {
387
387
  tagName: string;
package/dist/index.js CHANGED
@@ -300,7 +300,10 @@ var ATOM_TAGS_ALLOWED_CHILDREN = [
300
300
  { tagName: STRIKE_TAG, required: false },
301
301
  { tagName: SUB_TAG, required: false },
302
302
  { tagName: SUP_TAG, required: false },
303
- { tagName: HIGHLIGHTMARK_TAG, required: false }
303
+ { tagName: HIGHLIGHTMARK_TAG, required: false },
304
+ { tagName: SPAN_TAG, required: false },
305
+ { tagName: COMMENT_TAG, required: false },
306
+ { tagName: QUERY_TAG, required: false }
304
307
  ];
305
308
 
306
309
  // src/schema/elementSchemas/atoms/b.ts
@@ -335,7 +338,7 @@ var COMMENT_QUERY_SECTION_SCHEMA = createSchema({
335
338
  // src/schema/elementSchemas/inlineElements/inlineElementsTags.ts
336
339
  var FOOTNOTE_LINK_TAG = "FOOTNOTE1";
337
340
  var INLINEEQUATION_TAG = "INLINEEQUATION";
338
- var LINK_TAG = "LINK";
341
+ var LINK_TAG = "LINK1";
339
342
  var URI_TAG = "URI";
340
343
  var INLINE_ELEMENT_TAGS_ALLOWED_CHILDREN = [
341
344
  { tagName: FOOTNOTE_LINK_TAG, required: false },
@@ -738,7 +741,7 @@ var FIRSTNAME_SCHEMA = createSchema({
738
741
  tag: FIRSTNAME_TAG,
739
742
  requiredAttributes: [...ID_ATTRS],
740
743
  optionalAttributes: [],
741
- allowedChildTagNames: []
744
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
742
745
  });
743
746
 
744
747
  // src/schema/elementSchemas/elements/authors/surname.ts
@@ -747,7 +750,7 @@ var SURNAME_SCHEMA = createSchema({
747
750
  tag: SURNAME_TAG,
748
751
  requiredAttributes: [...ID_ATTRS],
749
752
  optionalAttributes: [],
750
- allowedChildTagNames: []
753
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
751
754
  });
752
755
 
753
756
  // src/schema/elementSchemas/elements/authors/honorific.ts
@@ -774,7 +777,7 @@ var EMAIL_SCHEMA = createSchema({
774
777
  tag: EMAIL_TAG,
775
778
  requiredAttributes: [...ID_ATTRS],
776
779
  optionalAttributes: [],
777
- allowedChildTagNames: []
780
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
778
781
  });
779
782
 
780
783
  // src/schema/elementSchemas/elements/authors/org.ts
@@ -816,7 +819,7 @@ var LINE_SCHEMA = createSchema({
816
819
  defaultValue: "add-element"
817
820
  }
818
821
  ],
819
- allowedChildTagNames: []
822
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
820
823
  });
821
824
 
822
825
  // src/schema/elementSchemas/elements/dialogue/speaker.ts
@@ -831,7 +834,7 @@ var SPEAKER_SCHEMA = createSchema({
831
834
  defaultValue: "add-element"
832
835
  }
833
836
  ],
834
- allowedChildTagNames: []
837
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
835
838
  });
836
839
 
837
840
  // src/schema/elementSchemas/elements/dialogue/dialogue.ts
@@ -927,7 +930,10 @@ var FIGSOURCE_SCHEMA = createSchema({
927
930
  tag: FIGSOURCE_TAG,
928
931
  requiredAttributes: [...ID_ATTRS],
929
932
  optionalAttributes: [],
930
- allowedChildTagNames: []
933
+ allowedChildTagNames: [
934
+ ...ATOM_TAGS_ALLOWED_CHILDREN,
935
+ ...INLINE_ELEMENT_TAGS_ALLOWED_CHILDREN
936
+ ]
931
937
  });
932
938
 
933
939
  // src/schema/elementSchemas/elements/figure/fignote.ts
@@ -936,10 +942,13 @@ var FIGNOTE_SCHEMA = createSchema({
936
942
  tag: FIGNOTE_TAG,
937
943
  requiredAttributes: [...ID_ATTRS],
938
944
  optionalAttributes: [],
939
- allowedChildTagNames: []
945
+ allowedChildTagNames: [
946
+ ...ATOM_TAGS_ALLOWED_CHILDREN,
947
+ ...INLINE_ELEMENT_TAGS_ALLOWED_CHILDREN
948
+ ]
940
949
  });
941
950
 
942
- // src/schema/elementSchemas/elements/figure/figure1.ts
951
+ // src/schema/elementSchemas/elements/figure/figure.ts
943
952
  var FIGURE_SCHEMA = createSchema({
944
953
  kind: "group",
945
954
  tag: FIGURE_TAG,
@@ -1027,16 +1036,16 @@ var KEYWORD_SCHEMA = createSchema({
1027
1036
  tag: KEYWORD_TAG,
1028
1037
  requiredAttributes: [...ID_ATTRS],
1029
1038
  optionalAttributes: ["data-pos"],
1030
- allowedChildTagNames: []
1039
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
1031
1040
  });
1032
1041
 
1033
1042
  // src/schema/elementSchemas/elements/keywords/punc.ts
1034
1043
  var PUNC_SCHEMA = createSchema({
1035
1044
  kind: "element",
1036
1045
  tag: PUNC_TAG,
1037
- requiredAttributes: [ID_ATTRS[0]],
1038
- optionalAttributes: [ID_ATTRS[1], "data-role"],
1039
- allowedChildTagNames: []
1046
+ requiredAttributes: [...ID_ATTRS],
1047
+ optionalAttributes: ["data-role"],
1048
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
1040
1049
  });
1041
1050
 
1042
1051
  // src/schema/elementSchemas/elements/label.ts
@@ -1052,7 +1061,7 @@ var LABEL_SCHEMA = createSchema({
1052
1061
  defaultValue: "false"
1053
1062
  }
1054
1063
  ],
1055
- allowedChildTagNames: []
1064
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
1056
1065
  });
1057
1066
 
1058
1067
  // src/schema/elementSchemas/elements/list/token.ts
@@ -1208,7 +1217,7 @@ var LRH_SCHEMA = createSchema({
1208
1217
  tag: LRH_TAG,
1209
1218
  requiredAttributes: [...ID_ATTRS],
1210
1219
  optionalAttributes: [],
1211
- allowedChildTagNames: []
1220
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
1212
1221
  });
1213
1222
 
1214
1223
  // src/schema/elementSchemas/elements/runningHeads/rrh.ts
@@ -1217,7 +1226,7 @@ var RRH_SCHEMA = createSchema({
1217
1226
  tag: RRH_TAG,
1218
1227
  requiredAttributes: [...ID_ATTRS],
1219
1228
  optionalAttributes: [],
1220
- allowedChildTagNames: []
1229
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
1221
1230
  });
1222
1231
 
1223
1232
  // src/schema/elementSchemas/elements/source.ts
@@ -1233,7 +1242,7 @@ var SOURCE_SCHEMA = createSchema({
1233
1242
  defaultValue: "add-element"
1234
1243
  }
1235
1244
  ],
1236
- allowedChildTagNames: []
1245
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
1237
1246
  });
1238
1247
 
1239
1248
  // src/schema/elementSchemas/elements/subtitle.ts
@@ -1248,7 +1257,7 @@ var SUBTITLE_SCHEMA = createSchema({
1248
1257
  defaultValue: "add-element"
1249
1258
  }
1250
1259
  ],
1251
- allowedChildTagNames: []
1260
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
1252
1261
  });
1253
1262
 
1254
1263
  // src/schema/elementSchemas/elements/table/tp.ts
@@ -1256,8 +1265,11 @@ var TP_SCHEMA = createSchema({
1256
1265
  kind: "element",
1257
1266
  tag: TP_TAG,
1258
1267
  requiredAttributes: [],
1259
- optionalAttributes: [ID_ATTRS[0], ID_ATTRS[1]],
1260
- allowedChildTagNames: []
1268
+ optionalAttributes: [...ID_ATTRS],
1269
+ allowedChildTagNames: [
1270
+ ...ATOM_TAGS_ALLOWED_CHILDREN,
1271
+ ...INLINE_ELEMENT_TAGS_ALLOWED_CHILDREN
1272
+ ]
1261
1273
  });
1262
1274
 
1263
1275
  // src/schema/elementSchemas/elements/table/td.ts
@@ -1278,7 +1290,7 @@ var TR_SCHEMA = createSchema({
1278
1290
  kind: "group",
1279
1291
  tag: TR_TAG,
1280
1292
  requiredAttributes: [],
1281
- optionalAttributes: [...LAYOUT_ATTRIBUTES, ID_ATTRS[0], ID_ATTRS[1], "width"],
1293
+ optionalAttributes: [...LAYOUT_ATTRIBUTES, ...ID_ATTRS, "width"],
1282
1294
  allowedChildTagNames: [{ tagName: TD_TAG, required: true }]
1283
1295
  });
1284
1296
 
@@ -1287,7 +1299,7 @@ var THEAD_SCHEMA = createSchema({
1287
1299
  kind: "element",
1288
1300
  tag: THEAD_TAG,
1289
1301
  requiredAttributes: [],
1290
- optionalAttributes: [ID_ATTRS[0], ID_ATTRS[1]],
1302
+ optionalAttributes: [...ID_ATTRS],
1291
1303
  allowedChildTagNames: [{ tagName: TR_TAG, required: true }]
1292
1304
  });
1293
1305
 
@@ -1296,7 +1308,7 @@ var TBODY_SCHEMA = createSchema({
1296
1308
  kind: "group",
1297
1309
  tag: TBODY_TAG,
1298
1310
  requiredAttributes: [],
1299
- optionalAttributes: [ID_ATTRS[0], ID_ATTRS[1]],
1311
+ optionalAttributes: [...ID_ATTRS],
1300
1312
  allowedChildTagNames: [{ tagName: TR_TAG, required: true }]
1301
1313
  });
1302
1314
 
@@ -1305,7 +1317,7 @@ var HTML_TABLE_SCHEMA = createSchema({
1305
1317
  kind: "group",
1306
1318
  tag: HTML_TABLE_TAG,
1307
1319
  requiredAttributes: [],
1308
- optionalAttributes: [ID_ATTRS[0], ID_ATTRS[1]],
1320
+ optionalAttributes: [...ID_ATTRS],
1309
1321
  allowedChildTagNames: [
1310
1322
  { tagName: THEAD_TAG, required: false },
1311
1323
  { tagName: TBODY_TAG, required: true }
@@ -1327,7 +1339,10 @@ var TBLFN_SCHEMA = createSchema({
1327
1339
  tag: TBLFN_TAG,
1328
1340
  requiredAttributes: [...ID_ATTRS],
1329
1341
  optionalAttributes: [],
1330
- allowedChildTagNames: []
1342
+ allowedChildTagNames: [
1343
+ ...ATOM_TAGS_ALLOWED_CHILDREN,
1344
+ ...INLINE_ELEMENT_TAGS_ALLOWED_CHILDREN
1345
+ ]
1331
1346
  });
1332
1347
 
1333
1348
  // src/schema/elementSchemas/elements/table/tblsource.ts
@@ -1336,7 +1351,7 @@ var TBLSOURCE_SCHEMA = createSchema({
1336
1351
  tag: TBLSOURCE_TAG,
1337
1352
  requiredAttributes: [],
1338
1353
  optionalAttributes: [],
1339
- allowedChildTagNames: []
1354
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
1340
1355
  });
1341
1356
 
1342
1357
  // src/schema/elementSchemas/elements/table/table1.ts
@@ -1616,6 +1631,7 @@ var HEADING_SCHEMA = createSchema({
1616
1631
  optionalAttributes: [...TRACK_CHANGES_ATTRS],
1617
1632
  allowedChildTagNames: [
1618
1633
  { tagName: TITLE_TAG, required: false },
1634
+ { tagName: LABEL_TAG, required: false },
1619
1635
  { tagName: PARA_TAG, required: false },
1620
1636
  { tagName: SUBTITLE_TAG, required: false },
1621
1637
  { tagName: SIDEBAR_TAG, required: false },
@@ -1628,7 +1644,8 @@ var HEADING_SCHEMA = createSchema({
1628
1644
  { tagName: APPENDIX_TAG, required: false },
1629
1645
  { tagName: TABLE_TAG, required: false },
1630
1646
  { tagName: FIGURE_TAG, required: false },
1631
- { tagName: SECTION_TAG, required: false }
1647
+ { tagName: SECTION_TAG, required: false },
1648
+ { tagName: INFO_TAG, required: false }
1632
1649
  ]
1633
1650
  });
1634
1651
 
@@ -1748,10 +1765,14 @@ var SCHEMA_MAP = new Map(
1748
1765
  // src/schema/shared/ignoredElements.ts
1749
1766
  var IGNORED_ELEMENT_SELECTORS = [
1750
1767
  "span.rhlabel",
1751
- "span.abstractlabel",
1768
+ "span.printlabel",
1752
1769
  "span.refIcon",
1753
1770
  "span.missLink",
1754
- "span.ref-drag"
1771
+ "span.ref-drag",
1772
+ "inlineequation",
1773
+ // TODO: remove this once we have a proper inlineequation schema
1774
+ "equation"
1775
+ // TODO: remove this once we have a proper equation schema
1755
1776
  ];
1756
1777
 
1757
1778
  // src/schema/shared/ignoredAttributes.ts
package/dist/index.mjs CHANGED
@@ -84,7 +84,10 @@ var ATOM_TAGS_ALLOWED_CHILDREN = [
84
84
  { tagName: STRIKE_TAG, required: false },
85
85
  { tagName: SUB_TAG, required: false },
86
86
  { tagName: SUP_TAG, required: false },
87
- { tagName: HIGHLIGHTMARK_TAG, required: false }
87
+ { tagName: HIGHLIGHTMARK_TAG, required: false },
88
+ { tagName: SPAN_TAG, required: false },
89
+ { tagName: COMMENT_TAG, required: false },
90
+ { tagName: QUERY_TAG, required: false }
88
91
  ];
89
92
 
90
93
  // src/schema/elementSchemas/atoms/b.ts
@@ -119,7 +122,7 @@ var COMMENT_QUERY_SECTION_SCHEMA = createSchema({
119
122
  // src/schema/elementSchemas/inlineElements/inlineElementsTags.ts
120
123
  var FOOTNOTE_LINK_TAG = "FOOTNOTE1";
121
124
  var INLINEEQUATION_TAG = "INLINEEQUATION";
122
- var LINK_TAG = "LINK";
125
+ var LINK_TAG = "LINK1";
123
126
  var URI_TAG = "URI";
124
127
  var INLINE_ELEMENT_TAGS_ALLOWED_CHILDREN = [
125
128
  { tagName: FOOTNOTE_LINK_TAG, required: false },
@@ -522,7 +525,7 @@ var FIRSTNAME_SCHEMA = createSchema({
522
525
  tag: FIRSTNAME_TAG,
523
526
  requiredAttributes: [...ID_ATTRS],
524
527
  optionalAttributes: [],
525
- allowedChildTagNames: []
528
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
526
529
  });
527
530
 
528
531
  // src/schema/elementSchemas/elements/authors/surname.ts
@@ -531,7 +534,7 @@ var SURNAME_SCHEMA = createSchema({
531
534
  tag: SURNAME_TAG,
532
535
  requiredAttributes: [...ID_ATTRS],
533
536
  optionalAttributes: [],
534
- allowedChildTagNames: []
537
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
535
538
  });
536
539
 
537
540
  // src/schema/elementSchemas/elements/authors/honorific.ts
@@ -558,7 +561,7 @@ var EMAIL_SCHEMA = createSchema({
558
561
  tag: EMAIL_TAG,
559
562
  requiredAttributes: [...ID_ATTRS],
560
563
  optionalAttributes: [],
561
- allowedChildTagNames: []
564
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
562
565
  });
563
566
 
564
567
  // src/schema/elementSchemas/elements/authors/org.ts
@@ -600,7 +603,7 @@ var LINE_SCHEMA = createSchema({
600
603
  defaultValue: "add-element"
601
604
  }
602
605
  ],
603
- allowedChildTagNames: []
606
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
604
607
  });
605
608
 
606
609
  // src/schema/elementSchemas/elements/dialogue/speaker.ts
@@ -615,7 +618,7 @@ var SPEAKER_SCHEMA = createSchema({
615
618
  defaultValue: "add-element"
616
619
  }
617
620
  ],
618
- allowedChildTagNames: []
621
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
619
622
  });
620
623
 
621
624
  // src/schema/elementSchemas/elements/dialogue/dialogue.ts
@@ -711,7 +714,10 @@ var FIGSOURCE_SCHEMA = createSchema({
711
714
  tag: FIGSOURCE_TAG,
712
715
  requiredAttributes: [...ID_ATTRS],
713
716
  optionalAttributes: [],
714
- allowedChildTagNames: []
717
+ allowedChildTagNames: [
718
+ ...ATOM_TAGS_ALLOWED_CHILDREN,
719
+ ...INLINE_ELEMENT_TAGS_ALLOWED_CHILDREN
720
+ ]
715
721
  });
716
722
 
717
723
  // src/schema/elementSchemas/elements/figure/fignote.ts
@@ -720,10 +726,13 @@ var FIGNOTE_SCHEMA = createSchema({
720
726
  tag: FIGNOTE_TAG,
721
727
  requiredAttributes: [...ID_ATTRS],
722
728
  optionalAttributes: [],
723
- allowedChildTagNames: []
729
+ allowedChildTagNames: [
730
+ ...ATOM_TAGS_ALLOWED_CHILDREN,
731
+ ...INLINE_ELEMENT_TAGS_ALLOWED_CHILDREN
732
+ ]
724
733
  });
725
734
 
726
- // src/schema/elementSchemas/elements/figure/figure1.ts
735
+ // src/schema/elementSchemas/elements/figure/figure.ts
727
736
  var FIGURE_SCHEMA = createSchema({
728
737
  kind: "group",
729
738
  tag: FIGURE_TAG,
@@ -811,16 +820,16 @@ var KEYWORD_SCHEMA = createSchema({
811
820
  tag: KEYWORD_TAG,
812
821
  requiredAttributes: [...ID_ATTRS],
813
822
  optionalAttributes: ["data-pos"],
814
- allowedChildTagNames: []
823
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
815
824
  });
816
825
 
817
826
  // src/schema/elementSchemas/elements/keywords/punc.ts
818
827
  var PUNC_SCHEMA = createSchema({
819
828
  kind: "element",
820
829
  tag: PUNC_TAG,
821
- requiredAttributes: [ID_ATTRS[0]],
822
- optionalAttributes: [ID_ATTRS[1], "data-role"],
823
- allowedChildTagNames: []
830
+ requiredAttributes: [...ID_ATTRS],
831
+ optionalAttributes: ["data-role"],
832
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
824
833
  });
825
834
 
826
835
  // src/schema/elementSchemas/elements/label.ts
@@ -836,7 +845,7 @@ var LABEL_SCHEMA = createSchema({
836
845
  defaultValue: "false"
837
846
  }
838
847
  ],
839
- allowedChildTagNames: []
848
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
840
849
  });
841
850
 
842
851
  // src/schema/elementSchemas/elements/list/token.ts
@@ -992,7 +1001,7 @@ var LRH_SCHEMA = createSchema({
992
1001
  tag: LRH_TAG,
993
1002
  requiredAttributes: [...ID_ATTRS],
994
1003
  optionalAttributes: [],
995
- allowedChildTagNames: []
1004
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
996
1005
  });
997
1006
 
998
1007
  // src/schema/elementSchemas/elements/runningHeads/rrh.ts
@@ -1001,7 +1010,7 @@ var RRH_SCHEMA = createSchema({
1001
1010
  tag: RRH_TAG,
1002
1011
  requiredAttributes: [...ID_ATTRS],
1003
1012
  optionalAttributes: [],
1004
- allowedChildTagNames: []
1013
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
1005
1014
  });
1006
1015
 
1007
1016
  // src/schema/elementSchemas/elements/source.ts
@@ -1017,7 +1026,7 @@ var SOURCE_SCHEMA = createSchema({
1017
1026
  defaultValue: "add-element"
1018
1027
  }
1019
1028
  ],
1020
- allowedChildTagNames: []
1029
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
1021
1030
  });
1022
1031
 
1023
1032
  // src/schema/elementSchemas/elements/subtitle.ts
@@ -1032,7 +1041,7 @@ var SUBTITLE_SCHEMA = createSchema({
1032
1041
  defaultValue: "add-element"
1033
1042
  }
1034
1043
  ],
1035
- allowedChildTagNames: []
1044
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
1036
1045
  });
1037
1046
 
1038
1047
  // src/schema/elementSchemas/elements/table/tp.ts
@@ -1040,8 +1049,11 @@ var TP_SCHEMA = createSchema({
1040
1049
  kind: "element",
1041
1050
  tag: TP_TAG,
1042
1051
  requiredAttributes: [],
1043
- optionalAttributes: [ID_ATTRS[0], ID_ATTRS[1]],
1044
- allowedChildTagNames: []
1052
+ optionalAttributes: [...ID_ATTRS],
1053
+ allowedChildTagNames: [
1054
+ ...ATOM_TAGS_ALLOWED_CHILDREN,
1055
+ ...INLINE_ELEMENT_TAGS_ALLOWED_CHILDREN
1056
+ ]
1045
1057
  });
1046
1058
 
1047
1059
  // src/schema/elementSchemas/elements/table/td.ts
@@ -1062,7 +1074,7 @@ var TR_SCHEMA = createSchema({
1062
1074
  kind: "group",
1063
1075
  tag: TR_TAG,
1064
1076
  requiredAttributes: [],
1065
- optionalAttributes: [...LAYOUT_ATTRIBUTES, ID_ATTRS[0], ID_ATTRS[1], "width"],
1077
+ optionalAttributes: [...LAYOUT_ATTRIBUTES, ...ID_ATTRS, "width"],
1066
1078
  allowedChildTagNames: [{ tagName: TD_TAG, required: true }]
1067
1079
  });
1068
1080
 
@@ -1071,7 +1083,7 @@ var THEAD_SCHEMA = createSchema({
1071
1083
  kind: "element",
1072
1084
  tag: THEAD_TAG,
1073
1085
  requiredAttributes: [],
1074
- optionalAttributes: [ID_ATTRS[0], ID_ATTRS[1]],
1086
+ optionalAttributes: [...ID_ATTRS],
1075
1087
  allowedChildTagNames: [{ tagName: TR_TAG, required: true }]
1076
1088
  });
1077
1089
 
@@ -1080,7 +1092,7 @@ var TBODY_SCHEMA = createSchema({
1080
1092
  kind: "group",
1081
1093
  tag: TBODY_TAG,
1082
1094
  requiredAttributes: [],
1083
- optionalAttributes: [ID_ATTRS[0], ID_ATTRS[1]],
1095
+ optionalAttributes: [...ID_ATTRS],
1084
1096
  allowedChildTagNames: [{ tagName: TR_TAG, required: true }]
1085
1097
  });
1086
1098
 
@@ -1089,7 +1101,7 @@ var HTML_TABLE_SCHEMA = createSchema({
1089
1101
  kind: "group",
1090
1102
  tag: HTML_TABLE_TAG,
1091
1103
  requiredAttributes: [],
1092
- optionalAttributes: [ID_ATTRS[0], ID_ATTRS[1]],
1104
+ optionalAttributes: [...ID_ATTRS],
1093
1105
  allowedChildTagNames: [
1094
1106
  { tagName: THEAD_TAG, required: false },
1095
1107
  { tagName: TBODY_TAG, required: true }
@@ -1111,7 +1123,10 @@ var TBLFN_SCHEMA = createSchema({
1111
1123
  tag: TBLFN_TAG,
1112
1124
  requiredAttributes: [...ID_ATTRS],
1113
1125
  optionalAttributes: [],
1114
- allowedChildTagNames: []
1126
+ allowedChildTagNames: [
1127
+ ...ATOM_TAGS_ALLOWED_CHILDREN,
1128
+ ...INLINE_ELEMENT_TAGS_ALLOWED_CHILDREN
1129
+ ]
1115
1130
  });
1116
1131
 
1117
1132
  // src/schema/elementSchemas/elements/table/tblsource.ts
@@ -1120,7 +1135,7 @@ var TBLSOURCE_SCHEMA = createSchema({
1120
1135
  tag: TBLSOURCE_TAG,
1121
1136
  requiredAttributes: [],
1122
1137
  optionalAttributes: [],
1123
- allowedChildTagNames: []
1138
+ allowedChildTagNames: [...ATOM_TAGS_ALLOWED_CHILDREN]
1124
1139
  });
1125
1140
 
1126
1141
  // src/schema/elementSchemas/elements/table/table1.ts
@@ -1400,6 +1415,7 @@ var HEADING_SCHEMA = createSchema({
1400
1415
  optionalAttributes: [...TRACK_CHANGES_ATTRS],
1401
1416
  allowedChildTagNames: [
1402
1417
  { tagName: TITLE_TAG, required: false },
1418
+ { tagName: LABEL_TAG, required: false },
1403
1419
  { tagName: PARA_TAG, required: false },
1404
1420
  { tagName: SUBTITLE_TAG, required: false },
1405
1421
  { tagName: SIDEBAR_TAG, required: false },
@@ -1412,7 +1428,8 @@ var HEADING_SCHEMA = createSchema({
1412
1428
  { tagName: APPENDIX_TAG, required: false },
1413
1429
  { tagName: TABLE_TAG, required: false },
1414
1430
  { tagName: FIGURE_TAG, required: false },
1415
- { tagName: SECTION_TAG, required: false }
1431
+ { tagName: SECTION_TAG, required: false },
1432
+ { tagName: INFO_TAG, required: false }
1416
1433
  ]
1417
1434
  });
1418
1435
 
@@ -1532,10 +1549,14 @@ var SCHEMA_MAP = new Map(
1532
1549
  // src/schema/shared/ignoredElements.ts
1533
1550
  var IGNORED_ELEMENT_SELECTORS = [
1534
1551
  "span.rhlabel",
1535
- "span.abstractlabel",
1552
+ "span.printlabel",
1536
1553
  "span.refIcon",
1537
1554
  "span.missLink",
1538
- "span.ref-drag"
1555
+ "span.ref-drag",
1556
+ "inlineequation",
1557
+ // TODO: remove this once we have a proper inlineequation schema
1558
+ "equation"
1559
+ // TODO: remove this once we have a proper equation schema
1539
1560
  ];
1540
1561
 
1541
1562
  // src/schema/shared/ignoredAttributes.ts
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pro-editor-schema",
3
- "version": "0.1.0",
3
+ "version": "0.1.12",
4
4
  "description": "Pro Editor XML schemas",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",