@rindo/core 1.17.4 → 2.5.2
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/LICENSE.md +27 -27
- package/bin/cli.ts +20 -0
- package/bin/rindo +51 -56
- package/cli/index.cjs +1263 -0
- package/cli/index.d.ts +1 -1
- package/cli/index.js +1232 -495
- package/cli/package.json +9 -4
- package/compiler/lib.d.ts +24 -0
- package/compiler/lib.dom.d.ts +20230 -0
- package/compiler/lib.dom.iterable.d.ts +351 -0
- package/compiler/lib.es2015.collection.d.ts +89 -0
- package/compiler/lib.es2015.core.d.ts +517 -0
- package/compiler/lib.es2015.d.ts +30 -0
- package/compiler/lib.es2015.generator.d.ts +79 -0
- package/compiler/lib.es2015.iterable.d.ts +505 -0
- package/compiler/lib.es2015.promise.d.ts +150 -0
- package/compiler/lib.es2015.proxy.d.ts +41 -0
- package/compiler/lib.es2015.reflect.d.ts +123 -0
- package/compiler/lib.es2015.symbol.d.ts +48 -0
- package/compiler/lib.es2015.symbol.wellknown.d.ts +324 -0
- package/compiler/lib.es2016.array.include.d.ts +118 -0
- package/compiler/lib.es2016.d.ts +22 -0
- package/compiler/lib.es2016.full.d.ts +25 -0
- package/compiler/lib.es2017.d.ts +26 -0
- package/compiler/lib.es2017.full.d.ts +25 -0
- package/compiler/lib.es2017.intl.d.ts +32 -0
- package/compiler/lib.es2017.object.d.ts +51 -0
- package/compiler/lib.es2017.sharedmemory.d.ts +137 -0
- package/compiler/lib.es2017.string.d.ts +47 -0
- package/compiler/lib.es2017.typedarrays.d.ts +55 -0
- package/compiler/lib.es2018.asyncgenerator.d.ts +79 -0
- package/compiler/lib.es2018.asynciterable.d.ts +45 -0
- package/compiler/lib.es2018.d.ts +26 -0
- package/compiler/lib.es2018.full.d.ts +25 -0
- package/compiler/lib.es2018.intl.d.ts +61 -0
- package/compiler/lib.es2018.promise.d.ts +32 -0
- package/compiler/lib.es2018.regexp.d.ts +39 -0
- package/compiler/lib.es2019.array.d.ts +85 -0
- package/compiler/lib.es2019.d.ts +25 -0
- package/compiler/lib.es2019.full.d.ts +25 -0
- package/compiler/lib.es2019.object.d.ts +35 -0
- package/compiler/lib.es2019.string.d.ts +33 -0
- package/compiler/lib.es2019.symbol.d.ts +26 -0
- package/compiler/lib.es2020.bigint.d.ts +728 -0
- package/compiler/lib.es2020.d.ts +27 -0
- package/compiler/lib.es2020.full.d.ts +25 -0
- package/compiler/lib.es2020.intl.d.ts +310 -0
- package/compiler/lib.es2020.promise.d.ts +50 -0
- package/compiler/lib.es2020.sharedmemory.d.ts +99 -0
- package/compiler/lib.es2020.string.d.ts +30 -0
- package/compiler/lib.es2020.symbol.wellknown.d.ts +39 -0
- package/compiler/lib.es5.d.ts +4435 -0
- package/compiler/lib.es6.d.ts +25 -0
- package/compiler/lib.esnext.d.ts +25 -0
- package/compiler/lib.esnext.full.d.ts +25 -0
- package/compiler/lib.esnext.intl.d.ts +32 -0
- package/compiler/lib.esnext.promise.d.ts +43 -0
- package/compiler/lib.esnext.string.d.ts +35 -0
- package/compiler/lib.esnext.weakref.d.ts +75 -0
- package/compiler/lib.scripthost.d.ts +327 -0
- package/compiler/lib.webworker.d.ts +6042 -0
- package/compiler/lib.webworker.importscripts.d.ts +26 -0
- package/compiler/lib.webworker.iterable.d.ts +166 -0
- package/compiler/package.json +3 -3
- package/compiler/rindo.d.ts +0 -16
- package/compiler/rindo.js +42738 -40541
- package/compiler/rindo.min.js +2 -15
- package/dependencies.json +73 -50
- package/dev-server/client/index.js +33 -10
- package/dev-server/client/package.json +3 -3
- package/dev-server/connector.html +3 -3
- package/dev-server/index.d.ts +3 -6
- package/dev-server/index.js +256 -252
- package/dev-server/package.json +3 -3
- package/dev-server/server-process.js +1738 -0
- package/dev-server/server-worker-thread.js +39 -0
- package/dev-server/templates/initial-load.html +160 -160
- package/dev-server/ws.js +1 -1
- package/internal/app-data/{index.cjs.js → index.cjs} +7 -5
- package/internal/app-data/index.d.ts +1 -0
- package/internal/app-data/index.js +7 -6
- package/internal/app-data/package.json +11 -5
- package/internal/client/css-shim.js +2 -2
- package/internal/client/dom.js +1 -1
- package/internal/client/index.js +193 -119
- package/internal/client/package.json +4 -3
- package/internal/client/{patch.js → patch-browser.js} +8 -24
- package/internal/client/patch-esm.js +23 -0
- package/internal/client/polyfills/css-shim.js +1 -1
- package/internal/client/polyfills/index.js +34 -34
- package/internal/client/shadow-css.js +9 -3
- package/internal/hydrate/index.js +305 -281
- package/internal/hydrate/package.json +2 -2
- package/internal/hydrate/runner.d.ts +24 -12
- package/internal/hydrate/runner.js +153 -124
- package/internal/hydrate/shadow-css.js +24 -24
- package/internal/package.json +5 -4
- package/internal/rindo-core/index.cjs +1 -0
- package/internal/rindo-core/index.d.ts +51 -2
- package/internal/rindo-core/index.js +15 -1
- package/internal/rindo-ext-modules.d.ts +41 -39
- package/internal/rindo-private.d.ts +93 -148
- package/internal/rindo-public-compiler.d.ts +231 -155
- package/internal/rindo-public-runtime.d.ts +42 -39
- package/internal/testing/index.js +144 -121
- package/internal/testing/package.json +2 -2
- package/internal/testing/shadow-css.js +24 -24
- package/mock-doc/index.cjs +4610 -0
- package/mock-doc/index.d.ts +12 -1
- package/mock-doc/index.js +177 -67
- package/mock-doc/package.json +11 -5
- package/package.json +132 -133
- package/readme.md +21 -95
- package/screenshot/compare/build/app.js +33 -33
- package/screenshot/compare/build/p-f4745c2f.entry.js +1 -1
- package/screenshot/connector-base.d.ts +1 -1
- package/screenshot/connector-local.d.ts +1 -1
- package/screenshot/index.js +63 -46
- package/screenshot/package.json +10 -3
- package/screenshot/pixel-match.js +54 -57
- package/screenshot/screenshot-compare.d.ts +1 -1
- package/screenshot/screenshot-fs.d.ts +1 -1
- package/sys/deno/index.js +1785 -0
- package/sys/deno/node-compat.js +2654 -0
- package/sys/deno/worker.js +44 -0
- package/sys/node/autoprefixer.js +8 -1
- package/sys/node/glob.js +1 -1
- package/sys/node/graceful-fs.js +1 -1
- package/sys/node/index.d.ts +1 -1
- package/sys/node/index.js +689 -705
- package/sys/node/node-fetch.js +1 -1
- package/sys/node/package.json +3 -3
- package/sys/node/prompts.js +1 -1
- package/sys/node/worker.js +38 -19
- package/testing/index.d.ts +3 -3
- package/testing/index.js +863 -749
- package/testing/jest/jest-config.d.ts +2 -89
- package/testing/jest/jest-environment.d.ts +1 -1
- package/testing/jest/jest-runner.d.ts +1 -1
- package/testing/jest/jest-screenshot.d.ts +1 -1
- package/testing/jest-preset.js +32 -32
- package/testing/matchers/events.d.ts +1 -1
- package/testing/matchers/screenshot.d.ts +1 -1
- package/testing/mock-fetch.d.ts +1 -1
- package/testing/mocks.d.ts +1 -1
- package/testing/package.json +3 -3
- package/testing/puppeteer/index.d.ts +1 -1
- package/testing/puppeteer/puppeteer-browser.d.ts +2 -2
- package/testing/puppeteer/puppeteer-declarations.d.ts +11 -11
- package/testing/puppeteer/puppeteer-element.d.ts +3 -3
- package/testing/puppeteer/puppeteer-emulate.d.ts +1 -1
- package/testing/puppeteer/puppeteer-events.d.ts +3 -3
- package/testing/puppeteer/puppeteer-page.d.ts +1 -1
- package/testing/puppeteer/puppeteer-screenshot.d.ts +2 -2
- package/testing/reset-build-conditionals.d.ts +1 -1
- package/testing/spec-page.d.ts +1 -1
- package/testing/test-transpile.d.ts +1 -1
- package/testing/testing-logger.d.ts +1 -1
- package/testing/testing-utils.d.ts +1 -1
- package/testing/testing.d.ts +1 -1
- package/cli/index.cjs.js +0 -524
- package/dev-server/content-type-db.json +0 -1
- package/dev-server/server-worker.js +0 -1570
- package/mock-doc/index.cjs.js +0 -4500
|
@@ -2,46 +2,49 @@ function componentOnReady() {
|
|
|
2
2
|
return getHostRef(this).$onReadyPromise$;
|
|
3
3
|
}
|
|
4
4
|
|
|
5
|
-
function forceUpdate
|
|
5
|
+
function forceUpdate() {}
|
|
6
6
|
|
|
7
7
|
function hydrateApp(e, t, o, n, s) {
|
|
8
|
-
function
|
|
9
|
-
global.clearTimeout(p), i.clear(), r.clear()
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
8
|
+
function a() {
|
|
9
|
+
if (global.clearTimeout(p), i.clear(), r.clear(), !h) {
|
|
10
|
+
h = !0;
|
|
11
|
+
try {
|
|
12
|
+
t.clientHydrateAnnotations && insertVdomAnnotations(e.document, t.staticComponents),
|
|
13
|
+
e.dispatchEvent(new e.Event("DOMContentLoaded")), e.document.createElement = c,
|
|
14
|
+
e.document.createElementNS = $;
|
|
15
|
+
} catch (e) {
|
|
16
|
+
renderCatchError(t, o, e);
|
|
17
|
+
}
|
|
15
18
|
}
|
|
16
19
|
n(e, t, o, s);
|
|
17
20
|
}
|
|
18
|
-
function
|
|
19
|
-
renderCatchError(t, o, e),
|
|
21
|
+
function l(e) {
|
|
22
|
+
renderCatchError(t, o, e), a();
|
|
20
23
|
}
|
|
21
24
|
const r = new Set, i = new Set, d = new Set, c = e.document.createElement, $ = e.document.createElementNS, m = Promise.resolve();
|
|
22
|
-
let p;
|
|
25
|
+
let p, h = !1;
|
|
23
26
|
try {
|
|
24
|
-
function
|
|
25
|
-
return
|
|
27
|
+
function u() {
|
|
28
|
+
return g(this);
|
|
26
29
|
}
|
|
27
|
-
function
|
|
30
|
+
function f(e) {
|
|
28
31
|
if (isValidComponent(e, t) && !getHostRef(e)) {
|
|
29
32
|
const t = loadModule({
|
|
30
33
|
$tagName$: e.nodeName.toLowerCase(),
|
|
31
34
|
$flags$: null
|
|
32
35
|
}, null);
|
|
33
|
-
null != t && null != t.cmpMeta && (i.add(e), e.connectedCallback =
|
|
36
|
+
null != t && null != t.cmpMeta && (i.add(e), e.connectedCallback = u, registerHost(e, t.cmpMeta),
|
|
34
37
|
function o(e, t) {
|
|
35
38
|
if ("function" != typeof e.componentOnReady && (e.componentOnReady = componentOnReady),
|
|
36
|
-
"function" != typeof e.forceUpdate && (e.forceUpdate = forceUpdate
|
|
39
|
+
"function" != typeof e.forceUpdate && (e.forceUpdate = forceUpdate), 1 & t.$flags$ && (e.shadowRoot = e),
|
|
37
40
|
null != t.$members$) {
|
|
38
41
|
const o = getHostRef(e);
|
|
39
|
-
Object.entries(t.$members$).forEach(([n, s]) => {
|
|
40
|
-
const
|
|
41
|
-
if (31 &
|
|
42
|
-
const
|
|
42
|
+
Object.entries(t.$members$).forEach((([n, s]) => {
|
|
43
|
+
const a = s[0];
|
|
44
|
+
if (31 & a) {
|
|
45
|
+
const l = s[1] || n, r = e.getAttribute(l);
|
|
43
46
|
if (null != r) {
|
|
44
|
-
const e = parsePropertyValue(r,
|
|
47
|
+
const e = parsePropertyValue(r, a);
|
|
45
48
|
o.$instanceValues$.set(n, e);
|
|
46
49
|
}
|
|
47
50
|
const i = e[n];
|
|
@@ -55,36 +58,31 @@ function hydrateApp(e, t, o, n, s) {
|
|
|
55
58
|
configurable: !0,
|
|
56
59
|
enumerable: !0
|
|
57
60
|
});
|
|
58
|
-
} else 64 &
|
|
61
|
+
} else 64 & a && Object.defineProperty(e, n, {
|
|
59
62
|
value() {
|
|
60
63
|
const e = getHostRef(this), t = arguments;
|
|
61
|
-
return e.$onInstancePromise$.then(() => e.$lazyInstance$[n].apply(e.$lazyInstance$, t)).catch(consoleError);
|
|
64
|
+
return e.$onInstancePromise$.then((() => e.$lazyInstance$[n].apply(e.$lazyInstance$, t))).catch(consoleError);
|
|
62
65
|
}
|
|
63
66
|
});
|
|
64
|
-
});
|
|
67
|
+
}));
|
|
65
68
|
}
|
|
66
69
|
}(e, t.cmpMeta));
|
|
67
70
|
}
|
|
68
71
|
}
|
|
69
|
-
function
|
|
70
|
-
return i.delete(n), isValidComponent(n, t) && o.hydratedCount < t.maxHydrateCount && !r.has(n) &&
|
|
71
|
-
|
|
72
|
-
if (NO_HYDRATE_TAGS.has(t.nodeName)) return !1;
|
|
73
|
-
if (t.hasAttribute("no-prerender")) return !1;
|
|
74
|
-
const o = t.parentNode;
|
|
75
|
-
return null == o || e(o);
|
|
76
|
-
}(n) ? (r.add(n), async function s(e, t, o, n, l) {
|
|
72
|
+
function g(n) {
|
|
73
|
+
return i.delete(n), isValidComponent(n, t) && o.hydratedCount < t.maxHydrateCount && !r.has(n) && shouldHydrate(n) ? (r.add(n),
|
|
74
|
+
async function s(e, t, o, n, a) {
|
|
77
75
|
o = o.toLowerCase();
|
|
78
|
-
const
|
|
76
|
+
const l = loadModule({
|
|
79
77
|
$tagName$: o,
|
|
80
78
|
$flags$: null
|
|
81
79
|
});
|
|
82
|
-
if (null !=
|
|
83
|
-
|
|
80
|
+
if (null != l && null != l.cmpMeta) {
|
|
81
|
+
a.add(n);
|
|
84
82
|
try {
|
|
85
83
|
connectedCallback(n), await n.componentOnReady(), t.hydratedCount++;
|
|
86
84
|
const e = getHostRef(n), s = e.$modeName$ ? e.$modeName$ : "$";
|
|
87
|
-
t.components.some(e => e.tag === o && e.mode === s) || t.components.push({
|
|
85
|
+
t.components.some((e => e.tag === o && e.mode === s)) || t.components.push({
|
|
88
86
|
tag: o,
|
|
89
87
|
mode: s,
|
|
90
88
|
count: 0,
|
|
@@ -93,33 +91,33 @@ function hydrateApp(e, t, o, n, s) {
|
|
|
93
91
|
} catch (t) {
|
|
94
92
|
e.console.error(t);
|
|
95
93
|
}
|
|
96
|
-
|
|
94
|
+
a.delete(n);
|
|
97
95
|
}
|
|
98
96
|
}(e, o, n.nodeName, n, d)) : m;
|
|
99
97
|
}
|
|
100
98
|
e.document.createElement = function t(o) {
|
|
101
99
|
const n = c.call(e.document, o);
|
|
102
|
-
return
|
|
100
|
+
return f(n), n;
|
|
103
101
|
}, e.document.createElementNS = function t(o, n) {
|
|
104
102
|
const s = $.call(e.document, o, n);
|
|
105
|
-
return
|
|
106
|
-
}, p = global.setTimeout((function
|
|
107
|
-
|
|
103
|
+
return f(s), s;
|
|
104
|
+
}, p = global.setTimeout((function L() {
|
|
105
|
+
l(`Hydrate exceeded timeout${function e(t) {
|
|
108
106
|
return Array.from(t).map(waitingOnElementMsg);
|
|
109
|
-
}(d));
|
|
107
|
+
}(d)}`);
|
|
110
108
|
}), t.timeout), plt.$resourcesUrl$ = new URL(t.resourcesUrl || "./", doc.baseURI).href,
|
|
111
109
|
globalScripts(), function e(t) {
|
|
112
110
|
if (null != t && 1 === t.nodeType) {
|
|
113
|
-
|
|
111
|
+
f(t);
|
|
114
112
|
const o = t.children;
|
|
115
113
|
for (let t = 0, n = o.length; t < n; t++) e(o[t]);
|
|
116
114
|
}
|
|
117
115
|
}(e.document.body), function e() {
|
|
118
|
-
const t = Array.from(i).filter(e => e.parentElement);
|
|
119
|
-
return t.length > 0 ? Promise.all(t.map(
|
|
120
|
-
}().then(
|
|
116
|
+
const t = Array.from(i).filter((e => e.parentElement));
|
|
117
|
+
return t.length > 0 ? Promise.all(t.map(g)).then(e) : m;
|
|
118
|
+
}().then(a).catch(l);
|
|
121
119
|
} catch (e) {
|
|
122
|
-
|
|
120
|
+
l(e);
|
|
123
121
|
}
|
|
124
122
|
}
|
|
125
123
|
|
|
@@ -131,6 +129,14 @@ function isValidComponent(e, t) {
|
|
|
131
129
|
return !1;
|
|
132
130
|
}
|
|
133
131
|
|
|
132
|
+
function shouldHydrate(e) {
|
|
133
|
+
if (9 === e.nodeType) return !0;
|
|
134
|
+
if (NO_HYDRATE_TAGS.has(e.nodeName)) return !1;
|
|
135
|
+
if (e.hasAttribute("no-prerender")) return !1;
|
|
136
|
+
const t = e.parentNode;
|
|
137
|
+
return null == t || shouldHydrate(t);
|
|
138
|
+
}
|
|
139
|
+
|
|
134
140
|
function renderCatchError(e, t, o) {
|
|
135
141
|
const n = {
|
|
136
142
|
level: "error",
|
|
@@ -150,10 +156,10 @@ function renderCatchError(e, t, o) {
|
|
|
150
156
|
}
|
|
151
157
|
|
|
152
158
|
function printTag(e) {
|
|
153
|
-
let t =
|
|
159
|
+
let t = `<${e.nodeName.toLowerCase()}`;
|
|
154
160
|
if (Array.isArray(e.attributes)) for (let o = 0; o < e.attributes.length; o++) {
|
|
155
161
|
const n = e.attributes[o];
|
|
156
|
-
t +=
|
|
162
|
+
t += ` ${n.name}`, "" !== n.value && (t += `="${n.value}"`);
|
|
157
163
|
}
|
|
158
164
|
return t += ">", t;
|
|
159
165
|
}
|
|
@@ -174,19 +180,23 @@ function waitingOnElementMsg(e) {
|
|
|
174
180
|
|
|
175
181
|
import { BUILD, NAMESPACE } from "@rindo/core/internal/app-data";
|
|
176
182
|
|
|
177
|
-
export { BUILD, NAMESPACE } from "@rindo/core/internal/app-data";
|
|
183
|
+
export { BUILD, Env, NAMESPACE } from "@rindo/core/internal/app-data";
|
|
178
184
|
|
|
179
185
|
import { globalScripts } from "@rindo/core/internal/app-globals";
|
|
180
186
|
|
|
181
187
|
const addHostEventListeners = (e, t, o, n) => {
|
|
182
|
-
BUILD.hostListener && o && (BUILD.hostListenerTargetParent && (o = n ? o.filter(([e]) =>
|
|
183
|
-
o.map(([o, n, s]) => {
|
|
184
|
-
const
|
|
185
|
-
plt.ael(
|
|
186
|
-
}));
|
|
188
|
+
BUILD.hostListener && o && (BUILD.hostListenerTargetParent && (o = n ? o.filter((([e]) => 32 & e)) : o.filter((([e]) => !(32 & e)))),
|
|
189
|
+
o.map((([o, n, s]) => {
|
|
190
|
+
const a = BUILD.hostListenerTarget ? getHostListenerTarget(e, o) : e, l = hostListenerProxy(t, s), r = hostListenerOpts(o);
|
|
191
|
+
plt.ael(a, n, l, r), (t.$rmListeners$ = t.$rmListeners$ || []).push((() => plt.rel(a, n, l, r)));
|
|
192
|
+
})));
|
|
187
193
|
}, hostListenerProxy = (e, t) => o => {
|
|
188
|
-
|
|
189
|
-
|
|
194
|
+
try {
|
|
195
|
+
BUILD.lazyLoad ? 256 & e.$flags$ ? e.$lazyInstance$[t](o) : (e.$queuedListeners$ = e.$queuedListeners$ || []).push([ t, o ]) : e.$hostElement$[t](o);
|
|
196
|
+
} catch (e) {
|
|
197
|
+
consoleError(e);
|
|
198
|
+
}
|
|
199
|
+
}, getHostListenerTarget = (e, t) => BUILD.hostListenerTargetDocument && 4 & t ? doc : BUILD.hostListenerTargetWindow && 8 & t ? win : BUILD.hostListenerTargetBody && 16 & t ? doc.body : BUILD.hostListenerTargetParent && 32 & t ? e.parentElement : e, hostListenerOpts = e => 0 != (2 & e), XLINK_NS = "http://www.w3.org/1999/xlink";
|
|
190
200
|
|
|
191
201
|
let i = 0;
|
|
192
202
|
|
|
@@ -200,46 +210,45 @@ const createTime = (e, t = "") => {
|
|
|
200
210
|
let n = styles.get(e);
|
|
201
211
|
n = t, styles.set(e, n);
|
|
202
212
|
}, addStyle = (e, t, o, n) => {
|
|
203
|
-
let s = getScopeId(t, o),
|
|
213
|
+
let s = getScopeId(t, o), a = styles.get(s);
|
|
204
214
|
if (!BUILD.attachStyles) return s;
|
|
205
|
-
if (e = 11 === e.nodeType ? e : doc,
|
|
215
|
+
if (e = 11 === e.nodeType ? e : doc, a) if ("string" == typeof a) {
|
|
206
216
|
e = e.head || e;
|
|
207
|
-
let o,
|
|
208
|
-
if (
|
|
209
|
-
if (BUILD.hydrateClientSide && e.host && (o = e.querySelector(`[sty-id="${s}"]`))) o.innerHTML =
|
|
217
|
+
let o, l = rootAppliedStyles.get(e);
|
|
218
|
+
if (l || rootAppliedStyles.set(e, l = new Set), !l.has(s)) {
|
|
219
|
+
if (BUILD.hydrateClientSide && e.host && (o = e.querySelector(`[sty-id="${s}"]`))) o.innerHTML = a; else {
|
|
210
220
|
if (BUILD.cssVarShim && plt.$cssShim$) {
|
|
211
|
-
o = plt.$cssShim$.createHostStyle(n, s,
|
|
221
|
+
o = plt.$cssShim$.createHostStyle(n, s, a, !!(10 & t.$flags$));
|
|
212
222
|
const e = o["s-sc"];
|
|
213
|
-
e && (s = e,
|
|
214
|
-
} else o = doc.createElement("style"), o.innerHTML =
|
|
223
|
+
e && (s = e, l = null);
|
|
224
|
+
} else o = doc.createElement("style"), o.innerHTML = a;
|
|
215
225
|
(BUILD.hydrateServerSide || BUILD.hotModuleReplacement) && o.setAttribute("sty-id", s),
|
|
216
226
|
e.insertBefore(o, e.querySelector("link"));
|
|
217
227
|
}
|
|
218
|
-
|
|
228
|
+
l && l.add(s);
|
|
219
229
|
}
|
|
220
|
-
} else BUILD.constructableCSS && !e.adoptedStyleSheets.includes(
|
|
230
|
+
} else BUILD.constructableCSS && !e.adoptedStyleSheets.includes(a) && (e.adoptedStyleSheets = [ ...e.adoptedStyleSheets, a ]);
|
|
221
231
|
return s;
|
|
222
232
|
}, attachStyles = e => {
|
|
223
|
-
const t = e.$cmpMeta$, o = e.$hostElement$, n = t.$flags$, s = createTime("attachStyles", t.$tagName$),
|
|
224
|
-
(BUILD.shadowDom || BUILD.scoped) && BUILD.cssAnnotations && 10 & n && (o["s-sc"] =
|
|
225
|
-
o.classList.add(
|
|
233
|
+
const t = e.$cmpMeta$, o = e.$hostElement$, n = t.$flags$, s = createTime("attachStyles", t.$tagName$), a = addStyle(BUILD.shadowDom && supportsShadow && o.shadowRoot ? o.shadowRoot : o.getRootNode(), t, e.$modeName$, o);
|
|
234
|
+
(BUILD.shadowDom || BUILD.scoped) && BUILD.cssAnnotations && 10 & n && (o["s-sc"] = a,
|
|
235
|
+
o.classList.add(a + "-h"), BUILD.scoped && 2 & n && o.classList.add(a + "-s")),
|
|
226
236
|
s();
|
|
227
|
-
}, getScopeId = (e, t) => "sc-" + (BUILD.mode && t && 32 & e.$flags$ ? e.$tagName$ + "-" + t : e.$tagName$), computeMode = e => modeResolutionChain.map(t => t(e)).find(e => !!e), setMode = e => modeResolutionChain.push(e), getMode = e => getHostRef(e).$modeName$, EMPTY_OBJ = {},
|
|
228
|
-
|
|
229
|
-
let n = null, s = null, l = null, a = !1, r = !1, i = [];
|
|
237
|
+
}, getScopeId = (e, t) => "sc-" + (BUILD.mode && t && 32 & e.$flags$ ? e.$tagName$ + "-" + t : e.$tagName$), computeMode = e => modeResolutionChain.map((t => t(e))).find((e => !!e)), setMode = e => modeResolutionChain.push(e), getMode = e => getHostRef(e).$modeName$, EMPTY_OBJ = {}, isComplexType = e => "object" == (e = typeof e) || "function" === e, isPromise = e => !!e && ("object" == typeof e || "function" == typeof e) && "function" == typeof e.then, h = (e, t, ...o) => {
|
|
238
|
+
let n = null, s = null, a = null, l = !1, r = !1, i = [];
|
|
230
239
|
const d = t => {
|
|
231
|
-
for (let o = 0; o < t.length; o++) n = t[o], Array.isArray(n) ? d(n) : null != n && "boolean" != typeof n && ((
|
|
232
|
-
|
|
240
|
+
for (let o = 0; o < t.length; o++) n = t[o], Array.isArray(n) ? d(n) : null != n && "boolean" != typeof n && ((l = "function" != typeof e && !isComplexType(n)) ? n = String(n) : BUILD.isDev && "function" != typeof e && n.$flags$,
|
|
241
|
+
l && r ? i[i.length - 1].$text$ += n : i.push(l ? newVNode(null, n) : n), r = l);
|
|
233
242
|
};
|
|
234
243
|
if (d(o), t && (BUILD.isDev && "input" === e && validateInputProperties(t), BUILD.vdomKey && t.key && (s = t.key),
|
|
235
|
-
BUILD.slotRelocation && t.name && (
|
|
244
|
+
BUILD.slotRelocation && t.name && (a = t.name), BUILD.vdomClass)) {
|
|
236
245
|
const e = t.className || t.class;
|
|
237
|
-
e && (t.class = "object" != typeof e ? e : Object.keys(e).filter(t => e[t]).join(" "));
|
|
246
|
+
e && (t.class = "object" != typeof e ? e : Object.keys(e).filter((t => e[t])).join(" "));
|
|
238
247
|
}
|
|
239
248
|
if (BUILD.isDev && i.some(isHost), BUILD.vdomFunctional && "function" == typeof e) return e(null === t ? {} : t, i, vdomFnUtils);
|
|
240
249
|
const c = newVNode(e, null);
|
|
241
250
|
return c.$attrs$ = t, i.length > 0 && (c.$children$ = i), BUILD.vdomKey && (c.$key$ = s),
|
|
242
|
-
BUILD.slotRelocation && (c.$name$ =
|
|
251
|
+
BUILD.slotRelocation && (c.$name$ = a), c;
|
|
243
252
|
}, newVNode = (e, t) => {
|
|
244
253
|
const o = {
|
|
245
254
|
$flags$: 0,
|
|
@@ -262,7 +271,9 @@ IS_NODE_ENV && global.process.platform, process.cwd, process.exit, e => "object"
|
|
|
262
271
|
vtext: e.$text$
|
|
263
272
|
}), convertToPrivate = e => {
|
|
264
273
|
if ("function" == typeof e.vtag) {
|
|
265
|
-
const t =
|
|
274
|
+
const t = {
|
|
275
|
+
...e.vattrs
|
|
276
|
+
};
|
|
266
277
|
return e.vkey && (t.key = e.vkey), e.vname && (t.name = e.vname), h(e.vtag, t, ...e.vchildren || []);
|
|
267
278
|
}
|
|
268
279
|
const t = newVNode(e.vtag, e.vtext);
|
|
@@ -271,54 +282,54 @@ IS_NODE_ENV && global.process.platform, process.cwd, process.exit, e => "object"
|
|
|
271
282
|
}, validateInputProperties = e => {
|
|
272
283
|
const t = Object.keys(e);
|
|
273
284
|
t.indexOf("type"), t.indexOf("min"), t.indexOf("max"), t.indexOf("min"), t.indexOf("value");
|
|
274
|
-
}, setAccessor = (e, t, o, n, s,
|
|
285
|
+
}, setAccessor = (e, t, o, n, s, a) => {
|
|
275
286
|
if (o !== n) {
|
|
276
|
-
let
|
|
287
|
+
let l = isMemberInElement(e, t), r = t.toLowerCase();
|
|
277
288
|
if (BUILD.vdomClass && "class" === t) {
|
|
278
|
-
const t = e.classList, s = parseClassList(o),
|
|
279
|
-
t.remove(...s.filter(e => e && !
|
|
289
|
+
const t = e.classList, s = parseClassList(o), a = parseClassList(n);
|
|
290
|
+
t.remove(...s.filter((e => e && !a.includes(e)))), t.add(...a.filter((e => e && !s.includes(e))));
|
|
280
291
|
} else if (BUILD.vdomStyle && "style" === t) {
|
|
281
292
|
if (BUILD.updatable) for (const t in o) n && null != n[t] || (!BUILD.hydrateServerSide && t.includes("-") ? e.style.removeProperty(t) : e.style[t] = "");
|
|
282
293
|
for (const t in n) o && n[t] === o[t] || (!BUILD.hydrateServerSide && t.includes("-") ? e.style.setProperty(t, n[t]) : e.style[t] = n[t]);
|
|
283
|
-
} else if (BUILD.vdomKey && "key" === t) ; else if (BUILD.vdomRef && "ref" === t) n && n(e); else if (!BUILD.vdomListener || (BUILD.lazyLoad ?
|
|
294
|
+
} else if (BUILD.vdomKey && "key" === t) ; else if (BUILD.vdomRef && "ref" === t) n && n(e); else if (!BUILD.vdomListener || (BUILD.lazyLoad ? l : e.__lookupSetter__(t)) || "o" !== t[0] || "n" !== t[1]) {
|
|
284
295
|
if (BUILD.vdomPropOrAttr) {
|
|
285
296
|
const i = isComplexType(n);
|
|
286
|
-
if ((
|
|
297
|
+
if ((l || i && null !== n) && !s) try {
|
|
287
298
|
if (e.tagName.includes("-")) e[t] = n; else {
|
|
288
299
|
let s = null == n ? "" : n;
|
|
289
|
-
"list" === t ?
|
|
300
|
+
"list" === t ? l = !1 : null != o && e[t] == s || (e[t] = s);
|
|
290
301
|
}
|
|
291
302
|
} catch (e) {}
|
|
292
303
|
let d = !1;
|
|
293
|
-
BUILD.vdomXlink && r !== (r = r.replace(/^xlink\:?/, "")) && (t = r, d = !0), null == n || !1 === n ? !1 === n && "" !== e.getAttribute(t) || (BUILD.vdomXlink && d ? e.removeAttributeNS(XLINK_NS, t) : e.removeAttribute(t)) : (!
|
|
304
|
+
BUILD.vdomXlink && r !== (r = r.replace(/^xlink\:?/, "")) && (t = r, d = !0), null == n || !1 === n ? !1 === n && "" !== e.getAttribute(t) || (BUILD.vdomXlink && d ? e.removeAttributeNS(XLINK_NS, t) : e.removeAttribute(t)) : (!l || 4 & a || s) && !i && (n = !0 === n ? "" : n,
|
|
294
305
|
BUILD.vdomXlink && d ? e.setAttributeNS(XLINK_NS, t, n) : e.setAttribute(t, n));
|
|
295
306
|
}
|
|
296
307
|
} else t = "-" === t[2] ? t.slice(3) : isMemberInElement(win, r) ? r.slice(2) : r[2] + t.slice(3),
|
|
297
308
|
o && plt.rel(e, t, o, !1), n && plt.ael(e, t, n, !1);
|
|
298
309
|
}
|
|
299
310
|
}, parseClassListRegex = /\s/, parseClassList = e => e ? e.split(parseClassListRegex) : [], updateElement = (e, t, o, n) => {
|
|
300
|
-
const s = 11 === t.$elm$.nodeType && t.$elm$.host ? t.$elm$.host : t.$elm$,
|
|
301
|
-
if (BUILD.updatable) for (n in
|
|
302
|
-
for (n in
|
|
311
|
+
const s = 11 === t.$elm$.nodeType && t.$elm$.host ? t.$elm$.host : t.$elm$, a = e && e.$attrs$ || EMPTY_OBJ, l = t.$attrs$ || EMPTY_OBJ;
|
|
312
|
+
if (BUILD.updatable) for (n in a) n in l || setAccessor(s, n, a[n], void 0, o, t.$flags$);
|
|
313
|
+
for (n in l) setAccessor(s, n, a[n], l[n], o, t.$flags$);
|
|
303
314
|
};
|
|
304
315
|
|
|
305
316
|
let scopeId, contentRef, hostTagName, useNativeShadowDom = !1, checkSlotFallbackVisibility = !1, checkSlotRelocate = !1, isSvgMode = !1;
|
|
306
317
|
|
|
307
318
|
const createElm = (e, t, o, n) => {
|
|
308
|
-
let s,
|
|
319
|
+
let s, a, l, r = t.$children$[o], i = 0;
|
|
309
320
|
if (BUILD.slotRelocation && !useNativeShadowDom && (checkSlotRelocate = !0, "slot" === r.$tag$ && (scopeId && n.classList.add(scopeId + "-s"),
|
|
310
|
-
r.$flags$ |= r.$children$ ? 2 : 1)), BUILD.isDev && r.$elm$ &&
|
|
321
|
+
r.$flags$ |= r.$children$ ? 2 : 1)), BUILD.isDev && r.$elm$ && consoleDevError(`The JSX ${null !== r.$text$ ? `"${r.$text$}" text` : `"${r.$tag$}" element`} node should not be shared within the same renderer. The renderer caches element lookups in order to improve performance. However, a side effect from this is that the exact same JSX node should not be reused. For more information please see https://rindojs.web.app/docs/templating-jsx#avoid-shared-jsx-nodes`),
|
|
311
322
|
BUILD.vdomText && null !== r.$text$) s = r.$elm$ = doc.createTextNode(r.$text$); else if (BUILD.slotRelocation && 1 & r.$flags$) s = r.$elm$ = BUILD.isDebug || BUILD.hydrateServerSide ? slotReferenceDebugNode(r) : doc.createTextNode(""); else {
|
|
312
323
|
if (BUILD.svg && !isSvgMode && (isSvgMode = "svg" === r.$tag$), s = r.$elm$ = BUILD.svg ? doc.createElementNS(isSvgMode ? "http://www.w3.org/2000/svg" : "http://www.w3.org/1999/xhtml", BUILD.slotRelocation && 2 & r.$flags$ ? "slot-fb" : r.$tag$) : doc.createElement(BUILD.slotRelocation && 2 & r.$flags$ ? "slot-fb" : r.$tag$),
|
|
313
324
|
BUILD.svg && isSvgMode && "foreignObject" === r.$tag$ && (isSvgMode = !1), BUILD.vdomAttribute && updateElement(null, r, isSvgMode),
|
|
314
325
|
(BUILD.shadowDom || BUILD.scoped) && null != scopeId && s["s-si"] !== scopeId && s.classList.add(s["s-si"] = scopeId),
|
|
315
|
-
r.$children$) for (i = 0; i < r.$children$.length; ++i)
|
|
316
|
-
|
|
326
|
+
r.$children$) for (i = 0; i < r.$children$.length; ++i) a = createElm(e, r, i, s),
|
|
327
|
+
a && s.appendChild(a);
|
|
317
328
|
BUILD.svg && ("svg" === r.$tag$ ? isSvgMode = !1 : "foreignObject" === s.tagName && (isSvgMode = !0));
|
|
318
329
|
}
|
|
319
330
|
return BUILD.slotRelocation && (s["s-hn"] = hostTagName, 3 & r.$flags$ && (s["s-sr"] = !0,
|
|
320
|
-
s["s-cr"] = contentRef, s["s-sn"] = r.$name$ || "",
|
|
321
|
-
|
|
331
|
+
s["s-cr"] = contentRef, s["s-sn"] = r.$name$ || "", l = e && e.$children$ && e.$children$[o],
|
|
332
|
+
l && l.$tag$ === r.$tag$ && e.$elm$ && putBackInOriginalLocation(e.$elm$, !1))),
|
|
322
333
|
s;
|
|
323
334
|
}, putBackInOriginalLocation = (e, t) => {
|
|
324
335
|
plt.$flags$ |= 1;
|
|
@@ -329,63 +340,63 @@ const createElm = (e, t, o, n) => {
|
|
|
329
340
|
n["s-ol"].remove(), n["s-ol"] = void 0, checkSlotRelocate = !0), t && putBackInOriginalLocation(n, t);
|
|
330
341
|
}
|
|
331
342
|
plt.$flags$ &= -2;
|
|
332
|
-
}, addVnodes = (e, t, o, n, s,
|
|
333
|
-
let
|
|
334
|
-
for (BUILD.shadowDom && r.shadowRoot && r.tagName === hostTagName && (r = r.shadowRoot); s <=
|
|
335
|
-
|
|
343
|
+
}, addVnodes = (e, t, o, n, s, a) => {
|
|
344
|
+
let l, r = BUILD.slotRelocation && e["s-cr"] && e["s-cr"].parentNode || e;
|
|
345
|
+
for (BUILD.shadowDom && r.shadowRoot && r.tagName === hostTagName && (r = r.shadowRoot); s <= a; ++s) n[s] && (l = createElm(null, o, s, e),
|
|
346
|
+
l && (n[s].$elm$ = l, r.insertBefore(l, BUILD.slotRelocation ? referenceNode(t) : t)));
|
|
336
347
|
}, removeVnodes = (e, t, o, n, s) => {
|
|
337
348
|
for (;t <= o; ++t) (n = e[t]) && (s = n.$elm$, callNodeRefs(n), BUILD.slotRelocation && (checkSlotFallbackVisibility = !0,
|
|
338
349
|
s["s-ol"] ? s["s-ol"].remove() : putBackInOriginalLocation(s, !0)), s.remove());
|
|
339
350
|
}, isSameVnode = (e, t) => e.$tag$ === t.$tag$ && (BUILD.slotRelocation && "slot" === e.$tag$ ? e.$name$ === t.$name$ : !BUILD.vdomKey || e.$key$ === t.$key$), referenceNode = e => e && e["s-ol"] || e, parentReferenceNode = e => (e["s-ol"] ? e["s-ol"] : e).parentNode, patch = (e, t) => {
|
|
340
|
-
const o = t.$elm$ = e.$elm$, n = e.$children$, s = t.$children$,
|
|
351
|
+
const o = t.$elm$ = e.$elm$, n = e.$children$, s = t.$children$, a = t.$tag$, l = t.$text$;
|
|
341
352
|
let r;
|
|
342
|
-
BUILD.vdomText && null !==
|
|
343
|
-
(BUILD.vdomAttribute || BUILD.reflect) && (BUILD.slot && "slot" ===
|
|
353
|
+
BUILD.vdomText && null !== l ? BUILD.vdomText && BUILD.slotRelocation && (r = o["s-cr"]) ? r.parentNode.textContent = l : BUILD.vdomText && e.$text$ !== l && (o.data = l) : (BUILD.svg && (isSvgMode = "svg" === a || "foreignObject" !== a && isSvgMode),
|
|
354
|
+
(BUILD.vdomAttribute || BUILD.reflect) && (BUILD.slot && "slot" === a || updateElement(e, t, isSvgMode)),
|
|
344
355
|
BUILD.updatable && null !== n && null !== s ? ((e, t, o, n) => {
|
|
345
|
-
let s,
|
|
346
|
-
for (;
|
|
347
|
-
$ = t[++
|
|
348
|
-
patch($, u), e.insertBefore($.$elm$, m.$elm$.nextSibling), $ = t[++
|
|
356
|
+
let s, a, l = 0, r = 0, i = 0, d = 0, c = t.length - 1, $ = t[0], m = t[c], p = n.length - 1, h = n[0], u = n[p];
|
|
357
|
+
for (;l <= c && r <= p; ) if (null == $) $ = t[++l]; else if (null == m) m = t[--c]; else if (null == h) h = n[++r]; else if (null == u) u = n[--p]; else if (isSameVnode($, h)) patch($, h),
|
|
358
|
+
$ = t[++l], h = n[++r]; else if (isSameVnode(m, u)) patch(m, u), m = t[--c], u = n[--p]; else if (isSameVnode($, u)) !BUILD.slotRelocation || "slot" !== $.$tag$ && "slot" !== u.$tag$ || putBackInOriginalLocation($.$elm$.parentNode, !1),
|
|
359
|
+
patch($, u), e.insertBefore($.$elm$, m.$elm$.nextSibling), $ = t[++l], u = n[--p]; else if (isSameVnode(m, h)) !BUILD.slotRelocation || "slot" !== $.$tag$ && "slot" !== u.$tag$ || putBackInOriginalLocation(m.$elm$.parentNode, !1),
|
|
349
360
|
patch(m, h), e.insertBefore(m.$elm$, $.$elm$), m = t[--c], h = n[++r]; else {
|
|
350
|
-
if (i = -1, BUILD.vdomKey) for (d =
|
|
361
|
+
if (i = -1, BUILD.vdomKey) for (d = l; d <= c; ++d) if (t[d] && null !== t[d].$key$ && t[d].$key$ === h.$key$) {
|
|
351
362
|
i = d;
|
|
352
363
|
break;
|
|
353
364
|
}
|
|
354
|
-
BUILD.vdomKey && i >= 0 ? (
|
|
355
|
-
t[i] = void 0, s =
|
|
365
|
+
BUILD.vdomKey && i >= 0 ? (a = t[i], a.$tag$ !== h.$tag$ ? s = createElm(t && t[r], o, i, e) : (patch(a, h),
|
|
366
|
+
t[i] = void 0, s = a.$elm$), h = n[++r]) : (s = createElm(t && t[r], o, r, e), h = n[++r]),
|
|
356
367
|
s && (BUILD.slotRelocation ? parentReferenceNode($.$elm$).insertBefore(s, referenceNode($.$elm$)) : $.$elm$.parentNode.insertBefore(s, $.$elm$));
|
|
357
368
|
}
|
|
358
|
-
|
|
369
|
+
l > c ? addVnodes(e, null == n[p + 1] ? null : n[p + 1].$elm$, o, n, r, p) : BUILD.updatable && r > p && removeVnodes(t, l, c);
|
|
359
370
|
})(o, n, t, s) : null !== s ? (BUILD.updatable && BUILD.vdomText && null !== e.$text$ && (o.textContent = ""),
|
|
360
371
|
addVnodes(o, null, t, s, 0, s.length - 1)) : BUILD.updatable && null !== n && removeVnodes(n, 0, n.length - 1),
|
|
361
|
-
BUILD.svg && isSvgMode && "svg" ===
|
|
372
|
+
BUILD.svg && isSvgMode && "svg" === a && (isSvgMode = !1));
|
|
362
373
|
}, updateFallbackSlotVisibility = e => {
|
|
363
|
-
let t, o, n, s,
|
|
374
|
+
let t, o, n, s, a, l, r = e.childNodes;
|
|
364
375
|
for (o = 0, n = r.length; o < n; o++) if (t = r[o], 1 === t.nodeType) {
|
|
365
|
-
if (t["s-sr"]) for (
|
|
366
|
-
"" !==
|
|
367
|
-
if (1 ===
|
|
376
|
+
if (t["s-sr"]) for (a = t["s-sn"], t.hidden = !1, s = 0; s < n; s++) if (l = r[s].nodeType,
|
|
377
|
+
r[s]["s-hn"] !== t["s-hn"] || "" !== a) {
|
|
378
|
+
if (1 === l && a === r[s].getAttribute("slot")) {
|
|
368
379
|
t.hidden = !0;
|
|
369
380
|
break;
|
|
370
381
|
}
|
|
371
|
-
} else if (1 ===
|
|
382
|
+
} else if (1 === l || 3 === l && "" !== r[s].textContent.trim()) {
|
|
372
383
|
t.hidden = !0;
|
|
373
384
|
break;
|
|
374
385
|
}
|
|
375
386
|
updateFallbackSlotVisibility(t);
|
|
376
387
|
}
|
|
377
388
|
}, relocateNodes = [], relocateSlotContent = e => {
|
|
378
|
-
let t, o, n, s,
|
|
389
|
+
let t, o, n, s, a, l, r = 0, i = e.childNodes, d = i.length;
|
|
379
390
|
for (;r < d; r++) {
|
|
380
|
-
if (t = i[r], t["s-sr"] && (o = t["s-cr"])) for (n = o.parentNode.childNodes,
|
|
381
|
-
|
|
382
|
-
checkSlotFallbackVisibility = !0, o["s-sn"] = o["s-sn"] || s,
|
|
391
|
+
if (t = i[r], t["s-sr"] && (o = t["s-cr"]) && o.parentNode) for (n = o.parentNode.childNodes,
|
|
392
|
+
s = t["s-sn"], l = n.length - 1; l >= 0; l--) o = n[l], o["s-cn"] || o["s-nr"] || o["s-hn"] === t["s-hn"] || (isNodeLocatedInSlot(o, s) ? (a = relocateNodes.find((e => e.$nodeToRelocate$ === o)),
|
|
393
|
+
checkSlotFallbackVisibility = !0, o["s-sn"] = o["s-sn"] || s, a ? a.$slotRefNode$ = t : relocateNodes.push({
|
|
383
394
|
$slotRefNode$: t,
|
|
384
395
|
$nodeToRelocate$: o
|
|
385
|
-
}), o["s-sr"] && relocateNodes.map(e => {
|
|
386
|
-
isNodeLocatedInSlot(e.$nodeToRelocate$, o["s-sn"]) && (
|
|
387
|
-
|
|
388
|
-
})) : relocateNodes.some(e => e.$nodeToRelocate$ === o) || relocateNodes.push({
|
|
396
|
+
}), o["s-sr"] && relocateNodes.map((e => {
|
|
397
|
+
isNodeLocatedInSlot(e.$nodeToRelocate$, o["s-sn"]) && (a = relocateNodes.find((e => e.$nodeToRelocate$ === o)),
|
|
398
|
+
a && !e.$slotRefNode$ && (e.$slotRefNode$ = a.$slotRefNode$));
|
|
399
|
+
}))) : relocateNodes.some((e => e.$nodeToRelocate$ === o)) || relocateNodes.push({
|
|
389
400
|
$nodeToRelocate$: o
|
|
390
401
|
}));
|
|
391
402
|
1 === t.nodeType && relocateSlotContent(t);
|
|
@@ -393,32 +404,32 @@ const createElm = (e, t, o, n) => {
|
|
|
393
404
|
}, isNodeLocatedInSlot = (e, t) => 1 === e.nodeType ? null === e.getAttribute("slot") && "" === t || e.getAttribute("slot") === t : e["s-sn"] === t || "" === t, callNodeRefs = e => {
|
|
394
405
|
BUILD.vdomRef && (e.$attrs$ && e.$attrs$.ref && e.$attrs$.ref(null), e.$children$ && e.$children$.map(callNodeRefs));
|
|
395
406
|
}, renderVdom = (e, t) => {
|
|
396
|
-
const o = e.$hostElement$, n = e.$cmpMeta$, s = e.$vnode$ || newVNode(null, null),
|
|
407
|
+
const o = e.$hostElement$, n = e.$cmpMeta$, s = e.$vnode$ || newVNode(null, null), a = isHost(t) ? t : h(null, null, t);
|
|
397
408
|
if (hostTagName = o.tagName, BUILD.isDev && Array.isArray(t) && t.some(isHost)) throw new Error(`The <Host> must be the single root component.\nLooks like the render() function of "${hostTagName.toLowerCase()}" is returning an array that contains the <Host>.\n\nThe render() function should look like this instead:\n\nrender() {\n // Do not return an array\n return (\n <Host>{content}</Host>\n );\n}\n `);
|
|
398
|
-
if (BUILD.reflect && n.$attrsToReflect$ && (
|
|
399
|
-
|
|
409
|
+
if (BUILD.reflect && n.$attrsToReflect$ && (a.$attrs$ = a.$attrs$ || {}, n.$attrsToReflect$.map((([e, t]) => a.$attrs$[t] = o[e]))),
|
|
410
|
+
a.$tag$ = null, a.$flags$ |= 4, e.$vnode$ = a, a.$elm$ = s.$elm$ = BUILD.shadowDom && o.shadowRoot || o,
|
|
400
411
|
(BUILD.scoped || BUILD.shadowDom) && (scopeId = o["s-sc"]), BUILD.slotRelocation && (contentRef = o["s-cr"],
|
|
401
|
-
useNativeShadowDom = supportsShadow, checkSlotFallbackVisibility = !1), patch(s,
|
|
412
|
+
useNativeShadowDom = supportsShadow, checkSlotFallbackVisibility = !1), patch(s, a),
|
|
402
413
|
BUILD.slotRelocation) {
|
|
403
414
|
if (plt.$flags$ |= 1, checkSlotRelocate) {
|
|
404
|
-
let e, t, o, n, s,
|
|
405
|
-
relocateSlotContent(
|
|
415
|
+
let e, t, o, n, s, l;
|
|
416
|
+
relocateSlotContent(a.$elm$);
|
|
406
417
|
let r = 0;
|
|
407
418
|
for (;r < relocateNodes.length; r++) e = relocateNodes[r], t = e.$nodeToRelocate$,
|
|
408
419
|
t["s-ol"] || (o = BUILD.isDebug || BUILD.hydrateServerSide ? originalLocationDebugNode(t) : doc.createTextNode(""),
|
|
409
420
|
o["s-nr"] = t, t.parentNode.insertBefore(t["s-ol"] = o, t));
|
|
410
421
|
for (r = 0; r < relocateNodes.length; r++) if (e = relocateNodes[r], t = e.$nodeToRelocate$,
|
|
411
422
|
e.$slotRefNode$) {
|
|
412
|
-
for (n = e.$slotRefNode$.parentNode, s = e.$slotRefNode$.nextSibling, o = t["s-ol"]; o = o.previousSibling; ) if (
|
|
413
|
-
|
|
414
|
-
s =
|
|
423
|
+
for (n = e.$slotRefNode$.parentNode, s = e.$slotRefNode$.nextSibling, o = t["s-ol"]; o = o.previousSibling; ) if (l = o["s-nr"],
|
|
424
|
+
l && l["s-sn"] === t["s-sn"] && n === l.parentNode && (l = l.nextSibling, !l || !l["s-nr"])) {
|
|
425
|
+
s = l;
|
|
415
426
|
break;
|
|
416
427
|
}
|
|
417
428
|
(!s && n !== t.parentNode || t.nextSibling !== s) && t !== s && (!t["s-hn"] && t["s-ol"] && (t["s-hn"] = t["s-ol"].parentNode.nodeName),
|
|
418
429
|
n.insertBefore(t, s));
|
|
419
430
|
} else 1 === t.nodeType && (t.hidden = !0);
|
|
420
431
|
}
|
|
421
|
-
checkSlotFallbackVisibility && updateFallbackSlotVisibility(
|
|
432
|
+
checkSlotFallbackVisibility && updateFallbackSlotVisibility(a.$elm$), plt.$flags$ &= -2,
|
|
422
433
|
relocateNodes.length = 0;
|
|
423
434
|
}
|
|
424
435
|
}, slotReferenceDebugNode = e => doc.createComment(`<slot${e.$name$ ? ' name="' + e.$name$ + '"' : ""}> (host=${hostTagName.toLowerCase()})`), originalLocationDebugNode = e => doc.createComment("org-location for " + (e.localName ? `<${e.localName}> (host=${e["s-hn"]})` : `[${e.textContent}]`)), getElement = e => BUILD.lazyLoad ? getHostRef(e).$hostElement$ : e, createEvent = (e, t, o) => {
|
|
@@ -435,32 +446,32 @@ const createElm = (e, t, o, n) => {
|
|
|
435
446
|
const n = plt.ce(t, o);
|
|
436
447
|
return e.dispatchEvent(n), n;
|
|
437
448
|
}, attachToAncestor = (e, t) => {
|
|
438
|
-
BUILD.asyncLoading && t && !e.$onRenderResolve$ && t["s-p"] && t["s-p"].push(new Promise(t => e.$onRenderResolve$ = t));
|
|
449
|
+
BUILD.asyncLoading && t && !e.$onRenderResolve$ && t["s-p"] && t["s-p"].push(new Promise((t => e.$onRenderResolve$ = t)));
|
|
439
450
|
}, scheduleUpdate = (e, t) => {
|
|
440
451
|
if (BUILD.taskQueue && BUILD.updatable && (e.$flags$ |= 16), BUILD.asyncLoading && 4 & e.$flags$) return void (e.$flags$ |= 512);
|
|
441
452
|
attachToAncestor(e, e.$ancestorComponent$);
|
|
442
453
|
const o = () => dispatchHooks(e, t);
|
|
443
|
-
return BUILD.taskQueue ? writeTask(o) : o;
|
|
454
|
+
return BUILD.taskQueue ? writeTask(o) : o();
|
|
444
455
|
}, dispatchHooks = (e, t) => {
|
|
445
456
|
const o = e.$hostElement$, n = createTime("scheduleUpdate", e.$cmpMeta$.$tagName$), s = BUILD.lazyLoad ? e.$lazyInstance$ : o;
|
|
446
|
-
let
|
|
447
|
-
return t ? (BUILD.lazyLoad && BUILD.hostListener && (e.$flags$ |= 256, e.$queuedListeners$ && (e.$queuedListeners$.map(([e, t]) => safeCall(s, e, t)),
|
|
448
|
-
e.$queuedListeners$ = null)), emitLifecycleEvent(o, "componentWillLoad"), BUILD.cmpWillLoad && (
|
|
449
|
-
BUILD.cmpWillUpdate && (
|
|
450
|
-
BUILD.cmpWillRender && (
|
|
451
|
-
n(), then(
|
|
452
|
-
}, updateComponent = (e, t, o) => {
|
|
453
|
-
const n = e.$hostElement$, s = createTime("update", e.$cmpMeta$.$tagName$),
|
|
457
|
+
let a;
|
|
458
|
+
return t ? (BUILD.lazyLoad && BUILD.hostListener && (e.$flags$ |= 256, e.$queuedListeners$ && (e.$queuedListeners$.map((([e, t]) => safeCall(s, e, t))),
|
|
459
|
+
e.$queuedListeners$ = null)), emitLifecycleEvent(o, "componentWillLoad"), BUILD.cmpWillLoad && (a = safeCall(s, "componentWillLoad"))) : (emitLifecycleEvent(o, "componentWillUpdate"),
|
|
460
|
+
BUILD.cmpWillUpdate && (a = safeCall(s, "componentWillUpdate"))), emitLifecycleEvent(o, "componentWillRender"),
|
|
461
|
+
BUILD.cmpWillRender && (a = then(a, (() => safeCall(s, "componentWillRender")))),
|
|
462
|
+
n(), then(a, (() => updateComponent(e, s, t)));
|
|
463
|
+
}, updateComponent = async (e, t, o) => {
|
|
464
|
+
const n = e.$hostElement$, s = createTime("update", e.$cmpMeta$.$tagName$), a = n["s-rc"];
|
|
454
465
|
BUILD.style && o && attachStyles(e);
|
|
455
|
-
const
|
|
456
|
-
if (BUILD.isDev && (e.$flags$ |= 1024),
|
|
466
|
+
const l = createTime("render", e.$cmpMeta$.$tagName$);
|
|
467
|
+
if (BUILD.isDev && (e.$flags$ |= 1024), BUILD.hydrateServerSide ? await callRender(e, t, n) : callRender(e, t, n),
|
|
457
468
|
BUILD.cssVarShim && plt.$cssShim$ && plt.$cssShim$.updateHost(n), BUILD.isDev && (e.$renderCount$++,
|
|
458
469
|
e.$flags$ &= -1025), BUILD.hydrateServerSide) try {
|
|
459
470
|
serverSideConnected(n), o && (1 & e.$cmpMeta$.$flags$ ? n["s-en"] = "" : 2 & e.$cmpMeta$.$flags$ && (n["s-en"] = "c"));
|
|
460
471
|
} catch (e) {
|
|
461
|
-
consoleError(e);
|
|
472
|
+
consoleError(e, n);
|
|
462
473
|
}
|
|
463
|
-
if (BUILD.asyncLoading &&
|
|
474
|
+
if (BUILD.asyncLoading && a && (a.map((e => e())), n["s-rc"] = void 0), l(), s(),
|
|
464
475
|
BUILD.asyncLoading) {
|
|
465
476
|
const t = n["s-p"], o = () => postUpdateComponent(e);
|
|
466
477
|
0 === t.length ? o() : (Promise.all(t).then(o), e.$flags$ |= 4, t.length = 0);
|
|
@@ -469,17 +480,20 @@ const createElm = (e, t, o, n) => {
|
|
|
469
480
|
|
|
470
481
|
let renderingRef = null;
|
|
471
482
|
|
|
472
|
-
const callRender = (e, t) => {
|
|
473
|
-
const
|
|
483
|
+
const callRender = (e, t, o) => {
|
|
484
|
+
const n = !!BUILD.allRenderFn, s = !!BUILD.lazyLoad, a = !!BUILD.taskQueue, l = !!BUILD.updatable;
|
|
474
485
|
try {
|
|
475
|
-
renderingRef = t, t = (
|
|
476
|
-
(l ||
|
|
477
|
-
|
|
478
|
-
|
|
486
|
+
if (renderingRef = t, t = (n || t.render) && t.render(), l && a && (e.$flags$ &= -17),
|
|
487
|
+
(l || s) && (e.$flags$ |= 2), BUILD.hasRenderFn || BUILD.reflect) if (BUILD.vdomRender || BUILD.reflect) {
|
|
488
|
+
if (BUILD.hydrateServerSide) return Promise.resolve(t).then((t => renderVdom(e, t)));
|
|
489
|
+
renderVdom(e, t);
|
|
490
|
+
} else o.textContent = t;
|
|
491
|
+
} catch (t) {
|
|
492
|
+
consoleError(t, e.$hostElement$);
|
|
479
493
|
}
|
|
480
|
-
return renderingRef = null,
|
|
494
|
+
return renderingRef = null, null;
|
|
481
495
|
}, getRenderingRef = () => renderingRef, postUpdateComponent = e => {
|
|
482
|
-
const t = e.$cmpMeta$.$tagName$, o = e.$hostElement$, n = createTime("postUpdate", t), s = BUILD.lazyLoad ? e.$lazyInstance$ : o,
|
|
496
|
+
const t = e.$cmpMeta$.$tagName$, o = e.$hostElement$, n = createTime("postUpdate", t), s = BUILD.lazyLoad ? e.$lazyInstance$ : o, a = e.$ancestorComponent$;
|
|
483
497
|
BUILD.cmpDidRender && (BUILD.isDev && (e.$flags$ |= 1024), safeCall(s, "componentDidRender"),
|
|
484
498
|
BUILD.isDev && (e.$flags$ &= -1025)), emitLifecycleEvent(o, "componentDidRender"),
|
|
485
499
|
64 & e.$flags$ ? (BUILD.cmpDidUpdate && (BUILD.isDev && (e.$flags$ |= 1024), safeCall(s, "componentDidUpdate"),
|
|
@@ -487,11 +501,11 @@ const callRender = (e, t) => {
|
|
|
487
501
|
n()) : (e.$flags$ |= 64, BUILD.asyncLoading && BUILD.cssAnnotations && addHydratedFlag(o),
|
|
488
502
|
BUILD.cmpDidLoad && (BUILD.isDev && (e.$flags$ |= 2048), safeCall(s, "componentDidLoad"),
|
|
489
503
|
BUILD.isDev && (e.$flags$ &= -2049)), emitLifecycleEvent(o, "componentDidLoad"),
|
|
490
|
-
n(), BUILD.asyncLoading && (e.$onReadyResolve$(o),
|
|
504
|
+
n(), BUILD.asyncLoading && (e.$onReadyResolve$(o), a || appDidLoad(t))), BUILD.hotModuleReplacement && o["s-hmr-load"] && o["s-hmr-load"](),
|
|
491
505
|
BUILD.method && BUILD.lazyLoad && e.$onInstanceResolve$(o), BUILD.asyncLoading && (e.$onRenderResolve$ && (e.$onRenderResolve$(),
|
|
492
|
-
e.$onRenderResolve$ = void 0), 512 & e.$flags$ && nextTick(() => scheduleUpdate(e, !1)),
|
|
506
|
+
e.$onRenderResolve$ = void 0), 512 & e.$flags$ && nextTick((() => scheduleUpdate(e, !1))),
|
|
493
507
|
e.$flags$ &= -517);
|
|
494
|
-
}, forceUpdate = e => {
|
|
508
|
+
}, forceUpdate$1 = e => {
|
|
495
509
|
if (BUILD.updatable) {
|
|
496
510
|
const t = getHostRef(e), o = t.$hostElement$.isConnected;
|
|
497
511
|
return o && 2 == (18 & t.$flags$) && scheduleUpdate(t, !1), o;
|
|
@@ -499,11 +513,11 @@ const callRender = (e, t) => {
|
|
|
499
513
|
return !1;
|
|
500
514
|
}, appDidLoad = e => {
|
|
501
515
|
BUILD.cssAnnotations && addHydratedFlag(doc.documentElement), BUILD.asyncQueue && (plt.$flags$ |= 2),
|
|
502
|
-
nextTick(() => emitEvent(win, "appload", {
|
|
516
|
+
nextTick((() => emitEvent(win, "appload", {
|
|
503
517
|
detail: {
|
|
504
518
|
namespace: NAMESPACE
|
|
505
519
|
}
|
|
506
|
-
})), BUILD.profile && performance.measure && performance.measure(`[Rindo] ${NAMESPACE} initial load (by ${e})`, "st:app:start");
|
|
520
|
+
}))), BUILD.profile && performance.measure && performance.measure(`[Rindo] ${NAMESPACE} initial load (by ${e})`, "st:app:start");
|
|
507
521
|
}, safeCall = (e, t, o) => {
|
|
508
522
|
if (e && e[t]) try {
|
|
509
523
|
return e[t](o);
|
|
@@ -524,49 +538,49 @@ const callRender = (e, t) => {
|
|
|
524
538
|
const o = t[e];
|
|
525
539
|
"function" == typeof o.connectedCallback && o.connectedCallback(), serverSideConnected(o);
|
|
526
540
|
}
|
|
527
|
-
}, clientHydrate = (e, t, o, n, s,
|
|
541
|
+
}, clientHydrate = (e, t, o, n, s, a, l) => {
|
|
528
542
|
let r, i, d, c;
|
|
529
|
-
if (1 ===
|
|
530
|
-
for (r =
|
|
543
|
+
if (1 === a.nodeType) {
|
|
544
|
+
for (r = a.getAttribute("c-id"), r && (i = r.split("."), i[0] !== l && "0" !== i[0] || (d = {
|
|
531
545
|
$flags$: 0,
|
|
532
546
|
$hostId$: i[0],
|
|
533
547
|
$nodeId$: i[1],
|
|
534
548
|
$depth$: i[2],
|
|
535
549
|
$index$: i[3],
|
|
536
|
-
$tag$:
|
|
537
|
-
$elm$:
|
|
550
|
+
$tag$: a.tagName.toLowerCase(),
|
|
551
|
+
$elm$: a,
|
|
538
552
|
$attrs$: null,
|
|
539
553
|
$children$: null,
|
|
540
554
|
$key$: null,
|
|
541
555
|
$name$: null,
|
|
542
556
|
$text$: null
|
|
543
|
-
}, t.push(d),
|
|
544
|
-
e = d, n && "0" === d.$depth$ && (n[d.$index$] = d.$elm$))), c =
|
|
545
|
-
if (
|
|
546
|
-
} else if (8 ===
|
|
557
|
+
}, t.push(d), a.removeAttribute("c-id"), e.$children$ || (e.$children$ = []), e.$children$[d.$index$] = d,
|
|
558
|
+
e = d, n && "0" === d.$depth$ && (n[d.$index$] = d.$elm$))), c = a.childNodes.length - 1; c >= 0; c--) clientHydrate(e, t, o, n, s, a.childNodes[c], l);
|
|
559
|
+
if (a.shadowRoot) for (c = a.shadowRoot.childNodes.length - 1; c >= 0; c--) clientHydrate(e, t, o, n, s, a.shadowRoot.childNodes[c], l);
|
|
560
|
+
} else if (8 === a.nodeType) i = a.nodeValue.split("."), i[1] !== l && "0" !== i[1] || (r = i[0],
|
|
547
561
|
d = {
|
|
548
562
|
$flags$: 0,
|
|
549
563
|
$hostId$: i[1],
|
|
550
564
|
$nodeId$: i[2],
|
|
551
565
|
$depth$: i[3],
|
|
552
566
|
$index$: i[4],
|
|
553
|
-
$elm$:
|
|
567
|
+
$elm$: a,
|
|
554
568
|
$attrs$: null,
|
|
555
569
|
$children$: null,
|
|
556
570
|
$key$: null,
|
|
557
571
|
$name$: null,
|
|
558
572
|
$tag$: null,
|
|
559
573
|
$text$: null
|
|
560
|
-
}, "t" === r ? (d.$elm$ =
|
|
561
|
-
t.push(d),
|
|
562
|
-
n && "0" === d.$depth$ && (n[d.$index$] = d.$elm$))) : d.$hostId$ ===
|
|
563
|
-
i[5] ?
|
|
564
|
-
d.$name$ && d.$elm$.setAttribute("name", d.$name$),
|
|
565
|
-
|
|
566
|
-
e.$children$[d.$index$] = d) : "r" === r && (BUILD.shadowDom && n ?
|
|
567
|
-
|
|
568
|
-
const t = newVNode(null,
|
|
569
|
-
t.$elm$ =
|
|
574
|
+
}, "t" === r ? (d.$elm$ = a.nextSibling, d.$elm$ && 3 === d.$elm$.nodeType && (d.$text$ = d.$elm$.textContent,
|
|
575
|
+
t.push(d), a.remove(), e.$children$ || (e.$children$ = []), e.$children$[d.$index$] = d,
|
|
576
|
+
n && "0" === d.$depth$ && (n[d.$index$] = d.$elm$))) : d.$hostId$ === l && ("s" === r ? (d.$tag$ = "slot",
|
|
577
|
+
i[5] ? a["s-sn"] = d.$name$ = i[5] : a["s-sn"] = "", a["s-sr"] = !0, BUILD.shadowDom && n && (d.$elm$ = doc.createElement(d.$tag$),
|
|
578
|
+
d.$name$ && d.$elm$.setAttribute("name", d.$name$), a.parentNode.insertBefore(d.$elm$, a),
|
|
579
|
+
a.remove(), "0" === d.$depth$ && (n[d.$index$] = d.$elm$)), o.push(d), e.$children$ || (e.$children$ = []),
|
|
580
|
+
e.$children$[d.$index$] = d) : "r" === r && (BUILD.shadowDom && n ? a.remove() : BUILD.slotRelocation && (s["s-cr"] = a,
|
|
581
|
+
a["s-cn"] = !0)))); else if (e && "style" === e.$tag$) {
|
|
582
|
+
const t = newVNode(null, a.textContent);
|
|
583
|
+
t.$elm$ = a, t.$index$ = "0", e.$children$ = [ t ];
|
|
570
584
|
}
|
|
571
585
|
}, initializeDocumentHydrate = (e, t) => {
|
|
572
586
|
if (1 === e.nodeType) {
|
|
@@ -578,21 +592,21 @@ const callRender = (e, t) => {
|
|
|
578
592
|
"o" === o[0] && (t.set(o[1] + "." + o[2], e), e.nodeValue = "", e["s-en"] = o[3]);
|
|
579
593
|
}
|
|
580
594
|
}, parsePropertyValue = (e, t) => null == e || isComplexType(e) ? e : BUILD.propBoolean && 4 & t ? "false" !== e && ("" === e || !!e) : BUILD.propNumber && 2 & t ? parseFloat(e) : BUILD.propString && 1 & t ? String(e) : e, getValue = (e, t) => getHostRef(e).$instanceValues$.get(t), setValue = (e, t, o, n) => {
|
|
581
|
-
const s = getHostRef(e),
|
|
582
|
-
if (o = parsePropertyValue(o, n.$members$[t][0]), !(BUILD.lazyLoad && 8 & r && void 0 !==
|
|
595
|
+
const s = getHostRef(e), a = BUILD.lazyLoad ? s.$hostElement$ : e, l = s.$instanceValues$.get(t), r = s.$flags$, i = BUILD.lazyLoad ? s.$lazyInstance$ : a;
|
|
596
|
+
if (o = parsePropertyValue(o, n.$members$[t][0]), !(BUILD.lazyLoad && 8 & r && void 0 !== l || o === l) && (s.$instanceValues$.set(t, o),
|
|
583
597
|
BUILD.isDev && (1024 & s.$flags$ || s.$flags$), !BUILD.lazyLoad || i)) {
|
|
584
598
|
if (BUILD.watchCallback && n.$watchers$ && 128 & r) {
|
|
585
599
|
const e = n.$watchers$[t];
|
|
586
|
-
e && e.map(e => {
|
|
600
|
+
e && e.map((e => {
|
|
587
601
|
try {
|
|
588
|
-
i[e](o,
|
|
602
|
+
i[e](o, l, t);
|
|
589
603
|
} catch (e) {
|
|
590
|
-
consoleError(e);
|
|
604
|
+
consoleError(e, a);
|
|
591
605
|
}
|
|
592
|
-
});
|
|
606
|
+
}));
|
|
593
607
|
}
|
|
594
608
|
if (BUILD.updatable && 2 == (18 & r)) {
|
|
595
|
-
if (BUILD.cmpShouldUpdate && i.componentShouldUpdate && !1 === i.componentShouldUpdate(o,
|
|
609
|
+
if (BUILD.cmpShouldUpdate && i.componentShouldUpdate && !1 === i.componentShouldUpdate(o, l, t)) return;
|
|
596
610
|
scheduleUpdate(s, !1);
|
|
597
611
|
}
|
|
598
612
|
}
|
|
@@ -600,13 +614,16 @@ const callRender = (e, t) => {
|
|
|
600
614
|
if (BUILD.member && t.$members$) {
|
|
601
615
|
BUILD.watchCallback && e.watchers && (t.$watchers$ = e.watchers);
|
|
602
616
|
const n = Object.entries(t.$members$), s = e.prototype;
|
|
603
|
-
if (n.map(([e, [n]]) => {
|
|
617
|
+
if (n.map((([e, [n]]) => {
|
|
604
618
|
(BUILD.prop || BUILD.state) && (31 & n || (!BUILD.lazyLoad || 2 & o) && 32 & n) ? Object.defineProperty(s, e, {
|
|
605
619
|
get() {
|
|
606
620
|
return getValue(this, e);
|
|
607
621
|
},
|
|
608
622
|
set(s) {
|
|
609
|
-
BUILD.isDev
|
|
623
|
+
if (BUILD.isDev) {
|
|
624
|
+
const s = getHostRef(this);
|
|
625
|
+
0 == (1 & o) && 0 == (8 & s.$flags$) && 0 != (31 & n) && 0 == (1024 & n) && consoleDevWarn(`@Prop() "${e}" on <${t.$tagName$}> is immutable but was modified from within the component.\nMore information: https://rindojs.web.app/docs/properties#prop-mutability`);
|
|
626
|
+
}
|
|
610
627
|
setValue(this, e, s, t);
|
|
611
628
|
},
|
|
612
629
|
configurable: !0,
|
|
@@ -614,21 +631,21 @@ const callRender = (e, t) => {
|
|
|
614
631
|
}) : BUILD.lazyLoad && BUILD.method && 1 & o && 64 & n && Object.defineProperty(s, e, {
|
|
615
632
|
value(...t) {
|
|
616
633
|
const o = getHostRef(this);
|
|
617
|
-
return o.$onInstancePromise$.then(() => o.$lazyInstance$[e](...t));
|
|
634
|
+
return o.$onInstancePromise$.then((() => o.$lazyInstance$[e](...t)));
|
|
618
635
|
}
|
|
619
636
|
});
|
|
620
|
-
}), BUILD.observeAttribute && (!BUILD.lazyLoad || 1 & o)) {
|
|
637
|
+
})), BUILD.observeAttribute && (!BUILD.lazyLoad || 1 & o)) {
|
|
621
638
|
const o = new Map;
|
|
622
639
|
s.attributeChangedCallback = function(e, t, n) {
|
|
623
|
-
plt.jmp(() => {
|
|
640
|
+
plt.jmp((() => {
|
|
624
641
|
const t = o.get(e);
|
|
625
642
|
this[t] = (null !== n || "boolean" != typeof this[t]) && n;
|
|
626
|
-
});
|
|
627
|
-
}, e.observedAttributes = n.filter(([e, t]) => 15 & t[0]).map(([e, n]) => {
|
|
643
|
+
}));
|
|
644
|
+
}, e.observedAttributes = n.filter((([e, t]) => 15 & t[0])).map((([e, n]) => {
|
|
628
645
|
const s = n[1] || e;
|
|
629
646
|
return o.set(s, e), BUILD.reflect && 512 & n[0] && t.$attrsToReflect$.push([ e, s ]),
|
|
630
647
|
s;
|
|
631
|
-
});
|
|
648
|
+
}));
|
|
632
649
|
}
|
|
633
650
|
}
|
|
634
651
|
return e;
|
|
@@ -636,10 +653,10 @@ const callRender = (e, t) => {
|
|
|
636
653
|
if ((BUILD.lazyLoad || BUILD.hydrateServerSide || BUILD.style) && 0 == (32 & t.$flags$)) {
|
|
637
654
|
if (BUILD.lazyLoad || BUILD.hydrateClientSide) {
|
|
638
655
|
if (t.$flags$ |= 32, (s = loadModule(o)).then) {
|
|
639
|
-
const e = (
|
|
640
|
-
BUILD.profile && performance.mark ? (0 === performance.getEntriesByName(
|
|
656
|
+
const e = (a = `st:load:${o.$tagName$}:${t.$modeName$}`, l = `[Rindo] Load module for <${o.$tagName$}>`,
|
|
657
|
+
BUILD.profile && performance.mark ? (0 === performance.getEntriesByName(a).length && performance.mark(a),
|
|
641
658
|
() => {
|
|
642
|
-
0 === performance.getEntriesByName(
|
|
659
|
+
0 === performance.getEntriesByName(l).length && performance.measure(l, a);
|
|
643
660
|
}) : () => {});
|
|
644
661
|
s = await s, e();
|
|
645
662
|
}
|
|
@@ -659,15 +676,15 @@ const callRender = (e, t) => {
|
|
|
659
676
|
if (BUILD.style && s.style) {
|
|
660
677
|
let n = s.style;
|
|
661
678
|
BUILD.mode && "string" != typeof n && (n = n[t.$modeName$ = computeMode(e)], BUILD.hydrateServerSide && t.$modeName$ && e.setAttribute("s-mode", t.$modeName$));
|
|
662
|
-
const
|
|
663
|
-
if (!styles.has(
|
|
679
|
+
const a = getScopeId(o, t.$modeName$);
|
|
680
|
+
if (!styles.has(a)) {
|
|
664
681
|
const e = createTime("registerStyles", o.$tagName$);
|
|
665
|
-
!BUILD.hydrateServerSide && BUILD.shadowDom && BUILD.shadowDomShim && 8 & o.$flags$ && (n = await import("./shadow-css.js").then(e => e.scopeCss(n,
|
|
666
|
-
registerStyle(
|
|
682
|
+
!BUILD.hydrateServerSide && BUILD.shadowDom && BUILD.shadowDomShim && 8 & o.$flags$ && (n = await import("./shadow-css.js").then((e => e.scopeCss(n, a, !1)))),
|
|
683
|
+
registerStyle(a, n, o.$flags$), e();
|
|
667
684
|
}
|
|
668
685
|
}
|
|
669
686
|
}
|
|
670
|
-
var
|
|
687
|
+
var a, l;
|
|
671
688
|
const r = t.$ancestorComponent$, i = () => scheduleUpdate(t, !0);
|
|
672
689
|
BUILD.asyncLoading && r && r["s-rc"] ? r["s-rc"].push(i) : i();
|
|
673
690
|
}, fireConnectedCallback = e => {
|
|
@@ -684,15 +701,15 @@ const callRender = (e, t) => {
|
|
|
684
701
|
e.classList.remove(t + "-h", t + "-s");
|
|
685
702
|
}
|
|
686
703
|
((e, t, o, n) => {
|
|
687
|
-
const s = createTime("hydrateClient", t),
|
|
704
|
+
const s = createTime("hydrateClient", t), a = e.shadowRoot, l = [], r = BUILD.shadowDom && a ? [] : null, i = n.$vnode$ = newVNode(t, null);
|
|
688
705
|
plt.$orgLocNodes$ || initializeDocumentHydrate(doc.body, plt.$orgLocNodes$ = new Map),
|
|
689
|
-
e["s-id"] = o, e.removeAttribute("s-id"), clientHydrate(i,
|
|
706
|
+
e["s-id"] = o, e.removeAttribute("s-id"), clientHydrate(i, l, [], r, e, e, o), l.map((e => {
|
|
690
707
|
const o = e.$hostId$ + "." + e.$nodeId$, n = plt.$orgLocNodes$.get(o), s = e.$elm$;
|
|
691
708
|
n && supportsShadow && "" === n["s-en"] && n.parentNode.insertBefore(s, n.nextSibling),
|
|
692
|
-
|
|
693
|
-
}), BUILD.shadowDom &&
|
|
694
|
-
e &&
|
|
695
|
-
}), s();
|
|
709
|
+
a || (s["s-hn"] = t, n && (s["s-ol"] = n, s["s-ol"]["s-nr"] = s)), plt.$orgLocNodes$.delete(o);
|
|
710
|
+
})), BUILD.shadowDom && a && r.map((e => {
|
|
711
|
+
e && a.appendChild(e);
|
|
712
|
+
})), s();
|
|
696
713
|
})(e, o.$tagName$, n, t);
|
|
697
714
|
}
|
|
698
715
|
if (BUILD.slotRelocation && !n && (BUILD.hydrateServerSide || (BUILD.slot || BUILD.shadowDom) && 12 & o.$flags$) && setContentReference(e),
|
|
@@ -703,12 +720,12 @@ const callRender = (e, t) => {
|
|
|
703
720
|
break;
|
|
704
721
|
}
|
|
705
722
|
}
|
|
706
|
-
BUILD.prop && BUILD.lazyLoad && !BUILD.hydrateServerSide && o.$members$ && Object.entries(o.$members$).map(([t, [o]]) => {
|
|
723
|
+
BUILD.prop && BUILD.lazyLoad && !BUILD.hydrateServerSide && o.$members$ && Object.entries(o.$members$).map((([t, [o]]) => {
|
|
707
724
|
if (31 & o && e.hasOwnProperty(t)) {
|
|
708
725
|
const o = e[t];
|
|
709
726
|
delete e[t], e[t] = o;
|
|
710
727
|
}
|
|
711
|
-
}), BUILD.initializeNextTick ? nextTick(() => initializeComponent(e, t, o)) : initializeComponent(e, t, o);
|
|
728
|
+
})), BUILD.initializeNextTick ? nextTick((() => initializeComponent(e, t, o))) : initializeComponent(e, t, o);
|
|
712
729
|
}
|
|
713
730
|
n();
|
|
714
731
|
}
|
|
@@ -718,7 +735,7 @@ const callRender = (e, t) => {
|
|
|
718
735
|
}, disconnectedCallback = e => {
|
|
719
736
|
if (0 == (1 & plt.$flags$)) {
|
|
720
737
|
const t = getHostRef(e), o = BUILD.lazyLoad ? t.$lazyInstance$ : e;
|
|
721
|
-
BUILD.hostListener && t.$rmListeners$ && (t.$rmListeners$.map(e => e()), t.$rmListeners$ = void 0),
|
|
738
|
+
BUILD.hostListener && t.$rmListeners$ && (t.$rmListeners$.map((e => e())), t.$rmListeners$ = void 0),
|
|
722
739
|
BUILD.cssVarShim && plt.$cssShim$ && plt.$cssShim$.removeHost(e), BUILD.lazyLoad && BUILD.disconnectedCallback && safeCall(o, "disconnectedCallback"),
|
|
723
740
|
BUILD.cmpDidUnload && safeCall(o, "componentDidUnload");
|
|
724
741
|
}
|
|
@@ -748,9 +765,9 @@ const callRender = (e, t) => {
|
|
|
748
765
|
if (BUILD.style && BUILD.mode && !BUILD.lazyLoad) {
|
|
749
766
|
const t = computeMode(e), o = getHostRef(e);
|
|
750
767
|
if (o.$modeName$ !== t) {
|
|
751
|
-
const n = o.$cmpMeta$, s = e["s-sc"],
|
|
752
|
-
n.$flags$,
|
|
753
|
-
attachStyles(o), forceUpdate(e));
|
|
768
|
+
const n = o.$cmpMeta$, s = e["s-sc"], a = getScopeId(n, t), l = e.constructor.style[t];
|
|
769
|
+
n.$flags$, l && (styles.has(a) || registerStyle(a, l), o.$modeName$ = t, e.classList.remove(s + "-h", s + "-s"),
|
|
770
|
+
attachStyles(o), forceUpdate$1(e));
|
|
754
771
|
}
|
|
755
772
|
}
|
|
756
773
|
}, attachShadow = e => {
|
|
@@ -760,8 +777,8 @@ const callRender = (e, t) => {
|
|
|
760
777
|
e.cloneNode = function(e) {
|
|
761
778
|
const o = this, n = !!BUILD.shadowDom && o.shadowRoot && supportsShadow, s = t.call(o, !!n && e);
|
|
762
779
|
if (BUILD.slot && !n && e) {
|
|
763
|
-
let e, t, n = 0,
|
|
764
|
-
for (;n < o.childNodes.length; n++) e = o.childNodes[n]["s-nr"], t =
|
|
780
|
+
let e, t, n = 0, a = [ "s-id", "s-cr", "s-lr", "s-rc", "s-sc", "s-p", "s-cn", "s-sr", "s-sn", "s-hn", "s-ol", "s-nr", "s-si" ];
|
|
781
|
+
for (;n < o.childNodes.length; n++) e = o.childNodes[n]["s-nr"], t = a.every((e => !o.childNodes[n][e])),
|
|
765
782
|
e && (BUILD.appendChildSlotFix && s.__appendChild ? s.__appendChild(e.cloneNode(!0)) : s.appendChild(e.cloneNode(!0))),
|
|
766
783
|
t && s.appendChild(o.childNodes[n].cloneNode(!0));
|
|
767
784
|
}
|
|
@@ -786,7 +803,7 @@ const callRender = (e, t) => {
|
|
|
786
803
|
const t = e.__lookupGetter__("childNodes");
|
|
787
804
|
Object.defineProperty(e, "children", {
|
|
788
805
|
get() {
|
|
789
|
-
return this.childNodes.map(e => 1 === e.nodeType);
|
|
806
|
+
return this.childNodes.map((e => 1 === e.nodeType));
|
|
790
807
|
}
|
|
791
808
|
}), Object.defineProperty(e, "childElementCount", {
|
|
792
809
|
get: () => e.children.length
|
|
@@ -864,34 +881,31 @@ const callRender = (e, t) => {
|
|
|
864
881
|
};
|
|
865
882
|
}
|
|
866
883
|
})();
|
|
867
|
-
const o = createTime("bootstrapLazy"), n = [], s = t.exclude || [],
|
|
884
|
+
const o = createTime("bootstrapLazy"), n = [], s = t.exclude || [], a = win.customElements, l = doc.head, r = l.querySelector("meta[charset]"), i = doc.createElement("style"), d = [], c = doc.querySelectorAll("[sty-id]");
|
|
868
885
|
let $, m = !0, p = 0;
|
|
869
886
|
if (Object.assign(plt, t), plt.$resourcesUrl$ = new URL(t.resourcesUrl || "./", doc.baseURI).href,
|
|
870
887
|
BUILD.asyncQueue && t.syncQueue && (plt.$flags$ |= 4), BUILD.hydrateClientSide && (plt.$flags$ |= 2),
|
|
871
888
|
BUILD.hydrateClientSide && BUILD.shadowDom) for (;p < c.length; p++) registerStyle(c[p].getAttribute("sty-id"), c[p].innerHTML.replace(/\/\*!@([^\/]+)\*\/[^\{]+\{/g, "$1{"));
|
|
872
|
-
e.map(e => e[1].map(o => {
|
|
873
|
-
const
|
|
889
|
+
e.map((e => e[1].map((o => {
|
|
890
|
+
const l = {
|
|
874
891
|
$flags$: o[0],
|
|
875
892
|
$tagName$: o[1],
|
|
876
893
|
$members$: o[2],
|
|
877
894
|
$listeners$: o[3]
|
|
878
895
|
};
|
|
879
|
-
BUILD.member && (
|
|
880
|
-
BUILD.reflect && (
|
|
881
|
-
BUILD.shadowDom && !supportsShadow && 1 &
|
|
882
|
-
const r = BUILD.transformTagName && t.transformTagName ? t.transformTagName(
|
|
896
|
+
BUILD.member && (l.$members$ = o[2]), BUILD.hostListener && (l.$listeners$ = o[3]),
|
|
897
|
+
BUILD.reflect && (l.$attrsToReflect$ = []), BUILD.watchCallback && (l.$watchers$ = {}),
|
|
898
|
+
BUILD.shadowDom && !supportsShadow && 1 & l.$flags$ && (l.$flags$ |= 8);
|
|
899
|
+
const r = BUILD.transformTagName && t.transformTagName ? t.transformTagName(l.$tagName$) : l.$tagName$, i = class extends HTMLElement {
|
|
883
900
|
constructor(e) {
|
|
884
|
-
super(e), registerHost(e = this,
|
|
885
|
-
BUILD.slotChildNodesFix && patchChildSlotNodes(e,
|
|
901
|
+
super(e), registerHost(e = this, l), BUILD.shadowDom && 1 & l.$flags$ && (BUILD.hydrateServerSide || "shadowRoot" in e || (e.shadowRoot = e)),
|
|
902
|
+
BUILD.slotChildNodesFix && patchChildSlotNodes(e, l);
|
|
886
903
|
}
|
|
887
904
|
connectedCallback() {
|
|
888
|
-
$ && (clearTimeout($), $ = null), m ? d.push(this) : plt.jmp(() => connectedCallback(this));
|
|
905
|
+
$ && (clearTimeout($), $ = null), m ? d.push(this) : plt.jmp((() => connectedCallback(this)));
|
|
889
906
|
}
|
|
890
907
|
disconnectedCallback() {
|
|
891
|
-
plt.jmp(() => disconnectedCallback(this));
|
|
892
|
-
}
|
|
893
|
-
forceUpdate() {
|
|
894
|
-
BUILD.isDev, forceUpdate(this);
|
|
908
|
+
plt.jmp((() => disconnectedCallback(this)));
|
|
895
909
|
}
|
|
896
910
|
componentOnReady() {
|
|
897
911
|
return getHostRef(this).$onReadyPromise$;
|
|
@@ -904,11 +918,11 @@ const callRender = (e, t) => {
|
|
|
904
918
|
n.$flags$ = 1, e["s-hmr-load"] = () => {
|
|
905
919
|
delete e["s-hmr-load"];
|
|
906
920
|
}, initializeComponent(e, n, t);
|
|
907
|
-
})(this,
|
|
908
|
-
}),
|
|
909
|
-
})), (BUILD.hydratedClass || BUILD.hydratedAttribute) && (i.innerHTML = n + "{visibility:hidden}.hydrated{visibility:inherit}",
|
|
910
|
-
i.setAttribute("data-styles", ""),
|
|
911
|
-
m = !1, d.length ? d.map(e => e.connectedCallback()) : BUILD.profile ? plt.jmp(() => $ = setTimeout(appDidLoad, 30, "timeout")) : plt.jmp(() => $ = setTimeout(appDidLoad, 30)),
|
|
921
|
+
})(this, l);
|
|
922
|
+
}), l.$lazyBundleId$ = e[0], s.includes(r) || a.get(r) || (n.push(r), a.define(r, proxyComponent(i, l, 1)));
|
|
923
|
+
})))), (BUILD.hydratedClass || BUILD.hydratedAttribute) && (i.innerHTML = n + "{visibility:hidden}.hydrated{visibility:inherit}",
|
|
924
|
+
i.setAttribute("data-styles", ""), l.insertBefore(i, r ? r.nextSibling : l.firstChild)),
|
|
925
|
+
m = !1, d.length ? d.map((e => e.connectedCallback())) : BUILD.profile ? plt.jmp((() => $ = setTimeout(appDidLoad, 30, "timeout"))) : plt.jmp((() => $ = setTimeout(appDidLoad, 30))),
|
|
912
926
|
o();
|
|
913
927
|
}, getAssetPath = e => {
|
|
914
928
|
const t = new URL(e, plt.$resourcesUrl$);
|
|
@@ -919,7 +933,7 @@ const callRender = (e, t) => {
|
|
|
919
933
|
return e || (e = doc.createElement(t), doc.body.appendChild(e)), "function" == typeof e.componentOnReady ? e.componentOnReady() : Promise.resolve(e);
|
|
920
934
|
};
|
|
921
935
|
return {
|
|
922
|
-
create: (...e) => o().then(t => t.create(...e)),
|
|
936
|
+
create: (...e) => o().then((t => t.create(...e))),
|
|
923
937
|
componentOnReady: o
|
|
924
938
|
};
|
|
925
939
|
}, getContext = (e, t) => t in Context ? Context[t] : "window" === t ? win : "document" === t ? doc : "isServer" === t || "isPrerender" === t ? !!BUILD.hydrateServerSide : "isClient" === t ? !BUILD.hydrateServerSide : "resourcesUrl" === t || "publicPath" === t ? getAssetPath(".") : "queue" === t ? {
|
|
@@ -935,24 +949,24 @@ const callRender = (e, t) => {
|
|
|
935
949
|
rootLevelIds: 0,
|
|
936
950
|
staticComponents: new Set(t)
|
|
937
951
|
}, n = [];
|
|
938
|
-
parseVNodeAnnotations(e, e.body, o, n), n.forEach(t => {
|
|
952
|
+
parseVNodeAnnotations(e, e.body, o, n), n.forEach((t => {
|
|
939
953
|
if (null != t) {
|
|
940
954
|
const n = t["s-nr"];
|
|
941
|
-
let s = n["s-host-id"],
|
|
942
|
-
if (null == s) if (s = 0, o.rootLevelIds++,
|
|
943
|
-
1 === n.nodeType) n.setAttribute("c-id",
|
|
955
|
+
let s = n["s-host-id"], a = n["s-node-id"], l = `${s}.${a}`;
|
|
956
|
+
if (null == s) if (s = 0, o.rootLevelIds++, a = o.rootLevelIds, l = `${s}.${a}`,
|
|
957
|
+
1 === n.nodeType) n.setAttribute("c-id", l); else if (3 === n.nodeType) {
|
|
944
958
|
if (0 === s && "" === n.nodeValue.trim()) return void t.remove();
|
|
945
|
-
const o = e.createComment(
|
|
946
|
-
o.nodeValue =
|
|
959
|
+
const o = e.createComment(l);
|
|
960
|
+
o.nodeValue = `t.${l}`, n.parentNode.insertBefore(o, n);
|
|
947
961
|
}
|
|
948
|
-
let r =
|
|
962
|
+
let r = `o.${l}`;
|
|
949
963
|
const i = t.parentElement;
|
|
950
964
|
i && ("" === i["s-en"] ? r += "." : "c" === i["s-en"] && (r += ".c")), t.nodeValue = r;
|
|
951
965
|
}
|
|
952
|
-
});
|
|
966
|
+
}));
|
|
953
967
|
}
|
|
954
968
|
}, parseVNodeAnnotations = (e, t, o, n) => {
|
|
955
|
-
null != t && (null != t["s-nr"] && n.push(t), 1 === t.nodeType && t.childNodes.forEach(t => {
|
|
969
|
+
null != t && (null != t["s-nr"] && n.push(t), 1 === t.nodeType && t.childNodes.forEach((t => {
|
|
956
970
|
const s = getHostRef(t);
|
|
957
971
|
if (null != s && !o.staticComponents.has(t.nodeName.toLowerCase())) {
|
|
958
972
|
const n = {
|
|
@@ -961,21 +975,21 @@ const callRender = (e, t) => {
|
|
|
961
975
|
insertVNodeAnnotations(e, t, s.$vnode$, o, n);
|
|
962
976
|
}
|
|
963
977
|
parseVNodeAnnotations(e, t, o, n);
|
|
964
|
-
}));
|
|
978
|
+
})));
|
|
965
979
|
}, insertVNodeAnnotations = (e, t, o, n, s) => {
|
|
966
980
|
if (null != o) {
|
|
967
|
-
const
|
|
968
|
-
if (t.setAttribute("s-id",
|
|
981
|
+
const a = ++n.hostIds;
|
|
982
|
+
if (t.setAttribute("s-id", a), null != t["s-cr"] && (t["s-cr"].nodeValue = `r.${a}`),
|
|
969
983
|
null != o.$children$) {
|
|
970
984
|
const t = 0;
|
|
971
|
-
o.$children$.forEach((o, n) => {
|
|
972
|
-
insertChildVNodeAnnotations(e, o, s,
|
|
973
|
-
});
|
|
985
|
+
o.$children$.forEach(((o, n) => {
|
|
986
|
+
insertChildVNodeAnnotations(e, o, s, a, t, n);
|
|
987
|
+
}));
|
|
974
988
|
}
|
|
975
989
|
if (t && o && o.$elm$ && !t.hasAttribute("c-id")) {
|
|
976
990
|
const e = t.parentElement;
|
|
977
991
|
if (e && e.childNodes) {
|
|
978
|
-
const n = Array.from(e.childNodes), s = n.find(e => 8 === e.nodeType && e["s-sr"]);
|
|
992
|
+
const n = Array.from(e.childNodes), s = n.find((e => 8 === e.nodeType && e["s-sr"]));
|
|
979
993
|
if (s) {
|
|
980
994
|
const e = n.indexOf(t) - 1;
|
|
981
995
|
o.$elm$.setAttribute("c-id", `${s["s-host-id"]}.${s["s-node-id"]}.0.${e}`);
|
|
@@ -983,27 +997,37 @@ const callRender = (e, t) => {
|
|
|
983
997
|
}
|
|
984
998
|
}
|
|
985
999
|
}
|
|
986
|
-
}, insertChildVNodeAnnotations = (e, t, o, n, s,
|
|
987
|
-
const
|
|
988
|
-
if (null ==
|
|
989
|
-
const r = o.nodeIds++, i = `${n}.${r}.${s}.${
|
|
990
|
-
if (
|
|
991
|
-
const t =
|
|
992
|
-
if ("STYLE" !==
|
|
993
|
-
const o =
|
|
994
|
-
t.insertBefore(n,
|
|
1000
|
+
}, insertChildVNodeAnnotations = (e, t, o, n, s, a) => {
|
|
1001
|
+
const l = t.$elm$;
|
|
1002
|
+
if (null == l) return;
|
|
1003
|
+
const r = o.nodeIds++, i = `${n}.${r}.${s}.${a}`;
|
|
1004
|
+
if (l["s-host-id"] = n, l["s-node-id"] = r, 1 === l.nodeType) l.setAttribute("c-id", i); else if (3 === l.nodeType) {
|
|
1005
|
+
const t = l.parentNode, o = t.nodeName;
|
|
1006
|
+
if ("STYLE" !== o && "SCRIPT" !== o) {
|
|
1007
|
+
const o = `t.${i}`, n = e.createComment(o);
|
|
1008
|
+
t.insertBefore(n, l);
|
|
995
1009
|
}
|
|
996
|
-
} else if (8 ===
|
|
997
|
-
const e = `s.${i}.${
|
|
998
|
-
|
|
1010
|
+
} else if (8 === l.nodeType && l["s-sr"]) {
|
|
1011
|
+
const e = `s.${i}.${l["s-sn"] || ""}`;
|
|
1012
|
+
l.nodeValue = e;
|
|
999
1013
|
}
|
|
1000
1014
|
if (null != t.$children$) {
|
|
1001
|
-
const
|
|
1002
|
-
t.$children$.forEach((t, s) => {
|
|
1003
|
-
insertChildVNodeAnnotations(e, t, o, n,
|
|
1004
|
-
});
|
|
1015
|
+
const a = s + 1;
|
|
1016
|
+
t.$children$.forEach(((t, s) => {
|
|
1017
|
+
insertChildVNodeAnnotations(e, t, o, n, a, s);
|
|
1018
|
+
}));
|
|
1019
|
+
}
|
|
1020
|
+
}, Fragment = (e, t) => t, NO_HYDRATE_TAGS = new Set([ "CODE", "HEAD", "IFRAME", "INPUT", "OBJECT", "OUTPUT", "NOSCRIPT", "PRE", "SCRIPT", "SELECT", "STYLE", "TEMPLATE", "TEXTAREA" ]), hAsync = (e, t, ...o) => {
|
|
1021
|
+
if (Array.isArray(o) && o.length > 0) {
|
|
1022
|
+
const n = o.flat(1 / 0);
|
|
1023
|
+
return n.some(isPromise) ? Promise.all(n).then((o => h(e, t, ...o))).catch((o => h(e, t))) : h(e, t, ...o);
|
|
1005
1024
|
}
|
|
1006
|
-
|
|
1025
|
+
return h(e, t);
|
|
1026
|
+
};
|
|
1027
|
+
|
|
1028
|
+
let customError;
|
|
1029
|
+
|
|
1030
|
+
const cmpModules = new Map, getModule = e => {
|
|
1007
1031
|
if ("string" == typeof e) {
|
|
1008
1032
|
e = e.toLowerCase();
|
|
1009
1033
|
const t = cmpModules.get(e);
|
|
@@ -1028,24 +1052,24 @@ const callRender = (e, t) => {
|
|
|
1028
1052
|
});
|
|
1029
1053
|
}
|
|
1030
1054
|
}, win = window, doc = win.document, readTask = e => {
|
|
1031
|
-
process.nextTick(() => {
|
|
1055
|
+
process.nextTick((() => {
|
|
1032
1056
|
try {
|
|
1033
1057
|
e();
|
|
1034
1058
|
} catch (e) {
|
|
1035
1059
|
consoleError(e);
|
|
1036
1060
|
}
|
|
1037
|
-
});
|
|
1061
|
+
}));
|
|
1038
1062
|
}, writeTask = e => {
|
|
1039
|
-
process.nextTick(() => {
|
|
1063
|
+
process.nextTick((() => {
|
|
1040
1064
|
try {
|
|
1041
1065
|
e();
|
|
1042
1066
|
} catch (e) {
|
|
1043
1067
|
consoleError(e);
|
|
1044
1068
|
}
|
|
1045
|
-
});
|
|
1046
|
-
}, resolved = Promise.resolve(), nextTick = e => resolved.then(e),
|
|
1069
|
+
}));
|
|
1070
|
+
}, resolved = Promise.resolve(), nextTick = e => resolved.then(e), defaultConsoleError = e => {
|
|
1047
1071
|
null != e && console.error(e.stack || e.message || e);
|
|
1048
|
-
}, consoleDevError = (...e) => {}, consoleDevWarn = (...e) => {}, consoleDevInfo = (...e) => {}, Context = {}, plt = {
|
|
1072
|
+
}, consoleError = (e, t) => (customError || defaultConsoleError)(e, t), consoleDevError = (...e) => {}, consoleDevWarn = (...e) => {}, consoleDevInfo = (...e) => {}, setErrorHandler = e => customError = e, Context = {}, plt = {
|
|
1049
1073
|
$flags$: 0,
|
|
1050
1074
|
$resourcesUrl$: "",
|
|
1051
1075
|
jmp: e => e(),
|
|
@@ -1061,7 +1085,7 @@ const callRender = (e, t) => {
|
|
|
1061
1085
|
$instanceValues$: new Map,
|
|
1062
1086
|
$renderCount$: 0
|
|
1063
1087
|
};
|
|
1064
|
-
return o.$onInstancePromise$ = new Promise(e => o.$onInstanceResolve$ = e), o.$onReadyPromise$ = new Promise(e => o.$onReadyResolve$ = e),
|
|
1088
|
+
return o.$onInstancePromise$ = new Promise((e => o.$onInstanceResolve$ = e)), o.$onReadyPromise$ = new Promise((e => o.$onReadyResolve$ = e)),
|
|
1065
1089
|
e["s-p"] = [], e["s-rc"] = [], addHostEventListeners(e, o, t.$listeners$, !1), hostRefs.set(e, o);
|
|
1066
1090
|
}, Build = {
|
|
1067
1091
|
isDev: !1,
|
|
@@ -1070,4 +1094,4 @@ const callRender = (e, t) => {
|
|
|
1070
1094
|
isTesting: !1
|
|
1071
1095
|
}, styles = new Map, modeResolutionChain = [];
|
|
1072
1096
|
|
|
1073
|
-
export { Build, Context, Host, addHostEventListeners, attachShadow, bootstrapLazy, cmpModules, connectedCallback, consoleDevError, consoleDevInfo, consoleDevWarn, consoleError, createEvent, defineCustomElement, disconnectedCallback, doc, forceModeUpdate, forceUpdate, getAssetPath, getConnect, getContext, getElement, getHostRef, getMode, getRenderingRef, getValue, h, hydrateApp, insertVdomAnnotations, isMemberInElement, loadModule, modeResolutionChain, nextTick, parsePropertyValue, plt, postUpdateComponent, proxyComponent, proxyCustomElement, readTask, registerComponents, registerHost, registerInstance, renderVdom, setAssetPath, setMode, setValue, styles, supportsConstructibleStylesheets, supportsListenerOptions, supportsShadow, win, writeTask };
|
|
1097
|
+
export { Build, Context, Fragment, Host, addHostEventListeners, attachShadow, bootstrapLazy, cmpModules, connectedCallback, consoleDevError, consoleDevInfo, consoleDevWarn, consoleError, createEvent, defineCustomElement, disconnectedCallback, doc, forceModeUpdate, forceUpdate$1 as forceUpdate, getAssetPath, getConnect, getContext, getElement, getHostRef, getMode, getRenderingRef, getValue, hAsync as h, hydrateApp, insertVdomAnnotations, isMemberInElement, loadModule, modeResolutionChain, nextTick, parsePropertyValue, plt, postUpdateComponent, proxyComponent, proxyCustomElement, readTask, registerComponents, registerHost, registerInstance, renderVdom, setAssetPath, setErrorHandler, setMode, setValue, styles, supportsConstructibleStylesheets, supportsListenerOptions, supportsShadow, win, writeTask };
|