@stencil/core 4.41.1 → 4.41.2-dev.1768799567.75e7562

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 (40) hide show
  1. package/cli/index.cjs +1 -18
  2. package/cli/index.js +1 -18
  3. package/cli/package.json +1 -1
  4. package/compiler/package.json +1 -1
  5. package/compiler/stencil.js +37 -11
  6. package/dev-server/client/index.js +1 -1
  7. package/dev-server/client/package.json +1 -1
  8. package/dev-server/connector.html +2 -2
  9. package/dev-server/index.js +1 -1
  10. package/dev-server/package.json +1 -1
  11. package/dev-server/server-process.js +2 -19
  12. package/internal/app-data/package.json +1 -1
  13. package/internal/app-globals/package.json +1 -1
  14. package/internal/client/index.js +199 -1826
  15. package/internal/client/package.json +1 -1
  16. package/internal/client/patch-browser.js +1 -1
  17. package/internal/client/shadow-css.js +3 -3
  18. package/internal/hydrate/index.js +5114 -5089
  19. package/internal/hydrate/package.json +1 -1
  20. package/internal/hydrate/runner.js +224 -241
  21. package/internal/package.json +1 -1
  22. package/internal/stencil-public-compiler.d.ts +10 -0
  23. package/internal/testing/index.js +98 -68
  24. package/internal/testing/jsx-dev-runtime.d.ts +2 -0
  25. package/internal/testing/jsx-dev-runtime.js +8 -0
  26. package/internal/testing/jsx-runtime.d.ts +2 -0
  27. package/internal/testing/jsx-runtime.js +9 -0
  28. package/internal/testing/package.json +1 -1
  29. package/mock-doc/index.cjs +3 -3
  30. package/mock-doc/index.js +3 -3
  31. package/mock-doc/package.json +1 -1
  32. package/package.json +13 -2
  33. package/screenshot/index.js +1 -18
  34. package/screenshot/package.json +1 -1
  35. package/screenshot/pixel-match.js +1 -1
  36. package/sys/node/index.js +28 -28
  37. package/sys/node/package.json +1 -1
  38. package/sys/node/worker.js +1 -1
  39. package/testing/index.js +19 -1
  40. package/testing/package.json +1 -1
@@ -344,7 +344,7 @@ var queuedLoadModules = [];
344
344
  var caughtErrors = [];
345
345
 
346
346
  // src/runtime/event-emitter.ts
347
- var import_app_data3 = require("@stencil/core/internal/app-data");
347
+ var import_app_data2 = require("@stencil/core/internal/app-data");
348
348
 
349
349
  // src/utils/constants.ts
350
350
  var SVG_NS = "http://www.w3.org/2000/svg";
@@ -374,6 +374,36 @@ var TYPE_CONSTANT = "type";
374
374
  var VALUE_CONSTANT = "value";
375
375
  var SERIALIZED_PREFIX = "serialized:";
376
376
 
377
+ // src/runtime/element.ts
378
+ var import_app_data = require("@stencil/core/internal/app-data");
379
+ var getElement = (ref) => {
380
+ var _a;
381
+ return import_app_data.BUILD.lazyLoad ? (_a = getHostRef(ref)) == null ? void 0 : _a.$hostElement$ : ref;
382
+ };
383
+
384
+ // src/runtime/event-emitter.ts
385
+ var createEvent = (ref, name, flags) => {
386
+ const elm = getElement(ref);
387
+ return {
388
+ emit: (detail) => {
389
+ if (import_app_data2.BUILD.isDev && !elm.isConnected) {
390
+ consoleDevWarn(`The "${name}" event was emitted, but the dispatcher node is no longer connected to the dom.`);
391
+ }
392
+ return emitEvent(elm, name, {
393
+ bubbles: !!(flags & 4 /* Bubbles */),
394
+ composed: !!(flags & 2 /* Composed */),
395
+ cancelable: !!(flags & 1 /* Cancellable */),
396
+ detail
397
+ });
398
+ }
399
+ };
400
+ };
401
+ var emitEvent = (elm, name, opts) => {
402
+ const ev = plt.ce(name, opts);
403
+ elm.dispatchEvent(ev);
404
+ return ev;
405
+ };
406
+
377
407
  // src/utils/helpers.ts
378
408
  var isDef = (v) => v != null && v !== void 0;
379
409
  var isComplexType = (o) => {
@@ -1898,7 +1928,7 @@ function deserializeProperty(value) {
1898
1928
  }
1899
1929
 
1900
1930
  // src/utils/shadow-root.ts
1901
- var import_app_data = require("@stencil/core/internal/app-data");
1931
+ var import_app_data3 = require("@stencil/core/internal/app-data");
1902
1932
 
1903
1933
  // src/app-globals/index.ts
1904
1934
  var globalStyles = (
@@ -1945,10 +1975,10 @@ var GLOBAL_STYLE_ID = "sc-global";
1945
1975
  function createShadowRoot(cmpMeta) {
1946
1976
  var _a;
1947
1977
  const opts = { mode: "open" };
1948
- if (import_app_data.BUILD.shadowDelegatesFocus) {
1978
+ if (import_app_data3.BUILD.shadowDelegatesFocus) {
1949
1979
  opts.delegatesFocus = !!(cmpMeta.$flags$ & 16 /* shadowDelegatesFocus */);
1950
1980
  }
1951
- if (import_app_data.BUILD.shadowSlotAssignmentManual) {
1981
+ if (import_app_data3.BUILD.shadowSlotAssignmentManual) {
1952
1982
  const isManual = !!(cmpMeta.$flags$ & 1024 /* shadowSlotAssignmentManual */);
1953
1983
  if (isManual) {
1954
1984
  opts.slotAssignment = "manual";
@@ -1965,7 +1995,7 @@ function createShadowRoot(cmpMeta) {
1965
1995
  } else if (globalStyles && !supportsConstructableStylesheets) {
1966
1996
  const styleElm = document.createElement("style");
1967
1997
  styleElm.innerHTML = globalStyles;
1968
- if (import_app_data.BUILD.hotModuleReplacement) {
1998
+ if (import_app_data3.BUILD.hotModuleReplacement) {
1969
1999
  styleElm.setAttribute(HYDRATED_STYLE_ID, GLOBAL_STYLE_ID);
1970
2000
  }
1971
2001
  shadowRoot.prepend(styleElm);
@@ -1986,36 +2016,6 @@ var isJsxFile = lowerPathParam(
1986
2016
  );
1987
2017
  var isJsFile = lowerPathParam((p) => p.endsWith(".js") || p.endsWith(".mjs") || p.endsWith(".cjs"));
1988
2018
 
1989
- // src/runtime/element.ts
1990
- var import_app_data2 = require("@stencil/core/internal/app-data");
1991
- var getElement = (ref) => {
1992
- var _a;
1993
- return import_app_data2.BUILD.lazyLoad ? (_a = getHostRef(ref)) == null ? void 0 : _a.$hostElement$ : ref;
1994
- };
1995
-
1996
- // src/runtime/event-emitter.ts
1997
- var createEvent = (ref, name, flags) => {
1998
- const elm = getElement(ref);
1999
- return {
2000
- emit: (detail) => {
2001
- if (import_app_data3.BUILD.isDev && !elm.isConnected) {
2002
- consoleDevWarn(`The "${name}" event was emitted, but the dispatcher node is no longer connected to the dom.`);
2003
- }
2004
- return emitEvent(elm, name, {
2005
- bubbles: !!(flags & 4 /* Bubbles */),
2006
- composed: !!(flags & 2 /* Composed */),
2007
- cancelable: !!(flags & 1 /* Cancellable */),
2008
- detail
2009
- });
2010
- }
2011
- };
2012
- };
2013
- var emitEvent = (elm, name, opts) => {
2014
- const ev = plt.ce(name, opts);
2015
- elm.dispatchEvent(ev);
2016
- return ev;
2017
- };
2018
-
2019
2019
  // src/testing/platform/testing-host-ref.ts
2020
2020
  var getHostRef = (elm) => {
2021
2021
  if (elm.__stencil__getHostRef) {
@@ -2990,10 +2990,10 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
2990
2990
  }
2991
2991
  const existingStyleElm = (import_app_data7.BUILD.hydrateClientSide || import_app_data7.BUILD.hotModuleReplacement) && styleContainerNode.querySelector(`[${HYDRATED_STYLE_ID}="${scopeId2}"]`);
2992
2992
  if (existingStyleElm) {
2993
- existingStyleElm.innerHTML = style;
2993
+ existingStyleElm.textContent = style;
2994
2994
  } else if (!appliedStyles.has(scopeId2)) {
2995
2995
  styleElm = win.document.createElement("style");
2996
- styleElm.innerHTML = style;
2996
+ styleElm.textContent = style;
2997
2997
  const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(win.document);
2998
2998
  if (nonce != null) {
2999
2999
  styleElm.setAttribute("nonce", nonce);
@@ -3022,7 +3022,7 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
3022
3022
  } else {
3023
3023
  const existingStyleContainer = styleContainerNode.querySelector("style");
3024
3024
  if (existingStyleContainer) {
3025
- existingStyleContainer.innerHTML = style + existingStyleContainer.innerHTML;
3025
+ existingStyleContainer.textContent = style + existingStyleContainer.textContent;
3026
3026
  } else {
3027
3027
  styleContainerNode.prepend(styleElm);
3028
3028
  }
@@ -3035,7 +3035,7 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
3035
3035
  styleContainerNode.insertBefore(styleElm, null);
3036
3036
  }
3037
3037
  if (cmpMeta.$flags$ & 4 /* hasSlotRelocation */) {
3038
- styleElm.innerHTML += SLOT_FB_CSS;
3038
+ styleElm.textContent += SLOT_FB_CSS;
3039
3039
  }
3040
3040
  if (appliedStyles) {
3041
3041
  appliedStyles.add(scopeId2);
@@ -3178,7 +3178,8 @@ var newVNode = (tag, text) => {
3178
3178
  const vnode = {
3179
3179
  $flags$: 0,
3180
3180
  $tag$: tag,
3181
- $text$: text,
3181
+ // Normalize undefined to null to prevent rendering "undefined" as text
3182
+ $text$: text != null ? text : null,
3182
3183
  $elm$: null,
3183
3184
  $children$: null
3184
3185
  };
@@ -3298,7 +3299,7 @@ var initializeClientHydrate = (hostElm, tagName, hostId, hostRef) => {
3298
3299
  );
3299
3300
  const styleSheet = win.document.querySelector(`style[sty-id="${scopeId3}"]`);
3300
3301
  if (styleSheet) {
3301
- hostElm.shadowRoot.append(styleSheet.cloneNode(true));
3302
+ shadowRootNodes.unshift(styleSheet.cloneNode(true));
3302
3303
  }
3303
3304
  }
3304
3305
  }
@@ -3376,7 +3377,7 @@ var initializeClientHydrate = (hostElm, tagName, hostId, hostRef) => {
3376
3377
  slot.$elm$.parentElement.classList.add(scopeId2 + "-s");
3377
3378
  });
3378
3379
  }
3379
- if (import_app_data9.BUILD.shadowDom && shadowRoot) {
3380
+ if (import_app_data9.BUILD.shadowDom && shadowRoot && !shadowRoot.childNodes.length) {
3380
3381
  let rnIdex = 0;
3381
3382
  const rnLen = shadowRootNodes.length;
3382
3383
  if (rnLen) {
@@ -3727,9 +3728,6 @@ var createSupportsRuleRe = (selector) => {
3727
3728
  "g"
3728
3729
  );
3729
3730
  };
3730
- var _colonSlottedRe = createSupportsRuleRe("::slotted");
3731
- var _colonHostRe = createSupportsRuleRe(":host");
3732
- var _colonHostContextRe = createSupportsRuleRe(":host-context");
3733
3731
  var _commentRe = /\/\*\s*[\s\S]*?\*\//g;
3734
3732
  var stripComments = (input) => {
3735
3733
  return input.replace(_commentRe, "");
@@ -3807,6 +3805,9 @@ var insertPolyfillHostInCssText = (cssText) => {
3807
3805
  supportsBlocks.push(selectorContent);
3808
3806
  return `@supports selector(${placeholder})`;
3809
3807
  });
3808
+ const _colonSlottedRe = createSupportsRuleRe("::slotted");
3809
+ const _colonHostRe = createSupportsRuleRe(":host");
3810
+ const _colonHostContextRe = createSupportsRuleRe(":host-context");
3810
3811
  cssText = cssText.replace(_colonHostContextRe, `$1${_polyfillHostContext}`).replace(_colonHostRe, `$1${_polyfillHost}`).replace(_colonSlottedRe, `$1${_polyfillSlotted}`);
3811
3812
  supportsBlocks.forEach((originalSelector, index) => {
3812
3813
  cssText = cssText.replace(`__supports_${index}__`, originalSelector);
@@ -4165,7 +4166,7 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
4165
4166
  } else if (import_app_data11.BUILD.vdomKey && memberName === "key") {
4166
4167
  } else if (import_app_data11.BUILD.vdomRef && memberName === "ref") {
4167
4168
  if (newValue) {
4168
- newValue(elm);
4169
+ queueRefAttachment(newValue, elm);
4169
4170
  }
4170
4171
  } else if (import_app_data11.BUILD.vdomListener && (import_app_data11.BUILD.lazyLoad ? !isProp : !elm.__lookupSetter__(memberName)) && memberName[0] === "o" && memberName[1] === "n") {
4171
4172
  if (memberName[2] === "-") {
@@ -4294,6 +4295,8 @@ var useNativeShadowDom = false;
4294
4295
  var checkSlotFallbackVisibility = false;
4295
4296
  var checkSlotRelocate = false;
4296
4297
  var isSvgMode = false;
4298
+ var refCallbacksToRemove = [];
4299
+ var refCallbacksToAttach = [];
4297
4300
  var createElm = (oldParentVNode, newParentVNode, childIndex) => {
4298
4301
  var _a;
4299
4302
  const newVNode2 = newParentVNode.$children$[childIndex];
@@ -4321,7 +4324,7 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
4321
4324
  `The JSX ${newVNode2.$text$ !== null ? `"${newVNode2.$text$}" text` : `"${newVNode2.$tag$}" element`} node should not be shared within the same renderer. The renderer caches element lookups in order to improve performance. However, a side effect from this is that the exact same JSX node should not be reused. For more information please see https://stenciljs.com/docs/templating-jsx#avoid-shared-jsx-nodes`
4322
4325
  );
4323
4326
  }
4324
- if (import_app_data13.BUILD.vdomText && newVNode2.$text$ !== null) {
4327
+ if (import_app_data13.BUILD.vdomText && newVNode2.$text$ != null) {
4325
4328
  elm = newVNode2.$elm$ = win.document.createTextNode(newVNode2.$text$);
4326
4329
  } else if (import_app_data13.BUILD.slotRelocation && newVNode2.$flags$ & 1 /* isSlotReference */) {
4327
4330
  elm = newVNode2.$elm$ = import_app_data13.BUILD.isDebug || import_app_data13.BUILD.hydrateServerSide ? slotReferenceDebugNode(newVNode2) : win.document.createTextNode("");
@@ -4333,9 +4336,7 @@ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
4333
4336
  isSvgMode = newVNode2.$tag$ === "svg";
4334
4337
  }
4335
4338
  if (!win.document) {
4336
- throw new Error(
4337
- "You are trying to render a Stencil component in an environment that doesn't support the DOM. Make sure to populate the [`window`](https://developer.mozilla.org/en-US/docs/Web/API/Window/window) object before rendering a component."
4338
- );
4339
+ throw new Error("You are trying to render a Stencil component in an environment that doesn't support the DOM.");
4339
4340
  }
4340
4341
  elm = newVNode2.$elm$ = import_app_data13.BUILD.svg ? win.document.createElementNS(
4341
4342
  isSvgMode ? SVG_NS : HTML_NS,
@@ -4593,7 +4594,7 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
4593
4594
  const tag = newVNode2.$tag$;
4594
4595
  const text = newVNode2.$text$;
4595
4596
  let defaultHolder;
4596
- if (!import_app_data13.BUILD.vdomText || text === null) {
4597
+ if (!import_app_data13.BUILD.vdomText || text == null) {
4597
4598
  if (import_app_data13.BUILD.svg) {
4598
4599
  isSvgMode = tag === "svg" ? true : tag === "foreignObject" ? false : isSvgMode;
4599
4600
  }
@@ -4682,21 +4683,38 @@ var markSlotContentForRelocation = (elm) => {
4682
4683
  };
4683
4684
  var nullifyVNodeRefs = (vNode) => {
4684
4685
  if (import_app_data13.BUILD.vdomRef) {
4685
- vNode.$attrs$ && vNode.$attrs$.ref && vNode.$attrs$.ref(null);
4686
+ if (vNode.$attrs$ && vNode.$attrs$.ref) {
4687
+ refCallbacksToRemove.push(() => vNode.$attrs$.ref(null));
4688
+ }
4686
4689
  vNode.$children$ && vNode.$children$.map(nullifyVNodeRefs);
4687
4690
  }
4688
4691
  };
4692
+ var queueRefAttachment = (refCallback, elm) => {
4693
+ if (import_app_data13.BUILD.vdomRef) {
4694
+ refCallbacksToAttach.push(() => refCallback(elm));
4695
+ }
4696
+ };
4697
+ var flushQueuedRefCallbacks = () => {
4698
+ if (import_app_data13.BUILD.vdomRef) {
4699
+ refCallbacksToRemove.forEach((cb) => cb());
4700
+ refCallbacksToRemove.length = 0;
4701
+ refCallbacksToAttach.forEach((cb) => cb());
4702
+ refCallbacksToAttach.length = 0;
4703
+ }
4704
+ };
4689
4705
  var insertBefore = (parent, newNode, reference, isInitialLoad) => {
4690
- if (import_app_data13.BUILD.scoped && typeof newNode["s-sn"] === "string" && !!newNode["s-sr"] && !!newNode["s-cr"]) {
4691
- addRemoveSlotScopedClass(newNode["s-cr"], newNode, parent, newNode.parentElement);
4692
- } else if (typeof newNode["s-sn"] === "string") {
4693
- if (import_app_data13.BUILD.experimentalSlotFixes && parent.getRootNode().nodeType !== 11 /* DOCUMENT_FRAGMENT_NODE */) {
4694
- patchParentNode(newNode);
4706
+ if (import_app_data13.BUILD.slotRelocation) {
4707
+ if (import_app_data13.BUILD.scoped && typeof newNode["s-sn"] === "string" && !!newNode["s-sr"] && !!newNode["s-cr"]) {
4708
+ addRemoveSlotScopedClass(newNode["s-cr"], newNode, parent, newNode.parentElement);
4709
+ } else if (typeof newNode["s-sn"] === "string") {
4710
+ if (import_app_data13.BUILD.experimentalSlotFixes && parent.getRootNode().nodeType !== 11 /* DOCUMENT_FRAGMENT_NODE */) {
4711
+ patchParentNode(newNode);
4712
+ }
4713
+ parent.insertBefore(newNode, reference);
4714
+ const { slotNode } = findSlotFromSlottedNode(newNode);
4715
+ if (slotNode && !isInitialLoad) dispatchSlotChangeEvent(slotNode);
4716
+ return newNode;
4695
4717
  }
4696
- parent.insertBefore(newNode, reference);
4697
- const { slotNode } = findSlotFromSlottedNode(newNode);
4698
- if (slotNode && !isInitialLoad) dispatchSlotChangeEvent(slotNode);
4699
- return newNode;
4700
4718
  }
4701
4719
  if (parent.__insertBefore) {
4702
4720
  return parent.__insertBefore(newNode, reference);
@@ -4872,6 +4890,7 @@ render() {
4872
4890
  }
4873
4891
  }
4874
4892
  contentRef = void 0;
4893
+ flushQueuedRefCallbacks();
4875
4894
  };
4876
4895
  var slotReferenceDebugNode = (slotVNode) => {
4877
4896
  var _a;
@@ -6024,7 +6043,7 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
6024
6043
  });
6025
6044
  });
6026
6045
  if (cmpTags.length > 0) {
6027
- if (hasSlotRelocation) {
6046
+ if (import_app_data21.BUILD.slotRelocation && hasSlotRelocation) {
6028
6047
  dataStyles.textContent += SLOT_FB_CSS;
6029
6048
  }
6030
6049
  if (import_app_data21.BUILD.invisiblePrehydration && (import_app_data21.BUILD.hydratedClass || import_app_data21.BUILD.hydratedAttribute)) {
@@ -6158,11 +6177,22 @@ function setTagTransformer(transformer) {
6158
6177
 
6159
6178
  // src/runtime/vdom/jsx-dev-runtime.ts
6160
6179
  function jsxDEV(type, props, key, _isStaticChildren, _source, _self) {
6161
- const { children, ...rest } = props;
6162
- const vnodeData = key !== void 0 ? { ...rest, key } : rest;
6163
- if (Array.isArray(children)) {
6164
- return h(type, vnodeData, ...children);
6165
- } else if (children !== void 0) {
6180
+ const propsObj = props || {};
6181
+ const { children, ...rest } = propsObj;
6182
+ let vnodeData = rest;
6183
+ if (key !== void 0 && !("key" in rest)) {
6184
+ vnodeData = { ...rest, key };
6185
+ }
6186
+ if (vnodeData && Object.keys(vnodeData).length === 0) {
6187
+ vnodeData = null;
6188
+ }
6189
+ if (children !== void 0) {
6190
+ if (Array.isArray(children)) {
6191
+ return h(type, vnodeData, ...children);
6192
+ }
6193
+ if (typeof children === "object" && children !== null && "$flags$" in children) {
6194
+ return h(type, vnodeData, children);
6195
+ }
6166
6196
  return h(type, vnodeData, children);
6167
6197
  }
6168
6198
  return h(type, vnodeData);
@@ -6173,7 +6203,7 @@ function jsx(type, props, key) {
6173
6203
  const propsObj = props || {};
6174
6204
  const { children, ...rest } = propsObj;
6175
6205
  let vnodeData = rest;
6176
- if (key !== void 0) {
6206
+ if (key !== void 0 && !("key" in rest)) {
6177
6207
  vnodeData = { ...rest, key };
6178
6208
  }
6179
6209
  if (vnodeData && Object.keys(vnodeData).length === 0) {
@@ -0,0 +1,2 @@
1
+ // Type definitions for automatic JSX development runtime in testing
2
+ export { jsxDEV, Fragment, JSX } from '../stencil-core/jsx-dev-runtime';
@@ -0,0 +1,8 @@
1
+ // Export automatic JSX development runtime for testing
2
+ // This file allows TypeScript's automatic JSX transform to work in tests
3
+ // when using jsxImportSource: "@stencil/core/internal/testing" with jsx: "react-jsxdev"
4
+ const testing = require('./index.js');
5
+ module.exports = {
6
+ jsxDEV: testing.jsxDEV,
7
+ Fragment: testing.Fragment,
8
+ };
@@ -0,0 +1,2 @@
1
+ // Type definitions for automatic JSX runtime in testing
2
+ export { jsx, jsxs, Fragment, JSX } from '../stencil-core/jsx-runtime';
@@ -0,0 +1,9 @@
1
+ // Export automatic JSX runtime for testing
2
+ // This file allows TypeScript's automatic JSX transform to work in tests
3
+ // when using jsxImportSource: "@stencil/core/internal/testing"
4
+ const testing = require('./index.js');
5
+ module.exports = {
6
+ jsx: testing.jsx,
7
+ jsxs: testing.jsxs,
8
+ Fragment: testing.Fragment,
9
+ };
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stencil/core/internal/testing",
3
- "version": "4.41.1",
3
+ "version": "4.41.2-dev.1768799567.75e7562",
4
4
  "description": "Stencil internal testing platform to be imported by the Stencil Compiler. Breaking changes can and will happen at any time.",
5
5
  "main": "./index.js",
6
6
  "private": true
@@ -1,5 +1,5 @@
1
1
  /*!
2
- Stencil Mock Doc (CommonJS) v4.41.1 | MIT Licensed | https://stenciljs.com
2
+ Stencil Mock Doc (CommonJS) v4.41.2-dev.1768799567.75e7562 | MIT Licensed | https://stenciljs.com
3
3
  */
4
4
  "use strict";
5
5
  var __defProp = Object.defineProperty;
@@ -9496,7 +9496,7 @@ var MockWindow = class {
9496
9496
  if (this.__timeouts == null) {
9497
9497
  this.__timeouts = /* @__PURE__ */ new Set();
9498
9498
  }
9499
- ms = Math.min(ms, this.__maxTimeout);
9499
+ ms = Math.min(ms != null ? ms : 0, this.__maxTimeout);
9500
9500
  if (this.__allowInterval) {
9501
9501
  const intervalId = this.__setInterval(() => {
9502
9502
  if (this.__timeouts) {
@@ -9544,7 +9544,7 @@ var MockWindow = class {
9544
9544
  if (this.__timeouts == null) {
9545
9545
  this.__timeouts = /* @__PURE__ */ new Set();
9546
9546
  }
9547
- ms = Math.min(ms, this.__maxTimeout);
9547
+ ms = Math.min(ms != null ? ms : 0, this.__maxTimeout);
9548
9548
  const timeoutId = this.__setTimeout.call(
9549
9549
  nativeWindow || this,
9550
9550
  () => {
package/mock-doc/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- Stencil Mock Doc v4.41.1 | MIT Licensed | https://stenciljs.com
2
+ Stencil Mock Doc v4.41.2-dev.1768799567.75e7562 | MIT Licensed | https://stenciljs.com
3
3
  */
4
4
  var __defProp = Object.defineProperty;
5
5
  var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
@@ -9444,7 +9444,7 @@ var MockWindow = class {
9444
9444
  if (this.__timeouts == null) {
9445
9445
  this.__timeouts = /* @__PURE__ */ new Set();
9446
9446
  }
9447
- ms = Math.min(ms, this.__maxTimeout);
9447
+ ms = Math.min(ms != null ? ms : 0, this.__maxTimeout);
9448
9448
  if (this.__allowInterval) {
9449
9449
  const intervalId = this.__setInterval(() => {
9450
9450
  if (this.__timeouts) {
@@ -9492,7 +9492,7 @@ var MockWindow = class {
9492
9492
  if (this.__timeouts == null) {
9493
9493
  this.__timeouts = /* @__PURE__ */ new Set();
9494
9494
  }
9495
- ms = Math.min(ms, this.__maxTimeout);
9495
+ ms = Math.min(ms != null ? ms : 0, this.__maxTimeout);
9496
9496
  const timeoutId = this.__setTimeout.call(
9497
9497
  nativeWindow || this,
9498
9498
  () => {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stencil/core/mock-doc",
3
- "version": "4.41.1",
3
+ "version": "4.41.2-dev.1768799567.75e7562",
4
4
  "description": "Mock window, document and DOM outside of a browser environment.",
5
5
  "main": "./index.cjs",
6
6
  "module": "./index.js",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stencil/core",
3
- "version": "4.41.1",
3
+ "version": "4.41.2-dev.1768799567.75e7562",
4
4
  "license": "MIT",
5
5
  "main": "./internal/stencil-core/index.cjs",
6
6
  "module": "./internal/stencil-core/index.js",
@@ -54,6 +54,16 @@
54
54
  "import": "./internal/testing/index.js",
55
55
  "require": "./internal/testing/index.js"
56
56
  },
57
+ "./internal/testing/jsx-runtime": {
58
+ "types": "./internal/testing/jsx-runtime.d.ts",
59
+ "import": "./internal/testing/jsx-runtime.js",
60
+ "require": "./internal/testing/jsx-runtime.js"
61
+ },
62
+ "./internal/testing/jsx-dev-runtime": {
63
+ "types": "./internal/testing/jsx-dev-runtime.d.ts",
64
+ "import": "./internal/testing/jsx-dev-runtime.js",
65
+ "require": "./internal/testing/jsx-dev-runtime.js"
66
+ },
57
67
  "./internal/testing/*": {
58
68
  "import": "./internal/testing/*"
59
69
  },
@@ -125,7 +135,8 @@
125
135
  "spellcheck.code": "cspell --config cspell-code.json --no-progress \"src/**/*.ts\" \"src/**/*.tsx\" \"scripts/**/*.ts\"",
126
136
  "spellcheck.markdown": "cspell --config cspell-markdown.json --no-progress \"*.md\" \"**/*.md\"",
127
137
  "test": "node --experimental-vm-modules ./node_modules/jest/bin/jest.js --coverage",
128
- "test.analysis": "cd test && npm run analysis.build-and-analyze",
138
+ "test.analysis": "cd test && npm ci && npm run analysis.build-and-analyze",
139
+ "test.bundle-size": "cd test/bundle-size && npm test",
129
140
  "test.bundlers": "cd test && npm run bundlers",
130
141
  "test.copytask": "cd test/copy-task && npm ci && npm run test",
131
142
  "test.dist": "npm run ts scripts/index.ts -- --validate-build",
@@ -1,5 +1,5 @@
1
1
  /*
2
- Stencil Screenshot v4.41.1 | MIT Licensed | https://stenciljs.com
2
+ Stencil Screenshot v4.41.2-dev.1768799567.75e7562 | MIT Licensed | https://stenciljs.com
3
3
  */
4
4
  "use strict";
5
5
  var __create = Object.create;
@@ -2128,11 +2128,6 @@ minimatch.Minimatch = Minimatch;
2128
2128
  minimatch.escape = escape;
2129
2129
  minimatch.unescape = unescape;
2130
2130
 
2131
- // src/utils/regular-expression.ts
2132
- var escapeRegExpSpecialCharacters = (text) => {
2133
- return text.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
2134
- };
2135
-
2136
2131
  // src/utils/result.ts
2137
2132
  var result_exports = {};
2138
2133
  __export(result_exports, {
@@ -2316,18 +2311,6 @@ var _cssColonHostRe = new RegExp("(" + _polyfillHost + _parenSuffix, "gim");
2316
2311
  var _cssColonHostContextRe = new RegExp("(" + _polyfillHostContext + _parenSuffix, "gim");
2317
2312
  var _cssColonSlottedRe = new RegExp("(" + _polyfillSlotted + _parenSuffix, "gim");
2318
2313
  var _polyfillHostNoCombinator = _polyfillHost + "-no-combinator";
2319
- var createSupportsRuleRe = (selector) => {
2320
- const safeSelector = escapeRegExpSpecialCharacters(selector);
2321
- return new RegExp(
2322
- // First capture group: match any context before the selector that's not inside @supports selector()
2323
- // Using negative lookahead to avoid matching inside @supports selector(...) condition
2324
- `(^|[^@]|@(?!supports\\s+selector\\s*\\([^{]*?${safeSelector}))(${safeSelector}\\b)`,
2325
- "g"
2326
- );
2327
- };
2328
- var _colonSlottedRe = createSupportsRuleRe("::slotted");
2329
- var _colonHostRe = createSupportsRuleRe(":host");
2330
- var _colonHostContextRe = createSupportsRuleRe(":host-context");
2331
2314
 
2332
2315
  // src/runtime/vdom/set-accessor.ts
2333
2316
  var CAPTURE_EVENT_SUFFIX = "Capture";
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stencil/core/screenshot",
3
- "version": "4.41.1",
3
+ "version": "4.41.2-dev.1768799567.75e7562",
4
4
  "description": "Stencil Screenshot.",
5
5
  "main": "./index.js",
6
6
  "types": "./index.d.ts",
@@ -1,5 +1,5 @@
1
1
  /*
2
- Stencil Screenshot Pixel Match v4.41.1 | MIT Licensed | https://stenciljs.com
2
+ Stencil Screenshot Pixel Match v4.41.2-dev.1768799567.75e7562 | MIT Licensed | https://stenciljs.com
3
3
  */
4
4
  "use strict";
5
5
  var __create = Object.create;