@chamn/render 0.0.40 → 0.0.41
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/commonComponent/index.d.ts +1 -12
- package/dist/core/adapterReact.d.ts +2 -2
- package/dist/core/designReactRender.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +16 -16
- package/dist/index.mjs.map +1 -1
- package/dist/index.umd.js +1 -1
- package/dist/index.umd.js.map +1 -1
- package/dist/util/assetsLoader.d.ts +4 -1
- package/dist/util/index.d.ts +3 -3
- package/package.json +6 -6
package/dist/index.mjs
CHANGED
|
@@ -4703,28 +4703,28 @@ class lv {
|
|
|
4703
4703
|
y(this, "_onErrorList", []);
|
|
4704
4704
|
this.assets = JSON.parse(JSON.stringify(e || [])), this.loadStatus = "INIT", r != null && r.window && (this.win = r.window);
|
|
4705
4705
|
}
|
|
4706
|
-
load() {
|
|
4707
|
-
const
|
|
4708
|
-
for (let
|
|
4709
|
-
const
|
|
4710
|
-
|
|
4711
|
-
const
|
|
4712
|
-
|
|
4713
|
-
async: !1,
|
|
4714
|
-
before: (
|
|
4706
|
+
load(e) {
|
|
4707
|
+
const r = this.assets || [], n = [];
|
|
4708
|
+
for (let o = 0; o < r.length; o++) {
|
|
4709
|
+
const a = r[o];
|
|
4710
|
+
a.id || (a.id = Z()), n.push(a.id);
|
|
4711
|
+
const i = a.resources.map((s) => s.src);
|
|
4712
|
+
i.length && Dn(i, a.id, {
|
|
4713
|
+
async: (e == null ? void 0 : e.async) ?? !1,
|
|
4714
|
+
before: (s, c) => (this.win.document.body.appendChild(c), !1)
|
|
4715
4715
|
});
|
|
4716
4716
|
}
|
|
4717
|
-
return new Promise((
|
|
4718
|
-
if (
|
|
4719
|
-
this._onSuccessList.forEach((
|
|
4717
|
+
return new Promise((o, a) => {
|
|
4718
|
+
if (r.length === 0) {
|
|
4719
|
+
this._onSuccessList.forEach((i) => i()), o("");
|
|
4720
4720
|
return;
|
|
4721
4721
|
}
|
|
4722
|
-
Dn.ready(
|
|
4722
|
+
Dn.ready(n, {
|
|
4723
4723
|
success: () => {
|
|
4724
|
-
this._onSuccessList.forEach((
|
|
4724
|
+
this._onSuccessList.forEach((i) => i()), o("");
|
|
4725
4725
|
},
|
|
4726
|
-
error: (
|
|
4727
|
-
this._onErrorList.forEach((
|
|
4726
|
+
error: (i) => {
|
|
4727
|
+
this._onErrorList.forEach((s) => s(i)), a(i);
|
|
4728
4728
|
}
|
|
4729
4729
|
});
|
|
4730
4730
|
});
|