From 516d722ed30a2ceeebd2466fca155c3ca262ac8c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Timoth=C3=A9e?= <tpoussard@neogeo.fr>
Date: Mon, 22 Aug 2022 11:25:21 +0200
Subject: [PATCH] keep field labels placement on mobile when offline

---
 .../FeaturesListAndMap/FeatureListTable.vue   | 37 +++++++++++++------
 1 file changed, 26 insertions(+), 11 deletions(-)

diff --git a/src/components/Project/FeaturesListAndMap/FeatureListTable.vue b/src/components/Project/FeaturesListAndMap/FeatureListTable.vue
index 6baa8528..cc4b12e1 100644
--- a/src/components/Project/FeaturesListAndMap/FeatureListTable.vue
+++ b/src/components/Project/FeaturesListAndMap/FeatureListTable.vue
@@ -147,6 +147,7 @@
           >
             <td
               v-if="isOnline"
+              id="select"
               class="dt-center"
             >
               <div
@@ -165,7 +166,10 @@
               </div>
             </td>
 
-            <td class="dt-center">
+            <td
+              id="status"
+              class="dt-center"
+            >
               <div
                 v-if="feature.status === 'archived'"
                 data-tooltip="Archivé"
@@ -203,7 +207,10 @@
                 />
               </div>
             </td>
-            <td class="dt-center">
+            <td
+              id="type"
+              class="dt-center"
+            >
               <router-link
                 :to="{
                   name: 'details-type-signalement',
@@ -216,7 +223,10 @@
                 {{ feature.feature_type.title }}
               </router-link>
             </td>
-            <td class="dt-center">
+            <td
+              id="name"
+              class="dt-center"
+            >
               <router-link
                 :to="{
                   name: 'details-signalement-filtre',
@@ -230,17 +240,22 @@
                 {{ feature.title || feature.feature_id }}
               </router-link>
             </td>
-            <td class="dt-center">
+            <td
+              id="update"
+              class="dt-center"
+            >
               {{ feature.updated_on | formatDate }}
             </td>
             <td
               v-if="user"
+              id="author"
               class="dt-center"
             >
               {{ feature.display_creator || ' ---- ' }}
             </td>
             <td
               v-if="user"
+              id="last_editor"
               class="dt-center"
             >
               {{ feature.display_last_editor || ' ---- ' }}
@@ -706,25 +721,25 @@ and also iPads specifically.
   /*
 	Label the data
 	*/
-  td:nth-of-type(1):before {
+  td#select:before {
     content: "";
   }
-  td:nth-of-type(2):before {
+  td#status:before {
     content: "Statut";
   }
-  td:nth-of-type(3):before {
+  td#type:before {
     content: "Type";
   }
-  td:nth-of-type(4):before {
+  td#name:before {
     content: "Nom";
   }
-  td:nth-of-type(5):before {
+  td#update:before {
     content: "Dernière modification";
   }
-  td:nth-of-type(6):before {
+  td#author:before {
     content: "Auteur";
   }
-  td:nth-of-type(7):before {
+  td#last_editor:before {
     content: "Dernier éditeur";
   }
 
-- 
GitLab