MOBILE-2509 grades: Remove padding on grade column name

main
Pau Ferrer Ocaña 2018-08-14 12:48:05 +02:00
parent 44917ca99d
commit 17cf89fada
3 changed files with 10 additions and 5 deletions

View File

@ -19,8 +19,8 @@
<tr *ngFor="let row of gradesTable.rows" (click)="row.itemtype != 'category' && gotoGrade(row.id)" [class]="row.rowclass"> <tr *ngFor="let row of gradesTable.rows" (click)="row.itemtype != 'category' && gotoGrade(row.id)" [class]="row.rowclass">
<td *ngIf="row.itemtype == 'category'" class="core-grades-table-category" [attr.rowspan]="row.rowspan"> <td *ngIf="row.itemtype == 'category'" class="core-grades-table-category" [attr.rowspan]="row.rowspan">
</td> </td>
<th class="core-grades-table-gradeitem" [attr.colspan]="row.colspan" [class.core-split-item-selected]="gradeId == row.id"> <th class="core-grades-table-gradeitem" [class.column-itemname]="row.itemtype == 'category'" [attr.colspan]="row.colspan" [class.core-split-item-selected]="gradeId == row.id">
<ion-icon *ngIf="row.icon" name="{{row.icon}}" item-start></ion-icon> <core-icon *ngIf="row.icon" name="{{row.icon}}" item-start></core-icon>
<img *ngIf="row.image" [src]="row.image" item-start/> <img *ngIf="row.image" [src]="row.image" item-start/>
<span [innerHTML]="row.gradeitem"></span> <span [innerHTML]="row.gradeitem"></span>
</th> </th>

View File

@ -32,6 +32,11 @@ core-grades-course {
.core-grades-table-gradeitem { .core-grades-table-gradeitem {
padding-left: 5px; padding-left: 5px;
font-weight: bold; font-weight: bold;
&.column-itemname {
padding-left: 0;
}
img { img {
width: 16px; width: 16px;
height: 16px; height: 16px;

View File

@ -426,13 +426,13 @@ export class CoreGradesHelperProvider {
row['image'] = 'assets/img/grades/agg_sum.png'; row['image'] = 'assets/img/grades/agg_sum.png';
} else if (text.indexOf('/outcomes') > -1 || text.indexOf('fa-tasks') > -1) { } else if (text.indexOf('/outcomes') > -1 || text.indexOf('fa-tasks') > -1) {
row['itemtype'] = 'outcome'; row['itemtype'] = 'outcome';
row['image'] = 'assets/img/grades/outcomes.png'; row['icon'] = 'fa-tasks';
} else if (text.indexOf('i/folder') > -1 || text.indexOf('fa-folder') > -1) { } else if (text.indexOf('i/folder') > -1 || text.indexOf('fa-folder') > -1) {
row['itemtype'] = 'category'; row['itemtype'] = 'category';
row['icon'] = 'folder'; row['icon'] = 'fa-folder';
} else if (text.indexOf('/manual_item') > -1 || text.indexOf('fa-square-o') > -1) { } else if (text.indexOf('/manual_item') > -1 || text.indexOf('fa-square-o') > -1) {
row['itemtype'] = 'manual'; row['itemtype'] = 'manual';
row['icon'] = 'square-outline'; row['icon'] = 'fa-square-o';
} else if (text.indexOf('/mod/') > -1) { } else if (text.indexOf('/mod/') > -1) {
const module = text.match(/mod\/([^\/]*)\//); const module = text.match(/mod\/([^\/]*)\//);
if (typeof module[1] != 'undefined') { if (typeof module[1] != 'undefined') {