@biggive/components 202609151306.0.0 → 202609171342.0.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 (174) hide show
  1. package/dist/biggive/biggive.esm.js +1 -1
  2. package/dist/biggive/{p-f1324c49.entry.js → p-01e245e6.entry.js} +1 -1
  3. package/dist/biggive/{p-3197ba6a.entry.js → p-0c3dd528.entry.js} +1 -1
  4. package/dist/biggive/{p-457e7161.entry.js → p-1fa05de0.entry.js} +1 -1
  5. package/dist/biggive/{p-aff122fa.entry.js → p-1fea7be4.entry.js} +1 -1
  6. package/dist/biggive/{p-c1c9b6a0.entry.js → p-2211bc73.entry.js} +1 -1
  7. package/dist/biggive/{p-b22ad681.entry.js → p-23840cdd.entry.js} +1 -1
  8. package/dist/biggive/{p-7fc50b70.entry.js → p-295d5b54.entry.js} +1 -1
  9. package/dist/biggive/{p-41720b30.entry.js → p-2acf2b34.entry.js} +1 -1
  10. package/dist/biggive/{p-f031945c.entry.js → p-2f773874.entry.js} +1 -1
  11. package/dist/biggive/{p-d96fd8bb.entry.js → p-38dbb8c5.entry.js} +1 -1
  12. package/dist/biggive/{p-e0174caf.entry.js → p-3bc183b3.entry.js} +1 -1
  13. package/dist/biggive/{p-43d962a9.entry.js → p-40f20fdb.entry.js} +1 -1
  14. package/dist/biggive/{p-0f1b0135.entry.js → p-42ccddeb.entry.js} +1 -1
  15. package/dist/biggive/{p-7e736f90.entry.js → p-43a82f03.entry.js} +1 -1
  16. package/dist/biggive/{p-99b388f2.entry.js → p-45fca1e3.entry.js} +1 -1
  17. package/dist/biggive/{p-c3efc536.entry.js → p-48cfd1db.entry.js} +1 -1
  18. package/dist/biggive/{p-8d8b1488.entry.js → p-4a6f68dc.entry.js} +1 -1
  19. package/dist/biggive/{p-861f2f4a.entry.js → p-4d2fd220.entry.js} +1 -1
  20. package/dist/biggive/{p-4f78f441.entry.js → p-4dcf84ba.entry.js} +1 -1
  21. package/dist/biggive/{p-cbcb6d1d.entry.js → p-523043cf.entry.js} +1 -1
  22. package/dist/biggive/{p-b6f2e063.entry.js → p-524f1490.entry.js} +1 -1
  23. package/dist/biggive/{p-dbf0630d.entry.js → p-587796aa.entry.js} +1 -1
  24. package/dist/biggive/{p-474ed546.entry.js → p-5d285d41.entry.js} +1 -1
  25. package/dist/biggive/{p-74cea715.entry.js → p-628d65d0.entry.js} +1 -1
  26. package/dist/biggive/p-686996e2.entry.js +1 -0
  27. package/dist/biggive/{p-23253e31.entry.js → p-6a865f26.entry.js} +1 -1
  28. package/dist/biggive/{p-d3e5c82f.entry.js → p-6bf328a9.entry.js} +1 -1
  29. package/dist/biggive/{p-ea02284e.entry.js → p-6cafb9ab.entry.js} +1 -1
  30. package/dist/biggive/{p-1f4c671f.entry.js → p-747ae673.entry.js} +1 -1
  31. package/dist/biggive/{p-491891ab.entry.js → p-790921c5.entry.js} +1 -1
  32. package/dist/biggive/{p-2a6463d8.entry.js → p-7d1cddf2.entry.js} +1 -1
  33. package/dist/biggive/{p-947b9f4e.entry.js → p-7f0e202c.entry.js} +1 -1
  34. package/dist/biggive/{p-9a1744ce.entry.js → p-95d24a15.entry.js} +1 -1
  35. package/dist/biggive/{p-575d8459.entry.js → p-99e19baf.entry.js} +1 -1
  36. package/dist/biggive/p-DrbVeNEi.js +3 -0
  37. package/dist/biggive/p-a6845ab4.entry.js +1 -0
  38. package/dist/biggive/p-a9d2ed45.entry.js +1 -0
  39. package/dist/biggive/{p-6f5830b4.entry.js → p-af577c74.entry.js} +1 -1
  40. package/dist/biggive/p-b5eae243.entry.js +1 -0
  41. package/dist/biggive/{p-1327ae07.entry.js → p-c0a86605.entry.js} +1 -1
  42. package/dist/biggive/{p-199dac64.entry.js → p-c1dc8561.entry.js} +1 -1
  43. package/dist/biggive/{p-80382091.entry.js → p-c31bf4aa.entry.js} +1 -1
  44. package/dist/biggive/{p-88aa444d.entry.js → p-c947136a.entry.js} +1 -1
  45. package/dist/biggive/{p-db09fc60.entry.js → p-d16c6558.entry.js} +1 -1
  46. package/dist/biggive/{p-8507bb63.entry.js → p-d2551043.entry.js} +1 -1
  47. package/dist/biggive/{p-e53193ca.entry.js → p-df7c482e.entry.js} +1 -1
  48. package/dist/biggive/{p-412f12ea.entry.js → p-e0f128b2.entry.js} +1 -1
  49. package/dist/biggive/{p-fc8dd9f4.entry.js → p-ec93c321.entry.js} +1 -1
  50. package/dist/biggive/{p-0799b185.entry.js → p-ed7dc7e1.entry.js} +1 -1
  51. package/dist/biggive/{p-96354618.entry.js → p-f168479e.entry.js} +1 -1
  52. package/dist/biggive/p-f93d4b9f.entry.js +1 -0
  53. package/dist/biggive/{p-b0be3314.entry.js → p-ff834a57.entry.js} +1 -1
  54. package/dist/cjs/biggive-accordion-entry.cjs.entry.js +1 -1
  55. package/dist/cjs/biggive-accordion.cjs.entry.js +1 -1
  56. package/dist/cjs/biggive-article-card.cjs.entry.js +1 -1
  57. package/dist/cjs/biggive-back-to-top.cjs.entry.js +1 -1
  58. package/dist/cjs/biggive-basic-card.cjs.entry.js +1 -1
  59. package/dist/cjs/biggive-biography-card.cjs.entry.js +1 -1
  60. package/dist/cjs/biggive-boxed-content.cjs.entry.js +1 -1
  61. package/dist/cjs/biggive-branded-image.cjs.entry.js +1 -1
  62. package/dist/cjs/biggive-button.cjs.entry.js +1 -1
  63. package/dist/cjs/biggive-call-to-action.cjs.entry.js +1 -1
  64. package/dist/cjs/biggive-campaign-card.cjs.entry.js +1 -1
  65. package/dist/cjs/biggive-campaign-highlights.cjs.entry.js +1 -1
  66. package/dist/cjs/biggive-container-card.cjs.entry.js +1 -1
  67. package/dist/cjs/biggive-cookie-banner.cjs.entry.js +1 -1
  68. package/dist/cjs/biggive-footer.cjs.entry.js +1 -1
  69. package/dist/cjs/biggive-form-field-select.cjs.entry.js +1 -1
  70. package/dist/cjs/biggive-form.cjs.entry.js +1 -1
  71. package/dist/cjs/biggive-formatted-text.cjs.entry.js +1 -1
  72. package/dist/cjs/biggive-grid.cjs.entry.js +1 -1
  73. package/dist/cjs/biggive-heading-banner.cjs.entry.js +1 -1
  74. package/dist/cjs/biggive-heading.cjs.entry.js +1 -1
  75. package/dist/cjs/biggive-hero-image.cjs.entry.js +1 -1
  76. package/dist/cjs/biggive-icon-button.cjs.entry.js +1 -1
  77. package/dist/cjs/biggive-image-button.cjs.entry.js +1 -1
  78. package/dist/cjs/biggive-image-card.cjs.entry.js +1 -1
  79. package/dist/cjs/biggive-image-feature.cjs.entry.js +1 -1
  80. package/dist/cjs/biggive-image.cjs.entry.js +1 -1
  81. package/dist/cjs/biggive-main-menu.cjs.entry.js +1 -1
  82. package/dist/cjs/biggive-misc-icon.cjs.entry.js +1 -1
  83. package/dist/cjs/biggive-nav-group.cjs.entry.js +1 -1
  84. package/dist/cjs/biggive-nav-item.cjs.entry.js +1 -1
  85. package/dist/cjs/biggive-page-column.cjs.entry.js +1 -1
  86. package/dist/cjs/biggive-page-columns.cjs.entry.js +1 -1
  87. package/dist/cjs/biggive-page-section.cjs.entry.js +1 -1
  88. package/dist/cjs/biggive-popup.cjs.entry.js +1 -1
  89. package/dist/cjs/biggive-progress-bar.cjs.entry.js +1 -1
  90. package/dist/cjs/biggive-quote.cjs.entry.js +1 -1
  91. package/dist/cjs/biggive-sheet.cjs.entry.js +1 -1
  92. package/dist/cjs/biggive-social-icon.cjs.entry.js +1 -1
  93. package/dist/cjs/biggive-tab.cjs.entry.js +1 -1
  94. package/dist/cjs/biggive-tabbed-content.cjs.entry.js +1 -1
  95. package/dist/cjs/biggive-table.cjs.entry.js +1 -1
  96. package/dist/cjs/biggive-text-input.cjs.entry.js +1 -1
  97. package/dist/cjs/biggive-timeline-entry.cjs.entry.js +1 -1
  98. package/dist/cjs/biggive-timeline.cjs.entry.js +1 -1
  99. package/dist/cjs/biggive-totalizer-ticker-item.cjs.entry.js +1 -1
  100. package/dist/cjs/biggive-totalizer.cjs.entry.js +1 -1
  101. package/dist/cjs/biggive-video-feature.cjs.entry.js +1 -1
  102. package/dist/cjs/biggive-video.cjs.entry.js +1 -1
  103. package/dist/cjs/biggive.cjs.js +2 -2
  104. package/dist/cjs/{index-BsyTxzpK.js → index-RsfwXn0X.js} +103 -35
  105. package/dist/cjs/loader.cjs.js +1 -1
  106. package/dist/cjs/philco-footer.cjs.entry.js +1 -1
  107. package/dist/cjs/philco-main-menu.cjs.entry.js +1 -1
  108. package/dist/collection/collection-manifest.json +1 -1
  109. package/dist/esm/biggive-accordion-entry.entry.js +1 -1
  110. package/dist/esm/biggive-accordion.entry.js +1 -1
  111. package/dist/esm/biggive-article-card.entry.js +1 -1
  112. package/dist/esm/biggive-back-to-top.entry.js +1 -1
  113. package/dist/esm/biggive-basic-card.entry.js +1 -1
  114. package/dist/esm/biggive-biography-card.entry.js +1 -1
  115. package/dist/esm/biggive-boxed-content.entry.js +1 -1
  116. package/dist/esm/biggive-branded-image.entry.js +1 -1
  117. package/dist/esm/biggive-button.entry.js +1 -1
  118. package/dist/esm/biggive-call-to-action.entry.js +1 -1
  119. package/dist/esm/biggive-campaign-card.entry.js +1 -1
  120. package/dist/esm/biggive-campaign-highlights.entry.js +1 -1
  121. package/dist/esm/biggive-container-card.entry.js +1 -1
  122. package/dist/esm/biggive-cookie-banner.entry.js +1 -1
  123. package/dist/esm/biggive-footer.entry.js +1 -1
  124. package/dist/esm/biggive-form-field-select.entry.js +1 -1
  125. package/dist/esm/biggive-form.entry.js +1 -1
  126. package/dist/esm/biggive-formatted-text.entry.js +1 -1
  127. package/dist/esm/biggive-grid.entry.js +1 -1
  128. package/dist/esm/biggive-heading-banner.entry.js +1 -1
  129. package/dist/esm/biggive-heading.entry.js +1 -1
  130. package/dist/esm/biggive-hero-image.entry.js +1 -1
  131. package/dist/esm/biggive-icon-button.entry.js +1 -1
  132. package/dist/esm/biggive-image-button.entry.js +1 -1
  133. package/dist/esm/biggive-image-card.entry.js +1 -1
  134. package/dist/esm/biggive-image-feature.entry.js +1 -1
  135. package/dist/esm/biggive-image.entry.js +1 -1
  136. package/dist/esm/biggive-main-menu.entry.js +1 -1
  137. package/dist/esm/biggive-misc-icon.entry.js +1 -1
  138. package/dist/esm/biggive-nav-group.entry.js +1 -1
  139. package/dist/esm/biggive-nav-item.entry.js +1 -1
  140. package/dist/esm/biggive-page-column.entry.js +1 -1
  141. package/dist/esm/biggive-page-columns.entry.js +1 -1
  142. package/dist/esm/biggive-page-section.entry.js +1 -1
  143. package/dist/esm/biggive-popup.entry.js +1 -1
  144. package/dist/esm/biggive-progress-bar.entry.js +1 -1
  145. package/dist/esm/biggive-quote.entry.js +1 -1
  146. package/dist/esm/biggive-sheet.entry.js +1 -1
  147. package/dist/esm/biggive-social-icon.entry.js +1 -1
  148. package/dist/esm/biggive-tab.entry.js +1 -1
  149. package/dist/esm/biggive-tabbed-content.entry.js +1 -1
  150. package/dist/esm/biggive-table.entry.js +1 -1
  151. package/dist/esm/biggive-text-input.entry.js +1 -1
  152. package/dist/esm/biggive-timeline-entry.entry.js +1 -1
  153. package/dist/esm/biggive-timeline.entry.js +1 -1
  154. package/dist/esm/biggive-totalizer-ticker-item.entry.js +1 -1
  155. package/dist/esm/biggive-totalizer.entry.js +1 -1
  156. package/dist/esm/biggive-video-feature.entry.js +1 -1
  157. package/dist/esm/biggive-video.entry.js +1 -1
  158. package/dist/esm/biggive.js +3 -3
  159. package/dist/esm/{index-Cml8trro.js → index-DrbVeNEi.js} +103 -35
  160. package/dist/esm/loader.js +2 -2
  161. package/dist/esm/philco-footer.entry.js +1 -1
  162. package/dist/esm/philco-main-menu.entry.js +1 -1
  163. package/dist/types/components.d.ts +2 -2
  164. package/dist/types/stencil-public-runtime.d.ts +74 -55
  165. package/hydrate/index.js +950 -415
  166. package/hydrate/index.mjs +950 -415
  167. package/loader/index.d.ts +1 -1
  168. package/package.json +3 -3
  169. package/dist/biggive/p-2078197e.entry.js +0 -1
  170. package/dist/biggive/p-3e31c822.entry.js +0 -1
  171. package/dist/biggive/p-70db6b6a.entry.js +0 -1
  172. package/dist/biggive/p-Cml8trro.js +0 -2
  173. package/dist/biggive/p-a38575b4.entry.js +0 -1
  174. package/dist/biggive/p-fa80ee3d.entry.js +0 -1
package/hydrate/index.js CHANGED
@@ -4,6 +4,10 @@ var stream = require('stream');
4
4
 
5
5
  const modeResolutionChain = [];
6
6
 
7
+ // captured here, at true module scope, before hydrateFactory shadows the
8
+ // AbortController identifier for component code below.
9
+ var $stencilNativeAbortController = AbortController;
10
+
7
11
  function hydrateFactory($stencilWindow, $stencilHydrateOpts, $stencilHydrateResults, $stencilAfterHydrate, $stencilHydrateResolve) {
8
12
  var globalThis = $stencilWindow;
9
13
  var self = $stencilWindow;
@@ -95,8 +99,46 @@ function hydrateFactory($stencilWindow, $stencilHydrateOpts, $stencilHydrateResu
95
99
 
96
100
  var fetch, FetchError, Headers, Request, Response;
97
101
 
102
+ // Aborted when the render times out or errors, so in-flight fetch() calls
103
+ // made by component code stop holding the render's window/results alive
104
+ // instead of running to completion against a torn-down window. See #6864.
105
+ var $stencilAbortController = new $stencilNativeAbortController();
106
+
107
+ // Any AbortController a component creates itself is transparently wired to
108
+ // cascade-abort when the render times out too, so component code using the
109
+ // standard AbortController convention for its own cancellable work (axios,
110
+ // aws-sdk v3, the mongodb driver, etc.) gets cancelled automatically.
111
+ var AbortController = function () {
112
+ var controller = new $stencilNativeAbortController();
113
+ $stencilAbortController.signal.addEventListener(
114
+ 'abort',
115
+ function () {
116
+ controller.abort();
117
+ },
118
+ { once: true },
119
+ );
120
+ return controller;
121
+ };
122
+
123
+ function $stencilFetchSignal(callerSignal) {
124
+ if (!callerSignal) {
125
+ return $stencilAbortController.signal;
126
+ }
127
+ if (callerSignal.aborted || $stencilAbortController.signal.aborted) {
128
+ return callerSignal.aborted ? callerSignal : $stencilAbortController.signal;
129
+ }
130
+ var merged = new $stencilNativeAbortController();
131
+ var onAbort = function () { merged.abort(); };
132
+ callerSignal.addEventListener('abort', onAbort, { once: true });
133
+ $stencilAbortController.signal.addEventListener('abort', onAbort, { once: true });
134
+ return merged.signal;
135
+ }
136
+
98
137
  if (typeof $stencilWindow.fetch === 'function') {
99
- fetch = $stencilWindow.fetch;
138
+ var $stencilRawFetch = $stencilWindow.fetch;
139
+ fetch = $stencilWindow.fetch = function(input, init) {
140
+ return $stencilRawFetch(input, Object.assign({}, init, { signal: $stencilFetchSignal(init && init.signal) }));
141
+ };
100
142
  } else {
101
143
  fetch = $stencilWindow.fetch = function() { throw new Error('fetch() is not implemented'); };
102
144
  }
@@ -134,10 +176,8 @@ function hydrateFactory($stencilWindow, $stencilHydrateOpts, $stencilHydrateResu
134
176
  const NAMESPACE = 'biggive';
135
177
  const BUILD = /* biggive */ { hotModuleReplacement: false, hydratedSelectorName: "hydrated", slotRelocation: true, state: true, updatable: true};
136
178
 
137
- const globalStyles = "a{color:inherit;text-decoration:underline}a:hover{text-decoration:none}";
138
-
139
179
  /*
140
- Stencil Hydrate Platform v4.43.2 | MIT Licensed | https://stenciljs.com
180
+ Stencil Hydrate Platform v4.45.0 | MIT Licensed | https://stenciljs.com
141
181
  */
142
182
  var __create = Object.create;
143
183
  var __defProp = Object.defineProperty;
@@ -172,7 +212,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
172
212
  __defProp(target, "default", { value: mod, enumerable: true }) ,
173
213
  mod
174
214
  ));
175
- var __publicField = (obj, key, value) => __defNormalProp(obj, key + "" , value);
215
+ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
176
216
  var __accessCheck = (obj, member, msg) => member.has(obj) || __typeError("Cannot " + msg);
177
217
  var __privateGet = (obj, member, getter) => (__accessCheck(obj, member, "read from private field"), getter ? getter.call(obj) : member.get(obj));
178
218
  var __privateAdd = (obj, member, value) => member.has(obj) ? __typeError("Cannot add the same private member more than once") : member instanceof WeakSet ? member.add(obj) : member.set(obj, value);
@@ -427,9 +467,9 @@ function getPropertyDescriptor(obj, memberName, getOnly) {
427
467
 
428
468
  // src/utils/es2022-rewire-class-members.ts
429
469
  var reWireGetterSetter = (instance, hostRef) => {
430
- var _a;
470
+ var _a2;
431
471
  const cmpMeta = hostRef.$cmpMeta$;
432
- const members = Object.entries((_a = cmpMeta.$members$) != null ? _a : {});
472
+ const members = Object.entries((_a2 = cmpMeta.$members$) != null ? _a2 : {});
433
473
  members.map(([memberName, [memberFlags]]) => {
434
474
  if ((memberFlags & 31 /* Prop */ || memberFlags & 32 /* State */)) {
435
475
  const ogValue = instance[memberName];
@@ -477,6 +517,8 @@ var DEFAULT_DOC_DATA = {
477
517
  staticComponents: /* @__PURE__ */ new Set()
478
518
  };
479
519
  var SLOT_FB_CSS = "slot-fb{display:contents}slot-fb[hidden]{display:none}";
520
+ var MAX_LAZY_LOAD_RETRIES = 3;
521
+ var LAZY_LOAD_RETRY_INTERVAL_MS = 1e3;
480
522
 
481
523
  // src/utils/style.ts
482
524
  function createStyleSheetIfNeededAndSupported(styles2) {
@@ -486,18 +528,14 @@ function createStyleSheetIfNeededAndSupported(styles2) {
486
528
  // src/utils/shadow-root.ts
487
529
  var globalStyleSheet;
488
530
  function createShadowRoot(cmpMeta) {
489
- var _a;
531
+ var _a2;
490
532
  const opts = { mode: "open" };
491
533
  const shadowRoot = this.attachShadow(opts);
492
- if (globalStyleSheet === void 0) globalStyleSheet = (_a = createStyleSheetIfNeededAndSupported()) != null ? _a : null;
534
+ if (globalStyleSheet === void 0) globalStyleSheet = (_a2 = createStyleSheetIfNeededAndSupported()) != null ? _a2 : null;
493
535
  if (globalStyleSheet) {
494
536
  {
495
537
  shadowRoot.adoptedStyleSheets = [...shadowRoot.adoptedStyleSheets, globalStyleSheet];
496
538
  }
497
- } else {
498
- const styleElm = document.createElement("style");
499
- styleElm.innerHTML = globalStyles;
500
- shadowRoot.prepend(styleElm);
501
539
  }
502
540
  }
503
541
  var updateFallbackSlotVisibility = (elm) => {
@@ -541,7 +579,7 @@ function getHostSlotNodes(childNodes, hostName, slotName) {
541
579
  slottedNodes.push(childNode);
542
580
  if (typeof slotName !== "undefined") return slottedNodes;
543
581
  }
544
- slottedNodes = [...slottedNodes, ...getHostSlotNodes(childNode.childNodes, hostName, slotName)];
582
+ slottedNodes = [...slottedNodes, ...getHostSlotNodes(internalCall(childNode, "childNodes"), hostName, slotName)];
545
583
  }
546
584
  return slottedNodes;
547
585
  }
@@ -629,8 +667,8 @@ function dispatchSlotChangeEvent(elm) {
629
667
  elm.dispatchEvent(new CustomEvent("slotchange", { bubbles: false, cancelable: false, composed: false }));
630
668
  }
631
669
  function findSlotFromSlottedNode(slottedNode, parentHost) {
632
- var _a;
633
- parentHost = parentHost || ((_a = slottedNode["s-ol"]) == null ? void 0 : _a.parentElement);
670
+ var _a2;
671
+ parentHost = parentHost || ((_a2 = slottedNode["s-ol"]) == null ? void 0 : _a2.parentElement);
634
672
  if (!parentHost) return { slotNode: null, slotName: "" };
635
673
  const slotName = slottedNode["s-sn"] = getSlotName(slottedNode) || "";
636
674
  const childNodes = internalCall(parentHost, "childNodes");
@@ -664,8 +702,8 @@ var uniqueTime = (key, measureText) => {
664
702
 
665
703
  // src/utils/query-nonce-meta-tag-content.ts
666
704
  function queryNonceMetaTagContent(doc) {
667
- var _a, _b, _c;
668
- return (_c = (_b = (_a = doc.head) == null ? void 0 : _a.querySelector('meta[name="csp-nonce"]')) == null ? void 0 : _b.getAttribute("content")) != null ? _c : void 0;
705
+ var _a2, _b, _c;
706
+ return (_c = (_b = (_a2 = doc.head) == null ? void 0 : _a2.querySelector('meta[name="csp-nonce"]')) == null ? void 0 : _b.getAttribute("content")) != null ? _c : void 0;
669
707
  }
670
708
 
671
709
  // src/runtime/styles.ts
@@ -678,7 +716,7 @@ var registerStyle = (scopeId2, cssText, allowCS) => {
678
716
  styles.set(scopeId2, style);
679
717
  };
680
718
  var addStyle = (styleContainerNode, cmpMeta, mode) => {
681
- var _a;
719
+ var _a2;
682
720
  const scopeId2 = getScopeId(cmpMeta);
683
721
  const style = styles.get(scopeId2);
684
722
  if (!win.document) {
@@ -699,7 +737,7 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
699
737
  } else if (!appliedStyles.has(scopeId2)) {
700
738
  styleElm = win.document.createElement("style");
701
739
  styleElm.textContent = style;
702
- const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(win.document);
740
+ const nonce = (_a2 = plt.$nonce$) != null ? _a2 : queryNonceMetaTagContent(win.document);
703
741
  if (nonce != null) {
704
742
  styleElm.setAttribute("nonce", nonce);
705
743
  }
@@ -783,6 +821,11 @@ var h = (nodeName, vnodeData, ...children) => {
783
821
  } else if (child != null && typeof child !== "boolean") {
784
822
  if (simple = typeof nodeName !== "function" && !isComplexType(child)) {
785
823
  child = String(child);
824
+ } else if (typeof nodeName !== "function" && child.$flags$ === void 0) {
825
+ {
826
+ consoleError("Invalid vNode child");
827
+ }
828
+ continue;
786
829
  }
787
830
  if (simple && lastSimple) {
788
831
  vNodeChildren[vNodeChildren.length - 1].$text$ += child;
@@ -883,7 +926,7 @@ var convertToPrivate = (node) => {
883
926
 
884
927
  // src/runtime/client-hydrate.ts
885
928
  var initializeClientHydrate = (hostElm, tagName, hostId, hostRef) => {
886
- var _a, _b, _c, _d;
929
+ var _a2, _b, _c, _d;
887
930
  const endHydrate = createTime("hydrateClient", tagName);
888
931
  const shadowRoot = hostElm.shadowRoot;
889
932
  const childRenderNodes = [];
@@ -920,7 +963,7 @@ var initializeClientHydrate = (hostElm, tagName, hostId, hostRef) => {
920
963
  if (childRenderNode.$tag$ === "slot") {
921
964
  node["s-cr"] = hostElm["s-cr"];
922
965
  }
923
- } else if (((_a = childRenderNode.$tag$) == null ? void 0 : _a.toString().includes("-")) && childRenderNode.$tag$ !== "slot-fb" && !childRenderNode.$elm$.shadowRoot) {
966
+ } else if (((_a2 = childRenderNode.$tag$) == null ? void 0 : _a2.toString().includes("-")) && childRenderNode.$tag$ !== "slot-fb" && !childRenderNode.$elm$.shadowRoot) {
924
967
  const cmpMeta = getHostRef(childRenderNode.$elm$);
925
968
  if (cmpMeta) {
926
969
  const scopeId3 = getScopeId(
@@ -1252,10 +1295,10 @@ function addSlot(slotName, slotId, childVNode, node, parentVNode, childRenderNod
1252
1295
  parentVNode.$children$[childVNode.$index$] = childVNode;
1253
1296
  }
1254
1297
  var addSlottedNodes = (slottedNodes, slotNodeId, slotName, slotNode, hostId) => {
1255
- var _a, _b;
1298
+ var _a2, _b;
1256
1299
  let slottedNode = slotNode.nextSibling;
1257
1300
  slottedNodes[slotNodeId] = slottedNodes[slotNodeId] || [];
1258
- if (!slottedNode || ((_a = slottedNode.nodeValue) == null ? void 0 : _a.startsWith(SLOT_NODE_ID + "."))) return;
1301
+ if (!slottedNode || ((_a2 = slottedNode.nodeValue) == null ? void 0 : _a2.startsWith(SLOT_NODE_ID + "."))) return;
1259
1302
  do {
1260
1303
  if (slottedNode && ((slottedNode["getAttribute"] && slottedNode.getAttribute("slot") || slottedNode["s-sn"]) === slotName || slotName === "" && !slottedNode["s-sn"] && (!slottedNode["getAttribute"] || !slottedNode.getAttribute("slot")) && (slottedNode.nodeType === 8 /* CommentNode */ || slottedNode.nodeType === 3 /* TextNode */))) {
1261
1304
  slottedNode["s-sn"] = slotName;
@@ -1573,13 +1616,14 @@ var scopeSelector = (selector, scopeSelectorText, hostSelector, slotSelector) =>
1573
1616
  }
1574
1617
  }).join(", ");
1575
1618
  };
1619
+ var isScopableAtRule = (selector) => selector.startsWith("@media") || selector.startsWith("@supports") || selector.startsWith("@page") || selector.startsWith("@document") || selector.startsWith("@layer");
1576
1620
  var scopeSelectors = (cssText, scopeSelectorText, hostSelector, slotSelector, commentOriginalSelector) => {
1577
1621
  return processRules(cssText, (rule) => {
1578
1622
  let selector = rule.selector;
1579
1623
  let content = rule.content;
1580
1624
  if (rule.selector[0] !== "@") {
1581
1625
  selector = scopeSelector(rule.selector, scopeSelectorText, hostSelector, slotSelector);
1582
- } else if (rule.selector.startsWith("@media") || rule.selector.startsWith("@supports") || rule.selector.startsWith("@page") || rule.selector.startsWith("@document")) {
1626
+ } else if (isScopableAtRule(rule.selector)) {
1583
1627
  content = scopeSelectors(rule.content, scopeSelectorText, hostSelector, slotSelector);
1584
1628
  }
1585
1629
  const cssRule = {
@@ -1658,15 +1702,16 @@ var scopeCss = (cssText, scopeId2, commentOriginalSelector) => {
1658
1702
  rule.selector = placeholder + rule.selector;
1659
1703
  return rule;
1660
1704
  };
1661
- cssText = processRules(cssText, (rule) => {
1705
+ const commentSelectors = (input) => processRules(input, (rule) => {
1662
1706
  if (rule.selector[0] !== "@") {
1663
1707
  return processCommentedSelector(rule);
1664
- } else if (rule.selector.startsWith("@media") || rule.selector.startsWith("@supports") || rule.selector.startsWith("@page") || rule.selector.startsWith("@document")) {
1665
- rule.content = processRules(rule.content, processCommentedSelector);
1666
- return rule;
1708
+ }
1709
+ if (isScopableAtRule(rule.selector)) {
1710
+ rule.content = commentSelectors(rule.content);
1667
1711
  }
1668
1712
  return rule;
1669
1713
  });
1714
+ cssText = commentSelectors(cssText);
1670
1715
  }
1671
1716
  const scoped = scopeCssText(cssText, scopeId2, hostScopeId, slotScopeId);
1672
1717
  cssText = [scoped.cssText, ...commentsWithHash].join("\n");
@@ -1683,6 +1728,31 @@ var scopeCss = (cssText, scopeId2, commentOriginalSelector) => {
1683
1728
  return cssText;
1684
1729
  };
1685
1730
 
1731
+ // src/runtime/normalize-watchers.ts
1732
+ var normalizeWatchers = (raw) => {
1733
+ if (!raw) return void 0;
1734
+ const keys = Object.keys(raw);
1735
+ if (keys.length === 0) return void 0;
1736
+ let hasLegacy = false;
1737
+ for (const propName of keys) {
1738
+ if (hasLegacy) break;
1739
+ for (const h2 of raw[propName]) {
1740
+ if (typeof h2 === "string") {
1741
+ hasLegacy = true;
1742
+ break;
1743
+ }
1744
+ }
1745
+ }
1746
+ if (!hasLegacy) return raw;
1747
+ const out = {};
1748
+ for (const propName of keys) {
1749
+ out[propName] = raw[propName].map(
1750
+ (h2) => typeof h2 === "string" ? { [h2]: 0 } : h2
1751
+ );
1752
+ }
1753
+ return out;
1754
+ };
1755
+
1686
1756
  // src/utils/remote-value.ts
1687
1757
  var RemoteValue = class _RemoteValue {
1688
1758
  /**
@@ -1779,11 +1849,19 @@ var RemoteValue = class _RemoteValue {
1779
1849
  };
1780
1850
 
1781
1851
  // src/utils/serialize.ts
1852
+ function decodeBase64Unicode(base64) {
1853
+ const binary = atob(base64);
1854
+ const bytes = new Uint8Array(binary.length);
1855
+ for (let i2 = 0; i2 < binary.length; i2++) {
1856
+ bytes[i2] = binary.charCodeAt(i2);
1857
+ }
1858
+ return new TextDecoder().decode(bytes);
1859
+ }
1782
1860
  function deserializeProperty(value) {
1783
1861
  if (typeof value !== "string" || !value.startsWith(SERIALIZED_PREFIX)) {
1784
1862
  return value;
1785
1863
  }
1786
- return RemoteValue.fromLocalValue(JSON.parse(atob(value.slice(SERIALIZED_PREFIX.length))));
1864
+ return RemoteValue.fromLocalValue(JSON.parse(decodeBase64Unicode(value.slice(SERIALIZED_PREFIX.length))));
1787
1865
  }
1788
1866
 
1789
1867
  // src/runtime/parse-property-value.ts
@@ -1809,8 +1887,8 @@ var parsePropertyValue = (propValue, propType, isFormAssociated) => {
1809
1887
  return propValue;
1810
1888
  };
1811
1889
  var getElement = (ref) => {
1812
- var _a;
1813
- return (_a = getHostRef(ref)) == null ? void 0 : _a.$hostElement$ ;
1890
+ var _a2;
1891
+ return (_a2 = getHostRef(ref)) == null ? void 0 : _a2.$hostElement$ ;
1814
1892
  };
1815
1893
 
1816
1894
  // src/runtime/event-emitter.ts
@@ -1945,7 +2023,7 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
1945
2023
  }
1946
2024
  }
1947
2025
  if (newValue == null || newValue === false) {
1948
- if (newValue !== false || elm.getAttribute(memberName) === "") {
2026
+ if (newValue !== false || elm.getAttribute(memberName) === "" || flags & 4 /* isHost */ && !isEnumeratedAttribute(memberName)) {
1949
2027
  {
1950
2028
  elm.removeAttribute(memberName);
1951
2029
  }
@@ -1958,6 +2036,8 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
1958
2036
  }
1959
2037
  }
1960
2038
  };
2039
+ var ENUMERATED_ATTRIBUTES = /* @__PURE__ */ new Set(["draggable", "contenteditable", "spellcheck"]);
2040
+ var isEnumeratedAttribute = (attrName) => ENUMERATED_ATTRIBUTES.has(attrName) || attrName.startsWith("aria-");
1961
2041
  var parseClassListRegex = /\s/;
1962
2042
  var parseClassList = (value) => {
1963
2043
  if (typeof value === "object" && value && "baseVal" in value) {
@@ -2024,7 +2104,7 @@ var isSvgMode = false;
2024
2104
  var refCallbacksToRemove = [];
2025
2105
  var refCallbacksToAttach = [];
2026
2106
  var createElm = (oldParentVNode, newParentVNode, childIndex) => {
2027
- var _a;
2107
+ var _a2;
2028
2108
  const newVNode2 = newParentVNode.$children$[childIndex];
2029
2109
  let i2 = 0;
2030
2110
  let elm;
@@ -2095,7 +2175,7 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
2095
2175
  elm["s-sr"] = true;
2096
2176
  elm["s-cr"] = contentRef;
2097
2177
  elm["s-sn"] = newVNode2.$name$ || "";
2098
- elm["s-rf"] = (_a = newVNode2.$attrs$) == null ? void 0 : _a.ref;
2178
+ elm["s-rf"] = (_a2 = newVNode2.$attrs$) == null ? void 0 : _a2.ref;
2099
2179
  patchSlotNode(elm);
2100
2180
  oldVNode = oldParentVNode && oldParentVNode.$children$ && oldParentVNode.$children$[childIndex];
2101
2181
  if (oldVNode && oldVNode.$tag$ === newVNode2.$tag$ && oldParentVNode.$elm$) {
@@ -2253,7 +2333,7 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
2253
2333
  if (idxInOld >= 0) {
2254
2334
  elmToMove = oldCh[idxInOld];
2255
2335
  if (elmToMove.$tag$ !== newStartVnode.$tag$) {
2256
- node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld);
2336
+ node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx);
2257
2337
  } else {
2258
2338
  patch(elmToMove, newStartVnode, isInitialRender);
2259
2339
  oldCh[idxInOld] = void 0;
@@ -2360,7 +2440,10 @@ var markSlotContentForRelocation = (elm) => {
2360
2440
  const slotName = childNode["s-sn"];
2361
2441
  for (j = hostContentNodes.length - 1; j >= 0; j--) {
2362
2442
  node = hostContentNodes[j];
2363
- if (!node["s-cn"] && !node["s-nr"] && node["s-hn"] !== childNode["s-hn"] && (!node["s-sh"] || node["s-sh"] !== childNode["s-hn"])) {
2443
+ if (!node["s-cn"] && !node["s-nr"] && node["s-hn"] !== childNode["s-hn"] && // let an exact named-slot match override a stale default-slot claim. Skip this for
2444
+ // `slotName === ''` itself - a matched default node's cached `s-sn` is `''` too, which
2445
+ // would trivially "match" on every re-render and force pointless re-insertion.
2446
+ (!node["s-sh"] || node["s-sh"] !== childNode["s-hn"] || slotName !== "" && getSlotName(node) === slotName)) {
2364
2447
  if (isNodeLocatedInSlot(node, slotName)) {
2365
2448
  let relocateNodeData = relocateNodes.find((r) => r.$nodeToRelocate$ === node);
2366
2449
  checkSlotFallbackVisibility = true;
@@ -2428,19 +2511,19 @@ var insertBefore = (parent, newNode, reference, isInitialLoad) => {
2428
2511
  return newNode;
2429
2512
  }
2430
2513
  }
2431
- if (parent.__insertBefore) {
2514
+ if ((parent == null ? void 0 : parent.__insertBefore)) {
2432
2515
  return parent.__insertBefore(newNode, reference);
2433
2516
  } else {
2434
2517
  return parent == null ? void 0 : parent.insertBefore(newNode, reference);
2435
2518
  }
2436
2519
  };
2437
2520
  function addRemoveSlotScopedClass(reference, slotNode, newParent, oldParent) {
2438
- var _a, _b;
2521
+ var _a2, _b;
2439
2522
  let scopeId2;
2440
2523
  if (reference && typeof slotNode["s-sn"] === "string" && !!slotNode["s-sr"] && reference.parentNode && reference.parentNode["s-sc"] && (scopeId2 = slotNode["s-si"] || reference.parentNode["s-sc"])) {
2441
2524
  const scopeName = slotNode["s-sn"];
2442
2525
  const hostName = slotNode["s-hn"];
2443
- (_a = newParent.classList) == null ? void 0 : _a.add(scopeId2 + "-s");
2526
+ (_a2 = newParent.classList) == null ? void 0 : _a2.add(scopeId2 + "-s");
2444
2527
  if (oldParent && ((_b = oldParent.classList) == null ? void 0 : _b.contains(scopeId2 + "-s"))) {
2445
2528
  let child = (oldParent.__childNodes || oldParent.childNodes)[0];
2446
2529
  let found = false;
@@ -2456,7 +2539,7 @@ function addRemoveSlotScopedClass(reference, slotNode, newParent, oldParent) {
2456
2539
  }
2457
2540
  }
2458
2541
  var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
2459
- var _a, _d, _e;
2542
+ var _a2, _d, _e;
2460
2543
  const hostElm = hostRef.$hostElement$;
2461
2544
  const cmpMeta = hostRef.$cmpMeta$;
2462
2545
  const oldVNode = hostRef.$vnode$ || newVNode(null, null);
@@ -2504,7 +2587,7 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
2504
2587
  const nodeToRelocate = relocateData.$nodeToRelocate$;
2505
2588
  const slotRefNode = relocateData.$slotRefNode$;
2506
2589
  if (nodeToRelocate.nodeType === 1 /* ElementNode */ && isInitialLoad) {
2507
- nodeToRelocate["s-ih"] = (_a = nodeToRelocate.hidden) != null ? _a : false;
2590
+ nodeToRelocate["s-ih"] = (_a2 = nodeToRelocate.hidden) != null ? _a2 : false;
2508
2591
  }
2509
2592
  if (slotRefNode) {
2510
2593
  const parentNodeRef = slotRefNode.parentNode;
@@ -2564,14 +2647,14 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
2564
2647
  flushQueuedRefCallbacks();
2565
2648
  };
2566
2649
  var slotReferenceDebugNode = (slotVNode) => {
2567
- var _a;
2568
- return (_a = win.document) == null ? void 0 : _a.createComment(
2650
+ var _a2;
2651
+ return (_a2 = win.document) == null ? void 0 : _a2.createComment(
2569
2652
  `<slot${slotVNode.$name$ ? ' name="' + slotVNode.$name$ + '"' : ""}> (host=${hostTagName.toLowerCase()})`
2570
2653
  );
2571
2654
  };
2572
2655
  var originalLocationDebugNode = (nodeToRelocate) => {
2573
- var _a;
2574
- return (_a = win.document) == null ? void 0 : _a.createComment(
2656
+ var _a2;
2657
+ return (_a2 = win.document) == null ? void 0 : _a2.createComment(
2575
2658
  `org-location for ` + (nodeToRelocate.localName ? `<${nodeToRelocate.localName}> (host=${nodeToRelocate["s-hn"]})` : `[${nodeToRelocate.textContent}]`)
2576
2659
  );
2577
2660
  };
@@ -2641,7 +2724,7 @@ var enqueue = (maybePromise, fn) => isPromisey(maybePromise) ? maybePromise.then
2641
2724
  }) : fn();
2642
2725
  var isPromisey = (maybePromise) => maybePromise instanceof Promise || maybePromise && maybePromise.then && typeof maybePromise.then === "function";
2643
2726
  var updateComponent = async (hostRef, instance, isInitialLoad) => {
2644
- var _a;
2727
+ var _a2;
2645
2728
  const elm = hostRef.$hostElement$;
2646
2729
  const endUpdate = createTime("update", hostRef.$cmpMeta$.$tagName$);
2647
2730
  const rc = elm["s-rc"];
@@ -2673,7 +2756,7 @@ var updateComponent = async (hostRef, instance, isInitialLoad) => {
2673
2756
  endRender();
2674
2757
  endUpdate();
2675
2758
  {
2676
- const childrenPromises = (_a = elm["s-p"]) != null ? _a : [];
2759
+ const childrenPromises = (_a2 = elm["s-p"]) != null ? _a2 : [];
2677
2760
  const postUpdate = () => postUpdateComponent(hostRef);
2678
2761
  if (childrenPromises.length === 0) {
2679
2762
  postUpdate();
@@ -2744,13 +2827,13 @@ var postUpdateComponent = (hostRef) => {
2744
2827
  }
2745
2828
  };
2746
2829
  var appDidLoad = (who) => {
2747
- var _a;
2830
+ var _a2;
2748
2831
  if (BUILD.asyncQueue) {
2749
2832
  plt.$flags$ |= 2 /* appLoaded */;
2750
2833
  }
2751
2834
  nextTick(() => emitEvent(win, "appload", { detail: { namespace: NAMESPACE } }));
2752
2835
  {
2753
- if ((_a = plt.$orgLocNodes$) == null ? void 0 : _a.size) {
2836
+ if ((_a2 = plt.$orgLocNodes$) == null ? void 0 : _a2.size) {
2754
2837
  plt.$orgLocNodes$.clear();
2755
2838
  }
2756
2839
  }
@@ -2766,8 +2849,8 @@ var safeCall = (instance, method, arg, elm) => {
2766
2849
  return void 0;
2767
2850
  };
2768
2851
  var addHydratedFlag = (elm) => {
2769
- var _a;
2770
- return elm.classList.add((_a = BUILD.hydratedSelectorName) != null ? _a : "hydrated") ;
2852
+ var _a2;
2853
+ return elm.classList.add((_a2 = BUILD.hydratedSelectorName) != null ? _a2 : "hydrated") ;
2771
2854
  };
2772
2855
  var serverSideConnected = (elm) => {
2773
2856
  const children = elm.children;
@@ -2839,15 +2922,13 @@ var setValue = (ref, propName, newVal, cmpMeta) => {
2839
2922
  }
2840
2923
  }
2841
2924
  };
2842
-
2843
- // src/runtime/proxy-component.ts
2844
2925
  var proxyComponent = (Cstr, cmpMeta, flags) => {
2845
- var _a;
2926
+ var _a2;
2846
2927
  const prototype = Cstr.prototype;
2847
2928
  {
2848
2929
  {
2849
2930
  if (Cstr.watchers && !cmpMeta.$watchers$) {
2850
- cmpMeta.$watchers$ = Cstr.watchers;
2931
+ cmpMeta.$watchers$ = normalizeWatchers(Cstr.watchers);
2851
2932
  }
2852
2933
  if (Cstr.deserializers && !cmpMeta.$deserializers$) {
2853
2934
  cmpMeta.$deserializers$ = Cstr.deserializers;
@@ -2856,7 +2937,7 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
2856
2937
  cmpMeta.$serializers$ = Cstr.serializers;
2857
2938
  }
2858
2939
  }
2859
- const members = Object.entries((_a = cmpMeta.$members$) != null ? _a : {});
2940
+ const members = Object.entries((_a2 = cmpMeta.$members$) != null ? _a2 : {});
2860
2941
  members.map(([memberName, [memberFlags]]) => {
2861
2942
  if ((memberFlags & 31 /* Prop */ || memberFlags & 32 /* State */)) {
2862
2943
  const { get: origGetter, set: origSetter } = getPropertyDescriptor(prototype, memberName) || {};
@@ -2915,10 +2996,12 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
2915
2996
 
2916
2997
  // src/runtime/initialize-component.ts
2917
2998
  var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
2999
+ var _a2;
2918
3000
  let Cstr;
2919
3001
  try {
2920
3002
  if ((hostRef.$flags$ & 32 /* hasInitializedComponent */) === 0) {
2921
3003
  hostRef.$flags$ |= 32 /* hasInitializedComponent */;
3004
+ hostRef.$flags$ &= -1025 /* hasFailedLoad */;
2922
3005
  const bundleId = cmpMeta.$lazyBundleId$;
2923
3006
  if (bundleId) {
2924
3007
  const CstrImport = loadModule(cmpMeta);
@@ -2930,11 +3013,16 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
2930
3013
  Cstr = CstrImport;
2931
3014
  }
2932
3015
  if (!Cstr) {
3016
+ hostRef.$flags$ &= -33 /* hasInitializedComponent */;
3017
+ hostRef.$loadRetryCount$ = ((_a2 = hostRef.$loadRetryCount$) != null ? _a2 : 0) + 1;
3018
+ if (hostRef.$loadRetryCount$ < MAX_LAZY_LOAD_RETRIES) {
3019
+ hostRef.$flags$ |= 1024 /* hasFailedLoad */;
3020
+ }
2933
3021
  throw new Error(`Constructor for "${cmpMeta.$tagName$}#${hostRef.$modeName$}" was not found`);
2934
3022
  }
2935
3023
  if (!Cstr.isProxied) {
2936
3024
  {
2937
- cmpMeta.$watchers$ = Cstr.watchers;
3025
+ cmpMeta.$watchers$ = normalizeWatchers(Cstr.watchers);
2938
3026
  cmpMeta.$serializers$ = Cstr.serializers;
2939
3027
  cmpMeta.$deserializers$ = Cstr.deserializers;
2940
3028
  }
@@ -3001,7 +3089,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
3001
3089
  hostRef.$onRenderResolve$();
3002
3090
  hostRef.$onRenderResolve$ = void 0;
3003
3091
  }
3004
- if (hostRef.$onReadyResolve$) {
3092
+ if (hostRef.$onReadyResolve$ && !(hostRef.$flags$ & 1024 /* hasFailedLoad */)) {
3005
3093
  hostRef.$onReadyResolve$(elm);
3006
3094
  }
3007
3095
  }
@@ -3056,6 +3144,8 @@ var connectedCallback = (elm) => {
3056
3144
  } else {
3057
3145
  if (hostRef == null ? void 0 : hostRef.$lazyInstance$) {
3058
3146
  fireConnectedCallback(hostRef.$lazyInstance$, elm);
3147
+ } else if (hostRef.$flags$ & 1024 /* hasFailedLoad */) {
3148
+ setTimeout(() => initializeComponent(elm, hostRef, cmpMeta), LAZY_LOAD_RETRY_INTERVAL_MS);
3059
3149
  } else if (hostRef == null ? void 0 : hostRef.$onReadyPromise$) {
3060
3150
  hostRef.$onReadyPromise$.then(() => fireConnectedCallback(hostRef.$lazyInstance$, elm));
3061
3151
  }
@@ -3085,7 +3175,7 @@ var insertVdomAnnotations = (doc, staticComponents) => {
3085
3175
  const orgLocationNodes = [];
3086
3176
  parseVNodeAnnotations(doc, doc.body, docData, orgLocationNodes);
3087
3177
  orgLocationNodes.forEach((orgLocationNode) => {
3088
- var _a;
3178
+ var _a2;
3089
3179
  if (orgLocationNode != null && orgLocationNode["s-nr"]) {
3090
3180
  const nodeRef = orgLocationNode["s-nr"];
3091
3181
  let hostId = nodeRef["s-host-id"];
@@ -3103,7 +3193,7 @@ var insertVdomAnnotations = (doc, staticComponents) => {
3103
3193
  }
3104
3194
  } else if (nodeRef.nodeType === 3 /* TextNode */) {
3105
3195
  if (hostId === 0) {
3106
- const textContent = (_a = nodeRef.nodeValue) == null ? void 0 : _a.trim();
3196
+ const textContent = (_a2 = nodeRef.nodeValue) == null ? void 0 : _a2.trim();
3107
3197
  if (textContent === "") {
3108
3198
  orgLocationNode.remove();
3109
3199
  return;
@@ -3133,7 +3223,7 @@ var insertVdomAnnotations = (doc, staticComponents) => {
3133
3223
  }
3134
3224
  };
3135
3225
  var parseVNodeAnnotations = (doc, node, docData, orgLocationNodes) => {
3136
- var _a;
3226
+ var _a2;
3137
3227
  if (node == null) {
3138
3228
  return;
3139
3229
  }
@@ -3141,7 +3231,7 @@ var parseVNodeAnnotations = (doc, node, docData, orgLocationNodes) => {
3141
3231
  orgLocationNodes.push(node);
3142
3232
  }
3143
3233
  if (node.nodeType === 1 /* ElementNode */) {
3144
- const childNodes = [...Array.from(node.childNodes), ...Array.from(((_a = node.shadowRoot) == null ? void 0 : _a.childNodes) || [])];
3234
+ const childNodes = [...Array.from(node.childNodes), ...Array.from(((_a2 = node.shadowRoot) == null ? void 0 : _a2.childNodes) || [])];
3145
3235
  childNodes.forEach((childNode) => {
3146
3236
  const hostRef = getHostRef(childNode);
3147
3237
  if (hostRef != null && !docData.staticComponents.has(childNode.nodeName.toLowerCase())) {
@@ -3367,8 +3457,35 @@ var unescape = (s, { windowsPathsNoEscape = false } = {}) => {
3367
3457
  };
3368
3458
 
3369
3459
  // node_modules/minimatch/dist/esm/ast.js
3460
+ var _a;
3370
3461
  var types = /* @__PURE__ */ new Set(["!", "?", "+", "*", "@"]);
3371
3462
  var isExtglobType = (c) => types.has(c);
3463
+ var isExtglobAST = (c) => isExtglobType(c.type);
3464
+ var adoptionMap = /* @__PURE__ */ new Map([
3465
+ ["!", ["@"]],
3466
+ ["?", ["?", "@"]],
3467
+ ["@", ["@"]],
3468
+ ["*", ["*", "+", "?", "@"]],
3469
+ ["+", ["+", "@"]]
3470
+ ]);
3471
+ var adoptionWithSpaceMap = /* @__PURE__ */ new Map([
3472
+ ["!", ["?"]],
3473
+ ["@", ["?"]],
3474
+ ["+", ["?", "*"]]
3475
+ ]);
3476
+ var adoptionAnyMap = /* @__PURE__ */ new Map([
3477
+ ["!", ["?", "@"]],
3478
+ ["?", ["?", "@"]],
3479
+ ["@", ["?", "@"]],
3480
+ ["*", ["*", "+", "?", "@"]],
3481
+ ["+", ["+", "@", "?", "*"]]
3482
+ ]);
3483
+ var usurpMap = /* @__PURE__ */ new Map([
3484
+ ["!", /* @__PURE__ */ new Map([["!", "@"]])],
3485
+ ["?", /* @__PURE__ */ new Map([["*", "*"], ["+", "*"]])],
3486
+ ["@", /* @__PURE__ */ new Map([["!", "!"], ["?", "?"], ["@", "@"], ["*", "*"], ["+", "+"]])],
3487
+ ["+", /* @__PURE__ */ new Map([["?", "*"], ["*", "*"]])]
3488
+ ]);
3372
3489
  var startNoTraversal = "(?!(?:^|/)\\.\\.?(?:$|/))";
3373
3490
  var startNoDot = "(?!\\.)";
3374
3491
  var addPatternStart = /* @__PURE__ */ new Set(["[", "."]);
@@ -3378,8 +3495,8 @@ var regExpEscape = (s) => s.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&");
3378
3495
  var qmark = "[^/]";
3379
3496
  var star = qmark + "*?";
3380
3497
  var starNoEmpty = qmark + "+?";
3381
- var _root, _hasMagic, _uflag, _parts, _parent, _parentIndex, _negs, _filledNegs, _options, _toString, _emptyExt, _AST_instances, fillNegs_fn, _AST_static, parseAST_fn, partsToRegExp_fn, parseGlob_fn;
3382
- var _AST = class _AST {
3498
+ var _root, _hasMagic, _uflag, _parts, _parent, _parentIndex, _negs, _filledNegs, _options, _toString, _emptyExt, _AST_instances, fillNegs_fn, _AST_static, parseAST_fn, canAdoptWithSpace_fn, canAdopt_fn, canAdoptType_fn, adoptWithSpace_fn, adopt_fn, canUsurpType_fn, canUsurp_fn, usurp_fn, flatten_fn, partsToRegExp_fn, parseGlob_fn;
3499
+ var AST = class {
3383
3500
  constructor(type, parent, options = {}) {
3384
3501
  __privateAdd(this, _AST_instances);
3385
3502
  __publicField(this, "type");
@@ -3432,44 +3549,44 @@ var _AST = class _AST {
3432
3549
  for (const p of parts) {
3433
3550
  if (p === "")
3434
3551
  continue;
3435
- if (typeof p !== "string" && !(p instanceof _AST && __privateGet(p, _parent) === this)) {
3552
+ if (typeof p !== "string" && !(p instanceof _a && __privateGet(p, _parent) === this)) {
3436
3553
  throw new Error("invalid part: " + p);
3437
3554
  }
3438
3555
  __privateGet(this, _parts).push(p);
3439
3556
  }
3440
3557
  }
3441
3558
  toJSON() {
3442
- var _a;
3559
+ var _a2;
3443
3560
  const ret = this.type === null ? __privateGet(this, _parts).slice().map((p) => typeof p === "string" ? p : p.toJSON()) : [this.type, ...__privateGet(this, _parts).map((p) => p.toJSON())];
3444
3561
  if (this.isStart() && !this.type)
3445
3562
  ret.unshift([]);
3446
- if (this.isEnd() && (this === __privateGet(this, _root) || __privateGet(__privateGet(this, _root), _filledNegs) && ((_a = __privateGet(this, _parent)) == null ? void 0 : _a.type) === "!")) {
3563
+ if (this.isEnd() && (this === __privateGet(this, _root) || __privateGet(__privateGet(this, _root), _filledNegs) && ((_a2 = __privateGet(this, _parent)) == null ? void 0 : _a2.type) === "!")) {
3447
3564
  ret.push({});
3448
3565
  }
3449
3566
  return ret;
3450
3567
  }
3451
3568
  isStart() {
3452
- var _a;
3569
+ var _a2;
3453
3570
  if (__privateGet(this, _root) === this)
3454
3571
  return true;
3455
- if (!((_a = __privateGet(this, _parent)) == null ? void 0 : _a.isStart()))
3572
+ if (!((_a2 = __privateGet(this, _parent)) == null ? void 0 : _a2.isStart()))
3456
3573
  return false;
3457
3574
  if (__privateGet(this, _parentIndex) === 0)
3458
3575
  return true;
3459
3576
  const p = __privateGet(this, _parent);
3460
3577
  for (let i2 = 0; i2 < __privateGet(this, _parentIndex); i2++) {
3461
3578
  const pp = __privateGet(p, _parts)[i2];
3462
- if (!(pp instanceof _AST && pp.type === "!")) {
3579
+ if (!(pp instanceof _a && pp.type === "!")) {
3463
3580
  return false;
3464
3581
  }
3465
3582
  }
3466
3583
  return true;
3467
3584
  }
3468
3585
  isEnd() {
3469
- var _a, _b, _c;
3586
+ var _a2, _b, _c;
3470
3587
  if (__privateGet(this, _root) === this)
3471
3588
  return true;
3472
- if (((_a = __privateGet(this, _parent)) == null ? void 0 : _a.type) === "!")
3589
+ if (((_a2 = __privateGet(this, _parent)) == null ? void 0 : _a2.type) === "!")
3473
3590
  return true;
3474
3591
  if (!((_b = __privateGet(this, _parent)) == null ? void 0 : _b.isEnd()))
3475
3592
  return false;
@@ -3485,16 +3602,16 @@ var _AST = class _AST {
3485
3602
  this.push(part.clone(this));
3486
3603
  }
3487
3604
  clone(parent) {
3488
- const c = new _AST(this.type, parent);
3605
+ const c = new _a(this.type, parent);
3489
3606
  for (const p of __privateGet(this, _parts)) {
3490
3607
  c.copyIn(p);
3491
3608
  }
3492
3609
  return c;
3493
3610
  }
3494
3611
  static fromGlob(pattern, options = {}) {
3495
- var _a;
3496
- const ast = new _AST(null, void 0, options);
3497
- __privateMethod(_a = _AST, _AST_static, parseAST_fn).call(_a, pattern, ast, 0, options);
3612
+ var _a2;
3613
+ const ast = new _a(null, void 0, options);
3614
+ __privateMethod(_a2 = _a, _AST_static, parseAST_fn).call(_a2, pattern, ast, 0, options, 0);
3498
3615
  return ast;
3499
3616
  }
3500
3617
  // returns the regular expression if there's magic, or the unescaped
@@ -3587,15 +3704,17 @@ var _AST = class _AST {
3587
3704
  // is ^(?!\.), we can just prepend (?!\.) to the pattern (either root
3588
3705
  // or start or whatever) and prepend ^ or / at the Regexp construction.
3589
3706
  toRegExpSource(allowDot) {
3590
- var _a;
3707
+ var _a2;
3591
3708
  const dot = allowDot != null ? allowDot : !!__privateGet(this, _options).dot;
3592
- if (__privateGet(this, _root) === this)
3709
+ if (__privateGet(this, _root) === this) {
3710
+ __privateMethod(this, _AST_instances, flatten_fn).call(this);
3593
3711
  __privateMethod(this, _AST_instances, fillNegs_fn).call(this);
3594
- if (!this.type) {
3712
+ }
3713
+ if (!isExtglobAST(this)) {
3595
3714
  const noEmpty = this.isStart() && this.isEnd();
3596
3715
  const src = __privateGet(this, _parts).map((p) => {
3597
- var _a2;
3598
- const [re, _, hasMagic, uflag] = typeof p === "string" ? __privateMethod(_a2 = _AST, _AST_static, parseGlob_fn).call(_a2, p, __privateGet(this, _hasMagic), noEmpty) : p.toRegExpSource(allowDot);
3716
+ var _a3;
3717
+ const [re, _, hasMagic, uflag] = typeof p === "string" ? __privateMethod(_a3 = _a, _AST_static, parseGlob_fn).call(_a3, p, __privateGet(this, _hasMagic), noEmpty) : p.toRegExpSource(allowDot);
3599
3718
  __privateSet(this, _hasMagic, __privateGet(this, _hasMagic) || hasMagic);
3600
3719
  __privateSet(this, _uflag, __privateGet(this, _uflag) || uflag);
3601
3720
  return re;
@@ -3618,7 +3737,7 @@ var _AST = class _AST {
3618
3737
  }
3619
3738
  }
3620
3739
  let end = "";
3621
- if (this.isEnd() && __privateGet(__privateGet(this, _root), _filledNegs) && ((_a = __privateGet(this, _parent)) == null ? void 0 : _a.type) === "!") {
3740
+ if (this.isEnd() && __privateGet(__privateGet(this, _root), _filledNegs) && ((_a2 = __privateGet(this, _parent)) == null ? void 0 : _a2.type) === "!") {
3622
3741
  end = "(?:$|\\/)";
3623
3742
  }
3624
3743
  const final2 = start2 + src + end;
@@ -3634,9 +3753,10 @@ var _AST = class _AST {
3634
3753
  let body = __privateMethod(this, _AST_instances, partsToRegExp_fn).call(this, dot);
3635
3754
  if (this.isStart() && this.isEnd() && !body && this.type !== "!") {
3636
3755
  const s = this.toString();
3637
- __privateSet(this, _parts, [s]);
3638
- this.type = null;
3639
- __privateSet(this, _hasMagic, void 0);
3756
+ const me = this;
3757
+ __privateSet(me, _parts, [s]);
3758
+ me.type = null;
3759
+ __privateSet(me, _hasMagic, void 0);
3640
3760
  return [s, unescape(this.toString()), false, false];
3641
3761
  }
3642
3762
  let bodyDotAllowed = !repeated || allowDot || dot || !startNoDot ? "" : __privateMethod(this, _AST_instances, partsToRegExp_fn).call(this, true);
@@ -3705,8 +3825,9 @@ fillNegs_fn = function() {
3705
3825
  return this;
3706
3826
  };
3707
3827
  _AST_static = new WeakSet();
3708
- parseAST_fn = function(str, ast, pos, opt) {
3709
- var _a, _b;
3828
+ parseAST_fn = function(str, ast, pos, opt, extDepth) {
3829
+ var _a2, _b, _c, _d, _e;
3830
+ const maxDepth = (_a2 = opt.maxExtglobRecursion) != null ? _a2 : 2;
3710
3831
  let escaping = false;
3711
3832
  let inBrace = false;
3712
3833
  let braceStart = -1;
@@ -3738,11 +3859,12 @@ parseAST_fn = function(str, ast, pos, opt) {
3738
3859
  acc2 += c;
3739
3860
  continue;
3740
3861
  }
3741
- if (!opt.noext && isExtglobType(c) && str.charAt(i3) === "(") {
3862
+ const doRecurse = !opt.noext && isExtglobType(c) && str.charAt(i3) === "(" && extDepth <= maxDepth;
3863
+ if (doRecurse) {
3742
3864
  ast.push(acc2);
3743
3865
  acc2 = "";
3744
- const ext2 = new _AST(c, ast);
3745
- i3 = __privateMethod(_a = _AST, _AST_static, parseAST_fn).call(_a, str, ext2, i3, opt);
3866
+ const ext2 = new _a(c, ast);
3867
+ i3 = __privateMethod(_b = _a, _AST_static, parseAST_fn).call(_b, str, ext2, i3, opt, extDepth + 1);
3746
3868
  ast.push(ext2);
3747
3869
  continue;
3748
3870
  }
@@ -3752,7 +3874,7 @@ parseAST_fn = function(str, ast, pos, opt) {
3752
3874
  return i3;
3753
3875
  }
3754
3876
  let i2 = pos + 1;
3755
- let part = new _AST(null, ast);
3877
+ let part = new _a(null, ast);
3756
3878
  const parts = [];
3757
3879
  let acc = "";
3758
3880
  while (i2 < str.length) {
@@ -3779,19 +3901,22 @@ parseAST_fn = function(str, ast, pos, opt) {
3779
3901
  acc += c;
3780
3902
  continue;
3781
3903
  }
3782
- if (isExtglobType(c) && str.charAt(i2) === "(") {
3904
+ const doRecurse = isExtglobType(c) && str.charAt(i2) === "(" && /* c8 ignore start - the maxDepth is sufficient here */
3905
+ (extDepth <= maxDepth || ast && __privateMethod(_c = ast, _AST_instances, canAdoptType_fn).call(_c, c));
3906
+ if (doRecurse) {
3907
+ const depthAdd = ast && __privateMethod(_d = ast, _AST_instances, canAdoptType_fn).call(_d, c) ? 0 : 1;
3783
3908
  part.push(acc);
3784
3909
  acc = "";
3785
- const ext2 = new _AST(c, part);
3910
+ const ext2 = new _a(c, part);
3786
3911
  part.push(ext2);
3787
- i2 = __privateMethod(_b = _AST, _AST_static, parseAST_fn).call(_b, str, ext2, i2, opt);
3912
+ i2 = __privateMethod(_e = _a, _AST_static, parseAST_fn).call(_e, str, ext2, i2, opt, extDepth + depthAdd);
3788
3913
  continue;
3789
3914
  }
3790
3915
  if (c === "|") {
3791
3916
  part.push(acc);
3792
3917
  acc = "";
3793
3918
  parts.push(part);
3794
- part = new _AST(null, ast);
3919
+ part = new _a(null, ast);
3795
3920
  continue;
3796
3921
  }
3797
3922
  if (c === ")") {
@@ -3810,6 +3935,100 @@ parseAST_fn = function(str, ast, pos, opt) {
3810
3935
  __privateSet(ast, _parts, [str.substring(pos - 1)]);
3811
3936
  return i2;
3812
3937
  };
3938
+ canAdoptWithSpace_fn = function(child) {
3939
+ return __privateMethod(this, _AST_instances, canAdopt_fn).call(this, child, adoptionWithSpaceMap);
3940
+ };
3941
+ canAdopt_fn = function(child, map2 = adoptionMap) {
3942
+ if (!child || typeof child !== "object" || child.type !== null || __privateGet(child, _parts).length !== 1 || this.type === null) {
3943
+ return false;
3944
+ }
3945
+ const gc = __privateGet(child, _parts)[0];
3946
+ if (!gc || typeof gc !== "object" || gc.type === null) {
3947
+ return false;
3948
+ }
3949
+ return __privateMethod(this, _AST_instances, canAdoptType_fn).call(this, gc.type, map2);
3950
+ };
3951
+ canAdoptType_fn = function(c, map2 = adoptionAnyMap) {
3952
+ var _a2;
3953
+ return !!((_a2 = map2.get(this.type)) == null ? void 0 : _a2.includes(c));
3954
+ };
3955
+ adoptWithSpace_fn = function(child, index) {
3956
+ const gc = __privateGet(child, _parts)[0];
3957
+ const blank = new _a(null, gc, this.options);
3958
+ __privateGet(blank, _parts).push("");
3959
+ gc.push(blank);
3960
+ __privateMethod(this, _AST_instances, adopt_fn).call(this, child, index);
3961
+ };
3962
+ adopt_fn = function(child, index) {
3963
+ const gc = __privateGet(child, _parts)[0];
3964
+ __privateGet(this, _parts).splice(index, 1, ...__privateGet(gc, _parts));
3965
+ for (const p of __privateGet(gc, _parts)) {
3966
+ if (typeof p === "object")
3967
+ __privateSet(p, _parent, this);
3968
+ }
3969
+ __privateSet(this, _toString, void 0);
3970
+ };
3971
+ canUsurpType_fn = function(c) {
3972
+ const m = usurpMap.get(this.type);
3973
+ return !!(m == null ? void 0 : m.has(c));
3974
+ };
3975
+ canUsurp_fn = function(child) {
3976
+ if (!child || typeof child !== "object" || child.type !== null || __privateGet(child, _parts).length !== 1 || this.type === null || __privateGet(this, _parts).length !== 1) {
3977
+ return false;
3978
+ }
3979
+ const gc = __privateGet(child, _parts)[0];
3980
+ if (!gc || typeof gc !== "object" || gc.type === null) {
3981
+ return false;
3982
+ }
3983
+ return __privateMethod(this, _AST_instances, canUsurpType_fn).call(this, gc.type);
3984
+ };
3985
+ usurp_fn = function(child) {
3986
+ const m = usurpMap.get(this.type);
3987
+ const gc = __privateGet(child, _parts)[0];
3988
+ const nt = m == null ? void 0 : m.get(gc.type);
3989
+ if (!nt)
3990
+ return false;
3991
+ __privateSet(this, _parts, __privateGet(gc, _parts));
3992
+ for (const p of __privateGet(this, _parts)) {
3993
+ if (typeof p === "object")
3994
+ __privateSet(p, _parent, this);
3995
+ }
3996
+ this.type = nt;
3997
+ __privateSet(this, _toString, void 0);
3998
+ __privateSet(this, _emptyExt, false);
3999
+ };
4000
+ flatten_fn = function() {
4001
+ var _a2, _b;
4002
+ if (!isExtglobAST(this)) {
4003
+ for (const p of __privateGet(this, _parts)) {
4004
+ if (typeof p === "object")
4005
+ __privateMethod(_a2 = p, _AST_instances, flatten_fn).call(_a2);
4006
+ }
4007
+ } else {
4008
+ let iterations = 0;
4009
+ let done = false;
4010
+ do {
4011
+ done = true;
4012
+ for (let i2 = 0; i2 < __privateGet(this, _parts).length; i2++) {
4013
+ const c = __privateGet(this, _parts)[i2];
4014
+ if (typeof c === "object") {
4015
+ __privateMethod(_b = c, _AST_instances, flatten_fn).call(_b);
4016
+ if (__privateMethod(this, _AST_instances, canAdopt_fn).call(this, c)) {
4017
+ done = false;
4018
+ __privateMethod(this, _AST_instances, adopt_fn).call(this, c, i2);
4019
+ } else if (__privateMethod(this, _AST_instances, canAdoptWithSpace_fn).call(this, c)) {
4020
+ done = false;
4021
+ __privateMethod(this, _AST_instances, adoptWithSpace_fn).call(this, c, i2);
4022
+ } else if (__privateMethod(this, _AST_instances, canUsurp_fn).call(this, c)) {
4023
+ done = false;
4024
+ __privateMethod(this, _AST_instances, usurp_fn).call(this, c);
4025
+ }
4026
+ }
4027
+ }
4028
+ } while (!done && ++iterations < 10);
4029
+ }
4030
+ __privateSet(this, _toString, void 0);
4031
+ };
3813
4032
  partsToRegExp_fn = function(dot) {
3814
4033
  return __privateGet(this, _parts).map((p) => {
3815
4034
  if (typeof p === "string") {
@@ -3824,11 +4043,13 @@ parseGlob_fn = function(glob, hasMagic, noEmpty = false) {
3824
4043
  let escaping = false;
3825
4044
  let re = "";
3826
4045
  let uflag = false;
4046
+ let inStar = false;
3827
4047
  for (let i2 = 0; i2 < glob.length; i2++) {
3828
4048
  const c = glob.charAt(i2);
3829
4049
  if (escaping) {
3830
4050
  escaping = false;
3831
4051
  re += (reSpecials.has(c) ? "\\" : "") + c;
4052
+ inStar = false;
3832
4053
  continue;
3833
4054
  }
3834
4055
  if (c === "\\") {
@@ -3846,16 +4067,19 @@ parseGlob_fn = function(glob, hasMagic, noEmpty = false) {
3846
4067
  uflag = uflag || needUflag;
3847
4068
  i2 += consumed - 1;
3848
4069
  hasMagic = hasMagic || magic;
4070
+ inStar = false;
3849
4071
  continue;
3850
4072
  }
3851
4073
  }
3852
4074
  if (c === "*") {
3853
- if (noEmpty && glob === "*")
3854
- re += starNoEmpty;
3855
- else
3856
- re += star;
4075
+ if (inStar)
4076
+ continue;
4077
+ inStar = true;
4078
+ re += noEmpty && /^[*]+$/.test(glob) ? starNoEmpty : star;
3857
4079
  hasMagic = true;
3858
4080
  continue;
4081
+ } else {
4082
+ inStar = false;
3859
4083
  }
3860
4084
  if (c === "?") {
3861
4085
  re += qmark;
@@ -3866,8 +4090,8 @@ parseGlob_fn = function(glob, hasMagic, noEmpty = false) {
3866
4090
  }
3867
4091
  return [re, unescape(glob), !!hasMagic, uflag];
3868
4092
  };
3869
- __privateAdd(_AST, _AST_static);
3870
- var AST = _AST;
4093
+ __privateAdd(AST, _AST_static);
4094
+ _a = AST;
3871
4095
 
3872
4096
  // node_modules/minimatch/dist/esm/escape.js
3873
4097
  var escape = (s, { windowsPathsNoEscape = false } = {}) => {
@@ -4006,28 +4230,33 @@ var match = (list, pattern, options = {}) => {
4006
4230
  minimatch.match = match;
4007
4231
  var globMagic = /[?*]|[+@!]\(.*?\)|\[|\]/;
4008
4232
  var regExpEscape2 = (s) => s.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&");
4233
+ var _Minimatch_instances, matchGlobstar_fn, matchGlobStarBodySections_fn, matchOne_fn;
4009
4234
  var Minimatch = class {
4010
- options;
4011
- set;
4012
- pattern;
4013
- windowsPathsNoEscape;
4014
- nonegate;
4015
- negate;
4016
- comment;
4017
- empty;
4018
- preserveMultipleSlashes;
4019
- partial;
4020
- globSet;
4021
- globParts;
4022
- nocase;
4023
- isWindows;
4024
- platform;
4025
- windowsNoMagicRoot;
4026
- regexp;
4027
4235
  constructor(pattern, options = {}) {
4236
+ __privateAdd(this, _Minimatch_instances);
4237
+ __publicField(this, "options");
4238
+ __publicField(this, "set");
4239
+ __publicField(this, "pattern");
4240
+ __publicField(this, "windowsPathsNoEscape");
4241
+ __publicField(this, "nonegate");
4242
+ __publicField(this, "negate");
4243
+ __publicField(this, "comment");
4244
+ __publicField(this, "empty");
4245
+ __publicField(this, "preserveMultipleSlashes");
4246
+ __publicField(this, "partial");
4247
+ __publicField(this, "globSet");
4248
+ __publicField(this, "globParts");
4249
+ __publicField(this, "nocase");
4250
+ __publicField(this, "isWindows");
4251
+ __publicField(this, "platform");
4252
+ __publicField(this, "windowsNoMagicRoot");
4253
+ __publicField(this, "maxGlobstarRecursion");
4254
+ __publicField(this, "regexp");
4255
+ var _a2;
4028
4256
  assertValidPattern(pattern);
4029
4257
  options = options || {};
4030
4258
  this.options = options;
4259
+ this.maxGlobstarRecursion = (_a2 = options.maxGlobstarRecursion) != null ? _a2 : 200;
4031
4260
  this.pattern = pattern;
4032
4261
  this.platform = options.platform || defaultPlatform;
4033
4262
  this.isWindows = this.platform === "win32";
@@ -4295,10 +4524,11 @@ var Minimatch = class {
4295
4524
  for (let i2 = 0; i2 < globParts.length - 1; i2++) {
4296
4525
  for (let j = i2 + 1; j < globParts.length; j++) {
4297
4526
  const matched = this.partsMatch(globParts[i2], globParts[j], !this.preserveMultipleSlashes);
4298
- if (!matched)
4299
- continue;
4300
- globParts[i2] = matched;
4301
- globParts[j] = [];
4527
+ if (matched) {
4528
+ globParts[i2] = [];
4529
+ globParts[j] = matched;
4530
+ break;
4531
+ }
4302
4532
  }
4303
4533
  }
4304
4534
  return globParts.filter((gs) => gs.length);
@@ -4359,7 +4589,8 @@ var Minimatch = class {
4359
4589
  // out of pattern, then that's fine, as long as all
4360
4590
  // the parts match.
4361
4591
  matchOne(file, pattern, partial = false) {
4362
- const options = this.options;
4592
+ let fileStartIndex = 0;
4593
+ let patternStartIndex = 0;
4363
4594
  if (this.isWindows) {
4364
4595
  const fileDrive = typeof file[0] === "string" && /^[a-z]:$/i.test(file[0]);
4365
4596
  const fileUNC = !fileDrive && file[0] === "" && file[1] === "" && file[2] === "?" && /^[a-z]:$/i.test(file[3]);
@@ -4368,14 +4599,14 @@ var Minimatch = class {
4368
4599
  const fdi = fileUNC ? 3 : fileDrive ? 0 : void 0;
4369
4600
  const pdi = patternUNC ? 3 : patternDrive ? 0 : void 0;
4370
4601
  if (typeof fdi === "number" && typeof pdi === "number") {
4371
- const [fd, pd] = [file[fdi], pattern[pdi]];
4602
+ const [fd, pd] = [
4603
+ file[fdi],
4604
+ pattern[pdi]
4605
+ ];
4372
4606
  if (fd.toLowerCase() === pd.toLowerCase()) {
4373
4607
  pattern[pdi] = fd;
4374
- if (pdi > fdi) {
4375
- pattern = pattern.slice(pdi);
4376
- } else if (fdi > pdi) {
4377
- file = file.slice(fdi);
4378
- }
4608
+ patternStartIndex = pdi;
4609
+ fileStartIndex = fdi;
4379
4610
  }
4380
4611
  }
4381
4612
  }
@@ -4383,71 +4614,10 @@ var Minimatch = class {
4383
4614
  if (optimizationLevel >= 2) {
4384
4615
  file = this.levelTwoFileOptimize(file);
4385
4616
  }
4386
- this.debug("matchOne", this, { file, pattern });
4387
- this.debug("matchOne", file.length, pattern.length);
4388
- for (var fi = 0, pi = 0, fl = file.length, pl = pattern.length; fi < fl && pi < pl; fi++, pi++) {
4389
- this.debug("matchOne loop");
4390
- var p = pattern[pi];
4391
- var f = file[fi];
4392
- this.debug(pattern, p, f);
4393
- if (p === false) {
4394
- return false;
4395
- }
4396
- if (p === GLOBSTAR) {
4397
- this.debug("GLOBSTAR", [pattern, p, f]);
4398
- var fr = fi;
4399
- var pr = pi + 1;
4400
- if (pr === pl) {
4401
- this.debug("** at the end");
4402
- for (; fi < fl; fi++) {
4403
- if (file[fi] === "." || file[fi] === ".." || !options.dot && file[fi].charAt(0) === ".")
4404
- return false;
4405
- }
4406
- return true;
4407
- }
4408
- while (fr < fl) {
4409
- var swallowee = file[fr];
4410
- this.debug("\nglobstar while", file, fr, pattern, pr, swallowee);
4411
- if (this.matchOne(file.slice(fr), pattern.slice(pr), partial)) {
4412
- this.debug("globstar found match!", fr, fl, swallowee);
4413
- return true;
4414
- } else {
4415
- if (swallowee === "." || swallowee === ".." || !options.dot && swallowee.charAt(0) === ".") {
4416
- this.debug("dot detected!", file, fr, pattern, pr);
4417
- break;
4418
- }
4419
- this.debug("globstar swallow a segment, and continue");
4420
- fr++;
4421
- }
4422
- }
4423
- if (partial) {
4424
- this.debug("\n>>> no match, partial?", file, fr, pattern, pr);
4425
- if (fr === fl) {
4426
- return true;
4427
- }
4428
- }
4429
- return false;
4430
- }
4431
- let hit;
4432
- if (typeof p === "string") {
4433
- hit = f === p;
4434
- this.debug("string match", p, f, hit);
4435
- } else {
4436
- hit = p.test(f);
4437
- this.debug("pattern match", p, f, hit);
4438
- }
4439
- if (!hit)
4440
- return false;
4441
- }
4442
- if (fi === fl && pi === pl) {
4443
- return true;
4444
- } else if (fi === fl) {
4445
- return partial;
4446
- } else if (pi === pl) {
4447
- return fi === fl - 1 && file[fi] === "";
4448
- } else {
4449
- throw new Error("wtf?");
4617
+ if (pattern.includes(GLOBSTAR)) {
4618
+ return __privateMethod(this, _Minimatch_instances, matchGlobstar_fn).call(this, file, pattern, partial, fileStartIndex, patternStartIndex);
4450
4619
  }
4620
+ return __privateMethod(this, _Minimatch_instances, matchOne_fn).call(this, file, pattern, partial, fileStartIndex, patternStartIndex);
4451
4621
  }
4452
4622
  braceExpand() {
4453
4623
  return braceExpand(this.pattern, this.options);
@@ -4586,6 +4756,135 @@ var Minimatch = class {
4586
4756
  return minimatch.defaults(def).Minimatch;
4587
4757
  }
4588
4758
  };
4759
+ _Minimatch_instances = new WeakSet();
4760
+ matchGlobstar_fn = function(file, pattern, partial, fileIndex, patternIndex) {
4761
+ const firstgs = pattern.indexOf(GLOBSTAR, patternIndex);
4762
+ const lastgs = pattern.lastIndexOf(GLOBSTAR);
4763
+ const [head, body, tail] = partial ? [
4764
+ pattern.slice(patternIndex, firstgs),
4765
+ pattern.slice(firstgs + 1),
4766
+ []
4767
+ ] : [
4768
+ pattern.slice(patternIndex, firstgs),
4769
+ pattern.slice(firstgs + 1, lastgs),
4770
+ pattern.slice(lastgs + 1)
4771
+ ];
4772
+ if (head.length) {
4773
+ const fileHead = file.slice(fileIndex, fileIndex + head.length);
4774
+ if (!__privateMethod(this, _Minimatch_instances, matchOne_fn).call(this, fileHead, head, partial, 0, 0))
4775
+ return false;
4776
+ fileIndex += head.length;
4777
+ }
4778
+ let fileTailMatch = 0;
4779
+ if (tail.length) {
4780
+ if (tail.length + fileIndex > file.length)
4781
+ return false;
4782
+ let tailStart = file.length - tail.length;
4783
+ if (__privateMethod(this, _Minimatch_instances, matchOne_fn).call(this, file, tail, partial, tailStart, 0)) {
4784
+ fileTailMatch = tail.length;
4785
+ } else {
4786
+ if (file[file.length - 1] !== "" || fileIndex + tail.length === file.length) {
4787
+ return false;
4788
+ }
4789
+ tailStart--;
4790
+ if (!__privateMethod(this, _Minimatch_instances, matchOne_fn).call(this, file, tail, partial, tailStart, 0))
4791
+ return false;
4792
+ fileTailMatch = tail.length + 1;
4793
+ }
4794
+ }
4795
+ if (!body.length) {
4796
+ let sawSome = !!fileTailMatch;
4797
+ for (let i3 = fileIndex; i3 < file.length - fileTailMatch; i3++) {
4798
+ const f = String(file[i3]);
4799
+ sawSome = true;
4800
+ if (f === "." || f === ".." || !this.options.dot && f.startsWith(".")) {
4801
+ return false;
4802
+ }
4803
+ }
4804
+ return partial || sawSome;
4805
+ }
4806
+ const bodySegments = [[[], 0]];
4807
+ let currentBody = bodySegments[0];
4808
+ let nonGsParts = 0;
4809
+ const nonGsPartsSums = [0];
4810
+ for (const b of body) {
4811
+ if (b === GLOBSTAR) {
4812
+ nonGsPartsSums.push(nonGsParts);
4813
+ currentBody = [[], 0];
4814
+ bodySegments.push(currentBody);
4815
+ } else {
4816
+ currentBody[0].push(b);
4817
+ nonGsParts++;
4818
+ }
4819
+ }
4820
+ let i2 = bodySegments.length - 1;
4821
+ const fileLength = file.length - fileTailMatch;
4822
+ for (const b of bodySegments) {
4823
+ b[1] = fileLength - (nonGsPartsSums[i2--] + b[0].length);
4824
+ }
4825
+ return !!__privateMethod(this, _Minimatch_instances, matchGlobStarBodySections_fn).call(this, file, bodySegments, fileIndex, 0, partial, 0, !!fileTailMatch);
4826
+ };
4827
+ matchGlobStarBodySections_fn = function(file, bodySegments, fileIndex, bodyIndex, partial, globStarDepth, sawTail) {
4828
+ const bs = bodySegments[bodyIndex];
4829
+ if (!bs) {
4830
+ for (let i2 = fileIndex; i2 < file.length; i2++) {
4831
+ sawTail = true;
4832
+ const f = file[i2];
4833
+ if (f === "." || f === ".." || !this.options.dot && f.startsWith(".")) {
4834
+ return false;
4835
+ }
4836
+ }
4837
+ return sawTail;
4838
+ }
4839
+ const [body, after] = bs;
4840
+ while (fileIndex <= after) {
4841
+ const m = __privateMethod(this, _Minimatch_instances, matchOne_fn).call(this, file.slice(0, fileIndex + body.length), body, partial, fileIndex, 0);
4842
+ if (m && globStarDepth < this.maxGlobstarRecursion) {
4843
+ const sub = __privateMethod(this, _Minimatch_instances, matchGlobStarBodySections_fn).call(this, file, bodySegments, fileIndex + body.length, bodyIndex + 1, partial, globStarDepth + 1, sawTail);
4844
+ if (sub !== false)
4845
+ return sub;
4846
+ }
4847
+ const f = file[fileIndex];
4848
+ if (f === "." || f === ".." || !this.options.dot && f.startsWith(".")) {
4849
+ return false;
4850
+ }
4851
+ fileIndex++;
4852
+ }
4853
+ return partial || null;
4854
+ };
4855
+ matchOne_fn = function(file, pattern, partial, fileIndex, patternIndex) {
4856
+ let fi;
4857
+ let pi;
4858
+ let pl;
4859
+ let fl;
4860
+ for (fi = fileIndex, pi = patternIndex, fl = file.length, pl = pattern.length; fi < fl && pi < pl; fi++, pi++) {
4861
+ this.debug("matchOne loop");
4862
+ let p = pattern[pi];
4863
+ let f = file[fi];
4864
+ this.debug(pattern, p, f);
4865
+ if (p === false || p === GLOBSTAR)
4866
+ return false;
4867
+ let hit;
4868
+ if (typeof p === "string") {
4869
+ hit = f === p;
4870
+ this.debug("string match", p, f, hit);
4871
+ } else {
4872
+ hit = p.test(f);
4873
+ this.debug("pattern match", p, f, hit);
4874
+ }
4875
+ if (!hit)
4876
+ return false;
4877
+ }
4878
+ if (fi === fl && pi === pl) {
4879
+ return true;
4880
+ } else if (fi === fl) {
4881
+ return partial;
4882
+ } else if (pi === pl) {
4883
+ return fi === fl - 1 && file[fi] === "";
4884
+ } else {
4885
+ throw new Error("wtf?");
4886
+ }
4887
+ };
4589
4888
  minimatch.AST = AST;
4590
4889
  minimatch.Minimatch = Minimatch;
4591
4890
  minimatch.escape = escape;
@@ -4659,7 +4958,7 @@ function proxyHostElement(elm, cstr) {
4659
4958
  const hostRef = getHostRef(elm);
4660
4959
  const members = Object.entries(cmpMeta.$members$);
4661
4960
  members.forEach(([memberName, [memberFlags, metaAttributeName]]) => {
4662
- var _a, _b;
4961
+ var _a2, _b;
4663
4962
  if (memberFlags & 31 /* Prop */) {
4664
4963
  const attributeName = metaAttributeName || memberName;
4665
4964
  const attrValue = elm.getAttribute(attributeName);
@@ -4667,7 +4966,7 @@ function proxyHostElement(elm, cstr) {
4667
4966
  let attrPropVal;
4668
4967
  const { get: origGetter, set: origSetter } = Object.getOwnPropertyDescriptor(cstr.prototype, memberName) || {};
4669
4968
  if (attrValue != null) {
4670
- if ((_a = cmpMeta.$deserializers$) == null ? void 0 : _a[memberName]) {
4969
+ if ((_a2 = cmpMeta.$deserializers$) == null ? void 0 : _a2[memberName]) {
4671
4970
  for (const deserializer of cmpMeta.$deserializers$[memberName]) {
4672
4971
  const [[methodName]] = Object.entries(deserializer);
4673
4972
  attrPropVal = cstr.prototype[methodName](attrValue, memberName);
@@ -4700,8 +4999,8 @@ function proxyHostElement(elm, cstr) {
4700
4999
  Object.defineProperty(elm, memberName, getterSetterDescriptor);
4701
5000
  Object.defineProperty(elm, metaAttributeName, getterSetterDescriptor);
4702
5001
  hostRef.$fetchedCbList$.push(() => {
4703
- var _a2;
4704
- if (!((_a2 = hostRef == null ? void 0 : hostRef.$instanceValues$) == null ? void 0 : _a2.has(memberName))) {
5002
+ var _a3;
5003
+ if (!((_a3 = hostRef == null ? void 0 : hostRef.$instanceValues$) == null ? void 0 : _a3.has(memberName))) {
4705
5004
  setValue(
4706
5005
  elm,
4707
5006
  memberName,
@@ -4714,11 +5013,11 @@ function proxyHostElement(elm, cstr) {
4714
5013
  } else if (memberFlags & 64 /* Method */) {
4715
5014
  Object.defineProperty(elm, memberName, {
4716
5015
  value(...args) {
4717
- var _a2;
5016
+ var _a3;
4718
5017
  const ref = getHostRef(this);
4719
- return (_a2 = ref == null ? void 0 : ref.$onInstancePromise$) == null ? void 0 : _a2.then(() => {
4720
- var _a3;
4721
- return (_a3 = ref == null ? void 0 : ref.$lazyInstance$) == null ? void 0 : _a3[memberName](...args);
5018
+ return (_a3 = ref == null ? void 0 : ref.$onInstancePromise$) == null ? void 0 : _a3.then(() => {
5019
+ var _a4;
5020
+ return (_a4 = ref == null ? void 0 : ref.$lazyInstance$) == null ? void 0 : _a4[memberName](...args);
4722
5021
  }).catch((e) => {
4723
5022
  consoleError(e, this);
4724
5023
  });
@@ -4729,14 +5028,14 @@ function proxyHostElement(elm, cstr) {
4729
5028
  }
4730
5029
  }
4731
5030
  function componentOnReady() {
4732
- var _a;
4733
- return (_a = getHostRef(this)) == null ? void 0 : _a.$onReadyPromise$;
5031
+ var _a2;
5032
+ return (_a2 = getHostRef(this)) == null ? void 0 : _a2.$onReadyPromise$;
4734
5033
  }
4735
5034
  function forceUpdate2() {
4736
5035
  }
4737
5036
 
4738
5037
  // src/hydrate/platform/hydrate-app.ts
4739
- function hydrateApp(win2, opts, results, afterHydrate, resolve) {
5038
+ function hydrateApp(win2, opts, results, afterHydrate, resolve, abortController) {
4740
5039
  const connectedElements = /* @__PURE__ */ new Set();
4741
5040
  const createdElements = /* @__PURE__ */ new Set();
4742
5041
  const waitingElements = /* @__PURE__ */ new Set();
@@ -4746,6 +5045,13 @@ function hydrateApp(win2, opts, results, afterHydrate, resolve) {
4746
5045
  setScopedSSR(opts);
4747
5046
  let tmrId;
4748
5047
  let ranCompleted = false;
5048
+ const abortedPromise = new Promise((res) => {
5049
+ if (abortController.signal.aborted) {
5050
+ res();
5051
+ } else {
5052
+ abortController.signal.addEventListener("abort", () => res(), { once: true });
5053
+ }
5054
+ });
4749
5055
  function hydratedComplete() {
4750
5056
  globalThis.clearTimeout(tmrId);
4751
5057
  createdElements.clear();
@@ -4767,6 +5073,7 @@ function hydrateApp(win2, opts, results, afterHydrate, resolve) {
4767
5073
  }
4768
5074
  function hydratedError(err2) {
4769
5075
  renderCatchError(opts, results, err2);
5076
+ abortController.abort();
4770
5077
  hydratedComplete();
4771
5078
  }
4772
5079
  function timeoutExceeded() {
@@ -4812,7 +5119,7 @@ function hydrateApp(win2, opts, results, afterHydrate, resolve) {
4812
5119
  if (isValidComponent(elm, opts) && results.hydratedCount < opts.maxHydrateCount) {
4813
5120
  if (!connectedElements.has(elm) && shouldHydrate(elm)) {
4814
5121
  connectedElements.add(elm);
4815
- return hydrateComponent.call(elm, win2, results, elm.nodeName, elm, waitingElements);
5122
+ return hydrateComponent.call(elm, win2, results, elm.nodeName, elm, waitingElements, abortedPromise);
4816
5123
  }
4817
5124
  }
4818
5125
  return resolved2;
@@ -4841,7 +5148,7 @@ function hydrateApp(win2, opts, results, afterHydrate, resolve) {
4841
5148
  hydratedError(e);
4842
5149
  }
4843
5150
  }
4844
- async function hydrateComponent(win2, results, tagName, elm, waitingElements) {
5151
+ async function hydrateComponent(win2, results, tagName, elm, waitingElements, aborted) {
4845
5152
  tagName = tagName.toLowerCase();
4846
5153
  const Cstr = loadModule(
4847
5154
  {
@@ -4856,17 +5163,19 @@ async function hydrateComponent(win2, results, tagName, elm, waitingElements) {
4856
5163
  }
4857
5164
  try {
4858
5165
  connectedCallback(elm);
4859
- await elm.componentOnReady();
4860
- results.hydratedCount++;
4861
- const ref = getHostRef(elm);
4862
- const modeName = !(ref == null ? void 0 : ref.$modeName$) ? "$" : ref == null ? void 0 : ref.$modeName$;
4863
- if (!results.components.some((c) => c.tag === tagName && c.mode === modeName)) {
4864
- results.components.push({
4865
- tag: tagName,
4866
- mode: modeName,
4867
- count: 0,
4868
- depth: -1
4869
- });
5166
+ const wasAborted = await Promise.race([elm.componentOnReady().then(() => false), aborted.then(() => true)]);
5167
+ if (!wasAborted) {
5168
+ results.hydratedCount++;
5169
+ const ref = getHostRef(elm);
5170
+ const modeName = !(ref == null ? void 0 : ref.$modeName$) ? "$" : ref == null ? void 0 : ref.$modeName$;
5171
+ if (!results.components.some((c) => c.tag === tagName && c.mode === modeName)) {
5172
+ results.components.push({
5173
+ tag: tagName,
5174
+ mode: modeName,
5175
+ count: 0,
5176
+ depth: -1
5177
+ });
5178
+ }
4870
5179
  }
4871
5180
  } catch (e) {
4872
5181
  win2.console.error(e);
@@ -8348,7 +8657,7 @@ exports.hydrateApp = hydrateApp;
8348
8657
 
8349
8658
 
8350
8659
  /*hydrateAppClosure end*/
8351
- hydrateApp(window, $stencilHydrateOpts, $stencilHydrateResults, $stencilAfterHydrate, $stencilHydrateResolve);
8660
+ hydrateApp(window, $stencilHydrateOpts, $stencilHydrateResults, $stencilAfterHydrate, $stencilHydrateResolve, $stencilAbortController);
8352
8661
  }
8353
8662
 
8354
8663
  hydrateAppClosure($stencilWindow);
@@ -8443,7 +8752,7 @@ var NAMESPACE = (
8443
8752
  );
8444
8753
 
8445
8754
  /*
8446
- Stencil Hydrate Runner v4.43.2 | MIT Licensed | https://stenciljs.com
8755
+ Stencil Hydrate Runner v4.45.0 | MIT Licensed | https://stenciljs.com
8447
8756
  */
8448
8757
  var __create = Object.create;
8449
8758
  var __defProp = Object.defineProperty;
@@ -9774,11 +10083,11 @@ var fromCodePoint = (
9774
10083
  }
9775
10084
  );
9776
10085
  function replaceCodePoint(codePoint) {
9777
- var _a2;
10086
+ var _a3;
9778
10087
  if (codePoint >= 55296 && codePoint <= 57343 || codePoint > 1114111) {
9779
10088
  return 65533;
9780
10089
  }
9781
- return (_a2 = decodeMap.get(codePoint)) !== null && _a2 !== void 0 ? _a2 : codePoint;
10090
+ return (_a3 = decodeMap.get(codePoint)) !== null && _a3 !== void 0 ? _a3 : codePoint;
9782
10091
  }
9783
10092
 
9784
10093
  // node_modules/entities/lib/esm/decode.js
@@ -9975,9 +10284,9 @@ var EntityDecoder = class {
9975
10284
  * @returns The number of characters that were consumed.
9976
10285
  */
9977
10286
  emitNumericEntity(lastCp, expectedLength) {
9978
- var _a2;
10287
+ var _a3;
9979
10288
  if (this.consumed <= expectedLength) {
9980
- (_a2 = this.errors) === null || _a2 === void 0 ? void 0 : _a2.absenceOfDigitsInNumericCharacterReference(this.consumed);
10289
+ (_a3 = this.errors) === null || _a3 === void 0 ? void 0 : _a3.absenceOfDigitsInNumericCharacterReference(this.consumed);
9981
10290
  return 0;
9982
10291
  }
9983
10292
  if (lastCp === CharCodes.SEMI) {
@@ -10037,11 +10346,11 @@ var EntityDecoder = class {
10037
10346
  * @returns The number of characters consumed.
10038
10347
  */
10039
10348
  emitNotTerminatedNamedEntity() {
10040
- var _a2;
10349
+ var _a3;
10041
10350
  const { result, decodeTree } = this;
10042
10351
  const valueLength = (decodeTree[result] & BinTrieFlags.VALUE_LENGTH) >> 14;
10043
10352
  this.emitNamedEntityData(result, valueLength, this.consumed);
10044
- (_a2 = this.errors) === null || _a2 === void 0 ? void 0 : _a2.missingSemicolonAfterCharacterReference();
10353
+ (_a3 = this.errors) === null || _a3 === void 0 ? void 0 : _a3.missingSemicolonAfterCharacterReference();
10045
10354
  return this.consumed;
10046
10355
  }
10047
10356
  /**
@@ -10069,7 +10378,7 @@ var EntityDecoder = class {
10069
10378
  * @returns The number of characters consumed.
10070
10379
  */
10071
10380
  end() {
10072
- var _a2;
10381
+ var _a3;
10073
10382
  switch (this.state) {
10074
10383
  case EntityDecoderState.NamedEntity: {
10075
10384
  return this.result !== 0 && (this.decodeMode !== DecodingMode.Attribute || this.result === this.treeIndex) ? this.emitNotTerminatedNamedEntity() : 0;
@@ -10082,7 +10391,7 @@ var EntityDecoder = class {
10082
10391
  return this.emitNumericEntity(0, 3);
10083
10392
  }
10084
10393
  case EntityDecoderState.NumericStart: {
10085
- (_a2 = this.errors) === null || _a2 === void 0 ? void 0 : _a2.absenceOfDigitsInNumericCharacterReference(this.consumed);
10394
+ (_a3 = this.errors) === null || _a3 === void 0 ? void 0 : _a3.absenceOfDigitsInNumericCharacterReference(this.consumed);
10086
10395
  return 0;
10087
10396
  }
10088
10397
  case EntityDecoderState.EntityStart: {
@@ -10563,8 +10872,8 @@ var TAG_NAME_TO_ID = /* @__PURE__ */ new Map([
10563
10872
  [TAG_NAMES.XMP, TAG_ID.XMP]
10564
10873
  ]);
10565
10874
  function getTagID(tagName) {
10566
- var _a2;
10567
- return (_a2 = TAG_NAME_TO_ID.get(tagName)) !== null && _a2 !== void 0 ? _a2 : TAG_ID.UNKNOWN;
10875
+ var _a3;
10876
+ return (_a3 = TAG_NAME_TO_ID.get(tagName)) !== null && _a3 !== void 0 ? _a3 : TAG_ID.UNKNOWN;
10568
10877
  }
10569
10878
  var $ = TAG_ID;
10570
10879
  var SPECIAL_ELEMENTS = {
@@ -10831,8 +11140,8 @@ var Tokenizer = class {
10831
11140
  }
10832
11141
  //Errors
10833
11142
  _err(code, cpOffset = 0) {
10834
- var _a2, _b;
10835
- (_b = (_a2 = this.handler).onParseError) === null || _b === void 0 ? void 0 : _b.call(_a2, this.preprocessor.getError(code, cpOffset));
11143
+ var _a3, _b;
11144
+ (_b = (_a3 = this.handler).onParseError) === null || _b === void 0 ? void 0 : _b.call(_a3, this.preprocessor.getError(code, cpOffset));
10836
11145
  }
10837
11146
  // NOTE: `offset` may never run across line boundaries.
10838
11147
  getCurrentLocation(offset) {
@@ -10974,13 +11283,13 @@ var Tokenizer = class {
10974
11283
  this.currentLocation = this.getCurrentLocation(0);
10975
11284
  }
10976
11285
  _leaveAttrName() {
10977
- var _a2;
11286
+ var _a3;
10978
11287
  var _b;
10979
11288
  const token = this.currentToken;
10980
11289
  if (getTokenAttr(token, this.currentAttr.name) === null) {
10981
11290
  token.attrs.push(this.currentAttr);
10982
11291
  if (token.location && this.currentLocation) {
10983
- const attrLocations = (_a2 = (_b = token.location).attrs) !== null && _a2 !== void 0 ? _a2 : _b.attrs = /* @__PURE__ */ Object.create(null);
11292
+ const attrLocations = (_a3 = (_b = token.location).attrs) !== null && _a3 !== void 0 ? _a3 : _b.attrs = /* @__PURE__ */ Object.create(null);
10984
11293
  attrLocations[this.currentAttr.name] = this.currentLocation;
10985
11294
  this._leaveAttrValue();
10986
11295
  }
@@ -14328,10 +14637,10 @@ var Parser = class {
14328
14637
  //Errors
14329
14638
  /** @internal */
14330
14639
  _err(token, code, beforeToken) {
14331
- var _a2;
14640
+ var _a3;
14332
14641
  if (!this.onParseError)
14333
14642
  return;
14334
- const loc = (_a2 = token.location) !== null && _a2 !== void 0 ? _a2 : BASE_LOC;
14643
+ const loc = (_a3 = token.location) !== null && _a3 !== void 0 ? _a3 : BASE_LOC;
14335
14644
  const err2 = {
14336
14645
  code,
14337
14646
  startLine: loc.startLine,
@@ -14346,18 +14655,18 @@ var Parser = class {
14346
14655
  //Stack events
14347
14656
  /** @internal */
14348
14657
  onItemPush(node, tid, isTop) {
14349
- var _a2, _b;
14350
- (_b = (_a2 = this.treeAdapter).onItemPush) === null || _b === void 0 ? void 0 : _b.call(_a2, node);
14658
+ var _a3, _b;
14659
+ (_b = (_a3 = this.treeAdapter).onItemPush) === null || _b === void 0 ? void 0 : _b.call(_a3, node);
14351
14660
  if (isTop && this.openElements.stackTop > 0)
14352
14661
  this._setContextModes(node, tid);
14353
14662
  }
14354
14663
  /** @internal */
14355
14664
  onItemPop(node, isTop) {
14356
- var _a2, _b;
14665
+ var _a3, _b;
14357
14666
  if (this.options.sourceCodeLocationInfo) {
14358
14667
  this._setEndLocation(node, this.currentToken);
14359
14668
  }
14360
- (_b = (_a2 = this.treeAdapter).onItemPop) === null || _b === void 0 ? void 0 : _b.call(_a2, node, this.openElements.current);
14669
+ (_b = (_a3 = this.treeAdapter).onItemPop) === null || _b === void 0 ? void 0 : _b.call(_a3, node, this.openElements.current);
14361
14670
  if (isTop) {
14362
14671
  let current;
14363
14672
  let currentTagId;
@@ -16431,9 +16740,9 @@ function eofInBody(p, token) {
16431
16740
  }
16432
16741
  }
16433
16742
  function endTagInText(p, token) {
16434
- var _a2;
16743
+ var _a3;
16435
16744
  if (token.tagID === TAG_ID.SCRIPT) {
16436
- (_a2 = p.scriptHandler) === null || _a2 === void 0 ? void 0 : _a2.call(p, p.openElements.current);
16745
+ (_a3 = p.scriptHandler) === null || _a3 === void 0 ? void 0 : _a3.call(p, p.openElements.current);
16437
16746
  }
16438
16747
  p.openElements.pop();
16439
16748
  p.insertionMode = p.originalInsertionMode;
@@ -17095,7 +17404,7 @@ function startTagAfterBody(p, token) {
17095
17404
  }
17096
17405
  }
17097
17406
  function endTagAfterBody(p, token) {
17098
- var _a2;
17407
+ var _a3;
17099
17408
  if (token.tagID === TAG_ID.HTML) {
17100
17409
  if (!p.fragmentContext) {
17101
17410
  p.insertionMode = InsertionMode.AFTER_AFTER_BODY;
@@ -17103,7 +17412,7 @@ function endTagAfterBody(p, token) {
17103
17412
  if (p.options.sourceCodeLocationInfo && p.openElements.tagIDs[0] === TAG_ID.HTML) {
17104
17413
  p._setEndLocation(p.openElements.items[0], token);
17105
17414
  const bodyElement = p.openElements.items[1];
17106
- if (bodyElement && !((_a2 = p.treeAdapter.getNodeSourceCodeLocation(bodyElement)) === null || _a2 === void 0 ? void 0 : _a2.endTag)) {
17415
+ if (bodyElement && !((_a3 = p.treeAdapter.getNodeSourceCodeLocation(bodyElement)) === null || _a3 === void 0 ? void 0 : _a3.endTag)) {
17107
17416
  p._setEndLocation(bodyElement, token);
17108
17417
  }
17109
17418
  }
@@ -18967,7 +19276,7 @@ function serializeNodeToHtml(elm, serializationOptions = {}) {
18967
19276
  }
18968
19277
  var shadowRootTag = "mock:shadow-root";
18969
19278
  function* streamToHtml(node, opts, output) {
18970
- var _a2, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p;
19279
+ var _a3, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p;
18971
19280
  const isShadowRoot = node.nodeType === 11 /* DOCUMENT_FRAGMENT_NODE */;
18972
19281
  if (node.nodeType === 1 /* ELEMENT_NODE */ || isShadowRoot) {
18973
19282
  const tagName = isShadowRoot ? shadowRootTag : getTagName(node);
@@ -18976,7 +19285,7 @@ function* streamToHtml(node, opts, output) {
18976
19285
  }
18977
19286
  const ignoreTag = opts.excludeTags != null && opts.excludeTags.includes(tagName);
18978
19287
  if (ignoreTag === false) {
18979
- const isWithinWhitespaceSensitiveNode = opts.newLines || ((_a2 = opts.indentSpaces) != null ? _a2 : 0) > 0 ? isWithinWhitespaceSensitive(node) : false;
19288
+ const isWithinWhitespaceSensitiveNode = opts.newLines || ((_a3 = opts.indentSpaces) != null ? _a3 : 0) > 0 ? isWithinWhitespaceSensitive(node) : false;
18980
19289
  if (opts.newLines && !isWithinWhitespaceSensitiveNode) {
18981
19290
  yield "\n";
18982
19291
  output.currentLineWidth = 0;
@@ -19495,9 +19804,7 @@ var MockNode2 = class {
19495
19804
  const firstChild = this.firstChild;
19496
19805
  items.forEach((item) => {
19497
19806
  const isNode = typeof item === "object" && item !== null && "nodeType" in item;
19498
- if (firstChild) {
19499
- this.insertBefore(isNode ? item : this.ownerDocument.createTextNode(String(item)), firstChild);
19500
- }
19807
+ this.insertBefore(isNode ? item : this.ownerDocument.createTextNode(String(item)), firstChild);
19501
19808
  });
19502
19809
  }
19503
19810
  cloneNode(deep) {
@@ -19546,8 +19853,8 @@ var MockNode2 = class {
19546
19853
  return null;
19547
19854
  }
19548
19855
  get nodeValue() {
19549
- var _a2;
19550
- return (_a2 = this._nodeValue) != null ? _a2 : "";
19856
+ var _a3;
19857
+ return (_a3 = this._nodeValue) != null ? _a3 : "";
19551
19858
  }
19552
19859
  set nodeValue(value) {
19553
19860
  this._nodeValue = value;
@@ -19607,8 +19914,8 @@ var MockNode2 = class {
19607
19914
  return null;
19608
19915
  }
19609
19916
  get textContent() {
19610
- var _a2;
19611
- return (_a2 = this._nodeValue) != null ? _a2 : "";
19917
+ var _a3;
19918
+ return (_a3 = this._nodeValue) != null ? _a3 : "";
19612
19919
  }
19613
19920
  set textContent(value) {
19614
19921
  this._nodeValue = String(value);
@@ -19667,9 +19974,9 @@ var MockElement = class extends MockNode2 {
19667
19974
  addEventListener(this, type, handler);
19668
19975
  }
19669
19976
  attachShadow(_opts) {
19670
- var _a2;
19977
+ var _a3;
19671
19978
  const shadowRoot = this.ownerDocument.createDocumentFragment();
19672
- shadowRoot.delegatesFocus = (_a2 = _opts.delegatesFocus) != null ? _a2 : false;
19979
+ shadowRoot.delegatesFocus = (_a3 = _opts.delegatesFocus) != null ? _a3 : false;
19673
19980
  this.shadowRoot = shadowRoot;
19674
19981
  return shadowRoot;
19675
19982
  }
@@ -19845,8 +20152,8 @@ var MockElement = class extends MockNode2 {
19845
20152
  });
19846
20153
  }
19847
20154
  set innerHTML(html) {
19848
- var _a2;
19849
- if (NON_ESCAPABLE_CONTENT.has((_a2 = this.nodeName) != null ? _a2 : "") === true) {
20155
+ var _a3;
20156
+ if (NON_ESCAPABLE_CONTENT.has((_a3 = this.nodeName) != null ? _a3 : "") === true) {
19850
20157
  setTextContent(this, html);
19851
20158
  } else {
19852
20159
  for (let i = this.childNodes.length - 1; i >= 0; i--) {
@@ -20089,8 +20396,8 @@ var MockElement = class extends MockNode2 {
20089
20396
  this.setAttributeNS(null, "tabindex", value);
20090
20397
  }
20091
20398
  get tagName() {
20092
- var _a2;
20093
- return (_a2 = this.nodeName) != null ? _a2 : "";
20399
+ var _a3;
20400
+ return (_a3 = this.nodeName) != null ? _a3 : "";
20094
20401
  }
20095
20402
  set tagName(value) {
20096
20403
  this.nodeName = value;
@@ -20312,11 +20619,11 @@ function getElementsByClassName(elm, classNames, foundElms) {
20312
20619
  }
20313
20620
  }
20314
20621
  function getElementsByTagName(elm, tagName, foundElms) {
20315
- var _a2;
20622
+ var _a3;
20316
20623
  const children = elm.children;
20317
20624
  for (let i = 0, ii = children.length; i < ii; i++) {
20318
20625
  const childElm = children[i];
20319
- if (tagName === "*" || ((_a2 = childElm.nodeName) != null ? _a2 : "").toLowerCase() === tagName) {
20626
+ if (tagName === "*" || ((_a3 = childElm.nodeName) != null ? _a3 : "").toLowerCase() === tagName) {
20320
20627
  foundElms.push(childElm);
20321
20628
  }
20322
20629
  getElementsByTagName(childElm, tagName, foundElms);
@@ -20353,8 +20660,8 @@ var MockHTMLElement = class extends MockElement {
20353
20660
  super(ownerDocument, typeof nodeName === "string" ? nodeName.toUpperCase() : null);
20354
20661
  }
20355
20662
  get tagName() {
20356
- var _a2;
20357
- return (_a2 = this.nodeName) != null ? _a2 : "";
20663
+ var _a3;
20664
+ return (_a3 = this.nodeName) != null ? _a3 : "";
20358
20665
  }
20359
20666
  set tagName(value) {
20360
20667
  this.nodeName = value;
@@ -20812,10 +21119,10 @@ var MockLabelElement = class extends MockHTMLElement {
20812
21119
  this.setAttributeNS(null, "for", value);
20813
21120
  }
20814
21121
  get control() {
20815
- var _a2, _b;
21122
+ var _a3, _b;
20816
21123
  const forAttr = this.htmlFor;
20817
21124
  if (forAttr) {
20818
- return (_b = (_a2 = this.ownerDocument) == null ? void 0 : _a2.getElementById(forAttr)) != null ? _b : null;
21125
+ return (_b = (_a3 = this.ownerDocument) == null ? void 0 : _a3.getElementById(forAttr)) != null ? _b : null;
20819
21126
  }
20820
21127
  const labelableSelector = 'button, input:not([type="hidden"]), meter, output, progress, select, textarea';
20821
21128
  return this.querySelector(labelableSelector);
@@ -22592,11 +22899,14 @@ function resetWindow(win2) {
22592
22899
  } catch (e) {
22593
22900
  }
22594
22901
  }
22595
- win2.fetch = null;
22596
- win2.Headers = null;
22597
- win2.Request = null;
22598
- win2.Response = null;
22599
- win2.FetchError = null;
22902
+ const windowDestroyed = () => {
22903
+ throw new Error("MockWindow was already destroyed");
22904
+ };
22905
+ win2.fetch = windowDestroyed;
22906
+ win2.Headers = windowDestroyed;
22907
+ win2.Request = windowDestroyed;
22908
+ win2.Response = windowDestroyed;
22909
+ win2.FetchError = windowDestroyed;
22600
22910
  }
22601
22911
  }
22602
22912
  function resetWindowDimensions(win2) {
@@ -23323,18 +23633,34 @@ var RemoteValue = class _RemoteValue {
23323
23633
  };
23324
23634
 
23325
23635
  // src/utils/serialize.ts
23636
+ function encodeBase64Unicode(str) {
23637
+ const utf8Bytes = new TextEncoder().encode(str);
23638
+ let binary = "";
23639
+ for (let i = 0; i < utf8Bytes.length; i++) {
23640
+ binary += String.fromCharCode(utf8Bytes[i]);
23641
+ }
23642
+ return btoa(binary);
23643
+ }
23644
+ function decodeBase64Unicode(base64) {
23645
+ const binary = atob(base64);
23646
+ const bytes = new Uint8Array(binary.length);
23647
+ for (let i = 0; i < binary.length; i++) {
23648
+ bytes[i] = binary.charCodeAt(i);
23649
+ }
23650
+ return new TextDecoder().decode(bytes);
23651
+ }
23326
23652
  function serializeProperty(value) {
23327
23653
  if (["string", "boolean", "undefined"].includes(typeof value) || typeof value === "number" && value !== Infinity && value !== -Infinity && !isNaN(value)) {
23328
23654
  return value;
23329
23655
  }
23330
23656
  const arg = LocalValue.getArgument(value);
23331
- return SERIALIZED_PREFIX + btoa(JSON.stringify(arg));
23657
+ return SERIALIZED_PREFIX + encodeBase64Unicode(JSON.stringify(arg));
23332
23658
  }
23333
23659
  function deserializeProperty(value) {
23334
23660
  if (typeof value !== "string" || !value.startsWith(SERIALIZED_PREFIX)) {
23335
23661
  return value;
23336
23662
  }
23337
- return RemoteValue.fromLocalValue(JSON.parse(atob(value.slice(SERIALIZED_PREFIX.length))));
23663
+ return RemoteValue.fromLocalValue(JSON.parse(decodeBase64Unicode(value.slice(SERIALIZED_PREFIX.length))));
23338
23664
  }
23339
23665
  var CAPTURE_EVENT_SUFFIX = "Capture";
23340
23666
  var CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + "$");
@@ -23528,8 +23854,35 @@ var unescape = (s, { windowsPathsNoEscape = false } = {}) => {
23528
23854
  };
23529
23855
 
23530
23856
  // node_modules/minimatch/dist/esm/ast.js
23857
+ var _a2;
23531
23858
  var types = /* @__PURE__ */ new Set(["!", "?", "+", "*", "@"]);
23532
23859
  var isExtglobType = (c) => types.has(c);
23860
+ var isExtglobAST = (c) => isExtglobType(c.type);
23861
+ var adoptionMap = /* @__PURE__ */ new Map([
23862
+ ["!", ["@"]],
23863
+ ["?", ["?", "@"]],
23864
+ ["@", ["@"]],
23865
+ ["*", ["*", "+", "?", "@"]],
23866
+ ["+", ["+", "@"]]
23867
+ ]);
23868
+ var adoptionWithSpaceMap = /* @__PURE__ */ new Map([
23869
+ ["!", ["?"]],
23870
+ ["@", ["?"]],
23871
+ ["+", ["?", "*"]]
23872
+ ]);
23873
+ var adoptionAnyMap = /* @__PURE__ */ new Map([
23874
+ ["!", ["?", "@"]],
23875
+ ["?", ["?", "@"]],
23876
+ ["@", ["?", "@"]],
23877
+ ["*", ["*", "+", "?", "@"]],
23878
+ ["+", ["+", "@", "?", "*"]]
23879
+ ]);
23880
+ var usurpMap = /* @__PURE__ */ new Map([
23881
+ ["!", /* @__PURE__ */ new Map([["!", "@"]])],
23882
+ ["?", /* @__PURE__ */ new Map([["*", "*"], ["+", "*"]])],
23883
+ ["@", /* @__PURE__ */ new Map([["!", "!"], ["?", "?"], ["@", "@"], ["*", "*"], ["+", "+"]])],
23884
+ ["+", /* @__PURE__ */ new Map([["?", "*"], ["*", "*"]])]
23885
+ ]);
23533
23886
  var startNoTraversal = "(?!(?:^|/)\\.\\.?(?:$|/))";
23534
23887
  var startNoDot = "(?!\\.)";
23535
23888
  var addPatternStart = /* @__PURE__ */ new Set(["[", "."]);
@@ -23539,8 +23892,8 @@ var regExpEscape = (s) => s.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&");
23539
23892
  var qmark = "[^/]";
23540
23893
  var star = qmark + "*?";
23541
23894
  var starNoEmpty = qmark + "+?";
23542
- var _root, _hasMagic, _uflag, _parts, _parent, _parentIndex, _negs, _filledNegs, _options, _toString, _emptyExt, _AST_instances, fillNegs_fn, _AST_static, parseAST_fn, partsToRegExp_fn, parseGlob_fn;
23543
- var _AST = class _AST {
23895
+ var _root, _hasMagic, _uflag, _parts, _parent, _parentIndex, _negs, _filledNegs, _options, _toString, _emptyExt, _AST_instances, fillNegs_fn, _AST_static, parseAST_fn, canAdoptWithSpace_fn, canAdopt_fn, canAdoptType_fn, adoptWithSpace_fn, adopt_fn, canUsurpType_fn, canUsurp_fn, usurp_fn, flatten_fn, partsToRegExp_fn, parseGlob_fn;
23896
+ var AST = class {
23544
23897
  constructor(type, parent, options = {}) {
23545
23898
  __privateAdd(this, _AST_instances);
23546
23899
  __publicField(this, "type");
@@ -23593,44 +23946,44 @@ var _AST = class _AST {
23593
23946
  for (const p of parts) {
23594
23947
  if (p === "")
23595
23948
  continue;
23596
- if (typeof p !== "string" && !(p instanceof _AST && __privateGet(p, _parent) === this)) {
23949
+ if (typeof p !== "string" && !(p instanceof _a2 && __privateGet(p, _parent) === this)) {
23597
23950
  throw new Error("invalid part: " + p);
23598
23951
  }
23599
23952
  __privateGet(this, _parts).push(p);
23600
23953
  }
23601
23954
  }
23602
23955
  toJSON() {
23603
- var _a2;
23956
+ var _a3;
23604
23957
  const ret = this.type === null ? __privateGet(this, _parts).slice().map((p) => typeof p === "string" ? p : p.toJSON()) : [this.type, ...__privateGet(this, _parts).map((p) => p.toJSON())];
23605
23958
  if (this.isStart() && !this.type)
23606
23959
  ret.unshift([]);
23607
- if (this.isEnd() && (this === __privateGet(this, _root) || __privateGet(__privateGet(this, _root), _filledNegs) && ((_a2 = __privateGet(this, _parent)) == null ? void 0 : _a2.type) === "!")) {
23960
+ if (this.isEnd() && (this === __privateGet(this, _root) || __privateGet(__privateGet(this, _root), _filledNegs) && ((_a3 = __privateGet(this, _parent)) == null ? void 0 : _a3.type) === "!")) {
23608
23961
  ret.push({});
23609
23962
  }
23610
23963
  return ret;
23611
23964
  }
23612
23965
  isStart() {
23613
- var _a2;
23966
+ var _a3;
23614
23967
  if (__privateGet(this, _root) === this)
23615
23968
  return true;
23616
- if (!((_a2 = __privateGet(this, _parent)) == null ? void 0 : _a2.isStart()))
23969
+ if (!((_a3 = __privateGet(this, _parent)) == null ? void 0 : _a3.isStart()))
23617
23970
  return false;
23618
23971
  if (__privateGet(this, _parentIndex) === 0)
23619
23972
  return true;
23620
23973
  const p = __privateGet(this, _parent);
23621
23974
  for (let i = 0; i < __privateGet(this, _parentIndex); i++) {
23622
23975
  const pp = __privateGet(p, _parts)[i];
23623
- if (!(pp instanceof _AST && pp.type === "!")) {
23976
+ if (!(pp instanceof _a2 && pp.type === "!")) {
23624
23977
  return false;
23625
23978
  }
23626
23979
  }
23627
23980
  return true;
23628
23981
  }
23629
23982
  isEnd() {
23630
- var _a2, _b, _c;
23983
+ var _a3, _b, _c;
23631
23984
  if (__privateGet(this, _root) === this)
23632
23985
  return true;
23633
- if (((_a2 = __privateGet(this, _parent)) == null ? void 0 : _a2.type) === "!")
23986
+ if (((_a3 = __privateGet(this, _parent)) == null ? void 0 : _a3.type) === "!")
23634
23987
  return true;
23635
23988
  if (!((_b = __privateGet(this, _parent)) == null ? void 0 : _b.isEnd()))
23636
23989
  return false;
@@ -23646,16 +23999,16 @@ var _AST = class _AST {
23646
23999
  this.push(part.clone(this));
23647
24000
  }
23648
24001
  clone(parent) {
23649
- const c = new _AST(this.type, parent);
24002
+ const c = new _a2(this.type, parent);
23650
24003
  for (const p of __privateGet(this, _parts)) {
23651
24004
  c.copyIn(p);
23652
24005
  }
23653
24006
  return c;
23654
24007
  }
23655
24008
  static fromGlob(pattern, options = {}) {
23656
- var _a2;
23657
- const ast = new _AST(null, void 0, options);
23658
- __privateMethod(_a2 = _AST, _AST_static, parseAST_fn).call(_a2, pattern, ast, 0, options);
24009
+ var _a3;
24010
+ const ast = new _a2(null, void 0, options);
24011
+ __privateMethod(_a3 = _a2, _AST_static, parseAST_fn).call(_a3, pattern, ast, 0, options, 0);
23659
24012
  return ast;
23660
24013
  }
23661
24014
  // returns the regular expression if there's magic, or the unescaped
@@ -23748,15 +24101,17 @@ var _AST = class _AST {
23748
24101
  // is ^(?!\.), we can just prepend (?!\.) to the pattern (either root
23749
24102
  // or start or whatever) and prepend ^ or / at the Regexp construction.
23750
24103
  toRegExpSource(allowDot) {
23751
- var _a2;
24104
+ var _a3;
23752
24105
  const dot = allowDot != null ? allowDot : !!__privateGet(this, _options).dot;
23753
- if (__privateGet(this, _root) === this)
24106
+ if (__privateGet(this, _root) === this) {
24107
+ __privateMethod(this, _AST_instances, flatten_fn).call(this);
23754
24108
  __privateMethod(this, _AST_instances, fillNegs_fn).call(this);
23755
- if (!this.type) {
24109
+ }
24110
+ if (!isExtglobAST(this)) {
23756
24111
  const noEmpty = this.isStart() && this.isEnd();
23757
24112
  const src = __privateGet(this, _parts).map((p) => {
23758
- var _a3;
23759
- const [re, _, hasMagic, uflag] = typeof p === "string" ? __privateMethod(_a3 = _AST, _AST_static, parseGlob_fn).call(_a3, p, __privateGet(this, _hasMagic), noEmpty) : p.toRegExpSource(allowDot);
24113
+ var _a4;
24114
+ const [re, _, hasMagic, uflag] = typeof p === "string" ? __privateMethod(_a4 = _a2, _AST_static, parseGlob_fn).call(_a4, p, __privateGet(this, _hasMagic), noEmpty) : p.toRegExpSource(allowDot);
23760
24115
  __privateSet(this, _hasMagic, __privateGet(this, _hasMagic) || hasMagic);
23761
24116
  __privateSet(this, _uflag, __privateGet(this, _uflag) || uflag);
23762
24117
  return re;
@@ -23779,7 +24134,7 @@ var _AST = class _AST {
23779
24134
  }
23780
24135
  }
23781
24136
  let end = "";
23782
- if (this.isEnd() && __privateGet(__privateGet(this, _root), _filledNegs) && ((_a2 = __privateGet(this, _parent)) == null ? void 0 : _a2.type) === "!") {
24137
+ if (this.isEnd() && __privateGet(__privateGet(this, _root), _filledNegs) && ((_a3 = __privateGet(this, _parent)) == null ? void 0 : _a3.type) === "!") {
23783
24138
  end = "(?:$|\\/)";
23784
24139
  }
23785
24140
  const final2 = start2 + src + end;
@@ -23795,9 +24150,10 @@ var _AST = class _AST {
23795
24150
  let body = __privateMethod(this, _AST_instances, partsToRegExp_fn).call(this, dot);
23796
24151
  if (this.isStart() && this.isEnd() && !body && this.type !== "!") {
23797
24152
  const s = this.toString();
23798
- __privateSet(this, _parts, [s]);
23799
- this.type = null;
23800
- __privateSet(this, _hasMagic, void 0);
24153
+ const me = this;
24154
+ __privateSet(me, _parts, [s]);
24155
+ me.type = null;
24156
+ __privateSet(me, _hasMagic, void 0);
23801
24157
  return [s, unescape(this.toString()), false, false];
23802
24158
  }
23803
24159
  let bodyDotAllowed = !repeated || allowDot || dot || !startNoDot ? "" : __privateMethod(this, _AST_instances, partsToRegExp_fn).call(this, true);
@@ -23866,8 +24222,9 @@ fillNegs_fn = function() {
23866
24222
  return this;
23867
24223
  };
23868
24224
  _AST_static = new WeakSet();
23869
- parseAST_fn = function(str, ast, pos, opt) {
23870
- var _a2, _b;
24225
+ parseAST_fn = function(str, ast, pos, opt, extDepth) {
24226
+ var _a3, _b, _c, _d, _e;
24227
+ const maxDepth = (_a3 = opt.maxExtglobRecursion) != null ? _a3 : 2;
23871
24228
  let escaping = false;
23872
24229
  let inBrace = false;
23873
24230
  let braceStart = -1;
@@ -23899,11 +24256,12 @@ parseAST_fn = function(str, ast, pos, opt) {
23899
24256
  acc2 += c;
23900
24257
  continue;
23901
24258
  }
23902
- if (!opt.noext && isExtglobType(c) && str.charAt(i2) === "(") {
24259
+ const doRecurse = !opt.noext && isExtglobType(c) && str.charAt(i2) === "(" && extDepth <= maxDepth;
24260
+ if (doRecurse) {
23903
24261
  ast.push(acc2);
23904
24262
  acc2 = "";
23905
- const ext2 = new _AST(c, ast);
23906
- i2 = __privateMethod(_a2 = _AST, _AST_static, parseAST_fn).call(_a2, str, ext2, i2, opt);
24263
+ const ext2 = new _a2(c, ast);
24264
+ i2 = __privateMethod(_b = _a2, _AST_static, parseAST_fn).call(_b, str, ext2, i2, opt, extDepth + 1);
23907
24265
  ast.push(ext2);
23908
24266
  continue;
23909
24267
  }
@@ -23913,7 +24271,7 @@ parseAST_fn = function(str, ast, pos, opt) {
23913
24271
  return i2;
23914
24272
  }
23915
24273
  let i = pos + 1;
23916
- let part = new _AST(null, ast);
24274
+ let part = new _a2(null, ast);
23917
24275
  const parts = [];
23918
24276
  let acc = "";
23919
24277
  while (i < str.length) {
@@ -23940,19 +24298,22 @@ parseAST_fn = function(str, ast, pos, opt) {
23940
24298
  acc += c;
23941
24299
  continue;
23942
24300
  }
23943
- if (isExtglobType(c) && str.charAt(i) === "(") {
24301
+ const doRecurse = isExtglobType(c) && str.charAt(i) === "(" && /* c8 ignore start - the maxDepth is sufficient here */
24302
+ (extDepth <= maxDepth || ast && __privateMethod(_c = ast, _AST_instances, canAdoptType_fn).call(_c, c));
24303
+ if (doRecurse) {
24304
+ const depthAdd = ast && __privateMethod(_d = ast, _AST_instances, canAdoptType_fn).call(_d, c) ? 0 : 1;
23944
24305
  part.push(acc);
23945
24306
  acc = "";
23946
- const ext2 = new _AST(c, part);
24307
+ const ext2 = new _a2(c, part);
23947
24308
  part.push(ext2);
23948
- i = __privateMethod(_b = _AST, _AST_static, parseAST_fn).call(_b, str, ext2, i, opt);
24309
+ i = __privateMethod(_e = _a2, _AST_static, parseAST_fn).call(_e, str, ext2, i, opt, extDepth + depthAdd);
23949
24310
  continue;
23950
24311
  }
23951
24312
  if (c === "|") {
23952
24313
  part.push(acc);
23953
24314
  acc = "";
23954
24315
  parts.push(part);
23955
- part = new _AST(null, ast);
24316
+ part = new _a2(null, ast);
23956
24317
  continue;
23957
24318
  }
23958
24319
  if (c === ")") {
@@ -23971,6 +24332,100 @@ parseAST_fn = function(str, ast, pos, opt) {
23971
24332
  __privateSet(ast, _parts, [str.substring(pos - 1)]);
23972
24333
  return i;
23973
24334
  };
24335
+ canAdoptWithSpace_fn = function(child) {
24336
+ return __privateMethod(this, _AST_instances, canAdopt_fn).call(this, child, adoptionWithSpaceMap);
24337
+ };
24338
+ canAdopt_fn = function(child, map2 = adoptionMap) {
24339
+ if (!child || typeof child !== "object" || child.type !== null || __privateGet(child, _parts).length !== 1 || this.type === null) {
24340
+ return false;
24341
+ }
24342
+ const gc = __privateGet(child, _parts)[0];
24343
+ if (!gc || typeof gc !== "object" || gc.type === null) {
24344
+ return false;
24345
+ }
24346
+ return __privateMethod(this, _AST_instances, canAdoptType_fn).call(this, gc.type, map2);
24347
+ };
24348
+ canAdoptType_fn = function(c, map2 = adoptionAnyMap) {
24349
+ var _a3;
24350
+ return !!((_a3 = map2.get(this.type)) == null ? void 0 : _a3.includes(c));
24351
+ };
24352
+ adoptWithSpace_fn = function(child, index) {
24353
+ const gc = __privateGet(child, _parts)[0];
24354
+ const blank = new _a2(null, gc, this.options);
24355
+ __privateGet(blank, _parts).push("");
24356
+ gc.push(blank);
24357
+ __privateMethod(this, _AST_instances, adopt_fn).call(this, child, index);
24358
+ };
24359
+ adopt_fn = function(child, index) {
24360
+ const gc = __privateGet(child, _parts)[0];
24361
+ __privateGet(this, _parts).splice(index, 1, ...__privateGet(gc, _parts));
24362
+ for (const p of __privateGet(gc, _parts)) {
24363
+ if (typeof p === "object")
24364
+ __privateSet(p, _parent, this);
24365
+ }
24366
+ __privateSet(this, _toString, void 0);
24367
+ };
24368
+ canUsurpType_fn = function(c) {
24369
+ const m = usurpMap.get(this.type);
24370
+ return !!(m == null ? void 0 : m.has(c));
24371
+ };
24372
+ canUsurp_fn = function(child) {
24373
+ if (!child || typeof child !== "object" || child.type !== null || __privateGet(child, _parts).length !== 1 || this.type === null || __privateGet(this, _parts).length !== 1) {
24374
+ return false;
24375
+ }
24376
+ const gc = __privateGet(child, _parts)[0];
24377
+ if (!gc || typeof gc !== "object" || gc.type === null) {
24378
+ return false;
24379
+ }
24380
+ return __privateMethod(this, _AST_instances, canUsurpType_fn).call(this, gc.type);
24381
+ };
24382
+ usurp_fn = function(child) {
24383
+ const m = usurpMap.get(this.type);
24384
+ const gc = __privateGet(child, _parts)[0];
24385
+ const nt = m == null ? void 0 : m.get(gc.type);
24386
+ if (!nt)
24387
+ return false;
24388
+ __privateSet(this, _parts, __privateGet(gc, _parts));
24389
+ for (const p of __privateGet(this, _parts)) {
24390
+ if (typeof p === "object")
24391
+ __privateSet(p, _parent, this);
24392
+ }
24393
+ this.type = nt;
24394
+ __privateSet(this, _toString, void 0);
24395
+ __privateSet(this, _emptyExt, false);
24396
+ };
24397
+ flatten_fn = function() {
24398
+ var _a3, _b;
24399
+ if (!isExtglobAST(this)) {
24400
+ for (const p of __privateGet(this, _parts)) {
24401
+ if (typeof p === "object")
24402
+ __privateMethod(_a3 = p, _AST_instances, flatten_fn).call(_a3);
24403
+ }
24404
+ } else {
24405
+ let iterations = 0;
24406
+ let done = false;
24407
+ do {
24408
+ done = true;
24409
+ for (let i = 0; i < __privateGet(this, _parts).length; i++) {
24410
+ const c = __privateGet(this, _parts)[i];
24411
+ if (typeof c === "object") {
24412
+ __privateMethod(_b = c, _AST_instances, flatten_fn).call(_b);
24413
+ if (__privateMethod(this, _AST_instances, canAdopt_fn).call(this, c)) {
24414
+ done = false;
24415
+ __privateMethod(this, _AST_instances, adopt_fn).call(this, c, i);
24416
+ } else if (__privateMethod(this, _AST_instances, canAdoptWithSpace_fn).call(this, c)) {
24417
+ done = false;
24418
+ __privateMethod(this, _AST_instances, adoptWithSpace_fn).call(this, c, i);
24419
+ } else if (__privateMethod(this, _AST_instances, canUsurp_fn).call(this, c)) {
24420
+ done = false;
24421
+ __privateMethod(this, _AST_instances, usurp_fn).call(this, c);
24422
+ }
24423
+ }
24424
+ }
24425
+ } while (!done && ++iterations < 10);
24426
+ }
24427
+ __privateSet(this, _toString, void 0);
24428
+ };
23974
24429
  partsToRegExp_fn = function(dot) {
23975
24430
  return __privateGet(this, _parts).map((p) => {
23976
24431
  if (typeof p === "string") {
@@ -23985,11 +24440,13 @@ parseGlob_fn = function(glob, hasMagic, noEmpty = false) {
23985
24440
  let escaping = false;
23986
24441
  let re = "";
23987
24442
  let uflag = false;
24443
+ let inStar = false;
23988
24444
  for (let i = 0; i < glob.length; i++) {
23989
24445
  const c = glob.charAt(i);
23990
24446
  if (escaping) {
23991
24447
  escaping = false;
23992
24448
  re += (reSpecials.has(c) ? "\\" : "") + c;
24449
+ inStar = false;
23993
24450
  continue;
23994
24451
  }
23995
24452
  if (c === "\\") {
@@ -24007,16 +24464,19 @@ parseGlob_fn = function(glob, hasMagic, noEmpty = false) {
24007
24464
  uflag = uflag || needUflag;
24008
24465
  i += consumed - 1;
24009
24466
  hasMagic = hasMagic || magic;
24467
+ inStar = false;
24010
24468
  continue;
24011
24469
  }
24012
24470
  }
24013
24471
  if (c === "*") {
24014
- if (noEmpty && glob === "*")
24015
- re += starNoEmpty;
24016
- else
24017
- re += star;
24472
+ if (inStar)
24473
+ continue;
24474
+ inStar = true;
24475
+ re += noEmpty && /^[*]+$/.test(glob) ? starNoEmpty : star;
24018
24476
  hasMagic = true;
24019
24477
  continue;
24478
+ } else {
24479
+ inStar = false;
24020
24480
  }
24021
24481
  if (c === "?") {
24022
24482
  re += qmark;
@@ -24027,8 +24487,8 @@ parseGlob_fn = function(glob, hasMagic, noEmpty = false) {
24027
24487
  }
24028
24488
  return [re, unescape(glob), !!hasMagic, uflag];
24029
24489
  };
24030
- __privateAdd(_AST, _AST_static);
24031
- var AST = _AST;
24490
+ __privateAdd(AST, _AST_static);
24491
+ _a2 = AST;
24032
24492
 
24033
24493
  // node_modules/minimatch/dist/esm/escape.js
24034
24494
  var escape = (s, { windowsPathsNoEscape = false } = {}) => {
@@ -24167,28 +24627,33 @@ var match = (list, pattern, options = {}) => {
24167
24627
  minimatch.match = match;
24168
24628
  var globMagic = /[?*]|[+@!]\(.*?\)|\[|\]/;
24169
24629
  var regExpEscape2 = (s) => s.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&");
24630
+ var _Minimatch_instances, matchGlobstar_fn, matchGlobStarBodySections_fn, matchOne_fn;
24170
24631
  var Minimatch = class {
24171
- options;
24172
- set;
24173
- pattern;
24174
- windowsPathsNoEscape;
24175
- nonegate;
24176
- negate;
24177
- comment;
24178
- empty;
24179
- preserveMultipleSlashes;
24180
- partial;
24181
- globSet;
24182
- globParts;
24183
- nocase;
24184
- isWindows;
24185
- platform;
24186
- windowsNoMagicRoot;
24187
- regexp;
24188
24632
  constructor(pattern, options = {}) {
24633
+ __privateAdd(this, _Minimatch_instances);
24634
+ __publicField(this, "options");
24635
+ __publicField(this, "set");
24636
+ __publicField(this, "pattern");
24637
+ __publicField(this, "windowsPathsNoEscape");
24638
+ __publicField(this, "nonegate");
24639
+ __publicField(this, "negate");
24640
+ __publicField(this, "comment");
24641
+ __publicField(this, "empty");
24642
+ __publicField(this, "preserveMultipleSlashes");
24643
+ __publicField(this, "partial");
24644
+ __publicField(this, "globSet");
24645
+ __publicField(this, "globParts");
24646
+ __publicField(this, "nocase");
24647
+ __publicField(this, "isWindows");
24648
+ __publicField(this, "platform");
24649
+ __publicField(this, "windowsNoMagicRoot");
24650
+ __publicField(this, "maxGlobstarRecursion");
24651
+ __publicField(this, "regexp");
24652
+ var _a3;
24189
24653
  assertValidPattern(pattern);
24190
24654
  options = options || {};
24191
24655
  this.options = options;
24656
+ this.maxGlobstarRecursion = (_a3 = options.maxGlobstarRecursion) != null ? _a3 : 200;
24192
24657
  this.pattern = pattern;
24193
24658
  this.platform = options.platform || defaultPlatform;
24194
24659
  this.isWindows = this.platform === "win32";
@@ -24456,10 +24921,11 @@ var Minimatch = class {
24456
24921
  for (let i = 0; i < globParts.length - 1; i++) {
24457
24922
  for (let j = i + 1; j < globParts.length; j++) {
24458
24923
  const matched = this.partsMatch(globParts[i], globParts[j], !this.preserveMultipleSlashes);
24459
- if (!matched)
24460
- continue;
24461
- globParts[i] = matched;
24462
- globParts[j] = [];
24924
+ if (matched) {
24925
+ globParts[i] = [];
24926
+ globParts[j] = matched;
24927
+ break;
24928
+ }
24463
24929
  }
24464
24930
  }
24465
24931
  return globParts.filter((gs) => gs.length);
@@ -24520,7 +24986,8 @@ var Minimatch = class {
24520
24986
  // out of pattern, then that's fine, as long as all
24521
24987
  // the parts match.
24522
24988
  matchOne(file, pattern, partial = false) {
24523
- const options = this.options;
24989
+ let fileStartIndex = 0;
24990
+ let patternStartIndex = 0;
24524
24991
  if (this.isWindows) {
24525
24992
  const fileDrive = typeof file[0] === "string" && /^[a-z]:$/i.test(file[0]);
24526
24993
  const fileUNC = !fileDrive && file[0] === "" && file[1] === "" && file[2] === "?" && /^[a-z]:$/i.test(file[3]);
@@ -24529,14 +24996,14 @@ var Minimatch = class {
24529
24996
  const fdi = fileUNC ? 3 : fileDrive ? 0 : void 0;
24530
24997
  const pdi = patternUNC ? 3 : patternDrive ? 0 : void 0;
24531
24998
  if (typeof fdi === "number" && typeof pdi === "number") {
24532
- const [fd, pd] = [file[fdi], pattern[pdi]];
24999
+ const [fd, pd] = [
25000
+ file[fdi],
25001
+ pattern[pdi]
25002
+ ];
24533
25003
  if (fd.toLowerCase() === pd.toLowerCase()) {
24534
25004
  pattern[pdi] = fd;
24535
- if (pdi > fdi) {
24536
- pattern = pattern.slice(pdi);
24537
- } else if (fdi > pdi) {
24538
- file = file.slice(fdi);
24539
- }
25005
+ patternStartIndex = pdi;
25006
+ fileStartIndex = fdi;
24540
25007
  }
24541
25008
  }
24542
25009
  }
@@ -24544,71 +25011,10 @@ var Minimatch = class {
24544
25011
  if (optimizationLevel >= 2) {
24545
25012
  file = this.levelTwoFileOptimize(file);
24546
25013
  }
24547
- this.debug("matchOne", this, { file, pattern });
24548
- this.debug("matchOne", file.length, pattern.length);
24549
- for (var fi = 0, pi = 0, fl = file.length, pl = pattern.length; fi < fl && pi < pl; fi++, pi++) {
24550
- this.debug("matchOne loop");
24551
- var p = pattern[pi];
24552
- var f = file[fi];
24553
- this.debug(pattern, p, f);
24554
- if (p === false) {
24555
- return false;
24556
- }
24557
- if (p === GLOBSTAR) {
24558
- this.debug("GLOBSTAR", [pattern, p, f]);
24559
- var fr = fi;
24560
- var pr = pi + 1;
24561
- if (pr === pl) {
24562
- this.debug("** at the end");
24563
- for (; fi < fl; fi++) {
24564
- if (file[fi] === "." || file[fi] === ".." || !options.dot && file[fi].charAt(0) === ".")
24565
- return false;
24566
- }
24567
- return true;
24568
- }
24569
- while (fr < fl) {
24570
- var swallowee = file[fr];
24571
- this.debug("\nglobstar while", file, fr, pattern, pr, swallowee);
24572
- if (this.matchOne(file.slice(fr), pattern.slice(pr), partial)) {
24573
- this.debug("globstar found match!", fr, fl, swallowee);
24574
- return true;
24575
- } else {
24576
- if (swallowee === "." || swallowee === ".." || !options.dot && swallowee.charAt(0) === ".") {
24577
- this.debug("dot detected!", file, fr, pattern, pr);
24578
- break;
24579
- }
24580
- this.debug("globstar swallow a segment, and continue");
24581
- fr++;
24582
- }
24583
- }
24584
- if (partial) {
24585
- this.debug("\n>>> no match, partial?", file, fr, pattern, pr);
24586
- if (fr === fl) {
24587
- return true;
24588
- }
24589
- }
24590
- return false;
24591
- }
24592
- let hit;
24593
- if (typeof p === "string") {
24594
- hit = f === p;
24595
- this.debug("string match", p, f, hit);
24596
- } else {
24597
- hit = p.test(f);
24598
- this.debug("pattern match", p, f, hit);
24599
- }
24600
- if (!hit)
24601
- return false;
24602
- }
24603
- if (fi === fl && pi === pl) {
24604
- return true;
24605
- } else if (fi === fl) {
24606
- return partial;
24607
- } else if (pi === pl) {
24608
- return fi === fl - 1 && file[fi] === "";
24609
- } else {
24610
- throw new Error("wtf?");
25014
+ if (pattern.includes(GLOBSTAR)) {
25015
+ return __privateMethod(this, _Minimatch_instances, matchGlobstar_fn).call(this, file, pattern, partial, fileStartIndex, patternStartIndex);
24611
25016
  }
25017
+ return __privateMethod(this, _Minimatch_instances, matchOne_fn).call(this, file, pattern, partial, fileStartIndex, patternStartIndex);
24612
25018
  }
24613
25019
  braceExpand() {
24614
25020
  return braceExpand(this.pattern, this.options);
@@ -24747,6 +25153,135 @@ var Minimatch = class {
24747
25153
  return minimatch.defaults(def).Minimatch;
24748
25154
  }
24749
25155
  };
25156
+ _Minimatch_instances = new WeakSet();
25157
+ matchGlobstar_fn = function(file, pattern, partial, fileIndex, patternIndex) {
25158
+ const firstgs = pattern.indexOf(GLOBSTAR, patternIndex);
25159
+ const lastgs = pattern.lastIndexOf(GLOBSTAR);
25160
+ const [head, body, tail] = partial ? [
25161
+ pattern.slice(patternIndex, firstgs),
25162
+ pattern.slice(firstgs + 1),
25163
+ []
25164
+ ] : [
25165
+ pattern.slice(patternIndex, firstgs),
25166
+ pattern.slice(firstgs + 1, lastgs),
25167
+ pattern.slice(lastgs + 1)
25168
+ ];
25169
+ if (head.length) {
25170
+ const fileHead = file.slice(fileIndex, fileIndex + head.length);
25171
+ if (!__privateMethod(this, _Minimatch_instances, matchOne_fn).call(this, fileHead, head, partial, 0, 0))
25172
+ return false;
25173
+ fileIndex += head.length;
25174
+ }
25175
+ let fileTailMatch = 0;
25176
+ if (tail.length) {
25177
+ if (tail.length + fileIndex > file.length)
25178
+ return false;
25179
+ let tailStart = file.length - tail.length;
25180
+ if (__privateMethod(this, _Minimatch_instances, matchOne_fn).call(this, file, tail, partial, tailStart, 0)) {
25181
+ fileTailMatch = tail.length;
25182
+ } else {
25183
+ if (file[file.length - 1] !== "" || fileIndex + tail.length === file.length) {
25184
+ return false;
25185
+ }
25186
+ tailStart--;
25187
+ if (!__privateMethod(this, _Minimatch_instances, matchOne_fn).call(this, file, tail, partial, tailStart, 0))
25188
+ return false;
25189
+ fileTailMatch = tail.length + 1;
25190
+ }
25191
+ }
25192
+ if (!body.length) {
25193
+ let sawSome = !!fileTailMatch;
25194
+ for (let i2 = fileIndex; i2 < file.length - fileTailMatch; i2++) {
25195
+ const f = String(file[i2]);
25196
+ sawSome = true;
25197
+ if (f === "." || f === ".." || !this.options.dot && f.startsWith(".")) {
25198
+ return false;
25199
+ }
25200
+ }
25201
+ return partial || sawSome;
25202
+ }
25203
+ const bodySegments = [[[], 0]];
25204
+ let currentBody = bodySegments[0];
25205
+ let nonGsParts = 0;
25206
+ const nonGsPartsSums = [0];
25207
+ for (const b of body) {
25208
+ if (b === GLOBSTAR) {
25209
+ nonGsPartsSums.push(nonGsParts);
25210
+ currentBody = [[], 0];
25211
+ bodySegments.push(currentBody);
25212
+ } else {
25213
+ currentBody[0].push(b);
25214
+ nonGsParts++;
25215
+ }
25216
+ }
25217
+ let i = bodySegments.length - 1;
25218
+ const fileLength = file.length - fileTailMatch;
25219
+ for (const b of bodySegments) {
25220
+ b[1] = fileLength - (nonGsPartsSums[i--] + b[0].length);
25221
+ }
25222
+ return !!__privateMethod(this, _Minimatch_instances, matchGlobStarBodySections_fn).call(this, file, bodySegments, fileIndex, 0, partial, 0, !!fileTailMatch);
25223
+ };
25224
+ matchGlobStarBodySections_fn = function(file, bodySegments, fileIndex, bodyIndex, partial, globStarDepth, sawTail) {
25225
+ const bs = bodySegments[bodyIndex];
25226
+ if (!bs) {
25227
+ for (let i = fileIndex; i < file.length; i++) {
25228
+ sawTail = true;
25229
+ const f = file[i];
25230
+ if (f === "." || f === ".." || !this.options.dot && f.startsWith(".")) {
25231
+ return false;
25232
+ }
25233
+ }
25234
+ return sawTail;
25235
+ }
25236
+ const [body, after] = bs;
25237
+ while (fileIndex <= after) {
25238
+ const m = __privateMethod(this, _Minimatch_instances, matchOne_fn).call(this, file.slice(0, fileIndex + body.length), body, partial, fileIndex, 0);
25239
+ if (m && globStarDepth < this.maxGlobstarRecursion) {
25240
+ const sub = __privateMethod(this, _Minimatch_instances, matchGlobStarBodySections_fn).call(this, file, bodySegments, fileIndex + body.length, bodyIndex + 1, partial, globStarDepth + 1, sawTail);
25241
+ if (sub !== false)
25242
+ return sub;
25243
+ }
25244
+ const f = file[fileIndex];
25245
+ if (f === "." || f === ".." || !this.options.dot && f.startsWith(".")) {
25246
+ return false;
25247
+ }
25248
+ fileIndex++;
25249
+ }
25250
+ return partial || null;
25251
+ };
25252
+ matchOne_fn = function(file, pattern, partial, fileIndex, patternIndex) {
25253
+ let fi;
25254
+ let pi;
25255
+ let pl;
25256
+ let fl;
25257
+ for (fi = fileIndex, pi = patternIndex, fl = file.length, pl = pattern.length; fi < fl && pi < pl; fi++, pi++) {
25258
+ this.debug("matchOne loop");
25259
+ let p = pattern[pi];
25260
+ let f = file[fi];
25261
+ this.debug(pattern, p, f);
25262
+ if (p === false || p === GLOBSTAR)
25263
+ return false;
25264
+ let hit;
25265
+ if (typeof p === "string") {
25266
+ hit = f === p;
25267
+ this.debug("string match", p, f, hit);
25268
+ } else {
25269
+ hit = p.test(f);
25270
+ this.debug("pattern match", p, f, hit);
25271
+ }
25272
+ if (!hit)
25273
+ return false;
25274
+ }
25275
+ if (fi === fl && pi === pl) {
25276
+ return true;
25277
+ } else if (fi === fl) {
25278
+ return partial;
25279
+ } else if (pi === pl) {
25280
+ return fi === fl - 1 && file[fi] === "";
25281
+ } else {
25282
+ throw new Error("wtf?");
25283
+ }
25284
+ };
24750
25285
  minimatch.AST = AST;
24751
25286
  minimatch.Minimatch = Minimatch;
24752
25287
  minimatch.escape = escape;
@@ -24817,7 +25352,7 @@ var isJsFile = lowerPathParam((p) => p.endsWith(".js") || p.endsWith(".mjs") ||
24817
25352
 
24818
25353
  // src/compiler/html/canonical-link.ts
24819
25354
  var updateCanonicalLink = (doc, href) => {
24820
- var _a2;
25355
+ var _a3;
24821
25356
  let canonicalLinkElm = doc.head.querySelector('link[rel="canonical"]');
24822
25357
  if (typeof href === "string") {
24823
25358
  if (canonicalLinkElm == null) {
@@ -24830,7 +25365,7 @@ var updateCanonicalLink = (doc, href) => {
24830
25365
  if (canonicalLinkElm != null) {
24831
25366
  const existingHref = canonicalLinkElm.getAttribute("href");
24832
25367
  if (!existingHref) {
24833
- (_a2 = canonicalLinkElm.parentNode) == null ? void 0 : _a2.removeChild(canonicalLinkElm);
25368
+ (_a3 = canonicalLinkElm.parentNode) == null ? void 0 : _a3.removeChild(canonicalLinkElm);
24834
25369
  }
24835
25370
  }
24836
25371
  }
@@ -25342,7 +25877,7 @@ var serializeCss = (stylesheet, serializeOpts) => {
25342
25877
  return out.join("");
25343
25878
  };
25344
25879
  var serializeCssVisitNode = (opts, node, index, len) => {
25345
- var _a2;
25880
+ var _a3;
25346
25881
  const nodeType = node.type;
25347
25882
  if (nodeType === 4 /* Declaration */) {
25348
25883
  return serializeCssDeclaration(node, index, len);
@@ -25351,7 +25886,7 @@ var serializeCssVisitNode = (opts, node, index, len) => {
25351
25886
  return serializeCssRule(opts, node);
25352
25887
  }
25353
25888
  if (nodeType === 1 /* Comment */) {
25354
- if (((_a2 = node.comment) == null ? void 0 : _a2[0]) === "!") {
25889
+ if (((_a3 = node.comment) == null ? void 0 : _a3[0]) === "!") {
25355
25890
  return `/*${node.comment}*/`;
25356
25891
  } else {
25357
25892
  return "";
@@ -25399,10 +25934,10 @@ var serializeCssVisitNode = (opts, node, index, len) => {
25399
25934
  return "";
25400
25935
  };
25401
25936
  var serializeCssRule = (opts, node) => {
25402
- var _a2, _b;
25937
+ var _a3, _b;
25403
25938
  const decls = node.declarations;
25404
25939
  const usedSelectors = opts.usedSelectors;
25405
- const selectors = (_b = (_a2 = node.selectors) == null ? void 0 : _a2.slice()) != null ? _b : [];
25940
+ const selectors = (_b = (_a3 = node.selectors) == null ? void 0 : _a3.slice()) != null ? _b : [];
25406
25941
  const hasDecls = decls != null && decls.length > 0;
25407
25942
  const hasNestedRules = node.rules != null && node.rules.length > 0;
25408
25943
  if (!hasDecls && !hasNestedRules) {
@@ -25506,8 +26041,8 @@ var serializeCssKeyframes = (opts, node) => {
25506
26041
  return "@" + (node.vendor || "") + "keyframes " + node.name + "{" + keyframesCss + "}";
25507
26042
  };
25508
26043
  var serializeCssKeyframe = (opts, node) => {
25509
- var _a2, _b;
25510
- return ((_b = (_a2 = node.values) == null ? void 0 : _a2.join(",")) != null ? _b : "") + "{" + serializeCssMapVisit(opts, node.declarations) + "}";
26044
+ var _a3, _b;
26045
+ return ((_b = (_a3 = node.values) == null ? void 0 : _a3.join(",")) != null ? _b : "") + "{" + serializeCssMapVisit(opts, node.declarations) + "}";
25511
26046
  };
25512
26047
  var serializeCssFontFace = (opts, node) => {
25513
26048
  const fontCss = serializeCssMapVisit(opts, node.declarations);
@@ -25531,8 +26066,8 @@ var serializeCssContainer = (opts, node) => {
25531
26066
  return "@container " + removeMediaWhitespace(node.media) + "{" + containerCss + "}";
25532
26067
  };
25533
26068
  var serializeCssPage = (opts, node) => {
25534
- var _a2, _b;
25535
- const sel = (_b = (_a2 = node.selectors) == null ? void 0 : _a2.join(", ")) != null ? _b : "";
26069
+ var _a3, _b;
26070
+ const sel = (_b = (_a3 = node.selectors) == null ? void 0 : _a3.join(", ")) != null ? _b : "";
25536
26071
  return "@page " + sel + "{" + serializeCssMapVisit(opts, node.declarations) + "}";
25537
26072
  };
25538
26073
  var serializeCssDocument = (opts, node) => {
@@ -25579,10 +26114,10 @@ var removeSelectorWhitespace = (selector) => {
25579
26114
  return rtn;
25580
26115
  };
25581
26116
  var removeMediaWhitespace = (media) => {
25582
- var _a2;
26117
+ var _a3;
25583
26118
  let rtn = "";
25584
26119
  let char = "";
25585
- media = (_a2 = media == null ? void 0 : media.trim()) != null ? _a2 : "";
26120
+ media = (_a3 = media == null ? void 0 : media.trim()) != null ? _a3 : "";
25586
26121
  for (let i = 0, l = media.length; i < l; i++) {
25587
26122
  char = media[i];
25588
26123
  if (CSS_WS_REG.test(char)) {