@stencil/core 2.5.0 → 2.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. package/CHANGELOG.md +19 -181
  2. package/NOTICE.md +109 -2
  3. package/cli/index.cjs +2 -2
  4. package/cli/index.js +2 -2
  5. package/cli/package.json +1 -1
  6. package/compiler/package.json +1 -1
  7. package/compiler/stencil.js +871 -419
  8. package/compiler/stencil.min.js +2 -2
  9. package/dependencies.json +1 -1
  10. package/dev-server/client/index.js +1 -1
  11. package/dev-server/client/package.json +1 -1
  12. package/dev-server/connector.html +2 -2
  13. package/dev-server/index.js +1 -1
  14. package/dev-server/package.json +1 -1
  15. package/dev-server/server-process.js +2 -2
  16. package/internal/app-data/package.json +1 -1
  17. package/internal/client/css-shim.js +1 -1
  18. package/internal/client/dom.js +1 -1
  19. package/internal/client/index.js +5 -2
  20. package/internal/client/package.json +1 -1
  21. package/internal/client/patch-browser.js +1 -1
  22. package/internal/client/patch-esm.js +1 -1
  23. package/internal/client/shadow-css.js +1 -1
  24. package/internal/hydrate/index.js +3 -1
  25. package/internal/hydrate/package.json +1 -1
  26. package/internal/package.json +1 -1
  27. package/internal/stencil-core/index.d.ts +1 -0
  28. package/internal/stencil-core/index.js +1 -0
  29. package/internal/stencil-public-runtime.d.ts +7 -0
  30. package/internal/testing/index.js +3 -2
  31. package/internal/testing/package.json +1 -1
  32. package/mock-doc/index.cjs +1 -1
  33. package/mock-doc/index.js +1 -1
  34. package/mock-doc/package.json +1 -1
  35. package/package.json +2 -3
  36. package/screenshot/compare/.DS_Store +0 -0
  37. package/screenshot/package.json +1 -1
  38. package/sys/.DS_Store +0 -0
  39. package/sys/deno/index.js +1 -1
  40. package/sys/node/index.js +1 -1
  41. package/sys/node/package.json +1 -1
  42. package/sys/node/worker.js +1 -1
  43. package/testing/index.js +275 -140
  44. package/testing/package.json +1 -1
  45. package/screenshot/connector-base.d.ts +0 -42
  46. package/screenshot/connector-local.d.ts +0 -7
  47. package/screenshot/index.d.ts +0 -3
  48. package/screenshot/pixel-match.d.ts +0 -1
  49. package/screenshot/screenshot-compare.d.ts +0 -3
  50. package/screenshot/screenshot-fs.d.ts +0 -15
@@ -1,5 +1,5 @@
1
1
  /*!
2
- Stencil Compiler v2.5.0 | MIT Licensed | https://stenciljs.com
2
+ Stencil Compiler v2.6.0 | MIT Licensed | https://stenciljs.com
3
3
  */
4
4
  (function(exports) {
5
5
  'use strict';
@@ -1653,30 +1653,30 @@ let sep;
1653
1653
  let delimiter;
1654
1654
  let posix$1;
1655
1655
  let win32$1;
1656
- const path$4 = {};
1656
+ const path$5 = {};
1657
1657
  const setPlatformPath = (platformPath) => {
1658
1658
  if (!platformPath) {
1659
1659
  platformPath = pathBrowserify;
1660
1660
  }
1661
- Object.assign(path$4, platformPath);
1662
- const normalizeOrg = path$4.normalize;
1663
- const joinOrg = path$4.join;
1664
- const relativeOrg = path$4.relative;
1665
- const resolveOrg = path$4.resolve;
1666
- normalize$1 = path$4.normalize = (...args) => normalizePath$1(normalizeOrg.apply(path$4, args));
1667
- join = path$4.join = (...args) => normalizePath$1(joinOrg.apply(path$4, args));
1668
- relative$1 = path$4.relative = (...args) => normalizePath$1(relativeOrg.apply(path$4, args));
1669
- resolve$1 = path$4.resolve = (...args) => normalizePath$1(resolveOrg.apply(path$4, args));
1670
- basename = path$4.basename;
1671
- dirname = path$4.dirname;
1672
- extname$1 = path$4.extname;
1673
- isAbsolute$1 = path$4.isAbsolute;
1674
- parse$7 = path$4.parse;
1675
- sep = path$4.sep;
1676
- delimiter = path$4.delimiter;
1677
- posix$1 = path$4.posix;
1678
- if (path$4.win32) {
1679
- win32$1 = path$4.win32;
1661
+ Object.assign(path$5, platformPath);
1662
+ const normalizeOrg = path$5.normalize;
1663
+ const joinOrg = path$5.join;
1664
+ const relativeOrg = path$5.relative;
1665
+ const resolveOrg = path$5.resolve;
1666
+ normalize$1 = path$5.normalize = (...args) => normalizePath$1(normalizeOrg.apply(path$5, args));
1667
+ join = path$5.join = (...args) => normalizePath$1(joinOrg.apply(path$5, args));
1668
+ relative$1 = path$5.relative = (...args) => normalizePath$1(relativeOrg.apply(path$5, args));
1669
+ resolve$1 = path$5.resolve = (...args) => normalizePath$1(resolveOrg.apply(path$5, args));
1670
+ basename = path$5.basename;
1671
+ dirname = path$5.dirname;
1672
+ extname$1 = path$5.extname;
1673
+ isAbsolute$1 = path$5.isAbsolute;
1674
+ parse$7 = path$5.parse;
1675
+ sep = path$5.sep;
1676
+ delimiter = path$5.delimiter;
1677
+ posix$1 = path$5.posix;
1678
+ if (path$5.win32) {
1679
+ win32$1 = path$5.win32;
1680
1680
  }
1681
1681
  else {
1682
1682
  win32$1 = { ...posix$1 };
@@ -1685,7 +1685,7 @@ const setPlatformPath = (platformPath) => {
1685
1685
  };
1686
1686
  setPlatformPath(IS_NODE_ENV ? requireFunc('path') : pathBrowserify);
1687
1687
 
1688
- const path$5 = {
1688
+ const path$6 = {
1689
1689
  __proto__: null,
1690
1690
  get basename () { return basename; },
1691
1691
  get dirname () { return dirname; },
@@ -1700,9 +1700,9 @@ const path$5 = {
1700
1700
  get delimiter () { return delimiter; },
1701
1701
  get posix () { return posix$1; },
1702
1702
  get win32 () { return win32$1; },
1703
- path: path$4,
1703
+ path: path$5,
1704
1704
  setPlatformPath: setPlatformPath,
1705
- 'default': path$4
1705
+ 'default': path$5
1706
1706
  };
1707
1707
 
1708
1708
  // MODULE: compiler/events.js
@@ -2268,7 +2268,7 @@ const require$$0$1 = {
2268
2268
  promisify,
2269
2269
  };
2270
2270
 
2271
- const util$3 = {
2271
+ const util$4 = {
2272
2272
  __proto__: null,
2273
2273
  inherits: inherits$3,
2274
2274
  inspect: inspect,
@@ -2286,25 +2286,25 @@ class FsError extends Error {
2286
2286
  this.errno = errno;
2287
2287
  }
2288
2288
  }
2289
- const fs$2 = {
2289
+ const fs$3 = {
2290
2290
  __sys: {},
2291
2291
  };
2292
- const exists$1 = (fs$2.exists = (p, cb) => {
2293
- fs$2.__sys
2292
+ const exists$1 = (fs$3.exists = (p, cb) => {
2293
+ fs$3.__sys
2294
2294
  .access(p)
2295
2295
  .then(cb)
2296
2296
  .catch(() => cb(false));
2297
2297
  });
2298
2298
  // https://nodejs.org/api/util.html#util_custom_promisified_functions
2299
- exists$1[promisify.custom] = (p) => fs$2.__sys.access(p);
2300
- const existsSync = (fs$2.existsSync = (p) => {
2299
+ exists$1[promisify.custom] = (p) => fs$3.__sys.access(p);
2300
+ const existsSync = (fs$3.existsSync = (p) => {
2301
2301
  // https://nodejs.org/api/fs.html#fs_fs_existssync_path
2302
- return fs$2.__sys.accessSync(p);
2302
+ return fs$3.__sys.accessSync(p);
2303
2303
  });
2304
- const mkdir = (fs$2.mkdir = (p, opts, cb) => {
2304
+ const mkdir = (fs$3.mkdir = (p, opts, cb) => {
2305
2305
  cb = typeof cb === 'function' ? cb : typeof opts === 'function' ? opts : null;
2306
2306
  opts = typeof opts === 'function' ? undefined : opts;
2307
- fs$2.__sys
2307
+ fs$3.__sys
2308
2308
  .createDir(p, opts)
2309
2309
  .then(results => {
2310
2310
  if (cb) {
@@ -2320,23 +2320,23 @@ const mkdir = (fs$2.mkdir = (p, opts, cb) => {
2320
2320
  cb && cb(e);
2321
2321
  });
2322
2322
  });
2323
- const mkdirSync = (fs$2.mkdirSync = (p, opts) => {
2324
- const results = fs$2.__sys.createDirSync(p, opts);
2323
+ const mkdirSync = (fs$3.mkdirSync = (p, opts) => {
2324
+ const results = fs$3.__sys.createDirSync(p, opts);
2325
2325
  if (results.error) {
2326
2326
  throw new FsError('mkdir', p);
2327
2327
  }
2328
2328
  });
2329
- const readdirSync = (fs$2.readdirSync = (p) => {
2329
+ const readdirSync = (fs$3.readdirSync = (p) => {
2330
2330
  // sys.readdirSync includes full paths
2331
2331
  // but if fs.readdirSync was called, the expected
2332
2332
  // nodejs results are of just the basename for each dir item
2333
- const dirItems = fs$2.__sys.readDirSync(p);
2333
+ const dirItems = fs$3.__sys.readDirSync(p);
2334
2334
  return dirItems.map(dirItem => basename(dirItem));
2335
2335
  });
2336
- const readFile$2 = (fs$2.readFile = async (p, opts, cb) => {
2336
+ const readFile$2 = (fs$3.readFile = async (p, opts, cb) => {
2337
2337
  const encoding = typeof opts === 'object' ? opts.encoding : typeof opts === 'string' ? opts : 'utf-8';
2338
2338
  cb = typeof cb === 'function' ? cb : typeof opts === 'function' ? opts : null;
2339
- fs$2.__sys
2339
+ fs$3.__sys
2340
2340
  .readFile(p, encoding)
2341
2341
  .then(data => {
2342
2342
  if (cb) {
@@ -2352,17 +2352,17 @@ const readFile$2 = (fs$2.readFile = async (p, opts, cb) => {
2352
2352
  cb && cb(e);
2353
2353
  });
2354
2354
  });
2355
- const readFileSync = (fs$2.readFileSync = (p, opts) => {
2355
+ const readFileSync = (fs$3.readFileSync = (p, opts) => {
2356
2356
  const encoding = typeof opts === 'object' ? opts.encoding : typeof opts === 'string' ? opts : 'utf-8';
2357
- const data = fs$2.__sys.readFileSync(p, encoding);
2357
+ const data = fs$3.__sys.readFileSync(p, encoding);
2358
2358
  if (typeof data !== 'string') {
2359
2359
  throw new FsError('open', p);
2360
2360
  }
2361
2361
  return data;
2362
2362
  });
2363
- const realpath$3 = (fs$2.realpath = (p, opts, cb) => {
2363
+ const realpath$3 = (fs$3.realpath = (p, opts, cb) => {
2364
2364
  cb = typeof cb === 'function' ? cb : typeof opts === 'function' ? opts : null;
2365
- fs$2.__sys
2365
+ fs$3.__sys
2366
2366
  .realpath(p)
2367
2367
  .then(results => {
2368
2368
  cb && cb(results.error, results.path);
@@ -2371,15 +2371,15 @@ const realpath$3 = (fs$2.realpath = (p, opts, cb) => {
2371
2371
  cb && cb(e);
2372
2372
  });
2373
2373
  });
2374
- const realpathSync$2 = (fs$2.realpathSync = (p) => {
2375
- const results = fs$2.__sys.realpathSync(p);
2374
+ const realpathSync$2 = (fs$3.realpathSync = (p) => {
2375
+ const results = fs$3.__sys.realpathSync(p);
2376
2376
  if (results.error) {
2377
2377
  throw results.error;
2378
2378
  }
2379
2379
  return normalizePath$1(results.path);
2380
2380
  });
2381
- const statSync = (fs$2.statSync = (p) => {
2382
- const fsStats = fs$2.__sys.statSync(p);
2381
+ const statSync = (fs$3.statSync = (p) => {
2382
+ const fsStats = fs$3.__sys.statSync(p);
2383
2383
  if (fsStats.error) {
2384
2384
  throw new FsError('statSync', p);
2385
2385
  }
@@ -2391,10 +2391,10 @@ const statSync = (fs$2.statSync = (p) => {
2391
2391
  mtimeMs: fsStats.mtimeMs,
2392
2392
  };
2393
2393
  });
2394
- const lstatSync = (fs$2.lstatSync = statSync);
2395
- const stat$1 = (fs$2.stat = (p, opts, cb) => {
2394
+ const lstatSync = (fs$3.lstatSync = statSync);
2395
+ const stat$1 = (fs$3.stat = (p, opts, cb) => {
2396
2396
  cb = typeof cb === 'function' ? cb : typeof opts === 'function' ? opts : null;
2397
- fs$2.__sys
2397
+ fs$3.__sys
2398
2398
  .stat(p)
2399
2399
  .then(fsStats => {
2400
2400
  if (cb) {
@@ -2416,12 +2416,12 @@ const stat$1 = (fs$2.stat = (p, opts, cb) => {
2416
2416
  cb && cb(e);
2417
2417
  });
2418
2418
  });
2419
- const watch = (fs$2.watch = () => {
2419
+ const watch = (fs$3.watch = () => {
2420
2420
  throw new Error(`fs.watch() not implemented`);
2421
2421
  });
2422
- const writeFile$1 = (fs$2.writeFile = (p, data, opts, cb) => {
2422
+ const writeFile$1 = (fs$3.writeFile = (p, data, opts, cb) => {
2423
2423
  cb = typeof cb === 'function' ? cb : typeof opts === 'function' ? opts : null;
2424
- fs$2.__sys
2424
+ fs$3.__sys
2425
2425
  .writeFile(p, data)
2426
2426
  .then(writeResults => {
2427
2427
  if (cb) {
@@ -2438,7 +2438,7 @@ const writeFile$1 = (fs$2.writeFile = (p, data, opts, cb) => {
2438
2438
  });
2439
2439
  });
2440
2440
 
2441
- const fs$3 = {
2441
+ const fs$4 = {
2442
2442
  __proto__: null,
2443
2443
  exists: exists$1,
2444
2444
  existsSync: existsSync,
@@ -2454,7 +2454,7 @@ const fs$3 = {
2454
2454
  stat: stat$1,
2455
2455
  watch: watch,
2456
2456
  writeFile: writeFile$1,
2457
- 'default': fs$2
2457
+ 'default': fs$3
2458
2458
  };
2459
2459
 
2460
2460
  // MODULE: ../node_modules/resolve/lib/caller.js
@@ -2596,11 +2596,11 @@ module.exports.win32 = win32.parse;
2596
2596
  });
2597
2597
 
2598
2598
  // MODULE: ..//Users/adam/git/stencil/build/compiler/sys/modules/path.js?commonjs-proxy
2599
- const path$3 = /*@__PURE__*/getAugmentedNamespace$1(path$5);
2599
+ const path$4 = /*@__PURE__*/getAugmentedNamespace$1(path$6);
2600
2600
 
2601
2601
  // MODULE: ../node_modules/resolve/lib/node-modules-paths.js
2602
2602
 
2603
- var parse$6 = path$3.parse || pathParse;
2603
+ var parse$6 = path$4.parse || pathParse;
2604
2604
 
2605
2605
  var getNodeModulesDirs = function getNodeModulesDirs(absoluteStart, modules) {
2606
2606
  var prefix = '/';
@@ -2619,7 +2619,7 @@ var getNodeModulesDirs = function getNodeModulesDirs(absoluteStart, modules) {
2619
2619
 
2620
2620
  return paths.reduce(function (dirs, aPath) {
2621
2621
  return dirs.concat(modules.map(function (moduleDir) {
2622
- return path$3.resolve(prefix, aPath, moduleDir);
2622
+ return path$4.resolve(prefix, aPath, moduleDir);
2623
2623
  }));
2624
2624
  }, []);
2625
2625
  };
@@ -2654,134 +2654,211 @@ var normalizeOptions = function (x, opts) {
2654
2654
  return opts || {};
2655
2655
  };
2656
2656
 
2657
- // MODULE: ../node_modules/resolve/lib/core.json
2658
- const assert$1 = true;
2659
- const async_hooks = ">= 8";
2660
- const buffer_ieee754 = "< 0.9.7";
2661
- const buffer = true;
2662
- const child_process = true;
2663
- const cluster = true;
2664
- const console$1 = true;
2665
- const constants$1 = true;
2666
- const crypto$1 = true;
2667
- const _debug_agent = ">= 1 && < 8";
2668
- const _debugger = "< 8";
2669
- const dgram = true;
2670
- const dns = true;
2671
- const domain = true;
2672
- const events$1 = true;
2673
- const freelist = "< 6";
2674
- const fs$1 = true;
2675
- const _http_agent = ">= 0.11.1";
2676
- const _http_client = ">= 0.11.1";
2677
- const _http_common = ">= 0.11.1";
2678
- const _http_incoming = ">= 0.11.1";
2679
- const _http_outgoing = ">= 0.11.1";
2680
- const _http_server = ">= 0.11.1";
2681
- const http = true;
2682
- const http2 = ">= 8.8";
2683
- const https = true;
2684
- const inspector = ">= 8.0.0";
2685
- const _linklist = "< 8";
2686
- const module$1 = true;
2687
- const net = true;
2688
- const os = true;
2689
- const path$2 = true;
2690
- const perf_hooks = ">= 8.5";
2691
- const process$1 = ">= 1";
2692
- const punycode = true;
2693
- const querystring = true;
2694
- const readline = true;
2695
- const repl = true;
2696
- const smalloc = ">= 0.11.5 && < 3";
2697
- const _stream_duplex = ">= 0.9.4";
2698
- const _stream_transform = ">= 0.9.4";
2699
- const _stream_wrap = ">= 1.4.1";
2700
- const _stream_passthrough = ">= 0.9.4";
2701
- const _stream_readable = ">= 0.9.4";
2702
- const _stream_writable = ">= 0.9.4";
2703
- const stream = true;
2704
- const string_decoder = true;
2705
- const sys = true;
2706
- const timers$1 = true;
2707
- const _tls_common = ">= 0.11.13";
2708
- const _tls_legacy = ">= 0.11.3 && < 10";
2709
- const _tls_wrap = ">= 0.11.3";
2710
- const tls = true;
2711
- const trace_events = ">= 10";
2712
- const tty = true;
2713
- const url = true;
2714
- const util$2 = true;
2715
- const v8 = ">= 1";
2716
- const vm = true;
2717
- const wasi = ">= 13.4 && < 13.5";
2718
- const worker_threads = ">= 11.7";
2719
- const zlib = true;
2720
- const data$1 = {
2721
- assert: assert$1,
2722
- async_hooks: async_hooks,
2723
- buffer_ieee754: buffer_ieee754,
2724
- buffer: buffer,
2725
- child_process: child_process,
2726
- cluster: cluster,
2727
- console: console$1,
2728
- constants: constants$1,
2729
- crypto: crypto$1,
2730
- _debug_agent: _debug_agent,
2731
- _debugger: _debugger,
2732
- dgram: dgram,
2733
- dns: dns,
2734
- domain: domain,
2735
- events: events$1,
2736
- freelist: freelist,
2737
- fs: fs$1,
2657
+ // MODULE: ../node_modules/function-bind/implementation.js
2658
+
2659
+ /* eslint no-invalid-this: 1 */
2660
+
2661
+ var ERROR_MESSAGE = 'Function.prototype.bind called on incompatible ';
2662
+ var slice$1 = Array.prototype.slice;
2663
+ var toStr = Object.prototype.toString;
2664
+ var funcType = '[object Function]';
2665
+
2666
+ var implementation = function bind(that) {
2667
+ var target = this;
2668
+ if (typeof target !== 'function' || toStr.call(target) !== funcType) {
2669
+ throw new TypeError(ERROR_MESSAGE + target);
2670
+ }
2671
+ var args = slice$1.call(arguments, 1);
2672
+
2673
+ var bound;
2674
+ var binder = function () {
2675
+ if (this instanceof bound) {
2676
+ var result = target.apply(
2677
+ this,
2678
+ args.concat(slice$1.call(arguments))
2679
+ );
2680
+ if (Object(result) === result) {
2681
+ return result;
2682
+ }
2683
+ return this;
2684
+ } else {
2685
+ return target.apply(
2686
+ that,
2687
+ args.concat(slice$1.call(arguments))
2688
+ );
2689
+ }
2690
+ };
2691
+
2692
+ var boundLength = Math.max(0, target.length - args.length);
2693
+ var boundArgs = [];
2694
+ for (var i = 0; i < boundLength; i++) {
2695
+ boundArgs.push('$' + i);
2696
+ }
2697
+
2698
+ bound = Function('binder', 'return function (' + boundArgs.join(',') + '){ return binder.apply(this,arguments); }')(binder);
2699
+
2700
+ if (target.prototype) {
2701
+ var Empty = function Empty() {};
2702
+ Empty.prototype = target.prototype;
2703
+ bound.prototype = new Empty();
2704
+ Empty.prototype = null;
2705
+ }
2706
+
2707
+ return bound;
2708
+ };
2709
+
2710
+ // MODULE: ../node_modules/function-bind/index.js
2711
+
2712
+
2713
+
2714
+ var functionBind = Function.prototype.bind || implementation;
2715
+
2716
+ // MODULE: ../node_modules/has/src/index.js
2717
+
2718
+
2719
+
2720
+ var src = functionBind.call(Function.call, Object.prototype.hasOwnProperty);
2721
+
2722
+ // MODULE: ../node_modules/is-core-module/core.json
2723
+ const assert$2 = true;
2724
+ const async_hooks$1 = ">= 8";
2725
+ const buffer_ieee754$1 = "< 0.9.7";
2726
+ const buffer$1 = true;
2727
+ const child_process$1 = true;
2728
+ const cluster$1 = true;
2729
+ const console$2 = true;
2730
+ const constants$2 = true;
2731
+ const crypto$2 = true;
2732
+ const _debug_agent$1 = ">= 1 && < 8";
2733
+ const _debugger$1 = "< 8";
2734
+ const dgram$1 = true;
2735
+ const diagnostics_channel$1 = ">= 15.1";
2736
+ const dns$1 = true;
2737
+ const domain$1 = ">= 0.7.12";
2738
+ const events$2 = true;
2739
+ const freelist$1 = "< 6";
2740
+ const fs$2 = true;
2741
+ const _http_agent$1 = ">= 0.11.1";
2742
+ const _http_client$1 = ">= 0.11.1";
2743
+ const _http_common$1 = ">= 0.11.1";
2744
+ const _http_incoming$1 = ">= 0.11.1";
2745
+ const _http_outgoing$1 = ">= 0.11.1";
2746
+ const _http_server$1 = ">= 0.11.1";
2747
+ const http$1 = true;
2748
+ const http2$1 = ">= 8.8";
2749
+ const https$1 = true;
2750
+ const inspector$1 = ">= 8.0.0";
2751
+ const _linklist$1 = "< 8";
2752
+ const module$2 = true;
2753
+ const net$1 = true;
2754
+ const os$1 = true;
2755
+ const path$3 = true;
2756
+ const perf_hooks$1 = ">= 8.5";
2757
+ const process$2 = ">= 1";
2758
+ const punycode$1 = true;
2759
+ const querystring$1 = true;
2760
+ const readline$1 = true;
2761
+ const repl$1 = true;
2762
+ const smalloc$1 = ">= 0.11.5 && < 3";
2763
+ const _stream_duplex$1 = ">= 0.9.4";
2764
+ const _stream_transform$1 = ">= 0.9.4";
2765
+ const _stream_wrap$1 = ">= 1.4.1";
2766
+ const _stream_passthrough$1 = ">= 0.9.4";
2767
+ const _stream_readable$1 = ">= 0.9.4";
2768
+ const _stream_writable$1 = ">= 0.9.4";
2769
+ const stream$1 = true;
2770
+ const string_decoder$1 = true;
2771
+ const sys$1 = [
2772
+ ">= 0.6 && < 0.7",
2773
+ ">= 0.8"
2774
+ ];
2775
+ const timers$2 = true;
2776
+ const _tls_common$1 = ">= 0.11.13";
2777
+ const _tls_legacy$1 = ">= 0.11.3 && < 10";
2778
+ const _tls_wrap$1 = ">= 0.11.3";
2779
+ const tls$1 = true;
2780
+ const trace_events$1 = ">= 10";
2781
+ const tty$1 = true;
2782
+ const url$1 = true;
2783
+ const util$3 = true;
2784
+ const v8$1 = ">= 1";
2785
+ const vm$1 = true;
2786
+ const wasi$1 = ">= 13.4 && < 13.5";
2787
+ const worker_threads$1 = ">= 11.7";
2788
+ const zlib$1 = true;
2789
+ const data$2 = {
2790
+ assert: assert$2,
2791
+ "assert/strict": ">= 15",
2792
+ async_hooks: async_hooks$1,
2793
+ buffer_ieee754: buffer_ieee754$1,
2794
+ buffer: buffer$1,
2795
+ child_process: child_process$1,
2796
+ cluster: cluster$1,
2797
+ console: console$2,
2798
+ constants: constants$2,
2799
+ crypto: crypto$2,
2800
+ _debug_agent: _debug_agent$1,
2801
+ _debugger: _debugger$1,
2802
+ dgram: dgram$1,
2803
+ diagnostics_channel: diagnostics_channel$1,
2804
+ dns: dns$1,
2805
+ "dns/promises": ">= 15",
2806
+ domain: domain$1,
2807
+ events: events$2,
2808
+ freelist: freelist$1,
2809
+ fs: fs$2,
2738
2810
  "fs/promises": [
2739
2811
  ">= 10 && < 10.1",
2740
2812
  ">= 14"
2741
2813
  ],
2742
- _http_agent: _http_agent,
2743
- _http_client: _http_client,
2744
- _http_common: _http_common,
2745
- _http_incoming: _http_incoming,
2746
- _http_outgoing: _http_outgoing,
2747
- _http_server: _http_server,
2748
- http: http,
2749
- http2: http2,
2750
- https: https,
2751
- inspector: inspector,
2752
- _linklist: _linklist,
2753
- module: module$1,
2754
- net: net,
2814
+ _http_agent: _http_agent$1,
2815
+ _http_client: _http_client$1,
2816
+ _http_common: _http_common$1,
2817
+ _http_incoming: _http_incoming$1,
2818
+ _http_outgoing: _http_outgoing$1,
2819
+ _http_server: _http_server$1,
2820
+ http: http$1,
2821
+ http2: http2$1,
2822
+ https: https$1,
2823
+ inspector: inspector$1,
2824
+ _linklist: _linklist$1,
2825
+ module: module$2,
2826
+ net: net$1,
2755
2827
  "node-inspect/lib/_inspect": ">= 7.6.0 && < 12",
2756
2828
  "node-inspect/lib/internal/inspect_client": ">= 7.6.0 && < 12",
2757
2829
  "node-inspect/lib/internal/inspect_repl": ">= 7.6.0 && < 12",
2758
- os: os,
2759
- path: path$2,
2760
- perf_hooks: perf_hooks,
2761
- process: process$1,
2762
- punycode: punycode,
2763
- querystring: querystring,
2764
- readline: readline,
2765
- repl: repl,
2766
- smalloc: smalloc,
2767
- _stream_duplex: _stream_duplex,
2768
- _stream_transform: _stream_transform,
2769
- _stream_wrap: _stream_wrap,
2770
- _stream_passthrough: _stream_passthrough,
2771
- _stream_readable: _stream_readable,
2772
- _stream_writable: _stream_writable,
2773
- stream: stream,
2774
- string_decoder: string_decoder,
2775
- sys: sys,
2776
- timers: timers$1,
2777
- _tls_common: _tls_common,
2778
- _tls_legacy: _tls_legacy,
2779
- _tls_wrap: _tls_wrap,
2780
- tls: tls,
2781
- trace_events: trace_events,
2782
- tty: tty,
2783
- url: url,
2784
- util: util$2,
2830
+ os: os$1,
2831
+ path: path$3,
2832
+ "path/posix": ">= 15.3",
2833
+ "path/win32": ">= 15.3",
2834
+ perf_hooks: perf_hooks$1,
2835
+ process: process$2,
2836
+ punycode: punycode$1,
2837
+ querystring: querystring$1,
2838
+ readline: readline$1,
2839
+ repl: repl$1,
2840
+ smalloc: smalloc$1,
2841
+ _stream_duplex: _stream_duplex$1,
2842
+ _stream_transform: _stream_transform$1,
2843
+ _stream_wrap: _stream_wrap$1,
2844
+ _stream_passthrough: _stream_passthrough$1,
2845
+ _stream_readable: _stream_readable$1,
2846
+ _stream_writable: _stream_writable$1,
2847
+ stream: stream$1,
2848
+ "stream/promises": ">= 15",
2849
+ string_decoder: string_decoder$1,
2850
+ sys: sys$1,
2851
+ timers: timers$2,
2852
+ "timers/promises": ">= 15",
2853
+ _tls_common: _tls_common$1,
2854
+ _tls_legacy: _tls_legacy$1,
2855
+ _tls_wrap: _tls_wrap$1,
2856
+ tls: tls$1,
2857
+ trace_events: trace_events$1,
2858
+ tty: tty$1,
2859
+ url: url$1,
2860
+ util: util$3,
2861
+ "util/types": ">= 15.3",
2785
2862
  "v8/tools/arguments": ">= 10 && < 12",
2786
2863
  "v8/tools/codemap": [
2787
2864
  ">= 4.4.0 && < 5",
@@ -2807,84 +2884,92 @@ const data$1 = {
2807
2884
  ">= 4.4.0 && < 5",
2808
2885
  ">= 5.2.0 && < 12"
2809
2886
  ],
2810
- v8: v8,
2811
- vm: vm,
2812
- wasi: wasi,
2813
- worker_threads: worker_threads,
2814
- zlib: zlib
2887
+ v8: v8$1,
2888
+ vm: vm$1,
2889
+ wasi: wasi$1,
2890
+ worker_threads: worker_threads$1,
2891
+ zlib: zlib$1
2815
2892
  };
2816
2893
 
2817
- // MODULE: ../node_modules/resolve/lib/core.js
2894
+ // MODULE: ../node_modules/is-core-module/index.js
2818
2895
 
2819
- var current = (process.versions && process.versions.node && process.versions.node.split('.')) || [];
2820
2896
 
2821
- function specifierIncluded(specifier) {
2822
- var parts = specifier.split(' ');
2823
- var op = parts.length > 1 ? parts[0] : '=';
2824
- var versionParts = (parts.length > 1 ? parts[1] : parts[0]).split('.');
2825
2897
 
2826
- for (var i = 0; i < 3; ++i) {
2827
- var cur = Number(current[i] || 0);
2828
- var ver = Number(versionParts[i] || 0);
2829
- if (cur === ver) {
2830
- continue; // eslint-disable-line no-restricted-syntax, no-continue
2831
- }
2832
- if (op === '<') {
2833
- return cur < ver;
2834
- } else if (op === '>=') {
2835
- return cur >= ver;
2836
- } else {
2837
- return false;
2838
- }
2839
- }
2840
- return op === '>=';
2841
- }
2898
+ function specifierIncluded$1(current, specifier) {
2899
+ var nodeParts = current.split('.');
2900
+ var parts = specifier.split(' ');
2901
+ var op = parts.length > 1 ? parts[0] : '=';
2902
+ var versionParts = (parts.length > 1 ? parts[1] : parts[0]).split('.');
2842
2903
 
2843
- function matchesRange(range) {
2844
- var specifiers = range.split(/ ?&& ?/);
2845
- if (specifiers.length === 0) { return false; }
2846
- for (var i = 0; i < specifiers.length; ++i) {
2847
- if (!specifierIncluded(specifiers[i])) { return false; }
2848
- }
2849
- return true;
2904
+ for (var i = 0; i < 3; ++i) {
2905
+ var cur = parseInt(nodeParts[i] || 0, 10);
2906
+ var ver = parseInt(versionParts[i] || 0, 10);
2907
+ if (cur === ver) {
2908
+ continue; // eslint-disable-line no-restricted-syntax, no-continue
2909
+ }
2910
+ if (op === '<') {
2911
+ return cur < ver;
2912
+ }
2913
+ if (op === '>=') {
2914
+ return cur >= ver;
2915
+ }
2916
+ return false;
2917
+ }
2918
+ return op === '>=';
2850
2919
  }
2851
2920
 
2852
- function versionIncluded(specifierValue) {
2853
- if (typeof specifierValue === 'boolean') { return specifierValue; }
2854
- if (specifierValue && typeof specifierValue === 'object') {
2855
- for (var i = 0; i < specifierValue.length; ++i) {
2856
- if (matchesRange(specifierValue[i])) { return true; }
2857
- }
2858
- return false;
2859
- }
2860
- return matchesRange(specifierValue);
2921
+ function matchesRange$1(current, range) {
2922
+ var specifiers = range.split(/ ?&& ?/);
2923
+ if (specifiers.length === 0) {
2924
+ return false;
2925
+ }
2926
+ for (var i = 0; i < specifiers.length; ++i) {
2927
+ if (!specifierIncluded$1(current, specifiers[i])) {
2928
+ return false;
2929
+ }
2930
+ }
2931
+ return true;
2861
2932
  }
2862
2933
 
2934
+ function versionIncluded$1(nodeVersion, specifierValue) {
2935
+ if (typeof specifierValue === 'boolean') {
2936
+ return specifierValue;
2937
+ }
2863
2938
 
2939
+ var current = typeof nodeVersion === 'undefined'
2940
+ ? process.versions && process.versions.node && process.versions.node
2941
+ : nodeVersion;
2864
2942
 
2865
- var core = {};
2866
- for (var mod in data$1) { // eslint-disable-line no-restricted-syntax
2867
- if (Object.prototype.hasOwnProperty.call(data$1, mod)) {
2868
- core[mod] = versionIncluded(data$1[mod]);
2869
- }
2943
+ if (typeof current !== 'string') {
2944
+ throw new TypeError(typeof nodeVersion === 'undefined' ? 'Unable to determine current node version' : 'If provided, a valid node version is required');
2945
+ }
2946
+
2947
+ if (specifierValue && typeof specifierValue === 'object') {
2948
+ for (var i = 0; i < specifierValue.length; ++i) {
2949
+ if (matchesRange$1(current, specifierValue[i])) {
2950
+ return true;
2951
+ }
2952
+ }
2953
+ return false;
2954
+ }
2955
+ return matchesRange$1(current, specifierValue);
2870
2956
  }
2871
- var core_1 = core;
2872
2957
 
2873
- // MODULE: ../node_modules/resolve/lib/is-core.js
2874
2958
 
2875
- var isCore = function isCore(x) {
2876
- return Object.prototype.hasOwnProperty.call(core_1, x);
2959
+
2960
+ var isCoreModule = function isCore(x, nodeVersion) {
2961
+ return src(data$2, x) && versionIncluded$1(nodeVersion, data$2[x]);
2877
2962
  };
2878
2963
 
2879
2964
  // MODULE: ..//Users/adam/git/stencil/build/compiler/sys/modules/fs.js?commonjs-proxy
2880
- const fs = /*@__PURE__*/getAugmentedNamespace$1(fs$3);
2965
+ const fs$1 = /*@__PURE__*/getAugmentedNamespace$1(fs$4);
2881
2966
 
2882
2967
  // MODULE: ../node_modules/resolve/lib/async.js
2883
2968
 
2884
- var realpathFS$1 = fs.realpath && typeof fs.realpath.native === 'function' ? fs.realpath.native : fs.realpath;
2969
+ var realpathFS$1 = fs$1.realpath && typeof fs$1.realpath.native === 'function' ? fs$1.realpath.native : fs$1.realpath;
2885
2970
 
2886
2971
  var defaultIsFile$1 = function isFile(file, cb) {
2887
- fs.stat(file, function (err, stat) {
2972
+ fs$1.stat(file, function (err, stat) {
2888
2973
  if (!err) {
2889
2974
  return cb(null, stat.isFile() || stat.isFIFO());
2890
2975
  }
@@ -2894,7 +2979,7 @@ var defaultIsFile$1 = function isFile(file, cb) {
2894
2979
  };
2895
2980
 
2896
2981
  var defaultIsDir$1 = function isDirectory(dir, cb) {
2897
- fs.stat(dir, function (err, stat) {
2982
+ fs$1.stat(dir, function (err, stat) {
2898
2983
  if (!err) {
2899
2984
  return cb(null, stat.isDirectory());
2900
2985
  }
@@ -2918,10 +3003,24 @@ var maybeRealpath = function maybeRealpath(realpath, x, opts, cb) {
2918
3003
  }
2919
3004
  };
2920
3005
 
3006
+ var defaultReadPackage = function defaultReadPackage(readFile, pkgfile, cb) {
3007
+ readFile(pkgfile, function (readFileErr, body) {
3008
+ if (readFileErr) cb(readFileErr);
3009
+ else {
3010
+ try {
3011
+ var pkg = JSON.parse(body);
3012
+ cb(null, pkg);
3013
+ } catch (jsonErr) {
3014
+ cb(null);
3015
+ }
3016
+ }
3017
+ });
3018
+ };
3019
+
2921
3020
  var getPackageCandidates$1 = function getPackageCandidates(x, start, opts) {
2922
3021
  var dirs = nodeModulesPaths(start, opts, x);
2923
3022
  for (var i = 0; i < dirs.length; i++) {
2924
- dirs[i] = path$3.join(dirs[i], x);
3023
+ dirs[i] = path$4.join(dirs[i], x);
2925
3024
  }
2926
3025
  return dirs;
2927
3026
  };
@@ -2944,18 +3043,26 @@ var async = function resolve(x, options, callback) {
2944
3043
 
2945
3044
  var isFile = opts.isFile || defaultIsFile$1;
2946
3045
  var isDirectory = opts.isDirectory || defaultIsDir$1;
2947
- var readFile = opts.readFile || fs.readFile;
3046
+ var readFile = opts.readFile || fs$1.readFile;
2948
3047
  var realpath = opts.realpath || defaultRealpath;
3048
+ var readPackage = opts.readPackage || defaultReadPackage;
3049
+ if (opts.readFile && opts.readPackage) {
3050
+ var conflictErr = new TypeError('`readFile` and `readPackage` are mutually exclusive.');
3051
+ return process.nextTick(function () {
3052
+ cb(conflictErr);
3053
+ });
3054
+ }
2949
3055
  var packageIterator = opts.packageIterator;
2950
3056
 
2951
3057
  var extensions = opts.extensions || ['.js'];
2952
- var basedir = opts.basedir || path$3.dirname(caller());
3058
+ var includeCoreModules = opts.includeCoreModules !== false;
3059
+ var basedir = opts.basedir || path$4.dirname(caller());
2953
3060
  var parent = opts.filename || basedir;
2954
3061
 
2955
3062
  opts.paths = opts.paths || [];
2956
3063
 
2957
3064
  // ensure that `basedir` is an absolute path at this point, resolving against the process' current working directory
2958
- var absoluteStart = path$3.resolve(basedir);
3065
+ var absoluteStart = path$4.resolve(basedir);
2959
3066
 
2960
3067
  maybeRealpath(
2961
3068
  realpath,
@@ -2970,12 +3077,12 @@ var async = function resolve(x, options, callback) {
2970
3077
  var res;
2971
3078
  function init(basedir) {
2972
3079
  if ((/^(?:\.\.?(?:\/|$)|\/|([A-Za-z]:)?[/\\])/).test(x)) {
2973
- res = path$3.resolve(basedir, x);
3080
+ res = path$4.resolve(basedir, x);
2974
3081
  if (x === '.' || x === '..' || x.slice(-1) === '/') res += '/';
2975
3082
  if ((/\/$/).test(x) && res === basedir) {
2976
3083
  loadAsDirectory(res, opts.package, onfile);
2977
3084
  } else loadAsFile(res, opts.package, onfile);
2978
- } else if (isCore(x)) {
3085
+ } else if (includeCoreModules && isCoreModule(x)) {
2979
3086
  return cb(null, x);
2980
3087
  } else loadNodeModules(x, basedir, function (err, n, pkg) {
2981
3088
  if (err) cb(err);
@@ -3033,18 +3140,18 @@ var async = function resolve(x, options, callback) {
3033
3140
 
3034
3141
  var pkg = loadPackage;
3035
3142
  if (pkg) onpkg(null, pkg);
3036
- else loadpkg(path$3.dirname(file), onpkg);
3143
+ else loadpkg(path$4.dirname(file), onpkg);
3037
3144
 
3038
3145
  function onpkg(err, pkg_, dir) {
3039
3146
  pkg = pkg_;
3040
3147
  if (err) return cb(err);
3041
3148
  if (dir && pkg && opts.pathFilter) {
3042
- var rfile = path$3.relative(dir, file);
3149
+ var rfile = path$4.relative(dir, file);
3043
3150
  var rel = rfile.slice(0, rfile.length - exts[0].length);
3044
3151
  var r = opts.pathFilter(pkg, x, rel);
3045
3152
  if (r) return load(
3046
3153
  [''].concat(extensions.slice()),
3047
- path$3.resolve(dir, r),
3154
+ path$4.resolve(dir, r),
3048
3155
  pkg
3049
3156
  );
3050
3157
  }
@@ -3066,15 +3173,16 @@ var async = function resolve(x, options, callback) {
3066
3173
  if ((/[/\\]node_modules[/\\]*$/).test(dir)) return cb(null);
3067
3174
 
3068
3175
  maybeRealpath(realpath, dir, opts, function (unwrapErr, pkgdir) {
3069
- if (unwrapErr) return loadpkg(path$3.dirname(dir), cb);
3070
- var pkgfile = path$3.join(pkgdir, 'package.json');
3176
+ if (unwrapErr) return loadpkg(path$4.dirname(dir), cb);
3177
+ var pkgfile = path$4.join(pkgdir, 'package.json');
3071
3178
  isFile(pkgfile, function (err, ex) {
3072
3179
  // on err, ex is false
3073
- if (!ex) return loadpkg(path$3.dirname(dir), cb);
3180
+ if (!ex) return loadpkg(path$4.dirname(dir), cb);
3074
3181
 
3075
- readFile(pkgfile, function (err, body) {
3182
+ readPackage(readFile, pkgfile, function (err, pkgParam) {
3076
3183
  if (err) cb(err);
3077
- try { var pkg = JSON.parse(body); } catch (jsonErr) {}
3184
+
3185
+ var pkg = pkgParam;
3078
3186
 
3079
3187
  if (pkg && opts.packageFilter) {
3080
3188
  pkg = opts.packageFilter(pkg, pkgfile);
@@ -3095,16 +3203,15 @@ var async = function resolve(x, options, callback) {
3095
3203
 
3096
3204
  maybeRealpath(realpath, x, opts, function (unwrapErr, pkgdir) {
3097
3205
  if (unwrapErr) return cb(unwrapErr);
3098
- var pkgfile = path$3.join(pkgdir, 'package.json');
3206
+ var pkgfile = path$4.join(pkgdir, 'package.json');
3099
3207
  isFile(pkgfile, function (err, ex) {
3100
3208
  if (err) return cb(err);
3101
- if (!ex) return loadAsFile(path$3.join(x, 'index'), fpkg, cb);
3209
+ if (!ex) return loadAsFile(path$4.join(x, 'index'), fpkg, cb);
3102
3210
 
3103
- readFile(pkgfile, function (err, body) {
3211
+ readPackage(readFile, pkgfile, function (err, pkgParam) {
3104
3212
  if (err) return cb(err);
3105
- try {
3106
- var pkg = JSON.parse(body);
3107
- } catch (jsonErr) {}
3213
+
3214
+ var pkg = pkgParam;
3108
3215
 
3109
3216
  if (pkg && opts.packageFilter) {
3110
3217
  pkg = opts.packageFilter(pkg, pkgfile);
@@ -3119,22 +3226,22 @@ var async = function resolve(x, options, callback) {
3119
3226
  if (pkg.main === '.' || pkg.main === './') {
3120
3227
  pkg.main = 'index';
3121
3228
  }
3122
- loadAsFile(path$3.resolve(x, pkg.main), pkg, function (err, m, pkg) {
3229
+ loadAsFile(path$4.resolve(x, pkg.main), pkg, function (err, m, pkg) {
3123
3230
  if (err) return cb(err);
3124
3231
  if (m) return cb(null, m, pkg);
3125
- if (!pkg) return loadAsFile(path$3.join(x, 'index'), pkg, cb);
3232
+ if (!pkg) return loadAsFile(path$4.join(x, 'index'), pkg, cb);
3126
3233
 
3127
- var dir = path$3.resolve(x, pkg.main);
3234
+ var dir = path$4.resolve(x, pkg.main);
3128
3235
  loadAsDirectory(dir, pkg, function (err, n, pkg) {
3129
3236
  if (err) return cb(err);
3130
3237
  if (n) return cb(null, n, pkg);
3131
- loadAsFile(path$3.join(x, 'index'), pkg, cb);
3238
+ loadAsFile(path$4.join(x, 'index'), pkg, cb);
3132
3239
  });
3133
3240
  });
3134
3241
  return;
3135
3242
  }
3136
3243
 
3137
- loadAsFile(path$3.join(x, '/index'), pkg, cb);
3244
+ loadAsFile(path$4.join(x, '/index'), pkg, cb);
3138
3245
  });
3139
3246
  });
3140
3247
  });
@@ -3144,7 +3251,7 @@ var async = function resolve(x, options, callback) {
3144
3251
  if (dirs.length === 0) return cb(null, undefined);
3145
3252
  var dir = dirs[0];
3146
3253
 
3147
- isDirectory(path$3.dirname(dir), isdir);
3254
+ isDirectory(path$4.dirname(dir), isdir);
3148
3255
 
3149
3256
  function isdir(err, isdir) {
3150
3257
  if (err) return cb(err);
@@ -3173,13 +3280,247 @@ var async = function resolve(x, options, callback) {
3173
3280
  }
3174
3281
  };
3175
3282
 
3283
+ // MODULE: ../node_modules/resolve/lib/core.json
3284
+ const assert$1 = true;
3285
+ const async_hooks = ">= 8";
3286
+ const buffer_ieee754 = "< 0.9.7";
3287
+ const buffer = true;
3288
+ const child_process = true;
3289
+ const cluster = true;
3290
+ const console$1 = true;
3291
+ const constants$1 = true;
3292
+ const crypto$1 = true;
3293
+ const _debug_agent = ">= 1 && < 8";
3294
+ const _debugger = "< 8";
3295
+ const dgram = true;
3296
+ const diagnostics_channel = ">= 15.1";
3297
+ const dns = true;
3298
+ const domain = ">= 0.7.12";
3299
+ const events$1 = true;
3300
+ const freelist = "< 6";
3301
+ const fs = true;
3302
+ const _http_agent = ">= 0.11.1";
3303
+ const _http_client = ">= 0.11.1";
3304
+ const _http_common = ">= 0.11.1";
3305
+ const _http_incoming = ">= 0.11.1";
3306
+ const _http_outgoing = ">= 0.11.1";
3307
+ const _http_server = ">= 0.11.1";
3308
+ const http = true;
3309
+ const http2 = ">= 8.8";
3310
+ const https = true;
3311
+ const inspector = ">= 8.0.0";
3312
+ const _linklist = "< 8";
3313
+ const module$1 = true;
3314
+ const net = true;
3315
+ const os = true;
3316
+ const path$2 = true;
3317
+ const perf_hooks = ">= 8.5";
3318
+ const process$1 = ">= 1";
3319
+ const punycode = true;
3320
+ const querystring = true;
3321
+ const readline = true;
3322
+ const repl = true;
3323
+ const smalloc = ">= 0.11.5 && < 3";
3324
+ const _stream_duplex = ">= 0.9.4";
3325
+ const _stream_transform = ">= 0.9.4";
3326
+ const _stream_wrap = ">= 1.4.1";
3327
+ const _stream_passthrough = ">= 0.9.4";
3328
+ const _stream_readable = ">= 0.9.4";
3329
+ const _stream_writable = ">= 0.9.4";
3330
+ const stream = true;
3331
+ const string_decoder = true;
3332
+ const sys = [
3333
+ ">= 0.6 && < 0.7",
3334
+ ">= 0.8"
3335
+ ];
3336
+ const timers$1 = true;
3337
+ const _tls_common = ">= 0.11.13";
3338
+ const _tls_legacy = ">= 0.11.3 && < 10";
3339
+ const _tls_wrap = ">= 0.11.3";
3340
+ const tls = true;
3341
+ const trace_events = ">= 10";
3342
+ const tty = true;
3343
+ const url = true;
3344
+ const util$2 = true;
3345
+ const v8 = ">= 1";
3346
+ const vm = true;
3347
+ const wasi = ">= 13.4 && < 13.5";
3348
+ const worker_threads = ">= 11.7";
3349
+ const zlib = true;
3350
+ const data$1 = {
3351
+ assert: assert$1,
3352
+ "assert/strict": ">= 15",
3353
+ async_hooks: async_hooks,
3354
+ buffer_ieee754: buffer_ieee754,
3355
+ buffer: buffer,
3356
+ child_process: child_process,
3357
+ cluster: cluster,
3358
+ console: console$1,
3359
+ constants: constants$1,
3360
+ crypto: crypto$1,
3361
+ _debug_agent: _debug_agent,
3362
+ _debugger: _debugger,
3363
+ dgram: dgram,
3364
+ diagnostics_channel: diagnostics_channel,
3365
+ dns: dns,
3366
+ "dns/promises": ">= 15",
3367
+ domain: domain,
3368
+ events: events$1,
3369
+ freelist: freelist,
3370
+ fs: fs,
3371
+ "fs/promises": [
3372
+ ">= 10 && < 10.1",
3373
+ ">= 14"
3374
+ ],
3375
+ _http_agent: _http_agent,
3376
+ _http_client: _http_client,
3377
+ _http_common: _http_common,
3378
+ _http_incoming: _http_incoming,
3379
+ _http_outgoing: _http_outgoing,
3380
+ _http_server: _http_server,
3381
+ http: http,
3382
+ http2: http2,
3383
+ https: https,
3384
+ inspector: inspector,
3385
+ _linklist: _linklist,
3386
+ module: module$1,
3387
+ net: net,
3388
+ "node-inspect/lib/_inspect": ">= 7.6.0 && < 12",
3389
+ "node-inspect/lib/internal/inspect_client": ">= 7.6.0 && < 12",
3390
+ "node-inspect/lib/internal/inspect_repl": ">= 7.6.0 && < 12",
3391
+ os: os,
3392
+ path: path$2,
3393
+ "path/posix": ">= 15.3",
3394
+ "path/win32": ">= 15.3",
3395
+ perf_hooks: perf_hooks,
3396
+ process: process$1,
3397
+ punycode: punycode,
3398
+ querystring: querystring,
3399
+ readline: readline,
3400
+ repl: repl,
3401
+ smalloc: smalloc,
3402
+ _stream_duplex: _stream_duplex,
3403
+ _stream_transform: _stream_transform,
3404
+ _stream_wrap: _stream_wrap,
3405
+ _stream_passthrough: _stream_passthrough,
3406
+ _stream_readable: _stream_readable,
3407
+ _stream_writable: _stream_writable,
3408
+ stream: stream,
3409
+ "stream/promises": ">= 15",
3410
+ string_decoder: string_decoder,
3411
+ sys: sys,
3412
+ timers: timers$1,
3413
+ "timers/promises": ">= 15",
3414
+ _tls_common: _tls_common,
3415
+ _tls_legacy: _tls_legacy,
3416
+ _tls_wrap: _tls_wrap,
3417
+ tls: tls,
3418
+ trace_events: trace_events,
3419
+ tty: tty,
3420
+ url: url,
3421
+ util: util$2,
3422
+ "util/types": ">= 15.3",
3423
+ "v8/tools/arguments": ">= 10 && < 12",
3424
+ "v8/tools/codemap": [
3425
+ ">= 4.4.0 && < 5",
3426
+ ">= 5.2.0 && < 12"
3427
+ ],
3428
+ "v8/tools/consarray": [
3429
+ ">= 4.4.0 && < 5",
3430
+ ">= 5.2.0 && < 12"
3431
+ ],
3432
+ "v8/tools/csvparser": [
3433
+ ">= 4.4.0 && < 5",
3434
+ ">= 5.2.0 && < 12"
3435
+ ],
3436
+ "v8/tools/logreader": [
3437
+ ">= 4.4.0 && < 5",
3438
+ ">= 5.2.0 && < 12"
3439
+ ],
3440
+ "v8/tools/profile_view": [
3441
+ ">= 4.4.0 && < 5",
3442
+ ">= 5.2.0 && < 12"
3443
+ ],
3444
+ "v8/tools/splaytree": [
3445
+ ">= 4.4.0 && < 5",
3446
+ ">= 5.2.0 && < 12"
3447
+ ],
3448
+ v8: v8,
3449
+ vm: vm,
3450
+ wasi: wasi,
3451
+ worker_threads: worker_threads,
3452
+ zlib: zlib
3453
+ };
3454
+
3455
+ // MODULE: ../node_modules/resolve/lib/core.js
3456
+
3457
+ var current = (process.versions && process.versions.node && process.versions.node.split('.')) || [];
3458
+
3459
+ function specifierIncluded(specifier) {
3460
+ var parts = specifier.split(' ');
3461
+ var op = parts.length > 1 ? parts[0] : '=';
3462
+ var versionParts = (parts.length > 1 ? parts[1] : parts[0]).split('.');
3463
+
3464
+ for (var i = 0; i < 3; ++i) {
3465
+ var cur = parseInt(current[i] || 0, 10);
3466
+ var ver = parseInt(versionParts[i] || 0, 10);
3467
+ if (cur === ver) {
3468
+ continue; // eslint-disable-line no-restricted-syntax, no-continue
3469
+ }
3470
+ if (op === '<') {
3471
+ return cur < ver;
3472
+ } else if (op === '>=') {
3473
+ return cur >= ver;
3474
+ } else {
3475
+ return false;
3476
+ }
3477
+ }
3478
+ return op === '>=';
3479
+ }
3480
+
3481
+ function matchesRange(range) {
3482
+ var specifiers = range.split(/ ?&& ?/);
3483
+ if (specifiers.length === 0) { return false; }
3484
+ for (var i = 0; i < specifiers.length; ++i) {
3485
+ if (!specifierIncluded(specifiers[i])) { return false; }
3486
+ }
3487
+ return true;
3488
+ }
3489
+
3490
+ function versionIncluded(specifierValue) {
3491
+ if (typeof specifierValue === 'boolean') { return specifierValue; }
3492
+ if (specifierValue && typeof specifierValue === 'object') {
3493
+ for (var i = 0; i < specifierValue.length; ++i) {
3494
+ if (matchesRange(specifierValue[i])) { return true; }
3495
+ }
3496
+ return false;
3497
+ }
3498
+ return matchesRange(specifierValue);
3499
+ }
3500
+
3501
+
3502
+
3503
+ var core = {};
3504
+ for (var mod in data$1) { // eslint-disable-line no-restricted-syntax
3505
+ if (Object.prototype.hasOwnProperty.call(data$1, mod)) {
3506
+ core[mod] = versionIncluded(data$1[mod]);
3507
+ }
3508
+ }
3509
+ var core_1 = core;
3510
+
3511
+ // MODULE: ../node_modules/resolve/lib/is-core.js
3512
+
3513
+ var isCore = function isCore(x) {
3514
+ return isCoreModule(x);
3515
+ };
3516
+
3176
3517
  // MODULE: ../node_modules/resolve/lib/sync.js
3177
3518
 
3178
- var realpathFS = fs.realpathSync && typeof fs.realpathSync.native === 'function' ? fs.realpathSync.native : fs.realpathSync;
3519
+ var realpathFS = fs$1.realpathSync && typeof fs$1.realpathSync.native === 'function' ? fs$1.realpathSync.native : fs$1.realpathSync;
3179
3520
 
3180
3521
  var defaultIsFile = function isFile(file) {
3181
3522
  try {
3182
- var stat = fs.statSync(file);
3523
+ var stat = fs$1.statSync(file);
3183
3524
  } catch (e) {
3184
3525
  if (e && (e.code === 'ENOENT' || e.code === 'ENOTDIR')) return false;
3185
3526
  throw e;
@@ -3189,7 +3530,7 @@ var defaultIsFile = function isFile(file) {
3189
3530
 
3190
3531
  var defaultIsDir = function isDirectory(dir) {
3191
3532
  try {
3192
- var stat = fs.statSync(dir);
3533
+ var stat = fs$1.statSync(dir);
3193
3534
  } catch (e) {
3194
3535
  if (e && (e.code === 'ENOENT' || e.code === 'ENOTDIR')) return false;
3195
3536
  throw e;
@@ -3215,10 +3556,18 @@ var maybeRealpathSync = function maybeRealpathSync(realpathSync, x, opts) {
3215
3556
  return x;
3216
3557
  };
3217
3558
 
3559
+ var defaultReadPackageSync = function defaultReadPackageSync(readFileSync, pkgfile) {
3560
+ var body = readFileSync(pkgfile);
3561
+ try {
3562
+ var pkg = JSON.parse(body);
3563
+ return pkg;
3564
+ } catch (jsonErr) {}
3565
+ };
3566
+
3218
3567
  var getPackageCandidates = function getPackageCandidates(x, start, opts) {
3219
3568
  var dirs = nodeModulesPaths(start, opts, x);
3220
3569
  for (var i = 0; i < dirs.length; i++) {
3221
- dirs[i] = path$3.join(dirs[i], x);
3570
+ dirs[i] = path$4.join(dirs[i], x);
3222
3571
  }
3223
3572
  return dirs;
3224
3573
  };
@@ -3230,26 +3579,31 @@ var sync$1 = function resolveSync(x, options) {
3230
3579
  var opts = normalizeOptions(x, options);
3231
3580
 
3232
3581
  var isFile = opts.isFile || defaultIsFile;
3233
- var readFileSync = opts.readFileSync || fs.readFileSync;
3582
+ var readFileSync = opts.readFileSync || fs$1.readFileSync;
3234
3583
  var isDirectory = opts.isDirectory || defaultIsDir;
3235
3584
  var realpathSync = opts.realpathSync || defaultRealpathSync;
3585
+ var readPackageSync = opts.readPackageSync || defaultReadPackageSync;
3586
+ if (opts.readFileSync && opts.readPackageSync) {
3587
+ throw new TypeError('`readFileSync` and `readPackageSync` are mutually exclusive.');
3588
+ }
3236
3589
  var packageIterator = opts.packageIterator;
3237
3590
 
3238
3591
  var extensions = opts.extensions || ['.js'];
3239
- var basedir = opts.basedir || path$3.dirname(caller());
3592
+ var includeCoreModules = opts.includeCoreModules !== false;
3593
+ var basedir = opts.basedir || path$4.dirname(caller());
3240
3594
  var parent = opts.filename || basedir;
3241
3595
 
3242
3596
  opts.paths = opts.paths || [];
3243
3597
 
3244
3598
  // ensure that `basedir` is an absolute path at this point, resolving against the process' current working directory
3245
- var absoluteStart = maybeRealpathSync(realpathSync, path$3.resolve(basedir), opts);
3599
+ var absoluteStart = maybeRealpathSync(realpathSync, path$4.resolve(basedir), opts);
3246
3600
 
3247
3601
  if ((/^(?:\.\.?(?:\/|$)|\/|([A-Za-z]:)?[/\\])/).test(x)) {
3248
- var res = path$3.resolve(absoluteStart, x);
3602
+ var res = path$4.resolve(absoluteStart, x);
3249
3603
  if (x === '.' || x === '..' || x.slice(-1) === '/') res += '/';
3250
3604
  var m = loadAsFileSync(res) || loadAsDirectorySync(res);
3251
3605
  if (m) return maybeRealpathSync(realpathSync, m, opts);
3252
- } else if (isCore(x)) {
3606
+ } else if (includeCoreModules && isCoreModule(x)) {
3253
3607
  return x;
3254
3608
  } else {
3255
3609
  var n = loadNodeModulesSync(x, absoluteStart);
@@ -3261,13 +3615,13 @@ var sync$1 = function resolveSync(x, options) {
3261
3615
  throw err;
3262
3616
 
3263
3617
  function loadAsFileSync(x) {
3264
- var pkg = loadpkg(path$3.dirname(x));
3618
+ var pkg = loadpkg(path$4.dirname(x));
3265
3619
 
3266
3620
  if (pkg && pkg.dir && pkg.pkg && opts.pathFilter) {
3267
- var rfile = path$3.relative(pkg.dir, x);
3621
+ var rfile = path$4.relative(pkg.dir, x);
3268
3622
  var r = opts.pathFilter(pkg.pkg, x, rfile);
3269
3623
  if (r) {
3270
- x = path$3.resolve(pkg.dir, r); // eslint-disable-line no-param-reassign
3624
+ x = path$4.resolve(pkg.dir, r); // eslint-disable-line no-param-reassign
3271
3625
  }
3272
3626
  }
3273
3627
 
@@ -3290,17 +3644,13 @@ var sync$1 = function resolveSync(x, options) {
3290
3644
  }
3291
3645
  if ((/[/\\]node_modules[/\\]*$/).test(dir)) return;
3292
3646
 
3293
- var pkgfile = path$3.join(maybeRealpathSync(realpathSync, dir, opts), 'package.json');
3647
+ var pkgfile = path$4.join(maybeRealpathSync(realpathSync, dir, opts), 'package.json');
3294
3648
 
3295
3649
  if (!isFile(pkgfile)) {
3296
- return loadpkg(path$3.dirname(dir));
3650
+ return loadpkg(path$4.dirname(dir));
3297
3651
  }
3298
3652
 
3299
- var body = readFileSync(pkgfile);
3300
-
3301
- try {
3302
- var pkg = JSON.parse(body);
3303
- } catch (jsonErr) {}
3653
+ var pkg = readPackageSync(readFileSync, pkgfile);
3304
3654
 
3305
3655
  if (pkg && opts.packageFilter) {
3306
3656
  // v2 will pass pkgfile
@@ -3311,11 +3661,10 @@ var sync$1 = function resolveSync(x, options) {
3311
3661
  }
3312
3662
 
3313
3663
  function loadAsDirectorySync(x) {
3314
- var pkgfile = path$3.join(maybeRealpathSync(realpathSync, x, opts), '/package.json');
3664
+ var pkgfile = path$4.join(maybeRealpathSync(realpathSync, x, opts), '/package.json');
3315
3665
  if (isFile(pkgfile)) {
3316
3666
  try {
3317
- var body = readFileSync(pkgfile, 'UTF8');
3318
- var pkg = JSON.parse(body);
3667
+ var pkg = readPackageSync(readFileSync, pkgfile);
3319
3668
  } catch (e) {}
3320
3669
 
3321
3670
  if (pkg && opts.packageFilter) {
@@ -3333,15 +3682,15 @@ var sync$1 = function resolveSync(x, options) {
3333
3682
  pkg.main = 'index';
3334
3683
  }
3335
3684
  try {
3336
- var m = loadAsFileSync(path$3.resolve(x, pkg.main));
3685
+ var m = loadAsFileSync(path$4.resolve(x, pkg.main));
3337
3686
  if (m) return m;
3338
- var n = loadAsDirectorySync(path$3.resolve(x, pkg.main));
3687
+ var n = loadAsDirectorySync(path$4.resolve(x, pkg.main));
3339
3688
  if (n) return n;
3340
3689
  } catch (e) {}
3341
3690
  }
3342
3691
  }
3343
3692
 
3344
- return loadAsFileSync(path$3.join(x, '/index'));
3693
+ return loadAsFileSync(path$4.join(x, '/index'));
3345
3694
  }
3346
3695
 
3347
3696
  function loadNodeModulesSync(x, start) {
@@ -3350,7 +3699,7 @@ var sync$1 = function resolveSync(x, options) {
3350
3699
 
3351
3700
  for (var i = 0; i < dirs.length; i++) {
3352
3701
  var dir = dirs[i];
3353
- if (isDirectory(path$3.dirname(dir))) {
3702
+ if (isDirectory(path$4.dirname(dir))) {
3354
3703
  var m = loadAsFileSync(dir);
3355
3704
  if (m) return m;
3356
3705
  var n = loadAsDirectorySync(dir);
@@ -3477,7 +3826,7 @@ const createCustomResolverAsync = (sys, inMemoryFs, exts) => {
3477
3826
  };
3478
3827
 
3479
3828
  // MODULE: version.js
3480
- const buildId = '20210322175239';
3829
+ const buildId = '20210602143345';
3481
3830
  const minfyJsId = 'terser5.6.1_7';
3482
3831
  const optimizeCssId = 'autoprefixer10.2.5_postcss8.2.8_7';
3483
3832
  const parse5Version = '6.0.1';
@@ -3485,8 +3834,8 @@ const rollupVersion = '2.42.3';
3485
3834
  const sizzleVersion = '2.42.3';
3486
3835
  const terserVersion = '5.6.1';
3487
3836
  const typescriptVersion = '4.2.3';
3488
- const vermoji = '🎠';
3489
- const version$3 = '2.5.0';
3837
+ const vermoji = '📟';
3838
+ const version$3 = '2.6.0';
3490
3839
  const versions = {
3491
3840
  stencil: version$3,
3492
3841
  parse5: parse5Version,
@@ -10936,7 +11285,7 @@ const getCssToEsmImports = (varNames, cssText, filePath, modeName) => {
10936
11285
  return cssImports;
10937
11286
  }
10938
11287
  cssText = stripCssComments(cssText);
10939
- const dir = path$4.dirname(filePath);
11288
+ const dir = path$5.dirname(filePath);
10940
11289
  let r;
10941
11290
  while ((r = CSS_IMPORT_RE.exec(cssText))) {
10942
11291
  const cssImportData = {
@@ -10953,13 +11302,13 @@ const getCssToEsmImports = (varNames, cssText, filePath, modeName) => {
10953
11302
  // do not resolve this path cuz it starts with node resolve id ~
10954
11303
  continue;
10955
11304
  }
10956
- else if (path$4.isAbsolute(cssImportData.url)) {
11305
+ else if (path$5.isAbsolute(cssImportData.url)) {
10957
11306
  // absolute path already
10958
11307
  cssImportData.filePath = normalizePath$1(cssImportData.url);
10959
11308
  }
10960
11309
  else {
10961
11310
  // relative path
10962
- cssImportData.filePath = normalizePath$1(path$4.resolve(dir, cssImportData.url));
11311
+ cssImportData.filePath = normalizePath$1(path$5.resolve(dir, cssImportData.url));
10963
11312
  }
10964
11313
  cssImportData.varName = createCssVarName(cssImportData.filePath, modeName);
10965
11314
  if (varNames.has(cssImportData.varName)) {
@@ -10987,7 +11336,7 @@ const isLocalCssImport$1 = (srcImport) => {
10987
11336
  return true;
10988
11337
  };
10989
11338
  const createCssVarName = (filePath, modeName) => {
10990
- let varName = path$4.basename(filePath);
11339
+ let varName = path$5.basename(filePath);
10991
11340
  if (modeName && modeName !== DEFAULT_STYLE_MODE && !varName.includes(modeName)) {
10992
11341
  varName = modeName + '-' + varName;
10993
11342
  }
@@ -11715,7 +12064,7 @@ minimatch$1.Minimatch = Minimatch$2;
11715
12064
 
11716
12065
  var path$1 = { sep: '/' };
11717
12066
  try {
11718
- path$1 = path$3;
12067
+ path$1 = path$4;
11719
12068
  } catch (er) {}
11720
12069
 
11721
12070
  var GLOBSTAR$1 = minimatch$1.GLOBSTAR = Minimatch$2.GLOBSTAR = {};
@@ -18898,7 +19247,7 @@ if (typeof Object.create === 'function') {
18898
19247
  });
18899
19248
 
18900
19249
  // MODULE: ..//Users/adam/git/stencil/build/compiler/sys/modules/util.js?commonjs-proxy
18901
- const require$$0 = /*@__PURE__*/getAugmentedNamespace$1(util$3);
19250
+ const require$$0 = /*@__PURE__*/getAugmentedNamespace$1(util$4);
18902
19251
 
18903
19252
  // MODULE: ../node_modules/inherits/inherits.js
18904
19253
 
@@ -41009,7 +41358,7 @@ var constants = {
41009
41358
  CHAR_VERTICAL_LINE: 124, /* | */
41010
41359
  CHAR_ZERO_WIDTH_NOBREAK_SPACE: 65279, /* \uFEFF */
41011
41360
 
41012
- SEP: path$4.sep,
41361
+ SEP: path$5.sep,
41013
41362
 
41014
41363
  /**
41015
41364
  * Create EXTGLOB_CHARS
@@ -41069,7 +41418,7 @@ exports.isWindows = options => {
41069
41418
  if (options && typeof options.windows === 'boolean') {
41070
41419
  return options.windows;
41071
41420
  }
41072
- return win32 === true || path$4.sep === '\\';
41421
+ return win32 === true || path$5.sep === '\\';
41073
41422
  };
41074
41423
 
41075
41424
  exports.escapeLast = (input, char, lastIdx) => {
@@ -42710,7 +43059,7 @@ picomatch$1.test = (input, regex, options, { glob, posix } = {}) => {
42710
43059
 
42711
43060
  picomatch$1.matchBase = (input, glob, options, posix = utils.isWindows(options)) => {
42712
43061
  const regex = glob instanceof RegExp ? glob : picomatch$1.makeRe(glob, options);
42713
- return regex.test(path$4.basename(input));
43062
+ return regex.test(path$5.basename(input));
42714
43063
  };
42715
43064
 
42716
43065
  /**
@@ -43231,7 +43580,7 @@ const makeLegalIdentifier$2 = function makeLegalIdentifier(str) {
43231
43580
  var commondir = function (basedir, relfiles) {
43232
43581
  if (relfiles) {
43233
43582
  var files = relfiles.map(function (r) {
43234
- return path$4.resolve(basedir, r);
43583
+ return path$5.resolve(basedir, r);
43235
43584
  });
43236
43585
  }
43237
43586
  else {
@@ -43256,18 +43605,42 @@ var commondir = function (basedir, relfiles) {
43256
43605
  return res.length > 1 ? res.join('/') : '/'
43257
43606
  };
43258
43607
 
43259
- class WalkerBase$1 {constructor() { WalkerBase$1.prototype.__init.call(this);WalkerBase$1.prototype.__init2.call(this);WalkerBase$1.prototype.__init3.call(this);WalkerBase$1.prototype.__init4.call(this); }
43260
- __init() {this.should_skip = false;}
43261
- __init2() {this.should_remove = false;}
43262
- __init3() {this.replacement = null;}
43608
+ // @ts-check
43609
+ /** @typedef { import('estree').BaseNode} BaseNode */
43263
43610
 
43264
- __init4() {this.context = {
43265
- skip: () => (this.should_skip = true),
43266
- remove: () => (this.should_remove = true),
43267
- replace: (node) => (this.replacement = node)
43268
- };}
43611
+ /** @typedef {{
43612
+ skip: () => void;
43613
+ remove: () => void;
43614
+ replace: (node: BaseNode) => void;
43615
+ }} WalkerContext */
43269
43616
 
43270
- replace(parent, prop, index, node) {
43617
+ class WalkerBase$1 {
43618
+ constructor() {
43619
+ /** @type {boolean} */
43620
+ this.should_skip = false;
43621
+
43622
+ /** @type {boolean} */
43623
+ this.should_remove = false;
43624
+
43625
+ /** @type {BaseNode | null} */
43626
+ this.replacement = null;
43627
+
43628
+ /** @type {WalkerContext} */
43629
+ this.context = {
43630
+ skip: () => (this.should_skip = true),
43631
+ remove: () => (this.should_remove = true),
43632
+ replace: (node) => (this.replacement = node)
43633
+ };
43634
+ }
43635
+
43636
+ /**
43637
+ *
43638
+ * @param {any} parent
43639
+ * @param {string} prop
43640
+ * @param {number} index
43641
+ * @param {BaseNode} node
43642
+ */
43643
+ replace(parent, prop, index, node) {
43271
43644
  if (parent) {
43272
43645
  if (index !== null) {
43273
43646
  parent[prop][index] = node;
@@ -43277,7 +43650,13 @@ class WalkerBase$1 {constructor() { WalkerBase$1.prototype.__init.call(this);Wal
43277
43650
  }
43278
43651
  }
43279
43652
 
43280
- remove(parent, prop, index) {
43653
+ /**
43654
+ *
43655
+ * @param {any} parent
43656
+ * @param {string} prop
43657
+ * @param {number} index
43658
+ */
43659
+ remove(parent, prop, index) {
43281
43660
  if (parent) {
43282
43661
  if (index !== null) {
43283
43662
  parent[prop].splice(index, 1);
@@ -43288,26 +43667,46 @@ class WalkerBase$1 {constructor() { WalkerBase$1.prototype.__init.call(this);Wal
43288
43667
  }
43289
43668
  }
43290
43669
 
43291
- class SyncWalkerClass$1 extends WalkerBase$1 {
43292
-
43293
-
43670
+ // @ts-check
43294
43671
 
43295
- constructor(walker) {
43672
+ /** @typedef { import('estree').BaseNode} BaseNode */
43673
+ /** @typedef { import('./walker.js').WalkerContext} WalkerContext */
43674
+
43675
+ /** @typedef {(
43676
+ * this: WalkerContext,
43677
+ * node: BaseNode,
43678
+ * parent: BaseNode,
43679
+ * key: string,
43680
+ * index: number
43681
+ * ) => void} SyncHandler */
43682
+
43683
+ class SyncWalker extends WalkerBase$1 {
43684
+ /**
43685
+ *
43686
+ * @param {SyncHandler} enter
43687
+ * @param {SyncHandler} leave
43688
+ */
43689
+ constructor(enter, leave) {
43296
43690
  super();
43297
- this.enter = walker.enter;
43298
- this.leave = walker.leave;
43691
+
43692
+ /** @type {SyncHandler} */
43693
+ this.enter = enter;
43694
+
43695
+ /** @type {SyncHandler} */
43696
+ this.leave = leave;
43299
43697
  }
43300
43698
 
43301
- visit(
43302
- node,
43303
- parent,
43304
- enter,
43305
- leave,
43306
- prop,
43307
- index
43308
- ) {
43699
+ /**
43700
+ *
43701
+ * @param {BaseNode} node
43702
+ * @param {BaseNode} parent
43703
+ * @param {string} [prop]
43704
+ * @param {number} [index]
43705
+ * @returns {BaseNode}
43706
+ */
43707
+ visit(node, parent, prop, index) {
43309
43708
  if (node) {
43310
- if (enter) {
43709
+ if (this.enter) {
43311
43710
  const _should_skip = this.should_skip;
43312
43711
  const _should_remove = this.should_remove;
43313
43712
  const _replacement = this.replacement;
@@ -43315,7 +43714,7 @@ class SyncWalkerClass$1 extends WalkerBase$1 {
43315
43714
  this.should_remove = false;
43316
43715
  this.replacement = null;
43317
43716
 
43318
- enter.call(this.context, node, parent, prop, index);
43717
+ this.enter.call(this.context, node, parent, prop, index);
43319
43718
 
43320
43719
  if (this.replacement) {
43321
43720
  node = this.replacement;
@@ -43338,31 +43737,31 @@ class SyncWalkerClass$1 extends WalkerBase$1 {
43338
43737
  }
43339
43738
 
43340
43739
  for (const key in node) {
43341
- const value = (node )[key];
43740
+ const value = node[key];
43342
43741
 
43343
43742
  if (typeof value !== "object") {
43344
43743
  continue;
43345
43744
  } else if (Array.isArray(value)) {
43346
43745
  for (let i = 0; i < value.length; i += 1) {
43347
43746
  if (value[i] !== null && typeof value[i].type === 'string') {
43348
- if (!this.visit(value[i], node, enter, leave, key, i)) {
43747
+ if (!this.visit(value[i], node, key, i)) {
43349
43748
  // removed
43350
43749
  i--;
43351
43750
  }
43352
43751
  }
43353
43752
  }
43354
43753
  } else if (value !== null && typeof value.type === "string") {
43355
- this.visit(value, node, enter, leave, key, null);
43754
+ this.visit(value, node, key, null);
43356
43755
  }
43357
43756
  }
43358
43757
 
43359
- if (leave) {
43758
+ if (this.leave) {
43360
43759
  const _replacement = this.replacement;
43361
43760
  const _should_remove = this.should_remove;
43362
43761
  this.replacement = null;
43363
43762
  this.should_remove = false;
43364
43763
 
43365
- leave.call(this.context, node, parent, prop, index);
43764
+ this.leave.call(this.context, node, parent, prop, index);
43366
43765
 
43367
43766
  if (this.replacement) {
43368
43767
  node = this.replacement;
@@ -43386,9 +43785,24 @@ class SyncWalkerClass$1 extends WalkerBase$1 {
43386
43785
  }
43387
43786
  }
43388
43787
 
43389
- function walk$1(ast, walker) {
43390
- const instance = new SyncWalkerClass$1(walker);
43391
- return instance.visit(ast, null, walker.enter, walker.leave);
43788
+ // @ts-check
43789
+
43790
+ /** @typedef { import('estree').BaseNode} BaseNode */
43791
+ /** @typedef { import('./sync.js').SyncHandler} SyncHandler */
43792
+ /** @typedef { import('./async.js').AsyncHandler} AsyncHandler */
43793
+
43794
+ /**
43795
+ *
43796
+ * @param {BaseNode} ast
43797
+ * @param {{
43798
+ * enter?: SyncHandler
43799
+ * leave?: SyncHandler
43800
+ * }} walker
43801
+ * @returns {BaseNode}
43802
+ */
43803
+ function walk$1(ast, { enter, leave }) {
43804
+ const instance = new SyncWalker(enter, leave);
43805
+ return instance.visit(ast, null);
43392
43806
  }
43393
43807
 
43394
43808
  var chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=';
@@ -44558,7 +44972,7 @@ if (isWindows) {
44558
44972
 
44559
44973
  var realpathSync$1 = function realpathSync(p, cache) {
44560
44974
  // make p is absolute
44561
- p = path$4.resolve(p);
44975
+ p = path$5.resolve(p);
44562
44976
 
44563
44977
  if (cache && Object.prototype.hasOwnProperty.call(cache, p)) {
44564
44978
  return cache[p];
@@ -44589,7 +45003,7 @@ var realpathSync$1 = function realpathSync(p, cache) {
44589
45003
 
44590
45004
  // On windows, check that the root exists. On unix there is no need.
44591
45005
  if (isWindows && !knownHard[base]) {
44592
- fs$2.lstatSync(base);
45006
+ fs$3.lstatSync(base);
44593
45007
  knownHard[base] = true;
44594
45008
  }
44595
45009
  }
@@ -44616,7 +45030,7 @@ var realpathSync$1 = function realpathSync(p, cache) {
44616
45030
  // some known symbolic link. no need to stat again.
44617
45031
  resolvedLink = cache[base];
44618
45032
  } else {
44619
- var stat = fs$2.lstatSync(base);
45033
+ var stat = fs$3.lstatSync(base);
44620
45034
  if (!stat.isSymbolicLink()) {
44621
45035
  knownHard[base] = true;
44622
45036
  if (cache) cache[base] = base;
@@ -44633,17 +45047,17 @@ var realpathSync$1 = function realpathSync(p, cache) {
44633
45047
  }
44634
45048
  }
44635
45049
  if (linkTarget === null) {
44636
- fs$2.statSync(base);
44637
- linkTarget = fs$2.readlinkSync(base);
45050
+ fs$3.statSync(base);
45051
+ linkTarget = fs$3.readlinkSync(base);
44638
45052
  }
44639
- resolvedLink = path$4.resolve(previous, linkTarget);
45053
+ resolvedLink = path$5.resolve(previous, linkTarget);
44640
45054
  // track this, if given a cache.
44641
45055
  if (cache) cache[base] = resolvedLink;
44642
45056
  if (!isWindows) seenLinks[id] = linkTarget;
44643
45057
  }
44644
45058
 
44645
45059
  // resolve the link, then start over
44646
- p = path$4.resolve(resolvedLink, p.slice(pos));
45060
+ p = path$5.resolve(resolvedLink, p.slice(pos));
44647
45061
  start();
44648
45062
  }
44649
45063
 
@@ -44660,7 +45074,7 @@ var realpath$2 = function realpath(p, cache, cb) {
44660
45074
  }
44661
45075
 
44662
45076
  // make p is absolute
44663
- p = path$4.resolve(p);
45077
+ p = path$5.resolve(p);
44664
45078
 
44665
45079
  if (cache && Object.prototype.hasOwnProperty.call(cache, p)) {
44666
45080
  return process.nextTick(cb.bind(null, null, cache[p]));
@@ -44691,7 +45105,7 @@ var realpath$2 = function realpath(p, cache, cb) {
44691
45105
 
44692
45106
  // On windows, check that the root exists. On unix there is no need.
44693
45107
  if (isWindows && !knownHard[base]) {
44694
- fs$2.lstat(base, function(err) {
45108
+ fs$3.lstat(base, function(err) {
44695
45109
  if (err) return cb(err);
44696
45110
  knownHard[base] = true;
44697
45111
  LOOP();
@@ -44728,7 +45142,7 @@ var realpath$2 = function realpath(p, cache, cb) {
44728
45142
  return gotResolvedLink(cache[base]);
44729
45143
  }
44730
45144
 
44731
- return fs$2.lstat(base, gotStat);
45145
+ return fs$3.lstat(base, gotStat);
44732
45146
  }
44733
45147
 
44734
45148
  function gotStat(err, stat) {
@@ -44750,10 +45164,10 @@ var realpath$2 = function realpath(p, cache, cb) {
44750
45164
  return gotTarget(null, seenLinks[id], base);
44751
45165
  }
44752
45166
  }
44753
- fs$2.stat(base, function(err) {
45167
+ fs$3.stat(base, function(err) {
44754
45168
  if (err) return cb(err);
44755
45169
 
44756
- fs$2.readlink(base, function(err, target) {
45170
+ fs$3.readlink(base, function(err, target) {
44757
45171
  if (!isWindows) seenLinks[id] = target;
44758
45172
  gotTarget(err, target);
44759
45173
  });
@@ -44763,14 +45177,14 @@ var realpath$2 = function realpath(p, cache, cb) {
44763
45177
  function gotTarget(err, target, base) {
44764
45178
  if (err) return cb(err);
44765
45179
 
44766
- var resolvedLink = path$4.resolve(previous, target);
45180
+ var resolvedLink = path$5.resolve(previous, target);
44767
45181
  if (cache) cache[base] = resolvedLink;
44768
45182
  gotResolvedLink(resolvedLink);
44769
45183
  }
44770
45184
 
44771
45185
  function gotResolvedLink(resolvedLink) {
44772
45186
  // resolve the link, then start over
44773
- p = path$4.resolve(resolvedLink, p.slice(pos));
45187
+ p = path$5.resolve(resolvedLink, p.slice(pos));
44774
45188
  start();
44775
45189
  }
44776
45190
  };
@@ -44788,8 +45202,8 @@ realpath$1.monkeypatch = monkeypatch;
44788
45202
  realpath$1.unmonkeypatch = unmonkeypatch;
44789
45203
 
44790
45204
 
44791
- var origRealpath = fs$2.realpath;
44792
- var origRealpathSync = fs$2.realpathSync;
45205
+ var origRealpath = fs$3.realpath;
45206
+ var origRealpathSync = fs$3.realpathSync;
44793
45207
 
44794
45208
  var version = process.version;
44795
45209
  var ok = /^v[0-5]\./.test(version);
@@ -44838,13 +45252,13 @@ function realpathSync (p, cache) {
44838
45252
  }
44839
45253
 
44840
45254
  function monkeypatch () {
44841
- fs$2.realpath = realpath$1;
44842
- fs$2.realpathSync = realpathSync;
45255
+ fs$3.realpath = realpath$1;
45256
+ fs$3.realpathSync = realpathSync;
44843
45257
  }
44844
45258
 
44845
45259
  function unmonkeypatch () {
44846
- fs$2.realpath = origRealpath;
44847
- fs$2.realpathSync = origRealpathSync;
45260
+ fs$3.realpath = origRealpath;
45261
+ fs$3.realpathSync = origRealpathSync;
44848
45262
  }
44849
45263
 
44850
45264
  var concatMap = function (xs, fn) {
@@ -45119,7 +45533,7 @@ minimatch.Minimatch = Minimatch$1;
45119
45533
 
45120
45534
  var path = { sep: '/' };
45121
45535
  try {
45122
- path = path$4;
45536
+ path = path$5;
45123
45537
  } catch (er) {}
45124
45538
 
45125
45539
  var GLOBSTAR = minimatch.GLOBSTAR = Minimatch$1.GLOBSTAR = {};
@@ -46509,30 +46923,51 @@ function unwrapListeners(arr) {
46509
46923
 
46510
46924
  function once$1(emitter, name) {
46511
46925
  return new Promise(function (resolve, reject) {
46512
- function eventListener() {
46513
- if (errorListener !== undefined) {
46926
+ function errorListener(err) {
46927
+ emitter.removeListener(name, resolver);
46928
+ reject(err);
46929
+ }
46930
+
46931
+ function resolver() {
46932
+ if (typeof emitter.removeListener === 'function') {
46514
46933
  emitter.removeListener('error', errorListener);
46515
46934
  }
46516
46935
  resolve([].slice.call(arguments));
46517
- } var errorListener;
46518
-
46519
- // Adding an error listener is not optional because
46520
- // if an error is thrown on an event emitter we cannot
46521
- // guarantee that the actual event we are waiting will
46522
- // be fired. The result could be a silent way to create
46523
- // memory or file descriptor leaks, which is something
46524
- // we should avoid.
46936
+ }
46937
+ eventTargetAgnosticAddListener(emitter, name, resolver, { once: true });
46525
46938
  if (name !== 'error') {
46526
- errorListener = function errorListener(err) {
46527
- emitter.removeListener(name, eventListener);
46528
- reject(err);
46529
- };
46939
+ addErrorHandlerIfEventEmitter(emitter, errorListener, { once: true });
46940
+ }
46941
+ });
46942
+ }
46530
46943
 
46531
- emitter.once('error', errorListener);
46944
+ function addErrorHandlerIfEventEmitter(emitter, handler, flags) {
46945
+ if (typeof emitter.on === 'function') {
46946
+ eventTargetAgnosticAddListener(emitter, 'error', handler, flags);
46532
46947
  }
46948
+ }
46533
46949
 
46534
- emitter.once(name, eventListener);
46950
+ function eventTargetAgnosticAddListener(emitter, name, listener, flags) {
46951
+ if (typeof emitter.on === 'function') {
46952
+ if (flags.once) {
46953
+ emitter.once(name, listener);
46954
+ } else {
46955
+ emitter.on(name, listener);
46956
+ }
46957
+ } else if (typeof emitter.addEventListener === 'function') {
46958
+ // EventTarget does not have `error` event semantics like Node
46959
+ // EventEmitters, we do not listen for `error` events here.
46960
+ emitter.addEventListener(name, function wrapListener(arg) {
46961
+ // IE does not have builtin `{ once: true }` support so we
46962
+ // have to do it manually.
46963
+ if (flags.once) {
46964
+ emitter.removeEventListener(name, wrapListener);
46965
+ }
46966
+ listener(arg);
46535
46967
  });
46968
+ } else {
46969
+ throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type ' + typeof emitter);
46970
+ }
46536
46971
  }
46537
46972
  events.once = once_1$1;
46538
46973
 
@@ -47843,12 +48278,12 @@ function setopts$2 (self, pattern, options) {
47843
48278
  if (!ownProp$2(options, "cwd"))
47844
48279
  self.cwd = cwd;
47845
48280
  else {
47846
- self.cwd = path$4.resolve(options.cwd);
48281
+ self.cwd = path$5.resolve(options.cwd);
47847
48282
  self.changedCwd = self.cwd !== cwd;
47848
48283
  }
47849
48284
 
47850
- self.root = options.root || path$4.resolve(self.cwd, "/");
47851
- self.root = path$4.resolve(self.root);
48285
+ self.root = options.root || path$5.resolve(self.cwd, "/");
48286
+ self.root = path$5.resolve(self.root);
47852
48287
  if (process.platform === "win32")
47853
48288
  self.root = self.root.replace(/\\/g, "/");
47854
48289
 
@@ -47952,13 +48387,13 @@ function mark (self, p) {
47952
48387
  function makeAbs (self, f) {
47953
48388
  var abs = f;
47954
48389
  if (f.charAt(0) === '/') {
47955
- abs = path$4.join(self.root, f);
48390
+ abs = path$5.join(self.root, f);
47956
48391
  } else if (pathIsAbsolute(f) || f === '') {
47957
48392
  abs = f;
47958
48393
  } else if (self.changedCwd) {
47959
- abs = path$4.resolve(self.cwd, f);
48394
+ abs = path$5.resolve(self.cwd, f);
47960
48395
  } else {
47961
- abs = path$4.resolve(f);
48396
+ abs = path$5.resolve(f);
47962
48397
  }
47963
48398
 
47964
48399
  if (process.platform === 'win32')
@@ -48175,7 +48610,7 @@ GlobSync$1.prototype._processReaddir = function (prefix, read, abs, remain, inde
48175
48610
  }
48176
48611
 
48177
48612
  if (e.charAt(0) === '/' && !this.nomount) {
48178
- e = path$4.join(this.root, e);
48613
+ e = path$5.join(this.root, e);
48179
48614
  }
48180
48615
  this._emitMatch(index, e);
48181
48616
  }
@@ -48236,7 +48671,7 @@ GlobSync$1.prototype._readdirInGlobStar = function (abs) {
48236
48671
  var entries;
48237
48672
  var lstat;
48238
48673
  try {
48239
- lstat = fs$2.lstatSync(abs);
48674
+ lstat = fs$3.lstatSync(abs);
48240
48675
  } catch (er) {
48241
48676
  if (er.code === 'ENOENT') {
48242
48677
  // lstat failed, doesn't exist
@@ -48272,7 +48707,7 @@ GlobSync$1.prototype._readdir = function (abs, inGlobStar) {
48272
48707
  }
48273
48708
 
48274
48709
  try {
48275
- return this._readdirEntries(abs, fs$2.readdirSync(abs))
48710
+ return this._readdirEntries(abs, fs$3.readdirSync(abs))
48276
48711
  } catch (er) {
48277
48712
  this._readdirError(abs, er);
48278
48713
  return null
@@ -48386,9 +48821,9 @@ GlobSync$1.prototype._processSimple = function (prefix, index) {
48386
48821
  if (prefix && pathIsAbsolute(prefix) && !this.nomount) {
48387
48822
  var trail = /[\/\\]$/.test(prefix);
48388
48823
  if (prefix.charAt(0) === '/') {
48389
- prefix = path$4.join(this.root, prefix);
48824
+ prefix = path$5.join(this.root, prefix);
48390
48825
  } else {
48391
- prefix = path$4.resolve(this.root, prefix);
48826
+ prefix = path$5.resolve(this.root, prefix);
48392
48827
  if (trail)
48393
48828
  prefix += '/';
48394
48829
  }
@@ -48429,7 +48864,7 @@ GlobSync$1.prototype._stat = function (f) {
48429
48864
  if (!stat) {
48430
48865
  var lstat;
48431
48866
  try {
48432
- lstat = fs$2.lstatSync(abs);
48867
+ lstat = fs$3.lstatSync(abs);
48433
48868
  } catch (er) {
48434
48869
  if (er && (er.code === 'ENOENT' || er.code === 'ENOTDIR')) {
48435
48870
  this.statCache[abs] = false;
@@ -48439,7 +48874,7 @@ GlobSync$1.prototype._stat = function (f) {
48439
48874
 
48440
48875
  if (lstat && lstat.isSymbolicLink()) {
48441
48876
  try {
48442
- stat = fs$2.statSync(abs);
48877
+ stat = fs$3.statSync(abs);
48443
48878
  } catch (er) {
48444
48879
  stat = lstat;
48445
48880
  }
@@ -49017,7 +49452,7 @@ Glob.prototype._processReaddir2 = function (prefix, read, abs, remain, index, in
49017
49452
  }
49018
49453
 
49019
49454
  if (e.charAt(0) === '/' && !this.nomount) {
49020
- e = path$4.join(this.root, e);
49455
+ e = path$5.join(this.root, e);
49021
49456
  }
49022
49457
  this._emitMatch(index, e);
49023
49458
  }
@@ -49093,7 +49528,7 @@ Glob.prototype._readdirInGlobStar = function (abs, cb) {
49093
49528
  var lstatcb = inflight_1(lstatkey, lstatcb_);
49094
49529
 
49095
49530
  if (lstatcb)
49096
- fs$2.lstat(abs, lstatcb);
49531
+ fs$3.lstat(abs, lstatcb);
49097
49532
 
49098
49533
  function lstatcb_ (er, lstat) {
49099
49534
  if (er && er.code === 'ENOENT')
@@ -49132,7 +49567,7 @@ Glob.prototype._readdir = function (abs, inGlobStar, cb) {
49132
49567
  if (Array.isArray(c))
49133
49568
  return cb(null, c)
49134
49569
  }
49135
- fs$2.readdir(abs, readdirCb(this, abs, cb));
49570
+ fs$3.readdir(abs, readdirCb(this, abs, cb));
49136
49571
  };
49137
49572
 
49138
49573
  function readdirCb (self, abs, cb) {
@@ -49278,9 +49713,9 @@ Glob.prototype._processSimple2 = function (prefix, index, er, exists, cb) {
49278
49713
  if (prefix && pathIsAbsolute(prefix) && !this.nomount) {
49279
49714
  var trail = /[\/\\]$/.test(prefix);
49280
49715
  if (prefix.charAt(0) === '/') {
49281
- prefix = path$4.join(this.root, prefix);
49716
+ prefix = path$5.join(this.root, prefix);
49282
49717
  } else {
49283
- prefix = path$4.resolve(this.root, prefix);
49718
+ prefix = path$5.resolve(this.root, prefix);
49284
49719
  if (trail)
49285
49720
  prefix += '/';
49286
49721
  }
@@ -49334,13 +49769,13 @@ Glob.prototype._stat = function (f, cb) {
49334
49769
  var self = this;
49335
49770
  var statcb = inflight_1('stat\0' + abs, lstatcb_);
49336
49771
  if (statcb)
49337
- fs$2.lstat(abs, statcb);
49772
+ fs$3.lstat(abs, statcb);
49338
49773
 
49339
49774
  function lstatcb_ (er, lstat) {
49340
49775
  if (lstat && lstat.isSymbolicLink()) {
49341
49776
  // If it's a symlink, then treat it as the target, unless
49342
49777
  // the target does not exist, then treat it as a file.
49343
- return fs$2.stat(abs, function (er, stat) {
49778
+ return fs$3.stat(abs, function (er, stat) {
49344
49779
  if (er)
49345
49780
  self._stat2(f, abs, null, lstat, cb);
49346
49781
  else
@@ -49674,8 +50109,8 @@ function getName(id) {
49674
50109
  const reserved = 'process location abstract arguments boolean break byte case catch char class const continue debugger default delete do double else enum eval export extends false final finally float for from function goto if implements import in instanceof int interface let long native new null package private protected public return short static super switch synchronized this throw throws transient true try typeof var void volatile while with yield'.split(
49675
50110
  ' '
49676
50111
  );
49677
- const blacklist$1 = { __esModule: true };
49678
- reserved.forEach((word) => (blacklist$1[word] = true));
50112
+ const blacklist = { __esModule: true };
50113
+ reserved.forEach((word) => (blacklist[word] = true));
49679
50114
 
49680
50115
  const exportsPattern = /^(?:module\.)?exports(?:\.([a-zA-Z_$][a-zA-Z_$0-9]*))?$/;
49681
50116
 
@@ -49687,7 +50122,7 @@ function deconflict(scope, globals, identifier) {
49687
50122
  let i = 1;
49688
50123
  let deconflicted = makeLegalIdentifier$2(identifier);
49689
50124
 
49690
- while (scope.contains(deconflicted) || globals.has(deconflicted) || deconflicted in blacklist$1) {
50125
+ while (scope.contains(deconflicted) || globals.has(deconflicted) || deconflicted in blacklist) {
49691
50126
  deconflicted = `${identifier}_${i}`;
49692
50127
  i += 1;
49693
50128
  }
@@ -50954,13 +51389,13 @@ function json(options) {
50954
51389
 
50955
51390
  const {builtinModules} = Module;
50956
51391
 
50957
- const blacklist = [
51392
+ const ignoreList = [
50958
51393
  'sys'
50959
51394
  ];
50960
51395
 
50961
51396
  // eslint-disable-next-line node/no-deprecated-api
50962
51397
  var builtinModules_1 = (builtinModules)
50963
- .filter(x => !/^_|^(internal|v8|node-inspect)\/|\//.test(x) && !blacklist.includes(x))
51398
+ .filter(x => !/^_|^(internal|v8|node-inspect)\/|\//.test(x) && !ignoreList.includes(x))
50964
51399
  .sort();
50965
51400
 
50966
51401
  var isMergeableObject = function isMergeableObject(value) {
@@ -51174,10 +51609,10 @@ const builtins$3 = 'arguments Infinity NaN undefined null true false eval uneval
51174
51609
  const forbiddenIdentifiers$2 = new Set(`${reservedWords$2} ${builtins$3}`.split(' '));
51175
51610
  forbiddenIdentifiers$2.add('');
51176
51611
 
51177
- const exists = promisify(fs$2.exists);
51178
- const readFile = promisify(fs$2.readFile);
51179
- const realpath = promisify(fs$2.realpath);
51180
- const stat = promisify(fs$2.stat);
51612
+ const exists = promisify(fs$3.exists);
51613
+ const readFile = promisify(fs$3.readFile);
51614
+ const realpath = promisify(fs$3.realpath);
51615
+ const stat = promisify(fs$3.stat);
51181
51616
 
51182
51617
  const onError = (error) => {
51183
51618
  if (error.code === 'ENOENT') {
@@ -52550,24 +52985,38 @@ const buildWorker = async (config, compilerCtx, buildCtx, ctx, workerEntryPath)
52550
52985
  };
52551
52986
  const WORKER_SUFFIX = ['.worker.ts', '.worker.tsx', '.worker/index.ts', '.worker/index.tsx'];
52552
52987
  const WORKER_HELPER_ID = '@worker-helper';
52553
- const getWorkerIntro = (workerMsgId, isDev) => `
52554
- const exports = {};
52555
- const workerMsgId = '${workerMsgId}';
52556
- const workerMsgCallbackId = workerMsgId + '.cb';
52988
+ const GET_TRANSFERABLES = `
52989
+ const isInstanceOf = (value, className) => {
52990
+ const C = globalThis[className];
52991
+ return C != null && value instanceof C;
52992
+ }
52557
52993
  const getTransferables = (value) => {
52558
- if (!!value) {
52559
- if (value instanceof ArrayBuffer) {
52994
+ if (value != null) {
52995
+ if (
52996
+ isInstanceOf(value, "ArrayBuffer") ||
52997
+ isInstanceOf(value, "MessagePort") ||
52998
+ isInstanceOf(value, "ImageBitmap") ||
52999
+ isInstanceOf(value, "OffscreenCanvas")
53000
+ ) {
52560
53001
  return [value];
52561
53002
  }
52562
- if (value.constructor === Object) {
52563
- return [].concat(...Object.keys(value).map(k => getTransferables(value[k])))
52564
- }
52565
- if (typeof value === 'object') {
53003
+ if (typeof value === "object") {
53004
+ if (value.constructor === Object) {
53005
+ value = Object.values(value);
53006
+ }
53007
+ if (Array.isArray(value)) {
53008
+ return value.flatMap(getTransferables);
53009
+ }
52566
53010
  return getTransferables(value.buffer);
52567
53011
  }
52568
53012
  }
52569
53013
  return [];
52570
- };
53014
+ };`;
53015
+ const getWorkerIntro = (workerMsgId, isDev) => `
53016
+ ${GET_TRANSFERABLES}
53017
+ const exports = {};
53018
+ const workerMsgId = '${workerMsgId}';
53019
+ const workerMsgCallbackId = workerMsgId + '.cb';
52571
53020
  addEventListener('message', async ({data}) => {
52572
53021
  if (data && data[0] === workerMsgId) {
52573
53022
  let id = data[1];
@@ -52633,6 +53082,8 @@ addEventListener('message', async ({data}) => {
52633
53082
  const WORKER_HELPERS = `
52634
53083
  import { consoleError } from '${STENCIL_INTERNAL_ID}';
52635
53084
 
53085
+ ${GET_TRANSFERABLES}
53086
+
52636
53087
  let pendingIds = 0;
52637
53088
  let callbackIds = 0;
52638
53089
  const pending = new Map();
@@ -52697,7 +53148,7 @@ export const createWorkerProxy = (worker, workerMsgId, exportedMethod) => (
52697
53148
  const postMessage = (w) => (
52698
53149
  w.postMessage(
52699
53150
  [workerMsgId, pendingId, exportedMethod, args],
52700
- args.filter(a => a instanceof ArrayBuffer)
53151
+ getTransferables(args)
52701
53152
  )
52702
53153
  );
52703
53154
  if (worker.then) {
@@ -52737,7 +53188,7 @@ const getMockedWorkerMain = () => {
52737
53188
  export const workerName = 'mocked-worker';
52738
53189
  export const workerMsgId = workerName;
52739
53190
  export const workerPath = workerName;
52740
- export const worker = { name: workerName };
53191
+ export const worker = { name: workerName };
52741
53192
  `;
52742
53193
  };
52743
53194
  const getWorkerProxy = (workerEntryPath, exportedMethods) => {
@@ -54096,6 +54547,7 @@ const KEEP_IMPORTS = new Set([
54096
54547
  'h',
54097
54548
  'setMode',
54098
54549
  'getMode',
54550
+ 'setPlatformHelpers',
54099
54551
  'Build',
54100
54552
  'Env',
54101
54553
  'Host',
@@ -61705,7 +62157,7 @@ const getConfig = (userConfig) => {
61705
62157
 
61706
62158
  // MODULE: compiler/sys/fs-patch.js
61707
62159
  const patchFs = (userSys) => {
61708
- const fsObj = fs$2;
62160
+ const fsObj = fs$3;
61709
62161
  Object.assign(fsObj.__sys, userSys);
61710
62162
  };
61711
62163
 
@@ -61776,7 +62228,7 @@ const getWriteFilePathFromUrlPath = (manager, inputHref) => {
61776
62228
  const isPrerrenderRoot = basePathname === inputPathname;
61777
62229
  let fileName;
61778
62230
  if (isPrerrenderRoot) {
61779
- fileName = path$4.basename(manager.outputTarget.indexHtml);
62231
+ fileName = path$5.basename(manager.outputTarget.indexHtml);
61780
62232
  }
61781
62233
  else {
61782
62234
  fileName = 'index.html';
@@ -61799,7 +62251,7 @@ const getWriteFilePathFromUrlPath = (manager, inputHref) => {
61799
62251
  }
61800
62252
  pathParts.push(fileName);
61801
62253
  // figure out the directory where this file will be saved
61802
- return path$4.join(manager.outputTarget.appDir, ...pathParts);
62254
+ return path$5.join(manager.outputTarget.appDir, ...pathParts);
61803
62255
  };
61804
62256
 
61805
62257
  // MODULE: compiler/prerender/prerender-queue.js
@@ -62398,7 +62850,7 @@ const getComponentPathContent = (componentGraph, outputTarget) => {
62398
62850
  const dependencies = [
62399
62851
  {
62400
62852
  name: "@stencil/core",
62401
- version: "2.5.0",
62853
+ version: "2.6.0",
62402
62854
  main: "compiler/stencil.js",
62403
62855
  resources: [
62404
62856
  "package.json",
@@ -64458,7 +64910,7 @@ exports.loadConfig = loadConfig;
64458
64910
  exports.nodeRequire = nodeRequire;
64459
64911
  exports.optimizeCss = optimizeCss$1;
64460
64912
  exports.optimizeJs = optimizeJs;
64461
- exports.path = path$4;
64913
+ exports.path = path$5;
64462
64914
  exports.transpile = transpile;
64463
64915
  exports.transpileSync = transpileSync;
64464
64916
  exports.ts = t;