Refactor interaction link handling in App.tsx and update tests

This commit is contained in:
2026-04-02 19:19:54 +02:00
parent 7bc4ca3293
commit 74e7be5073
4 changed files with 62 additions and 29 deletions

View File

@@ -226,7 +226,8 @@ describe("buildRuntimeSceneFromDocument", () => {
};
document.world.background = {
mode: "image",
assetId: imageAsset.id
assetId: imageAsset.id,
environmentIntensity: 0.75
};
document.world.ambientLight.intensity = 0.55;
document.world.sunLight.direction = {

View File

@@ -237,7 +237,8 @@ describe("validateSceneDocument", () => {
};
document.world.background = {
mode: "image",
assetId: imageAsset.id
assetId: imageAsset.id,
environmentIntensity: 0.5
};
const validation = validateSceneDocument(document);
@@ -273,7 +274,8 @@ describe("validateSceneDocument", () => {
};
document.world.background = {
mode: "image",
assetId: "asset-missing-background"
assetId: "asset-missing-background",
environmentIntensity: 0.5
};
const validation = validateSceneDocument(document);

View File

@@ -42,14 +42,16 @@ describe("world settings helpers", () => {
expect(imageBackground).toEqual({
mode: "image",
assetId: "asset-background-panorama"
assetId: "asset-background-panorama",
environmentIntensity: 0.5
});
const nextImageBackground = changeWorldBackgroundMode(imageBackground, "image", "asset-background-panorama-2");
expect(nextImageBackground).toEqual({
mode: "image",
assetId: "asset-background-panorama-2"
assetId: "asset-background-panorama-2",
environmentIntensity: 0.5
});
const world = createDefaultWorldSettings();