MOBILE-2481 courses: Highlight section selector

main
Pau Ferrer Ocaña 2018-08-09 15:49:06 +02:00
parent e5a4fb3412
commit 8a2160db17
5 changed files with 65 additions and 13 deletions

View File

@ -10,7 +10,7 @@
<core-loading [hideUntil]="filesLoaded" *ngIf="showPrivateFiles || showSiteFiles">
<!-- Allow selecting the files to see: private or site. -->
<div no-padding *ngIf="showPrivateFiles && showSiteFiles && !path">
<div padding *ngIf="showPrivateFiles && showSiteFiles && !path">
<ion-select [(ngModel)]="root" (ngModelChange)="rootChanged()" interface="popover">
<ion-option value="my">{{ 'addon.files.privatefiles' | translate }}</ion-option>
<ion-option value="site">{{ 'addon.files.sitefiles' | translate }}</ion-option>

View File

@ -402,7 +402,7 @@ ion-card core-format-text img {
// Ionic fix. Button can occupy all page if not.
ion-select {
position: relative
position: relative;
}
ion-col ion-select {
@ -415,12 +415,52 @@ ion-col ion-select {
}
}
:not(.item) ion-select,
.core-button-select {
background-color: white;
color: $core-color;
white-space: normal;
align-self: start;
max-width: none;
&.select-md,
&.button-md {
background: $card-md-background-color;
box-shadow: $card-md-box-shadow;
}
&.select-ios,
&.button-ios {
background: $card-ios-background-color;
box-shadow: $card-ios-box-shadow;
}
&.select-wp,
&.button-wp {
background: $card-wp-background-color;
box-shadow: $card-wp-box-shadow;
}
.select-text {
white-space: normal;
}
.button-inner {
justify-content: space-between;
}
.select-icon .select-icon-inner {
color: $core-color;
}
ion-icon:last-child {
@include margin(null, null, null, 5px);
}
}
// File uploader.
// -------------------------

View File

@ -9,6 +9,22 @@ core-course-format {
.core-format-progress-list {
margin-bottom: 0;
.item {
background: transparent;
.label {
margin-top: 0;
margin-bottom: 0;
}
progress {
.progress-bar-fallback,
&[value]::-webkit-progress-bar {
background-color: $white;
}
}
}
}
.core-course-thumb {
@ -40,7 +56,3 @@ core-course-format {
}
}
}
.core-section-select {
width: 100%;
}

View File

@ -57,7 +57,7 @@ core-course-module {
padding-right: $label-md-margin-end;
margin-bottom: $label-md-margin-bottom;
.core-module-description .core-show-more {
.core-show-more {
padding-right: $label-md-margin-end;
}
}
@ -87,7 +87,7 @@ core-course-module {
padding-right: $label-ios-margin-end;
margin-bottom: $label-md-margin-bottom;
.core-module-description .core-show-more {
.core-show-more {
padding-right: $label-ios-margin-end;
}
}
@ -112,7 +112,7 @@ core-course-module {
padding-right: ($item-wp-padding-end / 2);
margin-bottom: $label-md-margin-bottom;
.core-module-description .core-show-more {
.core-show-more {
padding-right: ($item-wp-padding-end / 2);
}
}

View File

@ -36,14 +36,14 @@
<core-loading [hideUntil]="courses.loaded" class="core-loading-center">
<!-- "Time" selector. -->
<div no-padding class="clearfix" [hidden]="showFilter">
<ion-select [title]="'core.show' | translate" [(ngModel)]="courses.selected" float-start (ngModelChange)="selectedChanged()" interface="popover">
<div padding class="clearfix" [hidden]="showFilter" ion-row justify-content-between>
<ion-select float-start [title]="'core.show' | translate" [(ngModel)]="courses.selected" ion-col (ngModelChange)="selectedChanged()" interface="popover">
<ion-option value="inprogress">{{ 'core.courses.inprogress' | translate }}</ion-option>
<ion-option value="future">{{ 'core.courses.future' | translate }}</ion-option>
<ion-option value="past">{{ 'core.courses.past' | translate }}</ion-option>
</ion-select>
<!-- Download all courses. -->
<div *ngIf="downloadAllCoursesEnabled && courses[courses.selected] && courses[courses.selected].length > 1" class="core-button-spinner" float-end>
<div *ngIf="downloadAllCoursesEnabled && courses[courses.selected] && courses[courses.selected].length > 1" class="core-button-spinner">
<button *ngIf="prefetchCoursesData[courses.selected].icon && prefetchCoursesData[courses.selected].icon != 'spinner'" ion-button icon-only clear color="dark" (click)="prefetchCourses()">
<core-icon [name]="prefetchCoursesData[courses.selected].icon"></core-icon>
</button>
@ -81,7 +81,7 @@
<ion-refresher-content pullingText="{{ 'core.pulltorefresh' | translate }}"></ion-refresher-content>
</ion-refresher>
<div no-padding [hidden]="!(timeline.loaded || timelineCourses.loaded)">
<div padding [hidden]="!(timeline.loaded || timelineCourses.loaded)">
<ion-select [(ngModel)]="timeline.sort" (ngModelChange)="switchSort()" interface="popover">
<ion-option value="sortbydates">{{ 'core.courses.sortbydates' | translate }}</ion-option>
<ion-option value="sortbycourses">{{ 'core.courses.sortbycourses' | translate }}</ion-option>