From b97f41eae81590208b768f576f784c0553c795ec Mon Sep 17 00:00:00 2001
From: Bastien DUMONT <bdumont@grandlyon.com>
Date: Thu, 22 Dec 2022 09:22:33 +0000
Subject: [PATCH] Resolve "[Annuaire] Masquer les structures en attente"

---
 src/app/profile/profile.component.html | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/src/app/profile/profile.component.html b/src/app/profile/profile.component.html
index 983c85ebf..0977efafd 100644
--- a/src/app/profile/profile.component.html
+++ b/src/app/profile/profile.component.html
@@ -90,8 +90,9 @@
       class="structuresContainer"
       *ngIf="userProfile.structuresLink.length > 0 || userProfile.pendingStructuresLink.length > 0"
     >
-      <div *ngFor="let structure of pendingStructures; let i = index">
+      <ng-container *ngIf="!this.isPublic">
         <app-profile-structure
+          *ngFor="let structure of pendingStructures; let i = index"
           [structureWithOwners]="structure"
           [userProfile]="this.userProfile"
           [isPublic]="this.isPublic"
@@ -99,18 +100,17 @@
           [joinRequestDate]="userProfile.pendingStructuresLink[i].createdAt"
           (cancelJoin)="cancelJoin($event)"
         ></app-profile-structure>
-      </div>
-      <div *ngFor="let structure of structures; let i = index">
-        <app-profile-structure
-          [structureWithOwners]="structure"
-          [userProfile]="this.userProfile"
-          [isPublic]="this.isPublic"
-        ></app-profile-structure>
-      </div>
+      </ng-container>
+      <app-profile-structure
+        *ngFor="let structure of structures; let i = index"
+        [structureWithOwners]="structure"
+        [userProfile]="this.userProfile"
+        [isPublic]="this.isPublic"
+      ></app-profile-structure>
     </div>
     <app-button
-      class="addStructure"
       *ngIf="!isPublic"
+      class="addStructure"
       [style]="buttonTypeEnum.SecondaryUltraWide"
       [iconBtn]="'add'"
       [text]="'Ajouter une structure'"
-- 
GitLab