MOBILE-2345 lesson: Styling

main
Pau Ferrer Ocaña 2018-05-28 14:52:32 +02:00 committed by Dani Palou
parent c29ed3be26
commit a3a7c3fc68
10 changed files with 33 additions and 27 deletions

View File

@ -76,7 +76,7 @@
<!-- Ungrouped users. -->
<div *ngIf="assign.teamsubmission && summary && summary.warnofungroupedusers" class="core-info-card" icon-start>
<ion-icon name="information"></ion-icon>
<ion-icon name="information-circle"></ion-icon>
{{ 'addon.mod_assign.ungroupedusers' | translate }}
</div>
</ion-card>

View File

@ -34,7 +34,7 @@
<!-- Inform what will happen with the choices. -->
<div *ngIf="canEdit && publishInfo && options && options.length" class="core-info-card" icon-start>
<ion-icon name="information"></ion-icon>
<ion-icon name="information-circle"></ion-icon>
{{ publishInfo | translate }}
</div>

View File

@ -21,7 +21,7 @@
<!-- Prevent access messages. Only show the first one. -->
<div class="core-info-card" icon-start *ngIf="lesson && preventMessages && preventMessages.length">
<ion-icon name="information"></ion-icon>
<ion-icon name="information-circle"></ion-icon>
<core-format-text [component]="component" [componentId]="componentId" [text]="preventMessages[0].message"></core-format-text>
</div>

View File

@ -13,7 +13,7 @@
<core-loading [hideUntil]="loaded">
<!-- Info messages. Only show the first one. -->
<div class="core-info-card" icon-start *ngIf="lesson && messages && messages.length">
<ion-icon name="information"></ion-icon>
<ion-icon name="information-circle"></ion-icon>
<core-format-text [component]="component" [componentId]="lesson.coursemodule" [text]="messages[0].message"></core-format-text>
</div>
@ -56,9 +56,7 @@
<!-- Essay. -->
<ng-container *ngSwitchCase="'essay'">
<ion-item *ngIf="question.textarea">
<core-rich-text-editor item-content placeholder="{{ 'addon.mod_lesson.youranswer' | translate }}" [control]="question.control"></core-rich-text-editor>
<!-- @todo: Attributes that were passed to RTE in Ionic 1 but now they aren't supported yet:
[component]="component" [componentId]="lesson.coursemodule" -->
<core-rich-text-editor item-content placeholder="{{ 'addon.mod_lesson.youranswer' | translate }}" [control]="question.control" [component]="component" [componentId]="lesson.coursemodule"></core-rich-text-editor>
</ion-item>
<ion-item text-wrap *ngIf="!question.textarea && question.useranswer">
<p class="item-heading">{{ 'addon.mod_lesson.youranswer' | translate }}</p>
@ -116,21 +114,19 @@
<!-- Page buttons and progress. -->
<ion-list *ngIf="!eolData && !processData">
<ion-item text-wrap *ngIf="pageButtons && pageButtons.length">
<ion-grid>
<ion-row>
<ion-col *ngFor="let button of pageButtons">
<a ion-button block color="light" text-wrap [id]="button.id" (click)="buttonClicked(button.data)">{{ button.content }}</a>
<ion-grid text-wrap *ngIf="pageButtons && pageButtons.length" class="addon-mod_lesson-pagebuttons">
<ion-row align-items-center>
<ion-col *ngFor="let button of pageButtons" col-12 col-md-6 col-lg-3 col-xl>
<a ion-button block outline text-wrap [id]="button.id" (click)="buttonClicked(button.data)">{{ button.content }}</a>
</ion-col>
</ion-row>
</ion-grid>
</ion-item>
<ion-item text-wrap *ngIf="lesson && lesson.progressbar && !canManage && pageData">
<p>{{ 'addon.mod_lesson.progresscompleted' | translate:{$a: pageData.progress} }}</p>
<core-progress-bar [progress]="pageData.progress"></core-progress-bar>
</ion-item>
<div class="core-info-card" icon-start *ngIf="lesson && lesson.progressbar && canManage">
<ion-icon name="information"></ion-icon>
<ion-icon name="information-circle"></ion-icon>
{{ 'addon.mod_lesson.progressbarteacherwarning2' | translate }}
</div>
</ion-list>

View File

@ -2,10 +2,20 @@ page-addon-mod-lesson-player {
.addon-mod_lesson-slideshow {
max-width: 100%;
max-height: 100%;
margin: 0 auto;
}
ion-input[padding-left] input[padding-left] {
// Applying padding-left to the ion-input applies it twice since it's replicated in the inner input.
padding-left: 0;
}
.addon-mod_lesson-pagebuttons .button-block {
contain: content;
height: auto;
.button-inner {
height: auto;
}
}
}

View File

@ -17,7 +17,7 @@
<!-- Warning message. -->
<div *ngIf="scorm && scorm.warningMessage" class="core-info-card" icon-start>
<ion-icon name="information"></ion-icon>
<ion-icon name="information-circle"></ion-icon>
{{ scorm.warningMessage }}
</div>

View File

@ -4,7 +4,7 @@
<ion-item text-wrap [ngClass]="{invisible: !question.loaded}">
<p *ngIf="!question.readOnly" class="core-info-card" icon-start>
<ion-icon name="information"></ion-icon>
<ion-icon name="information-circle"></ion-icon>
{{ 'core.question.howtodraganddrop' | translate }}
</p>
<p><core-format-text [component]="component" [componentId]="componentId" [text]="question.text"></core-format-text></p>

View File

@ -4,7 +4,7 @@
<ion-item text-wrap [ngClass]="{invisible: !question.loaded}">
<p *ngIf="!question.readOnly" class="core-info-card" icon-start>
<ion-icon name="information"></ion-icon>
<ion-icon name="information-circle"></ion-icon>
{{ 'core.question.howtodraganddrop' | translate }}
</p>
<p><core-format-text [component]="component" [componentId]="componentId" [text]="question.text"></core-format-text></p>

View File

@ -1,7 +1,7 @@
<section ion-list *ngIf="question.text || question.text === ''">
<ion-item text-wrap class="addon-qtype-ddwtos-container">
<p *ngIf="!question.readOnly" class="core-info-card" icon-start>
<ion-icon name="information"></ion-icon>
<ion-icon name="information-circle"></ion-icon>
{{ 'core.question.howtodraganddrop' | translate }}
</p>
<p><core-format-text [component]="component" [componentId]="componentId" [text]="question.text"></core-format-text></p>

View File

@ -11,7 +11,7 @@ core-show-password {
background: transparent;
padding: 0 ($content-padding / 2);
position: absolute;
top: $content-padding / 2;
bottom: $content-padding / 2;
right: 0;
margin-top: 0;
margin-bottom: 0;
@ -25,25 +25,25 @@ core-show-password {
.md {
.item-label-stacked core-show-password .button[icon-only] {
top: 0;
bottom: 0;
}
}
.ios {
.item-label-stacked core-show-password .button[icon-only] {
top: -5px;
bottom: -5px;
}
core-show-password .button[icon-only] {
top: 0;
bottom: 0;
}
}
.wp {
.item-label-stacked core-show-password .button[icon-only] {
top: 7px;
bottom: 7px;
}
core-show-password .button[icon-only] {
top: 12px;
bottom: 12px;
right: 5px;
}
}