commit
69e4e78fa8
|
@ -99,6 +99,7 @@ ion-button {
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
line-height: 20px;
|
line-height: 20px;
|
||||||
|
border-radius: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.select-text {
|
.select-text {
|
||||||
|
|
|
@ -69,7 +69,7 @@ export class CoreInfiniteLoadingComponent implements OnChanges {
|
||||||
* like the Ionic component does.
|
* like the Ionic component does.
|
||||||
*/
|
*/
|
||||||
protected async checkScrollDistance(): Promise<void> {
|
protected async checkScrollDistance(): Promise<void> {
|
||||||
if (!this.enabled) {
|
if (!this.enabled || this.error || this.loadingMore) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -20,7 +20,7 @@ import { CoreConfig } from '@services/config';
|
||||||
import { CoreSites, CoreSiteCheckResponse, CoreLoginSiteInfo, CoreSitesDemoSiteData } from '@services/sites';
|
import { CoreSites, CoreSiteCheckResponse, CoreLoginSiteInfo, CoreSitesDemoSiteData } from '@services/sites';
|
||||||
import { CoreUtils } from '@services/utils/utils';
|
import { CoreUtils } from '@services/utils/utils';
|
||||||
import { CoreDomUtils } from '@services/utils/dom';
|
import { CoreDomUtils } from '@services/utils/dom';
|
||||||
import { CoreLoginHelper, CoreLoginHelperProvider } from '@features/login/services/login-helper';
|
import { CoreLoginHelper, CoreLoginHelperProvider, CoreLoginSiteSelectorListMethod } from '@features/login/services/login-helper';
|
||||||
import { CoreSite } from '@classes/site';
|
import { CoreSite } from '@classes/site';
|
||||||
import { CoreError } from '@classes/errors/error';
|
import { CoreError } from '@classes/errors/error';
|
||||||
import { CoreConstants } from '@/core/constants';
|
import { CoreConstants } from '@/core/constants';
|
||||||
|
@ -49,7 +49,7 @@ export class CoreLoginSitePage implements OnInit {
|
||||||
siteForm: FormGroup;
|
siteForm: FormGroup;
|
||||||
fixedSites?: CoreLoginSiteInfoExtended[];
|
fixedSites?: CoreLoginSiteInfoExtended[];
|
||||||
filteredSites?: CoreLoginSiteInfoExtended[];
|
filteredSites?: CoreLoginSiteInfoExtended[];
|
||||||
siteSelector = 'sitefinder';
|
siteSelector: CoreLoginSiteSelectorListMethod = 'sitefinder';
|
||||||
showKeyboard = false;
|
showKeyboard = false;
|
||||||
filter = '';
|
filter = '';
|
||||||
sites: CoreLoginSiteInfoExtended[] = [];
|
sites: CoreLoginSiteInfoExtended[] = [];
|
||||||
|
@ -124,24 +124,14 @@ export class CoreLoginSitePage implements OnInit {
|
||||||
* @return URL of the first site.
|
* @return URL of the first site.
|
||||||
*/
|
*/
|
||||||
protected initSiteSelector(): string {
|
protected initSiteSelector(): string {
|
||||||
// Deprecate listnourl on 3.9.3, remove this block on the following release.
|
|
||||||
if (this.siteSelector == 'listnourl') {
|
|
||||||
this.siteSelector = 'list';
|
|
||||||
this.siteFinderSettings.displayurl = false;
|
|
||||||
}
|
|
||||||
|
|
||||||
this.fixedSites = this.extendCoreLoginSiteInfo(<CoreLoginSiteInfoExtended[]> CoreLoginHelper.getFixedSites());
|
this.fixedSites = this.extendCoreLoginSiteInfo(<CoreLoginSiteInfoExtended[]> CoreLoginHelper.getFixedSites());
|
||||||
|
this.siteSelector = 'list'; // In case it's not defined
|
||||||
|
|
||||||
// Do not show images if none are set.
|
// Do not show images if none are set.
|
||||||
if (!this.fixedSites.some((site) => !!site.imageurl)) {
|
if (!this.fixedSites.some((site) => !!site.imageurl)) {
|
||||||
this.siteFinderSettings.displayimage = false;
|
this.siteFinderSettings.displayimage = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Autoselect if not defined.
|
|
||||||
if (this.siteSelector != 'list' && this.siteSelector != 'buttons') {
|
|
||||||
this.siteSelector = this.fixedSites.length > 3 ? 'list' : 'buttons';
|
|
||||||
}
|
|
||||||
|
|
||||||
this.filteredSites = this.fixedSites;
|
this.filteredSites = this.fixedSites;
|
||||||
|
|
||||||
return this.fixedSites[0].url;
|
return this.fixedSites[0].url;
|
||||||
|
|
|
@ -1443,3 +1443,9 @@ type StoredLoginLaunchData = {
|
||||||
pageOptions: CoreNavigationOptions;
|
pageOptions: CoreNavigationOptions;
|
||||||
ssoUrlParams: CoreUrlParams;
|
ssoUrlParams: CoreUrlParams;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export type CoreLoginSiteSelectorListMethod =
|
||||||
|
'url'|
|
||||||
|
'sitefinder'|
|
||||||
|
'list'|
|
||||||
|
'';
|
||||||
|
|
|
@ -21,8 +21,8 @@
|
||||||
<!-- Site home main contents. -->
|
<!-- Site home main contents. -->
|
||||||
<ng-container *ngIf="section && section.hasContent">
|
<ng-container *ngIf="section && section.hasContent">
|
||||||
<ion-item class="ion-text-wrap" *ngIf="section.summary">
|
<ion-item class="ion-text-wrap" *ngIf="section.summary">
|
||||||
<core-format-text [text]="section.summary" contextLevel="course" [contextInstanceId]="siteHomeId">
|
<ion-label><core-format-text [text]="section.summary" contextLevel="course" [contextInstanceId]="siteHomeId">
|
||||||
</core-format-text>
|
</core-format-text></ion-label>
|
||||||
</ion-item>
|
</ion-item>
|
||||||
|
|
||||||
<core-course-module *ngFor="let module of section.modules" [module]="module" [courseId]="siteHomeId"
|
<core-course-module *ngFor="let module of section.modules" [module]="module" [courseId]="siteHomeId"
|
||||||
|
|
|
@ -27,7 +27,7 @@ import { AddonModForum, AddonModForumData } from '@addons/mod/forum/services/for
|
||||||
export enum FrontPageItemNames {
|
export enum FrontPageItemNames {
|
||||||
NEWS_ITEMS = 0,
|
NEWS_ITEMS = 0,
|
||||||
LIST_OF_CATEGORIES = 2,
|
LIST_OF_CATEGORIES = 2,
|
||||||
COMBO_LIST = 3,
|
COMBO_LIST = 4,
|
||||||
ENROLLED_COURSES = 5,
|
ENROLLED_COURSES = 5,
|
||||||
LIST_OF_COURSE = 6,
|
LIST_OF_COURSE = 6,
|
||||||
COURSE_SEARCH_BOX = 7,
|
COURSE_SEARCH_BOX = 7,
|
||||||
|
|
|
@ -193,6 +193,13 @@ core-format-text {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Erase if core-format-text display is contents again.
|
||||||
|
.flex > core-format-text {
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
.core-course-title > p.item-heading > core-format-text {
|
||||||
|
display: inline;
|
||||||
|
}
|
||||||
|
|
||||||
@keyframes loading {
|
@keyframes loading {
|
||||||
0% {
|
0% {
|
||||||
|
|
|
@ -466,7 +466,7 @@ ion-toolbar {
|
||||||
|
|
||||||
border-bottom: 3px solid var(--color-base);
|
border-bottom: 3px solid var(--color-base);
|
||||||
|
|
||||||
ion-item::part(native) {
|
ion-item {
|
||||||
--inner-border-width: 0;
|
--inner-border-width: 0;
|
||||||
}
|
}
|
||||||
ion-label {
|
ion-label {
|
||||||
|
@ -480,9 +480,9 @@ ion-toolbar {
|
||||||
.item.core-#{$color-name}-item {
|
.item.core-#{$color-name}-item {
|
||||||
--color-base: var(--ion-color-#{$color-name});
|
--color-base: var(--ion-color-#{$color-name});
|
||||||
|
|
||||||
--inner-border-width: 0 0 3px 0;
|
--border-width: 0 0 3px 0;
|
||||||
--border-width: 0;
|
--border-color: var(--color-base);
|
||||||
border-bottom: 3px solid var(--color-base) !important;
|
--inner-border-width: 0;
|
||||||
ion-icon {
|
ion-icon {
|
||||||
color: var(--color-base);
|
color: var(--color-base);
|
||||||
}
|
}
|
||||||
|
@ -922,7 +922,7 @@ ion-item.ion-activatable:not(.only-links) {
|
||||||
|
|
||||||
ion-anchor, a,
|
ion-anchor, a,
|
||||||
ion-button, button,
|
ion-button, button,
|
||||||
audio, video, select, input {
|
audio, video, select, input, iframe {
|
||||||
pointer-events: visible;
|
pointer-events: visible;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,6 +16,7 @@ import { CoreColorScheme, CoreZoomLevel } from '@features/settings/services/sett
|
||||||
import { CoreMainMenuLocalizedCustomItem } from '@features/mainmenu/services/mainmenu';
|
import { CoreMainMenuLocalizedCustomItem } from '@features/mainmenu/services/mainmenu';
|
||||||
import { CoreSitesDemoSiteData } from '@services/sites';
|
import { CoreSitesDemoSiteData } from '@services/sites';
|
||||||
import { OpenFileAction } from '@services/utils/utils';
|
import { OpenFileAction } from '@services/utils/utils';
|
||||||
|
import { CoreLoginSiteSelectorListMethod } from '@features/login/services/login-helper';
|
||||||
|
|
||||||
/* eslint-disable @typescript-eslint/naming-convention */
|
/* eslint-disable @typescript-eslint/naming-convention */
|
||||||
|
|
||||||
|
@ -37,7 +38,7 @@ export interface EnvironmentConfig {
|
||||||
customurlscheme: string;
|
customurlscheme: string;
|
||||||
siteurl: string;
|
siteurl: string;
|
||||||
sitename: string;
|
sitename: string;
|
||||||
multisitesdisplay: string;
|
multisitesdisplay: CoreLoginSiteSelectorListMethod;
|
||||||
sitefindersettings: Record<string, unknown>;
|
sitefindersettings: Record<string, unknown>;
|
||||||
onlyallowlistedsites: boolean;
|
onlyallowlistedsites: boolean;
|
||||||
skipssoconfirmation: boolean;
|
skipssoconfirmation: boolean;
|
||||||
|
|
Loading…
Reference in New Issue