MOBILE-3565 core: Add init page of the app

main
Dani Palou 2020-10-05 16:50:23 +02:00
parent af38737f40
commit 300f017036
6 changed files with 105 additions and 0 deletions

View File

@ -16,6 +16,15 @@ import { NgModule } from '@angular/core';
import { PreloadAllModules, RouterModule, Routes } from '@angular/router'; import { PreloadAllModules, RouterModule, Routes } from '@angular/router';
const routes: Routes = [ const routes: Routes = [
{
path: '',
redirectTo: 'login',
pathMatch: 'full',
},
{
path: 'login',
loadChildren: () => import('./core/login/login.module').then( m => m.CoreLoginModule),
},
]; ];
@NgModule({ @NgModule({

View File

@ -0,0 +1,30 @@
// (C) Copyright 2015 Moodle Pty Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
import { NgModule } from '@angular/core';
import { RouterModule, Routes } from '@angular/router';
import { CoreLoginInitPage } from './pages/init/init.page';
const routes: Routes = [
{
path: '',
component: CoreLoginInitPage,
},
];
@NgModule({
imports: [RouterModule.forChild(routes)],
exports: [RouterModule],
})
export class CoreLoginRoutingModule {}

View File

@ -0,0 +1,34 @@
// (C) Copyright 2015 Moodle Pty Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { IonicModule } from '@ionic/angular';
import { CoreLoginRoutingModule } from './login-routing.module';
import { CoreLoginInitPage } from './pages/init/init.page';
@NgModule({
imports: [
CommonModule,
IonicModule,
CoreLoginRoutingModule,
],
declarations: [
CoreLoginInitPage,
],
})
export class CoreLoginModule {}

View File

@ -0,0 +1,5 @@
<ion-content>
<div class="core-bglogo">
<ion-spinner></ion-spinner>
</div>
</ion-content>

View File

@ -0,0 +1,25 @@
// (C) Copyright 2015 Moodle Pty Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
import { Component } from '@angular/core';
/**
* Page that displays a "splash screen" while the app is being initialized.
*/
@Component({
selector: 'page-core-login-init',
templateUrl: 'init.html',
styleUrls: ['init.scss'],
})
export class CoreLoginInitPage { }

View File

@ -0,0 +1,2 @@
app-root page-core-login-init {
}