Skip to content

Commit c454521

Browse files
authored
Merge pull request #101 from EBISPOT/gwas-curation-ui#91_Studies_Management_Page_to_view,_filter,_and_export_studies_in_the_curation_app
remove quotes from params and minor ui improvements
2 parents c5c7895 + a2dde8a commit c454521

File tree

4 files changed

+22
-14
lines changed

4 files changed

+22
-14
lines changed

src/app/core/services/study.service.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,13 @@ export class StudyService {
2222
params = params.set('sort', sort + ',' + order);
2323
}
2424
if (efoTrait){
25-
params = params.set('efoTrait', '"' + efoTrait + '"');
25+
params = params.set('efoTrait', efoTrait);
2626
}
2727
if (reportedTrait) {
28-
params = params.set('reportedTrait', '"' + reportedTrait + '"');
28+
params = params.set('reportedTrait', reportedTrait);
2929
}
3030
if (note) {
31-
params = params.set('note', '"' + note + '"');
31+
params = params.set('note', note);
3232
}
3333
if (sumstatsFlag !== 'any' && sumstatsFlag != null) {
3434
params = params.set('sumstatsFlag', String(sumstatsFlag));

src/app/feature/study/pages/study-search/study-search.component.css

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,9 +70,9 @@ tr.example-element-row:not(.example-expanded-row):active {
7070
background-color: #eee;
7171
}
7272

73-
.note-col {
73+
.ellipsis-col {
7474
overflow: hidden;
75-
max-width: 120px;
75+
max-width: 200px;
7676
text-overflow: ellipsis;
7777
white-space: nowrap;
7878
}

src/app/feature/study/pages/study-search/study-search.component.html

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -65,10 +65,6 @@ <h3>Search parameters</h3>
6565
<mat-option disabled *ngIf="efoTraitsDropdownItems.length == 0"> No results.</mat-option>
6666
</mat-autocomplete>
6767
</mat-form-field>
68-
<button mat-raised-button class="ml-4 filters-button" color="accent" (click)="resetFilters()">
69-
<mat-icon>restart_alt</mat-icon>
70-
Reset
71-
</button>
7268
<br>
7369
<mat-form-field appearance="outline">
7470
<mat-label>GxE flag</mat-label>
@@ -97,7 +93,12 @@ <h3>Search parameters</h3>
9793
</mat-select>
9894
</mat-form-field>
9995

100-
<button mat-raised-button class="ml-4 filters-button" color="accent" (click)="search()">
96+
<button mat-raised-button class="ml-4 filters-button" color="primary" (click)="resetFilters()">
97+
<mat-icon>restart_alt</mat-icon>
98+
Reset
99+
</button>
100+
101+
<button mat-raised-button class="ml-4 filters-button" color="primary" (click)="search()">
101102
<mat-icon>search</mat-icon>
102103
Search
103104
</button>
@@ -146,8 +147,10 @@ <h3>Search parameters</h3>
146147
</ng-container>
147148

148149
<ng-container matColumnDef="title">
149-
<th mat-header-cell *matHeaderCellDef mat-sort-header>TITLE</th>
150-
<td mat-cell *matCellDef="let row">{{row?.title || 'NA'}}</td>
150+
<th mat-header-cell *matHeaderCellDef>TITLE</th>
151+
<td mat-cell *matCellDef="let row" class="ellipsis-col">
152+
<span matTooltip="{{row?.title}}" matTooltipClass="mat-tooltip">{{row?.title || 'NA'}}</span>
153+
</td>
151154
</ng-container>
152155

153156
<ng-container matColumnDef="efoTrait">
@@ -162,8 +165,8 @@ <h3>Search parameters</h3>
162165

163166
<ng-container matColumnDef="note">
164167
<th mat-header-cell *matHeaderCellDef>NOTE</th>
165-
<td mat-cell *matCellDef="let row" class="note-col">{{row?.notes?.toString() || 'NA'}}
166-
<button mat-icon-button class="float-right" (click)="(expandedElement = expandedElement === row ? null : row); $event.stopPropagation()" *ngIf="row?.notes">
168+
<td mat-cell *matCellDef="let row" class="ellipsis-col">{{row?.notes?.toString() || 'NA'}}
169+
<button mat-icon-button class="float-right -top-8 -right-6" (click)="(expandedElement = expandedElement === row ? null : row); $event.stopPropagation()" *ngIf="row?.notes">
167170
<mat-icon *ngIf="expandedElement !== row">keyboard_arrow_down</mat-icon>
168171
<mat-icon *ngIf="expandedElement === row">keyboard_arrow_up</mat-icon>
169172
</button>

src/styles.css

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -434,3 +434,8 @@ a.menu-btn {
434434
position: fixed;
435435
overflow-y: scroll;
436436
}
437+
438+
.mat-tooltip {
439+
font-family: 'IBM Plex Mono', monospace;
440+
font-size: 12px;
441+
}

0 commit comments

Comments
 (0)