@gmb/bitmark-parser-generator 5.0.1 → 5.2.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/cli/main.js CHANGED
@@ -594,6 +594,7 @@ var BitType = {
594
594
  trueFalse: "true-false",
595
595
  trueFalse1: "true-false-1",
596
596
  vendorAmcharts5Chart: "vendor-amcharts-5-chart",
597
+ vendorDatadogDashboard: "vendor-datadog-dashboard",
597
598
  vendorDatadogDashboardEmbed: "vendor-datadog-dashboard-embed",
598
599
  vendorFormbricksEmbed: "vendor-formbricks-embed",
599
600
  vendorFormbricksLink: "vendor-formbricks-link",
@@ -1198,6 +1199,7 @@ var propertyKeys = {
1198
1199
  property_internalComment: "@internalComment",
1199
1200
  property_internalPrintPdf: "@internalPrintPdf",
1200
1201
  property_hasPrintRestriction: "@hasPrintRestriction",
1202
+ property_enforceUpdateOverUserInput: "@enforceUpdateOverUserInput",
1201
1203
  property_isCaseSensitive: "@isCaseSensitive",
1202
1204
  property_isInfoOnly: "@isInfoOnly",
1203
1205
  property_isPublic: "@isPublic",
@@ -1224,6 +1226,7 @@ var propertyKeys = {
1224
1226
  property_listItemIndent: "@listItemIndent",
1225
1227
  property_location: "@location",
1226
1228
  property_machineTranslated: "@machineTranslated",
1229
+ property_translationOf: "@translationOf",
1227
1230
  property_spansPageBreak: "@spansPageBreak",
1228
1231
  property_mailingList: "@mailingList",
1229
1232
  property_mark: "@mark",
@@ -2702,6 +2705,11 @@ var GROUPS = {
2702
2705
  description: "If true, the bit is machine-translated",
2703
2706
  format: TagFormat.plainText
2704
2707
  },
2708
+ {
2709
+ key: ConfigKey.property_translationOf,
2710
+ description: "Translation source reference",
2711
+ format: TagFormat.plainText
2712
+ },
2705
2713
  {
2706
2714
  key: ConfigKey.property_spansPageBreak,
2707
2715
  description: "If true, the bit spans a page break",
@@ -3352,6 +3360,12 @@ var GROUPS = {
3352
3360
  description: "If true, the book has print restrictions",
3353
3361
  format: TagFormat.boolean,
3354
3362
  defaultValue: "true"
3363
+ },
3364
+ {
3365
+ key: ConfigKey.property_enforceUpdateOverUserInput,
3366
+ description: "If true, prioritize new content over legacy content from the instance API",
3367
+ format: TagFormat.boolean,
3368
+ defaultValue: "false"
3355
3369
  }
3356
3370
  ]
3357
3371
  },
@@ -9540,6 +9554,11 @@ var BITS = {
9540
9554
  description: "AmCharts 5 chart bit, used to embed AmCharts 5 charts in articles or books",
9541
9555
  textFormatDefault: TextFormat.json
9542
9556
  },
9557
+ [BitType.vendorDatadogDashboard]: {
9558
+ since: "5.2.0",
9559
+ baseBitType: BitType.nonProductionPrototypeIframe,
9560
+ description: "A Datadog dashboard bit, used to embed Datadog dashboards"
9561
+ },
9543
9562
  [BitType.vendorDatadogDashboardEmbed]: {
9544
9563
  since: "3.12.0",
9545
9564
  baseBitType: BitType.code,
@@ -10169,7 +10188,7 @@ var instance2 = new Config();
10169
10188
  // src/generated/package_info.ts
10170
10189
  var PACKAGE_INFO = {
10171
10190
  "name": "@gmb/bitmark-parser-generator",
10172
- "version": "5.0.1",
10191
+ "version": "5.2.0",
10173
10192
  "license": "ISC"};
10174
10193
  var Environment = {
10175
10194
  unknown: "",
@@ -10440,6 +10459,7 @@ var TextMarkType = {
10440
10459
  timer: "timer",
10441
10460
  duration: "duration",
10442
10461
  color: "color",
10462
+ colorPicker: "colorPicker",
10443
10463
  comment: "comment"
10444
10464
  };
10445
10465
  var TextNodeType = {
@@ -10757,6 +10777,8 @@ var NodeType = {
10757
10777
  internalPrintPdfValue: "internalPrintPdfValue",
10758
10778
  hasPrintRestriction: "hasPrintRestriction",
10759
10779
  hasPrintRestrictionValue: "hasPrintRestrictionValue",
10780
+ enforceUpdateOverUserInput: "enforceUpdateOverUserInput",
10781
+ enforceUpdateOverUserInputValue: "enforceUpdateOverUserInputValue",
10760
10782
  isCaseSensitive: "isCaseSensitive",
10761
10783
  isCommented: "isCommented",
10762
10784
  isCorrect: "isCorrect",
@@ -10823,6 +10845,8 @@ var NodeType = {
10823
10845
  locationValue: "locationValue",
10824
10846
  machineTranslated: "machineTranslated",
10825
10847
  machineTranslatedValue: "machineTranslatedValue",
10848
+ translationOf: "translationOf",
10849
+ translationOfValue: "translationOfValue",
10826
10850
  spansPageBreak: "spansPageBreak",
10827
10851
  spansPageBreakValue: "spansPageBreakValue",
10828
10852
  mailingList: "mailingList",
@@ -11907,6 +11931,7 @@ var INLINE_MARK_TYPES = [
11907
11931
  TextMarkType.timer,
11908
11932
  TextMarkType.duration,
11909
11933
  TextMarkType.color,
11934
+ TextMarkType.colorPicker,
11910
11935
  TextMarkType.comment
11911
11936
  ];
11912
11937
  var INDENTATION_REGEX = new RegExp(/(\n|\r\n)/, "g");
@@ -11917,10 +11942,11 @@ var Stage = {
11917
11942
  between: "between",
11918
11943
  exit: "exit"
11919
11944
  };
11920
- var TextGenerator = class extends AstWalkerGenerator {
11945
+ var TextGenerator = class _TextGenerator extends AstWalkerGenerator {
11921
11946
  ast = new Ast();
11922
11947
  bitmarkVersion;
11923
11948
  options;
11949
+ internalTextGenerator = null;
11924
11950
  // State
11925
11951
  generateOptions = {};
11926
11952
  textFormat = TextFormat.bitmarkText;
@@ -11936,6 +11962,7 @@ var TextGenerator = class extends AstWalkerGenerator {
11936
11962
  exitedCodeBlock = false;
11937
11963
  inBulletList = false;
11938
11964
  inInline = false;
11965
+ markDepth = 0;
11939
11966
  textDepth = 0;
11940
11967
  placeholderIndex = 0;
11941
11968
  placeholders = {};
@@ -11966,6 +11993,13 @@ var TextGenerator = class extends AstWalkerGenerator {
11966
11993
  this.between = this.between.bind(this);
11967
11994
  this.exit = this.exit.bind(this);
11968
11995
  this.leaf = this.leaf.bind(this);
11996
+ if (!this.options.isInternal) {
11997
+ this.internalTextGenerator = new _TextGenerator(bitmarkVersion, {
11998
+ ...this.options,
11999
+ writeCallback: void 0,
12000
+ isInternal: true
12001
+ });
12002
+ }
11969
12003
  }
11970
12004
  /**
11971
12005
  * Generate text from a bitmark text AST
@@ -12022,6 +12056,7 @@ var TextGenerator = class extends AstWalkerGenerator {
12022
12056
  this.exitedCodeBlock = false;
12023
12057
  this.inBulletList = false;
12024
12058
  this.inInline = false;
12059
+ this.markDepth = 0;
12025
12060
  this.textDepth = 0;
12026
12061
  this.placeholderIndex = 0;
12027
12062
  this.placeholders = {};
@@ -12069,8 +12104,16 @@ var TextGenerator = class extends AstWalkerGenerator {
12069
12104
  exit_contentValueValue(node, route) {
12070
12105
  return this.handleExitNode(node.value, route);
12071
12106
  }
12107
+ // * -> marks
12108
+ enter_marks(_node, _route) {
12109
+ this.markDepth++;
12110
+ }
12111
+ exit_marks(_node, _route) {
12112
+ this.markDepth--;
12113
+ }
12072
12114
  // END NODE HANDLERS
12073
12115
  handleEnterNode(node, route) {
12116
+ if (this.markDepth > 0) return;
12074
12117
  this.handleEnterNodePreTextCheck(node, route);
12075
12118
  this.handleIndent(node);
12076
12119
  switch (node.type) {
@@ -12081,7 +12124,7 @@ var TextGenerator = class extends AstWalkerGenerator {
12081
12124
  case TextNodeType.hardBreak:
12082
12125
  this.writeHardBreak(node);
12083
12126
  break;
12084
- case TextNodeType.text:
12127
+ case TextNodeType.text: {
12085
12128
  this.writeMarks(node, Stage.enter);
12086
12129
  this.writeText(node);
12087
12130
  this.writeMarks(node, Stage.between);
@@ -12090,6 +12133,7 @@ var TextGenerator = class extends AstWalkerGenerator {
12090
12133
  }
12091
12134
  this.textDepth++;
12092
12135
  break;
12136
+ }
12093
12137
  case TextNodeType.heading:
12094
12138
  this.writeHeading(node);
12095
12139
  this.inHeading = true;
@@ -12138,6 +12182,7 @@ var TextGenerator = class extends AstWalkerGenerator {
12138
12182
  }
12139
12183
  }
12140
12184
  handleExitNode(node, _route) {
12185
+ if (this.markDepth > 0) return;
12141
12186
  switch (node.type) {
12142
12187
  case TextNodeType.text:
12143
12188
  this.textDepth--;
@@ -12441,7 +12486,7 @@ var TextGenerator = class extends AstWalkerGenerator {
12441
12486
  */
12442
12487
  writeMarks(node, stage) {
12443
12488
  if (node.marks) {
12444
- const forceSingleMark = !!(this.inInline || this.inHeading);
12489
+ const forceSingleMark = this.generateOptions.forceInline || !!(this.inInline || this.inHeading);
12445
12490
  this.thisNodeIsPreText = false;
12446
12491
  const emptyMarks = node.marks.length === 0;
12447
12492
  if (emptyMarks) {
@@ -12628,7 +12673,7 @@ var TextGenerator = class extends AstWalkerGenerator {
12628
12673
  let s = `${mark.type}`;
12629
12674
  if (mark.attrs) {
12630
12675
  for (const [k, v] of Object.entries(mark.attrs)) {
12631
- if (k === "language" && v !== "plain text" || k === "color" || k === "name" || k === "duration") {
12676
+ if (k === "language" && v !== "plain text" || k === "color" || k === "propertyRef" || k === "name" || k === "duration") {
12632
12677
  s = `${s}:${v}`;
12633
12678
  }
12634
12679
  }
@@ -12669,13 +12714,33 @@ var TextGenerator = class extends AstWalkerGenerator {
12669
12714
  s += `|provider:${provider}`;
12670
12715
  this.write(s);
12671
12716
  }
12672
- writeFootnoteMark(_mark) {
12717
+ writeFootnoteMark(mark) {
12673
12718
  const s = `footnote:`;
12674
12719
  this.write(s);
12720
+ const text = this.internalTextGenerator?.generateSync(
12721
+ mark.attrs?.content,
12722
+ this.textFormat,
12723
+ this.textLocation,
12724
+ {
12725
+ ...this.generateOptions,
12726
+ forceInline: true
12727
+ }
12728
+ ) ?? "";
12729
+ this.write(text);
12675
12730
  }
12676
- writeFootnoteStarMark(_mark) {
12731
+ writeFootnoteStarMark(mark) {
12677
12732
  const s = `footnote*:`;
12678
12733
  this.write(s);
12734
+ const text = this.internalTextGenerator?.generateSync(
12735
+ mark.attrs?.content,
12736
+ this.textFormat,
12737
+ this.textLocation,
12738
+ {
12739
+ ...this.generateOptions,
12740
+ forceInline: true
12741
+ }
12742
+ ) ?? "";
12743
+ this.write(text);
12679
12744
  }
12680
12745
  writeSymbolMark(mark) {
12681
12746
  if (mark.attrs == null) return;
@@ -12819,7 +12884,7 @@ var TextGenerator = class extends AstWalkerGenerator {
12819
12884
  };
12820
12885
 
12821
12886
  // src/generated/parser/text/text-peggy-parser.js
12822
- var VERSION = "8.35.0";
12887
+ var VERSION = "8.37.3";
12823
12888
  function unbreakscape(str) {
12824
12889
  if (typeof str !== "string") return null;
12825
12890
  return instance3.unbreakscape(str);
@@ -13038,72 +13103,83 @@ function peg$parse(input, options) {
13038
13103
  const peg$c64 = "duration:";
13039
13104
  const peg$c65 = "P";
13040
13105
  const peg$c66 = "color:";
13041
- const peg$c67 = "|\u25BA";
13042
- const peg$c68 = "bold";
13043
- const peg$c69 = "italic";
13044
- const peg$c70 = "light";
13045
- const peg$c71 = "highlight";
13046
- const peg$c72 = "strike";
13047
- const peg$c73 = "subscript";
13048
- const peg$c74 = "superscript";
13049
- const peg$c75 = "ins";
13050
- const peg$c76 = "del";
13051
- const peg$c77 = "underline";
13052
- const peg$c78 = "doubleUnderline";
13053
- const peg$c79 = "circle";
13054
- const peg$c80 = "languageEmRed";
13055
- const peg$c81 = "languageEmOrange";
13056
- const peg$c82 = "languageEmYellow";
13057
- const peg$c83 = "languageEmGreen";
13058
- const peg$c84 = "languageEmBlue";
13059
- const peg$c85 = "languageEmPurple";
13060
- const peg$c86 = "languageEmPink";
13061
- const peg$c87 = "languageEmBrown";
13062
- const peg$c88 = "languageEmBlack";
13063
- const peg$c89 = "languageEmWhite";
13064
- const peg$c90 = "languageEmGray";
13065
- const peg$c91 = "languageEm";
13066
- const peg$c92 = "userUnderline";
13067
- const peg$c93 = "userDoubleUnderline";
13068
- const peg$c94 = "userStrike";
13069
- const peg$c95 = "userCircle";
13070
- const peg$c96 = "userHighlight";
13071
- const peg$c97 = "notranslate";
13072
- const peg$c98 = "aqua";
13073
- const peg$c99 = "black";
13074
- const peg$c100 = "blue";
13075
- const peg$c101 = "brown";
13076
- const peg$c102 = "fuchsia";
13077
- const peg$c103 = "lightgrey";
13078
- const peg$c104 = "gray";
13079
- const peg$c105 = "darkgray";
13080
- const peg$c106 = "green";
13081
- const peg$c107 = "lime";
13082
- const peg$c108 = "magenta";
13083
- const peg$c109 = "maroon";
13084
- const peg$c110 = "navy";
13085
- const peg$c111 = "olive";
13086
- const peg$c112 = "orange";
13087
- const peg$c113 = "pink";
13088
- const peg$c114 = "purple";
13089
- const peg$c115 = "red";
13090
- const peg$c116 = "silver";
13091
- const peg$c117 = "teal";
13092
- const peg$c118 = "violet";
13093
- const peg$c119 = "white";
13094
- const peg$c120 = "yellow";
13095
- const peg$c121 = "*";
13096
- const peg$c122 = "_";
13097
- const peg$c123 = "`";
13098
- const peg$c124 = "!";
13099
- const peg$c125 = "[!";
13100
- const peg$c126 = "]";
13101
- const peg$c127 = "\n";
13102
- const peg$c128 = "\r\n";
13103
- const peg$c129 = "http";
13104
- const peg$c130 = "s";
13105
- const peg$c131 = "://";
13106
- const peg$c132 = "mailto:";
13106
+ const peg$c67 = "colorPicker:";
13107
+ const peg$c68 = "|\u25BA";
13108
+ const peg$c69 = "bold";
13109
+ const peg$c70 = "italic";
13110
+ const peg$c71 = "light";
13111
+ const peg$c72 = "highlightOrange";
13112
+ const peg$c73 = "highlightYellow";
13113
+ const peg$c74 = "highlightGreen";
13114
+ const peg$c75 = "highlightBlue";
13115
+ const peg$c76 = "highlightPurple";
13116
+ const peg$c77 = "highlightPink";
13117
+ const peg$c78 = "highlightBrown";
13118
+ const peg$c79 = "highlightBlack";
13119
+ const peg$c80 = "highlightWhite";
13120
+ const peg$c81 = "highlightGray";
13121
+ const peg$c82 = "highlight";
13122
+ const peg$c83 = "strike";
13123
+ const peg$c84 = "subscript";
13124
+ const peg$c85 = "superscript";
13125
+ const peg$c86 = "ins";
13126
+ const peg$c87 = "del";
13127
+ const peg$c88 = "underline";
13128
+ const peg$c89 = "doubleUnderline";
13129
+ const peg$c90 = "circle";
13130
+ const peg$c91 = "languageEmRed";
13131
+ const peg$c92 = "languageEmOrange";
13132
+ const peg$c93 = "languageEmYellow";
13133
+ const peg$c94 = "languageEmGreen";
13134
+ const peg$c95 = "languageEmBlue";
13135
+ const peg$c96 = "languageEmPurple";
13136
+ const peg$c97 = "languageEmPink";
13137
+ const peg$c98 = "languageEmBrown";
13138
+ const peg$c99 = "languageEmBlack";
13139
+ const peg$c100 = "languageEmWhite";
13140
+ const peg$c101 = "languageEmGray";
13141
+ const peg$c102 = "languageEm";
13142
+ const peg$c103 = "userUnderline";
13143
+ const peg$c104 = "userDoubleUnderline";
13144
+ const peg$c105 = "userStrike";
13145
+ const peg$c106 = "userCircle";
13146
+ const peg$c107 = "userHighlight";
13147
+ const peg$c108 = "notranslate";
13148
+ const peg$c109 = "aqua";
13149
+ const peg$c110 = "black";
13150
+ const peg$c111 = "blue";
13151
+ const peg$c112 = "brown";
13152
+ const peg$c113 = "fuchsia";
13153
+ const peg$c114 = "lightgrey";
13154
+ const peg$c115 = "gray";
13155
+ const peg$c116 = "darkgray";
13156
+ const peg$c117 = "green";
13157
+ const peg$c118 = "lime";
13158
+ const peg$c119 = "magenta";
13159
+ const peg$c120 = "maroon";
13160
+ const peg$c121 = "navy";
13161
+ const peg$c122 = "olive";
13162
+ const peg$c123 = "orange";
13163
+ const peg$c124 = "pink";
13164
+ const peg$c125 = "purple";
13165
+ const peg$c126 = "red";
13166
+ const peg$c127 = "silver";
13167
+ const peg$c128 = "teal";
13168
+ const peg$c129 = "violet";
13169
+ const peg$c130 = "white";
13170
+ const peg$c131 = "yellow";
13171
+ const peg$c132 = "*";
13172
+ const peg$c133 = "_";
13173
+ const peg$c134 = "`";
13174
+ const peg$c135 = "!";
13175
+ const peg$c136 = "[!";
13176
+ const peg$c137 = "]";
13177
+ const peg$c138 = "\n";
13178
+ const peg$c139 = "\r\n";
13179
+ const peg$c140 = "http";
13180
+ const peg$c141 = "s";
13181
+ const peg$c142 = "://";
13182
+ const peg$c143 = "mailto:";
13107
13183
  const peg$r0 = /^[ \t]/;
13108
13184
  const peg$r1 = /^[0-9]/;
13109
13185
  const peg$r2 = /^[\r\u2028-\u2029]/;
@@ -13180,76 +13256,87 @@ function peg$parse(input, options) {
13180
13256
  const peg$e68 = peg$literalExpectation("duration:", false);
13181
13257
  const peg$e69 = peg$literalExpectation("P", false);
13182
13258
  const peg$e70 = peg$literalExpectation("color:", false);
13183
- const peg$e71 = peg$literalExpectation("|\u25BA", false);
13184
- const peg$e72 = peg$literalExpectation("bold", false);
13185
- const peg$e73 = peg$literalExpectation("italic", false);
13186
- const peg$e74 = peg$literalExpectation("light", false);
13187
- const peg$e75 = peg$literalExpectation("highlight", false);
13188
- const peg$e76 = peg$literalExpectation("strike", false);
13189
- const peg$e77 = peg$literalExpectation("subscript", false);
13190
- const peg$e78 = peg$literalExpectation("superscript", false);
13191
- const peg$e79 = peg$literalExpectation("ins", false);
13192
- const peg$e80 = peg$literalExpectation("del", false);
13193
- const peg$e81 = peg$literalExpectation("underline", false);
13194
- const peg$e82 = peg$literalExpectation("doubleUnderline", false);
13195
- const peg$e83 = peg$literalExpectation("circle", false);
13196
- const peg$e84 = peg$literalExpectation("languageEmRed", false);
13197
- const peg$e85 = peg$literalExpectation("languageEmOrange", false);
13198
- const peg$e86 = peg$literalExpectation("languageEmYellow", false);
13199
- const peg$e87 = peg$literalExpectation("languageEmGreen", false);
13200
- const peg$e88 = peg$literalExpectation("languageEmBlue", false);
13201
- const peg$e89 = peg$literalExpectation("languageEmPurple", false);
13202
- const peg$e90 = peg$literalExpectation("languageEmPink", false);
13203
- const peg$e91 = peg$literalExpectation("languageEmBrown", false);
13204
- const peg$e92 = peg$literalExpectation("languageEmBlack", false);
13205
- const peg$e93 = peg$literalExpectation("languageEmWhite", false);
13206
- const peg$e94 = peg$literalExpectation("languageEmGray", false);
13207
- const peg$e95 = peg$literalExpectation("languageEm", false);
13208
- const peg$e96 = peg$literalExpectation("userUnderline", false);
13209
- const peg$e97 = peg$literalExpectation("userDoubleUnderline", false);
13210
- const peg$e98 = peg$literalExpectation("userStrike", false);
13211
- const peg$e99 = peg$literalExpectation("userCircle", false);
13212
- const peg$e100 = peg$literalExpectation("userHighlight", false);
13213
- const peg$e101 = peg$literalExpectation("notranslate", false);
13214
- const peg$e102 = peg$literalExpectation("aqua", false);
13215
- const peg$e103 = peg$literalExpectation("black", false);
13216
- const peg$e104 = peg$literalExpectation("blue", false);
13217
- const peg$e105 = peg$literalExpectation("brown", false);
13218
- const peg$e106 = peg$literalExpectation("fuchsia", false);
13219
- const peg$e107 = peg$literalExpectation("lightgrey", false);
13220
- const peg$e108 = peg$literalExpectation("gray", false);
13221
- const peg$e109 = peg$literalExpectation("darkgray", false);
13222
- const peg$e110 = peg$literalExpectation("green", false);
13223
- const peg$e111 = peg$literalExpectation("lime", false);
13224
- const peg$e112 = peg$literalExpectation("magenta", false);
13225
- const peg$e113 = peg$literalExpectation("maroon", false);
13226
- const peg$e114 = peg$literalExpectation("navy", false);
13227
- const peg$e115 = peg$literalExpectation("olive", false);
13228
- const peg$e116 = peg$literalExpectation("orange", false);
13229
- const peg$e117 = peg$literalExpectation("pink", false);
13230
- const peg$e118 = peg$literalExpectation("purple", false);
13231
- const peg$e119 = peg$literalExpectation("red", false);
13232
- const peg$e120 = peg$literalExpectation("silver", false);
13233
- const peg$e121 = peg$literalExpectation("teal", false);
13234
- const peg$e122 = peg$literalExpectation("violet", false);
13235
- const peg$e123 = peg$literalExpectation("white", false);
13236
- const peg$e124 = peg$literalExpectation("yellow", false);
13237
- const peg$e125 = peg$literalExpectation("*", false);
13238
- const peg$e126 = peg$literalExpectation("_", false);
13239
- const peg$e127 = peg$literalExpectation("`", false);
13240
- const peg$e128 = peg$literalExpectation("!", false);
13241
- const peg$e129 = peg$literalExpectation("[!", false);
13242
- const peg$e130 = peg$literalExpectation("]", false);
13243
- const peg$e131 = peg$otherExpectation("Line Terminator");
13244
- const peg$e132 = peg$literalExpectation("\n", false);
13245
- const peg$e133 = peg$literalExpectation("\r\n", false);
13246
- const peg$e134 = peg$classExpectation(["\r", ["\u2028", "\u2029"]], false, false, false);
13247
- const peg$e135 = peg$classExpectation(["\n", "\r", "\u2028", "\u2029"], true, false, false);
13248
- const peg$e136 = peg$literalExpectation("http", false);
13249
- const peg$e137 = peg$literalExpectation("s", false);
13250
- const peg$e138 = peg$literalExpectation("://", false);
13251
- const peg$e139 = peg$literalExpectation("mailto:", false);
13252
- const peg$e140 = peg$classExpectation(["!", ["#", ";"], "=", ["?", "["], ["]", "_"], ["a", "{"], ["}", "~"]], false, false, false);
13259
+ const peg$e71 = peg$literalExpectation("colorPicker:", false);
13260
+ const peg$e72 = peg$literalExpectation("|\u25BA", false);
13261
+ const peg$e73 = peg$literalExpectation("bold", false);
13262
+ const peg$e74 = peg$literalExpectation("italic", false);
13263
+ const peg$e75 = peg$literalExpectation("light", false);
13264
+ const peg$e76 = peg$literalExpectation("highlightOrange", false);
13265
+ const peg$e77 = peg$literalExpectation("highlightYellow", false);
13266
+ const peg$e78 = peg$literalExpectation("highlightGreen", false);
13267
+ const peg$e79 = peg$literalExpectation("highlightBlue", false);
13268
+ const peg$e80 = peg$literalExpectation("highlightPurple", false);
13269
+ const peg$e81 = peg$literalExpectation("highlightPink", false);
13270
+ const peg$e82 = peg$literalExpectation("highlightBrown", false);
13271
+ const peg$e83 = peg$literalExpectation("highlightBlack", false);
13272
+ const peg$e84 = peg$literalExpectation("highlightWhite", false);
13273
+ const peg$e85 = peg$literalExpectation("highlightGray", false);
13274
+ const peg$e86 = peg$literalExpectation("highlight", false);
13275
+ const peg$e87 = peg$literalExpectation("strike", false);
13276
+ const peg$e88 = peg$literalExpectation("subscript", false);
13277
+ const peg$e89 = peg$literalExpectation("superscript", false);
13278
+ const peg$e90 = peg$literalExpectation("ins", false);
13279
+ const peg$e91 = peg$literalExpectation("del", false);
13280
+ const peg$e92 = peg$literalExpectation("underline", false);
13281
+ const peg$e93 = peg$literalExpectation("doubleUnderline", false);
13282
+ const peg$e94 = peg$literalExpectation("circle", false);
13283
+ const peg$e95 = peg$literalExpectation("languageEmRed", false);
13284
+ const peg$e96 = peg$literalExpectation("languageEmOrange", false);
13285
+ const peg$e97 = peg$literalExpectation("languageEmYellow", false);
13286
+ const peg$e98 = peg$literalExpectation("languageEmGreen", false);
13287
+ const peg$e99 = peg$literalExpectation("languageEmBlue", false);
13288
+ const peg$e100 = peg$literalExpectation("languageEmPurple", false);
13289
+ const peg$e101 = peg$literalExpectation("languageEmPink", false);
13290
+ const peg$e102 = peg$literalExpectation("languageEmBrown", false);
13291
+ const peg$e103 = peg$literalExpectation("languageEmBlack", false);
13292
+ const peg$e104 = peg$literalExpectation("languageEmWhite", false);
13293
+ const peg$e105 = peg$literalExpectation("languageEmGray", false);
13294
+ const peg$e106 = peg$literalExpectation("languageEm", false);
13295
+ const peg$e107 = peg$literalExpectation("userUnderline", false);
13296
+ const peg$e108 = peg$literalExpectation("userDoubleUnderline", false);
13297
+ const peg$e109 = peg$literalExpectation("userStrike", false);
13298
+ const peg$e110 = peg$literalExpectation("userCircle", false);
13299
+ const peg$e111 = peg$literalExpectation("userHighlight", false);
13300
+ const peg$e112 = peg$literalExpectation("notranslate", false);
13301
+ const peg$e113 = peg$literalExpectation("aqua", false);
13302
+ const peg$e114 = peg$literalExpectation("black", false);
13303
+ const peg$e115 = peg$literalExpectation("blue", false);
13304
+ const peg$e116 = peg$literalExpectation("brown", false);
13305
+ const peg$e117 = peg$literalExpectation("fuchsia", false);
13306
+ const peg$e118 = peg$literalExpectation("lightgrey", false);
13307
+ const peg$e119 = peg$literalExpectation("gray", false);
13308
+ const peg$e120 = peg$literalExpectation("darkgray", false);
13309
+ const peg$e121 = peg$literalExpectation("green", false);
13310
+ const peg$e122 = peg$literalExpectation("lime", false);
13311
+ const peg$e123 = peg$literalExpectation("magenta", false);
13312
+ const peg$e124 = peg$literalExpectation("maroon", false);
13313
+ const peg$e125 = peg$literalExpectation("navy", false);
13314
+ const peg$e126 = peg$literalExpectation("olive", false);
13315
+ const peg$e127 = peg$literalExpectation("orange", false);
13316
+ const peg$e128 = peg$literalExpectation("pink", false);
13317
+ const peg$e129 = peg$literalExpectation("purple", false);
13318
+ const peg$e130 = peg$literalExpectation("red", false);
13319
+ const peg$e131 = peg$literalExpectation("silver", false);
13320
+ const peg$e132 = peg$literalExpectation("teal", false);
13321
+ const peg$e133 = peg$literalExpectation("violet", false);
13322
+ const peg$e134 = peg$literalExpectation("white", false);
13323
+ const peg$e135 = peg$literalExpectation("yellow", false);
13324
+ const peg$e136 = peg$literalExpectation("*", false);
13325
+ const peg$e137 = peg$literalExpectation("_", false);
13326
+ const peg$e138 = peg$literalExpectation("`", false);
13327
+ const peg$e139 = peg$literalExpectation("!", false);
13328
+ const peg$e140 = peg$literalExpectation("[!", false);
13329
+ const peg$e141 = peg$literalExpectation("]", false);
13330
+ const peg$e142 = peg$otherExpectation("Line Terminator");
13331
+ const peg$e143 = peg$literalExpectation("\n", false);
13332
+ const peg$e144 = peg$literalExpectation("\r\n", false);
13333
+ const peg$e145 = peg$classExpectation(["\r", ["\u2028", "\u2029"]], false, false, false);
13334
+ const peg$e146 = peg$classExpectation(["\n", "\r", "\u2028", "\u2029"], true, false, false);
13335
+ const peg$e147 = peg$literalExpectation("http", false);
13336
+ const peg$e148 = peg$literalExpectation("s", false);
13337
+ const peg$e149 = peg$literalExpectation("://", false);
13338
+ const peg$e150 = peg$literalExpectation("mailto:", false);
13339
+ const peg$e151 = peg$classExpectation(["!", ["#", ";"], "=", ["?", "["], ["]", "_"], ["a", "{"], ["}", "~"]], false, false, false);
13253
13340
  function peg$f0() {
13254
13341
  return VERSION;
13255
13342
  }
@@ -13616,44 +13703,47 @@ function peg$parse(input, options) {
13616
13703
  function peg$f86(color) {
13617
13704
  return { type: "color", attrs: { color } };
13618
13705
  }
13619
- function peg$f87(style) {
13706
+ function peg$f87(str) {
13707
+ return { type: "colorPicker", attrs: { propertyRef: str.trim() } };
13708
+ }
13709
+ function peg$f88(style) {
13620
13710
  return { type: style };
13621
13711
  }
13622
- function peg$f88(str) {
13712
+ function peg$f89(str) {
13623
13713
  return { type: "comment", comment: str };
13624
13714
  }
13625
- function peg$f89(r) {
13715
+ function peg$f90(r) {
13626
13716
  return r.trim();
13627
13717
  }
13628
- function peg$f90(bs) {
13718
+ function peg$f91(bs) {
13629
13719
  return [{ type: "paragraph", content: bs, attrs: {} }];
13630
13720
  }
13631
- function peg$f91(first, more) {
13721
+ function peg$f92(first, more) {
13632
13722
  const cleaned_ = cleanEmptyTextNodes(first ? [first, ...more.flat()] : more.flat());
13633
13723
  return cleaned_;
13634
13724
  }
13635
- function peg$f92() {
13725
+ function peg$f93() {
13636
13726
  return { "type": "hardBreak" };
13637
13727
  }
13638
- function peg$f93(t) {
13728
+ function peg$f94(t) {
13639
13729
  return { text: unbreakscape(t), type: "text" };
13640
13730
  }
13641
- function peg$f94(t) {
13731
+ function peg$f95(t) {
13642
13732
  return { index: +t, type: "bit" };
13643
13733
  }
13644
- function peg$f95(t) {
13734
+ function peg$f96(t) {
13645
13735
  return { marks: [{ type: "bold" }], text: unbreakscape(t), type: "text" };
13646
13736
  }
13647
- function peg$f96(t) {
13737
+ function peg$f97(t) {
13648
13738
  return { marks: [{ type: "italic" }], text: unbreakscape(t), type: "text" };
13649
13739
  }
13650
- function peg$f97(t) {
13740
+ function peg$f98(t) {
13651
13741
  return { marks: [{ type: "light" }], text: unbreakscape(t), type: "text" };
13652
13742
  }
13653
- function peg$f98(t) {
13743
+ function peg$f99(t) {
13654
13744
  return { marks: [{ type: "highlight" }], text: unbreakscape(t), type: "text" };
13655
13745
  }
13656
- function peg$f99(pr, t) {
13746
+ function peg$f100(pr, t) {
13657
13747
  return { pr, t };
13658
13748
  }
13659
13749
  let peg$currPos = options.peg$currPos | 0;
@@ -19589,33 +19679,44 @@ function peg$parse(input, options) {
19589
19679
  }
19590
19680
  if (s0 === peg$FAILED) {
19591
19681
  s0 = peg$currPos;
19592
- s1 = peg$parseAlternativeStyleTags();
19593
- if (s1 !== peg$FAILED) {
19594
- s2 = peg$parseBlockTag();
19595
- if (s2 !== peg$FAILED) {
19596
- s0 = peg$f87(s1);
19597
- } else {
19598
- peg$currPos = s0;
19599
- s0 = peg$FAILED;
19600
- }
19682
+ if (input.substr(peg$currPos, 12) === peg$c67) {
19683
+ s1 = peg$c67;
19684
+ peg$currPos += 12;
19601
19685
  } else {
19602
- peg$currPos = s0;
19603
- s0 = peg$FAILED;
19686
+ s1 = peg$FAILED;
19687
+ if (peg$silentFails === 0) {
19688
+ peg$fail(peg$e71);
19689
+ }
19604
19690
  }
19605
- if (s0 === peg$FAILED) {
19606
- s0 = peg$currPos;
19607
- if (input.charCodeAt(peg$currPos) === 35) {
19608
- s1 = peg$c21;
19609
- peg$currPos++;
19691
+ if (s1 !== peg$FAILED) {
19692
+ s2 = peg$currPos;
19693
+ s3 = [];
19694
+ s4 = peg$currPos;
19695
+ s5 = peg$currPos;
19696
+ peg$silentFails++;
19697
+ s6 = peg$parseBlockTag();
19698
+ peg$silentFails--;
19699
+ if (s6 === peg$FAILED) {
19700
+ s5 = void 0;
19610
19701
  } else {
19611
- s1 = peg$FAILED;
19612
- if (peg$silentFails === 0) {
19613
- peg$fail(peg$e25);
19702
+ peg$currPos = s5;
19703
+ s5 = peg$FAILED;
19704
+ }
19705
+ if (s5 !== peg$FAILED) {
19706
+ s6 = peg$parsechar();
19707
+ if (s6 !== peg$FAILED) {
19708
+ s5 = [s5, s6];
19709
+ s4 = s5;
19710
+ } else {
19711
+ peg$currPos = s4;
19712
+ s4 = peg$FAILED;
19614
19713
  }
19714
+ } else {
19715
+ peg$currPos = s4;
19716
+ s4 = peg$FAILED;
19615
19717
  }
19616
- if (s1 !== peg$FAILED) {
19617
- s2 = peg$currPos;
19618
- s3 = [];
19718
+ while (s4 !== peg$FAILED) {
19719
+ s3.push(s4);
19619
19720
  s4 = peg$currPos;
19620
19721
  s5 = peg$currPos;
19621
19722
  peg$silentFails++;
@@ -19640,8 +19741,48 @@ function peg$parse(input, options) {
19640
19741
  peg$currPos = s4;
19641
19742
  s4 = peg$FAILED;
19642
19743
  }
19643
- while (s4 !== peg$FAILED) {
19644
- s3.push(s4);
19744
+ }
19745
+ s2 = input.substring(s2, peg$currPos);
19746
+ s3 = peg$parseBlockTag();
19747
+ if (s3 !== peg$FAILED) {
19748
+ s0 = peg$f87(s2);
19749
+ } else {
19750
+ peg$currPos = s0;
19751
+ s0 = peg$FAILED;
19752
+ }
19753
+ } else {
19754
+ peg$currPos = s0;
19755
+ s0 = peg$FAILED;
19756
+ }
19757
+ if (s0 === peg$FAILED) {
19758
+ s0 = peg$currPos;
19759
+ s1 = peg$parseAlternativeStyleTags();
19760
+ if (s1 !== peg$FAILED) {
19761
+ s2 = peg$parseBlockTag();
19762
+ if (s2 !== peg$FAILED) {
19763
+ s0 = peg$f88(s1);
19764
+ } else {
19765
+ peg$currPos = s0;
19766
+ s0 = peg$FAILED;
19767
+ }
19768
+ } else {
19769
+ peg$currPos = s0;
19770
+ s0 = peg$FAILED;
19771
+ }
19772
+ if (s0 === peg$FAILED) {
19773
+ s0 = peg$currPos;
19774
+ if (input.charCodeAt(peg$currPos) === 35) {
19775
+ s1 = peg$c21;
19776
+ peg$currPos++;
19777
+ } else {
19778
+ s1 = peg$FAILED;
19779
+ if (peg$silentFails === 0) {
19780
+ peg$fail(peg$e25);
19781
+ }
19782
+ }
19783
+ if (s1 !== peg$FAILED) {
19784
+ s2 = peg$currPos;
19785
+ s3 = [];
19645
19786
  s4 = peg$currPos;
19646
19787
  s5 = peg$currPos;
19647
19788
  peg$silentFails++;
@@ -19666,18 +19807,45 @@ function peg$parse(input, options) {
19666
19807
  peg$currPos = s4;
19667
19808
  s4 = peg$FAILED;
19668
19809
  }
19669
- }
19670
- s2 = input.substring(s2, peg$currPos);
19671
- s3 = peg$parseBlockTag();
19672
- if (s3 !== peg$FAILED) {
19673
- s0 = peg$f88(s2);
19810
+ while (s4 !== peg$FAILED) {
19811
+ s3.push(s4);
19812
+ s4 = peg$currPos;
19813
+ s5 = peg$currPos;
19814
+ peg$silentFails++;
19815
+ s6 = peg$parseBlockTag();
19816
+ peg$silentFails--;
19817
+ if (s6 === peg$FAILED) {
19818
+ s5 = void 0;
19819
+ } else {
19820
+ peg$currPos = s5;
19821
+ s5 = peg$FAILED;
19822
+ }
19823
+ if (s5 !== peg$FAILED) {
19824
+ s6 = peg$parsechar();
19825
+ if (s6 !== peg$FAILED) {
19826
+ s5 = [s5, s6];
19827
+ s4 = s5;
19828
+ } else {
19829
+ peg$currPos = s4;
19830
+ s4 = peg$FAILED;
19831
+ }
19832
+ } else {
19833
+ peg$currPos = s4;
19834
+ s4 = peg$FAILED;
19835
+ }
19836
+ }
19837
+ s2 = input.substring(s2, peg$currPos);
19838
+ s3 = peg$parseBlockTag();
19839
+ if (s3 !== peg$FAILED) {
19840
+ s0 = peg$f89(s2);
19841
+ } else {
19842
+ peg$currPos = s0;
19843
+ s0 = peg$FAILED;
19844
+ }
19674
19845
  } else {
19675
19846
  peg$currPos = s0;
19676
19847
  s0 = peg$FAILED;
19677
19848
  }
19678
- } else {
19679
- peg$currPos = s0;
19680
- s0 = peg$FAILED;
19681
19849
  }
19682
19850
  }
19683
19851
  }
@@ -19710,13 +19878,13 @@ function peg$parse(input, options) {
19710
19878
  function peg$parseRef() {
19711
19879
  let s0, s1, s2, s3, s4, s5, s6;
19712
19880
  s0 = peg$currPos;
19713
- if (input.substr(peg$currPos, 2) === peg$c67) {
19714
- s1 = peg$c67;
19881
+ if (input.substr(peg$currPos, 2) === peg$c68) {
19882
+ s1 = peg$c68;
19715
19883
  peg$currPos += 2;
19716
19884
  } else {
19717
19885
  s1 = peg$FAILED;
19718
19886
  if (peg$silentFails === 0) {
19719
- peg$fail(peg$e71);
19887
+ peg$fail(peg$e72);
19720
19888
  }
19721
19889
  }
19722
19890
  if (s1 !== peg$FAILED) {
@@ -19774,7 +19942,7 @@ function peg$parse(input, options) {
19774
19942
  }
19775
19943
  }
19776
19944
  s2 = input.substring(s2, peg$currPos);
19777
- s0 = peg$f89(s2);
19945
+ s0 = peg$f90(s2);
19778
19946
  } else {
19779
19947
  peg$currPos = s0;
19780
19948
  s0 = peg$FAILED;
@@ -19783,303 +19951,413 @@ function peg$parse(input, options) {
19783
19951
  }
19784
19952
  function peg$parseAlternativeStyleTags() {
19785
19953
  let s0;
19786
- if (input.substr(peg$currPos, 4) === peg$c68) {
19787
- s0 = peg$c68;
19954
+ if (input.substr(peg$currPos, 4) === peg$c69) {
19955
+ s0 = peg$c69;
19788
19956
  peg$currPos += 4;
19789
19957
  } else {
19790
19958
  s0 = peg$FAILED;
19791
19959
  if (peg$silentFails === 0) {
19792
- peg$fail(peg$e72);
19960
+ peg$fail(peg$e73);
19793
19961
  }
19794
19962
  }
19795
19963
  if (s0 === peg$FAILED) {
19796
- if (input.substr(peg$currPos, 6) === peg$c69) {
19797
- s0 = peg$c69;
19964
+ if (input.substr(peg$currPos, 6) === peg$c70) {
19965
+ s0 = peg$c70;
19798
19966
  peg$currPos += 6;
19799
19967
  } else {
19800
19968
  s0 = peg$FAILED;
19801
19969
  if (peg$silentFails === 0) {
19802
- peg$fail(peg$e73);
19970
+ peg$fail(peg$e74);
19803
19971
  }
19804
19972
  }
19805
19973
  if (s0 === peg$FAILED) {
19806
- if (input.substr(peg$currPos, 5) === peg$c70) {
19807
- s0 = peg$c70;
19974
+ if (input.substr(peg$currPos, 5) === peg$c71) {
19975
+ s0 = peg$c71;
19808
19976
  peg$currPos += 5;
19809
19977
  } else {
19810
19978
  s0 = peg$FAILED;
19811
19979
  if (peg$silentFails === 0) {
19812
- peg$fail(peg$e74);
19980
+ peg$fail(peg$e75);
19813
19981
  }
19814
19982
  }
19815
19983
  if (s0 === peg$FAILED) {
19816
- if (input.substr(peg$currPos, 9) === peg$c71) {
19817
- s0 = peg$c71;
19818
- peg$currPos += 9;
19984
+ if (input.substr(peg$currPos, 15) === peg$c72) {
19985
+ s0 = peg$c72;
19986
+ peg$currPos += 15;
19819
19987
  } else {
19820
19988
  s0 = peg$FAILED;
19821
19989
  if (peg$silentFails === 0) {
19822
- peg$fail(peg$e75);
19990
+ peg$fail(peg$e76);
19823
19991
  }
19824
19992
  }
19825
19993
  if (s0 === peg$FAILED) {
19826
- if (input.substr(peg$currPos, 6) === peg$c72) {
19827
- s0 = peg$c72;
19828
- peg$currPos += 6;
19994
+ if (input.substr(peg$currPos, 15) === peg$c73) {
19995
+ s0 = peg$c73;
19996
+ peg$currPos += 15;
19829
19997
  } else {
19830
19998
  s0 = peg$FAILED;
19831
19999
  if (peg$silentFails === 0) {
19832
- peg$fail(peg$e76);
20000
+ peg$fail(peg$e77);
19833
20001
  }
19834
20002
  }
19835
20003
  if (s0 === peg$FAILED) {
19836
- if (input.substr(peg$currPos, 9) === peg$c73) {
19837
- s0 = peg$c73;
19838
- peg$currPos += 9;
20004
+ if (input.substr(peg$currPos, 14) === peg$c74) {
20005
+ s0 = peg$c74;
20006
+ peg$currPos += 14;
19839
20007
  } else {
19840
20008
  s0 = peg$FAILED;
19841
20009
  if (peg$silentFails === 0) {
19842
- peg$fail(peg$e77);
20010
+ peg$fail(peg$e78);
19843
20011
  }
19844
20012
  }
19845
20013
  if (s0 === peg$FAILED) {
19846
- if (input.substr(peg$currPos, 11) === peg$c74) {
19847
- s0 = peg$c74;
19848
- peg$currPos += 11;
20014
+ if (input.substr(peg$currPos, 13) === peg$c75) {
20015
+ s0 = peg$c75;
20016
+ peg$currPos += 13;
19849
20017
  } else {
19850
20018
  s0 = peg$FAILED;
19851
20019
  if (peg$silentFails === 0) {
19852
- peg$fail(peg$e78);
20020
+ peg$fail(peg$e79);
19853
20021
  }
19854
20022
  }
19855
20023
  if (s0 === peg$FAILED) {
19856
- if (input.substr(peg$currPos, 3) === peg$c75) {
19857
- s0 = peg$c75;
19858
- peg$currPos += 3;
20024
+ if (input.substr(peg$currPos, 15) === peg$c76) {
20025
+ s0 = peg$c76;
20026
+ peg$currPos += 15;
19859
20027
  } else {
19860
20028
  s0 = peg$FAILED;
19861
20029
  if (peg$silentFails === 0) {
19862
- peg$fail(peg$e79);
20030
+ peg$fail(peg$e80);
19863
20031
  }
19864
20032
  }
19865
20033
  if (s0 === peg$FAILED) {
19866
- if (input.substr(peg$currPos, 3) === peg$c76) {
19867
- s0 = peg$c76;
19868
- peg$currPos += 3;
20034
+ if (input.substr(peg$currPos, 13) === peg$c77) {
20035
+ s0 = peg$c77;
20036
+ peg$currPos += 13;
19869
20037
  } else {
19870
20038
  s0 = peg$FAILED;
19871
20039
  if (peg$silentFails === 0) {
19872
- peg$fail(peg$e80);
20040
+ peg$fail(peg$e81);
19873
20041
  }
19874
20042
  }
19875
20043
  if (s0 === peg$FAILED) {
19876
- if (input.substr(peg$currPos, 9) === peg$c77) {
19877
- s0 = peg$c77;
19878
- peg$currPos += 9;
20044
+ if (input.substr(peg$currPos, 14) === peg$c78) {
20045
+ s0 = peg$c78;
20046
+ peg$currPos += 14;
19879
20047
  } else {
19880
20048
  s0 = peg$FAILED;
19881
20049
  if (peg$silentFails === 0) {
19882
- peg$fail(peg$e81);
20050
+ peg$fail(peg$e82);
19883
20051
  }
19884
20052
  }
19885
20053
  if (s0 === peg$FAILED) {
19886
- if (input.substr(peg$currPos, 15) === peg$c78) {
19887
- s0 = peg$c78;
19888
- peg$currPos += 15;
20054
+ if (input.substr(peg$currPos, 14) === peg$c79) {
20055
+ s0 = peg$c79;
20056
+ peg$currPos += 14;
19889
20057
  } else {
19890
20058
  s0 = peg$FAILED;
19891
20059
  if (peg$silentFails === 0) {
19892
- peg$fail(peg$e82);
20060
+ peg$fail(peg$e83);
19893
20061
  }
19894
20062
  }
19895
20063
  if (s0 === peg$FAILED) {
19896
- if (input.substr(peg$currPos, 6) === peg$c79) {
19897
- s0 = peg$c79;
19898
- peg$currPos += 6;
20064
+ if (input.substr(peg$currPos, 14) === peg$c80) {
20065
+ s0 = peg$c80;
20066
+ peg$currPos += 14;
19899
20067
  } else {
19900
20068
  s0 = peg$FAILED;
19901
20069
  if (peg$silentFails === 0) {
19902
- peg$fail(peg$e83);
20070
+ peg$fail(peg$e84);
19903
20071
  }
19904
20072
  }
19905
20073
  if (s0 === peg$FAILED) {
19906
- if (input.substr(peg$currPos, 13) === peg$c80) {
19907
- s0 = peg$c80;
20074
+ if (input.substr(peg$currPos, 13) === peg$c81) {
20075
+ s0 = peg$c81;
19908
20076
  peg$currPos += 13;
19909
20077
  } else {
19910
20078
  s0 = peg$FAILED;
19911
20079
  if (peg$silentFails === 0) {
19912
- peg$fail(peg$e84);
20080
+ peg$fail(peg$e85);
19913
20081
  }
19914
20082
  }
19915
20083
  if (s0 === peg$FAILED) {
19916
- if (input.substr(peg$currPos, 16) === peg$c81) {
19917
- s0 = peg$c81;
19918
- peg$currPos += 16;
20084
+ if (input.substr(peg$currPos, 9) === peg$c82) {
20085
+ s0 = peg$c82;
20086
+ peg$currPos += 9;
19919
20087
  } else {
19920
20088
  s0 = peg$FAILED;
19921
20089
  if (peg$silentFails === 0) {
19922
- peg$fail(peg$e85);
20090
+ peg$fail(peg$e86);
19923
20091
  }
19924
20092
  }
19925
20093
  if (s0 === peg$FAILED) {
19926
- if (input.substr(peg$currPos, 16) === peg$c82) {
19927
- s0 = peg$c82;
19928
- peg$currPos += 16;
20094
+ if (input.substr(peg$currPos, 6) === peg$c83) {
20095
+ s0 = peg$c83;
20096
+ peg$currPos += 6;
19929
20097
  } else {
19930
20098
  s0 = peg$FAILED;
19931
20099
  if (peg$silentFails === 0) {
19932
- peg$fail(peg$e86);
20100
+ peg$fail(peg$e87);
19933
20101
  }
19934
20102
  }
19935
20103
  if (s0 === peg$FAILED) {
19936
- if (input.substr(peg$currPos, 15) === peg$c83) {
19937
- s0 = peg$c83;
19938
- peg$currPos += 15;
20104
+ if (input.substr(peg$currPos, 9) === peg$c84) {
20105
+ s0 = peg$c84;
20106
+ peg$currPos += 9;
19939
20107
  } else {
19940
20108
  s0 = peg$FAILED;
19941
20109
  if (peg$silentFails === 0) {
19942
- peg$fail(peg$e87);
20110
+ peg$fail(peg$e88);
19943
20111
  }
19944
20112
  }
19945
20113
  if (s0 === peg$FAILED) {
19946
- if (input.substr(peg$currPos, 14) === peg$c84) {
19947
- s0 = peg$c84;
19948
- peg$currPos += 14;
20114
+ if (input.substr(peg$currPos, 11) === peg$c85) {
20115
+ s0 = peg$c85;
20116
+ peg$currPos += 11;
19949
20117
  } else {
19950
20118
  s0 = peg$FAILED;
19951
20119
  if (peg$silentFails === 0) {
19952
- peg$fail(peg$e88);
20120
+ peg$fail(peg$e89);
19953
20121
  }
19954
20122
  }
19955
20123
  if (s0 === peg$FAILED) {
19956
- if (input.substr(peg$currPos, 16) === peg$c85) {
19957
- s0 = peg$c85;
19958
- peg$currPos += 16;
20124
+ if (input.substr(peg$currPos, 3) === peg$c86) {
20125
+ s0 = peg$c86;
20126
+ peg$currPos += 3;
19959
20127
  } else {
19960
20128
  s0 = peg$FAILED;
19961
20129
  if (peg$silentFails === 0) {
19962
- peg$fail(peg$e89);
20130
+ peg$fail(peg$e90);
19963
20131
  }
19964
20132
  }
19965
20133
  if (s0 === peg$FAILED) {
19966
- if (input.substr(peg$currPos, 14) === peg$c86) {
19967
- s0 = peg$c86;
19968
- peg$currPos += 14;
20134
+ if (input.substr(peg$currPos, 3) === peg$c87) {
20135
+ s0 = peg$c87;
20136
+ peg$currPos += 3;
19969
20137
  } else {
19970
20138
  s0 = peg$FAILED;
19971
20139
  if (peg$silentFails === 0) {
19972
- peg$fail(peg$e90);
20140
+ peg$fail(peg$e91);
19973
20141
  }
19974
20142
  }
19975
20143
  if (s0 === peg$FAILED) {
19976
- if (input.substr(peg$currPos, 15) === peg$c87) {
19977
- s0 = peg$c87;
19978
- peg$currPos += 15;
20144
+ if (input.substr(peg$currPos, 9) === peg$c88) {
20145
+ s0 = peg$c88;
20146
+ peg$currPos += 9;
19979
20147
  } else {
19980
20148
  s0 = peg$FAILED;
19981
20149
  if (peg$silentFails === 0) {
19982
- peg$fail(peg$e91);
20150
+ peg$fail(peg$e92);
19983
20151
  }
19984
20152
  }
19985
20153
  if (s0 === peg$FAILED) {
19986
- if (input.substr(peg$currPos, 15) === peg$c88) {
19987
- s0 = peg$c88;
20154
+ if (input.substr(peg$currPos, 15) === peg$c89) {
20155
+ s0 = peg$c89;
19988
20156
  peg$currPos += 15;
19989
20157
  } else {
19990
20158
  s0 = peg$FAILED;
19991
20159
  if (peg$silentFails === 0) {
19992
- peg$fail(peg$e92);
20160
+ peg$fail(peg$e93);
19993
20161
  }
19994
20162
  }
19995
20163
  if (s0 === peg$FAILED) {
19996
- if (input.substr(peg$currPos, 15) === peg$c89) {
19997
- s0 = peg$c89;
19998
- peg$currPos += 15;
20164
+ if (input.substr(peg$currPos, 6) === peg$c90) {
20165
+ s0 = peg$c90;
20166
+ peg$currPos += 6;
19999
20167
  } else {
20000
20168
  s0 = peg$FAILED;
20001
20169
  if (peg$silentFails === 0) {
20002
- peg$fail(peg$e93);
20170
+ peg$fail(peg$e94);
20003
20171
  }
20004
20172
  }
20005
20173
  if (s0 === peg$FAILED) {
20006
- if (input.substr(peg$currPos, 14) === peg$c90) {
20007
- s0 = peg$c90;
20008
- peg$currPos += 14;
20174
+ if (input.substr(peg$currPos, 13) === peg$c91) {
20175
+ s0 = peg$c91;
20176
+ peg$currPos += 13;
20009
20177
  } else {
20010
20178
  s0 = peg$FAILED;
20011
20179
  if (peg$silentFails === 0) {
20012
- peg$fail(peg$e94);
20180
+ peg$fail(peg$e95);
20013
20181
  }
20014
20182
  }
20015
20183
  if (s0 === peg$FAILED) {
20016
- if (input.substr(peg$currPos, 10) === peg$c91) {
20017
- s0 = peg$c91;
20018
- peg$currPos += 10;
20184
+ if (input.substr(peg$currPos, 16) === peg$c92) {
20185
+ s0 = peg$c92;
20186
+ peg$currPos += 16;
20019
20187
  } else {
20020
20188
  s0 = peg$FAILED;
20021
20189
  if (peg$silentFails === 0) {
20022
- peg$fail(peg$e95);
20190
+ peg$fail(peg$e96);
20023
20191
  }
20024
20192
  }
20025
20193
  if (s0 === peg$FAILED) {
20026
- if (input.substr(peg$currPos, 13) === peg$c92) {
20027
- s0 = peg$c92;
20028
- peg$currPos += 13;
20194
+ if (input.substr(peg$currPos, 16) === peg$c93) {
20195
+ s0 = peg$c93;
20196
+ peg$currPos += 16;
20029
20197
  } else {
20030
20198
  s0 = peg$FAILED;
20031
20199
  if (peg$silentFails === 0) {
20032
- peg$fail(peg$e96);
20200
+ peg$fail(peg$e97);
20033
20201
  }
20034
20202
  }
20035
20203
  if (s0 === peg$FAILED) {
20036
- if (input.substr(peg$currPos, 19) === peg$c93) {
20037
- s0 = peg$c93;
20038
- peg$currPos += 19;
20204
+ if (input.substr(peg$currPos, 15) === peg$c94) {
20205
+ s0 = peg$c94;
20206
+ peg$currPos += 15;
20039
20207
  } else {
20040
20208
  s0 = peg$FAILED;
20041
20209
  if (peg$silentFails === 0) {
20042
- peg$fail(peg$e97);
20210
+ peg$fail(peg$e98);
20043
20211
  }
20044
20212
  }
20045
20213
  if (s0 === peg$FAILED) {
20046
- if (input.substr(peg$currPos, 10) === peg$c94) {
20047
- s0 = peg$c94;
20048
- peg$currPos += 10;
20214
+ if (input.substr(peg$currPos, 14) === peg$c95) {
20215
+ s0 = peg$c95;
20216
+ peg$currPos += 14;
20049
20217
  } else {
20050
20218
  s0 = peg$FAILED;
20051
20219
  if (peg$silentFails === 0) {
20052
- peg$fail(peg$e98);
20220
+ peg$fail(peg$e99);
20053
20221
  }
20054
20222
  }
20055
20223
  if (s0 === peg$FAILED) {
20056
- if (input.substr(peg$currPos, 10) === peg$c95) {
20057
- s0 = peg$c95;
20058
- peg$currPos += 10;
20224
+ if (input.substr(peg$currPos, 16) === peg$c96) {
20225
+ s0 = peg$c96;
20226
+ peg$currPos += 16;
20059
20227
  } else {
20060
20228
  s0 = peg$FAILED;
20061
20229
  if (peg$silentFails === 0) {
20062
- peg$fail(peg$e99);
20230
+ peg$fail(peg$e100);
20063
20231
  }
20064
20232
  }
20065
20233
  if (s0 === peg$FAILED) {
20066
- if (input.substr(peg$currPos, 13) === peg$c96) {
20067
- s0 = peg$c96;
20068
- peg$currPos += 13;
20234
+ if (input.substr(peg$currPos, 14) === peg$c97) {
20235
+ s0 = peg$c97;
20236
+ peg$currPos += 14;
20069
20237
  } else {
20070
20238
  s0 = peg$FAILED;
20071
20239
  if (peg$silentFails === 0) {
20072
- peg$fail(peg$e100);
20240
+ peg$fail(peg$e101);
20073
20241
  }
20074
20242
  }
20075
20243
  if (s0 === peg$FAILED) {
20076
- if (input.substr(peg$currPos, 11) === peg$c97) {
20077
- s0 = peg$c97;
20078
- peg$currPos += 11;
20244
+ if (input.substr(peg$currPos, 15) === peg$c98) {
20245
+ s0 = peg$c98;
20246
+ peg$currPos += 15;
20079
20247
  } else {
20080
20248
  s0 = peg$FAILED;
20081
20249
  if (peg$silentFails === 0) {
20082
- peg$fail(peg$e101);
20250
+ peg$fail(peg$e102);
20251
+ }
20252
+ }
20253
+ if (s0 === peg$FAILED) {
20254
+ if (input.substr(peg$currPos, 15) === peg$c99) {
20255
+ s0 = peg$c99;
20256
+ peg$currPos += 15;
20257
+ } else {
20258
+ s0 = peg$FAILED;
20259
+ if (peg$silentFails === 0) {
20260
+ peg$fail(peg$e103);
20261
+ }
20262
+ }
20263
+ if (s0 === peg$FAILED) {
20264
+ if (input.substr(peg$currPos, 15) === peg$c100) {
20265
+ s0 = peg$c100;
20266
+ peg$currPos += 15;
20267
+ } else {
20268
+ s0 = peg$FAILED;
20269
+ if (peg$silentFails === 0) {
20270
+ peg$fail(peg$e104);
20271
+ }
20272
+ }
20273
+ if (s0 === peg$FAILED) {
20274
+ if (input.substr(peg$currPos, 14) === peg$c101) {
20275
+ s0 = peg$c101;
20276
+ peg$currPos += 14;
20277
+ } else {
20278
+ s0 = peg$FAILED;
20279
+ if (peg$silentFails === 0) {
20280
+ peg$fail(peg$e105);
20281
+ }
20282
+ }
20283
+ if (s0 === peg$FAILED) {
20284
+ if (input.substr(peg$currPos, 10) === peg$c102) {
20285
+ s0 = peg$c102;
20286
+ peg$currPos += 10;
20287
+ } else {
20288
+ s0 = peg$FAILED;
20289
+ if (peg$silentFails === 0) {
20290
+ peg$fail(peg$e106);
20291
+ }
20292
+ }
20293
+ if (s0 === peg$FAILED) {
20294
+ if (input.substr(peg$currPos, 13) === peg$c103) {
20295
+ s0 = peg$c103;
20296
+ peg$currPos += 13;
20297
+ } else {
20298
+ s0 = peg$FAILED;
20299
+ if (peg$silentFails === 0) {
20300
+ peg$fail(peg$e107);
20301
+ }
20302
+ }
20303
+ if (s0 === peg$FAILED) {
20304
+ if (input.substr(peg$currPos, 19) === peg$c104) {
20305
+ s0 = peg$c104;
20306
+ peg$currPos += 19;
20307
+ } else {
20308
+ s0 = peg$FAILED;
20309
+ if (peg$silentFails === 0) {
20310
+ peg$fail(peg$e108);
20311
+ }
20312
+ }
20313
+ if (s0 === peg$FAILED) {
20314
+ if (input.substr(peg$currPos, 10) === peg$c105) {
20315
+ s0 = peg$c105;
20316
+ peg$currPos += 10;
20317
+ } else {
20318
+ s0 = peg$FAILED;
20319
+ if (peg$silentFails === 0) {
20320
+ peg$fail(peg$e109);
20321
+ }
20322
+ }
20323
+ if (s0 === peg$FAILED) {
20324
+ if (input.substr(peg$currPos, 10) === peg$c106) {
20325
+ s0 = peg$c106;
20326
+ peg$currPos += 10;
20327
+ } else {
20328
+ s0 = peg$FAILED;
20329
+ if (peg$silentFails === 0) {
20330
+ peg$fail(peg$e110);
20331
+ }
20332
+ }
20333
+ if (s0 === peg$FAILED) {
20334
+ if (input.substr(peg$currPos, 13) === peg$c107) {
20335
+ s0 = peg$c107;
20336
+ peg$currPos += 13;
20337
+ } else {
20338
+ s0 = peg$FAILED;
20339
+ if (peg$silentFails === 0) {
20340
+ peg$fail(peg$e111);
20341
+ }
20342
+ }
20343
+ if (s0 === peg$FAILED) {
20344
+ if (input.substr(peg$currPos, 11) === peg$c108) {
20345
+ s0 = peg$c108;
20346
+ peg$currPos += 11;
20347
+ } else {
20348
+ s0 = peg$FAILED;
20349
+ if (peg$silentFails === 0) {
20350
+ peg$fail(peg$e112);
20351
+ }
20352
+ }
20353
+ }
20354
+ }
20355
+ }
20356
+ }
20357
+ }
20358
+ }
20359
+ }
20360
+ }
20083
20361
  }
20084
20362
  }
20085
20363
  }
@@ -20115,233 +20393,233 @@ function peg$parse(input, options) {
20115
20393
  }
20116
20394
  function peg$parseColor() {
20117
20395
  let s0;
20118
- if (input.substr(peg$currPos, 4) === peg$c98) {
20119
- s0 = peg$c98;
20396
+ if (input.substr(peg$currPos, 4) === peg$c109) {
20397
+ s0 = peg$c109;
20120
20398
  peg$currPos += 4;
20121
20399
  } else {
20122
20400
  s0 = peg$FAILED;
20123
20401
  if (peg$silentFails === 0) {
20124
- peg$fail(peg$e102);
20402
+ peg$fail(peg$e113);
20125
20403
  }
20126
20404
  }
20127
20405
  if (s0 === peg$FAILED) {
20128
- if (input.substr(peg$currPos, 5) === peg$c99) {
20129
- s0 = peg$c99;
20406
+ if (input.substr(peg$currPos, 5) === peg$c110) {
20407
+ s0 = peg$c110;
20130
20408
  peg$currPos += 5;
20131
20409
  } else {
20132
20410
  s0 = peg$FAILED;
20133
20411
  if (peg$silentFails === 0) {
20134
- peg$fail(peg$e103);
20412
+ peg$fail(peg$e114);
20135
20413
  }
20136
20414
  }
20137
20415
  if (s0 === peg$FAILED) {
20138
- if (input.substr(peg$currPos, 4) === peg$c100) {
20139
- s0 = peg$c100;
20416
+ if (input.substr(peg$currPos, 4) === peg$c111) {
20417
+ s0 = peg$c111;
20140
20418
  peg$currPos += 4;
20141
20419
  } else {
20142
20420
  s0 = peg$FAILED;
20143
20421
  if (peg$silentFails === 0) {
20144
- peg$fail(peg$e104);
20422
+ peg$fail(peg$e115);
20145
20423
  }
20146
20424
  }
20147
20425
  if (s0 === peg$FAILED) {
20148
- if (input.substr(peg$currPos, 5) === peg$c101) {
20149
- s0 = peg$c101;
20426
+ if (input.substr(peg$currPos, 5) === peg$c112) {
20427
+ s0 = peg$c112;
20150
20428
  peg$currPos += 5;
20151
20429
  } else {
20152
20430
  s0 = peg$FAILED;
20153
20431
  if (peg$silentFails === 0) {
20154
- peg$fail(peg$e105);
20432
+ peg$fail(peg$e116);
20155
20433
  }
20156
20434
  }
20157
20435
  if (s0 === peg$FAILED) {
20158
- if (input.substr(peg$currPos, 7) === peg$c102) {
20159
- s0 = peg$c102;
20436
+ if (input.substr(peg$currPos, 7) === peg$c113) {
20437
+ s0 = peg$c113;
20160
20438
  peg$currPos += 7;
20161
20439
  } else {
20162
20440
  s0 = peg$FAILED;
20163
20441
  if (peg$silentFails === 0) {
20164
- peg$fail(peg$e106);
20442
+ peg$fail(peg$e117);
20165
20443
  }
20166
20444
  }
20167
20445
  if (s0 === peg$FAILED) {
20168
- if (input.substr(peg$currPos, 9) === peg$c103) {
20169
- s0 = peg$c103;
20446
+ if (input.substr(peg$currPos, 9) === peg$c114) {
20447
+ s0 = peg$c114;
20170
20448
  peg$currPos += 9;
20171
20449
  } else {
20172
20450
  s0 = peg$FAILED;
20173
20451
  if (peg$silentFails === 0) {
20174
- peg$fail(peg$e107);
20452
+ peg$fail(peg$e118);
20175
20453
  }
20176
20454
  }
20177
20455
  if (s0 === peg$FAILED) {
20178
- if (input.substr(peg$currPos, 4) === peg$c104) {
20179
- s0 = peg$c104;
20456
+ if (input.substr(peg$currPos, 4) === peg$c115) {
20457
+ s0 = peg$c115;
20180
20458
  peg$currPos += 4;
20181
20459
  } else {
20182
20460
  s0 = peg$FAILED;
20183
20461
  if (peg$silentFails === 0) {
20184
- peg$fail(peg$e108);
20462
+ peg$fail(peg$e119);
20185
20463
  }
20186
20464
  }
20187
20465
  if (s0 === peg$FAILED) {
20188
- if (input.substr(peg$currPos, 8) === peg$c105) {
20189
- s0 = peg$c105;
20466
+ if (input.substr(peg$currPos, 8) === peg$c116) {
20467
+ s0 = peg$c116;
20190
20468
  peg$currPos += 8;
20191
20469
  } else {
20192
20470
  s0 = peg$FAILED;
20193
20471
  if (peg$silentFails === 0) {
20194
- peg$fail(peg$e109);
20472
+ peg$fail(peg$e120);
20195
20473
  }
20196
20474
  }
20197
20475
  if (s0 === peg$FAILED) {
20198
- if (input.substr(peg$currPos, 5) === peg$c106) {
20199
- s0 = peg$c106;
20476
+ if (input.substr(peg$currPos, 5) === peg$c117) {
20477
+ s0 = peg$c117;
20200
20478
  peg$currPos += 5;
20201
20479
  } else {
20202
20480
  s0 = peg$FAILED;
20203
20481
  if (peg$silentFails === 0) {
20204
- peg$fail(peg$e110);
20482
+ peg$fail(peg$e121);
20205
20483
  }
20206
20484
  }
20207
20485
  if (s0 === peg$FAILED) {
20208
- if (input.substr(peg$currPos, 4) === peg$c107) {
20209
- s0 = peg$c107;
20486
+ if (input.substr(peg$currPos, 4) === peg$c118) {
20487
+ s0 = peg$c118;
20210
20488
  peg$currPos += 4;
20211
20489
  } else {
20212
20490
  s0 = peg$FAILED;
20213
20491
  if (peg$silentFails === 0) {
20214
- peg$fail(peg$e111);
20492
+ peg$fail(peg$e122);
20215
20493
  }
20216
20494
  }
20217
20495
  if (s0 === peg$FAILED) {
20218
- if (input.substr(peg$currPos, 7) === peg$c108) {
20219
- s0 = peg$c108;
20496
+ if (input.substr(peg$currPos, 7) === peg$c119) {
20497
+ s0 = peg$c119;
20220
20498
  peg$currPos += 7;
20221
20499
  } else {
20222
20500
  s0 = peg$FAILED;
20223
20501
  if (peg$silentFails === 0) {
20224
- peg$fail(peg$e112);
20502
+ peg$fail(peg$e123);
20225
20503
  }
20226
20504
  }
20227
20505
  if (s0 === peg$FAILED) {
20228
- if (input.substr(peg$currPos, 6) === peg$c109) {
20229
- s0 = peg$c109;
20506
+ if (input.substr(peg$currPos, 6) === peg$c120) {
20507
+ s0 = peg$c120;
20230
20508
  peg$currPos += 6;
20231
20509
  } else {
20232
20510
  s0 = peg$FAILED;
20233
20511
  if (peg$silentFails === 0) {
20234
- peg$fail(peg$e113);
20512
+ peg$fail(peg$e124);
20235
20513
  }
20236
20514
  }
20237
20515
  if (s0 === peg$FAILED) {
20238
- if (input.substr(peg$currPos, 4) === peg$c110) {
20239
- s0 = peg$c110;
20516
+ if (input.substr(peg$currPos, 4) === peg$c121) {
20517
+ s0 = peg$c121;
20240
20518
  peg$currPos += 4;
20241
20519
  } else {
20242
20520
  s0 = peg$FAILED;
20243
20521
  if (peg$silentFails === 0) {
20244
- peg$fail(peg$e114);
20522
+ peg$fail(peg$e125);
20245
20523
  }
20246
20524
  }
20247
20525
  if (s0 === peg$FAILED) {
20248
- if (input.substr(peg$currPos, 5) === peg$c111) {
20249
- s0 = peg$c111;
20526
+ if (input.substr(peg$currPos, 5) === peg$c122) {
20527
+ s0 = peg$c122;
20250
20528
  peg$currPos += 5;
20251
20529
  } else {
20252
20530
  s0 = peg$FAILED;
20253
20531
  if (peg$silentFails === 0) {
20254
- peg$fail(peg$e115);
20532
+ peg$fail(peg$e126);
20255
20533
  }
20256
20534
  }
20257
20535
  if (s0 === peg$FAILED) {
20258
- if (input.substr(peg$currPos, 6) === peg$c112) {
20259
- s0 = peg$c112;
20536
+ if (input.substr(peg$currPos, 6) === peg$c123) {
20537
+ s0 = peg$c123;
20260
20538
  peg$currPos += 6;
20261
20539
  } else {
20262
20540
  s0 = peg$FAILED;
20263
20541
  if (peg$silentFails === 0) {
20264
- peg$fail(peg$e116);
20542
+ peg$fail(peg$e127);
20265
20543
  }
20266
20544
  }
20267
20545
  if (s0 === peg$FAILED) {
20268
- if (input.substr(peg$currPos, 4) === peg$c113) {
20269
- s0 = peg$c113;
20546
+ if (input.substr(peg$currPos, 4) === peg$c124) {
20547
+ s0 = peg$c124;
20270
20548
  peg$currPos += 4;
20271
20549
  } else {
20272
20550
  s0 = peg$FAILED;
20273
20551
  if (peg$silentFails === 0) {
20274
- peg$fail(peg$e117);
20552
+ peg$fail(peg$e128);
20275
20553
  }
20276
20554
  }
20277
20555
  if (s0 === peg$FAILED) {
20278
- if (input.substr(peg$currPos, 6) === peg$c114) {
20279
- s0 = peg$c114;
20556
+ if (input.substr(peg$currPos, 6) === peg$c125) {
20557
+ s0 = peg$c125;
20280
20558
  peg$currPos += 6;
20281
20559
  } else {
20282
20560
  s0 = peg$FAILED;
20283
20561
  if (peg$silentFails === 0) {
20284
- peg$fail(peg$e118);
20562
+ peg$fail(peg$e129);
20285
20563
  }
20286
20564
  }
20287
20565
  if (s0 === peg$FAILED) {
20288
- if (input.substr(peg$currPos, 3) === peg$c115) {
20289
- s0 = peg$c115;
20566
+ if (input.substr(peg$currPos, 3) === peg$c126) {
20567
+ s0 = peg$c126;
20290
20568
  peg$currPos += 3;
20291
20569
  } else {
20292
20570
  s0 = peg$FAILED;
20293
20571
  if (peg$silentFails === 0) {
20294
- peg$fail(peg$e119);
20572
+ peg$fail(peg$e130);
20295
20573
  }
20296
20574
  }
20297
20575
  if (s0 === peg$FAILED) {
20298
- if (input.substr(peg$currPos, 6) === peg$c116) {
20299
- s0 = peg$c116;
20576
+ if (input.substr(peg$currPos, 6) === peg$c127) {
20577
+ s0 = peg$c127;
20300
20578
  peg$currPos += 6;
20301
20579
  } else {
20302
20580
  s0 = peg$FAILED;
20303
20581
  if (peg$silentFails === 0) {
20304
- peg$fail(peg$e120);
20582
+ peg$fail(peg$e131);
20305
20583
  }
20306
20584
  }
20307
20585
  if (s0 === peg$FAILED) {
20308
- if (input.substr(peg$currPos, 4) === peg$c117) {
20309
- s0 = peg$c117;
20586
+ if (input.substr(peg$currPos, 4) === peg$c128) {
20587
+ s0 = peg$c128;
20310
20588
  peg$currPos += 4;
20311
20589
  } else {
20312
20590
  s0 = peg$FAILED;
20313
20591
  if (peg$silentFails === 0) {
20314
- peg$fail(peg$e121);
20592
+ peg$fail(peg$e132);
20315
20593
  }
20316
20594
  }
20317
20595
  if (s0 === peg$FAILED) {
20318
- if (input.substr(peg$currPos, 6) === peg$c118) {
20319
- s0 = peg$c118;
20596
+ if (input.substr(peg$currPos, 6) === peg$c129) {
20597
+ s0 = peg$c129;
20320
20598
  peg$currPos += 6;
20321
20599
  } else {
20322
20600
  s0 = peg$FAILED;
20323
20601
  if (peg$silentFails === 0) {
20324
- peg$fail(peg$e122);
20602
+ peg$fail(peg$e133);
20325
20603
  }
20326
20604
  }
20327
20605
  if (s0 === peg$FAILED) {
20328
- if (input.substr(peg$currPos, 5) === peg$c119) {
20329
- s0 = peg$c119;
20606
+ if (input.substr(peg$currPos, 5) === peg$c130) {
20607
+ s0 = peg$c130;
20330
20608
  peg$currPos += 5;
20331
20609
  } else {
20332
20610
  s0 = peg$FAILED;
20333
20611
  if (peg$silentFails === 0) {
20334
- peg$fail(peg$e123);
20612
+ peg$fail(peg$e134);
20335
20613
  }
20336
20614
  }
20337
20615
  if (s0 === peg$FAILED) {
20338
- if (input.substr(peg$currPos, 6) === peg$c120) {
20339
- s0 = peg$c120;
20616
+ if (input.substr(peg$currPos, 6) === peg$c131) {
20617
+ s0 = peg$c131;
20340
20618
  peg$currPos += 6;
20341
20619
  } else {
20342
20620
  s0 = peg$FAILED;
20343
20621
  if (peg$silentFails === 0) {
20344
- peg$fail(peg$e124);
20622
+ peg$fail(peg$e135);
20345
20623
  }
20346
20624
  }
20347
20625
  }
@@ -20373,7 +20651,7 @@ function peg$parse(input, options) {
20373
20651
  peg$silentFails++;
20374
20652
  s0 = peg$currPos;
20375
20653
  s1 = peg$parsebitmarkMinusMinusString();
20376
- s1 = peg$f90(s1);
20654
+ s1 = peg$f91(s1);
20377
20655
  s0 = s1;
20378
20656
  peg$silentFails--;
20379
20657
  return s0;
@@ -20398,7 +20676,7 @@ function peg$parse(input, options) {
20398
20676
  s3 = peg$parsePlainText();
20399
20677
  }
20400
20678
  }
20401
- s0 = peg$f91(s1, s2);
20679
+ s0 = peg$f92(s1, s2);
20402
20680
  peg$silentFails--;
20403
20681
  return s0;
20404
20682
  }
@@ -20407,7 +20685,7 @@ function peg$parse(input, options) {
20407
20685
  s0 = peg$currPos;
20408
20686
  s1 = peg$parseNL();
20409
20687
  if (s1 !== peg$FAILED) {
20410
- s1 = peg$f92();
20688
+ s1 = peg$f93();
20411
20689
  }
20412
20690
  s0 = s1;
20413
20691
  if (s0 === peg$FAILED) {
@@ -20535,7 +20813,7 @@ function peg$parse(input, options) {
20535
20813
  s1 = s2;
20536
20814
  }
20537
20815
  if (s1 !== peg$FAILED) {
20538
- s1 = peg$f93(s1);
20816
+ s1 = peg$f94(s1);
20539
20817
  }
20540
20818
  s0 = s1;
20541
20819
  }
@@ -20544,12 +20822,12 @@ function peg$parse(input, options) {
20544
20822
  function peg$parseBoldHalfTag() {
20545
20823
  let s0;
20546
20824
  if (input.charCodeAt(peg$currPos) === 42) {
20547
- s0 = peg$c121;
20825
+ s0 = peg$c132;
20548
20826
  peg$currPos++;
20549
20827
  } else {
20550
20828
  s0 = peg$FAILED;
20551
20829
  if (peg$silentFails === 0) {
20552
- peg$fail(peg$e125);
20830
+ peg$fail(peg$e136);
20553
20831
  }
20554
20832
  }
20555
20833
  return s0;
@@ -20557,12 +20835,12 @@ function peg$parse(input, options) {
20557
20835
  function peg$parseItalicHalfTag() {
20558
20836
  let s0;
20559
20837
  if (input.charCodeAt(peg$currPos) === 95) {
20560
- s0 = peg$c122;
20838
+ s0 = peg$c133;
20561
20839
  peg$currPos++;
20562
20840
  } else {
20563
20841
  s0 = peg$FAILED;
20564
20842
  if (peg$silentFails === 0) {
20565
- peg$fail(peg$e126);
20843
+ peg$fail(peg$e137);
20566
20844
  }
20567
20845
  }
20568
20846
  return s0;
@@ -20570,12 +20848,12 @@ function peg$parse(input, options) {
20570
20848
  function peg$parseLightHalfTag() {
20571
20849
  let s0;
20572
20850
  if (input.charCodeAt(peg$currPos) === 96) {
20573
- s0 = peg$c123;
20851
+ s0 = peg$c134;
20574
20852
  peg$currPos++;
20575
20853
  } else {
20576
20854
  s0 = peg$FAILED;
20577
20855
  if (peg$silentFails === 0) {
20578
- peg$fail(peg$e127);
20856
+ peg$fail(peg$e138);
20579
20857
  }
20580
20858
  }
20581
20859
  return s0;
@@ -20583,12 +20861,12 @@ function peg$parse(input, options) {
20583
20861
  function peg$parseHighlightHalfTag() {
20584
20862
  let s0;
20585
20863
  if (input.charCodeAt(peg$currPos) === 33) {
20586
- s0 = peg$c124;
20864
+ s0 = peg$c135;
20587
20865
  peg$currPos++;
20588
20866
  } else {
20589
20867
  s0 = peg$FAILED;
20590
20868
  if (peg$silentFails === 0) {
20591
- peg$fail(peg$e128);
20869
+ peg$fail(peg$e139);
20592
20870
  }
20593
20871
  }
20594
20872
  return s0;
@@ -20671,13 +20949,13 @@ function peg$parse(input, options) {
20671
20949
  }
20672
20950
  function peg$parseBodyBitOpenTag() {
20673
20951
  let s0;
20674
- if (input.substr(peg$currPos, 2) === peg$c125) {
20675
- s0 = peg$c125;
20952
+ if (input.substr(peg$currPos, 2) === peg$c136) {
20953
+ s0 = peg$c136;
20676
20954
  peg$currPos += 2;
20677
20955
  } else {
20678
20956
  s0 = peg$FAILED;
20679
20957
  if (peg$silentFails === 0) {
20680
- peg$fail(peg$e129);
20958
+ peg$fail(peg$e140);
20681
20959
  }
20682
20960
  }
20683
20961
  return s0;
@@ -20685,12 +20963,12 @@ function peg$parse(input, options) {
20685
20963
  function peg$parseBodyBitCloseTag() {
20686
20964
  let s0;
20687
20965
  if (input.charCodeAt(peg$currPos) === 93) {
20688
- s0 = peg$c126;
20966
+ s0 = peg$c137;
20689
20967
  peg$currPos++;
20690
20968
  } else {
20691
20969
  s0 = peg$FAILED;
20692
20970
  if (peg$silentFails === 0) {
20693
- peg$fail(peg$e130);
20971
+ peg$fail(peg$e141);
20694
20972
  }
20695
20973
  }
20696
20974
  return s0;
@@ -20735,7 +21013,7 @@ function peg$parse(input, options) {
20735
21013
  if (s2 !== peg$FAILED) {
20736
21014
  s3 = peg$parseBodyBitCloseTag();
20737
21015
  if (s3 !== peg$FAILED) {
20738
- s0 = peg$f94(s2);
21016
+ s0 = peg$f95(s2);
20739
21017
  } else {
20740
21018
  peg$currPos = s0;
20741
21019
  s0 = peg$FAILED;
@@ -20824,7 +21102,7 @@ function peg$parse(input, options) {
20824
21102
  s2 = input.substring(s2, peg$currPos);
20825
21103
  s3 = peg$parseBoldTag();
20826
21104
  if (s3 !== peg$FAILED) {
20827
- s0 = peg$f95(s2);
21105
+ s0 = peg$f96(s2);
20828
21106
  } else {
20829
21107
  peg$currPos = s0;
20830
21108
  s0 = peg$FAILED;
@@ -20909,7 +21187,7 @@ function peg$parse(input, options) {
20909
21187
  s2 = input.substring(s2, peg$currPos);
20910
21188
  s3 = peg$parseItalicTag();
20911
21189
  if (s3 !== peg$FAILED) {
20912
- s0 = peg$f96(s2);
21190
+ s0 = peg$f97(s2);
20913
21191
  } else {
20914
21192
  peg$currPos = s0;
20915
21193
  s0 = peg$FAILED;
@@ -20994,7 +21272,7 @@ function peg$parse(input, options) {
20994
21272
  s2 = input.substring(s2, peg$currPos);
20995
21273
  s3 = peg$parseLightTag();
20996
21274
  if (s3 !== peg$FAILED) {
20997
- s0 = peg$f97(s2);
21275
+ s0 = peg$f98(s2);
20998
21276
  } else {
20999
21277
  peg$currPos = s0;
21000
21278
  s0 = peg$FAILED;
@@ -21079,7 +21357,7 @@ function peg$parse(input, options) {
21079
21357
  s2 = input.substring(s2, peg$currPos);
21080
21358
  s3 = peg$parseHighlightTag();
21081
21359
  if (s3 !== peg$FAILED) {
21082
- s0 = peg$f98(s2);
21360
+ s0 = peg$f99(s2);
21083
21361
  } else {
21084
21362
  peg$currPos = s0;
21085
21363
  s0 = peg$FAILED;
@@ -21164,22 +21442,22 @@ function peg$parse(input, options) {
21164
21442
  let s0;
21165
21443
  peg$silentFails++;
21166
21444
  if (input.charCodeAt(peg$currPos) === 10) {
21167
- s0 = peg$c127;
21445
+ s0 = peg$c138;
21168
21446
  peg$currPos++;
21169
21447
  } else {
21170
21448
  s0 = peg$FAILED;
21171
21449
  if (peg$silentFails === 0) {
21172
- peg$fail(peg$e132);
21450
+ peg$fail(peg$e143);
21173
21451
  }
21174
21452
  }
21175
21453
  if (s0 === peg$FAILED) {
21176
- if (input.substr(peg$currPos, 2) === peg$c128) {
21177
- s0 = peg$c128;
21454
+ if (input.substr(peg$currPos, 2) === peg$c139) {
21455
+ s0 = peg$c139;
21178
21456
  peg$currPos += 2;
21179
21457
  } else {
21180
21458
  s0 = peg$FAILED;
21181
21459
  if (peg$silentFails === 0) {
21182
- peg$fail(peg$e133);
21460
+ peg$fail(peg$e144);
21183
21461
  }
21184
21462
  }
21185
21463
  if (s0 === peg$FAILED) {
@@ -21189,7 +21467,7 @@ function peg$parse(input, options) {
21189
21467
  } else {
21190
21468
  s0 = peg$FAILED;
21191
21469
  if (peg$silentFails === 0) {
21192
- peg$fail(peg$e134);
21470
+ peg$fail(peg$e145);
21193
21471
  }
21194
21472
  }
21195
21473
  }
@@ -21197,7 +21475,7 @@ function peg$parse(input, options) {
21197
21475
  peg$silentFails--;
21198
21476
  if (s0 === peg$FAILED) {
21199
21477
  if (peg$silentFails === 0) {
21200
- peg$fail(peg$e131);
21478
+ peg$fail(peg$e142);
21201
21479
  }
21202
21480
  }
21203
21481
  return s0;
@@ -21210,7 +21488,7 @@ function peg$parse(input, options) {
21210
21488
  } else {
21211
21489
  s0 = peg$FAILED;
21212
21490
  if (peg$silentFails === 0) {
21213
- peg$fail(peg$e135);
21491
+ peg$fail(peg$e146);
21214
21492
  }
21215
21493
  }
21216
21494
  return s0;
@@ -21244,35 +21522,35 @@ function peg$parse(input, options) {
21244
21522
  let s0, s1, s2, s3, s4, s5, s6, s7, s8;
21245
21523
  s0 = peg$currPos;
21246
21524
  s1 = peg$currPos;
21247
- if (input.substr(peg$currPos, 4) === peg$c129) {
21248
- s2 = peg$c129;
21525
+ if (input.substr(peg$currPos, 4) === peg$c140) {
21526
+ s2 = peg$c140;
21249
21527
  peg$currPos += 4;
21250
21528
  } else {
21251
21529
  s2 = peg$FAILED;
21252
21530
  if (peg$silentFails === 0) {
21253
- peg$fail(peg$e136);
21531
+ peg$fail(peg$e147);
21254
21532
  }
21255
21533
  }
21256
21534
  if (s2 !== peg$FAILED) {
21257
21535
  if (input.charCodeAt(peg$currPos) === 115) {
21258
- s3 = peg$c130;
21536
+ s3 = peg$c141;
21259
21537
  peg$currPos++;
21260
21538
  } else {
21261
21539
  s3 = peg$FAILED;
21262
21540
  if (peg$silentFails === 0) {
21263
- peg$fail(peg$e137);
21541
+ peg$fail(peg$e148);
21264
21542
  }
21265
21543
  }
21266
21544
  if (s3 === peg$FAILED) {
21267
21545
  s3 = null;
21268
21546
  }
21269
- if (input.substr(peg$currPos, 3) === peg$c131) {
21270
- s4 = peg$c131;
21547
+ if (input.substr(peg$currPos, 3) === peg$c142) {
21548
+ s4 = peg$c142;
21271
21549
  peg$currPos += 3;
21272
21550
  } else {
21273
21551
  s4 = peg$FAILED;
21274
21552
  if (peg$silentFails === 0) {
21275
- peg$fail(peg$e138);
21553
+ peg$fail(peg$e149);
21276
21554
  }
21277
21555
  }
21278
21556
  if (s4 !== peg$FAILED) {
@@ -21350,35 +21628,35 @@ function peg$parse(input, options) {
21350
21628
  s0 = peg$currPos;
21351
21629
  s1 = peg$currPos;
21352
21630
  s2 = peg$currPos;
21353
- if (input.substr(peg$currPos, 4) === peg$c129) {
21354
- s3 = peg$c129;
21631
+ if (input.substr(peg$currPos, 4) === peg$c140) {
21632
+ s3 = peg$c140;
21355
21633
  peg$currPos += 4;
21356
21634
  } else {
21357
21635
  s3 = peg$FAILED;
21358
21636
  if (peg$silentFails === 0) {
21359
- peg$fail(peg$e136);
21637
+ peg$fail(peg$e147);
21360
21638
  }
21361
21639
  }
21362
21640
  if (s3 !== peg$FAILED) {
21363
21641
  if (input.charCodeAt(peg$currPos) === 115) {
21364
- s4 = peg$c130;
21642
+ s4 = peg$c141;
21365
21643
  peg$currPos++;
21366
21644
  } else {
21367
21645
  s4 = peg$FAILED;
21368
21646
  if (peg$silentFails === 0) {
21369
- peg$fail(peg$e137);
21647
+ peg$fail(peg$e148);
21370
21648
  }
21371
21649
  }
21372
21650
  if (s4 === peg$FAILED) {
21373
21651
  s4 = null;
21374
21652
  }
21375
- if (input.substr(peg$currPos, 3) === peg$c131) {
21376
- s5 = peg$c131;
21653
+ if (input.substr(peg$currPos, 3) === peg$c142) {
21654
+ s5 = peg$c142;
21377
21655
  peg$currPos += 3;
21378
21656
  } else {
21379
21657
  s5 = peg$FAILED;
21380
21658
  if (peg$silentFails === 0) {
21381
- peg$fail(peg$e138);
21659
+ peg$fail(peg$e149);
21382
21660
  }
21383
21661
  }
21384
21662
  if (s5 !== peg$FAILED) {
@@ -21393,13 +21671,13 @@ function peg$parse(input, options) {
21393
21671
  s2 = peg$FAILED;
21394
21672
  }
21395
21673
  if (s2 === peg$FAILED) {
21396
- if (input.substr(peg$currPos, 7) === peg$c132) {
21397
- s2 = peg$c132;
21674
+ if (input.substr(peg$currPos, 7) === peg$c143) {
21675
+ s2 = peg$c143;
21398
21676
  peg$currPos += 7;
21399
21677
  } else {
21400
21678
  s2 = peg$FAILED;
21401
21679
  if (peg$silentFails === 0) {
21402
- peg$fail(peg$e139);
21680
+ peg$fail(peg$e150);
21403
21681
  }
21404
21682
  }
21405
21683
  }
@@ -21463,7 +21741,7 @@ function peg$parse(input, options) {
21463
21741
  }
21464
21742
  }
21465
21743
  s2 = input.substring(s2, peg$currPos);
21466
- s0 = peg$f99(s1, s2);
21744
+ s0 = peg$f100(s1, s2);
21467
21745
  } else {
21468
21746
  peg$currPos = s0;
21469
21747
  s0 = peg$FAILED;
@@ -21478,7 +21756,7 @@ function peg$parse(input, options) {
21478
21756
  } else {
21479
21757
  s0 = peg$FAILED;
21480
21758
  if (peg$silentFails === 0) {
21481
- peg$fail(peg$e140);
21759
+ peg$fail(peg$e151);
21482
21760
  }
21483
21761
  }
21484
21762
  return s0;
@@ -23469,6 +23747,12 @@ var Builder = class extends BaseBuilder {
23469
23747
  data.machineTranslated,
23470
23748
  options
23471
23749
  ),
23750
+ translationOf: this.toAstProperty(
23751
+ bitType,
23752
+ ConfigKey.property_translationOf,
23753
+ data.translationOf,
23754
+ options
23755
+ ),
23472
23756
  spansPageBreak: this.toAstProperty(
23473
23757
  bitType,
23474
23758
  ConfigKey.property_spansPageBreak,
@@ -24185,6 +24469,12 @@ var Builder = class extends BaseBuilder {
24185
24469
  data.hasPrintRestriction,
24186
24470
  options
24187
24471
  ),
24472
+ enforceUpdateOverUserInput: this.toAstProperty(
24473
+ bitType,
24474
+ ConfigKey.property_enforceUpdateOverUserInput,
24475
+ data.enforceUpdateOverUserInput,
24476
+ options
24477
+ ),
24188
24478
  tocResource: this.toAstProperty(
24189
24479
  bitType,
24190
24480
  ConfigKey.property_tocResource,
@@ -29860,6 +30150,7 @@ var JsonGenerator = class extends AstWalkerGenerator {
29860
30150
  if (instance2.isOfBitType(bitType, BitType.book)) {
29861
30151
  if (bitJson.maxTocChapterLevel == null) bitJson.maxTocChapterLevel = -1;
29862
30152
  if (bitJson.hasPrintRestriction == null) bitJson.hasPrintRestriction = true;
30153
+ if (bitJson.enforceUpdateOverUserInput == null) bitJson.enforceUpdateOverUserInput = false;
29863
30154
  if (bitJson.hasMarkAsDone == null) bitJson.hasMarkAsDone = false;
29864
30155
  if (bitJson.processHandIn == null) bitJson.processHandIn = false;
29865
30156
  if (bitJson.isPublic == null) bitJson.isPublic = false;