@stencil/core 4.45.5 → 4.45.6-dev.1796101679.176b027
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cli/index.cjs +1 -1
- package/cli/index.js +1 -1
- package/cli/package.json +1 -1
- package/compiler/package.json +1 -1
- package/compiler/stencil.js +109 -73
- package/dev-server/client/index.js +1 -1
- package/dev-server/client/package.json +1 -1
- package/dev-server/connector.html +2 -2
- package/dev-server/index.js +1 -1
- package/dev-server/package.json +1 -1
- package/dev-server/server-process.js +2 -2
- package/internal/app-data/package.json +1 -1
- package/internal/app-globals/package.json +1 -1
- package/internal/client/index.js +6 -3
- package/internal/client/package.json +1 -1
- package/internal/client/patch-browser.js +1 -1
- package/internal/hydrate/index.js +6 -3
- package/internal/hydrate/package.json +1 -1
- package/internal/hydrate/runner.js +78 -5
- package/internal/package.json +1 -1
- package/internal/stencil-core/index.js +2 -0
- package/internal/stencil-public-compiler.d.ts +8 -0
- package/internal/stencil-public-runtime.d.ts +51 -0
- package/internal/testing/index.js +5 -2
- package/internal/testing/package.json +1 -1
- package/mock-doc/index.cjs +78 -5
- package/mock-doc/index.d.ts +7 -2
- package/mock-doc/index.js +78 -5
- package/mock-doc/package.json +1 -1
- package/package.json +1 -1
- package/screenshot/index.js +1 -1
- package/screenshot/package.json +1 -1
- package/screenshot/pixel-match.js +1 -1
- package/sys/node/index.js +9 -9
- package/sys/node/package.json +1 -1
- package/sys/node/worker.js +1 -1
- package/testing/index.js +6 -1
- package/testing/package.json +1 -1
- package/testing/puppeteer/puppeteer-element.d.ts +1 -1
- package/testing/puppeteer/test/puppeteer-browser.spec.d.ts +1 -0
package/internal/client/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
Stencil Client Platform v4.45.
|
|
2
|
+
Stencil Client Platform v4.45.6-dev.1796101679.176b027 | MIT Licensed | https://stenciljs.com
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
5
|
// src/client/client-build.ts
|
|
@@ -1253,7 +1253,7 @@ var isComplexType = (o) => {
|
|
|
1253
1253
|
|
|
1254
1254
|
// src/runtime/vdom/h.ts
|
|
1255
1255
|
var h = (nodeName, vnodeData, ...children) => {
|
|
1256
|
-
if (typeof nodeName === "string") {
|
|
1256
|
+
if (typeof nodeName === "string" && nodeName.includes("-")) {
|
|
1257
1257
|
nodeName = transformTag(nodeName);
|
|
1258
1258
|
}
|
|
1259
1259
|
let child = null;
|
|
@@ -1803,7 +1803,8 @@ var addSlottedNodes = (slottedNodes, slotNodeId, slotName, slotNode, hostId) =>
|
|
|
1803
1803
|
slottedNodes[slotNodeId] = slottedNodes[slotNodeId] || [];
|
|
1804
1804
|
if (!slottedNode || ((_a = slottedNode.nodeValue) == null ? void 0 : _a.startsWith(SLOT_NODE_ID + "."))) return;
|
|
1805
1805
|
do {
|
|
1806
|
-
|
|
1806
|
+
const ssrSlotName = slottedNode && slottedNode["getAttribute"] && slottedNode.getAttribute("s-sn");
|
|
1807
|
+
if (slottedNode && (ssrSlotName === slotName || (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 */))) {
|
|
1807
1808
|
slottedNode["s-sn"] = slotName;
|
|
1808
1809
|
slottedNodes[slotNodeId].push({ slot: slotNode, node: slottedNode, hostId });
|
|
1809
1810
|
}
|
|
@@ -2517,6 +2518,8 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
|
|
|
2517
2518
|
memberName = memberName.slice(3);
|
|
2518
2519
|
} else if (isMemberInElement(win, ln)) {
|
|
2519
2520
|
memberName = ln.slice(2);
|
|
2521
|
+
} else if (memberName.endsWith(CAPTURE_EVENT_SUFFIX) && isMemberInElement(win, ln.slice(0, -CAPTURE_EVENT_SUFFIX.length))) {
|
|
2522
|
+
memberName = ln.slice(2, -CAPTURE_EVENT_SUFFIX.length) + CAPTURE_EVENT_SUFFIX;
|
|
2520
2523
|
} else {
|
|
2521
2524
|
memberName = ln[2] + memberName.slice(3);
|
|
2522
2525
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stencil/core/internal/client",
|
|
3
|
-
"version": "4.45.
|
|
3
|
+
"version": "4.45.6-dev.1796101679.176b027",
|
|
4
4
|
"description": "Stencil internal client platform to be imported by the Stencil Compiler and internal runtime. Breaking changes can and will happen at any time.",
|
|
5
5
|
"main": "./index.js",
|
|
6
6
|
"exports": "./index.js",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
Stencil Hydrate Platform v4.45.
|
|
2
|
+
Stencil Hydrate Platform v4.45.6-dev.1796101679.176b027 | MIT Licensed | https://stenciljs.com
|
|
3
3
|
*/
|
|
4
4
|
var __create = Object.create;
|
|
5
5
|
var __defProp = Object.defineProperty;
|
|
@@ -1335,7 +1335,7 @@ var isComplexType = (o) => {
|
|
|
1335
1335
|
|
|
1336
1336
|
// src/runtime/vdom/h.ts
|
|
1337
1337
|
var h = (nodeName, vnodeData, ...children) => {
|
|
1338
|
-
if (typeof nodeName === "string") {
|
|
1338
|
+
if (typeof nodeName === "string" && nodeName.includes("-")) {
|
|
1339
1339
|
nodeName = transformTag(nodeName);
|
|
1340
1340
|
}
|
|
1341
1341
|
let child = null;
|
|
@@ -1885,7 +1885,8 @@ var addSlottedNodes = (slottedNodes, slotNodeId, slotName, slotNode, hostId) =>
|
|
|
1885
1885
|
slottedNodes[slotNodeId] = slottedNodes[slotNodeId] || [];
|
|
1886
1886
|
if (!slottedNode || ((_a2 = slottedNode.nodeValue) == null ? void 0 : _a2.startsWith(SLOT_NODE_ID + "."))) return;
|
|
1887
1887
|
do {
|
|
1888
|
-
|
|
1888
|
+
const ssrSlotName = slottedNode && slottedNode["getAttribute"] && slottedNode.getAttribute("s-sn");
|
|
1889
|
+
if (slottedNode && (ssrSlotName === slotName || (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 */))) {
|
|
1889
1890
|
slottedNode["s-sn"] = slotName;
|
|
1890
1891
|
slottedNodes[slotNodeId].push({ slot: slotNode, node: slottedNode, hostId });
|
|
1891
1892
|
}
|
|
@@ -2599,6 +2600,8 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
|
|
|
2599
2600
|
memberName = memberName.slice(3);
|
|
2600
2601
|
} else if (isMemberInElement(win, ln)) {
|
|
2601
2602
|
memberName = ln.slice(2);
|
|
2603
|
+
} else if (memberName.endsWith(CAPTURE_EVENT_SUFFIX) && isMemberInElement(win, ln.slice(0, -CAPTURE_EVENT_SUFFIX.length))) {
|
|
2604
|
+
memberName = ln.slice(2, -CAPTURE_EVENT_SUFFIX.length) + CAPTURE_EVENT_SUFFIX;
|
|
2602
2605
|
} else {
|
|
2603
2606
|
memberName = ln[2] + memberName.slice(3);
|
|
2604
2607
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stencil/core/internal/hydrate",
|
|
3
|
-
"version": "4.45.
|
|
3
|
+
"version": "4.45.6-dev.1796101679.176b027",
|
|
4
4
|
"description": "Stencil internal hydrate 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 Hydrate Runner v4.45.
|
|
2
|
+
Stencil Hydrate Runner v4.45.6-dev.1796101679.176b027 | MIT Licensed | https://stenciljs.com
|
|
3
3
|
*/
|
|
4
4
|
var __create = Object.create;
|
|
5
5
|
var __defProp = Object.defineProperty;
|
|
@@ -531,7 +531,7 @@ var MockCSSStyleDeclaration = class {
|
|
|
531
531
|
this._styles.clear();
|
|
532
532
|
return;
|
|
533
533
|
}
|
|
534
|
-
cssText
|
|
534
|
+
splitDeclarations(cssText).forEach((rule) => {
|
|
535
535
|
rule = rule.trim();
|
|
536
536
|
if (rule.length > 0) {
|
|
537
537
|
const splt = rule.split(":");
|
|
@@ -546,6 +546,39 @@ var MockCSSStyleDeclaration = class {
|
|
|
546
546
|
});
|
|
547
547
|
}
|
|
548
548
|
};
|
|
549
|
+
function splitDeclarations(cssText) {
|
|
550
|
+
const declarations = [];
|
|
551
|
+
let current = "";
|
|
552
|
+
let depth = 0;
|
|
553
|
+
let quote = "";
|
|
554
|
+
for (let i = 0; i < cssText.length; i++) {
|
|
555
|
+
const char = cssText[i];
|
|
556
|
+
if (char === "\\" && i + 1 < cssText.length) {
|
|
557
|
+
current += char + cssText[++i];
|
|
558
|
+
continue;
|
|
559
|
+
}
|
|
560
|
+
if (quote) {
|
|
561
|
+
if (char === quote) {
|
|
562
|
+
quote = "";
|
|
563
|
+
}
|
|
564
|
+
} else if (char === '"' || char === "'") {
|
|
565
|
+
quote = char;
|
|
566
|
+
} else if (char === "(") {
|
|
567
|
+
depth++;
|
|
568
|
+
} else if (char === ")") {
|
|
569
|
+
if (depth > 0) {
|
|
570
|
+
depth--;
|
|
571
|
+
}
|
|
572
|
+
} else if (char === ";" && depth === 0) {
|
|
573
|
+
declarations.push(current);
|
|
574
|
+
current = "";
|
|
575
|
+
continue;
|
|
576
|
+
}
|
|
577
|
+
current += char;
|
|
578
|
+
}
|
|
579
|
+
declarations.push(current);
|
|
580
|
+
return declarations;
|
|
581
|
+
}
|
|
549
582
|
function createCSSStyleDeclaration() {
|
|
550
583
|
return new Proxy(new MockCSSStyleDeclaration(), cssProxyHandler);
|
|
551
584
|
}
|
|
@@ -10737,7 +10770,7 @@ style="${escapeString(cssText, true)}">`;
|
|
|
10737
10770
|
yield* streamToHtml(shadowRoot, opts, output);
|
|
10738
10771
|
output.indent = output.indent - ((_d = opts.indentSpaces) != null ? _d : 0);
|
|
10739
10772
|
const childNodes = getChildNodes(node);
|
|
10740
|
-
if (opts.newLines && (childNodes.length === 0 || childNodes.length === 1 && childNodes[0].nodeType === 3 /* TEXT_NODE */ && ((_e = childNodes[0].nodeValue) == null ? void 0 : _e.trim()) === "")) {
|
|
10773
|
+
if (opts.newLines && (childNodes.length === 0 || childNodes.length === 1 && childNodes[0].nodeType === 3 /* TEXT_NODE */ && ((_e = childNodes[0].nodeValue) == null ? void 0 : _e.trim()) === "" || hasOnlyRemovedComments(childNodes, opts))) {
|
|
10741
10774
|
yield "\n";
|
|
10742
10775
|
output.currentLineWidth = 0;
|
|
10743
10776
|
for (let i = 0; i < output.indent; i++) {
|
|
@@ -10752,6 +10785,7 @@ style="${escapeString(cssText, true)}">`;
|
|
|
10752
10785
|
const childNodeLength = childNodes.length;
|
|
10753
10786
|
if (childNodeLength > 0) {
|
|
10754
10787
|
if (childNodeLength === 1 && childNodes[0].nodeType === 3 /* TEXT_NODE */ && (typeof childNodes[0].nodeValue !== "string" || childNodes[0].nodeValue.trim() === "")) {
|
|
10788
|
+
} else if (hasOnlyRemovedComments(childNodes, opts)) {
|
|
10755
10789
|
} else {
|
|
10756
10790
|
const isWithinWhitespaceSensitiveNode = opts.newLines || ((_f = opts.indentSpaces) != null ? _f : 0) > 0 ? isWithinWhitespaceSensitive(node) : false;
|
|
10757
10791
|
if (!isWithinWhitespaceSensitiveNode && ((_g = opts.indentSpaces) != null ? _g : 0) > 0 && ignoreTag === false) {
|
|
@@ -10868,8 +10902,7 @@ ${" ".repeat(output.indent)}<!--r.${sId.value}-->`;
|
|
|
10868
10902
|
}
|
|
10869
10903
|
} else if (node.nodeType === 8 /* COMMENT_NODE */) {
|
|
10870
10904
|
const nodeValue = node.nodeValue;
|
|
10871
|
-
|
|
10872
|
-
if (opts.removeHtmlComments && !isHydrateAnnotation) {
|
|
10905
|
+
if (isRemovedComment(node, opts)) {
|
|
10873
10906
|
return;
|
|
10874
10907
|
}
|
|
10875
10908
|
const isWithinWhitespaceSensitiveNode = opts.newLines || ((_o = opts.indentSpaces) != null ? _o : 0) > 0 ? isWithinWhitespaceSensitive(node) : false;
|
|
@@ -10921,6 +10954,26 @@ function isWithinWhitespaceSensitive(node) {
|
|
|
10921
10954
|
}
|
|
10922
10955
|
return false;
|
|
10923
10956
|
}
|
|
10957
|
+
function isRemovedComment(node, opts) {
|
|
10958
|
+
if (node.nodeType !== 8 /* COMMENT_NODE */ || !opts.removeHtmlComments) {
|
|
10959
|
+
return false;
|
|
10960
|
+
}
|
|
10961
|
+
const nodeValue = node.nodeValue;
|
|
10962
|
+
const isHydrateAnnotation = (nodeValue == null ? void 0 : nodeValue.startsWith(CONTENT_REF_ID + ".")) || (nodeValue == null ? void 0 : nodeValue.startsWith(ORG_LOCATION_ID + ".")) || (nodeValue == null ? void 0 : nodeValue.startsWith(SLOT_NODE_ID + ".")) || (nodeValue == null ? void 0 : nodeValue.startsWith(TEXT_NODE_ID + "."));
|
|
10963
|
+
return !isHydrateAnnotation;
|
|
10964
|
+
}
|
|
10965
|
+
function hasOnlyRemovedComments(childNodes, opts) {
|
|
10966
|
+
let hasRemovedComment = false;
|
|
10967
|
+
for (let i = 0; i < childNodes.length; i++) {
|
|
10968
|
+
const childNode = childNodes[i];
|
|
10969
|
+
if (isRemovedComment(childNode, opts)) {
|
|
10970
|
+
hasRemovedComment = true;
|
|
10971
|
+
} else if (childNode.nodeType !== 3 /* TEXT_NODE */ || typeof childNode.nodeValue === "string" && childNode.nodeValue.trim() !== "") {
|
|
10972
|
+
return false;
|
|
10973
|
+
}
|
|
10974
|
+
}
|
|
10975
|
+
return hasRemovedComment;
|
|
10976
|
+
}
|
|
10924
10977
|
function getChildNodes(node) {
|
|
10925
10978
|
return node.__childNodes || node.childNodes;
|
|
10926
10979
|
}
|
|
@@ -11763,6 +11816,19 @@ var MockElement = class extends MockNode2 {
|
|
|
11763
11816
|
set title(value) {
|
|
11764
11817
|
this.setAttributeNS(null, "title", value);
|
|
11765
11818
|
}
|
|
11819
|
+
toggleAttribute(attrName, force) {
|
|
11820
|
+
const has = this.hasAttribute(attrName);
|
|
11821
|
+
if (force != null ? force : !has) {
|
|
11822
|
+
if (!has) {
|
|
11823
|
+
this.setAttribute(attrName, "");
|
|
11824
|
+
}
|
|
11825
|
+
return true;
|
|
11826
|
+
}
|
|
11827
|
+
if (has) {
|
|
11828
|
+
this.removeAttribute(attrName);
|
|
11829
|
+
}
|
|
11830
|
+
return false;
|
|
11831
|
+
}
|
|
11766
11832
|
animate() {
|
|
11767
11833
|
}
|
|
11768
11834
|
onanimationstart() {
|
|
@@ -12907,6 +12973,13 @@ function getLabelsForElement(elm) {
|
|
|
12907
12973
|
parent = parent.parentNode;
|
|
12908
12974
|
}
|
|
12909
12975
|
}
|
|
12976
|
+
Object.defineProperty(labels, "item", {
|
|
12977
|
+
value: (index) => {
|
|
12978
|
+
var _a3;
|
|
12979
|
+
return (_a3 = labels[index]) != null ? _a3 : null;
|
|
12980
|
+
},
|
|
12981
|
+
enumerable: false
|
|
12982
|
+
});
|
|
12910
12983
|
return labels;
|
|
12911
12984
|
}
|
|
12912
12985
|
function patchPropAttributes(prototype, attrs, defaults2 = {}) {
|
package/internal/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stencil/core/internal",
|
|
3
|
-
"version": "4.45.
|
|
3
|
+
"version": "4.45.6-dev.1796101679.176b027",
|
|
4
4
|
"description": "Stencil internals only to be imported by the Stencil Compiler. Breaking changes can and will happen at any time.",
|
|
5
5
|
"main": "./index.js",
|
|
6
6
|
"types": "./index.d.ts",
|
|
@@ -1962,6 +1962,14 @@ export interface TestingConfig extends JestConfig {
|
|
|
1962
1962
|
* @default env.PUPPETEER_EXECUTABLE_PATH || env.CHROME_PATH || puppeteer.computeExecutablePath()
|
|
1963
1963
|
*/
|
|
1964
1964
|
browserExecutablePath?: string;
|
|
1965
|
+
/**
|
|
1966
|
+
* Maximum time in milliseconds to wait for the browser to start when running e2e tests.
|
|
1967
|
+
* Increase this value if the browser intermittently fails to start with a
|
|
1968
|
+
* "Timed out ... while trying to connect to the browser" error, e.g. on a heavily loaded CI machine.
|
|
1969
|
+
* Pass `0` to disable the timeout. Has no effect when `browserWSEndpoint` is used.
|
|
1970
|
+
* @default 30000
|
|
1971
|
+
*/
|
|
1972
|
+
browserLaunchTimeout?: number;
|
|
1965
1973
|
/**
|
|
1966
1974
|
* Url of remote Chrome instance to use instead of local Chrome.
|
|
1967
1975
|
*/
|
|
@@ -986,6 +986,10 @@ export declare namespace JSXBase {
|
|
|
986
986
|
export interface CanvasHTMLAttributes<T> extends HTMLAttributes<T> {
|
|
987
987
|
height?: number | string;
|
|
988
988
|
width?: number | string;
|
|
989
|
+
onContextLost?: (event: Event) => void;
|
|
990
|
+
onContextLostCapture?: (event: Event) => void;
|
|
991
|
+
onContextRestored?: (event: Event) => void;
|
|
992
|
+
onContextRestoredCapture?: (event: Event) => void;
|
|
989
993
|
}
|
|
990
994
|
export interface ColHTMLAttributes<T> extends HTMLAttributes<T> {
|
|
991
995
|
span?: number;
|
|
@@ -1380,6 +1384,8 @@ export declare namespace JSXBase {
|
|
|
1380
1384
|
src?: string;
|
|
1381
1385
|
srcLang?: string;
|
|
1382
1386
|
srclang?: string;
|
|
1387
|
+
onCueChange?: (event: Event) => void;
|
|
1388
|
+
onCueChangeCapture?: (event: Event) => void;
|
|
1383
1389
|
}
|
|
1384
1390
|
export interface VideoHTMLAttributes<T> extends MediaHTMLAttributes<T> {
|
|
1385
1391
|
height?: number | string;
|
|
@@ -1417,6 +1423,14 @@ export declare namespace JSXBase {
|
|
|
1417
1423
|
popover?: string | null;
|
|
1418
1424
|
focusgroup?: string;
|
|
1419
1425
|
focusgroupstart?: boolean;
|
|
1426
|
+
virtualKeyboardPolicy?: 'auto' | 'manual' | (string & {});
|
|
1427
|
+
virtualkeyboardpolicy?: 'auto' | 'manual' | (string & {});
|
|
1428
|
+
writingSuggestions?: 'true' | 'false' | (string & {});
|
|
1429
|
+
writingsuggestions?: 'true' | 'false' | (string & {});
|
|
1430
|
+
containertiming?: string;
|
|
1431
|
+
containertimingignore?: boolean;
|
|
1432
|
+
headingoffset?: number | string;
|
|
1433
|
+
headingreset?: boolean;
|
|
1420
1434
|
inputMode?: string;
|
|
1421
1435
|
inputmode?: string;
|
|
1422
1436
|
enterKeyHint?: string;
|
|
@@ -1715,6 +1729,13 @@ export declare namespace JSXBase {
|
|
|
1715
1729
|
z?: number | string;
|
|
1716
1730
|
zoomAndPan?: string;
|
|
1717
1731
|
}
|
|
1732
|
+
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/CommandEvent) */
|
|
1733
|
+
export interface CommandEvent extends Event {
|
|
1734
|
+
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/CommandEvent/command) */
|
|
1735
|
+
readonly command: string;
|
|
1736
|
+
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/CommandEvent/source) */
|
|
1737
|
+
readonly source: globalThis.Element | null;
|
|
1738
|
+
}
|
|
1718
1739
|
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/ToggleEvent) */
|
|
1719
1740
|
export interface ToggleEvent extends Event {
|
|
1720
1741
|
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/ToggleEvent/newState) */
|
|
@@ -1748,6 +1769,12 @@ export declare namespace JSXBase {
|
|
|
1748
1769
|
onBeforeToggleCapture?: (event: ToggleEvent) => void;
|
|
1749
1770
|
onToggle?: (event: ToggleEvent) => void;
|
|
1750
1771
|
onToggleCapture?: (event: ToggleEvent) => void;
|
|
1772
|
+
onBeforeMatch?: (event: Event) => void;
|
|
1773
|
+
onBeforeMatchCapture?: (event: Event) => void;
|
|
1774
|
+
onContentVisibilityAutoStateChange?: (event: ContentVisibilityAutoStateChangeEvent) => void;
|
|
1775
|
+
onContentVisibilityAutoStateChangeCapture?: (event: ContentVisibilityAutoStateChangeEvent) => void;
|
|
1776
|
+
onCommand?: (event: CommandEvent) => void;
|
|
1777
|
+
onCommandCapture?: (event: CommandEvent) => void;
|
|
1751
1778
|
onFocus?: (event: FocusEvent) => void;
|
|
1752
1779
|
onFocusCapture?: (event: FocusEvent) => void;
|
|
1753
1780
|
onFocusin?: (event: FocusEvent) => void;
|
|
@@ -1756,8 +1783,12 @@ export declare namespace JSXBase {
|
|
|
1756
1783
|
onFocusoutCapture?: (event: FocusEvent) => void;
|
|
1757
1784
|
onBlur?: (event: FocusEvent) => void;
|
|
1758
1785
|
onBlurCapture?: (event: FocusEvent) => void;
|
|
1786
|
+
onBeforeInput?: (event: InputEvent) => void;
|
|
1787
|
+
onBeforeInputCapture?: (event: InputEvent) => void;
|
|
1759
1788
|
onChange?: (event: Event) => void;
|
|
1760
1789
|
onChangeCapture?: (event: Event) => void;
|
|
1790
|
+
onFormData?: (event: FormDataEvent) => void;
|
|
1791
|
+
onFormDataCapture?: (event: FormDataEvent) => void;
|
|
1761
1792
|
onInput?: (event: InputEvent) => void;
|
|
1762
1793
|
onInputCapture?: (event: InputEvent) => void;
|
|
1763
1794
|
onReset?: (event: Event) => void;
|
|
@@ -1766,6 +1797,16 @@ export declare namespace JSXBase {
|
|
|
1766
1797
|
onSubmitCapture?: (event: Event) => void;
|
|
1767
1798
|
onInvalid?: (event: Event) => void;
|
|
1768
1799
|
onInvalidCapture?: (event: Event) => void;
|
|
1800
|
+
onSelectionChange?: (event: Event) => void;
|
|
1801
|
+
onSelectionChangeCapture?: (event: Event) => void;
|
|
1802
|
+
onSelectStart?: (event: Event) => void;
|
|
1803
|
+
onSelectStartCapture?: (event: Event) => void;
|
|
1804
|
+
onFullscreenchange?: (event: Event) => void;
|
|
1805
|
+
onFullscreenchangeCapture?: (event: Event) => void;
|
|
1806
|
+
onFullscreenerror?: (event: Event) => void;
|
|
1807
|
+
onFullscreenerrorCapture?: (event: Event) => void;
|
|
1808
|
+
onSecurityPolicyViolation?: (event: SecurityPolicyViolationEvent) => void;
|
|
1809
|
+
onSecurityPolicyViolationCapture?: (event: SecurityPolicyViolationEvent) => void;
|
|
1769
1810
|
onLoad?: (event: Event) => void;
|
|
1770
1811
|
onLoadCapture?: (event: Event) => void;
|
|
1771
1812
|
onError?: (event: Event) => void;
|
|
@@ -1839,10 +1880,20 @@ export declare namespace JSXBase {
|
|
|
1839
1880
|
onGotPointerCaptureCapture?: (event: PointerEvent) => void;
|
|
1840
1881
|
onLostPointerCapture?: (event: PointerEvent) => void;
|
|
1841
1882
|
onLostPointerCaptureCapture?: (event: PointerEvent) => void;
|
|
1883
|
+
onPointerRawUpdate?: (event: PointerEvent) => void;
|
|
1884
|
+
onPointerRawUpdateCapture?: (event: PointerEvent) => void;
|
|
1842
1885
|
onScroll?: (event: UIEvent) => void;
|
|
1843
1886
|
onScrollCapture?: (event: UIEvent) => void;
|
|
1887
|
+
onScrollEnd?: (event: Event) => void;
|
|
1888
|
+
onScrollEndCapture?: (event: Event) => void;
|
|
1889
|
+
onScrollSnapChange?: (event: Event) => void;
|
|
1890
|
+
onScrollSnapChangeCapture?: (event: Event) => void;
|
|
1891
|
+
onScrollSnapChanging?: (event: Event) => void;
|
|
1892
|
+
onScrollSnapChangingCapture?: (event: Event) => void;
|
|
1844
1893
|
onWheel?: (event: WheelEvent) => void;
|
|
1845
1894
|
onWheelCapture?: (event: WheelEvent) => void;
|
|
1895
|
+
onAnimationCancel?: (event: AnimationEvent) => void;
|
|
1896
|
+
onAnimationCancelCapture?: (event: AnimationEvent) => void;
|
|
1846
1897
|
onAnimationStart?: (event: AnimationEvent) => void;
|
|
1847
1898
|
onAnimationStartCapture?: (event: AnimationEvent) => void;
|
|
1848
1899
|
onAnimationEnd?: (event: AnimationEvent) => void;
|
|
@@ -3463,7 +3463,7 @@ var hydrateScopedToShadow = (cmpMetas) => {
|
|
|
3463
3463
|
// src/runtime/vdom/h.ts
|
|
3464
3464
|
var import_app_data8 = require("@stencil/core/internal/app-data");
|
|
3465
3465
|
var h = (nodeName, vnodeData, ...children) => {
|
|
3466
|
-
if (typeof nodeName === "string") {
|
|
3466
|
+
if (typeof nodeName === "string" && nodeName.includes("-")) {
|
|
3467
3467
|
nodeName = transformTag(nodeName);
|
|
3468
3468
|
}
|
|
3469
3469
|
let child = null;
|
|
@@ -4013,7 +4013,8 @@ var addSlottedNodes = (slottedNodes, slotNodeId, slotName, slotNode, hostId) =>
|
|
|
4013
4013
|
slottedNodes[slotNodeId] = slottedNodes[slotNodeId] || [];
|
|
4014
4014
|
if (!slottedNode || ((_a2 = slottedNode.nodeValue) == null ? void 0 : _a2.startsWith(SLOT_NODE_ID + "."))) return;
|
|
4015
4015
|
do {
|
|
4016
|
-
|
|
4016
|
+
const ssrSlotName = slottedNode && slottedNode["getAttribute"] && slottedNode.getAttribute("s-sn");
|
|
4017
|
+
if (slottedNode && (ssrSlotName === slotName || (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 */))) {
|
|
4017
4018
|
slottedNode["s-sn"] = slotName;
|
|
4018
4019
|
slottedNodes[slotNodeId].push({ slot: slotNode, node: slottedNode, hostId });
|
|
4019
4020
|
}
|
|
@@ -4587,6 +4588,8 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
|
|
|
4587
4588
|
memberName = memberName.slice(3);
|
|
4588
4589
|
} else if (isMemberInElement(win, ln)) {
|
|
4589
4590
|
memberName = ln.slice(2);
|
|
4591
|
+
} else if (memberName.endsWith(CAPTURE_EVENT_SUFFIX) && isMemberInElement(win, ln.slice(0, -CAPTURE_EVENT_SUFFIX.length))) {
|
|
4592
|
+
memberName = ln.slice(2, -CAPTURE_EVENT_SUFFIX.length) + CAPTURE_EVENT_SUFFIX;
|
|
4590
4593
|
} else {
|
|
4591
4594
|
memberName = ln[2] + memberName.slice(3);
|
|
4592
4595
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stencil/core/internal/testing",
|
|
3
|
-
"version": "4.45.
|
|
3
|
+
"version": "4.45.6-dev.1796101679.176b027",
|
|
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
|
package/mock-doc/index.cjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
Stencil Mock Doc (CommonJS) v4.45.
|
|
2
|
+
Stencil Mock Doc (CommonJS) v4.45.6-dev.1796101679.176b027 | MIT Licensed | https://stenciljs.com
|
|
3
3
|
*/
|
|
4
4
|
"use strict";
|
|
5
5
|
var __defProp = Object.defineProperty;
|
|
@@ -262,7 +262,7 @@ var MockCSSStyleDeclaration = class {
|
|
|
262
262
|
this._styles.clear();
|
|
263
263
|
return;
|
|
264
264
|
}
|
|
265
|
-
cssText
|
|
265
|
+
splitDeclarations(cssText).forEach((rule) => {
|
|
266
266
|
rule = rule.trim();
|
|
267
267
|
if (rule.length > 0) {
|
|
268
268
|
const splt = rule.split(":");
|
|
@@ -277,6 +277,39 @@ var MockCSSStyleDeclaration = class {
|
|
|
277
277
|
});
|
|
278
278
|
}
|
|
279
279
|
};
|
|
280
|
+
function splitDeclarations(cssText) {
|
|
281
|
+
const declarations = [];
|
|
282
|
+
let current = "";
|
|
283
|
+
let depth = 0;
|
|
284
|
+
let quote = "";
|
|
285
|
+
for (let i = 0; i < cssText.length; i++) {
|
|
286
|
+
const char = cssText[i];
|
|
287
|
+
if (char === "\\" && i + 1 < cssText.length) {
|
|
288
|
+
current += char + cssText[++i];
|
|
289
|
+
continue;
|
|
290
|
+
}
|
|
291
|
+
if (quote) {
|
|
292
|
+
if (char === quote) {
|
|
293
|
+
quote = "";
|
|
294
|
+
}
|
|
295
|
+
} else if (char === '"' || char === "'") {
|
|
296
|
+
quote = char;
|
|
297
|
+
} else if (char === "(") {
|
|
298
|
+
depth++;
|
|
299
|
+
} else if (char === ")") {
|
|
300
|
+
if (depth > 0) {
|
|
301
|
+
depth--;
|
|
302
|
+
}
|
|
303
|
+
} else if (char === ";" && depth === 0) {
|
|
304
|
+
declarations.push(current);
|
|
305
|
+
current = "";
|
|
306
|
+
continue;
|
|
307
|
+
}
|
|
308
|
+
current += char;
|
|
309
|
+
}
|
|
310
|
+
declarations.push(current);
|
|
311
|
+
return declarations;
|
|
312
|
+
}
|
|
280
313
|
function createCSSStyleDeclaration() {
|
|
281
314
|
return new Proxy(new MockCSSStyleDeclaration(), cssProxyHandler);
|
|
282
315
|
}
|
|
@@ -6288,7 +6321,7 @@ style="${escapeString(cssText, true)}">`;
|
|
|
6288
6321
|
yield* streamToHtml(shadowRoot, opts, output);
|
|
6289
6322
|
output.indent = output.indent - ((_d = opts.indentSpaces) != null ? _d : 0);
|
|
6290
6323
|
const childNodes = getChildNodes(node);
|
|
6291
|
-
if (opts.newLines && (childNodes.length === 0 || childNodes.length === 1 && childNodes[0].nodeType === 3 /* TEXT_NODE */ && ((_e = childNodes[0].nodeValue) == null ? void 0 : _e.trim()) === "")) {
|
|
6324
|
+
if (opts.newLines && (childNodes.length === 0 || childNodes.length === 1 && childNodes[0].nodeType === 3 /* TEXT_NODE */ && ((_e = childNodes[0].nodeValue) == null ? void 0 : _e.trim()) === "" || hasOnlyRemovedComments(childNodes, opts))) {
|
|
6292
6325
|
yield "\n";
|
|
6293
6326
|
output.currentLineWidth = 0;
|
|
6294
6327
|
for (let i = 0; i < output.indent; i++) {
|
|
@@ -6303,6 +6336,7 @@ style="${escapeString(cssText, true)}">`;
|
|
|
6303
6336
|
const childNodeLength = childNodes.length;
|
|
6304
6337
|
if (childNodeLength > 0) {
|
|
6305
6338
|
if (childNodeLength === 1 && childNodes[0].nodeType === 3 /* TEXT_NODE */ && (typeof childNodes[0].nodeValue !== "string" || childNodes[0].nodeValue.trim() === "")) {
|
|
6339
|
+
} else if (hasOnlyRemovedComments(childNodes, opts)) {
|
|
6306
6340
|
} else {
|
|
6307
6341
|
const isWithinWhitespaceSensitiveNode = opts.newLines || ((_f = opts.indentSpaces) != null ? _f : 0) > 0 ? isWithinWhitespaceSensitive(node) : false;
|
|
6308
6342
|
if (!isWithinWhitespaceSensitiveNode && ((_g = opts.indentSpaces) != null ? _g : 0) > 0 && ignoreTag === false) {
|
|
@@ -6419,8 +6453,7 @@ ${" ".repeat(output.indent)}<!--r.${sId.value}-->`;
|
|
|
6419
6453
|
}
|
|
6420
6454
|
} else if (node.nodeType === 8 /* COMMENT_NODE */) {
|
|
6421
6455
|
const nodeValue = node.nodeValue;
|
|
6422
|
-
|
|
6423
|
-
if (opts.removeHtmlComments && !isHydrateAnnotation) {
|
|
6456
|
+
if (isRemovedComment(node, opts)) {
|
|
6424
6457
|
return;
|
|
6425
6458
|
}
|
|
6426
6459
|
const isWithinWhitespaceSensitiveNode = opts.newLines || ((_o = opts.indentSpaces) != null ? _o : 0) > 0 ? isWithinWhitespaceSensitive(node) : false;
|
|
@@ -6472,6 +6505,26 @@ function isWithinWhitespaceSensitive(node) {
|
|
|
6472
6505
|
}
|
|
6473
6506
|
return false;
|
|
6474
6507
|
}
|
|
6508
|
+
function isRemovedComment(node, opts) {
|
|
6509
|
+
if (node.nodeType !== 8 /* COMMENT_NODE */ || !opts.removeHtmlComments) {
|
|
6510
|
+
return false;
|
|
6511
|
+
}
|
|
6512
|
+
const nodeValue = node.nodeValue;
|
|
6513
|
+
const isHydrateAnnotation = (nodeValue == null ? void 0 : nodeValue.startsWith(CONTENT_REF_ID + ".")) || (nodeValue == null ? void 0 : nodeValue.startsWith(ORG_LOCATION_ID + ".")) || (nodeValue == null ? void 0 : nodeValue.startsWith(SLOT_NODE_ID + ".")) || (nodeValue == null ? void 0 : nodeValue.startsWith(TEXT_NODE_ID + "."));
|
|
6514
|
+
return !isHydrateAnnotation;
|
|
6515
|
+
}
|
|
6516
|
+
function hasOnlyRemovedComments(childNodes, opts) {
|
|
6517
|
+
let hasRemovedComment = false;
|
|
6518
|
+
for (let i = 0; i < childNodes.length; i++) {
|
|
6519
|
+
const childNode = childNodes[i];
|
|
6520
|
+
if (isRemovedComment(childNode, opts)) {
|
|
6521
|
+
hasRemovedComment = true;
|
|
6522
|
+
} else if (childNode.nodeType !== 3 /* TEXT_NODE */ || typeof childNode.nodeValue === "string" && childNode.nodeValue.trim() !== "") {
|
|
6523
|
+
return false;
|
|
6524
|
+
}
|
|
6525
|
+
}
|
|
6526
|
+
return hasRemovedComment;
|
|
6527
|
+
}
|
|
6475
6528
|
function getChildNodes(node) {
|
|
6476
6529
|
return node.__childNodes || node.childNodes;
|
|
6477
6530
|
}
|
|
@@ -7314,6 +7367,19 @@ var MockElement = class extends MockNode2 {
|
|
|
7314
7367
|
set title(value) {
|
|
7315
7368
|
this.setAttributeNS(null, "title", value);
|
|
7316
7369
|
}
|
|
7370
|
+
toggleAttribute(attrName, force) {
|
|
7371
|
+
const has = this.hasAttribute(attrName);
|
|
7372
|
+
if (force != null ? force : !has) {
|
|
7373
|
+
if (!has) {
|
|
7374
|
+
this.setAttribute(attrName, "");
|
|
7375
|
+
}
|
|
7376
|
+
return true;
|
|
7377
|
+
}
|
|
7378
|
+
if (has) {
|
|
7379
|
+
this.removeAttribute(attrName);
|
|
7380
|
+
}
|
|
7381
|
+
return false;
|
|
7382
|
+
}
|
|
7317
7383
|
animate() {
|
|
7318
7384
|
}
|
|
7319
7385
|
onanimationstart() {
|
|
@@ -8458,6 +8524,13 @@ function getLabelsForElement(elm) {
|
|
|
8458
8524
|
parent = parent.parentNode;
|
|
8459
8525
|
}
|
|
8460
8526
|
}
|
|
8527
|
+
Object.defineProperty(labels, "item", {
|
|
8528
|
+
value: (index) => {
|
|
8529
|
+
var _a;
|
|
8530
|
+
return (_a = labels[index]) != null ? _a : null;
|
|
8531
|
+
},
|
|
8532
|
+
enumerable: false
|
|
8533
|
+
});
|
|
8461
8534
|
return labels;
|
|
8462
8535
|
}
|
|
8463
8536
|
function patchPropAttributes(prototype, attrs, defaults = {}) {
|
package/mock-doc/index.d.ts
CHANGED
|
@@ -165,7 +165,9 @@ declare class MockAnchorElement extends MockHTMLElement {
|
|
|
165
165
|
}
|
|
166
166
|
declare class MockButtonElement extends MockHTMLElement {
|
|
167
167
|
constructor(ownerDocument: any);
|
|
168
|
-
get labels(): MockHTMLElement[]
|
|
168
|
+
get labels(): MockHTMLElement[] & {
|
|
169
|
+
item(index: number): MockHTMLElement | null;
|
|
170
|
+
};
|
|
169
171
|
}
|
|
170
172
|
declare class MockImageElement extends MockHTMLElement {
|
|
171
173
|
constructor(ownerDocument: any);
|
|
@@ -177,7 +179,9 @@ declare class MockImageElement extends MockHTMLElement {
|
|
|
177
179
|
declare class MockInputElement extends MockHTMLElement {
|
|
178
180
|
constructor(ownerDocument: any);
|
|
179
181
|
get list(): HTMLElement;
|
|
180
|
-
get labels(): MockHTMLElement[]
|
|
182
|
+
get labels(): MockHTMLElement[] & {
|
|
183
|
+
item(index: number): MockHTMLElement | null;
|
|
184
|
+
};
|
|
181
185
|
}
|
|
182
186
|
declare class MockFormElement extends MockHTMLElement {
|
|
183
187
|
constructor(ownerDocument: any);
|
|
@@ -646,6 +650,7 @@ declare class MockElement extends MockNode {
|
|
|
646
650
|
set textContent(value: string);
|
|
647
651
|
get title(): string;
|
|
648
652
|
set title(value: string);
|
|
653
|
+
toggleAttribute(attrName: string, force?: boolean): boolean;
|
|
649
654
|
animate(): void;
|
|
650
655
|
onanimationstart(): void;
|
|
651
656
|
onanimationend(): void;
|