From cabd8d716a1c4a63b4ad1682c14210b8acce8cdd Mon Sep 17 00:00:00 2001 From: Hugo SUBTIL <ext.sopra.husubtil@grandlyon.com> Date: Wed, 30 Mar 2022 17:09:14 +0200 Subject: [PATCH 01/10] fix(carto): search design on pop-up --- .../post-header/post-header.component.scss | 2 +- .../modal-filter/modal-filter.component.html | 13 ++++++++----- .../modal-filter/modal-filter.component.scss | 2 ++ .../structure-list-search.component.scss | 6 +++--- src/assets/scss/_color.scss | 1 - src/styles.scss | 2 +- 6 files changed, 15 insertions(+), 11 deletions(-) diff --git a/src/app/post/components/post-header/post-header.component.scss b/src/app/post/components/post-header/post-header.component.scss index 92438dade..bb286f973 100644 --- a/src/app/post/components/post-header/post-header.component.scss +++ b/src/app/post/components/post-header/post-header.component.scss @@ -59,7 +59,7 @@ h1 { width: 7px; } &:focus { - border-color: $blue-middle; + border-color: $primary-color; } } .selected { diff --git a/src/app/structure-list/components/modal-filter/modal-filter.component.html b/src/app/structure-list/components/modal-filter/modal-filter.component.html index ad48225b7..9347b785b 100644 --- a/src/app/structure-list/components/modal-filter/modal-filter.component.html +++ b/src/app/structure-list/components/modal-filter/modal-filter.component.html @@ -120,13 +120,16 @@ class="customCheck customCheckPrimary" [ngClass]="{ halfCheck: getCategoryCheckboxStatus(c) === 'halfChecked' }" ></span> - <div class="label">{{ c.name }}</div> </label> <div - class="arrow" + fxLayout="row" + fxLayoutAlign="space-between center" + class="w-100 clickable" (click)="toggleShowCategory(c.id)" - [ngClass]="{ toggled: this.toggledCategories.includes(c.id) }" - ></div> + > + <div class="label">{{ c.name }}</div> + <div class="arrow" [ngClass]="{ toggled: this.toggledCategories.includes(c.id) }"></div> + </div> </div> <ul class="blockLigne smallList" [ngClass]="{ show: this.toggledCategories.includes(c.id) }"> <div fxLayout="row" fxLayoutAlign="start center" class="ligneFiltre" *ngFor="let module of c.modules"> @@ -137,7 +140,7 @@ type="checkbox" [checked]="searchService.getIndex(checkedModules, module.id, c.id) > -1" [value]="module.id" - (change)="onCheckboxChange($event, c.id)" + (change)="onCheckboxChange($event, c.id, module.text)" /> <span class="customCheck customCheckPrimary"></span> <div class="label">{{ module.text }}</div> diff --git a/src/app/structure-list/components/modal-filter/modal-filter.component.scss b/src/app/structure-list/components/modal-filter/modal-filter.component.scss index be2d034ef..41e24d147 100644 --- a/src/app/structure-list/components/modal-filter/modal-filter.component.scss +++ b/src/app/structure-list/components/modal-filter/modal-filter.component.scss @@ -79,6 +79,8 @@ .contentModal { overflow-y: auto; max-width: 1100px; + max-height: 50vh; + overflow-y: overlay; border-bottom: 1px solid $grey; @media #{$large-phone} { max-height: none; diff --git a/src/app/structure-list/components/structure-list-search/structure-list-search.component.scss b/src/app/structure-list/components/structure-list-search/structure-list-search.component.scss index 989a130a3..4c3a9bd3e 100644 --- a/src/app/structure-list/components/structure-list-search/structure-list-search.component.scss +++ b/src/app/structure-list/components/structure-list-search/structure-list-search.component.scss @@ -92,7 +92,7 @@ transition: all 300ms ease; } &:focus { - border-color: $blue-middle; + border-color: $primary-color; } } .selected { @@ -154,7 +154,7 @@ height: 20px; border: solid 1px $grey-4; background: white; - margin-left: 0; + margin: 0; margin-right: 5px; transition: all 300ms ease; position: relative; @@ -201,7 +201,7 @@ padding: 4px 6px 8px 6px; &:hover { .ico-pin-search { - background-color: $blue-middle; + background-color: $primary-color; } } &:focus { diff --git a/src/assets/scss/_color.scss b/src/assets/scss/_color.scss index c613467c3..f0a2a0fae 100644 --- a/src/assets/scss/_color.scss +++ b/src/assets/scss/_color.scss @@ -25,7 +25,6 @@ $orange-warning: #da6c2e; /* OTHERS */ $blue: #348899; $blue-ultra-light: #eaf8fb; -$blue-middle: #83b6c1; $blue-light: #c9ecf3; /* APP COLORS */ $primary-color: $red; diff --git a/src/styles.scss b/src/styles.scss index cd347352a..fc6508419 100644 --- a/src/styles.scss +++ b/src/styles.scss @@ -56,7 +56,7 @@ a { } &:hover { text-decoration: underline; - outline-color: $blue-middle; + outline-color: $primary-color; } &.primary { @include hyperlink; -- GitLab From 47e612a5e130ec00c026000c7642881116b822ac Mon Sep 17 00:00:00 2001 From: Hugo SUBTIL <ext.sopra.husubtil@grandlyon.com> Date: Thu, 31 Mar 2022 13:45:12 +0200 Subject: [PATCH 02/10] fix: double structure creation --- src/app/form/footer-form/footer-form.component.ts | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/app/form/footer-form/footer-form.component.ts b/src/app/form/footer-form/footer-form.component.ts index 75a4eba56..768195efc 100644 --- a/src/app/form/footer-form/footer-form.component.ts +++ b/src/app/form/footer-form/footer-form.component.ts @@ -125,10 +125,6 @@ export class FooterFormComponent implements OnChanges { //TODO Go to send mail page and send the mail return; } - if (this.currentStep === structureFormStep.structureConsent) { - const user: User = await this.profileService.getProfile(); - this.structureService.createStructure(this.form.value, user).subscribe(() => {}); - } } if (this.isPersonalOfferpage()) { this.endForm.emit({ formType: this.currentForm }); -- GitLab From 3f03788ee5eff89d54154466cf27cd900ef178e3 Mon Sep 17 00:00:00 2001 From: Hugo SUBTIL <ext.sopra.husubtil@grandlyon.com> Date: Fri, 1 Apr 2022 10:48:51 +0200 Subject: [PATCH 03/10] fix: 'ordinateur a disposition' to 'ordinateur' --- src/app/models/structure.model.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app/models/structure.model.ts b/src/app/models/structure.model.ts index 5f054a020..b6b46e2fd 100644 --- a/src/app/models/structure.model.ts +++ b/src/app/models/structure.model.ts @@ -176,7 +176,7 @@ export class Structure { case Equipment.tablet: return this.nbTablets > 1 ? 'Tablettes' : 'Tablette'; case Equipment.computer: - return this.nbComputers > 1 ? 'Ordinateurs à disposition' : 'Ordinateur à disposition'; + return this.nbComputers > 1 ? 'Ordinateurs' : 'Ordinateur'; case Equipment.scanner: return this.nbScanners > 1 ? 'Scanners' : 'Scanner'; default: -- GitLab From 3fbfed7dce6f039e5ce07e676363308b9fe0db0a Mon Sep 17 00:00:00 2001 From: Hugo SUBTIL <ext.sopra.husubtil@grandlyon.com> Date: Fri, 1 Apr 2022 11:53:54 +0200 Subject: [PATCH 04/10] fix(carto): modal display and selection --- src/app/login/login.component.ts | 1 - .../modal-filter/modal-filter.component.html | 2 +- .../modal-filter/modal-filter.component.scss | 7 +++++-- .../components/modal-filter/modal-filter.component.ts | 11 +++++++++-- 4 files changed, 15 insertions(+), 6 deletions(-) diff --git a/src/app/login/login.component.ts b/src/app/login/login.component.ts index 8a19ec138..e71bed030 100644 --- a/src/app/login/login.component.ts +++ b/src/app/login/login.component.ts @@ -86,7 +86,6 @@ export class LoginComponent implements OnInit { .subscribe( () => { if (this.isWelcome) { - console.log('la ?'); this.router.navigateByUrl('form/profile'); } else { this.router.navigateByUrl('news'); diff --git a/src/app/structure-list/components/modal-filter/modal-filter.component.html b/src/app/structure-list/components/modal-filter/modal-filter.component.html index 9347b785b..37b27ad7b 100644 --- a/src/app/structure-list/components/modal-filter/modal-filter.component.html +++ b/src/app/structure-list/components/modal-filter/modal-filter.component.html @@ -99,7 +99,7 @@ </div> <!-- Filter with multiple categories --> <div - class="contentModal maxModal" + class="contentModal maxModal max-height" fxLayout="row wrap" fxLayoutAlign="flex-start" *ngIf="categories.length > 1 && getModalType() !== 'moreFilters'" diff --git a/src/app/structure-list/components/modal-filter/modal-filter.component.scss b/src/app/structure-list/components/modal-filter/modal-filter.component.scss index 41e24d147..c74aa4544 100644 --- a/src/app/structure-list/components/modal-filter/modal-filter.component.scss +++ b/src/app/structure-list/components/modal-filter/modal-filter.component.scss @@ -79,8 +79,6 @@ .contentModal { overflow-y: auto; max-width: 1100px; - max-height: 50vh; - overflow-y: overlay; border-bottom: 1px solid $grey; @media #{$large-phone} { max-height: none; @@ -146,6 +144,10 @@ .toggled { transform: translateY(25%) rotate(-135deg); } + &.max-height { + max-height: 50vh; + overflow-y: overlay; + } } .footer { box-sizing: border-box; @@ -184,6 +186,7 @@ background: white; margin-top: 10%; border-radius: 8px; + // overflow: hidden; } .backDropModal { background: white; diff --git a/src/app/structure-list/components/modal-filter/modal-filter.component.ts b/src/app/structure-list/components/modal-filter/modal-filter.component.ts index f66820c5c..0620f70b8 100644 --- a/src/app/structure-list/components/modal-filter/modal-filter.component.ts +++ b/src/app/structure-list/components/modal-filter/modal-filter.component.ts @@ -1,4 +1,4 @@ -import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core'; +import { Component, EventEmitter, Input, OnChanges, OnInit, Output, SimpleChanges } from '@angular/core'; import { ButtonType } from '../../../shared/components/button/buttonType.enum'; import { TypeModal } from '../../enum/typeModal.enum'; import { Category } from '../../models/category.model'; @@ -10,8 +10,9 @@ import { SearchService } from '../../services/search.service'; templateUrl: './modal-filter.component.html', styleUrls: ['./modal-filter.component.scss'], }) -export class ModalFilterComponent implements OnInit { +export class ModalFilterComponent implements OnInit, OnChanges { constructor(public searchService: SearchService) {} + @Input() public modalType: TypeModal; @Input() public categories: Category[]; //checked modules filter list @@ -28,6 +29,12 @@ export class ModalFilterComponent implements OnInit { this.checkedModules = this.modules.slice(); } + ngOnChanges(changes: SimpleChanges): void { + if (changes.modalType) { + this.checkedModules = this.modules.slice(); + } + } + // Management of the checkbox event (Check / Uncheck) public onCheckboxChange(event, categ: string, text?: string): void { const checkValue: string = event.target.value; -- GitLab From e4c10e262d98930a14b468fb5f615937e09064bf Mon Sep 17 00:00:00 2001 From: Hugo SUBTIL <ext.sopra.husubtil@grandlyon.com> Date: Mon, 4 Apr 2022 10:40:37 +0200 Subject: [PATCH 05/10] fix: typo for structure details + add claimed structure handling for creation --- .../profile-structure-choice.component.html | 8 ++---- .../profile-structure-choice.component.ts | 28 +++++++++++-------- src/app/models/structure.model.ts | 2 ++ .../structure-details.component.ts | 2 +- 4 files changed, 22 insertions(+), 18 deletions(-) diff --git a/src/app/form/form-view/profile-form/profile-structure-choice/profile-structure-choice.component.html b/src/app/form/form-view/profile-form/profile-structure-choice/profile-structure-choice.component.html index 0c1388708..c6a731271 100644 --- a/src/app/form/form-view/profile-form/profile-structure-choice/profile-structure-choice.component.html +++ b/src/app/form/form-view/profile-form/profile-structure-choice/profile-structure-choice.component.html @@ -32,11 +32,7 @@ fxLayoutAlign="space-around" class="form-list" [class]=" - structure['alreadySelected'] - ? 'already-selected' - : isSelectedStructure(structure) - ? 'item-selected' - : '' + structure.alreadySelected ? 'already-selected' : isSelectedStructure(structure) ? 'item-selected' : '' " > <div fxLayout="row" fxLayoutAlign="space-between center"> @@ -51,7 +47,7 @@ [type]="'form'" [icon]="'validate'" ></app-svg-icon> - <div *ngIf="structure['alreadySelected']" class="sticker">Déjà <br />sélectionnée</div> + <div *ngIf="structure.alreadySelected" class="sticker">Déjà <br />sélectionnée</div> </div> </div> </div> diff --git a/src/app/form/form-view/profile-form/profile-structure-choice/profile-structure-choice.component.ts b/src/app/form/form-view/profile-form/profile-structure-choice/profile-structure-choice.component.ts index 0ea6eb920..f82a98768 100644 --- a/src/app/form/form-view/profile-form/profile-structure-choice/profile-structure-choice.component.ts +++ b/src/app/form/form-view/profile-form/profile-structure-choice/profile-structure-choice.component.ts @@ -16,7 +16,7 @@ export class ProfileStructureChoiceComponent implements OnInit { @Output() validateForm = new EventEmitter<Structure>(); @Output() selectedStructure: EventEmitter<Structure> = new EventEmitter<Structure>(); @Output() createStructure = new EventEmitter<any>(); - public searchString: string = ''; + public searchString = ''; public structures: Structure[]; public selectedStructureItem: Structure; public isAlreadySearching = false; @@ -29,13 +29,15 @@ export class ProfileStructureChoiceComponent implements OnInit { this.isAlreadySearching = true; this.profileService.getProfile().then((profile) => { this.isAlreadySearching = false; - this.profileStructuresLink = profile.structuresLink; + this.profileStructuresLink = [...profile.structuresLink, ...profile.pendingStructuresLink]; this.getStructures(null); }); } - public onSearchChange(searchString: string) { - if (searchString.length < 3 && this.searchString == '') return; + public onSearchChange(searchString: string): void { + if (searchString.length < 3 && this.searchString === '') { + return; + } this.searchString = searchString; const filters: Filter[] = []; if (searchString.length > 0) { @@ -45,28 +47,32 @@ export class ProfileStructureChoiceComponent implements OnInit { } public selectedResult(structure: Structure): void { - if (structure['alreadySelected']) return; - if (this.selectedStructureItem) this.selectedStructureItem['selected'] = false; + if (structure.alreadySelected) { + return; + } this.selectedStructureItem = structure; this.structureForm.patchValue({ _id: structure._id, structureName: structure.structureName }); this.validateForm.emit(); } public isSelectedStructure(structure: Structure): boolean { - if (this.selectedStructureItem && this.selectedStructureItem._id === structure._id) return true; - return false; + if (this.selectedStructureItem && this.selectedStructureItem._id === structure._id) { + return true; + } else { + return false; + } } - private getStructures(filters: Filter[]) { + private getStructures(filters: Filter[]): void { if (!this.isAlreadySearching) { this.isAlreadySearching = true; this.structureService.getStructuresByName(filters).subscribe((structures) => { structures.forEach((structure) => { if (this.profileStructuresLink.includes(structure._id)) { - structure['alreadySelected'] = true; + structure.alreadySelected = true; } }); - if (this.searchString == '') { + if (this.searchString === '') { structures.sort((a, b) => a.structureName.localeCompare(b.structureName)); } this.structures = structures; diff --git a/src/app/models/structure.model.ts b/src/app/models/structure.model.ts index b6b46e2fd..cfd7fce77 100644 --- a/src/app/models/structure.model.ts +++ b/src/app/models/structure.model.ts @@ -63,6 +63,8 @@ export class Structure { public personalOffers: PersonalOffer[] = []; + public alreadySelected? = false; + constructor(obj?: any) { Object.assign(this, obj, { hours: obj && obj.hours ? new Week(obj.hours) : new Week(), diff --git a/src/app/structure-list/components/structure-details/structure-details.component.ts b/src/app/structure-list/components/structure-details/structure-details.component.ts index b7d292dce..f5079f795 100644 --- a/src/app/structure-list/components/structure-details/structure-details.component.ts +++ b/src/app/structure-list/components/structure-details/structure-details.component.ts @@ -140,7 +140,7 @@ export class StructureDetailsComponent implements OnInit { case Equipment.tablet: return this.structure.nbTablets > 1 ? 'Tablettes' : 'Tablette'; case Equipment.computer: - return this.structure.nbComputers > 1 ? 'Ordinateurs à disposition' : 'Ordinateur à disposition'; + return this.structure.nbComputers > 1 ? 'Ordinateurs' : 'Ordinateur'; case Equipment.scanner: return this.structure.nbScanners > 1 ? 'Scanners' : 'Scanner'; default: -- GitLab From d090871c9cafe99cd6e5ac803639a586e8d7dfb5 Mon Sep 17 00:00:00 2001 From: Hugo SUBTIL <ext.sopra.husubtil@grandlyon.com> Date: Mon, 4 Apr 2022 11:32:07 +0200 Subject: [PATCH 06/10] fix: scroll issue and spacing on structure-list --- .../structure-details.component.html | 23 ++++------------ .../structure-list.component.html | 4 +-- .../structure-list.component.ts | 27 ------------------- 3 files changed, 7 insertions(+), 47 deletions(-) diff --git a/src/app/structure-list/components/structure-details/structure-details.component.html b/src/app/structure-list/components/structure-details/structure-details.component.html index 93a80c53b..b29bb96da 100644 --- a/src/app/structure-list/components/structure-details/structure-details.component.html +++ b/src/app/structure-list/components/structure-details/structure-details.component.html @@ -235,9 +235,7 @@ fxLayoutAlign="baseline baseline" fxLayoutGap="12px" > - <div fxLayout="row" fxLayoutAlign="none flex-end" fxLayoutGap="8px"> - <h2>Labellisations</h2> - </div> + <h2>Labellisations</h2> <div class="wrapper"> <div *ngFor="let labels of structure.labelsQualifications"> <app-logo-card [name]="labels"></app-logo-card> @@ -253,9 +251,7 @@ fxLayoutAlign="baseline baseline" fxLayoutGap="12px" > - <div fxLayout="row" fxLayoutAlign="none flex-end" fxLayoutGap="8px"> - <h2>Aides numérique</h2> - </div> + <h2>Aides numérique</h2> <div fxLayout="column"> <div class="wrapper"> <div *ngFor="let accompagnement of structure.proceduresAccompaniment"> @@ -276,11 +272,8 @@ fxLayout="column" class="structure-details-block noSeparator" fxLayoutAlign="baseline baseline" - fxLayoutGap="20px" > - <div fxLayout="row" fxLayoutAlign="none flex-end" fxLayoutGap="8px"> - <h2>Formations</h2> - </div> + <h2>Formations</h2> <div *ngIf="structure.freeWorkShop"> <span *ngIf="multipleWorkshop()" class="bold-info">L'accès à ces formations est gratuit</span> <span *ngIf="!multipleWorkshop()" class="bold-info">L'accès à cette formation est gratuit</span> @@ -424,11 +417,8 @@ fxLayout="column" class="structure-details-block" fxLayoutAlign="baseline baseline" - fxLayoutGap="20px" > - <div fxLayout="row" fxLayoutAlign="none flex-end" fxLayoutGap="8px"> - <h2>Matériel et wifi</h2> - </div> + <h2>Matériel et wifi</h2> <div fxLayout="column"> <div *ngIf="filterOnlyEquipments(structure.equipmentsAndServices).includes('wifiEnAccesLibre')"> {{ getEquipmentsLabel('wifiEnAccesLibre') }} @@ -459,11 +449,8 @@ fxLayout="column" class="structure-details-block noSeparator" fxLayoutAlign="baseline baseline" - fxLayoutGap="20px" > - <div fxLayout="row" fxLayoutAlign="none flex-end" fxLayoutGap="8px"> - <h2>Accès</h2> - </div> + <h2>Accès</h2> <div fxLayout="column wrap" fxLayoutGap="24px"> <div *ngFor="let tclStop of tclStopPoints | slice: 0:3"> {{ tclStop.name }} diff --git a/src/app/structure-list/structure-list.component.html b/src/app/structure-list/structure-list.component.html index 070db1154..e3ef2465b 100644 --- a/src/app/structure-list/structure-list.component.html +++ b/src/app/structure-list/structure-list.component.html @@ -1,4 +1,4 @@ -<div class="structureList-container" (scroll)="onScrollDown($event)"> +<div class="structureList-container"> <div class="structureListHeader hide-on-print"> <div class="nbStructuresLabel" [ngPlural]="structureList.length"> <ng-template ngPluralCase="0">0 structure</ng-template> @@ -16,7 +16,7 @@ <div id="listCard" class="listCard" (mouseleave)="mouseLeave()"> <app-card - *ngFor="let structure of structuresListChunked" + *ngFor="let structure of structureList" [structure]="structure" (showDetails)="showDetails($event, filters)" (hover)="handleCardHover($event)" diff --git a/src/app/structure-list/structure-list.component.ts b/src/app/structure-list/structure-list.component.ts index ff5496110..11aeae7da 100644 --- a/src/app/structure-list/structure-list.component.ts +++ b/src/app/structure-list/structure-list.component.ts @@ -23,10 +23,6 @@ export class StructureListComponent implements OnChanges { public buttonTypeEnum = ButtonType; public showStructureDetails = false; public structure: Structure; - public structuresListChunked: Structure[]; - private pageStructures = 0; - private arrayChunked: Structure[][] = []; - private chunck = 10; constructor( private route: ActivatedRoute, @@ -58,7 +54,6 @@ export class StructureListComponent implements OnChanges { }); } if (changes.structureList) { - this.structuresListChunked = this.chunckAnArray(this.structureList); document.getElementById('listCard').scrollTo(0, 0); } } @@ -93,26 +88,4 @@ export class StructureListComponent implements OnChanges { public emitUpdatedStructure(s: Structure): void { this.updatedStructure.emit(s); } - - private chunckAnArray(structures: Structure[]): Structure[] { - this.arrayChunked = []; - this.pageStructures = 0; - for (let i = 0; i < structures.length; i += this.chunck) { - this.arrayChunked.push(structures.slice(i, i + this.chunck)); - } - return this.arrayChunked[0]; - } - - public onScrollDown(event): void { - if (event.target.offsetHeight + event.target.scrollTop >= event.target.scrollHeight - 50) { - this.loadMoreStructures(); - } - } - private loadMoreStructures(): void { - if (this.pageStructures < this.arrayChunked.length - 1) { - this.pageStructures++; - const newStructures = _.map(this.arrayChunked[this.pageStructures]); - this.structuresListChunked = [...this.structuresListChunked, ...newStructures]; - } - } } -- GitLab From 3b6cc4a04ca86c302937a4fccc36028ac392227b Mon Sep 17 00:00:00 2001 From: Hugo SUBTIL <ext.sopra.husubtil@grandlyon.com> Date: Mon, 4 Apr 2022 12:54:02 +0200 Subject: [PATCH 07/10] fix(structure-details): tcl margin --- .../structure-details/structure-details.component.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app/structure-list/components/structure-details/structure-details.component.html b/src/app/structure-list/components/structure-details/structure-details.component.html index b29bb96da..d07ab3fd8 100644 --- a/src/app/structure-list/components/structure-details/structure-details.component.html +++ b/src/app/structure-list/components/structure-details/structure-details.component.html @@ -454,7 +454,7 @@ <div fxLayout="column wrap" fxLayoutGap="24px"> <div *ngFor="let tclStop of tclStopPoints | slice: 0:3"> {{ tclStop.name }} - <div fxLayout="row wrap" fxLayoutGap="24px"> + <div fxLayout="row wrap" fxLayoutGap="16px"> <p *ngFor="let sub of tclStop.subLines"> <app-svg-icon [type]="'tcl'" [icon]="sub" [iconClass]="'icon-75'"></app-svg-icon> </p> -- GitLab From 2a39d62b579f8a3476ef4e1d0555a0c8bcd705c1 Mon Sep 17 00:00:00 2001 From: Yoan VALLET <ext.sopra.yvallet@grandlyon.com> Date: Mon, 4 Apr 2022 14:18:01 +0200 Subject: [PATCH 08/10] fix: display of action btn in structure details --- .../structure-details/structure-details.component.scss | 1 - 1 file changed, 1 deletion(-) diff --git a/src/app/structure-list/components/structure-details/structure-details.component.scss b/src/app/structure-list/components/structure-details/structure-details.component.scss index 61c572e20..46c315d9c 100644 --- a/src/app/structure-list/components/structure-details/structure-details.component.scss +++ b/src/app/structure-list/components/structure-details/structure-details.component.scss @@ -86,7 +86,6 @@ h3 { } } @media #{$tablet} { - height: calc(100vh - #{$header-height}); .printButton { display: none !important; } -- GitLab From 2f3d842848f28bf52907ebe7b9242c72c8e6f7cf Mon Sep 17 00:00:00 2001 From: Yoan VALLET <ext.sopra.yvallet@grandlyon.com> Date: Mon, 4 Apr 2022 14:54:26 +0200 Subject: [PATCH 09/10] fix: add focus color --- src/app/post/components/post-header/post-header.component.scss | 2 +- .../structure-list-search/structure-list-search.component.scss | 2 +- src/assets/scss/_color.scss | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/app/post/components/post-header/post-header.component.scss b/src/app/post/components/post-header/post-header.component.scss index bb286f973..73030c03e 100644 --- a/src/app/post/components/post-header/post-header.component.scss +++ b/src/app/post/components/post-header/post-header.component.scss @@ -59,7 +59,7 @@ h1 { width: 7px; } &:focus { - border-color: $primary-color; + border-color: $focus-color; } } .selected { diff --git a/src/app/structure-list/components/structure-list-search/structure-list-search.component.scss b/src/app/structure-list/components/structure-list-search/structure-list-search.component.scss index 4c3a9bd3e..0161aa231 100644 --- a/src/app/structure-list/components/structure-list-search/structure-list-search.component.scss +++ b/src/app/structure-list/components/structure-list-search/structure-list-search.component.scss @@ -92,7 +92,7 @@ transition: all 300ms ease; } &:focus { - border-color: $primary-color; + border-color: $focus-color; } } .selected { diff --git a/src/assets/scss/_color.scss b/src/assets/scss/_color.scss index f0a2a0fae..a6a850372 100644 --- a/src/assets/scss/_color.scss +++ b/src/assets/scss/_color.scss @@ -38,3 +38,4 @@ $app-background: $grey-8; $ram-hover-principal: $primary-color; $scrollbar-track: rgba($grey-8, 0.65); $scrollbar-thumb: $grey-4; +$focus-color: $grey-1; -- GitLab From 09df831b67400b60e0f12aa149847e2d3c99d385 Mon Sep 17 00:00:00 2001 From: Hugo SUBTIL <ext.sopra.husubtil@grandlyon.com> Date: Mon, 4 Apr 2022 15:10:49 +0200 Subject: [PATCH 10/10] fix: structure creation name --- .../profile-structure-choice.component.ts | 4 ++-- .../form-view/structure-form/structure-form.component.html | 2 +- .../form/form-view/structure-form/structure-form.component.ts | 3 ++- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/app/form/form-view/profile-form/profile-structure-choice/profile-structure-choice.component.ts b/src/app/form/form-view/profile-form/profile-structure-choice/profile-structure-choice.component.ts index f82a98768..1afd24f12 100644 --- a/src/app/form/form-view/profile-form/profile-structure-choice/profile-structure-choice.component.ts +++ b/src/app/form/form-view/profile-form/profile-structure-choice/profile-structure-choice.component.ts @@ -15,7 +15,7 @@ export class ProfileStructureChoiceComponent implements OnInit { @Input() structureForm: FormGroup; @Output() validateForm = new EventEmitter<Structure>(); @Output() selectedStructure: EventEmitter<Structure> = new EventEmitter<Structure>(); - @Output() createStructure = new EventEmitter<any>(); + @Output() createStructure = new EventEmitter<string>(); public searchString = ''; public structures: Structure[]; public selectedStructureItem: Structure; @@ -82,6 +82,6 @@ export class ProfileStructureChoiceComponent implements OnInit { } public addStructure(): void { - this.createStructure.emit(); + this.createStructure.emit(this.searchString); } } diff --git a/src/app/form/form-view/structure-form/structure-form.component.html b/src/app/form/form-view/structure-form/structure-form.component.html index e169c6e8d..49dc8407f 100644 --- a/src/app/form/form-view/structure-form/structure-form.component.html +++ b/src/app/form/form-view/structure-form/structure-form.component.html @@ -3,7 +3,7 @@ <app-profile-structure-choice [structureForm]="structureForm" (validateForm)="setValidationsForm()" - (createStructure)="goToCreateStructure()" + (createStructure)="goToCreateStructure($event)" ></app-profile-structure-choice> </ng-container> <ng-container *ngIf="currentStep === structureFormStep.structureFormTime" class="no-max-width"> diff --git a/src/app/form/form-view/structure-form/structure-form.component.ts b/src/app/form/form-view/structure-form/structure-form.component.ts index 1bf91cbfa..d55a77f90 100644 --- a/src/app/form/form-view/structure-form/structure-form.component.ts +++ b/src/app/form/form-view/structure-form/structure-form.component.ts @@ -352,7 +352,8 @@ export class StructureFormComponent implements OnChanges { this.setValidationsForm(); } - public goToCreateStructure(): void { + public goToCreateStructure(structureName = ''): void { + this.structureForm.patchValue({ _id: null, structureName }); this.isNotExistingStructure.emit(); } } -- GitLab