From eec12354a8b9bdc94729a6f7ec3d30c3cca94c49 Mon Sep 17 00:00:00 2001 From: Victor Giers Date: Tue, 31 Mar 2026 17:41:24 +0200 Subject: [PATCH] Update describeSelection function to include model instance and asset details --- src/app/App.tsx | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/src/app/App.tsx b/src/app/App.tsx index b8b5fe82..c33224f9 100644 --- a/src/app/App.tsx +++ b/src/app/App.tsx @@ -373,7 +373,13 @@ function getSelectedBrushLabel(selection: EditorSelection, brushes: BoxBrush[]): return getBrushLabelById(selectedBrushId, brushes); } -function describeSelection(selection: EditorSelection, brushes: BoxBrush[], entities: Record): string { +function describeSelection( + selection: EditorSelection, + brushes: BoxBrush[], + modelInstances: Record, + assets: Record, + entities: Record +): string { switch (selection.kind) { case "none": return "No authored selection"; @@ -384,9 +390,9 @@ function describeSelection(selection: EditorSelection, brushes: BoxBrush[], enti case "entities": return `${selection.ids.length} entity selected (${getEntityDisplayLabelById(selection.ids[0], entities)})`; case "modelInstances": - return `${selection.ids.length} model instances selected`; - default: - return "Unknown selection"; + return `${selection.ids.length} model instance selected (${getModelInstanceDisplayLabelById(selection.ids[0], modelInstances, assets)})`; + case "modelInstances": + return `${selection.ids.length} model instance selected (${getModelInstanceDisplayLabelById(selection.ids[0], modelInstances, assets)})`; } }