@gmb/bitmark-parser-generator 4.9.0 → 4.11.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.
@@ -3,7 +3,7 @@
3
3
  <head>
4
4
  <meta charset="UTF-8"/>
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1"/>
6
- <title>@gmb/bitmark-parser-generator [15 Sep 2025 at 01:33]</title>
6
+ <title>@gmb/bitmark-parser-generator [23 Sep 2025 at 21:32]</title>
7
7
  <link rel="shortcut icon" href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAMAAACdt4HsAAABrVBMVEUAAAD///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////+O1foceMD///+J0/qK1Pr7/v8Xdr/9///W8P4UdL7L7P0Scr2r4Pyj3vwad8D5/f/2/f+55f3E6f34+/2H0/ojfMKpzOd0rNgQcb3F3O/j9f7c8v6g3Pz0/P/w+v/q+P7n9v6T1/uQ1vuE0vqLut/y+v+Z2fvt+f+15Pzv9fuc2/vR7v2V2Pvd6/bg9P7I6/285/2y4/yp3/zp8vk8i8kqgMT7/P31+fyv4vxGkcz6/P6/6P3j7vfS5PNnpNUxhcbO7f7F6v3O4vHK3/DA2u631Ouy0eqXweKJud5wqthfoNMMbLvY8f73+v2dxeR8sNtTmdDx9/zX6PSjyeaCtd1YnNGX2PuQveCGt95Nls42h8dLlM3F4vBtAAAAM3RSTlMAAyOx0/sKBvik8opWGBMOAe3l1snDm2E9LSb06eHcu5JpHbarfHZCN9CBb08zzkdNS0kYaptYAAAFV0lEQVRYw92X51/aYBDHHS2O2qqttVbrqNq9m+TJIAYIShBkWwqIiCgoWvfeq7Z2/s29hyQNyUcR7LveGwVyXy6XH8/9rqxglLfUPLxVduUor3h0rfp2TYvpivk37929TkG037hffoX0+peVtZQc1589rigVUdXS/ABSAyEmGIO/1XfvldSK8vs3OqB6u3m0nxmIrvgB0dj7rr7Y9IbuF68hnfFaiHA/sxqm0wciIG43P60qKv9WXWc1RXGh/mFESFABTSBi0sNAKzqet17eCtOb3kZIDwxEEU0oAIJGYxNBDhBND29e0rtXXbcpuPmED9IhEAAQ/AXEaF8EPmnrrKsv0LvWR3fg5sWDNAFZOgAgaKvZDogHNU9MFwnnYROkc56RD5CjAbQX9Ow4g7upCsvYu55aSI/Nj0H1akgKQEUM94dwK65hYRmFU9MIcH/fqJYOZYcnuJSU/waKDgTOEVaVKhwrTRP5XzgSpAITYzom7UvkhFX5VutmxeNnWDjjswTKTyfgluNDGbUpWissXhF3s7mlSml+czWkg3D0l1nNjGNjz3myOQOa1KM/jOS6ebdbAVTCi4gljHSFrviza7tOgRWcS0MOUX9zdNgag5w7rRqA44Lzw0hr1WqES36dFliSJFlh2rXIae3FFcDDgKdxrUIDePr8jGcSClV1u7A9xeN0ModY/pHMxmR1EzRh8TJiwqsHmKW0l4FCEZI+jHio+JdPPE9qwQtTRxku2D8sIeRL2LnxWSllANCQGOIiqVHAz2ye2JR0DcH+HoxDkaADLjgxjKQ+AwCX/g0+DNgdG0ukYCONAe+dbc2IAc6fwt1ARoDSezNHxV2Cmzwv3O6lDMV55edBGwGK9n1+x2F8EDfAGCxug8MhpsMEcTEAWf3rx2vZhe/LAmtIn/6apE6PN0ULKgywD9mmdxbmFl3OvD5AS5fW5zLbv/YHmcsBTjf/afDz3MaZTVCfAP9z6/Bw6ycv8EUBWJIn9zYcoAWWlW9+OzO3vkTy8H+RANLmdrpOuYWdZYEXpo+TlCJrW5EARb7fF+bWdqf3hhyZI1nWJQHgznErZhbjoEsWqi8dQNoE294aldzFurwSABL2XXMf9+H1VQGke9exw5P/AnA5Pv5ngMul7LOvO922iwACu8WkCwLCafvM4CeWPxfA8lNHcWZSoi8EwMAIciKX2Z4SWCMAa3snCZ/G4EA8D6CMLNFsGQhkkz/gQNEBbPCbWsxGUpYVu3z8IyNAknwJkfPMEhLyrdi5RTyUVACkw4GSFRNWJNEW+fgPGwHD8/JxnRuLabN4CGNRkAE23na2+VmEAUmrYymSGjMAYqH84YUIyzgzs3XC7gNgH36Vcc4zKY9o9fgPBXUAiHHwVboBHGLiX6Zcjp1f2wu4tvzZKo0ecPnDtQYDQvJXaBeNzce45Fp28ZQLrEZVuFqgBwOalArKXnW1UzlnSusQKJqKYNuz4tOnI6sZG4zanpemv+7ySU2jbA9h6uhcgpfy6G2PahirDZ6zvq6zDduMVFTKvzw8wgyEdelwY9in3XkEPs3osJuwRQ4qTkfzifndg9Gfc4pdsu82+tTnHZTBa2EAMrqr2t43pguc8tNm7JQVQ2S0ukj2d22dhXYP0/veWtwKrCkNoNimAN5+Xr/oLrxswKbVJjteWrX7eR63o4j9q0GxnaBdWgGA5VStpanIjQmEhV0/nVt5VOFUvix6awJhPcAaTEShgrG+iGyvb5a0Ndb1YGHFPEwoqAinoaykaID1o1pdPNu7XsnCKQ3R+hwWIIhGvORcJUBYXe3Xa3vq/mF/N9V13ugufMkfXn+KHsRD0B8AAAAASUVORK5CYII=" type="image/x-icon" />
8
8
 
9
9
  <script>
@@ -31,7 +31,7 @@
31
31
  <body>
32
32
  <div id="app"></div>
33
33
  <script>
34
- window.chartData = [{"label":"bitmark-parser-generator.min.js","isAsset":true,"statSize":1151858,"parsedSize":500933,"gzipSize":97722,"groups":[{"label":"dist/browser/cjs","path":"./dist/browser/cjs","statSize":1144878,"groups":[{"id":922,"label":"index.cjs","path":"./dist/browser/cjs/index.cjs","statSize":1144878,"parsedSize":500829,"gzipSize":97722}],"parsedSize":500829,"gzipSize":97722},{"label":"node_modules/@ncoderz/superenum/dist/esm","path":"./node_modules/@ncoderz/superenum/dist/esm","statSize":6980,"groups":[{"id":718,"label":"superenum.js","path":"./node_modules/@ncoderz/superenum/dist/esm/superenum.js","statSize":6980}],"parsedSize":0,"gzipSize":0}],"isInitialByEntrypoint":{"main":true}}];
34
+ window.chartData = [{"label":"bitmark-parser-generator.min.js","isAsset":true,"statSize":1155987,"parsedSize":503736,"gzipSize":98262,"groups":[{"label":"dist/browser/cjs","path":"./dist/browser/cjs","statSize":1149007,"groups":[{"id":922,"label":"index.cjs","path":"./dist/browser/cjs/index.cjs","statSize":1149007,"parsedSize":503632,"gzipSize":98262}],"parsedSize":503632,"gzipSize":98262},{"label":"node_modules/@ncoderz/superenum/dist/esm","path":"./node_modules/@ncoderz/superenum/dist/esm","statSize":6980,"groups":[{"id":718,"label":"superenum.js","path":"./node_modules/@ncoderz/superenum/dist/esm/superenum.js","statSize":6980}],"parsedSize":0,"gzipSize":0}],"isInitialByEntrypoint":{"main":true}}];
35
35
  window.entrypoints = ["main"];
36
36
  window.defaultSizes = "stat";
37
37
  </script>
@@ -79,6 +79,7 @@ var BitType = (0, import_superenum.superenum)({
79
79
  appAiPrompt: "app-ai-prompt",
80
80
  appBitmarkFromEditor: "app-bitmark-from-editor",
81
81
  appBitmarkFromJavascript: "app-bitmark-from-javascript",
82
+ appCalculatorLatex: "app-calculator-latex",
82
83
  appCodeCell: "app-code-cell",
83
84
  appCodeEditor: "app-code-editor",
84
85
  appCodeIde: "app-code-ide",
@@ -498,6 +499,10 @@ var BitType = (0, import_superenum.superenum)({
498
499
  reviewRequestForReviewNote: "review-request-for-review-note",
499
500
  reviewReviewerNote: "review-reviewer-note",
500
501
  sampleSolution: "sample-solution",
502
+ sandbox: "sandbox",
503
+ sandboxOutputJson: "sandbox-output-json",
504
+ sandboxOutputMarkup: "sandbox-output-markup",
505
+ sandboxOutputRender: "sandbox-output-render",
501
506
  scorm: "scorm",
502
507
  screenshot: "screenshot",
503
508
  selfAssessment: "self-assessment",
@@ -1199,6 +1204,7 @@ var propertyKeys = {
1199
1204
  property_focusX: "@focusX",
1200
1205
  property_focusY: "@focusY",
1201
1206
  property_format: "@format",
1207
+ property_formula: "@formula",
1202
1208
  property_fullName: "@fullName",
1203
1209
  property_groupTag: "@groupTag",
1204
1210
  property_handInAcceptFileType: "@handInAcceptFileType",
@@ -1302,6 +1308,7 @@ var propertyKeys = {
1302
1308
  property_siteName: "@siteName",
1303
1309
  property_size: "@size",
1304
1310
  property_slug: "@slug",
1311
+ property_sourceDocument: "@sourceDocument",
1305
1312
  property_spaceId: "@spaceId",
1306
1313
  property_src1x: "@src1x",
1307
1314
  property_src2x: "@src2x",
@@ -2854,7 +2861,7 @@ var GROUPS = {
2854
2861
  },
2855
2862
  [ConfigKey.group_standardItemLeadInstructionHint]: {
2856
2863
  type: GroupConfigType.standard,
2857
- description: "Standard group for item, lead, page number, margin number, instruction and hint tags",
2864
+ description: "Standard group for item, lead, page number, source page number, margin number, instruction and hint tags",
2858
2865
  tags: [
2859
2866
  {
2860
2867
  key: ConfigKey.tag_item,
@@ -2862,8 +2869,8 @@ var GROUPS = {
2862
2869
  chain: [
2863
2870
  {
2864
2871
  key: ConfigKey.tag_item,
2865
- description: "The lead, page number, and margin number for the bit",
2866
- maxCount: 3
2872
+ description: "The lead, page number, source page number, and margin number for the bit",
2873
+ maxCount: 4
2867
2874
  }
2868
2875
  ]
2869
2876
  },
@@ -3258,6 +3265,11 @@ var GROUPS = {
3258
3265
  key: ConfigKey.property_maxTocChapterLevel,
3259
3266
  description: "The maximum table of contents chapter level",
3260
3267
  format: TagFormat.number
3268
+ },
3269
+ {
3270
+ key: ConfigKey.property_sourceDocument,
3271
+ description: "Url of the source document for the book (for example, a PDF file)",
3272
+ format: TagFormat.plainText
3261
3273
  }
3262
3274
  ]
3263
3275
  },
@@ -5123,6 +5135,26 @@ var BITS = {
5123
5135
  baseBitType: BitType.code,
5124
5136
  description: "Standard output bit, used to display standard output from code snippets"
5125
5137
  },
5138
+ [BitType.sandbox]: {
5139
+ since: "4.10.0",
5140
+ baseBitType: BitType.code,
5141
+ description: "A sandbox bit, used to create a sandboxed environment for code execution"
5142
+ },
5143
+ [BitType.sandboxOutputJson]: {
5144
+ since: "4.10.0",
5145
+ baseBitType: BitType.code,
5146
+ description: "A sandbox output JSON bit, used to display JSON output from sandboxed code"
5147
+ },
5148
+ [BitType.sandboxOutputMarkup]: {
5149
+ since: "4.10.0",
5150
+ baseBitType: BitType.code,
5151
+ description: "A sandbox output markup bit, used to display markup output from sandboxed code"
5152
+ },
5153
+ [BitType.sandboxOutputRender]: {
5154
+ since: "4.10.0",
5155
+ baseBitType: BitType.code,
5156
+ description: "A sandbox output render bit, used to display rendered output from sandboxed code"
5157
+ },
5126
5158
  [BitType.step]: {
5127
5159
  since: "1.5.1",
5128
5160
  baseBitType: BitType.article,
@@ -6118,6 +6150,18 @@ var BITS = {
6118
6150
  }
6119
6151
  ]
6120
6152
  },
6153
+ [BitType.appCalculatorLatex]: {
6154
+ since: "4.10.0",
6155
+ baseBitType: BitType.article,
6156
+ description: "A LaTeX calculator bit, used to create a calculator that can interpret LaTeX expressions",
6157
+ tags: [
6158
+ {
6159
+ key: ConfigKey.property_formula,
6160
+ description: "The LaTeX formula for the calculator, used to define the calculation logic",
6161
+ format: TagFormat.plainText
6162
+ }
6163
+ ]
6164
+ },
6121
6165
  [BitType.container]: {
6122
6166
  since: "1.9.0",
6123
6167
  baseBitType: BitType.article,
@@ -9133,7 +9177,7 @@ var instance2 = new Config();
9133
9177
  // src/generated/package_info.ts
9134
9178
  var PACKAGE_INFO = {
9135
9179
  "name": "@gmb/bitmark-parser-generator",
9136
- "version": "4.9.0",
9180
+ "version": "4.11.0",
9137
9181
  "author": "Get More Brain Ltd",
9138
9182
  "license": "ISC",
9139
9183
  "description": "A bitmark parser and generator using Peggy.js"
@@ -9541,8 +9585,6 @@ var NodeType = (0, import_superenum20.superenum)({
9541
9585
  botValue: "botValue",
9542
9586
  bubbleTag: "bubbleTag",
9543
9587
  bubbleTagValue: "bubbleTagValue",
9544
- extractorTag: "extractorTag",
9545
- extractorTagValue: "extractorTagValue",
9546
9588
  buttonCaption: "buttonCaption",
9547
9589
  buttonCaptionValue: "buttonCaptionValue",
9548
9590
  callToActionUrl: "callToActionUrl",
@@ -9640,6 +9682,8 @@ var NodeType = (0, import_superenum20.superenum)({
9640
9682
  externalIdValue: "externalIdValue",
9641
9683
  externalLink: "externalLink",
9642
9684
  externalLinkText: "externalLinkText",
9685
+ extractorTag: "extractorTag",
9686
+ extractorTagValue: "extractorTagValue",
9643
9687
  extraProperties: "extraProperties",
9644
9688
  feedback: "feedback",
9645
9689
  feedbackEngine: "feedbackEngine",
@@ -9659,6 +9703,8 @@ var NodeType = (0, import_superenum20.superenum)({
9659
9703
  footerText: "footerText",
9660
9704
  forKeys: "forKeys",
9661
9705
  format: "format",
9706
+ formula: "formula",
9707
+ formulaValue: "formulaValue",
9662
9708
  forValues: "forValues",
9663
9709
  forValuesValue: "forValuesValue",
9664
9710
  fullName: "fullName",
@@ -9922,15 +9968,18 @@ var NodeType = (0, import_superenum20.superenum)({
9922
9968
  solution: "solution",
9923
9969
  solutions: "solutions",
9924
9970
  solutionsValue: "solutionsValue",
9971
+ sourceDocument: "sourceDocument",
9972
+ sourceDocumentValue: "sourceDocumentValue",
9973
+ sourcePageNumber: "sourcePageNumber",
9925
9974
  spaceId: "spaceId",
9926
9975
  spaceIdValue: "spaceIdValue",
9927
9976
  src: "src",
9928
- srcAlt: "srcAlt",
9929
- srcAltValue: "srcAltValue",
9930
9977
  src1x: "src1x",
9931
9978
  src2x: "src2x",
9932
9979
  src3x: "src3x",
9933
9980
  src4x: "src4x",
9981
+ srcAlt: "srcAlt",
9982
+ srcAltValue: "srcAltValue",
9934
9983
  start: "start",
9935
9984
  statement: "statement",
9936
9985
  statements: "statements",
@@ -22930,6 +22979,12 @@ var Builder = class extends BaseBuilder {
22930
22979
  data.maxTocChapterLevel,
22931
22980
  options
22932
22981
  ),
22982
+ sourceDocument: this.toAstProperty(
22983
+ bitType,
22984
+ ConfigKey.property_sourceDocument,
22985
+ data.sourceDocument,
22986
+ options
22987
+ ),
22933
22988
  tocResource: this.toAstProperty(
22934
22989
  bitType,
22935
22990
  ConfigKey.property_tocResource,
@@ -22979,6 +23034,7 @@ var Builder = class extends BaseBuilder {
22979
23034
  data.ratingLevelSelected,
22980
23035
  options
22981
23036
  ),
23037
+ formula: this.toAstProperty(bitType, ConfigKey.property_formula, data.formula, options),
22982
23038
  markConfig: this.buildMarkConfigs(context, data.markConfig),
22983
23039
  imageSource: this.buildImageSource(context, data.imageSource),
22984
23040
  person: this.buildPerson(context, data.person),
@@ -23013,6 +23069,7 @@ var Builder = class extends BaseBuilder {
23013
23069
  item: this.handleJsonText(context, TextLocation2.tag, data.item),
23014
23070
  lead: this.handleJsonText(context, TextLocation2.tag, data.lead),
23015
23071
  pageNumber: this.handleJsonText(context, TextLocation2.tag, data.pageNumber),
23072
+ sourcePageNumber: this.handleJsonText(context, TextLocation2.tag, data.sourcePageNumber),
23016
23073
  marginNumber: this.handleJsonText(context, TextLocation2.tag, data.marginNumber),
23017
23074
  hint: this.handleJsonText(context, TextLocation2.tag, data.hint),
23018
23075
  instruction: this.handleJsonText(context, TextLocation2.tag, data.instruction),
@@ -23115,7 +23172,15 @@ var Builder = class extends BaseBuilder {
23115
23172
  objectUtils.removeUnwantedProperties(node, {
23116
23173
  ignoreAllFalse: true,
23117
23174
  ignoreUndefined: ["example"],
23118
- ignoreEmptyArrays: ["item", "lead", "pageNumber", "marginNumber", "hint", "instruction"]
23175
+ ignoreEmptyArrays: [
23176
+ "item",
23177
+ "lead",
23178
+ "pageNumber",
23179
+ "sourcePageNumber",
23180
+ "marginNumber",
23181
+ "hint",
23182
+ "instruction"
23183
+ ]
23119
23184
  });
23120
23185
  return nodeValidator.validateBit(node);
23121
23186
  }
@@ -25428,6 +25493,7 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
25428
25493
  if (this.isEmptyText(item)) return false;
25429
25494
  if (!this.isEmptyText(parent?.value?.lead)) return true;
25430
25495
  if (!this.isEmptyText(parent?.value?.pageNumber)) return true;
25496
+ if (!this.isEmptyText(parent?.value?.sourcePageNumber)) return true;
25431
25497
  if (!this.isEmptyText(parent?.value?.marginNumber)) return true;
25432
25498
  this.writeNL_IfNotChain(route);
25433
25499
  this.writeOPC();
@@ -25441,6 +25507,7 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
25441
25507
  const parent = this.getParentNode(route);
25442
25508
  if (this.isEmptyText(lead)) return false;
25443
25509
  if (!this.isEmptyText(parent?.value?.pageNumber)) return true;
25510
+ if (!this.isEmptyText(parent?.value?.sourcePageNumber)) return true;
25444
25511
  if (!this.isEmptyText(parent?.value?.marginNumber)) return true;
25445
25512
  this.writeNL_IfNotChain(route);
25446
25513
  this.writeOPC();
@@ -25456,6 +25523,7 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
25456
25523
  const pageNumber = node.value;
25457
25524
  const parent = this.getParentNode(route);
25458
25525
  if (this.isEmptyText(pageNumber)) return false;
25526
+ if (!this.isEmptyText(parent?.value?.sourcePageNumber)) return true;
25459
25527
  if (!this.isEmptyText(parent?.value?.marginNumber)) return true;
25460
25528
  this.writeNL_IfNotChain(route);
25461
25529
  this.writeOPC();
@@ -25469,6 +25537,31 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
25469
25537
  this.writeCL();
25470
25538
  return true;
25471
25539
  }
25540
+ // bitmarkAst -> bits -> bitsValue -> sourcePageNumber
25541
+ enter_sourcePageNumber(node, route) {
25542
+ const sourcePageNumber = node.value;
25543
+ const parent = this.getParentNode(route);
25544
+ if (this.isEmptyText(sourcePageNumber)) return false;
25545
+ if (!this.isEmptyText(parent?.value?.marginNumber)) return true;
25546
+ this.writeNL_IfNotChain(route);
25547
+ this.writeOPC();
25548
+ this.writeTextOrValue(parent?.value?.item ?? "", TextFormat2.bitmarkText, TextLocation2.tag);
25549
+ this.writeCL();
25550
+ this.writeOPC();
25551
+ this.writeTextOrValue(parent?.value?.lead ?? "", TextFormat2.bitmarkText, TextLocation2.tag);
25552
+ this.writeCL();
25553
+ this.writeOPC();
25554
+ this.writeTextOrValue(
25555
+ parent?.value?.pageNumber ?? "",
25556
+ TextFormat2.bitmarkText,
25557
+ TextLocation2.tag
25558
+ );
25559
+ this.writeCL();
25560
+ this.writeOPC();
25561
+ this.writeTextOrValue(sourcePageNumber ?? "", TextFormat2.bitmarkText, TextLocation2.tag);
25562
+ this.writeCL();
25563
+ return true;
25564
+ }
25472
25565
  // bitmarkAst -> bits -> bitsValue -> marginNumber
25473
25566
  enter_marginNumber(node, route) {
25474
25567
  const marginNumber = node.value;
@@ -25489,6 +25582,13 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
25489
25582
  );
25490
25583
  this.writeCL();
25491
25584
  this.writeOPC();
25585
+ this.writeTextOrValue(
25586
+ parent?.value?.sourcePageNumber ?? "",
25587
+ TextFormat2.bitmarkText,
25588
+ TextLocation2.tag
25589
+ );
25590
+ this.writeCL();
25591
+ this.writeOPC();
25492
25592
  this.writeTextOrValue(marginNumber, TextFormat2.bitmarkText, TextLocation2.tag);
25493
25593
  this.writeCL();
25494
25594
  return true;
@@ -27313,6 +27413,10 @@ var JsonGenerator = class extends AstWalkerGenerator {
27313
27413
  enter_pageNumber(node, route) {
27314
27414
  return this.standardHandler(node, route, NodeType.bitsValue, { array: true });
27315
27415
  }
27416
+ // bitmarkAst -> bits -> bitsValue -> sourcePageNumber
27417
+ enter_sourcePageNumber(node, route) {
27418
+ return this.standardHandler(node, route, NodeType.bitsValue, { array: true });
27419
+ }
27316
27420
  // bitmarkAst -> bits -> bitsValue -> marginNumber
27317
27421
  enter_marginNumber(node, route) {
27318
27422
  return this.standardHandler(node, route, NodeType.bitsValue, { array: true });
@@ -28035,6 +28139,7 @@ var JsonGenerator = class extends AstWalkerGenerator {
28035
28139
  delete bitJson.item;
28036
28140
  delete bitJson.lead;
28037
28141
  delete bitJson.pageNumber;
28142
+ delete bitJson.sourcePageNumber;
28038
28143
  delete bitJson.marginNumber;
28039
28144
  delete bitJson.hint;
28040
28145
  delete bitJson.instruction;
@@ -28046,6 +28151,8 @@ var JsonGenerator = class extends AstWalkerGenerator {
28046
28151
  if (bitJson.lead == null || bitJson.lead?.length === 0) delete bitJson.lead;
28047
28152
  if (bitJson.pageNumber == null || bitJson.pageNumber?.length === 0)
28048
28153
  delete bitJson.pageNumber;
28154
+ if (bitJson.sourcePageNumber == null || bitJson.sourcePageNumber?.length === 0)
28155
+ delete bitJson.sourcePageNumber;
28049
28156
  if (bitJson.marginNumber == null || bitJson.marginNumber?.length === 0)
28050
28157
  delete bitJson.marginNumber;
28051
28158
  if (bitJson.hint == null || bitJson.hint?.length === 0) delete bitJson.hint;
@@ -28057,6 +28164,7 @@ var JsonGenerator = class extends AstWalkerGenerator {
28057
28164
  if (bitJson.hint == null) bitJson.hint = this.textDefault;
28058
28165
  if (bitJson.instruction == null) bitJson.instruction = this.textDefault;
28059
28166
  if (bitJson.pageNumber == null) bitJson.pageNumber = this.textDefault;
28167
+ if (bitJson.sourcePageNumber == null) bitJson.sourcePageNumber = this.textDefault;
28060
28168
  if (bitJson.marginNumber == null) bitJson.marginNumber = this.textDefault;
28061
28169
  }
28062
28170
  if (bitJson.body == null) bitJson.body = this.bodyDefault;
@@ -32496,7 +32604,8 @@ var BitmarkPegParserProcessor = class {
32496
32604
  if (l > 0) result.item = result.itemLead[0];
32497
32605
  if (l > 1) result.lead = result.itemLead[1];
32498
32606
  if (l > 2) result.pageNumber = result.itemLead[2];
32499
- if (l > 3) result.marginNumber = result.itemLead[l - 1];
32607
+ if (l > 3) result.sourcePageNumber = result.itemLead[3];
32608
+ if (l > 4) result.marginNumber = result.itemLead[l - 1];
32500
32609
  }
32501
32610
  if (inBit) {
32502
32611
  result.body = instance11.process(