Merge pull request #3256 from crazyserver/MOBILE-3833

Mobile 3833
main
Dani Palou 2022-04-19 16:35:32 +02:00 committed by GitHub
commit 63bc43ceb4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 13 additions and 9 deletions

View File

@ -1,15 +1,16 @@
<!-- Buttons to add to the header. --> <!-- Buttons to add to the header. -->
<core-navbar-buttons slot="end"> <core-navbar-buttons slot="end">
<ion-button *ngIf="glossary && glossary.browsemodes && glossary.browsemodes.length > 1" (click)="openModePicker($event)" <ion-button *ngIf="!showLoading && glossary && glossary.browsemodes && glossary.browsemodes.length > 1" (click)="openModePicker($event)"
[attr.aria-label]="'addon.mod_glossary.browsemode' | translate"> [attr.aria-label]="'addon.mod_glossary.browsemode' | translate">
<ion-icon name="fas-sort" slot="icon-only" aria-hidden="true"></ion-icon> <ion-icon name="fas-sort" slot="icon-only" aria-hidden="true"></ion-icon>
</ion-button> </ion-button>
<ion-button *ngIf="glossary" (click)="toggleSearch()" [attr.aria-label]="'addon.mod_glossary.bysearch' | translate"> <ion-button *ngIf="!showLoading && glossary" (click)="toggleSearch()" [attr.aria-label]="'addon.mod_glossary.bysearch' | translate">
<ion-icon name="fas-search" slot="icon-only" aria-hidden="true"></ion-icon> <ion-icon name="fas-search" slot="icon-only" aria-hidden="true"></ion-icon>
</ion-button> </ion-button>
<ion-button fill="clear" (click)="openModuleSummary()" aria-haspopup="true" [attr.aria-label]="'core.info' | translate"> <ion-button *ngIf="!showLoading" fill="clear" (click)="openModuleSummary()" aria-haspopup="true"
[attr.aria-label]="'core.info' | translate">
<ion-icon name="fas-info-circle" slot="icon-only" aria-hidden="true"></ion-icon> <ion-icon name="fas-info-circle" slot="icon-only" aria-hidden="true"></ion-icon>
</ion-button> </ion-button>
</core-navbar-buttons> </core-navbar-buttons>
@ -77,7 +78,7 @@
<core-course-module-navigation collapsible-footer [hidden]="showLoading" [courseId]="courseId" [currentModuleId]="module.id"> <core-course-module-navigation collapsible-footer [hidden]="showLoading" [courseId]="courseId" [currentModuleId]="module.id">
</core-course-module-navigation> </core-course-module-navigation>
<ion-fab slot="fixed" core-fab vertical="bottom" horizontal="end" *ngIf="canAdd"> <ion-fab slot="fixed" core-fab vertical="bottom" horizontal="end" *ngIf="canAdd && !showLoading">
<ion-fab-button (click)="openNewEntry()" [attr.aria-label]="'addon.mod_glossary.addentry' | translate"> <ion-fab-button (click)="openNewEntry()" [attr.aria-label]="'addon.mod_glossary.addentry' | translate">
<ion-icon name="fas-plus" aria-hidden="true"></ion-icon> <ion-icon name="fas-plus" aria-hidden="true"></ion-icon>
<span class="sr-only">{{ 'addon.mod_glossary.addentry' | translate }}</span> <span class="sr-only">{{ 'addon.mod_glossary.addentry' | translate }}</span>

View File

@ -3,9 +3,9 @@
@mixin inline() { @mixin inline() {
min-height: var(--internal-loading-inline-min-height); min-height: var(--internal-loading-inline-min-height);
max-height: 100vh; // In order show it on the page (content will be cut). max-height: 100vh; // In order show it on the page (content will be cut).
position: relative;
&:not(.core-loading-loaded) { &:not(.core-loading-loaded) {
position: relative;
--contents-display: flex; --contents-display: flex;
flex-direction: column; flex-direction: column;
} }
@ -15,6 +15,7 @@
flex-direction: row; flex-direction: row;
height: auto; height: auto;
width: auto; width: auto;
position: absolute;
.core-loading-message { .core-loading-message {
@include margin(0, 0, 0, 10px); @include margin(0, 0, 0, 10px);
@ -32,14 +33,14 @@
--internal-loading-inline-min-height: var(--loading-inline-min-height); --internal-loading-inline-min-height: var(--loading-inline-min-height);
--loading-display: flex; --loading-display: flex;
--loading-display-message: block; --loading-display-message: block;
--contents-display: contents; --contents-display: block;
@include core-transition(all, 200ms); @include core-transition(all, 200ms);
pointer-events: none; pointer-events: none;
display: var(--contents-display); display: var(--contents-display);
&.core-loading-loaded { &.core-loading-loaded {
position: static; --contents-display: contents;
pointer-events: auto; pointer-events: auto;
--internal-loading-inline-min-height: 0px; --internal-loading-inline-min-height: 0px;
@ -52,11 +53,11 @@
.core-loading-container { .core-loading-container {
pointer-events: none; pointer-events: none;
position: absolute; position: fixed;
@include position(0, 0, 0, 0); @include position(0, 0, 0, 0);
height: 100%; height: 100%;
width: 100%; width: 100%;
z-index: 3; z-index: 100;
margin: 0; margin: 0;
padding: 0; padding: 0;
color: var(--loading-text-color); color: var(--loading-text-color);
@ -101,4 +102,6 @@
:host-context(.ios) { :host-context(.ios) {
--contents-display: flex; --contents-display: flex;
flex-direction: column; flex-direction: column;
max-height: max-content;
width: 100%;
} }