@everymatrix/general-registration 1.52.6 → 1.53.10
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/dist/cjs/{checkbox-group-input_14.cjs.entry.js → checkbox-group-input_13.cjs.entry.js} +1820 -991
- package/dist/cjs/general-registration.cjs.js +3 -3
- package/dist/cjs/{index-e11c50f2.js → index-ed891a0d.js} +177 -80
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +1 -7
- package/dist/collection/components/general-registration/general-registration.js +50 -21
- package/dist/esm/{checkbox-group-input_14.entry.js → checkbox-group-input_13.entry.js} +1868 -1038
- package/dist/esm/general-registration.js +4 -4
- package/dist/esm/{index-a3724f84.js → index-d069ae9e.js} +177 -80
- package/dist/esm/loader.js +3 -3
- package/dist/general-registration/general-registration.esm.js +1 -1
- package/dist/general-registration/p-30224c7b.js +2 -0
- package/dist/general-registration/{p-0925f5f9.entry.js → p-a04c166c.entry.js} +1878 -892
- package/dist/types/components/general-registration/general-registration.d.ts +1 -1
- package/package.json +3 -3
- package/dist/general-registration/p-0095c1dc.js +0 -2
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-ed891a0d.js');
|
|
6
6
|
const appGlobals = require('./app-globals-3a1e7e63.js');
|
|
7
7
|
|
|
8
8
|
/*
|
|
9
|
-
Stencil Client Patch Browser v4.
|
|
9
|
+
Stencil Client Patch Browser v4.25.1 | MIT Licensed | https://stenciljs.com
|
|
10
10
|
*/
|
|
11
11
|
var patchBrowser = () => {
|
|
12
12
|
const importMeta = (typeof document === 'undefined' ? new (require('u' + 'rl').URL)('file:' + __filename).href : (document.currentScript && document.currentScript.src || new URL('general-registration.cjs.js', document.baseURI).href));
|
|
@@ -19,7 +19,7 @@ var patchBrowser = () => {
|
|
|
19
19
|
|
|
20
20
|
patchBrowser().then(async (options) => {
|
|
21
21
|
await appGlobals.globalScripts();
|
|
22
|
-
return index.bootstrapLazy([["checkbox-group-
|
|
22
|
+
return index.bootstrapLazy([["checkbox-group-input_13.cjs",[[1,"general-registration",{"endpoint":[513],"language":[513],"clientStyling":[1537,"client-styling"],"clientStylingUrl":[513,"client-styling-url"],"translationUrl":[513,"translation-url"],"dateFormat":[513,"date-format"],"buttonInsideForm":[516,"button-inside-form"],"btag":[513],"emitOnClick":[516,"emit-on-click"],"errorMessage":[32],"isFormValid":[32],"isConsentValid":[32],"isConsentReady":[32],"isLoading":[32],"isLoadingPOST":[32],"registrationStep":[32],"forms":[32],"limitStylingAppends":[32],"autofilled":[32]},[[0,"sendValidityState","checkInputsValidityHandler"],[0,"sendInputValue","getInputsValueHandler"],[8,"message","messageHandler"]],{"registrationStep":["sendStep"],"clientStyling":["handleStylingChange"],"clientStylingUrl":["handleStylingUrlChange"],"forms":["setFormValidity"],"btag":["addBtag"]}],[1,"general-input",{"type":[513],"name":[513],"displayName":[513,"display-name"],"placeholder":[513],"action":[513],"validation":[16],"options":[520],"language":[513],"autofilled":[516],"tooltip":[513],"defaultValue":[520,"default-value"],"emitValue":[516,"emit-value"],"isDuplicateInput":[516,"is-duplicate-input"],"clientStyling":[520,"client-styling"],"dateFormat":[513,"date-format"],"translationUrl":[513,"translation-url"],"emitOnClick":[516,"emit-on-click"]}],[1,"toggle-checkbox-input",{"name":[513],"displayName":[513,"display-name"],"defaultValue":[513,"default-value"],"options":[16],"autofilled":[516],"tooltip":[513],"validation":[16],"language":[513],"emitValue":[516,"emit-value"],"clientStyling":[513,"client-styling"],"errorMessage":[32],"isValid":[32],"limitStylingAppends":[32],"showTooltip":[32],"showFields":[32]},[[4,"click","handleClickOutside"]]],[1,"checkbox-group-input",{"name":[513],"displayName":[513,"display-name"],"defaultValue":[513,"default-value"],"autofilled":[516],"tooltip":[513],"options":[16],"validation":[16],"language":[513],"emitValue":[516,"emit-value"],"clientStyling":[513,"client-styling"],"errorMessage":[32],"isValid":[32],"limitStylingAppends":[32],"showTooltip":[32],"selectedValues":[32]},[[4,"click","handleClickOutside"]],{"isValid":["validityChanged"],"selectedValues":["setValue"],"emitValue":["emitValueHandler"]}],[1,"checkbox-input",{"name":[513],"displayName":[513,"display-name"],"defaultValue":[513,"default-value"],"autofilled":[516],"tooltip":[513],"validation":[16],"language":[513],"emitValue":[516,"emit-value"],"clientStyling":[513,"client-styling"],"errorMessage":[32],"isValid":[32],"limitStylingAppends":[32],"showTooltip":[32]},[[4,"click","handleClickOutside"]],{"isValid":["validityChanged"],"emitValue":["emitValueHandler"]}],[1,"date-input",{"name":[513],"displayName":[513,"display-name"],"placeholder":[513],"validation":[16],"defaultValue":[513,"default-value"],"autofilled":[516],"tooltip":[513],"language":[513],"emitValue":[516,"emit-value"],"clientStyling":[513,"client-styling"],"dateFormat":[513,"date-format"],"emitOnClick":[516,"emit-on-click"],"errorMessage":[32],"isValid":[32],"limitStylingAppends":[32],"showTooltip":[32]},[[4,"click","handleClickOutside"]],{"isValid":["validityChanged"],"emitValue":["emitValueHandler"]}],[1,"email-input",{"name":[513],"displayName":[513,"display-name"],"placeholder":[513],"validation":[16],"defaultValue":[513,"default-value"],"autofilled":[516],"tooltip":[513],"language":[513],"emitValue":[516,"emit-value"],"isDuplicateInput":[516,"is-duplicate-input"],"clientStyling":[513,"client-styling"],"errorMessage":[32],"isValid":[32],"limitStylingAppends":[32],"showTooltip":[32]},[[4,"click","handleClickOutside"],[16,"sendInputValue","valueChangedHandler"]],{"isValid":["validityChanged"],"emitValue":["emitValueHandler"]}],[1,"number-input",{"name":[513],"displayName":[513,"display-name"],"placeholder":[513],"validation":[16],"defaultValue":[513,"default-value"],"autofilled":[516],"tooltip":[513],"language":[513],"emitValue":[516,"emit-value"],"clientStyling":[513,"client-styling"],"errorMessage":[32],"isValid":[32],"limitStylingAppends":[32],"showTooltip":[32]},[[4,"click","handleClickOutside"]],{"isValid":["validityChanged"],"emitValue":["emitValueHandler"]}],[1,"password-input",{"name":[513],"displayName":[513,"display-name"],"placeholder":[513],"defaultValue":[513,"default-value"],"autofilled":[516],"tooltip":[513],"validation":[16],"language":[513],"emitValue":[516,"emit-value"],"isDuplicateInput":[516,"is-duplicate-input"],"clientStyling":[513,"client-styling"],"isValid":[32],"errorMessage":[32],"limitStylingAppends":[32],"showTooltip":[32],"passwordComplexity":[32],"showPopup":[32],"value":[32]},[[16,"sendOriginalValidityState","originalValidityChangedHandler"],[16,"sendInputValue","valueChangedHandler"],[4,"click","handleClickOutside"]],{"isValid":["validityChanged"],"value":["valueChanged"],"emitValue":["emitValueHandler"]}],[1,"radio-input",{"name":[513],"displayName":[513,"display-name"],"optionsGroup":[16],"validation":[16],"tooltip":[513],"language":[513],"emitValue":[516,"emit-value"],"clientStyling":[513,"client-styling"],"errorMessage":[32],"isValid":[32],"limitStylingAppends":[32],"showTooltip":[32]},[[4,"click","handleClickOutside"]],{"isValid":["validityChanged"],"emitValue":["emitValueHandler"]}],[1,"select-input",{"name":[513],"displayName":[513,"display-name"],"placeholder":[513],"action":[513],"defaultValue":[513,"default-value"],"autofilled":[516],"tooltip":[513],"options":[16],"validation":[16],"language":[513],"emitValue":[516,"emit-value"],"clientStyling":[513,"client-styling"],"errorMessage":[32],"isValid":[32],"limitStylingAppends":[32],"showTooltip":[32]},[[4,"click","handleClickOutside"]],{"isValid":["validityChanged"],"emitValue":["emitValueHandler"]}],[1,"tel-input",{"name":[513],"displayName":[513,"display-name"],"placeholder":[513],"showLabels":[516,"show-labels"],"action":[513],"validation":[16],"defaultValue":[520,"default-value"],"autofilled":[516],"tooltip":[513],"language":[513],"emitValue":[516,"emit-value"],"clientStyling":[513,"client-styling"],"isValid":[32],"errorMessage":[32],"limitStylingAppends":[32],"showTooltip":[32]},[[4,"click","handleClickOutside"]],{"isValid":["validityChanged"],"emitValue":["emitValueHandler"]}],[1,"text-input",{"name":[513],"displayName":[513,"display-name"],"placeholder":[513],"validation":[16],"defaultValue":[513,"default-value"],"autofilled":[516],"tooltip":[513],"language":[513],"checkValidity":[516,"check-validity"],"emitValue":[516,"emit-value"],"isDuplicateInput":[516,"is-duplicate-input"],"clientStyling":[513,"client-styling"],"isValid":[32],"errorMessage":[32],"limitStylingAppends":[32],"showTooltip":[32]},[[4,"click","handleClickOutside"],[16,"sendInputValue","valueChangedHandler"]],{"isValid":["validityChanged"],"emitValue":["emitValueHandler"]}]]]], options);
|
|
23
23
|
});
|
|
24
24
|
|
|
25
25
|
exports.setNonce = index.setNonce;
|
|
@@ -21,19 +21,27 @@ function _interopNamespace(e) {
|
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
const NAMESPACE = 'general-registration';
|
|
24
|
-
const BUILD = /* general-registration */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: true, cmpDidRender: true, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: true, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: true, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: false, hasRenderFn: true, hostListener: true, hostListenerTarget: true, hostListenerTargetBody: true, hostListenerTargetDocument: true, hostListenerTargetParent: false, hostListenerTargetWindow: true, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, hydratedSelectorName: "hydrated", initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: false, mode: false, observeAttribute: true, profile: false, prop: true, propBoolean: true, propMutable: true, propNumber: false, propString: true, reflect: true, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: true, slot: true, slotChildNodesFix: false, slotRelocation: false, state: true, style: true, svg: true, taskQueue: true, transformTagName: false, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: false, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: true, vdomRender: true, vdomStyle: false, vdomText: true, vdomXlink: false, watchCallback: true };
|
|
24
|
+
const BUILD = /* general-registration */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: true, cmpDidRender: true, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: true, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: true, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: false, hasRenderFn: true, hostListener: true, hostListenerTarget: true, hostListenerTargetBody: true, hostListenerTargetDocument: true, hostListenerTargetParent: false, hostListenerTargetWindow: true, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, hydratedSelectorName: "hydrated", initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: false, mode: false, modernPropertyDecls: false, observeAttribute: true, profile: false, prop: true, propBoolean: true, propMutable: true, propNumber: false, propString: true, reflect: true, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: true, slot: true, slotChildNodesFix: false, slotRelocation: false, state: true, style: true, svg: true, taskQueue: true, transformTagName: false, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: false, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: true, vdomRender: true, vdomStyle: false, vdomText: true, vdomXlink: false, watchCallback: true };
|
|
25
25
|
|
|
26
26
|
/*
|
|
27
|
-
Stencil Client Platform v4.
|
|
27
|
+
Stencil Client Platform v4.25.1 | MIT Licensed | https://stenciljs.com
|
|
28
28
|
*/
|
|
29
29
|
var __defProp = Object.defineProperty;
|
|
30
30
|
var __export = (target, all) => {
|
|
31
31
|
for (var name in all)
|
|
32
32
|
__defProp(target, name, { get: all[name], enumerable: true });
|
|
33
33
|
};
|
|
34
|
+
|
|
35
|
+
// src/utils/constants.ts
|
|
36
|
+
var SVG_NS = "http://www.w3.org/2000/svg";
|
|
37
|
+
var HTML_NS = "http://www.w3.org/1999/xhtml";
|
|
38
|
+
|
|
39
|
+
// src/client/client-host-ref.ts
|
|
34
40
|
var hostRefs = /* @__PURE__ */ new WeakMap();
|
|
35
41
|
var getHostRef = (ref) => hostRefs.get(ref);
|
|
36
|
-
var registerInstance = (lazyInstance, hostRef) =>
|
|
42
|
+
var registerInstance = (lazyInstance, hostRef) => {
|
|
43
|
+
hostRefs.set(hostRef.$lazyInstance$ = lazyInstance, hostRef);
|
|
44
|
+
};
|
|
37
45
|
var registerHost = (hostElement, cmpMeta) => {
|
|
38
46
|
const hostRef = {
|
|
39
47
|
$flags$: 0,
|
|
@@ -46,7 +54,8 @@ var registerHost = (hostElement, cmpMeta) => {
|
|
|
46
54
|
hostElement["s-p"] = [];
|
|
47
55
|
hostElement["s-rc"] = [];
|
|
48
56
|
}
|
|
49
|
-
|
|
57
|
+
const ref = hostRefs.set(hostElement, hostRef);
|
|
58
|
+
return ref;
|
|
50
59
|
};
|
|
51
60
|
var isMemberInElement = (elm, memberName) => memberName in elm;
|
|
52
61
|
var consoleError = (e, el) => (0, console.error)(e, el);
|
|
@@ -71,10 +80,10 @@ var loadModule = (cmpMeta, hostRef, hmrVersionId) => {
|
|
|
71
80
|
}
|
|
72
81
|
switch(bundleId) {
|
|
73
82
|
|
|
74
|
-
case 'checkbox-group-
|
|
83
|
+
case 'checkbox-group-input_13.cjs':
|
|
75
84
|
return Promise.resolve().then(function () { return /*#__PURE__*/_interopNamespace(require(
|
|
76
85
|
/* webpackMode: "lazy" */
|
|
77
|
-
'./checkbox-group-
|
|
86
|
+
'./checkbox-group-input_13.cjs.entry.js')); }).then(processMod, consoleError);
|
|
78
87
|
}
|
|
79
88
|
}
|
|
80
89
|
return Promise.resolve().then(function () { return /*#__PURE__*/_interopNamespace(require(
|
|
@@ -83,16 +92,22 @@ var loadModule = (cmpMeta, hostRef, hmrVersionId) => {
|
|
|
83
92
|
/* webpackExclude: /\.system\.entry\.js$/ */
|
|
84
93
|
/* webpackMode: "lazy" */
|
|
85
94
|
`./${bundleId}.entry.js${""}`
|
|
86
|
-
)); }).then(
|
|
87
|
-
{
|
|
88
|
-
|
|
95
|
+
)); }).then(
|
|
96
|
+
(importedModule) => {
|
|
97
|
+
{
|
|
98
|
+
cmpModules.set(bundleId, importedModule);
|
|
99
|
+
}
|
|
100
|
+
return importedModule[exportName];
|
|
101
|
+
},
|
|
102
|
+
(e) => {
|
|
103
|
+
consoleError(e, hostRef.$hostElement$);
|
|
89
104
|
}
|
|
90
|
-
|
|
91
|
-
}, consoleError);
|
|
105
|
+
);
|
|
92
106
|
};
|
|
93
107
|
|
|
94
108
|
// src/client/client-style.ts
|
|
95
109
|
var styles = /* @__PURE__ */ new Map();
|
|
110
|
+
var HYDRATED_STYLE_ID = "sty-id";
|
|
96
111
|
var HYDRATED_CSS = "{visibility:hidden}.hydrated{visibility:inherit}";
|
|
97
112
|
var SLOT_FB_CSS = "slot-fb{display:contents}slot-fb[hidden]{display:none}";
|
|
98
113
|
var win = typeof window !== "undefined" ? window : {};
|
|
@@ -166,14 +181,6 @@ var flush = () => {
|
|
|
166
181
|
};
|
|
167
182
|
var nextTick = (cb) => promiseResolve().then(cb);
|
|
168
183
|
var writeTask = /* @__PURE__ */ queueTask(queueDomWrites, true);
|
|
169
|
-
|
|
170
|
-
// src/utils/constants.ts
|
|
171
|
-
var EMPTY_OBJ = {};
|
|
172
|
-
var SVG_NS = "http://www.w3.org/2000/svg";
|
|
173
|
-
var HTML_NS = "http://www.w3.org/1999/xhtml";
|
|
174
|
-
|
|
175
|
-
// src/utils/helpers.ts
|
|
176
|
-
var isDef = (v) => v != null;
|
|
177
184
|
var isComplexType = (o) => {
|
|
178
185
|
o = typeof o;
|
|
179
186
|
return o === "object" || o === "function";
|
|
@@ -374,7 +381,7 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
|
|
|
374
381
|
}
|
|
375
382
|
if (!appliedStyles.has(scopeId2)) {
|
|
376
383
|
{
|
|
377
|
-
styleElm = doc.createElement("style");
|
|
384
|
+
styleElm = document.querySelector(`[${HYDRATED_STYLE_ID}="${scopeId2}"]`) || doc.createElement("style");
|
|
378
385
|
styleElm.innerHTML = style;
|
|
379
386
|
const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(doc);
|
|
380
387
|
if (nonce != null) {
|
|
@@ -384,7 +391,10 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
|
|
|
384
391
|
if (styleContainerNode.nodeName === "HEAD") {
|
|
385
392
|
const preconnectLinks = styleContainerNode.querySelectorAll("link[rel=preconnect]");
|
|
386
393
|
const referenceNode2 = preconnectLinks.length > 0 ? preconnectLinks[preconnectLinks.length - 1].nextSibling : styleContainerNode.querySelector("style");
|
|
387
|
-
styleContainerNode.insertBefore(
|
|
394
|
+
styleContainerNode.insertBefore(
|
|
395
|
+
styleElm,
|
|
396
|
+
(referenceNode2 == null ? void 0 : referenceNode2.parentNode) === styleContainerNode ? referenceNode2 : null
|
|
397
|
+
);
|
|
388
398
|
} else if ("host" in styleContainerNode) {
|
|
389
399
|
if (supportsConstructableStylesheets) {
|
|
390
400
|
const stylesheet = new CSSStyleSheet();
|
|
@@ -434,16 +444,18 @@ var attachStyles = (hostRef) => {
|
|
|
434
444
|
endAttachStyles();
|
|
435
445
|
};
|
|
436
446
|
var getScopeId = (cmp, mode) => "sc-" + (cmp.$tagName$);
|
|
437
|
-
var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
|
|
447
|
+
var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRender) => {
|
|
438
448
|
if (oldValue !== newValue) {
|
|
439
449
|
let isProp = isMemberInElement(elm, memberName);
|
|
440
450
|
let ln = memberName.toLowerCase();
|
|
441
451
|
if (memberName === "class") {
|
|
442
452
|
const classList = elm.classList;
|
|
443
453
|
const oldClasses = parseClassList(oldValue);
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
454
|
+
let newClasses = parseClassList(newValue);
|
|
455
|
+
{
|
|
456
|
+
classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
|
|
457
|
+
classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
|
|
458
|
+
}
|
|
447
459
|
} else if (memberName === "key") ; else if (memberName === "ref") {
|
|
448
460
|
if (newValue) {
|
|
449
461
|
newValue(elm);
|
|
@@ -481,7 +493,7 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
|
|
|
481
493
|
elm.setAttribute(memberName, n);
|
|
482
494
|
}
|
|
483
495
|
}
|
|
484
|
-
} else {
|
|
496
|
+
} else if (elm[memberName] !== newValue) {
|
|
485
497
|
elm[memberName] = newValue;
|
|
486
498
|
}
|
|
487
499
|
} catch (e) {
|
|
@@ -503,24 +515,44 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
|
|
|
503
515
|
}
|
|
504
516
|
};
|
|
505
517
|
var parseClassListRegex = /\s/;
|
|
506
|
-
var parseClassList = (value) =>
|
|
518
|
+
var parseClassList = (value) => {
|
|
519
|
+
if (typeof value === "object" && value && "baseVal" in value) {
|
|
520
|
+
value = value.baseVal;
|
|
521
|
+
}
|
|
522
|
+
if (!value || typeof value !== "string") {
|
|
523
|
+
return [];
|
|
524
|
+
}
|
|
525
|
+
return value.split(parseClassListRegex);
|
|
526
|
+
};
|
|
507
527
|
var CAPTURE_EVENT_SUFFIX = "Capture";
|
|
508
528
|
var CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + "$");
|
|
509
529
|
|
|
510
530
|
// src/runtime/vdom/update-element.ts
|
|
511
|
-
var updateElement = (oldVnode, newVnode, isSvgMode2) => {
|
|
531
|
+
var updateElement = (oldVnode, newVnode, isSvgMode2, isInitialRender) => {
|
|
512
532
|
const elm = newVnode.$elm$.nodeType === 11 /* DocumentFragment */ && newVnode.$elm$.host ? newVnode.$elm$.host : newVnode.$elm$;
|
|
513
|
-
const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ ||
|
|
514
|
-
const newVnodeAttrs = newVnode.$attrs$ ||
|
|
533
|
+
const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ || {};
|
|
534
|
+
const newVnodeAttrs = newVnode.$attrs$ || {};
|
|
515
535
|
{
|
|
516
536
|
for (const memberName of sortedAttrNames(Object.keys(oldVnodeAttrs))) {
|
|
517
537
|
if (!(memberName in newVnodeAttrs)) {
|
|
518
|
-
setAccessor(
|
|
538
|
+
setAccessor(
|
|
539
|
+
elm,
|
|
540
|
+
memberName,
|
|
541
|
+
oldVnodeAttrs[memberName],
|
|
542
|
+
void 0,
|
|
543
|
+
isSvgMode2,
|
|
544
|
+
newVnode.$flags$);
|
|
519
545
|
}
|
|
520
546
|
}
|
|
521
547
|
}
|
|
522
548
|
for (const memberName of sortedAttrNames(Object.keys(newVnodeAttrs))) {
|
|
523
|
-
setAccessor(
|
|
549
|
+
setAccessor(
|
|
550
|
+
elm,
|
|
551
|
+
memberName,
|
|
552
|
+
oldVnodeAttrs[memberName],
|
|
553
|
+
newVnodeAttrs[memberName],
|
|
554
|
+
isSvgMode2,
|
|
555
|
+
newVnode.$flags$);
|
|
524
556
|
}
|
|
525
557
|
};
|
|
526
558
|
function sortedAttrNames(attrNames) {
|
|
@@ -532,13 +564,10 @@ function sortedAttrNames(attrNames) {
|
|
|
532
564
|
attrNames
|
|
533
565
|
);
|
|
534
566
|
}
|
|
535
|
-
|
|
536
|
-
// src/runtime/vdom/vdom-render.ts
|
|
537
|
-
var scopeId;
|
|
538
567
|
var hostTagName;
|
|
539
568
|
var useNativeShadowDom = false;
|
|
540
569
|
var isSvgMode = false;
|
|
541
|
-
var createElm = (oldParentVNode, newParentVNode, childIndex
|
|
570
|
+
var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
542
571
|
const newVNode2 = newParentVNode.$children$[childIndex];
|
|
543
572
|
let i2 = 0;
|
|
544
573
|
let elm;
|
|
@@ -559,11 +588,6 @@ var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
|
|
|
559
588
|
{
|
|
560
589
|
updateElement(null, newVNode2, isSvgMode);
|
|
561
590
|
}
|
|
562
|
-
const rootNode = elm.getRootNode();
|
|
563
|
-
const isElementWithinShadowRoot = !rootNode.querySelector("body");
|
|
564
|
-
if (!isElementWithinShadowRoot && BUILD.scoped && isDef(scopeId) && elm["s-si"] !== scopeId) {
|
|
565
|
-
elm.classList.add(elm["s-si"] = scopeId);
|
|
566
|
-
}
|
|
567
591
|
if (newVNode2.$children$) {
|
|
568
592
|
for (i2 = 0; i2 < newVNode2.$children$.length; ++i2) {
|
|
569
593
|
childNode = createElm(oldParentVNode, newVNode2, i2);
|
|
@@ -700,6 +724,9 @@ var isSameVnode = (leftVNode, rightVNode, isInitialRender = false) => {
|
|
|
700
724
|
if (!isInitialRender) {
|
|
701
725
|
return leftVNode.$key$ === rightVNode.$key$;
|
|
702
726
|
}
|
|
727
|
+
if (isInitialRender && !leftVNode.$key$ && rightVNode.$key$) {
|
|
728
|
+
leftVNode.$key$ = rightVNode.$key$;
|
|
729
|
+
}
|
|
703
730
|
return true;
|
|
704
731
|
}
|
|
705
732
|
return false;
|
|
@@ -746,8 +773,9 @@ var nullifyVNodeRefs = (vNode) => {
|
|
|
746
773
|
}
|
|
747
774
|
};
|
|
748
775
|
var insertBefore = (parent, newNode, reference) => {
|
|
749
|
-
|
|
750
|
-
|
|
776
|
+
{
|
|
777
|
+
return parent == null ? void 0 : parent.insertBefore(newNode, reference);
|
|
778
|
+
}
|
|
751
779
|
};
|
|
752
780
|
var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
753
781
|
const hostElm = hostRef.$hostElement$;
|
|
@@ -772,9 +800,6 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
772
800
|
rootVnode.$flags$ |= 4 /* isHost */;
|
|
773
801
|
hostRef.$vnode$ = rootVnode;
|
|
774
802
|
rootVnode.$elm$ = oldVNode.$elm$ = hostElm.shadowRoot || hostElm ;
|
|
775
|
-
{
|
|
776
|
-
scopeId = hostElm["s-sc"];
|
|
777
|
-
}
|
|
778
803
|
useNativeShadowDom = (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) !== 0;
|
|
779
804
|
patch(oldVNode, rootVnode, isInitialLoad);
|
|
780
805
|
};
|
|
@@ -782,7 +807,14 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
782
807
|
// src/runtime/update-component.ts
|
|
783
808
|
var attachToAncestor = (hostRef, ancestorComponent) => {
|
|
784
809
|
if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent["s-p"]) {
|
|
785
|
-
ancestorComponent["s-p"].push(
|
|
810
|
+
const index = ancestorComponent["s-p"].push(
|
|
811
|
+
new Promise(
|
|
812
|
+
(r) => hostRef.$onRenderResolve$ = () => {
|
|
813
|
+
ancestorComponent["s-p"].splice(index - 1, 1);
|
|
814
|
+
r();
|
|
815
|
+
}
|
|
816
|
+
)
|
|
817
|
+
);
|
|
786
818
|
}
|
|
787
819
|
};
|
|
788
820
|
var scheduleUpdate = (hostRef, isInitialLoad) => {
|
|
@@ -811,12 +843,12 @@ var dispatchHooks = (hostRef, isInitialLoad) => {
|
|
|
811
843
|
{
|
|
812
844
|
hostRef.$flags$ |= 256 /* isListenReady */;
|
|
813
845
|
if (hostRef.$queuedListeners$) {
|
|
814
|
-
hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event));
|
|
846
|
+
hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event, elm));
|
|
815
847
|
hostRef.$queuedListeners$ = void 0;
|
|
816
848
|
}
|
|
817
849
|
}
|
|
818
850
|
{
|
|
819
|
-
maybePromise = safeCall(instance, "componentWillLoad");
|
|
851
|
+
maybePromise = safeCall(instance, "componentWillLoad", void 0, elm);
|
|
820
852
|
}
|
|
821
853
|
}
|
|
822
854
|
endSchedule();
|
|
@@ -885,7 +917,7 @@ var postUpdateComponent = (hostRef) => {
|
|
|
885
917
|
const instance = hostRef.$lazyInstance$ ;
|
|
886
918
|
const ancestorComponent = hostRef.$ancestorComponent$;
|
|
887
919
|
{
|
|
888
|
-
safeCall(instance, "componentDidRender");
|
|
920
|
+
safeCall(instance, "componentDidRender", void 0, elm);
|
|
889
921
|
}
|
|
890
922
|
if (!(hostRef.$flags$ & 64 /* hasLoadedComponent */)) {
|
|
891
923
|
hostRef.$flags$ |= 64 /* hasLoadedComponent */;
|
|
@@ -893,7 +925,7 @@ var postUpdateComponent = (hostRef) => {
|
|
|
893
925
|
addHydratedFlag(elm);
|
|
894
926
|
}
|
|
895
927
|
{
|
|
896
|
-
safeCall(instance, "componentDidLoad");
|
|
928
|
+
safeCall(instance, "componentDidLoad", void 0, elm);
|
|
897
929
|
}
|
|
898
930
|
endPostUpdate();
|
|
899
931
|
{
|
|
@@ -922,12 +954,12 @@ var appDidLoad = (who) => {
|
|
|
922
954
|
}
|
|
923
955
|
nextTick(() => emitEvent(win, "appload", { detail: { namespace: NAMESPACE } }));
|
|
924
956
|
};
|
|
925
|
-
var safeCall = (instance, method, arg) => {
|
|
957
|
+
var safeCall = (instance, method, arg, elm) => {
|
|
926
958
|
if (instance && instance[method]) {
|
|
927
959
|
try {
|
|
928
960
|
return instance[method](arg);
|
|
929
961
|
} catch (e) {
|
|
930
|
-
consoleError(e);
|
|
962
|
+
consoleError(e, elm);
|
|
931
963
|
}
|
|
932
964
|
}
|
|
933
965
|
return void 0;
|
|
@@ -986,15 +1018,68 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
986
1018
|
const members = Object.entries((_a = cmpMeta.$members$) != null ? _a : {});
|
|
987
1019
|
members.map(([memberName, [memberFlags]]) => {
|
|
988
1020
|
if ((memberFlags & 31 /* Prop */ || (flags & 2 /* proxyState */) && memberFlags & 32 /* State */)) {
|
|
1021
|
+
const { get: origGetter, set: origSetter } = Object.getOwnPropertyDescriptor(prototype, memberName) || {};
|
|
1022
|
+
if (origGetter) cmpMeta.$members$[memberName][0] |= 2048 /* Getter */;
|
|
1023
|
+
if (origSetter) cmpMeta.$members$[memberName][0] |= 4096 /* Setter */;
|
|
1024
|
+
if (flags & 1 /* isElementConstructor */ || !origGetter) {
|
|
1025
|
+
Object.defineProperty(prototype, memberName, {
|
|
1026
|
+
get() {
|
|
1027
|
+
{
|
|
1028
|
+
if ((cmpMeta.$members$[memberName][0] & 2048 /* Getter */) === 0) {
|
|
1029
|
+
return getValue(this, memberName);
|
|
1030
|
+
}
|
|
1031
|
+
const ref = getHostRef(this);
|
|
1032
|
+
const instance = ref ? ref.$lazyInstance$ : prototype;
|
|
1033
|
+
if (!instance) return;
|
|
1034
|
+
return instance[memberName];
|
|
1035
|
+
}
|
|
1036
|
+
},
|
|
1037
|
+
configurable: true,
|
|
1038
|
+
enumerable: true
|
|
1039
|
+
});
|
|
1040
|
+
}
|
|
989
1041
|
Object.defineProperty(prototype, memberName, {
|
|
990
|
-
get() {
|
|
991
|
-
return getValue(this, memberName);
|
|
992
|
-
},
|
|
993
1042
|
set(newValue) {
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
1043
|
+
const ref = getHostRef(this);
|
|
1044
|
+
if (origSetter) {
|
|
1045
|
+
const currentValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
|
|
1046
|
+
if (typeof currentValue === "undefined" && ref.$instanceValues$.get(memberName)) {
|
|
1047
|
+
newValue = ref.$instanceValues$.get(memberName);
|
|
1048
|
+
} else if (!ref.$instanceValues$.get(memberName) && currentValue) {
|
|
1049
|
+
ref.$instanceValues$.set(memberName, currentValue);
|
|
1050
|
+
}
|
|
1051
|
+
origSetter.apply(this, [parsePropertyValue(newValue, memberFlags)]);
|
|
1052
|
+
newValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
|
|
1053
|
+
setValue(this, memberName, newValue, cmpMeta);
|
|
1054
|
+
return;
|
|
1055
|
+
}
|
|
1056
|
+
{
|
|
1057
|
+
if ((flags & 1 /* isElementConstructor */) === 0 || (cmpMeta.$members$[memberName][0] & 4096 /* Setter */) === 0) {
|
|
1058
|
+
setValue(this, memberName, newValue, cmpMeta);
|
|
1059
|
+
if (flags & 1 /* isElementConstructor */ && !ref.$lazyInstance$) {
|
|
1060
|
+
ref.$onReadyPromise$.then(() => {
|
|
1061
|
+
if (cmpMeta.$members$[memberName][0] & 4096 /* Setter */ && ref.$lazyInstance$[memberName] !== ref.$instanceValues$.get(memberName)) {
|
|
1062
|
+
ref.$lazyInstance$[memberName] = newValue;
|
|
1063
|
+
}
|
|
1064
|
+
});
|
|
1065
|
+
}
|
|
1066
|
+
return;
|
|
1067
|
+
}
|
|
1068
|
+
const setterSetVal = () => {
|
|
1069
|
+
const currentValue = ref.$lazyInstance$[memberName];
|
|
1070
|
+
if (!ref.$instanceValues$.get(memberName) && currentValue) {
|
|
1071
|
+
ref.$instanceValues$.set(memberName, currentValue);
|
|
1072
|
+
}
|
|
1073
|
+
ref.$lazyInstance$[memberName] = parsePropertyValue(newValue, memberFlags);
|
|
1074
|
+
setValue(this, memberName, ref.$lazyInstance$[memberName], cmpMeta);
|
|
1075
|
+
};
|
|
1076
|
+
if (ref.$lazyInstance$) {
|
|
1077
|
+
setterSetVal();
|
|
1078
|
+
} else {
|
|
1079
|
+
ref.$onReadyPromise$.then(() => setterSetVal());
|
|
1080
|
+
}
|
|
1081
|
+
}
|
|
1082
|
+
}
|
|
998
1083
|
});
|
|
999
1084
|
}
|
|
1000
1085
|
});
|
|
@@ -1004,7 +1089,7 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1004
1089
|
plt.jmp(() => {
|
|
1005
1090
|
var _a2;
|
|
1006
1091
|
const propName = attrNameToPropName.get(attrName);
|
|
1007
|
-
if (this.hasOwnProperty(propName)) {
|
|
1092
|
+
if (this.hasOwnProperty(propName) && BUILD.lazyLoad) {
|
|
1008
1093
|
newValue = this[propName];
|
|
1009
1094
|
delete this[propName];
|
|
1010
1095
|
} else if (prototype.hasOwnProperty(propName) && typeof this[propName] === "number" && // cast type to number to avoid TS compiler issues
|
|
@@ -1024,7 +1109,11 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1024
1109
|
}
|
|
1025
1110
|
return;
|
|
1026
1111
|
}
|
|
1027
|
-
|
|
1112
|
+
const propDesc = Object.getOwnPropertyDescriptor(prototype, propName);
|
|
1113
|
+
newValue = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
|
|
1114
|
+
if (newValue !== this[propName] && (!propDesc.get || !!propDesc.set)) {
|
|
1115
|
+
this[propName] = newValue;
|
|
1116
|
+
}
|
|
1028
1117
|
});
|
|
1029
1118
|
};
|
|
1030
1119
|
Cstr.observedAttributes = Array.from(
|
|
@@ -1051,9 +1140,8 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1051
1140
|
let Cstr;
|
|
1052
1141
|
if ((hostRef.$flags$ & 32 /* hasInitializedComponent */) === 0) {
|
|
1053
1142
|
hostRef.$flags$ |= 32 /* hasInitializedComponent */;
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
const CstrImport = loadModule(cmpMeta);
|
|
1143
|
+
{
|
|
1144
|
+
const CstrImport = loadModule(cmpMeta, hostRef);
|
|
1057
1145
|
if (CstrImport && "then" in CstrImport) {
|
|
1058
1146
|
const endLoad = uniqueTime();
|
|
1059
1147
|
Cstr = await CstrImport;
|
|
@@ -1078,7 +1166,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1078
1166
|
try {
|
|
1079
1167
|
new Cstr(hostRef);
|
|
1080
1168
|
} catch (e) {
|
|
1081
|
-
consoleError(e);
|
|
1169
|
+
consoleError(e, elm);
|
|
1082
1170
|
}
|
|
1083
1171
|
{
|
|
1084
1172
|
hostRef.$flags$ &= ~8 /* isConstructingInstance */;
|
|
@@ -1087,11 +1175,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1087
1175
|
hostRef.$flags$ |= 128 /* isWatchReady */;
|
|
1088
1176
|
}
|
|
1089
1177
|
endNewInstance();
|
|
1090
|
-
fireConnectedCallback(hostRef.$lazyInstance
|
|
1091
|
-
} else {
|
|
1092
|
-
Cstr = elm.constructor;
|
|
1093
|
-
const cmpTag = elm.localName;
|
|
1094
|
-
customElements.whenDefined(cmpTag).then(() => hostRef.$flags$ |= 128 /* isWatchReady */);
|
|
1178
|
+
fireConnectedCallback(hostRef.$lazyInstance$, elm);
|
|
1095
1179
|
}
|
|
1096
1180
|
if (Cstr && Cstr.style) {
|
|
1097
1181
|
let style;
|
|
@@ -1114,9 +1198,9 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1114
1198
|
schedule();
|
|
1115
1199
|
}
|
|
1116
1200
|
};
|
|
1117
|
-
var fireConnectedCallback = (instance) => {
|
|
1201
|
+
var fireConnectedCallback = (instance, elm) => {
|
|
1118
1202
|
{
|
|
1119
|
-
safeCall(instance, "connectedCallback");
|
|
1203
|
+
safeCall(instance, "connectedCallback", void 0, elm);
|
|
1120
1204
|
}
|
|
1121
1205
|
};
|
|
1122
1206
|
|
|
@@ -1152,17 +1236,17 @@ var connectedCallback = (elm) => {
|
|
|
1152
1236
|
} else {
|
|
1153
1237
|
addHostEventListeners(elm, hostRef, cmpMeta.$listeners$);
|
|
1154
1238
|
if (hostRef == null ? void 0 : hostRef.$lazyInstance$) {
|
|
1155
|
-
fireConnectedCallback(hostRef.$lazyInstance
|
|
1239
|
+
fireConnectedCallback(hostRef.$lazyInstance$, elm);
|
|
1156
1240
|
} else if (hostRef == null ? void 0 : hostRef.$onReadyPromise$) {
|
|
1157
|
-
hostRef.$onReadyPromise$.then(() => fireConnectedCallback(hostRef.$lazyInstance
|
|
1241
|
+
hostRef.$onReadyPromise$.then(() => fireConnectedCallback(hostRef.$lazyInstance$, elm));
|
|
1158
1242
|
}
|
|
1159
1243
|
}
|
|
1160
1244
|
endConnected();
|
|
1161
1245
|
}
|
|
1162
1246
|
};
|
|
1163
|
-
var disconnectInstance = (instance) => {
|
|
1247
|
+
var disconnectInstance = (instance, elm) => {
|
|
1164
1248
|
{
|
|
1165
|
-
safeCall(instance, "disconnectedCallback");
|
|
1249
|
+
safeCall(instance, "disconnectedCallback", void 0, elm || instance);
|
|
1166
1250
|
}
|
|
1167
1251
|
};
|
|
1168
1252
|
var disconnectedCallback = async (elm) => {
|
|
@@ -1175,11 +1259,17 @@ var disconnectedCallback = async (elm) => {
|
|
|
1175
1259
|
}
|
|
1176
1260
|
}
|
|
1177
1261
|
if (hostRef == null ? void 0 : hostRef.$lazyInstance$) {
|
|
1178
|
-
disconnectInstance(hostRef.$lazyInstance
|
|
1262
|
+
disconnectInstance(hostRef.$lazyInstance$, elm);
|
|
1179
1263
|
} else if (hostRef == null ? void 0 : hostRef.$onReadyPromise$) {
|
|
1180
|
-
hostRef.$onReadyPromise$.then(() => disconnectInstance(hostRef.$lazyInstance
|
|
1264
|
+
hostRef.$onReadyPromise$.then(() => disconnectInstance(hostRef.$lazyInstance$, elm));
|
|
1181
1265
|
}
|
|
1182
1266
|
}
|
|
1267
|
+
if (rootAppliedStyles.has(elm)) {
|
|
1268
|
+
rootAppliedStyles.delete(elm);
|
|
1269
|
+
}
|
|
1270
|
+
if (elm.shadowRoot && rootAppliedStyles.has(elm.shadowRoot)) {
|
|
1271
|
+
rootAppliedStyles.delete(elm.shadowRoot);
|
|
1272
|
+
}
|
|
1183
1273
|
};
|
|
1184
1274
|
|
|
1185
1275
|
// src/runtime/bootstrap-lazy.ts
|
|
@@ -1264,6 +1354,13 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
1264
1354
|
}
|
|
1265
1355
|
disconnectedCallback() {
|
|
1266
1356
|
plt.jmp(() => disconnectedCallback(this));
|
|
1357
|
+
plt.raf(() => {
|
|
1358
|
+
var _a3;
|
|
1359
|
+
const hostRef = getHostRef(this);
|
|
1360
|
+
if (((_a3 = hostRef == null ? void 0 : hostRef.$vnode$) == null ? void 0 : _a3.$elm$) instanceof Node && !hostRef.$vnode$.$elm$.isConnected) {
|
|
1361
|
+
delete hostRef.$vnode$.$elm$;
|
|
1362
|
+
}
|
|
1363
|
+
});
|
|
1267
1364
|
}
|
|
1268
1365
|
componentOnReady() {
|
|
1269
1366
|
return getHostRef(this).$onReadyPromise$;
|
|
@@ -1327,7 +1424,7 @@ var hostListenerProxy = (hostRef, methodName) => (ev) => {
|
|
|
1327
1424
|
}
|
|
1328
1425
|
}
|
|
1329
1426
|
} catch (e) {
|
|
1330
|
-
consoleError(e);
|
|
1427
|
+
consoleError(e, hostRef.$hostElement$);
|
|
1331
1428
|
}
|
|
1332
1429
|
};
|
|
1333
1430
|
var getHostListenerTarget = (elm, flags) => {
|