@next-bricks/advanced 0.33.3 → 0.33.5

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.
Files changed (83) hide show
  1. package/dist/bricks.json +10 -10
  2. package/dist/chunks/1122.2c345ae6.js +2 -0
  3. package/dist/chunks/1122.2c345ae6.js.map +1 -0
  4. package/dist/chunks/1940.5c477924.js +2 -0
  5. package/dist/chunks/1940.5c477924.js.map +1 -0
  6. package/dist/chunks/{3171.fec4c148.js → 3171.afd7f489.js} +2 -2
  7. package/dist/chunks/{3171.fec4c148.js.map → 3171.afd7f489.js.map} +1 -1
  8. package/dist/chunks/{3933.a2ec75ea.js → 3933.64aa7bba.js} +2 -2
  9. package/dist/chunks/{3933.a2ec75ea.js.map → 3933.64aa7bba.js.map} +1 -1
  10. package/dist/chunks/4837.f6e3e461.js +2 -0
  11. package/dist/chunks/{7218.ef148faa.js.map → 4837.f6e3e461.js.map} +1 -1
  12. package/dist/chunks/{489.5ebb95a0.js → 489.59318cb6.js} +3 -3
  13. package/dist/chunks/{489.5ebb95a0.js.map → 489.59318cb6.js.map} +1 -1
  14. package/dist/chunks/4947.c1f458d5.js +3 -0
  15. package/dist/chunks/4947.c1f458d5.js.map +1 -0
  16. package/dist/chunks/5053.739ba196.js +2 -0
  17. package/dist/chunks/{5053.bc9a8e5b.js.map → 5053.739ba196.js.map} +1 -1
  18. package/dist/chunks/5399.8701798e.js +2 -0
  19. package/dist/chunks/5399.8701798e.js.map +1 -0
  20. package/dist/chunks/5479.03f51858.js +2 -0
  21. package/dist/chunks/{5479.344ebe72.js.map → 5479.03f51858.js.map} +1 -1
  22. package/dist/chunks/{5552.db1eb7a6.js → 5552.376ad301.js} +2 -2
  23. package/dist/chunks/{5552.db1eb7a6.js.map → 5552.376ad301.js.map} +1 -1
  24. package/dist/chunks/5683.c096a54a.js +2 -0
  25. package/dist/chunks/5683.c096a54a.js.map +1 -0
  26. package/dist/chunks/{6314.412f1f16.js → 6314.c1c149fd.js} +2 -2
  27. package/dist/chunks/{6314.412f1f16.js.map → 6314.c1c149fd.js.map} +1 -1
  28. package/dist/chunks/7218.b2afe775.js +2 -0
  29. package/dist/chunks/{4837.eae6f7c1.js.map → 7218.b2afe775.js.map} +1 -1
  30. package/dist/chunks/7434.8fc102a2.js +2 -0
  31. package/dist/chunks/{7434.e0962dca.js.map → 7434.8fc102a2.js.map} +1 -1
  32. package/dist/chunks/{790.3b264cd2.js → 790.4f1226b1.js} +2 -2
  33. package/dist/chunks/{790.3b264cd2.js.map → 790.4f1226b1.js.map} +1 -1
  34. package/dist/chunks/9260.c3e87ac0.js +2 -0
  35. package/dist/chunks/{9260.e70e8033.js.map → 9260.c3e87ac0.js.map} +1 -1
  36. package/dist/chunks/9559.9f33ce23.js +2 -0
  37. package/dist/chunks/9559.9f33ce23.js.map +1 -0
  38. package/dist/chunks/capture-snapshot.28c6e55d.js +2 -0
  39. package/dist/chunks/{capture-snapshot.7c399065.js.map → capture-snapshot.28c6e55d.js.map} +1 -1
  40. package/dist/chunks/{eo-cascader.f5ed2c9d.js → eo-cascader.0e175a05.js} +2 -2
  41. package/dist/chunks/{eo-cascader.f5ed2c9d.js.map → eo-cascader.0e175a05.js.map} +1 -1
  42. package/dist/chunks/eo-table.57b2411a.js +2 -0
  43. package/dist/chunks/{eo-table.1d52f43f.js.map → eo-table.57b2411a.js.map} +1 -1
  44. package/dist/chunks/{eo-tree-select.9d227853.js → eo-tree-select.fd0f59ab.js} +2 -2
  45. package/dist/chunks/{eo-tree-select.9d227853.js.map → eo-tree-select.fd0f59ab.js.map} +1 -1
  46. package/dist/chunks/{eo-tree.bb267ad3.js → eo-tree.105d8ebb.js} +3 -3
  47. package/dist/chunks/{eo-tree.bb267ad3.js.map → eo-tree.105d8ebb.js.map} +1 -1
  48. package/dist/chunks/{eo-workbench-layout.c476f8b7.js → eo-workbench-layout.ff7065f2.js} +2 -2
  49. package/dist/chunks/{eo-workbench-layout.c476f8b7.js.map → eo-workbench-layout.ff7065f2.js.map} +1 -1
  50. package/dist/chunks/main.8585ced2.js +2 -0
  51. package/dist/chunks/{main.58be882b.js.map → main.8585ced2.js.map} +1 -1
  52. package/dist/examples.json +6 -6
  53. package/dist/index.7e5c42fc.js +2 -0
  54. package/dist/index.7e5c42fc.js.map +1 -0
  55. package/dist/manifest.json +222 -222
  56. package/dist/types.json +156 -156
  57. package/package.json +2 -2
  58. package/dist/chunks/1122.2f11298f.js +0 -2
  59. package/dist/chunks/1122.2f11298f.js.map +0 -1
  60. package/dist/chunks/1940.cf7f5dd0.js +0 -2
  61. package/dist/chunks/1940.cf7f5dd0.js.map +0 -1
  62. package/dist/chunks/4837.eae6f7c1.js +0 -2
  63. package/dist/chunks/5053.bc9a8e5b.js +0 -2
  64. package/dist/chunks/5399.5bec9039.js +0 -2
  65. package/dist/chunks/5399.5bec9039.js.map +0 -1
  66. package/dist/chunks/5479.344ebe72.js +0 -2
  67. package/dist/chunks/5683.7b312ccc.js +0 -2
  68. package/dist/chunks/5683.7b312ccc.js.map +0 -1
  69. package/dist/chunks/7218.ef148faa.js +0 -2
  70. package/dist/chunks/7434.e0962dca.js +0 -2
  71. package/dist/chunks/9260.e70e8033.js +0 -2
  72. package/dist/chunks/9559.9d919d1a.js +0 -2
  73. package/dist/chunks/9559.9d919d1a.js.map +0 -1
  74. package/dist/chunks/9612.99e6f1a8.js +0 -3
  75. package/dist/chunks/9612.99e6f1a8.js.map +0 -1
  76. package/dist/chunks/capture-snapshot.7c399065.js +0 -2
  77. package/dist/chunks/eo-table.1d52f43f.js +0 -2
  78. package/dist/chunks/main.58be882b.js +0 -2
  79. package/dist/index.83dd4a85.js +0 -2
  80. package/dist/index.83dd4a85.js.map +0 -1
  81. /package/dist/chunks/{489.5ebb95a0.js.LICENSE.txt → 489.59318cb6.js.LICENSE.txt} +0 -0
  82. /package/dist/chunks/{9612.99e6f1a8.js.LICENSE.txt → 4947.c1f458d5.js.LICENSE.txt} +0 -0
  83. /package/dist/chunks/{eo-tree.bb267ad3.js.LICENSE.txt → eo-tree.105d8ebb.js.LICENSE.txt} +0 -0
package/dist/types.json CHANGED
@@ -275,162 +275,6 @@
275
275
  ],
276
276
  "methods": []
277
277
  },
278
- "eo-workbench-layout": {
279
- "properties": [
280
- {
281
- "name": "cardTitle",
282
- "annotation": {
283
- "type": "keyword",
284
- "value": "string"
285
- }
286
- },
287
- {
288
- "name": "isEdit",
289
- "annotation": {
290
- "type": "keyword",
291
- "value": "boolean"
292
- }
293
- },
294
- {
295
- "name": "layouts",
296
- "annotation": {
297
- "type": "array",
298
- "elementType": {
299
- "type": "reference",
300
- "typeName": {
301
- "type": "identifier",
302
- "name": "Layout"
303
- }
304
- }
305
- }
306
- },
307
- {
308
- "name": "componentList",
309
- "annotation": {
310
- "type": "array",
311
- "elementType": {
312
- "type": "reference",
313
- "typeName": {
314
- "type": "identifier",
315
- "name": "Item"
316
- }
317
- }
318
- }
319
- }
320
- ],
321
- "events": [
322
- {
323
- "name": "save",
324
- "detail": {
325
- "annotation": {
326
- "type": "array",
327
- "elementType": {
328
- "type": "reference",
329
- "typeName": {
330
- "type": "identifier",
331
- "name": "Layout"
332
- }
333
- }
334
- }
335
- }
336
- },
337
- {
338
- "name": "cancel",
339
- "detail": {
340
- "annotation": {
341
- "type": "keyword",
342
- "value": "void"
343
- }
344
- }
345
- }
346
- ],
347
- "methods": [],
348
- "types": [
349
- {
350
- "type": "interface",
351
- "name": "Item",
352
- "body": [
353
- {
354
- "type": "propertySignature",
355
- "key": {
356
- "type": "identifier",
357
- "name": "position"
358
- },
359
- "annotation": {
360
- "type": "reference",
361
- "typeName": {
362
- "type": "identifier",
363
- "name": "Layout"
364
- }
365
- },
366
- "computed": false
367
- },
368
- {
369
- "type": "propertySignature",
370
- "key": {
371
- "type": "identifier",
372
- "name": "key"
373
- },
374
- "annotation": {
375
- "type": "keyword",
376
- "value": "string"
377
- },
378
- "computed": false
379
- },
380
- {
381
- "type": "propertySignature",
382
- "key": {
383
- "type": "identifier",
384
- "name": "title"
385
- },
386
- "annotation": {
387
- "type": "keyword",
388
- "value": "string"
389
- },
390
- "computed": false
391
- },
392
- {
393
- "type": "propertySignature",
394
- "key": {
395
- "type": "identifier",
396
- "name": "style"
397
- },
398
- "annotation": {
399
- "type": "reference",
400
- "typeName": {
401
- "type": "qualifiedName",
402
- "left": {
403
- "type": "identifier",
404
- "name": "React"
405
- },
406
- "right": {
407
- "type": "identifier",
408
- "name": "CSSProperties"
409
- }
410
- }
411
- },
412
- "optional": true,
413
- "computed": false
414
- },
415
- {
416
- "type": "propertySignature",
417
- "key": {
418
- "type": "identifier",
419
- "name": "useBrick"
420
- },
421
- "annotation": {
422
- "type": "reference",
423
- "typeName": {
424
- "type": "identifier",
425
- "name": "UseSingleBrickConf"
426
- }
427
- },
428
- "computed": false
429
- }
430
- ]
431
- }
432
- ]
433
- },
434
278
  "eo-tree": {
435
279
  "properties": [
436
280
  {
@@ -1218,6 +1062,162 @@
1218
1062
  ],
1219
1063
  "methods": []
1220
1064
  },
1065
+ "eo-workbench-layout": {
1066
+ "properties": [
1067
+ {
1068
+ "name": "cardTitle",
1069
+ "annotation": {
1070
+ "type": "keyword",
1071
+ "value": "string"
1072
+ }
1073
+ },
1074
+ {
1075
+ "name": "isEdit",
1076
+ "annotation": {
1077
+ "type": "keyword",
1078
+ "value": "boolean"
1079
+ }
1080
+ },
1081
+ {
1082
+ "name": "layouts",
1083
+ "annotation": {
1084
+ "type": "array",
1085
+ "elementType": {
1086
+ "type": "reference",
1087
+ "typeName": {
1088
+ "type": "identifier",
1089
+ "name": "Layout"
1090
+ }
1091
+ }
1092
+ }
1093
+ },
1094
+ {
1095
+ "name": "componentList",
1096
+ "annotation": {
1097
+ "type": "array",
1098
+ "elementType": {
1099
+ "type": "reference",
1100
+ "typeName": {
1101
+ "type": "identifier",
1102
+ "name": "Item"
1103
+ }
1104
+ }
1105
+ }
1106
+ }
1107
+ ],
1108
+ "events": [
1109
+ {
1110
+ "name": "save",
1111
+ "detail": {
1112
+ "annotation": {
1113
+ "type": "array",
1114
+ "elementType": {
1115
+ "type": "reference",
1116
+ "typeName": {
1117
+ "type": "identifier",
1118
+ "name": "Layout"
1119
+ }
1120
+ }
1121
+ }
1122
+ }
1123
+ },
1124
+ {
1125
+ "name": "cancel",
1126
+ "detail": {
1127
+ "annotation": {
1128
+ "type": "keyword",
1129
+ "value": "void"
1130
+ }
1131
+ }
1132
+ }
1133
+ ],
1134
+ "methods": [],
1135
+ "types": [
1136
+ {
1137
+ "type": "interface",
1138
+ "name": "Item",
1139
+ "body": [
1140
+ {
1141
+ "type": "propertySignature",
1142
+ "key": {
1143
+ "type": "identifier",
1144
+ "name": "position"
1145
+ },
1146
+ "annotation": {
1147
+ "type": "reference",
1148
+ "typeName": {
1149
+ "type": "identifier",
1150
+ "name": "Layout"
1151
+ }
1152
+ },
1153
+ "computed": false
1154
+ },
1155
+ {
1156
+ "type": "propertySignature",
1157
+ "key": {
1158
+ "type": "identifier",
1159
+ "name": "key"
1160
+ },
1161
+ "annotation": {
1162
+ "type": "keyword",
1163
+ "value": "string"
1164
+ },
1165
+ "computed": false
1166
+ },
1167
+ {
1168
+ "type": "propertySignature",
1169
+ "key": {
1170
+ "type": "identifier",
1171
+ "name": "title"
1172
+ },
1173
+ "annotation": {
1174
+ "type": "keyword",
1175
+ "value": "string"
1176
+ },
1177
+ "computed": false
1178
+ },
1179
+ {
1180
+ "type": "propertySignature",
1181
+ "key": {
1182
+ "type": "identifier",
1183
+ "name": "style"
1184
+ },
1185
+ "annotation": {
1186
+ "type": "reference",
1187
+ "typeName": {
1188
+ "type": "qualifiedName",
1189
+ "left": {
1190
+ "type": "identifier",
1191
+ "name": "React"
1192
+ },
1193
+ "right": {
1194
+ "type": "identifier",
1195
+ "name": "CSSProperties"
1196
+ }
1197
+ }
1198
+ },
1199
+ "optional": true,
1200
+ "computed": false
1201
+ },
1202
+ {
1203
+ "type": "propertySignature",
1204
+ "key": {
1205
+ "type": "identifier",
1206
+ "name": "useBrick"
1207
+ },
1208
+ "annotation": {
1209
+ "type": "reference",
1210
+ "typeName": {
1211
+ "type": "identifier",
1212
+ "name": "UseSingleBrickConf"
1213
+ }
1214
+ },
1215
+ "computed": false
1216
+ }
1217
+ ]
1218
+ }
1219
+ ]
1220
+ },
1221
1221
  "advanced.capture-snapshot": {
1222
1222
  "type": "provider",
1223
1223
  "params": [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@next-bricks/advanced",
3
- "version": "0.33.3",
3
+ "version": "0.33.5",
4
4
  "homepage": "https://github.com/easyops-cn/next-bricks/tree/master/bricks/advanced",
5
5
  "repository": {
6
6
  "type": "git",
@@ -44,5 +44,5 @@
44
44
  "@next-bricks/icons": "*",
45
45
  "@next-bricks/markdown": "*"
46
46
  },
47
- "gitHead": "51797daa2bd879c8710f45956a4d01c8bade7177"
47
+ "gitHead": "8dd16729d3c01eac8553d16d913ff2efd55d4f8f"
48
48
  }
@@ -1,2 +0,0 @@
1
- "use strict";(globalThis.webpackChunk_next_bricks_advanced=globalThis.webpackChunk_next_bricks_advanced||[]).push([[1122],{24586:(e,n,t)=>{t.d(n,{A:()=>i});var r=t(11369);function i(e,n,t){return(n=(0,r.A)(n))in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}},11369:(e,n,t)=>{t.d(n,{A:()=>i});var r=t(17545);function i(e){var n=function(e,n){if("object"!=(0,r.A)(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var i=t.call(e,"string");if("object"!=(0,r.A)(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==(0,r.A)(n)?n:n+""}},17545:(e,n,t)=>{function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}t.d(n,{A:()=>r})},61122:(e,n,t)=>{t.r(n),t.d(n,{cook:()=>R,isEvaluable:()=>_,isTrackAll:()=>G,precook:()=>z,precookFunction:()=>q,preevaluate:()=>U,shouldAllowRecursiveEvaluations:()=>W});var r=t(24586);class i{constructor(){(0,r.A)(this,"VariableEnvironment",void 0),(0,r.A)(this,"LexicalEnvironment",void 0),(0,r.A)(this,"Function",void 0)}}class o{constructor(e){(0,r.A)(this,"OuterEnv",void 0),(0,r.A)(this,"bindingMap",new Map),this.OuterEnv=e}HasBinding(e){return this.bindingMap.has(e)}CreateMutableBinding(e,n){return this.bindingMap.set(e,{mutable:!0,deletable:n}),v(void 0)}CreateImmutableBinding(e,n){return this.bindingMap.set(e,{strict:n}),v(void 0)}InitializeBinding(e,n){const t=this.bindingMap.get(e);return Object.assign(t,{initialized:!0,value:n}),v(void 0)}SetMutableBinding(e,n,t){const r=this.bindingMap.get(e);if(!r.initialized)throw new ReferenceError(`${e} is not initialized`);if(!r.mutable)throw new TypeError("Assignment to constant variable");return r.value=n,v(void 0)}GetBindingValue(e,n){const t=this.bindingMap.get(e);if(!t.initialized)throw new ReferenceError(`${e} is not initialized`);return t.value}}class a extends o{}class s extends o{}const c=Symbol.for("SourceNode"),u=Symbol.for("FormalParameters"),l=Symbol.for("ECMAScriptCode"),f=Symbol.for("Environment"),d=Symbol.for("IsConstructor");class p{constructor(e,n,t){(0,r.A)(this,"Base",void 0),(0,r.A)(this,"ReferenceName",void 0),(0,r.A)(this,"Strict",void 0),this.Base=e,this.ReferenceName=n,this.Strict=t}}class m{constructor(e,n){(0,r.A)(this,"Type",void 0),(0,r.A)(this,"Value",void 0),this.Type=e,this.Value=n}}function v(e){return new m("normal",e)}const y=Symbol("empty completion");function b(e){const n=new Set,t=e=>{if(Array.isArray(e))for(const n of e)t(n);else if(e)switch(e.type){case"Identifier":return void n.add(e.name);case"VariableDeclaration":return t(e.declarations);case"VariableDeclarator":case"FunctionDeclaration":return t(e.id);case"ArrayPattern":return t(e.elements);case"AssignmentPattern":return t(e.left);case"ObjectPattern":return t(e.properties);case"Property":return t(e.value);case"RestElement":return t(e.argument)}};return t(e),Array.from(n)}function g(e){const n=e=>{if(Array.isArray(e))return e.some(n);if(e)switch(e.type){case"ArrayPattern":return n(e.elements);case"AssignmentPattern":return!0;case"ObjectPattern":return n(e.properties);case"Property":return e.computed||n(e.value);case"RestElement":return n(e.argument)}};return n(e)}function h(e,n){const t=[],r={var:n.var},i=(e,n)=>{if(Array.isArray(e))for(const t of e)i(t,n);else if(e){switch(e.type){case"FunctionDeclaration":return void(Number(!n.var)^Number(n.topLevel)&&t.push(e));case"VariableDeclaration":return void(Number(!n.var)^Number("var"===e.kind)&&t.push(e));case"SwitchCase":return void i(e.consequent,r);case"CatchClause":return void i(e.body,r)}if(n.var)switch(e.type){case"BlockStatement":case"DoWhileStatement":case"WhileStatement":return void i(e.body,r);case"IfStatement":return i(e.consequent,r),void i(e.alternate,r);case"ForStatement":return i(e.init,r),void i(e.body,r);case"ForInStatement":case"ForOfStatement":return i(e.left,r),void i(e.body,r);case"SwitchStatement":return void i(e.cases,r);case"TryStatement":return i(e.block,r),i(e.handler,r),void i(e.finalizer,r)}}};return i(e,n),t}function E(e){return"unresolvable"!==e.Base&&!(e.Base instanceof o)}function w(e,n){return e.Base.InitializeBinding(e.ReferenceName,n)}function x(e,n,t){if(null==n)return e;const r=Object.getOwnPropertyNames(n).concat(Object.getOwnPropertySymbols(n));for(const i of r)if(!t.has(i)){const t=Object.getOwnPropertyDescriptor(n,i);null!=t&&t.enumerable&&(e[i]=n[i])}return e}function S(e,n){const t="const"===e.kind;for(const r of b(e))t?n.CreateImmutableBinding(r,!0):n.CreateMutableBinding(r,!1)}function B(e){return"normal"===e.Type||"continue"==e.Type}function A(e,n){return e.Value!==y?e:new m(e.Type,n)}function k(e){if(e instanceof m&&(e=e.Value),!(e instanceof p))return e;if("unresolvable"===e.Base)throw new ReferenceError(`${e.ReferenceName} is not defined`);return e.Base instanceof o?e.Base.GetBindingValue(e.ReferenceName,e.Strict):e.Base[e.ReferenceName]}function L(e){return"symbol"==typeof e?e:String(e)}function V(e,n){return e[n]}function C(e,n){if("unresolvable"===e.Base)throw new ReferenceError(`${e.ReferenceName} is not defined`);return e.Base instanceof o?e.Base.SetMutableBinding(e.ReferenceName,n,e.Strict):(e.Base[e.ReferenceName]=n,v(void 0))}function P(e){if(n=e,!(Array.isArray(n)||null!=n&&"function"==typeof n[Symbol.iterator]))throw new TypeError(typeof e+" is not iterable");var n;return e[Symbol.iterator]()}function T(e){if(null==e)throw new TypeError("Cannot destructure properties of undefined or null")}function I(e,n,t){return e?e.HasBinding(n)?new p(e,n,t):I(e.OuterEnv,n,t):new p("unresolvable",n,t)}function O(e,n,t){switch(n){case"+":return e+t;case"-":return e-t;case"/":return e/t;case"%":return e%t;case"*":return e*t;case"**":return e**t;case"==":return e==t;case"===":return e===t;case"!=":return e!=t;case"!==":return e!==t;case">":return e>t;case"<":return e<t;case">=":return e>=t;case"<=":return e<=t}throw new SyntaxError(`Unsupported binary operator \`${n}\``)}const F=new WeakSet([Function,Object,Function.prototype,Object.prototype,function(){if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;if("undefined"!=typeof global)return global;throw new Error("unable to locate global object")}()]);function j(e){if(F.has(e))throw new TypeError("Cannot access reserved objects such as `Function`.")}const M=new WeakSet([Array,Map,Set,URLSearchParams,WeakMap,WeakSet,RegExp]);function R(e,n){var t;let{rules:r,globalVariables:o={},hooks:F={}}=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const R="FunctionDeclaration"!==e.type,D=new a(null),$=new i;$.VariableEnvironment=D,$.LexicalEnvironment=D;const z=[$];for(const[e,n]of Object.entries(o))D.CreateImmutableBinding(e,!0),D.InitializeBinding(e,n);const N=new WeakMap;function q(e,t){var r,i,o;switch(null===(r=F.beforeEvaluate)||void 0===r||r.call(F,e),e.type){case"ArrayExpression":{const n=[];for(const t of e.elements)if(t)if("SpreadElement"===t.type){const e=k(q(t.argument));n.push(...e)}else n.push(k(q(t)));else n.length+=1;return v(n)}case"ArrowFunctionExpression":return ue(e),v(re(e,U().LexicalEnvironment,!1));case"BinaryExpression":{const t=k(q(e.left)),r=q(e.right).Value,i=k(r);if(R&&"|>"===e.operator){if("function"!=typeof i){const t=n.substring(e.right.start,e.right.end);throw new TypeError(`${t} is not a function`)}let o;return r instanceof p&&E(r)&&(o=r.Base),v(i.call(o,t))}return v(O(t,e.operator,i))}case"CallExpression":{const n=q(e.callee,t).Value,r=k(n);return null==r&&(e.optional||null!=t&&t.skipped)?(t.skipped=!0,v(void 0)):(j(r),Z(r,n,e.arguments,e.callee))}case"ChainExpression":return q(e.expression,{});case"ConditionalExpression":return v(k(q(k(q(e.test))?e.consequent:e.alternate)));case"Identifier":return v(_(e.name));case"Literal":if(e.regex){if(null===e.value)throw new SyntaxError(`Invalid regular expression: ${e.raw}`);if(e.regex.flags.includes("u"))throw new SyntaxError(`Unsupported unicode flag in regular expression: ${e.raw}`)}return v(e.value);case"LogicalExpression":{const n=k(q(e.left));switch(e.operator){case"&&":return v(n&&k(q(e.right)));case"||":return v(n||k(q(e.right)));case"??":return v(n??k(q(e.right)));default:throw new SyntaxError(`Unsupported logical operator '${e.operator}'`)}}case"MemberExpression":{const n=k(q(e.object,t).Value);if(null==n&&(e.optional||null!=t&&t.skipped))return t.skipped=!0,v(void 0);j(n);const r=e.computed?function(e,n,t){const r=L(k(q(n)));return new p(e,r,!0)}(n,e.property):function(e,n,t){const r=n.name;return new p(e,r,!0)}(n,e.property);return j(r),v(r)}case"NewExpression":return function(e,t){const r=k(q(e)),i=ee(t);if("function"!=typeof r||!1===r[d]){const t=n.substring(e.start,e.end);throw new TypeError(`${t} is not a constructor`)}if(!function(e){return M.has(e)||e===Date}(r)){const t=n.substring(e.start,e.end);throw new TypeError(`${t} is not an allowed constructor`)}return v(new r(...i))}(e.callee,e.arguments);case"ObjectExpression":{const n={};for(const t of e.properties)if("SpreadElement"===t.type)x(n,k(q(t.argument)),new Set);else{if("init"!==t.kind)throw new SyntaxError("Unsupported object getter/setter");const e=t.computed||"Identifier"!==t.key.type?oe(t.key):t.key.name;if("__proto__"===e)throw new TypeError("Setting '__proto__' property is not allowed");n[e]=k(q(t.value))}return v(n)}case"SequenceExpression":{let n;for(const t of e.expressions)n=v(k(q(t)));return n}case"TemplateLiteral":{const n=[e.quasis[0].value.cooked];let t=0;for(const r of e.expressions){const i=k(q(r));n.push(String(i)),n.push(e.quasis[t+=1].value.cooked)}return v(n.join(""))}case"TaggedTemplateExpression":{const n=q(e.tag).Value,t=k(n);return j(t),Z(t,n,e.quasi,e.tag)}case"UnaryExpression":{const n=q(e.argument).Value;if(!R&&"delete"===e.operator){if(!(n instanceof p))return v(!0);if(E(n))return v(delete n.Base[n.ReferenceName])}return"typeof"===e.operator?n instanceof p&&"unresolvable"===n.Base?v("undefined"):v(typeof k(n)):v(function(e,n){switch(n){case"!":return!e;case"+":return+e;case"-":return-e;case"void":return}throw new SyntaxError(`Unsupported unary operator \`${n}\``)}(k(n),e.operator))}}if(!R)switch(e.type){case"AssignmentExpression":{if("="===e.operator){if("ArrayPattern"!==e.left.type&&"ObjectPattern"!==e.left.type){const n=q(e.left).Value,t=k(q(e.right));return C(n,t),v(t)}const n=k(q(e.right));return K(e.left,n),v(n)}const n=q(e.left).Value,t=k(n),r=k(q(e.right)),i=function(e,n,t){switch(n){case"+=":case"-=":case"*=":case"/=":case"%=":case"**=":return O(e,n.substr(0,n.length-1),t)}throw new SyntaxError(`Unsupported assignment operator \`${n}\``)}(t,e.operator,r);return C(n,i),v(i)}case"BlockStatement":{if(!e.body.length)return v(y);const n=U().LexicalEnvironment,t=new a(n);Y(e.body,t),U().LexicalEnvironment=t;const r=ne(e.body);return U().LexicalEnvironment=n,r}case"BreakStatement":return new m("break",y);case"ContinueStatement":return new m("continue",y);case"EmptyStatement":case"FunctionDeclaration":return v(y);case"DoWhileStatement":return W(function(e){let n;for(;;){const t=q(e.body);if(!B(t))return A(t,n);if(t.Value!==y&&(n=t.Value),!k(q(e.test)))return v(n)}}(e));case"ExpressionStatement":case"TSAsExpression":return q(e.expression);case"ForInStatement":case"ForOfStatement":return W(function(e){const n=e.left,t="VariableDeclaration"===n.type?"var"===n.kind?"varBinding":"lexicalBinding":"assignment",r="lexicalBinding"===t?b(n):[],i="ForInStatement"===e.type?"enumerate":"iterate",o=function(e,n,t){const r=U(),i=r.LexicalEnvironment;if(e.length>0){const n=new a(i);for(const t of e)n.CreateMutableBinding(t,!1);r.LexicalEnvironment=n}const o=q(n);r.LexicalEnvironment=i;const s=k(o);return"enumerate"===t?null==s?new m("break",y):v(function*(e){for(const n in e)yield n}(s)):v(P(s))}(r,e.right,i);return"normal"!==o.Type?o:function(e,n,t,r,i){const o="assignment"===i?e:e.declarations[0].id,s=U().LexicalEnvironment;let c;const u="ObjectPattern"===o.type||"ArrayPattern"===o.type;for(;;){const{done:l,value:f}=t.next();if(l)return v(c);let d,p;if("lexicalBinding"===i){if(p=new a(s),S(e,p),U().LexicalEnvironment=p,!u){const[e]=b(o);d=_(e)}}else u||(d=q(o).Value);u?"assignment"===i?K(o,f):ie(o,f,"varBinding"===i?void 0:p):"lexicalBinding"===i?w(d,f):C(d,f);const m=q(n);if(U().LexicalEnvironment=s,!B(m)){const e=A(m,c);if("enumerate"!==r&&void 0!==t.return){const e=t.return();if(!e||!["object","function"].includes(typeof e))throw new TypeError("Iterator result is not an object")}return e}m.Value!==y&&(c=m.Value)}}(n,e.body,o.Value,i,t)}(e));case"ForStatement":return W(function(e){var n;if("VariableDeclaration"===(null===(n=e.init)||void 0===n?void 0:n.type)){if("var"===e.init.kind)return q(e.init),H(e.test,e.update,e.body,[]);const n=U().LexicalEnvironment,t=new a(n),r="const"===e.init.kind,i=b(e.init);for(const e of i)r?t.CreateImmutableBinding(e,!0):t.CreateMutableBinding(e,!1);U().LexicalEnvironment=t,q(e.init);const o=r?[]:Array.from(i),s=H(e.test,e.update,e.body,o);return U().LexicalEnvironment=n,s}return e.init&&k(q(e.init)),H(e.test,e.update,e.body,[])}(e));case"FunctionExpression":return ue(e),v(function(e){const n=U().LexicalEnvironment;if(e.id){const t=e.id.name,r=new a(n);r.CreateImmutableBinding(t,!1);const i=re(e,r,!0);return r.InitializeBinding(t,i),i}return re(e,n,!0)}(e));case"IfStatement":return k(q(e.test))?(null!==(i=F.beforeBranch)&&void 0!==i&&i.call(F,e,"if"),A(q(e.consequent),void 0)):(null!==(o=F.beforeBranch)&&void 0!==o&&o.call(F,e,"else"),e.alternate?A(q(e.alternate),void 0):v(void 0));case"ReturnStatement":{let n;return e.argument&&(n=k(q(e.argument))),new m("return",n)}case"ThrowStatement":throw k(q(e.argument));case"UpdateExpression":{const n=q(e.argument).Value,t=Number(k(n)),r="++"===e.operator?t+1:t-1;return C(n,r),v(e.prefix?r:t)}case"SwitchCase":return ne(e.consequent);case"SwitchStatement":{const n=k(q(e.discriminant)),t=U().LexicalEnvironment,r=new a(t);Y(e.cases,r),U().LexicalEnvironment=r;const i=function(e,n){let t;const r=e.findIndex((e=>!e.test)),i=r>=0,o=i?e.slice(0,r):e;let a=!1;for(const e of o)if(a||(a=G(e,n)),a){const n=q(e);if(n.Value!==y&&(t=n.Value),"normal"!==n.Type)return A(n,t)}if(!i)return v(t);let s=!1;const c=e.slice(r+1);if(!a)for(const e of c)if(s||(s=G(e,n)),s){const n=q(e);if(n.Value!==y&&(t=n.Value),"normal"!==n.Type)return A(n,t)}if(s)return v(t);const u=q(e[r]);if(u.Value!==y&&(t=u.Value),"normal"!==u.Type)return A(u,t);for(const e of c){const n=q(e);if(n.Value!==y&&(t=n.Value),"normal"!==n.Type)return A(n,t)}return v(t)}(e.cases,n);return U().LexicalEnvironment=t,W(i)}case"TryStatement":{let n;try{n=q(e.block)}catch(t){if(!e.handler)throw t;var s;null===(s=F.beforeEvaluate)||void 0===s||s.call(F,e.handler),n=function(e,n){if(!e.param)return q(e.body);const t=U().LexicalEnvironment,r=new a(t);for(const n of b(e.param))r.CreateMutableBinding(n,!1);U().LexicalEnvironment=r,ie(e.param,n,r);const i=q(e.body);return U().LexicalEnvironment=t,i}(e.handler,t)}finally{if(e.finalizer){const t=q(e.finalizer);"normal"!==t.Type&&(n=t)}}return n}case"VariableDeclaration":{let n;for(const t of e.declarations)if(t.init)if("Identifier"===t.id.type){const r=_(t.id.name),i=k(q(t.init));n="var"===e.kind?C(r,i):w(r,i)}else{const r=k(q(t.init));n=ie(t.id,r,"var"===e.kind?void 0:U().LexicalEnvironment)}else n="var"===e.kind?v(y):w(_(t.id.name),void 0);return n}case"WhileStatement":return W(function(e){let n;for(;;){if(!k(q(e.test)))return v(n);const t=q(e.body);if(!B(t))return A(t,n);t.Value!==y&&(n=t.Value)}}(e))}throw new SyntaxError(`Unsupported node type \`${e.type}\``)}function U(){return z[z.length-1]}function _(e,n){return n||(n=U().LexicalEnvironment),I(n,e,!0)}function W(e){return"break"===e.Type?e.Value===y?v(void 0):v(e.Value):e}function G(e,n){return n===k(q(e.test))}function H(e,n,t,r){let i;for(J(r);;){if(e&&!k(q(e)))return v(i);const o=q(t);if(!B(o))return A(o,i);o.Value&&(i=o.Value),J(r),n&&k(q(n))}}function J(e){if(0===e.length)return;const n=U().LexicalEnvironment,t=n.OuterEnv,r=new a(t);for(const t of e){r.CreateMutableBinding(t,!1);const e=n.GetBindingValue(t,!1);r.InitializeBinding(t,e)}U().LexicalEnvironment=r}function K(e,n){if("ObjectPattern"===e.type)return T(n),e.properties.length>0&&function(e,n){const t=new Set;for(const r of e)if("Property"===r.type){const e=r.computed||"Identifier"!==r.key.type?oe(r.key):r.key.name,i="AssignmentPattern"===r.value.type?r.value.left:r.value;if("Identifier"===i.type){const o=_(i.name);let a=V(n,e);"AssignmentPattern"===r.value.type&&void 0===a&&(a=k(q(r.value.right))),C(o,a),t.add(e)}else Q(r.value,n,e),t.add(e)}else X(r,n,t)}(e.properties,n),v(y);const t=P(n);return function(e,n){let t=v(y);for(const r of e){if(!r){n.next(),t=v(y);continue}const e="RestElement"===r.type?r.argument:"AssignmentPattern"===r.type?r.left:r,i="ArrayPattern"===e.type||"ObjectPattern"===e.type;let o,a;if(i||(o=q(e).Value),"RestElement"!==r.type){const{done:e,value:t}=n.next(),i=e?void 0:t;a="AssignmentPattern"===r.type&&void 0===i?k(q(r.right)):i}else{a=[];let e=0;for(;;){const{done:t,value:r}=n.next();if(t)break;a[e]=r,e++}}t=i?K(e,a):C(o,a)}return t}(e.elements,t)}function Q(e,n,t){const r="AssignmentPattern"===e.type?e.left:e,i="ArrayPattern"===r.type||"ObjectPattern"===r.type;let o;i||(o=q(r).Value);const a=V(n,t);let s;return s="AssignmentPattern"===e.type&&void 0===a?k(q(e.right)):a,i?K(r,s):C(o,s)}function X(e,n,t){return C(q(e.argument).Value,x({},n,t))}function Y(e,n){const t=h(e,{var:!1,topLevel:!1});for(const e of t){const t="VariableDeclaration"===e.type&&"const"===e.kind;for(const r of b(e))t?n.CreateImmutableBinding(r,!0):n.CreateMutableBinding(r,!1);if("FunctionDeclaration"===e.type){const[t]=b(e),r=te(e,n);n.InitializeBinding(t,r)}}}function Z(e,t,r,i){let o;t instanceof p&&E(t)&&(o=t.Base);const a=ee(r);if("function"!=typeof e){const e=n.substring(i.start,i.end);throw new TypeError(`${e} is not a function`)}const s=e.apply(o,a);return j(s),v(s)}function ee(e){const n=[];if(Array.isArray(e))for(const t of e)if("SpreadElement"===t.type){const e=k(q(t.argument));n.push(...e)}else n.push(k(q(t)));else{n.push(function(e){const n=N.get(e);if(n)return n;const t=e.quasis.map((e=>e.value.raw)),r=e.quasis.map((e=>e.value.cooked));return Object.freeze(t),Object.defineProperty(r,"raw",{value:t,writable:!1,enumerable:!1,configurable:!1}),Object.freeze(r),N.set(e,r),r}(e));for(const t of e.expressions)n.push(k(q(t)))}return n}function ne(e){let n=v(y);for(const t of e){const e=q(t);if("normal"!==e.Type)return e;n=A(n,e.Value)}return n}function te(e,n){return re(e,n,!0)}function re(e,n,t){const o=function(){return function(e,n){var t;null===(t=F.beforeCall)||void 0===t||t.call(F,e[c]),function(e){const n=new i;n.Function=e;const t=new s(e[f]);n.VariableEnvironment=t,n.LexicalEnvironment=t,z.push(n)}(e);const o=function(e,n){return function(e,n,t){return function(e,n){const t=U(),i=e[l],o=e[u],s=b(o),c=g(o),f=h(i,{var:!0,topLevel:!0}),d=b(f),p=[],m=[];for(let e=f.length-1;e>=0;e--){const n=f[e];if("FunctionDeclaration"===n.type){ue(n);const[e]=b(n);p.includes(e)||(p.unshift(e),m.unshift(n))}else if(null!=r&&r.noVar)throw new SyntaxError("Var declaration is not recommended, use `let` or `const` instead")}const v=t.LexicalEnvironment;for(const e of s)v.CreateMutableBinding(e,!1);let y;if(se(o,P(n),v),c){y=new a(v),t.VariableEnvironment=y;for(const e of d){let n;y.CreateMutableBinding(e,!1),s.includes(e)&&!p.includes(e)&&(n=v.GetBindingValue(e,!1)),y.InitializeBinding(e,n)}}else{for(const e of d)s.includes(e)||(v.CreateMutableBinding(e,!1),v.InitializeBinding(e,void 0));y=v}const E=y;t.LexicalEnvironment=E;const w=h(i,{var:!1,topLevel:!0});for(const e of w)for(const n of b(e))"const"===e.kind?E.CreateImmutableBinding(n,!0):E.CreateMutableBinding(n,!1);for(const e of m){const[n]=b(e),t=te(e,E);y.SetMutableBinding(n,t,!1)}}(n,t),Array.isArray(e)?ne(e):new m("return",k(q(e)))}(e[l],e,n)}(e,n);if(z.pop(),"return"===o.Type)return o.Value}(o,arguments)};return Object.defineProperties(o,{[c]:{value:e},[u]:{value:e.params},[l]:{value:"BlockStatement"===e.body.type?e.body.body:e.body},[f]:{value:n},[d]:{value:t}}),o}function ie(e,n,t){switch(e.type){case"Identifier":return function(e,n,t){return t.InitializeBinding(e,n),v(y)}(e.name,n,t);case"ObjectPattern":return T(n),function(e,n,t){const r=new Set;for(const i of e){if("RestElement"===i.type)return ae(i,n,t,r);if(i.computed||"Identifier"!==i.key.type){const e=oe(i.key);ce(i.value,n,t,e),r.add(e)}else ce(i.value,n,t,i.key.name),r.add(i.key.name)}return v(y)}(e.properties,n,t);case"ArrayPattern":{const r=P(n);return se(e.elements,r,t)}}}function oe(e){return L(k(q(e)))}function ae(e,n,t,r){const i=_(e.argument.name,t),o=x({},n,r);return t?w(i,o):C(i,o)}function se(e,n,t){if(0===e.length)return v(y);let r;for(const i of e)if(i)if("RestElement"===i.type)if("Identifier"===i.argument.type){const e=_(i.argument.name,t),o=[];let a=0;for(;;){const{done:i,value:s}=n.next();if(i){r=t?w(e,o):C(e,o);break}o[a]=s,a++}}else{const e=[];let o=0;for(;;){const{done:a,value:s}=n.next();if(a){r=ie(i.argument,e,t);break}e[o]=s,o++}}else{const e="AssignmentPattern"===i.type?i.left:i;switch(e.type){case"ObjectPattern":case"ArrayPattern":{let o;const{done:a,value:s}=n.next();a||(o=s),"AssignmentPattern"===i.type&&void 0===o&&(o=k(q(i.right))),r=ie(e,o,t);break}case"Identifier":{const o=_(e.name,t);let a;const{done:s,value:c}=n.next();s||(a=c),"AssignmentPattern"===i.type&&void 0===a&&(a=k(q(i.right))),r=t?w(o,a):C(o,a);break}}}else n.next(),r=v(y);return r}function ce(e,n,t,r){if("Identifier"===e.type||"AssignmentPattern"===e.type&&"Identifier"===e.left.type){const i=_("Identifier"===e.type?e.name:e.left.name,t);let o=V(n,r);return"AssignmentPattern"===e.type&&void 0===o&&(o=k(q(e.right))),t?w(i,o):C(i,o)}let i=V(n,r);return"AssignmentPattern"===e.type&&void 0===i&&(i=k(q(e.right))),ie("AssignmentPattern"===e.type?e.left:e,i,t)}function ue(e){if(e.async||e.generator)throw new SyntaxError((e.async?"Async":"Generator")+" function is not allowed");if(R&&!e.expression)throw new SyntaxError("Only an `Expression` is allowed in `ArrowFunctionExpression`'s body")}if(R)return k(q(e));null===(t=F.beforeEvaluate)||void 0===t||t.call(F,e),ue(e);const[le]=b(e);D.CreateImmutableBinding(le,!0);const fe=te(e,D);return D.InitializeBinding(le,fe),fe}class D{constructor(){(0,r.A)(this,"VariableEnvironment",void 0),(0,r.A)(this,"LexicalEnvironment",void 0)}}class ${constructor(e){(0,r.A)(this,"OuterEnv",void 0),(0,r.A)(this,"bindingSet",new Set),this.OuterEnv=e}HasBinding(e){return this.bindingSet.has(e)}CreateBinding(e){this.bindingSet.add(e)}}function z(e){let{expressionOnly:n,visitors:t,withParent:r,hooks:i={}}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const o=new Set,a=[],s=new $(null),c=new D;function u(){return a[a.length-1]}function l(e,n,t){for(const r of n)f(e[r],null==t?void 0:t.concat({node:e,key:r}))}function f(e,r){if(Array.isArray(e))e.forEach(((e,n)=>{f(e,r?r.slice(0,-1).concat({...r[r.length-1],index:n}):r)}));else if(e){var a,s;switch(null===(a=i.beforeVisit)||void 0===a||a.call(i,e,r),function(e){var n,r;t&&(n=t,r=e.type,Object.prototype.hasOwnProperty.call(n,r))&&t[e.type](e)}(e),e.type){case"Identifier":var c;return h=e.name,void(p(u().LexicalEnvironment,h)||(null===(c=i.beforeVisitGlobal)||void 0===c||c.call(i,e,r),o.add(e.name)));case"ArrayExpression":case"ArrayPattern":return void l(e,["elements"],r);case"ArrowFunctionExpression":return void v(y(e,u().LexicalEnvironment),r);case"AssignmentPattern":case"BinaryExpression":case"LogicalExpression":return void l(e,["left","right"],r);case"CallExpression":case"NewExpression":return void l(e,["callee","arguments"],r);case"ChainExpression":return void l(e,["expression"],r);case"ConditionalExpression":return void l(e,["test","consequent","alternate"],r);case"MemberExpression":return l(e,["object"],r),void(e.computed&&l(e,["property"],r));case"ObjectExpression":case"ObjectPattern":return void l(e,["properties"],r);case"Property":return e.computed&&l(e,["key"],r),void l(e,["value"],r);case"RestElement":case"SpreadElement":case"UnaryExpression":return void l(e,["argument"],r);case"SequenceExpression":case"TemplateLiteral":return void l(e,["expressions"],r);case"TaggedTemplateExpression":return void l(e,["tag","quasi"],r);case"Literal":return}if(!n)switch(e.type){case"AssignmentExpression":return void l(e,["right","left"],r);case"BlockStatement":{if(!e.body.length)return;const n=u(),t=n.LexicalEnvironment,i=new $(t);return m(e.body,i),n.LexicalEnvironment=i,l(e,["body"],r),void(n.LexicalEnvironment=t)}case"BreakStatement":case"ContinueStatement":case"EmptyStatement":return;case"CatchClause":{const n=u(),t=n.LexicalEnvironment,i=new $(t);return d(e.param,i),n.LexicalEnvironment=i,l(e,["param","body"],r),void(n.LexicalEnvironment=t)}case"DoWhileStatement":return void l(e,["body","test"],r);case"ExpressionStatement":case"TSAsExpression":return void l(e,["expression"],r);case"ForInStatement":case"ForOfStatement":{const n="VariableDeclaration"===e.left.type&&"var"!==e.left.kind,t=u(),i=t.LexicalEnvironment;if(n){const n=new $(i);d(e.left,n),t.LexicalEnvironment=n}if(l(e,["right"],r),t.LexicalEnvironment=i,n){const n=new $(i);d(e.left,n),t.LexicalEnvironment=n}return l(e,["left","body"],r),void(t.LexicalEnvironment=i)}case"ForStatement":{var g;const n="VariableDeclaration"===(null===(g=e.init)||void 0===g?void 0:g.type)&&"var"!==e.init.kind,t=u(),i=t.LexicalEnvironment;if(n){const n=new $(i);d(e.init,n),t.LexicalEnvironment=n}return l(e,["init","test","body","update"],r),void(t.LexicalEnvironment=i)}case"FunctionDeclaration":{const[n]=b(e),t=u().LexicalEnvironment,i=y(e,t);return t.CreateBinding(n),void v(i,r)}case"FunctionExpression":{const n=function(e){const n=u().LexicalEnvironment;if(!e.id)return y(e,n);const t=e.id.name,r=new $(n);return r.CreateBinding(t),y(e,r)}(e);return void v(n,r)}case"IfStatement":return void l(e,["test","consequent","alternate"],r);case"ReturnStatement":case"ThrowStatement":case"UpdateExpression":return void l(e,["argument"],r);case"SwitchCase":return void l(e,["test","consequent"],r);case"SwitchStatement":{l(e,["discriminant"],r);const n=u(),t=n.LexicalEnvironment,i=new $(t);return m(e.cases,i),n.LexicalEnvironment=i,l(e,["cases"],r),void(n.LexicalEnvironment=t)}case"TryStatement":return void l(e,["block","handler","finalizer"],r);case"VariableDeclaration":return void l(e,["declarations"],r);case"VariableDeclarator":return void l(e,["id","init"],r);case"WhileStatement":return void l(e,["test","body"],r)}(null===(s=i.beforeVisitUnknown)||void 0===s?void 0:s.call(i,e,r))||console.warn(`Unsupported node type \`${e.type}\``)}var h}function d(e,n){for(const t of b(e))n.CreateBinding(t)}function p(e,n){return!!e&&(e.HasBinding(n)||p(e.OuterEnv,n))}function m(e,n){d(h(e,{var:!1,topLevel:!1}),n)}function v(e,n){!function(e){const n=new D,t=new $(e.Environment);n.VariableEnvironment=t,n.LexicalEnvironment=t,a.push(n)}(e),function(e,n){const t=u(),r=e.ECMAScriptCode,i=e.FormalParameters,o=g(i),a=b(h(r,{var:!0,topLevel:!0})),s=t.LexicalEnvironment;let c;if(d(i,s),f(i,null==n?void 0:n.concat({node:e.Function,key:"params"})),o){c=new $(s),t.VariableEnvironment=c;for(const e of a)c.CreateBinding(e)}else{for(const e of a)s.CreateBinding(e);c=s}const l=c;t.LexicalEnvironment=l,d(h(r,{var:!1,topLevel:!0}),l)}(e,n),f(e.ECMAScriptCode,null==n?void 0:n.concat({node:e.Function,key:"body"}).concat("BlockStatement"===e.Function.body.type?{node:e.Function.body,key:"body"}:[])),a.pop()}function y(e,n){return{Function:e,FormalParameters:e.params,ECMAScriptCode:"BlockStatement"===e.body.type?e.body.body:e.body,Environment:n}}return c.VariableEnvironment=s,c.LexicalEnvironment=s,a.push(c),f(e,r?[]:void 0),o}var N=t(56667);function q(e){let{typescript:n,...t}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const r=function(e){let{typescript:n}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const t=(0,N.parse)(e,{plugins:["estree",n&&"typescript"].filter(Boolean),strictMode:!0,attachComment:!1}).program.body,r=n?[]:t;if(n)for(const e of t)if(e.type.startsWith("TS")){if(/Enum|Import|Export/.test(e.type))throw new SyntaxError(`Unsupported TypeScript syntax: ${e.type}`)}else r.push(e);if(0===r.length)throw new SyntaxError("Function declaration not found");if(r.length>1||"FunctionDeclaration"!==r[0].type)throw new SyntaxError(`Expect a single function declaration at top level, but received: ${r.map((e=>`"${e.type}"`)).join(", ")}`);return r[0]}(e,{typescript:n});return{function:r,attemptToVisitGlobals:z(r,t)}}function U(e,n){const t=[],r=e.replace(/^\s*<%[~=]?\s|\s%>\s*$/g,(e=>(t.push(e),""))),i=function(e){return(0,N.parseExpression)(e,{plugins:["estree",["pipelineOperator",{proposal:"minimal"}]],attachComment:!1})}(r);return{expression:i,attemptToVisitGlobals:z(i,{...n,expressionOnly:!0}),source:r,prefix:t[0],suffix:t[1]}}function _(e){return/^\s*<%[~=]?\s/.test(e)&&/\s%>\s*$/.test(e)}function W(e){return/^\s*<%~\s/.test(e)}function G(e){return/^\s*<%=\s/.test(e)&&/\s%>\s*$/.test(e)}}}]);
2
- //# sourceMappingURL=1122.2f11298f.js.map