diff --git a/frontend/pages/infrastructure/building.vue b/frontend/pages/infrastructure/building.vue
index 4ee1aa1..77e73c4 100644
--- a/frontend/pages/infrastructure/building.vue
+++ b/frontend/pages/infrastructure/building.vue
@@ -19,7 +19,7 @@
v-for="entry in buildingLayouts"
:key="entry.building.id"
>
-
+
{{ entry.building.label || `Bâtiment ${entry.building.id}` }}
@@ -158,7 +158,10 @@ const buildLayoutView = (layout: BuildingLayoutData): {
const cellDrafts: GridCellDraft[] = []
// Tri visuel : de haut en bas, puis de gauche à droite
- const positionsSorted = [...positions].sort((a, b) => (a.y ?? 1) - (b.y ?? 1) || (a.x ?? 1) - (b.x ?? 1))
+ const positionsSorted = [...positions].sort(
+ (leftPosition, rightPosition) =>
+ (leftPosition.y ?? 1) - (rightPosition.y ?? 1) || (leftPosition.x ?? 1) - (rightPosition.x ?? 1)
+ )
for (const position of positionsSorted) {
const x = position.x ?? 1
const y = position.y ?? 1