@seatlayer/core 0.47.2 → 0.48.0
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/{chunk-FVCOOLJO.js → chunk-I6DPX3EM.js} +9 -4
- package/dist/chunk-I6DPX3EM.js.map +1 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +10 -2
- package/dist/index.d.ts +10 -2
- package/dist/index.js.map +1 -1
- package/dist/view3d/crossfade/panorama.cjs +8 -3
- package/dist/view3d/crossfade/panorama.cjs.map +1 -1
- package/dist/view3d/crossfade/panorama.d.cts +6 -0
- package/dist/view3d/crossfade/panorama.d.ts +6 -0
- package/dist/view3d/crossfade/panorama.js +1 -1
- package/dist/view3d/index.cjs +17 -5
- package/dist/view3d/index.cjs.map +1 -1
- package/dist/view3d/index.js +10 -3
- package/dist/view3d/index.js.map +1 -1
- package/package.json +1 -1
- package/dist/chunk-FVCOOLJO.js.map +0 -1
package/dist/view3d/index.js
CHANGED
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
clampPanoramaFov,
|
|
15
15
|
mountPanorama,
|
|
16
16
|
seatViewDisclosure
|
|
17
|
-
} from "../chunk-
|
|
17
|
+
} from "../chunk-I6DPX3EM.js";
|
|
18
18
|
import {
|
|
19
19
|
browserPanoramaConstraints,
|
|
20
20
|
loadPanoramaImage,
|
|
@@ -4713,7 +4713,9 @@ async function mountPanoramaSphere(container, view, deps, opts = {}) {
|
|
|
4713
4713
|
const delivery = planPanoramaDelivery(view, browserPanoramaConstraints(maxTextureSize));
|
|
4714
4714
|
let image;
|
|
4715
4715
|
try {
|
|
4716
|
-
|
|
4716
|
+
const initialUrl = view.resolveUrl ? await view.resolveUrl(delivery.initialUrl) : delivery.initialUrl;
|
|
4717
|
+
if (!initialUrl) throw new Error("panorama_asset_unavailable");
|
|
4718
|
+
image = await loadPanoramaImage(initialUrl, loadAbort.signal);
|
|
4717
4719
|
} catch {
|
|
4718
4720
|
opts.signal?.removeEventListener("abort", abortFromCaller);
|
|
4719
4721
|
return null;
|
|
@@ -4729,7 +4731,12 @@ async function mountPanoramaSphere(container, view, deps, opts = {}) {
|
|
|
4729
4731
|
sphere.mesh.setParent(deps.scene);
|
|
4730
4732
|
if (delivery.upgradeUrl) {
|
|
4731
4733
|
cancelUpgrade = schedulePanoramaUpgrade(() => {
|
|
4732
|
-
|
|
4734
|
+
const resolved = view.resolveUrl ? view.resolveUrl(delivery.upgradeUrl) : Promise.resolve(delivery.upgradeUrl);
|
|
4735
|
+
void resolved.then((url) => {
|
|
4736
|
+
if (!url || loadAbort.signal.aborted) return null;
|
|
4737
|
+
return loadPanoramaImage(url, loadAbort.signal);
|
|
4738
|
+
}).then((full) => {
|
|
4739
|
+
if (!full) return;
|
|
4733
4740
|
if (disposed || loadAbort.signal.aborted) return;
|
|
4734
4741
|
sphere?.setImage(full);
|
|
4735
4742
|
deps.requestRender();
|