@gmb/bitmark-parser-generator 5.4.0 → 5.6.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 [13 Jan 2026 at 00:31]</title>
6
+ <title>@gmb/bitmark-parser-generator [27 Jan 2026 at 03:26]</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/1XfvldSK8vs3OqB6u3m0nxmIrvgB0dj7rr7Y9Ib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nRuLabN4CGNRkAE23na2+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":1259321,"parsedSize":548009,"gzipSize":106517,"groups":[{"label":"dist/browser/cjs","path":"./dist/browser/cjs","statSize":1253259,"groups":[{"id":922,"label":"index.cjs","path":"./dist/browser/cjs/index.cjs","statSize":1253259,"parsedSize":547905,"gzipSize":106517}],"parsedSize":547905,"gzipSize":106517},{"label":"node_modules/@ncoderz/superenum/dist","path":"./node_modules/@ncoderz/superenum/dist","statSize":6062,"groups":[{"id":722,"label":"index.cjs","path":"./node_modules/@ncoderz/superenum/dist/index.cjs","statSize":6062}],"parsedSize":0,"gzipSize":0}],"isInitialByEntrypoint":{"main":true}}];
34
+ window.chartData = [{"label":"bitmark-parser-generator.min.js","isAsset":true,"statSize":1262370,"parsedSize":550030,"gzipSize":106826,"groups":[{"label":"dist/browser/cjs","path":"./dist/browser/cjs","statSize":1256308,"groups":[{"id":922,"label":"index.cjs","path":"./dist/browser/cjs/index.cjs","statSize":1256308,"parsedSize":549926,"gzipSize":106826}],"parsedSize":549926,"gzipSize":106826},{"label":"node_modules/@ncoderz/superenum/dist","path":"./node_modules/@ncoderz/superenum/dist","statSize":6062,"groups":[{"id":722,"label":"index.cjs","path":"./node_modules/@ncoderz/superenum/dist/index.cjs","statSize":6062}],"parsedSize":0,"gzipSize":0}],"isInitialByEntrypoint":{"main":true}}];
35
35
  window.entrypoints = ["main"];
36
36
  window.defaultSizes = "stat";
37
37
  window.compressionAlgorithm = "gzip";
@@ -475,6 +475,7 @@ var BitType = {
475
475
  pageHero: "page-hero",
476
476
  pageOpenBook: "page-open-book",
477
477
  pageOpenBookList: "page-open-book-list",
478
+ printBook: "print-book",
478
479
  openBookChapter: "open-book-chapter",
479
480
  pagePerson: "page-person",
480
481
  pageProduct: "page-product",
@@ -1184,6 +1185,7 @@ var propertyKeys = {
1184
1185
  property_ageRange: "@ageRange",
1185
1186
  property_aiGenerated: "@aiGenerated",
1186
1187
  property_allowedBit: "@allowedBit",
1188
+ property_allowPrint: "@allowPrint",
1187
1189
  property_allowSubtitles: "@allowSubtitles",
1188
1190
  property_alt: "@alt",
1189
1191
  property_altLangTag: "@altLangTag",
@@ -1288,6 +1290,7 @@ var propertyKeys = {
1288
1290
  property_internalPrintPdf: "@internalPrintPdf",
1289
1291
  property_hasPrintRestriction: "@hasPrintRestriction",
1290
1292
  property_enforceUpdateOverUserInput: "@enforceUpdateOverUserInput",
1293
+ property_extractorExtractionTimestamp: "@extractorExtractionTimestamp",
1291
1294
  property_isCaseSensitive: "@isCaseSensitive",
1292
1295
  property_isInfoOnly: "@isInfoOnly",
1293
1296
  property_isPublic: "@isPublic",
@@ -1325,6 +1328,7 @@ var propertyKeys = {
1325
1328
  property_mute: "@mute",
1326
1329
  property_padletId: "@padletId",
1327
1330
  property_page: "@page",
1331
+ property_printParentChapterLevel: "@printParentChapterLevel",
1328
1332
  property_pageNo: "@pageNo",
1329
1333
  property_partialAnswer: "@partialAnswer",
1330
1334
  property_partner: "@partner",
@@ -3453,6 +3457,12 @@ var GROUPS = {
3453
3457
  description: "Url of the internal print PDF for the book",
3454
3458
  format: TagFormat.plainText
3455
3459
  },
3460
+ {
3461
+ key: ConfigKey.property_allowPrint,
3462
+ description: "If true, the book allows printing",
3463
+ format: TagFormat.boolean,
3464
+ defaultValue: "false"
3465
+ },
3456
3466
  {
3457
3467
  key: ConfigKey.property_hasPrintRestriction,
3458
3468
  description: "If true, the book has print restrictions",
@@ -3464,6 +3474,12 @@ var GROUPS = {
3464
3474
  description: "If true, prioritize new content over legacy content from the instance API",
3465
3475
  format: TagFormat.boolean,
3466
3476
  defaultValue: "false"
3477
+ },
3478
+ {
3479
+ key: ConfigKey.property_extractorExtractionTimestamp,
3480
+ description: "Extraction timestamps for book conversion",
3481
+ format: TagFormat.plainText,
3482
+ maxCount: Count.infinity
3467
3483
  }
3468
3484
  ]
3469
3485
  },
@@ -6860,6 +6876,12 @@ var BITS = {
6860
6876
  key: ConfigKey.property_buttonCaption,
6861
6877
  description: "The caption of the print button",
6862
6878
  format: TagFormat.plainText
6879
+ },
6880
+ {
6881
+ key: ConfigKey.property_printParentChapterLevel,
6882
+ description: "The parent chapter level to print",
6883
+ format: TagFormat.number,
6884
+ defaultValue: "-1"
6863
6885
  }
6864
6886
  ]
6865
6887
  },
@@ -7440,6 +7462,39 @@ var BITS = {
7440
7462
  }
7441
7463
  ]
7442
7464
  },
7465
+ [BitType.printBook]: {
7466
+ since: "5.5.0",
7467
+ baseBitType: BitType.article,
7468
+ description: "Print book bit, used to create pages that open books without author information in articles or books",
7469
+ tags: [
7470
+ {
7471
+ key: ConfigKey.property_slug,
7472
+ description: "Slug for the book, used to identify the book in the system",
7473
+ format: TagFormat.plainText
7474
+ },
7475
+ {
7476
+ key: ConfigKey.property_book,
7477
+ description: "Book reference for the page, used to link to a specific book",
7478
+ format: TagFormat.plainText,
7479
+ chain: [
7480
+ {
7481
+ key: ConfigKey.tag_reference,
7482
+ description: "Reference tag for the book, used to link to the book in the system",
7483
+ maxCount: 2
7484
+ }
7485
+ ]
7486
+ },
7487
+ {
7488
+ /* Allow incorrectly chained reference tag */
7489
+ key: ConfigKey.tag_reference,
7490
+ description: "Reference tag for the book, used to link to the book in the system"
7491
+ },
7492
+ {
7493
+ key: ConfigKey.property_buttonCaption,
7494
+ description: "Caption for the button, used to define the text displayed on the button"
7495
+ }
7496
+ ]
7497
+ },
7443
7498
  [BitType.openBookChapter]: {
7444
7499
  since: "4.16.0",
7445
7500
  baseBitType: BitType.pageOpenBook,
@@ -10335,7 +10390,7 @@ var instance2 = new Config();
10335
10390
  // src/generated/package_info.ts
10336
10391
  var PACKAGE_INFO = {
10337
10392
  "name": "@gmb/bitmark-parser-generator",
10338
- "version": "5.4.0",
10393
+ "version": "5.6.0",
10339
10394
  "author": "Get More Brain Ltd",
10340
10395
  "license": "ISC",
10341
10396
  "description": "A bitmark parser and generator using Peggy.js"
@@ -10696,6 +10751,8 @@ var NodeType = {
10696
10751
  alignment: "alignment",
10697
10752
  allowedBit: "allowedBit",
10698
10753
  allowedBitValue: "allowedBitValue",
10754
+ allowPrint: "allowPrint",
10755
+ allowPrintValue: "allowPrintValue",
10699
10756
  alt: "alt",
10700
10757
  alternativeAnswers: "alternativeAnswers",
10701
10758
  alternativeAnswersValue: "alternativeAnswersValue",
@@ -10958,6 +11015,8 @@ var NodeType = {
10958
11015
  hasPrintRestrictionValue: "hasPrintRestrictionValue",
10959
11016
  enforceUpdateOverUserInput: "enforceUpdateOverUserInput",
10960
11017
  enforceUpdateOverUserInputValue: "enforceUpdateOverUserInputValue",
11018
+ extractorExtractionTimestamp: "extractorExtractionTimestamp",
11019
+ extractorExtractionTimestampValue: "extractorExtractionTimestampValue",
10961
11020
  isCaseSensitive: "isCaseSensitive",
10962
11021
  isCommented: "isCommented",
10963
11022
  isCorrect: "isCorrect",
@@ -11061,6 +11120,8 @@ var NodeType = {
11061
11120
  pageNumber: "pageNumber",
11062
11121
  pageNumberValue: "pageNumberValue",
11063
11122
  pageValue: "pageValue",
11123
+ printParentChapterLevel: "printParentChapterLevel",
11124
+ printParentChapterLevelValue: "printParentChapterLevelValue",
11064
11125
  pairs: "pairs",
11065
11126
  pairsValue: "pairsValue",
11066
11127
  parent: "parent",
@@ -24840,6 +24901,12 @@ var Builder = class extends BaseBuilder {
24840
24901
  data.enforceUpdateOverUserInput,
24841
24902
  options
24842
24903
  ),
24904
+ extractorExtractionTimestamp: this.toAstProperty(
24905
+ bitType,
24906
+ ConfigKey.property_extractorExtractionTimestamp,
24907
+ data.extractorExtractionTimestamp,
24908
+ options
24909
+ ),
24843
24910
  tocResource: this.toAstProperty(
24844
24911
  bitType,
24845
24912
  ConfigKey.property_tocResource,
@@ -24853,6 +24920,18 @@ var Builder = class extends BaseBuilder {
24853
24920
  options
24854
24921
  ),
24855
24922
  page: this.toAstProperty(bitType, ConfigKey.property_page, data.page, options),
24923
+ allowPrint: this.toAstProperty(
24924
+ bitType,
24925
+ ConfigKey.property_allowPrint,
24926
+ data.allowPrint,
24927
+ options
24928
+ ),
24929
+ printParentChapterLevel: this.toAstProperty(
24930
+ bitType,
24931
+ ConfigKey.property_printParentChapterLevel,
24932
+ data.printParentChapterLevel,
24933
+ options
24934
+ ),
24856
24935
  platformBrandTarget: this.toAstProperty(
24857
24936
  bitType,
24858
24937
  ConfigKey.property_platformBrandTarget,
@@ -30523,6 +30602,7 @@ var JsonGenerator = class extends AstWalkerGenerator {
30523
30602
  BitType.pageFooter,
30524
30603
  BitType.pageOpenBook,
30525
30604
  BitType.pagePerson,
30605
+ BitType.printBook,
30526
30606
  BitType.pageProduct,
30527
30607
  BitType.pageProductList,
30528
30608
  BitType.pageProductVideo,
@@ -30543,8 +30623,12 @@ var JsonGenerator = class extends AstWalkerGenerator {
30543
30623
  if (instance2.isOfBitType(bitType, BitType.tocContent)) {
30544
30624
  if (bitJson.tocContent == null) bitJson.tocContent = [];
30545
30625
  }
30626
+ if (instance2.isOfBitType(bitType, BitType.printThisChapter)) {
30627
+ if (bitJson.printParentChapterLevel == null) bitJson.printParentChapterLevel = -1;
30628
+ }
30546
30629
  if (instance2.isOfBitType(bitType, BitType.book)) {
30547
30630
  if (bitJson.maxTocChapterLevel == null) bitJson.maxTocChapterLevel = -1;
30631
+ if (bitJson.allowPrint == null) bitJson.allowPrint = false;
30548
30632
  if (bitJson.hasPrintRestriction == null) bitJson.hasPrintRestriction = true;
30549
30633
  if (bitJson.enforceUpdateOverUserInput == null) bitJson.enforceUpdateOverUserInput = false;
30550
30634
  if (bitJson.hasMarkAsDone == null) bitJson.hasMarkAsDone = false;