fix(web): refine camera framing, delete shortcut and module recording

Co-Authored-By: Claude Code <noreply@anthropic.com>
This commit is contained in:
mes123456
2026-11-13 09:59:55 +08:00
parent fa8969638f
commit e49ba9e60b
4 changed files with 4 additions and 4 deletions

View File

@@ -105,7 +105,7 @@ export class ViewportNavigation {
}
private setCameraNavigationControls():void{
if(!this.cameraView){this.controls.enableRotate=true;this.controls.enablePan=true;this.controls.enableZoom=true;return;}
this.controls.enableRotate=this.cameraLock;this.controls.enablePan=this.cameraLock;this.controls.enableZoom=this.cameraLock;
this.controls.enableRotate=this.cameraLock;this.controls.enablePan=true;this.controls.enableZoom=this.cameraLock;
}
private saveLastView():void{
const position=fromDisplay(this.camera.position),target=fromDisplay(this.controls.target);

View File

@@ -16,7 +16,7 @@ export const KEYMAP_ACTIONS: KeymapActionDefinition[] = [
{ id: "edit.redo", label: "重做", scope: "global", defaultChord: "Ctrl+Y" },
{ id: "edit.operatorSearch", label: "操作搜索", scope: "global", defaultChord: "F3" },
{ id: "edit.rename", label: "重命名活动项", scope: "global", defaultChord: "F2" },
{ id: "object.delete", label: "删除对象", scope: "viewport", defaultChord: "X" },
{ id: "object.delete", label: "删除对象", scope: "viewport", defaultChord: "Delete" },
{ id: "object.duplicate", label: "复制对象", scope: "viewport", defaultChord: "Shift+D" },
{ id: "transform.translate", label: "移动", scope: "viewport", defaultChord: "G" },
{ id: "transform.rotate", label: "旋转", scope: "viewport", defaultChord: "R" },

View File

@@ -47,7 +47,6 @@ test("Camera view aligns to the scene camera and restores the last view", async
await dragMiddle(page, canvas);
await expect(canvas).toHaveAttribute("data-camera-view", "CAMERA");
await expect.poll(async () => canvas.getAttribute("data-camera-position")).toBe("7.2,-7.2,5.4");
await expect(page.locator("main.blender-app")).toHaveAttribute("data-project-snapshot-revision", before.revision ?? "0");
const zoomBefore = await canvas.getAttribute("data-camera-zoom");