@podlite/editor-react 0.0.19 → 0.0.21

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/lib/index.cjs CHANGED
@@ -7020,6 +7020,12 @@ var require_AstTree = __commonJS({
7020
7020
  {
7021
7021
  $ref: "#/definitions/BlockCode"
7022
7022
  },
7023
+ {
7024
+ $ref: "#/definitions/BlockToc"
7025
+ },
7026
+ {
7027
+ $ref: "#/definitions/BlockMarkdown"
7028
+ },
7023
7029
  {
7024
7030
  $ref: "#/definitions/BlockNested"
7025
7031
  },
@@ -8071,6 +8077,12 @@ var require_AstTree = __commonJS({
8071
8077
  {
8072
8078
  $ref: "#/definitions/BlockCode"
8073
8079
  },
8080
+ {
8081
+ $ref: "#/definitions/BlockToc"
8082
+ },
8083
+ {
8084
+ $ref: "#/definitions/BlockMarkdown"
8085
+ },
8074
8086
  {
8075
8087
  $ref: "#/definitions/BlockNested"
8076
8088
  },
@@ -8748,6 +8760,110 @@ var require_AstTree = __commonJS({
8748
8760
  "type"
8749
8761
  ]
8750
8762
  },
8763
+ BlockToc: {
8764
+ type: "object",
8765
+ properties: {
8766
+ name: {
8767
+ type: "string",
8768
+ enum: [
8769
+ "toc"
8770
+ ]
8771
+ },
8772
+ type: {
8773
+ type: "string",
8774
+ enum: [
8775
+ "block"
8776
+ ]
8777
+ },
8778
+ location: {
8779
+ $ref: "#/definitions/Location"
8780
+ },
8781
+ content: {
8782
+ type: "array",
8783
+ items: {
8784
+ $ref: "#/definitions/PodNode"
8785
+ }
8786
+ },
8787
+ margin: {
8788
+ type: "string"
8789
+ },
8790
+ config: {
8791
+ type: "array",
8792
+ items: {
8793
+ anyOf: [
8794
+ {
8795
+ $ref: "#/definitions/BrokenConfigItem"
8796
+ },
8797
+ {
8798
+ $ref: "#/definitions/ConfigItem"
8799
+ }
8800
+ ]
8801
+ }
8802
+ },
8803
+ id: {
8804
+ type: "string"
8805
+ }
8806
+ },
8807
+ required: [
8808
+ "content",
8809
+ "location",
8810
+ "margin",
8811
+ "name",
8812
+ "type"
8813
+ ]
8814
+ },
8815
+ BlockMarkdown: {
8816
+ type: "object",
8817
+ properties: {
8818
+ name: {
8819
+ type: "string",
8820
+ enum: [
8821
+ "markdown"
8822
+ ]
8823
+ },
8824
+ type: {
8825
+ type: "string",
8826
+ enum: [
8827
+ "block"
8828
+ ]
8829
+ },
8830
+ location: {
8831
+ $ref: "#/definitions/Location"
8832
+ },
8833
+ content: {
8834
+ type: "array",
8835
+ items: {
8836
+ $ref: "#/definitions/PodNode"
8837
+ }
8838
+ },
8839
+ margin: {
8840
+ type: "string"
8841
+ },
8842
+ config: {
8843
+ type: "array",
8844
+ items: {
8845
+ anyOf: [
8846
+ {
8847
+ $ref: "#/definitions/BrokenConfigItem"
8848
+ },
8849
+ {
8850
+ $ref: "#/definitions/ConfigItem"
8851
+ }
8852
+ ]
8853
+ }
8854
+ },
8855
+ id: {
8856
+ type: "string"
8857
+ }
8858
+ },
8859
+ required: [
8860
+ "content",
8861
+ "location",
8862
+ "margin",
8863
+ "name",
8864
+ "type"
8865
+ ]
8866
+ },
8751
8867
  BlockNested: {
8752
8868
  type: "object",
8753
8869
  properties: {
@@ -9336,6 +9452,12 @@ var require_PodliteDocument = __commonJS({
9336
9452
  {
9337
9453
  $ref: "#/definitions/BlockCode"
9338
9454
  },
9455
+ {
9456
+ $ref: "#/definitions/BlockToc"
9457
+ },
9458
+ {
9459
+ $ref: "#/definitions/BlockMarkdown"
9460
+ },
9339
9461
  {
9340
9462
  $ref: "#/definitions/BlockNested"
9341
9463
  },
@@ -10387,6 +10509,12 @@ var require_PodliteDocument = __commonJS({
10387
10509
  {
10388
10510
  $ref: "#/definitions/BlockCode"
10389
10511
  },
10512
+ {
10513
+ $ref: "#/definitions/BlockToc"
10514
+ },
10515
+ {
10516
+ $ref: "#/definitions/BlockMarkdown"
10517
+ },
10390
10518
  {
10391
10519
  $ref: "#/definitions/BlockNested"
10392
10520
  },
@@ -11064,6 +11192,110 @@ var require_PodliteDocument = __commonJS({
11064
11192
  "type"
11065
11193
  ]
11066
11194
  },
11195
+ BlockToc: {
11196
+ type: "object",
11197
+ properties: {
11198
+ name: {
11199
+ type: "string",
11200
+ enum: [
11201
+ "toc"
11202
+ ]
11203
+ },
11204
+ type: {
11205
+ type: "string",
11206
+ enum: [
11207
+ "block"
11208
+ ]
11209
+ },
11210
+ location: {
11211
+ $ref: "#/definitions/Location"
11212
+ },
11213
+ content: {
11214
+ type: "array",
11215
+ items: {
11216
+ $ref: "#/definitions/PodNode"
11217
+ }
11218
+ },
11219
+ margin: {
11220
+ type: "string"
11221
+ },
11222
+ config: {
11223
+ type: "array",
11224
+ items: {
11225
+ anyOf: [
11226
+ {
11227
+ $ref: "#/definitions/BrokenConfigItem"
11228
+ },
11229
+ {
11230
+ $ref: "#/definitions/ConfigItem"
11231
+ }
11232
+ ]
11233
+ }
11234
+ },
11235
+ id: {
11236
+ type: "string"
11237
+ }
11238
+ },
11239
+ required: [
11240
+ "content",
11241
+ "location",
11242
+ "margin",
11243
+ "name",
11244
+ "type"
11245
+ ]
11246
+ },
11247
+ BlockMarkdown: {
11248
+ type: "object",
11249
+ properties: {
11250
+ name: {
11251
+ type: "string",
11252
+ enum: [
11253
+ "markdown"
11254
+ ]
11255
+ },
11256
+ type: {
11257
+ type: "string",
11258
+ enum: [
11259
+ "block"
11260
+ ]
11261
+ },
11262
+ location: {
11263
+ $ref: "#/definitions/Location"
11264
+ },
11265
+ content: {
11266
+ type: "array",
11267
+ items: {
11268
+ $ref: "#/definitions/PodNode"
11269
+ }
11270
+ },
11271
+ margin: {
11272
+ type: "string"
11273
+ },
11274
+ config: {
11275
+ type: "array",
11276
+ items: {
11277
+ anyOf: [
11278
+ {
11279
+ $ref: "#/definitions/BrokenConfigItem"
11280
+ },
11281
+ {
11282
+ $ref: "#/definitions/ConfigItem"
11283
+ }
11284
+ ]
11285
+ }
11286
+ },
11287
+ id: {
11288
+ type: "string"
11289
+ }
11290
+ },
11291
+ required: [
11292
+ "content",
11293
+ "location",
11294
+ "margin",
11295
+ "name",
11296
+ "type"
11297
+ ]
11298
+ },
11067
11299
  BlockNested: {
11068
11300
  type: "object",
11069
11301
  properties: {
@@ -12000,7 +12232,7 @@ var require_grammar = __commonJS({
12000
12232
  }, peg$c117 = function(number) {
12001
12233
  return parseInt(number, 10);
12002
12234
  }, peg$c118 = function(vmargin, name, config) {
12003
- return name.match(/code|comment|output|input|data/) || isNamedBlock2(name);
12235
+ return name.match(/code|comment|output|input|markdown|toc|data/) || isNamedBlock2(name);
12004
12236
  }, peg$c119 = function(vmargin, name, config, margins, ename) {
12005
12237
  return vmargin.length === margins.length && name === ename;
12006
12238
  }, peg$c120 = function(vmargin, name, config, margins, line) {
@@ -12149,7 +12381,7 @@ var require_grammar = __commonJS({
12149
12381
  }, peg$c151 = /^[s]/, peg$c152 = peg$classExpectation(["s"], false, false), peg$c153 = function(line) {
12150
12382
  return {text: text(), type: "ambient1"};
12151
12383
  }, peg$c154 = function(vmargin, name) {
12152
- return name.match(/code|comment|output|input|data/) || isNamedBlock2(name);
12384
+ return name.match(/code|comment|output|input|markdown|toc|data/) || isNamedBlock2(name);
12153
12385
  }, peg$c155 = function(vmargin, name, content2) {
12154
12386
  return {
12155
12387
  margin: vmargin,
@@ -12209,7 +12441,7 @@ var require_grammar = __commonJS({
12209
12441
  margin: vmargin
12210
12442
  };
12211
12443
  }, peg$c168 = function(vmargin, marker, name, config) {
12212
- return name.match(/code|comment|output|input|data/) || isNamedBlock2(name);
12444
+ return name.match(/code|comment|output|input|markdown|toc|data/) || isNamedBlock2(name);
12213
12445
  }, peg$c169 = function(vmargin, marker, name, config, content2) {
12214
12446
  return {
12215
12447
  type: "block",
@@ -13003,23 +13235,29 @@ var require_grammar = __commonJS({
13003
13235
  s2 = peg$currPos;
13004
13236
  s3 = peg$parse_();
13005
13237
  if (s3 !== peg$FAILED) {
13006
- s4 = peg$currPos;
13007
- s5 = peg$parsemarkers();
13008
- if (s5 !== peg$FAILED) {
13009
- s6 = peg$parsestrictIdentifier();
13010
- if (s6 !== peg$FAILED) {
13011
- s5 = [s5, s6];
13012
- s4 = s5;
13013
- } else {
13014
- peg$currPos = s4;
13015
- s4 = peg$FAILED;
13016
- }
13017
- } else {
13018
- peg$currPos = s4;
13019
- s4 = peg$FAILED;
13020
- }
13238
+ s4 = peg$parsemarkerConfig();
13021
13239
  if (s4 === peg$FAILED) {
13022
- s4 = peg$parsemarkerAbbreviatedBlock();
13240
+ s4 = peg$parsemarkerAlias();
13241
+ if (s4 === peg$FAILED) {
13242
+ s4 = peg$currPos;
13243
+ s5 = peg$parsemarkers();
13244
+ if (s5 !== peg$FAILED) {
13245
+ s6 = peg$parsestrictIdentifier();
13246
+ if (s6 !== peg$FAILED) {
13247
+ s5 = [s5, s6];
13248
+ s4 = s5;
13249
+ } else {
13250
+ peg$currPos = s4;
13251
+ s4 = peg$FAILED;
13252
+ }
13253
+ } else {
13254
+ peg$currPos = s4;
13255
+ s4 = peg$FAILED;
13256
+ }
13257
+ if (s4 === peg$FAILED) {
13258
+ s4 = peg$parsemarkerAbbreviatedBlock();
13259
+ }
13260
+ }
13023
13261
  }
13024
13262
  if (s4 !== peg$FAILED) {
13025
13263
  s3 = [s3, s4];
@@ -17636,11 +17874,13 @@ var require_grammar = __commonJS({
17636
17874
  "head",
17637
17875
  "input",
17638
17876
  "item",
17877
+ "markdown",
17639
17878
  "nested",
17640
17879
  "output",
17641
17880
  "para",
17642
17881
  "pod",
17643
- "table"
17882
+ "table",
17883
+ "toc"
17644
17884
  ].includes(name) || isSemanticBlock2(name) || name.match(/^(head|item)\d+$/) || isNamedBlock2(name);
17645
17885
  }
17646
17886
  function exludeVMargin(vmargin, string) {
@@ -17796,64 +18036,80 @@ var require_grammarfc = __commonJS({
17796
18036
  };
17797
18037
  }, peg$c48 = "<", peg$c49 = peg$literalExpectation("<", false), peg$c50 = ">", peg$c51 = peg$literalExpectation(">", false), peg$c52 = function() {
17798
18038
  return text();
17799
- }, peg$c53 = function(text2) {
18039
+ }, peg$c53 = "\xAB", peg$c54 = peg$literalExpectation("\xAB", false), peg$c55 = "\xBB", peg$c56 = peg$literalExpectation("\xBB", false), peg$c57 = function(text2) {
18040
+ return text2;
18041
+ }, peg$c58 = function(name) {
18042
+ return name.code === "C";
18043
+ }, peg$c59 = function(name, content2, end_tag) {
18044
+ return end_tag === name.end_tag;
18045
+ }, peg$c60 = function(name, content2, end_tag) {
18046
+ return {
18047
+ content: content2,
18048
+ "type": "fcode",
18049
+ name: name.code
18050
+ };
18051
+ }, peg$c61 = "|", peg$c62 = peg$literalExpectation("|", false), peg$c63 = function(text2) {
17800
18052
  return text2;
17801
- }, peg$c54 = function(name) {
17802
- return name === "C";
17803
- }, peg$c55 = "|", peg$c56 = peg$literalExpectation("|", false), peg$c57 = function(name) {
17804
- return name === "L";
17805
- }, peg$c58 = function(name, content2, t) {
18053
+ }, peg$c64 = function(name) {
18054
+ return name.code === "L";
18055
+ }, peg$c65 = function(name, content2, t) {
17806
18056
  return t;
17807
- }, peg$c59 = function(name, content2, meta) {
18057
+ }, peg$c66 = function(name, content2, meta, end_tag) {
18058
+ return end_tag === name.end_tag;
18059
+ }, peg$c67 = function(name, content2, meta, end_tag) {
17808
18060
  return {
17809
18061
  content: content2,
17810
18062
  "type": "fcode",
17811
- name,
18063
+ name: name.code,
17812
18064
  meta
17813
18065
  };
17814
- }, peg$c60 = ";", peg$c61 = peg$literalExpectation(";", false), peg$c62 = /^[ \xA0\u2001\t\f\u2008]/, peg$c63 = peg$classExpectation([" ", "\xA0", "\u2001", " ", "\f", "\u2008"], false, false), peg$c64 = function(code, codes) {
18066
+ }, peg$c68 = ";", peg$c69 = peg$literalExpectation(";", false), peg$c70 = /^[ \xA0\u2001\t\f\u2008]/, peg$c71 = peg$classExpectation([" ", "\xA0", "\u2001", " ", "\f", "\u2008"], false, false), peg$c72 = function(code, codes) {
17815
18067
  return flattenDeep5([code, codes]);
17816
- }, peg$c65 = function(code) {
18068
+ }, peg$c73 = function(code) {
17817
18069
  return [code];
17818
- }, peg$c66 = function(name) {
18070
+ }, peg$c74 = function(name) {
17819
18071
  return name === "X";
17820
- }, peg$c67 = function(name, content2, entry) {
18072
+ }, peg$c75 = function(name, content2, entry) {
17821
18073
  return {
17822
18074
  content: content2,
17823
18075
  "type": "fcode",
17824
18076
  name,
17825
18077
  entry
17826
18078
  };
17827
- }, peg$c68 = function(name) {
18079
+ }, peg$c76 = function(name) {
17828
18080
  return name === "S";
17829
- }, peg$c69 = function(name) {
18081
+ }, peg$c77 = function(name) {
17830
18082
  return name === "Z";
17831
- }, peg$c70 = /^[0-9]/, peg$c71 = peg$classExpectation([["0", "9"]], false, false), peg$c72 = "0d", peg$c73 = peg$literalExpectation("0d", false), peg$c74 = function(number) {
18083
+ }, peg$c78 = /^[0-9]/, peg$c79 = peg$classExpectation([["0", "9"]], false, false), peg$c80 = "0d", peg$c81 = peg$literalExpectation("0d", false), peg$c82 = function(number) {
17832
18084
  return parseInt(number, 10);
17833
- }, peg$c75 = "0o", peg$c76 = peg$literalExpectation("0o", false), peg$c77 = function(number) {
18085
+ }, peg$c83 = "0o", peg$c84 = peg$literalExpectation("0o", false), peg$c85 = function(number) {
17834
18086
  return parseInt(number, 8);
17835
- }, peg$c78 = "0b", peg$c79 = peg$literalExpectation("0b", false), peg$c80 = function(number) {
18087
+ }, peg$c86 = "0b", peg$c87 = peg$literalExpectation("0b", false), peg$c88 = function(number) {
17836
18088
  return parseInt(number, 2);
17837
- }, peg$c81 = "0x", peg$c82 = peg$literalExpectation("0x", false), peg$c83 = /^[0-9A-Fa-f]/, peg$c84 = peg$classExpectation([["0", "9"], ["A", "F"], ["a", "f"]], false, false), peg$c85 = function() {
18089
+ }, peg$c89 = "0x", peg$c90 = peg$literalExpectation("0x", false), peg$c91 = /^[0-9A-Fa-f]/, peg$c92 = peg$classExpectation([["0", "9"], ["A", "F"], ["a", "f"]], false, false), peg$c93 = function() {
17838
18090
  return parseInt(text());
17839
- }, peg$c86 = function(number) {
18091
+ }, peg$c94 = function(number) {
17840
18092
  return {type: "number", value: parseInt(number, 10)};
17841
- }, peg$c87 = function(name) {
18093
+ }, peg$c95 = function(name) {
17842
18094
  return name === "E";
17843
- }, peg$c88 = function(name, t) {
18095
+ }, peg$c96 = function(name, t) {
17844
18096
  return flattenDeep5(t);
17845
- }, peg$c89 = function(name, content2) {
18097
+ }, peg$c97 = function(name, content2) {
17846
18098
  return {
17847
18099
  content: content2 ? content2 : [],
17848
18100
  "type": "fcode",
17849
18101
  name
17850
18102
  };
17851
- }, peg$c90 = function(name) {
18103
+ }, peg$c98 = function(name) {
17852
18104
  return name;
17853
- }, peg$c91 = function(name) {
17854
- return name !== "C";
17855
- }, peg$c92 = function(name, content2) {
17856
- return {content: content2, type: "fcode", name};
18105
+ }, peg$c99 = function(name, begin_tag) {
18106
+ return {code: name, begin_tag, end_tag: get_pair_tag(begin_tag)};
18107
+ }, peg$c100 = function(name) {
18108
+ return name.code !== "C";
18109
+ }, peg$c101 = function(name, content2, end_tag) {
18110
+ return end_tag === name.end_tag;
18111
+ }, peg$c102 = function(name, content2, end_tag) {
18112
+ return {content: content2, type: "fcode", name: name.code};
17857
18113
  }, peg$currPos = 0, peg$savedPos = 0, peg$posDetailsCache = [{line: 1, column: 1}], peg$maxFailPos = 0, peg$maxFailExpected = [], peg$silentFails = 0, peg$result;
17858
18114
  if ("startRule" in options) {
17859
18115
  if (!(options.startRule in peg$startRuleFunctions)) {
@@ -17953,7 +18209,7 @@ var require_grammarfc = __commonJS({
17953
18209
  s0 = [];
17954
18210
  s1 = peg$parseallowed_rules();
17955
18211
  if (s1 === peg$FAILED) {
17956
- s1 = peg$parsecode();
18212
+ s1 = peg$parsecode_2();
17957
18213
  if (s1 === peg$FAILED) {
17958
18214
  s1 = peg$parsetext();
17959
18215
  if (s1 === peg$FAILED) {
@@ -17965,7 +18221,7 @@ var require_grammarfc = __commonJS({
17965
18221
  s0.push(s1);
17966
18222
  s1 = peg$parseallowed_rules();
17967
18223
  if (s1 === peg$FAILED) {
17968
- s1 = peg$parsecode();
18224
+ s1 = peg$parsecode_2();
17969
18225
  if (s1 === peg$FAILED) {
17970
18226
  s1 = peg$parsetext();
17971
18227
  if (s1 === peg$FAILED) {
@@ -18621,7 +18877,84 @@ var require_grammarfc = __commonJS({
18621
18877
  peg$currPos = s0;
18622
18878
  s0 = peg$FAILED;
18623
18879
  }
18624
- return s0;
18880
+ if (s0 === peg$FAILED) {
18881
+ s0 = peg$currPos;
18882
+ s1 = peg$currPos;
18883
+ s2 = peg$currPos;
18884
+ peg$silentFails++;
18885
+ s3 = peg$parseallowed_code_C();
18886
+ peg$silentFails--;
18887
+ if (s3 === peg$FAILED) {
18888
+ s2 = void 0;
18889
+ } else {
18890
+ peg$currPos = s2;
18891
+ s2 = peg$FAILED;
18892
+ }
18893
+ if (s2 !== peg$FAILED) {
18894
+ if (input.length > peg$currPos) {
18895
+ s3 = input.charAt(peg$currPos);
18896
+ peg$currPos++;
18897
+ } else {
18898
+ s3 = peg$FAILED;
18899
+ if (peg$silentFails === 0) {
18900
+ peg$fail(peg$c39);
18901
+ }
18902
+ }
18903
+ if (s3 !== peg$FAILED) {
18904
+ s2 = [s2, s3];
18905
+ s1 = s2;
18906
+ } else {
18907
+ peg$currPos = s1;
18908
+ s1 = peg$FAILED;
18909
+ }
18910
+ } else {
18911
+ peg$currPos = s1;
18912
+ s1 = peg$FAILED;
18913
+ }
18914
+ if (s1 !== peg$FAILED) {
18915
+ if (input.charCodeAt(peg$currPos) === 171) {
18916
+ s2 = peg$c53;
18917
+ peg$currPos++;
18918
+ } else {
18919
+ s2 = peg$FAILED;
18920
+ if (peg$silentFails === 0) {
18921
+ peg$fail(peg$c54);
18922
+ }
18923
+ }
18924
+ if (s2 !== peg$FAILED) {
18925
+ s3 = peg$parsenot_code();
18926
+ if (s3 !== peg$FAILED) {
18927
+ if (input.charCodeAt(peg$currPos) === 187) {
18928
+ s4 = peg$c55;
18929
+ peg$currPos++;
18930
+ } else {
18931
+ s4 = peg$FAILED;
18932
+ if (peg$silentFails === 0) {
18933
+ peg$fail(peg$c56);
18934
+ }
18935
+ }
18936
+ if (s4 !== peg$FAILED) {
18937
+ peg$savedPos = s0;
18938
+ s1 = peg$c52();
18939
+ s0 = s1;
18940
+ } else {
18941
+ peg$currPos = s0;
18942
+ s0 = peg$FAILED;
18943
+ }
18944
+ } else {
18945
+ peg$currPos = s0;
18946
+ s0 = peg$FAILED;
18947
+ }
18948
+ } else {
18949
+ peg$currPos = s0;
18950
+ s0 = peg$FAILED;
18951
+ }
18952
+ } else {
18953
+ peg$currPos = s0;
18954
+ s0 = peg$FAILED;
18955
+ }
18956
+ }
18957
+ return s0;
18625
18958
  }
18626
18959
  function peg$parsetext_C() {
18627
18960
  var s0, s1, s2, s3, s4, s5, s6, s7;
@@ -18717,9 +19050,99 @@ var require_grammarfc = __commonJS({
18717
19050
  s3 = peg$FAILED;
18718
19051
  }
18719
19052
  if (s3 === peg$FAILED) {
18720
- s3 = peg$parselooks_like_code_C();
19053
+ s3 = peg$currPos;
19054
+ s4 = peg$currPos;
19055
+ s5 = peg$currPos;
19056
+ peg$silentFails++;
19057
+ if (input.charCodeAt(peg$currPos) === 171) {
19058
+ s6 = peg$c53;
19059
+ peg$currPos++;
19060
+ } else {
19061
+ s6 = peg$FAILED;
19062
+ if (peg$silentFails === 0) {
19063
+ peg$fail(peg$c54);
19064
+ }
19065
+ }
19066
+ peg$silentFails--;
19067
+ if (s6 === peg$FAILED) {
19068
+ s5 = void 0;
19069
+ } else {
19070
+ peg$currPos = s5;
19071
+ s5 = peg$FAILED;
19072
+ }
19073
+ if (s5 !== peg$FAILED) {
19074
+ if (input.length > peg$currPos) {
19075
+ s6 = input.charAt(peg$currPos);
19076
+ peg$currPos++;
19077
+ } else {
19078
+ s6 = peg$FAILED;
19079
+ if (peg$silentFails === 0) {
19080
+ peg$fail(peg$c39);
19081
+ }
19082
+ }
19083
+ if (s6 !== peg$FAILED) {
19084
+ s5 = [s5, s6];
19085
+ s4 = s5;
19086
+ } else {
19087
+ peg$currPos = s4;
19088
+ s4 = peg$FAILED;
19089
+ }
19090
+ } else {
19091
+ peg$currPos = s4;
19092
+ s4 = peg$FAILED;
19093
+ }
19094
+ if (s4 === peg$FAILED) {
19095
+ s4 = null;
19096
+ }
19097
+ if (s4 !== peg$FAILED) {
19098
+ if (input.charCodeAt(peg$currPos) === 171) {
19099
+ s5 = peg$c53;
19100
+ peg$currPos++;
19101
+ } else {
19102
+ s5 = peg$FAILED;
19103
+ if (peg$silentFails === 0) {
19104
+ peg$fail(peg$c54);
19105
+ }
19106
+ }
19107
+ if (s5 !== peg$FAILED) {
19108
+ s6 = peg$parsetext_C();
19109
+ if (s6 === peg$FAILED) {
19110
+ s6 = null;
19111
+ }
19112
+ if (s6 !== peg$FAILED) {
19113
+ if (input.charCodeAt(peg$currPos) === 187) {
19114
+ s7 = peg$c55;
19115
+ peg$currPos++;
19116
+ } else {
19117
+ s7 = peg$FAILED;
19118
+ if (peg$silentFails === 0) {
19119
+ peg$fail(peg$c56);
19120
+ }
19121
+ }
19122
+ if (s7 !== peg$FAILED) {
19123
+ s4 = [s4, s5, s6, s7];
19124
+ s3 = s4;
19125
+ } else {
19126
+ peg$currPos = s3;
19127
+ s3 = peg$FAILED;
19128
+ }
19129
+ } else {
19130
+ peg$currPos = s3;
19131
+ s3 = peg$FAILED;
19132
+ }
19133
+ } else {
19134
+ peg$currPos = s3;
19135
+ s3 = peg$FAILED;
19136
+ }
19137
+ } else {
19138
+ peg$currPos = s3;
19139
+ s3 = peg$FAILED;
19140
+ }
18721
19141
  if (s3 === peg$FAILED) {
18722
- s3 = peg$parsenot_code();
19142
+ s3 = peg$parselooks_like_code_C();
19143
+ if (s3 === peg$FAILED) {
19144
+ s3 = peg$parsenot_code();
19145
+ }
18723
19146
  }
18724
19147
  }
18725
19148
  if (s3 !== peg$FAILED) {
@@ -18814,9 +19237,99 @@ var require_grammarfc = __commonJS({
18814
19237
  s3 = peg$FAILED;
18815
19238
  }
18816
19239
  if (s3 === peg$FAILED) {
18817
- s3 = peg$parselooks_like_code_C();
19240
+ s3 = peg$currPos;
19241
+ s4 = peg$currPos;
19242
+ s5 = peg$currPos;
19243
+ peg$silentFails++;
19244
+ if (input.charCodeAt(peg$currPos) === 171) {
19245
+ s6 = peg$c53;
19246
+ peg$currPos++;
19247
+ } else {
19248
+ s6 = peg$FAILED;
19249
+ if (peg$silentFails === 0) {
19250
+ peg$fail(peg$c54);
19251
+ }
19252
+ }
19253
+ peg$silentFails--;
19254
+ if (s6 === peg$FAILED) {
19255
+ s5 = void 0;
19256
+ } else {
19257
+ peg$currPos = s5;
19258
+ s5 = peg$FAILED;
19259
+ }
19260
+ if (s5 !== peg$FAILED) {
19261
+ if (input.length > peg$currPos) {
19262
+ s6 = input.charAt(peg$currPos);
19263
+ peg$currPos++;
19264
+ } else {
19265
+ s6 = peg$FAILED;
19266
+ if (peg$silentFails === 0) {
19267
+ peg$fail(peg$c39);
19268
+ }
19269
+ }
19270
+ if (s6 !== peg$FAILED) {
19271
+ s5 = [s5, s6];
19272
+ s4 = s5;
19273
+ } else {
19274
+ peg$currPos = s4;
19275
+ s4 = peg$FAILED;
19276
+ }
19277
+ } else {
19278
+ peg$currPos = s4;
19279
+ s4 = peg$FAILED;
19280
+ }
19281
+ if (s4 === peg$FAILED) {
19282
+ s4 = null;
19283
+ }
19284
+ if (s4 !== peg$FAILED) {
19285
+ if (input.charCodeAt(peg$currPos) === 171) {
19286
+ s5 = peg$c53;
19287
+ peg$currPos++;
19288
+ } else {
19289
+ s5 = peg$FAILED;
19290
+ if (peg$silentFails === 0) {
19291
+ peg$fail(peg$c54);
19292
+ }
19293
+ }
19294
+ if (s5 !== peg$FAILED) {
19295
+ s6 = peg$parsetext_C();
19296
+ if (s6 === peg$FAILED) {
19297
+ s6 = null;
19298
+ }
19299
+ if (s6 !== peg$FAILED) {
19300
+ if (input.charCodeAt(peg$currPos) === 187) {
19301
+ s7 = peg$c55;
19302
+ peg$currPos++;
19303
+ } else {
19304
+ s7 = peg$FAILED;
19305
+ if (peg$silentFails === 0) {
19306
+ peg$fail(peg$c56);
19307
+ }
19308
+ }
19309
+ if (s7 !== peg$FAILED) {
19310
+ s4 = [s4, s5, s6, s7];
19311
+ s3 = s4;
19312
+ } else {
19313
+ peg$currPos = s3;
19314
+ s3 = peg$FAILED;
19315
+ }
19316
+ } else {
19317
+ peg$currPos = s3;
19318
+ s3 = peg$FAILED;
19319
+ }
19320
+ } else {
19321
+ peg$currPos = s3;
19322
+ s3 = peg$FAILED;
19323
+ }
19324
+ } else {
19325
+ peg$currPos = s3;
19326
+ s3 = peg$FAILED;
19327
+ }
18818
19328
  if (s3 === peg$FAILED) {
18819
- s3 = peg$parsenot_code();
19329
+ s3 = peg$parselooks_like_code_C();
19330
+ if (s3 === peg$FAILED) {
19331
+ s3 = peg$parsenot_code();
19332
+ }
18820
19333
  }
18821
19334
  }
18822
19335
  }
@@ -18830,18 +19343,18 @@ var require_grammarfc = __commonJS({
18830
19343
  }
18831
19344
  if (s1 !== peg$FAILED) {
18832
19345
  peg$savedPos = s0;
18833
- s1 = peg$c53(s1);
19346
+ s1 = peg$c57(s1);
18834
19347
  }
18835
19348
  s0 = s1;
18836
19349
  return s0;
18837
19350
  }
18838
19351
  function peg$parsecode_C() {
18839
- var s0, s1, s2, s3, s4;
19352
+ var s0, s1, s2, s3, s4, s5;
18840
19353
  s0 = peg$currPos;
18841
- s1 = peg$parsestart_code();
19354
+ s1 = peg$parsestart_code_2();
18842
19355
  if (s1 !== peg$FAILED) {
18843
19356
  peg$savedPos = peg$currPos;
18844
- s2 = peg$c54(s1);
19357
+ s2 = peg$c58(s1);
18845
19358
  if (s2) {
18846
19359
  s2 = void 0;
18847
19360
  } else {
@@ -18861,9 +19374,21 @@ var require_grammarfc = __commonJS({
18861
19374
  if (s3 !== peg$FAILED) {
18862
19375
  s4 = peg$parseend_code();
18863
19376
  if (s4 !== peg$FAILED) {
18864
- peg$savedPos = s0;
18865
- s1 = peg$c42(s1, s3);
18866
- s0 = s1;
19377
+ peg$savedPos = peg$currPos;
19378
+ s5 = peg$c59(s1, s3, s4);
19379
+ if (s5) {
19380
+ s5 = void 0;
19381
+ } else {
19382
+ s5 = peg$FAILED;
19383
+ }
19384
+ if (s5 !== peg$FAILED) {
19385
+ peg$savedPos = s0;
19386
+ s1 = peg$c60(s1, s3, s4);
19387
+ s0 = s1;
19388
+ } else {
19389
+ peg$currPos = s0;
19390
+ s0 = peg$FAILED;
19391
+ }
18867
19392
  } else {
18868
19393
  peg$currPos = s0;
18869
19394
  s0 = peg$FAILED;
@@ -18885,53 +19410,110 @@ var require_grammarfc = __commonJS({
18885
19410
  function peg$parseseparator() {
18886
19411
  var s0;
18887
19412
  if (input.charCodeAt(peg$currPos) === 124) {
18888
- s0 = peg$c55;
19413
+ s0 = peg$c61;
18889
19414
  peg$currPos++;
18890
19415
  } else {
18891
19416
  s0 = peg$FAILED;
18892
19417
  if (peg$silentFails === 0) {
18893
- peg$fail(peg$c56);
19418
+ peg$fail(peg$c62);
18894
19419
  }
18895
19420
  }
18896
19421
  return s0;
18897
19422
  }
18898
19423
  function peg$parsetext_L() {
18899
- var s0, s1, s2, s3, s4, s5, s6, s7;
19424
+ var s0, s1, s2, s3, s4, s5, s6, s7, s8;
18900
19425
  s0 = peg$currPos;
18901
- s1 = [];
18902
- s2 = peg$currPos;
19426
+ s1 = peg$currPos;
19427
+ s2 = [];
18903
19428
  s3 = peg$currPos;
18904
19429
  s4 = peg$currPos;
19430
+ s5 = peg$currPos;
18905
19431
  peg$silentFails++;
18906
19432
  if (input.charCodeAt(peg$currPos) === 60) {
18907
- s5 = peg$c48;
19433
+ s6 = peg$c48;
18908
19434
  peg$currPos++;
18909
19435
  } else {
18910
- s5 = peg$FAILED;
19436
+ s6 = peg$FAILED;
18911
19437
  if (peg$silentFails === 0) {
18912
19438
  peg$fail(peg$c49);
18913
19439
  }
18914
19440
  }
18915
19441
  peg$silentFails--;
18916
- if (s5 === peg$FAILED) {
18917
- s4 = void 0;
19442
+ if (s6 === peg$FAILED) {
19443
+ s5 = void 0;
18918
19444
  } else {
18919
- peg$currPos = s4;
18920
- s4 = peg$FAILED;
19445
+ peg$currPos = s5;
19446
+ s5 = peg$FAILED;
19447
+ }
19448
+ if (s5 !== peg$FAILED) {
19449
+ s6 = peg$currPos;
19450
+ peg$silentFails++;
19451
+ s7 = peg$parseallowed_code();
19452
+ peg$silentFails--;
19453
+ if (s7 === peg$FAILED) {
19454
+ s6 = void 0;
19455
+ } else {
19456
+ peg$currPos = s6;
19457
+ s6 = peg$FAILED;
19458
+ }
19459
+ if (s6 !== peg$FAILED) {
19460
+ if (input.length > peg$currPos) {
19461
+ s7 = input.charAt(peg$currPos);
19462
+ peg$currPos++;
19463
+ } else {
19464
+ s7 = peg$FAILED;
19465
+ if (peg$silentFails === 0) {
19466
+ peg$fail(peg$c39);
19467
+ }
19468
+ }
19469
+ if (s7 !== peg$FAILED) {
19470
+ s5 = [s5, s6, s7];
19471
+ s4 = s5;
19472
+ } else {
19473
+ peg$currPos = s4;
19474
+ s4 = peg$FAILED;
19475
+ }
19476
+ } else {
19477
+ peg$currPos = s4;
19478
+ s4 = peg$FAILED;
19479
+ }
19480
+ } else {
19481
+ peg$currPos = s4;
19482
+ s4 = peg$FAILED;
18921
19483
  }
18922
19484
  if (s4 !== peg$FAILED) {
18923
- if (input.length > peg$currPos) {
18924
- s5 = input.charAt(peg$currPos);
19485
+ if (input.charCodeAt(peg$currPos) === 60) {
19486
+ s5 = peg$c48;
18925
19487
  peg$currPos++;
18926
19488
  } else {
18927
19489
  s5 = peg$FAILED;
18928
19490
  if (peg$silentFails === 0) {
18929
- peg$fail(peg$c39);
19491
+ peg$fail(peg$c49);
18930
19492
  }
18931
19493
  }
18932
19494
  if (s5 !== peg$FAILED) {
18933
- s4 = [s4, s5];
18934
- s3 = s4;
19495
+ s6 = peg$parsetext_L();
19496
+ if (s6 !== peg$FAILED) {
19497
+ if (input.charCodeAt(peg$currPos) === 62) {
19498
+ s7 = peg$c50;
19499
+ peg$currPos++;
19500
+ } else {
19501
+ s7 = peg$FAILED;
19502
+ if (peg$silentFails === 0) {
19503
+ peg$fail(peg$c51);
19504
+ }
19505
+ }
19506
+ if (s7 !== peg$FAILED) {
19507
+ s4 = [s4, s5, s6, s7];
19508
+ s3 = s4;
19509
+ } else {
19510
+ peg$currPos = s3;
19511
+ s3 = peg$FAILED;
19512
+ }
19513
+ } else {
19514
+ peg$currPos = s3;
19515
+ s3 = peg$FAILED;
19516
+ }
18935
19517
  } else {
18936
19518
  peg$currPos = s3;
18937
19519
  s3 = peg$FAILED;
@@ -18940,63 +19522,112 @@ var require_grammarfc = __commonJS({
18940
19522
  peg$currPos = s3;
18941
19523
  s3 = peg$FAILED;
18942
19524
  }
18943
- if (s3 !== peg$FAILED) {
18944
- if (input.charCodeAt(peg$currPos) === 60) {
18945
- s4 = peg$c48;
19525
+ if (s3 === peg$FAILED) {
19526
+ s3 = peg$currPos;
19527
+ s4 = peg$currPos;
19528
+ s5 = peg$currPos;
19529
+ peg$silentFails++;
19530
+ if (input.charCodeAt(peg$currPos) === 171) {
19531
+ s6 = peg$c53;
18946
19532
  peg$currPos++;
18947
19533
  } else {
18948
- s4 = peg$FAILED;
19534
+ s6 = peg$FAILED;
18949
19535
  if (peg$silentFails === 0) {
18950
- peg$fail(peg$c49);
19536
+ peg$fail(peg$c54);
18951
19537
  }
18952
19538
  }
18953
- if (s4 !== peg$FAILED) {
18954
- s5 = peg$parsetext_L();
18955
- if (s5 !== peg$FAILED) {
18956
- if (input.charCodeAt(peg$currPos) === 62) {
18957
- s6 = peg$c50;
19539
+ peg$silentFails--;
19540
+ if (s6 === peg$FAILED) {
19541
+ s5 = void 0;
19542
+ } else {
19543
+ peg$currPos = s5;
19544
+ s5 = peg$FAILED;
19545
+ }
19546
+ if (s5 !== peg$FAILED) {
19547
+ s6 = peg$currPos;
19548
+ peg$silentFails++;
19549
+ s7 = peg$parseallowed_code();
19550
+ peg$silentFails--;
19551
+ if (s7 === peg$FAILED) {
19552
+ s6 = void 0;
19553
+ } else {
19554
+ peg$currPos = s6;
19555
+ s6 = peg$FAILED;
19556
+ }
19557
+ if (s6 !== peg$FAILED) {
19558
+ if (input.length > peg$currPos) {
19559
+ s7 = input.charAt(peg$currPos);
18958
19560
  peg$currPos++;
18959
19561
  } else {
18960
- s6 = peg$FAILED;
19562
+ s7 = peg$FAILED;
18961
19563
  if (peg$silentFails === 0) {
18962
- peg$fail(peg$c51);
19564
+ peg$fail(peg$c39);
18963
19565
  }
18964
19566
  }
18965
- if (s6 !== peg$FAILED) {
18966
- s3 = [s3, s4, s5, s6];
18967
- s2 = s3;
19567
+ if (s7 !== peg$FAILED) {
19568
+ s5 = [s5, s6, s7];
19569
+ s4 = s5;
18968
19570
  } else {
18969
- peg$currPos = s2;
18970
- s2 = peg$FAILED;
19571
+ peg$currPos = s4;
19572
+ s4 = peg$FAILED;
18971
19573
  }
18972
19574
  } else {
18973
- peg$currPos = s2;
18974
- s2 = peg$FAILED;
19575
+ peg$currPos = s4;
19576
+ s4 = peg$FAILED;
18975
19577
  }
18976
19578
  } else {
18977
- peg$currPos = s2;
18978
- s2 = peg$FAILED;
19579
+ peg$currPos = s4;
19580
+ s4 = peg$FAILED;
18979
19581
  }
18980
- } else {
18981
- peg$currPos = s2;
18982
- s2 = peg$FAILED;
18983
- }
18984
- if (s2 === peg$FAILED) {
18985
- s2 = peg$currPos;
18986
- s3 = peg$currPos;
18987
- peg$silentFails++;
18988
- s4 = peg$parseseparator();
18989
- peg$silentFails--;
18990
- if (s4 === peg$FAILED) {
18991
- s3 = void 0;
19582
+ if (s4 !== peg$FAILED) {
19583
+ if (input.charCodeAt(peg$currPos) === 171) {
19584
+ s5 = peg$c53;
19585
+ peg$currPos++;
19586
+ } else {
19587
+ s5 = peg$FAILED;
19588
+ if (peg$silentFails === 0) {
19589
+ peg$fail(peg$c54);
19590
+ }
19591
+ }
19592
+ if (s5 !== peg$FAILED) {
19593
+ s6 = peg$parsetext_L();
19594
+ if (s6 === peg$FAILED) {
19595
+ s6 = null;
19596
+ }
19597
+ if (s6 !== peg$FAILED) {
19598
+ if (input.charCodeAt(peg$currPos) === 187) {
19599
+ s7 = peg$c55;
19600
+ peg$currPos++;
19601
+ } else {
19602
+ s7 = peg$FAILED;
19603
+ if (peg$silentFails === 0) {
19604
+ peg$fail(peg$c56);
19605
+ }
19606
+ }
19607
+ if (s7 !== peg$FAILED) {
19608
+ s4 = [s4, s5, s6, s7];
19609
+ s3 = s4;
19610
+ } else {
19611
+ peg$currPos = s3;
19612
+ s3 = peg$FAILED;
19613
+ }
19614
+ } else {
19615
+ peg$currPos = s3;
19616
+ s3 = peg$FAILED;
19617
+ }
19618
+ } else {
19619
+ peg$currPos = s3;
19620
+ s3 = peg$FAILED;
19621
+ }
18992
19622
  } else {
18993
19623
  peg$currPos = s3;
18994
19624
  s3 = peg$FAILED;
18995
19625
  }
18996
- if (s3 !== peg$FAILED) {
19626
+ if (s3 === peg$FAILED) {
19627
+ s3 = peg$currPos;
18997
19628
  s4 = peg$currPos;
18998
19629
  peg$silentFails++;
18999
- s5 = peg$parseend_code();
19630
+ s5 = peg$parseseparator();
19000
19631
  peg$silentFails--;
19001
19632
  if (s5 === peg$FAILED) {
19002
19633
  s4 = void 0;
@@ -19007,7 +19638,7 @@ var require_grammarfc = __commonJS({
19007
19638
  if (s4 !== peg$FAILED) {
19008
19639
  s5 = peg$currPos;
19009
19640
  peg$silentFails++;
19010
- s6 = peg$parsestart_code();
19641
+ s6 = peg$parseend_code();
19011
19642
  peg$silentFails--;
19012
19643
  if (s6 === peg$FAILED) {
19013
19644
  s5 = void 0;
@@ -19018,7 +19649,7 @@ var require_grammarfc = __commonJS({
19018
19649
  if (s5 !== peg$FAILED) {
19019
19650
  s6 = peg$currPos;
19020
19651
  peg$silentFails++;
19021
- s7 = peg$parselooks_like_code();
19652
+ s7 = peg$parsestart_code();
19022
19653
  peg$silentFails--;
19023
19654
  if (s7 === peg$FAILED) {
19024
19655
  s6 = void 0;
@@ -19027,75 +19658,143 @@ var require_grammarfc = __commonJS({
19027
19658
  s6 = peg$FAILED;
19028
19659
  }
19029
19660
  if (s6 !== peg$FAILED) {
19030
- if (input.length > peg$currPos) {
19031
- s7 = input.charAt(peg$currPos);
19032
- peg$currPos++;
19661
+ s7 = peg$currPos;
19662
+ peg$silentFails++;
19663
+ s8 = peg$parselooks_like_code();
19664
+ peg$silentFails--;
19665
+ if (s8 === peg$FAILED) {
19666
+ s7 = void 0;
19033
19667
  } else {
19668
+ peg$currPos = s7;
19034
19669
  s7 = peg$FAILED;
19035
- if (peg$silentFails === 0) {
19036
- peg$fail(peg$c39);
19037
- }
19038
19670
  }
19039
19671
  if (s7 !== peg$FAILED) {
19040
- s3 = [s3, s4, s5, s6, s7];
19041
- s2 = s3;
19672
+ if (input.length > peg$currPos) {
19673
+ s8 = input.charAt(peg$currPos);
19674
+ peg$currPos++;
19675
+ } else {
19676
+ s8 = peg$FAILED;
19677
+ if (peg$silentFails === 0) {
19678
+ peg$fail(peg$c39);
19679
+ }
19680
+ }
19681
+ if (s8 !== peg$FAILED) {
19682
+ s4 = [s4, s5, s6, s7, s8];
19683
+ s3 = s4;
19684
+ } else {
19685
+ peg$currPos = s3;
19686
+ s3 = peg$FAILED;
19687
+ }
19042
19688
  } else {
19043
- peg$currPos = s2;
19044
- s2 = peg$FAILED;
19689
+ peg$currPos = s3;
19690
+ s3 = peg$FAILED;
19045
19691
  }
19046
19692
  } else {
19047
- peg$currPos = s2;
19048
- s2 = peg$FAILED;
19693
+ peg$currPos = s3;
19694
+ s3 = peg$FAILED;
19049
19695
  }
19050
19696
  } else {
19051
- peg$currPos = s2;
19052
- s2 = peg$FAILED;
19697
+ peg$currPos = s3;
19698
+ s3 = peg$FAILED;
19053
19699
  }
19054
19700
  } else {
19055
- peg$currPos = s2;
19056
- s2 = peg$FAILED;
19701
+ peg$currPos = s3;
19702
+ s3 = peg$FAILED;
19057
19703
  }
19058
- } else {
19059
- peg$currPos = s2;
19060
- s2 = peg$FAILED;
19061
19704
  }
19062
19705
  }
19063
- if (s2 !== peg$FAILED) {
19064
- while (s2 !== peg$FAILED) {
19065
- s1.push(s2);
19066
- s2 = peg$currPos;
19706
+ if (s3 !== peg$FAILED) {
19707
+ while (s3 !== peg$FAILED) {
19708
+ s2.push(s3);
19067
19709
  s3 = peg$currPos;
19068
19710
  s4 = peg$currPos;
19711
+ s5 = peg$currPos;
19069
19712
  peg$silentFails++;
19070
19713
  if (input.charCodeAt(peg$currPos) === 60) {
19071
- s5 = peg$c48;
19714
+ s6 = peg$c48;
19072
19715
  peg$currPos++;
19073
19716
  } else {
19074
- s5 = peg$FAILED;
19717
+ s6 = peg$FAILED;
19075
19718
  if (peg$silentFails === 0) {
19076
19719
  peg$fail(peg$c49);
19077
19720
  }
19078
19721
  }
19079
19722
  peg$silentFails--;
19080
- if (s5 === peg$FAILED) {
19081
- s4 = void 0;
19723
+ if (s6 === peg$FAILED) {
19724
+ s5 = void 0;
19725
+ } else {
19726
+ peg$currPos = s5;
19727
+ s5 = peg$FAILED;
19728
+ }
19729
+ if (s5 !== peg$FAILED) {
19730
+ s6 = peg$currPos;
19731
+ peg$silentFails++;
19732
+ s7 = peg$parseallowed_code();
19733
+ peg$silentFails--;
19734
+ if (s7 === peg$FAILED) {
19735
+ s6 = void 0;
19736
+ } else {
19737
+ peg$currPos = s6;
19738
+ s6 = peg$FAILED;
19739
+ }
19740
+ if (s6 !== peg$FAILED) {
19741
+ if (input.length > peg$currPos) {
19742
+ s7 = input.charAt(peg$currPos);
19743
+ peg$currPos++;
19744
+ } else {
19745
+ s7 = peg$FAILED;
19746
+ if (peg$silentFails === 0) {
19747
+ peg$fail(peg$c39);
19748
+ }
19749
+ }
19750
+ if (s7 !== peg$FAILED) {
19751
+ s5 = [s5, s6, s7];
19752
+ s4 = s5;
19753
+ } else {
19754
+ peg$currPos = s4;
19755
+ s4 = peg$FAILED;
19756
+ }
19757
+ } else {
19758
+ peg$currPos = s4;
19759
+ s4 = peg$FAILED;
19760
+ }
19082
19761
  } else {
19083
19762
  peg$currPos = s4;
19084
19763
  s4 = peg$FAILED;
19085
19764
  }
19086
19765
  if (s4 !== peg$FAILED) {
19087
- if (input.length > peg$currPos) {
19088
- s5 = input.charAt(peg$currPos);
19766
+ if (input.charCodeAt(peg$currPos) === 60) {
19767
+ s5 = peg$c48;
19089
19768
  peg$currPos++;
19090
19769
  } else {
19091
19770
  s5 = peg$FAILED;
19092
19771
  if (peg$silentFails === 0) {
19093
- peg$fail(peg$c39);
19772
+ peg$fail(peg$c49);
19094
19773
  }
19095
19774
  }
19096
19775
  if (s5 !== peg$FAILED) {
19097
- s4 = [s4, s5];
19098
- s3 = s4;
19776
+ s6 = peg$parsetext_L();
19777
+ if (s6 !== peg$FAILED) {
19778
+ if (input.charCodeAt(peg$currPos) === 62) {
19779
+ s7 = peg$c50;
19780
+ peg$currPos++;
19781
+ } else {
19782
+ s7 = peg$FAILED;
19783
+ if (peg$silentFails === 0) {
19784
+ peg$fail(peg$c51);
19785
+ }
19786
+ }
19787
+ if (s7 !== peg$FAILED) {
19788
+ s4 = [s4, s5, s6, s7];
19789
+ s3 = s4;
19790
+ } else {
19791
+ peg$currPos = s3;
19792
+ s3 = peg$FAILED;
19793
+ }
19794
+ } else {
19795
+ peg$currPos = s3;
19796
+ s3 = peg$FAILED;
19797
+ }
19099
19798
  } else {
19100
19799
  peg$currPos = s3;
19101
19800
  s3 = peg$FAILED;
@@ -19104,63 +19803,112 @@ var require_grammarfc = __commonJS({
19104
19803
  peg$currPos = s3;
19105
19804
  s3 = peg$FAILED;
19106
19805
  }
19107
- if (s3 !== peg$FAILED) {
19108
- if (input.charCodeAt(peg$currPos) === 60) {
19109
- s4 = peg$c48;
19806
+ if (s3 === peg$FAILED) {
19807
+ s3 = peg$currPos;
19808
+ s4 = peg$currPos;
19809
+ s5 = peg$currPos;
19810
+ peg$silentFails++;
19811
+ if (input.charCodeAt(peg$currPos) === 171) {
19812
+ s6 = peg$c53;
19110
19813
  peg$currPos++;
19111
19814
  } else {
19112
- s4 = peg$FAILED;
19815
+ s6 = peg$FAILED;
19113
19816
  if (peg$silentFails === 0) {
19114
- peg$fail(peg$c49);
19817
+ peg$fail(peg$c54);
19115
19818
  }
19116
19819
  }
19117
- if (s4 !== peg$FAILED) {
19118
- s5 = peg$parsetext_L();
19119
- if (s5 !== peg$FAILED) {
19120
- if (input.charCodeAt(peg$currPos) === 62) {
19121
- s6 = peg$c50;
19820
+ peg$silentFails--;
19821
+ if (s6 === peg$FAILED) {
19822
+ s5 = void 0;
19823
+ } else {
19824
+ peg$currPos = s5;
19825
+ s5 = peg$FAILED;
19826
+ }
19827
+ if (s5 !== peg$FAILED) {
19828
+ s6 = peg$currPos;
19829
+ peg$silentFails++;
19830
+ s7 = peg$parseallowed_code();
19831
+ peg$silentFails--;
19832
+ if (s7 === peg$FAILED) {
19833
+ s6 = void 0;
19834
+ } else {
19835
+ peg$currPos = s6;
19836
+ s6 = peg$FAILED;
19837
+ }
19838
+ if (s6 !== peg$FAILED) {
19839
+ if (input.length > peg$currPos) {
19840
+ s7 = input.charAt(peg$currPos);
19122
19841
  peg$currPos++;
19123
19842
  } else {
19124
- s6 = peg$FAILED;
19843
+ s7 = peg$FAILED;
19125
19844
  if (peg$silentFails === 0) {
19126
- peg$fail(peg$c51);
19845
+ peg$fail(peg$c39);
19127
19846
  }
19128
19847
  }
19129
- if (s6 !== peg$FAILED) {
19130
- s3 = [s3, s4, s5, s6];
19131
- s2 = s3;
19848
+ if (s7 !== peg$FAILED) {
19849
+ s5 = [s5, s6, s7];
19850
+ s4 = s5;
19132
19851
  } else {
19133
- peg$currPos = s2;
19134
- s2 = peg$FAILED;
19852
+ peg$currPos = s4;
19853
+ s4 = peg$FAILED;
19135
19854
  }
19136
19855
  } else {
19137
- peg$currPos = s2;
19138
- s2 = peg$FAILED;
19856
+ peg$currPos = s4;
19857
+ s4 = peg$FAILED;
19139
19858
  }
19140
19859
  } else {
19141
- peg$currPos = s2;
19142
- s2 = peg$FAILED;
19860
+ peg$currPos = s4;
19861
+ s4 = peg$FAILED;
19143
19862
  }
19144
- } else {
19145
- peg$currPos = s2;
19146
- s2 = peg$FAILED;
19147
- }
19148
- if (s2 === peg$FAILED) {
19149
- s2 = peg$currPos;
19150
- s3 = peg$currPos;
19151
- peg$silentFails++;
19152
- s4 = peg$parseseparator();
19153
- peg$silentFails--;
19154
- if (s4 === peg$FAILED) {
19155
- s3 = void 0;
19863
+ if (s4 !== peg$FAILED) {
19864
+ if (input.charCodeAt(peg$currPos) === 171) {
19865
+ s5 = peg$c53;
19866
+ peg$currPos++;
19867
+ } else {
19868
+ s5 = peg$FAILED;
19869
+ if (peg$silentFails === 0) {
19870
+ peg$fail(peg$c54);
19871
+ }
19872
+ }
19873
+ if (s5 !== peg$FAILED) {
19874
+ s6 = peg$parsetext_L();
19875
+ if (s6 === peg$FAILED) {
19876
+ s6 = null;
19877
+ }
19878
+ if (s6 !== peg$FAILED) {
19879
+ if (input.charCodeAt(peg$currPos) === 187) {
19880
+ s7 = peg$c55;
19881
+ peg$currPos++;
19882
+ } else {
19883
+ s7 = peg$FAILED;
19884
+ if (peg$silentFails === 0) {
19885
+ peg$fail(peg$c56);
19886
+ }
19887
+ }
19888
+ if (s7 !== peg$FAILED) {
19889
+ s4 = [s4, s5, s6, s7];
19890
+ s3 = s4;
19891
+ } else {
19892
+ peg$currPos = s3;
19893
+ s3 = peg$FAILED;
19894
+ }
19895
+ } else {
19896
+ peg$currPos = s3;
19897
+ s3 = peg$FAILED;
19898
+ }
19899
+ } else {
19900
+ peg$currPos = s3;
19901
+ s3 = peg$FAILED;
19902
+ }
19156
19903
  } else {
19157
19904
  peg$currPos = s3;
19158
19905
  s3 = peg$FAILED;
19159
19906
  }
19160
- if (s3 !== peg$FAILED) {
19907
+ if (s3 === peg$FAILED) {
19908
+ s3 = peg$currPos;
19161
19909
  s4 = peg$currPos;
19162
19910
  peg$silentFails++;
19163
- s5 = peg$parseend_code();
19911
+ s5 = peg$parseseparator();
19164
19912
  peg$silentFails--;
19165
19913
  if (s5 === peg$FAILED) {
19166
19914
  s4 = void 0;
@@ -19171,7 +19919,7 @@ var require_grammarfc = __commonJS({
19171
19919
  if (s4 !== peg$FAILED) {
19172
19920
  s5 = peg$currPos;
19173
19921
  peg$silentFails++;
19174
- s6 = peg$parsestart_code();
19922
+ s6 = peg$parseend_code();
19175
19923
  peg$silentFails--;
19176
19924
  if (s6 === peg$FAILED) {
19177
19925
  s5 = void 0;
@@ -19182,7 +19930,7 @@ var require_grammarfc = __commonJS({
19182
19930
  if (s5 !== peg$FAILED) {
19183
19931
  s6 = peg$currPos;
19184
19932
  peg$silentFails++;
19185
- s7 = peg$parselooks_like_code();
19933
+ s7 = peg$parsestart_code();
19186
19934
  peg$silentFails--;
19187
19935
  if (s7 === peg$FAILED) {
19188
19936
  s6 = void 0;
@@ -19191,57 +19939,74 @@ var require_grammarfc = __commonJS({
19191
19939
  s6 = peg$FAILED;
19192
19940
  }
19193
19941
  if (s6 !== peg$FAILED) {
19194
- if (input.length > peg$currPos) {
19195
- s7 = input.charAt(peg$currPos);
19196
- peg$currPos++;
19942
+ s7 = peg$currPos;
19943
+ peg$silentFails++;
19944
+ s8 = peg$parselooks_like_code();
19945
+ peg$silentFails--;
19946
+ if (s8 === peg$FAILED) {
19947
+ s7 = void 0;
19197
19948
  } else {
19949
+ peg$currPos = s7;
19198
19950
  s7 = peg$FAILED;
19199
- if (peg$silentFails === 0) {
19200
- peg$fail(peg$c39);
19201
- }
19202
19951
  }
19203
19952
  if (s7 !== peg$FAILED) {
19204
- s3 = [s3, s4, s5, s6, s7];
19205
- s2 = s3;
19953
+ if (input.length > peg$currPos) {
19954
+ s8 = input.charAt(peg$currPos);
19955
+ peg$currPos++;
19956
+ } else {
19957
+ s8 = peg$FAILED;
19958
+ if (peg$silentFails === 0) {
19959
+ peg$fail(peg$c39);
19960
+ }
19961
+ }
19962
+ if (s8 !== peg$FAILED) {
19963
+ s4 = [s4, s5, s6, s7, s8];
19964
+ s3 = s4;
19965
+ } else {
19966
+ peg$currPos = s3;
19967
+ s3 = peg$FAILED;
19968
+ }
19206
19969
  } else {
19207
- peg$currPos = s2;
19208
- s2 = peg$FAILED;
19970
+ peg$currPos = s3;
19971
+ s3 = peg$FAILED;
19209
19972
  }
19210
19973
  } else {
19211
- peg$currPos = s2;
19212
- s2 = peg$FAILED;
19974
+ peg$currPos = s3;
19975
+ s3 = peg$FAILED;
19213
19976
  }
19214
19977
  } else {
19215
- peg$currPos = s2;
19216
- s2 = peg$FAILED;
19978
+ peg$currPos = s3;
19979
+ s3 = peg$FAILED;
19217
19980
  }
19218
19981
  } else {
19219
- peg$currPos = s2;
19220
- s2 = peg$FAILED;
19982
+ peg$currPos = s3;
19983
+ s3 = peg$FAILED;
19221
19984
  }
19222
- } else {
19223
- peg$currPos = s2;
19224
- s2 = peg$FAILED;
19225
19985
  }
19226
19986
  }
19227
19987
  }
19228
19988
  } else {
19229
- s1 = peg$FAILED;
19989
+ s2 = peg$FAILED;
19230
19990
  }
19231
- if (s1 !== peg$FAILED) {
19232
- s0 = input.substring(s0, peg$currPos);
19991
+ if (s2 !== peg$FAILED) {
19992
+ s1 = input.substring(s1, peg$currPos);
19233
19993
  } else {
19234
- s0 = s1;
19994
+ s1 = s2;
19995
+ }
19996
+ if (s1 !== peg$FAILED) {
19997
+ peg$savedPos = s0;
19998
+ s1 = peg$c63(s1);
19235
19999
  }
20000
+ s0 = s1;
19236
20001
  return s0;
19237
20002
  }
19238
20003
  function peg$parsecode_L() {
19239
20004
  var s0, s1, s2, s3, s4, s5, s6, s7, s8, s9, s10;
19240
20005
  s0 = peg$currPos;
19241
- s1 = peg$parsestart_code();
20006
+ s1 = peg$parsestart_code_2();
19242
20007
  if (s1 !== peg$FAILED) {
19243
20008
  peg$savedPos = peg$currPos;
19244
- s2 = peg$c57(s1);
20009
+ s2 = peg$c64(s1);
19245
20010
  if (s2) {
19246
20011
  s2 = void 0;
19247
20012
  } else {
@@ -19344,7 +20109,7 @@ var require_grammarfc = __commonJS({
19344
20109
  }
19345
20110
  if (s6 !== peg$FAILED) {
19346
20111
  peg$savedPos = s4;
19347
- s5 = peg$c58(s1, s3, s6);
20112
+ s5 = peg$c65(s1, s3, s6);
19348
20113
  s4 = s5;
19349
20114
  } else {
19350
20115
  peg$currPos = s4;
@@ -19360,9 +20125,21 @@ var require_grammarfc = __commonJS({
19360
20125
  if (s4 !== peg$FAILED) {
19361
20126
  s5 = peg$parseend_code();
19362
20127
  if (s5 !== peg$FAILED) {
19363
- peg$savedPos = s0;
19364
- s1 = peg$c59(s1, s3, s4);
19365
- s0 = s1;
20128
+ peg$savedPos = peg$currPos;
20129
+ s6 = peg$c66(s1, s3, s4, s5);
20130
+ if (s6) {
20131
+ s6 = void 0;
20132
+ } else {
20133
+ s6 = peg$FAILED;
20134
+ }
20135
+ if (s6 !== peg$FAILED) {
20136
+ peg$savedPos = s0;
20137
+ s1 = peg$c67(s1, s3, s4, s5);
20138
+ s0 = s1;
20139
+ } else {
20140
+ peg$currPos = s0;
20141
+ s0 = peg$FAILED;
20142
+ }
19366
20143
  } else {
19367
20144
  peg$currPos = s0;
19368
20145
  s0 = peg$FAILED;
@@ -19393,12 +20170,12 @@ var require_grammarfc = __commonJS({
19393
20170
  s3 = peg$currPos;
19394
20171
  peg$silentFails++;
19395
20172
  if (input.charCodeAt(peg$currPos) === 59) {
19396
- s4 = peg$c60;
20173
+ s4 = peg$c68;
19397
20174
  peg$currPos++;
19398
20175
  } else {
19399
20176
  s4 = peg$FAILED;
19400
20177
  if (peg$silentFails === 0) {
19401
- peg$fail(peg$c61);
20178
+ peg$fail(peg$c69);
19402
20179
  }
19403
20180
  }
19404
20181
  peg$silentFails--;
@@ -19451,12 +20228,12 @@ var require_grammarfc = __commonJS({
19451
20228
  s3 = peg$currPos;
19452
20229
  peg$silentFails++;
19453
20230
  if (input.charCodeAt(peg$currPos) === 59) {
19454
- s4 = peg$c60;
20231
+ s4 = peg$c68;
19455
20232
  peg$currPos++;
19456
20233
  } else {
19457
20234
  s4 = peg$FAILED;
19458
20235
  if (peg$silentFails === 0) {
19459
- peg$fail(peg$c61);
20236
+ peg$fail(peg$c69);
19460
20237
  }
19461
20238
  }
19462
20239
  peg$silentFails--;
@@ -19515,13 +20292,13 @@ var require_grammarfc = __commonJS({
19515
20292
  }
19516
20293
  function peg$parsehs() {
19517
20294
  var s0;
19518
- if (peg$c62.test(input.charAt(peg$currPos))) {
20295
+ if (peg$c70.test(input.charAt(peg$currPos))) {
19519
20296
  s0 = input.charAt(peg$currPos);
19520
20297
  peg$currPos++;
19521
20298
  } else {
19522
20299
  s0 = peg$FAILED;
19523
20300
  if (peg$silentFails === 0) {
19524
- peg$fail(peg$c63);
20301
+ peg$fail(peg$c71);
19525
20302
  }
19526
20303
  }
19527
20304
  return s0;
@@ -19539,12 +20316,12 @@ var require_grammarfc = __commonJS({
19539
20316
  }
19540
20317
  if (s2 !== peg$FAILED) {
19541
20318
  if (input.charCodeAt(peg$currPos) === 59) {
19542
- s3 = peg$c60;
20319
+ s3 = peg$c68;
19543
20320
  peg$currPos++;
19544
20321
  } else {
19545
20322
  s3 = peg$FAILED;
19546
20323
  if (peg$silentFails === 0) {
19547
- peg$fail(peg$c61);
20324
+ peg$fail(peg$c69);
19548
20325
  }
19549
20326
  }
19550
20327
  if (s3 !== peg$FAILED) {
@@ -19558,7 +20335,7 @@ var require_grammarfc = __commonJS({
19558
20335
  s5 = peg$parsearray_items();
19559
20336
  if (s5 !== peg$FAILED) {
19560
20337
  peg$savedPos = s0;
19561
- s1 = peg$c64(s1, s5);
20338
+ s1 = peg$c72(s1, s5);
19562
20339
  s0 = s1;
19563
20340
  } else {
19564
20341
  peg$currPos = s0;
@@ -19585,7 +20362,7 @@ var require_grammarfc = __commonJS({
19585
20362
  s1 = peg$parseitem();
19586
20363
  if (s1 !== peg$FAILED) {
19587
20364
  peg$savedPos = s0;
19588
- s1 = peg$c65(s1);
20365
+ s1 = peg$c73(s1);
19589
20366
  }
19590
20367
  s0 = s1;
19591
20368
  }
@@ -19597,7 +20374,7 @@ var require_grammarfc = __commonJS({
19597
20374
  s1 = peg$parsestart_code();
19598
20375
  if (s1 !== peg$FAILED) {
19599
20376
  peg$savedPos = peg$currPos;
19600
- s2 = peg$c66(s1);
20377
+ s2 = peg$c74(s1);
19601
20378
  if (s2) {
19602
20379
  s2 = void 0;
19603
20380
  } else {
@@ -19639,7 +20416,7 @@ var require_grammarfc = __commonJS({
19639
20416
  s5 = peg$parseend_code();
19640
20417
  if (s5 !== peg$FAILED) {
19641
20418
  peg$savedPos = s0;
19642
- s1 = peg$c67(s1, s3, s4);
20419
+ s1 = peg$c75(s1, s3, s4);
19643
20420
  s0 = s1;
19644
20421
  } else {
19645
20422
  peg$currPos = s0;
@@ -19669,7 +20446,7 @@ var require_grammarfc = __commonJS({
19669
20446
  s1 = peg$parsestart_code();
19670
20447
  if (s1 !== peg$FAILED) {
19671
20448
  peg$savedPos = peg$currPos;
19672
- s2 = peg$c68(s1);
20449
+ s2 = peg$c76(s1);
19673
20450
  if (s2) {
19674
20451
  s2 = void 0;
19675
20452
  } else {
@@ -19780,7 +20557,7 @@ var require_grammarfc = __commonJS({
19780
20557
  s1 = peg$parsestart_code();
19781
20558
  if (s1 !== peg$FAILED) {
19782
20559
  peg$savedPos = peg$currPos;
19783
- s2 = peg$c69(s1);
20560
+ s2 = peg$c77(s1);
19784
20561
  if (s2) {
19785
20562
  s2 = void 0;
19786
20563
  } else {
@@ -19889,25 +20666,25 @@ var require_grammarfc = __commonJS({
19889
20666
  var s0, s1, s2;
19890
20667
  s0 = peg$currPos;
19891
20668
  s1 = [];
19892
- if (peg$c70.test(input.charAt(peg$currPos))) {
20669
+ if (peg$c78.test(input.charAt(peg$currPos))) {
19893
20670
  s2 = input.charAt(peg$currPos);
19894
20671
  peg$currPos++;
19895
20672
  } else {
19896
20673
  s2 = peg$FAILED;
19897
20674
  if (peg$silentFails === 0) {
19898
- peg$fail(peg$c71);
20675
+ peg$fail(peg$c79);
19899
20676
  }
19900
20677
  }
19901
20678
  if (s2 !== peg$FAILED) {
19902
20679
  while (s2 !== peg$FAILED) {
19903
20680
  s1.push(s2);
19904
- if (peg$c70.test(input.charAt(peg$currPos))) {
20681
+ if (peg$c78.test(input.charAt(peg$currPos))) {
19905
20682
  s2 = input.charAt(peg$currPos);
19906
20683
  peg$currPos++;
19907
20684
  } else {
19908
20685
  s2 = peg$FAILED;
19909
20686
  if (peg$silentFails === 0) {
19910
- peg$fail(peg$c71);
20687
+ peg$fail(peg$c79);
19911
20688
  }
19912
20689
  }
19913
20690
  }
@@ -19924,20 +20701,20 @@ var require_grammarfc = __commonJS({
19924
20701
  function peg$parsedecimalNumber() {
19925
20702
  var s0, s1, s2;
19926
20703
  s0 = peg$currPos;
19927
- if (input.substr(peg$currPos, 2) === peg$c72) {
19928
- s1 = peg$c72;
20704
+ if (input.substr(peg$currPos, 2) === peg$c80) {
20705
+ s1 = peg$c80;
19929
20706
  peg$currPos += 2;
19930
20707
  } else {
19931
20708
  s1 = peg$FAILED;
19932
20709
  if (peg$silentFails === 0) {
19933
- peg$fail(peg$c73);
20710
+ peg$fail(peg$c81);
19934
20711
  }
19935
20712
  }
19936
20713
  if (s1 !== peg$FAILED) {
19937
20714
  s2 = peg$parsenumber();
19938
20715
  if (s2 !== peg$FAILED) {
19939
20716
  peg$savedPos = s0;
19940
- s1 = peg$c74(s2);
20717
+ s1 = peg$c82(s2);
19941
20718
  s0 = s1;
19942
20719
  } else {
19943
20720
  peg$currPos = s0;
@@ -19952,20 +20729,20 @@ var require_grammarfc = __commonJS({
19952
20729
  function peg$parseoctalNumber() {
19953
20730
  var s0, s1, s2;
19954
20731
  s0 = peg$currPos;
19955
- if (input.substr(peg$currPos, 2) === peg$c75) {
19956
- s1 = peg$c75;
20732
+ if (input.substr(peg$currPos, 2) === peg$c83) {
20733
+ s1 = peg$c83;
19957
20734
  peg$currPos += 2;
19958
20735
  } else {
19959
20736
  s1 = peg$FAILED;
19960
20737
  if (peg$silentFails === 0) {
19961
- peg$fail(peg$c76);
20738
+ peg$fail(peg$c84);
19962
20739
  }
19963
20740
  }
19964
20741
  if (s1 !== peg$FAILED) {
19965
20742
  s2 = peg$parsenumber();
19966
20743
  if (s2 !== peg$FAILED) {
19967
20744
  peg$savedPos = s0;
19968
- s1 = peg$c77(s2);
20745
+ s1 = peg$c85(s2);
19969
20746
  s0 = s1;
19970
20747
  } else {
19971
20748
  peg$currPos = s0;
@@ -19980,20 +20757,20 @@ var require_grammarfc = __commonJS({
19980
20757
  function peg$parsebinaryNumber() {
19981
20758
  var s0, s1, s2;
19982
20759
  s0 = peg$currPos;
19983
- if (input.substr(peg$currPos, 2) === peg$c78) {
19984
- s1 = peg$c78;
20760
+ if (input.substr(peg$currPos, 2) === peg$c86) {
20761
+ s1 = peg$c86;
19985
20762
  peg$currPos += 2;
19986
20763
  } else {
19987
20764
  s1 = peg$FAILED;
19988
20765
  if (peg$silentFails === 0) {
19989
- peg$fail(peg$c79);
20766
+ peg$fail(peg$c87);
19990
20767
  }
19991
20768
  }
19992
20769
  if (s1 !== peg$FAILED) {
19993
20770
  s2 = peg$parsenumber();
19994
20771
  if (s2 !== peg$FAILED) {
19995
20772
  peg$savedPos = s0;
19996
- s1 = peg$c80(s2);
20773
+ s1 = peg$c88(s2);
19997
20774
  s0 = s1;
19998
20775
  } else {
19999
20776
  peg$currPos = s0;
@@ -20010,36 +20787,36 @@ var require_grammarfc = __commonJS({
20010
20787
  s0 = peg$currPos;
20011
20788
  s1 = peg$currPos;
20012
20789
  s2 = peg$currPos;
20013
- if (input.substr(peg$currPos, 2) === peg$c81) {
20014
- s3 = peg$c81;
20790
+ if (input.substr(peg$currPos, 2) === peg$c89) {
20791
+ s3 = peg$c89;
20015
20792
  peg$currPos += 2;
20016
20793
  } else {
20017
20794
  s3 = peg$FAILED;
20018
20795
  if (peg$silentFails === 0) {
20019
- peg$fail(peg$c82);
20796
+ peg$fail(peg$c90);
20020
20797
  }
20021
20798
  }
20022
20799
  if (s3 !== peg$FAILED) {
20023
20800
  s4 = [];
20024
- if (peg$c83.test(input.charAt(peg$currPos))) {
20801
+ if (peg$c91.test(input.charAt(peg$currPos))) {
20025
20802
  s5 = input.charAt(peg$currPos);
20026
20803
  peg$currPos++;
20027
20804
  } else {
20028
20805
  s5 = peg$FAILED;
20029
20806
  if (peg$silentFails === 0) {
20030
- peg$fail(peg$c84);
20807
+ peg$fail(peg$c92);
20031
20808
  }
20032
20809
  }
20033
20810
  if (s5 !== peg$FAILED) {
20034
20811
  while (s5 !== peg$FAILED) {
20035
20812
  s4.push(s5);
20036
- if (peg$c83.test(input.charAt(peg$currPos))) {
20813
+ if (peg$c91.test(input.charAt(peg$currPos))) {
20037
20814
  s5 = input.charAt(peg$currPos);
20038
20815
  peg$currPos++;
20039
20816
  } else {
20040
20817
  s5 = peg$FAILED;
20041
20818
  if (peg$silentFails === 0) {
20042
- peg$fail(peg$c84);
20819
+ peg$fail(peg$c92);
20043
20820
  }
20044
20821
  }
20045
20822
  }
@@ -20064,7 +20841,7 @@ var require_grammarfc = __commonJS({
20064
20841
  }
20065
20842
  if (s1 !== peg$FAILED) {
20066
20843
  peg$savedPos = s0;
20067
- s1 = peg$c85();
20844
+ s1 = peg$c93();
20068
20845
  }
20069
20846
  s0 = s1;
20070
20847
  return s0;
@@ -20089,7 +20866,7 @@ var require_grammarfc = __commonJS({
20089
20866
  }
20090
20867
  if (s2 !== peg$FAILED) {
20091
20868
  peg$savedPos = s0;
20092
- s1 = peg$c86(s2);
20869
+ s1 = peg$c94(s2);
20093
20870
  s0 = s1;
20094
20871
  } else {
20095
20872
  peg$currPos = s0;
@@ -20114,12 +20891,12 @@ var require_grammarfc = __commonJS({
20114
20891
  }
20115
20892
  if (s2 !== peg$FAILED) {
20116
20893
  if (input.charCodeAt(peg$currPos) === 59) {
20117
- s3 = peg$c60;
20894
+ s3 = peg$c68;
20118
20895
  peg$currPos++;
20119
20896
  } else {
20120
20897
  s3 = peg$FAILED;
20121
20898
  if (peg$silentFails === 0) {
20122
- peg$fail(peg$c61);
20899
+ peg$fail(peg$c69);
20123
20900
  }
20124
20901
  }
20125
20902
  if (s3 !== peg$FAILED) {
@@ -20133,7 +20910,7 @@ var require_grammarfc = __commonJS({
20133
20910
  s5 = peg$parsearray_E_items();
20134
20911
  if (s5 !== peg$FAILED) {
20135
20912
  peg$savedPos = s0;
20136
- s1 = peg$c64(s1, s5);
20913
+ s1 = peg$c72(s1, s5);
20137
20914
  s0 = s1;
20138
20915
  } else {
20139
20916
  peg$currPos = s0;
@@ -20160,7 +20937,7 @@ var require_grammarfc = __commonJS({
20160
20937
  s1 = peg$parseitem_E();
20161
20938
  if (s1 !== peg$FAILED) {
20162
20939
  peg$savedPos = s0;
20163
- s1 = peg$c65(s1);
20940
+ s1 = peg$c73(s1);
20164
20941
  }
20165
20942
  s0 = s1;
20166
20943
  }
@@ -20172,7 +20949,7 @@ var require_grammarfc = __commonJS({
20172
20949
  s1 = peg$parsestart_code();
20173
20950
  if (s1 !== peg$FAILED) {
20174
20951
  peg$savedPos = peg$currPos;
20175
- s2 = peg$c87(s1);
20952
+ s2 = peg$c95(s1);
20176
20953
  if (s2) {
20177
20954
  s2 = void 0;
20178
20955
  } else {
@@ -20183,7 +20960,7 @@ var require_grammarfc = __commonJS({
20183
20960
  s4 = peg$parsearray_E_items();
20184
20961
  if (s4 !== peg$FAILED) {
20185
20962
  peg$savedPos = s3;
20186
- s4 = peg$c88(s1, s4);
20963
+ s4 = peg$c96(s1, s4);
20187
20964
  }
20188
20965
  s3 = s4;
20189
20966
  if (s3 === peg$FAILED) {
@@ -20193,7 +20970,7 @@ var require_grammarfc = __commonJS({
20193
20970
  s4 = peg$parseend_code();
20194
20971
  if (s4 !== peg$FAILED) {
20195
20972
  peg$savedPos = s0;
20196
- s1 = peg$c89(s1, s3);
20973
+ s1 = peg$c97(s1, s3);
20197
20974
  s0 = s1;
20198
20975
  } else {
20199
20976
  peg$currPos = s0;
@@ -20235,7 +21012,58 @@ var require_grammarfc = __commonJS({
20235
21012
  }
20236
21013
  if (s2 !== peg$FAILED) {
20237
21014
  peg$savedPos = s0;
20238
- s1 = peg$c90(s1);
21015
+ s1 = peg$c98(s1);
21016
+ s0 = s1;
21017
+ } else {
21018
+ peg$currPos = s0;
21019
+ s0 = peg$FAILED;
21020
+ }
21021
+ } else {
21022
+ peg$currPos = s0;
21023
+ s0 = peg$FAILED;
21024
+ }
21025
+ return s0;
21026
+ }
21027
+ function peg$parsestart_code_2() {
21028
+ var s0, s1, s2, s3;
21029
+ s0 = peg$currPos;
21030
+ s1 = peg$currPos;
21031
+ s2 = peg$parseallowed_code();
21032
+ if (s2 !== peg$FAILED) {
21033
+ s1 = input.substring(s1, peg$currPos);
21034
+ } else {
21035
+ s1 = s2;
21036
+ }
21037
+ if (s1 !== peg$FAILED) {
21038
+ s2 = peg$currPos;
21039
+ if (input.charCodeAt(peg$currPos) === 60) {
21040
+ s3 = peg$c48;
21041
+ peg$currPos++;
21042
+ } else {
21043
+ s3 = peg$FAILED;
21044
+ if (peg$silentFails === 0) {
21045
+ peg$fail(peg$c49);
21046
+ }
21047
+ }
21048
+ if (s3 === peg$FAILED) {
21049
+ if (input.charCodeAt(peg$currPos) === 171) {
21050
+ s3 = peg$c53;
21051
+ peg$currPos++;
21052
+ } else {
21053
+ s3 = peg$FAILED;
21054
+ if (peg$silentFails === 0) {
21055
+ peg$fail(peg$c54);
21056
+ }
21057
+ }
21058
+ }
21059
+ if (s3 !== peg$FAILED) {
21060
+ s2 = input.substring(s2, peg$currPos);
21061
+ } else {
21062
+ s2 = s3;
21063
+ }
21064
+ if (s2 !== peg$FAILED) {
21065
+ peg$savedPos = s0;
21066
+ s1 = peg$c99(s1, s2);
20239
21067
  s0 = s1;
20240
21068
  } else {
20241
21069
  peg$currPos = s0;
@@ -20258,15 +21086,26 @@ var require_grammarfc = __commonJS({
20258
21086
  peg$fail(peg$c51);
20259
21087
  }
20260
21088
  }
21089
+ if (s0 === peg$FAILED) {
21090
+ if (input.charCodeAt(peg$currPos) === 187) {
21091
+ s0 = peg$c55;
21092
+ peg$currPos++;
21093
+ } else {
21094
+ s0 = peg$FAILED;
21095
+ if (peg$silentFails === 0) {
21096
+ peg$fail(peg$c56);
21097
+ }
21098
+ }
21099
+ }
20261
21100
  return s0;
20262
21101
  }
20263
- function peg$parsecode() {
20264
- var s0, s1, s2, s3, s4;
21102
+ function peg$parsecode_2() {
21103
+ var s0, s1, s2, s3, s4, s5;
20265
21104
  s0 = peg$currPos;
20266
- s1 = peg$parsestart_code();
21105
+ s1 = peg$parsestart_code_2();
20267
21106
  if (s1 !== peg$FAILED) {
20268
21107
  peg$savedPos = peg$currPos;
20269
- s2 = peg$c91(s1);
21108
+ s2 = peg$c100(s1);
20270
21109
  if (s2) {
20271
21110
  s2 = void 0;
20272
21111
  } else {
@@ -20276,7 +21115,7 @@ var require_grammarfc = __commonJS({
20276
21115
  s3 = [];
20277
21116
  s4 = peg$parseallowed_rules();
20278
21117
  if (s4 === peg$FAILED) {
20279
- s4 = peg$parsecode();
21118
+ s4 = peg$parsecode_2();
20280
21119
  if (s4 === peg$FAILED) {
20281
21120
  s4 = peg$parsetext();
20282
21121
  }
@@ -20285,7 +21124,7 @@ var require_grammarfc = __commonJS({
20285
21124
  s3.push(s4);
20286
21125
  s4 = peg$parseallowed_rules();
20287
21126
  if (s4 === peg$FAILED) {
20288
- s4 = peg$parsecode();
21127
+ s4 = peg$parsecode_2();
20289
21128
  if (s4 === peg$FAILED) {
20290
21129
  s4 = peg$parsetext();
20291
21130
  }
@@ -20294,9 +21133,21 @@ var require_grammarfc = __commonJS({
20294
21133
  if (s3 !== peg$FAILED) {
20295
21134
  s4 = peg$parseend_code();
20296
21135
  if (s4 !== peg$FAILED) {
20297
- peg$savedPos = s0;
20298
- s1 = peg$c92(s1, s3);
20299
- s0 = s1;
21136
+ peg$savedPos = peg$currPos;
21137
+ s5 = peg$c101(s1, s3, s4);
21138
+ if (s5) {
21139
+ s5 = void 0;
21140
+ } else {
21141
+ s5 = peg$FAILED;
21142
+ }
21143
+ if (s5 !== peg$FAILED) {
21144
+ peg$savedPos = s0;
21145
+ s1 = peg$c102(s1, s3, s4);
21146
+ s0 = s1;
21147
+ } else {
21148
+ peg$currPos = s0;
21149
+ s0 = peg$FAILED;
21150
+ }
20300
21151
  } else {
20301
21152
  peg$currPos = s0;
20302
21153
  s0 = peg$FAILED;
@@ -20436,9 +21287,48 @@ var require_grammarfc = __commonJS({
20436
21287
  s3 = peg$FAILED;
20437
21288
  }
20438
21289
  if (s3 === peg$FAILED) {
20439
- s3 = peg$parselooks_like_code();
21290
+ s3 = peg$currPos;
21291
+ if (input.charCodeAt(peg$currPos) === 171) {
21292
+ s4 = peg$c53;
21293
+ peg$currPos++;
21294
+ } else {
21295
+ s4 = peg$FAILED;
21296
+ if (peg$silentFails === 0) {
21297
+ peg$fail(peg$c54);
21298
+ }
21299
+ }
21300
+ if (s4 !== peg$FAILED) {
21301
+ s5 = peg$parsetext();
21302
+ if (s5 !== peg$FAILED) {
21303
+ if (input.charCodeAt(peg$currPos) === 187) {
21304
+ s6 = peg$c55;
21305
+ peg$currPos++;
21306
+ } else {
21307
+ s6 = peg$FAILED;
21308
+ if (peg$silentFails === 0) {
21309
+ peg$fail(peg$c56);
21310
+ }
21311
+ }
21312
+ if (s6 !== peg$FAILED) {
21313
+ s4 = [s4, s5, s6];
21314
+ s3 = s4;
21315
+ } else {
21316
+ peg$currPos = s3;
21317
+ s3 = peg$FAILED;
21318
+ }
21319
+ } else {
21320
+ peg$currPos = s3;
21321
+ s3 = peg$FAILED;
21322
+ }
21323
+ } else {
21324
+ peg$currPos = s3;
21325
+ s3 = peg$FAILED;
21326
+ }
20440
21327
  if (s3 === peg$FAILED) {
20441
- s3 = peg$parsenot_code();
21328
+ s3 = peg$parselooks_like_code();
21329
+ if (s3 === peg$FAILED) {
21330
+ s3 = peg$parsenot_code();
21331
+ }
20442
21332
  }
20443
21333
  }
20444
21334
  if (s3 !== peg$FAILED) {
@@ -20482,9 +21372,48 @@ var require_grammarfc = __commonJS({
20482
21372
  s3 = peg$FAILED;
20483
21373
  }
20484
21374
  if (s3 === peg$FAILED) {
20485
- s3 = peg$parselooks_like_code();
21375
+ s3 = peg$currPos;
21376
+ if (input.charCodeAt(peg$currPos) === 171) {
21377
+ s4 = peg$c53;
21378
+ peg$currPos++;
21379
+ } else {
21380
+ s4 = peg$FAILED;
21381
+ if (peg$silentFails === 0) {
21382
+ peg$fail(peg$c54);
21383
+ }
21384
+ }
21385
+ if (s4 !== peg$FAILED) {
21386
+ s5 = peg$parsetext();
21387
+ if (s5 !== peg$FAILED) {
21388
+ if (input.charCodeAt(peg$currPos) === 187) {
21389
+ s6 = peg$c55;
21390
+ peg$currPos++;
21391
+ } else {
21392
+ s6 = peg$FAILED;
21393
+ if (peg$silentFails === 0) {
21394
+ peg$fail(peg$c56);
21395
+ }
21396
+ }
21397
+ if (s6 !== peg$FAILED) {
21398
+ s4 = [s4, s5, s6];
21399
+ s3 = s4;
21400
+ } else {
21401
+ peg$currPos = s3;
21402
+ s3 = peg$FAILED;
21403
+ }
21404
+ } else {
21405
+ peg$currPos = s3;
21406
+ s3 = peg$FAILED;
21407
+ }
21408
+ } else {
21409
+ peg$currPos = s3;
21410
+ s3 = peg$FAILED;
21411
+ }
20486
21412
  if (s3 === peg$FAILED) {
20487
- s3 = peg$parsenot_code();
21413
+ s3 = peg$parselooks_like_code();
21414
+ if (s3 === peg$FAILED) {
21415
+ s3 = peg$parsenot_code();
21416
+ }
20488
21417
  }
20489
21418
  }
20490
21419
  }
@@ -20498,7 +21427,7 @@ var require_grammarfc = __commonJS({
20498
21427
  }
20499
21428
  if (s1 !== peg$FAILED) {
20500
21429
  peg$savedPos = s0;
20501
- s1 = peg$c53(s1);
21430
+ s1 = peg$c57(s1);
20502
21431
  }
20503
21432
  s0 = s1;
20504
21433
  return s0;
@@ -20522,7 +21451,7 @@ var require_grammarfc = __commonJS({
20522
21451
  if (s4 !== peg$FAILED) {
20523
21452
  s5 = peg$currPos;
20524
21453
  peg$silentFails++;
20525
- s6 = peg$parsestart_code();
21454
+ s6 = peg$parsestart_code_2();
20526
21455
  peg$silentFails--;
20527
21456
  if (s6 === peg$FAILED) {
20528
21457
  s5 = void 0;
@@ -20587,7 +21516,7 @@ var require_grammarfc = __commonJS({
20587
21516
  if (s4 !== peg$FAILED) {
20588
21517
  s5 = peg$currPos;
20589
21518
  peg$silentFails++;
20590
- s6 = peg$parsestart_code();
21519
+ s6 = peg$parsestart_code_2();
20591
21520
  peg$silentFails--;
20592
21521
  if (s6 === peg$FAILED) {
20593
21522
  s5 = void 0;
@@ -20646,7 +21575,7 @@ var require_grammarfc = __commonJS({
20646
21575
  }
20647
21576
  if (s1 !== peg$FAILED) {
20648
21577
  peg$savedPos = s0;
20649
- s1 = peg$c53(s1);
21578
+ s1 = peg$c57(s1);
20650
21579
  }
20651
21580
  s0 = s1;
20652
21581
  return s0;
@@ -20728,11 +21657,92 @@ var require_grammarfc = __commonJS({
20728
21657
  peg$currPos = s0;
20729
21658
  s0 = peg$FAILED;
20730
21659
  }
21660
+ if (s0 === peg$FAILED) {
21661
+ s0 = peg$currPos;
21662
+ s1 = peg$currPos;
21663
+ s2 = peg$currPos;
21664
+ peg$silentFails++;
21665
+ s3 = peg$parseallowed_code();
21666
+ peg$silentFails--;
21667
+ if (s3 === peg$FAILED) {
21668
+ s2 = void 0;
21669
+ } else {
21670
+ peg$currPos = s2;
21671
+ s2 = peg$FAILED;
21672
+ }
21673
+ if (s2 !== peg$FAILED) {
21674
+ if (input.length > peg$currPos) {
21675
+ s3 = input.charAt(peg$currPos);
21676
+ peg$currPos++;
21677
+ } else {
21678
+ s3 = peg$FAILED;
21679
+ if (peg$silentFails === 0) {
21680
+ peg$fail(peg$c39);
21681
+ }
21682
+ }
21683
+ if (s3 !== peg$FAILED) {
21684
+ s2 = [s2, s3];
21685
+ s1 = s2;
21686
+ } else {
21687
+ peg$currPos = s1;
21688
+ s1 = peg$FAILED;
21689
+ }
21690
+ } else {
21691
+ peg$currPos = s1;
21692
+ s1 = peg$FAILED;
21693
+ }
21694
+ if (s1 !== peg$FAILED) {
21695
+ if (input.charCodeAt(peg$currPos) === 171) {
21696
+ s2 = peg$c53;
21697
+ peg$currPos++;
21698
+ } else {
21699
+ s2 = peg$FAILED;
21700
+ if (peg$silentFails === 0) {
21701
+ peg$fail(peg$c54);
21702
+ }
21703
+ }
21704
+ if (s2 !== peg$FAILED) {
21705
+ s3 = peg$parsenot_code();
21706
+ if (s3 !== peg$FAILED) {
21707
+ if (input.charCodeAt(peg$currPos) === 187) {
21708
+ s4 = peg$c55;
21709
+ peg$currPos++;
21710
+ } else {
21711
+ s4 = peg$FAILED;
21712
+ if (peg$silentFails === 0) {
21713
+ peg$fail(peg$c56);
21714
+ }
21715
+ }
21716
+ if (s4 !== peg$FAILED) {
21717
+ peg$savedPos = s0;
21718
+ s1 = peg$c52();
21719
+ s0 = s1;
21720
+ } else {
21721
+ peg$currPos = s0;
21722
+ s0 = peg$FAILED;
21723
+ }
21724
+ } else {
21725
+ peg$currPos = s0;
21726
+ s0 = peg$FAILED;
21727
+ }
21728
+ } else {
21729
+ peg$currPos = s0;
21730
+ s0 = peg$FAILED;
21731
+ }
21732
+ } else {
21733
+ peg$currPos = s0;
21734
+ s0 = peg$FAILED;
21735
+ }
21736
+ }
20731
21737
  return s0;
20732
21738
  }
20733
21739
  function flattenDeep5(arr) {
20734
21740
  return arr.reduce((acc, val) => Array.isArray(val) ? acc.concat(flattenDeep5(val)) : acc.concat(val), []);
20735
21741
  }
21742
+ function get_pair_tag(tag) {
21743
+ const map = {"<": ">", "\xAB": "\xBB", ">": "<", "\xBB": "\xAB"};
21744
+ return map[tag];
21745
+ }
20736
21746
  peg$result = peg$startRuleFunction();
20737
21747
  if (peg$result !== peg$FAILED && peg$currPos === input.length) {
20738
21748
  return peg$result;
@@ -20755,14 +21765,15 @@ var require_package = __commonJS({
20755
21765
  "../podlite-schema/package.json"(exports, module2) {
20756
21766
  module2.exports = {
20757
21767
  name: "@podlite/schema",
20758
- version: "0.0.13",
20759
- description: "podlite schema",
20760
- main: "src/index.ts",
21768
+ version: "0.0.15",
21769
+ description: "AST tools for Podlite markup language",
21770
+ main: "./src/index.ts",
20761
21771
  types: "./lib/index.d.ts",
20762
21772
  license: "MIT",
20763
21773
  files: [
20764
21774
  "lib/**/*.js",
20765
21775
  "lib/**/*.d.ts",
21776
+ "esm",
20766
21777
  "schema/*",
20767
21778
  "README.md",
20768
21779
  "CHANGELOG.md"
@@ -20774,16 +21785,17 @@ var require_package = __commonJS({
20774
21785
  publishConfig: {
20775
21786
  access: "public",
20776
21787
  main: "lib/index.js",
20777
- types: "./lib/index.d.ts"
21788
+ types: "./lib/index.d.ts",
21789
+ module: "./esm/index.js"
20778
21790
  },
20779
21791
  scripts: {
20780
- clean: "rm -rf lib esm tsconfig.tsbuildinfo",
20781
- build: "run-s build:pegjs build:ts build:ast ",
21792
+ clean: "rm -rf lib esm *.tsbuildinfo",
21793
+ build: "run-s build:pegjs build_lib build:ast ",
21794
+ build_lib: "yarn g:build",
20782
21795
  "build:ast": "ts-node scripts/make-ast-scheme.ts",
20783
- "build:ts": "yarn g:tsc --build $INIT_CWD",
20784
- "build:esm": "yarn g:tsctest -p tsconfig.esm.json",
20785
21796
  "build:pegjs": "pegjs -o src/grammar.js src/grammar.pegjs && pegjs -o src/grammarfc.js src/grammarfc.pegjs",
20786
21797
  watch: "npx nodemon -e js,ts --exec 'yarn' build",
21798
+ "watch:pegjs": "npx nodemon -e pegjs --exec 'yarn' build:pegjs",
20787
21799
  test: "yarn g:jest --passWithNoTests"
20788
21800
  },
20789
21801
  keywords: [
@@ -20974,33 +21986,33 @@ Everything else 57
20974
21986
  `
20975
21987
  },
20976
21988
  {
20977
- displayText: "Toc head1, head2, head3",
20978
- text: `=Toc head1, head2, head3
21989
+ displayText: "toc head1, head2, head3",
21990
+ text: `=toc head1, head2, head3
20979
21991
  `
20980
21992
  },
20981
21993
  {
20982
- displayText: "Toc (with :title) \u{1F3F7}",
20983
- text: `=for Toc :title('Table of contents')
21994
+ displayText: "toc (with :title) \u{1F3F7}",
21995
+ text: `=for toc :title('Table of contents')
20984
21996
  head1, head2, head3
20985
21997
 
20986
21998
  `
20987
21999
  },
20988
22000
  {
20989
- displayText: "Toc ( Images, Diagrams ) + tables \u{1F3F7}",
20990
- text: `=for Toc :title('List of media')
22001
+ displayText: "toc ( Images, Diagrams ) + tables \u{1F3F7}",
22002
+ text: `=for toc :title('List of media')
20991
22003
  Image, Diagram
20992
- =for Toc :title('List of tables')
22004
+ =for toc :title('List of tables')
20993
22005
  table
20994
22006
 
20995
22007
  `
20996
22008
  },
20997
22009
  {
20998
- displayText: "Markdown",
20999
- text: `=begin Markdown
22010
+ displayText: "markdown",
22011
+ text: `=begin markdown
21000
22012
 
21001
22013
  {}
21002
22014
 
21003
- =end Markdown
22015
+ =end markdown
21004
22016
  `
21005
22017
  },
21006
22018
  {
@@ -21862,8 +22874,9 @@ var middle2 = () => (tree) => {
21862
22874
  const conf = config_default(n, ctx);
21863
22875
  const isCodeBlock = "name" in n && n.name === "code";
21864
22876
  const isDataBlock = "name" in n && n.name === "data";
22877
+ const isMarkdownBlock = "name" in n && n.name === "markdown";
21865
22878
  const allowValues = conf.getAllValues("allow");
21866
- if ((isCodeBlock || isDataBlock) && allowValues.length == 0)
22879
+ if ((isCodeBlock || isDataBlock || isMarkdownBlock) && allowValues.length == 0)
21867
22880
  return n;
21868
22881
  const allowed = allowValues.sort();
21869
22882
  const transformer = makeTransformer_default({