@gmb/bitmark-parser-generator 4.12.0 → 4.14.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.
package/dist/index.cjs CHANGED
@@ -175,6 +175,7 @@ var BitType = (0, import_superenum.superenum)({
175
175
  botActionSend: "bot-action-send",
176
176
  botActionTrueFalse: "bot-action-true-false",
177
177
  botInterview: "bot-interview",
178
+ brandColor: "brand-color",
178
179
  browserImage: "browser-image",
179
180
  bug: "bug",
180
181
  bugAlt: "bug-alt",
@@ -489,7 +490,18 @@ var BitType = (0, import_superenum.superenum)({
489
490
  pageSubscribe: "page-subscribe",
490
491
  parameters: "parameters",
491
492
  photo: "photo",
493
+ platform: "platform",
494
+ platformHeader: "platform-header",
495
+ platformMain: "platform-main",
496
+ platformMainButton: "platform-main-button",
497
+ platformMainInput: "platform-main-input",
492
498
  platformPath: "platform-path",
499
+ platformSection: "platform-section",
500
+ platformSectionButton: "platform-section-button",
501
+ platformSectionChat: "platform-section-chat",
502
+ platformSectionHeader: "platform-section-header",
503
+ platformSectionInput: "platform-section-input",
504
+ platformSystemIcon: "platform-system-icon",
493
505
  preparationNote: "preparation-note",
494
506
  pronunciationTable: "pronunciation-table",
495
507
  prototypeImages: "prototype-images",
@@ -620,6 +632,7 @@ var BitType = (0, import_superenum.superenum)({
620
632
  surveyRatingOnce: "survey-rating-once",
621
633
  table: "table",
622
634
  tableAlt: "table-alt",
635
+ tableExtended: "table-extended",
623
636
  tableImage: "table-image",
624
637
  tableImageAlt: "table-image-alt",
625
638
  takePicture: "take-picture",
@@ -750,6 +763,7 @@ var CardSetConfigKey = (0, import_superenum7.superenum)({
750
763
  matchImagePairs: "matchImagePairs",
751
764
  matchMatrix: "matchMatrix",
752
765
  table: "table",
766
+ tableExtended: "tableExtended",
753
767
  pronunciationTable: "pronunciationTable",
754
768
  botActionResponses: "botActionResponses",
755
769
  exampleBitList: "exampleBitList",
@@ -1116,6 +1130,7 @@ var groupKeys = {
1116
1130
  group_bookCommon: "group_bookCommon",
1117
1131
  group_learningPathCommon: "group_learningPathCommon",
1118
1132
  group_advertisingCommon: "group_advertisingCommon",
1133
+ group_platformColorsCommon: "group_platformColorsCommon",
1119
1134
  group_quizCommon: "group_quizCommon",
1120
1135
  group_resourceBitTags: "group_resourceBitTags",
1121
1136
  group_resourceCommon: "group_resourceCommon",
@@ -1170,6 +1185,8 @@ var propertyKeys = {
1170
1185
  property_author: "@author",
1171
1186
  property_autoplay: "@autoplay",
1172
1187
  property_availableClassifications: "@availableClassifications",
1188
+ property_brandColor: "@brandColor",
1189
+ property_brandColorName: "@brandColorName",
1173
1190
  property_blockId: "@blockId",
1174
1191
  property_book: "@book",
1175
1192
  property_bookAlias: "@bookAlias",
@@ -1236,6 +1253,8 @@ var propertyKeys = {
1236
1253
  property_imageSource: "@imageSource",
1237
1254
  property_index: "@index",
1238
1255
  property_internalComment: "@internalComment",
1256
+ property_internalPrintPdf: "@internalPrintPdf",
1257
+ property_hasPrintRestriction: "@hasPrintRestriction",
1239
1258
  property_isCaseSensitive: "@isCaseSensitive",
1240
1259
  property_isInfoOnly: "@isInfoOnly",
1241
1260
  property_isPublic: "@isPublic",
@@ -1276,6 +1295,18 @@ var propertyKeys = {
1276
1295
  property_partner: "@partner",
1277
1296
  // Deprecated, replaced by person
1278
1297
  property_path: "@path",
1298
+ property_platformBackgroundColor: "@platformBackgroundColor",
1299
+ property_platformButtonBackgroundColor: "@platformButtonBackgroundColor",
1300
+ property_platformButtonPrimaryColor: "@platformButtonPrimaryColor",
1301
+ property_platformMessageBackgroundColor: "@platformMessageBackgroundColor",
1302
+ property_platformName: "@platformName",
1303
+ property_platformPlaceholderColor: "@platformPlaceholderColor",
1304
+ property_platformPrimaryColor: "@platformPrimaryColor",
1305
+ property_platformScrollbarColor: "@platformScrollbarColor",
1306
+ property_platformSecondaryColor: "@platformSecondaryColor",
1307
+ property_platformSelectionColor: "@platformSelectionColor",
1308
+ property_platformSeparatorColor: "@platformSeparatorColor",
1309
+ property_platformTextSelectionColor: "@platformTextSelectionColor",
1279
1310
  property_person: "@person",
1280
1311
  property_pointerLeft: "@pointerLeft",
1281
1312
  property_pointerTop: "@pointerTop",
@@ -1325,6 +1356,7 @@ var propertyKeys = {
1325
1356
  property_size: "@size",
1326
1357
  property_slug: "@slug",
1327
1358
  property_sourceDocument: "@sourceDocument",
1359
+ property_sourceRL: "@sourceRL",
1328
1360
  property_spaceId: "@spaceId",
1329
1361
  property_src1x: "@src1x",
1330
1362
  property_src2x: "@src2x",
@@ -1346,6 +1378,10 @@ var propertyKeys = {
1346
1378
  property_tableSearch: "@tableSearch",
1347
1379
  property_tableSort: "@tableSort",
1348
1380
  property_tableWhitespaceNoWrap: "@tableWhitespaceNoWrap",
1381
+ property_tableCellType: "@tableCellType",
1382
+ property_tableRowSpan: "@tableRowSpan",
1383
+ property_tableColSpan: "@tableColSpan",
1384
+ property_tableScope: "@tableScope",
1349
1385
  property_tag: "@tag",
1350
1386
  property_target: "@target",
1351
1387
  property_technicalTerm: "@technicalTerm",
@@ -1399,6 +1435,9 @@ var resourceKeys = {
1399
1435
  resource_appLink: "&appLink",
1400
1436
  resource_websiteLink: "&websiteLink",
1401
1437
  resource_icon: "&icon",
1438
+ resource_platformBackgroundImage: "&platformBackgroundImage",
1439
+ resource_platformIcon: "&platformIcon",
1440
+ resource_platformLogo: "&platformLogo",
1402
1441
  resource_backgroundWallpaper: "&backgroundWallpaper",
1403
1442
  resource_imagePlaceholder: "&imagePlaceholder"
1404
1443
  };
@@ -1625,7 +1664,10 @@ var ResourceType = (0, import_superenum13.superenum)({
1625
1664
  // Aliases for image
1626
1665
  icon: "icon",
1627
1666
  backgroundWallpaper: "backgroundWallpaper",
1628
- imagePlaceholder: "imagePlaceholder"
1667
+ imagePlaceholder: "imagePlaceholder",
1668
+ platformIcon: "platformIcon",
1669
+ platformLogo: "platformLogo",
1670
+ platformBackgroundImage: "platformBackgroundImage"
1629
1671
  });
1630
1672
  function resourceTypeToConfigKey(type) {
1631
1673
  return `&${stringUtils.kebabToCamel(type)}`;
@@ -2422,6 +2464,47 @@ var CARDSETS = {
2422
2464
  ]
2423
2465
  ]
2424
2466
  },
2467
+ [CardSetConfigKey.tableExtended]: {
2468
+ variants: [
2469
+ // Side 1
2470
+ [
2471
+ // Variant 1..N
2472
+ {
2473
+ tags: [
2474
+ {
2475
+ key: ConfigKey.group_standardItemLeadInstructionHint,
2476
+ description: "Standard tags for lead, instruction, and hint."
2477
+ },
2478
+ {
2479
+ key: ConfigKey.tag_title,
2480
+ description: "Title of the table."
2481
+ },
2482
+ {
2483
+ key: ConfigKey.property_tableCellType,
2484
+ description: "Table cell type (th/td).",
2485
+ format: TagFormat.plainText
2486
+ },
2487
+ {
2488
+ key: ConfigKey.property_tableRowSpan,
2489
+ description: "Number of rows the cell spans.",
2490
+ format: TagFormat.number
2491
+ },
2492
+ {
2493
+ key: ConfigKey.property_tableColSpan,
2494
+ description: "Number of columns the cell spans.",
2495
+ format: TagFormat.number
2496
+ },
2497
+ {
2498
+ key: ConfigKey.property_tableScope,
2499
+ description: "Scope attribute for header cells.",
2500
+ format: TagFormat.plainText
2501
+ }
2502
+ ],
2503
+ repeatCount: Count.infinity
2504
+ }
2505
+ ]
2506
+ ]
2507
+ },
2425
2508
  [CardSetConfigKey.pronunciationTable]: {
2426
2509
  variants: [
2427
2510
  // Side 1
@@ -2640,6 +2723,11 @@ var GROUPS = {
2640
2723
  format: TagFormat.plainText,
2641
2724
  maxCount: Count.infinity
2642
2725
  },
2726
+ {
2727
+ key: ConfigKey.property_sourceRL,
2728
+ description: "The original location of the information in the original source material",
2729
+ format: TagFormat.plainText
2730
+ },
2643
2731
  {
2644
2732
  key: ConfigKey.property_isTemplate,
2645
2733
  description: "If true, the bit is a template",
@@ -3286,6 +3374,17 @@ var GROUPS = {
3286
3374
  key: ConfigKey.property_sourceDocument,
3287
3375
  description: "Url of the source document for the book (for example, a PDF file)",
3288
3376
  format: TagFormat.plainText
3377
+ },
3378
+ {
3379
+ key: ConfigKey.property_internalPrintPdf,
3380
+ description: "Url of the internal print PDF for the book",
3381
+ format: TagFormat.plainText
3382
+ },
3383
+ {
3384
+ key: ConfigKey.property_hasPrintRestriction,
3385
+ description: "If true, the book has print restrictions",
3386
+ format: TagFormat.boolean,
3387
+ defaultValue: "true"
3289
3388
  }
3290
3389
  ]
3291
3390
  },
@@ -3375,6 +3474,67 @@ var GROUPS = {
3375
3474
  }
3376
3475
  ]
3377
3476
  },
3477
+ [ConfigKey.group_platformColorsCommon]: {
3478
+ type: GroupConfigType.standard,
3479
+ description: "Common platform colors",
3480
+ tags: [
3481
+ {
3482
+ key: ConfigKey.property_platformPrimaryColor,
3483
+ description: "The platform system primary color",
3484
+ format: TagFormat.plainText
3485
+ },
3486
+ {
3487
+ key: ConfigKey.property_platformSecondaryColor,
3488
+ description: "The platform section secondary color",
3489
+ format: TagFormat.plainText
3490
+ },
3491
+ {
3492
+ key: ConfigKey.property_platformBackgroundColor,
3493
+ description: "The platform system background color",
3494
+ format: TagFormat.plainText
3495
+ },
3496
+ {
3497
+ key: ConfigKey.property_platformButtonPrimaryColor,
3498
+ description: "The platform section header button primary color",
3499
+ format: TagFormat.plainText
3500
+ },
3501
+ {
3502
+ key: ConfigKey.property_platformButtonBackgroundColor,
3503
+ description: "The platform section header button background color",
3504
+ format: TagFormat.plainText
3505
+ },
3506
+ {
3507
+ key: ConfigKey.property_platformScrollbarColor,
3508
+ description: "The platform main scrollbar color",
3509
+ format: TagFormat.plainText
3510
+ },
3511
+ {
3512
+ key: ConfigKey.property_platformSelectionColor,
3513
+ description: "The platform main selection color",
3514
+ format: TagFormat.plainText
3515
+ },
3516
+ {
3517
+ key: ConfigKey.property_platformTextSelectionColor,
3518
+ description: "The platform main input text selection color",
3519
+ format: TagFormat.plainText
3520
+ },
3521
+ {
3522
+ key: ConfigKey.property_platformSeparatorColor,
3523
+ description: "The platform main separator color",
3524
+ format: TagFormat.plainText
3525
+ },
3526
+ {
3527
+ key: ConfigKey.property_platformPlaceholderColor,
3528
+ description: "The platform main input placeholder color",
3529
+ format: TagFormat.plainText
3530
+ },
3531
+ {
3532
+ key: ConfigKey.property_platformMessageBackgroundColor,
3533
+ description: "The platform section chat message background color",
3534
+ format: TagFormat.plainText
3535
+ }
3536
+ ]
3537
+ },
3378
3538
  [ConfigKey.group_quizCommon]: {
3379
3539
  type: GroupConfigType.standard,
3380
3540
  description: "Common quiz tags",
@@ -7176,6 +7336,23 @@ var BITS = {
7176
7336
  baseBitType: BitType.interview,
7177
7337
  description: "Bot interview bit, used to create bot interviews in articles or books"
7178
7338
  },
7339
+ [BitType.brandColor]: {
7340
+ since: "4.12.0",
7341
+ baseBitType: BitType._standard,
7342
+ description: "Brand color bit, used to define brand colors",
7343
+ tags: [
7344
+ {
7345
+ key: ConfigKey.property_brandColor,
7346
+ description: "The brand color",
7347
+ format: TagFormat.plainText
7348
+ },
7349
+ {
7350
+ key: ConfigKey.property_brandColorName,
7351
+ description: "The brand color name",
7352
+ format: TagFormat.plainText
7353
+ }
7354
+ ]
7355
+ },
7179
7356
  [BitType.learningPathBook]: {
7180
7357
  since: "1.3.0",
7181
7358
  baseBitType: BitType._standard,
@@ -7934,6 +8111,160 @@ var BITS = {
7934
8111
  baseBitType: BitType.image,
7935
8112
  description: "Photo bit, used to create photo bits in articles or books"
7936
8113
  },
8114
+ [BitType.platform]: {
8115
+ since: "4.12.0",
8116
+ baseBitType: BitType._standard,
8117
+ description: "Platform bit, used to define platform properties",
8118
+ tags: [
8119
+ {
8120
+ key: ConfigKey.property_platformName,
8121
+ description: "The platform name",
8122
+ format: TagFormat.plainText
8123
+ },
8124
+ {
8125
+ key: ConfigKey.resource_platformIcon,
8126
+ description: "The platform icon",
8127
+ chain: [
8128
+ {
8129
+ key: ConfigKey.group_resourceImageCommon,
8130
+ description: "Common image properties for the platform icon resource"
8131
+ }
8132
+ ],
8133
+ maxCount: 1
8134
+ }
8135
+ ]
8136
+ },
8137
+ [BitType.platformHeader]: {
8138
+ since: "4.12.0",
8139
+ baseBitType: BitType._standard,
8140
+ description: "Platform header bit, used to define platform header properties",
8141
+ tags: [
8142
+ {
8143
+ key: ConfigKey.resource_platformLogo,
8144
+ description: "The platform logo",
8145
+ chain: [
8146
+ {
8147
+ key: ConfigKey.group_resourceImageCommon,
8148
+ description: "Common image properties for the platform logo resource"
8149
+ }
8150
+ ],
8151
+ maxCount: 1
8152
+ },
8153
+ {
8154
+ key: ConfigKey.group_platformColorsCommon,
8155
+ description: "Common platform colors"
8156
+ }
8157
+ ]
8158
+ },
8159
+ [BitType.platformMain]: {
8160
+ since: "4.12.0",
8161
+ baseBitType: BitType._standard,
8162
+ description: "Platform main bit, used to define platform main properties",
8163
+ tags: [
8164
+ {
8165
+ key: ConfigKey.group_platformColorsCommon,
8166
+ description: "Common platform colors"
8167
+ }
8168
+ ]
8169
+ },
8170
+ [BitType.platformMainButton]: {
8171
+ since: "4.12.0",
8172
+ baseBitType: BitType._standard,
8173
+ description: "Platform main button bit, used to define platform main button properties",
8174
+ tags: [
8175
+ {
8176
+ key: ConfigKey.group_platformColorsCommon,
8177
+ description: "Common platform colors"
8178
+ }
8179
+ ]
8180
+ },
8181
+ [BitType.platformMainInput]: {
8182
+ since: "4.12.0",
8183
+ baseBitType: BitType._standard,
8184
+ description: "Platform main input bit, used to define platform main input properties",
8185
+ tags: [
8186
+ {
8187
+ key: ConfigKey.group_platformColorsCommon,
8188
+ description: "Common platform colors"
8189
+ }
8190
+ ]
8191
+ },
8192
+ [BitType.platformSection]: {
8193
+ since: "4.12.0",
8194
+ baseBitType: BitType._standard,
8195
+ description: "Platform section bit, used to define platform section properties",
8196
+ tags: [
8197
+ {
8198
+ key: ConfigKey.group_platformColorsCommon,
8199
+ description: "Common platform colors"
8200
+ }
8201
+ ]
8202
+ },
8203
+ [BitType.platformSectionButton]: {
8204
+ since: "4.12.0",
8205
+ baseBitType: BitType._standard,
8206
+ description: "Platform section button bit, used to define platform section button properties",
8207
+ tags: [
8208
+ {
8209
+ key: ConfigKey.group_platformColorsCommon,
8210
+ description: "Common platform colors"
8211
+ }
8212
+ ]
8213
+ },
8214
+ [BitType.platformSectionChat]: {
8215
+ since: "4.12.0",
8216
+ baseBitType: BitType._standard,
8217
+ description: "Platform section chat bit, used to define platform section chat properties",
8218
+ tags: [
8219
+ {
8220
+ key: ConfigKey.group_platformColorsCommon,
8221
+ description: "Common platform colors"
8222
+ },
8223
+ {
8224
+ key: ConfigKey.resource_platformBackgroundImage,
8225
+ description: "The platform section chat background image",
8226
+ chain: [
8227
+ {
8228
+ key: ConfigKey.group_resourceImageCommon,
8229
+ description: "Common image properties for the platform background image resource"
8230
+ }
8231
+ ]
8232
+ }
8233
+ ]
8234
+ },
8235
+ [BitType.platformSectionHeader]: {
8236
+ since: "4.12.0",
8237
+ baseBitType: BitType._standard,
8238
+ description: "Platform section header bit, used to define platform section header properties",
8239
+ tags: [
8240
+ {
8241
+ key: ConfigKey.group_platformColorsCommon,
8242
+ description: "Common platform colors"
8243
+ }
8244
+ ]
8245
+ },
8246
+ [BitType.platformSectionInput]: {
8247
+ since: "4.12.0",
8248
+ baseBitType: BitType._standard,
8249
+ description: "Platform section input bit, used to define platform section input properties",
8250
+ tags: [
8251
+ {
8252
+ key: ConfigKey.group_platformColorsCommon,
8253
+ description: "Common platform colors"
8254
+ }
8255
+ ]
8256
+ },
8257
+ [BitType.platformSystemIcon]: {
8258
+ since: "4.12.0",
8259
+ baseBitType: BitType._standard,
8260
+ description: "Platform system icon bit, used to define platform system icon properties",
8261
+ tags: [
8262
+ {
8263
+ key: ConfigKey.group_platformColorsCommon,
8264
+ description: "Common platform colors"
8265
+ }
8266
+ ]
8267
+ },
7937
8268
  [BitType.quote]: {
7938
8269
  since: "1.3.0",
7939
8270
  baseBitType: BitType._standard,
@@ -8301,6 +8632,12 @@ var BITS = {
8301
8632
  ],
8302
8633
  cardSet: CardSetConfigKey.table
8303
8634
  },
8635
+ [BitType.tableExtended]: {
8636
+ since: "4.14.0",
8637
+ baseBitType: BitType.table,
8638
+ description: "Extended table bit, used to create complex tables with all HTML table features",
8639
+ cardSet: CardSetConfigKey.tableExtended
8640
+ },
8304
8641
  [BitType.tableAlt]: {
8305
8642
  since: "1.16.0",
8306
8643
  baseBitType: BitType.table,
@@ -9282,7 +9619,7 @@ var instance2 = new Config();
9282
9619
  // src/generated/package_info.ts
9283
9620
  var PACKAGE_INFO = {
9284
9621
  "name": "@gmb/bitmark-parser-generator",
9285
- "version": "4.12.0",
9622
+ "version": "4.14.0",
9286
9623
  "author": "Get More Brain Ltd",
9287
9624
  "license": "ISC",
9288
9625
  "description": "A bitmark parser and generator using Peggy.js"
@@ -9627,6 +9964,10 @@ var NodeType = (0, import_superenum20.superenum)({
9627
9964
  advertisingClickUrl: "advertisingClickUrl",
9628
9965
  advertisingClickUrlValue: "advertisingClickUrlValue",
9629
9966
  ageRange: "ageRange",
9967
+ brandColor: "brandColor",
9968
+ brandColorValue: "brandColorValue",
9969
+ brandColorName: "brandColorName",
9970
+ brandColorNameValue: "brandColorNameValue",
9630
9971
  ageRangeValue: "ageRangeValue",
9631
9972
  aiGenerated: "aiGenerated",
9632
9973
  aiGeneratedValue: "aiGeneratedValue",
@@ -9779,6 +10120,7 @@ var NodeType = (0, import_superenum20.superenum)({
9779
10120
  durationValue: "durationValue",
9780
10121
  elements: "elements",
9781
10122
  elementsValue: "elementsValue",
10123
+ elementsValueValue: "elementsValueValue",
9782
10124
  emphasis: "emphasis",
9783
10125
  end: "end",
9784
10126
  errors: "errors",
@@ -9807,6 +10149,7 @@ var NodeType = (0, import_superenum20.superenum)({
9807
10149
  focusY: "focusY",
9808
10150
  focusYValue: "focusYValue",
9809
10151
  footer: "footer",
10152
+ footerValue: "footerValue",
9810
10153
  footerText: "footerText",
9811
10154
  forKeys: "forKeys",
9812
10155
  format: "format",
@@ -9829,11 +10172,13 @@ var NodeType = (0, import_superenum20.superenum)({
9829
10172
  hasBookNavigationValue: "hasBookNavigationValue",
9830
10173
  hasMarkAsDone: "hasMarkAsDone",
9831
10174
  hasMarkAsDoneValue: "hasMarkAsDoneValue",
10175
+ head: "head",
9832
10176
  heading: "heading",
9833
10177
  height: "height",
9834
10178
  heightValue: "heightValue",
9835
10179
  highlight: "highlight",
9836
10180
  hint: "hint",
10181
+ hintValue: "hintValue",
9837
10182
  href: "href",
9838
10183
  icon: "icon",
9839
10184
  iconTag: "iconTag",
@@ -9855,8 +10200,13 @@ var NodeType = (0, import_superenum20.superenum)({
9855
10200
  ingredients: "ingredients",
9856
10201
  ingredientsValue: "ingredientsValue",
9857
10202
  instruction: "instruction",
10203
+ instructionValue: "instructionValue",
9858
10204
  internalComment: "internalComment",
9859
10205
  internalCommentValue: "internalCommentValue",
10206
+ internalPrintPdf: "internalPrintPdf",
10207
+ internalPrintPdfValue: "internalPrintPdfValue",
10208
+ hasPrintRestriction: "hasPrintRestriction",
10209
+ hasPrintRestrictionValue: "hasPrintRestrictionValue",
9860
10210
  isCaseSensitive: "isCaseSensitive",
9861
10211
  isCommented: "isCommented",
9862
10212
  isCorrect: "isCorrect",
@@ -9875,6 +10225,7 @@ var NodeType = (0, import_superenum20.superenum)({
9875
10225
  isTracked: "isTracked",
9876
10226
  isTrackedValue: "isTrackedValue",
9877
10227
  item: "item",
10228
+ itemValue: "itemValue",
9878
10229
  itemLead: "itemLead",
9879
10230
  jobTitle: "jobTitle",
9880
10231
  jobTitleValue: "jobTitleValue",
@@ -9901,6 +10252,7 @@ var NodeType = (0, import_superenum20.superenum)({
9901
10252
  layerRoleValue: "layerRoleValue",
9902
10253
  layerValue: "layerValue",
9903
10254
  lead: "lead",
10255
+ leadValue: "leadValue",
9904
10256
  level: "level",
9905
10257
  levelACTFL: "levelACTFL",
9906
10258
  levelACTFLValue: "levelACTFLValue",
@@ -9922,6 +10274,7 @@ var NodeType = (0, import_superenum20.superenum)({
9922
10274
  machineTranslatedValue: "machineTranslatedValue",
9923
10275
  mailingList: "mailingList",
9924
10276
  marginNumber: "marginNumber",
10277
+ marginNumberValue: "marginNumberValue",
9925
10278
  mark: "mark",
9926
10279
  markConfig: "markConfig",
9927
10280
  markConfigValue: "markConfigValue",
@@ -9950,6 +10303,7 @@ var NodeType = (0, import_superenum20.superenum)({
9950
10303
  pageNo: "pageNo",
9951
10304
  pageNoValue: "pageNoValue",
9952
10305
  pageNumber: "pageNumber",
10306
+ pageNumberValue: "pageNumberValue",
9953
10307
  pageValue: "pageValue",
9954
10308
  pairs: "pairs",
9955
10309
  pairsValue: "pairsValue",
@@ -9959,6 +10313,36 @@ var NodeType = (0, import_superenum20.superenum)({
9959
10313
  partialAnswerValue: "partialAnswerValue",
9960
10314
  path: "path",
9961
10315
  pathValue: "pathValue",
10316
+ platformName: "platformName",
10317
+ platformNameValue: "platformNameValue",
10318
+ platformIcon: "platformIcon",
10319
+ platformIconValue: "platformIconValue",
10320
+ platformLogo: "platformLogo",
10321
+ platformLogoValue: "platformLogoValue",
10322
+ platformPrimaryColor: "platformPrimaryColor",
10323
+ platformPrimaryColorValue: "platformPrimaryColorValue",
10324
+ platformSecondaryColor: "platformSecondaryColor",
10325
+ platformSecondaryColorValue: "platformSecondaryColorValue",
10326
+ platformBackgroundColor: "platformBackgroundColor",
10327
+ platformBackgroundColorValue: "platformBackgroundColorValue",
10328
+ platformScrollbarColor: "platformScrollbarColor",
10329
+ platformScrollbarColorValue: "platformScrollbarColorValue",
10330
+ platformSelectionColor: "platformSelectionColor",
10331
+ platformSelectionColorValue: "platformSelectionColorValue",
10332
+ platformSeparatorColor: "platformSeparatorColor",
10333
+ platformSeparatorColorValue: "platformSeparatorColorValue",
10334
+ platformPlaceholderColor: "platformPlaceholderColor",
10335
+ platformPlaceholderColorValue: "platformPlaceholderColorValue",
10336
+ platformTextSelectionColor: "platformTextSelectionColor",
10337
+ platformTextSelectionColorValue: "platformTextSelectionColorValue",
10338
+ platformButtonPrimaryColor: "platformButtonPrimaryColor",
10339
+ platformButtonPrimaryColorValue: "platformButtonPrimaryColorValue",
10340
+ platformButtonBackgroundColor: "platformButtonBackgroundColor",
10341
+ platformButtonBackgroundColorValue: "platformButtonBackgroundColorValue",
10342
+ platformMessageBackgroundColor: "platformMessageBackgroundColor",
10343
+ platformMessageBackgroundColorValue: "platformMessageBackgroundColorValue",
10344
+ platformBackgroundImage: "platformBackgroundImage",
10345
+ platformBackgroundImageValue: "platformBackgroundImageValue",
9962
10346
  person: "person",
9963
10347
  pointerLeft: "pointerLeft",
9964
10348
  pointerLeftValue: "pointerLeftValue",
@@ -10003,6 +10387,7 @@ var NodeType = (0, import_superenum20.superenum)({
10003
10387
  publisherValue: "publisherValue",
10004
10388
  quantity: "quantity",
10005
10389
  question: "question",
10390
+ questionValue: "questionValue",
10006
10391
  questions: "questions",
10007
10392
  questionsValue: "questionsValue",
10008
10393
  quizCountItems: "quizCountItems",
@@ -10055,6 +10440,10 @@ var NodeType = (0, import_superenum20.superenum)({
10055
10440
  revealSolutions: "revealSolutions",
10056
10441
  root: "root",
10057
10442
  // bit type (root)
10443
+ rows: "rows",
10444
+ rowsValue: "rowsValue",
10445
+ rubric: "rubric",
10446
+ rubricValue: "rubricValue",
10058
10447
  sampleSolution: "sampleSolution",
10059
10448
  sampleSolutionValue: "sampleSolutionValue",
10060
10449
  scormSource: "scormSource",
@@ -10077,7 +10466,8 @@ var NodeType = (0, import_superenum20.superenum)({
10077
10466
  solutionsValue: "solutionsValue",
10078
10467
  sourceDocument: "sourceDocument",
10079
10468
  sourceDocumentValue: "sourceDocumentValue",
10080
- sourcePageNumber: "sourcePageNumber",
10469
+ sourceRL: "sourceRL",
10470
+ sourceRLValue: "sourceRLValue",
10081
10471
  spaceId: "spaceId",
10082
10472
  spaceIdValue: "spaceIdValue",
10083
10473
  src: "src",
@@ -10659,6 +11049,103 @@ var DeprecatedTextFormat = (0, import_superenum23.superenum)({
10659
11049
  // bitmark-- text format, deprecated
10660
11050
  });
10661
11051
 
11052
+ // src/parser/json/TableUtils.ts
11053
+ function isTableBasicFormat(table) {
11054
+ const t = table;
11055
+ return !!(t.columns || t.data) && !(t.head || t.body || t.foot);
11056
+ }
11057
+ function isTableExtendedFormat(table) {
11058
+ const t = table;
11059
+ return !!(t.head || t.body || t.foot);
11060
+ }
11061
+ function isMixedTableFormat(table) {
11062
+ const t = table;
11063
+ const hasOld = !!(t.columns || t.data);
11064
+ const hasNew = !!(t.head || t.body || t.foot);
11065
+ return hasOld && hasNew;
11066
+ }
11067
+ function convertBasicToExtendedTableFormat(table) {
11068
+ const tableExtended = {};
11069
+ if (table.columns && table.columns.length > 0) {
11070
+ tableExtended.head = {
11071
+ rows: [
11072
+ {
11073
+ cells: table.columns.map((col) => ({
11074
+ content: col,
11075
+ title: true
11076
+ }))
11077
+ }
11078
+ ]
11079
+ };
11080
+ }
11081
+ if (table.data && table.data.length > 0) {
11082
+ tableExtended.body = {
11083
+ rows: table.data.map((row) => ({
11084
+ cells: row.map((cell) => ({
11085
+ content: cell
11086
+ }))
11087
+ }))
11088
+ };
11089
+ }
11090
+ return tableExtended;
11091
+ }
11092
+ function convertExtendedToBasicTableFormat(tableExtended) {
11093
+ const table = {};
11094
+ const extractRowCells = (row) => {
11095
+ if (!row || !Array.isArray(row.cells)) {
11096
+ return [];
11097
+ }
11098
+ return row.cells.map((cell) => cell?.content).filter((content) => content !== void 0);
11099
+ };
11100
+ const dataRows = [];
11101
+ const headRows = tableExtended.head?.rows ?? [];
11102
+ if (headRows.length > 0) {
11103
+ const primaryHeader = extractRowCells(headRows[0]);
11104
+ if (primaryHeader.length > 0) {
11105
+ table.columns = primaryHeader;
11106
+ }
11107
+ const remainingHeadRows = headRows.slice(1);
11108
+ remainingHeadRows.forEach((row) => {
11109
+ const cells = extractRowCells(row);
11110
+ if (cells.length > 0) {
11111
+ dataRows.push(cells);
11112
+ }
11113
+ });
11114
+ }
11115
+ const appendSectionRows = (section) => {
11116
+ if (!section || !Array.isArray(section.rows)) {
11117
+ return;
11118
+ }
11119
+ section.rows.forEach((row) => {
11120
+ const cells = extractRowCells(row);
11121
+ if (cells.length > 0) {
11122
+ dataRows.push(cells);
11123
+ }
11124
+ });
11125
+ };
11126
+ appendSectionRows(tableExtended.body);
11127
+ appendSectionRows(tableExtended.foot);
11128
+ if (dataRows.length > 0) {
11129
+ table.data = dataRows;
11130
+ }
11131
+ return table;
11132
+ }
11133
+ function normalizeTableFormat(bitType, table) {
11134
+ if (isMixedTableFormat(table)) {
11135
+ const t = table;
11136
+ delete t.columns;
11137
+ delete t.data;
11138
+ }
11139
+ const isExtended = instance2.isOfBitType(bitType, BitType.tableExtended);
11140
+ if (isExtended && isTableBasicFormat(table)) {
11141
+ return convertBasicToExtendedTableFormat(table);
11142
+ }
11143
+ if (!isExtended && isTableExtendedFormat(table)) {
11144
+ return convertExtendedToBasicTableFormat(table);
11145
+ }
11146
+ return table;
11147
+ }
11148
+
10662
11149
  // src/utils/ArrayUtils.ts
10663
11150
  var ArrayUtils = class {
10664
11151
  /**
@@ -21476,6 +21963,9 @@ var ResourceBuilder = class extends BaseBuilder {
21476
21963
  case ResourceType.backgroundWallpaper:
21477
21964
  case ResourceType.imagePlaceholder:
21478
21965
  case ResourceType.icon:
21966
+ case ResourceType.platformIcon:
21967
+ case ResourceType.platformLogo:
21968
+ case ResourceType.platformBackgroundImage:
21479
21969
  node = this.imageResource(context, finalData, type);
21480
21970
  break;
21481
21971
  // case ResourceType.imageResponsive: {
@@ -22449,6 +22939,7 @@ var Builder = class extends BaseBuilder {
22449
22939
  * @returns
22450
22940
  */
22451
22941
  buildBit(data, options) {
22942
+ data = structuredClone(data);
22452
22943
  const bitType = data.bitType;
22453
22944
  const bitConfig = instance2.getBitConfig(bitType);
22454
22945
  const deprecatedTextFormat = DeprecatedTextFormat.fromValue(data.textFormat);
@@ -22512,6 +23003,7 @@ var Builder = class extends BaseBuilder {
22512
23003
  data.jupyterExecutionCount,
22513
23004
  options
22514
23005
  ),
23006
+ sourceRL: this.toAstProperty(bitType, ConfigKey.property_sourceRL, data.sourceRL, options),
22515
23007
  isPublic: this.toAstProperty(bitType, ConfigKey.property_isPublic, data.isPublic, options),
22516
23008
  isTemplate: this.toAstProperty(
22517
23009
  bitType,
@@ -23035,6 +23527,18 @@ var Builder = class extends BaseBuilder {
23035
23527
  data.advertisingClickUrl,
23036
23528
  options
23037
23529
  ),
23530
+ brandColor: this.toAstProperty(
23531
+ bitType,
23532
+ ConfigKey.property_brandColor,
23533
+ data.brandColor,
23534
+ options
23535
+ ),
23536
+ brandColorName: this.toAstProperty(
23537
+ bitType,
23538
+ ConfigKey.property_brandColorName,
23539
+ data.brandColorName,
23540
+ options
23541
+ ),
23038
23542
  caption: this.handleJsonText(context, TextLocation.tag, data.caption),
23039
23543
  quotedPerson: this.toAstProperty(
23040
23544
  bitType,
@@ -23098,6 +23602,18 @@ var Builder = class extends BaseBuilder {
23098
23602
  data.sourceDocument,
23099
23603
  options
23100
23604
  ),
23605
+ internalPrintPdf: this.toAstProperty(
23606
+ bitType,
23607
+ ConfigKey.property_internalPrintPdf,
23608
+ data.internalPrintPdf,
23609
+ options
23610
+ ),
23611
+ hasPrintRestriction: this.toAstProperty(
23612
+ bitType,
23613
+ ConfigKey.property_hasPrintRestriction,
23614
+ data.hasPrintRestriction,
23615
+ options
23616
+ ),
23101
23617
  tocResource: this.toAstProperty(
23102
23618
  bitType,
23103
23619
  ConfigKey.property_tocResource,
@@ -23111,6 +23627,81 @@ var Builder = class extends BaseBuilder {
23111
23627
  options
23112
23628
  ),
23113
23629
  page: this.toAstProperty(bitType, ConfigKey.property_page, data.page, options),
23630
+ platformName: this.toAstProperty(
23631
+ bitType,
23632
+ ConfigKey.property_platformName,
23633
+ data.platformName,
23634
+ options
23635
+ ),
23636
+ platformIcon: this.toImageResource(context, data.platformIcon),
23637
+ platformLogo: this.toImageResource(context, data.platformLogo),
23638
+ platformPrimaryColor: this.toAstProperty(
23639
+ bitType,
23640
+ ConfigKey.property_platformPrimaryColor,
23641
+ data.platformPrimaryColor,
23642
+ options
23643
+ ),
23644
+ platformSecondaryColor: this.toAstProperty(
23645
+ bitType,
23646
+ ConfigKey.property_platformSecondaryColor,
23647
+ data.platformSecondaryColor,
23648
+ options
23649
+ ),
23650
+ platformBackgroundColor: this.toAstProperty(
23651
+ bitType,
23652
+ ConfigKey.property_platformBackgroundColor,
23653
+ data.platformBackgroundColor,
23654
+ options
23655
+ ),
23656
+ platformScrollbarColor: this.toAstProperty(
23657
+ bitType,
23658
+ ConfigKey.property_platformScrollbarColor,
23659
+ data.platformScrollbarColor,
23660
+ options
23661
+ ),
23662
+ platformSelectionColor: this.toAstProperty(
23663
+ bitType,
23664
+ ConfigKey.property_platformSelectionColor,
23665
+ data.platformSelectionColor,
23666
+ options
23667
+ ),
23668
+ platformSeparatorColor: this.toAstProperty(
23669
+ bitType,
23670
+ ConfigKey.property_platformSeparatorColor,
23671
+ data.platformSeparatorColor,
23672
+ options
23673
+ ),
23674
+ platformPlaceholderColor: this.toAstProperty(
23675
+ bitType,
23676
+ ConfigKey.property_platformPlaceholderColor,
23677
+ data.platformPlaceholderColor,
23678
+ options
23679
+ ),
23680
+ platformTextSelectionColor: this.toAstProperty(
23681
+ bitType,
23682
+ ConfigKey.property_platformTextSelectionColor,
23683
+ data.platformTextSelectionColor,
23684
+ options
23685
+ ),
23686
+ platformButtonPrimaryColor: this.toAstProperty(
23687
+ bitType,
23688
+ ConfigKey.property_platformButtonPrimaryColor,
23689
+ data.platformButtonPrimaryColor,
23690
+ options
23691
+ ),
23692
+ platformButtonBackgroundColor: this.toAstProperty(
23693
+ bitType,
23694
+ ConfigKey.property_platformButtonBackgroundColor,
23695
+ data.platformButtonBackgroundColor,
23696
+ options
23697
+ ),
23698
+ platformMessageBackgroundColor: this.toAstProperty(
23699
+ bitType,
23700
+ ConfigKey.property_platformMessageBackgroundColor,
23701
+ data.platformMessageBackgroundColor,
23702
+ options
23703
+ ),
23704
+ platformBackgroundImage: this.toImageResource(context, data.platformBackgroundImage),
23114
23705
  productId: this.toAstProperty(bitType, ConfigKey.property_productId, data.productId, options),
23115
23706
  product: this.toAstProperty(bitType, ConfigKey.property_product, data.product, options),
23116
23707
  // productList: this.toAstProperty(
@@ -23182,7 +23773,6 @@ var Builder = class extends BaseBuilder {
23182
23773
  item: this.handleJsonText(context, TextLocation.tag, data.item),
23183
23774
  lead: this.handleJsonText(context, TextLocation.tag, data.lead),
23184
23775
  pageNumber: this.handleJsonText(context, TextLocation.tag, data.pageNumber),
23185
- sourcePageNumber: this.handleJsonText(context, TextLocation.tag, data.sourcePageNumber),
23186
23776
  marginNumber: this.handleJsonText(context, TextLocation.tag, data.marginNumber),
23187
23777
  hint: this.handleJsonText(context, TextLocation.tag, data.hint),
23188
23778
  instruction: this.handleJsonText(context, TextLocation.tag, data.instruction),
@@ -23285,15 +23875,7 @@ var Builder = class extends BaseBuilder {
23285
23875
  objectUtils.removeUnwantedProperties(node, {
23286
23876
  ignoreAllFalse: true,
23287
23877
  ignoreUndefined: ["example"],
23288
- ignoreEmptyArrays: [
23289
- "item",
23290
- "lead",
23291
- "pageNumber",
23292
- "sourcePageNumber",
23293
- "marginNumber",
23294
- "hint",
23295
- "instruction"
23296
- ]
23878
+ ignoreEmptyArrays: ["item", "lead", "pageNumber", "marginNumber", "hint", "instruction"]
23297
23879
  });
23298
23880
  return nodeValidator.validateBit(node);
23299
23881
  }
@@ -23801,21 +24383,53 @@ var Builder = class extends BaseBuilder {
23801
24383
  return node;
23802
24384
  }
23803
24385
  /**
23804
- * Build table node
24386
+ * Build table / table extended node
23805
24387
  *
23806
24388
  * @param data - data for the node
23807
24389
  * @returns
23808
24390
  */
23809
24391
  buildTable(context, dataIn) {
23810
24392
  if (!dataIn) return void 0;
23811
- const node = {
23812
- columns: (dataIn.columns || []).map(
24393
+ const node = normalizeTableFormat(context.bitType, dataIn);
24394
+ const nodeTable = node;
24395
+ const nodeTableExtended = node;
24396
+ if (Array.isArray(nodeTable.columns) && nodeTable.columns.length > 0) {
24397
+ nodeTable.columns = nodeTable.columns.map(
23813
24398
  (col) => this.handleJsonText(context, TextLocation.tag, col)
23814
- ),
23815
- data: (dataIn.data || []).map(
24399
+ );
24400
+ }
24401
+ if (Array.isArray(nodeTable.data) && nodeTable.data.length > 0) {
24402
+ nodeTable.data = nodeTable.data.map(
23816
24403
  (row) => (row || []).map((cell) => this.handleJsonText(context, TextLocation.tag, cell))
23817
- )
24404
+ );
24405
+ }
24406
+ const buildSection = (section) => {
24407
+ if (!section || !Array.isArray(section.rows)) return void 0;
24408
+ const rows = section.rows.map((row) => {
24409
+ const cells = (row.cells || []).map((cell) => {
24410
+ const tableCell = {
24411
+ content: this.handleJsonText(context, TextLocation.tag, cell.content)
24412
+ };
24413
+ if (cell.title != null) tableCell.title = cell.title;
24414
+ if (cell.rowspan != null) tableCell.rowspan = cell.rowspan;
24415
+ if (cell.colspan != null) tableCell.colspan = cell.colspan;
24416
+ if (cell.scope) tableCell.scope = cell.scope;
24417
+ return tableCell;
24418
+ });
24419
+ return {
24420
+ cells
24421
+ };
24422
+ });
24423
+ return {
24424
+ rows
24425
+ };
23818
24426
  };
24427
+ const head = buildSection(nodeTableExtended.head);
24428
+ if (head && head.rows?.length > 0) nodeTableExtended.head = head;
24429
+ const body = buildSection(nodeTableExtended.body);
24430
+ if (body && body.rows?.length > 0) nodeTableExtended.body = body;
24431
+ const foot = buildSection(nodeTableExtended.foot);
24432
+ if (foot && foot.rows?.length > 0) nodeTableExtended.foot = foot;
23819
24433
  return node;
23820
24434
  }
23821
24435
  /**
@@ -23839,7 +24453,7 @@ var Builder = class extends BaseBuilder {
23839
24453
  if (!data) return void 0;
23840
24454
  const defaultExample = data.__sampleSolutionAst;
23841
24455
  const node = {
23842
- question: data.question ?? "",
24456
+ question: this.handleJsonText(context, TextLocation.body, data.question),
23843
24457
  partialAnswer: data.partialAnswer ?? "",
23844
24458
  sampleSolution: data.sampleSolution ?? "",
23845
24459
  additionalSolutions: data.additionalSolutions ?? void 0,
@@ -23853,9 +24467,9 @@ var Builder = class extends BaseBuilder {
23853
24467
  };
23854
24468
  objectUtils.removeUnwantedProperties(node, {
23855
24469
  ignoreAllFalse: true,
23856
- ignoreEmptyArrays: ["item", "hint", "instruction"],
24470
+ ignoreEmptyArrays: ["question", "item", "hint", "instruction"],
23857
24471
  ignoreUndefined: ["example"],
23858
- ignoreEmptyString: ["question", "partialAnswer", "sampleSolution"]
24472
+ ignoreEmptyString: ["partialAnswer", "sampleSolution"]
23859
24473
  });
23860
24474
  return node;
23861
24475
  }
@@ -24393,7 +25007,7 @@ var Builder = class extends BaseBuilder {
24393
25007
  buildStatement(context, data) {
24394
25008
  if (!data) return void 0;
24395
25009
  const node = {
24396
- statement: data.statement ?? "",
25010
+ statement: this.handleJsonText(context, TextLocation.tag, data.statement),
24397
25011
  isCorrect: !!data.isCorrect,
24398
25012
  item: this.handleJsonText(context, TextLocation.tag, data.item),
24399
25013
  lead: this.handleJsonText(context, TextLocation.tag, data.lead),
@@ -24403,7 +25017,7 @@ var Builder = class extends BaseBuilder {
24403
25017
  };
24404
25018
  objectUtils.removeUnwantedProperties(node, {
24405
25019
  ignoreAllFalse: true,
24406
- // ignoreAllEmptyArrays: true,
25020
+ ignoreEmptyArrays: ["statement"],
24407
25021
  ignoreUndefined: ["example"]
24408
25022
  });
24409
25023
  return node;
@@ -24615,7 +25229,7 @@ var Builder = class extends BaseBuilder {
24615
25229
  const node = {
24616
25230
  heading: this.buildHeading(context, data.heading),
24617
25231
  questions: this.buildQuestions(context, data.questions),
24618
- elements: data.elements,
25232
+ elements: this.handleJsonText(context, TextLocation.body, data.elements),
24619
25233
  flashcards: this.buildFlashcards(context, data.flashcards),
24620
25234
  definitions: this.buildDefinitionList(context, data.definitions ?? data.legend),
24621
25235
  statement: this.buildStatement(context, data.statement),
@@ -24634,7 +25248,9 @@ var Builder = class extends BaseBuilder {
24634
25248
  // captionDefinitionList: this.buildCaptionDefinitionList(context, data.captionDefinitionList),
24635
25249
  cardBits: this.buildCardBits(context, data.cardBits)
24636
25250
  };
24637
- objectUtils.removeUnwantedProperties(node);
25251
+ objectUtils.removeUnwantedProperties(node, {
25252
+ ignoreEmptyObjects: ["table"]
25253
+ });
24638
25254
  return Object.keys(node).length > 0 ? node : void 0;
24639
25255
  }
24640
25256
  /**
@@ -25138,6 +25754,7 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
25138
25754
  __publicField(this, "hasCardSet", false);
25139
25755
  __publicField(this, "hasFooter", false);
25140
25756
  __publicField(this, "inTag", true);
25757
+ __publicField(this, "skipTableTraversal", false);
25141
25758
  this.enter = this.enter.bind(this);
25142
25759
  this.between = this.between.bind(this);
25143
25760
  this.exit = this.exit.bind(this);
@@ -25606,7 +26223,6 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
25606
26223
  if (this.isEmptyText(item)) return false;
25607
26224
  if (!this.isEmptyText(parent?.value?.lead)) return true;
25608
26225
  if (!this.isEmptyText(parent?.value?.pageNumber)) return true;
25609
- if (!this.isEmptyText(parent?.value?.sourcePageNumber)) return true;
25610
26226
  if (!this.isEmptyText(parent?.value?.marginNumber)) return true;
25611
26227
  this.writeNL_IfNotChain(route);
25612
26228
  this.writeOPC();
@@ -25620,7 +26236,6 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
25620
26236
  const parent = this.getParentNode(route);
25621
26237
  if (this.isEmptyText(lead)) return false;
25622
26238
  if (!this.isEmptyText(parent?.value?.pageNumber)) return true;
25623
- if (!this.isEmptyText(parent?.value?.sourcePageNumber)) return true;
25624
26239
  if (!this.isEmptyText(parent?.value?.marginNumber)) return true;
25625
26240
  this.writeNL_IfNotChain(route);
25626
26241
  this.writeOPC();
@@ -25636,7 +26251,6 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
25636
26251
  const pageNumber = node.value;
25637
26252
  const parent = this.getParentNode(route);
25638
26253
  if (this.isEmptyText(pageNumber)) return false;
25639
- if (!this.isEmptyText(parent?.value?.sourcePageNumber)) return true;
25640
26254
  if (!this.isEmptyText(parent?.value?.marginNumber)) return true;
25641
26255
  this.writeNL_IfNotChain(route);
25642
26256
  this.writeOPC();
@@ -25650,31 +26264,6 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
25650
26264
  this.writeCL();
25651
26265
  return true;
25652
26266
  }
25653
- // bitmarkAst -> bits -> bitsValue -> sourcePageNumber
25654
- enter_sourcePageNumber(node, route) {
25655
- const sourcePageNumber = node.value;
25656
- const parent = this.getParentNode(route);
25657
- if (this.isEmptyText(sourcePageNumber)) return false;
25658
- if (!this.isEmptyText(parent?.value?.marginNumber)) return true;
25659
- this.writeNL_IfNotChain(route);
25660
- this.writeOPC();
25661
- this.writeTextOrValue(parent?.value?.item ?? "", TextFormat.bitmarkText, TextLocation.tag);
25662
- this.writeCL();
25663
- this.writeOPC();
25664
- this.writeTextOrValue(parent?.value?.lead ?? "", TextFormat.bitmarkText, TextLocation.tag);
25665
- this.writeCL();
25666
- this.writeOPC();
25667
- this.writeTextOrValue(
25668
- parent?.value?.pageNumber ?? "",
25669
- TextFormat.bitmarkText,
25670
- TextLocation.tag
25671
- );
25672
- this.writeCL();
25673
- this.writeOPC();
25674
- this.writeTextOrValue(sourcePageNumber ?? "", TextFormat.bitmarkText, TextLocation.tag);
25675
- this.writeCL();
25676
- return true;
25677
- }
25678
26267
  // bitmarkAst -> bits -> bitsValue -> marginNumber
25679
26268
  enter_marginNumber(node, route) {
25680
26269
  const marginNumber = node.value;
@@ -25695,13 +26284,6 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
25695
26284
  );
25696
26285
  this.writeCL();
25697
26286
  this.writeOPC();
25698
- this.writeTextOrValue(
25699
- parent?.value?.sourcePageNumber ?? "",
25700
- TextFormat.bitmarkText,
25701
- TextLocation.tag
25702
- );
25703
- this.writeCL();
25704
- this.writeOPC();
25705
26287
  this.writeTextOrValue(marginNumber, TextFormat.bitmarkText, TextLocation.tag);
25706
26288
  this.writeCL();
25707
26289
  return true;
@@ -25875,7 +26457,7 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
25875
26457
  enter_elements(_node, _route) {
25876
26458
  }
25877
26459
  between_elements(_node, _left, _right, _route) {
25878
- this.writeCardSetVariantDivider();
26460
+ this.writeCardSetSideDivider();
25879
26461
  }
25880
26462
  // bitmarkAst -> bits -> bitsValue -> cardNode -> flashcards
25881
26463
  between_flashcards(_node, _left, _right, _route) {
@@ -26002,6 +26584,7 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
26002
26584
  enter_matrix(_node, _route) {
26003
26585
  }
26004
26586
  between_matrix(_node, _left, _right, _route) {
26587
+ if (!this.isCardAllowed) return;
26005
26588
  this.writeCardSetCardDivider();
26006
26589
  }
26007
26590
  // bitmarkAst -> bits -> bitsValue -> cardNode -> pairs -> pairsValue -> values
@@ -26022,12 +26605,83 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
26022
26605
  this.writeCardSetCardDivider();
26023
26606
  }
26024
26607
  // bitmarkAst -> bits -> bitsValue -> cardNode -> table
26608
+ enter_table(node, route) {
26609
+ const parent = this.getParentNode(route);
26610
+ if (parent?.key !== NodeType.cardNode) return true;
26611
+ const table = node.value;
26612
+ if (!table) return true;
26613
+ if (this.writeAdvancedTable(table)) {
26614
+ return false;
26615
+ }
26616
+ return true;
26617
+ }
26025
26618
  between_table(_node, _left, _right, route) {
26026
26619
  const parent = this.getParentNode(route);
26027
26620
  if (parent?.key !== NodeType.cardNode) return;
26028
26621
  if (!this.isCardAllowed) return;
26029
26622
  this.writeCardSetCardDivider();
26030
26623
  }
26624
+ writeAdvancedTable(table) {
26625
+ const normalized = normalizeTableFormat(BitType.tableExtended, table);
26626
+ const sections = [
26627
+ { key: "thead", qualifier: "thead", section: normalized.head },
26628
+ { key: "tbody", qualifier: void 0, section: normalized.body },
26629
+ { key: "tfoot", qualifier: "tfoot", section: normalized.foot }
26630
+ ];
26631
+ let rowCount = 0;
26632
+ for (const { key, qualifier, section } of sections) {
26633
+ const rows = section?.rows ?? [];
26634
+ if (rows.length === 0) {
26635
+ continue;
26636
+ }
26637
+ for (const row of rows) {
26638
+ this.writeCardSetCardDivider(qualifier);
26639
+ this.writeTableRow(row, key);
26640
+ rowCount++;
26641
+ }
26642
+ }
26643
+ return rowCount > 0;
26644
+ }
26645
+ writeTableRow(row, section) {
26646
+ const cells = row?.cells ?? [];
26647
+ if (cells.length === 0) return;
26648
+ for (let index = 0; index < cells.length; index++) {
26649
+ if (index > 0) {
26650
+ this.writeCardSetSideDivider();
26651
+ }
26652
+ this.writeNL();
26653
+ this.writeTableCell(cells[index], section);
26654
+ }
26655
+ }
26656
+ writeTableCell(cell, section) {
26657
+ const defaultCellType = section === "tbody" ? "td" : "th";
26658
+ const cellType = cell.title ? "th" : "td";
26659
+ if (cellType !== defaultCellType) {
26660
+ this.writeTableCellProperty("tableCellType", cellType);
26661
+ this.writeNL();
26662
+ }
26663
+ if (cell.rowspan && cell.rowspan > 1) {
26664
+ this.writeTableCellProperty("tableRowSpan", cell.rowspan);
26665
+ this.writeNL();
26666
+ }
26667
+ if (cell.colspan && cell.colspan > 1) {
26668
+ this.writeTableCellProperty("tableColSpan", cell.colspan);
26669
+ this.writeNL();
26670
+ }
26671
+ if (cell.scope) {
26672
+ this.writeTableCellProperty("tableScope", cell.scope);
26673
+ this.writeNL();
26674
+ }
26675
+ const content = cell.content ?? instance3.EMPTY_STRING;
26676
+ this.writeTextOrValue(content, this.textFormat, TextLocation.body);
26677
+ }
26678
+ writeTableCellProperty(name, value) {
26679
+ this.writeOPA();
26680
+ this.writeTagKey(name);
26681
+ this.writeColon();
26682
+ this.writeTextOrValue(`${value}`, TextFormat.plainText, TextLocation.tag);
26683
+ this.writeCL();
26684
+ }
26031
26685
  // bitmarkAst -> bits -> bitsValue -> cardNode -> table -> data
26032
26686
  // bitmarkAst -> bits -> bitsValue -> cardNode -> pronunciationTable -> data
26033
26687
  between_data(_node, _left, _right, route) {
@@ -26256,6 +26910,27 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
26256
26910
  this.writePropertyStyleResource(node.key, resource);
26257
26911
  return true;
26258
26912
  }
26913
+ // bitmarkAst -> bits -> bitsValue -> platformIcon
26914
+ enter_platformIcon(node, _route) {
26915
+ const resource = node.value;
26916
+ this.writeNL();
26917
+ this.writePropertyStyleResource(node.key, resource);
26918
+ return true;
26919
+ }
26920
+ // bitmarkAst -> bits -> bitsValue -> platformLogo
26921
+ enter_platformLogo(node, _route) {
26922
+ const resource = node.value;
26923
+ this.writeNL();
26924
+ this.writePropertyStyleResource(node.key, resource);
26925
+ return true;
26926
+ }
26927
+ // bitmarkAst -> bits -> bitsValue -> platformBackgroundImage
26928
+ enter_platformBackgroundImage(node, _route) {
26929
+ const resource = node.value;
26930
+ this.writeNL();
26931
+ this.writePropertyStyleResource(node.key, resource);
26932
+ return true;
26933
+ }
26259
26934
  exit_imagePlaceholder(_node, _route) {
26260
26935
  }
26261
26936
  // bitmarkAst -> bits -> bitsValue -> posterImage
@@ -26528,8 +27203,8 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
26528
27203
  } else {
26529
27204
  }
26530
27205
  }
26531
- // bitmarkAst -> bits -> bitsValue -> elements -> elementsValue
26532
- leaf_elementsValue(node, _route) {
27206
+ // bitmarkAst -> bits -> bitsValue -> cardNode -> elements -> elementsValue
27207
+ enter_elementsValue(node, _route) {
26533
27208
  if (node.value) {
26534
27209
  this.writeNL();
26535
27210
  this.writeTextOrValue(node.value, this.textFormat, TextLocation.body);
@@ -26612,10 +27287,19 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
26612
27287
  }
26613
27288
  }
26614
27289
  // bitmarkAst -> bits -> bitsValue -> questions -> questionsValue -> question
27290
+ // bitmarkAst -> bits -> bitsValue -> cardNode -> questions -> questionsValue -> question
27291
+ enter_question(node, route) {
27292
+ const parent = this.getParentNode(route);
27293
+ if (parent?.key !== NodeType.questionsValue) return;
27294
+ if (node.value) {
27295
+ this.writeNL();
27296
+ this.writeTextOrValue(node.value, this.textFormat, TextLocation.body);
27297
+ }
27298
+ }
26615
27299
  // bitmarkAst -> bits -> bitsValue -> cardNode -> flashcards -> flashcardsValue -> question
26616
27300
  leaf_question(node, route) {
26617
27301
  const parent = this.getParentNode(route);
26618
- if (parent?.key !== NodeType.questionsValue && parent?.key !== NodeType.flashcardsValue) return;
27302
+ if (parent?.key !== NodeType.flashcardsValue) return;
26619
27303
  if (node.value) {
26620
27304
  this.writeNL();
26621
27305
  this.writeTextOrValue(node.value, this.textFormat, TextLocation.body);
@@ -27091,12 +27775,12 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
27091
27775
  } else {
27092
27776
  }
27093
27777
  }
27094
- writeCardSetCardDivider() {
27778
+ writeCardSetCardDivider(qualifier) {
27095
27779
  this.writeNL();
27096
- if (this.options.cardSetVersion === CardSetVersion.v1) {
27097
- this.write("===");
27098
- } else {
27099
- this.write("====");
27780
+ const divider = this.getCardDividerMarker();
27781
+ this.write(divider);
27782
+ if (qualifier) {
27783
+ this.appendCardDividerQualifier(qualifier);
27100
27784
  }
27101
27785
  }
27102
27786
  writeCardSetSideDivider() {
@@ -27115,6 +27799,20 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
27115
27799
  this.write("++");
27116
27800
  }
27117
27801
  }
27802
+ getCardDividerMarker() {
27803
+ return this.options.cardSetVersion === CardSetVersion.v1 ? "===" : "====";
27804
+ }
27805
+ appendCardDividerQualifier(qualifier) {
27806
+ const marker = this.getCardDividerMarker();
27807
+ const normalizedQualifier = instance3.breakscape(qualifier, {
27808
+ format: TextFormat.plainText,
27809
+ location: TextLocation.tag
27810
+ });
27811
+ this.write(" ");
27812
+ this.write(normalizedQualifier);
27813
+ this.write(" ");
27814
+ this.write(marker);
27815
+ }
27118
27816
  writeNL_IfNotChain(route) {
27119
27817
  if (!this.isChain(route)) {
27120
27818
  this.writeNL();
@@ -27219,7 +27917,10 @@ var BitmarkGenerator = class extends AstWalkerGenerator {
27219
27917
  return !!writeFormat;
27220
27918
  }
27221
27919
  calculateIsCardAllowed() {
27222
- return this.isBodyBitmarkText && !this.isOfBitType1();
27920
+ return this.isBodyBitmarkText && !this.isOfBitType1() && !this.isTableBitType();
27921
+ }
27922
+ isTableBitType() {
27923
+ return this.isOfBitType([BitType.table]);
27223
27924
  }
27224
27925
  isOfBitType1() {
27225
27926
  return this.isOfBitType([
@@ -27526,10 +28227,6 @@ var JsonGenerator = class extends AstWalkerGenerator {
27526
28227
  enter_pageNumber(node, route) {
27527
28228
  return this.standardHandler(node, route, NodeType.bitsValue, { array: true });
27528
28229
  }
27529
- // bitmarkAst -> bits -> bitsValue -> sourcePageNumber
27530
- enter_sourcePageNumber(node, route) {
27531
- return this.standardHandler(node, route, NodeType.bitsValue, { array: true });
27532
- }
27533
28230
  // bitmarkAst -> bits -> bitsValue -> marginNumber
27534
28231
  enter_marginNumber(node, route) {
27535
28232
  return this.standardHandler(node, route, NodeType.bitsValue, { array: true });
@@ -27740,7 +28437,7 @@ var JsonGenerator = class extends AstWalkerGenerator {
27740
28437
  const parent = this.getParentNode(route);
27741
28438
  if (parent?.key !== NodeType.cardNode) return;
27742
28439
  if (statement) {
27743
- this.bitJson.statement = statement.statement ?? "";
28440
+ this.bitJson.statement = statement.statement ?? [];
27744
28441
  this.bitJson.isCorrect = statement.isCorrect ?? false;
27745
28442
  this.bitJson.example = statement.example;
27746
28443
  this.bitJson.isExample = statement.isExample;
@@ -27816,6 +28513,18 @@ var JsonGenerator = class extends AstWalkerGenerator {
27816
28513
  enter_imagePlaceholder(node, route) {
27817
28514
  return this.standardHandler(node, route, NodeType.bitsValue, { array: false });
27818
28515
  }
28516
+ // bitmarkAst -> bits -> bitsValue -> platformIcon
28517
+ enter_platformIcon(node, route) {
28518
+ return this.standardHandler(node, route, NodeType.bitsValue, { array: false });
28519
+ }
28520
+ // bitmarkAst -> bits -> bitsValue -> platformLogo
28521
+ enter_platformLogo(node, route) {
28522
+ return this.standardHandler(node, route, NodeType.bitsValue, { array: false });
28523
+ }
28524
+ // bitmarkAst -> bits -> bitsValue -> platformBackgroundImage
28525
+ enter_platformBackgroundImage(node, route) {
28526
+ return this.standardHandler(node, route, NodeType.bitsValue, { array: false });
28527
+ }
27819
28528
  // bitmarkAst -> bits -> bitsValue -> resources
27820
28529
  enter_resources(node, route) {
27821
28530
  const resources = node.value;
@@ -28252,7 +28961,6 @@ var JsonGenerator = class extends AstWalkerGenerator {
28252
28961
  delete bitJson.item;
28253
28962
  delete bitJson.lead;
28254
28963
  delete bitJson.pageNumber;
28255
- delete bitJson.sourcePageNumber;
28256
28964
  delete bitJson.marginNumber;
28257
28965
  delete bitJson.hint;
28258
28966
  delete bitJson.instruction;
@@ -28264,8 +28972,6 @@ var JsonGenerator = class extends AstWalkerGenerator {
28264
28972
  if (bitJson.lead == null || bitJson.lead?.length === 0) delete bitJson.lead;
28265
28973
  if (bitJson.pageNumber == null || bitJson.pageNumber?.length === 0)
28266
28974
  delete bitJson.pageNumber;
28267
- if (bitJson.sourcePageNumber == null || bitJson.sourcePageNumber?.length === 0)
28268
- delete bitJson.sourcePageNumber;
28269
28975
  if (bitJson.marginNumber == null || bitJson.marginNumber?.length === 0)
28270
28976
  delete bitJson.marginNumber;
28271
28977
  if (bitJson.hint == null || bitJson.hint?.length === 0) delete bitJson.hint;
@@ -28277,7 +28983,6 @@ var JsonGenerator = class extends AstWalkerGenerator {
28277
28983
  if (bitJson.hint == null) bitJson.hint = this.textDefault;
28278
28984
  if (bitJson.instruction == null) bitJson.instruction = this.textDefault;
28279
28985
  if (bitJson.pageNumber == null) bitJson.pageNumber = this.textDefault;
28280
- if (bitJson.sourcePageNumber == null) bitJson.sourcePageNumber = this.textDefault;
28281
28986
  if (bitJson.marginNumber == null) bitJson.marginNumber = this.textDefault;
28282
28987
  }
28283
28988
  if (bitJson.body == null) bitJson.body = this.bodyDefault;
@@ -28354,6 +29059,9 @@ var JsonGenerator = class extends AstWalkerGenerator {
28354
29059
  if (bitJson.footer == null) bitJson.footer = this.textDefault;
28355
29060
  if (bitJson.questions == null) bitJson.questions = [];
28356
29061
  }
29062
+ if (instance2.isOfBitType(bitType, BitType.sequence)) {
29063
+ if (bitJson.elements == null) bitJson.elements = [];
29064
+ }
28357
29065
  if (bitType === BitType.matchMatrix) {
28358
29066
  isTopLevelExample = true;
28359
29067
  }
@@ -28414,6 +29122,7 @@ var JsonGenerator = class extends AstWalkerGenerator {
28414
29122
  }
28415
29123
  if (instance2.isOfBitType(bitType, BitType.book)) {
28416
29124
  if (bitJson.maxTocChapterLevel == null) bitJson.maxTocChapterLevel = -1;
29125
+ if (bitJson.hasPrintRestriction == null) bitJson.hasPrintRestriction = true;
28417
29126
  if (bitJson.hasMarkAsDone == null) bitJson.hasMarkAsDone = false;
28418
29127
  if (bitJson.processHandIn == null) bitJson.processHandIn = false;
28419
29128
  if (bitJson.isPublic == null) bitJson.isPublic = false;
@@ -29071,6 +29780,9 @@ var BitmarkPegParserHelper = class {
29071
29780
  __publicField(this, "cardIndex", 0);
29072
29781
  __publicField(this, "cardSideIndex", 0);
29073
29782
  __publicField(this, "cardVariantIndex", 0);
29783
+ __publicField(this, "currentCardQualifier");
29784
+ __publicField(this, "currentSideQualifier");
29785
+ __publicField(this, "currentVariantQualifier");
29074
29786
  __publicField(this, "parse");
29075
29787
  __publicField(this, "parserText");
29076
29788
  __publicField(this, "parserLocation");
@@ -29239,30 +29951,43 @@ var BitmarkPegParserHelper = class {
29239
29951
  cardIndex,
29240
29952
  cardSideIndex,
29241
29953
  cardVariantIndex: cardContentIndex,
29242
- value: value2
29954
+ value: value2,
29955
+ cardQualifier,
29956
+ cardSideQualifier,
29957
+ cardVariantQualifier
29243
29958
  } = cardData;
29244
29959
  let card = unparsedCardSet.cards[cardIndex];
29245
29960
  if (!card) {
29246
29961
  card = {
29247
- sides: []
29962
+ sides: [],
29963
+ qualifier: cardQualifier
29248
29964
  };
29249
29965
  unparsedCardSet.cards[cardIndex] = card;
29966
+ } else if (cardQualifier && !card.qualifier) {
29967
+ card.qualifier = cardQualifier;
29250
29968
  }
29251
29969
  let side = card.sides[cardSideIndex];
29252
29970
  if (!side) {
29253
29971
  side = {
29254
- variants: []
29972
+ variants: [],
29973
+ qualifier: cardSideQualifier
29255
29974
  };
29256
29975
  card.sides[cardSideIndex] = side;
29976
+ } else if (cardSideQualifier && !side.qualifier) {
29977
+ side.qualifier = cardSideQualifier;
29257
29978
  }
29258
29979
  const variant = side.variants[cardContentIndex];
29259
29980
  if (!variant) {
29260
29981
  side.variants[cardContentIndex] = {
29261
29982
  value: value2,
29262
- parser: parser3
29983
+ parser: parser3,
29984
+ qualifier: cardVariantQualifier
29263
29985
  };
29264
29986
  } else {
29265
29987
  side.variants[cardContentIndex].value += value2;
29988
+ if (cardVariantQualifier && !variant.qualifier) {
29989
+ variant.qualifier = cardVariantQualifier;
29990
+ }
29266
29991
  }
29267
29992
  }
29268
29993
  unparsedCardSet.cards = unparsedCardSet.cards.filter((card) => {
@@ -29275,12 +30000,14 @@ var BitmarkPegParserHelper = class {
29275
30000
  });
29276
30001
  for (const unparsedCard of unparsedCardSet.cards) {
29277
30002
  const card = {
29278
- sides: []
30003
+ sides: [],
30004
+ qualifier: unparsedCard.qualifier
29279
30005
  };
29280
30006
  cardSet.cards.push(card);
29281
30007
  for (const unparsedSide of unparsedCard.sides) {
29282
30008
  const side = {
29283
- variants: []
30009
+ variants: [],
30010
+ qualifier: unparsedSide.qualifier
29284
30011
  };
29285
30012
  card.sides.push(side);
29286
30013
  for (const unparsedContent of unparsedSide.variants) {
@@ -29305,7 +30032,8 @@ var BitmarkPegParserHelper = class {
29305
30032
  if (DEBUG_TRACE_CARD_PARSED) this.debugPrint("parsedCardContent", content);
29306
30033
  side.variants.push({
29307
30034
  parser: parser2,
29308
- content
30035
+ content,
30036
+ qualifier: unparsedContent.qualifier
29309
30037
  });
29310
30038
  }
29311
30039
  }
@@ -29325,12 +30053,18 @@ var BitmarkPegParserHelper = class {
29325
30053
  this.cardIndex = -1;
29326
30054
  this.cardSideIndex = 0;
29327
30055
  this.cardVariantIndex = 0;
30056
+ this.currentCardQualifier = void 0;
30057
+ this.currentSideQualifier = void 0;
30058
+ this.currentVariantQualifier = void 0;
29328
30059
  }
29329
30060
  handleCardSetEnd() {
29330
30061
  if (DEBUG_TRACE_CARD_SET_END) this.debugPrint("CardSetEnd");
29331
30062
  this.cardIndex = 0;
29332
30063
  this.cardSideIndex = 0;
29333
30064
  this.cardVariantIndex = 0;
30065
+ this.currentCardQualifier = void 0;
30066
+ this.currentSideQualifier = void 0;
30067
+ this.currentVariantQualifier = void 0;
29334
30068
  }
29335
30069
  handleCards(value) {
29336
30070
  return value;
@@ -29340,27 +30074,45 @@ var BitmarkPegParserHelper = class {
29340
30074
  let isCardDivider = false;
29341
30075
  let isSideDivider = false;
29342
30076
  let isVariantDivider = false;
30077
+ let qualifier;
29343
30078
  if (Array.isArray(value) && value.length === 2) {
29344
- value = value[0];
29345
- if (version === CardSetVersion.v1) {
29346
- isCardDivider = value === CARD_DIVIDER_V1;
29347
- isSideDivider = value === CARD_SIDE_DIVIDER_V1;
29348
- isVariantDivider = value === CARD_VARIANT_DIVIDER_V1;
30079
+ const [divider, maybeQualifier] = value;
30080
+ if (typeof divider === "string") {
30081
+ value = divider;
30082
+ if (typeof maybeQualifier === "string" && maybeQualifier.trim() === maybeQualifier && maybeQualifier.length > 0) {
30083
+ qualifier = maybeQualifier;
30084
+ }
29349
30085
  } else {
29350
- isCardDivider = value === CARD_DIVIDER_V2;
29351
- isSideDivider = value === CARD_SIDE_DIVIDER_V2;
29352
- isVariantDivider = value === CARD_VARIANT_DIVIDER_V2;
30086
+ value = divider;
29353
30087
  }
30088
+ } else if (Array.isArray(value) && value.length === 1) {
30089
+ const [divider] = value;
30090
+ value = divider;
30091
+ }
30092
+ if (version === CardSetVersion.v1) {
30093
+ isCardDivider = value === CARD_DIVIDER_V1;
30094
+ isSideDivider = value === CARD_SIDE_DIVIDER_V1;
30095
+ isVariantDivider = value === CARD_VARIANT_DIVIDER_V1;
30096
+ } else {
30097
+ isCardDivider = value === CARD_DIVIDER_V2;
30098
+ isSideDivider = value === CARD_SIDE_DIVIDER_V2;
30099
+ isVariantDivider = value === CARD_VARIANT_DIVIDER_V2;
29354
30100
  }
29355
30101
  if (isCardDivider) {
29356
30102
  this.cardIndex++;
29357
30103
  this.cardSideIndex = 0;
29358
30104
  this.cardVariantIndex = 0;
30105
+ this.currentCardQualifier = qualifier;
30106
+ this.currentSideQualifier = void 0;
30107
+ this.currentVariantQualifier = void 0;
29359
30108
  } else if (isSideDivider) {
29360
30109
  this.cardSideIndex++;
29361
30110
  this.cardVariantIndex = 0;
30111
+ this.currentSideQualifier = qualifier;
30112
+ this.currentVariantQualifier = void 0;
29362
30113
  } else if (isVariantDivider) {
29363
30114
  this.cardVariantIndex++;
30115
+ this.currentVariantQualifier = qualifier;
29364
30116
  }
29365
30117
  if (this.isType(value, TypeKey.Card)) return value;
29366
30118
  return {
@@ -29369,7 +30121,10 @@ var BitmarkPegParserHelper = class {
29369
30121
  cardIndex: this.cardIndex,
29370
30122
  cardSideIndex: this.cardSideIndex,
29371
30123
  cardVariantIndex: this.cardVariantIndex,
29372
- value: ""
30124
+ value: "",
30125
+ cardQualifier: this.currentCardQualifier,
30126
+ cardSideQualifier: this.currentSideQualifier,
30127
+ cardVariantQualifier: this.currentVariantQualifier
29373
30128
  },
29374
30129
  parser: {
29375
30130
  text: this.parserText(),
@@ -29390,7 +30145,10 @@ var BitmarkPegParserHelper = class {
29390
30145
  cardIndex: this.cardIndex,
29391
30146
  cardSideIndex: this.cardSideIndex,
29392
30147
  cardVariantIndex: this.cardVariantIndex,
29393
- value
30148
+ value,
30149
+ cardQualifier: this.currentCardQualifier,
30150
+ cardSideQualifier: this.currentSideQualifier,
30151
+ cardVariantQualifier: this.currentVariantQualifier
29394
30152
  },
29395
30153
  parser: {
29396
30154
  text: this.parserText(),
@@ -29750,7 +30508,7 @@ var BitmarkPegParserValidator = class {
29750
30508
  let tagData = validTypeKeys.get(validTypeKey);
29751
30509
  if (!tagData && typeKey === TypeKey.Property) {
29752
30510
  const resourceKey = key.replace(/^@/, "&");
29753
- if (resourceKey === ConfigKey.resource_backgroundWallpaper || resourceKey === ConfigKey.resource_imagePlaceholder) {
30511
+ if (resourceKey === ConfigKey.resource_backgroundWallpaper || resourceKey === ConfigKey.resource_imagePlaceholder || resourceKey === ConfigKey.resource_platformIcon || resourceKey === ConfigKey.resource_platformLogo || resourceKey === ConfigKey.resource_platformBackgroundImage) {
29754
30512
  tagData = validTypeKeys.get(resourceKey);
29755
30513
  if (tagData) {
29756
30514
  typeKey = TypeKey.Resource;
@@ -30487,6 +31245,7 @@ function buildCards(context, bitType, textFormat, parsedCardSet, statementV1, st
30487
31245
  result = parsePronunciationTable(context, bitType, processedCardSet);
30488
31246
  break;
30489
31247
  case CardSetConfigKey.table:
31248
+ case CardSetConfigKey.tableExtended:
30490
31249
  result = parseTable(context, bitType, processedCardSet);
30491
31250
  break;
30492
31251
  case CardSetConfigKey.botActionResponses:
@@ -30523,20 +31282,23 @@ function processCardSet(context, parsedCardSet) {
30523
31282
  for (const card of parsedCardSet.cards) {
30524
31283
  const processedCard = {
30525
31284
  no: cardNo++,
30526
- sides: []
31285
+ sides: [],
31286
+ qualifier: card.qualifier
30527
31287
  };
30528
31288
  processedCardSet.cards.push(processedCard);
30529
31289
  for (const side of card.sides) {
30530
31290
  const processedSide = {
30531
31291
  no: sideNo++,
30532
- variants: []
31292
+ variants: [],
31293
+ qualifier: side.qualifier
30533
31294
  };
30534
31295
  processedCard.sides.push(processedSide);
30535
31296
  for (const variant of side.variants) {
30536
31297
  const { parser: parser2, content } = variant;
30537
31298
  const processedVariant = {
30538
31299
  parser: parser2,
30539
- no: variantNo++
31300
+ no: variantNo++,
31301
+ qualifier: variant.qualifier
30540
31302
  };
30541
31303
  processedSide.variants.push(processedVariant);
30542
31304
  const tagsConfig = instance2.getTagsConfigForCardSet(bitType, sideNo, variantNo);
@@ -30650,7 +31412,8 @@ function parseElements(_context, _bitType, cardSet) {
30650
31412
  for (const side of card.sides) {
30651
31413
  for (const content of side.variants) {
30652
31414
  const tags2 = content.data;
30653
- elements.push(tags2.cardBodyStr ?? "");
31415
+ const element = tags2.cardBody?.body ?? tags2.cardBodyStr ?? instance3.EMPTY_STRING;
31416
+ elements.push(element);
30654
31417
  }
30655
31418
  }
30656
31419
  }
@@ -30667,7 +31430,7 @@ function parseStatements(_context, _bitType, cardSet, statementV1, statementsV1)
30667
31430
  if (Array.isArray(chainedStatements)) {
30668
31431
  for (const s of chainedStatements) {
30669
31432
  const statement = {
30670
- statement: s.statement ?? "",
31433
+ statement: s.statement ?? [],
30671
31434
  isCorrect: s.isCorrect,
30672
31435
  item: s.item,
30673
31436
  lead: s.lead,
@@ -30809,7 +31572,7 @@ function parseQuestions(_context, _bitType, cardSet) {
30809
31572
  for (const content of side.variants) {
30810
31573
  const tags2 = content.data;
30811
31574
  const q = {
30812
- question: tags2.cardBodyStr ?? "",
31575
+ question: tags2.cardBody?.body ?? tags2.cardBodyStr ?? instance3.EMPTY_STRING,
30813
31576
  ...tags2
30814
31577
  };
30815
31578
  if (q) questions.push(q);
@@ -31013,37 +31776,158 @@ function parsePronunciationTable(_context, _bitType, cardSet) {
31013
31776
  };
31014
31777
  return { pronunciationTable: table };
31015
31778
  }
31016
- function parseTable(_context, _bitType, cardSet) {
31017
- let isHeading = false;
31018
- const columns = [];
31019
- const rows = [];
31020
- let rowValues = [];
31779
+ function parseTable(context, _bitType, cardSet) {
31780
+ const sectionRows = {
31781
+ thead: [],
31782
+ tbody: [],
31783
+ tfoot: []
31784
+ };
31785
+ const getNormalizedQualifier = (rawQualifier) => {
31786
+ if (!rawQualifier) return void 0;
31787
+ const normalized = rawQualifier.trim().toLowerCase();
31788
+ if (normalized === "thead" || normalized === "tbody" || normalized === "tfoot") {
31789
+ return normalized;
31790
+ }
31791
+ context.addWarning(`Unknown table section qualifier '${rawQualifier}', defaulting to tbody.`);
31792
+ return void 0;
31793
+ };
31794
+ const isLegacyHeadingRow = (card, cardIndex) => {
31795
+ if (cardIndex !== 0) return false;
31796
+ return card.sides.some(
31797
+ (side) => side.variants.some((variant) => {
31798
+ const titles = variant.data.title;
31799
+ return Array.isArray(titles) && titles[1]?.titleAst;
31800
+ })
31801
+ );
31802
+ };
31803
+ const readExtraProperty = (extra, key) => {
31804
+ if (!extra) return void 0;
31805
+ const value = extra[key];
31806
+ return Array.isArray(value) ? value[0] : value;
31807
+ };
31808
+ const cleanupExtraProperties = (tags2, keys) => {
31809
+ const extra = tags2.extraProperties;
31810
+ if (!extra) return;
31811
+ for (const key of keys) {
31812
+ if (Object.prototype.hasOwnProperty.call(extra, key)) delete extra[key];
31813
+ }
31814
+ if (Object.keys(extra).length === 0) {
31815
+ delete tags2.extraProperties;
31816
+ }
31817
+ };
31818
+ const normalizeCellType = (raw, section) => {
31819
+ if (typeof raw === "string") {
31820
+ const normalized = raw.trim().toLowerCase();
31821
+ if (normalized === "th" || normalized === "td") {
31822
+ return normalized;
31823
+ }
31824
+ context.addWarning(
31825
+ `Invalid table cell type '${raw}', using default for section '${section}'.`
31826
+ );
31827
+ }
31828
+ return section === "tbody" ? "td" : "th";
31829
+ };
31830
+ const normalizeSpan = (raw, kind) => {
31831
+ if (raw == null) return 1;
31832
+ const numeric = instance6.asNumber(raw);
31833
+ if (numeric == null || !Number.isInteger(numeric) || numeric < 1) {
31834
+ context.addWarning(`Invalid table ${kind} '${raw}', defaulting to 1.`);
31835
+ return 1;
31836
+ }
31837
+ return numeric;
31838
+ };
31839
+ const normalizeScope = (raw) => {
31840
+ if (raw == null) return void 0;
31841
+ if (typeof raw !== "string") {
31842
+ context.addWarning(`Invalid table scope '${raw}', ignoring.`);
31843
+ return void 0;
31844
+ }
31845
+ const normalized = raw.trim().toLowerCase();
31846
+ switch (normalized) {
31847
+ case "row":
31848
+ case "col":
31849
+ case "rowgroup":
31850
+ case "colgroup":
31851
+ return normalized;
31852
+ default:
31853
+ context.addWarning(`Invalid table scope '${raw}', ignoring.`);
31854
+ return void 0;
31855
+ }
31856
+ };
31857
+ const buildCell = (variant, section) => {
31858
+ const tags2 = variant.data;
31859
+ const heading = tags2.title && tags2.title[1]?.titleAst;
31860
+ const bodyContent = tags2.cardBody?.body ?? tags2.cardBodyStr ?? instance3.EMPTY_STRING;
31861
+ const content = heading ?? bodyContent;
31862
+ const cellTypeRaw = tags2.tableCellType ?? readExtraProperty(tags2.extraProperties, "tableCellType");
31863
+ const rowSpanRaw = tags2.tableRowSpan ?? readExtraProperty(tags2.extraProperties, "tableRowSpan");
31864
+ const colSpanRaw = tags2.tableColSpan ?? readExtraProperty(tags2.extraProperties, "tableColSpan");
31865
+ const scopeRaw = tags2.tableScope ?? readExtraProperty(tags2.extraProperties, "tableScope");
31866
+ cleanupExtraProperties(tags2, ["tableCellType", "tableRowSpan", "tableColSpan", "tableScope"]);
31867
+ const cellType = normalizeCellType(cellTypeRaw, section);
31868
+ const rowspan = normalizeSpan(rowSpanRaw, "rowspan");
31869
+ const colspan = normalizeSpan(colSpanRaw, "colspan");
31870
+ const scope = normalizeScope(scopeRaw);
31871
+ const cell = {
31872
+ content
31873
+ };
31874
+ if (cellType === "th") cell.title = true;
31875
+ if (rowspan > 1) cell.rowspan = rowspan;
31876
+ if (colspan > 1) cell.colspan = colspan;
31877
+ if (scope) cell.scope = scope;
31878
+ return cell;
31879
+ };
31880
+ const resolveSectionQualifier = (card) => {
31881
+ const cardQualifier = getNormalizedQualifier(card.qualifier);
31882
+ if (cardQualifier) return cardQualifier;
31883
+ for (const side of card.sides) {
31884
+ const sideQualifier = getNormalizedQualifier(side.qualifier);
31885
+ if (sideQualifier) return sideQualifier;
31886
+ for (const variant of side.variants) {
31887
+ const variantQualifier = getNormalizedQualifier(variant.qualifier);
31888
+ if (variantQualifier) return variantQualifier;
31889
+ }
31890
+ }
31891
+ return void 0;
31892
+ };
31021
31893
  for (let cardIdx = 0; cardIdx < cardSet.cards.length; cardIdx++) {
31022
31894
  const card = cardSet.cards[cardIdx];
31023
- isHeading = false;
31024
- rowValues = [];
31895
+ const qualifier = resolveSectionQualifier(card);
31896
+ const section = qualifier ? qualifier : isLegacyHeadingRow(card, cardIdx) ? "thead" : "tbody";
31897
+ const cells = [];
31025
31898
  for (const side of card.sides) {
31026
- for (const content of side.variants) {
31027
- const tags2 = content.data;
31028
- const { title, cardBody } = tags2;
31029
- const heading = title && title[1].titleAst;
31030
- if (cardIdx === 0 && heading != null) isHeading = true;
31031
- if (isHeading) {
31032
- columns.push(heading ?? []);
31033
- } else {
31034
- const value = cardBody?.body ?? [];
31035
- rowValues.push(value);
31036
- }
31899
+ for (const variant of side.variants) {
31900
+ cells.push(buildCell(variant, section));
31037
31901
  }
31038
31902
  }
31039
- if (!isHeading) {
31040
- rows.push(rowValues);
31041
- }
31903
+ sectionRows[section].push({
31904
+ cells
31905
+ });
31906
+ }
31907
+ const table = {};
31908
+ const hasHeadRows = sectionRows.thead.length > 0;
31909
+ const hasBodyRows = sectionRows.tbody.length > 0;
31910
+ const hasFootRows = sectionRows.tfoot.length > 0;
31911
+ if (hasHeadRows) {
31912
+ table.head = {
31913
+ rows: sectionRows.thead
31914
+ };
31915
+ }
31916
+ if (hasBodyRows) {
31917
+ table.body = {
31918
+ rows: sectionRows.tbody
31919
+ };
31920
+ }
31921
+ if (hasFootRows) {
31922
+ table.foot = {
31923
+ rows: sectionRows.tfoot
31924
+ };
31925
+ }
31926
+ if (!hasHeadRows && !hasBodyRows && !hasFootRows) {
31927
+ table.head = { rows: [] };
31928
+ table.body = { rows: [] };
31929
+ table.foot = { rows: [] };
31042
31930
  }
31043
- const table = {
31044
- columns,
31045
- data: rows
31046
- };
31047
31931
  return { table };
31048
31932
  }
31049
31933
  function parseBotActionResponses(_context, _bitType, cardSet) {
@@ -31194,11 +32078,11 @@ function extractHeadingCard(cardSet, valuesIsArray = false) {
31194
32078
  function defaultTagContentProcessor(context, _contentDepth, _tagsConfig, content, target) {
31195
32079
  const { type, value } = content;
31196
32080
  const { textFormat } = context;
31197
- const textParser9 = new TextParser();
32081
+ const textParser10 = new TextParser();
31198
32082
  const trimmedStringValue = stringUtils.trimmedString(value);
31199
32083
  switch (type) {
31200
32084
  case TypeKey.Instruction: {
31201
- target.instruction = textParser9.toAst(trimmedStringValue, {
32085
+ target.instruction = textParser10.toAst(trimmedStringValue, {
31202
32086
  format: textFormat,
31203
32087
  location: TextLocation.tag
31204
32088
  });
@@ -31209,7 +32093,7 @@ function defaultTagContentProcessor(context, _contentDepth, _tagsConfig, content
31209
32093
  break;
31210
32094
  }
31211
32095
  case TypeKey.Hint: {
31212
- target.hint = textParser9.toAst(trimmedStringValue, {
32096
+ target.hint = textParser10.toAst(trimmedStringValue, {
31213
32097
  format: textFormat,
31214
32098
  location: TextLocation.tag
31215
32099
  });
@@ -31239,7 +32123,7 @@ function defaultTagContentProcessor(context, _contentDepth, _tagsConfig, content
31239
32123
  format: TextFormat.bitmarkText,
31240
32124
  location: TextLocation.tag
31241
32125
  });
31242
- target.__sampleSolutionAst = textParser9.toAst(trimmedStringValue, {
32126
+ target.__sampleSolutionAst = textParser10.toAst(trimmedStringValue, {
31243
32127
  format: textFormat,
31244
32128
  location: TextLocation.tag
31245
32129
  });
@@ -31346,10 +32230,10 @@ function buildGap(context, _contentDepth, tagsConfig, content) {
31346
32230
  function itemLeadTagContentProcessor(context, _contentDepth, _tagsConfig, content, target) {
31347
32231
  const { textFormat } = context;
31348
32232
  const { value } = content;
31349
- const textParser9 = new TextParser();
32233
+ const textParser10 = new TextParser();
31350
32234
  const trimmedStringValue = stringUtils.trimmedString(value);
31351
32235
  if (!target.itemLead) target.itemLead = [];
31352
- const text = textParser9.toAst(trimmedStringValue, {
32236
+ const text = textParser10.toAst(trimmedStringValue, {
31353
32237
  format: textFormat,
31354
32238
  location: TextLocation.tag
31355
32239
  });
@@ -32027,7 +32911,7 @@ function resourceContentProcessor(context, _contentDepth, tagsConfig, content, t
32027
32911
  ...tags2
32028
32912
  });
32029
32913
  if (resource) {
32030
- if (configKey === ConfigKey.resource_backgroundWallpaper || configKey === ConfigKey.resource_imagePlaceholder) {
32914
+ if (configKey === ConfigKey.resource_backgroundWallpaper || configKey === ConfigKey.resource_imagePlaceholder || configKey === ConfigKey.resource_platformIcon || configKey === ConfigKey.resource_platformLogo || configKey === ConfigKey.resource_platformBackgroundImage) {
32031
32915
  if (target.propertyStyleResources) target.propertyStyleResources[resourceType] = resource;
32032
32916
  } else {
32033
32917
  resources.push(resource);
@@ -32100,7 +32984,9 @@ function buildTitles(_context, bitType, title) {
32100
32984
  }
32101
32985
 
32102
32986
  // src/parser/bitmark/peg/contentProcessors/TrueFalseTagContentProcessor.ts
32103
- function trueFalseTagContentProcessor(_context, _contentDepth, content, target) {
32987
+ var textParser9 = new TextParser();
32988
+ function trueFalseTagContentProcessor(context, _contentDepth, content, target) {
32989
+ const { textFormat } = context;
32104
32990
  const { type, value } = content;
32105
32991
  const trueFalse = target.trueFalse;
32106
32992
  if (!trueFalse) return;
@@ -32111,8 +32997,13 @@ function trueFalseTagContentProcessor(_context, _contentDepth, content, target)
32111
32997
  location: TextLocation.tag
32112
32998
  }
32113
32999
  );
33000
+ const textAst = textParser9.toAst(trimmedStringValue ?? "", {
33001
+ format: textFormat,
33002
+ location: TextLocation.tag
33003
+ });
32114
33004
  trueFalse.push({
32115
33005
  text: trimmedStringValue,
33006
+ textAst,
32116
33007
  isCorrect: type === TypeKey.True,
32117
33008
  __isDefaultExample: false
32118
33009
  });
@@ -32216,7 +33107,7 @@ function buildStatementsChoicesResponses(context, tagsConfig, trueFalseContent)
32216
33107
  const { statement: _ignore, ...tagsRest } = tags2;
32217
33108
  const statement = {
32218
33109
  ...firstTrueFalse,
32219
- statement: firstTrueFalse.text,
33110
+ statement: firstTrueFalse.textAst ?? [],
32220
33111
  ...tagsRest
32221
33112
  };
32222
33113
  if (statement) statements.push(statement);
@@ -32739,8 +33630,7 @@ var BitmarkPegParserProcessor = class {
32739
33630
  if (l > 0) result.item = result.itemLead[0];
32740
33631
  if (l > 1) result.lead = result.itemLead[1];
32741
33632
  if (l > 2) result.pageNumber = result.itemLead[2];
32742
- if (l > 3) result.sourcePageNumber = result.itemLead[3];
32743
- if (l > 4) result.marginNumber = result.itemLead[l - 1];
33633
+ if (l > 3) result.marginNumber = result.itemLead[l - 1];
32744
33634
  }
32745
33635
  if (inBit) {
32746
33636
  result.body = instance11.process(
@@ -33002,36 +33892,39 @@ function peg$parse2(input, options) {
33002
33892
  const peg$c7 = "text";
33003
33893
  const peg$c8 = "~~~~";
33004
33894
  const peg$c9 = "footer";
33005
- const peg$c10 = "--";
33006
- const peg$c11 = "++";
33007
- const peg$c12 = "===";
33008
- const peg$c13 = "==";
33009
- const peg$c14 = "[@id";
33010
- const peg$c15 = "#";
33011
- const peg$c16 = "[\u25BC";
33012
- const peg$c17 = "[\u25BA";
33013
- const peg$c18 = "[@";
33014
- const peg$c19 = "[%";
33015
- const peg$c20 = "[!";
33016
- const peg$c21 = "[?";
33017
- const peg$c22 = "[+";
33018
- const peg$c23 = "[-";
33019
- const peg$c24 = "[$";
33020
- const peg$c25 = "[_";
33021
- const peg$c26 = "[=";
33022
- const peg$c27 = "[&";
33023
- const peg$c28 = "^]";
33024
- const peg$c29 = "id:";
33025
- const peg$c30 = ".";
33026
- const peg$c31 = "\n";
33027
- const peg$c32 = "\r\n";
33895
+ const peg$c10 = " ";
33896
+ const peg$c11 = "--";
33897
+ const peg$c12 = "++";
33898
+ const peg$c13 = "===";
33899
+ const peg$c14 = "==";
33900
+ const peg$c15 = "[@id";
33901
+ const peg$c16 = "#";
33902
+ const peg$c17 = "[\u25BC";
33903
+ const peg$c18 = "[\u25BA";
33904
+ const peg$c19 = "[@";
33905
+ const peg$c20 = "[%";
33906
+ const peg$c21 = "[!";
33907
+ const peg$c22 = "[?";
33908
+ const peg$c23 = "[+";
33909
+ const peg$c24 = "[-";
33910
+ const peg$c25 = "[$";
33911
+ const peg$c26 = "[_";
33912
+ const peg$c27 = "[=";
33913
+ const peg$c28 = "[&";
33914
+ const peg$c29 = "^]";
33915
+ const peg$c30 = "id:";
33916
+ const peg$c31 = ".";
33917
+ const peg$c32 = "\n";
33918
+ const peg$c33 = "\r\n";
33028
33919
  const peg$r0 = /^[^\]]/;
33029
- const peg$r1 = /^[^:\]]/;
33030
- const peg$r2 = /^[^&:\]]/;
33031
- const peg$r3 = /^[^\n\r\u2028\u2029]/;
33032
- const peg$r4 = /^[ \t]/;
33033
- const peg$r5 = /^[\r\u2028-\u2029]/;
33034
- const peg$r6 = /^[ \t\n\r\u2028\u2029]/;
33920
+ const peg$r1 = /^[a-z]/;
33921
+ const peg$r2 = /^[a-z0-9\-]/;
33922
+ const peg$r3 = /^[^:\]]/;
33923
+ const peg$r4 = /^[^&:\]]/;
33924
+ const peg$r5 = /^[^\n\r\u2028\u2029]/;
33925
+ const peg$r6 = /^[ \t]/;
33926
+ const peg$r7 = /^[\r\u2028-\u2029]/;
33927
+ const peg$r8 = /^[ \t\n\r\u2028\u2029]/;
33035
33928
  const peg$e0 = peg$literalExpectation("[.", false);
33036
33929
  const peg$e1 = peg$classExpectation(["]"], true, false, false);
33037
33930
  const peg$e2 = peg$literalExpectation("]", false);
@@ -33044,40 +33937,43 @@ function peg$parse2(input, options) {
33044
33937
  const peg$e9 = peg$literalExpectation("text", false);
33045
33938
  const peg$e10 = peg$literalExpectation("~~~~", false);
33046
33939
  const peg$e11 = peg$literalExpectation("footer", false);
33047
- const peg$e12 = peg$literalExpectation("--", false);
33048
- const peg$e13 = peg$literalExpectation("++", false);
33049
- const peg$e14 = peg$literalExpectation("===", false);
33050
- const peg$e15 = peg$literalExpectation("==", false);
33051
- const peg$e16 = peg$literalExpectation("[@id", false);
33052
- const peg$e17 = peg$literalExpectation("#", false);
33053
- const peg$e18 = peg$literalExpectation("[\u25BC", false);
33054
- const peg$e19 = peg$literalExpectation("[\u25BA", false);
33055
- const peg$e20 = peg$literalExpectation("[@", false);
33056
- const peg$e21 = peg$literalExpectation("[%", false);
33057
- const peg$e22 = peg$literalExpectation("[!", false);
33058
- const peg$e23 = peg$literalExpectation("[?", false);
33059
- const peg$e24 = peg$literalExpectation("[+", false);
33060
- const peg$e25 = peg$literalExpectation("[-", false);
33061
- const peg$e26 = peg$literalExpectation("[$", false);
33062
- const peg$e27 = peg$literalExpectation("[_", false);
33063
- const peg$e28 = peg$literalExpectation("[=", false);
33064
- const peg$e29 = peg$literalExpectation("[&", false);
33065
- const peg$e30 = peg$literalExpectation("^]", false);
33066
- const peg$e31 = peg$literalExpectation("id:", false);
33067
- const peg$e32 = peg$classExpectation([":", "]"], true, false, false);
33068
- const peg$e33 = peg$literalExpectation(".", false);
33069
- const peg$e34 = peg$classExpectation(["&", ":", "]"], true, false, false);
33070
- const peg$e35 = peg$otherExpectation("Character");
33071
- const peg$e36 = peg$classExpectation(["\n", "\r", "\u2028", "\u2029"], true, false, false);
33072
- const peg$e37 = peg$otherExpectation("Blank Line");
33073
- const peg$e38 = peg$classExpectation([" ", " "], false, false, false);
33074
- const peg$e39 = peg$otherExpectation("Line Terminator");
33075
- const peg$e40 = peg$literalExpectation("\n", false);
33076
- const peg$e41 = peg$literalExpectation("\r\n", false);
33077
- const peg$e42 = peg$classExpectation(["\r", ["\u2028", "\u2029"]], false, false, false);
33078
- const peg$e43 = peg$otherExpectation("Whitespace, then Line Terminator");
33079
- const peg$e44 = peg$otherExpectation("whitespace");
33080
- const peg$e45 = peg$classExpectation([" ", " ", "\n", "\r", "\u2028", "\u2029"], false, false, false);
33940
+ const peg$e12 = peg$literalExpectation(" ", false);
33941
+ const peg$e13 = peg$literalExpectation("--", false);
33942
+ const peg$e14 = peg$literalExpectation("++", false);
33943
+ const peg$e15 = peg$literalExpectation("===", false);
33944
+ const peg$e16 = peg$literalExpectation("==", false);
33945
+ const peg$e17 = peg$classExpectation([["a", "z"]], false, false, false);
33946
+ const peg$e18 = peg$classExpectation([["a", "z"], ["0", "9"], "-"], false, false, false);
33947
+ const peg$e19 = peg$literalExpectation("[@id", false);
33948
+ const peg$e20 = peg$literalExpectation("#", false);
33949
+ const peg$e21 = peg$literalExpectation("[\u25BC", false);
33950
+ const peg$e22 = peg$literalExpectation("[\u25BA", false);
33951
+ const peg$e23 = peg$literalExpectation("[@", false);
33952
+ const peg$e24 = peg$literalExpectation("[%", false);
33953
+ const peg$e25 = peg$literalExpectation("[!", false);
33954
+ const peg$e26 = peg$literalExpectation("[?", false);
33955
+ const peg$e27 = peg$literalExpectation("[+", false);
33956
+ const peg$e28 = peg$literalExpectation("[-", false);
33957
+ const peg$e29 = peg$literalExpectation("[$", false);
33958
+ const peg$e30 = peg$literalExpectation("[_", false);
33959
+ const peg$e31 = peg$literalExpectation("[=", false);
33960
+ const peg$e32 = peg$literalExpectation("[&", false);
33961
+ const peg$e33 = peg$literalExpectation("^]", false);
33962
+ const peg$e34 = peg$literalExpectation("id:", false);
33963
+ const peg$e35 = peg$classExpectation([":", "]"], true, false, false);
33964
+ const peg$e36 = peg$literalExpectation(".", false);
33965
+ const peg$e37 = peg$classExpectation(["&", ":", "]"], true, false, false);
33966
+ const peg$e38 = peg$otherExpectation("Character");
33967
+ const peg$e39 = peg$classExpectation(["\n", "\r", "\u2028", "\u2029"], true, false, false);
33968
+ const peg$e40 = peg$otherExpectation("Blank Line");
33969
+ const peg$e41 = peg$classExpectation([" ", " "], false, false, false);
33970
+ const peg$e42 = peg$otherExpectation("Line Terminator");
33971
+ const peg$e43 = peg$literalExpectation("\n", false);
33972
+ const peg$e44 = peg$literalExpectation("\r\n", false);
33973
+ const peg$e45 = peg$classExpectation(["\r", ["\u2028", "\u2029"]], false, false, false);
33974
+ const peg$e46 = peg$otherExpectation("Whitespace, then Line Terminator");
33975
+ const peg$e47 = peg$otherExpectation("whitespace");
33976
+ const peg$e48 = peg$classExpectation([" ", " ", "\n", "\r", "\u2028", "\u2029"], false, false, false);
33081
33977
  function peg$f0(firstBit, bits) {
33082
33978
  return processor.buildBits([firstBit, ...bits]);
33083
33979
  }
@@ -33150,91 +34046,112 @@ function peg$parse2(input, options) {
33150
34046
  function peg$f23(value) {
33151
34047
  return helper.handleCardLineOrDivider(value, 2);
33152
34048
  }
33153
- function peg$f24(value) {
34049
+ function peg$f24(qualifier) {
34050
+ return ["====", qualifier];
34051
+ }
34052
+ function peg$f25() {
34053
+ return ["===="];
34054
+ }
34055
+ function peg$f26(qualifier) {
34056
+ return ["--", qualifier];
34057
+ }
34058
+ function peg$f27() {
34059
+ return ["--"];
34060
+ }
34061
+ function peg$f28(qualifier) {
34062
+ return ["++", qualifier];
34063
+ }
34064
+ function peg$f29() {
34065
+ return ["++"];
34066
+ }
34067
+ function peg$f30(value) {
33154
34068
  return helper.handleCardLine(value);
33155
34069
  }
33156
- function peg$f25(value) {
34070
+ function peg$f31(value) {
33157
34071
  return helper.handleCardSet(value[1].flat());
33158
34072
  }
33159
- function peg$f26() {
34073
+ function peg$f32() {
33160
34074
  helper.handleCardSetStart();
33161
34075
  }
33162
- function peg$f27() {
34076
+ function peg$f33() {
33163
34077
  helper.handleCardSetEnd();
33164
34078
  }
33165
- function peg$f28(value) {
34079
+ function peg$f34(value) {
33166
34080
  return helper.handleCards(value);
33167
34081
  }
33168
- function peg$f29(value) {
34082
+ function peg$f35(value) {
33169
34083
  return helper.handleCardLineOrDivider(value, 1);
33170
34084
  }
33171
- function peg$f30(value) {
34085
+ function peg$f36(value) {
33172
34086
  return helper.handleCardLine(value);
33173
34087
  }
33174
- function peg$f31(value) {
34088
+ function peg$f37(value) {
34089
+ return value;
34090
+ }
34091
+ function peg$f38(value) {
33175
34092
  return helper.handleCardContent(value);
33176
34093
  }
33177
- function peg$f32(value) {
34094
+ function peg$f39(value) {
33178
34095
  return { type: TypeKey.CardChar, value };
33179
34096
  }
33180
- function peg$f33(value) {
34097
+ function peg$f40(value) {
33181
34098
  return helper.handlePropertyTag("id", value);
33182
34099
  }
33183
- function peg$f34(level, title) {
34100
+ function peg$f41(level, title) {
33184
34101
  return helper.handleTag(TypeKey.Title, { level, title });
33185
34102
  }
33186
- function peg$f35(value) {
34103
+ function peg$f42(value) {
33187
34104
  return helper.handleTag(TypeKey.Anchor, value);
33188
34105
  }
33189
- function peg$f36(value) {
34106
+ function peg$f43(value) {
33190
34107
  return helper.handleTag(TypeKey.Reference, value);
33191
34108
  }
33192
- function peg$f37(key, value) {
34109
+ function peg$f44(key, value) {
33193
34110
  return helper.handlePropertyTag(key, value);
33194
34111
  }
33195
- function peg$f38(value) {
34112
+ function peg$f45(value) {
33196
34113
  return helper.handleTag(TypeKey.ItemLead, value);
33197
34114
  }
33198
- function peg$f39(value) {
34115
+ function peg$f46(value) {
33199
34116
  return helper.handleTag(TypeKey.Instruction, value);
33200
34117
  }
33201
- function peg$f40(value) {
34118
+ function peg$f47(value) {
33202
34119
  return helper.handleTag(TypeKey.Hint, value);
33203
34120
  }
33204
- function peg$f41(value) {
34121
+ function peg$f48(value) {
33205
34122
  return helper.handleTag(TypeKey.True, value);
33206
34123
  }
33207
- function peg$f42(value) {
34124
+ function peg$f49(value) {
33208
34125
  return helper.handleTag(TypeKey.False, value);
33209
34126
  }
33210
- function peg$f43(value) {
34127
+ function peg$f50(value) {
33211
34128
  return helper.handleTag(TypeKey.SampleSolution, value);
33212
34129
  }
33213
- function peg$f44(value) {
34130
+ function peg$f51(value) {
33214
34131
  return helper.handleTag(TypeKey.Gap, value);
33215
34132
  }
33216
- function peg$f45(value) {
34133
+ function peg$f52(value) {
33217
34134
  return helper.handleTag(TypeKey.Mark, value);
33218
34135
  }
33219
- function peg$f46(key, value) {
34136
+ function peg$f53(key, value) {
33220
34137
  return helper.handleResourceTag(key, value);
33221
34138
  }
33222
- function peg$f47(value) {
34139
+ function peg$f54(value) {
33223
34140
  return value;
33224
34141
  }
33225
- function peg$f48(value) {
34142
+ function peg$f55(value) {
33226
34143
  return value ? value.trim() : "";
33227
34144
  }
33228
- function peg$f49(value) {
34145
+ function peg$f56(value) {
33229
34146
  return value.length;
33230
34147
  }
33231
- function peg$f50(value) {
34148
+ function peg$f57(value) {
33232
34149
  return value ? value.trim() : null;
33233
34150
  }
33234
- function peg$f51(value) {
34151
+ function peg$f58(value) {
33235
34152
  return value ? value.trim() : "";
33236
34153
  }
33237
- function peg$f52() {
34154
+ function peg$f59() {
33238
34155
  return true;
33239
34156
  }
33240
34157
  let peg$currPos = options.peg$currPos | 0;
@@ -34152,35 +35069,28 @@ function peg$parse2(input, options) {
34152
35069
  return s0;
34153
35070
  }
34154
35071
  function peg$parseCardSetStart_V2() {
34155
- let s0, s1, s2, s3, s4, s5;
35072
+ let s0, s1, s2, s3;
34156
35073
  s0 = peg$currPos;
34157
- s1 = peg$parseNL();
35074
+ s1 = [];
35075
+ s2 = peg$parseWNL();
35076
+ if (s2 === peg$FAILED) {
35077
+ s2 = peg$parseNL();
35078
+ }
35079
+ if (s2 !== peg$FAILED) {
35080
+ while (s2 !== peg$FAILED) {
35081
+ s1.push(s2);
35082
+ s2 = peg$parseWNL();
35083
+ if (s2 === peg$FAILED) {
35084
+ s2 = peg$parseNL();
35085
+ }
35086
+ }
35087
+ } else {
35088
+ s1 = peg$FAILED;
35089
+ }
34158
35090
  if (s1 !== peg$FAILED) {
34159
35091
  s2 = peg$currPos;
34160
35092
  peg$silentFails++;
34161
- s3 = peg$currPos;
34162
- if (input.substr(peg$currPos, 4) === peg$c6) {
34163
- s4 = peg$c6;
34164
- peg$currPos += 4;
34165
- } else {
34166
- s4 = peg$FAILED;
34167
- if (peg$silentFails === 0) {
34168
- peg$fail(peg$e8);
34169
- }
34170
- }
34171
- if (s4 !== peg$FAILED) {
34172
- s5 = peg$parseWNL();
34173
- if (s5 !== peg$FAILED) {
34174
- s4 = [s4, s5];
34175
- s3 = s4;
34176
- } else {
34177
- peg$currPos = s3;
34178
- s3 = peg$FAILED;
34179
- }
34180
- } else {
34181
- peg$currPos = s3;
34182
- s3 = peg$FAILED;
34183
- }
35093
+ s3 = peg$parseCardDividerLookahead_V2();
34184
35094
  peg$silentFails--;
34185
35095
  if (s3 !== peg$FAILED) {
34186
35096
  peg$currPos = s2;
@@ -34245,39 +35155,147 @@ function peg$parse2(input, options) {
34245
35155
  return s0;
34246
35156
  }
34247
35157
  function peg$parseCardLineOrDivider_V2() {
34248
- let s0, s1, s2, s3;
35158
+ let s0, s1;
35159
+ s0 = peg$currPos;
35160
+ s1 = peg$parseCardDividerToken_V2();
35161
+ if (s1 === peg$FAILED) {
35162
+ s1 = peg$parseCardSideDividerToken_V2();
35163
+ if (s1 === peg$FAILED) {
35164
+ s1 = peg$parseCardVariantDividerToken_V2();
35165
+ if (s1 === peg$FAILED) {
35166
+ s1 = peg$parseCardLine_V2();
35167
+ }
35168
+ }
35169
+ }
35170
+ if (s1 !== peg$FAILED) {
35171
+ peg$savedPos = s0;
35172
+ s1 = peg$f23(s1);
35173
+ }
35174
+ s0 = s1;
35175
+ return s0;
35176
+ }
35177
+ function peg$parseCardDividerToken_V2() {
35178
+ let s0, s1, s2, s3, s4, s5, s6;
34249
35179
  s0 = peg$currPos;
34250
- s1 = peg$currPos;
34251
35180
  if (input.substr(peg$currPos, 4) === peg$c6) {
34252
- s2 = peg$c6;
35181
+ s1 = peg$c6;
34253
35182
  peg$currPos += 4;
34254
35183
  } else {
34255
- s2 = peg$FAILED;
35184
+ s1 = peg$FAILED;
34256
35185
  if (peg$silentFails === 0) {
34257
35186
  peg$fail(peg$e8);
34258
35187
  }
34259
35188
  }
34260
- if (s2 !== peg$FAILED) {
34261
- s3 = peg$parseWNL();
34262
- if (s3 === peg$FAILED) {
34263
- s3 = peg$parseWEOL();
35189
+ if (s1 !== peg$FAILED) {
35190
+ if (input.charCodeAt(peg$currPos) === 32) {
35191
+ s2 = peg$c10;
35192
+ peg$currPos++;
35193
+ } else {
35194
+ s2 = peg$FAILED;
35195
+ if (peg$silentFails === 0) {
35196
+ peg$fail(peg$e12);
35197
+ }
34264
35198
  }
34265
- if (s3 !== peg$FAILED) {
34266
- s2 = [s2, s3];
34267
- s1 = s2;
35199
+ if (s2 !== peg$FAILED) {
35200
+ s3 = peg$parseQualifier();
35201
+ if (s3 !== peg$FAILED) {
35202
+ if (input.charCodeAt(peg$currPos) === 32) {
35203
+ s4 = peg$c10;
35204
+ peg$currPos++;
35205
+ } else {
35206
+ s4 = peg$FAILED;
35207
+ if (peg$silentFails === 0) {
35208
+ peg$fail(peg$e12);
35209
+ }
35210
+ }
35211
+ if (s4 !== peg$FAILED) {
35212
+ if (input.substr(peg$currPos, 4) === peg$c6) {
35213
+ s5 = peg$c6;
35214
+ peg$currPos += 4;
35215
+ } else {
35216
+ s5 = peg$FAILED;
35217
+ if (peg$silentFails === 0) {
35218
+ peg$fail(peg$e8);
35219
+ }
35220
+ }
35221
+ if (s5 !== peg$FAILED) {
35222
+ s6 = peg$parseWNL();
35223
+ if (s6 === peg$FAILED) {
35224
+ s6 = peg$parseWEOL();
35225
+ }
35226
+ if (s6 !== peg$FAILED) {
35227
+ peg$savedPos = s0;
35228
+ s0 = peg$f24(s3);
35229
+ } else {
35230
+ peg$currPos = s0;
35231
+ s0 = peg$FAILED;
35232
+ }
35233
+ } else {
35234
+ peg$currPos = s0;
35235
+ s0 = peg$FAILED;
35236
+ }
35237
+ } else {
35238
+ peg$currPos = s0;
35239
+ s0 = peg$FAILED;
35240
+ }
35241
+ } else {
35242
+ peg$currPos = s0;
35243
+ s0 = peg$FAILED;
35244
+ }
35245
+ } else {
35246
+ peg$currPos = s0;
35247
+ s0 = peg$FAILED;
35248
+ }
35249
+ } else {
35250
+ peg$currPos = s0;
35251
+ s0 = peg$FAILED;
35252
+ }
35253
+ if (s0 === peg$FAILED) {
35254
+ s0 = peg$currPos;
35255
+ if (input.substr(peg$currPos, 4) === peg$c6) {
35256
+ s1 = peg$c6;
35257
+ peg$currPos += 4;
34268
35258
  } else {
34269
- peg$currPos = s1;
34270
35259
  s1 = peg$FAILED;
35260
+ if (peg$silentFails === 0) {
35261
+ peg$fail(peg$e8);
35262
+ }
34271
35263
  }
35264
+ if (s1 !== peg$FAILED) {
35265
+ s2 = peg$parseWNL();
35266
+ if (s2 === peg$FAILED) {
35267
+ s2 = peg$parseWEOL();
35268
+ }
35269
+ if (s2 !== peg$FAILED) {
35270
+ peg$savedPos = s0;
35271
+ s0 = peg$f25();
35272
+ } else {
35273
+ peg$currPos = s0;
35274
+ s0 = peg$FAILED;
35275
+ }
35276
+ } else {
35277
+ peg$currPos = s0;
35278
+ s0 = peg$FAILED;
35279
+ }
35280
+ }
35281
+ return s0;
35282
+ }
35283
+ function peg$parseCardSideDividerToken_V2() {
35284
+ let s0, s1, s2, s3, s4, s5, s6;
35285
+ s0 = peg$currPos;
35286
+ if (input.substr(peg$currPos, 2) === peg$c11) {
35287
+ s1 = peg$c11;
35288
+ peg$currPos += 2;
34272
35289
  } else {
34273
- peg$currPos = s1;
34274
35290
  s1 = peg$FAILED;
35291
+ if (peg$silentFails === 0) {
35292
+ peg$fail(peg$e13);
35293
+ }
34275
35294
  }
34276
- if (s1 === peg$FAILED) {
34277
- s1 = peg$currPos;
34278
- if (input.substr(peg$currPos, 2) === peg$c10) {
35295
+ if (s1 !== peg$FAILED) {
35296
+ if (input.charCodeAt(peg$currPos) === 32) {
34279
35297
  s2 = peg$c10;
34280
- peg$currPos += 2;
35298
+ peg$currPos++;
34281
35299
  } else {
34282
35300
  s2 = peg$FAILED;
34283
35301
  if (peg$silentFails === 0) {
@@ -34285,58 +35303,277 @@ function peg$parse2(input, options) {
34285
35303
  }
34286
35304
  }
34287
35305
  if (s2 !== peg$FAILED) {
34288
- s3 = peg$parseWNL();
34289
- if (s3 === peg$FAILED) {
34290
- s3 = peg$parseWEOL();
34291
- }
35306
+ s3 = peg$parseQualifier();
34292
35307
  if (s3 !== peg$FAILED) {
34293
- s2 = [s2, s3];
34294
- s1 = s2;
35308
+ if (input.charCodeAt(peg$currPos) === 32) {
35309
+ s4 = peg$c10;
35310
+ peg$currPos++;
35311
+ } else {
35312
+ s4 = peg$FAILED;
35313
+ if (peg$silentFails === 0) {
35314
+ peg$fail(peg$e12);
35315
+ }
35316
+ }
35317
+ if (s4 !== peg$FAILED) {
35318
+ if (input.substr(peg$currPos, 2) === peg$c11) {
35319
+ s5 = peg$c11;
35320
+ peg$currPos += 2;
35321
+ } else {
35322
+ s5 = peg$FAILED;
35323
+ if (peg$silentFails === 0) {
35324
+ peg$fail(peg$e13);
35325
+ }
35326
+ }
35327
+ if (s5 !== peg$FAILED) {
35328
+ s6 = peg$parseWNL();
35329
+ if (s6 === peg$FAILED) {
35330
+ s6 = peg$parseWEOL();
35331
+ }
35332
+ if (s6 !== peg$FAILED) {
35333
+ peg$savedPos = s0;
35334
+ s0 = peg$f26(s3);
35335
+ } else {
35336
+ peg$currPos = s0;
35337
+ s0 = peg$FAILED;
35338
+ }
35339
+ } else {
35340
+ peg$currPos = s0;
35341
+ s0 = peg$FAILED;
35342
+ }
35343
+ } else {
35344
+ peg$currPos = s0;
35345
+ s0 = peg$FAILED;
35346
+ }
34295
35347
  } else {
34296
- peg$currPos = s1;
34297
- s1 = peg$FAILED;
35348
+ peg$currPos = s0;
35349
+ s0 = peg$FAILED;
34298
35350
  }
34299
35351
  } else {
34300
- peg$currPos = s1;
35352
+ peg$currPos = s0;
35353
+ s0 = peg$FAILED;
35354
+ }
35355
+ } else {
35356
+ peg$currPos = s0;
35357
+ s0 = peg$FAILED;
35358
+ }
35359
+ if (s0 === peg$FAILED) {
35360
+ s0 = peg$currPos;
35361
+ if (input.substr(peg$currPos, 2) === peg$c11) {
35362
+ s1 = peg$c11;
35363
+ peg$currPos += 2;
35364
+ } else {
34301
35365
  s1 = peg$FAILED;
35366
+ if (peg$silentFails === 0) {
35367
+ peg$fail(peg$e13);
35368
+ }
34302
35369
  }
34303
- if (s1 === peg$FAILED) {
34304
- s1 = peg$currPos;
34305
- if (input.substr(peg$currPos, 2) === peg$c11) {
34306
- s2 = peg$c11;
34307
- peg$currPos += 2;
34308
- } else {
34309
- s2 = peg$FAILED;
34310
- if (peg$silentFails === 0) {
34311
- peg$fail(peg$e13);
34312
- }
35370
+ if (s1 !== peg$FAILED) {
35371
+ s2 = peg$parseWNL();
35372
+ if (s2 === peg$FAILED) {
35373
+ s2 = peg$parseWEOL();
34313
35374
  }
34314
35375
  if (s2 !== peg$FAILED) {
34315
- s3 = peg$parseWNL();
34316
- if (s3 === peg$FAILED) {
34317
- s3 = peg$parseWEOL();
35376
+ peg$savedPos = s0;
35377
+ s0 = peg$f27();
35378
+ } else {
35379
+ peg$currPos = s0;
35380
+ s0 = peg$FAILED;
35381
+ }
35382
+ } else {
35383
+ peg$currPos = s0;
35384
+ s0 = peg$FAILED;
35385
+ }
35386
+ }
35387
+ return s0;
35388
+ }
35389
+ function peg$parseCardVariantDividerToken_V2() {
35390
+ let s0, s1, s2, s3, s4, s5, s6;
35391
+ s0 = peg$currPos;
35392
+ if (input.substr(peg$currPos, 2) === peg$c12) {
35393
+ s1 = peg$c12;
35394
+ peg$currPos += 2;
35395
+ } else {
35396
+ s1 = peg$FAILED;
35397
+ if (peg$silentFails === 0) {
35398
+ peg$fail(peg$e14);
35399
+ }
35400
+ }
35401
+ if (s1 !== peg$FAILED) {
35402
+ if (input.charCodeAt(peg$currPos) === 32) {
35403
+ s2 = peg$c10;
35404
+ peg$currPos++;
35405
+ } else {
35406
+ s2 = peg$FAILED;
35407
+ if (peg$silentFails === 0) {
35408
+ peg$fail(peg$e12);
35409
+ }
35410
+ }
35411
+ if (s2 !== peg$FAILED) {
35412
+ s3 = peg$parseQualifier();
35413
+ if (s3 !== peg$FAILED) {
35414
+ if (input.charCodeAt(peg$currPos) === 32) {
35415
+ s4 = peg$c10;
35416
+ peg$currPos++;
35417
+ } else {
35418
+ s4 = peg$FAILED;
35419
+ if (peg$silentFails === 0) {
35420
+ peg$fail(peg$e12);
35421
+ }
34318
35422
  }
34319
- if (s3 !== peg$FAILED) {
34320
- s2 = [s2, s3];
34321
- s1 = s2;
35423
+ if (s4 !== peg$FAILED) {
35424
+ if (input.substr(peg$currPos, 2) === peg$c12) {
35425
+ s5 = peg$c12;
35426
+ peg$currPos += 2;
35427
+ } else {
35428
+ s5 = peg$FAILED;
35429
+ if (peg$silentFails === 0) {
35430
+ peg$fail(peg$e14);
35431
+ }
35432
+ }
35433
+ if (s5 !== peg$FAILED) {
35434
+ s6 = peg$parseWNL();
35435
+ if (s6 === peg$FAILED) {
35436
+ s6 = peg$parseWEOL();
35437
+ }
35438
+ if (s6 !== peg$FAILED) {
35439
+ peg$savedPos = s0;
35440
+ s0 = peg$f28(s3);
35441
+ } else {
35442
+ peg$currPos = s0;
35443
+ s0 = peg$FAILED;
35444
+ }
35445
+ } else {
35446
+ peg$currPos = s0;
35447
+ s0 = peg$FAILED;
35448
+ }
34322
35449
  } else {
34323
- peg$currPos = s1;
34324
- s1 = peg$FAILED;
35450
+ peg$currPos = s0;
35451
+ s0 = peg$FAILED;
34325
35452
  }
34326
35453
  } else {
34327
- peg$currPos = s1;
34328
- s1 = peg$FAILED;
35454
+ peg$currPos = s0;
35455
+ s0 = peg$FAILED;
34329
35456
  }
34330
- if (s1 === peg$FAILED) {
34331
- s1 = peg$parseCardLine_V2();
35457
+ } else {
35458
+ peg$currPos = s0;
35459
+ s0 = peg$FAILED;
35460
+ }
35461
+ } else {
35462
+ peg$currPos = s0;
35463
+ s0 = peg$FAILED;
35464
+ }
35465
+ if (s0 === peg$FAILED) {
35466
+ s0 = peg$currPos;
35467
+ if (input.substr(peg$currPos, 2) === peg$c12) {
35468
+ s1 = peg$c12;
35469
+ peg$currPos += 2;
35470
+ } else {
35471
+ s1 = peg$FAILED;
35472
+ if (peg$silentFails === 0) {
35473
+ peg$fail(peg$e14);
34332
35474
  }
34333
35475
  }
35476
+ if (s1 !== peg$FAILED) {
35477
+ s2 = peg$parseWNL();
35478
+ if (s2 === peg$FAILED) {
35479
+ s2 = peg$parseWEOL();
35480
+ }
35481
+ if (s2 !== peg$FAILED) {
35482
+ peg$savedPos = s0;
35483
+ s0 = peg$f29();
35484
+ } else {
35485
+ peg$currPos = s0;
35486
+ s0 = peg$FAILED;
35487
+ }
35488
+ } else {
35489
+ peg$currPos = s0;
35490
+ s0 = peg$FAILED;
35491
+ }
35492
+ }
35493
+ return s0;
35494
+ }
35495
+ function peg$parseCardDividerLookahead_V2() {
35496
+ let s0, s1, s2, s3, s4, s5, s6;
35497
+ s0 = peg$currPos;
35498
+ if (input.substr(peg$currPos, 4) === peg$c6) {
35499
+ s1 = peg$c6;
35500
+ peg$currPos += 4;
35501
+ } else {
35502
+ s1 = peg$FAILED;
35503
+ if (peg$silentFails === 0) {
35504
+ peg$fail(peg$e8);
35505
+ }
34334
35506
  }
34335
35507
  if (s1 !== peg$FAILED) {
34336
- peg$savedPos = s0;
34337
- s1 = peg$f23(s1);
35508
+ s2 = peg$currPos;
35509
+ if (input.charCodeAt(peg$currPos) === 32) {
35510
+ s3 = peg$c10;
35511
+ peg$currPos++;
35512
+ } else {
35513
+ s3 = peg$FAILED;
35514
+ if (peg$silentFails === 0) {
35515
+ peg$fail(peg$e12);
35516
+ }
35517
+ }
35518
+ if (s3 !== peg$FAILED) {
35519
+ s4 = peg$parseQualifier();
35520
+ if (s4 !== peg$FAILED) {
35521
+ if (input.charCodeAt(peg$currPos) === 32) {
35522
+ s5 = peg$c10;
35523
+ peg$currPos++;
35524
+ } else {
35525
+ s5 = peg$FAILED;
35526
+ if (peg$silentFails === 0) {
35527
+ peg$fail(peg$e12);
35528
+ }
35529
+ }
35530
+ if (s5 !== peg$FAILED) {
35531
+ if (input.substr(peg$currPos, 4) === peg$c6) {
35532
+ s6 = peg$c6;
35533
+ peg$currPos += 4;
35534
+ } else {
35535
+ s6 = peg$FAILED;
35536
+ if (peg$silentFails === 0) {
35537
+ peg$fail(peg$e8);
35538
+ }
35539
+ }
35540
+ if (s6 !== peg$FAILED) {
35541
+ s3 = [s3, s4, s5, s6];
35542
+ s2 = s3;
35543
+ } else {
35544
+ peg$currPos = s2;
35545
+ s2 = peg$FAILED;
35546
+ }
35547
+ } else {
35548
+ peg$currPos = s2;
35549
+ s2 = peg$FAILED;
35550
+ }
35551
+ } else {
35552
+ peg$currPos = s2;
35553
+ s2 = peg$FAILED;
35554
+ }
35555
+ } else {
35556
+ peg$currPos = s2;
35557
+ s2 = peg$FAILED;
35558
+ }
35559
+ if (s2 === peg$FAILED) {
35560
+ s2 = null;
35561
+ }
35562
+ s3 = peg$parseWNL();
35563
+ if (s3 === peg$FAILED) {
35564
+ s3 = peg$parseWEOL();
35565
+ }
35566
+ if (s3 !== peg$FAILED) {
35567
+ s1 = [s1, s2, s3];
35568
+ s0 = s1;
35569
+ } else {
35570
+ peg$currPos = s0;
35571
+ s0 = peg$FAILED;
35572
+ }
35573
+ } else {
35574
+ peg$currPos = s0;
35575
+ s0 = peg$FAILED;
34338
35576
  }
34339
- s0 = s1;
34340
35577
  return s0;
34341
35578
  }
34342
35579
  function peg$parseCardLine_V2() {
@@ -34411,7 +35648,7 @@ function peg$parse2(input, options) {
34411
35648
  }
34412
35649
  if (s2 !== peg$FAILED) {
34413
35650
  peg$savedPos = s0;
34414
- s0 = peg$f24(s2);
35651
+ s0 = peg$f30(s2);
34415
35652
  } else {
34416
35653
  peg$currPos = s0;
34417
35654
  s0 = peg$FAILED;
@@ -34448,7 +35685,7 @@ function peg$parse2(input, options) {
34448
35685
  }
34449
35686
  if (s1 !== peg$FAILED) {
34450
35687
  peg$savedPos = s0;
34451
- s1 = peg$f25(s1);
35688
+ s1 = peg$f31(s1);
34452
35689
  }
34453
35690
  s0 = s1;
34454
35691
  return s0;
@@ -34456,18 +35693,33 @@ function peg$parse2(input, options) {
34456
35693
  function peg$parseCardSetStart_V1() {
34457
35694
  let s0, s1, s2, s3, s4, s5;
34458
35695
  s0 = peg$currPos;
34459
- s1 = peg$parseNL();
35696
+ s1 = [];
35697
+ s2 = peg$parseWNL();
35698
+ if (s2 === peg$FAILED) {
35699
+ s2 = peg$parseNL();
35700
+ }
35701
+ if (s2 !== peg$FAILED) {
35702
+ while (s2 !== peg$FAILED) {
35703
+ s1.push(s2);
35704
+ s2 = peg$parseWNL();
35705
+ if (s2 === peg$FAILED) {
35706
+ s2 = peg$parseNL();
35707
+ }
35708
+ }
35709
+ } else {
35710
+ s1 = peg$FAILED;
35711
+ }
34460
35712
  if (s1 !== peg$FAILED) {
34461
35713
  s2 = peg$currPos;
34462
35714
  peg$silentFails++;
34463
35715
  s3 = peg$currPos;
34464
- if (input.substr(peg$currPos, 3) === peg$c12) {
34465
- s4 = peg$c12;
35716
+ if (input.substr(peg$currPos, 3) === peg$c13) {
35717
+ s4 = peg$c13;
34466
35718
  peg$currPos += 3;
34467
35719
  } else {
34468
35720
  s4 = peg$FAILED;
34469
35721
  if (peg$silentFails === 0) {
34470
- peg$fail(peg$e14);
35722
+ peg$fail(peg$e15);
34471
35723
  }
34472
35724
  }
34473
35725
  if (s4 !== peg$FAILED) {
@@ -34492,7 +35744,7 @@ function peg$parse2(input, options) {
34492
35744
  }
34493
35745
  if (s2 !== peg$FAILED) {
34494
35746
  peg$savedPos = s0;
34495
- s0 = peg$f26();
35747
+ s0 = peg$f32();
34496
35748
  } else {
34497
35749
  peg$currPos = s0;
34498
35750
  s0 = peg$FAILED;
@@ -34530,7 +35782,7 @@ function peg$parse2(input, options) {
34530
35782
  }
34531
35783
  if (s1 !== peg$FAILED) {
34532
35784
  peg$savedPos = s0;
34533
- s1 = peg$f27();
35785
+ s1 = peg$f33();
34534
35786
  }
34535
35787
  s0 = s1;
34536
35788
  return s0;
@@ -34541,7 +35793,7 @@ function peg$parse2(input, options) {
34541
35793
  s1 = peg$parseCardLineOrDivider_V1();
34542
35794
  if (s1 !== peg$FAILED) {
34543
35795
  peg$savedPos = s0;
34544
- s1 = peg$f28(s1);
35796
+ s1 = peg$f34(s1);
34545
35797
  }
34546
35798
  s0 = s1;
34547
35799
  return s0;
@@ -34550,13 +35802,13 @@ function peg$parse2(input, options) {
34550
35802
  let s0, s1, s2, s3;
34551
35803
  s0 = peg$currPos;
34552
35804
  s1 = peg$currPos;
34553
- if (input.substr(peg$currPos, 3) === peg$c12) {
34554
- s2 = peg$c12;
35805
+ if (input.substr(peg$currPos, 3) === peg$c13) {
35806
+ s2 = peg$c13;
34555
35807
  peg$currPos += 3;
34556
35808
  } else {
34557
35809
  s2 = peg$FAILED;
34558
35810
  if (peg$silentFails === 0) {
34559
- peg$fail(peg$e14);
35811
+ peg$fail(peg$e15);
34560
35812
  }
34561
35813
  }
34562
35814
  if (s2 !== peg$FAILED) {
@@ -34577,13 +35829,13 @@ function peg$parse2(input, options) {
34577
35829
  }
34578
35830
  if (s1 === peg$FAILED) {
34579
35831
  s1 = peg$currPos;
34580
- if (input.substr(peg$currPos, 2) === peg$c13) {
34581
- s2 = peg$c13;
35832
+ if (input.substr(peg$currPos, 2) === peg$c14) {
35833
+ s2 = peg$c14;
34582
35834
  peg$currPos += 2;
34583
35835
  } else {
34584
35836
  s2 = peg$FAILED;
34585
35837
  if (peg$silentFails === 0) {
34586
- peg$fail(peg$e15);
35838
+ peg$fail(peg$e16);
34587
35839
  }
34588
35840
  }
34589
35841
  if (s2 !== peg$FAILED) {
@@ -34604,13 +35856,13 @@ function peg$parse2(input, options) {
34604
35856
  }
34605
35857
  if (s1 === peg$FAILED) {
34606
35858
  s1 = peg$currPos;
34607
- if (input.substr(peg$currPos, 2) === peg$c10) {
34608
- s2 = peg$c10;
35859
+ if (input.substr(peg$currPos, 2) === peg$c11) {
35860
+ s2 = peg$c11;
34609
35861
  peg$currPos += 2;
34610
35862
  } else {
34611
35863
  s2 = peg$FAILED;
34612
35864
  if (peg$silentFails === 0) {
34613
- peg$fail(peg$e12);
35865
+ peg$fail(peg$e13);
34614
35866
  }
34615
35867
  }
34616
35868
  if (s2 !== peg$FAILED) {
@@ -34636,7 +35888,7 @@ function peg$parse2(input, options) {
34636
35888
  }
34637
35889
  if (s1 !== peg$FAILED) {
34638
35890
  peg$savedPos = s0;
34639
- s1 = peg$f29(s1);
35891
+ s1 = peg$f35(s1);
34640
35892
  }
34641
35893
  s0 = s1;
34642
35894
  return s0;
@@ -34713,7 +35965,7 @@ function peg$parse2(input, options) {
34713
35965
  }
34714
35966
  if (s2 !== peg$FAILED) {
34715
35967
  peg$savedPos = s0;
34716
- s0 = peg$f30(s2);
35968
+ s0 = peg$f36(s2);
34717
35969
  } else {
34718
35970
  peg$currPos = s0;
34719
35971
  s0 = peg$FAILED;
@@ -34724,6 +35976,102 @@ function peg$parse2(input, options) {
34724
35976
  }
34725
35977
  return s0;
34726
35978
  }
35979
+ function peg$parseQualifier() {
35980
+ let s0, s1, s2;
35981
+ s0 = peg$currPos;
35982
+ s1 = peg$currPos;
35983
+ peg$silentFails++;
35984
+ if (input.substr(peg$currPos, 6) === peg$c9) {
35985
+ s2 = peg$c9;
35986
+ peg$currPos += 6;
35987
+ } else {
35988
+ s2 = peg$FAILED;
35989
+ if (peg$silentFails === 0) {
35990
+ peg$fail(peg$e11);
35991
+ }
35992
+ }
35993
+ if (s2 === peg$FAILED) {
35994
+ if (input.substr(peg$currPos, 4) === peg$c7) {
35995
+ s2 = peg$c7;
35996
+ peg$currPos += 4;
35997
+ } else {
35998
+ s2 = peg$FAILED;
35999
+ if (peg$silentFails === 0) {
36000
+ peg$fail(peg$e9);
36001
+ }
36002
+ }
36003
+ }
36004
+ peg$silentFails--;
36005
+ if (s2 === peg$FAILED) {
36006
+ s1 = void 0;
36007
+ } else {
36008
+ peg$currPos = s1;
36009
+ s1 = peg$FAILED;
36010
+ }
36011
+ if (s1 !== peg$FAILED) {
36012
+ s2 = peg$parseQualifierName();
36013
+ if (s2 !== peg$FAILED) {
36014
+ peg$savedPos = s0;
36015
+ s0 = peg$f37(s2);
36016
+ } else {
36017
+ peg$currPos = s0;
36018
+ s0 = peg$FAILED;
36019
+ }
36020
+ } else {
36021
+ peg$currPos = s0;
36022
+ s0 = peg$FAILED;
36023
+ }
36024
+ return s0;
36025
+ }
36026
+ function peg$parseQualifierName() {
36027
+ let s0, s1, s2, s3, s4;
36028
+ s0 = peg$currPos;
36029
+ s1 = peg$currPos;
36030
+ s2 = input.charAt(peg$currPos);
36031
+ if (peg$r1.test(s2)) {
36032
+ peg$currPos++;
36033
+ } else {
36034
+ s2 = peg$FAILED;
36035
+ if (peg$silentFails === 0) {
36036
+ peg$fail(peg$e17);
36037
+ }
36038
+ }
36039
+ if (s2 !== peg$FAILED) {
36040
+ s3 = [];
36041
+ s4 = input.charAt(peg$currPos);
36042
+ if (peg$r2.test(s4)) {
36043
+ peg$currPos++;
36044
+ } else {
36045
+ s4 = peg$FAILED;
36046
+ if (peg$silentFails === 0) {
36047
+ peg$fail(peg$e18);
36048
+ }
36049
+ }
36050
+ while (s4 !== peg$FAILED) {
36051
+ s3.push(s4);
36052
+ s4 = input.charAt(peg$currPos);
36053
+ if (peg$r2.test(s4)) {
36054
+ peg$currPos++;
36055
+ } else {
36056
+ s4 = peg$FAILED;
36057
+ if (peg$silentFails === 0) {
36058
+ peg$fail(peg$e18);
36059
+ }
36060
+ }
36061
+ }
36062
+ s2 = [s2, s3];
36063
+ s1 = s2;
36064
+ } else {
36065
+ peg$currPos = s1;
36066
+ s1 = peg$FAILED;
36067
+ }
36068
+ if (s1 !== peg$FAILED) {
36069
+ s0 = input.substring(s0, peg$currPos);
36070
+ } else {
36071
+ s0 = s1;
36072
+ }
36073
+ return s0;
36074
+ }
34727
36075
  function peg$parsecardContent() {
34728
36076
  let s0, s1, s2;
34729
36077
  s0 = peg$currPos;
@@ -34740,7 +36088,7 @@ function peg$parse2(input, options) {
34740
36088
  }
34741
36089
  }
34742
36090
  peg$savedPos = s0;
34743
- s1 = peg$f31(s1);
36091
+ s1 = peg$f38(s1);
34744
36092
  s0 = s1;
34745
36093
  return s0;
34746
36094
  }
@@ -34758,7 +36106,7 @@ function peg$parse2(input, options) {
34758
36106
  }
34759
36107
  if (s1 !== peg$FAILED) {
34760
36108
  peg$savedPos = s0;
34761
- s1 = peg$f32(s1);
36109
+ s1 = peg$f39(s1);
34762
36110
  }
34763
36111
  s0 = s1;
34764
36112
  return s0;
@@ -34766,13 +36114,13 @@ function peg$parse2(input, options) {
34766
36114
  function peg$parseIDTag() {
34767
36115
  let s0, s1, s2, s3;
34768
36116
  s0 = peg$currPos;
34769
- if (input.substr(peg$currPos, 4) === peg$c14) {
34770
- s1 = peg$c14;
36117
+ if (input.substr(peg$currPos, 4) === peg$c15) {
36118
+ s1 = peg$c15;
34771
36119
  peg$currPos += 4;
34772
36120
  } else {
34773
36121
  s1 = peg$FAILED;
34774
36122
  if (peg$silentFails === 0) {
34775
- peg$fail(peg$e16);
36123
+ peg$fail(peg$e19);
34776
36124
  }
34777
36125
  }
34778
36126
  if (s1 !== peg$FAILED) {
@@ -34781,7 +36129,7 @@ function peg$parse2(input, options) {
34781
36129
  s3 = peg$parseTag_Close();
34782
36130
  if (s3 !== peg$FAILED) {
34783
36131
  peg$savedPos = s0;
34784
- s0 = peg$f33(s2);
36132
+ s0 = peg$f40(s2);
34785
36133
  } else {
34786
36134
  peg$currPos = s0;
34787
36135
  s0 = peg$FAILED;
@@ -34811,24 +36159,24 @@ function peg$parse2(input, options) {
34811
36159
  if (s1 !== peg$FAILED) {
34812
36160
  s2 = [];
34813
36161
  if (input.charCodeAt(peg$currPos) === 35) {
34814
- s3 = peg$c15;
36162
+ s3 = peg$c16;
34815
36163
  peg$currPos++;
34816
36164
  } else {
34817
36165
  s3 = peg$FAILED;
34818
36166
  if (peg$silentFails === 0) {
34819
- peg$fail(peg$e17);
36167
+ peg$fail(peg$e20);
34820
36168
  }
34821
36169
  }
34822
36170
  if (s3 !== peg$FAILED) {
34823
36171
  while (s3 !== peg$FAILED) {
34824
36172
  s2.push(s3);
34825
36173
  if (input.charCodeAt(peg$currPos) === 35) {
34826
- s3 = peg$c15;
36174
+ s3 = peg$c16;
34827
36175
  peg$currPos++;
34828
36176
  } else {
34829
36177
  s3 = peg$FAILED;
34830
36178
  if (peg$silentFails === 0) {
34831
- peg$fail(peg$e17);
36179
+ peg$fail(peg$e20);
34832
36180
  }
34833
36181
  }
34834
36182
  }
@@ -34840,7 +36188,7 @@ function peg$parse2(input, options) {
34840
36188
  s4 = peg$parseTag_CloseOrEOF();
34841
36189
  if (s4 !== peg$FAILED) {
34842
36190
  peg$savedPos = s0;
34843
- s0 = peg$f34(s2, s3);
36191
+ s0 = peg$f41(s2, s3);
34844
36192
  } else {
34845
36193
  peg$currPos = s0;
34846
36194
  s0 = peg$FAILED;
@@ -34858,13 +36206,13 @@ function peg$parse2(input, options) {
34858
36206
  function peg$parseAnchorTag() {
34859
36207
  let s0, s1, s2, s3;
34860
36208
  s0 = peg$currPos;
34861
- if (input.substr(peg$currPos, 2) === peg$c16) {
34862
- s1 = peg$c16;
36209
+ if (input.substr(peg$currPos, 2) === peg$c17) {
36210
+ s1 = peg$c17;
34863
36211
  peg$currPos += 2;
34864
36212
  } else {
34865
36213
  s1 = peg$FAILED;
34866
36214
  if (peg$silentFails === 0) {
34867
- peg$fail(peg$e18);
36215
+ peg$fail(peg$e21);
34868
36216
  }
34869
36217
  }
34870
36218
  if (s1 !== peg$FAILED) {
@@ -34872,7 +36220,7 @@ function peg$parse2(input, options) {
34872
36220
  s3 = peg$parseTag_CloseOrEOF();
34873
36221
  if (s3 !== peg$FAILED) {
34874
36222
  peg$savedPos = s0;
34875
- s0 = peg$f35(s2);
36223
+ s0 = peg$f42(s2);
34876
36224
  } else {
34877
36225
  peg$currPos = s0;
34878
36226
  s0 = peg$FAILED;
@@ -34886,13 +36234,13 @@ function peg$parse2(input, options) {
34886
36234
  function peg$parseReferenceTag() {
34887
36235
  let s0, s1, s2, s3;
34888
36236
  s0 = peg$currPos;
34889
- if (input.substr(peg$currPos, 2) === peg$c17) {
34890
- s1 = peg$c17;
36237
+ if (input.substr(peg$currPos, 2) === peg$c18) {
36238
+ s1 = peg$c18;
34891
36239
  peg$currPos += 2;
34892
36240
  } else {
34893
36241
  s1 = peg$FAILED;
34894
36242
  if (peg$silentFails === 0) {
34895
- peg$fail(peg$e19);
36243
+ peg$fail(peg$e22);
34896
36244
  }
34897
36245
  }
34898
36246
  if (s1 !== peg$FAILED) {
@@ -34900,7 +36248,7 @@ function peg$parse2(input, options) {
34900
36248
  s3 = peg$parseTag_CloseOrEOF();
34901
36249
  if (s3 !== peg$FAILED) {
34902
36250
  peg$savedPos = s0;
34903
- s0 = peg$f36(s2);
36251
+ s0 = peg$f43(s2);
34904
36252
  } else {
34905
36253
  peg$currPos = s0;
34906
36254
  s0 = peg$FAILED;
@@ -34914,13 +36262,13 @@ function peg$parse2(input, options) {
34914
36262
  function peg$parsePropertyTag() {
34915
36263
  let s0, s1, s2, s3, s4;
34916
36264
  s0 = peg$currPos;
34917
- if (input.substr(peg$currPos, 2) === peg$c18) {
34918
- s1 = peg$c18;
36265
+ if (input.substr(peg$currPos, 2) === peg$c19) {
36266
+ s1 = peg$c19;
34919
36267
  peg$currPos += 2;
34920
36268
  } else {
34921
36269
  s1 = peg$FAILED;
34922
36270
  if (peg$silentFails === 0) {
34923
- peg$fail(peg$e20);
36271
+ peg$fail(peg$e23);
34924
36272
  }
34925
36273
  }
34926
36274
  if (s1 !== peg$FAILED) {
@@ -34931,7 +36279,7 @@ function peg$parse2(input, options) {
34931
36279
  s4 = peg$parseTag_CloseOrEOF();
34932
36280
  if (s4 !== peg$FAILED) {
34933
36281
  peg$savedPos = s0;
34934
- s0 = peg$f37(s2, s3);
36282
+ s0 = peg$f44(s2, s3);
34935
36283
  } else {
34936
36284
  peg$currPos = s0;
34937
36285
  s0 = peg$FAILED;
@@ -34953,13 +36301,13 @@ function peg$parse2(input, options) {
34953
36301
  function peg$parseItemLeadTag() {
34954
36302
  let s0, s1, s2, s3;
34955
36303
  s0 = peg$currPos;
34956
- if (input.substr(peg$currPos, 2) === peg$c19) {
34957
- s1 = peg$c19;
36304
+ if (input.substr(peg$currPos, 2) === peg$c20) {
36305
+ s1 = peg$c20;
34958
36306
  peg$currPos += 2;
34959
36307
  } else {
34960
36308
  s1 = peg$FAILED;
34961
36309
  if (peg$silentFails === 0) {
34962
- peg$fail(peg$e21);
36310
+ peg$fail(peg$e24);
34963
36311
  }
34964
36312
  }
34965
36313
  if (s1 !== peg$FAILED) {
@@ -34967,7 +36315,7 @@ function peg$parse2(input, options) {
34967
36315
  s3 = peg$parseTag_CloseOrEOF();
34968
36316
  if (s3 !== peg$FAILED) {
34969
36317
  peg$savedPos = s0;
34970
- s0 = peg$f38(s2);
36318
+ s0 = peg$f45(s2);
34971
36319
  } else {
34972
36320
  peg$currPos = s0;
34973
36321
  s0 = peg$FAILED;
@@ -34981,13 +36329,13 @@ function peg$parse2(input, options) {
34981
36329
  function peg$parseInstructionTag() {
34982
36330
  let s0, s1, s2, s3;
34983
36331
  s0 = peg$currPos;
34984
- if (input.substr(peg$currPos, 2) === peg$c20) {
34985
- s1 = peg$c20;
36332
+ if (input.substr(peg$currPos, 2) === peg$c21) {
36333
+ s1 = peg$c21;
34986
36334
  peg$currPos += 2;
34987
36335
  } else {
34988
36336
  s1 = peg$FAILED;
34989
36337
  if (peg$silentFails === 0) {
34990
- peg$fail(peg$e22);
36338
+ peg$fail(peg$e25);
34991
36339
  }
34992
36340
  }
34993
36341
  if (s1 !== peg$FAILED) {
@@ -34995,7 +36343,7 @@ function peg$parse2(input, options) {
34995
36343
  s3 = peg$parseTag_CloseOrEOF();
34996
36344
  if (s3 !== peg$FAILED) {
34997
36345
  peg$savedPos = s0;
34998
- s0 = peg$f39(s2);
36346
+ s0 = peg$f46(s2);
34999
36347
  } else {
35000
36348
  peg$currPos = s0;
35001
36349
  s0 = peg$FAILED;
@@ -35009,13 +36357,13 @@ function peg$parse2(input, options) {
35009
36357
  function peg$parseHintTag() {
35010
36358
  let s0, s1, s2, s3;
35011
36359
  s0 = peg$currPos;
35012
- if (input.substr(peg$currPos, 2) === peg$c21) {
35013
- s1 = peg$c21;
36360
+ if (input.substr(peg$currPos, 2) === peg$c22) {
36361
+ s1 = peg$c22;
35014
36362
  peg$currPos += 2;
35015
36363
  } else {
35016
36364
  s1 = peg$FAILED;
35017
36365
  if (peg$silentFails === 0) {
35018
- peg$fail(peg$e23);
36366
+ peg$fail(peg$e26);
35019
36367
  }
35020
36368
  }
35021
36369
  if (s1 !== peg$FAILED) {
@@ -35023,7 +36371,7 @@ function peg$parse2(input, options) {
35023
36371
  s3 = peg$parseTag_CloseOrEOF();
35024
36372
  if (s3 !== peg$FAILED) {
35025
36373
  peg$savedPos = s0;
35026
- s0 = peg$f40(s2);
36374
+ s0 = peg$f47(s2);
35027
36375
  } else {
35028
36376
  peg$currPos = s0;
35029
36377
  s0 = peg$FAILED;
@@ -35037,13 +36385,13 @@ function peg$parse2(input, options) {
35037
36385
  function peg$parseTrueTag() {
35038
36386
  let s0, s1, s2, s3;
35039
36387
  s0 = peg$currPos;
35040
- if (input.substr(peg$currPos, 2) === peg$c22) {
35041
- s1 = peg$c22;
36388
+ if (input.substr(peg$currPos, 2) === peg$c23) {
36389
+ s1 = peg$c23;
35042
36390
  peg$currPos += 2;
35043
36391
  } else {
35044
36392
  s1 = peg$FAILED;
35045
36393
  if (peg$silentFails === 0) {
35046
- peg$fail(peg$e24);
36394
+ peg$fail(peg$e27);
35047
36395
  }
35048
36396
  }
35049
36397
  if (s1 !== peg$FAILED) {
@@ -35051,7 +36399,7 @@ function peg$parse2(input, options) {
35051
36399
  s3 = peg$parseTag_CloseOrEOF();
35052
36400
  if (s3 !== peg$FAILED) {
35053
36401
  peg$savedPos = s0;
35054
- s0 = peg$f41(s2);
36402
+ s0 = peg$f48(s2);
35055
36403
  } else {
35056
36404
  peg$currPos = s0;
35057
36405
  s0 = peg$FAILED;
@@ -35065,13 +36413,13 @@ function peg$parse2(input, options) {
35065
36413
  function peg$parseFalseTag() {
35066
36414
  let s0, s1, s2, s3;
35067
36415
  s0 = peg$currPos;
35068
- if (input.substr(peg$currPos, 2) === peg$c23) {
35069
- s1 = peg$c23;
36416
+ if (input.substr(peg$currPos, 2) === peg$c24) {
36417
+ s1 = peg$c24;
35070
36418
  peg$currPos += 2;
35071
36419
  } else {
35072
36420
  s1 = peg$FAILED;
35073
36421
  if (peg$silentFails === 0) {
35074
- peg$fail(peg$e25);
36422
+ peg$fail(peg$e28);
35075
36423
  }
35076
36424
  }
35077
36425
  if (s1 !== peg$FAILED) {
@@ -35079,7 +36427,7 @@ function peg$parse2(input, options) {
35079
36427
  s3 = peg$parseTag_CloseOrEOF();
35080
36428
  if (s3 !== peg$FAILED) {
35081
36429
  peg$savedPos = s0;
35082
- s0 = peg$f42(s2);
36430
+ s0 = peg$f49(s2);
35083
36431
  } else {
35084
36432
  peg$currPos = s0;
35085
36433
  s0 = peg$FAILED;
@@ -35093,13 +36441,13 @@ function peg$parse2(input, options) {
35093
36441
  function peg$parseSampleSolutionTag() {
35094
36442
  let s0, s1, s2, s3;
35095
36443
  s0 = peg$currPos;
35096
- if (input.substr(peg$currPos, 2) === peg$c24) {
35097
- s1 = peg$c24;
36444
+ if (input.substr(peg$currPos, 2) === peg$c25) {
36445
+ s1 = peg$c25;
35098
36446
  peg$currPos += 2;
35099
36447
  } else {
35100
36448
  s1 = peg$FAILED;
35101
36449
  if (peg$silentFails === 0) {
35102
- peg$fail(peg$e26);
36450
+ peg$fail(peg$e29);
35103
36451
  }
35104
36452
  }
35105
36453
  if (s1 !== peg$FAILED) {
@@ -35107,7 +36455,7 @@ function peg$parse2(input, options) {
35107
36455
  s3 = peg$parseTag_CloseOrEOF();
35108
36456
  if (s3 !== peg$FAILED) {
35109
36457
  peg$savedPos = s0;
35110
- s0 = peg$f43(s2);
36458
+ s0 = peg$f50(s2);
35111
36459
  } else {
35112
36460
  peg$currPos = s0;
35113
36461
  s0 = peg$FAILED;
@@ -35121,13 +36469,13 @@ function peg$parse2(input, options) {
35121
36469
  function peg$parseGapTag() {
35122
36470
  let s0, s1, s2, s3;
35123
36471
  s0 = peg$currPos;
35124
- if (input.substr(peg$currPos, 2) === peg$c25) {
35125
- s1 = peg$c25;
36472
+ if (input.substr(peg$currPos, 2) === peg$c26) {
36473
+ s1 = peg$c26;
35126
36474
  peg$currPos += 2;
35127
36475
  } else {
35128
36476
  s1 = peg$FAILED;
35129
36477
  if (peg$silentFails === 0) {
35130
- peg$fail(peg$e27);
36478
+ peg$fail(peg$e30);
35131
36479
  }
35132
36480
  }
35133
36481
  if (s1 !== peg$FAILED) {
@@ -35135,7 +36483,7 @@ function peg$parse2(input, options) {
35135
36483
  s3 = peg$parseTag_CloseOrEOF();
35136
36484
  if (s3 !== peg$FAILED) {
35137
36485
  peg$savedPos = s0;
35138
- s0 = peg$f44(s2);
36486
+ s0 = peg$f51(s2);
35139
36487
  } else {
35140
36488
  peg$currPos = s0;
35141
36489
  s0 = peg$FAILED;
@@ -35149,13 +36497,13 @@ function peg$parse2(input, options) {
35149
36497
  function peg$parseMarkTag() {
35150
36498
  let s0, s1, s2, s3;
35151
36499
  s0 = peg$currPos;
35152
- if (input.substr(peg$currPos, 2) === peg$c26) {
35153
- s1 = peg$c26;
36500
+ if (input.substr(peg$currPos, 2) === peg$c27) {
36501
+ s1 = peg$c27;
35154
36502
  peg$currPos += 2;
35155
36503
  } else {
35156
36504
  s1 = peg$FAILED;
35157
36505
  if (peg$silentFails === 0) {
35158
- peg$fail(peg$e28);
36506
+ peg$fail(peg$e31);
35159
36507
  }
35160
36508
  }
35161
36509
  if (s1 !== peg$FAILED) {
@@ -35163,7 +36511,7 @@ function peg$parse2(input, options) {
35163
36511
  s3 = peg$parseTag_CloseOrEOF();
35164
36512
  if (s3 !== peg$FAILED) {
35165
36513
  peg$savedPos = s0;
35166
- s0 = peg$f45(s2);
36514
+ s0 = peg$f52(s2);
35167
36515
  } else {
35168
36516
  peg$currPos = s0;
35169
36517
  s0 = peg$FAILED;
@@ -35177,13 +36525,13 @@ function peg$parse2(input, options) {
35177
36525
  function peg$parseResourceTag() {
35178
36526
  let s0, s1, s2, s3, s4;
35179
36527
  s0 = peg$currPos;
35180
- if (input.substr(peg$currPos, 2) === peg$c27) {
35181
- s1 = peg$c27;
36528
+ if (input.substr(peg$currPos, 2) === peg$c28) {
36529
+ s1 = peg$c28;
35182
36530
  peg$currPos += 2;
35183
36531
  } else {
35184
36532
  s1 = peg$FAILED;
35185
36533
  if (peg$silentFails === 0) {
35186
- peg$fail(peg$e29);
36534
+ peg$fail(peg$e32);
35187
36535
  }
35188
36536
  }
35189
36537
  if (s1 !== peg$FAILED) {
@@ -35194,7 +36542,7 @@ function peg$parse2(input, options) {
35194
36542
  s4 = peg$parseTag_CloseOrEOF();
35195
36543
  if (s4 !== peg$FAILED) {
35196
36544
  peg$savedPos = s0;
35197
- s0 = peg$f46(s2, s3);
36545
+ s0 = peg$f53(s2, s3);
35198
36546
  } else {
35199
36547
  peg$currPos = s0;
35200
36548
  s0 = peg$FAILED;
@@ -35218,13 +36566,13 @@ function peg$parse2(input, options) {
35218
36566
  s0 = peg$currPos;
35219
36567
  s1 = peg$currPos;
35220
36568
  s2 = [];
35221
- if (input.substr(peg$currPos, 2) === peg$c28) {
35222
- s3 = peg$c28;
36569
+ if (input.substr(peg$currPos, 2) === peg$c29) {
36570
+ s3 = peg$c29;
35223
36571
  peg$currPos += 2;
35224
36572
  } else {
35225
36573
  s3 = peg$FAILED;
35226
36574
  if (peg$silentFails === 0) {
35227
- peg$fail(peg$e30);
36575
+ peg$fail(peg$e33);
35228
36576
  }
35229
36577
  }
35230
36578
  if (s3 === peg$FAILED) {
@@ -35240,13 +36588,13 @@ function peg$parse2(input, options) {
35240
36588
  }
35241
36589
  while (s3 !== peg$FAILED) {
35242
36590
  s2.push(s3);
35243
- if (input.substr(peg$currPos, 2) === peg$c28) {
35244
- s3 = peg$c28;
36591
+ if (input.substr(peg$currPos, 2) === peg$c29) {
36592
+ s3 = peg$c29;
35245
36593
  peg$currPos += 2;
35246
36594
  } else {
35247
36595
  s3 = peg$FAILED;
35248
36596
  if (peg$silentFails === 0) {
35249
- peg$fail(peg$e30);
36597
+ peg$fail(peg$e33);
35250
36598
  }
35251
36599
  }
35252
36600
  if (s3 === peg$FAILED) {
@@ -35263,7 +36611,7 @@ function peg$parse2(input, options) {
35263
36611
  }
35264
36612
  s1 = input.substring(s1, peg$currPos);
35265
36613
  peg$savedPos = s0;
35266
- s1 = peg$f47(s1);
36614
+ s1 = peg$f54(s1);
35267
36615
  s0 = s1;
35268
36616
  return s0;
35269
36617
  }
@@ -35272,13 +36620,13 @@ function peg$parse2(input, options) {
35272
36620
  s0 = peg$currPos;
35273
36621
  s1 = peg$currPos;
35274
36622
  peg$silentFails++;
35275
- if (input.substr(peg$currPos, 3) === peg$c29) {
35276
- s2 = peg$c29;
36623
+ if (input.substr(peg$currPos, 3) === peg$c30) {
36624
+ s2 = peg$c30;
35277
36625
  peg$currPos += 3;
35278
36626
  } else {
35279
36627
  s2 = peg$FAILED;
35280
36628
  if (peg$silentFails === 0) {
35281
- peg$fail(peg$e31);
36629
+ peg$fail(peg$e34);
35282
36630
  }
35283
36631
  }
35284
36632
  peg$silentFails--;
@@ -35292,29 +36640,29 @@ function peg$parse2(input, options) {
35292
36640
  s2 = peg$currPos;
35293
36641
  s3 = [];
35294
36642
  s4 = input.charAt(peg$currPos);
35295
- if (peg$r1.test(s4)) {
36643
+ if (peg$r3.test(s4)) {
35296
36644
  peg$currPos++;
35297
36645
  } else {
35298
36646
  s4 = peg$FAILED;
35299
36647
  if (peg$silentFails === 0) {
35300
- peg$fail(peg$e32);
36648
+ peg$fail(peg$e35);
35301
36649
  }
35302
36650
  }
35303
36651
  while (s4 !== peg$FAILED) {
35304
36652
  s3.push(s4);
35305
36653
  s4 = input.charAt(peg$currPos);
35306
- if (peg$r1.test(s4)) {
36654
+ if (peg$r3.test(s4)) {
35307
36655
  peg$currPos++;
35308
36656
  } else {
35309
36657
  s4 = peg$FAILED;
35310
36658
  if (peg$silentFails === 0) {
35311
- peg$fail(peg$e32);
36659
+ peg$fail(peg$e35);
35312
36660
  }
35313
36661
  }
35314
36662
  }
35315
36663
  s2 = input.substring(s2, peg$currPos);
35316
36664
  peg$savedPos = s0;
35317
- s0 = peg$f48(s2);
36665
+ s0 = peg$f55(s2);
35318
36666
  } else {
35319
36667
  peg$currPos = s0;
35320
36668
  s0 = peg$FAILED;
@@ -35369,24 +36717,24 @@ function peg$parse2(input, options) {
35369
36717
  s0 = peg$currPos;
35370
36718
  s1 = [];
35371
36719
  if (input.charCodeAt(peg$currPos) === 46) {
35372
- s2 = peg$c30;
36720
+ s2 = peg$c31;
35373
36721
  peg$currPos++;
35374
36722
  } else {
35375
36723
  s2 = peg$FAILED;
35376
36724
  if (peg$silentFails === 0) {
35377
- peg$fail(peg$e33);
36725
+ peg$fail(peg$e36);
35378
36726
  }
35379
36727
  }
35380
36728
  if (s2 !== peg$FAILED) {
35381
36729
  while (s2 !== peg$FAILED) {
35382
36730
  s1.push(s2);
35383
36731
  if (input.charCodeAt(peg$currPos) === 46) {
35384
- s2 = peg$c30;
36732
+ s2 = peg$c31;
35385
36733
  peg$currPos++;
35386
36734
  } else {
35387
36735
  s2 = peg$FAILED;
35388
36736
  if (peg$silentFails === 0) {
35389
- peg$fail(peg$e33);
36737
+ peg$fail(peg$e36);
35390
36738
  }
35391
36739
  }
35392
36740
  }
@@ -35395,7 +36743,7 @@ function peg$parse2(input, options) {
35395
36743
  }
35396
36744
  if (s1 !== peg$FAILED) {
35397
36745
  peg$savedPos = s0;
35398
- s1 = peg$f49(s1);
36746
+ s1 = peg$f56(s1);
35399
36747
  }
35400
36748
  s0 = s1;
35401
36749
  return s0;
@@ -35406,29 +36754,29 @@ function peg$parse2(input, options) {
35406
36754
  s1 = peg$currPos;
35407
36755
  s2 = [];
35408
36756
  s3 = input.charAt(peg$currPos);
35409
- if (peg$r2.test(s3)) {
36757
+ if (peg$r4.test(s3)) {
35410
36758
  peg$currPos++;
35411
36759
  } else {
35412
36760
  s3 = peg$FAILED;
35413
36761
  if (peg$silentFails === 0) {
35414
- peg$fail(peg$e34);
36762
+ peg$fail(peg$e37);
35415
36763
  }
35416
36764
  }
35417
36765
  while (s3 !== peg$FAILED) {
35418
36766
  s2.push(s3);
35419
36767
  s3 = input.charAt(peg$currPos);
35420
- if (peg$r2.test(s3)) {
36768
+ if (peg$r4.test(s3)) {
35421
36769
  peg$currPos++;
35422
36770
  } else {
35423
36771
  s3 = peg$FAILED;
35424
36772
  if (peg$silentFails === 0) {
35425
- peg$fail(peg$e34);
36773
+ peg$fail(peg$e37);
35426
36774
  }
35427
36775
  }
35428
36776
  }
35429
36777
  s1 = input.substring(s1, peg$currPos);
35430
36778
  peg$savedPos = s0;
35431
- s1 = peg$f50(s1);
36779
+ s1 = peg$f57(s1);
35432
36780
  s0 = s1;
35433
36781
  return s0;
35434
36782
  }
@@ -35447,7 +36795,7 @@ function peg$parse2(input, options) {
35447
36795
  if (s1 !== peg$FAILED) {
35448
36796
  s2 = peg$parseTag_Value();
35449
36797
  peg$savedPos = s0;
35450
- s0 = peg$f51(s2);
36798
+ s0 = peg$f58(s2);
35451
36799
  } else {
35452
36800
  peg$currPos = s0;
35453
36801
  s0 = peg$FAILED;
@@ -35456,7 +36804,7 @@ function peg$parse2(input, options) {
35456
36804
  s0 = peg$currPos;
35457
36805
  s1 = "";
35458
36806
  peg$savedPos = s0;
35459
- s1 = peg$f52();
36807
+ s1 = peg$f59();
35460
36808
  s0 = s1;
35461
36809
  }
35462
36810
  return s0;
@@ -35493,19 +36841,19 @@ function peg$parse2(input, options) {
35493
36841
  let s0, s1;
35494
36842
  peg$silentFails++;
35495
36843
  s0 = input.charAt(peg$currPos);
35496
- if (peg$r3.test(s0)) {
36844
+ if (peg$r5.test(s0)) {
35497
36845
  peg$currPos++;
35498
36846
  } else {
35499
36847
  s0 = peg$FAILED;
35500
36848
  if (peg$silentFails === 0) {
35501
- peg$fail(peg$e36);
36849
+ peg$fail(peg$e39);
35502
36850
  }
35503
36851
  }
35504
36852
  peg$silentFails--;
35505
36853
  if (s0 === peg$FAILED) {
35506
36854
  s1 = peg$FAILED;
35507
36855
  if (peg$silentFails === 0) {
35508
- peg$fail(peg$e35);
36856
+ peg$fail(peg$e38);
35509
36857
  }
35510
36858
  }
35511
36859
  return s0;
@@ -35528,23 +36876,23 @@ function peg$parse2(input, options) {
35528
36876
  s0 = peg$currPos;
35529
36877
  s1 = [];
35530
36878
  s2 = input.charAt(peg$currPos);
35531
- if (peg$r4.test(s2)) {
36879
+ if (peg$r6.test(s2)) {
35532
36880
  peg$currPos++;
35533
36881
  } else {
35534
36882
  s2 = peg$FAILED;
35535
36883
  if (peg$silentFails === 0) {
35536
- peg$fail(peg$e38);
36884
+ peg$fail(peg$e41);
35537
36885
  }
35538
36886
  }
35539
36887
  while (s2 !== peg$FAILED) {
35540
36888
  s1.push(s2);
35541
36889
  s2 = input.charAt(peg$currPos);
35542
- if (peg$r4.test(s2)) {
36890
+ if (peg$r6.test(s2)) {
35543
36891
  peg$currPos++;
35544
36892
  } else {
35545
36893
  s2 = peg$FAILED;
35546
36894
  if (peg$silentFails === 0) {
35547
- peg$fail(peg$e38);
36895
+ peg$fail(peg$e41);
35548
36896
  }
35549
36897
  }
35550
36898
  }
@@ -35560,7 +36908,7 @@ function peg$parse2(input, options) {
35560
36908
  if (s0 === peg$FAILED) {
35561
36909
  s1 = peg$FAILED;
35562
36910
  if (peg$silentFails === 0) {
35563
- peg$fail(peg$e37);
36911
+ peg$fail(peg$e40);
35564
36912
  }
35565
36913
  }
35566
36914
  return s0;
@@ -35569,32 +36917,32 @@ function peg$parse2(input, options) {
35569
36917
  let s0, s1;
35570
36918
  peg$silentFails++;
35571
36919
  if (input.charCodeAt(peg$currPos) === 10) {
35572
- s0 = peg$c31;
36920
+ s0 = peg$c32;
35573
36921
  peg$currPos++;
35574
36922
  } else {
35575
36923
  s0 = peg$FAILED;
35576
36924
  if (peg$silentFails === 0) {
35577
- peg$fail(peg$e40);
36925
+ peg$fail(peg$e43);
35578
36926
  }
35579
36927
  }
35580
36928
  if (s0 === peg$FAILED) {
35581
- if (input.substr(peg$currPos, 2) === peg$c32) {
35582
- s0 = peg$c32;
36929
+ if (input.substr(peg$currPos, 2) === peg$c33) {
36930
+ s0 = peg$c33;
35583
36931
  peg$currPos += 2;
35584
36932
  } else {
35585
36933
  s0 = peg$FAILED;
35586
36934
  if (peg$silentFails === 0) {
35587
- peg$fail(peg$e41);
36935
+ peg$fail(peg$e44);
35588
36936
  }
35589
36937
  }
35590
36938
  if (s0 === peg$FAILED) {
35591
36939
  s0 = input.charAt(peg$currPos);
35592
- if (peg$r5.test(s0)) {
36940
+ if (peg$r7.test(s0)) {
35593
36941
  peg$currPos++;
35594
36942
  } else {
35595
36943
  s0 = peg$FAILED;
35596
36944
  if (peg$silentFails === 0) {
35597
- peg$fail(peg$e42);
36945
+ peg$fail(peg$e45);
35598
36946
  }
35599
36947
  }
35600
36948
  }
@@ -35603,7 +36951,7 @@ function peg$parse2(input, options) {
35603
36951
  if (s0 === peg$FAILED) {
35604
36952
  s1 = peg$FAILED;
35605
36953
  if (peg$silentFails === 0) {
35606
- peg$fail(peg$e39);
36954
+ peg$fail(peg$e42);
35607
36955
  }
35608
36956
  }
35609
36957
  return s0;
@@ -35614,23 +36962,23 @@ function peg$parse2(input, options) {
35614
36962
  s0 = peg$currPos;
35615
36963
  s1 = [];
35616
36964
  s2 = input.charAt(peg$currPos);
35617
- if (peg$r4.test(s2)) {
36965
+ if (peg$r6.test(s2)) {
35618
36966
  peg$currPos++;
35619
36967
  } else {
35620
36968
  s2 = peg$FAILED;
35621
36969
  if (peg$silentFails === 0) {
35622
- peg$fail(peg$e38);
36970
+ peg$fail(peg$e41);
35623
36971
  }
35624
36972
  }
35625
36973
  while (s2 !== peg$FAILED) {
35626
36974
  s1.push(s2);
35627
36975
  s2 = input.charAt(peg$currPos);
35628
- if (peg$r4.test(s2)) {
36976
+ if (peg$r6.test(s2)) {
35629
36977
  peg$currPos++;
35630
36978
  } else {
35631
36979
  s2 = peg$FAILED;
35632
36980
  if (peg$silentFails === 0) {
35633
- peg$fail(peg$e38);
36981
+ peg$fail(peg$e41);
35634
36982
  }
35635
36983
  }
35636
36984
  }
@@ -35646,7 +36994,7 @@ function peg$parse2(input, options) {
35646
36994
  if (s0 === peg$FAILED) {
35647
36995
  s1 = peg$FAILED;
35648
36996
  if (peg$silentFails === 0) {
35649
- peg$fail(peg$e43);
36997
+ peg$fail(peg$e46);
35650
36998
  }
35651
36999
  }
35652
37000
  return s0;
@@ -35655,19 +37003,19 @@ function peg$parse2(input, options) {
35655
37003
  let s0, s1;
35656
37004
  peg$silentFails++;
35657
37005
  s0 = input.charAt(peg$currPos);
35658
- if (peg$r6.test(s0)) {
37006
+ if (peg$r8.test(s0)) {
35659
37007
  peg$currPos++;
35660
37008
  } else {
35661
37009
  s0 = peg$FAILED;
35662
37010
  if (peg$silentFails === 0) {
35663
- peg$fail(peg$e45);
37011
+ peg$fail(peg$e48);
35664
37012
  }
35665
37013
  }
35666
37014
  peg$silentFails--;
35667
37015
  if (s0 === peg$FAILED) {
35668
37016
  s1 = peg$FAILED;
35669
37017
  if (peg$silentFails === 0) {
35670
- peg$fail(peg$e44);
37018
+ peg$fail(peg$e47);
35671
37019
  }
35672
37020
  }
35673
37021
  return s0;