@wireweave/core 3.1.0-beta.10 → 3.1.0-beta.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +174 -51
- package/dist/index.js +174 -51
- package/dist/parser.cjs +134 -37
- package/dist/parser.js +134 -37
- package/dist/renderer.cjs +40 -14
- package/dist/renderer.js +40 -14
- package/dist/spec.cjs +1 -6
- package/dist/spec.js +1 -6
- package/package.json +2 -1
package/dist/parser.cjs
CHANGED
|
@@ -72,10 +72,14 @@ var peg$SyntaxError = class extends SyntaxError {
|
|
|
72
72
|
return s;
|
|
73
73
|
}
|
|
74
74
|
function literalEscape(s) {
|
|
75
|
-
return unicodeEscape(
|
|
75
|
+
return unicodeEscape(
|
|
76
|
+
s.replace(/\\/g, "\\\\").replace(/"/g, '\\"').replace(/\0/g, "\\0").replace(/\t/g, "\\t").replace(/\n/g, "\\n").replace(/\r/g, "\\r").replace(/[\x00-\x0F]/g, (ch) => "\\x0" + hex(ch)).replace(/[\x10-\x1F\x7F-\x9F]/g, (ch) => "\\x" + hex(ch))
|
|
77
|
+
);
|
|
76
78
|
}
|
|
77
79
|
function classEscape(s) {
|
|
78
|
-
return unicodeEscape(
|
|
80
|
+
return unicodeEscape(
|
|
81
|
+
s.replace(/\\/g, "\\\\").replace(/\]/g, "\\]").replace(/\^/g, "\\^").replace(/-/g, "\\-").replace(/\0/g, "\\0").replace(/\t/g, "\\t").replace(/\n/g, "\\n").replace(/\r/g, "\\r").replace(/[\x00-\x0F]/g, (ch) => "\\x0" + hex(ch)).replace(/[\x10-\x1F\x7F-\x9F]/g, (ch) => "\\x" + hex(ch))
|
|
82
|
+
);
|
|
79
83
|
}
|
|
80
84
|
const DESCRIBE_EXPECTATION_FNS = {
|
|
81
85
|
literal(expectation) {
|
|
@@ -312,7 +316,12 @@ function peg$parse(input, options) {
|
|
|
312
316
|
const peg$e75 = peg$classExpectation([["0", "9"]], false, false, false);
|
|
313
317
|
const peg$e76 = peg$literalExpectation("at", false);
|
|
314
318
|
const peg$e77 = peg$classExpectation(["=", "[", "{", "}"], false, false, false);
|
|
315
|
-
const peg$e78 = peg$classExpectation(
|
|
319
|
+
const peg$e78 = peg$classExpectation(
|
|
320
|
+
[["a", "z"], ["A", "Z"], ["0", "9"], "_", "-"],
|
|
321
|
+
false,
|
|
322
|
+
false,
|
|
323
|
+
false
|
|
324
|
+
);
|
|
316
325
|
const peg$e79 = peg$otherExpectation("string");
|
|
317
326
|
const peg$e80 = peg$literalExpectation('"', false);
|
|
318
327
|
const peg$e81 = peg$literalExpectation("'", false);
|
|
@@ -6057,7 +6066,10 @@ function peg$parse(input, options) {
|
|
|
6057
6066
|
}
|
|
6058
6067
|
}
|
|
6059
6068
|
if (s1 === peg$FAILED) {
|
|
6060
|
-
if (input.substr(
|
|
6069
|
+
if (input.substr(
|
|
6070
|
+
peg$currPos,
|
|
6071
|
+
5
|
|
6072
|
+
) === peg$c57) {
|
|
6061
6073
|
s1 = peg$c57;
|
|
6062
6074
|
peg$currPos += 5;
|
|
6063
6075
|
} else {
|
|
@@ -6067,7 +6079,10 @@ function peg$parse(input, options) {
|
|
|
6067
6079
|
}
|
|
6068
6080
|
}
|
|
6069
6081
|
if (s1 === peg$FAILED) {
|
|
6070
|
-
if (input.substr(
|
|
6082
|
+
if (input.substr(
|
|
6083
|
+
peg$currPos,
|
|
6084
|
+
8
|
|
6085
|
+
) === peg$c58) {
|
|
6071
6086
|
s1 = peg$c58;
|
|
6072
6087
|
peg$currPos += 8;
|
|
6073
6088
|
} else {
|
|
@@ -6077,7 +6092,10 @@ function peg$parse(input, options) {
|
|
|
6077
6092
|
}
|
|
6078
6093
|
}
|
|
6079
6094
|
if (s1 === peg$FAILED) {
|
|
6080
|
-
if (input.substr(
|
|
6095
|
+
if (input.substr(
|
|
6096
|
+
peg$currPos,
|
|
6097
|
+
7
|
|
6098
|
+
) === peg$c59) {
|
|
6081
6099
|
s1 = peg$c59;
|
|
6082
6100
|
peg$currPos += 7;
|
|
6083
6101
|
} else {
|
|
@@ -6087,7 +6105,10 @@ function peg$parse(input, options) {
|
|
|
6087
6105
|
}
|
|
6088
6106
|
}
|
|
6089
6107
|
if (s1 === peg$FAILED) {
|
|
6090
|
-
if (input.substr(
|
|
6108
|
+
if (input.substr(
|
|
6109
|
+
peg$currPos,
|
|
6110
|
+
7
|
|
6111
|
+
) === peg$c60) {
|
|
6091
6112
|
s1 = peg$c60;
|
|
6092
6113
|
peg$currPos += 7;
|
|
6093
6114
|
} else {
|
|
@@ -6097,7 +6118,10 @@ function peg$parse(input, options) {
|
|
|
6097
6118
|
}
|
|
6098
6119
|
}
|
|
6099
6120
|
if (s1 === peg$FAILED) {
|
|
6100
|
-
if (input.substr(
|
|
6121
|
+
if (input.substr(
|
|
6122
|
+
peg$currPos,
|
|
6123
|
+
7
|
|
6124
|
+
) === peg$c61) {
|
|
6101
6125
|
s1 = peg$c61;
|
|
6102
6126
|
peg$currPos += 7;
|
|
6103
6127
|
} else {
|
|
@@ -6107,7 +6131,10 @@ function peg$parse(input, options) {
|
|
|
6107
6131
|
}
|
|
6108
6132
|
}
|
|
6109
6133
|
if (s1 === peg$FAILED) {
|
|
6110
|
-
if (input.substr(
|
|
6134
|
+
if (input.substr(
|
|
6135
|
+
peg$currPos,
|
|
6136
|
+
8
|
|
6137
|
+
) === peg$c62) {
|
|
6111
6138
|
s1 = peg$c62;
|
|
6112
6139
|
peg$currPos += 8;
|
|
6113
6140
|
} else {
|
|
@@ -6117,143 +6144,213 @@ function peg$parse(input, options) {
|
|
|
6117
6144
|
}
|
|
6118
6145
|
}
|
|
6119
6146
|
if (s1 === peg$FAILED) {
|
|
6120
|
-
if (input.substr(
|
|
6147
|
+
if (input.substr(
|
|
6148
|
+
peg$currPos,
|
|
6149
|
+
7
|
|
6150
|
+
) === peg$c63) {
|
|
6121
6151
|
s1 = peg$c63;
|
|
6122
6152
|
peg$currPos += 7;
|
|
6123
6153
|
} else {
|
|
6124
6154
|
s1 = peg$FAILED;
|
|
6125
6155
|
if (peg$silentFails === 0) {
|
|
6126
|
-
peg$fail(
|
|
6156
|
+
peg$fail(
|
|
6157
|
+
peg$e66
|
|
6158
|
+
);
|
|
6127
6159
|
}
|
|
6128
6160
|
}
|
|
6129
6161
|
if (s1 === peg$FAILED) {
|
|
6130
|
-
if (input.substr(
|
|
6162
|
+
if (input.substr(
|
|
6163
|
+
peg$currPos,
|
|
6164
|
+
3
|
|
6165
|
+
) === peg$c64) {
|
|
6131
6166
|
s1 = peg$c64;
|
|
6132
6167
|
peg$currPos += 3;
|
|
6133
6168
|
} else {
|
|
6134
6169
|
s1 = peg$FAILED;
|
|
6135
6170
|
if (peg$silentFails === 0) {
|
|
6136
|
-
peg$fail(
|
|
6171
|
+
peg$fail(
|
|
6172
|
+
peg$e67
|
|
6173
|
+
);
|
|
6137
6174
|
}
|
|
6138
6175
|
}
|
|
6139
6176
|
if (s1 === peg$FAILED) {
|
|
6140
|
-
if (input.substr(
|
|
6177
|
+
if (input.substr(
|
|
6178
|
+
peg$currPos,
|
|
6179
|
+
4
|
|
6180
|
+
) === peg$c66) {
|
|
6141
6181
|
s1 = peg$c66;
|
|
6142
6182
|
peg$currPos += 4;
|
|
6143
6183
|
} else {
|
|
6144
6184
|
s1 = peg$FAILED;
|
|
6145
6185
|
if (peg$silentFails === 0) {
|
|
6146
|
-
peg$fail(
|
|
6186
|
+
peg$fail(
|
|
6187
|
+
peg$e69
|
|
6188
|
+
);
|
|
6147
6189
|
}
|
|
6148
6190
|
}
|
|
6149
6191
|
if (s1 === peg$FAILED) {
|
|
6150
|
-
if (input.substr(
|
|
6192
|
+
if (input.substr(
|
|
6193
|
+
peg$currPos,
|
|
6194
|
+
3
|
|
6195
|
+
) === peg$c67) {
|
|
6151
6196
|
s1 = peg$c67;
|
|
6152
6197
|
peg$currPos += 3;
|
|
6153
6198
|
} else {
|
|
6154
6199
|
s1 = peg$FAILED;
|
|
6155
6200
|
if (peg$silentFails === 0) {
|
|
6156
|
-
peg$fail(
|
|
6201
|
+
peg$fail(
|
|
6202
|
+
peg$e70
|
|
6203
|
+
);
|
|
6157
6204
|
}
|
|
6158
6205
|
}
|
|
6159
6206
|
if (s1 === peg$FAILED) {
|
|
6160
|
-
if (input.substr(
|
|
6207
|
+
if (input.substr(
|
|
6208
|
+
peg$currPos,
|
|
6209
|
+
10
|
|
6210
|
+
) === peg$c68) {
|
|
6161
6211
|
s1 = peg$c68;
|
|
6162
6212
|
peg$currPos += 10;
|
|
6163
6213
|
} else {
|
|
6164
6214
|
s1 = peg$FAILED;
|
|
6165
6215
|
if (peg$silentFails === 0) {
|
|
6166
|
-
peg$fail(
|
|
6216
|
+
peg$fail(
|
|
6217
|
+
peg$e71
|
|
6218
|
+
);
|
|
6167
6219
|
}
|
|
6168
6220
|
}
|
|
6169
6221
|
if (s1 === peg$FAILED) {
|
|
6170
|
-
if (input.substr(
|
|
6222
|
+
if (input.substr(
|
|
6223
|
+
peg$currPos,
|
|
6224
|
+
5
|
|
6225
|
+
) === peg$c65) {
|
|
6171
6226
|
s1 = peg$c65;
|
|
6172
6227
|
peg$currPos += 5;
|
|
6173
6228
|
} else {
|
|
6174
6229
|
s1 = peg$FAILED;
|
|
6175
6230
|
if (peg$silentFails === 0) {
|
|
6176
|
-
peg$fail(
|
|
6231
|
+
peg$fail(
|
|
6232
|
+
peg$e68
|
|
6233
|
+
);
|
|
6177
6234
|
}
|
|
6178
6235
|
}
|
|
6179
6236
|
if (s1 === peg$FAILED) {
|
|
6180
|
-
if (input.substr(
|
|
6237
|
+
if (input.substr(
|
|
6238
|
+
peg$currPos,
|
|
6239
|
+
6
|
|
6240
|
+
) === peg$c69) {
|
|
6181
6241
|
s1 = peg$c69;
|
|
6182
6242
|
peg$currPos += 6;
|
|
6183
6243
|
} else {
|
|
6184
6244
|
s1 = peg$FAILED;
|
|
6185
6245
|
if (peg$silentFails === 0) {
|
|
6186
|
-
peg$fail(
|
|
6246
|
+
peg$fail(
|
|
6247
|
+
peg$e72
|
|
6248
|
+
);
|
|
6187
6249
|
}
|
|
6188
6250
|
}
|
|
6189
6251
|
if (s1 === peg$FAILED) {
|
|
6190
|
-
if (input.substr(
|
|
6252
|
+
if (input.substr(
|
|
6253
|
+
peg$currPos,
|
|
6254
|
+
11
|
|
6255
|
+
) === peg$c70) {
|
|
6191
6256
|
s1 = peg$c70;
|
|
6192
6257
|
peg$currPos += 11;
|
|
6193
6258
|
} else {
|
|
6194
6259
|
s1 = peg$FAILED;
|
|
6195
6260
|
if (peg$silentFails === 0) {
|
|
6196
|
-
peg$fail(
|
|
6261
|
+
peg$fail(
|
|
6262
|
+
peg$e73
|
|
6263
|
+
);
|
|
6197
6264
|
}
|
|
6198
6265
|
}
|
|
6199
6266
|
if (s1 === peg$FAILED) {
|
|
6200
|
-
if (input.substr(
|
|
6267
|
+
if (input.substr(
|
|
6268
|
+
peg$currPos,
|
|
6269
|
+
6
|
|
6270
|
+
) === peg$c20) {
|
|
6201
6271
|
s1 = peg$c20;
|
|
6202
6272
|
peg$currPos += 6;
|
|
6203
6273
|
} else {
|
|
6204
6274
|
s1 = peg$FAILED;
|
|
6205
6275
|
if (peg$silentFails === 0) {
|
|
6206
|
-
peg$fail(
|
|
6276
|
+
peg$fail(
|
|
6277
|
+
peg$e23
|
|
6278
|
+
);
|
|
6207
6279
|
}
|
|
6208
6280
|
}
|
|
6209
6281
|
if (s1 === peg$FAILED) {
|
|
6210
|
-
if (input.substr(
|
|
6282
|
+
if (input.substr(
|
|
6283
|
+
peg$currPos,
|
|
6284
|
+
6
|
|
6285
|
+
) === peg$c3) {
|
|
6211
6286
|
s1 = peg$c3;
|
|
6212
6287
|
peg$currPos += 6;
|
|
6213
6288
|
} else {
|
|
6214
6289
|
s1 = peg$FAILED;
|
|
6215
6290
|
if (peg$silentFails === 0) {
|
|
6216
|
-
peg$fail(
|
|
6291
|
+
peg$fail(
|
|
6292
|
+
peg$e3
|
|
6293
|
+
);
|
|
6217
6294
|
}
|
|
6218
6295
|
}
|
|
6219
6296
|
if (s1 === peg$FAILED) {
|
|
6220
|
-
if (input.substr(
|
|
6297
|
+
if (input.substr(
|
|
6298
|
+
peg$currPos,
|
|
6299
|
+
9
|
|
6300
|
+
) === peg$c4) {
|
|
6221
6301
|
s1 = peg$c4;
|
|
6222
6302
|
peg$currPos += 9;
|
|
6223
6303
|
} else {
|
|
6224
6304
|
s1 = peg$FAILED;
|
|
6225
6305
|
if (peg$silentFails === 0) {
|
|
6226
|
-
peg$fail(
|
|
6306
|
+
peg$fail(
|
|
6307
|
+
peg$e4
|
|
6308
|
+
);
|
|
6227
6309
|
}
|
|
6228
6310
|
}
|
|
6229
6311
|
if (s1 === peg$FAILED) {
|
|
6230
|
-
if (input.substr(
|
|
6312
|
+
if (input.substr(
|
|
6313
|
+
peg$currPos,
|
|
6314
|
+
3
|
|
6315
|
+
) === peg$c12) {
|
|
6231
6316
|
s1 = peg$c12;
|
|
6232
6317
|
peg$currPos += 3;
|
|
6233
6318
|
} else {
|
|
6234
6319
|
s1 = peg$FAILED;
|
|
6235
6320
|
if (peg$silentFails === 0) {
|
|
6236
|
-
peg$fail(
|
|
6321
|
+
peg$fail(
|
|
6322
|
+
peg$e12
|
|
6323
|
+
);
|
|
6237
6324
|
}
|
|
6238
6325
|
}
|
|
6239
6326
|
if (s1 === peg$FAILED) {
|
|
6240
|
-
if (input.substr(
|
|
6327
|
+
if (input.substr(
|
|
6328
|
+
peg$currPos,
|
|
6329
|
+
4
|
|
6330
|
+
) === peg$c15) {
|
|
6241
6331
|
s1 = peg$c15;
|
|
6242
6332
|
peg$currPos += 4;
|
|
6243
6333
|
} else {
|
|
6244
6334
|
s1 = peg$FAILED;
|
|
6245
6335
|
if (peg$silentFails === 0) {
|
|
6246
|
-
peg$fail(
|
|
6336
|
+
peg$fail(
|
|
6337
|
+
peg$e15
|
|
6338
|
+
);
|
|
6247
6339
|
}
|
|
6248
6340
|
}
|
|
6249
6341
|
if (s1 === peg$FAILED) {
|
|
6250
|
-
if (input.substr(
|
|
6342
|
+
if (input.substr(
|
|
6343
|
+
peg$currPos,
|
|
6344
|
+
4
|
|
6345
|
+
) === peg$c16) {
|
|
6251
6346
|
s1 = peg$c16;
|
|
6252
6347
|
peg$currPos += 4;
|
|
6253
6348
|
} else {
|
|
6254
6349
|
s1 = peg$FAILED;
|
|
6255
6350
|
if (peg$silentFails === 0) {
|
|
6256
|
-
peg$fail(
|
|
6351
|
+
peg$fail(
|
|
6352
|
+
peg$e16
|
|
6353
|
+
);
|
|
6257
6354
|
}
|
|
6258
6355
|
}
|
|
6259
6356
|
}
|