From 89fdbf6617d1f5e9f7d9a4f25a56e84fe3723f23 Mon Sep 17 00:00:00 2001 From: Pau Costa Date: Sat, 28 Mar 2026 15:53:33 +0100 Subject: [PATCH] Add support for space resizing and enhanced layout management - Update `SpacesService` to handle width and height properties for spaces. - Introduce `UpdateSpaceDto` for improved validation in batch update operations. - Extend `FloorplanEditor.svelte` and `FloorplanViewer.svelte` to support dynamic container scaling and space resizing. - Modify Prisma schema to include `width` and `height` fields for spaces. - Enhance floorplan rendering to maintain proportional layout during editing and viewing. --- .idea/workspace.xml | 27 +- apps/api/prisma/schema.prisma | 2 + apps/api/src/spaces/dto/update-space.dto.ts | 35 +++ apps/api/src/spaces/spaces.controller.ts | 5 +- apps/api/src/spaces/spaces.service.ts | 16 +- .../src/lib/components/FloorplanViewer.svelte | 52 +++- .../components/admin/FloorplanEditor.svelte | 284 ++++++++++++++---- 7 files changed, 344 insertions(+), 77 deletions(-) create mode 100644 apps/api/src/spaces/dto/update-space.dto.ts diff --git a/.idea/workspace.xml b/.idea/workspace.xml index 847b8ff..017aa2c 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -4,17 +4,13 @@