@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.esm.js CHANGED
@@ -7016,6 +7016,12 @@ var require_AstTree = __commonJS({
7016
7016
  {
7017
7017
  $ref: "#/definitions/BlockCode"
7018
7018
  },
7019
+ {
7020
+ $ref: "#/definitions/BlockToc"
7021
+ },
7022
+ {
7023
+ $ref: "#/definitions/BlockMarkdown"
7024
+ },
7019
7025
  {
7020
7026
  $ref: "#/definitions/BlockNested"
7021
7027
  },
@@ -8067,6 +8073,12 @@ var require_AstTree = __commonJS({
8067
8073
  {
8068
8074
  $ref: "#/definitions/BlockCode"
8069
8075
  },
8076
+ {
8077
+ $ref: "#/definitions/BlockToc"
8078
+ },
8079
+ {
8080
+ $ref: "#/definitions/BlockMarkdown"
8081
+ },
8070
8082
  {
8071
8083
  $ref: "#/definitions/BlockNested"
8072
8084
  },
@@ -8744,6 +8756,110 @@ var require_AstTree = __commonJS({
8744
8756
  "type"
8745
8757
  ]
8746
8758
  },
8759
+ BlockToc: {
8760
+ type: "object",
8761
+ properties: {
8762
+ name: {
8763
+ type: "string",
8764
+ enum: [
8765
+ "toc"
8766
+ ]
8767
+ },
8768
+ type: {
8769
+ type: "string",
8770
+ enum: [
8771
+ "block"
8772
+ ]
8773
+ },
8774
+ location: {
8775
+ $ref: "#/definitions/Location"
8776
+ },
8777
+ content: {
8778
+ type: "array",
8779
+ items: {
8780
+ $ref: "#/definitions/PodNode"
8781
+ }
8782
+ },
8783
+ margin: {
8784
+ type: "string"
8785
+ },
8786
+ config: {
8787
+ type: "array",
8788
+ items: {
8789
+ anyOf: [
8790
+ {
8791
+ $ref: "#/definitions/BrokenConfigItem"
8792
+ },
8793
+ {
8794
+ $ref: "#/definitions/ConfigItem"
8795
+ }
8796
+ ]
8797
+ }
8798
+ },
8799
+ id: {
8800
+ type: "string"
8801
+ }
8802
+ },
8803
+ required: [
8804
+ "content",
8805
+ "location",
8806
+ "margin",
8807
+ "name",
8808
+ "type"
8809
+ ]
8810
+ },
8811
+ BlockMarkdown: {
8812
+ type: "object",
8813
+ properties: {
8814
+ name: {
8815
+ type: "string",
8816
+ enum: [
8817
+ "markdown"
8818
+ ]
8819
+ },
8820
+ type: {
8821
+ type: "string",
8822
+ enum: [
8823
+ "block"
8824
+ ]
8825
+ },
8826
+ location: {
8827
+ $ref: "#/definitions/Location"
8828
+ },
8829
+ content: {
8830
+ type: "array",
8831
+ items: {
8832
+ $ref: "#/definitions/PodNode"
8833
+ }
8834
+ },
8835
+ margin: {
8836
+ type: "string"
8837
+ },
8838
+ config: {
8839
+ type: "array",
8840
+ items: {
8841
+ anyOf: [
8842
+ {
8843
+ $ref: "#/definitions/BrokenConfigItem"
8844
+ },
8845
+ {
8846
+ $ref: "#/definitions/ConfigItem"
8847
+ }
8848
+ ]
8849
+ }
8850
+ },
8851
+ id: {
8852
+ type: "string"
8853
+ }
8854
+ },
8855
+ required: [
8856
+ "content",
8857
+ "location",
8858
+ "margin",
8859
+ "name",
8860
+ "type"
8861
+ ]
8862
+ },
8747
8863
  BlockNested: {
8748
8864
  type: "object",
8749
8865
  properties: {
@@ -9332,6 +9448,12 @@ var require_PodliteDocument = __commonJS({
9332
9448
  {
9333
9449
  $ref: "#/definitions/BlockCode"
9334
9450
  },
9451
+ {
9452
+ $ref: "#/definitions/BlockToc"
9453
+ },
9454
+ {
9455
+ $ref: "#/definitions/BlockMarkdown"
9456
+ },
9335
9457
  {
9336
9458
  $ref: "#/definitions/BlockNested"
9337
9459
  },
@@ -10383,6 +10505,12 @@ var require_PodliteDocument = __commonJS({
10383
10505
  {
10384
10506
  $ref: "#/definitions/BlockCode"
10385
10507
  },
10508
+ {
10509
+ $ref: "#/definitions/BlockToc"
10510
+ },
10511
+ {
10512
+ $ref: "#/definitions/BlockMarkdown"
10513
+ },
10386
10514
  {
10387
10515
  $ref: "#/definitions/BlockNested"
10388
10516
  },
@@ -11060,6 +11188,110 @@ var require_PodliteDocument = __commonJS({
11060
11188
  "type"
11061
11189
  ]
11062
11190
  },
11191
+ BlockToc: {
11192
+ type: "object",
11193
+ properties: {
11194
+ name: {
11195
+ type: "string",
11196
+ enum: [
11197
+ "toc"
11198
+ ]
11199
+ },
11200
+ type: {
11201
+ type: "string",
11202
+ enum: [
11203
+ "block"
11204
+ ]
11205
+ },
11206
+ location: {
11207
+ $ref: "#/definitions/Location"
11208
+ },
11209
+ content: {
11210
+ type: "array",
11211
+ items: {
11212
+ $ref: "#/definitions/PodNode"
11213
+ }
11214
+ },
11215
+ margin: {
11216
+ type: "string"
11217
+ },
11218
+ config: {
11219
+ type: "array",
11220
+ items: {
11221
+ anyOf: [
11222
+ {
11223
+ $ref: "#/definitions/BrokenConfigItem"
11224
+ },
11225
+ {
11226
+ $ref: "#/definitions/ConfigItem"
11227
+ }
11228
+ ]
11229
+ }
11230
+ },
11231
+ id: {
11232
+ type: "string"
11233
+ }
11234
+ },
11235
+ required: [
11236
+ "content",
11237
+ "location",
11238
+ "margin",
11239
+ "name",
11240
+ "type"
11241
+ ]
11242
+ },
11243
+ BlockMarkdown: {
11244
+ type: "object",
11245
+ properties: {
11246
+ name: {
11247
+ type: "string",
11248
+ enum: [
11249
+ "markdown"
11250
+ ]
11251
+ },
11252
+ type: {
11253
+ type: "string",
11254
+ enum: [
11255
+ "block"
11256
+ ]
11257
+ },
11258
+ location: {
11259
+ $ref: "#/definitions/Location"
11260
+ },
11261
+ content: {
11262
+ type: "array",
11263
+ items: {
11264
+ $ref: "#/definitions/PodNode"
11265
+ }
11266
+ },
11267
+ margin: {
11268
+ type: "string"
11269
+ },
11270
+ config: {
11271
+ type: "array",
11272
+ items: {
11273
+ anyOf: [
11274
+ {
11275
+ $ref: "#/definitions/BrokenConfigItem"
11276
+ },
11277
+ {
11278
+ $ref: "#/definitions/ConfigItem"
11279
+ }
11280
+ ]
11281
+ }
11282
+ },
11283
+ id: {
11284
+ type: "string"
11285
+ }
11286
+ },
11287
+ required: [
11288
+ "content",
11289
+ "location",
11290
+ "margin",
11291
+ "name",
11292
+ "type"
11293
+ ]
11294
+ },
11063
11295
  BlockNested: {
11064
11296
  type: "object",
11065
11297
  properties: {
@@ -11996,7 +12228,7 @@ var require_grammar = __commonJS({
11996
12228
  }, peg$c117 = function(number) {
11997
12229
  return parseInt(number, 10);
11998
12230
  }, peg$c118 = function(vmargin, name, config) {
11999
- return name.match(/code|comment|output|input|data/) || isNamedBlock2(name);
12231
+ return name.match(/code|comment|output|input|markdown|toc|data/) || isNamedBlock2(name);
12000
12232
  }, peg$c119 = function(vmargin, name, config, margins, ename) {
12001
12233
  return vmargin.length === margins.length && name === ename;
12002
12234
  }, peg$c120 = function(vmargin, name, config, margins, line) {
@@ -12145,7 +12377,7 @@ var require_grammar = __commonJS({
12145
12377
  }, peg$c151 = /^[s]/, peg$c152 = peg$classExpectation(["s"], false, false), peg$c153 = function(line) {
12146
12378
  return {text: text(), type: "ambient1"};
12147
12379
  }, peg$c154 = function(vmargin, name) {
12148
- return name.match(/code|comment|output|input|data/) || isNamedBlock2(name);
12380
+ return name.match(/code|comment|output|input|markdown|toc|data/) || isNamedBlock2(name);
12149
12381
  }, peg$c155 = function(vmargin, name, content2) {
12150
12382
  return {
12151
12383
  margin: vmargin,
@@ -12205,7 +12437,7 @@ var require_grammar = __commonJS({
12205
12437
  margin: vmargin
12206
12438
  };
12207
12439
  }, peg$c168 = function(vmargin, marker, name, config) {
12208
- return name.match(/code|comment|output|input|data/) || isNamedBlock2(name);
12440
+ return name.match(/code|comment|output|input|markdown|toc|data/) || isNamedBlock2(name);
12209
12441
  }, peg$c169 = function(vmargin, marker, name, config, content2) {
12210
12442
  return {
12211
12443
  type: "block",
@@ -12999,23 +13231,29 @@ var require_grammar = __commonJS({
12999
13231
  s2 = peg$currPos;
13000
13232
  s3 = peg$parse_();
13001
13233
  if (s3 !== peg$FAILED) {
13002
- s4 = peg$currPos;
13003
- s5 = peg$parsemarkers();
13004
- if (s5 !== peg$FAILED) {
13005
- s6 = peg$parsestrictIdentifier();
13006
- if (s6 !== peg$FAILED) {
13007
- s5 = [s5, s6];
13008
- s4 = s5;
13009
- } else {
13010
- peg$currPos = s4;
13011
- s4 = peg$FAILED;
13012
- }
13013
- } else {
13014
- peg$currPos = s4;
13015
- s4 = peg$FAILED;
13016
- }
13234
+ s4 = peg$parsemarkerConfig();
13017
13235
  if (s4 === peg$FAILED) {
13018
- s4 = peg$parsemarkerAbbreviatedBlock();
13236
+ s4 = peg$parsemarkerAlias();
13237
+ if (s4 === peg$FAILED) {
13238
+ s4 = peg$currPos;
13239
+ s5 = peg$parsemarkers();
13240
+ if (s5 !== peg$FAILED) {
13241
+ s6 = peg$parsestrictIdentifier();
13242
+ if (s6 !== peg$FAILED) {
13243
+ s5 = [s5, s6];
13244
+ s4 = s5;
13245
+ } else {
13246
+ peg$currPos = s4;
13247
+ s4 = peg$FAILED;
13248
+ }
13249
+ } else {
13250
+ peg$currPos = s4;
13251
+ s4 = peg$FAILED;
13252
+ }
13253
+ if (s4 === peg$FAILED) {
13254
+ s4 = peg$parsemarkerAbbreviatedBlock();
13255
+ }
13256
+ }
13019
13257
  }
13020
13258
  if (s4 !== peg$FAILED) {
13021
13259
  s3 = [s3, s4];
@@ -17632,11 +17870,13 @@ var require_grammar = __commonJS({
17632
17870
  "head",
17633
17871
  "input",
17634
17872
  "item",
17873
+ "markdown",
17635
17874
  "nested",
17636
17875
  "output",
17637
17876
  "para",
17638
17877
  "pod",
17639
- "table"
17878
+ "table",
17879
+ "toc"
17640
17880
  ].includes(name) || isSemanticBlock2(name) || name.match(/^(head|item)\d+$/) || isNamedBlock2(name);
17641
17881
  }
17642
17882
  function exludeVMargin(vmargin, string) {
@@ -17792,64 +18032,80 @@ var require_grammarfc = __commonJS({
17792
18032
  };
17793
18033
  }, peg$c48 = "<", peg$c49 = peg$literalExpectation("<", false), peg$c50 = ">", peg$c51 = peg$literalExpectation(">", false), peg$c52 = function() {
17794
18034
  return text();
17795
- }, peg$c53 = function(text2) {
18035
+ }, peg$c53 = "\xAB", peg$c54 = peg$literalExpectation("\xAB", false), peg$c55 = "\xBB", peg$c56 = peg$literalExpectation("\xBB", false), peg$c57 = function(text2) {
18036
+ return text2;
18037
+ }, peg$c58 = function(name) {
18038
+ return name.code === "C";
18039
+ }, peg$c59 = function(name, content2, end_tag) {
18040
+ return end_tag === name.end_tag;
18041
+ }, peg$c60 = function(name, content2, end_tag) {
18042
+ return {
18043
+ content: content2,
18044
+ "type": "fcode",
18045
+ name: name.code
18046
+ };
18047
+ }, peg$c61 = "|", peg$c62 = peg$literalExpectation("|", false), peg$c63 = function(text2) {
17796
18048
  return text2;
17797
- }, peg$c54 = function(name) {
17798
- return name === "C";
17799
- }, peg$c55 = "|", peg$c56 = peg$literalExpectation("|", false), peg$c57 = function(name) {
17800
- return name === "L";
17801
- }, peg$c58 = function(name, content2, t) {
18049
+ }, peg$c64 = function(name) {
18050
+ return name.code === "L";
18051
+ }, peg$c65 = function(name, content2, t) {
17802
18052
  return t;
17803
- }, peg$c59 = function(name, content2, meta) {
18053
+ }, peg$c66 = function(name, content2, meta, end_tag) {
18054
+ return end_tag === name.end_tag;
18055
+ }, peg$c67 = function(name, content2, meta, end_tag) {
17804
18056
  return {
17805
18057
  content: content2,
17806
18058
  "type": "fcode",
17807
- name,
18059
+ name: name.code,
17808
18060
  meta
17809
18061
  };
17810
- }, 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) {
18062
+ }, 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) {
17811
18063
  return flattenDeep5([code, codes]);
17812
- }, peg$c65 = function(code) {
18064
+ }, peg$c73 = function(code) {
17813
18065
  return [code];
17814
- }, peg$c66 = function(name) {
18066
+ }, peg$c74 = function(name) {
17815
18067
  return name === "X";
17816
- }, peg$c67 = function(name, content2, entry) {
18068
+ }, peg$c75 = function(name, content2, entry) {
17817
18069
  return {
17818
18070
  content: content2,
17819
18071
  "type": "fcode",
17820
18072
  name,
17821
18073
  entry
17822
18074
  };
17823
- }, peg$c68 = function(name) {
18075
+ }, peg$c76 = function(name) {
17824
18076
  return name === "S";
17825
- }, peg$c69 = function(name) {
18077
+ }, peg$c77 = function(name) {
17826
18078
  return name === "Z";
17827
- }, 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) {
18079
+ }, 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) {
17828
18080
  return parseInt(number, 10);
17829
- }, peg$c75 = "0o", peg$c76 = peg$literalExpectation("0o", false), peg$c77 = function(number) {
18081
+ }, peg$c83 = "0o", peg$c84 = peg$literalExpectation("0o", false), peg$c85 = function(number) {
17830
18082
  return parseInt(number, 8);
17831
- }, peg$c78 = "0b", peg$c79 = peg$literalExpectation("0b", false), peg$c80 = function(number) {
18083
+ }, peg$c86 = "0b", peg$c87 = peg$literalExpectation("0b", false), peg$c88 = function(number) {
17832
18084
  return parseInt(number, 2);
17833
- }, 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() {
18085
+ }, 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() {
17834
18086
  return parseInt(text());
17835
- }, peg$c86 = function(number) {
18087
+ }, peg$c94 = function(number) {
17836
18088
  return {type: "number", value: parseInt(number, 10)};
17837
- }, peg$c87 = function(name) {
18089
+ }, peg$c95 = function(name) {
17838
18090
  return name === "E";
17839
- }, peg$c88 = function(name, t) {
18091
+ }, peg$c96 = function(name, t) {
17840
18092
  return flattenDeep5(t);
17841
- }, peg$c89 = function(name, content2) {
18093
+ }, peg$c97 = function(name, content2) {
17842
18094
  return {
17843
18095
  content: content2 ? content2 : [],
17844
18096
  "type": "fcode",
17845
18097
  name
17846
18098
  };
17847
- }, peg$c90 = function(name) {
18099
+ }, peg$c98 = function(name) {
17848
18100
  return name;
17849
- }, peg$c91 = function(name) {
17850
- return name !== "C";
17851
- }, peg$c92 = function(name, content2) {
17852
- return {content: content2, type: "fcode", name};
18101
+ }, peg$c99 = function(name, begin_tag) {
18102
+ return {code: name, begin_tag, end_tag: get_pair_tag(begin_tag)};
18103
+ }, peg$c100 = function(name) {
18104
+ return name.code !== "C";
18105
+ }, peg$c101 = function(name, content2, end_tag) {
18106
+ return end_tag === name.end_tag;
18107
+ }, peg$c102 = function(name, content2, end_tag) {
18108
+ return {content: content2, type: "fcode", name: name.code};
17853
18109
  }, peg$currPos = 0, peg$savedPos = 0, peg$posDetailsCache = [{line: 1, column: 1}], peg$maxFailPos = 0, peg$maxFailExpected = [], peg$silentFails = 0, peg$result;
17854
18110
  if ("startRule" in options) {
17855
18111
  if (!(options.startRule in peg$startRuleFunctions)) {
@@ -17949,7 +18205,7 @@ var require_grammarfc = __commonJS({
17949
18205
  s0 = [];
17950
18206
  s1 = peg$parseallowed_rules();
17951
18207
  if (s1 === peg$FAILED) {
17952
- s1 = peg$parsecode();
18208
+ s1 = peg$parsecode_2();
17953
18209
  if (s1 === peg$FAILED) {
17954
18210
  s1 = peg$parsetext();
17955
18211
  if (s1 === peg$FAILED) {
@@ -17961,7 +18217,7 @@ var require_grammarfc = __commonJS({
17961
18217
  s0.push(s1);
17962
18218
  s1 = peg$parseallowed_rules();
17963
18219
  if (s1 === peg$FAILED) {
17964
- s1 = peg$parsecode();
18220
+ s1 = peg$parsecode_2();
17965
18221
  if (s1 === peg$FAILED) {
17966
18222
  s1 = peg$parsetext();
17967
18223
  if (s1 === peg$FAILED) {
@@ -18617,7 +18873,84 @@ var require_grammarfc = __commonJS({
18617
18873
  peg$currPos = s0;
18618
18874
  s0 = peg$FAILED;
18619
18875
  }
18620
- return s0;
18876
+ if (s0 === peg$FAILED) {
18877
+ s0 = peg$currPos;
18878
+ s1 = peg$currPos;
18879
+ s2 = peg$currPos;
18880
+ peg$silentFails++;
18881
+ s3 = peg$parseallowed_code_C();
18882
+ peg$silentFails--;
18883
+ if (s3 === peg$FAILED) {
18884
+ s2 = void 0;
18885
+ } else {
18886
+ peg$currPos = s2;
18887
+ s2 = peg$FAILED;
18888
+ }
18889
+ if (s2 !== peg$FAILED) {
18890
+ if (input.length > peg$currPos) {
18891
+ s3 = input.charAt(peg$currPos);
18892
+ peg$currPos++;
18893
+ } else {
18894
+ s3 = peg$FAILED;
18895
+ if (peg$silentFails === 0) {
18896
+ peg$fail(peg$c39);
18897
+ }
18898
+ }
18899
+ if (s3 !== peg$FAILED) {
18900
+ s2 = [s2, s3];
18901
+ s1 = s2;
18902
+ } else {
18903
+ peg$currPos = s1;
18904
+ s1 = peg$FAILED;
18905
+ }
18906
+ } else {
18907
+ peg$currPos = s1;
18908
+ s1 = peg$FAILED;
18909
+ }
18910
+ if (s1 !== peg$FAILED) {
18911
+ if (input.charCodeAt(peg$currPos) === 171) {
18912
+ s2 = peg$c53;
18913
+ peg$currPos++;
18914
+ } else {
18915
+ s2 = peg$FAILED;
18916
+ if (peg$silentFails === 0) {
18917
+ peg$fail(peg$c54);
18918
+ }
18919
+ }
18920
+ if (s2 !== peg$FAILED) {
18921
+ s3 = peg$parsenot_code();
18922
+ if (s3 !== peg$FAILED) {
18923
+ if (input.charCodeAt(peg$currPos) === 187) {
18924
+ s4 = peg$c55;
18925
+ peg$currPos++;
18926
+ } else {
18927
+ s4 = peg$FAILED;
18928
+ if (peg$silentFails === 0) {
18929
+ peg$fail(peg$c56);
18930
+ }
18931
+ }
18932
+ if (s4 !== peg$FAILED) {
18933
+ peg$savedPos = s0;
18934
+ s1 = peg$c52();
18935
+ s0 = s1;
18936
+ } else {
18937
+ peg$currPos = s0;
18938
+ s0 = peg$FAILED;
18939
+ }
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
+ }
18953
+ return s0;
18621
18954
  }
18622
18955
  function peg$parsetext_C() {
18623
18956
  var s0, s1, s2, s3, s4, s5, s6, s7;
@@ -18713,9 +19046,99 @@ var require_grammarfc = __commonJS({
18713
19046
  s3 = peg$FAILED;
18714
19047
  }
18715
19048
  if (s3 === peg$FAILED) {
18716
- s3 = peg$parselooks_like_code_C();
19049
+ s3 = peg$currPos;
19050
+ s4 = peg$currPos;
19051
+ s5 = peg$currPos;
19052
+ peg$silentFails++;
19053
+ if (input.charCodeAt(peg$currPos) === 171) {
19054
+ s6 = peg$c53;
19055
+ peg$currPos++;
19056
+ } else {
19057
+ s6 = peg$FAILED;
19058
+ if (peg$silentFails === 0) {
19059
+ peg$fail(peg$c54);
19060
+ }
19061
+ }
19062
+ peg$silentFails--;
19063
+ if (s6 === peg$FAILED) {
19064
+ s5 = void 0;
19065
+ } else {
19066
+ peg$currPos = s5;
19067
+ s5 = peg$FAILED;
19068
+ }
19069
+ if (s5 !== peg$FAILED) {
19070
+ if (input.length > peg$currPos) {
19071
+ s6 = input.charAt(peg$currPos);
19072
+ peg$currPos++;
19073
+ } else {
19074
+ s6 = peg$FAILED;
19075
+ if (peg$silentFails === 0) {
19076
+ peg$fail(peg$c39);
19077
+ }
19078
+ }
19079
+ if (s6 !== peg$FAILED) {
19080
+ s5 = [s5, s6];
19081
+ s4 = s5;
19082
+ } else {
19083
+ peg$currPos = s4;
19084
+ s4 = peg$FAILED;
19085
+ }
19086
+ } else {
19087
+ peg$currPos = s4;
19088
+ s4 = peg$FAILED;
19089
+ }
19090
+ if (s4 === peg$FAILED) {
19091
+ s4 = null;
19092
+ }
19093
+ if (s4 !== peg$FAILED) {
19094
+ if (input.charCodeAt(peg$currPos) === 171) {
19095
+ s5 = peg$c53;
19096
+ peg$currPos++;
19097
+ } else {
19098
+ s5 = peg$FAILED;
19099
+ if (peg$silentFails === 0) {
19100
+ peg$fail(peg$c54);
19101
+ }
19102
+ }
19103
+ if (s5 !== peg$FAILED) {
19104
+ s6 = peg$parsetext_C();
19105
+ if (s6 === peg$FAILED) {
19106
+ s6 = null;
19107
+ }
19108
+ if (s6 !== peg$FAILED) {
19109
+ if (input.charCodeAt(peg$currPos) === 187) {
19110
+ s7 = peg$c55;
19111
+ peg$currPos++;
19112
+ } else {
19113
+ s7 = peg$FAILED;
19114
+ if (peg$silentFails === 0) {
19115
+ peg$fail(peg$c56);
19116
+ }
19117
+ }
19118
+ if (s7 !== peg$FAILED) {
19119
+ s4 = [s4, s5, s6, s7];
19120
+ s3 = s4;
19121
+ } else {
19122
+ peg$currPos = s3;
19123
+ s3 = peg$FAILED;
19124
+ }
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
+ }
18717
19137
  if (s3 === peg$FAILED) {
18718
- s3 = peg$parsenot_code();
19138
+ s3 = peg$parselooks_like_code_C();
19139
+ if (s3 === peg$FAILED) {
19140
+ s3 = peg$parsenot_code();
19141
+ }
18719
19142
  }
18720
19143
  }
18721
19144
  if (s3 !== peg$FAILED) {
@@ -18810,9 +19233,99 @@ var require_grammarfc = __commonJS({
18810
19233
  s3 = peg$FAILED;
18811
19234
  }
18812
19235
  if (s3 === peg$FAILED) {
18813
- s3 = peg$parselooks_like_code_C();
19236
+ s3 = peg$currPos;
19237
+ s4 = peg$currPos;
19238
+ s5 = peg$currPos;
19239
+ peg$silentFails++;
19240
+ if (input.charCodeAt(peg$currPos) === 171) {
19241
+ s6 = peg$c53;
19242
+ peg$currPos++;
19243
+ } else {
19244
+ s6 = peg$FAILED;
19245
+ if (peg$silentFails === 0) {
19246
+ peg$fail(peg$c54);
19247
+ }
19248
+ }
19249
+ peg$silentFails--;
19250
+ if (s6 === peg$FAILED) {
19251
+ s5 = void 0;
19252
+ } else {
19253
+ peg$currPos = s5;
19254
+ s5 = peg$FAILED;
19255
+ }
19256
+ if (s5 !== peg$FAILED) {
19257
+ if (input.length > peg$currPos) {
19258
+ s6 = input.charAt(peg$currPos);
19259
+ peg$currPos++;
19260
+ } else {
19261
+ s6 = peg$FAILED;
19262
+ if (peg$silentFails === 0) {
19263
+ peg$fail(peg$c39);
19264
+ }
19265
+ }
19266
+ if (s6 !== peg$FAILED) {
19267
+ s5 = [s5, s6];
19268
+ s4 = s5;
19269
+ } else {
19270
+ peg$currPos = s4;
19271
+ s4 = peg$FAILED;
19272
+ }
19273
+ } else {
19274
+ peg$currPos = s4;
19275
+ s4 = peg$FAILED;
19276
+ }
19277
+ if (s4 === peg$FAILED) {
19278
+ s4 = null;
19279
+ }
19280
+ if (s4 !== peg$FAILED) {
19281
+ if (input.charCodeAt(peg$currPos) === 171) {
19282
+ s5 = peg$c53;
19283
+ peg$currPos++;
19284
+ } else {
19285
+ s5 = peg$FAILED;
19286
+ if (peg$silentFails === 0) {
19287
+ peg$fail(peg$c54);
19288
+ }
19289
+ }
19290
+ if (s5 !== peg$FAILED) {
19291
+ s6 = peg$parsetext_C();
19292
+ if (s6 === peg$FAILED) {
19293
+ s6 = null;
19294
+ }
19295
+ if (s6 !== peg$FAILED) {
19296
+ if (input.charCodeAt(peg$currPos) === 187) {
19297
+ s7 = peg$c55;
19298
+ peg$currPos++;
19299
+ } else {
19300
+ s7 = peg$FAILED;
19301
+ if (peg$silentFails === 0) {
19302
+ peg$fail(peg$c56);
19303
+ }
19304
+ }
19305
+ if (s7 !== peg$FAILED) {
19306
+ s4 = [s4, s5, s6, s7];
19307
+ s3 = s4;
19308
+ } else {
19309
+ peg$currPos = s3;
19310
+ s3 = peg$FAILED;
19311
+ }
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
+ }
18814
19324
  if (s3 === peg$FAILED) {
18815
- s3 = peg$parsenot_code();
19325
+ s3 = peg$parselooks_like_code_C();
19326
+ if (s3 === peg$FAILED) {
19327
+ s3 = peg$parsenot_code();
19328
+ }
18816
19329
  }
18817
19330
  }
18818
19331
  }
@@ -18826,18 +19339,18 @@ var require_grammarfc = __commonJS({
18826
19339
  }
18827
19340
  if (s1 !== peg$FAILED) {
18828
19341
  peg$savedPos = s0;
18829
- s1 = peg$c53(s1);
19342
+ s1 = peg$c57(s1);
18830
19343
  }
18831
19344
  s0 = s1;
18832
19345
  return s0;
18833
19346
  }
18834
19347
  function peg$parsecode_C() {
18835
- var s0, s1, s2, s3, s4;
19348
+ var s0, s1, s2, s3, s4, s5;
18836
19349
  s0 = peg$currPos;
18837
- s1 = peg$parsestart_code();
19350
+ s1 = peg$parsestart_code_2();
18838
19351
  if (s1 !== peg$FAILED) {
18839
19352
  peg$savedPos = peg$currPos;
18840
- s2 = peg$c54(s1);
19353
+ s2 = peg$c58(s1);
18841
19354
  if (s2) {
18842
19355
  s2 = void 0;
18843
19356
  } else {
@@ -18857,9 +19370,21 @@ var require_grammarfc = __commonJS({
18857
19370
  if (s3 !== peg$FAILED) {
18858
19371
  s4 = peg$parseend_code();
18859
19372
  if (s4 !== peg$FAILED) {
18860
- peg$savedPos = s0;
18861
- s1 = peg$c42(s1, s3);
18862
- s0 = s1;
19373
+ peg$savedPos = peg$currPos;
19374
+ s5 = peg$c59(s1, s3, s4);
19375
+ if (s5) {
19376
+ s5 = void 0;
19377
+ } else {
19378
+ s5 = peg$FAILED;
19379
+ }
19380
+ if (s5 !== peg$FAILED) {
19381
+ peg$savedPos = s0;
19382
+ s1 = peg$c60(s1, s3, s4);
19383
+ s0 = s1;
19384
+ } else {
19385
+ peg$currPos = s0;
19386
+ s0 = peg$FAILED;
19387
+ }
18863
19388
  } else {
18864
19389
  peg$currPos = s0;
18865
19390
  s0 = peg$FAILED;
@@ -18881,53 +19406,110 @@ var require_grammarfc = __commonJS({
18881
19406
  function peg$parseseparator() {
18882
19407
  var s0;
18883
19408
  if (input.charCodeAt(peg$currPos) === 124) {
18884
- s0 = peg$c55;
19409
+ s0 = peg$c61;
18885
19410
  peg$currPos++;
18886
19411
  } else {
18887
19412
  s0 = peg$FAILED;
18888
19413
  if (peg$silentFails === 0) {
18889
- peg$fail(peg$c56);
19414
+ peg$fail(peg$c62);
18890
19415
  }
18891
19416
  }
18892
19417
  return s0;
18893
19418
  }
18894
19419
  function peg$parsetext_L() {
18895
- var s0, s1, s2, s3, s4, s5, s6, s7;
19420
+ var s0, s1, s2, s3, s4, s5, s6, s7, s8;
18896
19421
  s0 = peg$currPos;
18897
- s1 = [];
18898
- s2 = peg$currPos;
19422
+ s1 = peg$currPos;
19423
+ s2 = [];
18899
19424
  s3 = peg$currPos;
18900
19425
  s4 = peg$currPos;
19426
+ s5 = peg$currPos;
18901
19427
  peg$silentFails++;
18902
19428
  if (input.charCodeAt(peg$currPos) === 60) {
18903
- s5 = peg$c48;
19429
+ s6 = peg$c48;
18904
19430
  peg$currPos++;
18905
19431
  } else {
18906
- s5 = peg$FAILED;
19432
+ s6 = peg$FAILED;
18907
19433
  if (peg$silentFails === 0) {
18908
19434
  peg$fail(peg$c49);
18909
19435
  }
18910
19436
  }
18911
19437
  peg$silentFails--;
18912
- if (s5 === peg$FAILED) {
18913
- s4 = void 0;
19438
+ if (s6 === peg$FAILED) {
19439
+ s5 = void 0;
18914
19440
  } else {
18915
- peg$currPos = s4;
18916
- s4 = peg$FAILED;
19441
+ peg$currPos = s5;
19442
+ s5 = peg$FAILED;
19443
+ }
19444
+ if (s5 !== peg$FAILED) {
19445
+ s6 = peg$currPos;
19446
+ peg$silentFails++;
19447
+ s7 = peg$parseallowed_code();
19448
+ peg$silentFails--;
19449
+ if (s7 === peg$FAILED) {
19450
+ s6 = void 0;
19451
+ } else {
19452
+ peg$currPos = s6;
19453
+ s6 = peg$FAILED;
19454
+ }
19455
+ if (s6 !== peg$FAILED) {
19456
+ if (input.length > peg$currPos) {
19457
+ s7 = input.charAt(peg$currPos);
19458
+ peg$currPos++;
19459
+ } else {
19460
+ s7 = peg$FAILED;
19461
+ if (peg$silentFails === 0) {
19462
+ peg$fail(peg$c39);
19463
+ }
19464
+ }
19465
+ if (s7 !== peg$FAILED) {
19466
+ s5 = [s5, s6, s7];
19467
+ s4 = s5;
19468
+ } else {
19469
+ peg$currPos = s4;
19470
+ s4 = peg$FAILED;
19471
+ }
19472
+ } else {
19473
+ peg$currPos = s4;
19474
+ s4 = peg$FAILED;
19475
+ }
19476
+ } else {
19477
+ peg$currPos = s4;
19478
+ s4 = peg$FAILED;
18917
19479
  }
18918
19480
  if (s4 !== peg$FAILED) {
18919
- if (input.length > peg$currPos) {
18920
- s5 = input.charAt(peg$currPos);
19481
+ if (input.charCodeAt(peg$currPos) === 60) {
19482
+ s5 = peg$c48;
18921
19483
  peg$currPos++;
18922
19484
  } else {
18923
19485
  s5 = peg$FAILED;
18924
19486
  if (peg$silentFails === 0) {
18925
- peg$fail(peg$c39);
19487
+ peg$fail(peg$c49);
18926
19488
  }
18927
19489
  }
18928
19490
  if (s5 !== peg$FAILED) {
18929
- s4 = [s4, s5];
18930
- s3 = s4;
19491
+ s6 = peg$parsetext_L();
19492
+ if (s6 !== peg$FAILED) {
19493
+ if (input.charCodeAt(peg$currPos) === 62) {
19494
+ s7 = peg$c50;
19495
+ peg$currPos++;
19496
+ } else {
19497
+ s7 = peg$FAILED;
19498
+ if (peg$silentFails === 0) {
19499
+ peg$fail(peg$c51);
19500
+ }
19501
+ }
19502
+ if (s7 !== peg$FAILED) {
19503
+ s4 = [s4, s5, s6, s7];
19504
+ s3 = s4;
19505
+ } else {
19506
+ peg$currPos = s3;
19507
+ s3 = peg$FAILED;
19508
+ }
19509
+ } else {
19510
+ peg$currPos = s3;
19511
+ s3 = peg$FAILED;
19512
+ }
18931
19513
  } else {
18932
19514
  peg$currPos = s3;
18933
19515
  s3 = peg$FAILED;
@@ -18936,63 +19518,112 @@ var require_grammarfc = __commonJS({
18936
19518
  peg$currPos = s3;
18937
19519
  s3 = peg$FAILED;
18938
19520
  }
18939
- if (s3 !== peg$FAILED) {
18940
- if (input.charCodeAt(peg$currPos) === 60) {
18941
- s4 = peg$c48;
19521
+ if (s3 === peg$FAILED) {
19522
+ s3 = peg$currPos;
19523
+ s4 = peg$currPos;
19524
+ s5 = peg$currPos;
19525
+ peg$silentFails++;
19526
+ if (input.charCodeAt(peg$currPos) === 171) {
19527
+ s6 = peg$c53;
18942
19528
  peg$currPos++;
18943
19529
  } else {
18944
- s4 = peg$FAILED;
19530
+ s6 = peg$FAILED;
18945
19531
  if (peg$silentFails === 0) {
18946
- peg$fail(peg$c49);
19532
+ peg$fail(peg$c54);
18947
19533
  }
18948
19534
  }
18949
- if (s4 !== peg$FAILED) {
18950
- s5 = peg$parsetext_L();
18951
- if (s5 !== peg$FAILED) {
18952
- if (input.charCodeAt(peg$currPos) === 62) {
18953
- s6 = peg$c50;
19535
+ peg$silentFails--;
19536
+ if (s6 === peg$FAILED) {
19537
+ s5 = void 0;
19538
+ } else {
19539
+ peg$currPos = s5;
19540
+ s5 = peg$FAILED;
19541
+ }
19542
+ if (s5 !== peg$FAILED) {
19543
+ s6 = peg$currPos;
19544
+ peg$silentFails++;
19545
+ s7 = peg$parseallowed_code();
19546
+ peg$silentFails--;
19547
+ if (s7 === peg$FAILED) {
19548
+ s6 = void 0;
19549
+ } else {
19550
+ peg$currPos = s6;
19551
+ s6 = peg$FAILED;
19552
+ }
19553
+ if (s6 !== peg$FAILED) {
19554
+ if (input.length > peg$currPos) {
19555
+ s7 = input.charAt(peg$currPos);
18954
19556
  peg$currPos++;
18955
19557
  } else {
18956
- s6 = peg$FAILED;
19558
+ s7 = peg$FAILED;
18957
19559
  if (peg$silentFails === 0) {
18958
- peg$fail(peg$c51);
19560
+ peg$fail(peg$c39);
18959
19561
  }
18960
19562
  }
18961
- if (s6 !== peg$FAILED) {
18962
- s3 = [s3, s4, s5, s6];
18963
- s2 = s3;
19563
+ if (s7 !== peg$FAILED) {
19564
+ s5 = [s5, s6, s7];
19565
+ s4 = s5;
18964
19566
  } else {
18965
- peg$currPos = s2;
18966
- s2 = peg$FAILED;
19567
+ peg$currPos = s4;
19568
+ s4 = peg$FAILED;
18967
19569
  }
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
- } else {
18977
- peg$currPos = s2;
18978
- s2 = peg$FAILED;
18979
- }
18980
- if (s2 === peg$FAILED) {
18981
- s2 = peg$currPos;
18982
- s3 = peg$currPos;
18983
- peg$silentFails++;
18984
- s4 = peg$parseseparator();
18985
- peg$silentFails--;
18986
- if (s4 === peg$FAILED) {
18987
- s3 = void 0;
19578
+ if (s4 !== peg$FAILED) {
19579
+ if (input.charCodeAt(peg$currPos) === 171) {
19580
+ s5 = peg$c53;
19581
+ peg$currPos++;
19582
+ } else {
19583
+ s5 = peg$FAILED;
19584
+ if (peg$silentFails === 0) {
19585
+ peg$fail(peg$c54);
19586
+ }
19587
+ }
19588
+ if (s5 !== peg$FAILED) {
19589
+ s6 = peg$parsetext_L();
19590
+ if (s6 === peg$FAILED) {
19591
+ s6 = null;
19592
+ }
19593
+ if (s6 !== peg$FAILED) {
19594
+ if (input.charCodeAt(peg$currPos) === 187) {
19595
+ s7 = peg$c55;
19596
+ peg$currPos++;
19597
+ } else {
19598
+ s7 = peg$FAILED;
19599
+ if (peg$silentFails === 0) {
19600
+ peg$fail(peg$c56);
19601
+ }
19602
+ }
19603
+ if (s7 !== peg$FAILED) {
19604
+ s4 = [s4, s5, s6, s7];
19605
+ s3 = s4;
19606
+ } else {
19607
+ peg$currPos = s3;
19608
+ s3 = peg$FAILED;
19609
+ }
19610
+ } else {
19611
+ peg$currPos = s3;
19612
+ s3 = peg$FAILED;
19613
+ }
19614
+ } else {
19615
+ peg$currPos = s3;
19616
+ s3 = peg$FAILED;
19617
+ }
18988
19618
  } else {
18989
19619
  peg$currPos = s3;
18990
19620
  s3 = peg$FAILED;
18991
19621
  }
18992
- if (s3 !== peg$FAILED) {
19622
+ if (s3 === peg$FAILED) {
19623
+ s3 = peg$currPos;
18993
19624
  s4 = peg$currPos;
18994
19625
  peg$silentFails++;
18995
- s5 = peg$parseend_code();
19626
+ s5 = peg$parseseparator();
18996
19627
  peg$silentFails--;
18997
19628
  if (s5 === peg$FAILED) {
18998
19629
  s4 = void 0;
@@ -19003,7 +19634,7 @@ var require_grammarfc = __commonJS({
19003
19634
  if (s4 !== peg$FAILED) {
19004
19635
  s5 = peg$currPos;
19005
19636
  peg$silentFails++;
19006
- s6 = peg$parsestart_code();
19637
+ s6 = peg$parseend_code();
19007
19638
  peg$silentFails--;
19008
19639
  if (s6 === peg$FAILED) {
19009
19640
  s5 = void 0;
@@ -19014,7 +19645,7 @@ var require_grammarfc = __commonJS({
19014
19645
  if (s5 !== peg$FAILED) {
19015
19646
  s6 = peg$currPos;
19016
19647
  peg$silentFails++;
19017
- s7 = peg$parselooks_like_code();
19648
+ s7 = peg$parsestart_code();
19018
19649
  peg$silentFails--;
19019
19650
  if (s7 === peg$FAILED) {
19020
19651
  s6 = void 0;
@@ -19023,75 +19654,143 @@ var require_grammarfc = __commonJS({
19023
19654
  s6 = peg$FAILED;
19024
19655
  }
19025
19656
  if (s6 !== peg$FAILED) {
19026
- if (input.length > peg$currPos) {
19027
- s7 = input.charAt(peg$currPos);
19028
- peg$currPos++;
19657
+ s7 = peg$currPos;
19658
+ peg$silentFails++;
19659
+ s8 = peg$parselooks_like_code();
19660
+ peg$silentFails--;
19661
+ if (s8 === peg$FAILED) {
19662
+ s7 = void 0;
19029
19663
  } else {
19664
+ peg$currPos = s7;
19030
19665
  s7 = peg$FAILED;
19031
- if (peg$silentFails === 0) {
19032
- peg$fail(peg$c39);
19033
- }
19034
19666
  }
19035
19667
  if (s7 !== peg$FAILED) {
19036
- s3 = [s3, s4, s5, s6, s7];
19037
- s2 = s3;
19668
+ if (input.length > peg$currPos) {
19669
+ s8 = input.charAt(peg$currPos);
19670
+ peg$currPos++;
19671
+ } else {
19672
+ s8 = peg$FAILED;
19673
+ if (peg$silentFails === 0) {
19674
+ peg$fail(peg$c39);
19675
+ }
19676
+ }
19677
+ if (s8 !== peg$FAILED) {
19678
+ s4 = [s4, s5, s6, s7, s8];
19679
+ s3 = s4;
19680
+ } else {
19681
+ peg$currPos = s3;
19682
+ s3 = peg$FAILED;
19683
+ }
19038
19684
  } else {
19039
- peg$currPos = s2;
19040
- s2 = peg$FAILED;
19685
+ peg$currPos = s3;
19686
+ s3 = peg$FAILED;
19041
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
- } else {
19055
- peg$currPos = s2;
19056
- s2 = peg$FAILED;
19057
19700
  }
19058
19701
  }
19059
- if (s2 !== peg$FAILED) {
19060
- while (s2 !== peg$FAILED) {
19061
- s1.push(s2);
19062
- s2 = peg$currPos;
19702
+ if (s3 !== peg$FAILED) {
19703
+ while (s3 !== peg$FAILED) {
19704
+ s2.push(s3);
19063
19705
  s3 = peg$currPos;
19064
19706
  s4 = peg$currPos;
19707
+ s5 = peg$currPos;
19065
19708
  peg$silentFails++;
19066
19709
  if (input.charCodeAt(peg$currPos) === 60) {
19067
- s5 = peg$c48;
19710
+ s6 = peg$c48;
19068
19711
  peg$currPos++;
19069
19712
  } else {
19070
- s5 = peg$FAILED;
19713
+ s6 = peg$FAILED;
19071
19714
  if (peg$silentFails === 0) {
19072
19715
  peg$fail(peg$c49);
19073
19716
  }
19074
19717
  }
19075
19718
  peg$silentFails--;
19076
- if (s5 === peg$FAILED) {
19077
- s4 = void 0;
19719
+ if (s6 === peg$FAILED) {
19720
+ s5 = void 0;
19721
+ } else {
19722
+ peg$currPos = s5;
19723
+ s5 = peg$FAILED;
19724
+ }
19725
+ if (s5 !== peg$FAILED) {
19726
+ s6 = peg$currPos;
19727
+ peg$silentFails++;
19728
+ s7 = peg$parseallowed_code();
19729
+ peg$silentFails--;
19730
+ if (s7 === peg$FAILED) {
19731
+ s6 = void 0;
19732
+ } else {
19733
+ peg$currPos = s6;
19734
+ s6 = peg$FAILED;
19735
+ }
19736
+ if (s6 !== peg$FAILED) {
19737
+ if (input.length > peg$currPos) {
19738
+ s7 = input.charAt(peg$currPos);
19739
+ peg$currPos++;
19740
+ } else {
19741
+ s7 = peg$FAILED;
19742
+ if (peg$silentFails === 0) {
19743
+ peg$fail(peg$c39);
19744
+ }
19745
+ }
19746
+ if (s7 !== peg$FAILED) {
19747
+ s5 = [s5, s6, s7];
19748
+ s4 = s5;
19749
+ } else {
19750
+ peg$currPos = s4;
19751
+ s4 = peg$FAILED;
19752
+ }
19753
+ } else {
19754
+ peg$currPos = s4;
19755
+ s4 = peg$FAILED;
19756
+ }
19078
19757
  } else {
19079
19758
  peg$currPos = s4;
19080
19759
  s4 = peg$FAILED;
19081
19760
  }
19082
19761
  if (s4 !== peg$FAILED) {
19083
- if (input.length > peg$currPos) {
19084
- s5 = input.charAt(peg$currPos);
19762
+ if (input.charCodeAt(peg$currPos) === 60) {
19763
+ s5 = peg$c48;
19085
19764
  peg$currPos++;
19086
19765
  } else {
19087
19766
  s5 = peg$FAILED;
19088
19767
  if (peg$silentFails === 0) {
19089
- peg$fail(peg$c39);
19768
+ peg$fail(peg$c49);
19090
19769
  }
19091
19770
  }
19092
19771
  if (s5 !== peg$FAILED) {
19093
- s4 = [s4, s5];
19094
- s3 = s4;
19772
+ s6 = peg$parsetext_L();
19773
+ if (s6 !== peg$FAILED) {
19774
+ if (input.charCodeAt(peg$currPos) === 62) {
19775
+ s7 = peg$c50;
19776
+ peg$currPos++;
19777
+ } else {
19778
+ s7 = peg$FAILED;
19779
+ if (peg$silentFails === 0) {
19780
+ peg$fail(peg$c51);
19781
+ }
19782
+ }
19783
+ if (s7 !== peg$FAILED) {
19784
+ s4 = [s4, s5, s6, s7];
19785
+ s3 = s4;
19786
+ } else {
19787
+ peg$currPos = s3;
19788
+ s3 = peg$FAILED;
19789
+ }
19790
+ } else {
19791
+ peg$currPos = s3;
19792
+ s3 = peg$FAILED;
19793
+ }
19095
19794
  } else {
19096
19795
  peg$currPos = s3;
19097
19796
  s3 = peg$FAILED;
@@ -19100,63 +19799,112 @@ var require_grammarfc = __commonJS({
19100
19799
  peg$currPos = s3;
19101
19800
  s3 = peg$FAILED;
19102
19801
  }
19103
- if (s3 !== peg$FAILED) {
19104
- if (input.charCodeAt(peg$currPos) === 60) {
19105
- s4 = peg$c48;
19802
+ if (s3 === peg$FAILED) {
19803
+ s3 = peg$currPos;
19804
+ s4 = peg$currPos;
19805
+ s5 = peg$currPos;
19806
+ peg$silentFails++;
19807
+ if (input.charCodeAt(peg$currPos) === 171) {
19808
+ s6 = peg$c53;
19106
19809
  peg$currPos++;
19107
19810
  } else {
19108
- s4 = peg$FAILED;
19811
+ s6 = peg$FAILED;
19109
19812
  if (peg$silentFails === 0) {
19110
- peg$fail(peg$c49);
19813
+ peg$fail(peg$c54);
19111
19814
  }
19112
19815
  }
19113
- if (s4 !== peg$FAILED) {
19114
- s5 = peg$parsetext_L();
19115
- if (s5 !== peg$FAILED) {
19116
- if (input.charCodeAt(peg$currPos) === 62) {
19117
- s6 = peg$c50;
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$currPos;
19825
+ peg$silentFails++;
19826
+ s7 = peg$parseallowed_code();
19827
+ peg$silentFails--;
19828
+ if (s7 === peg$FAILED) {
19829
+ s6 = void 0;
19830
+ } else {
19831
+ peg$currPos = s6;
19832
+ s6 = peg$FAILED;
19833
+ }
19834
+ if (s6 !== peg$FAILED) {
19835
+ if (input.length > peg$currPos) {
19836
+ s7 = input.charAt(peg$currPos);
19118
19837
  peg$currPos++;
19119
19838
  } else {
19120
- s6 = peg$FAILED;
19839
+ s7 = peg$FAILED;
19121
19840
  if (peg$silentFails === 0) {
19122
- peg$fail(peg$c51);
19841
+ peg$fail(peg$c39);
19123
19842
  }
19124
19843
  }
19125
- if (s6 !== peg$FAILED) {
19126
- s3 = [s3, s4, s5, s6];
19127
- s2 = s3;
19844
+ if (s7 !== peg$FAILED) {
19845
+ s5 = [s5, s6, s7];
19846
+ s4 = s5;
19128
19847
  } else {
19129
- peg$currPos = s2;
19130
- s2 = peg$FAILED;
19848
+ peg$currPos = s4;
19849
+ s4 = peg$FAILED;
19131
19850
  }
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
- } else {
19141
- peg$currPos = s2;
19142
- s2 = peg$FAILED;
19143
- }
19144
- if (s2 === peg$FAILED) {
19145
- s2 = peg$currPos;
19146
- s3 = peg$currPos;
19147
- peg$silentFails++;
19148
- s4 = peg$parseseparator();
19149
- peg$silentFails--;
19150
- if (s4 === peg$FAILED) {
19151
- s3 = void 0;
19859
+ if (s4 !== peg$FAILED) {
19860
+ if (input.charCodeAt(peg$currPos) === 171) {
19861
+ s5 = peg$c53;
19862
+ peg$currPos++;
19863
+ } else {
19864
+ s5 = peg$FAILED;
19865
+ if (peg$silentFails === 0) {
19866
+ peg$fail(peg$c54);
19867
+ }
19868
+ }
19869
+ if (s5 !== peg$FAILED) {
19870
+ s6 = peg$parsetext_L();
19871
+ if (s6 === peg$FAILED) {
19872
+ s6 = null;
19873
+ }
19874
+ if (s6 !== peg$FAILED) {
19875
+ if (input.charCodeAt(peg$currPos) === 187) {
19876
+ s7 = peg$c55;
19877
+ peg$currPos++;
19878
+ } else {
19879
+ s7 = peg$FAILED;
19880
+ if (peg$silentFails === 0) {
19881
+ peg$fail(peg$c56);
19882
+ }
19883
+ }
19884
+ if (s7 !== peg$FAILED) {
19885
+ s4 = [s4, s5, s6, s7];
19886
+ s3 = s4;
19887
+ } else {
19888
+ peg$currPos = s3;
19889
+ s3 = peg$FAILED;
19890
+ }
19891
+ } else {
19892
+ peg$currPos = s3;
19893
+ s3 = peg$FAILED;
19894
+ }
19895
+ } else {
19896
+ peg$currPos = s3;
19897
+ s3 = peg$FAILED;
19898
+ }
19152
19899
  } else {
19153
19900
  peg$currPos = s3;
19154
19901
  s3 = peg$FAILED;
19155
19902
  }
19156
- if (s3 !== peg$FAILED) {
19903
+ if (s3 === peg$FAILED) {
19904
+ s3 = peg$currPos;
19157
19905
  s4 = peg$currPos;
19158
19906
  peg$silentFails++;
19159
- s5 = peg$parseend_code();
19907
+ s5 = peg$parseseparator();
19160
19908
  peg$silentFails--;
19161
19909
  if (s5 === peg$FAILED) {
19162
19910
  s4 = void 0;
@@ -19167,7 +19915,7 @@ var require_grammarfc = __commonJS({
19167
19915
  if (s4 !== peg$FAILED) {
19168
19916
  s5 = peg$currPos;
19169
19917
  peg$silentFails++;
19170
- s6 = peg$parsestart_code();
19918
+ s6 = peg$parseend_code();
19171
19919
  peg$silentFails--;
19172
19920
  if (s6 === peg$FAILED) {
19173
19921
  s5 = void 0;
@@ -19178,7 +19926,7 @@ var require_grammarfc = __commonJS({
19178
19926
  if (s5 !== peg$FAILED) {
19179
19927
  s6 = peg$currPos;
19180
19928
  peg$silentFails++;
19181
- s7 = peg$parselooks_like_code();
19929
+ s7 = peg$parsestart_code();
19182
19930
  peg$silentFails--;
19183
19931
  if (s7 === peg$FAILED) {
19184
19932
  s6 = void 0;
@@ -19187,57 +19935,74 @@ var require_grammarfc = __commonJS({
19187
19935
  s6 = peg$FAILED;
19188
19936
  }
19189
19937
  if (s6 !== peg$FAILED) {
19190
- if (input.length > peg$currPos) {
19191
- s7 = input.charAt(peg$currPos);
19192
- peg$currPos++;
19938
+ s7 = peg$currPos;
19939
+ peg$silentFails++;
19940
+ s8 = peg$parselooks_like_code();
19941
+ peg$silentFails--;
19942
+ if (s8 === peg$FAILED) {
19943
+ s7 = void 0;
19193
19944
  } else {
19945
+ peg$currPos = s7;
19194
19946
  s7 = peg$FAILED;
19195
- if (peg$silentFails === 0) {
19196
- peg$fail(peg$c39);
19197
- }
19198
19947
  }
19199
19948
  if (s7 !== peg$FAILED) {
19200
- s3 = [s3, s4, s5, s6, s7];
19201
- s2 = s3;
19949
+ if (input.length > peg$currPos) {
19950
+ s8 = input.charAt(peg$currPos);
19951
+ peg$currPos++;
19952
+ } else {
19953
+ s8 = peg$FAILED;
19954
+ if (peg$silentFails === 0) {
19955
+ peg$fail(peg$c39);
19956
+ }
19957
+ }
19958
+ if (s8 !== peg$FAILED) {
19959
+ s4 = [s4, s5, s6, s7, s8];
19960
+ s3 = s4;
19961
+ } else {
19962
+ peg$currPos = s3;
19963
+ s3 = peg$FAILED;
19964
+ }
19202
19965
  } else {
19203
- peg$currPos = s2;
19204
- s2 = peg$FAILED;
19966
+ peg$currPos = s3;
19967
+ s3 = peg$FAILED;
19205
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
- } else {
19219
- peg$currPos = s2;
19220
- s2 = peg$FAILED;
19221
19981
  }
19222
19982
  }
19223
19983
  }
19224
19984
  } else {
19225
- s1 = peg$FAILED;
19985
+ s2 = peg$FAILED;
19226
19986
  }
19227
- if (s1 !== peg$FAILED) {
19228
- s0 = input.substring(s0, peg$currPos);
19987
+ if (s2 !== peg$FAILED) {
19988
+ s1 = input.substring(s1, peg$currPos);
19229
19989
  } else {
19230
- s0 = s1;
19990
+ s1 = s2;
19991
+ }
19992
+ if (s1 !== peg$FAILED) {
19993
+ peg$savedPos = s0;
19994
+ s1 = peg$c63(s1);
19231
19995
  }
19996
+ s0 = s1;
19232
19997
  return s0;
19233
19998
  }
19234
19999
  function peg$parsecode_L() {
19235
20000
  var s0, s1, s2, s3, s4, s5, s6, s7, s8, s9, s10;
19236
20001
  s0 = peg$currPos;
19237
- s1 = peg$parsestart_code();
20002
+ s1 = peg$parsestart_code_2();
19238
20003
  if (s1 !== peg$FAILED) {
19239
20004
  peg$savedPos = peg$currPos;
19240
- s2 = peg$c57(s1);
20005
+ s2 = peg$c64(s1);
19241
20006
  if (s2) {
19242
20007
  s2 = void 0;
19243
20008
  } else {
@@ -19340,7 +20105,7 @@ var require_grammarfc = __commonJS({
19340
20105
  }
19341
20106
  if (s6 !== peg$FAILED) {
19342
20107
  peg$savedPos = s4;
19343
- s5 = peg$c58(s1, s3, s6);
20108
+ s5 = peg$c65(s1, s3, s6);
19344
20109
  s4 = s5;
19345
20110
  } else {
19346
20111
  peg$currPos = s4;
@@ -19356,9 +20121,21 @@ var require_grammarfc = __commonJS({
19356
20121
  if (s4 !== peg$FAILED) {
19357
20122
  s5 = peg$parseend_code();
19358
20123
  if (s5 !== peg$FAILED) {
19359
- peg$savedPos = s0;
19360
- s1 = peg$c59(s1, s3, s4);
19361
- s0 = s1;
20124
+ peg$savedPos = peg$currPos;
20125
+ s6 = peg$c66(s1, s3, s4, s5);
20126
+ if (s6) {
20127
+ s6 = void 0;
20128
+ } else {
20129
+ s6 = peg$FAILED;
20130
+ }
20131
+ if (s6 !== peg$FAILED) {
20132
+ peg$savedPos = s0;
20133
+ s1 = peg$c67(s1, s3, s4, s5);
20134
+ s0 = s1;
20135
+ } else {
20136
+ peg$currPos = s0;
20137
+ s0 = peg$FAILED;
20138
+ }
19362
20139
  } else {
19363
20140
  peg$currPos = s0;
19364
20141
  s0 = peg$FAILED;
@@ -19389,12 +20166,12 @@ var require_grammarfc = __commonJS({
19389
20166
  s3 = peg$currPos;
19390
20167
  peg$silentFails++;
19391
20168
  if (input.charCodeAt(peg$currPos) === 59) {
19392
- s4 = peg$c60;
20169
+ s4 = peg$c68;
19393
20170
  peg$currPos++;
19394
20171
  } else {
19395
20172
  s4 = peg$FAILED;
19396
20173
  if (peg$silentFails === 0) {
19397
- peg$fail(peg$c61);
20174
+ peg$fail(peg$c69);
19398
20175
  }
19399
20176
  }
19400
20177
  peg$silentFails--;
@@ -19447,12 +20224,12 @@ var require_grammarfc = __commonJS({
19447
20224
  s3 = peg$currPos;
19448
20225
  peg$silentFails++;
19449
20226
  if (input.charCodeAt(peg$currPos) === 59) {
19450
- s4 = peg$c60;
20227
+ s4 = peg$c68;
19451
20228
  peg$currPos++;
19452
20229
  } else {
19453
20230
  s4 = peg$FAILED;
19454
20231
  if (peg$silentFails === 0) {
19455
- peg$fail(peg$c61);
20232
+ peg$fail(peg$c69);
19456
20233
  }
19457
20234
  }
19458
20235
  peg$silentFails--;
@@ -19511,13 +20288,13 @@ var require_grammarfc = __commonJS({
19511
20288
  }
19512
20289
  function peg$parsehs() {
19513
20290
  var s0;
19514
- if (peg$c62.test(input.charAt(peg$currPos))) {
20291
+ if (peg$c70.test(input.charAt(peg$currPos))) {
19515
20292
  s0 = input.charAt(peg$currPos);
19516
20293
  peg$currPos++;
19517
20294
  } else {
19518
20295
  s0 = peg$FAILED;
19519
20296
  if (peg$silentFails === 0) {
19520
- peg$fail(peg$c63);
20297
+ peg$fail(peg$c71);
19521
20298
  }
19522
20299
  }
19523
20300
  return s0;
@@ -19535,12 +20312,12 @@ var require_grammarfc = __commonJS({
19535
20312
  }
19536
20313
  if (s2 !== peg$FAILED) {
19537
20314
  if (input.charCodeAt(peg$currPos) === 59) {
19538
- s3 = peg$c60;
20315
+ s3 = peg$c68;
19539
20316
  peg$currPos++;
19540
20317
  } else {
19541
20318
  s3 = peg$FAILED;
19542
20319
  if (peg$silentFails === 0) {
19543
- peg$fail(peg$c61);
20320
+ peg$fail(peg$c69);
19544
20321
  }
19545
20322
  }
19546
20323
  if (s3 !== peg$FAILED) {
@@ -19554,7 +20331,7 @@ var require_grammarfc = __commonJS({
19554
20331
  s5 = peg$parsearray_items();
19555
20332
  if (s5 !== peg$FAILED) {
19556
20333
  peg$savedPos = s0;
19557
- s1 = peg$c64(s1, s5);
20334
+ s1 = peg$c72(s1, s5);
19558
20335
  s0 = s1;
19559
20336
  } else {
19560
20337
  peg$currPos = s0;
@@ -19581,7 +20358,7 @@ var require_grammarfc = __commonJS({
19581
20358
  s1 = peg$parseitem();
19582
20359
  if (s1 !== peg$FAILED) {
19583
20360
  peg$savedPos = s0;
19584
- s1 = peg$c65(s1);
20361
+ s1 = peg$c73(s1);
19585
20362
  }
19586
20363
  s0 = s1;
19587
20364
  }
@@ -19593,7 +20370,7 @@ var require_grammarfc = __commonJS({
19593
20370
  s1 = peg$parsestart_code();
19594
20371
  if (s1 !== peg$FAILED) {
19595
20372
  peg$savedPos = peg$currPos;
19596
- s2 = peg$c66(s1);
20373
+ s2 = peg$c74(s1);
19597
20374
  if (s2) {
19598
20375
  s2 = void 0;
19599
20376
  } else {
@@ -19635,7 +20412,7 @@ var require_grammarfc = __commonJS({
19635
20412
  s5 = peg$parseend_code();
19636
20413
  if (s5 !== peg$FAILED) {
19637
20414
  peg$savedPos = s0;
19638
- s1 = peg$c67(s1, s3, s4);
20415
+ s1 = peg$c75(s1, s3, s4);
19639
20416
  s0 = s1;
19640
20417
  } else {
19641
20418
  peg$currPos = s0;
@@ -19665,7 +20442,7 @@ var require_grammarfc = __commonJS({
19665
20442
  s1 = peg$parsestart_code();
19666
20443
  if (s1 !== peg$FAILED) {
19667
20444
  peg$savedPos = peg$currPos;
19668
- s2 = peg$c68(s1);
20445
+ s2 = peg$c76(s1);
19669
20446
  if (s2) {
19670
20447
  s2 = void 0;
19671
20448
  } else {
@@ -19776,7 +20553,7 @@ var require_grammarfc = __commonJS({
19776
20553
  s1 = peg$parsestart_code();
19777
20554
  if (s1 !== peg$FAILED) {
19778
20555
  peg$savedPos = peg$currPos;
19779
- s2 = peg$c69(s1);
20556
+ s2 = peg$c77(s1);
19780
20557
  if (s2) {
19781
20558
  s2 = void 0;
19782
20559
  } else {
@@ -19885,25 +20662,25 @@ var require_grammarfc = __commonJS({
19885
20662
  var s0, s1, s2;
19886
20663
  s0 = peg$currPos;
19887
20664
  s1 = [];
19888
- if (peg$c70.test(input.charAt(peg$currPos))) {
20665
+ if (peg$c78.test(input.charAt(peg$currPos))) {
19889
20666
  s2 = input.charAt(peg$currPos);
19890
20667
  peg$currPos++;
19891
20668
  } else {
19892
20669
  s2 = peg$FAILED;
19893
20670
  if (peg$silentFails === 0) {
19894
- peg$fail(peg$c71);
20671
+ peg$fail(peg$c79);
19895
20672
  }
19896
20673
  }
19897
20674
  if (s2 !== peg$FAILED) {
19898
20675
  while (s2 !== peg$FAILED) {
19899
20676
  s1.push(s2);
19900
- if (peg$c70.test(input.charAt(peg$currPos))) {
20677
+ if (peg$c78.test(input.charAt(peg$currPos))) {
19901
20678
  s2 = input.charAt(peg$currPos);
19902
20679
  peg$currPos++;
19903
20680
  } else {
19904
20681
  s2 = peg$FAILED;
19905
20682
  if (peg$silentFails === 0) {
19906
- peg$fail(peg$c71);
20683
+ peg$fail(peg$c79);
19907
20684
  }
19908
20685
  }
19909
20686
  }
@@ -19920,20 +20697,20 @@ var require_grammarfc = __commonJS({
19920
20697
  function peg$parsedecimalNumber() {
19921
20698
  var s0, s1, s2;
19922
20699
  s0 = peg$currPos;
19923
- if (input.substr(peg$currPos, 2) === peg$c72) {
19924
- s1 = peg$c72;
20700
+ if (input.substr(peg$currPos, 2) === peg$c80) {
20701
+ s1 = peg$c80;
19925
20702
  peg$currPos += 2;
19926
20703
  } else {
19927
20704
  s1 = peg$FAILED;
19928
20705
  if (peg$silentFails === 0) {
19929
- peg$fail(peg$c73);
20706
+ peg$fail(peg$c81);
19930
20707
  }
19931
20708
  }
19932
20709
  if (s1 !== peg$FAILED) {
19933
20710
  s2 = peg$parsenumber();
19934
20711
  if (s2 !== peg$FAILED) {
19935
20712
  peg$savedPos = s0;
19936
- s1 = peg$c74(s2);
20713
+ s1 = peg$c82(s2);
19937
20714
  s0 = s1;
19938
20715
  } else {
19939
20716
  peg$currPos = s0;
@@ -19948,20 +20725,20 @@ var require_grammarfc = __commonJS({
19948
20725
  function peg$parseoctalNumber() {
19949
20726
  var s0, s1, s2;
19950
20727
  s0 = peg$currPos;
19951
- if (input.substr(peg$currPos, 2) === peg$c75) {
19952
- s1 = peg$c75;
20728
+ if (input.substr(peg$currPos, 2) === peg$c83) {
20729
+ s1 = peg$c83;
19953
20730
  peg$currPos += 2;
19954
20731
  } else {
19955
20732
  s1 = peg$FAILED;
19956
20733
  if (peg$silentFails === 0) {
19957
- peg$fail(peg$c76);
20734
+ peg$fail(peg$c84);
19958
20735
  }
19959
20736
  }
19960
20737
  if (s1 !== peg$FAILED) {
19961
20738
  s2 = peg$parsenumber();
19962
20739
  if (s2 !== peg$FAILED) {
19963
20740
  peg$savedPos = s0;
19964
- s1 = peg$c77(s2);
20741
+ s1 = peg$c85(s2);
19965
20742
  s0 = s1;
19966
20743
  } else {
19967
20744
  peg$currPos = s0;
@@ -19976,20 +20753,20 @@ var require_grammarfc = __commonJS({
19976
20753
  function peg$parsebinaryNumber() {
19977
20754
  var s0, s1, s2;
19978
20755
  s0 = peg$currPos;
19979
- if (input.substr(peg$currPos, 2) === peg$c78) {
19980
- s1 = peg$c78;
20756
+ if (input.substr(peg$currPos, 2) === peg$c86) {
20757
+ s1 = peg$c86;
19981
20758
  peg$currPos += 2;
19982
20759
  } else {
19983
20760
  s1 = peg$FAILED;
19984
20761
  if (peg$silentFails === 0) {
19985
- peg$fail(peg$c79);
20762
+ peg$fail(peg$c87);
19986
20763
  }
19987
20764
  }
19988
20765
  if (s1 !== peg$FAILED) {
19989
20766
  s2 = peg$parsenumber();
19990
20767
  if (s2 !== peg$FAILED) {
19991
20768
  peg$savedPos = s0;
19992
- s1 = peg$c80(s2);
20769
+ s1 = peg$c88(s2);
19993
20770
  s0 = s1;
19994
20771
  } else {
19995
20772
  peg$currPos = s0;
@@ -20006,36 +20783,36 @@ var require_grammarfc = __commonJS({
20006
20783
  s0 = peg$currPos;
20007
20784
  s1 = peg$currPos;
20008
20785
  s2 = peg$currPos;
20009
- if (input.substr(peg$currPos, 2) === peg$c81) {
20010
- s3 = peg$c81;
20786
+ if (input.substr(peg$currPos, 2) === peg$c89) {
20787
+ s3 = peg$c89;
20011
20788
  peg$currPos += 2;
20012
20789
  } else {
20013
20790
  s3 = peg$FAILED;
20014
20791
  if (peg$silentFails === 0) {
20015
- peg$fail(peg$c82);
20792
+ peg$fail(peg$c90);
20016
20793
  }
20017
20794
  }
20018
20795
  if (s3 !== peg$FAILED) {
20019
20796
  s4 = [];
20020
- if (peg$c83.test(input.charAt(peg$currPos))) {
20797
+ if (peg$c91.test(input.charAt(peg$currPos))) {
20021
20798
  s5 = input.charAt(peg$currPos);
20022
20799
  peg$currPos++;
20023
20800
  } else {
20024
20801
  s5 = peg$FAILED;
20025
20802
  if (peg$silentFails === 0) {
20026
- peg$fail(peg$c84);
20803
+ peg$fail(peg$c92);
20027
20804
  }
20028
20805
  }
20029
20806
  if (s5 !== peg$FAILED) {
20030
20807
  while (s5 !== peg$FAILED) {
20031
20808
  s4.push(s5);
20032
- if (peg$c83.test(input.charAt(peg$currPos))) {
20809
+ if (peg$c91.test(input.charAt(peg$currPos))) {
20033
20810
  s5 = input.charAt(peg$currPos);
20034
20811
  peg$currPos++;
20035
20812
  } else {
20036
20813
  s5 = peg$FAILED;
20037
20814
  if (peg$silentFails === 0) {
20038
- peg$fail(peg$c84);
20815
+ peg$fail(peg$c92);
20039
20816
  }
20040
20817
  }
20041
20818
  }
@@ -20060,7 +20837,7 @@ var require_grammarfc = __commonJS({
20060
20837
  }
20061
20838
  if (s1 !== peg$FAILED) {
20062
20839
  peg$savedPos = s0;
20063
- s1 = peg$c85();
20840
+ s1 = peg$c93();
20064
20841
  }
20065
20842
  s0 = s1;
20066
20843
  return s0;
@@ -20085,7 +20862,7 @@ var require_grammarfc = __commonJS({
20085
20862
  }
20086
20863
  if (s2 !== peg$FAILED) {
20087
20864
  peg$savedPos = s0;
20088
- s1 = peg$c86(s2);
20865
+ s1 = peg$c94(s2);
20089
20866
  s0 = s1;
20090
20867
  } else {
20091
20868
  peg$currPos = s0;
@@ -20110,12 +20887,12 @@ var require_grammarfc = __commonJS({
20110
20887
  }
20111
20888
  if (s2 !== peg$FAILED) {
20112
20889
  if (input.charCodeAt(peg$currPos) === 59) {
20113
- s3 = peg$c60;
20890
+ s3 = peg$c68;
20114
20891
  peg$currPos++;
20115
20892
  } else {
20116
20893
  s3 = peg$FAILED;
20117
20894
  if (peg$silentFails === 0) {
20118
- peg$fail(peg$c61);
20895
+ peg$fail(peg$c69);
20119
20896
  }
20120
20897
  }
20121
20898
  if (s3 !== peg$FAILED) {
@@ -20129,7 +20906,7 @@ var require_grammarfc = __commonJS({
20129
20906
  s5 = peg$parsearray_E_items();
20130
20907
  if (s5 !== peg$FAILED) {
20131
20908
  peg$savedPos = s0;
20132
- s1 = peg$c64(s1, s5);
20909
+ s1 = peg$c72(s1, s5);
20133
20910
  s0 = s1;
20134
20911
  } else {
20135
20912
  peg$currPos = s0;
@@ -20156,7 +20933,7 @@ var require_grammarfc = __commonJS({
20156
20933
  s1 = peg$parseitem_E();
20157
20934
  if (s1 !== peg$FAILED) {
20158
20935
  peg$savedPos = s0;
20159
- s1 = peg$c65(s1);
20936
+ s1 = peg$c73(s1);
20160
20937
  }
20161
20938
  s0 = s1;
20162
20939
  }
@@ -20168,7 +20945,7 @@ var require_grammarfc = __commonJS({
20168
20945
  s1 = peg$parsestart_code();
20169
20946
  if (s1 !== peg$FAILED) {
20170
20947
  peg$savedPos = peg$currPos;
20171
- s2 = peg$c87(s1);
20948
+ s2 = peg$c95(s1);
20172
20949
  if (s2) {
20173
20950
  s2 = void 0;
20174
20951
  } else {
@@ -20179,7 +20956,7 @@ var require_grammarfc = __commonJS({
20179
20956
  s4 = peg$parsearray_E_items();
20180
20957
  if (s4 !== peg$FAILED) {
20181
20958
  peg$savedPos = s3;
20182
- s4 = peg$c88(s1, s4);
20959
+ s4 = peg$c96(s1, s4);
20183
20960
  }
20184
20961
  s3 = s4;
20185
20962
  if (s3 === peg$FAILED) {
@@ -20189,7 +20966,7 @@ var require_grammarfc = __commonJS({
20189
20966
  s4 = peg$parseend_code();
20190
20967
  if (s4 !== peg$FAILED) {
20191
20968
  peg$savedPos = s0;
20192
- s1 = peg$c89(s1, s3);
20969
+ s1 = peg$c97(s1, s3);
20193
20970
  s0 = s1;
20194
20971
  } else {
20195
20972
  peg$currPos = s0;
@@ -20231,7 +21008,58 @@ var require_grammarfc = __commonJS({
20231
21008
  }
20232
21009
  if (s2 !== peg$FAILED) {
20233
21010
  peg$savedPos = s0;
20234
- s1 = peg$c90(s1);
21011
+ s1 = peg$c98(s1);
21012
+ s0 = s1;
21013
+ } else {
21014
+ peg$currPos = s0;
21015
+ s0 = peg$FAILED;
21016
+ }
21017
+ } else {
21018
+ peg$currPos = s0;
21019
+ s0 = peg$FAILED;
21020
+ }
21021
+ return s0;
21022
+ }
21023
+ function peg$parsestart_code_2() {
21024
+ var s0, s1, s2, s3;
21025
+ s0 = peg$currPos;
21026
+ s1 = peg$currPos;
21027
+ s2 = peg$parseallowed_code();
21028
+ if (s2 !== peg$FAILED) {
21029
+ s1 = input.substring(s1, peg$currPos);
21030
+ } else {
21031
+ s1 = s2;
21032
+ }
21033
+ if (s1 !== peg$FAILED) {
21034
+ s2 = peg$currPos;
21035
+ if (input.charCodeAt(peg$currPos) === 60) {
21036
+ s3 = peg$c48;
21037
+ peg$currPos++;
21038
+ } else {
21039
+ s3 = peg$FAILED;
21040
+ if (peg$silentFails === 0) {
21041
+ peg$fail(peg$c49);
21042
+ }
21043
+ }
21044
+ if (s3 === peg$FAILED) {
21045
+ if (input.charCodeAt(peg$currPos) === 171) {
21046
+ s3 = peg$c53;
21047
+ peg$currPos++;
21048
+ } else {
21049
+ s3 = peg$FAILED;
21050
+ if (peg$silentFails === 0) {
21051
+ peg$fail(peg$c54);
21052
+ }
21053
+ }
21054
+ }
21055
+ if (s3 !== peg$FAILED) {
21056
+ s2 = input.substring(s2, peg$currPos);
21057
+ } else {
21058
+ s2 = s3;
21059
+ }
21060
+ if (s2 !== peg$FAILED) {
21061
+ peg$savedPos = s0;
21062
+ s1 = peg$c99(s1, s2);
20235
21063
  s0 = s1;
20236
21064
  } else {
20237
21065
  peg$currPos = s0;
@@ -20254,15 +21082,26 @@ var require_grammarfc = __commonJS({
20254
21082
  peg$fail(peg$c51);
20255
21083
  }
20256
21084
  }
21085
+ if (s0 === peg$FAILED) {
21086
+ if (input.charCodeAt(peg$currPos) === 187) {
21087
+ s0 = peg$c55;
21088
+ peg$currPos++;
21089
+ } else {
21090
+ s0 = peg$FAILED;
21091
+ if (peg$silentFails === 0) {
21092
+ peg$fail(peg$c56);
21093
+ }
21094
+ }
21095
+ }
20257
21096
  return s0;
20258
21097
  }
20259
- function peg$parsecode() {
20260
- var s0, s1, s2, s3, s4;
21098
+ function peg$parsecode_2() {
21099
+ var s0, s1, s2, s3, s4, s5;
20261
21100
  s0 = peg$currPos;
20262
- s1 = peg$parsestart_code();
21101
+ s1 = peg$parsestart_code_2();
20263
21102
  if (s1 !== peg$FAILED) {
20264
21103
  peg$savedPos = peg$currPos;
20265
- s2 = peg$c91(s1);
21104
+ s2 = peg$c100(s1);
20266
21105
  if (s2) {
20267
21106
  s2 = void 0;
20268
21107
  } else {
@@ -20272,7 +21111,7 @@ var require_grammarfc = __commonJS({
20272
21111
  s3 = [];
20273
21112
  s4 = peg$parseallowed_rules();
20274
21113
  if (s4 === peg$FAILED) {
20275
- s4 = peg$parsecode();
21114
+ s4 = peg$parsecode_2();
20276
21115
  if (s4 === peg$FAILED) {
20277
21116
  s4 = peg$parsetext();
20278
21117
  }
@@ -20281,7 +21120,7 @@ var require_grammarfc = __commonJS({
20281
21120
  s3.push(s4);
20282
21121
  s4 = peg$parseallowed_rules();
20283
21122
  if (s4 === peg$FAILED) {
20284
- s4 = peg$parsecode();
21123
+ s4 = peg$parsecode_2();
20285
21124
  if (s4 === peg$FAILED) {
20286
21125
  s4 = peg$parsetext();
20287
21126
  }
@@ -20290,9 +21129,21 @@ var require_grammarfc = __commonJS({
20290
21129
  if (s3 !== peg$FAILED) {
20291
21130
  s4 = peg$parseend_code();
20292
21131
  if (s4 !== peg$FAILED) {
20293
- peg$savedPos = s0;
20294
- s1 = peg$c92(s1, s3);
20295
- s0 = s1;
21132
+ peg$savedPos = peg$currPos;
21133
+ s5 = peg$c101(s1, s3, s4);
21134
+ if (s5) {
21135
+ s5 = void 0;
21136
+ } else {
21137
+ s5 = peg$FAILED;
21138
+ }
21139
+ if (s5 !== peg$FAILED) {
21140
+ peg$savedPos = s0;
21141
+ s1 = peg$c102(s1, s3, s4);
21142
+ s0 = s1;
21143
+ } else {
21144
+ peg$currPos = s0;
21145
+ s0 = peg$FAILED;
21146
+ }
20296
21147
  } else {
20297
21148
  peg$currPos = s0;
20298
21149
  s0 = peg$FAILED;
@@ -20432,9 +21283,48 @@ var require_grammarfc = __commonJS({
20432
21283
  s3 = peg$FAILED;
20433
21284
  }
20434
21285
  if (s3 === peg$FAILED) {
20435
- s3 = peg$parselooks_like_code();
21286
+ s3 = peg$currPos;
21287
+ if (input.charCodeAt(peg$currPos) === 171) {
21288
+ s4 = peg$c53;
21289
+ peg$currPos++;
21290
+ } else {
21291
+ s4 = peg$FAILED;
21292
+ if (peg$silentFails === 0) {
21293
+ peg$fail(peg$c54);
21294
+ }
21295
+ }
21296
+ if (s4 !== peg$FAILED) {
21297
+ s5 = peg$parsetext();
21298
+ if (s5 !== peg$FAILED) {
21299
+ if (input.charCodeAt(peg$currPos) === 187) {
21300
+ s6 = peg$c55;
21301
+ peg$currPos++;
21302
+ } else {
21303
+ s6 = peg$FAILED;
21304
+ if (peg$silentFails === 0) {
21305
+ peg$fail(peg$c56);
21306
+ }
21307
+ }
21308
+ if (s6 !== peg$FAILED) {
21309
+ s4 = [s4, s5, s6];
21310
+ s3 = s4;
21311
+ } else {
21312
+ peg$currPos = s3;
21313
+ s3 = peg$FAILED;
21314
+ }
21315
+ } else {
21316
+ peg$currPos = s3;
21317
+ s3 = peg$FAILED;
21318
+ }
21319
+ } else {
21320
+ peg$currPos = s3;
21321
+ s3 = peg$FAILED;
21322
+ }
20436
21323
  if (s3 === peg$FAILED) {
20437
- s3 = peg$parsenot_code();
21324
+ s3 = peg$parselooks_like_code();
21325
+ if (s3 === peg$FAILED) {
21326
+ s3 = peg$parsenot_code();
21327
+ }
20438
21328
  }
20439
21329
  }
20440
21330
  if (s3 !== peg$FAILED) {
@@ -20478,9 +21368,48 @@ var require_grammarfc = __commonJS({
20478
21368
  s3 = peg$FAILED;
20479
21369
  }
20480
21370
  if (s3 === peg$FAILED) {
20481
- s3 = peg$parselooks_like_code();
21371
+ s3 = peg$currPos;
21372
+ if (input.charCodeAt(peg$currPos) === 171) {
21373
+ s4 = peg$c53;
21374
+ peg$currPos++;
21375
+ } else {
21376
+ s4 = peg$FAILED;
21377
+ if (peg$silentFails === 0) {
21378
+ peg$fail(peg$c54);
21379
+ }
21380
+ }
21381
+ if (s4 !== peg$FAILED) {
21382
+ s5 = peg$parsetext();
21383
+ if (s5 !== peg$FAILED) {
21384
+ if (input.charCodeAt(peg$currPos) === 187) {
21385
+ s6 = peg$c55;
21386
+ peg$currPos++;
21387
+ } else {
21388
+ s6 = peg$FAILED;
21389
+ if (peg$silentFails === 0) {
21390
+ peg$fail(peg$c56);
21391
+ }
21392
+ }
21393
+ if (s6 !== peg$FAILED) {
21394
+ s4 = [s4, s5, s6];
21395
+ s3 = s4;
21396
+ } else {
21397
+ peg$currPos = s3;
21398
+ s3 = peg$FAILED;
21399
+ }
21400
+ } else {
21401
+ peg$currPos = s3;
21402
+ s3 = peg$FAILED;
21403
+ }
21404
+ } else {
21405
+ peg$currPos = s3;
21406
+ s3 = peg$FAILED;
21407
+ }
20482
21408
  if (s3 === peg$FAILED) {
20483
- s3 = peg$parsenot_code();
21409
+ s3 = peg$parselooks_like_code();
21410
+ if (s3 === peg$FAILED) {
21411
+ s3 = peg$parsenot_code();
21412
+ }
20484
21413
  }
20485
21414
  }
20486
21415
  }
@@ -20494,7 +21423,7 @@ var require_grammarfc = __commonJS({
20494
21423
  }
20495
21424
  if (s1 !== peg$FAILED) {
20496
21425
  peg$savedPos = s0;
20497
- s1 = peg$c53(s1);
21426
+ s1 = peg$c57(s1);
20498
21427
  }
20499
21428
  s0 = s1;
20500
21429
  return s0;
@@ -20518,7 +21447,7 @@ var require_grammarfc = __commonJS({
20518
21447
  if (s4 !== peg$FAILED) {
20519
21448
  s5 = peg$currPos;
20520
21449
  peg$silentFails++;
20521
- s6 = peg$parsestart_code();
21450
+ s6 = peg$parsestart_code_2();
20522
21451
  peg$silentFails--;
20523
21452
  if (s6 === peg$FAILED) {
20524
21453
  s5 = void 0;
@@ -20583,7 +21512,7 @@ var require_grammarfc = __commonJS({
20583
21512
  if (s4 !== peg$FAILED) {
20584
21513
  s5 = peg$currPos;
20585
21514
  peg$silentFails++;
20586
- s6 = peg$parsestart_code();
21515
+ s6 = peg$parsestart_code_2();
20587
21516
  peg$silentFails--;
20588
21517
  if (s6 === peg$FAILED) {
20589
21518
  s5 = void 0;
@@ -20642,7 +21571,7 @@ var require_grammarfc = __commonJS({
20642
21571
  }
20643
21572
  if (s1 !== peg$FAILED) {
20644
21573
  peg$savedPos = s0;
20645
- s1 = peg$c53(s1);
21574
+ s1 = peg$c57(s1);
20646
21575
  }
20647
21576
  s0 = s1;
20648
21577
  return s0;
@@ -20724,11 +21653,92 @@ var require_grammarfc = __commonJS({
20724
21653
  peg$currPos = s0;
20725
21654
  s0 = peg$FAILED;
20726
21655
  }
21656
+ if (s0 === peg$FAILED) {
21657
+ s0 = peg$currPos;
21658
+ s1 = peg$currPos;
21659
+ s2 = peg$currPos;
21660
+ peg$silentFails++;
21661
+ s3 = peg$parseallowed_code();
21662
+ peg$silentFails--;
21663
+ if (s3 === peg$FAILED) {
21664
+ s2 = void 0;
21665
+ } else {
21666
+ peg$currPos = s2;
21667
+ s2 = peg$FAILED;
21668
+ }
21669
+ if (s2 !== peg$FAILED) {
21670
+ if (input.length > peg$currPos) {
21671
+ s3 = input.charAt(peg$currPos);
21672
+ peg$currPos++;
21673
+ } else {
21674
+ s3 = peg$FAILED;
21675
+ if (peg$silentFails === 0) {
21676
+ peg$fail(peg$c39);
21677
+ }
21678
+ }
21679
+ if (s3 !== peg$FAILED) {
21680
+ s2 = [s2, s3];
21681
+ s1 = s2;
21682
+ } else {
21683
+ peg$currPos = s1;
21684
+ s1 = peg$FAILED;
21685
+ }
21686
+ } else {
21687
+ peg$currPos = s1;
21688
+ s1 = peg$FAILED;
21689
+ }
21690
+ if (s1 !== peg$FAILED) {
21691
+ if (input.charCodeAt(peg$currPos) === 171) {
21692
+ s2 = peg$c53;
21693
+ peg$currPos++;
21694
+ } else {
21695
+ s2 = peg$FAILED;
21696
+ if (peg$silentFails === 0) {
21697
+ peg$fail(peg$c54);
21698
+ }
21699
+ }
21700
+ if (s2 !== peg$FAILED) {
21701
+ s3 = peg$parsenot_code();
21702
+ if (s3 !== peg$FAILED) {
21703
+ if (input.charCodeAt(peg$currPos) === 187) {
21704
+ s4 = peg$c55;
21705
+ peg$currPos++;
21706
+ } else {
21707
+ s4 = peg$FAILED;
21708
+ if (peg$silentFails === 0) {
21709
+ peg$fail(peg$c56);
21710
+ }
21711
+ }
21712
+ if (s4 !== peg$FAILED) {
21713
+ peg$savedPos = s0;
21714
+ s1 = peg$c52();
21715
+ s0 = s1;
21716
+ } else {
21717
+ peg$currPos = s0;
21718
+ s0 = peg$FAILED;
21719
+ }
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
+ }
20727
21733
  return s0;
20728
21734
  }
20729
21735
  function flattenDeep5(arr) {
20730
21736
  return arr.reduce((acc, val) => Array.isArray(val) ? acc.concat(flattenDeep5(val)) : acc.concat(val), []);
20731
21737
  }
21738
+ function get_pair_tag(tag) {
21739
+ const map = {"<": ">", "\xAB": "\xBB", ">": "<", "\xBB": "\xAB"};
21740
+ return map[tag];
21741
+ }
20732
21742
  peg$result = peg$startRuleFunction();
20733
21743
  if (peg$result !== peg$FAILED && peg$currPos === input.length) {
20734
21744
  return peg$result;
@@ -20751,14 +21761,15 @@ var require_package = __commonJS({
20751
21761
  "../podlite-schema/package.json"(exports, module) {
20752
21762
  module.exports = {
20753
21763
  name: "@podlite/schema",
20754
- version: "0.0.13",
20755
- description: "podlite schema",
20756
- main: "src/index.ts",
21764
+ version: "0.0.15",
21765
+ description: "AST tools for Podlite markup language",
21766
+ main: "./src/index.ts",
20757
21767
  types: "./lib/index.d.ts",
20758
21768
  license: "MIT",
20759
21769
  files: [
20760
21770
  "lib/**/*.js",
20761
21771
  "lib/**/*.d.ts",
21772
+ "esm",
20762
21773
  "schema/*",
20763
21774
  "README.md",
20764
21775
  "CHANGELOG.md"
@@ -20770,16 +21781,17 @@ var require_package = __commonJS({
20770
21781
  publishConfig: {
20771
21782
  access: "public",
20772
21783
  main: "lib/index.js",
20773
- types: "./lib/index.d.ts"
21784
+ types: "./lib/index.d.ts",
21785
+ module: "./esm/index.js"
20774
21786
  },
20775
21787
  scripts: {
20776
- clean: "rm -rf lib esm tsconfig.tsbuildinfo",
20777
- build: "run-s build:pegjs build:ts build:ast ",
21788
+ clean: "rm -rf lib esm *.tsbuildinfo",
21789
+ build: "run-s build:pegjs build_lib build:ast ",
21790
+ build_lib: "yarn g:build",
20778
21791
  "build:ast": "ts-node scripts/make-ast-scheme.ts",
20779
- "build:ts": "yarn g:tsc --build $INIT_CWD",
20780
- "build:esm": "yarn g:tsctest -p tsconfig.esm.json",
20781
21792
  "build:pegjs": "pegjs -o src/grammar.js src/grammar.pegjs && pegjs -o src/grammarfc.js src/grammarfc.pegjs",
20782
21793
  watch: "npx nodemon -e js,ts --exec 'yarn' build",
21794
+ "watch:pegjs": "npx nodemon -e pegjs --exec 'yarn' build:pegjs",
20783
21795
  test: "yarn g:jest --passWithNoTests"
20784
21796
  },
20785
21797
  keywords: [
@@ -20965,33 +21977,33 @@ Everything else 57
20965
21977
  `
20966
21978
  },
20967
21979
  {
20968
- displayText: "Toc head1, head2, head3",
20969
- text: `=Toc head1, head2, head3
21980
+ displayText: "toc head1, head2, head3",
21981
+ text: `=toc head1, head2, head3
20970
21982
  `
20971
21983
  },
20972
21984
  {
20973
- displayText: "Toc (with :title) \u{1F3F7}",
20974
- text: `=for Toc :title('Table of contents')
21985
+ displayText: "toc (with :title) \u{1F3F7}",
21986
+ text: `=for toc :title('Table of contents')
20975
21987
  head1, head2, head3
20976
21988
 
20977
21989
  `
20978
21990
  },
20979
21991
  {
20980
- displayText: "Toc ( Images, Diagrams ) + tables \u{1F3F7}",
20981
- text: `=for Toc :title('List of media')
21992
+ displayText: "toc ( Images, Diagrams ) + tables \u{1F3F7}",
21993
+ text: `=for toc :title('List of media')
20982
21994
  Image, Diagram
20983
- =for Toc :title('List of tables')
21995
+ =for toc :title('List of tables')
20984
21996
  table
20985
21997
 
20986
21998
  `
20987
21999
  },
20988
22000
  {
20989
- displayText: "Markdown",
20990
- text: `=begin Markdown
22001
+ displayText: "markdown",
22002
+ text: `=begin markdown
20991
22003
 
20992
22004
  {}
20993
22005
 
20994
- =end Markdown
22006
+ =end markdown
20995
22007
  `
20996
22008
  },
20997
22009
  {
@@ -21853,8 +22865,9 @@ var middle2 = () => (tree) => {
21853
22865
  const conf = config_default(n, ctx);
21854
22866
  const isCodeBlock = "name" in n && n.name === "code";
21855
22867
  const isDataBlock = "name" in n && n.name === "data";
22868
+ const isMarkdownBlock = "name" in n && n.name === "markdown";
21856
22869
  const allowValues = conf.getAllValues("allow");
21857
- if ((isCodeBlock || isDataBlock) && allowValues.length == 0)
22870
+ if ((isCodeBlock || isDataBlock || isMarkdownBlock) && allowValues.length == 0)
21858
22871
  return n;
21859
22872
  const allowed = allowValues.sort();
21860
22873
  const transformer = makeTransformer_default({