@searchcraft/javascript-sdk 0.13.1 → 0.13.3
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/README.md +5 -0
- package/dist/components/{p-D0j0UFpV.js → CoreInstanceRegistry.js} +2 -2
- package/dist/components/CoreInstanceRegistry.js.map +1 -0
- package/dist/components/defineCustomElements.js +23 -23
- package/dist/components/{p-_aHgRsRD.js → html.js} +3 -3
- package/dist/components/html.js.map +1 -0
- package/dist/components/index.d.ts +109 -0
- package/dist/components/index.js +28 -28
- package/dist/components/{p-DO5g2x-l.js → index2.js} +23 -6
- package/dist/components/index2.js.map +1 -0
- package/dist/components/{p-BfTCfPZ1.js → index3.js} +2 -2
- package/dist/components/index3.js.map +1 -0
- package/dist/components/{p-BlYgaV0q.js → purify.es.js} +10 -4
- package/dist/components/purify.es.js.map +1 -0
- package/dist/components/searchcraft-ad.js +1 -1
- package/dist/components/{p-C1S92_N8.js → searchcraft-ad2.js} +8 -8
- package/dist/components/searchcraft-ad2.js.map +1 -0
- package/dist/components/searchcraft-button.js +1 -1
- package/dist/components/{p-C681KruS.js → searchcraft-button2.js} +6 -6
- package/dist/components/searchcraft-button2.js.map +1 -0
- package/dist/components/searchcraft-error-message.js +1 -1
- package/dist/components/{p-DjPZkCLP.js → searchcraft-error-message2.js} +5 -5
- package/dist/components/searchcraft-error-message2.js.map +1 -0
- package/dist/components/searchcraft-facet-list.js +1 -1
- package/dist/components/{p-BV4HUriZ.js → searchcraft-facet-list2.js} +64 -9
- package/dist/components/searchcraft-facet-list2.js.map +1 -0
- package/dist/components/searchcraft-filter-panel.js +43 -11
- package/dist/components/searchcraft-filter-panel.js.map +1 -1
- package/dist/components/searchcraft-input-form.js +1 -1
- package/dist/components/{p-C-wcIch1.js → searchcraft-input-form2.js} +13 -13
- package/dist/components/searchcraft-input-form2.js.map +1 -0
- package/dist/components/searchcraft-input-label.js +1 -1
- package/dist/components/{p-L4PwHqQC.js → searchcraft-input-label2.js} +6 -6
- package/dist/components/searchcraft-input-label2.js.map +1 -0
- package/dist/components/searchcraft-loading.js +1 -1
- package/dist/components/{p-B_415D4A.js → searchcraft-loading2.js} +5 -5
- package/dist/components/searchcraft-loading2.js.map +1 -0
- package/dist/components/searchcraft-pagination.js +52 -7
- package/dist/components/searchcraft-pagination.js.map +1 -1
- package/dist/components/searchcraft-popover-button.js +5 -5
- package/dist/components/searchcraft-popover-footer.js +1 -1
- package/dist/components/{p-C7ZK8CYu.js → searchcraft-popover-footer2.js} +8 -8
- package/dist/components/searchcraft-popover-footer2.js.map +1 -0
- package/dist/components/searchcraft-popover-form.js +22 -22
- package/dist/components/searchcraft-popover-list-item.js +1 -1
- package/dist/components/{p-Cju73I1E.js → searchcraft-popover-list-item2.js} +8 -8
- package/dist/components/searchcraft-popover-list-item2.js.map +1 -0
- package/dist/components/searchcraft-popover-list-view.js +1 -1
- package/dist/components/{p-Dr9rPC9v.js → searchcraft-popover-list-view2.js} +10 -10
- package/dist/components/searchcraft-popover-list-view2.js.map +1 -0
- package/dist/components/searchcraft-results-info.js +6 -6
- package/dist/components/searchcraft-search-result.js +1 -1
- package/dist/components/{p-DotXR-Gz.js → searchcraft-search-result2.js} +7 -7
- package/dist/components/searchcraft-search-result2.js.map +1 -0
- package/dist/components/searchcraft-search-results-per-page.js +6 -6
- package/dist/components/searchcraft-search-results.js +10 -10
- package/dist/components/searchcraft-select.js +1 -1
- package/dist/components/{p-Dc7S4y3b.js → searchcraft-select2.js} +5 -5
- package/dist/components/searchcraft-select2.js.map +1 -0
- package/dist/components/searchcraft-slider.js +1 -1
- package/dist/components/{p-BbSxfaD7.js → searchcraft-slider2.js} +8 -8
- package/dist/components/searchcraft-slider2.js.map +1 -0
- package/dist/components/searchcraft-summary-box.js +7 -7
- package/dist/components/searchcraft-theme.js +4 -4
- package/dist/components/searchcraft-theme.js.map +1 -1
- package/dist/components/searchcraft-toggle-button.js +1 -1
- package/dist/components/{p-D5p2scT9.js → searchcraft-toggle-button2.js} +7 -7
- package/dist/components/searchcraft-toggle-button2.js.map +1 -0
- package/dist/components/{p-i8oXh7db.js → units.js} +2 -2
- package/dist/components/units.js.map +1 -0
- package/dist/hydrate/index.d.ts +12 -0
- package/dist/hydrate/index.js +1832 -1619
- package/dist/hydrate/index.mjs +1831 -1620
- package/dist/themes/hologram.css +1 -1
- package/dist/themes/hologram.css.map +1 -1
- package/dist/types/components/searchcraft-facet-list/searchcraft-facet-list.d.ts +47 -0
- package/dist/types/components/searchcraft-pagination/searchcraft-pagination.d.ts +9 -0
- package/dist/types/components.d.ts +96 -0
- package/dist/types/stencil-public-runtime.d.ts +43 -0
- package/dist/types/types/sdk-types/searchcraft-filter-panel.types.d.ts +13 -0
- package/package.json +3 -3
- package/dist/components/p-BV4HUriZ.js.map +0 -1
- package/dist/components/p-B_415D4A.js.map +0 -1
- package/dist/components/p-BbSxfaD7.js.map +0 -1
- package/dist/components/p-BfTCfPZ1.js.map +0 -1
- package/dist/components/p-BlYgaV0q.js.map +0 -1
- package/dist/components/p-C-wcIch1.js.map +0 -1
- package/dist/components/p-C1S92_N8.js.map +0 -1
- package/dist/components/p-C681KruS.js.map +0 -1
- package/dist/components/p-C7ZK8CYu.js.map +0 -1
- package/dist/components/p-Cju73I1E.js.map +0 -1
- package/dist/components/p-D0j0UFpV.js.map +0 -1
- package/dist/components/p-D5p2scT9.js.map +0 -1
- package/dist/components/p-DO5g2x-l.js.map +0 -1
- package/dist/components/p-Dc7S4y3b.js.map +0 -1
- package/dist/components/p-DjPZkCLP.js.map +0 -1
- package/dist/components/p-DotXR-Gz.js.map +0 -1
- package/dist/components/p-Dr9rPC9v.js.map +0 -1
- package/dist/components/p-L4PwHqQC.js.map +0 -1
- package/dist/components/p-_aHgRsRD.js.map +0 -1
- package/dist/components/p-i8oXh7db.js.map +0 -1
package/dist/hydrate/index.mjs
CHANGED
|
@@ -1,8 +1,99 @@
|
|
|
1
1
|
import { Readable } from 'stream';
|
|
2
2
|
|
|
3
|
+
// src/app-data/index.ts
|
|
4
|
+
var BUILD = {
|
|
5
|
+
allRenderFn: false,
|
|
6
|
+
element: true,
|
|
7
|
+
event: true,
|
|
8
|
+
hasRenderFn: true,
|
|
9
|
+
hostListener: true,
|
|
10
|
+
hostListenerTargetWindow: true,
|
|
11
|
+
hostListenerTargetDocument: true,
|
|
12
|
+
hostListenerTargetBody: true,
|
|
13
|
+
hostListenerTargetParent: false,
|
|
14
|
+
hostListenerTarget: true,
|
|
15
|
+
member: true,
|
|
16
|
+
method: true,
|
|
17
|
+
mode: true,
|
|
18
|
+
observeAttribute: true,
|
|
19
|
+
prop: true,
|
|
20
|
+
propMutable: true,
|
|
21
|
+
reflect: true,
|
|
22
|
+
scoped: true,
|
|
23
|
+
shadowDom: true,
|
|
24
|
+
slot: true,
|
|
25
|
+
cssAnnotations: true,
|
|
26
|
+
state: true,
|
|
27
|
+
style: true,
|
|
28
|
+
formAssociated: false,
|
|
29
|
+
svg: true,
|
|
30
|
+
updatable: true,
|
|
31
|
+
vdomAttribute: true,
|
|
32
|
+
vdomXlink: true,
|
|
33
|
+
vdomClass: true,
|
|
34
|
+
vdomFunctional: true,
|
|
35
|
+
vdomKey: true,
|
|
36
|
+
vdomListener: true,
|
|
37
|
+
vdomRef: true,
|
|
38
|
+
vdomPropOrAttr: true,
|
|
39
|
+
vdomRender: true,
|
|
40
|
+
vdomStyle: true,
|
|
41
|
+
vdomText: true,
|
|
42
|
+
propChangeCallback: true,
|
|
43
|
+
taskQueue: true,
|
|
44
|
+
hotModuleReplacement: false,
|
|
45
|
+
isDebug: false,
|
|
46
|
+
isDev: false,
|
|
47
|
+
isTesting: false,
|
|
48
|
+
hydrateServerSide: false,
|
|
49
|
+
hydrateClientSide: false,
|
|
50
|
+
lifecycleDOMEvents: false,
|
|
51
|
+
lazyLoad: false,
|
|
52
|
+
profile: false,
|
|
53
|
+
slotRelocation: true,
|
|
54
|
+
// TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior
|
|
55
|
+
appendChildSlotFix: false,
|
|
56
|
+
// TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior
|
|
57
|
+
cloneNodeFix: false,
|
|
58
|
+
hydratedAttribute: false,
|
|
59
|
+
hydratedClass: true,
|
|
60
|
+
// TODO(STENCIL-1305): remove this option
|
|
61
|
+
scriptDataOpts: false,
|
|
62
|
+
// TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior
|
|
63
|
+
scopedSlotTextContentFix: false,
|
|
64
|
+
// TODO(STENCIL-854): Remove code related to legacy shadowDomShim field
|
|
65
|
+
shadowDomShim: false,
|
|
66
|
+
// TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior
|
|
67
|
+
slotChildNodesFix: false,
|
|
68
|
+
invisiblePrehydration: true,
|
|
69
|
+
propBoolean: true,
|
|
70
|
+
propNumber: true,
|
|
71
|
+
propString: true,
|
|
72
|
+
constructableCSS: true,
|
|
73
|
+
devTools: false,
|
|
74
|
+
shadowDelegatesFocus: true,
|
|
75
|
+
initializeNextTick: false,
|
|
76
|
+
asyncLoading: true,
|
|
77
|
+
asyncQueue: false,
|
|
78
|
+
// TODO: deprecated in favour of `setTagTransformer` and `transformTag`. Remove in 5.0
|
|
79
|
+
transformTagName: false,
|
|
80
|
+
attachStyles: true,
|
|
81
|
+
// TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior
|
|
82
|
+
experimentalSlotFixes: false
|
|
83
|
+
};
|
|
84
|
+
var Env = {};
|
|
85
|
+
var NAMESPACE = (
|
|
86
|
+
/* default */
|
|
87
|
+
"app"
|
|
88
|
+
);
|
|
89
|
+
|
|
3
90
|
const modeResolutionChain = [];
|
|
4
91
|
|
|
5
92
|
function hydrateFactory($stencilWindow, $stencilHydrateOpts, $stencilHydrateResults, $stencilAfterHydrate, $stencilHydrateResolve) {
|
|
93
|
+
var everywhere;
|
|
94
|
+
try { everywhere = global || globalThis; }
|
|
95
|
+
catch (e) { everywhere = window || globalThis; }
|
|
96
|
+
|
|
6
97
|
var globalThis = $stencilWindow;
|
|
7
98
|
var self = $stencilWindow;
|
|
8
99
|
var top = $stencilWindow;
|
|
@@ -130,7 +221,7 @@ const NAMESPACE = 'searchcraft-javascript-sdk';
|
|
|
130
221
|
const BUILD = /* searchcraft-javascript-sdk */ { hydratedSelectorName: "hydrated", shadowDom: false, slotRelocation: true, state: true, updatable: true};
|
|
131
222
|
|
|
132
223
|
/*
|
|
133
|
-
Stencil Hydrate Platform v4.
|
|
224
|
+
Stencil Hydrate Platform v4.39.0 | MIT Licensed | https://stenciljs.com
|
|
134
225
|
*/
|
|
135
226
|
var __defProp = Object.defineProperty;
|
|
136
227
|
var __export = (target, all) => {
|
|
@@ -545,6 +636,9 @@ var uniqueTime = (key, measureText) => {
|
|
|
545
636
|
};
|
|
546
637
|
var getScopeId = (cmp, mode) => "sc-" + (cmp.$tagName$);
|
|
547
638
|
var h = (nodeName, vnodeData, ...children) => {
|
|
639
|
+
if (typeof nodeName === "string") {
|
|
640
|
+
nodeName = transformTag(nodeName);
|
|
641
|
+
}
|
|
548
642
|
let child = null;
|
|
549
643
|
let key = null;
|
|
550
644
|
let slotName = null;
|
|
@@ -691,7 +785,7 @@ var initializeClientHydrate = (hostElm, tagName, hostId, hostRef) => {
|
|
|
691
785
|
const orgLocationNode = plt.$orgLocNodes$.get(orgLocationId);
|
|
692
786
|
const node = childRenderNode.$elm$;
|
|
693
787
|
if (!shadowRoot) {
|
|
694
|
-
node["s-hn"] = tagName.toUpperCase();
|
|
788
|
+
node["s-hn"] = transformTag(tagName).toUpperCase();
|
|
695
789
|
if (childRenderNode.$tag$ === "slot") {
|
|
696
790
|
node["s-cr"] = hostElm["s-cr"];
|
|
697
791
|
}
|
|
@@ -1100,7 +1194,11 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRen
|
|
|
1100
1194
|
}
|
|
1101
1195
|
}
|
|
1102
1196
|
}
|
|
1103
|
-
} else if (memberName === "key") ; else if (
|
|
1197
|
+
} else if (memberName === "key") ; else if (memberName === "ref") {
|
|
1198
|
+
if (newValue) {
|
|
1199
|
+
newValue(elm);
|
|
1200
|
+
}
|
|
1201
|
+
} else if ((!isProp ) && memberName[0] === "o" && memberName[1] === "n") {
|
|
1104
1202
|
if (memberName[2] === "-") {
|
|
1105
1203
|
memberName = memberName.slice(3);
|
|
1106
1204
|
} else if (isMemberInElement(win, ln)) {
|
|
@@ -1334,6 +1432,7 @@ var removeVnodes = (vnodes, startIdx, endIdx) => {
|
|
|
1334
1432
|
const vnode = vnodes[index];
|
|
1335
1433
|
if (vnode) {
|
|
1336
1434
|
const elm = vnode.$elm$;
|
|
1435
|
+
nullifyVNodeRefs(vnode);
|
|
1337
1436
|
if (elm) {
|
|
1338
1437
|
{
|
|
1339
1438
|
checkSlotFallbackVisibility = true;
|
|
@@ -1546,6 +1645,12 @@ var markSlotContentForRelocation = (elm) => {
|
|
|
1546
1645
|
}
|
|
1547
1646
|
}
|
|
1548
1647
|
};
|
|
1648
|
+
var nullifyVNodeRefs = (vNode) => {
|
|
1649
|
+
{
|
|
1650
|
+
vNode.$attrs$ && vNode.$attrs$.ref && vNode.$attrs$.ref(null);
|
|
1651
|
+
vNode.$children$ && vNode.$children$.map(nullifyVNodeRefs);
|
|
1652
|
+
}
|
|
1653
|
+
};
|
|
1549
1654
|
var insertBefore = (parent, newNode, reference) => {
|
|
1550
1655
|
{
|
|
1551
1656
|
return parent == null ? void 0 : parent.insertBefore(newNode, reference);
|
|
@@ -1805,6 +1910,9 @@ var postUpdateComponent = (hostRef) => {
|
|
|
1805
1910
|
safeCall(instance, "componentDidUpdate", void 0, elm);
|
|
1806
1911
|
endPostUpdate();
|
|
1807
1912
|
}
|
|
1913
|
+
{
|
|
1914
|
+
hostRef.$onInstanceResolve$(elm);
|
|
1915
|
+
}
|
|
1808
1916
|
{
|
|
1809
1917
|
if (hostRef.$onRenderResolve$) {
|
|
1810
1918
|
hostRef.$onRenderResolve$();
|
|
@@ -2100,6 +2208,9 @@ var setContentReference = (elm) => {
|
|
|
2100
2208
|
|
|
2101
2209
|
// src/runtime/fragment.ts
|
|
2102
2210
|
var Fragment = (_, children) => children;
|
|
2211
|
+
function transformTag(tag) {
|
|
2212
|
+
return tag;
|
|
2213
|
+
}
|
|
2103
2214
|
|
|
2104
2215
|
// src/runtime/vdom/vdom-annotations.ts
|
|
2105
2216
|
var insertVdomAnnotations = (doc, staticComponents) => {
|
|
@@ -2655,9 +2766,15 @@ var isMemberInElement = (elm, memberName) => {
|
|
|
2655
2766
|
var registerComponents = (Cstrs) => {
|
|
2656
2767
|
for (const Cstr of Cstrs) {
|
|
2657
2768
|
const exportName = Cstr.cmpMeta.$tagName$;
|
|
2769
|
+
const transformedTagName = everywhere.tagTransform(exportName);
|
|
2658
2770
|
cmpModules.set(exportName, {
|
|
2659
2771
|
[exportName]: Cstr
|
|
2660
2772
|
});
|
|
2773
|
+
if (transformedTagName !== exportName) {
|
|
2774
|
+
cmpModules.set(transformedTagName, {
|
|
2775
|
+
[transformedTagName]: Cstr
|
|
2776
|
+
});
|
|
2777
|
+
}
|
|
2661
2778
|
}
|
|
2662
2779
|
};
|
|
2663
2780
|
var win = window;
|
|
@@ -3296,7 +3413,7 @@ function getFormattedDateString(granularity, date) {
|
|
|
3296
3413
|
}
|
|
3297
3414
|
}
|
|
3298
3415
|
|
|
3299
|
-
/*! @license DOMPurify 3.3.
|
|
3416
|
+
/*! @license DOMPurify 3.3.1 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.3.1/LICENSE */
|
|
3300
3417
|
|
|
3301
3418
|
const {
|
|
3302
3419
|
entries,
|
|
@@ -3594,7 +3711,7 @@ const _createHooksMap = function _createHooksMap() {
|
|
|
3594
3711
|
function createDOMPurify() {
|
|
3595
3712
|
let window = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : getGlobal();
|
|
3596
3713
|
const DOMPurify = root => createDOMPurify(root);
|
|
3597
|
-
DOMPurify.version = '3.3.
|
|
3714
|
+
DOMPurify.version = '3.3.1';
|
|
3598
3715
|
DOMPurify.removed = [];
|
|
3599
3716
|
if (!window || !window.document || window.document.nodeType !== NODE_TYPE.document || !window.Element) {
|
|
3600
3717
|
// Not running in a browser, provide a factory function
|
|
@@ -3940,6 +4057,12 @@ function createDOMPurify() {
|
|
|
3940
4057
|
}
|
|
3941
4058
|
addToSet(FORBID_CONTENTS, cfg.FORBID_CONTENTS, transformCaseFunc);
|
|
3942
4059
|
}
|
|
4060
|
+
if (cfg.ADD_FORBID_CONTENTS) {
|
|
4061
|
+
if (FORBID_CONTENTS === DEFAULT_FORBID_CONTENTS) {
|
|
4062
|
+
FORBID_CONTENTS = clone(FORBID_CONTENTS);
|
|
4063
|
+
}
|
|
4064
|
+
addToSet(FORBID_CONTENTS, cfg.ADD_FORBID_CONTENTS, transformCaseFunc);
|
|
4065
|
+
}
|
|
3943
4066
|
/* Add #text in case KEEP_CONTENT is set to true */
|
|
3944
4067
|
if (KEEP_CONTENT) {
|
|
3945
4068
|
ALLOWED_TAGS['#text'] = true;
|
|
@@ -4684,7 +4807,21 @@ const html$1 = (strings, ...values) => {
|
|
|
4684
4807
|
* @js-example
|
|
4685
4808
|
* ```html
|
|
4686
4809
|
* <!-- index.html -->
|
|
4810
|
+
* <!-- Basic usage -->
|
|
4687
4811
|
* <searchcraft-facet-list field-name="title" />
|
|
4812
|
+
*
|
|
4813
|
+
* <!-- With collapsible section (initially closed) and view more threshold -->
|
|
4814
|
+
* <searchcraft-facet-list
|
|
4815
|
+
* field-name="category"
|
|
4816
|
+
* initial-collapse-state="closed"
|
|
4817
|
+
* view-more-threshold="5"
|
|
4818
|
+
* />
|
|
4819
|
+
*
|
|
4820
|
+
* <!-- Show all facets without "view more" link -->
|
|
4821
|
+
* <searchcraft-facet-list
|
|
4822
|
+
* field-name="brand"
|
|
4823
|
+
* view-more-threshold="0"
|
|
4824
|
+
* />
|
|
4688
4825
|
* ```
|
|
4689
4826
|
*
|
|
4690
4827
|
* ```js
|
|
@@ -4694,6 +4831,9 @@ const html$1 = (strings, ...values) => {
|
|
|
4694
4831
|
* facetList.addEventListener('facetSelectionUpdated', () => {
|
|
4695
4832
|
* console.log('Facet selection updated');
|
|
4696
4833
|
* });
|
|
4834
|
+
*
|
|
4835
|
+
* // Programmatically toggle collapse state
|
|
4836
|
+
* await facetList.handleCollapseToggle();
|
|
4697
4837
|
* ```
|
|
4698
4838
|
*
|
|
4699
4839
|
* @internal
|
|
@@ -4715,6 +4855,17 @@ class SearchcraftFacetList {
|
|
|
4715
4855
|
* Array of facet values to exclude from rendering.
|
|
4716
4856
|
*/
|
|
4717
4857
|
exclude;
|
|
4858
|
+
/**
|
|
4859
|
+
* Initial collapse state of the facet section.
|
|
4860
|
+
* @default 'open'
|
|
4861
|
+
*/
|
|
4862
|
+
initialCollapseState = 'open';
|
|
4863
|
+
/**
|
|
4864
|
+
* The number of facets to show before displaying a "view more" link.
|
|
4865
|
+
* Set to 0 to show all facets without a "view more" link.
|
|
4866
|
+
* @default 8
|
|
4867
|
+
*/
|
|
4868
|
+
viewMoreThreshold = 8;
|
|
4718
4869
|
/**
|
|
4719
4870
|
* Emitted when the facets are updated.
|
|
4720
4871
|
*/
|
|
@@ -4749,6 +4900,14 @@ class SearchcraftFacetList {
|
|
|
4749
4900
|
count: 0,
|
|
4750
4901
|
children: {},
|
|
4751
4902
|
};
|
|
4903
|
+
/**
|
|
4904
|
+
* Tracks whether the facet section is collapsed or expanded.
|
|
4905
|
+
*/
|
|
4906
|
+
isCollapsed = false;
|
|
4907
|
+
/**
|
|
4908
|
+
* Tracks whether all facets are shown or limited by the threshold.
|
|
4909
|
+
*/
|
|
4910
|
+
showAllFacets = false;
|
|
4752
4911
|
// Internal vars used to track when to perform various facet actions.
|
|
4753
4912
|
lastTimeTaken;
|
|
4754
4913
|
lastSearchTerm;
|
|
@@ -4934,6 +5093,8 @@ class SearchcraftFacetList {
|
|
|
4934
5093
|
});
|
|
4935
5094
|
}
|
|
4936
5095
|
connectedCallback() {
|
|
5096
|
+
// Initialize collapse state based on prop
|
|
5097
|
+
this.isCollapsed = this.initialCollapseState === 'closed';
|
|
4937
5098
|
this.cleanupCore = registry.useCoreInstance(this.searchcraftId, this.onCoreAvailable.bind(this));
|
|
4938
5099
|
}
|
|
4939
5100
|
disconnectedCallback() {
|
|
@@ -4973,6 +5134,23 @@ class SearchcraftFacetList {
|
|
|
4973
5134
|
const label = name.replace(/^\//, '');
|
|
4974
5135
|
return `${label.replace(/-/g, ' ').replace(/\b\w/g, (char) => char.toUpperCase())}`;
|
|
4975
5136
|
};
|
|
5137
|
+
/**
|
|
5138
|
+
* Toggles the collapsed state of the facet section.
|
|
5139
|
+
* @returns A promise that resolves when the toggle is complete.
|
|
5140
|
+
*/
|
|
5141
|
+
async handleCollapseToggle() {
|
|
5142
|
+
this.isCollapsed = !this.isCollapsed;
|
|
5143
|
+
}
|
|
5144
|
+
/**
|
|
5145
|
+
* Returns whether the facet section is currently collapsed.
|
|
5146
|
+
* @returns A promise that resolves to true if collapsed, false if expanded.
|
|
5147
|
+
*/
|
|
5148
|
+
async getIsCollapsed() {
|
|
5149
|
+
return this.isCollapsed;
|
|
5150
|
+
}
|
|
5151
|
+
handleViewMoreToggle = () => {
|
|
5152
|
+
this.showAllFacets = !this.showAllFacets;
|
|
5153
|
+
};
|
|
4976
5154
|
renderFacet(keyName, facet) {
|
|
4977
5155
|
let isChildSelected = false;
|
|
4978
5156
|
for (const path of Object.keys(this.selectedPaths)) {
|
|
@@ -5011,7 +5189,18 @@ class SearchcraftFacetList {
|
|
|
5011
5189
|
(this.lastSearchTerm || '').trim().length > 0) {
|
|
5012
5190
|
return (hAsync("p", { class: 'searchcraft-facet-list-message' }, "No facets are available for this search query."));
|
|
5013
5191
|
}
|
|
5014
|
-
|
|
5192
|
+
// Get root-level facets for view more functionality
|
|
5193
|
+
const rootFacets = Object.keys(this.renderedFacetTree.children);
|
|
5194
|
+
const threshold = this.viewMoreThreshold ?? 8;
|
|
5195
|
+
const shouldShowViewMore = threshold > 0 && rootFacets.length > threshold;
|
|
5196
|
+
const visibleFacets = shouldShowViewMore && !this.showAllFacets
|
|
5197
|
+
? rootFacets.slice(0, threshold)
|
|
5198
|
+
: rootFacets;
|
|
5199
|
+
return (hAsync("div", { class: 'searchcraft-facet-list-wrapper', "data-facet-section-collapsed": this.isCollapsed ? '' : undefined, "data-facet-section-expanded": !this.isCollapsed ? '' : undefined }, !this.isCollapsed && (hAsync("div", { class: 'searchcraft-facet-list-content' }, hAsync("div", { class: 'searchcraft-facet-list' }, visibleFacets.map((key) => {
|
|
5200
|
+
if (this.renderedFacetTree.children[key]) {
|
|
5201
|
+
return this.renderFacet(key, this.renderedFacetTree.children[key]);
|
|
5202
|
+
}
|
|
5203
|
+
})), shouldShowViewMore && (hAsync("button", { class: 'searchcraft-facet-list-view-more', onClick: this.handleViewMoreToggle, type: 'button' }, this.showAllFacets ? 'View less' : 'View more...'))))));
|
|
5015
5204
|
}
|
|
5016
5205
|
static get cmpMeta() { return {
|
|
5017
5206
|
"$flags$": 768,
|
|
@@ -5020,9 +5209,15 @@ class SearchcraftFacetList {
|
|
|
5020
5209
|
"searchcraftId": [1, "searchcraft-id"],
|
|
5021
5210
|
"fieldName": [1, "field-name"],
|
|
5022
5211
|
"exclude": [16],
|
|
5212
|
+
"initialCollapseState": [1, "initial-collapse-state"],
|
|
5213
|
+
"viewMoreThreshold": [2, "view-more-threshold"],
|
|
5023
5214
|
"selectedPaths": [32],
|
|
5024
5215
|
"facetTreeCollectedFromSearchResponse": [32],
|
|
5025
|
-
"renderedFacetTree": [32]
|
|
5216
|
+
"renderedFacetTree": [32],
|
|
5217
|
+
"isCollapsed": [32],
|
|
5218
|
+
"showAllFacets": [32],
|
|
5219
|
+
"handleCollapseToggle": [64],
|
|
5220
|
+
"getIsCollapsed": [64]
|
|
5026
5221
|
},
|
|
5027
5222
|
"$listeners$": undefined,
|
|
5028
5223
|
"$lazyBundleId$": "-",
|
|
@@ -5336,8 +5531,40 @@ class SearchcraftFilterPanel {
|
|
|
5336
5531
|
}
|
|
5337
5532
|
case 'facets': {
|
|
5338
5533
|
const item = filterItem;
|
|
5534
|
+
let facetListElement = null;
|
|
5535
|
+
let labelElement = null;
|
|
5536
|
+
const updateLabelAttributes = (isCollapsed) => {
|
|
5537
|
+
if (labelElement) {
|
|
5538
|
+
if (isCollapsed) {
|
|
5539
|
+
labelElement.removeAttribute('data-facet-section-expanded');
|
|
5540
|
+
labelElement.setAttribute('data-facet-section-collapsed', '');
|
|
5541
|
+
labelElement.setAttribute('aria-expanded', 'false');
|
|
5542
|
+
}
|
|
5543
|
+
else {
|
|
5544
|
+
labelElement.removeAttribute('data-facet-section-collapsed');
|
|
5545
|
+
labelElement.setAttribute('data-facet-section-expanded', '');
|
|
5546
|
+
labelElement.setAttribute('aria-expanded', 'true');
|
|
5547
|
+
}
|
|
5548
|
+
}
|
|
5549
|
+
};
|
|
5550
|
+
const handleToggle = async () => {
|
|
5551
|
+
if (facetListElement && 'handleCollapseToggle' in facetListElement && 'getIsCollapsed' in facetListElement) {
|
|
5552
|
+
await facetListElement.handleCollapseToggle();
|
|
5553
|
+
const isCollapsed = await facetListElement.getIsCollapsed();
|
|
5554
|
+
updateLabelAttributes(isCollapsed);
|
|
5555
|
+
}
|
|
5556
|
+
};
|
|
5339
5557
|
// return "filters-list"
|
|
5340
|
-
return (hAsync("div", { class: 'searchcraft-filter-panel-section' }, hAsync("p", {
|
|
5558
|
+
return (hAsync("div", { class: 'searchcraft-filter-panel-section' }, hAsync("p", { ref: (el) => {
|
|
5559
|
+
labelElement = el || null;
|
|
5560
|
+
}, class: 'searchcraft-filter-panel-label', "data-toggle-facet-section": true, "data-facet-section-expanded": item.options.initialCollapseState !== 'closed' ? '' : undefined, "data-facet-section-collapsed": item.options.initialCollapseState === 'closed' ? '' : undefined, onClick: handleToggle, onKeyDown: async (event) => {
|
|
5561
|
+
if (event.key === 'Enter' || event.key === ' ') {
|
|
5562
|
+
event.preventDefault();
|
|
5563
|
+
await handleToggle();
|
|
5564
|
+
}
|
|
5565
|
+
}, tabIndex: 0, role: 'button', "aria-expanded": item.options.initialCollapseState !== 'closed' }, filterItem.label), hAsync("searchcraft-facet-list", { ref: (el) => {
|
|
5566
|
+
facetListElement = el || null;
|
|
5567
|
+
}, fieldName: item.fieldName, exclude: item.options.exclude, initialCollapseState: item.options.initialCollapseState, viewMoreThreshold: item.options.viewMoreThreshold, onFacetSelectionUpdated: (event) => {
|
|
5341
5568
|
this.handleFacetSelectionUpdated(item.fieldName, event.detail.paths);
|
|
5342
5569
|
} })));
|
|
5343
5570
|
}
|
|
@@ -5674,6 +5901,11 @@ class SearchcraftPagination {
|
|
|
5674
5901
|
* The id of the Searchcraft instance that this component should use.
|
|
5675
5902
|
*/
|
|
5676
5903
|
searchcraftId;
|
|
5904
|
+
/**
|
|
5905
|
+
* Whether to scroll to the top of the search results when pagination buttons are clicked.
|
|
5906
|
+
* @default true
|
|
5907
|
+
*/
|
|
5908
|
+
scrollToTop = true;
|
|
5677
5909
|
// store vars
|
|
5678
5910
|
searchTerm;
|
|
5679
5911
|
searchResultsPerPage;
|
|
@@ -5714,8 +5946,47 @@ class SearchcraftPagination {
|
|
|
5714
5946
|
this.unsubscribe?.();
|
|
5715
5947
|
this.cleanupCore?.();
|
|
5716
5948
|
}
|
|
5949
|
+
/**
|
|
5950
|
+
* Smooth scroll to the top of the search results component
|
|
5951
|
+
*/
|
|
5952
|
+
smoothScrollToSearchResults() {
|
|
5953
|
+
if (!this.scrollToTop) {
|
|
5954
|
+
return;
|
|
5955
|
+
}
|
|
5956
|
+
const searchResultsElement = document.querySelector('searchcraft-search-results .searchcraft-search-results');
|
|
5957
|
+
if (!searchResultsElement) {
|
|
5958
|
+
return;
|
|
5959
|
+
}
|
|
5960
|
+
const elementRect = searchResultsElement.getBoundingClientRect();
|
|
5961
|
+
const scrollOffset = 200; // Offset in pixels above the element
|
|
5962
|
+
const targetPosition = elementRect.top + window.scrollY - scrollOffset;
|
|
5963
|
+
const startPosition = window.scrollY;
|
|
5964
|
+
const distance = targetPosition - startPosition;
|
|
5965
|
+
const duration = 1500;
|
|
5966
|
+
let startTime = null;
|
|
5967
|
+
// smooth scrolling
|
|
5968
|
+
const easeOutExpo = (t) => {
|
|
5969
|
+
return t === 1 ? 1 : 1 - 2 ** (-10 * t);
|
|
5970
|
+
};
|
|
5971
|
+
const animation = (currentTime) => {
|
|
5972
|
+
if (startTime === null) {
|
|
5973
|
+
startTime = currentTime;
|
|
5974
|
+
}
|
|
5975
|
+
const timeElapsed = currentTime - startTime;
|
|
5976
|
+
const progress = Math.min(timeElapsed / duration, 1);
|
|
5977
|
+
const ease = easeOutExpo(progress);
|
|
5978
|
+
window.scrollTo(0, startPosition + distance * ease);
|
|
5979
|
+
if (progress < 1) {
|
|
5980
|
+
requestAnimationFrame(animation);
|
|
5981
|
+
}
|
|
5982
|
+
};
|
|
5983
|
+
requestAnimationFrame(animation);
|
|
5984
|
+
}
|
|
5717
5985
|
handleGoToPage(page) {
|
|
5718
5986
|
this.setSearchResultsPage(page);
|
|
5987
|
+
if (this.scrollToTop) {
|
|
5988
|
+
this.smoothScrollToSearchResults();
|
|
5989
|
+
}
|
|
5719
5990
|
}
|
|
5720
5991
|
renderOddPaginationItem(page) {
|
|
5721
5992
|
return (hAsync("li", null, hAsync("button", { class: classNames('searchcraft-pagination-item', {
|
|
@@ -5774,6 +6045,7 @@ class SearchcraftPagination {
|
|
|
5774
6045
|
"$tagName$": "searchcraft-pagination",
|
|
5775
6046
|
"$members$": {
|
|
5776
6047
|
"searchcraftId": [1, "searchcraft-id"],
|
|
6048
|
+
"scrollToTop": [4, "scroll-to-top"],
|
|
5777
6049
|
"searchTerm": [32],
|
|
5778
6050
|
"searchResultsPerPage": [32],
|
|
5779
6051
|
"searchResultsPage": [32],
|
|
@@ -9872,7 +10144,7 @@ class SearchcraftSummaryBox {
|
|
|
9872
10144
|
}; }
|
|
9873
10145
|
}
|
|
9874
10146
|
|
|
9875
|
-
var styles = `[class*=searchcraft-],[class*=searchcraft-] *,[class*=searchcraft-]::before,[class*=searchcraft-]::after,[class*=searchcraft-] *,::before,[class*=searchcraft-] *,::after{box-sizing:border-box;padding:0;margin:0}:root{--sc-text-base-size: 1em;--sc-text-scale-ratio: 1.1;--sc-font-family: sans-serif;--sc-font-bold: 700;--sc-font-normal: 400;--sc-heading-1-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-2-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-3-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-4-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-5-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-6-font-size: calc( var(--sc-text-base-size) / ( var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) ) );--sc-body-font-size: calc(var(--sc-text-base-size));--sc-body-small-font-size: calc( var(--sc-text-base-size) / ( var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) ) )}:root{--sc-border-radius: 8px;--sc-border-radius-sm: calc(var(--sc-border-radius) / 2);--sc-border-radius-lg: calc(var(--sc-border-radius) * 2);--sc-border-radius-xl: calc(var(--sc-border-radius) * 3);--sc-border-radius-2xl: calc(var(--sc-border-radius) * 4);--sc-border-radius-full: 9999px}:root{--sc-breakpoint-sm: 576px;--sc-breakpoint-md: 768px;--sc-breakpoint-lg: 992px}:root{--sc-surface-neutral-primary: var(--sc-color-background, #ffffff);--sc-color-background-hover-computed: hsl( from var(--sc-color-background) h s clamp(10, calc(l + 5), 95) );--sc-surface-neutral-primary-hover: var( --sc-color-background-hover, var(--sc-color-background-hover-computed, #fafafa) );--sc-color-background-active-computed: hsl( from var(--sc-color-background) h s clamp(5, calc(l - 5), 90) );--sc-surface-neutral-primary-active: var( --sc-color-background-active, var(--sc-color-background-active-computed, #f7f7f7) );--sc-surface-neutral-secondary: var( --sc-color-background-secondary, var(--sc-color-background, #f3f3f3) );--sc-color-background-secondary-hover-computed: hsl( from var(--sc-color-background-secondary) h s clamp(10, calc(l + 5), 95) );--sc-surface-neutral-secondary-hover: var( --sc-color-background-hover, var(--sc-color-background-hover-computed, #e6e6e6) );--sc-color-background-secondary-active-computed: hsl( from var(--sc-color-background-secondary) h s clamp(5, calc(l - 5), 90) );--sc-surface-neutral-secondary-active: var( --sc-color-background-secondary-active, var(--sc-color-background-active-computed, #e0e0e0) );--sc-surface-neutral-light: #ffffff;--sc-content-neutral-primary: var(--sc-color-foreground, #292929);--sc-color-foreground-secondary-computed: hsl( from var(--sc-color-foreground) h s clamp(10, calc(l + 5), 90) );--sc-content-neutral-secondary: var( --sc-color-foreground-secondary, var(--sc-color-foreground-secondary-computed, #404040) );--sc-border-neutral: var(--sc-color-border, rgba(0, 0, 0, 0.1));--sc-surface-brand-primary: var(--sc-color-brand, #000000);--sc-color-brand-hover-computed: hsl( from var(--sc-color-brand) h s clamp(20, calc(l + 5), 95) );--sc-surface-brand-primary-hover: var( --sc-color-brand-hover, var(--sc-color-brand-hover-computed, #2e2e2e) );--sc-color-brand-active-computed: hsl( from var(--sc-color-brand) h s clamp(10, calc(l - 5), 85) );--sc-surface-brand-primary-active: var( --sc-color-brand-active, var(--sc-color-brand-active-computed, #292929) );--sc-surface-brand-secondary: var( --sc-color-brand-secondary, var(--sc-color-brand, #e6e6e6) );--sc-color-brand-secondary-hover-computed: hsl( from var(--sc-color-brand-secondary) h s clamp(10, calc(l + 5), 95) );--sc-surface-brand-secondary-hover: var( --sc-color-background-hover, var(--sc-color-background-hover-computed, #ebebeb) );--sc-color-brand-secondary-active-computed: hsl( from var(--sc-color-brand-secondary) h s clamp(5, calc(l - 5), 90) );--sc-surface-brand-secondary-active: var( --sc-color-brand-secondary-active, var(--sc-color-brand-active-computed, #e0e0e0) );--sc-content-brand: var( --sc-color-brand-text, var(--sc-surface-brand-primary) );--sc-content-brand-on-primary: #ffffff;--sc-border-brand: var(--sc-surface-brand-primary);--sc-surface-success-primary: var(--sc-color-success, #008000);--sc-color-success-primary-hover-computed: hsl( from var(--sc-color-success) h s 30 );--sc-surface-success-primary-hover: var( --sc-color-success-primary-hover, var(--sc-color-success-primary-hover-computed, #009900) );--sc-color-success-primary-active-computed: hsl( from var(--sc-color-success) h s 20 );--sc-surface-success-primary-active: var( --sc-color-success-primary-active, var(--sc-color-success-primary-active-computed, #006600) );--sc-color-success-secondary-computed: hsl( from var(--sc-color-success) h s 90 );--sc-surface-success-secondary: var( --sc-color-success-secondary, var(--sc-color-success-secondary-computed, #ccffcc) );--sc-color-success-secondary-hover-computed: hsl( from var(--sc-color-success-secondary) h s 95 );--sc-surface-success-secondary-hover: var( --sc-color-success-secondary-hover, var(--sc-color-success-secondary-hover-computed, #e6ffe6) );--sc-color-success-secondary-active-computed: hsl( from var(--sc-color-success-secondary) h s 85 );--sc-surface-success-secondary-active: var( --sc-color-success-secondary-active, var(--sc-color-success-secondary-active-computed, #b2ffb2) );--sc-content-success: var( --sc-color-brand-text, hsl(from var(--sc-surface-success-primary) h s 30) );--sc-content-success-on-primary: #ffffff;--sc-border-success: var(--sc-surface-success-primary);--sc-surface-caution-primary: var(--sc-color-caution, #cc6600);--sc-color-caution-primary-hover-computed: hsl( from var(--sc-color-caution) h s 30 );--sc-surface-caution-primary-hover: var( --sc-color-caution-primary-hover, var(--sc-color-caution-primary-hover-computed, #e57300) );--sc-color-caution-primary-active-computed: hsl( from var(--sc-color-caution) h s 20 );--sc-surface-caution-primary-active: var( --sc-color-caution-primary-active, var(--sc-color-caution-primary-active-computed, #b25a00) );--sc-color-caution-secondary-computed: hsl( from var(--sc-color-caution) h s 90 );--sc-surface-caution-secondary: var( --sc-color-caution-secondary, var(--sc-color-caution-secondary-computed, #ffd9b3) );--sc-color-caution-secondary-hover-computed: hsl( from var(--sc-color-caution-secondary) h s 95 );--sc-surface-caution-secondary-hover: var( --sc-color-caution-secondary-hover, var(--sc-color-caution-secondary-hover-computed, #ffe5cc) );--sc-color-caution-secondary-active-computed: hsl( from var(--sc-color-caution-secondary) h s 85 );--sc-surface-caution-secondary-active: var( --sc-color-caution-secondary-active, var(--sc-color-caution-secondary-active-computed, #ffcc99) );--sc-content-caution: var( --sc-color-caution-text, hsl(from var(--sc-surface-caution-primary) h s 30) );--sc-content-caution-on-primary: #ffffff;--sc-border-caution: var(--sc-surface-caution-primary);--sc-surface-danger-primary: var(--sc-color-danger, #cc0000);--sc-color-danger-primary-hover-computed: hsl( from var(--sc-color-danger) h s 30 );--sc-surface-danger-primary-hover: var( --sc-color-danger-primary-hover, var(--sc-color-danger-primary-hover-computed, #e50000) );--sc-color-danger-primary-active-computed: hsl( from var(--sc-color-danger) h s 20 );--sc-surface-danger-primary-active: var( --sc-color-danger-primary-active, var(--sc-color-danger-primary-active-computed, #b30000) );--sc-color-danger-secondary-computed: hsl(from var(--sc-color-danger) h s 90);--sc-surface-danger-secondary: var( --sc-color-danger-secondary, var(--sc-color-danger-secondary-computed, #ffcccc) );--sc-color-danger-secondary-hover-computed: hsl( from var(--sc-color-danger-secondary) h s 95 );--sc-surface-danger-secondary-hover: var( --sc-color-danger-secondary-hover, var(--sc-color-danger-secondary-hover-computed, #ffe7e7) );--sc-color-danger-secondary-active-computed: hsl( from var(--sc-color-danger-secondary) h s 85 );--sc-surface-danger-secondary-active: var( --sc-color-danger-secondary-active, var(--sc-color-danger-secondary-active-computed, #ffb3b3) );--sc-content-danger: var( --sc-color-caution-text, hsl(from var(--sc-surface-danger-primary) h s 30) );--sc-content-danger-on-primary: #ffffff;--sc-border-danger: var(--sc-surface-danger-primary);--sc-color-disabled: hsl(from var(--sc-color-page-primary) h s calc(l * 0.5));--sc-surface-disabled: var(--sc-color-disabled, #d9d9d9);--sc-color-disabled-text: hsl( from var(--sc-color-text-primary) h s calc(l * 0.5) );--sc-content-disabled: var(--sc-color-disabled-text, #737373);--sc-content-disabled-on-disabled: var(--sc-color-disabled-text, #737373)}@supports(hanging-punctuation: first) and (font: -apple-system-body) and (-webkit-appearance: none){:root{--sc-color-background-hover-computed: hsl( from var(--sc-color-background) h s clamp(10%, calc(l + 5%), 95%) );--sc-color-background-active-computed: hsl( from var(--sc-color-background) h s clamp(5%, calc(l - 5%), 90%) );--sc-color-foreground-secondary-computed: hsl( from var(--sc-color-foreground) h s clamp(10%, calc(l + 5%), 90%) );--sc-color-brand-hover-computed: hsl( from var(--sc-color-brand) h s clamp(20%, calc(l + 5%), 95%) );--sc-color-brand-active-computed: hsl( from var(--sc-color-brand) h s clamp(10%, calc(l - 5%), 85%) );--sc-color-success-primary-hover-computed: hsl( from var(--sc-color-success) h s 30% );--sc-color-success-primary-active-computed: hsl( from var(--sc-color-success) h s 20% );--sc-color-success-secondary-computed: hsl( from var(--sc-color-success) h s 90% );--sc-color-success-secondary-hover-computed: hsl( from var(--sc-color-success-secondary) h s 95% );--sc-color-success-secondary-active-computed: hsl( from var(--sc-color-success-secondary) h s 85% );--sc-content-success: var( --sc-color-brand-text, hsl(from var(--sc-surface-success-primary) h s 30%) );--sc-color-caution-primary-hover-computed: hsl( from var(--sc-color-caution) h s 30% );--sc-color-caution-primary-active-computed: hsl( from var(--sc-color-caution) h s 20% );--sc-color-caution-secondary-computed: hsl( from var(--sc-color-caution) h s 90% );--sc-color-caution-secondary-hover-computed: hsl( from var(--sc-color-caution-secondary) h s 95% );--sc-color-caution-secondary-active-computed: hsl( from var(--sc-color-caution-secondary) h s 85% );--sc-content-caution: var( --sc-color-caution-text, hsl(from var(--sc-surface-caution-primary) h s 30%) );--sc-color-danger-primary-hover-computed: hsl( from var(--sc-color-danger) h s 30% );--sc-color-danger-primary-active-computed: hsl( from var(--sc-color-danger) h s 20% );--sc-color-danger-secondary-computed: hsl( from var(--sc-color-danger) h s 90% );--sc-color-danger-secondary-hover-computed: hsl( from var(--sc-color-danger-secondary) h s 95% );--sc-color-danger-secondary-active-computed: hsl( from var(--sc-color-danger-secondary) h s 85% );--sc-content-danger: var( --sc-color-caution-text, hsl(from var(--sc-surface-danger-primary) h s 30%) )}}.searchcraft-ad{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased}.searchcraft-ad-no-template{display:flex;flex-direction:column;font-size:.875rem}.searchcraft-ad-no-template>p{margin:0}.searchcraft-adm-ad{display:flex;flex-direction:column;justify-content:center;gap:16px}.searchcraft-search-result{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased}.searchcraft-search-result-no-template{display:flex;flex-direction:column;font-size:.875rem}.searchcraft-search-result-no-template>p{margin:0}.searchcraft-search-results{display:flex;flex-direction:column;justify-content:center;gap:16px}.searchcraft-search-results-empty-state{text-align:center}.searchcraft-search-results-error-message{text-align:center}.searchcraft-button{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);background:none;border:2px solid rgba(0,0,0,0);border-radius:var(--sc-border-radius);cursor:pointer;display:flex;gap:4px;padding:12px;position:relative}.searchcraft-button.searchcraft-button-disabled{cursor:not-allowed}.searchcraft-button-primary{background-color:var(--sc-surface-brand-primary);color:var(--sc-content-brand-on-primary);font-weight:var(--sc-font-bold)}.searchcraft-button-primary:hover{background-color:var(--sc-surface-brand-primary-hover)}.searchcraft-button-primary:focus{border-color:var(--sc-border-primary)}.searchcraft-button-primary:active{background-color:var(--sc-surface-brand-primary-active)}.searchcraft-button-primary.searchcraft-button-disabled,.searchcraft-button-primary.searchcraft-button-disabled:hover,.searchcraft-button-primary.searchcraft-button-disabled:focus,.searchcraft-button-primary.searchcraft-button-disabled:active{background-color:var(--sc-surface-disabled);border-color:rgba(0,0,0,0);color:var(--sc-content-disabled)}.searchcraft-button-tertiary{background-color:var(--sc-surface-neutral-primary);color:var(--sc-content-brand);font-weight:var(--sc-font-normal)}.searchcraft-button-tertiary:hover{background-color:var(--sc-surface-brand-secondary-hover)}.searchcraft-button-tertiary:focus{background-color:var(--sc-surface-neutral-light);border-color:var(--sc-border-primary)}.searchcraft-button-tertiary:active{background-color:var(--sc-surface-brand-secondary-active)}.searchcraft-button-tertiary.searchcraft-button-disabled,.searchcraft-button-tertiary.searchcraft-button-disabled:hover,.searchcraft-button-tertiary.searchcraft-button-disabled:focus,.searchcraft-button-tertiary.searchcraft-button-disabled:active{background-color:var(--sc-surface-neutral-light);border-color:rgba(0,0,0,0);color:var(--sc-content-disabled)}.searchcraft-button-icon{fill:none}.searchcraft-error-message{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal);color:var(--sc-content-danger);margin:0}.searchcraft-facet-list{display:flex;flex-direction:column;gap:8px;width:100%}.searchcraft-facet-list-checkbox-label{align-items:center;color:var(--sc-content-neutral-primary);display:flex;font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);gap:8px;position:relative;-webkit-font-smoothing:antialiased}.searchcraft-facet-list-checkbox-input-wrapper{position:relative}.searchcraft-facet-list-checkbox-input{align-items:center;appearance:none;background-color:var(--sc-surface-neutral-secondary);border:1px solid var(--sc-surface-disabled);border-radius:var(--sc-border-radius);cursor:pointer;display:flex;height:24px;justify-content:center;width:24px;margin:0}.searchcraft-facet-list-checkbox-input:focus{outline:2px solid var(--sc-surface-brand-primary);outline-offset:2px}.searchcraft-facet-list-checkbox-input:checked{background-color:var(--sc-surface-brand-primary);position:relative}.searchcraft-facet-list-checkbox-input:checked+.searchcraft-facet-list-checkbox-input-check-icon{display:flex}.searchcraft-facet-list-checkbox-input:checked+.searchcraft-facet-list-checkbox-input-dash-icon{display:flex}.searchcraft-facet-child-list{display:flex;flex-direction:column;gap:6px}.searchcraft-facet-child-list-checkbox-label{margin-left:24px}.searchcraft-facet-child-list-checkbox-label:first-child{margin-top:6px}.searchcraft-facet-list-checkbox-input-check-icon{display:none;height:16px;left:50%;position:absolute;margin-top:2px;top:50%;transform:translate(-50%, -50%);width:16px}.searchcraft-facet-list-checkbox-input-dash-icon{display:none;height:3px;left:50%;position:absolute;top:50%;transform:translate(-50%, -50%);width:14px}.searchcraft-facet-list-message{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal);color:var(--sc-content-disabled);text-align:center}.searchcraft-filter-panel{display:flex;flex-direction:column;gap:16px}.searchcraft-filter-panel-section{display:flex;flex-direction:column;gap:8px}.searchcraft-filter-panel-label{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal);font-weight:var(--sc-font-bold)}@media(max-width: 767px){[data-toggle-filter-panel]{cursor:pointer;display:flex !important;align-items:center;justify-content:space-between;width:100%}[data-toggle-filter-panel]::after{content:"›";display:inline-block;font-size:1.5em;line-height:1;margin-left:auto;flex-shrink:0;transition:transform .2s ease;transform-origin:center}[data-toggle-filter-panel][data-filter-panel-collapsed]::after{transform:rotate(90deg)}[data-toggle-filter-panel][data-filter-panel-expanded]::after{transform:rotate(-90deg)}}@media(min-width: 768px){[data-toggle-filter-panel]{cursor:default}[data-toggle-filter-panel]::after{display:none}}:root{--sc-input-form-border-radius: var(--sc-border-radius);--sc-input-form-search-icon-size: 20px;--sc-input-form-clear-icon-size: 20px}.searchcraft-input-form-grid{display:grid;gap:4px 8px}.searchcraft-input-form-grid-button-left{grid-template-rows:repeat(3, auto);grid-template-columns:auto 1fr}.searchcraft-input-form-grid-button-left .searchcraft-input-form-button{grid-column:1/span 1;grid-row:2/span 1}.searchcraft-input-form-grid-button-left .searchcraft-input-form-label{grid-column:2/span 1;grid-row:1/span 1}.searchcraft-input-form-grid-button-left .searchcraft-input-form-error-message{grid-column:2/span 1;grid-row:3/span 1}.searchcraft-input-form-grid-button-left .searchcraft-input-form-input-wrapper{grid-column:2/span 1;grid-row:2/span 1}.searchcraft-input-form-grid-button-right{grid-template-rows:repeat(3, auto);grid-template-columns:1fr auto}.searchcraft-input-form-grid-button-right .searchcraft-input-form-button{grid-column:2/span 1;grid-row:2/span 1}.searchcraft-input-form-grid-button-right .searchcraft-input-form-label{grid-column:1/span 1;grid-row:1/span 1}.searchcraft-input-form-grid-button-right .searchcraft-input-form-error-message{grid-column:1/span 1;grid-row:3/span 1}.searchcraft-input-form-grid-button-right .searchcraft-input-form-input-wrapper{grid-column:1/span 1;grid-row:2/span 1}.searchcraft-input-form-grid-button-none{grid-template-rows:repeat(3, auto);grid-template-columns:auto}.searchcraft-input-form-grid-button-none .searchcraft-input-form-button{display:none}.searchcraft-input-form-grid-button-none .searchcraft-input-form-label{grid-column:1/span 1;grid-row:1/span 1}.searchcraft-input-form-grid-button-none .searchcraft-input-form-error-message{grid-column:1/span 1;grid-row:3/span 1}.searchcraft-input-form-grid-button-none .searchcraft-input-form-input-wrapper{grid-column:1/span 1;grid-row:2/span 1}.searchcraft-input-form-input-wrapper{display:flex;position:relative}.searchcraft-input-form-input{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);background-color:var(--sc-surface-neutral-secondary);border-radius:var(--sc-input-form-border-radius);border:none;color:var(--sc-content-neutral-primary);flex:1;outline:none;padding:12px 44px}.searchcraft-input-form-input::placeholder{color:var(--sc-content-disabled)}.searchcraft-input-form-input:focus{outline:var(--sc-border-brand) solid 2px;outline-offset:-1px}.searchcraft-input-form-input.searchcraft-placeholder-hide-on-focus:focus::placeholder{opacity:0}.searchcraft-input-form-error{color:var(--sc-content-danger);outline:var(--sc-border-danger) solid 2px}.searchcraft-input-form-error:focus{outline:var(--sc-border-danger) solid 2px}.searchcraft-input-form-input-icon{align-items:center;bottom:0;display:flex;justify-content:center;left:0;position:absolute;pointer-events:none;top:0;width:44px}.searchcraft-input-form-input-search-icon{color:var(--sc-content-neutral-secondary);fill:none;height:var(--sc-input-form-search-icon-size);pointer-events:none;width:var(--sc-input-form-search-icon-size)}.searchcraft-input-form-clear-button{all:unset;align-items:center;bottom:0;border:none;cursor:pointer;display:flex;justify-content:center;outline:none;position:absolute;right:0;top:0;width:44px}.searchcraft-input-form-clear-icon{color:var(--sc-content-brand);fill:none;height:var(--sc-input-form-clear-icon-size);width:var(--sc-input-form-clear-icon-size)}.searchcraft-input-label{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal);color:var(--sc-content-neutral-primary);font-weight:var(--sc-font-bold);margin-top:4px;margin-bottom:4px}:root{--sc-popover-button-border-radius: var(--sc-border-radius)}@media(min-width: 576px){:root{--sc-popover-button-border-radius: var(--sc-border-radius-lg)}}.searchcraft-popover-button{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);cursor:pointer}.searchcraft-popover-button-skeuomorphic{appearance:none;background:none;border:none;color:var(--sc-content-neutral-primary);display:block;width:100%}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-wrapper{border:1px solid var(--sc-border-neutral);border-radius:var(--sc-popover-button-border-radius);box-shadow:0 1px 1px rgb(from var(--sc-content-neutral-secondary) r g b/10%) inset,0 2px 4px rgb(from var(--sc-content-neutral-secondary) r g b/5%) inset;display:flex;gap:24px;height:40px;justify-content:space-between;line-height:1;padding:4px 5px 4px 10px;background:var(--sc-surface-neutral-primary)}@media(min-width: 576px){.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-wrapper{box-shadow:0 1px 1px rgb(from var(--sc-content-neutral-secondary) r g b/10%) inset,0 2px 2px rgb(from var(--sc-content-neutral-secondary) r g b/5%) inset,0 4px 4px rgb(from var(--sc-content-neutral-secondary) r g b/5%) inset;height:63px;padding:8px 10px 8px 16px}}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-input{align-items:center;display:flex;gap:4px}@media(min-width: 576px){.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-input{gap:8px}}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps{color:var(--sc-content-neutral-secondary);display:flex;gap:4px;font-size:20px;font-weight:500}@media(min-width: 576px){.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps{gap:8px}}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps-keycap{border-radius:calc(var(--sc-popover-button-border-radius) - 3px);border-radius:calc(var(var(--sc-popover-button-border-radius)) - 3px);background-color:var(--sc-surface-neutral-primary);box-shadow:0 3px hsl(from var(--sc-surface-neutral-secondary) h s calc(l - 5)),0 1px 2px rgb(from var(--sc-content-neutral-secondary) r g b/10%),0 6px 4px rgb(from var(--sc-content-neutral-secondary) r g b/5%);height:calc(100% - 2px);position:relative}@media(min-width: 576px){.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps-keycap{border-radius:calc(var(--sc-popover-button-border-radius) - 8px);border-radius:calc(var(var(--sc-popover-button-border-radius)) - 8px);box-shadow:0 4px hsl(from var(--sc-surface-neutral-secondary) h s calc(l - 5)),0 1px 2px rgb(from var(--sc-content-neutral-secondary) r g b/15%),0 6px 1px rgb(from var(--sc-content-neutral-secondary) r g b/20%),0 7px 2px rgb(from var(--sc-content-neutral-secondary) r g b/15%),0 9px 4px rgb(from var(--sc-content-neutral-secondary) r g b/10%),0 13px 8px rgb(from var(--sc-content-neutral-secondary) r g b/5%);height:calc(100% - 5px)}}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps-keycap::before,.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps-keycap::after{content:"";display:block}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps-keycap::before{border-radius:calc(var(--sc-popover-button-border-radius) - 4px);border-radius:calc(var(var(--sc-popover-button-border-radius)) - 4px);background:linear-gradient(340deg, rgb(from var(--sc-surface-neutral-secondary) r g b/2%) 0%, var(--sc-surface-neutral-secondary) 100%);inset:2px;position:absolute}@media(min-width: 576px){.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps-keycap::before{border-radius:calc(var(--sc-popover-button-border-radius) - 12px);border-radius:calc(var(var(--sc-popover-button-border-radius)) - 12px);inset:4px}}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps-keycap::after{aspect-ratio:1/1;height:100%}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps-keycap>span{display:flex;line-height:1;left:50%;margin-top:2%;position:absolute;top:50%;transform:translate(-50%, -50%)}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-input-search-icon{height:60%;width:auto}@media(min-width: 576px){.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-input-search-icon{height:50%}}:root{--sc-popover-list-view-height: 600px;--sc-popover-modal-max-width: 800px}.searchcraft-popover-form{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);display:flex;flex:1;flex-direction:column}.searchcraft-popover-form searchcraft-input-form,.searchcraft-popover-form searchcraft-popover-footer{width:100%}.searchcraft-popover-form.searchcraft-popover-form-active .searchcraft-popover-form-input{padding-bottom:1px}.searchcraft-popover-form searchcraft-popover-list-view{flex-shrink:1;height:100%;min-height:0;overflow:auto;padding:0 24px}.searchcraft-popover-form-input{display:flex;flex-direction:row;gap:12px}.searchcraft-popover-form-input .searchcraft-input-form-input{background-color:var(--sc-surface-neutral-primary);border:1px solid var(--sc-border-neutral);border-radius:var(--sc-border-radius-lg);box-shadow:0 1px 1px rgb(from var(--sc-content-neutral-primary) r g b/10%) inset,0 2px 2px rgb(from var(--sc-content-neutral-primary) r g b/5%) inset,0 4px 4px rgb(from var(--sc-content-neutral-primary) r g b/5%) inset;width:0}.searchcraft-popover-form-cancel-button{background:none;border:none;cursor:pointer;font-size:14px}.searchcraft-popover-form-modal-input,.searchcraft-popover-form-fullscreen-input{padding:24px}.searchcraft-popover-form-modal-popover-list-view,.searchcraft-popover-form-fullscreen-popover-list-view{flex-grow:1;flex-shrink:1;min-height:0;overflow:auto;padding:0 24px}.searchcraft-popover-form-inline{background-color:var(--sc-surface-neutral-primary);border:1px solid rgba(0,0,0,0);border-radius:var(--sc-border-radius-xl);padding:12px;position:relative}.searchcraft-popover-form-inline.searchcraft-popover-form-active{border:1px solid var(--sc-border-neutral);border-bottom:none;border-bottom-left-radius:0;border-bottom-right-radius:0;padding-bottom:1px}.searchcraft-popover-form-inline searchcraft-popover-list-view{padding:0 12px}.searchcraft-popover-form-inline .searchcraft-input-form-input,.searchcraft-popover-form-inline .searchcraft-popover-list-item-link,.searchcraft-popover-form-inline .searchcraft-adm-ad-link{border-radius:calc(--sc-border-radius-xl - 12px);border-radius:calc(var(--sc-border-radius-xl) - 12px)}.searchcraft-popover-form-inline-wrapper{background-color:var(--sc-surface-neutral-primary);border:1px solid var(--sc-border-neutral);border-top:none;border-bottom-left-radius:var(--sc-border-radius-xl);border-bottom-right-radius:var(--sc-border-radius-xl);display:flex;flex-direction:column;left:-1px;max-height:var(--sc-popover-list-view-height);overflow:hidden;position:absolute;right:-1px;top:100%}.searchcraft-popover-form-modal{align-items:center;display:flex;inset:0;position:fixed;z-index:1000}.searchcraft-popover-form-modal .searchcraft-input-form-input,.searchcraft-popover-form-modal .searchcraft-popover-list-item-link,.searchcraft-popover-form-modal .searchcraft-adm-ad-link{border-radius:calc(--sc-border-radius-2xl - 20px);border-radius:calc(var(--sc-border-radius-2xl) - 20px)}.searchcraft-popover-form-modal-backdrop{background-color:rgb(from var(--sc-content-neutral-primary) r g b/50%);display:none;inset:0;position:fixed}@media(min-width: 576px){.searchcraft-popover-form-modal-backdrop{display:block}}.searchcraft-popover-form-modal-wrapper{background-color:var(--sc-surface-neutral-primary);box-shadow:1px 2px rgb(from var(--sc-content-neutral-primary) r g b/7%),0 2px 4px rgb(from var(--sc-content-neutral-primary) r g b/7%),0 4px 8px rgb(from var(--sc-content-neutral-primary) r g b/7%),0 8px 16px rgb(from var(--sc-content-neutral-primary) r g b/7%),0 16px 32px rgb(from var(--sc-content-neutral-primary) r g b/7%),0 32px 64px rgb(from var(--sc-content-neutral-primary) r g b/7%);display:flex;flex-direction:column;inset:0;max-width:var(--sc-popover-modal-max-width);overflow:hidden;position:absolute;width:100%;z-index:1001}@media(min-width: 576px){.searchcraft-popover-form-modal-wrapper{border-radius:var(--sc-border-radius-2xl);inset:0;margin-top:100px;max-height:var(--sc-popover-list-view-height);max-width:var(--sc-popover-modal-max-width);position:relative}}.searchcraft-popover-form-modal-cancel-button{border-radius:calc(--sc-border-radius-2xl - 20px);border-radius:calc(var(--sc-border-radius-2xl) - 20px);padding:8px}@media(min-width: 576px){.searchcraft-popover-form-modal-cancel-button{padding:8px 12px}}.searchcraft-popover-form-fullscreen{background-color:var(--sc-surface-neutral-primary);display:flex;flex-direction:column;justify-content:space-between;inset:0;position:fixed;z-index:1000}.searchcraft-popover-form-fullscreen .searchcraft-popover-list-item-link,.searchcraft-popover-form-fullscreen .searchcraft-adm-ad-link{border-radius:var(--sc-border-radius-lg)}.searchcraft-popover-form-fullscreen-cancel-button{border-radius:var(--sc-border-radius-lg);padding:8px}@media(min-width: 576px){.searchcraft-popover-form-fullscreen-cancel-button{padding:8px 12px}}.searchcraft-popover-footer{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;background-color:var(--sc-surface-neutral-secondary);box-shadow:0 1px 1px rgb(from var(--sc-content-neutral-primary) r g b/10%) inset,0 2px 2px rgb(from var(--sc-content-neutral-primary) r g b/5%) inset,0 4px 4px rgb(from var(--sc-content-neutral-primary) r g b/5%) inset;display:flex;gap:8px;justify-content:space-between;line-height:1;padding:20px 24px}@media(min-width: 576px){.searchcraft-popover-footer{padding:20px 32px}}.searchcraft-popover-footer-results-info{margin:0}.searchcraft-popover-footer-link{color:var(--sc-content-neutral-primary);display:flex;max-width:160px;width:100%}:root{--sc-popover-list-item-image-fit: contain}.searchcraft-popover-list-item{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;border-bottom:1px solid var(--sc-border-neutral);padding:12px 0}searchcraft-popover-list-item:last-child .searchcraft-popover-list-item{border-bottom:none}.searchcraft-popover-list-item-link{align-items:flex-start;color:var(--sc-content-neutral-primary);display:flex;gap:24px;padding:12px;text-decoration:none}.searchcraft-popover-list-item-link:focus,.searchcraft-popover-list-item-link:active{background-color:var(--sc-surface-neutral-primary-active)}.searchcraft-popover-list-item-link:hover{background-color:var(--sc-surface-neutral-primary-hover)}.searchcraft-popover-list-item-image-wrapper{align-items:center;aspect-ratio:16/9;display:flex;flex-shrink:0;justify-content:center;width:160px}.searchcraft-popover-list-item-image{height:100%;object-fit:var(--sc-popover-list-item-image-fit);width:100%}.searchcraft-popover-list-item-content{display:flex;flex-direction:column;flex-grow:1;gap:4px;justify-content:center}.searchcraft-popover-list-item-content-title,.searchcraft-popover-list-item-content-subtitle{display:-webkit-box;line-clamp:2;margin:0;overflow:hidden;-webkit-line-clamp:2;-webkit-box-orient:vertical}.searchcraft-popover-list-item-content-title{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-heading-5-font-size);font-weight:var(--sc-font-bold)}.searchcraft-popover-list-item-content-subtitle{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal)}.searchcraft-popover-list-view{display:flex;flex-direction:column}.searchcraft-results-info{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);color:var(--sc-content-primary);margin:0}.searchcraft-slider{align-items:center;display:flex;flex-direction:column;gap:10px;width:100%;margin-top:4px}.searchcraft-slider-range{align-items:center;background-color:var(--sc-surface-disabled);border-radius:999px;display:flex;position:relative;height:4px;width:100%}.searchcraft-slider-range::-webkit-slider-runnable-track{pointer-events:none}.searchcraft-slider-range .searchcraft-slider-active-range{background-color:var(--sc-surface-brand-primary);border-radius:2px;height:4px;position:absolute;top:50%;transform:translateY(-50%);z-index:0}.searchcraft-slider-range .searchcraft-slider-active-range::-webkit-slider-runnable-track{pointer-events:none}.searchcraft-slider-range .searchcraft-slider-active-range::-moz-range-track{pointer-events:none}.searchcraft-slider-range .searchcraft-slider-input{appearance:none;background:rgba(0,0,0,0);border-radius:2px;height:4px;margin:0;outline:none;pointer-events:none;position:absolute;width:100%;-webkit-appearance:none}.searchcraft-slider-range .searchcraft-slider-input::-webkit-slider-thumb{background-color:var(--sc-surface-neutral-light);border-radius:50%;border:1px solid var(--sc-border-neutral);cursor:pointer;height:18px;pointer-events:all;width:18px;-webkit-appearance:none}.searchcraft-slider-range .searchcraft-slider-input::-moz-range-thumb{background-color:var(--sc-surface-neutral-light);border-radius:50%;border:1px solid var(--sc-border-neutral);cursor:pointer;height:18px;pointer-events:all;width:18px}.searchcraft-slider-range .searchcraft-slider-input:focus::-webkit-slider-thumb{outline:2px solid var(--sc-surface-brand-primary)}.searchcraft-slider-range .searchcraft-slider-input:focus::-moz-range-thumb{outline:2px solid var(--sc-surface-brand-primary)}.searchcraft-slider-label{color:var(--sc-content-primary);display:flex;font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal);justify-content:space-between;margin-top:4px;width:100%}.searchcraft-slider-start-label,.searchcraft-slider-end-label{min-width:30px;text-align:center}.searchcraft-toggle-button{align-items:flex-start;display:flex;gap:10px;justify-content:space-between}.searchcraft-toggle-button-label{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);color:var(--sc-content-neutral-primary);margin:0}.searchcraft-toggle-button-sub-label{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal);color:var(--sc-content-neutral-secondary);margin:0}.searchcraft-toggle-button-background{background:var(--sc-surface-disabled);border-radius:var(--sc-border-radius-full);border:none;cursor:pointer;flex-shrink:0;height:26px;position:relative;transition:background-color .2s;width:44px}.searchcraft-toggle-button-handle{background:var(--sc-surface-neutral-light);border-radius:50%;height:18px;left:4px;position:absolute;top:calc(50% - 9px);transition:transform .3s ease;width:18px}.searchcraft-toggle-button-active .searchcraft-toggle-button-background{background:var(--sc-surface-brand-primary);box-shadow:0px 0px 0px 1px rgba(0,0,0,.05)}.searchcraft-toggle-button-active .searchcraft-toggle-button-handle{transform:translateX(16px)}.searchcraft-pagination{display:inline-grid;gap:16px;grid-template-columns:repeat(3, auto);grid-template-rows:1fr}.searchcraft-pagination-list{border:1px solid var(--sc-border-neutral);border-radius:var(--sc-border-radius);display:flex;list-style-type:none;margin:0;overflow:hidden;padding:0;width:auto}.searchcraft-pagination-list li{border-right:1px solid var(--sc-border-neutral);height:100%;min-height:44px;width:44px}.searchcraft-pagination-list li:last-child{border-right:none}.searchcraft-pagination-item{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);align-items:center;background-color:var(--sc-surface-neutral-primary);border:none;display:flex;height:100%;justify-content:center;width:100%}.searchcraft-pagination-item-active{background-color:var(--sc-surface-brand-secondary);font-weight:var(--sc-font-bold)}.searchcraft-pagination-control{border:1px solid var(--sc-border-neutral);border-radius:var(--sc-border-radius)}.searchcraft-pagination-range{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);align-items:center;display:flex}.searchcraft-select{display:flex;flex-direction:column;gap:4px}.searchcraft-select-label{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal);font-weight:var(--sc-font-bold)}.searchcraft-select-input-wrapper{position:relative}.searchcraft-select-input{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);appearance:none;background-color:var(--sc-surface-neutral-secondary);border:2px solid rgba(0,0,0,0);border-radius:var(--sc-border-radius);cursor:pointer;height:44px;padding:0 44px 0 16px;width:100%}.searchcraft-select-input:hover{background-color:var(--sc-surface-neutral-secondary-hover)}.searchcraft-select-input:active{background-color:var(--sc-surface-neutral-secondary-active)}.searchcraft-select-input:focus{border-color:var(--sc-border-brand);outline:none}.searchcraft-select-input-icon{fill:none;pointer-events:none;position:absolute;right:12px;top:50%;transform:translateY(-50%)}.searchcraft-select-caption{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal)}.searchcraft-search-results-per-page{display:flex}.searchcraft-search-results-per-page-select{align-items:center;display:flex;gap:12px}.searchcraft-search-results-per-page-select-label{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal)}.searchcraft-search-results-per-page-select-input{min-width:120px}.searchcraft-summary-box{padding:20px;border-radius:var(--sc-border-radius);background-color:var(--sc-surface-neutral-secondary);position:relative;min-height:200px;color:var(--sc-content-neutral-primary);font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal)}.searchcraft-summary-box h1,.searchcraft-summary-box h2,.searchcraft-summary-box h3,.searchcraft-summary-box h4,.searchcraft-summary-box h5{padding-top:10px;padding-bottom:10px}.searchcraft-summary-box p{padding-bottom:10px}.searchcraft-summary-box img{max-width:200px}.searchcraft-summary-box ol,.searchcraft-summary-box ul{padding-left:1em;padding-bottom:10px}.searchcraft-summary-box a{color:var(--sc-content-brand)}.searchcraft-loading-label{position:absolute;top:50%;left:50%;transform:translateY(-50%) translateX(-50%);margin-top:40px;letter-spacing:2px;color:#828282;font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal)}.searchcraft-loading-bars{margin:0 auto;width:60px;height:50px;text-align:center;position:absolute;top:50%;left:50%;transform:translateY(-50%) translateX(-50%);display:flex;gap:2px}.searchcraft-loading-bars>div{height:100%;width:8px;-webkit-animation:delay .8s infinite ease-in-out;animation:delay .8s infinite ease-in-out;opacity:.2}.searchcraft-loading-bars .searchcraft-loading-bar-1{background-color:var(--sc-surface-brand-primary);opacity:.1}.searchcraft-loading-bars .searchcraft-loading-bar-2{background-color:var(--sc-surface-brand-primary);animation-delay:-0.7s;opacity:.2}.searchcraft-loading-bars .searchcraft-loading-bar-3{background-color:var(--sc-surface-brand-primary);animation-delay:-0.6s;opacity:.3}.searchcraft-loading-bars .searchcraft-loading-bar-4{background-color:var(--sc-surface-brand-primary);animation-delay:-0.5s;opacity:.4}.searchcraft-loading-bars .searchcraft-loading-bar-5{background-color:var(--sc-surface-brand-primary);animation-delay:-0.4s;opacity:.5}.searchcraft-loading-bars .searchcraft-loading-bar-6{background-color:var(--sc-surface-brand-primary);animation-delay:-0.3s;opacity:.6}@keyframes delay{0%,40%,100%{transform:scaleY(0.05)}20%{transform:scaleY(1)}}/*# sourceMappingURL=hologram.css.map */
|
|
10147
|
+
var styles = `[class*=searchcraft-],[class*=searchcraft-] *,[class*=searchcraft-]::before,[class*=searchcraft-]::after,[class*=searchcraft-] *,::before,[class*=searchcraft-] *,::after{box-sizing:border-box;padding:0;margin:0}:root{--sc-text-base-size: 1em;--sc-text-scale-ratio: 1.1;--sc-font-family: sans-serif;--sc-font-bold: 700;--sc-font-normal: 400;--sc-heading-1-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-2-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-3-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-4-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-5-font-size: calc( var(--sc-text-base-size) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) );--sc-heading-6-font-size: calc( var(--sc-text-base-size) / ( var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) ) );--sc-body-font-size: calc(var(--sc-text-base-size));--sc-body-small-font-size: calc( var(--sc-text-base-size) / ( var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) * var(--sc-text-scale-ratio) ) )}:root{--sc-border-radius: 8px;--sc-border-radius-sm: calc(var(--sc-border-radius) / 2);--sc-border-radius-lg: calc(var(--sc-border-radius) * 2);--sc-border-radius-xl: calc(var(--sc-border-radius) * 3);--sc-border-radius-2xl: calc(var(--sc-border-radius) * 4);--sc-border-radius-full: 9999px}:root{--sc-breakpoint-sm: 576px;--sc-breakpoint-md: 768px;--sc-breakpoint-lg: 992px}:root{--sc-surface-neutral-primary: var(--sc-color-background, #ffffff);--sc-color-background-hover-computed: hsl( from var(--sc-color-background) h s clamp(10, calc(l + 5), 95) );--sc-surface-neutral-primary-hover: var( --sc-color-background-hover, var(--sc-color-background-hover-computed, #fafafa) );--sc-color-background-active-computed: hsl( from var(--sc-color-background) h s clamp(5, calc(l - 5), 90) );--sc-surface-neutral-primary-active: var( --sc-color-background-active, var(--sc-color-background-active-computed, #f7f7f7) );--sc-surface-neutral-secondary: var( --sc-color-background-secondary, var(--sc-color-background, #f3f3f3) );--sc-color-background-secondary-hover-computed: hsl( from var(--sc-color-background-secondary) h s clamp(10, calc(l + 5), 95) );--sc-surface-neutral-secondary-hover: var( --sc-color-background-hover, var(--sc-color-background-hover-computed, #e6e6e6) );--sc-color-background-secondary-active-computed: hsl( from var(--sc-color-background-secondary) h s clamp(5, calc(l - 5), 90) );--sc-surface-neutral-secondary-active: var( --sc-color-background-secondary-active, var(--sc-color-background-active-computed, #e0e0e0) );--sc-surface-neutral-light: #ffffff;--sc-content-neutral-primary: var(--sc-color-foreground, #292929);--sc-color-foreground-secondary-computed: hsl( from var(--sc-color-foreground) h s clamp(10, calc(l + 5), 90) );--sc-content-neutral-secondary: var( --sc-color-foreground-secondary, var(--sc-color-foreground-secondary-computed, #404040) );--sc-border-neutral: var(--sc-color-border, rgba(0, 0, 0, 0.1));--sc-surface-brand-primary: var(--sc-color-brand, #000000);--sc-color-brand-hover-computed: hsl( from var(--sc-color-brand) h s clamp(20, calc(l + 5), 95) );--sc-surface-brand-primary-hover: var( --sc-color-brand-hover, var(--sc-color-brand-hover-computed, #2e2e2e) );--sc-color-brand-active-computed: hsl( from var(--sc-color-brand) h s clamp(10, calc(l - 5), 85) );--sc-surface-brand-primary-active: var( --sc-color-brand-active, var(--sc-color-brand-active-computed, #292929) );--sc-surface-brand-secondary: var( --sc-color-brand-secondary, var(--sc-color-brand, #e6e6e6) );--sc-color-brand-secondary-hover-computed: hsl( from var(--sc-color-brand-secondary) h s clamp(10, calc(l + 5), 95) );--sc-surface-brand-secondary-hover: var( --sc-color-background-hover, var(--sc-color-background-hover-computed, #ebebeb) );--sc-color-brand-secondary-active-computed: hsl( from var(--sc-color-brand-secondary) h s clamp(5, calc(l - 5), 90) );--sc-surface-brand-secondary-active: var( --sc-color-brand-secondary-active, var(--sc-color-brand-active-computed, #e0e0e0) );--sc-content-brand: var( --sc-color-brand-text, var(--sc-surface-brand-primary) );--sc-content-brand-on-primary: #ffffff;--sc-border-brand: var(--sc-surface-brand-primary);--sc-surface-success-primary: var(--sc-color-success, #008000);--sc-color-success-primary-hover-computed: hsl( from var(--sc-color-success) h s 30 );--sc-surface-success-primary-hover: var( --sc-color-success-primary-hover, var(--sc-color-success-primary-hover-computed, #009900) );--sc-color-success-primary-active-computed: hsl( from var(--sc-color-success) h s 20 );--sc-surface-success-primary-active: var( --sc-color-success-primary-active, var(--sc-color-success-primary-active-computed, #006600) );--sc-color-success-secondary-computed: hsl( from var(--sc-color-success) h s 90 );--sc-surface-success-secondary: var( --sc-color-success-secondary, var(--sc-color-success-secondary-computed, #ccffcc) );--sc-color-success-secondary-hover-computed: hsl( from var(--sc-color-success-secondary) h s 95 );--sc-surface-success-secondary-hover: var( --sc-color-success-secondary-hover, var(--sc-color-success-secondary-hover-computed, #e6ffe6) );--sc-color-success-secondary-active-computed: hsl( from var(--sc-color-success-secondary) h s 85 );--sc-surface-success-secondary-active: var( --sc-color-success-secondary-active, var(--sc-color-success-secondary-active-computed, #b2ffb2) );--sc-content-success: var( --sc-color-brand-text, hsl(from var(--sc-surface-success-primary) h s 30) );--sc-content-success-on-primary: #ffffff;--sc-border-success: var(--sc-surface-success-primary);--sc-surface-caution-primary: var(--sc-color-caution, #cc6600);--sc-color-caution-primary-hover-computed: hsl( from var(--sc-color-caution) h s 30 );--sc-surface-caution-primary-hover: var( --sc-color-caution-primary-hover, var(--sc-color-caution-primary-hover-computed, #e57300) );--sc-color-caution-primary-active-computed: hsl( from var(--sc-color-caution) h s 20 );--sc-surface-caution-primary-active: var( --sc-color-caution-primary-active, var(--sc-color-caution-primary-active-computed, #b25a00) );--sc-color-caution-secondary-computed: hsl( from var(--sc-color-caution) h s 90 );--sc-surface-caution-secondary: var( --sc-color-caution-secondary, var(--sc-color-caution-secondary-computed, #ffd9b3) );--sc-color-caution-secondary-hover-computed: hsl( from var(--sc-color-caution-secondary) h s 95 );--sc-surface-caution-secondary-hover: var( --sc-color-caution-secondary-hover, var(--sc-color-caution-secondary-hover-computed, #ffe5cc) );--sc-color-caution-secondary-active-computed: hsl( from var(--sc-color-caution-secondary) h s 85 );--sc-surface-caution-secondary-active: var( --sc-color-caution-secondary-active, var(--sc-color-caution-secondary-active-computed, #ffcc99) );--sc-content-caution: var( --sc-color-caution-text, hsl(from var(--sc-surface-caution-primary) h s 30) );--sc-content-caution-on-primary: #ffffff;--sc-border-caution: var(--sc-surface-caution-primary);--sc-surface-danger-primary: var(--sc-color-danger, #cc0000);--sc-color-danger-primary-hover-computed: hsl( from var(--sc-color-danger) h s 30 );--sc-surface-danger-primary-hover: var( --sc-color-danger-primary-hover, var(--sc-color-danger-primary-hover-computed, #e50000) );--sc-color-danger-primary-active-computed: hsl( from var(--sc-color-danger) h s 20 );--sc-surface-danger-primary-active: var( --sc-color-danger-primary-active, var(--sc-color-danger-primary-active-computed, #b30000) );--sc-color-danger-secondary-computed: hsl(from var(--sc-color-danger) h s 90);--sc-surface-danger-secondary: var( --sc-color-danger-secondary, var(--sc-color-danger-secondary-computed, #ffcccc) );--sc-color-danger-secondary-hover-computed: hsl( from var(--sc-color-danger-secondary) h s 95 );--sc-surface-danger-secondary-hover: var( --sc-color-danger-secondary-hover, var(--sc-color-danger-secondary-hover-computed, #ffe7e7) );--sc-color-danger-secondary-active-computed: hsl( from var(--sc-color-danger-secondary) h s 85 );--sc-surface-danger-secondary-active: var( --sc-color-danger-secondary-active, var(--sc-color-danger-secondary-active-computed, #ffb3b3) );--sc-content-danger: var( --sc-color-caution-text, hsl(from var(--sc-surface-danger-primary) h s 30) );--sc-content-danger-on-primary: #ffffff;--sc-border-danger: var(--sc-surface-danger-primary);--sc-color-disabled: hsl(from var(--sc-color-page-primary) h s calc(l * 0.5));--sc-surface-disabled: var(--sc-color-disabled, #d9d9d9);--sc-color-disabled-text: hsl( from var(--sc-color-text-primary) h s calc(l * 0.5) );--sc-content-disabled: var(--sc-color-disabled-text, #737373);--sc-content-disabled-on-disabled: var(--sc-color-disabled-text, #737373)}@supports(hanging-punctuation: first) and (font: -apple-system-body) and (-webkit-appearance: none){:root{--sc-color-background-hover-computed: hsl( from var(--sc-color-background) h s clamp(10%, calc(l + 5%), 95%) );--sc-color-background-active-computed: hsl( from var(--sc-color-background) h s clamp(5%, calc(l - 5%), 90%) );--sc-color-foreground-secondary-computed: hsl( from var(--sc-color-foreground) h s clamp(10%, calc(l + 5%), 90%) );--sc-color-brand-hover-computed: hsl( from var(--sc-color-brand) h s clamp(20%, calc(l + 5%), 95%) );--sc-color-brand-active-computed: hsl( from var(--sc-color-brand) h s clamp(10%, calc(l - 5%), 85%) );--sc-color-success-primary-hover-computed: hsl( from var(--sc-color-success) h s 30% );--sc-color-success-primary-active-computed: hsl( from var(--sc-color-success) h s 20% );--sc-color-success-secondary-computed: hsl( from var(--sc-color-success) h s 90% );--sc-color-success-secondary-hover-computed: hsl( from var(--sc-color-success-secondary) h s 95% );--sc-color-success-secondary-active-computed: hsl( from var(--sc-color-success-secondary) h s 85% );--sc-content-success: var( --sc-color-brand-text, hsl(from var(--sc-surface-success-primary) h s 30%) );--sc-color-caution-primary-hover-computed: hsl( from var(--sc-color-caution) h s 30% );--sc-color-caution-primary-active-computed: hsl( from var(--sc-color-caution) h s 20% );--sc-color-caution-secondary-computed: hsl( from var(--sc-color-caution) h s 90% );--sc-color-caution-secondary-hover-computed: hsl( from var(--sc-color-caution-secondary) h s 95% );--sc-color-caution-secondary-active-computed: hsl( from var(--sc-color-caution-secondary) h s 85% );--sc-content-caution: var( --sc-color-caution-text, hsl(from var(--sc-surface-caution-primary) h s 30%) );--sc-color-danger-primary-hover-computed: hsl( from var(--sc-color-danger) h s 30% );--sc-color-danger-primary-active-computed: hsl( from var(--sc-color-danger) h s 20% );--sc-color-danger-secondary-computed: hsl( from var(--sc-color-danger) h s 90% );--sc-color-danger-secondary-hover-computed: hsl( from var(--sc-color-danger-secondary) h s 95% );--sc-color-danger-secondary-active-computed: hsl( from var(--sc-color-danger-secondary) h s 85% );--sc-content-danger: var( --sc-color-caution-text, hsl(from var(--sc-surface-danger-primary) h s 30%) )}}.searchcraft-ad{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased}.searchcraft-ad-no-template{display:flex;flex-direction:column;font-size:.875rem}.searchcraft-ad-no-template>p{margin:0}.searchcraft-adm-ad{display:flex;flex-direction:column;justify-content:center;gap:16px}.searchcraft-search-result{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased}.searchcraft-search-result-no-template{display:flex;flex-direction:column;font-size:.875rem}.searchcraft-search-result-no-template>p{margin:0}.searchcraft-search-results{display:flex;flex-direction:column;justify-content:center;gap:16px}.searchcraft-search-results-empty-state{text-align:center}.searchcraft-search-results-error-message{text-align:center}.searchcraft-button{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);background:none;border:2px solid rgba(0,0,0,0);border-radius:var(--sc-border-radius);cursor:pointer;display:flex;gap:4px;padding:12px;position:relative}.searchcraft-button.searchcraft-button-disabled{cursor:not-allowed}.searchcraft-button-primary{background-color:var(--sc-surface-brand-primary);color:var(--sc-content-brand-on-primary);font-weight:var(--sc-font-bold)}.searchcraft-button-primary:hover{background-color:var(--sc-surface-brand-primary-hover)}.searchcraft-button-primary:focus{border-color:var(--sc-border-primary)}.searchcraft-button-primary:active{background-color:var(--sc-surface-brand-primary-active)}.searchcraft-button-primary.searchcraft-button-disabled,.searchcraft-button-primary.searchcraft-button-disabled:hover,.searchcraft-button-primary.searchcraft-button-disabled:focus,.searchcraft-button-primary.searchcraft-button-disabled:active{background-color:var(--sc-surface-disabled);border-color:rgba(0,0,0,0);color:var(--sc-content-disabled)}.searchcraft-button-tertiary{background-color:var(--sc-surface-neutral-primary);color:var(--sc-content-brand);font-weight:var(--sc-font-normal)}.searchcraft-button-tertiary:hover{background-color:var(--sc-surface-brand-secondary-hover)}.searchcraft-button-tertiary:focus{background-color:var(--sc-surface-neutral-light);border-color:var(--sc-border-primary)}.searchcraft-button-tertiary:active{background-color:var(--sc-surface-brand-secondary-active)}.searchcraft-button-tertiary.searchcraft-button-disabled,.searchcraft-button-tertiary.searchcraft-button-disabled:hover,.searchcraft-button-tertiary.searchcraft-button-disabled:focus,.searchcraft-button-tertiary.searchcraft-button-disabled:active{background-color:var(--sc-surface-neutral-light);border-color:rgba(0,0,0,0);color:var(--sc-content-disabled)}.searchcraft-button-icon{fill:none}.searchcraft-error-message{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal);color:var(--sc-content-danger);margin:0}.searchcraft-facet-list{display:flex;flex-direction:column;gap:8px;width:100%}.searchcraft-facet-list-checkbox-label{align-items:center;color:var(--sc-content-neutral-primary);display:flex;font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);gap:8px;position:relative;-webkit-font-smoothing:antialiased}.searchcraft-facet-list-checkbox-input-wrapper{position:relative}.searchcraft-facet-list-checkbox-input{align-items:center;appearance:none;background-color:var(--sc-surface-neutral-secondary);border:1px solid var(--sc-surface-disabled);border-radius:var(--sc-border-radius);cursor:pointer;display:flex;height:24px;justify-content:center;width:24px;margin:0}.searchcraft-facet-list-checkbox-input:focus{outline:2px solid var(--sc-surface-brand-primary);outline-offset:2px}.searchcraft-facet-list-checkbox-input:checked{background-color:var(--sc-surface-brand-primary);position:relative}.searchcraft-facet-list-checkbox-input:checked+.searchcraft-facet-list-checkbox-input-check-icon{display:flex}.searchcraft-facet-list-checkbox-input:checked+.searchcraft-facet-list-checkbox-input-dash-icon{display:flex}.searchcraft-facet-child-list{display:flex;flex-direction:column;gap:6px}.searchcraft-facet-child-list-checkbox-label{margin-left:24px}.searchcraft-facet-child-list-checkbox-label:first-child{margin-top:6px}.searchcraft-facet-list-checkbox-input-check-icon{display:none;height:16px;left:50%;position:absolute;margin-top:2px;top:50%;transform:translate(-50%, -50%);width:16px}.searchcraft-facet-list-checkbox-input-dash-icon{display:none;height:3px;left:50%;position:absolute;top:50%;transform:translate(-50%, -50%);width:14px}.searchcraft-facet-list-message{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal);color:var(--sc-content-disabled);text-align:center}.searchcraft-facet-list-wrapper{display:flex;flex-direction:column;width:100%;min-height:0}.searchcraft-facet-list-content{display:flex;flex-direction:column;gap:8px;min-height:0;flex-shrink:0}.searchcraft-facet-list-view-more{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);background:none;border:none;color:var(--sc-content-brand);cursor:pointer;padding:8px 0;text-align:left;text-decoration:underline}.searchcraft-facet-list-view-more:hover{color:var(--sc-surface-brand-primary-hover)}.searchcraft-facet-list-view-more:focus{outline:2px solid var(--sc-surface-brand-primary);outline-offset:2px}.searchcraft-filter-panel{display:flex;flex-direction:column;gap:16px}.searchcraft-filter-panel-section{display:flex;flex-direction:column;gap:8px}.searchcraft-filter-panel-label{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal);font-weight:var(--sc-font-bold)}[data-toggle-facet-section]{cursor:pointer;display:flex;align-items:center;justify-content:space-between;width:100%;position:relative}[data-toggle-facet-section]::after{content:"›";display:inline-block;font-size:1.5em;line-height:1;margin-left:auto;flex-shrink:0;transition:transform .2s ease;transform-origin:center}[data-toggle-facet-section][data-facet-section-collapsed]::after{transform:rotate(90deg)}[data-toggle-facet-section][data-facet-section-expanded]::after{transform:rotate(-90deg)}@media(max-width: 767px){[data-toggle-filter-panel]{cursor:pointer;display:flex !important;align-items:center;justify-content:space-between;width:100%}[data-toggle-filter-panel]::after{content:"›";display:inline-block;font-size:1.5em;line-height:1;margin-left:auto;flex-shrink:0;transition:transform .2s ease;transform-origin:center}[data-toggle-filter-panel][data-filter-panel-collapsed]::after{transform:rotate(90deg)}[data-toggle-filter-panel][data-filter-panel-expanded]::after{transform:rotate(-90deg)}}@media(min-width: 768px){[data-toggle-filter-panel]{cursor:default}[data-toggle-filter-panel]::after{display:none}}:root{--sc-input-form-border-radius: var(--sc-border-radius);--sc-input-form-search-icon-size: 20px;--sc-input-form-clear-icon-size: 20px}.searchcraft-input-form-grid{display:grid;gap:4px 8px}.searchcraft-input-form-grid-button-left{grid-template-rows:repeat(3, auto);grid-template-columns:auto 1fr}.searchcraft-input-form-grid-button-left .searchcraft-input-form-button{grid-column:1/span 1;grid-row:2/span 1}.searchcraft-input-form-grid-button-left .searchcraft-input-form-label{grid-column:2/span 1;grid-row:1/span 1}.searchcraft-input-form-grid-button-left .searchcraft-input-form-error-message{grid-column:2/span 1;grid-row:3/span 1}.searchcraft-input-form-grid-button-left .searchcraft-input-form-input-wrapper{grid-column:2/span 1;grid-row:2/span 1}.searchcraft-input-form-grid-button-right{grid-template-rows:repeat(3, auto);grid-template-columns:1fr auto}.searchcraft-input-form-grid-button-right .searchcraft-input-form-button{grid-column:2/span 1;grid-row:2/span 1}.searchcraft-input-form-grid-button-right .searchcraft-input-form-label{grid-column:1/span 1;grid-row:1/span 1}.searchcraft-input-form-grid-button-right .searchcraft-input-form-error-message{grid-column:1/span 1;grid-row:3/span 1}.searchcraft-input-form-grid-button-right .searchcraft-input-form-input-wrapper{grid-column:1/span 1;grid-row:2/span 1}.searchcraft-input-form-grid-button-none{grid-template-rows:repeat(3, auto);grid-template-columns:auto}.searchcraft-input-form-grid-button-none .searchcraft-input-form-button{display:none}.searchcraft-input-form-grid-button-none .searchcraft-input-form-label{grid-column:1/span 1;grid-row:1/span 1}.searchcraft-input-form-grid-button-none .searchcraft-input-form-error-message{grid-column:1/span 1;grid-row:3/span 1}.searchcraft-input-form-grid-button-none .searchcraft-input-form-input-wrapper{grid-column:1/span 1;grid-row:2/span 1}.searchcraft-input-form-input-wrapper{display:flex;position:relative}.searchcraft-input-form-input{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);background-color:var(--sc-surface-neutral-secondary);border-radius:var(--sc-input-form-border-radius);border:none;color:var(--sc-content-neutral-primary);flex:1;outline:none;padding:12px 44px}.searchcraft-input-form-input::placeholder{color:var(--sc-content-disabled)}.searchcraft-input-form-input:focus{outline:var(--sc-border-brand) solid 2px;outline-offset:-1px}.searchcraft-input-form-input.searchcraft-placeholder-hide-on-focus:focus::placeholder{opacity:0}.searchcraft-input-form-error{color:var(--sc-content-danger);outline:var(--sc-border-danger) solid 2px}.searchcraft-input-form-error:focus{outline:var(--sc-border-danger) solid 2px}.searchcraft-input-form-input-icon{align-items:center;bottom:0;display:flex;justify-content:center;left:0;position:absolute;pointer-events:none;top:0;width:44px}.searchcraft-input-form-input-search-icon{color:var(--sc-content-neutral-secondary);fill:none;height:var(--sc-input-form-search-icon-size);pointer-events:none;width:var(--sc-input-form-search-icon-size)}.searchcraft-input-form-clear-button{all:unset;align-items:center;bottom:0;border:none;cursor:pointer;display:flex;justify-content:center;outline:none;position:absolute;right:0;top:0;width:44px}.searchcraft-input-form-clear-icon{color:var(--sc-content-brand);fill:none;height:var(--sc-input-form-clear-icon-size);width:var(--sc-input-form-clear-icon-size)}.searchcraft-input-label{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal);color:var(--sc-content-neutral-primary);font-weight:var(--sc-font-bold);margin-top:4px;margin-bottom:4px}:root{--sc-popover-button-border-radius: var(--sc-border-radius)}@media(min-width: 576px){:root{--sc-popover-button-border-radius: var(--sc-border-radius-lg)}}.searchcraft-popover-button{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);cursor:pointer}.searchcraft-popover-button-skeuomorphic{appearance:none;background:none;border:none;color:var(--sc-content-neutral-primary);display:block;width:100%}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-wrapper{border:1px solid var(--sc-border-neutral);border-radius:var(--sc-popover-button-border-radius);box-shadow:0 1px 1px rgb(from var(--sc-content-neutral-secondary) r g b/10%) inset,0 2px 4px rgb(from var(--sc-content-neutral-secondary) r g b/5%) inset;display:flex;gap:24px;height:40px;justify-content:space-between;line-height:1;padding:4px 5px 4px 10px;background:var(--sc-surface-neutral-primary)}@media(min-width: 576px){.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-wrapper{box-shadow:0 1px 1px rgb(from var(--sc-content-neutral-secondary) r g b/10%) inset,0 2px 2px rgb(from var(--sc-content-neutral-secondary) r g b/5%) inset,0 4px 4px rgb(from var(--sc-content-neutral-secondary) r g b/5%) inset;height:63px;padding:8px 10px 8px 16px}}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-input{align-items:center;display:flex;gap:4px}@media(min-width: 576px){.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-input{gap:8px}}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps{color:var(--sc-content-neutral-secondary);display:flex;gap:4px;font-size:20px;font-weight:500}@media(min-width: 576px){.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps{gap:8px}}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps-keycap{border-radius:calc(var(--sc-popover-button-border-radius) - 3px);border-radius:calc(var(var(--sc-popover-button-border-radius)) - 3px);background-color:var(--sc-surface-neutral-primary);box-shadow:0 3px hsl(from var(--sc-surface-neutral-secondary) h s calc(l - 5)),0 1px 2px rgb(from var(--sc-content-neutral-secondary) r g b/10%),0 6px 4px rgb(from var(--sc-content-neutral-secondary) r g b/5%);height:calc(100% - 2px);position:relative}@media(min-width: 576px){.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps-keycap{border-radius:calc(var(--sc-popover-button-border-radius) - 8px);border-radius:calc(var(var(--sc-popover-button-border-radius)) - 8px);box-shadow:0 4px hsl(from var(--sc-surface-neutral-secondary) h s calc(l - 5)),0 1px 2px rgb(from var(--sc-content-neutral-secondary) r g b/15%),0 6px 1px rgb(from var(--sc-content-neutral-secondary) r g b/20%),0 7px 2px rgb(from var(--sc-content-neutral-secondary) r g b/15%),0 9px 4px rgb(from var(--sc-content-neutral-secondary) r g b/10%),0 13px 8px rgb(from var(--sc-content-neutral-secondary) r g b/5%);height:calc(100% - 5px)}}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps-keycap::before,.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps-keycap::after{content:"";display:block}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps-keycap::before{border-radius:calc(var(--sc-popover-button-border-radius) - 4px);border-radius:calc(var(var(--sc-popover-button-border-radius)) - 4px);background:linear-gradient(340deg, rgb(from var(--sc-surface-neutral-secondary) r g b/2%) 0%, var(--sc-surface-neutral-secondary) 100%);inset:2px;position:absolute}@media(min-width: 576px){.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps-keycap::before{border-radius:calc(var(--sc-popover-button-border-radius) - 12px);border-radius:calc(var(var(--sc-popover-button-border-radius)) - 12px);inset:4px}}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps-keycap::after{aspect-ratio:1/1;height:100%}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-keycaps-keycap>span{display:flex;line-height:1;left:50%;margin-top:2%;position:absolute;top:50%;transform:translate(-50%, -50%)}.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-input-search-icon{height:60%;width:auto}@media(min-width: 576px){.searchcraft-popover-button-skeuomorphic .searchcraft-popover-button-input-search-icon{height:50%}}:root{--sc-popover-list-view-height: 600px;--sc-popover-modal-max-width: 800px}.searchcraft-popover-form{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);display:flex;flex:1;flex-direction:column}.searchcraft-popover-form searchcraft-input-form,.searchcraft-popover-form searchcraft-popover-footer{width:100%}.searchcraft-popover-form.searchcraft-popover-form-active .searchcraft-popover-form-input{padding-bottom:1px}.searchcraft-popover-form searchcraft-popover-list-view{flex-shrink:1;height:100%;min-height:0;overflow:auto;padding:0 24px}.searchcraft-popover-form-input{display:flex;flex-direction:row;gap:12px}.searchcraft-popover-form-input .searchcraft-input-form-input{background-color:var(--sc-surface-neutral-primary);border:1px solid var(--sc-border-neutral);border-radius:var(--sc-border-radius-lg);box-shadow:0 1px 1px rgb(from var(--sc-content-neutral-primary) r g b/10%) inset,0 2px 2px rgb(from var(--sc-content-neutral-primary) r g b/5%) inset,0 4px 4px rgb(from var(--sc-content-neutral-primary) r g b/5%) inset;width:0}.searchcraft-popover-form-cancel-button{background:none;border:none;cursor:pointer;font-size:14px}.searchcraft-popover-form-modal-input,.searchcraft-popover-form-fullscreen-input{padding:24px}.searchcraft-popover-form-modal-popover-list-view,.searchcraft-popover-form-fullscreen-popover-list-view{flex-grow:1;flex-shrink:1;min-height:0;overflow:auto;padding:0 24px}.searchcraft-popover-form-inline{background-color:var(--sc-surface-neutral-primary);border:1px solid rgba(0,0,0,0);border-radius:var(--sc-border-radius-xl);padding:12px;position:relative}.searchcraft-popover-form-inline.searchcraft-popover-form-active{border:1px solid var(--sc-border-neutral);border-bottom:none;border-bottom-left-radius:0;border-bottom-right-radius:0;padding-bottom:1px}.searchcraft-popover-form-inline searchcraft-popover-list-view{padding:0 12px}.searchcraft-popover-form-inline .searchcraft-input-form-input,.searchcraft-popover-form-inline .searchcraft-popover-list-item-link,.searchcraft-popover-form-inline .searchcraft-adm-ad-link{border-radius:calc(--sc-border-radius-xl - 12px);border-radius:calc(var(--sc-border-radius-xl) - 12px)}.searchcraft-popover-form-inline-wrapper{background-color:var(--sc-surface-neutral-primary);border:1px solid var(--sc-border-neutral);border-top:none;border-bottom-left-radius:var(--sc-border-radius-xl);border-bottom-right-radius:var(--sc-border-radius-xl);display:flex;flex-direction:column;left:-1px;max-height:var(--sc-popover-list-view-height);overflow:hidden;position:absolute;right:-1px;top:100%}.searchcraft-popover-form-modal{align-items:center;display:flex;inset:0;position:fixed;z-index:1000}.searchcraft-popover-form-modal .searchcraft-input-form-input,.searchcraft-popover-form-modal .searchcraft-popover-list-item-link,.searchcraft-popover-form-modal .searchcraft-adm-ad-link{border-radius:calc(--sc-border-radius-2xl - 20px);border-radius:calc(var(--sc-border-radius-2xl) - 20px)}.searchcraft-popover-form-modal-backdrop{background-color:rgb(from var(--sc-content-neutral-primary) r g b/50%);display:none;inset:0;position:fixed}@media(min-width: 576px){.searchcraft-popover-form-modal-backdrop{display:block}}.searchcraft-popover-form-modal-wrapper{background-color:var(--sc-surface-neutral-primary);box-shadow:1px 2px rgb(from var(--sc-content-neutral-primary) r g b/7%),0 2px 4px rgb(from var(--sc-content-neutral-primary) r g b/7%),0 4px 8px rgb(from var(--sc-content-neutral-primary) r g b/7%),0 8px 16px rgb(from var(--sc-content-neutral-primary) r g b/7%),0 16px 32px rgb(from var(--sc-content-neutral-primary) r g b/7%),0 32px 64px rgb(from var(--sc-content-neutral-primary) r g b/7%);display:flex;flex-direction:column;inset:0;max-width:var(--sc-popover-modal-max-width);overflow:hidden;position:absolute;width:100%;z-index:1001}@media(min-width: 576px){.searchcraft-popover-form-modal-wrapper{border-radius:var(--sc-border-radius-2xl);inset:0;margin-top:100px;max-height:var(--sc-popover-list-view-height);max-width:var(--sc-popover-modal-max-width);position:relative}}.searchcraft-popover-form-modal-cancel-button{border-radius:calc(--sc-border-radius-2xl - 20px);border-radius:calc(var(--sc-border-radius-2xl) - 20px);padding:8px}@media(min-width: 576px){.searchcraft-popover-form-modal-cancel-button{padding:8px 12px}}.searchcraft-popover-form-fullscreen{background-color:var(--sc-surface-neutral-primary);display:flex;flex-direction:column;justify-content:space-between;inset:0;position:fixed;z-index:1000}.searchcraft-popover-form-fullscreen .searchcraft-popover-list-item-link,.searchcraft-popover-form-fullscreen .searchcraft-adm-ad-link{border-radius:var(--sc-border-radius-lg)}.searchcraft-popover-form-fullscreen-cancel-button{border-radius:var(--sc-border-radius-lg);padding:8px}@media(min-width: 576px){.searchcraft-popover-form-fullscreen-cancel-button{padding:8px 12px}}.searchcraft-popover-footer{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;background-color:var(--sc-surface-neutral-secondary);box-shadow:0 1px 1px rgb(from var(--sc-content-neutral-primary) r g b/10%) inset,0 2px 2px rgb(from var(--sc-content-neutral-primary) r g b/5%) inset,0 4px 4px rgb(from var(--sc-content-neutral-primary) r g b/5%) inset;display:flex;gap:8px;justify-content:space-between;line-height:1;padding:20px 24px}@media(min-width: 576px){.searchcraft-popover-footer{padding:20px 32px}}.searchcraft-popover-footer-results-info{margin:0}.searchcraft-popover-footer-link{color:var(--sc-content-neutral-primary);display:flex;max-width:160px;width:100%}:root{--sc-popover-list-item-image-fit: contain}.searchcraft-popover-list-item{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;border-bottom:1px solid var(--sc-border-neutral);padding:12px 0}searchcraft-popover-list-item:last-child .searchcraft-popover-list-item{border-bottom:none}.searchcraft-popover-list-item-link{align-items:flex-start;color:var(--sc-content-neutral-primary);display:flex;gap:24px;padding:12px;text-decoration:none}.searchcraft-popover-list-item-link:focus,.searchcraft-popover-list-item-link:active{background-color:var(--sc-surface-neutral-primary-active)}.searchcraft-popover-list-item-link:hover{background-color:var(--sc-surface-neutral-primary-hover)}.searchcraft-popover-list-item-image-wrapper{align-items:center;aspect-ratio:16/9;display:flex;flex-shrink:0;justify-content:center;width:160px}.searchcraft-popover-list-item-image{height:100%;object-fit:var(--sc-popover-list-item-image-fit);width:100%}.searchcraft-popover-list-item-content{display:flex;flex-direction:column;flex-grow:1;gap:4px;justify-content:center}.searchcraft-popover-list-item-content-title,.searchcraft-popover-list-item-content-subtitle{display:-webkit-box;line-clamp:2;margin:0;overflow:hidden;-webkit-line-clamp:2;-webkit-box-orient:vertical}.searchcraft-popover-list-item-content-title{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-heading-5-font-size);font-weight:var(--sc-font-bold)}.searchcraft-popover-list-item-content-subtitle{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal)}.searchcraft-popover-list-view{display:flex;flex-direction:column}.searchcraft-results-info{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);color:var(--sc-content-primary);margin:0}.searchcraft-slider{align-items:center;display:flex;flex-direction:column;gap:10px;width:100%;margin-top:4px}.searchcraft-slider-range{align-items:center;background-color:var(--sc-surface-disabled);border-radius:999px;display:flex;position:relative;height:4px;width:100%}.searchcraft-slider-range::-webkit-slider-runnable-track{pointer-events:none}.searchcraft-slider-range .searchcraft-slider-active-range{background-color:var(--sc-surface-brand-primary);border-radius:2px;height:4px;position:absolute;top:50%;transform:translateY(-50%);z-index:0}.searchcraft-slider-range .searchcraft-slider-active-range::-webkit-slider-runnable-track{pointer-events:none}.searchcraft-slider-range .searchcraft-slider-active-range::-moz-range-track{pointer-events:none}.searchcraft-slider-range .searchcraft-slider-input{appearance:none;background:rgba(0,0,0,0);border-radius:2px;height:4px;margin:0;outline:none;pointer-events:none;position:absolute;width:100%;-webkit-appearance:none}.searchcraft-slider-range .searchcraft-slider-input::-webkit-slider-thumb{background-color:var(--sc-surface-neutral-light);border-radius:50%;border:1px solid var(--sc-border-neutral);cursor:pointer;height:18px;pointer-events:all;width:18px;-webkit-appearance:none}.searchcraft-slider-range .searchcraft-slider-input::-moz-range-thumb{background-color:var(--sc-surface-neutral-light);border-radius:50%;border:1px solid var(--sc-border-neutral);cursor:pointer;height:18px;pointer-events:all;width:18px}.searchcraft-slider-range .searchcraft-slider-input:focus::-webkit-slider-thumb{outline:2px solid var(--sc-surface-brand-primary)}.searchcraft-slider-range .searchcraft-slider-input:focus::-moz-range-thumb{outline:2px solid var(--sc-surface-brand-primary)}.searchcraft-slider-label{color:var(--sc-content-primary);display:flex;font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal);justify-content:space-between;margin-top:4px;width:100%}.searchcraft-slider-start-label,.searchcraft-slider-end-label{min-width:30px;text-align:center}.searchcraft-toggle-button{align-items:flex-start;display:flex;gap:10px;justify-content:space-between}.searchcraft-toggle-button-label{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);color:var(--sc-content-neutral-primary);margin:0}.searchcraft-toggle-button-sub-label{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal);color:var(--sc-content-neutral-secondary);margin:0}.searchcraft-toggle-button-background{background:var(--sc-surface-disabled);border-radius:var(--sc-border-radius-full);border:none;cursor:pointer;flex-shrink:0;height:26px;position:relative;transition:background-color .2s;width:44px}.searchcraft-toggle-button-handle{background:var(--sc-surface-neutral-light);border-radius:50%;height:18px;left:4px;position:absolute;top:calc(50% - 9px);transition:transform .3s ease;width:18px}.searchcraft-toggle-button-active .searchcraft-toggle-button-background{background:var(--sc-surface-brand-primary);box-shadow:0px 0px 0px 1px rgba(0,0,0,.05)}.searchcraft-toggle-button-active .searchcraft-toggle-button-handle{transform:translateX(16px)}.searchcraft-pagination{display:inline-grid;gap:16px;grid-template-columns:repeat(3, auto);grid-template-rows:1fr}.searchcraft-pagination-list{border:1px solid var(--sc-border-neutral);border-radius:var(--sc-border-radius);display:flex;list-style-type:none;margin:0;overflow:hidden;padding:0;width:auto}.searchcraft-pagination-list li{border-right:1px solid var(--sc-border-neutral);height:100%;min-height:44px;width:44px}.searchcraft-pagination-list li:last-child{border-right:none}.searchcraft-pagination-item{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);align-items:center;background-color:var(--sc-surface-neutral-primary);border:none;display:flex;height:100%;justify-content:center;width:100%}.searchcraft-pagination-item-active{background-color:var(--sc-surface-brand-secondary);font-weight:var(--sc-font-bold)}.searchcraft-pagination-control{border:1px solid var(--sc-border-neutral);border-radius:var(--sc-border-radius)}.searchcraft-pagination-range{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);align-items:center;display:flex}.searchcraft-select{display:flex;flex-direction:column;gap:4px}.searchcraft-select-label{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal);font-weight:var(--sc-font-bold)}.searchcraft-select-input-wrapper{position:relative}.searchcraft-select-input{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal);appearance:none;background-color:var(--sc-surface-neutral-secondary);border:2px solid rgba(0,0,0,0);border-radius:var(--sc-border-radius);cursor:pointer;height:44px;padding:0 44px 0 16px;width:100%}.searchcraft-select-input:hover{background-color:var(--sc-surface-neutral-secondary-hover)}.searchcraft-select-input:active{background-color:var(--sc-surface-neutral-secondary-active)}.searchcraft-select-input:focus{border-color:var(--sc-border-brand);outline:none}.searchcraft-select-input-icon{fill:none;pointer-events:none;position:absolute;right:12px;top:50%;transform:translateY(-50%)}.searchcraft-select-caption{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal)}.searchcraft-search-results-per-page{display:flex}.searchcraft-search-results-per-page-select{align-items:center;display:flex;gap:12px}.searchcraft-search-results-per-page-select-label{font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal)}.searchcraft-search-results-per-page-select-input{min-width:120px}.searchcraft-summary-box{padding:20px;border-radius:var(--sc-border-radius);background-color:var(--sc-surface-neutral-secondary);position:relative;min-height:200px;color:var(--sc-content-neutral-primary);font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-font-size);font-weight:var(--sc-font-normal)}.searchcraft-summary-box h1,.searchcraft-summary-box h2,.searchcraft-summary-box h3,.searchcraft-summary-box h4,.searchcraft-summary-box h5{padding-top:10px;padding-bottom:10px}.searchcraft-summary-box p{padding-bottom:10px}.searchcraft-summary-box img{max-width:200px}.searchcraft-summary-box ol,.searchcraft-summary-box ul{padding-left:1em;padding-bottom:10px}.searchcraft-summary-box a{color:var(--sc-content-brand)}.searchcraft-loading-label{position:absolute;top:50%;left:50%;transform:translateY(-50%) translateX(-50%);margin-top:40px;letter-spacing:2px;color:#828282;font-family:var(--sc-font-family);line-height:1.25;-webkit-font-smoothing:antialiased;font-size:var(--sc-body-small-font-size);font-weight:var(--sc-font-normal)}.searchcraft-loading-bars{margin:0 auto;width:60px;height:50px;text-align:center;position:absolute;top:50%;left:50%;transform:translateY(-50%) translateX(-50%);display:flex;gap:2px}.searchcraft-loading-bars>div{height:100%;width:8px;-webkit-animation:delay .8s infinite ease-in-out;animation:delay .8s infinite ease-in-out;opacity:.2}.searchcraft-loading-bars .searchcraft-loading-bar-1{background-color:var(--sc-surface-brand-primary);opacity:.1}.searchcraft-loading-bars .searchcraft-loading-bar-2{background-color:var(--sc-surface-brand-primary);animation-delay:-0.7s;opacity:.2}.searchcraft-loading-bars .searchcraft-loading-bar-3{background-color:var(--sc-surface-brand-primary);animation-delay:-0.6s;opacity:.3}.searchcraft-loading-bars .searchcraft-loading-bar-4{background-color:var(--sc-surface-brand-primary);animation-delay:-0.5s;opacity:.4}.searchcraft-loading-bars .searchcraft-loading-bar-5{background-color:var(--sc-surface-brand-primary);animation-delay:-0.4s;opacity:.5}.searchcraft-loading-bars .searchcraft-loading-bar-6{background-color:var(--sc-surface-brand-primary);animation-delay:-0.3s;opacity:.6}@keyframes delay{0%,40%,100%{transform:scaleY(0.05)}20%{transform:scaleY(1)}}/*# sourceMappingURL=hologram.css.map */
|
|
9876
10148
|
`;
|
|
9877
10149
|
|
|
9878
10150
|
/**
|
|
@@ -10028,805 +10300,1269 @@ exports.hydrateApp = hydrateApp;
|
|
|
10028
10300
|
hydrateAppClosure($stencilWindow);
|
|
10029
10301
|
}
|
|
10030
10302
|
|
|
10031
|
-
// src/app-data/index.ts
|
|
10032
|
-
var BUILD = {
|
|
10033
|
-
allRenderFn: false,
|
|
10034
|
-
element: true,
|
|
10035
|
-
event: true,
|
|
10036
|
-
hasRenderFn: true,
|
|
10037
|
-
hostListener: true,
|
|
10038
|
-
hostListenerTargetWindow: true,
|
|
10039
|
-
hostListenerTargetDocument: true,
|
|
10040
|
-
hostListenerTargetBody: true,
|
|
10041
|
-
hostListenerTargetParent: false,
|
|
10042
|
-
hostListenerTarget: true,
|
|
10043
|
-
member: true,
|
|
10044
|
-
method: true,
|
|
10045
|
-
mode: true,
|
|
10046
|
-
observeAttribute: true,
|
|
10047
|
-
prop: true,
|
|
10048
|
-
propMutable: true,
|
|
10049
|
-
reflect: true,
|
|
10050
|
-
scoped: true,
|
|
10051
|
-
shadowDom: true,
|
|
10052
|
-
slot: true,
|
|
10053
|
-
cssAnnotations: true,
|
|
10054
|
-
state: true,
|
|
10055
|
-
style: true,
|
|
10056
|
-
formAssociated: false,
|
|
10057
|
-
svg: true,
|
|
10058
|
-
updatable: true,
|
|
10059
|
-
vdomAttribute: true,
|
|
10060
|
-
vdomXlink: true,
|
|
10061
|
-
vdomClass: true,
|
|
10062
|
-
vdomFunctional: true,
|
|
10063
|
-
vdomKey: true,
|
|
10064
|
-
vdomListener: true,
|
|
10065
|
-
vdomRef: true,
|
|
10066
|
-
vdomPropOrAttr: true,
|
|
10067
|
-
vdomRender: true,
|
|
10068
|
-
vdomStyle: true,
|
|
10069
|
-
vdomText: true,
|
|
10070
|
-
propChangeCallback: true,
|
|
10071
|
-
taskQueue: true,
|
|
10072
|
-
hotModuleReplacement: false,
|
|
10073
|
-
isDebug: false,
|
|
10074
|
-
isDev: false,
|
|
10075
|
-
isTesting: false,
|
|
10076
|
-
hydrateServerSide: false,
|
|
10077
|
-
hydrateClientSide: false,
|
|
10078
|
-
lifecycleDOMEvents: false,
|
|
10079
|
-
lazyLoad: false,
|
|
10080
|
-
profile: false,
|
|
10081
|
-
slotRelocation: true,
|
|
10082
|
-
// TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior
|
|
10083
|
-
appendChildSlotFix: false,
|
|
10084
|
-
// TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior
|
|
10085
|
-
cloneNodeFix: false,
|
|
10086
|
-
hydratedAttribute: false,
|
|
10087
|
-
hydratedClass: true,
|
|
10088
|
-
// TODO(STENCIL-1305): remove this option
|
|
10089
|
-
scriptDataOpts: false,
|
|
10090
|
-
// TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior
|
|
10091
|
-
scopedSlotTextContentFix: false,
|
|
10092
|
-
// TODO(STENCIL-854): Remove code related to legacy shadowDomShim field
|
|
10093
|
-
shadowDomShim: false,
|
|
10094
|
-
// TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior
|
|
10095
|
-
slotChildNodesFix: false,
|
|
10096
|
-
invisiblePrehydration: true,
|
|
10097
|
-
propBoolean: true,
|
|
10098
|
-
propNumber: true,
|
|
10099
|
-
propString: true,
|
|
10100
|
-
constructableCSS: true,
|
|
10101
|
-
devTools: false,
|
|
10102
|
-
shadowDelegatesFocus: true,
|
|
10103
|
-
initializeNextTick: false,
|
|
10104
|
-
asyncLoading: true,
|
|
10105
|
-
asyncQueue: false,
|
|
10106
|
-
transformTagName: false,
|
|
10107
|
-
attachStyles: true,
|
|
10108
|
-
// TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior
|
|
10109
|
-
experimentalSlotFixes: false
|
|
10110
|
-
};
|
|
10111
|
-
var Env = {};
|
|
10112
|
-
var NAMESPACE = (
|
|
10113
|
-
/* default */
|
|
10114
|
-
"app"
|
|
10115
|
-
);
|
|
10116
|
-
|
|
10117
10303
|
/*
|
|
10118
|
-
Stencil Hydrate Runner v4.
|
|
10304
|
+
Stencil Hydrate Runner v4.39.0 | MIT Licensed | https://stenciljs.com
|
|
10119
10305
|
*/
|
|
10120
10306
|
var __defProp = Object.defineProperty;
|
|
10121
10307
|
var __export = (target, all) => {
|
|
10122
10308
|
for (var name in all)
|
|
10123
10309
|
__defProp(target, name, { get: all[name], enumerable: true });
|
|
10124
10310
|
};
|
|
10125
|
-
|
|
10126
|
-
|
|
10127
|
-
|
|
10128
|
-
|
|
10129
|
-
|
|
10130
|
-
var TEXT_NODE_ID = "t";
|
|
10131
|
-
var HYDRATE_ID = "s-id";
|
|
10132
|
-
var HYDRATED_STYLE_ID = "sty-id";
|
|
10133
|
-
var STENCIL_DOC_DATA = "_stencilDocData";
|
|
10134
|
-
var XLINK_NS = "http://www.w3.org/1999/xlink";
|
|
10135
|
-
|
|
10136
|
-
// src/mock-doc/attribute.ts
|
|
10137
|
-
var attrHandler = {
|
|
10138
|
-
get(obj, prop) {
|
|
10139
|
-
if (prop in obj) {
|
|
10140
|
-
return obj[prop];
|
|
10141
|
-
}
|
|
10142
|
-
if (typeof prop !== "symbol" && !isNaN(prop)) {
|
|
10143
|
-
return obj.__items[prop];
|
|
10144
|
-
}
|
|
10145
|
-
return void 0;
|
|
10146
|
-
}
|
|
10311
|
+
var Build = {
|
|
10312
|
+
isDev: BUILD.isDev ? true : false,
|
|
10313
|
+
isBrowser: true,
|
|
10314
|
+
isServer: false,
|
|
10315
|
+
isTesting: BUILD.isTesting ? true : false
|
|
10147
10316
|
};
|
|
10148
|
-
|
|
10149
|
-
|
|
10150
|
-
|
|
10151
|
-
|
|
10152
|
-
|
|
10153
|
-
|
|
10154
|
-
|
|
10155
|
-
|
|
10156
|
-
|
|
10157
|
-
|
|
10158
|
-
|
|
10159
|
-
|
|
10160
|
-
|
|
10161
|
-
|
|
10162
|
-
|
|
10317
|
+
|
|
10318
|
+
// src/utils/constants.ts
|
|
10319
|
+
var PrimitiveType = /* @__PURE__ */ ((PrimitiveType2) => {
|
|
10320
|
+
PrimitiveType2["Undefined"] = "undefined";
|
|
10321
|
+
PrimitiveType2["Null"] = "null";
|
|
10322
|
+
PrimitiveType2["String"] = "string";
|
|
10323
|
+
PrimitiveType2["Number"] = "number";
|
|
10324
|
+
PrimitiveType2["SpecialNumber"] = "number";
|
|
10325
|
+
PrimitiveType2["Boolean"] = "boolean";
|
|
10326
|
+
PrimitiveType2["BigInt"] = "bigint";
|
|
10327
|
+
return PrimitiveType2;
|
|
10328
|
+
})(PrimitiveType || {});
|
|
10329
|
+
var NonPrimitiveType = /* @__PURE__ */ ((NonPrimitiveType2) => {
|
|
10330
|
+
NonPrimitiveType2["Array"] = "array";
|
|
10331
|
+
NonPrimitiveType2["Date"] = "date";
|
|
10332
|
+
NonPrimitiveType2["Map"] = "map";
|
|
10333
|
+
NonPrimitiveType2["Object"] = "object";
|
|
10334
|
+
NonPrimitiveType2["RegularExpression"] = "regexp";
|
|
10335
|
+
NonPrimitiveType2["Set"] = "set";
|
|
10336
|
+
NonPrimitiveType2["Channel"] = "channel";
|
|
10337
|
+
NonPrimitiveType2["Symbol"] = "symbol";
|
|
10338
|
+
return NonPrimitiveType2;
|
|
10339
|
+
})(NonPrimitiveType || {});
|
|
10340
|
+
var TYPE_CONSTANT = "type";
|
|
10341
|
+
var VALUE_CONSTANT = "value";
|
|
10342
|
+
var SERIALIZED_PREFIX = "serialized:";
|
|
10343
|
+
var STENCIL_DEV_MODE = BUILD.isTesting ? ["STENCIL:"] : [
|
|
10344
|
+
"%cstencil",
|
|
10345
|
+
"color: white;background:#4c47ff;font-weight: bold; font-size:10px; padding:2px 6px; border-radius: 5px"
|
|
10346
|
+
];
|
|
10347
|
+
|
|
10348
|
+
// src/runtime/runtime-constants.ts
|
|
10349
|
+
var CONTENT_REF_ID = "r";
|
|
10350
|
+
var ORG_LOCATION_ID = "o";
|
|
10351
|
+
var SLOT_NODE_ID = "s";
|
|
10352
|
+
var TEXT_NODE_ID = "t";
|
|
10353
|
+
var HYDRATE_ID = "s-id";
|
|
10354
|
+
var HYDRATED_STYLE_ID = "sty-id";
|
|
10355
|
+
var STENCIL_DOC_DATA = "_stencilDocData";
|
|
10356
|
+
var XLINK_NS = "http://www.w3.org/1999/xlink";
|
|
10357
|
+
var win = typeof window !== "undefined" ? window : {};
|
|
10358
|
+
var H = win.HTMLElement || class {
|
|
10359
|
+
};
|
|
10360
|
+
var supportsShadow = BUILD.shadowDom;
|
|
10361
|
+
var supportsConstructableStylesheets = BUILD.constructableCSS ? /* @__PURE__ */ (() => {
|
|
10362
|
+
try {
|
|
10363
|
+
new CSSStyleSheet();
|
|
10364
|
+
return typeof new CSSStyleSheet().replaceSync === "function";
|
|
10365
|
+
} catch (e) {
|
|
10163
10366
|
}
|
|
10164
|
-
|
|
10165
|
-
|
|
10166
|
-
|
|
10167
|
-
|
|
10168
|
-
|
|
10169
|
-
|
|
10170
|
-
|
|
10367
|
+
return false;
|
|
10368
|
+
})() : false;
|
|
10369
|
+
|
|
10370
|
+
// src/utils/helpers.ts
|
|
10371
|
+
var isString = (v) => typeof v === "string";
|
|
10372
|
+
|
|
10373
|
+
// src/utils/local-value.ts
|
|
10374
|
+
var LocalValue = class _LocalValue {
|
|
10375
|
+
constructor(type, value) {
|
|
10376
|
+
if (type === "undefined" /* Undefined */ || type === "null" /* Null */) {
|
|
10377
|
+
this.type = type;
|
|
10171
10378
|
} else {
|
|
10172
|
-
this.
|
|
10173
|
-
|
|
10174
|
-
}
|
|
10175
|
-
getNamedItem(attrName) {
|
|
10176
|
-
if (this.caseInsensitive) {
|
|
10177
|
-
attrName = attrName.toLowerCase();
|
|
10379
|
+
this.type = type;
|
|
10380
|
+
this.value = value;
|
|
10178
10381
|
}
|
|
10179
|
-
return this.getNamedItemNS(null, attrName);
|
|
10180
10382
|
}
|
|
10181
|
-
|
|
10182
|
-
|
|
10183
|
-
|
|
10383
|
+
/**
|
|
10384
|
+
* Creates a new LocalValue object with a string value.
|
|
10385
|
+
*
|
|
10386
|
+
* @param {string} value - The string value to be stored in the LocalValue object.
|
|
10387
|
+
* @returns {LocalValue} - The created LocalValue object.
|
|
10388
|
+
*/
|
|
10389
|
+
static createStringValue(value) {
|
|
10390
|
+
return new _LocalValue("string" /* String */, value);
|
|
10184
10391
|
}
|
|
10185
|
-
|
|
10186
|
-
|
|
10392
|
+
/**
|
|
10393
|
+
* Creates a new LocalValue object with a number value.
|
|
10394
|
+
*
|
|
10395
|
+
* @param {number} value - The number value.
|
|
10396
|
+
* @returns {LocalValue} - The created LocalValue object.
|
|
10397
|
+
*/
|
|
10398
|
+
static createNumberValue(value) {
|
|
10399
|
+
return new _LocalValue("number" /* Number */, value);
|
|
10187
10400
|
}
|
|
10188
|
-
|
|
10189
|
-
|
|
10190
|
-
|
|
10191
|
-
|
|
10192
|
-
|
|
10193
|
-
|
|
10401
|
+
/**
|
|
10402
|
+
* Creates a new LocalValue object with a special number value.
|
|
10403
|
+
*
|
|
10404
|
+
* @param {number} value - The value of the special number.
|
|
10405
|
+
* @returns {LocalValue} - The created LocalValue object.
|
|
10406
|
+
*/
|
|
10407
|
+
static createSpecialNumberValue(value) {
|
|
10408
|
+
if (Number.isNaN(value)) {
|
|
10409
|
+
return new _LocalValue("number" /* SpecialNumber */, "NaN");
|
|
10194
10410
|
}
|
|
10195
|
-
|
|
10196
|
-
|
|
10197
|
-
let i = 0;
|
|
10198
|
-
return {
|
|
10199
|
-
next: () => ({
|
|
10200
|
-
done: i === this.length,
|
|
10201
|
-
value: this.item(i++)
|
|
10202
|
-
})
|
|
10203
|
-
};
|
|
10204
|
-
}
|
|
10205
|
-
get [Symbol.toStringTag]() {
|
|
10206
|
-
return "MockAttributeMap";
|
|
10207
|
-
}
|
|
10208
|
-
};
|
|
10209
|
-
function getNamespaceURI(namespaceURI) {
|
|
10210
|
-
return namespaceURI === XLINK_NS ? null : namespaceURI;
|
|
10211
|
-
}
|
|
10212
|
-
function cloneAttributes(srcAttrs, sortByName = false) {
|
|
10213
|
-
const dstAttrs = new MockAttributeMap(srcAttrs.caseInsensitive);
|
|
10214
|
-
if (srcAttrs != null) {
|
|
10215
|
-
const attrLen = srcAttrs.length;
|
|
10216
|
-
if (sortByName && attrLen > 1) {
|
|
10217
|
-
const sortedAttrs = [];
|
|
10218
|
-
for (let i = 0; i < attrLen; i++) {
|
|
10219
|
-
const srcAttr = srcAttrs.item(i);
|
|
10220
|
-
const dstAttr = new MockAttr(srcAttr.name, srcAttr.value, srcAttr.namespaceURI);
|
|
10221
|
-
sortedAttrs.push(dstAttr);
|
|
10222
|
-
}
|
|
10223
|
-
sortedAttrs.sort(sortAttributes).forEach((attr) => {
|
|
10224
|
-
dstAttrs.setNamedItemNS(attr);
|
|
10225
|
-
});
|
|
10226
|
-
} else {
|
|
10227
|
-
for (let i = 0; i < attrLen; i++) {
|
|
10228
|
-
const srcAttr = srcAttrs.item(i);
|
|
10229
|
-
const dstAttr = new MockAttr(srcAttr.name, srcAttr.value, srcAttr.namespaceURI);
|
|
10230
|
-
dstAttrs.setNamedItemNS(dstAttr);
|
|
10231
|
-
}
|
|
10411
|
+
if (Object.is(value, -0)) {
|
|
10412
|
+
return new _LocalValue("number" /* SpecialNumber */, "-0");
|
|
10232
10413
|
}
|
|
10414
|
+
if (value === Infinity) {
|
|
10415
|
+
return new _LocalValue("number" /* SpecialNumber */, "Infinity");
|
|
10416
|
+
}
|
|
10417
|
+
if (value === -Infinity) {
|
|
10418
|
+
return new _LocalValue("number" /* SpecialNumber */, "-Infinity");
|
|
10419
|
+
}
|
|
10420
|
+
return new _LocalValue("number" /* SpecialNumber */, value);
|
|
10233
10421
|
}
|
|
10234
|
-
|
|
10235
|
-
|
|
10236
|
-
|
|
10237
|
-
|
|
10238
|
-
|
|
10239
|
-
|
|
10240
|
-
}
|
|
10241
|
-
var MockAttr = class {
|
|
10242
|
-
constructor(attrName, attrValue, namespaceURI = null) {
|
|
10243
|
-
this._name = attrName;
|
|
10244
|
-
this._value = String(attrValue);
|
|
10245
|
-
this._namespaceURI = namespaceURI;
|
|
10246
|
-
}
|
|
10247
|
-
get name() {
|
|
10248
|
-
return this._name;
|
|
10249
|
-
}
|
|
10250
|
-
set name(value) {
|
|
10251
|
-
this._name = value;
|
|
10252
|
-
}
|
|
10253
|
-
get value() {
|
|
10254
|
-
return this._value;
|
|
10422
|
+
/**
|
|
10423
|
+
* Creates a new LocalValue object with an undefined value.
|
|
10424
|
+
* @returns {LocalValue} - The created LocalValue object.
|
|
10425
|
+
*/
|
|
10426
|
+
static createUndefinedValue() {
|
|
10427
|
+
return new _LocalValue("undefined" /* Undefined */);
|
|
10255
10428
|
}
|
|
10256
|
-
|
|
10257
|
-
|
|
10429
|
+
/**
|
|
10430
|
+
* Creates a new LocalValue object with a null value.
|
|
10431
|
+
* @returns {LocalValue} - The created LocalValue object.
|
|
10432
|
+
*/
|
|
10433
|
+
static createNullValue() {
|
|
10434
|
+
return new _LocalValue("null" /* Null */);
|
|
10258
10435
|
}
|
|
10259
|
-
|
|
10260
|
-
|
|
10436
|
+
/**
|
|
10437
|
+
* Creates a new LocalValue object with a boolean value.
|
|
10438
|
+
*
|
|
10439
|
+
* @param {boolean} value - The boolean value.
|
|
10440
|
+
* @returns {LocalValue} - The created LocalValue object.
|
|
10441
|
+
*/
|
|
10442
|
+
static createBooleanValue(value) {
|
|
10443
|
+
return new _LocalValue("boolean" /* Boolean */, value);
|
|
10261
10444
|
}
|
|
10262
|
-
|
|
10263
|
-
|
|
10445
|
+
/**
|
|
10446
|
+
* Creates a new LocalValue object with a BigInt value.
|
|
10447
|
+
*
|
|
10448
|
+
* @param {BigInt} value - The BigInt value.
|
|
10449
|
+
* @returns {LocalValue} - The created LocalValue object.
|
|
10450
|
+
*/
|
|
10451
|
+
static createBigIntValue(value) {
|
|
10452
|
+
return new _LocalValue("bigint" /* BigInt */, value.toString());
|
|
10264
10453
|
}
|
|
10265
|
-
|
|
10266
|
-
|
|
10454
|
+
/**
|
|
10455
|
+
* Creates a new LocalValue object with an array.
|
|
10456
|
+
*
|
|
10457
|
+
* @param {Array} value - The array.
|
|
10458
|
+
* @returns {LocalValue} - The created LocalValue object.
|
|
10459
|
+
*/
|
|
10460
|
+
static createArrayValue(value) {
|
|
10461
|
+
return new _LocalValue("array" /* Array */, value);
|
|
10267
10462
|
}
|
|
10268
|
-
|
|
10269
|
-
|
|
10463
|
+
/**
|
|
10464
|
+
* Creates a new LocalValue object with date value.
|
|
10465
|
+
*
|
|
10466
|
+
* @param {string} value - The date.
|
|
10467
|
+
* @returns {LocalValue} - The created LocalValue object.
|
|
10468
|
+
*/
|
|
10469
|
+
static createDateValue(value) {
|
|
10470
|
+
return new _LocalValue("date" /* Date */, value);
|
|
10270
10471
|
}
|
|
10271
|
-
|
|
10272
|
-
|
|
10472
|
+
/**
|
|
10473
|
+
* Creates a new LocalValue object of map value.
|
|
10474
|
+
* @param {Map} map - The map.
|
|
10475
|
+
* @returns {LocalValue} - The created LocalValue object.
|
|
10476
|
+
*/
|
|
10477
|
+
static createMapValue(map2) {
|
|
10478
|
+
const value = [];
|
|
10479
|
+
Array.from(map2.entries()).forEach(([key, val]) => {
|
|
10480
|
+
value.push([_LocalValue.getArgument(key), _LocalValue.getArgument(val)]);
|
|
10481
|
+
});
|
|
10482
|
+
return new _LocalValue("map" /* Map */, value);
|
|
10273
10483
|
}
|
|
10274
|
-
|
|
10275
|
-
|
|
10276
|
-
|
|
10277
|
-
|
|
10278
|
-
|
|
10279
|
-
|
|
10280
|
-
|
|
10281
|
-
|
|
10282
|
-
|
|
10283
|
-
|
|
10284
|
-
|
|
10285
|
-
|
|
10286
|
-
if (value == null || value === "") {
|
|
10287
|
-
this._styles.delete(prop);
|
|
10288
|
-
} else {
|
|
10289
|
-
this._styles.set(prop, String(value));
|
|
10290
|
-
}
|
|
10484
|
+
/**
|
|
10485
|
+
* Creates a new LocalValue object from the passed object.
|
|
10486
|
+
*
|
|
10487
|
+
* @param object the object to create a LocalValue from
|
|
10488
|
+
* @returns {LocalValue} - The created LocalValue object.
|
|
10489
|
+
*/
|
|
10490
|
+
static createObjectValue(object) {
|
|
10491
|
+
const value = [];
|
|
10492
|
+
Object.entries(object).forEach(([key, val]) => {
|
|
10493
|
+
value.push([key, _LocalValue.getArgument(val)]);
|
|
10494
|
+
});
|
|
10495
|
+
return new _LocalValue("object" /* Object */, value);
|
|
10291
10496
|
}
|
|
10292
|
-
|
|
10293
|
-
|
|
10294
|
-
|
|
10497
|
+
/**
|
|
10498
|
+
* Creates a new LocalValue object of regular expression value.
|
|
10499
|
+
*
|
|
10500
|
+
* @param {string} value - The value of the regular expression.
|
|
10501
|
+
* @returns {LocalValue} - The created LocalValue object.
|
|
10502
|
+
*/
|
|
10503
|
+
static createRegularExpressionValue(value) {
|
|
10504
|
+
return new _LocalValue("regexp" /* RegularExpression */, value);
|
|
10295
10505
|
}
|
|
10296
|
-
|
|
10297
|
-
|
|
10298
|
-
|
|
10506
|
+
/**
|
|
10507
|
+
* Creates a new LocalValue object with the specified value.
|
|
10508
|
+
* @param {Set} value - The value to be set.
|
|
10509
|
+
* @returns {LocalValue} - The created LocalValue object.
|
|
10510
|
+
*/
|
|
10511
|
+
static createSetValue(value) {
|
|
10512
|
+
return new _LocalValue("set" /* Set */, value);
|
|
10299
10513
|
}
|
|
10300
|
-
|
|
10301
|
-
|
|
10514
|
+
/**
|
|
10515
|
+
* Creates a new LocalValue object with the given channel value
|
|
10516
|
+
*
|
|
10517
|
+
* @param {ChannelValue} value - The channel value.
|
|
10518
|
+
* @returns {LocalValue} - The created LocalValue object.
|
|
10519
|
+
*/
|
|
10520
|
+
static createChannelValue(value) {
|
|
10521
|
+
return new _LocalValue("channel" /* Channel */, value);
|
|
10302
10522
|
}
|
|
10303
|
-
|
|
10304
|
-
|
|
10305
|
-
|
|
10306
|
-
|
|
10307
|
-
|
|
10308
|
-
|
|
10523
|
+
/**
|
|
10524
|
+
* Creates a new LocalValue object with a Symbol value.
|
|
10525
|
+
*
|
|
10526
|
+
* @param {Symbol} symbol - The Symbol value
|
|
10527
|
+
* @returns {LocalValue} - The created LocalValue object
|
|
10528
|
+
*/
|
|
10529
|
+
static createSymbolValue(symbol) {
|
|
10530
|
+
const description = symbol.description || "Symbol()";
|
|
10531
|
+
return new _LocalValue("symbol" /* Symbol */, description);
|
|
10309
10532
|
}
|
|
10310
|
-
|
|
10311
|
-
|
|
10312
|
-
|
|
10313
|
-
|
|
10314
|
-
|
|
10315
|
-
|
|
10316
|
-
|
|
10317
|
-
|
|
10318
|
-
const splt = rule.split(":");
|
|
10319
|
-
if (splt.length > 1) {
|
|
10320
|
-
const prop = splt[0].trim();
|
|
10321
|
-
const value = splt.slice(1).join(":").trim();
|
|
10322
|
-
if (prop !== "" && value !== "") {
|
|
10323
|
-
this._styles.set(jsCaseToCssCase(prop), value);
|
|
10324
|
-
}
|
|
10533
|
+
static getArgument(argument) {
|
|
10534
|
+
const type = typeof argument;
|
|
10535
|
+
switch (type) {
|
|
10536
|
+
case "string" /* String */:
|
|
10537
|
+
return _LocalValue.createStringValue(argument);
|
|
10538
|
+
case "number" /* Number */:
|
|
10539
|
+
if (Number.isNaN(argument) || Object.is(argument, -0) || !Number.isFinite(argument)) {
|
|
10540
|
+
return _LocalValue.createSpecialNumberValue(argument);
|
|
10325
10541
|
}
|
|
10326
|
-
|
|
10327
|
-
|
|
10328
|
-
|
|
10329
|
-
|
|
10330
|
-
|
|
10331
|
-
|
|
10332
|
-
|
|
10333
|
-
|
|
10334
|
-
|
|
10335
|
-
|
|
10336
|
-
|
|
10337
|
-
|
|
10338
|
-
|
|
10339
|
-
|
|
10340
|
-
|
|
10341
|
-
|
|
10342
|
-
|
|
10343
|
-
|
|
10344
|
-
|
|
10345
|
-
|
|
10542
|
+
return _LocalValue.createNumberValue(argument);
|
|
10543
|
+
case "boolean" /* Boolean */:
|
|
10544
|
+
return _LocalValue.createBooleanValue(argument);
|
|
10545
|
+
case "bigint" /* BigInt */:
|
|
10546
|
+
return _LocalValue.createBigIntValue(argument);
|
|
10547
|
+
case "undefined" /* Undefined */:
|
|
10548
|
+
return _LocalValue.createUndefinedValue();
|
|
10549
|
+
case "symbol" /* Symbol */:
|
|
10550
|
+
return _LocalValue.createSymbolValue(argument);
|
|
10551
|
+
case "object" /* Object */:
|
|
10552
|
+
if (argument === null) {
|
|
10553
|
+
return _LocalValue.createNullValue();
|
|
10554
|
+
}
|
|
10555
|
+
if (argument instanceof Date) {
|
|
10556
|
+
return _LocalValue.createDateValue(argument);
|
|
10557
|
+
}
|
|
10558
|
+
if (argument instanceof Map) {
|
|
10559
|
+
const map2 = [];
|
|
10560
|
+
argument.forEach((value, key) => {
|
|
10561
|
+
const objectKey = typeof key === "string" ? key : _LocalValue.getArgument(key);
|
|
10562
|
+
const objectValue = _LocalValue.getArgument(value);
|
|
10563
|
+
map2.push([objectKey, objectValue]);
|
|
10564
|
+
});
|
|
10565
|
+
return _LocalValue.createMapValue(argument);
|
|
10566
|
+
}
|
|
10567
|
+
if (argument instanceof Set) {
|
|
10568
|
+
const set = [];
|
|
10569
|
+
argument.forEach((value) => {
|
|
10570
|
+
set.push(_LocalValue.getArgument(value));
|
|
10571
|
+
});
|
|
10572
|
+
return _LocalValue.createSetValue(set);
|
|
10573
|
+
}
|
|
10574
|
+
if (argument instanceof Array) {
|
|
10575
|
+
const arr = [];
|
|
10576
|
+
argument.forEach((value) => {
|
|
10577
|
+
arr.push(_LocalValue.getArgument(value));
|
|
10578
|
+
});
|
|
10579
|
+
return _LocalValue.createArrayValue(arr);
|
|
10580
|
+
}
|
|
10581
|
+
if (argument instanceof RegExp) {
|
|
10582
|
+
return _LocalValue.createRegularExpressionValue({
|
|
10583
|
+
pattern: argument.source,
|
|
10584
|
+
flags: argument.flags
|
|
10585
|
+
});
|
|
10586
|
+
}
|
|
10587
|
+
return _LocalValue.createObjectValue(argument);
|
|
10346
10588
|
}
|
|
10347
|
-
|
|
10348
|
-
}
|
|
10349
|
-
};
|
|
10350
|
-
function cssCaseToJsCase(str) {
|
|
10351
|
-
if (str.length > 1 && str.includes("-") === true) {
|
|
10352
|
-
str = str.toLowerCase().split("-").map((segment) => segment.charAt(0).toUpperCase() + segment.slice(1)).join("");
|
|
10353
|
-
str = str.slice(0, 1).toLowerCase() + str.slice(1);
|
|
10589
|
+
throw new Error(`Unsupported type: ${type}`);
|
|
10354
10590
|
}
|
|
10355
|
-
|
|
10356
|
-
|
|
10357
|
-
|
|
10358
|
-
|
|
10359
|
-
|
|
10591
|
+
asMap() {
|
|
10592
|
+
return {
|
|
10593
|
+
[TYPE_CONSTANT]: this.type,
|
|
10594
|
+
...!(this.type === "null" /* Null */ || this.type === "undefined" /* Undefined */) ? { [VALUE_CONSTANT]: this.value } : {}
|
|
10595
|
+
};
|
|
10360
10596
|
}
|
|
10361
|
-
|
|
10362
|
-
}
|
|
10597
|
+
};
|
|
10363
10598
|
|
|
10364
|
-
// src/
|
|
10365
|
-
var
|
|
10366
|
-
|
|
10367
|
-
|
|
10368
|
-
|
|
10369
|
-
|
|
10370
|
-
|
|
10371
|
-
|
|
10372
|
-
|
|
10373
|
-
|
|
10374
|
-
|
|
10375
|
-
|
|
10376
|
-
|
|
10377
|
-
|
|
10378
|
-
|
|
10379
|
-
|
|
10380
|
-
|
|
10381
|
-
|
|
10382
|
-
|
|
10383
|
-
whenDefinedResolveFn();
|
|
10384
|
-
});
|
|
10385
|
-
whenDefinedResolveFns.length = 0;
|
|
10386
|
-
this.__whenDefined.delete(tagName);
|
|
10599
|
+
// src/utils/message-utils.ts
|
|
10600
|
+
var catchError = (diagnostics, err2, msg) => {
|
|
10601
|
+
const diagnostic = {
|
|
10602
|
+
level: "error",
|
|
10603
|
+
type: "build",
|
|
10604
|
+
header: "Build Error",
|
|
10605
|
+
messageText: "build error",
|
|
10606
|
+
lines: []
|
|
10607
|
+
};
|
|
10608
|
+
if (isString(msg)) {
|
|
10609
|
+
diagnostic.messageText = msg.length ? msg : "UNKNOWN ERROR";
|
|
10610
|
+
} else if (err2 != null) {
|
|
10611
|
+
if (err2.stack != null) {
|
|
10612
|
+
diagnostic.messageText = err2.stack.toString();
|
|
10613
|
+
} else {
|
|
10614
|
+
if (err2.message != null) {
|
|
10615
|
+
diagnostic.messageText = err2.message.length ? err2.message : "UNKNOWN ERROR";
|
|
10616
|
+
} else {
|
|
10617
|
+
diagnostic.messageText = err2.toString();
|
|
10387
10618
|
}
|
|
10388
10619
|
}
|
|
10389
|
-
const doc = this.win.document;
|
|
10390
|
-
if (doc != null) {
|
|
10391
|
-
const hosts = doc.querySelectorAll(tagName);
|
|
10392
|
-
hosts.forEach((host) => {
|
|
10393
|
-
if (upgradedElements.has(host) === false) {
|
|
10394
|
-
tempDisableCallbacks.add(doc);
|
|
10395
|
-
const upgradedCmp = createCustomElement(this, doc, tagName);
|
|
10396
|
-
for (let i = 0; i < host.childNodes.length; i++) {
|
|
10397
|
-
const childNode = host.childNodes[i];
|
|
10398
|
-
childNode.remove();
|
|
10399
|
-
upgradedCmp.appendChild(childNode);
|
|
10400
|
-
}
|
|
10401
|
-
tempDisableCallbacks.delete(doc);
|
|
10402
|
-
if (proxyElements.has(host)) {
|
|
10403
|
-
proxyElements.set(host, upgradedCmp);
|
|
10404
|
-
}
|
|
10405
|
-
}
|
|
10406
|
-
fireConnectedCallback(host);
|
|
10407
|
-
});
|
|
10408
|
-
}
|
|
10409
10620
|
}
|
|
10410
|
-
|
|
10411
|
-
|
|
10412
|
-
const def = this.__registry.get(tagName.toLowerCase());
|
|
10413
|
-
if (def != null) {
|
|
10414
|
-
return def.cstr;
|
|
10415
|
-
}
|
|
10416
|
-
}
|
|
10417
|
-
return void 0;
|
|
10621
|
+
if (diagnostics != null && !shouldIgnoreError(diagnostic.messageText)) {
|
|
10622
|
+
diagnostics.push(diagnostic);
|
|
10418
10623
|
}
|
|
10419
|
-
|
|
10420
|
-
|
|
10421
|
-
|
|
10422
|
-
|
|
10423
|
-
|
|
10624
|
+
return diagnostic;
|
|
10625
|
+
};
|
|
10626
|
+
var hasError = (diagnostics) => {
|
|
10627
|
+
if (diagnostics == null || diagnostics.length === 0) {
|
|
10628
|
+
return false;
|
|
10629
|
+
}
|
|
10630
|
+
return diagnostics.some((d) => d.level === "error" && d.type !== "runtime");
|
|
10631
|
+
};
|
|
10632
|
+
var shouldIgnoreError = (msg) => {
|
|
10633
|
+
return msg === TASK_CANCELED_MSG;
|
|
10634
|
+
};
|
|
10635
|
+
var TASK_CANCELED_MSG = `task canceled`;
|
|
10636
|
+
|
|
10637
|
+
// src/utils/regular-expression.ts
|
|
10638
|
+
var escapeRegExpSpecialCharacters = (text) => {
|
|
10639
|
+
return text.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
10640
|
+
};
|
|
10641
|
+
|
|
10642
|
+
// src/utils/remote-value.ts
|
|
10643
|
+
var RemoteValue = class _RemoteValue {
|
|
10644
|
+
/**
|
|
10645
|
+
* Deserializes a LocalValue serialized object back to its original JavaScript representation
|
|
10646
|
+
*
|
|
10647
|
+
* @param serialized The serialized LocalValue object
|
|
10648
|
+
* @returns The original JavaScript value/object
|
|
10649
|
+
*/
|
|
10650
|
+
static fromLocalValue(serialized) {
|
|
10651
|
+
const type = serialized[TYPE_CONSTANT];
|
|
10652
|
+
const value = VALUE_CONSTANT in serialized ? serialized[VALUE_CONSTANT] : void 0;
|
|
10653
|
+
switch (type) {
|
|
10654
|
+
case "string" /* String */:
|
|
10655
|
+
return value;
|
|
10656
|
+
case "boolean" /* Boolean */:
|
|
10657
|
+
return value;
|
|
10658
|
+
case "bigint" /* BigInt */:
|
|
10659
|
+
return BigInt(value);
|
|
10660
|
+
case "undefined" /* Undefined */:
|
|
10661
|
+
return void 0;
|
|
10662
|
+
case "null" /* Null */:
|
|
10663
|
+
return null;
|
|
10664
|
+
case "number" /* Number */:
|
|
10665
|
+
if (value === "NaN") return NaN;
|
|
10666
|
+
if (value === "-0") return -0;
|
|
10667
|
+
if (value === "Infinity") return Infinity;
|
|
10668
|
+
if (value === "-Infinity") return -Infinity;
|
|
10669
|
+
return value;
|
|
10670
|
+
case "array" /* Array */:
|
|
10671
|
+
return value.map((item) => _RemoteValue.fromLocalValue(item));
|
|
10672
|
+
case "date" /* Date */:
|
|
10673
|
+
return new Date(value);
|
|
10674
|
+
case "map" /* Map */:
|
|
10675
|
+
const map2 = /* @__PURE__ */ new Map();
|
|
10676
|
+
for (const [key, val] of value) {
|
|
10677
|
+
const deserializedKey = typeof key === "object" && key !== null ? _RemoteValue.fromLocalValue(key) : key;
|
|
10678
|
+
const deserializedValue = _RemoteValue.fromLocalValue(val);
|
|
10679
|
+
map2.set(deserializedKey, deserializedValue);
|
|
10680
|
+
}
|
|
10681
|
+
return map2;
|
|
10682
|
+
case "object" /* Object */:
|
|
10683
|
+
const obj = {};
|
|
10684
|
+
for (const [key, val] of value) {
|
|
10685
|
+
obj[key] = _RemoteValue.fromLocalValue(val);
|
|
10686
|
+
}
|
|
10687
|
+
return obj;
|
|
10688
|
+
case "regexp" /* RegularExpression */:
|
|
10689
|
+
const { pattern, flags } = value;
|
|
10690
|
+
return new RegExp(pattern, flags);
|
|
10691
|
+
case "set" /* Set */:
|
|
10692
|
+
const set = /* @__PURE__ */ new Set();
|
|
10693
|
+
for (const item of value) {
|
|
10694
|
+
set.add(_RemoteValue.fromLocalValue(item));
|
|
10695
|
+
}
|
|
10696
|
+
return set;
|
|
10697
|
+
case "symbol" /* Symbol */:
|
|
10698
|
+
return Symbol(value);
|
|
10699
|
+
default:
|
|
10700
|
+
throw new Error(`Unsupported type: ${type}`);
|
|
10424
10701
|
}
|
|
10425
|
-
return void 0;
|
|
10426
10702
|
}
|
|
10427
|
-
|
|
10703
|
+
/**
|
|
10704
|
+
* Utility method to deserialize multiple LocalValues at once
|
|
10705
|
+
*
|
|
10706
|
+
* @param serializedValues Array of serialized LocalValue objects
|
|
10707
|
+
* @returns Array of deserialized JavaScript values
|
|
10708
|
+
*/
|
|
10709
|
+
static fromLocalValueArray(serializedValues) {
|
|
10710
|
+
return serializedValues.map((value) => _RemoteValue.fromLocalValue(value));
|
|
10428
10711
|
}
|
|
10429
|
-
|
|
10430
|
-
|
|
10431
|
-
|
|
10712
|
+
/**
|
|
10713
|
+
* Verifies if the given object matches the structure of a serialized LocalValue
|
|
10714
|
+
*
|
|
10715
|
+
* @param obj Object to verify
|
|
10716
|
+
* @returns boolean indicating if the object has LocalValue structure
|
|
10717
|
+
*/
|
|
10718
|
+
static isLocalValueObject(obj) {
|
|
10719
|
+
if (typeof obj !== "object" || obj === null) {
|
|
10720
|
+
return false;
|
|
10432
10721
|
}
|
|
10433
|
-
if (
|
|
10434
|
-
|
|
10722
|
+
if (!obj.hasOwnProperty(TYPE_CONSTANT)) {
|
|
10723
|
+
return false;
|
|
10435
10724
|
}
|
|
10436
|
-
|
|
10437
|
-
|
|
10438
|
-
|
|
10439
|
-
|
|
10440
|
-
return Promise.resolve(this.__registry.get(tagName).cstr);
|
|
10725
|
+
const type = obj[TYPE_CONSTANT];
|
|
10726
|
+
const hasTypeProperty = Object.values({ ...PrimitiveType, ...NonPrimitiveType }).includes(type);
|
|
10727
|
+
if (!hasTypeProperty) {
|
|
10728
|
+
return false;
|
|
10441
10729
|
}
|
|
10442
|
-
|
|
10443
|
-
|
|
10444
|
-
|
|
10445
|
-
|
|
10446
|
-
let whenDefinedResolveFns = this.__whenDefined.get(tagName);
|
|
10447
|
-
if (whenDefinedResolveFns == null) {
|
|
10448
|
-
whenDefinedResolveFns = [];
|
|
10449
|
-
this.__whenDefined.set(tagName, whenDefinedResolveFns);
|
|
10450
|
-
}
|
|
10451
|
-
whenDefinedResolveFns.push(resolve);
|
|
10452
|
-
});
|
|
10730
|
+
if (type !== "null" /* Null */ && type !== "undefined" /* Undefined */) {
|
|
10731
|
+
return obj.hasOwnProperty(VALUE_CONSTANT);
|
|
10732
|
+
}
|
|
10733
|
+
return true;
|
|
10453
10734
|
}
|
|
10454
10735
|
};
|
|
10455
|
-
|
|
10456
|
-
|
|
10457
|
-
|
|
10458
|
-
|
|
10459
|
-
|
|
10460
|
-
|
|
10461
|
-
|
|
10462
|
-
|
|
10463
|
-
|
|
10464
|
-
|
|
10465
|
-
|
|
10466
|
-
|
|
10467
|
-
|
|
10468
|
-
|
|
10469
|
-
|
|
10470
|
-
|
|
10471
|
-
|
|
10472
|
-
|
|
10473
|
-
|
|
10474
|
-
|
|
10475
|
-
|
|
10476
|
-
|
|
10477
|
-
|
|
10478
|
-
|
|
10479
|
-
|
|
10480
|
-
|
|
10481
|
-
|
|
10482
|
-
has(obj, prop) {
|
|
10483
|
-
const elm2 = proxyElements.get(host);
|
|
10484
|
-
if (prop in elm2) {
|
|
10485
|
-
return true;
|
|
10486
|
-
}
|
|
10487
|
-
if (prop in obj) {
|
|
10488
|
-
return true;
|
|
10489
|
-
}
|
|
10490
|
-
return false;
|
|
10491
|
-
}
|
|
10736
|
+
|
|
10737
|
+
// src/utils/result.ts
|
|
10738
|
+
var result_exports = {};
|
|
10739
|
+
__export(result_exports, {
|
|
10740
|
+
err: () => err,
|
|
10741
|
+
map: () => map,
|
|
10742
|
+
ok: () => ok,
|
|
10743
|
+
unwrap: () => unwrap,
|
|
10744
|
+
unwrapErr: () => unwrapErr
|
|
10745
|
+
});
|
|
10746
|
+
var ok = (value) => ({
|
|
10747
|
+
isOk: true,
|
|
10748
|
+
isErr: false,
|
|
10749
|
+
value
|
|
10750
|
+
});
|
|
10751
|
+
var err = (value) => ({
|
|
10752
|
+
isOk: false,
|
|
10753
|
+
isErr: true,
|
|
10754
|
+
value
|
|
10755
|
+
});
|
|
10756
|
+
function map(result, fn) {
|
|
10757
|
+
if (result.isOk) {
|
|
10758
|
+
const val = fn(result.value);
|
|
10759
|
+
if (val instanceof Promise) {
|
|
10760
|
+
return val.then((newVal) => ok(newVal));
|
|
10761
|
+
} else {
|
|
10762
|
+
return ok(val);
|
|
10492
10763
|
}
|
|
10493
|
-
|
|
10494
|
-
|
|
10495
|
-
|
|
10496
|
-
|
|
10764
|
+
}
|
|
10765
|
+
if (result.isErr) {
|
|
10766
|
+
const value = result.value;
|
|
10767
|
+
return err(value);
|
|
10768
|
+
}
|
|
10769
|
+
throw "should never get here";
|
|
10497
10770
|
}
|
|
10498
|
-
var
|
|
10499
|
-
|
|
10500
|
-
|
|
10501
|
-
node.ownerDocument = ownerDocument;
|
|
10502
|
-
if (node.nodeType === 1 /* ELEMENT_NODE */) {
|
|
10503
|
-
if (ownerDocument != null && node.nodeName.includes("-")) {
|
|
10504
|
-
const win2 = ownerDocument.defaultView;
|
|
10505
|
-
if (win2 != null && typeof node.connectedCallback === "function" && node.isConnected) {
|
|
10506
|
-
fireConnectedCallback(node);
|
|
10507
|
-
}
|
|
10508
|
-
const shadowRoot = node.shadowRoot;
|
|
10509
|
-
if (shadowRoot != null) {
|
|
10510
|
-
shadowRoot.childNodes.forEach((childNode) => {
|
|
10511
|
-
connectNode(ownerDocument, childNode);
|
|
10512
|
-
});
|
|
10513
|
-
}
|
|
10514
|
-
}
|
|
10515
|
-
node.childNodes.forEach((childNode) => {
|
|
10516
|
-
connectNode(ownerDocument, childNode);
|
|
10517
|
-
});
|
|
10771
|
+
var unwrap = (result) => {
|
|
10772
|
+
if (result.isOk) {
|
|
10773
|
+
return result.value;
|
|
10518
10774
|
} else {
|
|
10519
|
-
|
|
10520
|
-
childNode.ownerDocument = ownerDocument;
|
|
10521
|
-
});
|
|
10775
|
+
throw result.value;
|
|
10522
10776
|
}
|
|
10523
|
-
}
|
|
10524
|
-
|
|
10525
|
-
if (
|
|
10526
|
-
|
|
10527
|
-
|
|
10528
|
-
|
|
10529
|
-
|
|
10530
|
-
|
|
10531
|
-
|
|
10532
|
-
|
|
10777
|
+
};
|
|
10778
|
+
var unwrapErr = (result) => {
|
|
10779
|
+
if (result.isErr) {
|
|
10780
|
+
return result.value;
|
|
10781
|
+
} else {
|
|
10782
|
+
throw result.value;
|
|
10783
|
+
}
|
|
10784
|
+
};
|
|
10785
|
+
|
|
10786
|
+
// src/utils/serialize.ts
|
|
10787
|
+
function serializeProperty(value) {
|
|
10788
|
+
if (["string", "boolean", "undefined"].includes(typeof value) || typeof value === "number" && value !== Infinity && value !== -Infinity && !isNaN(value)) {
|
|
10789
|
+
return value;
|
|
10533
10790
|
}
|
|
10791
|
+
const arg = LocalValue.getArgument(value);
|
|
10792
|
+
return SERIALIZED_PREFIX + btoa(JSON.stringify(arg));
|
|
10534
10793
|
}
|
|
10535
|
-
function
|
|
10536
|
-
if (
|
|
10537
|
-
|
|
10538
|
-
if (tempDisableCallbacks.has(node.ownerDocument) === false) {
|
|
10539
|
-
try {
|
|
10540
|
-
node.disconnectedCallback();
|
|
10541
|
-
} catch (e) {
|
|
10542
|
-
console.error(e);
|
|
10543
|
-
}
|
|
10544
|
-
}
|
|
10545
|
-
}
|
|
10546
|
-
node.childNodes.forEach(disconnectNode);
|
|
10547
|
-
}
|
|
10548
|
-
}
|
|
10549
|
-
function attributeChanged(node, attrName, oldValue, newValue) {
|
|
10550
|
-
attrName = attrName.toLowerCase();
|
|
10551
|
-
const observedAttributes = node.constructor.observedAttributes;
|
|
10552
|
-
if (Array.isArray(observedAttributes) === true && observedAttributes.some((obs) => obs.toLowerCase() === attrName) === true) {
|
|
10553
|
-
try {
|
|
10554
|
-
node.attributeChangedCallback(attrName, oldValue, newValue);
|
|
10555
|
-
} catch (e) {
|
|
10556
|
-
console.error(e);
|
|
10557
|
-
}
|
|
10794
|
+
function deserializeProperty(value) {
|
|
10795
|
+
if (typeof value !== "string" || !value.startsWith(SERIALIZED_PREFIX)) {
|
|
10796
|
+
return value;
|
|
10558
10797
|
}
|
|
10798
|
+
return RemoteValue.fromLocalValue(JSON.parse(atob(value.slice(SERIALIZED_PREFIX.length))));
|
|
10559
10799
|
}
|
|
10560
|
-
function checkAttributeChanged(node) {
|
|
10561
|
-
return node.nodeName.includes("-") === true && typeof node.attributeChangedCallback === "function";
|
|
10562
|
-
}
|
|
10563
|
-
var tempDisableCallbacks = /* @__PURE__ */ new Set();
|
|
10564
10800
|
|
|
10565
|
-
// src/
|
|
10566
|
-
|
|
10567
|
-
|
|
10568
|
-
|
|
10569
|
-
|
|
10570
|
-
|
|
10571
|
-
|
|
10572
|
-
|
|
10573
|
-
|
|
10574
|
-
|
|
10575
|
-
|
|
10576
|
-
|
|
10577
|
-
|
|
10578
|
-
|
|
10579
|
-
|
|
10580
|
-
|
|
10581
|
-
|
|
10582
|
-
|
|
10583
|
-
|
|
10584
|
-
|
|
10585
|
-
|
|
10586
|
-
|
|
10587
|
-
|
|
10588
|
-
|
|
10589
|
-
|
|
10801
|
+
// src/utils/util.ts
|
|
10802
|
+
var lowerPathParam = (fn) => (p) => fn(p.toLowerCase());
|
|
10803
|
+
var isDtsFile = lowerPathParam((p) => p.endsWith(".d.ts") || p.endsWith(".d.mts") || p.endsWith(".d.cts"));
|
|
10804
|
+
var isTsFile = lowerPathParam(
|
|
10805
|
+
(p) => !isDtsFile(p) && (p.endsWith(".ts") || p.endsWith(".mts") || p.endsWith(".cts"))
|
|
10806
|
+
);
|
|
10807
|
+
var isTsxFile = lowerPathParam(
|
|
10808
|
+
(p) => p.endsWith(".tsx") || p.endsWith(".mtsx") || p.endsWith(".ctsx")
|
|
10809
|
+
);
|
|
10810
|
+
var isJsxFile = lowerPathParam(
|
|
10811
|
+
(p) => p.endsWith(".jsx") || p.endsWith(".mjsx") || p.endsWith(".cjsx")
|
|
10812
|
+
);
|
|
10813
|
+
var isJsFile = lowerPathParam((p) => p.endsWith(".js") || p.endsWith(".mjs") || p.endsWith(".cjs"));
|
|
10814
|
+
|
|
10815
|
+
// src/utils/shadow-css.ts
|
|
10816
|
+
/**
|
|
10817
|
+
* @license
|
|
10818
|
+
* Copyright Google Inc. All Rights Reserved.
|
|
10819
|
+
*
|
|
10820
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
10821
|
+
* found in the LICENSE file at https://angular.io/license
|
|
10822
|
+
*
|
|
10823
|
+
* This file is a port of shadowCSS from `webcomponents.js` to TypeScript.
|
|
10824
|
+
* https://github.com/webcomponents/webcomponentsjs/blob/4efecd7e0e/src/ShadowCSS/ShadowCSS.js
|
|
10825
|
+
* https://github.com/angular/angular/blob/master/packages/compiler/src/shadow_css.ts
|
|
10826
|
+
*/
|
|
10827
|
+
var _polyfillHost = "-shadowcsshost";
|
|
10828
|
+
var _polyfillSlotted = "-shadowcssslotted";
|
|
10829
|
+
var _polyfillHostContext = "-shadowcsscontext";
|
|
10830
|
+
var _parenSuffix = ")(?:\\(((?:\\([^)(]*\\)|[^)(]*)+?)\\))?([^,{]*)";
|
|
10831
|
+
var _cssColonHostRe = new RegExp("(" + _polyfillHost + _parenSuffix, "gim");
|
|
10832
|
+
var _cssColonHostContextRe = new RegExp("(" + _polyfillHostContext + _parenSuffix, "gim");
|
|
10833
|
+
var _cssColonSlottedRe = new RegExp("(" + _polyfillSlotted + _parenSuffix, "gim");
|
|
10834
|
+
var _polyfillHostNoCombinator = _polyfillHost + "-no-combinator";
|
|
10835
|
+
var createSupportsRuleRe = (selector) => {
|
|
10836
|
+
const safeSelector = escapeRegExpSpecialCharacters(selector);
|
|
10837
|
+
return new RegExp(
|
|
10838
|
+
// First capture group: match any context before the selector that's not inside @supports selector()
|
|
10839
|
+
// Using negative lookahead to avoid matching inside @supports selector(...) condition
|
|
10840
|
+
`(^|[^@]|@(?!supports\\s+selector\\s*\\([^{]*?${safeSelector}))(${safeSelector}\\b)`,
|
|
10841
|
+
"g"
|
|
10842
|
+
);
|
|
10843
|
+
};
|
|
10844
|
+
var _colonSlottedRe = createSupportsRuleRe("::slotted");
|
|
10845
|
+
var _colonHostRe = createSupportsRuleRe(":host");
|
|
10846
|
+
var _colonHostContextRe = createSupportsRuleRe(":host-context");
|
|
10847
|
+
|
|
10848
|
+
// src/runtime/mode.ts
|
|
10849
|
+
var setMode = (handler) => modeResolutionChain.push(handler);
|
|
10850
|
+
var CAPTURE_EVENT_SUFFIX = "Capture";
|
|
10851
|
+
var CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + "$");
|
|
10852
|
+
var baseClass = BUILD.lazyLoad ? class {
|
|
10853
|
+
} : globalThis.HTMLElement || class {
|
|
10854
|
+
};
|
|
10855
|
+
|
|
10856
|
+
// src/runtime/tag-transform.ts
|
|
10857
|
+
var tagTransformer = void 0;
|
|
10858
|
+
function transformTag(tag) {
|
|
10859
|
+
if (!tagTransformer) return tag;
|
|
10860
|
+
return tagTransformer(tag);
|
|
10590
10861
|
}
|
|
10591
|
-
function
|
|
10592
|
-
|
|
10593
|
-
|
|
10594
|
-
|
|
10595
|
-
|
|
10596
|
-
|
|
10597
|
-
|
|
10598
|
-
|
|
10862
|
+
function setTagTransformer(transformer) {
|
|
10863
|
+
if (tagTransformer) {
|
|
10864
|
+
console.warn(`
|
|
10865
|
+
A tagTransformer has already been set.
|
|
10866
|
+
Overwriting it may lead to error and unexpected results if your components have already been defined.
|
|
10867
|
+
`);
|
|
10868
|
+
}
|
|
10869
|
+
tagTransformer = transformer;
|
|
10599
10870
|
}
|
|
10600
10871
|
|
|
10601
|
-
// src/mock-doc/
|
|
10602
|
-
var
|
|
10603
|
-
|
|
10604
|
-
|
|
10605
|
-
|
|
10606
|
-
this.cancelable = false;
|
|
10607
|
-
this.composed = false;
|
|
10608
|
-
this.currentTarget = null;
|
|
10609
|
-
this.defaultPrevented = false;
|
|
10610
|
-
this.srcElement = null;
|
|
10611
|
-
this.target = null;
|
|
10612
|
-
if (typeof type !== "string") {
|
|
10613
|
-
throw new Error(`Event type required`);
|
|
10872
|
+
// src/mock-doc/attribute.ts
|
|
10873
|
+
var attrHandler = {
|
|
10874
|
+
get(obj, prop) {
|
|
10875
|
+
if (prop in obj) {
|
|
10876
|
+
return obj[prop];
|
|
10614
10877
|
}
|
|
10615
|
-
|
|
10616
|
-
|
|
10617
|
-
if (eventInitDict != null) {
|
|
10618
|
-
Object.assign(this, eventInitDict);
|
|
10878
|
+
if (typeof prop !== "symbol" && !isNaN(prop)) {
|
|
10879
|
+
return obj.__items[prop];
|
|
10619
10880
|
}
|
|
10881
|
+
return void 0;
|
|
10620
10882
|
}
|
|
10621
|
-
|
|
10622
|
-
|
|
10883
|
+
};
|
|
10884
|
+
var createAttributeProxy = (caseInsensitive) => new Proxy(new MockAttributeMap(caseInsensitive), attrHandler);
|
|
10885
|
+
var MockAttributeMap = class {
|
|
10886
|
+
constructor(caseInsensitive = false) {
|
|
10887
|
+
this.caseInsensitive = caseInsensitive;
|
|
10888
|
+
this.__items = [];
|
|
10623
10889
|
}
|
|
10624
|
-
|
|
10625
|
-
this.
|
|
10890
|
+
get length() {
|
|
10891
|
+
return this.__items.length;
|
|
10626
10892
|
}
|
|
10627
|
-
|
|
10628
|
-
this.
|
|
10893
|
+
item(index) {
|
|
10894
|
+
return this.__items[index] || null;
|
|
10629
10895
|
}
|
|
10630
|
-
|
|
10631
|
-
|
|
10632
|
-
|
|
10633
|
-
*/
|
|
10634
|
-
composedPath() {
|
|
10635
|
-
const composedPath = [];
|
|
10636
|
-
let currentElement = this.target;
|
|
10637
|
-
while (currentElement) {
|
|
10638
|
-
composedPath.push(currentElement);
|
|
10639
|
-
if (!currentElement.parentElement && currentElement.nodeName === "#document" /* DOCUMENT_NODE */) {
|
|
10640
|
-
composedPath.push(currentElement.defaultView);
|
|
10641
|
-
break;
|
|
10642
|
-
}
|
|
10643
|
-
if (currentElement.parentElement == null && currentElement.tagName === "HTML") {
|
|
10644
|
-
currentElement = currentElement.ownerDocument;
|
|
10645
|
-
} else {
|
|
10646
|
-
currentElement = currentElement.parentElement;
|
|
10647
|
-
}
|
|
10648
|
-
}
|
|
10649
|
-
return composedPath;
|
|
10896
|
+
setNamedItem(attr) {
|
|
10897
|
+
attr.namespaceURI = null;
|
|
10898
|
+
this.setNamedItemNS(attr);
|
|
10650
10899
|
}
|
|
10651
|
-
|
|
10652
|
-
|
|
10653
|
-
|
|
10654
|
-
super(type);
|
|
10655
|
-
this.detail = null;
|
|
10656
|
-
if (customEventInitDic != null) {
|
|
10657
|
-
Object.assign(this, customEventInitDic);
|
|
10900
|
+
setNamedItemNS(attr) {
|
|
10901
|
+
if (attr != null && attr.value != null) {
|
|
10902
|
+
attr.value = String(attr.value);
|
|
10658
10903
|
}
|
|
10659
|
-
|
|
10660
|
-
|
|
10661
|
-
|
|
10662
|
-
|
|
10663
|
-
|
|
10664
|
-
this.code = "";
|
|
10665
|
-
this.key = "";
|
|
10666
|
-
this.altKey = false;
|
|
10667
|
-
this.ctrlKey = false;
|
|
10668
|
-
this.metaKey = false;
|
|
10669
|
-
this.shiftKey = false;
|
|
10670
|
-
this.location = 0;
|
|
10671
|
-
this.repeat = false;
|
|
10672
|
-
if (keyboardEventInitDic != null) {
|
|
10673
|
-
Object.assign(this, keyboardEventInitDic);
|
|
10904
|
+
const existingAttr = this.__items.find((a) => a.name === attr.name && a.namespaceURI === attr.namespaceURI);
|
|
10905
|
+
if (existingAttr != null) {
|
|
10906
|
+
existingAttr.value = attr.value;
|
|
10907
|
+
} else {
|
|
10908
|
+
this.__items.push(attr);
|
|
10674
10909
|
}
|
|
10675
10910
|
}
|
|
10676
|
-
|
|
10677
|
-
|
|
10678
|
-
|
|
10679
|
-
super(type);
|
|
10680
|
-
this.screenX = 0;
|
|
10681
|
-
this.screenY = 0;
|
|
10682
|
-
this.clientX = 0;
|
|
10683
|
-
this.clientY = 0;
|
|
10684
|
-
this.ctrlKey = false;
|
|
10685
|
-
this.shiftKey = false;
|
|
10686
|
-
this.altKey = false;
|
|
10687
|
-
this.metaKey = false;
|
|
10688
|
-
this.button = 0;
|
|
10689
|
-
this.buttons = 0;
|
|
10690
|
-
this.relatedTarget = null;
|
|
10691
|
-
if (mouseEventInitDic != null) {
|
|
10692
|
-
Object.assign(this, mouseEventInitDic);
|
|
10911
|
+
getNamedItem(attrName) {
|
|
10912
|
+
if (this.caseInsensitive) {
|
|
10913
|
+
attrName = attrName.toLowerCase();
|
|
10693
10914
|
}
|
|
10915
|
+
return this.getNamedItemNS(null, attrName);
|
|
10694
10916
|
}
|
|
10695
|
-
|
|
10696
|
-
|
|
10697
|
-
|
|
10698
|
-
super(type);
|
|
10699
|
-
this.detail = null;
|
|
10700
|
-
this.view = null;
|
|
10701
|
-
if (uiEventInitDic != null) {
|
|
10702
|
-
Object.assign(this, uiEventInitDic);
|
|
10703
|
-
}
|
|
10917
|
+
getNamedItemNS(namespaceURI, attrName) {
|
|
10918
|
+
namespaceURI = getNamespaceURI(namespaceURI);
|
|
10919
|
+
return this.__items.find((attr) => attr.name === attrName && getNamespaceURI(attr.namespaceURI) === namespaceURI) || null;
|
|
10704
10920
|
}
|
|
10705
|
-
|
|
10706
|
-
|
|
10707
|
-
constructor(type, focusEventInitDic) {
|
|
10708
|
-
super(type);
|
|
10709
|
-
this.relatedTarget = null;
|
|
10710
|
-
if (focusEventInitDic != null) {
|
|
10711
|
-
Object.assign(this, focusEventInitDic);
|
|
10712
|
-
}
|
|
10921
|
+
removeNamedItem(attr) {
|
|
10922
|
+
this.removeNamedItemNS(attr);
|
|
10713
10923
|
}
|
|
10714
|
-
|
|
10715
|
-
|
|
10716
|
-
|
|
10717
|
-
|
|
10718
|
-
|
|
10924
|
+
removeNamedItemNS(attr) {
|
|
10925
|
+
for (let i = 0, ii = this.__items.length; i < ii; i++) {
|
|
10926
|
+
if (this.__items[i].name === attr.name && this.__items[i].namespaceURI === attr.namespaceURI) {
|
|
10927
|
+
this.__items.splice(i, 1);
|
|
10928
|
+
break;
|
|
10929
|
+
}
|
|
10930
|
+
}
|
|
10719
10931
|
}
|
|
10720
|
-
|
|
10721
|
-
|
|
10722
|
-
|
|
10723
|
-
|
|
10724
|
-
|
|
10932
|
+
[Symbol.iterator]() {
|
|
10933
|
+
let i = 0;
|
|
10934
|
+
return {
|
|
10935
|
+
next: () => ({
|
|
10936
|
+
done: i === this.length,
|
|
10937
|
+
value: this.item(i++)
|
|
10938
|
+
})
|
|
10939
|
+
};
|
|
10725
10940
|
}
|
|
10726
|
-
|
|
10941
|
+
get [Symbol.toStringTag]() {
|
|
10942
|
+
return "MockAttributeMap";
|
|
10943
|
+
}
|
|
10944
|
+
};
|
|
10945
|
+
function getNamespaceURI(namespaceURI) {
|
|
10946
|
+
return namespaceURI === XLINK_NS ? null : namespaceURI;
|
|
10727
10947
|
}
|
|
10728
|
-
function
|
|
10729
|
-
const
|
|
10730
|
-
if (
|
|
10731
|
-
const
|
|
10732
|
-
if (
|
|
10733
|
-
const
|
|
10734
|
-
|
|
10948
|
+
function cloneAttributes(srcAttrs, sortByName = false) {
|
|
10949
|
+
const dstAttrs = new MockAttributeMap(srcAttrs.caseInsensitive);
|
|
10950
|
+
if (srcAttrs != null) {
|
|
10951
|
+
const attrLen = srcAttrs.length;
|
|
10952
|
+
if (sortByName && attrLen > 1) {
|
|
10953
|
+
const sortedAttrs = [];
|
|
10954
|
+
for (let i = 0; i < attrLen; i++) {
|
|
10955
|
+
const srcAttr = srcAttrs.item(i);
|
|
10956
|
+
const dstAttr = new MockAttr(srcAttr.name, srcAttr.value, srcAttr.namespaceURI);
|
|
10957
|
+
sortedAttrs.push(dstAttr);
|
|
10958
|
+
}
|
|
10959
|
+
sortedAttrs.sort(sortAttributes).forEach((attr) => {
|
|
10960
|
+
dstAttrs.setNamedItemNS(attr);
|
|
10961
|
+
});
|
|
10962
|
+
} else {
|
|
10963
|
+
for (let i = 0; i < attrLen; i++) {
|
|
10964
|
+
const srcAttr = srcAttrs.item(i);
|
|
10965
|
+
const dstAttr = new MockAttr(srcAttr.name, srcAttr.value, srcAttr.namespaceURI);
|
|
10966
|
+
dstAttrs.setNamedItemNS(dstAttr);
|
|
10967
|
+
}
|
|
10735
10968
|
}
|
|
10736
10969
|
}
|
|
10970
|
+
return dstAttrs;
|
|
10737
10971
|
}
|
|
10738
|
-
function
|
|
10739
|
-
if (
|
|
10740
|
-
|
|
10741
|
-
|
|
10972
|
+
function sortAttributes(a, b) {
|
|
10973
|
+
if (a.name < b.name) return -1;
|
|
10974
|
+
if (a.name > b.name) return 1;
|
|
10975
|
+
return 0;
|
|
10742
10976
|
}
|
|
10743
|
-
|
|
10744
|
-
|
|
10745
|
-
|
|
10977
|
+
var MockAttr = class {
|
|
10978
|
+
constructor(attrName, attrValue, namespaceURI = null) {
|
|
10979
|
+
this._name = attrName;
|
|
10980
|
+
this._value = String(attrValue);
|
|
10981
|
+
this._namespaceURI = namespaceURI;
|
|
10746
10982
|
}
|
|
10747
|
-
|
|
10748
|
-
|
|
10749
|
-
if (Array.isArray(target.__listeners) === true) {
|
|
10750
|
-
const listeners = target.__listeners.filter((e) => e.type === ev.type);
|
|
10751
|
-
listeners.forEach((listener) => {
|
|
10752
|
-
try {
|
|
10753
|
-
listener.handler.call(target, ev);
|
|
10754
|
-
} catch (err2) {
|
|
10755
|
-
console.error(err2);
|
|
10756
|
-
}
|
|
10757
|
-
});
|
|
10983
|
+
get name() {
|
|
10984
|
+
return this._name;
|
|
10758
10985
|
}
|
|
10759
|
-
|
|
10760
|
-
|
|
10986
|
+
set name(value) {
|
|
10987
|
+
this._name = value;
|
|
10761
10988
|
}
|
|
10762
|
-
|
|
10763
|
-
|
|
10764
|
-
} else if (elm.parentElement == null && elm.tagName === "HTML") {
|
|
10765
|
-
triggerEventListener(elm.ownerDocument, ev);
|
|
10766
|
-
} else {
|
|
10767
|
-
const nextTarget = getNextEventTarget(elm, ev);
|
|
10768
|
-
triggerEventListener(nextTarget, ev);
|
|
10989
|
+
get value() {
|
|
10990
|
+
return this._value;
|
|
10769
10991
|
}
|
|
10770
|
-
|
|
10771
|
-
|
|
10772
|
-
if (elm.parentElement) {
|
|
10773
|
-
return elm.parentElement;
|
|
10992
|
+
set value(value) {
|
|
10993
|
+
this._value = String(value);
|
|
10774
10994
|
}
|
|
10775
|
-
|
|
10776
|
-
return
|
|
10995
|
+
get nodeName() {
|
|
10996
|
+
return this._name;
|
|
10777
10997
|
}
|
|
10778
|
-
|
|
10779
|
-
|
|
10998
|
+
set nodeName(value) {
|
|
10999
|
+
this._name = value;
|
|
10780
11000
|
}
|
|
10781
|
-
|
|
11001
|
+
get nodeValue() {
|
|
11002
|
+
return this._value;
|
|
11003
|
+
}
|
|
11004
|
+
set nodeValue(value) {
|
|
11005
|
+
this._value = String(value);
|
|
11006
|
+
}
|
|
11007
|
+
get namespaceURI() {
|
|
11008
|
+
return this._namespaceURI;
|
|
11009
|
+
}
|
|
11010
|
+
set namespaceURI(namespaceURI) {
|
|
11011
|
+
this._namespaceURI = namespaceURI;
|
|
11012
|
+
}
|
|
11013
|
+
};
|
|
11014
|
+
|
|
11015
|
+
// src/mock-doc/css-style-declaration.ts
|
|
11016
|
+
var MockCSSStyleDeclaration = class {
|
|
11017
|
+
constructor() {
|
|
11018
|
+
this._styles = /* @__PURE__ */ new Map();
|
|
11019
|
+
}
|
|
11020
|
+
setProperty(prop, value) {
|
|
11021
|
+
prop = jsCaseToCssCase(prop);
|
|
11022
|
+
if (value == null || value === "") {
|
|
11023
|
+
this._styles.delete(prop);
|
|
11024
|
+
} else {
|
|
11025
|
+
this._styles.set(prop, String(value));
|
|
11026
|
+
}
|
|
11027
|
+
}
|
|
11028
|
+
getPropertyValue(prop) {
|
|
11029
|
+
prop = jsCaseToCssCase(prop);
|
|
11030
|
+
return String(this._styles.get(prop) || "");
|
|
11031
|
+
}
|
|
11032
|
+
removeProperty(prop) {
|
|
11033
|
+
prop = jsCaseToCssCase(prop);
|
|
11034
|
+
this._styles.delete(prop);
|
|
11035
|
+
}
|
|
11036
|
+
get length() {
|
|
11037
|
+
return this._styles.size;
|
|
11038
|
+
}
|
|
11039
|
+
get cssText() {
|
|
11040
|
+
const cssText = [];
|
|
11041
|
+
this._styles.forEach((value, prop) => {
|
|
11042
|
+
cssText.push(`${prop}: ${value};`);
|
|
11043
|
+
});
|
|
11044
|
+
return cssText.join(" ").trim();
|
|
11045
|
+
}
|
|
11046
|
+
set cssText(cssText) {
|
|
11047
|
+
if (cssText == null || cssText === "") {
|
|
11048
|
+
this._styles.clear();
|
|
11049
|
+
return;
|
|
11050
|
+
}
|
|
11051
|
+
cssText.split(";").forEach((rule) => {
|
|
11052
|
+
rule = rule.trim();
|
|
11053
|
+
if (rule.length > 0) {
|
|
11054
|
+
const splt = rule.split(":");
|
|
11055
|
+
if (splt.length > 1) {
|
|
11056
|
+
const prop = splt[0].trim();
|
|
11057
|
+
const value = splt.slice(1).join(":").trim();
|
|
11058
|
+
if (prop !== "" && value !== "") {
|
|
11059
|
+
this._styles.set(jsCaseToCssCase(prop), value);
|
|
11060
|
+
}
|
|
11061
|
+
}
|
|
11062
|
+
}
|
|
11063
|
+
});
|
|
11064
|
+
}
|
|
11065
|
+
};
|
|
11066
|
+
function createCSSStyleDeclaration() {
|
|
11067
|
+
return new Proxy(new MockCSSStyleDeclaration(), cssProxyHandler);
|
|
10782
11068
|
}
|
|
10783
|
-
|
|
10784
|
-
|
|
10785
|
-
|
|
10786
|
-
|
|
11069
|
+
var cssProxyHandler = {
|
|
11070
|
+
get(cssStyle, prop) {
|
|
11071
|
+
if (prop in cssStyle) {
|
|
11072
|
+
return cssStyle[prop];
|
|
11073
|
+
}
|
|
11074
|
+
prop = cssCaseToJsCase(prop);
|
|
11075
|
+
return cssStyle.getPropertyValue(prop);
|
|
11076
|
+
},
|
|
11077
|
+
set(cssStyle, prop, value) {
|
|
11078
|
+
if (prop in cssStyle) {
|
|
11079
|
+
cssStyle[prop] = value;
|
|
11080
|
+
} else {
|
|
11081
|
+
cssStyle.setProperty(prop, value);
|
|
11082
|
+
}
|
|
11083
|
+
return true;
|
|
11084
|
+
}
|
|
11085
|
+
};
|
|
11086
|
+
function cssCaseToJsCase(str) {
|
|
11087
|
+
if (str.length > 1 && str.includes("-") === true) {
|
|
11088
|
+
str = str.toLowerCase().split("-").map((segment) => segment.charAt(0).toUpperCase() + segment.slice(1)).join("");
|
|
11089
|
+
str = str.slice(0, 1).toLowerCase() + str.slice(1);
|
|
11090
|
+
}
|
|
11091
|
+
return str;
|
|
11092
|
+
}
|
|
11093
|
+
function jsCaseToCssCase(str) {
|
|
11094
|
+
if (str.length > 1 && str.includes("-") === false && /[A-Z]/.test(str) === true) {
|
|
11095
|
+
str = str.replace(/([A-Z])/g, (g) => " " + g[0]).trim().replace(/ /g, "-").toLowerCase();
|
|
11096
|
+
}
|
|
11097
|
+
return str;
|
|
10787
11098
|
}
|
|
10788
11099
|
|
|
10789
|
-
//
|
|
10790
|
-
var
|
|
10791
|
-
|
|
10792
|
-
|
|
10793
|
-
|
|
10794
|
-
|
|
10795
|
-
|
|
10796
|
-
|
|
10797
|
-
|
|
10798
|
-
|
|
10799
|
-
|
|
10800
|
-
|
|
10801
|
-
|
|
10802
|
-
|
|
10803
|
-
|
|
10804
|
-
|
|
10805
|
-
|
|
10806
|
-
|
|
10807
|
-
|
|
10808
|
-
|
|
10809
|
-
|
|
10810
|
-
|
|
10811
|
-
|
|
10812
|
-
|
|
10813
|
-
|
|
10814
|
-
|
|
10815
|
-
|
|
10816
|
-
|
|
10817
|
-
|
|
10818
|
-
|
|
10819
|
-
|
|
10820
|
-
|
|
10821
|
-
|
|
10822
|
-
|
|
10823
|
-
|
|
10824
|
-
|
|
10825
|
-
|
|
10826
|
-
|
|
10827
|
-
|
|
10828
|
-
(
|
|
10829
|
-
|
|
11100
|
+
// src/mock-doc/custom-element-registry.ts
|
|
11101
|
+
var MockCustomElementRegistry = class {
|
|
11102
|
+
constructor(win2) {
|
|
11103
|
+
this.win = win2;
|
|
11104
|
+
}
|
|
11105
|
+
define(tagName, cstr, options) {
|
|
11106
|
+
if (tagName.toLowerCase() !== tagName) {
|
|
11107
|
+
throw new Error(
|
|
11108
|
+
`Failed to execute 'define' on 'CustomElementRegistry': "${tagName}" is not a valid custom element name`
|
|
11109
|
+
);
|
|
11110
|
+
}
|
|
11111
|
+
if (this.__registry == null) {
|
|
11112
|
+
this.__registry = /* @__PURE__ */ new Map();
|
|
11113
|
+
}
|
|
11114
|
+
this.__registry.set(tagName, { cstr, options });
|
|
11115
|
+
if (this.__whenDefined != null) {
|
|
11116
|
+
const whenDefinedResolveFns = this.__whenDefined.get(tagName);
|
|
11117
|
+
if (whenDefinedResolveFns != null) {
|
|
11118
|
+
whenDefinedResolveFns.forEach((whenDefinedResolveFn) => {
|
|
11119
|
+
whenDefinedResolveFn();
|
|
11120
|
+
});
|
|
11121
|
+
whenDefinedResolveFns.length = 0;
|
|
11122
|
+
this.__whenDefined.delete(tagName);
|
|
11123
|
+
}
|
|
11124
|
+
}
|
|
11125
|
+
const doc = this.win.document;
|
|
11126
|
+
if (doc != null) {
|
|
11127
|
+
const hosts = doc.querySelectorAll(tagName);
|
|
11128
|
+
hosts.forEach((host) => {
|
|
11129
|
+
if (upgradedElements.has(host) === false) {
|
|
11130
|
+
tempDisableCallbacks.add(doc);
|
|
11131
|
+
const upgradedCmp = createCustomElement(this, doc, tagName);
|
|
11132
|
+
for (let i = 0; i < host.childNodes.length; i++) {
|
|
11133
|
+
const childNode = host.childNodes[i];
|
|
11134
|
+
childNode.remove();
|
|
11135
|
+
upgradedCmp.appendChild(childNode);
|
|
11136
|
+
}
|
|
11137
|
+
tempDisableCallbacks.delete(doc);
|
|
11138
|
+
if (proxyElements.has(host)) {
|
|
11139
|
+
proxyElements.set(host, upgradedCmp);
|
|
11140
|
+
}
|
|
11141
|
+
}
|
|
11142
|
+
fireConnectedCallback2(host);
|
|
11143
|
+
});
|
|
11144
|
+
}
|
|
11145
|
+
}
|
|
11146
|
+
get(tagName) {
|
|
11147
|
+
if (this.__registry != null) {
|
|
11148
|
+
const def = this.__registry.get(tagName.toLowerCase());
|
|
11149
|
+
if (def != null) {
|
|
11150
|
+
return def.cstr;
|
|
11151
|
+
}
|
|
11152
|
+
}
|
|
11153
|
+
return void 0;
|
|
11154
|
+
}
|
|
11155
|
+
getName(cstr) {
|
|
11156
|
+
for (const [tagName, def] of this.__registry.entries()) {
|
|
11157
|
+
if (def.cstr === cstr) {
|
|
11158
|
+
return tagName;
|
|
11159
|
+
}
|
|
11160
|
+
}
|
|
11161
|
+
return void 0;
|
|
11162
|
+
}
|
|
11163
|
+
upgrade(_rootNode) {
|
|
11164
|
+
}
|
|
11165
|
+
clear() {
|
|
11166
|
+
if (this.__registry != null) {
|
|
11167
|
+
this.__registry.clear();
|
|
11168
|
+
}
|
|
11169
|
+
if (this.__whenDefined != null) {
|
|
11170
|
+
this.__whenDefined.clear();
|
|
11171
|
+
}
|
|
11172
|
+
}
|
|
11173
|
+
whenDefined(tagName) {
|
|
11174
|
+
tagName = tagName.toLowerCase();
|
|
11175
|
+
if (this.__registry != null && this.__registry.has(tagName) === true) {
|
|
11176
|
+
return Promise.resolve(this.__registry.get(tagName).cstr);
|
|
11177
|
+
}
|
|
11178
|
+
return new Promise((resolve) => {
|
|
11179
|
+
if (this.__whenDefined == null) {
|
|
11180
|
+
this.__whenDefined = /* @__PURE__ */ new Map();
|
|
11181
|
+
}
|
|
11182
|
+
let whenDefinedResolveFns = this.__whenDefined.get(tagName);
|
|
11183
|
+
if (whenDefinedResolveFns == null) {
|
|
11184
|
+
whenDefinedResolveFns = [];
|
|
11185
|
+
this.__whenDefined.set(tagName, whenDefinedResolveFns);
|
|
11186
|
+
}
|
|
11187
|
+
whenDefinedResolveFns.push(resolve);
|
|
11188
|
+
});
|
|
11189
|
+
}
|
|
11190
|
+
};
|
|
11191
|
+
function createCustomElement(customElements2, ownerDocument, tagName) {
|
|
11192
|
+
const Cstr = customElements2.get(tagName);
|
|
11193
|
+
if (Cstr != null) {
|
|
11194
|
+
const cmp = new Cstr(ownerDocument);
|
|
11195
|
+
cmp.nodeName = tagName.toUpperCase();
|
|
11196
|
+
upgradedElements.add(cmp);
|
|
11197
|
+
return cmp;
|
|
11198
|
+
}
|
|
11199
|
+
const host = new Proxy(
|
|
11200
|
+
{},
|
|
11201
|
+
{
|
|
11202
|
+
get(obj, prop) {
|
|
11203
|
+
const elm2 = proxyElements.get(host);
|
|
11204
|
+
if (elm2 != null) {
|
|
11205
|
+
return elm2[prop];
|
|
11206
|
+
}
|
|
11207
|
+
return obj[prop];
|
|
11208
|
+
},
|
|
11209
|
+
set(obj, prop, val) {
|
|
11210
|
+
const elm2 = proxyElements.get(host);
|
|
11211
|
+
if (elm2 != null) {
|
|
11212
|
+
elm2[prop] = val;
|
|
11213
|
+
} else {
|
|
11214
|
+
obj[prop] = val;
|
|
11215
|
+
}
|
|
11216
|
+
return true;
|
|
11217
|
+
},
|
|
11218
|
+
has(obj, prop) {
|
|
11219
|
+
const elm2 = proxyElements.get(host);
|
|
11220
|
+
if (prop in elm2) {
|
|
11221
|
+
return true;
|
|
11222
|
+
}
|
|
11223
|
+
if (prop in obj) {
|
|
11224
|
+
return true;
|
|
11225
|
+
}
|
|
11226
|
+
return false;
|
|
11227
|
+
}
|
|
11228
|
+
}
|
|
11229
|
+
);
|
|
11230
|
+
const elm = new MockHTMLElement(ownerDocument, tagName);
|
|
11231
|
+
proxyElements.set(host, elm);
|
|
11232
|
+
return host;
|
|
11233
|
+
}
|
|
11234
|
+
var proxyElements = /* @__PURE__ */ new WeakMap();
|
|
11235
|
+
var upgradedElements = /* @__PURE__ */ new WeakSet();
|
|
11236
|
+
function connectNode(ownerDocument, node) {
|
|
11237
|
+
node.ownerDocument = ownerDocument;
|
|
11238
|
+
if (node.nodeType === 1 /* ELEMENT_NODE */) {
|
|
11239
|
+
if (ownerDocument != null && node.nodeName.includes("-")) {
|
|
11240
|
+
const win2 = ownerDocument.defaultView;
|
|
11241
|
+
if (win2 != null && typeof node.connectedCallback === "function" && node.isConnected) {
|
|
11242
|
+
fireConnectedCallback2(node);
|
|
11243
|
+
}
|
|
11244
|
+
const shadowRoot = node.shadowRoot;
|
|
11245
|
+
if (shadowRoot != null) {
|
|
11246
|
+
shadowRoot.childNodes.forEach((childNode) => {
|
|
11247
|
+
connectNode(ownerDocument, childNode);
|
|
11248
|
+
});
|
|
11249
|
+
}
|
|
11250
|
+
}
|
|
11251
|
+
node.childNodes.forEach((childNode) => {
|
|
11252
|
+
connectNode(ownerDocument, childNode);
|
|
11253
|
+
});
|
|
11254
|
+
} else {
|
|
11255
|
+
node.childNodes.forEach((childNode) => {
|
|
11256
|
+
childNode.ownerDocument = ownerDocument;
|
|
11257
|
+
});
|
|
11258
|
+
}
|
|
11259
|
+
}
|
|
11260
|
+
function fireConnectedCallback2(node) {
|
|
11261
|
+
if (typeof node.connectedCallback === "function") {
|
|
11262
|
+
if (tempDisableCallbacks.has(node.ownerDocument) === false) {
|
|
11263
|
+
try {
|
|
11264
|
+
node.connectedCallback();
|
|
11265
|
+
} catch (e) {
|
|
11266
|
+
console.error(e);
|
|
11267
|
+
}
|
|
11268
|
+
}
|
|
11269
|
+
}
|
|
11270
|
+
}
|
|
11271
|
+
function disconnectNode(node) {
|
|
11272
|
+
if (node.nodeType === 1 /* ELEMENT_NODE */) {
|
|
11273
|
+
if (node.nodeName.includes("-") === true && typeof node.disconnectedCallback === "function") {
|
|
11274
|
+
if (tempDisableCallbacks.has(node.ownerDocument) === false) {
|
|
11275
|
+
try {
|
|
11276
|
+
node.disconnectedCallback();
|
|
11277
|
+
} catch (e) {
|
|
11278
|
+
console.error(e);
|
|
11279
|
+
}
|
|
11280
|
+
}
|
|
11281
|
+
}
|
|
11282
|
+
node.childNodes.forEach(disconnectNode);
|
|
11283
|
+
}
|
|
11284
|
+
}
|
|
11285
|
+
function attributeChanged(node, attrName, oldValue, newValue) {
|
|
11286
|
+
attrName = attrName.toLowerCase();
|
|
11287
|
+
const observedAttributes = node.constructor.observedAttributes;
|
|
11288
|
+
if (Array.isArray(observedAttributes) === true && observedAttributes.some((obs) => obs.toLowerCase() === attrName) === true) {
|
|
11289
|
+
try {
|
|
11290
|
+
node.attributeChangedCallback(attrName, oldValue, newValue);
|
|
11291
|
+
} catch (e) {
|
|
11292
|
+
console.error(e);
|
|
11293
|
+
}
|
|
11294
|
+
}
|
|
11295
|
+
}
|
|
11296
|
+
function checkAttributeChanged(node) {
|
|
11297
|
+
return node.nodeName.includes("-") === true && typeof node.attributeChangedCallback === "function";
|
|
11298
|
+
}
|
|
11299
|
+
var tempDisableCallbacks = /* @__PURE__ */ new Set();
|
|
11300
|
+
|
|
11301
|
+
// src/mock-doc/dataset.ts
|
|
11302
|
+
function dataset(elm) {
|
|
11303
|
+
const ds = {};
|
|
11304
|
+
const attributes = elm.attributes;
|
|
11305
|
+
const attrLen = attributes.length;
|
|
11306
|
+
for (let i = 0; i < attrLen; i++) {
|
|
11307
|
+
const attr = attributes.item(i);
|
|
11308
|
+
const nodeName = attr.nodeName;
|
|
11309
|
+
if (nodeName.startsWith("data-")) {
|
|
11310
|
+
ds[dashToPascalCase2(nodeName)] = attr.nodeValue;
|
|
11311
|
+
}
|
|
11312
|
+
}
|
|
11313
|
+
return new Proxy(ds, {
|
|
11314
|
+
get(_obj, camelCaseProp) {
|
|
11315
|
+
return ds[camelCaseProp];
|
|
11316
|
+
},
|
|
11317
|
+
set(_obj, camelCaseProp, value) {
|
|
11318
|
+
const dataAttr = toDataAttribute(camelCaseProp);
|
|
11319
|
+
elm.setAttribute(dataAttr, value);
|
|
11320
|
+
return true;
|
|
11321
|
+
}
|
|
11322
|
+
});
|
|
11323
|
+
}
|
|
11324
|
+
function toDataAttribute(str) {
|
|
11325
|
+
return "data-" + String(str).replace(/([A-Z0-9])/g, (g) => " " + g[0]).trim().replace(/ /g, "-").toLowerCase();
|
|
11326
|
+
}
|
|
11327
|
+
function dashToPascalCase2(str) {
|
|
11328
|
+
str = String(str).slice(5);
|
|
11329
|
+
return str.split("-").map((segment, index) => {
|
|
11330
|
+
if (index === 0) {
|
|
11331
|
+
return segment.charAt(0).toLowerCase() + segment.slice(1);
|
|
11332
|
+
}
|
|
11333
|
+
return segment.charAt(0).toUpperCase() + segment.slice(1);
|
|
11334
|
+
}).join("");
|
|
11335
|
+
}
|
|
11336
|
+
|
|
11337
|
+
// src/mock-doc/event.ts
|
|
11338
|
+
var MockEvent = class {
|
|
11339
|
+
constructor(type, eventInitDict) {
|
|
11340
|
+
this.bubbles = false;
|
|
11341
|
+
this.cancelBubble = false;
|
|
11342
|
+
this.cancelable = false;
|
|
11343
|
+
this.composed = false;
|
|
11344
|
+
this.currentTarget = null;
|
|
11345
|
+
this.defaultPrevented = false;
|
|
11346
|
+
this.srcElement = null;
|
|
11347
|
+
this.target = null;
|
|
11348
|
+
if (typeof type !== "string") {
|
|
11349
|
+
throw new Error(`Event type required`);
|
|
11350
|
+
}
|
|
11351
|
+
this.type = type;
|
|
11352
|
+
this.timeStamp = Date.now();
|
|
11353
|
+
if (eventInitDict != null) {
|
|
11354
|
+
Object.assign(this, eventInitDict);
|
|
11355
|
+
}
|
|
11356
|
+
}
|
|
11357
|
+
preventDefault() {
|
|
11358
|
+
this.defaultPrevented = true;
|
|
11359
|
+
}
|
|
11360
|
+
stopPropagation() {
|
|
11361
|
+
this.cancelBubble = true;
|
|
11362
|
+
}
|
|
11363
|
+
stopImmediatePropagation() {
|
|
11364
|
+
this.cancelBubble = true;
|
|
11365
|
+
}
|
|
11366
|
+
/**
|
|
11367
|
+
* @ref https://developer.mozilla.org/en-US/docs/Web/API/Event/composedPath
|
|
11368
|
+
* @returns a composed path of the event
|
|
11369
|
+
*/
|
|
11370
|
+
composedPath() {
|
|
11371
|
+
const composedPath = [];
|
|
11372
|
+
let currentElement = this.target;
|
|
11373
|
+
while (currentElement) {
|
|
11374
|
+
composedPath.push(currentElement);
|
|
11375
|
+
if (!currentElement.parentElement && currentElement.nodeName === "#document" /* DOCUMENT_NODE */) {
|
|
11376
|
+
composedPath.push(currentElement.defaultView);
|
|
11377
|
+
break;
|
|
11378
|
+
}
|
|
11379
|
+
if (currentElement.parentElement == null && currentElement.tagName === "HTML") {
|
|
11380
|
+
currentElement = currentElement.ownerDocument;
|
|
11381
|
+
} else {
|
|
11382
|
+
currentElement = currentElement.parentElement;
|
|
11383
|
+
}
|
|
11384
|
+
}
|
|
11385
|
+
return composedPath;
|
|
11386
|
+
}
|
|
11387
|
+
};
|
|
11388
|
+
var MockCustomEvent = class extends MockEvent {
|
|
11389
|
+
constructor(type, customEventInitDic) {
|
|
11390
|
+
super(type);
|
|
11391
|
+
this.detail = null;
|
|
11392
|
+
if (customEventInitDic != null) {
|
|
11393
|
+
Object.assign(this, customEventInitDic);
|
|
11394
|
+
}
|
|
11395
|
+
}
|
|
11396
|
+
};
|
|
11397
|
+
var MockKeyboardEvent = class extends MockEvent {
|
|
11398
|
+
constructor(type, keyboardEventInitDic) {
|
|
11399
|
+
super(type);
|
|
11400
|
+
this.code = "";
|
|
11401
|
+
this.key = "";
|
|
11402
|
+
this.altKey = false;
|
|
11403
|
+
this.ctrlKey = false;
|
|
11404
|
+
this.metaKey = false;
|
|
11405
|
+
this.shiftKey = false;
|
|
11406
|
+
this.location = 0;
|
|
11407
|
+
this.repeat = false;
|
|
11408
|
+
if (keyboardEventInitDic != null) {
|
|
11409
|
+
Object.assign(this, keyboardEventInitDic);
|
|
11410
|
+
}
|
|
11411
|
+
}
|
|
11412
|
+
};
|
|
11413
|
+
var MockMouseEvent = class extends MockEvent {
|
|
11414
|
+
constructor(type, mouseEventInitDic) {
|
|
11415
|
+
super(type);
|
|
11416
|
+
this.screenX = 0;
|
|
11417
|
+
this.screenY = 0;
|
|
11418
|
+
this.clientX = 0;
|
|
11419
|
+
this.clientY = 0;
|
|
11420
|
+
this.ctrlKey = false;
|
|
11421
|
+
this.shiftKey = false;
|
|
11422
|
+
this.altKey = false;
|
|
11423
|
+
this.metaKey = false;
|
|
11424
|
+
this.button = 0;
|
|
11425
|
+
this.buttons = 0;
|
|
11426
|
+
this.relatedTarget = null;
|
|
11427
|
+
if (mouseEventInitDic != null) {
|
|
11428
|
+
Object.assign(this, mouseEventInitDic);
|
|
11429
|
+
}
|
|
11430
|
+
}
|
|
11431
|
+
};
|
|
11432
|
+
var MockUIEvent = class extends MockEvent {
|
|
11433
|
+
constructor(type, uiEventInitDic) {
|
|
11434
|
+
super(type);
|
|
11435
|
+
this.detail = null;
|
|
11436
|
+
this.view = null;
|
|
11437
|
+
if (uiEventInitDic != null) {
|
|
11438
|
+
Object.assign(this, uiEventInitDic);
|
|
11439
|
+
}
|
|
11440
|
+
}
|
|
11441
|
+
};
|
|
11442
|
+
var MockFocusEvent = class extends MockUIEvent {
|
|
11443
|
+
constructor(type, focusEventInitDic) {
|
|
11444
|
+
super(type);
|
|
11445
|
+
this.relatedTarget = null;
|
|
11446
|
+
if (focusEventInitDic != null) {
|
|
11447
|
+
Object.assign(this, focusEventInitDic);
|
|
11448
|
+
}
|
|
11449
|
+
}
|
|
11450
|
+
};
|
|
11451
|
+
var MockEventListener = class {
|
|
11452
|
+
constructor(type, handler) {
|
|
11453
|
+
this.type = type;
|
|
11454
|
+
this.handler = handler;
|
|
11455
|
+
}
|
|
11456
|
+
};
|
|
11457
|
+
function addEventListener(elm, type, handler) {
|
|
11458
|
+
const target = elm;
|
|
11459
|
+
if (target.__listeners == null) {
|
|
11460
|
+
target.__listeners = [];
|
|
11461
|
+
}
|
|
11462
|
+
target.__listeners.push(new MockEventListener(type, handler));
|
|
11463
|
+
}
|
|
11464
|
+
function removeEventListener(elm, type, handler) {
|
|
11465
|
+
const target = elm;
|
|
11466
|
+
if (target != null && Array.isArray(target.__listeners) === true) {
|
|
11467
|
+
const elmListener = target.__listeners.find((e) => e.type === type && e.handler === handler);
|
|
11468
|
+
if (elmListener != null) {
|
|
11469
|
+
const index = target.__listeners.indexOf(elmListener);
|
|
11470
|
+
target.__listeners.splice(index, 1);
|
|
11471
|
+
}
|
|
11472
|
+
}
|
|
11473
|
+
}
|
|
11474
|
+
function resetEventListeners(target) {
|
|
11475
|
+
if (target != null && target.__listeners != null) {
|
|
11476
|
+
target.__listeners = null;
|
|
11477
|
+
}
|
|
11478
|
+
}
|
|
11479
|
+
function triggerEventListener(elm, ev) {
|
|
11480
|
+
if (elm == null || ev.cancelBubble === true) {
|
|
11481
|
+
return;
|
|
11482
|
+
}
|
|
11483
|
+
const target = elm;
|
|
11484
|
+
ev.currentTarget = elm;
|
|
11485
|
+
if (Array.isArray(target.__listeners) === true) {
|
|
11486
|
+
const listeners = target.__listeners.filter((e) => e.type === ev.type);
|
|
11487
|
+
listeners.forEach((listener) => {
|
|
11488
|
+
try {
|
|
11489
|
+
listener.handler.call(target, ev);
|
|
11490
|
+
} catch (err2) {
|
|
11491
|
+
console.error(err2);
|
|
11492
|
+
}
|
|
11493
|
+
});
|
|
11494
|
+
}
|
|
11495
|
+
if (ev.bubbles === false) {
|
|
11496
|
+
return;
|
|
11497
|
+
}
|
|
11498
|
+
if (elm.nodeName === "#document" /* DOCUMENT_NODE */) {
|
|
11499
|
+
triggerEventListener(elm.defaultView, ev);
|
|
11500
|
+
} else if (elm.parentElement == null && elm.tagName === "HTML") {
|
|
11501
|
+
triggerEventListener(elm.ownerDocument, ev);
|
|
11502
|
+
} else {
|
|
11503
|
+
const nextTarget = getNextEventTarget(elm, ev);
|
|
11504
|
+
triggerEventListener(nextTarget, ev);
|
|
11505
|
+
}
|
|
11506
|
+
}
|
|
11507
|
+
function getNextEventTarget(elm, ev) {
|
|
11508
|
+
if (elm.parentElement) {
|
|
11509
|
+
return elm.parentElement;
|
|
11510
|
+
}
|
|
11511
|
+
if (elm.host && ev.composed) {
|
|
11512
|
+
return elm.host;
|
|
11513
|
+
}
|
|
11514
|
+
if (ev.composed && elm.parentNode && elm.parentNode.host) {
|
|
11515
|
+
return elm.parentNode.host;
|
|
11516
|
+
}
|
|
11517
|
+
return null;
|
|
11518
|
+
}
|
|
11519
|
+
function dispatchEvent(currentTarget, ev) {
|
|
11520
|
+
ev.target = currentTarget;
|
|
11521
|
+
triggerEventListener(currentTarget, ev);
|
|
11522
|
+
return true;
|
|
11523
|
+
}
|
|
11524
|
+
|
|
11525
|
+
// node_modules/parse5/dist/common/unicode.js
|
|
11526
|
+
var UNDEFINED_CODE_POINTS = /* @__PURE__ */ new Set([
|
|
11527
|
+
65534,
|
|
11528
|
+
65535,
|
|
11529
|
+
131070,
|
|
11530
|
+
131071,
|
|
11531
|
+
196606,
|
|
11532
|
+
196607,
|
|
11533
|
+
262142,
|
|
11534
|
+
262143,
|
|
11535
|
+
327678,
|
|
11536
|
+
327679,
|
|
11537
|
+
393214,
|
|
11538
|
+
393215,
|
|
11539
|
+
458750,
|
|
11540
|
+
458751,
|
|
11541
|
+
524286,
|
|
11542
|
+
524287,
|
|
11543
|
+
589822,
|
|
11544
|
+
589823,
|
|
11545
|
+
655358,
|
|
11546
|
+
655359,
|
|
11547
|
+
720894,
|
|
11548
|
+
720895,
|
|
11549
|
+
786430,
|
|
11550
|
+
786431,
|
|
11551
|
+
851966,
|
|
11552
|
+
851967,
|
|
11553
|
+
917502,
|
|
11554
|
+
917503,
|
|
11555
|
+
983038,
|
|
11556
|
+
983039,
|
|
11557
|
+
1048574,
|
|
11558
|
+
1048575,
|
|
11559
|
+
1114110,
|
|
11560
|
+
1114111
|
|
11561
|
+
]);
|
|
11562
|
+
var REPLACEMENT_CHARACTER = "\uFFFD";
|
|
11563
|
+
var CODE_POINTS;
|
|
11564
|
+
(function(CODE_POINTS2) {
|
|
11565
|
+
CODE_POINTS2[CODE_POINTS2["EOF"] = -1] = "EOF";
|
|
10830
11566
|
CODE_POINTS2[CODE_POINTS2["NULL"] = 0] = "NULL";
|
|
10831
11567
|
CODE_POINTS2[CODE_POINTS2["TABULATION"] = 9] = "TABULATION";
|
|
10832
11568
|
CODE_POINTS2[CODE_POINTS2["CARRIAGE_RETURN"] = 13] = "CARRIAGE_RETURN";
|
|
@@ -18940,14 +19676,14 @@ var jquery_default = (
|
|
|
18940
19676
|
*
|
|
18941
19677
|
* Date: 2023-12-11T17:55Z
|
|
18942
19678
|
*/
|
|
18943
|
-
function(global2, factory) {
|
|
19679
|
+
(function(global2, factory) {
|
|
18944
19680
|
"use strict";
|
|
18945
19681
|
if (true) {
|
|
18946
19682
|
return factory(global2, true);
|
|
18947
19683
|
} else {
|
|
18948
19684
|
factory(global2);
|
|
18949
19685
|
}
|
|
18950
|
-
}({
|
|
19686
|
+
})({
|
|
18951
19687
|
document: {
|
|
18952
19688
|
createElement() {
|
|
18953
19689
|
return {};
|
|
@@ -20917,10 +21653,10 @@ var MockNode2 = class {
|
|
|
20917
21653
|
insertBefore(newNode, referenceNode) {
|
|
20918
21654
|
if (newNode.nodeType === 11 /* DOCUMENT_FRAGMENT_NODE */) {
|
|
20919
21655
|
for (let i = 0, ii = newNode.childNodes.length; i < ii; i++) {
|
|
20920
|
-
|
|
21656
|
+
insertBefore2(this, newNode.childNodes[i], referenceNode);
|
|
20921
21657
|
}
|
|
20922
21658
|
} else {
|
|
20923
|
-
|
|
21659
|
+
insertBefore2(this, newNode, referenceNode);
|
|
20924
21660
|
}
|
|
20925
21661
|
return newNode;
|
|
20926
21662
|
}
|
|
@@ -21265,13 +22001,13 @@ var MockElement = class extends MockNode2 {
|
|
|
21265
22001
|
}
|
|
21266
22002
|
insertAdjacentElement(position, elm) {
|
|
21267
22003
|
if (position === "beforebegin" && this.parentNode) {
|
|
21268
|
-
|
|
22004
|
+
insertBefore2(this.parentNode, elm, this);
|
|
21269
22005
|
} else if (position === "afterbegin") {
|
|
21270
22006
|
this.prepend(elm);
|
|
21271
22007
|
} else if (position === "beforeend") {
|
|
21272
22008
|
this.appendChild(elm);
|
|
21273
22009
|
} else if (position === "afterend" && this.parentNode) {
|
|
21274
|
-
|
|
22010
|
+
insertBefore2(this.parentNode, elm, this.nextSibling);
|
|
21275
22011
|
}
|
|
21276
22012
|
return elm;
|
|
21277
22013
|
}
|
|
@@ -21280,7 +22016,7 @@ var MockElement = class extends MockNode2 {
|
|
|
21280
22016
|
if (position === "beforebegin") {
|
|
21281
22017
|
while (frag.childNodes.length > 0) {
|
|
21282
22018
|
if (this.parentNode) {
|
|
21283
|
-
|
|
22019
|
+
insertBefore2(this.parentNode, frag.childNodes[0], this);
|
|
21284
22020
|
}
|
|
21285
22021
|
}
|
|
21286
22022
|
} else if (position === "afterbegin") {
|
|
@@ -21294,7 +22030,7 @@ var MockElement = class extends MockNode2 {
|
|
|
21294
22030
|
} else if (position === "afterend") {
|
|
21295
22031
|
while (frag.childNodes.length > 0) {
|
|
21296
22032
|
if (this.parentNode) {
|
|
21297
|
-
|
|
22033
|
+
insertBefore2(this.parentNode, frag.childNodes[frag.childNodes.length - 1], this.nextSibling);
|
|
21298
22034
|
}
|
|
21299
22035
|
}
|
|
21300
22036
|
}
|
|
@@ -21302,13 +22038,13 @@ var MockElement = class extends MockNode2 {
|
|
|
21302
22038
|
insertAdjacentText(position, text) {
|
|
21303
22039
|
const elm = this.ownerDocument.createTextNode(text);
|
|
21304
22040
|
if (position === "beforebegin" && this.parentNode) {
|
|
21305
|
-
|
|
22041
|
+
insertBefore2(this.parentNode, elm, this);
|
|
21306
22042
|
} else if (position === "afterbegin") {
|
|
21307
22043
|
this.prepend(elm);
|
|
21308
22044
|
} else if (position === "beforeend") {
|
|
21309
22045
|
this.appendChild(elm);
|
|
21310
22046
|
} else if (position === "afterend" && this.parentNode) {
|
|
21311
|
-
|
|
22047
|
+
insertBefore2(this.parentNode, elm, this.nextSibling);
|
|
21312
22048
|
}
|
|
21313
22049
|
}
|
|
21314
22050
|
hasAttribute(attrName) {
|
|
@@ -21723,7 +22459,7 @@ function resetElement(elm) {
|
|
|
21723
22459
|
delete elm.__shadowRoot;
|
|
21724
22460
|
delete elm.__style;
|
|
21725
22461
|
}
|
|
21726
|
-
function
|
|
22462
|
+
function insertBefore2(parentNode, newNode, referenceNode) {
|
|
21727
22463
|
if (newNode !== referenceNode) {
|
|
21728
22464
|
newNode.remove();
|
|
21729
22465
|
newNode.parentNode = parentNode;
|
|
@@ -23835,968 +24571,434 @@ var MockWindow = class {
|
|
|
23835
24571
|
}
|
|
23836
24572
|
onpointerout() {
|
|
23837
24573
|
}
|
|
23838
|
-
onpointerover() {
|
|
23839
|
-
}
|
|
23840
|
-
onpointerup() {
|
|
23841
|
-
}
|
|
23842
|
-
onprogress() {
|
|
23843
|
-
}
|
|
23844
|
-
onratechange() {
|
|
23845
|
-
}
|
|
23846
|
-
onreset() {
|
|
23847
|
-
}
|
|
23848
|
-
onresize() {
|
|
23849
|
-
}
|
|
23850
|
-
onscroll() {
|
|
23851
|
-
}
|
|
23852
|
-
onsearch() {
|
|
23853
|
-
}
|
|
23854
|
-
onseeked() {
|
|
23855
|
-
}
|
|
23856
|
-
onseeking() {
|
|
23857
|
-
}
|
|
23858
|
-
onselect() {
|
|
23859
|
-
}
|
|
23860
|
-
onselectstart() {
|
|
23861
|
-
}
|
|
23862
|
-
onstalled() {
|
|
23863
|
-
}
|
|
23864
|
-
onsubmit() {
|
|
23865
|
-
}
|
|
23866
|
-
onsuspend() {
|
|
23867
|
-
}
|
|
23868
|
-
ontimeupdate() {
|
|
23869
|
-
}
|
|
23870
|
-
ontoggle() {
|
|
23871
|
-
}
|
|
23872
|
-
onvolumechange() {
|
|
23873
|
-
}
|
|
23874
|
-
onwaiting() {
|
|
23875
|
-
}
|
|
23876
|
-
onwebkitfullscreenchange() {
|
|
23877
|
-
}
|
|
23878
|
-
onwebkitfullscreenerror() {
|
|
23879
|
-
}
|
|
23880
|
-
onwheel() {
|
|
23881
|
-
}
|
|
23882
|
-
};
|
|
23883
|
-
addGlobalsToWindowPrototype(MockWindow.prototype);
|
|
23884
|
-
function resetWindowDefaults(win2) {
|
|
23885
|
-
win2.__clearInterval = nativeClearInterval;
|
|
23886
|
-
win2.__clearTimeout = nativeClearTimeout;
|
|
23887
|
-
win2.__setInterval = nativeSetInterval;
|
|
23888
|
-
win2.__setTimeout = nativeSetTimeout;
|
|
23889
|
-
win2.__maxTimeout = 6e4;
|
|
23890
|
-
win2.__allowInterval = true;
|
|
23891
|
-
win2.URL = nativeURL;
|
|
23892
|
-
}
|
|
23893
|
-
function cloneWindow(srcWin, opts = {}) {
|
|
23894
|
-
if (srcWin == null) {
|
|
23895
|
-
return null;
|
|
23896
|
-
}
|
|
23897
|
-
const clonedWin = new MockWindow(false);
|
|
23898
|
-
if (!opts.customElementProxy) {
|
|
23899
|
-
srcWin.customElements = null;
|
|
23900
|
-
}
|
|
23901
|
-
if (srcWin.document != null) {
|
|
23902
|
-
const clonedDoc = new MockDocument(false, clonedWin);
|
|
23903
|
-
clonedWin.document = clonedDoc;
|
|
23904
|
-
clonedDoc.documentElement = srcWin.document.documentElement.cloneNode(true);
|
|
23905
|
-
} else {
|
|
23906
|
-
clonedWin.document = new MockDocument(null, clonedWin);
|
|
23907
|
-
}
|
|
23908
|
-
return clonedWin;
|
|
23909
|
-
}
|
|
23910
|
-
function constrainTimeouts(win2) {
|
|
23911
|
-
win2.__allowInterval = false;
|
|
23912
|
-
win2.__maxTimeout = 0;
|
|
23913
|
-
}
|
|
23914
|
-
function resetWindow(win2) {
|
|
23915
|
-
if (win2 != null) {
|
|
23916
|
-
if (win2.__timeouts) {
|
|
23917
|
-
win2.__timeouts.forEach((timeoutId) => {
|
|
23918
|
-
nativeClearInterval(timeoutId);
|
|
23919
|
-
nativeClearTimeout(timeoutId);
|
|
23920
|
-
});
|
|
23921
|
-
win2.__timeouts.clear();
|
|
23922
|
-
}
|
|
23923
|
-
if (win2.customElements && win2.customElements.clear) {
|
|
23924
|
-
win2.customElements.clear();
|
|
23925
|
-
}
|
|
23926
|
-
resetDocument(win2.document);
|
|
23927
|
-
resetPerformance(win2.performance);
|
|
23928
|
-
for (const key in win2) {
|
|
23929
|
-
if (win2.hasOwnProperty(key) && key !== "document" && key !== "performance" && key !== "customElements") {
|
|
23930
|
-
delete win2[key];
|
|
23931
|
-
}
|
|
23932
|
-
}
|
|
23933
|
-
resetWindowDefaults(win2);
|
|
23934
|
-
resetWindowDimensions(win2);
|
|
23935
|
-
resetEventListeners(win2);
|
|
23936
|
-
if (win2.document != null) {
|
|
23937
|
-
try {
|
|
23938
|
-
win2.document.defaultView = win2;
|
|
23939
|
-
} catch (e) {
|
|
23940
|
-
}
|
|
23941
|
-
}
|
|
23942
|
-
win2.fetch = null;
|
|
23943
|
-
win2.Headers = null;
|
|
23944
|
-
win2.Request = null;
|
|
23945
|
-
win2.Response = null;
|
|
23946
|
-
win2.FetchError = null;
|
|
23947
|
-
}
|
|
23948
|
-
}
|
|
23949
|
-
function resetWindowDimensions(win2) {
|
|
23950
|
-
try {
|
|
23951
|
-
win2.devicePixelRatio = 1;
|
|
23952
|
-
win2.innerHeight = 768;
|
|
23953
|
-
win2.innerWidth = 1366;
|
|
23954
|
-
win2.pageXOffset = 0;
|
|
23955
|
-
win2.pageYOffset = 0;
|
|
23956
|
-
win2.screenLeft = 0;
|
|
23957
|
-
win2.screenTop = 0;
|
|
23958
|
-
win2.screenX = 0;
|
|
23959
|
-
win2.screenY = 0;
|
|
23960
|
-
win2.scrollX = 0;
|
|
23961
|
-
win2.scrollY = 0;
|
|
23962
|
-
win2.screen = {
|
|
23963
|
-
availHeight: win2.innerHeight,
|
|
23964
|
-
availLeft: 0,
|
|
23965
|
-
availTop: 0,
|
|
23966
|
-
availWidth: win2.innerWidth,
|
|
23967
|
-
colorDepth: 24,
|
|
23968
|
-
height: win2.innerHeight,
|
|
23969
|
-
keepAwake: false,
|
|
23970
|
-
orientation: {
|
|
23971
|
-
angle: 0,
|
|
23972
|
-
type: "portrait-primary"
|
|
23973
|
-
},
|
|
23974
|
-
pixelDepth: 24,
|
|
23975
|
-
width: win2.innerWidth
|
|
23976
|
-
};
|
|
23977
|
-
} catch (e) {
|
|
23978
|
-
}
|
|
23979
|
-
}
|
|
23980
|
-
|
|
23981
|
-
// src/mock-doc/document.ts
|
|
23982
|
-
var MockDocument = class _MockDocument extends MockHTMLElement {
|
|
23983
|
-
constructor(html = null, win2 = null) {
|
|
23984
|
-
super(null, null);
|
|
23985
|
-
this.nodeName = "#document" /* DOCUMENT_NODE */;
|
|
23986
|
-
this.nodeType = 9 /* DOCUMENT_NODE */;
|
|
23987
|
-
this.defaultView = win2;
|
|
23988
|
-
this.cookie = "";
|
|
23989
|
-
this.referrer = "";
|
|
23990
|
-
this.appendChild(this.createDocumentTypeNode());
|
|
23991
|
-
if (typeof html === "string") {
|
|
23992
|
-
const parsedDoc = parseDocumentUtil(this, html);
|
|
23993
|
-
const documentElement = parsedDoc.children.find((elm) => elm.nodeName === "HTML");
|
|
23994
|
-
if (documentElement != null) {
|
|
23995
|
-
this.appendChild(documentElement);
|
|
23996
|
-
setOwnerDocument(documentElement, this);
|
|
23997
|
-
}
|
|
23998
|
-
} else if (html !== false) {
|
|
23999
|
-
const documentElement = new MockHTMLElement(this, "html");
|
|
24000
|
-
this.appendChild(documentElement);
|
|
24001
|
-
documentElement.appendChild(new MockHTMLElement(this, "head"));
|
|
24002
|
-
documentElement.appendChild(new MockHTMLElement(this, "body"));
|
|
24003
|
-
}
|
|
24004
|
-
}
|
|
24005
|
-
get dir() {
|
|
24006
|
-
return this.documentElement.dir;
|
|
24007
|
-
}
|
|
24008
|
-
set dir(value) {
|
|
24009
|
-
this.documentElement.dir = value;
|
|
24010
|
-
}
|
|
24011
|
-
get localName() {
|
|
24012
|
-
throw new Error("Unimplemented");
|
|
24013
|
-
}
|
|
24014
|
-
get location() {
|
|
24015
|
-
if (this.defaultView != null) {
|
|
24016
|
-
return this.defaultView.location;
|
|
24017
|
-
}
|
|
24018
|
-
return null;
|
|
24019
|
-
}
|
|
24020
|
-
set location(val) {
|
|
24021
|
-
if (this.defaultView != null) {
|
|
24022
|
-
this.defaultView.location.href = val;
|
|
24023
|
-
}
|
|
24024
|
-
}
|
|
24025
|
-
get baseURI() {
|
|
24026
|
-
const baseNode = this.head.childNodes.find((node) => node.nodeName === "BASE");
|
|
24027
|
-
if (baseNode) {
|
|
24028
|
-
return baseNode.href;
|
|
24029
|
-
}
|
|
24030
|
-
return this.URL;
|
|
24031
|
-
}
|
|
24032
|
-
get URL() {
|
|
24033
|
-
return this.location.href;
|
|
24034
|
-
}
|
|
24035
|
-
get styleSheets() {
|
|
24036
|
-
return this.querySelectorAll("style");
|
|
24037
|
-
}
|
|
24038
|
-
get scripts() {
|
|
24039
|
-
return this.querySelectorAll("script");
|
|
24040
|
-
}
|
|
24041
|
-
get forms() {
|
|
24042
|
-
return this.querySelectorAll("form");
|
|
24043
|
-
}
|
|
24044
|
-
get images() {
|
|
24045
|
-
return this.querySelectorAll("img");
|
|
24046
|
-
}
|
|
24047
|
-
get scrollingElement() {
|
|
24048
|
-
return this.documentElement;
|
|
24049
|
-
}
|
|
24050
|
-
get documentElement() {
|
|
24051
|
-
for (let i = this.childNodes.length - 1; i >= 0; i--) {
|
|
24052
|
-
if (this.childNodes[i].nodeName === "HTML") {
|
|
24053
|
-
return this.childNodes[i];
|
|
24054
|
-
}
|
|
24055
|
-
}
|
|
24056
|
-
const documentElement = new MockHTMLElement(this, "html");
|
|
24057
|
-
this.appendChild(documentElement);
|
|
24058
|
-
return documentElement;
|
|
24574
|
+
onpointerover() {
|
|
24059
24575
|
}
|
|
24060
|
-
|
|
24061
|
-
for (let i = this.childNodes.length - 1; i >= 0; i--) {
|
|
24062
|
-
if (this.childNodes[i].nodeType !== 10 /* DOCUMENT_TYPE_NODE */) {
|
|
24063
|
-
this.childNodes[i].remove();
|
|
24064
|
-
}
|
|
24065
|
-
}
|
|
24066
|
-
if (documentElement != null) {
|
|
24067
|
-
this.appendChild(documentElement);
|
|
24068
|
-
setOwnerDocument(documentElement, this);
|
|
24069
|
-
}
|
|
24576
|
+
onpointerup() {
|
|
24070
24577
|
}
|
|
24071
|
-
|
|
24072
|
-
const documentElement = this.documentElement;
|
|
24073
|
-
for (let i = 0; i < documentElement.childNodes.length; i++) {
|
|
24074
|
-
if (documentElement.childNodes[i].nodeName === "HEAD") {
|
|
24075
|
-
return documentElement.childNodes[i];
|
|
24076
|
-
}
|
|
24077
|
-
}
|
|
24078
|
-
const head = new MockHTMLElement(this, "head");
|
|
24079
|
-
documentElement.insertBefore(head, documentElement.firstChild);
|
|
24080
|
-
return head;
|
|
24578
|
+
onprogress() {
|
|
24081
24579
|
}
|
|
24082
|
-
|
|
24083
|
-
const documentElement = this.documentElement;
|
|
24084
|
-
for (let i = documentElement.childNodes.length - 1; i >= 0; i--) {
|
|
24085
|
-
if (documentElement.childNodes[i].nodeName === "HEAD") {
|
|
24086
|
-
documentElement.childNodes[i].remove();
|
|
24087
|
-
}
|
|
24088
|
-
}
|
|
24089
|
-
if (head != null) {
|
|
24090
|
-
documentElement.insertBefore(head, documentElement.firstChild);
|
|
24091
|
-
setOwnerDocument(head, this);
|
|
24092
|
-
}
|
|
24580
|
+
onratechange() {
|
|
24093
24581
|
}
|
|
24094
|
-
|
|
24095
|
-
const documentElement = this.documentElement;
|
|
24096
|
-
for (let i = documentElement.childNodes.length - 1; i >= 0; i--) {
|
|
24097
|
-
if (documentElement.childNodes[i].nodeName === "BODY") {
|
|
24098
|
-
return documentElement.childNodes[i];
|
|
24099
|
-
}
|
|
24100
|
-
}
|
|
24101
|
-
const body = new MockHTMLElement(this, "body");
|
|
24102
|
-
documentElement.appendChild(body);
|
|
24103
|
-
return body;
|
|
24582
|
+
onreset() {
|
|
24104
24583
|
}
|
|
24105
|
-
|
|
24106
|
-
const documentElement = this.documentElement;
|
|
24107
|
-
for (let i = documentElement.childNodes.length - 1; i >= 0; i--) {
|
|
24108
|
-
if (documentElement.childNodes[i].nodeName === "BODY") {
|
|
24109
|
-
documentElement.childNodes[i].remove();
|
|
24110
|
-
}
|
|
24111
|
-
}
|
|
24112
|
-
if (body != null) {
|
|
24113
|
-
documentElement.appendChild(body);
|
|
24114
|
-
setOwnerDocument(body, this);
|
|
24115
|
-
}
|
|
24584
|
+
onresize() {
|
|
24116
24585
|
}
|
|
24117
|
-
|
|
24118
|
-
newNode.remove();
|
|
24119
|
-
newNode.parentNode = this;
|
|
24120
|
-
this.childNodes.push(newNode);
|
|
24121
|
-
return newNode;
|
|
24586
|
+
onscroll() {
|
|
24122
24587
|
}
|
|
24123
|
-
|
|
24124
|
-
return new MockComment(this, data);
|
|
24588
|
+
onsearch() {
|
|
24125
24589
|
}
|
|
24126
|
-
|
|
24127
|
-
return new MockAttr(attrName.toLowerCase(), "");
|
|
24590
|
+
onseeked() {
|
|
24128
24591
|
}
|
|
24129
|
-
|
|
24130
|
-
return new MockAttr(attrName, "", namespaceURI);
|
|
24592
|
+
onseeking() {
|
|
24131
24593
|
}
|
|
24132
|
-
|
|
24133
|
-
if (tagName === "#document" /* DOCUMENT_NODE */) {
|
|
24134
|
-
const doc = new _MockDocument(false);
|
|
24135
|
-
doc.nodeName = tagName;
|
|
24136
|
-
doc.parentNode = null;
|
|
24137
|
-
return doc;
|
|
24138
|
-
}
|
|
24139
|
-
return createElement(this, tagName);
|
|
24594
|
+
onselect() {
|
|
24140
24595
|
}
|
|
24141
|
-
|
|
24142
|
-
const elmNs = createElementNS(this, namespaceURI, tagName);
|
|
24143
|
-
return elmNs;
|
|
24596
|
+
onselectstart() {
|
|
24144
24597
|
}
|
|
24145
|
-
|
|
24146
|
-
return new MockTextNode(this, text);
|
|
24598
|
+
onstalled() {
|
|
24147
24599
|
}
|
|
24148
|
-
|
|
24149
|
-
return new MockDocumentFragment(this);
|
|
24600
|
+
onsubmit() {
|
|
24150
24601
|
}
|
|
24151
|
-
|
|
24152
|
-
return new MockDocumentTypeNode(this);
|
|
24602
|
+
onsuspend() {
|
|
24153
24603
|
}
|
|
24154
|
-
|
|
24155
|
-
return getElementById(this, id);
|
|
24604
|
+
ontimeupdate() {
|
|
24156
24605
|
}
|
|
24157
|
-
|
|
24158
|
-
return getElementsByName(this, elmName.toLowerCase());
|
|
24606
|
+
ontoggle() {
|
|
24159
24607
|
}
|
|
24160
|
-
|
|
24161
|
-
const title = this.head.childNodes.find((elm) => elm.nodeName === "TITLE");
|
|
24162
|
-
if (title != null && typeof title.textContent === "string") {
|
|
24163
|
-
return title.textContent.trim();
|
|
24164
|
-
}
|
|
24165
|
-
return "";
|
|
24608
|
+
onvolumechange() {
|
|
24166
24609
|
}
|
|
24167
|
-
|
|
24168
|
-
|
|
24169
|
-
|
|
24170
|
-
|
|
24171
|
-
|
|
24172
|
-
|
|
24173
|
-
|
|
24174
|
-
title.textContent = value;
|
|
24610
|
+
onwaiting() {
|
|
24611
|
+
}
|
|
24612
|
+
onwebkitfullscreenchange() {
|
|
24613
|
+
}
|
|
24614
|
+
onwebkitfullscreenerror() {
|
|
24615
|
+
}
|
|
24616
|
+
onwheel() {
|
|
24175
24617
|
}
|
|
24176
24618
|
};
|
|
24177
|
-
|
|
24178
|
-
|
|
24179
|
-
|
|
24180
|
-
|
|
24181
|
-
|
|
24182
|
-
|
|
24183
|
-
|
|
24184
|
-
|
|
24185
|
-
|
|
24186
|
-
|
|
24187
|
-
|
|
24188
|
-
|
|
24189
|
-
|
|
24190
|
-
|
|
24191
|
-
|
|
24192
|
-
|
|
24193
|
-
|
|
24194
|
-
|
|
24195
|
-
|
|
24196
|
-
|
|
24197
|
-
|
|
24198
|
-
|
|
24199
|
-
|
|
24200
|
-
|
|
24201
|
-
}
|
|
24202
|
-
try {
|
|
24203
|
-
doc.cookie = "";
|
|
24204
|
-
} catch (e) {
|
|
24205
|
-
}
|
|
24206
|
-
try {
|
|
24207
|
-
doc.referrer = "";
|
|
24208
|
-
} catch (e) {
|
|
24209
|
-
}
|
|
24619
|
+
addGlobalsToWindowPrototype(MockWindow.prototype);
|
|
24620
|
+
function resetWindowDefaults(win2) {
|
|
24621
|
+
win2.__clearInterval = nativeClearInterval;
|
|
24622
|
+
win2.__clearTimeout = nativeClearTimeout;
|
|
24623
|
+
win2.__setInterval = nativeSetInterval;
|
|
24624
|
+
win2.__setTimeout = nativeSetTimeout;
|
|
24625
|
+
win2.__maxTimeout = 6e4;
|
|
24626
|
+
win2.__allowInterval = true;
|
|
24627
|
+
win2.URL = nativeURL;
|
|
24628
|
+
}
|
|
24629
|
+
function cloneWindow(srcWin, opts = {}) {
|
|
24630
|
+
if (srcWin == null) {
|
|
24631
|
+
return null;
|
|
24632
|
+
}
|
|
24633
|
+
const clonedWin = new MockWindow(false);
|
|
24634
|
+
if (!opts.customElementProxy) {
|
|
24635
|
+
srcWin.customElements = null;
|
|
24636
|
+
}
|
|
24637
|
+
if (srcWin.document != null) {
|
|
24638
|
+
const clonedDoc = new MockDocument(false, clonedWin);
|
|
24639
|
+
clonedWin.document = clonedDoc;
|
|
24640
|
+
clonedDoc.documentElement = srcWin.document.documentElement.cloneNode(true);
|
|
24641
|
+
} else {
|
|
24642
|
+
clonedWin.document = new MockDocument(null, clonedWin);
|
|
24210
24643
|
}
|
|
24644
|
+
return clonedWin;
|
|
24211
24645
|
}
|
|
24212
|
-
|
|
24213
|
-
|
|
24214
|
-
|
|
24215
|
-
|
|
24216
|
-
|
|
24217
|
-
|
|
24218
|
-
|
|
24219
|
-
|
|
24220
|
-
|
|
24221
|
-
|
|
24222
|
-
|
|
24223
|
-
|
|
24224
|
-
const childElm = children[i];
|
|
24225
|
-
if (childElm.id === id) {
|
|
24226
|
-
return childElm;
|
|
24646
|
+
function constrainTimeouts(win2) {
|
|
24647
|
+
win2.__allowInterval = false;
|
|
24648
|
+
win2.__maxTimeout = 0;
|
|
24649
|
+
}
|
|
24650
|
+
function resetWindow(win2) {
|
|
24651
|
+
if (win2 != null) {
|
|
24652
|
+
if (win2.__timeouts) {
|
|
24653
|
+
win2.__timeouts.forEach((timeoutId) => {
|
|
24654
|
+
nativeClearInterval(timeoutId);
|
|
24655
|
+
nativeClearTimeout(timeoutId);
|
|
24656
|
+
});
|
|
24657
|
+
win2.__timeouts.clear();
|
|
24227
24658
|
}
|
|
24228
|
-
|
|
24229
|
-
|
|
24230
|
-
return childElmFound;
|
|
24659
|
+
if (win2.customElements && win2.customElements.clear) {
|
|
24660
|
+
win2.customElements.clear();
|
|
24231
24661
|
}
|
|
24232
|
-
|
|
24233
|
-
|
|
24234
|
-
|
|
24235
|
-
|
|
24236
|
-
|
|
24237
|
-
|
|
24238
|
-
const childElm = children[i];
|
|
24239
|
-
if (childElm.name && childElm.name.toLowerCase() === elmName) {
|
|
24240
|
-
foundElms.push(childElm);
|
|
24662
|
+
resetDocument(win2.document);
|
|
24663
|
+
resetPerformance(win2.performance);
|
|
24664
|
+
for (const key in win2) {
|
|
24665
|
+
if (win2.hasOwnProperty(key) && key !== "document" && key !== "performance" && key !== "customElements") {
|
|
24666
|
+
delete win2[key];
|
|
24667
|
+
}
|
|
24241
24668
|
}
|
|
24242
|
-
|
|
24243
|
-
|
|
24244
|
-
|
|
24245
|
-
|
|
24246
|
-
|
|
24247
|
-
|
|
24248
|
-
|
|
24249
|
-
|
|
24250
|
-
setOwnerDocument(elm.childNodes[i], ownerDocument);
|
|
24669
|
+
resetWindowDefaults(win2);
|
|
24670
|
+
resetWindowDimensions(win2);
|
|
24671
|
+
resetEventListeners(win2);
|
|
24672
|
+
if (win2.document != null) {
|
|
24673
|
+
try {
|
|
24674
|
+
win2.document.defaultView = win2;
|
|
24675
|
+
} catch (e) {
|
|
24676
|
+
}
|
|
24251
24677
|
}
|
|
24678
|
+
win2.fetch = null;
|
|
24679
|
+
win2.Headers = null;
|
|
24680
|
+
win2.Request = null;
|
|
24681
|
+
win2.Response = null;
|
|
24682
|
+
win2.FetchError = null;
|
|
24252
24683
|
}
|
|
24253
24684
|
}
|
|
24254
|
-
|
|
24255
|
-
// src/hydrate/runner/create-window.ts
|
|
24256
|
-
var templateWindows = /* @__PURE__ */ new Map();
|
|
24257
|
-
function createWindowFromHtml(templateHtml, uniqueId) {
|
|
24258
|
-
let templateWindow = templateWindows.get(uniqueId);
|
|
24259
|
-
if (templateWindow == null) {
|
|
24260
|
-
templateWindow = new MockWindow(templateHtml);
|
|
24261
|
-
templateWindows.set(uniqueId, templateWindow);
|
|
24262
|
-
}
|
|
24263
|
-
const win2 = cloneWindow(templateWindow);
|
|
24264
|
-
return win2;
|
|
24265
|
-
}
|
|
24266
|
-
var Build = {
|
|
24267
|
-
isDev: BUILD.isDev ? true : false,
|
|
24268
|
-
isBrowser: true,
|
|
24269
|
-
isServer: false,
|
|
24270
|
-
isTesting: BUILD.isTesting ? true : false
|
|
24271
|
-
};
|
|
24272
|
-
|
|
24273
|
-
// src/utils/constants.ts
|
|
24274
|
-
var PrimitiveType = /* @__PURE__ */ ((PrimitiveType2) => {
|
|
24275
|
-
PrimitiveType2["Undefined"] = "undefined";
|
|
24276
|
-
PrimitiveType2["Null"] = "null";
|
|
24277
|
-
PrimitiveType2["String"] = "string";
|
|
24278
|
-
PrimitiveType2["Number"] = "number";
|
|
24279
|
-
PrimitiveType2["SpecialNumber"] = "number";
|
|
24280
|
-
PrimitiveType2["Boolean"] = "boolean";
|
|
24281
|
-
PrimitiveType2["BigInt"] = "bigint";
|
|
24282
|
-
return PrimitiveType2;
|
|
24283
|
-
})(PrimitiveType || {});
|
|
24284
|
-
var NonPrimitiveType = /* @__PURE__ */ ((NonPrimitiveType2) => {
|
|
24285
|
-
NonPrimitiveType2["Array"] = "array";
|
|
24286
|
-
NonPrimitiveType2["Date"] = "date";
|
|
24287
|
-
NonPrimitiveType2["Map"] = "map";
|
|
24288
|
-
NonPrimitiveType2["Object"] = "object";
|
|
24289
|
-
NonPrimitiveType2["RegularExpression"] = "regexp";
|
|
24290
|
-
NonPrimitiveType2["Set"] = "set";
|
|
24291
|
-
NonPrimitiveType2["Channel"] = "channel";
|
|
24292
|
-
NonPrimitiveType2["Symbol"] = "symbol";
|
|
24293
|
-
return NonPrimitiveType2;
|
|
24294
|
-
})(NonPrimitiveType || {});
|
|
24295
|
-
var TYPE_CONSTANT = "type";
|
|
24296
|
-
var VALUE_CONSTANT = "value";
|
|
24297
|
-
var SERIALIZED_PREFIX = "serialized:";
|
|
24298
|
-
var STENCIL_DEV_MODE = BUILD.isTesting ? ["STENCIL:"] : [
|
|
24299
|
-
"%cstencil",
|
|
24300
|
-
"color: white;background:#4c47ff;font-weight: bold; font-size:10px; padding:2px 6px; border-radius: 5px"
|
|
24301
|
-
];
|
|
24302
|
-
var win = typeof window !== "undefined" ? window : {};
|
|
24303
|
-
var H = win.HTMLElement || class {
|
|
24304
|
-
};
|
|
24305
|
-
var supportsShadow = BUILD.shadowDom;
|
|
24306
|
-
var supportsConstructableStylesheets = BUILD.constructableCSS ? /* @__PURE__ */ (() => {
|
|
24685
|
+
function resetWindowDimensions(win2) {
|
|
24307
24686
|
try {
|
|
24308
|
-
|
|
24309
|
-
|
|
24687
|
+
win2.devicePixelRatio = 1;
|
|
24688
|
+
win2.innerHeight = 768;
|
|
24689
|
+
win2.innerWidth = 1366;
|
|
24690
|
+
win2.pageXOffset = 0;
|
|
24691
|
+
win2.pageYOffset = 0;
|
|
24692
|
+
win2.screenLeft = 0;
|
|
24693
|
+
win2.screenTop = 0;
|
|
24694
|
+
win2.screenX = 0;
|
|
24695
|
+
win2.screenY = 0;
|
|
24696
|
+
win2.scrollX = 0;
|
|
24697
|
+
win2.scrollY = 0;
|
|
24698
|
+
win2.screen = {
|
|
24699
|
+
availHeight: win2.innerHeight,
|
|
24700
|
+
availLeft: 0,
|
|
24701
|
+
availTop: 0,
|
|
24702
|
+
availWidth: win2.innerWidth,
|
|
24703
|
+
colorDepth: 24,
|
|
24704
|
+
height: win2.innerHeight,
|
|
24705
|
+
keepAwake: false,
|
|
24706
|
+
orientation: {
|
|
24707
|
+
angle: 0,
|
|
24708
|
+
type: "portrait-primary"
|
|
24709
|
+
},
|
|
24710
|
+
pixelDepth: 24,
|
|
24711
|
+
width: win2.innerWidth
|
|
24712
|
+
};
|
|
24310
24713
|
} catch (e) {
|
|
24311
24714
|
}
|
|
24312
|
-
|
|
24313
|
-
})() : false;
|
|
24314
|
-
|
|
24315
|
-
// src/utils/helpers.ts
|
|
24316
|
-
var isString = (v) => typeof v === "string";
|
|
24715
|
+
}
|
|
24317
24716
|
|
|
24318
|
-
// src/
|
|
24319
|
-
var
|
|
24320
|
-
constructor(
|
|
24321
|
-
|
|
24322
|
-
|
|
24323
|
-
|
|
24324
|
-
|
|
24325
|
-
|
|
24717
|
+
// src/mock-doc/document.ts
|
|
24718
|
+
var MockDocument = class _MockDocument extends MockHTMLElement {
|
|
24719
|
+
constructor(html = null, win2 = null) {
|
|
24720
|
+
super(null, null);
|
|
24721
|
+
this.nodeName = "#document" /* DOCUMENT_NODE */;
|
|
24722
|
+
this.nodeType = 9 /* DOCUMENT_NODE */;
|
|
24723
|
+
this.defaultView = win2;
|
|
24724
|
+
this.cookie = "";
|
|
24725
|
+
this.referrer = "";
|
|
24726
|
+
this.appendChild(this.createDocumentTypeNode());
|
|
24727
|
+
if (typeof html === "string") {
|
|
24728
|
+
const parsedDoc = parseDocumentUtil(this, html);
|
|
24729
|
+
const documentElement = parsedDoc.children.find((elm) => elm.nodeName === "HTML");
|
|
24730
|
+
if (documentElement != null) {
|
|
24731
|
+
this.appendChild(documentElement);
|
|
24732
|
+
setOwnerDocument(documentElement, this);
|
|
24733
|
+
}
|
|
24734
|
+
} else if (html !== false) {
|
|
24735
|
+
const documentElement = new MockHTMLElement(this, "html");
|
|
24736
|
+
this.appendChild(documentElement);
|
|
24737
|
+
documentElement.appendChild(new MockHTMLElement(this, "head"));
|
|
24738
|
+
documentElement.appendChild(new MockHTMLElement(this, "body"));
|
|
24326
24739
|
}
|
|
24327
24740
|
}
|
|
24328
|
-
|
|
24329
|
-
|
|
24330
|
-
*
|
|
24331
|
-
* @param {string} value - The string value to be stored in the LocalValue object.
|
|
24332
|
-
* @returns {LocalValue} - The created LocalValue object.
|
|
24333
|
-
*/
|
|
24334
|
-
static createStringValue(value) {
|
|
24335
|
-
return new _LocalValue("string" /* String */, value);
|
|
24741
|
+
get dir() {
|
|
24742
|
+
return this.documentElement.dir;
|
|
24336
24743
|
}
|
|
24337
|
-
|
|
24338
|
-
|
|
24339
|
-
*
|
|
24340
|
-
* @param {number} value - The number value.
|
|
24341
|
-
* @returns {LocalValue} - The created LocalValue object.
|
|
24342
|
-
*/
|
|
24343
|
-
static createNumberValue(value) {
|
|
24344
|
-
return new _LocalValue("number" /* Number */, value);
|
|
24744
|
+
set dir(value) {
|
|
24745
|
+
this.documentElement.dir = value;
|
|
24345
24746
|
}
|
|
24346
|
-
|
|
24347
|
-
|
|
24348
|
-
*
|
|
24349
|
-
* @param {number} value - The value of the special number.
|
|
24350
|
-
* @returns {LocalValue} - The created LocalValue object.
|
|
24351
|
-
*/
|
|
24352
|
-
static createSpecialNumberValue(value) {
|
|
24353
|
-
if (Number.isNaN(value)) {
|
|
24354
|
-
return new _LocalValue("number" /* SpecialNumber */, "NaN");
|
|
24355
|
-
}
|
|
24356
|
-
if (Object.is(value, -0)) {
|
|
24357
|
-
return new _LocalValue("number" /* SpecialNumber */, "-0");
|
|
24358
|
-
}
|
|
24359
|
-
if (value === Infinity) {
|
|
24360
|
-
return new _LocalValue("number" /* SpecialNumber */, "Infinity");
|
|
24361
|
-
}
|
|
24362
|
-
if (value === -Infinity) {
|
|
24363
|
-
return new _LocalValue("number" /* SpecialNumber */, "-Infinity");
|
|
24364
|
-
}
|
|
24365
|
-
return new _LocalValue("number" /* SpecialNumber */, value);
|
|
24747
|
+
get localName() {
|
|
24748
|
+
throw new Error("Unimplemented");
|
|
24366
24749
|
}
|
|
24367
|
-
|
|
24368
|
-
|
|
24369
|
-
|
|
24370
|
-
|
|
24371
|
-
|
|
24372
|
-
return new _LocalValue("undefined" /* Undefined */);
|
|
24750
|
+
get location() {
|
|
24751
|
+
if (this.defaultView != null) {
|
|
24752
|
+
return this.defaultView.location;
|
|
24753
|
+
}
|
|
24754
|
+
return null;
|
|
24373
24755
|
}
|
|
24374
|
-
|
|
24375
|
-
|
|
24376
|
-
|
|
24377
|
-
|
|
24378
|
-
static createNullValue() {
|
|
24379
|
-
return new _LocalValue("null" /* Null */);
|
|
24756
|
+
set location(val) {
|
|
24757
|
+
if (this.defaultView != null) {
|
|
24758
|
+
this.defaultView.location.href = val;
|
|
24759
|
+
}
|
|
24380
24760
|
}
|
|
24381
|
-
|
|
24382
|
-
|
|
24383
|
-
|
|
24384
|
-
|
|
24385
|
-
|
|
24386
|
-
|
|
24387
|
-
static createBooleanValue(value) {
|
|
24388
|
-
return new _LocalValue("boolean" /* Boolean */, value);
|
|
24761
|
+
get baseURI() {
|
|
24762
|
+
const baseNode = this.head.childNodes.find((node) => node.nodeName === "BASE");
|
|
24763
|
+
if (baseNode) {
|
|
24764
|
+
return baseNode.href;
|
|
24765
|
+
}
|
|
24766
|
+
return this.URL;
|
|
24389
24767
|
}
|
|
24390
|
-
|
|
24391
|
-
|
|
24392
|
-
*
|
|
24393
|
-
* @param {BigInt} value - The BigInt value.
|
|
24394
|
-
* @returns {LocalValue} - The created LocalValue object.
|
|
24395
|
-
*/
|
|
24396
|
-
static createBigIntValue(value) {
|
|
24397
|
-
return new _LocalValue("bigint" /* BigInt */, value.toString());
|
|
24768
|
+
get URL() {
|
|
24769
|
+
return this.location.href;
|
|
24398
24770
|
}
|
|
24399
|
-
|
|
24400
|
-
|
|
24401
|
-
*
|
|
24402
|
-
* @param {Array} value - The array.
|
|
24403
|
-
* @returns {LocalValue} - The created LocalValue object.
|
|
24404
|
-
*/
|
|
24405
|
-
static createArrayValue(value) {
|
|
24406
|
-
return new _LocalValue("array" /* Array */, value);
|
|
24771
|
+
get styleSheets() {
|
|
24772
|
+
return this.querySelectorAll("style");
|
|
24407
24773
|
}
|
|
24408
|
-
|
|
24409
|
-
|
|
24410
|
-
*
|
|
24411
|
-
* @param {string} value - The date.
|
|
24412
|
-
* @returns {LocalValue} - The created LocalValue object.
|
|
24413
|
-
*/
|
|
24414
|
-
static createDateValue(value) {
|
|
24415
|
-
return new _LocalValue("date" /* Date */, value);
|
|
24774
|
+
get scripts() {
|
|
24775
|
+
return this.querySelectorAll("script");
|
|
24416
24776
|
}
|
|
24417
|
-
|
|
24418
|
-
|
|
24419
|
-
* @param {Map} map - The map.
|
|
24420
|
-
* @returns {LocalValue} - The created LocalValue object.
|
|
24421
|
-
*/
|
|
24422
|
-
static createMapValue(map2) {
|
|
24423
|
-
const value = [];
|
|
24424
|
-
Array.from(map2.entries()).forEach(([key, val]) => {
|
|
24425
|
-
value.push([_LocalValue.getArgument(key), _LocalValue.getArgument(val)]);
|
|
24426
|
-
});
|
|
24427
|
-
return new _LocalValue("map" /* Map */, value);
|
|
24777
|
+
get forms() {
|
|
24778
|
+
return this.querySelectorAll("form");
|
|
24428
24779
|
}
|
|
24429
|
-
|
|
24430
|
-
|
|
24431
|
-
*
|
|
24432
|
-
* @param object the object to create a LocalValue from
|
|
24433
|
-
* @returns {LocalValue} - The created LocalValue object.
|
|
24434
|
-
*/
|
|
24435
|
-
static createObjectValue(object) {
|
|
24436
|
-
const value = [];
|
|
24437
|
-
Object.entries(object).forEach(([key, val]) => {
|
|
24438
|
-
value.push([key, _LocalValue.getArgument(val)]);
|
|
24439
|
-
});
|
|
24440
|
-
return new _LocalValue("object" /* Object */, value);
|
|
24780
|
+
get images() {
|
|
24781
|
+
return this.querySelectorAll("img");
|
|
24441
24782
|
}
|
|
24442
|
-
|
|
24443
|
-
|
|
24444
|
-
*
|
|
24445
|
-
* @param {string} value - The value of the regular expression.
|
|
24446
|
-
* @returns {LocalValue} - The created LocalValue object.
|
|
24447
|
-
*/
|
|
24448
|
-
static createRegularExpressionValue(value) {
|
|
24449
|
-
return new _LocalValue("regexp" /* RegularExpression */, value);
|
|
24783
|
+
get scrollingElement() {
|
|
24784
|
+
return this.documentElement;
|
|
24450
24785
|
}
|
|
24451
|
-
|
|
24452
|
-
|
|
24453
|
-
|
|
24454
|
-
|
|
24455
|
-
|
|
24456
|
-
|
|
24457
|
-
|
|
24786
|
+
get documentElement() {
|
|
24787
|
+
for (let i = this.childNodes.length - 1; i >= 0; i--) {
|
|
24788
|
+
if (this.childNodes[i].nodeName === "HTML") {
|
|
24789
|
+
return this.childNodes[i];
|
|
24790
|
+
}
|
|
24791
|
+
}
|
|
24792
|
+
const documentElement = new MockHTMLElement(this, "html");
|
|
24793
|
+
this.appendChild(documentElement);
|
|
24794
|
+
return documentElement;
|
|
24458
24795
|
}
|
|
24459
|
-
|
|
24460
|
-
|
|
24461
|
-
|
|
24462
|
-
|
|
24463
|
-
|
|
24464
|
-
|
|
24465
|
-
|
|
24466
|
-
|
|
24796
|
+
set documentElement(documentElement) {
|
|
24797
|
+
for (let i = this.childNodes.length - 1; i >= 0; i--) {
|
|
24798
|
+
if (this.childNodes[i].nodeType !== 10 /* DOCUMENT_TYPE_NODE */) {
|
|
24799
|
+
this.childNodes[i].remove();
|
|
24800
|
+
}
|
|
24801
|
+
}
|
|
24802
|
+
if (documentElement != null) {
|
|
24803
|
+
this.appendChild(documentElement);
|
|
24804
|
+
setOwnerDocument(documentElement, this);
|
|
24805
|
+
}
|
|
24467
24806
|
}
|
|
24468
|
-
|
|
24469
|
-
|
|
24470
|
-
|
|
24471
|
-
|
|
24472
|
-
|
|
24473
|
-
|
|
24474
|
-
|
|
24475
|
-
const
|
|
24476
|
-
|
|
24807
|
+
get head() {
|
|
24808
|
+
const documentElement = this.documentElement;
|
|
24809
|
+
for (let i = 0; i < documentElement.childNodes.length; i++) {
|
|
24810
|
+
if (documentElement.childNodes[i].nodeName === "HEAD") {
|
|
24811
|
+
return documentElement.childNodes[i];
|
|
24812
|
+
}
|
|
24813
|
+
}
|
|
24814
|
+
const head = new MockHTMLElement(this, "head");
|
|
24815
|
+
documentElement.insertBefore(head, documentElement.firstChild);
|
|
24816
|
+
return head;
|
|
24477
24817
|
}
|
|
24478
|
-
|
|
24479
|
-
const
|
|
24480
|
-
|
|
24481
|
-
|
|
24482
|
-
|
|
24483
|
-
|
|
24484
|
-
|
|
24485
|
-
|
|
24486
|
-
|
|
24487
|
-
|
|
24488
|
-
case "boolean" /* Boolean */:
|
|
24489
|
-
return _LocalValue.createBooleanValue(argument);
|
|
24490
|
-
case "bigint" /* BigInt */:
|
|
24491
|
-
return _LocalValue.createBigIntValue(argument);
|
|
24492
|
-
case "undefined" /* Undefined */:
|
|
24493
|
-
return _LocalValue.createUndefinedValue();
|
|
24494
|
-
case "symbol" /* Symbol */:
|
|
24495
|
-
return _LocalValue.createSymbolValue(argument);
|
|
24496
|
-
case "object" /* Object */:
|
|
24497
|
-
if (argument === null) {
|
|
24498
|
-
return _LocalValue.createNullValue();
|
|
24499
|
-
}
|
|
24500
|
-
if (argument instanceof Date) {
|
|
24501
|
-
return _LocalValue.createDateValue(argument);
|
|
24502
|
-
}
|
|
24503
|
-
if (argument instanceof Map) {
|
|
24504
|
-
const map2 = [];
|
|
24505
|
-
argument.forEach((value, key) => {
|
|
24506
|
-
const objectKey = typeof key === "string" ? key : _LocalValue.getArgument(key);
|
|
24507
|
-
const objectValue = _LocalValue.getArgument(value);
|
|
24508
|
-
map2.push([objectKey, objectValue]);
|
|
24509
|
-
});
|
|
24510
|
-
return _LocalValue.createMapValue(argument);
|
|
24511
|
-
}
|
|
24512
|
-
if (argument instanceof Set) {
|
|
24513
|
-
const set = [];
|
|
24514
|
-
argument.forEach((value) => {
|
|
24515
|
-
set.push(_LocalValue.getArgument(value));
|
|
24516
|
-
});
|
|
24517
|
-
return _LocalValue.createSetValue(set);
|
|
24518
|
-
}
|
|
24519
|
-
if (argument instanceof Array) {
|
|
24520
|
-
const arr = [];
|
|
24521
|
-
argument.forEach((value) => {
|
|
24522
|
-
arr.push(_LocalValue.getArgument(value));
|
|
24523
|
-
});
|
|
24524
|
-
return _LocalValue.createArrayValue(arr);
|
|
24525
|
-
}
|
|
24526
|
-
if (argument instanceof RegExp) {
|
|
24527
|
-
return _LocalValue.createRegularExpressionValue({
|
|
24528
|
-
pattern: argument.source,
|
|
24529
|
-
flags: argument.flags
|
|
24530
|
-
});
|
|
24531
|
-
}
|
|
24532
|
-
return _LocalValue.createObjectValue(argument);
|
|
24818
|
+
set head(head) {
|
|
24819
|
+
const documentElement = this.documentElement;
|
|
24820
|
+
for (let i = documentElement.childNodes.length - 1; i >= 0; i--) {
|
|
24821
|
+
if (documentElement.childNodes[i].nodeName === "HEAD") {
|
|
24822
|
+
documentElement.childNodes[i].remove();
|
|
24823
|
+
}
|
|
24824
|
+
}
|
|
24825
|
+
if (head != null) {
|
|
24826
|
+
documentElement.insertBefore(head, documentElement.firstChild);
|
|
24827
|
+
setOwnerDocument(head, this);
|
|
24533
24828
|
}
|
|
24534
|
-
throw new Error(`Unsupported type: ${type}`);
|
|
24535
24829
|
}
|
|
24536
|
-
|
|
24537
|
-
|
|
24538
|
-
|
|
24539
|
-
|
|
24540
|
-
|
|
24830
|
+
get body() {
|
|
24831
|
+
const documentElement = this.documentElement;
|
|
24832
|
+
for (let i = documentElement.childNodes.length - 1; i >= 0; i--) {
|
|
24833
|
+
if (documentElement.childNodes[i].nodeName === "BODY") {
|
|
24834
|
+
return documentElement.childNodes[i];
|
|
24835
|
+
}
|
|
24836
|
+
}
|
|
24837
|
+
const body = new MockHTMLElement(this, "body");
|
|
24838
|
+
documentElement.appendChild(body);
|
|
24839
|
+
return body;
|
|
24541
24840
|
}
|
|
24542
|
-
|
|
24543
|
-
|
|
24544
|
-
|
|
24545
|
-
|
|
24546
|
-
|
|
24547
|
-
level: "error",
|
|
24548
|
-
type: "build",
|
|
24549
|
-
header: "Build Error",
|
|
24550
|
-
messageText: "build error",
|
|
24551
|
-
lines: []
|
|
24552
|
-
};
|
|
24553
|
-
if (isString(msg)) {
|
|
24554
|
-
diagnostic.messageText = msg.length ? msg : "UNKNOWN ERROR";
|
|
24555
|
-
} else if (err2 != null) {
|
|
24556
|
-
if (err2.stack != null) {
|
|
24557
|
-
diagnostic.messageText = err2.stack.toString();
|
|
24558
|
-
} else {
|
|
24559
|
-
if (err2.message != null) {
|
|
24560
|
-
diagnostic.messageText = err2.message.length ? err2.message : "UNKNOWN ERROR";
|
|
24561
|
-
} else {
|
|
24562
|
-
diagnostic.messageText = err2.toString();
|
|
24841
|
+
set body(body) {
|
|
24842
|
+
const documentElement = this.documentElement;
|
|
24843
|
+
for (let i = documentElement.childNodes.length - 1; i >= 0; i--) {
|
|
24844
|
+
if (documentElement.childNodes[i].nodeName === "BODY") {
|
|
24845
|
+
documentElement.childNodes[i].remove();
|
|
24563
24846
|
}
|
|
24564
24847
|
}
|
|
24848
|
+
if (body != null) {
|
|
24849
|
+
documentElement.appendChild(body);
|
|
24850
|
+
setOwnerDocument(body, this);
|
|
24851
|
+
}
|
|
24565
24852
|
}
|
|
24566
|
-
|
|
24567
|
-
|
|
24853
|
+
appendChild(newNode) {
|
|
24854
|
+
newNode.remove();
|
|
24855
|
+
newNode.parentNode = this;
|
|
24856
|
+
this.childNodes.push(newNode);
|
|
24857
|
+
return newNode;
|
|
24568
24858
|
}
|
|
24569
|
-
|
|
24570
|
-
|
|
24571
|
-
var hasError = (diagnostics) => {
|
|
24572
|
-
if (diagnostics == null || diagnostics.length === 0) {
|
|
24573
|
-
return false;
|
|
24859
|
+
createComment(data) {
|
|
24860
|
+
return new MockComment(this, data);
|
|
24574
24861
|
}
|
|
24575
|
-
|
|
24576
|
-
|
|
24577
|
-
|
|
24578
|
-
|
|
24579
|
-
|
|
24580
|
-
|
|
24581
|
-
|
|
24582
|
-
|
|
24583
|
-
|
|
24584
|
-
|
|
24585
|
-
|
|
24586
|
-
|
|
24587
|
-
// src/utils/remote-value.ts
|
|
24588
|
-
var RemoteValue = class _RemoteValue {
|
|
24589
|
-
/**
|
|
24590
|
-
* Deserializes a LocalValue serialized object back to its original JavaScript representation
|
|
24591
|
-
*
|
|
24592
|
-
* @param serialized The serialized LocalValue object
|
|
24593
|
-
* @returns The original JavaScript value/object
|
|
24594
|
-
*/
|
|
24595
|
-
static fromLocalValue(serialized) {
|
|
24596
|
-
const type = serialized[TYPE_CONSTANT];
|
|
24597
|
-
const value = VALUE_CONSTANT in serialized ? serialized[VALUE_CONSTANT] : void 0;
|
|
24598
|
-
switch (type) {
|
|
24599
|
-
case "string" /* String */:
|
|
24600
|
-
return value;
|
|
24601
|
-
case "boolean" /* Boolean */:
|
|
24602
|
-
return value;
|
|
24603
|
-
case "bigint" /* BigInt */:
|
|
24604
|
-
return BigInt(value);
|
|
24605
|
-
case "undefined" /* Undefined */:
|
|
24606
|
-
return void 0;
|
|
24607
|
-
case "null" /* Null */:
|
|
24608
|
-
return null;
|
|
24609
|
-
case "number" /* Number */:
|
|
24610
|
-
if (value === "NaN") return NaN;
|
|
24611
|
-
if (value === "-0") return -0;
|
|
24612
|
-
if (value === "Infinity") return Infinity;
|
|
24613
|
-
if (value === "-Infinity") return -Infinity;
|
|
24614
|
-
return value;
|
|
24615
|
-
case "array" /* Array */:
|
|
24616
|
-
return value.map((item) => _RemoteValue.fromLocalValue(item));
|
|
24617
|
-
case "date" /* Date */:
|
|
24618
|
-
return new Date(value);
|
|
24619
|
-
case "map" /* Map */:
|
|
24620
|
-
const map2 = /* @__PURE__ */ new Map();
|
|
24621
|
-
for (const [key, val] of value) {
|
|
24622
|
-
const deserializedKey = typeof key === "object" && key !== null ? _RemoteValue.fromLocalValue(key) : key;
|
|
24623
|
-
const deserializedValue = _RemoteValue.fromLocalValue(val);
|
|
24624
|
-
map2.set(deserializedKey, deserializedValue);
|
|
24625
|
-
}
|
|
24626
|
-
return map2;
|
|
24627
|
-
case "object" /* Object */:
|
|
24628
|
-
const obj = {};
|
|
24629
|
-
for (const [key, val] of value) {
|
|
24630
|
-
obj[key] = _RemoteValue.fromLocalValue(val);
|
|
24631
|
-
}
|
|
24632
|
-
return obj;
|
|
24633
|
-
case "regexp" /* RegularExpression */:
|
|
24634
|
-
const { pattern, flags } = value;
|
|
24635
|
-
return new RegExp(pattern, flags);
|
|
24636
|
-
case "set" /* Set */:
|
|
24637
|
-
const set = /* @__PURE__ */ new Set();
|
|
24638
|
-
for (const item of value) {
|
|
24639
|
-
set.add(_RemoteValue.fromLocalValue(item));
|
|
24640
|
-
}
|
|
24641
|
-
return set;
|
|
24642
|
-
case "symbol" /* Symbol */:
|
|
24643
|
-
return Symbol(value);
|
|
24644
|
-
default:
|
|
24645
|
-
throw new Error(`Unsupported type: ${type}`);
|
|
24862
|
+
createAttribute(attrName) {
|
|
24863
|
+
return new MockAttr(attrName.toLowerCase(), "");
|
|
24864
|
+
}
|
|
24865
|
+
createAttributeNS(namespaceURI, attrName) {
|
|
24866
|
+
return new MockAttr(attrName, "", namespaceURI);
|
|
24867
|
+
}
|
|
24868
|
+
createElement(tagName) {
|
|
24869
|
+
if (tagName === "#document" /* DOCUMENT_NODE */) {
|
|
24870
|
+
const doc = new _MockDocument(false);
|
|
24871
|
+
doc.nodeName = tagName;
|
|
24872
|
+
doc.parentNode = null;
|
|
24873
|
+
return doc;
|
|
24646
24874
|
}
|
|
24875
|
+
return createElement(this, tagName);
|
|
24647
24876
|
}
|
|
24648
|
-
|
|
24649
|
-
|
|
24650
|
-
|
|
24651
|
-
* @param serializedValues Array of serialized LocalValue objects
|
|
24652
|
-
* @returns Array of deserialized JavaScript values
|
|
24653
|
-
*/
|
|
24654
|
-
static fromLocalValueArray(serializedValues) {
|
|
24655
|
-
return serializedValues.map((value) => _RemoteValue.fromLocalValue(value));
|
|
24877
|
+
createElementNS(namespaceURI, tagName) {
|
|
24878
|
+
const elmNs = createElementNS(this, namespaceURI, tagName);
|
|
24879
|
+
return elmNs;
|
|
24656
24880
|
}
|
|
24657
|
-
|
|
24658
|
-
|
|
24659
|
-
|
|
24660
|
-
|
|
24661
|
-
|
|
24662
|
-
|
|
24663
|
-
|
|
24664
|
-
|
|
24665
|
-
|
|
24666
|
-
|
|
24667
|
-
|
|
24668
|
-
|
|
24669
|
-
|
|
24670
|
-
|
|
24671
|
-
|
|
24672
|
-
|
|
24673
|
-
|
|
24881
|
+
createTextNode(text) {
|
|
24882
|
+
return new MockTextNode(this, text);
|
|
24883
|
+
}
|
|
24884
|
+
createDocumentFragment() {
|
|
24885
|
+
return new MockDocumentFragment(this);
|
|
24886
|
+
}
|
|
24887
|
+
createDocumentTypeNode() {
|
|
24888
|
+
return new MockDocumentTypeNode(this);
|
|
24889
|
+
}
|
|
24890
|
+
getElementById(id) {
|
|
24891
|
+
return getElementById(this, id);
|
|
24892
|
+
}
|
|
24893
|
+
getElementsByName(elmName) {
|
|
24894
|
+
return getElementsByName(this, elmName.toLowerCase());
|
|
24895
|
+
}
|
|
24896
|
+
get title() {
|
|
24897
|
+
const title = this.head.childNodes.find((elm) => elm.nodeName === "TITLE");
|
|
24898
|
+
if (title != null && typeof title.textContent === "string") {
|
|
24899
|
+
return title.textContent.trim();
|
|
24674
24900
|
}
|
|
24675
|
-
|
|
24676
|
-
|
|
24901
|
+
return "";
|
|
24902
|
+
}
|
|
24903
|
+
set title(value) {
|
|
24904
|
+
const head = this.head;
|
|
24905
|
+
let title = head.childNodes.find((elm) => elm.nodeName === "TITLE");
|
|
24906
|
+
if (title == null) {
|
|
24907
|
+
title = this.createElement("title");
|
|
24908
|
+
head.appendChild(title);
|
|
24677
24909
|
}
|
|
24678
|
-
|
|
24910
|
+
title.textContent = value;
|
|
24679
24911
|
}
|
|
24680
24912
|
};
|
|
24681
|
-
|
|
24682
|
-
|
|
24683
|
-
|
|
24684
|
-
|
|
24685
|
-
|
|
24686
|
-
|
|
24687
|
-
|
|
24688
|
-
|
|
24689
|
-
|
|
24690
|
-
|
|
24691
|
-
|
|
24692
|
-
|
|
24693
|
-
|
|
24694
|
-
|
|
24695
|
-
|
|
24696
|
-
|
|
24697
|
-
|
|
24698
|
-
|
|
24699
|
-
|
|
24700
|
-
})
|
|
24701
|
-
|
|
24702
|
-
|
|
24703
|
-
|
|
24704
|
-
|
|
24705
|
-
|
|
24706
|
-
|
|
24707
|
-
|
|
24913
|
+
function resetDocument(doc) {
|
|
24914
|
+
if (doc != null) {
|
|
24915
|
+
resetEventListeners(doc);
|
|
24916
|
+
const documentElement = doc.documentElement;
|
|
24917
|
+
if (documentElement != null) {
|
|
24918
|
+
resetElement(documentElement);
|
|
24919
|
+
for (let i = 0, ii = documentElement.childNodes.length; i < ii; i++) {
|
|
24920
|
+
const childNode = documentElement.childNodes[i];
|
|
24921
|
+
resetElement(childNode);
|
|
24922
|
+
childNode.childNodes.length = 0;
|
|
24923
|
+
}
|
|
24924
|
+
}
|
|
24925
|
+
for (const key in doc) {
|
|
24926
|
+
if (doc.hasOwnProperty(key) && !DOC_KEY_KEEPERS.has(key)) {
|
|
24927
|
+
delete doc[key];
|
|
24928
|
+
}
|
|
24929
|
+
}
|
|
24930
|
+
try {
|
|
24931
|
+
doc.nodeName = "#document" /* DOCUMENT_NODE */;
|
|
24932
|
+
} catch (e) {
|
|
24933
|
+
}
|
|
24934
|
+
try {
|
|
24935
|
+
doc.nodeType = 9 /* DOCUMENT_NODE */;
|
|
24936
|
+
} catch (e) {
|
|
24937
|
+
}
|
|
24938
|
+
try {
|
|
24939
|
+
doc.cookie = "";
|
|
24940
|
+
} catch (e) {
|
|
24941
|
+
}
|
|
24942
|
+
try {
|
|
24943
|
+
doc.referrer = "";
|
|
24944
|
+
} catch (e) {
|
|
24708
24945
|
}
|
|
24709
24946
|
}
|
|
24710
|
-
if (result.isErr) {
|
|
24711
|
-
const value = result.value;
|
|
24712
|
-
return err(value);
|
|
24713
|
-
}
|
|
24714
|
-
throw "should never get here";
|
|
24715
24947
|
}
|
|
24716
|
-
var
|
|
24717
|
-
|
|
24718
|
-
|
|
24719
|
-
|
|
24720
|
-
|
|
24721
|
-
|
|
24722
|
-
|
|
24723
|
-
|
|
24724
|
-
|
|
24725
|
-
|
|
24726
|
-
|
|
24727
|
-
|
|
24948
|
+
var DOC_KEY_KEEPERS = /* @__PURE__ */ new Set([
|
|
24949
|
+
"nodeName",
|
|
24950
|
+
"nodeType",
|
|
24951
|
+
"nodeValue",
|
|
24952
|
+
"ownerDocument",
|
|
24953
|
+
"parentNode",
|
|
24954
|
+
"childNodes",
|
|
24955
|
+
"_shadowRoot"
|
|
24956
|
+
]);
|
|
24957
|
+
function getElementById(elm, id) {
|
|
24958
|
+
const children = elm.children;
|
|
24959
|
+
for (let i = 0, ii = children.length; i < ii; i++) {
|
|
24960
|
+
const childElm = children[i];
|
|
24961
|
+
if (childElm.id === id) {
|
|
24962
|
+
return childElm;
|
|
24963
|
+
}
|
|
24964
|
+
const childElmFound = getElementById(childElm, id);
|
|
24965
|
+
if (childElmFound != null) {
|
|
24966
|
+
return childElmFound;
|
|
24967
|
+
}
|
|
24728
24968
|
}
|
|
24729
|
-
|
|
24730
|
-
|
|
24731
|
-
|
|
24732
|
-
|
|
24733
|
-
|
|
24734
|
-
|
|
24969
|
+
return null;
|
|
24970
|
+
}
|
|
24971
|
+
function getElementsByName(elm, elmName, foundElms = []) {
|
|
24972
|
+
const children = elm.children;
|
|
24973
|
+
for (let i = 0, ii = children.length; i < ii; i++) {
|
|
24974
|
+
const childElm = children[i];
|
|
24975
|
+
if (childElm.name && childElm.name.toLowerCase() === elmName) {
|
|
24976
|
+
foundElms.push(childElm);
|
|
24977
|
+
}
|
|
24978
|
+
getElementsByName(childElm, elmName, foundElms);
|
|
24735
24979
|
}
|
|
24736
|
-
|
|
24737
|
-
return SERIALIZED_PREFIX + btoa(JSON.stringify(arg));
|
|
24980
|
+
return foundElms;
|
|
24738
24981
|
}
|
|
24739
|
-
function
|
|
24740
|
-
|
|
24741
|
-
|
|
24982
|
+
function setOwnerDocument(elm, ownerDocument) {
|
|
24983
|
+
for (let i = 0, ii = elm.childNodes.length; i < ii; i++) {
|
|
24984
|
+
elm.childNodes[i].ownerDocument = ownerDocument;
|
|
24985
|
+
if (elm.childNodes[i].nodeType === 1 /* ELEMENT_NODE */) {
|
|
24986
|
+
setOwnerDocument(elm.childNodes[i], ownerDocument);
|
|
24987
|
+
}
|
|
24742
24988
|
}
|
|
24743
|
-
return RemoteValue.fromLocalValue(JSON.parse(atob(value.slice(SERIALIZED_PREFIX.length))));
|
|
24744
24989
|
}
|
|
24745
24990
|
|
|
24746
|
-
// src/
|
|
24747
|
-
var
|
|
24748
|
-
|
|
24749
|
-
|
|
24750
|
-
|
|
24751
|
-
);
|
|
24752
|
-
|
|
24753
|
-
|
|
24754
|
-
);
|
|
24755
|
-
|
|
24756
|
-
|
|
24757
|
-
);
|
|
24758
|
-
var isJsFile = lowerPathParam((p) => p.endsWith(".js") || p.endsWith(".mjs") || p.endsWith(".cjs"));
|
|
24759
|
-
|
|
24760
|
-
// src/utils/shadow-css.ts
|
|
24761
|
-
/**
|
|
24762
|
-
* @license
|
|
24763
|
-
* Copyright Google Inc. All Rights Reserved.
|
|
24764
|
-
*
|
|
24765
|
-
* Use of this source code is governed by an MIT-style license that can be
|
|
24766
|
-
* found in the LICENSE file at https://angular.io/license
|
|
24767
|
-
*
|
|
24768
|
-
* This file is a port of shadowCSS from `webcomponents.js` to TypeScript.
|
|
24769
|
-
* https://github.com/webcomponents/webcomponentsjs/blob/4efecd7e0e/src/ShadowCSS/ShadowCSS.js
|
|
24770
|
-
* https://github.com/angular/angular/blob/master/packages/compiler/src/shadow_css.ts
|
|
24771
|
-
*/
|
|
24772
|
-
var _polyfillHost = "-shadowcsshost";
|
|
24773
|
-
var _polyfillSlotted = "-shadowcssslotted";
|
|
24774
|
-
var _polyfillHostContext = "-shadowcsscontext";
|
|
24775
|
-
var _parenSuffix = ")(?:\\(((?:\\([^)(]*\\)|[^)(]*)+?)\\))?([^,{]*)";
|
|
24776
|
-
var _cssColonHostRe = new RegExp("(" + _polyfillHost + _parenSuffix, "gim");
|
|
24777
|
-
var _cssColonHostContextRe = new RegExp("(" + _polyfillHostContext + _parenSuffix, "gim");
|
|
24778
|
-
var _cssColonSlottedRe = new RegExp("(" + _polyfillSlotted + _parenSuffix, "gim");
|
|
24779
|
-
var _polyfillHostNoCombinator = _polyfillHost + "-no-combinator";
|
|
24780
|
-
var createSupportsRuleRe = (selector) => {
|
|
24781
|
-
const safeSelector = escapeRegExpSpecialCharacters(selector);
|
|
24782
|
-
return new RegExp(
|
|
24783
|
-
// First capture group: match any context before the selector that's not inside @supports selector()
|
|
24784
|
-
// Using negative lookahead to avoid matching inside @supports selector(...) condition
|
|
24785
|
-
`(^|[^@]|@(?!supports\\s+selector\\s*\\([^{]*?${safeSelector}))(${safeSelector}\\b)`,
|
|
24786
|
-
"g"
|
|
24787
|
-
);
|
|
24788
|
-
};
|
|
24789
|
-
var _colonSlottedRe = createSupportsRuleRe("::slotted");
|
|
24790
|
-
var _colonHostRe = createSupportsRuleRe(":host");
|
|
24791
|
-
var _colonHostContextRe = createSupportsRuleRe(":host-context");
|
|
24792
|
-
|
|
24793
|
-
// src/runtime/mode.ts
|
|
24794
|
-
var setMode = (handler) => modeResolutionChain.push(handler);
|
|
24795
|
-
var CAPTURE_EVENT_SUFFIX = "Capture";
|
|
24796
|
-
var CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + "$");
|
|
24797
|
-
var baseClass = BUILD.lazyLoad ? class {
|
|
24798
|
-
} : globalThis.HTMLElement || class {
|
|
24799
|
-
};
|
|
24991
|
+
// src/hydrate/runner/create-window.ts
|
|
24992
|
+
var templateWindows = /* @__PURE__ */ new Map();
|
|
24993
|
+
function createWindowFromHtml(templateHtml, uniqueId) {
|
|
24994
|
+
let templateWindow = templateWindows.get(uniqueId);
|
|
24995
|
+
if (templateWindow == null) {
|
|
24996
|
+
templateWindow = new MockWindow(templateHtml);
|
|
24997
|
+
templateWindows.set(uniqueId, templateWindow);
|
|
24998
|
+
}
|
|
24999
|
+
const win2 = cloneWindow(templateWindow);
|
|
25000
|
+
return win2;
|
|
25001
|
+
}
|
|
24800
25002
|
|
|
24801
25003
|
// src/compiler/html/canonical-link.ts
|
|
24802
25004
|
var updateCanonicalLink = (doc, href) => {
|
|
@@ -26179,4 +26381,13 @@ function removeScripts(elm) {
|
|
|
26179
26381
|
}
|
|
26180
26382
|
}
|
|
26181
26383
|
|
|
26182
|
-
|
|
26384
|
+
// src/hydrate/runner/index.ts
|
|
26385
|
+
var everywhere;
|
|
26386
|
+
try {
|
|
26387
|
+
everywhere = global || globalThis;
|
|
26388
|
+
} catch (e) {
|
|
26389
|
+
everywhere = window || globalThis;
|
|
26390
|
+
}
|
|
26391
|
+
everywhere.tagTransform = transformTag;
|
|
26392
|
+
|
|
26393
|
+
export { createWindowFromHtml, deserializeProperty, hydrateDocument, renderToString, serializeDocumentToString, serializeProperty, setTagTransformer, streamToString, transformTag };
|